{"version":3,"sources":["webpack:///./node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js","webpack:///./node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js","webpack:///./node_modules/@babel/runtime/helpers/esm/inherits.js","webpack:///./node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js","webpack:///./node_modules/@babel/runtime/helpers/esm/iterableToArray.js","webpack:///./node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js","webpack:///./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js","webpack:///./node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js","webpack:///./node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js","webpack:///./node_modules/@babel/runtime/helpers/esm/nonIterableRest.js","webpack:///./node_modules/@babel/runtime/helpers/esm/slicedToArray.js","webpack:///./node_modules/@babel/runtime/helpers/esm/isNativeReflectConstruct.js","webpack:///./node_modules/@babel/runtime/helpers/esm/construct.js","webpack:///./node_modules/@babel/runtime/helpers/esm/superPropBase.js","webpack:///./node_modules/@babel/runtime/helpers/esm/get.js","webpack:///./node_modules/@babel/runtime/helpers/esm/typeof.js","webpack:///./node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js","webpack:///./node_modules/@babel/runtime/helpers/typeof.js","webpack:///./node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js","webpack:///./node_modules/@babel/runtime/helpers/esm/isNativeFunction.js","webpack:///./node_modules/@babel/runtime/helpers/esm/wrapNativeSuper.js","webpack:///./node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js","webpack:///./node_modules/@babel/runtime/helpers/esm/defineProperty.js","webpack:///./node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","webpack:///./node_modules/@babel/runtime/helpers/esm/createClass.js","webpack:///./node_modules/@ckeditor/ckeditor5-alignment/src/utils.js","webpack:///./node_modules/@ckeditor/ckeditor5-alignment/src/alignmentcommand.js","webpack:///./node_modules/@ckeditor/ckeditor5-alignment/src/alignmentediting.js","webpack:///./node_modules/@ckeditor/ckeditor5-alignment/src/alignmentui.js","webpack:///./node_modules/@ckeditor/ckeditor5-alignment/src/alignment.js","webpack:///./node_modules/@babel/runtime/helpers/esm/classCallCheck.js"],"names":["__webpack_require__","d","__webpack_exports__","_unsupportedIterableToArray","_arrayLikeToArray_js__WEBPACK_IMPORTED_MODULE_0__","o","minLen","Object","n","prototype","toString","call","slice","constructor","name","Array","from","test","_assertThisInitialized","self","ReferenceError","_inherits","_setPrototypeOf_js__WEBPACK_IMPORTED_MODULE_0__","subClass","superClass","TypeError","create","value","writable","configurable","_arrayWithoutHoles","arr","isArray","arrayLikeToArray","_iterableToArray","iter","Symbol","iterator","_nonIterableSpread","_toConsumableArray","unsupportedIterableToArray","_arrayWithHoles","_iterableToArrayLimit","i","_i","_s","_e","_arr","_n","_d","next","done","push","length","err","_nonIterableRest","_slicedToArray","_isNativeReflectConstruct","Reflect","construct","sham","Proxy","Boolean","valueOf","e","construct_construct","Parent","args","Class","a","apply","Constructor","Function","bind","instance","setPrototypeOf","arguments","_superPropBase","object","property","hasOwnProperty","getPrototypeOf","get_get","get","target","receiver","base","desc","getOwnPropertyDescriptor","this","_typeof","obj","_arrayLikeToArray","len","arr2","module","exports","__esModule","_getPrototypeOf","__proto__","_isNativeFunction","fn","indexOf","wrapNativeSuper_wrapNativeSuper","_cache","Map","undefined","has","set","Wrapper","enumerable","_possibleConstructorReturn","_babel_runtime_helpers_typeof__WEBPACK_IMPORTED_MODULE_0__","_babel_runtime_helpers_typeof__WEBPACK_IMPORTED_MODULE_0___default","_assertThisInitialized_js__WEBPACK_IMPORTED_MODULE_1__","_defineProperty","key","defineProperty","_setPrototypeOf","p","_defineProperties","props","descriptor","_createClass","protoProps","staticProps","supportedOptions","isSupported","option","includes","isDefault","alignment","locale","contentLanguageDirection","normalizeAlignmentOptions","configuredOptions","normalizedOptions","map","result","filter","isNameValid","logWarning","classNameCount","className","CKEditorError","forEach","index","allOptions","succeedingOptions","nameAlreadyExists","some","item","classNameAlreadyExists","ALIGNMENT","AlignmentCommand","editor","firstBlock","first","model","document","selection","getSelectedBlocks","isEnabled","_canBeAligned","hasAttribute","getAttribute","_this","options","doc","change","writer","blocks","block","currentAlignment","removeAlignment","removeAlignmentFromSelection","setAlignmentOnSelection","schema","checkAttribute","Command","_step","_iterator","_createForOfIteratorHelper","s","removeAttribute","f","_step2","_iterator2","setAttribute","AlignmentEditing","classCallCheck","_super","config","define","toConsumableArray","optionsToConvert","shouldUseClasses","extend","allowAttributes","setAttributeProperties","isFormatting","conversion","attributeToAttribute","buildClassDefinition","for","buildDowncastInlineDefinition","upcastInlineDefinitions","buildUpcastInlineDefinitions","alignmentediting_createForOfIteratorHelper","definition","upcastCompatibilityDefinitions","buildUpcastCompatibilityDefinitions","commands","add","Plugin","_step3","values","view","_iterator3","text-align","_step4","definitions","_iterator4","_step5","_iterator5","_step6","_iterator6","iconsMap","icons","alignLeft","alignRight","alignCenter","alignJustify","AlignmentUI","t","left","right","center","justify","componentFactory","ui","_addButton","dropdownView","createDropdown","buttons","concat","addToolbarToDropdown","buttonView","label","tooltip","toolbarView","isVertical","ariaLabel","extendTemplate","attributes","class","defaultIcon","toMany","_len","areActive","_key","findIndex","icon","_len2","areEnabled","_key2","_this2","command","ButtonView","localizedOptionTitles","isToggleable","to","listenTo","execute","editing","focus","Alignment","_classCallCheck"],"mappings":"kHAAAA,EAAAC,EAAAC,EAAA,sBAAAC,IAAA,IAAAC,EAAAJ,EAAA,QACe,SAAAG,EAAAE,EAAAC,GACf,GAAAD,EAAA,CACA,qBAAAA,EAAA,OAAoCE,OAAAH,EAAA,KAAAG,CAAgBF,EAAAC,GACpD,IAAAE,EAAAD,OAAAE,UAAAC,SAAAC,KAAAN,GAAAO,MAAA,MAEA,MADA,WAAAJ,GAAAH,EAAAQ,cAAAL,EAAAH,EAAAQ,YAAAC,MACA,QAAAN,GAAA,QAAAA,EAAAO,MAAAC,KAAAX,GACA,cAAAG,GAAA,2CAAAS,KAAAT,GAAsFD,O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,KAAKkE,OAEpBA,EAAOqF,GAAGD,iBAAiB1B,IAA3B,aAAAgC,OAA8CrH,GAAW,SAAAI,GACxD,IAAMuI,EAAUhH,EAAOyD,SAASjI,IAAK,aAC/BoK,EAAa,IAAIqB,OAAYxI,GAmBnC,OAjBAmH,EAAW3I,KACV4I,MAAOkB,EAAKG,sBAAuB7I,GACnCsI,KAAMnC,EAAShJ,IAAK6C,GACpByH,SAAS,EACTqB,cAAc,IAIfvB,EAAW9K,KAAM,aAAcsM,GAAIJ,GACnCpB,EAAW9K,KAAM,QAASsM,GAAIJ,EAAS,QAAS,SAAAhP,GAAK,OAAIA,IAAUqG,IAGnE0I,EAAKM,SAAUzB,EAAY,UAAW,WACrC5F,EAAOsH,QAAS,aAAetP,MAAOqG,IACtC2B,EAAOuH,QAAQzD,KAAK0D,UAGd5B,8BA9FT,WACC,MAAO,qBA9BgCjC;;;;OCJpB8D,kKAIpB,WACC,OAASvF,EAAkB4C,2BAM5B,WACC,MAAO,mBAZ8BnB,2CCzBxB,SAAA+D,EAAA3M,EAAAH,GACf,KAAAG,aAAAH,GACA,UAAA9C,UAAA,qCAFAzB,EAAAC,EAAAC,EAAA,sBAAAmR","file":"js/chunk-3994d1a1.674cec00.js","sourcesContent":["import arrayLikeToArray from \"./arrayLikeToArray.js\";\nexport default function _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);\n}","export default function _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return self;\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n });\n if (superClass) setPrototypeOf(subClass, superClass);\n}","import arrayLikeToArray from \"./arrayLikeToArray.js\";\nexport default function _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return arrayLikeToArray(arr);\n}","export default function _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && iter[Symbol.iterator] != null || iter[\"@@iterator\"] != null) return Array.from(iter);\n}","export default function _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","import arrayWithoutHoles from \"./arrayWithoutHoles.js\";\nimport iterableToArray from \"./iterableToArray.js\";\nimport unsupportedIterableToArray from \"./unsupportedIterableToArray.js\";\nimport nonIterableSpread from \"./nonIterableSpread.js\";\nexport default function _toConsumableArray(arr) {\n return arrayWithoutHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableSpread();\n}","export default function _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n}","export default function _iterableToArrayLimit(arr, i) {\n var _i = arr == null ? null : typeof Symbol !== \"undefined\" && arr[Symbol.iterator] || arr[\"@@iterator\"];\n\n if (_i == null) return;\n var _arr = [];\n var _n = true;\n var _d = false;\n\n var _s, _e;\n\n try {\n for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {\n _arr.push(_s.value);\n\n if (i && _arr.length === i) break;\n }\n } catch (err) {\n _d = true;\n _e = err;\n } finally {\n try {\n if (!_n && _i[\"return\"] != null) _i[\"return\"]();\n } finally {\n if (_d) throw _e;\n }\n }\n\n return _arr;\n}","export default function _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","import arrayWithHoles from \"./arrayWithHoles.js\";\nimport iterableToArrayLimit from \"./iterableToArrayLimit.js\";\nimport unsupportedIterableToArray from \"./unsupportedIterableToArray.js\";\nimport nonIterableRest from \"./nonIterableRest.js\";\nexport default function _slicedToArray(arr, i) {\n return arrayWithHoles(arr) || iterableToArrayLimit(arr, i) || unsupportedIterableToArray(arr, i) || nonIterableRest();\n}","export default function _isNativeReflectConstruct() {\n if (typeof Reflect === \"undefined\" || !Reflect.construct) return false;\n if (Reflect.construct.sham) return false;\n if (typeof Proxy === \"function\") return true;\n\n try {\n Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));\n return true;\n } catch (e) {\n return false;\n }\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nimport isNativeReflectConstruct from \"./isNativeReflectConstruct.js\";\nexport default function _construct(Parent, args, Class) {\n if (isNativeReflectConstruct()) {\n _construct = Reflect.construct;\n } else {\n _construct = function _construct(Parent, args, Class) {\n var a = [null];\n a.push.apply(a, args);\n var Constructor = Function.bind.apply(Parent, a);\n var instance = new Constructor();\n if (Class) setPrototypeOf(instance, Class.prototype);\n return instance;\n };\n }\n\n return _construct.apply(null, arguments);\n}","import getPrototypeOf from \"./getPrototypeOf.js\";\nexport default function _superPropBase(object, property) {\n while (!Object.prototype.hasOwnProperty.call(object, property)) {\n object = getPrototypeOf(object);\n if (object === null) break;\n }\n\n return object;\n}","import superPropBase from \"./superPropBase.js\";\nexport default function _get() {\n if (typeof Reflect !== \"undefined\" && Reflect.get) {\n _get = Reflect.get;\n } else {\n _get = function _get(target, property, receiver) {\n var base = superPropBase(target, property);\n if (!base) return;\n var desc = Object.getOwnPropertyDescriptor(base, property);\n\n if (desc.get) {\n return desc.get.call(arguments.length < 3 ? target : receiver);\n }\n\n return desc.value;\n };\n }\n\n return _get.apply(this, arguments);\n}","export default function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n _typeof = function _typeof(obj) {\n return typeof obj;\n };\n } else {\n _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}","export default function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}","function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n module.exports = _typeof = function _typeof(obj) {\n return typeof obj;\n };\n\n module.exports[\"default\"] = module.exports, module.exports.__esModule = true;\n } else {\n module.exports = _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n\n module.exports[\"default\"] = module.exports, module.exports.__esModule = true;\n }\n\n return _typeof(obj);\n}\n\nmodule.exports = _typeof;\nmodule.exports[\"default\"] = module.exports, module.exports.__esModule = true;","export default function _getPrototypeOf(o) {\n _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return _getPrototypeOf(o);\n}","export default function _isNativeFunction(fn) {\n return Function.toString.call(fn).indexOf(\"[native code]\") !== -1;\n}","import getPrototypeOf from \"./getPrototypeOf.js\";\nimport setPrototypeOf from \"./setPrototypeOf.js\";\nimport isNativeFunction from \"./isNativeFunction.js\";\nimport construct from \"./construct.js\";\nexport default function _wrapNativeSuper(Class) {\n var _cache = typeof Map === \"function\" ? new Map() : undefined;\n\n _wrapNativeSuper = function _wrapNativeSuper(Class) {\n if (Class === null || !isNativeFunction(Class)) return Class;\n\n if (typeof Class !== \"function\") {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n if (typeof _cache !== \"undefined\") {\n if (_cache.has(Class)) return _cache.get(Class);\n\n _cache.set(Class, Wrapper);\n }\n\n function Wrapper() {\n return construct(Class, arguments, getPrototypeOf(this).constructor);\n }\n\n Wrapper.prototype = Object.create(Class.prototype, {\n constructor: {\n value: Wrapper,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n return setPrototypeOf(Wrapper, Class);\n };\n\n return _wrapNativeSuper(Class);\n}","import _typeof from \"@babel/runtime/helpers/typeof\";\nimport assertThisInitialized from \"./assertThisInitialized.js\";\nexport default function _possibleConstructorReturn(self, call) {\n if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) {\n return call;\n } else if (call !== void 0) {\n throw new TypeError(\"Derived constructors may only return object or undefined\");\n }\n\n return assertThisInitialized(self);\n}","export default function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n\n return _setPrototypeOf(o, p);\n}","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nexport default function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}","/**\n * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\nimport { CKEditorError, logWarning } from 'ckeditor5/src/utils';\n\n/**\n * @module alignment/utils\n */\n\n/**\n * The list of supported alignment options:\n *\n * * `'left'`,\n * * `'right'`,\n * * `'center'`,\n * * `'justify'`\n */\nexport const supportedOptions = [ 'left', 'right', 'center', 'justify' ];\n\n/**\n * Checks whether the passed option is supported by {@link module:alignment/alignmentediting~AlignmentEditing}.\n *\n * @param {String} option The option value to check.\n * @returns {Boolean}\n */\nexport function isSupported( option ) {\n\treturn supportedOptions.includes( option );\n}\n\n/**\n * Checks whether alignment is the default one considering the direction\n * of the editor content.\n *\n * @param {String} alignment The name of the alignment to check.\n * @param {module:utils/locale~Locale} locale The {@link module:core/editor/editor~Editor#locale} instance.\n * @returns {Boolean}\n */\nexport function isDefault( alignment, locale ) {\n\t// Right now only LTR is supported so the 'left' value is always the default one.\n\n\tif ( locale.contentLanguageDirection == 'rtl' ) {\n\t\treturn alignment === 'right';\n\t} else {\n\t\treturn alignment === 'left';\n\t}\n}\n\n/**\n * Brings the configuration to the common form, an array of objects.\n *\n * @param {Array.} configuredOptions Alignment plugin configuration.\n * @returns {Array.} Normalized object holding the configuration.\n */\nexport function normalizeAlignmentOptions( configuredOptions ) {\n\tconst normalizedOptions = configuredOptions\n\t\t.map( option => {\n\t\t\tlet result;\n\n\t\t\tif ( typeof option == 'string' ) {\n\t\t\t\tresult = { name: option };\n\t\t\t} else {\n\t\t\t\tresult = option;\n\t\t\t}\n\n\t\t\treturn result;\n\t\t} )\n\t\t// Remove all unknown options.\n\t\t.filter( option => {\n\t\t\tconst isNameValid = !!supportedOptions.includes( option.name );\n\t\t\tif ( !isNameValid ) {\n\t\t\t\t/**\n\t\t\t\t * The `name` in one of the `alignment.options` is not recognized.\n\t\t\t\t * The available options are: `'left'`, `'right'`, `'center'` and `'justify'`.\n\t\t\t\t *\n\t\t\t\t * @error alignment-config-name-not-recognized\n\t\t\t\t * @param {Object} option Options with unknown value of the `name` property.\n\t\t\t\t */\n\t\t\t\tlogWarning( 'alignment-config-name-not-recognized', { option } );\n\t\t\t}\n\n\t\t\treturn isNameValid;\n\t\t} );\n\n\tconst classNameCount = normalizedOptions.filter( option => !!option.className ).length;\n\n\t// We either use classes for all styling options or for none.\n\tif ( classNameCount && classNameCount < normalizedOptions.length ) {\n\t\t/**\n\t\t * The `className` property has to be defined for all options once at least one option declares `className`.\n\t\t *\n\t\t * @error alignment-config-classnames-are-missing\n\t\t * @param {Array.} configuredOptions Contents of `alignment.options`.\n\t\t */\n\t\tthrow new CKEditorError( 'alignment-config-classnames-are-missing', { configuredOptions } );\n\t}\n\n\t// Validate resulting config.\n\tnormalizedOptions.forEach( ( option, index, allOptions ) => {\n\t\tconst succeedingOptions = allOptions.slice( index + 1 );\n\t\tconst nameAlreadyExists = succeedingOptions.some( item => item.name == option.name );\n\n\t\tif ( nameAlreadyExists ) {\n\t\t\t/**\n\t\t\t * The same `name` in one of the `alignment.options` was already declared.\n\t\t\t * Each `name` representing one alignment option can be set exactly once.\n\t\t\t *\n\t\t\t * @error alignment-config-name-already-defined\n\t\t\t * @param {Object} option First option that declares given `name`.\n\t\t\t * @param {Array.} configuredOptions Contents of `alignment.options`.\n\t\t\t */\n\t\t\tthrow new CKEditorError( 'alignment-config-name-already-defined', { option, configuredOptions } );\n\t\t}\n\n\t\t// The `className` property is present. Check for duplicates then.\n\t\tif ( option.className ) {\n\t\t\tconst classNameAlreadyExists = succeedingOptions.some( item => item.className == option.className );\n\n\t\t\tif ( classNameAlreadyExists ) {\n\t\t\t\t/**\n\t\t\t\t * The same `className` in one of the `alignment.options` was already declared.\n\t\t\t\t *\n\t\t\t\t * @error alignment-config-classname-already-defined\n\t\t\t\t * @param {Object} option First option that declares given `className`.\n\t\t\t\t * @param {Array.} configuredOptions\n\t\t\t\t * Contents of `alignment.options`.\n\t\t\t\t */\n\t\t\t\tthrow new CKEditorError( 'alignment-config-classname-already-defined', { option, configuredOptions } );\n\t\t\t}\n\t\t}\n\t} );\n\n\treturn normalizedOptions;\n}\n","/**\n * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * @module alignment/alignmentcommand\n */\n\nimport { Command } from 'ckeditor5/src/core';\nimport { first } from 'ckeditor5/src/utils';\n\nimport { isDefault } from './utils';\n\nconst ALIGNMENT = 'alignment';\n\n/**\n * The alignment command plugin.\n *\n * @extends module:core/command~Command\n */\nexport default class AlignmentCommand extends Command {\n\t/**\n\t * @inheritDoc\n\t */\n\trefresh() {\n\t\tconst editor = this.editor;\n\t\tconst locale = editor.locale;\n\t\tconst firstBlock = first( this.editor.model.document.selection.getSelectedBlocks() );\n\n\t\t// As first check whether to enable or disable the command as the value will always be false if the command cannot be enabled.\n\t\tthis.isEnabled = !!firstBlock && this._canBeAligned( firstBlock );\n\n\t\t/**\n\t\t * A value of the current block's alignment.\n\t\t *\n\t\t * @observable\n\t\t * @readonly\n\t\t * @member {String} #value\n\t\t */\n\t\tif ( this.isEnabled && firstBlock.hasAttribute( 'alignment' ) ) {\n\t\t\tthis.value = firstBlock.getAttribute( 'alignment' );\n\t\t} else {\n\t\t\tthis.value = locale.contentLanguageDirection === 'rtl' ? 'right' : 'left';\n\t\t}\n\t}\n\n\t/**\n\t * Executes the command. Applies the alignment `value` to the selected blocks.\n\t * If no `value` is passed, the `value` is the default one or it is equal to the currently selected block's alignment attribute,\n\t * the command will remove the attribute from the selected blocks.\n\t *\n\t * @param {Object} [options] Options for the executed command.\n\t * @param {String} [options.value] The value to apply.\n\t * @fires execute\n\t */\n\texecute( options = {} ) {\n\t\tconst editor = this.editor;\n\t\tconst locale = editor.locale;\n\t\tconst model = editor.model;\n\t\tconst doc = model.document;\n\n\t\tconst value = options.value;\n\n\t\tmodel.change( writer => {\n\t\t\t// Get only those blocks from selected that can have alignment set\n\t\t\tconst blocks = Array.from( doc.selection.getSelectedBlocks() ).filter( block => this._canBeAligned( block ) );\n\t\t\tconst currentAlignment = blocks[ 0 ].getAttribute( 'alignment' );\n\n\t\t\t// Remove alignment attribute if current alignment is:\n\t\t\t// - default (should not be stored in model as it will bloat model data)\n\t\t\t// - equal to currently set\n\t\t\t// - or no value is passed - denotes default alignment.\n\t\t\tconst removeAlignment = isDefault( value, locale ) || currentAlignment === value || !value;\n\n\t\t\tif ( removeAlignment ) {\n\t\t\t\tremoveAlignmentFromSelection( blocks, writer );\n\t\t\t} else {\n\t\t\t\tsetAlignmentOnSelection( blocks, writer, value );\n\t\t\t}\n\t\t} );\n\t}\n\n\t/**\n\t * Checks whether a block can have alignment set.\n\t *\n\t * @private\n\t * @param {module:engine/model/element~Element} block The block to be checked.\n\t * @returns {Boolean}\n\t */\n\t_canBeAligned( block ) {\n\t\treturn this.editor.model.schema.checkAttribute( block, ALIGNMENT );\n\t}\n}\n\n// Removes the alignment attribute from blocks.\n// @private\nfunction removeAlignmentFromSelection( blocks, writer ) {\n\tfor ( const block of blocks ) {\n\t\twriter.removeAttribute( ALIGNMENT, block );\n\t}\n}\n\n// Sets the alignment attribute on blocks.\n// @private\nfunction setAlignmentOnSelection( blocks, writer, alignment ) {\n\tfor ( const block of blocks ) {\n\t\twriter.setAttribute( ALIGNMENT, alignment, block );\n\t}\n}\n","/**\n * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * @module alignment/alignmentediting\n */\n\nimport { Plugin } from 'ckeditor5/src/core';\n\nimport AlignmentCommand from './alignmentcommand';\nimport { isDefault, isSupported, normalizeAlignmentOptions, supportedOptions } from './utils';\n\n/**\n * The alignment editing feature. It introduces the {@link module:alignment/alignmentcommand~AlignmentCommand command} and adds\n * the `alignment` attribute for block elements in the {@link module:engine/model/model~Model model}.\n * @extends module:core/plugin~Plugin\n */\nexport default class AlignmentEditing extends Plugin {\n\t/**\n\t * @inheritDoc\n\t */\n\tstatic get pluginName() {\n\t\treturn 'AlignmentEditing';\n\t}\n\n\t/**\n\t * @inheritDoc\n\t */\n\tconstructor( editor ) {\n\t\tsuper( editor );\n\n\t\teditor.config.define( 'alignment', {\n\t\t\toptions: [ ...supportedOptions.map( option => ( { name: option } ) ) ]\n\t\t} );\n\t}\n\n\t/**\n\t * @inheritDoc\n\t */\n\tinit() {\n\t\tconst editor = this.editor;\n\t\tconst locale = editor.locale;\n\t\tconst schema = editor.model.schema;\n\n\t\tconst options = normalizeAlignmentOptions( editor.config.get( 'alignment.options' ) );\n\n\t\t// Filter out unsupported options and those that are redundant, e.g. `left` in LTR / `right` in RTL mode.\n\t\tconst optionsToConvert = options.filter(\n\t\t\toption => isSupported( option.name ) && !isDefault( option.name, locale )\n\t\t);\n\n\t\t// Once there is at least one `className` defined, we switch to alignment with classes.\n\t\tconst shouldUseClasses = optionsToConvert.some( option => !!option.className );\n\n\t\t// Allow alignment attribute on all blocks.\n\t\tschema.extend( '$block', { allowAttributes: 'alignment' } );\n\t\teditor.model.schema.setAttributeProperties( 'alignment', { isFormatting: true } );\n\n\t\tif ( shouldUseClasses ) {\n\t\t\teditor.conversion.attributeToAttribute( buildClassDefinition( optionsToConvert ) );\n\t\t} else {\n\t\t\t// Downcast inline styles.\n\t\t\teditor.conversion.for( 'downcast' ).attributeToAttribute( buildDowncastInlineDefinition( optionsToConvert ) );\n\t\t}\n\n\t\tconst upcastInlineDefinitions = buildUpcastInlineDefinitions( optionsToConvert );\n\n\t\t// Always upcast from inline styles.\n\t\tfor ( const definition of upcastInlineDefinitions ) {\n\t\t\teditor.conversion.for( 'upcast' ).attributeToAttribute( definition );\n\t\t}\n\n\t\tconst upcastCompatibilityDefinitions = buildUpcastCompatibilityDefinitions( optionsToConvert );\n\n\t\t// Always upcast from deprecated `align` attribute.\n\t\tfor ( const definition of upcastCompatibilityDefinitions ) {\n\t\t\teditor.conversion.for( 'upcast' ).attributeToAttribute( definition );\n\t\t}\n\n\t\teditor.commands.add( 'alignment', new AlignmentCommand( editor ) );\n\t}\n}\n\n// Prepare downcast conversion definition for inline alignment styling.\n// @private\nfunction buildDowncastInlineDefinition( options ) {\n\tconst definition = {\n\t\tmodel: {\n\t\t\tkey: 'alignment',\n\t\t\tvalues: options.map( option => option.name )\n\t\t},\n\t\tview: {}\n\t};\n\n\tfor ( const { name } of options ) {\n\t\tdefinition.view[ name ] = {\n\t\t\tkey: 'style',\n\t\t\tvalue: {\n\t\t\t\t'text-align': name\n\t\t\t}\n\t\t};\n\t}\n\n\treturn definition;\n}\n\n// Prepare upcast definitions for inline alignment styles.\n// @private\nfunction buildUpcastInlineDefinitions( options ) {\n\tconst definitions = [];\n\n\tfor ( const { name } of options ) {\n\t\tdefinitions.push( {\n\t\t\tview: {\n\t\t\t\tkey: 'style',\n\t\t\t\tvalue: {\n\t\t\t\t\t'text-align': name\n\t\t\t\t}\n\t\t\t},\n\t\t\tmodel: {\n\t\t\t\tkey: 'alignment',\n\t\t\t\tvalue: name\n\t\t\t}\n\t\t} );\n\t}\n\n\treturn definitions;\n}\n\n// Prepare upcast definitions for deprecated `align` attribute.\n// @private\nfunction buildUpcastCompatibilityDefinitions( options ) {\n\tconst definitions = [];\n\n\tfor ( const { name } of options ) {\n\t\tdefinitions.push( {\n\t\t\tview: {\n\t\t\t\tkey: 'align',\n\t\t\t\tvalue: name\n\t\t\t},\n\t\t\tmodel: {\n\t\t\t\tkey: 'alignment',\n\t\t\t\tvalue: name\n\t\t\t}\n\t\t} );\n\t}\n\n\treturn definitions;\n}\n\n// Prepare conversion definitions for upcast and downcast alignment with classes.\n// @private\nfunction buildClassDefinition( options ) {\n\tconst definition = {\n\t\tmodel: {\n\t\t\tkey: 'alignment',\n\t\t\tvalues: options.map( option => option.name )\n\t\t},\n\t\tview: {}\n\t};\n\n\tfor ( const option of options ) {\n\t\tdefinition.view[ option.name ] = {\n\t\t\tkey: 'class',\n\t\t\tvalue: option.className\n\t\t};\n\t}\n\n\treturn definition;\n}\n\n/**\n * The alignment configuration format descriptor.\n *\n *\t\tconst alignmentFormat = {\n *\t\t\tname: 'right',\n *\t\t\tclassName: 'my-align-right-class'\n *\t\t}\n *\n * @typedef {Object} module:alignment/alignmentediting~AlignmentFormat\n *\n * @property {'left'|'right'|'center'|'justify'} name One of the alignment names options.\n *\n * @property {String} className The CSS class used to represent the style in the view.\n * Used to override default, inline styling for alignment.\n */\n","/**\n * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * @module alignment/alignmentui\n */\n\nimport { Plugin, icons } from 'ckeditor5/src/core';\nimport { ButtonView, createDropdown, addToolbarToDropdown } from 'ckeditor5/src/ui';\n\nimport { isSupported, normalizeAlignmentOptions } from './utils';\n\nconst iconsMap = new Map( [\n\t[ 'left', icons.alignLeft ],\n\t[ 'right', icons.alignRight ],\n\t[ 'center', icons.alignCenter ],\n\t[ 'justify', icons.alignJustify ]\n] );\n\n/**\n * The default alignment UI plugin.\n *\n * It introduces the `'alignment:left'`, `'alignment:right'`, `'alignment:center'` and `'alignment:justify'` buttons\n * and the `'alignment'` dropdown.\n *\n * @extends module:core/plugin~Plugin\n */\nexport default class AlignmentUI extends Plugin {\n\t/**\n\t * Returns the localized option titles provided by the plugin.\n\t *\n\t * The following localized titles corresponding with\n\t * {@link module:alignment/alignment~AlignmentConfig#options} are available:\n\t *\n\t * * `'left'`,\n\t * * `'right'`,\n\t * * `'center'`,\n\t * * `'justify'`.\n\t *\n\t * @readonly\n\t * @type {Object.}\n\t */\n\tget localizedOptionTitles() {\n\t\tconst t = this.editor.t;\n\n\t\treturn {\n\t\t\t'left': t( 'Align left' ),\n\t\t\t'right': t( 'Align right' ),\n\t\t\t'center': t( 'Align center' ),\n\t\t\t'justify': t( 'Justify' )\n\t\t};\n\t}\n\n\t/**\n\t * @inheritDoc\n\t */\n\tstatic get pluginName() {\n\t\treturn 'AlignmentUI';\n\t}\n\n\t/**\n\t * @inheritDoc\n\t */\n\tinit() {\n\t\tconst editor = this.editor;\n\t\tconst componentFactory = editor.ui.componentFactory;\n\t\tconst t = editor.t;\n\t\tconst options = normalizeAlignmentOptions( editor.config.get( 'alignment.options' ) );\n\n\t\toptions\n\t\t\t.map( option => option.name )\n\t\t\t.filter( isSupported )\n\t\t\t.forEach( option => this._addButton( option ) );\n\n\t\tcomponentFactory.add( 'alignment', locale => {\n\t\t\tconst dropdownView = createDropdown( locale );\n\n\t\t\t// Add existing alignment buttons to dropdown's toolbar.\n\t\t\tconst buttons = options.map( option => componentFactory.create( `alignment:${ option.name }` ) );\n\t\t\taddToolbarToDropdown( dropdownView, buttons );\n\n\t\t\t// Configure dropdown properties an behavior.\n\t\t\tdropdownView.buttonView.set( {\n\t\t\t\tlabel: t( 'Text alignment' ),\n\t\t\t\ttooltip: true\n\t\t\t} );\n\n\t\t\tdropdownView.toolbarView.isVertical = true;\n\t\t\tdropdownView.toolbarView.ariaLabel = t( 'Text alignment toolbar' );\n\n\t\t\tdropdownView.extendTemplate( {\n\t\t\t\tattributes: {\n\t\t\t\t\tclass: 'ck-alignment-dropdown'\n\t\t\t\t}\n\t\t\t} );\n\n\t\t\t// The default icon depends on the direction of the content.\n\t\t\tconst defaultIcon = locale.contentLanguageDirection === 'rtl' ? iconsMap.get( 'right' ) : iconsMap.get( 'left' );\n\n\t\t\t// Change icon to reflect current selection's alignment.\n\t\t\tdropdownView.buttonView.bind( 'icon' ).toMany( buttons, 'isOn', ( ...areActive ) => {\n\t\t\t\t// Get the index of an active button.\n\t\t\t\tconst index = areActive.findIndex( value => value );\n\n\t\t\t\t// If none of the commands is active, display either defaultIcon or the first button's icon.\n\t\t\t\tif ( index < 0 ) {\n\t\t\t\t\treturn defaultIcon;\n\t\t\t\t}\n\n\t\t\t\t// Return active button's icon.\n\t\t\t\treturn buttons[ index ].icon;\n\t\t\t} );\n\n\t\t\t// Enable button if any of the buttons is enabled.\n\t\t\tdropdownView.bind( 'isEnabled' ).toMany( buttons, 'isEnabled', ( ...areEnabled ) => areEnabled.some( isEnabled => isEnabled ) );\n\n\t\t\treturn dropdownView;\n\t\t} );\n\t}\n\n\t/**\n\t * Helper method for initializing the button and linking it with an appropriate command.\n\t *\n\t * @private\n\t * @param {String} option The name of the alignment option for which the button is added.\n\t */\n\t_addButton( option ) {\n\t\tconst editor = this.editor;\n\n\t\teditor.ui.componentFactory.add( `alignment:${ option }`, locale => {\n\t\t\tconst command = editor.commands.get( 'alignment' );\n\t\t\tconst buttonView = new ButtonView( locale );\n\n\t\t\tbuttonView.set( {\n\t\t\t\tlabel: this.localizedOptionTitles[ option ],\n\t\t\t\ticon: iconsMap.get( option ),\n\t\t\t\ttooltip: true,\n\t\t\t\tisToggleable: true\n\t\t\t} );\n\n\t\t\t// Bind button model to command.\n\t\t\tbuttonView.bind( 'isEnabled' ).to( command );\n\t\t\tbuttonView.bind( 'isOn' ).to( command, 'value', value => value === option );\n\n\t\t\t// Execute command.\n\t\t\tthis.listenTo( buttonView, 'execute', () => {\n\t\t\t\teditor.execute( 'alignment', { value: option } );\n\t\t\t\teditor.editing.view.focus();\n\t\t\t} );\n\n\t\t\treturn buttonView;\n\t\t} );\n\t}\n}\n","/**\n * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * @module alignment/alignment\n */\n\nimport { Plugin } from 'ckeditor5/src/core';\n\nimport AlignmentEditing from './alignmentediting';\nimport AlignmentUI from './alignmentui';\n\n/**\n * The text alignment plugin.\n *\n * For a detailed overview, check the {@glink features/text-alignment Text alignment feature documentation}\n * and the {@glink api/alignment package page}.\n *\n * This is a \"glue\" plugin which loads the {@link module:alignment/alignmentediting~AlignmentEditing} and\n * {@link module:alignment/alignmentui~AlignmentUI} plugins.\n *\n * @extends module:core/plugin~Plugin\n */\nexport default class Alignment extends Plugin {\n\t/**\n\t * @inheritDoc\n\t */\n\tstatic get requires() {\n\t\treturn [ AlignmentEditing, AlignmentUI ];\n\t}\n\n\t/**\n\t * @inheritDoc\n\t */\n\tstatic get pluginName() {\n\t\treturn 'Alignment';\n\t}\n}\n\n/**\n * The configuration of the {@link module:alignment/alignment~Alignment alignment feature}.\n *\n * Read more in {@link module:alignment/alignment~AlignmentConfig}.\n *\n * @member {module:alignment/alignment~AlignmentConfig} module:core/editor/editorconfig~EditorConfig#alignment\n */\n\n/**\n * The configuration of the {@link module:alignment/alignment~Alignment alignment feature}.\n *\n *\t\tClassicEditor\n *\t\t\t.create( editorElement, {\n *\t\t\t\talignment: {\n *\t\t\t\t\toptions: [ 'left', 'right' ]\n *\t\t\t\t}\n *\t\t\t} )\n *\t\t\t.then( ... )\n *\t\t\t.catch( ... );\n *\n * See {@link module:core/editor/editorconfig~EditorConfig all editor configuration options}.\n *\n * @interface AlignmentConfig\n */\n\n/**\n * Available alignment options.\n *\n * The available options are: `'left'`, `'right'`, `'center'` and `'justify'`. Other values are ignored.\n *\n * **Note:** It is recommended to always use `'left'` or `'right'` as these are default values which the user should\n * normally be able to choose depending on the\n * {@glink features/ui-language#setting-the-language-of-the-content language of the editor content}.\n *\n *\t\tClassicEditor\n *\t\t\t.create( editorElement, {\n *\t\t\t\talignment: {\n *\t\t\t\t\toptions: [ 'left', 'right' ]\n *\t\t\t\t}\n *\t\t\t} )\n *\t\t\t.then( ... )\n *\t\t\t.catch( ... );\n *\n * By default the alignment is set inline using the `text-align` CSS property. To further customize the alignment,\n * you can provide names of classes for each alignment option using the `className` property.\n *\n * **Note:** Once you define the `className` property for one option, you need to specify it for all other options.\n *\n *\t\tClassicEditor\n *\t\t\t.create( editorElement, {\n *\t\t\t\talignment: {\n *\t\t\t\t\toptions: [\n *\t\t\t\t\t\t{ name: 'left', className: 'my-align-left' },\n *\t\t\t\t\t\t{ name: 'right', className: 'my-align-right' }\n *\t\t\t\t\t]\n *\t\t\t\t}\n *\t\t\t} )\n *\t\t\t.then( ... )\n *\t\t\t.catch( ... );\n *\n * See the demo of {@glink features/text-alignment#configuring-alignment-options custom alignment options}.\n *\n * @member {Array.} module:alignment/alignment~AlignmentConfig#options\n */\n","export default function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}"],"sourceRoot":""}