diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index 878af2a2d746..3db90e894c39 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -250,7 +250,7 @@ jobs: - name: Merge digests uses: actions/upload-artifact/merge@v4 with: - pattern: digests-* + pattern: "digests-${{ matrix.target }}-*" overwrite: true name: "merged-digests-${{ matrix.target }}-${{ github.run_number }}-${{ github.run_attempt }}" - name: Download digests diff --git a/Gemfile.lock b/Gemfile.lock index a36a253284ec..8aca7e282b26 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -342,8 +342,8 @@ GEM activerecord (>= 4.0.0, < 7.2) awrence (1.2.1) aws-eventstream (1.3.0) - aws-partitions (1.966.0) - aws-sdk-core (3.201.5) + aws-partitions (1.969.0) + aws-sdk-core (3.202.1) aws-eventstream (~> 1, >= 1.3.0) aws-partitions (~> 1, >= 1.651.0) aws-sigv4 (~> 1.9) @@ -560,7 +560,8 @@ GEM websocket-driver (~> 0.7) ffi (1.17.0) flamegraph (0.9.5) - fog-aws (3.24.0) + fog-aws (3.25.0) + base64 (~> 0.2.0) fog-core (~> 2.1) fog-json (~> 1.1) fog-xml (~> 0.1) @@ -748,7 +749,7 @@ GEM method_source (1.1.0) mime-types (3.5.2) mime-types-data (~> 3.2015) - mime-types-data (3.2024.0806) + mime-types-data (3.2024.0820) mini_magick (5.0.1) mini_mime (1.1.5) mini_portile2 (2.8.7) @@ -1054,9 +1055,9 @@ GEM crass (~> 1.0.2) nokogiri (>= 1.12.0) secure_headers (6.5.0) - selenium-devtools (0.127.0) + selenium-devtools (0.128.0) selenium-webdriver (~> 4.2) - selenium-webdriver (4.23.0) + selenium-webdriver (4.24.0) base64 (~> 0.2) logger (~> 1.4) rexml (~> 3.2, >= 3.2.5) @@ -1143,7 +1144,7 @@ GEM public_suffix vcr (6.3.1) base64 - view_component (3.13.0) + view_component (3.14.0) activesupport (>= 5.2.0, < 8.0) concurrent-ruby (~> 1.0) method_source (~> 1.0) diff --git a/app/assets/images/enterprise/attribute-help-texts.png b/app/assets/images/enterprise/attribute-help-texts.png deleted file mode 100644 index 58fa216c7a9d..000000000000 Binary files a/app/assets/images/enterprise/attribute-help-texts.png and /dev/null differ diff --git a/app/components/admin/backups/show_page_header_component.html.erb b/app/components/admin/backups/show_page_header_component.html.erb new file mode 100644 index 000000000000..4b1ddcd8bca8 --- /dev/null +++ b/app/components/admin/backups/show_page_header_component.html.erb @@ -0,0 +1,65 @@ +<%#-- copyright +OpenProject is an open source project management software. +Copyright (C) the OpenProject GmbH + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License version 3. + +OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows: +Copyright (C) 2006-2013 Jean-Philippe Lang +Copyright (C) 2010-2013 the ChiliProject Team + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + +See COPYRIGHT and LICENSE files for more details. + +++#%> +<%= + render(Primer::OpenProject::PageHeader.new) do |header| + header.with_title { t(:label_backup) } + header.with_breadcrumbs([{ href: admin_index_path, text: t(:label_administration) }, + t(:label_backup)]) + + header.with_action_button(tag: :a, + scheme: button_scheme, + mobile_label: button_title, + mobile_icon: button_icon, + size: :medium, + href: reset_token_admin_backups_path, + aria: { label: button_title }, + title: button_title) do |button| + button.with_leading_visual_icon(icon: button_icon) + button_title + end + + if @backup_token.present? + header.with_action_button(tag: :a, + scheme: :danger, + mobile_icon: :trash, + mobile_label: t("backup.label_delete_token"), + size: :medium, + href: delete_token_admin_backups_path, + aria: { label: I18n.t("backup.label_delete_token") }, + data: { + confirm: I18n.t(:text_are_you_sure), + method: :post + }, + title: I18n.t(:button_delete)) do |button| + button.with_leading_visual_icon(icon: :trash) + t("backup.label_delete_token") + end + end + end +%> diff --git a/app/components/admin/backups/show_page_header_component.rb b/app/components/admin/backups/show_page_header_component.rb new file mode 100644 index 000000000000..3b7dc6f70b90 --- /dev/null +++ b/app/components/admin/backups/show_page_header_component.rb @@ -0,0 +1,61 @@ +# frozen_string_literal: true + +# -- copyright +# OpenProject is an open source project management software. +# Copyright (C) the OpenProject GmbH +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License version 3. +# +# OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows: +# Copyright (C) 2006-2013 Jean-Philippe Lang +# Copyright (C) 2010-2013 the ChiliProject Team +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# +# See COPYRIGHT and LICENSE files for more details. +# ++ + +module Admin + module Backups + class ShowPageHeaderComponent < ApplicationComponent + include OpPrimer::ComponentHelpers + include ApplicationHelper + + def initialize(backup_token:) + super + @backup_token = backup_token + end + + def breadcrumb_items + [{ href: admin_index_path, text: t(:label_administration) }, + t(:label_backup)] + end + + def button_title + button_action = @backup_token.present? ? "reset" : "create" + t("backup.label_#{button_action}_token") + end + + def button_icon + @backup_token.present? ? :"op-reload" : :plus + end + + def button_scheme + @backup_token.present? ? :default : :primary + end + end + end +end diff --git a/app/views/attribute_help_texts/upsale.html.erb b/app/components/attribute_help_texts/index_page_header_component.html.erb similarity index 70% rename from app/views/attribute_help_texts/upsale.html.erb rename to app/components/attribute_help_texts/index_page_header_component.html.erb index bba919c1ee1a..602390526de0 100644 --- a/app/views/attribute_help_texts/upsale.html.erb +++ b/app/components/attribute_help_texts/index_page_header_component.html.erb @@ -26,13 +26,17 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. See COPYRIGHT and LICENSE files for more details. ++#%> - -<% html_title t(:label_administration), t(:'attribute_help_texts.label_plural') %> - -<%= render template: 'common/upsale', - locals: { - feature_title: t(:'attribute_help_texts.label_plural'), - feature_description: t('attribute_help_texts.enterprise.description'), - feature_reference: 'enterprise-attribute-help-texts', - feature_image: 'enterprise/attribute-help-texts.png' - } %> +<%= + render(Primer::OpenProject::PageHeader.new) do |header| + header.with_title { I18n.t(:"attribute_help_texts.label_plural") } + header.with_breadcrumbs(breadcrumb_items, selected_item_font_weight: :normal) + + header.with_tab_nav(label: nil) do |tab_nav| + @tabs.each do |tab| + tab_nav.with_tab(selected: currently_selected_tab == tab, href: tab[:path]) do |t| + t.with_text { I18n.t(tab[:label]) } + end + end + end if @tabs.present? + end +%> diff --git a/app/components/attribute_help_texts/index_page_header_component.rb b/app/components/attribute_help_texts/index_page_header_component.rb new file mode 100644 index 000000000000..0e0637a472e1 --- /dev/null +++ b/app/components/attribute_help_texts/index_page_header_component.rb @@ -0,0 +1,50 @@ +# frozen_string_literal: true + +# -- copyright +# OpenProject is an open source project management software. +# Copyright (C) the OpenProject GmbH +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License version 3. +# +# OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows: +# Copyright (C) 2006-2013 Jean-Philippe Lang +# Copyright (C) 2010-2013 the ChiliProject Team +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# +# See COPYRIGHT and LICENSE files for more details. +# ++ + +class AttributeHelpTexts::IndexPageHeaderComponent < ApplicationComponent + include OpPrimer::ComponentHelpers + include ApplicationHelper + include TabsHelper + + def initialize(tabs: nil) + super + @tabs = tabs + end + + def breadcrumb_items + [{ href: admin_index_path, text: t("label_administration") }, + I18n.t("menus.breadcrumb.nested_element", section_header: t(:"attribute_help_texts.label_plural"), + title: I18n.t(currently_selected_tab[:label].to_s)).html_safe] + end + + def currently_selected_tab + @currently_selected_tab ||= selected_tab(@tabs) + end +end diff --git a/app/components/custom_fields/index_page_header_component.html.erb b/app/components/custom_fields/index_page_header_component.html.erb new file mode 100644 index 000000000000..f91e3f13d795 --- /dev/null +++ b/app/components/custom_fields/index_page_header_component.html.erb @@ -0,0 +1,42 @@ +<%#-- copyright +OpenProject is an open source project management software. +Copyright (C) the OpenProject GmbH + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License version 3. + +OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows: +Copyright (C) 2006-2013 Jean-Philippe Lang +Copyright (C) 2010-2013 the ChiliProject Team + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + +See COPYRIGHT and LICENSE files for more details. + +++#%> +<%= + render(Primer::OpenProject::PageHeader.new) do |header| + header.with_title { I18n.t(:label_custom_field_plural) } + header.with_breadcrumbs(breadcrumb_items, selected_item_font_weight: :normal) + + header.with_tab_nav(label: nil, test_selector: "custom-fields--tab-nav") do |tab_nav| + @tabs.each do |tab| + tab_nav.with_tab(selected: currently_selected_tab == tab, href: tab[:path]) do |t| + t.with_text { I18n.t(tab[:label]) } + end + end + end if @tabs.present? + end +%> diff --git a/app/components/custom_fields/index_page_header_component.rb b/app/components/custom_fields/index_page_header_component.rb new file mode 100644 index 000000000000..bfefb5b22ec2 --- /dev/null +++ b/app/components/custom_fields/index_page_header_component.rb @@ -0,0 +1,50 @@ +# frozen_string_literal: true + +# -- copyright +# OpenProject is an open source project management software. +# Copyright (C) the OpenProject GmbH +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License version 3. +# +# OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows: +# Copyright (C) 2006-2013 Jean-Philippe Lang +# Copyright (C) 2010-2013 the ChiliProject Team +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# +# See COPYRIGHT and LICENSE files for more details. +# ++ + +class CustomFields::IndexPageHeaderComponent < ApplicationComponent + include OpPrimer::ComponentHelpers + include ApplicationHelper + include TabsHelper + + def initialize(tabs: nil) + super + @tabs = tabs + end + + def breadcrumb_items + [{ href: admin_index_path, text: t("label_administration") }, + I18n.t("menus.breadcrumb.nested_element", section_header: t(:label_custom_field_plural), + title: I18n.t(currently_selected_tab[:label].to_s)).html_safe] + end + + def currently_selected_tab + @currently_selected_tab ||= selected_tab(@tabs) + end +end diff --git a/app/components/projects/row_component.rb b/app/components/projects/row_component.rb index d7765f9d451a..813360e27a06 100644 --- a/app/components/projects/row_component.rb +++ b/app/components/projects/row_component.rb @@ -342,7 +342,8 @@ def more_menu_copy_item scheme: :default, icon: :copy, label: I18n.t(:button_copy), - href: copy_project_path(project) + href: copy_project_path(project), + data: { turbo: false } } end end diff --git a/app/components/work_packages/exports/column_selection_component.html.erb b/app/components/work_packages/exports/column_selection_component.html.erb index 3db7647073cd..738bef270c8d 100644 --- a/app/components/work_packages/exports/column_selection_component.html.erb +++ b/app/components/work_packages/exports/column_selection_component.html.erb @@ -9,7 +9,7 @@ selected: selected_columns, protected: protected_options, inputCaption: caption, - inputLabel: I18n.t(:"queries.configure_view.columns.input_label"), + inputLabel: label, inputPlaceholder: I18n.t(:"queries.configure_view.columns.input_placeholder"), dragAreaLabel: I18n.t(:"queries.configure_view.columns.drag_area_label"), } diff --git a/app/components/work_packages/exports/column_selection_component.rb b/app/components/work_packages/exports/column_selection_component.rb index 7715b74cd5eb..e99625ca6188 100644 --- a/app/components/work_packages/exports/column_selection_component.rb +++ b/app/components/work_packages/exports/column_selection_component.rb @@ -33,14 +33,16 @@ module Exports class ColumnSelectionComponent < ApplicationComponent include WorkPackagesHelper - attr_reader :query, :id, :caption + attr_reader :query, :id, :caption, :label - def initialize(query, id, caption) + def initialize(query, id, caption, + label = I18n.t(:"queries.configure_view.columns.input_label")) super() @query = query @id = id @caption = caption + @label = label end def available_columns diff --git a/app/components/work_packages/exports/pdf/report/export_settings_component.html.erb b/app/components/work_packages/exports/pdf/report/export_settings_component.html.erb index b35226de16a8..95e026d32eda 100644 --- a/app/components/work_packages/exports/pdf/report/export_settings_component.html.erb +++ b/app/components/work_packages/exports/pdf/report/export_settings_component.html.erb @@ -3,7 +3,8 @@ <%= render WorkPackages::Exports::ColumnSelectionComponent.new( query, "columns-select-export-pdf-report", - I18n.t("export.dialog.columns.input_caption_report") + I18n.t("export.dialog.columns.input_caption_report"), + I18n.t("export.dialog.columns.input_label_report") ) %> <% end %> <% container.with_row do |_columns| %> diff --git a/app/components/work_packages/progress/work_based/modal_body_component.html.erb b/app/components/work_packages/progress/work_based/modal_body_component.html.erb index 49e1a8bdb250..d29236da0e9e 100644 --- a/app/components/work_packages/progress/work_based/modal_body_component.html.erb +++ b/app/components/work_packages/progress/work_based/modal_body_component.html.erb @@ -38,10 +38,13 @@ <% end %> <% end %> - <% modal_body.with_row(mt: 3) do |_tooltip| %> - <%= render(Primer::Beta::Text.new(font_weight: :semibold)) { t("work_package.progress.label_note") } %> - <%= render(Primer::Beta::Text.new) { t("work_package.progress.modal.work_based_help_text") } %> - <%= render(Primer::Beta::Link.new(href: learn_more_href)) { t(:label_learn_more) } %> + <%# This condition branch to be removed in 15.0 with :percent_complete_edition feature flag removal %> + <% unless OpenProject::FeatureDecisions.percent_complete_edition_active? %> + <% modal_body.with_row(mt: 3) do |_tooltip| %> + <%= render(Primer::Beta::Text.new(font_weight: :semibold)) { t("work_package.progress.label_note") } %> + <%= render(Primer::Beta::Text.new) { t("work_package.progress.modal.work_based_help_text_pre_14_4_without_percent_complete_edition") } %> + <%= render(Primer::Beta::Link.new(href: learn_more_href)) { t(:label_learn_more) } %> + <% end %> <% end %> <% modal_body.with_row(mt: 3) do |_actions_row| %> diff --git a/app/components/work_packages/split_view_component.html.erb b/app/components/work_packages/split_view_component.html.erb index acc03f9bbe2d..a978b875dd7d 100644 --- a/app/components/work_packages/split_view_component.html.erb +++ b/app/components/work_packages/split_view_component.html.erb @@ -19,7 +19,6 @@ inputs: { work_package_id: params[:work_package_id] || @work_package.id, resizerClass: "op-work-package-split-view", - resizeStyle: "width", activeTab: @tab } end diff --git a/app/components/work_packages/split_view_component.sass b/app/components/work_packages/split_view_component.sass index 7aad3bdcbeb3..87e22c19c856 100644 --- a/app/components/work_packages/split_view_component.sass +++ b/app/components/work_packages/split_view_component.sass @@ -1,6 +1,6 @@ .op-work-package-split-view height: 100% - width: 550px + min-width: 550px justify-content: space-around border-left: 1px solid var(--borderColor-muted) diff --git a/app/contracts/work_packages/base_contract.rb b/app/contracts/work_packages/base_contract.rb index 2ffdc13dd8b0..dc62c589bf41 100644 --- a/app/contracts/work_packages/base_contract.rb +++ b/app/contracts/work_packages/base_contract.rb @@ -58,8 +58,10 @@ class BaseContract < ::ModelContract && WorkPackage.work_based_mode? } do if OpenProject::FeatureDecisions.percent_complete_edition_active? + next if invalid_work_or_remaining_work_values? # avoid too many error messages at the same time + validate_percent_complete_matches_work_and_remaining_work - validate_percent_complete_is_unset_when_work_is_zero + validate_percent_complete_is_empty_when_work_is_zero validate_percent_complete_is_set_when_work_and_remaining_work_are_set end end @@ -80,6 +82,7 @@ class BaseContract < ::ModelContract attribute :remaining_hours do validate_remaining_work_is_lower_than_work if OpenProject::FeatureDecisions.percent_complete_edition_active? + validate_remaining_work_is_zero_or_empty_when_percent_complete_is_100p validate_remaining_work_is_set_when_work_and_percent_complete_are_set else # to be removed in 15.0 with :percent_complete_edition feature flag removal @@ -362,39 +365,44 @@ def validate_work_is_set_when_remaining_work_is_set end def validate_work_is_set_when_remaining_work_and_percent_complete_are_set - if remaining_work_set_and_valid? && percent_complete_set_and_valid? && work_unset? + if remaining_work_set_and_valid? && percent_complete_set_and_valid? && work_empty? && percent_complete != 100 errors.add(:estimated_hours, :must_be_set_when_remaining_work_and_percent_complete_are_set) end end + def validate_remaining_work_is_zero_or_empty_when_percent_complete_is_100p + return unless percent_complete == 100 + + if work_set_and_valid? && remaining_work != 0 + errors.add(:remaining_hours, :must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p) + elsif work_empty? && remaining_work_set? + errors.add(:remaining_hours, :must_be_empty_when_work_is_empty_and_percent_complete_is_100p) + end + end + def validate_remaining_work_is_set_when_work_and_percent_complete_are_set - if work_set_and_valid? && percent_complete_set_and_valid? && remaining_work_unset? + return if percent_complete == 100 + + if work_set_and_valid? && percent_complete_set_and_valid? && remaining_work_empty? errors.add(:remaining_hours, :must_be_set_when_work_and_percent_complete_are_set) end end def validate_percent_complete_is_set_when_work_and_remaining_work_are_set - if work_set_and_valid? && remaining_work_set_and_valid? && work != 0 && percent_complete_unset? + if work_set? && remaining_work_set? && work != 0 && percent_complete_empty? errors.add(:done_ratio, :must_be_set_when_work_and_remaining_work_are_set) end end - # rubocop:disable Metrics/AbcSize def validate_percent_complete_matches_work_and_remaining_work - return if WorkPackage.status_based_mode? || percent_complete_unset? || work == 0 - return if remaining_work_exceeds_work? # avoid too many error messages at the same time - return unless work_set? && remaining_work_set? - - work_done = work - remaining_work - expected_percent_complete = (100 * work_done.to_f / work).round + return if percent_complete_derivation_unapplicable? - if percent_complete != expected_percent_complete + if !percent_complete_range_derived_from_work_and_remaining_work.cover?(percent_complete) errors.add(:done_ratio, :does_not_match_work_and_remaining_work) end end - # rubocop:enable Metrics/AbcSize - def validate_percent_complete_is_unset_when_work_is_zero + def validate_percent_complete_is_empty_when_work_is_zero return if WorkPackage.status_based_mode? if work == 0 && percent_complete_set? @@ -411,10 +419,10 @@ def work_set? end def work_set_and_valid? - work_set? && work >= 0 + work_set? && work >= 0 && !model.errors.has_key?(:estimated_hours) end - def work_unset? + def work_empty? work.nil? end @@ -427,15 +435,26 @@ def remaining_work_set? end def remaining_work_set_and_valid? - remaining_work_set? && remaining_work >= 0 + remaining_work_set? && remaining_work >= 0 && !model.errors.has_key?(:remaining_hours) end - def remaining_work_unset? + def remaining_work_empty? remaining_work.nil? end + def invalid_work_or_remaining_work_values? + (work_set? && work.negative?) || + (remaining_work_set? && remaining_work.negative?) || + (model.errors.has_key?(:estimated_hours) || model.errors.has_key?(:remaining_hours)) || + remaining_work_exceeds_work? + end + def remaining_work_exceeds_work? - work_set? && remaining_work_set? && remaining_work > work + # if % complete is 100%, then remaining work should be 0h or empty, so no + # need to display an error for remaining work exceeding work + return false if percent_complete == 100 + + work_set_and_valid? && remaining_work_set_and_valid? && remaining_work > work end def percent_complete @@ -450,10 +469,25 @@ def percent_complete_set_and_valid? percent_complete_set? && percent_complete.between?(0, 100) end - def percent_complete_unset? + def percent_complete_empty? percent_complete.nil? end + def percent_complete_derivation_unapplicable? + WorkPackage.status_based_mode? || # only applicable in work-based mode + work_empty? || remaining_work_empty? || percent_complete_empty? || # only applicable if all 3 values are set + work == 0 || percent_complete == 100 # only applicable if not in special cases leading to divisions by zero + end + + def percent_complete_range_derived_from_work_and_remaining_work + work_done = work - remaining_work + percentage = (100 * work_done.to_f / work) + + lower_bound = percentage.truncate + upper_bound = lower_bound + 1 + lower_bound..upper_bound + end + def validate_no_reopen_on_closed_version if model.version_id && model.reopened? && model.version.closed? errors.add :base, I18n.t(:error_can_not_reopen_work_package_on_closed_version) diff --git a/app/controllers/admin/backups_controller.rb b/app/controllers/admin/backups_controller.rb index fb50e597c75b..0be5ebdff8a0 100644 --- a/app/controllers/admin/backups_controller.rb +++ b/app/controllers/admin/backups_controller.rb @@ -76,12 +76,10 @@ def delete_token redirect_to action: "show" end - def default_breadcrumb - t(:label_backup) - end + def default_breadcrumb; end def show_local_breadcrumb - true + false end def check_enabled diff --git a/app/controllers/attribute_help_texts_controller.rb b/app/controllers/attribute_help_texts_controller.rb index 737002a40f77..44aa15e6085f 100644 --- a/app/controllers/attribute_help_texts_controller.rb +++ b/app/controllers/attribute_help_texts_controller.rb @@ -44,8 +44,6 @@ def new def edit; end - def upsale; end - def create call = ::AttributeHelpTexts::CreateService .new(user: current_user) @@ -87,16 +85,10 @@ def destroy protected - def default_breadcrumb - if action_name == "index" - t("attribute_help_texts.label_plural") - else - ActionController::Base.helpers.link_to(t("attribute_help_texts.label_plural"), attribute_help_texts_path) - end - end + def default_breadcrumb; end def show_local_breadcrumb - true + false end private diff --git a/app/controllers/custom_fields_controller.rb b/app/controllers/custom_fields_controller.rb index 644a489ec762..de3a72af308e 100644 --- a/app/controllers/custom_fields_controller.rb +++ b/app/controllers/custom_fields_controller.rb @@ -58,16 +58,10 @@ def edit protected - def default_breadcrumb - if action_name == "index" - t("label_custom_field_plural") - else - ActionController::Base.helpers.link_to(t("label_custom_field_plural"), custom_fields_path) - end - end + def default_breadcrumb; end def show_local_breadcrumb - true + false end def find_custom_field diff --git a/app/controllers/custom_styles_controller.rb b/app/controllers/custom_styles_controller.rb index 884d8a87548f..e2e70eb61dfb 100644 --- a/app/controllers/custom_styles_controller.rb +++ b/app/controllers/custom_styles_controller.rb @@ -153,7 +153,7 @@ def update_themes end def show_local_breadcrumb - true + false end private diff --git a/app/controllers/enterprises_controller.rb b/app/controllers/enterprises_controller.rb index 85bc3e8eb9c1..a011ec00375c 100644 --- a/app/controllers/enterprises_controller.rb +++ b/app/controllers/enterprises_controller.rb @@ -98,12 +98,10 @@ def render_gon helpers.write_augur_to_gon end - def default_breadcrumb - t(:label_enterprise_edition) - end + def default_breadcrumb; end def show_local_breadcrumb - true + false end def check_user_limit diff --git a/app/controllers/work_packages_controller.rb b/app/controllers/work_packages_controller.rb index b2461ee0c4b4..9e68b8b46495 100644 --- a/app/controllers/work_packages_controller.rb +++ b/app/controllers/work_packages_controller.rb @@ -39,14 +39,12 @@ class WorkPackagesController < ApplicationController :project, only: :show before_action :load_and_authorize_in_optional_project, :check_allowed_export, - :protect_from_unauthorized_export, only: :index + :protect_from_unauthorized_export, only: %i[index export_dialog] authorization_checked! :index, :show, :export_dialog before_action :load_and_validate_query, only: :index, unless: -> { request.format.html? } before_action :load_work_packages, only: :index, if: -> { request.format.atom? } - - before_action :load_and_authorize_in_optional_project_for_export, only: :export_dialog, if: -> { request.format.html? } - before_action :load_and_validate_query_for_export, only: :export_dialog, if: -> { request.format.html? } + before_action :load_and_validate_query_for_export, only: :export_dialog def index respond_to do |format| @@ -94,10 +92,6 @@ def export_dialog protected - def load_and_authorize_in_optional_project_for_export - load_and_authorize_in_optional_project - end - def load_and_validate_query_for_export load_and_validate_query end diff --git a/app/controllers/workflows_controller.rb b/app/controllers/workflows_controller.rb index aec51ef4790b..bf78196c288c 100644 --- a/app/controllers/workflows_controller.rb +++ b/app/controllers/workflows_controller.rb @@ -45,7 +45,7 @@ def show end def edit - @used_statuses_only = params[:used_statuses_only] != "0" + @used_statuses_only = params[:used_statuses_only] == "1" statuses_for_form diff --git a/app/forms/work_packages/progress_form.rb b/app/forms/work_packages/progress_form.rb index 58cad379767b..61eecfa284b5 100644 --- a/app/forms/work_packages/progress_form.rb +++ b/app/forms/work_packages/progress_form.rb @@ -62,56 +62,20 @@ def initialize(work_package:, form do |query_form| query_form.group(layout: :horizontal) do |group| if mode == :status_based - select_field_options = - default_field_options(:status_id) - .merge( - name: :status_id, - label: I18n.t(:label_percent_complete), - disabled: @work_package.new_record? - ) - - group.select_list(**select_field_options) do |select_list| - WorkPackages::UpdateContract.new(@work_package, User.current) - .assignable_statuses - .find_each do |status| - select_list.option( - label: "#{status.name} (#{status.default_done_ratio}%)", - value: status.id - ) - end - end - - render_text_field(group, name: :estimated_hours, label: I18n.t(:label_work)) - render_readonly_text_field(group, name: :remaining_hours, label: I18n.t(:label_remaining_work)) - - # Add a hidden field in create forms as the select field is disabled and is otherwise not included in the form payload - group.hidden(name: :status_id) if @work_package.new_record? + select_status_list(group) + text_field(group, name: :estimated_hours, label: I18n.t(:label_work)) + readonly_text_field(group, name: :remaining_hours, label: I18n.t(:label_remaining_work)) - group.hidden(name: :status_id_touched, - value: @touched_field_map["status_id_touched"] || false, - data: { "work-packages--progress--touched-field-marker-target": "touchedFieldInput", - "referrer-field": "work_package[status_id]" }) - group.hidden(name: :estimated_hours_touched, - value: @touched_field_map["estimated_hours_touched"] || false, - data: { "work-packages--progress--touched-field-marker-target": "touchedFieldInput", - "referrer-field": "work_package[estimated_hours]" }) + hidden_touched_field(group, name: :status_id) + hidden_touched_field(group, name: :estimated_hours) else - render_text_field(group, name: :estimated_hours, label: I18n.t(:label_work)) - render_text_field(group, name: :remaining_hours, label: I18n.t(:label_remaining_work)) - render_text_field(group, name: :done_ratio, label: I18n.t(:label_percent_complete)) - - group.hidden(name: :estimated_hours_touched, - value: @touched_field_map["estimated_hours_touched"] || false, - data: { "work-packages--progress--touched-field-marker-target": "touchedFieldInput", - "referrer-field": "work_package[estimated_hours]" }) - group.hidden(name: :remaining_hours_touched, - value: @touched_field_map["remaining_hours_touched"] || false, - data: { "work-packages--progress--touched-field-marker-target": "touchedFieldInput", - "referrer-field": "work_package[remaining_hours]" }) - group.hidden(name: :done_ratio_touched, - value: @touched_field_map["done_ratio_touched"] || false, - data: { "work-packages--progress--touched-field-marker-target": "touchedFieldInput", - "referrer-field": "work_package[done_ratio]" }) + text_field(group, name: :estimated_hours, label: I18n.t(:label_work)) + text_field(group, name: :remaining_hours, label: I18n.t(:label_remaining_work)) + text_field(group, name: :done_ratio, label: I18n.t(:label_percent_complete)) + + hidden_touched_field(group, name: :estimated_hours) + hidden_touched_field(group, name: :remaining_hours) + hidden_touched_field(group, name: :done_ratio) end group.fields_for(:initial) do |builder| InitialValuesForm.new(builder, work_package:, mode:) @@ -138,36 +102,74 @@ def focused_field_by_selection(field) field end - def render_text_field(group, - name:, - label:) - text_field_options = { + def select_status_list(group) + # status selection is disabled in create forms + disabled = work_package.new_record? + + select_field_options = + default_field_options(:status_id) + .merge( + name: :status_id, + label: I18n.t(:label_percent_complete), + disabled: + ) + + group.select_list(**select_field_options) do |select_list| + WorkPackages::UpdateContract.new(work_package, User.current) + .assignable_statuses + .each do |status| # avoid find_each to keep ordering by position + select_list.option( + label: "#{status.name} (#{status.default_done_ratio}%)", + value: status.id + ) + end + end + + # Add a hidden field if the select field is disabled, otherwise it would not be included in the form payload + group.hidden(name: :status_id) if disabled + end + + def text_field(group, + name:, + label:) + text_field_options = default_field_options(name).merge( name:, value: field_value(name), - label: - } - text_field_options.reverse_merge!(default_field_options(name)) + label:, + caption: field_hint_message(name), + validation_message: validation_message(name) + ) group.text_field(**text_field_options) end - def render_readonly_text_field(group, - name:, - label:, - placeholder: true) - text_field_options = { + def readonly_text_field(group, + name:, + label:, + placeholder: true) + text_field_options = default_field_options(name).merge( name:, value: field_value(name), label:, readonly: true, classes: "input--readonly", placeholder: ("-" if placeholder) - } - text_field_options.reverse_merge!(default_field_options(name)) + ) group.text_field(**text_field_options) end + def hidden_touched_field(group, name:) + group.hidden(name: :"#{name}_touched", + value: touched(name), + data: { "work-packages--progress--touched-field-marker-target": "touchedFieldInput", + "referrer-field": "work_package[#{name}]" }) + end + + def touched(name) + @touched_field_map["#{name}_touched"] || false + end + def field_value(name) errors = @work_package.errors.where(name) if (user_value = errors.map { |error| error.options[:value] }.find { !_1.nil? }) @@ -179,6 +181,19 @@ def field_value(name) end end + def field_hint_message(field_name) + hint = work_package.derived_progress_hints[field_name] + return if hint.nil? + + I18n.t("work_package.progress.derivation_hints.#{field_name}.#{hint}") + end + + def validation_message(name) + # it's ok to take the first error only, that's how primer_view_component does it anyway. + message = @work_package.errors.messages_for(name).first + message&.upcase_first + end + def as_percent(value) value ? "#{value}%" : nil end diff --git a/app/forms/work_packages/progress_form/initial_values_form.rb b/app/forms/work_packages/progress_form/initial_values_form.rb index 2c10cc81d8e6..6ffe9618b536 100644 --- a/app/forms/work_packages/progress_form/initial_values_form.rb +++ b/app/forms/work_packages/progress_form/initial_values_form.rb @@ -40,21 +40,25 @@ def initialize(work_package:, form do |form| if mode == :status_based - form.hidden(name: :status_id, - value: work_package.status_id_was) - form.hidden(name: :estimated_hours, - value: work_package.estimated_hours_was) + hidden_initial_field(form, name: :status_id) + hidden_initial_field(form, name: :estimated_hours) else - form.hidden(name: :estimated_hours, - value: work_package.estimated_hours_was) - form.hidden(name: :remaining_hours, - value: work_package.remaining_hours_was) + hidden_initial_field(form, name: :estimated_hours) + hidden_initial_field(form, name: :remaining_hours) # next line to be removed in 15.0 with :percent_complete_edition feature flag removal next unless OpenProject::FeatureDecisions.percent_complete_edition_active? - form.hidden(name: :done_ratio, - value: work_package.done_ratio_was) + hidden_initial_field(form, name: :done_ratio) end end + + private + + def hidden_initial_field(form, name:) + form.hidden(name:, + value: work_package.public_send(:"#{name}_was"), + data: { "work-packages--progress--touched-field-marker-target": "initialValueInput", + "referrer-field": "work_package[#{name}]" }) + end end end diff --git a/app/models/custom_field/order_statements.rb b/app/models/custom_field/order_statements.rb index c5463cf147c8..e13a19a9f306 100644 --- a/app/models/custom_field/order_statements.rb +++ b/app/models/custom_field/order_statements.rb @@ -38,7 +38,7 @@ def order_statements else [select_custom_option_position] end - when "string", "text", "date", "bool" + when "string", "text", "date", "bool", "link" if multi_value? [select_custom_values_as_group] else diff --git a/app/models/mail_handler.rb b/app/models/mail_handler.rb index c404f5d4e238..3525d0d6ba26 100644 --- a/app/models/mail_handler.rb +++ b/app/models/mail_handler.rb @@ -377,17 +377,18 @@ def target_project # Returns a Hash of issue attributes extracted from keywords in the email body def wp_attributes_from_keywords(work_package) { - "type_id" => wp_type_from_keywords(work_package), - "status_id" => wp_status_from_keywords, - "parent_id" => wp_parent_from_keywords, - "priority_id" => wp_priority_from_keywords, - "category_id" => wp_category_from_keywords(work_package), "assigned_to_id" => wp_assignee_from_keywords(work_package), - "version_id" => wp_version_from_keywords(work_package), - "start_date" => wp_start_date_from_keywords, + "category_id" => wp_category_from_keywords(work_package), "due_date" => wp_due_date_from_keywords, "estimated_hours" => wp_estimated_hours_from_keywords, - "remaining_hours" => wp_remaining_hours_from_keywords + "parent_id" => wp_parent_from_keywords, + "priority_id" => wp_priority_from_keywords, + "remaining_hours" => wp_remaining_hours_from_keywords, + "responsible_id" => wp_accountable_from_keywords(work_package), + "start_date" => wp_start_date_from_keywords, + "status_id" => wp_status_from_keywords, + "type_id" => wp_type_from_keywords(work_package), + "version_id" => wp_version_from_keywords(work_package) }.compact_blank! end @@ -541,8 +542,16 @@ def wp_category_from_keywords(work_package) lookup_case_insensitive_key(work_package.project.categories, :category) end + def wp_accountable_from_keywords(work_package) + get_assignable_principal_from_keywords(:responsible, work_package) + end + def wp_assignee_from_keywords(work_package) - keyword = get_keyword(:assigned_to, override: true) + get_assignable_principal_from_keywords(:assigned_to, work_package) + end + + def get_assignable_principal_from_keywords(keyword, work_package) + keyword = get_keyword(keyword, override: true) return nil if keyword.blank? diff --git a/app/models/work_package.rb b/app/models/work_package.rb index 0ed89cfe3737..859a093eb4d6 100644 --- a/app/models/work_package.rb +++ b/app/models/work_package.rb @@ -328,6 +328,18 @@ def remaining_hours=(hours) write_attribute :remaining_hours, convert_duration_to_hours(hours) end + def done_ratio=(value) + write_attribute :done_ratio, convert_value_to_percentage(value) + end + + def derived_progress_hints=(hints) + @derived_progress_hints = hints + end + + def derived_progress_hints + @derived_progress_hints ||= {} + end + def duration_in_hours duration ? duration * 24 : nil end @@ -553,7 +565,7 @@ def add_time_entry_for(user, attributes) def convert_duration_to_hours(value) if value.is_a?(String) begin - value = value.blank? ? nil : DurationConverter.parse(value) + value = DurationConverter.parse(value) rescue ChronicDuration::DurationParseError # keep invalid value, error shall be caught by numericality validator end @@ -561,6 +573,13 @@ def convert_duration_to_hours(value) value end + def convert_value_to_percentage(value) + if value.is_a?(String) && PercentageConverter.valid?(value) + value = PercentageConverter.parse(value) + end + value + end + ## # Checks if the time entry defined by the given attributes is blank. # A time entry counts as blank despite a selected activity if that activity diff --git a/app/models/work_package/validations.rb b/app/models/work_package/validations.rb index 80c849dc620a..28bc8b4c5cdf 100644 --- a/app/models/work_package/validations.rb +++ b/app/models/work_package/validations.rb @@ -33,7 +33,7 @@ module WorkPackage::Validations validates :subject, :priority, :project, :type, :author, :status, presence: true validates :subject, length: { maximum: 255 } - validates :done_ratio, inclusion: { in: 0..100 }, allow_nil: true + validates :done_ratio, inclusion: { in: 0..100 }, numericality: true, allow_nil: true validates :estimated_hours, numericality: { allow_nil: true, greater_than_or_equal_to: 0 } validates :remaining_hours, numericality: { allow_nil: true, greater_than_or_equal_to: 0 } validates :derived_remaining_hours, numericality: { allow_nil: true, greater_than_or_equal_to: 0 } diff --git a/app/services/duration_converter.rb b/app/services/duration_converter.rb index f267b5b05c24..e2efe5a771e7 100644 --- a/app/services/duration_converter.rb +++ b/app/services/duration_converter.rb @@ -76,6 +76,53 @@ class DurationConverter class << self def parse(duration_string) + return nil if duration_string.blank? + + do_parse(duration_string) + end + + def valid?(duration) + case duration + when String + duration.blank? || parseable?(duration) + when Numeric + duration >= 0 + when nil + true + else + false + end + rescue ChronicDuration::DurationParseError + false + end + + def output(duration_in_hours) + return duration_in_hours if duration_in_hours.nil? + + seconds = (duration_in_hours * 3600).to_i + + # :days_and_hours format return "0h" when parsing 0. + ChronicDuration.output(seconds, + format:, + **duration_length_options) + end + + private + + def parseable?(duration_string) + if number = Integer(duration_string, 10, exception: false) || Float(duration_string, exception: false) + number >= 0 + else + begin + do_parse(duration_string) + true + rescue ChronicDuration::DurationParseError + false + end + end + end + + def do_parse(duration_string) # Assume the next logical unit to allow users to write # durations such as "2h 1" assuming "1" is "1 minute" last_unit_in_string = duration_string.scan(/[a-zA-Z]+/) @@ -88,26 +135,13 @@ def parse(duration_string) "hours" end - ChronicDuration.raise_exceptions = true ChronicDuration.parse(duration_string, keep_zero: true, default_unit:, + raise_exceptions: true, **duration_length_options) / 3600.to_f end - def output(duration_in_hours) - return duration_in_hours if duration_in_hours.nil? - - seconds = (duration_in_hours * 3600).to_i - - # :days_and_hours format return "0h" when parsing 0. - ChronicDuration.output(seconds, - format:, - **duration_length_options) - end - - private - def format Setting.duration_format == "days_and_hours" ? :days_and_hours : :hours_only end diff --git a/app/services/percentage_converter.rb b/app/services/percentage_converter.rb new file mode 100644 index 000000000000..75774b001f87 --- /dev/null +++ b/app/services/percentage_converter.rb @@ -0,0 +1,57 @@ +# frozen_string_literal: true + +# -- copyright +# OpenProject is an open source project management software. +# Copyright (C) the OpenProject GmbH +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License version 3. +# +# OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows: +# Copyright (C) 2006-2013 Jean-Philippe Lang +# Copyright (C) 2010-2013 the ChiliProject Team +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# +# See COPYRIGHT and LICENSE files for more details. +# ++ + +class PercentageConverter + class ParseError < StandardError; end + + class << self + VALID_PERCENTAGE = /\A\s*(\+|-)?\d+(\.\d*)?\s*%?\s*\z/ + + # Parse a string representing a percentage and return the value as a float. + def parse(percentage_string) + return nil if percentage_string.blank? + raise ParseError, "invalid percentage: #{percentage_string}" unless valid?(percentage_string) + + percentage_string.to_f + end + + # Returns true for a value which could assigned to a % complete value (done_ratio). + def valid?(percentage) + case percentage + when String + percentage.blank? || percentage.match?(VALID_PERCENTAGE) + when Numeric, nil + true + else + false + end + end + end +end diff --git a/app/services/work_packages/set_attributes_service/derive_progress_values_base.rb b/app/services/work_packages/set_attributes_service/derive_progress_values_base.rb index 0138952612d1..fa057d81076f 100644 --- a/app/services/work_packages/set_attributes_service/derive_progress_values_base.rb +++ b/app/services/work_packages/set_attributes_service/derive_progress_values_base.rb @@ -30,8 +30,6 @@ class WorkPackages::SetAttributesService class DeriveProgressValuesBase attr_reader :work_package - PROGRESS_ATTRIBUTES = %i[work remaining_work percent_complete].freeze - def initialize(work_package) @work_package = work_package end @@ -57,11 +55,11 @@ def work_set? work.present? end - def work_unset? + def work_empty? work.nil? end - def work_was_unset? + def work_was_empty? work_package.estimated_hours_was.nil? end @@ -77,6 +75,10 @@ def work_not_provided_by_user? !work_came_from_user? end + def work_valid? + DurationConverter.valid?(work_package.estimated_hours_before_type_cast) + end + def remaining_work work_package.remaining_hours end @@ -89,11 +91,11 @@ def remaining_work_set? remaining_work.present? end - def remaining_work_unset? + def remaining_work_empty? remaining_work.nil? end - def remaining_work_was_unset? + def remaining_work_was_empty? work_package.remaining_hours_was.nil? end @@ -109,6 +111,10 @@ def remaining_work_not_provided_by_user? !remaining_work_came_from_user? end + def remaining_work_valid? + DurationConverter.valid?(work_package.remaining_hours_before_type_cast) + end + def percent_complete work_package.done_ratio end @@ -121,11 +127,11 @@ def percent_complete_set? percent_complete.present? end - def percent_complete_unset? + def percent_complete_empty? percent_complete.nil? end - def percent_complete_was_unset? + def percent_complete_was_empty? work_package.done_ratio_was.nil? end @@ -143,24 +149,26 @@ def percent_complete_not_provided_by_user? private + def set_hint(field, hint) + work_package.derived_progress_hints[field] = hint + end + def round_progress_values # The values are set only when rounding returns a different value. Doing # otherwise would modify the values returned by `xxx_before_type_cast` and # prevent the numericality validator from working when setting the field # to a string value. rounded = work&.round(2) - if rounded != work + if rounded != work && work_valid? self.work = rounded end rounded = remaining_work&.round(2) - if rounded != remaining_work + if rounded != remaining_work && remaining_work_valid? self.remaining_work = rounded end end def remaining_work_from_percent_complete_and_work - return nil if work_unset? || percent_complete_unset? - completed_work = work * percent_complete / 100.0 remaining_work = (work - completed_work).round(2) remaining_work.clamp(0.0, work) diff --git a/app/services/work_packages/set_attributes_service/derive_progress_values_status_based.rb b/app/services/work_packages/set_attributes_service/derive_progress_values_status_based.rb index b38db2a6744a..3035a88ccafc 100644 --- a/app/services/work_packages/set_attributes_service/derive_progress_values_status_based.rb +++ b/app/services/work_packages/set_attributes_service/derive_progress_values_status_based.rb @@ -51,7 +51,15 @@ def update_remaining_work_from_percent_complete return if remaining_work_came_from_user? return if work&.negative? - self.remaining_work = remaining_work_from_percent_complete_and_work + if work_empty? + return unless work_changed? + + set_hint(:remaining_hours, :cleared_because_work_is_empty) + self.remaining_work = nil + else + set_hint(:remaining_hours, :derived) + self.remaining_work = remaining_work_from_percent_complete_and_work + end end end end diff --git a/app/services/work_packages/set_attributes_service/derive_progress_values_work_based.rb b/app/services/work_packages/set_attributes_service/derive_progress_values_work_based.rb index c599d8456876..69cb6736875e 100644 --- a/app/services/work_packages/set_attributes_service/derive_progress_values_work_based.rb +++ b/app/services/work_packages/set_attributes_service/derive_progress_values_work_based.rb @@ -30,6 +30,8 @@ class WorkPackages::SetAttributesService class DeriveProgressValuesWorkBased < DeriveProgressValuesBase private + attr_accessor :skip_percent_complete_derivation + def derive_progress_attributes raise ArgumentError, "Cannot use #{self.class.name} in status-based mode" if WorkPackage.status_based_mode? @@ -43,9 +45,10 @@ def derive_progress_attributes end def invalid_progress_values? - work&.negative? \ - || remaining_work&.negative? \ + work_invalid? \ + || remaining_work_invalid? \ || percent_complete_out_of_range? \ + || percent_complete_unparsable? \ || remaining_work_set_greater_than_work? end @@ -62,66 +65,124 @@ def derive_remaining_work? end def derive_percent_complete? - percent_complete_not_provided_by_user? && (work_changed? || remaining_work_changed?) + percent_complete_not_provided_by_user? && (work_changed? || remaining_work_changed?) \ + && !skip_percent_complete_derivation end + # rubocop:disable Metrics/AbcSize,Metrics/PerceivedComplexity def update_work - return if work_set_and_no_user_inputs_provided_for_both_remaining_work_and_percent_complete? - return if remaining_work_unset? && percent_complete_unset? - - self.work = work_from_percent_complete_and_remaining_work + return if remaining_work_empty? && percent_complete_empty? + return if percent_complete == 100 # would be Infinity if computed when % complete is 100% + return unless work_can_be_derived? + + if remaining_work_empty? + return unless remaining_work_changed? + + set_hint(:estimated_hours, :cleared_because_remaining_work_is_empty) + self.work = nil + elsif percent_complete_empty? + set_hint(:estimated_hours, :same_as_remaining_work) + self.work = remaining_work + else + set_hint(:estimated_hours, :derived) + self.work = work_from_percent_complete_and_remaining_work + skip_percent_complete_derivation! + end end - # rubocop:disable Metrics/AbcSize,Metrics/PerceivedComplexity def update_remaining_work - return if work_unset? && percent_complete_unset? - return if work_was_unset? && remaining_work_set? # remaining work is kept and % complete will be set + return if work_empty? && percent_complete_empty? + return if work_was_empty? && remaining_work_set? # remaining work is kept and % complete will be unset - if work_set? && remaining_work_unset? && percent_complete_unset? + if work_set? && remaining_work_empty? && percent_complete_empty? + set_hint(:remaining_hours, :same_as_work) self.remaining_work = work - elsif work_changed? && work_set? && remaining_work_set? && !percent_complete_changed? + elsif work_changed? && work_set? && remaining_work_set? && percent_complete_not_provided_by_user? delta = work - work_was + if delta.positive? + set_hint(:remaining_hours, :increased_like_work) + elsif delta.negative? + set_hint(:remaining_hours, :decreased_like_work) + end self.remaining_work = (remaining_work + delta).clamp(0.0, work) - elsif work_unset? || percent_complete_unset? + elsif work_empty? + return unless work_changed? + + set_hint(:remaining_hours, :cleared_because_work_is_empty) + self.remaining_work = nil + elsif percent_complete_empty? + set_hint(:remaining_hours, :cleared_because_percent_complete_is_empty) self.remaining_work = nil else + set_hint(:remaining_hours, :derived) self.remaining_work = remaining_work_from_percent_complete_and_work + skip_percent_complete_derivation! end end # rubocop:enable Metrics/AbcSize,Metrics/PerceivedComplexity def update_percent_complete - return if work_unset? + return if work_empty? + + if work < 0.005 + set_hint(:done_ratio, :cleared_because_work_is_0h) + self.percent_complete = nil + elsif remaining_work_empty? + set_hint(:done_ratio, :cleared_because_remaining_work_is_empty) + self.percent_complete = nil + else + set_hint(:done_ratio, :derived) + self.percent_complete = percent_complete_from_work_and_remaining_work + end + end - self.percent_complete = percent_complete_from_work_and_remaining_work + def skip_percent_complete_derivation! + self.skip_percent_complete_derivation = true end def percent_complete_from_work_and_remaining_work - return nil if work.zero? || remaining_work_unset? - - completed_work = work - remaining_work - completion_ratio = completed_work.to_f / work - - (completion_ratio * 100).round + rounded_work = work.round(2) + rounded_remaining_work = remaining_work.round(2) + completed_work = rounded_work - rounded_remaining_work + completion_ratio = completed_work.to_f / rounded_work + + percentage = (completion_ratio * 100) + case percentage + in 0 then 0 + in 0..1 then 1 + in 99...100 then 99 + else + percentage.round + end end def work_from_percent_complete_and_remaining_work - return if remaining_work_unset? - - remaining_percent_complete = 1.0 - ((percent_complete || 0) / 100.0) + remaining_percent_complete = 1.0 - (percent_complete / 100.0) remaining_work / remaining_percent_complete end - def remaining_work_set_greater_than_work? - attributes_from_user == %i[remaining_work] && work && remaining_work && remaining_work > work + def work_invalid? + !work_valid? end - def attributes_from_user - @attributes_from_user ||= PROGRESS_ATTRIBUTES.filter { |attr| public_send(:"#{attr}_came_from_user?") } + def remaining_work_invalid? + !remaining_work_valid? + end + + def percent_complete_unparsable? + !PercentageConverter.valid?(work_package.done_ratio_before_type_cast) + end + + def remaining_work_set_greater_than_work? + (work_was_empty? || remaining_work_came_from_user?) \ + && percent_complete_not_provided_by_user? \ + && work && remaining_work && remaining_work > work end - def work_set_and_no_user_inputs_provided_for_both_remaining_work_and_percent_complete? - work_set? && (remaining_work_not_provided_by_user? || percent_complete_not_provided_by_user?) + def work_can_be_derived? + work_empty? \ + || (remaining_work_came_from_user? && percent_complete_came_from_user?) \ + || (remaining_work_empty? && remaining_work_came_from_user?) end end end diff --git a/app/views/admin/backups/show.html.erb b/app/views/admin/backups/show.html.erb index 1b6f6fa64d16..b1bcd6f88465 100644 --- a/app/views/admin/backups/show.html.erb +++ b/app/views/admin/backups/show.html.erb @@ -29,40 +29,7 @@ See COPYRIGHT and LICENSE files for more details. <% html_title t(:label_administration), t(:label_backup) -%> -<%= toolbar title: t('label_backup') do %> -
  • - <% label_action = @backup_token.present? ? 'reset' : 'create' %> - <% label = t("backup.label_#{label_action}_token") %> - <%= - link_to( - { action: 'reset_token' }, - class: 'button -primary', - aria: {label: label}, - title: label - ) do - %> - <%= op_icon("button--icon icon-#{@backup_token.present? ? 'reload' : 'add'}") %> - <%= t('backup.label_backup_token') %> - <% end %> -
  • - <% if @backup_token.present? %> -
  • - <% label = t("backup.label_delete_token") %> - <%= - link_to( - { action: 'delete_token' }, - method: :post, - class: 'button -primary', - aria: {label: label}, - title: label - ) do - %> - <%= op_icon("button--icon icon-delete") %> - <%= t('backup.label_backup_token') %> - <% end %> -
  • - <% end %> -<% end %> +<%= render Admin::Backups::ShowPageHeaderComponent.new(backup_token: @backup_token) %>

    <%= t("backup.reset_token.info") %> diff --git a/app/views/admin/settings/work_packages_settings/show.html.erb b/app/views/admin/settings/work_packages_settings/show.html.erb index 3baa0765efe3..24865fffc3c2 100644 --- a/app/views/admin/settings/work_packages_settings/show.html.erb +++ b/app/views/admin/settings/work_packages_settings/show.html.erb @@ -38,12 +38,11 @@ See COPYRIGHT and LICENSE files for more details. end %> - - <%= styled_form_tag({ action: :update }, method: :patch) do %>

    + data-controller="admin--work-packages-settings" + data-admin--work-packages-settings-percent-complete-edition-active-value="<%= OpenProject::FeatureDecisions.percent_complete_edition_active? %>">
    <%= setting_check_box :cross_project_work_package_relations %>
    <%= setting_check_box :display_subprojects_work_packages %>
    <%= setting_check_box :work_package_startdate_is_adddate %>
    @@ -53,7 +52,14 @@ See COPYRIGHT and LICENSE files for more details. container_class: "-middle", data: { admin__work_packages_settings_target: "progressCalculationModeSelect", action: "change->admin--work-packages-settings#displayWarning" } %> -
    <%= t("setting_work_package_done_ratio_explanation_html") %>
    +
    <%= + if OpenProject::FeatureDecisions.percent_complete_edition_active? + t("setting_work_package_done_ratio_explanation_html") + else + # This condition branch to be removed in 15.0 with :percent_complete_edition feature flag removal + t("setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html") + end + %>
    @@ -69,14 +68,15 @@ See COPYRIGHT and LICENSE files for more details. <%= f.text_field :lastname, required: true, container_class: '-middle', disabled: login_via_provider || login_via_ldap %> <% if login_via_provider %> <%= t('user.text_change_disabled_for_provider_login') %> - <% end %> - <% if login_via_ldap %> + <% elsif login_via_ldap %> <%= t('user.text_change_disabled_for_ldap_login') %> <% end %>
    <%= f.text_field :mail, required: true, container_class: '-middle', disabled: login_via_ldap %> - <% if login_via_ldap %> + <% if login_via_provider %> + <%= t('user.text_change_disabled_for_provider_login') %> + <% elsif login_via_ldap %> <%= t('user.text_change_disabled_for_ldap_login') %> <% end %>
    diff --git a/app/views/projects/_toolbar.html.erb b/app/views/projects/_toolbar.html.erb index fbfa41072e26..a9f699a27294 100644 --- a/app/views/projects/_toolbar.html.erb +++ b/app/views/projects/_toolbar.html.erb @@ -47,7 +47,7 @@ See COPYRIGHT and LICENSE files for more details. <% if @project.copy_allowed? %>
  • - <%= link_to copy_project_path(@project), class: 'button copy', accesskey: accesskey(:copy) do %> + <%= link_to copy_project_path(@project), class: 'button copy', accesskey: accesskey(:copy), data: { turbo: false } do %> <%= op_icon('button--icon icon-copy') %> <%= t(:button_copy) %> <% end %> diff --git a/app/workers/work_packages/progress/apply_statuses_change_job.rb b/app/workers/work_packages/progress/apply_statuses_change_job.rb index 4a29583b0b35..affb1979cea7 100644 --- a/app/workers/work_packages/progress/apply_statuses_change_job.rb +++ b/app/workers/work_packages/progress/apply_statuses_change_job.rb @@ -58,18 +58,27 @@ def perform(cause_type:, status_name: nil, status_id: nil, changes: nil) @changes = changes with_temporary_progress_table do - if WorkPackage.use_status_for_done_ratio? - set_p_complete_from_status - derive_remaining_work_from_work_and_p_complete - end + adjust_progress_values update_totals - copy_progress_values_to_work_packages_and_update_journals(journal_cause) end end private + def adjust_progress_values + if WorkPackage.work_based_mode? + clear_percent_complete_when_0h_work + elsif WorkPackage.status_based_mode? + set_p_complete_from_status + if OpenProject::FeatureDecisions.percent_complete_edition_active? + fix_remaining_work_set_with_100p_complete + derive_unset_work_from_remaining_work_and_p_complete + end + derive_remaining_work_from_work_and_p_complete + end + end + def journal_cause assert_valid_cause_type! @@ -109,4 +118,12 @@ def assert_status_information_present! raise ArgumentError, "changes must be provided" end end + + def clear_percent_complete_when_0h_work + execute(<<~SQL.squish) + UPDATE temp_wp_progress_values + SET done_ratio = NULL + WHERE estimated_hours = 0 + SQL + end end diff --git a/app/workers/work_packages/progress/migrate_values_job.rb b/app/workers/work_packages/progress/migrate_values_job.rb index 04f9d741d05a..6fcf14aad81c 100644 --- a/app/workers/work_packages/progress/migrate_values_job.rb +++ b/app/workers/work_packages/progress/migrate_values_job.rb @@ -76,17 +76,6 @@ def unset_all_percent_complete_values SQL end - def fix_remaining_work_set_with_100p_complete - execute(<<~SQL.squish) - UPDATE temp_wp_progress_values - SET estimated_hours = remaining_hours, - remaining_hours = 0 - WHERE estimated_hours IS NULL - AND remaining_hours IS NOT NULL - AND done_ratio = 100 - SQL - end - def fix_remaining_work_exceeding_work execute(<<~SQL.squish) UPDATE temp_wp_progress_values @@ -133,20 +122,6 @@ def derive_unset_remaining_work_from_work_and_p_complete SQL end - def derive_unset_work_from_remaining_work_and_p_complete - execute(<<~SQL.squish) - UPDATE temp_wp_progress_values - SET estimated_hours = - CASE done_ratio - WHEN 0 THEN remaining_hours - ELSE ROUND((remaining_hours * 100 / (100 - done_ratio))::numeric, 2) - END - WHERE estimated_hours IS NULL - AND remaining_hours IS NOT NULL - AND done_ratio IS NOT NULL - SQL - end - def derive_p_complete_from_work_and_remaining_work execute(<<~SQL.squish) UPDATE temp_wp_progress_values diff --git a/app/workers/work_packages/progress/sql_commands.rb b/app/workers/work_packages/progress/sql_commands.rb index 5ae49386fd40..b00763d1098f 100644 --- a/app/workers/work_packages/progress/sql_commands.rb +++ b/app/workers/work_packages/progress/sql_commands.rb @@ -83,6 +83,31 @@ def set_p_complete_from_status SQL end + def fix_remaining_work_set_with_100p_complete + execute(<<~SQL.squish) + UPDATE temp_wp_progress_values + SET estimated_hours = remaining_hours, + remaining_hours = 0 + WHERE estimated_hours IS NULL + AND remaining_hours IS NOT NULL + AND done_ratio = 100 + SQL + end + + def derive_unset_work_from_remaining_work_and_p_complete + execute(<<~SQL.squish) + UPDATE temp_wp_progress_values + SET estimated_hours = + CASE done_ratio + WHEN 0 THEN remaining_hours + ELSE ROUND((remaining_hours * 100 / (100 - done_ratio))::numeric, 2) + END + WHERE estimated_hours IS NULL + AND remaining_hours IS NOT NULL + AND done_ratio IS NOT NULL + SQL + end + # Computes total work, total remaining work and total % complete for all work # packages having children. def update_totals diff --git a/config/locales/crowdin/af.yml b/config/locales/crowdin/af.yml index 3840bb1bb197..2e44ea426ef8 100644 --- a/config/locales/crowdin/af.yml +++ b/config/locales/crowdin/af.yml @@ -1040,10 +1040,10 @@ af: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1073,15 +1073,17 @@ af: does_not_exist: "Die spesefieke kategorie bestaan nie." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ af: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ af: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ af: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Opmerking" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/ar.yml b/config/locales/crowdin/ar.yml index 75d52bc5fd81..9494864a26f2 100644 --- a/config/locales/crowdin/ar.yml +++ b/config/locales/crowdin/ar.yml @@ -1068,10 +1068,10 @@ ar: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "ليس في تاريخ البدء، وعلى الرغم من أن هذا المطلوب للمعالم." @@ -1101,15 +1101,17 @@ ar: does_not_exist: "الفئة المحددة غير موجودة." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1800,7 +1802,8 @@ ar: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3263,8 +3266,10 @@ ar: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "خصائص مجموعة العمل" setting_work_package_startdate_is_adddate: "استخدام التاريخ الحالي كتاريخ البدء لمجموعات العمل الجديدة" setting_work_packages_projects_export_limit: "حد تصدير حزم العمل / المشاريع" @@ -3651,9 +3656,26 @@ ar: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "تعليق" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/az.yml b/config/locales/crowdin/az.yml index a262fd9995db..187327f6e154 100644 --- a/config/locales/crowdin/az.yml +++ b/config/locales/crowdin/az.yml @@ -1040,10 +1040,10 @@ az: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1073,15 +1073,17 @@ az: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ az: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ az: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ az: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comment" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/be.yml b/config/locales/crowdin/be.yml index 491c89a56aab..3a89b5721d57 100644 --- a/config/locales/crowdin/be.yml +++ b/config/locales/crowdin/be.yml @@ -1054,10 +1054,10 @@ be: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1087,15 +1087,17 @@ be: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1730,7 +1732,8 @@ be: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3191,8 +3194,10 @@ be: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3577,9 +3582,26 @@ be: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comment" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/bg.yml b/config/locales/crowdin/bg.yml index 828333e8ab34..e449214a6517 100644 --- a/config/locales/crowdin/bg.yml +++ b/config/locales/crowdin/bg.yml @@ -1040,10 +1040,10 @@ bg: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Изисква се, когато е зададена Оставаща работа." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "не е на начална дата, въпреки че това е необходимо за важни събития." @@ -1073,15 +1073,17 @@ bg: does_not_exist: "Определената категория не съществува." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Не може да бъде по-ниско от Оставащата работа." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Не може да бъде по-високо от Работа." - must_be_set_when_work_is_set: "Изисква се, когато е зададена Работа." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Работният пакет е в състояние само за четене, така че атрибутите му не могат да бъдат променяни." type: attributes: @@ -1660,7 +1662,8 @@ bg: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ bg: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ bg: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Коментар" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/ca.yml b/config/locales/crowdin/ca.yml index 46d851f420e4..2ca0e9078d98 100644 --- a/config/locales/crowdin/ca.yml +++ b/config/locales/crowdin/ca.yml @@ -1036,10 +1036,10 @@ ca: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "no és la data d'inici, tot i que és necessari per a les fites." @@ -1069,15 +1069,17 @@ ca: does_not_exist: "La categoria especificada no existeix." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "No pot ser inferior al treball restant." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "El paquet de treball està en un estat de només lectura, per això els seus atributs no poden ser modificats." type: attributes: @@ -1656,7 +1658,8 @@ ca: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3106,8 +3109,10 @@ ca: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Propietats de paquet de treball" setting_work_package_startdate_is_adddate: "Utilitzar la data actual com a data d'inici dels paquets de treball nous" setting_work_packages_projects_export_limit: "Límit d'exportació de paquets de treball/projectes" @@ -3490,9 +3495,26 @@ ca: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comentari" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/ckb-IR.yml b/config/locales/crowdin/ckb-IR.yml index 396097831e26..312b45ca7129 100644 --- a/config/locales/crowdin/ckb-IR.yml +++ b/config/locales/crowdin/ckb-IR.yml @@ -1040,10 +1040,10 @@ ckb-IR: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1073,15 +1073,17 @@ ckb-IR: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ ckb-IR: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ ckb-IR: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ ckb-IR: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comment" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/cs.yml b/config/locales/crowdin/cs.yml index 8a96da96b29d..72f8d5b2bffb 100644 --- a/config/locales/crowdin/cs.yml +++ b/config/locales/crowdin/cs.yml @@ -273,7 +273,7 @@ cs: favored: "Oblíbené projekty" archived: "Archivované projekty" shared: "Sdílené seznamy projektů" - my_lists: "My project lists" + my_lists: "Moje seznamy projektů" new: placeholder: "Nový seznam projektů" delete_modal: @@ -462,7 +462,7 @@ cs: irreversible: "Tato akce je nevratná" confirmation: "Zadejte název zástupného uživatele %{name} pro potvrzení odstranění." upsale: - title: placeholder uživatel + title: Placeholder uživatel description: > Placeholder uživatelé jsou způsob, jak přiřadit pracovní balíčky uživatelům, kteří nejsou součástí vašeho projektu. Mohou být užiteční v řadě scénářů; například, pokud potřebujete sledovat úkoly u zdroje, který ještě nejsou pojmenovány nebo dostupné, nebo pokud nechcete této osobě umožnit přístup k OpenProject ale stále chcete sledovat úkoly, které jim byly přiděleny. prioritiies: @@ -496,7 +496,7 @@ cs: is_readonly: "Pouze pro čtení" excluded_from_totals: "Vyloučeno z celkových hodnot" themes: - dark: "Dark (Beta)" + dark: "Tmavý (Beta)" light: "Světlý" light_high_contrast: "Světlý kontrast" types: @@ -684,7 +684,7 @@ cs: false: "archivováno" identifier: "Identifikátor" latest_activity_at: "Poslední aktivita" - parent: "Podprojekt" + parent: "Nadřazený projekt" public_value: title: "Viditelnost" true: "veřejný" @@ -729,7 +729,7 @@ cs: is_closed: "Pracovní balíček uzavřen" is_readonly: "Pracovní balíček jen pro čtení" excluded_from_totals: "Exclude from calculation of totals in hierarchy" - default_done_ratio: "% Complete" + default_done_ratio: "% Dokončeno" time_entry: activity: "Aktivita" hours: "Hodiny" @@ -790,7 +790,7 @@ cs: true: "zahrnuje nepracovní dny" notify: "Oznámit" #used in custom actions parent: "Nadřazený" - parent_issue: "Rodič" + parent_issue: "Nadřazený" parent_work_package: "Nadřazený" priority: "Priorita" progress: "% Dokončeno" @@ -920,7 +920,7 @@ cs: blank: "je povinné. Zvolte prosím název." not_unique: " už bylo použito. Prosím vyberte jiný název." notifications: - at_least_one_channel: "Alespoň jeden kanál pro odesílání oznámení musí být specifikován." + at_least_one_channel: "Pro odesílání notifikací musí být specifikován alespoň jeden kanál" attributes: read_ian: read_on_creation: "nelze nastavit na pravdivé při vytváření oznámení " @@ -1054,10 +1054,10 @@ cs: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "není v počátečním datu, i když je to nutné pro milníky." @@ -1087,15 +1087,17 @@ cs: does_not_exist: "Zadaná kategorie neexistuje." estimated_hours: not_a_number: "není platná doba trvání." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "není platná doba trvání." - cant_exceed_work: "Nemůže být vyšší než Práce." - must_be_set_when_work_is_set: "Vyžadováno, když je nastavena práce." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Pracovní balíček je ve stavu jen pro čtení, takže jeho atributy nelze změnit." type: attributes: @@ -1170,11 +1172,11 @@ cs: member: "Člen" news: "Novinky" notification: - one: "Oznámení" - few: "Oznámení" - many: "Oznámení" - other: "Oznámení" - placeholder_user: "placeholder uživatel" + one: "Notifikace" + few: "Notifikací" + many: "Notifikací" + other: "Notifikace" + placeholder_user: "Placeholder uživatel" project: "Projekt" project_query: one: "Seznam projektů" @@ -1721,7 +1723,7 @@ cs: title: "Export" submit: "Export" format: - label: "File format" + label: "Formát souboru" options: csv: label: "CSV" @@ -1730,32 +1732,33 @@ cs: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: - label: "PDF export type" + label: "Typ exportu do PDF" options: table: - label: "Table" + label: "Tabulka" caption: "Export the work packages list in a table with the desired columns." report: label: "Report" caption: "Export the work package on a detailed report of all work packages in the list." gantt: - label: "Gantt chart" + label: "Ganttův diagram" caption: "Export the work packages list in a Gantt diagram view." include_images: - label: "Include images" + label: "Včetně obrázků" caption: "Exclude images to reduce the size of the PDF export." gantt_zoom_levels: - label: "Zoom levels" + label: "Úrovně přiblížení" caption: "Select what is the zoom level for dates displayed in the chart." options: - days: "Days" - weeks: "Weeks" - months: "Months" - quarters: "Quarters" + days: "Dny" + weeks: "Týdny" + months: "Měsíce" + quarters: "Čtvrtletí" column_width: label: "Table column width" options: @@ -1887,7 +1890,7 @@ cs: instructions_after_error: "Zkuste se znovu přihlásit kliknutím na %{signin}. Pokud chyba přetrvává, požádejte správce o pomoc." menus: admin: - mail_notification: "E-mailová upozornění" + mail_notification: "E-mailové notifikace" mails_and_notifications: "E-maily a oznámení" aggregation: "Agregace" api_and_webhooks: "API & Webhooky" @@ -1950,7 +1953,7 @@ cs: by_project: "Nepřečteno dle projektu" by_reason: "Důvod" inbox: "Doručená pošta" - send_notifications: "Odeslat oznámení pro tuto akci" + send_notifications: "Pro tuto akci odeslat notifikaci" work_packages: subject: created: "Pracovní balíček byl vytvořen." @@ -2010,7 +2013,7 @@ cs: label_ldap_auth_source_plural: "Připojení LDAP" label_attribute_expand_text: "Úplný text pro '%{attribute}'" label_authentication: "Ověření" - label_authentication_settings: "Authentication settings" + label_authentication_settings: "Nastavení ověření" label_available_global_roles: "Dostupné globální role" label_available_project_attributes: "Dostupné atributy projektu" label_available_project_forums: "Dostupná fóra" @@ -2208,7 +2211,7 @@ cs: label_introduction_video: "Seznamovací video" label_invite_user: "Pozvat uživatele" label_share: "Sdílet" - label_share_project_list: "Share project list" + label_share_project_list: "Sdílet seznam projektů" label_share_work_package: "Sdílet pracovní balíček" label_show_hide: "Zobrazit/skrýt" label_show_hide_n_items: "Show/hide %{count} items" @@ -2305,8 +2308,8 @@ cs: label_next_week: "Příští týden" label_no_change_option: "(Beze změny)" label_no_data: "Žádná data k zobrazení" - label_no_due_date: "no finish date" - label_no_start_date: "no start date" + label_no_due_date: "žádné datum dokončení" + label_no_start_date: "žádné datum začátku" label_no_parent_page: "Žádná nadřazená stránka" label_nothing_display: "Nic k zobrazení" label_nobody: "nikdo" @@ -2343,9 +2346,9 @@ cs: label_permissions: "Práva" label_permissions_report: "Přehled oprávnění" label_personalize_page: "Přizpůsobit tuto stránku" - label_placeholder_user: "placeholder uživatel" + label_placeholder_user: "Placeholder uživatel" label_placeholder_user_new: "" - label_placeholder_user_plural: "placeholder uživatelé" + label_placeholder_user_plural: "Placeholder uživatelé" label_planning: "Plánování" label_please_login: "Přihlaste se prosím" label_plugins: "Pluginy" @@ -2367,7 +2370,7 @@ cs: label_project_attribute_plural: "Atributy projektu" label_project_attribute_manage_link: "Správa atributů produktu" label_project_count: "Celkový počet projektů" - label_project_copy_notifications: "Během kopie projektu odeslat oznámení e-mailem" + label_project_copy_notifications: "Během kopírování projektu odeslat notifikace e-mailem" label_project_latest: "Nejnovější projekty" label_project_default_type: "Povolit prázdný typ" label_project_hierarchy: "Hierarchie projektu" @@ -2432,7 +2435,7 @@ cs: label_role_search: "Přiřadit roli novým členům" label_scm: "SCM" label_search: "Vyhledávání" - label_search_by_name: "Search by name" + label_search_by_name: "Hledat podle názvu" label_send_information: "Poslat nové přihlašovací údaje uživateli" label_send_test_email: "Odeslat testovací email" label_session: "Relace" @@ -2507,7 +2510,7 @@ cs: label_users_settings: "Uživatelská nastavení" label_version_new: "Nová verze" label_version_plural: "Verze" - label_version_sharing_descendants: "S Podprojekty" + label_version_sharing_descendants: "S podprojekty" label_version_sharing_hierarchy: "S hierarchií projektu" label_version_sharing_none: "Není sdíleno" label_version_sharing_system: "Se všemi projekty" @@ -2545,7 +2548,7 @@ cs: label_work_package_new: "Nový pracovní balíček" label_work_package_edit: "Upravit pracovní balíček %{name}" label_work_package_plural: "Pracovní balíčky" - label_work_packages_settings: "Work packages settings" + label_work_packages_settings: "Nastavení pracovních balíčků" label_work_package_status: "Stav pracovního balíčku" label_work_package_status_new: "Nový stav" label_work_package_status_plural: "Stav pracovního balíčku" @@ -2613,28 +2616,28 @@ cs: digests: including_mention_singular: "včetně zmínky" including_mention_plural: "včetně %{number_mentioned} zmínění" - unread_notification_singular: "1 nepřečtené oznámení" - unread_notification_plural: "%{number_unread} nepřečtených oznámení" + unread_notification_singular: "1 nepřečtená notifikace" + unread_notification_plural: "%{number_unread} nepřečtených notifikací" you_have: "Máte" logo_alt_text: "Logo" mention: subject: "%{user_name} vás zmínil v #%{id} - %{subject}" notification: - center: "Centrum oznámení" + center: "Centrum notifikací" see_in_center: "Zobrazit komentář v oznamovacím centru" settings: "Změnit nastavení e-mailu" salutation: "Ahoj %{user}!" salutation_full_name: "Jméno a příjmení" work_packages: created_at: "Vytvořeno v %{timestamp} uživatelem %{user} " - login_to_see_all: "Přihlaste se pro zobrazení všech oznámení." + login_to_see_all: "Přihlaste se pro zobrazení všech notifikací." mentioned: "Byli jste zmíněni v komentáři" mentioned_by: "%{user} vás zmínil v komentáři" more_to_see: - one: "Existuje ještě 1 pracovní balíček s oznámeními." - few: "Existuje ještě %{count} pracovních balíčků s oznámeními." - many: "Existuje ještě %{count} pracovních balíčků s oznámeními." - other: "Existuje ještě %{count} pracovních balíčků s oznámeními." + one: "Existuje ještě 1 pracovní balíček s notifikací." + few: "Existuje ještě %{count} pracovních balíčků s notifikacema." + many: "Existuje ještě %{count} pracovních balíčků s notifikacema." + other: "Existuje ještě %{count} pracovních balíčků s notifikacema." open_in_browser: "Otevřít v prohlížeči" reason: watched: "Sledováno" @@ -2643,7 +2646,7 @@ cs: mentioned: "Zmíněné" shared: "Sdílené" subscribed: "vše" - prefix: "Obdrženo z důvodu nastavení oznámení: %{reason}" + prefix: "Obdrženo z důvodu nastavení notifikací: %{reason}" date_alert_start_date: "Upozornění na datum" date_alert_due_date: "Upozornění na datum" see_all: "Zobrazit vše" @@ -2891,7 +2894,7 @@ cs: permission_edit_own_messages: "Upravit vlastní zprávy" permission_edit_own_time_entries: "Upravit vlastní časové záznamy" permission_edit_project: "Upravit projekt" - permission_edit_project_attributes: "Edit project attributes" + permission_edit_project_attributes: "Úprava atributů projektu" permission_edit_reportings: "Upravit přehledy" permission_edit_time_entries: "Upravit časové záznamy pro ostatní uživatele" permission_edit_timelines: "Úpravy časové osy" @@ -2917,7 +2920,7 @@ cs: permission_move_work_packages: "Přesun pracovních balíčků" permission_protect_wiki_pages: "Ochrana stránky wiki" permission_rename_wiki_pages: "Přejmenovat stránky wiki" - permission_save_queries: "Uložit pohled" + permission_save_queries: "Uložit zobrazení" permission_search_project: "Hledat projekt" permission_select_custom_fields: "Vybrat vlastní pole" permission_select_project_custom_fields: "Vyberte atributy projektu" @@ -2942,7 +2945,7 @@ cs: permission_work_package_assigned: "Staňte se řešitelem/odpovědným" permission_work_package_assigned_explanation: "Pracovní balíčky mohou být přiřazeny uživatelům a skupinám, které tuto roli vlastní v příslušném projektu" permission_view_project_activity: "Zobrazit aktivitu projektu" - permission_view_project_attributes: "View project attributes" + permission_view_project_attributes: "Zobrazit atributy projektu" permission_save_bcf_queries: "Uložit dotazy BCF" permission_manage_public_bcf_queries: "Spravovat veřejné dotazy BCF." permission_edit_attribute_help_texts: "Upravit text nápovědy atributu" @@ -3169,9 +3172,9 @@ cs: setting_default_projects_public: "Nové projekty nastavovat jako veřejné" setting_diff_max_lines_displayed: "Maximální počet zobrazených řádků rozdílu" setting_display_subprojects_work_packages: "Automaticky zobrazit úkoly podprojektu v hlavním projektu" - setting_duration_format: "Duration format" - setting_duration_format_hours_only: "Hours only" - setting_duration_format_days_and_hours: "Days and hours" + setting_duration_format: "Formát doby trvání" + setting_duration_format_hours_only: "Pouze hodiny" + setting_duration_format_days_and_hours: "Dny a hodiny" setting_duration_format_instructions: "This defines how Work, Remaining work, and Time spent durations are displayed." setting_emails_footer: "Zápatí emailů" setting_emails_header: "Záhlaví emailů" @@ -3190,8 +3193,10 @@ cs: setting_work_package_done_ratio: "Výpočet průběhu" setting_work_package_done_ratio_field: "Na základě práce" setting_work_package_done_ratio_status: "Na základě stavu" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Vlastnosti pracovního balíčku" setting_work_package_startdate_is_adddate: "Použít aktuální datum jako počáteční datum pro nové úkoly" setting_work_packages_projects_export_limit: "Limit exportu pracovních balíčků / projektů" @@ -3294,7 +3299,7 @@ cs: enable_subscriptions_text_html: Umožňuje uživatelům s nezbytnými oprávněními přihlásit se do OpenProject kalendářů a získat přístup k informacím o pracovním balíčku prostřednictvím externího klienta kalendáře. Poznámka: Před povolením si prosím přečtěte iCalendar předplatné. language_name_being_default: "%{language_name} (výchozí)" notifications: - events_explanation: "Určuje, pro kterou událost je odeslán e-mail. Pracovní balíčky jsou z tohoto seznamu vyloučeny, protože oznámení pro ně mohou být nastavena speciálně pro každého uživatele." + events_explanation: "Určuje, pro kterou událost je odeslán e-mail. Pracovní balíčky jsou z tohoto seznamu vyloučeny, protože notifikace pro ně mohou být nastavena speciálně pro každého uživatele." delay_minutes_explanation: "Odesílání e-mailu může být pozdrženo, aby bylo uživatelům s nakonfigurovaným v oznámení aplikace před odesláním pošty potvrzeno oznámení. Uživatelé, kteří si přečtou oznámení v aplikaci, nedostanou e-mail pro již přečtené oznámení." other: "Ostatní" passwords: "Hesla" @@ -3379,7 +3384,7 @@ cs: text_destroy_with_associated: "Existují další objekty, které jsou přiřazeny k pracovním balíčkům a které mají být odstraněny. Tyto objekty jsou následující typy:" text_destroy_what_to_do: "Co chcete udělat?" text_diff_truncated: "... Toto rozlišení bylo zkráceno, protože přesahuje maximální velikost, kterou lze zobrazit." - text_email_delivery_not_configured: "Doručení e-mailu není nakonfigurováno a oznámení jsou zakázána.\nNakonfigurujte váš SMTP server pro jejich povolení." + text_email_delivery_not_configured: "Doručení e-mailu není nakonfigurováno a notifikace jsou zakázány.\nNakonfigurujte váš SMTP server pro jejich povolení." text_enumeration_category_reassign_to: "Přiřadit je k této hodnotě:" text_enumeration_destroy_question: "%{count} objektů je přiřazeno k této hodnotě." text_file_repository_writable: "Do adresáře příloh lze zapisovat" @@ -3575,9 +3580,26 @@ cs: progress: label_note: "Poznámka:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Komentář" comment_description: "Může zobrazit a komentovat tento pracovní balíček." diff --git a/config/locales/crowdin/da.yml b/config/locales/crowdin/da.yml index d1e1934bac14..cd069d10f239 100644 --- a/config/locales/crowdin/da.yml +++ b/config/locales/crowdin/da.yml @@ -1038,10 +1038,10 @@ da: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "er ikke på startdato, selvom dette er påkrævet for milepæle." @@ -1071,15 +1071,17 @@ da: does_not_exist: "Den angivne kategori findes ikke." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1658,7 +1660,8 @@ da: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3113,8 +3116,10 @@ da: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Egenskaber for arbejdspakke" setting_work_package_startdate_is_adddate: "Brug dags dato som start for nye arbejdspakker" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3497,9 +3502,26 @@ da: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Kommentér" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/de.yml b/config/locales/crowdin/de.yml index 3ff3bfaa2abd..65cbe6b291d7 100644 --- a/config/locales/crowdin/de.yml +++ b/config/locales/crowdin/de.yml @@ -48,7 +48,7 @@ de: main-menu-border-color: "Rahmenfarbe des Hauptmenüs" custom_colors: "Benutzerdefinierte Farben" customize: "Passen Sie Ihre OpenProject Installation mit Ihrem eigenen Logo und eigenen Farben an." - enterprise_notice: "Diese kleine Erweiterung steht den Abonnenten der Enterprise edition ganz exklusiv als kleines Dankeschön für deren finanzielle Unterstützung zur Verfügung." + enterprise_notice: "Dieses kleine Add-on steht den Abonnenten der Enterprise-Edition ganz exklusiv als kleines Dankeschön für deren finanzielle Unterstützung zur Verfügung." enterprise_more_info: "Hinweis: Das verwendete Logo wird öffentlich zugänglich sein." manage_colors: "Farbauswahloptionen bearbeiten" instructions: @@ -61,15 +61,15 @@ de: main-menu-bg-color: "Hintergrundfarbe des Menüs in der linken Seitenleiste." theme_warning: Das Ändern des Themes wird Ihr benutzerdefiniertes Design überschreiben. Alle Änderungen werden dann verloren gehen. Sind Sie sicher, dass Sie fortfahren möchten? enterprise: - upgrade_to_ee: "Auf Enterprise edition upgraden" - add_token: "Enterprise edition Support Token hochladen" + upgrade_to_ee: "Auf Enterprise-Edition upgraden" + add_token: "Enterprise-Edition Support Token hochladen" delete_token_modal: - text: "Sind Sie sicher, dass Sie das aktuelle Enterprise edition token entfernen möchten?" + text: "Sind Sie sicher, dass Sie das aktuelle Enterprise Edition-Token entfernen möchten?" title: "Token löschen" replace_token: "Aktuellen Enterprise edition Support Token ersetzen" order: "Enterprise on-premises bestellen" - paste: "Enterprise edition Support Token hier einfügen" - required_for_feature: "Dieses Add-on ist nur mit einem aktiven Enterprise edition Support-Token verfügbar." + paste: "Enterprise-Edition Support Token hier einfügen" + required_for_feature: "Dieses Add-on ist nur mit einem aktiven Enterprise-Edition Support-Token verfügbar." enterprise_link: "Klicken Sie hier für weitere Informationen." start_trial: "Kostenlose Testversion starten" book_now: "Jetzt buchen" @@ -1034,10 +1034,10 @@ de: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "stimmt nicht mit Aufwand und Verbleibender Aufwand überein" - cannot_be_set_when_work_is_zero: "kann nicht eingestellt werden, wenn Aufwand gleich Null ist" - must_be_set_when_remaining_work_is_set: "Ist erforderlich, wenn Verbleibender Aufwand gesetzt ist." - must_be_set_when_work_and_remaining_work_are_set: "Ist erforderlich, wenn Aufwand und Verbleibender Aufwand gesetzt ist." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "muss zwischen 0 und 100 liegen." due_date: not_start_date: "ist nicht identisch mit dem Startdatum, obwohl dies bei Meilensteinen Pflicht ist." @@ -1067,15 +1067,17 @@ de: does_not_exist: "Die angegebene Kategorie existiert nicht." estimated_hours: not_a_number: "ist keine gültige Dauer." - cant_be_inferior_to_remaining_work: "Kann nicht niedriger sein als Verbleibender Aufwand." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Erforderlich, wenn Verbleibender Aufwand und % abgeschlossen eingestellt sind." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "ist keine gültige Dauer." - cant_exceed_work: "Kann nicht größer als der Aufwand sein." - must_be_set_when_work_is_set: "Ist erforderlich, wenn Aufwand gesetzt ist." - must_be_set_when_work_and_percent_complete_are_set: "Erforderlich, wenn Aufwand und % abgeschlossen eingestellt sind." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Das Arbeitspaket befindet sich in einem schreibgeschützten Status, so dass seine Attribute nicht geändert werden können." type: attributes: @@ -1589,7 +1591,7 @@ de: error_cookie_missing: "Das OpenProject Cookie fehlt. Bitte stellen Sie sicher, dass Cookies aktiviert sind, da diese Applikation ohne aktivierte Cookies nicht korrekt funktioniert." error_custom_option_not_found: "Option ist nicht vorhanden." error_enterprise_activation_user_limit: "Ihr Konto konnte nicht aktiviert werden (Nutzerlimit erreicht). Bitte kontaktieren Sie Ihren Administrator um Zugriff zu erhalten." - error_enterprise_token_invalid_domain: "Die Enterprise edition ist nicht aktiv. Die aktuelle Domain (%{actual}) entspricht nicht dem erwarteten Hostnamen (%{expected})." + error_enterprise_token_invalid_domain: "Die Enterprise-Edition ist nicht aktiv. Die aktuelle Domain (%{actual}) entspricht nicht dem erwarteten Hostnamen (%{expected})." error_failed_to_delete_entry: "Fehler beim Löschen dieses Eintrags." error_in_dependent: "Fehler beim Versuch, abhängiges Objekt zu ändern: %{dependent_class} #%{related_id} - %{related_subject}: %{error}" error_in_new_dependent: "Fehler beim Versuch, abhängiges Objekt zu erstellen: %{dependent_class} - %{related_subject}: %{error}" @@ -1654,7 +1656,8 @@ de: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -1753,10 +1756,10 @@ de: blocks: community: "OpenProject Community" upsale: - title: "Auf Enterprise edition upgraden" + title: "Auf Enterprise-Edition upgraden" more_info: "Weitere Informationen" links: - upgrade_enterprise_edition: "Auf Enterprise edition upgraden" + upgrade_enterprise_edition: "Auf Enterprise-Edition upgraden" postgres_migration: "Migration Ihrer Installation zu PostgreSQL" user_guides: "Benutzerhandbuch" faq: "Häufig gestellte Fragen" @@ -1790,7 +1793,7 @@ de: dates: working: "%{date} ist jetzt ein Arbeitstag" non_working: "%{date} ist jetzt ein arbeitsfreier Tag" - progress_mode_changed_to_status_based: Fortschrittberechnung wurde auf Status-basiert gesetzt + progress_mode_changed_to_status_based: Fortschrittberechnung wurde auf Status-bezogen gesetzt status_excluded_from_totals_set_to_false_message: jetzt in den Gesamtwerten der Hierarchie enthalten status_excluded_from_totals_set_to_true_message: jetzt von den Hierarchie-Gesamtwerten ausgeschlossen status_percent_complete_changed: "% vollständig von %{old_value}% auf %{new_value} % geändert" @@ -2062,7 +2065,7 @@ de: label_enumerations: "Aufzählungen" label_enterprise: "Enterprise" label_enterprise_active_users: "%{current}/%{limit} gebuchte aktive Nutzer" - label_enterprise_edition: "Enterprise edition" + label_enterprise_edition: "Enterprise Edition" label_enterprise_support: "Enterprise Support" label_enterprise_addon: "Enterprise Add-on" label_environment: "Umgebung" @@ -3006,8 +3009,8 @@ de: update_timeout: "Speichere die Informationen bzgl. des genutzten Festplattenspeichers eines Projektarchivs für N Minuten.\nErhöhen Sie diesen Wert zur Verbesserung der Performance, da die Erfassung des genutzten Festplattenspeichers Ressourcen-intensiv ist." oauth_application_details: "Der Client Geheimcode wird nach dem Schließen dieses Fensters nicht mehr zugänglich sein. Bitte kopieren Sie diese Werte in die Nextcloud OpenProject Integrationseinstellungen:" oauth_application_details_link_text: "Zu den Einstellungen gehen" - setup_documentation_details: "Wenn Sie Hilfe bei der Konfiguration eines neuen Datei-Speichers benötigen, konsultieren Sie bitte die Dokumentation: " - setup_documentation_details_link_text: "Datei-Speicher einrichten" + setup_documentation_details: "Wenn Sie Hilfe bei der Konfiguration eines neuen Dateispeichers benötigen, konsultieren Sie bitte die Dokumentation: " + setup_documentation_details_link_text: "Dateispeicher einrichten" show_warning_details: "Um diesen Dateispeicher nutzen zu können, müssen Sie das Modul und den spezifischen Speicher in den Projekteinstellungen jedes gewünschten Projekts aktivieren." subversion: existing_title: "Vorhandenes Subversion Projektarchiv" @@ -3111,8 +3114,10 @@ de: setting_work_package_done_ratio: "Fortschrittsberechnung" setting_work_package_done_ratio_field: "Arbeitsbezogen" setting_work_package_done_ratio_status: "Statusbezogen" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - Im aufwandsbezogenen Modus wird % Abgeschlossen durch das Verhältnis zu, Gesamtaufwand berechnet. Im statusbezogenen Modus ist mit jedem Status ein fester Wert für % Abgeschlossen verbunden. Wenn Sie den Status ändern, ändert sich dadurch auch das % Abgeschlossen Attribut. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Arbeitspaket-Eigenschaften" setting_work_package_startdate_is_adddate: "Neue Arbeitspakete haben \"Heute\" als Anfangsdatum" setting_work_packages_projects_export_limit: "Arbeitspakete / Exportlimit für Projekte" @@ -3465,7 +3470,7 @@ de: warning_user_limit_reached_admin: > Das Hinzufügen zusätzlicher Benutzer überschreitet das aktuelle Benutzerlimit. Bitte aktualisieren Sie Ihr Abonnement um sicherzustellen, dass externe Benutzer auf diese Instanz zugreifen können. warning_user_limit_reached_instructions: > - Du hast dein Nutzerlimit erreicht (%{current}/%{max} active users). Bitte kontaktiere sales@openproject.com um deinen Enterprise edition Plan upzugraden und weitere Nutzer hinzuzufügen. + Du hast dein Nutzerlimit erreicht (%{current}/%{max} active users). Bitte kontaktiere sales@openproject.com um deinen Enterprise Edition Plan upzugraden und weitere Nutzer hinzuzufügen. warning_protocol_mismatch_html: > warning_bar: @@ -3494,9 +3499,26 @@ de: progress: label_note: "Hinweis:" modal: - work_based_help_text: "% Abgeschlossen wird automatisch aus Aufwand und Verbleibender Aufwand abgeleitet." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Abgeschlossen wird durch den Status des Arbeitspakets festgelegt." migration_warning_text: "Im aufwandsbezogenen Modus, kann % Fertig nicht manuell eingegeben werden und ist immer an den Aufwand gebunden. Der vorhandene Wert wurde beibehalten, kann aber nicht bearbeitet werden. Bitte geben Sie zuerst den Wert für Aufwand ein." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Kommentar" comment_description: "Kann dieses Arbeitspaket anzeigen und kommentieren." diff --git a/config/locales/crowdin/el.yml b/config/locales/crowdin/el.yml index 05af2bb6d0c7..b968ac9a5edc 100644 --- a/config/locales/crowdin/el.yml +++ b/config/locales/crowdin/el.yml @@ -1036,10 +1036,10 @@ el: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "δεν είναι στην ημερομηνία έναρξης, παρόλο που απαιτείται από τα ορόσημα." @@ -1069,15 +1069,17 @@ el: does_not_exist: "Η καθορισμένη κατηγορία δεν υπάρχει." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1656,7 +1658,8 @@ el: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3112,8 +3115,10 @@ el: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Ιδιότητες πακέτου εργασίας" setting_work_package_startdate_is_adddate: "Χρήση σημερινής ημερομηνίας ως ημερομηνία έναρξης για νέα πακέτα εργασίας" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3495,9 +3500,26 @@ el: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Σχόλιο" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/eo.yml b/config/locales/crowdin/eo.yml index dac2fa8d4508..ace0ab3fc8da 100644 --- a/config/locales/crowdin/eo.yml +++ b/config/locales/crowdin/eo.yml @@ -1040,10 +1040,10 @@ eo: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1073,15 +1073,17 @@ eo: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ eo: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ eo: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ eo: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Komento" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/es.yml b/config/locales/crowdin/es.yml index 9795547245fd..d2bec73660ac 100644 --- a/config/locales/crowdin/es.yml +++ b/config/locales/crowdin/es.yml @@ -1037,10 +1037,10 @@ es: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "no coincide el trabajo y el trabajo restante" - cannot_be_set_when_work_is_zero: "no puede fijarse cuando el trabajo es cero" - must_be_set_when_remaining_work_is_set: "Obligatorio cuando el Trabajo restante está establecido." - must_be_set_when_work_and_remaining_work_are_set: "Obligatorio cuando se fijan Trabajo y Trabajo restante." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "debe estar entre 0 y 100." due_date: not_start_date: "no es en fecha de inicio, aunque esto es necesario para hitos." @@ -1070,15 +1070,17 @@ es: does_not_exist: "La categoría especificada no existe." estimated_hours: not_a_number: "no es una duración válida." - cant_be_inferior_to_remaining_work: "No puede ser inferior al Trabajo restante." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Obligatorio cuando se fijan Trabajo restante y % completado." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "no es una duración válida." - cant_exceed_work: "No puede ser superior a Trabajo." - must_be_set_when_work_is_set: "Obligatorio cuando Trabajo está establecido." - must_be_set_when_work_and_percent_complete_are_set: "Obligatorio cuando se fijan Trabajo y % completado." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "El paquete de trabajo está en un estado de sólo lectura por lo que sus atributos no se pueden cambiar." type: attributes: @@ -1657,7 +1659,8 @@ es: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3113,8 +3116,10 @@ es: setting_work_package_done_ratio: "Cálculo del progreso" setting_work_package_done_ratio_field: "Basado en el trabajo" setting_work_package_done_ratio_status: "Basado en el estado" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - En el modo basado en el trabajo, el % completado se calcula a partir de cuánto trabajo se ha realizado en relación con el trabajo total. En el modo basado en el estado, cada estado tiene asociado un valor de % completado. El cambio de estado modificará el % completado. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Propiedades de paquete de trabajo" setting_work_package_startdate_is_adddate: "Usar fecha actual como fecha de inicio para nuevos paquetes de trabajo" setting_work_packages_projects_export_limit: "Fecha límite para exportar paquete de trabajo o proyectos" @@ -3496,9 +3501,26 @@ es: progress: label_note: "Nota:" modal: - work_based_help_text: "El % completado se obtiene automáticamente a partir del Trabajo y del Trabajo restante." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% completado se establece por el estado del paquete de trabajo." migration_warning_text: "En el modo de cálculo del progreso basado en el trabajo, el % completado no puede fijarse manualmente y está vinculado al Trabajo. El valor existente se mantiene, pero no puede editarse. Introduzca primero el Trabajo." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comentario" comment_description: "Puede ver y comentar este paquete de trabajo." diff --git a/config/locales/crowdin/et.yml b/config/locales/crowdin/et.yml index ca1d00337ff1..cc2e4ee8cb00 100644 --- a/config/locales/crowdin/et.yml +++ b/config/locales/crowdin/et.yml @@ -1040,10 +1040,10 @@ et: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "verstapostil on vajalik määrata alguskuupäev." @@ -1073,15 +1073,17 @@ et: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ et: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ et: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Teemade atribuudid" setting_work_package_startdate_is_adddate: "Uute teemade alguskuupäevaks käesolev päev" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ et: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Kommentaar" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/eu.yml b/config/locales/crowdin/eu.yml index 37b8e1de401b..8e562c32eeeb 100644 --- a/config/locales/crowdin/eu.yml +++ b/config/locales/crowdin/eu.yml @@ -1040,10 +1040,10 @@ eu: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1073,15 +1073,17 @@ eu: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ eu: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ eu: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ eu: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comment" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/fa.yml b/config/locales/crowdin/fa.yml index 177e471190cf..3d0398f47c35 100644 --- a/config/locales/crowdin/fa.yml +++ b/config/locales/crowdin/fa.yml @@ -1040,10 +1040,10 @@ fa: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1073,15 +1073,17 @@ fa: does_not_exist: "دسته انتخاب شده وجود ندارد." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ fa: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ fa: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ fa: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "نظر" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/fi.yml b/config/locales/crowdin/fi.yml index f1d2e0886e00..391e2249d9da 100644 --- a/config/locales/crowdin/fi.yml +++ b/config/locales/crowdin/fi.yml @@ -1040,10 +1040,10 @@ fi: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "ei ole aloituspäivänä, vaikka välitavoite vaatii sen olevan." @@ -1073,15 +1073,17 @@ fi: does_not_exist: "Määritettyä luokkaa ei ole." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ fi: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ fi: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Tehtävän ominaisuudet" setting_work_package_startdate_is_adddate: "Käytä nykyistä päivämäärää uuden tehtävän aloistuspäivänä" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ fi: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Kommentti" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/fil.yml b/config/locales/crowdin/fil.yml index 5d5add737685..2365685dafd2 100644 --- a/config/locales/crowdin/fil.yml +++ b/config/locales/crowdin/fil.yml @@ -1040,10 +1040,10 @@ fil: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "hindi sa petsa ng pagsisimula, kahit naa ito ay kinakailangan para sa mga milestone." @@ -1073,15 +1073,17 @@ fil: does_not_exist: "Ang tinukoy na kategorya ay hindi umiiral." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ fil: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3115,8 +3118,10 @@ fil: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Ang mga property ng work package" setting_work_package_startdate_is_adddate: "Gamitin ang kasulukuyang petsa bilang pagsisimula ng petsa para sa mga bagong work package" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3499,9 +3504,26 @@ fil: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Komento" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/fr.yml b/config/locales/crowdin/fr.yml index 7fa3b96fc8a9..5638c54d1a0d 100644 --- a/config/locales/crowdin/fr.yml +++ b/config/locales/crowdin/fr.yml @@ -1039,10 +1039,10 @@ fr: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "ne correspond pas au travail et au travail restant" - cannot_be_set_when_work_is_zero: "ne peut pas être défini lorsque le travail est nul" - must_be_set_when_remaining_work_is_set: "Requis lorsque le travail restant est défini." - must_be_set_when_work_and_remaining_work_are_set: "Requis lorsque le travail et les travaux restants sont définis." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "doit être compris entre 0 et 100." due_date: not_start_date: "n'est pas identique à la date de début, bien que cela soit requis pour les jalons." @@ -1072,15 +1072,17 @@ fr: does_not_exist: "La catégorie spécifiée n'existe pas." estimated_hours: not_a_number: "n'est pas une durée valide." - cant_be_inferior_to_remaining_work: "Ne peut être inférieur au Travail restant." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Requis lorsque le travail restant et le % d'achèvement sont définis." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "n'est pas une durée valide." - cant_exceed_work: "Ne peut être supérieur au Travail." - must_be_set_when_work_is_set: "Requis lorsque le Travail est défini." - must_be_set_when_work_and_percent_complete_are_set: "Requis lorsque le travail et le % d'achèvement sont définis." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Le lot de travaux est en lecture seule, ses attributs ne peuvent donc pas être changés." type: attributes: @@ -1659,7 +1661,8 @@ fr: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3116,8 +3119,10 @@ fr: setting_work_package_done_ratio: "Calcul de la progression" setting_work_package_done_ratio_field: "Basé sur le travail" setting_work_package_done_ratio_status: "Basé sur le statut" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - En mode Basé sur le travail, le % réalisé est calculé à partir de la quantité de travail effectuée par rapport au travail total. En mode Basé sur le statut, chaque statut est associé à une valeur de % réalisé. La modification du statut entraîne une modification du % réalisé. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Propriétés du Lot de Travaux" setting_work_package_startdate_is_adddate: "Utiliser la date actuelle comme date de début des nouveaux lots de travaux" setting_work_packages_projects_export_limit: "Limite d'exportation des lots de travaux/projets" @@ -3499,9 +3504,26 @@ fr: progress: label_note: "Note :" modal: - work_based_help_text: "Le % réalisé est automatiquement dérivé de Travail et Travail restant." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "Le % réalisé est défini par le statut du lot de travaux." migration_warning_text: "Dans le mode de calcul de la progression basé sur le travail, le % réalisé ne peut pas être défini manuellement et est lié au travail. La valeur existante a été conservée mais ne peut pas être modifiée. Veuillez d'abord renseigner Travail." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Commentaire" comment_description: "Peut consulter et commenter ce lot de travaux." diff --git a/config/locales/crowdin/he.yml b/config/locales/crowdin/he.yml index 0eece0dcf602..6b5e3234fab1 100644 --- a/config/locales/crowdin/he.yml +++ b/config/locales/crowdin/he.yml @@ -1054,10 +1054,10 @@ he: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1087,15 +1087,17 @@ he: does_not_exist: "הקטגוריה שצוינה אינה קיימת." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1730,7 +1732,8 @@ he: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3191,8 +3194,10 @@ he: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3577,9 +3582,26 @@ he: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "תגובה" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/hi.yml b/config/locales/crowdin/hi.yml index c482732a16e4..ca1cdebb33f3 100644 --- a/config/locales/crowdin/hi.yml +++ b/config/locales/crowdin/hi.yml @@ -1038,10 +1038,10 @@ hi: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1071,15 +1071,17 @@ hi: does_not_exist: "निर्दिष्ट श्रेणी मौजूद नहीं है ।" estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1658,7 +1660,8 @@ hi: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3115,8 +3118,10 @@ hi: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3499,9 +3504,26 @@ hi: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "टिप्पणी" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/hr.yml b/config/locales/crowdin/hr.yml index 3c10e1b74f88..81c8c1662d5f 100644 --- a/config/locales/crowdin/hr.yml +++ b/config/locales/crowdin/hr.yml @@ -1047,10 +1047,10 @@ hr: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "nije na datum početka, međutim potrebno je za ključne točke." @@ -1080,15 +1080,17 @@ hr: does_not_exist: "Navedena kategorija ne postoji." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1695,7 +1697,8 @@ hr: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3154,8 +3157,10 @@ hr: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Postavke radnih paketa" setting_work_package_startdate_is_adddate: "Koristite današanji datum kao početni datum novih radnih paketa" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3539,9 +3544,26 @@ hr: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Komentar" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/hu.yml b/config/locales/crowdin/hu.yml index f19fdfd7f459..375a4168a936 100644 --- a/config/locales/crowdin/hu.yml +++ b/config/locales/crowdin/hu.yml @@ -1037,10 +1037,10 @@ hu: assigned_to: format: "%{message}\n" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "nincs kezdő dátum, ez szükséges a fordulóponthoz." @@ -1070,15 +1070,17 @@ hu: does_not_exist: "A megadott kategória nem létezik." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}\n" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}\n" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "A munkacsomag írásvédett, ezért a tulajdonságai nem módosíthatók." type: attributes: @@ -1657,7 +1659,8 @@ hu: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3113,8 +3116,10 @@ hu: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "feladatcsoport tulajdonságok" setting_work_package_startdate_is_adddate: "Az aktuális dátum használata, mint kezdő dátuma az új feladatcsoportoknak" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3497,9 +3502,26 @@ hu: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Vélemény" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/id.yml b/config/locales/crowdin/id.yml index 680b7f43ed7d..84eef066d0d7 100644 --- a/config/locales/crowdin/id.yml +++ b/config/locales/crowdin/id.yml @@ -1026,10 +1026,10 @@ id: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "tanggal mulai dan berakhir pada milestone harus sama." @@ -1059,15 +1059,17 @@ id: does_not_exist: "Kategori yang dipilih tidak ada." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1618,7 +1620,8 @@ id: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -2052,7 +2055,7 @@ id: label_file_plural: "File" label_filter_add: "Tambah Filter" label_filter: "Filter" - label_filter_plural: "Filter" + label_filter_plural: "Penyaring" label_filters_toggle: "Tampilkan/Sembunyikan penyaringan" label_float: "Float" label_folder: "Folder" @@ -3069,8 +3072,10 @@ id: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Properti Paket-Penugasan" setting_work_package_startdate_is_adddate: "Gunakan tanggal sekarang untuk start Paket-Penugasan" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3452,9 +3457,26 @@ id: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Komentar" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/it.yml b/config/locales/crowdin/it.yml index ecf2a3733679..bd6e4af4e2d5 100644 --- a/config/locales/crowdin/it.yml +++ b/config/locales/crowdin/it.yml @@ -64,11 +64,11 @@ it: upgrade_to_ee: "Aggiorna a Enterprise edition" add_token: "Carica un token di assistenza per Enterprise edition" delete_token_modal: - text: "Vuoi davvero rimuovere il token Enterprise edition attualmente utilizzato?" + text: "Vuoi davvero rimuovere il token Enterprise Edition attualmente utilizzato?" title: "Elimina token" replace_token: "Sostituisci il token di assistenza attuale" order: "Ordina l'edizione Enterprise on-premises" - paste: "Incolla il tuo token di assistenza per Enterprise edition" + paste: "Incolla il tuo token di assistenza per Enterprise Edition" required_for_feature: "Questa aggiunta è disponibile solo con un token di assistenza Enterprise Edition attivo." enterprise_link: "Per ulteriori informazioni, clicca qui." start_trial: "Inizia la prova gratuita" @@ -804,7 +804,7 @@ it: confirmation: "non coincide con %{attribute}." could_not_be_copied: "%{dependency} non può essere (completamente) copiato." does_not_exist: "non esiste." - error_enterprise_only: "%{action} è disponibile solo in OpenProject Enterprise edition" + error_enterprise_only: "%{action} è disponibile solo in OpenProject Enterprise Edition" error_unauthorized: "potrebbe non essere accessibile." error_readonly: "è in sola lettura, pertanto non è stato possibile modificarlo." error_conflict: "L'informazione è stata aggiornata da almeno un altro utente nel frattempo." @@ -1037,10 +1037,10 @@ it: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "non corrisponde al lavoro e al lavoro residuo" - cannot_be_set_when_work_is_zero: "non può essere impostata quando il lavoro è zero" - must_be_set_when_remaining_work_is_set: "Obbligatorio quando si imposta Lavoro residuo." - must_be_set_when_work_and_remaining_work_are_set: "Obbligatorio quando si impostano Lavoro e Lavoro residuo." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "deve essere compresa tra 0 e 100." due_date: not_start_date: "non è sulla data di inizio, nonostante sia obbligatorio per i traguardi." @@ -1070,15 +1070,17 @@ it: does_not_exist: "La categoria specificata non esiste." estimated_hours: not_a_number: "non è una durata valida." - cant_be_inferior_to_remaining_work: "Non può essere inferiore al Lavoro residuo." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Richiesto quando sono impostate le opzioni Lavoro residuo e % completamento." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "non è una durata valida." - cant_exceed_work: "Non può essere superiore a Lavoro." - must_be_set_when_work_is_set: "Obbligatorio quando è impostato Lavoro." - must_be_set_when_work_and_percent_complete_are_set: "Richiesto quando sono impostate le opzioni Lavoro e % completamento." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "La macro-attività è in uno stato di sola lettura perciò i suoi attributi non possono essere modificati." type: attributes: @@ -1592,7 +1594,7 @@ it: error_cookie_missing: "Il cookie di OpenProject è mancante. Prego, verifica che i cookie siano attivati, questa applicazione non funziona correttamente senza." error_custom_option_not_found: "L'opzione non esiste." error_enterprise_activation_user_limit: "Il tuo account potrebbe non essere attivo (raggiunto il limite utente). Si prega di contattare l'amministratore per ottenere l'accesso." - error_enterprise_token_invalid_domain: "L'Enterprise edition non è attiva. Il dominio del token Enterprise (%{actual}) non corrisponde al nome host del sistema (%{expected})." + error_enterprise_token_invalid_domain: "L'Enterprise Edition non è attiva. Il dominio del token Enterprise (%{actual}) non corrisponde al nome host del sistema (%{expected})." error_failed_to_delete_entry: "Cancellazione voce non riuscita." error_in_dependent: "Errore nel tentativo di modificare l'oggetto dipendente: %{dependent_class} #%{related_id} - %{related_subject}: %{error}" error_in_new_dependent: "Errore nel tentativo di creare un oggetto dipendente: %{dependent_class} - %{related_subject}: %{error}" @@ -1657,7 +1659,8 @@ it: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -1756,10 +1759,10 @@ it: blocks: community: "Comunità di OpenProject" upsale: - title: "Aggiorna ad Enterprise edition" + title: "Aggiorna ad Enterprise Edition" more_info: "Altre informazioni" links: - upgrade_enterprise_edition: "Aggiorna ad Enterprise edition" + upgrade_enterprise_edition: "Aggiorna ad Enterprise Edition" postgres_migration: "Migrazione dell'installazione su PostgreSQL" user_guides: "Guide utente" faq: "FAQ" @@ -2065,7 +2068,7 @@ it: label_enumerations: "Enumerazioni" label_enterprise: "Enterprise" label_enterprise_active_users: "%{current}/%{limit} utenti attivi riservati" - label_enterprise_edition: "Enterprise edition" + label_enterprise_edition: "Enterprise Edition" label_enterprise_support: "Supporto per Imprese" label_enterprise_addon: "Componente aggiuntivo Enterprise" label_environment: "Ambiente" @@ -3114,8 +3117,10 @@ it: setting_work_package_done_ratio: "Calcolo dei progressi" setting_work_package_done_ratio_field: "Basato sul lavoro" setting_work_package_done_ratio_status: "Basato sullo stato" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - Nella modalità basata sul lavoro, la % di completamento viene calcolata in base alla quantità di lavoro svolto rispetto al lavoro totale. Nella modalità basata sullo stato, a ogni stato è associato un valore di % completamento. La modifica dello stato cambierà la % completamento. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Proprietà della macro-attività" setting_work_package_startdate_is_adddate: "Usa la data corrente come data di inizio per le nuove macro-attività" setting_work_packages_projects_export_limit: "Limite di esportazione di macro-attività/progetti" @@ -3498,9 +3503,26 @@ it: progress: label_note: "Nota:" modal: - work_based_help_text: "La % completamento viene ricavata automaticamente dal lavoro e dal lavoro residuo." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "La % completamento è stabilita dallo stato della macro-attività." migration_warning_text: "Nella modalità di calcolo basata sul lavoro, la % completamento non può essere impostata manualmente ed è legata al lavoro. Il valore esistente è stato mantenuto ma non può essere modificato. Specifica prima il lavoro." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Commentare" comment_description: "Può visualizzare e commentare questa macro-attività." diff --git a/config/locales/crowdin/ja.yml b/config/locales/crowdin/ja.yml index 85d634191c27..5f263fc3e1ea 100644 --- a/config/locales/crowdin/ja.yml +++ b/config/locales/crowdin/ja.yml @@ -1029,10 +1029,10 @@ ja: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "は開始日になっていません。これはマイルストーンの場倍、必要である。" @@ -1062,15 +1062,17 @@ ja: does_not_exist: "指定されたカテゴリは存在しません。" estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1621,7 +1623,8 @@ ja: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3076,8 +3079,10 @@ ja: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "項目名" setting_work_package_startdate_is_adddate: "今日の日付を新しいワークパッケージの開始日とする" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3458,9 +3463,26 @@ ja: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "コメント" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/js-af.yml b/config/locales/crowdin/js-af.yml index 51171b86d736..59c8f7063574 100644 --- a/config/locales/crowdin/js-af.yml +++ b/config/locales/crowdin/js-af.yml @@ -138,6 +138,8 @@ af: description_select_work_package: "Kies werkspakket #%{id}" description_subwork_package: "Kind van werkspakket #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ af: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ af: label_create: "Skep" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Datum" label_date_with_format: "Tik die %{date_attribute} in die volgende formaat: %{format}" label_deactivate: "Deactivate" @@ -1182,6 +1187,9 @@ af: one: "1 dag" other: "%{count} dae" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-ar.yml b/config/locales/crowdin/js-ar.yml index e2689d339bb5..67c66f6142eb 100644 --- a/config/locales/crowdin/js-ar.yml +++ b/config/locales/crowdin/js-ar.yml @@ -138,6 +138,8 @@ ar: description_select_work_package: "اختر مجموعة العمل #%{id}" description_subwork_package: "إنتاج مجموعة العمل #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ ar: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ ar: label_create: "إنشاء" label_create_work_package: "إنشاء حزمة جديدة" label_created_by: "أنشئ بواسطة" + label_current: "current" label_date: "التاريخ" label_date_with_format: "أدخل %{date_attribute} باستخدام التنسيق التالي: %{format}" label_deactivate: "تعطيل" @@ -1194,6 +1199,13 @@ ar: one: "1 يوم" other: "%{count} يوم" zero: "0 days" + word: + zero: "%{count} words" + one: "1 word" + two: "%{count} words" + few: "%{count} words" + many: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-az.yml b/config/locales/crowdin/js-az.yml index b1be89ad35de..2e0ab9648773 100644 --- a/config/locales/crowdin/js-az.yml +++ b/config/locales/crowdin/js-az.yml @@ -138,6 +138,8 @@ az: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ az: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ az: label_create: "Create" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Date" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Söndür" @@ -1182,6 +1187,9 @@ az: one: "1 day" other: "%{count} days" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-be.yml b/config/locales/crowdin/js-be.yml index 29a6fea761ea..8d0243e24336 100644 --- a/config/locales/crowdin/js-be.yml +++ b/config/locales/crowdin/js-be.yml @@ -138,6 +138,8 @@ be: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ be: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ be: label_create: "Create" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Дата" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deactivate" @@ -1188,6 +1193,11 @@ be: one: "1 day" other: "%{count} days" zero: "0 days" + word: + one: "1 word" + few: "%{count} words" + many: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-bg.yml b/config/locales/crowdin/js-bg.yml index a9fed73b3646..a776d0e9eece 100644 --- a/config/locales/crowdin/js-bg.yml +++ b/config/locales/crowdin/js-bg.yml @@ -138,6 +138,8 @@ bg: description_select_work_package: "Избери работен пакет #%{id}" description_subwork_package: "Подработен пакет #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ bg: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ bg: label_create: "Създаване" label_create_work_package: "Създаване на нов работен пакет" label_created_by: "Created by" + label_current: "current" label_date: "Дата" label_date_with_format: "Въведете %{date_attribute}, като използвате следния формат: %{format}" label_deactivate: "Деактивирай" @@ -1182,6 +1187,9 @@ bg: one: "1 ден" other: "%{count} дни" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-ca.yml b/config/locales/crowdin/js-ca.yml index f21ff37aeb0f..f6796c90e146 100644 --- a/config/locales/crowdin/js-ca.yml +++ b/config/locales/crowdin/js-ca.yml @@ -102,7 +102,7 @@ ca: button_save: "Desa" button_settings: "Configuració" button_uncheck_all: "Desmarca-ho tot" - button_update: "Actualitza" + button_update: "Actualitzar" button_export-pdf: "Descarregar PDF" button_export-atom: "Descarregar Atom" button_create: "Crear" @@ -138,6 +138,8 @@ ca: description_select_work_package: "Selecciona el paquet de treball #%{id}" description_subwork_package: "Fill del paquet de treball #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Canvia al mode de vista prèvia" source_code: "Canvia al mode de font Markdown" error_saving_failed: "No s'ha pogut guardar el document per culpa del següent error: %{error}" @@ -276,8 +278,10 @@ ca: Els canvis poden tardar un temps a ser aplicats. Et notificarem un cop s'hagin actualitzat tots els paquets de treball rellevants. Estàs segur que vols continuar? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ ca: label_create: "Crear" label_create_work_package: "Crear nou paquet de treball" label_created_by: "Creat per" + label_current: "current" label_date: "Data" label_date_with_format: "Introdueix el %{date_attribute} amb el format següent: %{format}" label_deactivate: "Desactivar" @@ -752,7 +757,7 @@ ca: label: "Pausa els correu electrònic recordatori temporalment" first_day: "Primer dia" last_day: "Últim dia" - text_are_you_sure: "N'esteu segur?" + text_are_you_sure: "N'estas segur?" text_data_lost: "Totes les dades entrades es perdran." text_user_wrote: "%{value} va escriure:" types: @@ -1182,6 +1187,9 @@ ca: one: "1 dia" other: "%{count} dies" zero: "0 dies" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activa el mode zen" button_deactivate: "Desactiva el mode zen" diff --git a/config/locales/crowdin/js-ckb-IR.yml b/config/locales/crowdin/js-ckb-IR.yml index 97b05d7c9cd7..7d3a413846e8 100644 --- a/config/locales/crowdin/js-ckb-IR.yml +++ b/config/locales/crowdin/js-ckb-IR.yml @@ -138,6 +138,8 @@ ckb-IR: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ ckb-IR: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ ckb-IR: label_create: "Create" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Date" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deactivate" @@ -1182,6 +1187,9 @@ ckb-IR: one: "1 day" other: "%{count} days" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-cs.yml b/config/locales/crowdin/js-cs.yml index bce3f5cf525e..d27f8ecf91f6 100644 --- a/config/locales/crowdin/js-cs.yml +++ b/config/locales/crowdin/js-cs.yml @@ -138,6 +138,8 @@ cs: description_select_work_package: "Vyberte pracovní balíček #%{id}" description_subwork_package: "Podřazený pracovního balíčku #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Přepnout režim náhledu" source_code: "Přepnout zdrojový mód Markdown" error_saving_failed: "Uložení dokumentu se nezdařilo s následující chybou: %{error}" @@ -275,8 +277,10 @@ cs: warning: > work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -397,6 +401,7 @@ cs: label_create: "Vytvořit" label_create_work_package: "Vytvořit nový pracovní balíček" label_created_by: "Vytvořil(a)" + label_current: "current" label_date: "Datum" label_date_with_format: "Zadejte %{date_attribute} v následujícím formátu: %{format}" label_deactivate: "Deaktivovat" @@ -1187,6 +1192,11 @@ cs: one: "1 den" other: "%{count} dní" zero: "0 dní" + word: + one: "1 word" + few: "%{count} words" + many: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Aktivovat zen režim" button_deactivate: "Deaktivovat zen režim" diff --git a/config/locales/crowdin/js-da.yml b/config/locales/crowdin/js-da.yml index 18ff291e892e..6e34ff7e00a8 100644 --- a/config/locales/crowdin/js-da.yml +++ b/config/locales/crowdin/js-da.yml @@ -138,6 +138,8 @@ da: description_select_work_package: "Vælg arbejds pakke #%{id}" description_subwork_package: "Barn af arbejds-pakke #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle forhåndsvisning" source_code: "Toggle Markdown kilde-visning" error_saving_failed: "Lagring af dokumentet mislykkedes med følgende fejl: %{error}" @@ -275,8 +277,10 @@ da: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -397,6 +401,7 @@ da: label_create: "Opret" label_create_work_package: "Opret ny arbejdspakke" label_created_by: "Created by" + label_current: "current" label_date: "Dato" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deaktivér" @@ -1181,6 +1186,9 @@ da: one: "1 dag" other: "%{count} dage" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-de.yml b/config/locales/crowdin/js-de.yml index b0d2329a8172..d0ec8e4711fc 100644 --- a/config/locales/crowdin/js-de.yml +++ b/config/locales/crowdin/js-de.yml @@ -138,6 +138,8 @@ de: description_select_work_package: "Arbeitspaket #%{id} auswählen" description_subwork_package: "Kind von Arbeitspaket #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Vorschau-Modus ein/aus" source_code: "Wechseln zwischen Markdown-Source und WYSIWYG" error_saving_failed: "Fehler beim Speichern des Dokuments: %{error}" @@ -275,8 +277,10 @@ de: Es kann einige Zeit dauern, bis die Änderungen wirksam werden. Sie werden benachrichtigt, wenn alle relevanten Arbeitspakete aktualisiert worden sind. Sind Sie sicher, dass Sie fortfahren möchten? work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - Wenn Sie den Modus der Fortschrittsberechnung von statusbezogen auf aufwandsbezogen ändern, wird % Abgeschlossen zu einem nicht editierbaren Feld, dessen Wert von Aufwand und Verbleibender Aufwand abgeleitet wird. Vorhandene Werte für % Abgeschlossen werden beibehalten. Wenn die Werte für Aufwand und Verbleibender Aufwand nicht vorhanden waren, werden sie benötigt, um % Abgeschlossen zu ändern. + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Wenn Sie den Modus der Fortschrittsberechnung von aufwandsbezogen auf statusbezogen ändern, gehen alle bestehenden Werte für % Fertigstellung verloren und werden durch Werte ersetzt, die mit dem jeweiligen Status verbunden sind. Bestehende Werte für Verbleibender Aufwand können ebenfalls neu berechnet werden, um diese Änderung widerzuspiegeln. Diese Aktion ist nicht umkehrbar. custom_actions: @@ -397,6 +401,7 @@ de: label_create: "Erstellen" label_create_work_package: "Erstelle neues Arbeitspaket" label_created_by: "Erstellt von" + label_current: "current" label_date: "Datum" label_date_with_format: "Die %{date_attribute} im folgenden Format eingeben: %{format}" label_deactivate: "Deaktiviere" @@ -1181,6 +1186,9 @@ de: one: "1 Tag" other: "%{count} Tage" zero: "0 Tage" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Zen-Modus aktivieren" button_deactivate: "Zen-Modus deaktivieren" diff --git a/config/locales/crowdin/js-el.yml b/config/locales/crowdin/js-el.yml index ee2cce95fc3a..36994192495f 100644 --- a/config/locales/crowdin/js-el.yml +++ b/config/locales/crowdin/js-el.yml @@ -138,6 +138,8 @@ el: description_select_work_package: "Επιλέξτε πακέτο εργασίας #%{id}" description_subwork_package: "Παιδί του πακέτου εργασίας #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Ενεργοποίηση λειτουργίας προεπισκόπησης" source_code: "Ενεργοποίηση λειτουργίας Markdown source" error_saving_failed: "Η αποθήκευση του αρχείου απέτυχε δίνοντας το ακόλουθο μήνυμα: %{error}" @@ -275,8 +277,10 @@ el: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -397,6 +401,7 @@ el: label_create: "Δημιουργία" label_create_work_package: "Δημιουργήστε νέο πακέτο εργασίας" label_created_by: "Δημιουργήθηκε από" + label_current: "current" label_date: "Ημερομηνία" label_date_with_format: "Εισάγετε την %{date_attribute} χρησιμοποιώντας την ακόλουθη μορφοποίηση: %{format}" label_deactivate: "Απενεργοποίηση" @@ -1181,6 +1186,9 @@ el: one: "1 ημέρα" other: "%{count} ημέρες" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Ενεργοποίηση λειτουργίας zen" button_deactivate: "Απενεργοποίηση λειτουργίας zen" diff --git a/config/locales/crowdin/js-eo.yml b/config/locales/crowdin/js-eo.yml index 167ba8baa574..6db7e9189022 100644 --- a/config/locales/crowdin/js-eo.yml +++ b/config/locales/crowdin/js-eo.yml @@ -138,6 +138,8 @@ eo: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Baskuligi antaŭrigarda reĝimo" source_code: "Baskuligi Markdown fonta reĝimo" error_saving_failed: "Ne eblis konservi la dokumenton pro la jena eraro: %{error}" @@ -276,8 +278,10 @@ eo: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ eo: label_create: "Krei" label_create_work_package: "Create new work package" label_created_by: "Kreita de" + label_current: "current" label_date: "Dato" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Malaktivigi" @@ -1182,6 +1187,9 @@ eo: one: "1 tago" other: "%{count} tagoj" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Aktivigi zen reĝimo" button_deactivate: "Malaktivigi zen reĝimo" diff --git a/config/locales/crowdin/js-es.yml b/config/locales/crowdin/js-es.yml index 93758bdaaee0..1804c45121fb 100644 --- a/config/locales/crowdin/js-es.yml +++ b/config/locales/crowdin/js-es.yml @@ -138,6 +138,8 @@ es: description_select_work_package: "Seleccione el paquete de trabajo #%{id}" description_subwork_package: "Seleccione el paquete de trabajo #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Activar modo de vista previa" source_code: "Activar modo de visualización Markdown" error_saving_failed: "No se pudo guardar el documento debido al siguiente error: %{error}" @@ -276,8 +278,10 @@ es: Los cambios pueden tardar algún tiempo en surtir efecto. Se le notificará cuando todos los paquetes de trabajo relevantes hayan sido actualizados. ¿Está seguro de que desea continuar? work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - Cambiar el modo de cálculo del progreso de basado en el estado a basado en el trabajo hará que % completado sea un campo no editable cuyo valor se deriva de Trabajo y Trabajo restante. Los valores existentes para % completado se conservan. Si los valores para Trabajo y Trabajo restante no estaban presentes, serán necesarios para cambiar % completado. + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- El cambio del modo de cálculo del progreso de basado en el trabajo a basado en el estado hará que todos los valores existentes de % completado se pierdan y se sustituyan por valores asociados a cada estado. Los valores existentes para Trabajo restante también pueden recalcularse para reflejar este cambio. Esta acción no es reversible. custom_actions: @@ -398,6 +402,7 @@ es: label_create: "Crear" label_create_work_package: "Crear un nuevo paquete de trabajo" label_created_by: "Creado por" + label_current: "current" label_date: "Fecha" label_date_with_format: "Introduzca el %{date_attribute} usando el siguiente formato: %{format}" label_deactivate: "Desactivar" @@ -1182,6 +1187,9 @@ es: one: "1 día" other: "%{count} días" zero: "0 días" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activar modo zen" button_deactivate: "Desactivar modo zen" diff --git a/config/locales/crowdin/js-et.yml b/config/locales/crowdin/js-et.yml index e9bf7a10f2aa..bcaaf4d917fb 100644 --- a/config/locales/crowdin/js-et.yml +++ b/config/locales/crowdin/js-et.yml @@ -138,6 +138,8 @@ et: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ et: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ et: label_create: "Loo uus" label_create_work_package: "Lisa uus teema" label_created_by: "Created by" + label_current: "current" label_date: "Kuupäev" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deactivate" @@ -1182,6 +1187,9 @@ et: one: "1 päev" other: "%{count} päeva" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-eu.yml b/config/locales/crowdin/js-eu.yml index ad04877e8d6d..e09f597ca49a 100644 --- a/config/locales/crowdin/js-eu.yml +++ b/config/locales/crowdin/js-eu.yml @@ -138,6 +138,8 @@ eu: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ eu: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ eu: label_create: "Create" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Date" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deactivate" @@ -1182,6 +1187,9 @@ eu: one: "1 day" other: "%{count} days" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-fa.yml b/config/locales/crowdin/js-fa.yml index aec2cd41c730..85dac0af3395 100644 --- a/config/locales/crowdin/js-fa.yml +++ b/config/locales/crowdin/js-fa.yml @@ -138,6 +138,8 @@ fa: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "ذخیره سازی مستند، ناموفق بود، خطا: %{error}" @@ -276,8 +278,10 @@ fa: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ fa: label_create: "ایجاد" label_create_work_package: "Create new work package" label_created_by: "ایجاد شده توسط" + label_current: "current" label_date: "تاریخ" label_date_with_format: "%{date_attribute} را با این فرمت وارد کنید: %{format}" label_deactivate: "غیر فعال کردن" @@ -1182,6 +1187,9 @@ fa: one: "1 day" other: "%{count} روز" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-fi.yml b/config/locales/crowdin/js-fi.yml index 1c29ae6593b4..cb6e9c4d76a5 100644 --- a/config/locales/crowdin/js-fi.yml +++ b/config/locales/crowdin/js-fi.yml @@ -138,6 +138,8 @@ fi: description_select_work_package: "Valitse tehtävä #%{id}" description_subwork_package: "Tehtävän #%{id} alitehtävä" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Esikatselutila" source_code: "Lähdekoodi" error_saving_failed: "Tallennus epäonnistui: %{error}" @@ -276,8 +278,10 @@ fi: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ fi: label_create: "Uusi" label_create_work_package: "Uusi tehtävä" label_created_by: "Luonut" + label_current: "current" label_date: "Päivämäärä" label_date_with_format: "Kirjoita %{date_attribute} seuraavassa muodossa: %{format}" label_deactivate: "Poistaa käytöstä" @@ -1182,6 +1187,9 @@ fi: one: "päivä" other: "%{count} päivää" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Koko näyttö" button_deactivate: "Sulje koko näyttö" diff --git a/config/locales/crowdin/js-fil.yml b/config/locales/crowdin/js-fil.yml index 921993122e3e..02c377429a92 100644 --- a/config/locales/crowdin/js-fil.yml +++ b/config/locales/crowdin/js-fil.yml @@ -138,6 +138,8 @@ fil: description_select_work_package: "Piliin ang work package #%{id}" description_subwork_package: "Bata ng work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ fil: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ fil: label_create: "Lumikha" label_create_work_package: "Lumikha ng bagong work package" label_created_by: "Nilikha ni" + label_current: "current" label_date: "Petsa" label_date_with_format: "Ipasok anv %{date_attribute} gamit ang sumusunod na format: %{format}" label_deactivate: "I-deactivate" @@ -1182,6 +1187,9 @@ fil: one: "Isang araw" other: "mga Isang %{count} araw" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "I-aktibo ang zen mode" button_deactivate: "I-deactive ang zen mode" diff --git a/config/locales/crowdin/js-fr.yml b/config/locales/crowdin/js-fr.yml index 0a7bcdda7388..0952189c86a9 100644 --- a/config/locales/crowdin/js-fr.yml +++ b/config/locales/crowdin/js-fr.yml @@ -138,6 +138,8 @@ fr: description_select_work_package: "Sélectionner le lot de travaux #%{id}" description_subwork_package: "Enfant du lot de travaux #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Basculer en mode aperçu" source_code: "Basculer en mode source Markdown" error_saving_failed: "L'enregistrement du document a échoué en raison de l'erreur suivante : %{error}" @@ -276,8 +278,10 @@ fr: Les modifications pourraient prendre un certain temps pour être appliquées. Vous serez averti(e) lorsque tous les lots de travaux pertinents auront été mis à jour. Voulez-vous continuer ? work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - Passer du mode de calcul de la progression basé sur le statut au mode basé sur le travail transformera % réalisé en champ non modifiable dont la valeur est dérivée des champs Travail et Travail restant. Les valeurs existantes pour % réalisé sont conservées. Des valeurs pour Travail et Travail restant sont requises pour modifier % réalisé. + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Passer du mode de calcul de la progression basé sur le travail au mode basé sur le statut entraînera la perte de toutes les valeurs de % réalisé existantes et leur remplacement par les valeurs associées à chaque statut. Les valeurs existantes pour Travail restant peuvent également être recalculées pour refléter ce changement. Cette action est irréversible. custom_actions: @@ -398,6 +402,7 @@ fr: label_create: "Créer" label_create_work_package: "Créer un nouveau lot de travaux" label_created_by: "Créé par" + label_current: "current" label_date: "date" label_date_with_format: "Saisissez l'attribut %{date_attribute} en utilisant le format suivant : %{format}" label_deactivate: "Désactiver" @@ -1182,6 +1187,9 @@ fr: one: "1 jour" other: "%{count} jours" zero: "0 jour" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activer le mode zen" button_deactivate: "Désactiver le mode zen" diff --git a/config/locales/crowdin/js-he.yml b/config/locales/crowdin/js-he.yml index 6d1dc6089e38..56d938579d5d 100644 --- a/config/locales/crowdin/js-he.yml +++ b/config/locales/crowdin/js-he.yml @@ -138,6 +138,8 @@ he: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ he: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ he: label_create: "צור" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "תאריך" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "השבת" @@ -1188,6 +1193,11 @@ he: one: "יום אחד" other: "%{count} ימים" zero: "0 days" + word: + one: "1 word" + two: "%{count} words" + many: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-hi.yml b/config/locales/crowdin/js-hi.yml index 080b3c2c4760..789b8e4a0e36 100644 --- a/config/locales/crowdin/js-hi.yml +++ b/config/locales/crowdin/js-hi.yml @@ -138,6 +138,8 @@ hi: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Markdown स्रोत मोड टॉगल करें" error_saving_failed: "दस्तावेज़ को सहेजना निम्न त्रुटि के साथ विफल हुआ: %{error}" @@ -276,8 +278,10 @@ hi: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ hi: label_create: "रचना करें" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "तिथि" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "निष्क्रिय करें" @@ -1182,6 +1187,9 @@ hi: one: "1 दिन" other: "%{count} days" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-hr.yml b/config/locales/crowdin/js-hr.yml index f5f498fc1d16..0a79c465a4d4 100644 --- a/config/locales/crowdin/js-hr.yml +++ b/config/locales/crowdin/js-hr.yml @@ -138,6 +138,8 @@ hr: description_select_work_package: "Odaberite radni paket #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ hr: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ hr: label_create: "Stvori" label_create_work_package: "Kreirajte novi radni paket" label_created_by: "Kreirao korisnik" + label_current: "current" label_date: "Datum" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deaktivirajte" @@ -1185,6 +1190,10 @@ hr: one: "1 dan" other: "%{count} dana" zero: "0 days" + word: + one: "1 word" + few: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-hu.yml b/config/locales/crowdin/js-hu.yml index 051f82fc470f..7ff296cf1146 100644 --- a/config/locales/crowdin/js-hu.yml +++ b/config/locales/crowdin/js-hu.yml @@ -138,6 +138,8 @@ hu: description_select_work_package: "Munkacsomag kiválasztás #%{id}" description_subwork_package: "Munkacsomag gyermeke #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Váltás az előnézeti módra" source_code: "Váltás Markdown forrás módra" error_saving_failed: "A dokumentum mentése a következő hiba miatt nem sikerült: %{error}" @@ -276,8 +278,10 @@ hu: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ hu: label_create: "Létrehoz" label_create_work_package: "Új munkacsomag létrehozása" label_created_by: "Létrehozta" + label_current: "current" label_date: "dátum" label_date_with_format: "Adja meg a %{date_attribute}, a következő formátumban: %{format}" label_deactivate: "Kikapcsol" @@ -1182,6 +1187,9 @@ hu: one: "1 nap" other: "%{count} nap" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Zen mód aktiválása" button_deactivate: "Zen mód kikapcsolása" diff --git a/config/locales/crowdin/js-id.yml b/config/locales/crowdin/js-id.yml index 886d19f0c34d..e133255e427f 100644 --- a/config/locales/crowdin/js-id.yml +++ b/config/locales/crowdin/js-id.yml @@ -102,7 +102,7 @@ id: button_save: "Simpan" button_settings: "Pengaturan" button_uncheck_all: "Uncek semua" - button_update: "Update" + button_update: "Perbarui" button_export-pdf: "Download PDF" button_export-atom: "Download Atom" button_create: "Buat baru" @@ -138,6 +138,8 @@ id: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Beralih ke mode preview" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ id: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ id: label_create: "Buat baru" label_create_work_package: "Buat Paket-Penugasan baru" label_created_by: "Created by" + label_current: "current" label_date: "Tanggal" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Nonaktifkan" @@ -1179,6 +1184,8 @@ id: one: "1 day" other: "%{count} hari" zero: "0 days" + word: + other: "%{count} words" zen_mode: button_activate: "Mengaktifkan modus zen" button_deactivate: "Menonaktifkan modus zen" diff --git a/config/locales/crowdin/js-it.yml b/config/locales/crowdin/js-it.yml index d332e70d53a5..8b17fd570f46 100644 --- a/config/locales/crowdin/js-it.yml +++ b/config/locales/crowdin/js-it.yml @@ -138,6 +138,8 @@ it: description_select_work_package: "Seleziona la macro-attività #%{id}" description_subwork_package: "Subordinata alla macro-attività #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Attiva/disattiva modalità anteprima" source_code: "Attiva/Disattiva modalità origine Marcatura" error_saving_failed: "Il salvataggio del documento è fallito con il seguente errore: %{error}" @@ -276,8 +278,10 @@ it: L'applicazione delle modifiche potrebbe richiedere del tempo. Riceverai una notifica quando tutti i pacchetti di lavoro pertinenti saranno aggiornati. Vuoi davvero continuare? work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - Cambiare la modalità di calcolo dell'avanzamento da basata sullo stato a basata su lavoro renderà % Completa un campo non modificabile il cui valore è derivato da Lavoro e Lavoro rimanente. I valori esistenti per % Complete sono conservati. Se i valori per Lavoro e Lavoro rimanente non erano presenti, saranno necessari per modificare % Complete. + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Cambiando la modalità di calcolo dell'avanzamento da basata sul lavoro a basata sullo stato porvocherà la perdita di tutti i valori % Complete esistenti e saranno sostituiti con i valori associati ad ogni stato. I valori esistenti per il lavoro rimanente potrebbero anche essere ricalcolati per riflettere questo cambiamento. Questa azione non è reversibile. custom_actions: @@ -398,6 +402,7 @@ it: label_create: "Crea" label_create_work_package: "Crea una nuova macro-attività" label_created_by: "Creato da" + label_current: "current" label_date: "Data" label_date_with_format: "Immettere il %{date_attribute} utilizzando il seguente formato: %{format}" label_deactivate: "Disattivare" @@ -1182,6 +1187,9 @@ it: one: "1 giorno" other: "%{count} giorni" zero: "0 giorni" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Attiva modalità zen" button_deactivate: "Disattiva modalità zen" diff --git a/config/locales/crowdin/js-ja.yml b/config/locales/crowdin/js-ja.yml index efe8fab1c711..c3e4953bf501 100644 --- a/config/locales/crowdin/js-ja.yml +++ b/config/locales/crowdin/js-ja.yml @@ -139,6 +139,8 @@ ja: description_select_work_package: "作業項目を選択 #%{id}" description_subwork_package: "作業項目の子 #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "プレビューモードの切り替え" source_code: "Markdown ソースモードの切り替え" error_saving_failed: "次のエラーで文書を保存するのに失敗しました: %{error}" @@ -277,8 +279,10 @@ ja: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -399,6 +403,7 @@ ja: label_create: "作成" label_create_work_package: "新しいワークパッケージを作成" label_created_by: "作成者:" + label_current: "current" label_date: "日付" label_date_with_format: "次の形式を使用して %{date_attribute} を入力してください: %{format}" label_deactivate: "無効" @@ -1180,6 +1185,8 @@ ja: one: "1 day" other: "%{count}日間" zero: "0 days" + word: + other: "%{count} words" zen_mode: button_activate: "マナーモードをアクティブにする" button_deactivate: "マナーモードを非アクティブにする" diff --git a/config/locales/crowdin/js-ka.yml b/config/locales/crowdin/js-ka.yml index 98c54102bc8a..233ff758bde0 100644 --- a/config/locales/crowdin/js-ka.yml +++ b/config/locales/crowdin/js-ka.yml @@ -138,6 +138,8 @@ ka: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ ka: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ ka: label_create: "შექმნა" label_create_work_package: "Create new work package" label_created_by: "ავტორი" + label_current: "current" label_date: "თარიღი" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "დეაქტივაცია" @@ -1182,6 +1187,9 @@ ka: one: "1 დღე" other: "%{count} დღე" zero: "0 დღე" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-kk.yml b/config/locales/crowdin/js-kk.yml index 5a85236462d0..49aa639d5b3e 100644 --- a/config/locales/crowdin/js-kk.yml +++ b/config/locales/crowdin/js-kk.yml @@ -138,6 +138,8 @@ kk: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ kk: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ kk: label_create: "Create" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Date" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deactivate" @@ -1182,6 +1187,9 @@ kk: one: "1 day" other: "%{count} days" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-ko.yml b/config/locales/crowdin/js-ko.yml index 6139005fa515..de00872f4943 100644 --- a/config/locales/crowdin/js-ko.yml +++ b/config/locales/crowdin/js-ko.yml @@ -138,6 +138,8 @@ ko: description_select_work_package: "작업 패키지 #%{id} 선택" description_subwork_package: "작업 패키지 #%{id}의 자식" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "미리 보기 모드 토글" source_code: "Markdown 소스 모드 토글" error_saving_failed: "다음 오류로 인해 문서를 저장하지 못했습니다: %{error}" @@ -276,8 +278,10 @@ ko: 변경 사항이 적용되는 데 시간이 걸릴 수 있습니다. 모든 관련 작업 패키지가 업데이트되면 알림이 전송됩니다. 계속하시겠습니까? work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - 진행률 계산 모드를 상태 기반에서 작업 기반으로 변경하면 완료 %가 편집할 수 없는 필드가 되며 해당 값은 작업남은 작업에서 파생됩니다. 완료 %의 기존 값은 유지됩니다. 작업남은 작업의 값이 없는 경우, 완료 %를 변경하려면 해당 값이 필요합니다. + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- 진행률 계산 모드를 작업 기반에서 상태 기반으로 변경하면 기존의 모든 완료 % 값이 손실되고 각 상태와 관련된 값으로 대체됩니다. 남은 작업의 기존 값도 이 변경 사항을 반영하기 위해 다시 계산될 수 있습니다. 이 작업은 되돌릴 수 없습니다. custom_actions: @@ -398,6 +402,7 @@ ko: label_create: "만들기" label_create_work_package: "새 작업 패키지 만들기" label_created_by: "작성자" + label_current: "current" label_date: "날짜" label_date_with_format: "%{date_attribute} 는 %{format} 과 같이 입력되어야 합니다." label_deactivate: "비활성화" @@ -1179,6 +1184,8 @@ ko: one: "1일" other: "%{count}일" zero: "0일" + word: + other: "%{count} words" zen_mode: button_activate: "Zen 모드 활성화" button_deactivate: "Zen 모드 비활성화" diff --git a/config/locales/crowdin/js-lt.yml b/config/locales/crowdin/js-lt.yml index 5121b4a7050e..9acf538d97a2 100644 --- a/config/locales/crowdin/js-lt.yml +++ b/config/locales/crowdin/js-lt.yml @@ -138,6 +138,8 @@ lt: description_select_work_package: "Pasirinkite darbų paketą #%{id}" description_subwork_package: "Darbų paketo vaikas #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Perjungti peržiūros režimą" source_code: "Perjungti Markdown išeities kodo režimą" error_saving_failed: "Dokumento išsaugoti nepavyko. Klaida: %{error}" @@ -276,8 +278,10 @@ lt: Pakeitimų įsigaliojimas gali užtrukti. Jums bus pranešta, kai visi susiję darbo paketai bus atnaujinti. Ar tikrai norite tęsti? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ lt: label_create: "Kurti" label_create_work_package: "Kurti naują darbų paketą" label_created_by: "Sukūrė" + label_current: "current" label_date: "Data" label_date_with_format: "Įveskite %{date_attribute} naudodami šį formatą: %{format}" label_deactivate: "Išjungti" @@ -1188,6 +1193,11 @@ lt: one: "1 dieną" other: "%{count} dienas (-ą, -ų)" zero: "0 dienų" + word: + one: "1 word" + few: "%{count} words" + many: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Įjungti Zen režimą" button_deactivate: "Išjungti Zen režimą" diff --git a/config/locales/crowdin/js-lv.yml b/config/locales/crowdin/js-lv.yml index 9440bab5a8c9..8275a54e8493 100644 --- a/config/locales/crowdin/js-lv.yml +++ b/config/locales/crowdin/js-lv.yml @@ -138,6 +138,8 @@ lv: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ lv: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ lv: label_create: "Izveidot" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Datums" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deaktivizēt" @@ -1185,6 +1190,10 @@ lv: one: "1 dienas" other: "%{count} dienām" zero: "0 days" + word: + zero: "%{count} words" + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-mn.yml b/config/locales/crowdin/js-mn.yml index 99190a800ba7..ebfa0c211315 100644 --- a/config/locales/crowdin/js-mn.yml +++ b/config/locales/crowdin/js-mn.yml @@ -138,6 +138,8 @@ mn: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ mn: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ mn: label_create: "Create" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Date" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deactivate" @@ -1182,6 +1187,9 @@ mn: one: "1 day" other: "%{count} days" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-ms.yml b/config/locales/crowdin/js-ms.yml index a97e1ac6b8f6..215adb82447a 100644 --- a/config/locales/crowdin/js-ms.yml +++ b/config/locales/crowdin/js-ms.yml @@ -138,6 +138,8 @@ ms: description_select_work_package: "Pilih pakej kerja #%{id}" description_subwork_package: "Anak kepada pakej kerja #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Tukar mod tinjauan" source_code: "Tukar mod sumber Markdown" error_saving_failed: "Penyimpanan dokumen gagal dengan ralat yang berikut: %{error}" @@ -276,8 +278,10 @@ ms: Perubahan mungkin mengambil sedikit masa untuk berkesan. Anda akan dimaklumkan apabila semua pakej kerja yang berkaitan telah dikemas kini. Adakah anda pasti anda ingin teruskan? work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - Mengubah mod pengiraan perkembangan daripada berdasarkan-status kepada berdasarkan-kerja akan menjadikan % Selesai ruang yang tidak boleh diedit yang nilainya diperoleh daripada Kerja dan Kerja yang berbaki. Nilai yang sedia ada bagi % Selesai dikekalkan. Jika nilai Kerja dan Kerja yang berbaki tiada, nilai tersebut akan diperlukan untuk mengubah % Selesai. + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Mengubah mod pengiraan perkembangan daripada berasaskan-kerja kepada berasaskan-status akan menjadikan semua nilai % Selesai yang sedia ada hilang dan digantikan dengan nilai yang berkaitan dengan setiap status. Nilai sedia ada bagi Kerja yang berbaki juga akan dikira semula untuk menggambarkan perubahan ini. Tindakan ini tidak boleh dipulihkan. custom_actions: @@ -398,6 +402,7 @@ ms: label_create: "Cipta" label_create_work_package: "Cipta pakej kerja baharu" label_created_by: "Dicipta oleh" + label_current: "current" label_date: "Tarikh" label_date_with_format: "Masukkan %{date_attribute} menggunakan format berikut: %{format}" label_deactivate: "Nyahaktifkan" @@ -1179,6 +1184,8 @@ ms: one: "1 hari" other: "%{count} hari" zero: "0 hari" + word: + other: "%{count} words" zen_mode: button_activate: "Aktifkan mod zen" button_deactivate: "Nyahaktifkan mod zen" diff --git a/config/locales/crowdin/js-ne.yml b/config/locales/crowdin/js-ne.yml index b31d1666edbf..d20b15db62ad 100644 --- a/config/locales/crowdin/js-ne.yml +++ b/config/locales/crowdin/js-ne.yml @@ -138,6 +138,8 @@ ne: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ ne: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ ne: label_create: "Create" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Date" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deactivate" @@ -1182,6 +1187,9 @@ ne: one: "1 day" other: "%{count} days" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-nl.yml b/config/locales/crowdin/js-nl.yml index 4be9f106e041..01476b3fed01 100644 --- a/config/locales/crowdin/js-nl.yml +++ b/config/locales/crowdin/js-nl.yml @@ -138,6 +138,8 @@ nl: description_select_work_package: "Selecteer werk pakket #%{id}" description_subwork_package: "Kind van werkpakket #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Voorbeeld modus wijzigen" source_code: "Wissel Markdown bronmodus" error_saving_failed: "Het opslaan van het document is mislukt met de volgende foutmelding:%{error}" @@ -276,8 +278,10 @@ nl: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ nl: label_create: "Maken" label_create_work_package: "Nieuw werkpakket maken" label_created_by: "Gemaakt door" + label_current: "current" label_date: "Datum" label_date_with_format: "Geef de %{date_attribute} met gebruik van volgend formaat: %{format}" label_deactivate: "Deactiveren" @@ -1182,6 +1187,9 @@ nl: one: "1 dag" other: "%{count} dagen" zero: "0 dagen" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Zen-modus activeren" button_deactivate: "Deactiveren van zen modus" diff --git a/config/locales/crowdin/js-no.yml b/config/locales/crowdin/js-no.yml index 3c602175cee4..7758851695d3 100644 --- a/config/locales/crowdin/js-no.yml +++ b/config/locales/crowdin/js-no.yml @@ -102,7 +102,7 @@ button_save: "Lagre" button_settings: "Innstillinger" button_uncheck_all: "Avmerk alle" - button_update: "Oppdatèr" + button_update: "Oppdater" button_export-pdf: "Last ned PDF" button_export-atom: "Last ned Atom" button_create: "Opprett" @@ -138,6 +138,8 @@ description_select_work_package: "Velg arbeidspakke #%{id}" description_subwork_package: "Barn av arbeidspakke #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Veksle forhåndsvisningsmodus" source_code: "Veksle 'Markdown'-kildemodus" error_saving_failed: "Lagring av dokumentet mislyktes med følgende feil: %{error}" @@ -276,8 +278,10 @@ Endringene kan ta noe tid på å bli effektivisert. Du vil bli varslet når alle relevante arbeidspakker har blitt oppdatert. Er du sikker på at du vil fortsette? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ label_create: "Opprett" label_create_work_package: "Opprett ny arbeidspakke" label_created_by: "Opprettet av" + label_current: "current" label_date: "Dato" label_date_with_format: "Angi %{date_attribute} med følgende format: %{format}" label_deactivate: "Deaktiver" @@ -1182,6 +1187,9 @@ one: "1 dag" other: "%{count} dager" zero: "0 dager" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Aktiver zen modus" button_deactivate: "Deaktiver zen modus" diff --git a/config/locales/crowdin/js-pl.yml b/config/locales/crowdin/js-pl.yml index 6a21fff4139e..441f84c5c33b 100644 --- a/config/locales/crowdin/js-pl.yml +++ b/config/locales/crowdin/js-pl.yml @@ -138,6 +138,8 @@ pl: description_select_work_package: "Zaznacz zestaw Zadań #%{id}" description_subwork_package: "Otwórz zadanie-dziecko #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Przełącz tryb podglądu" source_code: "Przełącz tryb źródła Markdown" error_saving_failed: "Zapisywanie dokumentu nie powiodło się, błąd: %{error}" @@ -276,8 +278,10 @@ pl: Zmiany mogą wejść w życie po pewnym czasie. Gdy wszystkie odpowiednie pakiety robocze zostaną zaktualizowane, otrzymasz powiadomienie. Czy na pewno chcesz kontynuować? work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - Zmiana trybu obliczania postępu z opartego na statusie na oparty na pracy sprawi, że atrybut % ukończenia będzie nieedytowalnym polem, którego wartość pochodzi z atrybutów Praca i Pozostała praca. Istniejące wartości atrybutu % ukończenia zostaną zachowane. Jeśli wartości atrybutów Praca i Pozostała praca nie były obecne, będą one wymagane w celu zmiany wartości % ukończenia. + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Zmiana trybu obliczania postępu z opartego na pracy na oparty na statusie spowoduje, że wszystkie istniejące wartości % ukończenia zostaną utracone i zastąpione wartościami powiązanymi z poszczególnymi statusami. Istniejące wartości Pozostała praca mogą również zostać obliczone ponownie w celu odzwierciedlenia tej zmiany. Działanie to jest nieodwracalne. custom_actions: @@ -398,6 +402,7 @@ pl: label_create: "Utwórz" label_create_work_package: "Utwórz nowy pakiet roboczy" label_created_by: "Utworzony przez" + label_current: "current" label_date: "Data" label_date_with_format: "Wprowadź %{date_attribute} w następującym formacie: %{format}" label_deactivate: "Wyłącz" @@ -1188,6 +1193,11 @@ pl: one: "1 dzień" other: "%{count} dni" zero: "0 dni" + word: + one: "1 word" + few: "%{count} words" + many: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Włącz tryb zen" button_deactivate: "Wyłącz tryb zen" diff --git a/config/locales/crowdin/js-pt-BR.yml b/config/locales/crowdin/js-pt-BR.yml index eb0f0881cdda..63cb73415d72 100644 --- a/config/locales/crowdin/js-pt-BR.yml +++ b/config/locales/crowdin/js-pt-BR.yml @@ -138,6 +138,8 @@ pt-BR: description_select_work_package: "Selecionar o pacote de trabalho #%{id}" description_subwork_package: "Filho do pacote de trabalho #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Alternar modo de visualização" source_code: "Alternar para código Markdown" error_saving_failed: "Não foi possível salvar o documento pelo seguinte erro: %{error}" @@ -275,8 +277,10 @@ pt-BR: As alterações podem demorar algum tempo para entrar em vigor. Receberá uma notificação quando todos os pacotes de trabalho relevantes forem atualizados. Tem a certeza de que deseja continuar? work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - Alterar o modo de cálculo do progresso de "baseado em status" para "baseado em trabalho" tornará o campo % de conclusão não editável, com seu valor derivado de Trabalho e Trabalho Restante. Os valores existentes de % de conclusão serão preservados. Se os valores de Trabalho e Trabalho Restante não estiverem presentes, eles serão necessários para modificar a % de conclusão. + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Alterar o modo de cálculo do progresso de "baseado em trabalho" para "baseado em status" resultará na perda de todos os valores existentes de % de conclusão, que serão substituídos pelos valores associados a cada status. Os valores existentes de Trabalho restante também podem ser recalculados para refletir essa mudança. Essa ação é irreversível. custom_actions: @@ -397,6 +401,7 @@ pt-BR: label_create: "Criar" label_create_work_package: "Criar novo pacote de trabalho" label_created_by: "Criado por" + label_current: "current" label_date: "Data" label_date_with_format: "Insira a %{date_attribute} usando o seguinte formato: %{format}" label_deactivate: "Desativado" @@ -1181,6 +1186,9 @@ pt-BR: one: "1 dia" other: "%{count} dias" zero: "0 dias" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Ativar modo zen" button_deactivate: "Desativar modo zen" diff --git a/config/locales/crowdin/js-pt-PT.yml b/config/locales/crowdin/js-pt-PT.yml index 32545ca68cce..17a4c4e3e8da 100644 --- a/config/locales/crowdin/js-pt-PT.yml +++ b/config/locales/crowdin/js-pt-PT.yml @@ -138,6 +138,8 @@ pt-PT: description_select_work_package: "Selecionar pacote de trabalho #%{id}" description_subwork_package: "Filho de pacote de trabalho #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Alternar modo de pré-visualização" source_code: "Alternar modo de fonte do Markdown" error_saving_failed: "Ao guardar o documento ocorreu o seguinte erro: %{error}" @@ -276,8 +278,10 @@ pt-PT: As alterações podem demorar algum tempo a entrar em vigor. Receberá uma notificação quando todos os pacotes de trabalho relevantes forem atualizados. Tem a certeza de que quer continuar? work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - Alterar o modo de cálculo do progresso de "baseado no estado" para "baseado no trabalho" fará com que % Completo seja um campo não editável cujo valor é derivado de Trabalho e Trabalho restante. Os valores existentes para % Completo são preservados. Se os valores para Trabalho e Trabalho restante não estiverem presentes, eles serão necessários para alterar % Completo. + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Se alterar o modo de cálculo do progresso de "baseado no trabalho" para "baseado no estado", todos os valores % Completo existentes serão perdidos e substituídos por valores associados a cada estado. Os valores existentes para Trabalho restante também podem ser recalculados para refletir esta alteração. Esta ação não é reversível. custom_actions: @@ -398,6 +402,7 @@ pt-PT: label_create: "Criar" label_create_work_package: "Criar nova tarefa" label_created_by: "Criado por" + label_current: "current" label_date: "Data" label_date_with_format: "Digite o %{date_attribute} usando o seguinte formato: %{format}" label_deactivate: "Desativar" @@ -1182,6 +1187,9 @@ pt-PT: one: "1 dia" other: "%{count} dias" zero: "0 dias" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Ativar modo zen" button_deactivate: "Desativar modo zen" diff --git a/config/locales/crowdin/js-ro.yml b/config/locales/crowdin/js-ro.yml index 4fde82fcb61f..3f474cdde792 100644 --- a/config/locales/crowdin/js-ro.yml +++ b/config/locales/crowdin/js-ro.yml @@ -102,7 +102,7 @@ ro: button_save: "Salvează" button_settings: "Setări" button_uncheck_all: "Deselectează tot" - button_update: "Actualizare" + button_update: "Actualizează" button_export-pdf: "Descarcă PDF" button_export-atom: "Descarcă Atom" button_create: "Creează" @@ -138,6 +138,8 @@ ro: description_select_work_package: "Selectaţi pachetul de lucru #%{id}" description_subwork_package: "Fiu al pachetului de lucru #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Activaţi/Dezactivați previzualizarea" source_code: "Faceți click pentru a activa/dezactiva modul ierarhic." error_saving_failed: "Salvarea documentului a eșuat cu următoarea eroare: %{error}" @@ -275,8 +277,10 @@ ro: Modificările ar putea dura ceva timp pentru a produce efecte. Vei fi notificat când toate pachetele de lucru relevante au fost actualizate. Ești sigur că vrei să continui? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -397,6 +401,7 @@ ro: label_create: "Creare" label_create_work_package: "Creare pachet de lucru nou" label_created_by: "Creat de" + label_current: "current" label_date: "Dată" label_date_with_format: "Introduceţi %{date_attribute} folosind următorul format: %{format}" label_deactivate: "Dezactivare" @@ -752,7 +757,7 @@ ro: label: "Întrerupeți temporar memento-urile zilnice prin e-mail" first_day: "Prima zi" last_day: "Ultima zi" - text_are_you_sure: "Sunteți sigur?" + text_are_you_sure: "Ești sigur?" text_data_lost: "Toate datele introduse vor fi pierdute." text_user_wrote: "%{value} a scris:" types: @@ -1184,6 +1189,10 @@ ro: one: "1 zi" other: "%{count} zile" zero: "0 zile" + word: + one: "1 word" + few: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Activați modul zen" button_deactivate: "Dezactivați modul zen" diff --git a/config/locales/crowdin/js-ru.yml b/config/locales/crowdin/js-ru.yml index 8aa9574d25b7..b454f9ee123c 100644 --- a/config/locales/crowdin/js-ru.yml +++ b/config/locales/crowdin/js-ru.yml @@ -102,7 +102,7 @@ ru: button_save: "Сохранить" button_settings: "Настройки" button_uncheck_all: "Снять все отметки" - button_update: "Обновление" + button_update: "Обновить" button_export-pdf: "Скачать PDF" button_export-atom: "Скачать Atom" button_create: "Создать" @@ -138,6 +138,8 @@ ru: description_select_work_package: "Выберите пакет работ #%{id}" description_subwork_package: "Дочерний пакет работ #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Переключить режим предварительного просмотра" source_code: "В режим просмотра исходного кода " error_saving_failed: "Не удалось сохранить документ по следующей причине: %{error}" @@ -275,8 +277,10 @@ ru: Для вступления изменений в силу может потребоваться некоторое время. Вы будете уведомлены, когда все соответствующие пакеты работ будут обновлены. Хотите продолжить? work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - При изменении расчета прогресса с режима на основе статуса на режим на основе трудозатрат поле % Завершения станет нередактируемым, его значение будет получено из значений Работа и Оставшаяся работа. Существующие значения для % Завершения сохраняются. Если значения для Работа и Оставшаяся работа отсутствуют, они потребуются для изменения % Завершения. + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- При изменении расчета прогресса с режима на основе трудозатрат на режим на основе статуса все существующие значения % Завершения будут потеряны и заменены значениями, связанными с каждым статусом. Существующие значения параметра Оставшаяся работа также могут быть пересчитаны с учетом этого изменения. Это действие необратимо. custom_actions: @@ -397,6 +401,7 @@ ru: label_create: "Создать" label_create_work_package: "Создать новый пакет работ" label_created_by: "Автор" + label_current: "current" label_date: "Дата" label_date_with_format: "Введите %{date_attribute}, используя следующий формат: %{format}" label_deactivate: "Деактивировать" @@ -1187,6 +1192,11 @@ ru: one: "1 день" other: "%{count} дней" zero: "0 дней" + word: + one: "1 word" + few: "%{count} words" + many: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Включить полноэкранный режим" button_deactivate: "Отключить полноэкранный режим" diff --git a/config/locales/crowdin/js-rw.yml b/config/locales/crowdin/js-rw.yml index 35de85c5fe16..a4ae2d063591 100644 --- a/config/locales/crowdin/js-rw.yml +++ b/config/locales/crowdin/js-rw.yml @@ -138,6 +138,8 @@ rw: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ rw: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ rw: label_create: "Create" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Date" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deactivate" @@ -1182,6 +1187,9 @@ rw: one: "1 day" other: "%{count} days" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-si.yml b/config/locales/crowdin/js-si.yml index 320b439bc427..9ecf6bb32ce4 100644 --- a/config/locales/crowdin/js-si.yml +++ b/config/locales/crowdin/js-si.yml @@ -138,6 +138,8 @@ si: description_select_work_package: "වැඩ පැකේජය තෝරන්න #%{id}" description_subwork_package: "වැඩ පැකේජය දරුවා #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "පෙරදසුනෙහි මාදිලිය ටොගල් කරන්න" source_code: "සලකුණු කිරීමේ ප්රභව ප්රකාරය ටොගල් කරන්න" error_saving_failed: "පහත දැක්වෙන දෝෂය සමඟ ලේඛනය සුරැකීම අසාර්ථක විය: %{error}" @@ -276,8 +278,10 @@ si: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ si: label_create: "සාදන්න" label_create_work_package: "නව වැඩ පැකේජයක් සාදන්න" label_created_by: "විසින් නිර්මාණය" + label_current: "current" label_date: "දිනය" label_date_with_format: "පහත දැක්වෙන ආකෘතිය භාවිතා කරමින් %{date_attribute} ඇතුල් කරන්න: %{format}" label_deactivate: "අක්රිය කරන්න" @@ -1182,6 +1187,9 @@ si: one: "දින 1" other: "%{count} දින" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "සක්රිය මාදිලිය" button_deactivate: "සෙන් මාදිලිය අක්රිය" diff --git a/config/locales/crowdin/js-sk.yml b/config/locales/crowdin/js-sk.yml index 553ed4ddbf27..425e8805c4c8 100644 --- a/config/locales/crowdin/js-sk.yml +++ b/config/locales/crowdin/js-sk.yml @@ -138,6 +138,8 @@ sk: description_select_work_package: "Vyberte pracovný balík #%{id}" description_subwork_package: "Podradený pracovný balík #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Prepnúť do režimu náhľadu" source_code: "Prepnúť do režimu Markdown" error_saving_failed: "Uloženie dokumentu zlyhalo s nasledujúcou chybou: %{error}" @@ -276,8 +278,10 @@ sk: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ sk: label_create: "Vytvoriť" label_create_work_package: "Vytvoriť nový pracovný balíček" label_created_by: "Vytvoril(a)" + label_current: "current" label_date: "Dátum" label_date_with_format: "Zadajte %{date_attribute} v tomto formáte: %{format}" label_deactivate: "Deaktivovať" @@ -1188,6 +1193,11 @@ sk: one: "1 deň" other: "%{count} dní" zero: "0 days" + word: + one: "1 word" + few: "%{count} words" + many: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Aktivovať zen režim" button_deactivate: "Deaktivovať zen režim" diff --git a/config/locales/crowdin/js-sl.yml b/config/locales/crowdin/js-sl.yml index 73c2f3d40931..75ad600e70dc 100644 --- a/config/locales/crowdin/js-sl.yml +++ b/config/locales/crowdin/js-sl.yml @@ -138,6 +138,8 @@ sl: description_select_work_package: "Izberi delovni paket #%{id}" description_subwork_package: "Podrejen delovni paket #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Preklopi način predogleda" source_code: "Preklopite vhodni način označevanja" error_saving_failed: "Shranjevanje dokumenta ni uspelo zaradi napake: %{error}" @@ -275,8 +277,10 @@ sl: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -397,6 +401,7 @@ sl: label_create: "Ustvari" label_create_work_package: "Ustvari delovni paket" label_created_by: "Ustvaril" + label_current: "current" label_date: "Datum" label_date_with_format: "Vstavi %{date_attribute} tako da uporabiš format: %{format}" label_deactivate: "Onemogoči" @@ -1187,6 +1192,11 @@ sl: one: "1 dan" other: "%{count} dni" zero: "0 days" + word: + one: "1 word" + two: "%{count} words" + few: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Omogočite zen način" button_deactivate: "Onemogočite zen način" diff --git a/config/locales/crowdin/js-sr.yml b/config/locales/crowdin/js-sr.yml index 5308d001aca9..ddf5b8630abd 100644 --- a/config/locales/crowdin/js-sr.yml +++ b/config/locales/crowdin/js-sr.yml @@ -138,6 +138,8 @@ sr: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ sr: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ sr: label_create: "Create" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Date" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deactivate" @@ -1185,6 +1190,10 @@ sr: one: "1 day" other: "%{count} days" zero: "0 days" + word: + one: "1 word" + few: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-sv.yml b/config/locales/crowdin/js-sv.yml index 70e9dfb8f36f..ab63025c4242 100644 --- a/config/locales/crowdin/js-sv.yml +++ b/config/locales/crowdin/js-sv.yml @@ -138,6 +138,8 @@ sv: description_select_work_package: "Välj arbetspaket #%{id}" description_subwork_package: "Barn till arbetspaket #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Växla förhandsgranskningsläge" source_code: "Växla markdown-källläge" error_saving_failed: "Misslyckades med att spara dokumentet på grund av följande fel: %{error}" @@ -275,8 +277,10 @@ sv: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -397,6 +401,7 @@ sv: label_create: "Skapa" label_create_work_package: "Skapa nya arbetspaket" label_created_by: "Skapad av" + label_current: "current" label_date: "Datum" label_date_with_format: "Ange %{date_attribute} med följande format: %{format}" label_deactivate: "Deaktivera" @@ -1181,6 +1186,9 @@ sv: one: "1 dag" other: "%{count} dagar" zero: "0 dagar" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Aktivera zen-läge" button_deactivate: "Inaktivera avskalat läge" diff --git a/config/locales/crowdin/js-th.yml b/config/locales/crowdin/js-th.yml index 6f3ac79579e7..8b49d1ff8034 100644 --- a/config/locales/crowdin/js-th.yml +++ b/config/locales/crowdin/js-th.yml @@ -138,6 +138,8 @@ th: description_select_work_package: "เลือกแพ็คเกจงาน #%{id}" description_subwork_package: "แพ็คเกจงานย่อย #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "สลับโหมดแสดงตัวอย่าง" source_code: "Toggle Markdown source mode" error_saving_failed: "การบันทึกเอกสารล้มเหลวด้วยข้อผิดพลาดต่อไปนี้: %{error}" @@ -276,8 +278,10 @@ th: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ th: label_create: "สร้าง" label_create_work_package: "สร้างชุดภารกิจใหม่" label_created_by: "Created by" + label_current: "current" label_date: "วันที่" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "ปิดใช้งาน" @@ -1179,6 +1184,8 @@ th: one: "1 day" other: "%{count} วัน" zero: "0 days" + word: + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-tr.yml b/config/locales/crowdin/js-tr.yml index d0da66f2e1fc..8e2568d6c52e 100644 --- a/config/locales/crowdin/js-tr.yml +++ b/config/locales/crowdin/js-tr.yml @@ -138,6 +138,8 @@ tr: description_select_work_package: "#%{id} nolu iş paketini seçin" description_subwork_package: "#%{id} nolu iş paketinin alt parçası" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Önizleme modunu aç/kapat" source_code: "Markdown kaynak modunu değiştir" error_saving_failed: "Aşağıdaki nedenden dolayı belge kayıt edilemedi: %{error}" @@ -275,8 +277,10 @@ tr: warning: > Değişikliklerin geçerlilik kazanması biraz zaman alabilir. İlgili tüm iş paketleri güncellendiğinde bilgilendirileceksiniz. Devam etmek istediğine emin misin? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -397,6 +401,7 @@ tr: label_create: "Oluştur" label_create_work_package: "Yeni iş paketi oluştur" label_created_by: "Oluşturan" + label_current: "current" label_date: "Tarih" label_date_with_format: "Aşağıdaki biçimi kullanarak %{date_attribute} girin: %{format}" label_deactivate: "Etkisizleştir" @@ -1181,6 +1186,9 @@ tr: one: "1 gün" other: "%{count} gün" zero: "0 gün" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Zen modunu etkinleştir" button_deactivate: "Zen modunu devre dışı bırak" diff --git a/config/locales/crowdin/js-uk.yml b/config/locales/crowdin/js-uk.yml index bf0ed75df078..a9a929d4e2cf 100644 --- a/config/locales/crowdin/js-uk.yml +++ b/config/locales/crowdin/js-uk.yml @@ -138,6 +138,8 @@ uk: description_select_work_package: "Виберіть пакет робіт #%{id}" description_subwork_package: "Нащадок пакету робіт #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Перемкнути режим попереднього перегляду" source_code: "Увімкнути режим вимкнення Markdown" error_saving_failed: "Не вдалося зберегти документ із такою помилкою: %{error}" @@ -276,8 +278,10 @@ uk: Застосування змін може тривати деякий час. Ви отримаєте сповіщення, коли всі відповідні пакети робіт буде оновлено. Продовжити? work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - Якщо перейти з режиму обчислення прогресу на основі статусу на режим на основі робіт, атрибут % завершення стане недоступним для редагування полем, значення якого отримуватиметься зі значень атрибутів Робота й Залишок роботи. Наявні значення атрибута % завершення буде збережено. Якщо значення атрибутів Робота й Залишок роботи не задано, їх потрібно буде задати, щоб змінити значення атрибута % завершення. + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Якщо перейти з режиму обчислення прогресу на основі робіт на режим на основі статусу, усі наявні значення атрибута % завершення буде втрачено й замінено значеннями, пов’язаними з кожним статусом. Наявні значення атрибута Залишок роботи може бути також переобчислено з урахуванням цієї зміни. Цю дію не можна скасувати. custom_actions: @@ -398,6 +402,7 @@ uk: label_create: "Створити" label_create_work_package: "Створити новий робочий пакет" label_created_by: "Створено" + label_current: "current" label_date: "Дата" label_date_with_format: "Введіть %{date_attribute}, використовуючи наступний формат: %{format}" label_deactivate: "Деактивувати" @@ -1188,6 +1193,11 @@ uk: one: "1 день" other: "%{count} д." zero: "0 днів" + word: + one: "1 word" + few: "%{count} words" + many: "%{count} words" + other: "%{count} words" zen_mode: button_activate: "Активуйте режим дзен" button_deactivate: "Деактивуйте режим дзен" diff --git a/config/locales/crowdin/js-uz.yml b/config/locales/crowdin/js-uz.yml index 598bfb848769..4615140e34d8 100644 --- a/config/locales/crowdin/js-uz.yml +++ b/config/locales/crowdin/js-uz.yml @@ -138,6 +138,8 @@ uz: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -276,8 +278,10 @@ uz: The changes might take some time to take effect. You will be notified when all relevant work packages have been updated. Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values associated with each status. Existing values for Remaining work may also be recalculated to reflect this change. This action is not reversible. custom_actions: @@ -398,6 +402,7 @@ uz: label_create: "Create" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Date" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deactivate" @@ -1182,6 +1187,9 @@ uz: one: "1 day" other: "%{count} days" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/locales/crowdin/js-vi.yml b/config/locales/crowdin/js-vi.yml index 913476e9125b..665f62f99cee 100644 --- a/config/locales/crowdin/js-vi.yml +++ b/config/locales/crowdin/js-vi.yml @@ -102,7 +102,7 @@ vi: button_save: "Lưu" button_settings: "Cài đặt" button_uncheck_all: "Bỏ chọn tất cả" - button_update: "Cập Nhật" + button_update: "Cập nhật" button_export-pdf: "Tải xuống PDF" button_export-atom: "Tải xuống Atom" button_create: "Tạo" @@ -138,6 +138,8 @@ vi: description_select_work_package: "Chọn công việc #%{id}" description_subwork_package: "Con của công việc #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Chuyển đổi chế độ xem trước" source_code: "Chuyển đổi chế độ mã Markdown" error_saving_failed: "Lưu tài liệu không thành công với lỗi sau: %{error}" @@ -276,8 +278,10 @@ vi: Các thay đổi có thể mất một thời gian để có hiệu lực. Bạn sẽ được thông báo khi tất cả các công việc liên quan đã được cập nhật. Bạn có chắc chắn muốn tiếp tục không? work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - Thay đổi chế độ tính toán tiến độ từ dựa trên trạng thái sang dựa trên công việc sẽ làm cho % Hoàn thành trở thành trường không thể chỉnh sửa, giá trị của nó được lấy từ Công việcCông việc còn lại. Các giá trị hiện tại cho % Hoàn thành sẽ được giữ lại. Nếu các giá trị cho Công việcCông việc còn lại không có, chúng sẽ được yêu cầu để thay đổi % Hoàn thành. + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Thay đổi chế độ tính toán tiến độ từ dựa trên công việc sang dựa trên trạng thái sẽ dẫn đến việc tất cả các giá trị hiện tại của % Hoàn thành bị mất và thay thế bằng các giá trị liên kết với từng trạng thái. Các giá trị hiện tại cho Công việc còn lại cũng có thể được tính lại để phản ánh sự thay đổi này. Hành động này không thể hoàn tác. custom_actions: @@ -398,6 +402,7 @@ vi: label_create: "Tạo" label_create_work_package: "Tạo gói công việc mới" label_created_by: "Được tạo bởi" + label_current: "current" label_date: "Ngày" label_date_with_format: "Nhập %{date_attribute} theo định dạng sau: %{format}" label_deactivate: "Hủy kích hoạt" @@ -1179,6 +1184,8 @@ vi: one: "1 ngày" other: "%{count} ngày" zero: "0 ngày" + word: + other: "%{count} words" zen_mode: button_activate: "Kích hoạt chế độ Zen" button_deactivate: "Tắt chế độ Zen" diff --git a/config/locales/crowdin/js-zh-CN.yml b/config/locales/crowdin/js-zh-CN.yml index 004167832401..e70f8b25452e 100644 --- a/config/locales/crowdin/js-zh-CN.yml +++ b/config/locales/crowdin/js-zh-CN.yml @@ -138,6 +138,8 @@ zh-CN: description_select_work_package: "选择工作包 #%{id}" description_subwork_package: "子工作包 #%{id}" editor: + revisions: "显示本地修改" + no_revisions: "未找到本地修改" preview: "切换预览模式" source_code: "切换 Markdown 模式" error_saving_failed: "保存文档失败,出现以下错误:%{error}" @@ -275,8 +277,10 @@ zh-CN: warning: > 更改可能需要一些时间才能生效。当更新完所有相关工作包时,您将收到通知。 work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + 将进度计算模式从基于状态改为基于工时,将使% 完成变为不可编辑字段,其值来自工时剩余工时% 完成现有值将保留。如果没有 工时剩余工时的值,则需要这些值才能更改 % 完成。 warning_progress_calculation_mode_change_from_status_to_field_html: >- - 将进度计算模式从基于状态改为基于工作,将使完成百分比成为不可编辑字段,其值来自工作剩余工时完成百分比的现有值将保留。如果没有 "工时"和 "剩余工作"的值,则需要这些值才能更改 "完成百分比"。 + 将进度计算模式从基于状态改为基于工时,将使% 完成字段可自由编辑。如果您选择输入工时剩余工时的值,它们也将与% 完成相关联。更改剩余工时就可以更新% 完成。 warning_progress_calculation_mode_change_from_field_to_status_html: >- 将进度计算模式从基于工时的方式改为基于状态,将会导致所有现有的 %完整的 值丢失,并被与每个状态相关的值所替代。 剩余工时 的现有值也可能被重新计算,以反映这种变化。此操作不可逆转。 custom_actions: @@ -397,6 +401,7 @@ zh-CN: label_create: "创建" label_create_work_package: "创建新工作包" label_created_by: "创建自" + label_current: "当前" label_date: "日期" label_date_with_format: "以%{format} 的格式输入 %{date_attribute}" label_deactivate: "停用" @@ -1178,6 +1183,8 @@ zh-CN: one: "1 天" other: "%{count} 天" zero: "0 天" + word: + other: "%{count} words" zen_mode: button_activate: "激活 zen 模式" button_deactivate: "取消激活 zen 模式" diff --git a/config/locales/crowdin/js-zh-TW.yml b/config/locales/crowdin/js-zh-TW.yml index 3fbb0a03eeb7..c9bc01ae3ace 100644 --- a/config/locales/crowdin/js-zh-TW.yml +++ b/config/locales/crowdin/js-zh-TW.yml @@ -138,6 +138,8 @@ zh-TW: description_select_work_package: "選取工作項目 #%{id}" description_subwork_package: "子工作項目 #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "切換預覽模式" source_code: "切換Markdown模式" error_saving_failed: "保存文件失敗, 出現以下錯誤: %{error}" @@ -274,8 +276,10 @@ zh-TW: warning: > 更改可能需要一些時間才能生效。當更新完所有相關工作包時,您將收到通知。 work_packages_settings: + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- + Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. warning_progress_calculation_mode_change_from_status_to_field_html: >- - 將進度計算模式從基於狀態改為基於工作,將使完成百分比成為不可編輯字段,其值來自工作剩餘工時完成百分比的現有值將保留。如果沒有 "工時"和 "剩餘工作"的值,則需要這些值才能更改 "完成百分比"。 + Changing progress calculation mode from status-based to work-based will make the % Complete field freely editable. If you optionally enter values for Work or Remaining work, they will also be linked to % Complete. Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- 將進度計算模式從基於工時的方式改為基於狀態,將會導致所有現有的 %完整的 值丟失,並被與每個狀態相關的值所替代。 剩餘工時 的現有值也可能被重新計算,以反映這種變化。此操作不可逆轉。 custom_actions: @@ -396,6 +400,7 @@ zh-TW: label_create: "建立" label_create_work_package: "建立新的工作項目" label_created_by: "建立者:" + label_current: "目前" label_date: "日期" label_date_with_format: "輸入 %{date_attribute} 使用以下格式: %{format}" label_deactivate: "停用" @@ -1177,6 +1182,8 @@ zh-TW: one: "1 天" other: "%{count} 天" zero: "0 天" + word: + other: "%{count} words" zen_mode: button_activate: "啟動 zen 模式" button_deactivate: "停用 zen 模式" diff --git a/config/locales/crowdin/ka.yml b/config/locales/crowdin/ka.yml index f147e65dd84b..c334143978e9 100644 --- a/config/locales/crowdin/ka.yml +++ b/config/locales/crowdin/ka.yml @@ -1040,10 +1040,10 @@ ka: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1073,15 +1073,17 @@ ka: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ ka: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ ka: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ ka: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "კომენტარი" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/kk.yml b/config/locales/crowdin/kk.yml index bbee919bdbde..b27671681648 100644 --- a/config/locales/crowdin/kk.yml +++ b/config/locales/crowdin/kk.yml @@ -1040,10 +1040,10 @@ kk: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1073,15 +1073,17 @@ kk: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ kk: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ kk: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ kk: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comment" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/ko.yml b/config/locales/crowdin/ko.yml index 3260a8347a8f..82c093b93630 100644 --- a/config/locales/crowdin/ko.yml +++ b/config/locales/crowdin/ko.yml @@ -1032,10 +1032,10 @@ ko: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "- 작업과 남은 작업이 일치하지 않습니다" - cannot_be_set_when_work_is_zero: "- 작업이 0인 경우 설정할 수 없습니다" - must_be_set_when_remaining_work_is_set: "'남은 작업'이 설정된 경우 필수입니다." - must_be_set_when_work_and_remaining_work_are_set: "'작업' 및 '남은 작업'이 설정된 경우 필수입니다." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "- 0에서 100 사이여야 합니다." due_date: not_start_date: "마일스톤에서 요구하지만, 시작 날짜가 없음" @@ -1065,15 +1065,17 @@ ko: does_not_exist: "지정한 카테고리가 존재하지 않습니다." estimated_hours: not_a_number: "- 유효한 기간이 아닙니다." - cant_be_inferior_to_remaining_work: "남은 작업보다 낮을 수 없습니다." - must_be_set_when_remaining_work_and_percent_complete_are_set: "'남은 작업' 및 '완료 %'가 설정된 경우 필수입니다." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "- 유효한 기간이 아닙니다." - cant_exceed_work: "작업보다 높을 수 없습니다." - must_be_set_when_work_is_set: "작업이 설정된 경우 필수입니다." - must_be_set_when_work_and_percent_complete_are_set: "'작업' 및 '완료 %'가 설정된 경우 필수입니다." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "작업 패키지가 읽기 전용 상태이므로 해당 속성을 변경할 수 없습니다." type: attributes: @@ -1624,7 +1626,8 @@ ko: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3076,8 +3079,10 @@ ko: setting_work_package_done_ratio: "진행률 계산" setting_work_package_done_ratio_field: "작업 기반" setting_work_package_done_ratio_status: "상태 기반" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - 작업 기반 모드에서 완료 %는 총 작업 대비 완료된 작업을 기준으로 계산됩니다. 상태 기반 모드에서는 각 상태에 완료 % 값이 연결되어 있습니다. 상태를 변경하면 완료 %도 변경됩니다. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "작업 패키지 속성" setting_work_package_startdate_is_adddate: "새 작업 패키지에 대한 시작 날짜로 현재 날짜 사용" setting_work_packages_projects_export_limit: "작업 패키지/프로젝트 내보내기 제한" @@ -3459,9 +3464,26 @@ ko: progress: label_note: "참고:" modal: - work_based_help_text: "완료 %는 작업 및 남은 작업에서 자동으로 파생됩니다." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "완료 %는 작업 패키지 상태에 따라 설정됩니다." migration_warning_text: "작업 기반 진행률 계산 모드에서 완료 %는 수동으로 설정할 수 없으며 작업에 연결됩니다. 기존 값은 유지되지만 편집할 수 없습니다. 먼저 작업을 입력하세요." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "코멘트" comment_description: "이 작업 패키지를 보고 코멘트를 작성할 수 있습니다." diff --git a/config/locales/crowdin/lt.yml b/config/locales/crowdin/lt.yml index d21be5617dac..1e69aa7281fb 100644 --- a/config/locales/crowdin/lt.yml +++ b/config/locales/crowdin/lt.yml @@ -1051,10 +1051,10 @@ lt: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Privaloma, kai nustatytas likęs darbas." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "nėra pradžios data, nors tai reikalinga svarbiems etapams." @@ -1084,15 +1084,17 @@ lt: does_not_exist: "Nurodyta kategorija neegzistuoja." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Negali būti mažesnis už likusį darbą." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Negali būdi daugiau nei Darbas." - must_be_set_when_work_is_set: "Privaloma, kai nustatytas Darbas." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Darbo paketas yra tik skaitymo būsenoje, taigi jo atributų keisti negalima." type: attributes: @@ -1727,7 +1729,8 @@ lt: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3184,8 +3187,10 @@ lt: setting_work_package_done_ratio: "Eigos skaičiavimas" setting_work_package_done_ratio_field: "Pagal-darbą" setting_work_package_done_ratio_status: "Pagal-būseną" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - Režime pagal-darbą, pabaigimo % skaičiuojami pagal tai, kiek darbo atlikta lyginant su visu darbo kiekiu. Režime pagal-būseną, kiekvienas būsenas turi savo susijusią baigtumo % reikšmę. Pakeitus būseną pasikeis ir % baigta. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Darbų paketo ypatybės" setting_work_package_startdate_is_adddate: "Naudoti dabartinę datą kaip naujų darbų paketų pradžios datą" setting_work_packages_projects_export_limit: "Darbo paketų / Projektų eksporto limitas" @@ -3569,9 +3574,26 @@ lt: progress: label_note: "Pastaba:" modal: - work_based_help_text: "% baigta automatiškai skaičiuojama pagal Darbą ir Likusį darbą." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% baigta nustatoma pagal paketo būseną." migration_warning_text: "Darbu paremtame eigos skaičiavimo režime % baigta negali būti nustatomas rankomis ir yra susietas su darbu. Esamos reikšmės buvo išlaikytos, bet negali būti keičiamos. Prašome iš pradžių įveskite darbą." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Komentaras" comment_description: "Gali žiūrėti ir komentuoti šį darbo paketą." diff --git a/config/locales/crowdin/lv.yml b/config/locales/crowdin/lv.yml index 5d836bef386a..0d2c068d97db 100644 --- a/config/locales/crowdin/lv.yml +++ b/config/locales/crowdin/lv.yml @@ -1047,10 +1047,10 @@ lv: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "nav sākuma datums, kaut arī tas ir nepieciešams atskaites punktam." @@ -1080,15 +1080,17 @@ lv: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1695,7 +1697,8 @@ lv: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3154,8 +3157,10 @@ lv: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3539,9 +3544,26 @@ lv: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Komentârs" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/mn.yml b/config/locales/crowdin/mn.yml index 7c7de23fd470..98d5253536c9 100644 --- a/config/locales/crowdin/mn.yml +++ b/config/locales/crowdin/mn.yml @@ -1040,10 +1040,10 @@ mn: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1073,15 +1073,17 @@ mn: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ mn: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ mn: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ mn: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comment" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/ms.yml b/config/locales/crowdin/ms.yml index f5559f9e5978..b7663e3af9cf 100644 --- a/config/locales/crowdin/ms.yml +++ b/config/locales/crowdin/ms.yml @@ -1031,10 +1031,10 @@ ms: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Diperlukan apabila kerja yang Berbaki ditetapkan." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "bukan pada tarikh mula, walaupun ini diperlukan untuk pencapaian." @@ -1064,15 +1064,17 @@ ms: does_not_exist: "Kategori yang ditentukan tidak wujud." estimated_hours: not_a_number: "bukan jangka masa yang sah." - cant_be_inferior_to_remaining_work: "Tidak boleh lebih rendah daripada kerja yang Berbaki." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "bukan jangka masa yang sah." - cant_exceed_work: "Tidak boleh lebih tinggi daripada Kerja." - must_be_set_when_work_is_set: "Diperlukan apabila Kerja ditetapkan." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Pakej kerja berada dalam status baca sahaja maka atributnya tidak boleh diubah." type: attributes: @@ -1623,7 +1625,8 @@ ms: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3076,8 +3079,10 @@ ms: setting_work_package_done_ratio: "Pengiraan perkembangan" setting_work_package_done_ratio_field: "Berasaskan kerja" setting_work_package_done_ratio_status: "Berasaskan status" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - Di mod berasaskan kerja, % Selesai dikira daripada berapa banyak kerja yang telah siap berhubungan dengan jumlah kerja. Di mod berasaskan status, setiap status mempunyai kadar % Selesai berkait dengannya. Pertukaran status akan mengubah % Selesai. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Ciri-ciri pakej kerja" setting_work_package_startdate_is_adddate: "Guna tarikh semasa sebagai tarikh mula untuk pakej kerja baharu" setting_work_packages_projects_export_limit: "Pakej kerja / Had eksport projek" @@ -3459,9 +3464,26 @@ ms: progress: label_note: "Perhatian:" modal: - work_based_help_text: "% Selesai secara automatik diperolehi daripada Kerja dan Kerja yang berbaki." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Selesai ditetapkan oleh status pakej kerja." migration_warning_text: "Dalam mod pengiraan perkembangan berdasarkan kerja, % Selesai tidak boleh ditetapkan secara manual dan ianya terikat kepada Kerja. Nilai sedia ada tersebut telah disimpan tetapi tidak boleh diedit. Sila input Kerja dahulu." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Komen" comment_description: "Boleh lihat dan komen berkenaan pakej kerja ini." diff --git a/config/locales/crowdin/ne.yml b/config/locales/crowdin/ne.yml index a2f21dce670e..c17c821777e2 100644 --- a/config/locales/crowdin/ne.yml +++ b/config/locales/crowdin/ne.yml @@ -1040,10 +1040,10 @@ ne: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1073,15 +1073,17 @@ ne: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ ne: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ ne: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ ne: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comment" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/nl.yml b/config/locales/crowdin/nl.yml index f99888e32180..979bea334719 100644 --- a/config/locales/crowdin/nl.yml +++ b/config/locales/crowdin/nl.yml @@ -1037,10 +1037,10 @@ nl: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Vereist wanneer Resterend werk is ingesteld." - must_be_set_when_work_and_remaining_work_are_set: "Vereist wanneer Werk en Resterend werk zijn ingesteld." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "moet tussen 0 en 100 liggen." due_date: not_start_date: "is niet op begindatum, hoewel dit voor mijlpalen vereist is." @@ -1070,15 +1070,17 @@ nl: does_not_exist: "De gekozen categorie bestaat niet." estimated_hours: not_a_number: "is geen geldige duur." - cant_be_inferior_to_remaining_work: "Kan niet lager zijn dan Resterend werk." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Vereist wanneer Resterend werk en % Voltooid zijn ingesteld." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is geen geldige duur." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Vereist wanneer Werk is ingesteld." - must_be_set_when_work_and_percent_complete_are_set: "Vereist wanneer Werk en % Voltooid zijn ingesteld." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Het werkpakket heeft een alleen-lezen status dus kunne attributen niet worden gewijzigd." type: attributes: @@ -1657,7 +1659,8 @@ nl: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3113,8 +3116,10 @@ nl: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Werkpakketeigenschappen" setting_work_package_startdate_is_adddate: "Huidige datum als begindatum voor nieuwe werkpakketten gebruiken" setting_work_packages_projects_export_limit: "Werkpakketten / Projecten exportlimiet" @@ -3496,9 +3501,26 @@ nl: progress: label_note: "Opmerking:" modal: - work_based_help_text: "% Voltooid wordt automatisch afgeleid van Werk en Resterend werk." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Voltooid wordt ingesteld door de status van het werkpakket." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Commentaar" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/no.yml b/config/locales/crowdin/no.yml index 2fd4b4cac66d..9e5bea29f725 100644 --- a/config/locales/crowdin/no.yml +++ b/config/locales/crowdin/no.yml @@ -1039,10 +1039,10 @@ assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "samsvarer ikke med arbeid og arbeid som gjenstår" - cannot_be_set_when_work_is_zero: "kan ikke angis når arbeidet er null" - must_be_set_when_remaining_work_is_set: "Påkrevd når gjenværende arbeid er satt." - must_be_set_when_work_and_remaining_work_are_set: "Påkrevd når arbeid og gjenstående arbeid settes." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "må være mellom 0 og 100." due_date: not_start_date: "er ikke på startdato, selv om dette er nødvendig for milepæler." @@ -1072,15 +1072,17 @@ does_not_exist: "Den angitte kategorien finnes ikke." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Kan ikke være lavere enn gjenstående arbeid." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Påkrevd når gjenværende arbeid og % Fullført er satt." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Kan ikke være høyere enn arbeidet." - must_be_set_when_work_is_set: "Påkrevet når arbeidet settes." - must_be_set_when_work_and_percent_complete_are_set: "Påkrevd når gjenværende arbeid og % Fullført er satt." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Arbeidspakken er i skrivebeskyttet status slik at egenskapene ikke kan endres." type: attributes: @@ -1659,7 +1661,8 @@ xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3116,8 +3119,10 @@ setting_work_package_done_ratio: "Beregning av fremdrift" setting_work_package_done_ratio_field: "Arbeidsbasert" setting_work_package_done_ratio_status: "Statusbasert" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - I arbeidsbasert modus, beregnes % Ferdig ut fra hvor mye arbeid som er gjort i forhold til det totale arbeidet. I -statusbasert modus har hver status en % Ferdig verdi knyttet til den. Endring av status vil endre % Ferdig. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Egenskaper for arbeidspakke" setting_work_package_startdate_is_adddate: "Bruk gjeldende dato som startdato for nye arbeidspakker" setting_work_packages_projects_export_limit: "Eksportgrense for arbeidspakker/prosjekter" @@ -3500,9 +3505,26 @@ progress: label_note: "Merk:" modal: - work_based_help_text: "% Ferdig utledes automatisk fra arbeid og gjenstående arbeid." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Ferdig er angitt etter status på arbeidspakken." migration_warning_text: "I arbeidsbasert fremdriftsberegningsmodus kan % Ferdig ferdigstilt ikke settes manuelt og er knyttet til jobber. Den eksisterende verdien er lagret, men kan ikke endres. Skriv inn arbeidet først." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Kommentar" comment_description: "Kan se og kommentere denne arbeidspakken." diff --git a/config/locales/crowdin/pl.yml b/config/locales/crowdin/pl.yml index 36bb718fd034..f8ee29dc4695 100644 --- a/config/locales/crowdin/pl.yml +++ b/config/locales/crowdin/pl.yml @@ -818,7 +818,7 @@ pl: confirmation: "nie pasuje do %{attribute}." could_not_be_copied: "Nie można było (w pełni) skopiować %{dependency}." does_not_exist: "nie istnieje." - error_enterprise_only: "%{action} jest dostępna tylko w OpenProject Enterprise edition" + error_enterprise_only: "%{action} jest dostępna tylko w OpenProject Enterprise Edition" error_unauthorized: "— nie można uzyskac dostępu." error_readonly: "— podjęto próbę zapisu, ale nie jest zapisywalny." error_conflict: "Information has been updated by at least one other user in the meantime." @@ -1051,10 +1051,10 @@ pl: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "nie odpowiada pracy i pozostałej pracy" - cannot_be_set_when_work_is_zero: "nie można ustawić, gdy praca wynosi zero" - must_be_set_when_remaining_work_is_set: "Wymagane, gdy ustawiona jest opcja Pozostała praca." - must_be_set_when_work_and_remaining_work_are_set: "Wymagane, gdy ustawione są opcje Praca i Pozostała praca." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "musi wynosić od 0 do 100." due_date: not_start_date: "nie jest w dniu rozpoczęcia, chociaż jest to wymagane dla Kamieni Milowych." @@ -1084,15 +1084,17 @@ pl: does_not_exist: "Podana kategoria nie istnieje." estimated_hours: not_a_number: "nie jest prawidłowym czasem trwania." - cant_be_inferior_to_remaining_work: "Nie może być mniejsza niż wartość pozostałej pracy." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Wymagane, gdy ustawione są opcje Pozostała praca i % ukończenia." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "nie jest prawidłowym czasem trwania." - cant_exceed_work: "Nie może być wyższa niż wartość pracy." - must_be_set_when_work_is_set: "Wymagane, gdy ustawiona jest opcja Praca." - must_be_set_when_work_and_percent_complete_are_set: "Wymagane, gdy ustawione są opcje Praca i % ukończenia." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Pakiet roboczy ma status tylko do odczytu, więc jego atrybutów nie można zmienić." type: attributes: @@ -1727,7 +1729,8 @@ pl: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3185,8 +3188,10 @@ pl: setting_work_package_done_ratio: "Obliczenie postępu" setting_work_package_done_ratio_field: "Oparte na pracy" setting_work_package_done_ratio_status: "Oparte na statusie" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - W trybie opartym na pracy % ukończenia jest obliczany na podstawie ilości wykonanej pracy w stosunku do pracy całkowitej. W trybie opartym na statusie każdy status ma powiązaną wartość % ukończenia. Zmiana statusu spowoduje zmianę % ukończenia. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Właściwości pakietu roboczego" setting_work_package_startdate_is_adddate: "Użyj bieżącej daty jako daty początkowej dla nowych pakietów roboczych" setting_work_packages_projects_export_limit: "Limit eksportu pakietów roboczych / projektów" @@ -3571,9 +3576,26 @@ pl: progress: label_note: "Uwaga:" modal: - work_based_help_text: "% ukończenia jest automatycznie wyprowadzany z wartości Praca i Pozostała praca." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% ukończenia jest ustawiany na podstawie statusu pakietu roboczego." migration_warning_text: "W trybie obliczania postępu na podstawie pracy wartości % ukończenia nie można ustawić ręcznie i jest ona powiązana z wartością Praca. Istniejąca wartość została zachowana, ale nie można jej edytować. Najpierw wprowadź wartość Praca." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Komentarz" comment_description: "Może wyświetlać i komentować ten pakiet roboczy." diff --git a/config/locales/crowdin/pt-BR.yml b/config/locales/crowdin/pt-BR.yml index eab9dd2929d1..c57cc6f876fc 100644 --- a/config/locales/crowdin/pt-BR.yml +++ b/config/locales/crowdin/pt-BR.yml @@ -1038,10 +1038,10 @@ pt-BR: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "não corresponde ao trabalho e ao trabalho restante" - cannot_be_set_when_work_is_zero: "não pode ser definido quando o trabalho é zero" - must_be_set_when_remaining_work_is_set: "Necessário quando o Trabalho restante for definido." - must_be_set_when_work_and_remaining_work_are_set: "Necessário quando o Trabalho e o Trabalho restante são definidos." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "deve estar entre 0 e 100." due_date: not_start_date: "não é na data de início, embora isso seja necessário para os marcos." @@ -1071,15 +1071,17 @@ pt-BR: does_not_exist: "Categoria especificada não existe." estimated_hours: not_a_number: "não é uma duração válida." - cant_be_inferior_to_remaining_work: "Não pode ser menor do que o Trabalho restante." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Necessário quando o Trabalho restante e o % concluído são definidos." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "não é uma duração válida." - cant_exceed_work: "Não pode ser maior do que o Trabalho." - must_be_set_when_work_is_set: "Necessário quando o Trabalho for definido." - must_be_set_when_work_and_percent_complete_are_set: "Necessário quando Trabalho e % concluído são definidos." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "O pacote de trabalho está em estado somente leitura, então seus atributos não podem ser alterados." type: attributes: @@ -1658,7 +1660,8 @@ pt-BR: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3113,8 +3116,10 @@ pt-BR: setting_work_package_done_ratio: "Cálculo de progresso" setting_work_package_done_ratio_field: "Com base no trabalho" setting_work_package_done_ratio_status: "Com base no estado" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - No modo com base no trabalho, a % de conclusão é calculada com base na quantidade de trabalho realizado em relação ao total de trabalho. Já no modo com base no estado, cada estado possui um valor de % de conclusão associado a ele. Alterar o estado resultará em uma mudança na % de conclusão. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Propriedades do pacote de trabalho" setting_work_package_startdate_is_adddate: "Usar a data atual como data para início dos novos pacotes de trabalho" setting_work_packages_projects_export_limit: "Limite de exportação de pacote de trabalho / projetos" @@ -3496,9 +3501,26 @@ pt-BR: progress: label_note: "Obs.:" modal: - work_based_help_text: "% de conclusão é automaticamente calculada com base no trabalho total e no trabalho restante." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "A % de conclusão é definida pelo estado do pacote de trabalho." migration_warning_text: "No modo de cálculo de progresso com base no trabalho, a % conclusão não pode ser definida manualmente e está vinculada ao Trabalho. O valor existente foi mantido, mas não pode ser editado. Favor inserir o Trabalho primeiro." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comentário" comment_description: "Pode visualizar e comentar neste pacote de trabalho." diff --git a/config/locales/crowdin/pt-PT.yml b/config/locales/crowdin/pt-PT.yml index bfda7066f05a..a1ae4eb0b417 100644 --- a/config/locales/crowdin/pt-PT.yml +++ b/config/locales/crowdin/pt-PT.yml @@ -1038,10 +1038,10 @@ pt-PT: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "não corresponde ao trabalho e ao trabalho restante" - cannot_be_set_when_work_is_zero: "não pode ser definido quando o trabalho é zero" - must_be_set_when_remaining_work_is_set: "Obrigatório quando o Trabalho restante está definido." - must_be_set_when_work_and_remaining_work_are_set: "Obrigatório quando o Trabalho e o Trabalho restante estão definidos." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "tem de estar entre 0 e 100." due_date: not_start_date: "não é na data de início, embora isto seja necessário para os registos." @@ -1071,15 +1071,17 @@ pt-PT: does_not_exist: "A categoria especificada não existe." estimated_hours: not_a_number: "não é uma duração válida." - cant_be_inferior_to_remaining_work: "Não pode ser inferior a Trabalho restante." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Necessário quando são definidos Trabalho restante e % concluído." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "não é uma duração válida." - cant_exceed_work: "Não pode ser superior a Trabalho." - must_be_set_when_work_is_set: "Obrigatório quando o Trabalho é definido." - must_be_set_when_work_and_percent_complete_are_set: "Necessário quando Trabalho e % concluído estão definidos." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "O pacote de trabalho está em estado de apenas leitura, por isso os seus atributos não podem ser alterados." type: attributes: @@ -1658,7 +1660,8 @@ pt-PT: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3112,8 +3115,10 @@ pt-PT: setting_work_package_done_ratio: "Cálculo do progresso" setting_work_package_done_ratio_field: "Baseado no trabalho" setting_work_package_done_ratio_status: "Baseado no estado" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - No modo baseado no trabalho, a % de conclusão é calculada a partir da quantidade de trabalho realizado em relação ao trabalho total. No modo baseado no estado, cada estado tem um valor de % de conclusão associado. A alteração do estado altera a % de conclusão. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Propriedades das tarefas" setting_work_package_startdate_is_adddate: "Utilizar a data atual como data de início para novos pacotes de trabalho" setting_work_packages_projects_export_limit: "Pacotes de trabalho / limite de exportação de projetos" @@ -3496,9 +3501,26 @@ pt-PT: progress: label_note: "Nota:" modal: - work_based_help_text: "A % de conclusão é derivada automaticamente do Trabalho e do Trabalho restante." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "A % de conclusão é definida pelo estado do pacote de trabalho." migration_warning_text: "No modo de cálculo do progresso com base no trabalho, a % de conclusão não pode ser definida manualmente e está ligada ao Trabalho. O valor existente foi mantido, mas não pode ser editado. Introduza primeiro o Trabalho." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comentário" comment_description: "Pode ver e comentar este pacote de trabalho." diff --git a/config/locales/crowdin/ro.yml b/config/locales/crowdin/ro.yml index fa615fd5ec18..18f916b57fff 100644 --- a/config/locales/crowdin/ro.yml +++ b/config/locales/crowdin/ro.yml @@ -1047,10 +1047,10 @@ ro: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "nu este în data de început, deși acest lucru este necesar pentru etape." @@ -1080,15 +1080,17 @@ ro: does_not_exist: "Categoria specificată nu există." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Pachetul de lucru este în stare de numai citire, astfel încât atributele sale nu pot fi modificate." type: attributes: @@ -1695,7 +1697,8 @@ ro: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -2090,7 +2093,7 @@ ro: label_duplicated_by: "dublat de" label_duplicate: "duplicat" label_duplicates: "dublează" - label_edit: "Editare" + label_edit: "Editează" label_edit_x: "Editare: %{x}" label_enable_multi_select: "Comutare selecție multiplă" label_enabled_project_custom_fields: "Câmpuri personalizate activate" @@ -2142,7 +2145,7 @@ ro: label_generate_key: "Generare cheie" label_git_path: "Calea catre directorul .git" label_greater_or_equal: ">=" - label_group_by: "Grupare după" + label_group_by: "Grupează după" label_group_new: "Grupare nouă" label_group: "Grup" label_group_named: "Grup %{name}" @@ -3153,8 +3156,10 @@ ro: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Proprietăți pachet de lucru" setting_work_package_startdate_is_adddate: "Folosire data curentă ca dată de început pentru pachetele de lucru noi" setting_work_packages_projects_export_limit: "Limita de export a pachetelor de lucru / proiectelor" @@ -3538,9 +3543,26 @@ ro: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comentariu" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/ru.yml b/config/locales/crowdin/ru.yml index 2d4491ff6604..fd91cdb07b34 100644 --- a/config/locales/crowdin/ru.yml +++ b/config/locales/crowdin/ru.yml @@ -1053,10 +1053,10 @@ ru: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Требуется, если установлен параметр Оставшаяся работа." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "должно быть между 0 и 100." due_date: not_start_date: "не совпадает с датой начала, хотя это требуется для вех." @@ -1086,15 +1086,17 @@ ru: does_not_exist: "Указанная категория не существует." estimated_hours: not_a_number: "не является допустимой продолжительностью." - cant_be_inferior_to_remaining_work: "Не может быть меньше, чем Оставшаяся работа." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "не является допустимой продолжительностью." - cant_exceed_work: "Не может быть выше Работы." - must_be_set_when_work_is_set: "Требуется, если установлен параметр «Работа»." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Пакет работ находится в статусе доступном только для чтения, поэтому его атрибуты не могут быть изменены." type: attributes: @@ -1729,7 +1731,8 @@ ru: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3187,8 +3190,10 @@ ru: setting_work_package_done_ratio: "Режим расчета прогресса" setting_work_package_done_ratio_field: "На основе трудозатрат" setting_work_package_done_ratio_status: "На основе статуса" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - В режиме На основе трудозатрат, процент завершения рассчитывается на основе того, сколько работы выполнено по отношению к общему объему работ. В режиме На основе статуса, каждый статус имеет связанное с ним значение процента завершения. Изменение статуса изменит процент завершения. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Свойства пакета работ" setting_work_package_startdate_is_adddate: "Использовать текущую дату как дату начала для новых пакетов работ" setting_work_packages_projects_export_limit: "Ограничение экспорта пакетов работ / проектов" @@ -3572,9 +3577,26 @@ ru: progress: label_note: "Примечание:" modal: - work_based_help_text: "% Выполнения автоматически выводится из Работ и Оставшихся работ." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Выполнения определяется статусом пакета работ." migration_warning_text: "В режиме расчета прогресса \"На основе трудозатрат\" процент завершения невозможно установить вручную, он привязан к трудозатратам. Существующее значение сохранено, но его нельзя изменить. Пожалуйста, сначала введите трудозатраты." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Комментировать" comment_description: "Может просматривать и комментировать этот пакет работ." diff --git a/config/locales/crowdin/rw.yml b/config/locales/crowdin/rw.yml index b01d31e6f239..e83722c5ac42 100644 --- a/config/locales/crowdin/rw.yml +++ b/config/locales/crowdin/rw.yml @@ -1040,10 +1040,10 @@ rw: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1073,15 +1073,17 @@ rw: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ rw: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ rw: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ rw: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comment" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/si.yml b/config/locales/crowdin/si.yml index 91d3507b8d68..d8e84bb796b8 100644 --- a/config/locales/crowdin/si.yml +++ b/config/locales/crowdin/si.yml @@ -1040,10 +1040,10 @@ si: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "සන්ධිස්ථාන සඳහා මෙය අවශ්ය වුවද ආරම්භක දිනයේ නොවේ." @@ -1073,15 +1073,17 @@ si: does_not_exist: "නිශ්චිත කාණ්ඩය නොපවතී." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ si: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ si: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "වැඩ පැකේජය ගුණ" setting_work_package_startdate_is_adddate: "නව වැඩ පැකේජ සඳහා ආරම්භක දිනය ලෙස වත්මන් දිනය භාවිතා කරන්න" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ si: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "අදහස් දක්වන්න" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/sk.yml b/config/locales/crowdin/sk.yml index 19c66f12d3d4..d94f2648ffbc 100644 --- a/config/locales/crowdin/sk.yml +++ b/config/locales/crowdin/sk.yml @@ -1054,10 +1054,10 @@ sk: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "nemá rovnakú hodnotu ako dátum začiatku, aj keď je to požadované pre pracovné balíčky typu \"míľnik\"." @@ -1087,15 +1087,17 @@ sk: does_not_exist: "Špecifikovaná kategória neexistuje." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1730,7 +1732,8 @@ sk: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3190,8 +3193,10 @@ sk: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Vlastnosti pracovného balíčka" setting_work_package_startdate_is_adddate: "Použiť aktuálny dátum ako počiatočný dátum pre nové pracovné balíčky" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3576,9 +3581,26 @@ sk: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Komentár" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/sl.yml b/config/locales/crowdin/sl.yml index 49c22e30f415..00fed2c09ece 100644 --- a/config/locales/crowdin/sl.yml +++ b/config/locales/crowdin/sl.yml @@ -1051,10 +1051,10 @@ sl: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "ni začeten datum, čeprav je to pomembno za mejnike." @@ -1084,15 +1084,17 @@ sl: does_not_exist: "Izbrana kategorija ne obstaja." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1500,8 +1502,8 @@ sl: - "avgust" - "september" - "oktober" - - "November" - - "December" + - "november" + - "december" order: - :leto - :mesec @@ -1727,7 +1729,8 @@ sl: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3187,8 +3190,10 @@ sl: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Lastnosti delovnega paketa" setting_work_package_startdate_is_adddate: "52/5000\nUporabite trenutni datum kot datum začetka za nove delovne pakete" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3573,9 +3578,26 @@ sl: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Komentar" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/sr.yml b/config/locales/crowdin/sr.yml index 0982a18dc38a..a4136d290e31 100644 --- a/config/locales/crowdin/sr.yml +++ b/config/locales/crowdin/sr.yml @@ -1047,10 +1047,10 @@ sr: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1080,15 +1080,17 @@ sr: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1695,7 +1697,8 @@ sr: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3154,8 +3157,10 @@ sr: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3539,9 +3544,26 @@ sr: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comment" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/sv.yml b/config/locales/crowdin/sv.yml index dbd75813ec51..e0f687d32b91 100644 --- a/config/locales/crowdin/sv.yml +++ b/config/locales/crowdin/sv.yml @@ -1039,10 +1039,10 @@ sv: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "är inte på startdatum, även om detta behövs för milstolpar." @@ -1072,15 +1072,17 @@ sv: does_not_exist: "Den angivna kategorin finns inte." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1659,7 +1661,8 @@ sv: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3114,8 +3117,10 @@ sv: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Egenskaper för arbetspaket" setting_work_package_startdate_is_adddate: "Använda aktuellt datum som startdatum för nya arbetspaket" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3497,9 +3502,26 @@ sv: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Kommentar" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/th.yml b/config/locales/crowdin/th.yml index 63bd24cbc502..4cf3f4ec7fad 100644 --- a/config/locales/crowdin/th.yml +++ b/config/locales/crowdin/th.yml @@ -1033,10 +1033,10 @@ th: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1066,15 +1066,17 @@ th: does_not_exist: "ไม่มีประเภทที่ระบุ" estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1625,7 +1627,8 @@ th: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3080,8 +3083,10 @@ th: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "คุณสมบัติของชุดภารกิจ" setting_work_package_startdate_is_adddate: "ใช้วันปัจจุบันเป็นวันเริ่มต้นสำหรับชุดภารกิจใหม่" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3463,9 +3468,26 @@ th: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "ความคิดเห็น" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/tr.yml b/config/locales/crowdin/tr.yml index d054a3086939..68269daef45a 100644 --- a/config/locales/crowdin/tr.yml +++ b/config/locales/crowdin/tr.yml @@ -1039,10 +1039,10 @@ tr: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "kilometre taşları için gerekli olmasına rağmen başlangıç tarihi değil." @@ -1072,15 +1072,17 @@ tr: does_not_exist: "Belirtilen kategori yok." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "İş paketi salt okunur durumdadır, dolayısıyla öznitelikleri değiştirilemez." type: attributes: @@ -1227,7 +1229,7 @@ tr: base: "Genel Hata:" blocks_ids: "Engellenen iş paketlerinin ID'leri" category: "Kategori" - comment: "Yorum" + comment: "Yorumlar" comments: "Yorum" content: "İçerik" color: "Renk" @@ -1659,7 +1661,8 @@ tr: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3113,8 +3116,10 @@ tr: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "İş paketi özellikleri" setting_work_package_startdate_is_adddate: "Yeni iş paketlerinde şu anki tarihi başlangıç tarihi olarak kullan" setting_work_packages_projects_export_limit: "İş paketleri / Projeler dışa aktarım limiti" @@ -3496,9 +3501,26 @@ tr: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Yorum" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/uk.yml b/config/locales/crowdin/uk.yml index e921d3ea9c4a..1624d8dc48db 100644 --- a/config/locales/crowdin/uk.yml +++ b/config/locales/crowdin/uk.yml @@ -1048,10 +1048,10 @@ uk: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "не збігається зі значеннями атрибутів «Робота» й «Залишок роботи»" - cannot_be_set_when_work_is_zero: "не можна встановити, коли атрибут «Робота» дорівнює нулю" - must_be_set_when_remaining_work_is_set: "Потрібно вказати, якщо визначено атрибут «Залишок роботи»." - must_be_set_when_work_and_remaining_work_are_set: "Потрібно вказати, якщо визначено атрибути «Робота» й «Залишок роботи»." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "має бути в діапазоні від 0 до 100." due_date: not_start_date: "не на дату початку, хоча це потрібно для етапів." @@ -1081,15 +1081,17 @@ uk: does_not_exist: "Указана категорія не існує." estimated_hours: not_a_number: "– не дійсна тривалість." - cant_be_inferior_to_remaining_work: "Має дорівнювати значенню «Залишок робіт» або перевищувати його." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Потрібно вказати, якщо визначено атрибути «Залишок роботи» й «% завершення»." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "– не дійсна тривалість." - cant_exceed_work: "Не може перевищувати значення «Робота»." - must_be_set_when_work_is_set: "Потрібно вказати, якщо визначено атрибут «Робота»." - must_be_set_when_work_and_percent_complete_are_set: "Потрібно вказати, якщо визначено атрибути «Робота» й «% завершення»." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Пакет робіт перебуває в стані лише для читання, тому його атрибути не можна змінити." type: attributes: @@ -1724,7 +1726,8 @@ uk: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -2196,7 +2199,7 @@ uk: label_index_by_title: "Індекс за назвою" label_information: "Інформація" label_information_plural: "Інформація" - label_installation_guides: "Інструкції зі встановлення" + label_installation_guides: "Інструкції із встановлення" label_integer: "Ціле число" label_internal: "Власне" label_introduction_video: "Введення відео" @@ -3182,8 +3185,10 @@ uk: setting_work_package_done_ratio: "Обчислення прогресу" setting_work_package_done_ratio_field: "На основі роботи" setting_work_package_done_ratio_status: "На основі статусу" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - У режимі на основі роботи значення параметра «% завершення» залежить від частки виконаної роботи відносно загального обсягу робіт. У режимі на основі статусу кожен статус має пов’язане з ним значення параметра «% завершення». У разі змінення статусу змінюється й значення параметра «% завершення». + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Властивості робочого пакета" setting_work_package_startdate_is_adddate: "Використовувати поточну дату в якості дати початку роботи для нових пакетів" setting_work_packages_projects_export_limit: "Ліміт експорту пакетів робіт / проєктів" @@ -3567,9 +3572,26 @@ uk: progress: label_note: "Примітка." modal: - work_based_help_text: "Значення параметра «% завершення» автоматично виводиться зі значень параметрів «Робота» й «Залишок роботи»." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "Значення параметра «% завершення» визначається статусом пакета робіт." migration_warning_text: "У режимі обчислення прогресу на основі робіт значення параметра «% завершення» не можна встановити вручну й прив’язати до значення параметра «Робота». Наявне значення збережено, але його не можна змінити. Спочатку визначте параметр «Робота»." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Коментування" comment_description: "Може переглядати й коментувати цей пакет робіт." diff --git a/config/locales/crowdin/uz.yml b/config/locales/crowdin/uz.yml index 46ae060e5b77..021f91e952f8 100644 --- a/config/locales/crowdin/uz.yml +++ b/config/locales/crowdin/uz.yml @@ -1040,10 +1040,10 @@ uz: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1073,15 +1073,17 @@ uz: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1660,7 +1662,8 @@ uz: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3117,8 +3120,10 @@ uz: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3501,9 +3506,26 @@ uz: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comment" comment_description: "Can view and comment this work package." diff --git a/config/locales/crowdin/vi.yml b/config/locales/crowdin/vi.yml index f5235adafb50..88766dcd0ed6 100644 --- a/config/locales/crowdin/vi.yml +++ b/config/locales/crowdin/vi.yml @@ -1035,10 +1035,10 @@ vi: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "không khớp với công việc và công việc còn lại" - cannot_be_set_when_work_is_zero: "không thể thiết lập khi công việc bằng không" - must_be_set_when_remaining_work_is_set: "Bắt buộc khi thiết lập Công việc còn lại." - must_be_set_when_work_and_remaining_work_are_set: "Bắt buộc khi thiết lập Công việc và Công việc còn lại." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "phải nằm trong khoảng từ 0 đến 100." due_date: not_start_date: "không phải ngày bắt đầu, mặc dù điều này là cần thiết cho các mốc quan trọng." @@ -1068,15 +1068,17 @@ vi: does_not_exist: "Thể loại đã chỉ định không tồn tại." estimated_hours: not_a_number: "không phải là thời gian hợp lệ." - cant_be_inferior_to_remaining_work: "Không thể thấp hơn Công việc còn lại." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Bắt buộc khi thiết lập Lượng công việc còn lại và % Hoàn thành." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "không phải là thời gian hợp lệ." - cant_exceed_work: "Không thể cao hơn Công việc." - must_be_set_when_work_is_set: "Yêu cầu khi Công việc được đặt." - must_be_set_when_work_and_percent_complete_are_set: "Bắt buộc khi Công việc và % Hoàn thành được thiết lập." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "Gói công việc đang ở trạng thái chỉ đọc nên các thuộc tính của nó không thể bị thay đổi." type: attributes: @@ -1627,7 +1629,8 @@ vi: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -2061,7 +2064,7 @@ vi: label_file_plural: "Tệp" label_filter_add: "Thêm bộ lọc" label_filter: "Bộ lọc" - label_filter_plural: "Bộ lọc" + label_filter_plural: "Các bộ lọc" label_filters_toggle: "Hiển thị/ẩn bộ lọc" label_float: "Số thực" label_folder: "Thư mục" @@ -3082,8 +3085,10 @@ vi: setting_work_package_done_ratio: "Tính toán tiến độ" setting_work_package_done_ratio_field: "Dựa trên công việc" setting_work_package_done_ratio_status: "Dựa trên trạng thái" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - Trong chế độ dựa trên công việc, % Hoàn thành được tính từ mức độ công việc đã thực hiện so với tổng công việc. Trong chế độ dựa trên trạng thái, mỗi trạng thái có một giá trị % Hoàn thành liên kết. Thay đổi trạng thái sẽ thay đổi % Hoàn thành. + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Thuộc tính gói công việc" setting_work_package_startdate_is_adddate: "Sử dụng ngày hiện tại làm ngày bắt đầu cho các gói công việc mới" setting_work_packages_projects_export_limit: "Giới hạn xuất gói công việc / Dự án" @@ -3464,9 +3469,26 @@ vi: progress: label_note: "Ghi chú:" modal: - work_based_help_text: "% Hoàn thành được tự động lấy từ Công việc và Công việc còn lại." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Hoàn thành được thiết lập theo trạng thái của gói công việc." migration_warning_text: "Trong chế độ tính toán tiến độ dựa trên công việc, % Hoàn thành không thể được đặt thủ công và liên kết với Công việc. Giá trị hiện tại đã được giữ nhưng không thể chỉnh sửa. Vui lòng nhập Công việc trước." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Nhận xét" comment_description: "Có thể xem và nhận xét gói công việc này." diff --git a/config/locales/crowdin/zh-CN.seeders.yml b/config/locales/crowdin/zh-CN.seeders.yml index 037d46169ec8..64166d212273 100644 --- a/config/locales/crowdin/zh-CN.seeders.yml +++ b/config/locales/crowdin/zh-CN.seeders.yml @@ -81,7 +81,7 @@ zh-CN: demo-project: name: 演示项目 status_explanation: 所有任务都按计划进行。相关人员均知晓各自任务。系统已完全建立。 - description: 这是对此演示项目目标的简短摘要。 + description: 这是对此演示 Scrum 项目目标的简短摘要。 news: item_0: title: 欢迎来到您的演示项目 @@ -199,7 +199,7 @@ zh-CN: scrum-project: name: Scrum 项目 status_explanation: 所有任务都按计划进行。相关人员均知晓各自任务。系统已完全建立。 - description: 这是对此演示Scrum项目目标的简短摘要。 + description: 这是对此演示 Scrum 项目目标的简短摘要。 news: item_0: title: 欢迎来到您的 Scrum 演示项目 diff --git a/config/locales/crowdin/zh-CN.yml b/config/locales/crowdin/zh-CN.yml index 44646952f423..396e2ec5554b 100644 --- a/config/locales/crowdin/zh-CN.yml +++ b/config/locales/crowdin/zh-CN.yml @@ -67,7 +67,7 @@ zh-CN: text: "您确定要删除当前使用的企业版令牌吗?" title: "删除令牌" replace_token: "替换您当前的支持令牌" - order: "订购本地部署的 Enterprise edition" + order: "订购本地部署版的 Enterprise edition" paste: "粘贴您企业版的支持令牌" required_for_feature: "此功能仅限具激活的企业版支持令牌的订阅者使用。" enterprise_link: "如需了解详细信息,请单击此处。" @@ -262,8 +262,8 @@ zh-CN: no_results_title_text: 目前没有项目。 no_results_content_text: 创建一个新的项目 search: - label: Project name filter - placeholder: Search by project name + label: 项目名称过滤器 + placeholder: 按项目名称搜索 lists: active: "有效项目" my: "我的项目" @@ -1029,10 +1029,10 @@ zh-CN: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "工作与剩余工作不匹配" - cannot_be_set_when_work_is_zero: "工作 为 零 时无法设置" - must_be_set_when_remaining_work_is_set: "设置 剩余工作 时必须" - must_be_set_when_work_and_remaining_work_are_set: "当设置了工作和剩余工作时必填。" + does_not_match_work_and_remaining_work: "工时与剩余工时不匹配" + cannot_be_set_when_work_is_zero: "当工时为 0h 时无法设置" + must_be_set_when_remaining_work_is_set: "设置“剩余工时”时必填。" + must_be_set_when_work_and_remaining_work_are_set: "设置“工时”和“剩余工时”时必填。" inclusion: "必须介于 0 和 100 之间。" due_date: not_start_date: "不是在开始日期开始,尽管这是必需的里程碑。" @@ -1063,14 +1063,16 @@ zh-CN: estimated_hours: not_a_number: "不是有效的持续时间。" cant_be_inferior_to_remaining_work: "不能低于剩余工时。" - must_be_set_when_remaining_work_and_percent_complete_are_set: "设置 剩余工作 和 已完成% 时必填。" - format: "%{message}" + must_be_set_when_remaining_work_and_percent_complete_are_set: "设置“剩余工时”和“% 完成”时必填。" remaining_hours: not_a_number: "不是有效的持续时间。" cant_exceed_work: "不能高于工时。" - must_be_set_when_work_is_set: "当设置工时需要。" - must_be_set_when_work_and_percent_complete_are_set: "设置 工作 和 已完成% 时必填。" - format: "%{message}" + must_be_set_when_work_is_set: "设置“工时”时必填。" + must_be_set_when_work_and_percent_complete_are_set: "设置“工时”和“% 完成”时必填。" + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + 当“工时”已设置,且“% 完成”为 100%时,必须为0h。 + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + 当“工时”为空,且“% 完成”为 100%时,必须为空。 readonly_status: "工作包处于只读状态,因此无法更改其属性。" type: attributes: @@ -1609,10 +1611,10 @@ zh-CN: subproject: "子项目:%{name}" export: dialog: - title: "Export" - submit: "Export" + title: "导出" + submit: "导出" format: - label: "File format" + label: "文件格式" options: csv: label: "CSV" @@ -1621,57 +1623,58 @@ zh-CN: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." - input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." + input_label_report: "添加列到属性表" + input_caption_report: "默认情况下,所有添加到当前工作包列表中的列都会被选中。长文本字段在属性表中不可用,但可以显示在其下方。" + input_caption_table: "默认情况下,所有添加到当前工作包列表中的列都会被选中。长文本字段在基于表格的导出中不可用。" pdf: export_type: - label: "PDF export type" + label: "PDF 导出类型" options: table: - label: "Table" - caption: "Export the work packages list in a table with the desired columns." + label: "表格" + caption: "以表格形式导出工作包列表,包含所需的列。" report: - label: "Report" - caption: "Export the work package on a detailed report of all work packages in the list." + label: "报告" + caption: "以详细报告的形式导出列表中的所有工作包。" gantt: - label: "Gantt chart" - caption: "Export the work packages list in a Gantt diagram view." + label: "甘特图" + caption: "以甘特图视图导出工作包列表。" include_images: - label: "Include images" - caption: "Exclude images to reduce the size of the PDF export." + label: "包含图片" + caption: "不包含图像以缩小导出PDF的大小。" gantt_zoom_levels: - label: "Zoom levels" - caption: "Select what is the zoom level for dates displayed in the chart." + label: "缩放级别" + caption: "选择图表中显示日期的缩放级别。" options: - days: "Days" - weeks: "Weeks" - months: "Months" - quarters: "Quarters" + days: "天" + weeks: "周" + months: "月" + quarters: "季度" column_width: - label: "Table column width" + label: "列宽" options: - narrow: "Narrow" - medium: "Medium" - wide: "Wide" - very_wide: "Very wide" + narrow: "窄" + medium: "正常" + wide: "宽" + very_wide: "非常宽" paper_size: - label: "Paper size" - caption: "Depending on the chart size more than one page might be exported." + label: "纸张大小" + caption: "根据图表大小,可能会导出不止一页。" long_text_fields: - input_caption: "By default all long text fields are selected." - input_label: "Add long text fields" - input_placeholder: "Search for long text fields" - drag_area_label: "Manage long text fields" + input_caption: "默认情况下,所有长文本字段都被选中。" + input_label: "添加长文本字段" + input_placeholder: "搜索长文本字段" + drag_area_label: "管理长文本字段" xls: include_relations: - label: "Include relations" - caption: "This option will create a duplicate of each work package for every relation this has with another work package." + label: "包含关系" + caption: "该选项将为每个工作包与另一个工作包的关系创建一个副本。" include_descriptions: - label: "Include descriptions" - caption: "This option will add a description column in raw format." - your_work_packages_export: "Work packages are being exported" - succeeded: "Export completed" - failed: "An error has occurred while trying to export the work packages: %{message}" + label: "包含描述" + caption: "该选项将添加原始格式的描述列。" + your_work_packages_export: "正在导出工作包" + succeeded: "导出完成" + failed: "在尝试导出工作包时发生错误: %{message}" format: atom: "Atom" csv: "CSV" @@ -2313,7 +2316,7 @@ zh-CN: label_revision_id: "修订版本 %{value}" label_revision_plural: "修订" label_roadmap: "路线图" - label_roadmap_edit: "编辑路线图 %{name}" + label_roadmap_edit: "编辑路线图%{name}" label_roadmap_due_in: "%{value} 到期" label_roadmap_no_work_packages: "该版本没有工作包。" label_roadmap_overdue: "%{value} 超时" @@ -2962,7 +2965,7 @@ zh-CN: managed: "在 OpenProject 中创建新的存储库" storage: not_available: "磁盘存储开销不可用于此存储库。" - update_timeout: "在 N 分钟内保留存储库最后所需磁盘空间的信息。由于计算存储库所需的磁盘空间可能增加系统开销,增加该值可以减少性能影响。" + update_timeout: "在 N 分钟内保留存储库最后所需的磁盘空间信息。由于计算存储库所需的磁盘空间可能增加系统开销,增加该值可以减少性能影响。" oauth_application_details: "关闭此窗口后,将无法再次访问客户端密钥值。请将这些值复制到 Nextcloud OpenProject 集成设置中:" oauth_application_details_link_text: "转到设置页面" setup_documentation_details: "如果您在配置新文件存储方面需要帮助,请查看文档:" @@ -3070,8 +3073,10 @@ zh-CN: setting_work_package_done_ratio: "进度计算" setting_work_package_done_ratio_field: "基于工时" setting_work_package_done_ratio_status: "基于状态" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + 在基于工时模式下,“% 完成”是根据已完成的工时占总工时的比例计算出来的。在基于状态模式下,每个状态都有一个与之相关的“% 完成”。更改状态将改变“% 完成”。 setting_work_package_done_ratio_explanation_html: > - 在基于工时模式下,完成百分比是根据已完成的工时占总工时的比例计算出来的。在基于状态模式下,每个状态都有一个与之相关的完成百分比。更改状态将改变完成百分比。 + 在基于工作的模式下,“% 完成”可以自由设置为任何值。如果选择输入 "工时 "值,则会自动得出 "剩余工时"。在基于状态的模式下,每个状态都有一个与之相关的“% 完成”值。更改状态将改变“% 完成”。 setting_work_package_properties: "工作包属性" setting_work_package_startdate_is_adddate: "使用当前日期作为新工作包的开始日期" setting_work_packages_projects_export_limit: "工作包/项目导出限制" @@ -3111,7 +3116,7 @@ zh-CN: setting_session_ttl_hint: "当设置的值低于5时,其作用类似于禁用。" setting_session_ttl_enabled: "会话过期" setting_start_of_week: "一周起始日" - setting_sys_api_enabled: "启用版本库管理 web 服务" + setting_sys_api_enabled: "启用存储库管理网页服务" setting_sys_api_description: "存储库管理网页服务提供了集成的,用户授权的存储库访问。" setting_time_format: "时间" setting_accessibility_mode_for_anonymous: "为匿名用户启用辅助功能模式" @@ -3423,7 +3428,7 @@ zh-CN: warning_user_limit_reached_admin: > 添加额外的用户将超出当前限制。请升级您的计划,以确保外部用户能够访问此实例。 warning_user_limit_reached_instructions: > - 您达到了用户限制(%{current}/%{max}活跃用户)。 请联系sales@openproject.com以升级您的Enterprise edition计划并添加其他用户。 + 您已达到用户限制(%{current}/%{max} 活跃用户)。请联系 sales@openproject.com 升级您的企业版计划以添加额外用户。 warning_protocol_mismatch_html: > warning_bar: @@ -3452,9 +3457,26 @@ zh-CN: progress: label_note: "注意:" modal: - work_based_help_text: "完成百分比由 \"工时\" 和 \"剩余工时\" 自动得出。" + work_based_help_text: "在可能的情况下,每个字段都会根据另外两个字段自动计算。" + work_based_help_text_pre_14_4_without_percent_complete_edition: "“% 完成”由 \"工时\" 和 \"剩余工时\" 自动得出。" status_based_help_text: "完成百分比由工作包状态设定。" migration_warning_text: "在基于工时的进度计算模式下,完成百分比不能手动设置,而是与工时绑定。现有值已被保留,但无法编辑。请先输入工时。" + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "已清空,因为“剩余工时”为空。" + cleared_because_work_is_0h: "已清空,因为 \"工时 \"为 0h。" + derived: "源自“工时”和“剩余工时”。" + estimated_hours: + cleared_because_remaining_work_is_empty: "已清空,因为“剩余工时”为空。" + derived: "由“剩余工时”和“% 完成”得出" + same_as_remaining_work: "设置为与“剩余工时”相同的值。" + remaining_hours: + cleared_because_work_is_empty: "已清空,因为 \"工时 \"为空。" + cleared_because_percent_complete_is_empty: "已清空,因为“% 完成”为空。" + decreased_like_work: "减少与 \"工时 \"相同的数额。" + derived: "由“工时”和“% 完成”得出" + increased_like_work: "增加与 \"工时 \"相同的数额。" + same_as_work: "设置为与 \"工时 \"相同的值。" permissions: comment: "评论" comment_description: "可以查看和评论该工作包。" diff --git a/config/locales/crowdin/zh-TW.yml b/config/locales/crowdin/zh-TW.yml index 605bce74a79b..2a2764865450 100644 --- a/config/locales/crowdin/zh-TW.yml +++ b/config/locales/crowdin/zh-TW.yml @@ -264,8 +264,8 @@ zh-TW: no_results_title_text: 目前沒有專案 no_results_content_text: 建立新專案 search: - label: Project name filter - placeholder: Search by project name + label: 查詢專案名稱 + placeholder: 依專案名稱搜尋 lists: active: "啟用中的專案" my: "我的專案" @@ -1031,10 +1031,10 @@ zh-TW: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "工作與剩餘工作不匹配" - cannot_be_set_when_work_is_zero: "工作為零時無法設置" - must_be_set_when_remaining_work_is_set: "設置剩餘工作時需要" - must_be_set_when_work_and_remaining_work_are_set: "當設置了工作和剩餘工作時需要。" + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "必須介於 0 和 100 之間。" due_date: not_start_date: "儘管日期是里程碑所必需的,但不是開始日期。" @@ -1064,15 +1064,17 @@ zh-TW: does_not_exist: "指定的類別不存在" estimated_hours: not_a_number: "不是有效的持續時間。" - cant_be_inferior_to_remaining_work: "不能低於剩餘工時。" - must_be_set_when_remaining_work_and_percent_complete_are_set: "設置 剩餘工作 和 已完成% 時必填。" - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "不是有效的持續時間。" - cant_exceed_work: "不能高於工時。" - must_be_set_when_work_is_set: "當設置工時需要。" - must_be_set_when_work_and_percent_complete_are_set: "設置 工作 和 已完成% 時必填。" - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "工作項目處於唯讀狀態,因此無法變更其屬性。" type: attributes: @@ -1611,10 +1613,10 @@ zh-TW: subproject: "子專案: %{name}" export: dialog: - title: "Export" - submit: "Export" + title: "匯出" + submit: "匯出" format: - label: "File format" + label: "檔案格式" options: csv: label: "CSV" @@ -1623,57 +1625,58 @@ zh-TW: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." - input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." + input_label_report: "將欄位新增至屬性表" + input_caption_report: "預設情況下,所有在工作項目清單中新增為欄位的屬性都會被選取。長文字欄位在屬性表中不可用,但可以顯示在屬性表下方。" + input_caption_table: "預設情況下,所有在工作項目清單中新增為欄位的屬性都會被選取。長文字欄位在以表格匯出中不可用。" pdf: export_type: - label: "PDF export type" + label: "PDF 匯出類型" options: table: - label: "Table" - caption: "Export the work packages list in a table with the desired columns." + label: "表格" + caption: "匯出所需欄位表格含有工作項目清單" report: - label: "Report" - caption: "Export the work package on a detailed report of all work packages in the list." + label: "報表" + caption: "在清單中所有工作項目的詳細報告上匯出工作項目。" gantt: - label: "Gantt chart" - caption: "Export the work packages list in a Gantt diagram view." + label: "甘特圖" + caption: "匯出甘特圖檢視中的工作項目清單。" include_images: - label: "Include images" - caption: "Exclude images to reduce the size of the PDF export." + label: "包含圖片" + caption: "排除影像以減少 PDF 匯出的大小。" gantt_zoom_levels: - label: "Zoom levels" - caption: "Select what is the zoom level for dates displayed in the chart." + label: "縮放等級" + caption: "選擇圖表中顯示日期的縮放程度。" options: - days: "Days" - weeks: "Weeks" - months: "Months" - quarters: "Quarters" + days: "天" + weeks: "週" + months: "月" + quarters: "季度" column_width: - label: "Table column width" + label: "表格列寬" options: - narrow: "Narrow" - medium: "Medium" - wide: "Wide" - very_wide: "Very wide" + narrow: "窄" + medium: "中" + wide: "寬" + very_wide: "非常寬" paper_size: - label: "Paper size" - caption: "Depending on the chart size more than one page might be exported." + label: "紙張大小" + caption: "視圖表大小而定,可能會輸出超過一頁。" long_text_fields: - input_caption: "By default all long text fields are selected." - input_label: "Add long text fields" - input_placeholder: "Search for long text fields" - drag_area_label: "Manage long text fields" + input_caption: "預設選取所有長文字欄位。" + input_label: "新增長文字欄位" + input_placeholder: "搜尋長文字欄位" + drag_area_label: "新增長文字欄位" xls: include_relations: - label: "Include relations" - caption: "This option will create a duplicate of each work package for every relation this has with another work package." + label: "包含相關連的" + caption: "此選項會針對每個工作項目與其他工作項目的關係,建立一個複本。" include_descriptions: - label: "Include descriptions" - caption: "This option will add a description column in raw format." - your_work_packages_export: "Work packages are being exported" - succeeded: "Export completed" - failed: "An error has occurred while trying to export the work packages: %{message}" + label: "包含說明" + caption: "此選項會在原始格式新增說明欄位。" + your_work_packages_export: "工作項目已匯出" + succeeded: "匯出完成" + failed: "嘗試匯出工作項目時發生錯誤: %{message}" format: atom: "Atom" csv: "CSV" @@ -2057,7 +2060,7 @@ zh-TW: label_file_plural: "檔案" label_filter_add: "新增條件" label_filter: "篩選條件" - label_filter_plural: "篩選器" + label_filter_plural: "篩選條件" label_filters_toggle: "顯示/隱藏篩選條件" label_float: "浮點數" label_folder: "資料夾" @@ -2070,7 +2073,7 @@ zh-TW: label_generate_key: "產生一個金鑰" label_git_path: ".git 目錄的路徑" label_greater_or_equal: ">=" - label_group_by: "分組依據" + label_group_by: "分類" label_group_new: "新增群組" label_group: "群組" label_group_named: "群組名稱 %{name}" @@ -2081,7 +2084,7 @@ zh-TW: label_history: "歷史" label_hierarchy_leaf: "頁面結構頁" label_home: "Home" - label_subject_or_id: "主旨或 id" + label_subject_or_id: "名稱或 id" label_calendar_subscriptions: "訂閱行事曆" label_identifier: "識別碼" label_in: "在" @@ -2124,7 +2127,7 @@ zh-TW: label_latest_revision_plural: "最新版本" label_ldap_authentication: "LDAP 認證" label_learn_more: "了解更多" - label_less_or_equal: "<=" + label_less_or_equal: "之後" label_less_than_ago: "幾天內" label_link_url: "連結(URL)" label_list: "清單" @@ -3075,8 +3078,10 @@ zh-TW: setting_work_package_done_ratio: "進度計算" setting_work_package_done_ratio_field: "基於工時" setting_work_package_done_ratio_status: "基於狀態" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - 在基於工時模式中,"完成百分比"是根據已完成的工作量與總工作量來計算的。在 基於狀態 模式中,每個狀態都有一個與其關聯的完成百分比值。更改狀態將更改完成百分比。 + In work-based mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "工作項目屬性" setting_work_package_startdate_is_adddate: "使用目前日期作為新工作項目的開始日期" setting_work_packages_projects_export_limit: "工作項目/專案匯出數量限制" @@ -3458,9 +3463,26 @@ zh-TW: progress: label_note: "備註" modal: - work_based_help_text: "完成百分比由 \"工時\" 和 \"剩餘工時\" 自動得出。" + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "完成百分比由工作包狀態設定。" migration_warning_text: "在「基於工時」進度計算模式下,完成百分比無法手動設置,並且與「工時」相關聯。目前手動輸入數值已保留,無法編輯。 請務必輸入「工時」才能進行。" + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "留言" comment_description: "可查看此工作項目與留言" diff --git a/config/locales/en.yml b/config/locales/en.yml index 31a3f8845185..d0d10725d37a 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -1116,10 +1116,10 @@ en: assigned_to: format: "%{message}" done_ratio: - does_not_match_work_and_remaining_work: "does not match work and remaining work" - cannot_be_set_when_work_is_zero: "cannot be set when work is zero" - must_be_set_when_remaining_work_is_set: "Required when Remaining work is set." - must_be_set_when_work_and_remaining_work_are_set: "Required when Work and Remaining work are set." + does_not_match_work_and_remaining_work: "does not match Work and Remaining work" + cannot_be_set_when_work_is_zero: "cannot be set when Work is 0h" + must_be_set_when_remaining_work_is_set: "required when Remaining work is set." + must_be_set_when_work_and_remaining_work_are_set: "required when Work and Remaining work are set." inclusion: "must be between 0 and 100." due_date: not_start_date: "is not on start date, although this is required for milestones." @@ -1149,15 +1149,17 @@ en: does_not_exist: "The specified category does not exist." estimated_hours: not_a_number: "is not a valid duration." - cant_be_inferior_to_remaining_work: "Cannot be lower than Remaining work." - must_be_set_when_remaining_work_and_percent_complete_are_set: "Required when Remaining work and % Complete are set." - format: "%{message}" + cant_be_inferior_to_remaining_work: "cannot be lower than Remaining work." + must_be_set_when_remaining_work_and_percent_complete_are_set: "required when Remaining work and % Complete are set." remaining_hours: not_a_number: "is not a valid duration." - cant_exceed_work: "Cannot be higher than Work." - must_be_set_when_work_is_set: "Required when Work is set." - must_be_set_when_work_and_percent_complete_are_set: "Required when Work and % Complete are set." - format: "%{message}" + cant_exceed_work: "cannot be higher than Work." + must_be_set_when_work_is_set: "required when Work is set." + must_be_set_when_work_and_percent_complete_are_set: "required when Work and % Complete are set." + must_be_set_to_zero_hours_when_work_is_set_and_percent_complete_is_100p: >- + must be 0h when Work is set and % Complete is 100%. + must_be_empty_when_work_is_empty_and_percent_complete_is_100p: >- + must be empty when Work is empty and % Complete is 100%. readonly_status: "The work package is in a readonly status so its attributes cannot be changed." type: attributes: @@ -1764,7 +1766,8 @@ en: xls: label: "XLS" columns: - input_caption_report: "By default all attributes added as columns in the work package list are selected." + input_label_report: "Add columns to attribute table" + input_caption_report: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in the attribute table, but can be displayed below it." input_caption_table: "By default all attributes added as columns in the work package list are selected. Long text fields are not available in table based exports." pdf: export_type: @@ -3280,9 +3283,13 @@ en: setting_work_package_done_ratio: "Progress calculation" setting_work_package_done_ratio_field: "Work-based" setting_work_package_done_ratio_status: "Status-based" + setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: > + In work-based mode, % Complete is calculated from how much work is done in relation to total work. + In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_done_ratio_explanation_html: > - In work-based mode, % Complete is calculated from how much work is done in relation to total work. - In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. + In work-based mode, % Complete can be freely set to any value. + If you optionally enter a value for Work, Remaining work will automatically be derived. + In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit" @@ -3750,9 +3757,26 @@ en: progress: label_note: "Note:" modal: - work_based_help_text: "% Complete is automatically derived from Work and Remaining work." + work_based_help_text: "Each field is automatically calculated from the two others when possible." + work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work." status_based_help_text: "% Complete is set by work package status." migration_warning_text: "In work-based progress calculation mode, % Complete cannot be manually set and is tied to Work. The existing value has been kept but cannot be edited. Please input Work first." + derivation_hints: + done_ratio: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + cleared_because_work_is_0h: "Cleared because Work is 0h." + derived: "Derived from Work and Remaining work." + estimated_hours: + cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty." + derived: "Derived from Remaining work and % Complete." + same_as_remaining_work: "Set to same value as Remaining work." + remaining_hours: + cleared_because_work_is_empty: "Cleared because Work is empty." + cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty." + decreased_like_work: "Decreased by the same amount as Work." + derived: "Derived from Work and % Complete." + increased_like_work: "Increased by the same amount as Work." + same_as_work: "Set to same value as Work." permissions: comment: "Comment" comment_description: "Can view and comment this work package." diff --git a/config/locales/js-en.yml b/config/locales/js-en.yml index 98891fd45968..4cc9ceb6ad47 100644 --- a/config/locales/js-en.yml +++ b/config/locales/js-en.yml @@ -160,6 +160,8 @@ en: description_select_work_package: "Select work package #%{id}" description_subwork_package: "Child of work package #%{id}" editor: + revisions: "Show local modifications" + no_revisions: "No local modifications found" preview: "Toggle preview mode" source_code: "Toggle Markdown source mode" error_saving_failed: "Saving the document failed with the following error: %{error}" @@ -306,12 +308,17 @@ en: Are you sure you want to continue? work_packages_settings: - warning_progress_calculation_mode_change_from_status_to_field_html: >- + warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html: >- Changing progress calculation mode from status-based to work-based will make % Complete a non-editable field whose value is derived from Work and Remaining work. Existing values for % Complete are preserved. If values for Work and Remaining work were not present, they will be required in order to change % Complete. + warning_progress_calculation_mode_change_from_status_to_field_html: >- + Changing progress calculation mode from status-based to work-based will make + the % Complete field freely editable. If you optionally enter values + for Work or Remaining work, they will also be linked to % Complete. + Changing Remaining work can then update % Complete. warning_progress_calculation_mode_change_from_field_to_status_html: >- Changing progress calculation mode from work-based to status-based will result in all existing % Complete values to be lost and replaced with values @@ -451,6 +458,7 @@ en: label_create: "Create" label_create_work_package: "Create new work package" label_created_by: "Created by" + label_current: "current" label_date: "Date" label_date_with_format: "Enter the %{date_attribute} using the following format: %{format}" label_deactivate: "Deactivate" @@ -1270,6 +1278,9 @@ en: one: "1 day" other: "%{count} days" zero: "0 days" + word: + one: "1 word" + other: "%{count} words" zen_mode: button_activate: "Activate zen mode" button_deactivate: "Deactivate zen mode" diff --git a/config/routes.rb b/config/routes.rb index a404cc0c565c..b5c8414b26fa 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -426,9 +426,7 @@ resource :custom_style, only: %i[update show create], path: "design" - resources :attribute_help_texts, only: %i(index new create edit update destroy) do - get :upsale, to: "attribute_help_texts#upsale", on: :collection, as: :upsale - end + resources :attribute_help_texts, only: %i(index new create edit update destroy) resources :groups, except: %i[show] do member do diff --git a/docker/ci/entrypoint.sh b/docker/ci/entrypoint.sh index 6c41d9e9cdeb..d4dc280c9223 100755 --- a/docker/ci/entrypoint.sh +++ b/docker/ci/entrypoint.sh @@ -92,7 +92,7 @@ backend_stuff() { } frontend_stuff() { - execute_quiet "DATABASE_URL=nulldb://db time bin/rails openproject:plugins:register_frontend assets:precompile" + execute_quiet "OPENPROJECT_ANGULAR_BUILD=fast DATABASE_URL=nulldb://db time bin/rails openproject:plugins:register_frontend assets:precompile" execute_quiet "cp -rp config/frontend_assets.manifest.json public/assets/frontend_assets.manifest.json" } diff --git a/docker/pullpreview/docker-compose.yml b/docker/pullpreview/docker-compose.yml index 7c9664a60635..f6a3bb409c39 100644 --- a/docker/pullpreview/docker-compose.yml +++ b/docker/pullpreview/docker-compose.yml @@ -14,7 +14,7 @@ x-defaults: &defaults build: context: . args: - OPENPROJECT_ANGULAR_UGLIFY: "false" + OPENPROJECT_ANGULAR_BUILD: "fast" restart: unless-stopped env_file: - .env.pullpreview diff --git a/docs/README.md b/docs/README.md index 84d3456a947b..e7dff7774c12 100644 --- a/docs/README.md +++ b/docs/README.md @@ -39,7 +39,7 @@ Please see our [Use Cases section](./use-cases/) for detailed how-to guides and ## Development -* [Full development environment for developers on Ubuntu](./development/development-environment-ubuntu) and [Mac OS X](./development/development-environment-osx) +* [Full development environment for developers](./development/development-environment) * [Developing plugins](./development/create-openproject-plugin) * [Developing OmniAuth Plugins](./development/create-omniauth-plugin) * [Running tests](./development/running-tests) diff --git a/docs/api/apiv3/components/examples/work_package_create_only_subject.yml b/docs/api/apiv3/components/examples/work_package_create_only_subject.yml new file mode 100644 index 000000000000..39f3795735f8 --- /dev/null +++ b/docs/api/apiv3/components/examples/work_package_create_only_subject.yml @@ -0,0 +1,5 @@ +description: |- + A request body to create a work package with only a subject. This can only be used, if the project context is already + given in the path. All other values will fall back to defaults. +value: + subject: Replace GNK power droids diff --git a/docs/api/apiv3/components/examples/work_package_create_valid.yml b/docs/api/apiv3/components/examples/work_package_create_valid.yml new file mode 100644 index 000000000000..0e251cf18537 --- /dev/null +++ b/docs/api/apiv3/components/examples/work_package_create_valid.yml @@ -0,0 +1,20 @@ +description: |- + A valid request body to create or edit a work package with a couple of properties. +value: + subject: Install Dromund Kass planetary shield + description: + format: markdown + raw: |- + # TODO + + The planetary shield of Dromund Kass needs to be installed to protect the planet from orbital bombardment. + startDate: '2877-07-21' + duration: P1337D + estimatedTime: P1Y5DT13H + ignoreNonWorkingDays: true + project: + href: /api/v3/projects/42 + type: + href: /api/v3/types/13 + status: + href: /api/v3/statuses/2 diff --git a/docs/api/apiv3/components/examples/work_package_edit_subject.yml b/docs/api/apiv3/components/examples/work_package_edit_subject.yml new file mode 100644 index 000000000000..ec3c65b384eb --- /dev/null +++ b/docs/api/apiv3/components/examples/work_package_edit_subject.yml @@ -0,0 +1,4 @@ +description: |- + A request body to edit a work package's subject. +value: + subject: Replace GNK power droids diff --git a/docs/api/apiv3/components/schemas/work_package_form_model.yml b/docs/api/apiv3/components/schemas/work_package_form_model.yml new file mode 100644 index 000000000000..e9c957f26e6b --- /dev/null +++ b/docs/api/apiv3/components/schemas/work_package_form_model.yml @@ -0,0 +1,53 @@ +# Schema: WorkPackageFormModel +--- +type: object +description: |- + The work package creation form. This object is returned, whenever a work package form endpoint is called. It contains + an allowed payload definition, the full schema and any validation errors on the current request body. +properties: + _type: + type: string + enum: + - Form + _embedded: + type: object + properties: + payload: + $ref: './work_package_write_model.yml' + schema: + $ref: './work_package_schema_model.yml' + validationErrors: + type: object + description: |- + All validation errors, where the key is the faulty property. The object is empty, if the request body is + valid. + _links: + type: object + properties: + self: + allOf: + - $ref: './link.yml' + - description: |- + This form endpoint + + **Resource** : Form + validate: + allOf: + - $ref: './link.yml' + - description: |- + The endpoint for validating the request bodies. Often referring to this very form endpoint. + previewMarkup: + allOf: + - $ref: './link.yml' + - description: |- + Renders a markup preview for the work package form. + customFields: + allOf: + - $ref: './link.yml' + - description: |- + Link to the HTML page for the custom field definitions. + configureForm: + allOf: + - $ref: './link.yml' + - description: |- + Link to the HTML page for the form configuration. diff --git a/docs/api/apiv3/components/schemas/work_package_patch_model.yml b/docs/api/apiv3/components/schemas/work_package_patch_model.yml index fc5aae1d604f..9c9690ac3edc 100644 --- a/docs/api/apiv3/components/schemas/work_package_patch_model.yml +++ b/docs/api/apiv3/components/schemas/work_package_patch_model.yml @@ -1,176 +1,11 @@ # Schema: WorkPackagePatchModel --- -type: object -required: - - lockVersion -properties: - lockVersion: - type: integer - description: The version of the item as used for optimistic locking - subject: - type: string - description: Work package subject - description: - allOf: - - $ref: "./formattable.yml" - - description: The work package description - scheduleManually: - type: boolean - description: If false (default) schedule automatically. - startDate: - type: string - format: date - description: Scheduled beginning of a work package - dueDate: - type: string - format: date - description: Scheduled end of a work package - date: - type: string - format: date - description: Date on which a milestone is achieved - estimatedTime: - type: string - format: duration - description: Time a work package likely needs to be completed excluding its descendants - ignoreNonWorkingDays: - type: boolean - description: |- - **(NOT IMPLEMENTED)** When scheduling, whether or not to ignore the non working days being defined. - A work package with the flag set to true will be allowed to be scheduled to a non working day. - readOnly: true - spentTime: - type: string - format: duration - description: |- - The time booked for this work package by users working on it - - # Conditions - - **Permission** view time entries - readOnly: true - percentageDone: - type: integer - description: Amount of total completion for a work package - maximum: 100 - createdAt: - type: string - format: date-time - description: Time of creation - readOnly: true - updatedAt: - type: string - format: date-time - description: Time of the most recent change to the work package - readOnly: true - _links: - type: object +allOf: + - $ref: './work_package_write_model.yml' + - type: object + required: + - lockVersion properties: - assignee: - allOf: - - $ref: "./link.yml" - - description: |- - The person that is intended to work on the work package - - **Resource**: User - budget: - allOf: - - $ref: "./link.yml" - - description: |- - The budget this work package is associated to - - **Resource**: Budget - - # Conditions - - **Permission** view cost objects - category: - allOf: - - $ref: "./link.yml" - - description: |- - The category of the work package - - **Resource**: Category - parent: - allOf: - - $ref: "./link.yml" - - description: |- - Parent work package - - **Resource**: WorkPackage - priority: - allOf: - - $ref: "./link.yml" - - description: |- - The priority of the work package - - **Resource**: Priority - project: - allOf: - - $ref: "./link.yml" - - description: |- - The project to which the work package belongs - - **Resource**: Project - responsible: - allOf: - - $ref: "./link.yml" - - description: |- - The person that is responsible for the overall outcome - - **Resource**: User - status: - allOf: - - $ref: "./link.yml" - - description: |- - The current status of the work package - - **Resource**: Status - type: - allOf: - - $ref: "./link.yml" - - description: |- - The type of the work package - - **Resource**: Type - version: - allOf: - - $ref: "./link.yml" - - description: |- - The version associated to the work package - - **Resource**: Version - -examples: - - subject: Upgrade hangar 25 - lockVersion: 0 - description: - format: markdown - raw: we need more place for new TIE Advanced - html: "

    we need more place for new TIE Advanced

    " - scheduleManually: false - _links: - responsible: - href: "/api/v3/users/23" - title: Palpatine - assignee: - href: "/api/v3/users/33" - title: Darth Vader - priority: - href: "/api/v3/priorities/2" - title: Normal - project: - href: "/api/v3/projects/1" - title: Galactic Conquest - status: - href: "/api/v3/statuses/1" - title: New - type: - href: "/api/v3/types/11" - title: DeathStarUpgrades - version: - href: "/api/v3/versions/1" - title: Version 1 - parent: - href: "/api/v3/work_packages/1298" - title: ct'hulhu f'tagn + lockVersion: + type: integer + description: The version of the item as used for optimistic locking diff --git a/docs/api/apiv3/components/schemas/work_package_schema_model.yml b/docs/api/apiv3/components/schemas/work_package_schema_model.yml new file mode 100644 index 000000000000..c900a77b087a --- /dev/null +++ b/docs/api/apiv3/components/schemas/work_package_schema_model.yml @@ -0,0 +1,92 @@ +# Schema: WorkPackageSchemaModel +--- +type: object +description: |- + A schema for a work package. This schema defines the attributes of a work package. + + TODO: Incomplete, needs to be updated with the real behaviour of schemas (when does which attribute appear?). +properties: + _type: + type: string + enum: + - Schema + _dependencies: + type: array + items: + type: string + description: TBD + _attributeGroups: + type: array + items: + type: object + description: TBD (WorkPackageFormAttributeGroup) + lockVersion: + $ref: './schema_property_model.yml' + id: + $ref: './schema_property_model.yml' + subject: + $ref: './schema_property_model.yml' + description: + $ref: './schema_property_model.yml' + duration: + $ref: './schema_property_model.yml' + scheduleManually: + $ref: './schema_property_model.yml' + ignoreNonWorkingDays: + $ref: './schema_property_model.yml' + startDate: + $ref: './schema_property_model.yml' + dueDate: + $ref: './schema_property_model.yml' + derivedStartDate: + $ref: './schema_property_model.yml' + derivedDueDate: + $ref: './schema_property_model.yml' + estimatedTime: + $ref: './schema_property_model.yml' + derivedEstimatedTime: + $ref: './schema_property_model.yml' + remainingTime: + $ref: './schema_property_model.yml' + derivedRemainingTime: + $ref: './schema_property_model.yml' + percentageDone: + $ref: './schema_property_model.yml' + derivedPercentageDone: + $ref: './schema_property_model.yml' + readonly: + $ref: './schema_property_model.yml' + createdAt: + $ref: './schema_property_model.yml' + updatedAt: + $ref: './schema_property_model.yml' + author: + $ref: './schema_property_model.yml' + project: + $ref: './schema_property_model.yml' + parent: + $ref: './schema_property_model.yml' + assignee: + $ref: './schema_property_model.yml' + responsible: + $ref: './schema_property_model.yml' + type: + $ref: './schema_property_model.yml' + status: + $ref: './schema_property_model.yml' + category: + $ref: './schema_property_model.yml' + version: + $ref: './schema_property_model.yml' + priority: + $ref: './schema_property_model.yml' + _links: + type: object + properties: + self: + allOf: + - $ref: './link.yml' + - description: |- + This work package schema + + **Resource**: Schema diff --git a/docs/api/apiv3/components/schemas/work_package_schemas_model.yml b/docs/api/apiv3/components/schemas/work_package_schemas_model.yml deleted file mode 100644 index 4a7dd065c0a8..000000000000 --- a/docs/api/apiv3/components/schemas/work_package_schemas_model.yml +++ /dev/null @@ -1,20 +0,0 @@ -# Schema: Work_Package_SchemasModel ---- -type: object -example: - _links: - self: - href: "/api/v3/work_packages/schemas" - total: 5 - count: 2 - _type: Collection - _embedded: - elements: - - _type: Schema... - _links: - self: - href: "/api/v3/work_packages/schemas/13-1" - - _type: Schema... - _links: - self: - href: "/api/v3/work_packages/schemas/7-6" diff --git a/docs/api/apiv3/components/schemas/work_package_write_model.yml b/docs/api/apiv3/components/schemas/work_package_write_model.yml new file mode 100644 index 000000000000..f0893ae3ff4f --- /dev/null +++ b/docs/api/apiv3/components/schemas/work_package_write_model.yml @@ -0,0 +1,118 @@ +# Schema: WorkPackageWriteModel +--- +type: object +description: |- + This model is used for creating and updating work packages. It can also be used for validation against the work + package form endpoints. +properties: + subject: + type: string + description: Work package subject + description: + allOf: + - $ref: './formattable.yml' + - description: The work package description + scheduleManually: + type: boolean + description: If false (default) schedule automatically. + startDate: + type: + - 'string' + - 'null' + format: date + description: Scheduled beginning of a work package + dueDate: + type: + - 'string' + - 'null' + format: date + description: Scheduled end of a work package + estimatedTime: + type: + - 'string' + - 'null' + format: duration + description: Time a work package likely needs to be completed excluding its descendants + duration: + type: + - 'string' + - 'null' + format: duration + description: |- + The amount of time in hours the work package needs to be completed. This value must be bigger or equal to `P1D`, + and any the value will get floored to the nearest day. + + The duration has no effect, unless either a start date or a due date is set. + + Not available for milestone type of work packages. + ignoreNonWorkingDays: + type: boolean + description: |- + When scheduling, whether or not to ignore the non working days being defined. + A work package with the flag set to true will be allowed to be scheduled to a non working day. + _links: + type: object + properties: + category: + allOf: + - $ref: './link.yml' + - description: |- + The category of the work package + + **Resource**: Category + type: + allOf: + - $ref: './link.yml' + - description: |- + The type of the work package + + **Resource**: Type + priority: + allOf: + - $ref: './link.yml' + - description: |- + The priority of the work package + + **Resource**: Priority + project: + allOf: + - $ref: './link.yml' + - description: |- + The project to which the work package belongs + + **Resource**: Project + status: + allOf: + - $ref: './link.yml' + - description: |- + The current status of the work package + + **Resource**: Status + responsible: + allOf: + - $ref: './link.yml' + - description: |- + The person that is responsible for the overall outcome + + **Resource**: User + assignee: + allOf: + - $ref: './link.yml' + - description: |- + The person that is intended to work on the work package + + **Resource**: User + version: + allOf: + - $ref: './link.yml' + - description: |- + The version associated to the work package + + **Resource**: Version + parent: + allOf: + - $ref: './link.yml' + - description: |- + Parent work package + + **Resource**: WorkPackage diff --git a/docs/api/apiv3/openapi-spec.yml b/docs/api/apiv3/openapi-spec.yml index f03d67d66aec..c9ffc28257e3 100644 --- a/docs/api/apiv3/openapi-spec.yml +++ b/docs/api/apiv3/openapi-spec.yml @@ -567,6 +567,12 @@ components: $ref: "./components/examples/view_work_packages_table.yml" ViewTeamPlanner: $ref: "./components/examples/view_team_planner.yml" + WorkPackageCreateOnlySubject: + $ref: "./components/examples/work_package_create_only_subject.yml" + WorkPackageCreateValid: + $ref: "./components/examples/work_package_create_valid.yml" + WorkPackageEditSubject: + $ref: "./components/examples/work_package_edit_subject.yml" responses: InvalidQuery: @@ -867,16 +873,20 @@ components: "$ref": "./components/schemas/week_day_write_model.yml" Wiki_PageModel: "$ref": "./components/schemas/wiki_page_model.yml" - Work_PackageModel: + WorkPackageModel: "$ref": "./components/schemas/work_package_model.yml" - Work_Package_SchemasModel: - "$ref": "./components/schemas/work_package_schemas_model.yml" + WorkPackageFormModel: + "$ref": "./components/schemas/work_package_form_model.yml" + WorkPackagePatchModel: + "$ref": "./components/schemas/work_package_patch_model.yml" + WorkPackageSchemaModel: + "$ref": "./components/schemas/work_package_schema_model.yml" + WorkPackageWriteModel: + "$ref": "./components/schemas/work_package_write_model.yml" Work_Package_activitiesModel: "$ref": "./components/schemas/work_package_activities_model.yml" Work_PackagesModel: "$ref": "./components/schemas/work_packages_model.yml" - WorkPackagePatchModel: - "$ref": "./components/schemas/work_package_patch_model.yml" securitySchemes: BasicAuth: type: http diff --git a/docs/api/apiv3/paths/project_work_packages_form.yml b/docs/api/apiv3/paths/project_work_packages_form.yml index 57c6280d48e2..382d36624080 100644 --- a/docs/api/apiv3/paths/project_work_packages_form.yml +++ b/docs/api/apiv3/paths/project_work_packages_form.yml @@ -1,20 +1,38 @@ # /api/v3/projects/{id}/work_packages/form --- post: + summary: Form for creating Work Packages in a Project + operationId: form_create_work_package_in_project + tags: + - Work Packages + description: |- + This endpoint allows you to validation a new work package creation body in a specific project. It works similarly + to the `/api/v3/work_packages/form` endpoint, but already specifies the work package's project in the path, so that + it does not have to be defined in the request body. parameters: - - description: ID of the project in which the work package will be created - example: '1' - in: path - name: id - required: true - schema: - type: integer + - name: id + description: ID of the project in which the work package will be created + in: path + required: true + schema: + type: integer + example: '1' + requestBody: + content: + application/json: + schema: + $ref: '../components/schemas/work_package_write_model.yml' + examples: + 'Minimal example': + $ref: '../components/examples/work_package_create_only_subject.yml' + 'Valid example': + $ref: '../components/examples/work_package_create_valid.yml' responses: '200': description: OK - headers: {} - tags: - - Work Packages - description: '' - operationId: Work_Package_Create_Form_For_Project - summary: Work Package Create Form For Project + content: + application/json: + schema: + $ref: '../components/schemas/work_package_form_model.yml' + '415': + $ref: '../components/responses/unsupported_media_type.yml' diff --git a/docs/api/apiv3/paths/work_package_form.yml b/docs/api/apiv3/paths/work_package_form.yml index c63fadd615d0..911944a29c33 100644 --- a/docs/api/apiv3/paths/work_package_form.yml +++ b/docs/api/apiv3/paths/work_package_form.yml @@ -1,68 +1,59 @@ # /api/v3/work_packages/{id}/form --- post: - summary: Work Package Edit Form - operationId: Work_Package_Edit_Form + summary: Form for editing a Work Package + operationId: form_edit_work_package tags: - Work Packages description: |- - When calling this endpoint, the client provides a single object containing the properties and links to be edited, in the body. + When calling this endpoint, the client provides a single object containing the properties and links to be + edited, in the body. The input is validated and a schema response is returned. If the validation errors of the + response is empty, the same payload can be used to edit the work package. - Note that it is only allowed to provide properties or links supporting the write operation. + Only the properties of the work package write model are allowed to set on a work package on editing. - When setting start date, finish date, and duration together, their correctness will be checked and a 422 error will be returned if one value does not match with the two others. You can make the server compute a value: set only two values in the request and the third one will be computed and returned in the response. For instance, when sending `{ "startDate": "2022-08-23", duration: "P2D" }`, the response will include `{ "dueDate": "2022-08-24" }`. + When setting start date, finish date, and duration together, their correctness will be checked and a validation + error will be returned if one value does not match with the two others. You can make the server compute a value: + set only two values in the request and the third one will be computed and returned in the response. For instance, + when sending `{ "startDate": "2022-08-23", duration: "P2D" }`, the response will + include `{ "dueDate": "2022-08-24" }`. requestBody: content: application/json: schema: - "$ref": "../components/schemas/work_package_model.yml" + $ref: '../components/schemas/work_package_write_model.yml' + examples: + 'Changing subject': + $ref: '../components/examples/work_package_edit_subject.yml' parameters: - - description: ID of the work package being modified - example: '1' - in: path - name: id - required: true - schema: - type: integer + - name: id + description: ID of the work package being modified + in: path + required: true + schema: + type: integer + example: '1' responses: '200': description: OK - headers: {} - '403': content: - application/hal+json: + application/json: schema: - $ref: "../components/schemas/error_response.yml" - examples: - response: - value: - _type: Error - errorIdentifier: urn:openproject-org:api:v3:errors:MissingPermission - message: You are not allowed to edit the specified work package. + $ref: '../components/schemas/work_package_form_model.yml' + '404': description: |- - Returned if the client does not have sufficient permissions. + Returned if the work package does not exist or the client does not have sufficient permissions to see it. - **Required permission:** edit work package, assign version, change work package status, manage subtasks or move work package - - *Note that you will only receive this error, if you are at least allowed to see the corresponding work package.* - headers: {} - '404': + **Required permission:** view work package content: application/hal+json: schema: - $ref: "../components/schemas/error_response.yml" + $ref: '../components/schemas/error_response.yml' examples: response: value: _type: Error errorIdentifier: urn:openproject-org:api:v3:errors:NotFound message: The specified work package does not exist. - description: |- - Returned if the work package does not exist or the client does not have sufficient permissions to see it. - - **Required permission:** view work package - headers: {} - '406': - $ref: "../components/responses/missing_content_type.yml" '415': - $ref: "../components/responses/unsupported_media_type.yml" + $ref: '../components/responses/unsupported_media_type.yml' diff --git a/docs/api/apiv3/paths/work_packages_form.yml b/docs/api/apiv3/paths/work_packages_form.yml index a9c2d3541957..4998b9a41810 100644 --- a/docs/api/apiv3/paths/work_packages_form.yml +++ b/docs/api/apiv3/paths/work_packages_form.yml @@ -1,12 +1,36 @@ # /api/v3/work_packages/form --- post: + summary: Form for creating a Work Package + operationId: form_create_work_package + tags: + - Work Packages + description: |- + When calling this endpoint, the client provides a single object containing the properties and links to be + created, in the body. The input is validated and a schema response is returned. If the validation errors of the + response is empty, the same payload can be used to create a work package. + + Only the properties of the work package write model are allowed to set on a work package on creation. + + When setting start date, finish date, and duration together, their correctness will be checked and a validation + error will be returned if one value does not match with the two others. You can make the server compute a value: + set only two values in the request and the third one will be computed and returned in the response. For instance, + when sending `{ "startDate": "2022-08-23", duration: "P2D" }`, the response will + include `{ "dueDate": "2022-08-24" }`. + requestBody: + content: + application/json: + schema: + $ref: '../components/schemas/work_package_write_model.yml' + examples: + 'Valid creation': + $ref: '../components/examples/work_package_create_valid.yml' responses: '200': description: OK - headers: {} - tags: - - Work Packages - description: '' - operationId: Work_Package_Create_Form - summary: Work Package Create Form + content: + application/json: + schema: + $ref: '../components/schemas/work_package_form_model.yml' + '415': + $ref: '../components/responses/unsupported_media_type.yml' diff --git a/docs/api/apiv3/paths/work_packages_schemas.yml b/docs/api/apiv3/paths/work_packages_schemas.yml index 623071ebddd1..994b8d003542 100644 --- a/docs/api/apiv3/paths/work_packages_schemas.yml +++ b/docs/api/apiv3/paths/work_packages_schemas.yml @@ -1,22 +1,31 @@ # /api/v3/work_packages/schemas/ --- get: + summary: List Work Package Schemas + operationId: list_work_package_schemas + tags: + - Work Packages + description: |- + List all work package schemas that match the given filters. This endpoint does not return a successful response, + if no filter is given. parameters: - - description: |- - JSON specifying filter conditions. - Accepts the same format as returned by the [queries](https://www.openproject.org/docs/api/endpoints/queries/) endpoint. Currently supported filters are: - - + id: The schema's id - - Schema id has the form `project_id-work_package_type_id`. - example: '[{ "id": { "operator": "=", "values": ["12-1", "14-2"] } }]' - in: query - name: filters - required: true - schema: - type: string + - name: filters + description: |- + JSON specifying filter conditions. + Accepts the same format as returned by the [queries](https://www.openproject.org/docs/api/endpoints/queries/) + endpoint. Currently supported filters are: + + + id: The schema's id + + Schema id has the form `project_id-work_package_type_id`. + in: query + required: true + schema: + type: string + example: '[{ "id": { "operator": "=", "values": ["12-1", "14-2"] } }]' responses: '200': + description: OK content: application/hal+json: examples: @@ -24,24 +33,20 @@ get: value: _embedded: elements: - - _links: - self: - href: "/api/v3/work_packages/schemas/13-1" - _type: Schema... - - _links: - self: - href: "/api/v3/work_packages/schemas/7-6" - _type: Schema... + - _links: + self: + href: "/api/v3/work_packages/schemas/13-1" + _type: Schema... + - _links: + self: + href: "/api/v3/work_packages/schemas/7-6" + _type: Schema... _links: self: href: "/api/v3/work_packages/schemas" _type: Collection count: 2 total: 5 - schema: - "$ref": "../components/schemas/work_package_schemas_model.yml" - description: OK - headers: {} '400': $ref: "../components/responses/invalid_request_body.yml" '403': @@ -59,9 +64,4 @@ get: Returned if the client does not have sufficient permissions. **Required permission:** View work packages in any project. - headers: {} - tags: - - Work Packages - description: List work package schemas. - operationId: List_Work_Package_Schemas - summary: List Work Package Schemas + headers: { } diff --git a/docs/api/apiv3/tags/users.yml b/docs/api/apiv3/tags/users.yml index 9a1eabdcfc82..f047b64d03c6 100644 --- a/docs/api/apiv3/tags/users.yml +++ b/docs/api/apiv3/tags/users.yml @@ -1,4 +1,5 @@ --- +name: Users description: |- ## Actions @@ -7,37 +8,37 @@ description: |- | lock | Restrict the user from logging in and performing any actions | not locked; **Permission**: Administrator | | show | Link to the OpenProject user page (HTML) | | | unlock | Allow a locked user to login and act again | locked; **Permission**: Administrator | - | updateImmediately | Updates the user's attributes. | **Permission**: Administrator, manage_user global permission | + | updateImmediately | Updates the user's attributes. | **Permission**: Administrator, manage_user global permission | | delete | Permanently remove a user from the instance | **Permission**: Administrator, self-delete | ## Linked Properties | Link | Description | Type | Constraints | Supported operations | Condition | - |:-----------:|-------------------------------------------------------------- | ------------- | --------------------- | -------------------- | ----------------------------------------- | + |:-----------:|--------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------- | --------------------- | -------------------- | ----------------------------------------- | | self | This user | User | not null | READ | | - | auth_source | Link to the user's auth source (endpoint not yet implemented) | LdapAuthSource | | READ / WRITE | **Permission**: Administrator | + | auth_source | Link to the user's auth source (endpoint not yet implemented) | LdapAuthSource | | READ / WRITE | **Permission**: Administrator | | members | Link to collection of all the user's memberships. The list will only include the memberships in projects in which the requesting user has the necessary permissions. | MemberCollection | | READ | **Permission**: view members or manage members in any project | Depending on custom fields defined for users, additional links might exist. ## Local Properties - | Property | Description | Type | Constraints | Supported operations | Condition | - | :----------: | --------------------------------------------------------- | -------- | ---------------------------------------------------- | -------------------- | ----------------------------------------------------------- | - | id | User's id | Integer | x > 0 | READ | | + | Property | Description | Type | Constraints | Supported operations | Condition | + | :----------: | --------------------------------------------------------- | -------- | ---------------------------------------------------- | -------------------- | ----------------------------------------------------------- | + | id | User's id | Integer | x > 0 | READ | | | login | User's login name | String | unique, 256 max length | READ / WRITE | **Permission**: Administrator, manage_user global permission | | firstName | User's first name | String | 30 max length | READ / WRITE | **Permission**: Administrator, manage_user global permission | | lastName | User's last name | String | 30 max length | READ / WRITE | **Permission**: Administrator, manage_user global permission | - | name | User's full name, formatting depends on instance settings | String | | READ | | + | name | User's full name, formatting depends on instance settings | String | | READ | | | email | User's email address | String | unique, 60 max length | READ / WRITE | E-Mail address not hidden, **Permission**: Administrator, manage_user global permission | - | admin | Flag indicating whether or not the user is an admin | Boolean | in: [true, false] | READ / WRITE | **Permission**: Administrator | - | avatar | URL to user's avatar | Url | | READ | | - | status | The current activation status of the user (see below) | String | in: ["active", "registered", "locked", "invited"] | READ | | + | admin | Flag indicating whether or not the user is an admin | Boolean | in: [true, false] | READ / WRITE | **Permission**: Administrator | + | avatar | URL to user's avatar | Url | | READ | | + | status | The current activation status of the user (see below) | String | in: ["active", "registered", "locked", "invited"] | READ | | | language | User's language | String | ISO 639-1 | READ / WRITE | **Permission**: Administrator, manage_user global permission | - | password | User's password for the default password authentication | String | | WRITE | **Permission**: Administrator | - | identity_url | User's identity_url for OmniAuth authentication | String | | READ / WRITE | **Permission**: Administrator | - | createdAt | Time of creation | DateTime | | READ | | - | updatedAt | Time of the most recent change to the user | DateTime | | READ | | + | password | User's password for the default password authentication | String | | WRITE | **Permission**: Administrator | + | identity_url | User's identity_url for OmniAuth authentication | String | | READ / WRITE | **Permission**: Administrator | + | createdAt | Time of creation | DateTime | | READ | | + | updatedAt | Time of the most recent change to the user | DateTime | | READ | | Depending on custom fields defined for users, additional properties might exist. @@ -65,4 +66,3 @@ description: |- users except for admins or the user themselves. Please note that custom fields are not yet supported by the api although the backend supports them. -name: Users diff --git a/docs/development/README.md b/docs/development/README.md index aee88f742be9..5b091adb4e83 100644 --- a/docs/development/README.md +++ b/docs/development/README.md @@ -96,10 +96,7 @@ If you want to contribute to OpenProject, please make sure to accept our Contrib ## Additional resources -* [Development environment for Ubuntu 18.04](development-environment-ubuntu) -* [Development environment for Mac OS X](development-environment-osx) -* [Development environment using docker](development-environment-docker) - +* [Development environment](development-environment) * [Developing Plugins](create-openproject-plugin) * [Running Tests](running-tests) * [API Documentation](../api) diff --git a/docs/development/concepts/README.md b/docs/development/concepts/README.md index e41d5fc66eda..784312f9d056 100644 --- a/docs/development/concepts/README.md +++ b/docs/development/concepts/README.md @@ -12,14 +12,14 @@ This guide will introduce some concepts and give you a big picture of the develo Please choose an area that you would like to read about: -| Topic | Content | -|------------------------------------------------------|:------------------------------------------------------------------------------| -| [Application architecture](application-architecture) | An introduction of the application architecture used at OpenProject. | -| [State management](state-management) | How does the frontend handle state and react to changes? | -| [HAL resources](hal-resources) | What are HAL resources and how are they used in the frontend? | -| [Permissions](permissions) | How are roles and permissions handled in OpenProject code? | -| [Translations](translations) | How are translations used and built? | -| [Resource schemas](resource-schemas) | What is a schema and how is it tied to an editable resource? | -| [Resource changesets](resource-changesets) | How is change tracked to resources in the frontend? How to save the changes. | -| [Inline editing](inline-editing) | How does inline editing and the edit field functionality work in OpenProject? | -| [Queries and QuerySpace](queries) | What is the Query API concept and how is it used in the frontend? | +| Topic | Content | +|---------------------------------------------------------|:------------------------------------------------------------------------------| +| [Application architecture](../application-architecture) | An introduction of the application architecture used at OpenProject. | +| [State management](state-management) | How does the frontend handle state and react to changes? | +| [HAL resources](hal-resources) | What are HAL resources and how are they used in the frontend? | +| [Permissions](permissions) | How are roles and permissions handled in OpenProject code? | +| [Translations](translations) | How are translations used and built? | +| [Resource schemas](resource-schemas) | What is a schema and how is it tied to an editable resource? | +| [Resource changesets](resource-changesets) | How is change tracked to resources in the frontend? How to save the changes. | +| [Inline editing](inline-editing) | How does inline editing and the edit field functionality work in OpenProject? | +| [Queries and QuerySpace](queries) | What is the Query API concept and how is it used in the frontend? | diff --git a/docs/development/concepts/application-architecture/README.md b/docs/development/concepts/application-architecture/README.md deleted file mode 100644 index 0e48122469fa..000000000000 --- a/docs/development/concepts/application-architecture/README.md +++ /dev/null @@ -1,8 +0,0 @@ ---- -sidebar_navigation: - title: Application architecture ---- - -# Application architecture - -This guide has been integrated into the [application architecture documentation](../../application-architecture/). diff --git a/docs/development/create-openproject-plugin/README.md b/docs/development/create-openproject-plugin/README.md index 4300f774b669..6f43cb25a369 100644 --- a/docs/development/create-openproject-plugin/README.md +++ b/docs/development/create-openproject-plugin/README.md @@ -136,7 +136,7 @@ It is probably best to use READMEs of already released plugins as a template. Activity, Issue Tracking, Time Tracking, Forums, and Backlogs are default. Also, the My Project Page should only show Project Description and Tickets blocks. 3. Create a news article about the newly released plugin and its features. -4. Twitter with a link to the news article. +4. Share a link to the news article on social media. 5. If the plugin is referenced in our feature tour, add a download link to the plugin in the feature tour ## Frontend plugins [WIP] diff --git a/docs/development/design-system/README.md b/docs/development/design-system/README.md index 58aa524fd4b9..812763f929e2 100644 --- a/docs/development/design-system/README.md +++ b/docs/development/design-system/README.md @@ -8,7 +8,3 @@ keywords: Design system, Primer, styles, design, components # Design System and Component Libraries Starting in OpenProject 13.0., the [Primer Design System](https://primer.style/design/) is being used in OpenProject. Relevant reusable components from Primer as well as common patterns and compositions of these components will be documented in our [Lookbook](https://qa.openproject-edge.com/lookbook/). - -Prior to 13.0., components were defined in its own Design System called SPOT which is slowly being replaced by Primer. -Components still defined for SPOT are documented in the last build of storybook found -here: https://opf.github.io/design-system diff --git a/docs/development/development-environment/README.md b/docs/development/development-environment/README.md new file mode 100644 index 000000000000..58ecee41d708 --- /dev/null +++ b/docs/development/development-environment/README.md @@ -0,0 +1,34 @@ +--- +sidebar_navigation: + title: Development setup +description: OpenProject development setup +keywords: development setup +--- + +# OpenProject development setup + +| OS/Method | Description | +|------------------------------------|-----------------------------------------------------------------------------------| +| [Ubuntu / Debian](linux) | Develop setup on Linux | +| [via docker](docker) | The quickest way to get started developing OpenProject is to use the docker setup | +| [via docker (MacOS)](docker-macos) | MacOS specific docker topics | +| [MacOS](macos) | Develop setup on MacOS | + + +### Start Coding + +Please have a look at [our development guidelines](../code-review-guidelines/) for tips and guides on how to start +coding. We have advice on how to get your changes back into the OpenProject core as smooth as possible. +Also, take a look at the `doc` directory in our sources, especially +the [how to run tests](../running-tests) documentation (we like to have automated tests for every new developed feature). + +### Troubleshooting + +The OpenProject logfile can be found in `log/development.log`. + +If an error occurs, it should be logged there (as well as in the output to STDOUT/STDERR of the rails server process). + +### Questions, Comments, and Feedback + +If you have any further questions, comments, feedback, or an idea to enhance this guide, please tell us at the +appropriate [forum](https://community.openproject.org/projects/openproject/boards/9). diff --git a/docs/development/development-environment-docker-macos/README.md b/docs/development/development-environment/docker-macos/README.md similarity index 96% rename from docs/development/development-environment-docker-macos/README.md rename to docs/development/development-environment/docker-macos/README.md index 4457931890fc..7ff3c7c3bb1f 100644 --- a/docs/development/development-environment-docker-macos/README.md +++ b/docs/development/development-environment/docker-macos/README.md @@ -1,13 +1,14 @@ --- sidebar_navigation: title: Development setup via docker on MacOS + short_title: Setup via Docker on MacOS description: OpenProject development setup via docker on MacOS keywords: development setup docker macos --- # OpenProject development setup via docker (MacOS) -This guide covers observed nuances with the docker runtime on MacOS. Please ensure you've gone through the general [OpenProject development setup via docker](../development-environment-docker) guide before proceeding. +This guide covers observed nuances with the docker runtime on MacOS. Please ensure you've gone through the general [OpenProject development setup via docker](../docker) guide before proceeding. ## Docker on MacOS File System Performance diff --git a/docs/development/development-environment-docker/README.md b/docs/development/development-environment/docker/README.md similarity index 99% rename from docs/development/development-environment-docker/README.md rename to docs/development/development-environment/docker/README.md index 9a413945b78a..b6b0873f77cb 100644 --- a/docs/development/development-environment-docker/README.md +++ b/docs/development/development-environment/docker/README.md @@ -1,6 +1,7 @@ --- sidebar_navigation: title: Development setup via docker + short_title: Setup via Docker description: OpenProject development setup via docker keywords: development setup docker --- @@ -464,7 +465,7 @@ Once the keycloak service is started and running, you can access the keycloak in and login with initial username and password as `admin`. Keycloak being an OpenID connect provider, we need to setup an OIDC integration for OpenProject. -[Setup OIDC (keycloak) integration for OpenProject](../../installation-and-operations/misc/custom-openid-connect-providers/#keycloak) +[Setup OIDC (keycloak) integration for OpenProject](../../../installation-and-operations/misc/custom-openid-connect-providers/#keycloak) Once the above setup is completed, In the root `docker-compose.override.yml` file, uncomment all the environment in `backend` service for keycloak and set the values according to configuration done in keycloak for OpenProject Integration. diff --git a/docs/development/development-environment-ubuntu/README.md b/docs/development/development-environment/linux/README.md similarity index 90% rename from docs/development/development-environment-ubuntu/README.md rename to docs/development/development-environment/linux/README.md index 995a021b55a1..94e719700759 100644 --- a/docs/development/development-environment-ubuntu/README.md +++ b/docs/development/development-environment/linux/README.md @@ -1,6 +1,7 @@ --- sidebar_navigation: title: Development setup on Debian / Ubuntu + short_title: Setup on Debian / Ubuntu description: OpenProject development setup on Debian / Ubuntu keywords: development setup debian ubuntu linux --- @@ -18,8 +19,6 @@ shall NOT be present before. **Please note**: This guide is NOT suitable for a production setup, but only for developing with it! -Remark: *At the time of writing* in this page refers to 12/10/2021 - If you find any bugs or you have any recommendations for improving this tutorial, please, feel free to send a pull request or comment in the [OpenProject forums](https://community.openproject.org/projects/openproject/boards). @@ -350,24 +349,3 @@ in a production setting.** ```shell RAILS_ENV=development bin/rails runner "Delayed::Job.delete_all" ``` - -### Start Coding - -Please have a look at [our development guidelines](../code-review-guidelines/) for tips and guides on how to start -coding. We have advice on how to get your changes back into the OpenProject core as smooth as possible. -Also, take a look at the `doc` directory in our sources, especially -the [how to run tests](https://github.com/opf/openproject/tree/dev/docs/development/running-tests) documentation (we -like to have automated tests for every new developed feature). - -### Troubleshooting - -The OpenProject logfile can be found in `log/development.log`. - -If an error occurs, it should be logged there (as well as in the output to STDOUT/STDERR of the rails server process). - -### Questions, Comments, and Feedback - -If you have any further questions, comments, feedback, or an idea to enhance this guide, please tell us at the -appropriate community.openproject.org [forum](https://community.openproject.org/projects/openproject/boards/9). -[Follow OpenProject on twitter](https://twitter.com/openproject), and -follow [the news](https://www.openproject.org/blog) to stay up to date. diff --git a/docs/development/development-environment-osx/README.md b/docs/development/development-environment/macos/README.md similarity index 90% rename from docs/development/development-environment-osx/README.md rename to docs/development/development-environment/macos/README.md index 1ba17bd97e1c..5d1ed3b0e16c 100644 --- a/docs/development/development-environment-osx/README.md +++ b/docs/development/development-environment/macos/README.md @@ -1,6 +1,7 @@ --- sidebar_navigation: title: Development setup on MacOS + short_title: Setup on MacOS description: OpenProject development setup on Mac OS keywords: development setup macos --- @@ -207,8 +208,6 @@ Now, run the following tasks to migrate and seed the dev database, and prepare t RAILS_ENV=development bin/rails db:seed ``` -1 - ### Run OpenProject through overmind You can run all required workers of OpenProject through `overmind`, which combines them in a single tab. Optionally, you @@ -334,24 +333,3 @@ in a production setting.** ```shell RAILS_ENV=development bin/rails runner "Delayed::Job.delete_all" ``` - -### Start Coding - -Please have a look at [our development guidelines](../code-review-guidelines) for tips and guides on how to start -coding. We have advice on how to get your changes back into the OpenProject core as smooth as possible. -Also, take a look at the `doc` directory in our sources, especially -the [how to run tests](https://github.com/opf/openproject/blob/dev/docs/development/running-tests) documentation (we -like to have automated tests for every new developed feature). - -### Troubleshooting - -The OpenProject logfile can be found in `log/development.log`. - -If an error occurs, it should be logged there (as well as in the output to STDOUT/STDERR of the rails server process). - -### Questions, Comments, and Feedback - -If you have any further questions, comments, feedback, or an idea to enhance this guide, please tell us at the -appropriate community.openproject.org [forum](https://community.openproject.org/projects/openproject/boards/9). -[Follow OpenProject on twitter](https://twitter.com/openproject), and -follow [the news](https://www.openproject.org/blog) to stay up to date. diff --git a/docs/development/environments/README.md b/docs/development/environments/README.md deleted file mode 100644 index 11b7bdeaffa7..000000000000 --- a/docs/development/environments/README.md +++ /dev/null @@ -1,10 +0,0 @@ ---- -sidebar_navigation: - title: Environments -description: Get an overview of the different environments at play in the development phases of OpenProject -keywords: environments, CI, development ---- - -# Environments - -This guide has been integrated into the [application architecture documentation](../application-architecture/). diff --git a/docs/development/localhost-ssl/README.md b/docs/development/localhost-ssl/README.md index a8210f721b02..b9f80d101938 100644 --- a/docs/development/localhost-ssl/README.md +++ b/docs/development/localhost-ssl/README.md @@ -93,7 +93,7 @@ application server. You can do that with `/usr/sbin/setsebool -P httpd_can_netwo ## Step 4: Configure OpenProject for HTTPS usage We assume you have already configured your OpenProject local development environment -as [described in this guide](../development-environment-ubuntu). You will need to add your custom host name +as [described in this guide](../development-environment). You will need to add your custom host name to the environment. You can use this variable to do so. ```yaml @@ -133,10 +133,3 @@ setup a reverse proxy in docker, like [traefik](https://traefik.io/). Then follo > **Reminder**: This setup is still experimental and under further development. Use it only, when you know what you are doing. - -## Questions, Comments, and Feedback - -If you have any further questions, comments, feedback, or an idea to enhance this guide, please tell us at the -appropriate community.openproject.org [forum](https://community.openproject.org/projects/openproject/boards/9). -[Follow OpenProject on twitter](https://twitter.com/openproject), and -follow [the news](https://www.openproject.org/blog) to stay up to date. diff --git a/docs/development/product-development-handbook/README.md b/docs/development/product-development-handbook/README.md index e6c60f96e640..eb3690209e85 100644 --- a/docs/development/product-development-handbook/README.md +++ b/docs/development/product-development-handbook/README.md @@ -343,7 +343,7 @@ The entire team documents possible improvements for the next release. ### 4.1 Version/Release -A version is the name given to a collection of features and/or bugfixes. A release is the publicly available version of the OpenProject software. More information is provided on the [release page](../releases/). +A version is the name given to a collection of features and/or bugfixes. A release is the publicly available version of the OpenProject software. More information is provided on the [Application architecture page](../application-architecture/#patch-and-change-management). ### 4.2 RICE Score diff --git a/docs/development/releases/README.md b/docs/development/releases/README.md deleted file mode 100644 index d21561c7da86..000000000000 --- a/docs/development/releases/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# Releases - -This page has been integrated into the [application architecture guide](../application-architecture/#patch-and-change-management). diff --git a/docs/development/running-tests/README.md b/docs/development/running-tests/README.md index 3f482e5797eb..d833d8886f4d 100644 --- a/docs/development/running-tests/README.md +++ b/docs/development/running-tests/README.md @@ -119,7 +119,7 @@ Smoke tests are automated and manual tests to ensure the main application featur **Best practices** - Automate smoke testing on top of manual testing when possible -- Run after deployments to the appropriate [environments](../environments), e.g., the edge environment for features of the next release and staging environment for bug fixes to a stable release +- Run after deployments to the appropriate [environments](../application-architecture/#environments), e.g., the edge environment for features of the next release and staging environment for bug fixes to a stable release - Keep smoke tests updated so that they can evolve together with the application **References** @@ -251,7 +251,7 @@ Upgrade tests are manually performed for major code changes and data migrations #### Usability testing -When new features or changes to the application are available on our [Edge or Community environments](../environments), product team members, customers, and community users can provide usability feedback on how the change is perceived. +When new features or changes to the application are available on our [Edge or Community environments](../application-architecture/#environments), product team members, customers, and community users can provide usability feedback on how the change is perceived. **Key objectives and effects** @@ -725,7 +725,7 @@ good as a test server. ### Running tests locally in Docker Most of the above applies to running tests locally, with some docker specific setup changes that are discussed [in the -docker development documentation](../development-environment-docker). +docker development documentation](../development-environment/docker). ### Generators diff --git a/docs/installation-and-operations/installation/manual/README.md b/docs/installation-and-operations/installation/manual/README.md index 1664c77b412f..ca8887e63dff 100644 --- a/docs/installation-and-operations/installation/manual/README.md +++ b/docs/installation-and-operations/installation/manual/README.md @@ -456,8 +456,3 @@ If you need to restart the server (for example after a configuration change), do With each new OpenProject core version, the plug-ins might need to be updated. Please make sure that the plug-in versions of all you plug-ins works with the OpenProject version you use. Many plug-ins follow the OpenProject version with their version number (So, if you have installed OpenProject version 4.1.0, the plug-in should also have the version 4.1.0). - -## Questions, comments, and feedback - -If you have any further questions, comments, feedback, or an idea to enhance this guide, please tell us at the appropriate community [forum](https://community.openproject.org/projects/openproject/boards/9). -[Follow OpenProject on twitter](https://twitter.com/openproject), and follow the news on [openproject.org](https://www.openproject.org) to stay up to date. diff --git a/docs/release-notes/14-4-1/README.md b/docs/release-notes/14-4-1/README.md new file mode 100644 index 000000000000..f161e68d01bd --- /dev/null +++ b/docs/release-notes/14-4-1/README.md @@ -0,0 +1,32 @@ +--- +title: OpenProject 14.4.1 +sidebar_navigation: + title: 14.4.1 +release_version: 14.4.1 +release_date: 2024-08-28 +--- + +# OpenProject 14.4.1 + +Release date: 2024-08-28 + +We released OpenProject [OpenProject 14.4.1](https://community.openproject.org/versions/2110). +The release contains several bug fixes and we recommend updating to the newest version. +In these Release Notes, we will give an overview of important feature changes. +At the end, you will find a complete list of all changes and bug fixes. + + + +## Bug fixes and changes + + + + +- Bugfix: Project Storage Members breaks when Groups or Placeholder Users are members of a project \[[#57260](https://community.openproject.org/wp/57260)\] +- Bugfix: Custom field filter in project list causes internal server error when opening it \[[#57298](https://community.openproject.org/wp/57298)\] +- Bugfix: Robots follow sort header links unnecessarily \[[#57306](https://community.openproject.org/wp/57306)\] +- Bugfix: Internal error when trying to access notifications menu \[[#57351](https://community.openproject.org/wp/57351)\] +- Bugfix: \[API\] File link creation does not work for legacy nextcloud storage data \[[#57501](https://community.openproject.org/wp/57501)\] + + + diff --git a/docs/release-notes/README.md b/docs/release-notes/README.md index ae1f4c0886e0..20ef61cebbe5 100644 --- a/docs/release-notes/README.md +++ b/docs/release-notes/README.md @@ -13,6 +13,13 @@ Stay up to date and get an overview of the new features included in the releases +## 14.4.1 + +Release date: 2024-08-28 + +[Release Notes](14-4-1/) + + ## 14.4.0 Release date: 2024-08-14 diff --git a/frontend/angular.json b/frontend/angular.json index 4be288938831..7c48128237c2 100644 --- a/frontend/angular.json +++ b/frontend/angular.json @@ -102,38 +102,6 @@ } ] }, - "fastprod": { - "index": "", - "preserveSymlinks": true, - "optimization": false, - "outputHashing": "all", - "sourceMap": false, - "namedChunks": false, - "extractLicenses": false, - "buildOptimizer" : false, - "fileReplacements": [ - { - "replace": "src/environments/environment.ts", - "with": "src/environments/environment.prod.ts" - } - ] - }, - "ci": { - "index": "", - "preserveSymlinks": true, - "optimization": false, - "outputHashing": "all", - "sourceMap": false, - "namedChunks": false, - "extractLicenses": false, - "buildOptimizer" : false, - "fileReplacements": [ - { - "replace": "src/environments/environment.ts", - "with": "src/environments/environment.prod.ts" - } - ] - } } }, "serve": { diff --git a/frontend/extra-webpack.config.js b/frontend/extra-webpack.config.js index 2eef5b817f14..4ca5c933c4b1 100644 --- a/frontend/extra-webpack.config.js +++ b/frontend/extra-webpack.config.js @@ -5,7 +5,7 @@ module.exports = { minimizer: [ new TerserPlugin({ terserOptions: { - mangle: process.env.OPENPROJECT_ANGULAR_UGLIFY !== 'false', + mangle: process.env.OPENPROJECT_ANGULAR_BUILD !== 'fast', keep_classnames: true, keep_fnames: true, } diff --git a/frontend/package-lock.json b/frontend/package-lock.json index c3c3d54e3628..0bb34eab1273 100644 --- a/frontend/package-lock.json +++ b/frontend/package-lock.json @@ -261,11 +261,11 @@ } }, "node_modules/@angular-devkit/architect": { - "version": "0.1703.8", - "resolved": "https://registry.npmjs.org/@angular-devkit/architect/-/architect-0.1703.8.tgz", - "integrity": "sha512-lKxwG4/QABXZvJpqeSIn/kAwnY6MM9HdHZUV+o5o3UiTi+vO8rZApG4CCaITH3Bxebm7Nam7Xbk8RuukC5rq6g==", + "version": "0.1703.9", + "resolved": "https://registry.npmjs.org/@angular-devkit/architect/-/architect-0.1703.9.tgz", + "integrity": "sha512-kEPfTOVnzrJxPGTvaXy8653HU9Fucxttx9gVfQR1yafs+yIEGx3fKGKe89YPmaEay32bIm7ZUpxDF1FO14nkdQ==", "dependencies": { - "@angular-devkit/core": "17.3.8", + "@angular-devkit/core": "17.3.9", "rxjs": "7.8.1" }, "engines": { @@ -275,14 +275,14 @@ } }, "node_modules/@angular-devkit/build-angular": { - "version": "17.3.8", - "resolved": "https://registry.npmjs.org/@angular-devkit/build-angular/-/build-angular-17.3.8.tgz", - "integrity": "sha512-ixsdXggWaFRP7Jvxd0AMukImnePuGflT9Yy7NJ9/y0cL/k//S/3RnkQv5i411KzN+7D4RIbNkRGGTYeqH24zlg==", + "version": "17.3.9", + "resolved": "https://registry.npmjs.org/@angular-devkit/build-angular/-/build-angular-17.3.9.tgz", + "integrity": "sha512-EuAPSC4c2DSJLlL4ieviKLx1faTyY+ymWycq6KFwoxu1FgWly/dqBeWyXccYinLhPVZmoh6+A/5S4YWXlOGSnA==", "dependencies": { "@ampproject/remapping": "2.3.0", - "@angular-devkit/architect": "0.1703.8", - "@angular-devkit/build-webpack": "0.1703.8", - "@angular-devkit/core": "17.3.8", + "@angular-devkit/architect": "0.1703.9", + "@angular-devkit/build-webpack": "0.1703.9", + "@angular-devkit/core": "17.3.9", "@babel/core": "7.24.0", "@babel/generator": "7.23.6", "@babel/helper-annotate-as-pure": "7.22.5", @@ -293,7 +293,7 @@ "@babel/preset-env": "7.24.0", "@babel/runtime": "7.24.0", "@discoveryjs/json-ext": "0.5.7", - "@ngtools/webpack": "17.3.8", + "@ngtools/webpack": "17.3.9", "@vitejs/plugin-basic-ssl": "1.1.0", "ansi-colors": "4.1.3", "autoprefixer": "10.4.18", @@ -337,7 +337,7 @@ "undici": "6.11.1", "vite": "5.1.7", "watchpack": "2.4.0", - "webpack": "5.90.3", + "webpack": "5.94.0", "webpack-dev-middleware": "6.1.2", "webpack-dev-server": "4.15.1", "webpack-merge": "5.10.0", @@ -582,11 +582,11 @@ "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==" }, "node_modules/@angular-devkit/build-webpack": { - "version": "0.1703.8", - "resolved": "https://registry.npmjs.org/@angular-devkit/build-webpack/-/build-webpack-0.1703.8.tgz", - "integrity": "sha512-9u6fl8VVOxcLOEMzrUeaybSvi9hSLSRucHnybneYrabsgreDo32tuy/4G8p6YAHQjpWEj9jvF9Um13ertdni5Q==", + "version": "0.1703.9", + "resolved": "https://registry.npmjs.org/@angular-devkit/build-webpack/-/build-webpack-0.1703.9.tgz", + "integrity": "sha512-3b0LND39Nc+DwCQ0N7Tbsd7RAFWTeIc4VDwk/7RO8EMYTP5Kfgr/TK66nwTBypHsjmD69IMKHZZaZuiDfGfx2A==", "dependencies": { - "@angular-devkit/architect": "0.1703.8", + "@angular-devkit/architect": "0.1703.9", "rxjs": "7.8.1" }, "engines": { @@ -600,9 +600,9 @@ } }, "node_modules/@angular-devkit/core": { - "version": "17.3.8", - "resolved": "https://registry.npmjs.org/@angular-devkit/core/-/core-17.3.8.tgz", - "integrity": "sha512-Q8q0voCGudbdCgJ7lXdnyaxKHbNQBARH68zPQV72WT8NWy+Gw/tys870i6L58NWbBaCJEUcIj/kb6KoakSRu+Q==", + "version": "17.3.9", + "resolved": "https://registry.npmjs.org/@angular-devkit/core/-/core-17.3.9.tgz", + "integrity": "sha512-/iKyn5YT7NW5ylrg9yufUydS8byExeQ2HHIwFC4Ebwb/JYYCz+k4tBf2LdP+zXpemDpLznXTQGWia0/yJjG8Vg==", "dependencies": { "ajv": "8.12.0", "ajv-formats": "2.1.1", @@ -637,11 +637,11 @@ } }, "node_modules/@angular-devkit/schematics": { - "version": "17.3.8", - "resolved": "https://registry.npmjs.org/@angular-devkit/schematics/-/schematics-17.3.8.tgz", - "integrity": "sha512-QRVEYpIfgkprNHc916JlPuNbLzOgrm9DZalHasnLUz4P6g7pR21olb8YCyM2OTJjombNhya9ZpckcADU5Qyvlg==", + "version": "17.3.9", + "resolved": "https://registry.npmjs.org/@angular-devkit/schematics/-/schematics-17.3.9.tgz", + "integrity": "sha512-9qg+uWywgAtaQlvbnCQv47hcL6ZuA+d9ucgZ0upZftBllZ2vp5WIthCPb2mB0uBkj84Csmtz9MsErFjOQtTj4g==", "dependencies": { - "@angular-devkit/core": "17.3.8", + "@angular-devkit/core": "17.3.9", "jsonc-parser": "3.2.1", "magic-string": "0.30.8", "ora": "5.4.1", @@ -888,14 +888,14 @@ } }, "node_modules/@angular/cli": { - "version": "17.3.8", - "resolved": "https://registry.npmjs.org/@angular/cli/-/cli-17.3.8.tgz", - "integrity": "sha512-X5ZOQ6ZTKVHjhIsfl32ZRqbs+FUoeHLbT7x4fh2Os/8ObDDwrUcCJPqxe2b2RB5E2d0vepYigknHeLE7gwzlNQ==", - "dependencies": { - "@angular-devkit/architect": "0.1703.8", - "@angular-devkit/core": "17.3.8", - "@angular-devkit/schematics": "17.3.8", - "@schematics/angular": "17.3.8", + "version": "17.3.9", + "resolved": "https://registry.npmjs.org/@angular/cli/-/cli-17.3.9.tgz", + "integrity": "sha512-b5RGu5RO4VKZlMQDatwABAn1qocgD9u4IrGN2dvHDcrz5apTKYftUdGyG42vngyDNBCg1mWkSDQEWK4f2HfuGg==", + "dependencies": { + "@angular-devkit/architect": "0.1703.9", + "@angular-devkit/core": "17.3.9", + "@angular-devkit/schematics": "17.3.9", + "@schematics/angular": "17.3.9", "@yarnpkg/lockfile": "1.1.0", "ansi-colors": "4.1.3", "ini": "4.1.2", @@ -4071,9 +4071,9 @@ } }, "node_modules/@ngtools/webpack": { - "version": "17.3.8", - "resolved": "https://registry.npmjs.org/@ngtools/webpack/-/webpack-17.3.8.tgz", - "integrity": "sha512-CjSVVa/9fzMpEDQP01SC4colKCbZwj7vUq0H2bivp8jVsmd21x9Fu0gDBH0Y9NdfAIm4eGZvmiZKMII3vIOaYQ==", + "version": "17.3.9", + "resolved": "https://registry.npmjs.org/@ngtools/webpack/-/webpack-17.3.9.tgz", + "integrity": "sha512-2+NvEQuYKRWdZaJbRJWEnR48tpW0uYbhwfHBHLDI9Kazb3mb0oAwYBVXdq+TtDLBypXnMsFpCewjRHTvkVx4/A==", "engines": { "node": "^18.13.0 || >=20.9.0", "npm": "^6.11.0 || ^7.5.6 || >=8.0.0", @@ -5132,12 +5132,12 @@ ] }, "node_modules/@schematics/angular": { - "version": "17.3.8", - "resolved": "https://registry.npmjs.org/@schematics/angular/-/angular-17.3.8.tgz", - "integrity": "sha512-2g4OmSyE9YGq50Uj7fNI26P/TSAFJ7ZuirwTF2O7Xc4XRQ29/tYIIqhezpNlTb6rlYblcQuMcUZBrMfWJHcqJw==", + "version": "17.3.9", + "resolved": "https://registry.npmjs.org/@schematics/angular/-/angular-17.3.9.tgz", + "integrity": "sha512-q6N8mbcYC6cgPyjTrMH7ehULQoUUwEYN4g7uo4ylZ/PFklSLJvpSp4BuuxANgW449qHSBvQfdIoui9ayAUXQzA==", "dependencies": { - "@angular-devkit/core": "17.3.8", - "@angular-devkit/schematics": "17.3.8", + "@angular-devkit/core": "17.3.9", + "@angular-devkit/schematics": "17.3.9", "jsonc-parser": "3.2.1" }, "engines": { @@ -5470,24 +5470,6 @@ "integrity": "sha512-jojr2JVJB8DawAKXApGnollMvVOMyiMKpchH8gLeoExx35Eq0BQ4WgAiAHoBoEn7h/9eDrIl0yz//cM6ALIJbg==", "dev": true }, - "node_modules/@types/eslint": { - "version": "8.56.9", - "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.56.9.tgz", - "integrity": "sha512-W4W3KcqzjJ0sHg2vAq9vfml6OhsJ53TcUjUqfzzZf/EChUtwspszj/S0pzMxnfRcO55/iGq47dscXw71Fxc4Zg==", - "dependencies": { - "@types/estree": "*", - "@types/json-schema": "*" - } - }, - "node_modules/@types/eslint-scope": { - "version": "3.7.7", - "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.7.tgz", - "integrity": "sha512-MzMFlSLBqNF2gcHWO0G1vP/YQyfvrxZ0bF+u7mzUdZ1/xK4A4sru+nraZz5i3iEIk1l1uyicaDVTB4QbbEkAYg==", - "dependencies": { - "@types/eslint": "*", - "@types/estree": "*" - } - }, "node_modules/@types/estree": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", @@ -6646,10 +6628,10 @@ "node": ">=0.4.0" } }, - "node_modules/acorn-import-assertions": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz", - "integrity": "sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA==", + "node_modules/acorn-import-attributes": { + "version": "1.9.5", + "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz", + "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==", "peerDependencies": { "acorn": "^8" } @@ -8196,9 +8178,9 @@ } }, "node_modules/chrome-trace-event": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.3.tgz", - "integrity": "sha512-p3KULyQg4S7NIHixdwbGX+nFHkoBiA4YQmyWtjb8XngSKV124nJmRysgAeujbUVb15vh+RvFUfCPqU7rXk+hZg==", + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.4.tgz", + "integrity": "sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ==", "engines": { "node": ">=6.0" } @@ -8730,9 +8712,9 @@ } }, "node_modules/core-js": { - "version": "3.38.0", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.38.0.tgz", - "integrity": "sha512-XPpwqEodRljce9KswjZShh95qJ1URisBeKCjUdq27YdenkslVe7OO0ZJhlYXAChW7OhXaRLl8AAba7IBfoIHug==", + "version": "3.38.1", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.38.1.tgz", + "integrity": "sha512-OP35aUorbU3Zvlx7pjsFdu1rGNnD4pgw/CWoYzRY3t2EzoVT7shKHY1dlAy3f41cGIO7ZDPQimhGFTlEYkG/Hw==", "hasInstallScript": true, "funding": { "type": "opencollective", @@ -9745,9 +9727,9 @@ } }, "node_modules/enhanced-resolve": { - "version": "5.16.0", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.16.0.tgz", - "integrity": "sha512-O+QWCviPNSSLAD9Ucn8Awv+poAkqn3T1XY5/N7kR7rQO9yfSGWkYZDwpJ+iKF7B8rxaQKWngSqACpgzeapSyoA==", + "version": "5.17.1", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.17.1.tgz", + "integrity": "sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==", "dependencies": { "graceful-fs": "^4.2.4", "tapable": "^2.2.0" @@ -9958,9 +9940,9 @@ } }, "node_modules/es-module-lexer": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.5.0.tgz", - "integrity": "sha512-pqrTKmwEIgafsYZAGw9kszYzmagcE/n4dbgwGWLEXg7J4QFJVQRBld8j3Q3GNez79jzxZshq0bcT962QHOghjw==" + "version": "1.5.4", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.5.4.tgz", + "integrity": "sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw==" }, "node_modules/es-object-atoms": { "version": "1.0.0", @@ -21534,25 +21516,24 @@ } }, "node_modules/webpack": { - "version": "5.90.3", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.90.3.tgz", - "integrity": "sha512-h6uDYlWCctQRuXBs1oYpVe6sFcWedl0dpcVaTf/YF67J9bKvwJajFulMVSYKHrksMB3I/pIagRzDxwxkebuzKA==", + "version": "5.94.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz", + "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==", "dependencies": { - "@types/eslint-scope": "^3.7.3", "@types/estree": "^1.0.5", - "@webassemblyjs/ast": "^1.11.5", - "@webassemblyjs/wasm-edit": "^1.11.5", - "@webassemblyjs/wasm-parser": "^1.11.5", + "@webassemblyjs/ast": "^1.12.1", + "@webassemblyjs/wasm-edit": "^1.12.1", + "@webassemblyjs/wasm-parser": "^1.12.1", "acorn": "^8.7.1", - "acorn-import-assertions": "^1.9.0", + "acorn-import-attributes": "^1.9.5", "browserslist": "^4.21.10", "chrome-trace-event": "^1.0.2", - "enhanced-resolve": "^5.15.0", + "enhanced-resolve": "^5.17.1", "es-module-lexer": "^1.2.1", "eslint-scope": "5.1.1", "events": "^3.2.0", "glob-to-regexp": "^0.4.1", - "graceful-fs": "^4.2.9", + "graceful-fs": "^4.2.11", "json-parse-even-better-errors": "^2.3.1", "loader-runner": "^4.2.0", "mime-types": "^2.1.27", @@ -21560,7 +21541,7 @@ "schema-utils": "^3.2.0", "tapable": "^2.1.1", "terser-webpack-plugin": "^5.3.10", - "watchpack": "^2.4.0", + "watchpack": "^2.4.1", "webpack-sources": "^3.2.3" }, "bin": { @@ -21931,6 +21912,18 @@ "url": "https://opencollective.com/webpack" } }, + "node_modules/webpack/node_modules/watchpack": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz", + "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==", + "dependencies": { + "glob-to-regexp": "^0.4.1", + "graceful-fs": "^4.1.2" + }, + "engines": { + "node": ">=10.13.0" + } + }, "node_modules/websocket-driver": { "version": "0.7.4", "resolved": "https://registry.npmjs.org/websocket-driver/-/websocket-driver-0.7.4.tgz", @@ -22322,23 +22315,23 @@ } }, "@angular-devkit/architect": { - "version": "0.1703.8", - "resolved": "https://registry.npmjs.org/@angular-devkit/architect/-/architect-0.1703.8.tgz", - "integrity": "sha512-lKxwG4/QABXZvJpqeSIn/kAwnY6MM9HdHZUV+o5o3UiTi+vO8rZApG4CCaITH3Bxebm7Nam7Xbk8RuukC5rq6g==", + "version": "0.1703.9", + "resolved": "https://registry.npmjs.org/@angular-devkit/architect/-/architect-0.1703.9.tgz", + "integrity": "sha512-kEPfTOVnzrJxPGTvaXy8653HU9Fucxttx9gVfQR1yafs+yIEGx3fKGKe89YPmaEay32bIm7ZUpxDF1FO14nkdQ==", "requires": { - "@angular-devkit/core": "17.3.8", + "@angular-devkit/core": "17.3.9", "rxjs": "7.8.1" } }, "@angular-devkit/build-angular": { - "version": "17.3.8", - "resolved": "https://registry.npmjs.org/@angular-devkit/build-angular/-/build-angular-17.3.8.tgz", - "integrity": "sha512-ixsdXggWaFRP7Jvxd0AMukImnePuGflT9Yy7NJ9/y0cL/k//S/3RnkQv5i411KzN+7D4RIbNkRGGTYeqH24zlg==", + "version": "17.3.9", + "resolved": "https://registry.npmjs.org/@angular-devkit/build-angular/-/build-angular-17.3.9.tgz", + "integrity": "sha512-EuAPSC4c2DSJLlL4ieviKLx1faTyY+ymWycq6KFwoxu1FgWly/dqBeWyXccYinLhPVZmoh6+A/5S4YWXlOGSnA==", "requires": { "@ampproject/remapping": "2.3.0", - "@angular-devkit/architect": "0.1703.8", - "@angular-devkit/build-webpack": "0.1703.8", - "@angular-devkit/core": "17.3.8", + "@angular-devkit/architect": "0.1703.9", + "@angular-devkit/build-webpack": "0.1703.9", + "@angular-devkit/core": "17.3.9", "@babel/core": "7.24.0", "@babel/generator": "7.23.6", "@babel/helper-annotate-as-pure": "7.22.5", @@ -22349,7 +22342,7 @@ "@babel/preset-env": "7.24.0", "@babel/runtime": "7.24.0", "@discoveryjs/json-ext": "0.5.7", - "@ngtools/webpack": "17.3.8", + "@ngtools/webpack": "17.3.9", "@vitejs/plugin-basic-ssl": "1.1.0", "ansi-colors": "4.1.3", "autoprefixer": "10.4.18", @@ -22394,7 +22387,7 @@ "undici": "6.11.1", "vite": "5.1.7", "watchpack": "2.4.0", - "webpack": "5.90.3", + "webpack": "5.94.0", "webpack-dev-middleware": "6.1.2", "webpack-dev-server": "4.15.1", "webpack-merge": "5.10.0", @@ -22514,18 +22507,18 @@ } }, "@angular-devkit/build-webpack": { - "version": "0.1703.8", - "resolved": "https://registry.npmjs.org/@angular-devkit/build-webpack/-/build-webpack-0.1703.8.tgz", - "integrity": "sha512-9u6fl8VVOxcLOEMzrUeaybSvi9hSLSRucHnybneYrabsgreDo32tuy/4G8p6YAHQjpWEj9jvF9Um13ertdni5Q==", + "version": "0.1703.9", + "resolved": "https://registry.npmjs.org/@angular-devkit/build-webpack/-/build-webpack-0.1703.9.tgz", + "integrity": "sha512-3b0LND39Nc+DwCQ0N7Tbsd7RAFWTeIc4VDwk/7RO8EMYTP5Kfgr/TK66nwTBypHsjmD69IMKHZZaZuiDfGfx2A==", "requires": { - "@angular-devkit/architect": "0.1703.8", + "@angular-devkit/architect": "0.1703.9", "rxjs": "7.8.1" } }, "@angular-devkit/core": { - "version": "17.3.8", - "resolved": "https://registry.npmjs.org/@angular-devkit/core/-/core-17.3.8.tgz", - "integrity": "sha512-Q8q0voCGudbdCgJ7lXdnyaxKHbNQBARH68zPQV72WT8NWy+Gw/tys870i6L58NWbBaCJEUcIj/kb6KoakSRu+Q==", + "version": "17.3.9", + "resolved": "https://registry.npmjs.org/@angular-devkit/core/-/core-17.3.9.tgz", + "integrity": "sha512-/iKyn5YT7NW5ylrg9yufUydS8byExeQ2HHIwFC4Ebwb/JYYCz+k4tBf2LdP+zXpemDpLznXTQGWia0/yJjG8Vg==", "requires": { "ajv": "8.12.0", "ajv-formats": "2.1.1", @@ -22543,11 +22536,11 @@ } }, "@angular-devkit/schematics": { - "version": "17.3.8", - "resolved": "https://registry.npmjs.org/@angular-devkit/schematics/-/schematics-17.3.8.tgz", - "integrity": "sha512-QRVEYpIfgkprNHc916JlPuNbLzOgrm9DZalHasnLUz4P6g7pR21olb8YCyM2OTJjombNhya9ZpckcADU5Qyvlg==", + "version": "17.3.9", + "resolved": "https://registry.npmjs.org/@angular-devkit/schematics/-/schematics-17.3.9.tgz", + "integrity": "sha512-9qg+uWywgAtaQlvbnCQv47hcL6ZuA+d9ucgZ0upZftBllZ2vp5WIthCPb2mB0uBkj84Csmtz9MsErFjOQtTj4g==", "requires": { - "@angular-devkit/core": "17.3.8", + "@angular-devkit/core": "17.3.9", "jsonc-parser": "3.2.1", "magic-string": "0.30.8", "ora": "5.4.1", @@ -22718,14 +22711,14 @@ } }, "@angular/cli": { - "version": "17.3.8", - "resolved": "https://registry.npmjs.org/@angular/cli/-/cli-17.3.8.tgz", - "integrity": "sha512-X5ZOQ6ZTKVHjhIsfl32ZRqbs+FUoeHLbT7x4fh2Os/8ObDDwrUcCJPqxe2b2RB5E2d0vepYigknHeLE7gwzlNQ==", - "requires": { - "@angular-devkit/architect": "0.1703.8", - "@angular-devkit/core": "17.3.8", - "@angular-devkit/schematics": "17.3.8", - "@schematics/angular": "17.3.8", + "version": "17.3.9", + "resolved": "https://registry.npmjs.org/@angular/cli/-/cli-17.3.9.tgz", + "integrity": "sha512-b5RGu5RO4VKZlMQDatwABAn1qocgD9u4IrGN2dvHDcrz5apTKYftUdGyG42vngyDNBCg1mWkSDQEWK4f2HfuGg==", + "requires": { + "@angular-devkit/architect": "0.1703.9", + "@angular-devkit/core": "17.3.9", + "@angular-devkit/schematics": "17.3.9", + "@schematics/angular": "17.3.9", "@yarnpkg/lockfile": "1.1.0", "ansi-colors": "4.1.3", "ini": "4.1.2", @@ -24876,9 +24869,9 @@ } }, "@ngtools/webpack": { - "version": "17.3.8", - "resolved": "https://registry.npmjs.org/@ngtools/webpack/-/webpack-17.3.8.tgz", - "integrity": "sha512-CjSVVa/9fzMpEDQP01SC4colKCbZwj7vUq0H2bivp8jVsmd21x9Fu0gDBH0Y9NdfAIm4eGZvmiZKMII3vIOaYQ==" + "version": "17.3.9", + "resolved": "https://registry.npmjs.org/@ngtools/webpack/-/webpack-17.3.9.tgz", + "integrity": "sha512-2+NvEQuYKRWdZaJbRJWEnR48tpW0uYbhwfHBHLDI9Kazb3mb0oAwYBVXdq+TtDLBypXnMsFpCewjRHTvkVx4/A==" }, "@ngx-formly/core": { "version": "6.3.6", @@ -25572,12 +25565,12 @@ "optional": true }, "@schematics/angular": { - "version": "17.3.8", - "resolved": "https://registry.npmjs.org/@schematics/angular/-/angular-17.3.8.tgz", - "integrity": "sha512-2g4OmSyE9YGq50Uj7fNI26P/TSAFJ7ZuirwTF2O7Xc4XRQ29/tYIIqhezpNlTb6rlYblcQuMcUZBrMfWJHcqJw==", + "version": "17.3.9", + "resolved": "https://registry.npmjs.org/@schematics/angular/-/angular-17.3.9.tgz", + "integrity": "sha512-q6N8mbcYC6cgPyjTrMH7ehULQoUUwEYN4g7uo4ylZ/PFklSLJvpSp4BuuxANgW449qHSBvQfdIoui9ayAUXQzA==", "requires": { - "@angular-devkit/core": "17.3.8", - "@angular-devkit/schematics": "17.3.8", + "@angular-devkit/core": "17.3.9", + "@angular-devkit/schematics": "17.3.9", "jsonc-parser": "3.2.1" } }, @@ -25848,24 +25841,6 @@ "integrity": "sha512-jojr2JVJB8DawAKXApGnollMvVOMyiMKpchH8gLeoExx35Eq0BQ4WgAiAHoBoEn7h/9eDrIl0yz//cM6ALIJbg==", "dev": true }, - "@types/eslint": { - "version": "8.56.9", - "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.56.9.tgz", - "integrity": "sha512-W4W3KcqzjJ0sHg2vAq9vfml6OhsJ53TcUjUqfzzZf/EChUtwspszj/S0pzMxnfRcO55/iGq47dscXw71Fxc4Zg==", - "requires": { - "@types/estree": "*", - "@types/json-schema": "*" - } - }, - "@types/eslint-scope": { - "version": "3.7.7", - "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.7.tgz", - "integrity": "sha512-MzMFlSLBqNF2gcHWO0G1vP/YQyfvrxZ0bF+u7mzUdZ1/xK4A4sru+nraZz5i3iEIk1l1uyicaDVTB4QbbEkAYg==", - "requires": { - "@types/eslint": "*", - "@types/estree": "*" - } - }, "@types/estree": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", @@ -26728,10 +26703,10 @@ "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.11.3.tgz", "integrity": "sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg==" }, - "acorn-import-assertions": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz", - "integrity": "sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA==" + "acorn-import-attributes": { + "version": "1.9.5", + "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz", + "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==" }, "acorn-jsx": { "version": "5.3.2", @@ -27852,9 +27827,9 @@ "integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==" }, "chrome-trace-event": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.3.tgz", - "integrity": "sha512-p3KULyQg4S7NIHixdwbGX+nFHkoBiA4YQmyWtjb8XngSKV124nJmRysgAeujbUVb15vh+RvFUfCPqU7rXk+hZg==" + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.4.tgz", + "integrity": "sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ==" }, "class-utils": { "version": "0.3.6", @@ -28258,9 +28233,9 @@ } }, "core-js": { - "version": "3.38.0", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.38.0.tgz", - "integrity": "sha512-XPpwqEodRljce9KswjZShh95qJ1URisBeKCjUdq27YdenkslVe7OO0ZJhlYXAChW7OhXaRLl8AAba7IBfoIHug==" + "version": "3.38.1", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.38.1.tgz", + "integrity": "sha512-OP35aUorbU3Zvlx7pjsFdu1rGNnD4pgw/CWoYzRY3t2EzoVT7shKHY1dlAy3f41cGIO7ZDPQimhGFTlEYkG/Hw==" }, "core-js-compat": { "version": "3.36.1", @@ -29004,9 +28979,9 @@ "dev": true }, "enhanced-resolve": { - "version": "5.16.0", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.16.0.tgz", - "integrity": "sha512-O+QWCviPNSSLAD9Ucn8Awv+poAkqn3T1XY5/N7kR7rQO9yfSGWkYZDwpJ+iKF7B8rxaQKWngSqACpgzeapSyoA==", + "version": "5.17.1", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.17.1.tgz", + "integrity": "sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==", "requires": { "graceful-fs": "^4.2.4", "tapable": "^2.2.0" @@ -29178,9 +29153,9 @@ } }, "es-module-lexer": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.5.0.tgz", - "integrity": "sha512-pqrTKmwEIgafsYZAGw9kszYzmagcE/n4dbgwGWLEXg7J4QFJVQRBld8j3Q3GNez79jzxZshq0bcT962QHOghjw==" + "version": "1.5.4", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.5.4.tgz", + "integrity": "sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw==" }, "es-object-atoms": { "version": "1.0.0", @@ -37687,25 +37662,24 @@ } }, "webpack": { - "version": "5.90.3", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.90.3.tgz", - "integrity": "sha512-h6uDYlWCctQRuXBs1oYpVe6sFcWedl0dpcVaTf/YF67J9bKvwJajFulMVSYKHrksMB3I/pIagRzDxwxkebuzKA==", + "version": "5.94.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz", + "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==", "requires": { - "@types/eslint-scope": "^3.7.3", "@types/estree": "^1.0.5", - "@webassemblyjs/ast": "^1.11.5", - "@webassemblyjs/wasm-edit": "^1.11.5", - "@webassemblyjs/wasm-parser": "^1.11.5", + "@webassemblyjs/ast": "^1.12.1", + "@webassemblyjs/wasm-edit": "^1.12.1", + "@webassemblyjs/wasm-parser": "^1.12.1", "acorn": "^8.7.1", - "acorn-import-assertions": "^1.9.0", + "acorn-import-attributes": "^1.9.5", "browserslist": "^4.21.10", "chrome-trace-event": "^1.0.2", - "enhanced-resolve": "^5.15.0", + "enhanced-resolve": "^5.17.1", "es-module-lexer": "^1.2.1", "eslint-scope": "5.1.1", "events": "^3.2.0", "glob-to-regexp": "^0.4.1", - "graceful-fs": "^4.2.9", + "graceful-fs": "^4.2.11", "json-parse-even-better-errors": "^2.3.1", "loader-runner": "^4.2.0", "mime-types": "^2.1.27", @@ -37713,7 +37687,7 @@ "schema-utils": "^3.2.0", "tapable": "^2.1.1", "terser-webpack-plugin": "^5.3.10", - "watchpack": "^2.4.0", + "watchpack": "^2.4.1", "webpack-sources": "^3.2.3" }, "dependencies": { @@ -37761,6 +37735,15 @@ "ajv": "^6.12.5", "ajv-keywords": "^3.5.2" } + }, + "watchpack": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz", + "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==", + "requires": { + "glob-to-regexp": "^0.4.1", + "graceful-fs": "^4.1.2" + } } } }, diff --git a/frontend/package.json b/frontend/package.json index 6ab4fc9227f5..5615a4afe820 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -162,8 +162,7 @@ }, "scripts": { "analyze": "ng build --configuration production --stats-json && webpack-bundle-analyzer -h 0.0.0.0 -p 9999 ../public/assets/frontend/stats.json", - "build:ci": "node --max_old_space_size=8192 ./node_modules/@angular/cli/bin/ng build --configuration ci", - "build:fast": "OPENPROJECT_ANGULAR_UGLIFY=false node --max_old_space_size=8192 ./node_modules/@angular/cli/bin/ng build --configuration fastprod", + "build:fast": "OPENPROJECT_ANGULAR_BUILD=fast node --max_old_space_size=8192 ./node_modules/@angular/cli/bin/ng build --configuration production", "build": "node --max_old_space_size=4096 ./node_modules/@angular/cli/bin/ng build --configuration production --named-chunks --source-map", "build:watch": "node --max_old_space_size=4096 ./node_modules/@angular/cli/bin/ng build --watch --named-chunks", "tokens:generate": "theo src/app/spot/styles/tokens/tokens.yml --transform web --format sass,json --dest src/app/spot/styles/tokens/dist", diff --git a/frontend/src/app/features/hal/services/hal-resource.service.ts b/frontend/src/app/features/hal/services/hal-resource.service.ts index 66ec21cf0d31..59d6c055e0d7 100644 --- a/frontend/src/app/features/hal/services/hal-resource.service.ts +++ b/frontend/src/app/features/hal/services/hal-resource.service.ts @@ -26,23 +26,10 @@ // See COPYRIGHT and LICENSE files for more details. //++ -import { - Injectable, - Injector, -} from '@angular/core'; -import { - HttpClient, - HttpErrorResponse, - HttpParams, -} from '@angular/common/http'; -import { - catchError, - map, -} from 'rxjs/operators'; -import { - Observable, - throwError, -} from 'rxjs'; +import { Injectable, Injector } from '@angular/core'; +import { HttpClient, HttpErrorResponse, HttpParams } from '@angular/common/http'; +import { catchError, map } from 'rxjs/operators'; +import { Observable, throwError } from 'rxjs'; import { CollectionResource } from 'core-app/features/hal/resources/collection-resource'; import { ErrorResource } from 'core-app/features/hal/resources/error-resource'; import * as Pako from 'pako'; @@ -54,15 +41,9 @@ import { HTTPClientParamMap, HTTPSupportedMethods, } from 'core-app/features/hal/http/http.interfaces'; -import { - HalLink, - HalLinkInterface, -} from 'core-app/features/hal/hal-link/hal-link'; +import { HalLink, HalLinkInterface } from 'core-app/features/hal/hal-link/hal-link'; import { URLParamsEncoder } from 'core-app/features/hal/services/url-params-encoder'; -import { - HalResource, - HalResourceClass, -} from 'core-app/features/hal/resources/hal-resource'; +import { HalResource, HalResourceClass } from 'core-app/features/hal/resources/hal-resource'; import { initializeHalProperties } from '../helpers/hal-resource-builder'; import { HalError } from 'core-app/features/hal/services/hal-error'; import { getPaginatedCollections } from 'core-app/core/apiv3/helpers/get-paginated-results'; @@ -289,6 +270,7 @@ export class HalResourceService { } /** + * * Get a linked resource from its HalLink with the correct type. */ public createLinkedResource(halResource:T, linkName:string, link:HalLinkInterface) { @@ -327,6 +309,7 @@ export class HalResourceService { protected toEprops(params:unknown):{ eprops:string } { const deflatedArray = Pako.deflate(JSON.stringify(params)); + const compressed = base64.bytesToBase64(deflatedArray); return { eprops: compressed }; diff --git a/frontend/src/app/features/plugins/plugin-context.ts b/frontend/src/app/features/plugins/plugin-context.ts index 01e1604ceff9..20371f50c4cc 100644 --- a/frontend/src/app/features/plugins/plugin-context.ts +++ b/frontend/src/app/features/plugins/plugin-context.ts @@ -31,6 +31,7 @@ import { import { DomAutoscrollService } from 'core-app/shared/helpers/drag-and-drop/dom-autoscroll.service'; import { AttachmentsResourceService } from 'core-app/core/state/attachments/attachments.service'; import { HttpClient } from '@angular/common/http'; +import { TimezoneService } from 'core-app/core/datetime/timezone.service'; /** * Plugin context bridge for plugins outside the CLI compiler context @@ -53,6 +54,7 @@ export class OpenProjectPluginContext { hooks: this.injector.get(HookService), i18n: this.injector.get(I18nService), notifications: this.injector.get(ToastService), + timezone: this.injector.get(TimezoneService), opModalService: this.injector.get(OpModalService), displayField: this.injector.get(DisplayFieldService), editField: this.injector.get(EditFieldService), diff --git a/frontend/src/app/features/work-packages/components/wp-table/wp-table.component.html b/frontend/src/app/features/work-packages/components/wp-table/wp-table.component.html index 93a506c9b6bd..4f51a55a9790 100644 --- a/frontend/src/app/features/work-packages/components/wp-table/wp-table.component.html +++ b/frontend/src/app/features/work-packages/components/wp-table/wp-table.component.html @@ -90,6 +90,7 @@ class="work-packages--tabletimeline--timeline--resizer hidden-for-mobile hide-when-print"> diff --git a/frontend/src/app/features/work-packages/routing/wp-full-view/wp-full-view.html b/frontend/src/app/features/work-packages/routing/wp-full-view/wp-full-view.html index 68482fef358b..a364194a4c85 100644 --- a/frontend/src/app/features/work-packages/routing/wp-full-view/wp-full-view.html +++ b/frontend/src/app/features/work-packages/routing/wp-full-view/wp-full-view.html @@ -81,6 +81,7 @@
    diff --git a/frontend/src/app/features/work-packages/routing/wp-split-view/wp-split-view-entry.component.ts b/frontend/src/app/features/work-packages/routing/wp-split-view/wp-split-view-entry.component.ts index 43a3942d7d9b..3ed93189d8da 100644 --- a/frontend/src/app/features/work-packages/routing/wp-split-view/wp-split-view-entry.component.ts +++ b/frontend/src/app/features/work-packages/routing/wp-split-view/wp-split-view-entry.component.ts @@ -43,7 +43,6 @@ import { populateInputsFromDataset } from 'core-app/shared/components/dataset-in [workPackageId]="workPackageId" [activeTab]="activeTab" [showTabs]="false" - [resizeStyle]="resizeStyle" [resizerClass]="resizerClass" > `, @@ -53,7 +52,6 @@ export class WorkPackageSplitViewEntryComponent { @Input() workPackageId:string; @Input() activeTab:string; @Input() resizerClass:string; - @Input() resizeStyle:string; constructor(readonly elementRef:ElementRef) { populateInputsFromDataset(this); diff --git a/frontend/src/app/features/work-packages/routing/wp-split-view/wp-split-view.component.ts b/frontend/src/app/features/work-packages/routing/wp-split-view/wp-split-view.component.ts index 6f672428da8e..d1fb67ad878a 100644 --- a/frontend/src/app/features/work-packages/routing/wp-split-view/wp-split-view.component.ts +++ b/frontend/src/app/features/work-packages/routing/wp-split-view/wp-split-view.component.ts @@ -76,7 +76,6 @@ export class WorkPackageSplitViewComponent extends WorkPackageSingleViewBase imp @Input() activeTab?:string; @Input() resizerClass = 'work-packages-partitioned-page--content-right'; - @Input() resizeStyle:'flexBasis'|'width' = 'flexBasis'; constructor( public injector:Injector, diff --git a/frontend/src/app/features/work-packages/routing/wp-split-view/wp-split-view.html b/frontend/src/app/features/work-packages/routing/wp-split-view/wp-split-view.html index 7342cf387288..e3adad05d238 100644 --- a/frontend/src/app/features/work-packages/routing/wp-split-view/wp-split-view.html +++ b/frontend/src/app/features/work-packages/routing/wp-split-view/wp-split-view.html @@ -69,7 +69,6 @@
    diff --git a/frontend/src/app/shared/components/dynamic-forms/components/dynamic-inputs/formattable-textarea-input/components/formattable-control/formattable-control.component.ts b/frontend/src/app/shared/components/dynamic-forms/components/dynamic-inputs/formattable-textarea-input/components/formattable-control/formattable-control.component.ts index 3b94dd32bea0..5a9ef021fd0f 100644 --- a/frontend/src/app/shared/components/dynamic-forms/components/dynamic-inputs/formattable-textarea-input/components/formattable-control/formattable-control.component.ts +++ b/frontend/src/app/shared/components/dynamic-forms/components/dynamic-inputs/formattable-textarea-input/components/formattable-control/formattable-control.component.ts @@ -1,6 +1,4 @@ -import { - Component, forwardRef, Input, OnInit, ViewChild, -} from '@angular/core'; +import { Component, forwardRef, Input, OnInit, ViewChild } from '@angular/core'; import { I18nService } from 'core-app/core/i18n/i18n.service'; import { FormlyTemplateOptions } from '@ngx-formly/core'; import { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms'; @@ -9,6 +7,7 @@ import { ICKEditorContext, ICKEditorInstance, } from 'core-app/shared/components/editor/components/ckeditor/ckeditor.types'; +import { ICKEditorType } from 'core-app/shared/components/editor/components/ckeditor/ckeditor-setup.service'; @Component({ selector: 'op-formattable-control', @@ -44,7 +43,8 @@ export class FormattableControlComponent implements ControlValueAccessor, OnInit public get ckEditorContext():ICKEditorContext { return { - type: this.templateOptions.editorType, + type: this.templateOptions.editorType as ICKEditorType, + field: this.templateOptions.name as string, // This is a very project resource specific hack to allow macros on description and statusExplanation but // disable it for custom fields. As the formly based approach is currently limited to projects, and that is to be removed, // such a "pragmatic" approach should be ok. diff --git a/frontend/src/app/shared/components/editor/components/ckeditor-augmented-textarea/ckeditor-augmented-textarea.component.ts b/frontend/src/app/shared/components/editor/components/ckeditor-augmented-textarea/ckeditor-augmented-textarea.component.ts index e6d82bc52d32..70b44f268b5c 100644 --- a/frontend/src/app/shared/components/editor/components/ckeditor-augmented-textarea/ckeditor-augmented-textarea.component.ts +++ b/frontend/src/app/shared/components/editor/components/ckeditor-augmented-textarea/ckeditor-augmented-textarea.component.ts @@ -129,6 +129,7 @@ export class CkeditorAugmentedTextareaComponent extends UntilDestroyedMixin impl this.context = { type: this.editorType, resource: this.halResource, + field: this.wrappedTextArea.name, previewContext: this.previewContext, removePlugins: this.removePlugins, }; @@ -149,7 +150,7 @@ export class CkeditorAugmentedTextareaComponent extends UntilDestroyedMixin impl ) .subscribe((evt:SubmitEvent) => { evt.preventDefault(); - this.saveForm(evt); + void this.saveForm(evt); }); } @@ -157,9 +158,10 @@ export class CkeditorAugmentedTextareaComponent extends UntilDestroyedMixin impl window.OpenProject.pageWasEdited = true; } - public saveForm(evt?:SubmitEvent):void { - this.syncToTextarea(); + public async saveForm(evt?:SubmitEvent):Promise { this.inFlight = true; + + this.syncToTextarea(); window.OpenProject.pageIsSubmitted = true; setTimeout(() => { @@ -193,8 +195,9 @@ export class CkeditorAugmentedTextareaComponent extends UntilDestroyedMixin impl private syncToTextarea() { try { - this.wrappedTextArea.value = this.ckEditorInstance.getRawData(); + this.wrappedTextArea.value = this.ckEditorInstance.getTransformedContent(true); } catch (e) { + // eslint-disable-next-line @typescript-eslint/no-base-to-string const message = (e as Error)?.message || (e as object).toString(); console.error(`Failed to save CKEditor body to textarea: ${message}.`); this.Notifications.addError(message || this.I18n.t('js.error.internal')); diff --git a/frontend/src/app/shared/components/editor/components/ckeditor/ckeditor-setup.service.ts b/frontend/src/app/shared/components/editor/components/ckeditor/ckeditor-setup.service.ts index 41fb1b8e82f2..507795dc47f2 100644 --- a/frontend/src/app/shared/components/editor/components/ckeditor/ckeditor-setup.service.ts +++ b/frontend/src/app/shared/components/editor/components/ckeditor/ckeditor-setup.service.ts @@ -80,9 +80,11 @@ export class CKEditorSetupService { // Allow custom events on wrapper to set/get data for debugging jQuery(wrapper) - .on('op:ckeditor:setData', (event:unknown, data:string) => editor.setData(data)) + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access,@typescript-eslint/no-unsafe-call,@typescript-eslint/no-unsafe-return + .on('op:ckeditor:autosave', () => editor.config.get('autosave').save(editor)) + .on('op:ckeditor:setData', (_, data:string) => editor.setData(data)) .on('op:ckeditor:clear', () => editor.setData(' ')) - .on('op:ckeditor:getData', (event:unknown, cb:(data:string) => void) => cb(editor.getData({ trim: false }))); + .on('op:ckeditor:getData', (_, cb:(data:string) => void) => cb(editor.getData({ trim: false }))); return watchdog; }); diff --git a/frontend/src/app/shared/components/editor/components/ckeditor/ckeditor.types.ts b/frontend/src/app/shared/components/editor/components/ckeditor/ckeditor.types.ts index f60aa15bae9f..bcaae992decc 100644 --- a/frontend/src/app/shared/components/editor/components/ckeditor/ckeditor.types.ts +++ b/frontend/src/app/shared/components/editor/components/ckeditor/ckeditor.types.ts @@ -21,6 +21,10 @@ export interface CKEditorDomEventData { } export interface ICKEditorInstance { + id:string; + + state:string; + getData(options:{ trim:boolean }):string; setData(content:string):void; @@ -88,6 +92,8 @@ export interface ICKEditorContext { type:ICKEditorType; // Hal Resource to pass into ckeditor resource?:HalResource; + // If available, field name of the edit + field?:string; // Specific removing of plugins removePlugins?:string[]; // Set of enabled macro plugins or false to disable all diff --git a/frontend/src/app/shared/components/editor/components/ckeditor/op-ckeditor.component.ts b/frontend/src/app/shared/components/editor/components/ckeditor/op-ckeditor.component.ts index ecb70c61d3d3..f29c1558d5c7 100644 --- a/frontend/src/app/shared/components/editor/components/ckeditor/op-ckeditor.component.ts +++ b/frontend/src/app/shared/components/editor/components/ckeditor/op-ckeditor.component.ts @@ -26,16 +26,7 @@ // See COPYRIGHT and LICENSE files for more details. //++ -import { - Component, - ElementRef, - EventEmitter, - Input, - OnDestroy, - OnInit, - Output, - ViewChild, -} from '@angular/core'; +import { Component, ElementRef, EventEmitter, Input, OnDestroy, OnInit, Output, ViewChild } from '@angular/core'; import { ToastService } from 'core-app/shared/components/toaster/toast.service'; import { I18nService } from 'core-app/core/i18n/i18n.service'; import { ConfigurationService } from 'core-app/core/config/configuration.service'; @@ -47,6 +38,7 @@ import { import { CKEditorSetupService } from 'core-app/shared/components/editor/components/ckeditor/ckeditor-setup.service'; import { KeyCodes } from 'core-app/shared/helpers/keyCodes.enum'; import { debugLog } from 'core-app/shared/helpers/debug_output'; +import { UntilDestroyedMixin } from 'core-app/shared/helpers/angular/until-destroyed.mixin'; declare module 'codemirror'; @@ -55,7 +47,7 @@ declare module 'codemirror'; templateUrl: './op-ckeditor.html', styleUrls: ['./op-ckeditor.sass'], }) -export class OpCkeditorComponent implements OnInit, OnDestroy { +export class OpCkeditorComponent extends UntilDestroyedMixin implements OnInit, OnDestroy { @Input() context:ICKEditorContext; @Input() @@ -108,10 +100,8 @@ export class OpCkeditorComponent implements OnInit, OnDestroy { // to read back changes as they happen private debouncedEmitter = _.debounce( () => { - void this.getTransformedContent(false) - .then((val) => { - this.contentChanged.emit(val); - }); + const val = this.getTransformedContent(false); + this.contentChanged.emit(val); }, 1000, { leading: true }, @@ -126,6 +116,7 @@ export class OpCkeditorComponent implements OnInit, OnDestroy { private readonly configurationService:ConfigurationService, private readonly ckEditorSetup:CKEditorSetupService, ) { + super(); } /** @@ -133,38 +124,58 @@ export class OpCkeditorComponent implements OnInit, OnDestroy { * the data cannot be loaded (MS Edge!) */ public getRawData():string { + let content:string; + if (this.manualMode) { - return this._content = this.codeMirrorInstance.getValue(); + // eslint-disable-next-line @typescript-eslint/no-unsafe-call,@typescript-eslint/no-unsafe-member-access + content = this.codeMirrorInstance.getValue() as string; + } else { + content = this.ckEditorInstance.getData({ trim: false }); } - return this._content = this.ckEditorInstance.getData({ trim: false }); + + if (content === null || content === undefined) { + throw new Error('Trying to get content from CKEditor failed, as it returned null.'); + } + + this._content = content; + return content; } /** * Get a promise with the transformed content, will wrap errors in the promise. * @param notificationOnError */ - public getTransformedContent(notificationOnError = true):Promise { - if (!this.initialized) { - throw new Error('Tried to access CKEditor instance before initialization.'); - } + public getTransformedContent(notificationOnError = true):string { + try { + if (!this.initialized) { + throw new Error('Tried to access CKEditor instance before initialization.'); + } - return new Promise((resolve, reject) => { - try { - resolve(this.getRawData()); - } catch (e) { - console.error(`Failed to save CKEditor content: ${e}.`); - const error = this.I18n.t( - 'js.editor.error_saving_failed', - { error: e || this.I18n.t('js.error.internal') }, - ); + if (this.componentDestroyed) { + throw new Error('Component destroyed'); + } - if (notificationOnError) { - this.Notifications.addError(error); - } + if (!this.ckEditorInstance || this.ckEditorInstance.state === 'destroyed') { + console.warn('CKEditor instance is destroyed, returning last content'); + return this._content; + } + + return this.getRawData(); + } catch (e) { + console.error(`Failed to save CKEditor content: ${e}.`); + + const error = this.I18n.t( + 'js.editor.error_saving_failed', + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access,@typescript-eslint/no-unsafe-assignment,@typescript-eslint/no-unsafe-call + { error: e.toString() || this.I18n.t('js.error.internal') }, + ); - reject(error); + if (notificationOnError) { + this.Notifications.addError(error); } - }); + + return this._content; + } } /** @@ -217,7 +228,6 @@ export class OpCkeditorComponent implements OnInit, OnDestroy { const editor = watchdog.editor; this.ckEditorInstance = editor; - // Switch mode editor.on('op:source-code-enabled', () => this.enableManualMode()); editor.on('op:source-code-disabled', () => this.disableManualMode()); diff --git a/frontend/src/app/shared/components/fields/edit/field-types/formattable-edit-field/formattable-edit-field.component.ts b/frontend/src/app/shared/components/fields/edit/field-types/formattable-edit-field/formattable-edit-field.component.ts index f2213be03e63..0cc5fce95667 100644 --- a/frontend/src/app/shared/components/fields/edit/field-types/formattable-edit-field/formattable-edit-field.component.ts +++ b/frontend/src/app/shared/components/fields/edit/field-types/formattable-edit-field/formattable-edit-field.component.ts @@ -25,13 +25,7 @@ // See COPYRIGHT and LICENSE files for more details. // ++ -import { - ChangeDetectionStrategy, - Component, - OnDestroy, - OnInit, - ViewChild, -} from '@angular/core'; +import { ChangeDetectionStrategy, Component, OnDestroy, OnInit, ViewChild } from '@angular/core'; import { EditFieldComponent } from 'core-app/shared/components/fields/edit/edit-field.component'; import { OpCkeditorComponent } from 'core-app/shared/components/editor/components/ckeditor/op-ckeditor.component'; import { @@ -65,17 +59,20 @@ export class FormattableEditFieldComponent extends EditFieldComponent implements public ckEditorContext:ICKEditorContext = { resource: this.change.pristineResource, + field: this.field.name, macros: 'none' as const, previewContext: this.previewContext, + // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment,@typescript-eslint/no-unsafe-member-access options: { rtl: this.schema.options && this.schema.options.rtl }, type: 'constrained', + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access,@typescript-eslint/no-unsafe-call ...this.resource.getEditorContext(this.field.name), - }; + } as ICKEditorContext; ngOnInit():void { super.ngOnInit(); - this.handler.registerOnSubmit(() => this.getCurrentValue()); + this.handler.registerOnSubmit(() => Promise.resolve(this.getCurrentValue())); this.text = { attachmentLabel: this.I18n.t('js.label_formattable_attachment_hint'), save: this.I18n.t('js.inplace.button_save', { attribute: this.schema.name }), @@ -101,12 +98,8 @@ export class FormattableEditFieldComponent extends EditFieldComponent implements } } - public getCurrentValue():Promise { - return this.editor - .getTransformedContent() - .then((val) => { - this.rawValue = val; - }); + public getCurrentValue():void { + this.rawValue = this.editor.getTransformedContent(); } public onContentChange(value:string):void { @@ -118,10 +111,8 @@ export class FormattableEditFieldComponent extends EditFieldComponent implements } public handleUserSubmit():boolean { - this.getCurrentValue() - .then(() => { - this.handler.handleUserSubmit(); - }); + this.getCurrentValue(); + void this.handler.handleUserSubmit(); return false; } diff --git a/frontend/src/app/shared/components/forms/highlighted-input.sass b/frontend/src/app/shared/components/forms/highlighted-input.sass index 97e760925770..67df2bffe13a 100644 --- a/frontend/src/app/shared/components/forms/highlighted-input.sass +++ b/frontend/src/app/shared/components/forms/highlighted-input.sass @@ -7,7 +7,7 @@ border-radius: 4px &_active - border: 1px solid #90cdf4 - background: #ebf8ff + border: 1px solid var(--borderColor-accent-muted) + background-color: var(--bgColor-accent-muted) & .ng-select-container background-color: var(--body-background) !important diff --git a/frontend/src/app/shared/components/option-list/option-list.sass b/frontend/src/app/shared/components/option-list/option-list.sass index afd0c6c2a863..8b3e01ef4f2f 100644 --- a/frontend/src/app/shared/components/option-list/option-list.sass +++ b/frontend/src/app/shared/components/option-list/option-list.sass @@ -18,8 +18,8 @@ margin-bottom: 0.5rem &_selected - border: 1px solid #90cdf4 - background: #ebf8ff + border: 1px solid var(--borderColor-accent-muted) + background-color: var(--bgColor-accent-muted) &_disabled color: #959595 diff --git a/frontend/src/app/shared/components/resizer/resizer.component.ts b/frontend/src/app/shared/components/resizer/resizer.component.ts index 7e4f38c6f52f..47874dacf0f6 100644 --- a/frontend/src/app/shared/components/resizer/resizer.component.ts +++ b/frontend/src/app/shared/components/resizer/resizer.component.ts @@ -137,7 +137,6 @@ export class ResizerComponent implements OnDestroy { } private onMouseMove(event:MouseEvent|TouchEvent) { - event.preventDefault(); event.stopPropagation(); this.oldX = this.newX; diff --git a/frontend/src/app/shared/components/resizer/resizer/wp-resizer.component.ts b/frontend/src/app/shared/components/resizer/resizer/wp-resizer.component.ts index 75d7426a33e2..2ab52d9d40c2 100644 --- a/frontend/src/app/shared/components/resizer/resizer/wp-resizer.component.ts +++ b/frontend/src/app/shared/components/resizer/resizer/wp-resizer.component.ts @@ -29,7 +29,6 @@ import { AfterViewInit, ChangeDetectionStrategy, Component, ElementRef, Input, OnInit } from '@angular/core'; import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; import { TransitionService } from '@uirouter/core'; -import { BrowserDetector } from 'core-app/core/browser/browser-detector.service'; import { UntilDestroyedMixin } from 'core-app/shared/helpers/angular/until-destroyed.mixin'; import { ResizeDelta } from 'core-app/shared/components/resizer/resizer.component'; import { fromEvent } from 'rxjs'; @@ -56,7 +55,7 @@ export class WpResizerDirective extends UntilDestroyedMixin implements OnInit, A @Input() localStorageKey:string; - @Input() resizeStyle:'flexBasis'|'width' = 'flexBasis'; + @Input() variableName:string = '--split-screen-width'; private resizingElement:HTMLElement; @@ -67,7 +66,7 @@ export class WpResizerDirective extends UntilDestroyedMixin implements OnInit, A private resizer:HTMLElement; // Min-width this element is allowed to have - private elementMinWidth = 530; + private elementMinWidth = 550; public moving = false; @@ -77,7 +76,6 @@ export class WpResizerDirective extends UntilDestroyedMixin implements OnInit, A readonly toggleService:MainMenuToggleService, private elementRef:ElementRef, readonly $transitions:TransitionService, - readonly browserDetector:BrowserDetector, ) { super(); } @@ -88,7 +86,7 @@ export class WpResizerDirective extends UntilDestroyedMixin implements OnInit, A // to still work in case an element is duplicated by Angular. const elements = document.getElementsByClassName(this.elementClass); this.resizingElement = elements[elements.length - 1]; - + if (!this.resizingElement) { return; } @@ -106,7 +104,7 @@ export class WpResizerDirective extends UntilDestroyedMixin implements OnInit, A this.elementWidth = this.resizingElement.parentElement.offsetWidth / 2; } - this.resizingElement.style[this.resizeStyle] = `${this.elementWidth}px`; + this.setWidthVariable(this.elementWidth); // Add event listener this.element = this.elementRef.nativeElement; @@ -142,7 +140,7 @@ export class WpResizerDirective extends UntilDestroyedMixin implements OnInit, A super.ngOnDestroy(); // Reset the style when killing this directive, otherwise the style remains if (this.resizingElement) { - this.resizingElement.style[this.resizeStyle] = ''; + this.setWidthVariable(this.elementMinWidth); } } @@ -193,7 +191,7 @@ export class WpResizerDirective extends UntilDestroyedMixin implements OnInit, A this.applyColumnLayout(); // Set new width - this.resizingElement.style[this.resizeStyle] = `${newValue}px`; + this.setWidthVariable(newValue); } private parseLocalStorageValue():number|undefined { @@ -222,4 +220,8 @@ export class WpResizerDirective extends UntilDestroyedMixin implements OnInit, A this.resizer.classList.remove('-error-font'); } } + + private setWidthVariable(value:number):void { + document.documentElement.style.setProperty(this.variableName, `${value}px`); + } } diff --git a/frontend/src/global_styles/layout/_base.sass b/frontend/src/global_styles/layout/_base.sass index 28b84ef6f321..08da9c9412eb 100644 --- a/frontend/src/global_styles/layout/_base.sass +++ b/frontend/src/global_styles/layout/_base.sass @@ -88,9 +88,11 @@ $right-space: 16px $bottom-space: 10px $left-space: 16px +$left-side-min-width: 300px + #content display: grid - grid-template-columns: 1fr auto + grid-template-columns: minmax($left-side-min-width, 1fr) auto grid-template-rows: auto 1fr grid-template-areas: "header bodyRight" "body bodyRight" padding: 0 @@ -102,6 +104,11 @@ $left-space: 16px z-index: 10 background-color: var(--body-background) + // Basically if the content-BodyRight is filled: + // Apply the user-defined split screen width but be able to shrink in case the screen is not wide enough + &:has(#content-bodyRight > *) + grid-template-columns: minmax($left-side-min-width, 1fr) minmax(550px, var(--split-screen-width)) + &.content--split overflow: hidden diff --git a/frontend/src/global_styles/layout/work_packages/_details_view.sass b/frontend/src/global_styles/layout/work_packages/_details_view.sass index 6c387a043451..bd2e9c6871b6 100644 --- a/frontend/src/global_styles/layout/work_packages/_details_view.sass +++ b/frontend/src/global_styles/layout/work_packages/_details_view.sass @@ -39,7 +39,7 @@ body.router--work-packages-partitioned-split-view-new padding: 0 // Will eventually be overridden by the resizer - flex-basis: 580px + flex-basis: var(--split-screen-width) .work-packages--details height: 100% diff --git a/frontend/src/global_styles/layout/work_packages/_full_view.sass b/frontend/src/global_styles/layout/work_packages/_full_view.sass index ceaae992aa8c..f80f657b2c8a 100644 --- a/frontend/src/global_styles/layout/work_packages/_full_view.sass +++ b/frontend/src/global_styles/layout/work_packages/_full_view.sass @@ -69,7 +69,8 @@ line-height: calc(30px) &--split-right - min-width: 530px + flex-basis: var(--full-view-split-right-width) + min-width: 550px overflow-y: hidden overflow-x: auto position: relative diff --git a/frontend/src/global_styles/layout/work_packages/_table.sass b/frontend/src/global_styles/layout/work_packages/_table.sass index ddf152ec811c..a9c36f7e2f96 100644 --- a/frontend/src/global_styles/layout/work_packages/_table.sass +++ b/frontend/src/global_styles/layout/work_packages/_table.sass @@ -125,7 +125,7 @@ body[class*="router--"] // TIMELINE half of the tabletimeline flexbox .work-packages-tabletimeline--timeline-side border-left: 3px solid var(--borderColor-default) - flex-basis: 50% + flex-basis: var(--gantt-split-width) // Show the horizontal scrollbar _always_ (same as table) overflow-x: scroll // Show the vertical scrollbar when necessary diff --git a/frontend/src/global_styles/openproject/_variable_defaults.scss b/frontend/src/global_styles/openproject/_variable_defaults.scss index ed624748e036..57f165baedbe 100644 --- a/frontend/src/global_styles/openproject/_variable_defaults.scss +++ b/frontend/src/global_styles/openproject/_variable_defaults.scss @@ -131,4 +131,7 @@ --link-text-decoration: none; --type-form-conf-attribute--background: var(--gray-light); --select-arrow-bg-color-url: url("data:image/svg+xml;utf8,"); + --split-screen-width: 550px; + --full-view-split-right-width: 550px; + --gantt-split-width: 50%; } diff --git a/frontend/src/stimulus/controllers/dynamic/admin/work-packages-settings.controller.ts b/frontend/src/stimulus/controllers/dynamic/admin/work-packages-settings.controller.ts index 147cb918ba9e..6dc3e76c2355 100644 --- a/frontend/src/stimulus/controllers/dynamic/admin/work-packages-settings.controller.ts +++ b/frontend/src/stimulus/controllers/dynamic/admin/work-packages-settings.controller.ts @@ -31,12 +31,18 @@ import { Controller } from '@hotwired/stimulus'; export default class WorkPackagesSettingsController extends Controller { + static values = { + percentCompleteEditionActive: Boolean, + }; + static targets = [ 'progressCalculationModeSelect', 'warningText', 'warningToast', ]; + declare readonly percentCompleteEditionActiveValue:boolean; + declare readonly progressCalculationModeSelectTarget:HTMLSelectElement; declare readonly warningTextTarget:HTMLElement; declare readonly warningToastTarget:HTMLElement; @@ -58,9 +64,19 @@ export default class WorkPackagesSettingsController extends Controller { getWarningMessageHtml():string { const newMode = this.progressCalculationModeSelectTarget.value; + if (newMode === this.initialMode) { + return ''; + } + + // to be removed in 15.0 with :percent_complete_edition feature flag removal + if (!this.percentCompleteEditionActiveValue && newMode === 'field') { + return I18n.t( + 'js.admin.work_packages_settings.warning_progress_calculation_mode_change_from_status_to_field_pre_14_4_without_percent_complete_edition_html', + ); + } + return I18n.t( `js.admin.work_packages_settings.warning_progress_calculation_mode_change_from_${this.initialMode}_to_${newMode}_html`, - { defaultValue: '' }, ); } } diff --git a/frontend/src/stimulus/controllers/dynamic/work-packages/progress/preview-progress.controller.ts b/frontend/src/stimulus/controllers/dynamic/work-packages/progress/preview-progress.controller.ts index e3de2013ec1a..2b39d00218dd 100644 --- a/frontend/src/stimulus/controllers/dynamic/work-packages/progress/preview-progress.controller.ts +++ b/frontend/src/stimulus/controllers/dynamic/work-packages/progress/preview-progress.controller.ts @@ -91,20 +91,22 @@ export default class PreviewProgressController extends Controller { const formData = new FormData(form) as unknown as undefined; const formParams = new URLSearchParams(formData); const wpParams = [ - ['work_package[initial][remaining_hours]', formParams.get('work_package[initial][remaining_hours]') || ''], ['work_package[initial][estimated_hours]', formParams.get('work_package[initial][estimated_hours]') || ''], + ['work_package[initial][remaining_hours]', formParams.get('work_package[initial][remaining_hours]') || ''], ['work_package[initial][done_ratio]', formParams.get('work_package[initial][done_ratio]') || ''], - ['work_package[remaining_hours]', formParams.get('work_package[remaining_hours]') || ''], ['work_package[estimated_hours]', formParams.get('work_package[estimated_hours]') || ''], + ['work_package[remaining_hours]', formParams.get('work_package[remaining_hours]') || ''], ['work_package[done_ratio]', formParams.get('work_package[done_ratio]') || ''], ['work_package[status_id]', formParams.get('work_package[status_id]') || ''], ['field', field?.name ?? ''], - ['work_package[estimated_hours_touched]', formParams.get('work_package[estimated_hours_touched]') || ''], - ['work_package[remaining_hours_touched]', formParams.get('work_package[remaining_hours_touched]') || ''], - ['work_package[done_ratio_touched]', formParams.get('work_package[done_ratio_touched]') || ''], - ['work_package[status_id_touched]', formParams.get('work_package[status_id_touched]') || ''], ]; + this.progressInputTargets.forEach((progressInput) => { + const touchedInputName = progressInput.name.replace(']', '_touched]'); + const touchedValue = formParams.get(touchedInputName) || ''; + wpParams.push([touchedInputName, touchedValue]); + }); + const wpPath = this.ensureValidPathname(form.action); const wpAction = wpPath.endsWith('/work_packages/new/progress') ? 'new' : 'edit'; diff --git a/frontend/src/stimulus/controllers/dynamic/work-packages/progress/touched-field-marker.controller.ts b/frontend/src/stimulus/controllers/dynamic/work-packages/progress/touched-field-marker.controller.ts index ba3539767dcb..7c96bcd31913 100644 --- a/frontend/src/stimulus/controllers/dynamic/work-packages/progress/touched-field-marker.controller.ts +++ b/frontend/src/stimulus/controllers/dynamic/work-packages/progress/touched-field-marker.controller.ts @@ -32,18 +32,151 @@ import { Controller } from '@hotwired/stimulus'; export default class TouchedFieldMarkerController extends Controller { static targets = [ + 'initialValueInput', 'touchedFieldInput', 'progressInput', ]; + declare readonly initialValueInputTargets:HTMLInputElement[]; declare readonly touchedFieldInputTargets:HTMLInputElement[]; declare readonly progressInputTargets:HTMLInputElement[]; + private targetFieldName:string; + private markFieldAsTouched(event:{ target:HTMLInputElement }) { - this.touchedFieldInputTargets.forEach((input) => { - if (input.dataset.referrerField === event.target.name) { - input.value = 'true'; + this.targetFieldName = event.target.name.replace(/^work_package\[([^\]]+)\]$/, '$1'); + this.markTouched(this.targetFieldName); + + if (this.isWorkBasedMode()) { + this.keepWorkValue(); + } + } + + private isWorkBasedMode() { + return this.findValueInput('done_ratio') !== undefined; + } + + private keepWorkValue() { + if (this.isInitialValueEmpty('estimated_hours') && !this.isTouched('estimated_hours')) { + // let work be derived + return; + } + + if (this.isBeingEdited('estimated_hours')) { + this.untouchFieldsWhenWorkIsEdited(); + } else if (this.isBeingEdited('remaining_hours')) { + this.untouchFieldsWhenRemainingWorkIsEdited(); + } else if (this.isBeingEdited('done_ratio')) { + this.untouchFieldsWhenPercentCompleteIsEdited(); + } + } + + private untouchFieldsWhenWorkIsEdited() { + if (this.areBothTouched('remaining_hours', 'done_ratio')) { + if (this.isValueEmpty('done_ratio') && this.isValueEmpty('remaining_hours')) { + return; + } + if (this.isValueEmpty('done_ratio')) { + this.markUntouched('done_ratio'); + } else { + this.markUntouched('remaining_hours'); } - }); + } else if (this.isTouchedAndEmpty('remaining_hours') && this.isValueSet('done_ratio')) { + // force remaining work derivation + this.markUntouched('remaining_hours'); + this.markTouched('done_ratio'); + } else if (this.isTouchedAndEmpty('done_ratio') && this.isValueSet('remaining_hours')) { + // force % complete derivation + this.markUntouched('done_ratio'); + this.markTouched('remaining_hours'); + } + } + + private untouchFieldsWhenRemainingWorkIsEdited() { + if (this.isTouchedAndEmpty('estimated_hours') && this.isValueSet('done_ratio')) { + // force work derivation + this.markUntouched('estimated_hours'); + this.markTouched('done_ratio'); + } else if (this.isValueSet('estimated_hours')) { + this.markUntouched('done_ratio'); + } + } + + private untouchFieldsWhenPercentCompleteIsEdited() { + if (this.isValueSet('estimated_hours')) { + this.markUntouched('remaining_hours'); + } + } + + private areBothTouched(fieldName1:string, fieldName2:string) { + return this.isTouched(fieldName1) && this.isTouched(fieldName2); + } + + private isBeingEdited(fieldName:string) { + return fieldName === this.targetFieldName; + } + + // Finds the hidden initial value input based on a field name. + // + // The initial value input field holds the initial value of the work package + // before being set by the user or derived. + private findInitialValueInput(fieldName:string):HTMLInputElement|undefined { + return this.initialValueInputTargets.find((input) => + (input.dataset.referrerField === fieldName) || (input.dataset.referrerField === `work_package[${fieldName}]`)); + } + + // Finds the touched field input based on a field name. + // + // The touched input field is used to mark a field as touched by the user so + // that the backend keeps the value instead of deriving it. + private findTouchedInput(fieldName:string):HTMLInputElement|undefined { + return this.touchedFieldInputTargets.find((input) => + (input.dataset.referrerField === fieldName) || (input.dataset.referrerField === `work_package[${fieldName}]`)); + } + + // Finds the value field input based on a field name. + // + // The value field input holds the current value of a progress field. + private findValueInput(fieldName:string):HTMLInputElement|undefined { + return this.progressInputTargets.find((input) => + (input.name === fieldName) || (input.name === `work_package[${fieldName}]`)); + } + + private isTouchedAndEmpty(fieldName:string) { + return this.isTouched(fieldName) && this.isValueEmpty(fieldName); + } + + private isTouched(fieldName:string) { + const touchedInput = this.findTouchedInput(fieldName); + return touchedInput?.value === 'true'; + } + + private isInitialValueEmpty(fieldName:string) { + const valueInput = this.findInitialValueInput(fieldName); + return valueInput?.value === ''; + } + + private isValueEmpty(fieldName:string) { + const valueInput = this.findValueInput(fieldName); + return valueInput?.value === ''; + } + + private isValueSet(fieldName:string) { + const valueInput = this.findValueInput(fieldName); + return valueInput !== undefined && valueInput.value !== ''; + } + + private markTouched(fieldName:string) { + const touchedInput = this.findTouchedInput(fieldName); + if (touchedInput) { + touchedInput.value = 'true'; + } + } + + private markUntouched(fieldName:string) { + const touchedInput = this.findTouchedInput(fieldName); + if (touchedInput) { + touchedInput.value = 'false'; + } } } diff --git a/frontend/src/vendor/ckeditor/ckeditor.js b/frontend/src/vendor/ckeditor/ckeditor.js index c2ed49515518..1b228722d334 100644 --- a/frontend/src/vendor/ckeditor/ckeditor.js +++ b/frontend/src/vendor/ckeditor/ckeditor.js @@ -1,7 +1,7 @@ -!function(e){const t=e.en=e.en||{};t.dictionary=Object.assign(t.dictionary||{},{"(may require Fn)":"(may require Fn)","%0 of %1":"%0 of %1",Accept:"Accept",Accessibility:"Accessibility","Accessibility help":"Accessibility help","Align cell text to the bottom":"Align cell text to the bottom","Align cell text to the center":"Align cell text to the center","Align cell text to the left":"Align cell text to the left","Align cell text to the middle":"Align cell text to the middle","Align cell text to the right":"Align cell text to the right","Align cell text to the top":"Align cell text to the top","Align table to the left":"Align table to the left","Align table to the right":"Align table to the right",Alignment:"Alignment",Aquamarine:"Aquamarine",Background:"Background","Below, you can find a list of keyboard shortcuts that can be used in the editor.":"Below, you can find a list of keyboard shortcuts that can be used in the editor.",Black:"Black","Block quote":"Block quote",Blue:"Blue",Bold:"Bold","Bold text":"Bold text",Border:"Border","Break text":"Break text","Bulleted List":"Bulleted List","Bulleted list styles toolbar":"Bulleted list styles toolbar",Cancel:"Cancel","Cannot upload file:":"Cannot upload file:","Caption for image: %0":"Caption for image: %0","Caption for the image":"Caption for the image","Cell properties":"Cell properties","Center table":"Center table","Centered image":"Centered image","Change image text alternative":"Change image text alternative","Choose heading":"Choose heading",Circle:"Circle",Clear:"Clear","Click to edit block":"Click to edit block",Close:"Close","Close contextual balloons, dropdowns, and dialogs":"Close contextual balloons, dropdowns, and dialogs",Code:"Code",Color:"Color","Color picker":"Color picker",Column:"Column","Content editing keystrokes":"Content editing keystrokes","Copy selected content":"Copy selected content","Create link":"Create link",Custom:"Custom","Custom image size":"Custom image size",Dashed:"Dashed",Decimal:"Decimal","Decimal with leading zero":"Decimal with leading zero","Decrease list item indent":"Decrease list item indent","Delete column":"Delete column","Delete row":"Delete row","Dim grey":"Dim grey",Dimensions:"Dimensions",Disc:"Disc",Dotted:"Dotted",Double:"Double",Downloadable:"Downloadable","Drag to move":"Drag to move","Dropdown toolbar":"Dropdown toolbar","Edit block":"Edit block","Edit link":"Edit link","Editor block content toolbar":"Editor block content toolbar","Editor contextual toolbar":"Editor contextual toolbar","Editor dialog":"Editor dialog","Editor editing area: %0":"Editor editing area: %0","Editor menu bar":"Editor menu bar","Editor toolbar":"Editor toolbar","Enter image caption":"Enter image caption","Enter table caption":"Enter table caption","Entering a to-do list":"Entering a to-do list","Error during image upload":"Error during image upload","Execute the currently focused button. Executing buttons that interact with the editor content moves the focus back to the content.":"Execute the currently focused button. Executing buttons that interact with the editor content moves the focus back to the content.","From computer":"From computer","Full size image":"Full size image",Green:"Green",Grey:"Grey",Groove:"Groove","Header column":"Header column","Header row":"Header row",Heading:"Heading","Heading 1":"Heading 1","Heading 2":"Heading 2","Heading 3":"Heading 3","Heading 4":"Heading 4","Heading 5":"Heading 5","Heading 6":"Heading 6",Height:"Height","Help Contents. To close this dialog press ESC.":"Help Contents. To close this dialog press ESC.",HEX:"HEX","Horizontal text alignment toolbar":"Horizontal text alignment toolbar",Image:"Image","Image from computer":"Image from computer","Image resize list":"Image resize list","Image toolbar":"Image toolbar","Image upload complete":"Image upload complete","Image via URL":"Image via URL","image widget":"image widget","In line":"In line","Increase list item indent":"Increase list item indent","Insert a hard break (a new paragraph)":"Insert a hard break (a new paragraph)","Insert a new paragraph directly after a widget":"Insert a new paragraph directly after a widget","Insert a new paragraph directly before a widget":"Insert a new paragraph directly before a widget","Insert a new table row (when in the last cell of a table)":"Insert a new table row (when in the last cell of a table)","Insert a soft break (a <br> element)":"Insert a soft break (a <br> element)","Insert column left":"Insert column left","Insert column right":"Insert column right","Insert image":"Insert image","Insert image via URL":"Insert image via URL","Insert paragraph after block":"Insert paragraph after block","Insert paragraph before block":"Insert paragraph before block","Insert row above":"Insert row above","Insert row below":"Insert row below","Insert table":"Insert table","Insert via URL":"Insert via URL",Inset:"Inset","Invalid start index value.":"Invalid start index value.",Italic:"Italic","Italic text":"Italic text","Justify cell text":"Justify cell text","Keystrokes that can be used in a list":"Keystrokes that can be used in a list","Keystrokes that can be used in a table cell":"Keystrokes that can be used in a table cell","Keystrokes that can be used when a widget is selected (for example: image, table, etc.)":"Keystrokes that can be used when a widget is selected (for example: image, table, etc.)","Leaving a to-do list":"Leaving a to-do list","Left aligned image":"Left aligned image","Light blue":"Light blue","Light green":"Light green","Light grey":"Light grey",Link:"Link","Link image":"Link image","Link URL":"Link URL","Link URL must not be empty.":"Link URL must not be empty.","List properties":"List properties","Lower-latin":"Lower-latin","Lower–roman":"Lower–roman",MENU_BAR_MENU_EDIT:"Edit",MENU_BAR_MENU_FILE:"File",MENU_BAR_MENU_FONT:"Font",MENU_BAR_MENU_FORMAT:"Format",MENU_BAR_MENU_HELP:"Help",MENU_BAR_MENU_INSERT:"Insert",MENU_BAR_MENU_TEXT:"Text",MENU_BAR_MENU_TOOLS:"Tools",MENU_BAR_MENU_VIEW:"View","Merge cell down":"Merge cell down","Merge cell left":"Merge cell left","Merge cell right":"Merge cell right","Merge cell up":"Merge cell up","Merge cells":"Merge cells","Move focus between form fields (inputs, buttons, etc.)":"Move focus between form fields (inputs, buttons, etc.)","Move focus from an editable area back to the parent widget":"Move focus from an editable area back to the parent widget","Move focus in and out of an active dialog window":"Move focus in and out of an active dialog window","Move focus to the menu bar, navigate between menu bars":"Move focus to the menu bar, navigate between menu bars","Move focus to the toolbar, navigate between toolbars":"Move focus to the toolbar, navigate between toolbars","Move out of a link":"Move out of a link","Move out of an inline code style":"Move out of an inline code style","Move the caret to allow typing directly after a widget":"Move the caret to allow typing directly after a widget","Move the caret to allow typing directly before a widget":"Move the caret to allow typing directly before a widget","Move the selection to the next cell":"Move the selection to the next cell","Move the selection to the previous cell":"Move the selection to the previous cell","Navigate through the table":"Navigate through the table","Navigate through the toolbar or menu bar":"Navigate through the toolbar or menu bar",Next:"Next","No results found":"No results found","No searchable items":"No searchable items",None:"None","Numbered List":"Numbered List","Numbered list styles toolbar":"Numbered list styles toolbar","Open in a new tab":"Open in a new tab","Open link in new tab":"Open link in new tab","Open the accessibility help dialog":"Open the accessibility help dialog",Orange:"Orange",Original:"Original",Outset:"Outset",Padding:"Padding",Paragraph:"Paragraph","Paste content":"Paste content","Paste content as plain text":"Paste content as plain text",'Please enter a valid color (e.g. "ff0000").':'Please enter a valid color (e.g. "ff0000").',"Press %0 for help.":"Press %0 for help.","Press Enter to type after or press Shift + Enter to type before the widget":"Press Enter to type after or press Shift + Enter to type before the widget",Previous:"Previous",Purple:"Purple",Red:"Red",Redo:"Redo","Remove color":"Remove color","Replace from computer":"Replace from computer","Replace image":"Replace image","Replace image from computer":"Replace image from computer","Resize image":"Resize image","Resize image (in %0)":"Resize image (in %0)","Resize image to %0":"Resize image to %0","Resize image to the original size":"Resize image to the original size","Restore default":"Restore default","Reversed order":"Reversed order","Revert autoformatting action":"Revert autoformatting action","Rich Text Editor":"Rich Text Editor","Rich Text Editor. Editing area: %0":"Rich Text Editor. Editing area: %0",Ridge:"Ridge","Right aligned image":"Right aligned image",Row:"Row",Save:"Save","Select all":"Select all","Select column":"Select column","Select row":"Select row","Show more items":"Show more items","Side image":"Side image",Solid:"Solid","Split cell horizontally":"Split cell horizontally","Split cell vertically":"Split cell vertically",Square:"Square","Start at":"Start at","Start index must be greater than 0.":"Start index must be greater than 0.",Strikethrough:"Strikethrough","Strikethrough text":"Strikethrough text",Style:"Style",Subscript:"Subscript",Superscript:"Superscript",Table:"Table","Table alignment toolbar":"Table alignment toolbar","Table cell text alignment":"Table cell text alignment","Table properties":"Table properties","Table toolbar":"Table toolbar","Text alternative":"Text alternative",'The color is invalid. Try "#FF0000" or "rgb(255,0,0)" or "red".':'The color is invalid. Try "#FF0000" or "rgb(255,0,0)" or "red".','The value is invalid. Try "10px" or "2em" or simply "2".':'The value is invalid. Try "10px" or "2em" or simply "2".',"The value must not be empty.":"The value must not be empty.","The value should be a plain number.":"The value should be a plain number.","These keyboard shortcuts allow for quick access to content editing features.":"These keyboard shortcuts allow for quick access to content editing features.","This link has no URL":"This link has no URL","To-do List":"To-do List","Toggle caption off":"Toggle caption off","Toggle caption on":"Toggle caption on","Toggle the circle list style":"Toggle the circle list style","Toggle the decimal list style":"Toggle the decimal list style","Toggle the decimal with leading zero list style":"Toggle the decimal with leading zero list style","Toggle the disc list style":"Toggle the disc list style","Toggle the lower–latin list style":"Toggle the lower–latin list style","Toggle the lower–roman list style":"Toggle the lower–roman list style","Toggle the square list style":"Toggle the square list style","Toggle the upper–latin list style":"Toggle the upper–latin list style","Toggle the upper–roman list style":"Toggle the upper–roman list style",Turquoise:"Turquoise","Type or paste your content here.":"Type or paste your content here.","Type your title":"Type your title",Underline:"Underline","Underline text":"Underline text",Undo:"Undo",Unlink:"Unlink","Update image URL":"Update image URL","Upload failed":"Upload failed","Upload from computer":"Upload from computer","Upload image from computer":"Upload image from computer","Upload in progress":"Upload in progress","Uploading image":"Uploading image","Upper-latin":"Upper-latin","Upper-roman":"Upper-roman","Use the following keystrokes for more efficient navigation in the CKEditor 5 user interface.":"Use the following keystrokes for more efficient navigation in the CKEditor 5 user interface.","User interface and content navigation keystrokes":"User interface and content navigation keystrokes","Vertical text alignment toolbar":"Vertical text alignment toolbar","Via URL":"Via URL",White:"White","Widget toolbar":"Widget toolbar",Width:"Width","Wrap text":"Wrap text",Yellow:"Yellow","You have no image upload permissions.":"You have no image upload permissions."})}(window.CKEDITOR_TRANSLATIONS||(window.CKEDITOR_TRANSLATIONS={})), +!function(e){const t=e.en=e.en||{};t.dictionary=Object.assign(t.dictionary||{},{"(may require Fn)":"(may require Fn)","%0 of %1":"%0 of %1",Accept:"Accept",Accessibility:"Accessibility","Accessibility help":"Accessibility help","Align cell text to the bottom":"Align cell text to the bottom","Align cell text to the center":"Align cell text to the center","Align cell text to the left":"Align cell text to the left","Align cell text to the middle":"Align cell text to the middle","Align cell text to the right":"Align cell text to the right","Align cell text to the top":"Align cell text to the top","Align table to the left":"Align table to the left","Align table to the right":"Align table to the right",Alignment:"Alignment",Aquamarine:"Aquamarine",Background:"Background","Below, you can find a list of keyboard shortcuts that can be used in the editor.":"Below, you can find a list of keyboard shortcuts that can be used in the editor.",Black:"Black","Block quote":"Block quote",Blue:"Blue",Bold:"Bold","Bold text":"Bold text",Border:"Border","Break text":"Break text","Bulleted List":"Bulleted List","Bulleted list styles toolbar":"Bulleted list styles toolbar",Cancel:"Cancel","Cannot upload file:":"Cannot upload file:","Caption for image: %0":"Caption for image: %0","Caption for the image":"Caption for the image","Cell properties":"Cell properties","Center table":"Center table","Centered image":"Centered image","Change image text alternative":"Change image text alternative","Choose heading":"Choose heading",Circle:"Circle",Clear:"Clear","Click to edit block":"Click to edit block",Close:"Close","Close contextual balloons, dropdowns, and dialogs":"Close contextual balloons, dropdowns, and dialogs",Code:"Code",Color:"Color","Color picker":"Color picker",Column:"Column","Content editing keystrokes":"Content editing keystrokes","Copy selected content":"Copy selected content","Create link":"Create link",Custom:"Custom","Custom image size":"Custom image size",Dashed:"Dashed",Decimal:"Decimal","Decimal with leading zero":"Decimal with leading zero","Decrease list item indent":"Decrease list item indent","Delete column":"Delete column","Delete row":"Delete row","Dim grey":"Dim grey",Dimensions:"Dimensions",Disc:"Disc",Dotted:"Dotted",Double:"Double",Downloadable:"Downloadable","Drag to move":"Drag to move","Dropdown toolbar":"Dropdown toolbar","Edit block":"Edit block","Edit link":"Edit link","Editor block content toolbar":"Editor block content toolbar","Editor contextual toolbar":"Editor contextual toolbar","Editor dialog":"Editor dialog","Editor editing area: %0":"Editor editing area: %0","Editor menu bar":"Editor menu bar","Editor toolbar":"Editor toolbar","Enter image caption":"Enter image caption","Enter table caption":"Enter table caption","Entering a to-do list":"Entering a to-do list","Error during image upload":"Error during image upload","Execute the currently focused button. Executing buttons that interact with the editor content moves the focus back to the content.":"Execute the currently focused button. Executing buttons that interact with the editor content moves the focus back to the content.","From computer":"From computer","Full size image":"Full size image",Green:"Green",Grey:"Grey",Groove:"Groove","Header column":"Header column","Header row":"Header row",Heading:"Heading","Heading 1":"Heading 1","Heading 2":"Heading 2","Heading 3":"Heading 3","Heading 4":"Heading 4","Heading 5":"Heading 5","Heading 6":"Heading 6",Height:"Height","Help Contents. To close this dialog press ESC.":"Help Contents. To close this dialog press ESC.",HEX:"HEX","Horizontal text alignment toolbar":"Horizontal text alignment toolbar",Image:"Image","Image from computer":"Image from computer","Image resize list":"Image resize list","Image toolbar":"Image toolbar","Image upload complete":"Image upload complete","Image via URL":"Image via URL","image widget":"image widget","In line":"In line","Increase list item indent":"Increase list item indent","Insert a hard break (a new paragraph)":"Insert a hard break (a new paragraph)","Insert a new paragraph directly after a widget":"Insert a new paragraph directly after a widget","Insert a new paragraph directly before a widget":"Insert a new paragraph directly before a widget","Insert a new table row (when in the last cell of a table)":"Insert a new table row (when in the last cell of a table)","Insert a soft break (a <br> element)":"Insert a soft break (a <br> element)","Insert column left":"Insert column left","Insert column right":"Insert column right","Insert image":"Insert image","Insert image via URL":"Insert image via URL","Insert paragraph after block":"Insert paragraph after block","Insert paragraph before block":"Insert paragraph before block","Insert row above":"Insert row above","Insert row below":"Insert row below","Insert table":"Insert table","Insert via URL":"Insert via URL",Inset:"Inset","Invalid start index value.":"Invalid start index value.",Italic:"Italic","Italic text":"Italic text","Justify cell text":"Justify cell text","Keystrokes that can be used in a list":"Keystrokes that can be used in a list","Keystrokes that can be used in a table cell":"Keystrokes that can be used in a table cell","Keystrokes that can be used when a widget is selected (for example: image, table, etc.)":"Keystrokes that can be used when a widget is selected (for example: image, table, etc.)","Leaving a to-do list":"Leaving a to-do list","Left aligned image":"Left aligned image","Light blue":"Light blue","Light green":"Light green","Light grey":"Light grey",Link:"Link","Link image":"Link image","Link URL":"Link URL","Link URL must not be empty.":"Link URL must not be empty.","List properties":"List properties","Lower-latin":"Lower-latin","Lower–roman":"Lower–roman",MENU_BAR_MENU_EDIT:"Edit",MENU_BAR_MENU_FILE:"File",MENU_BAR_MENU_FONT:"Font",MENU_BAR_MENU_FORMAT:"Format",MENU_BAR_MENU_HELP:"Help",MENU_BAR_MENU_INSERT:"Insert",MENU_BAR_MENU_TEXT:"Text",MENU_BAR_MENU_TOOLS:"Tools",MENU_BAR_MENU_VIEW:"View","Merge cell down":"Merge cell down","Merge cell left":"Merge cell left","Merge cell right":"Merge cell right","Merge cell up":"Merge cell up","Merge cells":"Merge cells","Move focus between form fields (inputs, buttons, etc.)":"Move focus between form fields (inputs, buttons, etc.)","Move focus from an editable area back to the parent widget":"Move focus from an editable area back to the parent widget","Move focus in and out of an active dialog window":"Move focus in and out of an active dialog window","Move focus to the menu bar, navigate between menu bars":"Move focus to the menu bar, navigate between menu bars","Move focus to the toolbar, navigate between toolbars":"Move focus to the toolbar, navigate between toolbars","Move out of a link":"Move out of a link","Move out of an inline code style":"Move out of an inline code style","Move the caret to allow typing directly after a widget":"Move the caret to allow typing directly after a widget","Move the caret to allow typing directly before a widget":"Move the caret to allow typing directly before a widget","Move the selection to the next cell":"Move the selection to the next cell","Move the selection to the previous cell":"Move the selection to the previous cell","Navigate through the table":"Navigate through the table","Navigate through the toolbar or menu bar":"Navigate through the toolbar or menu bar",Next:"Next","No results found":"No results found","No searchable items":"No searchable items",None:"None","Numbered List":"Numbered List","Numbered list styles toolbar":"Numbered list styles toolbar","Open in a new tab":"Open in a new tab","Open link in new tab":"Open link in new tab","Open the accessibility help dialog":"Open the accessibility help dialog",Orange:"Orange",Original:"Original",Outset:"Outset",Padding:"Padding",Paragraph:"Paragraph","Paste content":"Paste content","Paste content as plain text":"Paste content as plain text",'Please enter a valid color (e.g. "ff0000").':'Please enter a valid color (e.g. "ff0000").',"Press %0 for help.":"Press %0 for help.","Press Enter to type after or press Shift + Enter to type before the widget":"Press Enter to type after or press Shift + Enter to type before the widget",Previous:"Previous",Purple:"Purple",Red:"Red",Redo:"Redo","Remove color":"Remove color","Replace from computer":"Replace from computer","Replace image":"Replace image","Replace image from computer":"Replace image from computer","Resize image":"Resize image","Resize image (in %0)":"Resize image (in %0)","Resize image to %0":"Resize image to %0","Resize image to the original size":"Resize image to the original size","Restore default":"Restore default","Reversed order":"Reversed order","Revert autoformatting action":"Revert autoformatting action","Rich Text Editor":"Rich Text Editor","Rich Text Editor. Editing area: %0":"Rich Text Editor. Editing area: %0",Ridge:"Ridge","Right aligned image":"Right aligned image",Row:"Row",Save:"Save","Saving changes":"Saving changes","Select all":"Select all","Select column":"Select column","Select row":"Select row","Show more items":"Show more items","Side image":"Side image",Solid:"Solid","Split cell horizontally":"Split cell horizontally","Split cell vertically":"Split cell vertically",Square:"Square","Start at":"Start at","Start index must be greater than 0.":"Start index must be greater than 0.",Strikethrough:"Strikethrough","Strikethrough text":"Strikethrough text",Style:"Style",Subscript:"Subscript",Superscript:"Superscript",Table:"Table","Table alignment toolbar":"Table alignment toolbar","Table cell text alignment":"Table cell text alignment","Table properties":"Table properties","Table toolbar":"Table toolbar","Text alternative":"Text alternative",'The color is invalid. Try "#FF0000" or "rgb(255,0,0)" or "red".':'The color is invalid. Try "#FF0000" or "rgb(255,0,0)" or "red".','The value is invalid. Try "10px" or "2em" or simply "2".':'The value is invalid. Try "10px" or "2em" or simply "2".',"The value must not be empty.":"The value must not be empty.","The value should be a plain number.":"The value should be a plain number.","These keyboard shortcuts allow for quick access to content editing features.":"These keyboard shortcuts allow for quick access to content editing features.","This link has no URL":"This link has no URL","To-do List":"To-do List","Toggle caption off":"Toggle caption off","Toggle caption on":"Toggle caption on","Toggle the circle list style":"Toggle the circle list style","Toggle the decimal list style":"Toggle the decimal list style","Toggle the decimal with leading zero list style":"Toggle the decimal with leading zero list style","Toggle the disc list style":"Toggle the disc list style","Toggle the lower–latin list style":"Toggle the lower–latin list style","Toggle the lower–roman list style":"Toggle the lower–roman list style","Toggle the square list style":"Toggle the square list style","Toggle the upper–latin list style":"Toggle the upper–latin list style","Toggle the upper–roman list style":"Toggle the upper–roman list style",Turquoise:"Turquoise","Type or paste your content here.":"Type or paste your content here.","Type your title":"Type your title",Underline:"Underline","Underline text":"Underline text",Undo:"Undo",Unlink:"Unlink","Update image URL":"Update image URL","Upload failed":"Upload failed","Upload from computer":"Upload from computer","Upload image from computer":"Upload image from computer","Upload in progress":"Upload in progress","Uploading image":"Uploading image","Upper-latin":"Upper-latin","Upper-roman":"Upper-roman","Use the following keystrokes for more efficient navigation in the CKEditor 5 user interface.":"Use the following keystrokes for more efficient navigation in the CKEditor 5 user interface.","User interface and content navigation keystrokes":"User interface and content navigation keystrokes","Vertical text alignment toolbar":"Vertical text alignment toolbar","Via URL":"Via URL",White:"White","Widget toolbar":"Widget toolbar",Width:"Width","Wrap text":"Wrap text",Yellow:"Yellow","You have no image upload permissions.":"You have no image upload permissions."})}(window.CKEDITOR_TRANSLATIONS||(window.CKEDITOR_TRANSLATIONS={})), /*! * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved. * For licensing, see LICENSE.md. */ -function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.OPEditor=t():e.OPEditor=t()}(self,(()=>(()=>{var e,t,o={5659:(e,t,o)=>{const n=o(8156),i={};for(const e of Object.keys(n))i[n[e]]=e;const r={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};e.exports=r;for(const e of Object.keys(r)){if(!("channels"in r[e]))throw new Error("missing channels property: "+e);if(!("labels"in r[e]))throw new Error("missing channel labels property: "+e);if(r[e].labels.length!==r[e].channels)throw new Error("channel and label counts mismatch: "+e);const{channels:t,labels:o}=r[e];delete r[e].channels,delete r[e].labels,Object.defineProperty(r[e],"channels",{value:t}),Object.defineProperty(r[e],"labels",{value:o})}r.rgb.hsl=function(e){const t=e[0]/255,o=e[1]/255,n=e[2]/255,i=Math.min(t,o,n),r=Math.max(t,o,n),s=r-i;let a,l;r===i?a=0:t===r?a=(o-n)/s:o===r?a=2+(n-t)/s:n===r&&(a=4+(t-o)/s),a=Math.min(60*a,360),a<0&&(a+=360);const c=(i+r)/2;return l=r===i?0:c<=.5?s/(r+i):s/(2-r-i),[a,100*l,100*c]},r.rgb.hsv=function(e){let t,o,n,i,r;const s=e[0]/255,a=e[1]/255,l=e[2]/255,c=Math.max(s,a,l),d=c-Math.min(s,a,l),u=function(e){return(c-e)/6/d+.5};return 0===d?(i=0,r=0):(r=d/c,t=u(s),o=u(a),n=u(l),s===c?i=n-o:a===c?i=1/3+t-n:l===c&&(i=2/3+o-t),i<0?i+=1:i>1&&(i-=1)),[360*i,100*r,100*c]},r.rgb.hwb=function(e){const t=e[0],o=e[1];let n=e[2];const i=r.rgb.hsl(e)[0],s=1/255*Math.min(t,Math.min(o,n));return n=1-1/255*Math.max(t,Math.max(o,n)),[i,100*s,100*n]},r.rgb.cmyk=function(e){const t=e[0]/255,o=e[1]/255,n=e[2]/255,i=Math.min(1-t,1-o,1-n);return[100*((1-t-i)/(1-i)||0),100*((1-o-i)/(1-i)||0),100*((1-n-i)/(1-i)||0),100*i]},r.rgb.keyword=function(e){const t=i[e];if(t)return t;let o,r=1/0;for(const t of Object.keys(n)){const i=n[t],l=(a=i,((s=e)[0]-a[0])**2+(s[1]-a[1])**2+(s[2]-a[2])**2);l.04045?((t+.055)/1.055)**2.4:t/12.92,o=o>.04045?((o+.055)/1.055)**2.4:o/12.92,n=n>.04045?((n+.055)/1.055)**2.4:n/12.92;return[100*(.4124*t+.3576*o+.1805*n),100*(.2126*t+.7152*o+.0722*n),100*(.0193*t+.1192*o+.9505*n)]},r.rgb.lab=function(e){const t=r.rgb.xyz(e);let o=t[0],n=t[1],i=t[2];o/=95.047,n/=100,i/=108.883,o=o>.008856?o**(1/3):7.787*o+16/116,n=n>.008856?n**(1/3):7.787*n+16/116,i=i>.008856?i**(1/3):7.787*i+16/116;return[116*n-16,500*(o-n),200*(n-i)]},r.hsl.rgb=function(e){const t=e[0]/360,o=e[1]/100,n=e[2]/100;let i,r,s;if(0===o)return s=255*n,[s,s,s];i=n<.5?n*(1+o):n+o-n*o;const a=2*n-i,l=[0,0,0];for(let e=0;e<3;e++)r=t+1/3*-(e-1),r<0&&r++,r>1&&r--,s=6*r<1?a+6*(i-a)*r:2*r<1?i:3*r<2?a+(i-a)*(2/3-r)*6:a,l[e]=255*s;return l},r.hsl.hsv=function(e){const t=e[0];let o=e[1]/100,n=e[2]/100,i=o;const r=Math.max(n,.01);n*=2,o*=n<=1?n:2-n,i*=r<=1?r:2-r;return[t,100*(0===n?2*i/(r+i):2*o/(n+o)),100*((n+o)/2)]},r.hsv.rgb=function(e){const t=e[0]/60,o=e[1]/100;let n=e[2]/100;const i=Math.floor(t)%6,r=t-Math.floor(t),s=255*n*(1-o),a=255*n*(1-o*r),l=255*n*(1-o*(1-r));switch(n*=255,i){case 0:return[n,l,s];case 1:return[a,n,s];case 2:return[s,n,l];case 3:return[s,a,n];case 4:return[l,s,n];case 5:return[n,s,a]}},r.hsv.hsl=function(e){const t=e[0],o=e[1]/100,n=e[2]/100,i=Math.max(n,.01);let r,s;s=(2-o)*n;const a=(2-o)*i;return r=o*i,r/=a<=1?a:2-a,r=r||0,s/=2,[t,100*r,100*s]},r.hwb.rgb=function(e){const t=e[0]/360;let o=e[1]/100,n=e[2]/100;const i=o+n;let r;i>1&&(o/=i,n/=i);const s=Math.floor(6*t),a=1-n;r=6*t-s,0!=(1&s)&&(r=1-r);const l=o+r*(a-o);let c,d,u;switch(s){default:case 6:case 0:c=a,d=l,u=o;break;case 1:c=l,d=a,u=o;break;case 2:c=o,d=a,u=l;break;case 3:c=o,d=l,u=a;break;case 4:c=l,d=o,u=a;break;case 5:c=a,d=o,u=l}return[255*c,255*d,255*u]},r.cmyk.rgb=function(e){const t=e[0]/100,o=e[1]/100,n=e[2]/100,i=e[3]/100;return[255*(1-Math.min(1,t*(1-i)+i)),255*(1-Math.min(1,o*(1-i)+i)),255*(1-Math.min(1,n*(1-i)+i))]},r.xyz.rgb=function(e){const t=e[0]/100,o=e[1]/100,n=e[2]/100;let i,r,s;return i=3.2406*t+-1.5372*o+-.4986*n,r=-.9689*t+1.8758*o+.0415*n,s=.0557*t+-.204*o+1.057*n,i=i>.0031308?1.055*i**(1/2.4)-.055:12.92*i,r=r>.0031308?1.055*r**(1/2.4)-.055:12.92*r,s=s>.0031308?1.055*s**(1/2.4)-.055:12.92*s,i=Math.min(Math.max(0,i),1),r=Math.min(Math.max(0,r),1),s=Math.min(Math.max(0,s),1),[255*i,255*r,255*s]},r.xyz.lab=function(e){let t=e[0],o=e[1],n=e[2];t/=95.047,o/=100,n/=108.883,t=t>.008856?t**(1/3):7.787*t+16/116,o=o>.008856?o**(1/3):7.787*o+16/116,n=n>.008856?n**(1/3):7.787*n+16/116;return[116*o-16,500*(t-o),200*(o-n)]},r.lab.xyz=function(e){let t,o,n;o=(e[0]+16)/116,t=e[1]/500+o,n=o-e[2]/200;const i=o**3,r=t**3,s=n**3;return o=i>.008856?i:(o-16/116)/7.787,t=r>.008856?r:(t-16/116)/7.787,n=s>.008856?s:(n-16/116)/7.787,t*=95.047,o*=100,n*=108.883,[t,o,n]},r.lab.lch=function(e){const t=e[0],o=e[1],n=e[2];let i;i=360*Math.atan2(n,o)/2/Math.PI,i<0&&(i+=360);return[t,Math.sqrt(o*o+n*n),i]},r.lch.lab=function(e){const t=e[0],o=e[1],n=e[2]/360*2*Math.PI;return[t,o*Math.cos(n),o*Math.sin(n)]},r.rgb.ansi16=function(e,t=null){const[o,n,i]=e;let s=null===t?r.rgb.hsv(e)[2]:t;if(s=Math.round(s/50),0===s)return 30;let a=30+(Math.round(i/255)<<2|Math.round(n/255)<<1|Math.round(o/255));return 2===s&&(a+=60),a},r.hsv.ansi16=function(e){return r.rgb.ansi16(r.hsv.rgb(e),e[2])},r.rgb.ansi256=function(e){const t=e[0],o=e[1],n=e[2];if(t===o&&o===n)return t<8?16:t>248?231:Math.round((t-8)/247*24)+232;return 16+36*Math.round(t/255*5)+6*Math.round(o/255*5)+Math.round(n/255*5)},r.ansi16.rgb=function(e){let t=e%10;if(0===t||7===t)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];const o=.5*(1+~~(e>50));return[(1&t)*o*255,(t>>1&1)*o*255,(t>>2&1)*o*255]},r.ansi256.rgb=function(e){if(e>=232){const t=10*(e-232)+8;return[t,t,t]}let t;e-=16;return[Math.floor(e/36)/5*255,Math.floor((t=e%36)/6)/5*255,t%6/5*255]},r.rgb.hex=function(e){const t=(((255&Math.round(e[0]))<<16)+((255&Math.round(e[1]))<<8)+(255&Math.round(e[2]))).toString(16).toUpperCase();return"000000".substring(t.length)+t},r.hex.rgb=function(e){const t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];let o=t[0];3===t[0].length&&(o=o.split("").map((e=>e+e)).join(""));const n=parseInt(o,16);return[n>>16&255,n>>8&255,255&n]},r.rgb.hcg=function(e){const t=e[0]/255,o=e[1]/255,n=e[2]/255,i=Math.max(Math.max(t,o),n),r=Math.min(Math.min(t,o),n),s=i-r;let a,l;return a=s<1?r/(1-s):0,l=s<=0?0:i===t?(o-n)/s%6:i===o?2+(n-t)/s:4+(t-o)/s,l/=6,l%=1,[360*l,100*s,100*a]},r.hsl.hcg=function(e){const t=e[1]/100,o=e[2]/100,n=o<.5?2*t*o:2*t*(1-o);let i=0;return n<1&&(i=(o-.5*n)/(1-n)),[e[0],100*n,100*i]},r.hsv.hcg=function(e){const t=e[1]/100,o=e[2]/100,n=t*o;let i=0;return n<1&&(i=(o-n)/(1-n)),[e[0],100*n,100*i]},r.hcg.rgb=function(e){const t=e[0]/360,o=e[1]/100,n=e[2]/100;if(0===o)return[255*n,255*n,255*n];const i=[0,0,0],r=t%1*6,s=r%1,a=1-s;let l=0;switch(Math.floor(r)){case 0:i[0]=1,i[1]=s,i[2]=0;break;case 1:i[0]=a,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=s;break;case 3:i[0]=0,i[1]=a,i[2]=1;break;case 4:i[0]=s,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=a}return l=(1-o)*n,[255*(o*i[0]+l),255*(o*i[1]+l),255*(o*i[2]+l)]},r.hcg.hsv=function(e){const t=e[1]/100,o=t+e[2]/100*(1-t);let n=0;return o>0&&(n=t/o),[e[0],100*n,100*o]},r.hcg.hsl=function(e){const t=e[1]/100,o=e[2]/100*(1-t)+.5*t;let n=0;return o>0&&o<.5?n=t/(2*o):o>=.5&&o<1&&(n=t/(2*(1-o))),[e[0],100*n,100*o]},r.hcg.hwb=function(e){const t=e[1]/100,o=t+e[2]/100*(1-t);return[e[0],100*(o-t),100*(1-o)]},r.hwb.hcg=function(e){const t=e[1]/100,o=1-e[2]/100,n=o-t;let i=0;return n<1&&(i=(o-n)/(1-n)),[e[0],100*n,100*i]},r.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},r.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},r.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},r.gray.hsl=function(e){return[0,0,e[0]]},r.gray.hsv=r.gray.hsl,r.gray.hwb=function(e){return[0,100,e[0]]},r.gray.cmyk=function(e){return[0,0,0,e[0]]},r.gray.lab=function(e){return[e[0],0,0]},r.gray.hex=function(e){const t=255&Math.round(e[0]/100*255),o=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(o.length)+o},r.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]}},734:(e,t,o)=>{const n=o(5659),i=o(8507),r={};Object.keys(n).forEach((e=>{r[e]={},Object.defineProperty(r[e],"channels",{value:n[e].channels}),Object.defineProperty(r[e],"labels",{value:n[e].labels});const t=i(e);Object.keys(t).forEach((o=>{const n=t[o];r[e][o]=function(e){const t=function(...t){const o=t[0];if(null==o)return o;o.length>1&&(t=o);const n=e(t);if("object"==typeof n)for(let e=n.length,t=0;t1&&(t=o),e(t))};return"conversion"in e&&(t.conversion=e.conversion),t}(n)}))})),e.exports=r},8507:(e,t,o)=>{const n=o(5659);function i(e){const t=function(){const e={},t=Object.keys(n);for(let o=t.length,n=0;n{"use strict";e.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},9248:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck-content code{background-color:hsla(0,0%,78%,.3);border-radius:2px;padding:.15em}.ck.ck-editor__editable .ck-code_selected{background-color:hsla(0,0%,78%,.5)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-basic-styles/theme/code.css"],names:[],mappings:"AAKA,iBACC,kCAAuC,CAEvC,iBAAkB,CADlB,aAED,CAEA,0CACC,kCACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck-content code {\n\tbackground-color: hsla(0, 0%, 78%, 0.3);\n\tpadding: .15em;\n\tborder-radius: 2px;\n}\n\n.ck.ck-editor__editable .ck-code_selected {\n\tbackground-color: hsla(0, 0%, 78%, 0.5);\n}\n"],sourceRoot:""}]);const a=s},1501:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck-content blockquote{border-left:5px solid #ccc;font-style:italic;margin-left:0;margin-right:0;overflow:hidden;padding-left:1.5em;padding-right:1.5em}.ck-content[dir=rtl] blockquote{border-left:0;border-right:5px solid #ccc}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-block-quote/theme/blockquote.css"],names:[],mappings:"AAKA,uBAWC,0BAAsC,CADtC,iBAAkB,CAFlB,aAAc,CACd,cAAe,CAPf,eAAgB,CAIhB,kBAAmB,CADnB,mBAOD,CAEA,gCACC,aAAc,CACd,2BACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck-content blockquote {\n\t/* See #12 */\n\toverflow: hidden;\n\n\t/* https://github.com/ckeditor/ckeditor5-block-quote/issues/15 */\n\tpadding-right: 1.5em;\n\tpadding-left: 1.5em;\n\n\tmargin-left: 0;\n\tmargin-right: 0;\n\tfont-style: italic;\n\tborder-left: solid 5px hsl(0, 0%, 80%);\n}\n\n.ck-content[dir="rtl"] blockquote {\n\tborder-left: 0;\n\tborder-right: solid 5px hsl(0, 0%, 80%);\n}\n'],sourceRoot:""}]);const a=s},9262:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,'.ck.ck-editor__editable .ck.ck-clipboard-drop-target-position{display:inline;pointer-events:none;position:relative}.ck.ck-editor__editable .ck.ck-clipboard-drop-target-position span{position:absolute;width:0}.ck.ck-editor__editable .ck-widget:-webkit-drag>.ck-widget__selection-handle,.ck.ck-editor__editable .ck-widget:-webkit-drag>.ck-widget__type-around{display:none}.ck.ck-clipboard-drop-target-line{pointer-events:none;position:absolute}:root{--ck-clipboard-drop-target-dot-width:12px;--ck-clipboard-drop-target-dot-height:8px;--ck-clipboard-drop-target-color:var(--ck-color-focus-border)}.ck.ck-editor__editable .ck.ck-clipboard-drop-target-position span{background:var(--ck-clipboard-drop-target-color);border:1px solid var(--ck-clipboard-drop-target-color);bottom:calc(var(--ck-clipboard-drop-target-dot-height)*-.5);margin-left:-1px;top:calc(var(--ck-clipboard-drop-target-dot-height)*-.5)}.ck.ck-editor__editable .ck.ck-clipboard-drop-target-position span:after{border-color:var(--ck-clipboard-drop-target-color) transparent transparent transparent;border-style:solid;border-width:calc(var(--ck-clipboard-drop-target-dot-height)) calc(var(--ck-clipboard-drop-target-dot-width)*.5) 0 calc(var(--ck-clipboard-drop-target-dot-width)*.5);content:"";display:block;height:0;left:50%;position:absolute;top:calc(var(--ck-clipboard-drop-target-dot-height)*-.5);transform:translateX(-50%);width:0}.ck.ck-editor__editable .ck-widget.ck-clipboard-drop-target-range{outline:var(--ck-widget-outline-thickness) solid var(--ck-clipboard-drop-target-color)!important}.ck.ck-editor__editable .ck-widget:-webkit-drag{zoom:.6;outline:none!important}.ck.ck-clipboard-drop-target-line{background:var(--ck-clipboard-drop-target-color);border:1px solid var(--ck-clipboard-drop-target-color);height:0;margin-top:-1px}.ck.ck-clipboard-drop-target-line:before{border-style:solid;content:"";height:0;position:absolute;top:calc(var(--ck-clipboard-drop-target-dot-width)*-.5);width:0}[dir=ltr] .ck.ck-clipboard-drop-target-line:before{border-color:transparent transparent transparent var(--ck-clipboard-drop-target-color);border-width:calc(var(--ck-clipboard-drop-target-dot-width)*.5) 0 calc(var(--ck-clipboard-drop-target-dot-width)*.5) var(--ck-clipboard-drop-target-dot-height);left:-1px}[dir=rtl] .ck.ck-clipboard-drop-target-line:before{border-color:transparent var(--ck-clipboard-drop-target-color) transparent transparent;border-width:calc(var(--ck-clipboard-drop-target-dot-width)*.5) var(--ck-clipboard-drop-target-dot-height) calc(var(--ck-clipboard-drop-target-dot-width)*.5) 0;right:-1px}',"",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-clipboard/theme/clipboard.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-clipboard/clipboard.css"],names:[],mappings:"AASC,8DACC,cAAe,CAEf,mBAAoB,CADpB,iBAOD,CAJC,mEACC,iBAAkB,CAClB,OACD,CAWA,qJACC,YACD,CAIF,kCAEC,mBAAoB,CADpB,iBAED,CC9BA,MACC,yCAA0C,CAC1C,yCAA0C,CAC1C,6DACD,CAOE,mEAIC,gDAAiD,CADjD,sDAAuD,CAFvD,2DAA8D,CAI9D,gBAAiB,CAHjB,wDAqBD,CAfC,yEAWC,sFAAuF,CAEvF,kBAAmB,CADnB,qKAA0K,CAX1K,UAAW,CAIX,aAAc,CAFd,QAAS,CAIT,QAAS,CADT,iBAAkB,CAElB,wDAA2D,CAE3D,0BAA2B,CAR3B,OAYD,CAOF,kEACC,gGACD,CAKA,gDACC,OAAS,CACT,sBACD,CAGD,kCAGC,gDAAiD,CADjD,sDAAuD,CADvD,QAAS,CAGT,eAwBD,CAtBC,yCAMC,kBAAmB,CALnB,UAAW,CAIX,QAAS,CAHT,iBAAkB,CAClB,uDAA0D,CAC1D,OAiBD,CArBA,mDAYE,sFAAuF,CADvF,+JAAoK,CAFpK,SAYF,CArBA,mDAmBE,sFAAuF,CADvF,+JAAmK,CAFnK,UAKF",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-editor__editable {\n\t/*\n\t * Vertical drop target (in text).\n\t */\n\t& .ck.ck-clipboard-drop-target-position {\n\t\tdisplay: inline;\n\t\tposition: relative;\n\t\tpointer-events: none;\n\n\t\t& span {\n\t\t\tposition: absolute;\n\t\t\twidth: 0;\n\t\t}\n\t}\n\n\t/*\n\t * Styles of the widget being dragged (its preview).\n\t */\n\t& .ck-widget:-webkit-drag {\n\t\t& > .ck-widget__selection-handle {\n\t\t\tdisplay: none;\n\t\t}\n\n\t\t& > .ck-widget__type-around {\n\t\t\tdisplay: none;\n\t\t}\n\t}\n}\n\n.ck.ck-clipboard-drop-target-line {\n\tposition: absolute;\n\tpointer-events: none;\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import \"@ckeditor/ckeditor5-ui/theme/mixins/_dir.css\";\n\n:root {\n\t--ck-clipboard-drop-target-dot-width: 12px;\n\t--ck-clipboard-drop-target-dot-height: 8px;\n\t--ck-clipboard-drop-target-color: var(--ck-color-focus-border);\n}\n\n.ck.ck-editor__editable {\n\t/*\n\t * Vertical drop target (in text).\n\t */\n\t& .ck.ck-clipboard-drop-target-position {\n\t\t& span {\n\t\t\tbottom: calc(-.5 * var(--ck-clipboard-drop-target-dot-height));\n\t\t\ttop: calc(-.5 * var(--ck-clipboard-drop-target-dot-height));\n\t\t\tborder: 1px solid var(--ck-clipboard-drop-target-color);\n\t\t\tbackground: var(--ck-clipboard-drop-target-color);\n\t\t\tmargin-left: -1px;\n\n\t\t\t/* The triangle above the marker */\n\t\t\t&::after {\n\t\t\t\tcontent: '';\n\t\t\t\twidth: 0;\n\t\t\t\theight: 0;\n\n\t\t\t\tdisplay: block;\n\t\t\t\tposition: absolute;\n\t\t\t\tleft: 50%;\n\t\t\t\ttop: calc(-.5 * var(--ck-clipboard-drop-target-dot-height));\n\n\t\t\t\ttransform: translateX(-50%);\n\t\t\t\tborder-color: var(--ck-clipboard-drop-target-color) transparent transparent transparent;\n\t\t\t\tborder-width: calc(var(--ck-clipboard-drop-target-dot-height)) calc(.5 * var(--ck-clipboard-drop-target-dot-width)) 0 calc(.5 * var(--ck-clipboard-drop-target-dot-width));\n\t\t\t\tborder-style: solid;\n\t\t\t}\n\t\t}\n\t}\n\n\t/*\n\t * Styles of the widget that it a drop target.\n\t */\n\t& .ck-widget.ck-clipboard-drop-target-range {\n\t\toutline: var(--ck-widget-outline-thickness) solid var(--ck-clipboard-drop-target-color) !important;\n\t}\n\n\t/*\n\t * Styles of the widget being dragged (its preview).\n\t */\n\t& .ck-widget:-webkit-drag {\n\t\tzoom: 0.6;\n\t\toutline: none !important;\n\t}\n}\n\n.ck.ck-clipboard-drop-target-line {\n\theight: 0;\n\tborder: 1px solid var(--ck-clipboard-drop-target-color);\n\tbackground: var(--ck-clipboard-drop-target-color);\n\tmargin-top: -1px;\n\n\t&::before {\n\t\tcontent: '';\n\t\tposition: absolute;\n\t\ttop: calc(-.5 * var(--ck-clipboard-drop-target-dot-width));\n\t\twidth: 0;\n\t\theight: 0;\n\t\tborder-style: solid;\n\n\t\t@mixin ck-dir ltr {\n\t\t\tleft: -1px;\n\n\t\t\tborder-width: calc(.5 * var(--ck-clipboard-drop-target-dot-width)) 0 calc(.5 * var(--ck-clipboard-drop-target-dot-width)) var(--ck-clipboard-drop-target-dot-height);\n\t\t\tborder-color: transparent transparent transparent var(--ck-clipboard-drop-target-color);\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\tright: -1px;\n\n\t\t\tborder-width:calc(.5 * var(--ck-clipboard-drop-target-dot-width)) var(--ck-clipboard-drop-target-dot-height) calc(.5 * var(--ck-clipboard-drop-target-dot-width)) 0;\n\t\t\tborder-color: transparent var(--ck-clipboard-drop-target-color) transparent transparent;\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},1111:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck .ck-placeholder,.ck.ck-placeholder{position:relative}.ck .ck-placeholder:before,.ck.ck-placeholder:before{content:attr(data-placeholder);left:0;pointer-events:none;position:absolute;right:0}.ck.ck-read-only .ck-placeholder:before{display:none}.ck.ck-reset_all .ck-placeholder{position:relative}@media (forced-colors:active){.ck .ck-placeholder,.ck.ck-placeholder{forced-color-adjust:preserve-parent-color}}.ck .ck-placeholder:before,.ck.ck-placeholder:before{cursor:text}@media (forced-colors:none){.ck .ck-placeholder:before,.ck.ck-placeholder:before{color:var(--ck-color-engine-placeholder-text)}}@media (forced-colors:active){.ck .ck-placeholder:before,.ck.ck-placeholder:before{font-style:italic;margin-left:1px}}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-engine/theme/placeholder.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_mediacolors.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-engine/placeholder.css"],names:[],mappings:"AAMA,uCAEC,iBAWD,CATC,qDAIC,8BAA+B,CAF/B,MAAO,CAKP,mBAAoB,CANpB,iBAAkB,CAElB,OAKD,CAKA,wCACC,YACD,CAQD,iCACC,iBACD,CC7BC,8BACC,uCCOA,yCDLA,CACD,CCOA,qDACC,WAmBD,CDvBA,4BACC,qDCMC,6CDJD,CACD,CAZA,8BACC,qDCsBC,iBAAkB,CAMlB,eD1BD,CACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/* See ckeditor/ckeditor5#936. */\n.ck.ck-placeholder,\n.ck .ck-placeholder {\n\tposition: relative;\n\n\t&::before {\n\t\tposition: absolute;\n\t\tleft: 0;\n\t\tright: 0;\n\t\tcontent: attr(data-placeholder);\n\n\t\t/* See ckeditor/ckeditor5#469. */\n\t\tpointer-events: none;\n\t}\n}\n\n/* See ckeditor/ckeditor5#1987. */\n.ck.ck-read-only .ck-placeholder {\n\t&::before {\n\t\tdisplay: none;\n\t}\n}\n\n/*\n * Rules for the `ck-placeholder` are loaded before the rules for `ck-reset_all` in the base CKEditor 5 DLL build.\n * This fix overwrites the incorrectly set `position: static` from `ck-reset_all`.\n * See https://github.com/ckeditor/ckeditor5/issues/11418.\n */\n.ck.ck-reset_all .ck-placeholder {\n\tposition: relative;\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@define-mixin ck-media-forced-colors {\n\t@media (forced-colors: active) {\n\t\t& {\n\t\t\t@mixin-content;\n\t\t}\n\t}\n}\n\n@define-mixin ck-media-default-colors {\n\t@media (forced-colors: none) {\n\t\t& {\n\t\t\t@mixin-content;\n\t\t}\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_mediacolors.css";\n\n/* See ckeditor/ckeditor5#936. */\n.ck.ck-placeholder, .ck .ck-placeholder {\n\t@mixin ck-media-forced-colors {\n\t\t/*\n\t\t * This is needed for Edge on Windows to use the right color for the placeholder content (::before).\n\t\t * See https://github.com/ckeditor/ckeditor5/issues/14907.\n\t\t */\n\t\tforced-color-adjust: preserve-parent-color;\n\t}\n\n\t&::before {\n\t\tcursor: text;\n\n\t\t@mixin ck-media-default-colors {\n\t\t\tcolor: var(--ck-color-engine-placeholder-text);\n\t\t}\n\n\t\t@mixin ck-media-forced-colors {\n\t\t\t/*\n\t\t\t * In the high contrast mode there is no telling between regular and placeholder text. Using\n\t\t\t * italic text to address that issue. See https://github.com/ckeditor/ckeditor5/issues/14907.\n\t\t\t */\n\t\t\tfont-style: italic;\n\n\t\t\t/*\n\t\t\t * Without this margin, the caret will not show up and blink when the user puts the selection\n\t\t\t * in the placeholder (Edge on Windows). See https://github.com/ckeditor/ckeditor5/issues/14907.\n\t\t\t */\n\t\t\tmargin-left: 1px;\n\t\t}\n\t}\n}\n'],sourceRoot:""}]);const a=s},6531:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-editor__editable span[data-ck-unsafe-element]{display:none}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-engine/theme/renderer.css"],names:[],mappings:"AAMA,qDACC,YACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/* Elements marked by the Renderer as hidden should be invisible in the editor. */\n.ck.ck-editor__editable span[data-ck-unsafe-element] {\n\tdisplay: none;\n}\n"],sourceRoot:""}]);const a=s},6186:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-heading_heading1 .ck-button__label{font-size:20px}.ck.ck-heading_heading2 .ck-button__label{font-size:17px}.ck.ck-heading_heading3 .ck-button__label{font-size:14px}.ck[class*=ck-heading_heading]{font-weight:700}.ck.ck-dropdown.ck-heading-dropdown .ck-dropdown__button .ck-button__label{width:8em}.ck.ck-dropdown.ck-heading-dropdown .ck-dropdown__panel .ck-list__item{min-width:18em}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-heading/theme/heading.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-heading/heading.css"],names:[],mappings:"AAKA,0CACC,cACD,CAEA,0CACC,cACD,CAEA,0CACC,cACD,CAEA,+BACC,eACD,CCZC,2EACC,SACD,CAEA,uEACC,cACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-heading_heading1 .ck-button__label {\n\tfont-size: 20px;\n}\n\n.ck.ck-heading_heading2 .ck-button__label {\n\tfont-size: 17px;\n}\n\n.ck.ck-heading_heading3 .ck-button__label {\n\tfont-size: 14px;\n}\n\n.ck[class*="ck-heading_heading"] {\n\tfont-weight: bold;\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/* Resize dropdown's button label. */\n.ck.ck-dropdown.ck-heading-dropdown {\n\t& .ck-dropdown__button .ck-button__label {\n\t\twidth: 8em;\n\t}\n\n\t& .ck-dropdown__panel .ck-list__item {\n\t\tmin-width: 18em;\n\t}\n}\n"],sourceRoot:""}]);const a=s},8574:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck-content .image{clear:both;display:table;margin:.9em auto;min-width:50px;text-align:center}.ck-content .image img{display:block;height:auto;margin:0 auto;max-width:100%;min-width:100%}.ck-content .image-inline{align-items:flex-start;display:inline-flex;max-width:100%}.ck-content .image-inline picture{display:flex}.ck-content .image-inline img,.ck-content .image-inline picture{flex-grow:1;flex-shrink:1;max-width:100%}.ck.ck-editor__editable .image>figcaption.ck-placeholder:before{overflow:hidden;padding-left:inherit;padding-right:inherit;text-overflow:ellipsis;white-space:nowrap}.ck.ck-editor__editable .image{z-index:1}.ck.ck-editor__editable .image.ck-widget_selected{z-index:2}.ck.ck-editor__editable .image-inline{z-index:1}.ck.ck-editor__editable .image-inline.ck-widget_selected{z-index:2}.ck.ck-editor__editable .image-inline.ck-widget_selected ::selection{display:none}.ck.ck-editor__editable .image-inline img{height:auto}.ck.ck-editor__editable td .image-inline img,.ck.ck-editor__editable th .image-inline img{max-width:none}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-image/theme/image.css"],names:[],mappings:"AAMC,mBAEC,UAAW,CADX,aAAc,CAOd,gBAAkB,CAGlB,cAAe,CARf,iBA2BD,CAjBC,uBAEC,aAAc,CAad,WAAY,CAVZ,aAAc,CAGd,cAAe,CAGf,cAKD,CAGD,0BAYC,sBAAuB,CANvB,mBAAoB,CAGpB,cAoBD,CAdC,kCACC,YACD,CAGA,gEAGC,WAAY,CACZ,aAAc,CAGd,cACD,CAUD,gEASC,eAAgB,CARhB,oBAAqB,CACrB,qBAAsB,CAQtB,sBAAuB,CAFvB,kBAGD,CAKA,+BACC,SASD,CAHC,kDACC,SACD,CAMD,sCACC,SAkBD,CAZC,yDACC,SAUD,CAHC,qEACC,YACD,CAMF,0CACC,WACD,CAMC,0FACC,cACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck-content {\n\t& .image {\n\t\tdisplay: table;\n\t\tclear: both;\n\t\ttext-align: center;\n\n\t\t/* Make sure there is some space between the content and the image. Center image by default. */\n\t\t/* The first value should be equal to --ck-spacing-large variable if used in the editor context\n\t \tto avoid the content jumping (See https://github.com/ckeditor/ckeditor5/issues/9825). */\n\t\tmargin: 0.9em auto;\n\n\t\t/* Make sure the caption will be displayed properly (See: https://github.com/ckeditor/ckeditor5/issues/1870). */\n\t\tmin-width: 50px;\n\n\t\t& img {\n\t\t\t/* Prevent unnecessary margins caused by line-height (see #44). */\n\t\t\tdisplay: block;\n\n\t\t\t/* Center the image if its width is smaller than the content\'s width. */\n\t\t\tmargin: 0 auto;\n\n\t\t\t/* Make sure the image never exceeds the size of the parent container (ckeditor/ckeditor5-ui#67). */\n\t\t\tmax-width: 100%;\n\n\t\t\t/* Make sure the image is never smaller than the parent container (See: https://github.com/ckeditor/ckeditor5/issues/9300). */\n\t\t\tmin-width: 100%;\n\n\t\t\t/* Keep proportions of the block image if the height is set and the image is wider than the editor width.\n\t\t\tSee https://github.com/ckeditor/ckeditor5/issues/14542. */\n\t\t\theight: auto;\n\t\t}\n\t}\n\n\t& .image-inline {\n\t\t/*\n\t\t * Normally, the .image-inline would have "display: inline-block" and "img { width: 100% }" (to follow the wrapper while resizing).\n\t\t * Unfortunately, together with "srcset", it gets automatically stretched up to the width of the editing root.\n\t\t * This strange behavior does not happen with inline-flex.\n\t\t */\n\t\tdisplay: inline-flex;\n\n\t\t/* While being resized, don\'t allow the image to exceed the width of the editing root. */\n\t\tmax-width: 100%;\n\n\t\t/* This is required by Safari to resize images in a sensible way. Without this, the browser breaks the ratio. */\n\t\talign-items: flex-start;\n\n\t\t/* When the picture is present it must act as a flex container to let the img resize properly */\n\t\t& picture {\n\t\t\tdisplay: flex;\n\t\t}\n\n\t\t/* When the picture is present, it must act like a resizable img. */\n\t\t& picture,\n\t\t& img {\n\t\t\t/* This is necessary for the img to span the entire .image-inline wrapper and to resize properly. */\n\t\t\tflex-grow: 1;\n\t\t\tflex-shrink: 1;\n\n\t\t\t/* Prevents overflowing the editing root boundaries when an inline image is very wide. */\n\t\t\tmax-width: 100%;\n\t\t}\n\t}\n}\n\n.ck.ck-editor__editable {\n\t/*\n\t * Inhertit the content styles padding of the
    in case the integration overrides `text-align: center`\n\t * of `.image` (e.g. to the left/right). This ensures the placeholder stays at the padding just like the native\n\t * caret does, and not at the edge of
    .\n\t */\n\t& .image > figcaption.ck-placeholder::before {\n\t\tpadding-left: inherit;\n\t\tpadding-right: inherit;\n\n\t\t/*\n\t\t * Make sure the image caption placeholder doesn\'t overflow the placeholder area.\n\t\t * See https://github.com/ckeditor/ckeditor5/issues/9162.\n\t\t */\n\t\twhite-space: nowrap;\n\t\toverflow: hidden;\n\t\ttext-overflow: ellipsis;\n\t}\n\n\t/*\n\t * See https://github.com/ckeditor/ckeditor5/issues/15115.\n\t */\n\t& .image {\n\t\tz-index: 1;\n\n\t\t/*\n\t\t * Make sure the selected image always stays on top of its siblings.\n\t\t * See https://github.com/ckeditor/ckeditor5/issues/9108.\n\t\t */\n\t\t&.ck-widget_selected {\n\t\t\tz-index: 2;\n\t\t}\n\t}\n\n\t/*\n\t * See https://github.com/ckeditor/ckeditor5/issues/15115.\n\t */\n\t& .image-inline {\n\t\tz-index: 1;\n\n\t\t/*\n\t\t * Make sure the selected inline image always stays on top of its siblings.\n\t\t * See https://github.com/ckeditor/ckeditor5/issues/9108.\n\t\t */\n\t\t&.ck-widget_selected {\n\t\t\tz-index: 2;\n\n\t\t\t/*\n\t\t\t * Make sure the native browser selection style is not displayed.\n\t\t\t * Inline image widgets have their own styles for the selected state and\n\t\t\t * leaving this up to the browser is asking for a visual collision.\n\t\t\t */\n\t\t\t& ::selection {\n\t\t\t\tdisplay: none;\n\t\t\t}\n\t\t}\n\t}\n\n\t/* Keep proportions of the inline image if the height is set and the image is wider than the editor width.\n\tSee https://github.com/ckeditor/ckeditor5/issues/14542. */\n\t& .image-inline img {\n\t\theight: auto;\n\t}\n\n\t/* The inline image nested in the table should have its original size if not resized.\n\tSee https://github.com/ckeditor/ckeditor5/issues/9117. */\n\t& td,\n\t& th {\n\t\t& .image-inline img {\n\t\t\tmax-width: none;\n\t\t}\n\t}\n}\n'],sourceRoot:""}]);const a=s},3038:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-color-image-caption-background:#f7f7f7;--ck-color-image-caption-text:#333;--ck-color-image-caption-highlighted-background:#fd0}.ck-content .image>figcaption{background-color:var(--ck-color-image-caption-background);caption-side:bottom;color:var(--ck-color-image-caption-text);display:table-caption;font-size:.75em;outline-offset:-1px;padding:.6em;word-break:break-word}@media (forced-colors:active){.ck-content .image>figcaption{background-color:unset;color:unset}}@media (forced-colors:none){.ck.ck-editor__editable .image>figcaption.image__caption_highlighted{animation:ck-image-caption-highlight .6s ease-out}}@media (prefers-reduced-motion:reduce){.ck.ck-editor__editable .image>figcaption.image__caption_highlighted{animation:none}}@keyframes ck-image-caption-highlight{0%{background-color:var(--ck-color-image-caption-highlighted-background)}to{background-color:var(--ck-color-image-caption-background)}}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-image/theme/imagecaption.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_mediacolors.css"],names:[],mappings:"AAOA,MACC,2CAAoD,CACpD,kCAA8C,CAC9C,oDACD,CAGA,8BAKC,yDAA0D,CAH1D,mBAAoB,CAEpB,wCAAyC,CAHzC,qBAAsB,CAMtB,eAAgB,CAChB,mBAAoB,CAFpB,YAAa,CAHb,qBAYD,CAJC,8BAXD,8BAYE,sBAAuB,CACvB,WAEF,CADC,CCdA,4BACC,qEDmBA,iDCjBA,CACD,CDmBA,uCALD,qEAME,cAEF,CADC,CAGD,sCACC,GACC,qEACD,CAEA,GACC,yDACD,CACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_mediacolors.css";\n\n:root {\n\t--ck-color-image-caption-background: hsl(0, 0%, 97%);\n\t--ck-color-image-caption-text: hsl(0, 0%, 20%);\n\t--ck-color-image-caption-highlighted-background: hsl(52deg 100% 50%);\n}\n\n/* Content styles */\n.ck-content .image > figcaption {\n\tdisplay: table-caption;\n\tcaption-side: bottom;\n\tword-break: break-word;\n\tcolor: var(--ck-color-image-caption-text);\n\tbackground-color: var(--ck-color-image-caption-background);\n\tpadding: .6em;\n\tfont-size: .75em;\n\toutline-offset: -1px;\n\n\t/* Improve placeholder rendering in high-constrast mode (https://github.com/ckeditor/ckeditor5/issues/14907). */\n\t@media (forced-colors: active) {\n\t\tbackground-color: unset;\n\t\tcolor: unset;\n\t}\n}\n\n/* Editing styles */\n.ck.ck-editor__editable .image > figcaption.image__caption_highlighted {\n\t@mixin ck-media-default-colors {\n\t\tanimation: ck-image-caption-highlight .6s ease-out;\n\t}\n\n\t@media (prefers-reduced-motion: reduce) {\n\t\tanimation: none;\n\t}\n}\n\n@keyframes ck-image-caption-highlight {\n\t0% {\n\t\tbackground-color: var(--ck-color-image-caption-highlighted-background);\n\t}\n\n\t100% {\n\t\tbackground-color: var(--ck-color-image-caption-background);\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@define-mixin ck-media-forced-colors {\n\t@media (forced-colors: active) {\n\t\t& {\n\t\t\t@mixin-content;\n\t\t}\n\t}\n}\n\n@define-mixin ck-media-default-colors {\n\t@media (forced-colors: none) {\n\t\t& {\n\t\t\t@mixin-content;\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},1173:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-image-custom-resize-form{align-items:flex-start;display:flex;flex-direction:row;flex-wrap:nowrap}.ck.ck-image-custom-resize-form .ck-labeled-field-view{display:inline-block}.ck.ck-image-custom-resize-form .ck-label{display:none}@media screen and (max-width:600px){.ck.ck-image-custom-resize-form{flex-wrap:wrap}.ck.ck-image-custom-resize-form .ck-labeled-field-view{flex-basis:100%}.ck.ck-image-custom-resize-form .ck-button{flex-basis:50%}}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-image/theme/imagecustomresizeform.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css"],names:[],mappings:"AAOA,gCAIC,sBAAuB,CAHvB,YAAa,CACb,kBAAmB,CACnB,gBAsBD,CAnBC,uDACC,oBACD,CAEA,0CACC,YACD,CCbA,oCDCD,gCAeE,cAUF,CARE,uDACC,eACD,CAEA,2CACC,cACD,CCtBD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css";\n\n.ck.ck-image-custom-resize-form {\n\tdisplay: flex;\n\tflex-direction: row;\n\tflex-wrap: nowrap;\n\talign-items: flex-start;\n\n\t& .ck-labeled-field-view {\n\t\tdisplay: inline-block;\n\t}\n\n\t& .ck-label {\n\t\tdisplay: none;\n\t}\n\n\t@mixin ck-media-phone {\n\t\tflex-wrap: wrap;\n\n\t\t& .ck-labeled-field-view {\n\t\t\tflex-basis: 100%;\n\t\t}\n\n\t\t& .ck-button {\n\t\t\tflex-basis: 50%;\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@define-mixin ck-media-phone {\n\t@media screen and (max-width: 600px) {\n\t\t@mixin-content;\n\t}\n}\n"],sourceRoot:""}]);const a=s},1545:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-image-insert-url{padding:var(--ck-spacing-large) var(--ck-spacing-large) 0;width:400px}.ck.ck-image-insert-url .ck-image-insert-url__action-row{display:grid;grid-template-columns:repeat(2,1fr)}:root{--ck-image-insert-insert-by-url-width:250px}.ck.ck-image-insert-url{--ck-input-width:100%}.ck.ck-image-insert-url .ck-image-insert-url__action-row{grid-column-gap:var(--ck-spacing-large);margin-top:var(--ck-spacing-large)}.ck.ck-image-insert-url .ck-image-insert-url__action-row .ck-button-cancel,.ck.ck-image-insert-url .ck-image-insert-url__action-row .ck-button-save{justify-content:center;min-width:auto}.ck.ck-image-insert-url .ck-image-insert-url__action-row .ck-button .ck-button__label{color:var(--ck-color-text)}.ck.ck-image-insert-form>.ck.ck-button{display:block;width:100%}[dir=ltr] .ck.ck-image-insert-form>.ck.ck-button{text-align:left}[dir=rtl] .ck.ck-image-insert-form>.ck.ck-button{text-align:right}.ck.ck-image-insert-form>.ck.ck-collapsible:not(:first-child){border-top:1px solid var(--ck-color-base-border)}.ck.ck-image-insert-form>.ck.ck-collapsible:not(:last-child){border-bottom:1px solid var(--ck-color-base-border)}.ck.ck-image-insert-form>.ck.ck-collapsible,.ck.ck-image-insert-form>.ck.ck-image-insert-url{min-width:var(--ck-image-insert-insert-by-url-width)}.ck.ck-image-insert-form>.ck.ck-image-insert-url{padding:var(--ck-spacing-large)}.ck.ck-image-insert-form:focus{outline:none}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-image/theme/imageinsert.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-image/imageinsert.css"],names:[],mappings:"AAKA,wBAEC,yDAA0D,CAD1D,WAOD,CAJC,yDACC,YAAa,CACb,mCACD,CCLD,MACC,2CACD,CAEA,wBACC,qBAgBD,CAdC,yDACC,uCAAwC,CACxC,kCAWD,CATC,oJAEC,sBAAuB,CACvB,cACD,CAEA,sFACC,0BACD,CAKD,uCACC,aAAc,CACd,UASD,CAXA,iDAKE,eAMF,CAXA,iDASE,gBAEF,CAGC,8DACC,gDACD,CAEA,6DACC,mDACD,CAMD,6FAJC,oDAOD,CAHA,iDAEC,+BACD,CAEA,+BACC,YACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-image-insert-url {\n\twidth: 400px;\n\tpadding: var(--ck-spacing-large) var(--ck-spacing-large) 0;\n\n\t& .ck-image-insert-url__action-row {\n\t\tdisplay: grid;\n\t\tgrid-template-columns: repeat(2, 1fr);\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n:root {\n\t--ck-image-insert-insert-by-url-width: 250px;\n}\n\n.ck.ck-image-insert-url {\n\t--ck-input-width: 100%;\n\n\t& .ck-image-insert-url__action-row {\n\t\tgrid-column-gap: var(--ck-spacing-large);\n\t\tmargin-top: var(--ck-spacing-large);\n\n\t\t& .ck-button-save,\n\t\t& .ck-button-cancel {\n\t\t\tjustify-content: center;\n\t\t\tmin-width: auto;\n\t\t}\n\n\t\t& .ck-button .ck-button__label {\n\t\t\tcolor: var(--ck-color-text);\n\t\t}\n\t}\n}\n\n.ck.ck-image-insert-form {\n\t& > .ck.ck-button {\n\t\tdisplay: block;\n\t\twidth: 100%;\n\n\t\t@mixin ck-dir ltr {\n\t\t\ttext-align: left;\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\ttext-align: right;\n\t\t}\n\t}\n\n\t& > .ck.ck-collapsible {\n\t\t&:not(:first-child) {\n\t\t\tborder-top: 1px solid var(--ck-color-base-border);\n\t\t}\n\n\t\t&:not(:last-child) {\n\t\t\tborder-bottom: 1px solid var(--ck-color-base-border);\n\t\t}\n\n\t\tmin-width: var(--ck-image-insert-insert-by-url-width);\n\t}\n\n\t/* This is the case when there are no other integrations configured than insert by URL */\n\t& > .ck.ck-image-insert-url {\n\t\tmin-width: var(--ck-image-insert-insert-by-url-width);\n\t\tpadding: var(--ck-spacing-large);\n\t}\n\n\t&:focus {\n\t\toutline: none;\n\t}\n}\n'],sourceRoot:""}]);const a=s},1091:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-editor__editable img.image_placeholder{background-size:100% 100%}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-image/theme/imageplaceholder.css"],names:[],mappings:"AAMC,8CACC,yBACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-editor__editable {\n\t& img.image_placeholder {\n\t\tbackground-size: 100% 100%;\n\t}\n}\n"],sourceRoot:""}]);const a=s},4214:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck-content img.image_resized{height:auto}.ck-content .image.image_resized{box-sizing:border-box;display:block;max-width:100%}.ck-content .image.image_resized img{width:100%}.ck-content .image.image_resized>figcaption{display:block}.ck.ck-editor__editable td .image-inline.image_resized img,.ck.ck-editor__editable th .image-inline.image_resized img{max-width:100%}[dir=ltr] .ck.ck-button.ck-button_with-text.ck-resize-image-button .ck-button__icon{margin-right:var(--ck-spacing-standard)}[dir=rtl] .ck.ck-button.ck-button_with-text.ck-resize-image-button .ck-button__icon{margin-left:var(--ck-spacing-standard)}.ck.ck-dropdown .ck-button.ck-resize-image-button .ck-button__label{width:4em}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-image/theme/imageresize.css"],names:[],mappings:"AAMA,8BACC,WACD,CAEA,iCAQC,qBAAsB,CADtB,aAAc,CANd,cAkBD,CATC,qCAEC,UACD,CAEA,4CAEC,aACD,CAQC,sHACC,cACD,CAIF,oFACC,uCACD,CAEA,oFACC,sCACD,CAEA,oEACC,SACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/* Preserve aspect ratio of the resized image after introducing image height attribute. */\n.ck-content img.image_resized {\n\theight: auto;\n}\n\n.ck-content .image.image_resized {\n\tmax-width: 100%;\n\t/*\n\tThe `
    ` element for resized images must not use `display:table` as browsers do not support `max-width` for it well.\n\tSee https://stackoverflow.com/questions/4019604/chrome-safari-ignoring-max-width-in-table/14420691#14420691 for more.\n\tFortunately, since we control the width, there is no risk that the image will look bad.\n\t*/\n\tdisplay: block;\n\tbox-sizing: border-box;\n\n\t& img {\n\t\t/* For resized images it is the `
    ` element that determines the image width. */\n\t\twidth: 100%;\n\t}\n\n\t& > figcaption {\n\t\t/* The `
    ` element uses `display:block`, so `
    ` also has to. */\n\t\tdisplay: block;\n\t}\n}\n\n.ck.ck-editor__editable {\n\t/* The resized inline image nested in the table should respect its parent size.\n\tSee https://github.com/ckeditor/ckeditor5/issues/9117. */\n\t& td,\n\t& th {\n\t\t& .image-inline.image_resized img {\n\t\t\tmax-width: 100%;\n\t\t}\n\t}\n}\n\n[dir="ltr"] .ck.ck-button.ck-button_with-text.ck-resize-image-button .ck-button__icon {\n\tmargin-right: var(--ck-spacing-standard);\n}\n\n[dir="rtl"] .ck.ck-button.ck-button_with-text.ck-resize-image-button .ck-button__icon {\n\tmargin-left: var(--ck-spacing-standard);\n}\n\n.ck.ck-dropdown .ck-button.ck-resize-image-button .ck-button__label {\n\twidth: 4em;\n}\n'],sourceRoot:""}]);const a=s},7879:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-image-style-spacing:1.5em;--ck-inline-image-style-spacing:calc(var(--ck-image-style-spacing)/2)}.ck-content .image.image-style-block-align-left,.ck-content .image.image-style-block-align-right{max-width:calc(100% - var(--ck-image-style-spacing))}.ck-content .image.image-style-align-left,.ck-content .image.image-style-align-right{clear:none}.ck-content .image.image-style-side{float:right;margin-left:var(--ck-image-style-spacing);max-width:50%}.ck-content .image.image-style-align-left{float:left;margin-right:var(--ck-image-style-spacing)}.ck-content .image.image-style-align-right{float:right;margin-left:var(--ck-image-style-spacing)}.ck-content .image.image-style-block-align-right{margin-left:auto;margin-right:0}.ck-content .image.image-style-block-align-left{margin-left:0;margin-right:auto}.ck-content .image-style-align-center{margin-left:auto;margin-right:auto}.ck-content .image-style-align-left{float:left;margin-right:var(--ck-image-style-spacing)}.ck-content .image-style-align-right{float:right;margin-left:var(--ck-image-style-spacing)}.ck-content p+.image.image-style-align-left,.ck-content p+.image.image-style-align-right,.ck-content p+.image.image-style-side{margin-top:0}.ck-content .image-inline.image-style-align-left,.ck-content .image-inline.image-style-align-right{margin-bottom:var(--ck-inline-image-style-spacing);margin-top:var(--ck-inline-image-style-spacing)}.ck-content .image-inline.image-style-align-left{margin-right:var(--ck-inline-image-style-spacing)}.ck-content .image-inline.image-style-align-right{margin-left:var(--ck-inline-image-style-spacing)}.ck.ck-splitbutton.ck-splitbutton_flatten.ck-splitbutton_open>.ck-splitbutton__action:not(.ck-disabled),.ck.ck-splitbutton.ck-splitbutton_flatten.ck-splitbutton_open>.ck-splitbutton__arrow:not(.ck-disabled),.ck.ck-splitbutton.ck-splitbutton_flatten.ck-splitbutton_open>.ck-splitbutton__arrow:not(.ck-disabled):not(:hover),.ck.ck-splitbutton.ck-splitbutton_flatten:hover>.ck-splitbutton__action:not(.ck-disabled),.ck.ck-splitbutton.ck-splitbutton_flatten:hover>.ck-splitbutton__arrow:not(.ck-disabled),.ck.ck-splitbutton.ck-splitbutton_flatten:hover>.ck-splitbutton__arrow:not(.ck-disabled):not(:hover){background-color:var(--ck-color-button-on-background)}.ck.ck-splitbutton.ck-splitbutton_flatten.ck-splitbutton_open>.ck-splitbutton__action:not(.ck-disabled):after,.ck.ck-splitbutton.ck-splitbutton_flatten.ck-splitbutton_open>.ck-splitbutton__arrow:not(.ck-disabled):after,.ck.ck-splitbutton.ck-splitbutton_flatten.ck-splitbutton_open>.ck-splitbutton__arrow:not(.ck-disabled):not(:hover):after,.ck.ck-splitbutton.ck-splitbutton_flatten:hover>.ck-splitbutton__action:not(.ck-disabled):after,.ck.ck-splitbutton.ck-splitbutton_flatten:hover>.ck-splitbutton__arrow:not(.ck-disabled):after,.ck.ck-splitbutton.ck-splitbutton_flatten:hover>.ck-splitbutton__arrow:not(.ck-disabled):not(:hover):after{display:none}.ck.ck-splitbutton.ck-splitbutton_flatten.ck-splitbutton_open:hover>.ck-splitbutton__action:not(.ck-disabled),.ck.ck-splitbutton.ck-splitbutton_flatten.ck-splitbutton_open:hover>.ck-splitbutton__arrow:not(.ck-disabled),.ck.ck-splitbutton.ck-splitbutton_flatten.ck-splitbutton_open:hover>.ck-splitbutton__arrow:not(.ck-disabled):not(:hover){background-color:var(--ck-color-button-on-hover-background)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-image/theme/imagestyle.css"],names:[],mappings:"AAKA,MACC,8BAA+B,CAC/B,qEACD,CAQE,iGAEC,oDACD,CAIA,qFAEC,UACD,CAEA,oCACC,WAAY,CACZ,yCAA0C,CAC1C,aACD,CAEA,0CACC,UAAW,CACX,0CACD,CAEA,2CACC,WAAY,CACZ,yCACD,CAEA,iDAEC,gBAAiB,CADjB,cAED,CAEA,gDACC,aAAc,CACd,iBACD,CAGD,sCACC,gBAAiB,CACjB,iBACD,CAEA,oCACC,UAAW,CACX,0CACD,CAEA,qCACC,WAAY,CACZ,yCACD,CAGA,+HAGC,YACD,CAGC,mGAGC,kDAAmD,CADnD,+CAED,CAEA,iDACC,iDACD,CAEA,kDACC,gDACD,CAUC,0lBAGC,qDAKD,CAHC,8nBACC,YACD,CAKD,oVAGC,2DACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-image-style-spacing: 1.5em;\n\t--ck-inline-image-style-spacing: calc(var(--ck-image-style-spacing) / 2);\n}\n\n.ck-content {\n\t/* See: https://github.com/ckeditor/ckeditor5/issues/16317 */\n\t& .image {\n\t\t/* Provides a minimal side margin for the left and right aligned images, so that the user has a visual feedback\n\t\tconfirming successful application of the style if image width exceeds the editor's size.\n\t\tSee https://github.com/ckeditor/ckeditor5/issues/9342 */\n\t\t&.image-style-block-align-left,\n\t\t&.image-style-block-align-right {\n\t\t\tmax-width: calc(100% - var(--ck-image-style-spacing));\n\t\t}\n\n\t\t/* Allows displaying multiple floating images in the same line.\n\t\tSee https://github.com/ckeditor/ckeditor5/issues/9183#issuecomment-804988132 */\n\t\t&.image-style-align-left,\n\t\t&.image-style-align-right {\n\t\t\tclear: none;\n\t\t}\n\n\t\t&.image-style-side {\n\t\t\tfloat: right;\n\t\t\tmargin-left: var(--ck-image-style-spacing);\n\t\t\tmax-width: 50%;\n\t\t}\n\n\t\t&.image-style-align-left {\n\t\t\tfloat: left;\n\t\t\tmargin-right: var(--ck-image-style-spacing);\n\t\t}\n\n\t\t&.image-style-align-right {\n\t\t\tfloat: right;\n\t\t\tmargin-left: var(--ck-image-style-spacing);\n\t\t}\n\n\t\t&.image-style-block-align-right {\n\t\t\tmargin-right: 0;\n\t\t\tmargin-left: auto;\n\t\t}\n\n\t\t&.image-style-block-align-left {\n\t\t\tmargin-left: 0;\n\t\t\tmargin-right: auto;\n\t\t}\n\t}\n\n\t& .image-style-align-center {\n\t\tmargin-left: auto;\n\t\tmargin-right: auto;\n\t}\n\n\t& .image-style-align-left {\n\t\tfloat: left;\n\t\tmargin-right: var(--ck-image-style-spacing);\n\t}\n\n\t& .image-style-align-right {\n\t\tfloat: right;\n\t\tmargin-left: var(--ck-image-style-spacing);\n\t}\n\n\t/* Simulates margin collapsing with the preceding paragraph, which does not work for the floating elements. */\n\t& p + .image.image-style-align-left,\n\t& p + .image.image-style-align-right,\n\t& p + .image.image-style-side {\n\t\tmargin-top: 0;\n\t}\n\n\t& .image-inline {\n\t\t&.image-style-align-left,\n\t\t&.image-style-align-right {\n\t\t\tmargin-top: var(--ck-inline-image-style-spacing);\n\t\t\tmargin-bottom: var(--ck-inline-image-style-spacing);\n\t\t}\n\n\t\t&.image-style-align-left {\n\t\t\tmargin-right: var(--ck-inline-image-style-spacing);\n\t\t}\n\n\t\t&.image-style-align-right {\n\t\t\tmargin-left: var(--ck-inline-image-style-spacing);\n\t\t}\n\t}\n}\n\n.ck.ck-splitbutton {\n\t/* The button should display as a regular drop-down if the action button\n\tis forced to fire the same action as the arrow button. */\n\t&.ck-splitbutton_flatten {\n\t\t&:hover,\n\t\t&.ck-splitbutton_open {\n\t\t\t& > .ck-splitbutton__action:not(.ck-disabled),\n\t\t\t& > .ck-splitbutton__arrow:not(.ck-disabled),\n\t\t\t& > .ck-splitbutton__arrow:not(.ck-disabled):not(:hover) {\n\t\t\t\tbackground-color: var(--ck-color-button-on-background);\n\n\t\t\t\t&::after {\n\t\t\t\t\tdisplay: none;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t&.ck-splitbutton_open:hover {\n\t\t\t& > .ck-splitbutton__action:not(.ck-disabled),\n\t\t\t& > .ck-splitbutton__arrow:not(.ck-disabled),\n\t\t\t& > .ck-splitbutton__arrow:not(.ck-disabled):not(:hover) {\n\t\t\t\tbackground-color: var(--ck-color-button-on-hover-background);\n\t\t\t}\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},1230:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,'.ck-image-upload-complete-icon{border-radius:50%;display:block;position:absolute;right:min(var(--ck-spacing-medium),6%);top:min(var(--ck-spacing-medium),6%);z-index:1}.ck-image-upload-complete-icon:after{content:"";position:absolute}:root{--ck-color-image-upload-icon:#fff;--ck-color-image-upload-icon-background:#008a00;--ck-image-upload-icon-size:20;--ck-image-upload-icon-width:2px;--ck-image-upload-icon-is-visible:clamp(0px,100% - 50px,1px)}.ck-image-upload-complete-icon{animation-delay:0ms,3s;animation-duration:.5s,.5s;animation-fill-mode:forwards,forwards;animation-name:ck-upload-complete-icon-show,ck-upload-complete-icon-hide;background:var(--ck-color-image-upload-icon-background);font-size:calc(1px*var(--ck-image-upload-icon-size));height:calc(var(--ck-image-upload-icon-is-visible)*var(--ck-image-upload-icon-size));opacity:0;overflow:hidden;width:calc(var(--ck-image-upload-icon-is-visible)*var(--ck-image-upload-icon-size))}.ck-image-upload-complete-icon:after{animation-delay:.5s;animation-duration:.5s;animation-fill-mode:forwards;animation-name:ck-upload-complete-icon-check;border-right:var(--ck-image-upload-icon-width) solid var(--ck-color-image-upload-icon);border-top:var(--ck-image-upload-icon-width) solid var(--ck-color-image-upload-icon);box-sizing:border-box;height:0;left:25%;opacity:0;top:50%;transform:scaleX(-1) rotate(135deg);transform-origin:left top;width:0}@media (prefers-reduced-motion:reduce){.ck-image-upload-complete-icon{animation-duration:0ms}.ck-image-upload-complete-icon:after{animation:none;height:.45em;opacity:1;width:.3em}}@keyframes ck-upload-complete-icon-show{0%{opacity:0}to{opacity:1}}@keyframes ck-upload-complete-icon-hide{0%{opacity:1}to{opacity:0}}@keyframes ck-upload-complete-icon-check{0%{height:0;opacity:1;width:0}33%{height:0;width:.3em}to{height:.45em;opacity:1;width:.3em}}',"",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-image/theme/imageuploadicon.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-image/imageuploadicon.css"],names:[],mappings:"AAKA,+BAUC,iBAAkB,CATlB,aAAc,CACd,iBAAkB,CAOlB,sCAAwC,CADxC,oCAAsC,CAGtC,SAMD,CAJC,qCACC,UAAW,CACX,iBACD,CChBD,MACC,iCAA8C,CAC9C,+CAA4D,CAG5D,8BAA+B,CAC/B,gCAAiC,CACjC,4DACD,CAEA,+BAWC,sBAA4B,CAN5B,0BAAgC,CADhC,qCAAuC,CADvC,wEAA0E,CAD1E,uDAAwD,CAMxD,oDAAuD,CAWvD,oFAAuF,CAlBvF,SAAU,CAgBV,eAAgB,CAChB,mFAqCD,CAjCC,qCAgBC,mBAAsB,CADtB,sBAAyB,CAEzB,4BAA6B,CAH7B,4CAA6C,CAF7C,sFAAuF,CADvF,oFAAqF,CASrF,qBAAsB,CAdtB,QAAS,CAJT,QAAS,CAGT,SAAU,CADV,OAAQ,CAKR,mCAAoC,CACpC,yBAA0B,CAH1B,OAcD,CAEA,uCA7CD,+BA8CE,sBASF,CAPE,qCACC,cAAe,CAGf,YAAc,CAFd,SAAU,CACV,UAED,CACD,CAGD,wCACC,GACC,SACD,CAEA,GACC,SACD,CACD,CAEA,wCACC,GACC,SACD,CAEA,GACC,SACD,CACD,CAEA,yCACC,GAGC,QAAS,CAFT,SAAU,CACV,OAED,CACA,IAEC,QAAS,CADT,UAED,CACA,GAGC,YAAc,CAFd,SAAU,CACV,UAED,CACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck-image-upload-complete-icon {\n\tdisplay: block;\n\tposition: absolute;\n\n\t/*\n\t * Smaller images should have the icon closer to the border.\n\t * Match the icon position with the linked image indicator brought by the link image feature.\n\t */\n\ttop: min(var(--ck-spacing-medium), 6%);\n\tright: min(var(--ck-spacing-medium), 6%);\n\tborder-radius: 50%;\n\tz-index: 1;\n\n\t&::after {\n\t\tcontent: "";\n\t\tposition: absolute;\n\t}\n}\n','/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-color-image-upload-icon: hsl(0, 0%, 100%);\n\t--ck-color-image-upload-icon-background: hsl(120, 100%, 27%);\n\n\t/* Match the icon size with the linked image indicator brought by the link image feature. */\n\t--ck-image-upload-icon-size: 20;\n\t--ck-image-upload-icon-width: 2px;\n\t--ck-image-upload-icon-is-visible: clamp(0px, 100% - 50px, 1px);\n}\n\n.ck-image-upload-complete-icon {\n\topacity: 0;\n\tbackground: var(--ck-color-image-upload-icon-background);\n\tanimation-name: ck-upload-complete-icon-show, ck-upload-complete-icon-hide;\n\tanimation-fill-mode: forwards, forwards;\n\tanimation-duration: 500ms, 500ms;\n\n\t/* To make animation scalable. */\n\tfont-size: calc(1px * var(--ck-image-upload-icon-size));\n\n\t/* Hide completed upload icon after 3 seconds. */\n\tanimation-delay: 0ms, 3000ms;\n\n\t/*\n\t * Use CSS math to simulate container queries.\n\t * https://css-tricks.com/the-raven-technique-one-step-closer-to-container-queries/#what-about-showing-and-hiding-things\n\t */\n\toverflow: hidden;\n\twidth: calc(var(--ck-image-upload-icon-is-visible) * var(--ck-image-upload-icon-size));\n\theight: calc(var(--ck-image-upload-icon-is-visible) * var(--ck-image-upload-icon-size));\n\n\t/* This is check icon element made from border-width mixed with animations. */\n\t&::after {\n\t\t/* Because of border transformation we need to "hard code" left position. */\n\t\tleft: 25%;\n\n\t\ttop: 50%;\n\t\topacity: 0;\n\t\theight: 0;\n\t\twidth: 0;\n\n\t\ttransform: scaleX(-1) rotate(135deg);\n\t\ttransform-origin: left top;\n\t\tborder-top: var(--ck-image-upload-icon-width) solid var(--ck-color-image-upload-icon);\n\t\tborder-right: var(--ck-image-upload-icon-width) solid var(--ck-color-image-upload-icon);\n\n\t\tanimation-name: ck-upload-complete-icon-check;\n\t\tanimation-duration: 500ms;\n\t\tanimation-delay: 500ms;\n\t\tanimation-fill-mode: forwards;\n\n\t\t/* #1095. While reset is not providing proper box-sizing for pseudoelements, we need to handle it. */\n\t\tbox-sizing: border-box;\n\t}\n\n\t@media (prefers-reduced-motion: reduce) {\n\t\tanimation-duration: 0ms;\n\n\t\t&::after {\n\t\t\tanimation: none;\n\t\t\topacity: 1;\n\t\t\twidth: 0.3em;\n\t\t\theight: 0.45em;\n\t\t}\n\t}\n}\n\n@keyframes ck-upload-complete-icon-show {\n\tfrom {\n\t\topacity: 0;\n\t}\n\n\tto {\n\t\topacity: 1;\n\t}\n}\n\n@keyframes ck-upload-complete-icon-hide {\n\tfrom {\n\t\topacity: 1;\n\t}\n\n\tto {\n\t\topacity: 0;\n\t}\n}\n\n@keyframes ck-upload-complete-icon-check {\n\t0% {\n\t\topacity: 1;\n\t\twidth: 0;\n\t\theight: 0;\n\t}\n\t33% {\n\t\twidth: 0.3em;\n\t\theight: 0;\n\t}\n\t100% {\n\t\topacity: 1;\n\t\twidth: 0.3em;\n\t\theight: 0.45em;\n\t}\n}\n'],sourceRoot:""}]);const a=s},1160:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,'.ck .ck-upload-placeholder-loader{align-items:center;display:flex;justify-content:center;left:0;position:absolute;top:0}.ck .ck-upload-placeholder-loader:before{content:"";position:relative}:root{--ck-color-upload-placeholder-loader:#b3b3b3;--ck-upload-placeholder-loader-size:32px;--ck-upload-placeholder-image-aspect-ratio:2.8}.ck .ck-image-upload-placeholder{margin:0;width:100%}.ck .ck-image-upload-placeholder.image-inline{width:calc(var(--ck-upload-placeholder-loader-size)*2*var(--ck-upload-placeholder-image-aspect-ratio))}.ck .ck-image-upload-placeholder img{aspect-ratio:var(--ck-upload-placeholder-image-aspect-ratio)}.ck .ck-upload-placeholder-loader{height:100%;width:100%}.ck .ck-upload-placeholder-loader:before{animation:ck-upload-placeholder-loader 1s linear infinite;border-radius:50%;border-right:2px solid transparent;border-top:3px solid var(--ck-color-upload-placeholder-loader);height:var(--ck-upload-placeholder-loader-size);width:var(--ck-upload-placeholder-loader-size)}@keyframes ck-upload-placeholder-loader{to{transform:rotate(1turn)}}',"",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-image/theme/imageuploadloader.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-image/imageuploadloader.css"],names:[],mappings:"AAKA,kCAGC,kBAAmB,CADnB,YAAa,CAEb,sBAAuB,CAEvB,MAAO,CALP,iBAAkB,CAIlB,KAOD,CAJC,yCACC,UAAW,CACX,iBACD,CCXD,MACC,4CAAqD,CACrD,wCAAyC,CACzC,8CACD,CAEA,iCAGC,QAAS,CADT,UAgBD,CAbC,8CACC,sGACD,CAEA,qCAOC,4DACD,CAGD,kCAEC,WAAY,CADZ,UAWD,CARC,yCAMC,yDAA0D,CAH1D,iBAAkB,CAElB,kCAAmC,CADnC,8DAA+D,CAF/D,+CAAgD,CADhD,8CAMD,CAGD,wCACC,GACC,uBACD,CACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck .ck-upload-placeholder-loader {\n\tposition: absolute;\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\ttop: 0;\n\tleft: 0;\n\n\t&::before {\n\t\tcontent: '';\n\t\tposition: relative;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-color-upload-placeholder-loader: hsl(0, 0%, 70%);\n\t--ck-upload-placeholder-loader-size: 32px;\n\t--ck-upload-placeholder-image-aspect-ratio: 2.8;\n}\n\n.ck .ck-image-upload-placeholder {\n\t/* We need to control the full width of the SVG gray background. */\n\twidth: 100%;\n\tmargin: 0;\n\n\t&.image-inline {\n\t\twidth: calc( 2 * var(--ck-upload-placeholder-loader-size) * var(--ck-upload-placeholder-image-aspect-ratio) );\n\t}\n\n\t& img {\n\t\t/*\n\t\t * This is an arbitrary aspect for a 1x1 px GIF to display to the user. Not too tall, not too short.\n\t\t * There's nothing special about this number except that it should make the image placeholder look like\n\t\t * a real image during this short period after the upload started and before the image was read from the\n\t\t * file system (and a rich preview was loaded).\n\t\t */\n\t\taspect-ratio: var(--ck-upload-placeholder-image-aspect-ratio);\n\t}\n}\n\n.ck .ck-upload-placeholder-loader {\n\twidth: 100%;\n\theight: 100%;\n\n\t&::before {\n\t\twidth: var(--ck-upload-placeholder-loader-size);\n\t\theight: var(--ck-upload-placeholder-loader-size);\n\t\tborder-radius: 50%;\n\t\tborder-top: 3px solid var(--ck-color-upload-placeholder-loader);\n\t\tborder-right: 2px solid transparent;\n\t\tanimation: ck-upload-placeholder-loader 1s linear infinite;\n\t}\n}\n\n@keyframes ck-upload-placeholder-loader {\n\tto {\n\t\ttransform: rotate( 360deg );\n\t}\n}\n"],sourceRoot:""}]);const a=s},7504:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-editor__editable .image,.ck.ck-editor__editable .image-inline{position:relative}.ck.ck-editor__editable .image .ck-progress-bar,.ck.ck-editor__editable .image-inline .ck-progress-bar{left:0;position:absolute;top:0}.ck.ck-editor__editable .image-inline.ck-appear,.ck.ck-editor__editable .image.ck-appear{animation:fadeIn .7s}@media (prefers-reduced-motion:reduce){.ck.ck-editor__editable .image-inline.ck-appear,.ck.ck-editor__editable .image.ck-appear{animation:none;opacity:1}}.ck.ck-editor__editable .image .ck-progress-bar,.ck.ck-editor__editable .image-inline .ck-progress-bar{background:var(--ck-color-upload-bar-background);height:2px;transition:width .1s;width:0}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-image/theme/imageuploadprogress.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-image/imageuploadprogress.css"],names:[],mappings:"AAMC,qEAEC,iBACD,CAGA,uGAIC,MAAO,CAFP,iBAAkB,CAClB,KAED,CCRC,yFACC,oBAMD,CAJC,uCAHD,yFAKE,cAAe,CADf,SAGF,CADC,CAKF,uGAIC,gDAAiD,CAFjD,UAAW,CAGX,oBAAuB,CAFvB,OAGD,CAGD,kBACC,GAAO,SAAY,CACnB,GAAO,SAAY,CACpB",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-editor__editable {\n\t& .image,\n\t& .image-inline {\n\t\tposition: relative;\n\t}\n\n\t/* Upload progress bar. */\n\t& .image .ck-progress-bar,\n\t& .image-inline .ck-progress-bar {\n\t\tposition: absolute;\n\t\ttop: 0;\n\t\tleft: 0;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-editor__editable {\n\t& .image,\n\t& .image-inline {\n\t\t/* Showing animation. */\n\t\t&.ck-appear {\n\t\t\tanimation: fadeIn 700ms;\n\n\t\t\t@media (prefers-reduced-motion: reduce) {\n\t\t\t\topacity: 1;\n\t\t\t\tanimation: none;\n\t\t\t}\n\t\t}\n\t}\n\n\t/* Upload progress bar. */\n\t& .image .ck-progress-bar,\n\t& .image-inline .ck-progress-bar {\n\t\theight: 2px;\n\t\twidth: 0;\n\t\tbackground: var(--ck-color-upload-bar-background);\n\t\ttransition: width 100ms;\n\t}\n}\n\n@keyframes fadeIn {\n\tfrom { opacity: 0; }\n\tto { opacity: 1; }\n}\n"],sourceRoot:""}]);const a=s},8429:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-text-alternative-form{display:flex;flex-direction:row;flex-wrap:nowrap}.ck.ck-text-alternative-form .ck-labeled-field-view{display:inline-block}.ck.ck-text-alternative-form .ck-label{display:none}@media screen and (max-width:600px){.ck.ck-text-alternative-form{flex-wrap:wrap}.ck.ck-text-alternative-form .ck-labeled-field-view{flex-basis:100%}.ck.ck-text-alternative-form .ck-button{flex-basis:50%}}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-image/theme/textalternativeform.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css"],names:[],mappings:"AAOA,6BACC,YAAa,CACb,kBAAmB,CACnB,gBAqBD,CAnBC,oDACC,oBACD,CAEA,uCACC,YACD,CCZA,oCDCD,6BAcE,cAUF,CARE,oDACC,eACD,CAEA,wCACC,cACD,CCrBD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css";\n\n.ck.ck-text-alternative-form {\n\tdisplay: flex;\n\tflex-direction: row;\n\tflex-wrap: nowrap;\n\n\t& .ck-labeled-field-view {\n\t\tdisplay: inline-block;\n\t}\n\n\t& .ck-label {\n\t\tdisplay: none;\n\t}\n\n\t@mixin ck-media-phone {\n\t\tflex-wrap: wrap;\n\n\t\t& .ck-labeled-field-view {\n\t\t\tflex-basis: 100%;\n\t\t}\n\n\t\t& .ck-button {\n\t\t\tflex-basis: 50%;\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@define-mixin ck-media-phone {\n\t@media screen and (max-width: 600px) {\n\t\t@mixin-content;\n\t}\n}\n"],sourceRoot:""}]);const a=s},7456:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck .ck-link_selected{background:var(--ck-color-link-selected-background)}.ck .ck-link_selected span.image-inline{outline:var(--ck-widget-outline-thickness) solid var(--ck-color-link-selected-background)}.ck .ck-fake-link-selection{background:var(--ck-color-link-fake-selection)}.ck .ck-fake-link-selection_collapsed{border-right:1px solid var(--ck-color-base-text);height:100%;margin-right:-1px;outline:1px solid hsla(0,0%,100%,.5)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-link/link.css"],names:[],mappings:"AAMA,sBACC,mDAMD,CAHC,wCACC,yFACD,CAOD,4BACC,8CACD,CAGA,sCAEC,gDAAiD,CADjD,WAAY,CAEZ,iBAAkB,CAClB,oCACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/* Class added to span element surrounding currently selected link. */\n.ck .ck-link_selected {\n\tbackground: var(--ck-color-link-selected-background);\n\n\t/* Give linked inline images some outline to let the user know they are also part of the link. */\n\t& span.image-inline {\n\t\toutline: var(--ck-widget-outline-thickness) solid var(--ck-color-link-selected-background);\n\t}\n}\n\n/*\n * Classes used by the "fake visual selection" displayed in the content when an input\n * in the link UI has focus (the browser does not render the native selection in this state).\n */\n.ck .ck-fake-link-selection {\n\tbackground: var(--ck-color-link-fake-selection);\n}\n\n/* A collapsed fake visual selection. */\n.ck .ck-fake-link-selection_collapsed {\n\theight: 100%;\n\tborder-right: 1px solid var(--ck-color-base-text);\n\tmargin-right: -1px;\n\toutline: solid 1px hsla(0, 0%, 100%, .5);\n}\n'],sourceRoot:""}]);const a=s},8040:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-link-actions{display:flex;flex-direction:row;flex-wrap:nowrap}.ck.ck-link-actions .ck-link-actions__preview{display:inline-block}.ck.ck-link-actions .ck-link-actions__preview .ck-button__label{overflow:hidden}@media screen and (max-width:600px){.ck.ck-link-actions{flex-wrap:wrap}.ck.ck-link-actions .ck-link-actions__preview{flex-basis:100%}.ck.ck-link-actions .ck-button:not(.ck-link-actions__preview){flex-basis:50%}}.ck.ck-link-actions .ck-button.ck-link-actions__preview{padding-left:0;padding-right:0}.ck.ck-link-actions .ck-button.ck-link-actions__preview .ck-button__label{color:var(--ck-color-link-default);cursor:pointer;max-width:var(--ck-input-width);min-width:3em;padding:0 var(--ck-spacing-medium);text-align:center;text-overflow:ellipsis}.ck.ck-link-actions .ck-button.ck-link-actions__preview .ck-button__label:hover{text-decoration:underline}.ck.ck-link-actions .ck-button.ck-link-actions__preview,.ck.ck-link-actions .ck-button.ck-link-actions__preview:active,.ck.ck-link-actions .ck-button.ck-link-actions__preview:focus,.ck.ck-link-actions .ck-button.ck-link-actions__preview:hover{background:none}.ck.ck-link-actions .ck-button.ck-link-actions__preview:active{box-shadow:none}.ck.ck-link-actions .ck-button.ck-link-actions__preview:focus .ck-button__label{text-decoration:underline}[dir=ltr] .ck.ck-link-actions .ck-button:not(:first-child),[dir=rtl] .ck.ck-link-actions .ck-button:not(:last-child){margin-left:var(--ck-spacing-standard)}@media screen and (max-width:600px){.ck.ck-link-actions .ck-button.ck-link-actions__preview{margin:var(--ck-spacing-standard) var(--ck-spacing-standard) 0}.ck.ck-link-actions .ck-button.ck-link-actions__preview .ck-button__label{max-width:100%;min-width:0}[dir=ltr] .ck.ck-link-actions .ck-button:not(.ck-link-actions__preview),[dir=rtl] .ck.ck-link-actions .ck-button:not(.ck-link-actions__preview){margin-left:0}}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-link/theme/linkactions.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-link/linkactions.css"],names:[],mappings:"AAOA,oBACC,YAAa,CACb,kBAAmB,CACnB,gBAqBD,CAnBC,8CACC,oBAKD,CAHC,gEACC,eACD,CCXD,oCDCD,oBAcE,cAUF,CARE,8CACC,eACD,CAEA,8DACC,cACD,CCrBD,CCIA,wDACC,cAAe,CACf,eAmCD,CAjCC,0EAEC,kCAAmC,CAEnC,cAAe,CAIf,+BAAgC,CAChC,aAAc,CARd,kCAAmC,CASnC,iBAAkB,CAPlB,sBAYD,CAHC,gFACC,yBACD,CAGD,mPAIC,eACD,CAEA,+DACC,eACD,CAGC,gFACC,yBACD,CAWD,qHACC,sCACD,CDtDD,oCC0DC,wDACC,8DAMD,CAJC,0EAEC,cAAe,CADf,WAED,CAGD,gJAME,aAEF,CDzED",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css";\n\n.ck.ck-link-actions {\n\tdisplay: flex;\n\tflex-direction: row;\n\tflex-wrap: nowrap;\n\n\t& .ck-link-actions__preview {\n\t\tdisplay: inline-block;\n\n\t\t& .ck-button__label {\n\t\t\toverflow: hidden;\n\t\t}\n\t}\n\n\t@mixin ck-media-phone {\n\t\tflex-wrap: wrap;\n\n\t\t& .ck-link-actions__preview {\n\t\t\tflex-basis: 100%;\n\t\t}\n\n\t\t& .ck-button:not(.ck-link-actions__preview) {\n\t\t\tflex-basis: 50%;\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@define-mixin ck-media-phone {\n\t@media screen and (max-width: 600px) {\n\t\t@mixin-content;\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_unselectable.css";\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n@import "../mixins/_focus.css";\n@import "../mixins/_shadow.css";\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css";\n\n.ck.ck-link-actions {\n\t& .ck-button.ck-link-actions__preview {\n\t\tpadding-left: 0;\n\t\tpadding-right: 0;\n\n\t\t& .ck-button__label {\n\t\t\tpadding: 0 var(--ck-spacing-medium);\n\t\t\tcolor: var(--ck-color-link-default);\n\t\t\ttext-overflow: ellipsis;\n\t\t\tcursor: pointer;\n\n\t\t\t/* Match the box model of the link editor form\'s input so the balloon\n\t\t\tdoes not change width when moving between actions and the form. */\n\t\t\tmax-width: var(--ck-input-width);\n\t\t\tmin-width: 3em;\n\t\t\ttext-align: center;\n\n\t\t\t&:hover {\n\t\t\t\ttext-decoration: underline;\n\t\t\t}\n\t\t}\n\n\t\t&,\n\t\t&:hover,\n\t\t&:focus,\n\t\t&:active {\n\t\t\tbackground: none;\n\t\t}\n\n\t\t&:active {\n\t\t\tbox-shadow: none;\n\t\t}\n\n\t\t&:focus {\n\t\t\t& .ck-button__label {\n\t\t\t\ttext-decoration: underline;\n\t\t\t}\n\t\t}\n\t}\n\n\t@mixin ck-dir ltr {\n\t\t& .ck-button:not(:first-child) {\n\t\t\tmargin-left: var(--ck-spacing-standard);\n\t\t}\n\t}\n\n\t@mixin ck-dir rtl {\n\t\t& .ck-button:not(:last-child) {\n\t\t\tmargin-left: var(--ck-spacing-standard);\n\t\t}\n\t}\n\n\t@mixin ck-media-phone {\n\t\t& .ck-button.ck-link-actions__preview {\n\t\t\tmargin: var(--ck-spacing-standard) var(--ck-spacing-standard) 0;\n\n\t\t\t& .ck-button__label {\n\t\t\t\tmin-width: 0;\n\t\t\t\tmax-width: 100%;\n\t\t\t}\n\t\t}\n\n\t\t& .ck-button:not(.ck-link-actions__preview) {\n\t\t\t@mixin ck-dir ltr {\n\t\t\t\tmargin-left: 0;\n\t\t\t}\n\n\t\t\t@mixin ck-dir rtl {\n\t\t\t\tmargin-left: 0;\n\t\t\t}\n\t\t}\n\t}\n}\n'],sourceRoot:""}]);const a=s},2350:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-link-form{align-items:flex-start;display:flex}.ck.ck-link-form .ck-label{display:none}@media screen and (max-width:600px){.ck.ck-link-form{flex-wrap:wrap}.ck.ck-link-form .ck-labeled-field-view{flex-basis:100%}.ck.ck-link-form .ck-button{flex-basis:50%}}.ck.ck-link-form_layout-vertical{display:block}.ck.ck-link-form_layout-vertical .ck-button.ck-button-cancel,.ck.ck-link-form_layout-vertical .ck-button.ck-button-save{margin-top:var(--ck-spacing-medium)}.ck.ck-link-form_layout-vertical{min-width:var(--ck-input-width);padding:0}.ck.ck-link-form_layout-vertical .ck-labeled-field-view{margin:var(--ck-spacing-large) var(--ck-spacing-large) var(--ck-spacing-small)}.ck.ck-link-form_layout-vertical .ck-labeled-field-view .ck-input-text{min-width:0;width:100%}.ck.ck-link-form_layout-vertical>.ck-button{border-radius:0;margin:0;padding:var(--ck-spacing-standard);width:50%}.ck.ck-link-form_layout-vertical>.ck-button:not(:focus){border-top:1px solid var(--ck-color-base-border)}[dir=ltr] .ck.ck-link-form_layout-vertical>.ck-button,[dir=rtl] .ck.ck-link-form_layout-vertical>.ck-button{margin-left:0}[dir=rtl] .ck.ck-link-form_layout-vertical>.ck-button:last-of-type{border-right:1px solid var(--ck-color-base-border)}.ck.ck-link-form_layout-vertical .ck.ck-list{margin:0 var(--ck-spacing-large)}.ck.ck-link-form_layout-vertical .ck.ck-list .ck-button.ck-switchbutton{padding:0;width:100%}.ck.ck-link-form_layout-vertical .ck.ck-list .ck-button.ck-switchbutton:hover{background:none}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-link/theme/linkform.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-link/linkform.css"],names:[],mappings:"AAOA,iBAEC,sBAAuB,CADvB,YAkBD,CAfC,2BACC,YACD,CCPA,oCDCD,iBASE,cAUF,CARE,wCACC,eACD,CAEA,4BACC,cACD,CChBD,CDwBD,iCACC,aAYD,CALE,wHAEC,mCACD,CEhCF,iCAEC,+BAAgC,CADhC,SAgDD,CA7CC,wDACC,8EAMD,CAJC,uEACC,WAAY,CACZ,UACD,CAGD,4CAIC,eAAgB,CAFhB,QAAS,CADT,kCAAmC,CAEnC,SAkBD,CAfC,wDACC,gDACD,CARD,4GAeE,aAMF,CAJE,mEACC,kDACD,CAKF,6CACC,gCAUD,CARC,wEACC,SAAU,CACV,UAKD,CAHC,8EACC,eACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css";\n\n.ck.ck-link-form {\n\tdisplay: flex;\n\talign-items: flex-start;\n\n\t& .ck-label {\n\t\tdisplay: none;\n\t}\n\n\t@mixin ck-media-phone {\n\t\tflex-wrap: wrap;\n\n\t\t& .ck-labeled-field-view {\n\t\t\tflex-basis: 100%;\n\t\t}\n\n\t\t& .ck-button {\n\t\t\tflex-basis: 50%;\n\t\t}\n\t}\n}\n\n/*\n * Style link form differently when manual decorators are available.\n * See: https://github.com/ckeditor/ckeditor5-link/issues/186.\n */\n.ck.ck-link-form_layout-vertical {\n\tdisplay: block;\n\n\t/*\n\t * Whether the form is in the responsive mode or not, if there are decorator buttons\n\t * keep the top margin of action buttons medium.\n\t */\n\t& .ck-button {\n\t\t&.ck-button-save,\n\t\t&.ck-button-cancel {\n\t\t\tmargin-top: var(--ck-spacing-medium);\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@define-mixin ck-media-phone {\n\t@media screen and (max-width: 600px) {\n\t\t@mixin-content;\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n/*\n * Style link form differently when manual decorators are available.\n * See: https://github.com/ckeditor/ckeditor5-link/issues/186.\n */\n.ck.ck-link-form_layout-vertical {\n\tpadding: 0;\n\tmin-width: var(--ck-input-width);\n\n\t& .ck-labeled-field-view {\n\t\tmargin: var(--ck-spacing-large) var(--ck-spacing-large) var(--ck-spacing-small);\n\n\t\t& .ck-input-text {\n\t\t\tmin-width: 0;\n\t\t\twidth: 100%;\n\t\t}\n\t}\n\n\t& > .ck-button {\n\t\tpadding: var(--ck-spacing-standard);\n\t\tmargin: 0;\n\t\twidth: 50%;\n\t\tborder-radius: 0;\n\n\t\t&:not(:focus) {\n\t\t\tborder-top: 1px solid var(--ck-color-base-border);\n\t\t}\n\n\t\t@mixin ck-dir ltr {\n\t\t\tmargin-left: 0;\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\tmargin-left: 0;\n\n\t\t\t&:last-of-type {\n\t\t\t\tborder-right: 1px solid var(--ck-color-base-border);\n\t\t\t}\n\t\t}\n\t}\n\n\t/* Using additional `.ck` class for stronger CSS specificity than `.ck.ck-link-form > :not(:first-child)`. */\n\t& .ck.ck-list {\n\t\tmargin: 0 var(--ck-spacing-large);\n\n\t\t& .ck-button.ck-switchbutton {\n\t\t\tpadding: 0;\n\t\t\twidth: 100%;\n\n\t\t\t&:hover {\n\t\t\t\tbackground: none;\n\t\t\t}\n\t\t}\n\t}\n}\n'],sourceRoot:""}]);const a=s},3669:(e,t,o)=>{"use strict";o.d(t,{A:()=>h});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r),a=o(4417),l=o.n(a),c=new URL(o(2401),o.b),d=s()(i()),u=l()(c);d.push([e.id,`.ck.ck-editor__editable a span.image-inline:after,.ck.ck-editor__editable figure.image>a:after{display:block;position:absolute}:root{--ck-link-image-indicator-icon-size:20;--ck-link-image-indicator-icon-is-visible:clamp(0px,100% - 50px,1px)}.ck.ck-editor__editable a span.image-inline:after,.ck.ck-editor__editable figure.image>a:after{background-color:rgba(0,0,0,.4);background-image:url(${u});background-position:50%;background-repeat:no-repeat;background-size:14px;border-radius:100%;content:"";height:calc(var(--ck-link-image-indicator-icon-is-visible)*var(--ck-link-image-indicator-icon-size));overflow:hidden;right:min(var(--ck-spacing-medium),6%);top:min(var(--ck-spacing-medium),6%);width:calc(var(--ck-link-image-indicator-icon-is-visible)*var(--ck-link-image-indicator-icon-size))}`,"",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-link/theme/linkimage.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-link/linkimage.css"],names:[],mappings:"AASE,+FACC,aAAc,CACd,iBACD,CCPF,MAEC,sCAAuC,CACvC,oEACD,CAME,+FAUC,+BAAqC,CACrC,wDAA+3B,CAG/3B,uBAA2B,CAD3B,2BAA4B,CAD5B,oBAAqB,CAGrB,kBAAmB,CAdnB,UAAW,CAsBX,oGAAuG,CAFvG,eAAgB,CAbhB,sCAAwC,CADxC,oCAAsC,CAetC,mGAED",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-editor__editable {\n\t/* Linked image indicator */\n\t& figure.image > a,\n\t& a span.image-inline {\n\t\t&::after {\n\t\t\tdisplay: block;\n\t\t\tposition: absolute;\n\t\t}\n\t}\n}\n\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t/* Match the icon size with the upload indicator brought by the image upload feature. */\n\t--ck-link-image-indicator-icon-size: 20;\n\t--ck-link-image-indicator-icon-is-visible: clamp(0px, 100% - 50px, 1px);\n}\n\n.ck.ck-editor__editable {\n\t/* Linked image indicator */\n\t& figure.image > a,\n\t& a span.image-inline {\n\t\t&::after {\n\t\t\tcontent: "";\n\n\t\t\t/*\n\t\t\t * Smaller images should have the icon closer to the border.\n\t\t\t * Match the icon position with the upload indicator brought by the image upload feature.\n\t\t\t */\n\t\t\ttop: min(var(--ck-spacing-medium), 6%);\n\t\t\tright: min(var(--ck-spacing-medium), 6%);\n\n\t\t\tbackground-color: hsla(0, 0%, 0%, .4);\n\t\t\tbackground-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjAgMjAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZmlsbD0iI2ZmZiIgZD0ibTExLjA3NyAxNSAuOTkxLTEuNDE2YS43NS43NSAwIDEgMSAxLjIyOS44NmwtMS4xNDggMS42NGEuNzQ4Ljc0OCAwIDAgMS0uMjE3LjIwNiA1LjI1MSA1LjI1MSAwIDAgMS04LjUwMy01Ljk1NS43NDEuNzQxIDAgMCAxIC4xMi0uMjc0bDEuMTQ3LTEuNjM5YS43NS43NSAwIDEgMSAxLjIyOC44Nkw0LjkzMyAxMC43bC4wMDYuMDAzYTMuNzUgMy43NSAwIDAgMCA2LjEzMiA0LjI5NGwuMDA2LjAwNHptNS40OTQtNS4zMzVhLjc0OC43NDggMCAwIDEtLjEyLjI3NGwtMS4xNDcgMS42MzlhLjc1Ljc1IDAgMSAxLTEuMjI4LS44NmwuODYtMS4yM2EzLjc1IDMuNzUgMCAwIDAtNi4xNDQtNC4zMDFsLS44NiAxLjIyOWEuNzUuNzUgMCAwIDEtMS4yMjktLjg2bDEuMTQ4LTEuNjRhLjc0OC43NDggMCAwIDEgLjIxNy0uMjA2IDUuMjUxIDUuMjUxIDAgMCAxIDguNTAzIDUuOTU1em0tNC41NjMtMi41MzJhLjc1Ljc1IDAgMCAxIC4xODQgMS4wNDVsLTMuMTU1IDQuNTA1YS43NS43NSAwIDEgMS0xLjIyOS0uODZsMy4xNTUtNC41MDZhLjc1Ljc1IDAgMCAxIDEuMDQ1LS4xODR6Ii8+PC9zdmc+");\n\t\t\tbackground-size: 14px;\n\t\t\tbackground-repeat: no-repeat;\n\t\t\tbackground-position: center;\n\t\t\tborder-radius: 100%;\n\n\t\t\t/*\n\t\t\t* Use CSS math to simulate container queries.\n\t\t\t* https://css-tricks.com/the-raven-technique-one-step-closer-to-container-queries/#what-about-showing-and-hiding-things\n\t\t\t*/\n\t\t\toverflow: hidden;\n\t\t\twidth: calc(var(--ck-link-image-indicator-icon-is-visible) * var(--ck-link-image-indicator-icon-size));\n\t\t\theight: calc(var(--ck-link-image-indicator-icon-is-visible) * var(--ck-link-image-indicator-icon-size));\n\t\t}\n\t}\n}\n\n'],sourceRoot:""}]);const h=d},7875:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck-editor__editable .ck-list-bogus-paragraph{display:block}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-list/theme/documentlist.css"],names:[],mappings:"AAKA,8CACC,aACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck-editor__editable .ck-list-bogus-paragraph {\n\tdisplay: block;\n}\n"],sourceRoot:""}]);const a=s},532:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck-content ol{list-style-type:decimal}.ck-content ol ol{list-style-type:lower-latin}.ck-content ol ol ol{list-style-type:lower-roman}.ck-content ol ol ol ol{list-style-type:upper-latin}.ck-content ol ol ol ol ol{list-style-type:upper-roman}.ck-content ul{list-style-type:disc}.ck-content ul ul{list-style-type:circle}.ck-content ul ul ul,.ck-content ul ul ul ul{list-style-type:square}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-list/theme/list.css"],names:[],mappings:"AAKA,eACC,uBAiBD,CAfC,kBACC,2BAaD,CAXC,qBACC,2BASD,CAPC,wBACC,2BAKD,CAHC,2BACC,2BACD,CAMJ,eACC,oBAaD,CAXC,kBACC,sBASD,CAJE,6CACC,sBACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck-content ol {\n\tlist-style-type: decimal;\n\n\t& ol {\n\t\tlist-style-type: lower-latin;\n\n\t\t& ol {\n\t\t\tlist-style-type: lower-roman;\n\n\t\t\t& ol {\n\t\t\t\tlist-style-type: upper-latin;\n\n\t\t\t\t& ol {\n\t\t\t\t\tlist-style-type: upper-roman;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}\n\n.ck-content ul {\n\tlist-style-type: disc;\n\n\t& ul {\n\t\tlist-style-type: circle;\n\n\t\t& ul {\n\t\t\tlist-style-type: square;\n\n\t\t\t& ul {\n\t\t\t\tlist-style-type: square;\n\t\t\t}\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},1911:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-list-properties.ck-list-properties_without-styles{padding:var(--ck-spacing-large)}.ck.ck-list-properties.ck-list-properties_without-styles>*{min-width:14em}.ck.ck-list-properties.ck-list-properties_without-styles>*+*{margin-top:var(--ck-spacing-standard)}.ck.ck-list-properties.ck-list-properties_with-numbered-properties>.ck-list-styles-list{grid-template-columns:repeat(4,auto)}.ck.ck-list-properties.ck-list-properties_with-numbered-properties>.ck-collapsible{border-top:1px solid var(--ck-color-base-border)}.ck.ck-list-properties.ck-list-properties_with-numbered-properties>.ck-collapsible>.ck-collapsible__children>*{width:100%}.ck.ck-list-properties.ck-list-properties_with-numbered-properties>.ck-collapsible>.ck-collapsible__children>*+*{margin-top:var(--ck-spacing-standard)}.ck.ck-list-properties .ck.ck-numbered-list-properties__start-index .ck-input{min-width:auto;width:100%}.ck.ck-list-properties .ck.ck-numbered-list-properties__reversed-order{background:transparent;margin-bottom:calc(var(--ck-spacing-tiny)*-1);padding-left:0;padding-right:0}.ck.ck-list-properties .ck.ck-numbered-list-properties__reversed-order:active,.ck.ck-list-properties .ck.ck-numbered-list-properties__reversed-order:hover{background:none;border-color:transparent;box-shadow:none}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-list/listproperties.css"],names:[],mappings:"AAOC,yDACC,+BASD,CAPC,2DACC,cAKD,CAHC,6DACC,qCACD,CASD,wFACC,oCACD,CAGA,mFACC,gDAWD,CARE,+GACC,UAKD,CAHC,iHACC,qCACD,CAMJ,8EACC,cAAe,CACf,UACD,CAEA,uEACC,sBAAuB,CAGvB,6CAAgD,CAFhD,cAAe,CACf,eAQD,CALC,2JAGC,eAAgB,CADhB,wBAAyB,CADzB,eAGD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-list-properties {\n\t/* When there are no list styles and there is no collapsible. */\n\t&.ck-list-properties_without-styles {\n\t\tpadding: var(--ck-spacing-large);\n\n\t\t& > * {\n\t\t\tmin-width: 14em;\n\n\t\t\t& + * {\n\t\t\t\tmargin-top: var(--ck-spacing-standard);\n\t\t\t}\n\t\t}\n\t}\n\n\t/*\n\t * When the numbered list property fields (start at, reversed) should be displayed,\n\t * more horizontal space is needed. Reconfigure the style grid to create that space.\n\t */\n\t&.ck-list-properties_with-numbered-properties {\n\t\t& > .ck-list-styles-list {\n\t\t\tgrid-template-columns: repeat( 4, auto );\n\t\t}\n\n\t\t/* When list styles are rendered and property fields are in a collapsible. */\n\t\t& > .ck-collapsible {\n\t\t\tborder-top: 1px solid var(--ck-color-base-border);\n\n\t\t\t& > .ck-collapsible__children {\n\t\t\t\t& > * {\n\t\t\t\t\twidth: 100%;\n\n\t\t\t\t\t& + * {\n\t\t\t\t\t\tmargin-top: var(--ck-spacing-standard);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t& .ck.ck-numbered-list-properties__start-index .ck-input {\n\t\tmin-width: auto;\n\t\twidth: 100%;\n\t}\n\n\t& .ck.ck-numbered-list-properties__reversed-order {\n\t\tbackground: transparent;\n\t\tpadding-left: 0;\n\t\tpadding-right: 0;\n\t\tmargin-bottom: calc(-1 * var(--ck-spacing-tiny));\n\n\t\t&:active, &:hover {\n\t\t\tbox-shadow: none;\n\t\t\tborder-color: transparent;\n\t\t\tbackground: none;\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},1330:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-list-styles-list{display:grid}:root{--ck-list-style-button-size:44px}.ck.ck-list-styles-list{column-gap:var(--ck-spacing-medium);grid-template-columns:repeat(3,auto);padding:var(--ck-spacing-large);row-gap:var(--ck-spacing-medium)}.ck.ck-list-styles-list .ck-button{box-sizing:content-box;margin:0;padding:0}.ck.ck-list-styles-list .ck-button,.ck.ck-list-styles-list .ck-button .ck-icon{height:var(--ck-list-style-button-size);width:var(--ck-list-style-button-size)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-list/theme/liststyles.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-list/liststyles.css"],names:[],mappings:"AAKA,wBACC,YACD,CCFA,MACC,gCACD,CAEA,wBAGC,mCAAoC,CAFpC,oCAAwC,CAGxC,+BAAgC,CAFhC,gCA4BD,CAxBC,mCAiBC,sBAAuB,CAPvB,QAAS,CANT,SAmBD,CAJC,+EAhBA,uCAAwC,CADxC,sCAoBA",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-list-styles-list {\n\tdisplay: grid;\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-list-style-button-size: 44px;\n}\n\n.ck.ck-list-styles-list {\n\tgrid-template-columns: repeat( 3, auto );\n\trow-gap: var(--ck-spacing-medium);\n\tcolumn-gap: var(--ck-spacing-medium);\n\tpadding: var(--ck-spacing-large);\n\n\t& .ck-button {\n\t\t/* Make the button look like a thumbnail (the icon "takes it all"). */\n\t\twidth: var(--ck-list-style-button-size);\n\t\theight: var(--ck-list-style-button-size);\n\t\tpadding: 0;\n\n\t\t/*\n\t\t * Buttons are aligned by the grid so disable default button margins to not collide with the\n\t\t * gaps in the grid.\n\t\t */\n\t\tmargin: 0;\n\n\t\t/*\n\t\t * Make sure the button border (which is displayed on focus, BTW) does not steal pixels\n\t\t * from the button dimensions and, as a result, decrease the size of the icon\n\t\t * (which becomes blurry as it scales down).\n\t\t */\n\t\tbox-sizing: content-box;\n\n\t\t& .ck-icon {\n\t\t\twidth: var(--ck-list-style-button-size);\n\t\t\theight: var(--ck-list-style-button-size);\n\t\t}\n\t}\n}\n'],sourceRoot:""}]);const a=s},5484:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,':root{--ck-todo-list-checkmark-size:16px}.ck-content .todo-list{list-style:none}.ck-content .todo-list li{margin-bottom:5px;position:relative}.ck-content .todo-list li .todo-list{margin-top:5px}.ck-content .todo-list .todo-list__label>input{-webkit-appearance:none;border:0;display:inline-block;height:var(--ck-todo-list-checkmark-size);left:-25px;margin-left:0;margin-right:-15px;position:relative;right:0;vertical-align:middle;width:var(--ck-todo-list-checkmark-size)}.ck-content[dir=rtl] .todo-list .todo-list__label>input{left:0;margin-left:-15px;margin-right:0;right:-25px}.ck-content .todo-list .todo-list__label>input:before{border:1px solid #333;border-radius:2px;box-sizing:border-box;content:"";display:block;height:100%;position:absolute;transition:box-shadow .25s ease-in-out;width:100%}@media (prefers-reduced-motion:reduce){.ck-content .todo-list .todo-list__label>input:before{transition:none}}.ck-content .todo-list .todo-list__label>input:after{border-color:transparent;border-style:solid;border-width:0 calc(var(--ck-todo-list-checkmark-size)/8) calc(var(--ck-todo-list-checkmark-size)/8) 0;box-sizing:content-box;content:"";display:block;height:calc(var(--ck-todo-list-checkmark-size)/2.6);left:calc(var(--ck-todo-list-checkmark-size)/3);pointer-events:none;position:absolute;top:calc(var(--ck-todo-list-checkmark-size)/5.3);transform:rotate(45deg);width:calc(var(--ck-todo-list-checkmark-size)/5.3)}.ck-content .todo-list .todo-list__label>input[checked]:before{background:#26ab33;border-color:#26ab33}.ck-content .todo-list .todo-list__label>input[checked]:after{border-color:#fff}.ck-content .todo-list .todo-list__label .todo-list__label__description{vertical-align:middle}.ck-content .todo-list .todo-list__label.todo-list__label_without-description input[type=checkbox]{position:absolute}.ck-editor__editable.ck-content .todo-list .todo-list__label>input,.ck-editor__editable.ck-content .todo-list .todo-list__label>span[contenteditable=false]>input{cursor:pointer}.ck-editor__editable.ck-content .todo-list .todo-list__label>input:hover:before,.ck-editor__editable.ck-content .todo-list .todo-list__label>span[contenteditable=false]>input:hover:before{box-shadow:0 0 0 5px rgba(0,0,0,.1)}.ck-editor__editable.ck-content .todo-list .todo-list__label>span[contenteditable=false]>input{-webkit-appearance:none;border:0;display:inline-block;height:var(--ck-todo-list-checkmark-size);left:-25px;margin-left:0;margin-right:-15px;position:relative;right:0;vertical-align:middle;width:var(--ck-todo-list-checkmark-size)}.ck-editor__editable.ck-content[dir=rtl] .todo-list .todo-list__label>span[contenteditable=false]>input{left:0;margin-left:-15px;margin-right:0;right:-25px}.ck-editor__editable.ck-content .todo-list .todo-list__label>span[contenteditable=false]>input:before{border:1px solid #333;border-radius:2px;box-sizing:border-box;content:"";display:block;height:100%;position:absolute;transition:box-shadow .25s ease-in-out;width:100%}@media (prefers-reduced-motion:reduce){.ck-editor__editable.ck-content .todo-list .todo-list__label>span[contenteditable=false]>input:before{transition:none}}.ck-editor__editable.ck-content .todo-list .todo-list__label>span[contenteditable=false]>input:after{border-color:transparent;border-style:solid;border-width:0 calc(var(--ck-todo-list-checkmark-size)/8) calc(var(--ck-todo-list-checkmark-size)/8) 0;box-sizing:content-box;content:"";display:block;height:calc(var(--ck-todo-list-checkmark-size)/2.6);left:calc(var(--ck-todo-list-checkmark-size)/3);pointer-events:none;position:absolute;top:calc(var(--ck-todo-list-checkmark-size)/5.3);transform:rotate(45deg);width:calc(var(--ck-todo-list-checkmark-size)/5.3)}.ck-editor__editable.ck-content .todo-list .todo-list__label>span[contenteditable=false]>input[checked]:before{background:#26ab33;border-color:#26ab33}.ck-editor__editable.ck-content .todo-list .todo-list__label>span[contenteditable=false]>input[checked]:after{border-color:#fff}.ck-editor__editable.ck-content .todo-list .todo-list__label.todo-list__label_without-description input[type=checkbox]{position:absolute}',"",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-list/theme/todolist.css"],names:[],mappings:"AAKA,MACC,kCACD,CA4EA,uBACC,eAwBD,CAtBC,0BAEC,iBAAkB,CADlB,iBAMD,CAHC,qCACC,cACD,CAIA,+CAtFD,uBAAwB,CAQxB,QAAS,CAPT,oBAAqB,CAGrB,yCAA0C,CAO1C,UAAW,CAGX,aAAc,CAFd,kBAAmB,CAVnB,iBAAkB,CAWlB,OAAQ,CARR,qBAAsB,CAFtB,wCAqFC,CAFA,wDApEA,MAAO,CAGP,iBAAkB,CAFlB,cAAe,CACf,WAoEA,CAhED,sDAOC,qBAAiC,CACjC,iBAAkB,CALlB,qBAAsB,CACtB,UAAW,CAHX,aAAc,CAKd,WAAY,CAJZ,iBAAkB,CAOlB,sCAAwC,CAJxC,UASD,CAHC,uCAXD,sDAYE,eAEF,CADC,CAGD,qDAaC,wBAAyB,CADzB,kBAAmB,CAEnB,sGAA+G,CAX/G,sBAAuB,CAEvB,UAAW,CAJX,aAAc,CAUd,mDAAwD,CAHxD,+CAAoD,CAJpD,mBAAoB,CAFpB,iBAAkB,CAOlB,gDAAqD,CAMrD,uBAAwB,CALxB,kDAMD,CAGC,+DACC,kBAA8B,CAC9B,oBACD,CAEA,8DACC,iBACD,CAwBA,wEACC,qBACD,CAEA,mGACC,iBACD,CAYD,kKAEC,cAKD,CAHC,4LACC,mCACD,CAMD,+FAxHA,uBAAwB,CAQxB,QAAS,CAPT,oBAAqB,CAGrB,yCAA0C,CAO1C,UAAW,CAGX,aAAc,CAFd,kBAAmB,CAVnB,iBAAkB,CAWlB,OAAQ,CARR,qBAAsB,CAFtB,wCAuHA,CAFA,wGAtGC,MAAO,CAGP,iBAAkB,CAFlB,cAAe,CACf,WAsGD,CAlGA,sGAOC,qBAAiC,CACjC,iBAAkB,CALlB,qBAAsB,CACtB,UAAW,CAHX,aAAc,CAKd,WAAY,CAJZ,iBAAkB,CAOlB,sCAAwC,CAJxC,UASD,CAHC,uCAXD,sGAYE,eAEF,CADC,CAGD,qGAaC,wBAAyB,CADzB,kBAAmB,CAEnB,sGAA+G,CAX/G,sBAAuB,CAEvB,UAAW,CAJX,aAAc,CAUd,mDAAwD,CAHxD,+CAAoD,CAJpD,mBAAoB,CAFpB,iBAAkB,CAOlB,gDAAqD,CAMrD,uBAAwB,CALxB,kDAMD,CAGC,+GACC,kBAA8B,CAC9B,oBACD,CAEA,8GACC,iBACD,CA2DA,uHACC,iBACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-todo-list-checkmark-size: 16px;\n}\n\n@define-mixin todo-list-checkbox {\n\t-webkit-appearance: none;\n\tdisplay: inline-block;\n\tposition: relative;\n\twidth: var(--ck-todo-list-checkmark-size);\n\theight: var(--ck-todo-list-checkmark-size);\n\tvertical-align: middle;\n\n\t/* Needed on iOS */\n\tborder: 0;\n\n\t/* LTR styles */\n\tleft: -25px;\n\tmargin-right: -15px;\n\tright: 0;\n\tmargin-left: 0;\n\n\t/* RTL styles */\n\t@nest [dir=rtl]& {\n\t\tleft: 0;\n\t\tmargin-right: 0;\n\t\tright: -25px;\n\t\tmargin-left: -15px;\n\t}\n\n\t&::before {\n\t\tdisplay: block;\n\t\tposition: absolute;\n\t\tbox-sizing: border-box;\n\t\tcontent: '';\n\t\twidth: 100%;\n\t\theight: 100%;\n\t\tborder: 1px solid hsl(0, 0%, 20%);\n\t\tborder-radius: 2px;\n\t\ttransition: 250ms ease-in-out box-shadow;\n\n\t\t@media (prefers-reduced-motion: reduce) {\n\t\t\ttransition: none;\n\t\t}\n\t}\n\n\t&::after {\n\t\tdisplay: block;\n\t\tposition: absolute;\n\t\tbox-sizing: content-box;\n\t\tpointer-events: none;\n\t\tcontent: '';\n\n\t\t/* Calculate tick position, size and border-width proportional to the checkmark size. */\n\t\tleft: calc( var(--ck-todo-list-checkmark-size) / 3 );\n\t\ttop: calc( var(--ck-todo-list-checkmark-size) / 5.3 );\n\t\twidth: calc( var(--ck-todo-list-checkmark-size) / 5.3 );\n\t\theight: calc( var(--ck-todo-list-checkmark-size) / 2.6 );\n\t\tborder-style: solid;\n\t\tborder-color: transparent;\n\t\tborder-width: 0 calc( var(--ck-todo-list-checkmark-size) / 8 ) calc( var(--ck-todo-list-checkmark-size) / 8 ) 0;\n\t\ttransform: rotate(45deg);\n\t}\n\n\t&[checked] {\n\t\t&::before {\n\t\t\tbackground: hsl(126, 64%, 41%);\n\t\t\tborder-color: hsl(126, 64%, 41%);\n\t\t}\n\n\t\t&::after {\n\t\t\tborder-color: hsl(0, 0%, 100%);\n\t\t}\n\t}\n}\n\n/*\n * To-do list content styles.\n */\n.ck-content .todo-list {\n\tlist-style: none;\n\n\t& li {\n\t\tposition: relative;\n\t\tmargin-bottom: 5px;\n\n\t\t& .todo-list {\n\t\t\tmargin-top: 5px;\n\t\t}\n\t}\n\n\t& .todo-list__label {\n\t\t& > input {\n\t\t\t@mixin todo-list-checkbox;\n\t\t}\n\n\t\t& .todo-list__label__description {\n\t\t\tvertical-align: middle;\n\t\t}\n\n\t\t&.todo-list__label_without-description input[type=checkbox] {\n\t\t\tposition: absolute;\n\t\t}\n\t}\n}\n\n/*\n * To-do list editing view styles.\n */\n.ck-editor__editable.ck-content .todo-list .todo-list__label {\n\t/*\n\t * To-do list should be interactive only during the editing\n\t * (https://github.com/ckeditor/ckeditor5/issues/2090).\n\t */\n\t& > input,\n\t& > span[contenteditable=false] > input {\n\t\tcursor: pointer;\n\n\t\t&:hover::before {\n\t\t\tbox-shadow: 0 0 0 5px hsla(0, 0%, 0%, 0.1);\n\t\t}\n\t}\n\n\t/*\n\t * Document Lists - editing view has an additional span around checkbox.\n\t */\n\t& > span[contenteditable=false] > input {\n\t\t@mixin todo-list-checkbox;\n\t}\n\n\t&.todo-list__label_without-description {\n\t\t& input[type=checkbox] {\n\t\t\tposition: absolute;\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},1478:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-color-mention-background:rgba(153,0,48,.1);--ck-color-mention-text:#990030}.ck-content .mention{background:var(--ck-color-mention-background);color:var(--ck-color-mention-text)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-mention/mention.css"],names:[],mappings:"AAKA,MACC,+CAAwD,CACxD,+BACD,CAEA,qBACC,6CAA8C,CAC9C,kCACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-color-mention-background: hsla(341, 100%, 30%, 0.1);\n\t--ck-color-mention-text: hsl(341, 100%, 30%);\n}\n\n.ck-content .mention {\n\tbackground: var(--ck-color-mention-background);\n\tcolor: var(--ck-color-mention-text);\n}\n"],sourceRoot:""}]);const a=s},7216:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-mention-list-max-height:300px}.ck.ck-mentions{max-height:var(--ck-mention-list-max-height);overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain}.ck.ck-mentions>.ck-list__item{flex-shrink:0;overflow:hidden}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-mention/theme/mentionui.css"],names:[],mappings:"AAKA,MACC,kCACD,CAEA,gBACC,4CAA6C,CAM7C,iBAAkB,CAJlB,eAAgB,CAMhB,2BAQD,CAJC,+BAEC,aAAc,CADd,eAED",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-mention-list-max-height: 300px;\n}\n\n.ck.ck-mentions {\n\tmax-height: var(--ck-mention-list-max-height);\n\n\toverflow-y: auto;\n\n\t/* Prevent unnecessary horizontal scrollbar in Safari\n\thttps://github.com/ckeditor/ckeditor5-mention/issues/41 */\n\toverflow-x: hidden;\n\n\toverscroll-behavior: contain;\n\n\t/* Prevent unnecessary vertical scrollbar in Safari\n\thttps://github.com/ckeditor/ckeditor5-mention/issues/41 */\n\t& > .ck-list__item {\n\t\toverflow: hidden;\n\t\tflex-shrink: 0;\n\t}\n}\n"],sourceRoot:""}]);const a=s},4307:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-input-color{display:flex;flex-direction:row-reverse;width:100%}.ck.ck-input-color>input.ck.ck-input-text{flex-grow:1;min-width:auto}.ck.ck-input-color>div.ck.ck-dropdown{min-width:auto}.ck.ck-input-color>div.ck.ck-dropdown>.ck-input-color__button .ck-dropdown__arrow{display:none}.ck.ck-input-color .ck.ck-input-color__button{display:flex}.ck.ck-input-color .ck.ck-input-color__button .ck.ck-input-color__button__preview{overflow:hidden;position:relative}.ck.ck-input-color .ck.ck-input-color__button .ck.ck-input-color__button__preview>.ck.ck-input-color__button__preview__no-color-indicator{display:block;position:absolute}[dir=ltr] .ck.ck-input-color>.ck.ck-input-text{border-bottom-right-radius:0;border-top-right-radius:0}[dir=rtl] .ck.ck-input-color>.ck.ck-input-text{border-bottom-left-radius:0;border-top-left-radius:0}.ck.ck-input-color>.ck.ck-input-text:focus{z-index:0}.ck.ck-input-color>.ck.ck-dropdown>.ck.ck-button.ck-input-color__button{padding:0}[dir=ltr] .ck.ck-input-color>.ck.ck-dropdown>.ck.ck-button.ck-input-color__button{border-bottom-left-radius:0;border-top-left-radius:0}[dir=ltr] .ck.ck-input-color>.ck.ck-dropdown>.ck.ck-button.ck-input-color__button:not(:focus){border-left:1px solid transparent}[dir=rtl] .ck.ck-input-color>.ck.ck-dropdown>.ck.ck-button.ck-input-color__button{border-bottom-right-radius:0;border-top-right-radius:0}[dir=rtl] .ck.ck-input-color>.ck.ck-dropdown>.ck.ck-button.ck-input-color__button:not(:focus){border-right:1px solid transparent}.ck.ck-input-color>.ck.ck-dropdown>.ck.ck-button.ck-input-color__button.ck-disabled{background:var(--ck-color-input-disabled-background)}.ck.ck-input-color>.ck.ck-dropdown>.ck.ck-button.ck-input-color__button>.ck.ck-input-color__button__preview{border-radius:0}.ck-rounded-corners .ck.ck-input-color>.ck.ck-dropdown>.ck.ck-button.ck-input-color__button>.ck.ck-input-color__button__preview,.ck.ck-input-color>.ck.ck-dropdown>.ck.ck-button.ck-input-color__button>.ck.ck-input-color__button__preview.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-input-color>.ck.ck-dropdown>.ck.ck-button.ck-input-color__button>.ck.ck-input-color__button__preview{border:1px solid var(--ck-color-input-border);height:20px;width:20px}.ck.ck-input-color>.ck.ck-dropdown>.ck.ck-button.ck-input-color__button>.ck.ck-input-color__button__preview>.ck.ck-input-color__button__preview__no-color-indicator{background:red;border-radius:2px;height:150%;left:50%;top:-30%;transform:rotate(45deg);transform-origin:50%;width:8%}.ck.ck-input-color .ck.ck-input-color__remove-color{border-bottom-left-radius:0;border-bottom-right-radius:0;padding:calc(var(--ck-spacing-standard)/2) var(--ck-spacing-standard);width:100%}.ck.ck-input-color .ck.ck-input-color__remove-color:not(:focus){border-bottom:1px solid var(--ck-color-input-border)}[dir=ltr] .ck.ck-input-color .ck.ck-input-color__remove-color{border-top-right-radius:0}[dir=rtl] .ck.ck-input-color .ck.ck-input-color__remove-color{border-top-left-radius:0}.ck.ck-input-color .ck.ck-input-color__remove-color .ck.ck-icon{margin-right:var(--ck-spacing-standard)}[dir=rtl] .ck.ck-input-color .ck.ck-input-color__remove-color .ck.ck-icon{margin-left:var(--ck-spacing-standard);margin-right:0}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-table/theme/colorinput.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-table/colorinput.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css"],names:[],mappings:"AAKA,mBAEC,YAAa,CACb,0BAA2B,CAF3B,UAgCD,CA5BC,0CAEC,WAAY,CADZ,cAED,CAEA,sCACC,cAMD,CAHC,kFACC,YACD,CAGD,8CAEC,YAWD,CATC,kFAEC,eAAgB,CADhB,iBAOD,CAJC,0IAEC,aAAc,CADd,iBAED,CC1BF,+CAGE,4BAA6B,CAD7B,yBAcF,CAhBA,+CAQE,2BAA4B,CAD5B,wBASF,CAHC,2CACC,SACD,CAIA,wEACC,SA0CD,CA3CA,kFAKE,2BAA4B,CAD5B,wBAuCF,CApCE,8FACC,iCACD,CATF,kFAcE,4BAA6B,CAD7B,yBA8BF,CA3BE,8FACC,kCACD,CAGD,oFACC,oDACD,CAEA,4GC1CF,eD2DE,CAjBA,+PCtCD,qCDuDC,CAjBA,4GAKC,6CAA8C,CAD9C,WAAY,CADZ,UAcD,CAVC,oKAKC,cAA6B,CAC7B,iBAAkB,CAHlB,WAAY,CADZ,QAAS,CADT,QAAS,CAMT,uBAAwB,CACxB,oBAAqB,CAJrB,QAKD,CAKH,oDAIC,2BAA4B,CAC5B,4BAA6B,CAH7B,qEAAwE,CADxE,UA0BD,CApBC,gEACC,oDACD,CATD,8DAYE,yBAeF,CA3BA,8DAgBE,wBAWF,CARC,gEACC,uCAMD,CAPA,0EAKE,sCAAuC,CADvC,cAGF",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-input-color {\n\twidth: 100%;\n\tdisplay: flex;\n\tflex-direction: row-reverse;\n\n\t& > input.ck.ck-input-text {\n\t\tmin-width: auto;\n\t\tflex-grow: 1;\n\t}\n\n\t& > div.ck.ck-dropdown {\n\t\tmin-width: auto;\n\n\t\t/* This dropdown has no arrow but a color preview instead. */\n\t\t& > .ck-input-color__button .ck-dropdown__arrow {\n\t\t\tdisplay: none;\n\t\t}\n\t}\n\n\t& .ck.ck-input-color__button {\n\t\t/* Resolving issue with misaligned buttons on Safari (see #10589) */\n\t\tdisplay: flex;\n\n\t\t& .ck.ck-input-color__button__preview {\n\t\t\tposition: relative;\n\t\t\toverflow: hidden;\n\n\t\t\t& > .ck.ck-input-color__button__preview__no-color-indicator {\n\t\t\t\tposition: absolute;\n\t\t\t\tdisplay: block;\n\t\t\t}\n\t\t}\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n@import "../mixins/_rounded.css";\n\n.ck.ck-input-color {\n\t& > .ck.ck-input-text {\n\t\t@mixin ck-dir ltr {\n\t\t\tborder-top-right-radius: 0;\n\t\t\tborder-bottom-right-radius: 0;\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\tborder-top-left-radius: 0;\n\t\t\tborder-bottom-left-radius: 0;\n\t\t}\n\n\t\t/* Make sure the focused input is always on top of the dropdown button so its\n\t\t outline and border are never cropped (also when the input is read-only). */\n\t\t&:focus {\n\t\t\tz-index: 0;\n\t\t}\n\t}\n\n\t& > .ck.ck-dropdown {\n\t\t& > .ck.ck-button.ck-input-color__button {\n\t\t\tpadding: 0;\n\n\t\t\t@mixin ck-dir ltr {\n\t\t\t\tborder-top-left-radius: 0;\n\t\t\t\tborder-bottom-left-radius: 0;\n\n\t\t\t\t&:not(:focus) {\n\t\t\t\t\tborder-left: 1px solid transparent;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t@mixin ck-dir rtl {\n\t\t\t\tborder-top-right-radius: 0;\n\t\t\t\tborder-bottom-right-radius: 0;\n\n\t\t\t\t&:not(:focus) {\n\t\t\t\t\tborder-right: 1px solid transparent;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t&.ck-disabled {\n\t\t\t\tbackground: var(--ck-color-input-disabled-background);\n\t\t\t}\n\n\t\t\t& > .ck.ck-input-color__button__preview {\n\t\t\t\t@mixin ck-rounded-corners;\n\n\t\t\t\twidth: 20px;\n\t\t\t\theight: 20px;\n\t\t\t\tborder: 1px solid var(--ck-color-input-border);\n\n\t\t\t\t& > .ck.ck-input-color__button__preview__no-color-indicator {\n\t\t\t\t\ttop: -30%;\n\t\t\t\t\tleft: 50%;\n\t\t\t\t\theight: 150%;\n\t\t\t\t\twidth: 8%;\n\t\t\t\t\tbackground: hsl(0, 100%, 50%);\n\t\t\t\t\tborder-radius: 2px;\n\t\t\t\t\ttransform: rotate(45deg);\n\t\t\t\t\ttransform-origin: 50%;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t& .ck.ck-input-color__remove-color {\n\t\twidth: 100%;\n\t\tpadding: calc(var(--ck-spacing-standard) / 2) var(--ck-spacing-standard);\n\n\t\tborder-bottom-left-radius: 0;\n\t\tborder-bottom-right-radius: 0;\n\n\t\t&:not(:focus) {\n\t\t\tborder-bottom: 1px solid var(--ck-color-input-border);\n\t\t}\n\n\t\t@mixin ck-dir ltr {\n\t\t\tborder-top-right-radius: 0;\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\tborder-top-left-radius: 0;\n\t\t}\n\n\t\t& .ck.ck-icon {\n\t\t\tmargin-right: var(--ck-spacing-standard);\n\n\t\t\t@mixin ck-dir rtl {\n\t\t\t\tmargin-right: 0;\n\t\t\t\tmargin-left: var(--ck-spacing-standard);\n\t\t\t}\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n"],sourceRoot:""}]);const a=s},1806:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-form{padding:0 0 var(--ck-spacing-large)}.ck.ck-form:focus{outline:none}.ck.ck-form .ck.ck-input-text{min-width:100%;width:0}.ck.ck-form .ck.ck-dropdown{min-width:100%}.ck.ck-form .ck.ck-dropdown .ck-dropdown__button:not(:focus){border:1px solid var(--ck-color-base-border)}.ck.ck-form .ck.ck-dropdown .ck-dropdown__button .ck-button__label{width:100%}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-table/form.css"],names:[],mappings:"AAKA,YACC,mCAyBD,CAvBC,kBAEC,YACD,CAEA,8BACC,cAAe,CACf,OACD,CAEA,4BACC,cAWD,CARE,6DACC,4CACD,CAEA,mEACC,UACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-form {\n\tpadding: 0 0 var(--ck-spacing-large);\n\n\t&:focus {\n\t\t/* See: https://github.com/ckeditor/ckeditor5/issues/4773 */\n\t\toutline: none;\n\t}\n\n\t& .ck.ck-input-text {\n\t\tmin-width: 100%;\n\t\twidth: 0;\n\t}\n\n\t& .ck.ck-dropdown {\n\t\tmin-width: 100%;\n\n\t\t& .ck-dropdown__button {\n\t\t\t&:not(:focus) {\n\t\t\t\tborder: 1px solid var(--ck-color-base-border);\n\t\t\t}\n\n\t\t\t& .ck-button__label {\n\t\t\t\twidth: 100%;\n\t\t\t}\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},6016:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-form__row{display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:space-between}.ck.ck-form__row>:not(.ck-label){flex-grow:1}.ck.ck-form__row.ck-table-form__action-row .ck-button-cancel,.ck.ck-form__row.ck-table-form__action-row .ck-button-save{justify-content:center}.ck.ck-form__row{padding:var(--ck-spacing-standard) var(--ck-spacing-large) 0}[dir=ltr] .ck.ck-form__row>:not(.ck-label)+*{margin-left:var(--ck-spacing-large)}[dir=rtl] .ck.ck-form__row>:not(.ck-label)+*{margin-right:var(--ck-spacing-large)}.ck.ck-form__row>.ck-label{min-width:100%;width:100%}.ck.ck-form__row.ck-table-form__action-row{margin-top:var(--ck-spacing-large)}.ck.ck-form__row.ck-table-form__action-row .ck-button .ck-button__label{color:var(--ck-color-text)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-table/theme/formrow.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-table/formrow.css"],names:[],mappings:"AAKA,iBACC,YAAa,CACb,kBAAmB,CACnB,gBAAiB,CACjB,6BAaD,CAVC,iCACC,WACD,CAGC,wHAEC,sBACD,CCbF,iBACC,4DA2BD,CAvBE,6CAEE,mCAMF,CARA,6CAME,oCAEF,CAGD,2BAEC,cAAe,CADf,UAED,CAEA,2CACC,kCAKD,CAHC,wEACC,0BACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-form__row {\n\tdisplay: flex;\n\tflex-direction: row;\n\tflex-wrap: nowrap;\n\tjustify-content: space-between;\n\n\t/* Ignore labels that work as fieldset legends */\n\t& > *:not(.ck-label) {\n\t\tflex-grow: 1;\n\t}\n\n\t&.ck-table-form__action-row {\n\t\t& .ck-button-save,\n\t\t& .ck-button-cancel {\n\t\t\tjustify-content: center;\n\t\t}\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n.ck.ck-form__row {\n\tpadding: var(--ck-spacing-standard) var(--ck-spacing-large) 0;\n\n\t/* Ignore labels that work as fieldset legends */\n\t& > *:not(.ck-label) {\n\t\t& + * {\n\t\t\t@mixin ck-dir ltr {\n\t\t\t\tmargin-left: var(--ck-spacing-large);\n\t\t\t}\n\n\t\t\t@mixin ck-dir rtl {\n\t\t\t\tmargin-right: var(--ck-spacing-large);\n\t\t\t}\n\t\t}\n\t}\n\n\t& > .ck-label {\n\t\twidth: 100%;\n\t\tmin-width: 100%;\n\t}\n\n\t&.ck-table-form__action-row {\n\t\tmargin-top: var(--ck-spacing-large);\n\n\t\t& .ck-button .ck-button__label {\n\t\t\tcolor: var(--ck-color-text);\n\t\t}\n\t}\n}\n'],sourceRoot:""}]);const a=s},8603:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck .ck-insert-table-dropdown__grid{display:flex;flex-direction:row;flex-wrap:wrap}:root{--ck-insert-table-dropdown-padding:10px;--ck-insert-table-dropdown-box-height:11px;--ck-insert-table-dropdown-box-width:12px;--ck-insert-table-dropdown-box-margin:1px}.ck .ck-insert-table-dropdown__grid{padding:var(--ck-insert-table-dropdown-padding) var(--ck-insert-table-dropdown-padding) 0;width:calc(var(--ck-insert-table-dropdown-box-width)*10 + var(--ck-insert-table-dropdown-box-margin)*20 + var(--ck-insert-table-dropdown-padding)*2)}.ck .ck-insert-table-dropdown__label,.ck[dir=rtl] .ck-insert-table-dropdown__label{text-align:center}.ck .ck-insert-table-dropdown-grid-box{border:1px solid var(--ck-color-base-border);border-radius:1px;margin:var(--ck-insert-table-dropdown-box-margin);min-height:var(--ck-insert-table-dropdown-box-height);min-width:var(--ck-insert-table-dropdown-box-width);outline:none;transition:none}@media (prefers-reduced-motion:reduce){.ck .ck-insert-table-dropdown-grid-box{transition:none}}.ck .ck-insert-table-dropdown-grid-box:focus{box-shadow:none}.ck .ck-insert-table-dropdown-grid-box.ck-on{background:var(--ck-color-focus-outer-shadow);border-color:var(--ck-color-focus-border)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-table/theme/inserttable.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-table/inserttable.css"],names:[],mappings:"AAKA,oCACC,YAAa,CACb,kBAAmB,CACnB,cACD,CCJA,MACC,uCAAwC,CACxC,0CAA2C,CAC3C,yCAA0C,CAC1C,yCACD,CAEA,oCAGC,yFAA0F,CAD1F,oJAED,CAEA,mFAEC,iBACD,CAEA,uCAIC,4CAA6C,CAC7C,iBAAkB,CAFlB,iDAAkD,CADlD,qDAAsD,CADtD,mDAAoD,CAKpD,YAAa,CACb,eAcD,CAZC,uCATD,uCAUE,eAWF,CAVC,CAEA,6CACC,eACD,CAEA,6CAEC,6CAA8C,CAD9C,yCAED",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck .ck-insert-table-dropdown__grid {\n\tdisplay: flex;\n\tflex-direction: row;\n\tflex-wrap: wrap;\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-insert-table-dropdown-padding: 10px;\n\t--ck-insert-table-dropdown-box-height: 11px;\n\t--ck-insert-table-dropdown-box-width: 12px;\n\t--ck-insert-table-dropdown-box-margin: 1px;\n}\n\n.ck .ck-insert-table-dropdown__grid {\n\t/* The width of a container should match 10 items in a row so there will be a 10x10 grid. */\n\twidth: calc(var(--ck-insert-table-dropdown-box-width) * 10 + var(--ck-insert-table-dropdown-box-margin) * 20 + var(--ck-insert-table-dropdown-padding) * 2);\n\tpadding: var(--ck-insert-table-dropdown-padding) var(--ck-insert-table-dropdown-padding) 0;\n}\n\n.ck .ck-insert-table-dropdown__label,\n.ck[dir=rtl] .ck-insert-table-dropdown__label {\n\ttext-align: center;\n}\n\n.ck .ck-insert-table-dropdown-grid-box {\n\tmin-width: var(--ck-insert-table-dropdown-box-width);\n\tmin-height: var(--ck-insert-table-dropdown-box-height);\n\tmargin: var(--ck-insert-table-dropdown-box-margin);\n\tborder: 1px solid var(--ck-color-base-border);\n\tborder-radius: 1px;\n\toutline: none;\n\ttransition: none;\n\n\t@media (prefers-reduced-motion: reduce) {\n\t\ttransition: none;\n\t}\n\n\t&:focus {\n\t\tbox-shadow: none;\n\t}\n\n\t&.ck-on {\n\t\tborder-color: var(--ck-color-focus-border);\n\t\tbackground: var(--ck-color-focus-outer-shadow);\n\t}\n}\n\n"],sourceRoot:""}]);const a=s},9969:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck-content .table{display:table;margin:.9em auto}.ck-content .table table{border:1px double #b3b3b3;border-collapse:collapse;border-spacing:0;height:100%;width:100%}.ck-content .table table td,.ck-content .table table th{border:1px solid #bfbfbf;min-width:2em;padding:.4em}.ck-content .table table th{background:rgba(0,0,0,.05);font-weight:700}.ck-content[dir=rtl] .table th{text-align:right}.ck-content[dir=ltr] .table th{text-align:left}.ck-editor__editable .ck-table-bogus-paragraph{display:inline-block;width:100%}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-table/theme/table.css"],names:[],mappings:"AAKA,mBAKC,aAAc,CADd,gBAiCD,CA9BC,yBAYC,yBAAkC,CAVlC,wBAAyB,CACzB,gBAAiB,CAKjB,WAAY,CADZ,UAsBD,CAfC,wDAQC,wBAAiC,CANjC,aAAc,CACd,YAMD,CAEA,4BAEC,0BAA+B,CAD/B,eAED,CAMF,+BACC,gBACD,CAEA,+BACC,eACD,CAEA,+CAKC,oBAAqB,CAMrB,UACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck-content .table {\n\t/* Give the table widget some air and center it horizontally */\n\t/* The first value should be equal to --ck-spacing-large variable if used in the editor context\n\tto avoid the content jumping (See https://github.com/ckeditor/ckeditor5/issues/9825). */\n\tmargin: 0.9em auto;\n\tdisplay: table;\n\n\t& table {\n\t\t/* The table cells should have slight borders */\n\t\tborder-collapse: collapse;\n\t\tborder-spacing: 0;\n\n\t\t/* Table width and height are set on the parent
    . Make sure the table inside stretches\n\t\tto the full dimensions of the container (https://github.com/ckeditor/ckeditor5/issues/6186). */\n\t\twidth: 100%;\n\t\theight: 100%;\n\n\t\t/* The outer border of the table should be slightly darker than the inner lines.\n\t\tAlso see https://github.com/ckeditor/ckeditor5-table/issues/50. */\n\t\tborder: 1px double hsl(0, 0%, 70%);\n\n\t\t& td,\n\t\t& th {\n\t\t\tmin-width: 2em;\n\t\t\tpadding: .4em;\n\n\t\t\t/* The border is inherited from .ck-editor__nested-editable styles, so theoretically it\'s not necessary here.\n\t\t\tHowever, the border is a content style, so it should use .ck-content (so it works outside the editor).\n\t\t\tHence, the duplication. See https://github.com/ckeditor/ckeditor5/issues/6314 */\n\t\t\tborder: 1px solid hsl(0, 0%, 75%);\n\t\t}\n\n\t\t& th {\n\t\t\tfont-weight: bold;\n\t\t\tbackground: hsla(0, 0%, 0%, 5%);\n\t\t}\n\t}\n}\n\n/* Text alignment of the table header should match the editor settings and override the native browser styling,\nwhen content is available outside the editor. See https://github.com/ckeditor/ckeditor5/issues/6638 */\n.ck-content[dir="rtl"] .table th {\n\ttext-align: right;\n}\n\n.ck-content[dir="ltr"] .table th {\n\ttext-align: left;\n}\n\n.ck-editor__editable .ck-table-bogus-paragraph {\n\t/*\n\t * Use display:inline-block to force Chrome/Safari to limit text mutations to this element.\n\t * See https://github.com/ckeditor/ckeditor5/issues/6062.\n\t */\n\tdisplay: inline-block;\n\n\t/*\n\t * Inline HTML elements nested in the span should always be dimensioned in relation to the whole cell width.\n\t * See https://github.com/ckeditor/ckeditor5/issues/9117.\n\t */\n\twidth: 100%;\n}\n'],sourceRoot:""}]);const a=s},7406:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-color-selector-caption-background:#f7f7f7;--ck-color-selector-caption-text:#333;--ck-color-selector-caption-highlighted-background:#fd0}.ck-content .table>figcaption{background-color:var(--ck-color-selector-caption-background);caption-side:top;color:var(--ck-color-selector-caption-text);display:table-caption;font-size:.75em;outline-offset:-1px;padding:.6em;text-align:center;word-break:break-word}@media (forced-colors:active){.ck-content .table>figcaption{background-color:unset;color:unset}}@media (forced-colors:none){.ck.ck-editor__editable .table>figcaption.table__caption_highlighted{animation:ck-table-caption-highlight .6s ease-out}}.ck.ck-editor__editable .table>figcaption.ck-placeholder:before{overflow:hidden;padding-left:inherit;padding-right:inherit;text-overflow:ellipsis;white-space:nowrap}@keyframes ck-table-caption-highlight{0%{background-color:var(--ck-color-selector-caption-highlighted-background)}to{background-color:var(--ck-color-selector-caption-background)}}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-table/theme/tablecaption.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_mediacolors.css"],names:[],mappings:"AAOA,MACC,8CAAuD,CACvD,qCAAiD,CACjD,uDACD,CAGA,8BAMC,4DAA6D,CAJ7D,gBAAiB,CAGjB,2CAA4C,CAJ5C,qBAAsB,CAOtB,eAAgB,CAChB,mBAAoB,CAFpB,YAAa,CAHb,iBAAkB,CADlB,qBAaD,CCxBC,8BACC,8BDoBA,sBAAuB,CACvB,WCnBA,CACD,CAIA,4BDqBC,qEACC,iDACD,CCnBD,CDsBA,gEASC,eAAgB,CARhB,oBAAqB,CACrB,qBAAsB,CAQtB,sBAAuB,CAFvB,kBAGD,CAGD,sCACC,GACC,wEACD,CAEA,GACC,4DACD,CACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_mediacolors.css";\n\n:root {\n\t--ck-color-selector-caption-background: hsl(0, 0%, 97%);\n\t--ck-color-selector-caption-text: hsl(0, 0%, 20%);\n\t--ck-color-selector-caption-highlighted-background: hsl(52deg 100% 50%);\n}\n\n/* Content styles */\n.ck-content .table > figcaption {\n\tdisplay: table-caption;\n\tcaption-side: top;\n\tword-break: break-word;\n\ttext-align: center;\n\tcolor: var(--ck-color-selector-caption-text);\n\tbackground-color: var(--ck-color-selector-caption-background);\n\tpadding: .6em;\n\tfont-size: .75em;\n\toutline-offset: -1px;\n\n\t/* Improve placeholder rendering in high-constrast mode (https://github.com/ckeditor/ckeditor5/issues/14907). */\n\t@mixin ck-media-forced-colors {\n\t\tbackground-color: unset;\n\t\tcolor: unset;\n\t}\n}\n\n/* Editing styles */\n.ck.ck-editor__editable .table > figcaption {\n\t@mixin ck-media-default-colors {\n\t\t&.table__caption_highlighted {\n\t\t\tanimation: ck-table-caption-highlight .6s ease-out;\n\t\t}\n\t}\n\n\t&.ck-placeholder::before {\n\t\tpadding-left: inherit;\n\t\tpadding-right: inherit;\n\n\t\t/*\n\t\t * Make sure the table caption placeholder doesn\'t overflow the placeholder area.\n\t\t * See https://github.com/ckeditor/ckeditor5/issues/9162.\n\t\t */\n\t\twhite-space: nowrap;\n\t\toverflow: hidden;\n\t\ttext-overflow: ellipsis;\n\t}\n}\n\n@keyframes ck-table-caption-highlight {\n\t0% {\n\t\tbackground-color: var(--ck-color-selector-caption-highlighted-background);\n\t}\n\n\t100% {\n\t\tbackground-color: var(--ck-color-selector-caption-background);\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@define-mixin ck-media-forced-colors {\n\t@media (forced-colors: active) {\n\t\t& {\n\t\t\t@mixin-content;\n\t\t}\n\t}\n}\n\n@define-mixin ck-media-default-colors {\n\t@media (forced-colors: none) {\n\t\t& {\n\t\t\t@mixin-content;\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},6701:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-table-cell-properties-form .ck-form__row.ck-table-cell-properties-form__alignment-row{flex-wrap:wrap}.ck.ck-table-cell-properties-form .ck-form__row.ck-table-cell-properties-form__alignment-row .ck.ck-toolbar:first-of-type{flex-grow:0.57}.ck.ck-table-cell-properties-form .ck-form__row.ck-table-cell-properties-form__alignment-row .ck.ck-toolbar:last-of-type{flex-grow:0.43}.ck.ck-table-cell-properties-form .ck-form__row.ck-table-cell-properties-form__alignment-row .ck.ck-toolbar .ck-button{flex-grow:1}.ck.ck-table-cell-properties-form{width:320px}.ck.ck-table-cell-properties-form .ck-form__row.ck-table-cell-properties-form__padding-row{align-self:flex-end;padding:0;width:25%}.ck.ck-table-cell-properties-form .ck-form__row.ck-table-cell-properties-form__alignment-row .ck.ck-toolbar{background:none;margin-top:var(--ck-spacing-standard)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-table/theme/tablecellproperties.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-table/tablecellproperties.css"],names:[],mappings:"AAOE,6FACC,cAiBD,CAdE,0HAEC,cACD,CAEA,yHAEC,cACD,CAEA,uHACC,WACD,CClBJ,kCACC,WAkBD,CAfE,2FACC,mBAAoB,CACpB,SAAU,CACV,SACD,CAGC,4GACC,eAAgB,CAGhB,qCACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-table-cell-properties-form {\n\t& .ck-form__row {\n\t\t&.ck-table-cell-properties-form__alignment-row {\n\t\t\tflex-wrap: wrap;\n\n\t\t\t& .ck.ck-toolbar {\n\t\t\t\t&:first-of-type {\n\t\t\t\t\t/* 4 buttons out of 7 (h-alignment + v-alignment) = 0.57 */\n\t\t\t\t\tflex-grow: 0.57;\n\t\t\t\t}\n\n\t\t\t\t&:last-of-type {\n\t\t\t\t\t/* 3 buttons out of 7 (h-alignment + v-alignment) = 0.43 */\n\t\t\t\t\tflex-grow: 0.43;\n\t\t\t\t}\n\n\t\t\t\t& .ck-button {\n\t\t\t\t\tflex-grow: 1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-table-cell-properties-form {\n\twidth: 320px;\n\n\t& .ck-form__row {\n\t\t&.ck-table-cell-properties-form__padding-row {\n\t\t\talign-self: flex-end;\n\t\t\tpadding: 0;\n\t\t\twidth: 25%;\n\t\t}\n\n\t\t&.ck-table-cell-properties-form__alignment-row {\n\t\t\t& .ck.ck-toolbar {\n\t\t\t\tbackground: none;\n\n\t\t\t\t/* Compensate for missing input label that would push the margin (toolbar has no inputs). */\n\t\t\t\tmargin-top: var(--ck-spacing-standard);\n\t\t\t}\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},4204:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-color-selector-column-resizer-hover:var(--ck-color-base-active);--ck-table-column-resizer-width:7px;--ck-table-column-resizer-position-offset:calc(var(--ck-table-column-resizer-width)*-0.5 - 0.5px)}.ck-content .table .ck-table-resized{table-layout:fixed}.ck-content .table table{overflow:hidden}.ck-content .table td,.ck-content .table th{overflow-wrap:break-word;position:relative}.ck.ck-editor__editable .table .ck-table-column-resizer{bottom:0;cursor:col-resize;position:absolute;right:var(--ck-table-column-resizer-position-offset);top:0;user-select:none;width:var(--ck-table-column-resizer-width);z-index:var(--ck-z-default)}.ck.ck-editor__editable .table[draggable] .ck-table-column-resizer,.ck.ck-editor__editable.ck-column-resize_disabled .table .ck-table-column-resizer{display:none}.ck.ck-editor__editable .table .ck-table-column-resizer:hover,.ck.ck-editor__editable .table .ck-table-column-resizer__active{background-color:var(--ck-color-selector-column-resizer-hover);bottom:-999999px;opacity:.25;top:-999999px}.ck.ck-editor__editable[dir=rtl] .table .ck-table-column-resizer{left:var(--ck-table-column-resizer-position-offset);right:unset}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-table/theme/tablecolumnresize.css"],names:[],mappings:"AAKA,MACC,oEAAqE,CACrE,mCAAoC,CAIpC,iGACD,CAEA,qCACC,kBACD,CAEA,yBACC,eACD,CAEA,4CAIC,wBAAyB,CACzB,iBACD,CAEA,wDAGC,QAAS,CAGT,iBAAkB,CALlB,iBAAkB,CAGlB,oDAAqD,CAFrD,KAAM,CAKN,gBAAiB,CAFjB,0CAA2C,CAG3C,2BACD,CAQA,qJACC,YACD,CAEA,8HAEC,8DAA+D,CAO/D,gBAAiB,CANjB,WAAa,CAKb,aAED,CAEA,iEACC,mDAAoD,CACpD,WACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-color-selector-column-resizer-hover: var(--ck-color-base-active);\n\t--ck-table-column-resizer-width: 7px;\n\n\t/* The offset used for absolute positioning of the resizer element, so that it is placed exactly above the cell border.\n\t The value is: minus half the width of the resizer decreased additionaly by the half the width of the border (0.5px). */\n\t--ck-table-column-resizer-position-offset: calc(var(--ck-table-column-resizer-width) * -0.5 - 0.5px);\n}\n\n.ck-content .table .ck-table-resized {\n\ttable-layout: fixed;\n}\n\n.ck-content .table table {\n\toverflow: hidden;\n}\n\n.ck-content .table td,\n.ck-content .table th {\n\t/* To prevent text overflowing beyond its cell when columns are resized by resize handler\n\t(https://github.com/ckeditor/ckeditor5/pull/14379#issuecomment-1589460978). */\n\toverflow-wrap: break-word;\n\tposition: relative;\n}\n\n.ck.ck-editor__editable .table .ck-table-column-resizer {\n\tposition: absolute;\n\ttop: 0;\n\tbottom: 0;\n\tright: var(--ck-table-column-resizer-position-offset);\n\twidth: var(--ck-table-column-resizer-width);\n\tcursor: col-resize;\n\tuser-select: none;\n\tz-index: var(--ck-z-default);\n}\n\n.ck.ck-editor__editable.ck-column-resize_disabled .table .ck-table-column-resizer {\n\tdisplay: none;\n}\n\n/* The resizer elements, which are extended to an extremely high height, break the drag & drop feature in Chrome. To make it work again,\n all resizers must be hidden while the table is dragged. */\n.ck.ck-editor__editable .table[draggable] .ck-table-column-resizer {\n\tdisplay: none;\n}\n\n.ck.ck-editor__editable .table .ck-table-column-resizer:hover,\n.ck.ck-editor__editable .table .ck-table-column-resizer__active {\n\tbackground-color: var(--ck-color-selector-column-resizer-hover);\n\topacity: 0.25;\n\t/* The resizer element resides in each cell so to occupy the entire height of the table, which is unknown from a CSS point of view,\n\t it is extended to an extremely high height. Even for screens with a very high pixel density, the resizer will fulfill its role as\n\t it should, i.e. for a screen of 476 ppi the total height of the resizer will take over 350 sheets of A4 format, which is totally\n\t unrealistic height for a single table. */\n\ttop: -999999px;\n\tbottom: -999999px;\n}\n\n.ck.ck-editor__editable[dir=rtl] .table .ck-table-column-resizer {\n\tleft: var(--ck-table-column-resizer-position-offset);\n\tright: unset;\n}\n"],sourceRoot:""}]);const a=s},8864:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-color-selector-focused-cell-background:rgba(158,201,250,.3)}.ck-widget.table td.ck-editor__nested-editable.ck-editor__nested-editable_focused,.ck-widget.table td.ck-editor__nested-editable:focus,.ck-widget.table th.ck-editor__nested-editable.ck-editor__nested-editable_focused,.ck-widget.table th.ck-editor__nested-editable:focus{background:var(--ck-color-selector-focused-cell-background);border-style:none;outline:1px solid var(--ck-color-focus-border);outline-offset:-1px}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-table/tableediting.css"],names:[],mappings:"AAKA,MACC,gEACD,CAKE,8QAGC,2DAA4D,CAK5D,iBAAkB,CAClB,8CAA+C,CAC/C,mBACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-color-selector-focused-cell-background: hsla(212, 90%, 80%, .3);\n}\n\n.ck-widget.table {\n\t& td,\n\t& th {\n\t\t&.ck-editor__nested-editable.ck-editor__nested-editable_focused,\n\t\t&.ck-editor__nested-editable:focus {\n\t\t\t/* A very slight background to highlight the focused cell */\n\t\t\tbackground: var(--ck-color-selector-focused-cell-background);\n\n\t\t\t/* Fixes the problem where surrounding cells cover the focused cell's border.\n\t\t\tIt does not fix the problem in all places but the UX is improved.\n\t\t\tSee https://github.com/ckeditor/ckeditor5-table/issues/29. */\n\t\t\tborder-style: none;\n\t\t\toutline: 1px solid var(--ck-color-focus-border);\n\t\t\toutline-offset: -1px; /* progressive enhancement - no IE support */\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},5704:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,'.ck.ck-table-form .ck-form__row.ck-table-form__background-row,.ck.ck-table-form .ck-form__row.ck-table-form__border-row{flex-wrap:wrap}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row{align-items:center;flex-wrap:wrap}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-labeled-field-view{align-items:center;display:flex;flex-direction:column-reverse}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-labeled-field-view .ck.ck-dropdown,.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-table-form__dimension-operator{flex-grow:0}.ck.ck-table-form .ck.ck-labeled-field-view{position:relative}.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status{bottom:calc(var(--ck-table-properties-error-arrow-size)*-1);left:50%;position:absolute;transform:translate(-50%,100%);z-index:1}.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status:after{content:"";left:50%;position:absolute;top:calc(var(--ck-table-properties-error-arrow-size)*-1);transform:translateX(-50%)}:root{--ck-table-properties-error-arrow-size:6px;--ck-table-properties-min-error-width:150px}.ck.ck-table-form .ck-form__row.ck-table-form__border-row .ck-labeled-field-view>.ck-label{font-size:var(--ck-font-size-tiny);text-align:center}.ck.ck-table-form .ck-form__row.ck-table-form__border-row .ck-table-form__border-style,.ck.ck-table-form .ck-form__row.ck-table-form__border-row .ck-table-form__border-width{max-width:80px;min-width:80px;width:80px}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row{padding:0}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-table-form__dimensions-row__height,.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-table-form__dimensions-row__width{margin:0}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-table-form__dimension-operator{align-self:flex-end;display:inline-block;height:var(--ck-ui-component-min-height);line-height:var(--ck-ui-component-min-height);margin:0 var(--ck-spacing-small)}.ck.ck-table-form .ck.ck-labeled-field-view{padding-top:var(--ck-spacing-standard)}.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status{border-radius:0}.ck-rounded-corners .ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status,.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status{background:var(--ck-color-base-error);color:var(--ck-color-base-background);min-width:var(--ck-table-properties-min-error-width);padding:var(--ck-spacing-small) var(--ck-spacing-medium);text-align:center}.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status:after{border-color:transparent transparent var(--ck-color-base-error) transparent;border-style:solid;border-width:0 var(--ck-table-properties-error-arrow-size) var(--ck-table-properties-error-arrow-size) var(--ck-table-properties-error-arrow-size)}.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status{animation:ck-table-form-labeled-view-status-appear .15s ease both}@media (prefers-reduced-motion:reduce){.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status{animation:none}}.ck.ck-table-form .ck.ck-labeled-field-view .ck-input.ck-error:not(:focus)+.ck.ck-labeled-field-view__status{display:none}@keyframes ck-table-form-labeled-view-status-appear{0%{opacity:0}to{opacity:1}}',"",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-table/theme/tableform.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-table/tableform.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css"],names:[],mappings:"AAWE,wHACC,cACD,CAEA,8DAEC,kBAAmB,CADnB,cAgBD,CAbC,qFAGC,kBAAmB,CAFnB,YAAa,CACb,6BAMD,CAEA,sMACC,WACD,CAIF,4CAEC,iBAoBD,CAlBC,8EAGC,2DAAgE,CADhE,QAAS,CADT,iBAAkB,CAGlB,8BAA+B,CAG/B,SAUD,CAPC,oFACC,UAAW,CAGX,QAAS,CAFT,iBAAkB,CAClB,wDAA6D,CAE7D,0BACD,CChDH,MACC,0CAA2C,CAC3C,2CACD,CAMI,2FACC,kCAAmC,CACnC,iBACD,CAGD,8KAIC,cAAe,CADf,cAAe,CADf,UAGD,CAGD,8DACC,SAcD,CAZC,yMAEC,QACD,CAEA,iGACC,mBAAoB,CACpB,oBAAqB,CACrB,wCAAyC,CACzC,6CAA8C,CAC9C,gCACD,CAIF,4CACC,sCA6BD,CA3BC,8ECxCD,eD6DC,CArBA,mMCpCA,qCDyDA,CArBA,8EAGC,qCAAsC,CACtC,qCAAsC,CAEtC,oDAAqD,CADrD,wDAAyD,CAEzD,iBAcD,CAXC,oFACC,2EAA4E,CAE5E,kBAAmB,CADnB,kJAED,CAdD,8EAgBC,iEAKD,CAHC,uCAlBD,8EAmBE,cAEF,CADC,CAID,6GACC,YACD,CAIF,oDACC,GACC,SACD,CAEA,GACC,SACD,CACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-table-form {\n\t& .ck-form__row {\n\t\t&.ck-table-form__border-row {\n\t\t\tflex-wrap: wrap;\n\t\t}\n\n\t\t&.ck-table-form__background-row {\n\t\t\tflex-wrap: wrap;\n\t\t}\n\n\t\t&.ck-table-form__dimensions-row {\n\t\t\tflex-wrap: wrap;\n\t\t\talign-items: center;\n\n\t\t\t& .ck-labeled-field-view {\n\t\t\t\tdisplay: flex;\n\t\t\t\tflex-direction: column-reverse;\n\t\t\t\talign-items: center;\n\n\t\t\t\t& .ck.ck-dropdown {\n\t\t\t\t\tflex-grow: 0;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t& .ck-table-form__dimension-operator {\n\t\t\t\tflex-grow: 0;\n\t\t\t}\n\t\t}\n\t}\n\n\t& .ck.ck-labeled-field-view {\n\t\t/* Allow absolute positioning of the status (error) balloons. */\n\t\tposition: relative;\n\n\t\t& .ck.ck-labeled-field-view__status {\n\t\t\tposition: absolute;\n\t\t\tleft: 50%;\n\t\t\tbottom: calc( -1 * var(--ck-table-properties-error-arrow-size) );\n\t\t\ttransform: translate(-50%,100%);\n\n\t\t\t/* Make sure the balloon status stays on top of other form elements. */\n\t\t\tz-index: 1;\n\n\t\t\t/* The arrow pointing towards the field. */\n\t\t\t&::after {\n\t\t\t\tcontent: "";\n\t\t\t\tposition: absolute;\n\t\t\t\ttop: calc( -1 * var(--ck-table-properties-error-arrow-size) );\n\t\t\t\tleft: 50%;\n\t\t\t\ttransform: translateX( -50% );\n\t\t\t}\n\t\t}\n\t}\n}\n','/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../mixins/_rounded.css";\n\n:root {\n\t--ck-table-properties-error-arrow-size: 6px;\n\t--ck-table-properties-min-error-width: 150px;\n}\n\n.ck.ck-table-form {\n\t& .ck-form__row {\n\t\t&.ck-table-form__border-row {\n\t\t\t& .ck-labeled-field-view {\n\t\t\t\t& > .ck-label {\n\t\t\t\t\tfont-size: var(--ck-font-size-tiny);\n\t\t\t\t\ttext-align: center;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t& .ck-table-form__border-style,\n\t\t\t& .ck-table-form__border-width {\n\t\t\t\twidth: 80px;\n\t\t\t\tmin-width: 80px;\n\t\t\t\tmax-width: 80px;\n\t\t\t}\n\t\t}\n\n\t\t&.ck-table-form__dimensions-row {\n\t\t\tpadding: 0;\n\n\t\t\t& .ck-table-form__dimensions-row__width,\n\t\t\t& .ck-table-form__dimensions-row__height {\n\t\t\t\tmargin: 0\n\t\t\t}\n\n\t\t\t& .ck-table-form__dimension-operator {\n\t\t\t\talign-self: flex-end;\n\t\t\t\tdisplay: inline-block;\n\t\t\t\theight: var(--ck-ui-component-min-height);\n\t\t\t\tline-height: var(--ck-ui-component-min-height);\n\t\t\t\tmargin: 0 var(--ck-spacing-small);\n\t\t\t}\n\t\t}\n\t}\n\n\t& .ck.ck-labeled-field-view {\n\t\tpadding-top: var(--ck-spacing-standard);\n\n\t\t& .ck.ck-labeled-field-view__status {\n\t\t\t@mixin ck-rounded-corners;\n\n\t\t\tbackground: var(--ck-color-base-error);\n\t\t\tcolor: var(--ck-color-base-background);\n\t\t\tpadding: var(--ck-spacing-small) var(--ck-spacing-medium);\n\t\t\tmin-width: var(--ck-table-properties-min-error-width);\n\t\t\ttext-align: center;\n\n\t\t\t/* The arrow pointing towards the field. */\n\t\t\t&::after {\n\t\t\t\tborder-color: transparent transparent var(--ck-color-base-error) transparent;\n\t\t\t\tborder-width: 0 var(--ck-table-properties-error-arrow-size) var(--ck-table-properties-error-arrow-size) var(--ck-table-properties-error-arrow-size);\n\t\t\t\tborder-style: solid;\n\t\t\t}\n\n\t\t\tanimation: ck-table-form-labeled-view-status-appear .15s ease both;\n\n\t\t\t@media (prefers-reduced-motion: reduce) {\n\t\t\t\tanimation: none;\n\t\t\t}\n\t\t}\n\n\t\t/* Hide the error balloon when the field is blurred. Makes the experience much more clear. */\n\t\t& .ck-input.ck-error:not(:focus) + .ck.ck-labeled-field-view__status {\n\t\t\tdisplay: none;\n\t\t}\n\t}\n}\n\n@keyframes ck-table-form-labeled-view-status-appear {\n\t0% {\n\t\topacity: 0;\n\t}\n\n\t100% {\n\t\topacity: 1;\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n"],sourceRoot:""}]);const a=s},4001:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-table-properties-form .ck-form__row.ck-table-properties-form__alignment-row{align-content:baseline;flex-basis:0;flex-wrap:wrap}.ck.ck-table-properties-form .ck-form__row.ck-table-properties-form__alignment-row .ck.ck-toolbar .ck-toolbar__items{flex-wrap:nowrap}.ck.ck-table-properties-form{width:320px}.ck.ck-table-properties-form .ck-form__row.ck-table-properties-form__alignment-row{align-self:flex-end;padding:0}.ck.ck-table-properties-form .ck-form__row.ck-table-properties-form__alignment-row .ck.ck-toolbar{background:none;margin-top:var(--ck-spacing-standard)}.ck.ck-table-properties-form .ck-form__row.ck-table-properties-form__alignment-row .ck.ck-toolbar .ck-toolbar__items>*{width:40px}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-table/theme/tableproperties.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-table/tableproperties.css"],names:[],mappings:"AAOE,mFAGC,sBAAuB,CADvB,YAAa,CADb,cAOD,CAHC,qHACC,gBACD,CCTH,6BACC,WAmBD,CAhBE,mFACC,mBAAoB,CACpB,SAYD,CAVC,kGACC,eAAgB,CAGhB,qCAKD,CAHC,uHACC,UACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-table-properties-form {\n\t& .ck-form__row {\n\t\t&.ck-table-properties-form__alignment-row {\n\t\t\tflex-wrap: wrap;\n\t\t\tflex-basis: 0;\n\t\t\talign-content: baseline;\n\n\t\t\t& .ck.ck-toolbar .ck-toolbar__items {\n\t\t\t\tflex-wrap: nowrap;\n\t\t\t}\n\t\t}\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-table-properties-form {\n\twidth: 320px;\n\n\t& .ck-form__row {\n\t\t&.ck-table-properties-form__alignment-row {\n\t\t\talign-self: flex-end;\n\t\t\tpadding: 0;\n\n\t\t\t& .ck.ck-toolbar {\n\t\t\t\tbackground: none;\n\n\t\t\t\t/* Compensate for missing input label that would push the margin (toolbar has no inputs). */\n\t\t\t\tmargin-top: var(--ck-spacing-standard);\n\n\t\t\t\t& .ck-toolbar__items > * {\n\t\t\t\t\twidth: 40px;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},2850:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,':root{--ck-table-selected-cell-background:rgba(158,207,250,.3)}.ck.ck-editor__editable .table table td.ck-editor__editable_selected,.ck.ck-editor__editable .table table th.ck-editor__editable_selected{box-shadow:unset;caret-color:transparent;outline:unset;position:relative}.ck.ck-editor__editable .table table td.ck-editor__editable_selected:after,.ck.ck-editor__editable .table table th.ck-editor__editable_selected:after{background-color:var(--ck-table-selected-cell-background);bottom:0;content:"";left:0;pointer-events:none;position:absolute;right:0;top:0}.ck.ck-editor__editable .table table td.ck-editor__editable_selected ::selection,.ck.ck-editor__editable .table table td.ck-editor__editable_selected:focus,.ck.ck-editor__editable .table table th.ck-editor__editable_selected ::selection,.ck.ck-editor__editable .table table th.ck-editor__editable_selected:focus{background-color:transparent}.ck.ck-editor__editable .table table td.ck-editor__editable_selected .ck-widget,.ck.ck-editor__editable .table table th.ck-editor__editable_selected .ck-widget{outline:unset}.ck.ck-editor__editable .table table td.ck-editor__editable_selected .ck-widget>.ck-widget__selection-handle,.ck.ck-editor__editable .table table th.ck-editor__editable_selected .ck-widget>.ck-widget__selection-handle{display:none}',"",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-table/tableselection.css"],names:[],mappings:"AAKA,MACC,wDACD,CAGC,0IAKC,gBAAiB,CAFjB,uBAAwB,CACxB,aAAc,CAFd,iBAiCD,CA3BC,sJAGC,yDAA0D,CAK1D,QAAS,CAPT,UAAW,CAKX,MAAO,CAJP,mBAAoB,CAEpB,iBAAkB,CAGlB,OAAQ,CAFR,KAID,CAEA,wTAEC,4BACD,CAMA,gKACC,aAKD,CAHC,0NACC,YACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-table-selected-cell-background: hsla(208, 90%, 80%, .3);\n}\n\n.ck.ck-editor__editable .table table {\n\t& td.ck-editor__editable_selected,\n\t& th.ck-editor__editable_selected {\n\t\tposition: relative;\n\t\tcaret-color: transparent;\n\t\toutline: unset;\n\t\tbox-shadow: unset;\n\n\t\t/* https://github.com/ckeditor/ckeditor5/issues/6446 */\n\t\t&:after {\n\t\t\tcontent: '';\n\t\t\tpointer-events: none;\n\t\t\tbackground-color: var(--ck-table-selected-cell-background);\n\t\t\tposition: absolute;\n\t\t\ttop: 0;\n\t\t\tleft: 0;\n\t\t\tright: 0;\n\t\t\tbottom: 0;\n\t\t}\n\n\t\t& ::selection,\n\t\t&:focus {\n\t\t\tbackground-color: transparent;\n\t\t}\n\n\t\t/*\n\t\t * To reduce the amount of noise, all widgets in the table selection have no outline and no selection handle.\n\t\t * See https://github.com/ckeditor/ckeditor5/issues/9491.\n\t\t */\n\t\t& .ck-widget {\n\t\t\toutline: unset;\n\n\t\t\t& > .ck-widget__selection-handle {\n\t\t\t\tdisplay: none;\n\t\t\t}\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},1710:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-aria-live-announcer{left:-10000px;position:absolute;top:-10000px}.ck.ck-aria-live-region-list{list-style-type:none}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/arialiveannouncer/arialiveannouncer.css"],names:[],mappings:"AAKA,2BAEC,aAAc,CADd,iBAAkB,CAElB,YACD,CAEA,6BACC,oBACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-aria-live-announcer {\n\tposition: absolute;\n\tleft: -10000px;\n\ttop: -10000px;\n}\n\n.ck.ck-aria-live-region-list {\n\tlist-style-type: none;\n}\n"],sourceRoot:""}]);const a=s},2688:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-autocomplete{position:relative}.ck.ck-autocomplete>.ck-search__results{position:absolute;z-index:var(--ck-z-panel)}.ck.ck-autocomplete>.ck-search__results.ck-search__results_n{bottom:100%}.ck.ck-autocomplete>.ck-search__results.ck-search__results_s{bottom:auto;top:100%}.ck.ck-autocomplete>.ck-search__results{border-radius:0}.ck-rounded-corners .ck.ck-autocomplete>.ck-search__results,.ck.ck-autocomplete>.ck-search__results.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-autocomplete>.ck-search__results{background:var(--ck-color-base-background);border:1px solid var(--ck-color-dropdown-panel-border);box-shadow:var(--ck-drop-shadow),0 0;max-height:200px;min-width:auto;overflow-y:auto}.ck.ck-autocomplete>.ck-search__results.ck-search__results_n{border-bottom-left-radius:0;border-bottom-right-radius:0;margin-bottom:-1px}.ck.ck-autocomplete>.ck-search__results.ck-search__results_s{border-top-left-radius:0;border-top-right-radius:0;margin-top:-1px}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/autocomplete/autocomplete.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/autocomplete/autocomplete.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css"],names:[],mappings:"AAKA,oBACC,iBAeD,CAbC,wCACC,iBAAkB,CAClB,yBAUD,CARC,6DACC,WACD,CAEA,6DAEC,WAAY,CADZ,QAED,CCVD,wCCEA,eDuBA,CAzBA,uHCMC,qCDmBD,CAzBA,wCAMC,0CAA2C,CAC3C,sDAAuD,CEPxD,oCAA8B,CFI7B,gBAAiB,CAIjB,cAAe,CAHf,eAoBD,CAfC,6DACC,2BAA4B,CAC5B,4BAA6B,CAG7B,kBACD,CAEA,6DACC,wBAAyB,CACzB,yBAA0B,CAG1B,eACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-autocomplete {\n\tposition: relative;\n\n\t& > .ck-search__results {\n\t\tposition: absolute;\n\t\tz-index: var(--ck-z-panel);\n\n\t\t&.ck-search__results_n {\n\t\t\tbottom: 100%;\n\t\t}\n\n\t\t&.ck-search__results_s {\n\t\t\ttop: 100%;\n\t\t\tbottom: auto;\n\t\t}\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css";\n@import "@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css";\n\n.ck.ck-autocomplete {\n\t& > .ck-search__results {\n\t\t@mixin ck-rounded-corners;\n\t\t@mixin ck-drop-shadow;\n\n\t\tmax-height: 200px;\n\t\toverflow-y: auto;\n\t\tbackground: var(--ck-color-base-background);\n\t\tborder: 1px solid var(--ck-color-dropdown-panel-border);\n\t\tmin-width: auto;\n\n\t\t&.ck-search__results_n {\n\t\t\tborder-bottom-left-radius: 0;\n\t\t\tborder-bottom-right-radius: 0;\n\n\t\t\t/* Prevent duplicated borders between the input and the results pane. */\n\t\t\tmargin-bottom: -1px;\n\t\t}\n\n\t\t&.ck-search__results_s {\n\t\t\tborder-top-left-radius: 0;\n\t\t\tborder-top-right-radius: 0;\n\n\t\t\t/* Prevent duplicated borders between the input and the results pane. */\n\t\t\tmargin-top: -1px;\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A helper to combine multiple shadows.\n */\n@define-mixin ck-box-shadow $shadowA, $shadowB: 0 0 {\n\tbox-shadow: $shadowA, $shadowB;\n}\n\n/**\n * Gives an element a drop shadow so it looks like a floating panel.\n */\n@define-mixin ck-drop-shadow {\n\t@mixin ck-box-shadow var(--ck-drop-shadow);\n}\n"],sourceRoot:""}]);const a=s},8948:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-button,a.ck.ck-button{align-items:center;display:inline-flex;position:relative;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}[dir=ltr] .ck.ck-button,[dir=ltr] a.ck.ck-button{justify-content:left}[dir=rtl] .ck.ck-button,[dir=rtl] a.ck.ck-button{justify-content:right}.ck.ck-button .ck-button__label,a.ck.ck-button .ck-button__label{display:none}.ck.ck-button.ck-button_with-text .ck-button__label,a.ck.ck-button.ck-button_with-text .ck-button__label{display:inline-block}.ck.ck-button:not(.ck-button_with-text),a.ck.ck-button:not(.ck-button_with-text){justify-content:center}.ck.ck-button,a.ck.ck-button{background:var(--ck-color-button-default-background)}.ck.ck-button:not(.ck-disabled):hover,a.ck.ck-button:not(.ck-disabled):hover{background:var(--ck-color-button-default-hover-background)}.ck.ck-button:not(.ck-disabled):active,a.ck.ck-button:not(.ck-disabled):active{background:var(--ck-color-button-default-active-background)}.ck.ck-button.ck-disabled,a.ck.ck-button.ck-disabled{background:var(--ck-color-button-default-disabled-background)}.ck.ck-button,a.ck.ck-button{border-radius:0}.ck-rounded-corners .ck.ck-button,.ck-rounded-corners a.ck.ck-button,.ck.ck-button.ck-rounded-corners,a.ck.ck-button.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-button,a.ck.ck-button{-webkit-appearance:none;border:1px solid transparent;cursor:default;font-size:inherit;line-height:1;min-height:var(--ck-ui-component-min-height);min-width:var(--ck-ui-component-min-height);padding:var(--ck-spacing-tiny);text-align:center;transition:box-shadow .2s ease-in-out,border .2s ease-in-out;vertical-align:middle;white-space:nowrap}@media (prefers-reduced-motion:reduce){.ck.ck-button,a.ck.ck-button{transition:none}}.ck.ck-button:active,.ck.ck-button:focus,a.ck.ck-button:active,a.ck.ck-button:focus{border:var(--ck-focus-ring);box-shadow:var(--ck-focus-outer-shadow),0 0;outline:none}.ck.ck-button .ck-button__icon use,.ck.ck-button .ck-button__icon use *,a.ck.ck-button .ck-button__icon use,a.ck.ck-button .ck-button__icon use *{color:inherit}.ck.ck-button .ck-button__label,a.ck.ck-button .ck-button__label{color:inherit;cursor:inherit;font-size:inherit;font-weight:inherit;vertical-align:middle}[dir=ltr] .ck.ck-button .ck-button__label,[dir=ltr] a.ck.ck-button .ck-button__label{text-align:left}[dir=rtl] .ck.ck-button .ck-button__label,[dir=rtl] a.ck.ck-button .ck-button__label{text-align:right}.ck.ck-button .ck-button__keystroke,a.ck.ck-button .ck-button__keystroke{color:inherit}[dir=ltr] .ck.ck-button .ck-button__keystroke,[dir=ltr] a.ck.ck-button .ck-button__keystroke{margin-left:var(--ck-spacing-large)}[dir=rtl] .ck.ck-button .ck-button__keystroke,[dir=rtl] a.ck.ck-button .ck-button__keystroke{margin-right:var(--ck-spacing-large)}.ck.ck-button .ck-button__keystroke,a.ck.ck-button .ck-button__keystroke{opacity:.5}.ck.ck-button.ck-disabled:active,.ck.ck-button.ck-disabled:focus,a.ck.ck-button.ck-disabled:active,a.ck.ck-button.ck-disabled:focus{box-shadow:var(--ck-focus-disabled-outer-shadow),0 0}.ck.ck-button.ck-disabled .ck-button__icon,.ck.ck-button.ck-disabled .ck-button__label,a.ck.ck-button.ck-disabled .ck-button__icon,a.ck.ck-button.ck-disabled .ck-button__label{opacity:var(--ck-disabled-opacity)}.ck.ck-button.ck-disabled .ck-button__keystroke,a.ck.ck-button.ck-disabled .ck-button__keystroke{opacity:.3}.ck.ck-button.ck-button_with-text,a.ck.ck-button.ck-button_with-text{padding:var(--ck-spacing-tiny) var(--ck-spacing-standard)}[dir=ltr] .ck.ck-button.ck-button_with-text .ck-button__icon,[dir=ltr] a.ck.ck-button.ck-button_with-text .ck-button__icon{margin-right:var(--ck-spacing-medium)}[dir=rtl] .ck.ck-button.ck-button_with-text .ck-button__icon,[dir=rtl] a.ck.ck-button.ck-button_with-text .ck-button__icon{margin-left:var(--ck-spacing-medium)}.ck.ck-button.ck-button_with-keystroke .ck-button__label,a.ck.ck-button.ck-button_with-keystroke .ck-button__label{flex-grow:1}.ck.ck-button.ck-on,a.ck.ck-button.ck-on{background:var(--ck-color-button-on-background)}.ck.ck-button.ck-on:not(.ck-disabled):hover,a.ck.ck-button.ck-on:not(.ck-disabled):hover{background:var(--ck-color-button-on-hover-background)}.ck.ck-button.ck-on:not(.ck-disabled):active,a.ck.ck-button.ck-on:not(.ck-disabled):active{background:var(--ck-color-button-on-active-background)}.ck.ck-button.ck-on.ck-disabled,a.ck.ck-button.ck-on.ck-disabled{background:var(--ck-color-button-on-disabled-background)}.ck.ck-button.ck-on,a.ck.ck-button.ck-on{color:var(--ck-color-button-on-color)}.ck.ck-button.ck-button-save,a.ck.ck-button.ck-button-save{color:var(--ck-color-button-save)}.ck.ck-button.ck-button-cancel,a.ck.ck-button.ck-button-cancel{color:var(--ck-color-button-cancel)}.ck.ck-button-action,a.ck.ck-button-action{background:var(--ck-color-button-action-background)}.ck.ck-button-action:not(.ck-disabled):hover,a.ck.ck-button-action:not(.ck-disabled):hover{background:var(--ck-color-button-action-hover-background)}.ck.ck-button-action:not(.ck-disabled):active,a.ck.ck-button-action:not(.ck-disabled):active{background:var(--ck-color-button-action-active-background)}.ck.ck-button-action.ck-disabled,a.ck.ck-button-action.ck-disabled{background:var(--ck-color-button-action-disabled-background)}.ck.ck-button-action,a.ck.ck-button-action{color:var(--ck-color-button-action-text)}.ck.ck-button-bold,a.ck.ck-button-bold{font-weight:700}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/button/button.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_unselectable.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/button/button.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/mixins/_button.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_focus.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_disabled.css"],names:[],mappings:"AAQA,6BAMC,kBAAmB,CADnB,mBAAoB,CADpB,iBAAkB,CCHlB,qBAAsB,CACtB,wBAAyB,CACzB,oBAAqB,CACrB,gBD0BD,CA9BA,iDASE,oBAqBF,CA9BA,iDAaE,qBAiBF,CAdC,iEACC,YACD,CAGC,yGACC,oBACD,CAID,iFACC,sBACD,CEzBD,6BCAC,oDD6ID,CC1IE,6EACC,0DACD,CAEA,+EACC,2DACD,CAID,qDACC,6DACD,CDfD,6BEDC,eF8ID,CA7IA,wIEGE,qCF0IF,CA7IA,6BA6BC,uBAAwB,CANxB,4BAA6B,CAjB7B,cAAe,CAcf,iBAAkB,CAHlB,aAAc,CAJd,4CAA6C,CAD7C,2CAA4C,CAJ5C,8BAA+B,CAC/B,iBAAkB,CAiBlB,4DAA8D,CAnB9D,qBAAsB,CAFtB,kBAwID,CA9GC,uCA/BD,6BAgCE,eA6GF,CA5GC,CAEA,oFGpCA,2BAA2B,CCF3B,2CAA8B,CDC9B,YHyCA,CAIC,kJAEC,aACD,CAGD,iEAIC,aAAc,CACd,cAAe,CAHf,iBAAkB,CAClB,mBAAoB,CAMpB,qBASD,CAlBA,qFAYE,eAMF,CAlBA,qFAgBE,gBAEF,CAEA,yEACC,aAWD,CAZA,6FAIE,mCAQF,CAZA,6FAQE,oCAIF,CAZA,yEAWC,UACD,CAIC,oIIxFD,oDJ4FC,CAOA,gLKnGD,kCLqGC,CAEA,iGACC,UACD,CAGD,qEACC,yDAYD,CATC,2HAEE,qCAMF,CARA,2HAME,oCAEF,CAKA,mHACC,WACD,CAID,yCChIA,+CDoIA,CCjIC,yFACC,qDACD,CAEA,2FACC,sDACD,CAID,iEACC,wDACD,CDiHA,yCAGC,qCACD,CAEA,2DACC,iCACD,CAEA,+DACC,mCACD,CAID,2CChJC,mDDqJD,CClJE,2FACC,yDACD,CAEA,6FACC,0DACD,CAID,mEACC,4DACD,CDiID,2CAIC,wCACD,CAEA,uCAEC,eACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../mixins/_unselectable.css";\n@import "../../mixins/_dir.css";\n\n.ck.ck-button,\na.ck.ck-button {\n\t@mixin ck-unselectable;\n\n\tposition: relative;\n\tdisplay: inline-flex;\n\talign-items: center;\n\n\t@mixin ck-dir ltr {\n\t\tjustify-content: left;\n\t}\n\n\t@mixin ck-dir rtl {\n\t\tjustify-content: right;\n\t}\n\n\t& .ck-button__label {\n\t\tdisplay: none;\n\t}\n\n\t&.ck-button_with-text {\n\t\t& .ck-button__label {\n\t\t\tdisplay: inline-block;\n\t\t}\n\t}\n\n\t/* Center the icon horizontally in a button without text. */\n\t&:not(.ck-button_with-text) {\n\t\tjustify-content: center;\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Makes element unselectable.\n */\n@define-mixin ck-unselectable {\n\t-moz-user-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n\tuser-select: none\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_focus.css";\n@import "../../../mixins/_shadow.css";\n@import "../../../mixins/_disabled.css";\n@import "../../../mixins/_rounded.css";\n@import "../../mixins/_button.css";\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n.ck.ck-button,\na.ck.ck-button {\n\t@mixin ck-button-colors --ck-color-button-default;\n\t@mixin ck-rounded-corners;\n\n\twhite-space: nowrap;\n\tcursor: default;\n\tvertical-align: middle;\n\tpadding: var(--ck-spacing-tiny);\n\ttext-align: center;\n\n\t/* A very important piece of styling. Go to variable declaration to learn more. */\n\tmin-width: var(--ck-ui-component-min-height);\n\tmin-height: var(--ck-ui-component-min-height);\n\n\t/* Normalize the height of the line. Removing this will break consistent height\n\tamong text and text-less buttons (with icons). */\n\tline-height: 1;\n\n\t/* Enable font size inheritance, which allows fluid UI scaling. */\n\tfont-size: inherit;\n\n\t/* Avoid flickering when the foucs border shows up. */\n\tborder: 1px solid transparent;\n\n\t/* Apply some smooth transition to the box-shadow and border. */\n\ttransition: box-shadow .2s ease-in-out, border .2s ease-in-out;\n\n\t/* https://github.com/ckeditor/ckeditor5-theme-lark/issues/189 */\n\t-webkit-appearance: none;\n\n\t@media (prefers-reduced-motion: reduce) {\n\t\ttransition: none;\n\t}\n\n\t&:active,\n\t&:focus {\n\t\t@mixin ck-focus-ring;\n\t\t@mixin ck-box-shadow var(--ck-focus-outer-shadow);\n\t}\n\n\t/* Allow icon coloring using the text "color" property. */\n\t& .ck-button__icon {\n\t\t& use,\n\t\t& use * {\n\t\t\tcolor: inherit;\n\t\t}\n\t}\n\n\t& .ck-button__label {\n\t\t/* Enable font size inheritance, which allows fluid UI scaling. */\n\t\tfont-size: inherit;\n\t\tfont-weight: inherit;\n\t\tcolor: inherit;\n\t\tcursor: inherit;\n\n\t\t/* Must be consistent with .ck-icon\'s vertical align. Otherwise, buttons with and\n\t\twithout labels (but with icons) have different sizes in Chrome */\n\t\tvertical-align: middle;\n\n\t\t@mixin ck-dir ltr {\n\t\t\ttext-align: left;\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\ttext-align: right;\n\t\t}\n\t}\n\n\t& .ck-button__keystroke {\n\t\tcolor: inherit;\n\n\t\t@mixin ck-dir ltr {\n\t\t\tmargin-left: var(--ck-spacing-large);\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\tmargin-right: var(--ck-spacing-large);\n\t\t}\n\n\t\topacity: .5;\n\t}\n\n\t/* https://github.com/ckeditor/ckeditor5-theme-lark/issues/70 */\n\t&.ck-disabled {\n\t\t&:active,\n\t\t&:focus {\n\t\t\t/* The disabled button should have a slightly less visible shadow when focused. */\n\t\t\t@mixin ck-box-shadow var(--ck-focus-disabled-outer-shadow);\n\t\t}\n\n\t\t& .ck-button__icon {\n\t\t\t@mixin ck-disabled;\n\t\t}\n\n\t\t/* https://github.com/ckeditor/ckeditor5-theme-lark/issues/98 */\n\t\t& .ck-button__label {\n\t\t\t@mixin ck-disabled;\n\t\t}\n\n\t\t& .ck-button__keystroke {\n\t\t\topacity: .3;\n\t\t}\n\t}\n\n\t&.ck-button_with-text {\n\t\tpadding: var(--ck-spacing-tiny) var(--ck-spacing-standard);\n\n\t\t/* stylelint-disable-next-line no-descending-specificity */\n\t\t& .ck-button__icon {\n\t\t\t@mixin ck-dir ltr {\n\t\t\t\tmargin-right: var(--ck-spacing-medium);\n\t\t\t}\n\n\t\t\t@mixin ck-dir rtl {\n\t\t\t\tmargin-left: var(--ck-spacing-medium);\n\t\t\t}\n\t\t}\n\t}\n\n\t&.ck-button_with-keystroke {\n\t\t/* stylelint-disable-next-line no-descending-specificity */\n\t\t& .ck-button__label {\n\t\t\tflex-grow: 1;\n\t\t}\n\t}\n\n\t/* A style of the button which is currently on, e.g. its feature is active. */\n\t&.ck-on {\n\t\t@mixin ck-button-colors --ck-color-button-on;\n\n\t\tcolor: var(--ck-color-button-on-color);\n\t}\n\n\t&.ck-button-save {\n\t\tcolor: var(--ck-color-button-save);\n\t}\n\n\t&.ck-button-cancel {\n\t\tcolor: var(--ck-color-button-cancel);\n\t}\n}\n\n/* A style of the button which handles the primary action. */\n.ck.ck-button-action,\na.ck.ck-button-action {\n\t@mixin ck-button-colors --ck-color-button-action;\n\n\tcolor: var(--ck-color-button-action-text);\n}\n\n.ck.ck-button-bold,\na.ck.ck-button-bold {\n\tfont-weight: bold;\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements a button of given background color.\n *\n * @param {String} $background - Background color of the button.\n * @param {String} $border - Border color of the button.\n */\n@define-mixin ck-button-colors $prefix {\n\tbackground: var($(prefix)-background);\n\n\t&:not(.ck-disabled) {\n\t\t&:hover {\n\t\t\tbackground: var($(prefix)-hover-background);\n\t\t}\n\n\t\t&:active {\n\t\t\tbackground: var($(prefix)-active-background);\n\t\t}\n\t}\n\n\t/* https://github.com/ckeditor/ckeditor5-theme-lark/issues/98 */\n\t&.ck-disabled {\n\t\tbackground: var($(prefix)-disabled-background);\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A visual style of focused element's border.\n */\n@define-mixin ck-focus-ring {\n\t/* Disable native outline. */\n\toutline: none;\n\tborder: var(--ck-focus-ring)\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A helper to combine multiple shadows.\n */\n@define-mixin ck-box-shadow $shadowA, $shadowB: 0 0 {\n\tbox-shadow: $shadowA, $shadowB;\n}\n\n/**\n * Gives an element a drop shadow so it looks like a floating panel.\n */\n@define-mixin ck-drop-shadow {\n\t@mixin ck-box-shadow var(--ck-drop-shadow);\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A class which indicates that an element holding it is disabled.\n */\n@define-mixin ck-disabled {\n\topacity: var(--ck-disabled-opacity);\n}\n"],sourceRoot:""}]);const a=s},3389:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-list-item-button{border-radius:0;min-height:unset;width:100%}[dir=ltr] .ck.ck-list-item-button{text-align:left}[dir=rtl] .ck.ck-list-item-button{text-align:right}[dir=ltr] .ck.ck-list-item-button.ck-list-item-button_toggleable{padding-left:var(--ck-spacing-small)}[dir=rtl] .ck.ck-list-item-button.ck-list-item-button_toggleable{padding-right:var(--ck-spacing-small)}.ck.ck-list-item-button .ck-list-item-button__check-holder{display:inline-flex;height:.9em;width:.9em}[dir=ltr] .ck.ck-list-item-button .ck-list-item-button__check-holder{margin-right:var(--ck-spacing-small)}[dir=rtl] .ck.ck-list-item-button .ck-list-item-button__check-holder{margin-left:var(--ck-spacing-small)}.ck.ck-list-item-button .ck-list-item-button__check-icon{height:100%}.ck.ck-button.ck-list-item-button{padding:var(--ck-spacing-tiny) calc(var(--ck-spacing-standard)*2)}.ck.ck-button.ck-list-item-button,.ck.ck-button.ck-list-item-button.ck-on{background:var(--ck-color-list-background);color:var(--ck-color-text)}[dir=ltr] .ck.ck-button.ck-list-item-button:has(.ck-list-item-button__check-holder){padding-left:var(--ck-spacing-small)}[dir=rtl] .ck.ck-button.ck-list-item-button:has(.ck-list-item-button__check-holder){padding-right:var(--ck-spacing-small)}.ck.ck-button.ck-list-item-button.ck-button.ck-on:hover,.ck.ck-button.ck-list-item-button.ck-on:hover,.ck.ck-button.ck-list-item-button.ck-on:not(.ck-list-item-button_toggleable),.ck.ck-button.ck-list-item-button:hover:not(.ck-disabled){background:var(--ck-color-list-button-hover-background)}.ck.ck-button.ck-list-item-button.ck-button.ck-on:hover:not(.ck-disabled),.ck.ck-button.ck-list-item-button.ck-on:hover:not(.ck-disabled),.ck.ck-button.ck-list-item-button.ck-on:not(.ck-list-item-button_toggleable):not(.ck-disabled),.ck.ck-button.ck-list-item-button:hover:not(.ck-disabled):not(.ck-disabled){color:var(--ck-color-text)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/button/listitembutton.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/button/listitembutton.css"],names:[],mappings:"AAOA,wBAGC,eAAgB,CAFhB,gBAAiB,CACjB,UAsCD,CAxCA,kCAME,eAkCF,CAxCA,kCAUE,gBA8BF,CA3BC,iEAEE,oCAMF,CARA,iEAME,qCAEF,CAEA,2DACC,mBAAoB,CAEpB,WAAY,CADZ,UAUD,CAZA,qEAME,oCAMF,CAZA,qEAUE,mCAEF,CAEA,yDACC,WACD,CCvCD,kCACC,iEAiCD,CA/BC,0EAEC,0CAA2C,CAC3C,0BACD,CAEA,oFAEE,oCAMF,CARA,oFAME,qCAEF,CAOA,6OAIC,uDAKD,CAHC,qTACC,0BACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../mixins/_dir.css";\n\n.ck.ck-list-item-button {\n\tmin-height: unset;\n\twidth: 100%;\n\tborder-radius: 0;\n\n\t@mixin ck-dir ltr {\n\t\ttext-align: left;\n\t}\n\n\t@mixin ck-dir rtl {\n\t\ttext-align: right;\n\t}\n\n\t&.ck-list-item-button_toggleable {\n\t\t@mixin ck-dir ltr {\n\t\t\tpadding-left: var(--ck-spacing-small);\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\tpadding-right: var(--ck-spacing-small);\n\t\t}\n\t}\n\n\t& .ck-list-item-button__check-holder {\n\t\tdisplay: inline-flex;\n\t\twidth: .9em;\n\t\theight: .9em;\n\n\t\t@mixin ck-dir ltr {\n\t\t\tmargin-right: var(--ck-spacing-small);\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\tmargin-left: var(--ck-spacing-small);\n\t\t}\n\t}\n\n\t& .ck-list-item-button__check-icon {\n\t\theight: 100%;\n\t}\n}\n','/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n.ck.ck-button.ck-list-item-button {\n\tpadding: var(--ck-spacing-tiny) calc(2 * var(--ck-spacing-standard));\n\n\t&,\n\t&.ck-on {\n\t\tbackground: var(--ck-color-list-background);\n\t\tcolor: var(--ck-color-text);\n\t}\n\n\t&:has(.ck-list-item-button__check-holder) {\n\t\t@mixin ck-dir ltr {\n\t\t\tpadding-left: var(--ck-spacing-small);\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\tpadding-right: var(--ck-spacing-small);\n\t\t}\n\t}\n\n\t/*\n\t * `.ck-on` class and background styling is overridden for `ck-button` in many places.\n\t * This is a workaround to make sure that the background is not overridden and uses similar\n\t * selector specificity as the other overrides.\n\t */\n\t&:hover:not(.ck-disabled),\n\t&.ck-button.ck-on:hover,\n\t&.ck-on:not(.ck-list-item-button_toggleable),\n\t&.ck-on:hover {\n\t\tbackground: var(--ck-color-list-button-hover-background);\n\n\t\t&:not(.ck-disabled) {\n\t\t\tcolor: var(--ck-color-text);\n\t\t}\n\t}\n}\n'],sourceRoot:""}]);const a=s},9624:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-button.ck-switchbutton .ck-button__toggle,.ck.ck-button.ck-switchbutton .ck-button__toggle .ck-button__toggle__inner{display:block}:root{--ck-switch-button-toggle-width:2.6153846154em;--ck-switch-button-toggle-inner-size:calc(1.07692em + 1px);--ck-switch-button-translation:calc(var(--ck-switch-button-toggle-width) - var(--ck-switch-button-toggle-inner-size) - 2px);--ck-switch-button-inner-hover-shadow:0 0 0 5px var(--ck-color-switch-button-inner-shadow)}.ck.ck-button.ck-switchbutton,.ck.ck-button.ck-switchbutton.ck-on:active,.ck.ck-button.ck-switchbutton.ck-on:focus,.ck.ck-button.ck-switchbutton.ck-on:hover,.ck.ck-button.ck-switchbutton:active,.ck.ck-button.ck-switchbutton:focus,.ck.ck-button.ck-switchbutton:hover{background:transparent;color:inherit}[dir=ltr] .ck.ck-button.ck-switchbutton .ck-button__label{margin-right:calc(var(--ck-spacing-large)*2)}[dir=rtl] .ck.ck-button.ck-switchbutton .ck-button__label{margin-left:calc(var(--ck-spacing-large)*2)}.ck.ck-button.ck-switchbutton .ck-button__toggle{border-radius:0}.ck-rounded-corners .ck.ck-button.ck-switchbutton .ck-button__toggle,.ck.ck-button.ck-switchbutton .ck-button__toggle.ck-rounded-corners{border-radius:var(--ck-border-radius)}[dir=ltr] .ck.ck-button.ck-switchbutton .ck-button__toggle{margin-left:auto}[dir=rtl] .ck.ck-button.ck-switchbutton .ck-button__toggle{margin-right:auto}.ck.ck-button.ck-switchbutton .ck-button__toggle{background:var(--ck-color-switch-button-off-background);border:1px solid transparent;transition:background .4s ease,box-shadow .2s ease-in-out,outline .2s ease-in-out;width:var(--ck-switch-button-toggle-width)}.ck.ck-button.ck-switchbutton .ck-button__toggle .ck-button__toggle__inner{border-radius:0}.ck-rounded-corners .ck.ck-button.ck-switchbutton .ck-button__toggle .ck-button__toggle__inner,.ck.ck-button.ck-switchbutton .ck-button__toggle .ck-button__toggle__inner.ck-rounded-corners{border-radius:var(--ck-border-radius);border-radius:calc(var(--ck-border-radius)*.5)}.ck.ck-button.ck-switchbutton .ck-button__toggle .ck-button__toggle__inner{background:var(--ck-color-switch-button-inner-background);height:var(--ck-switch-button-toggle-inner-size);transition:all .3s ease;width:var(--ck-switch-button-toggle-inner-size)}@media (prefers-reduced-motion:reduce){.ck.ck-button.ck-switchbutton .ck-button__toggle .ck-button__toggle__inner{transition:none}}.ck.ck-button.ck-switchbutton .ck-button__toggle:hover{background:var(--ck-color-switch-button-off-hover-background)}.ck.ck-button.ck-switchbutton .ck-button__toggle:hover .ck-button__toggle__inner{box-shadow:var(--ck-switch-button-inner-hover-shadow)}.ck.ck-button.ck-switchbutton.ck-disabled .ck-button__toggle{opacity:var(--ck-disabled-opacity)}.ck.ck-button.ck-switchbutton:focus{border-color:transparent;box-shadow:none;outline:none}.ck.ck-button.ck-switchbutton:focus .ck-button__toggle{box-shadow:0 0 0 1px var(--ck-color-base-background),0 0 0 5px var(--ck-color-focus-outer-shadow);outline:var(--ck-focus-ring);outline-offset:1px}.ck.ck-button.ck-switchbutton.ck-on .ck-button__toggle{background:var(--ck-color-switch-button-on-background)}.ck.ck-button.ck-switchbutton.ck-on .ck-button__toggle:hover{background:var(--ck-color-switch-button-on-hover-background)}[dir=ltr] .ck.ck-button.ck-switchbutton.ck-on .ck-button__toggle .ck-button__toggle__inner{transform:translateX(var( --ck-switch-button-translation ))}[dir=rtl] .ck.ck-button.ck-switchbutton.ck-on .ck-button__toggle .ck-button__toggle__inner{transform:translateX(calc(var( --ck-switch-button-translation )*-1))}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/button/switchbutton.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/button/switchbutton.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_disabled.css"],names:[],mappings:"AASE,4HACC,aACD,CCCF,MAEC,8CAA+C,CAE/C,0DAAgE,CAChE,2HAIC,CACD,0FACD,CAOC,0QAEC,sBAAuB,CADvB,aAED,CAEA,0DAGE,4CAOF,CAVA,0DAQE,2CAEF,CAEA,iDCpCA,eDgFA,CA5CA,yIChCC,qCD4ED,CA5CA,2DAKE,gBAuCF,CA5CA,2DAUE,iBAkCF,CA5CA,iDAkBC,uDAAwD,CAFxD,4BAA6B,CAD7B,iFAAsF,CAEtF,0CA2BD,CAxBC,2ECxDD,eDuEC,CAfA,6LCpDA,qCAAsC,CDsDpC,8CAaF,CAfA,2EAOC,yDAA0D,CAD1D,gDAAiD,CAIjD,uBAA0B,CAL1B,+CAUD,CAHC,uCAZD,2EAaE,eAEF,CADC,CAGD,uDACC,6DAKD,CAHC,iFACC,qDACD,CAIF,6DEpFA,kCFsFA,CAGA,oCACC,wBAAyB,CAEzB,eAAgB,CADhB,YAQD,CALC,uDACC,iGAAmG,CAEnG,4BAA6B,CAD7B,kBAED,CAKA,uDACC,sDAkBD,CAhBC,6DACC,4DACD,CAEA,2FAKE,2DAMF,CAXA,2FASE,oEAEF",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-button.ck-switchbutton {\n\t& .ck-button__toggle {\n\t\tdisplay: block;\n\n\t\t& .ck-button__toggle__inner {\n\t\t\tdisplay: block;\n\t\t}\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_rounded.css";\n@import "../../../mixins/_disabled.css";\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n/* Note: To avoid rendering issues (aliasing) but to preserve the responsive nature\nof the component, floating–point numbers have been used which, for the default font size\n(see: --ck-font-size-base), will generate simple integers. */\n:root {\n\t/* 34px at 13px font-size */\n\t--ck-switch-button-toggle-width: 2.6153846154em;\n\t/* 14px at 13px font-size */\n\t--ck-switch-button-toggle-inner-size: calc(1.0769230769em + 1px);\n\t--ck-switch-button-translation: calc(\n\t\tvar(--ck-switch-button-toggle-width) -\n\t\tvar(--ck-switch-button-toggle-inner-size) -\n\t\t2px /* Border */\n\t);\n\t--ck-switch-button-inner-hover-shadow: 0 0 0 5px var(--ck-color-switch-button-inner-shadow);\n}\n\n.ck.ck-button.ck-switchbutton {\n\t/* Unlike a regular button, the switch button text color and background should never change.\n\t * Changing toggle switch (background, outline) is enough to carry the information about the\n\t * state of the entire component (https://github.com/ckeditor/ckeditor5/issues/12519)\n\t */\n\t&, &:hover, &:focus, &:active, &.ck-on:hover, &.ck-on:focus, &.ck-on:active {\n\t\tcolor: inherit;\n\t\tbackground: transparent;\n\t}\n\n\t& .ck-button__label {\n\t\t@mixin ck-dir ltr {\n\t\t\t/* Separate the label from the switch */\n\t\t\tmargin-right: calc(2 * var(--ck-spacing-large));\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\t/* Separate the label from the switch */\n\t\t\tmargin-left: calc(2 * var(--ck-spacing-large));\n\t\t}\n\t}\n\n\t& .ck-button__toggle {\n\t\t@mixin ck-rounded-corners;\n\n\t\t@mixin ck-dir ltr {\n\t\t\t/* Make sure the toggle is always to the right as far as possible. */\n\t\t\tmargin-left: auto;\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\t/* Make sure the toggle is always to the left as far as possible. */\n\t\t\tmargin-right: auto;\n\t\t}\n\n\t\t/* Apply some smooth transition to the box-shadow and border. */\n\t\t/* Gently animate the background color of the toggle switch */\n\t\ttransition: background 400ms ease, box-shadow .2s ease-in-out, outline .2s ease-in-out;\n\t\tborder: 1px solid transparent;\n\t\twidth: var(--ck-switch-button-toggle-width);\n\t\tbackground: var(--ck-color-switch-button-off-background);\n\n\t\t& .ck-button__toggle__inner {\n\t\t\t@mixin ck-rounded-corners {\n\t\t\t\tborder-radius: calc(.5 * var(--ck-border-radius));\n\t\t\t}\n\n\t\t\twidth: var(--ck-switch-button-toggle-inner-size);\n\t\t\theight: var(--ck-switch-button-toggle-inner-size);\n\t\t\tbackground: var(--ck-color-switch-button-inner-background);\n\n\t\t\t/* Gently animate the inner part of the toggle switch */\n\t\t\ttransition: all 300ms ease;\n\n\t\t\t@media (prefers-reduced-motion: reduce) {\n\t\t\t\ttransition: none;\n\t\t\t}\n\t\t}\n\n\t\t&:hover {\n\t\t\tbackground: var(--ck-color-switch-button-off-hover-background);\n\n\t\t\t& .ck-button__toggle__inner {\n\t\t\t\tbox-shadow: var(--ck-switch-button-inner-hover-shadow);\n\t\t\t}\n\t\t}\n\t}\n\n\t&.ck-disabled .ck-button__toggle {\n\t\t@mixin ck-disabled;\n\t}\n\n\t/* Overriding default .ck-button:focus styles + an outline around the toogle */\n\t&:focus {\n\t\tborder-color: transparent;\n\t\toutline: none;\n\t\tbox-shadow: none;\n\n\t\t& .ck-button__toggle {\n\t\t\tbox-shadow: 0 0 0 1px var(--ck-color-base-background), 0 0 0 5px var(--ck-color-focus-outer-shadow);\n\t\t\toutline-offset: 1px;\n\t\t\toutline: var(--ck-focus-ring);\n\t\t}\n\t}\n\n\t/* stylelint-disable-next-line no-descending-specificity */\n\t&.ck-on {\n\t\t& .ck-button__toggle {\n\t\t\tbackground: var(--ck-color-switch-button-on-background);\n\n\t\t\t&:hover {\n\t\t\t\tbackground: var(--ck-color-switch-button-on-hover-background);\n\t\t\t}\n\n\t\t\t& .ck-button__toggle__inner {\n\t\t\t\t/*\n\t\t\t\t* Move the toggle switch to the right. It will be animated.\n\t\t\t\t*/\n\t\t\t\t@mixin ck-dir ltr {\n\t\t\t\t\ttransform: translateX( var( --ck-switch-button-translation ) );\n\t\t\t\t}\n\n\t\t\t\t@mixin ck-dir rtl {\n\t\t\t\t\ttransform: translateX( calc( -1 * var( --ck-switch-button-translation ) ) );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A class which indicates that an element holding it is disabled.\n */\n@define-mixin ck-disabled {\n\topacity: var(--ck-disabled-opacity);\n}\n"],sourceRoot:""}]);const a=s},1750:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-collapsible.ck-collapsible_collapsed>.ck-collapsible__children{display:none}:root{--ck-collapsible-arrow-size:calc(var(--ck-icon-size)*0.5)}.ck.ck-collapsible>.ck.ck-button{border-radius:0;color:inherit;font-weight:700;width:100%}.ck.ck-collapsible>.ck.ck-button:focus{background:transparent}.ck.ck-collapsible>.ck.ck-button:active,.ck.ck-collapsible>.ck.ck-button:hover:not(:focus),.ck.ck-collapsible>.ck.ck-button:not(:focus){background:transparent;border-color:transparent;box-shadow:none}.ck.ck-collapsible>.ck.ck-button>.ck-icon{margin-right:var(--ck-spacing-medium);width:var(--ck-collapsible-arrow-size)}.ck.ck-collapsible>.ck-collapsible__children{padding:var(--ck-spacing-medium) var(--ck-spacing-large) var(--ck-spacing-large)}.ck.ck-collapsible.ck-collapsible_collapsed>.ck.ck-button .ck-icon{transform:rotate(-90deg)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/collapsible/collapsible.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/collapsible/collapsible.css"],names:[],mappings:"AAMC,sEACC,YACD,CCHD,MACC,yDACD,CAGC,iCAGC,eAAgB,CAChB,aAAc,CAFd,eAAiB,CADjB,UAmBD,CAdC,uCACC,sBACD,CAEA,wIACC,sBAAuB,CACvB,wBAAyB,CACzB,eACD,CAEA,0CACC,qCAAsC,CACtC,sCACD,CAGD,6CACC,gFACD,CAGC,mEACC,wBACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-collapsible.ck-collapsible_collapsed {\n\t& > .ck-collapsible__children {\n\t\tdisplay: none;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-collapsible-arrow-size: calc(0.5 * var(--ck-icon-size));\n}\n\n.ck.ck-collapsible {\n\t& > .ck.ck-button {\n\t\twidth: 100%;\n\t\tfont-weight: bold;\n\t\tborder-radius: 0;\n\t\tcolor: inherit;\n\n\t\t&:focus {\n\t\t\tbackground: transparent;\n\t\t}\n\n\t\t&:active, &:not(:focus), &:hover:not(:focus) {\n\t\t\tbackground: transparent;\n\t\t\tborder-color: transparent;\n\t\t\tbox-shadow: none;\n\t\t}\n\n\t\t& > .ck-icon {\n\t\t\tmargin-right: var(--ck-spacing-medium);\n\t\t\twidth: var(--ck-collapsible-arrow-size);\n\t\t}\n\t}\n\n\t& > .ck-collapsible__children {\n\t\tpadding: var(--ck-spacing-medium) var(--ck-spacing-large) var(--ck-spacing-large);\n\t}\n\n\t&.ck-collapsible_collapsed {\n\t\t& > .ck.ck-button .ck-icon {\n\t\t\ttransform: rotate(-90deg);\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},7962:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-color-grid{display:grid}:root{--ck-color-grid-tile-size:24px;--ck-color-color-grid-check-icon:#166fd4}.ck.ck-color-grid{grid-gap:5px;padding:8px}.ck.ck-color-grid__tile{transition:box-shadow .2s ease}@media (forced-colors:none){.ck.ck-color-grid__tile{border:0;height:var(--ck-color-grid-tile-size);min-height:var(--ck-color-grid-tile-size);min-width:var(--ck-color-grid-tile-size);padding:0;width:var(--ck-color-grid-tile-size)}.ck.ck-color-grid__tile.ck-on,.ck.ck-color-grid__tile:focus:not(.ck-disabled),.ck.ck-color-grid__tile:hover:not(.ck-disabled){border:0}.ck.ck-color-grid__tile.ck-color-selector__color-tile_bordered{box-shadow:0 0 0 1px var(--ck-color-base-border)}.ck.ck-color-grid__tile.ck-on{box-shadow:inset 0 0 0 1px var(--ck-color-base-background),0 0 0 2px var(--ck-color-base-text)}.ck.ck-color-grid__tile:focus:not(.ck-disabled),.ck.ck-color-grid__tile:hover:not(.ck-disabled){box-shadow:inset 0 0 0 1px var(--ck-color-base-background),0 0 0 2px var(--ck-color-focus-border)}}@media (forced-colors:active){.ck.ck-color-grid__tile{height:unset;min-height:unset;min-width:unset;padding:0 var(--ck-spacing-small);width:unset}.ck.ck-color-grid__tile .ck-button__label{display:inline-block}}@media (prefers-reduced-motion:reduce){.ck.ck-color-grid__tile{transition:none}}.ck.ck-color-grid__tile.ck-disabled{cursor:unset;transition:unset}.ck.ck-color-grid__tile .ck.ck-icon{color:var(--ck-color-color-grid-check-icon);display:none}.ck.ck-color-grid__tile.ck-on .ck.ck-icon{display:block}.ck.ck-color-grid__label{padding:0 var(--ck-spacing-standard)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/colorgrid/colorgrid.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/colorgrid/colorgrid.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_mediacolors.css"],names:[],mappings:"AAKA,kBACC,YACD,CCCA,MACC,8BAA+B,CAK/B,wCACD,CAEA,kBACC,YAAa,CACb,WACD,CAEA,wBACC,8BAkED,CC3EC,4BACC,wBDgBA,QAAS,CAJT,qCAAsC,CAEtC,yCAA0C,CAD1C,wCAAyC,CAEzC,SAAU,CAJV,oCCTA,CDgBA,8HAIC,QACD,CAEA,+DACC,gDACD,CAEA,8BACC,8FACD,CAEA,gGAEC,iGACD,CCjCD,CAZA,8BACC,wBDqDA,YAAa,CAEb,gBAAiB,CADjB,eAAgB,CAEhB,iCAAkC,CAJlC,WClDA,CDwDA,0CACC,oBACD,CCzDD,CD4DA,uCAhDD,wBAiDE,eAkBF,CAjBC,CAEA,oCACC,YAAa,CACb,gBACD,CAEA,oCAEC,2CAA4C,CAD5C,YAED,CAGC,0CACC,aACD,CAIF,yBACC,oCACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-color-grid {\n\tdisplay: grid;\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_rounded.css";\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_mediacolors.css";\n\n:root {\n\t--ck-color-grid-tile-size: 24px;\n\n\t/* Not using global colors here because these may change but some colors in a pallette\n\t * require special treatment. For instance, this ensures no matter what the UI text color is,\n\t * the check icon will look good on the black color tile. */\n\t--ck-color-color-grid-check-icon: hsl(212, 81%, 46%);\n}\n\n.ck.ck-color-grid {\n\tgrid-gap: 5px;\n\tpadding: 8px;\n}\n\n.ck.ck-color-grid__tile {\n\ttransition: .2s ease box-shadow;\n\n\t@mixin ck-media-default-colors {\n\t\twidth: var(--ck-color-grid-tile-size);\n\t\theight: var(--ck-color-grid-tile-size);\n\t\tmin-width: var(--ck-color-grid-tile-size);\n\t\tmin-height: var(--ck-color-grid-tile-size);\n\t\tpadding: 0;\n\t\tborder: 0;\n\n\t\t&.ck-on,\n\t\t&:focus:not( .ck-disabled ),\n\t\t&:hover:not( .ck-disabled ) {\n\t\t\t/* Disable the default .ck-button\'s border ring. */\n\t\t\tborder: 0;\n\t\t}\n\n\t\t&.ck-color-selector__color-tile_bordered {\n\t\t\tbox-shadow: 0 0 0 1px var(--ck-color-base-border);\n\t\t}\n\n\t\t&.ck-on {\n\t\t\tbox-shadow: inset 0 0 0 1px var(--ck-color-base-background), 0 0 0 2px var(--ck-color-base-text);\n\t\t}\n\n\t\t&:focus:not( .ck-disabled ),\n\t\t&:hover:not( .ck-disabled ) {\n\t\t\tbox-shadow: inset 0 0 0 1px var(--ck-color-base-background), 0 0 0 2px var(--ck-color-focus-border);\n\t\t}\n\t}\n\n\t/*\n\t * In high contrast mode, the colors are replaced with text labels.\n\t * See https://github.com/ckeditor/ckeditor5/issues/14907.\n\t */\n\t@mixin ck-media-forced-colors {\n\t\twidth: unset;\n\t\theight: unset;\n\t\tmin-width: unset;\n\t\tmin-height: unset;\n\t\tpadding: 0 var(--ck-spacing-small);\n\n\t\t& .ck-button__label {\n\t\t\tdisplay: inline-block;\n\t\t}\n\t}\n\n\t@media (prefers-reduced-motion: reduce) {\n\t\ttransition: none;\n\t}\n\n\t&.ck-disabled {\n\t\tcursor: unset;\n\t\ttransition: unset;\n\t}\n\n\t& .ck.ck-icon {\n\t\tdisplay: none;\n\t\tcolor: var(--ck-color-color-grid-check-icon);\n\t}\n\n\t&.ck-on {\n\t\t& .ck.ck-icon {\n\t\t\tdisplay: block;\n\t\t}\n\t}\n}\n\n.ck.ck-color-grid__label {\n\tpadding: 0 var(--ck-spacing-standard);\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@define-mixin ck-media-forced-colors {\n\t@media (forced-colors: active) {\n\t\t& {\n\t\t\t@mixin-content;\n\t\t}\n\t}\n}\n\n@define-mixin ck-media-default-colors {\n\t@media (forced-colors: none) {\n\t\t& {\n\t\t\t@mixin-content;\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},3086:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".color-picker-hex-input{width:max-content}.color-picker-hex-input .ck.ck-input{min-width:unset}.ck.ck-color-picker__row{display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:space-between;margin:var(--ck-spacing-large) 0 0;width:unset}.ck.ck-color-picker__row .ck.ck-labeled-field-view{padding-top:unset}.ck.ck-color-picker__row .ck.ck-input-text{width:unset}.ck.ck-color-picker__row .ck-color-picker__hash-view{padding-right:var(--ck-spacing-medium);padding-top:var(--ck-spacing-tiny)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/colorpicker/colorpicker.css"],names:[],mappings:"AAKA,wBACC,iBAKD,CAHC,qCACC,eACD,CAGD,yBACC,YAAa,CACb,kBAAmB,CACnB,gBAAiB,CACjB,6BAA8B,CAC9B,kCAAmC,CACnC,WAcD,CAZC,mDACC,iBACD,CAEA,2CACC,WACD,CAEA,qDAEC,sCAAuC,CADvC,kCAED",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.color-picker-hex-input {\n\twidth: max-content;\n\n\t& .ck.ck-input {\n\t\tmin-width: unset;\n\t}\n}\n\n.ck.ck-color-picker__row {\n\tdisplay: flex;\n\tflex-direction: row;\n\tflex-wrap: nowrap;\n\tjustify-content: space-between;\n\tmargin: var(--ck-spacing-large) 0 0;\n\twidth: unset;\n\n\t& .ck.ck-labeled-field-view {\n\t\tpadding-top: unset;\n\t}\n\n\t& .ck.ck-input-text {\n\t\twidth: unset;\n\t}\n\n\t& .ck-color-picker__hash-view {\n\t\tpadding-top: var(--ck-spacing-tiny);\n\t\tpadding-right: var(--ck-spacing-medium);\n\t}\n}\n"],sourceRoot:""}]);const a=s},2922:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-color-selector .ck-color-grids-fragment .ck-button.ck-color-selector__color-picker,.ck.ck-color-selector .ck-color-grids-fragment .ck-button.ck-color-selector__remove-color{align-items:center;display:flex}[dir=rtl] .ck.ck-color-selector .ck-color-grids-fragment .ck-button.ck-color-selector__color-picker,[dir=rtl] .ck.ck-color-selector .ck-color-grids-fragment .ck-button.ck-color-selector__remove-color{justify-content:flex-start}.ck.ck-color-selector .ck-color-picker-fragment .ck.ck-color-selector_action-bar{display:flex;flex-direction:row;justify-content:space-around}.ck.ck-color-selector .ck-color-picker-fragment .ck.ck-color-selector_action-bar .ck-button-cancel,.ck.ck-color-selector .ck-color-picker-fragment .ck.ck-color-selector_action-bar .ck-button-save{flex:1}.ck.ck-color-selector .ck-color-grids-fragment .ck-button.ck-color-selector__color-picker,.ck.ck-color-selector .ck-color-grids-fragment .ck-button.ck-color-selector__remove-color{width:100%}.ck.ck-color-selector .ck-color-grids-fragment .ck-button.ck-color-selector__color-picker{border-bottom-left-radius:0;border-bottom-right-radius:0;padding:calc(var(--ck-spacing-standard)/2) var(--ck-spacing-standard)}.ck.ck-color-selector .ck-color-grids-fragment .ck-button.ck-color-selector__color-picker:not(:focus){border-top:1px solid var(--ck-color-base-border)}[dir=ltr] .ck.ck-color-selector .ck-color-grids-fragment .ck-button.ck-color-selector__color-picker .ck.ck-icon{margin-right:var(--ck-spacing-standard)}[dir=rtl] .ck.ck-color-selector .ck-color-grids-fragment .ck-button.ck-color-selector__color-picker .ck.ck-icon{margin-left:var(--ck-spacing-standard)}.ck.ck-color-selector .ck-color-grids-fragment label.ck.ck-color-grid__label{font-weight:unset}.ck.ck-color-selector .ck-color-picker-fragment .ck.ck-color-picker{padding:8px}.ck.ck-color-selector .ck-color-picker-fragment .ck.ck-color-picker .hex-color-picker{height:100px;min-width:180px}.ck.ck-color-selector .ck-color-picker-fragment .ck.ck-color-picker .hex-color-picker::part(saturation){border-radius:var(--ck-border-radius) var(--ck-border-radius) 0 0}.ck.ck-color-selector .ck-color-picker-fragment .ck.ck-color-picker .hex-color-picker::part(hue){border-radius:0 0 var(--ck-border-radius) var(--ck-border-radius)}.ck.ck-color-selector .ck-color-picker-fragment .ck.ck-color-picker .hex-color-picker::part(hue-pointer),.ck.ck-color-selector .ck-color-picker-fragment .ck.ck-color-picker .hex-color-picker::part(saturation-pointer){height:15px;width:15px}.ck.ck-color-selector .ck-color-picker-fragment .ck.ck-color-selector_action-bar{padding:0 8px 8px}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/colorselector/colorselector.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/colorselector/colorselector.css"],names:[],mappings:"AAUE,oLAGC,kBAAmB,CADnB,YAMD,CARA,wMAME,0BAEF,CAKA,iFACC,YAAa,CACb,kBAAmB,CACnB,4BAMD,CAJC,oMAEC,MACD,CCrBD,oLAEC,UACD,CAEA,0FAEC,2BAA4B,CAC5B,4BAA6B,CAF7B,qEAiBD,CAbC,sGACC,gDACD,CAEA,gHAEE,uCAMF,CARA,gHAME,sCAEF,CAGD,6EACC,iBACD,CAKA,oEACC,WAoBD,CAlBC,sFACC,YAAa,CACb,eAeD,CAbC,wGACC,iEACD,CAEA,iGACC,iEACD,CAEA,yNAGC,WAAY,CADZ,UAED,CAIF,iFACC,iBACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n.ck.ck-color-selector {\n\t/* View fragment with color grids. */\n\t& .ck-color-grids-fragment {\n\t\t& .ck-button.ck-color-selector__remove-color,\n\t\t& .ck-button.ck-color-selector__color-picker {\n\t\t\tdisplay: flex;\n\t\t\talign-items: center;\n\n\t\t\t@mixin ck-dir rtl {\n\t\t\t\tjustify-content: flex-start;\n\t\t\t}\n\t\t}\n\t}\n\n\t/* View fragment with a color picker. */\n\t& .ck-color-picker-fragment {\n\t\t& .ck.ck-color-selector_action-bar {\n\t\t\tdisplay: flex;\n\t\t\tflex-direction: row;\n\t\t\tjustify-content: space-around;\n\n\t\t\t& .ck-button-save,\n\t\t\t& .ck-button-cancel {\n\t\t\t\tflex: 1\n\t\t\t}\n\t\t}\n\t}\n}\n','/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n.ck.ck-color-selector {\n\t/* View fragment with color grids. */\n\t& .ck-color-grids-fragment {\n\t\t& .ck-button.ck-color-selector__remove-color,\n\t\t& .ck-button.ck-color-selector__color-picker {\n\t\t\twidth: 100%;\n\t\t}\n\n\t\t& .ck-button.ck-color-selector__color-picker {\n\t\t\tpadding: calc(var(--ck-spacing-standard) / 2) var(--ck-spacing-standard);\n\t\t\tborder-bottom-left-radius: 0;\n\t\t\tborder-bottom-right-radius: 0;\n\n\t\t\t&:not(:focus) {\n\t\t\t\tborder-top: 1px solid var(--ck-color-base-border);\n\t\t\t}\n\n\t\t\t& .ck.ck-icon {\n\t\t\t\t@mixin ck-dir ltr {\n\t\t\t\t\tmargin-right: var(--ck-spacing-standard);\n\t\t\t\t}\n\n\t\t\t\t@mixin ck-dir rtl {\n\t\t\t\t\tmargin-left: var(--ck-spacing-standard);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t& label.ck.ck-color-grid__label {\n\t\t\tfont-weight: unset;\n\t\t}\n\t}\n\n\t/* View fragment with a color picker. */\n\t& .ck-color-picker-fragment {\n\t\t& .ck.ck-color-picker {\n\t\t\tpadding: 8px;\n\n\t\t\t& .hex-color-picker {\n\t\t\t\theight: 100px;\n\t\t\t\tmin-width: 180px;\n\n\t\t\t\t&::part(saturation) {\n\t\t\t\t\tborder-radius: var(--ck-border-radius) var(--ck-border-radius) 0 0;\n\t\t\t\t}\n\n\t\t\t\t&::part(hue) {\n\t\t\t\t\tborder-radius: 0 0 var(--ck-border-radius) var(--ck-border-radius);\n\t\t\t\t}\n\n\t\t\t\t&::part(saturation-pointer),\n\t\t\t\t&::part(hue-pointer) {\n\t\t\t\t\twidth: 15px;\n\t\t\t\t\theight: 15px;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t& .ck.ck-color-selector_action-bar {\n\t\t\tpadding: 0 8px 8px;\n\t\t}\n\t}\n}\n'],sourceRoot:""}]);const a=s},880:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-dialog-overlay{bottom:0;left:0;overscroll-behavior:none;position:fixed;right:0;top:0;user-select:none}.ck.ck-dialog-overlay.ck-dialog-overlay__transparent{animation:none;background:none;pointer-events:none}.ck.ck-dialog{overscroll-behavior:none;position:absolute;width:fit-content}.ck.ck-dialog .ck.ck-form__header{flex-shrink:0}.ck.ck-dialog .ck.ck-form__header .ck-form__header__label{cursor:grab}.ck.ck-dialog-overlay.ck-dialog-overlay__transparent .ck.ck-dialog{pointer-events:all}:root{--ck-dialog-overlay-background-color:rgba(0,0,0,.5);--ck-dialog-drop-shadow:0px 0px 6px 2px rgba(0,0,0,.15);--ck-dialog-max-width:100vw;--ck-dialog-max-height:90vh;--ck-color-dialog-background:var(--ck-color-base-background);--ck-color-dialog-form-header-border:var(--ck-color-base-border)}.ck.ck-dialog-overlay{animation:ck-dialog-fade-in .3s;background:var(--ck-dialog-overlay-background-color);z-index:var(--ck-z-dialog)}.ck.ck-dialog{border-radius:0}.ck-rounded-corners .ck.ck-dialog,.ck.ck-dialog.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-dialog{box-shadow:var(--ck-drop-shadow),0 0;--ck-drop-shadow:var(--ck-dialog-drop-shadow);background:var(--ck-color-dialog-background);border:1px solid var(--ck-color-base-border);max-height:var(--ck-dialog-max-height);max-width:var(--ck-dialog-max-width)}.ck.ck-dialog .ck.ck-form__header{border-bottom:1px solid var(--ck-color-dialog-form-header-border)}@keyframes ck-dialog-fade-in{0%{background:transparent}to{background:var(--ck-dialog-overlay-background-color)}}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/dialog/dialog.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/dialog/dialog.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css"],names:[],mappings:"AAKA,sBAKC,QAAS,CACT,MAAO,CAJP,wBAAyB,CAEzB,cAAe,CAGf,OAAQ,CACR,KAAM,CAPN,gBAcD,CALC,qDAEC,cAAe,CACf,eAAgB,CAFhB,mBAGD,CAGD,cACC,wBAAyB,CAEzB,iBAAkB,CADlB,iBAcD,CAXC,kCACC,aAKD,CAHC,0DACC,WACD,CAVF,mEAcE,kBAEF,CC7BA,MACC,mDAA2D,CAC3D,uDAA8D,CAC9D,2BAA4B,CAC5B,2BAA4B,CAC5B,4DAA6D,CAC7D,gEACD,CAEA,sBACC,+BAAgC,CAChC,oDAAqD,CACrD,0BACD,CAEA,cCbC,eD2BD,CAdA,mECTE,qCDuBF,CAdA,cEfC,oCAA8B,CFmB9B,6CAA8C,CAE9C,4CAA6C,CAG7C,4CAA6C,CAF7C,sCAAuC,CACvC,oCAMD,CAHC,kCACC,iEACD,CAGD,6BACC,GACC,sBACD,CAEA,GACC,oDACD,CACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-dialog-overlay {\n\tuser-select: none;\n\toverscroll-behavior: none;\n\n\tposition: fixed;\n\tbottom: 0;\n\tleft: 0;\n\tright: 0;\n\ttop: 0;\n\n\t&.ck-dialog-overlay__transparent {\n\t\tpointer-events: none;\n\t\tanimation: none;\n\t\tbackground: none;\n\t}\n}\n\n.ck.ck-dialog {\n\toverscroll-behavior: none;\n\twidth: fit-content;\n\tposition: absolute;\n\n\t& .ck.ck-form__header {\n\t\tflex-shrink: 0;\n\n\t\t& .ck-form__header__label {\n\t\t\tcursor: grab;\n\t\t}\n\t}\n\n\t@nest .ck.ck-dialog-overlay.ck-dialog-overlay__transparent & {\n\t\tpointer-events: all;\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_rounded.css";\n@import "../../../mixins/_shadow.css";\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css";\n\n:root {\n\t--ck-dialog-overlay-background-color: hsla( 0, 0%, 0%, .5 );\n\t--ck-dialog-drop-shadow: 0px 0px 6px 2px hsl(0deg 0% 0% / 15%);\n\t--ck-dialog-max-width: 100vw;\n\t--ck-dialog-max-height: 90vh;\n\t--ck-color-dialog-background: var(--ck-color-base-background);\n\t--ck-color-dialog-form-header-border: var(--ck-color-base-border);\n}\n\n.ck.ck-dialog-overlay {\n\tanimation: ck-dialog-fade-in .3s;\n\tbackground: var(--ck-dialog-overlay-background-color);\n\tz-index: var(--ck-z-dialog);\n}\n\n.ck.ck-dialog {\n\t@mixin ck-rounded-corners;\n\t@mixin ck-drop-shadow;\n\n\t--ck-drop-shadow: var(--ck-dialog-drop-shadow);\n\n\tbackground: var(--ck-color-dialog-background);\n\tmax-height: var(--ck-dialog-max-height);\n\tmax-width: var(--ck-dialog-max-width);\n\tborder: 1px solid var(--ck-color-base-border);\n\n\t& .ck.ck-form__header {\n\t\tborder-bottom: 1px solid var(--ck-color-dialog-form-header-border);\n\t}\n}\n\n@keyframes ck-dialog-fade-in {\n\t0% {\n\t\tbackground: hsla( 0, 0%, 0%, 0 );\n\t}\n\n\t100% {\n\t\tbackground: var(--ck-dialog-overlay-background-color);\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A helper to combine multiple shadows.\n */\n@define-mixin ck-box-shadow $shadowA, $shadowB: 0 0 {\n\tbox-shadow: $shadowA, $shadowB;\n}\n\n/**\n * Gives an element a drop shadow so it looks like a floating panel.\n */\n@define-mixin ck-drop-shadow {\n\t@mixin ck-box-shadow var(--ck-drop-shadow);\n}\n"],sourceRoot:""}]);const a=s},8091:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-dialog .ck.ck-dialog__actions{display:flex;justify-content:flex-end;padding:var(--ck-spacing-large)}.ck.ck-dialog .ck.ck-dialog__actions>*+*{margin-left:var(--ck-spacing-large)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/dialog/dialogactions.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/dialog/dialogactions.css"],names:[],mappings:"AAMC,qCACC,YAAa,CACb,wBAAyB,CCDzB,+BDED,CCAC,yCACC,mCACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-dialog {\n\t& .ck.ck-dialog__actions {\n\t\tdisplay: flex;\n\t\tjustify-content: flex-end;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-dialog {\n\t& .ck.ck-dialog__actions {\n\t\tpadding: var(--ck-spacing-large);\n\n\t\t& > * + * {\n\t\t\tmargin-left: var(--ck-spacing-large);\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},426:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-dropdown-max-width:75vw}.ck.ck-dropdown{display:inline-block;position:relative}.ck.ck-dropdown .ck-dropdown__arrow{pointer-events:none;z-index:var(--ck-z-default)}.ck.ck-dropdown .ck-button.ck-dropdown__button{width:100%}.ck.ck-dropdown .ck-dropdown__panel{display:none;max-width:var(--ck-dropdown-max-width);position:absolute;z-index:var(--ck-z-panel)}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel-visible{display:inline-block}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_n,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_ne,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_nme,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_nmw,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_nw{bottom:100%}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_s,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_se,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_sme,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_smw,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_sw{bottom:auto;top:100%}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_ne,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_se{left:0}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_nw,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_sw{right:0}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_n,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_s{left:50%;transform:translateX(-50%)}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_nmw,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_smw{left:75%;transform:translateX(-75%)}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_nme,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_sme{left:25%;transform:translateX(-25%)}.ck.ck-toolbar .ck-dropdown__panel{z-index:calc(var(--ck-z-panel) + 1)}:root{--ck-dropdown-arrow-size:calc(var(--ck-icon-size)*0.5)}.ck.ck-dropdown{font-size:inherit}.ck.ck-dropdown .ck-dropdown__arrow{width:var(--ck-dropdown-arrow-size)}[dir=ltr] .ck.ck-dropdown .ck-dropdown__arrow{margin-left:var(--ck-spacing-standard);right:var(--ck-spacing-standard)}[dir=rtl] .ck.ck-dropdown .ck-dropdown__arrow{left:var(--ck-spacing-standard);margin-right:var(--ck-spacing-small)}.ck.ck-dropdown.ck-disabled .ck-dropdown__arrow{opacity:var(--ck-disabled-opacity)}[dir=ltr] .ck.ck-dropdown .ck-button.ck-dropdown__button:not(.ck-button_with-text){padding-left:var(--ck-spacing-small)}[dir=rtl] .ck.ck-dropdown .ck-button.ck-dropdown__button:not(.ck-button_with-text){padding-right:var(--ck-spacing-small)}.ck.ck-dropdown .ck-button.ck-dropdown__button .ck-button__label{overflow:hidden;text-overflow:ellipsis;width:7em}.ck.ck-dropdown .ck-button.ck-dropdown__button.ck-disabled .ck-button__label{opacity:var(--ck-disabled-opacity)}.ck.ck-dropdown .ck-button.ck-dropdown__button.ck-on{border-bottom-left-radius:0;border-bottom-right-radius:0}.ck.ck-dropdown .ck-button.ck-dropdown__button.ck-dropdown__button_label-width_auto .ck-button__label{width:auto}.ck.ck-dropdown .ck-button.ck-dropdown__button.ck-off:active,.ck.ck-dropdown .ck-button.ck-dropdown__button.ck-on:active{box-shadow:none}.ck.ck-dropdown .ck-button.ck-dropdown__button.ck-off:active:focus,.ck.ck-dropdown .ck-button.ck-dropdown__button.ck-on:active:focus{box-shadow:var(--ck-focus-outer-shadow),0 0}.ck.ck-dropdown__panel{border-radius:0}.ck-rounded-corners .ck.ck-dropdown__panel,.ck.ck-dropdown__panel.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-dropdown__panel{background:var(--ck-color-dropdown-panel-background);border:1px solid var(--ck-color-dropdown-panel-border);bottom:0;box-shadow:var(--ck-drop-shadow),0 0;min-width:100%}.ck.ck-dropdown__panel.ck-dropdown__panel_se{border-top-left-radius:0}.ck.ck-dropdown__panel.ck-dropdown__panel_sw{border-top-right-radius:0}.ck.ck-dropdown__panel.ck-dropdown__panel_ne{border-bottom-left-radius:0}.ck.ck-dropdown__panel.ck-dropdown__panel_nw{border-bottom-right-radius:0}.ck.ck-dropdown__panel:focus{outline:none}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/dropdown/dropdown.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/dropdown/dropdown.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_disabled.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css"],names:[],mappings:"AAKA,MACC,4BACD,CAEA,gBACC,oBAAqB,CACrB,iBA2ED,CAzEC,oCACC,mBAAoB,CACpB,2BACD,CAGA,+CACC,UACD,CAEA,oCACC,YAAa,CAEb,sCAAuC,CAEvC,iBAAkB,CAHlB,yBA4DD,CAvDC,+DACC,oBACD,CAEA,mSAKC,WACD,CAEA,mSAUC,WAAY,CADZ,QAED,CAEA,oHAEC,MACD,CAEA,oHAEC,OACD,CAEA,kHAGC,QAAS,CACT,0BACD,CAEA,sHAGC,QAAS,CACT,0BACD,CAEA,sHAGC,QAAS,CACT,0BACD,CAQF,mCACC,mCACD,CCpFA,MACC,sDACD,CAEA,gBAEC,iBA2ED,CAzEC,oCACC,mCACD,CAGC,8CAIC,sCAAuC,CAHvC,gCAID,CAIA,8CACC,+BAAgC,CAGhC,oCACD,CAGD,gDC/BA,kCDiCA,CAIE,mFAEC,oCACD,CAIA,mFAEC,qCACD,CAID,iEAEC,eAAgB,CAChB,sBAAuB,CAFvB,SAGD,CAGA,6EC1DD,kCD4DC,CAGA,qDACC,2BAA4B,CAC5B,4BACD,CAEA,sGACC,UACD,CAGA,yHAEC,eAKD,CAHC,qIE7EF,2CF+EE,CAKH,uBGlFC,eHkHD,CAhCA,qFG9EE,qCH8GF,CAhCA,uBAIC,oDAAqD,CACrD,sDAAuD,CACvD,QAAS,CE1FT,oCAA8B,CF6F9B,cAuBD,CAnBC,6CACC,wBACD,CAEA,6CACC,yBACD,CAEA,6CACC,2BACD,CAEA,6CACC,4BACD,CAEA,6BACC,YACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-dropdown-max-width: 75vw;\n}\n\n.ck.ck-dropdown {\n\tdisplay: inline-block;\n\tposition: relative;\n\n\t& .ck-dropdown__arrow {\n\t\tpointer-events: none;\n\t\tz-index: var(--ck-z-default);\n\t}\n\n\t/* Dropdown button should span horizontally, e.g. in vertical toolbars */\n\t& .ck-button.ck-dropdown__button {\n\t\twidth: 100%;\n\t}\n\n\t& .ck-dropdown__panel {\n\t\tdisplay: none;\n\t\tz-index: var(--ck-z-panel);\n\t\tmax-width: var(--ck-dropdown-max-width);\n\n\t\tposition: absolute;\n\n\t\t&.ck-dropdown__panel-visible {\n\t\t\tdisplay: inline-block;\n\t\t}\n\n\t\t&.ck-dropdown__panel_ne,\n\t\t&.ck-dropdown__panel_nw,\n\t\t&.ck-dropdown__panel_n,\n\t\t&.ck-dropdown__panel_nmw,\n\t\t&.ck-dropdown__panel_nme {\n\t\t\tbottom: 100%;\n\t\t}\n\n\t\t&.ck-dropdown__panel_se,\n\t\t&.ck-dropdown__panel_sw,\n\t\t&.ck-dropdown__panel_smw,\n\t\t&.ck-dropdown__panel_sme,\n\t\t&.ck-dropdown__panel_s {\n\t\t\t/*\n\t\t\t * Using transform: translate3d( 0, 100%, 0 ) causes blurry dropdown on Chrome 67-78+ on non-retina displays.\n\t\t\t * See https://github.com/ckeditor/ckeditor5/issues/1053.\n\t\t\t */\n\t\t\ttop: 100%;\n\t\t\tbottom: auto;\n\t\t}\n\n\t\t&.ck-dropdown__panel_ne,\n\t\t&.ck-dropdown__panel_se {\n\t\t\tleft: 0px;\n\t\t}\n\n\t\t&.ck-dropdown__panel_nw,\n\t\t&.ck-dropdown__panel_sw {\n\t\t\tright: 0px;\n\t\t}\n\n\t\t&.ck-dropdown__panel_s,\n\t\t&.ck-dropdown__panel_n {\n\t\t\t/* Positioning panels relative to the center of the button */\n\t\t\tleft: 50%;\n\t\t\ttransform: translateX(-50%);\n\t\t}\n\n\t\t&.ck-dropdown__panel_nmw,\n\t\t&.ck-dropdown__panel_smw {\n\t\t\t/* Positioning panels relative to the middle-west of the button */\n\t\t\tleft: 75%;\n\t\t\ttransform: translateX(-75%);\n\t\t}\n\n\t\t&.ck-dropdown__panel_nme,\n\t\t&.ck-dropdown__panel_sme {\n\t\t\t/* Positioning panels relative to the middle-east of the button */\n\t\t\tleft: 25%;\n\t\t\ttransform: translateX(-25%);\n\t\t}\n\t}\n}\n\n/*\n * Toolbar dropdown panels should be always above the UI (eg. other dropdown panels) from the editor's content.\n * See https://github.com/ckeditor/ckeditor5/issues/7874\n */\n.ck.ck-toolbar .ck-dropdown__panel {\n\tz-index: calc( var(--ck-z-panel) + 1 );\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_rounded.css";\n@import "../../../mixins/_disabled.css";\n@import "../../../mixins/_shadow.css";\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n:root {\n\t--ck-dropdown-arrow-size: calc(0.5 * var(--ck-icon-size));\n}\n\n.ck.ck-dropdown {\n\t/* Enable font size inheritance, which allows fluid UI scaling. */\n\tfont-size: inherit;\n\n\t& .ck-dropdown__arrow {\n\t\twidth: var(--ck-dropdown-arrow-size);\n\t}\n\n\t@mixin ck-dir ltr {\n\t\t& .ck-dropdown__arrow {\n\t\t\tright: var(--ck-spacing-standard);\n\n\t\t\t/* A space to accommodate the triangle. */\n\t\t\tmargin-left: var(--ck-spacing-standard);\n\t\t}\n\t}\n\n\t@mixin ck-dir rtl {\n\t\t& .ck-dropdown__arrow {\n\t\t\tleft: var(--ck-spacing-standard);\n\n\t\t\t/* A space to accommodate the triangle. */\n\t\t\tmargin-right: var(--ck-spacing-small);\n\t\t}\n\t}\n\n\t&.ck-disabled .ck-dropdown__arrow {\n\t\t@mixin ck-disabled;\n\t}\n\n\t& .ck-button.ck-dropdown__button {\n\t\t@mixin ck-dir ltr {\n\t\t\t&:not(.ck-button_with-text) {\n\t\t\t\t/* Make sure dropdowns with just an icon have the right inner spacing */\n\t\t\t\tpadding-left: var(--ck-spacing-small);\n\t\t\t}\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\t&:not(.ck-button_with-text) {\n\t\t\t\t/* Make sure dropdowns with just an icon have the right inner spacing */\n\t\t\t\tpadding-right: var(--ck-spacing-small);\n\t\t\t}\n\t\t}\n\n\t\t/* #23 */\n\t\t& .ck-button__label {\n\t\t\twidth: 7em;\n\t\t\toverflow: hidden;\n\t\t\ttext-overflow: ellipsis;\n\t\t}\n\n\t\t/* https://github.com/ckeditor/ckeditor5-theme-lark/issues/70 */\n\t\t&.ck-disabled .ck-button__label {\n\t\t\t@mixin ck-disabled;\n\t\t}\n\n\t\t/* https://github.com/ckeditor/ckeditor5/issues/816 */\n\t\t&.ck-on {\n\t\t\tborder-bottom-left-radius: 0;\n\t\t\tborder-bottom-right-radius: 0;\n\t\t}\n\n\t\t&.ck-dropdown__button_label-width_auto .ck-button__label {\n\t\t\twidth: auto;\n\t\t}\n\n\t\t/* https://github.com/ckeditor/ckeditor5/issues/8699 */\n\t\t&.ck-off:active,\n\t\t&.ck-on:active {\n\t\t\tbox-shadow: none;\n\n\t\t\t&:focus {\n\t\t\t\t@mixin ck-box-shadow var(--ck-focus-outer-shadow);\n\t\t\t}\n\t\t}\n\t}\n}\n\n.ck.ck-dropdown__panel {\n\t@mixin ck-rounded-corners;\n\t@mixin ck-drop-shadow;\n\n\tbackground: var(--ck-color-dropdown-panel-background);\n\tborder: 1px solid var(--ck-color-dropdown-panel-border);\n\tbottom: 0;\n\n\t/* Make sure the panel is at least as wide as the drop-down\'s button. */\n\tmin-width: 100%;\n\n\t/* Disabled corner border radius to be consistent with the .dropdown__button\n\thttps://github.com/ckeditor/ckeditor5/issues/816 */\n\t&.ck-dropdown__panel_se {\n\t\tborder-top-left-radius: 0;\n\t}\n\n\t&.ck-dropdown__panel_sw {\n\t\tborder-top-right-radius: 0;\n\t}\n\n\t&.ck-dropdown__panel_ne {\n\t\tborder-bottom-left-radius: 0;\n\t}\n\n\t&.ck-dropdown__panel_nw {\n\t\tborder-bottom-right-radius: 0;\n\t}\n\n\t&:focus {\n\t\toutline: none;\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A class which indicates that an element holding it is disabled.\n */\n@define-mixin ck-disabled {\n\topacity: var(--ck-disabled-opacity);\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A helper to combine multiple shadows.\n */\n@define-mixin ck-box-shadow $shadowA, $shadowB: 0 0 {\n\tbox-shadow: $shadowA, $shadowB;\n}\n\n/**\n * Gives an element a drop shadow so it looks like a floating panel.\n */\n@define-mixin ck-drop-shadow {\n\t@mixin ck-box-shadow var(--ck-drop-shadow);\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n"],sourceRoot:""}]);const a=s},2454:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-dropdown>.ck-dropdown__panel>.ck-list{border-radius:0}.ck-rounded-corners .ck.ck-dropdown>.ck-dropdown__panel>.ck-list,.ck.ck-dropdown>.ck-dropdown__panel>.ck-list.ck-rounded-corners{border-radius:var(--ck-border-radius);border-top-left-radius:0}.ck.ck-dropdown>.ck-dropdown__panel>.ck-list .ck-list__item:first-child>.ck-button{border-radius:0}.ck-rounded-corners .ck.ck-dropdown>.ck-dropdown__panel>.ck-list .ck-list__item:first-child>.ck-button,.ck.ck-dropdown>.ck-dropdown__panel>.ck-list .ck-list__item:first-child>.ck-button.ck-rounded-corners{border-radius:var(--ck-border-radius);border-bottom-left-radius:0;border-bottom-right-radius:0;border-top-left-radius:0}.ck.ck-dropdown>.ck-dropdown__panel>.ck-list .ck-list__item:last-child>.ck-button{border-radius:0}.ck-rounded-corners .ck.ck-dropdown>.ck-dropdown__panel>.ck-list .ck-list__item:last-child>.ck-button,.ck.ck-dropdown>.ck-dropdown__panel>.ck-list .ck-list__item:last-child>.ck-button.ck-rounded-corners{border-radius:var(--ck-border-radius);border-top-left-radius:0;border-top-right-radius:0}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/dropdown/listdropdown.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css"],names:[],mappings:"AAOA,6CCIC,eDqBD,CAzBA,iICQE,qCAAsC,CDJtC,wBAqBF,CAfE,mFCND,eDYC,CANA,6MCFA,qCAAsC,CDKpC,2BAA4B,CAC5B,4BAA6B,CAF7B,wBAIF,CAEA,kFCdD,eDmBC,CALA,2MCVA,qCAAsC,CDYpC,wBAAyB,CACzB,yBAEF",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_rounded.css";\n\n.ck.ck-dropdown > .ck-dropdown__panel > .ck-list {\n\t/* Disabled radius of top-left border to be consistent with .dropdown__button\n\thttps://github.com/ckeditor/ckeditor5/issues/816 */\n\t@mixin ck-rounded-corners {\n\t\tborder-top-left-radius: 0;\n\t}\n\n\t/* Make sure the button belonging to the first/last child of the list goes well with the\n\tborder radius of the entire panel. */\n\t& .ck-list__item {\n\t\t&:first-child > .ck-button {\n\t\t\t@mixin ck-rounded-corners {\n\t\t\t\tborder-top-left-radius: 0;\n\t\t\t\tborder-bottom-left-radius: 0;\n\t\t\t\tborder-bottom-right-radius: 0;\n\t\t\t}\n\t\t}\n\n\t\t&:last-child > .ck-button {\n\t\t\t@mixin ck-rounded-corners {\n\t\t\t\tborder-top-left-radius: 0;\n\t\t\t\tborder-top-right-radius: 0;\n\t\t\t}\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n"],sourceRoot:""}]);const a=s},7133:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,'.ck.ck-splitbutton{font-size:inherit}.ck.ck-splitbutton .ck-splitbutton__action:focus{z-index:calc(var(--ck-z-default) + 1)}:root{--ck-color-split-button-hover-background:#ebebeb;--ck-color-split-button-hover-border:#b3b3b3}[dir=ltr] .ck.ck-splitbutton.ck-splitbutton_open>.ck-splitbutton__action,[dir=ltr] .ck.ck-splitbutton:hover>.ck-splitbutton__action{border-bottom-right-radius:unset;border-top-right-radius:unset}[dir=rtl] .ck.ck-splitbutton.ck-splitbutton_open>.ck-splitbutton__action,[dir=rtl] .ck.ck-splitbutton:hover>.ck-splitbutton__action{border-bottom-left-radius:unset;border-top-left-radius:unset}.ck.ck-splitbutton>.ck-splitbutton__arrow{min-width:unset}[dir=ltr] .ck.ck-splitbutton>.ck-splitbutton__arrow{border-bottom-left-radius:unset;border-top-left-radius:unset}[dir=rtl] .ck.ck-splitbutton>.ck-splitbutton__arrow{border-bottom-right-radius:unset;border-top-right-radius:unset}.ck.ck-splitbutton>.ck-splitbutton__arrow svg{width:var(--ck-dropdown-arrow-size)}.ck.ck-splitbutton>.ck-splitbutton__arrow:not(:focus){border-bottom-width:0;border-top-width:0}.ck.ck-splitbutton.ck-splitbutton_open>.ck-button:not(.ck-on):not(.ck-disabled):not(:hover),.ck.ck-splitbutton:hover>.ck-button:not(.ck-on):not(.ck-disabled):not(:hover){background:var(--ck-color-split-button-hover-background)}.ck.ck-splitbutton.ck-splitbutton_open>.ck-splitbutton__arrow:not(.ck-disabled):after,.ck.ck-splitbutton:hover>.ck-splitbutton__arrow:not(.ck-disabled):after{background-color:var(--ck-color-split-button-hover-border);content:"";height:100%;position:absolute;width:1px}.ck.ck-splitbutton.ck-splitbutton_open>.ck-splitbutton__arrow:focus:after,.ck.ck-splitbutton:hover>.ck-splitbutton__arrow:focus:after{--ck-color-split-button-hover-border:var(--ck-color-focus-border)}[dir=ltr] .ck.ck-splitbutton.ck-splitbutton_open>.ck-splitbutton__arrow:not(.ck-disabled):after,[dir=ltr] .ck.ck-splitbutton:hover>.ck-splitbutton__arrow:not(.ck-disabled):after{left:-1px}[dir=rtl] .ck.ck-splitbutton.ck-splitbutton_open>.ck-splitbutton__arrow:not(.ck-disabled):after,[dir=rtl] .ck.ck-splitbutton:hover>.ck-splitbutton__arrow:not(.ck-disabled):after{right:-1px}.ck.ck-splitbutton.ck-splitbutton_open{border-radius:0}.ck-rounded-corners .ck.ck-splitbutton.ck-splitbutton_open,.ck.ck-splitbutton.ck-splitbutton_open.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck-rounded-corners .ck.ck-splitbutton.ck-splitbutton_open>.ck-splitbutton__action,.ck.ck-splitbutton.ck-splitbutton_open.ck-rounded-corners>.ck-splitbutton__action{border-bottom-left-radius:0}.ck-rounded-corners .ck.ck-splitbutton.ck-splitbutton_open>.ck-splitbutton__arrow,.ck.ck-splitbutton.ck-splitbutton_open.ck-rounded-corners>.ck-splitbutton__arrow{border-bottom-right-radius:0}',"",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/dropdown/splitbutton.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/dropdown/splitbutton.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css"],names:[],mappings:"AAKA,mBAEC,iBAKD,CAHC,iDACC,qCACD,CCJD,MACC,gDAAyD,CACzD,4CACD,CAMC,oIAKE,gCAAiC,CADjC,6BASF,CAbA,oIAWE,+BAAgC,CADhC,4BAGF,CAEA,0CAGC,eAiBD,CApBA,oDAQE,+BAAgC,CADhC,4BAaF,CApBA,oDAcE,gCAAiC,CADjC,6BAOF,CAHC,8CACC,mCACD,CAKD,sDAEC,qBAAwB,CADxB,kBAED,CAQC,0KACC,wDACD,CAIA,8JAKC,0DAA2D,CAJ3D,UAAW,CAGX,WAAY,CAFZ,iBAAkB,CAClB,SAGD,CAGA,sIACC,iEACD,CAGC,kLACC,SACD,CAIA,kLACC,UACD,CAMF,uCCzFA,eDmGA,CAVA,qHCrFC,qCD+FD,CARE,qKACC,2BACD,CAEA,mKACC,4BACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-splitbutton {\n\t/* Enable font size inheritance, which allows fluid UI scaling. */\n\tfont-size: inherit;\n\n\t& .ck-splitbutton__action:focus {\n\t\tz-index: calc(var(--ck-z-default) + 1);\n\t}\n}\n\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_rounded.css";\n\n:root {\n\t--ck-color-split-button-hover-background: hsl(0, 0%, 92%);\n\t--ck-color-split-button-hover-border: hsl(0, 0%, 70%);\n}\n\n.ck.ck-splitbutton {\n\t/*\n\t * Note: ck-rounded and ck-dir mixins don\'t go together (because they both use @nest).\n\t */\n\t&:hover > .ck-splitbutton__action,\n\t&.ck-splitbutton_open > .ck-splitbutton__action {\n\t\t@nest [dir="ltr"] & {\n\t\t\t/* Don\'t round the action button on the right side */\n\t\t\tborder-top-right-radius: unset;\n\t\t\tborder-bottom-right-radius: unset;\n\t\t}\n\n\t\t@nest [dir="rtl"] & {\n\t\t\t/* Don\'t round the action button on the left side */\n\t\t\tborder-top-left-radius: unset;\n\t\t\tborder-bottom-left-radius: unset;\n\t\t}\n\t}\n\n\t& > .ck-splitbutton__arrow {\n\t\t/* It\'s a text-less button and since the icon is positioned absolutely in such situation,\n\t\tit must get some arbitrary min-width. */\n\t\tmin-width: unset;\n\n\t\t@nest [dir="ltr"] & {\n\t\t\t/* Don\'t round the arrow button on the left side */\n\t\t\tborder-top-left-radius: unset;\n\t\t\tborder-bottom-left-radius: unset;\n\t\t}\n\n\t\t@nest [dir="rtl"] & {\n\t\t\t/* Don\'t round the arrow button on the right side */\n\t\t\tborder-top-right-radius: unset;\n\t\t\tborder-bottom-right-radius: unset;\n\t\t}\n\n\t\t& svg {\n\t\t\twidth: var(--ck-dropdown-arrow-size);\n\t\t}\n\t}\n\n\t/* Make sure the divider stretches 100% height of the button\n\thttps://github.com/ckeditor/ckeditor5/issues/10936 */\n\t& > .ck-splitbutton__arrow:not(:focus) {\n\t\tborder-top-width: 0px;\n\t\tborder-bottom-width: 0px;\n\t}\n\n\t/* When the split button is "open" (the arrow is on) or being hovered, it should get some styling\n\tas a whole. The background of both buttons should stand out and there should be a visual\n\tseparation between both buttons. */\n\t&.ck-splitbutton_open,\n\t&:hover {\n\t\t/* When the split button hovered as a whole, not as individual buttons. */\n\t\t& > .ck-button:not(.ck-on):not(.ck-disabled):not(:hover) {\n\t\t\tbackground: var(--ck-color-split-button-hover-background);\n\t\t}\n\n\t\t/* Splitbutton separator needs to be set with the ::after pseudoselector\n\t\tto display properly the borders on focus */\n\t\t& > .ck-splitbutton__arrow:not(.ck-disabled)::after {\n\t\t\tcontent: \'\';\n\t\t\tposition: absolute;\n\t\t\twidth: 1px;\n\t\t\theight: 100%;\n\t\t\tbackground-color: var(--ck-color-split-button-hover-border);\n\t\t}\n\n\t\t/* Make sure the divider between the buttons looks fine when the button is focused */\n\t\t& > .ck-splitbutton__arrow:focus::after {\n\t\t\t--ck-color-split-button-hover-border: var(--ck-color-focus-border);\n\t\t}\n\n\t\t@nest [dir="ltr"] & {\n\t\t\t& > .ck-splitbutton__arrow:not(.ck-disabled)::after {\n\t\t\t\tleft: -1px;\n\t\t\t}\n\t\t}\n\n\t\t@nest [dir="rtl"] & {\n\t\t\t& > .ck-splitbutton__arrow:not(.ck-disabled)::after {\n\t\t\t\tright: -1px;\n\t\t\t}\n\t\t}\n\t}\n\n\t/* Don\'t round the bottom left and right corners of the buttons when "open"\n\thttps://github.com/ckeditor/ckeditor5/issues/816 */\n\t&.ck-splitbutton_open {\n\t\t@mixin ck-rounded-corners {\n\t\t\t& > .ck-splitbutton__action {\n\t\t\t\tborder-bottom-left-radius: 0;\n\t\t\t}\n\n\t\t\t& > .ck-splitbutton__arrow {\n\t\t\t\tborder-bottom-right-radius: 0;\n\t\t\t}\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n"],sourceRoot:""}]);const a=s},7475:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-toolbar-dropdown-max-width:60vw}.ck.ck-toolbar-dropdown>.ck-dropdown__panel{max-width:var(--ck-toolbar-dropdown-max-width);width:max-content}.ck.ck-toolbar-dropdown>.ck-dropdown__panel .ck-button:focus{z-index:calc(var(--ck-z-default) + 1)}.ck.ck-toolbar-dropdown .ck-toolbar{border:0}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/dropdown/toolbardropdown.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/dropdown/toolbardropdown.css"],names:[],mappings:"AAKA,MACC,oCACD,CAEA,4CAGC,8CAA+C,CAD/C,iBAQD,CAJE,6DACC,qCACD,CCZF,oCACC,QACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-toolbar-dropdown-max-width: 60vw;\n}\n\n.ck.ck-toolbar-dropdown > .ck-dropdown__panel {\n\t/* https://github.com/ckeditor/ckeditor5/issues/5586 */\n\twidth: max-content;\n\tmax-width: var(--ck-toolbar-dropdown-max-width);\n\n\t& .ck-button {\n\t\t&:focus {\n\t\t\tz-index: calc(var(--ck-z-default) + 1);\n\t\t}\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-toolbar-dropdown .ck-toolbar {\n\tborder: 0;\n}\n"],sourceRoot:""}]);const a=s},9550:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-accessibility-help-dialog-max-width:600px;--ck-accessibility-help-dialog-max-height:400px;--ck-accessibility-help-dialog-border-color:#ccced1;--ck-accessibility-help-dialog-code-background-color:#ededed;--ck-accessibility-help-dialog-kbd-shadow-color:#9c9c9c}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content{border:1px solid transparent;max-height:var(--ck-accessibility-help-dialog-max-height);max-width:var(--ck-accessibility-help-dialog-max-width);overflow:auto;padding:var(--ck-spacing-large);user-select:text}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content:focus{border:var(--ck-focus-ring);box-shadow:var(--ck-focus-outer-shadow),0 0;outline:none}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content{*{white-space:normal}}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content .ck-label{display:none}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content h3{font-size:1.2em;font-weight:700}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content h4{font-size:1em;font-weight:700}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content h3,.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content h4,.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content p,.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content table{margin:1em 0}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content dl{border-bottom:none;border-top:1px solid var(--ck-accessibility-help-dialog-border-color);display:grid;grid-template-columns:2fr 1fr}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content dl dd,.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content dl dt{border-bottom:1px solid var(--ck-accessibility-help-dialog-border-color);padding:.4em 0}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content dl dt{grid-column-start:1}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content dl dd{grid-column-start:2;text-align:right}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content code,.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content kbd{background:var(--ck-accessibility-help-dialog-code-background-color);border-radius:2px;display:inline-block;font-size:.9em;line-height:1;padding:.4em;text-align:center;vertical-align:middle}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content code{font-family:monospace}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content kbd{box-shadow:0 1px 1px var(--ck-accessibility-help-dialog-kbd-shadow-color);margin:0 1px;min-width:1.8em}.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content kbd+kbd{margin-left:2px}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/editorui/accessibilityhelp.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_focus.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css"],names:[],mappings:"AAQA,MACC,8CAA+C,CAC/C,+CAAgD,CAChD,mDAA8D,CAC9D,4DAAyE,CACzE,uDACD,CAEA,wEAOC,4BAA6B,CAJ7B,yDAA0D,CAD1D,uDAAwD,CAExD,aAAc,CAHd,+BAAgC,CAIhC,gBAgFD,CA5EC,8ECdA,2BAA2B,CCF3B,2CAA8B,CDC9B,YDkBA,CAZD,wEAcC,EACC,kBACD,CAqED,CAlEC,kFACC,YACD,CAEA,2EAEC,eAAgB,CADhB,eAED,CAEA,2EAEC,aAAc,CADd,eAED,CAEA,8SAIC,YACD,CAEA,2EAIC,kBAAmB,CADnB,qEAAsE,CAFtE,YAAa,CACb,6BAiBD,CAbC,4JACC,wEAAyE,CACzE,cACD,CAEA,8EACC,mBACD,CAEA,8EACC,mBAAoB,CACpB,gBACD,CAGD,yJAEC,oEAAqE,CAIrE,iBAAkB,CALlB,oBAAqB,CAOrB,cAAe,CAHf,aAAc,CAFd,YAAa,CAIb,iBAAkB,CAHlB,qBAKD,CAEA,6EACC,qBACD,CAEA,4EAEC,yEAA4E,CAC5E,YAAa,CAFb,eAOD,CAHC,gFACC,eACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_focus.css";\n@import "../../../mixins/_shadow.css";\n\n:root {\n\t--ck-accessibility-help-dialog-max-width: 600px;\n\t--ck-accessibility-help-dialog-max-height: 400px;\n\t--ck-accessibility-help-dialog-border-color: hsl(220, 6%, 81%);\n\t--ck-accessibility-help-dialog-code-background-color: hsl(0deg 0% 92.94%);\n\t--ck-accessibility-help-dialog-kbd-shadow-color: hsl(0deg 0% 61%);\n}\n\n.ck.ck-accessibility-help-dialog .ck-accessibility-help-dialog__content {\n\tpadding: var(--ck-spacing-large);\n\tmax-width: var(--ck-accessibility-help-dialog-max-width);\n\tmax-height: var(--ck-accessibility-help-dialog-max-height);\n\toverflow: auto;\n\tuser-select: text;\n\n\tborder: 1px solid transparent;\n\n\t&:focus {\n\t\t@mixin ck-focus-ring;\n\t\t@mixin ck-box-shadow var(--ck-focus-outer-shadow);\n\t}\n\n\t* {\n\t\twhite-space: normal;\n\t}\n\n\t/* Hide the main label of the content container. */\n\t& .ck-label {\n\t\tdisplay: none;\n\t}\n\n\t& h3 {\n\t\tfont-weight: bold;\n\t\tfont-size: 1.2em;\n\t}\n\n\t& h4 {\n\t\tfont-weight: bold;\n\t\tfont-size: 1em;\n\t}\n\n\t& p,\n\t& h3,\n\t& h4,\n\t& table {\n\t\tmargin: 1em 0;\n\t}\n\n\t& dl {\n\t\tdisplay: grid;\n\t\tgrid-template-columns: 2fr 1fr;\n\t\tborder-top: 1px solid var(--ck-accessibility-help-dialog-border-color);\n\t\tborder-bottom: none;\n\n\t\t& dt, & dd {\n\t\t\tborder-bottom: 1px solid var(--ck-accessibility-help-dialog-border-color);\n\t\t\tpadding: .4em 0;\n\t\t}\n\n\t\t& dt {\n\t\t\tgrid-column-start: 1;\n\t\t}\n\n\t\t& dd {\n\t\t\tgrid-column-start: 2;\n\t\t\ttext-align: right;\n\t\t}\n\t}\n\n\t& kbd, & code {\n\t\tdisplay: inline-block;\n\t\tbackground: var(--ck-accessibility-help-dialog-code-background-color);\n\t\tpadding: .4em;\n\t\tvertical-align: middle;\n\t\tline-height: 1;\n\t\tborder-radius: 2px;\n\t\ttext-align: center;\n\t\tfont-size: .9em;\n\t}\n\n\t& code {\n\t\tfont-family: monospace;\n\t}\n\n\t& kbd {\n\t\tmin-width: 1.8em;\n\t\tbox-shadow: 0px 1px 1px var(--ck-accessibility-help-dialog-kbd-shadow-color);\n\t\tmargin: 0 1px;\n\n\t\t& + kbd {\n\t\t\tmargin-left: 2px;\n\t\t}\n\t}\n}\n\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A visual style of focused element's border.\n */\n@define-mixin ck-focus-ring {\n\t/* Disable native outline. */\n\toutline: none;\n\tborder: var(--ck-focus-ring)\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A helper to combine multiple shadows.\n */\n@define-mixin ck-box-shadow $shadowA, $shadowB: 0 0 {\n\tbox-shadow: $shadowA, $shadowB;\n}\n\n/**\n * Gives an element a drop shadow so it looks like a floating panel.\n */\n@define-mixin ck-drop-shadow {\n\t@mixin ck-box-shadow var(--ck-drop-shadow);\n}\n"],sourceRoot:""}]);const a=s},178:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-color-editable-blur-selection:#d9d9d9}.ck.ck-editor__editable:not(.ck-editor__nested-editable){border-radius:0}.ck-rounded-corners .ck.ck-editor__editable:not(.ck-editor__nested-editable),.ck.ck-editor__editable.ck-rounded-corners:not(.ck-editor__nested-editable){border-radius:var(--ck-border-radius)}.ck.ck-editor__editable.ck-focused:not(.ck-editor__nested-editable){border:var(--ck-focus-ring);box-shadow:var(--ck-inner-shadow),0 0;outline:none}.ck.ck-editor__editable_inline{border:1px solid transparent;overflow:auto;padding:0 var(--ck-spacing-standard)}.ck.ck-editor__editable_inline[dir=ltr]{text-align:left}.ck.ck-editor__editable_inline[dir=rtl]{text-align:right}.ck.ck-editor__editable_inline>:first-child{margin-top:var(--ck-spacing-large)}.ck.ck-editor__editable_inline>:last-child{margin-bottom:var(--ck-spacing-large)}.ck.ck-editor__editable_inline.ck-blurred ::selection{background:var(--ck-color-editable-blur-selection)}.ck.ck-balloon-panel.ck-toolbar-container[class*=arrow_n]:after{border-bottom-color:var(--ck-color-panel-background)}.ck.ck-balloon-panel.ck-toolbar-container[class*=arrow_s]:after{border-top-color:var(--ck-color-panel-background)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/editorui/editorui.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_focus.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css"],names:[],mappings:"AAWA,MACC,0CACD,CAEA,yDCJC,eDWD,CAPA,yJCAE,qCDOF,CAJC,oEEPA,2BAA2B,CCF3B,qCAA8B,CDC9B,YFWA,CAGD,+BAGC,4BAA6B,CAF7B,aAAc,CACd,oCA6BD,CA1BC,wCACC,eACD,CAEA,wCACC,gBACD,CAGA,4CACC,kCACD,CAGA,2CAKC,qCACD,CAGA,sDACC,kDACD,CAKA,gEACC,oDACD,CAIA,gEACC,iDACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_rounded.css";\n@import "../../../mixins/_disabled.css";\n@import "../../../mixins/_shadow.css";\n@import "../../../mixins/_focus.css";\n@import "../../mixins/_button.css";\n\n:root {\n\t--ck-color-editable-blur-selection: hsl(0, 0%, 85%);\n}\n\n.ck.ck-editor__editable:not(.ck-editor__nested-editable) {\n\t@mixin ck-rounded-corners;\n\n\t&.ck-focused {\n\t\t@mixin ck-focus-ring;\n\t\t@mixin ck-box-shadow var(--ck-inner-shadow);\n\t}\n}\n\n.ck.ck-editor__editable_inline {\n\toverflow: auto;\n\tpadding: 0 var(--ck-spacing-standard);\n\tborder: 1px solid transparent;\n\n\t&[dir="ltr"] {\n\t\ttext-align: left;\n\t}\n\n\t&[dir="rtl"] {\n\t\ttext-align: right;\n\t}\n\n\t/* https://github.com/ckeditor/ckeditor5-theme-lark/issues/116 */\n\t& > *:first-child {\n\t\tmargin-top: var(--ck-spacing-large);\n\t}\n\n\t/* https://github.com/ckeditor/ckeditor5/issues/847 */\n\t& > *:last-child {\n\t\t/*\n\t\t * This value should match with the default margins of the block elements (like .media or .image)\n\t\t * to avoid a content jumping when the fake selection container shows up (See https://github.com/ckeditor/ckeditor5/issues/9825).\n\t\t */\n\t\tmargin-bottom: var(--ck-spacing-large);\n\t}\n\n\t/* https://github.com/ckeditor/ckeditor5/issues/6517 */\n\t&.ck-blurred ::selection {\n\t\tbackground: var(--ck-color-editable-blur-selection);\n\t}\n}\n\n/* https://github.com/ckeditor/ckeditor5-theme-lark/issues/111 */\n.ck.ck-balloon-panel.ck-toolbar-container[class*="arrow_n"] {\n\t&::after {\n\t\tborder-bottom-color: var(--ck-color-panel-background);\n\t}\n}\n\n.ck.ck-balloon-panel.ck-toolbar-container[class*="arrow_s"] {\n\t&::after {\n\t\tborder-top-color: var(--ck-color-panel-background);\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A visual style of focused element's border.\n */\n@define-mixin ck-focus-ring {\n\t/* Disable native outline. */\n\toutline: none;\n\tborder: var(--ck-focus-ring)\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A helper to combine multiple shadows.\n */\n@define-mixin ck-box-shadow $shadowA, $shadowB: 0 0 {\n\tbox-shadow: $shadowA, $shadowB;\n}\n\n/**\n * Gives an element a drop shadow so it looks like a floating panel.\n */\n@define-mixin ck-drop-shadow {\n\t@mixin ck-box-shadow var(--ck-drop-shadow);\n}\n"],sourceRoot:""}]);const a=s},4866:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-form__header{align-items:center;display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:space-between}.ck.ck-form__header h2.ck-form__header__label{flex-grow:1}:root{--ck-form-header-height:44px}.ck.ck-form__header{border-bottom:1px solid var(--ck-color-base-border);height:var(--ck-form-header-height);line-height:var(--ck-form-header-height);padding:var(--ck-spacing-small) var(--ck-spacing-large)}[dir=ltr] .ck.ck-form__header>.ck-icon{margin-right:var(--ck-spacing-medium)}[dir=rtl] .ck.ck-form__header>.ck-icon{margin-left:var(--ck-spacing-medium)}.ck.ck-form__header .ck-form__header__label{--ck-font-size-base:15px;font-weight:700}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/formheader/formheader.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/formheader/formheader.css"],names:[],mappings:"AAKA,oBAIC,kBAAmB,CAHnB,YAAa,CACb,kBAAmB,CACnB,gBAAiB,CAEjB,6BAKD,CAHC,8CACC,WACD,CCPD,MACC,4BACD,CAEA,oBAIC,mDAAoD,CAFpD,mCAAoC,CACpC,wCAAyC,CAFzC,uDAmBD,CAdC,uCAEE,qCAMF,CARA,uCAME,oCAEF,CAEA,4CACC,wBAAyB,CACzB,eACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-form__header {\n\tdisplay: flex;\n\tflex-direction: row;\n\tflex-wrap: nowrap;\n\talign-items: center;\n\tjustify-content: space-between;\n\n\t& h2.ck-form__header__label {\n\t\tflex-grow: 1;\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n:root {\n\t--ck-form-header-height: 44px;\n}\n\n.ck.ck-form__header {\n\tpadding: var(--ck-spacing-small) var(--ck-spacing-large);\n\theight: var(--ck-form-header-height);\n\tline-height: var(--ck-form-header-height);\n\tborder-bottom: 1px solid var(--ck-color-base-border);\n\n\t& > .ck-icon {\n\t\t@mixin ck-dir ltr {\n\t\t\tmargin-right: var(--ck-spacing-medium);\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\tmargin-left: var(--ck-spacing-medium);\n\t\t}\n\t}\n\n\t& .ck-form__header__label {\n\t\t--ck-font-size-base: 15px;\n\t\tfont-weight: bold;\n\t}\n}\n'],sourceRoot:""}]);const a=s},1998:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-highlighted-text mark{background:var(--ck-color-highlight-background);font-size:inherit;font-weight:inherit;line-height:inherit;vertical-align:initial}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/highlightedtext/highlightedtext.css"],names:[],mappings:"AAKA,6BACC,+CAAgD,CAIhD,iBAAkB,CAFlB,mBAAoB,CACpB,mBAAoB,CAFpB,sBAID",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-highlighted-text mark {\n\tbackground: var(--ck-color-highlight-background);\n\tvertical-align: initial;\n\tfont-weight: inherit;\n\tline-height: inherit;\n\tfont-size: inherit;\n}\n"],sourceRoot:""}]);const a=s},4106:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-icon{vertical-align:middle}:root{--ck-icon-size:calc(var(--ck-line-height-base)*var(--ck-font-size-normal));--ck-icon-font-size:.8333350694em}.ck.ck-icon{font-size:var(--ck-icon-font-size);height:var(--ck-icon-size);width:var(--ck-icon-size);will-change:transform}.ck.ck-icon,.ck.ck-icon *{cursor:inherit}.ck.ck-icon.ck-icon_inherit-color,.ck.ck-icon.ck-icon_inherit-color *{color:inherit}.ck.ck-icon.ck-icon_inherit-color :not([fill]){fill:currentColor}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/icon/icon.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/icon/icon.css"],names:[],mappings:"AAKA,YACC,qBACD,CCFA,MACC,0EAA6E,CAC7E,iCACD,CAEA,YAKC,kCAAmC,CAHnC,0BAA2B,CAD3B,yBAA0B,CAU1B,qBAoBD,CAlBC,0BALA,cAQA,CAMC,sEACC,aAMD,CAJC,+CAEC,iBACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-icon {\n\tvertical-align: middle;\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-icon-size: calc(var(--ck-line-height-base) * var(--ck-font-size-normal));\n\t--ck-icon-font-size: .8333350694em;\n}\n\n.ck.ck-icon {\n\twidth: var(--ck-icon-size);\n\theight: var(--ck-icon-size);\n\n\t/* Multiplied by the height of the line in "px" should give SVG "viewport" dimensions */\n\tfont-size: var(--ck-icon-font-size);\n\n\t/* Inherit cursor style (#5). */\n\tcursor: inherit;\n\n\t/* This will prevent blurry icons on Firefox. See #340. */\n\twill-change: transform;\n\n\t& * {\n\t\t/* Inherit cursor style (#5). */\n\t\tcursor: inherit;\n\t}\n\n\t/* Allows dynamic coloring of an icon by inheriting its color from the parent. */\n\t&.ck-icon_inherit-color {\n\t\tcolor: inherit;\n\n\t\t& * {\n\t\t\tcolor: inherit;\n\n\t\t\t&:not([fill]) {\n\t\t\t\t/* Needed by FF. */\n\t\t\t\tfill: currentColor;\n\t\t\t}\n\t\t}\n\t}\n}\n'],sourceRoot:""}]);const a=s},1546:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-input-width:18em;--ck-input-text-width:var(--ck-input-width)}.ck.ck-input{border-radius:0}.ck-rounded-corners .ck.ck-input,.ck.ck-input.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-input{background:var(--ck-color-input-background);border:1px solid var(--ck-color-input-border);min-height:var(--ck-ui-component-min-height);min-width:var(--ck-input-width);padding:var(--ck-spacing-extra-tiny) var(--ck-spacing-medium);transition:box-shadow .1s ease-in-out,border .1s ease-in-out}@media (prefers-reduced-motion:reduce){.ck.ck-input{transition:none}}.ck.ck-input:focus{border:var(--ck-focus-ring);box-shadow:var(--ck-focus-outer-shadow),0 0;outline:none}.ck.ck-input[readonly]{background:var(--ck-color-input-disabled-background);border:1px solid var(--ck-color-input-disabled-border);color:var(--ck-color-input-disabled-text)}.ck.ck-input[readonly]:focus{box-shadow:var(--ck-focus-disabled-outer-shadow),0 0}.ck.ck-input.ck-error{animation:ck-input-shake .3s ease both;border-color:var(--ck-color-input-error-border)}@media (prefers-reduced-motion:reduce){.ck.ck-input.ck-error{animation:none}}.ck.ck-input.ck-error:focus{box-shadow:var(--ck-focus-error-outer-shadow),0 0}@keyframes ck-input-shake{20%{transform:translateX(-2px)}40%{transform:translateX(2px)}60%{transform:translateX(-1px)}80%{transform:translateX(1px)}}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/input/input.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_focus.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css"],names:[],mappings:"AASA,MACC,qBAAsB,CAGtB,2CACD,CAEA,aCLC,eDmDD,CA9CA,iECDE,qCD+CF,CA9CA,aAGC,2CAA4C,CAC5C,6CAA8C,CAK9C,4CAA6C,CAH7C,+BAAgC,CADhC,6DAA8D,CAO9D,4DAkCD,CAhCC,uCAdD,aAeE,eA+BF,CA9BC,CAEA,mBEvBA,2BAA2B,CCF3B,2CAA8B,CDC9B,YF2BA,CAEA,uBAEC,oDAAqD,CADrD,sDAAuD,CAEvD,yCAMD,CAJC,6BGnCD,oDHsCC,CAGD,sBAEC,sCAAuC,CADvC,+CAUD,CAPC,uCAJD,sBAKE,cAMF,CALC,CAEA,4BGjDD,iDHmDC,CAIF,0BACC,IACC,0BACD,CAEA,IACC,yBACD,CAEA,IACC,0BACD,CAEA,IACC,yBACD,CACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_rounded.css";\n@import "../../../mixins/_focus.css";\n@import "../../../mixins/_shadow.css";\n\n:root {\n\t--ck-input-width: 18em;\n\n\t/* Backward compatibility. */\n\t--ck-input-text-width: var(--ck-input-width);\n}\n\n.ck.ck-input {\n\t@mixin ck-rounded-corners;\n\n\tbackground: var(--ck-color-input-background);\n\tborder: 1px solid var(--ck-color-input-border);\n\tpadding: var(--ck-spacing-extra-tiny) var(--ck-spacing-medium);\n\tmin-width: var(--ck-input-width);\n\n\t/* This is important to stay of the same height as surrounding buttons */\n\tmin-height: var(--ck-ui-component-min-height);\n\n\t/* Apply some smooth transition to the box-shadow and border. */\n\ttransition: box-shadow .1s ease-in-out, border .1s ease-in-out;\n\n\t@media (prefers-reduced-motion: reduce) {\n\t\ttransition: none;\n\t}\n\n\t&:focus {\n\t\t@mixin ck-focus-ring;\n\t\t@mixin ck-box-shadow var(--ck-focus-outer-shadow);\n\t}\n\n\t&[readonly] {\n\t\tborder: 1px solid var(--ck-color-input-disabled-border);\n\t\tbackground: var(--ck-color-input-disabled-background);\n\t\tcolor: var(--ck-color-input-disabled-text);\n\n\t\t&:focus {\n\t\t\t/* The read-only input should have a slightly less visible shadow when focused. */\n\t\t\t@mixin ck-box-shadow var(--ck-focus-disabled-outer-shadow);\n\t\t}\n\t}\n\n\t&.ck-error {\n\t\tborder-color: var(--ck-color-input-error-border);\n\t\tanimation: ck-input-shake .3s ease both;\n\n\t\t@media (prefers-reduced-motion: reduce) {\n\t\t\tanimation: none;\n\t\t}\n\n\t\t&:focus {\n\t\t\t@mixin ck-box-shadow var(--ck-focus-error-outer-shadow);\n\t\t}\n\t}\n}\n\n@keyframes ck-input-shake {\n\t20% {\n\t\ttransform: translateX(-2px);\n\t}\n\n\t40% {\n\t\ttransform: translateX(2px);\n\t}\n\n\t60% {\n\t\ttransform: translateX(-1px);\n\t}\n\n\t80% {\n\t\ttransform: translateX(1px);\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A visual style of focused element's border.\n */\n@define-mixin ck-focus-ring {\n\t/* Disable native outline. */\n\toutline: none;\n\tborder: var(--ck-focus-ring)\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A helper to combine multiple shadows.\n */\n@define-mixin ck-box-shadow $shadowA, $shadowB: 0 0 {\n\tbox-shadow: $shadowA, $shadowB;\n}\n\n/**\n * Gives an element a drop shadow so it looks like a floating panel.\n */\n@define-mixin ck-drop-shadow {\n\t@mixin ck-box-shadow var(--ck-drop-shadow);\n}\n"],sourceRoot:""}]);const a=s},4606:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-label{display:block}.ck.ck-voice-label{display:none}.ck.ck-label{font-weight:700}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/label/label.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/label/label.css"],names:[],mappings:"AAKA,aACC,aACD,CAEA,mBACC,YACD,CCNA,aACC,eACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-label {\n\tdisplay: block;\n}\n\n.ck.ck-voice-label {\n\tdisplay: none;\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-label {\n\tfont-weight: bold;\n}\n"],sourceRoot:""}]);const a=s},6365:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-labeled-field-view>.ck.ck-labeled-field-view__input-wrapper{display:flex;position:relative}.ck.ck-labeled-field-view .ck.ck-label{display:block;position:absolute}:root{--ck-labeled-field-view-transition:.1s cubic-bezier(0,0,0.24,0.95);--ck-labeled-field-empty-unfocused-max-width:100% - 2 * var(--ck-spacing-medium);--ck-labeled-field-label-default-position-x:var(--ck-spacing-medium);--ck-labeled-field-label-default-position-y:calc(var(--ck-font-size-base)*0.6);--ck-color-labeled-field-label-background:var(--ck-color-base-background)}.ck.ck-labeled-field-view{border-radius:0}.ck-rounded-corners .ck.ck-labeled-field-view,.ck.ck-labeled-field-view.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-labeled-field-view>.ck.ck-labeled-field-view__input-wrapper{width:100%}.ck.ck-labeled-field-view>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label{top:0}[dir=ltr] .ck.ck-labeled-field-view>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label{left:0;transform:translate(var(--ck-spacing-medium),-6px) scale(.75);transform-origin:0 0}[dir=rtl] .ck.ck-labeled-field-view>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label{right:0;transform:translate(calc(var(--ck-spacing-medium)*-1),-6px) scale(.75);transform-origin:100% 0}.ck.ck-labeled-field-view>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label{background:var(--ck-color-labeled-field-label-background);font-weight:400;line-height:normal;max-width:100%;overflow:hidden;padding:0 calc(var(--ck-font-size-tiny)*.5);pointer-events:none;text-overflow:ellipsis;transition:transform var(--ck-labeled-field-view-transition),padding var(--ck-labeled-field-view-transition),background var(--ck-labeled-field-view-transition)}@media (prefers-reduced-motion:reduce){.ck.ck-labeled-field-view>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label{transition:none}}.ck.ck-labeled-field-view.ck-error .ck-input:not([readonly])+.ck.ck-label,.ck.ck-labeled-field-view.ck-error>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label{color:var(--ck-color-base-error)}.ck.ck-labeled-field-view .ck-labeled-field-view__status{font-size:var(--ck-font-size-small);margin-top:var(--ck-spacing-small);white-space:normal}.ck.ck-labeled-field-view .ck-labeled-field-view__status.ck-labeled-field-view__status_error{color:var(--ck-color-base-error)}.ck.ck-labeled-field-view.ck-disabled>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label,.ck.ck-labeled-field-view.ck-labeled-field-view_empty:not(.ck-labeled-field-view_focused)>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label{color:var(--ck-color-input-disabled-text)}[dir=ltr] .ck.ck-labeled-field-view.ck-disabled.ck-labeled-field-view_empty:not(.ck-labeled-field-view_placeholder)>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label,[dir=ltr] .ck.ck-labeled-field-view.ck-labeled-field-view_empty:not(.ck-labeled-field-view_focused):not(.ck-labeled-field-view_placeholder):not(.ck-error)>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label{transform:translate(var(--ck-labeled-field-label-default-position-x),var(--ck-labeled-field-label-default-position-y)) scale(1)}[dir=rtl] .ck.ck-labeled-field-view.ck-disabled.ck-labeled-field-view_empty:not(.ck-labeled-field-view_placeholder)>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label,[dir=rtl] .ck.ck-labeled-field-view.ck-labeled-field-view_empty:not(.ck-labeled-field-view_focused):not(.ck-labeled-field-view_placeholder):not(.ck-error)>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label{transform:translate(calc(var(--ck-labeled-field-label-default-position-x)*-1),var(--ck-labeled-field-label-default-position-y)) scale(1)}.ck.ck-labeled-field-view.ck-disabled.ck-labeled-field-view_empty:not(.ck-labeled-field-view_placeholder)>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label,.ck.ck-labeled-field-view.ck-labeled-field-view_empty:not(.ck-labeled-field-view_focused):not(.ck-labeled-field-view_placeholder):not(.ck-error)>.ck.ck-labeled-field-view__input-wrapper>.ck.ck-label{background:transparent;max-width:calc(var(--ck-labeled-field-empty-unfocused-max-width));padding:0}.ck.ck-labeled-field-view>.ck.ck-labeled-field-view__input-wrapper>.ck-dropdown>.ck.ck-button{background:transparent}.ck.ck-labeled-field-view.ck-labeled-field-view_empty>.ck.ck-labeled-field-view__input-wrapper>.ck-dropdown>.ck-button>.ck-button__label{opacity:0}.ck.ck-labeled-field-view.ck-labeled-field-view_empty:not(.ck-labeled-field-view_focused):not(.ck-labeled-field-view_placeholder)>.ck.ck-labeled-field-view__input-wrapper>.ck-dropdown+.ck-label{max-width:calc(var(--ck-labeled-field-empty-unfocused-max-width) - var(--ck-dropdown-arrow-size) - var(--ck-spacing-standard))}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/labeledfield/labeledfieldview.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/labeledfield/labeledfieldview.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css"],names:[],mappings:"AAMC,mEACC,YAAa,CACb,iBACD,CAEA,uCACC,aAAc,CACd,iBACD,CCND,MACC,kEAAsE,CACtE,gFAAiF,CACjF,oEAAqE,CACrE,8EAAiF,CACjF,yEACD,CAEA,0BCLC,eDmHD,CA9GA,2FCDE,qCD+GF,CA3GC,mEACC,UAwCD,CAtCC,gFACC,KAoCD,CArCA,0FAIE,MAAS,CAGT,6DAA+D,CAF/D,oBAgCF,CArCA,0FAWE,OAAU,CAEV,sEAA0E,CAD1E,uBAyBF,CArCA,gFAkBC,yDAA0D,CAG1D,eAAmB,CADnB,kBAAoB,CAOpB,cAAe,CAFf,eAAgB,CANhB,2CAA8C,CAH9C,mBAAoB,CAQpB,sBAAuB,CAKvB,+JAQD,CAHC,uCAlCD,gFAmCE,eAEF,CADC,CASD,mKACC,gCACD,CAGD,yDACC,mCAAoC,CACpC,kCAAmC,CAInC,kBAKD,CAHC,6FACC,gCACD,CAID,4OAEC,yCACD,CAIA,2XAGE,+HAYF,CAfA,2XAOE,wIAQF,CAfA,uWAaC,sBAAuB,CAFvB,iEAAkE,CAGlE,SACD,CAKA,8FACC,sBACD,CAGA,yIACC,SACD,CAGA,kMACC,8HACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-labeled-field-view {\n\t& > .ck.ck-labeled-field-view__input-wrapper {\n\t\tdisplay: flex;\n\t\tposition: relative;\n\t}\n\n\t& .ck.ck-label {\n\t\tdisplay: block;\n\t\tposition: absolute;\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n@import "../../../mixins/_rounded.css";\n\n:root {\n\t--ck-labeled-field-view-transition: .1s cubic-bezier(0, 0, 0.24, 0.95);\n\t--ck-labeled-field-empty-unfocused-max-width: 100% - 2 * var(--ck-spacing-medium);\n\t--ck-labeled-field-label-default-position-x: var(--ck-spacing-medium);\n\t--ck-labeled-field-label-default-position-y: calc(0.6 * var(--ck-font-size-base));\n\t--ck-color-labeled-field-label-background: var(--ck-color-base-background);\n}\n\n.ck.ck-labeled-field-view {\n\t@mixin ck-rounded-corners;\n\n\t& > .ck.ck-labeled-field-view__input-wrapper {\n\t\twidth: 100%;\n\n\t\t& > .ck.ck-label {\n\t\t\ttop: 0px;\n\n\t\t\t@mixin ck-dir ltr {\n\t\t\t\tleft: 0px;\n\t\t\t\ttransform-origin: 0 0;\n\t\t\t\t/* By default, display the label scaled down above the field. */\n\t\t\t\ttransform: translate(var(--ck-spacing-medium), -6px) scale(.75);\n\t\t\t}\n\n\t\t\t@mixin ck-dir rtl {\n\t\t\t\tright: 0px;\n\t\t\t\ttransform-origin: 100% 0;\n\t\t\t\ttransform: translate(calc(-1 * var(--ck-spacing-medium)), -6px) scale(.75);\n\t\t\t}\n\n\t\t\tpointer-events: none;\n\n\t\t\tbackground: var(--ck-color-labeled-field-label-background);\n\t\t\tpadding: 0 calc(.5 * var(--ck-font-size-tiny));\n\t\t\tline-height: initial;\n\t\t\tfont-weight: normal;\n\n\t\t\t/* Prevent overflow when the label is longer than the input */\n\t\t\ttext-overflow: ellipsis;\n\t\t\toverflow: hidden;\n\n\t\t\tmax-width: 100%;\n\n\t\t\ttransition:\n\t\t\t\ttransform var(--ck-labeled-field-view-transition),\n\t\t\t\tpadding var(--ck-labeled-field-view-transition),\n\t\t\t\tbackground var(--ck-labeled-field-view-transition);\n\n\t\t\t@media (prefers-reduced-motion: reduce) {\n\t\t\t\ttransition: none;\n\t\t\t}\n\t\t}\n\t}\n\n\t&.ck-error {\n\t\t& > .ck.ck-labeled-field-view__input-wrapper > .ck.ck-label {\n\t\t\tcolor: var(--ck-color-base-error);\n\t\t}\n\n\t\t& .ck-input:not([readonly]) + .ck.ck-label {\n\t\t\tcolor: var(--ck-color-base-error);\n\t\t}\n\t}\n\n\t& .ck-labeled-field-view__status {\n\t\tfont-size: var(--ck-font-size-small);\n\t\tmargin-top: var(--ck-spacing-small);\n\n\t\t/* Let the info wrap to the next line to avoid stretching the layout horizontally.\n\t\tThe status could be very long. */\n\t\twhite-space: normal;\n\n\t\t&.ck-labeled-field-view__status_error {\n\t\t\tcolor: var(--ck-color-base-error);\n\t\t}\n\t}\n\n\t/* Disabled fields and fields that have no focus should fade out. */\n\t&.ck-disabled > .ck.ck-labeled-field-view__input-wrapper > .ck.ck-label,\n\t&.ck-labeled-field-view_empty:not(.ck-labeled-field-view_focused) > .ck.ck-labeled-field-view__input-wrapper > .ck.ck-label {\n\t\tcolor: var(--ck-color-input-disabled-text);\n\t}\n\n\t/* Fields that are disabled or not focused and without a placeholder should have full-sized labels. */\n\t/* stylelint-disable-next-line no-descending-specificity */\n\t&.ck-disabled.ck-labeled-field-view_empty:not(.ck-labeled-field-view_placeholder) > .ck.ck-labeled-field-view__input-wrapper > .ck.ck-label,\n\t&.ck-labeled-field-view_empty:not(.ck-labeled-field-view_focused):not(.ck-labeled-field-view_placeholder):not(.ck-error) > .ck.ck-labeled-field-view__input-wrapper > .ck.ck-label {\n\t\t@mixin ck-dir ltr {\n\t\t\ttransform: translate(var(--ck-labeled-field-label-default-position-x), var(--ck-labeled-field-label-default-position-y)) scale(1);\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\ttransform: translate(calc(-1 * var(--ck-labeled-field-label-default-position-x)), var(--ck-labeled-field-label-default-position-y)) scale(1);\n\t\t}\n\n\t\t/* Compensate for the default translate position. */\n\t\tmax-width: calc(var(--ck-labeled-field-empty-unfocused-max-width));\n\n\t\tbackground: transparent;\n\t\tpadding: 0;\n\t}\n\n\t/*------ DropdownView integration ----------------------------------------------------------------------------------- */\n\n\t/* Make sure dropdown\' background color in any of dropdown\'s state does not collide with labeled field. */\n\t& > .ck.ck-labeled-field-view__input-wrapper > .ck-dropdown > .ck.ck-button {\n\t\tbackground: transparent;\n\t}\n\n\t/* When the dropdown is "empty", the labeled field label replaces its label. */\n\t&.ck-labeled-field-view_empty > .ck.ck-labeled-field-view__input-wrapper > .ck-dropdown > .ck-button > .ck-button__label {\n\t\topacity: 0;\n\t}\n\n\t/* Make sure the label of the empty, unfocused input does not cover the dropdown arrow. */\n\t&.ck-labeled-field-view_empty:not(.ck-labeled-field-view_focused):not(.ck-labeled-field-view_placeholder) > .ck.ck-labeled-field-view__input-wrapper > .ck-dropdown + .ck-label {\n\t\tmax-width: calc(var(--ck-labeled-field-empty-unfocused-max-width) - var(--ck-dropdown-arrow-size) - var(--ck-spacing-standard));\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n"],sourceRoot:""}]);const a=s},6048:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-list{display:flex;flex-direction:column;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.ck.ck-list .ck-list__item,.ck.ck-list .ck-list__separator{display:block}.ck.ck-list .ck-list__item>:focus{position:relative;z-index:var(--ck-z-default)}.ck.ck-list{border-radius:0}.ck-rounded-corners .ck.ck-list,.ck.ck-list.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-list{background:var(--ck-color-list-background);list-style-type:none;padding:var(--ck-spacing-small) 0}.ck.ck-list__item{cursor:default;min-width:15em}.ck.ck-list__item>.ck-button:not(.ck-list-item-button){border-radius:0;min-height:unset;padding:var(--ck-spacing-tiny) calc(var(--ck-spacing-standard)*2);width:100%}[dir=ltr] .ck.ck-list__item>.ck-button:not(.ck-list-item-button){text-align:left}[dir=rtl] .ck.ck-list__item>.ck-button:not(.ck-list-item-button){text-align:right}.ck.ck-list__item>.ck-button:not(.ck-list-item-button) .ck-button__label{line-height:calc(var(--ck-line-height-base)*var(--ck-font-size-base))}.ck.ck-list__item>.ck-button:not(.ck-list-item-button):active{box-shadow:none}.ck.ck-list__item>.ck-button.ck-on:not(.ck-list-item-button){background:var(--ck-color-list-button-on-background);color:var(--ck-color-list-button-on-text)}.ck.ck-list__item>.ck-button.ck-on:not(.ck-list-item-button):active{box-shadow:none}.ck.ck-list__item>.ck-button.ck-on:not(.ck-list-item-button):hover:not(.ck-disabled){background:var(--ck-color-list-button-on-background-focus)}.ck.ck-list__item>.ck-button.ck-on:not(.ck-list-item-button):focus:not(.ck-disabled){border-color:var(--ck-color-base-background)}.ck.ck-list__item>.ck-button:not(.ck-list-item-button):hover:not(.ck-disabled){background:var(--ck-color-list-button-hover-background)}.ck.ck-list__item>.ck-button.ck-switchbutton.ck-on{background:var(--ck-color-list-background);color:inherit}.ck.ck-list__item>.ck-button.ck-switchbutton.ck-on:hover:not(.ck-disabled){background:var(--ck-color-list-button-hover-background);color:inherit}.ck-list .ck-list__group{padding-top:var(--ck-spacing-medium)}.ck-list .ck-list__group:first-child{padding-top:0}.ck-list .ck-list__group{:not(.ck-hidden)~&{border-top:1px solid var(--ck-color-base-border)}}.ck-list .ck-list__group>.ck-label{font-size:11px;font-weight:700;padding:var(--ck-spacing-medium) var(--ck-spacing-large) 0}.ck.ck-list__separator{background:var(--ck-color-base-border);height:1px;margin:var(--ck-spacing-small) 0;width:100%}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/list/list.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_unselectable.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/list/list.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css"],names:[],mappings:"AAOA,YAGC,YAAa,CACb,qBAAsB,CCFtB,qBAAsB,CACtB,wBAAyB,CACzB,oBAAqB,CACrB,gBDaD,CAZC,2DAEC,aACD,CAKA,kCACC,iBAAkB,CAClB,2BACD,CEdD,YCCC,eDOD,CARA,+DCKE,qCDGF,CARA,YAIC,0CAA2C,CAD3C,oBAAqB,CAIrB,iCACD,CAEA,kBACC,cAAe,CAGf,cA4DD,CA1DC,uDAIC,eAAgB,CAFhB,gBAAiB,CADjB,iEAAoE,CAEpE,UAwCD,CA3CA,iEAOE,eAoCF,CA3CA,iEAWE,gBAgCF,CA7BC,yEAEC,qEACD,CAEA,8DACC,eACD,CAEA,6DACC,oDAAqD,CACrD,yCAaD,CAXC,oEACC,eACD,CAEA,qFACC,0DACD,CAEA,qFACC,4CACD,CAGD,+EACC,uDACD,CAMA,mDACC,0CAA2C,CAC3C,aAMD,CAJC,2EACC,uDAAwD,CACxD,aACD,CAKH,yBACC,oCAiBD,CAdC,qCACC,aACD,CAND,yBASC,mBACC,gDACD,CAOD,CALC,mCACC,cAAe,CACf,eAAiB,CACjB,0DACD,CAGD,uBAGC,sCAAuC,CAFvC,UAAW,CAKX,gCAAiC,CAJjC,UAKD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../mixins/_unselectable.css";\n\n.ck.ck-list {\n\t@mixin ck-unselectable;\n\n\tdisplay: flex;\n\tflex-direction: column;\n\n\t& .ck-list__item,\n\t& .ck-list__separator {\n\t\tdisplay: block;\n\t}\n\n\t/* Make sure that whatever child of the list item gets focus, it remains on the\n\ttop. Thanks to that, styles like box-shadow, outline, etc. are not masked by\n\tadjacent list items. */\n\t& .ck-list__item > *:focus {\n\t\tposition: relative;\n\t\tz-index: var(--ck-z-default);\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Makes element unselectable.\n */\n@define-mixin ck-unselectable {\n\t-moz-user-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n\tuser-select: none\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_disabled.css";\n@import "../../../mixins/_rounded.css";\n@import "../../../mixins/_shadow.css";\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n.ck.ck-list {\n\t@mixin ck-rounded-corners;\n\n\tlist-style-type: none;\n\tbackground: var(--ck-color-list-background);\n\n\t/* A spacing at the beginning and end of the list */\n\tpadding: var(--ck-spacing-small) 0;\n}\n\n.ck.ck-list__item {\n\tcursor: default;\n\n\t/* Almost as wide as menu bar items. */\n\tmin-width: 15em;\n\n\t& > .ck-button:not(.ck-list-item-button) {\n\t\tpadding: var(--ck-spacing-tiny) calc(2 * var(--ck-spacing-standard));\n\t\tmin-height: unset;\n\t\twidth: 100%;\n\t\tborder-radius: 0;\n\n\t\t@mixin ck-dir ltr {\n\t\t\ttext-align: left;\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\ttext-align: right;\n\t\t}\n\n\t\t& .ck-button__label {\n\t\t\t/* https://github.com/ckeditor/ckeditor5-heading/issues/63 */\n\t\t\tline-height: calc(var(--ck-line-height-base) * var(--ck-font-size-base));\n\t\t}\n\n\t\t&:active {\n\t\t\tbox-shadow: none;\n\t\t}\n\n\t\t&.ck-on {\n\t\t\tbackground: var(--ck-color-list-button-on-background);\n\t\t\tcolor: var(--ck-color-list-button-on-text);\n\n\t\t\t&:active {\n\t\t\t\tbox-shadow: none;\n\t\t\t}\n\n\t\t\t&:hover:not(.ck-disabled) {\n\t\t\t\tbackground: var(--ck-color-list-button-on-background-focus);\n\t\t\t}\n\n\t\t\t&:focus:not(.ck-disabled) {\n\t\t\t\tborder-color: var(--ck-color-base-background);\n\t\t\t}\n\t\t}\n\n\t\t&:hover:not(.ck-disabled) {\n\t\t\tbackground: var(--ck-color-list-button-hover-background);\n\t\t}\n\t}\n\n\t/* It\'s unnecessary to change the background/text of a switch toggle; it has different ways\n\tof conveying its state (like the switcher) */\n\t& > .ck-button.ck-switchbutton {\n\t\t&.ck-on {\n\t\t\tbackground: var(--ck-color-list-background);\n\t\t\tcolor: inherit;\n\n\t\t\t&:hover:not(.ck-disabled) {\n\t\t\t\tbackground: var(--ck-color-list-button-hover-background);\n\t\t\t\tcolor: inherit;\n\t\t\t}\n\t\t}\n\t}\n}\n\n.ck-list .ck-list__group {\n\tpadding-top: var(--ck-spacing-medium);\n\n\t/* Lists come with an inner vertical padding. Don\'t duplicate it. */\n\t&:first-child {\n\t\tpadding-top: 0;\n\t}\n\n\t/* The group should have a border when it\'s not the first item. */\n\t*:not(.ck-hidden) ~ & {\n\t\tborder-top: 1px solid var(--ck-color-base-border);\n\t}\n\n\t& > .ck-label {\n\t\tfont-size: 11px;\n\t\tfont-weight: bold;\n\t\tpadding: var(--ck-spacing-medium) var(--ck-spacing-large) 0;\n\t}\n}\n\n.ck.ck-list__separator {\n\theight: 1px;\n\twidth: 100%;\n\tbackground: var(--ck-color-base-border);\n\n\t/* Give the separator some air */\n\tmargin: var(--ck-spacing-small) 0;\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n"],sourceRoot:""}]);const a=s},4782:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-menu-bar{background:var(--ck-color-base-background);border:1px solid var(--ck-color-toolbar-border);display:flex;flex-wrap:wrap;gap:var(--ck-spacing-small);justify-content:flex-start;padding:var(--ck-spacing-small);width:100%}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/menubar/menubar.css"],names:[],mappings:"AAKA,gBAIC,0CAA2C,CAG3C,+CAAgD,CANhD,YAAa,CACb,cAAe,CAIf,2BAA4B,CAH5B,0BAA2B,CAE3B,+BAAgC,CAGhC,UACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-menu-bar {\n\tdisplay: flex;\n\tflex-wrap: wrap;\n\tjustify-content: flex-start;\n\tbackground: var(--ck-color-base-background);\n\tpadding: var(--ck-spacing-small);\n\tgap: var(--ck-spacing-small);\n\tborder: 1px solid var(--ck-color-toolbar-border);\n\twidth: 100%;\n}\n"],sourceRoot:""}]);const a=s},55:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-menu-bar__menu{display:block;font-size:inherit;position:relative}.ck.ck-menu-bar__menu.ck-menu-bar__menu_top-level{max-width:100%}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/menubar/menubarmenu.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/menubar/menubarmenu.css"],names:[],mappings:"AAKA,sBACC,aAAc,CCCd,iBAAkB,CDAlB,iBACD,CCCC,kDACC,cACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-menu-bar__menu {\n\tdisplay: block;\n\tposition: relative;\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-menu-bar__menu {\n\t/* Enable font size inheritance, which allows fluid UI scaling. */\n\tfont-size: inherit;\n\n\t&.ck-menu-bar__menu_top-level {\n\t\tmax-width: 100%;\n\t}\n}\n"],sourceRoot:""}]);const a=s},5667:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-menu-bar__menu>.ck-menu-bar__menu__button>.ck-menu-bar__menu__button__arrow{pointer-events:none;z-index:var(--ck-z-default)}.ck.ck-menu-bar__menu>.ck-menu-bar__menu__button{width:100%}.ck.ck-menu-bar__menu>.ck-menu-bar__menu__button>.ck-button__label{flex-grow:1;overflow:hidden;text-overflow:ellipsis}.ck.ck-menu-bar__menu>.ck-menu-bar__menu__button.ck-disabled>.ck-button__label{opacity:var(--ck-disabled-opacity)}[dir=ltr] .ck.ck-menu-bar__menu>.ck-menu-bar__menu__button:not(.ck-button_with-text){padding-left:var(--ck-spacing-small)}[dir=rtl] .ck.ck-menu-bar__menu>.ck-menu-bar__menu__button:not(.ck-button_with-text){padding-right:var(--ck-spacing-small)}.ck.ck-menu-bar__menu.ck-menu-bar__menu_top-level>.ck-menu-bar__menu__button{min-height:unset;padding:var(--ck-spacing-small) var(--ck-spacing-medium)}.ck.ck-menu-bar__menu.ck-menu-bar__menu_top-level>.ck-menu-bar__menu__button .ck-button__label{line-height:unset;width:unset}.ck.ck-menu-bar__menu.ck-menu-bar__menu_top-level>.ck-menu-bar__menu__button.ck-on{border-bottom-left-radius:0;border-bottom-right-radius:0}.ck.ck-menu-bar__menu.ck-menu-bar__menu_top-level>.ck-menu-bar__menu__button .ck-icon{display:none}.ck.ck-menu-bar__menu:not(.ck-menu-bar__menu_top-level) .ck-menu-bar__menu__button{border-radius:0}.ck.ck-menu-bar__menu:not(.ck-menu-bar__menu_top-level) .ck-menu-bar__menu__button>.ck-menu-bar__menu__button__arrow{width:var(--ck-dropdown-arrow-size)}[dir=ltr] .ck.ck-menu-bar__menu:not(.ck-menu-bar__menu_top-level) .ck-menu-bar__menu__button>.ck-menu-bar__menu__button__arrow{margin-left:var(--ck-spacing-standard);margin-right:calc(var(--ck-spacing-small)*-1);transform:rotate(-90deg)}[dir=rtl] .ck.ck-menu-bar__menu:not(.ck-menu-bar__menu_top-level) .ck-menu-bar__menu__button>.ck-menu-bar__menu__button__arrow{left:var(--ck-spacing-standard);margin-left:calc(var(--ck-spacing-small)*-1);margin-right:var(--ck-spacing-small);transform:rotate(90deg)}.ck.ck-menu-bar__menu:not(.ck-menu-bar__menu_top-level) .ck-menu-bar__menu__button.ck-disabled>.ck-menu-bar__menu__button__arrow{opacity:var(--ck-disabled-opacity)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/menubar/menubarmenubutton.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/menubar/menubarmenubutton.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_disabled.css"],names:[],mappings:"AAMC,mFACC,mBAAoB,CACpB,2BACD,CCIA,iDACC,UAuBD,CArBC,mEACC,WAAY,CACZ,eAAgB,CAChB,sBACD,CAEA,+ECbD,kCDeC,CAGC,qFACC,oCACD,CAIA,qFACC,qCACD,CAOF,6EAEC,gBAAiB,CADjB,wDAgBD,CAbC,+FAEC,iBAAkB,CADlB,WAED,CAEA,mFACC,2BAA4B,CAC5B,4BACD,CAEA,sFACC,YACD,CAMD,mFACC,eA+BD,CA7BC,qHACC,mCAuBD,CAxBA,+HAOE,sCAAuC,CAGvC,6CAAgD,CANhD,wBAoBF,CAxBA,+HAgBE,+BAAgC,CAMhC,4CAA+C,CAH/C,oCAAqC,CALrC,uBAUF,CAEA,iICpFD,kCDsFC",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-menu-bar__menu {\n\t& > .ck-menu-bar__menu__button > .ck-menu-bar__menu__button__arrow {\n\t\tpointer-events: none;\n\t\tz-index: var(--ck-z-default);\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_disabled.css";\n@import "../../mixins/_button.css";\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n.ck.ck-menu-bar__menu {\n\t/*\n\t * All menu buttons.\n\t */\n\t& > .ck-menu-bar__menu__button {\n\t\twidth: 100%;\n\n\t\t& > .ck-button__label {\n\t\t\tflex-grow: 1;\n\t\t\toverflow: hidden;\n\t\t\ttext-overflow: ellipsis;\n\t\t}\n\n\t\t&.ck-disabled > .ck-button__label {\n\t\t\t@mixin ck-disabled;\n\t\t}\n\n\t\t@mixin ck-dir ltr {\n\t\t\t&:not(.ck-button_with-text) {\n\t\t\t\tpadding-left: var(--ck-spacing-small);\n\t\t\t}\n\t\t}\n\n\t\t@mixin ck-dir rtl {\n\t\t\t&:not(.ck-button_with-text) {\n\t\t\t\tpadding-right: var(--ck-spacing-small);\n\t\t\t}\n\t\t}\n\t}\n\n\t/*\n\t * Top-level menu buttons only.\n\t */\n\t&.ck-menu-bar__menu_top-level > .ck-menu-bar__menu__button {\n\t\tpadding: var(--ck-spacing-small) var(--ck-spacing-medium);\n\t\tmin-height: unset;\n\n\t\t& .ck-button__label {\n\t\t\twidth: unset;\n\t\t\tline-height: unset;\n\t\t}\n\n\t\t&.ck-on {\n\t\t\tborder-bottom-left-radius: 0;\n\t\t\tborder-bottom-right-radius: 0;\n\t\t}\n\n\t\t& .ck-icon {\n\t\t\tdisplay: none;\n\t\t}\n\t}\n\n\t/*\n\t * Sub-menu buttons.\n\t */\n\t&:not(.ck-menu-bar__menu_top-level) .ck-menu-bar__menu__button {\n\t\tborder-radius: 0;\n\n\t\t& > .ck-menu-bar__menu__button__arrow {\n\t\t\twidth: var(--ck-dropdown-arrow-size);\n\n\t\t\t@mixin ck-dir ltr {\n\t\t\t\ttransform: rotate(-90deg);\n\n\t\t\t\t/* A space to accommodate the triangle. */\n\t\t\t\tmargin-left: var(--ck-spacing-standard);\n\n\t\t\t\t/* Nudge the arrow gently to the right because its center of gravity is to the left */\n\t\t\t\tmargin-right: calc(-1 * var(--ck-spacing-small));\n\t\t\t}\n\n\t\t\t@mixin ck-dir rtl {\n\t\t\t\ttransform: rotate(90deg);\n\n\t\t\t\tleft: var(--ck-spacing-standard);\n\n\t\t\t\t/* A space to accommodate the triangle. */\n\t\t\t\tmargin-right: var(--ck-spacing-small);\n\n\t\t\t\t/* Nudge the arrow gently to the left because its center of gravity is to the right (after rotation). */\n\t\t\t\tmargin-left: calc(-1 * var(--ck-spacing-small));\n\t\t\t}\n\t\t}\n\n\t\t&.ck-disabled > .ck-menu-bar__menu__button__arrow {\n\t\t\t@mixin ck-disabled;\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A class which indicates that an element holding it is disabled.\n */\n@define-mixin ck-disabled {\n\topacity: var(--ck-disabled-opacity);\n}\n"],sourceRoot:""}]);const a=s},1214:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-menu-bar-menu-item-min-width:18em}.ck.ck-menu-bar__menu .ck.ck-menu-bar__menu__item{min-width:var(--ck-menu-bar-menu-item-min-width)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/menubar/menubarmenulistitem.css"],names:[],mappings:"AAKA,MACC,sCACD,CAEA,kDACC,gDACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-menu-bar-menu-item-min-width: 18em;\n}\n\n.ck.ck-menu-bar__menu .ck.ck-menu-bar__menu__item {\n\tmin-width: var(--ck-menu-bar-menu-item-min-width);\n}\n"],sourceRoot:""}]);const a=s},5078:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-menu-bar__menu .ck-button.ck-menu-bar__menu__item__button{border-radius:0}.ck.ck-menu-bar__menu .ck-button.ck-menu-bar__menu__item__button>.ck-spinner-container,.ck.ck-menu-bar__menu .ck-button.ck-menu-bar__menu__item__button>.ck-spinner-container .ck-spinner{--ck-toolbar-spinner-size:20px}.ck.ck-menu-bar__menu .ck-button.ck-menu-bar__menu__item__button>.ck-spinner-container{font-size:var(--ck-icon-font-size)}[dir=ltr] .ck.ck-menu-bar__menu .ck-button.ck-menu-bar__menu__item__button>.ck-spinner-container{margin-right:var(--ck-spacing-medium)}[dir=rtl] .ck.ck-menu-bar__menu .ck-button.ck-menu-bar__menu__item__button>.ck-spinner-container{margin-left:var(--ck-spacing-medium)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/menubar/menubarmenulistitembutton.css"],names:[],mappings:"AAWC,iEACC,eAoBD,CAlBC,0LAGC,8BACD,CAEA,uFAEC,kCASD,CAXA,iGAKE,qCAMF,CAXA,iGASE,oCAEF",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n.ck.ck-menu-bar__menu {\n\t/*\n\t * List item buttons.\n\t */\n\t& .ck-button.ck-menu-bar__menu__item__button {\n\t\tborder-radius: 0;\n\n\t\t& > .ck-spinner-container,\n\t\t& > .ck-spinner-container .ck-spinner {\n\t\t\t/* These styles correspond to .ck-icon so that the spinner seamlessly replaces the icon. */\n\t\t\t--ck-toolbar-spinner-size: 20px;\n\t\t}\n\n\t\t& > .ck-spinner-container {\n\t\t\t/* This ensures margins corresponding to the .ck-icon. */\n\t\t\tfont-size: var(--ck-icon-font-size);\n\n\t\t\t@mixin ck-dir ltr {\n\t\t\t\tmargin-right: var(--ck-spacing-medium);\n\t\t\t}\n\n\t\t\t@mixin ck-dir rtl {\n\t\t\t\tmargin-left: var(--ck-spacing-medium);\n\t\t\t}\n\t\t}\n\t}\n}\n\n\n'],sourceRoot:""}]);const a=s},4873:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-menu-bar-menu-max-width:75vw;--ck-menu-bar-nested-menu-horizontal-offset:5px}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel{max-width:var(--ck-menu-bar-menu-max-width);position:absolute;z-index:var(--ck-z-panel)}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_ne,.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_nw{bottom:100%}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_se,.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_sw{bottom:auto;top:100%}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_ne,.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_se{left:0}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_nw,.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_sw{right:0}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_en,.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_es{left:calc(100% - var(--ck-menu-bar-nested-menu-horizontal-offset))}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_es{top:0}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_en{bottom:0}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_wn,.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_ws{right:calc(100% - var(--ck-menu-bar-nested-menu-horizontal-offset))}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_ws{top:0}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_wn{bottom:0}:root{--ck-menu-bar-menu-panel-max-width:75vw}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel{border-radius:0}.ck-rounded-corners .ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel,.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel{background:var(--ck-color-dropdown-panel-background);border:1px solid var(--ck-color-dropdown-panel-border);bottom:0;box-shadow:var(--ck-drop-shadow),0 0;height:fit-content;max-width:var(--ck-menu-bar-menu-panel-max-width)}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_es,.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_se{border-top-left-radius:0}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_sw,.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_ws{border-top-right-radius:0}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_en,.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_ne{border-bottom-left-radius:0}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_nw,.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel.ck-menu-bar__menu__panel_position_wn{border-bottom-right-radius:0}.ck.ck-menu-bar__menu>.ck.ck-menu-bar__menu__panel:focus{outline:none}.ck.ck-menu-bar .ck-list-item-button:active,.ck.ck-menu-bar .ck-list-item-button:focus{border-color:transparent;box-shadow:none}.ck.ck-menu-bar.ck-menu-bar_focus-border-enabled .ck-list-item-button:active,.ck.ck-menu-bar.ck-menu-bar_focus-border-enabled .ck-list-item-button:focus{border:var(--ck-focus-ring);box-shadow:var(--ck-focus-outer-shadow),0 0;outline:none;position:relative;z-index:2}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/menubar/menubarmenupanel.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/menubar/menubarmenupanel.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_focus.css"],names:[],mappings:"AAKA,MACC,iCAAkC,CAClC,+CACD,CAEA,mDAEC,2CAA4C,CAC5C,iBAAkB,CAFlB,yBAkDD,CA9CC,gLAEC,WACD,CAEA,gLAGC,WAAY,CADZ,QAED,CAEA,gLAEC,MACD,CAEA,gLAEC,OACD,CAEA,gLAEC,kEACD,CAEA,wFACC,KACD,CAEA,wFACC,QACD,CAEA,gLAEC,mEACD,CAEA,wFACC,KACD,CAEA,wFACC,QACD,CCnDD,MACC,uCACD,CAEA,mDCFC,eDoCD,CAlCA,6ICEE,qCDgCF,CAlCA,mDAIC,oDAAqD,CACrD,sDAAuD,CACvD,QAAS,CEVT,oCAA8B,CFW9B,kBAAmB,CACnB,iDA0BD,CAvBC,gLAEC,wBACD,CAEA,gLAEC,yBACD,CAEA,gLAEC,2BACD,CAEA,gLAEC,4BACD,CAEA,yDACC,YACD,CAKC,uFAEC,wBAAyB,CACzB,eACD,CAIA,yJGhDD,2BAA2B,CDF3B,2CAA8B,CCC9B,YAAa,CHoDX,iBAAkB,CAClB,SAID",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-menu-bar-menu-max-width: 75vw;\n\t--ck-menu-bar-nested-menu-horizontal-offset: 5px;\n}\n\n.ck.ck-menu-bar__menu > .ck.ck-menu-bar__menu__panel {\n\tz-index: var(--ck-z-panel);\n\tmax-width: var(--ck-menu-bar-menu-max-width);\n\tposition: absolute;\n\n\t&.ck-menu-bar__menu__panel_position_ne,\n\t&.ck-menu-bar__menu__panel_position_nw {\n\t\tbottom: 100%;\n\t}\n\n\t&.ck-menu-bar__menu__panel_position_se,\n\t&.ck-menu-bar__menu__panel_position_sw {\n\t\ttop: 100%;\n\t\tbottom: auto;\n\t}\n\n\t&.ck-menu-bar__menu__panel_position_ne,\n\t&.ck-menu-bar__menu__panel_position_se {\n\t\tleft: 0px;\n\t}\n\n\t&.ck-menu-bar__menu__panel_position_nw,\n\t&.ck-menu-bar__menu__panel_position_sw {\n\t\tright: 0px;\n\t}\n\n\t&.ck-menu-bar__menu__panel_position_es,\n\t&.ck-menu-bar__menu__panel_position_en {\n\t\tleft: calc( 100% - var(--ck-menu-bar-nested-menu-horizontal-offset) );\n\t}\n\n\t&.ck-menu-bar__menu__panel_position_es {\n\t\ttop: 0px;\n\t}\n\n\t&.ck-menu-bar__menu__panel_position_en {\n\t\tbottom: 0px;\n\t}\n\n\t&.ck-menu-bar__menu__panel_position_ws,\n\t&.ck-menu-bar__menu__panel_position_wn {\n\t\tright: calc( 100% - var(--ck-menu-bar-nested-menu-horizontal-offset) );\n\t}\n\n\t&.ck-menu-bar__menu__panel_position_ws {\n\t\ttop: 0px;\n\t}\n\n\t&.ck-menu-bar__menu__panel_position_wn {\n\t\tbottom: 0px;\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_rounded.css";\n@import "../../../mixins/_shadow.css";\n@import "../../../mixins/_focus.css";\n\n:root {\n\t--ck-menu-bar-menu-panel-max-width: 75vw;\n}\n\n.ck.ck-menu-bar__menu > .ck.ck-menu-bar__menu__panel {\n\t@mixin ck-rounded-corners;\n\t@mixin ck-drop-shadow;\n\n\tbackground: var(--ck-color-dropdown-panel-background);\n\tborder: 1px solid var(--ck-color-dropdown-panel-border);\n\tbottom: 0;\n\theight: fit-content;\n\tmax-width: var(--ck-menu-bar-menu-panel-max-width);\n\n\t/* Corner border radius consistent with the button. */\n\t&.ck-menu-bar__menu__panel_position_es,\n\t&.ck-menu-bar__menu__panel_position_se {\n\t\tborder-top-left-radius: 0;\n\t}\n\n\t&.ck-menu-bar__menu__panel_position_ws,\n\t&.ck-menu-bar__menu__panel_position_sw {\n\t\tborder-top-right-radius: 0;\n\t}\n\n\t&.ck-menu-bar__menu__panel_position_en,\n\t&.ck-menu-bar__menu__panel_position_ne {\n\t\tborder-bottom-left-radius: 0;\n\t}\n\n\t&.ck-menu-bar__menu__panel_position_wn,\n\t&.ck-menu-bar__menu__panel_position_nw {\n\t\tborder-bottom-right-radius: 0;\n\t}\n\n\t&:focus {\n\t\toutline: none;\n\t}\n}\n\n.ck.ck-menu-bar {\n\t& .ck-list-item-button {\n\t\t&:focus,\n\t\t&:active {\n\t\t\tborder-color: transparent;\n\t\t\tbox-shadow: none;\n\t\t}\n\t}\n\n\t&.ck-menu-bar_focus-border-enabled .ck-list-item-button {\n\t\t&:focus,\n\t\t&:active {\n\t\t\t/* Fix truncated shadows due to rendering order. */\n\t\t\tposition: relative;\n\t\t\tz-index: 2;\n\n\t\t\t@mixin ck-focus-ring;\n\t\t\t@mixin ck-box-shadow var(--ck-focus-outer-shadow);\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A helper to combine multiple shadows.\n */\n@define-mixin ck-box-shadow $shadowA, $shadowB: 0 0 {\n\tbox-shadow: $shadowA, $shadowB;\n}\n\n/**\n * Gives an element a drop shadow so it looks like a floating panel.\n */\n@define-mixin ck-drop-shadow {\n\t@mixin ck-box-shadow var(--ck-drop-shadow);\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A visual style of focused element's border.\n */\n@define-mixin ck-focus-ring {\n\t/* Disable native outline. */\n\toutline: none;\n\tborder: var(--ck-focus-ring)\n}\n"],sourceRoot:""}]);const a=s},5615:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,':root{--ck-balloon-panel-arrow-z-index:calc(var(--ck-z-default) - 3)}.ck.ck-balloon-panel{display:none;position:absolute;z-index:var(--ck-z-panel)}.ck.ck-balloon-panel.ck-balloon-panel_with-arrow:after,.ck.ck-balloon-panel.ck-balloon-panel_with-arrow:before{content:"";position:absolute}.ck.ck-balloon-panel.ck-balloon-panel_with-arrow:before{z-index:var(--ck-balloon-panel-arrow-z-index)}.ck.ck-balloon-panel.ck-balloon-panel_with-arrow:after{z-index:calc(var(--ck-balloon-panel-arrow-z-index) + 1)}.ck.ck-balloon-panel[class*=arrow_n]:before{z-index:var(--ck-balloon-panel-arrow-z-index)}.ck.ck-balloon-panel[class*=arrow_n]:after{z-index:calc(var(--ck-balloon-panel-arrow-z-index) + 1)}.ck.ck-balloon-panel[class*=arrow_s]:before{z-index:var(--ck-balloon-panel-arrow-z-index)}.ck.ck-balloon-panel[class*=arrow_s]:after{z-index:calc(var(--ck-balloon-panel-arrow-z-index) + 1)}.ck.ck-balloon-panel.ck-balloon-panel_visible{display:block}:root{--ck-balloon-border-width:1px;--ck-balloon-arrow-offset:2px;--ck-balloon-arrow-height:10px;--ck-balloon-arrow-half-width:8px;--ck-balloon-arrow-drop-shadow:0 2px 2px var(--ck-color-shadow-drop)}.ck.ck-balloon-panel{border-radius:0}.ck-rounded-corners .ck.ck-balloon-panel,.ck.ck-balloon-panel.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-balloon-panel{background:var(--ck-color-panel-background);border:var(--ck-balloon-border-width) solid var(--ck-color-panel-border);box-shadow:var(--ck-drop-shadow),0 0;min-height:15px}.ck.ck-balloon-panel.ck-balloon-panel_with-arrow:after,.ck.ck-balloon-panel.ck-balloon-panel_with-arrow:before{border-style:solid;height:0;width:0}.ck.ck-balloon-panel[class*=arrow_n]:after,.ck.ck-balloon-panel[class*=arrow_n]:before{border-width:0 var(--ck-balloon-arrow-half-width) var(--ck-balloon-arrow-height) var(--ck-balloon-arrow-half-width)}.ck.ck-balloon-panel[class*=arrow_n]:before{border-color:transparent transparent var(--ck-color-panel-border) transparent;margin-top:calc(var(--ck-balloon-border-width)*-1)}.ck.ck-balloon-panel[class*=arrow_n]:after{border-color:transparent transparent var(--ck-color-panel-background) transparent;margin-top:calc(var(--ck-balloon-arrow-offset) - var(--ck-balloon-border-width))}.ck.ck-balloon-panel[class*=arrow_s]:after,.ck.ck-balloon-panel[class*=arrow_s]:before{border-width:var(--ck-balloon-arrow-height) var(--ck-balloon-arrow-half-width) 0 var(--ck-balloon-arrow-half-width)}.ck.ck-balloon-panel[class*=arrow_s]:before{border-color:var(--ck-color-panel-border) transparent transparent;filter:drop-shadow(var(--ck-balloon-arrow-drop-shadow));margin-bottom:calc(var(--ck-balloon-border-width)*-1)}.ck.ck-balloon-panel[class*=arrow_s]:after{border-color:var(--ck-color-panel-background) transparent transparent transparent;margin-bottom:calc(var(--ck-balloon-arrow-offset) - var(--ck-balloon-border-width))}.ck.ck-balloon-panel[class*=arrow_e]:after,.ck.ck-balloon-panel[class*=arrow_e]:before{border-width:var(--ck-balloon-arrow-half-width) 0 var(--ck-balloon-arrow-half-width) var(--ck-balloon-arrow-height)}.ck.ck-balloon-panel[class*=arrow_e]:before{border-color:transparent transparent transparent var(--ck-color-panel-border);margin-right:calc(var(--ck-balloon-border-width)*-1)}.ck.ck-balloon-panel[class*=arrow_e]:after{border-color:transparent transparent transparent var(--ck-color-panel-background);margin-right:calc(var(--ck-balloon-arrow-offset) - var(--ck-balloon-border-width))}.ck.ck-balloon-panel[class*=arrow_w]:after,.ck.ck-balloon-panel[class*=arrow_w]:before{border-width:var(--ck-balloon-arrow-half-width) var(--ck-balloon-arrow-height) var(--ck-balloon-arrow-half-width) 0}.ck.ck-balloon-panel[class*=arrow_w]:before{border-color:transparent var(--ck-color-panel-border) transparent transparent;margin-left:calc(var(--ck-balloon-border-width)*-1)}.ck.ck-balloon-panel[class*=arrow_w]:after{border-color:transparent var(--ck-color-panel-background) transparent transparent;margin-left:calc(var(--ck-balloon-arrow-offset) - var(--ck-balloon-border-width))}.ck.ck-balloon-panel.ck-balloon-panel_arrow_n:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_n:before{left:50%;margin-left:calc(var(--ck-balloon-arrow-half-width)*-1);top:calc(var(--ck-balloon-arrow-height)*-1)}.ck.ck-balloon-panel.ck-balloon-panel_arrow_nw:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_nw:before{left:calc(var(--ck-balloon-arrow-half-width)*2);top:calc(var(--ck-balloon-arrow-height)*-1)}.ck.ck-balloon-panel.ck-balloon-panel_arrow_ne:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_ne:before{right:calc(var(--ck-balloon-arrow-half-width)*2);top:calc(var(--ck-balloon-arrow-height)*-1)}.ck.ck-balloon-panel.ck-balloon-panel_arrow_s:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_s:before{bottom:calc(var(--ck-balloon-arrow-height)*-1);left:50%;margin-left:calc(var(--ck-balloon-arrow-half-width)*-1)}.ck.ck-balloon-panel.ck-balloon-panel_arrow_sw:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_sw:before{bottom:calc(var(--ck-balloon-arrow-height)*-1);left:calc(var(--ck-balloon-arrow-half-width)*2)}.ck.ck-balloon-panel.ck-balloon-panel_arrow_se:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_se:before{bottom:calc(var(--ck-balloon-arrow-height)*-1);right:calc(var(--ck-balloon-arrow-half-width)*2)}.ck.ck-balloon-panel.ck-balloon-panel_arrow_sme:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_sme:before{bottom:calc(var(--ck-balloon-arrow-height)*-1);margin-right:calc(var(--ck-balloon-arrow-half-width)*2);right:25%}.ck.ck-balloon-panel.ck-balloon-panel_arrow_smw:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_smw:before{bottom:calc(var(--ck-balloon-arrow-height)*-1);left:25%;margin-left:calc(var(--ck-balloon-arrow-half-width)*2)}.ck.ck-balloon-panel.ck-balloon-panel_arrow_nme:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_nme:before{margin-right:calc(var(--ck-balloon-arrow-half-width)*2);right:25%;top:calc(var(--ck-balloon-arrow-height)*-1)}.ck.ck-balloon-panel.ck-balloon-panel_arrow_nmw:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_nmw:before{left:25%;margin-left:calc(var(--ck-balloon-arrow-half-width)*2);top:calc(var(--ck-balloon-arrow-height)*-1)}.ck.ck-balloon-panel.ck-balloon-panel_arrow_e:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_e:before{margin-top:calc(var(--ck-balloon-arrow-half-width)*-1);right:calc(var(--ck-balloon-arrow-height)*-1);top:50%}.ck.ck-balloon-panel.ck-balloon-panel_arrow_w:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_w:before{left:calc(var(--ck-balloon-arrow-height)*-1);margin-top:calc(var(--ck-balloon-arrow-half-width)*-1);top:50%}',"",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/panel/balloonpanel.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/panel/balloonpanel.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css"],names:[],mappings:"AAKA,MAEC,8DACD,CAEA,qBACC,YAAa,CACb,iBAAkB,CAElB,yBAyCD,CAtCE,+GAEC,UAAW,CACX,iBACD,CAEA,wDACC,6CACD,CAEA,uDACC,uDACD,CAIA,4CACC,6CACD,CAEA,2CACC,uDACD,CAIA,4CACC,6CACD,CAEA,2CACC,uDACD,CAGD,8CACC,aACD,CC9CD,MACC,6BAA8B,CAC9B,6BAA8B,CAC9B,8BAA+B,CAC/B,iCAAkC,CAClC,oEACD,CAEA,qBCLC,eDmMD,CA9LA,iFCDE,qCD+LF,CA9LA,qBAMC,2CAA4C,CAC5C,wEAAyE,CEdzE,oCAA8B,CFW9B,eA0LD,CApLE,+GAIC,kBAAmB,CADnB,QAAS,CADT,OAGD,CAIA,uFAEC,mHACD,CAEA,4CACC,6EAA8E,CAC9E,kDACD,CAEA,2CACC,iFAAkF,CAClF,gFACD,CAIA,uFAEC,mHACD,CAEA,4CACC,iEAAkE,CAClE,uDAAwD,CACxD,qDACD,CAEA,2CACC,iFAAkF,CAClF,mFACD,CAIA,uFAEC,mHACD,CAEA,4CACC,6EAA8E,CAC9E,oDACD,CAEA,2CACC,iFAAkF,CAClF,kFACD,CAIA,uFAEC,mHACD,CAEA,4CACC,6EAA8E,CAC9E,mDACD,CAEA,2CACC,iFAAkF,CAClF,iFACD,CAIA,yGAEC,QAAS,CACT,uDAA0D,CAC1D,2CACD,CAIA,2GAEC,+CAAkD,CAClD,2CACD,CAIA,2GAEC,gDAAmD,CACnD,2CACD,CAIA,yGAIC,8CAAiD,CAFjD,QAAS,CACT,uDAED,CAIA,2GAGC,8CAAiD,CADjD,+CAED,CAIA,2GAGC,8CAAiD,CADjD,gDAED,CAIA,6GAIC,8CAAiD,CADjD,uDAA0D,CAD1D,SAGD,CAIA,6GAIC,8CAAiD,CAFjD,QAAS,CACT,sDAED,CAIA,6GAGC,uDAA0D,CAD1D,SAAU,CAEV,2CACD,CAIA,6GAEC,QAAS,CACT,sDAAyD,CACzD,2CACD,CAIA,yGAGC,sDAAyD,CADzD,6CAAgD,CAEhD,OACD,CAIA,yGAEC,4CAA+C,CAC/C,sDAAyD,CACzD,OACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t/* Make sure the balloon arrow does not float over its children. */\n\t--ck-balloon-panel-arrow-z-index: calc(var(--ck-z-default) - 3);\n}\n\n.ck.ck-balloon-panel {\n\tdisplay: none;\n\tposition: absolute;\n\n\tz-index: var(--ck-z-panel);\n\n\t&.ck-balloon-panel_with-arrow {\n\t\t&::before,\n\t\t&::after {\n\t\t\tcontent: "";\n\t\t\tposition: absolute;\n\t\t}\n\n\t\t&::before {\n\t\t\tz-index: var(--ck-balloon-panel-arrow-z-index);\n\t\t}\n\n\t\t&::after {\n\t\t\tz-index: calc(var(--ck-balloon-panel-arrow-z-index) + 1);\n\t\t}\n\t}\n\n\t&[class*="arrow_n"] {\n\t\t&::before {\n\t\t\tz-index: var(--ck-balloon-panel-arrow-z-index);\n\t\t}\n\n\t\t&::after {\n\t\t\tz-index: calc(var(--ck-balloon-panel-arrow-z-index) + 1);\n\t\t}\n\t}\n\n\t&[class*="arrow_s"] {\n\t\t&::before {\n\t\t\tz-index: var(--ck-balloon-panel-arrow-z-index);\n\t\t}\n\n\t\t&::after {\n\t\t\tz-index: calc(var(--ck-balloon-panel-arrow-z-index) + 1);\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_visible {\n\t\tdisplay: block;\n\t}\n}\n','/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_rounded.css";\n@import "../../../mixins/_shadow.css";\n\n:root {\n\t--ck-balloon-border-width: 1px;\n\t--ck-balloon-arrow-offset: 2px;\n\t--ck-balloon-arrow-height: 10px;\n\t--ck-balloon-arrow-half-width: 8px;\n\t--ck-balloon-arrow-drop-shadow: 0 2px 2px var(--ck-color-shadow-drop);\n}\n\n.ck.ck-balloon-panel {\n\t@mixin ck-rounded-corners;\n\t@mixin ck-drop-shadow;\n\n\tmin-height: 15px;\n\n\tbackground: var(--ck-color-panel-background);\n\tborder: var(--ck-balloon-border-width) solid var(--ck-color-panel-border);\n\n\t&.ck-balloon-panel_with-arrow {\n\t\t&::before,\n\t\t&::after {\n\t\t\twidth: 0;\n\t\t\theight: 0;\n\t\t\tborder-style: solid;\n\t\t}\n\t}\n\n\t&[class*="arrow_n"] {\n\t\t&::before,\n\t\t&::after {\n\t\t\tborder-width: 0 var(--ck-balloon-arrow-half-width) var(--ck-balloon-arrow-height) var(--ck-balloon-arrow-half-width);\n\t\t}\n\n\t\t&::before {\n\t\t\tborder-color: transparent transparent var(--ck-color-panel-border) transparent;\n\t\t\tmargin-top: calc( -1 * var(--ck-balloon-border-width) );\n\t\t}\n\n\t\t&::after {\n\t\t\tborder-color: transparent transparent var(--ck-color-panel-background) transparent;\n\t\t\tmargin-top: calc( var(--ck-balloon-arrow-offset) - var(--ck-balloon-border-width) );\n\t\t}\n\t}\n\n\t&[class*="arrow_s"] {\n\t\t&::before,\n\t\t&::after {\n\t\t\tborder-width: var(--ck-balloon-arrow-height) var(--ck-balloon-arrow-half-width) 0 var(--ck-balloon-arrow-half-width);\n\t\t}\n\n\t\t&::before {\n\t\t\tborder-color: var(--ck-color-panel-border) transparent transparent;\n\t\t\tfilter: drop-shadow(var(--ck-balloon-arrow-drop-shadow));\n\t\t\tmargin-bottom: calc( -1 * var(--ck-balloon-border-width) );\n\t\t}\n\n\t\t&::after {\n\t\t\tborder-color: var(--ck-color-panel-background) transparent transparent transparent;\n\t\t\tmargin-bottom: calc( var(--ck-balloon-arrow-offset) - var(--ck-balloon-border-width) );\n\t\t}\n\t}\n\n\t&[class*="arrow_e"] {\n\t\t&::before,\n\t\t&::after {\n\t\t\tborder-width: var(--ck-balloon-arrow-half-width) 0 var(--ck-balloon-arrow-half-width) var(--ck-balloon-arrow-height);\n\t\t}\n\n\t\t&::before {\n\t\t\tborder-color: transparent transparent transparent var(--ck-color-panel-border);\n\t\t\tmargin-right: calc( -1 * var(--ck-balloon-border-width) );\n\t\t}\n\n\t\t&::after {\n\t\t\tborder-color: transparent transparent transparent var(--ck-color-panel-background);\n\t\t\tmargin-right: calc( var(--ck-balloon-arrow-offset) - var(--ck-balloon-border-width) );\n\t\t}\n\t}\n\n\t&[class*="arrow_w"] {\n\t\t&::before,\n\t\t&::after {\n\t\t\tborder-width: var(--ck-balloon-arrow-half-width) var(--ck-balloon-arrow-height) var(--ck-balloon-arrow-half-width) 0;\n\t\t}\n\n\t\t&::before {\n\t\t\tborder-color: transparent var(--ck-color-panel-border) transparent transparent;\n\t\t\tmargin-left: calc( -1 * var(--ck-balloon-border-width) );\n\t\t}\n\n\t\t&::after {\n\t\t\tborder-color: transparent var(--ck-color-panel-background) transparent transparent;\n\t\t\tmargin-left: calc( var(--ck-balloon-arrow-offset) - var(--ck-balloon-border-width) );\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_arrow_n {\n\t\t&::before,\n\t\t&::after {\n\t\t\tleft: 50%;\n\t\t\tmargin-left: calc(-1 * var(--ck-balloon-arrow-half-width));\n\t\t\ttop: calc(-1 * var(--ck-balloon-arrow-height));\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_arrow_nw {\n\t\t&::before,\n\t\t&::after {\n\t\t\tleft: calc(2 * var(--ck-balloon-arrow-half-width));\n\t\t\ttop: calc(-1 * var(--ck-balloon-arrow-height));\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_arrow_ne {\n\t\t&::before,\n\t\t&::after {\n\t\t\tright: calc(2 * var(--ck-balloon-arrow-half-width));\n\t\t\ttop: calc(-1 * var(--ck-balloon-arrow-height));\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_arrow_s {\n\t\t&::before,\n\t\t&::after {\n\t\t\tleft: 50%;\n\t\t\tmargin-left: calc(-1 * var(--ck-balloon-arrow-half-width));\n\t\t\tbottom: calc(-1 * var(--ck-balloon-arrow-height));\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_arrow_sw {\n\t\t&::before,\n\t\t&::after {\n\t\t\tleft: calc(2 * var(--ck-balloon-arrow-half-width));\n\t\t\tbottom: calc(-1 * var(--ck-balloon-arrow-height));\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_arrow_se {\n\t\t&::before,\n\t\t&::after {\n\t\t\tright: calc(2 * var(--ck-balloon-arrow-half-width));\n\t\t\tbottom: calc(-1 * var(--ck-balloon-arrow-height));\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_arrow_sme {\n\t\t&::before,\n\t\t&::after {\n\t\t\tright: 25%;\n\t\t\tmargin-right: calc(2 * var(--ck-balloon-arrow-half-width));\n\t\t\tbottom: calc(-1 * var(--ck-balloon-arrow-height));\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_arrow_smw {\n\t\t&::before,\n\t\t&::after {\n\t\t\tleft: 25%;\n\t\t\tmargin-left: calc(2 * var(--ck-balloon-arrow-half-width));\n\t\t\tbottom: calc(-1 * var(--ck-balloon-arrow-height));\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_arrow_nme {\n\t\t&::before,\n\t\t&::after {\n\t\t\tright: 25%;\n\t\t\tmargin-right: calc(2 * var(--ck-balloon-arrow-half-width));\n\t\t\ttop: calc(-1 * var(--ck-balloon-arrow-height));\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_arrow_nmw {\n\t\t&::before,\n\t\t&::after {\n\t\t\tleft: 25%;\n\t\t\tmargin-left: calc(2 * var(--ck-balloon-arrow-half-width));\n\t\t\ttop: calc(-1 * var(--ck-balloon-arrow-height));\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_arrow_e {\n\t\t&::before,\n\t\t&::after {\n\t\t\tright: calc(-1 * var(--ck-balloon-arrow-height));\n\t\t\tmargin-top: calc(-1 * var(--ck-balloon-arrow-half-width));\n\t\t\ttop: 50%;\n\t\t}\n\t}\n\n\t&.ck-balloon-panel_arrow_w {\n\t\t&::before,\n\t\t&::after {\n\t\t\tleft: calc(-1 * var(--ck-balloon-arrow-height));\n\t\t\tmargin-top: calc(-1 * var(--ck-balloon-arrow-half-width));\n\t\t\ttop: 50%;\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A helper to combine multiple shadows.\n */\n@define-mixin ck-box-shadow $shadowA, $shadowB: 0 0 {\n\tbox-shadow: $shadowA, $shadowB;\n}\n\n/**\n * Gives an element a drop shadow so it looks like a floating panel.\n */\n@define-mixin ck-drop-shadow {\n\t@mixin ck-box-shadow var(--ck-drop-shadow);\n}\n"],sourceRoot:""}]);const a=s},9938:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck .ck-balloon-rotator__navigation{align-items:center;display:flex;justify-content:center}.ck .ck-balloon-rotator__content .ck-toolbar{justify-content:center}.ck .ck-balloon-rotator__navigation{background:var(--ck-color-toolbar-background);border-bottom:1px solid var(--ck-color-toolbar-border);padding:0 var(--ck-spacing-small)}.ck .ck-balloon-rotator__navigation>*{margin-bottom:var(--ck-spacing-small);margin-right:var(--ck-spacing-small);margin-top:var(--ck-spacing-small)}.ck .ck-balloon-rotator__navigation .ck-balloon-rotator__counter{margin-left:var(--ck-spacing-small);margin-right:var(--ck-spacing-standard)}.ck .ck-balloon-rotator__content .ck.ck-annotation-wrapper{box-shadow:none}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/panel/balloonrotator.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/panel/balloonrotator.css"],names:[],mappings:"AAKA,oCAEC,kBAAmB,CADnB,YAAa,CAEb,sBACD,CAKA,6CACC,sBACD,CCXA,oCACC,6CAA8C,CAC9C,sDAAuD,CACvD,iCAgBD,CAbC,sCAGC,qCAAsC,CAFtC,oCAAqC,CACrC,kCAED,CAGA,iEAIC,mCAAoC,CAHpC,uCAID,CAMA,2DACC,eACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck .ck-balloon-rotator__navigation {\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n}\n\n/* Buttons inside a toolbar should be centered when rotator bar is wider.\n * See: https://github.com/ckeditor/ckeditor5-ui/issues/495\n */\n.ck .ck-balloon-rotator__content .ck-toolbar {\n\tjustify-content: center;\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck .ck-balloon-rotator__navigation {\n\tbackground: var(--ck-color-toolbar-background);\n\tborder-bottom: 1px solid var(--ck-color-toolbar-border);\n\tpadding: 0 var(--ck-spacing-small);\n\n\t/* Let's keep similar appearance to `ck-toolbar`. */\n\t& > * {\n\t\tmargin-right: var(--ck-spacing-small);\n\t\tmargin-top: var(--ck-spacing-small);\n\t\tmargin-bottom: var(--ck-spacing-small);\n\t}\n\n\t/* Gives counter more breath than buttons. */\n\t& .ck-balloon-rotator__counter {\n\t\tmargin-right: var(--ck-spacing-standard);\n\n\t\t/* We need to use smaller margin because of previous button's right margin. */\n\t\tmargin-left: var(--ck-spacing-small);\n\t}\n}\n\n.ck .ck-balloon-rotator__content {\n\n\t/* Disable default annotation shadow inside rotator with fake panels. */\n\t& .ck.ck-annotation-wrapper {\n\t\tbox-shadow: none;\n\t}\n}\n"],sourceRoot:""}]);const a=s},3579:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck .ck-fake-panel{position:absolute;z-index:calc(var(--ck-z-panel) - 1)}.ck .ck-fake-panel div{position:absolute}.ck .ck-fake-panel div:first-child{z-index:2}.ck .ck-fake-panel div:nth-child(2){z-index:1}:root{--ck-balloon-fake-panel-offset-horizontal:6px;--ck-balloon-fake-panel-offset-vertical:6px}.ck .ck-fake-panel div{background:var(--ck-color-panel-background);border:1px solid var(--ck-color-panel-border);border-radius:var(--ck-border-radius);box-shadow:var(--ck-drop-shadow),0 0;height:100%;min-height:15px;width:100%}.ck .ck-fake-panel div:first-child{margin-left:var(--ck-balloon-fake-panel-offset-horizontal);margin-top:var(--ck-balloon-fake-panel-offset-vertical)}.ck .ck-fake-panel div:nth-child(2){margin-left:calc(var(--ck-balloon-fake-panel-offset-horizontal)*2);margin-top:calc(var(--ck-balloon-fake-panel-offset-vertical)*2)}.ck .ck-fake-panel div:nth-child(3){margin-left:calc(var(--ck-balloon-fake-panel-offset-horizontal)*3);margin-top:calc(var(--ck-balloon-fake-panel-offset-vertical)*3)}.ck .ck-balloon-panel_arrow_s+.ck-fake-panel,.ck .ck-balloon-panel_arrow_se+.ck-fake-panel,.ck .ck-balloon-panel_arrow_sw+.ck-fake-panel{--ck-balloon-fake-panel-offset-vertical:-6px}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/panel/fakepanel.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/panel/fakepanel.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css"],names:[],mappings:"AAKA,mBACC,iBAAkB,CAGlB,mCACD,CAEA,uBACC,iBACD,CAEA,mCACC,SACD,CAEA,oCACC,SACD,CCfA,MACC,6CAA8C,CAC9C,2CACD,CAGA,uBAKC,2CAA4C,CAC5C,6CAA8C,CAC9C,qCAAsC,CCXtC,oCAA8B,CDc9B,WAAY,CAPZ,eAAgB,CAMhB,UAED,CAEA,mCACC,0DAA2D,CAC3D,uDACD,CAEA,oCACC,kEAAqE,CACrE,+DACD,CACA,oCACC,kEAAqE,CACrE,+DACD,CAGA,yIAGC,4CACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck .ck-fake-panel {\n\tposition: absolute;\n\n\t/* Fake panels should be placed under main balloon content. */\n\tz-index: calc(var(--ck-z-panel) - 1);\n}\n\n.ck .ck-fake-panel div {\n\tposition: absolute;\n}\n\n.ck .ck-fake-panel div:nth-child( 1 ) {\n\tz-index: 2;\n}\n\n.ck .ck-fake-panel div:nth-child( 2 ) {\n\tz-index: 1;\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_shadow.css";\n\n:root {\n\t--ck-balloon-fake-panel-offset-horizontal: 6px;\n\t--ck-balloon-fake-panel-offset-vertical: 6px;\n}\n\n/* Let\'s use `.ck-balloon-panel` appearance. See: balloonpanel.css. */\n.ck .ck-fake-panel div {\n\t@mixin ck-drop-shadow;\n\n\tmin-height: 15px;\n\n\tbackground: var(--ck-color-panel-background);\n\tborder: 1px solid var(--ck-color-panel-border);\n\tborder-radius: var(--ck-border-radius);\n\n\twidth: 100%;\n\theight: 100%;\n}\n\n.ck .ck-fake-panel div:nth-child( 1 ) {\n\tmargin-left: var(--ck-balloon-fake-panel-offset-horizontal);\n\tmargin-top: var(--ck-balloon-fake-panel-offset-vertical);\n}\n\n.ck .ck-fake-panel div:nth-child( 2 ) {\n\tmargin-left: calc(var(--ck-balloon-fake-panel-offset-horizontal) * 2);\n\tmargin-top: calc(var(--ck-balloon-fake-panel-offset-vertical) * 2);\n}\n.ck .ck-fake-panel div:nth-child( 3 ) {\n\tmargin-left: calc(var(--ck-balloon-fake-panel-offset-horizontal) * 3);\n\tmargin-top: calc(var(--ck-balloon-fake-panel-offset-vertical) * 3);\n}\n\n/* If balloon is positioned above element, we need to move fake panel to the top. */\n.ck .ck-balloon-panel_arrow_s + .ck-fake-panel,\n.ck .ck-balloon-panel_arrow_se + .ck-fake-panel,\n.ck .ck-balloon-panel_arrow_sw + .ck-fake-panel {\n\t--ck-balloon-fake-panel-offset-vertical: -6px;\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A helper to combine multiple shadows.\n */\n@define-mixin ck-box-shadow $shadowA, $shadowB: 0 0 {\n\tbox-shadow: $shadowA, $shadowB;\n}\n\n/**\n * Gives an element a drop shadow so it looks like a floating panel.\n */\n@define-mixin ck-drop-shadow {\n\t@mixin ck-box-shadow var(--ck-drop-shadow);\n}\n"],sourceRoot:""}]);const a=s},7289:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-sticky-panel .ck-sticky-panel__content_sticky{position:fixed;top:0;z-index:var(--ck-z-panel)}.ck.ck-sticky-panel .ck-sticky-panel__content_sticky_bottom-limit{position:absolute;top:auto}.ck.ck-sticky-panel .ck-sticky-panel__content_sticky{border-top-left-radius:0;border-top-right-radius:0;border-width:0 1px 1px;box-shadow:var(--ck-drop-shadow),0 0}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/panel/stickypanel.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/panel/stickypanel.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css"],names:[],mappings:"AAMC,qDAEC,cAAe,CACf,KAAM,CAFN,yBAGD,CAEA,kEAEC,iBAAkB,CADlB,QAED,CCPA,qDAIC,wBAAyB,CACzB,yBAA0B,CAF1B,sBAAuB,CCFxB,oCDKA",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-sticky-panel {\n\t& .ck-sticky-panel__content_sticky {\n\t\tz-index: var(--ck-z-panel); /* #315 */\n\t\tposition: fixed;\n\t\ttop: 0;\n\t}\n\n\t& .ck-sticky-panel__content_sticky_bottom-limit {\n\t\ttop: auto;\n\t\tposition: absolute;\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_shadow.css";\n\n.ck.ck-sticky-panel {\n\t& .ck-sticky-panel__content_sticky {\n\t\t@mixin ck-drop-shadow;\n\n\t\tborder-width: 0 1px 1px;\n\t\tborder-top-left-radius: 0;\n\t\tborder-top-right-radius: 0;\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A helper to combine multiple shadows.\n */\n@define-mixin ck-box-shadow $shadowA, $shadowB: 0 0 {\n\tbox-shadow: $shadowA, $shadowB;\n}\n\n/**\n * Gives an element a drop shadow so it looks like a floating panel.\n */\n@define-mixin ck-drop-shadow {\n\t@mixin ck-box-shadow var(--ck-drop-shadow);\n}\n"],sourceRoot:""}]);const a=s},871:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,'.ck-vertical-form .ck-button:after{bottom:-1px;content:"";position:absolute;right:-1px;top:-1px;width:0;z-index:1}.ck-vertical-form .ck-button:focus:after{display:none}@media screen and (max-width:600px){.ck.ck-responsive-form .ck-button:after{bottom:-1px;content:"";position:absolute;right:-1px;top:-1px;width:0;z-index:1}.ck.ck-responsive-form .ck-button:focus:after{display:none}}.ck-vertical-form>.ck-button:nth-last-child(2):after{border-right:1px solid var(--ck-color-base-border)}.ck.ck-responsive-form{padding:var(--ck-spacing-large)}.ck.ck-responsive-form:focus{outline:none}[dir=ltr] .ck.ck-responsive-form>:not(:first-child),[dir=rtl] .ck.ck-responsive-form>:not(:last-child){margin-left:var(--ck-spacing-standard)}@media screen and (max-width:600px){.ck.ck-responsive-form{padding:0;width:calc(var(--ck-input-width)*.8)}.ck.ck-responsive-form .ck-labeled-field-view{margin:var(--ck-spacing-large) var(--ck-spacing-large) 0}.ck.ck-responsive-form .ck-labeled-field-view .ck-input-number,.ck.ck-responsive-form .ck-labeled-field-view .ck-input-text{min-width:0;width:100%}.ck.ck-responsive-form .ck-labeled-field-view .ck-labeled-field-view__error{white-space:normal}.ck.ck-responsive-form>.ck-button:nth-last-child(2):after{border-right:1px solid var(--ck-color-base-border)}.ck.ck-responsive-form>.ck-button:last-child,.ck.ck-responsive-form>.ck-button:nth-last-child(2){border-radius:0;margin-top:var(--ck-spacing-large);padding:var(--ck-spacing-standard)}.ck.ck-responsive-form>.ck-button:last-child:not(:focus),.ck.ck-responsive-form>.ck-button:nth-last-child(2):not(:focus){border-top:1px solid var(--ck-color-base-border)}[dir=ltr] .ck.ck-responsive-form>.ck-button:last-child,[dir=ltr] .ck.ck-responsive-form>.ck-button:nth-last-child(2),[dir=rtl] .ck.ck-responsive-form>.ck-button:last-child,[dir=rtl] .ck.ck-responsive-form>.ck-button:nth-last-child(2){margin-left:0}[dir=rtl] .ck.ck-responsive-form>.ck-button:last-child:last-of-type,[dir=rtl] .ck.ck-responsive-form>.ck-button:nth-last-child(2):last-of-type{border-right:1px solid var(--ck-color-base-border)}}',"",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/responsive-form/responsiveform.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/responsive-form/responsiveform.css"],names:[],mappings:"AAQC,mCAMC,WAAY,CALZ,UAAW,CAEX,iBAAkB,CAClB,UAAW,CACX,QAAS,CAHT,OAAQ,CAKR,SACD,CAEA,yCACC,YACD,CCdA,oCDoBE,wCAMC,WAAY,CALZ,UAAW,CAEX,iBAAkB,CAClB,UAAW,CACX,QAAS,CAHT,OAAQ,CAKR,SACD,CAEA,8CACC,YACD,CC9BF,CCAD,qDACC,kDACD,CAEA,uBACC,+BAoED,CAlEC,6BAEC,YACD,CASC,uGACC,sCACD,CDvBD,oCCMD,uBAqBE,SAAU,CACV,oCA+CF,CA7CE,8CACC,wDAYD,CAVC,4HAEC,WAAY,CACZ,UACD,CAGA,4EACC,kBACD,CAKA,0DACC,kDACD,CAGD,iGAIC,eAAgB,CADhB,kCAAmC,CADnC,kCAmBD,CAfC,yHACC,gDACD,CARD,0OAeE,aAMF,CAJE,+IACC,kDACD,CDrEH",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css";\n\n.ck-vertical-form .ck-button {\n\t&::after {\n\t\tcontent: "";\n\t\twidth: 0;\n\t\tposition: absolute;\n\t\tright: -1px;\n\t\ttop: -1px;\n\t\tbottom: -1px;\n\t\tz-index: 1;\n\t}\n\n\t&:focus::after {\n\t\tdisplay: none;\n\t}\n}\n\n.ck.ck-responsive-form {\n\t@mixin ck-media-phone {\n\t\t& .ck-button {\n\t\t\t&::after {\n\t\t\t\tcontent: "";\n\t\t\t\twidth: 0;\n\t\t\t\tposition: absolute;\n\t\t\t\tright: -1px;\n\t\t\t\ttop: -1px;\n\t\t\t\tbottom: -1px;\n\t\t\t\tz-index: 1;\n\t\t\t}\n\n\t\t\t&:focus::after {\n\t\t\t\tdisplay: none;\n\t\t\t}\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@define-mixin ck-media-phone {\n\t@media screen and (max-width: 600px) {\n\t\t@mixin-content;\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_rwd.css";\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n.ck-vertical-form > .ck-button:nth-last-child(2)::after {\n\tborder-right: 1px solid var(--ck-color-base-border);\n}\n\n.ck.ck-responsive-form {\n\tpadding: var(--ck-spacing-large);\n\n\t&:focus {\n\t\t/* See: https://github.com/ckeditor/ckeditor5/issues/4773 */\n\t\toutline: none;\n\t}\n\n\t@mixin ck-dir ltr {\n\t\t& > :not(:first-child) {\n\t\t\tmargin-left: var(--ck-spacing-standard);\n\t\t}\n\t}\n\n\t@mixin ck-dir rtl {\n\t\t& > :not(:last-child) {\n\t\t\tmargin-left: var(--ck-spacing-standard);\n\t\t}\n\t}\n\n\t@mixin ck-media-phone {\n\t\tpadding: 0;\n\t\twidth: calc(.8 * var(--ck-input-width));\n\n\t\t& .ck-labeled-field-view {\n\t\t\tmargin: var(--ck-spacing-large) var(--ck-spacing-large) 0;\n\n\t\t\t& .ck-input-text,\n\t\t\t& .ck-input-number {\n\t\t\t\tmin-width: 0;\n\t\t\t\twidth: 100%;\n\t\t\t}\n\n\t\t\t/* Let the long error messages wrap in the narrow form. */\n\t\t\t& .ck-labeled-field-view__error {\n\t\t\t\twhite-space: normal;\n\t\t\t}\n\t\t}\n\n\t\t/* Styles for two last buttons in the form (save&cancel, edit&unlink, etc.). */\n\t\t& > .ck-button:nth-last-child(2) {\n\t\t\t&::after {\n\t\t\t\tborder-right: 1px solid var(--ck-color-base-border);\n\t\t\t}\n\t\t}\n\n\t\t& > .ck-button:nth-last-child(1),\n\t\t& > .ck-button:nth-last-child(2) {\n\t\t\tpadding: var(--ck-spacing-standard);\n\t\t\tmargin-top: var(--ck-spacing-large);\n\t\t\tborder-radius: 0;\n\n\t\t\t&:not(:focus) {\n\t\t\t\tborder-top: 1px solid var(--ck-color-base-border);\n\t\t\t}\n\n\t\t\t@mixin ck-dir ltr {\n\t\t\t\tmargin-left: 0;\n\t\t\t}\n\n\t\t\t@mixin ck-dir rtl {\n\t\t\t\tmargin-left: 0;\n\n\t\t\t\t&:last-of-type {\n\t\t\t\t\tborder-right: 1px solid var(--ck-color-base-border);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}\n'],sourceRoot:""}]);const a=s},5540:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-search>.ck-labeled-field-view>.ck-labeled-field-view__input-wrapper>.ck-icon{position:absolute;top:50%;transform:translateY(-50%)}[dir=ltr] .ck.ck-search>.ck-labeled-field-view>.ck-labeled-field-view__input-wrapper>.ck-icon{left:var(--ck-spacing-medium)}[dir=rtl] .ck.ck-search>.ck-labeled-field-view>.ck-labeled-field-view__input-wrapper>.ck-icon{right:var(--ck-spacing-medium)}.ck.ck-search>.ck-labeled-field-view .ck-search__reset{position:absolute;top:50%;transform:translateY(-50%)}.ck.ck-search>.ck-search__results>.ck-search__info>span:first-child{display:block}.ck.ck-search>.ck-search__results>.ck-search__info:not(.ck-hidden)~*{display:none}:root{--ck-search-field-view-horizontal-spacing:calc(var(--ck-icon-size) + var(--ck-spacing-medium))}.ck.ck-search>.ck-labeled-field-view .ck-input{width:100%}.ck.ck-search>.ck-labeled-field-view.ck-search__query_with-icon{--ck-labeled-field-label-default-position-x:var(--ck-search-field-view-horizontal-spacing)}.ck.ck-search>.ck-labeled-field-view.ck-search__query_with-icon>.ck-labeled-field-view__input-wrapper>.ck-icon{opacity:.5;pointer-events:none}.ck.ck-search>.ck-labeled-field-view.ck-search__query_with-icon .ck-input{width:100%}[dir=ltr] .ck.ck-search>.ck-labeled-field-view.ck-search__query_with-icon .ck-input,[dir=rtl] .ck.ck-search>.ck-labeled-field-view.ck-search__query_with-icon .ck-input:not(.ck-input-text_empty){padding-left:var(--ck-search-field-view-horizontal-spacing)}.ck.ck-search>.ck-labeled-field-view.ck-search__query_with-reset{--ck-labeled-field-empty-unfocused-max-width:100% - 2 * var(--ck-search-field-view-horizontal-spacing)}.ck.ck-search>.ck-labeled-field-view.ck-search__query_with-reset.ck-labeled-field-view_empty{--ck-labeled-field-empty-unfocused-max-width:100% - var(--ck-search-field-view-horizontal-spacing) - var(--ck-spacing-medium)}.ck.ck-search>.ck-labeled-field-view.ck-search__query_with-reset .ck-search__reset{background:none;min-height:auto;min-width:auto;opacity:.5;padding:0}[dir=ltr] .ck.ck-search>.ck-labeled-field-view.ck-search__query_with-reset .ck-search__reset{right:var(--ck-spacing-medium)}[dir=rtl] .ck.ck-search>.ck-labeled-field-view.ck-search__query_with-reset .ck-search__reset{left:var(--ck-spacing-medium)}.ck.ck-search>.ck-labeled-field-view.ck-search__query_with-reset .ck-search__reset:hover{opacity:1}.ck.ck-search>.ck-labeled-field-view.ck-search__query_with-reset .ck-input{width:100%}[dir=ltr] .ck.ck-search>.ck-labeled-field-view.ck-search__query_with-reset .ck-input:not(.ck-input-text_empty),[dir=rtl] .ck.ck-search>.ck-labeled-field-view.ck-search__query_with-reset .ck-input{padding-right:var(--ck-search-field-view-horizontal-spacing)}.ck.ck-search>.ck-search__results{min-width:100%}.ck.ck-search>.ck-search__results>.ck-search__info{padding:var(--ck-spacing-medium) var(--ck-spacing-large);width:100%}.ck.ck-search>.ck-search__results>.ck-search__info *{white-space:normal}.ck.ck-search>.ck-search__results>.ck-search__info>span:first-child{font-weight:700}.ck.ck-search>.ck-search__results>.ck-search__info>span:last-child{margin-top:var(--ck-spacing-medium)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/search/search.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/search/search.css"],names:[],mappings:"AASE,oFACC,iBAAkB,CAClB,OAAQ,CACR,0BASD,CAZA,8FAME,6BAMF,CAZA,8FAUE,8BAEF,CAEA,uDACC,iBAAkB,CAClB,OAAQ,CACR,0BACD,CAKC,oEACC,aACD,CAGA,qEACC,YACD,CChCH,MACC,8FACD,CAIE,+CACC,UACD,CAEA,gEACC,0FAoBD,CAlBC,+GACC,UAAW,CACX,mBACD,CAEA,0EACC,UAWD,CAJE,kMACC,2DACD,CAKH,iEACC,sGAwCD,CAtCC,6FACC,6HACD,CAEA,mFAIC,eAAgB,CAFhB,eAAgB,CADhB,cAAe,CAIf,UAAW,CACX,SAaD,CAnBA,6FASE,8BAUF,CAnBA,6FAaE,6BAMF,CAHC,yFACC,SACD,CAGD,2EACC,UAWD,CAZA,oMAUE,4DAEF,CAIF,kCACC,cAkBD,CAhBC,mDAEC,wDAAyD,CADzD,UAcD,CAXC,qDACC,kBACD,CAEA,oEACC,eACD,CAEA,mEACC,mCACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n.ck.ck-search {\n\t& > .ck-labeled-field-view {\n\t\t& > .ck-labeled-field-view__input-wrapper > .ck-icon {\n\t\t\tposition: absolute;\n\t\t\ttop: 50%;\n\t\t\ttransform: translateY(-50%);\n\n\t\t\t@mixin ck-dir ltr {\n\t\t\t\tleft: var(--ck-spacing-medium);\n\t\t\t}\n\n\t\t\t@mixin ck-dir rtl {\n\t\t\t\tright: var(--ck-spacing-medium);\n\t\t\t}\n\t\t}\n\n\t\t& .ck-search__reset {\n\t\t\tposition: absolute;\n\t\t\ttop: 50%;\n\t\t\ttransform: translateY(-50%);\n\t\t}\n\t}\n\n\t& > .ck-search__results {\n\t\t& > .ck-search__info {\n\t\t\t& > span:first-child {\n\t\t\t\tdisplay: block;\n\t\t\t}\n\n\t\t\t/* Hide the filtered view when nothing was found */\n\t\t\t&:not(.ck-hidden) ~ * {\n\t\t\t\tdisplay: none;\n\t\t\t}\n\t\t}\n\t}\n}\n','/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n:root {\n\t--ck-search-field-view-horizontal-spacing: calc(var(--ck-icon-size) + var(--ck-spacing-medium));\n}\n\n.ck.ck-search {\n\t& > .ck-labeled-field-view {\n\t\t& .ck-input {\n\t\t\twidth: 100%;\n\t\t}\n\n\t\t&.ck-search__query_with-icon {\n\t\t\t--ck-labeled-field-label-default-position-x: var(--ck-search-field-view-horizontal-spacing);\n\n\t\t\t& > .ck-labeled-field-view__input-wrapper > .ck-icon {\n\t\t\t\topacity: .5;\n\t\t\t\tpointer-events: none;\n\t\t\t}\n\n\t\t\t& .ck-input {\n\t\t\t\twidth: 100%;\n\n\t\t\t\t@mixin ck-dir ltr {\n\t\t\t\t\tpadding-left: var(--ck-search-field-view-horizontal-spacing);\n\t\t\t\t}\n\n\t\t\t\t@mixin ck-dir rtl {\n\t\t\t\t\t&:not(.ck-input-text_empty) {\n\t\t\t\t\t\tpadding-left: var(--ck-search-field-view-horizontal-spacing);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t&.ck-search__query_with-reset {\n\t\t\t--ck-labeled-field-empty-unfocused-max-width: 100% - 2 * var(--ck-search-field-view-horizontal-spacing);\n\n\t\t\t&.ck-labeled-field-view_empty {\n\t\t\t\t--ck-labeled-field-empty-unfocused-max-width: 100% - var(--ck-search-field-view-horizontal-spacing) - var(--ck-spacing-medium);\n\t\t\t}\n\n\t\t\t& .ck-search__reset {\n\t\t\t\tmin-width: auto;\n\t\t\t\tmin-height: auto;\n\n\t\t\t\tbackground: none;\n\t\t\t\topacity: .5;\n\t\t\t\tpadding: 0;\n\n\t\t\t\t@mixin ck-dir ltr {\n\t\t\t\t\tright: var(--ck-spacing-medium);\n\t\t\t\t}\n\n\t\t\t\t@mixin ck-dir rtl {\n\t\t\t\t\tleft: var(--ck-spacing-medium);\n\t\t\t\t}\n\n\t\t\t\t&:hover {\n\t\t\t\t\topacity: 1;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t& .ck-input {\n\t\t\t\twidth: 100%;\n\n\t\t\t\t@mixin ck-dir ltr {\n\t\t\t\t\t&:not(.ck-input-text_empty) {\n\t\t\t\t\t\tpadding-right: var(--ck-search-field-view-horizontal-spacing);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t@mixin ck-dir rtl {\n\t\t\t\t\tpadding-right: var(--ck-search-field-view-horizontal-spacing);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t& > .ck-search__results {\n\t\tmin-width: 100%;\n\n\t\t& > .ck-search__info {\n\t\t\twidth: 100%;\n\t\t\tpadding: var(--ck-spacing-medium) var(--ck-spacing-large);\n\n\t\t\t& * {\n\t\t\t\twhite-space: normal;\n\t\t\t}\n\n\t\t\t& > span:first-child {\n\t\t\t\tfont-weight: bold;\n\t\t\t}\n\n\t\t\t& > span:last-child {\n\t\t\t\tmargin-top: var(--ck-spacing-medium);\n\t\t\t}\n\t\t}\n\t}\n}\n\n'],sourceRoot:""}]);const a=s},5706:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-spinner-container{display:block;position:relative}.ck.ck-spinner{left:0;margin:0 auto;position:absolute;right:0;top:50%;transform:translateY(-50%);z-index:1}:root{--ck-toolbar-spinner-size:18px}.ck.ck-spinner-container{animation:ck-spinner-rotate 1.5s linear infinite;height:var(--ck-toolbar-spinner-size);width:var(--ck-toolbar-spinner-size)}@media (prefers-reduced-motion:reduce){.ck.ck-spinner-container{animation-duration:3s}}.ck.ck-spinner{border:2px solid var(--ck-color-text);border-radius:50%;border-top:2px solid transparent;height:var(--ck-toolbar-spinner-size);width:var(--ck-toolbar-spinner-size)}@keyframes ck-spinner-rotate{to{transform:rotate(1turn)}}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/spinner/spinner.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/spinner/spinner.css"],names:[],mappings:"AASA,yBACC,aAAc,CACd,iBACD,CAEA,eAGC,MAAO,CAEP,aAAc,CAJd,iBAAkB,CAGlB,OAAQ,CAFR,OAAQ,CAIR,0BAA2B,CAC3B,SACD,CCjBA,MACC,8BACD,CAEA,yBAGC,gDAAiD,CADjD,qCAAsC,CADtC,oCAOD,CAHC,uCALD,yBAME,qBAEF,CADC,CAGD,eAKC,qCAA6B,CAF7B,iBAAkB,CAElB,gCAA6B,CAH7B,qCAAsC,CADtC,oCAKD,CAEA,6BACC,GACC,uBACD,CACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-toolbar-spinner-size: 18px;\n}\n\n.ck.ck-spinner-container {\n\tdisplay: block;\n\tposition: relative;\n}\n\n.ck.ck-spinner {\n\tposition: absolute;\n\ttop: 50%;\n\tleft: 0;\n\tright: 0;\n\tmargin: 0 auto;\n\ttransform: translateY(-50%);\n\tz-index: 1;\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-toolbar-spinner-size: 18px;\n}\n\n.ck.ck-spinner-container {\n\twidth: var(--ck-toolbar-spinner-size);\n\theight: var(--ck-toolbar-spinner-size);\n\tanimation: 1.5s infinite ck-spinner-rotate linear;\n\n\t@media (prefers-reduced-motion: reduce) {\n\t\tanimation-duration: 3s;\n\t}\n}\n\n.ck.ck-spinner {\n\twidth: var(--ck-toolbar-spinner-size);\n\theight: var(--ck-toolbar-spinner-size);\n\tborder-radius: 50%;\n\tborder: 2px solid var(--ck-color-text);\n\tborder-top-color: transparent;\n}\n\n@keyframes ck-spinner-rotate {\n\tto {\n\t\ttransform: rotate(360deg)\n\t}\n}\n"],sourceRoot:""}]);const a=s},8368:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck-textarea{overflow-x:hidden}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/textarea/textarea.css"],names:[],mappings:"AASA,aACC,iBACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/*\n * This fixes a problem in Firefox when the initial height of the complement does not match the number of rows.\n * This bug is especially visible when rows=1.\n */\n.ck-textarea {\n\toverflow-x: hidden\n}\n"],sourceRoot:""}]);const a=s},9939:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-block-toolbar-button{position:absolute;z-index:var(--ck-z-default)}:root{--ck-color-block-toolbar-button:var(--ck-color-text);--ck-block-toolbar-button-size:var(--ck-font-size-normal)}.ck.ck-block-toolbar-button{color:var(--ck-color-block-toolbar-button);font-size:var(--ck-block-toolbar-size)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/toolbar/blocktoolbar.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/toolbar/blocktoolbar.css"],names:[],mappings:"AAKA,4BACC,iBAAkB,CAClB,2BACD,CCHA,MACC,oDAAqD,CACrD,yDACD,CAEA,4BACC,0CAA2C,CAC3C,sCACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-block-toolbar-button {\n\tposition: absolute;\n\tz-index: var(--ck-z-default);\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-color-block-toolbar-button: var(--ck-color-text);\n\t--ck-block-toolbar-button-size: var(--ck-font-size-normal);\n}\n\n.ck.ck-block-toolbar-button {\n\tcolor: var(--ck-color-block-toolbar-button);\n\tfont-size: var(--ck-block-toolbar-size);\n}\n"],sourceRoot:""}]);const a=s},66:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-toolbar{align-items:center;display:flex;flex-flow:row nowrap;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.ck.ck-toolbar>.ck-toolbar__items{align-items:center;display:flex;flex-flow:row wrap;flex-grow:1}.ck.ck-toolbar .ck.ck-toolbar__separator{display:inline-block}.ck.ck-toolbar .ck.ck-toolbar__separator:first-child,.ck.ck-toolbar .ck.ck-toolbar__separator:last-child{display:none}.ck.ck-toolbar .ck-toolbar__line-break{flex-basis:100%}.ck.ck-toolbar.ck-toolbar_grouping>.ck-toolbar__items{flex-wrap:nowrap}.ck.ck-toolbar.ck-toolbar_vertical>.ck-toolbar__items{flex-direction:column}.ck.ck-toolbar.ck-toolbar_floating>.ck-toolbar__items{flex-wrap:nowrap}.ck.ck-toolbar>.ck.ck-toolbar__grouped-dropdown>.ck-dropdown__button .ck-dropdown__arrow{display:none}.ck.ck-toolbar{border-radius:0}.ck-rounded-corners .ck.ck-toolbar,.ck.ck-toolbar.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-toolbar{background:var(--ck-color-toolbar-background);border:1px solid var(--ck-color-toolbar-border);padding:0 var(--ck-spacing-small)}.ck.ck-toolbar .ck.ck-toolbar__separator{background:var(--ck-color-toolbar-border);height:var(--ck-icon-size);margin-bottom:var(--ck-spacing-small);margin-top:var(--ck-spacing-small);min-width:1px;width:1px}.ck.ck-toolbar .ck-toolbar__line-break{height:0}.ck.ck-toolbar>.ck-toolbar__items>:not(.ck-toolbar__line-break){margin-right:var(--ck-spacing-small)}.ck.ck-toolbar>.ck-toolbar__items:empty+.ck.ck-toolbar__separator{display:none}.ck.ck-toolbar>.ck-toolbar__items>:not(.ck-toolbar__line-break),.ck.ck-toolbar>.ck.ck-toolbar__grouped-dropdown{margin-bottom:var(--ck-spacing-small);margin-top:var(--ck-spacing-small)}.ck.ck-toolbar.ck-toolbar_vertical{padding:0}.ck.ck-toolbar.ck-toolbar_vertical>.ck-toolbar__items>.ck{border-radius:0;margin:0;width:100%}.ck.ck-toolbar.ck-toolbar_compact{padding:0}.ck.ck-toolbar.ck-toolbar_compact>.ck-toolbar__items>*{margin:0}.ck.ck-toolbar.ck-toolbar_compact>.ck-toolbar__items>:not(:first-child):not(:last-child){border-radius:0}.ck.ck-toolbar>.ck.ck-toolbar__grouped-dropdown>.ck.ck-button.ck-dropdown__button{padding-left:var(--ck-spacing-tiny)}.ck.ck-toolbar .ck-toolbar__nested-toolbar-dropdown>.ck-dropdown__panel{min-width:auto}.ck.ck-toolbar .ck-toolbar__nested-toolbar-dropdown>.ck-button>.ck-button__label{max-width:7em;width:auto}.ck.ck-toolbar:focus{outline:none}.ck-toolbar-container .ck.ck-toolbar{border:0}.ck.ck-toolbar[dir=rtl]>.ck-toolbar__items>.ck,[dir=rtl] .ck.ck-toolbar>.ck-toolbar__items>.ck{margin-right:0}.ck.ck-toolbar[dir=rtl]:not(.ck-toolbar_compact)>.ck-toolbar__items>.ck,[dir=rtl] .ck.ck-toolbar:not(.ck-toolbar_compact)>.ck-toolbar__items>.ck{margin-left:var(--ck-spacing-small)}.ck.ck-toolbar[dir=rtl]>.ck-toolbar__items>.ck:last-child,[dir=rtl] .ck.ck-toolbar>.ck-toolbar__items>.ck:last-child{margin-left:0}.ck.ck-toolbar.ck-toolbar_compact[dir=rtl]>.ck-toolbar__items>.ck:first-child,[dir=rtl] .ck.ck-toolbar.ck-toolbar_compact>.ck-toolbar__items>.ck:first-child{border-bottom-left-radius:0;border-top-left-radius:0}.ck.ck-toolbar.ck-toolbar_compact[dir=rtl]>.ck-toolbar__items>.ck:last-child,[dir=rtl] .ck.ck-toolbar.ck-toolbar_compact>.ck-toolbar__items>.ck:last-child{border-bottom-right-radius:0;border-top-right-radius:0}.ck.ck-toolbar.ck-toolbar_grouping[dir=rtl]>.ck-toolbar__items:not(:empty):not(:only-child),.ck.ck-toolbar[dir=rtl]>.ck.ck-toolbar__separator,[dir=rtl] .ck.ck-toolbar.ck-toolbar_grouping>.ck-toolbar__items:not(:empty):not(:only-child),[dir=rtl] .ck.ck-toolbar>.ck.ck-toolbar__separator{margin-left:var(--ck-spacing-small)}.ck.ck-toolbar[dir=ltr]>.ck-toolbar__items>.ck:last-child,[dir=ltr] .ck.ck-toolbar>.ck-toolbar__items>.ck:last-child{margin-right:0}.ck.ck-toolbar.ck-toolbar_compact[dir=ltr]>.ck-toolbar__items>.ck:first-child,[dir=ltr] .ck.ck-toolbar.ck-toolbar_compact>.ck-toolbar__items>.ck:first-child{border-bottom-right-radius:0;border-top-right-radius:0}.ck.ck-toolbar.ck-toolbar_compact[dir=ltr]>.ck-toolbar__items>.ck:last-child,[dir=ltr] .ck.ck-toolbar.ck-toolbar_compact>.ck-toolbar__items>.ck:last-child{border-bottom-left-radius:0;border-top-left-radius:0}.ck.ck-toolbar.ck-toolbar_grouping[dir=ltr]>.ck-toolbar__items:not(:empty):not(:only-child),.ck.ck-toolbar[dir=ltr]>.ck.ck-toolbar__separator,[dir=ltr] .ck.ck-toolbar.ck-toolbar_grouping>.ck-toolbar__items:not(:empty):not(:only-child),[dir=ltr] .ck.ck-toolbar>.ck.ck-toolbar__separator{margin-right:var(--ck-spacing-small)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/toolbar/toolbar.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_unselectable.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/toolbar/toolbar.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_rounded.css"],names:[],mappings:"AAOA,eAKC,kBAAmB,CAFnB,YAAa,CACb,oBAAqB,CCFrB,qBAAsB,CACtB,wBAAyB,CACzB,oBAAqB,CACrB,gBD6CD,CA3CC,kCAGC,kBAAmB,CAFnB,YAAa,CACb,kBAAmB,CAEnB,WAED,CAEA,yCACC,oBAWD,CAJC,yGAEC,YACD,CAGD,uCACC,eACD,CAEA,sDACC,gBACD,CAEA,sDACC,qBACD,CAEA,sDACC,gBACD,CAGC,yFACC,YACD,CE/CF,eCGC,eDwGD,CA3GA,qECOE,qCDoGF,CA3GA,eAGC,6CAA8C,CAE9C,+CAAgD,CADhD,iCAuGD,CApGC,yCAIC,yCAA0C,CAH1C,0BAA2B,CAU3B,qCAAsC,CADtC,kCAAmC,CAPnC,aAAc,CADd,SAUD,CAEA,uCACC,QACD,CAGC,gEAEC,oCACD,CAIA,kEACC,YACD,CAGD,gHAIC,qCAAsC,CADtC,kCAED,CAEA,mCAEC,SAaD,CAVC,0DAQC,eAAgB,CAHhB,QAAS,CAHT,UAOD,CAGD,kCAEC,SAWD,CATC,uDAEC,QAMD,CAHC,yFACC,eACD,CASD,kFACC,mCACD,CAMA,wEACC,cACD,CAEA,iFACC,aAAc,CACd,UACD,CAGD,qBACC,YACD,CAtGD,qCAyGE,QAEF,CAYC,+FACC,cACD,CAEA,iJAEC,mCACD,CAEA,qHACC,aACD,CAIC,6JAEC,2BAA4B,CAD5B,wBAED,CAGA,2JAEC,4BAA6B,CAD7B,yBAED,CASD,8RACC,mCACD,CAWA,qHACC,cACD,CAIC,6JAEC,4BAA6B,CAD7B,yBAED,CAGA,2JAEC,2BAA4B,CAD5B,wBAED,CASD,8RACC,oCACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../mixins/_unselectable.css";\n\n.ck.ck-toolbar {\n\t@mixin ck-unselectable;\n\n\tdisplay: flex;\n\tflex-flow: row nowrap;\n\talign-items: center;\n\n\t& > .ck-toolbar__items {\n\t\tdisplay: flex;\n\t\tflex-flow: row wrap;\n\t\talign-items: center;\n\t\tflex-grow: 1;\n\n\t}\n\n\t& .ck.ck-toolbar__separator {\n\t\tdisplay: inline-block;\n\n\t\t/*\n\t\t * A leading or trailing separator makes no sense (separates from nothing on one side).\n\t\t * For instance, it can happen when toolbar items (also separators) are getting grouped one by one and\n\t\t * moved to another toolbar in the dropdown.\n\t\t */\n\t\t&:first-child,\n\t\t&:last-child {\n\t\t\tdisplay: none;\n\t\t}\n\t}\n\n\t& .ck-toolbar__line-break {\n\t\tflex-basis: 100%;\n\t}\n\n\t&.ck-toolbar_grouping > .ck-toolbar__items {\n\t\tflex-wrap: nowrap;\n\t}\n\n\t&.ck-toolbar_vertical > .ck-toolbar__items {\n\t\tflex-direction: column;\n\t}\n\n\t&.ck-toolbar_floating > .ck-toolbar__items {\n\t\tflex-wrap: nowrap;\n\t}\n\n\t& > .ck.ck-toolbar__grouped-dropdown {\n\t\t& > .ck-dropdown__button .ck-dropdown__arrow {\n\t\t\tdisplay: none;\n\t\t}\n\t}\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Makes element unselectable.\n */\n@define-mixin ck-unselectable {\n\t-moz-user-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n\tuser-select: none\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_rounded.css";\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_dir.css";\n\n.ck.ck-toolbar {\n\t@mixin ck-rounded-corners;\n\n\tbackground: var(--ck-color-toolbar-background);\n\tpadding: 0 var(--ck-spacing-small);\n\tborder: 1px solid var(--ck-color-toolbar-border);\n\n\t& .ck.ck-toolbar__separator {\n\t\theight: var(--ck-icon-size);\n\t\twidth: 1px;\n\t\tmin-width: 1px;\n\t\tbackground: var(--ck-color-toolbar-border);\n\n\t\t/*\n\t\t * These margins make the separators look better in balloon toolbars (when aligned with the "tip").\n\t\t * See https://github.com/ckeditor/ckeditor5/issues/7493.\n\t\t */\n\t\tmargin-top: var(--ck-spacing-small);\n\t\tmargin-bottom: var(--ck-spacing-small);\n\t}\n\n\t& .ck-toolbar__line-break {\n\t\theight: 0;\n\t}\n\n\t& > .ck-toolbar__items {\n\t\t& > *:not(.ck-toolbar__line-break) {\n\t\t\t/* (#11) Separate toolbar items. */\n\t\t\tmargin-right: var(--ck-spacing-small);\n\t\t}\n\n\t\t/* Don\'t display a separator after an empty items container, for instance,\n\t\twhen all items were grouped */\n\t\t&:empty + .ck.ck-toolbar__separator {\n\t\t\tdisplay: none;\n\t\t}\n\t}\n\n\t& > .ck-toolbar__items > *:not(.ck-toolbar__line-break),\n\t& > .ck.ck-toolbar__grouped-dropdown {\n\t\t/* Make sure items wrapped to the next line have v-spacing */\n\t\tmargin-top: var(--ck-spacing-small);\n\t\tmargin-bottom: var(--ck-spacing-small);\n\t}\n\n\t&.ck-toolbar_vertical {\n\t\t/* Items in a vertical toolbar span the entire width. */\n\t\tpadding: 0;\n\n\t\t/* Specificity matters here. See https://github.com/ckeditor/ckeditor5-theme-lark/issues/168. */\n\t\t& > .ck-toolbar__items > .ck {\n\t\t\t/* Items in a vertical toolbar should span the horizontal space. */\n\t\t\twidth: 100%;\n\n\t\t\t/* Items in a vertical toolbar should have no margin. */\n\t\t\tmargin: 0;\n\n\t\t\t/* Items in a vertical toolbar span the entire width so rounded corners are pointless. */\n\t\t\tborder-radius: 0;\n\t\t}\n\t}\n\n\t&.ck-toolbar_compact {\n\t\t/* No spacing around items. */\n\t\tpadding: 0;\n\n\t\t& > .ck-toolbar__items > * {\n\t\t\t/* Compact toolbar items have no spacing between them. */\n\t\t\tmargin: 0;\n\n\t\t\t/* "Middle" children should have no rounded corners. */\n\t\t\t&:not(:first-child):not(:last-child) {\n\t\t\t\tborder-radius: 0;\n\t\t\t}\n\t\t}\n\t}\n\n\t& > .ck.ck-toolbar__grouped-dropdown {\n\t\t/*\n\t\t * Dropdown button has asymmetric padding to fit the arrow.\n\t\t * This button has no arrow so let\'s revert that padding back to normal.\n\t\t */\n\t\t& > .ck.ck-button.ck-dropdown__button {\n\t\t\tpadding-left: var(--ck-spacing-tiny);\n\t\t}\n\t}\n\n\t/* A drop-down containing the nested toolbar with configured items. */\n\t& .ck-toolbar__nested-toolbar-dropdown {\n\t\t/* Prevent empty space in the panel when the dropdown label is visible and long but the toolbar has few items. */\n\t\t& > .ck-dropdown__panel {\n\t\t\tmin-width: auto;\n\t\t}\n\n\t\t& > .ck-button > .ck-button__label {\n\t\t\tmax-width: 7em;\n\t\t\twidth: auto;\n\t\t}\n\t}\n\n\t&:focus {\n\t\toutline: none;\n\t}\n\n\t@nest .ck-toolbar-container & {\n\t\tborder: 0;\n\t}\n}\n\n/* stylelint-disable */\n\n/*\n * Styles for RTL toolbars.\n *\n * Note: In some cases (e.g. a decoupled editor), the toolbar has its own "dir"\n * because its parent is not controlled by the editor framework.\n */\n[dir="rtl"] .ck.ck-toolbar,\n.ck.ck-toolbar[dir="rtl"] {\n\t& > .ck-toolbar__items > .ck {\n\t\tmargin-right: 0;\n\t}\n\n\t&:not(.ck-toolbar_compact) > .ck-toolbar__items > .ck {\n\t\t/* (#11) Separate toolbar items. */\n\t\tmargin-left: var(--ck-spacing-small);\n\t}\n\n\t& > .ck-toolbar__items > .ck:last-child {\n\t\tmargin-left: 0;\n\t}\n\n\t&.ck-toolbar_compact > .ck-toolbar__items > .ck {\n\t\t/* No rounded corners on the right side of the first child. */\n\t\t&:first-child {\n\t\t\tborder-top-left-radius: 0;\n\t\t\tborder-bottom-left-radius: 0;\n\t\t}\n\n\t\t/* No rounded corners on the left side of the last child. */\n\t\t&:last-child {\n\t\t\tborder-top-right-radius: 0;\n\t\t\tborder-bottom-right-radius: 0;\n\t\t}\n\t}\n\n\t/* Separate the the separator form the grouping dropdown when some items are grouped. */\n\t& > .ck.ck-toolbar__separator {\n\t\tmargin-left: var(--ck-spacing-small);\n\t}\n\n\t/* Some spacing between the items and the separator before the grouped items dropdown. */\n\t&.ck-toolbar_grouping > .ck-toolbar__items:not(:empty):not(:only-child) {\n\t\tmargin-left: var(--ck-spacing-small);\n\t}\n}\n\n/*\n * Styles for LTR toolbars.\n *\n * Note: In some cases (e.g. a decoupled editor), the toolbar has its own "dir"\n * because its parent is not controlled by the editor framework.\n */\n[dir="ltr"] .ck.ck-toolbar,\n.ck.ck-toolbar[dir="ltr"] {\n\t& > .ck-toolbar__items > .ck:last-child {\n\t\tmargin-right: 0;\n\t}\n\n\t&.ck-toolbar_compact > .ck-toolbar__items > .ck {\n\t\t/* No rounded corners on the right side of the first child. */\n\t\t&:first-child {\n\t\t\tborder-top-right-radius: 0;\n\t\t\tborder-bottom-right-radius: 0;\n\t\t}\n\n\t\t/* No rounded corners on the left side of the last child. */\n\t\t&:last-child {\n\t\t\tborder-top-left-radius: 0;\n\t\t\tborder-bottom-left-radius: 0;\n\t\t}\n\t}\n\n\t/* Separate the the separator form the grouping dropdown when some items are grouped. */\n\t& > .ck.ck-toolbar__separator {\n\t\tmargin-right: var(--ck-spacing-small);\n\t}\n\n\t/* Some spacing between the items and the separator before the grouped items dropdown. */\n\t&.ck-toolbar_grouping > .ck-toolbar__items:not(:empty):not(:only-child) {\n\t\tmargin-right: var(--ck-spacing-small);\n\t}\n}\n\n/* stylelint-enable */\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Implements rounded corner interface for .ck-rounded-corners class.\n *\n * @see $ck-border-radius\n */\n@define-mixin ck-rounded-corners {\n\tborder-radius: 0;\n\n\t@nest .ck-rounded-corners &,\n\t&.ck-rounded-corners {\n\t\tborder-radius: var(--ck-border-radius);\n\t\t@mixin-content;\n\t}\n}\n"],sourceRoot:""}]);const a=s},4650:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck.ck-balloon-panel.ck-tooltip{-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none;z-index:calc(var(--ck-z-dialog) + 100);--ck-balloon-border-width:0px;--ck-balloon-arrow-offset:0px;--ck-balloon-arrow-half-width:4px;--ck-balloon-arrow-height:4px;--ck-tooltip-text-padding:4px;--ck-color-panel-background:var(--ck-color-tooltip-background);padding:0 var(--ck-spacing-medium)}.ck.ck-balloon-panel.ck-tooltip .ck-tooltip__text{color:var(--ck-color-tooltip-text);font-size:.9em;line-height:1.5}.ck.ck-balloon-panel.ck-tooltip.ck-tooltip_multi-line .ck-tooltip__text{display:inline-block;max-width:200px;padding:var(--ck-tooltip-text-padding) 0;white-space:break-spaces}.ck.ck-balloon-panel.ck-tooltip{box-shadow:none}.ck.ck-balloon-panel.ck-tooltip:before{display:none}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/components/tooltip/tooltip.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_unselectable.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/components/tooltip/tooltip.css"],names:[],mappings:"AAOA,gCCEC,qBAAsB,CACtB,wBAAyB,CACzB,oBAAqB,CACrB,gBAAgB,CDFhB,sCAAyC,CEFzC,6BAA8B,CAC9B,6BAA8B,CAC9B,iCAAkC,CAClC,6BAA8B,CAC9B,6BAA8B,CAC9B,8DAA+D,CAE/D,kCFJD,CEMC,kDAGC,kCAAmC,CAFnC,cAAe,CACf,eAED,CAEA,wEAEC,oBAAqB,CAErB,eAAgB,CADhB,wCAAyC,CAFzC,wBAID,CArBD,gCAwBC,eAMD,CAHC,uCACC,YACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../mixins/_unselectable.css";\n\n.ck.ck-balloon-panel.ck-tooltip {\n\t@mixin ck-unselectable;\n\n\tz-index: calc( var(--ck-z-dialog) + 100 );\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Makes element unselectable.\n */\n@define-mixin ck-unselectable {\n\t-moz-user-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n\tuser-select: none\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../../../mixins/_rounded.css";\n\n.ck.ck-balloon-panel.ck-tooltip {\n\t--ck-balloon-border-width: 0px;\n\t--ck-balloon-arrow-offset: 0px;\n\t--ck-balloon-arrow-half-width: 4px;\n\t--ck-balloon-arrow-height: 4px;\n\t--ck-tooltip-text-padding: 4px;\n\t--ck-color-panel-background: var(--ck-color-tooltip-background);\n\n\tpadding: 0 var(--ck-spacing-medium);\n\n\t& .ck-tooltip__text {\n\t\tfont-size: .9em;\n\t\tline-height: 1.5;\n\t\tcolor: var(--ck-color-tooltip-text);\n\t}\n\n\t&.ck-tooltip_multi-line .ck-tooltip__text {\n\t\twhite-space: break-spaces;\n\t\tdisplay: inline-block;\n\t\tpadding: var(--ck-tooltip-text-padding) 0;\n\t\tmax-width: 200px;\n\t}\n\n\t/* Reset balloon panel styles */\n\tbox-shadow: none;\n\n\t/* Hide the default shadow of the .ck-balloon-panel tip */\n\t&::before {\n\t\tdisplay: none;\n\t}\n}\n'],sourceRoot:""}]);const a=s},601:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck-hidden{display:none!important}:root{--ck-z-default:1;--ck-z-panel:calc(var(--ck-z-default) + 999);--ck-z-dialog:9999}.ck-transitions-disabled,.ck-transitions-disabled *{transition:none!important}:root{--ck-powered-by-line-height:10px;--ck-powered-by-padding-vertical:2px;--ck-powered-by-padding-horizontal:4px;--ck-powered-by-text-color:#4f4f4f;--ck-powered-by-border-radius:var(--ck-border-radius);--ck-powered-by-background:#fff;--ck-powered-by-border-color:var(--ck-color-focus-border)}.ck.ck-balloon-panel.ck-powered-by-balloon{--ck-border-radius:var(--ck-powered-by-border-radius);background:var(--ck-powered-by-background);box-shadow:none;min-height:unset;z-index:calc(var(--ck-z-panel) - 1)}.ck.ck-balloon-panel.ck-powered-by-balloon .ck.ck-powered-by{line-height:var(--ck-powered-by-line-height)}.ck.ck-balloon-panel.ck-powered-by-balloon .ck.ck-powered-by a{align-items:center;cursor:pointer;display:flex;filter:grayscale(80%);line-height:var(--ck-powered-by-line-height);opacity:.66;padding:var(--ck-powered-by-padding-vertical) var(--ck-powered-by-padding-horizontal)}.ck.ck-balloon-panel.ck-powered-by-balloon .ck.ck-powered-by .ck-powered-by__label{color:var(--ck-powered-by-text-color);cursor:pointer;font-size:7.5px;font-weight:700;letter-spacing:-.2px;line-height:normal;margin-right:4px;padding-left:2px;text-transform:uppercase}.ck.ck-balloon-panel.ck-powered-by-balloon .ck.ck-powered-by .ck-icon{cursor:pointer;display:block}.ck.ck-balloon-panel.ck-powered-by-balloon .ck.ck-powered-by:hover a{filter:grayscale(0);opacity:1}.ck.ck-balloon-panel.ck-powered-by-balloon[class*=position_inside]{border-color:transparent}.ck.ck-balloon-panel.ck-powered-by-balloon[class*=position_border]{border:var(--ck-focus-ring);border-color:var(--ck-powered-by-border-color)}:root{--ck-color-base-foreground:#fafafa;--ck-color-base-background:#fff;--ck-color-base-border:#ccced1;--ck-color-base-action:#53a336;--ck-color-base-focus:#6cb5f9;--ck-color-base-text:#333;--ck-color-base-active:#2977ff;--ck-color-base-active-focus:#0d65ff;--ck-color-base-error:#db3700;--ck-color-focus-border-coordinates:218,81.8%,56.9%;--ck-color-focus-border:hsl(var(--ck-color-focus-border-coordinates));--ck-color-focus-outer-shadow:#cae1fc;--ck-color-focus-disabled-shadow:rgba(119,186,248,.3);--ck-color-focus-error-shadow:rgba(255,64,31,.3);--ck-color-text:var(--ck-color-base-text);--ck-color-shadow-drop:rgba(0,0,0,.15);--ck-color-shadow-drop-active:rgba(0,0,0,.2);--ck-color-shadow-inner:rgba(0,0,0,.1);--ck-color-button-default-background:transparent;--ck-color-button-default-hover-background:#f0f0f0;--ck-color-button-default-active-background:#f0f0f0;--ck-color-button-default-disabled-background:transparent;--ck-color-button-on-background:#f0f7ff;--ck-color-button-on-hover-background:#dbecff;--ck-color-button-on-active-background:#dbecff;--ck-color-button-on-disabled-background:#f0f2f4;--ck-color-button-on-color:#2977ff;--ck-color-button-action-background:var(--ck-color-base-action);--ck-color-button-action-hover-background:#4d9d30;--ck-color-button-action-active-background:#4d9d30;--ck-color-button-action-disabled-background:#7ec365;--ck-color-button-action-text:var(--ck-color-base-background);--ck-color-button-save:#008a00;--ck-color-button-cancel:#db3700;--ck-color-switch-button-off-background:#939393;--ck-color-switch-button-off-hover-background:#7d7d7d;--ck-color-switch-button-on-background:var(--ck-color-button-action-background);--ck-color-switch-button-on-hover-background:#4d9d30;--ck-color-switch-button-inner-background:var(--ck-color-base-background);--ck-color-switch-button-inner-shadow:rgba(0,0,0,.1);--ck-color-dropdown-panel-background:var(--ck-color-base-background);--ck-color-dropdown-panel-border:var(--ck-color-base-border);--ck-color-dialog-background:var(--ck-custom-background);--ck-color-dialog-form-header-border:var(--ck-custom-border);--ck-color-input-background:var(--ck-color-base-background);--ck-color-input-border:var(--ck-color-base-border);--ck-color-input-error-border:var(--ck-color-base-error);--ck-color-input-text:var(--ck-color-base-text);--ck-color-input-disabled-background:#f2f2f2;--ck-color-input-disabled-border:var(--ck-color-base-border);--ck-color-input-disabled-text:#757575;--ck-color-list-background:var(--ck-color-base-background);--ck-color-list-button-hover-background:var(--ck-color-button-default-hover-background);--ck-color-list-button-on-background:var(--ck-color-button-on-color);--ck-color-list-button-on-background-focus:var(--ck-color-button-on-color);--ck-color-list-button-on-text:var(--ck-color-base-background);--ck-color-panel-background:var(--ck-color-base-background);--ck-color-panel-border:var(--ck-color-base-border);--ck-color-toolbar-background:var(--ck-color-base-background);--ck-color-toolbar-border:var(--ck-color-base-border);--ck-color-tooltip-background:var(--ck-color-base-text);--ck-color-tooltip-text:var(--ck-color-base-background);--ck-color-engine-placeholder-text:#707070;--ck-color-upload-bar-background:#6cb5f9;--ck-color-link-default:#0000f0;--ck-color-link-selected-background:rgba(31,176,255,.1);--ck-color-link-fake-selection:rgba(31,176,255,.3);--ck-color-highlight-background:#ff0;--ck-color-light-red:#fcc;--ck-disabled-opacity:.5;--ck-focus-outer-shadow-geometry:0 0 0 3px;--ck-focus-outer-shadow:var(--ck-focus-outer-shadow-geometry) var(--ck-color-focus-outer-shadow);--ck-focus-disabled-outer-shadow:var(--ck-focus-outer-shadow-geometry) var(--ck-color-focus-disabled-shadow);--ck-focus-error-outer-shadow:var(--ck-focus-outer-shadow-geometry) var(--ck-color-focus-error-shadow);--ck-focus-ring:1px solid var(--ck-color-focus-border);--ck-font-size-base:13px;--ck-line-height-base:1.84615;--ck-font-face:Helvetica,Arial,Tahoma,Verdana,Sans-Serif;--ck-font-size-tiny:0.7em;--ck-font-size-small:0.75em;--ck-font-size-normal:1em;--ck-font-size-big:1.4em;--ck-font-size-large:1.8em;--ck-ui-component-min-height:2.3em}.ck-reset_all :not(.ck-reset_all-excluded *),.ck.ck-reset,.ck.ck-reset_all{background:transparent;border:0;box-sizing:border-box;height:auto;margin:0;padding:0;position:static;text-decoration:none;transition:none;vertical-align:middle;width:auto;word-wrap:break-word}.ck-reset_all :not(.ck-reset_all-excluded *),.ck.ck-reset_all{border-collapse:collapse;color:var(--ck-color-text);cursor:auto;float:none;font:normal normal normal var(--ck-font-size-base)/var(--ck-line-height-base) var(--ck-font-face);text-align:left;white-space:nowrap}.ck-reset_all .ck-rtl :not(.ck-reset_all-excluded *){text-align:right}.ck-reset_all iframe:not(.ck-reset_all-excluded *){vertical-align:inherit}.ck-reset_all textarea:not(.ck-reset_all-excluded *){white-space:pre-wrap}.ck-reset_all input[type=password]:not(.ck-reset_all-excluded *),.ck-reset_all input[type=text]:not(.ck-reset_all-excluded *),.ck-reset_all textarea:not(.ck-reset_all-excluded *){cursor:text}.ck-reset_all input[type=password][disabled]:not(.ck-reset_all-excluded *),.ck-reset_all input[type=text][disabled]:not(.ck-reset_all-excluded *),.ck-reset_all textarea[disabled]:not(.ck-reset_all-excluded *){cursor:default}.ck-reset_all fieldset:not(.ck-reset_all-excluded *){border:2px groove #dfdee3;padding:10px}.ck-reset_all button:not(.ck-reset_all-excluded *)::-moz-focus-inner{border:0;padding:0}.ck[dir=rtl],.ck[dir=rtl] .ck{text-align:right}:root{--ck-border-radius:2px;--ck-inner-shadow:2px 2px 3px var(--ck-color-shadow-inner) inset;--ck-drop-shadow:0 1px 2px 1px var(--ck-color-shadow-drop);--ck-drop-shadow-active:0 3px 6px 1px var(--ck-color-shadow-drop-active);--ck-spacing-unit:0.6em;--ck-spacing-large:calc(var(--ck-spacing-unit)*1.5);--ck-spacing-standard:var(--ck-spacing-unit);--ck-spacing-medium:calc(var(--ck-spacing-unit)*0.8);--ck-spacing-small:calc(var(--ck-spacing-unit)*0.5);--ck-spacing-tiny:calc(var(--ck-spacing-unit)*0.3);--ck-spacing-extra-tiny:calc(var(--ck-spacing-unit)*0.16)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/globals/_hidden.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/globals/_zindex.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/globals/_transition.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/globals/_poweredby.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/globals/_colors.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/globals/_disabled.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/globals/_focus.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/globals/_fonts.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/globals/_reset.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/globals/_rounded.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/globals/_shadow.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-ui/globals/_spacing.css"],names:[],mappings:"AAQA,WAGC,sBACD,CCPA,MACC,gBAAiB,CACjB,4CAA+C,CAC/C,kBACD,CCDA,oDAEC,yBACD,CCNA,MACC,gCAAiC,CACjC,oCAAqC,CACrC,sCAAuC,CACvC,kCAA2C,CAC3C,qDAAsD,CACtD,+BAA4C,CAC5C,yDACD,CAEA,2CACC,qDAAsD,CAGtD,0CAA2C,CAD3C,eAAgB,CAEhB,gBAAiB,CACjB,mCAiDD,CA/CC,6DACC,4CAoCD,CAlCC,+DAGC,kBAAmB,CAFnB,cAAe,CACf,YAAa,CAGb,qBAAsB,CACtB,4CAA6C,CAF7C,WAAY,CAGZ,qFACD,CAEA,mFASC,qCAAsC,CAFtC,cAAe,CANf,eAAgB,CAIhB,eAAiB,CAHjB,oBAAqB,CAMrB,kBAAmB,CAFnB,gBAAiB,CAHjB,gBAAiB,CACjB,wBAOD,CAEA,sEAEC,cAAe,CADf,aAED,CAGC,qEACC,mBAAqB,CACrB,SACD,CAIF,mEACC,wBACD,CAEA,mEACC,2BAA4B,CAC5B,8CACD,CChED,MACC,kCAAmD,CACnD,+BAAoD,CACpD,8BAAkD,CAClD,8BAAuD,CACvD,6BAAmD,CACnD,yBAA+C,CAC/C,8BAAsD,CACtD,oCAA4D,CAC5D,6BAAkD,CAIlD,mDAA4D,CAC5D,qEAA+E,CAC/E,qCAA4D,CAC5D,qDAA8D,CAC9D,gDAAyD,CACzD,yCAAqD,CACrD,sCAAsD,CACtD,4CAA0D,CAC1D,sCAAsD,CAItD,gDAAuD,CACvD,kDAAiE,CACjE,mDAAkE,CAClE,yDAA8D,CAE9D,uCAA6D,CAC7D,6CAAoE,CACpE,8CAAoE,CACpE,gDAAiE,CACjE,kCAAyD,CAGzD,+DAAsE,CACtE,iDAAsE,CACtE,kDAAsE,CACtE,oDAAoE,CACpE,6DAAsE,CAEtE,8BAAoD,CACpD,gCAAqD,CAErD,+CAA8D,CAC9D,qDAAiE,CACjE,+EAAqF,CACrF,oDAAuE,CACvE,yEAA8E,CAC9E,oDAAgE,CAIhE,oEAA2E,CAC3E,4DAAoE,CAIpE,wDAAiE,CACjE,4DAAmE,CAInE,2DAAoE,CACpE,mDAA6D,CAC7D,wDAAgE,CAChE,+CAA0D,CAC1D,4CAA2D,CAC3D,4DAAoE,CACpE,sCAAsD,CAItD,0DAAmE,CACnE,uFAA6F,CAC7F,oEAA2E,CAC3E,0EAA+E,CAC/E,8DAAsE,CAItE,2DAAoE,CACpE,mDAA6D,CAI7D,6DAAsE,CACtE,qDAA+D,CAI/D,uDAAgE,CAChE,uDAAiE,CAIjE,0CAAyD,CAIzD,wCAA2D,CAI3D,+BAAoD,CACpD,uDAAmE,CACnE,kDAAgE,CAIhE,oCAAyD,CAIzD,yBAAgD,CChHhD,wBAAyB,CCAzB,0CAA2C,CAK3C,gGAAiG,CAKjG,4GAA6G,CAK7G,sGAAuG,CAKvG,sDAAuD,CCvBvD,wBAAyB,CACzB,6BAA8B,CAC9B,wDAA6D,CAE7D,yBAA0B,CAC1B,2BAA4B,CAC5B,yBAA0B,CAC1B,wBAAyB,CACzB,0BAA2B,CCJ3B,kCJgHD,CI1GA,2EAYC,sBAAuB,CADvB,QAAS,CART,qBAAsB,CAEtB,WAAY,CAIZ,QAAS,CACT,SAAU,CAJV,eAAgB,CAOhB,oBAAqB,CAErB,eAAgB,CADhB,qBAAsB,CAVtB,UAAW,CAcX,oBACD,CAKA,8DAGC,wBAAyB,CAEzB,0BAA2B,CAG3B,WAAY,CACZ,UAAW,CALX,iGAAkG,CAElG,eAAgB,CAChB,kBAGD,CAGC,qDACC,gBACD,CAEA,mDAEC,sBACD,CAEA,qDACC,oBACD,CAEA,mLAGC,WACD,CAEA,iNAGC,cACD,CAEA,qDAEC,yBAAoC,CADpC,YAED,CAEA,qEAGC,QAAQ,CADR,SAED,CAMD,8BAEC,gBACD,CCxFA,MACC,sBAAuB,CCAvB,gEAAiE,CAKjE,0DAA2D,CAK3D,wEAAyE,CCbzE,uBAA8B,CAC9B,mDAA2D,CAC3D,4CAAkD,CAClD,oDAA4D,CAC5D,mDAA2D,CAC3D,kDAA2D,CAC3D,yDFFD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A class which hides an element in DOM.\n */\n.ck-hidden {\n\t/* Override selector specificity. Otherwise, all elements with some display\n\tstyle defined will override this one, which is not a desired result. */\n\tdisplay: none !important;\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-z-default: 1;\n\t--ck-z-panel: calc( var(--ck-z-default) + 999 );\n\t--ck-z-dialog: 9999;\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A class that disables all transitions of the element and its children.\n */\n.ck-transitions-disabled,\n.ck-transitions-disabled * {\n\ttransition: none !important;\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-powered-by-line-height: 10px;\n\t--ck-powered-by-padding-vertical: 2px;\n\t--ck-powered-by-padding-horizontal: 4px;\n\t--ck-powered-by-text-color: hsl(0, 0%, 31%);\n\t--ck-powered-by-border-radius: var(--ck-border-radius);\n\t--ck-powered-by-background: hsl(0, 0%, 100%);\n\t--ck-powered-by-border-color: var(--ck-color-focus-border);\n}\n\n.ck.ck-balloon-panel.ck-powered-by-balloon {\n\t--ck-border-radius: var(--ck-powered-by-border-radius);\n\n\tbox-shadow: none;\n\tbackground: var(--ck-powered-by-background);\n\tmin-height: unset;\n\tz-index: calc( var(--ck-z-panel) - 1 );\n\n\t& .ck.ck-powered-by {\n\t\tline-height: var(--ck-powered-by-line-height);\n\n\t\t& a {\n\t\t\tcursor: pointer;\n\t\t\tdisplay: flex;\n\t\t\talign-items: center;\n\t\t\topacity: .66;\n\t\t\tfilter: grayscale(80%);\n\t\t\tline-height: var(--ck-powered-by-line-height);\n\t\t\tpadding: var(--ck-powered-by-padding-vertical) var(--ck-powered-by-padding-horizontal);\n\t\t}\n\n\t\t& .ck-powered-by__label {\n\t\t\tfont-size: 7.5px;\n\t\t\tletter-spacing: -.2px;\n\t\t\tpadding-left: 2px;\n\t\t\ttext-transform: uppercase;\n\t\t\tfont-weight: bold;\n\t\t\tmargin-right: 4px;\n\t\t\tcursor: pointer;\n\t\t\tline-height: normal;\n\t\t\tcolor: var(--ck-powered-by-text-color);\n\n\t\t}\n\n\t\t& .ck-icon {\n\t\t\tdisplay: block;\n\t\t\tcursor: pointer;\n\t\t}\n\n\t\t&:hover {\n\t\t\t& a {\n\t\t\t\tfilter: grayscale(0%);\n\t\t\t\topacity: 1;\n\t\t\t}\n\t\t}\n\t}\n\n\t&[class*="position_inside"] {\n\t\tborder-color: transparent;\n\t}\n\n\t&[class*="position_border"] {\n\t\tborder: var(--ck-focus-ring);\n\t\tborder-color: var(--ck-powered-by-border-color);\n\t}\n}\n\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-color-base-foreground: \t\t\t\t\t\t\t\thsl(0, 0%, 98%);\n\t--ck-color-base-background: \t\t\t\t\t\t\t\thsl(0, 0%, 100%);\n\t--ck-color-base-border: \t\t\t\t\t\t\t\t\thsl(220, 6%, 81%);\n\t--ck-color-base-action: \t\t\t\t\t\t\t\t\thsl(104, 50.2%, 42.5%);\n\t--ck-color-base-focus: \t\t\t\t\t\t\t\t\t\thsl(209, 92%, 70%);\n\t--ck-color-base-text: \t\t\t\t\t\t\t\t\t\thsl(0, 0%, 20%);\n\t--ck-color-base-active: \t\t\t\t\t\t\t\t\thsl(218.1, 100%, 58%);\n\t--ck-color-base-active-focus:\t\t\t\t\t\t\t\thsl(218.2, 100%, 52.5%);\n\t--ck-color-base-error:\t\t\t\t\t\t\t\t\t\thsl(15, 100%, 43%);\n\n\t/* -- Generic colors ------------------------------------------------------------------------ */\n\n\t--ck-color-focus-border-coordinates: \t\t\t\t\t\t218, 81.8%, 56.9%;\n\t--ck-color-focus-border: \t\t\t\t\t\t\t\t\thsl(var(--ck-color-focus-border-coordinates));\n\t--ck-color-focus-outer-shadow:\t\t\t\t\t\t\t\thsl(212.4, 89.3%, 89%);\n\t--ck-color-focus-disabled-shadow:\t\t\t\t\t\t\thsla(209, 90%, 72%,.3);\n\t--ck-color-focus-error-shadow:\t\t\t\t\t\t\t\thsla(9,100%,56%,.3);\n\t--ck-color-text: \t\t\t\t\t\t\t\t\t\t\tvar(--ck-color-base-text);\n\t--ck-color-shadow-drop: \t\t\t\t\t\t\t\t\thsla(0, 0%, 0%, 0.15);\n\t--ck-color-shadow-drop-active:\t\t\t\t\t\t\t\thsla(0, 0%, 0%, 0.2);\n\t--ck-color-shadow-inner: \t\t\t\t\t\t\t\t\thsla(0, 0%, 0%, 0.1);\n\n\t/* -- Buttons ------------------------------------------------------------------------------- */\n\n\t--ck-color-button-default-background: \t\t\t\t\t\ttransparent;\n\t--ck-color-button-default-hover-background: \t\t\t\thsl(0, 0%, 94.1%);\n\t--ck-color-button-default-active-background: \t\t\t\thsl(0, 0%, 94.1%);\n\t--ck-color-button-default-disabled-background: \t\t\t\ttransparent;\n\n\t--ck-color-button-on-background: \t\t\t\t\t\t\thsl(212, 100%, 97.1%);\n\t--ck-color-button-on-hover-background: \t\t\t\t\t\thsl(211.7, 100%, 92.9%);\n\t--ck-color-button-on-active-background: \t\t\t\t\thsl(211.7, 100%, 92.9%);\n\t--ck-color-button-on-disabled-background: \t\t\t\t\thsl(211, 15%, 95%);\n\t--ck-color-button-on-color:\t\t\t\t\t\t\t\t\thsl(218.1, 100%, 58%);\n\n\n\t--ck-color-button-action-background: \t\t\t\t\t\tvar(--ck-color-base-action);\n\t--ck-color-button-action-hover-background: \t\t\t\t\thsl(104, 53.2%, 40.2%);\n\t--ck-color-button-action-active-background: \t\t\t\thsl(104, 53.2%, 40.2%);\n\t--ck-color-button-action-disabled-background: \t\t\t\thsl(104, 44%, 58%);\n\t--ck-color-button-action-text: \t\t\t\t\t\t\t\tvar(--ck-color-base-background);\n\n\t--ck-color-button-save: \t\t\t\t\t\t\t\t\thsl(120, 100%, 27%);\n\t--ck-color-button-cancel: \t\t\t\t\t\t\t\t\thsl(15, 100%, 43%);\n\n\t--ck-color-switch-button-off-background:\t\t\t\t\thsl(0, 0%, 57.6%);\n\t--ck-color-switch-button-off-hover-background:\t\t\t\thsl(0, 0%, 49%);\n\t--ck-color-switch-button-on-background:\t\t\t\t\t\tvar(--ck-color-button-action-background);\n\t--ck-color-switch-button-on-hover-background:\t\t\t\thsl(104, 53.2%, 40.2%);\n\t--ck-color-switch-button-inner-background:\t\t\t\t\tvar(--ck-color-base-background);\n\t--ck-color-switch-button-inner-shadow:\t\t\t\t\t\thsla(0, 0%, 0%, 0.1);\n\n\t/* -- Dropdown ------------------------------------------------------------------------------ */\n\n\t--ck-color-dropdown-panel-background: \t\t\t\t\t\tvar(--ck-color-base-background);\n\t--ck-color-dropdown-panel-border: \t\t\t\t\t\t\tvar(--ck-color-base-border);\n\n\t/* -- Dialog -------------------------------------------------------------------------------- */\n\n\t--ck-color-dialog-background: \t\t\t\t\t\t\t\tvar(--ck-custom-background);\n\t--ck-color-dialog-form-header-border: \t\t\t\t\t\tvar(--ck-custom-border);\n\n\t/* -- Input --------------------------------------------------------------------------------- */\n\n\t--ck-color-input-background: \t\t\t\t\t\t\t\tvar(--ck-color-base-background);\n\t--ck-color-input-border: \t\t\t\t\t\t\t\t\tvar(--ck-color-base-border);\n\t--ck-color-input-error-border:\t\t\t\t\t\t\t\tvar(--ck-color-base-error);\n\t--ck-color-input-text: \t\t\t\t\t\t\t\t\t\tvar(--ck-color-base-text);\n\t--ck-color-input-disabled-background: \t\t\t\t\t\thsl(0, 0%, 95%);\n\t--ck-color-input-disabled-border: \t\t\t\t\t\t\tvar(--ck-color-base-border);\n\t--ck-color-input-disabled-text: \t\t\t\t\t\t\thsl(0, 0%, 46%);\n\n\t/* -- List ---------------------------------------------------------------------------------- */\n\n\t--ck-color-list-background: \t\t\t\t\t\t\t\tvar(--ck-color-base-background);\n\t--ck-color-list-button-hover-background: \t\t\t\t\tvar(--ck-color-button-default-hover-background);\n\t--ck-color-list-button-on-background: \t\t\t\t\t\tvar(--ck-color-button-on-color);\n\t--ck-color-list-button-on-background-focus: \t\t\t\tvar(--ck-color-button-on-color);\n\t--ck-color-list-button-on-text:\t\t\t\t\t\t\t\tvar(--ck-color-base-background);\n\n\t/* -- Panel --------------------------------------------------------------------------------- */\n\n\t--ck-color-panel-background: \t\t\t\t\t\t\t\tvar(--ck-color-base-background);\n\t--ck-color-panel-border: \t\t\t\t\t\t\t\t\tvar(--ck-color-base-border);\n\n\t/* -- Toolbar ------------------------------------------------------------------------------- */\n\n\t--ck-color-toolbar-background: \t\t\t\t\t\t\t\tvar(--ck-color-base-background);\n\t--ck-color-toolbar-border: \t\t\t\t\t\t\t\t\tvar(--ck-color-base-border);\n\n\t/* -- Tooltip ------------------------------------------------------------------------------- */\n\n\t--ck-color-tooltip-background: \t\t\t\t\t\t\t\tvar(--ck-color-base-text);\n\t--ck-color-tooltip-text: \t\t\t\t\t\t\t\t\tvar(--ck-color-base-background);\n\n\t/* -- Engine -------------------------------------------------------------------------------- */\n\n\t--ck-color-engine-placeholder-text: \t\t\t\t\t\thsl(0, 0%, 44%);\n\n\t/* -- Upload -------------------------------------------------------------------------------- */\n\n\t--ck-color-upload-bar-background:\t\t \t\t\t\t\thsl(209, 92%, 70%);\n\n\t/* -- Link -------------------------------------------------------------------------------- */\n\n\t--ck-color-link-default:\t\t\t\t\t\t\t\t\thsl(240, 100%, 47%);\n\t--ck-color-link-selected-background:\t\t\t\t\t\thsla(201, 100%, 56%, 0.1);\n\t--ck-color-link-fake-selection:\t\t\t\t\t\t\t\thsla(201, 100%, 56%, 0.3);\n\n\t/* -- Search result highlight ---------------------------------------------------------------- */\n\n\t--ck-color-highlight-background:\t\t\t\t\t\t\thsl(60, 100%, 50%);\n\n\t/* -- Generic colors ------------------------------------------------------------------------- */\n\n\t--ck-color-light-red:\t\t\t\t\t\t\t\t\t\thsl(0, 100%, 90%);\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t/**\n\t * An opacity value of disabled UI item.\n\t */\n\t--ck-disabled-opacity: .5;\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t/**\n\t * The geometry of the of focused element's outer shadow.\n\t */\n\t--ck-focus-outer-shadow-geometry: 0 0 0 3px;\n\n\t/**\n\t * A visual style of focused element's outer shadow.\n\t */\n\t--ck-focus-outer-shadow: var(--ck-focus-outer-shadow-geometry) var(--ck-color-focus-outer-shadow);\n\n\t/**\n\t * A visual style of focused element's outer shadow (when disabled).\n\t */\n\t--ck-focus-disabled-outer-shadow: var(--ck-focus-outer-shadow-geometry) var(--ck-color-focus-disabled-shadow);\n\n\t/**\n\t * A visual style of focused element's outer shadow (when has errors).\n\t */\n\t--ck-focus-error-outer-shadow: var(--ck-focus-outer-shadow-geometry) var(--ck-color-focus-error-shadow);\n\n\t/**\n\t * A visual style of focused element's border or outline.\n\t */\n\t--ck-focus-ring: 1px solid var(--ck-color-focus-border);\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-font-size-base: 13px;\n\t--ck-line-height-base: 1.84615;\n\t--ck-font-face: Helvetica, Arial, Tahoma, Verdana, Sans-Serif;\n\n\t--ck-font-size-tiny: 0.7em;\n\t--ck-font-size-small: 0.75em;\n\t--ck-font-size-normal: 1em;\n\t--ck-font-size-big: 1.4em;\n\t--ck-font-size-large: 1.8em;\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t/* This is super-important. This is **manually** adjusted so a button without an icon\n\tis never smaller than a button with icon, additionally making sure that text-less buttons\n\tare perfect squares. The value is also shared by other components which should stay "in-line"\n\twith buttons. */\n\t--ck-ui-component-min-height: 2.3em;\n}\n\n/**\n * Resets an element, ignoring its children.\n */\n.ck.ck-reset,\n.ck.ck-reset_all,\n.ck-reset_all *:not(.ck-reset_all-excluded *) {\n\tbox-sizing: border-box;\n\twidth: auto;\n\theight: auto;\n\tposition: static;\n\n\t/* Do not include inheritable rules here. */\n\tmargin: 0;\n\tpadding: 0;\n\tborder: 0;\n\tbackground: transparent;\n\ttext-decoration: none;\n\tvertical-align: middle;\n\ttransition: none;\n\n\t/* https://github.com/ckeditor/ckeditor5-theme-lark/issues/105 */\n\tword-wrap: break-word;\n}\n\n/**\n * Resets an element AND its children.\n */\n.ck.ck-reset_all,\n.ck-reset_all *:not(.ck-reset_all-excluded *) {\n\t/* These are rule inherited by all children elements. */\n\tborder-collapse: collapse;\n\tfont: normal normal normal var(--ck-font-size-base)/var(--ck-line-height-base) var(--ck-font-face);\n\tcolor: var(--ck-color-text);\n\ttext-align: left;\n\twhite-space: nowrap;\n\tcursor: auto;\n\tfloat: none;\n}\n\n.ck-reset_all {\n\t& .ck-rtl *:not(.ck-reset_all-excluded *) {\n\t\ttext-align: right;\n\t}\n\n\t& iframe:not(.ck-reset_all-excluded *) {\n\t\t/* For IE */\n\t\tvertical-align: inherit;\n\t}\n\n\t& textarea:not(.ck-reset_all-excluded *) {\n\t\twhite-space: pre-wrap;\n\t}\n\n\t& textarea:not(.ck-reset_all-excluded *),\n\t& input[type="text"]:not(.ck-reset_all-excluded *),\n\t& input[type="password"]:not(.ck-reset_all-excluded *) {\n\t\tcursor: text;\n\t}\n\n\t& textarea[disabled]:not(.ck-reset_all-excluded *),\n\t& input[type="text"][disabled]:not(.ck-reset_all-excluded *),\n\t& input[type="password"][disabled]:not(.ck-reset_all-excluded *) {\n\t\tcursor: default;\n\t}\n\n\t& fieldset:not(.ck-reset_all-excluded *) {\n\t\tpadding: 10px;\n\t\tborder: 2px groove hsl(255, 7%, 88%);\n\t}\n\n\t& button:not(.ck-reset_all-excluded *)::-moz-focus-inner {\n\t\t/* See http://stackoverflow.com/questions/5517744/remove-extra-button-spacing-padding-in-firefox */\n\t\tpadding: 0;\n\t\tborder: 0\n\t}\n}\n\n/**\n * Default UI rules for RTL languages.\n */\n.ck[dir="rtl"],\n.ck[dir="rtl"] .ck {\n\ttext-align: right;\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * Default border-radius value.\n */\n:root{\n\t--ck-border-radius: 2px;\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t/**\n\t * A visual style of element's inner shadow (i.e. input).\n\t */\n\t--ck-inner-shadow: 2px 2px 3px var(--ck-color-shadow-inner) inset;\n\n\t/**\n\t * A visual style of element's drop shadow (i.e. panel).\n\t */\n\t--ck-drop-shadow: 0 1px 2px 1px var(--ck-color-shadow-drop);\n\n\t/**\n\t * A visual style of element's active shadow (i.e. comment or suggestion).\n\t */\n\t--ck-drop-shadow-active: 0 3px 6px 1px var(--ck-color-shadow-drop-active);\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-spacing-unit: \t\t\t\t\t\t0.6em;\n\t--ck-spacing-large: \t\t\t\t\tcalc(var(--ck-spacing-unit) * 1.5);\n\t--ck-spacing-standard: \t\t\t\t\tvar(--ck-spacing-unit);\n\t--ck-spacing-medium: \t\t\t\t\tcalc(var(--ck-spacing-unit) * 0.8);\n\t--ck-spacing-small: \t\t\t\t\tcalc(var(--ck-spacing-unit) * 0.5);\n\t--ck-spacing-tiny: \t\t\t\t\t\tcalc(var(--ck-spacing-unit) * 0.3);\n\t--ck-spacing-extra-tiny: \t\t\t\tcalc(var(--ck-spacing-unit) * 0.16);\n}\n"],sourceRoot:""}]);const a=s},1216:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,":root{--ck-color-resizer:var(--ck-color-focus-border);--ck-color-resizer-tooltip-background:#262626;--ck-color-resizer-tooltip-text:#f2f2f2;--ck-resizer-border-radius:var(--ck-border-radius);--ck-resizer-tooltip-offset:10px;--ck-resizer-tooltip-height:calc(var(--ck-spacing-small)*2 + 10px)}.ck .ck-widget,.ck .ck-widget.ck-widget_with-selection-handle{position:relative}.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle{position:absolute}.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle .ck-icon{display:block}.ck .ck-widget.ck-widget_with-selection-handle.ck-widget_selected>.ck-widget__selection-handle,.ck .ck-widget.ck-widget_with-selection-handle:hover>.ck-widget__selection-handle{visibility:visible}.ck .ck-size-view{background:var(--ck-color-resizer-tooltip-background);border:1px solid var(--ck-color-resizer-tooltip-text);border-radius:var(--ck-resizer-border-radius);color:var(--ck-color-resizer-tooltip-text);display:block;font-size:var(--ck-font-size-tiny);height:var(--ck-resizer-tooltip-height);line-height:var(--ck-resizer-tooltip-height);padding:0 var(--ck-spacing-small)}.ck .ck-size-view.ck-orientation-above-center,.ck .ck-size-view.ck-orientation-bottom-left,.ck .ck-size-view.ck-orientation-bottom-right,.ck .ck-size-view.ck-orientation-top-left,.ck .ck-size-view.ck-orientation-top-right{position:absolute}.ck .ck-size-view.ck-orientation-top-left{left:var(--ck-resizer-tooltip-offset);top:var(--ck-resizer-tooltip-offset)}.ck .ck-size-view.ck-orientation-top-right{right:var(--ck-resizer-tooltip-offset);top:var(--ck-resizer-tooltip-offset)}.ck .ck-size-view.ck-orientation-bottom-right{bottom:var(--ck-resizer-tooltip-offset);right:var(--ck-resizer-tooltip-offset)}.ck .ck-size-view.ck-orientation-bottom-left{bottom:var(--ck-resizer-tooltip-offset);left:var(--ck-resizer-tooltip-offset)}.ck .ck-size-view.ck-orientation-above-center{left:50%;top:calc(var(--ck-resizer-tooltip-height)*-1);transform:translate(-50%)}:root{--ck-widget-outline-thickness:3px;--ck-widget-handler-icon-size:16px;--ck-widget-handler-animation-duration:200ms;--ck-widget-handler-animation-curve:ease;--ck-color-widget-blurred-border:#dedede;--ck-color-widget-hover-border:#ffc83d;--ck-color-widget-editable-focus-background:var(--ck-color-base-background);--ck-color-widget-drag-handler-icon-color:var(--ck-color-base-background)}.ck .ck-widget{outline-color:transparent;outline-style:solid;outline-width:var(--ck-widget-outline-thickness);transition:outline-color var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve)}@media (prefers-reduced-motion:reduce){.ck .ck-widget{transition:none}}.ck .ck-widget.ck-widget_selected,.ck .ck-widget.ck-widget_selected:hover{outline:var(--ck-widget-outline-thickness) solid var(--ck-color-focus-border)}.ck .ck-widget:hover{outline-color:var(--ck-color-widget-hover-border)}.ck .ck-editor__nested-editable{border:1px solid transparent}.ck .ck-editor__nested-editable.ck-editor__nested-editable_focused,.ck .ck-editor__nested-editable:focus{border:var(--ck-focus-ring);box-shadow:var(--ck-inner-shadow),0 0;outline:none}@media (forced-colors:none){.ck .ck-editor__nested-editable.ck-editor__nested-editable_focused,.ck .ck-editor__nested-editable:focus{background-color:var(--ck-color-widget-editable-focus-background)}}.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle{background-color:transparent;border-radius:var(--ck-border-radius) var(--ck-border-radius) 0 0;box-sizing:border-box;left:calc(0px - var(--ck-widget-outline-thickness));opacity:0;padding:4px;top:0;transform:translateY(-100%);transition:background-color var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve),visibility var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve),opacity var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve)}@media (prefers-reduced-motion:reduce){.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle{transition:none}}.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle .ck-icon{color:var(--ck-color-widget-drag-handler-icon-color);height:var(--ck-widget-handler-icon-size);width:var(--ck-widget-handler-icon-size)}.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle .ck-icon .ck-icon__selected-indicator{opacity:0;transition:opacity .3s var(--ck-widget-handler-animation-curve)}@media (prefers-reduced-motion:reduce){.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle .ck-icon .ck-icon__selected-indicator{transition:none}}.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle:hover .ck-icon .ck-icon__selected-indicator{opacity:1}.ck .ck-widget.ck-widget_with-selection-handle:hover>.ck-widget__selection-handle{background-color:var(--ck-color-widget-hover-border);opacity:1}.ck .ck-widget.ck-widget_with-selection-handle.ck-widget_selected:hover>.ck-widget__selection-handle,.ck .ck-widget.ck-widget_with-selection-handle.ck-widget_selected>.ck-widget__selection-handle{background-color:var(--ck-color-focus-border);opacity:1}.ck .ck-widget.ck-widget_with-selection-handle.ck-widget_selected:hover>.ck-widget__selection-handle .ck-icon .ck-icon__selected-indicator,.ck .ck-widget.ck-widget_with-selection-handle.ck-widget_selected>.ck-widget__selection-handle .ck-icon .ck-icon__selected-indicator{opacity:1}.ck[dir=rtl] .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle{left:auto;right:calc(0px - var(--ck-widget-outline-thickness))}.ck.ck-editor__editable.ck-read-only .ck-widget{transition:none}.ck.ck-editor__editable.ck-read-only .ck-widget:not(.ck-widget_selected){--ck-widget-outline-thickness:0px}.ck.ck-editor__editable.ck-read-only .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle,.ck.ck-editor__editable.ck-read-only .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle:hover{background:var(--ck-color-widget-blurred-border)}.ck.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected,.ck.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected:hover{outline-color:var(--ck-color-widget-blurred-border)}.ck.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected.ck-widget_with-selection-handle:hover>.ck-widget__selection-handle,.ck.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected.ck-widget_with-selection-handle:hover>.ck-widget__selection-handle:hover,.ck.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected.ck-widget_with-selection-handle>.ck-widget__selection-handle,.ck.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected.ck-widget_with-selection-handle>.ck-widget__selection-handle:hover{background:var(--ck-color-widget-blurred-border)}.ck.ck-editor__editable blockquote>.ck-widget.ck-widget_with-selection-handle:first-child,.ck.ck-editor__editable>.ck-widget.ck-widget_with-selection-handle:first-child{margin-top:calc(1em + var(--ck-widget-handler-icon-size))}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-widget/theme/widget.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-widget/widget.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_focus.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/mixins/_shadow.css","webpack://./node_modules/@ckeditor/ckeditor5-ui/theme/mixins/_mediacolors.css"],names:[],mappings:"AAKA,MACC,+CAAgD,CAChD,6CAAsD,CACtD,uCAAgD,CAEhD,kDAAmD,CACnD,gCAAiC,CACjC,kEACD,CAOA,8DAEC,iBAqBD,CAnBC,4EACC,iBAOD,CALC,qFAGC,aACD,CASD,iLACC,kBACD,CAGD,kBACC,qDAAsD,CAEtD,qDAAsD,CACtD,6CAA8C,CAF9C,0CAA2C,CAI3C,aAAc,CADd,kCAAmC,CAGnC,uCAAwC,CACxC,4CAA6C,CAF7C,iCAsCD,CAlCC,8NAKC,iBACD,CAEA,0CAEC,qCAAsC,CADtC,oCAED,CAEA,2CAEC,sCAAuC,CADvC,oCAED,CAEA,8CACC,uCAAwC,CACxC,sCACD,CAEA,6CACC,uCAAwC,CACxC,qCACD,CAGA,8CAEC,QAAS,CADT,6CAAgD,CAEhD,yBACD,CChFD,MACC,iCAAkC,CAClC,kCAAmC,CACnC,4CAA6C,CAC7C,wCAAyC,CAEzC,wCAAiD,CACjD,sCAAkD,CAClD,2EAA4E,CAC5E,yEACD,CAEA,eAGC,yBAA0B,CAD1B,mBAAoB,CADpB,gDAAiD,CAGjD,6GAcD,CAZC,uCAND,eAOE,eAWF,CAVC,CAEA,0EAEC,6EACD,CAEA,qBACC,iDACD,CAGD,gCACC,4BAYD,CARC,yGCnCA,2BAA2B,CCF3B,qCAA8B,CDC9B,YD2CA,CGvCA,4BACC,yGHoCC,iEGlCD,CACD,CHuCA,4EAKC,4BAA6B,CAa7B,iEAAkE,CAhBlE,qBAAsB,CAoBtB,mDAAoD,CAhBpD,SAAU,CALV,WAAY,CAsBZ,KAAM,CAFN,2BAA4B,CAT5B,6SAwCD,CA3BC,uCAzBD,4EA0BE,eA0BF,CAzBC,CAEA,qFAIC,oDAAqD,CADrD,yCAA0C,CAD1C,wCAeD,CAVC,kHACC,SAAU,CAGV,+DAKD,CAHC,uCAND,kHAOE,eAEF,CADC,CAKF,wHACC,SACD,CAID,kFAEC,oDAAqD,CADrD,SAED,CAKC,oMAEC,6CAA8C,CAD9C,SAOD,CAHC,gRACC,SACD,CAOH,qFACC,SAAU,CACV,oDACD,CAGA,gDAEC,eAkBD,CAhBC,yEAOC,iCACD,CAGC,gOAEC,gDACD,CAOD,wIAEC,mDAQD,CALE,ghBAEC,gDACD,CAKH,yKAOC,yDACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-color-resizer: var(--ck-color-focus-border);\n\t--ck-color-resizer-tooltip-background: hsl(0, 0%, 15%);\n\t--ck-color-resizer-tooltip-text: hsl(0, 0%, 95%);\n\n\t--ck-resizer-border-radius: var(--ck-border-radius);\n\t--ck-resizer-tooltip-offset: 10px;\n\t--ck-resizer-tooltip-height: calc(var(--ck-spacing-small) * 2 + 10px);\n}\n\n.ck .ck-widget {\n\t/* This is neccessary for type around UI to be positioned properly. */\n\tposition: relative;\n}\n\n.ck .ck-widget.ck-widget_with-selection-handle {\n\t/* Make the widget wrapper a relative positioning container for the drag handle. */\n\tposition: relative;\n\n\t& .ck-widget__selection-handle {\n\t\tposition: absolute;\n\n\t\t& .ck-icon {\n\t\t\t/* Make sure the icon in not a subject to font-size or line-height to avoid\n\t\t\tunnecessary spacing around it. */\n\t\t\tdisplay: block;\n\t\t}\n\t}\n\n\t/* Show the selection handle on mouse hover over the widget, but not for nested widgets. */\n\t&:hover > .ck-widget__selection-handle {\n\t\tvisibility: visible;\n\t}\n\n\t/* Show the selection handle when the widget is selected, but not for nested widgets. */\n\t&.ck-widget_selected > .ck-widget__selection-handle {\n\t\tvisibility: visible;\n\t}\n}\n\n.ck .ck-size-view {\n\tbackground: var(--ck-color-resizer-tooltip-background);\n\tcolor: var(--ck-color-resizer-tooltip-text);\n\tborder: 1px solid var(--ck-color-resizer-tooltip-text);\n\tborder-radius: var(--ck-resizer-border-radius);\n\tfont-size: var(--ck-font-size-tiny);\n\tdisplay: block;\n\tpadding: 0 var(--ck-spacing-small);\n\theight: var(--ck-resizer-tooltip-height);\n\tline-height: var(--ck-resizer-tooltip-height);\n\n\t&.ck-orientation-top-left,\n\t&.ck-orientation-top-right,\n\t&.ck-orientation-bottom-right,\n\t&.ck-orientation-bottom-left,\n\t&.ck-orientation-above-center {\n\t\tposition: absolute;\n\t}\n\n\t&.ck-orientation-top-left {\n\t\ttop: var(--ck-resizer-tooltip-offset);\n\t\tleft: var(--ck-resizer-tooltip-offset);\n\t}\n\n\t&.ck-orientation-top-right {\n\t\ttop: var(--ck-resizer-tooltip-offset);\n\t\tright: var(--ck-resizer-tooltip-offset);\n\t}\n\n\t&.ck-orientation-bottom-right {\n\t\tbottom: var(--ck-resizer-tooltip-offset);\n\t\tright: var(--ck-resizer-tooltip-offset);\n\t}\n\n\t&.ck-orientation-bottom-left {\n\t\tbottom: var(--ck-resizer-tooltip-offset);\n\t\tleft: var(--ck-resizer-tooltip-offset);\n\t}\n\n\t/* Class applied if the widget is too small to contain the size label */\n\t&.ck-orientation-above-center {\n\t\ttop: calc(var(--ck-resizer-tooltip-height) * -1);\n\t\tleft: 50%;\n\t\ttransform: translate(-50%);\n\t}\n}\n",'/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@import "../mixins/_focus.css";\n@import "../mixins/_shadow.css";\n@import "@ckeditor/ckeditor5-ui/theme/mixins/_mediacolors.css";\n\n:root {\n\t--ck-widget-outline-thickness: 3px;\n\t--ck-widget-handler-icon-size: 16px;\n\t--ck-widget-handler-animation-duration: 200ms;\n\t--ck-widget-handler-animation-curve: ease;\n\n\t--ck-color-widget-blurred-border: hsl(0, 0%, 87%);\n\t--ck-color-widget-hover-border: hsl(43, 100%, 62%);\n\t--ck-color-widget-editable-focus-background: var(--ck-color-base-background);\n\t--ck-color-widget-drag-handler-icon-color: var(--ck-color-base-background);\n}\n\n.ck .ck-widget {\n\toutline-width: var(--ck-widget-outline-thickness);\n\toutline-style: solid;\n\toutline-color: transparent;\n\ttransition: outline-color var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve);\n\n\t@media (prefers-reduced-motion: reduce) {\n\t\ttransition: none;\n\t}\n\n\t&.ck-widget_selected,\n\t&.ck-widget_selected:hover {\n\t\toutline: var(--ck-widget-outline-thickness) solid var(--ck-color-focus-border);\n\t}\n\n\t&:hover {\n\t\toutline-color: var(--ck-color-widget-hover-border);\n\t}\n}\n\n.ck .ck-editor__nested-editable {\n\tborder: 1px solid transparent;\n\n\t/* The :focus style is applied before .ck-editor__nested-editable_focused class is rendered in the view.\n\tThese styles show a different border for a blink of an eye, so `:focus` need to have same styles applied. */\n\t&.ck-editor__nested-editable_focused,\n\t&:focus {\n\t\t@mixin ck-focus-ring;\n\t\t@mixin ck-box-shadow var(--ck-inner-shadow);\n\t\t@mixin ck-media-default-colors {\n\t\t\tbackground-color: var(--ck-color-widget-editable-focus-background);\n\t\t}\n\t}\n}\n\n.ck .ck-widget.ck-widget_with-selection-handle {\n\t& .ck-widget__selection-handle {\n\t\tpadding: 4px;\n\t\tbox-sizing: border-box;\n\n\t\t/* Background and opacity will be animated as the handler shows up or the widget gets selected. */\n\t\tbackground-color: transparent;\n\t\topacity: 0;\n\n\t\t/* Transition:\n\t\t * background-color for the .ck-widget_selected state change,\n\t\t * visibility for hiding the handler,\n\t\t * opacity for the proper look of the icon when the handler disappears. */\n\t\ttransition:\n\t\t\tbackground-color var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve),\n\t\t\tvisibility var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve),\n\t\t\topacity var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve);\n\n\t\t/* Make only top corners round. */\n\t\tborder-radius: var(--ck-border-radius) var(--ck-border-radius) 0 0;\n\n\t\t/* Place the drag handler outside the widget wrapper. */\n\t\ttransform: translateY(-100%);\n\t\tleft: calc(0px - var(--ck-widget-outline-thickness));\n\t\ttop: 0;\n\n\t\t@media (prefers-reduced-motion: reduce) {\n\t\t\ttransition: none;\n\t\t}\n\n\t\t& .ck-icon {\n\t\t\t/* Make sure the dimensions of the icon are independent of the fon-size of the content. */\n\t\t\twidth: var(--ck-widget-handler-icon-size);\n\t\t\theight: var(--ck-widget-handler-icon-size);\n\t\t\tcolor: var(--ck-color-widget-drag-handler-icon-color);\n\n\t\t\t/* The "selected" part of the icon is invisible by default */\n\t\t\t& .ck-icon__selected-indicator {\n\t\t\t\topacity: 0;\n\n\t\t\t\t/* Note: The animation is longer on purpose. Simply feels better. */\n\t\t\t\ttransition: opacity 300ms var(--ck-widget-handler-animation-curve);\n\n\t\t\t\t@media (prefers-reduced-motion: reduce) {\n\t\t\t\t\ttransition: none;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t/* Advertise using the look of the icon that once clicked the handler, the widget will be selected. */\n\t\t&:hover .ck-icon .ck-icon__selected-indicator {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\n\t/* Show the selection handler on mouse hover over the widget, but not for nested widgets. */\n\t&:hover > .ck-widget__selection-handle {\n\t\topacity: 1;\n\t\tbackground-color: var(--ck-color-widget-hover-border);\n\t}\n\n\t/* Show the selection handler when the widget is selected, but not for nested widgets. */\n\t&.ck-widget_selected,\n\t&.ck-widget_selected:hover {\n\t\t& > .ck-widget__selection-handle {\n\t\t\topacity: 1;\n\t\t\tbackground-color: var(--ck-color-focus-border);\n\n\t\t\t/* When the widget is selected, notify the user using the proper look of the icon. */\n\t\t\t& .ck-icon .ck-icon__selected-indicator {\n\t\t\t\topacity: 1;\n\t\t\t}\n\t\t}\n\t}\n}\n\n/* In a RTL environment, align the selection handler to the right side of the widget */\n/* stylelint-disable-next-line no-descending-specificity */\n.ck[dir="rtl"] .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle {\n\tleft: auto;\n\tright: calc(0px - var(--ck-widget-outline-thickness));\n}\n\n/* https://github.com/ckeditor/ckeditor5/issues/6415 */\n.ck.ck-editor__editable.ck-read-only .ck-widget {\n\t/* Prevent the :hover outline from showing up because of the used outline-color transition. */\n\ttransition: none;\n\n\t&:not(.ck-widget_selected) {\n\t\t/* Disable visual effects of hover/active widget when CKEditor is in readOnly mode.\n\t\t * See: https://github.com/ckeditor/ckeditor5/issues/1261\n\t\t *\n\t\t * Leave the unit because this custom property is used in calc() by other features.\n\t\t * See: https://github.com/ckeditor/ckeditor5/issues/6775\n\t\t */\n\t\t--ck-widget-outline-thickness: 0px;\n\t}\n\n\t&.ck-widget_with-selection-handle {\n\t\t& .ck-widget__selection-handle,\n\t\t& .ck-widget__selection-handle:hover {\n\t\t\tbackground: var(--ck-color-widget-blurred-border);\n\t\t}\n\t}\n}\n\n/* Style the widget when it\'s selected but the editable it belongs to lost focus. */\n/* stylelint-disable-next-line no-descending-specificity */\n.ck.ck-editor__editable.ck-blurred .ck-widget {\n\t&.ck-widget_selected,\n\t&.ck-widget_selected:hover {\n\t\toutline-color: var(--ck-color-widget-blurred-border);\n\n\t\t&.ck-widget_with-selection-handle {\n\t\t\t& > .ck-widget__selection-handle,\n\t\t\t& > .ck-widget__selection-handle:hover {\n\t\t\t\tbackground: var(--ck-color-widget-blurred-border);\n\t\t\t}\n\t\t}\n\t}\n}\n\n.ck.ck-editor__editable > .ck-widget.ck-widget_with-selection-handle:first-child,\n.ck.ck-editor__editable blockquote > .ck-widget.ck-widget_with-selection-handle:first-child {\n\t/* Do not crop selection handler if a widget is a first-child in the blockquote or in the root editable.\n\tIn fact, anything with overflow: hidden.\n\thttps://github.com/ckeditor/ckeditor5-block-quote/issues/28\n\thttps://github.com/ckeditor/ckeditor5-widget/issues/44\n\thttps://github.com/ckeditor/ckeditor5-widget/issues/66 */\n\tmargin-top: calc(1em + var(--ck-widget-handler-icon-size));\n}\n',"/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A visual style of focused element's border.\n */\n@define-mixin ck-focus-ring {\n\t/* Disable native outline. */\n\toutline: none;\n\tborder: var(--ck-focus-ring)\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * A helper to combine multiple shadows.\n */\n@define-mixin ck-box-shadow $shadowA, $shadowB: 0 0 {\n\tbox-shadow: $shadowA, $shadowB;\n}\n\n/**\n * Gives an element a drop shadow so it looks like a floating panel.\n */\n@define-mixin ck-drop-shadow {\n\t@mixin ck-box-shadow var(--ck-drop-shadow);\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n@define-mixin ck-media-forced-colors {\n\t@media (forced-colors: active) {\n\t\t& {\n\t\t\t@mixin-content;\n\t\t}\n\t}\n}\n\n@define-mixin ck-media-default-colors {\n\t@media (forced-colors: none) {\n\t\t& {\n\t\t\t@mixin-content;\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const a=s},2060:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,".ck .ck-widget_with-resizer{position:relative}.ck .ck-widget__resizer{display:none;left:0;pointer-events:none;position:absolute;top:0}.ck-focused .ck-widget_with-resizer.ck-widget_selected>.ck-widget__resizer{display:block}.ck .ck-widget__resizer__handle{pointer-events:all;position:absolute}.ck .ck-widget__resizer__handle.ck-widget__resizer__handle-bottom-right,.ck .ck-widget__resizer__handle.ck-widget__resizer__handle-top-left{cursor:nwse-resize}.ck .ck-widget__resizer__handle.ck-widget__resizer__handle-bottom-left,.ck .ck-widget__resizer__handle.ck-widget__resizer__handle-top-right{cursor:nesw-resize}:root{--ck-resizer-size:10px;--ck-resizer-offset:calc(var(--ck-resizer-size)/-2 - 2px);--ck-resizer-border-width:1px}.ck .ck-widget__resizer{outline:1px solid var(--ck-color-resizer)}.ck .ck-widget__resizer__handle{background:var(--ck-color-focus-border);border:var(--ck-resizer-border-width) solid #fff;border-radius:var(--ck-resizer-border-radius);height:var(--ck-resizer-size);width:var(--ck-resizer-size)}.ck .ck-widget__resizer__handle.ck-widget__resizer__handle-top-left{left:var(--ck-resizer-offset);top:var(--ck-resizer-offset)}.ck .ck-widget__resizer__handle.ck-widget__resizer__handle-top-right{right:var(--ck-resizer-offset);top:var(--ck-resizer-offset)}.ck .ck-widget__resizer__handle.ck-widget__resizer__handle-bottom-right{bottom:var(--ck-resizer-offset);right:var(--ck-resizer-offset)}.ck .ck-widget__resizer__handle.ck-widget__resizer__handle-bottom-left{bottom:var(--ck-resizer-offset);left:var(--ck-resizer-offset)}","",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-widget/theme/widgetresize.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-widget/widgetresize.css"],names:[],mappings:"AAKA,4BAEC,iBACD,CAEA,wBACC,YAAa,CAMb,MAAO,CAFP,mBAAoB,CAHpB,iBAAkB,CAMlB,KACD,CAGC,2EACC,aACD,CAGD,gCAIC,kBAAmB,CAHnB,iBAcD,CATC,4IAEC,kBACD,CAEA,4IAEC,kBACD,CCpCD,MACC,sBAAuB,CAGvB,yDAAiE,CACjE,6BACD,CAEA,wBACC,yCACD,CAEA,gCAGC,uCAAwC,CACxC,gDAA6D,CAC7D,6CAA8C,CAH9C,6BAA8B,CAD9B,4BAyBD,CAnBC,oEAEC,6BAA8B,CAD9B,4BAED,CAEA,qEAEC,8BAA+B,CAD/B,4BAED,CAEA,wEACC,+BAAgC,CAChC,8BACD,CAEA,uEACC,+BAAgC,CAChC,6BACD",sourcesContent:["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck .ck-widget_with-resizer {\n\t/* Make the widget wrapper a relative positioning container for the drag handle. */\n\tposition: relative;\n}\n\n.ck .ck-widget__resizer {\n\tdisplay: none;\n\tposition: absolute;\n\n\t/* The wrapper itself should not interfere with the pointer device, only the handles should. */\n\tpointer-events: none;\n\n\tleft: 0;\n\ttop: 0;\n}\n\n.ck-focused .ck-widget_with-resizer.ck-widget_selected {\n\t& > .ck-widget__resizer {\n\t\tdisplay: block;\n\t}\n}\n\n.ck .ck-widget__resizer__handle {\n\tposition: absolute;\n\n\t/* Resizers are the only UI elements that should interfere with a pointer device. */\n\tpointer-events: all;\n\n\t&.ck-widget__resizer__handle-top-left,\n\t&.ck-widget__resizer__handle-bottom-right {\n\t\tcursor: nwse-resize;\n\t}\n\n\t&.ck-widget__resizer__handle-top-right,\n\t&.ck-widget__resizer__handle-bottom-left {\n\t\tcursor: nesw-resize;\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-resizer-size: 10px;\n\n\t/* Set the resizer with a 50% offset. */\n\t--ck-resizer-offset: calc( ( var(--ck-resizer-size) / -2 ) - 2px);\n\t--ck-resizer-border-width: 1px;\n}\n\n.ck .ck-widget__resizer {\n\toutline: 1px solid var(--ck-color-resizer);\n}\n\n.ck .ck-widget__resizer__handle {\n\twidth: var(--ck-resizer-size);\n\theight: var(--ck-resizer-size);\n\tbackground: var(--ck-color-focus-border);\n\tborder: var(--ck-resizer-border-width) solid hsl(0, 0%, 100%);\n\tborder-radius: var(--ck-resizer-border-radius);\n\n\t&.ck-widget__resizer__handle-top-left {\n\t\ttop: var(--ck-resizer-offset);\n\t\tleft: var(--ck-resizer-offset);\n\t}\n\n\t&.ck-widget__resizer__handle-top-right {\n\t\ttop: var(--ck-resizer-offset);\n\t\tright: var(--ck-resizer-offset);\n\t}\n\n\t&.ck-widget__resizer__handle-bottom-right {\n\t\tbottom: var(--ck-resizer-offset);\n\t\tright: var(--ck-resizer-offset);\n\t}\n\n\t&.ck-widget__resizer__handle-bottom-left {\n\t\tbottom: var(--ck-resizer-offset);\n\t\tleft: var(--ck-resizer-offset);\n\t}\n}\n"],sourceRoot:""}]);const a=s},6779:(e,t,o)=>{"use strict";o.d(t,{A:()=>a});var n=o(1354),i=o.n(n),r=o(6314),s=o.n(r)()(i());s.push([e.id,'.ck .ck-widget .ck-widget__type-around__button{display:block;overflow:hidden;position:absolute;z-index:var(--ck-z-default)}.ck .ck-widget .ck-widget__type-around__button svg{left:50%;position:absolute;top:50%;z-index:calc(var(--ck-z-default) + 2)}.ck .ck-widget .ck-widget__type-around__button.ck-widget__type-around__button_before{left:min(10%,30px);top:calc(var(--ck-widget-outline-thickness)*-.5);transform:translateY(-50%)}.ck .ck-widget .ck-widget__type-around__button.ck-widget__type-around__button_after{bottom:calc(var(--ck-widget-outline-thickness)*-.5);right:min(10%,30px);transform:translateY(50%)}.ck .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button:after,.ck .ck-widget>.ck-widget__type-around>.ck-widget__type-around__button:hover:after{content:"";display:block;left:1px;position:absolute;top:1px;z-index:calc(var(--ck-z-default) + 1)}.ck .ck-widget>.ck-widget__type-around>.ck-widget__type-around__fake-caret{display:none;left:0;position:absolute;right:0}.ck .ck-widget:hover>.ck-widget__type-around>.ck-widget__type-around__fake-caret{left:calc(var(--ck-widget-outline-thickness)*-1);right:calc(var(--ck-widget-outline-thickness)*-1)}.ck .ck-widget.ck-widget_type-around_show-fake-caret_before>.ck-widget__type-around>.ck-widget__type-around__fake-caret{display:block;top:calc(var(--ck-widget-outline-thickness)*-1 - 1px)}.ck .ck-widget.ck-widget_type-around_show-fake-caret_after>.ck-widget__type-around>.ck-widget__type-around__fake-caret{bottom:calc(var(--ck-widget-outline-thickness)*-1 - 1px);display:block}.ck.ck-editor__editable.ck-read-only .ck-widget__type-around,.ck.ck-editor__editable.ck-restricted-editing_mode_restricted .ck-widget__type-around,.ck.ck-editor__editable.ck-widget__type-around_disabled .ck-widget__type-around{display:none}:root{--ck-widget-type-around-button-size:20px;--ck-color-widget-type-around-button-active:var(--ck-color-focus-border);--ck-color-widget-type-around-button-hover:var(--ck-color-widget-hover-border);--ck-color-widget-type-around-button-blurred-editable:var(--ck-color-widget-blurred-border);--ck-color-widget-type-around-button-radar-start-alpha:0;--ck-color-widget-type-around-button-radar-end-alpha:.3;--ck-color-widget-type-around-button-icon:var(--ck-color-base-background)}.ck .ck-widget .ck-widget__type-around__button{background:var(--ck-color-widget-type-around-button);border-radius:100px;height:var(--ck-widget-type-around-button-size);opacity:0;pointer-events:none;transition:opacity var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve),background var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve);width:var(--ck-widget-type-around-button-size)}@media (prefers-reduced-motion:reduce){.ck .ck-widget .ck-widget__type-around__button{transition:none}}.ck .ck-widget .ck-widget__type-around__button svg{height:8px;margin-top:1px;transform:translate(-50%,-50%);transition:transform .5s ease;width:10px}@media (prefers-reduced-motion:reduce){.ck .ck-widget .ck-widget__type-around__button svg{transition:none}}.ck .ck-widget .ck-widget__type-around__button svg *{stroke-dasharray:10;stroke-dashoffset:0;fill:none;stroke:var(--ck-color-widget-type-around-button-icon);stroke-width:1.5px;stroke-linecap:round;stroke-linejoin:round}.ck .ck-widget .ck-widget__type-around__button svg line{stroke-dasharray:7}.ck .ck-widget .ck-widget__type-around__button:hover{animation:ck-widget-type-around-button-sonar 1s ease infinite}.ck .ck-widget .ck-widget__type-around__button:hover svg polyline{animation:ck-widget-type-around-arrow-dash 2s linear}.ck .ck-widget .ck-widget__type-around__button:hover svg line{animation:ck-widget-type-around-arrow-tip-dash 2s linear}@media (prefers-reduced-motion:reduce){.ck .ck-widget .ck-widget__type-around__button:hover,.ck .ck-widget .ck-widget__type-around__button:hover svg line,.ck .ck-widget .ck-widget__type-around__button:hover svg polyline{animation:none}}.ck .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button,.ck .ck-widget:hover>.ck-widget__type-around>.ck-widget__type-around__button{opacity:1;pointer-events:auto}.ck .ck-widget:not(.ck-widget_selected)>.ck-widget__type-around>.ck-widget__type-around__button{background:var(--ck-color-widget-type-around-button-hover)}.ck .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button,.ck .ck-widget>.ck-widget__type-around>.ck-widget__type-around__button:hover{background:var(--ck-color-widget-type-around-button-active)}.ck .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button:after,.ck .ck-widget>.ck-widget__type-around>.ck-widget__type-around__button:hover:after{background:linear-gradient(135deg,hsla(0,0%,100%,0),hsla(0,0%,100%,.3));border-radius:100px;height:calc(var(--ck-widget-type-around-button-size) - 2px);width:calc(var(--ck-widget-type-around-button-size) - 2px)}.ck .ck-widget.ck-widget_with-selection-handle>.ck-widget__type-around>.ck-widget__type-around__button_before{margin-left:20px}.ck .ck-widget .ck-widget__type-around__fake-caret{animation:ck-widget-type-around-fake-caret-pulse 1s linear infinite normal forwards;background:var(--ck-color-base-text);height:1px;outline:1px solid hsla(0,0%,100%,.5);pointer-events:none}.ck .ck-widget.ck-widget_selected.ck-widget_type-around_show-fake-caret_after,.ck .ck-widget.ck-widget_selected.ck-widget_type-around_show-fake-caret_before{outline-color:transparent}.ck .ck-widget.ck-widget_type-around_show-fake-caret_after.ck-widget_selected:hover,.ck .ck-widget.ck-widget_type-around_show-fake-caret_before.ck-widget_selected:hover{outline-color:var(--ck-color-widget-hover-border)}.ck .ck-widget.ck-widget_type-around_show-fake-caret_after>.ck-widget__type-around>.ck-widget__type-around__button,.ck .ck-widget.ck-widget_type-around_show-fake-caret_before>.ck-widget__type-around>.ck-widget__type-around__button{opacity:0;pointer-events:none}.ck .ck-widget.ck-widget_type-around_show-fake-caret_after.ck-widget_selected.ck-widget_with-resizer>.ck-widget__resizer,.ck .ck-widget.ck-widget_type-around_show-fake-caret_after.ck-widget_with-selection-handle.ck-widget_selected:hover>.ck-widget__selection-handle,.ck .ck-widget.ck-widget_type-around_show-fake-caret_after.ck-widget_with-selection-handle.ck-widget_selected>.ck-widget__selection-handle,.ck .ck-widget.ck-widget_type-around_show-fake-caret_before.ck-widget_selected.ck-widget_with-resizer>.ck-widget__resizer,.ck .ck-widget.ck-widget_type-around_show-fake-caret_before.ck-widget_with-selection-handle.ck-widget_selected:hover>.ck-widget__selection-handle,.ck .ck-widget.ck-widget_type-around_show-fake-caret_before.ck-widget_with-selection-handle.ck-widget_selected>.ck-widget__selection-handle{opacity:0}.ck[dir=rtl] .ck-widget.ck-widget_with-selection-handle .ck-widget__type-around>.ck-widget__type-around__button_before{margin-left:0;margin-right:20px}.ck-editor__nested-editable.ck-editor__editable_selected .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button,.ck-editor__nested-editable.ck-editor__editable_selected .ck-widget:hover>.ck-widget__type-around>.ck-widget__type-around__button{opacity:0;pointer-events:none}.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button:not(:hover){background:var(--ck-color-widget-type-around-button-blurred-editable)}.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button:not(:hover) svg *{stroke:#999}@keyframes ck-widget-type-around-arrow-dash{0%{stroke-dashoffset:10}20%,to{stroke-dashoffset:0}}@keyframes ck-widget-type-around-arrow-tip-dash{0%,20%{stroke-dashoffset:7}40%,to{stroke-dashoffset:0}}@keyframes ck-widget-type-around-button-sonar{0%{box-shadow:0 0 0 0 hsla(var(--ck-color-focus-border-coordinates),var(--ck-color-widget-type-around-button-radar-start-alpha))}50%{box-shadow:0 0 0 5px hsla(var(--ck-color-focus-border-coordinates),var(--ck-color-widget-type-around-button-radar-end-alpha))}to{box-shadow:0 0 0 5px hsla(var(--ck-color-focus-border-coordinates),var(--ck-color-widget-type-around-button-radar-start-alpha))}}@keyframes ck-widget-type-around-fake-caret-pulse{0%{opacity:1}49%{opacity:1}50%{opacity:0}99%{opacity:0}to{opacity:1}}',"",{version:3,sources:["webpack://./node_modules/@ckeditor/ckeditor5-widget/theme/widgettypearound.css","webpack://./node_modules/@ckeditor/ckeditor5-theme-lark/theme/ckeditor5-widget/widgettypearound.css"],names:[],mappings:"AASC,+CACC,aAAc,CAEd,eAAgB,CADhB,iBAAkB,CAElB,2BAwBD,CAtBC,mDAGC,QAAS,CAFT,iBAAkB,CAClB,OAAQ,CAER,qCACD,CAEA,qFAGC,kBAAoB,CADpB,gDAAoD,CAGpD,0BACD,CAEA,oFAEC,mDAAuD,CACvD,mBAAqB,CAErB,yBACD,CAUA,mLACC,UAAW,CACX,aAAc,CAGd,QAAS,CAFT,iBAAkB,CAClB,OAAQ,CAER,qCACD,CAMD,2EACC,YAAa,CAEb,MAAO,CADP,iBAAkB,CAElB,OACD,CAOA,iFACC,gDAAqD,CACrD,iDACD,CAKA,wHAEC,aAAc,CADd,qDAED,CAKA,uHACC,wDAA6D,CAC7D,aACD,CAoBD,mOACC,YACD,CC3GA,MACC,wCAAyC,CACzC,wEAAyE,CACzE,8EAA+E,CAC/E,2FAA4F,CAC5F,wDAAyD,CACzD,uDAAwD,CACxD,yEACD,CAgBC,+CAGC,oDAAqD,CACrD,mBAAoB,CAFpB,+CAAgD,CAVjD,SAAU,CACV,mBAAoB,CAYnB,uMAAyM,CAJzM,8CAwED,CAhEC,uCATD,+CAUE,eA+DF,CA9DC,CAEA,mDAEC,UAAW,CAGX,cAAe,CAFf,8BAA+B,CAC/B,6BAA8B,CAH9B,UAwBD,CAlBC,uCAPD,mDAQE,eAiBF,CAhBC,CAEA,qDACC,mBAAoB,CACpB,mBAAoB,CAEpB,SAAU,CACV,qDAAsD,CACtD,kBAAmB,CACnB,oBAAqB,CACrB,qBACD,CAEA,wDACC,kBACD,CAGD,qDAIC,6DA4BD,CAtBE,kEACC,oDACD,CAEA,8DACC,wDACD,CAGD,uCAQE,qLACC,cACD,CAEF,CASD,uKA7FD,SAAU,CACV,mBA8FC,CAOD,gGACC,0DACD,CAOA,uKAEC,2DAQD,CANC,mLAIC,uEAAkF,CADlF,mBAAoB,CADpB,2DAA4D,CAD5D,0DAID,CAOD,8GACC,gBACD,CAKA,mDAGC,mFAAoF,CAOpF,oCAAqC,CARrC,UAAW,CAOX,oCAAwC,CARxC,mBAUD,CAOC,6JAEC,yBACD,CAUA,yKACC,iDACD,CAMA,uOAxKD,SAAU,CACV,mBAyKC,CAoBA,6yBACC,SACD,CASF,uHACC,aAAc,CACd,iBACD,CAYG,iRAxNF,SAAU,CACV,mBAyNE,CAQH,kIACC,qEAKD,CAHC,wIACC,WACD,CAGD,4CACC,GACC,oBACD,CACA,OACC,mBACD,CACD,CAEA,gDACC,OACC,mBACD,CACA,OACC,mBACD,CACD,CAEA,8CACC,GACC,6HACD,CACA,IACC,6HACD,CACA,GACC,+HACD,CACD,CAEA,kDACC,GACC,SACD,CACA,IACC,SACD,CACA,IACC,SACD,CACA,IACC,SACD,CACA,GACC,SACD,CACD",sourcesContent:['/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck .ck-widget {\n\t/*\n\t * Styles of the type around buttons\n\t */\n\t& .ck-widget__type-around__button {\n\t\tdisplay: block;\n\t\tposition: absolute;\n\t\toverflow: hidden;\n\t\tz-index: var(--ck-z-default);\n\n\t\t& svg {\n\t\t\tposition: absolute;\n\t\t\ttop: 50%;\n\t\t\tleft: 50%;\n\t\t\tz-index: calc(var(--ck-z-default) + 2);\n\t\t}\n\n\t\t&.ck-widget__type-around__button_before {\n\t\t\t/* Place it in the middle of the outline */\n\t\t\ttop: calc(-0.5 * var(--ck-widget-outline-thickness));\n\t\t\tleft: min(10%, 30px);\n\n\t\t\ttransform: translateY(-50%);\n\t\t}\n\n\t\t&.ck-widget__type-around__button_after {\n\t\t\t/* Place it in the middle of the outline */\n\t\t\tbottom: calc(-0.5 * var(--ck-widget-outline-thickness));\n\t\t\tright: min(10%, 30px);\n\n\t\t\ttransform: translateY(50%);\n\t\t}\n\t}\n\n\t/*\n\t * Styles for the buttons when:\n\t * - the widget is selected,\n\t * - or the button is being hovered (regardless of the widget state).\n\t */\n\t&.ck-widget_selected > .ck-widget__type-around > .ck-widget__type-around__button,\n\t& > .ck-widget__type-around > .ck-widget__type-around__button:hover {\n\t\t&::after {\n\t\t\tcontent: "";\n\t\t\tdisplay: block;\n\t\t\tposition: absolute;\n\t\t\ttop: 1px;\n\t\t\tleft: 1px;\n\t\t\tz-index: calc(var(--ck-z-default) + 1);\n\t\t}\n\t}\n\n\t/*\n\t * Styles for the horizontal "fake caret" which is displayed when the user navigates using the keyboard.\n\t */\n\t& > .ck-widget__type-around > .ck-widget__type-around__fake-caret {\n\t\tdisplay: none;\n\t\tposition: absolute;\n\t\tleft: 0;\n\t\tright: 0;\n\t}\n\n\t/*\n\t * When the widget is hovered the "fake caret" would normally be narrower than the\n\t * extra outline displayed around the widget. Let\'s extend the "fake caret" to match\n\t * the full width of the widget.\n\t */\n\t&:hover > .ck-widget__type-around > .ck-widget__type-around__fake-caret {\n\t\tleft: calc( -1 * var(--ck-widget-outline-thickness) );\n\t\tright: calc( -1 * var(--ck-widget-outline-thickness) );\n\t}\n\n\t/*\n\t * Styles for the horizontal "fake caret" when it should be displayed before the widget (backward keyboard navigation).\n\t */\n\t&.ck-widget_type-around_show-fake-caret_before > .ck-widget__type-around > .ck-widget__type-around__fake-caret {\n\t\ttop: calc( -1 * var(--ck-widget-outline-thickness) - 1px );\n\t\tdisplay: block;\n\t}\n\n\t/*\n\t * Styles for the horizontal "fake caret" when it should be displayed after the widget (forward keyboard navigation).\n\t */\n\t&.ck-widget_type-around_show-fake-caret_after > .ck-widget__type-around > .ck-widget__type-around__fake-caret {\n\t\tbottom: calc( -1 * var(--ck-widget-outline-thickness) - 1px );\n\t\tdisplay: block;\n\t}\n}\n\n/*\n * Integration with the read-only mode of the editor.\n */\n.ck.ck-editor__editable.ck-read-only .ck-widget__type-around {\n\tdisplay: none;\n}\n\n/*\n * Integration with the restricted editing mode (feature) of the editor.\n */\n.ck.ck-editor__editable.ck-restricted-editing_mode_restricted .ck-widget__type-around {\n\tdisplay: none;\n}\n\n/*\n * Integration with the #isEnabled property of the WidgetTypeAround plugin.\n */\n.ck.ck-editor__editable.ck-widget__type-around_disabled .ck-widget__type-around {\n\tdisplay: none;\n}\n','/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n:root {\n\t--ck-widget-type-around-button-size: 20px;\n\t--ck-color-widget-type-around-button-active: var(--ck-color-focus-border);\n\t--ck-color-widget-type-around-button-hover: var(--ck-color-widget-hover-border);\n\t--ck-color-widget-type-around-button-blurred-editable: var(--ck-color-widget-blurred-border);\n\t--ck-color-widget-type-around-button-radar-start-alpha: 0;\n\t--ck-color-widget-type-around-button-radar-end-alpha: .3;\n\t--ck-color-widget-type-around-button-icon: var(--ck-color-base-background);\n}\n\n@define-mixin ck-widget-type-around-button-visible {\n\topacity: 1;\n\tpointer-events: auto;\n}\n\n@define-mixin ck-widget-type-around-button-hidden {\n\topacity: 0;\n\tpointer-events: none;\n}\n\n.ck .ck-widget {\n\t/*\n\t * Styles of the type around buttons\n\t */\n\t& .ck-widget__type-around__button {\n\t\twidth: var(--ck-widget-type-around-button-size);\n\t\theight: var(--ck-widget-type-around-button-size);\n\t\tbackground: var(--ck-color-widget-type-around-button);\n\t\tborder-radius: 100px;\n\t\ttransition: opacity var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve), background var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve);\n\n\t\t@mixin ck-widget-type-around-button-hidden;\n\n\t\t@media (prefers-reduced-motion: reduce) {\n\t\t\ttransition: none;\n\t\t}\n\n\t\t& svg {\n\t\t\twidth: 10px;\n\t\t\theight: 8px;\n\t\t\ttransform: translate(-50%,-50%);\n\t\t\ttransition: transform .5s ease;\n\t\t\tmargin-top: 1px;\n\n\t\t\t@media (prefers-reduced-motion: reduce) {\n\t\t\t\ttransition: none;\n\t\t\t}\n\n\t\t\t& * {\n\t\t\t\tstroke-dasharray: 10;\n\t\t\t\tstroke-dashoffset: 0;\n\n\t\t\t\tfill: none;\n\t\t\t\tstroke: var(--ck-color-widget-type-around-button-icon);\n\t\t\t\tstroke-width: 1.5px;\n\t\t\t\tstroke-linecap: round;\n\t\t\t\tstroke-linejoin: round;\n\t\t\t}\n\n\t\t\t& line {\n\t\t\t\tstroke-dasharray: 7;\n\t\t\t}\n\t\t}\n\n\t\t&:hover {\n\t\t\t/*\n\t\t\t * Display the "sonar" around the button when hovered.\n\t\t\t */\n\t\t\tanimation: ck-widget-type-around-button-sonar 1s ease infinite;\n\n\t\t\t/*\n\t\t\t * Animate active button\'s icon.\n\t\t\t */\n\t\t\t& svg {\n\t\t\t\t& polyline {\n\t\t\t\t\tanimation: ck-widget-type-around-arrow-dash 2s linear;\n\t\t\t\t}\n\n\t\t\t\t& line {\n\t\t\t\t\tanimation: ck-widget-type-around-arrow-tip-dash 2s linear;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t@media (prefers-reduced-motion: reduce) {\n\t\t\t\tanimation: none;\n\n\t\t\t\t& svg {\n\t\t\t\t\t& polyline {\n\t\t\t\t\t\tanimation: none;\n\t\t\t\t\t}\n\n\t\t\t\t\t& line {\n\t\t\t\t\t\tanimation: none;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t/*\n\t * Show type around buttons when the widget gets selected or being hovered.\n\t */\n\t&.ck-widget_selected,\n\t&:hover {\n\t\t& > .ck-widget__type-around > .ck-widget__type-around__button {\n\t\t\t@mixin ck-widget-type-around-button-visible;\n\t\t}\n\t}\n\n\t/*\n\t * Styles for the buttons when the widget is NOT selected (but the buttons are visible\n\t * and still can be hovered).\n\t */\n\t&:not(.ck-widget_selected) > .ck-widget__type-around > .ck-widget__type-around__button {\n\t\tbackground: var(--ck-color-widget-type-around-button-hover);\n\t}\n\n\t/*\n\t * Styles for the buttons when:\n\t * - the widget is selected,\n\t * - or the button is being hovered (regardless of the widget state).\n\t */\n\t&.ck-widget_selected > .ck-widget__type-around > .ck-widget__type-around__button,\n\t& > .ck-widget__type-around > .ck-widget__type-around__button:hover {\n\t\tbackground: var(--ck-color-widget-type-around-button-active);\n\n\t\t&::after {\n\t\t\twidth: calc(var(--ck-widget-type-around-button-size) - 2px);\n\t\t\theight: calc(var(--ck-widget-type-around-button-size) - 2px);\n\t\t\tborder-radius: 100px;\n\t\t\tbackground: linear-gradient(135deg, hsla(0,0%,100%,0) 0%, hsla(0,0%,100%,.3) 100%);\n\t\t}\n\t}\n\n\t/*\n\t * Styles for the "before" button when the widget has a selection handle. Because some space\n\t * is consumed by the handle, the button must be moved slightly to the right to let it breathe.\n\t */\n\t&.ck-widget_with-selection-handle > .ck-widget__type-around > .ck-widget__type-around__button_before {\n\t\tmargin-left: 20px;\n\t}\n\n\t/*\n\t * Styles for the horizontal "fake caret" which is displayed when the user navigates using the keyboard.\n\t */\n\t& .ck-widget__type-around__fake-caret {\n\t\tpointer-events: none;\n\t\theight: 1px;\n\t\tanimation: ck-widget-type-around-fake-caret-pulse linear 1s infinite normal forwards;\n\n\t\t/*\n\t\t * The semi-transparent-outline+background combo improves the contrast\n\t\t * when the background underneath the fake caret is dark.\n\t\t */\n\t\toutline: solid 1px hsla(0, 0%, 100%, .5);\n\t\tbackground: var(--ck-color-base-text);\n\t}\n\n\t/*\n\t * Styles of the widget when the "fake caret" is blinking (e.g. upon keyboard navigation).\n\t * Despite the widget being physically selected in the model, its outline should disappear.\n\t */\n\t&.ck-widget_selected {\n\t\t&.ck-widget_type-around_show-fake-caret_before,\n\t\t&.ck-widget_type-around_show-fake-caret_after {\n\t\t\toutline-color: transparent;\n\t\t}\n\t}\n\n\t&.ck-widget_type-around_show-fake-caret_before,\n\t&.ck-widget_type-around_show-fake-caret_after {\n\t\t/*\n\t\t * When the "fake caret" is visible we simulate that the widget is not selected\n\t\t * (despite being physically selected), so the outline color should be for the\n\t\t * unselected widget.\n\t\t */\n\t\t&.ck-widget_selected:hover {\n\t\t\toutline-color: var(--ck-color-widget-hover-border);\n\t\t}\n\n\t\t/*\n\t\t * Styles of the type around buttons when the "fake caret" is blinking (e.g. upon keyboard navigation).\n\t\t * In this state, the type around buttons would collide with the fake carets so they should disappear.\n\t\t */\n\t\t& > .ck-widget__type-around > .ck-widget__type-around__button {\n\t\t\t@mixin ck-widget-type-around-button-hidden;\n\t\t}\n\n\t\t/*\n\t\t * Fake horizontal caret integration with the selection handle. When the caret is visible, simply\n\t\t * hide the handle because it intersects with the caret (and does not make much sense anyway).\n\t\t */\n\t\t&.ck-widget_with-selection-handle {\n\t\t\t&.ck-widget_selected,\n\t\t\t&.ck-widget_selected:hover {\n\t\t\t\t& > .ck-widget__selection-handle {\n\t\t\t\t\topacity: 0\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t/*\n\t\t * Fake horizontal caret integration with the resize UI. When the caret is visible, simply\n\t\t * hide the resize UI because it creates too much noise. It can be visible when the user\n\t\t * hovers the widget, though.\n\t\t */\n\t\t&.ck-widget_selected.ck-widget_with-resizer > .ck-widget__resizer {\n\t\t\topacity: 0\n\t\t}\n\t}\n}\n\n/*\n * Styles for the "before" button when the widget has a selection handle in an RTL environment.\n * The selection handler is aligned to the right side of the widget so there is no need to create\n * additional space for it next to the "before" button.\n */\n.ck[dir="rtl"] .ck-widget.ck-widget_with-selection-handle .ck-widget__type-around > .ck-widget__type-around__button_before {\n\tmargin-left: 0;\n\tmargin-right: 20px;\n}\n\n/*\n * Hide type around buttons when the widget is selected as a child of a selected\n * nested editable (e.g. mulit-cell table selection).\n *\n * See https://github.com/ckeditor/ckeditor5/issues/7263.\n */\n.ck-editor__nested-editable.ck-editor__editable_selected {\n\t& .ck-widget {\n\t\t&.ck-widget_selected,\n\t\t&:hover {\n\t\t\t& > .ck-widget__type-around > .ck-widget__type-around__button {\n\t\t\t\t@mixin ck-widget-type-around-button-hidden;\n\t\t\t}\n\t\t}\n\t}\n}\n\n/*\n * Styles for the buttons when the widget is selected but the user clicked outside of the editor (blurred the editor).\n */\n.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected > .ck-widget__type-around > .ck-widget__type-around__button:not(:hover) {\n\tbackground: var(--ck-color-widget-type-around-button-blurred-editable);\n\n\t& svg * {\n\t\tstroke: hsl(0,0%,60%);\n\t}\n}\n\n@keyframes ck-widget-type-around-arrow-dash {\n\t0% {\n\t\tstroke-dashoffset: 10;\n\t}\n\t20%, 100% {\n\t\tstroke-dashoffset: 0;\n\t}\n}\n\n@keyframes ck-widget-type-around-arrow-tip-dash {\n\t0%, 20% {\n\t\tstroke-dashoffset: 7;\n\t}\n\t40%, 100% {\n\t\tstroke-dashoffset: 0;\n\t}\n}\n\n@keyframes ck-widget-type-around-button-sonar {\n\t0% {\n\t\tbox-shadow: 0 0 0 0 hsla(var(--ck-color-focus-border-coordinates), var(--ck-color-widget-type-around-button-radar-start-alpha));\n\t}\n\t50% {\n\t\tbox-shadow: 0 0 0 5px hsla(var(--ck-color-focus-border-coordinates), var(--ck-color-widget-type-around-button-radar-end-alpha));\n\t}\n\t100% {\n\t\tbox-shadow: 0 0 0 5px hsla(var(--ck-color-focus-border-coordinates), var(--ck-color-widget-type-around-button-radar-start-alpha));\n\t}\n}\n\n@keyframes ck-widget-type-around-fake-caret-pulse {\n\t0% {\n\t\topacity: 1;\n\t}\n\t49% {\n\t\topacity: 1;\n\t}\n\t50% {\n\t\topacity: 0;\n\t}\n\t99% {\n\t\topacity: 0;\n\t}\n\t100% {\n\t\topacity: 1;\n\t}\n}\n'],sourceRoot:""}]);const a=s},6314:e=>{"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var o="",n=void 0!==t[5];return t[4]&&(o+="@supports (".concat(t[4],") {")),t[2]&&(o+="@media ".concat(t[2]," {")),n&&(o+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),o+=e(t),n&&(o+="}"),t[2]&&(o+="}"),t[4]&&(o+="}"),o})).join("")},t.i=function(e,o,n,i,r){"string"==typeof e&&(e=[[null,e,void 0]]);var s={};if(n)for(var a=0;a0?" ".concat(d[5]):""," {").concat(d[1],"}")),d[5]=r),o&&(d[2]?(d[1]="@media ".concat(d[2]," {").concat(d[1],"}"),d[2]=o):d[2]=o),i&&(d[4]?(d[1]="@supports (".concat(d[4],") {").concat(d[1],"}"),d[4]=i):d[4]="".concat(i)),t.push(d))}},t}},4417:e=>{"use strict";e.exports=function(e,t){return t||(t={}),e?(e=String(e.__esModule?e.default:e),/^['"].*['"]$/.test(e)&&(e=e.slice(1,-1)),t.hash&&(e+=t.hash),/["'() \t\n]|(%20)/.test(e)||t.needQuotes?'"'.concat(e.replace(/"/g,'\\"').replace(/\n/g,"\\n"),'"'):e):e}},1354:e=>{"use strict";e.exports=function(e){var t=e[1],o=e[3];if(!o)return t;if("function"==typeof btoa){var n=btoa(unescape(encodeURIComponent(JSON.stringify(o)))),i="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(n),r="/*# ".concat(i," */");return[t].concat([r]).join("\n")}return[t].join("\n")}},9878:function(e,t,o){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,o,n){void 0===n&&(n=o);var i=Object.getOwnPropertyDescriptor(t,o);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[o]}}),Object.defineProperty(e,n,i)}:function(e,t,o,n){void 0===n&&(n=o),e[n]=t[o]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),r=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var o in e)"default"!==o&&Object.prototype.hasOwnProperty.call(e,o)&&n(t,e,o);return i(t,e),t},s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.decodeXML=t.decodeHTMLStrict=t.decodeHTMLAttribute=t.decodeHTML=t.determineBranch=t.EntityDecoder=t.DecodingMode=t.BinTrieFlags=t.fromCodePoint=t.replaceCodePoint=t.decodeCodePoint=t.xmlDecodeTree=t.htmlDecodeTree=void 0;var a=s(o(3603));t.htmlDecodeTree=a.default;var l=s(o(2517));t.xmlDecodeTree=l.default;var c=r(o(5096));t.decodeCodePoint=c.default;var d,u=o(5096);Object.defineProperty(t,"replaceCodePoint",{enumerable:!0,get:function(){return u.replaceCodePoint}}),Object.defineProperty(t,"fromCodePoint",{enumerable:!0,get:function(){return u.fromCodePoint}}),function(e){e[e.NUM=35]="NUM",e[e.SEMI=59]="SEMI",e[e.EQUALS=61]="EQUALS",e[e.ZERO=48]="ZERO",e[e.NINE=57]="NINE",e[e.LOWER_A=97]="LOWER_A",e[e.LOWER_F=102]="LOWER_F",e[e.LOWER_X=120]="LOWER_X",e[e.LOWER_Z=122]="LOWER_Z",e[e.UPPER_A=65]="UPPER_A",e[e.UPPER_F=70]="UPPER_F",e[e.UPPER_Z=90]="UPPER_Z"}(d||(d={}));var h,m,p;function g(e){return e>=d.ZERO&&e<=d.NINE}function f(e){return e===d.EQUALS||function(e){return e>=d.UPPER_A&&e<=d.UPPER_Z||e>=d.LOWER_A&&e<=d.LOWER_Z||g(e)}(e)}!function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"}(h=t.BinTrieFlags||(t.BinTrieFlags={})),function(e){e[e.EntityStart=0]="EntityStart",e[e.NumericStart=1]="NumericStart",e[e.NumericDecimal=2]="NumericDecimal",e[e.NumericHex=3]="NumericHex",e[e.NamedEntity=4]="NamedEntity"}(m||(m={})),function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"}(p=t.DecodingMode||(t.DecodingMode={}));var b=function(){function e(e,t,o){this.decodeTree=e,this.emitCodePoint=t,this.errors=o,this.state=m.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=p.Strict}return e.prototype.startEntity=function(e){this.decodeMode=e,this.state=m.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1},e.prototype.write=function(e,t){switch(this.state){case m.EntityStart:return e.charCodeAt(t)===d.NUM?(this.state=m.NumericStart,this.consumed+=1,this.stateNumericStart(e,t+1)):(this.state=m.NamedEntity,this.stateNamedEntity(e,t));case m.NumericStart:return this.stateNumericStart(e,t);case m.NumericDecimal:return this.stateNumericDecimal(e,t);case m.NumericHex:return this.stateNumericHex(e,t);case m.NamedEntity:return this.stateNamedEntity(e,t)}},e.prototype.stateNumericStart=function(e,t){return t>=e.length?-1:(32|e.charCodeAt(t))===d.LOWER_X?(this.state=m.NumericHex,this.consumed+=1,this.stateNumericHex(e,t+1)):(this.state=m.NumericDecimal,this.stateNumericDecimal(e,t))},e.prototype.addToNumericResult=function(e,t,o,n){if(t!==o){var i=o-t;this.result=this.result*Math.pow(n,i)+parseInt(e.substr(t,i),n),this.consumed+=i}},e.prototype.stateNumericHex=function(e,t){for(var o,n=t;t=d.UPPER_A&&o<=d.UPPER_F||o>=d.LOWER_A&&o<=d.LOWER_F)))return this.addToNumericResult(e,n,t,16),this.emitNumericEntity(i,3);t+=1}return this.addToNumericResult(e,n,t,16),-1},e.prototype.stateNumericDecimal=function(e,t){for(var o=t;t>14;t>14)){if(r===d.SEMI)return this.emitNamedEntityData(this.treeIndex,i,this.consumed+this.excess);this.decodeMode!==p.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1},e.prototype.emitNotTerminatedNamedEntity=function(){var e,t=this.result,o=(this.decodeTree[t]&h.VALUE_LENGTH)>>14;return this.emitNamedEntityData(t,o,this.consumed),null===(e=this.errors)||void 0===e||e.missingSemicolonAfterCharacterReference(),this.consumed},e.prototype.emitNamedEntityData=function(e,t,o){var n=this.decodeTree;return this.emitCodePoint(1===t?n[e]&~h.VALUE_LENGTH:n[e+1],o),3===t&&this.emitCodePoint(n[e+2],o),o},e.prototype.end=function(){var e;switch(this.state){case m.NamedEntity:return 0===this.result||this.decodeMode===p.Attribute&&this.result!==this.treeIndex?0:this.emitNotTerminatedNamedEntity();case m.NumericDecimal:return this.emitNumericEntity(0,2);case m.NumericHex:return this.emitNumericEntity(0,3);case m.NumericStart:return null===(e=this.errors)||void 0===e||e.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case m.EntityStart:return 0}},e}();function k(e){var t="",o=new b(e,(function(e){return t+=(0,c.fromCodePoint)(e)}));return function(e,n){for(var i=0,r=0;(r=e.indexOf("&",r))>=0;){t+=e.slice(i,r),o.startEntity(n);var s=o.write(e,r+1);if(s<0){i=r+o.end();break}i=r+s,r=0===s?i+1:i}var a=t+e.slice(i);return t="",a}}function w(e,t,o,n){var i=(t&h.BRANCH_LENGTH)>>7,r=t&h.JUMP_TABLE;if(0===i)return 0!==r&&n===r?o:-1;if(r){var s=n-r;return s<0||s>=i?-1:e[o+s]-1}for(var a=o,l=a+i-1;a<=l;){var c=a+l>>>1,d=e[c];if(dn))return e[c+i];l=c-1}}return-1}t.EntityDecoder=b,t.determineBranch=w;var _=k(a.default),y=k(l.default);t.decodeHTML=function(e,t){return void 0===t&&(t=p.Legacy),_(e,t)},t.decodeHTMLAttribute=function(e){return _(e,p.Attribute)},t.decodeHTMLStrict=function(e){return _(e,p.Strict)},t.decodeXML=function(e){return y(e,p.Strict)}},5096:(e,t)=>{"use strict";var o;Object.defineProperty(t,"__esModule",{value:!0}),t.replaceCodePoint=t.fromCodePoint=void 0;var n=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]);function i(e){var t;return e>=55296&&e<=57343||e>1114111?65533:null!==(t=n.get(e))&&void 0!==t?t:e}t.fromCodePoint=null!==(o=String.fromCodePoint)&&void 0!==o?o:function(e){var t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|1023&e),t+=String.fromCharCode(e)},t.replaceCodePoint=i,t.default=function(e){return(0,t.fromCodePoint)(i(e))}},1818:function(e,t,o){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.encodeNonAsciiHTML=t.encodeHTML=void 0;var i=n(o(5504)),r=o(5987),s=/[\t\n!-,./:-@[-`\f{-}$\x80-\uFFFF]/g;function a(e,t){for(var o,n="",s=0;null!==(o=e.exec(t));){var a=o.index;n+=t.substring(s,a);var l=t.charCodeAt(a),c=i.default.get(l);if("object"==typeof c){if(a+1{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.escapeText=t.escapeAttribute=t.escapeUTF8=t.escape=t.encodeXML=t.getCodePoint=t.xmlReplacer=void 0,t.xmlReplacer=/["&'<>$\x80-\uFFFF]/g;var o=new Map([[34,"""],[38,"&"],[39,"'"],[60,"<"],[62,">"]]);function n(e){for(var n,i="",r=0;null!==(n=t.xmlReplacer.exec(e));){var s=n.index,a=e.charCodeAt(s),l=o.get(a);void 0!==l?(i+=e.substring(r,s)+l,r=s+1):(i+="".concat(e.substring(r,s),"&#x").concat((0,t.getCodePoint)(e,s).toString(16),";"),r=t.xmlReplacer.lastIndex+=Number(55296==(64512&a)))}return i+e.substr(r)}function i(e,t){return function(o){for(var n,i=0,r="";n=e.exec(o);)i!==n.index&&(r+=o.substring(i,n.index)),r+=t.get(n[0].charCodeAt(0)),i=n.index+1;return r+o.substring(i)}}t.getCodePoint=null!=String.prototype.codePointAt?function(e,t){return e.codePointAt(t)}:function(e,t){return 55296==(64512&e.charCodeAt(t))?1024*(e.charCodeAt(t)-55296)+e.charCodeAt(t+1)-56320+65536:e.charCodeAt(t)},t.encodeXML=n,t.escape=n,t.escapeUTF8=i(/[&<>'"]/g,o),t.escapeAttribute=i(/["&\u00A0]/g,new Map([[34,"""],[38,"&"],[160," "]])),t.escapeText=i(/[&<>\u00A0]/g,new Map([[38,"&"],[60,"<"],[62,">"],[160," "]]))},3603:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏ੊ઑඡ๭༉༦჊ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ὾⁠↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms„‹•˜¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲ΂ϏϢϸontourIntegraìȹoɴ͹\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՗՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲ׌y;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱cò׋؀JTabcdfgorstר׬ׯ׺؀ؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d׷׸䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇܎ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ޷޼߂ߐĀiyޱ޵rc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄΀HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶߻dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣ঳সে্਷ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗ࡜ࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४Ānrࢃ࢏gleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpw৔ਖਛgȀLRlr৞৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼੝੠੷੼અઋ઎p;椅y;䐜Ādl੥੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑ඗ඞcy;䐊cute;䅃ƀaey઴હાron;䅇dil;䅅;䐝ƀgswે૰଎ativeƀMTV૓૟૨ediumSpace;怋hiĀcn૦૘ë૙eryThiî૙tedĀGL૸ଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷ଺reak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊ஛ement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater΀;EFGLSTஶஷ஽௉௓௘௥扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲௽ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ೒拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨೹setĀ;E೰ೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂ෉෕ෛ෠෧෼ขภยา฿ไlig;䅒cute耻Ó䃓Āiy෎ීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲ෶cr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬื฼de耻Õ䃕es;樷ml耻Ö䃖erĀBP๋๠Āar๐๓r;怾acĀek๚๜;揞et;掴arenthesis;揜Ҁacfhilors๿ງຊຏຒດຝະ໼rtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ໠໤檻cedesȀ;EST່້໏໚扺qual;檯lantEqual;扼ilde;找me;怳Ādp໩໮uct;戏ortionĀ;aȥ໹l;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬؀BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁࿫࿳ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL࿜࿝࿡憒ar;懥eftArrow;懄eiling;按oǵ࿹\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»࿝pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄ቉ቕ቞ቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHc቎ቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗Āeiቻ኉Dzኀ\0ኇefore;戴a;䎘Ācn኎ኘkSpace;쀀  Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0᏿ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0጖y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻፿on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtè૙a;䎖r;愨pf;愤cr;쀀𝒵௡ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚΀;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒΀;Eaeiop዁ᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;e዁ᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;e዁ᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰ᜼ᝃᝈ᝸᝽០៦ᠹᡐᜍ᤽᥈ᥰot;櫭Ācrᛶ᜞kȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e᜚᜛戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀako៭ᠦᠵĀcn៲ᠣkƀlst៺֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘᠝斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈؀DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬ᣿ᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教΀;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ᣷᣹᣻᣽;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ᤟;敛;敘;攘;攔΀;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģ᥂bar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;e᜚᜜lƀ;bhᥨᥩᥫ䁜;槅sub;柈Ŭᥴ᥾lĀ;e᥹᥺怢t»᥺pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭍᭒\0᯽\0ᰌƀcpr᦭ᦲ᧝ute;䄇̀;abcdsᦿᧀᧄ᧊᧕᧙戩nd;橄rcup;橉Āau᧏᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r΀;Ecefms᩟᩠ᩢᩫ᪤᪪᪮旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖᪚᪟»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇᫔᫺\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ᫙\0\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩eóɍǧ᫾\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯΀delprvw᭠᭬᭷ᮂᮬᯔ᯹arrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;p᭿ᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰸᰻᰿ᱝᱩᱵᲊᲞᲬᲷ᳻᳿ᴍᵻᶑᶫᶻ᷆᷍rò΁ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂͸᳖᳜᳠mƀ;oș᳊᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄ὎὚ĀDoḆᴴoôᲉĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»Ṻƀaeiἒ἖Ἒls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙ῜ῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao‌⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧‪‬\0‮耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₟₥₰₴⃰⃵⃺⃿℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕ₝ute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽⃉ƀ;qsؾٌ⃄lanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqr׮ⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0↎proø₞r;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢␧␭␱␵␻ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀஀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼rò৆òΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonó྘quigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d྘➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ᠛旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐௏쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop඄⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roø඄urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓΀;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨í஘istĀ;s஠டr;쀀𝔫ȀEest௅⩦⩹⩼ƀ;qs஼⩭௡ƀ;qs஼௅⩴lanô௢ií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚΀AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs఻⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs఻⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast୻⭕⭚⭟lleì୻l;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖ΀chimpqu⮽⯍⯙⬄୸⯤⯯Ȁ;cerല⯆ഷ⯉uå൅;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭å೸åഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñ೗Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰⳴ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥ⵲ⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;c᪞ⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\0\0⵼\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕ⶘ⶥⶨrò᪀Āir⶝ⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔ⷗ǒr;榷rp;榹΀;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ⹞\0⹽\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ⹧⹲຅脀¶;l⹭⹮䂶leìЃɩ⹸\0\0⹻m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳⻴ᤈ⻹⻽⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp໬⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t໻⾴ï໻rel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⿚⋢⿟⿥⿫⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei⿾々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔઀ABHabcdefhilmnoprstux぀けさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤΀cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstw࿜ガクシスゼゾダッデナp;極Ā;f࿠ゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes㄂㄄;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ì࿲âヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘㇤㇮rrowĀ;t࿜ㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowó࿪arpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓rò࿪aòՑ;怏oustĀ;a㈞㈟掱che»㈟mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦΀Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼਴t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì⹯耻­䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;q኱ኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫ਩war;椪lig耻ß䃟௡㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rë๟ƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproø዁im»ኬsðኞĀas㚺㚮ð዁rn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈ΀adempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xô᝷headĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜΀eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roð໻tré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚΀cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜ៟tré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map((function(e){return e.charCodeAt(0)})))},2517:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=new Uint16Array("Ȁaglq\tɭ\0\0p;䀦os;䀧t;䀾t;䀼uot;䀢".split("").map((function(e){return e.charCodeAt(0)})))},5504:(e,t)=>{"use strict";function o(e){for(var t=1;t{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeXMLStrict=t.decodeHTML5Strict=t.decodeHTML4Strict=t.decodeHTML5=t.decodeHTML4=t.decodeHTMLAttribute=t.decodeHTMLStrict=t.decodeHTML=t.decodeXML=t.DecodingMode=t.EntityDecoder=t.encodeHTML5=t.encodeHTML4=t.encodeNonAsciiHTML=t.encodeHTML=t.escapeText=t.escapeAttribute=t.escapeUTF8=t.escape=t.encodeXML=t.encode=t.decodeStrict=t.decode=t.EncodingMode=t.EntityLevel=void 0;var n,i,r=o(9878),s=o(1818),a=o(5987);function l(e,t){if(void 0===t&&(t=n.XML),("number"==typeof t?t:t.level)===n.HTML){var o="object"==typeof t?t.mode:void 0;return(0,r.decodeHTML)(e,o)}return(0,r.decodeXML)(e)}!function(e){e[e.XML=0]="XML",e[e.HTML=1]="HTML"}(n=t.EntityLevel||(t.EntityLevel={})),function(e){e[e.UTF8=0]="UTF8",e[e.ASCII=1]="ASCII",e[e.Extensive=2]="Extensive",e[e.Attribute=3]="Attribute",e[e.Text=4]="Text"}(i=t.EncodingMode||(t.EncodingMode={})),t.decode=l,t.decodeStrict=function(e,t){var o;void 0===t&&(t=n.XML);var i="number"==typeof t?{level:t}:t;return null!==(o=i.mode)&&void 0!==o||(i.mode=r.DecodingMode.Strict),l(e,i)},t.encode=function(e,t){void 0===t&&(t=n.XML);var o="number"==typeof t?{level:t}:t;return o.mode===i.UTF8?(0,a.escapeUTF8)(e):o.mode===i.Attribute?(0,a.escapeAttribute)(e):o.mode===i.Text?(0,a.escapeText)(e):o.level===n.HTML?o.mode===i.ASCII?(0,s.encodeNonAsciiHTML)(e):(0,s.encodeHTML)(e):(0,a.encodeXML)(e)};var c=o(5987);Object.defineProperty(t,"encodeXML",{enumerable:!0,get:function(){return c.encodeXML}}),Object.defineProperty(t,"escape",{enumerable:!0,get:function(){return c.escape}}),Object.defineProperty(t,"escapeUTF8",{enumerable:!0,get:function(){return c.escapeUTF8}}),Object.defineProperty(t,"escapeAttribute",{enumerable:!0,get:function(){return c.escapeAttribute}}),Object.defineProperty(t,"escapeText",{enumerable:!0,get:function(){return c.escapeText}});var d=o(1818);Object.defineProperty(t,"encodeHTML",{enumerable:!0,get:function(){return d.encodeHTML}}),Object.defineProperty(t,"encodeNonAsciiHTML",{enumerable:!0,get:function(){return d.encodeNonAsciiHTML}}),Object.defineProperty(t,"encodeHTML4",{enumerable:!0,get:function(){return d.encodeHTML}}),Object.defineProperty(t,"encodeHTML5",{enumerable:!0,get:function(){return d.encodeHTML}});var u=o(9878);Object.defineProperty(t,"EntityDecoder",{enumerable:!0,get:function(){return u.EntityDecoder}}),Object.defineProperty(t,"DecodingMode",{enumerable:!0,get:function(){return u.DecodingMode}}),Object.defineProperty(t,"decodeXML",{enumerable:!0,get:function(){return u.decodeXML}}),Object.defineProperty(t,"decodeHTML",{enumerable:!0,get:function(){return u.decodeHTML}}),Object.defineProperty(t,"decodeHTMLStrict",{enumerable:!0,get:function(){return u.decodeHTMLStrict}}),Object.defineProperty(t,"decodeHTMLAttribute",{enumerable:!0,get:function(){return u.decodeHTMLAttribute}}),Object.defineProperty(t,"decodeHTML4",{enumerable:!0,get:function(){return u.decodeHTML}}),Object.defineProperty(t,"decodeHTML5",{enumerable:!0,get:function(){return u.decodeHTML}}),Object.defineProperty(t,"decodeHTML4Strict",{enumerable:!0,get:function(){return u.decodeHTMLStrict}}),Object.defineProperty(t,"decodeHTML5Strict",{enumerable:!0,get:function(){return u.decodeHTMLStrict}}),Object.defineProperty(t,"decodeXMLStrict",{enumerable:!0,get:function(){return u.decodeXML}})},2814:(e,t,o)=>{"use strict";var n=o(3492);function i(e){return Array.prototype.slice.call(arguments,1).forEach((function(t){t&&Object.keys(t).forEach((function(o){e[o]=t[o]}))})),e}function r(e){return Object.prototype.toString.call(e)}function s(e){return"[object Function]"===r(e)}function a(e){return e.replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}const l={fuzzyLink:!0,fuzzyEmail:!0,fuzzyIP:!1};const c={"http:":{validate:function(e,t,o){const n=e.slice(t);return o.re.http||(o.re.http=new RegExp("^\\/\\/"+o.re.src_auth+o.re.src_host_port_strict+o.re.src_path,"i")),o.re.http.test(n)?n.match(o.re.http)[0].length:0}},"https:":"http:","ftp:":"http:","//":{validate:function(e,t,o){const n=e.slice(t);return o.re.no_http||(o.re.no_http=new RegExp("^"+o.re.src_auth+"(?:localhost|(?:(?:"+o.re.src_domain+")\\.)+"+o.re.src_domain_root+")"+o.re.src_port+o.re.src_host_terminator+o.re.src_path,"i")),o.re.no_http.test(n)?t>=3&&":"===e[t-3]||t>=3&&"/"===e[t-3]?0:n.match(o.re.no_http)[0].length:0}},"mailto:":{validate:function(e,t,o){const n=e.slice(t);return o.re.mailto||(o.re.mailto=new RegExp("^"+o.re.src_email_name+"@"+o.re.src_host_strict,"i")),o.re.mailto.test(n)?n.match(o.re.mailto)[0].length:0}}},d="a[cdefgilmnoqrstuwxz]|b[abdefghijmnorstvwyz]|c[acdfghiklmnoruvwxyz]|d[ejkmoz]|e[cegrstu]|f[ijkmor]|g[abdefghilmnpqrstuwy]|h[kmnrtu]|i[delmnoqrst]|j[emop]|k[eghimnprwyz]|l[abcikrstuvy]|m[acdeghklmnopqrstuvwxyz]|n[acefgilopruz]|om|p[aefghklmnrstwy]|qa|r[eosuw]|s[abcdeghijklmnortuvxyz]|t[cdfghjklmnortvwz]|u[agksyz]|v[aceginu]|w[fs]|y[et]|z[amw]",u="biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф".split("|");function h(e){const t=e.re=function(e){const t={};e=e||{},t.src_Any=n.Any.source,t.src_Cc=n.Cc.source,t.src_Z=n.Z.source,t.src_P=n.P.source,t.src_ZPCc=[t.src_Z,t.src_P,t.src_Cc].join("|"),t.src_ZCc=[t.src_Z,t.src_Cc].join("|");const o="[><|]";return t.src_pseudo_letter="(?:(?![><|]|"+t.src_ZPCc+")"+t.src_Any+")",t.src_ip4="(?:(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)",t.src_auth="(?:(?:(?!"+t.src_ZCc+"|[@/\\[\\]()]).)+@)?",t.src_port="(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?",t.src_host_terminator="(?=$|[><|]|"+t.src_ZPCc+")(?!"+(e["---"]?"-(?!--)|":"-|")+"_|:\\d|\\.-|\\.(?!$|"+t.src_ZPCc+"))",t.src_path="(?:[/?#](?:(?!"+t.src_ZCc+"|"+o+"|[()[\\]{}.,\"'?!\\-;]).|\\[(?:(?!"+t.src_ZCc+"|\\]).)*\\]|\\((?:(?!"+t.src_ZCc+"|[)]).)*\\)|\\{(?:(?!"+t.src_ZCc+'|[}]).)*\\}|\\"(?:(?!'+t.src_ZCc+'|["]).)+\\"|\\\'(?:(?!'+t.src_ZCc+"|[']).)+\\'|\\'(?="+t.src_pseudo_letter+"|[-])|\\.{2,}[a-zA-Z0-9%/&]|\\.(?!"+t.src_ZCc+"|[.]|$)|"+(e["---"]?"\\-(?!--(?:[^-]|$))(?:-*)|":"\\-+|")+",(?!"+t.src_ZCc+"|$)|;(?!"+t.src_ZCc+"|$)|\\!+(?!"+t.src_ZCc+"|[!]|$)|\\?(?!"+t.src_ZCc+"|[?]|$))+|\\/)?",t.src_email_name='[\\-;:&=\\+\\$,\\.a-zA-Z0-9_][\\-;:&=\\+\\$,\\"\\.a-zA-Z0-9_]*',t.src_xn="xn--[a-z0-9\\-]{1,59}",t.src_domain_root="(?:"+t.src_xn+"|"+t.src_pseudo_letter+"{1,63})",t.src_domain="(?:"+t.src_xn+"|(?:"+t.src_pseudo_letter+")|(?:"+t.src_pseudo_letter+"(?:-|"+t.src_pseudo_letter+"){0,61}"+t.src_pseudo_letter+"))",t.src_host="(?:(?:(?:(?:"+t.src_domain+")\\.)*"+t.src_domain+"))",t.tpl_host_fuzzy="(?:"+t.src_ip4+"|(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%)))",t.tpl_host_no_ip_fuzzy="(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%))",t.src_host_strict=t.src_host+t.src_host_terminator,t.tpl_host_fuzzy_strict=t.tpl_host_fuzzy+t.src_host_terminator,t.src_host_port_strict=t.src_host+t.src_port+t.src_host_terminator,t.tpl_host_port_fuzzy_strict=t.tpl_host_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_port_no_ip_fuzzy_strict=t.tpl_host_no_ip_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_fuzzy_test="localhost|www\\.|\\.\\d{1,3}\\.|(?:\\.(?:%TLDS%)(?:"+t.src_ZPCc+"|>|$))",t.tpl_email_fuzzy='(^|[><|]|"|\\(|'+t.src_ZCc+")("+t.src_email_name+"@"+t.tpl_host_fuzzy_strict+")",t.tpl_link_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`||]|"+t.src_ZPCc+"))((?![$+<=>^`||])"+t.tpl_host_port_fuzzy_strict+t.src_path+")",t.tpl_link_no_ip_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`||]|"+t.src_ZPCc+"))((?![$+<=>^`||])"+t.tpl_host_port_no_ip_fuzzy_strict+t.src_path+")",t}(e.__opts__),o=e.__tlds__.slice();function i(e){return e.replace("%TLDS%",t.src_tlds)}e.onCompile(),e.__tlds_replaced__||o.push(d),o.push(t.src_xn),t.src_tlds=o.join("|"),t.email_fuzzy=RegExp(i(t.tpl_email_fuzzy),"i"),t.link_fuzzy=RegExp(i(t.tpl_link_fuzzy),"i"),t.link_no_ip_fuzzy=RegExp(i(t.tpl_link_no_ip_fuzzy),"i"),t.host_fuzzy_test=RegExp(i(t.tpl_host_fuzzy_test),"i");const l=[];function c(e,t){throw new Error('(LinkifyIt) Invalid schema "'+e+'": '+t)}e.__compiled__={},Object.keys(e.__schemas__).forEach((function(t){const o=e.__schemas__[t];if(null===o)return;const n={validate:null,link:null};if(e.__compiled__[t]=n,"[object Object]"===r(o))return!function(e){return"[object RegExp]"===r(e)}(o.validate)?s(o.validate)?n.validate=o.validate:c(t,o):n.validate=function(e){return function(t,o){const n=t.slice(o);return e.test(n)?n.match(e)[0].length:0}}(o.validate),void(s(o.normalize)?n.normalize=o.normalize:o.normalize?c(t,o):n.normalize=function(e,t){t.normalize(e)});!function(e){return"[object String]"===r(e)}(o)?c(t,o):l.push(t)})),l.forEach((function(t){e.__compiled__[e.__schemas__[t]]&&(e.__compiled__[t].validate=e.__compiled__[e.__schemas__[t]].validate,e.__compiled__[t].normalize=e.__compiled__[e.__schemas__[t]].normalize)})),e.__compiled__[""]={validate:null,normalize:function(e,t){t.normalize(e)}};const u=Object.keys(e.__compiled__).filter((function(t){return t.length>0&&e.__compiled__[t]})).map(a).join("|");e.re.schema_test=RegExp("(^|(?!_)(?:[><|]|"+t.src_ZPCc+"))("+u+")","i"),e.re.schema_search=RegExp("(^|(?!_)(?:[><|]|"+t.src_ZPCc+"))("+u+")","ig"),e.re.schema_at_start=RegExp("^"+e.re.schema_search.source,"i"),e.re.pretest=RegExp("("+e.re.schema_test.source+")|("+e.re.host_fuzzy_test.source+")|@","i"),function(e){e.__index__=-1,e.__text_cache__=""}(e)}function m(e,t){const o=e.__index__,n=e.__last_index__,i=e.__text_cache__.slice(o,n);this.schema=e.__schema__.toLowerCase(),this.index=o+t,this.lastIndex=n+t,this.raw=i,this.text=i,this.url=i}function p(e,t){const o=new m(e,t);return e.__compiled__[o.schema].normalize(o,e),o}function g(e,t){if(!(this instanceof g))return new g(e,t);var o;t||(o=e,Object.keys(o||{}).reduce((function(e,t){return e||l.hasOwnProperty(t)}),!1)&&(t=e,e={})),this.__opts__=i({},l,t),this.__index__=-1,this.__last_index__=-1,this.__schema__="",this.__text_cache__="",this.__schemas__=i({},c,e),this.__compiled__={},this.__tlds__=u,this.__tlds_replaced__=!1,this.re={},h(this)}g.prototype.add=function(e,t){return this.__schemas__[e]=t,h(this),this},g.prototype.set=function(e){return this.__opts__=i(this.__opts__,e),this},g.prototype.test=function(e){if(this.__text_cache__=e,this.__index__=-1,!e.length)return!1;let t,o,n,i,r,s,a,l,c;if(this.re.schema_test.test(e))for(a=this.re.schema_search,a.lastIndex=0;null!==(t=a.exec(e));)if(i=this.testSchemaAt(e,t[2],a.lastIndex),i){this.__schema__=t[2],this.__index__=t.index+t[1].length,this.__last_index__=t.index+t[0].length+i;break}return this.__opts__.fuzzyLink&&this.__compiled__["http:"]&&(l=e.search(this.re.host_fuzzy_test),l>=0&&(this.__index__<0||l=0&&null!==(n=e.match(this.re.email_fuzzy))&&(r=n.index+n[1].length,s=n.index+n[0].length,(this.__index__<0||rthis.__last_index__)&&(this.__schema__="mailto:",this.__index__=r,this.__last_index__=s))),this.__index__>=0},g.prototype.pretest=function(e){return this.re.pretest.test(e)},g.prototype.testSchemaAt=function(e,t,o){return this.__compiled__[t.toLowerCase()]?this.__compiled__[t.toLowerCase()].validate(e,o,this):0},g.prototype.match=function(e){const t=[];let o=0;this.__index__>=0&&this.__text_cache__===e&&(t.push(p(this,o)),o=this.__last_index__);let n=o?e.slice(o):e;for(;this.test(n);)t.push(p(this,o)),n=n.slice(this.__last_index__),o+=this.__last_index__;return t.length?t:null},g.prototype.matchAtStart=function(e){if(this.__text_cache__=e,this.__index__=-1,!e.length)return null;const t=this.re.schema_at_start.exec(e);if(!t)return null;const o=this.testSchemaAt(e,t[2],t[0].length);return o?(this.__schema__=t[2],this.__index__=t.index+t[1].length,this.__last_index__=t.index+t[0].length+o,p(this,0)):null},g.prototype.tlds=function(e,t){return e=Array.isArray(e)?e:[e],t?(this.__tlds__=this.__tlds__.concat(e).sort().filter((function(e,t,o){return e!==o[t-1]})).reverse(),h(this),this):(this.__tlds__=e.slice(),this.__tlds_replaced__=!0,h(this),this)},g.prototype.normalize=function(e){e.schema||(e.url="http://"+e.url),"mailto:"!==e.schema||/^mailto:/i.test(e.url)||(e.url="mailto:"+e.url)},g.prototype.onCompile=function(){},e.exports=g},9428:e=>{var t=!0,o=!1,n=!1;function i(e,t,o){var n=e.attrIndex(t),i=[t,o];n<0?e.attrPush(i):e.attrs[n]=i}function r(e,t){for(var o=e[t].level-1,n=t-1;n>=0;n--)if(e[n].level===o)return n;return-1}function s(e,t){return"inline"===e[t].type&&function(e){return"paragraph_open"===e.type}(e[t-1])&&function(e){return"list_item_open"===e.type}(e[t-2])&&function(e){return 0===e.content.indexOf("[ ] ")||0===e.content.indexOf("[x] ")||0===e.content.indexOf("[X] ")}(e[t])}function a(e,i){if(e.children.unshift(function(e,o){var n=new o("html_inline","",0),i=t?' disabled="" ':"";0===e.content.indexOf("[ ] ")?n.content='':0!==e.content.indexOf("[x] ")&&0!==e.content.indexOf("[X] ")||(n.content='');return n}(e,i)),e.children[1].content=e.children[1].content.slice(3),e.content=e.content.slice(3),o)if(n){e.children.pop();var r="task-item-"+Math.ceil(1e7*Math.random()-1e3);e.children[0].content=e.children[0].content.slice(0,-1)+' id="'+r+'">',e.children.push(function(e,t,o){var n=new o("html_inline","",0);return n.content='",n.attrs=[{for:t}],n}(e.content,r,i))}else e.children.unshift(function(e){var t=new e("html_inline","",0);return t.content="",t}(i))}e.exports=function(e,l){l&&(t=!l.enabled,o=!!l.label,n=!!l.labelAfter),e.core.ruler.after("inline","github-task-lists",(function(e){for(var o=e.tokens,n=2;n{"use strict";var n=o(5778),i=o(3492),r=o(2730),s=o(2814),a=o(7444);function l(e){var t=Object.create(null);return e&&Object.keys(e).forEach((function(o){if("default"!==o){var n=Object.getOwnPropertyDescriptor(e,o);Object.defineProperty(t,o,n.get?n:{enumerable:!0,get:function(){return e[o]}})}})),t.default=e,Object.freeze(t)}var c=l(n),d=l(i);function u(e){return"[object String]"===function(e){return Object.prototype.toString.call(e)}(e)}const h=Object.prototype.hasOwnProperty;function m(e){return Array.prototype.slice.call(arguments,1).forEach((function(t){if(t){if("object"!=typeof t)throw new TypeError(t+"must be object");Object.keys(t).forEach((function(o){e[o]=t[o]}))}})),e}function p(e,t,o){return[].concat(e.slice(0,t),o,e.slice(t+1))}function g(e){return!(e>=55296&&e<=57343)&&(!(e>=64976&&e<=65007)&&(65535!=(65535&e)&&65534!=(65535&e)&&(!(e>=0&&e<=8)&&(11!==e&&(!(e>=14&&e<=31)&&(!(e>=127&&e<=159)&&!(e>1114111)))))))}function f(e){if(e>65535){const t=55296+((e-=65536)>>10),o=56320+(1023&e);return String.fromCharCode(t,o)}return String.fromCharCode(e)}const b=/\\([!"#$%&'()*+,\-./:;<=>?@[\\\]^_`{|}~])/g,k=new RegExp(b.source+"|"+/&([a-z#][a-z0-9]{1,31});/gi.source,"gi"),w=/^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))$/i;function _(e){return e.indexOf("\\")<0&&e.indexOf("&")<0?e:e.replace(k,(function(e,t,o){return t||function(e,t){if(35===t.charCodeAt(0)&&w.test(t)){const o="x"===t[1].toLowerCase()?parseInt(t.slice(2),16):parseInt(t.slice(1),10);return g(o)?f(o):e}const o=r.decodeHTML(e);return o!==e?o:e}(e,o)}))}const y=/[&<>"]/,A=/[&<>"]/g,C={"&":"&","<":"<",">":">",'"':"""};function v(e){return C[e]}function x(e){return y.test(e)?e.replace(A,v):e}const E=/[.?*+^$[\]\\(){}|-]/g;function D(e){switch(e){case 9:case 32:return!0}return!1}function B(e){if(e>=8192&&e<=8202)return!0;switch(e){case 9:case 10:case 11:case 12:case 13:case 32:case 160:case 5760:case 8239:case 8287:case 12288:return!0}return!1}function S(e){return d.P.test(e)||d.S.test(e)}function T(e){switch(e){case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:case 58:case 59:case 60:case 61:case 62:case 63:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 124:case 125:case 126:return!0;default:return!1}}function I(e){return e=e.trim().replace(/\s+/g," "),"Ṿ"==="ẞ".toLowerCase()&&(e=e.replace(/ẞ/g,"ß")),e.toLowerCase().toUpperCase()}const P={mdurl:c,ucmicro:d};var F=Object.freeze({__proto__:null,arrayReplaceAt:p,assign:m,escapeHtml:x,escapeRE:function(e){return e.replace(E,"\\$&")},fromCodePoint:f,has:function(e,t){return h.call(e,t)},isMdAsciiPunct:T,isPunctChar:S,isSpace:D,isString:u,isValidEntityCode:g,isWhiteSpace:B,lib:P,normalizeReference:I,unescapeAll:_,unescapeMd:function(e){return e.indexOf("\\")<0?e:e.replace(b,"$1")}});var M=Object.freeze({__proto__:null,parseLinkDestination:function(e,t,o){let n,i=t;const r={ok:!1,pos:0,str:""};if(60===e.charCodeAt(i)){for(i++;i32))return r;if(41===n){if(0===s)break;s--}i++}return t===i||0!==s||(r.str=_(e.slice(t,i)),r.pos=i,r.ok=!0),r},parseLinkLabel:function(e,t,o){let n,i,r,s;const a=e.posMax,l=e.pos;for(e.pos=t+1,n=1;e.pos=o)return s;let n=e.charCodeAt(r);if(34!==n&&39!==n&&40!==n)return s;t++,r++,40===n&&(n=41),s.marker=n}for(;r"+x(r.content)+""},R.code_block=function(e,t,o,n,i){const r=e[t];return""+x(e[t].content)+"\n"},R.fence=function(e,t,o,n,i){const r=e[t],s=r.info?_(r.info).trim():"";let a,l="",c="";if(s){const e=s.split(/(\s+)/g);l=e[0],c=e.slice(2).join("")}if(a=o.highlight&&o.highlight(r.content,l,c)||x(r.content),0===a.indexOf("${a}\n`}return`
    ${a}
    \n`},R.image=function(e,t,o,n,i){const r=e[t];return r.attrs[r.attrIndex("alt")][1]=i.renderInlineAsText(r.children,o,n),i.renderToken(e,t,o)},R.hardbreak=function(e,t,o){return o.xhtmlOut?"
    \n":"
    \n"},R.softbreak=function(e,t,o){return o.breaks?o.xhtmlOut?"
    \n":"
    \n":"\n"},R.text=function(e,t){return x(e[t].content)},R.html_block=function(e,t){return e[t].content},R.html_inline=function(e,t){return e[t].content},z.prototype.renderAttrs=function(e){let t,o,n;if(!e.attrs)return"";for(n="",t=0,o=e.attrs.length;t\n":">",i},z.prototype.renderInline=function(e,t,o){let n="";const i=this.rules;for(let r=0,s=e.length;r=0&&(o=this.attrs[t][1]),o},O.prototype.attrJoin=function(e,t){const o=this.attrIndex(e);o<0?this.attrPush([e,t]):this.attrs[o][1]=this.attrs[o][1]+" "+t},N.prototype.Token=O;const L=/\r\n?|\n/g,H=/\0/g;function j(e){return/^<\/a\s*>/i.test(e)}const q=/\+-|\.\.|\?\?\?\?|!!!!|,,|--/,U=/\((c|tm|r)\)/i,W=/\((c|tm|r)\)/gi,$={c:"©",r:"®",tm:"™"};function G(e,t){return $[t.toLowerCase()]}function K(e){let t=0;for(let o=e.length-1;o>=0;o--){const n=e[o];"text"!==n.type||t||(n.content=n.content.replace(W,G)),"link_open"===n.type&&"auto"===n.info&&t--,"link_close"===n.type&&"auto"===n.info&&t++}}function Z(e){let t=0;for(let o=e.length-1;o>=0;o--){const n=e[o];"text"!==n.type||t||q.test(n.content)&&(n.content=n.content.replace(/\+-/g,"±").replace(/\.{2,}/g,"…").replace(/([?!])…/g,"$1..").replace(/([?!]){4,}/g,"$1$1$1").replace(/,{2,}/g,",").replace(/(^|[^-])---(?=[^-]|$)/gm,"$1—").replace(/(^|\s)--(?=\s|$)/gm,"$1–").replace(/(^|[^-\s])--(?=[^-\s]|$)/gm,"$1–")),"link_open"===n.type&&"auto"===n.info&&t--,"link_close"===n.type&&"auto"===n.info&&t++}}const J=/['"]/,Y=/['"]/g,Q="’";function X(e,t,o){return e.slice(0,t)+o+e.slice(t+1)}function ee(e,t){let o;const n=[];for(let i=0;i=0&&!(n[o].level<=s);o--);if(n.length=o+1,"text"!==r.type)continue;let a=r.content,l=0,c=a.length;e:for(;l=0)p=a.charCodeAt(d.index-1);else for(o=i-1;o>=0&&("softbreak"!==e[o].type&&"hardbreak"!==e[o].type);o--)if(e[o].content){p=e[o].content.charCodeAt(e[o].content.length-1);break}let g=32;if(l=48&&p<=57&&(h=u=!1),u&&h&&(u=f,h=b),u||h){if(h)for(o=n.length-1;o>=0;o--){let u=n[o];if(n[o].level=0;s--){const a=i[s];if("link_close"!==a.type){if("html_inline"===a.type&&(o=a.content,/^\s]/i.test(o)&&r>0&&r--,j(a.content)&&r++),!(r>0)&&"text"===a.type&&e.md.linkify.test(a.content)){const o=a.content;let r=e.md.linkify.match(o);const l=[];let c=a.level,d=0;r.length>0&&0===r[0].index&&s>0&&"text_special"===i[s-1].type&&(r=r.slice(1));for(let t=0;td){const t=new e.Token("text","",0);t.content=o.slice(d,a),t.level=c,l.push(t)}const u=new e.Token("link_open","a",1);u.attrs=[["href",i]],u.level=c++,u.markup="linkify",u.info="auto",l.push(u);const h=new e.Token("text","",0);h.content=s,h.level=c,l.push(h);const m=new e.Token("link_close","a",-1);m.level=--c,m.markup="linkify",m.info="auto",l.push(m),d=r[t].lastIndex}if(d=0;t--)"inline"===e.tokens[t].type&&(U.test(e.tokens[t].content)&&K(e.tokens[t].children),q.test(e.tokens[t].content)&&Z(e.tokens[t].children))}],["smartquotes",function(e){if(e.md.options.typographer)for(let t=e.tokens.length-1;t>=0;t--)"inline"===e.tokens[t].type&&J.test(e.tokens[t].content)&&ee(e.tokens[t].children,e)}],["text_join",function(e){let t,o;const n=e.tokens,i=n.length;for(let e=0;e0&&this.level++,this.tokens.push(n),n},ne.prototype.isEmpty=function(e){return this.bMarks[e]+this.tShift[e]>=this.eMarks[e]},ne.prototype.skipEmptyLines=function(e){for(let t=this.lineMax;et;)if(!D(this.src.charCodeAt(--e)))return e+1;return e},ne.prototype.skipChars=function(e,t){for(let o=this.src.length;eo;)if(t!==this.src.charCodeAt(--e))return e+1;return e},ne.prototype.getLines=function(e,t,o,n){if(e>=t)return"";const i=new Array(t-e);for(let r=0,s=e;so?new Array(e-o+1).join(" ")+this.src.slice(c,l):this.src.slice(c,l)}return i.join("")},ne.prototype.Token=O;function ie(e,t){const o=e.bMarks[t]+e.tShift[t],n=e.eMarks[t];return e.src.slice(o,n)}function re(e){const t=[],o=e.length;let n=0,i=e.charCodeAt(n),r=!1,s=0,a="";for(;n=n)return-1;let r=e.src.charCodeAt(i++);if(r<48||r>57)return-1;for(;;){if(i>=n)return-1;if(r=e.src.charCodeAt(i++),!(r>=48&&r<=57)){if(41===r||46===r)break;return-1}if(i-o>=10)return-1}return i`\\x00-\\x20]+|'[^']*'|\"[^\"]*\"))?)*\\s*\\/?>",ce="<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>",de=new RegExp("^(?:"+le+"|"+ce+"|\x3c!---?>|\x3c!--(?:[^-]|-[^-]|--[^>])*--\x3e|<[?][\\s\\S]*?[?]>|]*>|)"),ue=new RegExp("^(?:"+le+"|"+ce+")"),he=[[/^<(script|pre|style|textarea)(?=(\s|>|$))/i,/<\/(script|pre|style|textarea)>/i,!0],[/^/,!0],[/^<\?/,/\?>/,!0],[/^/,!0],[/^/,!0],[new RegExp("^|$))","i"),/^$/,!0],[new RegExp(ue.source+"\\s*$"),/^$/,!1]];const me=[["table",function(e,t,o,n){if(t+2>o)return!1;let i=t+1;if(e.sCount[i]=4)return!1;let r=e.bMarks[i]+e.tShift[i];if(r>=e.eMarks[i])return!1;const s=e.src.charCodeAt(r++);if(124!==s&&45!==s&&58!==s)return!1;if(r>=e.eMarks[i])return!1;const a=e.src.charCodeAt(r++);if(124!==a&&45!==a&&58!==a&&!D(a))return!1;if(45===s&&D(a))return!1;for(;r=4)return!1;c=re(l),c.length&&""===c[0]&&c.shift(),c.length&&""===c[c.length-1]&&c.pop();const u=c.length;if(0===u||u!==d.length)return!1;if(n)return!0;const h=e.parentType;e.parentType="table";const m=e.md.block.ruler.getRules("blockquote"),p=[t,0];e.push("table_open","table",1).map=p,e.push("thead_open","thead",1).map=[t,t+1],e.push("tr_open","tr",1).map=[t,t+1];for(let t=0;t=4)break;if(c=re(l),c.length&&""===c[0]&&c.shift(),c.length&&""===c[c.length-1]&&c.pop(),f+=u-c.length,f>65536)break;if(i===t+2){e.push("tbody_open","tbody",1).map=g=[t+2,0]}e.push("tr_open","tr",1).map=[i,i+1];for(let t=0;t=4))break;n++,i=n}e.line=i;const r=e.push("code_block","code",0);return r.content=e.getLines(t,i,4+e.blkIndent,!1)+"\n",r.map=[t,e.line],!0}],["fence",function(e,t,o,n){let i=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;if(i+3>r)return!1;const s=e.src.charCodeAt(i);if(126!==s&&96!==s)return!1;let a=i;i=e.skipChars(i,s);let l=i-a;if(l<3)return!1;const c=e.src.slice(a,i),d=e.src.slice(i,r);if(96===s&&d.indexOf(String.fromCharCode(s))>=0)return!1;if(n)return!0;let u=t,h=!1;for(;(u++,!(u>=o))&&(i=a=e.bMarks[u]+e.tShift[u],r=e.eMarks[u],!(i=4||(i=e.skipChars(i,s),i-a=4)return!1;if(62!==e.src.charCodeAt(i))return!1;if(n)return!0;const a=[],l=[],c=[],d=[],u=e.md.block.ruler.getRules("blockquote"),h=e.parentType;e.parentType="blockquote";let m,p=!1;for(m=t;m=r)break;if(62===e.src.charCodeAt(i++)&&!t){let t,o,n=e.sCount[m]+1;32===e.src.charCodeAt(i)?(i++,n++,o=!1,t=!0):9===e.src.charCodeAt(i)?(t=!0,(e.bsCount[m]+n)%4==3?(i++,n++,o=!1):o=!0):t=!1;let s=n;for(a.push(e.bMarks[m]),e.bMarks[m]=i;i=r,l.push(e.bsCount[m]),e.bsCount[m]=e.sCount[m]+1+(t?1:0),c.push(e.sCount[m]),e.sCount[m]=s-n,d.push(e.tShift[m]),e.tShift[m]=i-e.bMarks[m];continue}if(p)break;let n=!1;for(let t=0,i=u.length;t";const b=[t,0];f.map=b,e.md.block.tokenize(e,t,m),e.push("blockquote_close","blockquote",-1).markup=">",e.lineMax=s,e.parentType=h,b[1]=e.line;for(let o=0;o=4)return!1;let r=e.bMarks[t]+e.tShift[t];const s=e.src.charCodeAt(r++);if(42!==s&&45!==s&&95!==s)return!1;let a=1;for(;r=4)return!1;if(e.listIndent>=0&&e.sCount[l]-e.listIndent>=4&&e.sCount[l]=e.blkIndent&&(m=!0),(h=ae(e,l))>=0){if(d=!0,s=e.bMarks[l]+e.tShift[l],u=Number(e.src.slice(s,h-1)),m&&1!==u)return!1}else{if(!((h=se(e,l))>=0))return!1;d=!1}if(m&&e.skipSpaces(h)>=e.eMarks[l])return!1;if(n)return!0;const p=e.src.charCodeAt(h-1),g=e.tokens.length;d?(a=e.push("ordered_list_open","ol",1),1!==u&&(a.attrs=[["start",u]])):a=e.push("bullet_list_open","ul",1);const f=[l,0];a.map=f,a.markup=String.fromCharCode(p);let b=!1;const k=e.md.block.ruler.getRules("list"),w=e.parentType;for(e.parentType="list";l=i?1:n-t,m>4&&(m=1);const g=t+m;a=e.push("list_item_open","li",1),a.markup=String.fromCharCode(p);const f=[l,0];a.map=f,d&&(a.info=e.src.slice(s,h-1));const w=e.tight,_=e.tShift[l],y=e.sCount[l],A=e.listIndent;if(e.listIndent=e.blkIndent,e.blkIndent=g,e.tight=!0,e.tShift[l]=u-e.bMarks[l],e.sCount[l]=n,u>=i&&e.isEmpty(l+1)?e.line=Math.min(e.line+2,o):e.md.block.tokenize(e,l,o,!0),e.tight&&!b||(c=!1),b=e.line-l>1&&e.isEmpty(e.line-1),e.blkIndent=e.listIndent,e.listIndent=A,e.tShift[l]=_,e.sCount[l]=y,e.tight=w,a=e.push("list_item_close","li",-1),a.markup=String.fromCharCode(p),l=e.line,f[1]=l,l>=o)break;if(e.sCount[l]=4)break;let C=!1;for(let t=0,n=k.length;t=4)return!1;if(91!==e.src.charCodeAt(i))return!1;function a(t){const o=e.lineMax;if(t>=o||e.isEmpty(t))return null;let n=!1;if(e.sCount[t]-e.blkIndent>3&&(n=!0),e.sCount[t]<0&&(n=!0),!n){const n=e.md.block.ruler.getRules("reference"),i=e.parentType;e.parentType="reference";let r=!1;for(let i=0,s=n.length;i=4)return!1;if(!e.md.options.html)return!1;if(60!==e.src.charCodeAt(i))return!1;let s=e.src.slice(i,r),a=0;for(;a=4)return!1;let s=e.src.charCodeAt(i);if(35!==s||i>=r)return!1;let a=1;for(s=e.src.charCodeAt(++i);35===s&&i6||ii&&D(e.src.charCodeAt(l-1))&&(r=l),e.line=t+1;const c=e.push("heading_open","h"+String(a),1);c.markup="########".slice(0,a),c.map=[t,e.line];const d=e.push("inline","",0);return d.content=e.src.slice(i,r).trim(),d.map=[t,e.line],d.children=[],e.push("heading_close","h"+String(a),-1).markup="########".slice(0,a),!0},["paragraph","reference","blockquote"]],["lheading",function(e,t,o){const n=e.md.block.ruler.getRules("paragraph");if(e.sCount[t]-e.blkIndent>=4)return!1;const i=e.parentType;e.parentType="paragraph";let r,s=0,a=t+1;for(;a3)continue;if(e.sCount[a]>=e.blkIndent){let t=e.bMarks[a]+e.tShift[a];const o=e.eMarks[a];if(t=o))){s=61===r?1:2;break}}if(e.sCount[a]<0)continue;let t=!1;for(let i=0,r=n.length;i3)continue;if(e.sCount[r]<0)continue;let t=!1;for(let i=0,s=n.length;i=o))&&!(e.sCount[s]=r){e.line=o;break}const t=e.line;let l=!1;for(let r=0;r=e.line)throw new Error("block rule didn't increment state.line");break}if(!l)throw new Error("none of the block rules matched");e.tight=!a,e.isEmpty(e.line-1)&&(a=!0),s=e.line,s0&&(this.level++,this._prev_delimiters.push(this.delimiters),this.delimiters=[],i={delimiters:this.delimiters}),this.pendingLevel=this.level,this.tokens.push(n),this.tokens_meta.push(i),n},ge.prototype.scanDelims=function(e,t){const o=this.posMax,n=this.src.charCodeAt(e),i=e>0?this.src.charCodeAt(e-1):32;let r=e;for(;r?@[]^_`{|}~-".split("").forEach((function(e){ke[e.charCodeAt(0)]=1}));var _e={tokenize:function(e,t){const o=e.pos,n=e.src.charCodeAt(o);if(t)return!1;if(126!==n)return!1;const i=e.scanDelims(e.pos,!0);let r=i.length;const s=String.fromCharCode(n);if(r<2)return!1;let a;r%2&&(a=e.push("text","",0),a.content=s,r--);for(let t=0;t=0;o--){const n=t[o];if(95!==n.marker&&42!==n.marker)continue;if(-1===n.end)continue;const i=t[n.end],r=o>0&&t[o-1].end===n.end+1&&t[o-1].marker===n.marker&&t[o-1].token===n.token-1&&t[n.end+1].token===i.token+1,s=String.fromCharCode(n.marker),a=e.tokens[n.token];a.type=r?"strong_open":"em_open",a.tag=r?"strong":"em",a.nesting=1,a.markup=r?s+s:s,a.content="";const l=e.tokens[i.token];l.type=r?"strong_close":"em_close",l.tag=r?"strong":"em",l.nesting=-1,l.markup=r?s+s:s,l.content="",r&&(e.tokens[t[o-1].token].content="",e.tokens[t[n.end+1].token].content="",o--)}}var Ae={tokenize:function(e,t){const o=e.pos,n=e.src.charCodeAt(o);if(t)return!1;if(95!==n&&42!==n)return!1;const i=e.scanDelims(e.pos,42===n);for(let t=0;t\x00-\x20]*)$/;const xe=/^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i,Ee=/^&([a-z][a-z0-9]{1,31});/i;function De(e){const t={},o=e.length;if(!o)return;let n=0,i=-2;const r=[];for(let s=0;sa;l-=r[l]+1){const t=e[l];if(t.marker===o.marker&&(t.open&&t.end<0)){let n=!1;if((t.close||o.open)&&(t.length+o.length)%3==0&&(t.length%3==0&&o.length%3==0||(n=!0)),!n){const n=l>0&&!e[l-1].open?r[l-1]+1:0;r[s]=s-l+n,r[l]=n,o.open=!1,t.end=s,t.close=!1,c=-1,i=-2;break}}}-1!==c&&(t[o.marker][(o.open?3:0)+(o.length||0)%3]=c)}}const Be=[["text",function(e,t){let o=e.pos;for(;o0)return!1;const o=e.pos;if(o+3>e.posMax)return!1;if(58!==e.src.charCodeAt(o))return!1;if(47!==e.src.charCodeAt(o+1))return!1;if(47!==e.src.charCodeAt(o+2))return!1;const n=e.pending.match(be);if(!n)return!1;const i=n[1],r=e.md.linkify.matchAtStart(e.src.slice(o-i.length));if(!r)return!1;let s=r.url;if(s.length<=i.length)return!1;s=s.replace(/\*+$/,"");const a=e.md.normalizeLink(s);if(!e.md.validateLink(a))return!1;if(!t){e.pending=e.pending.slice(0,-i.length);const t=e.push("link_open","a",1);t.attrs=[["href",a]],t.markup="linkify",t.info="auto";e.push("text","",0).content=e.md.normalizeLinkText(s);const o=e.push("link_close","a",-1);o.markup="linkify",o.info="auto"}return e.pos+=s.length-i.length,!0}],["newline",function(e,t){let o=e.pos;if(10!==e.src.charCodeAt(o))return!1;const n=e.pending.length-1,i=e.posMax;if(!t)if(n>=0&&32===e.pending.charCodeAt(n))if(n>=1&&32===e.pending.charCodeAt(n-1)){let t=n-1;for(;t>=1&&32===e.pending.charCodeAt(t-1);)t--;e.pending=e.pending.slice(0,t),e.push("hardbreak","br",0)}else e.pending=e.pending.slice(0,-1),e.push("softbreak","br",0);else e.push("softbreak","br",0);for(o++;o=n)return!1;let i=e.src.charCodeAt(o);if(10===i){for(t||e.push("hardbreak","br",0),o++;o=55296&&i<=56319&&o+1=56320&&t<=57343&&(r+=e.src[o+1],o++)}const s="\\"+r;if(!t){const t=e.push("text_special","",0);i<256&&0!==ke[i]?t.content=r:t.content=s,t.markup=s,t.info="escape"}return e.pos=o+1,!0}],["backticks",function(e,t){let o=e.pos;if(96!==e.src.charCodeAt(o))return!1;const n=o;o++;const i=e.posMax;for(;o=u)return!1;if(l=p,i=e.md.helpers.parseLinkDestination(e.src,p,e.posMax),i.ok){for(s=e.md.normalizeLink(i.str),e.md.validateLink(s)?p=i.pos:s="",l=p;p=u||41!==e.src.charCodeAt(p))&&(c=!0),p++}if(c){if(void 0===e.env.references)return!1;if(p=0?n=e.src.slice(l,p++):p=m+1):p=m+1,n||(n=e.src.slice(h,m)),r=e.env.references[I(n)],!r)return e.pos=d,!1;s=r.href,a=r.title}if(!t){e.pos=h,e.posMax=m;const t=[["href",s]];e.push("link_open","a",1).attrs=t,a&&t.push(["title",a]),e.linkLevel++,e.md.inline.tokenize(e),e.linkLevel--,e.push("link_close","a",-1)}return e.pos=p,e.posMax=u,!0}],["image",function(e,t){let o,n,i,r,s,a,l,c,d="";const u=e.pos,h=e.posMax;if(33!==e.src.charCodeAt(e.pos))return!1;if(91!==e.src.charCodeAt(e.pos+1))return!1;const m=e.pos+2,p=e.md.helpers.parseLinkLabel(e,e.pos+1,!1);if(p<0)return!1;if(r=p+1,r=h)return!1;for(c=r,a=e.md.helpers.parseLinkDestination(e.src,r,e.posMax),a.ok&&(d=e.md.normalizeLink(a.str),e.md.validateLink(d)?r=a.pos:d=""),c=r;r=h||41!==e.src.charCodeAt(r))return e.pos=u,!1;r++}else{if(void 0===e.env.references)return!1;if(r=0?i=e.src.slice(c,r++):r=p+1):r=p+1,i||(i=e.src.slice(m,p)),s=e.env.references[I(i)],!s)return e.pos=u,!1;d=s.href,l=s.title}if(!t){n=e.src.slice(m,p);const t=[];e.md.inline.parse(n,e.md,e.env,t);const o=e.push("image","img",0),i=[["src",d],["alt",""]];o.attrs=i,o.children=t,o.content=n,l&&i.push(["title",l])}return e.pos=r,e.posMax=h,!0}],["autolink",function(e,t){let o=e.pos;if(60!==e.src.charCodeAt(o))return!1;const n=e.pos,i=e.posMax;for(;;){if(++o>=i)return!1;const t=e.src.charCodeAt(o);if(60===t)return!1;if(62===t)break}const r=e.src.slice(n+1,o);if(ve.test(r)){const o=e.md.normalizeLink(r);if(!e.md.validateLink(o))return!1;if(!t){const t=e.push("link_open","a",1);t.attrs=[["href",o]],t.markup="autolink",t.info="auto";e.push("text","",0).content=e.md.normalizeLinkText(r);const n=e.push("link_close","a",-1);n.markup="autolink",n.info="auto"}return e.pos+=r.length+2,!0}if(Ce.test(r)){const o=e.md.normalizeLink("mailto:"+r);if(!e.md.validateLink(o))return!1;if(!t){const t=e.push("link_open","a",1);t.attrs=[["href",o]],t.markup="autolink",t.info="auto";e.push("text","",0).content=e.md.normalizeLinkText(r);const n=e.push("link_close","a",-1);n.markup="autolink",n.info="auto"}return e.pos+=r.length+2,!0}return!1}],["html_inline",function(e,t){if(!e.md.options.html)return!1;const o=e.posMax,n=e.pos;if(60!==e.src.charCodeAt(n)||n+2>=o)return!1;const i=e.src.charCodeAt(n+1);if(33!==i&&63!==i&&47!==i&&!function(e){const t=32|e;return t>=97&&t<=122}(i))return!1;const r=e.src.slice(n).match(de);if(!r)return!1;if(!t){const t=e.push("html_inline","",0);t.content=r[0],s=t.content,/^\s]/i.test(s)&&e.linkLevel++,function(e){return/^<\/a\s*>/i.test(e)}(t.content)&&e.linkLevel--}var s;return e.pos+=r[0].length,!0}],["entity",function(e,t){const o=e.pos,n=e.posMax;if(38!==e.src.charCodeAt(o))return!1;if(o+1>=n)return!1;if(35===e.src.charCodeAt(o+1)){const n=e.src.slice(o).match(xe);if(n){if(!t){const t="x"===n[1][0].toLowerCase()?parseInt(n[1].slice(1),16):parseInt(n[1],10),o=e.push("text_special","",0);o.content=g(t)?f(t):f(65533),o.markup=n[0],o.info="entity"}return e.pos+=n[0].length,!0}}else{const n=e.src.slice(o).match(Ee);if(n){const o=r.decodeHTML(n[0]);if(o!==n[0]){if(!t){const t=e.push("text_special","",0);t.content=o,t.markup=n[0],t.info="entity"}return e.pos+=n[0].length,!0}}}return!1}]],Se=[["balance_pairs",function(e){const t=e.tokens_meta,o=e.tokens_meta.length;De(e.delimiters);for(let e=0;e0&&n++,"text"===i[t].type&&t+1=e.pos)throw new Error("inline rule didn't increment state.pos");break}}else e.pos=e.posMax;s||e.pos++,r[t]=e.pos},Te.prototype.tokenize=function(e){const t=this.ruler.getRules(""),o=t.length,n=e.posMax,i=e.md.options.maxNesting;for(;e.pos=e.pos)throw new Error("inline rule didn't increment state.pos");break}if(s){if(e.pos>=n)break}else e.pending+=e.src[e.pos++]}e.pending&&e.pushPending()},Te.prototype.parse=function(e,t,o,n){const i=new this.State(e,t,o,n);this.tokenize(i);const r=this.ruler2.getRules(""),s=r.length;for(let e=0;e=0))try{t.hostname=a.toASCII(t.hostname)}catch(e){}return c.encode(c.format(t))}function Ve(e){const t=c.parse(e,!0);if(t.hostname&&(!t.protocol||Re.indexOf(t.protocol)>=0))try{t.hostname=a.toUnicode(t.hostname)}catch(e){}return c.decode(c.format(t),c.decode.defaultChars+"%")}function Oe(e,t){if(!(this instanceof Oe))return new Oe(e,t);t||u(e)||(t=e||{},e="default"),this.inline=new Te,this.block=new pe,this.core=new oe,this.renderer=new z,this.linkify=new s,this.validateLink=Me,this.normalizeLink=ze,this.normalizeLinkText=Ve,this.utils=F,this.helpers=m({},M),this.options={},this.configure(e),t&&this.set(t)}Oe.prototype.set=function(e){return m(this.options,e),this},Oe.prototype.configure=function(e){const t=this;if(u(e)){const t=e;if(!(e=Ie[t]))throw new Error('Wrong `markdown-it` preset "'+t+'", check name')}if(!e)throw new Error("Wrong `markdown-it` preset, can't be empty");return e.options&&t.set(e.options),e.components&&Object.keys(e.components).forEach((function(o){e.components[o].rules&&t[o].ruler.enableOnly(e.components[o].rules),e.components[o].rules2&&t[o].ruler2.enableOnly(e.components[o].rules2)})),this},Oe.prototype.enable=function(e,t){let o=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach((function(t){o=o.concat(this[t].ruler.enable(e,!0))}),this),o=o.concat(this.inline.ruler2.enable(e,!0));const n=e.filter((function(e){return o.indexOf(e)<0}));if(n.length&&!t)throw new Error("MarkdownIt. Failed to enable unknown rule(s): "+n);return this},Oe.prototype.disable=function(e,t){let o=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach((function(t){o=o.concat(this[t].ruler.disable(e,!0))}),this),o=o.concat(this.inline.ruler2.disable(e,!0));const n=e.filter((function(e){return o.indexOf(e)<0}));if(n.length&&!t)throw new Error("MarkdownIt. Failed to disable unknown rule(s): "+n);return this},Oe.prototype.use=function(e){const t=[this].concat(Array.prototype.slice.call(arguments,1));return e.apply(e,t),this},Oe.prototype.parse=function(e,t){if("string"!=typeof e)throw new Error("Input data should be a String");const o=new this.core.State(e,this,t);return this.core.process(o),o.tokens},Oe.prototype.render=function(e,t){return t=t||{},this.renderer.render(this.parse(e,t),this.options,t)},Oe.prototype.parseInline=function(e,t){const o=new this.core.State(e,this,t);return o.inlineMode=!0,this.core.process(o),o.tokens},Oe.prototype.renderInline=function(e,t){return t=t||{},this.renderer.render(this.parseInline(e,t),this.options,t)},e.exports=Oe},5778:(e,t)=>{"use strict";const o={};function n(e,t){"string"!=typeof t&&(t=n.defaultChars);const i=function(e){let t=o[e];if(t)return t;t=o[e]=[];for(let e=0;e<128;e++){const o=String.fromCharCode(e);t.push(o)}for(let o=0;o=55296&&e<=57343?"���":String.fromCharCode(e),o+=6;continue}}if(240==(248&r)&&o+91114111?t+="����":(e-=65536,t+=String.fromCharCode(55296+(e>>10),56320+(1023&e))),o+=9;continue}}t+="�"}}return t}))}n.defaultChars=";/?:@&=+$,#",n.componentChars="";const i={};function r(e,t,o){"string"!=typeof t&&(o=t,t=r.defaultChars),void 0===o&&(o=!0);const n=function(e){let t=i[e];if(t)return t;t=i[e]=[];for(let e=0;e<128;e++){const o=String.fromCharCode(e);/^[0-9a-z]$/i.test(o)?t.push(o):t.push("%"+("0"+e.toString(16).toUpperCase()).slice(-2))}for(let o=0;o=55296&&r<=57343){if(r>=55296&&r<=56319&&t+1=56320&&o<=57343){s+=encodeURIComponent(e[t]+e[t+1]),t++;continue}}s+="%EF%BF%BD"}else s+=encodeURIComponent(e[t])}return s}function s(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}r.defaultChars=";/?:@&=+$,-_.!~*'()#",r.componentChars="-_.!~*'()";const a=/^([a-z0-9.+-]+:)/i,l=/:[0-9]*$/,c=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,d=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),u=["'"].concat(d),h=["%","/","?",";","#"].concat(u),m=["/","?","#"],p=/^[+a-z0-9A-Z_-]{0,63}$/,g=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,f={javascript:!0,"javascript:":!0},b={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};s.prototype.parse=function(e,t){let o,n,i,r=e;if(r=r.trim(),!t&&1===e.split("#").length){const e=c.exec(r);if(e)return this.pathname=e[1],e[2]&&(this.search=e[2]),this}let s=a.exec(r);if(s&&(s=s[0],o=s.toLowerCase(),this.protocol=s,r=r.substr(s.length)),(t||s||r.match(/^\/\/[^@\/]+@[^@\/]+/))&&(i="//"===r.substr(0,2),!i||s&&f[s]||(r=r.substr(2),this.slashes=!0)),!f[s]&&(i||s&&!b[s])){let e,t,o=-1;for(let e=0;e127?n+="x":n+=o[e];if(!n.match(p)){const n=e.slice(0,t),i=e.slice(t+1),s=o.match(g);s&&(n.push(s[1]),i.unshift(s[2])),i.length&&(r=i.join(".")+r),this.hostname=n.join(".");break}}}}this.hostname.length>255&&(this.hostname=""),s&&(this.hostname=this.hostname.substr(1,this.hostname.length-2))}const l=r.indexOf("#");-1!==l&&(this.hash=r.substr(l),r=r.slice(0,l));const d=r.indexOf("?");return-1!==d&&(this.search=r.substr(d),r=r.slice(0,d)),r&&(this.pathname=r),b[o]&&this.hostname&&!this.pathname&&(this.pathname=""),this},s.prototype.parseHost=function(e){let t=l.exec(e);t&&(t=t[0],":"!==t&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)},t.decode=n,t.encode=r,t.format=function(e){let t="";return t+=e.protocol||"",t+=e.slashes?"//":"",t+=e.auth?e.auth+"@":"",e.hostname&&-1!==e.hostname.indexOf(":")?t+="["+e.hostname+"]":t+=e.hostname||"",t+=e.port?":"+e.port:"",t+=e.pathname||"",t+=e.search||"",t+=e.hash||"",t},t.parse=function(e,t){if(e&&e instanceof s)return e;const o=new s;return o.parse(e,t),o}},7444:(e,t,o)=>{"use strict";o.r(t),o.d(t,{decode:()=>b,default:()=>y,encode:()=>k,toASCII:()=>_,toUnicode:()=>w,ucs2decode:()=>m,ucs2encode:()=>p});const n=2147483647,i=36,r=/^xn--/,s=/[^\0-\x7F]/,a=/[\x2E\u3002\uFF0E\uFF61]/g,l={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},c=Math.floor,d=String.fromCharCode;function u(e){throw new RangeError(l[e])}function h(e,t){const o=e.split("@");let n="";o.length>1&&(n=o[0]+"@",e=o[1]);const i=function(e,t){const o=[];let n=e.length;for(;n--;)o[n]=t(e[n]);return o}((e=e.replace(a,".")).split("."),t).join(".");return n+i}function m(e){const t=[];let o=0;const n=e.length;for(;o=55296&&i<=56319&&oString.fromCodePoint(...e),g=function(e,t){return e+22+75*(e<26)-((0!=t)<<5)},f=function(e,t,o){let n=0;for(e=o?c(e/700):e>>1,e+=c(e/t);e>455;n+=i)e=c(e/35);return c(n+36*e/(e+38))},b=function(e){const t=[],o=e.length;let r=0,s=128,a=72,l=e.lastIndexOf("-");l<0&&(l=0);for(let o=0;o=128&&u("not-basic"),t.push(e.charCodeAt(o));for(let h=l>0?l+1:0;h=o&&u("invalid-input");const l=(d=e.charCodeAt(h++))>=48&&d<58?d-48+26:d>=65&&d<91?d-65:d>=97&&d<123?d-97:i;l>=i&&u("invalid-input"),l>c((n-r)/t)&&u("overflow"),r+=l*t;const m=s<=a?1:s>=a+26?26:s-a;if(lc(n/p)&&u("overflow"),t*=p}const m=t.length+1;a=f(r-l,m,0==l),c(r/m)>n-s&&u("overflow"),s+=c(r/m),r%=m,t.splice(r++,0,s)}var d;return String.fromCodePoint(...t)},k=function(e){const t=[],o=(e=m(e)).length;let r=128,s=0,a=72;for(const o of e)o<128&&t.push(d(o));const l=t.length;let h=l;for(l&&t.push("-");h=r&&tc((n-s)/m)&&u("overflow"),s+=(o-r)*m,r=o;for(const o of e)if(on&&u("overflow"),o===r){let e=s;for(let o=i;;o+=i){const n=o<=a?1:o>=a+26?26:o-a;if(e{"use strict";var t=[];function o(e){for(var o=-1,n=0;n{"use strict";var t={};e.exports=function(e,o){var n=function(e){if(void 0===t[e]){var o=document.querySelector(e);if(window.HTMLIFrameElement&&o instanceof window.HTMLIFrameElement)try{o=o.contentDocument.head}catch(e){o=null}t[e]=o}return t[e]}(e);if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");n.appendChild(o)}},540:e=>{"use strict";e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},4868:e=>{"use strict";e.exports=function(e,t){Object.keys(t).forEach((function(o){e.setAttribute(o,t[o])}))}},4284:e=>{"use strict";var t,o=(t=[],function(e,o){return t[e]=o,t.filter(Boolean).join("\n")});function n(e,t,n,i){var r;if(n)r="";else{r="",i.supports&&(r+="@supports (".concat(i.supports,") {")),i.media&&(r+="@media ".concat(i.media," {"));var s=void 0!==i.layer;s&&(r+="@layer".concat(i.layer.length>0?" ".concat(i.layer):""," {")),r+=i.css,s&&(r+="}"),i.media&&(r+="}"),i.supports&&(r+="}")}if(e.styleSheet)e.styleSheet.cssText=o(t,r);else{var a=document.createTextNode(r),l=e.childNodes;l[t]&&e.removeChild(l[t]),l.length?e.insertBefore(a,l[t]):e.appendChild(a)}}var i={singleton:null,singletonCounter:0};e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=i.singletonCounter++,o=i.singleton||(i.singleton=e.insertStyleElement(e));return{update:function(e){n(o,t,!1,e)},remove:function(e){n(o,t,!0,e)}}}},3492:(e,t)=>{"use strict";t.Any=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,t.Cc=/[\0-\x1F\x7F-\x9F]/,t.Cf=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u0890\u0891\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD80D[\uDC30-\uDC3F]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/,t.P=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1B7D\u1B7E\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDEAD\uDF55-\uDF59\uDF86-\uDF89]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDC4B-\uDC4F\uDC5A\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDEB9\uDF3C-\uDF3E]|\uD806[\uDC3B\uDD44-\uDD46\uDDE2\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2\uDF00-\uDF09]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8\uDF43-\uDF4F\uDFFF]|\uD809[\uDC70-\uDC74]|\uD80B[\uDFF1\uDFF2]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDE97-\uDE9A\uDFE2]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD83A[\uDD5E\uDD5F]/,t.S=/[\$\+<->\^`\|~\xA2-\xA6\xA8\xA9\xAC\xAE-\xB1\xB4\xB8\xD7\xF7\u02C2-\u02C5\u02D2-\u02DF\u02E5-\u02EB\u02ED\u02EF-\u02FF\u0375\u0384\u0385\u03F6\u0482\u058D-\u058F\u0606-\u0608\u060B\u060E\u060F\u06DE\u06E9\u06FD\u06FE\u07F6\u07FE\u07FF\u0888\u09F2\u09F3\u09FA\u09FB\u0AF1\u0B70\u0BF3-\u0BFA\u0C7F\u0D4F\u0D79\u0E3F\u0F01-\u0F03\u0F13\u0F15-\u0F17\u0F1A-\u0F1F\u0F34\u0F36\u0F38\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE\u0FCF\u0FD5-\u0FD8\u109E\u109F\u1390-\u1399\u166D\u17DB\u1940\u19DE-\u19FF\u1B61-\u1B6A\u1B74-\u1B7C\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u2044\u2052\u207A-\u207C\u208A-\u208C\u20A0-\u20C0\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u214F\u218A\u218B\u2190-\u2307\u230C-\u2328\u232B-\u2426\u2440-\u244A\u249C-\u24E9\u2500-\u2767\u2794-\u27C4\u27C7-\u27E5\u27F0-\u2982\u2999-\u29D7\u29DC-\u29FB\u29FE-\u2B73\u2B76-\u2B95\u2B97-\u2BFF\u2CE5-\u2CEA\u2E50\u2E51\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3004\u3012\u3013\u3020\u3036\u3037\u303E\u303F\u309B\u309C\u3190\u3191\u3196-\u319F\u31C0-\u31E3\u31EF\u3200-\u321E\u322A-\u3247\u3250\u3260-\u327F\u328A-\u32B0\u32C0-\u33FF\u4DC0-\u4DFF\uA490-\uA4C6\uA700-\uA716\uA720\uA721\uA789\uA78A\uA828-\uA82B\uA836-\uA839\uAA77-\uAA79\uAB5B\uAB6A\uAB6B\uFB29\uFBB2-\uFBC2\uFD40-\uFD4F\uFDCF\uFDFC-\uFDFF\uFE62\uFE64-\uFE66\uFE69\uFF04\uFF0B\uFF1C-\uFF1E\uFF3E\uFF40\uFF5C\uFF5E\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFFC\uFFFD]|\uD800[\uDD37-\uDD3F\uDD79-\uDD89\uDD8C-\uDD8E\uDD90-\uDD9C\uDDA0\uDDD0-\uDDFC]|\uD802[\uDC77\uDC78\uDEC8]|\uD805\uDF3F|\uD807[\uDFD5-\uDFF1]|\uD81A[\uDF3C-\uDF3F\uDF45]|\uD82F\uDC9C|\uD833[\uDF50-\uDFC3]|\uD834[\uDC00-\uDCF5\uDD00-\uDD26\uDD29-\uDD64\uDD6A-\uDD6C\uDD83\uDD84\uDD8C-\uDDA9\uDDAE-\uDDEA\uDE00-\uDE41\uDE45\uDF00-\uDF56]|\uD835[\uDEC1\uDEDB\uDEFB\uDF15\uDF35\uDF4F\uDF6F\uDF89\uDFA9\uDFC3]|\uD836[\uDC00-\uDDFF\uDE37-\uDE3A\uDE6D-\uDE74\uDE76-\uDE83\uDE85\uDE86]|\uD838[\uDD4F\uDEFF]|\uD83B[\uDCAC\uDCB0\uDD2E\uDEF0\uDEF1]|\uD83C[\uDC00-\uDC2B\uDC30-\uDC93\uDCA0-\uDCAE\uDCB1-\uDCBF\uDCC1-\uDCCF\uDCD1-\uDCF5\uDD0D-\uDDAD\uDDE6-\uDE02\uDE10-\uDE3B\uDE40-\uDE48\uDE50\uDE51\uDE60-\uDE65\uDF00-\uDFFF]|\uD83D[\uDC00-\uDED7\uDEDC-\uDEEC\uDEF0-\uDEFC\uDF00-\uDF76\uDF7B-\uDFD9\uDFE0-\uDFEB\uDFF0]|\uD83E[\uDC00-\uDC0B\uDC10-\uDC47\uDC50-\uDC59\uDC60-\uDC87\uDC90-\uDCAD\uDCB0\uDCB1\uDD00-\uDE53\uDE60-\uDE6D\uDE70-\uDE7C\uDE80-\uDE88\uDE90-\uDEBD\uDEBF-\uDEC5\uDECE-\uDEDB\uDEE0-\uDEE8\uDEF0-\uDEF8\uDF00-\uDF92\uDF94-\uDFCA]/,t.Z=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/},2401:e=>{"use strict";e.exports="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAyMCI+PHBhdGggZmlsbD0iI2ZmZiIgZD0ibTExLjA3NyAxNSAuOTkxLTEuNDE2YS43NS43NSAwIDEgMSAxLjIyOS44NmwtMS4xNDggMS42NGEuNzUuNzUgMCAwIDEtLjIxNy4yMDYgNS4yNTEgNS4yNTEgMCAwIDEtOC41MDMtNS45NTUuNy43IDAgMCAxIC4xMi0uMjc0bDEuMTQ3LTEuNjM5YS43NS43NSAwIDEgMSAxLjIyOC44Nkw0LjkzMyAxMC43bC4wMDYuMDAzYTMuNzUgMy43NSAwIDAgMCA2LjEzMiA0LjI5NHptNS40OTQtNS4zMzVhLjc1Ljc1IDAgMCAxLS4xMi4yNzRsLTEuMTQ3IDEuNjM5YS43NS43NSAwIDEgMS0xLjIyOC0uODZsLjg2LTEuMjNhMy43NSAzLjc1IDAgMCAwLTYuMTQ0LTQuMzAxbC0uODYgMS4yMjlhLjc1Ljc1IDAgMCAxLTEuMjI5LS44NmwxLjE0OC0xLjY0YS43NS43NSAwIDAgMSAuMjE3LS4yMDYgNS4yNTEgNS4yNTEgMCAwIDEgOC41MDMgNS45NTVtLTQuNTYzLTIuNTMyYS43NS43NSAwIDAgMSAuMTg0IDEuMDQ1bC0zLjE1NSA0LjUwNWEuNzUuNzUgMCAxIDEtMS4yMjktLjg2bDMuMTU1LTQuNTA2YS43NS43NSAwIDAgMSAxLjA0NS0uMTg0Ii8+PC9zdmc+"}},n={};function i(e){var t=n[e];if(void 0!==t)return t.exports;var r=n[e]={id:e,exports:{}};return o[e].call(r.exports,r,r.exports,i),r.exports}i.m=o,i.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return i.d(t,{a:t}),t},t=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,i.t=function(o,n){if(1&n&&(o=this(o)),8&n)return o;if("object"==typeof o&&o){if(4&n&&o.__esModule)return o;if(16&n&&"function"==typeof o.then)return o}var r=Object.create(null);i.r(r);var s={};e=e||[null,t({}),t([]),t(t)];for(var a=2&n&&o;"object"==typeof a&&!~e.indexOf(a);a=t(a))Object.getOwnPropertyNames(a).forEach((e=>s[e]=()=>o[e]));return s.default=()=>o,i.d(r,s),r},i.d=(e,t)=>{for(var o in t)i.o(t,o)&&!i.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},i.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.b=document.baseURI||self.location.href;var r={};return(()=>{"use strict";let e;try{e={window,document}}catch(t){e={window:{},document:{}}}const t=e;function o(){try{return navigator.userAgent.toLowerCase()}catch(e){return""}}const n=o(),r={isMac:s(n),isWindows:a(n),isGecko:l(n),isSafari:c(n),isiOS:d(n),isAndroid:u(n),isBlink:h(n),get isMediaForcedColors(){return!!t.window.matchMedia&&t.window.matchMedia("(forced-colors: active)").matches},get isMotionReduced(){return!!t.window.matchMedia&&t.window.matchMedia("(prefers-reduced-motion)").matches},features:{isRegExpUnicodePropertySupported:m()}};function s(e){return e.indexOf("macintosh")>-1}function a(e){return e.indexOf("windows")>-1}function l(e){return!!e.match(/gecko\/\d+/)}function c(e){return e.indexOf(" applewebkit/")>-1&&-1===e.indexOf("chrome")}function d(e){return!!e.match(/iphone|ipad/i)||s(e)&&navigator.maxTouchPoints>0}function u(e){return e.indexOf("android")>-1}function h(e){return e.indexOf("chrome/")>-1&&e.indexOf("edge/")<0}function m(){let e=!1;try{e=0==="ć".search(new RegExp("[\\p{L}]","u"))}catch(e){}return e}function p(e,t,o,n){o=o||function(e,t){return e===t};const i=Array.isArray(e)?e:Array.prototype.slice.call(e),r=Array.isArray(t)?t:Array.prototype.slice.call(t),s=function(e,t,o){const n=g(e,t,o);if(-1===n)return{firstIndex:-1,lastIndexOld:-1,lastIndexNew:-1};const i=f(e,n),r=f(t,n),s=g(i,r,o),a=e.length-s,l=t.length-s;return{firstIndex:n,lastIndexOld:a,lastIndexNew:l}}(i,r,o),a=n?function(e,t){const{firstIndex:o,lastIndexOld:n,lastIndexNew:i}=e;if(-1===o)return Array(t).fill("equal");let r=[];o>0&&(r=r.concat(Array(o).fill("equal")));i-o>0&&(r=r.concat(Array(i-o).fill("insert")));n-o>0&&(r=r.concat(Array(n-o).fill("delete")));i0&&o.push({index:n,type:"insert",values:e.slice(n,r)});i-n>0&&o.push({index:n+(r-n),type:"delete",howMany:i-n});return o}(r,s);return a}function g(e,t,o){for(let n=0;n200||i>200||n+i>300)return b.fastDiff(e,t,o,!0);let r,s;if(ic?-1:1;d[n+h]&&(d[n]=d[n+h].slice(0)),d[n]||(d[n]=[]),d[n].push(i>c?r:s);let m=Math.max(i,c),p=m-n;for(;pc;m--)u[m]=h(m);u[c]=h(c),p++}while(u[c]!==l);return d[c].slice(1)}b.fastDiff=p;const k=function(){return function e(){e.called=!0}};class w{constructor(e,t){this.source=e,this.name=t,this.path=[],this.stop=k(),this.off=k()}}const y=new Array(256).fill("").map(((e,t)=>("0"+t.toString(16)).slice(-2)));function A(){const e=4294967296*Math.random()>>>0,t=4294967296*Math.random()>>>0,o=4294967296*Math.random()>>>0,n=4294967296*Math.random()>>>0;return"e"+y[e>>0&255]+y[e>>8&255]+y[e>>16&255]+y[e>>24&255]+y[t>>0&255]+y[t>>8&255]+y[t>>16&255]+y[t>>24&255]+y[o>>0&255]+y[o>>8&255]+y[o>>16&255]+y[o>>24&255]+y[n>>0&255]+y[n>>8&255]+y[n>>16&255]+y[n>>24&255]}const C={get(e="normal"){return"number"!=typeof e?this[e]||this.normal:e},highest:1e5,high:1e3,normal:0,low:-1e3,lowest:-1e5};function v(e,t){const o=C.get(t.priority);for(let n=0;n{if("object"==typeof t&&null!==t){if(o.has(t))return`[object ${t.constructor.name}]`;o.add(t)}return t},i=t?` ${JSON.stringify(t,n)}`:"",r=B(e);return e+i+r}(e,o)),this.name="CKEditorError",this.context=t,this.data=o}is(e){return"CKEditorError"===e}static rethrowUnexpectedError(e,t){if(e.is&&e.is("CKEditorError"))throw e;const o=new E(e.message,t);throw o.stack=e.stack,o}}function D(e,t){console.warn(...S(e,t))}function B(e){return`\nRead more: ${x}#error-${e}`}function S(e,t){const o=B(e);return t?[e,t,o]:[e,o]}const T="43.0.0",I=new Date(2024,7,7);if(globalThis.CKEDITOR_VERSION)throw new E("ckeditor-duplicated-modules",null);globalThis.CKEDITOR_VERSION=T;const P=Symbol("listeningTo"),F=Symbol("emitterId"),M=Symbol("delegations"),R=z(Object);function z(e){if(!e)return R;return class extends e{on(e,t,o){this.listenTo(this,e,t,o)}once(e,t,o){let n=!1;this.listenTo(this,e,((e,...o)=>{n||(n=!0,e.off(),t.call(this,e,...o))}),o)}off(e,t){this.stopListening(this,e,t)}listenTo(e,t,o,n={}){let i,r;this[P]||(this[P]={});const s=this[P];O(e)||V(e);const a=O(e);(i=s[a])||(i=s[a]={emitter:e,callbacks:{}}),(r=i.callbacks[t])||(r=i.callbacks[t]=[]),r.push(o),function(e,t,o,n,i){t._addEventListener?t._addEventListener(o,n,i):e._addEventListener.call(t,o,n,i)}(this,e,t,o,n)}stopListening(e,t,o){const n=this[P];let i=e&&O(e);const r=n&&i?n[i]:void 0,s=r&&t?r.callbacks[t]:void 0;if(!(!n||e&&!r||t&&!s))if(o){q(this,e,t,o);-1!==s.indexOf(o)&&(1===s.length?delete r.callbacks[t]:q(this,e,t,o))}else if(s){for(;o=s.pop();)q(this,e,t,o);delete r.callbacks[t]}else if(r){for(t in r.callbacks)this.stopListening(e,t);delete n[i]}else{for(i in n)this.stopListening(n[i].emitter);delete this[P]}}fire(e,...t){try{const o=e instanceof w?e:new w(this,e),n=o.name;let i=H(this,n);if(o.path.push(this),i){const e=[o,...t];i=Array.from(i);for(let t=0;t{this[M]||(this[M]=new Map),e.forEach((e=>{const n=this[M].get(e);n?n.set(t,o):this[M].set(e,new Map([[t,o]]))}))}}}stopDelegating(e,t){if(this[M])if(e)if(t){const o=this[M].get(e);o&&o.delete(t)}else this[M].delete(e);else this[M].clear()}_addEventListener(e,t,o){!function(e,t){const o=N(e);if(o[t])return;let n=t,i=null;const r=[];for(;""!==n&&!o[n];)o[n]={callbacks:[],childEvents:[]},r.push(o[n]),i&&o[n].childEvents.push(i),i=n,n=n.substr(0,n.lastIndexOf(":"));if(""!==n){for(const e of r)e.callbacks=o[n].callbacks.slice();o[n].childEvents.push(i)}}(this,e);const n=L(this,e),i={callback:t,priority:C.get(o.priority)};for(const e of n)v(e,i)}_removeEventListener(e,t){const o=L(this,e);for(const e of o)for(let o=0;o-1?H(e,t.substr(0,t.lastIndexOf(":"))):null}function j(e,t,o){for(let[n,i]of e){i?"function"==typeof i&&(i=i(t.name)):i=t.name;const e=new w(t.source,i);e.path=[...t.path],n.fire(e,...o)}}function q(e,t,o,n){t._removeEventListener?t._removeEventListener(o,n):e._removeEventListener.call(t,o,n)}["on","once","off","listenTo","stopListening","fire","delegate","stopDelegating","_addEventListener","_removeEventListener"].forEach((e=>{z[e]=R.prototype[e]}));const U=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)},W=Symbol("observableProperties"),$=Symbol("boundObservables"),G=Symbol("boundProperties"),K=Symbol("decoratedMethods"),Z=Symbol("decoratedOriginal"),J=Y(z());function Y(e){if(!e)return J;return class extends e{set(e,t){if(U(e))return void Object.keys(e).forEach((t=>{this.set(t,e[t])}),this);Q(this);const o=this[W];if(e in this&&!o.has(e))throw new E("observable-set-cannot-override",this);Object.defineProperty(this,e,{enumerable:!0,configurable:!0,get:()=>o.get(e),set(t){const n=o.get(e);let i=this.fire(`set:${e}`,e,t,n);void 0===i&&(i=t),n===i&&o.has(e)||(o.set(e,i),this.fire(`change:${e}`,e,i,n))}}),this[e]=t}bind(...e){if(!e.length||!te(e))throw new E("observable-bind-wrong-properties",this);if(new Set(e).size!==e.length)throw new E("observable-bind-duplicate-properties",this);Q(this);const t=this[G];e.forEach((e=>{if(t.has(e))throw new E("observable-bind-rebind",this)}));const o=new Map;return e.forEach((e=>{const n={property:e,to:[]};t.set(e,n),o.set(e,n)})),{to:X,toMany:ee,_observable:this,_bindProperties:e,_to:[],_bindings:o}}unbind(...e){if(!this[W])return;const t=this[G],o=this[$];if(e.length){if(!te(e))throw new E("observable-unbind-wrong-properties",this);e.forEach((e=>{const n=t.get(e);n&&(n.to.forEach((([e,t])=>{const i=o.get(e),r=i[t];r.delete(n),r.size||delete i[t],Object.keys(i).length||(o.delete(e),this.stopListening(e,"change"))})),t.delete(e))}))}else o.forEach(((e,t)=>{this.stopListening(t,"change")})),o.clear(),t.clear()}decorate(e){Q(this);const t=this[e];if(!t)throw new E("observablemixin-cannot-decorate-undefined",this,{object:this,methodName:e});this.on(e,((e,o)=>{e.return=t.apply(this,o)})),this[e]=function(...t){return this.fire(e,t)},this[e][Z]=t,this[K]||(this[K]=[]),this[K].push(e)}stopListening(e,t,o){if(!e&&this[K]){for(const e of this[K])this[e]=this[e][Z];delete this[K]}super.stopListening(e,t,o)}}}function Q(e){e[W]||(Object.defineProperty(e,W,{value:new Map}),Object.defineProperty(e,$,{value:new Map}),Object.defineProperty(e,G,{value:new Map}))}function X(...e){const t=function(...e){if(!e.length)throw new E("observable-bind-to-parse-error",null);const t={to:[]};let o;"function"==typeof e[e.length-1]&&(t.callback=e.pop());return e.forEach((e=>{if("string"==typeof e)o.properties.push(e);else{if("object"!=typeof e)throw new E("observable-bind-to-parse-error",null);o={observable:e,properties:[]},t.to.push(o)}})),t}(...e),o=Array.from(this._bindings.keys()),n=o.length;if(!t.callback&&t.to.length>1)throw new E("observable-bind-to-no-callback",this);if(n>1&&t.callback)throw new E("observable-bind-to-extra-callback",this);var i;t.to.forEach((e=>{if(e.properties.length&&e.properties.length!==n)throw new E("observable-bind-to-properties-length",this);e.properties.length||(e.properties=this._bindProperties)})),this._to=t.to,t.callback&&(this._bindings.get(o[0]).callback=t.callback),i=this._observable,this._to.forEach((e=>{const t=i[$];let o;t.get(e.observable)||i.listenTo(e.observable,"change",((n,r)=>{o=t.get(e.observable)[r],o&&o.forEach((e=>{oe(i,e.property)}))}))})),function(e){let t;e._bindings.forEach(((o,n)=>{e._to.forEach((i=>{t=i.properties[o.callback?0:e._bindProperties.indexOf(n)],o.to.push([i.observable,t]),function(e,t,o,n){const i=e[$],r=i.get(o),s=r||{};s[n]||(s[n]=new Set);s[n].add(t),r||i.set(o,s)}(e._observable,o,i.observable,t)}))}))}(this),this._bindProperties.forEach((e=>{oe(this._observable,e)}))}function ee(e,t,o){if(this._bindings.size>1)throw new E("observable-bind-to-many-not-one-binding",this);this.to(...function(e,t){const o=e.map((e=>[e,t]));return Array.prototype.concat.apply([],o)}(e,t),o)}function te(e){return e.every((e=>"string"==typeof e))}function oe(e,t){const o=e[G].get(t);let n;o.callback?n=o.callback.apply(e,o.to.map((e=>e[0][e[1]]))):(n=o.to[0],n=n[0][n[1]]),Object.prototype.hasOwnProperty.call(e,t)?e[t]=n:e.set(t,n)}function ne(e){let t=0;for(const o of e)t++;return t}function ie(e,t){const o=Math.min(e.length,t.length);for(let n=0;n{Y[e]=J.prototype[e]}));const se="object"==typeof global&&global&&global.Object===Object&&global;var ae="object"==typeof self&&self&&self.Object===Object&&self;const le=se||ae||Function("return this")();const ce=le.Symbol;var de=Object.prototype,ue=de.hasOwnProperty,he=de.toString,me=ce?ce.toStringTag:void 0;const pe=function(e){var t=ue.call(e,me),o=e[me];try{e[me]=void 0;var n=!0}catch(e){}var i=he.call(e);return n&&(t?e[me]=o:delete e[me]),i};var ge=Object.prototype.toString;const fe=function(e){return ge.call(e)};var be=ce?ce.toStringTag:void 0;const ke=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":be&&be in Object(e)?pe(e):fe(e)};const we=Array.isArray;const _e=function(e){return null!=e&&"object"==typeof e};const ye=function(e){return"string"==typeof e||!we(e)&&_e(e)&&"[object String]"==ke(e)};function Ae(e,t,o={},n=[]){const i=o&&o.xmlns,r=i?e.createElementNS(i,t):e.createElement(t);for(const e in o)r.setAttribute(e,o[e]);!ye(n)&&re(n)||(n=[n]);for(let t of n)ye(t)&&(t=e.createTextNode(t)),r.appendChild(t);return r}const Ce=function(e,t){return function(o){return e(t(o))}};const ve=Ce(Object.getPrototypeOf,Object);var xe=Function.prototype,Ee=Object.prototype,De=xe.toString,Be=Ee.hasOwnProperty,Se=De.call(Object);const Te=function(e){if(!_e(e)||"[object Object]"!=ke(e))return!1;var t=ve(e);if(null===t)return!0;var o=Be.call(t,"constructor")&&t.constructor;return"function"==typeof o&&o instanceof o&&De.call(o)==Se};const Ie=function(){this.__data__=[],this.size=0};const Pe=function(e,t){return e===t||e!=e&&t!=t};const Fe=function(e,t){for(var o=e.length;o--;)if(Pe(e[o][0],t))return o;return-1};var Me=Array.prototype.splice;const Re=function(e){var t=this.__data__,o=Fe(t,e);return!(o<0)&&(o==t.length-1?t.pop():Me.call(t,o,1),--this.size,!0)};const ze=function(e){var t=this.__data__,o=Fe(t,e);return o<0?void 0:t[o][1]};const Ve=function(e){return Fe(this.__data__,e)>-1};const Oe=function(e,t){var o=this.__data__,n=Fe(o,e);return n<0?(++this.size,o.push([e,t])):o[n][1]=t,this};function Ne(e){var t=-1,o=null==e?0:e.length;for(this.clear();++t-1&&e%1==0&&e-1&&e%1==0&&e<=9007199254740991};var Zt={};Zt["[object Float32Array]"]=Zt["[object Float64Array]"]=Zt["[object Int8Array]"]=Zt["[object Int16Array]"]=Zt["[object Int32Array]"]=Zt["[object Uint8Array]"]=Zt["[object Uint8ClampedArray]"]=Zt["[object Uint16Array]"]=Zt["[object Uint32Array]"]=!0,Zt["[object Arguments]"]=Zt["[object Array]"]=Zt["[object ArrayBuffer]"]=Zt["[object Boolean]"]=Zt["[object DataView]"]=Zt["[object Date]"]=Zt["[object Error]"]=Zt["[object Function]"]=Zt["[object Map]"]=Zt["[object Number]"]=Zt["[object Object]"]=Zt["[object RegExp]"]=Zt["[object Set]"]=Zt["[object String]"]=Zt["[object WeakMap]"]=!1;const Jt=function(e){return _e(e)&&Kt(e.length)&&!!Zt[ke(e)]};const Yt=function(e){return function(t){return e(t)}};var Qt="object"==typeof exports&&exports&&!exports.nodeType&&exports,Xt=Qt&&"object"==typeof module&&module&&!module.nodeType&&module,eo=Xt&&Xt.exports===Qt&&se.process;const to=function(){try{var e=Xt&&Xt.require&&Xt.require("util").types;return e||eo&&eo.binding&&eo.binding("util")}catch(e){}}();var oo=to&&to.isTypedArray;const no=oo?Yt(oo):Jt;var io=Object.prototype.hasOwnProperty;const ro=function(e,t){var o=we(e),n=!o&&Lt(e),i=!o&&!n&&Wt(e),r=!o&&!n&&!i&&no(e),s=o||n||i||r,a=s?Rt(e.length,String):[],l=a.length;for(var c in e)!t&&!io.call(e,c)||s&&("length"==c||i&&("offset"==c||"parent"==c)||r&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||Gt(c,l))||a.push(c);return a};var so=Object.prototype;const ao=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||so)};const lo=Ce(Object.keys,Object);var co=Object.prototype.hasOwnProperty;const uo=function(e){if(!ao(e))return lo(e);var t=[];for(var o in Object(e))co.call(e,o)&&"constructor"!=o&&t.push(o);return t};const ho=function(e){return null!=e&&Kt(e.length)&&!We(e)};const mo=function(e){return ho(e)?ro(e):uo(e)};const po=function(e,t){return e&&Mt(t,mo(t),e)};const go=function(e){var t=[];if(null!=e)for(var o in Object(e))t.push(o);return t};var fo=Object.prototype.hasOwnProperty;const bo=function(e){if(!U(e))return go(e);var t=ao(e),o=[];for(var n in e)("constructor"!=n||!t&&fo.call(e,n))&&o.push(n);return o};const ko=function(e){return ho(e)?ro(e,!0):bo(e)};const wo=function(e,t){return e&&Mt(t,ko(t),e)};var _o="object"==typeof exports&&exports&&!exports.nodeType&&exports,yo=_o&&"object"==typeof module&&module&&!module.nodeType&&module,Ao=yo&&yo.exports===_o?le.Buffer:void 0,Co=Ao?Ao.allocUnsafe:void 0;const vo=function(e,t){if(t)return e.slice();var o=e.length,n=Co?Co(o):new e.constructor(o);return e.copy(n),n};const xo=function(e,t){var o=-1,n=e.length;for(t||(t=Array(n));++o{this._setToTarget(e,n,t[n],o)}))}}function Tn(e){return Dn(e,In)}function In(e){return Bn(e)||"function"==typeof e?e:void 0}function Pn(e){if(e){if(e.defaultView)return e instanceof e.defaultView.Document;if(e.ownerDocument&&e.ownerDocument.defaultView)return e instanceof e.ownerDocument.defaultView.Node}return!1}function Fn(e){const t=Object.prototype.toString.apply(e);return"[object Window]"==t||"[object global]"==t}const Mn=Rn(z());function Rn(e){if(!e)return Mn;return class extends e{listenTo(e,t,o,n={}){if(Pn(e)||Fn(e)){const i={capture:!!n.useCapture,passive:!!n.usePassive},r=this._getProxyEmitter(e,i)||new zn(e,i);this.listenTo(r,t,o,n)}else super.listenTo(e,t,o,n)}stopListening(e,t,o){if(Pn(e)||Fn(e)){const n=this._getAllProxyEmitters(e);for(const e of n)this.stopListening(e,t,o)}else super.stopListening(e,t,o)}_getProxyEmitter(e,t){return function(e,t){const o=e[P];return o&&o[t]?o[t].emitter:null}(this,Vn(e,t))}_getAllProxyEmitters(e){return[{capture:!1,passive:!1},{capture:!1,passive:!0},{capture:!0,passive:!1},{capture:!0,passive:!0}].map((t=>this._getProxyEmitter(e,t))).filter((e=>!!e))}}}["_getProxyEmitter","_getAllProxyEmitters","on","once","off","listenTo","stopListening","fire","delegate","stopDelegating","_addEventListener","_removeEventListener"].forEach((e=>{Rn[e]=Mn.prototype[e]}));class zn extends(z()){constructor(e,t){super(),V(this,Vn(e,t)),this._domNode=e,this._options=t}attach(e){if(this._domListeners&&this._domListeners[e])return;const t=this._createDomListener(e);this._domNode.addEventListener(e,t,this._options),this._domListeners||(this._domListeners={}),this._domListeners[e]=t}detach(e){let t;!this._domListeners[e]||(t=this._events[e])&&t.callbacks.length||this._domListeners[e].removeListener()}_addEventListener(e,t,o){this.attach(e),z().prototype._addEventListener.call(this,e,t,o)}_removeEventListener(e,t){z().prototype._removeEventListener.call(this,e,t),this.detach(e)}_createDomListener(e){const t=t=>{this.fire(e,t)};return t.removeListener=()=>{this._domNode.removeEventListener(e,t,this._options),delete this._domListeners[e]},t}}function Vn(e,t){let o=function(e){return e["data-ck-expando"]||(e["data-ck-expando"]=A())}(e);for(const e of Object.keys(t).sort())t[e]&&(o+="-"+e);return o}function On(e){const t=e.ownerDocument.defaultView.getComputedStyle(e);return{top:parseInt(t.borderTopWidth,10),right:parseInt(t.borderRightWidth,10),bottom:parseInt(t.borderBottomWidth,10),left:parseInt(t.borderLeftWidth,10)}}function Nn(e){return"[object Text]"==Object.prototype.toString.call(e)}function Ln(e){return"[object Range]"==Object.prototype.toString.apply(e)}function Hn(e){return e&&e.parentNode?e.offsetParent===t.document.body?null:e.offsetParent:null}const jn=["top","right","bottom","left","width","height"];class qn{constructor(e){const t=Ln(e);if(Object.defineProperty(this,"_source",{value:e._source||e,writable:!0,enumerable:!1}),$n(e)||t)if(t){const t=qn.getDomRangeRects(e);Un(this,qn.getBoundingRect(t))}else Un(this,e.getBoundingClientRect());else if(Fn(e)){const{innerWidth:t,innerHeight:o}=e;Un(this,{top:0,right:t,bottom:o,left:0,width:t,height:o})}else Un(this,e)}clone(){return new qn(this)}moveTo(e,t){return this.top=t,this.right=e+this.width,this.bottom=t+this.height,this.left=e,this}moveBy(e,t){return this.top+=t,this.right+=e,this.left+=e,this.bottom+=t,this}getIntersection(e){const t={top:Math.max(this.top,e.top),right:Math.min(this.right,e.right),bottom:Math.min(this.bottom,e.bottom),left:Math.max(this.left,e.left),width:0,height:0};if(t.width=t.right-t.left,t.height=t.bottom-t.top,t.width<0||t.height<0)return null;{const e=new qn(t);return e._source=this._source,e}}getIntersectionArea(e){const t=this.getIntersection(e);return t?t.getArea():0}getArea(){return this.width*this.height}getVisible(){const e=this._source;let t=this.clone();if(Wn(e))return t;let o,n=e,i=e.parentNode||e.commonAncestorContainer;for(;i&&!Wn(i);){const e="visible"===((r=i)instanceof HTMLElement?r.ownerDocument.defaultView.getComputedStyle(r).overflow:"visible");n instanceof HTMLElement&&"absolute"===Gn(n)&&(o=n);const s=Gn(i);if(e||o&&("relative"===s&&e||"relative"!==s)){n=i,i=i.parentNode;continue}const a=new qn(i),l=t.getIntersection(a);if(!l)return null;l.getArea(){for(const t of e){const e=Kn._getElementCallbacks(t.target);if(e)for(const o of e)o(t)}}))}}Kn._observerInstance=null,Kn._elementCallbacks=null;const Zn=Kn;function Jn(e,t){e instanceof HTMLTextAreaElement&&(e.value=t),e.innerHTML=t}function Yn(e){return t=>t+e}function Qn(e){let t=0;for(;e.previousSibling;)e=e.previousSibling,t++;return t}function Xn(e,t,o){e.insertBefore(o,e.childNodes[t]||null)}function ei(e){return e&&e.nodeType===Node.COMMENT_NODE}function ti(e){return!!(e&&e.getClientRects&&e.getClientRects().length)}function oi({element:e,target:o,positions:n,limiter:i,fitInViewport:r,viewportOffsetConfig:s}){We(o)&&(o=o()),We(i)&&(i=i());const a=Hn(e),l=function(e){e=Object.assign({top:0,bottom:0,left:0,right:0},e);const o=new qn(t.window);return o.top+=e.top,o.height-=e.top,o.bottom-=e.bottom,o.height-=e.bottom,o}(s),c=new qn(e),d=ni(o,l);let u;if(!d||!l.getIntersection(d))return null;const h={targetRect:d,elementRect:c,positionedElementAncestor:a,viewportRect:l};if(i||r){if(i){const e=ni(i,l);e&&(h.limiterRect=e)}u=function(e,t){const{elementRect:o}=t,n=o.getArea(),i=e.map((e=>new ii(e,t))).filter((e=>!!e.name));let r=0,s=null;for(const e of i){const{limiterIntersectionArea:t,viewportIntersectionArea:o}=e;if(t===n)return e;const i=o**2+t**2;i>r&&(r=i,s=e)}return s}(n,h)}else u=new ii(n[0],h);return u}function ni(e,t){const o=new qn(e).getVisible();return o?o.getIntersection(t):null}class ii{constructor(e,t){const o=e(t.targetRect,t.elementRect,t.viewportRect,t.limiterRect);if(!o)return;const{left:n,top:i,name:r,config:s}=o;this.name=r,this.config=s,this._positioningFunctionCoordinates={left:n,top:i},this._options=t}get left(){return this._absoluteRect.left}get top(){return this._absoluteRect.top}get limiterIntersectionArea(){const e=this._options.limiterRect;return e?e.getIntersectionArea(this._rect):0}get viewportIntersectionArea(){return this._options.viewportRect.getIntersectionArea(this._rect)}get _rect(){return this._cachedRect||(this._cachedRect=this._options.elementRect.clone().moveTo(this._positioningFunctionCoordinates.left,this._positioningFunctionCoordinates.top)),this._cachedRect}get _absoluteRect(){return this._cachedAbsoluteRect||(this._cachedAbsoluteRect=this._rect.toAbsoluteRect()),this._cachedAbsoluteRect}}function ri(e){const t=e.parentNode;t&&t.removeChild(e)}function si({window:e,rect:t,alignToTop:o,forceScroll:n,viewportOffset:i}){const r=t.clone().moveBy(0,i.bottom),s=t.clone().moveBy(0,-i.top),a=new qn(e).excludeScrollbarsAndBorders(),l=o&&n,c=[s,r].every((e=>a.contains(e)));let{scrollX:d,scrollY:u}=e;const h=d,m=u;l?u-=a.top-t.top+i.top:c||(ci(s,a)?u-=a.top-t.top+i.top:li(r,a)&&(u+=o?t.top-a.top-i.top:t.bottom-a.bottom+i.bottom)),c||(di(t,a)?d-=a.left-t.left+i.left:ui(t,a)&&(d+=t.right-a.right+i.right)),d==h&&u===m||e.scrollTo(d,u)}function ai({parent:e,getRect:t,alignToTop:o,forceScroll:n,ancestorOffset:i=0,limiterElement:r}){const s=hi(e),a=o&&n;let l,c,d;const u=r||s.document.body;for(;e!=u;)c=t(),l=new qn(e).excludeScrollbarsAndBorders(),d=l.contains(c),a?e.scrollTop-=l.top-c.top+i:d||(ci(c,l)?e.scrollTop-=l.top-c.top+i:li(c,l)&&(e.scrollTop+=o?c.top-l.top-i:c.bottom-l.bottom+i)),d||(di(c,l)?e.scrollLeft-=l.left-c.left+i:ui(c,l)&&(e.scrollLeft+=c.right-l.right+i)),e=e.parentNode}function li(e,t){return e.bottom>t.bottom}function ci(e,t){return e.topt.right}function hi(e){return Ln(e)?e.startContainer.ownerDocument.defaultView:e.ownerDocument.defaultView}function mi(e){if(Ln(e)){let t=e.commonAncestorContainer;return Nn(t)&&(t=t.parentNode),t}return e.parentNode}function pi(e,t){const o=hi(e),n=new qn(e);if(o===t)return n;{let e=o;for(;e!=t;){const t=e.frameElement,o=new qn(t).excludeScrollbarsAndBorders();n.moveBy(o.left,o.top),e=e.parent}}return n}const gi={ctrl:"⌃",cmd:"⌘",alt:"⌥",shift:"⇧"},fi={ctrl:"Ctrl+",alt:"Alt+",shift:"Shift+"},bi={37:"←",38:"↑",39:"→",40:"↓",9:"⇥",33:"Page Up",34:"Page Down"},ki=vi(),wi=Object.fromEntries(Object.entries(ki).map((([e,t])=>{let o;return o=t in bi?bi[t]:e.charAt(0).toUpperCase()+e.slice(1),[t,o]})));function _i(e){let t;if("string"==typeof e){if(t=ki[e.toLowerCase()],!t)throw new E("keyboard-unknown-key",null,{key:e})}else t=e.keyCode+(e.altKey?ki.alt:0)+(e.ctrlKey?ki.ctrl:0)+(e.shiftKey?ki.shift:0)+(e.metaKey?ki.cmd:0);return t}function yi(e){return"string"==typeof e&&(e=function(e){return e.split("+").map((e=>e.trim()))}(e)),e.map((e=>"string"==typeof e?function(e){if(e.endsWith("!"))return _i(e.slice(0,-1));const t=_i(e);return(r.isMac||r.isiOS)&&t==ki.ctrl?ki.cmd:t}(e):e)).reduce(((e,t)=>t+e),0)}function Ai(e){let t=yi(e);return Object.entries(r.isMac||r.isiOS?gi:fi).reduce(((e,[o,n])=>(0!=(t&ki[o])&&(t&=~ki[o],e+=n),e)),"")+(t?wi[t]:"")}function Ci(e,t){const o="ltr"===t;switch(e){case ki.arrowleft:return o?"left":"right";case ki.arrowright:return o?"right":"left";case ki.arrowup:return"up";case ki.arrowdown:return"down"}}function vi(){const e={pageup:33,pagedown:34,arrowleft:37,arrowup:38,arrowright:39,arrowdown:40,backspace:8,delete:46,enter:13,space:32,esc:27,tab:9,ctrl:1114112,shift:2228224,alt:4456448,cmd:8912896};for(let t=65;t<=90;t++){e[String.fromCharCode(t).toLowerCase()]=t}for(let t=48;t<=57;t++)e[t-48]=t;for(let t=112;t<=123;t++)e["f"+(t-111)]=t;return Object.assign(e,{"'":222,",":108,"-":109,".":110,"/":111,";":186,"=":187,"[":219,"\\":220,"]":221,"`":223}),e}function xi(e){return Array.isArray(e)?e:[e]}const Ei=function(e,t,o){(void 0!==o&&!Pe(e[t],o)||void 0===o&&!(t in e))&&It(e,t,o)};const Di=function(e){return function(t,o,n){for(var i=-1,r=Object(t),s=n(t),a=s.length;a--;){var l=s[e?a:++i];if(!1===o(r[l],l,r))break}return t}}();const Bi=function(e){return _e(e)&&ho(e)};const Si=function(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]};const Ti=function(e){return Mt(e,ko(e))};const Ii=function(e,t,o,n,i,r,s){var a=Si(e,o),l=Si(t,o),c=s.get(l);if(c)Ei(e,o,c);else{var d=r?r(a,l,o+"",e,t,s):void 0,u=void 0===d;if(u){var h=we(l),m=!h&&Wt(l),p=!h&&!m&&no(l);d=l,h||m||p?we(a)?d=a:Bi(a)?d=xo(a):m?(u=!1,d=vo(l,!0)):p?(u=!1,d=un(l,!0)):d=[]:Te(l)||Lt(l)?(d=a,Lt(a)?d=Ti(a):U(a)&&!We(a)||(d=gn(l))):u=!1}u&&(s.set(l,d),i(d,l,n,r,s),s.delete(l)),Ei(e,o,d)}};const Pi=function e(t,o,n,i,r){t!==o&&Di(o,(function(s,a){if(r||(r=new Bt),U(s))Ii(t,o,a,n,e,i,r);else{var l=i?i(Si(t,a),s,a+"",t,o,r):void 0;void 0===l&&(l=s),Ei(t,a,l)}}),ko)};const Fi=function(e){return e};const Mi=function(e,t,o){switch(o.length){case 0:return e.call(t);case 1:return e.call(t,o[0]);case 2:return e.call(t,o[0],o[1]);case 3:return e.call(t,o[0],o[1],o[2])}return e.apply(t,o)};var Ri=Math.max;const zi=function(e,t,o){return t=Ri(void 0===t?e.length-1:t,0),function(){for(var n=arguments,i=-1,r=Ri(n.length-t,0),s=Array(r);++i0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}};const Hi=Li(Oi);const ji=function(e,t){return Hi(zi(e,t,Fi),e+"")};const qi=function(e,t,o){if(!U(o))return!1;var n=typeof t;return!!("number"==n?ho(o)&&Gt(t,o.length):"string"==n&&t in o)&&Pe(o[t],e)};const Ui=function(e){return ji((function(t,o){var n=-1,i=o.length,r=i>1?o[i-1]:void 0,s=i>2?o[2]:void 0;for(r=e.length>3&&"function"==typeof r?(i--,r):void 0,s&&qi(o[0],o[1],s)&&(r=i<3?void 0:r,i=1),t=Object(t);++n1===e?0:1),d=l[a];if("string"==typeof d)return d;return d[Number(c(n))]}t.window.CKEDITOR_TRANSLATIONS||(t.window.CKEDITOR_TRANSLATIONS={});const Ki=["ar","ara","dv","div","fa","per","fas","he","heb","ku","kur","ug","uig"];function Zi(e){return Ki.includes(e)?"rtl":"ltr"}class Ji{constructor({uiLanguage:e="en",contentLanguage:t,translations:o}={}){this.uiLanguage=e,this.contentLanguage=t||this.uiLanguage,this.uiLanguageDirection=Zi(this.uiLanguage),this.contentLanguageDirection=Zi(this.contentLanguage),this.translations=function(e){return Array.isArray(e)?e.reduce(((e,t)=>$i(e,t))):e}(o),this.t=(e,t)=>this._t(e,t)}get language(){return console.warn("locale-deprecated-language-property: The Locale#language property has been deprecated and will be removed in the near future. Please use #uiLanguage and #contentLanguage properties instead."),this.uiLanguage}_t(e,t=[]){t=xi(t),"string"==typeof e&&(e={string:e});const o=!!e.plural?t[0]:1;return function(e,t){return e.replace(/%(\d+)/g,((e,o)=>othis._items.length||t<0)throw new E("collection-add-item-invalid-index",this);let o=0;for(const n of e){const e=this._getItemIdBeforeAdding(n),i=t+o;this._items.splice(i,0,n),this._itemMap.set(e,n),this.fire("add",n,i),o++}return this.fire("change",{added:e,removed:[],index:t}),this}get(e){let t;if("string"==typeof e)t=this._itemMap.get(e);else{if("number"!=typeof e)throw new E("collection-get-invalid-arg",this);t=this._items[e]}return t||null}has(e){if("string"==typeof e)return this._itemMap.has(e);{const t=e[this._idProperty];return t&&this._itemMap.has(t)}}getIndex(e){let t;return t="string"==typeof e?this._itemMap.get(e):e,t?this._items.indexOf(t):-1}remove(e){const[t,o]=this._remove(e);return this.fire("change",{added:[],removed:[t],index:o}),t}map(e,t){return this._items.map(e,t)}forEach(e,t){this._items.forEach(e,t)}find(e,t){return this._items.find(e,t)}filter(e,t){return this._items.filter(e,t)}clear(){this._bindToCollection&&(this.stopListening(this._bindToCollection),this._bindToCollection=null);const e=Array.from(this._items);for(;this.length;)this._remove(0);this.fire("change",{added:[],removed:e,index:0})}bindTo(e){if(this._bindToCollection)throw new E("collection-bind-to-rebind",this);return this._bindToCollection=e,{as:e=>{this._setUpBindToBinding((t=>new e(t)))},using:e=>{"function"==typeof e?this._setUpBindToBinding(e):this._setUpBindToBinding((t=>t[e]))}}}_setUpBindToBinding(e){const t=this._bindToCollection,o=(o,n,i)=>{const r=t._bindToCollection==this,s=t._bindToInternalToExternalMap.get(n);if(r&&s)this._bindToExternalToInternalMap.set(n,s),this._bindToInternalToExternalMap.set(s,n);else{const o=e(n);if(!o)return void this._skippedIndexesFromExternal.push(i);let r=i;for(const e of this._skippedIndexesFromExternal)i>e&&r--;for(const e of t._skippedIndexesFromExternal)r>=e&&r++;this._bindToExternalToInternalMap.set(n,o),this._bindToInternalToExternalMap.set(o,n),this.add(o,r);for(let e=0;e{const n=this._bindToExternalToInternalMap.get(t);n&&this.remove(n),this._skippedIndexesFromExternal=this._skippedIndexesFromExternal.reduce(((e,t)=>(ot&&e.push(t),e)),[])}))}_getItemIdBeforeAdding(e){const t=this._idProperty;let o;if(t in e){if(o=e[t],"string"!=typeof o)throw new E("collection-add-invalid-id",this);if(this.get(o))throw new E("collection-add-item-already-exists",this)}else e[t]=o=A();return o}_remove(e){let t,o,n,i=!1;const r=this._idProperty;if("string"==typeof e?(o=e,n=this._itemMap.get(o),i=!n,n&&(t=this._items.indexOf(n))):"number"==typeof e?(t=e,n=this._items[t],i=!n,n&&(o=n[r])):(n=e,o=n[r],t=this._items.indexOf(n),i=-1==t||!this._itemMap.get(o)),i)throw new E("collection-remove-404",this);this._items.splice(t,1),this._itemMap.delete(o);const s=this._bindToInternalToExternalMap.get(n);return this._bindToInternalToExternalMap.delete(n),this._bindToExternalToInternalMap.delete(s),this.fire("remove",n,t),[n,t]}[Symbol.iterator](){return this._items[Symbol.iterator]()}}function Qi(e){const t=e.next();return t.done?null:t.value}class Xi extends(Rn(Y())){constructor(){super(),this._elements=new Set,this._nextEventLoopTimeout=null,this.set("isFocused",!1),this.set("focusedElement",null)}add(e){if(this._elements.has(e))throw new E("focustracker-add-element-already-exist",this);this.listenTo(e,"focus",(()=>this._focus(e)),{useCapture:!0}),this.listenTo(e,"blur",(()=>this._blur()),{useCapture:!0}),this._elements.add(e)}remove(e){e===this.focusedElement&&this._blur(),this._elements.has(e)&&(this.stopListening(e),this._elements.delete(e))}destroy(){this.stopListening()}_focus(e){clearTimeout(this._nextEventLoopTimeout),this.focusedElement=e,this.isFocused=!0}_blur(){clearTimeout(this._nextEventLoopTimeout),this._nextEventLoopTimeout=setTimeout((()=>{this.focusedElement=null,this.isFocused=!1}),0)}}class er{constructor(){this._listener=new(Rn())}listenTo(e){this._listener.listenTo(e,"keydown",((e,t)=>{this._listener.fire("_keydown:"+_i(t),t)}))}set(e,t,o={}){const n=yi(e),i=o.priority;this._listener.listenTo(this._listener,"_keydown:"+n,((e,n)=>{o.filter&&!o.filter(n)||(t(n,(()=>{n.preventDefault(),n.stopPropagation(),e.stop()})),e.return=!0)}),{priority:i})}press(e){return!!this._listener.fire("_keydown:"+_i(e),e)}stopListening(e){this._listener.stopListening(e)}destroy(){this.stopListening()}}function tr(e){return re(e)?new Map(e):function(e){const t=new Map;for(const o in e)t.set(o,e[o]);return t}(e)}function or(e,t){let o;function n(...i){n.cancel(),o=setTimeout((()=>e(...i)),t)}return n.cancel=()=>{clearTimeout(o)},n}function nr(e,t){return!!(o=e.charAt(t-1))&&1==o.length&&/[\ud800-\udbff]/.test(o)&&function(e){return!!e&&1==e.length&&/[\udc00-\udfff]/.test(e)}(e.charAt(t));var o}function ir(e,t){return!!(o=e.charAt(t))&&1==o.length&&/[\u0300-\u036f\u1ab0-\u1aff\u1dc0-\u1dff\u20d0-\u20ff\ufe20-\ufe2f]/.test(o);var o}const rr=ar();function sr(e,t){const o=String(e).matchAll(rr);return Array.from(o).some((e=>e.indexe.source)).join("|")+")";return new RegExp(`${e}|${t}(?:‍${t})*`,"ug")}class lr extends(Y()){constructor(e){super(),this._disableStack=new Set,this.editor=e,this.set("isEnabled",!0)}forceDisabled(e){this._disableStack.add(e),1==this._disableStack.size&&(this.on("set:isEnabled",cr,{priority:"highest"}),this.isEnabled=!1)}clearForceDisabled(e){this._disableStack.delete(e),0==this._disableStack.size&&(this.off("set:isEnabled",cr),this.isEnabled=!0)}destroy(){this.stopListening()}static get isContextPlugin(){return!1}}function cr(e){e.return=!1,e.stop()}class dr extends(Y()){constructor(e){super(),this.editor=e,this.set("value",void 0),this.set("isEnabled",!1),this._affectsData=!0,this._isEnabledBasedOnSelection=!0,this._disableStack=new Set,this.decorate("execute"),this.listenTo(this.editor.model.document,"change",(()=>{this.refresh()})),this.listenTo(e,"change:isReadOnly",(()=>{this.refresh()})),this.on("set:isEnabled",(t=>{if(!this.affectsData)return;const o=e.model.document.selection,n=!("$graveyard"==o.getFirstPosition().root.rootName)&&e.model.canEditAt(o);(e.isReadOnly||this._isEnabledBasedOnSelection&&!n)&&(t.return=!1,t.stop())}),{priority:"highest"}),this.on("execute",(e=>{this.isEnabled||e.stop()}),{priority:"high"})}get affectsData(){return this._affectsData}set affectsData(e){this._affectsData=e}refresh(){this.isEnabled=!0}forceDisabled(e){this._disableStack.add(e),1==this._disableStack.size&&(this.on("set:isEnabled",ur,{priority:"highest"}),this.isEnabled=!1)}clearForceDisabled(e){this._disableStack.delete(e),0==this._disableStack.size&&(this.off("set:isEnabled",ur),this.refresh())}execute(...e){}destroy(){this.stopListening()}}function ur(e){e.return=!1,e.stop()}class hr extends(z()){constructor(e,t=[],o=[]){super(),this._plugins=new Map,this._context=e,this._availablePlugins=new Map;for(const e of t)e.pluginName&&this._availablePlugins.set(e.pluginName,e);this._contextPlugins=new Map;for(const[e,t]of o)this._contextPlugins.set(e,t),this._contextPlugins.set(t,e),e.pluginName&&this._availablePlugins.set(e.pluginName,e)}*[Symbol.iterator](){for(const e of this._plugins)"function"==typeof e[0]&&(yield e)}get(e){const t=this._plugins.get(e);if(!t){let t=e;throw"function"==typeof e&&(t=e.pluginName||e.name),new E("plugincollection-plugin-not-loaded",this._context,{plugin:t})}return t}has(e){return this._plugins.has(e)}init(e,t=[],o=[]){const n=this,i=this._context;!function e(t,o=new Set){t.forEach((t=>{a(t)&&(o.has(t)||(o.add(t),t.pluginName&&!n._availablePlugins.has(t.pluginName)&&n._availablePlugins.set(t.pluginName,t),t.requires&&e(t.requires,o)))}))}(e),u(e);const r=[...function e(t,o=new Set){return t.map((e=>a(e)?e:n._availablePlugins.get(e))).reduce(((t,n)=>o.has(n)?t:(o.add(n),n.requires&&(u(n.requires,n),e(n.requires,o).forEach((e=>t.add(e)))),t.add(n))),new Set)}(e.filter((e=>!c(e,t))))];!function(e,t){for(const o of t){if("function"!=typeof o)throw new E("plugincollection-replace-plugin-invalid-type",null,{pluginItem:o});const t=o.pluginName;if(!t)throw new E("plugincollection-replace-plugin-missing-name",null,{pluginItem:o});if(o.requires&&o.requires.length)throw new E("plugincollection-plugin-for-replacing-cannot-have-dependencies",null,{pluginName:t});const i=n._availablePlugins.get(t);if(!i)throw new E("plugincollection-plugin-for-replacing-not-exist",null,{pluginName:t});const r=e.indexOf(i);if(-1===r){if(n._contextPlugins.has(i))return;throw new E("plugincollection-plugin-for-replacing-not-loaded",null,{pluginName:t})}if(i.requires&&i.requires.length)throw new E("plugincollection-replaced-plugin-cannot-have-dependencies",null,{pluginName:t});e.splice(r,1,o),n._availablePlugins.set(t,o)}}(r,o);const s=function(e){return e.map((e=>{let t=n._contextPlugins.get(e);return t=t||new e(i),n._add(e,t),t}))}(r);return h(s,"init").then((()=>h(s,"afterInit"))).then((()=>s));function a(e){return"function"==typeof e}function l(e){return a(e)&&!!e.isContextPlugin}function c(e,t){return t.some((t=>t===e||(d(e)===t||d(t)===e)))}function d(e){return a(e)?e.pluginName||e.name:e}function u(e,o=null){e.map((e=>a(e)?e:n._availablePlugins.get(e)||e)).forEach((e=>{!function(e,t){if(a(e))return;if(t)throw new E("plugincollection-soft-required",i,{missingPlugin:e,requiredBy:d(t)});throw new E("plugincollection-plugin-not-found",i,{plugin:e})}(e,o),function(e,t){if(!l(t))return;if(l(e))return;throw new E("plugincollection-context-required",i,{plugin:d(e),requiredBy:d(t)})}(e,o),function(e,o){if(!o)return;if(!c(e,t))return;throw new E("plugincollection-required",i,{plugin:d(e),requiredBy:d(o)})}(e,o)}))}function h(e,t){return e.reduce(((e,o)=>o[t]?n._contextPlugins.has(o)?e:e.then(o[t].bind(o)):e),Promise.resolve())}}destroy(){const e=[];for(const[,t]of this)"function"!=typeof t.destroy||this._contextPlugins.has(t)||e.push(t.destroy());return Promise.all(e)}_add(e,t){this._plugins.set(e,t);const o=e.pluginName;if(o){if(this._plugins.has(o))throw new E("plugincollection-plugin-name-conflict",null,{pluginName:o,plugin1:this._plugins.get(o).constructor,plugin2:e});this._plugins.set(o,t)}}}class mr{constructor(e){this._contextOwner=null;const{translations:t,...o}=e||{};this.config=new Sn(o,this.constructor.defaultConfig);const n=this.constructor.builtinPlugins;this.config.define("plugins",n),this.plugins=new hr(this,n);const i=this.config.get("language")||{};this.locale=new Ji({uiLanguage:"string"==typeof i?i:i.ui,contentLanguage:this.config.get("language.content"),translations:t}),this.t=this.locale.t,this.editors=new Yi}initPlugins(){const e=this.config.get("plugins")||[],t=this.config.get("substitutePlugins")||[];for(const o of e.concat(t)){if("function"!=typeof o)throw new E("context-initplugins-constructor-only",null,{Plugin:o});if(!0!==o.isContextPlugin)throw new E("context-initplugins-invalid-plugin",null,{Plugin:o})}return this.plugins.init(e,[],t)}destroy(){return Promise.all(Array.from(this.editors,(e=>e.destroy()))).then((()=>this.plugins.destroy()))}_addEditor(e,t){if(this._contextOwner)throw new E("context-addeditor-private-context");this.editors.add(e),t&&(this._contextOwner=e)}_removeEditor(e){return this.editors.has(e)&&this.editors.remove(e),this._contextOwner===e?this.destroy():Promise.resolve()}_getEditorConfig(){const e={};for(const t of this.config.names())["plugins","removePlugins","extraPlugins"].includes(t)||(e[t]=this.config.get(t));return e}static create(e){return new Promise((t=>{const o=new this(e);t(o.initPlugins().then((()=>o)))}))}}class pr extends(Y()){constructor(e){super(),this.context=e}destroy(){this.stopListening()}static get isContextPlugin(){return!0}}var gr=i(5072),fr=i.n(gr),br=i(4284),kr=i.n(br),wr=i(7659),_r=i.n(wr),yr=i(4868),Ar=i.n(yr),Cr=i(540),vr=i.n(Cr),xr=i(1111),Er={attributes:{"data-cke":!0}};Er.setAttributes=Ar(),Er.insert=_r().bind(null,"head"),Er.domAPI=kr(),Er.insertStyleElement=vr();fr()(xr.A,Er);xr.A&&xr.A.locals&&xr.A.locals;const Dr=new WeakMap;let Br=!1;function Sr({view:e,element:t,text:o,isDirectHost:n=!0,keepOnFocus:i=!1}){const r=e.document;function s(o){Dr.get(r).set(t,{text:o,isDirectHost:n,keepOnFocus:i,hostElement:n?t:null}),e.change((e=>Fr(r,e)))}Dr.has(r)||(Dr.set(r,new Map),r.registerPostFixer((e=>Fr(r,e))),r.on("change:isComposing",(()=>{e.change((e=>Fr(r,e)))}),{priority:"high"})),t.is("editableElement")&&t.on("change:placeholder",((e,t,o)=>{s(o)})),t.placeholder?s(t.placeholder):o&&s(o),o&&function(){Br||D("enableplaceholder-deprecated-text-option");Br=!0}()}function Tr(e,t){return!t.hasClass("ck-placeholder")&&(e.addClass("ck-placeholder",t),!0)}function Ir(e,t){return!!t.hasClass("ck-placeholder")&&(e.removeClass("ck-placeholder",t),!0)}function Pr(e,t){if(!e.isAttached())return!1;const o=Array.from(e.getChildren()).some((e=>!e.is("uiElement")));if(o)return!1;const n=e.document,i=n.selection.anchor;return(!n.isComposing||!i||i.parent!==e)&&(!!t||(!n.isFocused||!!i&&i.parent!==e))}function Fr(e,t){const o=Dr.get(e),n=[];let i=!1;for(const[e,r]of o)r.isDirectHost&&(n.push(e),Mr(t,e,r)&&(i=!0));for(const[e,r]of o){if(r.isDirectHost)continue;const o=Rr(e);o&&(n.includes(o)||(r.hostElement=o,Mr(t,e,r)&&(i=!0)))}return i}function Mr(e,t,o){const{text:n,isDirectHost:i,hostElement:r}=o;let s=!1;r.getAttribute("data-placeholder")!==n&&(e.setAttribute("data-placeholder",n,r),s=!0);return(i||1==t.childCount)&&Pr(r,o.keepOnFocus)?Tr(e,r)&&(s=!0):Ir(e,r)&&(s=!0),s}function Rr(e){if(e.childCount){const t=e.getChild(0);if(t.is("element")&&!t.is("uiElement")&&!t.is("attributeElement"))return t}return null}class zr{is(){throw new Error("is() method is abstract")}}const Vr=function(e){return En(e,4)};class Or extends(z(zr)){constructor(e){super(),this.document=e,this.parent=null}get index(){let e;if(!this.parent)return null;if(-1==(e=this.parent.getChildIndex(this)))throw new E("view-node-not-found-in-parent",this);return e}get nextSibling(){const e=this.index;return null!==e&&this.parent.getChild(e+1)||null}get previousSibling(){const e=this.index;return null!==e&&this.parent.getChild(e-1)||null}get root(){let e=this;for(;e.parent;)e=e.parent;return e}isAttached(){return this.root.is("rootElement")}getPath(){const e=[];let t=this;for(;t.parent;)e.unshift(t.index),t=t.parent;return e}getAncestors(e={}){const t=[];let o=e.includeSelf?this:this.parent;for(;o;)t[e.parentFirst?"push":"unshift"](o),o=o.parent;return t}getCommonAncestor(e,t={}){const o=this.getAncestors(t),n=e.getAncestors(t);let i=0;for(;o[i]==n[i]&&o[i];)i++;return 0===i?null:o[i-1]}isBefore(e){if(this==e)return!1;if(this.root!==e.root)return!1;const t=this.getPath(),o=e.getPath(),n=ie(t,o);switch(n){case"prefix":return!0;case"extension":return!1;default:return t[n]e.data.length)throw new E("view-textproxy-wrong-offsetintext",this);if(o<0||t+o>e.data.length)throw new E("view-textproxy-wrong-length",this);this.data=e.data.substring(t,t+o),this.offsetInText=t}get offsetSize(){return this.data.length}get isPartial(){return this.data.length!==this.textNode.data.length}get parent(){return this.textNode.parent}get root(){return this.textNode.root}get document(){return this.textNode.document}getAncestors(e={}){const t=[];let o=e.includeSelf?this.textNode:this.parent;for(;null!==o;)t[e.parentFirst?"push":"unshift"](o),o=o.parent;return t}}Lr.prototype.is=function(e){return"$textProxy"===e||"view:$textProxy"===e||"textProxy"===e||"view:textProxy"===e};class Hr{constructor(...e){this._patterns=[],this.add(...e)}add(...e){for(let t of e)("string"==typeof t||t instanceof RegExp)&&(t={name:t}),this._patterns.push(t)}match(...e){for(const t of e)for(const e of this._patterns){const o=jr(t,e);if(o)return{element:t,pattern:e,match:o}}return null}matchAll(...e){const t=[];for(const o of e)for(const e of this._patterns){const n=jr(o,e);n&&t.push({element:o,pattern:e,match:n})}return t.length>0?t:null}getElementName(){if(1!==this._patterns.length)return null;const e=this._patterns[0],t=e.name;return"function"==typeof e||!t||t instanceof RegExp?null:t}}function jr(e,t){if("function"==typeof t)return t(e);const o={};return t.name&&(o.name=function(e,t){if(e instanceof RegExp)return!!t.match(e);return e===t}(t.name,e.name),!o.name)||t.attributes&&(o.attributes=function(e,t){const o=new Set(t.getAttributeKeys());Te(e)?(void 0!==e.style&&D("matcher-pattern-deprecated-attributes-style-key",e),void 0!==e.class&&D("matcher-pattern-deprecated-attributes-class-key",e)):(o.delete("style"),o.delete("class"));return qr(e,o,(e=>t.getAttribute(e)))}(t.attributes,e),!o.attributes)||t.classes&&(o.classes=function(e,t){return qr(e,t.getClassNames(),(()=>{}))}(t.classes,e),!o.classes)||t.styles&&(o.styles=function(e,t){return qr(e,t.getStyleNames(!0),(e=>t.getStyle(e)))}(t.styles,e),!o.styles)?null:o}function qr(e,t,o){const n=function(e){if(Array.isArray(e))return e.map((e=>Te(e)?(void 0!==e.key&&void 0!==e.value||D("matcher-pattern-missing-key-or-value",e),[e.key,e.value]):[e,!0]));if(Te(e))return Object.entries(e);return[[e,!0]]}(e),i=Array.from(t),r=[];if(n.forEach((([e,t])=>{i.forEach((n=>{(function(e,t){return!0===e||e===t||e instanceof RegExp&&t.match(e)})(e,n)&&function(e,t,o){if(!0===e)return!0;const n=o(t);return e===n||e instanceof RegExp&&!!String(n).match(e)}(t,n,o)&&r.push(n)}))})),n.length&&!(r.lengthi?0:i+t),(o=o>i?i:o)<0&&(o+=i),i=t>o?0:o-t>>>0,t>>>=0;for(var r=Array(i);++nt===e));return Array.isArray(t)}set(e,t){if(U(e))for(const[t,o]of Object.entries(e))this._styleProcessor.toNormalizedForm(t,o,this._styles);else this._styleProcessor.toNormalizedForm(e,t,this._styles)}remove(e){const t=ws(e);ms(this._styles,t),delete this._styles[e],this._cleanEmptyObjectsOnPath(t)}getNormalized(e){return this._styleProcessor.getNormalized(e,this._styles)}toString(){return this.isEmpty?"":this.getStylesEntries().map((e=>e.join(":"))).sort().join(";")+";"}getAsString(e){if(this.isEmpty)return;if(this._styles[e]&&!U(this._styles[e]))return this._styles[e];const t=this._styleProcessor.getReducedForm(e,this._styles).find((([t])=>t===e));return Array.isArray(t)?t[1]:void 0}getStyleNames(e=!1){if(this.isEmpty)return[];if(e)return this._styleProcessor.getStyleNames(this._styles);return this.getStylesEntries().map((([e])=>e))}clear(){this._styles={}}getStylesEntries(){const e=[],t=Object.keys(this._styles);for(const o of t)e.push(...this._styleProcessor.getReducedForm(o,this._styles));return e}_cleanEmptyObjectsOnPath(e){const t=e.split(".");if(!(t.length>1))return;const o=t.splice(0,t.length-1).join("."),n=ps(this._styles,o);if(!n)return;!Object.keys(n).length&&this.remove(o)}}class ks{constructor(){this._normalizers=new Map,this._extractors=new Map,this._reducers=new Map,this._consumables=new Map}toNormalizedForm(e,t,o){if(U(t))_s(o,ws(e),t);else if(this._normalizers.has(e)){const n=this._normalizers.get(e),{path:i,value:r}=n(t);_s(o,i,r)}else _s(o,e,t)}getNormalized(e,t){if(!e)return $i({},t);if(void 0!==t[e])return t[e];if(this._extractors.has(e)){const o=this._extractors.get(e);if("string"==typeof o)return ps(t,o);const n=o(e,t);if(n)return n}return ps(t,ws(e))}getReducedForm(e,t){const o=this.getNormalized(e,t);if(void 0===o)return[];if(this._reducers.has(e)){return this._reducers.get(e)(o)}return[[e,o]]}getStyleNames(e){const t=Array.from(this._consumables.keys()).filter((t=>{const o=this.getNormalized(t,e);return o&&"object"==typeof o?Object.keys(o).length:o})),o=new Set([...t,...Object.keys(e)]);return Array.from(o)}getRelatedStyles(e){return this._consumables.get(e)||[]}setNormalizer(e,t){this._normalizers.set(e,t)}setExtractor(e,t){this._extractors.set(e,t)}setReducer(e,t){this._reducers.set(e,t)}setStyleRelation(e,t){this._mapStyleNames(e,t);for(const o of t)this._mapStyleNames(o,[e])}_mapStyleNames(e,t){this._consumables.has(e)||this._consumables.set(e,[]),this._consumables.get(e).push(...t)}}function ws(e){return e.replace("-",".")}function _s(e,t,o){let n=o;U(o)&&(n=$i({},ps(e,t),o)),fs(e,t,n)}class ys extends Or{constructor(e,t,o,n){if(super(e),this._unsafeAttributesToRender=[],this._customProperties=new Map,this.name=t,this._attrs=function(e){const t=tr(e);for(const[e,o]of t)null===o?t.delete(e):"string"!=typeof o&&t.set(e,String(o));return t}(o),this._children=[],n&&this._insertChild(0,n),this._classes=new Set,this._attrs.has("class")){const e=this._attrs.get("class");As(this._classes,e),this._attrs.delete("class")}this._styles=new bs(this.document.stylesProcessor),this._attrs.has("style")&&(this._styles.setTo(this._attrs.get("style")),this._attrs.delete("style"))}get childCount(){return this._children.length}get isEmpty(){return 0===this._children.length}getChild(e){return this._children[e]}getChildIndex(e){return this._children.indexOf(e)}getChildren(){return this._children[Symbol.iterator]()}*getAttributeKeys(){this._classes.size>0&&(yield"class"),this._styles.isEmpty||(yield"style"),yield*this._attrs.keys()}*getAttributes(){yield*this._attrs.entries(),this._classes.size>0&&(yield["class",this.getAttribute("class")]),this._styles.isEmpty||(yield["style",this.getAttribute("style")])}getAttribute(e){if("class"==e)return this._classes.size>0?[...this._classes].join(" "):void 0;if("style"==e){const e=this._styles.toString();return""==e?void 0:e}return this._attrs.get(e)}hasAttribute(e){return"class"==e?this._classes.size>0:"style"==e?!this._styles.isEmpty:this._attrs.has(e)}isSimilar(e){if(!(e instanceof ys))return!1;if(this===e)return!0;if(this.name!=e.name)return!1;if(this._attrs.size!==e._attrs.size||this._classes.size!==e._classes.size||this._styles.size!==e._styles.size)return!1;for(const[t,o]of this._attrs)if(!e._attrs.has(t)||e._attrs.get(t)!==o)return!1;for(const t of this._classes)if(!e._classes.has(t))return!1;for(const t of this._styles.getStyleNames())if(!e._styles.has(t)||e._styles.getAsString(t)!==this._styles.getAsString(t))return!1;return!0}hasClass(...e){for(const t of e)if(!this._classes.has(t))return!1;return!0}getClassNames(){return this._classes.keys()}getStyle(e){return this._styles.getAsString(e)}getNormalizedStyle(e){return this._styles.getNormalized(e)}getStyleNames(e){return this._styles.getStyleNames(e)}hasStyle(...e){for(const t of e)if(!this._styles.has(t))return!1;return!0}findAncestor(...e){const t=new Hr(...e);let o=this.parent;for(;o&&!o.is("documentFragment");){if(t.match(o))return o;o=o.parent}return null}getCustomProperty(e){return this._customProperties.get(e)}*getCustomProperties(){yield*this._customProperties.entries()}getIdentity(){const e=Array.from(this._classes).sort().join(","),t=this._styles.toString(),o=Array.from(this._attrs).map((e=>`${e[0]}="${e[1]}"`)).sort().join(" ");return this.name+(""==e?"":` class="${e}"`)+(t?` style="${t}"`:"")+(""==o?"":` ${o}`)}shouldRenderUnsafeAttribute(e){return this._unsafeAttributesToRender.includes(e)}_clone(e=!1){const t=[];if(e)for(const o of this.getChildren())t.push(o._clone(e));const o=new this.constructor(this.document,this.name,this._attrs,t);return o._classes=new Set(this._classes),o._styles.set(this._styles.getNormalized()),o._customProperties=new Map(this._customProperties),o.getFillerOffset=this.getFillerOffset,o._unsafeAttributesToRender=this._unsafeAttributesToRender,o}_appendChild(e){return this._insertChild(this.childCount,e)}_insertChild(e,t){this._fireChange("children",this);let o=0;const n=function(e,t){if("string"==typeof t)return[new Nr(e,t)];re(t)||(t=[t]);return Array.from(t).map((t=>"string"==typeof t?new Nr(e,t):t instanceof Lr?new Nr(e,t.data):t))}(this.document,t);for(const t of n)null!==t.parent&&t._remove(),t.parent=this,t.document=this.document,this._children.splice(e,0,t),e++,o++;return o}_removeChildren(e,t=1){this._fireChange("children",this);for(let o=e;o0&&(this._classes.clear(),!0):"style"==e?!this._styles.isEmpty&&(this._styles.clear(),!0):this._attrs.delete(e)}_addClass(e){this._fireChange("attributes",this);for(const t of xi(e))this._classes.add(t)}_removeClass(e){this._fireChange("attributes",this);for(const t of xi(e))this._classes.delete(t)}_setStyle(e,t){this._fireChange("attributes",this),"string"!=typeof e?this._styles.set(e):this._styles.set(e,t)}_removeStyle(e){this._fireChange("attributes",this);for(const t of xi(e))this._styles.remove(t)}_setCustomProperty(e,t){this._customProperties.set(e,t)}_removeCustomProperty(e){return this._customProperties.delete(e)}}function As(e,t){const o=t.split(/\s+/);e.clear(),o.forEach((t=>e.add(t)))}ys.prototype.is=function(e,t){return t?t===this.name&&("element"===e||"view:element"===e):"element"===e||"view:element"===e||"node"===e||"view:node"===e};class Cs extends ys{constructor(e,t,o,n){super(e,t,o,n),this.getFillerOffset=vs}}function vs(){const e=[...this.getChildren()],t=e[this.childCount-1];if(t&&t.is("element","br"))return this.childCount;for(const t of e)if(!t.is("uiElement"))return null;return this.childCount}Cs.prototype.is=function(e,t){return t?t===this.name&&("containerElement"===e||"view:containerElement"===e||"element"===e||"view:element"===e):"containerElement"===e||"view:containerElement"===e||"element"===e||"view:element"===e||"node"===e||"view:node"===e};class xs extends(Y(Cs)){constructor(e,t,o,n){super(e,t,o,n),this.set("isReadOnly",!1),this.set("isFocused",!1),this.set("placeholder",void 0),this.bind("isReadOnly").to(e),this.bind("isFocused").to(e,"isFocused",(t=>t&&e.selection.editableElement==this)),this.listenTo(e.selection,"change",(()=>{this.isFocused=e.isFocused&&e.selection.editableElement==this}))}destroy(){this.stopListening()}}xs.prototype.is=function(e,t){return t?t===this.name&&("editableElement"===e||"view:editableElement"===e||"containerElement"===e||"view:containerElement"===e||"element"===e||"view:element"===e):"editableElement"===e||"view:editableElement"===e||"containerElement"===e||"view:containerElement"===e||"element"===e||"view:element"===e||"node"===e||"view:node"===e};const Es=Symbol("rootName");class Ds extends xs{constructor(e,t){super(e,t),this.rootName="main"}get rootName(){return this.getCustomProperty(Es)}set rootName(e){this._setCustomProperty(Es,e)}set _name(e){this.name=e}}Ds.prototype.is=function(e,t){return t?t===this.name&&("rootElement"===e||"view:rootElement"===e||"editableElement"===e||"view:editableElement"===e||"containerElement"===e||"view:containerElement"===e||"element"===e||"view:element"===e):"rootElement"===e||"view:rootElement"===e||"editableElement"===e||"view:editableElement"===e||"containerElement"===e||"view:containerElement"===e||"element"===e||"view:element"===e||"node"===e||"view:node"===e};class Bs{constructor(e={}){if(!e.boundaries&&!e.startPosition)throw new E("view-tree-walker-no-start-position",null);if(e.direction&&"forward"!=e.direction&&"backward"!=e.direction)throw new E("view-tree-walker-unknown-direction",e.startPosition,{direction:e.direction});this.boundaries=e.boundaries||null,e.startPosition?this._position=Ss._createAt(e.startPosition):this._position=Ss._createAt(e.boundaries["backward"==e.direction?"end":"start"]),this.direction=e.direction||"forward",this.singleCharacters=!!e.singleCharacters,this.shallow=!!e.shallow,this.ignoreElementEnd=!!e.ignoreElementEnd,this._boundaryStartParent=this.boundaries?this.boundaries.start.parent:null,this._boundaryEndParent=this.boundaries?this.boundaries.end.parent:null}[Symbol.iterator](){return this}get position(){return this._position}skip(e){let t,o;do{o=this.position,t=this.next()}while(!t.done&&e(t.value));t.done||(this._position=o)}next(){return"forward"==this.direction?this._next():this._previous()}_next(){let e=this.position.clone();const t=this.position,o=e.parent;if(null===o.parent&&e.offset===o.childCount)return{done:!0,value:void 0};if(o===this._boundaryEndParent&&e.offset==this.boundaries.end.offset)return{done:!0,value:void 0};let n;if(o instanceof Nr){if(e.isAtEnd)return this._position=Ss._createAfter(o),this._next();n=o.data[e.offset]}else n=o.getChild(e.offset);if(n instanceof ys){if(this.shallow){if(this.boundaries&&this.boundaries.end.isBefore(e))return{done:!0,value:void 0};e.offset++}else e=new Ss(n,0);return this._position=e,this._formatReturnValue("elementStart",n,t,e,1)}if(n instanceof Nr){if(this.singleCharacters)return e=new Ss(n,0),this._position=e,this._next();let o,i=n.data.length;return n==this._boundaryEndParent?(i=this.boundaries.end.offset,o=new Lr(n,0,i),e=Ss._createAfter(o)):(o=new Lr(n,0,n.data.length),e.offset++),this._position=e,this._formatReturnValue("text",o,t,e,i)}if("string"==typeof n){let n;if(this.singleCharacters)n=1;else{n=(o===this._boundaryEndParent?this.boundaries.end.offset:o.data.length)-e.offset}const i=new Lr(o,e.offset,n);return e.offset+=n,this._position=e,this._formatReturnValue("text",i,t,e,n)}return e=Ss._createAfter(o),this._position=e,this.ignoreElementEnd?this._next():this._formatReturnValue("elementEnd",o,t,e)}_previous(){let e=this.position.clone();const t=this.position,o=e.parent;if(null===o.parent&&0===e.offset)return{done:!0,value:void 0};if(o==this._boundaryStartParent&&e.offset==this.boundaries.start.offset)return{done:!0,value:void 0};let n;if(o instanceof Nr){if(e.isAtStart)return this._position=Ss._createBefore(o),this._previous();n=o.data[e.offset-1]}else n=o.getChild(e.offset-1);if(n instanceof ys)return this.shallow?(e.offset--,this._position=e,this._formatReturnValue("elementStart",n,t,e,1)):(e=new Ss(n,n.childCount),this._position=e,this.ignoreElementEnd?this._previous():this._formatReturnValue("elementEnd",n,t,e));if(n instanceof Nr){if(this.singleCharacters)return e=new Ss(n,n.data.length),this._position=e,this._previous();let o,i=n.data.length;if(n==this._boundaryStartParent){const t=this.boundaries.start.offset;o=new Lr(n,t,n.data.length-t),i=o.data.length,e=Ss._createBefore(o)}else o=new Lr(n,0,n.data.length),e.offset--;return this._position=e,this._formatReturnValue("text",o,t,e,i)}if("string"==typeof n){let n;if(this.singleCharacters)n=1;else{const t=o===this._boundaryStartParent?this.boundaries.start.offset:0;n=e.offset-t}e.offset-=n;const i=new Lr(o,e.offset,n);return this._position=e,this._formatReturnValue("text",i,t,e,n)}return e=Ss._createBefore(o),this._position=e,this._formatReturnValue("elementStart",o,t,e,1)}_formatReturnValue(e,t,o,n,i){return t instanceof Lr&&(t.offsetInText+t.data.length==t.textNode.data.length&&("forward"!=this.direction||this.boundaries&&this.boundaries.end.isEqual(this.position)?o=Ss._createAfter(t.textNode):(n=Ss._createAfter(t.textNode),this._position=n)),0===t.offsetInText&&("backward"!=this.direction||this.boundaries&&this.boundaries.start.isEqual(this.position)?o=Ss._createBefore(t.textNode):(n=Ss._createBefore(t.textNode),this._position=n))),{done:!1,value:{type:e,item:t,previousPosition:o,nextPosition:n,length:i}}}}class Ss extends zr{constructor(e,t){super(),this.parent=e,this.offset=t}get nodeAfter(){return this.parent.is("$text")?null:this.parent.getChild(this.offset)||null}get nodeBefore(){return this.parent.is("$text")?null:this.parent.getChild(this.offset-1)||null}get isAtStart(){return 0===this.offset}get isAtEnd(){const e=this.parent.is("$text")?this.parent.data.length:this.parent.childCount;return this.offset===e}get root(){return this.parent.root}get editableElement(){let e=this.parent;for(;!(e instanceof xs);){if(!e.parent)return null;e=e.parent}return e}getShiftedBy(e){const t=Ss._createAt(this),o=t.offset+e;return t.offset=o<0?0:o,t}getLastMatchingPosition(e,t={}){t.startPosition=this;const o=new Bs(t);return o.skip(e),o.position}getAncestors(){return this.parent.is("documentFragment")?[this.parent]:this.parent.getAncestors({includeSelf:!0})}getCommonAncestor(e){const t=this.getAncestors(),o=e.getAncestors();let n=0;for(;t[n]==o[n]&&t[n];)n++;return 0===n?null:t[n-1]}isEqual(e){return this.parent==e.parent&&this.offset==e.offset}isBefore(e){return"before"==this.compareWith(e)}isAfter(e){return"after"==this.compareWith(e)}compareWith(e){if(this.root!==e.root)return"different";if(this.isEqual(e))return"same";const t=this.parent.is("node")?this.parent.getPath():[],o=e.parent.is("node")?e.parent.getPath():[];t.push(this.offset),o.push(e.offset);const n=ie(t,o);switch(n){case"prefix":return"before";case"extension":return"after";default:return t[n]0?new this(o,n):new this(n,o)}static _createIn(e){return this._createFromParentsAndOffsets(e,0,e,e.childCount)}static _createOn(e){const t=e.is("$textProxy")?e.offsetSize:1;return this._createFromPositionAndShift(Ss._createBefore(e),t)}}function Is(e){return!(!e.item.is("attributeElement")&&!e.item.is("uiElement"))}Ts.prototype.is=function(e){return"range"===e||"view:range"===e};class Ps extends(z(zr)){constructor(...e){super(),this._ranges=[],this._lastRangeBackward=!1,this._isFake=!1,this._fakeSelectionLabel="",e.length&&this.setTo(...e)}get isFake(){return this._isFake}get fakeSelectionLabel(){return this._fakeSelectionLabel}get anchor(){if(!this._ranges.length)return null;const e=this._ranges[this._ranges.length-1];return(this._lastRangeBackward?e.end:e.start).clone()}get focus(){if(!this._ranges.length)return null;const e=this._ranges[this._ranges.length-1];return(this._lastRangeBackward?e.start:e.end).clone()}get isCollapsed(){return 1===this.rangeCount&&this._ranges[0].isCollapsed}get rangeCount(){return this._ranges.length}get isBackward(){return!this.isCollapsed&&this._lastRangeBackward}get editableElement(){return this.anchor?this.anchor.editableElement:null}*getRanges(){for(const e of this._ranges)yield e.clone()}getFirstRange(){let e=null;for(const t of this._ranges)e&&!t.start.isBefore(e.start)||(e=t);return e?e.clone():null}getLastRange(){let e=null;for(const t of this._ranges)e&&!t.end.isAfter(e.end)||(e=t);return e?e.clone():null}getFirstPosition(){const e=this.getFirstRange();return e?e.start.clone():null}getLastPosition(){const e=this.getLastRange();return e?e.end.clone():null}isEqual(e){if(this.isFake!=e.isFake)return!1;if(this.isFake&&this.fakeSelectionLabel!=e.fakeSelectionLabel)return!1;if(this.rangeCount!=e.rangeCount)return!1;if(0===this.rangeCount)return!0;if(!this.anchor.isEqual(e.anchor)||!this.focus.isEqual(e.focus))return!1;for(const t of this._ranges){let o=!1;for(const n of e._ranges)if(t.isEqual(n)){o=!0;break}if(!o)return!1}return!0}isSimilar(e){if(this.isBackward!=e.isBackward)return!1;const t=ne(this.getRanges());if(t!=ne(e.getRanges()))return!1;if(0==t)return!0;for(let t of this.getRanges()){t=t.getTrimmed();let o=!1;for(let n of e.getRanges())if(n=n.getTrimmed(),t.start.isEqual(n.start)&&t.end.isEqual(n.end)){o=!0;break}if(!o)return!1}return!0}getSelectedElement(){return 1!==this.rangeCount?null:this.getFirstRange().getContainedElement()}setTo(...e){let[t,o,n]=e;if("object"==typeof o&&(n=o,o=void 0),null===t)this._setRanges([]),this._setFakeOptions(n);else if(t instanceof Ps||t instanceof Fs)this._setRanges(t.getRanges(),t.isBackward),this._setFakeOptions({fake:t.isFake,label:t.fakeSelectionLabel});else if(t instanceof Ts)this._setRanges([t],n&&n.backward),this._setFakeOptions(n);else if(t instanceof Ss)this._setRanges([new Ts(t)]),this._setFakeOptions(n);else if(t instanceof Or){const e=!!n&&!!n.backward;let i;if(void 0===o)throw new E("view-selection-setto-required-second-parameter",this);i="in"==o?Ts._createIn(t):"on"==o?Ts._createOn(t):new Ts(Ss._createAt(t,o)),this._setRanges([i],e),this._setFakeOptions(n)}else{if(!re(t))throw new E("view-selection-setto-not-selectable",this);this._setRanges(t,n&&n.backward),this._setFakeOptions(n)}this.fire("change")}setFocus(e,t){if(null===this.anchor)throw new E("view-selection-setfocus-no-ranges",this);const o=Ss._createAt(e,t);if("same"==o.compareWith(this.focus))return;const n=this.anchor;this._ranges.pop(),"before"==o.compareWith(n)?this._addRange(new Ts(o,n),!0):this._addRange(new Ts(n,o)),this.fire("change")}_setRanges(e,t=!1){e=Array.from(e),this._ranges=[];for(const t of e)this._addRange(t);this._lastRangeBackward=!!t}_setFakeOptions(e={}){this._isFake=!!e.fake,this._fakeSelectionLabel=e.fake&&e.label||""}_addRange(e,t=!1){if(!(e instanceof Ts))throw new E("view-selection-add-range-not-range",this);this._pushRange(e),this._lastRangeBackward=!!t}_pushRange(e){for(const t of this._ranges)if(e.isIntersecting(t))throw new E("view-selection-range-intersects",this,{addedRange:e,intersectingRange:t});this._ranges.push(new Ts(e.start,e.end))}}Ps.prototype.is=function(e){return"selection"===e||"view:selection"===e};class Fs extends(z(zr)){constructor(...e){super(),this._selection=new Ps,this._selection.delegate("change").to(this),e.length&&this._selection.setTo(...e)}get isFake(){return this._selection.isFake}get fakeSelectionLabel(){return this._selection.fakeSelectionLabel}get anchor(){return this._selection.anchor}get focus(){return this._selection.focus}get isCollapsed(){return this._selection.isCollapsed}get rangeCount(){return this._selection.rangeCount}get isBackward(){return this._selection.isBackward}get editableElement(){return this._selection.editableElement}get _ranges(){return this._selection._ranges}*getRanges(){yield*this._selection.getRanges()}getFirstRange(){return this._selection.getFirstRange()}getLastRange(){return this._selection.getLastRange()}getFirstPosition(){return this._selection.getFirstPosition()}getLastPosition(){return this._selection.getLastPosition()}getSelectedElement(){return this._selection.getSelectedElement()}isEqual(e){return this._selection.isEqual(e)}isSimilar(e){return this._selection.isSimilar(e)}_setTo(...e){this._selection.setTo(...e)}_setFocus(e,t){this._selection.setFocus(e,t)}}Fs.prototype.is=function(e){return"selection"===e||"documentSelection"==e||"view:selection"==e||"view:documentSelection"==e};class Ms extends w{constructor(e,t,o){super(e,t),this.startRange=o,this._eventPhase="none",this._currentTarget=null}get eventPhase(){return this._eventPhase}get currentTarget(){return this._currentTarget}}const Rs=Symbol("bubbling contexts");function zs(e){return class extends e{fire(e,...t){try{const o=e instanceof w?e:new w(this,e),n=Ls(this);if(!n.size)return;if(Vs(o,"capturing",this),Os(n,"$capture",o,...t))return o.return;const i=o.startRange||this.selection.getFirstRange(),r=i?i.getContainedElement():null,s=!!r&&Boolean(Ns(n,r));let a=r||function(e){if(!e)return null;const t=e.start.parent,o=e.end.parent,n=t.getPath(),i=o.getPath();return n.length>i.length?t:o}(i);if(Vs(o,"atTarget",a),!s){if(Os(n,"$text",o,...t))return o.return;Vs(o,"bubbling",a)}for(;a;){if(a.is("rootElement")){if(Os(n,"$root",o,...t))return o.return}else if(a.is("element")&&Os(n,a.name,o,...t))return o.return;if(Os(n,a,o,...t))return o.return;a=a.parent,Vs(o,"bubbling",a)}return Vs(o,"bubbling",this),Os(n,"$document",o,...t),o.return}catch(e){E.rethrowUnexpectedError(e,this)}}_addEventListener(e,t,o){const n=xi(o.context||"$document"),i=Ls(this);for(const r of n){let n=i.get(r);n||(n=new(z()),i.set(r,n)),this.listenTo(n,e,t,o)}}_removeEventListener(e,t){const o=Ls(this);for(const n of o.values())this.stopListening(n,e,t)}}}{const e=zs(Object);["fire","_addEventListener","_removeEventListener"].forEach((t=>{zs[t]=e.prototype[t]}))}function Vs(e,t,o){e instanceof Ms&&(e._eventPhase=t,e._currentTarget=o)}function Os(e,t,o,...n){const i="string"==typeof t?e.get(t):Ns(e,t);return!!i&&(i.fire(o,...n),o.stop.called)}function Ns(e,t){for(const[o,n]of e)if("function"==typeof o&&o(t))return n;return null}function Ls(e){return e[Rs]||(e[Rs]=new Map),e[Rs]}class Hs extends(zs(Y())){constructor(e){super(),this._postFixers=new Set,this.selection=new Fs,this.roots=new Yi({idProperty:"rootName"}),this.stylesProcessor=e,this.set("isReadOnly",!1),this.set("isFocused",!1),this.set("isSelecting",!1),this.set("isComposing",!1)}getRoot(e="main"){return this.roots.get(e)}registerPostFixer(e){this._postFixers.add(e)}destroy(){this.roots.forEach((e=>e.destroy())),this.stopListening()}_callPostFixers(e){let t=!1;do{for(const o of this._postFixers)if(t=o(e),t)break}while(t)}}class js extends ys{constructor(e,t,o,n){super(e,t,o,n),this._priority=10,this._id=null,this._clonesGroup=null,this.getFillerOffset=Us}get priority(){return this._priority}get id(){return this._id}getElementsWithSameId(){if(null===this.id)throw new E("attribute-element-get-elements-with-same-id-no-id",this);return new Set(this._clonesGroup)}isSimilar(e){return null!==this.id||null!==e.id?this.id===e.id:super.isSimilar(e)&&this.priority==e.priority}_clone(e=!1){const t=super._clone(e);return t._priority=this._priority,t._id=this._id,t}}js.DEFAULT_PRIORITY=10;const qs=js;function Us(){if(Ws(this))return null;let e=this.parent;for(;e&&e.is("attributeElement");){if(Ws(e)>1)return null;e=e.parent}return!e||Ws(e)>1?null:this.childCount}function Ws(e){return Array.from(e.getChildren()).filter((e=>!e.is("uiElement"))).length}js.prototype.is=function(e,t){return t?t===this.name&&("attributeElement"===e||"view:attributeElement"===e||"element"===e||"view:element"===e):"attributeElement"===e||"view:attributeElement"===e||"element"===e||"view:element"===e||"node"===e||"view:node"===e};class $s extends ys{constructor(e,t,o,n){super(e,t,o,n),this.getFillerOffset=Gs}_insertChild(e,t){if(t&&(t instanceof Or||Array.from(t).length>0))throw new E("view-emptyelement-cannot-add",[this,t]);return 0}}function Gs(){return null}$s.prototype.is=function(e,t){return t?t===this.name&&("emptyElement"===e||"view:emptyElement"===e||"element"===e||"view:element"===e):"emptyElement"===e||"view:emptyElement"===e||"element"===e||"view:element"===e||"node"===e||"view:node"===e};class Ks extends ys{constructor(e,t,o,n){super(e,t,o,n),this.getFillerOffset=Js}_insertChild(e,t){if(t&&(t instanceof Or||Array.from(t).length>0))throw new E("view-uielement-cannot-add",[this,t]);return 0}render(e,t){return this.toDomElement(e)}toDomElement(e){const t=e.createElement(this.name);for(const e of this.getAttributeKeys())t.setAttribute(e,this.getAttribute(e));return t}}function Zs(e){e.document.on("arrowKey",((t,o)=>function(e,t,o){if(t.keyCode==ki.arrowright){const e=t.domTarget.ownerDocument.defaultView.getSelection(),n=1==e.rangeCount&&e.getRangeAt(0).collapsed;if(n||t.shiftKey){const t=e.focusNode,i=e.focusOffset,r=o.domPositionToView(t,i);if(null===r)return;let s=!1;const a=r.getLastMatchingPosition((e=>(e.item.is("uiElement")&&(s=!0),!(!e.item.is("uiElement")&&!e.item.is("attributeElement")))));if(s){const t=o.viewPositionToDom(a);n?e.collapse(t.parent,t.offset):e.extend(t.parent,t.offset)}}}}(0,o,e.domConverter)),{priority:"low"})}function Js(){return null}Ks.prototype.is=function(e,t){return t?t===this.name&&("uiElement"===e||"view:uiElement"===e||"element"===e||"view:element"===e):"uiElement"===e||"view:uiElement"===e||"element"===e||"view:element"===e||"node"===e||"view:node"===e};class Ys extends ys{constructor(e,t,o,n){super(e,t,o,n),this.getFillerOffset=Qs}_insertChild(e,t){if(t&&(t instanceof Or||Array.from(t).length>0))throw new E("view-rawelement-cannot-add",[this,t]);return 0}render(e,t){}}function Qs(){return null}Ys.prototype.is=function(e,t){return t?t===this.name&&("rawElement"===e||"view:rawElement"===e||"element"===e||"view:element"===e):"rawElement"===e||"view:rawElement"===e||e===this.name||e==="view:"+this.name||"element"===e||"view:element"===e||"node"===e||"view:node"===e};class Xs extends(z(zr)){constructor(e,t){super(),this._children=[],this._customProperties=new Map,this.document=e,t&&this._insertChild(0,t)}[Symbol.iterator](){return this._children[Symbol.iterator]()}get childCount(){return this._children.length}get isEmpty(){return 0===this.childCount}get root(){return this}get parent(){return null}get name(){}get getFillerOffset(){}getCustomProperty(e){return this._customProperties.get(e)}*getCustomProperties(){yield*this._customProperties.entries()}_appendChild(e){return this._insertChild(this.childCount,e)}getChild(e){return this._children[e]}getChildIndex(e){return this._children.indexOf(e)}getChildren(){return this._children[Symbol.iterator]()}_insertChild(e,t){this._fireChange("children",this);let o=0;const n=function(e,t){if("string"==typeof t)return[new Nr(e,t)];re(t)||(t=[t]);return Array.from(t).map((t=>"string"==typeof t?new Nr(e,t):t instanceof Lr?new Nr(e,t.data):t))}(this.document,t);for(const t of n)null!==t.parent&&t._remove(),t.parent=this,this._children.splice(e,0,t),e++,o++;return o}_removeChildren(e,t=1){this._fireChange("children",this);for(let o=e;o{const o=e[e.length-1],n=!t.is("uiElement");return o&&o.breakAttributes==n?o.nodes.push(t):e.push({breakAttributes:n,nodes:[t]}),e}),[]);let n=null,i=e;for(const{nodes:e,breakAttributes:t}of o){const o=this._insertNodes(i,e,t);n||(n=o.start),i=o.end}return n?new Ts(n,i):new Ts(e)}remove(e){const t=e instanceof Ts?e:Ts._createOn(e);if(ca(t,this.document),t.isCollapsed)return new Xs(this.document);const{start:o,end:n}=this._breakAttributesRange(t,!0),i=o.parent,r=n.offset-o.offset,s=i._removeChildren(o.offset,r);for(const e of s)this._removeFromClonedElementsGroup(e);const a=this.mergeAttributes(o);return t.start=a,t.end=a.clone(),new Xs(this.document,s)}clear(e,t){ca(e,this.document);const o=e.getWalker({direction:"backward",ignoreElementEnd:!0});for(const n of o){const o=n.item;let i;if(o.is("element")&&t.isSimilar(o))i=Ts._createOn(o);else if(!n.nextPosition.isAfter(e.start)&&o.is("$textProxy")){const e=o.getAncestors().find((e=>e.is("element")&&t.isSimilar(e)));e&&(i=Ts._createIn(e))}i&&(i.end.isAfter(e.end)&&(i.end=e.end),i.start.isBefore(e.start)&&(i.start=e.start),this.remove(i))}}move(e,t){let o;if(t.isAfter(e.end)){const n=(t=this._breakAttributes(t,!0)).parent,i=n.childCount;e=this._breakAttributesRange(e,!0),o=this.remove(e),t.offset+=n.childCount-i}else o=this.remove(e);return this.insert(t,o)}wrap(e,t){if(!(t instanceof qs))throw new E("view-writer-wrap-invalid-attribute",this.document);if(ca(e,this.document),e.isCollapsed){let n=e.start;n.parent.is("element")&&(o=n.parent,!Array.from(o.getChildren()).some((e=>!e.is("uiElement"))))&&(n=n.getLastMatchingPosition((e=>e.item.is("uiElement")))),n=this._wrapPosition(n,t);const i=this.document.selection;return i.isCollapsed&&i.getFirstPosition().isEqual(e.start)&&this.setSelection(n),new Ts(n)}return this._wrapRange(e,t);var o}unwrap(e,t){if(!(t instanceof qs))throw new E("view-writer-unwrap-invalid-attribute",this.document);if(ca(e,this.document),e.isCollapsed)return e;const{start:o,end:n}=this._breakAttributesRange(e,!0),i=o.parent,r=this._unwrapChildren(i,o.offset,n.offset,t),s=this.mergeAttributes(r.start);s.isEqual(r.start)||r.end.offset--;const a=this.mergeAttributes(r.end);return new Ts(s,a)}rename(e,t){const o=new Cs(this.document,e,t.getAttributes());return this.insert(Ss._createAfter(t),o),this.move(Ts._createIn(t),Ss._createAt(o,0)),this.remove(Ts._createOn(t)),o}clearClonedElementsGroup(e){this._cloneGroups.delete(e)}createPositionAt(e,t){return Ss._createAt(e,t)}createPositionAfter(e){return Ss._createAfter(e)}createPositionBefore(e){return Ss._createBefore(e)}createRange(e,t){return new Ts(e,t)}createRangeOn(e){return Ts._createOn(e)}createRangeIn(e){return Ts._createIn(e)}createSelection(...e){return new Ps(...e)}createSlot(e="children"){if(!this._slotFactory)throw new E("view-writer-invalid-create-slot-context",this.document);return this._slotFactory(this,e)}_registerSlotFactory(e){this._slotFactory=e}_clearSlotFactory(){this._slotFactory=null}_insertNodes(e,t,o){let n,i;if(n=o?ta(e):e.parent.is("$text")?e.parent.parent:e.parent,!n)throw new E("view-writer-invalid-position-container",this.document);i=o?this._breakAttributes(e,!0):e.parent.is("$text")?ia(e):e;const r=n._insertChild(i.offset,t);for(const e of t)this._addToClonedElementsGroup(e);const s=i.getShiftedBy(r),a=this.mergeAttributes(i);a.isEqual(i)||s.offset--;const l=this.mergeAttributes(s);return new Ts(a,l)}_wrapChildren(e,t,o,n){let i=t;const r=[];for(;i!1,e.parent._insertChild(e.offset,o);const n=new Ts(e,e.getShiftedBy(1));this.wrap(n,t);const i=new Ss(o.parent,o.index);o._remove();const r=i.nodeBefore,s=i.nodeAfter;return r instanceof Nr&&s instanceof Nr?ra(r,s):na(i)}_wrapAttributeElement(e,t){if(!da(e,t))return!1;if(e.name!==t.name||e.priority!==t.priority)return!1;for(const o of e.getAttributeKeys())if("class"!==o&&"style"!==o&&t.hasAttribute(o)&&t.getAttribute(o)!==e.getAttribute(o))return!1;for(const o of e.getStyleNames())if(t.hasStyle(o)&&t.getStyle(o)!==e.getStyle(o))return!1;for(const o of e.getAttributeKeys())"class"!==o&&"style"!==o&&(t.hasAttribute(o)||this.setAttribute(o,e.getAttribute(o),t));for(const o of e.getStyleNames())t.hasStyle(o)||this.setStyle(o,e.getStyle(o),t);for(const o of e.getClassNames())t.hasClass(o)||this.addClass(o,t);return!0}_unwrapAttributeElement(e,t){if(!da(e,t))return!1;if(e.name!==t.name||e.priority!==t.priority)return!1;for(const o of e.getAttributeKeys())if("class"!==o&&"style"!==o&&(!t.hasAttribute(o)||t.getAttribute(o)!==e.getAttribute(o)))return!1;if(!t.hasClass(...e.getClassNames()))return!1;for(const o of e.getStyleNames())if(!t.hasStyle(o)||t.getStyle(o)!==e.getStyle(o))return!1;for(const o of e.getAttributeKeys())"class"!==o&&"style"!==o&&this.removeAttribute(o,t);return this.removeClass(Array.from(e.getClassNames()),t),this.removeStyle(Array.from(e.getStyleNames()),t),!0}_breakAttributesRange(e,t=!1){const o=e.start,n=e.end;if(ca(e,this.document),e.isCollapsed){const o=this._breakAttributes(e.start,t);return new Ts(o,o)}const i=this._breakAttributes(n,t),r=i.parent.childCount,s=this._breakAttributes(o,t);return i.offset+=i.parent.childCount-r,new Ts(s,i)}_breakAttributes(e,t=!1){const o=e.offset,n=e.parent;if(e.parent.is("emptyElement"))throw new E("view-writer-cannot-break-empty-element",this.document);if(e.parent.is("uiElement"))throw new E("view-writer-cannot-break-ui-element",this.document);if(e.parent.is("rawElement"))throw new E("view-writer-cannot-break-raw-element",this.document);if(!t&&n.is("$text")&&la(n.parent))return e.clone();if(la(n))return e.clone();if(n.is("$text"))return this._breakAttributes(ia(e),t);if(o==n.childCount){const e=new Ss(n.parent,n.index+1);return this._breakAttributes(e,t)}if(0===o){const e=new Ss(n.parent,n.index);return this._breakAttributes(e,t)}{const e=n.index+1,i=n._clone();n.parent._insertChild(e,i),this._addToClonedElementsGroup(i);const r=n.childCount-o,s=n._removeChildren(o,r);i._appendChild(s);const a=new Ss(n.parent,e);return this._breakAttributes(a,t)}}_addToClonedElementsGroup(e){if(!e.root.is("rootElement"))return;if(e.is("element"))for(const t of e.getChildren())this._addToClonedElementsGroup(t);const t=e.id;if(!t)return;let o=this._cloneGroups.get(t);o||(o=new Set,this._cloneGroups.set(t,o)),o.add(e),e._clonesGroup=o}_removeFromClonedElementsGroup(e){if(e.is("element"))for(const t of e.getChildren())this._removeFromClonedElementsGroup(t);const t=e.id;if(!t)return;const o=this._cloneGroups.get(t);o&&o.delete(e)}}function ta(e){let t=e.parent;for(;!la(t);){if(!t)return;t=t.parent}return t}function oa(e,t){return e.priorityt.priority)&&e.getIdentity()o instanceof e)))throw new E("view-writer-insert-invalid-node-type",t);o.is("$text")||aa(o.getChildren(),t)}}function la(e){return e&&(e.is("containerElement")||e.is("documentFragment"))}function ca(e,t){const o=ta(e.start),n=ta(e.end);if(!o||!n||o!==n)throw new E("view-writer-invalid-range-container",t)}function da(e,t){return null===e.id&&null===t.id}const ua=e=>e.createTextNode(" "),ha=e=>{const t=e.createElement("span");return t.dataset.ckeFiller="true",t.innerText=" ",t},ma=e=>{const t=e.createElement("br");return t.dataset.ckeFiller="true",t},pa=7,ga="⁠".repeat(pa);function fa(e){return"string"==typeof e?e.substr(0,pa)===ga:Nn(e)&&e.data.substr(0,pa)===ga}function ba(e){return e.data.length==pa&&fa(e)}function ka(e){const t="string"==typeof e?e:e.data;return fa(e)?t.slice(pa):t}function wa(e,t){if(t.keyCode==ki.arrowleft){const e=t.domTarget.ownerDocument.defaultView.getSelection();if(1==e.rangeCount&&e.getRangeAt(0).collapsed){const t=e.getRangeAt(0).startContainer,o=e.getRangeAt(0).startOffset;fa(t)&&o<=pa&&e.collapse(t,0)}}}var _a=i(6531),ya={attributes:{"data-cke":!0}};ya.setAttributes=Ar(),ya.insert=_r().bind(null,"head"),ya.domAPI=kr(),ya.insertStyleElement=vr();fr()(_a.A,ya);_a.A&&_a.A.locals&&_a.A.locals;class Aa extends(Y()){constructor(e,t){super(),this.domDocuments=new Set,this.markedAttributes=new Set,this.markedChildren=new Set,this.markedTexts=new Set,this._inlineFiller=null,this._fakeSelectionContainer=null,this.domConverter=e,this.selection=t,this.set("isFocused",!1),this.set("isSelecting",!1),this.set("isComposing",!1),r.isBlink&&!r.isAndroid&&this.on("change:isSelecting",(()=>{this.isSelecting||this.render()}))}markToSync(e,t){if("text"===e)this.domConverter.mapViewToDom(t.parent)&&this.markedTexts.add(t);else{if(!this.domConverter.mapViewToDom(t))return;if("attributes"===e)this.markedAttributes.add(t);else{if("children"!==e){throw new E("view-renderer-unknown-type",this)}this.markedChildren.add(t)}}}render(){if(this.isComposing&&!r.isAndroid)return;let e=null;const t=!(r.isBlink&&!r.isAndroid)||!this.isSelecting;for(const e of this.markedChildren)this._updateChildrenMappings(e);t?(this._inlineFiller&&!this._isSelectionInInlineFiller()&&this._removeInlineFiller(),this._inlineFiller?e=this._getInlineFillerPosition():this._needsInlineFillerAtSelection()&&(e=this.selection.getFirstPosition(),this.markedChildren.add(e.parent))):this._inlineFiller&&this._inlineFiller.parentNode&&(e=this.domConverter.domPositionToView(this._inlineFiller),e&&e.parent.is("$text")&&(e=Ss._createBefore(e.parent)));for(const e of this.markedAttributes)this._updateAttrs(e);for(const t of this.markedChildren)this._updateChildren(t,{inlineFillerPosition:e});for(const t of this.markedTexts)!this.markedChildren.has(t.parent)&&this.domConverter.mapViewToDom(t.parent)&&this._updateText(t,{inlineFillerPosition:e});if(t)if(e){const t=this.domConverter.viewPositionToDom(e),o=t.parent.ownerDocument;fa(t.parent)?this._inlineFiller=t.parent:this._inlineFiller=Ca(o,t.parent,t.offset)}else this._inlineFiller=null;this._updateFocus(),this._updateSelection(),this.domConverter._clearTemporaryCustomProperties(),this.markedTexts.clear(),this.markedAttributes.clear(),this.markedChildren.clear()}_updateChildrenMappings(e){const t=this.domConverter.mapViewToDom(e);if(!t)return;const o=Array.from(t.childNodes),n=Array.from(this.domConverter.viewChildrenToDom(e,{withChildren:!1})),i=this._diffNodeLists(o,n),r=this._findUpdateActions(i,o,n,va);if(-1!==r.indexOf("update")){const t={equal:0,insert:0,delete:0};for(const i of r)if("update"===i){const i=t.equal+t.insert,r=t.equal+t.delete,s=e.getChild(i);!s||s.is("uiElement")||s.is("rawElement")||this._updateElementMappings(s,o[r]),ri(n[i]),t.equal++}else t[i]++}}_updateElementMappings(e,t){this.domConverter.unbindDomElement(t),this.domConverter.bindElements(t,e),this.markedChildren.add(e),this.markedAttributes.add(e)}_getInlineFillerPosition(){const e=this.selection.getFirstPosition();return e.parent.is("$text")?Ss._createBefore(e.parent):e}_isSelectionInInlineFiller(){if(1!=this.selection.rangeCount||!this.selection.isCollapsed)return!1;const e=this.selection.getFirstPosition(),t=this.domConverter.viewPositionToDom(e);return!!(t&&Nn(t.parent)&&fa(t.parent))}_removeInlineFiller(){const e=this._inlineFiller;if(!fa(e))throw new E("view-renderer-filler-was-lost",this);ba(e)?e.remove():e.data=e.data.substr(pa),this._inlineFiller=null}_needsInlineFillerAtSelection(){if(1!=this.selection.rangeCount||!this.selection.isCollapsed)return!1;const e=this.selection.getFirstPosition(),t=e.parent,o=e.offset;if(!this.domConverter.mapViewToDom(t.root))return!1;if(!t.is("element"))return!1;if(!function(e){if("false"==e.getAttribute("contenteditable"))return!1;const t=e.findAncestor((e=>e.hasAttribute("contenteditable")));return!t||"true"==t.getAttribute("contenteditable")}(t))return!1;const n=e.nodeBefore,i=e.nodeAfter;return!(n instanceof Nr||i instanceof Nr)&&(!!(o!==t.getFillerOffset()||n&&n.is("element","br"))&&(!r.isAndroid||!n&&!i))}_updateText(e,t){const o=this.domConverter.findCorrespondingDomText(e);let n=this.domConverter.viewToDom(e).data;const i=t.inlineFillerPosition;i&&i.parent==e.parent&&i.offset==e.index&&(n=ga+n),this._updateTextNode(o,n)}_updateAttrs(e){const t=this.domConverter.mapViewToDom(e);if(!t)return;const o=Array.from(t.attributes).map((e=>e.name)),n=e.getAttributeKeys();for(const o of n)this.domConverter.setDomElementAttribute(t,o,e.getAttribute(o),e);for(const n of o)e.hasAttribute(n)||this.domConverter.removeDomElementAttribute(t,n)}_updateChildren(e,t){const o=this.domConverter.mapViewToDom(e);if(!o)return;if(r.isAndroid){let e=null;for(const t of Array.from(o.childNodes)){if(e&&Nn(e)&&Nn(t)){o.normalize();break}e=t}}const n=t.inlineFillerPosition,i=o.childNodes,s=Array.from(this.domConverter.viewChildrenToDom(e,{bind:!0}));n&&n.parent===e&&Ca(o.ownerDocument,s,n.offset);const a=this._diffNodeLists(i,s),l=this._findUpdateActions(a,i,s,xa);let c=0;const d=new Set;for(const e of l)"delete"===e?(d.add(i[c]),ri(i[c])):"equal"!==e&&"update"!==e||c++;c=0;for(const e of l)"insert"===e?(Xn(o,c,s[c]),c++):"update"===e?(this._updateTextNode(i[c],s[c].data),c++):"equal"===e&&(this._markDescendantTextToSync(this.domConverter.domToView(s[c])),c++);for(const e of d)e.parentNode||this.domConverter.unbindDomElement(e)}_diffNodeLists(e,t){return e=function(e,t){const o=Array.from(e);if(0==o.length||!t)return o;const n=o[o.length-1];n==t&&o.pop();return o}(e,this._fakeSelectionContainer),b(e,t,Ea.bind(null,this.domConverter))}_findUpdateActions(e,t,o,n){if(-1===e.indexOf("insert")||-1===e.indexOf("delete"))return e;let i=[],r=[],s=[];const a={equal:0,insert:0,delete:0};for(const l of e)"insert"===l?s.push(o[a.equal+a.insert]):"delete"===l?r.push(t[a.equal+a.delete]):(i=i.concat(b(r,s,n).map((e=>"equal"===e?"update":e))),i.push("equal"),r=[],s=[]),a[l]++;return i.concat(b(r,s,n).map((e=>"equal"===e?"update":e)))}_updateTextNode(e,t){const o=e.data;o!=t&&(r.isAndroid&&this.isComposing&&o.replace(/\u00A0/g," ")==t.replace(/\u00A0/g," ")||this._updateTextNodeInternal(e,t))}_updateTextNodeInternal(e,t){const o=p(e.data,t);for(const t of o)"insert"===t.type?e.insertData(t.index,t.values.join("")):e.deleteData(t.index,t.howMany)}_markDescendantTextToSync(e){if(e)if(e.is("$text"))this.markedTexts.add(e);else if(e.is("element"))for(const t of e.getChildren())this._markDescendantTextToSync(t)}_updateSelection(){if(r.isBlink&&!r.isAndroid&&this.isSelecting&&!this.markedChildren.size)return;if(0===this.selection.rangeCount)return this._removeDomSelection(),void this._removeFakeSelection();const e=this.domConverter.mapViewToDom(this.selection.editableElement);this.isFocused&&e&&(this.selection.isFake?this._updateFakeSelection(e):this._fakeSelectionContainer&&this._fakeSelectionContainer.isConnected?(this._removeFakeSelection(),this._updateDomSelection(e)):this.isComposing&&r.isAndroid||this._updateDomSelection(e))}_updateFakeSelection(e){const t=e.ownerDocument;this._fakeSelectionContainer||(this._fakeSelectionContainer=function(e){const t=e.createElement("div");return t.className="ck-fake-selection-container",Object.assign(t.style,{position:"fixed",top:0,left:"-9999px",width:"42px"}),t.textContent=" ",t}(t));const o=this._fakeSelectionContainer;if(this.domConverter.bindFakeSelection(o,this.selection),!this._fakeSelectionNeedsUpdate(e))return;o.parentElement&&o.parentElement==e||e.appendChild(o),o.textContent=this.selection.fakeSelectionLabel||" ";const n=t.getSelection(),i=t.createRange();n.removeAllRanges(),i.selectNodeContents(o),n.addRange(i)}_updateDomSelection(e){const t=e.ownerDocument.defaultView.getSelection();if(!this._domSelectionNeedsUpdate(t))return;const o=this.domConverter.viewPositionToDom(this.selection.anchor),n=this.domConverter.viewPositionToDom(this.selection.focus);t.setBaseAndExtent(o.parent,o.offset,n.parent,n.offset),r.isGecko&&function(e,t){let o=e.parent,n=e.offset;Nn(o)&&ba(o)&&(n=Qn(o)+1,o=o.parentNode);if(o.nodeType!=Node.ELEMENT_NODE||n!=o.childNodes.length-1)return;const i=o.childNodes[n];i&&"BR"==i.tagName&&t.addRange(t.getRangeAt(0))}(n,t)}_domSelectionNeedsUpdate(e){if(!this.domConverter.isDomSelectionCorrect(e))return!0;const t=e&&this.domConverter.domSelectionToView(e);return(!t||!this.selection.isEqual(t))&&!(!this.selection.isCollapsed&&this.selection.isSimilar(t))}_fakeSelectionNeedsUpdate(e){const t=this._fakeSelectionContainer,o=e.ownerDocument.getSelection();return!t||t.parentElement!==e||(o.anchorNode!==t&&!t.contains(o.anchorNode)||t.textContent!==this.selection.fakeSelectionLabel)}_removeDomSelection(){for(const e of this.domDocuments){const t=e.getSelection();if(t.rangeCount){const o=e.activeElement,n=this.domConverter.mapDomToView(o);o&&n&&t.removeAllRanges()}}}_removeFakeSelection(){const e=this._fakeSelectionContainer;e&&e.remove()}_updateFocus(){if(this.isFocused){const e=this.selection.editableElement;e&&this.domConverter.focus(e)}}}function Ca(e,t,o){const n=t instanceof Array?t:t.childNodes,i=n[o];if(Nn(i))return i.data=ga+i.data,i;{const i=e.createTextNode(ga);return Array.isArray(t)?n.splice(o,0,i):Xn(t,o,i),i}}function va(e,t){return Pn(e)&&Pn(t)&&!Nn(e)&&!Nn(t)&&!ei(e)&&!ei(t)&&e.tagName.toLowerCase()===t.tagName.toLowerCase()}function xa(e,t){return Pn(e)&&Pn(t)&&Nn(e)&&Nn(t)}function Ea(e,t,o){return t===o||(Nn(t)&&Nn(o)?t.data===o.data:!(!e.isBlockFiller(t)||!e.isBlockFiller(o)))}const Da=ma(t.document),Ba=ua(t.document),Sa=ha(t.document),Ta="data-ck-unsafe-attribute-",Ia="data-ck-unsafe-element";class Pa{constructor(e,{blockFillerMode:o,renderingMode:n="editing"}={}){this._domToViewMapping=new WeakMap,this._viewToDomMapping=new WeakMap,this._fakeSelectionMapping=new WeakMap,this._rawContentElementMatcher=new Hr,this._inlineObjectElementMatcher=new Hr,this._elementsWithTemporaryCustomProperties=new Set,this.document=e,this.renderingMode=n,this.blockFillerMode=o||("editing"===n?"br":"nbsp"),this.preElements=["pre"],this.blockElements=["address","article","aside","blockquote","caption","center","dd","details","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","legend","li","main","menu","nav","ol","p","pre","section","summary","table","tbody","td","tfoot","th","thead","tr","ul"],this.inlineObjectElements=["object","iframe","input","button","textarea","select","option","video","embed","audio","img","canvas"],this.unsafeElements=["script","style"],this._domDocument="editing"===this.renderingMode?t.document:t.document.implementation.createHTMLDocument("")}bindFakeSelection(e,t){this._fakeSelectionMapping.set(e,new Ps(t))}fakeSelectionToView(e){return this._fakeSelectionMapping.get(e)}bindElements(e,t){this._domToViewMapping.set(e,t),this._viewToDomMapping.set(t,e)}unbindDomElement(e){const t=this._domToViewMapping.get(e);if(t){this._domToViewMapping.delete(e),this._viewToDomMapping.delete(t);for(const t of Array.from(e.children))this.unbindDomElement(t)}}bindDocumentFragments(e,t){this._domToViewMapping.set(e,t),this._viewToDomMapping.set(t,e)}shouldRenderAttribute(e,t,o){return"data"===this.renderingMode||!(e=e.toLowerCase()).startsWith("on")&&(("srcdoc"!==e||!t.match(/\bon\S+\s*=|javascript:|<\s*\/*script/i))&&("img"===o&&("src"===e||"srcset"===e)||("source"===o&&"srcset"===e||!t.match(/^\s*(javascript:|data:(image\/svg|text\/x?html))/i))))}setContentOf(e,t){if("data"===this.renderingMode)return void(e.innerHTML=t);const o=(new DOMParser).parseFromString(t,"text/html"),n=o.createDocumentFragment(),i=o.body.childNodes;for(;i.length>0;)n.appendChild(i[0]);const r=o.createTreeWalker(n,NodeFilter.SHOW_ELEMENT),s=[];let a;for(;a=r.nextNode();)s.push(a);for(const e of s){for(const t of e.getAttributeNames())this.setDomElementAttribute(e,t,e.getAttribute(t));const t=e.tagName.toLowerCase();this._shouldRenameElement(t)&&(Ra(t),e.replaceWith(this._createReplacementDomElement(t,e)))}for(;e.firstChild;)e.firstChild.remove();e.append(n)}viewToDom(e,t={}){if(e.is("$text")){const t=this._processDataFromViewText(e);return this._domDocument.createTextNode(t)}{const o=e;if(this.mapViewToDom(o)){if(!o.getCustomProperty("editingPipeline:doNotReuseOnce"))return this.mapViewToDom(o);this._elementsWithTemporaryCustomProperties.add(o)}let n;if(o.is("documentFragment"))n=this._domDocument.createDocumentFragment(),t.bind&&this.bindDocumentFragments(n,o);else{if(o.is("uiElement"))return n="$comment"===o.name?this._domDocument.createComment(o.getCustomProperty("$rawContent")):o.render(this._domDocument,this),t.bind&&this.bindElements(n,o),n;this._shouldRenameElement(o.name)?(Ra(o.name),n=this._createReplacementDomElement(o.name)):n=o.hasAttribute("xmlns")?this._domDocument.createElementNS(o.getAttribute("xmlns"),o.name):this._domDocument.createElement(o.name),o.is("rawElement")&&o.render(n,this),t.bind&&this.bindElements(n,o);for(const e of o.getAttributeKeys())this.setDomElementAttribute(n,e,o.getAttribute(e),o)}if(!1!==t.withChildren)for(const e of this.viewChildrenToDom(o,t))n instanceof HTMLTemplateElement?n.content.appendChild(e):n.appendChild(e);return n}}setDomElementAttribute(e,o,n,i){const r=this.shouldRenderAttribute(o,n,e.tagName.toLowerCase())||i&&i.shouldRenderUnsafeAttribute(o);r||D("domconverter-unsafe-attribute-detected",{domElement:e,key:o,value:n}),function(e){try{t.document.createAttribute(e)}catch(e){return!1}return!0}(o)?(e.hasAttribute(o)&&!r?e.removeAttribute(o):e.hasAttribute(Ta+o)&&r&&e.removeAttribute(Ta+o),e.setAttribute(r?o:Ta+o,n)):D("domconverter-invalid-attribute-detected",{domElement:e,key:o,value:n})}removeDomElementAttribute(e,t){t!=Ia&&(e.removeAttribute(t),e.removeAttribute(Ta+t))}*viewChildrenToDom(e,t={}){const o=e.getFillerOffset&&e.getFillerOffset();let n=0;for(const i of e.getChildren()){o===n&&(yield this._getBlockFiller());const e=i.is("element")&&!!i.getCustomProperty("dataPipeline:transparentRendering")&&!Qi(i.getAttributes());if(e&&"data"==this.renderingMode)if(i.is("rawElement")){const e=this._domDocument.createElement(i.name);i.render(e,this),yield*[...e.childNodes]}else yield*this.viewChildrenToDom(i,t);else e&&D("domconverter-transparent-rendering-unsupported-in-editing-pipeline",{viewElement:i}),yield this.viewToDom(i,t);n++}o===n&&(yield this._getBlockFiller())}viewRangeToDom(e){const t=this.viewPositionToDom(e.start),o=this.viewPositionToDom(e.end),n=this._domDocument.createRange();return n.setStart(t.parent,t.offset),n.setEnd(o.parent,o.offset),n}viewPositionToDom(e){const t=e.parent;if(t.is("$text")){const o=this.findCorrespondingDomText(t);if(!o)return null;let n=e.offset;return fa(o)&&(n+=pa),{parent:o,offset:n}}{let o,n,i;if(0===e.offset){if(o=this.mapViewToDom(t),!o)return null;i=o.childNodes[0]}else{const t=e.nodeBefore;if(n=t.is("$text")?this.findCorrespondingDomText(t):this.mapViewToDom(t),!n)return null;o=n.parentNode,i=n.nextSibling}if(Nn(i)&&fa(i))return{parent:i,offset:pa};return{parent:o,offset:n?Qn(n)+1:0}}}domToView(e,t={}){const o=[],n=this._domToView(e,t,o),i=n.next().value;return i?(n.next(),this._processDomInlineNodes(null,o,t),i.is("$text")&&0==i.data.length?null:i):null}*domChildrenToView(e,t={},o=[]){let n=[];n=e instanceof HTMLTemplateElement?[...e.content.childNodes]:[...e.childNodes];for(let i=0;i{const{scrollLeft:t,scrollTop:o}=e;i.push([t,o])})),o.focus(),Fa(o,(e=>{const[t,o]=i.shift();e.scrollLeft=t,e.scrollTop=o})),t.window.scrollTo(e,n)}}_clearDomSelection(){const e=this.mapViewToDom(this.document.selection.editableElement);if(!e)return;const t=e.ownerDocument.defaultView.getSelection(),o=this.domSelectionToView(t);o&&o.rangeCount>0&&t.removeAllRanges()}isElement(e){return e&&e.nodeType==Node.ELEMENT_NODE}isDocumentFragment(e){return e&&e.nodeType==Node.DOCUMENT_FRAGMENT_NODE}isBlockFiller(e){return"br"==this.blockFillerMode?e.isEqualNode(Da):!("BR"!==e.tagName||!Ma(e,this.blockElements)||1!==e.parentNode.childNodes.length)||(e.isEqualNode(Sa)||function(e,t){const o=e.isEqualNode(Ba);return o&&Ma(e,t)&&1===e.parentNode.childNodes.length}(e,this.blockElements))}isDomSelectionBackward(e){if(e.isCollapsed)return!1;const t=this._domDocument.createRange();try{t.setStart(e.anchorNode,e.anchorOffset),t.setEnd(e.focusNode,e.focusOffset)}catch(e){return!1}const o=t.collapsed;return t.detach(),o}getHostViewElement(e){const t=function(e){const t=[];let o=e;for(;o&&o.nodeType!=Node.DOCUMENT_NODE;)t.unshift(o),o=o.parentNode;return t}(e);for(t.pop();t.length;){const e=t.pop(),o=this._domToViewMapping.get(e);if(o&&(o.is("uiElement")||o.is("rawElement")))return o}return null}isDomSelectionCorrect(e){return this._isDomSelectionPositionCorrect(e.anchorNode,e.anchorOffset)&&this._isDomSelectionPositionCorrect(e.focusNode,e.focusOffset)}registerRawContentMatcher(e){this._rawContentElementMatcher.add(e)}registerInlineObjectMatcher(e){this._inlineObjectElementMatcher.add(e)}_clearTemporaryCustomProperties(){for(const e of this._elementsWithTemporaryCustomProperties)e._removeCustomProperty("editingPipeline:doNotReuseOnce");this._elementsWithTemporaryCustomProperties.clear()}_getBlockFiller(){switch(this.blockFillerMode){case"nbsp":return ua(this._domDocument);case"markedNbsp":return ha(this._domDocument);case"br":return ma(this._domDocument)}}_isDomSelectionPositionCorrect(e,t){if(Nn(e)&&fa(e)&&t0?t[e-1]:null,l=e+1e.is("element")&&t.includes(e.name)))}(e,this.preElements))return!0;for(const t of e.getAncestors({parentFirst:!0}))if(t.is("element")&&t.hasStyle("white-space")&&"inherit"!==t.getStyle("white-space"))return["pre","pre-wrap","break-spaces"].includes(t.getStyle("white-space"));return!1}_getTouchingInlineViewNode(e,t){const o=new Bs({startPosition:t?Ss._createAfter(e):Ss._createBefore(e),direction:t?"forward":"backward"});for(const{item:e}of o){if(e.is("$textProxy"))return e;if(!e.is("element")||!e.getCustomProperty("dataPipeline:transparentRendering")){if(e.is("element","br"))return null;if(this._isInlineObjectElement(e))return e;if(e.is("containerElement"))return null}}return null}_isBlockDomElement(e){return this.isElement(e)&&this.blockElements.includes(e.tagName.toLowerCase())}_isBlockViewElement(e){return e.is("element")&&this.blockElements.includes(e.name)}_isInlineObjectElement(e){return!!e.is("element")&&("br"==e.name||this.inlineObjectElements.includes(e.name)||!!this._inlineObjectElementMatcher.match(e))}_createViewElement(e,t){if(ei(e))return new Ks(this.document,"$comment");const o=t.keepOriginalCase?e.tagName:e.tagName.toLowerCase();return new ys(this.document,o)}_isViewElementWithRawContent(e,t){return!1!==t.withChildren&&e.is("element")&&!!this._rawContentElementMatcher.match(e)}_shouldRenameElement(e){const t=e.toLowerCase();return"editing"===this.renderingMode&&this.unsafeElements.includes(t)}_createReplacementDomElement(e,t){const o=this._domDocument.createElement("span");if(o.setAttribute(Ia,e),t){for(;t.firstChild;)o.appendChild(t.firstChild);for(const e of t.getAttributeNames())o.setAttribute(e,t.getAttribute(e))}return o}}function Fa(e,t){let o=e;for(;o;)t(o),o=o.parentElement}function Ma(e,t){const o=e.parentNode;return!!o&&!!o.tagName&&t.includes(o.tagName.toLowerCase())}function Ra(e){"script"===e&&D("domconverter-unsafe-script-element-detected"),"style"===e&&D("domconverter-unsafe-style-element-detected")}class za extends(Rn()){constructor(e){super(),this._isEnabled=!1,this.view=e,this.document=e.document}get isEnabled(){return this._isEnabled}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}destroy(){this.disable(),this.stopListening()}checkShouldIgnoreEventFromTarget(e){return e&&3===e.nodeType&&(e=e.parentNode),!(!e||1!==e.nodeType)&&e.matches("[data-cke-ignore-events], [data-cke-ignore-events] *")}}var Va=Ui((function(e,t){Mt(t,ko(t),e)}));const Oa=Va;class Na{constructor(e,t,o){this.view=e,this.document=e.document,this.domEvent=t,this.domTarget=t.target,Oa(this,o)}get target(){return this.view.domConverter.mapDomToView(this.domTarget)}preventDefault(){this.domEvent.preventDefault()}stopPropagation(){this.domEvent.stopPropagation()}}class La extends za{constructor(){super(...arguments),this.useCapture=!1}observe(e){("string"==typeof this.domEventType?[this.domEventType]:this.domEventType).forEach((t=>{this.listenTo(e,t,((e,t)=>{this.isEnabled&&!this.checkShouldIgnoreEventFromTarget(t.target)&&this.onDomEvent(t)}),{useCapture:this.useCapture})}))}stopObserving(e){this.stopListening(e)}fire(e,t,o){this.isEnabled&&this.document.fire(e,new Na(this.view,t,o))}}class Ha extends La{constructor(){super(...arguments),this.domEventType=["keydown","keyup"]}onDomEvent(e){const t={keyCode:e.keyCode,altKey:e.altKey,ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,metaKey:e.metaKey,get keystroke(){return _i(this)}};this.fire(e.type,e,t)}}const ja=function(){return le.Date.now()};var qa=/\s/;const Ua=function(e){for(var t=e.length;t--&&qa.test(e.charAt(t)););return t};var Wa=/^\s+/;const $a=function(e){return e?e.slice(0,Ua(e)+1).replace(Wa,""):e};var Ga=/^[-+]0x[0-9a-f]+$/i,Ka=/^0b[01]+$/i,Za=/^0o[0-7]+$/i,Ja=parseInt;const Ya=function(e){if("number"==typeof e)return e;if(Ur(e))return NaN;if(U(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=U(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=$a(e);var o=Ka.test(e);return o||Za.test(e)?Ja(e.slice(2),o?2:8):Ga.test(e)?NaN:+e};var Qa=Math.max,Xa=Math.min;const el=function(e,t,o){var n,i,r,s,a,l,c=0,d=!1,u=!1,h=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function m(t){var o=n,r=i;return n=i=void 0,c=t,s=e.apply(r,o)}function p(e){var o=e-l;return void 0===l||o>=t||o<0||u&&e-c>=r}function g(){var e=ja();if(p(e))return f(e);a=setTimeout(g,function(e){var o=t-(e-l);return u?Xa(o,r-(e-c)):o}(e))}function f(e){return a=void 0,h&&n?m(e):(n=i=void 0,s)}function b(){var e=ja(),o=p(e);if(n=arguments,i=this,l=e,o){if(void 0===a)return function(e){return c=e,a=setTimeout(g,t),d?m(e):s}(l);if(u)return clearTimeout(a),a=setTimeout(g,t),m(l)}return void 0===a&&(a=setTimeout(g,t)),s}return t=Ya(t)||0,U(o)&&(d=!!o.leading,r=(u="maxWait"in o)?Qa(Ya(o.maxWait)||0,t):r,h="trailing"in o?!!o.trailing:h),b.cancel=function(){void 0!==a&&clearTimeout(a),c=0,n=l=i=a=void 0},b.flush=function(){return void 0===a?s:f(ja())},b};class tl extends za{constructor(e){super(e),this._fireSelectionChangeDoneDebounced=el((e=>{this.document.fire("selectionChangeDone",e)}),200)}observe(){const e=this.document;e.on("arrowKey",((t,o)=>{e.selection.isFake&&this.isEnabled&&o.preventDefault()}),{context:"$capture"}),e.on("arrowKey",((t,o)=>{e.selection.isFake&&this.isEnabled&&this._handleSelectionMove(o.keyCode)}),{priority:"lowest"})}stopObserving(){}destroy(){super.destroy(),this._fireSelectionChangeDoneDebounced.cancel()}_handleSelectionMove(e){const t=this.document.selection,o=new Ps(t.getRanges(),{backward:t.isBackward,fake:!1});e!=ki.arrowleft&&e!=ki.arrowup||o.setTo(o.getFirstPosition()),e!=ki.arrowright&&e!=ki.arrowdown||o.setTo(o.getLastPosition());const n={oldSelection:t,newSelection:o,domSelection:null};this.document.fire("selectionChange",n),this._fireSelectionChangeDoneDebounced(n)}}const ol=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this};const nl=function(e){return this.__data__.has(e)};function il(e){var t=-1,o=null==e?0:e.length;for(this.__data__=new xt;++ta))return!1;var c=r.get(e),d=r.get(t);if(c&&d)return c==t&&d==e;var u=-1,h=!0,m=2&o?new rl:void 0;for(r.set(e,t),r.set(t,e);++uthis._handleFocus())),t.on("blur",((e,t)=>this._handleBlur(t))),t.on("beforeinput",(()=>{t.isFocused||this._handleFocus()}),{priority:"highest"})}flush(){this._isFocusChanging&&(this._isFocusChanging=!1,this.document.isFocused=!0)}onDomEvent(e){this.fire(e.type,e)}destroy(){this._clearTimeout(),super.destroy()}_handleFocus(){this._clearTimeout(),this._isFocusChanging=!0,this._renderTimeoutId=setTimeout((()=>{this._renderTimeoutId=null,this.flush(),this.view.change((()=>{}))}),50)}_handleBlur(e){const t=this.document.selection.editableElement;null!==t&&t!==e.target||(this.document.isFocused=!1,this._isFocusChanging=!1,this.view.change((()=>{})))}_clearTimeout(){this._renderTimeoutId&&(clearTimeout(this._renderTimeoutId),this._renderTimeoutId=null)}}class El extends za{constructor(e){super(e),this.mutationObserver=e.getObserver(Cl),this.focusObserver=e.getObserver(xl),this.selection=this.document.selection,this.domConverter=e.domConverter,this._documents=new WeakSet,this._fireSelectionChangeDoneDebounced=el((e=>{this.document.fire("selectionChangeDone",e)}),200),this._clearInfiniteLoopInterval=setInterval((()=>this._clearInfiniteLoop()),1e3),this._documentIsSelectingInactivityTimeoutDebounced=el((()=>this.document.isSelecting=!1),5e3),this._loopbackCounter=0}observe(e){const t=e.ownerDocument,o=()=>{this.document.isSelecting&&(this._handleSelectionChange(t),this.document.isSelecting=!1,this._documentIsSelectingInactivityTimeoutDebounced.cancel())};this.listenTo(e,"selectstart",(()=>{this.document.isSelecting=!0,this._documentIsSelectingInactivityTimeoutDebounced()}),{priority:"highest"}),this.listenTo(e,"keydown",o,{priority:"highest",useCapture:!0}),this.listenTo(e,"keyup",o,{priority:"highest",useCapture:!0}),this._documents.has(t)||(this.listenTo(t,"mouseup",o,{priority:"highest",useCapture:!0}),this.listenTo(t,"selectionchange",((e,o)=>{this.document.isComposing&&!r.isAndroid||(this._handleSelectionChange(t),this._documentIsSelectingInactivityTimeoutDebounced())})),this.listenTo(this.view.document,"compositionstart",(()=>{this._handleSelectionChange(t)}),{priority:"lowest"}),this._documents.add(t))}stopObserving(e){this.stopListening(e)}destroy(){super.destroy(),clearInterval(this._clearInfiniteLoopInterval),this._fireSelectionChangeDoneDebounced.cancel(),this._documentIsSelectingInactivityTimeoutDebounced.cancel()}_reportInfiniteLoop(){}_handleSelectionChange(e){if(!this.isEnabled)return;const t=e.defaultView.getSelection();if(this.checkShouldIgnoreEventFromTarget(t.anchorNode))return;this.mutationObserver.flush();const o=this.domConverter.domSelectionToView(t);if(0!=o.rangeCount){if(this.view.hasDomSelection=!0,this.focusObserver.flush(),!this.selection.isEqual(o)||!this.domConverter.isDomSelectionCorrect(t))if(++this._loopbackCounter>60)this._reportInfiniteLoop();else if(this.selection.isSimilar(o))this.view.forceRender();else{const e={oldSelection:this.selection,newSelection:o,domSelection:t};this.document.fire("selectionChange",e),this._fireSelectionChangeDoneDebounced(e)}}else this.view.hasDomSelection=!1}_clearInfiniteLoop(){this._loopbackCounter=0}}class Dl extends La{constructor(e){super(e),this.domEventType=["compositionstart","compositionupdate","compositionend"];const t=this.document;t.on("compositionstart",(()=>{t.isComposing=!0}),{priority:"low"}),t.on("compositionend",(()=>{t.isComposing=!1}),{priority:"low"})}onDomEvent(e){this.fire(e.type,e,{data:e.data})}}class Bl{constructor(e,t={}){this._files=t.cacheFiles?Sl(e):null,this._native=e}get files(){return this._files||(this._files=Sl(this._native)),this._files}get types(){return this._native.types}getData(e){return this._native.getData(e)}setData(e,t){this._native.setData(e,t)}set effectAllowed(e){this._native.effectAllowed=e}get effectAllowed(){return this._native.effectAllowed}set dropEffect(e){this._native.dropEffect=e}get dropEffect(){return this._native.dropEffect}setDragImage(e,t,o){this._native.setDragImage(e,t,o)}get isCanceled(){return"none"==this._native.dropEffect||!!this._native.mozUserCancelled}}function Sl(e){const t=Array.from(e.files||[]),o=Array.from(e.items||[]);return t.length?t:o.filter((e=>"file"===e.kind)).map((e=>e.getAsFile()))}class Tl extends La{constructor(){super(...arguments),this.domEventType="beforeinput"}onDomEvent(e){const t=e.getTargetRanges(),o=this.view,n=o.document;let i=null,s=null,a=[];if(e.dataTransfer&&(i=new Bl(e.dataTransfer)),null!==e.data?s=e.data:i&&(s=i.getData("text/plain")),n.selection.isFake)a=Array.from(n.selection.getRanges());else if(t.length)a=t.map((e=>{const t=o.domConverter.domPositionToView(e.startContainer,e.startOffset),n=o.domConverter.domPositionToView(e.endContainer,e.endOffset);return t?o.createRange(t,n):n?o.createRange(n):void 0})).filter((e=>!!e));else if(r.isAndroid){const t=e.target.ownerDocument.defaultView.getSelection();a=Array.from(o.domConverter.domSelectionToView(t).getRanges())}if(r.isAndroid&&"insertCompositionText"==e.inputType&&s&&s.endsWith("\n"))this.fire(e.type,e,{inputType:"insertParagraph",targetRanges:[o.createRange(a[0].end)]});else if("insertText"==e.inputType&&s&&s.includes("\n")){const t=s.split(/\n{1,2}/g);let o=a;for(let r=0;r{if(this.isEnabled&&((o=t.keyCode)==ki.arrowright||o==ki.arrowleft||o==ki.arrowup||o==ki.arrowdown)){const o=new Ms(this.document,"arrowKey",this.document.selection.getFirstRange());this.document.fire(o,t),o.stop.called&&e.stop()}var o}))}observe(){}stopObserving(){}}class Pl extends za{constructor(e){super(e);const t=this.document;t.on("keydown",((e,o)=>{if(!this.isEnabled||o.keyCode!=ki.tab||o.ctrlKey)return;const n=new Ms(t,"tab",t.selection.getFirstRange());t.fire(n,o),n.stop.called&&e.stop()}))}observe(){}stopObserving(){}}const Fl=function(e){return En(e,5)};class Ml extends(Y()){constructor(e){super(),this.domRoots=new Map,this._initialDomRootAttributes=new WeakMap,this._observers=new Map,this._ongoingChange=!1,this._postFixersInProgress=!1,this._renderingDisabled=!1,this._hasChangedSinceTheLastRendering=!1,this.document=new Hs(e),this.domConverter=new Pa(this.document),this.set("isRenderingInProgress",!1),this.set("hasDomSelection",!1),this._renderer=new Aa(this.domConverter,this.document.selection),this._renderer.bind("isFocused","isSelecting","isComposing").to(this.document,"isFocused","isSelecting","isComposing"),this._writer=new ea(this.document),this.addObserver(Cl),this.addObserver(xl),this.addObserver(El),this.addObserver(Ha),this.addObserver(tl),this.addObserver(Dl),this.addObserver(Il),this.addObserver(Tl),this.addObserver(Pl),this.document.on("arrowKey",wa,{priority:"low"}),Zs(this),this.on("render",(()=>{this._render(),this.document.fire("layoutChanged"),this._hasChangedSinceTheLastRendering=!1})),this.listenTo(this.document.selection,"change",(()=>{this._hasChangedSinceTheLastRendering=!0})),this.listenTo(this.document,"change:isFocused",(()=>{this._hasChangedSinceTheLastRendering=!0})),r.isiOS&&this.listenTo(this.document,"blur",((e,t)=>{this.domConverter.mapDomToView(t.domEvent.relatedTarget)||this.domConverter._clearDomSelection()})),this.listenTo(this.document,"mutations",((e,{mutations:t})=>{t.forEach((e=>this._renderer.markToSync(e.type,e.node)))}),{priority:"low"}),this.listenTo(this.document,"mutations",(()=>{this.forceRender()}),{priority:"lowest"})}attachDomRoot(e,t="main"){const o=this.document.getRoot(t);o._name=e.tagName.toLowerCase();const n={};for(const{name:t,value:i}of Array.from(e.attributes))n[t]=i,"class"===t?this._writer.addClass(i.split(" "),o):this._writer.setAttribute(t,i,o);this._initialDomRootAttributes.set(e,n);const i=()=>{this._writer.setAttribute("contenteditable",(!o.isReadOnly).toString(),o),o.isReadOnly?this._writer.addClass("ck-read-only",o):this._writer.removeClass("ck-read-only",o)};i(),this.domRoots.set(t,e),this.domConverter.bindElements(e,o),this._renderer.markToSync("children",o),this._renderer.markToSync("attributes",o),this._renderer.domDocuments.add(e.ownerDocument),o.on("change:children",((e,t)=>this._renderer.markToSync("children",t))),o.on("change:attributes",((e,t)=>this._renderer.markToSync("attributes",t))),o.on("change:text",((e,t)=>this._renderer.markToSync("text",t))),o.on("change:isReadOnly",(()=>this.change(i))),o.on("change",(()=>{this._hasChangedSinceTheLastRendering=!0}));for(const o of this._observers.values())o.observe(e,t)}detachDomRoot(e){const t=this.domRoots.get(e);Array.from(t.attributes).forEach((({name:e})=>t.removeAttribute(e)));const o=this._initialDomRootAttributes.get(t);for(const e in o)t.setAttribute(e,o[e]);this.domRoots.delete(e),this.domConverter.unbindDomElement(t);for(const e of this._observers.values())e.stopObserving(t)}getDomRoot(e="main"){return this.domRoots.get(e)}addObserver(e){let t=this._observers.get(e);if(t)return t;t=new e(this),this._observers.set(e,t);for(const[e,o]of this.domRoots)t.observe(o,e);return t.enable(),t}getObserver(e){return this._observers.get(e)}disableObservers(){for(const e of this._observers.values())e.disable()}enableObservers(){for(const e of this._observers.values())e.enable()}scrollToTheSelection({alignToTop:e,forceScroll:t,viewportOffset:o=20,ancestorOffset:n=20}={}){const i=this.document.selection.getFirstRange();if(!i)return;const r=Fl({alignToTop:e,forceScroll:t,viewportOffset:o,ancestorOffset:n});"number"==typeof o&&(o={top:o,bottom:o,left:o,right:o});const s={target:this.domConverter.viewRangeToDom(i),viewportOffset:o,ancestorOffset:n,alignToTop:e,forceScroll:t};this.fire("scrollToTheSelection",s,r),function({target:e,viewportOffset:t=0,ancestorOffset:o=0,alignToTop:n,forceScroll:i}){const r=hi(e);let s=r,a=null;for(t=function(e){return"number"==typeof e?{top:e,bottom:e,left:e,right:e}:e}(t);s;){let l;l=mi(s==r?e:a),ai({parent:l,getRect:()=>pi(e,s),alignToTop:n,ancestorOffset:o,forceScroll:i});const c=pi(e,s);if(si({window:s,rect:c,viewportOffset:t,alignToTop:n,forceScroll:i}),s.parent!=s){if(a=s.frameElement,s=s.parent,!a)return}else s=null}}(s)}focus(){if(!this.document.isFocused){const e=this.document.selection.editableElement;e&&(this.domConverter.focus(e),this.forceRender())}}change(e){if(this.isRenderingInProgress||this._postFixersInProgress)throw new E("cannot-change-view-tree",this);try{if(this._ongoingChange)return e(this._writer);this._ongoingChange=!0;const t=e(this._writer);return this._ongoingChange=!1,!this._renderingDisabled&&this._hasChangedSinceTheLastRendering&&(this._postFixersInProgress=!0,this.document._callPostFixers(this._writer),this._postFixersInProgress=!1,this.fire("render")),t}catch(e){E.rethrowUnexpectedError(e,this)}}forceRender(){this._hasChangedSinceTheLastRendering=!0,this.getObserver(xl).flush(),this.change((()=>{}))}destroy(){for(const e of this._observers.values())e.destroy();this.document.destroy(),this.stopListening()}createPositionAt(e,t){return Ss._createAt(e,t)}createPositionAfter(e){return Ss._createAfter(e)}createPositionBefore(e){return Ss._createBefore(e)}createRange(e,t){return new Ts(e,t)}createRangeOn(e){return Ts._createOn(e)}createRangeIn(e){return Ts._createIn(e)}createSelection(...e){return new Ps(...e)}_disableRendering(e){this._renderingDisabled=e,0==e&&this.change((()=>{}))}_render(){this.isRenderingInProgress=!0,this.disableObservers(),this._renderer.render(),this.enableObservers(),this.isRenderingInProgress=!1}}class Rl{is(){throw new Error("is() method is abstract")}}class zl extends Rl{constructor(e){super(),this.parent=null,this._attrs=tr(e)}get document(){return null}get index(){let e;if(!this.parent)return null;if(null===(e=this.parent.getChildIndex(this)))throw new E("model-node-not-found-in-parent",this);return e}get startOffset(){let e;if(!this.parent)return null;if(null===(e=this.parent.getChildStartOffset(this)))throw new E("model-node-not-found-in-parent",this);return e}get offsetSize(){return 1}get endOffset(){return this.parent?this.startOffset+this.offsetSize:null}get nextSibling(){const e=this.index;return null!==e&&this.parent.getChild(e+1)||null}get previousSibling(){const e=this.index;return null!==e&&this.parent.getChild(e-1)||null}get root(){let e=this;for(;e.parent;)e=e.parent;return e}isAttached(){return null!==this.parent&&this.root.isAttached()}getPath(){const e=[];let t=this;for(;t.parent;)e.unshift(t.startOffset),t=t.parent;return e}getAncestors(e={}){const t=[];let o=e.includeSelf?this:this.parent;for(;o;)t[e.parentFirst?"push":"unshift"](o),o=o.parent;return t}getCommonAncestor(e,t={}){const o=this.getAncestors(t),n=e.getAncestors(t);let i=0;for(;o[i]==n[i]&&o[i];)i++;return 0===i?null:o[i-1]}isBefore(e){if(this==e)return!1;if(this.root!==e.root)return!1;const t=this.getPath(),o=e.getPath(),n=ie(t,o);switch(n){case"prefix":return!0;case"extension":return!1;default:return t[n](e[t[0]]=t[1],e)),{})),e}_clone(e){return new this.constructor(this._attrs)}_remove(){this.parent._removeChildren(this.index)}_setAttribute(e,t){this._attrs.set(e,t)}_setAttributesTo(e){this._attrs=tr(e)}_removeAttribute(e){return this._attrs.delete(e)}_clearAttributes(){this._attrs.clear()}}zl.prototype.is=function(e){return"node"===e||"model:node"===e};class Vl{constructor(e){this._nodes=[],e&&this._insertNodes(0,e)}[Symbol.iterator](){return this._nodes[Symbol.iterator]()}get length(){return this._nodes.length}get maxOffset(){return this._nodes.reduce(((e,t)=>e+t.offsetSize),0)}getNode(e){return this._nodes[e]||null}getNodeIndex(e){const t=this._nodes.indexOf(e);return-1==t?null:t}getNodeStartOffset(e){const t=this.getNodeIndex(e);return null===t?null:this._nodes.slice(0,t).reduce(((e,t)=>e+t.offsetSize),0)}indexToOffset(e){if(e==this._nodes.length)return this.maxOffset;const t=this._nodes[e];if(!t)throw new E("model-nodelist-index-out-of-bounds",this);return this.getNodeStartOffset(t)}offsetToIndex(e){let t=0;for(const o of this._nodes){if(e>=t&&e1e4)return e.slice(0,o).concat(t).concat(e.slice(o+n,e.length));{const i=Array.from(e);return i.splice(o,n,...t),i}}(this._nodes,Array.from(t),e,0)}_removeNodes(e,t=1){return this._nodes.splice(e,t)}toJSON(){return this._nodes.map((e=>e.toJSON()))}}class Ol extends zl{constructor(e,t){super(t),this._data=e||""}get offsetSize(){return this.data.length}get data(){return this._data}toJSON(){const e=super.toJSON();return e.data=this.data,e}_clone(){return new Ol(this.data,this.getAttributes())}static fromJSON(e){return new Ol(e.data,e.attributes)}}Ol.prototype.is=function(e){return"$text"===e||"model:$text"===e||"text"===e||"model:text"===e||"node"===e||"model:node"===e};class Nl extends Rl{constructor(e,t,o){if(super(),this.textNode=e,t<0||t>e.offsetSize)throw new E("model-textproxy-wrong-offsetintext",this);if(o<0||t+o>e.offsetSize)throw new E("model-textproxy-wrong-length",this);this.data=e.data.substring(t,t+o),this.offsetInText=t}get startOffset(){return null!==this.textNode.startOffset?this.textNode.startOffset+this.offsetInText:null}get offsetSize(){return this.data.length}get endOffset(){return null!==this.startOffset?this.startOffset+this.offsetSize:null}get isPartial(){return this.offsetSize!==this.textNode.offsetSize}get parent(){return this.textNode.parent}get root(){return this.textNode.root}getPath(){const e=this.textNode.getPath();return e.length>0&&(e[e.length-1]+=this.offsetInText),e}getAncestors(e={}){const t=[];let o=e.includeSelf?this:this.parent;for(;o;)t[e.parentFirst?"push":"unshift"](o),o=o.parent;return t}hasAttribute(e){return this.textNode.hasAttribute(e)}getAttribute(e){return this.textNode.getAttribute(e)}getAttributes(){return this.textNode.getAttributes()}getAttributeKeys(){return this.textNode.getAttributeKeys()}}Nl.prototype.is=function(e){return"$textProxy"===e||"model:$textProxy"===e||"textProxy"===e||"model:textProxy"===e};class Ll extends zl{constructor(e,t,o){super(t),this._children=new Vl,this.name=e,o&&this._insertChild(0,o)}get childCount(){return this._children.length}get maxOffset(){return this._children.maxOffset}get isEmpty(){return 0===this.childCount}getChild(e){return this._children.getNode(e)}getChildren(){return this._children[Symbol.iterator]()}getChildIndex(e){return this._children.getNodeIndex(e)}getChildStartOffset(e){return this._children.getNodeStartOffset(e)}offsetToIndex(e){return this._children.offsetToIndex(e)}getNodeByPath(e){let t=this;for(const o of e)t=t.getChild(t.offsetToIndex(o));return t}findAncestor(e,t={}){let o=t.includeSelf?this:this.parent;for(;o;){if(o.name===e)return o;o=o.parent}return null}toJSON(){const e=super.toJSON();if(e.name=this.name,this._children.length>0){e.children=[];for(const t of this._children)e.children.push(t.toJSON())}return e}_clone(e=!1){const t=e?Array.from(this._children).map((e=>e._clone(!0))):void 0;return new Ll(this.name,this.getAttributes(),t)}_appendChild(e){this._insertChild(this.childCount,e)}_insertChild(e,t){const o=function(e){if("string"==typeof e)return[new Ol(e)];re(e)||(e=[e]);return Array.from(e).map((e=>"string"==typeof e?new Ol(e):e instanceof Nl?new Ol(e.data,e.getAttributes()):e))}(t);for(const e of o)null!==e.parent&&e._remove(),e.parent=this;this._children._insertNodes(e,o)}_removeChildren(e,t=1){const o=this._children._removeNodes(e,t);for(const e of o)e.parent=null;return o}static fromJSON(e){let t;if(e.children){t=[];for(const o of e.children)o.name?t.push(Ll.fromJSON(o)):t.push(Ol.fromJSON(o))}return new Ll(e.name,e.attributes,t)}}Ll.prototype.is=function(e,t){return t?t===this.name&&("element"===e||"model:element"===e):"element"===e||"model:element"===e||"node"===e||"model:node"===e};class Hl{constructor(e){if(!e||!e.boundaries&&!e.startPosition)throw new E("model-tree-walker-no-start-position",null);const t=e.direction||"forward";if("forward"!=t&&"backward"!=t)throw new E("model-tree-walker-unknown-direction",e,{direction:t});this.direction=t,this.boundaries=e.boundaries||null,e.startPosition?this._position=e.startPosition.clone():this._position=ql._createAt(this.boundaries["backward"==this.direction?"end":"start"]),this.position.stickiness="toNone",this.singleCharacters=!!e.singleCharacters,this.shallow=!!e.shallow,this.ignoreElementEnd=!!e.ignoreElementEnd,this._boundaryStartParent=this.boundaries?this.boundaries.start.parent:null,this._boundaryEndParent=this.boundaries?this.boundaries.end.parent:null,this._visitedParent=this.position.parent}[Symbol.iterator](){return this}get position(){return this._position}skip(e){let t,o,n,i;do{n=this.position,i=this._visitedParent,({done:t,value:o}=this.next())}while(!t&&e(o));t||(this._position=n,this._visitedParent=i)}next(){return"forward"==this.direction?this._next():this._previous()}_next(){const e=this.position,t=this.position.clone(),o=this._visitedParent;if(null===o.parent&&t.offset===o.maxOffset)return{done:!0,value:void 0};if(o===this._boundaryEndParent&&t.offset==this.boundaries.end.offset)return{done:!0,value:void 0};const n=Ul(t,o),i=n||Wl(t,o,n);if(i instanceof Ll){if(this.shallow){if(this.boundaries&&this.boundaries.end.isBefore(t))return{done:!0,value:void 0};t.offset++}else t.path.push(0),this._visitedParent=i;return this._position=t,jl("elementStart",i,e,t,1)}if(i instanceof Ol){let n;if(this.singleCharacters)n=1;else{let e=i.endOffset;this._boundaryEndParent==o&&this.boundaries.end.offsete&&(e=this.boundaries.start.offset),n=t.offset-e}const i=t.offset-r.startOffset,s=new Nl(r,i-n,n);return t.offset-=n,this._position=t,jl("text",s,e,t,n)}return t.path.pop(),this._position=t,this._visitedParent=o.parent,jl("elementStart",o,e,t,1)}}function jl(e,t,o,n,i){return{done:!1,value:{type:e,item:t,previousPosition:o,nextPosition:n,length:i}}}class ql extends Rl{constructor(e,t,o="toNone"){if(super(),!e.is("element")&&!e.is("documentFragment"))throw new E("model-position-root-invalid",e);if(!(t instanceof Array)||0===t.length)throw new E("model-position-path-incorrect-format",e,{path:t});e.is("rootElement")?t=t.slice():(t=[...e.getPath(),...t],e=e.root),this.root=e,this.path=t,this.stickiness=o}get offset(){return this.path[this.path.length-1]}set offset(e){this.path[this.path.length-1]=e}get parent(){let e=this.root;for(let t=0;t1)return!1;if(1===t)return Gl(e,this,o);if(-1===t)return Gl(this,e,o)}return this.path.length===e.path.length||(this.path.length>e.path.length?Kl(this.path,t):Kl(e.path,t))}hasSameParentAs(e){if(this.root!==e.root)return!1;return"same"==ie(this.getParentPath(),e.getParentPath())}getTransformedByOperation(e){let t;switch(e.type){case"insert":t=this._getTransformedByInsertOperation(e);break;case"move":case"remove":case"reinsert":t=this._getTransformedByMoveOperation(e);break;case"split":t=this._getTransformedBySplitOperation(e);break;case"merge":t=this._getTransformedByMergeOperation(e);break;default:t=ql._createAt(this)}return t}_getTransformedByInsertOperation(e){return this._getTransformedByInsertion(e.position,e.howMany)}_getTransformedByMoveOperation(e){return this._getTransformedByMove(e.sourcePosition,e.targetPosition,e.howMany)}_getTransformedBySplitOperation(e){const t=e.movedRange;return t.containsPosition(this)||t.start.isEqual(this)&&"toNext"==this.stickiness?this._getCombined(e.splitPosition,e.moveTargetPosition):e.graveyardPosition?this._getTransformedByMove(e.graveyardPosition,e.insertionPosition,1):this._getTransformedByInsertion(e.insertionPosition,1)}_getTransformedByMergeOperation(e){const t=e.movedRange;let o;return t.containsPosition(this)||t.start.isEqual(this)?(o=this._getCombined(e.sourcePosition,e.targetPosition),e.sourcePosition.isBefore(e.targetPosition)&&(o=o._getTransformedByDeletion(e.deletionPosition,1))):o=this.isEqual(e.deletionPosition)?ql._createAt(e.deletionPosition):this._getTransformedByMove(e.deletionPosition,e.graveyardPosition,1),o}_getTransformedByDeletion(e,t){const o=ql._createAt(this);if(this.root!=e.root)return o;if("same"==ie(e.getParentPath(),this.getParentPath())){if(e.offsetthis.offset)return null;o.offset-=t}}else if("prefix"==ie(e.getParentPath(),this.getParentPath())){const n=e.path.length-1;if(e.offset<=this.path[n]){if(e.offset+t>this.path[n])return null;o.path[n]-=t}}return o}_getTransformedByInsertion(e,t){const o=ql._createAt(this);if(this.root!=e.root)return o;if("same"==ie(e.getParentPath(),this.getParentPath()))(e.offset=t;){if(e.path[n]+i!==o.maxOffset)return!1;i=1,n--,o=o.parent}return!0}(e,o+1))}function Kl(e,t){for(;tt+1;){const t=n.maxOffset-o.offset;0!==t&&e.push(new Zl(o,o.getShiftedBy(t))),o.path=o.path.slice(0,-1),o.offset++,n=n.parent}for(;o.path.length<=this.end.path.length;){const t=this.end.path[o.path.length-1],n=t-o.offset;0!==n&&e.push(new Zl(o,o.getShiftedBy(n))),o.offset=t,o.path.push(0)}return e}getWalker(e={}){return e.boundaries=this,new Hl(e)}*getItems(e={}){e.boundaries=this,e.ignoreElementEnd=!0;const t=new Hl(e);for(const e of t)yield e.item}*getPositions(e={}){e.boundaries=this;const t=new Hl(e);yield t.position;for(const e of t)yield e.nextPosition}getTransformedByOperation(e){switch(e.type){case"insert":return this._getTransformedByInsertOperation(e);case"move":case"remove":case"reinsert":return this._getTransformedByMoveOperation(e);case"split":return[this._getTransformedBySplitOperation(e)];case"merge":return[this._getTransformedByMergeOperation(e)]}return[new Zl(this.start,this.end)]}getTransformedByOperations(e){const t=[new Zl(this.start,this.end)];for(const o of e)for(let e=0;e0?new this(o,n):new this(n,o)}static _createIn(e){return new this(ql._createAt(e,0),ql._createAt(e,e.maxOffset))}static _createOn(e){return this._createFromPositionAndShift(ql._createBefore(e),e.offsetSize)}static _createFromRanges(e){if(0===e.length)throw new E("range-create-from-ranges-empty-array",null);if(1==e.length)return e[0].clone();const t=e[0];e.sort(((e,t)=>e.start.isAfter(t.start)?1:-1));const o=e.indexOf(t),n=new this(t.start,t.end);if(o>0)for(let t=o-1;e[t].end.isEqual(n.start);t++)n.start=ql._createAt(e[t].start);for(let t=o+1;t{if(t.viewPosition)return;const o=this._modelToViewMapping.get(t.modelPosition.parent);if(!o)throw new E("mapping-model-position-view-parent-not-found",this,{modelPosition:t.modelPosition});t.viewPosition=this.findPositionIn(o,t.modelPosition.offset)}),{priority:"low"}),this.on("viewToModelPosition",((e,t)=>{if(t.modelPosition)return;const o=this.findMappedViewAncestor(t.viewPosition),n=this._viewToModelMapping.get(o),i=this._toModelOffset(t.viewPosition.parent,t.viewPosition.offset,o);t.modelPosition=ql._createAt(n,i)}),{priority:"low"})}bindElements(e,t){this._modelToViewMapping.set(e,t),this._viewToModelMapping.set(t,e)}unbindViewElement(e,t={}){const o=this.toModelElement(e);if(this._elementToMarkerNames.has(e))for(const t of this._elementToMarkerNames.get(e))this._unboundMarkerNames.add(t);t.defer?this._deferredBindingRemovals.set(e,e.root):(this._viewToModelMapping.delete(e),this._modelToViewMapping.get(o)==e&&this._modelToViewMapping.delete(o))}unbindModelElement(e){const t=this.toViewElement(e);this._modelToViewMapping.delete(e),this._viewToModelMapping.get(t)==e&&this._viewToModelMapping.delete(t)}bindElementToMarker(e,t){const o=this._markerNameToElements.get(t)||new Set;o.add(e);const n=this._elementToMarkerNames.get(e)||new Set;n.add(t),this._markerNameToElements.set(t,o),this._elementToMarkerNames.set(e,n)}unbindElementFromMarkerName(e,t){const o=this._markerNameToElements.get(t);o&&(o.delete(e),0==o.size&&this._markerNameToElements.delete(t));const n=this._elementToMarkerNames.get(e);n&&(n.delete(t),0==n.size&&this._elementToMarkerNames.delete(e))}flushUnboundMarkerNames(){const e=Array.from(this._unboundMarkerNames);return this._unboundMarkerNames.clear(),e}flushDeferredBindings(){for(const[e,t]of this._deferredBindingRemovals)e.root==t&&this.unbindViewElement(e);this._deferredBindingRemovals=new Map}clearBindings(){this._modelToViewMapping=new WeakMap,this._viewToModelMapping=new WeakMap,this._markerNameToElements=new Map,this._elementToMarkerNames=new Map,this._unboundMarkerNames=new Set,this._deferredBindingRemovals=new Map}toModelElement(e){return this._viewToModelMapping.get(e)}toViewElement(e){return this._modelToViewMapping.get(e)}toModelRange(e){return new Zl(this.toModelPosition(e.start),this.toModelPosition(e.end))}toViewRange(e){return new Ts(this.toViewPosition(e.start),this.toViewPosition(e.end))}toModelPosition(e){const t={viewPosition:e,mapper:this};return this.fire("viewToModelPosition",t),t.modelPosition}toViewPosition(e,t={}){const o={modelPosition:e,mapper:this,isPhantom:t.isPhantom};return this.fire("modelToViewPosition",o),o.viewPosition}markerNameToElements(e){const t=this._markerNameToElements.get(e);if(!t)return null;const o=new Set;for(const e of t)if(e.is("attributeElement"))for(const t of e.getElementsWithSameId())o.add(t);else o.add(e);return o}registerViewToModelLength(e,t){this._viewToModelLengthCallbacks.set(e,t)}findMappedViewAncestor(e){let t=e.parent;for(;!this._viewToModelMapping.has(t);)t=t.parent;return t}_toModelOffset(e,t,o){if(o!=e){return this._toModelOffset(e.parent,e.index,o)+this._toModelOffset(e,t,e)}if(e.is("$text"))return t;let n=0;for(let o=0;o1?t[0]+":"+t[1]:t[0]}class Xl extends(z()){constructor(e){super(),this._conversionApi={dispatcher:this,...e},this._firedEventsMap=new WeakMap}convertChanges(e,t,o){const n=this._createConversionApi(o,e.getRefreshedItems());for(const t of e.getMarkersToRemove())this._convertMarkerRemove(t.name,t.range,n);const i=this._reduceChanges(e.getChanges());for(const e of i)"insert"===e.type?this._convertInsert(Zl._createFromPositionAndShift(e.position,e.length),n):"reinsert"===e.type?this._convertReinsert(Zl._createFromPositionAndShift(e.position,e.length),n):"remove"===e.type?this._convertRemove(e.position,e.length,e.name,n):this._convertAttribute(e.range,e.attributeKey,e.attributeOldValue,e.attributeNewValue,n);n.mapper.flushDeferredBindings();for(const e of n.mapper.flushUnboundMarkerNames()){const o=t.get(e).getRange();this._convertMarkerRemove(e,o,n),this._convertMarkerAdd(e,o,n)}for(const t of e.getMarkersToAdd())this._convertMarkerAdd(t.name,t.range,n);n.consumable.verifyAllConsumed("insert")}convert(e,t,o,n={}){const i=this._createConversionApi(o,void 0,n);this._convertInsert(e,i);for(const[e,o]of t)this._convertMarkerAdd(e,o,i);i.consumable.verifyAllConsumed("insert")}convertSelection(e,t,o){const n=this._createConversionApi(o);this.fire("cleanSelection",{selection:e},n);const i=e.getFirstPosition().root;if(!n.mapper.toViewElement(i))return;const r=Array.from(t.getMarkersAtPosition(e.getFirstPosition()));if(this._addConsumablesForSelection(n.consumable,e,r),this.fire("selection",{selection:e},n),e.isCollapsed){for(const t of r)if(n.consumable.test(e,"addMarker:"+t.name)){const o=t.getRange();if(!ec(e.getFirstPosition(),t,n.mapper))continue;const i={item:e,markerName:t.name,markerRange:o};this.fire(`addMarker:${t.name}`,i,n)}for(const t of e.getAttributeKeys())if(n.consumable.test(e,"attribute:"+t)){const o={item:e,range:e.getFirstRange(),attributeKey:t,attributeOldValue:null,attributeNewValue:e.getAttribute(t)};this.fire(`attribute:${t}:$text`,o,n)}}}_convertInsert(e,t,o={}){o.doNotAddConsumables||this._addConsumablesForInsert(t.consumable,e);for(const o of Array.from(e.getWalker({shallow:!0})).map(tc))this._testAndFire("insert",o,t)}_convertRemove(e,t,o,n){this.fire(`remove:${o}`,{position:e,length:t},n)}_convertAttribute(e,t,o,n,i){this._addConsumablesForRange(i.consumable,e,`attribute:${t}`);for(const r of e){const e={item:r.item,range:Zl._createFromPositionAndShift(r.previousPosition,r.length),attributeKey:t,attributeOldValue:o,attributeNewValue:n};this._testAndFire(`attribute:${t}`,e,i)}}_convertReinsert(e,t){const o=Array.from(e.getWalker({shallow:!0}));this._addConsumablesForInsert(t.consumable,o);for(const e of o.map(tc))this._testAndFire("insert",{...e,reconversion:!0},t)}_convertMarkerAdd(e,t,o){if("$graveyard"==t.root.rootName)return;const n=`addMarker:${e}`;if(o.consumable.add(t,n),this.fire(n,{markerName:e,markerRange:t},o),o.consumable.consume(t,n)){this._addConsumablesForRange(o.consumable,t,n);for(const i of t.getItems()){if(!o.consumable.test(i,n))continue;const r={item:i,range:Zl._createOn(i),markerName:e,markerRange:t};this.fire(n,r,o)}}}_convertMarkerRemove(e,t,o){"$graveyard"!=t.root.rootName&&this.fire(`removeMarker:${e}`,{markerName:e,markerRange:t},o)}_reduceChanges(e){const t={changes:e};return this.fire("reduceChanges",t),t.changes}_addConsumablesForInsert(e,t){for(const o of t){const t=o.item;if(null===e.test(t,"insert")){e.add(t,"insert");for(const o of t.getAttributeKeys())e.add(t,"attribute:"+o)}}return e}_addConsumablesForRange(e,t,o){for(const n of t.getItems())e.add(n,o);return e}_addConsumablesForSelection(e,t,o){e.add(t,"selection");for(const n of o)e.add(t,"addMarker:"+n.name);for(const o of t.getAttributeKeys())e.add(t,"attribute:"+o);return e}_testAndFire(e,t,o){const n=function(e,t){const o=t.item.is("element")?t.item.name:"$text";return`${e}:${o}`}(e,t),i=t.item.is("$textProxy")?o.consumable._getSymbolForTextProxy(t.item):t.item,r=this._firedEventsMap.get(o),s=r.get(i);if(s){if(s.has(n))return;s.add(n)}else r.set(i,new Set([n]));this.fire(n,t,o)}_testAndFireAddAttributes(e,t){const o={item:e,range:Zl._createOn(e)};for(const e of o.item.getAttributeKeys())o.attributeKey=e,o.attributeOldValue=null,o.attributeNewValue=o.item.getAttribute(e),this._testAndFire(`attribute:${e}`,o,t)}_createConversionApi(e,t=new Set,o={}){const n={...this._conversionApi,consumable:new Yl,writer:e,options:o,convertItem:e=>this._convertInsert(Zl._createOn(e),n),convertChildren:e=>this._convertInsert(Zl._createIn(e),n,{doNotAddConsumables:!0}),convertAttributes:e=>this._testAndFireAddAttributes(e,n),canReuseView:e=>!t.has(n.mapper.toModelElement(e))};return this._firedEventsMap.set(n,new Map),n}}function ec(e,t,o){const n=t.getRange(),i=Array.from(e.getAncestors());i.shift(),i.reverse();return!i.some((e=>{if(n.containsItem(e)){return!!o.toViewElement(e).getCustomProperty("addHighlight")}}))}function tc(e){return{item:e.item,range:Zl._createFromPositionAndShift(e.previousPosition,e.length)}}class oc extends(z(Rl)){constructor(...e){super(),this._lastRangeBackward=!1,this._attrs=new Map,this._ranges=[],e.length&&this.setTo(...e)}get anchor(){if(this._ranges.length>0){const e=this._ranges[this._ranges.length-1];return this._lastRangeBackward?e.end:e.start}return null}get focus(){if(this._ranges.length>0){const e=this._ranges[this._ranges.length-1];return this._lastRangeBackward?e.start:e.end}return null}get isCollapsed(){return 1===this._ranges.length&&this._ranges[0].isCollapsed}get rangeCount(){return this._ranges.length}get isBackward(){return!this.isCollapsed&&this._lastRangeBackward}isEqual(e){if(this.rangeCount!=e.rangeCount)return!1;if(0===this.rangeCount)return!0;if(!this.anchor.isEqual(e.anchor)||!this.focus.isEqual(e.focus))return!1;for(const t of this._ranges){let o=!1;for(const n of e._ranges)if(t.isEqual(n)){o=!0;break}if(!o)return!1}return!0}*getRanges(){for(const e of this._ranges)yield new Zl(e.start,e.end)}getFirstRange(){let e=null;for(const t of this._ranges)e&&!t.start.isBefore(e.start)||(e=t);return e?new Zl(e.start,e.end):null}getLastRange(){let e=null;for(const t of this._ranges)e&&!t.end.isAfter(e.end)||(e=t);return e?new Zl(e.start,e.end):null}getFirstPosition(){const e=this.getFirstRange();return e?e.start.clone():null}getLastPosition(){const e=this.getLastRange();return e?e.end.clone():null}setTo(...e){let[t,o,n]=e;if("object"==typeof o&&(n=o,o=void 0),null===t)this._setRanges([]);else if(t instanceof oc)this._setRanges(t.getRanges(),t.isBackward);else if(t&&"function"==typeof t.getRanges)this._setRanges(t.getRanges(),t.isBackward);else if(t instanceof Zl)this._setRanges([t],!!n&&!!n.backward);else if(t instanceof ql)this._setRanges([new Zl(t)]);else if(t instanceof zl){const e=!!n&&!!n.backward;let i;if("in"==o)i=Zl._createIn(t);else if("on"==o)i=Zl._createOn(t);else{if(void 0===o)throw new E("model-selection-setto-required-second-parameter",[this,t]);i=new Zl(ql._createAt(t,o))}this._setRanges([i],e)}else{if(!re(t))throw new E("model-selection-setto-not-selectable",[this,t]);this._setRanges(t,n&&!!n.backward)}}_setRanges(e,t=!1){const o=Array.from(e),n=o.some((t=>{if(!(t instanceof Zl))throw new E("model-selection-set-ranges-not-range",[this,e]);return this._ranges.every((e=>!e.isEqual(t)))}));(o.length!==this._ranges.length||n)&&(this._replaceAllRanges(o),this._lastRangeBackward=!!t,this.fire("change:range",{directChange:!0}))}setFocus(e,t){if(null===this.anchor)throw new E("model-selection-setfocus-no-ranges",[this,e]);const o=ql._createAt(e,t);if("same"==o.compareWith(this.focus))return;const n=this.anchor;this._ranges.length&&this._popRange(),"before"==o.compareWith(n)?(this._pushRange(new Zl(o,n)),this._lastRangeBackward=!0):(this._pushRange(new Zl(n,o)),this._lastRangeBackward=!1),this.fire("change:range",{directChange:!0})}getAttribute(e){return this._attrs.get(e)}getAttributes(){return this._attrs.entries()}getAttributeKeys(){return this._attrs.keys()}hasAttribute(e){return this._attrs.has(e)}removeAttribute(e){this.hasAttribute(e)&&(this._attrs.delete(e),this.fire("change:attribute",{attributeKeys:[e],directChange:!0}))}setAttribute(e,t){this.getAttribute(e)!==t&&(this._attrs.set(e,t),this.fire("change:attribute",{attributeKeys:[e],directChange:!0}))}getSelectedElement(){return 1!==this.rangeCount?null:this.getFirstRange().getContainedElement()}*getSelectedBlocks(){const e=new WeakSet;for(const t of this.getRanges()){const o=rc(t.start,e);ac(o,t)&&(yield o);for(const o of t.getWalker()){const n=o.item;"elementEnd"==o.type&&ic(n,e,t)&&(yield n)}const n=rc(t.end,e);lc(n,t)&&(yield n)}}containsEntireContent(e=this.anchor.root){const t=ql._createAt(e,0),o=ql._createAt(e,"end");return t.isTouching(this.getFirstPosition())&&o.isTouching(this.getLastPosition())}_pushRange(e){this._checkRange(e),this._ranges.push(new Zl(e.start,e.end))}_checkRange(e){for(let t=0;t0;)this._popRange()}_popRange(){this._ranges.pop()}}function nc(e,t){return!t.has(e)&&(t.add(e),e.root.document.model.schema.isBlock(e)&&!!e.parent)}function ic(e,t,o){return nc(e,t)&&sc(e,o)}function rc(e,t){const o=e.parent.root.document.model.schema,n=e.parent.getAncestors({parentFirst:!0,includeSelf:!0});let i=!1;const r=n.find((e=>!i&&(i=o.isLimit(e),!i&&nc(e,t))));return n.forEach((e=>t.add(e))),r}function sc(e,t){const o=function(e){const t=e.root.document.model.schema;let o=e.parent;for(;o;){if(t.isBlock(o))return o;o=o.parent}}(e);if(!o)return!0;return!t.containsRange(Zl._createOn(o),!0)}function ac(e,t){return!!e&&(!(!t.isCollapsed&&!e.isEmpty)||!t.start.isTouching(ql._createAt(e,e.maxOffset))&&sc(e,t))}function lc(e,t){return!!e&&(!(!t.isCollapsed&&!e.isEmpty)||!t.end.isTouching(ql._createAt(e,0))&&sc(e,t))}oc.prototype.is=function(e){return"selection"===e||"model:selection"===e};class cc extends(z(Zl)){constructor(e,t){super(e,t),dc.call(this)}detach(){this.stopListening()}toRange(){return new Zl(this.start,this.end)}static fromRange(e){return new cc(e.start,e.end)}}function dc(){this.listenTo(this.root.document.model,"applyOperation",((e,t)=>{const o=t[0];o.isDocumentOperation&&uc.call(this,o)}),{priority:"low"})}function uc(e){const t=this.getTransformedByOperation(e),o=Zl._createFromRanges(t),n=!o.isEqual(this),i=function(e,t){switch(t.type){case"insert":return e.containsPosition(t.position);case"move":case"remove":case"reinsert":case"merge":return e.containsPosition(t.sourcePosition)||e.start.isEqual(t.sourcePosition)||e.containsPosition(t.targetPosition);case"split":return e.containsPosition(t.splitPosition)||e.containsPosition(t.insertionPosition)}return!1}(this,e);let r=null;if(n){"$graveyard"==o.root.rootName&&(r="remove"==e.type?e.sourcePosition:e.deletionPosition);const t=this.toRange();this.start=o.start,this.end=o.end,this.fire("change:range",t,{deletionPosition:r})}else i&&this.fire("change:content",this.toRange(),{deletionPosition:r})}cc.prototype.is=function(e){return"liveRange"===e||"model:liveRange"===e||"range"==e||"model:range"===e};const hc="selection:";class mc extends(z(Rl)){constructor(e){super(),this._selection=new pc(e),this._selection.delegate("change:range").to(this),this._selection.delegate("change:attribute").to(this),this._selection.delegate("change:marker").to(this)}get isCollapsed(){return this._selection.isCollapsed}get anchor(){return this._selection.anchor}get focus(){return this._selection.focus}get rangeCount(){return this._selection.rangeCount}get hasOwnRange(){return this._selection.hasOwnRange}get isBackward(){return this._selection.isBackward}get isGravityOverridden(){return this._selection.isGravityOverridden}get markers(){return this._selection.markers}get _ranges(){return this._selection._ranges}getRanges(){return this._selection.getRanges()}getFirstPosition(){return this._selection.getFirstPosition()}getLastPosition(){return this._selection.getLastPosition()}getFirstRange(){return this._selection.getFirstRange()}getLastRange(){return this._selection.getLastRange()}getSelectedBlocks(){return this._selection.getSelectedBlocks()}getSelectedElement(){return this._selection.getSelectedElement()}containsEntireContent(e){return this._selection.containsEntireContent(e)}destroy(){this._selection.destroy()}getAttributeKeys(){return this._selection.getAttributeKeys()}getAttributes(){return this._selection.getAttributes()}getAttribute(e){return this._selection.getAttribute(e)}hasAttribute(e){return this._selection.hasAttribute(e)}refresh(){this._selection.updateMarkers(),this._selection._updateAttributes(!1)}observeMarkers(e){this._selection.observeMarkers(e)}_setFocus(e,t){this._selection.setFocus(e,t)}_setTo(...e){this._selection.setTo(...e)}_setAttribute(e,t){this._selection.setAttribute(e,t)}_removeAttribute(e){this._selection.removeAttribute(e)}_getStoredAttributes(){return this._selection.getStoredAttributes()}_overrideGravity(){return this._selection.overrideGravity()}_restoreGravity(e){this._selection.restoreGravity(e)}static _getStoreAttributeKey(e){return hc+e}static _isStoreAttributeKey(e){return e.startsWith(hc)}}mc.prototype.is=function(e){return"selection"===e||"model:selection"==e||"documentSelection"==e||"model:documentSelection"==e};class pc extends oc{constructor(e){super(),this.markers=new Yi({idProperty:"name"}),this._attributePriority=new Map,this._selectionRestorePosition=null,this._hasChangedRange=!1,this._overriddenGravityRegister=new Set,this._observedMarkers=new Set,this._model=e.model,this._document=e,this.listenTo(this._model,"applyOperation",((e,t)=>{const o=t[0];o.isDocumentOperation&&"marker"!=o.type&&"rename"!=o.type&&"noop"!=o.type&&(0==this._ranges.length&&this._selectionRestorePosition&&this._fixGraveyardSelection(this._selectionRestorePosition),this._selectionRestorePosition=null,this._hasChangedRange&&(this._hasChangedRange=!1,this.fire("change:range",{directChange:!1})))}),{priority:"lowest"}),this.on("change:range",(()=>{this._validateSelectionRanges(this.getRanges())})),this.listenTo(this._model.markers,"update",((e,t,o,n)=>{this._updateMarker(t,n)})),this.listenTo(this._document,"change",((e,t)=>{!function(e,t){const o=e.document.differ;for(const n of o.getChanges()){if("insert"!=n.type)continue;const o=n.position.parent;n.length===o.maxOffset&&e.enqueueChange(t,(e=>{const t=Array.from(o.getAttributeKeys()).filter((e=>e.startsWith(hc)));for(const n of t)e.removeAttribute(n,o)}))}}(this._model,t)}))}get isCollapsed(){return 0===this._ranges.length?this._document._getDefaultRange().isCollapsed:super.isCollapsed}get anchor(){return super.anchor||this._document._getDefaultRange().start}get focus(){return super.focus||this._document._getDefaultRange().end}get rangeCount(){return this._ranges.length?this._ranges.length:1}get hasOwnRange(){return this._ranges.length>0}get isGravityOverridden(){return!!this._overriddenGravityRegister.size}destroy(){for(let e=0;e{if(this._hasChangedRange=!0,t.root==this._document.graveyard){this._selectionRestorePosition=n.deletionPosition;const e=this._ranges.indexOf(t);this._ranges.splice(e,1),t.detach()}})),t}updateMarkers(){if(!this._observedMarkers.size)return;const e=[];let t=!1;for(const t of this._model.markers){const o=t.name.split(":",1)[0];if(!this._observedMarkers.has(o))continue;const n=t.getRange();for(const o of this.getRanges())n.containsRange(o,!o.isCollapsed)&&e.push(t)}const o=Array.from(this.markers);for(const o of e)this.markers.has(o)||(this.markers.add(o),t=!0);for(const o of Array.from(this.markers))e.includes(o)||(this.markers.remove(o),t=!0);t&&this.fire("change:marker",{oldMarkers:o,directChange:!1})}_updateMarker(e,t){const o=e.name.split(":",1)[0];if(!this._observedMarkers.has(o))return;let n=!1;const i=Array.from(this.markers),r=this.markers.has(e);if(t){let o=!1;for(const e of this.getRanges())if(t.containsRange(e,!e.isCollapsed)){o=!0;break}o&&!r?(this.markers.add(e),n=!0):!o&&r&&(this.markers.remove(e),n=!0)}else r&&(this.markers.remove(e),n=!0);n&&this.fire("change:marker",{oldMarkers:i,directChange:!1})}_updateAttributes(e){const t=tr(this._getSurroundingAttributes()),o=tr(this.getAttributes());if(e)this._attributePriority=new Map,this._attrs=new Map;else for(const[e,t]of this._attributePriority)"low"==t&&(this._attrs.delete(e),this._attributePriority.delete(e));this._setAttributesTo(t);const n=[];for(const[e,t]of this.getAttributes())o.has(e)&&o.get(e)===t||n.push(e);for(const[e]of o)this.hasAttribute(e)||n.push(e);n.length>0&&this.fire("change:attribute",{attributeKeys:n,directChange:!1})}_setAttribute(e,t,o=!0){const n=o?"normal":"low";if("low"==n&&"normal"==this._attributePriority.get(e))return!1;return super.getAttribute(e)!==t&&(this._attrs.set(e,t),this._attributePriority.set(e,n),!0)}_removeAttribute(e,t=!0){const o=t?"normal":"low";return("low"!=o||"normal"!=this._attributePriority.get(e))&&(this._attributePriority.set(e,o),!!super.hasAttribute(e)&&(this._attrs.delete(e),!0))}_setAttributesTo(e){const t=new Set;for(const[t,o]of this.getAttributes())e.get(t)!==o&&this._removeAttribute(t,!1);for(const[o,n]of e){this._setAttribute(o,n,!1)&&t.add(o)}return t}*getStoredAttributes(){const e=this.getFirstPosition().parent;if(this.isCollapsed&&e.isEmpty)for(const t of e.getAttributeKeys())if(t.startsWith(hc)){const o=t.substr(10);yield[o,e.getAttribute(t)]}}_getSurroundingAttributes(){const e=this.getFirstPosition(),t=this._model.schema;if("$graveyard"==e.root.rootName)return null;let o=null;if(this.isCollapsed){const n=e.textNode?e.textNode:e.nodeBefore,i=e.textNode?e.textNode:e.nodeAfter;if(this.isGravityOverridden||(o=gc(n,t)),o||(o=gc(i,t)),!this.isGravityOverridden&&!o){let e=n;for(;e&&!o;)e=e.previousSibling,o=gc(e,t)}if(!o){let e=i;for(;e&&!o;)e=e.nextSibling,o=gc(e,t)}o||(o=this.getStoredAttributes())}else{const e=this.getFirstRange();for(const n of e){if(n.item.is("element")&&t.isObject(n.item)){o=gc(n.item,t);break}if("text"==n.type){o=n.item.getAttributes();break}}}return o}_fixGraveyardSelection(e){const t=this._model.schema.getNearestSelectionRange(e);t&&this._pushRange(t)}}function gc(e,t){if(!e)return null;if(e instanceof Nl||e instanceof Ol)return e.getAttributes();if(!t.isInline(e))return null;if(!t.isObject(e))return[];const o=[];for(const[n,i]of e.getAttributes())t.checkAttribute("$text",n)&&!1!==t.getAttributeProperties(n).copyFromObject&&o.push([n,i]);return o}class fc{constructor(e){this._dispatchers=e}add(e){for(const t of this._dispatchers)e(t);return this}}class bc extends fc{elementToElement(e){return this.add(function(e){const t=Cc(e.model),o=vc(e.view,"container");t.attributes.length&&(t.children=!0);return n=>{n.on(`insert:${t.name}`,_c(o,Sc(t)),{priority:e.converterPriority||"normal"}),(t.children||t.attributes.length)&&n.on("reduceChanges",Bc(t),{priority:"low"})}}(e))}elementToStructure(e){return this.add(function(e){const t=Cc(e.model),o=vc(e.view,"container");return t.children=!0,n=>{if(n._conversionApi.schema.checkChild(t.name,"$text"))throw new E("conversion-element-to-structure-disallowed-text",n,{elementName:t.name});var i,r;n.on(`insert:${t.name}`,(i=o,r=Sc(t),(e,t,o)=>{if(!r(t.item,o.consumable,{preflight:!0}))return;const n=new Map;o.writer._registerSlotFactory(function(e,t,o){return(n,i)=>{const r=n.createContainerElement("$slot");let s=null;if("children"===i)s=Array.from(e.getChildren());else{if("function"!=typeof i)throw new E("conversion-slot-mode-unknown",o.dispatcher,{modeOrFilter:i});s=Array.from(e.getChildren()).filter((e=>i(e)))}return t.set(r,s),r}}(t.item,n,o));const s=i(t.item,o,t);if(o.writer._clearSlotFactory(),!s)return;!function(e,t,o){const n=Array.from(t.values()).flat(),i=new Set(n);if(i.size!=n.length)throw new E("conversion-slot-filter-overlap",o.dispatcher,{element:e});if(i.size!=e.childCount)throw new E("conversion-slot-filter-incomplete",o.dispatcher,{element:e})}(t.item,n,o),r(t.item,o.consumable);const a=o.mapper.toViewPosition(t.range.start);o.mapper.bindElements(t.item,s),o.writer.insert(a,s),o.convertAttributes(t.item),function(e,t,o,n){o.mapper.on("modelToViewPosition",s,{priority:"highest"});let i=null,r=null;for([i,r]of t)Tc(e,r,o,n),o.writer.move(o.writer.createRangeIn(i),o.writer.createPositionBefore(i)),o.writer.remove(i);function s(e,t){const o=t.modelPosition.nodeAfter,n=r.indexOf(o);n<0||(t.viewPosition=t.mapper.findPositionIn(i,n))}o.mapper.off("modelToViewPosition",s)}(s,n,o,{reconversion:t.reconversion})}),{priority:e.converterPriority||"normal"}),n.on("reduceChanges",Bc(t),{priority:"low"})}}(e))}attributeToElement(e){return this.add(function(e){e=Fl(e);let t=e.model;"string"==typeof t&&(t={key:t});let o=`attribute:${t.key}`;t.name&&(o+=":"+t.name);if(t.values)for(const o of t.values)e.view[o]=vc(e.view[o],"attribute");else e.view=vc(e.view,"attribute");const n=xc(e);return t=>{t.on(o,wc(n),{priority:e.converterPriority||"normal"})}}(e))}attributeToAttribute(e){return this.add(function(e){e=Fl(e);let t=e.model;"string"==typeof t&&(t={key:t});let o=`attribute:${t.key}`;t.name&&(o+=":"+t.name);if(t.values)for(const o of t.values)e.view[o]=Ec(e.view[o]);else e.view=Ec(e.view);const n=xc(e);return t=>{var i;t.on(o,(i=n,(e,t,o)=>{if(!o.consumable.test(t.item,e.name))return;const n=i(t.attributeOldValue,o,t),r=i(t.attributeNewValue,o,t);if(!n&&!r)return;o.consumable.consume(t.item,e.name);const s=o.mapper.toViewElement(t.item),a=o.writer;if(!s)throw new E("conversion-attribute-to-attribute-on-text",o.dispatcher,t);if(null!==t.attributeOldValue&&n)if("class"==n.key){const e="string"==typeof n.value?n.value.split(/\s+/):n.value;for(const t of e)a.removeClass(t,s)}else if("style"==n.key)if("string"==typeof n.value){const e=new bs(a.document.stylesProcessor);e.setTo(n.value);for(const[t]of e.getStylesEntries())a.removeStyle(t,s)}else{const e=Object.keys(n.value);for(const t of e)a.removeStyle(t,s)}else a.removeAttribute(n.key,s);if(null!==t.attributeNewValue&&r)if("class"==r.key){const e="string"==typeof r.value?r.value.split(/\s+/):r.value;for(const t of e)a.addClass(t,s)}else if("style"==r.key)if("string"==typeof r.value){const e=new bs(a.document.stylesProcessor);e.setTo(r.value);for(const[t,o]of e.getStylesEntries())a.setStyle(t,o,s)}else{const e=Object.keys(r.value);for(const t of e)a.setStyle(t,r.value[t],s)}else a.setAttribute(r.key,r.value,s)}),{priority:e.converterPriority||"normal"})}}(e))}markerToElement(e){return this.add(function(e){const t=vc(e.view,"ui");return o=>{o.on(`addMarker:${e.model}`,yc(t),{priority:e.converterPriority||"normal"}),o.on(`removeMarker:${e.model}`,((e,t,o)=>{const n=o.mapper.markerNameToElements(t.markerName);if(n){for(const e of n)o.mapper.unbindElementFromMarkerName(e,t.markerName),o.writer.clear(o.writer.createRangeOn(e),e);o.writer.clearClonedElementsGroup(t.markerName),e.stop()}}),{priority:e.converterPriority||"normal"})}}(e))}markerToHighlight(e){return this.add(function(e){return t=>{var o;t.on(`addMarker:${e.model}`,(o=e.view,(e,t,n)=>{if(!t.item)return;if(!(t.item instanceof oc||t.item instanceof mc||t.item.is("$textProxy")))return;const i=Dc(o,t,n);if(!i)return;if(!n.consumable.consume(t.item,e.name))return;const r=n.writer,s=kc(r,i),a=r.document.selection;if(t.item instanceof oc||t.item instanceof mc)r.wrap(a.getFirstRange(),s);else{const e=n.mapper.toViewRange(t.range),o=r.wrap(e,s);for(const e of o.getItems())if(e.is("attributeElement")&&e.isSimilar(s)){n.mapper.bindElementToMarker(e,t.markerName);break}}}),{priority:e.converterPriority||"normal"}),t.on(`addMarker:${e.model}`,function(e){return(t,o,n)=>{if(!o.item)return;if(!(o.item instanceof Ll))return;const i=Dc(e,o,n);if(!i)return;if(!n.consumable.test(o.item,t.name))return;const r=n.mapper.toViewElement(o.item);if(r&&r.getCustomProperty("addHighlight")){n.consumable.consume(o.item,t.name);for(const e of Zl._createIn(o.item))n.consumable.consume(e.item,t.name);r.getCustomProperty("addHighlight")(r,i,n.writer),n.mapper.bindElementToMarker(r,o.markerName)}}}(e.view),{priority:e.converterPriority||"normal"}),t.on(`removeMarker:${e.model}`,function(e){return(t,o,n)=>{if(o.markerRange.isCollapsed)return;const i=Dc(e,o,n);if(!i)return;const r=kc(n.writer,i),s=n.mapper.markerNameToElements(o.markerName);if(s){for(const e of s)if(n.mapper.unbindElementFromMarkerName(e,o.markerName),e.is("attributeElement"))n.writer.unwrap(n.writer.createRangeOn(e),r);else{e.getCustomProperty("removeHighlight")(e,i.id,n.writer)}n.writer.clearClonedElementsGroup(o.markerName),t.stop()}}}(e.view),{priority:e.converterPriority||"normal"})}}(e))}markerToData(e){return this.add(function(e){e=Fl(e);const t=e.model;let o=e.view;o||(o=o=>({group:t,name:o.substr(e.model.length+1)}));return n=>{var i;n.on(`addMarker:${t}`,(i=o,(e,t,o)=>{const n=i(t.markerName,o);if(!n)return;const r=t.markerRange;o.consumable.consume(r,e.name)&&(Ac(r,!1,o,t,n),Ac(r,!0,o,t,n),e.stop())}),{priority:e.converterPriority||"normal"}),n.on(`removeMarker:${t}`,function(e){return(t,o,n)=>{const i=e(o.markerName,n);if(!i)return;const r=n.mapper.markerNameToElements(o.markerName);if(r){for(const e of r)n.mapper.unbindElementFromMarkerName(e,o.markerName),e.is("containerElement")?(s(`data-${i.group}-start-before`,e),s(`data-${i.group}-start-after`,e),s(`data-${i.group}-end-before`,e),s(`data-${i.group}-end-after`,e)):n.writer.clear(n.writer.createRangeOn(e),e);n.writer.clearClonedElementsGroup(o.markerName),t.stop()}function s(e,t){if(t.hasAttribute(e)){const o=new Set(t.getAttribute(e).split(","));o.delete(i.name),0==o.size?n.writer.removeAttribute(e,t):n.writer.setAttribute(e,Array.from(o).join(","),t)}}}}(o),{priority:e.converterPriority||"normal"})}}(e))}}function kc(e,t){const o=e.createAttributeElement("span",t.attributes);return t.classes&&o._addClass(t.classes),"number"==typeof t.priority&&(o._priority=t.priority),o._id=t.id,o}function wc(e){return(t,o,n)=>{if(!n.consumable.test(o.item,t.name))return;const i=e(o.attributeOldValue,n,o),r=e(o.attributeNewValue,n,o);if(!i&&!r)return;n.consumable.consume(o.item,t.name);const s=n.writer,a=s.document.selection;if(o.item instanceof oc||o.item instanceof mc)s.wrap(a.getFirstRange(),r);else{let e=n.mapper.toViewRange(o.range);null!==o.attributeOldValue&&i&&(e=s.unwrap(e,i)),null!==o.attributeNewValue&&r&&s.wrap(e,r)}}}function _c(e,t=Pc){return(o,n,i)=>{if(!t(n.item,i.consumable,{preflight:!0}))return;const r=e(n.item,i,n);if(!r)return;t(n.item,i.consumable);const s=i.mapper.toViewPosition(n.range.start);i.mapper.bindElements(n.item,r),i.writer.insert(s,r),i.convertAttributes(n.item),Tc(r,n.item.getChildren(),i,{reconversion:n.reconversion})}}function yc(e){return(t,o,n)=>{o.isOpening=!0;const i=e(o,n);o.isOpening=!1;const r=e(o,n);if(!i||!r)return;const s=o.markerRange;if(s.isCollapsed&&!n.consumable.consume(s,t.name))return;for(const e of s)if(!n.consumable.consume(e.item,t.name))return;const a=n.mapper,l=n.writer;l.insert(a.toViewPosition(s.start),i),n.mapper.bindElementToMarker(i,o.markerName),s.isCollapsed||(l.insert(a.toViewPosition(s.end),r),n.mapper.bindElementToMarker(r,o.markerName)),t.stop()}}function Ac(e,t,o,n,i){const r=t?e.start:e.end,s=r.nodeAfter&&r.nodeAfter.is("element")?r.nodeAfter:null,a=r.nodeBefore&&r.nodeBefore.is("element")?r.nodeBefore:null;if(s||a){let e,r;t&&s||!t&&!a?(e=s,r=!0):(e=a,r=!1);const l=o.mapper.toViewElement(e);if(l)return void function(e,t,o,n,i,r){const s=`data-${r.group}-${t?"start":"end"}-${o?"before":"after"}`,a=e.hasAttribute(s)?e.getAttribute(s).split(","):[];a.unshift(r.name),n.writer.setAttribute(s,a.join(","),e),n.mapper.bindElementToMarker(e,i.markerName)}(l,t,r,o,n,i)}!function(e,t,o,n,i){const r=`${i.group}-${t?"start":"end"}`,s=i.name?{name:i.name}:null,a=o.writer.createUIElement(r,s);o.writer.insert(e,a),o.mapper.bindElementToMarker(a,n.markerName)}(o.mapper.toViewPosition(r),t,o,n,i)}function Cc(e){return"string"==typeof e&&(e={name:e}),{name:e.name,attributes:e.attributes?xi(e.attributes):[],children:!!e.children}}function vc(e,t){return"function"==typeof e?e:(o,n)=>function(e,t,o){"string"==typeof e&&(e={name:e});let n;const i=t.writer,r=Object.assign({},e.attributes);if("container"==o)n=i.createContainerElement(e.name,r);else if("attribute"==o){const t={priority:e.priority||qs.DEFAULT_PRIORITY};n=i.createAttributeElement(e.name,r,t)}else n=i.createUIElement(e.name,r);if(e.styles){const t=Object.keys(e.styles);for(const o of t)i.setStyle(o,e.styles[o],n)}if(e.classes){const t=e.classes;if("string"==typeof t)i.addClass(t,n);else for(const e of t)i.addClass(e,n)}return n}(e,n,t)}function xc(e){return e.model.values?(t,o,n)=>{const i=e.view[t];return i?i(t,o,n):null}:e.view}function Ec(e){return"string"==typeof e?t=>({key:e,value:t}):"object"==typeof e?e.value?()=>e:t=>({key:e.key,value:t}):e}function Dc(e,t,o){const n="function"==typeof e?e(t,o):e;return n?(n.priority||(n.priority=10),n.id||(n.id=t.markerName),n):null}function Bc(e){const t=function(e){return(t,o)=>{if(!t.is("element",e.name))return!1;if("attribute"==o.type){if(e.attributes.includes(o.attributeKey))return!0}else if(e.children)return!0;return!1}}(e);return(e,o)=>{const n=[];o.reconvertedElements||(o.reconvertedElements=new Set);for(const e of o.changes){const i="attribute"==e.type?e.range.start.nodeAfter:e.position.parent;if(i&&t(i,e)){if(!o.reconvertedElements.has(i)){o.reconvertedElements.add(i);const e=ql._createBefore(i);let t=n.length;for(let o=n.length-1;o>=0;o--){const i=n[o],r=("attribute"==i.type?i.range.start:i.position).compareWith(e);if("before"==r||"remove"==i.type&&"same"==r)break;t=o}n.splice(t,0,{type:"remove",name:i.name,position:e,length:1},{type:"reinsert",name:i.name,position:e,length:1})}}else n.push(e)}o.changes=n}}function Sc(e){return(t,o,n={})=>{const i=["insert"];for(const o of e.attributes)t.hasAttribute(o)&&i.push(`attribute:${o}`);return!!i.every((e=>o.test(t,e)))&&(n.preflight||i.forEach((e=>o.consume(t,e))),!0)}}function Tc(e,t,o,n){for(const i of t)Ic(e.root,i,o,n)||o.convertItem(i)}function Ic(e,t,o,n){const{writer:i,mapper:r}=o;if(!n.reconversion)return!1;const s=r.toViewElement(t);return!(!s||s.root==e)&&(!!o.canReuseView(s)&&(i.move(i.createRangeOn(s),r.toViewPosition(ql._createBefore(t))),!0))}function Pc(e,t,{preflight:o}={}){return o?t.test(e,"insert"):t.consume(e,"insert")}function Fc(e){const{schema:t,document:o}=e.model;for(const n of o.getRoots())if(n.isEmpty&&!t.checkChild(n,"$text")&&t.checkChild(n,"paragraph"))return e.insertElement("paragraph",n),!0;return!1}function Mc(e,t,o){const n=o.createContext(e);return!!o.checkChild(n,"paragraph")&&!!o.checkChild(n.push("paragraph"),t)}function Rc(e,t){const o=t.createElement("paragraph");return t.insert(o,e),t.createPositionAt(o,0)}class zc extends fc{elementToElement(e){return this.add(Vc(e))}elementToAttribute(e){return this.add(function(e){e=Fl(e),Lc(e);const t=Hc(e,!1),o=Oc(e.view),n=o?`element:${o}`:"element";return o=>{o.on(n,t,{priority:e.converterPriority||"low"})}}(e))}attributeToAttribute(e){return this.add(function(e){e=Fl(e);let t=null;("string"==typeof e.view||e.view.key)&&(t=function(e){"string"==typeof e.view&&(e.view={key:e.view});const t=e.view.key,o=void 0===e.view.value?/[\s\S]*/:e.view.value;let n;if("class"==t||"style"==t){n={["class"==t?"classes":"styles"]:o}}else n={attributes:{[t]:o}};e.view.name&&(n.name=e.view.name);return e.view=n,t}(e));Lc(e,t);const o=Hc(e,!0);return t=>{t.on("element",o,{priority:e.converterPriority||"low"})}}(e))}elementToMarker(e){return this.add(function(e){const t=function(e){return(t,o)=>{const n="string"==typeof e?e:e(t,o);return o.writer.createElement("$marker",{"data-name":n})}}(e.model);return Vc({...e,model:t})}(e))}dataToMarker(e){return this.add(function(e){e=Fl(e),e.model||(e.model=t=>t?e.view+":"+t:e.view);const t={view:e.view,model:e.model},o=Nc(jc(t,"start")),n=Nc(jc(t,"end"));return i=>{i.on(`element:${e.view}-start`,o,{priority:e.converterPriority||"normal"}),i.on(`element:${e.view}-end`,n,{priority:e.converterPriority||"normal"});const r=C.low,s=C.highest,a=C.get(e.converterPriority)/s;i.on("element",function(e){return(t,o,n)=>{const i=`data-${e.view}`;function r(t,i){for(const r of i){const i=e.model(r,n),s=n.writer.createElement("$marker",{"data-name":i});n.writer.insert(s,t),o.modelCursor.isEqual(t)?o.modelCursor=o.modelCursor.getShiftedBy(1):o.modelCursor=o.modelCursor._getTransformedByInsertion(t,1),o.modelRange=o.modelRange._getTransformedByInsertion(t,1)[0]}}(n.consumable.test(o.viewItem,{attributes:i+"-end-after"})||n.consumable.test(o.viewItem,{attributes:i+"-start-after"})||n.consumable.test(o.viewItem,{attributes:i+"-end-before"})||n.consumable.test(o.viewItem,{attributes:i+"-start-before"}))&&(o.modelRange||Object.assign(o,n.convertChildren(o.viewItem,o.modelCursor)),n.consumable.consume(o.viewItem,{attributes:i+"-end-after"})&&r(o.modelRange.end,o.viewItem.getAttribute(i+"-end-after").split(",")),n.consumable.consume(o.viewItem,{attributes:i+"-start-after"})&&r(o.modelRange.end,o.viewItem.getAttribute(i+"-start-after").split(",")),n.consumable.consume(o.viewItem,{attributes:i+"-end-before"})&&r(o.modelRange.start,o.viewItem.getAttribute(i+"-end-before").split(",")),n.consumable.consume(o.viewItem,{attributes:i+"-start-before"})&&r(o.modelRange.start,o.viewItem.getAttribute(i+"-start-before").split(",")))}}(t),{priority:r+a})}}(e))}}function Vc(e){const t=Nc(e=Fl(e)),o=Oc(e.view),n=o?`element:${o}`:"element";return o=>{o.on(n,t,{priority:e.converterPriority||"normal"})}}function Oc(e){return"string"==typeof e?e:"object"==typeof e&&"string"==typeof e.name?e.name:null}function Nc(e){const t=new Hr(e.view);return(o,n,i)=>{const r=t.match(n.viewItem);if(!r)return;const s=r.match;if(s.name=!0,!i.consumable.test(n.viewItem,s))return;const a=function(e,t,o){return e instanceof Function?e(t,o):o.writer.createElement(e)}(e.model,n.viewItem,i);a&&i.safeInsert(a,n.modelCursor)&&(i.consumable.consume(n.viewItem,s),i.convertChildren(n.viewItem,a),i.updateConversionResult(a,n))}}function Lc(e,t=null){const o=null===t||(e=>e.getAttribute(t)),n="object"!=typeof e.model?e.model:e.model.key,i="object"!=typeof e.model||void 0===e.model.value?o:e.model.value;e.model={key:n,value:i}}function Hc(e,t){const o=new Hr(e.view);return(n,i,r)=>{if(!i.modelRange&&t)return;const s=o.match(i.viewItem);if(!s)return;if(!function(e,t){const o="function"==typeof e?e(t):e;if("object"==typeof o&&!Oc(o))return!1;return!o.classes&&!o.attributes&&!o.styles}(e.view,i.viewItem)?delete s.match.name:s.match.name=!0,!r.consumable.test(i.viewItem,s.match))return;const a=e.model.key,l="function"==typeof e.model.value?e.model.value(i.viewItem,r):e.model.value;if(null===l)return;i.modelRange||Object.assign(i,r.convertChildren(i.viewItem,i.modelCursor));const c=function(e,t,o,n){let i=!1;for(const r of Array.from(e.getItems({shallow:o})))n.schema.checkAttribute(r,t.key)&&(i=!0,r.hasAttribute(t.key)||n.writer.setAttribute(t.key,t.value,r));return i}(i.modelRange,{key:a,value:l},t,r);c&&(r.consumable.test(i.viewItem,{name:!0})&&(s.match.name=!0),r.consumable.consume(i.viewItem,s.match))}}function jc(e,t){return{view:`${e.view}-${t}`,model:(t,o)=>{const n=t.getAttribute("name"),i=e.model(n,o);return o.writer.createElement("$marker",{"data-name":i})}}}function qc(e){e.document.registerPostFixer((t=>function(e,t){const o=t.document.selection,n=t.schema,i=[];let r=!1;for(const e of o.getRanges()){const t=Uc(e,n);t&&!t.isEqual(e)?(i.push(t),r=!0):i.push(e)}r&&e.setSelection(function(e){const t=[...e],o=new Set;let n=1;for(;n!o.has(t)))}(i),{backward:o.isBackward});return!1}(t,e)))}function Uc(e,t){return e.isCollapsed?function(e,t){const o=e.start,n=t.getNearestSelectionRange(o);if(!n){const e=o.getAncestors().reverse().find((e=>t.isObject(e)));return e?Zl._createOn(e):null}if(!n.isCollapsed)return n;const i=n.start;if(o.isEqual(i))return null;return new Zl(i)}(e,t):function(e,t){const{start:o,end:n}=e,i=t.checkChild(o,"$text"),r=t.checkChild(n,"$text"),s=t.getLimitElement(o),a=t.getLimitElement(n);if(s===a){if(i&&r)return null;if(function(e,t,o){const n=e.nodeAfter&&!o.isLimit(e.nodeAfter)||o.checkChild(e,"$text"),i=t.nodeBefore&&!o.isLimit(t.nodeBefore)||o.checkChild(t,"$text");return n||i}(o,n,t)){const e=o.nodeAfter&&t.isSelectable(o.nodeAfter)?null:t.getNearestSelectionRange(o,"forward"),i=n.nodeBefore&&t.isSelectable(n.nodeBefore)?null:t.getNearestSelectionRange(n,"backward"),r=e?e.start:o,s=i?i.end:n;return new Zl(r,s)}}const l=s&&!s.is("rootElement"),c=a&&!a.is("rootElement");if(l||c){const e=o.nodeAfter&&n.nodeBefore&&o.nodeAfter.parent===n.nodeBefore.parent,i=l&&(!e||!$c(o.nodeAfter,t)),r=c&&(!e||!$c(n.nodeBefore,t));let d=o,u=n;return i&&(d=ql._createBefore(Wc(s,t))),r&&(u=ql._createAfter(Wc(a,t))),new Zl(d,u)}return null}(e,t)}function Wc(e,t){let o=e,n=o;for(;t.isLimit(n)&&n.parent;)o=n,n=n.parent;return o}function $c(e,t){return e&&t.isSelectable(e)}class Gc extends(Y()){constructor(e,t){super(),this.model=e,this.view=new Ml(t),this.mapper=new Jl,this.downcastDispatcher=new Xl({mapper:this.mapper,schema:e.schema});const o=this.model.document,n=o.selection,i=this.model.markers;var s,a,l;this.listenTo(this.model,"_beforeChanges",(()=>{this.view._disableRendering(!0)}),{priority:"highest"}),this.listenTo(this.model,"_afterChanges",(()=>{this.view._disableRendering(!1)}),{priority:"lowest"}),this.listenTo(o,"change",(()=>{this.view.change((e=>{this.downcastDispatcher.convertChanges(o.differ,i,e),this.downcastDispatcher.convertSelection(n,i,e)}))}),{priority:"low"}),this.listenTo(this.view.document,"selectionChange",function(e,t){return(o,n)=>{const i=n.newSelection,r=[];for(const e of i.getRanges())r.push(t.toModelRange(e));const s=e.createSelection(r,{backward:i.isBackward});s.isEqual(e.document.selection)||e.change((e=>{e.setSelection(s)}))}}(this.model,this.mapper)),this.listenTo(this.view.document,"beforeinput",(s=this.mapper,a=this.model.schema,l=this.view,(e,t)=>{if(!l.document.isComposing||r.isAndroid)for(let e=0;e{if(!o.consumable.consume(t.item,e.name))return;const n=o.writer,i=o.mapper.toViewPosition(t.range.start),r=n.createText(t.item.data);n.insert(i,r)}),{priority:"lowest"}),this.downcastDispatcher.on("insert",((e,t,o)=>{o.convertAttributes(t.item),t.reconversion||!t.item.is("element")||t.item.isEmpty||o.convertChildren(t.item)}),{priority:"lowest"}),this.downcastDispatcher.on("remove",((e,t,o)=>{const n=o.mapper.toViewPosition(t.position),i=t.position.getShiftedBy(t.length),r=o.mapper.toViewPosition(i,{isPhantom:!0}),s=o.writer.createRange(n,r),a=o.writer.remove(s.getTrimmed());for(const e of o.writer.createRangeIn(a).getItems())o.mapper.unbindViewElement(e,{defer:!0})}),{priority:"low"}),this.downcastDispatcher.on("cleanSelection",((e,t,o)=>{const n=o.writer,i=n.document.selection;for(const e of i.getRanges())e.isCollapsed&&e.end.parent.isAttached()&&o.writer.mergeAttributes(e.start);n.setSelection(null)})),this.downcastDispatcher.on("selection",((e,t,o)=>{const n=t.selection;if(n.isCollapsed)return;if(!o.consumable.consume(n,"selection"))return;const i=[];for(const e of n.getRanges())i.push(o.mapper.toViewRange(e));o.writer.setSelection(i,{backward:n.isBackward})}),{priority:"low"}),this.downcastDispatcher.on("selection",((e,t,o)=>{const n=t.selection;if(!n.isCollapsed)return;if(!o.consumable.consume(n,"selection"))return;const i=o.writer,r=n.getFirstPosition(),s=o.mapper.toViewPosition(r),a=i.breakAttributes(s);i.setSelection(a)}),{priority:"low"}),this.view.document.roots.bindTo(this.model.document.roots).using((e=>{if("$graveyard"==e.rootName)return null;const t=new Ds(this.view.document,e.name);return t.rootName=e.rootName,this.mapper.bindElements(e,t),t}))}destroy(){this.view.destroy(),this.stopListening()}reconvertMarker(e){const t="string"==typeof e?e:e.name,o=this.model.markers.get(t);if(!o)throw new E("editingcontroller-reconvertmarker-marker-not-exist",this,{markerName:t});this.model.change((()=>{this.model.markers._refresh(o)}))}reconvertItem(e){this.model.change((()=>{this.model.document.differ._refreshItem(e)}))}}class Kc{constructor(){this._consumables=new Map}add(e,t){let o;e.is("$text")||e.is("documentFragment")?this._consumables.set(e,!0):(this._consumables.has(e)?o=this._consumables.get(e):(o=new Jc(e),this._consumables.set(e,o)),o.add(t))}test(e,t){const o=this._consumables.get(e);return void 0===o?null:e.is("$text")||e.is("documentFragment")?o:o.test(t)}consume(e,t){return!!this.test(e,t)&&(e.is("$text")||e.is("documentFragment")?this._consumables.set(e,!1):this._consumables.get(e).consume(t),!0)}revert(e,t){const o=this._consumables.get(e);void 0!==o&&(e.is("$text")||e.is("documentFragment")?this._consumables.set(e,!0):o.revert(t))}static consumablesFromElement(e){const t={element:e,name:!0,attributes:[],classes:[],styles:[]},o=e.getAttributeKeys();for(const e of o)"style"!=e&&"class"!=e&&t.attributes.push(e);const n=e.getClassNames();for(const e of n)t.classes.push(e);const i=e.getStyleNames();for(const e of i)t.styles.push(e);return t}static createFrom(e,t){if(t||(t=new Kc),e.is("$text"))return t.add(e),t;e.is("element")&&t.add(e,Kc.consumablesFromElement(e)),e.is("documentFragment")&&t.add(e);for(const o of e.getChildren())t=Kc.createFrom(o,t);return t}}const Zc=["attributes","classes","styles"];class Jc{constructor(e){this.element=e,this._canConsumeName=null,this._consumables={attributes:new Map,styles:new Map,classes:new Map}}add(e){e.name&&(this._canConsumeName=!0);for(const t of Zc)t in e&&this._add(t,e[t])}test(e){if(e.name&&!this._canConsumeName)return this._canConsumeName;for(const t of Zc)if(t in e){const o=this._test(t,e[t]);if(!0!==o)return o}return!0}consume(e){e.name&&(this._canConsumeName=!1);for(const t of Zc)t in e&&this._consume(t,e[t])}revert(e){e.name&&(this._canConsumeName=!0);for(const t of Zc)t in e&&this._revert(t,e[t])}_add(e,t){const o=xi(t),n=this._consumables[e];for(const t of o){if("attributes"===e&&("class"===t||"style"===t))throw new E("viewconsumable-invalid-attribute",this);if(n.set(t,!0),"styles"===e)for(const e of this.element.document.stylesProcessor.getRelatedStyles(t))n.set(e,!0)}}_test(e,t){const o=xi(t),n=this._consumables[e];for(const t of o)if("attributes"!==e||"class"!==t&&"style"!==t){const e=n.get(t);if(void 0===e)return null;if(!e)return!1}else{const e="class"==t?"classes":"styles",o=this._test(e,[...this._consumables[e].keys()]);if(!0!==o)return o}return!0}_consume(e,t){const o=xi(t),n=this._consumables[e];for(const t of o)if("attributes"!==e||"class"!==t&&"style"!==t){if(n.set(t,!1),"styles"==e)for(const e of this.element.document.stylesProcessor.getRelatedStyles(t))n.set(e,!1)}else{const e="class"==t?"classes":"styles";this._consume(e,[...this._consumables[e].keys()])}}_revert(e,t){const o=xi(t),n=this._consumables[e];for(const t of o)if("attributes"!==e||"class"!==t&&"style"!==t){!1===n.get(t)&&n.set(t,!0)}else{const e="class"==t?"classes":"styles";this._revert(e,[...this._consumables[e].keys()])}}}class Yc extends(Y()){constructor(){super(),this._sourceDefinitions={},this._attributeProperties={},this._customChildChecks=new Map,this._customAttributeChecks=new Map,this._genericCheckSymbol=Symbol("$generic"),this.decorate("checkChild"),this.decorate("checkAttribute"),this.on("checkAttribute",((e,t)=>{t[0]=new Qc(t[0])}),{priority:"highest"}),this.on("checkChild",((e,t)=>{t[0]=new Qc(t[0]),t[1]=this.getDefinition(t[1])}),{priority:"highest"})}register(e,t){if(this._sourceDefinitions[e])throw new E("schema-cannot-register-item-twice",this,{itemName:e});this._sourceDefinitions[e]=[Object.assign({},t)],this._clearCache()}extend(e,t){if(!this._sourceDefinitions[e])throw new E("schema-cannot-extend-missing-item",this,{itemName:e});this._sourceDefinitions[e].push(Object.assign({},t)),this._clearCache()}getDefinitions(){return this._compiledDefinitions||this._compile(),this._compiledDefinitions}getDefinition(e){let t;return t="string"==typeof e?e:"is"in e&&(e.is("$text")||e.is("$textProxy"))?"$text":e.name,this.getDefinitions()[t]}isRegistered(e){return!!this.getDefinition(e)}isBlock(e){const t=this.getDefinition(e);return!(!t||!t.isBlock)}isLimit(e){const t=this.getDefinition(e);return!!t&&!(!t.isLimit&&!t.isObject)}isObject(e){const t=this.getDefinition(e);return!!t&&!!(t.isObject||t.isLimit&&t.isSelectable&&t.isContent)}isInline(e){const t=this.getDefinition(e);return!(!t||!t.isInline)}isSelectable(e){const t=this.getDefinition(e);return!!t&&!(!t.isSelectable&&!t.isObject)}isContent(e){const t=this.getDefinition(e);return!!t&&!(!t.isContent&&!t.isObject)}checkChild(e,t){return!!t&&this._checkContextMatch(e,t)}checkAttribute(e,t){const o=this.getDefinition(e.last);if(!o)return!1;const n=this._evaluateAttributeChecks(e,t);return void 0!==n?n:o.allowAttributes.includes(t)}checkMerge(e,t){if(e instanceof ql){const t=e.nodeBefore,o=e.nodeAfter;if(!(t instanceof Ll))throw new E("schema-check-merge-no-element-before",this);if(!(o instanceof Ll))throw new E("schema-check-merge-no-element-after",this);return this.checkMerge(t,o)}if(this.isLimit(e)||this.isLimit(t))return!1;for(const o of t.getChildren())if(!this.checkChild(e,o))return!1;return!0}addChildCheck(e,t){const o=void 0!==t?t:this._genericCheckSymbol,n=this._customChildChecks.get(o)||[];n.push(e),this._customChildChecks.set(o,n)}addAttributeCheck(e,t){const o=void 0!==t?t:this._genericCheckSymbol,n=this._customAttributeChecks.get(o)||[];n.push(e),this._customAttributeChecks.set(o,n)}setAttributeProperties(e,t){this._attributeProperties[e]=Object.assign(this.getAttributeProperties(e),t)}getAttributeProperties(e){return this._attributeProperties[e]||{}}getLimitElement(e){let t;if(e instanceof ql)t=e.parent;else{t=(e instanceof Zl?[e]:Array.from(e.getRanges())).reduce(((e,t)=>{const o=t.getCommonAncestor();return e?e.getCommonAncestor(o,{includeSelf:!0}):o}),null)}for(;!this.isLimit(t)&&t.parent;)t=t.parent;return t}checkAttributeInSelection(e,t){if(e.isCollapsed){const o=[...e.getFirstPosition().getAncestors(),new Ol("",e.getAttributes())];return this.checkAttribute(o,t)}{const o=e.getRanges();for(const e of o)for(const o of e)if(this.checkAttribute(o.item,t))return!0}return!1}*getValidRanges(e,t){e=function*(e){for(const t of e)yield*t.getMinimalFlatRanges()}(e);for(const o of e)yield*this._getValidRangesForRange(o,t)}getNearestSelectionRange(e,t="both"){if("$graveyard"==e.root.rootName)return null;if(this.checkChild(e,"$text"))return new Zl(e);let o,n;const i=e.getAncestors().reverse().find((e=>this.isLimit(e)))||e.root;"both"!=t&&"backward"!=t||(o=new Hl({boundaries:Zl._createIn(i),startPosition:e,direction:"backward"})),"both"!=t&&"forward"!=t||(n=new Hl({boundaries:Zl._createIn(i),startPosition:e}));for(const e of function*(e,t){let o=!1;for(;!o;){if(o=!0,e){const t=e.next();t.done||(o=!1,yield{walker:e,value:t.value})}if(t){const e=t.next();e.done||(o=!1,yield{walker:t,value:e.value})}}}(o,n)){const t=e.walker==o?"elementEnd":"elementStart",n=e.value;if(n.type==t&&this.isObject(n.item))return Zl._createOn(n.item);if(this.checkChild(n.nextPosition,"$text"))return new Zl(n.nextPosition)}return null}findAllowedParent(e,t){let o=e.parent;for(;o;){if(this.checkChild(o,t))return o;if(this.isLimit(o))return null;o=o.parent}return null}setAllowedAttributes(e,t,o){const n=o.model;for(const[i,r]of Object.entries(t))n.schema.checkAttribute(e,i)&&o.setAttribute(i,r,e)}removeDisallowedAttributes(e,t){for(const o of e)if(o.is("$text"))ud(this,o,t);else{const e=Zl._createIn(o).getPositions();for(const o of e){ud(this,o.nodeBefore||o.parent,t)}}}getAttributesWithProperty(e,t,o){const n={};for(const[i,r]of e.getAttributes()){const e=this.getAttributeProperties(i);void 0!==e[t]&&(void 0!==o&&o!==e[t]||(n[i]=r))}return n}createContext(e){return new Qc(e)}_clearCache(){this._compiledDefinitions=null}_compile(){const e={},t=this._sourceDefinitions,o=Object.keys(t);for(const n of o)e[n]=Xc(t[n],n);const n=Object.values(e);for(const t of n)ed(e,t),td(e,t),od(e,t),nd(e,t);for(const t of n)id(e,t);for(const t of n)rd(e,t);for(const t of n)sd(e,t);for(const t of n)ad(e,t);for(const t of n)ld(e,t);this._compiledDefinitions=function(e){const t={};for(const o of Object.values(e))t[o.name]={name:o.name,isBlock:!!o.isBlock,isContent:!!o.isContent,isInline:!!o.isInline,isLimit:!!o.isLimit,isObject:!!o.isObject,isSelectable:!!o.isSelectable,allowIn:Array.from(o.allowIn).filter((t=>!!e[t])),allowChildren:Array.from(o.allowChildren).filter((t=>!!e[t])),allowAttributes:Array.from(o.allowAttributes)};return t}(e)}_checkContextMatch(e,t){const o=e.last;let n=this._evaluateChildChecks(e,t);if(n=void 0!==n?n:t.allowIn.includes(o.name),!n)return!1;const i=this.getDefinition(o),r=e.trimLast();return!!i&&(0==r.length||this._checkContextMatch(r,i))}_evaluateChildChecks(e,t){const o=this._customChildChecks.get(this._genericCheckSymbol)||[],n=this._customChildChecks.get(t.name)||[];for(const i of[...o,...n]){const o=i(e,t);if(void 0!==o)return o}}_evaluateAttributeChecks(e,t){const o=this._customAttributeChecks.get(this._genericCheckSymbol)||[],n=this._customAttributeChecks.get(t)||[];for(const i of[...o,...n]){const o=i(e,t);if(void 0!==o)return o}}*_getValidRangesForRange(e,t){let o=e.start,n=e.start;for(const i of e.getItems({shallow:!0}))i.is("element")&&(yield*this._getValidRangesForRange(Zl._createIn(i),t)),this.checkAttribute(i,t)||(o.isEqual(n)||(yield new Zl(o,n)),o=ql._createAfter(i)),n=ql._createAfter(i);o.isEqual(n)||(yield new Zl(o,n))}findOptimalInsertionRange(e,t){const o=e.getSelectedElement();if(o&&this.isObject(o)&&!this.isInline(o))return"before"==t||"after"==t?new Zl(ql._createAt(o,t)):Zl._createOn(o);const n=Qi(e.getSelectedBlocks());if(!n)return new Zl(e.focus);if(n.isEmpty)return new Zl(ql._createAt(n,0));const i=ql._createAfter(n);return e.focus.isTouching(i)?new Zl(i):new Zl(ql._createBefore(n))}}class Qc{constructor(e){if(e instanceof Qc)return e;let t;t="string"==typeof e?[e]:Array.isArray(e)?e:e.getAncestors({includeSelf:!0}),this._items=t.map(dd)}get length(){return this._items.length}get last(){return this._items[this._items.length-1]}[Symbol.iterator](){return this._items[Symbol.iterator]()}push(e){const t=new Qc([e]);return t._items=[...this._items,...t._items],t}trimLast(){const e=new Qc([]);return e._items=this._items.slice(0,-1),e}getItem(e){return this._items[e]}*getNames(){yield*this._items.map((e=>e.name))}endsWith(e){return Array.from(this.getNames()).join(" ").endsWith(e)}startsWith(e){return Array.from(this.getNames()).join(" ").startsWith(e)}}function Xc(e,t){const o={name:t,allowIn:new Set,allowChildren:new Set,disallowIn:new Set,disallowChildren:new Set,allowContentOf:new Set,allowWhere:new Set,allowAttributes:new Set,disallowAttributes:new Set,allowAttributesOf:new Set,inheritTypesFrom:new Set};return function(e,t){for(const o of e){const e=Object.keys(o).filter((e=>e.startsWith("is")));for(const n of e)t[n]=!!o[n]}}(e,o),cd(e,o,"allowIn"),cd(e,o,"allowChildren"),cd(e,o,"disallowIn"),cd(e,o,"disallowChildren"),cd(e,o,"allowContentOf"),cd(e,o,"allowWhere"),cd(e,o,"allowAttributes"),cd(e,o,"disallowAttributes"),cd(e,o,"allowAttributesOf"),cd(e,o,"inheritTypesFrom"),function(e,t){for(const o of e){const e=o.inheritAllFrom;e&&(t.allowContentOf.add(e),t.allowWhere.add(e),t.allowAttributesOf.add(e),t.inheritTypesFrom.add(e))}}(e,o),o}function ed(e,t){for(const o of t.allowIn){const n=e[o];n?n.allowChildren.add(t.name):t.allowIn.delete(o)}}function td(e,t){for(const o of t.allowChildren){const n=e[o];n?n.allowIn.add(t.name):t.allowChildren.delete(o)}}function od(e,t){for(const o of t.disallowIn){const n=e[o];n?n.disallowChildren.add(t.name):t.disallowIn.delete(o)}}function nd(e,t){for(const o of t.disallowChildren){const n=e[o];n?n.disallowIn.add(t.name):t.disallowChildren.delete(o)}}function id(e,t){for(const e of t.disallowChildren)t.allowChildren.delete(e);for(const e of t.disallowIn)t.allowIn.delete(e);for(const e of t.disallowAttributes)t.allowAttributes.delete(e)}function rd(e,t){for(const o of t.allowContentOf){const n=e[o];n&&(n.disallowChildren.forEach((o=>{t.allowChildren.has(o)||(t.disallowChildren.add(o),e[o].disallowIn.add(t.name))})),n.allowChildren.forEach((o=>{t.disallowChildren.has(o)||(t.allowChildren.add(o),e[o].allowIn.add(t.name))})))}}function sd(e,t){for(const o of t.allowWhere){const n=e[o];n&&(n.disallowIn.forEach((o=>{t.allowIn.has(o)||(t.disallowIn.add(o),e[o].disallowChildren.add(t.name))})),n.allowIn.forEach((o=>{t.disallowIn.has(o)||(t.allowIn.add(o),e[o].allowChildren.add(t.name))})))}}function ad(e,t){for(const o of t.allowAttributesOf){const n=e[o];if(!n)return;n.allowAttributes.forEach((e=>{t.disallowAttributes.has(e)||t.allowAttributes.add(e)}))}}function ld(e,t){for(const o of t.inheritTypesFrom){const n=e[o];if(n){const e=Object.keys(n).filter((e=>e.startsWith("is")));for(const o of e)o in t||(t[o]=n[o])}}}function cd(e,t,o){for(const n of e){let e=n[o];"string"==typeof e&&(e=[e]),Array.isArray(e)&&e.forEach((e=>t[o].add(e)))}}function dd(e){return"string"==typeof e||e.is("documentFragment")?{name:"string"==typeof e?e:"$documentFragment",*getAttributeKeys(){},getAttribute(){}}:{name:e.is("element")?e.name:"$text",*getAttributeKeys(){yield*e.getAttributeKeys()},getAttribute:t=>e.getAttribute(t)}}function ud(e,t,o){for(const n of t.getAttributeKeys())e.checkAttribute(t,n)||o.removeAttribute(n,t)}class hd extends(z()){constructor(e){super(),this._splitParts=new Map,this._cursorParents=new Map,this._modelCursor=null,this._emptyElementsToKeep=new Set,this.conversionApi={...e,consumable:null,writer:null,store:null,convertItem:(e,t)=>this._convertItem(e,t),convertChildren:(e,t)=>this._convertChildren(e,t),safeInsert:(e,t)=>this._safeInsert(e,t),updateConversionResult:(e,t)=>this._updateConversionResult(e,t),splitToAllowedParent:(e,t)=>this._splitToAllowedParent(e,t),getSplitParts:e=>this._getSplitParts(e),keepEmptyElement:e=>this._keepEmptyElement(e)}}convert(e,t,o=["$root"]){this.fire("viewCleanup",e),this._modelCursor=function(e,t){let o;for(const n of new Qc(e)){const e={};for(const t of n.getAttributeKeys())e[t]=n.getAttribute(t);const i=t.createElement(n.name,e);o&&t.insert(i,o),o=ql._createAt(i,0)}return o}(o,t),this.conversionApi.writer=t,this.conversionApi.consumable=Kc.createFrom(e),this.conversionApi.store={};const{modelRange:n}=this._convertItem(e,this._modelCursor),i=t.createDocumentFragment();if(n){this._removeEmptyElements();for(const e of Array.from(this._modelCursor.parent.getChildren()))t.append(e,i);i.markers=function(e,t){const o=new Set,n=new Map,i=Zl._createIn(e).getItems();for(const e of i)e.is("element","$marker")&&o.add(e);for(const e of o){const o=e.getAttribute("data-name"),i=t.createPositionBefore(e);n.has(o)?n.get(o).end=i.clone():n.set(o,new Zl(i.clone())),t.remove(e)}return n}(i,t)}return this._modelCursor=null,this._splitParts.clear(),this._cursorParents.clear(),this._emptyElementsToKeep.clear(),this.conversionApi.writer=null,this.conversionApi.store=null,i}_convertItem(e,t){const o={viewItem:e,modelCursor:t,modelRange:null};if(e.is("element")?this.fire(`element:${e.name}`,o,this.conversionApi):e.is("$text")?this.fire("text",o,this.conversionApi):this.fire("documentFragment",o,this.conversionApi),o.modelRange&&!(o.modelRange instanceof Zl))throw new E("view-conversion-dispatcher-incorrect-result",this);return{modelRange:o.modelRange,modelCursor:o.modelCursor}}_convertChildren(e,t){let o=t.is("position")?t:ql._createAt(t,0);const n=new Zl(o);for(const t of Array.from(e.getChildren())){const e=this._convertItem(t,o);e.modelRange instanceof Zl&&(n.end=e.modelRange.end,o=e.modelCursor)}return{modelRange:n,modelCursor:o}}_safeInsert(e,t){const o=this._splitToAllowedParent(e,t);return!!o&&(this.conversionApi.writer.insert(e,o.position),!0)}_updateConversionResult(e,t){const o=this._getSplitParts(e),n=this.conversionApi.writer;t.modelRange||(t.modelRange=n.createRange(n.createPositionBefore(e),n.createPositionAfter(o[o.length-1])));const i=this._cursorParents.get(e);t.modelCursor=i?n.createPositionAt(i,0):t.modelRange.end}_splitToAllowedParent(e,t){const{schema:o,writer:n}=this.conversionApi;let i=o.findAllowedParent(t,e);if(i){if(i===t.parent)return{position:t};this._modelCursor.parent.getAncestors().includes(i)&&(i=null)}if(!i)return Mc(t,e,o)?{position:Rc(t,n)}:null;const r=this.conversionApi.writer.split(t,i),s=[];for(const e of r.range.getWalker())if("elementEnd"==e.type)s.push(e.item);else{const t=s.pop(),o=e.item;this._registerSplitPair(t,o)}const a=r.range.end.parent;return this._cursorParents.set(e,a),{position:r.position,cursorParent:a}}_registerSplitPair(e,t){this._splitParts.has(e)||this._splitParts.set(e,[e]);const o=this._splitParts.get(e);this._splitParts.set(t,o),o.push(t)}_getSplitParts(e){let t;return t=this._splitParts.has(e)?this._splitParts.get(e):[e],t}_keepEmptyElement(e){this._emptyElementsToKeep.add(e)}_removeEmptyElements(){let e=!1;for(const t of this._splitParts.keys())t.isEmpty&&!this._emptyElementsToKeep.has(t)&&(this.conversionApi.writer.remove(t),this._splitParts.delete(t),e=!0);e&&this._removeEmptyElements()}}class md{getHtml(e){const o=t.document.implementation.createHTMLDocument("").createElement("div");return o.appendChild(e),o.innerHTML}}class pd{constructor(e){this.skipComments=!0,this.domParser=new DOMParser,this.domConverter=new Pa(e,{renderingMode:"data"}),this.htmlWriter=new md}toData(e){const t=this.domConverter.viewToDom(e);return this.htmlWriter.getHtml(t)}toView(e){const t=this._toDom(e);return this.domConverter.domToView(t,{skipComments:this.skipComments})}registerRawContentMatcher(e){this.domConverter.registerRawContentMatcher(e)}useFillerType(e){this.domConverter.blockFillerMode="marked"==e?"markedNbsp":"nbsp"}_toDom(e){e.match(/<(?:html|body|head|meta)(?:\s[^>]*)?>/i)||(e=`${e}`);const t=this.domParser.parseFromString(e,"text/html"),o=t.createDocumentFragment(),n=t.body.childNodes;for(;n.length>0;)o.appendChild(n[0]);return o}}class gd extends(z()){constructor(e,t){super(),this.model=e,this.mapper=new Jl,this.downcastDispatcher=new Xl({mapper:this.mapper,schema:e.schema}),this.downcastDispatcher.on("insert:$text",((e,t,o)=>{if(!o.consumable.consume(t.item,e.name))return;const n=o.writer,i=o.mapper.toViewPosition(t.range.start),r=n.createText(t.item.data);n.insert(i,r)}),{priority:"lowest"}),this.downcastDispatcher.on("insert",((e,t,o)=>{o.convertAttributes(t.item),t.reconversion||!t.item.is("element")||t.item.isEmpty||o.convertChildren(t.item)}),{priority:"lowest"}),this.upcastDispatcher=new hd({schema:e.schema}),this.viewDocument=new Hs(t),this.stylesProcessor=t,this.htmlProcessor=new pd(this.viewDocument),this.processor=this.htmlProcessor,this._viewWriter=new ea(this.viewDocument),this.upcastDispatcher.on("text",((e,t,{schema:o,consumable:n,writer:i})=>{let r=t.modelCursor;if(!n.test(t.viewItem))return;if(!o.checkChild(r,"$text")){if(!Mc(r,"$text",o))return;if(0==t.viewItem.data.trim().length)return;r=Rc(r,i)}n.consume(t.viewItem);const s=i.createText(t.viewItem.data);i.insert(s,r),t.modelRange=i.createRange(r,r.getShiftedBy(s.offsetSize)),t.modelCursor=t.modelRange.end}),{priority:"lowest"}),this.upcastDispatcher.on("element",((e,t,o)=>{if(!t.modelRange&&o.consumable.consume(t.viewItem,{name:!0})){const{modelRange:e,modelCursor:n}=o.convertChildren(t.viewItem,t.modelCursor);t.modelRange=e,t.modelCursor=n}}),{priority:"lowest"}),this.upcastDispatcher.on("documentFragment",((e,t,o)=>{if(!t.modelRange&&o.consumable.consume(t.viewItem,{name:!0})){const{modelRange:e,modelCursor:n}=o.convertChildren(t.viewItem,t.modelCursor);t.modelRange=e,t.modelCursor=n}}),{priority:"lowest"}),Y().prototype.decorate.call(this,"init"),Y().prototype.decorate.call(this,"set"),Y().prototype.decorate.call(this,"get"),Y().prototype.decorate.call(this,"toView"),Y().prototype.decorate.call(this,"toModel"),this.on("init",(()=>{this.fire("ready")}),{priority:"lowest"}),this.on("ready",(()=>{this.model.enqueueChange({isUndoable:!1},Fc)}),{priority:"lowest"})}get(e={}){const{rootName:t="main",trim:o="empty"}=e;if(!this._checkIfRootsExists([t]))throw new E("datacontroller-get-non-existent-root",this);const n=this.model.document.getRoot(t);return n.isAttached()||D("datacontroller-get-detached-root",this),"empty"!==o||this.model.hasContent(n,{ignoreWhitespaces:!0})?this.stringify(n,e):""}stringify(e,t={}){const o=this.toView(e,t);return this.processor.toData(o)}toView(e,t={}){const o=this.viewDocument,n=this._viewWriter;this.mapper.clearBindings();const i=Zl._createIn(e),r=new Xs(o);this.mapper.bindElements(e,r);const s=e.is("documentFragment")?e.markers:function(e){const t=[],o=e.root.document;if(!o)return new Map;const n=Zl._createIn(e);for(const e of o.model.markers){const o=e.getRange(),i=o.isCollapsed,r=o.start.isEqual(n.start)||o.end.isEqual(n.end);if(i&&r)t.push([e.name,o]);else{const i=n.getIntersection(o);i&&t.push([e.name,i])}}return t.sort((([e,t],[o,n])=>{if("after"!==t.end.compareWith(n.start))return 1;if("before"!==t.start.compareWith(n.end))return-1;switch(t.start.compareWith(n.start)){case"before":return 1;case"after":return-1;default:switch(t.end.compareWith(n.end)){case"before":return 1;case"after":return-1;default:return o.localeCompare(e)}}})),new Map(t)}(e);return this.downcastDispatcher.convert(i,s,n,t),r}init(e){if(this.model.document.version)throw new E("datacontroller-init-document-not-empty",this);let t={};if("string"==typeof e?t.main=e:t=e,!this._checkIfRootsExists(Object.keys(t)))throw new E("datacontroller-init-non-existent-root",this);return this.model.enqueueChange({isUndoable:!1},(e=>{for(const o of Object.keys(t)){const n=this.model.document.getRoot(o);e.insert(this.parse(t[o],n),n,0)}})),Promise.resolve()}set(e,t={}){let o={};if("string"==typeof e?o.main=e:o=e,!this._checkIfRootsExists(Object.keys(o)))throw new E("datacontroller-set-non-existent-root",this);this.model.enqueueChange(t.batchType||{},(e=>{e.setSelection(null),e.removeSelectionAttribute(this.model.document.selection.getAttributeKeys());for(const t of Object.keys(o)){const n=this.model.document.getRoot(t);e.remove(e.createRangeIn(n)),e.insert(this.parse(o[t],n),n,0)}}))}parse(e,t="$root"){const o=this.processor.toView(e);return this.toModel(o,t)}toModel(e,t="$root"){return this.model.change((o=>this.upcastDispatcher.convert(e,o,t)))}addStyleProcessorRules(e){e(this.stylesProcessor)}registerRawContentMatcher(e){this.processor&&this.processor!==this.htmlProcessor&&this.processor.registerRawContentMatcher(e),this.htmlProcessor.registerRawContentMatcher(e)}destroy(){this.stopListening()}_checkIfRootsExists(e){for(const t of e)if(!this.model.document.getRoot(t))return!1;return!0}}class fd{constructor(e,t){this._helpers=new Map,this._downcast=xi(e),this._createConversionHelpers({name:"downcast",dispatchers:this._downcast,isDowncast:!0}),this._upcast=xi(t),this._createConversionHelpers({name:"upcast",dispatchers:this._upcast,isDowncast:!1})}addAlias(e,t){const o=this._downcast.includes(t);if(!this._upcast.includes(t)&&!o)throw new E("conversion-add-alias-dispatcher-not-registered",this);this._createConversionHelpers({name:e,dispatchers:[t],isDowncast:o})}for(e){if(!this._helpers.has(e))throw new E("conversion-for-unknown-group",this);return this._helpers.get(e)}elementToElement(e){this.for("downcast").elementToElement(e);for(const{model:t,view:o}of bd(e))this.for("upcast").elementToElement({model:t,view:o,converterPriority:e.converterPriority})}attributeToElement(e){this.for("downcast").attributeToElement(e);for(const{model:t,view:o}of bd(e))this.for("upcast").elementToAttribute({view:o,model:t,converterPriority:e.converterPriority})}attributeToAttribute(e){this.for("downcast").attributeToAttribute(e);for(const{model:t,view:o}of bd(e))this.for("upcast").attributeToAttribute({view:o,model:t})}_createConversionHelpers({name:e,dispatchers:t,isDowncast:o}){if(this._helpers.has(e))throw new E("conversion-group-exists",this);const n=o?new bc(t):new zc(t);this._helpers.set(e,n)}}function*bd(e){if(e.model.values)for(const t of e.model.values){const o={key:e.model.key,value:t},n=e.view[t],i=e.upcastAlso?e.upcastAlso[t]:void 0;yield*kd(o,n,i)}else yield*kd(e.model,e.view,e.upcastAlso)}function*kd(e,t,o){if(yield{model:e,view:t},o)for(const t of xi(o))yield{model:e,view:t}}class wd{constructor(e){this.baseVersion=e,this.isDocumentOperation=null!==this.baseVersion,this.batch=null}_validate(){}toJSON(){const e=Object.assign({},this);return e.__className=this.constructor.className,delete e.batch,delete e.isDocumentOperation,e}static get className(){return"Operation"}static fromJSON(e,t){return new this(e.baseVersion)}}function _d(e,t){const o=Cd(t),n=o.reduce(((e,t)=>e+t.offsetSize),0),i=e.parent;xd(e);const r=e.index;return i._insertChild(r,o),vd(i,r+o.length),vd(i,r),new Zl(e,e.getShiftedBy(n))}function yd(e){if(!e.isFlat)throw new E("operation-utils-remove-range-not-flat",this);const t=e.start.parent;xd(e.start),xd(e.end);const o=t._removeChildren(e.start.index,e.end.index-e.start.index);return vd(t,e.start.index),o}function Ad(e,t){if(!e.isFlat)throw new E("operation-utils-move-range-not-flat",this);const o=yd(e);return _d(t=t._getTransformedByDeletion(e.start,e.end.offset-e.start.offset),o)}function Cd(e){const t=[];!function e(o){if("string"==typeof o)t.push(new Ol(o));else if(o instanceof Nl)t.push(new Ol(o.data,o.getAttributes()));else if(o instanceof zl)t.push(o);else if(re(o))for(const t of o)e(t);else{}}(e);for(let e=1;ee.maxOffset)throw new E("move-operation-nodes-do-not-exist",this);if(e===t&&o=o&&this.targetPosition.path[e]e._clone(!0)))),t=new Bd(this.position,e,this.baseVersion);return t.shouldReceiveAttributes=this.shouldReceiveAttributes,t}getReversed(){const e=this.position.root.document.graveyard,t=new ql(e,[0]);return new Dd(this.position,this.nodes.maxOffset,t,this.baseVersion+1)}_validate(){const e=this.position.parent;if(!e||e.maxOffsete._clone(!0)))),_d(this.position,e)}toJSON(){const e=super.toJSON();return e.position=this.position.toJSON(),e.nodes=this.nodes.toJSON(),e}static get className(){return"InsertOperation"}static fromJSON(e,t){const o=[];for(const t of e.nodes)t.name?o.push(Ll.fromJSON(t)):o.push(Ol.fromJSON(t));const n=new Bd(ql.fromJSON(e.position,t),o,e.baseVersion);return n.shouldReceiveAttributes=e.shouldReceiveAttributes,n}}class Sd extends wd{constructor(e,t,o,n,i){super(i),this.splitPosition=e.clone(),this.splitPosition.stickiness="toNext",this.howMany=t,this.insertionPosition=o,this.graveyardPosition=n?n.clone():null,this.graveyardPosition&&(this.graveyardPosition.stickiness="toNext")}get type(){return"split"}get moveTargetPosition(){const e=this.insertionPosition.path.slice();return e.push(0),new ql(this.insertionPosition.root,e)}get movedRange(){const e=this.splitPosition.getShiftedBy(Number.POSITIVE_INFINITY);return new Zl(this.splitPosition,e)}get affectedSelectable(){const e=[Zl._createFromPositionAndShift(this.splitPosition,0),Zl._createFromPositionAndShift(this.insertionPosition,0)];return this.graveyardPosition&&e.push(Zl._createFromPositionAndShift(this.graveyardPosition,0)),e}clone(){return new Sd(this.splitPosition,this.howMany,this.insertionPosition,this.graveyardPosition,this.baseVersion)}getReversed(){const e=this.splitPosition.root.document.graveyard,t=new ql(e,[0]);return new Td(this.moveTargetPosition,this.howMany,this.splitPosition,t,this.baseVersion+1)}_validate(){const e=this.splitPosition.parent,t=this.splitPosition.offset;if(!e||e.maxOffset0&&(e.sourcePosition.isEqual(t.sourcePosition.getShiftedBy(t.howMany))&&this._setRelation(e,t,"mergeSourceAffected"),e.targetPosition.isEqual(t.sourcePosition)&&this._setRelation(e,t,"mergeTargetWasBefore"));else if(e instanceof Id){const o=e.newRange;if(!o)return;if(t instanceof Dd){const n=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany),i=n.containsPosition(o.start)||n.start.isEqual(o.start),r=n.containsPosition(o.end)||n.end.isEqual(o.end);!i&&!r||n.containsRange(o)||this._setRelation(e,t,{side:i?"left":"right",path:i?o.start.path.slice():o.end.path.slice()})}else if(t instanceof Td){const n=o.start.isEqual(t.targetPosition),i=o.start.isEqual(t.deletionPosition),r=o.end.isEqual(t.deletionPosition),s=o.end.isEqual(t.sourcePosition);(n||i||r||s)&&this._setRelation(e,t,{wasInLeftElement:n,wasStartBeforeMergedElement:i,wasEndBeforeMergedElement:r,wasInRightElement:s})}}}getContext(e,t,o){return{aIsStrong:o,aWasUndone:this._wasUndone(e),bWasUndone:this._wasUndone(t),abRelation:this._useRelations?this._getRelation(e,t):null,baRelation:this._useRelations?this._getRelation(t,e):null,forceWeakRemove:this._forceWeakRemove}}_wasUndone(e){const t=this.originalOperations.get(e);return t.wasUndone||this._history.isUndoneOperation(t)}_getRelation(e,t){const o=this.originalOperations.get(t),n=this._history.getUndoneOperation(o);if(!n)return null;const i=this.originalOperations.get(e),r=this._relations.get(i);return r&&r.get(n)||null}_setRelation(e,t,o){const n=this.originalOperations.get(e),i=this.originalOperations.get(t);let r=this._relations.get(n);r||(r=new Map,this._relations.set(n,r)),r.set(i,o)}}function $d(e,t){for(const o of e)o.baseVersion=t++}function Gd(e,t){for(let o=0;o{if(e.key===t.key&&e.range.start.hasSameParentAs(t.range.start)){const n=e.range.getDifference(t.range).map((t=>new Fd(t,e.key,e.oldValue,e.newValue,0))),i=e.range.getIntersection(t.range);return i&&o.aIsStrong&&n.push(new Fd(i,t.key,t.newValue,e.newValue,0)),0==n.length?[new Md(0)]:n}return[e]})),Hd(Fd,Bd,((e,t)=>{if(e.range.start.hasSameParentAs(t.position)&&e.range.containsPosition(t.position)){const o=e.range._getTransformedByInsertion(t.position,t.howMany,!t.shouldReceiveAttributes).map((t=>new Fd(t,e.key,e.oldValue,e.newValue,e.baseVersion)));if(t.shouldReceiveAttributes){const n=Kd(t,e.key,e.oldValue);n&&o.unshift(n)}return o}return e.range=e.range._getTransformedByInsertion(t.position,t.howMany,!1)[0],[e]})),Hd(Fd,Td,((e,t)=>{const o=[];e.range.start.hasSameParentAs(t.deletionPosition)&&(e.range.containsPosition(t.deletionPosition)||e.range.start.isEqual(t.deletionPosition))&&o.push(Zl._createFromPositionAndShift(t.graveyardPosition,1));const n=e.range._getTransformedByMergeOperation(t);return n.isCollapsed||o.push(n),o.map((t=>new Fd(t,e.key,e.oldValue,e.newValue,e.baseVersion)))})),Hd(Fd,Dd,((e,t)=>{const o=function(e,t){const o=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany);let n=null,i=[];o.containsRange(e,!0)?n=e:e.start.hasSameParentAs(o.start)?(i=e.getDifference(o),n=e.getIntersection(o)):i=[e];const r=[];for(let e of i){e=e._getTransformedByDeletion(t.sourcePosition,t.howMany);const o=t.getMovedRangeStart(),n=e.start.hasSameParentAs(o),i=e._getTransformedByInsertion(o,t.howMany,n);r.push(...i)}n&&r.push(n._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany,!1)[0]);return r}(e.range,t);return o.map((t=>new Fd(t,e.key,e.oldValue,e.newValue,e.baseVersion)))})),Hd(Fd,Sd,((e,t)=>{if(e.range.end.isEqual(t.insertionPosition))return t.graveyardPosition||e.range.end.offset++,[e];if(e.range.start.hasSameParentAs(t.splitPosition)&&e.range.containsPosition(t.splitPosition)){const o=e.clone();return o.range=new Zl(t.moveTargetPosition.clone(),e.range.end._getCombined(t.splitPosition,t.moveTargetPosition)),e.range.end=t.splitPosition.clone(),e.range.end.stickiness="toPrevious",[e,o]}return e.range=e.range._getTransformedBySplitOperation(t),[e]})),Hd(Bd,Fd,((e,t)=>{const o=[e];if(e.shouldReceiveAttributes&&e.position.hasSameParentAs(t.range.start)&&t.range.containsPosition(e.position)){const n=Kd(e,t.key,t.newValue);n&&o.push(n)}return o})),Hd(Bd,Bd,((e,t,o)=>(e.position.isEqual(t.position)&&o.aIsStrong||(e.position=e.position._getTransformedByInsertOperation(t)),[e]))),Hd(Bd,Dd,((e,t)=>(e.position=e.position._getTransformedByMoveOperation(t),[e]))),Hd(Bd,Sd,((e,t)=>(e.position=e.position._getTransformedBySplitOperation(t),[e]))),Hd(Bd,Td,((e,t)=>(e.position=e.position._getTransformedByMergeOperation(t),[e]))),Hd(Id,Bd,((e,t)=>(e.oldRange&&(e.oldRange=e.oldRange._getTransformedByInsertOperation(t)[0]),e.newRange&&(e.newRange=e.newRange._getTransformedByInsertOperation(t)[0]),[e]))),Hd(Id,Id,((e,t,o)=>{if(e.name==t.name){if(!o.aIsStrong)return[new Md(0)];e.oldRange=t.newRange?t.newRange.clone():null}return[e]})),Hd(Id,Td,((e,t)=>(e.oldRange&&(e.oldRange=e.oldRange._getTransformedByMergeOperation(t)),e.newRange&&(e.newRange=e.newRange._getTransformedByMergeOperation(t)),[e]))),Hd(Id,Dd,((e,t,o)=>{if(e.oldRange&&(e.oldRange=Zl._createFromRanges(e.oldRange._getTransformedByMoveOperation(t))),e.newRange){if(o.abRelation){const n=Zl._createFromRanges(e.newRange._getTransformedByMoveOperation(t));if("left"==o.abRelation.side&&t.targetPosition.isEqual(e.newRange.start))return e.newRange.end=n.end,e.newRange.start.path=o.abRelation.path,[e];if("right"==o.abRelation.side&&t.targetPosition.isEqual(e.newRange.end))return e.newRange.start=n.start,e.newRange.end.path=o.abRelation.path,[e]}e.newRange=Zl._createFromRanges(e.newRange._getTransformedByMoveOperation(t))}return[e]})),Hd(Id,Sd,((e,t,o)=>{if(e.oldRange&&(e.oldRange=e.oldRange._getTransformedBySplitOperation(t)),e.newRange){if(o.abRelation){const n=e.newRange._getTransformedBySplitOperation(t);return e.newRange.start.isEqual(t.splitPosition)&&o.abRelation.wasStartBeforeMergedElement?e.newRange.start=ql._createAt(t.insertionPosition):e.newRange.start.isEqual(t.splitPosition)&&!o.abRelation.wasInLeftElement&&(e.newRange.start=ql._createAt(t.moveTargetPosition)),e.newRange.end.isEqual(t.splitPosition)&&o.abRelation.wasInRightElement?e.newRange.end=ql._createAt(t.moveTargetPosition):e.newRange.end.isEqual(t.splitPosition)&&o.abRelation.wasEndBeforeMergedElement?e.newRange.end=ql._createAt(t.insertionPosition):e.newRange.end=n.end,[e]}e.newRange=e.newRange._getTransformedBySplitOperation(t)}return[e]})),Hd(Td,Bd,((e,t)=>(e.sourcePosition.hasSameParentAs(t.position)&&(e.howMany+=t.howMany),e.sourcePosition=e.sourcePosition._getTransformedByInsertOperation(t),e.targetPosition=e.targetPosition._getTransformedByInsertOperation(t),[e]))),Hd(Td,Td,((e,t,o)=>{if(e.sourcePosition.isEqual(t.sourcePosition)&&e.targetPosition.isEqual(t.targetPosition)){if(o.bWasUndone){const o=t.graveyardPosition.path.slice();return o.push(0),e.sourcePosition=new ql(t.graveyardPosition.root,o),e.howMany=0,[e]}return[new Md(0)]}if(e.sourcePosition.isEqual(t.sourcePosition)&&!e.targetPosition.isEqual(t.targetPosition)&&!o.bWasUndone&&"splitAtSource"!=o.abRelation){const n="$graveyard"==e.targetPosition.root.rootName,i="$graveyard"==t.targetPosition.root.rootName;if(i&&!n||!(n&&!i)&&o.aIsStrong){const o=t.targetPosition._getTransformedByMergeOperation(t),n=e.targetPosition._getTransformedByMergeOperation(t);return[new Dd(o,e.howMany,n,0)]}return[new Md(0)]}return e.sourcePosition.hasSameParentAs(t.targetPosition)&&(e.howMany+=t.howMany),e.sourcePosition=e.sourcePosition._getTransformedByMergeOperation(t),e.targetPosition=e.targetPosition._getTransformedByMergeOperation(t),e.graveyardPosition.isEqual(t.graveyardPosition)&&o.aIsStrong||(e.graveyardPosition=e.graveyardPosition._getTransformedByMergeOperation(t)),[e]})),Hd(Td,Dd,((e,t,o)=>{const n=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany);return"remove"==t.type&&!o.bWasUndone&&!o.forceWeakRemove&&e.deletionPosition.hasSameParentAs(t.sourcePosition)&&n.containsPosition(e.sourcePosition)?[new Md(0)]:(t.sourcePosition.getShiftedBy(t.howMany).isEqual(e.sourcePosition)?e.sourcePosition.stickiness="toNone":t.targetPosition.isEqual(e.sourcePosition)&&"mergeSourceAffected"==o.abRelation?e.sourcePosition.stickiness="toNext":t.sourcePosition.isEqual(e.targetPosition)?(e.targetPosition.stickiness="toNone",e.howMany-=t.howMany):t.targetPosition.isEqual(e.targetPosition)&&"mergeTargetWasBefore"==o.abRelation?(e.targetPosition.stickiness="toPrevious",e.howMany+=t.howMany):(e.sourcePosition.hasSameParentAs(t.targetPosition)&&(e.howMany+=t.howMany),e.sourcePosition.hasSameParentAs(t.sourcePosition)&&(e.howMany-=t.howMany)),e.sourcePosition=e.sourcePosition._getTransformedByMoveOperation(t),e.targetPosition=e.targetPosition._getTransformedByMoveOperation(t),e.sourcePosition.stickiness="toPrevious",e.targetPosition.stickiness="toNext",e.graveyardPosition.isEqual(t.targetPosition)||(e.graveyardPosition=e.graveyardPosition._getTransformedByMoveOperation(t)),[e])})),Hd(Td,Sd,((e,t,o)=>{if(t.graveyardPosition&&(e.graveyardPosition=e.graveyardPosition._getTransformedByDeletion(t.graveyardPosition,1),e.deletionPosition.isEqual(t.graveyardPosition)&&(e.howMany=t.howMany)),e.targetPosition.isEqual(t.splitPosition)){const n=0!=t.howMany,i=t.graveyardPosition&&e.deletionPosition.isEqual(t.graveyardPosition);if(n||i||"mergeTargetNotMoved"==o.abRelation)return e.sourcePosition=e.sourcePosition._getTransformedBySplitOperation(t),[e]}if(e.sourcePosition.isEqual(t.splitPosition)){if("mergeSourceNotMoved"==o.abRelation)return e.howMany=0,e.targetPosition=e.targetPosition._getTransformedBySplitOperation(t),[e];if("mergeSameElement"==o.abRelation||e.sourcePosition.offset>0)return e.sourcePosition=t.moveTargetPosition.clone(),e.targetPosition=e.targetPosition._getTransformedBySplitOperation(t),[e]}return e.sourcePosition.hasSameParentAs(t.splitPosition)&&(e.howMany=t.splitPosition.offset),e.sourcePosition=e.sourcePosition._getTransformedBySplitOperation(t),e.targetPosition=e.targetPosition._getTransformedBySplitOperation(t),[e]})),Hd(Dd,Bd,((e,t)=>{const o=Zl._createFromPositionAndShift(e.sourcePosition,e.howMany)._getTransformedByInsertOperation(t,!1)[0];return e.sourcePosition=o.start,e.howMany=o.end.offset-o.start.offset,e.targetPosition.isEqual(t.position)||(e.targetPosition=e.targetPosition._getTransformedByInsertOperation(t)),[e]})),Hd(Dd,Dd,((e,t,o)=>{const n=Zl._createFromPositionAndShift(e.sourcePosition,e.howMany),i=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany);let r,s=o.aIsStrong,a=!o.aIsStrong;if("insertBefore"==o.abRelation||"insertAfter"==o.baRelation?a=!0:"insertAfter"!=o.abRelation&&"insertBefore"!=o.baRelation||(a=!1),r=e.targetPosition.isEqual(t.targetPosition)&&a?e.targetPosition._getTransformedByDeletion(t.sourcePosition,t.howMany):e.targetPosition._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany),Zd(e,t)&&Zd(t,e))return[t.getReversed()];if(n.containsPosition(t.targetPosition)&&n.containsRange(i,!0))return n.start=n.start._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany),n.end=n.end._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany),Jd([n],r);if(i.containsPosition(e.targetPosition)&&i.containsRange(n,!0))return n.start=n.start._getCombined(t.sourcePosition,t.getMovedRangeStart()),n.end=n.end._getCombined(t.sourcePosition,t.getMovedRangeStart()),Jd([n],r);const l=ie(e.sourcePosition.getParentPath(),t.sourcePosition.getParentPath());if("prefix"==l||"extension"==l)return n.start=n.start._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany),n.end=n.end._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany),Jd([n],r);"remove"!=e.type||"remove"==t.type||o.aWasUndone||o.forceWeakRemove?"remove"==e.type||"remove"!=t.type||o.bWasUndone||o.forceWeakRemove||(s=!1):s=!0;const c=[],d=n.getDifference(i);for(const e of d){e.start=e.start._getTransformedByDeletion(t.sourcePosition,t.howMany),e.end=e.end._getTransformedByDeletion(t.sourcePosition,t.howMany);const o="same"==ie(e.start.getParentPath(),t.getMovedRangeStart().getParentPath()),n=e._getTransformedByInsertion(t.getMovedRangeStart(),t.howMany,o);c.push(...n)}const u=n.getIntersection(i);return null!==u&&s&&(u.start=u.start._getCombined(t.sourcePosition,t.getMovedRangeStart()),u.end=u.end._getCombined(t.sourcePosition,t.getMovedRangeStart()),0===c.length?c.push(u):1==c.length?i.start.isBefore(n.start)||i.start.isEqual(n.start)?c.unshift(u):c.push(u):c.splice(1,0,u)),0===c.length?[new Md(e.baseVersion)]:Jd(c,r)})),Hd(Dd,Sd,((e,t,o)=>{let n=e.targetPosition.clone();e.targetPosition.isEqual(t.insertionPosition)&&t.graveyardPosition&&"moveTargetAfter"!=o.abRelation||(n=e.targetPosition._getTransformedBySplitOperation(t));const i=Zl._createFromPositionAndShift(e.sourcePosition,e.howMany);if(i.end.isEqual(t.insertionPosition))return t.graveyardPosition||e.howMany++,e.targetPosition=n,[e];if(i.start.hasSameParentAs(t.splitPosition)&&i.containsPosition(t.splitPosition)){let e=new Zl(t.splitPosition,i.end);e=e._getTransformedBySplitOperation(t);return Jd([new Zl(i.start,t.splitPosition),e],n)}e.targetPosition.isEqual(t.splitPosition)&&"insertAtSource"==o.abRelation&&(n=t.moveTargetPosition),e.targetPosition.isEqual(t.insertionPosition)&&"insertBetween"==o.abRelation&&(n=e.targetPosition);const r=[i._getTransformedBySplitOperation(t)];if(t.graveyardPosition){const n=i.start.isEqual(t.graveyardPosition)||i.containsPosition(t.graveyardPosition);e.howMany>1&&n&&!o.aWasUndone&&r.push(Zl._createFromPositionAndShift(t.insertionPosition,1))}return Jd(r,n)})),Hd(Dd,Td,((e,t,o)=>{const n=Zl._createFromPositionAndShift(e.sourcePosition,e.howMany);if(t.deletionPosition.hasSameParentAs(e.sourcePosition)&&n.containsPosition(t.sourcePosition))if("remove"!=e.type||o.forceWeakRemove){if(1==e.howMany)return o.bWasUndone?(e.sourcePosition=t.graveyardPosition.clone(),e.targetPosition=e.targetPosition._getTransformedByMergeOperation(t),[e]):[new Md(0)]}else if(!o.aWasUndone){const o=[];let n=t.graveyardPosition.clone(),i=t.targetPosition._getTransformedByMergeOperation(t);e.howMany>1&&(o.push(new Dd(e.sourcePosition,e.howMany-1,e.targetPosition,0)),n=n._getTransformedByMove(e.sourcePosition,e.targetPosition,e.howMany-1),i=i._getTransformedByMove(e.sourcePosition,e.targetPosition,e.howMany-1));const r=t.deletionPosition._getCombined(e.sourcePosition,e.targetPosition),s=new Dd(n,1,r,0),a=s.getMovedRangeStart().path.slice();a.push(0);const l=new ql(s.targetPosition.root,a);i=i._getTransformedByMove(n,r,1);const c=new Dd(i,t.howMany,l,0);return o.push(s),o.push(c),o}const i=Zl._createFromPositionAndShift(e.sourcePosition,e.howMany)._getTransformedByMergeOperation(t);return e.sourcePosition=i.start,e.howMany=i.end.offset-i.start.offset,e.targetPosition=e.targetPosition._getTransformedByMergeOperation(t),[e]})),Hd(Rd,Bd,((e,t)=>(e.position=e.position._getTransformedByInsertOperation(t),[e]))),Hd(Rd,Td,((e,t)=>e.position.isEqual(t.deletionPosition)?(e.position=t.graveyardPosition.clone(),e.position.stickiness="toNext",[e]):(e.position=e.position._getTransformedByMergeOperation(t),[e]))),Hd(Rd,Dd,((e,t)=>(e.position=e.position._getTransformedByMoveOperation(t),[e]))),Hd(Rd,Rd,((e,t,o)=>{if(e.position.isEqual(t.position)){if(!o.aIsStrong)return[new Md(0)];e.oldName=t.newName}return[e]})),Hd(Rd,Sd,((e,t)=>{if("same"==ie(e.position.path,t.splitPosition.getParentPath())&&!t.graveyardPosition){const t=new Rd(e.position.getShiftedBy(1),e.oldName,e.newName,0);return[e,t]}return e.position=e.position._getTransformedBySplitOperation(t),[e]})),Hd(zd,zd,((e,t,o)=>{if(e.root===t.root&&e.key===t.key){if(!o.aIsStrong||e.newValue===t.newValue)return[new Md(0)];e.oldValue=t.newValue}return[e]})),Hd(Vd,Vd,((e,t)=>e.rootName===t.rootName&&e.isAdd===t.isAdd?[new Md(0)]:[e])),Hd(Sd,Bd,((e,t)=>(e.splitPosition.hasSameParentAs(t.position)&&e.splitPosition.offset{if(!e.graveyardPosition&&!o.bWasUndone&&e.splitPosition.hasSameParentAs(t.sourcePosition)){const o=t.graveyardPosition.path.slice();o.push(0);const n=new ql(t.graveyardPosition.root,o),i=Sd.getInsertionPosition(new ql(t.graveyardPosition.root,o)),r=new Sd(n,0,i,null,0);return e.splitPosition=e.splitPosition._getTransformedByMergeOperation(t),e.insertionPosition=Sd.getInsertionPosition(e.splitPosition),e.graveyardPosition=r.insertionPosition.clone(),e.graveyardPosition.stickiness="toNext",[r,e]}return e.splitPosition.hasSameParentAs(t.deletionPosition)&&!e.splitPosition.isAfter(t.deletionPosition)&&e.howMany--,e.splitPosition.hasSameParentAs(t.targetPosition)&&(e.howMany+=t.howMany),e.splitPosition=e.splitPosition._getTransformedByMergeOperation(t),e.insertionPosition=Sd.getInsertionPosition(e.splitPosition),e.graveyardPosition&&(e.graveyardPosition=e.graveyardPosition._getTransformedByMergeOperation(t)),[e]})),Hd(Sd,Dd,((e,t,o)=>{const n=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany);if(e.graveyardPosition){const i=n.start.isEqual(e.graveyardPosition)||n.containsPosition(e.graveyardPosition);if(!o.bWasUndone&&i){const o=e.splitPosition._getTransformedByMoveOperation(t),n=e.graveyardPosition._getTransformedByMoveOperation(t),i=n.path.slice();i.push(0);const r=new ql(n.root,i);return[new Dd(o,e.howMany,r,0)]}e.graveyardPosition=e.graveyardPosition._getTransformedByMoveOperation(t)}const i=e.splitPosition.isEqual(t.targetPosition);if(i&&("insertAtSource"==o.baRelation||"splitBefore"==o.abRelation))return e.howMany+=t.howMany,e.splitPosition=e.splitPosition._getTransformedByDeletion(t.sourcePosition,t.howMany),e.insertionPosition=Sd.getInsertionPosition(e.splitPosition),[e];if(i&&o.abRelation&&o.abRelation.howMany){const{howMany:t,offset:n}=o.abRelation;return e.howMany+=t,e.splitPosition=e.splitPosition.getShiftedBy(n),[e]}if(e.splitPosition.hasSameParentAs(t.sourcePosition)&&n.containsPosition(e.splitPosition)){const o=t.howMany-(e.splitPosition.offset-t.sourcePosition.offset);return e.howMany-=o,e.splitPosition.hasSameParentAs(t.targetPosition)&&e.splitPosition.offset{if(e.splitPosition.isEqual(t.splitPosition)){if(!e.graveyardPosition&&!t.graveyardPosition)return[new Md(0)];if(e.graveyardPosition&&t.graveyardPosition&&e.graveyardPosition.isEqual(t.graveyardPosition))return[new Md(0)];if("splitBefore"==o.abRelation)return e.howMany=0,e.graveyardPosition=e.graveyardPosition._getTransformedBySplitOperation(t),[e]}if(e.graveyardPosition&&t.graveyardPosition&&e.graveyardPosition.isEqual(t.graveyardPosition)){const n="$graveyard"==e.splitPosition.root.rootName,i="$graveyard"==t.splitPosition.root.rootName;if(i&&!n||!(n&&!i)&&o.aIsStrong){const o=[];return t.howMany&&o.push(new Dd(t.moveTargetPosition,t.howMany,t.splitPosition,0)),e.howMany&&o.push(new Dd(e.splitPosition,e.howMany,e.moveTargetPosition,0)),o}return[new Md(0)]}if(e.graveyardPosition&&(e.graveyardPosition=e.graveyardPosition._getTransformedBySplitOperation(t)),e.splitPosition.isEqual(t.insertionPosition)&&"splitBefore"==o.abRelation)return e.howMany++,[e];if(t.splitPosition.isEqual(e.insertionPosition)&&"splitBefore"==o.baRelation){const o=t.insertionPosition.path.slice();o.push(0);const n=new ql(t.insertionPosition.root,o);return[e,new Dd(e.insertionPosition,1,n,0)]}return e.splitPosition.hasSameParentAs(t.splitPosition)&&e.splitPosition.offset{const o=t[0];o.isDocumentOperation&&Xd.call(this,o)}),{priority:"low"})}function Xd(e){const t=this.getTransformedByOperation(e);if(!this.isEqual(t)){const e=this.toPosition();this.path=t.path,this.root=t.root,this.fire("change",e)}}Yd.prototype.is=function(e){return"livePosition"===e||"model:livePosition"===e||"position"==e||"model:position"===e};class eu{constructor(e={}){"string"==typeof e&&(e="transparent"===e?{isUndoable:!1}:{},D("batch-constructor-deprecated-string-type"));const{isUndoable:t=!0,isLocal:o=!0,isUndo:n=!1,isTyping:i=!1}=e;this.operations=[],this.isUndoable=t,this.isLocal=o,this.isUndo=n,this.isTyping=i}get type(){return D("batch-type-deprecated"),"default"}get baseVersion(){for(const e of this.operations)if(null!==e.baseVersion)return e.baseVersion;return null}addOperation(e){return e.batch=this,this.operations.push(e),e}}class tu{constructor(e){this._changesInElement=new Map,this._elementsSnapshots=new Map,this._elementChildrenSnapshots=new Map,this._elementState=new Map,this._changedMarkers=new Map,this._changedRoots=new Map,this._changeCount=0,this._cachedChanges=null,this._cachedChangesWithGraveyard=null,this._refreshedItems=new Set,this._markerCollection=e}get isEmpty(){return 0==this._changesInElement.size&&0==this._changedMarkers.size&&0==this._changedRoots.size}bufferOperation(e){const t=e;switch(t.type){case"insert":if(this._isInInsertedElement(t.position.parent))return;this._markInsert(t.position.parent,t.position.offset,t.nodes.maxOffset);break;case"addAttribute":case"removeAttribute":case"changeAttribute":for(const e of t.range.getItems({shallow:!0}))this._isInInsertedElement(e.parent)||this._markAttribute(e);break;case"remove":case"move":case"reinsert":{if(t.sourcePosition.isEqual(t.targetPosition)||t.sourcePosition.getShiftedBy(t.howMany).isEqual(t.targetPosition))return;const e=this._isInInsertedElement(t.sourcePosition.parent),o=this._isInInsertedElement(t.targetPosition.parent);e||this._markRemove(t.sourcePosition.parent,t.sourcePosition.offset,t.howMany),o||this._markInsert(t.targetPosition.parent,t.getMovedRangeStart().offset,t.howMany);const n=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany);for(const e of n.getItems({shallow:!0}))this._setElementState(e,"move");break}case"rename":{if(this._isInInsertedElement(t.position.parent))return;this._markRemove(t.position.parent,t.position.offset,1),this._markInsert(t.position.parent,t.position.offset,1);const e=Zl._createFromPositionAndShift(t.position,1);for(const t of this._markerCollection.getMarkersIntersectingRange(e)){const e=t.getData();this.bufferMarkerChange(t.name,e,e)}this._setElementState(t.position.nodeAfter,"rename");break}case"split":{const e=t.splitPosition.parent;if(!this._isInInsertedElement(e)){this._markRemove(e,t.splitPosition.offset,t.howMany);const o=Zl._createFromPositionAndShift(t.splitPosition,t.howMany);for(const e of o.getItems({shallow:!0}))this._setElementState(e,"move")}this._isInInsertedElement(t.insertionPosition.parent)||this._markInsert(t.insertionPosition.parent,t.insertionPosition.offset,1),t.graveyardPosition&&(this._markRemove(t.graveyardPosition.parent,t.graveyardPosition.offset,1),this._setElementState(t.graveyardPosition.nodeAfter,"move"));break}case"merge":{const e=t.sourcePosition.parent;this._isInInsertedElement(e.parent)||this._markRemove(e.parent,e.startOffset,1);const o=t.graveyardPosition.parent;this._markInsert(o,t.graveyardPosition.offset,1),this._setElementState(e,"move");const n=t.targetPosition.parent;if(!this._isInInsertedElement(n)){this._markInsert(n,t.targetPosition.offset,e.maxOffset);const o=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany);for(const e of o.getItems({shallow:!0}))this._setElementState(e,"move")}break}case"detachRoot":case"addRoot":{const e=t.affectedSelectable;if(!e._isLoaded)return;if(e.isAttached()==t.isAdd)return;this._bufferRootStateChange(t.rootName,t.isAdd);break}case"addRootAttribute":case"removeRootAttribute":case"changeRootAttribute":{if(!t.root._isLoaded)return;const e=t.root.rootName;this._bufferRootAttributeChange(e,t.key,t.oldValue,t.newValue);break}}this._cachedChanges=null}bufferMarkerChange(e,t,o){t.range&&t.range.root.is("rootElement")&&!t.range.root._isLoaded&&(t.range=null),o.range&&o.range.root.is("rootElement")&&!o.range.root._isLoaded&&(o.range=null);let n=this._changedMarkers.get(e);n?n.newMarkerData=o:(n={newMarkerData:o,oldMarkerData:t},this._changedMarkers.set(e,n)),null==n.oldMarkerData.range&&null==o.range&&this._changedMarkers.delete(e)}getMarkersToRemove(){const e=[];for(const[t,o]of this._changedMarkers)null!=o.oldMarkerData.range&&e.push({name:t,range:o.oldMarkerData.range});return e}getMarkersToAdd(){const e=[];for(const[t,o]of this._changedMarkers)null!=o.newMarkerData.range&&e.push({name:t,range:o.newMarkerData.range});return e}getChangedMarkers(){return Array.from(this._changedMarkers).map((([e,t])=>({name:e,data:{oldRange:t.oldMarkerData.range,newRange:t.newMarkerData.range}})))}hasDataChanges(){if(this.getChanges().length)return!0;if(this._changedRoots.size>0)return!0;for(const{newMarkerData:e,oldMarkerData:t}of this._changedMarkers.values()){if(e.affectsData!==t.affectsData)return!0;if(e.affectsData){const o=e.range&&!t.range,n=!e.range&&t.range,i=e.range&&t.range&&!e.range.isEqual(t.range);if(o||n||i)return!0}}return!1}getChanges(e={}){if(this._cachedChanges)return e.includeChangesInGraveyard?this._cachedChangesWithGraveyard.slice():this._cachedChanges.slice();let t=[];for(const e of this._changesInElement.keys()){const o=this._changesInElement.get(e).sort(((e,t)=>e.offset===t.offset?e.type!=t.type?"remove"==e.type?-1:1:0:e.offsete.position.root!=t.position.root?e.position.root.rootNamee));for(const e of t)delete e.changeCount,"attribute"==e.type&&(delete e.position,delete e.length);return this._changeCount=0,this._cachedChangesWithGraveyard=t,this._cachedChanges=t.filter(su),e.includeChangesInGraveyard?this._cachedChangesWithGraveyard.slice():this._cachedChanges.slice()}getChangedRoots(){return Array.from(this._changedRoots.values()).map((e=>{const t={...e};return void 0!==t.state&&delete t.attributes,t}))}getRefreshedItems(){return new Set(this._refreshedItems)}reset(){this._changesInElement.clear(),this._elementChildrenSnapshots.clear(),this._elementsSnapshots.clear(),this._elementState.clear(),this._changedMarkers.clear(),this._changedRoots.clear(),this._refreshedItems.clear(),this._cachedChanges=null}_refreshItem(e){if(this._isInInsertedElement(e.parent))return;this._markRemove(e.parent,e.startOffset,e.offsetSize),this._markInsert(e.parent,e.startOffset,e.offsetSize),this._refreshedItems.add(e),this._setElementState(e,"refresh");const t=Zl._createOn(e);for(const e of this._markerCollection.getMarkersIntersectingRange(t)){const t=e.getData();this.bufferMarkerChange(e.name,t,t)}this._cachedChanges=null}_bufferRootLoad(e){if(e.isAttached()){this._bufferRootStateChange(e.rootName,!0),this._markInsert(e,0,e.maxOffset);for(const t of e.getAttributeKeys())this._bufferRootAttributeChange(e.rootName,t,null,e.getAttribute(t));for(const t of this._markerCollection)if(t.getRange().root==e){const e=t.getData();this.bufferMarkerChange(t.name,{...e,range:null},e)}}}_bufferRootStateChange(e,t){if(!this._changedRoots.has(e))return void this._changedRoots.set(e,{name:e,state:t?"attached":"detached"});const o=this._changedRoots.get(e);void 0!==o.state?(delete o.state,void 0===o.attributes&&this._changedRoots.delete(e)):o.state=t?"attached":"detached"}_bufferRootAttributeChange(e,t,o,n){const i=this._changedRoots.get(e)||{name:e},r=i.attributes||{};if(r[t]){const e=r[t];n===e.oldValue?delete r[t]:e.newValue=n}else r[t]={oldValue:o,newValue:n};0===Object.entries(r).length?(delete i.attributes,void 0===i.state&&this._changedRoots.delete(e)):(i.attributes=r,this._changedRoots.set(e,i))}_markInsert(e,t,o){if(e.root.is("rootElement")&&!e.root._isLoaded)return;const n={type:"insert",offset:t,howMany:o,count:this._changeCount++};this._markChange(e,n)}_markRemove(e,t,o){if(e.root.is("rootElement")&&!e.root._isLoaded)return;const n={type:"remove",offset:t,howMany:o,count:this._changeCount++};this._markChange(e,n),this._removeAllNestedChanges(e,t,o)}_markAttribute(e){if(e.root.is("rootElement")&&!e.root._isLoaded)return;const t={type:"attribute",offset:e.startOffset,howMany:e.offsetSize,count:this._changeCount++};this._markChange(e.parent,t)}_markChange(e,t){this._makeSnapshots(e);const o=this._getChangesForElement(e);this._handleChange(t,o),o.push(t);for(let e=0;eo&&this._elementState.set(e,t)}_getDiffActionForNode(e,t){if(!e.is("element"))return t;if(!this._elementsSnapshots.has(e))return t;const o=this._elementState.get(e);return o&&"move"!=o?o:t}_getChangesForElement(e){let t;return this._changesInElement.has(e)?t=this._changesInElement.get(e):(t=[],this._changesInElement.set(e,t)),t}_makeSnapshots(e){if(this._elementChildrenSnapshots.has(e))return;const t=iu(e.getChildren());this._elementChildrenSnapshots.set(e,t);for(const e of t)this._elementsSnapshots.set(e.node,e)}_handleChange(e,t){e.nodesToHandle=e.howMany;for(const o of t){const n=e.offset+e.howMany,i=o.offset+o.howMany;if("insert"==e.type&&("insert"==o.type&&(e.offset<=o.offset?o.offset+=e.howMany:e.offseto.offset){if(n>i){const e={type:"attribute",offset:i,howMany:n-i,count:this._changeCount++};this._handleChange(e,t),t.push(e)}e.nodesToHandle=o.offset-e.offset,e.howMany=e.nodesToHandle}else e.offset>=o.offset&&e.offseti?(e.nodesToHandle=n-i,e.offset=i):e.nodesToHandle=0);if("remove"==o.type&&e.offseto.offset){const i={type:"attribute",offset:o.offset,howMany:n-o.offset,count:this._changeCount++};this._handleChange(i,t),t.push(i),e.nodesToHandle=o.offset-e.offset,e.howMany=e.nodesToHandle}"attribute"==o.type&&(e.offset>=o.offset&&n<=i?(e.nodesToHandle=0,e.howMany=0,e.offset=0):e.offset<=o.offset&&n>=i&&(o.howMany=0))}}e.howMany=e.nodesToHandle,delete e.nodesToHandle}_getInsertDiff(e,t,o,n,i){const r={type:"insert",position:ql._createAt(e,t),name:n.name,attributes:new Map(n.attributes),length:1,changeCount:this._changeCount++,action:o};return"insert"!=o&&i&&(r.before={name:i.name,attributes:new Map(i.attributes)}),r}_getRemoveDiff(e,t,o,n){return{type:"remove",action:o,position:ql._createAt(e,t),name:n.name,attributes:new Map(n.attributes),length:1,changeCount:this._changeCount++}}_getAttributesDiff(e,t,o){const n=[];o=new Map(o);for(const[i,r]of t){const t=o.has(i)?o.get(i):null;t!==r&&n.push({type:"attribute",position:e.start,range:e.clone(),length:1,attributeKey:i,attributeOldValue:r,attributeNewValue:t,changeCount:this._changeCount++}),o.delete(i)}for(const[t,i]of o)n.push({type:"attribute",position:e.start,range:e.clone(),length:1,attributeKey:t,attributeOldValue:null,attributeNewValue:i,changeCount:this._changeCount++});return n}_isInInsertedElement(e){const t=e.parent;if(!t)return!1;const o=this._changesInElement.get(t),n=e.startOffset;if(o)for(const e of o)if("insert"==e.type&&n>=e.offset&&nn){for(let t=0;tthis._version+1&&this._gaps.set(this._version,e),this._version=e}get lastOperation(){return this._operations[this._operations.length-1]}addOperation(e){if(e.baseVersion!==this.version)throw new E("model-document-history-addoperation-incorrect-version",this,{operation:e,historyVersion:this.version});this._operations.push(e),this._version++,this._baseVersionToOperationIndex.set(e.baseVersion,this._operations.length-1)}getOperations(e,t=this.version){if(!this._operations.length)return[];const o=this._operations[0];void 0===e&&(e=o.baseVersion);let n=t-1;for(const[t,o]of this._gaps)e>t&&et&&nthis.lastOperation.baseVersion)return[];let i=this._baseVersionToOperationIndex.get(e);void 0===i&&(i=0);let r=this._baseVersionToOperationIndex.get(n);return void 0===r&&(r=this._operations.length-1),this._operations.slice(i,r+1)}getOperation(e){const t=this._baseVersionToOperationIndex.get(e);if(void 0!==t)return this._operations[t]}setOperationAsUndone(e,t){this._undoPairs.set(t,e),this._undoneOperations.add(e)}isUndoingOperation(e){return this._undoPairs.has(e)}isUndoneOperation(e){return this._undoneOperations.has(e)}getUndoneOperation(e){return this._undoPairs.get(e)}reset(){this._version=0,this._undoPairs=new Map,this._operations=[],this._undoneOperations=new Set,this._gaps=new Map,this._baseVersionToOperationIndex=new Map}}class lu extends Ll{constructor(e,t,o="main"){super(t),this._isAttached=!0,this._isLoaded=!0,this._document=e,this.rootName=o}get document(){return this._document}isAttached(){return this._isAttached}toJSON(){return this.rootName}}lu.prototype.is=function(e,t){return t?t===this.name&&("rootElement"===e||"model:rootElement"===e||"element"===e||"model:element"===e):"rootElement"===e||"model:rootElement"===e||"element"===e||"model:element"===e||"node"===e||"model:node"===e};const cu="$graveyard";class du extends(z()){constructor(e){super(),this.model=e,this.history=new au,this.selection=new mc(this),this.roots=new Yi({idProperty:"rootName"}),this.differ=new ou(e.markers),this.isReadOnly=!1,this._postFixers=new Set,this._hasSelectionChangedFromTheLastChangeBlock=!1,this.createRoot("$root",cu),this.listenTo(e,"applyOperation",((e,t)=>{const o=t[0];o.isDocumentOperation&&this.differ.bufferOperation(o)}),{priority:"high"}),this.listenTo(e,"applyOperation",((e,t)=>{const o=t[0];o.isDocumentOperation&&this.history.addOperation(o)}),{priority:"low"}),this.listenTo(this.selection,"change",(()=>{this._hasSelectionChangedFromTheLastChangeBlock=!0})),this.listenTo(e.markers,"update",((e,t,o,n,i)=>{const r={...t.getData(),range:n};this.differ.bufferMarkerChange(t.name,i,r),null===o&&t.on("change",((e,o)=>{const n=t.getData();this.differ.bufferMarkerChange(t.name,{...n,range:o},n)}))})),this.registerPostFixer((e=>{let t=!1;for(const o of this.roots)o.isAttached()||o.isEmpty||(e.remove(e.createRangeIn(o)),t=!0);for(const o of this.model.markers)o.getRange().root.isAttached()||(e.removeMarker(o),t=!0);return t}))}get version(){return this.history.version}set version(e){this.history.version=e}get graveyard(){return this.getRoot(cu)}createRoot(e="$root",t="main"){if(this.roots.get(t))throw new E("model-document-createroot-name-exists",this,{name:t});const o=new lu(this,e,t);return this.roots.add(o),o}destroy(){this.selection.destroy(),this.stopListening()}getRoot(e="main"){return this.roots.get(e)}getRootNames(e=!1){return this.getRoots(e).map((e=>e.rootName))}getRoots(e=!1){return this.roots.filter((t=>t!=this.graveyard&&(e||t.isAttached())&&t._isLoaded))}registerPostFixer(e){this._postFixers.add(e)}toJSON(){const e=Vr(this);return e.selection="[engine.model.DocumentSelection]",e.model="[engine.model.Model]",e}_handleChangeBlock(e){this._hasDocumentChangedFromTheLastChangeBlock()&&(this._callPostFixers(e),this.selection.refresh(),this.differ.hasDataChanges()?this.fire("change:data",e.batch):this.fire("change",e.batch),this.selection.refresh(),this.differ.reset()),this._hasSelectionChangedFromTheLastChangeBlock=!1}_hasDocumentChangedFromTheLastChangeBlock(){return!this.differ.isEmpty||this._hasSelectionChangedFromTheLastChangeBlock}_getDefaultRoot(){const e=this.getRoots();return e.length?e[0]:this.graveyard}_getDefaultRange(){const e=this._getDefaultRoot(),t=this.model,o=t.schema,n=t.createPositionFromPath(e,[0]);return o.getNearestSelectionRange(n)||t.createRange(n)}_validateSelectionRange(e){return uu(e.start)&&uu(e.end)}_callPostFixers(e){let t=!1;do{for(const o of this._postFixers)if(this.selection.refresh(),t=o(e),t)break}while(t)}}function uu(e){const t=e.textNode;if(t){const o=t.data,n=e.offset-t.startOffset;return!nr(o,n)&&!ir(o,n)}return!0}class hu extends(z()){constructor(){super(...arguments),this._markers=new Map}[Symbol.iterator](){return this._markers.values()}has(e){const t=e instanceof mu?e.name:e;return this._markers.has(t)}get(e){return this._markers.get(e)||null}_set(e,t,o=!1,n=!1){const i=e instanceof mu?e.name:e;if(i.includes(","))throw new E("markercollection-incorrect-marker-name",this);const r=this._markers.get(i);if(r){const e=r.getData(),s=r.getRange();let a=!1;return s.isEqual(t)||(r._attachLiveRange(cc.fromRange(t)),a=!0),o!=r.managedUsingOperations&&(r._managedUsingOperations=o,a=!0),"boolean"==typeof n&&n!=r.affectsData&&(r._affectsData=n,a=!0),a&&this.fire(`update:${i}`,r,s,t,e),r}const s=cc.fromRange(t),a=new mu(i,s,o,n);return this._markers.set(i,a),this.fire(`update:${i}`,a,null,t,{...a.getData(),range:null}),a}_remove(e){const t=e instanceof mu?e.name:e,o=this._markers.get(t);return!!o&&(this._markers.delete(t),this.fire(`update:${t}`,o,o.getRange(),null,o.getData()),this._destroyMarker(o),!0)}_refresh(e){const t=e instanceof mu?e.name:e,o=this._markers.get(t);if(!o)throw new E("markercollection-refresh-marker-not-exists",this);const n=o.getRange();this.fire(`update:${t}`,o,n,n,o.getData())}*getMarkersAtPosition(e){for(const t of this)t.getRange().containsPosition(e)&&(yield t)}*getMarkersIntersectingRange(e){for(const t of this)null!==t.getRange().getIntersection(e)&&(yield t)}destroy(){for(const e of this._markers.values())this._destroyMarker(e);this._markers=null,this.stopListening()}*getMarkersGroup(e){for(const t of this._markers.values())t.name.startsWith(e+":")&&(yield t)}_destroyMarker(e){e.stopListening(),e._detachLiveRange()}}class mu extends(z(Rl)){constructor(e,t,o,n){super(),this.name=e,this._liveRange=this._attachLiveRange(t),this._managedUsingOperations=o,this._affectsData=n}get managedUsingOperations(){if(!this._liveRange)throw new E("marker-destroyed",this);return this._managedUsingOperations}get affectsData(){if(!this._liveRange)throw new E("marker-destroyed",this);return this._affectsData}getData(){return{range:this.getRange(),affectsData:this.affectsData,managedUsingOperations:this.managedUsingOperations}}getStart(){if(!this._liveRange)throw new E("marker-destroyed",this);return this._liveRange.start.clone()}getEnd(){if(!this._liveRange)throw new E("marker-destroyed",this);return this._liveRange.end.clone()}getRange(){if(!this._liveRange)throw new E("marker-destroyed",this);return this._liveRange.toRange()}_attachLiveRange(e){return this._liveRange&&this._detachLiveRange(),e.delegate("change:range").to(this),e.delegate("change:content").to(this),this._liveRange=e,e}_detachLiveRange(){this._liveRange.stopDelegating("change:range",this),this._liveRange.stopDelegating("change:content",this),this._liveRange.detach(),this._liveRange=null}}mu.prototype.is=function(e){return"marker"===e||"model:marker"===e};class pu extends wd{constructor(e,t){super(null),this.sourcePosition=e.clone(),this.howMany=t}get type(){return"detach"}get affectedSelectable(){return null}toJSON(){const e=super.toJSON();return e.sourcePosition=this.sourcePosition.toJSON(),e}_validate(){if(this.sourcePosition.root.document)throw new E("detach-operation-on-document-node",this)}_execute(){yd(Zl._createFromPositionAndShift(this.sourcePosition,this.howMany))}static get className(){return"DetachOperation"}}class gu extends Rl{constructor(e){super(),this.markers=new Map,this._children=new Vl,e&&this._insertChild(0,e)}[Symbol.iterator](){return this.getChildren()}get childCount(){return this._children.length}get maxOffset(){return this._children.maxOffset}get isEmpty(){return 0===this.childCount}get nextSibling(){return null}get previousSibling(){return null}get root(){return this}get parent(){return null}get document(){return null}isAttached(){return!1}getAncestors(){return[]}getChild(e){return this._children.getNode(e)}getChildren(){return this._children[Symbol.iterator]()}getChildIndex(e){return this._children.getNodeIndex(e)}getChildStartOffset(e){return this._children.getNodeStartOffset(e)}getPath(){return[]}getNodeByPath(e){let t=this;for(const o of e)t=t.getChild(t.offsetToIndex(o));return t}offsetToIndex(e){return this._children.offsetToIndex(e)}toJSON(){const e=[];for(const t of this._children)e.push(t.toJSON());return e}static fromJSON(e){const t=[];for(const o of e)o.name?t.push(Ll.fromJSON(o)):t.push(Ol.fromJSON(o));return new gu(t)}_appendChild(e){this._insertChild(this.childCount,e)}_insertChild(e,t){const o=function(e){if("string"==typeof e)return[new Ol(e)];re(e)||(e=[e]);return Array.from(e).map((e=>"string"==typeof e?new Ol(e):e instanceof Nl?new Ol(e.data,e.getAttributes()):e))}(t);for(const e of o)null!==e.parent&&e._remove(),e.parent=this;this._children._insertNodes(e,o)}_removeChildren(e,t=1){const o=this._children._removeNodes(e,t);for(const e of o)e.parent=null;return o}}gu.prototype.is=function(e){return"documentFragment"===e||"model:documentFragment"===e};class fu{constructor(e,t){this.model=e,this.batch=t}createText(e,t){return new Ol(e,t)}createElement(e,t){return new Ll(e,t)}createDocumentFragment(){return new gu}cloneElement(e,t=!0){return e._clone(t)}insert(e,t,o=0){if(this._assertWriterUsedCorrectly(),e instanceof Ol&&""==e.data)return;const n=ql._createAt(t,o);if(e.parent){if(yu(e.root,n.root))return void this.move(Zl._createOn(e),n);if(e.root.document)throw new E("model-writer-insert-forbidden-move",this);this.remove(e)}const i=n.root.document?n.root.document.version:null,r=new Bd(n,e,i);if(e instanceof Ol&&(r.shouldReceiveAttributes=!0),this.batch.addOperation(r),this.model.applyOperation(r),e instanceof gu)for(const[t,o]of e.markers){const e=ql._createAt(o.root,0),i={range:new Zl(o.start._getCombined(e,n),o.end._getCombined(e,n)),usingOperation:!0,affectsData:!0};this.model.markers.has(t)?this.updateMarker(t,i):this.addMarker(t,i)}}insertText(e,t,o,n){t instanceof gu||t instanceof Ll||t instanceof ql?this.insert(this.createText(e),t,o):this.insert(this.createText(e,t),o,n)}insertElement(e,t,o,n){t instanceof gu||t instanceof Ll||t instanceof ql?this.insert(this.createElement(e),t,o):this.insert(this.createElement(e,t),o,n)}append(e,t){this.insert(e,t,"end")}appendText(e,t,o){t instanceof gu||t instanceof Ll?this.insert(this.createText(e),t,"end"):this.insert(this.createText(e,t),o,"end")}appendElement(e,t,o){t instanceof gu||t instanceof Ll?this.insert(this.createElement(e),t,"end"):this.insert(this.createElement(e,t),o,"end")}setAttribute(e,t,o){if(this._assertWriterUsedCorrectly(),o instanceof Zl){const n=o.getMinimalFlatRanges();for(const o of n)bu(this,e,t,o)}else ku(this,e,t,o)}setAttributes(e,t){for(const[o,n]of tr(e))this.setAttribute(o,n,t)}removeAttribute(e,t){if(this._assertWriterUsedCorrectly(),t instanceof Zl){const o=t.getMinimalFlatRanges();for(const t of o)bu(this,e,null,t)}else ku(this,e,null,t)}clearAttributes(e){this._assertWriterUsedCorrectly();const t=e=>{for(const t of e.getAttributeKeys())this.removeAttribute(t,e)};if(e instanceof Zl)for(const o of e.getItems())t(o);else t(e)}move(e,t,o){if(this._assertWriterUsedCorrectly(),!(e instanceof Zl))throw new E("writer-move-invalid-range",this);if(!e.isFlat)throw new E("writer-move-range-not-flat",this);const n=ql._createAt(t,o);if(n.isEqual(e.start))return;if(this._addOperationForAffectedMarkers("move",e),!yu(e.root,n.root))throw new E("writer-move-different-document",this);const i=e.root.document?e.root.document.version:null,r=new Dd(e.start,e.end.offset-e.start.offset,n,i);this.batch.addOperation(r),this.model.applyOperation(r)}remove(e){this._assertWriterUsedCorrectly();const t=(e instanceof Zl?e:Zl._createOn(e)).getMinimalFlatRanges().reverse();for(const e of t)this._addOperationForAffectedMarkers("move",e),_u(e.start,e.end.offset-e.start.offset,this.batch,this.model)}merge(e){this._assertWriterUsedCorrectly();const t=e.nodeBefore,o=e.nodeAfter;if(this._addOperationForAffectedMarkers("merge",e),!(t instanceof Ll))throw new E("writer-merge-no-element-before",this);if(!(o instanceof Ll))throw new E("writer-merge-no-element-after",this);e.root.document?this._merge(e):this._mergeDetached(e)}createPositionFromPath(e,t,o){return this.model.createPositionFromPath(e,t,o)}createPositionAt(e,t){return this.model.createPositionAt(e,t)}createPositionAfter(e){return this.model.createPositionAfter(e)}createPositionBefore(e){return this.model.createPositionBefore(e)}createRange(e,t){return this.model.createRange(e,t)}createRangeIn(e){return this.model.createRangeIn(e)}createRangeOn(e){return this.model.createRangeOn(e)}createSelection(...e){return this.model.createSelection(...e)}_mergeDetached(e){const t=e.nodeBefore,o=e.nodeAfter;this.move(Zl._createIn(o),ql._createAt(t,"end")),this.remove(o)}_merge(e){const t=ql._createAt(e.nodeBefore,"end"),o=ql._createAt(e.nodeAfter,0),n=e.root.document.graveyard,i=new ql(n,[0]),r=e.root.document.version,s=new Td(o,e.nodeAfter.maxOffset,t,i,r);this.batch.addOperation(s),this.model.applyOperation(s)}rename(e,t){if(this._assertWriterUsedCorrectly(),!(e instanceof Ll))throw new E("writer-rename-not-element-instance",this);const o=e.root.document?e.root.document.version:null,n=new Rd(ql._createBefore(e),e.name,t,o);this.batch.addOperation(n),this.model.applyOperation(n)}split(e,t){this._assertWriterUsedCorrectly();let o,n,i=e.parent;if(!i.parent)throw new E("writer-split-element-no-parent",this);if(t||(t=i.parent),!e.parent.getAncestors({includeSelf:!0}).includes(t))throw new E("writer-split-invalid-limit-element",this);do{const t=i.root.document?i.root.document.version:null,r=i.maxOffset-e.offset,s=Sd.getInsertionPosition(e),a=new Sd(e,r,s,null,t);this.batch.addOperation(a),this.model.applyOperation(a),o||n||(o=i,n=e.parent.nextSibling),i=(e=this.createPositionAfter(e.parent)).parent}while(i!==t);return{position:e,range:new Zl(ql._createAt(o,"end"),ql._createAt(n,0))}}wrap(e,t){if(this._assertWriterUsedCorrectly(),!e.isFlat)throw new E("writer-wrap-range-not-flat",this);const o=t instanceof Ll?t:new Ll(t);if(o.childCount>0)throw new E("writer-wrap-element-not-empty",this);if(null!==o.parent)throw new E("writer-wrap-element-attached",this);this.insert(o,e.start);const n=new Zl(e.start.getShiftedBy(1),e.end.getShiftedBy(1));this.move(n,ql._createAt(o,0))}unwrap(e){if(this._assertWriterUsedCorrectly(),null===e.parent)throw new E("writer-unwrap-element-no-parent",this);this.move(Zl._createIn(e),this.createPositionAfter(e)),this.remove(e)}addMarker(e,t){if(this._assertWriterUsedCorrectly(),!t||"boolean"!=typeof t.usingOperation)throw new E("writer-addmarker-no-usingoperation",this);const o=t.usingOperation,n=t.range,i=void 0!==t.affectsData&&t.affectsData;if(this.model.markers.has(e))throw new E("writer-addmarker-marker-exists",this);if(!n)throw new E("writer-addmarker-no-range",this);return o?(wu(this,e,null,n,i),this.model.markers.get(e)):this.model.markers._set(e,n,o,i)}updateMarker(e,t){this._assertWriterUsedCorrectly();const o="string"==typeof e?e:e.name,n=this.model.markers.get(o);if(!n)throw new E("writer-updatemarker-marker-not-exists",this);if(!t)return D("writer-updatemarker-reconvert-using-editingcontroller",{markerName:o}),void this.model.markers._refresh(n);const i="boolean"==typeof t.usingOperation,r="boolean"==typeof t.affectsData,s=r?t.affectsData:n.affectsData;if(!i&&!t.range&&!r)throw new E("writer-updatemarker-wrong-options",this);const a=n.getRange(),l=t.range?t.range:a;i&&t.usingOperation!==n.managedUsingOperations?t.usingOperation?wu(this,o,null,l,s):(wu(this,o,a,null,s),this.model.markers._set(o,l,void 0,s)):n.managedUsingOperations?wu(this,o,a,l,s):this.model.markers._set(o,l,void 0,s)}removeMarker(e){this._assertWriterUsedCorrectly();const t="string"==typeof e?e:e.name;if(!this.model.markers.has(t))throw new E("writer-removemarker-no-marker",this);const o=this.model.markers.get(t);if(!o.managedUsingOperations)return void this.model.markers._remove(t);wu(this,t,o.getRange(),null,o.affectsData)}addRoot(e,t="$root"){this._assertWriterUsedCorrectly();const o=this.model.document.getRoot(e);if(o&&o.isAttached())throw new E("writer-addroot-root-exists",this);const n=this.model.document,i=new Vd(e,t,!0,n,n.version);return this.batch.addOperation(i),this.model.applyOperation(i),this.model.document.getRoot(e)}detachRoot(e){this._assertWriterUsedCorrectly();const t="string"==typeof e?this.model.document.getRoot(e):e;if(!t||!t.isAttached())throw new E("writer-detachroot-no-root",this);for(const e of this.model.markers)e.getRange().root===t&&this.removeMarker(e);for(const e of t.getAttributeKeys())this.removeAttribute(e,t);this.remove(this.createRangeIn(t));const o=this.model.document,n=new Vd(t.rootName,t.name,!1,o,o.version);this.batch.addOperation(n),this.model.applyOperation(n)}setSelection(...e){this._assertWriterUsedCorrectly(),this.model.document.selection._setTo(...e)}setSelectionFocus(e,t){this._assertWriterUsedCorrectly(),this.model.document.selection._setFocus(e,t)}setSelectionAttribute(e,t){if(this._assertWriterUsedCorrectly(),"string"==typeof e)this._setSelectionAttribute(e,t);else for(const[t,o]of tr(e))this._setSelectionAttribute(t,o)}removeSelectionAttribute(e){if(this._assertWriterUsedCorrectly(),"string"==typeof e)this._removeSelectionAttribute(e);else for(const t of e)this._removeSelectionAttribute(t)}overrideSelectionGravity(){return this.model.document.selection._overrideGravity()}restoreSelectionGravity(e){this.model.document.selection._restoreGravity(e)}_setSelectionAttribute(e,t){const o=this.model.document.selection;if(o.isCollapsed&&o.anchor.parent.isEmpty){const n=mc._getStoreAttributeKey(e);this.setAttribute(n,t,o.anchor.parent)}o._setAttribute(e,t)}_removeSelectionAttribute(e){const t=this.model.document.selection;if(t.isCollapsed&&t.anchor.parent.isEmpty){const o=mc._getStoreAttributeKey(e);this.removeAttribute(o,t.anchor.parent)}t._removeAttribute(e)}_assertWriterUsedCorrectly(){if(this.model._currentWriter!==this)throw new E("writer-incorrect-use",this)}_addOperationForAffectedMarkers(e,t){for(const o of this.model.markers){if(!o.managedUsingOperations)continue;const n=o.getRange();let i=!1;if("move"===e){const e=t;i=e.containsPosition(n.start)||e.start.isEqual(n.start)||e.containsPosition(n.end)||e.end.isEqual(n.end)}else{const e=t,o=e.nodeBefore,r=e.nodeAfter,s=n.start.parent==o&&n.start.isAtEnd,a=n.end.parent==r&&0==n.end.offset,l=n.end.nodeAfter==r,c=n.start.nodeAfter==r;i=s||a||l||c}i&&this.updateMarker(o.name,{range:n})}}}function bu(e,t,o,n){const i=e.model,r=i.document;let s,a,l,c=n.start;for(const e of n.getWalker({shallow:!0}))l=e.item.getAttribute(t),s&&a!=l&&(a!=o&&d(),c=s),s=e.nextPosition,a=l;function d(){const n=new Zl(c,s),l=n.root.document?r.version:null,d=new Fd(n,t,a,o,l);e.batch.addOperation(d),i.applyOperation(d)}s instanceof ql&&s!=c&&a!=o&&d()}function ku(e,t,o,n){const i=e.model,r=i.document,s=n.getAttribute(t);let a,l;if(s!=o){if(n.root===n){const e=n.document?r.version:null;l=new zd(n,t,s,o,e)}else{a=new Zl(ql._createBefore(n),e.createPositionAfter(n));const i=a.root.document?r.version:null;l=new Fd(a,t,s,o,i)}e.batch.addOperation(l),i.applyOperation(l)}}function wu(e,t,o,n,i){const r=e.model,s=r.document,a=new Id(t,o,n,r.markers,!!i,s.version);e.batch.addOperation(a),r.applyOperation(a)}function _u(e,t,o,n){let i;if(e.root.document){const o=n.document,r=new ql(o.graveyard,[0]);i=new Dd(e,t,r,o.version)}else i=new pu(e,t);o.addOperation(i),n.applyOperation(i)}function yu(e,t){return e===t||e instanceof lu&&t instanceof lu}function Au(e,t,o={}){if(t.isCollapsed)return;const n=t.getFirstRange();if("$graveyard"==n.root.rootName)return;const i=e.schema;e.change((e=>{if(!o.doNotResetEntireContent&&function(e,t){const o=e.getLimitElement(t);if(!t.containsEntireContent(o))return!1;const n=t.getFirstRange();if(n.start.parent==n.end.parent)return!1;return e.checkChild(o,"paragraph")}(i,t))return void function(e,t){const o=e.model.schema.getLimitElement(t);e.remove(e.createRangeIn(o)),Eu(e,e.createPositionAt(o,0),t)}(e,t);const r={};if(!o.doNotAutoparagraph){const e=t.getSelectedElement();e&&Object.assign(r,i.getAttributesWithProperty(e,"copyOnReplace",!0))}const[s,a]=function(e){const t=e.root.document.model,o=e.start;let n=e.end;if(t.hasContent(e,{ignoreMarkers:!0})){const o=function(e){const t=e.parent,o=t.root.document.model.schema,n=t.getAncestors({parentFirst:!0,includeSelf:!0});for(const e of n){if(o.isLimit(e))return null;if(o.isBlock(e))return e}}(n);if(o&&n.isTouching(t.createPositionAt(o,0))){const o=t.createSelection(e);t.modifySelection(o,{direction:"backward"});const i=o.getLastPosition(),r=t.createRange(i,n);t.hasContent(r,{ignoreMarkers:!0})||(n=i)}}return[Yd.fromPosition(o,"toPrevious"),Yd.fromPosition(n,"toNext")]}(n);s.isTouching(a)||e.remove(e.createRange(s,a)),o.leaveUnmerged||(!function(e,t,o){const n=e.model;if(!xu(e.model.schema,t,o))return;const[i,r]=function(e,t){const o=e.getAncestors(),n=t.getAncestors();let i=0;for(;o[i]&&o[i]==n[i];)i++;return[o[i],n[i]]}(t,o);if(!i||!r)return;!n.hasContent(i,{ignoreMarkers:!0})&&n.hasContent(r,{ignoreMarkers:!0})?vu(e,t,o,i.parent):Cu(e,t,o,i.parent)}(e,s,a),i.removeDisallowedAttributes(s.parent.getChildren(),e)),Du(e,t,s),!o.doNotAutoparagraph&&function(e,t){const o=e.checkChild(t,"$text"),n=e.checkChild(t,"paragraph");return!o&&n}(i,s)&&Eu(e,s,t,r),s.detach(),a.detach()}))}function Cu(e,t,o,n){const i=t.parent,r=o.parent;if(i!=n&&r!=n){for(t=e.createPositionAfter(i),(o=e.createPositionBefore(r)).isEqual(t)||e.insert(r,t),e.merge(t);o.parent.isEmpty;){const t=o.parent;o=e.createPositionBefore(t),e.remove(t)}xu(e.model.schema,t,o)&&Cu(e,t,o,n)}}function vu(e,t,o,n){const i=t.parent,r=o.parent;if(i!=n&&r!=n){for(t=e.createPositionAfter(i),(o=e.createPositionBefore(r)).isEqual(t)||e.insert(i,o);t.parent.isEmpty;){const o=t.parent;t=e.createPositionBefore(o),e.remove(o)}o=e.createPositionBefore(r),function(e,t){const o=t.nodeBefore,n=t.nodeAfter;o.name!=n.name&&e.rename(o,n.name);e.clearAttributes(o),e.setAttributes(Object.fromEntries(n.getAttributes()),o),e.merge(t)}(e,o),xu(e.model.schema,t,o)&&vu(e,t,o,n)}}function xu(e,t,o){const n=t.parent,i=o.parent;return n!=i&&(!e.isLimit(n)&&!e.isLimit(i)&&function(e,t,o){const n=new Zl(e,t);for(const e of n.getWalker())if(o.isLimit(e.item))return!1;return!0}(t,o,e))}function Eu(e,t,o,n={}){const i=e.createElement("paragraph");e.model.schema.setAllowedAttributes(i,n,e),e.insert(i,t),Du(e,o,e.createPositionAt(i,0))}function Du(e,t,o){t instanceof mc?e.setSelection(o):t.setTo(o)}function Bu(e,t){const o=[];Array.from(e.getItems({direction:"backward"})).map((e=>t.createRangeOn(e))).filter((t=>(t.start.isAfter(e.start)||t.start.isEqual(e.start))&&(t.end.isBefore(e.end)||t.end.isEqual(e.end)))).forEach((e=>{o.push(e.start.parent),t.remove(e)})),o.forEach((e=>{let o=e;for(;o.parent&&o.isEmpty;){const e=t.createRangeOn(o);o=o.parent,t.remove(e)}}))}class Su{constructor(e,t,o){this._firstNode=null,this._lastNode=null,this._lastAutoParagraph=null,this._filterAttributesOf=[],this._affectedStart=null,this._affectedEnd=null,this._nodeToSelect=null,this.model=e,this.writer=t,this.position=o,this.canMergeWith=new Set([this.position.parent]),this.schema=e.schema,this._documentFragment=t.createDocumentFragment(),this._documentFragmentPosition=t.createPositionAt(this._documentFragment,0)}handleNodes(e){for(const t of Array.from(e))this._handleNode(t);this._insertPartialFragment(),this._lastAutoParagraph&&this._updateLastNodeFromAutoParagraph(this._lastAutoParagraph),this._mergeOnRight(),this.schema.removeDisallowedAttributes(this._filterAttributesOf,this.writer),this._filterAttributesOf=[]}_updateLastNodeFromAutoParagraph(e){const t=this.writer.createPositionAfter(this._lastNode),o=this.writer.createPositionAfter(e);if(o.isAfter(t)){if(this._lastNode=e,this.position.parent!=e||!this.position.isAtEnd)throw new E("insertcontent-invalid-insertion-position",this);this.position=o,this._setAffectedBoundaries(this.position)}}getSelectionRange(){return this._nodeToSelect?Zl._createOn(this._nodeToSelect):this.model.schema.getNearestSelectionRange(this.position)}getAffectedRange(){return this._affectedStart?new Zl(this._affectedStart,this._affectedEnd):null}destroy(){this._affectedStart&&this._affectedStart.detach(),this._affectedEnd&&this._affectedEnd.detach()}_handleNode(e){this._checkAndSplitToAllowedPosition(e)?(this._appendToFragment(e),this._firstNode||(this._firstNode=e),this._lastNode=e):this.schema.isObject(e)||this._handleDisallowedNode(e)}_insertPartialFragment(){if(this._documentFragment.isEmpty)return;const e=Yd.fromPosition(this.position,"toNext");this._setAffectedBoundaries(this.position),this._documentFragment.getChild(0)==this._firstNode&&(this.writer.insert(this._firstNode,this.position),this._mergeOnLeft(),this.position=e.toPosition()),this._documentFragment.isEmpty||this.writer.insert(this._documentFragment,this.position),this._documentFragmentPosition=this.writer.createPositionAt(this._documentFragment,0),this.position=e.toPosition(),e.detach()}_handleDisallowedNode(e){e.is("element")&&this.handleNodes(e.getChildren())}_appendToFragment(e){if(!this.schema.checkChild(this.position,e))throw new E("insertcontent-wrong-position",this,{node:e,position:this.position});this.writer.insert(e,this._documentFragmentPosition),this._documentFragmentPosition=this._documentFragmentPosition.getShiftedBy(e.offsetSize),this.schema.isObject(e)&&!this.schema.checkChild(this.position,"$text")?this._nodeToSelect=e:this._nodeToSelect=null,this._filterAttributesOf.push(e)}_setAffectedBoundaries(e){this._affectedStart||(this._affectedStart=Yd.fromPosition(e,"toPrevious")),this._affectedEnd&&!this._affectedEnd.isBefore(e)||(this._affectedEnd&&this._affectedEnd.detach(),this._affectedEnd=Yd.fromPosition(e,"toNext"))}_mergeOnLeft(){const e=this._firstNode;if(!(e instanceof Ll))return;if(!this._canMergeLeft(e))return;const t=Yd._createBefore(e);t.stickiness="toNext";const o=Yd.fromPosition(this.position,"toNext");this._affectedStart.isEqual(t)&&(this._affectedStart.detach(),this._affectedStart=Yd._createAt(t.nodeBefore,"end","toPrevious")),this._firstNode===this._lastNode&&(this._firstNode=t.nodeBefore,this._lastNode=t.nodeBefore),this.writer.merge(t),t.isEqual(this._affectedEnd)&&this._firstNode===this._lastNode&&(this._affectedEnd.detach(),this._affectedEnd=Yd._createAt(t.nodeBefore,"end","toNext")),this.position=o.toPosition(),o.detach(),this._filterAttributesOf.push(this.position.parent),t.detach()}_mergeOnRight(){const e=this._lastNode;if(!(e instanceof Ll))return;if(!this._canMergeRight(e))return;const t=Yd._createAfter(e);if(t.stickiness="toNext",!this.position.isEqual(t))throw new E("insertcontent-invalid-insertion-position",this);this.position=ql._createAt(t.nodeBefore,"end");const o=Yd.fromPosition(this.position,"toPrevious");this._affectedEnd.isEqual(t)&&(this._affectedEnd.detach(),this._affectedEnd=Yd._createAt(t.nodeBefore,"end","toNext")),this._firstNode===this._lastNode&&(this._firstNode=t.nodeBefore,this._lastNode=t.nodeBefore),this.writer.merge(t),t.getShiftedBy(-1).isEqual(this._affectedStart)&&this._firstNode===this._lastNode&&(this._affectedStart.detach(),this._affectedStart=Yd._createAt(t.nodeBefore,0,"toPrevious")),this.position=o.toPosition(),o.detach(),this._filterAttributesOf.push(this.position.parent),t.detach()}_canMergeLeft(e){const t=e.previousSibling;return t instanceof Ll&&this.canMergeWith.has(t)&&this.model.schema.checkMerge(t,e)}_canMergeRight(e){const t=e.nextSibling;return t instanceof Ll&&this.canMergeWith.has(t)&&this.model.schema.checkMerge(e,t)}_insertAutoParagraph(){this._insertPartialFragment();const e=this.writer.createElement("paragraph");this.writer.insert(e,this.position),this._setAffectedBoundaries(this.position),this._lastAutoParagraph=e,this.position=this.writer.createPositionAt(e,0)}_checkAndSplitToAllowedPosition(e){const t=this._getAllowedIn(this.position.parent,e);if(!t)return!1;for(t!=this.position.parent&&this._insertPartialFragment();t!=this.position.parent;)if(this.position.isAtStart){const e=this.position.parent;this.position=this.writer.createPositionBefore(e),e.isEmpty&&e.parent===t&&this.writer.remove(e)}else if(this.position.isAtEnd)this.position=this.writer.createPositionAfter(this.position.parent);else{const e=this.writer.createPositionAfter(this.position.parent);this._setAffectedBoundaries(this.position),this.writer.split(this.position),this.position=e,this.canMergeWith.add(this.position.nodeAfter)}return this.schema.checkChild(this.position.parent,e)||this._insertAutoParagraph(),!0}_getAllowedIn(e,t){return this.schema.checkChild(e,t)||this.schema.checkChild(e,"paragraph")&&this.schema.checkChild("paragraph",t)?e:this.schema.isLimit(e)?null:this._getAllowedIn(e.parent,t)}}function Tu(e,t,o,n={}){if(!e.schema.isObject(t))throw new E("insertobject-element-not-an-object",e,{object:t});const i=o||e.document.selection;let r=i;n.findOptimalPosition&&e.schema.isBlock(t)&&(r=e.createSelection(e.schema.findOptimalInsertionRange(i,n.findOptimalPosition)));const s=Qi(i.getSelectedBlocks()),a={};return s&&Object.assign(a,e.schema.getAttributesWithProperty(s,"copyOnReplace",!0)),e.change((o=>{r.isCollapsed||e.deleteContent(r,{doNotAutoparagraph:!0});let i=t;const s=r.anchor.parent;!e.schema.checkChild(s,t)&&e.schema.checkChild(s,"paragraph")&&e.schema.checkChild("paragraph",t)&&(i=o.createElement("paragraph"),o.insert(t,i)),e.schema.setAllowedAttributes(i,a,o);const l=e.insertContent(i,r);return l.isCollapsed||n.setSelection&&function(e,t,o,n){const i=e.model;if("on"==o)return void e.setSelection(t,"on");if("after"!=o)throw new E("insertobject-invalid-place-parameter-value",i);let r=t.nextSibling;if(i.schema.isInline(t))return void e.setSelection(t,"after");const s=r&&i.schema.checkChild(r,"$text");!s&&i.schema.checkChild(t.parent,"paragraph")&&(r=e.createElement("paragraph"),i.schema.setAllowedAttributes(r,n,e),i.insertContent(r,e.createPositionAfter(t)));r&&e.setSelection(r,0)}(o,t,n.setSelection,a),l}))}const Iu=' ,.?!:;"-()';function Pu(e,t){const{isForward:o,walker:n,unit:i,schema:r,treatEmojiAsSingleUnit:s}=e,{type:a,item:l,nextPosition:c}=t;if("text"==a)return"word"===e.unit?function(e,t){let o=e.position.textNode;o||(o=t?e.position.nodeAfter:e.position.nodeBefore);for(;o&&o.is("$text");){const n=e.position.offset-o.startOffset;if(Ru(o,n,t))o=t?e.position.nodeAfter:e.position.nodeBefore;else{if(Mu(o.data,n,t))break;e.next()}}return e.position}(n,o):function(e,t,o){const n=e.position.textNode;if(n){const i=n.data;let r=e.position.offset-n.startOffset;for(;nr(i,r)||"character"==t&&ir(i,r)||o&&sr(i,r);)e.next(),r=e.position.offset-n.startOffset}return e.position}(n,i,s);if(a==(o?"elementStart":"elementEnd")){if(r.isSelectable(l))return ql._createAt(l,o?"after":"before");if(r.checkChild(c,"$text"))return c}else{if(r.isLimit(l))return void n.skip((()=>!0));if(r.checkChild(c,"$text"))return c}}function Fu(e,t){const o=e.root,n=ql._createAt(o,t?"end":0);return t?new Zl(e,n):new Zl(n,e)}function Mu(e,t,o){const n=t+(o?0:-1);return Iu.includes(e.charAt(n))}function Ru(e,t,o){return t===(o?e.offsetSize:0)}class zu extends(Y()){constructor(){super(),this.markers=new hu,this.document=new du(this),this.schema=new Yc,this._pendingChanges=[],this._currentWriter=null,["deleteContent","modifySelection","getSelectedContent","applyOperation"].forEach((e=>this.decorate(e))),this.on("applyOperation",((e,t)=>{t[0]._validate()}),{priority:"highest"}),this.schema.register("$root",{isLimit:!0}),this.schema.register("$container",{allowIn:["$root","$container"]}),this.schema.register("$block",{allowIn:["$root","$container"],isBlock:!0}),this.schema.register("$blockObject",{allowWhere:"$block",isBlock:!0,isObject:!0}),this.schema.register("$inlineObject",{allowWhere:"$text",allowAttributesOf:"$text",isInline:!0,isObject:!0}),this.schema.register("$text",{allowIn:"$block",isInline:!0,isContent:!0}),this.schema.register("$clipboardHolder",{allowContentOf:"$root",allowChildren:"$text",isLimit:!0}),this.schema.register("$documentFragment",{allowContentOf:"$root",allowChildren:"$text",isLimit:!0}),this.schema.register("$marker"),this.schema.addChildCheck((()=>!0),"$marker"),qc(this),this.document.registerPostFixer(Fc),this.on("insertContent",((e,[t,o])=>{e.return=function(e,t,o){return e.change((n=>{const i=o||e.document.selection;i.isCollapsed||e.deleteContent(i,{doNotAutoparagraph:!0});const r=new Su(e,n,i.anchor),s=[];let a;if(t.is("documentFragment")){if(t.markers.size){const e=[];for(const[o,n]of t.markers){const{start:t,end:i}=n,r=t.isEqual(i);e.push({position:t,name:o,isCollapsed:r},{position:i,name:o,isCollapsed:r})}e.sort((({position:e},{position:t})=>e.isBefore(t)?1:-1));for(const{position:o,name:i,isCollapsed:r}of e){let e=null,a=null;const l=o.parent===t&&o.isAtStart,c=o.parent===t&&o.isAtEnd;l||c?r&&(a=l?"start":"end"):(e=n.createElement("$marker"),n.insert(e,o)),s.push({name:i,element:e,collapsed:a})}}a=t.getChildren()}else a=[t];r.handleNodes(a);let l=r.getSelectionRange();if(t.is("documentFragment")&&s.length){const e=l?cc.fromRange(l):null,t={};for(let e=s.length-1;e>=0;e--){const{name:o,element:i,collapsed:a}=s[e],l=!t[o];if(l&&(t[o]=[]),i){const e=n.createPositionAt(i,"before");t[o].push(e),n.remove(i)}else{const e=r.getAffectedRange();if(!e){a&&t[o].push(r.position);continue}a?t[o].push(e[a]):t[o].push(l?e.start:e.end)}}for(const[e,[o,i]]of Object.entries(t))o&&i&&o.root===i.root&&o.root.document&&!n.model.markers.has(e)&&n.addMarker(e,{usingOperation:!0,affectsData:!0,range:new Zl(o,i)});e&&(l=e.toRange(),e.detach())}l&&(i instanceof mc?n.setSelection(l):i.setTo(l));const c=r.getAffectedRange()||e.createRange(i.anchor);return r.destroy(),c}))}(this,t,o)})),this.on("insertObject",((e,[t,o,n])=>{e.return=Tu(this,t,o,n)})),this.on("canEditAt",(e=>{const t=!this.document.isReadOnly;e.return=t,t||e.stop()}))}change(e){try{return 0===this._pendingChanges.length?(this._pendingChanges.push({batch:new eu,callback:e}),this._runPendingChanges()[0]):e(this._currentWriter)}catch(e){E.rethrowUnexpectedError(e,this)}}enqueueChange(e,t){try{e?"function"==typeof e?(t=e,e=new eu):e instanceof eu||(e=new eu(e)):e=new eu,this._pendingChanges.push({batch:e,callback:t}),1==this._pendingChanges.length&&this._runPendingChanges()}catch(e){E.rethrowUnexpectedError(e,this)}}applyOperation(e){e._execute()}insertContent(e,t,o,...n){const i=Vu(t,o);return this.fire("insertContent",[e,i,o,...n])}insertObject(e,t,o,n,...i){const r=Vu(t,o);return this.fire("insertObject",[e,r,n,n,...i])}deleteContent(e,t){Au(this,e,t)}modifySelection(e,t){!function(e,t,o={}){const n=e.schema,i="backward"!=o.direction,r=o.unit?o.unit:"character",s=!!o.treatEmojiAsSingleUnit,a=t.focus,l=new Hl({boundaries:Fu(a,i),singleCharacters:!0,direction:i?"forward":"backward"}),c={walker:l,schema:n,isForward:i,unit:r,treatEmojiAsSingleUnit:s};let d;for(;d=l.next();){if(d.done)return;const o=Pu(c,d.value);if(o)return void(t instanceof mc?e.change((e=>{e.setSelectionFocus(o)})):t.setFocus(o))}}(this,e,t)}getSelectedContent(e){return function(e,t){return e.change((e=>{const o=e.createDocumentFragment(),n=t.getFirstRange();if(!n||n.isCollapsed)return o;const i=n.start.root,r=n.start.getCommonPath(n.end),s=i.getNodeByPath(r);let a;a=n.start.parent==n.end.parent?n:e.createRange(e.createPositionAt(s,n.start.path[r.length]),e.createPositionAt(s,n.end.path[r.length]+1));const l=a.end.offset-a.start.offset;for(const t of a.getItems({shallow:!0}))t.is("$textProxy")?e.appendText(t.data,t.getAttributes(),o):e.append(e.cloneElement(t,!0),o);if(a!=n){const t=n._getTransformedByMove(a.start,e.createPositionAt(o,0),l)[0],i=e.createRange(e.createPositionAt(o,0),t.start);Bu(e.createRange(t.end,e.createPositionAt(o,"end")),e),Bu(i,e)}return o}))}(this,e)}hasContent(e,t={}){const o=e instanceof Zl?e:Zl._createIn(e);if(o.isCollapsed)return!1;const{ignoreWhitespaces:n=!1,ignoreMarkers:i=!1}=t;if(!i)for(const e of this.markers.getMarkersIntersectingRange(o))if(e.affectsData)return!0;for(const e of o.getItems())if(this.schema.isContent(e)){if(!e.is("$textProxy"))return!0;if(!n)return!0;if(-1!==e.data.search(/\S/))return!0}return!1}canEditAt(e){const t=Vu(e);return this.fire("canEditAt",[t])}createPositionFromPath(e,t,o){return new ql(e,t,o)}createPositionAt(e,t){return ql._createAt(e,t)}createPositionAfter(e){return ql._createAfter(e)}createPositionBefore(e){return ql._createBefore(e)}createRange(e,t){return new Zl(e,t)}createRangeIn(e){return Zl._createIn(e)}createRangeOn(e){return Zl._createOn(e)}createSelection(...e){return new oc(...e)}createBatch(e){return new eu(e)}createOperationFromJSON(e){return Nd.fromJSON(e,this.document)}destroy(){this.document.destroy(),this.stopListening()}_runPendingChanges(){const e=[];this.fire("_beforeChanges");try{for(;this._pendingChanges.length;){const t=this._pendingChanges[0].batch;this._currentWriter=new fu(this,t);const o=this._pendingChanges[0].callback(this._currentWriter);e.push(o),this.document._handleChangeBlock(this._currentWriter),this._pendingChanges.shift(),this._currentWriter=null}}finally{this._pendingChanges.length=0,this._currentWriter=null,this.fire("_afterChanges")}return e}}function Vu(e,t){if(e)return e instanceof oc||e instanceof mc?e:e instanceof zl?t||0===t?new oc(e,t):e.is("rootElement")?new oc(e,"in"):new oc(e,"on"):new oc(e)}class Ou extends La{constructor(){super(...arguments),this.domEventType="click"}onDomEvent(e){this.fire(e.type,e)}}class Nu extends La{constructor(){super(...arguments),this.domEventType=["mousedown","mouseup","mouseover","mouseout"]}onDomEvent(e){this.fire(e.type,e)}}class Lu{constructor(e){this.document=e}createDocumentFragment(e){return new Xs(this.document,e)}createElement(e,t,o){return new ys(this.document,e,t,o)}createText(e){return new Nr(this.document,e)}clone(e,t=!1){return e._clone(t)}appendChild(e,t){return t._appendChild(e)}insertChild(e,t,o){return o._insertChild(e,t)}removeChildren(e,t,o){return o._removeChildren(e,t)}remove(e){const t=e.parent;return t?this.removeChildren(t.getChildIndex(e),1,t):[]}replace(e,t){const o=e.parent;if(o){const n=o.getChildIndex(e);return this.removeChildren(n,1,o),this.insertChild(n,t,o),!0}return!1}unwrapElement(e){const t=e.parent;if(t){const o=t.getChildIndex(e);this.remove(e),this.insertChild(o,e.getChildren(),t)}}rename(e,t){const o=new ys(this.document,e,t.getAttributes(),t.getChildren());return this.replace(t,o)?o:null}setAttribute(e,t,o){o._setAttribute(e,t)}removeAttribute(e,t){t._removeAttribute(e)}addClass(e,t){t._addClass(e)}removeClass(e,t){t._removeClass(e)}setStyle(e,t,o){Te(e)&&void 0===o?t._setStyle(e):o._setStyle(e,t)}removeStyle(e,t){t._removeStyle(e)}setCustomProperty(e,t,o){o._setCustomProperty(e,t)}removeCustomProperty(e,t){return t._removeCustomProperty(e)}createPositionAt(e,t){return Ss._createAt(e,t)}createPositionAfter(e){return Ss._createAfter(e)}createPositionBefore(e){return Ss._createBefore(e)}createRange(e,t){return new Ts(e,t)}createRangeOn(e){return Ts._createOn(e)}createRangeIn(e){return Ts._createIn(e)}createSelection(...e){return new Ps(...e)}}const Hu=/^#([0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/i,ju=/^rgb\([ ]?([0-9]{1,3}[ %]?,[ ]?){2,3}[0-9]{1,3}[ %]?\)$/i,qu=/^rgba\([ ]?([0-9]{1,3}[ %]?,[ ]?){3}(1|[0-9]+%|[0]?\.?[0-9]+)\)$/i,Uu=/^hsl\([ ]?([0-9]{1,3}[ %]?[,]?[ ]*){3}(1|[0-9]+%|[0]?\.?[0-9]+)?\)$/i,Wu=/^hsla\([ ]?([0-9]{1,3}[ %]?,[ ]?){2,3}(1|[0-9]+%|[0]?\.?[0-9]+)\)$/i,$u=/\w+\((?:[^()]|\([^()]*\))*\)|\S+/gi,Gu=new Set(["black","silver","gray","white","maroon","red","purple","fuchsia","green","lime","olive","yellow","navy","blue","teal","aqua","orange","aliceblue","antiquewhite","aquamarine","azure","beige","bisque","blanchedalmond","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkgrey","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkslategrey","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dimgrey","dodgerblue","firebrick","floralwhite","forestgreen","gainsboro","ghostwhite","gold","goldenrod","greenyellow","grey","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightgrey","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightslategrey","lightsteelblue","lightyellow","limegreen","linen","magenta","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","oldlace","olivedrab","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","skyblue","slateblue","slategray","slategrey","snow","springgreen","steelblue","tan","thistle","tomato","turquoise","violet","wheat","whitesmoke","yellowgreen","activeborder","activecaption","appworkspace","background","buttonface","buttonhighlight","buttonshadow","buttontext","captiontext","graytext","highlight","highlighttext","inactiveborder","inactivecaption","inactivecaptiontext","infobackground","infotext","menu","menutext","scrollbar","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","window","windowframe","windowtext","rebeccapurple","currentcolor","transparent"]);function Ku(e){return e.startsWith("#")?Hu.test(e):e.startsWith("rgb")?ju.test(e)||qu.test(e):e.startsWith("hsl")?Uu.test(e)||Wu.test(e):Gu.has(e.toLowerCase())}const Zu=["none","hidden","dotted","dashed","solid","double","groove","ridge","inset","outset"];function Ju(e){return Zu.includes(e)}const Yu=/^([+-]?[0-9]*([.][0-9]+)?(px|cm|mm|in|pc|pt|ch|em|ex|rem|vh|vw|vmin|vmax)|0)$/;function Qu(e){return Yu.test(e)}const Xu=/^[+-]?[0-9]*([.][0-9]+)?%$/;const eh=["repeat-x","repeat-y","repeat","space","round","no-repeat"];function th(e){return eh.includes(e)}const oh=["center","top","bottom","left","right"];function nh(e){return oh.includes(e)}const ih=["fixed","scroll","local"];function rh(e){return ih.includes(e)}const sh=/^url\(/;function ah(e){return sh.test(e)}function lh(e=""){if(""===e)return{top:void 0,right:void 0,bottom:void 0,left:void 0};const t=uh(e),o=t[0],n=t[2]||o,i=t[1]||o;return{top:o,bottom:n,right:i,left:t[3]||i}}function ch(e){return t=>{const{top:o,right:n,bottom:i,left:r}=t,s=[];return[o,n,r,i].every((e=>!!e))?s.push([e,dh(t)]):(o&&s.push([e+"-top",o]),n&&s.push([e+"-right",n]),i&&s.push([e+"-bottom",i]),r&&s.push([e+"-left",r])),s}}function dh({top:e,right:t,bottom:o,left:n}){const i=[];return n!==t?i.push(e,t,o,n):o!==e?i.push(e,t,o):t!==e?i.push(e,t):i.push(e),i.join(" ")}function uh(e){const t=e.matchAll($u);return Array.from(t).map((e=>e[0]))}function hh(e){e.setNormalizer("background",(e=>{const t={},o=uh(e);for(const e of o)th(e)?(t.repeat=t.repeat||[],t.repeat.push(e)):nh(e)?(t.position=t.position||[],t.position.push(e)):rh(e)?t.attachment=e:Ku(e)?t.color=e:ah(e)&&(t.image=e);return{path:"background",value:t}})),e.setNormalizer("background-color",(e=>({path:"background.color",value:e}))),e.setReducer("background",(e=>{const t=[];return t.push(["background-color",e.color]),t})),e.setStyleRelation("background",["background-color"])}function mh(e){e.setNormalizer("border",(e=>{const{color:t,style:o,width:n}=_h(e);return{path:"border",value:{color:lh(t),style:lh(o),width:lh(n)}}})),e.setNormalizer("border-top",ph("top")),e.setNormalizer("border-right",ph("right")),e.setNormalizer("border-bottom",ph("bottom")),e.setNormalizer("border-left",ph("left")),e.setNormalizer("border-color",gh("color")),e.setNormalizer("border-width",gh("width")),e.setNormalizer("border-style",gh("style")),e.setNormalizer("border-top-color",bh("color","top")),e.setNormalizer("border-top-style",bh("style","top")),e.setNormalizer("border-top-width",bh("width","top")),e.setNormalizer("border-right-color",bh("color","right")),e.setNormalizer("border-right-style",bh("style","right")),e.setNormalizer("border-right-width",bh("width","right")),e.setNormalizer("border-bottom-color",bh("color","bottom")),e.setNormalizer("border-bottom-style",bh("style","bottom")),e.setNormalizer("border-bottom-width",bh("width","bottom")),e.setNormalizer("border-left-color",bh("color","left")),e.setNormalizer("border-left-style",bh("style","left")),e.setNormalizer("border-left-width",bh("width","left")),e.setExtractor("border-top",kh("top")),e.setExtractor("border-right",kh("right")),e.setExtractor("border-bottom",kh("bottom")),e.setExtractor("border-left",kh("left")),e.setExtractor("border-top-color","border.color.top"),e.setExtractor("border-right-color","border.color.right"),e.setExtractor("border-bottom-color","border.color.bottom"),e.setExtractor("border-left-color","border.color.left"),e.setExtractor("border-top-width","border.width.top"),e.setExtractor("border-right-width","border.width.right"),e.setExtractor("border-bottom-width","border.width.bottom"),e.setExtractor("border-left-width","border.width.left"),e.setExtractor("border-top-style","border.style.top"),e.setExtractor("border-right-style","border.style.right"),e.setExtractor("border-bottom-style","border.style.bottom"),e.setExtractor("border-left-style","border.style.left"),e.setReducer("border-color",ch("border-color")),e.setReducer("border-style",ch("border-style")),e.setReducer("border-width",ch("border-width")),e.setReducer("border-top",yh("top")),e.setReducer("border-right",yh("right")),e.setReducer("border-bottom",yh("bottom")),e.setReducer("border-left",yh("left")),e.setReducer("border",function(){return t=>{const o=wh(t,"top"),n=wh(t,"right"),i=wh(t,"bottom"),r=wh(t,"left"),s=[o,n,i,r],a={width:e(s,"width"),style:e(s,"style"),color:e(s,"color")},l=Ah(a,"all");if(l.length)return l;const c=Object.entries(a).reduce(((e,[t,o])=>(o&&(e.push([`border-${t}`,o]),s.forEach((e=>delete e[t]))),e)),[]);return[...c,...Ah(o,"top"),...Ah(n,"right"),...Ah(i,"bottom"),...Ah(r,"left")]};function e(e,t){return e.map((e=>e[t])).reduce(((e,t)=>e==t?e:null))}}()),e.setStyleRelation("border",["border-color","border-style","border-width","border-top","border-right","border-bottom","border-left","border-top-color","border-right-color","border-bottom-color","border-left-color","border-top-style","border-right-style","border-bottom-style","border-left-style","border-top-width","border-right-width","border-bottom-width","border-left-width"]),e.setStyleRelation("border-color",["border-top-color","border-right-color","border-bottom-color","border-left-color"]),e.setStyleRelation("border-style",["border-top-style","border-right-style","border-bottom-style","border-left-style"]),e.setStyleRelation("border-width",["border-top-width","border-right-width","border-bottom-width","border-left-width"]),e.setStyleRelation("border-top",["border-top-color","border-top-style","border-top-width"]),e.setStyleRelation("border-right",["border-right-color","border-right-style","border-right-width"]),e.setStyleRelation("border-bottom",["border-bottom-color","border-bottom-style","border-bottom-width"]),e.setStyleRelation("border-left",["border-left-color","border-left-style","border-left-width"])}function ph(e){return t=>{const{color:o,style:n,width:i}=_h(t),r={};return void 0!==o&&(r.color={[e]:o}),void 0!==n&&(r.style={[e]:n}),void 0!==i&&(r.width={[e]:i}),{path:"border",value:r}}}function gh(e){return t=>({path:"border",value:fh(t,e)})}function fh(e,t){return{[t]:lh(e)}}function bh(e,t){return o=>({path:"border",value:{[e]:{[t]:o}}})}function kh(e){return(t,o)=>{if(o.border)return wh(o.border,e)}}function wh(e,t){const o={};return e.width&&e.width[t]&&(o.width=e.width[t]),e.style&&e.style[t]&&(o.style=e.style[t]),e.color&&e.color[t]&&(o.color=e.color[t]),o}function _h(e){const t={},o=uh(e);for(const e of o)Qu(e)||/thin|medium|thick/.test(e)?t.width=e:Ju(e)?t.style=e:t.color=e;return t}function yh(e){return t=>Ah(t,e)}function Ah(e,t){const o=[];if(e&&e.width&&o.push("width"),e&&e.style&&o.push("style"),e&&e.color&&o.push("color"),3==o.length){const n=o.map((t=>e[t])).join(" ");return["all"==t?["border",n]:[`border-${t}`,n]]}return"all"==t?[]:o.map((o=>[`border-${t}-${o}`,e[o]]))}function Ch(e){var t;e.setNormalizer("padding",(t="padding",e=>({path:t,value:lh(e)}))),e.setNormalizer("padding-top",(e=>({path:"padding.top",value:e}))),e.setNormalizer("padding-right",(e=>({path:"padding.right",value:e}))),e.setNormalizer("padding-bottom",(e=>({path:"padding.bottom",value:e}))),e.setNormalizer("padding-left",(e=>({path:"padding.left",value:e}))),e.setReducer("padding",ch("padding")),e.setStyleRelation("padding",["padding-top","padding-right","padding-bottom","padding-left"])}class vh{constructor(e){if(this.crashes=[],this.state="initializing",this._now=Date.now,this.crashes=[],this._crashNumberLimit="number"==typeof e.crashNumberLimit?e.crashNumberLimit:3,this._minimumNonErrorTimePeriod="number"==typeof e.minimumNonErrorTimePeriod?e.minimumNonErrorTimePeriod:5e3,this._boundErrorHandler=e=>{const t="error"in e?e.error:e.reason;t instanceof Error&&this._handleError(t,e)},this._listeners={},!this._restart)throw new Error("The Watchdog class was split into the abstract `Watchdog` class and the `EditorWatchdog` class. Please, use `EditorWatchdog` if you have used the `Watchdog` class previously.")}destroy(){this._stopErrorHandling(),this._listeners={}}on(e,t){this._listeners[e]||(this._listeners[e]=[]),this._listeners[e].push(t)}off(e,t){this._listeners[e]=this._listeners[e].filter((e=>e!==t))}_fire(e,...t){const o=this._listeners[e]||[];for(const e of o)e.apply(this,[null,...t])}_startErrorHandling(){window.addEventListener("error",this._boundErrorHandler),window.addEventListener("unhandledrejection",this._boundErrorHandler)}_stopErrorHandling(){window.removeEventListener("error",this._boundErrorHandler),window.removeEventListener("unhandledrejection",this._boundErrorHandler)}_handleError(e,t){if(this._shouldReactToError(e)){this.crashes.push({message:e.message,stack:e.stack,filename:t instanceof ErrorEvent?t.filename:void 0,lineno:t instanceof ErrorEvent?t.lineno:void 0,colno:t instanceof ErrorEvent?t.colno:void 0,date:this._now()});const o=this._shouldRestart();this.state="crashed",this._fire("stateChange"),this._fire("error",{error:e,causesRestart:o}),o?this._restart():(this.state="crashedPermanently",this._fire("stateChange"))}}_shouldReactToError(e){return e.is&&e.is("CKEditorError")&&void 0!==e.context&&null!==e.context&&"ready"===this.state&&this._isErrorComingFromThisItem(e)}_shouldRestart(){if(this.crashes.length<=this._crashNumberLimit)return!0;return(this.crashes[this.crashes.length-1].date-this.crashes[this.crashes.length-1-this._crashNumberLimit].date)/this._crashNumberLimit>this._minimumNonErrorTimePeriod}}function xh(e,t=new Set){const o=[e],n=new Set;let i=0;for(;o.length>i;){const e=o[i++];if(!n.has(e)&&Eh(e)&&!t.has(e))if(n.add(e),Symbol.iterator in e)try{for(const t of e)o.push(t)}catch(e){}else for(const t in e)"defaultValue"!==t&&o.push(e[t])}return n}function Eh(e){const t=Object.prototype.toString.call(e),o=typeof e;return!("number"===o||"boolean"===o||"string"===o||"symbol"===o||"function"===o||"[object Date]"===t||"[object RegExp]"===t||"[object Module]"===t||null==e||e._watchdogExcluded||e instanceof EventTarget||e instanceof Event)}function Dh(e,t,o=new Set){if(e===t&&("object"==typeof(n=e)&&null!==n))return!0;var n;const i=xh(e,o),r=xh(t,o);for(const e of i)if(r.has(e))return!0;return!1}const Bh=function(e,t,o){var n=!0,i=!0;if("function"!=typeof e)throw new TypeError("Expected a function");return U(o)&&(n="leading"in o?!!o.leading:n,i="trailing"in o?!!o.trailing:i),el(e,t,{leading:n,maxWait:t,trailing:i})};class Sh extends vh{constructor(e,t={}){super(t),this._editor=null,this._lifecyclePromise=null,this._initUsingData=!0,this._editables={},this._throttledSave=Bh(this._save.bind(this),"number"==typeof t.saveInterval?t.saveInterval:5e3),e&&(this._creator=(t,o)=>e.create(t,o)),this._destructor=e=>e.destroy()}get editor(){return this._editor}get _item(){return this._editor}setCreator(e){this._creator=e}setDestructor(e){this._destructor=e}_restart(){return Promise.resolve().then((()=>(this.state="initializing",this._fire("stateChange"),this._destroy()))).catch((e=>{console.error("An error happened during the editor destroying.",e)})).then((()=>{const e={},t=[],o=this._config.rootsAttributes||{},n={};for(const[i,r]of Object.entries(this._data.roots))r.isLoaded?(e[i]="",n[i]=o[i]||{}):t.push(i);const i={...this._config,extraPlugins:this._config.extraPlugins||[],lazyRoots:t,rootsAttributes:n,_watchdogInitialData:this._data};return delete i.initialData,i.extraPlugins.push(Th),this._initUsingData?this.create(e,i,i.context):Bn(this._elementOrData)?this.create(this._elementOrData,i,i.context):this.create(this._editables,i,i.context)})).then((()=>{this._fire("restart")}))}create(e=this._elementOrData,t=this._config,o){return this._lifecyclePromise=Promise.resolve(this._lifecyclePromise).then((()=>(super._startErrorHandling(),this._elementOrData=e,this._initUsingData="string"==typeof e||Object.keys(e).length>0&&"string"==typeof Object.values(e)[0],this._config=this._cloneEditorConfiguration(t)||{},this._config.context=o,this._creator(e,this._config)))).then((e=>{this._editor=e,e.model.document.on("change:data",this._throttledSave),this._lastDocumentVersion=e.model.document.version,this._data=this._getData(),this._initUsingData||(this._editables=this._getEditables()),this.state="ready",this._fire("stateChange")})).finally((()=>{this._lifecyclePromise=null})),this._lifecyclePromise}destroy(){return this._lifecyclePromise=Promise.resolve(this._lifecyclePromise).then((()=>(this.state="destroyed",this._fire("stateChange"),super.destroy(),this._destroy()))).finally((()=>{this._lifecyclePromise=null})),this._lifecyclePromise}_destroy(){return Promise.resolve().then((()=>{this._stopErrorHandling(),this._throttledSave.cancel();const e=this._editor;return this._editor=null,e.model.document.off("change:data",this._throttledSave),this._destructor(e)}))}_save(){const e=this._editor.model.document.version;try{this._data=this._getData(),this._initUsingData||(this._editables=this._getEditables()),this._lastDocumentVersion=e}catch(e){console.error(e,"An error happened during restoring editor data. Editor will be restored from the previously saved data.")}}_setExcludedProperties(e){this._excludedProps=e}_getData(){const e=this._editor,t=e.model.document.roots.filter((e=>e.isAttached()&&"$graveyard"!=e.rootName)),{plugins:o}=e,n=o.has("CommentsRepository")&&o.get("CommentsRepository"),i=o.has("TrackChanges")&&o.get("TrackChanges"),r={roots:{},markers:{},commentThreads:JSON.stringify([]),suggestions:JSON.stringify([])};t.forEach((e=>{r.roots[e.rootName]={content:JSON.stringify(Array.from(e.getChildren())),attributes:JSON.stringify(Array.from(e.getAttributes())),isLoaded:e._isLoaded}}));for(const t of e.model.markers)t._affectsData&&(r.markers[t.name]={rangeJSON:t.getRange().toJSON(),usingOperation:t._managedUsingOperations,affectsData:t._affectsData});return n&&(r.commentThreads=JSON.stringify(n.getCommentThreads({toJSON:!0,skipNotAttached:!0}))),i&&(r.suggestions=JSON.stringify(i.getSuggestions({toJSON:!0,skipNotAttached:!0}))),r}_getEditables(){const e={};for(const t of this.editor.model.document.getRootNames()){const o=this.editor.ui.getEditableElement(t);o&&(e[t]=o)}return e}_isErrorComingFromThisItem(e){return Dh(this._editor,e.context,this._excludedProps)}_cloneEditorConfiguration(e){return Dn(e,((e,t)=>Bn(e)||"context"===t?e:void 0))}}class Th{constructor(e){this.editor=e,this._data=e.config.get("_watchdogInitialData")}init(){this.editor.data.on("init",(e=>{e.stop(),this.editor.model.enqueueChange({isUndoable:!1},(e=>{this._restoreCollaborationData(),this._restoreEditorData(e)})),this.editor.data.fire("ready")}),{priority:999})}_createNode(e,t){if("name"in t){const o=e.createElement(t.name,t.attributes);if(t.children)for(const n of t.children)o._appendChild(this._createNode(e,n));return o}return e.createText(t.data,t.attributes)}_restoreEditorData(e){const t=this.editor;Object.entries(this._data.roots).forEach((([o,{content:n,attributes:i}])=>{const r=JSON.parse(n),s=JSON.parse(i),a=t.model.document.getRoot(o);for(const[t,o]of s)e.setAttribute(t,o,a);for(const t of r){const o=this._createNode(e,t);e.insert(o,a,"end")}})),Object.entries(this._data.markers).forEach((([o,n])=>{const{document:i}=t.model,{rangeJSON:{start:r,end:s},...a}=n,l=i.getRoot(r.root),c=e.createPositionFromPath(l,r.path,r.stickiness),d=e.createPositionFromPath(l,s.path,s.stickiness),u=e.createRange(c,d);e.addMarker(o,{range:u,...a})}))}_restoreCollaborationData(){const e=JSON.parse(this._data.commentThreads),t=JSON.parse(this._data.suggestions);e.forEach((e=>{const t=this.editor.config.get("collaboration.channelId"),o=this.editor.plugins.get("CommentsRepository");if(o.hasCommentThread(e.threadId)){o.getCommentThread(e.threadId).remove()}o.addCommentThread({channelId:t,...e})})),t.forEach((e=>{const t=this.editor.plugins.get("TrackChangesEditing");if(t.hasSuggestion(e.id)){t.getSuggestion(e.id).attributes=e.attributes}else t.addSuggestionData(e)}))}}const Ih=Symbol("MainQueueId");class Ph{constructor(){this._onEmptyCallbacks=[],this._queues=new Map,this._activeActions=0}onEmpty(e){this._onEmptyCallbacks.push(e)}enqueue(e,t){const o=e===Ih;this._activeActions++,this._queues.get(e)||this._queues.set(e,Promise.resolve());const n=(o?Promise.all(this._queues.values()):Promise.all([this._queues.get(Ih),this._queues.get(e)])).then(t),i=n.catch((()=>{}));return this._queues.set(e,i),n.finally((()=>{this._activeActions--,this._queues.get(e)===i&&0===this._activeActions&&this._onEmptyCallbacks.forEach((e=>e()))}))}}function Fh(e){return Array.isArray(e)?e:[e]}class Mh{constructor(){this._commands=new Map}add(e,t){this._commands.set(e,t)}get(e){return this._commands.get(e)}execute(e,...t){const o=this.get(e);if(!o)throw new E("commandcollection-command-not-found",this,{commandName:e});return o.execute(...t)}*names(){yield*this._commands.keys()}*commands(){yield*this._commands.values()}[Symbol.iterator](){return this._commands[Symbol.iterator]()}destroy(){for(const e of this.commands())e.destroy()}}class Rh extends er{constructor(e){super(),this.editor=e}set(e,t,o={}){if("string"==typeof t){const e=t;t=(t,o)=>{this.editor.execute(e),o()}}super.set(e,t,o)}}const zh="contentEditing",Vh="common";class Oh{constructor(e){this.keystrokeInfos=new Map,this._editor=e;const t=e.config.get("menuBar.isVisible"),o=e.locale.t;this.addKeystrokeInfoCategory({id:zh,label:o("Content editing keystrokes"),description:o("These keyboard shortcuts allow for quick access to content editing features.")});const n=[{label:o("Close contextual balloons, dropdowns, and dialogs"),keystroke:"Esc"},{label:o("Open the accessibility help dialog"),keystroke:"Alt+0"},{label:o("Move focus between form fields (inputs, buttons, etc.)"),keystroke:[["Tab"],["Shift+Tab"]]},{label:o("Move focus to the toolbar, navigate between toolbars"),keystroke:"Alt+F10",mayRequireFn:!0},{label:o("Navigate through the toolbar or menu bar"),keystroke:[["arrowup"],["arrowright"],["arrowdown"],["arrowleft"]]},{label:o("Execute the currently focused button. Executing buttons that interact with the editor content moves the focus back to the content."),keystroke:[["Enter"],["Space"]]}];t&&n.push({label:o("Move focus to the menu bar, navigate between menu bars"),keystroke:"Alt+F9",mayRequireFn:!0}),this.addKeystrokeInfoCategory({id:"navigation",label:o("User interface and content navigation keystrokes"),description:o("Use the following keystrokes for more efficient navigation in the CKEditor 5 user interface."),groups:[{id:"common",keystrokes:n}]})}addKeystrokeInfoCategory({id:e,label:t,description:o,groups:n}){this.keystrokeInfos.set(e,{id:e,label:t,description:o,groups:new Map}),this.addKeystrokeInfoGroup({categoryId:e,id:Vh}),n&&n.forEach((t=>{this.addKeystrokeInfoGroup({categoryId:e,...t})}))}addKeystrokeInfoGroup({categoryId:e=zh,id:t,label:o,keystrokes:n}){const i=this.keystrokeInfos.get(e);if(!i)throw new E("accessibility-unknown-keystroke-info-category",this._editor,{groupId:t,categoryId:e});i.groups.set(t,{id:t,label:o,keystrokes:n||[]})}addKeystrokeInfos({categoryId:e=zh,groupId:t=Vh,keystrokes:o}){if(!this.keystrokeInfos.has(e))throw new E("accessibility-unknown-keystroke-info-category",this._editor,{categoryId:e,keystrokes:o});const n=this.keystrokeInfos.get(e);if(!n.groups.has(t))throw new E("accessibility-unknown-keystroke-info-group",this._editor,{groupId:t,categoryId:e,keystrokes:o});n.groups.get(t).keystrokes.push(...o)}}class Nh extends(Y()){constructor(e={}){super();const t=this.constructor,{translations:o,...n}=t.defaultConfig||{},{translations:i=o,...r}=e,s=e.language||n.language;this._context=e.context||new mr({language:s,translations:i}),this._context._addEditor(this,!e.context);const a=Array.from(t.builtinPlugins||[]);this.config=new Sn(r,n),this.config.define("plugins",a),this.config.define(this._context._getEditorConfig()),this.plugins=new hr(this,a,this._context.plugins),this.locale=this._context.locale,this.t=this.locale.t,this._readOnlyLocks=new Set,this.commands=new Mh,this.set("state","initializing"),this.once("ready",(()=>this.state="ready"),{priority:"high"}),this.once("destroy",(()=>this.state="destroyed"),{priority:"high"}),this.model=new zu,this.on("change:isReadOnly",(()=>{this.model.document.isReadOnly=this.isReadOnly}));const l=new ks;this.data=new gd(this.model,l),this.editing=new Gc(this.model,l),this.editing.view.document.bind("isReadOnly").to(this),this.conversion=new fd([this.editing.downcastDispatcher,this.data.downcastDispatcher],this.data.upcastDispatcher),this.conversion.addAlias("dataDowncast",this.data.downcastDispatcher),this.conversion.addAlias("editingDowncast",this.editing.downcastDispatcher),this.keystrokes=new Rh(this),this.keystrokes.listenTo(this.editing.view.document),this.accessibility=new Oh(this)}get isReadOnly(){return this._readOnlyLocks.size>0}set isReadOnly(e){throw new E("editor-isreadonly-has-no-setter")}enableReadOnlyMode(e){if("string"!=typeof e&&"symbol"!=typeof e)throw new E("editor-read-only-lock-id-invalid",null,{lockId:e});this._readOnlyLocks.has(e)||(this._readOnlyLocks.add(e),1===this._readOnlyLocks.size&&this.fire("change:isReadOnly","isReadOnly",!0,!1))}disableReadOnlyMode(e){if("string"!=typeof e&&"symbol"!=typeof e)throw new E("editor-read-only-lock-id-invalid",null,{lockId:e});this._readOnlyLocks.has(e)&&(this._readOnlyLocks.delete(e),0===this._readOnlyLocks.size&&this.fire("change:isReadOnly","isReadOnly",!1,!0))}setData(e){this.data.set(e)}getData(e){return this.data.get(e)}initPlugins(){const e=this.config,t=e.get("plugins"),o=e.get("removePlugins")||[],n=e.get("extraPlugins")||[],i=e.get("substitutePlugins")||[];return this.plugins.init(t.concat(n),o,i)}destroy(){let e=Promise.resolve();return"initializing"==this.state&&(e=new Promise((e=>this.once("ready",e)))),e.then((()=>{this.fire("destroy"),this.stopListening(),this.commands.destroy()})).then((()=>this.plugins.destroy())).then((()=>{this.model.destroy(),this.data.destroy(),this.editing.destroy(),this.keystrokes.destroy()})).then((()=>this._context._removeEditor(this)))}execute(e,...t){try{return this.commands.execute(e,...t)}catch(e){E.rethrowUnexpectedError(e,this)}}focus(){this.editing.view.focus()}static create(...e){throw new Error("This is an abstract method.")}}Nh.Context=mr,Nh.EditorWatchdog=Sh,Nh.ContextWatchdog=class extends vh{constructor(e,t={}){super(t),this._watchdogs=new Map,this._context=null,this._contextProps=new Set,this._actionQueues=new Ph,this._watchdogConfig=t,this._creator=t=>e.create(t),this._destructor=e=>e.destroy(),this._actionQueues.onEmpty((()=>{"initializing"===this.state&&(this.state="ready",this._fire("stateChange"))}))}setCreator(e){this._creator=e}setDestructor(e){this._destructor=e}get context(){return this._context}create(e={}){return this._actionQueues.enqueue(Ih,(()=>(this._contextConfig=e,this._create())))}getItem(e){return this._getWatchdog(e)._item}getItemState(e){return this._getWatchdog(e).state}add(e){const t=Fh(e);return Promise.all(t.map((e=>this._actionQueues.enqueue(e.id,(()=>{if("destroyed"===this.state)throw new Error("Cannot add items to destroyed watchdog.");if(!this._context)throw new Error("Context was not created yet. You should call the `ContextWatchdog#create()` method first.");let t;if(this._watchdogs.has(e.id))throw new Error(`Item with the given id is already added: '${e.id}'.`);if("editor"===e.type)return t=new Sh(null,this._watchdogConfig),t.setCreator(e.creator),t._setExcludedProperties(this._contextProps),e.destructor&&t.setDestructor(e.destructor),this._watchdogs.set(e.id,t),t.on("error",((o,{error:n,causesRestart:i})=>{this._fire("itemError",{itemId:e.id,error:n}),i&&this._actionQueues.enqueue(e.id,(()=>new Promise((o=>{const n=()=>{t.off("restart",n),this._fire("itemRestart",{itemId:e.id}),o()};t.on("restart",n)}))))})),t.create(e.sourceElementOrData,e.config,this._context);throw new Error(`Not supported item type: '${e.type}'.`)})))))}remove(e){const t=Fh(e);return Promise.all(t.map((e=>this._actionQueues.enqueue(e,(()=>{const t=this._getWatchdog(e);return this._watchdogs.delete(e),t.destroy()})))))}destroy(){return this._actionQueues.enqueue(Ih,(()=>(this.state="destroyed",this._fire("stateChange"),super.destroy(),this._destroy())))}_restart(){return this._actionQueues.enqueue(Ih,(()=>(this.state="initializing",this._fire("stateChange"),this._destroy().catch((e=>{console.error("An error happened during destroying the context or items.",e)})).then((()=>this._create())).then((()=>this._fire("restart"))))))}_create(){return Promise.resolve().then((()=>(this._startErrorHandling(),this._creator(this._contextConfig)))).then((e=>(this._context=e,this._contextProps=xh(this._context),Promise.all(Array.from(this._watchdogs.values()).map((e=>(e._setExcludedProperties(this._contextProps),e.create(void 0,void 0,this._context))))))))}_destroy(){return Promise.resolve().then((()=>{this._stopErrorHandling();const e=this._context;return this._context=null,this._contextProps=new Set,Promise.all(Array.from(this._watchdogs.values()).map((e=>e.destroy()))).then((()=>this._destructor(e)))}))}_getWatchdog(e){const t=this._watchdogs.get(e);if(!t)throw new Error(`Item with the given id was not registered: ${e}.`);return t}_isErrorComingFromThisItem(e){for(const t of this._watchdogs.values())if(t._isErrorComingFromThisItem(e))return!1;return Dh(this._context,e.context)}};const Lh=Nh;function Hh(e){return class extends e{updateSourceElement(e){if(!this.sourceElement)throw new E("editor-missing-sourceelement",this);const t=this.config.get("updateSourceElementOnDestroy"),o=this.sourceElement instanceof HTMLTextAreaElement;if(!t&&!o)return void Jn(this.sourceElement,"");const n="string"==typeof e?e:this.data.get();Jn(this.sourceElement,n)}}}Hh.updateSourceElement=Hh(Object).prototype.updateSourceElement;class jh extends pr{static get pluginName(){return"PendingActions"}init(){this.set("hasAny",!1),this._actions=new Yi({idProperty:"_id"}),this._actions.delegate("add","remove").to(this)}add(e){if("string"!=typeof e)throw new E("pendingactions-add-invalid-message",this);const t=new(Y());return t.set("message",e),this._actions.add(t),this.hasAny=!0,t}remove(e){this._actions.remove(e),this.hasAny=!!this._actions.length}get first(){return this._actions.get(0)}[Symbol.iterator](){return this._actions[Symbol.iterator]()}}const qh={bold:'',cancel:'',caption:'',check:'',cog:'',colorPalette:'',eraser:'',history:'',image:'',imageUpload:'',imageAssetManager:'',imageUrl:'',lowVision:'',textAlternative:'',loupe:'',previousArrow:'',nextArrow:'',importExport:'',paragraph:'',plus:'',text:'',alignBottom:'',alignMiddle:'',alignTop:'',alignLeft:'',alignCenter:'',alignRight:'',alignJustify:'',objectLeft:'',objectCenter:'',objectRight:'',objectFullWidth:'',objectInline:'',objectBlockLeft:'',objectBlockRight:'',objectSizeCustom:'',objectSizeFull:'',objectSizeLarge:'',objectSizeSmall:'',objectSizeMedium:'',pencil:'',pilcrow:'',quote:'',threeVerticalDots:'',dragIndicator:'',redo:'',undo:'',bulletedList:'',numberedList:'',todoList:'',codeBlock:'',browseFiles:'',heading1:'',heading2:'',heading3:'',heading4:'',heading5:'',heading6:'',horizontalLine:'',html:'',indent:'',outdent:'',table:''};class Uh extends Yi{constructor(e=[]){super(e,{idProperty:"viewUid"}),this.on("add",((e,t,o)=>{this._renderViewIntoCollectionParent(t,o)})),this.on("remove",((e,t)=>{t.element&&this._parentElement&&t.element.remove()})),this._parentElement=null}destroy(){this.map((e=>e.destroy()))}setParent(e){this._parentElement=e;for(const e of this)this._renderViewIntoCollectionParent(e)}delegate(...e){if(!e.length||!e.every((e=>"string"==typeof e)))throw new E("ui-viewcollection-delegate-wrong-events",this);return{to:t=>{for(const o of this)for(const n of e)o.delegate(n).to(t);this.on("add",((o,n)=>{for(const o of e)n.delegate(o).to(t)})),this.on("remove",((o,n)=>{for(const o of e)n.stopDelegating(o,t)}))}}}_renderViewIntoCollectionParent(e,t){e.isRendered||e.render(),e.element&&this._parentElement&&this._parentElement.insertBefore(e.element,this._parentElement.children[t])}remove(e){return super.remove(e)}}class Wh extends(z()){constructor(e){super(),Object.assign(this,tm(em(e))),this._isRendered=!1,this._revertData=null}render(){const e=this._renderNode({intoFragment:!0});return this._isRendered=!0,e}apply(e){return this._revertData={children:[],bindings:[],attributes:{}},this._renderNode({node:e,intoFragment:!1,isApplying:!0,revertData:this._revertData}),e}revert(e){if(!this._revertData)throw new E("ui-template-revert-not-applied",[this,e]);this._revertTemplateFromNode(e,this._revertData)}*getViews(){yield*function*e(t){if(t.children)for(const o of t.children)am(o)?yield o:lm(o)&&(yield*e(o))}(this)}static bind(e,t){return{to:(o,n)=>new Gh({eventNameOrFunction:o,attribute:o,observable:e,emitter:t,callback:n}),if:(o,n,i)=>new Kh({observable:e,emitter:t,attribute:o,valueIfTrue:n,callback:i})}}static extend(e,t){if(e._isRendered)throw new E("template-extend-render",[this,e]);rm(e,tm(em(t)))}_renderNode(e){let t;if(t=e.node?this.tag&&this.text:this.tag?this.text:!this.text,t)throw new E("ui-template-wrong-syntax",this);return this.text?this._renderText(e):this._renderElement(e)}_renderElement(e){let t=e.node;return t||(t=e.node=document.createElementNS(this.ns||"http://www.w3.org/1999/xhtml",this.tag)),this._renderAttributes(e),this._renderElementChildren(e),this._setUpListeners(e),t}_renderText(e){let t=e.node;return t?e.revertData.text=t.textContent:t=e.node=document.createTextNode(""),Zh(this.text)?this._bindToObservable({schema:this.text,updater:Yh(t),data:e}):t.textContent=this.text.join(""),t}_renderAttributes(e){if(!this.attributes)return;const t=e.node,o=e.revertData;for(const n in this.attributes){const i=t.getAttribute(n),r=this.attributes[n];o&&(o.attributes[n]=i);const s=dm(r)?r[0].ns:null;if(Zh(r)){const a=dm(r)?r[0].value:r;o&&um(n)&&a.unshift(i),this._bindToObservable({schema:a,updater:Qh(t,n,s),data:e})}else if("style"==n&&"string"!=typeof r[0])this._renderStyleAttribute(r[0],e);else{o&&i&&um(n)&&r.unshift(i);const e=r.map((e=>e&&e.value||e)).reduce(((e,t)=>e.concat(t)),[]).reduce(nm,"");sm(e)||t.setAttributeNS(s,n,e)}}}_renderStyleAttribute(e,t){const o=t.node;for(const n in e){const i=e[n];Zh(i)?this._bindToObservable({schema:[i],updater:Xh(o,n),data:t}):o.style[n]=i}}_renderElementChildren(e){const t=e.node,o=e.intoFragment?document.createDocumentFragment():t,n=e.isApplying;let i=0;for(const r of this.children)if(cm(r)){if(!n){r.setParent(t);for(const e of r)o.appendChild(e.element)}}else if(am(r))n||(r.isRendered||r.render(),o.appendChild(r.element));else if(Pn(r))o.appendChild(r);else if(n){const t={children:[],bindings:[],attributes:{}};e.revertData.children.push(t),r._renderNode({intoFragment:!1,node:o.childNodes[i++],isApplying:!0,revertData:t})}else o.appendChild(r.render());e.intoFragment&&t.appendChild(o)}_setUpListeners(e){if(this.eventListeners)for(const t in this.eventListeners){const o=this.eventListeners[t].map((o=>{const[n,i]=t.split("@");return o.activateDomEventListener(n,i,e)}));e.revertData&&e.revertData.bindings.push(o)}}_bindToObservable({schema:e,updater:t,data:o}){const n=o.revertData;Jh(e,t,o);const i=e.filter((e=>!sm(e))).filter((e=>e.observable)).map((n=>n.activateAttributeListener(e,t,o)));n&&n.bindings.push(i)}_revertTemplateFromNode(e,t){for(const e of t.bindings)for(const t of e)t();if(t.text)return void(e.textContent=t.text);const o=e;for(const e in t.attributes){const n=t.attributes[e];null===n?o.removeAttribute(e):o.setAttribute(e,n)}for(let e=0;eJh(e,t,o);return this.emitter.listenTo(this.observable,`change:${this.attribute}`,n),()=>{this.emitter.stopListening(this.observable,`change:${this.attribute}`,n)}}}class Gh extends $h{constructor(e){super(e),this.eventNameOrFunction=e.eventNameOrFunction}activateDomEventListener(e,t,o){const n=(e,o)=>{t&&!o.target.matches(t)||("function"==typeof this.eventNameOrFunction?this.eventNameOrFunction(o):this.observable.fire(this.eventNameOrFunction,o))};return this.emitter.listenTo(o.node,e,n),()=>{this.emitter.stopListening(o.node,e,n)}}}class Kh extends $h{constructor(e){super(e),this.valueIfTrue=e.valueIfTrue}getValue(e){return!sm(super.getValue(e))&&(this.valueIfTrue||!0)}}function Zh(e){return!!e&&(e.value&&(e=e.value),Array.isArray(e)?e.some(Zh):e instanceof $h)}function Jh(e,t,{node:o}){const n=function(e,t){return e.map((e=>e instanceof $h?e.getValue(t):e))}(e,o);let i;i=1==e.length&&e[0]instanceof Kh?n[0]:n.reduce(nm,""),sm(i)?t.remove():t.set(i)}function Yh(e){return{set(t){e.textContent=t},remove(){e.textContent=""}}}function Qh(e,t,o){return{set(n){e.setAttributeNS(o,t,n)},remove(){e.removeAttributeNS(o,t)}}}function Xh(e,t){return{set(o){e.style[t]=o},remove(){e.style[t]=null}}}function em(e){return Dn(e,(e=>{if(e&&(e instanceof $h||lm(e)||am(e)||cm(e)))return e}))}function tm(e){if("string"==typeof e?e=function(e){return{text:[e]}}(e):e.text&&function(e){e.text=xi(e.text)}(e),e.on&&(e.eventListeners=function(e){for(const t in e)om(e,t);return e}(e.on),delete e.on),!e.text){e.attributes&&function(e){for(const t in e)e[t].value&&(e[t].value=xi(e[t].value)),om(e,t)}(e.attributes);const t=[];if(e.children)if(cm(e.children))t.push(e.children);else for(const o of e.children)lm(o)||am(o)||Pn(o)?t.push(o):t.push(new Wh(o));e.children=t}return e}function om(e,t){e[t]=xi(e[t])}function nm(e,t){return sm(t)?e:sm(e)?t:`${e} ${t}`}function im(e,t){for(const o in t)e[o]?e[o].push(...t[o]):e[o]=t[o]}function rm(e,t){if(t.attributes&&(e.attributes||(e.attributes={}),im(e.attributes,t.attributes)),t.eventListeners&&(e.eventListeners||(e.eventListeners={}),im(e.eventListeners,t.eventListeners)),t.text&&e.text.push(...t.text),t.children&&t.children.length){if(e.children.length!=t.children.length)throw new E("ui-template-extend-children-mismatch",e);let o=0;for(const n of t.children)rm(e.children[o++],n)}}function sm(e){return!e&&0!==e}function am(e){return e instanceof pm}function lm(e){return e instanceof Wh}function cm(e){return e instanceof Uh}function dm(e){return U(e[0])&&e[0].ns}function um(e){return"class"==e||"style"==e}var hm=i(601),mm={attributes:{"data-cke":!0}};mm.setAttributes=Ar(),mm.insert=_r().bind(null,"head"),mm.domAPI=kr(),mm.insertStyleElement=vr();fr()(hm.A,mm);hm.A&&hm.A.locals&&hm.A.locals;class pm extends(Rn(Y())){constructor(e){super(),this.element=null,this.isRendered=!1,this.locale=e,this.t=e&&e.t,this._viewCollections=new Yi,this._unboundChildren=this.createCollection(),this._viewCollections.on("add",((t,o)=>{o.locale=e,o.t=e&&e.t})),this.decorate("render")}get bindTemplate(){return this._bindTemplate?this._bindTemplate:this._bindTemplate=Wh.bind(this,this)}createCollection(e){const t=new Uh(e);return this._viewCollections.add(t),t}registerChild(e){re(e)||(e=[e]);for(const t of e)this._unboundChildren.add(t)}deregisterChild(e){re(e)||(e=[e]);for(const t of e)this._unboundChildren.remove(t)}setTemplate(e){this.template=new Wh(e)}extendTemplate(e){Wh.extend(this.template,e)}render(){if(this.isRendered)throw new E("ui-view-render-already-rendered",this);this.template&&(this.element=this.template.render(),this.registerChild(this.template.getViews())),this.isRendered=!0}destroy(){this.stopListening(),this._viewCollections.map((e=>e.destroy())),this.template&&this.template._revertData&&this.template.revert(this.element)}}function gm({emitter:e,activator:t,callback:o,contextElements:n}){e.listenTo(document,"mousedown",((e,i)=>{if(!t())return;const r="function"==typeof i.composedPath?i.composedPath():[],s="function"==typeof n?n():n;for(const e of s)if(e.contains(i.target)||r.includes(e))return;o()}))}function fm(e){return class extends e{disableCssTransitions(){this._isCssTransitionsDisabled=!0}enableCssTransitions(){this._isCssTransitionsDisabled=!1}constructor(...e){super(...e),this.set("_isCssTransitionsDisabled",!1),this.initializeCssTransitionDisablerMixin()}initializeCssTransitionDisablerMixin(){this.extendTemplate({attributes:{class:[this.bindTemplate.if("_isCssTransitionsDisabled","ck-transitions-disabled")]}})}}}function bm({view:e}){e.listenTo(e.element,"submit",((t,o)=>{o.preventDefault(),e.fire("submit")}),{useCapture:!0})}function km({keystrokeHandler:e,focusTracker:t,gridItems:o,numberOfColumns:n,uiLanguageDirection:i}){const r="number"==typeof n?()=>n:n;function s(e){return n=>{const i=o.find((e=>e.element===t.focusedElement)),r=o.getIndex(i),s=e(r,o);o.get(s).focus(),n.stopPropagation(),n.preventDefault()}}function a(e,t){return e===t-1?0:e+1}function l(e,t){return 0===e?t-1:e-1}e.set("arrowright",s(((e,t)=>"rtl"===i?l(e,t.length):a(e,t.length)))),e.set("arrowleft",s(((e,t)=>"rtl"===i?a(e,t.length):l(e,t.length)))),e.set("arrowup",s(((e,t)=>{let o=e-r();return o<0&&(o=e+r()*Math.floor(t.length/r()),o>t.length-1&&(o-=r())),o}))),e.set("arrowdown",s(((e,t)=>{let o=e+r();return o>t.length-1&&(o=e%r()),o})))}var wm=i(4106),_m={attributes:{"data-cke":!0}};_m.setAttributes=Ar(),_m.insert=_r().bind(null,"head"),_m.domAPI=kr(),_m.insertStyleElement=vr();fr()(wm.A,_m);wm.A&&wm.A.locals&&wm.A.locals;class ym extends pm{constructor(){super();const e=this.bindTemplate;this.set("content",""),this.set("viewBox","0 0 20 20"),this.set("fillColor",""),this.set("isColorInherited",!0),this.set("isVisible",!0),this.setTemplate({tag:"svg",ns:"http://www.w3.org/2000/svg",attributes:{class:["ck","ck-icon",e.if("isVisible","ck-hidden",(e=>!e)),"ck-reset_all-excluded",e.if("isColorInherited","ck-icon_inherit-color")],viewBox:e.to("viewBox")}})}render(){super.render(),this._updateXMLContent(),this._colorFillPaths(),this.on("change:content",(()=>{this._updateXMLContent(),this._colorFillPaths()})),this.on("change:fillColor",(()=>{this._colorFillPaths()}))}_updateXMLContent(){if(this.content){const e=(new DOMParser).parseFromString(this.content.trim(),"image/svg+xml").querySelector("svg"),t=e.getAttribute("viewBox");t&&(this.viewBox=t);for(const{name:t,value:o}of Array.from(e.attributes))ym.presentationalAttributeNames.includes(t)&&this.element.setAttribute(t,o);for(;this.element.firstChild;)this.element.removeChild(this.element.firstChild);for(;e.childNodes.length>0;)this.element.appendChild(e.childNodes[0])}}_colorFillPaths(){this.fillColor&&this.element.querySelectorAll(".ck-icon__fill").forEach((e=>{e.style.fill=this.fillColor}))}}ym.presentationalAttributeNames=["alignment-baseline","baseline-shift","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-rendering","cursor","direction","display","dominant-baseline","fill","fill-opacity","fill-rule","filter","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","image-rendering","letter-spacing","lighting-color","marker-end","marker-mid","marker-start","mask","opacity","overflow","paint-order","pointer-events","shape-rendering","stop-color","stop-opacity","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-decoration","text-overflow","text-rendering","transform","unicode-bidi","vector-effect","visibility","white-space","word-spacing","writing-mode"];const Am=ym;class Cm extends pm{constructor(){super(),this.set({style:void 0,text:void 0,id:void 0});const e=this.bindTemplate;this.setTemplate({tag:"span",attributes:{class:["ck","ck-button__label"],style:e.to("style"),id:e.to("id")},children:[{text:e.to("text")}]})}}var vm=i(8948),xm={attributes:{"data-cke":!0}};xm.setAttributes=Ar(),xm.insert=_r().bind(null,"head"),xm.domAPI=kr(),xm.insertStyleElement=vr();fr()(vm.A,xm);vm.A&&vm.A.locals&&vm.A.locals;class Em extends pm{constructor(e,t=new Cm){super(e),this._focusDelayed=null;const o=this.bindTemplate,n=A();this.set("_ariaPressed",!1),this.set("_ariaChecked",!1),this.set("ariaLabel",void 0),this.set("ariaLabelledBy",`ck-editor__aria-label_${n}`),this.set("class",void 0),this.set("labelStyle",void 0),this.set("icon",void 0),this.set("isEnabled",!0),this.set("isOn",!1),this.set("isVisible",!0),this.set("isToggleable",!1),this.set("keystroke",void 0),this.set("label",void 0),this.set("role",void 0),this.set("tabindex",-1),this.set("tooltip",!1),this.set("tooltipPosition","s"),this.set("type","button"),this.set("withText",!1),this.set("withKeystroke",!1),this.children=this.createCollection(),this.labelView=this._setupLabelView(t),this.iconView=new Am,this.iconView.extendTemplate({attributes:{class:"ck-button__icon"}}),this.keystrokeView=this._createKeystrokeView(),this.bind("_tooltipString").to(this,"tooltip",this,"label",this,"keystroke",this._getTooltipString.bind(this));const i={tag:"button",attributes:{class:["ck","ck-button",o.to("class"),o.if("isEnabled","ck-disabled",(e=>!e)),o.if("isVisible","ck-hidden",(e=>!e)),o.to("isOn",(e=>e?"ck-on":"ck-off")),o.if("withText","ck-button_with-text"),o.if("withKeystroke","ck-button_with-keystroke")],role:o.to("role"),type:o.to("type",(e=>e||"button")),tabindex:o.to("tabindex"),"aria-checked":o.to("_ariaChecked"),"aria-pressed":o.to("_ariaPressed"),"aria-label":o.to("ariaLabel"),"aria-labelledby":o.to("ariaLabelledBy"),"aria-disabled":o.if("isEnabled",!0,(e=>!e)),"data-cke-tooltip-text":o.to("_tooltipString"),"data-cke-tooltip-position":o.to("tooltipPosition")},children:this.children,on:{click:o.to((e=>{this.isEnabled?this.fire("execute"):e.preventDefault()}))}};this.bind("_ariaPressed").to(this,"isOn",this,"isToggleable",this,"role",((e,t,o)=>!(!t||Dm(o))&&String(!!e))),this.bind("_ariaChecked").to(this,"isOn",this,"isToggleable",this,"role",((e,t,o)=>!(!t||!Dm(o))&&String(!!e))),r.isSafari&&(this._focusDelayed||(this._focusDelayed=or((()=>this.focus()),0)),i.on.mousedown=o.to((()=>{this._focusDelayed()})),i.on.mouseup=o.to((()=>{this._focusDelayed.cancel()}))),this.setTemplate(i)}render(){super.render(),this.icon&&(this.iconView.bind("content").to(this,"icon"),this.children.add(this.iconView)),this.children.add(this.labelView),this.withKeystroke&&this.keystroke&&this.children.add(this.keystrokeView)}focus(){this.element.focus()}destroy(){this._focusDelayed&&this._focusDelayed.cancel(),super.destroy()}_setupLabelView(e){return e.bind("text","style","id").to(this,"label","labelStyle","ariaLabelledBy"),e}_createKeystrokeView(){const e=new pm;return e.setTemplate({tag:"span",attributes:{class:["ck","ck-button__keystroke"]},children:[{text:this.bindTemplate.to("keystroke",(e=>Ai(e)))}]}),e}_getTooltipString(e,t,o){return e?"string"==typeof e?e:(o&&(o=Ai(o)),e instanceof Function?e(t,o):`${t}${o?` (${o})`:""}`):""}}function Dm(e){switch(e){case"radio":case"checkbox":case"option":case"switch":case"menuitemcheckbox":case"menuitemradio":return!0;default:return!1}}var Bm=i(4866),Sm={attributes:{"data-cke":!0}};Sm.setAttributes=Ar(),Sm.insert=_r().bind(null,"head"),Sm.domAPI=kr(),Sm.insertStyleElement=vr();fr()(Bm.A,Sm);Bm.A&&Bm.A.locals&&Bm.A.locals;class Tm extends pm{constructor(e,t={}){super(e);const o=this.bindTemplate;this.set("label",t.label||""),this.set("class",t.class||null),this.children=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-form__header",o.to("class")]},children:this.children}),t.icon&&(this.iconView=new Am,this.iconView.content=t.icon,this.children.add(this.iconView));const n=new pm(e);n.setTemplate({tag:"h2",attributes:{class:["ck","ck-form__header__label"],role:"presentation"},children:[{text:o.to("label")}]}),this.children.add(n)}}class Im extends(z()){constructor(e){if(super(),this.focusables=e.focusables,this.focusTracker=e.focusTracker,this.keystrokeHandler=e.keystrokeHandler,this.actions=e.actions,e.actions&&e.keystrokeHandler)for(const t in e.actions){let o=e.actions[t];"string"==typeof o&&(o=[o]);for(const n of o)e.keystrokeHandler.set(n,((e,o)=>{this[t](),o()}),e.keystrokeHandlerOptions)}this.on("forwardCycle",(()=>this.focusFirst()),{priority:"low"}),this.on("backwardCycle",(()=>this.focusLast()),{priority:"low"})}get first(){return this.focusables.find(Pm)||null}get last(){return this.focusables.filter(Pm).slice(-1)[0]||null}get next(){return this._getDomFocusableItem(1)}get previous(){return this._getDomFocusableItem(-1)}get current(){let e=null;return null===this.focusTracker.focusedElement?null:(this.focusables.find(((t,o)=>{const n=t.element===this.focusTracker.focusedElement;return n&&(e=o),n})),e)}focusFirst(){this._focus(this.first,1)}focusLast(){this._focus(this.last,-1)}focusNext(){const e=this.next;e&&this.focusables.getIndex(e)===this.current||e===this.first?this.fire("forwardCycle"):this._focus(e,1)}focusPrevious(){const e=this.previous;e&&this.focusables.getIndex(e)===this.current||e===this.last?this.fire("backwardCycle"):this._focus(e,-1)}chain(e){const t=()=>null===this.current?null:this.focusables.get(this.current);this.listenTo(e,"forwardCycle",(e=>{const o=t();this.focusNext(),o!==t()&&e.stop()}),{priority:"low"}),this.listenTo(e,"backwardCycle",(e=>{const o=t();this.focusPrevious(),o!==t()&&e.stop()}),{priority:"low"})}unchain(e){this.stopListening(e)}_focus(e,t){e&&this.focusTracker.focusedElement!==e.element&&e.focus(t)}_getDomFocusableItem(e){const t=this.focusables.length;if(!t)return null;const o=this.current;if(null===o)return this[1===e?"first":"last"];let n=this.focusables.get(o),i=(o+t+e)%t;do{const o=this.focusables.get(i);if(Pm(o)){n=o;break}i=(i+t+e)%t}while(i!==o);return n}}function Pm(e){return Fm(e)&&ti(e.element)}function Fm(e){return!(!("focus"in e)||"function"!=typeof e.focus)}function Mm(e){return class extends e{constructor(...e){super(...e),this._onDragBound=this._onDrag.bind(this),this._onDragEndBound=this._onDragEnd.bind(this),this._lastDraggingCoordinates={x:0,y:0},this.on("render",(()=>{this._attachListeners()})),this.set("isDragging",!1)}_attachListeners(){this.listenTo(this.element,"mousedown",this._onDragStart.bind(this)),this.listenTo(this.element,"touchstart",this._onDragStart.bind(this))}_attachDragListeners(){this.listenTo(t.document,"mouseup",this._onDragEndBound),this.listenTo(t.document,"touchend",this._onDragEndBound),this.listenTo(t.document,"mousemove",this._onDragBound),this.listenTo(t.document,"touchmove",this._onDragBound)}_detachDragListeners(){this.stopListening(t.document,"mouseup",this._onDragEndBound),this.stopListening(t.document,"touchend",this._onDragEndBound),this.stopListening(t.document,"mousemove",this._onDragBound),this.stopListening(t.document,"touchmove",this._onDragBound)}_onDragStart(e,t){if(!this._isHandleElementPressed(t))return;this._attachDragListeners();let o=0,n=0;t instanceof MouseEvent?(o=t.clientX,n=t.clientY):(o=t.touches[0].clientX,n=t.touches[0].clientY),this._lastDraggingCoordinates={x:o,y:n},this.isDragging=!0}_onDrag(e,t){if(!this.isDragging)return void this._detachDragListeners();let o=0,n=0;t instanceof MouseEvent?(o=t.clientX,n=t.clientY):(o=t.touches[0].clientX,n=t.touches[0].clientY),t.preventDefault(),this.fire("drag",{deltaX:Math.round(o-this._lastDraggingCoordinates.x),deltaY:Math.round(n-this._lastDraggingCoordinates.y)}),this._lastDraggingCoordinates={x:o,y:n}}_onDragEnd(){this._detachDragListeners(),this.isDragging=!1}_isHandleElementPressed(e){return!!this.dragHandleElement&&(this.dragHandleElement===e.target||e.target instanceof HTMLElement&&this.dragHandleElement.contains(e.target))}}}var Rm=i(8091),zm={attributes:{"data-cke":!0}};zm.setAttributes=Ar(),zm.insert=_r().bind(null,"head"),zm.domAPI=kr(),zm.insertStyleElement=vr();fr()(Rm.A,zm);Rm.A&&Rm.A.locals&&Rm.A.locals;class Vm extends pm{constructor(e){super(e),this.children=this.createCollection(),this.keystrokes=new er,this._focusTracker=new Xi,this._focusables=new Uh,this.focusCycler=new Im({focusables:this._focusables,focusTracker:this._focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-dialog__actions"]},children:this.children})}render(){super.render(),this.keystrokes.listenTo(this.element)}setButtons(e){for(const t of e){const e=new Em(this.locale);let o;for(o in e.on("execute",(()=>t.onExecute())),t.onCreate&&t.onCreate(e),t)"onExecute"!=o&&"onCreate"!=o&&e.set(o,t[o]);this.children.add(e)}this._updateFocusCyclableItems()}focus(e){-1===e?this.focusCycler.focusLast():this.focusCycler.focusFirst()}_updateFocusCyclableItems(){Array.from(this.children).forEach((e=>{this._focusables.add(e),this._focusTracker.add(e.element)}))}}class Om extends pm{constructor(e){super(e),this.children=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-dialog__content"]},children:this.children})}reset(){for(;this.children.length;)this.children.remove(0)}}var Nm=i(880),Lm={attributes:{"data-cke":!0}};Lm.setAttributes=Ar(),Lm.insert=_r().bind(null,"head"),Lm.domAPI=kr(),Lm.insertStyleElement=vr();fr()(Nm.A,Lm);Nm.A&&Nm.A.locals&&Nm.A.locals;const Hm="screen-center",jm="editor-center",qm="editor-top-side",Um="editor-top-center",Wm="editor-bottom-center",$m="editor-above-center",Gm="editor-below-center",Km=Yn("px");class Zm extends(Mm(pm)){constructor(e,{getCurrentDomRoot:t,getViewportOffset:o}){super(e),this.wasMoved=!1;const n=this.bindTemplate,i=e.t;this.set("className",""),this.set("ariaLabel",i("Editor dialog")),this.set("isModal",!1),this.set("position",Hm),this.set("_isVisible",!1),this.set("_isTransparent",!1),this.set("_top",0),this.set("_left",0),this._getCurrentDomRoot=t,this._getViewportOffset=o,this.decorate("moveTo"),this.parts=this.createCollection(),this.keystrokes=new er,this.focusTracker=new Xi,this._focusables=new Uh,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-dialog-overlay",n.if("isModal","ck-dialog-overlay__transparent",(e=>!e)),n.if("_isVisible","ck-hidden",(e=>!e))],tabindex:"-1"},children:[{tag:"div",attributes:{tabindex:"-1",class:["ck","ck-dialog",n.to("className")],role:"dialog","aria-label":n.to("ariaLabel"),style:{top:n.to("_top",(e=>Km(e))),left:n.to("_left",(e=>Km(e))),visibility:n.if("_isTransparent","hidden")}},children:this.parts}]})}render(){super.render(),this.keystrokes.set("Esc",((e,t)=>{this.fire("close",{source:"escKeyPress"}),t()})),this.on("drag",((e,{deltaX:t,deltaY:o})=>{this.wasMoved=!0,this.moveBy(t,o)})),this.listenTo(t.window,"resize",(()=>{this._isVisible&&!this.wasMoved&&this.updatePosition()})),this.listenTo(t.document,"scroll",(()=>{this._isVisible&&!this.wasMoved&&this.updatePosition()})),this.on("change:_isVisible",((e,t,o)=>{o&&(this._isTransparent=!0,setTimeout((()=>{this.updatePosition(),this._isTransparent=!1,this.focus()}),10))})),this.keystrokes.listenTo(this.element)}get dragHandleElement(){return this.headerView?this.headerView.element:null}setupParts({icon:e,title:t,hasCloseButton:o=!0,content:n,actionButtons:i}){t&&(this.headerView=new Tm(this.locale,{icon:e}),o&&(this.closeButtonView=this._createCloseButton(),this.headerView.children.add(this.closeButtonView)),this.headerView.label=t,this.ariaLabel=t,this.parts.add(this.headerView,0)),n&&(n instanceof pm&&(n=[n]),this.contentView=new Om(this.locale),this.contentView.children.addMany(n),this.parts.add(this.contentView)),i&&(this.actionsView=new Vm(this.locale),this.actionsView.setButtons(i),this.parts.add(this.actionsView)),this._updateFocusCyclableItems()}focus(){this._focusCycler.focusFirst()}moveTo(e,t){const o=this._getViewportRect(),n=this._getDialogRect();e+n.width>o.right&&(e=o.right-n.width),e{var t;this._focusables.add(e),this.focusTracker.add(e.element),Fm(t=e)&&"focusCycler"in t&&t.focusCycler instanceof Im&&this._focusCycler.chain(e.focusCycler)}))}_createCloseButton(){const e=new Em(this.locale),t=this.locale.t;return e.set({label:t("Close"),tooltip:!0,icon:qh.cancel}),e.on("execute",(()=>this.fire("close",{source:"closeButton"}))),e}}Zm.defaultOffset=15;const Jm=Zm;class Ym extends lr{static get pluginName(){return"Dialog"}constructor(e){super(e);const t=e.t;this._initShowHideListeners(),this._initFocusToggler(),this._initMultiRootIntegration(),this.set({id:null,isOpen:!1}),e.accessibility.addKeystrokeInfos({categoryId:"navigation",keystrokes:[{label:t("Move focus in and out of an active dialog window"),keystroke:"Ctrl+F6",mayRequireFn:!0}]})}_initShowHideListeners(){this.on("show",((e,t)=>{this._show(t)})),this.on("show",((e,t)=>{t.onShow&&t.onShow(this)}),{priority:"low"}),this.on("hide",(()=>{Ym._visibleDialogPlugin&&Ym._visibleDialogPlugin._hide()})),this.on("hide",(()=>{this._onHide&&(this._onHide(this),this._onHide=void 0)}),{priority:"low"})}_initFocusToggler(){const e=this.editor;e.keystrokes.set("Ctrl+F6",((t,o)=>{this.isOpen&&!this.view.isModal&&(this.view.focusTracker.isFocused?e.editing.view.focus():this.view.focus(),o())}))}_initMultiRootIntegration(){const e=this.editor.model;e.document.on("change:data",(()=>{if(!this.view)return;const t=e.document.differ.getChangedRoots();for(const e of t)e.state&&this.view.updatePosition()}))}show(e){this.hide(),this.fire(`show:${e.id}`,e)}_show({id:e,icon:t,title:o,hasCloseButton:n=!0,content:i,actionButtons:r,className:s,isModal:a,position:l,onHide:c}){const d=this.editor;this.view=new Jm(d.locale,{getCurrentDomRoot:()=>d.editing.view.getDomRoot(d.model.document.selection.anchor.root.rootName),getViewportOffset:()=>d.ui.viewportOffset});const u=this.view;u.on("close",(()=>{this.hide()})),d.ui.view.body.add(u),d.ui.focusTracker.add(u.element),d.keystrokes.listenTo(u.element),l||(l=a?Hm:jm),u.set({position:l,_isVisible:!0,className:s,isModal:a}),u.setupParts({icon:t,title:o,hasCloseButton:n,content:i,actionButtons:r}),this.id=e,c&&(this._onHide=c),this.isOpen=!0,Ym._visibleDialogPlugin=this}hide(){Ym._visibleDialogPlugin&&Ym._visibleDialogPlugin.fire(`hide:${Ym._visibleDialogPlugin.id}`)}_hide(){if(!this.view)return;const e=this.editor,t=this.view;t.contentView&&t.contentView.reset(),e.ui.view.body.remove(t),e.ui.focusTracker.remove(t.element),e.keystrokes.stopListening(t.element),t.destroy(),e.editing.view.focus(),this.id=null,this.isOpen=!1,Ym._visibleDialogPlugin=null}}var Qm=i(3389),Xm={attributes:{"data-cke":!0}};Xm.setAttributes=Ar(),Xm.insert=_r().bind(null,"head"),Xm.domAPI=kr(),Xm.insertStyleElement=vr();fr()(Qm.A,Xm);Qm.A&&Qm.A.locals&&Qm.A.locals;class ep extends Em{constructor(e,t=new Cm){super(e,t),this._checkIconHolderView=new tp,this.set({hasCheckSpace:!1,_hasCheck:this.isToggleable});const o=this.bindTemplate;this.extendTemplate({attributes:{class:["ck-list-item-button",o.if("isToggleable","ck-list-item-button_toggleable")]}}),this.bind("_hasCheck").to(this,"hasCheckSpace",this,"isToggleable",((e,t)=>e||t))}render(){super.render(),this._hasCheck&&this.children.add(this._checkIconHolderView,0),this._watchCheckIconHolderMount()}_watchCheckIconHolderMount(){this._checkIconHolderView.bind("isOn").to(this,"isOn",(e=>this.isToggleable&&e)),this.on("change:_hasCheck",((e,t,o)=>{const{children:n,_checkIconHolderView:i}=this;o?n.add(i,0):n.remove(i)}))}}class tp extends pm{constructor(){super(),this._checkIconView=this._createCheckIconView();const e=this.bindTemplate;this.children=this.createCollection(),this.set("isOn",!1),this.setTemplate({tag:"span",children:this.children,attributes:{class:["ck","ck-list-item-button__check-holder",e.to("isOn",(e=>e?"ck-on":"ck-off"))]}})}render(){super.render(),this.isOn&&this.children.add(this._checkIconView,0),this._watchCheckIconMount()}_watchCheckIconMount(){this.on("change:isOn",((e,t,o)=>{const{children:n,_checkIconView:i}=this;o&&!n.has(i)?n.add(i):!o&&n.has(i)&&n.remove(i)}))}_createCheckIconView(){const e=new Am;return e.content=qh.check,e.extendTemplate({attributes:{class:"ck-list-item-button__check-icon"}}),e}}var op=i(5078),np={attributes:{"data-cke":!0}};np.setAttributes=Ar(),np.insert=_r().bind(null,"head"),np.domAPI=kr(),np.insertStyleElement=vr();fr()(op.A,np);op.A&&op.A.locals&&op.A.locals;class ip extends ep{constructor(e){super(e),this.set({withText:!0,withKeystroke:!0,tooltip:!1,role:"menuitem"}),this.extendTemplate({attributes:{class:["ck-menu-bar__menu__item__button"]}})}}var rp=i(4606),sp={attributes:{"data-cke":!0}};sp.setAttributes=Ar(),sp.insert=_r().bind(null,"head"),sp.domAPI=kr(),sp.insertStyleElement=vr();fr()(rp.A,sp);rp.A&&rp.A.locals&&rp.A.locals;class ap extends pm{constructor(e){super(e),this.set("text",void 0),this.set("for",void 0),this.id=`ck-editor__label_${A()}`;const t=this.bindTemplate;this.setTemplate({tag:"label",attributes:{class:["ck","ck-label"],id:this.id,for:t.to("for")},children:[{text:t.to("text")}]})}}class lp extends pm{constructor(e,t){super(e);const o=e.t,n=new ap;n.text=o("Help Contents. To close this dialog press ESC."),this.setTemplate({tag:"div",attributes:{class:["ck","ck-accessibility-help-dialog__content"],"aria-labelledby":n.id,role:"document",tabindex:-1},children:[Ae(document,"p",{},o("Below, you can find a list of keyboard shortcuts that can be used in the editor.")),...this._createCategories(Array.from(t.values())),n]})}focus(){this.element.focus()}_createCategories(e){return e.map((e=>{const t=[Ae(document,"h3",{},e.label),...Array.from(e.groups.values()).map((e=>this._createGroup(e))).flat()];return e.description&&t.splice(1,0,Ae(document,"p",{},e.description)),Ae(document,"section",{},t)}))}_createGroup(e){const t=e.keystrokes.sort(((e,t)=>e.label.localeCompare(t.label))).map((e=>this._createGroupRow(e))).flat(),o=[Ae(document,"dl",{},t)];return e.label&&o.unshift(Ae(document,"h4",{},e.label)),o}_createGroupRow(e){const t=this.locale.t,o=Ae(document,"dt"),n=Ae(document,"dd"),i=function(e){if("string"==typeof e)return[[e]];if("string"==typeof e[0])return[e];return e}(e.keystroke),s=[];for(const e of i)s.push(e.map(cp).join(""));return o.innerHTML=e.label,n.innerHTML=s.join(", ")+(e.mayRequireFn&&r.isMac?` ${t("(may require Fn)")}`:""),[o,n]}}function cp(e){return Ai(e).split("+").map((e=>`${e}`)).join("+")}const dp='';var up=i(9550),hp={attributes:{"data-cke":!0}};hp.setAttributes=Ar(),hp.insert=_r().bind(null,"head"),hp.domAPI=kr(),hp.insertStyleElement=vr();fr()(up.A,hp);up.A&&up.A.locals&&up.A.locals;class mp extends lr{constructor(){super(...arguments),this.contentView=null}static get requires(){return[Ym]}static get pluginName(){return"AccessibilityHelp"}init(){const e=this.editor,t=e.locale.t;e.ui.componentFactory.add("accessibilityHelp",(()=>{const e=this._createButton(Em);return e.set({tooltip:!0,withText:!1,label:t("Accessibility help")}),e})),e.ui.componentFactory.add("menuBar:accessibilityHelp",(()=>{const e=this._createButton(ip);return e.label=t("Accessibility"),e})),e.keystrokes.set("Alt+0",((e,t)=>{this._toggleDialog(),t()})),this._setupRootLabels()}_createButton(e){const t=this.editor,o=t.plugins.get("Dialog"),n=new e(t.locale);return n.set({keystroke:"Alt+0",icon:dp,isToggleable:!0}),n.on("execute",(()=>this._toggleDialog())),n.bind("isOn").to(o,"id",(e=>"accessibilityHelp"===e)),n}_setupRootLabels(){const e=this.editor,t=e.editing.view,o=e.t;function n(e,t){const n=`${t.getAttribute("aria-label")}. ${o("Press %0 for help.",[Ai("Alt+0")])}`;e.setAttribute("aria-label",n,t)}e.ui.on("ready",(()=>{t.change((e=>{for(const o of t.document.roots)n(e,o)})),e.on("addRoot",((o,i)=>{const r=e.editing.view.document.getRoot(i.rootName);t.change((e=>n(e,r)))}),{priority:"low"})}))}_toggleDialog(){const e=this.editor,t=e.plugins.get("Dialog"),o=e.locale.t;this.contentView||(this.contentView=new lp(e.locale,e.accessibility.keystrokeInfos)),"accessibilityHelp"===t.id?t.hide():t.show({id:"accessibilityHelp",className:"ck-accessibility-help-dialog",title:o("Accessibility help"),icon:dp,hasCloseButton:!0,content:this.contentView})}}class pp extends Uh{constructor(e,t=[]){super(t),this.locale=e}get bodyCollectionContainer(){return this._bodyCollectionContainer}attachToDom(){this._bodyCollectionContainer=new Wh({tag:"div",attributes:{class:["ck","ck-reset_all","ck-body","ck-rounded-corners"],dir:this.locale.uiLanguageDirection,role:"application"},children:this}).render();let e=document.querySelector(".ck-body-wrapper");e||(e=Ae(document,"div",{class:"ck-body-wrapper"}),document.body.appendChild(e)),e.appendChild(this._bodyCollectionContainer)}detachFromDom(){super.destroy(),this._bodyCollectionContainer&&this._bodyCollectionContainer.remove();const e=document.querySelector(".ck-body-wrapper");e&&0==e.childElementCount&&e.remove()}}var gp=i(9624),fp={attributes:{"data-cke":!0}};fp.setAttributes=Ar(),fp.insert=_r().bind(null,"head"),fp.domAPI=kr(),fp.insertStyleElement=vr();fr()(gp.A,fp);gp.A&&gp.A.locals&&gp.A.locals;class bp extends Em{constructor(e){super(e),this.isToggleable=!0,this.toggleSwitchView=this._createToggleView(),this.extendTemplate({attributes:{class:"ck-switchbutton"}})}render(){super.render(),this.children.add(this.toggleSwitchView)}_createToggleView(){const e=new pm;return e.setTemplate({tag:"span",attributes:{class:["ck","ck-button__toggle"]},children:[{tag:"span",attributes:{class:["ck","ck-button__toggle__inner"]}}]}),e}}class kp extends(_p(Em)){}class wp extends(_p(ep)){}function _p(e){return class extends e{constructor(...e){super(...e),this.buttonView=this,this._fileInputView=new yp(this.locale),this._fileInputView.bind("acceptedType").to(this),this._fileInputView.bind("allowMultipleFiles").to(this),this._fileInputView.delegate("done").to(this),this.on("execute",(()=>{this._fileInputView.open()})),this.extendTemplate({attributes:{class:"ck-file-dialog-button"}})}render(){super.render(),this.children.add(this._fileInputView)}}}class yp extends pm{constructor(e){super(e),this.set("acceptedType",void 0),this.set("allowMultipleFiles",!1);const t=this.bindTemplate;this.setTemplate({tag:"input",attributes:{class:["ck-hidden"],type:"file",tabindex:"-1",accept:t.to("acceptedType"),multiple:t.to("allowMultipleFiles")},on:{change:t.to((()=>{this.element&&this.element.files&&this.element.files.length&&this.fire("done",this.element.files),this.element.value=""}))}})}open(){this.element.click()}}const Ap='';var Cp=i(1750),vp={attributes:{"data-cke":!0}};vp.setAttributes=Ar(),vp.insert=_r().bind(null,"head"),vp.domAPI=kr(),vp.insertStyleElement=vr();fr()(Cp.A,vp);Cp.A&&Cp.A.locals&&Cp.A.locals;class xp extends pm{constructor(e,t){super(e);const o=this.bindTemplate;this.set("isCollapsed",!1),this.set("label",""),this.buttonView=this._createButtonView(),this.children=this.createCollection(),this.set("_collapsibleAriaLabelUid",void 0),t&&this.children.addMany(t),this.setTemplate({tag:"div",attributes:{class:["ck","ck-collapsible",o.if("isCollapsed","ck-collapsible_collapsed")]},children:[this.buttonView,{tag:"div",attributes:{class:["ck","ck-collapsible__children"],role:"region",hidden:o.if("isCollapsed","hidden"),"aria-labelledby":o.to("_collapsibleAriaLabelUid")},children:this.children}]})}render(){super.render(),this._collapsibleAriaLabelUid=this.buttonView.labelView.element.id}focus(){this.buttonView.focus()}_createButtonView(){const e=new Em(this.locale),t=e.bindTemplate;return e.set({withText:!0,icon:Ap}),e.extendTemplate({attributes:{"aria-expanded":t.to("isOn",(e=>String(e)))}}),e.bind("label").to(this),e.bind("isOn").to(this,"isCollapsed",(e=>!e)),e.on("execute",(()=>{this.isCollapsed=!this.isCollapsed})),e}}function Ep(e,t){const o=e.t,n={Black:o("Black"),"Dim grey":o("Dim grey"),Grey:o("Grey"),"Light grey":o("Light grey"),White:o("White"),Red:o("Red"),Orange:o("Orange"),Yellow:o("Yellow"),"Light green":o("Light green"),Green:o("Green"),Aquamarine:o("Aquamarine"),Turquoise:o("Turquoise"),"Light blue":o("Light blue"),Blue:o("Blue"),Purple:o("Purple")};return t.map((e=>{const t=n[e.label];return t&&t!=e.label&&(e.label=t),e}))}function Dp(e){return e.map(Bp).filter((e=>!!e))}function Bp(e){return"string"==typeof e?{model:e,label:e,hasBorder:!1,view:{name:"span",styles:{color:e}}}:{model:e.color,label:e.label||e.color,hasBorder:void 0!==e.hasBorder&&e.hasBorder,view:{name:"span",styles:{color:`${e.color}`}}}}class Sp extends Em{constructor(e){super(e);const t=this.bindTemplate;this.set("color",void 0),this.set("hasBorder",!1),this.icon='',this.extendTemplate({attributes:{style:{backgroundColor:t.to("color",(e=>r.isMediaForcedColors?null:e))},class:["ck","ck-color-grid__tile",t.if("hasBorder","ck-color-selector__color-tile_bordered")]}})}render(){super.render(),this.iconView.fillColor="hsl(0, 0%, 100%)"}}var Tp=i(7962),Ip={attributes:{"data-cke":!0}};Ip.setAttributes=Ar(),Ip.insert=_r().bind(null,"head"),Ip.domAPI=kr(),Ip.insertStyleElement=vr();fr()(Tp.A,Ip);Tp.A&&Tp.A.locals&&Tp.A.locals;class Pp extends pm{constructor(e,t){super(e);const o=t&&t.colorDefinitions?t.colorDefinitions:[];this.columns=t&&t.columns?t.columns:5;const n={gridTemplateColumns:`repeat( ${this.columns}, 1fr)`};this.set("selectedColor",void 0),this.items=this.createCollection(),this.focusTracker=new Xi,this.keystrokes=new er,this.items.on("add",((e,t)=>{t.isOn=t.color===this.selectedColor})),o.forEach((e=>{const t=new Sp;t.set({color:e.color,label:e.label,tooltip:!0,hasBorder:e.options.hasBorder}),t.on("execute",(()=>{this.fire("execute",{value:e.color,hasBorder:e.options.hasBorder,label:e.label})})),this.items.add(t)})),this.setTemplate({tag:"div",children:this.items,attributes:{class:["ck","ck-color-grid"],style:n}}),this.on("change:selectedColor",((e,t,o)=>{for(const e of this.items)e.isOn=e.color===o}))}focus(){this.items.length&&this.items.first.focus()}focusLast(){this.items.length&&this.items.last.focus()}render(){super.render();for(const e of this.items)this.focusTracker.add(e.element);this.items.on("add",((e,t)=>{this.focusTracker.add(t.element)})),this.items.on("remove",((e,t)=>{this.focusTracker.remove(t.element)})),this.keystrokes.listenTo(this.element),km({keystrokeHandler:this.keystrokes,focusTracker:this.focusTracker,gridItems:this.items,numberOfColumns:this.columns,uiLanguageDirection:this.locale&&this.locale.uiLanguageDirection})}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}}var Fp=i(8156);const Mp=function(e){var t,o,n=[],i=1;if("string"==typeof e)if(Fp[e])n=Fp[e].slice(),o="rgb";else if("transparent"===e)i=0,o="rgb",n=[0,0,0];else if(/^#[A-Fa-f0-9]+$/.test(e)){var r=e.slice(1);i=1,(l=r.length)<=4?(n=[parseInt(r[0]+r[0],16),parseInt(r[1]+r[1],16),parseInt(r[2]+r[2],16)],4===l&&(i=parseInt(r[3]+r[3],16)/255)):(n=[parseInt(r[0]+r[1],16),parseInt(r[2]+r[3],16),parseInt(r[4]+r[5],16)],8===l&&(i=parseInt(r[6]+r[7],16)/255)),n[0]||(n[0]=0),n[1]||(n[1]=0),n[2]||(n[2]=0),o="rgb"}else if(t=/^((?:rgb|hs[lvb]|hwb|cmyk?|xy[zy]|gray|lab|lchu?v?|[ly]uv|lms)a?)\s*\(([^\)]*)\)/.exec(e)){var s=t[1],a="rgb"===s;o=r=s.replace(/a$/,"");var l="cmyk"===r?4:"gray"===r?1:3;n=t[2].trim().split(/\s*[,\/]\s*|\s+/).map((function(e,t){if(/%$/.test(e))return t===l?parseFloat(e)/100:"rgb"===r?255*parseFloat(e)/100:parseFloat(e);if("h"===r[t]){if(/deg$/.test(e))return parseFloat(e);if(void 0!==Rp[e])return Rp[e]}return parseFloat(e)})),s===r&&n.push(1),i=a||void 0===n[l]?1:n[l],n=n.slice(0,l)}else e.length>10&&/[0-9](?:\s|\/)/.test(e)&&(n=e.match(/([0-9]+)/g).map((function(e){return parseFloat(e)})),o=e.match(/([a-z])/gi).join("").toLowerCase());else isNaN(e)?Array.isArray(e)||e.length?(n=[e[0],e[1],e[2]],o="rgb",i=4===e.length?e[3]:1):e instanceof Object&&(null!=e.r||null!=e.red||null!=e.R?(o="rgb",n=[e.r||e.red||e.R||0,e.g||e.green||e.G||0,e.b||e.blue||e.B||0]):(o="hsl",n=[e.h||e.hue||e.H||0,e.s||e.saturation||e.S||0,e.l||e.lightness||e.L||e.b||e.brightness]),i=e.a||e.alpha||e.opacity||1,null!=e.opacity&&(i/=100)):(o="rgb",n=[e>>>16,(65280&e)>>>8,255&e]);return{space:o,values:n,alpha:i}};var Rp={red:0,orange:60,yellow:120,green:180,blue:240,purple:300};var zp=i(734),Vp=i.t(zp,2);function Op(e,t){if(!e)return"";const o=Np(e);if(!o)return"";if(o.space===t)return e;if(n=o,!Object.keys(Vp).includes(n.space))return"";var n;const i=Vp[o.space][t];if(!i)return"";return function(e,t){switch(t){case"hex":return`#${e}`;case"rgb":return`rgb( ${e[0]}, ${e[1]}, ${e[2]} )`;case"hsl":return`hsl( ${e[0]}, ${e[1]}%, ${e[2]}% )`;case"hwb":return`hwb( ${e[0]}, ${e[1]}, ${e[2]} )`;case"lab":return`lab( ${e[0]}% ${e[1]} ${e[2]} )`;case"lch":return`lch( ${e[0]}% ${e[1]} ${e[2]} )`;default:return""}}(i("hex"===o.space?o.hexValue:o.values),t)}function Np(e){if(e.startsWith("#")){const t=Mp(e);return{space:"hex",values:t.values,hexValue:e,alpha:t.alpha}}const t=Mp(e);return t.space?t:null}var Lp=i(6365),Hp={attributes:{"data-cke":!0}};Hp.setAttributes=Ar(),Hp.insert=_r().bind(null,"head"),Hp.domAPI=kr(),Hp.insertStyleElement=vr();fr()(Lp.A,Hp);Lp.A&&Lp.A.locals&&Lp.A.locals;class jp extends pm{constructor(e,t){super(e);const o=`ck-labeled-field-view-${A()}`,n=`ck-labeled-field-view-status-${A()}`;this.fieldView=t(this,o,n),this.set("label",void 0),this.set("isEnabled",!0),this.set("isEmpty",!0),this.set("isFocused",!1),this.set("errorText",null),this.set("infoText",null),this.set("class",void 0),this.set("placeholder",void 0),this.labelView=this._createLabelView(o),this.statusView=this._createStatusView(n),this.fieldWrapperChildren=this.createCollection([this.fieldView,this.labelView]),this.bind("_statusText").to(this,"errorText",this,"infoText",((e,t)=>e||t));const i=this.bindTemplate;this.setTemplate({tag:"div",attributes:{class:["ck","ck-labeled-field-view",i.to("class"),i.if("isEnabled","ck-disabled",(e=>!e)),i.if("isEmpty","ck-labeled-field-view_empty"),i.if("isFocused","ck-labeled-field-view_focused"),i.if("placeholder","ck-labeled-field-view_placeholder"),i.if("errorText","ck-error")]},children:[{tag:"div",attributes:{class:["ck","ck-labeled-field-view__input-wrapper"]},children:this.fieldWrapperChildren},this.statusView]})}_createLabelView(e){const t=new ap(this.locale);return t.for=e,t.bind("text").to(this,"label"),t}_createStatusView(e){const t=new pm(this.locale),o=this.bindTemplate;return t.setTemplate({tag:"div",attributes:{class:["ck","ck-labeled-field-view__status",o.if("errorText","ck-labeled-field-view__status_error"),o.if("_statusText","ck-hidden",(e=>!e))],id:e,role:o.if("errorText","alert")},children:[{text:o.to("_statusText")}]}),t}focus(e){this.fieldView.focus(e)}}class qp extends pm{constructor(e){super(e),this.set("value",void 0),this.set("id",void 0),this.set("placeholder",void 0),this.set("tabIndex",void 0),this.set("isReadOnly",!1),this.set("hasError",!1),this.set("ariaDescribedById",void 0),this.set("ariaLabel",void 0),this.focusTracker=new Xi,this.bind("isFocused").to(this.focusTracker),this.set("isEmpty",!0);const t=this.bindTemplate;this.setTemplate({tag:"input",attributes:{class:["ck","ck-input",t.if("isFocused","ck-input_focused"),t.if("isEmpty","ck-input-text_empty"),t.if("hasError","ck-error")],id:t.to("id"),placeholder:t.to("placeholder"),tabindex:t.to("tabIndex"),readonly:t.to("isReadOnly"),"aria-invalid":t.if("hasError",!0),"aria-describedby":t.to("ariaDescribedById"),"aria-label":t.to("ariaLabel")},on:{input:t.to(((...e)=>{this.fire("input",...e),this._updateIsEmpty()})),change:t.to(this._updateIsEmpty.bind(this))}})}render(){super.render(),this.focusTracker.add(this.element),this._setDomElementValue(this.value),this._updateIsEmpty(),this.on("change:value",((e,t,o)=>{this._setDomElementValue(o),this._updateIsEmpty()}))}destroy(){super.destroy(),this.focusTracker.destroy()}select(){this.element.select()}focus(){this.element.focus()}reset(){this.value=this.element.value="",this._updateIsEmpty()}_updateIsEmpty(){this.isEmpty=!this.element.value}_setDomElementValue(e){this.element.value=e||0===e?e:""}}var Up=i(1546),Wp={attributes:{"data-cke":!0}};Wp.setAttributes=Ar(),Wp.insert=_r().bind(null,"head"),Wp.domAPI=kr(),Wp.insertStyleElement=vr();fr()(Up.A,Wp);Up.A&&Up.A.locals&&Up.A.locals;class $p extends qp{constructor(e){super(e),this.set("inputMode","text");const t=this.bindTemplate;this.extendTemplate({attributes:{inputmode:t.to("inputMode")}})}}class Gp extends $p{constructor(e){super(e),this.extendTemplate({attributes:{type:"text",class:["ck-input-text"]}})}}class Kp extends $p{constructor(e,{min:t,max:o,step:n}={}){super(e);const i=this.bindTemplate;this.set("min",t),this.set("max",o),this.set("step",n),this.extendTemplate({attributes:{type:"number",class:["ck-input-number"],min:i.to("min"),max:i.to("max"),step:i.to("step")}})}}var Zp=i(8368),Jp={attributes:{"data-cke":!0}};Jp.setAttributes=Ar(),Jp.insert=_r().bind(null,"head"),Jp.domAPI=kr(),Jp.insertStyleElement=vr();fr()(Zp.A,Jp);Zp.A&&Zp.A.locals&&Zp.A.locals;class Yp extends pm{constructor(e){super(e);const t=this.bindTemplate;this.set("isVisible",!1),this.set("position","se"),this.children=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-reset","ck-dropdown__panel",t.to("position",(e=>`ck-dropdown__panel_${e}`)),t.if("isVisible","ck-dropdown__panel-visible")],tabindex:"-1"},children:this.children,on:{selectstart:t.to((e=>{"input"!==e.target.tagName.toLocaleLowerCase()&&e.preventDefault()}))}})}focus(){if(this.children.length){const e=this.children.first;"function"==typeof e.focus?e.focus():D("ui-dropdown-panel-focus-child-missing-focus",{childView:this.children.first,dropdownPanel:this})}}focusLast(){if(this.children.length){const e=this.children.last;"function"==typeof e.focusLast?e.focusLast():e.focus()}}}var Qp=i(426),Xp={attributes:{"data-cke":!0}};Xp.setAttributes=Ar(),Xp.insert=_r().bind(null,"head"),Xp.domAPI=kr(),Xp.insertStyleElement=vr();fr()(Qp.A,Xp);Qp.A&&Qp.A.locals&&Qp.A.locals;class eg extends pm{constructor(e,t,o){super(e);const n=this.bindTemplate;this.buttonView=t,this.panelView=o,this.set("isOpen",!1),this.set("isEnabled",!0),this.set("class",void 0),this.set("id",void 0),this.set("panelPosition","auto"),this.panelView.bind("isVisible").to(this,"isOpen"),this.keystrokes=new er,this.focusTracker=new Xi,this.setTemplate({tag:"div",attributes:{class:["ck","ck-dropdown",n.to("class"),n.if("isEnabled","ck-disabled",(e=>!e))],id:n.to("id"),"aria-describedby":n.to("ariaDescribedById")},children:[t,o]}),t.extendTemplate({attributes:{class:["ck-dropdown__button"],"data-cke-tooltip-disabled":n.to("isOpen")}})}render(){super.render(),this.focusTracker.add(this.buttonView.element),this.focusTracker.add(this.panelView.element),this.listenTo(this.buttonView,"open",(()=>{this.isOpen=!this.isOpen})),this.on("change:isOpen",((e,t,o)=>{if(o)if("auto"===this.panelPosition){const e=eg._getOptimalPosition({element:this.panelView.element,target:this.buttonView.element,fitInViewport:!0,positions:this._panelPositions});this.panelView.position=e?e.name:this._panelPositions[0].name}else this.panelView.position=this.panelPosition})),this.keystrokes.listenTo(this.element);const e=(e,t)=>{this.isOpen&&(this.isOpen=!1,t())};this.keystrokes.set("arrowdown",((e,t)=>{this.buttonView.isEnabled&&!this.isOpen&&(this.isOpen=!0,t())})),this.keystrokes.set("arrowright",((e,t)=>{this.isOpen&&t()})),this.keystrokes.set("arrowleft",e),this.keystrokes.set("esc",e)}focus(){this.buttonView.focus()}get _panelPositions(){const{south:e,north:t,southEast:o,southWest:n,northEast:i,northWest:r,southMiddleEast:s,southMiddleWest:a,northMiddleEast:l,northMiddleWest:c}=eg.defaultPanelPositions;return"rtl"!==this.locale.uiLanguageDirection?[o,n,s,a,e,i,r,l,c,t]:[n,o,a,s,e,r,i,c,l,t]}}eg.defaultPanelPositions={south:(e,t)=>({top:e.bottom,left:e.left-(t.width-e.width)/2,name:"s"}),southEast:e=>({top:e.bottom,left:e.left,name:"se"}),southWest:(e,t)=>({top:e.bottom,left:e.left-t.width+e.width,name:"sw"}),southMiddleEast:(e,t)=>({top:e.bottom,left:e.left-(t.width-e.width)/4,name:"sme"}),southMiddleWest:(e,t)=>({top:e.bottom,left:e.left-3*(t.width-e.width)/4,name:"smw"}),north:(e,t)=>({top:e.top-t.height,left:e.left-(t.width-e.width)/2,name:"n"}),northEast:(e,t)=>({top:e.top-t.height,left:e.left,name:"ne"}),northWest:(e,t)=>({top:e.top-t.height,left:e.left-t.width+e.width,name:"nw"}),northMiddleEast:(e,t)=>({top:e.top-t.height,left:e.left-(t.width-e.width)/4,name:"nme"}),northMiddleWest:(e,t)=>({top:e.top-t.height,left:e.left-3*(t.width-e.width)/4,name:"nmw"})},eg._getOptimalPosition=oi;const tg=eg;class og extends Em{constructor(e){super(e),this.arrowView=this._createArrowView(),this.extendTemplate({attributes:{"aria-haspopup":!0,"aria-expanded":this.bindTemplate.to("isOn",(e=>String(e)))}}),this.delegate("execute").to(this,"open")}render(){super.render(),this.children.add(this.arrowView)}_createArrowView(){const e=new Am;return e.content=Ap,e.extendTemplate({attributes:{class:"ck-dropdown__arrow"}}),e}}class ng extends pm{constructor(e){super(e),this.setTemplate({tag:"span",attributes:{class:["ck","ck-toolbar__separator"]}})}}class ig extends pm{constructor(e){super(e),this.setTemplate({tag:"span",attributes:{class:["ck","ck-toolbar__line-break"]}})}}function rg(e){if(Array.isArray(e))return{items:e,removeItems:[]};const t={items:[],removeItems:[]};return e?{...t,...e}:t}var sg=i(66),ag={attributes:{"data-cke":!0}};ag.setAttributes=Ar(),ag.insert=_r().bind(null,"head"),ag.domAPI=kr(),ag.insertStyleElement=vr();fr()(sg.A,ag);sg.A&&sg.A.locals&&sg.A.locals;const lg=(()=>({alignLeft:qh.alignLeft,bold:qh.bold,importExport:qh.importExport,paragraph:qh.paragraph,plus:qh.plus,text:qh.text,threeVerticalDots:qh.threeVerticalDots,pilcrow:qh.pilcrow,dragIndicator:qh.dragIndicator}))();class cg extends pm{constructor(e,t){super(e);const o=this.bindTemplate,n=this.t;this.options=t||{},this.set("ariaLabel",n("Editor toolbar")),this.set("maxWidth","auto"),this.items=this.createCollection(),this.focusTracker=new Xi,this.keystrokes=new er,this.set("class",void 0),this.set("isCompact",!1),this.itemsView=new dg(e),this.children=this.createCollection(),this.children.add(this.itemsView),this.focusables=this.createCollection();const i="rtl"===e.uiLanguageDirection;this._focusCycler=new Im({focusables:this.focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:[i?"arrowright":"arrowleft","arrowup"],focusNext:[i?"arrowleft":"arrowright","arrowdown"]}});const r=["ck","ck-toolbar",o.to("class"),o.if("isCompact","ck-toolbar_compact")];var s;this.options.shouldGroupWhenFull&&this.options.isFloating&&r.push("ck-toolbar_floating"),this.setTemplate({tag:"div",attributes:{class:r,role:"toolbar","aria-label":o.to("ariaLabel"),style:{maxWidth:o.to("maxWidth")},tabindex:-1},children:this.children,on:{mousedown:(s=this,s.bindTemplate.to((e=>{e.target===s.element&&e.preventDefault()})))}}),this._behavior=this.options.shouldGroupWhenFull?new hg(this):new ug(this)}render(){super.render(),this.focusTracker.add(this.element);for(const e of this.items)this.focusTracker.add(e.element);this.items.on("add",((e,t)=>{this.focusTracker.add(t.element)})),this.items.on("remove",((e,t)=>{this.focusTracker.remove(t.element)})),this.keystrokes.listenTo(this.element),this._behavior.render(this)}destroy(){return this._behavior.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy(),super.destroy()}focus(){this._focusCycler.focusFirst()}focusLast(){this._focusCycler.focusLast()}fillFromConfig(e,t,o){this.items.addMany(this._buildItemsFromConfig(e,t,o))}_buildItemsFromConfig(e,t,o){const n=rg(e),i=o||n.removeItems;return this._cleanItemsConfiguration(n.items,t,i).map((e=>U(e)?this._createNestedToolbarDropdown(e,t,i):"|"===e?new ng:"-"===e?new ig:t.create(e))).filter((e=>!!e))}_cleanItemsConfiguration(e,t,o){const n=e.filter(((e,n,i)=>"|"===e||-1===o.indexOf(e)&&("-"===e?!this.options.shouldGroupWhenFull||(D("toolbarview-line-break-ignored-when-grouping-items",i),!1):!(!U(e)&&!t.has(e))||(D("toolbarview-item-unavailable",{item:e}),!1))));return this._cleanSeparatorsAndLineBreaks(n)}_cleanSeparatorsAndLineBreaks(e){const t=e=>"-"!==e&&"|"!==e,o=e.length,n=e.findIndex(t);if(-1===n)return[];const i=o-e.slice().reverse().findIndex(t);return e.slice(n,i).filter(((e,o,n)=>{if(t(e))return!0;return!(o>0&&n[o-1]===e)}))}_createNestedToolbarDropdown(e,t,o){let{label:n,icon:i,items:r,tooltip:s=!0,withText:a=!1}=e;if(r=this._cleanItemsConfiguration(r,t,o),!r.length)return null;const l=Eg(this.locale);return n||D("toolbarview-nested-toolbar-dropdown-missing-label",e),l.class="ck-toolbar__nested-toolbar-dropdown",l.buttonView.set({label:n,tooltip:s,withText:!!a}),!1!==i?l.buttonView.icon=lg[i]||i||qh.threeVerticalDots:l.buttonView.withText=!0,Dg(l,(()=>l.toolbarView._buildItemsFromConfig(r,t,o))),l}}class dg extends pm{constructor(e){super(e),this.children=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-toolbar__items"]},children:this.children})}}class ug{constructor(e){const t=e.bindTemplate;e.set("isVertical",!1),e.itemsView.children.bindTo(e.items).using((e=>e)),e.focusables.bindTo(e.items).using((e=>Fm(e)?e:null)),e.extendTemplate({attributes:{class:[t.if("isVertical","ck-toolbar_vertical")]}})}render(){}destroy(){}}class hg{constructor(e){this.resizeObserver=null,this.cachedPadding=null,this.shouldUpdateGroupingOnNextResize=!1,this.view=e,this.viewChildren=e.children,this.viewFocusables=e.focusables,this.viewItemsView=e.itemsView,this.viewFocusTracker=e.focusTracker,this.viewLocale=e.locale,this.ungroupedItems=e.createCollection(),this.groupedItems=e.createCollection(),this.groupedItemsDropdown=this._createGroupedItemsDropdown(),e.itemsView.children.bindTo(this.ungroupedItems).using((e=>e)),this.ungroupedItems.on("change",this._updateFocusCyclableItems.bind(this)),e.children.on("change",this._updateFocusCyclableItems.bind(this)),e.items.on("change",((e,t)=>{const o=t.index,n=Array.from(t.added);for(const e of t.removed)o>=this.ungroupedItems.length?this.groupedItems.remove(e):this.ungroupedItems.remove(e);for(let e=o;ethis.ungroupedItems.length?this.groupedItems.add(t,e-this.ungroupedItems.length):this.ungroupedItems.add(t,e)}this._updateGrouping()})),e.extendTemplate({attributes:{class:["ck-toolbar_grouping"]}})}render(e){this.viewElement=e.element,this._enableGroupingOnResize(),this._enableGroupingOnMaxWidthChange(e)}destroy(){this.groupedItemsDropdown.destroy(),this.resizeObserver.destroy()}_updateGrouping(){if(!this.viewElement.ownerDocument.body.contains(this.viewElement))return;if(!ti(this.viewElement))return void(this.shouldUpdateGroupingOnNextResize=!0);const e=this.groupedItems.length;let t;for(;this._areItemsOverflowing;)this._groupLastItem(),t=!0;if(!t&&this.groupedItems.length){for(;this.groupedItems.length&&!this._areItemsOverflowing;)this._ungroupFirstItem();this._areItemsOverflowing&&this._groupLastItem()}this.groupedItems.length!==e&&this.view.fire("groupedItemsUpdate")}get _areItemsOverflowing(){if(!this.ungroupedItems.length)return!1;const e=this.viewElement,o=this.viewLocale.uiLanguageDirection,n=new qn(e.lastChild),i=new qn(e);if(!this.cachedPadding){const n=t.window.getComputedStyle(e),i="ltr"===o?"paddingRight":"paddingLeft";this.cachedPadding=Number.parseInt(n[i])}return"ltr"===o?n.right>i.right-this.cachedPadding:n.left{e&&e===t.contentRect.width&&!this.shouldUpdateGroupingOnNextResize||(this.shouldUpdateGroupingOnNextResize=!1,this._updateGrouping(),e=t.contentRect.width)})),this._updateGrouping()}_enableGroupingOnMaxWidthChange(e){e.on("change:maxWidth",(()=>{this._updateGrouping()}))}_groupLastItem(){this.groupedItems.length||(this.viewChildren.add(new ng),this.viewChildren.add(this.groupedItemsDropdown),this.viewFocusTracker.add(this.groupedItemsDropdown.element)),this.groupedItems.add(this.ungroupedItems.remove(this.ungroupedItems.last),0)}_ungroupFirstItem(){this.ungroupedItems.add(this.groupedItems.remove(this.groupedItems.first)),this.groupedItems.length||(this.viewChildren.remove(this.groupedItemsDropdown),this.viewChildren.remove(this.viewChildren.last),this.viewFocusTracker.remove(this.groupedItemsDropdown.element))}_createGroupedItemsDropdown(){const e=this.viewLocale,t=e.t,o=Eg(e);return o.class="ck-toolbar__grouped-dropdown",o.panelPosition="ltr"===e.uiLanguageDirection?"sw":"se",Dg(o,this.groupedItems),o.buttonView.set({label:t("Show more items"),tooltip:!0,tooltipPosition:"rtl"===e.uiLanguageDirection?"se":"sw",icon:qh.threeVerticalDots}),o}_updateFocusCyclableItems(){this.viewFocusables.clear(),this.ungroupedItems.map((e=>{Fm(e)&&this.viewFocusables.add(e)})),this.groupedItems.length&&this.viewFocusables.add(this.groupedItemsDropdown)}}class mg extends pm{constructor(e){super(e);const t=this.bindTemplate;this.set("isVisible",!0),this.children=this.createCollection(),this.setTemplate({tag:"li",attributes:{class:["ck","ck-list__item",t.if("isVisible","ck-hidden",(e=>!e))],role:"presentation"},children:this.children})}focus(){this.children.first&&this.children.first.focus()}}class pg extends pm{constructor(e){super(e),this.setTemplate({tag:"li",attributes:{class:["ck","ck-list__separator"]}})}}class gg extends pm{constructor(e,t=new ap){super(e);const o=this.bindTemplate,n=new kg(e);this.set({label:"",isVisible:!0}),this.labelView=t,this.labelView.bind("text").to(this,"label"),this.children=this.createCollection(),this.children.addMany([this.labelView,n]),n.set({role:"group",ariaLabelledBy:t.id}),n.focusTracker.destroy(),n.keystrokes.destroy(),this.items=n.items,this.setTemplate({tag:"li",attributes:{role:"presentation",class:["ck","ck-list__group",o.if("isVisible","ck-hidden",(e=>!e))]},children:this.children})}focus(){if(this.items){const e=this.items.find((e=>!(e instanceof pg)));e&&e.focus()}}}var fg=i(6048),bg={attributes:{"data-cke":!0}};bg.setAttributes=Ar(),bg.insert=_r().bind(null,"head"),bg.domAPI=kr(),bg.insertStyleElement=vr();fr()(fg.A,bg);fg.A&&fg.A.locals&&fg.A.locals;class kg extends pm{constructor(e){super(e),this._listItemGroupToChangeListeners=new WeakMap;const t=this.bindTemplate;this.focusables=new Uh,this.items=this.createCollection(),this.focusTracker=new Xi,this.keystrokes=new er,this._focusCycler=new Im({focusables:this.focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"arrowup",focusNext:"arrowdown"}}),this.set("ariaLabel",void 0),this.set("ariaLabelledBy",void 0),this.set("role",void 0),this.setTemplate({tag:"ul",attributes:{class:["ck","ck-reset","ck-list"],role:t.to("role"),"aria-label":t.to("ariaLabel"),"aria-labelledby":t.to("ariaLabelledBy")},children:this.items})}render(){super.render();for(const e of this.items)e instanceof gg?this._registerFocusableItemsGroup(e):e instanceof mg&&this._registerFocusableListItem(e);this.items.on("change",((e,t)=>{for(const e of t.removed)e instanceof gg?this._deregisterFocusableItemsGroup(e):e instanceof mg&&this._deregisterFocusableListItem(e);for(const e of Array.from(t.added).reverse())e instanceof gg?this._registerFocusableItemsGroup(e,t.index):this._registerFocusableListItem(e,t.index)})),this.keystrokes.listenTo(this.element)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this._focusCycler.focusFirst()}focusFirst(){this._focusCycler.focusFirst()}focusLast(){this._focusCycler.focusLast()}_registerFocusableListItem(e,t){this.focusTracker.add(e.element),this.focusables.add(e,t)}_deregisterFocusableListItem(e){this.focusTracker.remove(e.element),this.focusables.remove(e)}_getOnGroupItemsChangeCallback(e){return(t,o)=>{for(const e of o.removed)this._deregisterFocusableListItem(e);for(const t of Array.from(o.added).reverse())this._registerFocusableListItem(t,this.items.getIndex(e)+o.index)}}_registerFocusableItemsGroup(e,t){Array.from(e.items).forEach(((e,o)=>{const n=void 0!==t?t+o:void 0;this._registerFocusableListItem(e,n)}));const o=this._getOnGroupItemsChangeCallback(e);this._listItemGroupToChangeListeners.set(e,o),e.items.on("change",o)}_deregisterFocusableItemsGroup(e){for(const t of e.items)this._deregisterFocusableListItem(t);e.items.off("change",this._listItemGroupToChangeListeners.get(e)),this._listItemGroupToChangeListeners.delete(e)}}var wg=i(7133),_g={attributes:{"data-cke":!0}};_g.setAttributes=Ar(),_g.insert=_r().bind(null,"head"),_g.domAPI=kr(),_g.insertStyleElement=vr();fr()(wg.A,_g);wg.A&&wg.A.locals&&wg.A.locals;class yg extends pm{constructor(e,t){super(e);const o=this.bindTemplate;this.set("class",void 0),this.set("labelStyle",void 0),this.set("icon",void 0),this.set("isEnabled",!0),this.set("isOn",!1),this.set("isToggleable",!1),this.set("isVisible",!0),this.set("keystroke",void 0),this.set("withKeystroke",!1),this.set("label",void 0),this.set("tabindex",-1),this.set("tooltip",!1),this.set("tooltipPosition","s"),this.set("type","button"),this.set("withText",!1),this.children=this.createCollection(),this.actionView=this._createActionView(t),this.arrowView=this._createArrowView(),this.keystrokes=new er,this.focusTracker=new Xi,this.setTemplate({tag:"div",attributes:{class:["ck","ck-splitbutton",o.to("class"),o.if("isVisible","ck-hidden",(e=>!e)),this.arrowView.bindTemplate.if("isOn","ck-splitbutton_open")]},children:this.children})}render(){super.render(),this.children.add(this.actionView),this.children.add(this.arrowView),this.focusTracker.add(this.actionView.element),this.focusTracker.add(this.arrowView.element),this.keystrokes.listenTo(this.element),this.keystrokes.set("arrowright",((e,t)=>{this.focusTracker.focusedElement===this.actionView.element&&(this.arrowView.focus(),t())})),this.keystrokes.set("arrowleft",((e,t)=>{this.focusTracker.focusedElement===this.arrowView.element&&(this.actionView.focus(),t())}))}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this.actionView.focus()}_createActionView(e){const t=e||new Em;return e||t.bind("icon","isEnabled","isOn","isToggleable","keystroke","label","tabindex","tooltip","tooltipPosition","type","withText").to(this),t.extendTemplate({attributes:{class:"ck-splitbutton__action"}}),t.delegate("execute").to(this),t}_createArrowView(){const e=new Em,t=e.bindTemplate;return e.icon=Ap,e.extendTemplate({attributes:{class:["ck-splitbutton__arrow"],"data-cke-tooltip-disabled":t.to("isOn"),"aria-haspopup":!0,"aria-expanded":t.to("isOn",(e=>String(e)))}}),e.bind("isEnabled").to(this),e.bind("label").to(this),e.bind("tooltip").to(this),e.delegate("execute").to(this,"open"),e}}var Ag=i(7475),Cg={attributes:{"data-cke":!0}};Cg.setAttributes=Ar(),Cg.insert=_r().bind(null,"head"),Cg.domAPI=kr(),Cg.insertStyleElement=vr();fr()(Ag.A,Cg);Ag.A&&Ag.A.locals&&Ag.A.locals;var vg=i(2454),xg={attributes:{"data-cke":!0}};xg.setAttributes=Ar(),xg.insert=_r().bind(null,"head"),xg.domAPI=kr(),xg.insertStyleElement=vr();fr()(vg.A,xg);vg.A&&vg.A.locals&&vg.A.locals;function Eg(e,o=og){const n="function"==typeof o?new o(e):o,i=new Yp(e),r=new tg(e,n,i);return n.bind("isEnabled").to(r),n instanceof yg?n.arrowView.bind("isOn").to(r,"isOpen"):n.bind("isOn").to(r,"isOpen"),function(e){(function(e){e.on("render",(()=>{gm({emitter:e,activator:()=>e.isOpen,callback:()=>{e.isOpen=!1},contextElements:()=>[e.element,...e.focusTracker._elements]})}))})(e),function(e){e.on("execute",(t=>{t.source instanceof bp||(e.isOpen=!1)}))}(e),function(e){e.focusTracker.on("change:isFocused",((t,o,n)=>{e.isOpen&&!n&&(e.isOpen=!1)}))}(e),function(e){e.keystrokes.set("arrowdown",((t,o)=>{e.isOpen&&(e.panelView.focus(),o())})),e.keystrokes.set("arrowup",((t,o)=>{e.isOpen&&(e.panelView.focusLast(),o())}))}(e),function(e){e.on("change:isOpen",((o,n,i)=>{if(i)return;const r=e.panelView.element;r&&r.contains(t.document.activeElement)&&e.buttonView.focus()}))}(e),function(e){e.on("change:isOpen",((t,o,n)=>{n&&e.panelView.focus()}),{priority:"low"})}(e)}(r),r}function Dg(e,t,o={}){e.extendTemplate({attributes:{class:["ck-toolbar-dropdown"]}}),e.isOpen?Bg(e,t,o):e.once("change:isOpen",(()=>Bg(e,t,o)),{priority:"highest"}),o.enableActiveItemFocusOnDropdownOpen&&Ig(e,(()=>e.toolbarView.items.find((e=>e.isOn))))}function Bg(e,t,o){const n=e.locale,i=n.t,r=e.toolbarView=new cg(n),s="function"==typeof t?t():t;r.ariaLabel=o.ariaLabel||i("Dropdown toolbar"),o.maxWidth&&(r.maxWidth=o.maxWidth),o.class&&(r.class=o.class),o.isCompact&&(r.isCompact=o.isCompact),o.isVertical&&(r.isVertical=!0),s instanceof Uh?r.items.bindTo(s).using((e=>e)):r.items.addMany(s),e.panelView.children.add(r),r.items.delegate("execute").to(e)}function Sg(e,t,o={}){e.isOpen?Tg(e,t,o):e.once("change:isOpen",(()=>Tg(e,t,o)),{priority:"highest"}),Ig(e,(()=>e.listView.items.find((e=>e instanceof mg&&e.children.first.isOn))))}function Tg(e,t,o){const n=e.locale,i=e.listView=new kg(n),r="function"==typeof t?t():t;i.ariaLabel=o.ariaLabel,i.role=o.role,Pg(e,i.items,r,n),e.panelView.children.add(i),i.items.delegate("execute").to(e)}function Ig(e,t){e.on("change:isOpen",(()=>{if(!e.isOpen)return;const o=t();o&&("function"==typeof o.focus?o.focus():D("ui-dropdown-focus-child-on-open-child-missing-focus",{view:o}))}),{priority:C.low-10})}function Pg(e,t,o,n){t.on("change",(()=>{const e=[...t].reduce(((e,t)=>(t instanceof mg&&t.children.first instanceof ep&&e.push(t.children.first),e)),[]),o=e.some((e=>e.isToggleable));e.forEach((e=>{e.hasCheckSpace=o}))})),t.bindTo(o).using((t=>{if("separator"===t.type)return new pg(n);if("group"===t.type){const o=new gg(n);return o.set({label:t.label}),Pg(e,o.items,t.items,n),o.items.delegate("execute").to(e),o}if("button"===t.type||"switchbutton"===t.type){const e="menuitemcheckbox"===t.model.role||"menuitemradio"===t.model.role,o=new mg(n);let i;return"button"===t.type?(i=new ep(n),i.set({isToggleable:e})):i=new bp(n),i.bind(...Object.keys(t.model)).to(t.model),i.delegate("execute").to(o),o.children.add(i),o}return null}))}const Fg=(e,t,o)=>{const n=new Gp(e.locale);return n.set({id:t,ariaDescribedById:o}),n.bind("isReadOnly").to(e,"isEnabled",(e=>!e)),n.bind("hasError").to(e,"errorText",(e=>!!e)),n.on("input",(()=>{e.errorText=null})),e.bind("isEmpty","isFocused","placeholder").to(n),n},Mg=(e,t,o)=>{const n=new Kp(e.locale);return n.set({id:t,ariaDescribedById:o,inputMode:"numeric"}),n.bind("isReadOnly").to(e,"isEnabled",(e=>!e)),n.bind("hasError").to(e,"errorText",(e=>!!e)),n.on("input",(()=>{e.errorText=null})),e.bind("isEmpty","isFocused","placeholder").to(n),n},Rg=(e,t,o)=>{const n=Eg(e.locale);return n.set({id:t,ariaDescribedById:o}),n.bind("isEnabled").to(e),n},zg=(e,t=0,o=1)=>e>o?o:eMath.round(o*e)/o,Og=(Math.PI,e=>("#"===e[0]&&(e=e.substring(1)),e.length<6?{r:parseInt(e[0]+e[0],16),g:parseInt(e[1]+e[1],16),b:parseInt(e[2]+e[2],16),a:4===e.length?Vg(parseInt(e[3]+e[3],16)/255,2):1}:{r:parseInt(e.substring(0,2),16),g:parseInt(e.substring(2,4),16),b:parseInt(e.substring(4,6),16),a:8===e.length?Vg(parseInt(e.substring(6,8),16)/255,2):1})),Ng=({h:e,s:t,v:o,a:n})=>{const i=(200-t)*o/100;return{h:Vg(e),s:Vg(i>0&&i<200?t*o/100/(i<=100?i:200-i)*100:0),l:Vg(i/2),a:Vg(n,2)}},Lg=e=>{const{h:t,s:o,l:n}=Ng(e);return`hsl(${t}, ${o}%, ${n}%)`},Hg=({h:e,s:t,v:o,a:n})=>{e=e/360*6,t/=100,o/=100;const i=Math.floor(e),r=o*(1-t),s=o*(1-(e-i)*t),a=o*(1-(1-e+i)*t),l=i%6;return{r:Vg(255*[o,s,r,r,a,o][l]),g:Vg(255*[a,o,o,s,r,r][l]),b:Vg(255*[r,r,a,o,o,s][l]),a:Vg(n,2)}},jg=e=>{const t=e.toString(16);return t.length<2?"0"+t:t},qg=({r:e,g:t,b:o,a:n})=>{const i=n<1?jg(Vg(255*n)):"";return"#"+jg(e)+jg(t)+jg(o)+i},Ug=({r:e,g:t,b:o,a:n})=>{const i=Math.max(e,t,o),r=i-Math.min(e,t,o),s=r?i===e?(t-o)/r:i===t?2+(o-e)/r:4+(e-t)/r:0;return{h:Vg(60*(s<0?s+6:s)),s:Vg(i?r/i*100:0),v:Vg(i/255*100),a:n}},Wg=(e,t)=>{if(e===t)return!0;for(const o in e)if(e[o]!==t[o])return!1;return!0},$g={},Gg=e=>{let t=$g[e];return t||(t=document.createElement("template"),t.innerHTML=e,$g[e]=t),t},Kg=(e,t,o)=>{e.dispatchEvent(new CustomEvent(t,{bubbles:!0,detail:o}))};let Zg=!1;const Jg=e=>"touches"in e,Yg=(e,t)=>{const o=Jg(t)?t.touches[0]:t,n=e.el.getBoundingClientRect();Kg(e.el,"move",e.getMove({x:zg((o.pageX-(n.left+window.pageXOffset))/n.width),y:zg((o.pageY-(n.top+window.pageYOffset))/n.height)}))};class Qg{constructor(e,t,o,n){const i=Gg(`
    `);e.appendChild(i.content.cloneNode(!0));const r=e.querySelector(`[part=${t}]`);r.addEventListener("mousedown",this),r.addEventListener("touchstart",this),r.addEventListener("keydown",this),this.el=r,this.xy=n,this.nodes=[r.firstChild,r]}set dragging(e){const t=e?document.addEventListener:document.removeEventListener;t(Zg?"touchmove":"mousemove",this),t(Zg?"touchend":"mouseup",this)}handleEvent(e){switch(e.type){case"mousedown":case"touchstart":if(e.preventDefault(),!(e=>!(Zg&&!Jg(e)||(Zg||(Zg=Jg(e)),0)))(e)||!Zg&&0!=e.button)return;this.el.focus(),Yg(this,e),this.dragging=!0;break;case"mousemove":case"touchmove":e.preventDefault(),Yg(this,e);break;case"mouseup":case"touchend":this.dragging=!1;break;case"keydown":((e,t)=>{const o=t.keyCode;o>40||e.xy&&o<37||o<33||(t.preventDefault(),Kg(e.el,"move",e.getMove({x:39===o?.01:37===o?-.01:34===o?.05:33===o?-.05:35===o?1:36===o?-1:0,y:40===o?.01:38===o?-.01:0},!0)))})(this,e)}}style(e){e.forEach(((e,t)=>{for(const o in e)this.nodes[t].style.setProperty(o,e[o])}))}}class Xg extends Qg{constructor(e){super(e,"hue",'aria-label="Hue" aria-valuemin="0" aria-valuemax="360"',!1)}update({h:e}){this.h=e,this.style([{left:e/360*100+"%",color:Lg({h:e,s:100,v:100,a:1})}]),this.el.setAttribute("aria-valuenow",`${Vg(e)}`)}getMove(e,t){return{h:t?zg(this.h+360*e.x,0,360):360*e.x}}}class ef extends Qg{constructor(e){super(e,"saturation",'aria-label="Color"',!0)}update(e){this.hsva=e,this.style([{top:100-e.v+"%",left:`${e.s}%`,color:Lg(e)},{"background-color":Lg({h:e.h,s:100,v:100,a:1})}]),this.el.setAttribute("aria-valuetext",`Saturation ${Vg(e.s)}%, Brightness ${Vg(e.v)}%`)}getMove(e,t){return{s:t?zg(this.hsva.s+100*e.x,0,100):100*e.x,v:t?zg(this.hsva.v-100*e.y,0,100):Math.round(100-100*e.y)}}}const tf=Symbol("same"),of=Symbol("color"),nf=Symbol("hsva"),rf=Symbol("update"),sf=Symbol("parts"),af=Symbol("css"),lf=Symbol("sliders");class cf extends HTMLElement{static get observedAttributes(){return["color"]}get[af](){return[':host{display:flex;flex-direction:column;position:relative;width:200px;height:200px;user-select:none;-webkit-user-select:none;cursor:default}:host([hidden]){display:none!important}[role=slider]{position:relative;touch-action:none;user-select:none;-webkit-user-select:none;outline:0}[role=slider]:last-child{border-radius:0 0 8px 8px}[part$=pointer]{position:absolute;z-index:1;box-sizing:border-box;width:28px;height:28px;display:flex;place-content:center center;transform:translate(-50%,-50%);background-color:#fff;border:2px solid #fff;border-radius:50%;box-shadow:0 2px 4px rgba(0,0,0,.2)}[part$=pointer]::after{content:"";width:100%;height:100%;border-radius:inherit;background-color:currentColor}[role=slider]:focus [part$=pointer]{transform:translate(-50%,-50%) scale(1.1)}',"[part=hue]{flex:0 0 24px;background:linear-gradient(to right,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red 100%)}[part=hue-pointer]{top:50%;z-index:2}","[part=saturation]{flex-grow:1;border-color:transparent;border-bottom:12px solid #000;border-radius:8px 8px 0 0;background-image:linear-gradient(to top,#000,transparent),linear-gradient(to right,#fff,rgba(255,255,255,0));box-shadow:inset 0 0 0 1px rgba(0,0,0,.05)}[part=saturation-pointer]{z-index:3}"]}get[lf](){return[ef,Xg]}get color(){return this[of]}set color(e){if(!this[tf](e)){const t=this.colorModel.toHsva(e);this[rf](t),this[of]=e}}constructor(){super();const e=Gg(``),t=this.attachShadow({mode:"open"});t.appendChild(e.content.cloneNode(!0)),t.addEventListener("move",this),this[sf]=this[lf].map((e=>new e(t)))}connectedCallback(){if(this.hasOwnProperty("color")){const e=this.color;delete this.color,this.color=e}else this.color||(this.color=this.colorModel.defaultColor)}attributeChangedCallback(e,t,o){const n=this.colorModel.fromAttr(o);this[tf](n)||(this.color=n)}handleEvent(e){const t=this[nf],o={...t,...e.detail};let n;this[rf](o),Wg(o,t)||this[tf](n=this.colorModel.fromHsva(o))||(this[of]=n,Kg(this,"color-changed",{value:n}))}[tf](e){return this.color&&this.colorModel.equal(e,this.color)}[rf](e){this[nf]=e,this[sf].forEach((t=>t.update(e)))}}const df={defaultColor:"#000",toHsva:e=>Ug(Og(e)),fromHsva:({h:e,s:t,v:o})=>qg(Hg({h:e,s:t,v:o,a:1})),equal:(e,t)=>e.toLowerCase()===t.toLowerCase()||Wg(Og(e),Og(t)),fromAttr:e=>e};class uf extends cf{get colorModel(){return df}}var hf=i(3086),mf={attributes:{"data-cke":!0}};mf.setAttributes=Ar(),mf.insert=_r().bind(null,"head"),mf.domAPI=kr(),mf.insertStyleElement=vr();fr()(hf.A,mf);hf.A&&hf.A.locals&&hf.A.locals;class pf extends pm{constructor(e,t={}){super(e),this.set({color:"",_hexColor:""}),this.hexInputRow=this._createInputRow();const o=this.createCollection();t.hideInput||o.add(this.hexInputRow),this.setTemplate({tag:"div",attributes:{class:["ck","ck-color-picker"],tabindex:-1},children:o}),this._config=t,this._debounceColorPickerEvent=el((e=>{this.set("color",e),this.fire("colorSelected",{color:this.color})}),150,{leading:!0}),this.on("set:color",((e,t,o)=>{e.return=Op(o,this._config.format||"hsl")})),this.on("change:color",(()=>{this._hexColor=gf(this.color)})),this.on("change:_hexColor",(()=>{document.activeElement!==this.picker&&this.picker.setAttribute("color",this._hexColor),gf(this.color)!=gf(this._hexColor)&&(this.color=this._hexColor)}))}render(){var e,o;if(super.render(),e="hex-color-picker",o=uf,void 0===customElements.get(e)&&customElements.define(e,o),this.picker=t.document.createElement("hex-color-picker"),this.picker.setAttribute("class","hex-color-picker"),this.picker.setAttribute("tabindex","-1"),this._createSlidersView(),this.element){this.hexInputRow.element?this.element.insertBefore(this.picker,this.hexInputRow.element):this.element.appendChild(this.picker);const e=document.createElement("style");e.textContent='[role="slider"]:focus [part$="pointer"] {border: 1px solid #fff;outline: 1px solid var(--ck-color-focus-border);box-shadow: 0 0 0 2px #fff;}',this.picker.shadowRoot.appendChild(e)}this.picker.addEventListener("color-changed",(e=>{const t=e.detail.value;this._debounceColorPickerEvent(t)}))}focus(){if(!this._config.hideInput&&(r.isGecko||r.isiOS||r.isSafari)){this.hexInputRow.children.get(1).focus()}this.slidersView.first.focus()}_createSlidersView(){const e=[...this.picker.shadowRoot.children].filter((e=>"slider"===e.getAttribute("role"))).map((e=>new ff(e)));this.slidersView=this.createCollection(),e.forEach((e=>{this.slidersView.add(e)}))}_createInputRow(){const e=this._createColorInput();return new kf(this.locale,e)}_createColorInput(){const e=new jp(this.locale,Fg),{t}=this.locale;return e.set({label:t("HEX"),class:"color-picker-hex-input"}),e.fieldView.bind("value").to(this,"_hexColor",(t=>e.isFocused?e.fieldView.value:t.startsWith("#")?t.substring(1):t)),e.fieldView.on("input",(()=>{const t=e.fieldView.element.value;if(t){const e=wf(t);e&&this._debounceColorPickerEvent(e)}})),e}isValid(){const{t:e}=this.locale;return!!this._config.hideInput||(this.resetValidationStatus(),!!this.hexInputRow.getParsedColor()||(this.hexInputRow.inputView.errorText=e('Please enter a valid color (e.g. "ff0000").'),!1))}resetValidationStatus(){this.hexInputRow.inputView.errorText=null}}function gf(e){let t=function(e){if(!e)return"";const t=Np(e);return t?"hex"===t.space?t.hexValue:Op(e,"hex"):"#000"}(e);return t||(t="#000"),4===t.length&&(t="#"+[t[1],t[1],t[2],t[2],t[3],t[3]].join("")),t.toLowerCase()}class ff extends pm{constructor(e){super(),this.element=e}focus(){this.element.focus()}}class bf extends pm{constructor(e){super(e),this.setTemplate({tag:"div",attributes:{class:["ck","ck-color-picker__hash-view"]},children:"#"})}}class kf extends pm{constructor(e,t){super(e),this.inputView=t,this.children=this.createCollection([new bf,this.inputView]),this.setTemplate({tag:"div",attributes:{class:["ck","ck-color-picker__row"]},children:this.children})}getParsedColor(){return wf(this.inputView.fieldView.element.value)}}function wf(e){if(!e)return null;const t=e.trim().replace(/^#/,"");return[3,4,6,8].includes(t.length)&&/^(([0-9a-fA-F]{2}){3,4}|([0-9a-fA-F]){3,4})$/.test(t)?`#${t}`:null}class _f extends(Y(Yi)){constructor(e){super(e),this.set("isEmpty",!0),this.on("change",(()=>{this.set("isEmpty",0===this.length)}))}add(e,t){return this.find((t=>t.color===e.color))?this:super.add(e,t)}hasColor(e){return!!this.find((t=>t.color===e))}}class yf extends pm{constructor(e,{colors:t,columns:o,removeButtonLabel:n,documentColorsLabel:i,documentColorsCount:r,colorPickerLabel:s,focusTracker:a,focusables:l}){super(e);const c=this.bindTemplate;this.set("isVisible",!0),this.focusTracker=a,this.items=this.createCollection(),this.colorDefinitions=t,this.columns=o,this.documentColors=new _f,this.documentColorsCount=r,this._focusables=l,this._removeButtonLabel=n,this._colorPickerLabel=s,this._documentColorsLabel=i,this.setTemplate({tag:"div",attributes:{class:["ck-color-grids-fragment",c.if("isVisible","ck-hidden",(e=>!e))]},children:this.items}),this.removeColorButtonView=this._createRemoveColorButton(),this.items.add(this.removeColorButtonView)}updateDocumentColors(e,t){const o=e.document,n=this.documentColorsCount;this.documentColors.clear();for(const i of o.getRoots()){const o=e.createRangeIn(i);for(const e of o.getItems())if(e.is("$textProxy")&&e.hasAttribute(t)&&(this._addColorToDocumentColors(e.getAttribute(t)),this.documentColors.length>=n))return}}updateSelectedColors(){const e=this.documentColorsGrid,t=this.staticColorsGrid,o=this.selectedColor;t.selectedColor=o,e&&(e.selectedColor=o)}render(){if(super.render(),this.staticColorsGrid=this._createStaticColorsGrid(),this.items.add(this.staticColorsGrid),this.documentColorsCount){const e=Wh.bind(this.documentColors,this.documentColors),t=new pm(this.locale);t.setTemplate({tag:"span",attributes:{class:["ck","ck-color-grid__label",e.if("isEmpty","ck-hidden")]},children:[{text:this._documentColorsLabel}]}),this.items.add(t),this.documentColorsGrid=this._createDocumentColorsGrid(),this.items.add(this.documentColorsGrid)}this._createColorPickerButton(),this._addColorSelectorElementsToFocusTracker()}focus(){this.removeColorButtonView.focus()}destroy(){super.destroy()}addColorPickerButton(){this.colorPickerButtonView&&(this.items.add(this.colorPickerButtonView),this.focusTracker.add(this.colorPickerButtonView.element),this._focusables.add(this.colorPickerButtonView))}_addColorSelectorElementsToFocusTracker(){this.focusTracker.add(this.removeColorButtonView.element),this._focusables.add(this.removeColorButtonView),this.staticColorsGrid&&(this.focusTracker.add(this.staticColorsGrid.element),this._focusables.add(this.staticColorsGrid)),this.documentColorsGrid&&(this.focusTracker.add(this.documentColorsGrid.element),this._focusables.add(this.documentColorsGrid))}_createColorPickerButton(){this.colorPickerButtonView=new Em,this.colorPickerButtonView.set({label:this._colorPickerLabel,withText:!0,icon:qh.colorPalette,class:"ck-color-selector__color-picker"}),this.colorPickerButtonView.on("execute",(()=>{this.fire("colorPicker:show")}))}_createRemoveColorButton(){const e=new Em;return e.set({withText:!0,icon:qh.eraser,label:this._removeButtonLabel}),e.class="ck-color-selector__remove-color",e.on("execute",(()=>{this.fire("execute",{value:null,source:"removeColorButton"})})),e.render(),e}_createStaticColorsGrid(){const e=new Pp(this.locale,{colorDefinitions:this.colorDefinitions,columns:this.columns});return e.on("execute",((e,t)=>{this.fire("execute",{value:t.value,source:"staticColorsGrid"})})),e}_createDocumentColorsGrid(){const e=Wh.bind(this.documentColors,this.documentColors),t=new Pp(this.locale,{columns:this.columns});return t.extendTemplate({attributes:{class:e.if("isEmpty","ck-hidden")}}),t.items.bindTo(this.documentColors).using((e=>{const t=new Sp;return t.set({color:e.color,hasBorder:e.options&&e.options.hasBorder}),e.label&&t.set({label:e.label,tooltip:!0}),t.on("execute",(()=>{this.fire("execute",{value:e.color,source:"documentColorsGrid"})})),t})),this.documentColors.on("change:isEmpty",((e,o,n)=>{n&&(t.selectedColor=null)})),t}_addColorToDocumentColors(e){const t=this.colorDefinitions.find((t=>t.color===e));t?this.documentColors.add(Object.assign({},t)):this.documentColors.add({color:e,label:e,options:{hasBorder:!1}})}}class Af extends pm{constructor(e,{focusTracker:t,focusables:o,keystrokes:n,colorPickerViewConfig:i}){super(e),this.items=this.createCollection(),this.focusTracker=t,this.keystrokes=n,this.set("isVisible",!1),this.set("selectedColor",void 0),this._focusables=o,this._colorPickerViewConfig=i;const r=this.bindTemplate,{saveButtonView:s,cancelButtonView:a}=this._createActionButtons();this.saveButtonView=s,this.cancelButtonView=a,this.actionBarView=this._createActionBarView({saveButtonView:s,cancelButtonView:a}),this.setTemplate({tag:"div",attributes:{class:["ck-color-picker-fragment",r.if("isVisible","ck-hidden",(e=>!e))]},children:this.items})}render(){super.render();const e=new pf(this.locale,{...this._colorPickerViewConfig});this.colorPickerView=e,this.colorPickerView.render(),this.selectedColor&&(e.color=this.selectedColor),this.listenTo(this,"change:selectedColor",((t,o,n)=>{e.color=n})),this.items.add(this.colorPickerView),this.items.add(this.actionBarView),this._addColorPickersElementsToFocusTracker(),this._stopPropagationOnArrowsKeys(),this._executeOnEnterPress(),this._executeUponColorChange()}destroy(){super.destroy()}focus(){this.colorPickerView.focus()}resetValidationStatus(){this.colorPickerView.resetValidationStatus()}_executeOnEnterPress(){this.keystrokes.set("enter",(e=>{this.isVisible&&this.focusTracker.focusedElement!==this.cancelButtonView.element&&this.colorPickerView.isValid()&&(this.fire("execute",{value:this.selectedColor}),e.stopPropagation(),e.preventDefault())}))}_stopPropagationOnArrowsKeys(){const e=e=>e.stopPropagation();this.keystrokes.set("arrowright",e),this.keystrokes.set("arrowleft",e),this.keystrokes.set("arrowup",e),this.keystrokes.set("arrowdown",e)}_addColorPickersElementsToFocusTracker(){for(const e of this.colorPickerView.slidersView)this.focusTracker.add(e.element),this._focusables.add(e);const e=this.colorPickerView.hexInputRow.children.get(1);e.element&&(this.focusTracker.add(e.element),this._focusables.add(e)),this.focusTracker.add(this.saveButtonView.element),this._focusables.add(this.saveButtonView),this.focusTracker.add(this.cancelButtonView.element),this._focusables.add(this.cancelButtonView)}_createActionBarView({saveButtonView:e,cancelButtonView:t}){const o=new pm,n=this.createCollection();return n.add(e),n.add(t),o.setTemplate({tag:"div",attributes:{class:["ck","ck-color-selector_action-bar"]},children:n}),o}_createActionButtons(){const e=this.locale,t=e.t,o=new Em(e),n=new Em(e);return o.set({icon:qh.check,class:"ck-button-save",type:"button",withText:!1,label:t("Accept")}),n.set({icon:qh.cancel,class:"ck-button-cancel",type:"button",withText:!1,label:t("Cancel")}),o.on("execute",(()=>{this.colorPickerView.isValid()&&this.fire("execute",{source:"colorPickerSaveButton",value:this.selectedColor})})),n.on("execute",(()=>{this.fire("colorPicker:cancel")})),{saveButtonView:o,cancelButtonView:n}}_executeUponColorChange(){this.colorPickerView.on("colorSelected",((e,t)=>{this.fire("execute",{value:t.color,source:"colorPicker"}),this.set("selectedColor",t.color)}))}}var Cf=i(2922),vf={attributes:{"data-cke":!0}};vf.setAttributes=Ar(),vf.insert=_r().bind(null,"head"),vf.domAPI=kr(),vf.insertStyleElement=vr();fr()(Cf.A,vf);Cf.A&&Cf.A.locals&&Cf.A.locals;class xf extends pm{constructor(e,{colors:t,columns:o,removeButtonLabel:n,documentColorsLabel:i,documentColorsCount:r,colorPickerLabel:s,colorPickerViewConfig:a}){super(e),this.items=this.createCollection(),this.focusTracker=new Xi,this.keystrokes=new er,this._focusables=new Uh,this._colorPickerViewConfig=a,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.colorGridsFragmentView=new yf(e,{colors:t,columns:o,removeButtonLabel:n,documentColorsLabel:i,documentColorsCount:r,colorPickerLabel:s,focusTracker:this.focusTracker,focusables:this._focusables}),this.colorPickerFragmentView=new Af(e,{focusables:this._focusables,focusTracker:this.focusTracker,keystrokes:this.keystrokes,colorPickerViewConfig:a}),this.set("_isColorGridsFragmentVisible",!0),this.set("_isColorPickerFragmentVisible",!1),this.set("selectedColor",void 0),this.colorGridsFragmentView.bind("isVisible").to(this,"_isColorGridsFragmentVisible"),this.colorPickerFragmentView.bind("isVisible").to(this,"_isColorPickerFragmentVisible"),this.on("change:selectedColor",((e,t,o)=>{this.colorGridsFragmentView.set("selectedColor",o),this.colorPickerFragmentView.set("selectedColor",o)})),this.colorGridsFragmentView.on("change:selectedColor",((e,t,o)=>{this.set("selectedColor",o)})),this.colorPickerFragmentView.on("change:selectedColor",((e,t,o)=>{this.set("selectedColor",o)})),this.setTemplate({tag:"div",attributes:{class:["ck","ck-color-selector"]},children:this.items})}render(){super.render(),this.keystrokes.listenTo(this.element)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}appendUI(){this._appendColorGridsFragment(),this._colorPickerViewConfig&&this._appendColorPickerFragment()}showColorPickerFragment(){this.colorPickerFragmentView.colorPickerView&&!this._isColorPickerFragmentVisible&&(this._isColorPickerFragmentVisible=!0,this.colorPickerFragmentView.focus(),this.colorPickerFragmentView.resetValidationStatus(),this._isColorGridsFragmentVisible=!1)}showColorGridsFragment(){this._isColorGridsFragmentVisible||(this._isColorGridsFragmentVisible=!0,this.colorGridsFragmentView.focus(),this._isColorPickerFragmentVisible=!1)}focus(){this._focusCycler.focusFirst()}focusLast(){this._focusCycler.focusLast()}updateDocumentColors(e,t){this.colorGridsFragmentView.updateDocumentColors(e,t)}updateSelectedColors(){this.colorGridsFragmentView.updateSelectedColors()}_appendColorGridsFragment(){this.items.length||(this.items.add(this.colorGridsFragmentView),this.colorGridsFragmentView.delegate("execute").to(this),this.colorGridsFragmentView.delegate("colorPicker:show").to(this))}_appendColorPickerFragment(){2!==this.items.length&&(this.items.add(this.colorPickerFragmentView),this.colorGridsFragmentView.colorPickerButtonView&&this.colorGridsFragmentView.colorPickerButtonView.on("execute",(()=>{this.showColorPickerFragment()})),this.colorGridsFragmentView.addColorPickerButton(),this.colorPickerFragmentView.delegate("execute").to(this),this.colorPickerFragmentView.delegate("colorPicker:cancel").to(this))}}class Ef{constructor(e){this._components=new Map,this.editor=e}*names(){for(const e of this._components.values())yield e.originalName}add(e,t){this._components.set(Df(e),{callback:t,originalName:e})}create(e){if(!this.has(e))throw new E("componentfactory-item-missing",this,{name:e});return this._components.get(Df(e)).callback(this.editor.locale)}has(e){return this._components.has(Df(e))}}function Df(e){return String(e).toLowerCase()}var Bf=i(5615),Sf={attributes:{"data-cke":!0}};Sf.setAttributes=Ar(),Sf.insert=_r().bind(null,"head"),Sf.domAPI=kr(),Sf.insertStyleElement=vr();fr()(Bf.A,Sf);Bf.A&&Bf.A.locals&&Bf.A.locals;const Tf=Yn("px"),If={top:-99999,left:-99999,name:"arrowless",config:{withArrow:!1}};class Pf extends pm{constructor(e){super(e);const t=this.bindTemplate;this.set("top",0),this.set("left",0),this.set("position","arrow_nw"),this.set("isVisible",!1),this.set("withArrow",!0),this.set("class",void 0),this._pinWhenIsVisibleCallback=null,this._resizeObserver=null,this.content=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-balloon-panel",t.to("position",(e=>`ck-balloon-panel_${e}`)),t.if("isVisible","ck-balloon-panel_visible"),t.if("withArrow","ck-balloon-panel_with-arrow"),t.to("class")],style:{top:t.to("top",Tf),left:t.to("left",Tf)}},children:this.content})}destroy(){this.hide(),super.destroy()}show(){this.isVisible=!0}hide(){this.isVisible=!1}attachTo(e){const o=Mf(e.target);if(o&&!ti(o))return!1;this.show();const n=Pf.defaultPositions,i=Object.assign({},{element:this.element,positions:[n.southArrowNorth,n.southArrowNorthMiddleWest,n.southArrowNorthMiddleEast,n.southArrowNorthWest,n.southArrowNorthEast,n.northArrowSouth,n.northArrowSouthMiddleWest,n.northArrowSouthMiddleEast,n.northArrowSouthWest,n.northArrowSouthEast,n.viewportStickyNorth],limiter:t.document.body,fitInViewport:!0},e),r=Pf._getOptimalPosition(i)||If,s=parseInt(r.left),a=parseInt(r.top),l=r.name,c=r.config||{},{withArrow:d=!0}=c;return this.top=a,this.left=s,this.position=l,this.withArrow=d,!0}pin(e){this.unpin(),this._startPinning(e)&&(this._pinWhenIsVisibleCallback=()=>{this.isVisible?this._startPinning(e):this._stopPinning()},this.listenTo(this,"change:isVisible",this._pinWhenIsVisibleCallback))}unpin(){this._pinWhenIsVisibleCallback&&(this._stopPinning(),this.stopListening(this,"change:isVisible",this._pinWhenIsVisibleCallback),this._pinWhenIsVisibleCallback=null,this.hide())}_startPinning(e){if(!this.attachTo(e))return!1;const o=Mf(e.target),n=e.limiter?Mf(e.limiter):t.document.body;if(this.listenTo(t.document,"scroll",((t,i)=>{const r=i.target,s=o&&r.contains(o),a=n&&r.contains(n);!s&&!a&&o&&n||this.attachTo(e)}),{useCapture:!0}),this.listenTo(t.window,"resize",(()=>{this.attachTo(e)})),o&&!this._resizeObserver){const e=()=>{ti(o)||this.unpin()};this._resizeObserver=new Zn(o,e)}return!0}_stopPinning(){this.stopListening(t.document,"scroll"),this.stopListening(t.window,"resize"),this._resizeObserver&&(this._resizeObserver.destroy(),this._resizeObserver=null)}static generatePositions(e={}){const{sideOffset:t=Pf.arrowSideOffset,heightOffset:o=Pf.arrowHeightOffset,stickyVerticalOffset:n=Pf.stickyVerticalOffset,config:i}=e;return{northWestArrowSouthWest:(e,o)=>({top:r(e,o),left:e.left-t,name:"arrow_sw",...i&&{config:i}}),northWestArrowSouthMiddleWest:(e,o)=>({top:r(e,o),left:e.left-.25*o.width-t,name:"arrow_smw",...i&&{config:i}}),northWestArrowSouth:(e,t)=>({top:r(e,t),left:e.left-t.width/2,name:"arrow_s",...i&&{config:i}}),northWestArrowSouthMiddleEast:(e,o)=>({top:r(e,o),left:e.left-.75*o.width+t,name:"arrow_sme",...i&&{config:i}}),northWestArrowSouthEast:(e,o)=>({top:r(e,o),left:e.left-o.width+t,name:"arrow_se",...i&&{config:i}}),northArrowSouthWest:(e,o)=>({top:r(e,o),left:e.left+e.width/2-t,name:"arrow_sw",...i&&{config:i}}),northArrowSouthMiddleWest:(e,o)=>({top:r(e,o),left:e.left+e.width/2-.25*o.width-t,name:"arrow_smw",...i&&{config:i}}),northArrowSouth:(e,t)=>({top:r(e,t),left:e.left+e.width/2-t.width/2,name:"arrow_s",...i&&{config:i}}),northArrowSouthMiddleEast:(e,o)=>({top:r(e,o),left:e.left+e.width/2-.75*o.width+t,name:"arrow_sme",...i&&{config:i}}),northArrowSouthEast:(e,o)=>({top:r(e,o),left:e.left+e.width/2-o.width+t,name:"arrow_se",...i&&{config:i}}),northEastArrowSouthWest:(e,o)=>({top:r(e,o),left:e.right-t,name:"arrow_sw",...i&&{config:i}}),northEastArrowSouthMiddleWest:(e,o)=>({top:r(e,o),left:e.right-.25*o.width-t,name:"arrow_smw",...i&&{config:i}}),northEastArrowSouth:(e,t)=>({top:r(e,t),left:e.right-t.width/2,name:"arrow_s",...i&&{config:i}}),northEastArrowSouthMiddleEast:(e,o)=>({top:r(e,o),left:e.right-.75*o.width+t,name:"arrow_sme",...i&&{config:i}}),northEastArrowSouthEast:(e,o)=>({top:r(e,o),left:e.right-o.width+t,name:"arrow_se",...i&&{config:i}}),southWestArrowNorthWest:e=>({top:s(e),left:e.left-t,name:"arrow_nw",...i&&{config:i}}),southWestArrowNorthMiddleWest:(e,o)=>({top:s(e),left:e.left-.25*o.width-t,name:"arrow_nmw",...i&&{config:i}}),southWestArrowNorth:(e,t)=>({top:s(e),left:e.left-t.width/2,name:"arrow_n",...i&&{config:i}}),southWestArrowNorthMiddleEast:(e,o)=>({top:s(e),left:e.left-.75*o.width+t,name:"arrow_nme",...i&&{config:i}}),southWestArrowNorthEast:(e,o)=>({top:s(e),left:e.left-o.width+t,name:"arrow_ne",...i&&{config:i}}),southArrowNorthWest:e=>({top:s(e),left:e.left+e.width/2-t,name:"arrow_nw",...i&&{config:i}}),southArrowNorthMiddleWest:(e,o)=>({top:s(e),left:e.left+e.width/2-.25*o.width-t,name:"arrow_nmw",...i&&{config:i}}),southArrowNorth:(e,t)=>({top:s(e),left:e.left+e.width/2-t.width/2,name:"arrow_n",...i&&{config:i}}),southArrowNorthMiddleEast:(e,o)=>({top:s(e),left:e.left+e.width/2-.75*o.width+t,name:"arrow_nme",...i&&{config:i}}),southArrowNorthEast:(e,o)=>({top:s(e),left:e.left+e.width/2-o.width+t,name:"arrow_ne",...i&&{config:i}}),southEastArrowNorthWest:e=>({top:s(e),left:e.right-t,name:"arrow_nw",...i&&{config:i}}),southEastArrowNorthMiddleWest:(e,o)=>({top:s(e),left:e.right-.25*o.width-t,name:"arrow_nmw",...i&&{config:i}}),southEastArrowNorth:(e,t)=>({top:s(e),left:e.right-t.width/2,name:"arrow_n",...i&&{config:i}}),southEastArrowNorthMiddleEast:(e,o)=>({top:s(e),left:e.right-.75*o.width+t,name:"arrow_nme",...i&&{config:i}}),southEastArrowNorthEast:(e,o)=>({top:s(e),left:e.right-o.width+t,name:"arrow_ne",...i&&{config:i}}),westArrowEast:(e,t)=>({top:e.top+e.height/2-t.height/2,left:e.left-t.width-o,name:"arrow_e",...i&&{config:i}}),eastArrowWest:(e,t)=>({top:e.top+e.height/2-t.height/2,left:e.right+o,name:"arrow_w",...i&&{config:i}}),viewportStickyNorth:(e,t,o,r)=>{const s=r||o;return e.getIntersection(s)?s.height-e.height>n?null:{top:s.top+n,left:e.left+e.width/2-t.width/2,name:"arrowless",config:{withArrow:!1,...i}}:null}};function r(e,t){return e.top-t.height-o}function s(e){return e.bottom+o}}}Pf.arrowSideOffset=25,Pf.arrowHeightOffset=10,Pf.stickyVerticalOffset=20,Pf._getOptimalPosition=oi,Pf.defaultPositions=Pf.generatePositions();const Ff=Pf;function Mf(e){return Bn(e)?e:Ln(e)?e.commonAncestorContainer:"function"==typeof e?Mf(e()):null}var Rf=i(4650),zf={attributes:{"data-cke":!0}};zf.setAttributes=Ar(),zf.insert=_r().bind(null,"head"),zf.domAPI=kr(),zf.insertStyleElement=vr();fr()(Rf.A,zf);Rf.A&&Rf.A.locals&&Rf.A.locals;const Vf="ck-tooltip";class Of extends(Rn()){constructor(e){if(super(),this._currentElementWithTooltip=null,this._currentTooltipPosition=null,this._mutationObserver=null,Of._editors.add(e),Of._instance)return Of._instance;Of._instance=this,this.tooltipTextView=new pm(e.locale),this.tooltipTextView.set("text",""),this.tooltipTextView.setTemplate({tag:"span",attributes:{class:["ck","ck-tooltip__text"]},children:[{text:this.tooltipTextView.bindTemplate.to("text")}]}),this.balloonPanelView=new Ff(e.locale),this.balloonPanelView.class=Vf,this.balloonPanelView.content.add(this.tooltipTextView),this._mutationObserver=function(e){const t=new MutationObserver((()=>{e()}));return{attach(e){t.observe(e,{attributes:!0,attributeFilter:["data-cke-tooltip-text","data-cke-tooltip-position"]})},detach(){t.disconnect()}}}((()=>{this._updateTooltipPosition()})),this._pinTooltipDebounced=el(this._pinTooltip,600),this._unpinTooltipDebounced=el(this._unpinTooltip,400),this.listenTo(t.document,"keydown",this._onKeyDown.bind(this),{useCapture:!0}),this.listenTo(t.document,"mouseenter",this._onEnterOrFocus.bind(this),{useCapture:!0}),this.listenTo(t.document,"mouseleave",this._onLeaveOrBlur.bind(this),{useCapture:!0}),this.listenTo(t.document,"focus",this._onEnterOrFocus.bind(this),{useCapture:!0}),this.listenTo(t.document,"blur",this._onLeaveOrBlur.bind(this),{useCapture:!0}),this.listenTo(t.document,"scroll",this._onScroll.bind(this),{useCapture:!0}),this._watchdogExcluded=!0}destroy(e){const t=e.ui.view&&e.ui.view.body;Of._editors.delete(e),this.stopListening(e.ui),t&&t.has(this.balloonPanelView)&&t.remove(this.balloonPanelView),Of._editors.size||(this._unpinTooltip(),this.balloonPanelView.destroy(),this.stopListening(),Of._instance=null)}static getPositioningFunctions(e){const t=Of.defaultBalloonPositions;return{s:[t.southArrowNorth,t.southArrowNorthEast,t.southArrowNorthWest],n:[t.northArrowSouth],e:[t.eastArrowWest],w:[t.westArrowEast],sw:[t.southArrowNorthEast],se:[t.southArrowNorthWest]}[e]}_onKeyDown(e,t){"Escape"===t.key&&this._currentElementWithTooltip&&(this._unpinTooltip(),t.stopPropagation())}_onEnterOrFocus(e,{target:t}){const o=Lf(t);o?o!==this._currentElementWithTooltip&&(this._unpinTooltip(),"focus"!==e.name||o.matches(":hover")?this._pinTooltipDebounced(o,Hf(o)):this._pinTooltip(o,Hf(o))):"focus"===e.name&&this._unpinTooltip()}_onLeaveOrBlur(e,{target:t,relatedTarget:o}){if("mouseleave"===e.name){if(!Bn(t))return;const e=this.balloonPanelView.element,n=e&&(e===o||e.contains(o)),i=!n&&t===e;if(n)return void this._unpinTooltipDebounced.cancel();if(!i&&this._currentElementWithTooltip&&t!==this._currentElementWithTooltip)return;const r=Lf(t),s=Lf(o);(i||r&&r!==s)&&this._unpinTooltipDebounced()}else{if(this._currentElementWithTooltip&&t!==this._currentElementWithTooltip)return;this._unpinTooltipDebounced()}}_onScroll(e,{target:t}){this._currentElementWithTooltip&&(t.contains(this.balloonPanelView.element)&&t.contains(this._currentElementWithTooltip)||this._unpinTooltip())}_pinTooltip(e,{text:t,position:o,cssClass:n}){this._unpinTooltip();const i=Qi(Of._editors.values()).ui.view.body;i.has(this.balloonPanelView)||i.add(this.balloonPanelView),this.tooltipTextView.text=t,this.balloonPanelView.class=[Vf,n].filter((e=>e)).join(" "),this.balloonPanelView.pin({target:e,positions:Of.getPositioningFunctions(o)}),this._mutationObserver.attach(e);for(const e of Of._editors)this.listenTo(e.ui,"update",this._updateTooltipPosition.bind(this),{priority:"low"});this._currentElementWithTooltip=e,this._currentTooltipPosition=o}_unpinTooltip(){this._unpinTooltipDebounced.cancel(),this._pinTooltipDebounced.cancel(),this.balloonPanelView.unpin();for(const e of Of._editors)this.stopListening(e.ui,"update");this._currentElementWithTooltip=null,this._currentTooltipPosition=null,this.tooltipTextView.text="",this._mutationObserver.detach()}_updateTooltipPosition(){if(!this._currentElementWithTooltip)return;const e=Hf(this._currentElementWithTooltip);ti(this._currentElementWithTooltip)&&e.text?this.balloonPanelView.pin({target:this._currentElementWithTooltip,positions:Of.getPositioningFunctions(e.position)}):this._unpinTooltip()}}Of.defaultBalloonPositions=Ff.generatePositions({heightOffset:5,sideOffset:13}),Of._editors=new Set,Of._instance=null;const Nf=Of;function Lf(e){return Bn(e)?e.closest("[data-cke-tooltip-text]:not([data-cke-tooltip-disabled])"):null}function Hf(e){return{text:e.dataset.ckeTooltipText,position:e.dataset.ckeTooltipPosition||"s",cssClass:e.dataset.ckeTooltipClass||""}}const jf=50,qf=350,Uf="Powered by";class Wf extends(Rn()){constructor(e){super(),this.editor=e,this._balloonView=null,this._lastFocusedEditableElement=null,this._showBalloonThrottled=Bh(this._showBalloon.bind(this),50,{leading:!0}),e.on("ready",this._handleEditorReady.bind(this))}destroy(){const e=this._balloonView;e&&(e.unpin(),this._balloonView=null),this._showBalloonThrottled.cancel(),this.stopListening()}_handleEditorReady(){const e=this.editor;(!!e.config.get("ui.poweredBy.forceVisible")||"VALID"!==function(e){function t(e){return e.length>=40&&e.length<=255?"VALID":"INVALID"}if(!e)return"INVALID";let o="";try{o=atob(e)}catch(e){return"INVALID"}const n=o.split("-"),i=n[0],r=n[1];if(!r)return t(e);try{atob(r)}catch(o){try{if(atob(i),!atob(i).length)return t(e)}catch(o){return t(e)}}if(i.length<40||i.length>255)return"INVALID";let s="";try{atob(i),s=atob(r)}catch(e){return"INVALID"}if(8!==s.length)return"INVALID";const a=Number(s.substring(0,4)),l=Number(s.substring(4,6))-1,c=Number(s.substring(6,8)),d=new Date(a,l,c);return d{this._updateLastFocusedEditableElement(),o?this._showBalloon():this._hideBalloon()})),e.ui.focusTracker.on("change:focusedElement",((e,t,o)=>{this._updateLastFocusedEditableElement(),o&&this._showBalloon()})),e.ui.on("update",(()=>{this._showBalloonThrottled()})))}_createBalloonView(){const e=this.editor,t=this._balloonView=new Ff,o=Kf(e),n=new $f(e.locale,o.label);t.content.add(n),t.set({class:"ck-powered-by-balloon"}),e.ui.view.body.add(t),e.ui.focusTracker.add(t.element),this._balloonView=t}_showBalloon(){if(!this._lastFocusedEditableElement)return;const e=function(e,t){const o=Kf(e),n="right"===o.side?function(e,t){return Gf(e,t,((e,o)=>e.left+e.width-o.width-t.horizontalOffset))}(t,o):function(e,t){return Gf(e,t,(e=>e.left+t.horizontalOffset))}(t,o);return{target:t,positions:[n]}}(this.editor,this._lastFocusedEditableElement);e&&(this._balloonView||this._createBalloonView(),this._balloonView.pin(e))}_hideBalloon(){this._balloonView&&this._balloonView.unpin()}_updateLastFocusedEditableElement(){const e=this.editor,t=e.ui.focusTracker.isFocused,o=e.ui.focusTracker.focusedElement;if(!t||!o)return void(this._lastFocusedEditableElement=null);const n=Array.from(e.ui.getEditableElementsNames()).map((t=>e.ui.getEditableElement(t)));n.includes(o)?this._lastFocusedEditableElement=o:this._lastFocusedEditableElement=n[0]}}class $f extends pm{constructor(e,t){super(e);const o=new Am,n=this.bindTemplate;o.set({content:'\n',isColorInherited:!1}),o.extendTemplate({attributes:{style:{width:"53px",height:"10px"}}}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-powered-by"],"aria-hidden":!0},children:[{tag:"a",attributes:{href:"https://ckeditor.com/?utm_source=ckeditor&utm_medium=referral&utm_campaign=701Dn000000hVgmIAE_powered_by_ckeditor_logo",target:"_blank",tabindex:"-1"},children:[...t?[{tag:"span",attributes:{class:["ck","ck-powered-by__label"]},children:[t]}]:[],o],on:{dragstart:n.to((e=>e.preventDefault()))}}]})}}function Gf(e,t,o){return(n,i)=>{const r=new qn(e);if(r.width{for(const e of Object.values(Yf))this.announce("",e)}))}announce(e,t=Yf.POLITE){const o=this.editor;if(!o.ui.view)return;this.view||(this.view=new Xf(o.locale),o.ui.view.body.add(this.view));const{politeness:n,isUnsafeHTML:i}="string"==typeof t?{politeness:t}:t;let r=this.view.regionViews.find((e=>e.politeness===n));r||(r=new eb(o,n),this.view.regionViews.add(r)),r.announce({announcement:e,isUnsafeHTML:i})}}class Xf extends pm{constructor(e){super(e),this.regionViews=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-aria-live-announcer"]},children:this.regionViews})}}class eb extends pm{constructor(e,t){super(e.locale),this.setTemplate({tag:"div",attributes:{"aria-live":t,"aria-relevant":"additions"},children:[{tag:"ul",attributes:{class:["ck","ck-aria-live-region-list"]}}]}),e.on("destroy",(()=>{null!==this._pruneAnnouncementsInterval&&(clearInterval(this._pruneAnnouncementsInterval),this._pruneAnnouncementsInterval=null)})),this.politeness=t,this._domConverter=e.data.htmlProcessor.domConverter,this._pruneAnnouncementsInterval=setInterval((()=>{this.element&&this._listElement.firstChild&&this._listElement.firstChild.remove()}),5e3)}announce({announcement:e,isUnsafeHTML:t}){if(!e.trim().length)return;const o=document.createElement("li");t?this._domConverter.setContentOf(o,e):o.innerText=e,this._listElement.appendChild(o)}get _listElement(){return this.element.querySelector("ul")}}var tb=i(1214),ob={attributes:{"data-cke":!0}};ob.setAttributes=Ar(),ob.insert=_r().bind(null,"head"),ob.domAPI=kr(),ob.insertStyleElement=vr();fr()(tb.A,ob);tb.A&&tb.A.locals&&tb.A.locals;class nb extends mg{constructor(e,t){super(e);const o=this.bindTemplate;this.extendTemplate({attributes:{class:["ck-menu-bar__menu__item"]},on:{mouseenter:o.to("mouseenter")}}),this.delegate("mouseenter").to(t)}}const ib={toggleMenusAndFocusItemsOnHover(e){e.on("menu:mouseenter",(t=>{if(e.isFocusBorderEnabled||e.isOpen){if(e.isOpen)for(const o of e.menus){const e=t.path[0],n=e instanceof nb&&e.children.first===o;o.isOpen=(t.path.includes(o)||n)&&o.isEnabled}t.source.focus()}}))},focusCycleMenusOnArrows(e){const t="rtl"===e.locale.uiLanguageDirection;function o(t,o){const n=e.children.getIndex(t),i=t.isOpen,r=e.children.length,s=e.children.get((n+r+o)%r);t.isOpen=!1,i&&(s.isOpen=!0),s.buttonView.focus()}e.on("menu:arrowright",(e=>{o(e.source,t?-1:1)})),e.on("menu:arrowleft",(e=>{o(e.source,t?1:-1)}))},closeMenusWhenTheBarCloses(e){e.on("change:isOpen",(()=>{e.isOpen||e.menus.forEach((e=>{e.isOpen=!1}))}))},closeMenuWhenAnotherOnTheSameLevelOpens(e){e.on("menu:change:isOpen",((t,o,n)=>{n&&e.menus.filter((e=>t.source.parentMenuView===e.parentMenuView&&t.source!==e&&e.isOpen)).forEach((e=>{e.isOpen=!1}))}))},closeOnClickOutside(e){gm({emitter:e,activator:()=>e.isOpen,callback:()=>e.close(),contextElements:()=>e.children.map((e=>e.element))})},enableFocusHighlightOnInteraction(e){let t=!1;e.on("change:isOpen",((o,n,i)=>{i||(e.isFocusBorderEnabled=!1,t=!1)})),e.listenTo(e.element,"click",(()=>{e.isOpen&&e.element.matches(":focus-within")&&(e.isFocusBorderEnabled=!0)}),{useCapture:!0}),e.listenTo(e.element,"keydown",(()=>{t=!0}),{useCapture:!0}),e.listenTo(e.element,"keyup",(()=>{t=!1}),{useCapture:!0}),e.listenTo(e.element,"focus",(()=>{t&&(e.isFocusBorderEnabled=!0)}),{useCapture:!0})}},rb={openAndFocusPanelOnArrowDownKey(e){e.keystrokes.set("arrowdown",((t,o)=>{e.focusTracker.focusedElement===e.buttonView.element&&(e.isOpen||(e.isOpen=!0),e.panelView.focus(),o())}))},openOnArrowRightKey(e){const t="rtl"===e.locale.uiLanguageDirection?"arrowleft":"arrowright";e.keystrokes.set(t,((t,o)=>{e.focusTracker.focusedElement===e.buttonView.element&&e.isEnabled&&(e.isOpen||(e.isOpen=!0),e.panelView.focus(),o())}))},openOnButtonClick(e){e.buttonView.on("execute",(()=>{e.isOpen=!0,e.parentMenuView&&e.panelView.focus()}))},toggleOnButtonClick(e){e.buttonView.on("execute",(()=>{e.isOpen=!e.isOpen}))},closeOnArrowLeftKey(e){const t="rtl"===e.locale.uiLanguageDirection?"arrowright":"arrowleft";e.keystrokes.set(t,((t,o)=>{e.isOpen&&(e.isOpen=!1,e.focus(),o())}))},closeOnEscKey(e){e.keystrokes.set("esc",((t,o)=>{e.isOpen&&(e.isOpen=!1,e.focus(),o())}))},closeOnParentClose(e){e.parentMenuView.on("change:isOpen",((t,o,n)=>{n||t.source!==e.parentMenuView||(e.isOpen=!1)}))}},sb={southEast:e=>({top:e.bottom,left:e.left,name:"se"}),southWest:(e,t)=>({top:e.bottom,left:e.left-t.width+e.width,name:"sw"}),northEast:(e,t)=>({top:e.top-t.height,left:e.left,name:"ne"}),northWest:(e,t)=>({top:e.top-t.height,left:e.left-t.width+e.width,name:"nw"}),eastSouth:e=>({top:e.top,left:e.right-5,name:"es"}),eastNorth:(e,t)=>({top:e.top-t.height,left:e.right-5,name:"en"}),westSouth:(e,t)=>({top:e.top,left:e.left-t.width+5,name:"ws"}),westNorth:(e,t)=>({top:e.top-t.height,left:e.left-t.width+5,name:"wn"})},ab=[{menuId:"file",label:"File",groups:[{groupId:"export",items:["menuBar:exportPdf","menuBar:exportWord"]},{groupId:"import",items:["menuBar:importWord"]},{groupId:"revisionHistory",items:["menuBar:revisionHistory"]}]},{menuId:"edit",label:"Edit",groups:[{groupId:"undo",items:["menuBar:undo","menuBar:redo"]},{groupId:"selectAll",items:["menuBar:selectAll"]},{groupId:"findAndReplace",items:["menuBar:findAndReplace"]}]},{menuId:"view",label:"View",groups:[{groupId:"sourceEditing",items:["menuBar:sourceEditing"]},{groupId:"showBlocks",items:["menuBar:showBlocks"]},{groupId:"previewMergeFields",items:["menuBar:previewMergeFields"]},{groupId:"restrictedEditing",items:["menuBar:restrictedEditing"]}]},{menuId:"insert",label:"Insert",groups:[{groupId:"insertMainWidgets",items:["menuBar:insertImage","menuBar:ckbox","menuBar:ckfinder","menuBar:insertTable"]},{groupId:"insertInline",items:["menuBar:link","menuBar:comment","menuBar:insertMergeField"]},{groupId:"insertMinorWidgets",items:["menuBar:mediaEmbed","menuBar:insertTemplate","menuBar:specialCharacters","menuBar:blockQuote","menuBar:codeBlock","menuBar:htmlEmbed"]},{groupId:"insertStructureWidgets",items:["menuBar:horizontalLine","menuBar:pageBreak","menuBar:tableOfContents"]},{groupId:"restrictedEditingException",items:["menuBar:restrictedEditingException"]}]},{menuId:"format",label:"Format",groups:[{groupId:"textAndFont",items:[{menuId:"text",label:"Text",groups:[{groupId:"basicStyles",items:["menuBar:bold","menuBar:italic","menuBar:underline","menuBar:strikethrough","menuBar:superscript","menuBar:subscript","menuBar:code"]},{groupId:"textPartLanguage",items:["menuBar:textPartLanguage"]}]},{menuId:"font",label:"Font",groups:[{groupId:"fontProperties",items:["menuBar:fontSize","menuBar:fontFamily"]},{groupId:"fontColors",items:["menuBar:fontColor","menuBar:fontBackgroundColor"]},{groupId:"highlight",items:["menuBar:highlight"]}]},"menuBar:heading"]},{groupId:"list",items:["menuBar:bulletedList","menuBar:numberedList","menuBar:multiLevelList","menuBar:todoList"]},{groupId:"indent",items:["menuBar:alignment","menuBar:indent","menuBar:outdent"]},{groupId:"caseChange",items:["menuBar:caseChange"]},{groupId:"removeFormat",items:["menuBar:removeFormat"]}]},{menuId:"tools",label:"Tools",groups:[{groupId:"aiTools",items:["menuBar:aiAssistant","menuBar:aiCommands"]},{groupId:"tools",items:["menuBar:trackChanges","menuBar:commentsArchive"]}]},{menuId:"help",label:"Help",groups:[{groupId:"help",items:["menuBar:accessibilityHelp"]}]}];function lb({normalizedConfig:e,locale:t,componentFactory:o,extraItems:n}){const i=Fl(e);return cb(e,i,n),function(e,t){const o=t.removeItems,n=[];t.items=t.items.filter((({menuId:e})=>!o.includes(e)||(n.push(e),!1))),mb(t.items,(e=>{e.groups=e.groups.filter((({groupId:e})=>!o.includes(e)||(n.push(e),!1)));for(const t of e.groups)t.items=t.items.filter((e=>{const t=bb(e);return!o.includes(t)||(n.push(t),!1)}))}));for(const t of o)n.includes(t)||D("menu-bar-item-could-not-be-removed",{menuBarConfig:e,itemName:t})}(e,i),cb(e,i,i.addItems),function(e,t,o){mb(t.items,(n=>{for(const i of n.groups)i.items=i.items.filter((i=>{const r="string"==typeof i&&!o.has(i);return r&&!t.isUsingDefaultConfig&&D("menu-bar-item-unavailable",{menuBarConfig:e,parentMenuConfig:Fl(n),componentName:i}),!r}))}))}(e,i,o),ub(e,i),function(e,t){const o=t.t,n={File:o({string:"File",id:"MENU_BAR_MENU_FILE"}),Edit:o({string:"Edit",id:"MENU_BAR_MENU_EDIT"}),View:o({string:"View",id:"MENU_BAR_MENU_VIEW"}),Insert:o({string:"Insert",id:"MENU_BAR_MENU_INSERT"}),Format:o({string:"Format",id:"MENU_BAR_MENU_FORMAT"}),Tools:o({string:"Tools",id:"MENU_BAR_MENU_TOOLS"}),Help:o({string:"Help",id:"MENU_BAR_MENU_HELP"}),Text:o({string:"Text",id:"MENU_BAR_MENU_TEXT"}),Font:o({string:"Font",id:"MENU_BAR_MENU_FONT"})};mb(e.items,(e=>{e.label in n&&(e.label=n[e.label])}))}(i,t),i}function cb(e,t,o){const n=[];if(0!=o.length){for(const e of o){const o=gb(e.position),r=fb(e.position);if("object"==typeof(i=e)&&"menu"in i)if(r){const i=t.items.findIndex((e=>e.menuId===r));if(-1!=i)"before"===o?(t.items.splice(i,0,e.menu),n.push(e)):"after"===o&&(t.items.splice(i+1,0,e.menu),n.push(e));else{db(t,e.menu,r,o)&&n.push(e)}}else"start"===o?(t.items.unshift(e.menu),n.push(e)):"end"===o&&(t.items.push(e.menu),n.push(e));else if(pb(e))mb(t.items,(t=>{if(t.menuId===r)"start"===o?(t.groups.unshift(e.group),n.push(e)):"end"===o&&(t.groups.push(e.group),n.push(e));else{const i=t.groups.findIndex((e=>e.groupId===r));-1!==i&&("before"===o?(t.groups.splice(i,0,e.group),n.push(e)):"after"===o&&(t.groups.splice(i+1,0,e.group),n.push(e)))}}));else{db(t,e.item,r,o)&&n.push(e)}}var i;for(const t of o)n.includes(t)||D("menu-bar-item-could-not-be-added",{menuBarConfig:e,addedItemConfig:t})}}function db(e,t,o,n){let i=!1;return mb(e.items,(e=>{for(const{groupId:r,items:s}of e.groups){if(i)return;if(r===o)"start"===n?(s.unshift(t),i=!0):"end"===n&&(s.push(t),i=!0);else{const e=s.findIndex((e=>bb(e)===o));-1!==e&&("before"===n?(s.splice(e,0,t),i=!0):"after"===n&&(s.splice(e+1,0,t),i=!0))}}})),i}function ub(e,t){const o=t.isUsingDefaultConfig;let n=!1;t.items=t.items.filter((t=>!!t.groups.length||(hb(e,t,o),!1))),t.items.length?(mb(t.items,(t=>{t.groups=t.groups.filter((e=>!!e.items.length||(n=!0,!1)));for(const i of t.groups)i.items=i.items.filter((t=>!(kb(t)&&!t.groups.length)||(hb(e,t,o),n=!0,!1)))})),n&&ub(e,t)):hb(e,e,o)}function hb(e,t,o){o||D("menu-bar-menu-empty",{menuBarConfig:e,emptyMenuConfig:t})}function mb(e,t){if(Array.isArray(e))for(const t of e)o(t);function o(e){t(e);for(const t of e.groups)for(const e of t.items)kb(e)&&o(e)}}function pb(e){return"object"==typeof e&&"group"in e}function gb(e){return e.startsWith("start")?"start":e.startsWith("end")?"end":e.startsWith("after")?"after":"before"}function fb(e){const t=e.match(/^[^:]+:(.+)/);return t?t[1]:null}function bb(e){return"string"==typeof e?e:e.menuId}function kb(e){return"object"==typeof e&&"menuId"in e}class wb extends(Y()){constructor(e){super(),this.isReady=!1,this._editableElementsMap=new Map,this._focusableToolbarDefinitions=[],this._extraMenuBarElements=[],this._lastFocusedForeignElement=null;const t=e.editing.view;this.editor=e,this.componentFactory=new Ef(e),this.focusTracker=new Xi,this.tooltipManager=new Nf(e),this.poweredBy=new Wf(e),this.ariaLiveAnnouncer=new Qf(e),this.set("viewportOffset",this._readViewportOffsetFromConfig()),this.once("ready",(()=>{this.isReady=!0})),this.listenTo(t.document,"layoutChanged",this.update.bind(this)),this.listenTo(t,"scrollToTheSelection",this._handleScrollToTheSelection.bind(this)),this._initFocusTracking()}get element(){return null}update(){this.fire("update")}destroy(){this.stopListening(),this.focusTracker.destroy(),this.tooltipManager.destroy(this.editor),this.poweredBy.destroy();for(const e of this._editableElementsMap.values())e.ckeditorInstance=null,this.editor.keystrokes.stopListening(e);this._editableElementsMap=new Map,this._focusableToolbarDefinitions=[]}setEditableElement(e,t){this._editableElementsMap.set(e,t),t.ckeditorInstance||(t.ckeditorInstance=this.editor),this.focusTracker.add(t);const o=()=>{this.editor.editing.view.getDomRoot(e)||this.editor.keystrokes.listenTo(t)};this.isReady?o():this.once("ready",o)}removeEditableElement(e){const t=this._editableElementsMap.get(e);t&&(this._editableElementsMap.delete(e),this.editor.keystrokes.stopListening(t),this.focusTracker.remove(t),t.ckeditorInstance=null)}getEditableElement(e="main"){return this._editableElementsMap.get(e)}getEditableElementsNames(){return this._editableElementsMap.keys()}addToolbar(e,t={}){e.isRendered?(this.focusTracker.add(e.element),this.editor.keystrokes.listenTo(e.element)):e.once("render",(()=>{this.focusTracker.add(e.element),this.editor.keystrokes.listenTo(e.element)})),this._focusableToolbarDefinitions.push({toolbarView:e,options:t})}extendMenuBar(e){this._extraMenuBarElements.push(e)}get _editableElements(){return console.warn("editor-ui-deprecated-editable-elements: The EditorUI#_editableElements property has been deprecated and will be removed in the near future.",{editorUI:this}),this._editableElementsMap}_initMenuBar(e){const t=e.element;this.focusTracker.add(t),this.editor.keystrokes.listenTo(t);const o=function(e){let t;return t="items"in e&&e.items?{items:e.items,removeItems:[],addItems:[],isVisible:!0,isUsingDefaultConfig:!1,...e}:{items:Fl(ab),addItems:[],removeItems:[],isVisible:!0,isUsingDefaultConfig:!0,...e},t}(this.editor.config.get("menuBar")||{});e.fillFromConfig(o,this.componentFactory,this._extraMenuBarElements),this.editor.keystrokes.set("Esc",((e,o)=>{t.contains(this.editor.ui.focusTracker.focusedElement)&&(this._lastFocusedForeignElement?(this._lastFocusedForeignElement.focus(),this._lastFocusedForeignElement=null):this.editor.editing.view.focus(),o())})),this.editor.keystrokes.set("Alt+F9",((o,n)=>{t.contains(this.editor.ui.focusTracker.focusedElement)||(this._saveLastFocusedForeignElement(),e.isFocusBorderEnabled=!0,e.focus(),n())}))}_readViewportOffsetFromConfig(){const e=this.editor,t=e.config.get("ui.viewportOffset");if(t)return t;const o=e.config.get("toolbar.viewportTopOffset");return o?(console.warn("editor-ui-deprecated-viewport-offset-config: The `toolbar.vieportTopOffset` configuration option is deprecated. It will be removed from future CKEditor versions. Use `ui.viewportOffset.top` instead."),{top:o}):{top:0}}_initFocusTracking(){const e=this.editor;e.editing.view;let t;e.keystrokes.set("Alt+F10",((e,o)=>{this._saveLastFocusedForeignElement();const n=this._getCurrentFocusedToolbarDefinition();n&&t||(t=this._getFocusableCandidateToolbarDefinitions());for(let e=0;e{const n=this._getCurrentFocusedToolbarDefinition();n&&(this._lastFocusedForeignElement?(this._lastFocusedForeignElement.focus(),this._lastFocusedForeignElement=null):e.editing.view.focus(),n.options.afterBlur&&n.options.afterBlur(),o())}))}_saveLastFocusedForeignElement(){const e=this.focusTracker.focusedElement;Array.from(this._editableElementsMap.values()).includes(e)&&!Array.from(this.editor.editing.view.domRoots.values()).includes(e)&&(this._lastFocusedForeignElement=e)}_getFocusableCandidateToolbarDefinitions(){const e=[];for(const t of this._focusableToolbarDefinitions){const{toolbarView:o,options:n}=t;(ti(o.element)||n.beforeFocus)&&e.push(t)}return e.sort(((e,t)=>_b(e)-_b(t))),e}_getCurrentFocusedToolbarDefinition(){for(const e of this._focusableToolbarDefinitions)if(e.toolbarView.element&&e.toolbarView.element.contains(this.focusTracker.focusedElement))return e;return null}_focusFocusableCandidateToolbar(e){const{toolbarView:t,options:{beforeFocus:o}}=e;return o&&o(),!!ti(t.element)&&(t.focus(),!0)}_handleScrollToTheSelection(e,t){const o={top:0,bottom:0,left:0,right:0,...this.viewportOffset};t.viewportOffset.top+=o.top,t.viewportOffset.bottom+=o.bottom,t.viewportOffset.left+=o.left,t.viewportOffset.right+=o.right}}function _b(e){const{toolbarView:t,options:o}=e;let n=10;return ti(t.element)&&n--,o.isContextual&&n--,n}var yb=i(178),Ab={attributes:{"data-cke":!0}};Ab.setAttributes=Ar(),Ab.insert=_r().bind(null,"head"),Ab.domAPI=kr(),Ab.insertStyleElement=vr();fr()(yb.A,Ab);yb.A&&yb.A.locals&&yb.A.locals;class Cb extends pm{constructor(e){super(e),this.body=new pp(e)}render(){super.render(),this.body.attachToDom()}destroy(){return this.body.detachFromDom(),super.destroy()}}class vb extends pm{constructor(e,t,o){super(e),this.name=null,this.setTemplate({tag:"div",attributes:{class:["ck","ck-content","ck-editor__editable","ck-rounded-corners"],lang:e.contentLanguage,dir:e.contentLanguageDirection}}),this.set("isFocused",!1),this._editableElement=o,this._hasExternalElement=!!this._editableElement,this._editingView=t}render(){super.render(),this._hasExternalElement?this.template.apply(this.element=this._editableElement):this._editableElement=this.element,this.on("change:isFocused",(()=>this._updateIsFocusedClasses())),this._updateIsFocusedClasses()}destroy(){this._hasExternalElement&&this.template.revert(this._editableElement),super.destroy()}get hasExternalElement(){return this._hasExternalElement}_updateIsFocusedClasses(){const e=this._editingView;function t(t){e.change((o=>{const n=e.document.getRoot(t.name);o.addClass(t.isFocused?"ck-focused":"ck-blurred",n),o.removeClass(t.isFocused?"ck-blurred":"ck-focused",n)}))}e.isRenderingInProgress?function o(n){e.once("change:isRenderingInProgress",((e,i,r)=>{r?o(n):t(n)}))}(this):t(this)}}class xb extends vb{constructor(e,t,o,n={}){super(e,t,o);const i=e.t;this.extendTemplate({attributes:{role:"textbox",class:"ck-editor__editable_inline"}}),this._generateLabel=n.label||(()=>i("Editor editing area: %0",this.name))}render(){super.render();const e=this._editingView;e.change((t=>{const o=e.document.getRoot(this.name);t.setAttribute("aria-label",this._generateLabel(this),o)}))}}class Eb extends pr{static get pluginName(){return"Notification"}init(){this.on("show:warning",((e,t)=>{window.alert(t.message)}),{priority:"lowest"})}showSuccess(e,t={}){this._showNotification({message:e,type:"success",namespace:t.namespace,title:t.title})}showInfo(e,t={}){this._showNotification({message:e,type:"info",namespace:t.namespace,title:t.title})}showWarning(e,t={}){this._showNotification({message:e,type:"warning",namespace:t.namespace,title:t.title})}_showNotification(e){const t=e.namespace?`show:${e.type}:${e.namespace}`:`show:${e.type}`;this.fire(t,{message:e.message,type:e.type,title:e.title||""})}}class Db extends(Y()){constructor(e,t){super(),t&&Oa(this,t),e&&this.set(e)}}var Bb=i(9938),Sb={attributes:{"data-cke":!0}};Sb.setAttributes=Ar(),Sb.insert=_r().bind(null,"head"),Sb.domAPI=kr(),Sb.insertStyleElement=vr();fr()(Bb.A,Sb);Bb.A&&Bb.A.locals&&Bb.A.locals;var Tb=i(3579),Ib={attributes:{"data-cke":!0}};Ib.setAttributes=Ar(),Ib.insert=_r().bind(null,"head"),Ib.domAPI=kr(),Ib.insertStyleElement=vr();fr()(Tb.A,Ib);Tb.A&&Tb.A.locals&&Tb.A.locals;const Pb=Yn("px");class Fb extends lr{static get pluginName(){return"ContextualBalloon"}constructor(e){super(e),this._viewToStack=new Map,this._idToStack=new Map,this._view=null,this._rotatorView=null,this._fakePanelsView=null,this.positionLimiter=()=>{const e=this.editor.editing.view,t=e.document.selection.editableElement;return t?e.domConverter.mapViewToDom(t.root):null},this.set("visibleView",null),this.set("_numberOfStacks",0),this.set("_singleViewMode",!1)}destroy(){super.destroy(),this._view&&this._view.destroy(),this._rotatorView&&this._rotatorView.destroy(),this._fakePanelsView&&this._fakePanelsView.destroy()}get view(){return this._view||this._createPanelView(),this._view}hasView(e){return Array.from(this._viewToStack.keys()).includes(e)}add(e){if(this._view||this._createPanelView(),this.hasView(e.view))throw new E("contextualballoon-add-view-exist",[this,e]);const t=e.stackId||"main";if(!this._idToStack.has(t))return this._idToStack.set(t,new Map([[e.view,e]])),this._viewToStack.set(e.view,this._idToStack.get(t)),this._numberOfStacks=this._idToStack.size,void(this._visibleStack&&!e.singleViewMode||this.showStack(t));const o=this._idToStack.get(t);e.singleViewMode&&this.showStack(t),o.set(e.view,e),this._viewToStack.set(e.view,o),o===this._visibleStack&&this._showView(e)}remove(e){if(!this.hasView(e))throw new E("contextualballoon-remove-view-not-exist",[this,e]);const t=this._viewToStack.get(e);this._singleViewMode&&this.visibleView===e&&(this._singleViewMode=!1),this.visibleView===e&&(1===t.size?this._idToStack.size>1?this._showNextStack():(this.view.hide(),this.visibleView=null,this._rotatorView.hideView()):this._showView(Array.from(t.values())[t.size-2])),1===t.size?(this._idToStack.delete(this._getStackId(t)),this._numberOfStacks=this._idToStack.size):t.delete(e),this._viewToStack.delete(e)}updatePosition(e){e&&(this._visibleStack.get(this.visibleView).position=e),this.view.pin(this._getBalloonPosition()),this._fakePanelsView.updatePosition()}showStack(e){this.visibleStack=e;const t=this._idToStack.get(e);if(!t)throw new E("contextualballoon-showstack-stack-not-exist",this);this._visibleStack!==t&&this._showView(Array.from(t.values()).pop())}_createPanelView(){this._view=new Ff(this.editor.locale),this.editor.ui.view.body.add(this._view),this.editor.ui.focusTracker.add(this._view.element),this._rotatorView=this._createRotatorView(),this._fakePanelsView=this._createFakePanelsView()}get _visibleStack(){return this._viewToStack.get(this.visibleView)}_getStackId(e){return Array.from(this._idToStack.entries()).find((t=>t[1]===e))[0]}_showNextStack(){const e=Array.from(this._idToStack.values());let t=e.indexOf(this._visibleStack)+1;e[t]||(t=0),this.showStack(this._getStackId(e[t]))}_showPrevStack(){const e=Array.from(this._idToStack.values());let t=e.indexOf(this._visibleStack)-1;e[t]||(t=e.length-1),this.showStack(this._getStackId(e[t]))}_createRotatorView(){const e=new Mb(this.editor.locale),t=this.editor.locale.t;return this.view.content.add(e),e.bind("isNavigationVisible").to(this,"_numberOfStacks",this,"_singleViewMode",((e,t)=>!t&&e>1)),e.on("change:isNavigationVisible",(()=>this.updatePosition()),{priority:"low"}),e.bind("counter").to(this,"visibleView",this,"_numberOfStacks",((e,o)=>{if(o<2)return"";const n=Array.from(this._idToStack.values()).indexOf(this._visibleStack)+1;return t("%0 of %1",[n,o])})),e.buttonNextView.on("execute",(()=>{e.focusTracker.isFocused&&this.editor.editing.view.focus(),this._showNextStack()})),e.buttonPrevView.on("execute",(()=>{e.focusTracker.isFocused&&this.editor.editing.view.focus(),this._showPrevStack()})),e}_createFakePanelsView(){const e=new Rb(this.editor.locale,this.view);return e.bind("numberOfPanels").to(this,"_numberOfStacks",this,"_singleViewMode",((e,t)=>!t&&e>=2?Math.min(e-1,2):0)),e.listenTo(this.view,"change:top",(()=>e.updatePosition())),e.listenTo(this.view,"change:left",(()=>e.updatePosition())),this.editor.ui.view.body.add(e),e}_showView({view:e,balloonClassName:t="",withArrow:o=!0,singleViewMode:n=!1}){this.view.class=t,this.view.withArrow=o,this._rotatorView.showView(e),this.visibleView=e,this.view.pin(this._getBalloonPosition()),this._fakePanelsView.updatePosition(),n&&(this._singleViewMode=!0)}_getBalloonPosition(){let e=Array.from(this._visibleStack.values()).pop().position;return e&&(e.limiter||(e=Object.assign({},e,{limiter:this.positionLimiter})),e=Object.assign({},e,{viewportOffsetConfig:this.editor.ui.viewportOffset})),e}}class Mb extends pm{constructor(e){super(e);const t=e.t,o=this.bindTemplate;this.set("isNavigationVisible",!0),this.focusTracker=new Xi,this.buttonPrevView=this._createButtonView(t("Previous"),qh.previousArrow),this.buttonNextView=this._createButtonView(t("Next"),qh.nextArrow),this.content=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-balloon-rotator"],"z-index":"-1"},children:[{tag:"div",attributes:{class:["ck-balloon-rotator__navigation",o.to("isNavigationVisible",(e=>e?"":"ck-hidden"))]},children:[this.buttonPrevView,{tag:"span",attributes:{class:["ck-balloon-rotator__counter"]},children:[{text:o.to("counter")}]},this.buttonNextView]},{tag:"div",attributes:{class:"ck-balloon-rotator__content"},children:this.content}]})}render(){super.render(),this.focusTracker.add(this.element)}destroy(){super.destroy(),this.focusTracker.destroy()}showView(e){this.hideView(),this.content.add(e)}hideView(){this.content.clear()}_createButtonView(e,t){const o=new Em(this.locale);return o.set({label:e,icon:t,tooltip:!0}),o}}class Rb extends pm{constructor(e,t){super(e);const o=this.bindTemplate;this.set("top",0),this.set("left",0),this.set("height",0),this.set("width",0),this.set("numberOfPanels",0),this.content=this.createCollection(),this._balloonPanelView=t,this.setTemplate({tag:"div",attributes:{class:["ck-fake-panel",o.to("numberOfPanels",(e=>e?"":"ck-hidden"))],style:{top:o.to("top",Pb),left:o.to("left",Pb),width:o.to("width",Pb),height:o.to("height",Pb)}},children:this.content}),this.on("change:numberOfPanels",((e,t,o,n)=>{o>n?this._addPanels(o-n):this._removePanels(n-o),this.updatePosition()}))}_addPanels(e){for(;e--;){const e=new pm;e.setTemplate({tag:"div"}),this.content.add(e),this.registerChild(e)}}_removePanels(e){for(;e--;){const e=this.content.last;this.content.remove(e),this.deregisterChild(e),e.destroy()}}updatePosition(){if(this.numberOfPanels){const{top:e,left:t}=this._balloonPanelView,{width:o,height:n}=new qn(this._balloonPanelView.element);Object.assign(this,{top:e,left:t,width:o,height:n})}}}var zb=i(7289),Vb={attributes:{"data-cke":!0}};Vb.setAttributes=Ar(),Vb.insert=_r().bind(null,"head"),Vb.domAPI=kr(),Vb.insertStyleElement=vr();fr()(zb.A,Vb);zb.A&&zb.A.locals&&zb.A.locals;class Ob extends jp{constructor(e,t){const o=e.t,n=Object.assign({},{showResetButton:!0,showIcon:!0,creator:Fg},t);super(e,n.creator),this.label=t.label,this._viewConfig=n,this._viewConfig.showIcon&&(this.iconView=new Am,this.iconView.content=qh.loupe,this.fieldWrapperChildren.add(this.iconView,0),this.extendTemplate({attributes:{class:"ck-search__query_with-icon"}})),this._viewConfig.showResetButton&&(this.resetButtonView=new Em(e),this.resetButtonView.set({label:o("Clear"),icon:qh.cancel,class:"ck-search__reset",isVisible:!1,tooltip:!0}),this.resetButtonView.on("execute",(()=>{this.reset(),this.focus(),this.fire("reset")})),this.resetButtonView.bind("isVisible").to(this.fieldView,"isEmpty",(e=>!e)),this.fieldWrapperChildren.add(this.resetButtonView),this.extendTemplate({attributes:{class:"ck-search__query_with-reset"}}))}reset(){this.fieldView.reset(),this._viewConfig.showResetButton&&(this.resetButtonView.isVisible=!1)}}class Nb extends pm{constructor(){super();const e=this.bindTemplate;this.set({isVisible:!1,primaryText:"",secondaryText:""}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-search__info",e.if("isVisible","ck-hidden",(e=>!e))],tabindex:-1},children:[{tag:"span",children:[{text:[e.to("primaryText")]}]},{tag:"span",children:[{text:[e.to("secondaryText")]}]}]})}focus(){this.element.focus()}}class Lb extends pm{constructor(e){super(e),this.children=this.createCollection(),this.focusTracker=new Xi,this.setTemplate({tag:"div",attributes:{class:["ck","ck-search__results"],tabindex:-1},children:this.children}),this._focusCycler=new Im({focusables:this.children,focusTracker:this.focusTracker})}render(){super.render();for(const e of this.children)this.focusTracker.add(e.element)}focus(){this._focusCycler.focusFirst()}focusFirst(){this._focusCycler.focusFirst()}focusLast(){this._focusCycler.focusLast()}}var Hb=/[\\^$.*+?()[\]{}|]/g,jb=RegExp(Hb.source);const qb=function(e){return(e=rs(e))&&jb.test(e)?e.replace(Hb,"\\$&"):e};var Ub=i(5540),Wb={attributes:{"data-cke":!0}};Wb.setAttributes=Ar(),Wb.insert=_r().bind(null,"head"),Wb.domAPI=kr(),Wb.insertStyleElement=vr();fr()(Ub.A,Wb);Ub.A&&Ub.A.locals&&Ub.A.locals;class $b extends pm{constructor(e,t){super(e),this._config=t,this.filteredView=t.filteredView,this.queryView=this._createSearchTextQueryView(),this.focusTracker=new Xi,this.keystrokes=new er,this.resultsView=new Lb(e),this.children=this.createCollection(),this.focusableChildren=this.createCollection([this.queryView,this.resultsView]),this.set("isEnabled",!0),this.set("resultsCount",0),this.set("totalItemsCount",0),t.infoView&&t.infoView.instance?this.infoView=t.infoView.instance:(this.infoView=new Nb,this._enableDefaultInfoViewBehavior(),this.on("render",(()=>{this.search("")}))),this.resultsView.children.addMany([this.infoView,this.filteredView]),this.focusCycler=new Im({focusables:this.focusableChildren,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.on("search",((e,{resultsCount:t,totalItemsCount:o})=>{this.resultsCount=t,this.totalItemsCount=o})),this.setTemplate({tag:"div",attributes:{class:["ck","ck-search",t.class||null],tabindex:"-1"},children:this.children})}render(){super.render(),this.children.addMany([this.queryView,this.resultsView]);const e=e=>e.stopPropagation();for(const e of this.focusableChildren)this.focusTracker.add(e.element);this.keystrokes.listenTo(this.element),this.keystrokes.set("arrowright",e),this.keystrokes.set("arrowleft",e),this.keystrokes.set("arrowup",e),this.keystrokes.set("arrowdown",e)}focus(){this.queryView.focus()}reset(){this.queryView.reset(),this.search(""),this.filteredView.element.scrollTo(0,0)}search(e){const t=e?new RegExp(qb(e),"ig"):null,o=this.filteredView.filter(t);this.fire("search",{query:e,...o})}_createSearchTextQueryView(){const e=new Ob(this.locale,this._config.queryView);return this.listenTo(e.fieldView,"input",(()=>{this.search(e.fieldView.element.value)})),e.on("reset",(()=>this.reset())),e.bind("isEnabled").to(this),e}_enableDefaultInfoViewBehavior(){const e=this.locale.t,t=this.infoView;function o(e,{query:t,resultsCount:o,totalItemsCount:n}){return"function"==typeof e?e(t,o,n):e}this.on("search",((n,i)=>{if(i.resultsCount)t.set({isVisible:!1});else{const n=this._config.infoView&&this._config.infoView.text;let r,s;i.totalItemsCount?n&&n.notFound?(r=n.notFound.primary,s=n.notFound.secondary):(r=e("No results found"),s=""):n&&n.noSearchableItems?(r=n.noSearchableItems.primary,s=n.noSearchableItems.secondary):(r=e("No searchable items"),s=""),t.set({primaryText:o(r,i),secondaryText:o(s,i),isVisible:!0})}}))}}var Gb=i(2688),Kb={attributes:{"data-cke":!0}};Kb.setAttributes=Ar(),Kb.insert=_r().bind(null,"head"),Kb.domAPI=kr(),Kb.insertStyleElement=vr();fr()(Gb.A,Kb);Gb.A&&Gb.A.locals&&Gb.A.locals;class Zb extends $b{constructor(e,o){super(e,o),this._config=o;const n=Yn("px");this.extendTemplate({attributes:{class:["ck-autocomplete"]}});const i=this.resultsView.bindTemplate;this.resultsView.set("isVisible",!1),this.resultsView.set("_position","s"),this.resultsView.set("_width",0),this.resultsView.extendTemplate({attributes:{class:[i.if("isVisible","ck-hidden",(e=>!e)),i.to("_position",(e=>`ck-search__results_${e}`))],style:{width:i.to("_width",n)}}}),this.focusTracker.on("change:isFocused",((e,t,n)=>{this._updateResultsVisibility(),n?this.resultsView.element.scrollTop=0:o.resetOnBlur&&this.queryView.reset()})),this.on("search",(()=>{this._updateResultsVisibility(),this._updateResultsViewWidthAndPosition()})),this.keystrokes.set("esc",((e,t)=>{this.resultsView.isVisible&&(this.queryView.focus(),this.resultsView.isVisible=!1,t())})),this.listenTo(t.document,"scroll",(()=>{this._updateResultsViewWidthAndPosition()})),this.on("change:isEnabled",(()=>{this._updateResultsVisibility()})),this.filteredView.on("execute",((e,{value:t})=>{this.focus(),this.reset(),this.queryView.fieldView.value=this.queryView.fieldView.element.value=t,this.resultsView.isVisible=!1})),this.resultsView.on("change:isVisible",(()=>{this._updateResultsViewWidthAndPosition()}))}_updateResultsViewWidthAndPosition(){if(!this.resultsView.isVisible)return;this.resultsView._width=new qn(this.queryView.fieldView.element).width;const e=Zb._getOptimalPosition({element:this.resultsView.element,target:this.queryView.element,fitInViewport:!0,positions:Zb.defaultResultsPositions});this.resultsView._position=e?e.name:"s"}_updateResultsVisibility(){const e=void 0===this._config.queryMinChars?0:this._config.queryMinChars,t=this.queryView.fieldView.element.value.length;this.resultsView.isVisible=this.focusTracker.isFocused&&this.isEnabled&&t>=e}}Zb.defaultResultsPositions=[e=>({top:e.bottom,left:e.left,name:"s"}),(e,t)=>({top:e.top-t.height,left:e.left,name:"n"})],Zb._getOptimalPosition=oi;Jb={"&":"&","<":"<",">":">",'"':""","'":"'"};var Jb;var Yb=/[&<>"']/g;RegExp(Yb.source);var Qb=i(1998),Xb={attributes:{"data-cke":!0}};Xb.setAttributes=Ar(),Xb.insert=_r().bind(null,"head"),Xb.domAPI=kr(),Xb.insertStyleElement=vr();fr()(Qb.A,Xb);Qb.A&&Qb.A.locals&&Qb.A.locals;var ek=i(5706),tk={attributes:{"data-cke":!0}};tk.setAttributes=Ar(),tk.insert=_r().bind(null,"head"),tk.domAPI=kr(),tk.insertStyleElement=vr();fr()(ek.A,tk);ek.A&&ek.A.locals&&ek.A.locals;var ok=i(9939),nk={attributes:{"data-cke":!0}};nk.setAttributes=Ar(),nk.insert=_r().bind(null,"head"),nk.domAPI=kr(),nk.insertStyleElement=vr();fr()(ok.A,nk);ok.A&&ok.A.locals&&ok.A.locals;var ik=i(5667),rk={attributes:{"data-cke":!0}};rk.setAttributes=Ar(),rk.insert=_r().bind(null,"head"),rk.domAPI=kr(),rk.insertStyleElement=vr();fr()(ik.A,rk);ik.A&&ik.A.locals&&ik.A.locals;class sk extends ep{constructor(e){super(e);const t=this.bindTemplate;this.set({withText:!0,role:"menuitem"}),this.arrowView=this._createArrowView(),this.extendTemplate({attributes:{class:["ck-menu-bar__menu__button"],"aria-haspopup":!0,"aria-expanded":this.bindTemplate.to("isOn",(e=>String(e))),"data-cke-tooltip-disabled":t.to("isOn")},on:{mouseenter:t.to("mouseenter")}})}render(){super.render(),this.children.add(this.arrowView)}_createArrowView(){const e=new Am;return e.content=Ap,e.extendTemplate({attributes:{class:"ck-menu-bar__menu__button__arrow"}}),e}}var ak=i(4873),lk={attributes:{"data-cke":!0}};lk.setAttributes=Ar(),lk.insert=_r().bind(null,"head"),lk.domAPI=kr(),lk.insertStyleElement=vr();fr()(ak.A,lk);ak.A&&ak.A.locals&&ak.A.locals;class ck extends pm{constructor(e){super(e);const t=this.bindTemplate;this.set("isVisible",!1),this.set("position","se"),this.children=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-reset","ck-menu-bar__menu__panel",t.to("position",(e=>`ck-menu-bar__menu__panel_position_${e}`)),t.if("isVisible","ck-hidden",(e=>!e))],tabindex:"-1"},children:this.children,on:{selectstart:t.to((e=>{"input"!==e.target.tagName.toLocaleLowerCase()&&e.preventDefault()}))}})}focus(e=1){this.children.length&&(1===e?this.children.first.focus():this.children.last.focus())}}var dk=i(55),uk={attributes:{"data-cke":!0}};uk.setAttributes=Ar(),uk.insert=_r().bind(null,"head"),uk.domAPI=kr(),uk.insertStyleElement=vr();fr()(dk.A,uk);dk.A&&dk.A.locals&&dk.A.locals;class hk extends pm{constructor(e){super(e);const t=this.bindTemplate;this.buttonView=new sk(e),this.buttonView.delegate("mouseenter").to(this),this.buttonView.bind("isOn","isEnabled").to(this,"isOpen","isEnabled"),this.panelView=new ck(e),this.panelView.bind("isVisible").to(this,"isOpen"),this.keystrokes=new er,this.focusTracker=new Xi,this.set("isOpen",!1),this.set("isEnabled",!0),this.set("panelPosition","w"),this.set("class",void 0),this.set("parentMenuView",null),this.setTemplate({tag:"div",attributes:{class:["ck","ck-menu-bar__menu",t.to("class"),t.if("isEnabled","ck-disabled",(e=>!e)),t.if("parentMenuView","ck-menu-bar__menu_top-level",(e=>!e))]},children:[this.buttonView,this.panelView]})}render(){super.render(),this.focusTracker.add(this.buttonView.element),this.focusTracker.add(this.panelView.element),this.keystrokes.listenTo(this.element),rb.closeOnEscKey(this),this._repositionPanelOnOpen()}_attachBehaviors(){this.parentMenuView?(rb.openOnButtonClick(this),rb.openOnArrowRightKey(this),rb.closeOnArrowLeftKey(this),rb.closeOnParentClose(this)):(this._propagateArrowKeystrokeEvents(),rb.openAndFocusPanelOnArrowDownKey(this),rb.toggleOnButtonClick(this))}_propagateArrowKeystrokeEvents(){this.keystrokes.set("arrowright",((e,t)=>{this.fire("arrowright"),t()})),this.keystrokes.set("arrowleft",((e,t)=>{this.fire("arrowleft"),t()}))}_repositionPanelOnOpen(){this.on("change:isOpen",((e,t,o)=>{if(!o)return;const n=hk._getOptimalPosition({element:this.panelView.element,target:this.buttonView.element,fitInViewport:!0,positions:this._panelPositions});this.panelView.position=n?n.name:this._panelPositions[0].name}))}focus(){this.buttonView.focus()}get _panelPositions(){const{southEast:e,southWest:t,northEast:o,northWest:n,westSouth:i,eastSouth:r,westNorth:s,eastNorth:a}=sb;return"ltr"===this.locale.uiLanguageDirection?this.parentMenuView?[r,a,i,s]:[e,t,o,n]:this.parentMenuView?[i,s,r,a]:[t,e,n,o]}}hk._getOptimalPosition=oi;const mk=hk;class pk extends kg{constructor(e){super(e),this.role="menu",this.items.on("change",this._setItemsCheckSpace.bind(this))}_setItemsCheckSpace(){const e=Array.from(this.items).some((e=>{const t=gk(e);return t&&t.isToggleable}));this.items.forEach((t=>{const o=gk(t);o&&(o.hasCheckSpace=e)}))}}function gk(e){return e instanceof mg?e.children.map((e=>function(e){return"object"==typeof e&&"buttonView"in e&&e.buttonView instanceof Em}(e)?e.buttonView:e)).find((e=>e instanceof ep)):null}class fk extends wp{constructor(e){super(e),this.set({withText:!0,withKeystroke:!0,tooltip:!1,role:"menuitem"}),this.extendTemplate({attributes:{class:["ck-menu-bar__menu__item__button"]}})}}var bk=i(4782),kk={attributes:{"data-cke":!0}};kk.setAttributes=Ar(),kk.insert=_r().bind(null,"head"),kk.domAPI=kr(),kk.insertStyleElement=vr();fr()(bk.A,kk);bk.A&&bk.A.locals&&bk.A.locals;const wk=["mouseenter","arrowleft","arrowright","change:isOpen"];class _k extends pm{constructor(e){super(e),this.menus=[];const t=e.t,o=this.bindTemplate;this.set({isOpen:!1,isFocusBorderEnabled:!1}),this._setupIsOpenUpdater(),this.children=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-menu-bar",o.if("isFocusBorderEnabled","ck-menu-bar_focus-border-enabled")],"aria-label":t("Editor menu bar"),role:"menubar"},children:this.children})}fillFromConfig(e,t,o=[]){const n=lb({normalizedConfig:e,locale:this.locale,componentFactory:t,extraItems:o}).items.map((e=>this._createMenu({componentFactory:t,menuDefinition:e})));this.children.addMany(n)}render(){super.render(),ib.toggleMenusAndFocusItemsOnHover(this),ib.closeMenusWhenTheBarCloses(this),ib.closeMenuWhenAnotherOnTheSameLevelOpens(this),ib.focusCycleMenusOnArrows(this),ib.closeOnClickOutside(this),ib.enableFocusHighlightOnInteraction(this)}focus(){this.children.first&&this.children.first.focus()}close(){for(const e of this.children)e.isOpen=!1}registerMenu(e,t=null){t?(e.delegate(...wk).to(t),e.parentMenuView=t):e.delegate(...wk).to(this,(e=>"menu:"+e)),e._attachBehaviors(),this.menus.push(e)}_createMenu({componentFactory:e,menuDefinition:t,parentMenuView:o}){const n=this.locale,i=new mk(n);return this.registerMenu(i,o),i.buttonView.set({label:t.label}),i.once("change:isOpen",(()=>{const o=new pk(n);o.ariaLabel=t.label,i.panelView.children.add(o),o.items.addMany(this._createMenuItems({menuDefinition:t,parentMenuView:i,componentFactory:e}))})),i}_createMenuItems({menuDefinition:e,parentMenuView:t,componentFactory:o}){const n=this.locale,i=[];for(const r of e.groups){for(const e of r.items){const r=new nb(n,t);if(U(e))r.children.add(this._createMenu({componentFactory:o,menuDefinition:e,parentMenuView:t}));else{const n=this._createMenuItemContentFromFactory({componentName:e,componentFactory:o,parentMenuView:t});if(!n)continue;r.children.add(n)}i.push(r)}r!==e.groups[e.groups.length-1]&&i.push(new pg(n))}return i}_createMenuItemContentFromFactory({componentName:e,parentMenuView:t,componentFactory:o}){const n=o.create(e);return n instanceof mk||n instanceof ip||n instanceof fk?(this._registerMenuTree(n,t),n.on("execute",(()=>{this.close()})),n):(D("menu-bar-component-unsupported",{componentName:e,componentView:n}),null)}_registerMenuTree(e,t){if(!(e instanceof mk))return void e.delegate("mouseenter").to(t);this.registerMenu(e,t);const o=e.panelView.children.filter((e=>e instanceof pk))[0];if(!o)return void e.delegate("mouseenter").to(t);const n=o.items.filter((e=>e instanceof mg));for(const t of n)this._registerMenuTree(t.children.get(0),e)}_setupIsOpenUpdater(){let e;this.on("menu:change:isOpen",((t,o,n)=>{clearTimeout(e),n?this.isOpen=!0:e=setTimeout((()=>{this.isOpen=Array.from(this.children).some((e=>e.isOpen))}),0)}))}}class yk extends wb{constructor(e,t){super(e),this.view=t}init(){const e=this.editor,t=this.view,o=e.editing.view,n=t.editable,i=o.document.getRoot();n.name=i.rootName,t.render();const r=n.element;this.setEditableElement(n.name,r),t.editable.bind("isFocused").to(this.focusTracker),o.attachDomRoot(r),this._initPlaceholder(),this._initToolbar(),this._initMenuBar(this.view.menuBarView),this.fire("ready")}destroy(){super.destroy();const e=this.view;this.editor.editing.view.detachDomRoot(e.editable.name),e.destroy()}_initToolbar(){const e=this.editor,t=this.view;t.toolbar.fillFromConfig(e.config.get("toolbar"),this.componentFactory),this.addToolbar(t.toolbar)}_initPlaceholder(){const e=this.editor,t=e.editing.view,o=t.document.getRoot(),n=e.config.get("placeholder");if(n){const e="string"==typeof n?n:n[o.rootName];e&&(o.placeholder=e)}Sr({view:t,element:o,isDirectHost:!1,keepOnFocus:!0})}}class Ak extends Cb{constructor(e,t,o={}){super(e);const n=e.t;this.toolbar=new cg(e,{shouldGroupWhenFull:o.shouldToolbarGroupWhenFull}),this.menuBarView=new _k(e),this.editable=new xb(e,t,o.editableElement,{label:e=>n("Rich Text Editor. Editing area: %0",e.name)}),this.toolbar.extendTemplate({attributes:{class:["ck-reset_all","ck-rounded-corners"],dir:e.uiLanguageDirection}}),this.menuBarView.extendTemplate({attributes:{class:["ck-reset_all","ck-rounded-corners"],dir:e.uiLanguageDirection}})}render(){super.render(),this.registerChild([this.menuBarView,this.toolbar,this.editable])}}class Ck extends(Hh(Lh)){constructor(e,t={}){if(!vk(e)&&void 0!==t.initialData)throw new E("editor-create-initial-data",null);super(t),void 0===this.config.get("initialData")&&this.config.set("initialData",function(e){return vk(e)?(t=e,t instanceof HTMLTextAreaElement?t.value:t.innerHTML):e;var t}(e)),vk(e)&&(this.sourceElement=e,function(e,t){if(t.ckeditorInstance)throw new E("editor-source-element-already-used",e);t.ckeditorInstance=e,e.once("destroy",(()=>{delete t.ckeditorInstance}))}(this,e)),this.model.document.createRoot();const o=!this.config.get("toolbar.shouldNotGroupWhenFull"),n=new Ak(this.locale,this.editing.view,{editableElement:this.sourceElement,shouldToolbarGroupWhenFull:o});this.ui=new yk(this,n)}destroy(){const e=this.getData();return this.ui.destroy(),super.destroy().then((()=>{this.sourceElement&&this.updateSourceElement(e)}))}static create(e,t={}){return new Promise((o=>{if(vk(e)&&"TEXTAREA"===e.tagName)throw new E("editor-wrong-element",null);const n=new this(e,t);o(n.initPlugins().then((()=>n.ui.init())).then((()=>n.data.init(n.config.get("initialData")))).then((()=>n.fire("ready"))).then((()=>n)))}))}}function vk(e){return Bn(e)}class xk extends(z()){constructor(){super(...arguments),this._stack=[]}add(e,t){const o=this._stack,n=o[0];this._insertDescriptor(e);const i=o[0];n===i||Ek(n,i)||this.fire("change:top",{oldDescriptor:n,newDescriptor:i,writer:t})}remove(e,t){const o=this._stack,n=o[0];this._removeDescriptor(e);const i=o[0];n===i||Ek(n,i)||this.fire("change:top",{oldDescriptor:n,newDescriptor:i,writer:t})}_insertDescriptor(e){const t=this._stack,o=t.findIndex((t=>t.id===e.id));if(Ek(e,t[o]))return;o>-1&&t.splice(o,1);let n=0;for(;t[n]&&Dk(t[n],e);)n++;t.splice(n,0,e)}_removeDescriptor(e){const t=this._stack,o=t.findIndex((t=>t.id===e));o>-1&&t.splice(o,1)}}function Ek(e,t){return e&&t&&e.priority==t.priority&&Bk(e.classes)==Bk(t.classes)}function Dk(e,t){return e.priority>t.priority||!(e.priorityBk(t.classes)}function Bk(e){return Array.isArray(e)?e.sort().join(","):e}const Sk="widget-type-around";function Tk(e,t,o){return!!e&&Rk(e)&&!o.isInline(t)}function Ik(e){return e.getAttribute(Sk)}const Pk='',Fk="ck-widget",Mk="ck-widget_selected";function Rk(e){return!!e.is("element")&&!!e.getCustomProperty("widget")}function zk(e,t,o={}){if(!e.is("containerElement"))throw new E("widget-to-widget-wrong-element-type",null,{element:e});return t.setAttribute("contenteditable","false",e),t.addClass(Fk,e),t.setCustomProperty("widget",!0,e),e.getFillerOffset=Hk,t.setCustomProperty("widgetLabel",[],e),o.label&&function(e,t){const o=e.getCustomProperty("widgetLabel");o.push(t)}(e,o.label),o.hasSelectionHandle&&function(e,t){const o=t.createUIElement("div",{class:"ck ck-widget__selection-handle"},(function(e){const t=this.toDomElement(e),o=new Am;return o.set("content",Pk),o.render(),t.appendChild(o.element),t}));t.insert(t.createPositionAt(e,0),o),t.addClass(["ck-widget_with-selection-handle"],e)}(e,t),Nk(e,t),e}function Vk(e,t,o){if(t.classes&&o.addClass(xi(t.classes),e),t.attributes)for(const n in t.attributes)o.setAttribute(n,t.attributes[n],e)}function Ok(e,t,o){if(t.classes&&o.removeClass(xi(t.classes),e),t.attributes)for(const n in t.attributes)o.removeAttribute(n,e)}function Nk(e,t,o=Vk,n=Ok){const i=new xk;i.on("change:top",((t,i)=>{i.oldDescriptor&&n(e,i.oldDescriptor,i.writer),i.newDescriptor&&o(e,i.newDescriptor,i.writer)}));t.setCustomProperty("addHighlight",((e,t,o)=>i.add(t,o)),e),t.setCustomProperty("removeHighlight",((e,t,o)=>i.remove(t,o)),e)}function Lk(e,t,o={}){return t.addClass(["ck-editor__editable","ck-editor__nested-editable"],e),t.setAttribute("role","textbox",e),t.setAttribute("tabindex","-1",e),o.label&&t.setAttribute("aria-label",o.label,e),t.setAttribute("contenteditable",e.isReadOnly?"false":"true",e),e.on("change:isReadOnly",((o,n,i)=>{t.setAttribute("contenteditable",i?"false":"true",e)})),e.on("change:isFocused",((o,n,i)=>{i?t.addClass("ck-editor__nested-editable_focused",e):t.removeClass("ck-editor__nested-editable_focused",e)})),Nk(e,t),e}function Hk(){return null}function jk(e){const t=e=>{const{width:t,paddingLeft:o,paddingRight:n}=e.ownerDocument.defaultView.getComputedStyle(e);return parseFloat(t)-(parseFloat(o)||0)-(parseFloat(n)||0)},o=e.parentElement;if(!o)return 0;let n=t(o);let i=0,r=o;for(;isNaN(n);){if(r=r.parentElement,++i>5)return 0;n=t(r)}return n}class qk extends lr{static get pluginName(){return"OPMacroToc"}static get buttonName(){return"insertToc"}init(){const e=this.editor,t=e.model,o=e.conversion;t.schema.register("op-macro-toc",{allowWhere:"$block",isBlock:!0,isLimit:!0}),o.for("upcast").elementToElement({view:{name:"macro",classes:"toc"},model:"op-macro-toc"}),o.for("editingDowncast").elementToElement({model:"op-macro-toc",view:(e,{writer:t})=>zk(this.createTocViewElement(t),t,{label:this.label})}),o.for("dataDowncast").elementToElement({model:"op-macro-toc",view:(e,{writer:t})=>this.createTocDataElement(t)}),e.ui.componentFactory.add(qk.buttonName,(t=>{const o=new Em(t);return o.set({label:this.label,withText:!0}),o.on("execute",(()=>{e.model.change((t=>{const o=t.createElement("op-macro-toc",{});e.model.insertContent(o,e.model.document.selection)}))})),o}))}get label(){return window.I18n.t("js.editor.macro.toc")}createTocViewElement(e){const t=e.createText(this.label),o=e.createContainerElement("div");return e.insert(e.createPositionAt(o,0),t),o}createTocDataElement(e){return e.createContainerElement("macro",{class:"toc"})}}const Uk=Symbol("isOPEmbeddedTable");function Wk(e){const t=e.getSelectedElement();return!(!t||!function(e){return!!e.getCustomProperty(Uk)&&Rk(e)}(t))}function $k(e){return _.get(e.config,"_config.openProject.context.resource")}function Gk(e){return _.get(e.config,"_config.openProject.pluginContext")}function Kk(e,t){return Gk(e).services[t]}function Zk(e){return Kk(e,"pathHelperService")}class Jk extends lr{static get pluginName(){return"EmbeddedTableEditing"}static get buttonName(){return"insertEmbeddedTable"}init(){const e=this.editor,t=e.model,o=e.conversion,n=Gk(e);this.text={button:window.I18n.t("js.editor.macro.embedded_table.button"),macro_text:window.I18n.t("js.editor.macro.embedded_table.text")},t.schema.register("op-macro-embedded-table",{allowWhere:"$block",allowAttributes:["opEmbeddedTableQuery"],isBlock:!0,isObject:!0}),o.for("upcast").elementToElement({view:{name:"macro",classes:"embedded-table"},model:(e,{writer:t})=>{const o=e.getAttribute("data-query-props");return t.createElement("op-macro-embedded-table",{opEmbeddedTableQuery:o?JSON.parse(o):{}})}}),o.for("editingDowncast").elementToElement({model:"op-macro-embedded-table",view:(e,{writer:t})=>{return o=this.createEmbeddedTableView(t),n=t,this.label,n.setCustomProperty(Uk,!0,o),zk(o,n,{label:"your label here"});var o,n}}),o.for("dataDowncast").elementToElement({model:"op-macro-embedded-table",view:(e,{writer:t})=>this.createEmbeddedTableDataElement(e,t)}),e.ui.componentFactory.add(Jk.buttonName,(t=>{const o=new Em(t);return o.set({label:this.text.button,withText:!0}),o.on("execute",(()=>n.runInZone((()=>{n.services.externalQueryConfiguration.show({currentQuery:{},callback:t=>e.model.change((o=>{const n=o.createElement("op-macro-embedded-table",{opEmbeddedTableQuery:t});e.model.insertContent(n,e.model.document.selection)}))})})))),o}))}createEmbeddedTableView(e){const t=e.createText(this.text.macro_text),o=e.createContainerElement("div");return e.insert(e.createPositionAt(o,0),t),o}createEmbeddedTableDataElement(e,t){const o=e.getAttribute("opEmbeddedTableQuery")||{};return t.createContainerElement("macro",{class:"embedded-table","data-query-props":JSON.stringify(o)})}}class Yk{constructor(e,t=20){this._batch=null,this.model=e,this._size=0,this.limit=t,this._isLocked=!1,this._changeCallback=(e,t)=>{t.isLocal&&t.isUndoable&&t!==this._batch&&this._reset(!0)},this._selectionChangeCallback=()=>{this._reset()},this.model.document.on("change",this._changeCallback),this.model.document.selection.on("change:range",this._selectionChangeCallback),this.model.document.selection.on("change:attribute",this._selectionChangeCallback)}get batch(){return this._batch||(this._batch=this.model.createBatch({isTyping:!0})),this._batch}get size(){return this._size}input(e){this._size+=e,this._size>=this.limit&&this._reset(!0)}get isLocked(){return this._isLocked}lock(){this._isLocked=!0}unlock(){this._isLocked=!1}destroy(){this.model.document.off("change",this._changeCallback),this.model.document.selection.off("change:range",this._selectionChangeCallback),this.model.document.selection.off("change:attribute",this._selectionChangeCallback)}_reset(e=!1){this.isLocked&&!e||(this._batch=null,this._size=0)}}class Qk extends dr{constructor(e,t){super(e),this._buffer=new Yk(e.model,t),this._isEnabledBasedOnSelection=!1}get buffer(){return this._buffer}destroy(){super.destroy(),this._buffer.destroy()}execute(e={}){const t=this.editor.model,o=t.document,n=e.text||"",i=n.length;let r=o.selection;if(e.selection?r=e.selection:e.range&&(r=t.createSelection(e.range)),!t.canEditAt(r))return;const s=e.resultRange;t.enqueueChange(this._buffer.batch,(e=>{this._buffer.lock();const a=Array.from(o.selection.getAttributes());t.deleteContent(r),n&&t.insertContent(e.createText(n,a),r),s?e.setSelection(s):r.is("documentSelection")||e.setSelection(r),this._buffer.unlock(),this._buffer.input(i)}))}}const Xk=["insertText","insertReplacementText"],ew=[...Xk,"insertCompositionText"];class tw extends za{constructor(e){super(e),this.focusObserver=e.getObserver(xl);const t=r.isAndroid?ew:Xk,o=e.document;o.on("beforeinput",((n,i)=>{if(!this.isEnabled)return;const{data:r,targetRanges:s,inputType:a,domEvent:l}=i;if(!t.includes(a))return;this.focusObserver.flush();const c=new w(o,"insertText");o.fire(c,new Na(e,l,{text:r,selection:e.createSelection(s)})),c.stop.called&&n.stop()})),r.isAndroid||o.on("compositionend",((t,{data:n,domEvent:i})=>{this.isEnabled&&n&&o.fire("insertText",new Na(e,i,{text:n}))}),{priority:"lowest"})}observe(){}stopObserving(){}}class ow extends lr{static get pluginName(){return"Input"}init(){const e=this.editor,t=e.model,o=e.editing.view,n=e.editing.mapper,i=t.document.selection;this._compositionQueue=new nw(e),o.addObserver(tw);const s=new Qk(e,e.config.get("typing.undoStep")||20);e.commands.add("insertText",s),e.commands.add("input",s),this.listenTo(o.document,"insertText",((s,a)=>{o.document.isComposing||a.preventDefault(),r.isAndroid&&o.document.isComposing&&this._compositionQueue.flush("next beforeinput");const{text:l,selection:c}=a;let d;d=c?Array.from(c.getRanges()).map((e=>n.toModelRange(e))):Array.from(i.getRanges());let u=l;if(r.isAndroid){const e=Array.from(d[0].getItems()).reduce(((e,t)=>e+(t.is("$textProxy")?t.data:"")),"");if(e&&(e.length<=u.length?u.startsWith(e)&&(u=u.substring(e.length),d[0].start=d[0].start.getShiftedBy(e.length)):e.startsWith(u)&&(d[0].start=d[0].start.getShiftedBy(u.length),u="")),0==u.length&&d[0].isCollapsed)return}const h={text:u,selection:t.createSelection(d)};r.isAndroid&&o.document.isComposing?this._compositionQueue.push(h):(e.execute("insertText",h),o.scrollToTheSelection())})),r.isAndroid?this.listenTo(o.document,"keydown",((e,n)=>{!i.isCollapsed&&229==n.keyCode&&o.document.isComposing&&iw(t,s)})):this.listenTo(o.document,"compositionstart",(()=>{i.isCollapsed||iw(t,s)})),r.isAndroid?(this.listenTo(o.document,"mutations",((e,{mutations:t})=>{if(o.document.isComposing)for(const{node:e}of t){const t=rw(e,n),o=n.toModelElement(t);if(this._compositionQueue.isComposedElement(o))return void this._compositionQueue.flush("mutations")}})),this.listenTo(o.document,"compositionend",(()=>{this._compositionQueue.flush("composition end")})),this.listenTo(o.document,"compositionend",(()=>{const e=[];for(const t of this._compositionQueue.flushComposedElements()){const o=n.toViewElement(t);o&&e.push({type:"children",node:o})}e.length&&o.document.fire("mutations",{mutations:e})}),{priority:"lowest"})):this.listenTo(o.document,"compositionend",(()=>{o.document.fire("mutations",{mutations:[]})}),{priority:"lowest"})}destroy(){super.destroy(),this._compositionQueue.destroy()}}class nw{constructor(e){this.flushDebounced=el((()=>this.flush("timeout")),50),this._queue=[],this._compositionElements=new Set,this.editor=e}destroy(){for(this.flushDebounced.cancel(),this._compositionElements.clear();this._queue.length;)this.shift()}get length(){return this._queue.length}push(e){const t={text:e.text};if(e.selection){t.selectionRanges=[];for(const o of e.selection.getRanges())t.selectionRanges.push(cc.fromRange(o)),this._compositionElements.add(o.start.parent)}this._queue.push(t),this.flushDebounced()}shift(){const e=this._queue.shift(),t={text:e.text};if(e.selectionRanges){const o=e.selectionRanges.map((e=>function(e){const t=e.toRange();if(e.detach(),"$graveyard"==t.root.rootName)return null;return t}(e))).filter((e=>!!e));o.length&&(t.selection=this.editor.model.createSelection(o))}return t}flush(e){const t=this.editor,o=t.model,n=t.editing.view;if(this.flushDebounced.cancel(),!this._queue.length)return;const i=t.commands.get("insertText").buffer;o.enqueueChange(i.batch,(()=>{for(i.lock();this._queue.length;){const e=this.shift();t.execute("insertText",e)}i.unlock()})),n.scrollToTheSelection()}isComposedElement(e){return this._compositionElements.has(e)}flushComposedElements(){const e=Array.from(this._compositionElements);return this._compositionElements.clear(),e}}function iw(e,t){if(!t.isEnabled)return;const o=t.buffer;o.lock(),e.enqueueChange(o.batch,(()=>{e.deleteContent(e.document.selection)})),o.unlock()}function rw(e,t){let o=e.is("$text")?e.parent:e;for(;!t.toModelElement(o);)o=o.parent;return o}class sw extends dr{constructor(e,t){super(e),this.direction=t,this._buffer=new Yk(e.model,e.config.get("typing.undoStep")),this._isEnabledBasedOnSelection=!1}get buffer(){return this._buffer}execute(e={}){const t=this.editor.model,o=t.document;t.enqueueChange(this._buffer.batch,(n=>{this._buffer.lock();const i=n.createSelection(e.selection||o.selection);if(!t.canEditAt(i))return;const r=e.sequence||1,s=i.isCollapsed;if(i.isCollapsed&&t.modifySelection(i,{direction:this.direction,unit:e.unit,treatEmojiAsSingleUnit:!0}),this._shouldEntireContentBeReplacedWithParagraph(r))return void this._replaceEntireContentWithParagraph(n);if(this._shouldReplaceFirstBlockWithParagraph(i,r))return void this.editor.execute("paragraph",{selection:i});if(i.isCollapsed)return;let a=0;i.getFirstRange().getMinimalFlatRanges().forEach((e=>{a+=ne(e.getWalker({singleCharacters:!0,ignoreElementEnd:!0,shallow:!0}))})),t.deleteContent(i,{doNotResetEntireContent:s,direction:this.direction}),this._buffer.input(a),n.setSelection(i),this._buffer.unlock()}))}_shouldEntireContentBeReplacedWithParagraph(e){if(e>1)return!1;const t=this.editor.model,o=t.document.selection,n=t.schema.getLimitElement(o);if(!(o.isCollapsed&&o.containsEntireContent(n)))return!1;if(!t.schema.checkChild(n,"paragraph"))return!1;const i=n.getChild(0);return!i||!i.is("element","paragraph")}_replaceEntireContentWithParagraph(e){const t=this.editor.model,o=t.document.selection,n=t.schema.getLimitElement(o),i=e.createElement("paragraph");e.remove(e.createRangeIn(n)),e.insert(i,n),e.setSelection(i,0)}_shouldReplaceFirstBlockWithParagraph(e,t){const o=this.editor.model;if(t>1||"backward"!=this.direction)return!1;if(!e.isCollapsed)return!1;const n=e.getFirstPosition(),i=o.schema.getLimitElement(n),r=i.getChild(0);return n.parent==r&&(!!e.containsEntireContent(r)&&(!!o.schema.checkChild(i,"paragraph")&&"paragraph"!=r.name))}}const aw="word",lw="selection",cw="backward",dw="forward",uw={deleteContent:{unit:lw,direction:cw},deleteContentBackward:{unit:"codePoint",direction:cw},deleteWordBackward:{unit:aw,direction:cw},deleteHardLineBackward:{unit:lw,direction:cw},deleteSoftLineBackward:{unit:lw,direction:cw},deleteContentForward:{unit:"character",direction:dw},deleteWordForward:{unit:aw,direction:dw},deleteHardLineForward:{unit:lw,direction:dw},deleteSoftLineForward:{unit:lw,direction:dw}};class hw extends za{constructor(e){super(e);const t=e.document;let o=0;t.on("keydown",(()=>{o++})),t.on("keyup",(()=>{o=0})),t.on("beforeinput",((n,i)=>{if(!this.isEnabled)return;const{targetRanges:s,domEvent:a,inputType:l}=i,c=uw[l];if(!c)return;const d={direction:c.direction,unit:c.unit,sequence:o};d.unit==lw&&(d.selectionToRemove=e.createSelection(s[0])),"deleteContentBackward"===l&&(r.isAndroid&&(d.sequence=1),function(e){if(1!=e.length||e[0].isCollapsed)return!1;const t=e[0].getWalker({direction:"backward",singleCharacters:!0,ignoreElementEnd:!0});let o=0;for(const{nextPosition:e,item:n}of t){if(e.parent.is("$text")){const t=e.parent.data,n=e.offset;if(nr(t,n)||ir(t,n)||sr(t,n))continue;o++}else(n.is("containerElement")||n.is("emptyElement"))&&o++;if(o>1)return!0}return!1}(s)&&(d.unit=lw,d.selectionToRemove=e.createSelection(s)));const u=new Ms(t,"delete",s[0]);t.fire(u,new Na(e,a,d)),u.stop.called&&n.stop()})),r.isBlink&&function(e){const t=e.view,o=t.document;let n=null,i=!1;function r(e){return e==ki.backspace||e==ki.delete}function s(e){return e==ki.backspace?cw:dw}o.on("keydown",((e,{keyCode:t})=>{n=t,i=!1})),o.on("keyup",((a,{keyCode:l,domEvent:c})=>{const d=o.selection,u=e.isEnabled&&l==n&&r(l)&&!d.isCollapsed&&!i;if(n=null,u){const e=d.getFirstRange(),n=new Ms(o,"delete",e),i={unit:lw,direction:s(l),selectionToRemove:d};o.fire(n,new Na(t,c,i))}})),o.on("beforeinput",((e,{inputType:t})=>{const o=uw[t];r(n)&&o&&o.direction==s(n)&&(i=!0)}),{priority:"high"}),o.on("beforeinput",((e,{inputType:t,data:o})=>{n==ki.delete&&"insertText"==t&&""==o&&e.stop()}),{priority:"high"})}(this)}observe(){}stopObserving(){}}class mw extends lr{static get pluginName(){return"Delete"}init(){const e=this.editor,t=e.editing.view,o=t.document,n=e.model.document;t.addObserver(hw),this._undoOnBackspace=!1;const i=new sw(e,"forward");e.commands.add("deleteForward",i),e.commands.add("forwardDelete",i),e.commands.add("delete",new sw(e,"backward")),this.listenTo(o,"delete",((n,i)=>{o.isComposing||i.preventDefault();const{direction:r,sequence:s,selectionToRemove:a,unit:l}=i,c="forward"===r?"deleteForward":"delete",d={sequence:s};if("selection"==l){const t=Array.from(a.getRanges()).map((t=>e.editing.mapper.toModelRange(t)));d.selection=e.model.createSelection(t)}else d.unit=l;e.execute(c,d),t.scrollToTheSelection()}),{priority:"low"}),this.editor.plugins.has("UndoEditing")&&(this.listenTo(o,"delete",((t,o)=>{this._undoOnBackspace&&"backward"==o.direction&&1==o.sequence&&"codePoint"==o.unit&&(this._undoOnBackspace=!1,e.execute("undo"),o.preventDefault(),t.stop())}),{context:"$capture"}),this.listenTo(n,"change",(()=>{this._undoOnBackspace=!1})))}requestUndoOnBackspace(){this.editor.plugins.has("UndoEditing")&&(this._undoOnBackspace=!0)}}class pw extends lr{static get requires(){return[ow,mw]}static get pluginName(){return"Typing"}}function gw(e,t){let o=e.start;return{text:Array.from(e.getWalker({ignoreElementEnd:!1})).reduce(((e,{item:n})=>n.is("$text")||n.is("$textProxy")?e+n.data:(o=t.createPositionAfter(n),"")),""),range:t.createRange(o,e.end)}}class fw extends(Y()){constructor(e,t){super(),this.model=e,this.testCallback=t,this._hasMatch=!1,this.set("isEnabled",!0),this.on("change:isEnabled",(()=>{this.isEnabled?this._startListening():(this.stopListening(e.document.selection),this.stopListening(e.document))})),this._startListening()}get hasMatch(){return this._hasMatch}_startListening(){const e=this.model.document;this.listenTo(e.selection,"change:range",((t,{directChange:o})=>{o&&(e.selection.isCollapsed?this._evaluateTextBeforeSelection("selection"):this.hasMatch&&(this.fire("unmatched"),this._hasMatch=!1))})),this.listenTo(e,"change:data",((e,t)=>{!t.isUndo&&t.isLocal&&this._evaluateTextBeforeSelection("data",{batch:t})}))}_evaluateTextBeforeSelection(e,t={}){const o=this.model,n=o.document.selection,i=o.createRange(o.createPositionAt(n.focus.parent,0),n.focus),{text:r,range:s}=gw(i,o),a=this.testCallback(r);if(!a&&this.hasMatch&&this.fire("unmatched"),this._hasMatch=!!a,a){const o=Object.assign(t,{text:r,range:s});"object"==typeof a&&Object.assign(o,a),this.fire(`matched:${e}`,o)}}}class bw extends lr{static get pluginName(){return"TwoStepCaretMovement"}constructor(e){super(e),this._isNextGravityRestorationSkipped=!1,this.attributes=new Set,this._overrideUid=null}init(){const e=this.editor,t=e.model,o=e.editing.view,n=e.locale,i=t.document.selection;this.listenTo(o.document,"arrowKey",((e,t)=>{if(!i.isCollapsed)return;if(t.shiftKey||t.altKey||t.ctrlKey)return;const o=t.keyCode==ki.arrowright,r=t.keyCode==ki.arrowleft;if(!o&&!r)return;const s=n.contentLanguageDirection;let a=!1;a="ltr"===s&&o||"rtl"===s&&r?this._handleForwardMovement(t):this._handleBackwardMovement(t),!0===a&&e.stop()}),{context:"$text",priority:"highest"}),this.listenTo(i,"change:range",((e,t)=>{this._isNextGravityRestorationSkipped?this._isNextGravityRestorationSkipped=!1:this._isGravityOverridden&&(!t.directChange&&Cw(i.getFirstPosition(),this.attributes)||this._restoreGravity())})),this._enableClickingAfterNode(),this._enableInsertContentSelectionAttributesFixer(),this._handleDeleteContentAfterNode()}registerAttribute(e){this.attributes.add(e)}_handleForwardMovement(e){const t=this.attributes,o=this.editor.model,n=o.document.selection,i=n.getFirstPosition();return!this._isGravityOverridden&&((!i.isAtStart||!kw(n,t))&&(!!Cw(i,t)&&(yw(e),kw(n,t)&&Cw(i,t,!0)?_w(o,t):this._overrideGravity(),!0)))}_handleBackwardMovement(e){const t=this.attributes,o=this.editor.model,n=o.document.selection,i=n.getFirstPosition();return this._isGravityOverridden?(yw(e),this._restoreGravity(),Cw(i,t,!0)?_w(o,t):ww(o,t,i),!0):i.isAtStart?!!kw(n,t)&&(yw(e),ww(o,t,i),!0):!kw(n,t)&&Cw(i,t,!0)?(yw(e),ww(o,t,i),!0):!!Aw(i,t)&&(i.isAtEnd&&!kw(n,t)&&Cw(i,t)?(yw(e),ww(o,t,i),!0):(this._isNextGravityRestorationSkipped=!0,this._overrideGravity(),!1))}_enableClickingAfterNode(){const e=this.editor,t=e.model,o=t.document.selection,n=e.editing.view.document;e.editing.view.addObserver(Nu);let i=!1;this.listenTo(n,"mousedown",(()=>{i=!0})),this.listenTo(n,"selectionChange",(()=>{const e=this.attributes;if(!i)return;if(i=!1,!o.isCollapsed)return;if(!kw(o,e))return;const n=o.getFirstPosition();Cw(n,e)&&(n.isAtStart||Cw(n,e,!0)?_w(t,e):this._isGravityOverridden||this._overrideGravity())}))}_enableInsertContentSelectionAttributesFixer(){const e=this.editor.model,t=e.document.selection,o=this.attributes;this.listenTo(e,"insertContent",(()=>{const n=t.getFirstPosition();kw(t,o)&&Cw(n,o)&&_w(e,o)}),{priority:"low"})}_handleDeleteContentAfterNode(){const e=this.editor,t=e.model,o=t.document.selection,n=e.editing.view;let i=!1,r=!1;this.listenTo(n.document,"delete",((e,t)=>{i="backward"===t.direction}),{priority:"high"}),this.listenTo(t,"deleteContent",(()=>{if(!i)return;const e=o.getFirstPosition();r=kw(o,this.attributes)&&!Aw(e,this.attributes)}),{priority:"high"}),this.listenTo(t,"deleteContent",(()=>{i&&(i=!1,r||e.model.enqueueChange((()=>{const e=o.getFirstPosition();kw(o,this.attributes)&&Cw(e,this.attributes)&&(e.isAtStart||Cw(e,this.attributes,!0)?_w(t,this.attributes):this._isGravityOverridden||this._overrideGravity())})))}),{priority:"low"})}get _isGravityOverridden(){return!!this._overrideUid}_overrideGravity(){this._overrideUid=this.editor.model.change((e=>e.overrideSelectionGravity()))}_restoreGravity(){this.editor.model.change((e=>{e.restoreSelectionGravity(this._overrideUid),this._overrideUid=null}))}}function kw(e,t){for(const o of t)if(e.hasAttribute(o))return!0;return!1}function ww(e,t,o){const n=o.nodeBefore;e.change((o=>{if(n){const t=[],i=e.schema.isObject(n)&&e.schema.isInline(n);for(const[o,r]of n.getAttributes())!e.schema.checkAttribute("$text",o)||i&&!1===e.schema.getAttributeProperties(o).copyFromObject||t.push([o,r]);o.setSelectionAttribute(t)}else o.removeSelectionAttribute(t)}))}function _w(e,t){e.change((e=>{e.removeSelectionAttribute(t)}))}function yw(e){e.preventDefault()}function Aw(e,t){return Cw(e.getShiftedBy(-1),t)}function Cw(e,t,o=!1){const{nodeBefore:n,nodeAfter:i}=e;for(const e of t){const t=n?n.getAttribute(e):void 0,r=i?i.getAttribute(e):void 0;if((!o||void 0!==t&&void 0!==r)&&r!==t)return!0}return!1}vw('"'),vw("'"),vw("'"),vw('"'),vw('"'),vw("'");function vw(e){return new RegExp(`(^|\\s)(${e})([^${e}]*)(${e})$`)}function xw(e,t,o,n){return n.createRange(Ew(e,t,o,!0,n),Ew(e,t,o,!1,n))}function Ew(e,t,o,n,i){let r=e.textNode||(n?e.nodeBefore:e.nodeAfter),s=null;for(;r&&r.getAttribute(t)==o;)s=r,r=n?r.previousSibling:r.nextSibling;return s?i.createPositionAt(s,n?"before":"after"):e}function Dw(e,t,o,n){const i=e.editing.view,r=new Set;i.document.registerPostFixer((i=>{const s=e.model.document.selection;let a=!1;if(s.hasAttribute(t)){const l=xw(s.getFirstPosition(),t,s.getAttribute(t),e.model),c=e.editing.mapper.toViewRange(l);for(const e of c.getItems())e.is("element",o)&&!e.hasClass(n)&&(i.addClass(n,e),r.add(e),a=!0)}return a})),e.conversion.for("editingDowncast").add((e=>{function t(){i.change((e=>{for(const t of r.values())e.removeClass(n,t),r.delete(t)}))}e.on("insert",t,{priority:"highest"}),e.on("remove",t,{priority:"highest"}),e.on("attribute",t,{priority:"highest"}),e.on("selection",t,{priority:"highest"})}))}function*Bw(e,t){for(const o of t)o&&e.getAttributeProperties(o[0]).copyOnEnter&&(yield o)}class Sw extends dr{execute(){this.editor.model.change((e=>{this.enterBlock(e),this.fire("afterExecute",{writer:e})}))}enterBlock(e){const t=this.editor.model,o=t.document.selection,n=t.schema,i=o.isCollapsed,r=o.getFirstRange(),s=r.start.parent,a=r.end.parent;if(n.isLimit(s)||n.isLimit(a))return i||s!=a||t.deleteContent(o),!1;if(i){const t=Bw(e.model.schema,o.getAttributes());return Tw(e,r.start),e.setSelectionAttribute(t),!0}{const n=!(r.start.isAtStart&&r.end.isAtEnd),i=s==a;if(t.deleteContent(o,{leaveUnmerged:n}),n){if(i)return Tw(e,o.focus),!0;e.setSelection(a,0)}}return!1}}function Tw(e,t){e.split(t),e.setSelection(t.parent.nextSibling,0)}const Iw={insertParagraph:{isSoft:!1},insertLineBreak:{isSoft:!0}};class Pw extends za{constructor(e){super(e);const t=this.document;let o=!1;t.on("keydown",((e,t)=>{o=t.shiftKey})),t.on("beforeinput",((n,i)=>{if(!this.isEnabled)return;let s=i.inputType;r.isSafari&&o&&"insertParagraph"==s&&(s="insertLineBreak");const a=i.domEvent,l=Iw[s];if(!l)return;const c=new Ms(t,"enter",i.targetRanges[0]);t.fire(c,new Na(e,a,{isSoft:l.isSoft})),c.stop.called&&n.stop()}))}observe(){}stopObserving(){}}class Fw extends lr{static get pluginName(){return"Enter"}init(){const e=this.editor,t=e.editing.view,o=t.document,n=this.editor.t;t.addObserver(Pw),e.commands.add("enter",new Sw(e)),this.listenTo(o,"enter",((n,i)=>{o.isComposing||i.preventDefault(),i.isSoft||(e.execute("enter"),t.scrollToTheSelection())}),{priority:"low"}),e.accessibility.addKeystrokeInfos({keystrokes:[{label:n("Insert a hard break (a new paragraph)"),keystroke:"Enter"}]})}}class Mw extends dr{execute(){const e=this.editor.model,t=e.document;e.change((o=>{!function(e,t,o){const n=o.isCollapsed,i=o.getFirstRange(),r=i.start.parent,s=i.end.parent,a=r==s;if(n){const n=Bw(e.schema,o.getAttributes());Rw(e,t,i.end),t.removeSelectionAttribute(o.getAttributeKeys()),t.setSelectionAttribute(n)}else{const n=!(i.start.isAtStart&&i.end.isAtEnd);e.deleteContent(o,{leaveUnmerged:n}),a?Rw(e,t,o.focus):n&&t.setSelection(s,0)}}(e,o,t.selection),this.fire("afterExecute",{writer:o})}))}refresh(){const e=this.editor.model,t=e.document;this.isEnabled=function(e,t){if(t.rangeCount>1)return!1;const o=t.anchor;if(!o||!e.checkChild(o,"softBreak"))return!1;const n=t.getFirstRange(),i=n.start.parent,r=n.end.parent;if((zw(i,e)||zw(r,e))&&i!==r)return!1;return!0}(e.schema,t.selection)}}function Rw(e,t,o){const n=t.createElement("softBreak");e.insertContent(n,o),t.setSelection(n,"after")}function zw(e,t){return!e.is("rootElement")&&(t.isLimit(e)||zw(e.parent,t))}class Vw extends lr{static get pluginName(){return"ShiftEnter"}init(){const e=this.editor,t=e.model.schema,o=e.conversion,n=e.editing.view,i=n.document,r=this.editor.t;t.register("softBreak",{allowWhere:"$text",isInline:!0}),o.for("upcast").elementToElement({model:"softBreak",view:"br"}),o.for("downcast").elementToElement({model:"softBreak",view:(e,{writer:t})=>t.createEmptyElement("br")}),n.addObserver(Pw),e.commands.add("shiftEnter",new Mw(e)),this.listenTo(i,"enter",((t,o)=>{i.isComposing||o.preventDefault(),o.isSoft&&(e.execute("shiftEnter"),n.scrollToTheSelection())}),{priority:"low"}),e.accessibility.addKeystrokeInfos({keystrokes:[{label:r("Insert a soft break (a <br> element)"),keystroke:"Shift+Enter"}]})}}var Ow=i(6779),Nw={attributes:{"data-cke":!0}};Nw.setAttributes=Ar(),Nw.insert=_r().bind(null,"head"),Nw.domAPI=kr(),Nw.insertStyleElement=vr();fr()(Ow.A,Nw);Ow.A&&Ow.A.locals&&Ow.A.locals;const Lw=["before","after"],Hw=(new DOMParser).parseFromString('',"image/svg+xml").firstChild,jw="ck-widget__type-around_disabled";class qw extends lr{constructor(){super(...arguments),this._currentFakeCaretModelElement=null}static get pluginName(){return"WidgetTypeAround"}static get requires(){return[Fw,mw]}init(){const e=this.editor,t=e.editing.view;this.on("change:isEnabled",((o,n,i)=>{t.change((e=>{for(const o of t.document.roots)i?e.removeClass(jw,o):e.addClass(jw,o)})),i||e.model.change((e=>{e.removeSelectionAttribute(Sk)}))})),this._enableTypeAroundUIInjection(),this._enableInsertingParagraphsOnButtonClick(),this._enableInsertingParagraphsOnEnterKeypress(),this._enableInsertingParagraphsOnTypingKeystroke(),this._enableTypeAroundFakeCaretActivationUsingKeyboardArrows(),this._enableDeleteIntegration(),this._enableInsertContentIntegration(),this._enableInsertObjectIntegration(),this._enableDeleteContentIntegration()}destroy(){super.destroy(),this._currentFakeCaretModelElement=null}_insertParagraph(e,t){const o=this.editor,n=o.editing.view,i=o.model.schema.getAttributesWithProperty(e,"copyOnReplace",!0);o.execute("insertParagraph",{position:o.model.createPositionAt(e,t),attributes:i}),n.focus(),n.scrollToTheSelection()}_listenToIfEnabled(e,t,o,n){this.listenTo(e,t,((...e)=>{this.isEnabled&&o(...e)}),n)}_insertParagraphAccordingToFakeCaretPosition(){const e=this.editor.model.document.selection,t=Ik(e);if(!t)return!1;const o=e.getSelectedElement();return this._insertParagraph(o,t),!0}_enableTypeAroundUIInjection(){const e=this.editor,t=e.model.schema,o=e.locale.t,n={before:o("Insert paragraph before block"),after:o("Insert paragraph after block")};e.editing.downcastDispatcher.on("insert",((e,i,r)=>{const s=r.mapper.toViewElement(i.item);if(s&&Tk(s,i.item,t)){!function(e,t,o){const n=e.createUIElement("div",{class:"ck ck-reset_all ck-widget__type-around"},(function(e){const o=this.toDomElement(e);return function(e,t){for(const o of Lw){const n=new Wh({tag:"div",attributes:{class:["ck","ck-widget__type-around__button",`ck-widget__type-around__button_${o}`],title:t[o],"aria-hidden":"true"},children:[e.ownerDocument.importNode(Hw,!0)]});e.appendChild(n.render())}}(o,t),function(e){const t=new Wh({tag:"div",attributes:{class:["ck","ck-widget__type-around__fake-caret"]}});e.appendChild(t.render())}(o),o}));e.insert(e.createPositionAt(o,"end"),n)}(r.writer,n,s);s.getCustomProperty("widgetLabel").push((()=>this.isEnabled?o("Press Enter to type after or press Shift + Enter to type before the widget"):""))}}),{priority:"low"})}_enableTypeAroundFakeCaretActivationUsingKeyboardArrows(){const e=this.editor,t=e.model,o=t.document.selection,n=t.schema,i=e.editing.view;function r(e){return`ck-widget_type-around_show-fake-caret_${e}`}this._listenToIfEnabled(i.document,"arrowKey",((e,t)=>{this._handleArrowKeyPress(e,t)}),{context:[Rk,"$text"],priority:"high"}),this._listenToIfEnabled(o,"change:range",((t,o)=>{o.directChange&&e.model.change((e=>{e.removeSelectionAttribute(Sk)}))})),this._listenToIfEnabled(t.document,"change:data",(()=>{const t=o.getSelectedElement();if(t){if(Tk(e.editing.mapper.toViewElement(t),t,n))return}e.model.change((e=>{e.removeSelectionAttribute(Sk)}))})),this._listenToIfEnabled(e.editing.downcastDispatcher,"selection",((e,t,o)=>{const i=o.writer;if(this._currentFakeCaretModelElement){const e=o.mapper.toViewElement(this._currentFakeCaretModelElement);e&&(i.removeClass(Lw.map(r),e),this._currentFakeCaretModelElement=null)}const s=t.selection.getSelectedElement();if(!s)return;const a=o.mapper.toViewElement(s);if(!Tk(a,s,n))return;const l=Ik(t.selection);l&&(i.addClass(r(l),a),this._currentFakeCaretModelElement=s)})),this._listenToIfEnabled(e.ui.focusTracker,"change:isFocused",((t,o,n)=>{n||e.model.change((e=>{e.removeSelectionAttribute(Sk)}))}))}_handleArrowKeyPress(e,t){const o=this.editor,n=o.model,i=n.document.selection,r=n.schema,s=o.editing.view,a=function(e,t){const o=Ci(e,t);return"down"===o||"right"===o}(t.keyCode,o.locale.contentLanguageDirection),l=s.document.selection.getSelectedElement();let c;Tk(l,o.editing.mapper.toModelElement(l),r)?c=this._handleArrowKeyPressOnSelectedWidget(a):i.isCollapsed?c=this._handleArrowKeyPressWhenSelectionNextToAWidget(a):t.shiftKey||(c=this._handleArrowKeyPressWhenNonCollapsedSelection(a)),c&&(t.preventDefault(),e.stop())}_handleArrowKeyPressOnSelectedWidget(e){const t=this.editor.model,o=Ik(t.document.selection);return t.change((t=>{if(!o)return t.setSelectionAttribute(Sk,e?"after":"before"),!0;if(!(o===(e?"after":"before")))return t.removeSelectionAttribute(Sk),!0;return!1}))}_handleArrowKeyPressWhenSelectionNextToAWidget(e){const t=this.editor,o=t.model,n=o.schema,i=t.plugins.get("Widget"),r=i._getObjectElementNextToSelection(e);return!!Tk(t.editing.mapper.toViewElement(r),r,n)&&(o.change((t=>{i._setSelectionOverElement(r),t.setSelectionAttribute(Sk,e?"before":"after")})),!0)}_handleArrowKeyPressWhenNonCollapsedSelection(e){const t=this.editor,o=t.model,n=o.schema,i=t.editing.mapper,r=o.document.selection,s=e?r.getLastPosition().nodeBefore:r.getFirstPosition().nodeAfter;return!!Tk(i.toViewElement(s),s,n)&&(o.change((t=>{t.setSelection(s,"on"),t.setSelectionAttribute(Sk,e?"after":"before")})),!0)}_enableInsertingParagraphsOnButtonClick(){const e=this.editor,t=e.editing.view;this._listenToIfEnabled(t.document,"mousedown",((o,n)=>{const i=n.domTarget.closest(".ck-widget__type-around__button");if(!i)return;const r=function(e){return e.classList.contains("ck-widget__type-around__button_before")?"before":"after"}(i),s=function(e,t){const o=e.closest(".ck-widget");return t.mapDomToView(o)}(i,t.domConverter),a=e.editing.mapper.toModelElement(s);this._insertParagraph(a,r),n.preventDefault(),o.stop()}))}_enableInsertingParagraphsOnEnterKeypress(){const e=this.editor,t=e.model.document.selection,o=e.editing.view;this._listenToIfEnabled(o.document,"enter",((o,n)=>{if("atTarget"!=o.eventPhase)return;const i=t.getSelectedElement(),r=e.editing.mapper.toViewElement(i),s=e.model.schema;let a;this._insertParagraphAccordingToFakeCaretPosition()?a=!0:Tk(r,i,s)&&(this._insertParagraph(i,n.isSoft?"before":"after"),a=!0),a&&(n.preventDefault(),o.stop())}),{context:Rk})}_enableInsertingParagraphsOnTypingKeystroke(){const e=this.editor.editing.view.document;this._listenToIfEnabled(e,"insertText",((t,o)=>{this._insertParagraphAccordingToFakeCaretPosition()&&(o.selection=e.selection)}),{priority:"high"}),r.isAndroid?this._listenToIfEnabled(e,"keydown",((e,t)=>{229==t.keyCode&&this._insertParagraphAccordingToFakeCaretPosition()})):this._listenToIfEnabled(e,"compositionstart",(()=>{this._insertParagraphAccordingToFakeCaretPosition()}),{priority:"high"})}_enableDeleteIntegration(){const e=this.editor,t=e.editing.view,o=e.model,n=o.schema;this._listenToIfEnabled(t.document,"delete",((t,i)=>{if("atTarget"!=t.eventPhase)return;const r=Ik(o.document.selection);if(!r)return;const s=i.direction,a=o.document.selection.getSelectedElement(),l="forward"==s;if("before"===r===l)e.execute("delete",{selection:o.createSelection(a,"on")});else{const t=n.getNearestSelectionRange(o.createPositionAt(a,r),s);if(t)if(t.isCollapsed){const i=o.createSelection(t.start);if(o.modifySelection(i,{direction:s}),i.focus.isEqual(t.start)){const e=function(e,t){let o=t;for(const n of t.getAncestors({parentFirst:!0})){if(n.childCount>1||e.isLimit(n))break;o=n}return o}(n,t.start.parent);o.deleteContent(o.createSelection(e,"on"),{doNotAutoparagraph:!0})}else o.change((o=>{o.setSelection(t),e.execute(l?"deleteForward":"delete")}))}else o.change((o=>{o.setSelection(t),e.execute(l?"deleteForward":"delete")}))}i.preventDefault(),t.stop()}),{context:Rk})}_enableInsertContentIntegration(){const e=this.editor,t=this.editor.model,o=t.document.selection;this._listenToIfEnabled(e.model,"insertContent",((e,[n,i])=>{if(i&&!i.is("documentSelection"))return;const r=Ik(o);return r?(e.stop(),t.change((e=>{const i=o.getSelectedElement(),s=t.createPositionAt(i,r),a=e.createSelection(s),l=t.insertContent(n,a);return e.setSelection(a),l}))):void 0}),{priority:"high"})}_enableInsertObjectIntegration(){const e=this.editor,t=this.editor.model.document.selection;this._listenToIfEnabled(e.model,"insertObject",((e,o)=>{const[,n,i={}]=o;if(n&&!n.is("documentSelection"))return;const r=Ik(t);r&&(i.findOptimalPosition=r,o[3]=i)}),{priority:"high"})}_enableDeleteContentIntegration(){const e=this.editor,t=this.editor.model.document.selection;this._listenToIfEnabled(e.model,"deleteContent",((e,[o])=>{if(o&&!o.is("documentSelection"))return;Ik(t)&&e.stop()}),{priority:"high"})}}function Uw(e){const t=e.model;return(o,n)=>{const i=n.keyCode==ki.arrowup,r=n.keyCode==ki.arrowdown,s=n.shiftKey,a=t.document.selection;if(!i&&!r)return;const l=r;if(s&&function(e,t){return!e.isCollapsed&&e.isBackward==t}(a,l))return;const c=function(e,t,o){const n=e.model;if(o){const e=t.isCollapsed?t.focus:t.getLastPosition(),o=Ww(n,e,"forward");if(!o)return null;const i=n.createRange(e,o),r=$w(n.schema,i,"backward");return r?n.createRange(e,r):null}{const e=t.isCollapsed?t.focus:t.getFirstPosition(),o=Ww(n,e,"backward");if(!o)return null;const i=n.createRange(o,e),r=$w(n.schema,i,"forward");return r?n.createRange(r,e):null}}(e,a,l);if(c){if(c.isCollapsed){if(a.isCollapsed)return;if(s)return}(c.isCollapsed||function(e,t,o){const n=e.model,i=e.view.domConverter;if(o){const e=n.createSelection(t.start);n.modifySelection(e),e.focus.isAtEnd||t.start.isEqual(e.focus)||(t=n.createRange(e.focus,t.end))}const r=e.mapper.toViewRange(t),s=i.viewRangeToDom(r),a=qn.getDomRangeRects(s);let l;for(const e of a)if(void 0!==l){if(Math.round(e.top)>=l)return!1;l=Math.max(l,Math.round(e.bottom))}else l=Math.round(e.bottom);return!0}(e,c,l))&&(t.change((e=>{const o=l?c.end:c.start;if(s){const n=t.createSelection(a.anchor);n.setFocus(o),e.setSelection(n)}else e.setSelection(o)})),o.stop(),n.preventDefault(),n.stopPropagation())}}}function Ww(e,t,o){const n=e.schema,i=e.createRangeIn(t.root),r="forward"==o?"elementStart":"elementEnd";for(const{previousPosition:e,item:s,type:a}of i.getWalker({startPosition:t,direction:o})){if(n.isLimit(s)&&!n.isInline(s))return e;if(a==r&&n.isBlock(s))return null}return null}function $w(e,t,o){const n="backward"==o?t.end:t.start;if(e.checkChild(n,"$text"))return n;for(const{nextPosition:n}of t.getWalker({direction:o}))if(e.checkChild(n,"$text"))return n;return null}var Gw=i(1216),Kw={attributes:{"data-cke":!0}};Kw.setAttributes=Ar(),Kw.insert=_r().bind(null,"head"),Kw.domAPI=kr(),Kw.insertStyleElement=vr();fr()(Gw.A,Kw);Gw.A&&Gw.A.locals&&Gw.A.locals;class Zw extends lr{constructor(){super(...arguments),this._previouslySelected=new Set}static get pluginName(){return"Widget"}static get requires(){return[qw,mw]}init(){const e=this.editor,t=e.editing.view,o=t.document,n=e.t;this.editor.editing.downcastDispatcher.on("selection",((t,o,n)=>{const i=n.writer,r=o.selection;if(r.isCollapsed)return;const s=r.getSelectedElement();if(!s)return;const a=e.editing.mapper.toViewElement(s);var l;Rk(a)&&(n.consumable.consume(r,"selection")&&i.setSelection(i.createRangeOn(a),{fake:!0,label:(l=a,l.getCustomProperty("widgetLabel").reduce(((e,t)=>"function"==typeof t?e?e+". "+t():t():e?e+". "+t:t),""))}))})),this.editor.editing.downcastDispatcher.on("selection",((e,t,o)=>{this._clearPreviouslySelectedWidgets(o.writer);const n=o.writer,i=n.document.selection;let r=null;for(const e of i.getRanges())for(const t of e){const e=t.item;Rk(e)&&!Jw(e,r)&&(n.addClass(Mk,e),this._previouslySelected.add(e),r=e)}}),{priority:"low"}),t.addObserver(Nu),this.listenTo(o,"mousedown",((...e)=>this._onMousedown(...e))),this.listenTo(o,"arrowKey",((...e)=>{this._handleSelectionChangeOnArrowKeyPress(...e)}),{context:[Rk,"$text"]}),this.listenTo(o,"arrowKey",((...e)=>{this._preventDefaultOnArrowKeyPress(...e)}),{context:"$root"}),this.listenTo(o,"arrowKey",Uw(this.editor.editing),{context:"$text"}),this.listenTo(o,"delete",((e,t)=>{this._handleDelete("forward"==t.direction)&&(t.preventDefault(),e.stop())}),{context:"$root"}),this.listenTo(o,"tab",((e,t)=>{"atTarget"==e.eventPhase&&(t.shiftKey||this._selectFirstNestedEditable()&&(t.preventDefault(),e.stop()))}),{context:Rk,priority:"low"}),this.listenTo(o,"tab",((e,t)=>{t.shiftKey&&this._selectAncestorWidget()&&(t.preventDefault(),e.stop())}),{priority:"low"}),this.listenTo(o,"keydown",((e,t)=>{t.keystroke==ki.esc&&this._selectAncestorWidget()&&(t.preventDefault(),e.stop())}),{priority:"low"}),e.accessibility.addKeystrokeInfoGroup({id:"widget",label:n("Keystrokes that can be used when a widget is selected (for example: image, table, etc.)"),keystrokes:[{label:n("Move focus from an editable area back to the parent widget"),keystroke:"Esc"},{label:n("Insert a new paragraph directly after a widget"),keystroke:"Enter"},{label:n("Insert a new paragraph directly before a widget"),keystroke:"Shift+Enter"},{label:n("Move the caret to allow typing directly before a widget"),keystroke:[["arrowup"],["arrowleft"]]},{label:n("Move the caret to allow typing directly after a widget"),keystroke:[["arrowdown"],["arrowright"]]}]})}_onMousedown(e,t){const o=this.editor,n=o.editing.view,i=n.document;let s=t.target;if(t.domEvent.detail>=3)return void(this._selectBlockContent(s)&&t.preventDefault());if(function(e){let t=e;for(;t;){if(t.is("editableElement")&&!t.is("rootElement"))return!0;if(Rk(t))return!1;t=t.parent}return!1}(s))return;if(!Rk(s)&&(s=s.findAncestor(Rk),!s))return;r.isAndroid&&t.preventDefault(),i.isFocused||n.focus();const a=o.editing.mapper.toModelElement(s);this._setSelectionOverElement(a)}_selectBlockContent(e){const t=this.editor,o=t.model,n=t.editing.mapper,i=o.schema,r=n.findMappedViewAncestor(this.editor.editing.view.createPositionAt(e,0)),s=function(e,t){for(const o of e.getAncestors({includeSelf:!0,parentFirst:!0})){if(t.checkChild(o,"$text"))return o;if(t.isLimit(o)&&!t.isObject(o))break}return null}(n.toModelElement(r),o.schema);return!!s&&(o.change((e=>{const t=i.isLimit(s)?null:function(e,t){const o=new Hl({startPosition:e});for(const{item:e}of o){if(t.isLimit(e)||!e.is("element"))return null;if(t.checkChild(e,"$text"))return e}return null}(e.createPositionAfter(s),i),o=e.createPositionAt(s,0),n=t?e.createPositionAt(t,0):e.createPositionAt(s,"end");e.setSelection(e.createRange(o,n))})),!0)}_handleSelectionChangeOnArrowKeyPress(e,t){const o=t.keyCode,n=this.editor.model,i=n.schema,r=n.document.selection,s=r.getSelectedElement(),a=Ci(o,this.editor.locale.contentLanguageDirection),l="down"==a||"right"==a,c="up"==a||"down"==a;if(s&&i.isObject(s)){const o=l?r.getLastPosition():r.getFirstPosition(),s=i.getNearestSelectionRange(o,l?"forward":"backward");return void(s&&(n.change((e=>{e.setSelection(s)})),t.preventDefault(),e.stop()))}if(!r.isCollapsed&&!t.shiftKey){const o=r.getFirstPosition(),s=r.getLastPosition(),a=o.nodeAfter,c=s.nodeBefore;return void((a&&i.isObject(a)||c&&i.isObject(c))&&(n.change((e=>{e.setSelection(l?s:o)})),t.preventDefault(),e.stop()))}if(!r.isCollapsed)return;const d=this._getObjectElementNextToSelection(l);if(d&&i.isObject(d)){if(i.isInline(d)&&c)return;this._setSelectionOverElement(d),t.preventDefault(),e.stop()}}_preventDefaultOnArrowKeyPress(e,t){const o=this.editor.model,n=o.schema,i=o.document.selection.getSelectedElement();i&&n.isObject(i)&&(t.preventDefault(),e.stop())}_handleDelete(e){const t=this.editor.model.document.selection;if(!this.editor.model.canEditAt(t))return;if(!t.isCollapsed)return;const o=this._getObjectElementNextToSelection(e);return o?(this.editor.model.change((e=>{let n=t.anchor.parent;for(;n.isEmpty;){const t=n;n=t.parent,e.remove(t)}this._setSelectionOverElement(o)})),!0):void 0}_setSelectionOverElement(e){this.editor.model.change((t=>{t.setSelection(t.createRangeOn(e))}))}_getObjectElementNextToSelection(e){const t=this.editor.model,o=t.schema,n=t.document.selection,i=t.createSelection(n);if(t.modifySelection(i,{direction:e?"forward":"backward"}),i.isEqual(n))return null;const r=e?i.focus.nodeBefore:i.focus.nodeAfter;return r&&o.isObject(r)?r:null}_clearPreviouslySelectedWidgets(e){for(const t of this._previouslySelected)e.removeClass(Mk,t);this._previouslySelected.clear()}_selectFirstNestedEditable(){const e=this.editor,t=this.editor.editing.view.document;for(const o of t.selection.getFirstRange().getItems())if(o.is("editableElement")){const t=e.editing.mapper.toModelElement(o);if(!t)continue;const n=e.model.createPositionAt(t,0),i=e.model.schema.getNearestSelectionRange(n,"forward");return e.model.change((e=>{e.setSelection(i)})),!0}return!1}_selectAncestorWidget(){const e=this.editor,t=e.editing.mapper,o=e.editing.view.document.selection.getFirstPosition().parent,n=(o.is("$text")?o.parent:o).findAncestor(Rk);if(!n)return!1;const i=t.toModelElement(n);return!!i&&(e.model.change((e=>{e.setSelection(i,"on")})),!0)}}function Jw(e,t){return!!t&&Array.from(e.getAncestors()).includes(t)}class Yw extends lr{constructor(){super(...arguments),this._toolbarDefinitions=new Map}static get requires(){return[Fb]}static get pluginName(){return"WidgetToolbarRepository"}init(){const e=this.editor;if(e.plugins.has("BalloonToolbar")){const t=e.plugins.get("BalloonToolbar");this.listenTo(t,"show",(t=>{(function(e){const t=e.getSelectedElement();return!(!t||!Rk(t))})(e.editing.view.document.selection)&&t.stop()}),{priority:"high"})}this._balloon=this.editor.plugins.get("ContextualBalloon"),this.on("change:isEnabled",(()=>{this._updateToolbarsVisibility()})),this.listenTo(e.ui,"update",(()=>{this._updateToolbarsVisibility()})),this.listenTo(e.ui.focusTracker,"change:isFocused",(()=>{this._updateToolbarsVisibility()}),{priority:"low"})}destroy(){super.destroy();for(const e of this._toolbarDefinitions.values())e.view.destroy()}register(e,{ariaLabel:t,items:o,getRelatedElement:n,balloonClassName:i="ck-toolbar-container"}){if(!o.length)return void D("widget-toolbar-no-items",{toolbarId:e});const r=this.editor,s=r.t,a=new cg(r.locale);if(a.ariaLabel=t||s("Widget toolbar"),this._toolbarDefinitions.has(e))throw new E("widget-toolbar-duplicated",this,{toolbarId:e});const l={view:a,getRelatedElement:n,balloonClassName:i,itemsConfig:o,initialized:!1};r.ui.addToolbar(a,{isContextual:!0,beforeFocus:()=>{const e=n(r.editing.view.document.selection);e&&this._showToolbar(l,e)},afterBlur:()=>{this._hideToolbar(l)}}),this._toolbarDefinitions.set(e,l)}_updateToolbarsVisibility(){let e=0,t=null,o=null;for(const n of this._toolbarDefinitions.values()){const i=n.getRelatedElement(this.editor.editing.view.document.selection);if(this.isEnabled&&i)if(this.editor.ui.focusTracker.isFocused){const r=i.getAncestors().length;r>e&&(e=r,t=i,o=n)}else this._isToolbarVisible(n)&&this._hideToolbar(n);else this._isToolbarInBalloon(n)&&this._hideToolbar(n)}o&&this._showToolbar(o,t)}_hideToolbar(e){this._balloon.remove(e.view),this.stopListening(this._balloon,"change:visibleView")}_showToolbar(e,t){this._isToolbarVisible(e)?Qw(this.editor,t):this._isToolbarInBalloon(e)||(e.initialized||(e.initialized=!0,e.view.fillFromConfig(e.itemsConfig,this.editor.ui.componentFactory)),this._balloon.add({view:e.view,position:Xw(this.editor,t),balloonClassName:e.balloonClassName}),this.listenTo(this._balloon,"change:visibleView",(()=>{for(const e of this._toolbarDefinitions.values())if(this._isToolbarVisible(e)){const t=e.getRelatedElement(this.editor.editing.view.document.selection);Qw(this.editor,t)}})))}_isToolbarVisible(e){return this._balloon.visibleView===e.view}_isToolbarInBalloon(e){return this._balloon.hasView(e.view)}}function Qw(e,t){const o=e.plugins.get("ContextualBalloon"),n=Xw(e,t);o.updatePosition(n)}function Xw(e,t){const o=e.editing.view,n=Ff.defaultPositions;return{target:o.domConverter.mapViewToDom(t),positions:[n.northArrowSouth,n.northArrowSouthWest,n.northArrowSouthEast,n.southArrowNorth,n.southArrowNorthWest,n.southArrowNorthEast,n.viewportStickyNorth]}}class e_ extends(Y()){constructor(e){super(),this.set("activeHandlePosition",null),this.set("proposedWidthPercents",null),this.set("proposedWidth",null),this.set("proposedHeight",null),this.set("proposedHandleHostWidth",null),this.set("proposedHandleHostHeight",null),this._options=e,this._referenceCoordinates=null}get originalWidth(){return this._originalWidth}get originalHeight(){return this._originalHeight}get originalWidthPercents(){return this._originalWidthPercents}get aspectRatio(){return this._aspectRatio}begin(e,t,o){const n=new qn(t);this.activeHandlePosition=function(e){const t=["top-left","top-right","bottom-right","bottom-left"];for(const o of t)if(e.classList.contains(t_(o)))return o}(e),this._referenceCoordinates=function(e,t){const o=new qn(e),n=t.split("-"),i={x:"right"==n[1]?o.right:o.left,y:"bottom"==n[0]?o.bottom:o.top};return i.x+=e.ownerDocument.defaultView.scrollX,i.y+=e.ownerDocument.defaultView.scrollY,i}(t,function(e){const t=e.split("-"),o={top:"bottom",bottom:"top",left:"right",right:"left"};return`${o[t[0]]}-${o[t[1]]}`}(this.activeHandlePosition)),this._originalWidth=n.width,this._originalHeight=n.height,this._aspectRatio=n.width/n.height;const i=o.style.width;i&&i.match(/^\d+(\.\d*)?%$/)?this._originalWidthPercents=parseFloat(i):this._originalWidthPercents=function(e,t=new qn(e)){const o=jk(e);return o?t.width/o*100:0}(o,n)}update(e){this.proposedWidth=e.width,this.proposedHeight=e.height,this.proposedWidthPercents=e.widthPercents,this.proposedHandleHostWidth=e.handleHostWidth,this.proposedHandleHostHeight=e.handleHostHeight}}function t_(e){return`ck-widget__resizer__handle-${e}`}class o_ extends pm{constructor(){super();const e=this.bindTemplate;this.setTemplate({tag:"div",attributes:{class:["ck","ck-size-view",e.to("_viewPosition",(e=>e?`ck-orientation-${e}`:""))],style:{display:e.if("_isVisible","none",(e=>!e))}},children:[{text:e.to("_label")}]})}_bindToState(e,t){this.bind("_isVisible").to(t,"proposedWidth",t,"proposedHeight",((e,t)=>null!==e&&null!==t)),this.bind("_label").to(t,"proposedHandleHostWidth",t,"proposedHandleHostHeight",t,"proposedWidthPercents",((t,o,n)=>"px"===e.unit?`${t}×${o}`:`${n}%`)),this.bind("_viewPosition").to(t,"activeHandlePosition",t,"proposedHandleHostWidth",t,"proposedHandleHostHeight",((e,t,o)=>t<50||o<50?"above-center":e))}_dismiss(){this.unbind(),this._isVisible=!1}}class n_ extends(Y()){constructor(e){super(),this._viewResizerWrapper=null,this._options=e,this.set("isEnabled",!0),this.set("isSelected",!1),this.bind("isVisible").to(this,"isEnabled",this,"isSelected",((e,t)=>e&&t)),this.decorate("begin"),this.decorate("cancel"),this.decorate("commit"),this.decorate("updateSize"),this.on("commit",(e=>{this.state.proposedWidth||this.state.proposedWidthPercents||(this._cleanup(),e.stop())}),{priority:"high"})}get state(){return this._state}show(){this._options.editor.editing.view.change((e=>{e.removeClass("ck-hidden",this._viewResizerWrapper)}))}hide(){this._options.editor.editing.view.change((e=>{e.addClass("ck-hidden",this._viewResizerWrapper)}))}attach(){const e=this,t=this._options.viewElement;this._options.editor.editing.view.change((o=>{const n=o.createUIElement("div",{class:"ck ck-reset_all ck-widget__resizer"},(function(t){const o=this.toDomElement(t);return e._appendHandles(o),e._appendSizeUI(o),o}));o.insert(o.createPositionAt(t,"end"),n),o.addClass("ck-widget_with-resizer",t),this._viewResizerWrapper=n,this.isVisible||this.hide()})),this.on("change:isVisible",(()=>{this.isVisible?(this.show(),this.redraw()):this.hide()}))}begin(e){this._state=new e_(this._options),this._sizeView._bindToState(this._options,this.state),this._initialViewWidth=this._options.viewElement.getStyle("width"),this.state.begin(e,this._getHandleHost(),this._getResizeHost())}updateSize(e){const t=this._proposeNewSize(e);this._options.editor.editing.view.change((e=>{const o=this._options.unit||"%",n=("%"===o?t.widthPercents:t.width)+o;e.setStyle("width",n,this._options.viewElement)}));const o=this._getHandleHost(),n=new qn(o),i=Math.round(n.width),r=Math.round(n.height),s=new qn(o);t.width=Math.round(s.width),t.height=Math.round(s.height),this.redraw(n),this.state.update({...t,handleHostWidth:i,handleHostHeight:r})}commit(){const e=this._options.unit||"%",t=("%"===e?this.state.proposedWidthPercents:this.state.proposedWidth)+e;this._options.editor.editing.view.change((()=>{this._cleanup(),this._options.onCommit(t)}))}cancel(){this._cleanup()}destroy(){this.cancel()}redraw(e){const t=this._domResizerWrapper;if(!((o=t)&&o.ownerDocument&&o.ownerDocument.contains(o)))return;var o;const n=t.parentElement,i=this._getHandleHost(),r=this._viewResizerWrapper,s=[r.getStyle("width"),r.getStyle("height"),r.getStyle("left"),r.getStyle("top")];let a;if(n.isSameNode(i)){const t=e||new qn(i);a=[t.width+"px",t.height+"px",void 0,void 0]}else a=[i.offsetWidth+"px",i.offsetHeight+"px",i.offsetLeft+"px",i.offsetTop+"px"];"same"!==ie(s,a)&&this._options.editor.editing.view.change((e=>{e.setStyle({width:a[0],height:a[1],left:a[2],top:a[3]},r)}))}containsHandle(e){return this._domResizerWrapper.contains(e)}static isResizeHandle(e){return e.classList.contains("ck-widget__resizer__handle")}_cleanup(){this._sizeView._dismiss();this._options.editor.editing.view.change((e=>{e.setStyle("width",this._initialViewWidth,this._options.viewElement)}))}_proposeNewSize(e){const t=this.state,o={x:(n=e).pageX,y:n.pageY};var n;const i=!this._options.isCentered||this._options.isCentered(this),r={x:t._referenceCoordinates.x-(o.x+t.originalWidth),y:o.y-t.originalHeight-t._referenceCoordinates.y};i&&t.activeHandlePosition.endsWith("-right")&&(r.x=o.x-(t._referenceCoordinates.x+t.originalWidth)),i&&(r.x*=2);let s=Math.abs(t.originalWidth+r.x),a=Math.abs(t.originalHeight+r.y);return"width"==(s/t.aspectRatio>a?"width":"height")?a=s/t.aspectRatio:s=a*t.aspectRatio,{width:Math.round(s),height:Math.round(a),widthPercents:Math.min(Math.round(t.originalWidthPercents/t.originalWidth*s*100)/100,100)}}_getResizeHost(){const e=this._domResizerWrapper.parentElement;return this._options.getResizeHost(e)}_getHandleHost(){const e=this._domResizerWrapper.parentElement;return this._options.getHandleHost(e)}get _domResizerWrapper(){return this._options.editor.editing.view.domConverter.mapViewToDom(this._viewResizerWrapper)}_appendHandles(e){const t=["top-left","top-right","bottom-right","bottom-left"];for(const n of t)e.appendChild(new Wh({tag:"div",attributes:{class:"ck-widget__resizer__handle "+(o=n,`ck-widget__resizer__handle-${o}`)}}).render());var o}_appendSizeUI(e){this._sizeView=new o_,this._sizeView.render(),e.appendChild(this._sizeView.element)}}var i_=i(2060),r_={attributes:{"data-cke":!0}};r_.setAttributes=Ar(),r_.insert=_r().bind(null,"head"),r_.domAPI=kr(),r_.insertStyleElement=vr();fr()(i_.A,r_);i_.A&&i_.A.locals&&i_.A.locals;class s_ extends lr{constructor(){super(...arguments),this._resizers=new Map}static get pluginName(){return"WidgetResize"}init(){const e=this.editor.editing,o=t.window.document;this.set("selectedResizer",null),this.set("_activeResizer",null),e.view.addObserver(Nu),this._observer=new(Rn()),this.listenTo(e.view.document,"mousedown",this._mouseDownListener.bind(this),{priority:"high"}),this._observer.listenTo(o,"mousemove",this._mouseMoveListener.bind(this)),this._observer.listenTo(o,"mouseup",this._mouseUpListener.bind(this)),this._redrawSelectedResizerThrottled=Bh((()=>this.redrawSelectedResizer()),200),this.editor.ui.on("update",this._redrawSelectedResizerThrottled),this.editor.model.document.on("change",(()=>{for(const[e,t]of this._resizers)e.isAttached()||(this._resizers.delete(e),t.destroy())}),{priority:"lowest"}),this._observer.listenTo(t.window,"resize",this._redrawSelectedResizerThrottled);const n=this.editor.editing.view.document.selection;n.on("change",(()=>{const e=n.getSelectedElement(),t=this.getResizerByViewElement(e)||null;t?this.select(t):this.deselect()}))}redrawSelectedResizer(){this.selectedResizer&&this.selectedResizer.isVisible&&this.selectedResizer.redraw()}destroy(){super.destroy(),this._observer.stopListening();for(const e of this._resizers.values())e.destroy();this._redrawSelectedResizerThrottled.cancel()}select(e){this.deselect(),this.selectedResizer=e,this.selectedResizer.isSelected=!0}deselect(){this.selectedResizer&&(this.selectedResizer.isSelected=!1),this.selectedResizer=null}attachTo(e){const t=new n_(e),o=this.editor.plugins;if(t.attach(),o.has("WidgetToolbarRepository")){const e=o.get("WidgetToolbarRepository");t.on("begin",(()=>{e.forceDisabled("resize")}),{priority:"lowest"}),t.on("cancel",(()=>{e.clearForceDisabled("resize")}),{priority:"highest"}),t.on("commit",(()=>{e.clearForceDisabled("resize")}),{priority:"highest"})}this._resizers.set(e.viewElement,t);const n=this.editor.editing.view.document.selection.getSelectedElement();return this.getResizerByViewElement(n)==t&&this.select(t),t}getResizerByViewElement(e){return this._resizers.get(e)}_getResizerByHandle(e){for(const t of this._resizers.values())if(t.containsHandle(e))return t}_mouseDownListener(e,t){const o=t.domTarget;n_.isResizeHandle(o)&&(this._activeResizer=this._getResizerByHandle(o)||null,this._activeResizer&&(this._activeResizer.begin(o),e.stop(),t.preventDefault()))}_mouseMoveListener(e,t){this._activeResizer&&this._activeResizer.updateSize(t)}_mouseUpListener(){this._activeResizer&&(this._activeResizer.commit(),this._activeResizer=null)}}function a_(e,t,o){e.ui.componentFactory.add(t,(t=>{const n=new Em(t);return n.set({label:I18n.t("js.button_edit"),icon:'\n',tooltip:!0}),n.on("execute",(()=>{const t=e.model.document.selection.getSelectedElement();t&&o(t)})),n}))}const l_="ck-toolbar-container";function c_(e,t,o,n){const i=t.config.get(o+".toolbar");if(!i||!i.length)return;const r=t.plugins.get("ContextualBalloon"),s=new cg(t.locale);function a(){t.ui.focusTracker.isFocused&&n(t.editing.view.document.selection)?c()?function(e,t){const o=e.plugins.get("ContextualBalloon");if(t(e.editing.view.document.selection)){const t=d_(e);o.updatePosition(t)}}(t,n):r.hasView(s)||r.add({view:s,position:d_(t),balloonClassName:l_}):l()}function l(){c()&&r.remove(s)}function c(){return r.visibleView==s}s.fillFromConfig(i,t.ui.componentFactory),e.listenTo(t.editing.view,"render",a),e.listenTo(t.ui.focusTracker,"change:isFocused",a,{priority:"low"})}function d_(e){const t=e.editing.view,o=Ff.defaultPositions;return{target:t.domConverter.viewToDom(t.document.selection.getSelectedElement()),positions:[o.northArrowSouth,o.northArrowSouthWest,o.northArrowSouthEast,o.southArrowNorth,o.southArrowNorthWest,o.southArrowNorthEast]}}class u_ extends lr{static get requires(){return[Fb]}static get pluginName(){return"EmbeddedTableToolbar"}init(){const e=this.editor,t=this.editor.model,o=Gk(e);a_(e,"opEditEmbeddedTableQuery",(e=>{const n=o.services.externalQueryConfiguration,i=e.getAttribute("opEmbeddedTableQuery")||{};o.runInZone((()=>{n.show({currentQuery:i,callback:o=>t.change((t=>{t.setAttribute("opEmbeddedTableQuery",o,e)}))})}))}))}afterInit(){c_(this,this.editor,"OPMacroEmbeddedTable",Wk)}}const h_=Symbol("isWpButtonMacroSymbol");function m_(e){const t=e.getSelectedElement();return!(!t||!function(e){return!!e.getCustomProperty(h_)&&Rk(e)}(t))}class p_ extends lr{static get pluginName(){return"OPMacroWpButtonEditing"}static get buttonName(){return"insertWorkPackageButton"}init(){const e=this.editor,t=e.model,o=e.conversion,n=Gk(e);t.schema.register("op-macro-wp-button",{allowWhere:["$block"],allowAttributes:["type","classes"],isBlock:!0,isLimit:!0}),o.for("upcast").elementToElement({view:{name:"macro",classes:"create_work_package_link"},model:(e,{writer:t})=>{const o=e.getAttribute("data-type")||"",n=e.getAttribute("data-classes")||"";return t.createElement("op-macro-wp-button",{type:o,classes:n})}}),o.for("editingDowncast").elementToElement({model:"op-macro-wp-button",view:(e,{writer:t})=>this.createMacroViewElement(e,t)}),o.for("dataDowncast").elementToElement({model:"op-macro-wp-button",view:(e,{writer:t})=>t.createContainerElement("macro",{class:"create_work_package_link","data-type":e.getAttribute("type")||"","data-classes":e.getAttribute("classes")||""})}),e.ui.componentFactory.add(p_.buttonName,(t=>{const o=new Em(t);return o.set({label:window.I18n.t("js.editor.macro.work_package_button.button"),withText:!0}),o.on("execute",(()=>{n.services.macros.configureWorkPackageButton().then((t=>e.model.change((o=>{const n=o.createElement("op-macro-wp-button",{});o.setAttribute("type",t.type,n),o.setAttribute("classes",t.classes,n),e.model.insertContent(n,e.model.document.selection)}))))})),o}))}macroLabel(e){return e?window.I18n.t("js.editor.macro.work_package_button.with_type",{typename:e}):window.I18n.t("js.editor.macro.work_package_button.without_type")}createMacroViewElement(e,t){e.getAttribute("type");const o=e.getAttribute("classes")||"",n=this.macroLabel(),i=t.createText(n),r=t.createContainerElement("span",{class:o});return t.insert(t.createPositionAt(r,0),i),function(e,t,o){return t.setCustomProperty(h_,!0,e),zk(e,t,{label:o})}(r,t,{label:n})}}class g_ extends lr{static get requires(){return[Fb]}static get pluginName(){return"OPMacroWpButtonToolbar"}init(){const e=this.editor,t=(this.editor.model,Gk(e));a_(e,"opEditWpMacroButton",(o=>{const n=t.services.macros,i=o.getAttribute("type"),r=o.getAttribute("classes");n.configureWorkPackageButton(i,r).then((t=>e.model.change((e=>{e.setAttribute("classes",t.classes,o),e.setAttribute("type",t.type,o)}))))}))}afterInit(){c_(this,this.editor,"OPMacroWpButton",m_)}}class f_ extends(Y()){constructor(){super();const e=new window.FileReader;this._reader=e,this._data=void 0,this.set("loaded",0),e.onprogress=e=>{this.loaded=e.loaded}}get error(){return this._reader.error}get data(){return this._data}read(e){const t=this._reader;return this.total=e.size,new Promise(((o,n)=>{t.onload=()=>{const e=t.result;this._data=e,o(e)},t.onerror=()=>{n("error")},t.onabort=()=>{n("aborted")},this._reader.readAsDataURL(e)}))}abort(){this._reader.abort()}}class b_ extends lr{constructor(){super(...arguments),this.loaders=new Yi,this._loadersMap=new Map,this._pendingAction=null}static get pluginName(){return"FileRepository"}static get requires(){return[jh]}init(){this.loaders.on("change",(()=>this._updatePendingAction())),this.set("uploaded",0),this.set("uploadTotal",null),this.bind("uploadedPercent").to(this,"uploaded",this,"uploadTotal",((e,t)=>t?e/t*100:0))}getLoader(e){return this._loadersMap.get(e)||null}createLoader(e){if(!this.createUploadAdapter)return D("filerepository-no-upload-adapter"),null;const t=new k_(Promise.resolve(e),this.createUploadAdapter);return this.loaders.add(t),this._loadersMap.set(e,t),e instanceof Promise&&t.file.then((e=>{this._loadersMap.set(e,t)})).catch((()=>{})),t.on("change:uploaded",(()=>{let e=0;for(const t of this.loaders)e+=t.uploaded;this.uploaded=e})),t.on("change:uploadTotal",(()=>{let e=0;for(const t of this.loaders)t.uploadTotal&&(e+=t.uploadTotal);this.uploadTotal=e})),t}destroyLoader(e){const t=e instanceof k_?e:this.getLoader(e);t._destroy(),this.loaders.remove(t),this._loadersMap.forEach(((e,o)=>{e===t&&this._loadersMap.delete(o)}))}_updatePendingAction(){const e=this.editor.plugins.get(jh);if(this.loaders.length){if(!this._pendingAction){const t=this.editor.t,o=e=>`${t("Upload in progress")} ${parseInt(e)}%.`;this._pendingAction=e.add(o(this.uploadedPercent)),this._pendingAction.bind("message").to(this,"uploadedPercent",o)}}else e.remove(this._pendingAction),this._pendingAction=null}}class k_ extends(Y()){constructor(e,t){super(),this.id=A(),this._filePromiseWrapper=this._createFilePromiseWrapper(e),this._adapter=t(this),this._reader=new f_,this.set("status","idle"),this.set("uploaded",0),this.set("uploadTotal",null),this.bind("uploadedPercent").to(this,"uploaded",this,"uploadTotal",((e,t)=>t?e/t*100:0)),this.set("uploadResponse",null)}get file(){return this._filePromiseWrapper?this._filePromiseWrapper.promise.then((e=>this._filePromiseWrapper?e:null)):Promise.resolve(null)}get data(){return this._reader.data}read(){if("idle"!=this.status)throw new E("filerepository-read-wrong-status",this);return this.status="reading",this.file.then((e=>this._reader.read(e))).then((e=>{if("reading"!==this.status)throw this.status;return this.status="idle",e})).catch((e=>{if("aborted"===e)throw this.status="aborted","aborted";throw this.status="error",this._reader.error?this._reader.error:e}))}upload(){if("idle"!=this.status)throw new E("filerepository-upload-wrong-status",this);return this.status="uploading",this.file.then((()=>this._adapter.upload())).then((e=>(this.uploadResponse=e,this.status="idle",e))).catch((e=>{if("aborted"===this.status)throw"aborted";throw this.status="error",e}))}abort(){const e=this.status;this.status="aborted",this._filePromiseWrapper.isFulfilled?"reading"==e?this._reader.abort():"uploading"==e&&this._adapter.abort&&this._adapter.abort():(this._filePromiseWrapper.promise.catch((()=>{})),this._filePromiseWrapper.rejecter("aborted")),this._destroy()}_destroy(){this._filePromiseWrapper=void 0,this._reader=void 0,this._adapter=void 0,this.uploadResponse=void 0}_createFilePromiseWrapper(e){const t={};return t.promise=new Promise(((o,n)=>{t.rejecter=n,t.isFulfilled=!1,e.then((e=>{t.isFulfilled=!0,o(e)})).catch((e=>{t.isFulfilled=!0,n(e)}))})),t}}class w_{constructor(e,t,o){this.loader=e,this.resource=t,this.editor=o}upload(){const e=this.resource,t=Kk(this.editor,"attachmentsResourceService");return e?this.loader.file.then((o=>t.attachFiles(e,[o]).toPromise().then((e=>(this.editor.model.fire("op:attachment-added",e),this.buildResponse(e[0])))).catch((e=>{console.error("Failed upload %O",e)})))):(console.warn("resource not available in this CKEditor instance"),Promise.reject("Not possible to upload attachments without resource"))}buildResponse(e){return{default:e._links.staticDownloadLocation.href}}abort(){return!1}}class __ extends La{constructor(e){super(e),this.domEventType=["paste","copy","cut","drop","dragover","dragstart","dragend","dragenter","dragleave"];const t=this.document;function o(e){return(o,n)=>{n.preventDefault();const i=n.dropRange?[n.dropRange]:null,r=new w(t,e);t.fire(r,{dataTransfer:n.dataTransfer,method:o.name,targetRanges:i,target:n.target,domEvent:n.domEvent}),r.stop.called&&n.stopPropagation()}}this.listenTo(t,"paste",o("clipboardInput"),{priority:"low"}),this.listenTo(t,"drop",o("clipboardInput"),{priority:"low"}),this.listenTo(t,"dragover",o("dragging"),{priority:"low"})}onDomEvent(e){const t="clipboardData"in e?e.clipboardData:e.dataTransfer,o="drop"==e.type||"paste"==e.type,n={dataTransfer:new Bl(t,{cacheFiles:o})};"drop"!=e.type&&"dragover"!=e.type||(n.dropRange=function(e,t){const o=t.target.ownerDocument,n=t.clientX,i=t.clientY;let r;o.caretRangeFromPoint&&o.caretRangeFromPoint(n,i)?r=o.caretRangeFromPoint(n,i):t.rangeParent&&(r=o.createRange(),r.setStart(t.rangeParent,t.rangeOffset),r.collapse(!0));if(r)return e.domConverter.domRangeToView(r);return null}(this.view,e)),this.fire(e.type,e,n)}}const y_=["figcaption","li"],A_=["ol","ul"];function C_(e){if(e.is("$text")||e.is("$textProxy"))return e.data;if(e.is("element","img")&&e.hasAttribute("alt"))return e.getAttribute("alt");if(e.is("element","br"))return"\n";let t="",o=null;for(const n of e.getChildren())t+=v_(n,o)+C_(n),o=n;return t}function v_(e,t){return t?e.is("element","li")&&!e.isEmpty&&e.getChild(0).is("containerElement")||A_.includes(e.name)&&A_.includes(t.name)?"\n\n":e.is("containerElement")||t.is("containerElement")?y_.includes(e.name)||y_.includes(t.name)?"\n":e.is("element")&&e.getCustomProperty("dataPipeline:transparentRendering")||t.is("element")&&t.getCustomProperty("dataPipeline:transparentRendering")?"":"\n\n":"":""}const x_=function(e,t){return e&&Di(e,t,mo)};const E_=function(e,t,o,n){var i=o.length,r=i,s=!n;if(null==e)return!r;for(e=Object(e);i--;){var a=o[i];if(s&&a[2]?a[1]!==e[a[0]]:!(a[0]in e))return!1}for(;++ie.model.getSelectedContent(e.model.document.selection))){return this.editor.model.change((n=>{const i=n.model.document.selection;n.setSelection(t);const r=this._insertFakeMarkersIntoSelection(n,n.model.document.selection,e),s=o(n),a=this._removeFakeMarkersInsideElement(n,s);for(const[e,t]of Object.entries(r)){a[e]||(a[e]=n.createRangeIn(s));for(const e of t)n.remove(e)}s.markers.clear();for(const[e,t]of Object.entries(a))s.markers.set(e,t);return n.setSelection(i),s}))}_pasteMarkersIntoTransformedElement(e,t){const o=this._getPasteMarkersFromRangeMap(e);return this.editor.model.change((e=>{const n=this._insertFakeMarkersElements(e,o),i=t(e),r=this._removeFakeMarkersInsideElement(e,i);for(const t of Object.values(n).flat())e.remove(t);for(const[t,o]of Object.entries(r))e.model.markers.has(t)||e.addMarker(t,{usingOperation:!0,affectsData:!0,range:o});return i}))}_pasteFragmentWithMarkers(e){const t=this._getPasteMarkersFromRangeMap(e.markers);e.markers.clear();for(const o of t)e.markers.set(o.name,o.range);return this.editor.model.insertContent(e)}_forceMarkersCopy(e,t,o={allowedActions:"all",copyPartiallySelected:!0,duplicateOnPaste:!0}){const n=this._markersToCopy.get(e);this._markersToCopy.set(e,o),t(),n?this._markersToCopy.set(e,n):this._markersToCopy.delete(e)}_isMarkerCopyable(e,t){const o=this._getMarkerClipboardConfig(e);if(!o)return!1;if(!t)return!0;const{allowedActions:n}=o;return"all"===n||n.includes(t)}_hasMarkerConfiguration(e){return!!this._getMarkerClipboardConfig(e)}_getMarkerClipboardConfig(e){const[t]=e.split(":");return this._markersToCopy.get(t)||null}_insertFakeMarkersIntoSelection(e,t,o){const n=this._getCopyableMarkersFromSelection(e,t,o);return this._insertFakeMarkersElements(e,n)}_getCopyableMarkersFromSelection(e,t,o){const n=Array.from(t.getRanges()),i=new Set(n.flatMap((t=>Array.from(e.model.markers.getMarkersIntersectingRange(t)))));return Array.from(i).filter((e=>{if(!this._isMarkerCopyable(e.name,o))return!1;const{copyPartiallySelected:t}=this._getMarkerClipboardConfig(e.name);if(!t){const t=e.getRange();return n.some((e=>e.containsRange(t,!0)))}return!0})).map((e=>({name:"dragstart"===o?this._getUniqueMarkerName(e.name):e.name,range:e.getRange()})))}_getPasteMarkersFromRangeMap(e,t=null){const{model:o}=this.editor;return(e instanceof Map?Array.from(e.entries()):Object.entries(e)).flatMap((([e,n])=>{if(!this._hasMarkerConfiguration(e))return[{name:e,range:n}];if(this._isMarkerCopyable(e,t)){const t=this._getMarkerClipboardConfig(e),i=o.markers.has(e)&&"$graveyard"===o.markers.get(e).getRange().root.rootName;return(t.duplicateOnPaste||i)&&(e=this._getUniqueMarkerName(e)),[{name:e,range:n}]}return[]}))}_insertFakeMarkersElements(e,t){const o={},n=t.flatMap((e=>{const{start:t,end:o}=e.range;return[{position:t,marker:e,type:"start"},{position:o,marker:e,type:"end"}]})).sort((({position:e},{position:t})=>e.isBefore(t)?1:-1));for(const{position:t,marker:i,type:r}of n){const n=e.createElement("$marker",{"data-name":i.name,"data-type":r});o[i.name]||(o[i.name]=[]),o[i.name].push(n),e.insert(n,t)}return o}_removeFakeMarkersInsideElement(e,t){const o=this._getAllFakeMarkersFromElement(e,t).reduce(((t,o)=>{const n=o.markerElement&&e.createPositionBefore(o.markerElement);let i=t[o.name],r=!1;if(i&&i.start&&i.end){this._getMarkerClipboardConfig(o.name).duplicateOnPaste?t[this._getUniqueMarkerName(o.name)]=t[o.name]:r=!0,i=null}return r||(t[o.name]={...i,[o.type]:n}),o.markerElement&&e.remove(o.markerElement),t}),{});return N_(o,(o=>new Zl(o.start||e.createPositionFromPath(t,[0]),o.end||e.createPositionAt(t,"end"))))}_getAllFakeMarkersFromElement(e,t){const o=Array.from(e.createRangeIn(t)).flatMap((({item:e})=>{if(!e.is("element","$marker"))return[];const t=e.getAttribute("data-name"),o=e.getAttribute("data-type");return[{markerElement:e,name:t,type:o}]})),n=[],i=[];for(const e of o){if("end"===e.type){o.some((t=>t.name===e.name&&"start"===t.type))||n.push({markerElement:null,name:e.name,type:"start"})}if("start"===e.type){o.some((t=>t.name===e.name&&"end"===t.type))||i.unshift({markerElement:null,name:e.name,type:"end"})}}return[...n,...o,...i]}_getUniqueMarkerName(e){const t=e.split(":"),o=A().substring(1,6);return 3===t.length?`${t.slice(0,2).join(":")}:${o}`:`${t.join(":")}:${o}`}}class H_ extends lr{static get pluginName(){return"ClipboardPipeline"}static get requires(){return[L_]}init(){this.editor.editing.view.addObserver(__),this._setupPasteDrop(),this._setupCopyCut()}_fireOutputTransformationEvent(e,t,o){const n=this.editor.plugins.get("ClipboardMarkersUtils");this.editor.model.enqueueChange({isUndoable:"cut"===o},(()=>{const i=n._copySelectedFragmentWithMarkers(o,t);this.fire("outputTransformation",{dataTransfer:e,content:i,method:o})}))}_setupPasteDrop(){const e=this.editor,t=e.model,o=e.editing.view,n=o.document,i=this.editor.plugins.get("ClipboardMarkersUtils");this.listenTo(n,"clipboardInput",((t,o)=>{"paste"!=o.method||e.model.canEditAt(e.model.document.selection)||t.stop()}),{priority:"highest"}),this.listenTo(n,"clipboardInput",((e,t)=>{const n=t.dataTransfer;let i;if(t.content)i=t.content;else{let e="";n.getData("text/html")?e=function(e){return e.replace(/(\s+)<\/span>/g,((e,t)=>1==t.length?" ":t)).replace(//g,"")}(n.getData("text/html")):n.getData("text/plain")&&(((r=(r=n.getData("text/plain")).replace(/&/g,"&").replace(//g,">").replace(/\r?\n\r?\n/g,"

    ").replace(/\r?\n/g,"
    ").replace(/\t/g,"    ").replace(/^\s/," ").replace(/\s$/," ").replace(/\s\s/g,"  ")).includes("

    ")||r.includes("
    "))&&(r=`

    ${r}

    `),e=r),i=this.editor.data.htmlProcessor.toView(e)}var r;const s=new w(this,"inputTransformation");this.fire(s,{content:i,dataTransfer:n,targetRanges:t.targetRanges,method:t.method}),s.stop.called&&e.stop(),o.scrollToTheSelection()}),{priority:"low"}),this.listenTo(this,"inputTransformation",((e,o)=>{if(o.content.isEmpty)return;const n=this.editor.data.toModel(o.content,"$clipboardHolder");0!=n.childCount&&(e.stop(),t.change((()=>{this.fire("contentInsertion",{content:n,method:o.method,dataTransfer:o.dataTransfer,targetRanges:o.targetRanges})})))}),{priority:"low"}),this.listenTo(this,"contentInsertion",((e,t)=>{t.resultRange=i._pasteFragmentWithMarkers(t.content)}),{priority:"low"})}_setupCopyCut(){const e=this.editor,t=e.model.document,o=e.editing.view.document,n=(e,o)=>{const n=o.dataTransfer;o.preventDefault(),this._fireOutputTransformationEvent(n,t.selection,e.name)};this.listenTo(o,"copy",n,{priority:"low"}),this.listenTo(o,"cut",((t,o)=>{e.model.canEditAt(e.model.document.selection)?n(t,o):o.preventDefault()}),{priority:"low"}),this.listenTo(this,"outputTransformation",((t,n)=>{const i=e.data.toView(n.content);o.fire("clipboardOutput",{dataTransfer:n.dataTransfer,content:i,method:n.method})}),{priority:"low"}),this.listenTo(o,"clipboardOutput",((o,n)=>{n.content.isEmpty||(n.dataTransfer.setData("text/html",this.editor.data.htmlProcessor.toData(n.content)),n.dataTransfer.setData("text/plain",C_(n.content))),"cut"==n.method&&e.model.deleteContent(t.selection)}),{priority:"low"})}}const j_=Yn("px");class q_ extends pm{constructor(){super();const e=this.bindTemplate;this.set({isVisible:!1,left:null,top:null,width:null}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-clipboard-drop-target-line",e.if("isVisible","ck-hidden",(e=>!e))],style:{left:e.to("left",(e=>j_(e))),top:e.to("top",(e=>j_(e))),width:e.to("width",(e=>j_(e)))}}})}}class U_ extends lr{constructor(){super(...arguments),this.removeDropMarkerDelayed=or((()=>this.removeDropMarker()),40),this._updateDropMarkerThrottled=Bh((e=>this._updateDropMarker(e)),40),this._reconvertMarkerThrottled=Bh((()=>{this.editor.model.markers.has("drop-target")&&this.editor.editing.reconvertMarker("drop-target")}),0),this._dropTargetLineView=new q_,this._domEmitter=new(Rn()),this._scrollables=new Map}static get pluginName(){return"DragDropTarget"}init(){this._setupDropMarker()}destroy(){this._domEmitter.stopListening();for(const{resizeObserver:e}of this._scrollables.values())e.destroy();return this._updateDropMarkerThrottled.cancel(),this.removeDropMarkerDelayed.cancel(),this._reconvertMarkerThrottled.cancel(),super.destroy()}updateDropMarker(e,t,o,n,i,r){this.removeDropMarkerDelayed.cancel();const s=W_(this.editor,e,t,o,n,i,r);if(s)return r&&r.containsRange(s)?this.removeDropMarker():void this._updateDropMarkerThrottled(s)}getFinalDropRange(e,t,o,n,i,r){const s=W_(this.editor,e,t,o,n,i,r);return this.removeDropMarker(),s}removeDropMarker(){const e=this.editor.model;this.removeDropMarkerDelayed.cancel(),this._updateDropMarkerThrottled.cancel(),this._dropTargetLineView.isVisible=!1,e.markers.has("drop-target")&&e.change((e=>{e.removeMarker("drop-target")}))}_setupDropMarker(){const e=this.editor;e.ui.view.body.add(this._dropTargetLineView),e.conversion.for("editingDowncast").markerToHighlight({model:"drop-target",view:{classes:["ck-clipboard-drop-target-range"]}}),e.conversion.for("editingDowncast").markerToElement({model:"drop-target",view:(t,{writer:o})=>{if(e.model.schema.checkChild(t.markerRange.start,"$text"))return this._dropTargetLineView.isVisible=!1,this._createDropTargetPosition(o);t.markerRange.isCollapsed?this._updateDropTargetLine(t.markerRange):this._dropTargetLineView.isVisible=!1}})}_updateDropMarker(e){const t=this.editor,o=t.model.markers;t.model.change((t=>{o.has("drop-target")?o.get("drop-target").getRange().isEqual(e)||t.updateMarker("drop-target",{range:e}):t.addMarker("drop-target",{range:e,usingOperation:!1,affectsData:!1})}))}_createDropTargetPosition(e){return e.createUIElement("span",{class:"ck ck-clipboard-drop-target-position"},(function(e){const t=this.toDomElement(e);return t.append("⁠",e.createElement("span"),"⁠"),t}))}_updateDropTargetLine(e){const o=this.editor.editing,n=e.start.nodeBefore,i=e.start.nodeAfter,r=e.start.parent,s=n?o.mapper.toViewElement(n):null,a=s?o.view.domConverter.mapViewToDom(s):null,l=i?o.mapper.toViewElement(i):null,c=l?o.view.domConverter.mapViewToDom(l):null,d=o.mapper.toViewElement(r);if(!d)return;const u=o.view.domConverter.mapViewToDom(d),h=this._getScrollableRect(d),{scrollX:m,scrollY:p}=t.window,g=a?new qn(a):null,f=c?new qn(c):null,b=new qn(u).excludeScrollbarsAndBorders(),k=g?g.bottom:b.top,w=f?f.top:b.bottom,_=t.window.getComputedStyle(u),y=k<=w?(k+w)/2:w;if(h.topa.schema.checkChild(r,e)))){if(a.schema.checkChild(r,"$text"))return a.createRange(r);if(t)return G_(e,Z_(e,t.parent),n,i)}}}else if(a.schema.isInline(c))return G_(e,c,n,i);if(a.schema.isBlock(c))return G_(e,c,n,i);if(a.schema.checkChild(c,"$block")){const t=Array.from(c.getChildren()).filter((t=>t.is("element")&&!$_(e,t)));let o=0,r=t.length;if(0==r)return a.createRange(a.createPositionAt(c,"end"));for(;o{o?(this.forceDisabled("readOnlyMode"),this._isBlockDragging=!1):this.clearForceDisabled("readOnlyMode")})),r.isAndroid&&this.forceDisabled("noAndroidSupport"),e.plugins.has("BlockToolbar")){const o=e.plugins.get("BlockToolbar").buttonView.element;this._domEmitter.listenTo(o,"dragstart",((e,t)=>this._handleBlockDragStart(t))),this._domEmitter.listenTo(t.document,"dragover",((e,t)=>this._handleBlockDragging(t))),this._domEmitter.listenTo(t.document,"drop",((e,t)=>this._handleBlockDragging(t))),this._domEmitter.listenTo(t.document,"dragend",(()=>this._handleBlockDragEnd()),{useCapture:!0}),this.isEnabled&&o.setAttribute("draggable","true"),this.on("change:isEnabled",((e,t,n)=>{o.setAttribute("draggable",n?"true":"false")}))}}destroy(){return this._domEmitter.stopListening(),super.destroy()}_handleBlockDragStart(e){if(!this.isEnabled)return;const t=this.editor.model,o=t.document.selection,n=this.editor.editing.view,i=Array.from(o.getSelectedBlocks()),r=t.createRange(t.createPositionBefore(i[0]),t.createPositionAfter(i[i.length-1]));t.change((e=>e.setSelection(r))),this._isBlockDragging=!0,n.focus(),n.getObserver(__).onDomEvent(e)}_handleBlockDragging(e){if(!this.isEnabled||!this._isBlockDragging)return;const t=e.clientX+("ltr"==this.editor.locale.contentLanguageDirection?100:-100),o=e.clientY,n=document.elementFromPoint(t,o),i=this.editor.editing.view;n&&n.closest(".ck-editor__editable")&&i.getObserver(__).onDomEvent({...e,type:e.type,dataTransfer:e.dataTransfer,target:n,clientX:t,clientY:o,preventDefault:()=>e.preventDefault(),stopPropagation:()=>e.stopPropagation()})}_handleBlockDragEnd(){this._isBlockDragging=!1}}var Y_=i(9262),Q_={attributes:{"data-cke":!0}};Q_.setAttributes=Ar(),Q_.insert=_r().bind(null,"head"),Q_.domAPI=kr(),Q_.insertStyleElement=vr();fr()(Y_.A,Q_);Y_.A&&Y_.A.locals&&Y_.A.locals;class X_ extends lr{constructor(){super(...arguments),this._clearDraggableAttributesDelayed=or((()=>this._clearDraggableAttributes()),40),this._blockMode=!1,this._domEmitter=new(Rn())}static get pluginName(){return"DragDrop"}static get requires(){return[H_,Zw,U_,J_]}init(){const e=this.editor,t=e.editing.view;this._draggedRange=null,this._draggingUid="",this._draggableElement=null,t.addObserver(__),t.addObserver(Nu),this._setupDragging(),this._setupContentInsertionIntegration(),this._setupClipboardInputIntegration(),this._setupDraggableAttributeHandling(),this.listenTo(e,"change:isReadOnly",((e,t,o)=>{o?this.forceDisabled("readOnlyMode"):this.clearForceDisabled("readOnlyMode")})),this.on("change:isEnabled",((e,t,o)=>{o||this._finalizeDragging(!1)})),r.isAndroid&&this.forceDisabled("noAndroidSupport")}destroy(){return this._draggedRange&&(this._draggedRange.detach(),this._draggedRange=null),this._previewContainer&&this._previewContainer.remove(),this._domEmitter.stopListening(),this._clearDraggableAttributesDelayed.cancel(),super.destroy()}_setupDragging(){const e=this.editor,o=e.model,n=e.editing.view,i=n.document,s=e.plugins.get(U_);this.listenTo(i,"dragstart",((e,t)=>{if(t.target&&t.target.is("editableElement"))return void t.preventDefault();if(this._prepareDraggedRange(t.target),!this._draggedRange)return void t.preventDefault();this._draggingUid=A(),t.dataTransfer.effectAllowed=this.isEnabled?"copyMove":"copy",t.dataTransfer.setData("application/ckeditor5-dragging-uid",this._draggingUid);const n=o.createSelection(this._draggedRange.toRange());this.editor.plugins.get("ClipboardPipeline")._fireOutputTransformationEvent(t.dataTransfer,n,"dragstart");const{dataTransfer:i,domTarget:r,domEvent:s}=t,{clientX:a}=s;this._updatePreview({dataTransfer:i,domTarget:r,clientX:a}),t.stopPropagation(),this.isEnabled||(this._draggedRange.detach(),this._draggedRange=null,this._draggingUid="")}),{priority:"low"}),this.listenTo(i,"dragend",((e,t)=>{this._finalizeDragging(!t.dataTransfer.isCanceled&&"move"==t.dataTransfer.dropEffect)}),{priority:"low"}),this._domEmitter.listenTo(t.document,"dragend",(()=>{this._blockMode=!1}),{useCapture:!0}),this.listenTo(i,"dragenter",(()=>{this.isEnabled&&n.focus()})),this.listenTo(i,"dragleave",(()=>{s.removeDropMarkerDelayed()})),this.listenTo(i,"dragging",((e,t)=>{if(!this.isEnabled)return void(t.dataTransfer.dropEffect="none");const{clientX:o,clientY:n}=t.domEvent;s.updateDropMarker(t.target,t.targetRanges,o,n,this._blockMode,this._draggedRange),this._draggedRange||(t.dataTransfer.dropEffect="copy"),r.isGecko||("copy"==t.dataTransfer.effectAllowed?t.dataTransfer.dropEffect="copy":["all","copyMove"].includes(t.dataTransfer.effectAllowed)&&(t.dataTransfer.dropEffect="move")),e.stop()}),{priority:"low"})}_setupClipboardInputIntegration(){const e=this.editor,t=e.editing.view.document,o=e.plugins.get(U_);this.listenTo(t,"clipboardInput",((t,n)=>{if("drop"!=n.method)return;const{clientX:i,clientY:r}=n.domEvent,s=o.getFinalDropRange(n.target,n.targetRanges,i,r,this._blockMode,this._draggedRange);if(!s)return this._finalizeDragging(!1),void t.stop();this._draggedRange&&this._draggingUid!=n.dataTransfer.getData("application/ckeditor5-dragging-uid")&&(this._draggedRange.detach(),this._draggedRange=null,this._draggingUid="");if("move"==ey(n.dataTransfer)&&this._draggedRange&&this._draggedRange.containsRange(s,!0))return this._finalizeDragging(!1),void t.stop();n.targetRanges=[e.editing.mapper.toViewRange(s)]}),{priority:"high"})}_setupContentInsertionIntegration(){const e=this.editor.plugins.get(H_);e.on("contentInsertion",((e,t)=>{if(!this.isEnabled||"drop"!==t.method)return;const o=t.targetRanges.map((e=>this.editor.editing.mapper.toModelRange(e)));this.editor.model.change((e=>e.setSelection(o)))}),{priority:"high"}),e.on("contentInsertion",((e,t)=>{if(!this.isEnabled||"drop"!==t.method)return;const o="move"==ey(t.dataTransfer),n=!t.resultRange||!t.resultRange.isCollapsed;this._finalizeDragging(n&&o)}),{priority:"lowest"})}_setupDraggableAttributeHandling(){const e=this.editor,t=e.editing.view,o=t.document;this.listenTo(o,"mousedown",((n,i)=>{if(r.isAndroid||!i)return;this._clearDraggableAttributesDelayed.cancel();let s=ty(i.target);if(r.isBlink&&!e.isReadOnly&&!s&&!o.selection.isCollapsed){const e=o.selection.getSelectedElement();e&&Rk(e)||(s=o.selection.editableElement)}s&&(t.change((e=>{e.setAttribute("draggable","true",s)})),this._draggableElement=e.editing.mapper.toModelElement(s))})),this.listenTo(o,"mouseup",(()=>{r.isAndroid||this._clearDraggableAttributesDelayed()}))}_clearDraggableAttributes(){const e=this.editor.editing;e.view.change((t=>{this._draggableElement&&"$graveyard"!=this._draggableElement.root.rootName&&t.removeAttribute("draggable",e.mapper.toViewElement(this._draggableElement)),this._draggableElement=null}))}_finalizeDragging(e){const t=this.editor,o=t.model;if(t.plugins.get(U_).removeDropMarker(),this._clearDraggableAttributes(),t.plugins.has("WidgetToolbarRepository")){t.plugins.get("WidgetToolbarRepository").clearForceDisabled("dragDrop")}this._draggingUid="",this._previewContainer&&(this._previewContainer.remove(),this._previewContainer=void 0),this._draggedRange&&(e&&this.isEnabled&&o.change((e=>{const t=o.createSelection(this._draggedRange);o.deleteContent(t,{doNotAutoparagraph:!0});const n=t.getFirstPosition().parent;n.isEmpty&&!o.schema.checkChild(n,"$text")&&o.schema.checkChild(n,"paragraph")&&e.insertElement("paragraph",n,0)})),this._draggedRange.detach(),this._draggedRange=null)}_prepareDraggedRange(e){const t=this.editor,o=t.model,n=o.document.selection,i=e?ty(e):null;if(i){const e=t.editing.mapper.toModelElement(i);if(this._draggedRange=cc.fromRange(o.createRangeOn(e)),this._blockMode=o.schema.isBlock(e),t.plugins.has("WidgetToolbarRepository")){t.plugins.get("WidgetToolbarRepository").forceDisabled("dragDrop")}return}if(n.isCollapsed&&!n.getFirstPosition().parent.isEmpty)return;const r=Array.from(n.getSelectedBlocks()),s=n.getFirstRange();if(0==r.length)return void(this._draggedRange=cc.fromRange(s));const a=oy(o,r);if(r.length>1)this._draggedRange=cc.fromRange(a),this._blockMode=!0;else if(1==r.length){const e=s.start.isTouching(a.start)&&s.end.isTouching(a.end);this._draggedRange=cc.fromRange(e?a:s),this._blockMode=e}o.change((e=>e.setSelection(this._draggedRange.toRange())))}_updatePreview({dataTransfer:e,domTarget:o,clientX:n}){const i=this.editor.editing.view,s=i.document.selection.editableElement,a=i.domConverter.mapViewToDom(s),l=t.window.getComputedStyle(a);this._previewContainer?this._previewContainer.firstElementChild&&this._previewContainer.removeChild(this._previewContainer.firstElementChild):(this._previewContainer=Ae(t.document,"div",{style:"position: fixed; left: -999999px;"}),t.document.body.appendChild(this._previewContainer));const c=new qn(a);if(a.contains(o))return;const d=parseFloat(l.paddingLeft),u=Ae(t.document,"div");u.className="ck ck-content",u.style.width=l.width,u.style.paddingLeft=`${c.left-n+d}px`,r.isiOS&&(u.style.backgroundColor="white"),u.innerHTML=e.getData("text/html"),e.setDragImage(u,0,0),this._previewContainer.appendChild(u)}}function ey(e){return r.isGecko?e.dropEffect:["all","copyMove"].includes(e.effectAllowed)?"move":"copy"}function ty(e){if(e.is("editableElement"))return null;if(e.hasClass("ck-widget__selection-handle"))return e.findAncestor(Rk);if(Rk(e))return e;const t=e.findAncestor((e=>Rk(e)||e.is("editableElement")));return Rk(t)?t:null}function oy(e,t){const o=t[0],n=t[t.length-1],i=o.getCommonAncestor(n),r=e.createPositionBefore(o),s=e.createPositionAfter(n);if(i&&i.is("element")&&!e.schema.isLimit(i)){const t=e.createRangeOn(i),o=r.isTouching(t.start),n=s.isTouching(t.end);if(o&&n)return oy(e,[i])}return e.createRange(r,s)}class ny extends lr{static get pluginName(){return"PastePlainText"}static get requires(){return[H_]}init(){const e=this.editor,t=e.model,o=e.editing.view,n=t.document.selection;o.addObserver(__),e.plugins.get(H_).on("contentInsertion",((e,o)=>{(function(e,t){let o=t.createRangeIn(e);if(1==e.childCount){const n=e.getChild(0);n.is("element")&&t.schema.isBlock(n)&&!t.schema.isObject(n)&&!t.schema.isLimit(n)&&(o=t.createRangeIn(n))}for(const e of o.getItems()){if(!t.schema.isInline(e))return!1;if(Array.from(e.getAttributeKeys()).find((e=>t.schema.getAttributeProperties(e).isFormatting)))return!1}return!0})(o.content,t)&&t.change((e=>{const i=Array.from(n.getAttributes()).filter((([e])=>t.schema.getAttributeProperties(e).isFormatting));n.isCollapsed||t.deleteContent(n,{doNotAutoparagraph:!0}),i.push(...n.getAttributes());const r=e.createRangeIn(o.content);for(const o of r.getItems())for(const n of i)t.schema.checkAttribute(o,n[0])&&e.setAttribute(n[0],n[1],o)}))}))}}class iy extends lr{static get pluginName(){return"Clipboard"}static get requires(){return[L_,H_,X_,ny]}init(){const e=this.editor,t=this.editor.t;e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Copy selected content"),keystroke:"CTRL+C"},{label:t("Paste content"),keystroke:"CTRL+V"},{label:t("Paste content as plain text"),keystroke:"CTRL+SHIFT+V"}]})}}class ry extends dr{constructor(e){super(e),this._stack=[],this._createdBatches=new WeakSet,this.refresh(),this._isEnabledBasedOnSelection=!1,this.listenTo(e.data,"set",((e,t)=>{t[1]={...t[1]};const o=t[1];o.batchType||(o.batchType={isUndoable:!1})}),{priority:"high"}),this.listenTo(e.data,"set",((e,t)=>{t[1].batchType.isUndoable||this.clearStack()}))}refresh(){this.isEnabled=this._stack.length>0}get createdBatches(){return this._createdBatches}addBatch(e){const t=this.editor.model.document.selection,o={ranges:t.hasOwnRange?Array.from(t.getRanges()):[],isBackward:t.isBackward};this._stack.push({batch:e,selection:o}),this.refresh()}clearStack(){this._stack=[],this.refresh()}_restoreSelection(e,t,o){const n=this.editor.model,i=n.document,r=[],s=e.map((e=>e.getTransformedByOperations(o))),a=s.flat();for(const e of s){const t=e.filter((e=>e.root!=i.graveyard)).filter((e=>!ay(e,a)));t.length&&(sy(t),r.push(t[0]))}r.length&&n.change((e=>{e.setSelection(r,{backward:t})}))}_undo(e,t){const o=this.editor.model,n=o.document;this._createdBatches.add(t);const i=e.operations.slice().filter((e=>e.isDocumentOperation));i.reverse();for(const e of i){const i=e.baseVersion+1,r=Array.from(n.history.getOperations(i)),s=Ud([e.getReversed()],r,{useRelations:!0,document:this.editor.model.document,padWithNoOps:!1,forceWeakRemove:!0}).operationsA;for(let i of s){const r=i.affectedSelectable;r&&!o.canEditAt(r)&&(i=new Md(i.baseVersion)),t.addOperation(i),o.applyOperation(i),n.history.setOperationAsUndone(e,i)}}}}function sy(e){e.sort(((e,t)=>e.start.isBefore(t.start)?-1:1));for(let t=1;tt!==e&&t.containsRange(e,!0)))}class ly extends ry{execute(e=null){const t=e?this._stack.findIndex((t=>t.batch==e)):this._stack.length-1,o=this._stack.splice(t,1)[0],n=this.editor.model.createBatch({isUndo:!0});this.editor.model.enqueueChange(n,(()=>{this._undo(o.batch,n);const e=this.editor.model.document.history.getOperations(o.batch.baseVersion);this._restoreSelection(o.selection.ranges,o.selection.isBackward,e)})),this.fire("revert",o.batch,n),this.refresh()}}class cy extends ry{execute(){const e=this._stack.pop(),t=this.editor.model.createBatch({isUndo:!0});this.editor.model.enqueueChange(t,(()=>{const o=e.batch.operations[e.batch.operations.length-1].baseVersion+1,n=this.editor.model.document.history.getOperations(o);this._restoreSelection(e.selection.ranges,e.selection.isBackward,n),this._undo(e.batch,t)})),this.refresh()}}class dy extends lr{constructor(){super(...arguments),this._batchRegistry=new WeakSet}static get pluginName(){return"UndoEditing"}init(){const e=this.editor,t=e.t;this._undoCommand=new ly(e),this._redoCommand=new cy(e),e.commands.add("undo",this._undoCommand),e.commands.add("redo",this._redoCommand),this.listenTo(e.model,"applyOperation",((e,t)=>{const o=t[0];if(!o.isDocumentOperation)return;const n=o.batch,i=this._redoCommand.createdBatches.has(n),r=this._undoCommand.createdBatches.has(n);this._batchRegistry.has(n)||(this._batchRegistry.add(n),n.isUndoable&&(i?this._undoCommand.addBatch(n):r||(this._undoCommand.addBatch(n),this._redoCommand.clearStack())))}),{priority:"highest"}),this.listenTo(this._undoCommand,"revert",((e,t,o)=>{this._redoCommand.addBatch(o)})),e.keystrokes.set("CTRL+Z","undo"),e.keystrokes.set("CTRL+Y","redo"),e.keystrokes.set("CTRL+SHIFT+Z","redo"),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Undo"),keystroke:"CTRL+Z"},{label:t("Redo"),keystroke:[["CTRL+Y"],["CTRL+SHIFT+Z"]]}]})}}class uy extends lr{static get pluginName(){return"UndoUI"}init(){const e=this.editor,t=e.locale,o=e.t,n="ltr"==t.uiLanguageDirection?qh.undo:qh.redo,i="ltr"==t.uiLanguageDirection?qh.redo:qh.undo;this._addButtonsToFactory("undo",o("Undo"),"CTRL+Z",n),this._addButtonsToFactory("redo",o("Redo"),"CTRL+Y",i)}_addButtonsToFactory(e,t,o,n){const i=this.editor;i.ui.componentFactory.add(e,(()=>{const i=this._createButton(Em,e,t,o,n);return i.set({tooltip:!0}),i})),i.ui.componentFactory.add("menuBar:"+e,(()=>this._createButton(ip,e,t,o,n)))}_createButton(e,t,o,n,i){const r=this.editor,s=r.locale,a=r.commands.get(t),l=new e(s);return l.set({label:o,icon:i,keystroke:n}),l.bind("isEnabled").to(a,"isEnabled"),this.listenTo(l,"execute",(()=>{r.execute(t),r.editing.view.focus()})),l}}class hy extends lr{static get requires(){return[dy,uy]}static get pluginName(){return"Undo"}}function my(e){return e.createContainerElement("figure",{class:"image"},[e.createEmptyElement("img"),e.createSlot("children")])}function py(e,t){const o=e.plugins.get("ImageUtils"),n=e.plugins.has("ImageInlineEditing")&&e.plugins.has("ImageBlockEditing");return e=>{if(!o.isInlineImageView(e))return null;if(!n)return i(e);return("block"==e.getStyle("display")||e.findAncestor(o.isBlockImageView)?"imageBlock":"imageInline")!==t?null:i(e)};function i(e){const t={name:!0};return e.hasAttribute("src")&&(t.attributes=["src"]),t}}function gy(e,t){const o=Qi(t.getSelectedBlocks());return!o||e.isObject(o)||o.isEmpty&&"listItem"!=o.name?"imageBlock":"imageInline"}function fy(e){return e&&e.endsWith("px")?parseInt(e):null}function by(e){const t=fy(e.getStyle("width")),o=fy(e.getStyle("height"));return!(!t||!o)}const ky=/^(image|image-inline)$/;class wy extends lr{constructor(){super(...arguments),this._domEmitter=new(Rn())}static get pluginName(){return"ImageUtils"}isImage(e){return this.isInlineImage(e)||this.isBlockImage(e)}isInlineImageView(e){return!!e&&e.is("element","img")}isBlockImageView(e){return!!e&&e.is("element","figure")&&e.hasClass("image")}insertImage(e={},t=null,o=null,n={}){const i=this.editor,r=i.model,s=r.document.selection,a=_y(i,t||s,o);e={...Object.fromEntries(s.getAttributes()),...e};for(const t in e)r.schema.checkAttribute(a,t)||delete e[t];return r.change((o=>{const{setImageSizes:i=!0}=n,s=o.createElement(a,e);return r.insertObject(s,t,null,{setSelection:"on",findOptimalPosition:t||"imageInline"==a?void 0:"auto"}),s.parent?(i&&this.setImageNaturalSizeAttributes(s),s):null}))}setImageNaturalSizeAttributes(e){const o=e.getAttribute("src");o&&(e.getAttribute("width")||e.getAttribute("height")||this.editor.model.change((n=>{const i=new t.window.Image;this._domEmitter.listenTo(i,"load",(()=>{e.getAttribute("width")||e.getAttribute("height")||this.editor.model.enqueueChange(n.batch,(t=>{t.setAttribute("width",i.naturalWidth,e),t.setAttribute("height",i.naturalHeight,e)})),this._domEmitter.stopListening(i,"load")})),i.src=o})))}getClosestSelectedImageWidget(e){const t=e.getFirstPosition();if(!t)return null;const o=e.getSelectedElement();if(o&&this.isImageWidget(o))return o;let n=t.parent;for(;n;){if(n.is("element")&&this.isImageWidget(n))return n;n=n.parent}return null}getClosestSelectedImageElement(e){const t=e.getSelectedElement();return this.isImage(t)?t:e.getFirstPosition().findAncestor("imageBlock")}getImageWidgetFromImageView(e){return e.findAncestor({classes:ky})}isImageAllowed(){const e=this.editor.model.document.selection;return function(e,t){const o=_y(e,t,null);if("imageBlock"==o){const o=function(e,t){const o=function(e,t){const o=e.getSelectedElement();if(o){const n=Ik(e);if(n)return t.createRange(t.createPositionAt(o,n))}return t.schema.findOptimalInsertionRange(e)}(e,t),n=o.start.parent;if(n.isEmpty&&!n.is("element","$root"))return n.parent;return n}(t,e.model);if(e.model.schema.checkChild(o,"imageBlock"))return!0}else if(e.model.schema.checkChild(t.focus,"imageInline"))return!0;return!1}(this.editor,e)&&function(e){return[...e.focus.getAncestors()].every((e=>!e.is("element","imageBlock")))}(e)}toImageWidget(e,t,o){t.setCustomProperty("image",!0,e);return zk(e,t,{label:()=>{const t=this.findViewImgElement(e).getAttribute("alt");return t?`${t} ${o}`:o}})}isImageWidget(e){return!!e.getCustomProperty("image")&&Rk(e)}isBlockImage(e){return!!e&&e.is("element","imageBlock")}isInlineImage(e){return!!e&&e.is("element","imageInline")}findViewImgElement(e){if(this.isInlineImageView(e))return e;const t=this.editor.editing.view;for(const{item:o}of t.createRangeIn(e))if(this.isInlineImageView(o))return o}destroy(){return this._domEmitter.stopListening(),super.destroy()}}function _y(e,t,o){const n=e.model.schema,i=e.config.get("image.insert.type");return e.plugins.has("ImageBlockEditing")?e.plugins.has("ImageInlineEditing")?o||("inline"===i?"imageInline":"auto"!==i?"imageBlock":t.is("selection")?gy(n,t):n.checkChild(t,"imageInline")?"imageInline":"imageBlock"):"imageBlock":"imageInline"}new RegExp(String(/^(http(s)?:\/\/)?[\w-]+\.[\w.~:/[\]@!$&'()*+,;=%-]+/.source+/\.(jpg|jpeg|png|gif|ico|webp|JPG|JPEG|PNG|GIF|ICO|WEBP)/.source+/(\?[\w.~:/[\]@!$&'()*+,;=%-]*)?/.source+/(#[\w.~:/[\]@!$&'()*+,;=%-]*)?$/.source));class yy extends dr{refresh(){const e=this.editor.plugins.get("ImageUtils").getClosestSelectedImageElement(this.editor.model.document.selection);this.isEnabled=!!e,this.isEnabled&&e.hasAttribute("alt")?this.value=e.getAttribute("alt"):this.value=!1}execute(e){const t=this.editor,o=t.plugins.get("ImageUtils"),n=t.model,i=o.getClosestSelectedImageElement(n.document.selection);n.change((t=>{t.setAttribute("alt",e.newValue,i)}))}}class Ay extends lr{static get requires(){return[wy]}static get pluginName(){return"ImageTextAlternativeEditing"}init(){this.editor.commands.add("imageTextAlternative",new yy(this.editor))}}var Cy=i(8429),vy={attributes:{"data-cke":!0}};vy.setAttributes=Ar(),vy.insert=_r().bind(null,"head"),vy.domAPI=kr(),vy.insertStyleElement=vr();fr()(Cy.A,vy);Cy.A&&Cy.A.locals&&Cy.A.locals;var xy=i(871),Ey={attributes:{"data-cke":!0}};Ey.setAttributes=Ar(),Ey.insert=_r().bind(null,"head"),Ey.domAPI=kr(),Ey.insertStyleElement=vr();fr()(xy.A,Ey);xy.A&&xy.A.locals&&xy.A.locals;class Dy extends pm{constructor(e){super(e);const t=this.locale.t;this.focusTracker=new Xi,this.keystrokes=new er,this.labeledInput=this._createLabeledInputView(),this.saveButtonView=this._createButton(t("Save"),qh.check,"ck-button-save"),this.saveButtonView.type="submit",this.cancelButtonView=this._createButton(t("Cancel"),qh.cancel,"ck-button-cancel","cancel"),this._focusables=new Uh,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.setTemplate({tag:"form",attributes:{class:["ck","ck-text-alternative-form","ck-responsive-form"],tabindex:"-1"},children:[this.labeledInput,this.saveButtonView,this.cancelButtonView]})}render(){super.render(),this.keystrokes.listenTo(this.element),bm({view:this}),[this.labeledInput,this.saveButtonView,this.cancelButtonView].forEach((e=>{this._focusables.add(e),this.focusTracker.add(e.element)}))}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}_createButton(e,t,o,n){const i=new Em(this.locale);return i.set({label:e,icon:t,tooltip:!0}),i.extendTemplate({attributes:{class:o}}),n&&i.delegate("execute").to(this,n),i}_createLabeledInputView(){const e=this.locale.t,t=new jp(this.locale,Fg);return t.label=e("Text alternative"),t}}function By(e){const t=e.editing.view,o=Ff.defaultPositions,n=e.plugins.get("ImageUtils");return{target:t.domConverter.mapViewToDom(n.getClosestSelectedImageWidget(t.document.selection)),positions:[o.northArrowSouth,o.northArrowSouthWest,o.northArrowSouthEast,o.southArrowNorth,o.southArrowNorthWest,o.southArrowNorthEast,o.viewportStickyNorth]}}class Sy extends lr{static get requires(){return[Fb]}static get pluginName(){return"ImageTextAlternativeUI"}init(){this._createButton()}destroy(){super.destroy(),this._form&&this._form.destroy()}_createButton(){const e=this.editor,t=e.t;e.ui.componentFactory.add("imageTextAlternative",(o=>{const n=e.commands.get("imageTextAlternative"),i=new Em(o);return i.set({label:t("Change image text alternative"),icon:qh.textAlternative,tooltip:!0}),i.bind("isEnabled").to(n,"isEnabled"),i.bind("isOn").to(n,"value",(e=>!!e)),this.listenTo(i,"execute",(()=>{this._showForm()})),i}))}_createForm(){const e=this.editor,t=e.editing.view.document,o=e.plugins.get("ImageUtils");this._balloon=this.editor.plugins.get("ContextualBalloon"),this._form=new(fm(Dy))(e.locale),this._form.render(),this.listenTo(this._form,"submit",(()=>{e.execute("imageTextAlternative",{newValue:this._form.labeledInput.fieldView.element.value}),this._hideForm(!0)})),this.listenTo(this._form,"cancel",(()=>{this._hideForm(!0)})),this._form.keystrokes.set("Esc",((e,t)=>{this._hideForm(!0),t()})),this.listenTo(e.ui,"update",(()=>{o.getClosestSelectedImageWidget(t.selection)?this._isVisible&&function(e){const t=e.plugins.get("ContextualBalloon");if(e.plugins.get("ImageUtils").getClosestSelectedImageWidget(e.editing.view.document.selection)){const o=By(e);t.updatePosition(o)}}(e):this._hideForm(!0)})),gm({emitter:this._form,activator:()=>this._isVisible,contextElements:()=>[this._balloon.view.element],callback:()=>this._hideForm()})}_showForm(){if(this._isVisible)return;this._form||this._createForm();const e=this.editor,t=e.commands.get("imageTextAlternative"),o=this._form.labeledInput;this._form.disableCssTransitions(),this._isInBalloon||this._balloon.add({view:this._form,position:By(e)}),o.fieldView.value=o.fieldView.element.value=t.value||"",this._form.labeledInput.fieldView.select(),this._form.enableCssTransitions()}_hideForm(e=!1){this._isInBalloon&&(this._form.focusTracker.isFocused&&this._form.saveButtonView.focus(),this._balloon.remove(this._form),e&&this.editor.editing.view.focus())}get _isVisible(){return!!this._balloon&&this._balloon.visibleView===this._form}get _isInBalloon(){return!!this._balloon&&this._balloon.hasView(this._form)}}class Ty extends lr{static get requires(){return[Ay,Sy]}static get pluginName(){return"ImageTextAlternative"}}function Iy(e,t){const o=(t,o,n)=>{if(!n.consumable.consume(o.item,t.name))return;const i=n.writer,r=n.mapper.toViewElement(o.item),s=e.findViewImgElement(r);null===o.attributeNewValue?(i.removeAttribute("srcset",s),i.removeAttribute("sizes",s)):o.attributeNewValue&&(i.setAttribute("srcset",o.attributeNewValue,s),i.setAttribute("sizes","100vw",s))};return e=>{e.on(`attribute:srcset:${t}`,o)}}function Py(e,t,o){const n=(t,o,n)=>{if(!n.consumable.consume(o.item,t.name))return;const i=n.writer,r=n.mapper.toViewElement(o.item),s=e.findViewImgElement(r);i.setAttribute(o.attributeKey,o.attributeNewValue||"",s)};return e=>{e.on(`attribute:${o}:${t}`,n)}}class Fy extends za{observe(e){this.listenTo(e,"load",((e,t)=>{const o=t.target;this.checkShouldIgnoreEventFromTarget(o)||"IMG"==o.tagName&&this._fireEvents(t)}),{useCapture:!0})}stopObserving(e){this.stopListening(e)}_fireEvents(e){this.isEnabled&&(this.document.fire("layoutChanged"),this.document.fire("imageLoaded",e))}}class My extends dr{constructor(e){super(e);const t=e.config.get("image.insert.type");e.plugins.has("ImageBlockEditing")||"block"===t&&D("image-block-plugin-required"),e.plugins.has("ImageInlineEditing")||"inline"===t&&D("image-inline-plugin-required")}refresh(){const e=this.editor.plugins.get("ImageUtils");this.isEnabled=e.isImageAllowed()}execute(e){const t=xi(e.source),o=this.editor.model.document.selection,n=this.editor.plugins.get("ImageUtils"),i=Object.fromEntries(o.getAttributes());t.forEach(((e,t)=>{const r=o.getSelectedElement();if("string"==typeof e&&(e={src:e}),t&&r&&n.isImage(r)){const t=this.editor.model.createPositionAfter(r);n.insertImage({...e,...i},t)}else n.insertImage({...e,...i})}))}}class Ry extends dr{constructor(e){super(e),this.decorate("cleanupImage")}refresh(){const e=this.editor.plugins.get("ImageUtils"),t=this.editor.model.document.selection.getSelectedElement();this.isEnabled=e.isImage(t),this.value=this.isEnabled?t.getAttribute("src"):null}execute(e){const t=this.editor.model.document.selection.getSelectedElement(),o=this.editor.plugins.get("ImageUtils");this.editor.model.change((n=>{n.setAttribute("src",e.source,t),this.cleanupImage(n,t),o.setImageNaturalSizeAttributes(t)}))}cleanupImage(e,t){e.removeAttribute("srcset",t),e.removeAttribute("sizes",t),e.removeAttribute("sources",t),e.removeAttribute("width",t),e.removeAttribute("height",t),e.removeAttribute("alt",t)}}class zy extends lr{static get requires(){return[wy]}static get pluginName(){return"ImageEditing"}init(){const e=this.editor,t=e.conversion;e.editing.view.addObserver(Fy),t.for("upcast").attributeToAttribute({view:{name:"img",key:"alt"},model:"alt"}).attributeToAttribute({view:{name:"img",key:"srcset"},model:"srcset"});const o=new My(e),n=new Ry(e);e.commands.add("insertImage",o),e.commands.add("replaceImageSource",n),e.commands.add("imageInsert",o)}}class Vy extends lr{static get requires(){return[wy]}static get pluginName(){return"ImageSizeAttributes"}afterInit(){this._registerSchema(),this._registerConverters("imageBlock"),this._registerConverters("imageInline")}_registerSchema(){this.editor.plugins.has("ImageBlockEditing")&&this.editor.model.schema.extend("imageBlock",{allowAttributes:["width","height"]}),this.editor.plugins.has("ImageInlineEditing")&&this.editor.model.schema.extend("imageInline",{allowAttributes:["width","height"]})}_registerConverters(e){const t=this.editor,o=t.plugins.get("ImageUtils"),n="imageBlock"===e?"figure":"img";function i(t,n,i,r){t.on(`attribute:${n}:${e}`,((t,n,s)=>{if(!s.consumable.consume(n.item,t.name))return;const a=s.writer,l=s.mapper.toViewElement(n.item),c=o.findViewImgElement(l);if(null!==n.attributeNewValue?a.setAttribute(i,n.attributeNewValue,c):a.removeAttribute(i,c),n.item.hasAttribute("sources"))return;const d=n.item.hasAttribute("resizedWidth");if("imageInline"===e&&!d&&!r)return;const u=n.item.getAttribute("width"),h=n.item.getAttribute("height");u&&h&&a.setStyle("aspect-ratio",`${u}/${h}`,c)}))}t.conversion.for("upcast").attributeToAttribute({view:{name:n,styles:{width:/.+/}},model:{key:"width",value:e=>by(e)?fy(e.getStyle("width")):null}}).attributeToAttribute({view:{name:n,key:"width"},model:"width"}).attributeToAttribute({view:{name:n,styles:{height:/.+/}},model:{key:"height",value:e=>by(e)?fy(e.getStyle("height")):null}}).attributeToAttribute({view:{name:n,key:"height"},model:"height"}),t.conversion.for("editingDowncast").add((e=>{i(e,"width","width",!0),i(e,"height","height",!0)})),t.conversion.for("dataDowncast").add((e=>{i(e,"width","width",!1),i(e,"height","height",!1)}))}}class Oy extends dr{constructor(e,t){super(e),this._modelElementName=t}refresh(){const e=this.editor.plugins.get("ImageUtils"),t=e.getClosestSelectedImageElement(this.editor.model.document.selection);"imageBlock"===this._modelElementName?this.isEnabled=e.isInlineImage(t):this.isEnabled=e.isBlockImage(t)}execute(e={}){const t=this.editor,o=this.editor.model,n=t.plugins.get("ImageUtils"),i=n.getClosestSelectedImageElement(o.document.selection),r=Object.fromEntries(i.getAttributes());return r.src||r.uploadId?o.change((t=>{const{setImageSizes:s=!0}=e,a=Array.from(o.markers).filter((e=>e.getRange().containsItem(i))),l=n.insertImage(r,o.createSelection(i,"on"),this._modelElementName,{setImageSizes:s});if(!l)return null;const c=t.createRangeOn(l);for(const e of a){const o=e.getRange(),n="$graveyard"!=o.root.rootName?o.getJoined(c,!0):c;t.updateMarker(e,{range:n})}return{oldElement:i,newElement:l}})):null}}var Ny=i(1091),Ly={attributes:{"data-cke":!0}};Ly.setAttributes=Ar(),Ly.insert=_r().bind(null,"head"),Ly.domAPI=kr(),Ly.insertStyleElement=vr();fr()(Ny.A,Ly);Ny.A&&Ny.A.locals&&Ny.A.locals;class Hy extends lr{static get requires(){return[wy]}static get pluginName(){return"ImagePlaceholder"}afterInit(){this._setupSchema(),this._setupConversion(),this._setupLoadListener()}_setupSchema(){const e=this.editor.model.schema;e.isRegistered("imageBlock")&&e.extend("imageBlock",{allowAttributes:["placeholder"]}),e.isRegistered("imageInline")&&e.extend("imageInline",{allowAttributes:["placeholder"]})}_setupConversion(){const e=this.editor,t=e.conversion,o=e.plugins.get("ImageUtils");t.for("editingDowncast").add((e=>{e.on("attribute:placeholder",((e,t,n)=>{if(!n.consumable.test(t.item,e.name))return;if(!t.item.is("element","imageBlock")&&!t.item.is("element","imageInline"))return;n.consumable.consume(t.item,e.name);const i=n.writer,r=n.mapper.toViewElement(t.item),s=o.findViewImgElement(r);t.attributeNewValue?(i.addClass("image_placeholder",s),i.setStyle("background-image",`url(${t.attributeNewValue})`,s),i.setCustomProperty("editingPipeline:doNotReuseOnce",!0,s)):(i.removeClass("image_placeholder",s),i.removeStyle("background-image",s))}))}))}_setupLoadListener(){const e=this.editor,t=e.model,o=e.editing,n=o.view,i=e.plugins.get("ImageUtils");n.addObserver(Fy),this.listenTo(n.document,"imageLoaded",((e,r)=>{const s=n.domConverter.mapDomToView(r.target);if(!s)return;const a=i.getImageWidgetFromImageView(s);if(!a)return;const l=o.mapper.toModelElement(a);l&&l.hasAttribute("placeholder")&&t.enqueueChange({isUndoable:!1},(e=>{e.removeAttribute("placeholder",l)}))}))}}class jy extends lr{static get requires(){return[zy,Vy,wy,Hy,H_]}static get pluginName(){return"ImageBlockEditing"}init(){const e=this.editor;e.model.schema.register("imageBlock",{inheritAllFrom:"$blockObject",allowAttributes:["alt","src","srcset"]}),this._setupConversion(),e.plugins.has("ImageInlineEditing")&&(e.commands.add("imageTypeBlock",new Oy(this.editor,"imageBlock")),this._setupClipboardIntegration())}_setupConversion(){const e=this.editor,t=e.t,o=e.conversion,n=e.plugins.get("ImageUtils");o.for("dataDowncast").elementToStructure({model:"imageBlock",view:(e,{writer:t})=>my(t)}),o.for("editingDowncast").elementToStructure({model:"imageBlock",view:(e,{writer:o})=>n.toImageWidget(my(o),o,t("image widget"))}),o.for("downcast").add(Py(n,"imageBlock","src")).add(Py(n,"imageBlock","alt")).add(Iy(n,"imageBlock")),o.for("upcast").elementToElement({view:py(e,"imageBlock"),model:(e,{writer:t})=>t.createElement("imageBlock",e.hasAttribute("src")?{src:e.getAttribute("src")}:void 0)}).add(function(e){const t=(t,o,n)=>{if(!n.consumable.test(o.viewItem,{name:!0,classes:"image"}))return;const i=e.findViewImgElement(o.viewItem);if(!i||!n.consumable.test(i,{name:!0}))return;n.consumable.consume(o.viewItem,{name:!0,classes:"image"});const r=Qi(n.convertItem(i,o.modelCursor).modelRange.getItems());r?(n.convertChildren(o.viewItem,r),n.updateConversionResult(r,o)):n.consumable.revert(o.viewItem,{name:!0,classes:"image"})};return e=>{e.on("element:figure",t)}}(n))}_setupClipboardIntegration(){const e=this.editor,t=e.model,o=e.editing.view,n=e.plugins.get("ImageUtils"),i=e.plugins.get("ClipboardPipeline");this.listenTo(i,"inputTransformation",((i,r)=>{const s=Array.from(r.content.getChildren());let a;if(!s.every(n.isInlineImageView))return;a=r.targetRanges?e.editing.mapper.toModelRange(r.targetRanges[0]):t.document.selection.getFirstRange();const l=t.createSelection(a);if("imageBlock"===gy(t.schema,l)){const e=new Lu(o.document),t=s.map((t=>e.createElement("figure",{class:"image"},t)));r.content=e.createDocumentFragment(t)}})),this.listenTo(i,"contentInsertion",((e,o)=>{"paste"===o.method&&t.change((e=>{const t=e.createRangeIn(o.content);for(const e of t.getItems())e.is("element","imageBlock")&&n.setImageNaturalSizeAttributes(e)}))}))}}var qy=i(1545),Uy={attributes:{"data-cke":!0}};Uy.setAttributes=Ar(),Uy.insert=_r().bind(null,"head"),Uy.domAPI=kr(),Uy.insertStyleElement=vr();fr()(qy.A,Uy);qy.A&&qy.A.locals&&qy.A.locals;class Wy extends pm{constructor(e,t=[]){super(e),this.focusTracker=new Xi,this.keystrokes=new er,this._focusables=new Uh,this.children=this.createCollection(),this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}});for(const e of t)this.children.add(e),this._focusables.add(e),e instanceof xp&&this._focusables.addMany(e.children);this.setTemplate({tag:"form",attributes:{class:["ck","ck-image-insert-form"],tabindex:-1},children:this.children})}render(){super.render(),bm({view:this});for(const e of this._focusables)this.focusTracker.add(e.element);this.keystrokes.listenTo(this.element);const e=e=>e.stopPropagation();this.keystrokes.set("arrowright",e),this.keystrokes.set("arrowleft",e),this.keystrokes.set("arrowup",e),this.keystrokes.set("arrowdown",e)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this._focusCycler.focusFirst()}}class $y extends lr{static get pluginName(){return"ImageInsertUI"}static get requires(){return[wy]}constructor(e){super(e),this._integrations=new Map,e.config.define("image.insert.integrations",["upload","assetManager","url"])}init(){const e=this.editor,t=e.model.document.selection,o=e.plugins.get("ImageUtils");this.set("isImageSelected",!1),this.listenTo(e.model.document,"change",(()=>{this.isImageSelected=o.isImage(t.getSelectedElement())}));const n=e=>this._createToolbarComponent(e);e.ui.componentFactory.add("insertImage",n),e.ui.componentFactory.add("imageInsert",n),e.ui.componentFactory.add("menuBar:insertImage",(e=>this._createMenuBarComponent(e)))}registerIntegration({name:e,observable:t,buttonViewCreator:o,formViewCreator:n,menuBarButtonViewCreator:i,requiresForm:r=!1}){this._integrations.has(e)&&D("image-insert-integration-exists",{name:e}),this._integrations.set(e,{observable:t,buttonViewCreator:o,menuBarButtonViewCreator:i,formViewCreator:n,requiresForm:r})}_createToolbarComponent(e){const t=this.editor,o=e.t,n=this._prepareIntegrations();if(!n.length)return null;let i;const r=n[0];if(1==n.length){if(!r.requiresForm)return r.buttonViewCreator(!0);i=r.buttonViewCreator(!0)}else{const t=r.buttonViewCreator(!1);i=new yg(e,t),i.tooltip=!0,i.bind("label").to(this,"isImageSelected",(e=>o(e?"Replace image":"Insert image")))}const s=this.dropdownView=Eg(e,i),a=n.map((({observable:e})=>"function"==typeof e?e():e));return s.bind("isEnabled").toMany(a,"isEnabled",((...e)=>e.some((e=>e)))),s.once("change:isOpen",(()=>{const e=n.map((({formViewCreator:e})=>e(1==n.length))),o=new Wy(t.locale,e);s.panelView.children.add(o)})),s}_createMenuBarComponent(e){const t=e.t,o=this._prepareIntegrations();if(!o.length)return null;let n;const i=o[0];if(1==o.length)n=i.menuBarButtonViewCreator(!0);else{n=new mk(e);const i=new pk(e);n.panelView.children.add(i),n.buttonView.set({icon:qh.image,label:t("Image")});for(const t of o){const o=new nb(e,n),r=t.menuBarButtonViewCreator(!1);o.children.add(r),i.items.add(o)}}return n}_prepareIntegrations(){const e=this.editor.config.get("image.insert.integrations"),t=[];if(!e.length)return D("image-insert-integrations-not-specified"),t;for(const o of e)this._integrations.has(o)?t.push(this._integrations.get(o)):["upload","assetManager","url"].includes(o)||D("image-insert-unknown-integration",{item:o});return t.length||D("image-insert-integrations-not-registered"),t}}var Gy=i(8574),Ky={attributes:{"data-cke":!0}};Ky.setAttributes=Ar(),Ky.insert=_r().bind(null,"head"),Ky.domAPI=kr(),Ky.insertStyleElement=vr();fr()(Gy.A,Ky);Gy.A&&Gy.A.locals&&Gy.A.locals;class Zy extends lr{static get requires(){return[zy,Vy,wy,Hy,H_]}static get pluginName(){return"ImageInlineEditing"}init(){const e=this.editor;e.model.schema.register("imageInline",{inheritAllFrom:"$inlineObject",allowAttributes:["alt","src","srcset"],disallowIn:["caption"]}),this._setupConversion(),e.plugins.has("ImageBlockEditing")&&(e.commands.add("imageTypeInline",new Oy(this.editor,"imageInline")),this._setupClipboardIntegration())}_setupConversion(){const e=this.editor,t=e.t,o=e.conversion,n=e.plugins.get("ImageUtils");o.for("dataDowncast").elementToElement({model:"imageInline",view:(e,{writer:t})=>t.createEmptyElement("img")}),o.for("editingDowncast").elementToStructure({model:"imageInline",view:(e,{writer:o})=>n.toImageWidget(function(e){return e.createContainerElement("span",{class:"image-inline"},e.createEmptyElement("img"))}(o),o,t("image widget"))}),o.for("downcast").add(Py(n,"imageInline","src")).add(Py(n,"imageInline","alt")).add(Iy(n,"imageInline")),o.for("upcast").elementToElement({view:py(e,"imageInline"),model:(e,{writer:t})=>t.createElement("imageInline",e.hasAttribute("src")?{src:e.getAttribute("src")}:void 0)})}_setupClipboardIntegration(){const e=this.editor,t=e.model,o=e.editing.view,n=e.plugins.get("ImageUtils"),i=e.plugins.get("ClipboardPipeline");this.listenTo(i,"inputTransformation",((i,r)=>{const s=Array.from(r.content.getChildren());let a;if(!s.every(n.isBlockImageView))return;a=r.targetRanges?e.editing.mapper.toModelRange(r.targetRanges[0]):t.document.selection.getFirstRange();const l=t.createSelection(a);if("imageInline"===gy(t.schema,l)){const e=new Lu(o.document),t=s.map((t=>1===t.childCount?(Array.from(t.getAttributes()).forEach((o=>e.setAttribute(...o,n.findViewImgElement(t)))),t.getChild(0)):t));r.content=e.createDocumentFragment(t)}})),this.listenTo(i,"contentInsertion",((e,o)=>{"paste"===o.method&&t.change((e=>{const t=e.createRangeIn(o.content);for(const e of t.getItems())e.is("element","imageInline")&&n.setImageNaturalSizeAttributes(e)}))}))}}class Jy extends lr{static get pluginName(){return"ImageCaptionUtils"}static get requires(){return[wy]}getCaptionFromImageModelElement(e){for(const t of e.getChildren())if(t&&t.is("element","caption"))return t;return null}getCaptionFromModelSelection(e){const t=this.editor.plugins.get("ImageUtils"),o=e.getFirstPosition().findAncestor("caption");return o&&t.isBlockImage(o.parent)?o:null}matchImageCaptionViewElement(e){const t=this.editor.plugins.get("ImageUtils");return"figcaption"==e.name&&t.isBlockImageView(e.parent)?{name:!0}:null}}class Yy extends dr{refresh(){const e=this.editor,t=e.plugins.get("ImageCaptionUtils"),o=e.plugins.get("ImageUtils");if(!e.plugins.has(jy))return this.isEnabled=!1,void(this.value=!1);const n=e.model.document.selection,i=n.getSelectedElement();if(!i){const e=t.getCaptionFromModelSelection(n);return this.isEnabled=!!e,void(this.value=!!e)}this.isEnabled=o.isImage(i),this.isEnabled?this.value=!!t.getCaptionFromImageModelElement(i):this.value=!1}execute(e={}){const{focusCaptionOnShow:t}=e;this.editor.model.change((e=>{this.value?this._hideImageCaption(e):this._showImageCaption(e,t)}))}_showImageCaption(e,t){const o=this.editor.model.document.selection,n=this.editor.plugins.get("ImageCaptionEditing"),i=this.editor.plugins.get("ImageUtils");let r=o.getSelectedElement();const s=n._getSavedCaption(r);i.isInlineImage(r)&&(this.editor.execute("imageTypeBlock"),r=o.getSelectedElement());const a=s||e.createElement("caption");e.append(a,r),t&&e.setSelection(a,"in")}_hideImageCaption(e){const t=this.editor,o=t.model.document.selection,n=t.plugins.get("ImageCaptionEditing"),i=t.plugins.get("ImageCaptionUtils");let r,s=o.getSelectedElement();s?r=i.getCaptionFromImageModelElement(s):(r=i.getCaptionFromModelSelection(o),s=r.parent),n._saveCaption(s,r),e.setSelection(s,"on"),e.remove(r)}}class Qy extends lr{static get requires(){return[wy,Jy]}static get pluginName(){return"ImageCaptionEditing"}constructor(e){super(e),this._savedCaptionsMap=new WeakMap}init(){const e=this.editor,t=e.model.schema;t.isRegistered("caption")?t.extend("caption",{allowIn:"imageBlock"}):t.register("caption",{allowIn:"imageBlock",allowContentOf:"$block",isLimit:!0}),e.commands.add("toggleImageCaption",new Yy(this.editor)),this._setupConversion(),this._setupImageTypeCommandsIntegration(),this._registerCaptionReconversion()}_setupConversion(){const e=this.editor,t=e.editing.view,o=e.plugins.get("ImageUtils"),n=e.plugins.get("ImageCaptionUtils"),i=e.t;e.conversion.for("upcast").elementToElement({view:e=>n.matchImageCaptionViewElement(e),model:"caption"}),e.conversion.for("dataDowncast").elementToElement({model:"caption",view:(e,{writer:t})=>o.isBlockImage(e.parent)?t.createContainerElement("figcaption"):null}),e.conversion.for("editingDowncast").elementToElement({model:"caption",view:(e,{writer:n})=>{if(!o.isBlockImage(e.parent))return null;const r=n.createEditableElement("figcaption");n.setCustomProperty("imageCaption",!0,r),r.placeholder=i("Enter image caption"),Sr({view:t,element:r,keepOnFocus:!0});const s=e.parent.getAttribute("alt");return Lk(r,n,{label:s?i("Caption for image: %0",[s]):i("Caption for the image")})}})}_setupImageTypeCommandsIntegration(){const e=this.editor,t=e.plugins.get("ImageUtils"),o=e.plugins.get("ImageCaptionUtils"),n=e.commands.get("imageTypeInline"),i=e.commands.get("imageTypeBlock"),r=e=>{if(!e.return)return;const{oldElement:n,newElement:i}=e.return;if(!n)return;if(t.isBlockImage(n)){const e=o.getCaptionFromImageModelElement(n);if(e)return void this._saveCaption(i,e)}const r=this._getSavedCaption(n);r&&this._saveCaption(i,r)};n&&this.listenTo(n,"execute",r,{priority:"low"}),i&&this.listenTo(i,"execute",r,{priority:"low"})}_getSavedCaption(e){const t=this._savedCaptionsMap.get(e);return t?Ll.fromJSON(t):null}_saveCaption(e,t){this._savedCaptionsMap.set(e,t.toJSON())}_registerCaptionReconversion(){const e=this.editor,t=e.model,o=e.plugins.get("ImageUtils"),n=e.plugins.get("ImageCaptionUtils");t.document.on("change:data",(()=>{const i=t.document.differ.getChanges();for(const t of i){if("alt"!==t.attributeKey)continue;const i=t.range.start.nodeAfter;if(o.isBlockImage(i)){const t=n.getCaptionFromImageModelElement(i);if(!t)return;e.editing.reconvertItem(t)}}}))}}class Xy extends lr{static get requires(){return[Jy]}static get pluginName(){return"ImageCaptionUI"}init(){const e=this.editor,t=e.editing.view,o=e.plugins.get("ImageCaptionUtils"),n=e.t;e.ui.componentFactory.add("toggleImageCaption",(i=>{const r=e.commands.get("toggleImageCaption"),s=new Em(i);return s.set({icon:qh.caption,tooltip:!0,isToggleable:!0}),s.bind("isOn","isEnabled").to(r,"value","isEnabled"),s.bind("label").to(r,"value",(e=>n(e?"Toggle caption off":"Toggle caption on"))),this.listenTo(s,"execute",(()=>{e.execute("toggleImageCaption",{focusCaptionOnShow:!0});const n=o.getCaptionFromModelSelection(e.model.document.selection);if(n){const o=e.editing.mapper.toViewElement(n);t.scrollToTheSelection(),t.change((e=>{e.addClass("image__caption_highlighted",o)}))}e.editing.view.focus()})),s}))}}var eA=i(3038),tA={attributes:{"data-cke":!0}};tA.setAttributes=Ar(),tA.insert=_r().bind(null,"head"),tA.domAPI=kr(),tA.insertStyleElement=vr();fr()(eA.A,tA);eA.A&&eA.A.locals&&eA.A.locals;function oA(e){const t=e.map((e=>e.replace("+","\\+")));return new RegExp(`^image\\/(${t.join("|")})$`)}function nA(e){return new Promise(((o,n)=>{const i=e.getAttribute("src");fetch(i).then((e=>e.blob())).then((e=>{const t=iA(e,i),n=t.replace("image/",""),r=new File([e],`image.${n}`,{type:t});o(r)})).catch((e=>e&&"TypeError"===e.name?function(e){return function(e){return new Promise(((o,n)=>{const i=t.document.createElement("img");i.addEventListener("load",(()=>{const e=t.document.createElement("canvas");e.width=i.width,e.height=i.height;e.getContext("2d").drawImage(i,0,0),e.toBlob((e=>e?o(e):n()))})),i.addEventListener("error",(()=>n())),i.src=e}))}(e).then((t=>{const o=iA(t,e),n=o.replace("image/","");return new File([t],`image.${n}`,{type:o})}))}(i).then(o).catch(n):n(e)))}))}function iA(e,t){return e.type?e.type:t.match(/data:(image\/\w+);base64/)?t.match(/data:(image\/\w+);base64/)[1].toLowerCase():"image/jpeg"}class rA extends lr{static get pluginName(){return"ImageUploadUI"}init(){const e=this.editor;e.ui.componentFactory.add("uploadImage",(()=>this._createToolbarButton())),e.ui.componentFactory.add("imageUpload",(()=>this._createToolbarButton())),e.ui.componentFactory.add("menuBar:uploadImage",(()=>this._createMenuBarButton("standalone"))),e.plugins.has("ImageInsertUI")&&e.plugins.get("ImageInsertUI").registerIntegration({name:"upload",observable:()=>e.commands.get("uploadImage"),buttonViewCreator:()=>this._createToolbarButton(),formViewCreator:()=>this._createDropdownButton(),menuBarButtonViewCreator:e=>this._createMenuBarButton(e?"insertOnly":"insertNested")})}_createButton(e){const t=this.editor,o=t.locale,n=t.commands.get("uploadImage"),i=t.config.get("image.upload.types"),r=oA(i),s=new e(t.locale),a=o.t;return s.set({acceptedType:i.map((e=>`image/${e}`)).join(","),allowMultipleFiles:!0,label:a("Upload from computer"),icon:qh.imageUpload}),s.bind("isEnabled").to(n),s.on("done",((e,o)=>{const n=Array.from(o).filter((e=>r.test(e.type)));n.length&&(t.execute("uploadImage",{file:n}),t.editing.view.focus())})),s}_createToolbarButton(){const e=this.editor.locale.t,t=this.editor.plugins.get("ImageInsertUI"),o=this.editor.commands.get("uploadImage"),n=this._createButton(kp);return n.tooltip=!0,n.bind("label").to(t,"isImageSelected",o,"isAccessAllowed",((t,o)=>e(o?t?"Replace image from computer":"Upload image from computer":"You have no image upload permissions."))),n}_createDropdownButton(){const e=this.editor.locale.t,t=this.editor.plugins.get("ImageInsertUI"),o=this._createButton(kp);return o.withText=!0,o.bind("label").to(t,"isImageSelected",(t=>e(t?"Replace from computer":"Upload from computer"))),o.on("execute",(()=>{t.dropdownView.isOpen=!1})),o}_createMenuBarButton(e){const t=this.editor.locale.t,o=this._createButton(fk);switch(o.withText=!0,e){case"standalone":o.label=t("Image from computer");break;case"insertOnly":o.label=t("Image");break;case"insertNested":o.label=t("From computer")}return o}}var sA=i(7504),aA={attributes:{"data-cke":!0}};aA.setAttributes=Ar(),aA.insert=_r().bind(null,"head"),aA.domAPI=kr(),aA.insertStyleElement=vr();fr()(sA.A,aA);sA.A&&sA.A.locals&&sA.A.locals;var lA=i(1230),cA={attributes:{"data-cke":!0}};cA.setAttributes=Ar(),cA.insert=_r().bind(null,"head"),cA.domAPI=kr(),cA.insertStyleElement=vr();fr()(lA.A,cA);lA.A&&lA.A.locals&&lA.A.locals;var dA=i(1160),uA={attributes:{"data-cke":!0}};uA.setAttributes=Ar(),uA.insert=_r().bind(null,"head"),uA.domAPI=kr(),uA.insertStyleElement=vr();fr()(dA.A,uA);dA.A&&dA.A.locals&&dA.A.locals;class hA extends lr{static get pluginName(){return"ImageUploadProgress"}constructor(e){super(e),this.uploadStatusChange=(e,t,o)=>{const n=this.editor,i=t.item,r=i.getAttribute("uploadId");if(!o.consumable.consume(t.item,e.name))return;const s=n.plugins.get("ImageUtils"),a=n.plugins.get(b_),l=r?t.attributeNewValue:null,c=this.placeholder,d=n.editing.mapper.toViewElement(i),u=o.writer;if("reading"==l)return mA(d,u),void pA(s,c,d,u);if("uploading"==l){const e=a.loaders.get(r);return mA(d,u),void(e?(gA(d,u),function(e,t,o,n){const i=function(e){const t=e.createUIElement("div",{class:"ck-progress-bar"});return e.setCustomProperty("progressBar",!0,t),t}(t);t.insert(t.createPositionAt(e,"end"),i),o.on("change:uploadedPercent",((e,t,o)=>{n.change((e=>{e.setStyle("width",o+"%",i)}))}))}(d,u,e,n.editing.view),function(e,t,o,n){if(n.data){const i=e.findViewImgElement(t);o.setAttribute("src",n.data,i)}}(s,d,u,e)):pA(s,c,d,u))}"complete"==l&&a.loaders.get(r)&&function(e,t,o){const n=t.createUIElement("div",{class:"ck-image-upload-complete-icon"});t.insert(t.createPositionAt(e,"end"),n),setTimeout((()=>{o.change((e=>e.remove(e.createRangeOn(n))))}),3e3)}(d,u,n.editing.view),function(e,t){bA(e,t,"progressBar")}(d,u),gA(d,u),function(e,t){t.removeClass("ck-appear",e)}(d,u)},this.placeholder="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw=="}init(){const e=this.editor;e.plugins.has("ImageBlockEditing")&&e.editing.downcastDispatcher.on("attribute:uploadStatus:imageBlock",this.uploadStatusChange),e.plugins.has("ImageInlineEditing")&&e.editing.downcastDispatcher.on("attribute:uploadStatus:imageInline",this.uploadStatusChange)}}function mA(e,t){e.hasClass("ck-appear")||t.addClass("ck-appear",e)}function pA(e,t,o,n){o.hasClass("ck-image-upload-placeholder")||n.addClass("ck-image-upload-placeholder",o);const i=e.findViewImgElement(o);i.getAttribute("src")!==t&&n.setAttribute("src",t,i),fA(o,"placeholder")||n.insert(n.createPositionAfter(i),function(e){const t=e.createUIElement("div",{class:"ck-upload-placeholder-loader"});return e.setCustomProperty("placeholder",!0,t),t}(n))}function gA(e,t){e.hasClass("ck-image-upload-placeholder")&&t.removeClass("ck-image-upload-placeholder",e),bA(e,t,"placeholder")}function fA(e,t){for(const o of e.getChildren())if(o.getCustomProperty(t))return o}function bA(e,t,o){const n=fA(e,o);n&&t.remove(t.createRangeOn(n))}class kA extends dr{constructor(e){super(e),this.set("isAccessAllowed",!0)}refresh(){const e=this.editor,t=e.plugins.get("ImageUtils"),o=e.model.document.selection.getSelectedElement();this.isEnabled=t.isImageAllowed()||t.isImage(o)}execute(e){const t=xi(e.file),o=this.editor.model.document.selection,n=this.editor.plugins.get("ImageUtils"),i=Object.fromEntries(o.getAttributes());t.forEach(((e,t)=>{const r=o.getSelectedElement();if(t&&r&&n.isImage(r)){const t=this.editor.model.createPositionAfter(r);this._uploadImage(e,i,t)}else this._uploadImage(e,i)}))}_uploadImage(e,t,o){const n=this.editor,i=n.plugins.get(b_).createLoader(e),r=n.plugins.get("ImageUtils");i&&r.insertImage({...t,uploadId:i.id},o)}}class wA extends lr{static get requires(){return[b_,Eb,H_,wy]}static get pluginName(){return"ImageUploadEditing"}constructor(e){super(e),e.config.define("image",{upload:{types:["jpeg","png","gif","bmp","webp","tiff"]}}),this._uploadImageElements=new Map}init(){const e=this.editor,t=e.model.document,o=e.conversion,n=e.plugins.get(b_),i=e.plugins.get("ImageUtils"),r=e.plugins.get("ClipboardPipeline"),s=oA(e.config.get("image.upload.types")),a=new kA(e);e.commands.add("uploadImage",a),e.commands.add("imageUpload",a),o.for("upcast").attributeToAttribute({view:{name:"img",key:"uploadId"},model:"uploadId"}),this.listenTo(e.editing.view.document,"clipboardInput",((t,o)=>{if(n=o.dataTransfer,Array.from(n.types).includes("text/html")&&""!==n.getData("text/html"))return;var n;const i=Array.from(o.dataTransfer.files).filter((e=>!!e&&s.test(e.type)));if(!i.length)return;t.stop(),e.model.change((t=>{o.targetRanges&&t.setSelection(o.targetRanges.map((t=>e.editing.mapper.toModelRange(t)))),e.execute("uploadImage",{file:i})}));if(!e.commands.get("uploadImage").isAccessAllowed){const t=e.plugins.get("Notification"),o=e.locale.t;t.showWarning(o("You have no image upload permissions."),{namespace:"image"})}})),this.listenTo(r,"inputTransformation",((t,o)=>{const r=Array.from(e.editing.view.createRangeIn(o.content)).map((e=>e.item)).filter((e=>function(e,t){return!(!e.isInlineImageView(t)||!t.getAttribute("src")||!t.getAttribute("src").match(/^data:image\/\w+;base64,/g)&&!t.getAttribute("src").match(/^blob:/g))}(i,e)&&!e.getAttribute("uploadProcessed"))).map((e=>({promise:nA(e),imageElement:e})));if(!r.length)return;const s=new Lu(e.editing.view.document);for(const e of r){s.setAttribute("uploadProcessed",!0,e.imageElement);const t=n.createLoader(e.promise);t&&(s.setAttribute("src","",e.imageElement),s.setAttribute("uploadId",t.id,e.imageElement))}})),e.editing.view.document.on("dragover",((e,t)=>{t.preventDefault()})),t.on("change",(()=>{const o=t.differ.getChanges({includeChangesInGraveyard:!0}).reverse(),i=new Set;for(const t of o)if("insert"==t.type&&"$text"!=t.name){const o=t.position.nodeAfter,r="$graveyard"==t.position.root.rootName;for(const t of _A(e,o)){const e=t.getAttribute("uploadId");if(!e)continue;const o=n.loaders.get(e);o&&(r?i.has(e)||o.abort():(i.add(e),this._uploadImageElements.set(e,t),"idle"==o.status&&this._readAndUpload(o)))}}})),this.on("uploadComplete",((e,{imageElement:t,data:o})=>{const n=o.urls?o.urls:o;this.editor.model.change((e=>{e.setAttribute("src",n.default,t),this._parseAndSetSrcsetAttributeOnImage(n,t,e),i.setImageNaturalSizeAttributes(t)}))}),{priority:"low"})}afterInit(){const e=this.editor.model.schema;this.editor.plugins.has("ImageBlockEditing")&&e.extend("imageBlock",{allowAttributes:["uploadId","uploadStatus"]}),this.editor.plugins.has("ImageInlineEditing")&&e.extend("imageInline",{allowAttributes:["uploadId","uploadStatus"]})}_readAndUpload(e){const t=this.editor,o=t.model,n=t.locale.t,i=t.plugins.get(b_),s=t.plugins.get(Eb),a=t.plugins.get("ImageUtils"),l=this._uploadImageElements;return o.enqueueChange({isUndoable:!1},(t=>{t.setAttribute("uploadStatus","reading",l.get(e.id))})),e.read().then((()=>{const i=e.upload(),s=l.get(e.id);if(r.isSafari){const e=t.editing.mapper.toViewElement(s),o=a.findViewImgElement(e);t.editing.view.once("render",(()=>{if(!o.parent)return;const e=t.editing.view.domConverter.mapViewToDom(o.parent);if(!e)return;const n=e.style.display;e.style.display="none",e._ckHack=e.offsetHeight,e.style.display=n}))}return t.ui&&t.ui.ariaLiveAnnouncer.announce(n("Uploading image")),o.enqueueChange({isUndoable:!1},(e=>{e.setAttribute("uploadStatus","uploading",s)})),i})).then((i=>{o.enqueueChange({isUndoable:!1},(o=>{const r=l.get(e.id);o.setAttribute("uploadStatus","complete",r),t.ui&&t.ui.ariaLiveAnnouncer.announce(n("Image upload complete")),this.fire("uploadComplete",{data:i,imageElement:r})})),c()})).catch((i=>{if(t.ui&&t.ui.ariaLiveAnnouncer.announce(n("Error during image upload")),"error"!==e.status&&"aborted"!==e.status)throw i;"error"==e.status&&i&&s.showWarning(i,{title:n("Upload failed"),namespace:"upload"}),o.enqueueChange({isUndoable:!1},(t=>{t.remove(l.get(e.id))})),c()}));function c(){o.enqueueChange({isUndoable:!1},(t=>{const o=l.get(e.id);t.removeAttribute("uploadId",o),t.removeAttribute("uploadStatus",o),l.delete(e.id)})),i.destroyLoader(e)}}_parseAndSetSrcsetAttributeOnImage(e,t,o){let n=0;const i=Object.keys(e).filter((e=>{const t=parseInt(e,10);if(!isNaN(t))return n=Math.max(n,t),!0})).map((t=>`${e[t]} ${t}w`)).join(", ");if(""!=i){const e={srcset:i};t.hasAttribute("width")||t.hasAttribute("height")||(e.width=n),o.setAttributes(e,t)}}}function _A(e,t){const o=e.plugins.get("ImageUtils");return Array.from(e.model.createRangeOn(t)).filter((e=>o.isImage(e.item))).map((e=>e.item))}class yA extends lr{static get pluginName(){return"ImageUpload"}static get requires(){return[wA,rA,hA]}}const AA=function(e,t){return function(o,n){if(null==o)return o;if(!ho(o))return e(o,n);for(var i=o.length,r=t?i:-1,s=Object(o);(t?r--:++r{t.setAttribute("resizedWidth",e.width,i),t.removeAttribute("resizedHeight",i),n.setImageNaturalSizeAttributes(i)}))}}class EA extends lr{static get requires(){return[wy]}static get pluginName(){return"ImageResizeEditing"}constructor(e){super(e),e.config.define("image",{resizeUnit:"%",resizeOptions:[{name:"resizeImage:original",value:null,icon:"original"},{name:"resizeImage:custom",value:"custom",icon:"custom"},{name:"resizeImage:25",value:"25",icon:"small"},{name:"resizeImage:50",value:"50",icon:"medium"},{name:"resizeImage:75",value:"75",icon:"large"}]})}init(){const e=this.editor,t=new xA(e);this._registerConverters("imageBlock"),this._registerConverters("imageInline"),e.commands.add("resizeImage",t),e.commands.add("imageResize",t)}afterInit(){this._registerSchema()}_registerSchema(){this.editor.plugins.has("ImageBlockEditing")&&this.editor.model.schema.extend("imageBlock",{allowAttributes:["resizedWidth","resizedHeight"]}),this.editor.plugins.has("ImageInlineEditing")&&this.editor.model.schema.extend("imageInline",{allowAttributes:["resizedWidth","resizedHeight"]})}_registerConverters(e){const t=this.editor,o=t.plugins.get("ImageUtils");t.conversion.for("downcast").add((t=>t.on(`attribute:resizedWidth:${e}`,((e,t,o)=>{if(!o.consumable.consume(t.item,e.name))return;const n=o.writer,i=o.mapper.toViewElement(t.item);null!==t.attributeNewValue?(n.setStyle("width",t.attributeNewValue,i),n.addClass("image_resized",i)):(n.removeStyle("width",i),n.removeClass("image_resized",i))})))),t.conversion.for("dataDowncast").attributeToAttribute({model:{name:e,key:"resizedHeight"},view:e=>({key:"style",value:{height:e}})}),t.conversion.for("editingDowncast").add((t=>t.on(`attribute:resizedHeight:${e}`,((t,n,i)=>{if(!i.consumable.consume(n.item,t.name))return;const r=i.writer,s=i.mapper.toViewElement(n.item),a="imageInline"===e?o.findViewImgElement(s):s;null!==n.attributeNewValue?r.setStyle("height",n.attributeNewValue,a):r.removeStyle("height",a)})))),t.conversion.for("upcast").attributeToAttribute({view:{name:"imageBlock"===e?"figure":"img",styles:{width:/.+/}},model:{key:"resizedWidth",value:e=>by(e)?null:e.getStyle("width")}}),t.conversion.for("upcast").attributeToAttribute({view:{name:"imageBlock"===e?"figure":"img",styles:{height:/.+/}},model:{key:"resizedHeight",value:e=>by(e)?null:e.getStyle("height")}})}}const DA=(()=>({small:qh.objectSizeSmall,medium:qh.objectSizeMedium,large:qh.objectSizeLarge,custom:qh.objectSizeCustom,original:qh.objectSizeFull}))();class BA extends lr{static get requires(){return[EA]}static get pluginName(){return"ImageResizeButtons"}constructor(e){super(e),this._resizeUnit=e.config.get("image.resizeUnit")}init(){const e=this.editor,t=e.config.get("image.resizeOptions"),o=e.commands.get("resizeImage");this.bind("isEnabled").to(o);for(const e of t)this._registerImageResizeButton(e);this._registerImageResizeDropdown(t)}_registerImageResizeButton(e){const t=this.editor,{name:o,value:n,icon:i}=e;t.ui.componentFactory.add(o,(o=>{const r=new Em(o),s=t.commands.get("resizeImage"),a=this._getOptionLabelValue(e,!0);if(!DA[i])throw new E("imageresizebuttons-missing-icon",t,e);if(r.set({label:a,icon:DA[i],tooltip:a,isToggleable:!0}),r.bind("isEnabled").to(this),t.plugins.has("ImageCustomResizeUI")&&SA(e)){const e=t.plugins.get("ImageCustomResizeUI");this.listenTo(r,"execute",(()=>{e._showForm(this._resizeUnit)}))}else{const e=n?n+this._resizeUnit:null;r.bind("isOn").to(s,"value",TA(e)),this.listenTo(r,"execute",(()=>{t.execute("resizeImage",{width:e})}))}return r}))}_registerImageResizeDropdown(e){const t=this.editor,o=t.t,n=e.find((e=>!e.value)),i=i=>{const r=t.commands.get("resizeImage"),s=Eg(i,og),a=s.buttonView,l=o("Resize image");return a.set({tooltip:l,commandValue:n.value,icon:DA.medium,isToggleable:!0,label:this._getOptionLabelValue(n),withText:!0,class:"ck-resize-image-button",ariaLabel:l,ariaLabelledBy:void 0}),a.bind("label").to(r,"value",(e=>e&&e.width?e.width:this._getOptionLabelValue(n))),s.bind("isEnabled").to(this),Sg(s,(()=>this._getResizeDropdownListItemDefinitions(e,r)),{ariaLabel:o("Image resize list"),role:"menu"}),this.listenTo(s,"execute",(e=>{"onClick"in e.source?e.source.onClick():(t.execute(e.source.commandName,{width:e.source.commandValue}),t.editing.view.focus())})),s};t.ui.componentFactory.add("resizeImage",i),t.ui.componentFactory.add("imageResize",i)}_getOptionLabelValue(e,t=!1){const o=this.editor.t;return e.label?e.label:t?SA(e)?o("Custom image size"):e.value?o("Resize image to %0",e.value+this._resizeUnit):o("Resize image to the original size"):SA(e)?o("Custom"):e.value?e.value+this._resizeUnit:o("Original")}_getResizeDropdownListItemDefinitions(e,t){const{editor:o}=this,n=new Yi,i=e.map((e=>SA(e)?{...e,valueWithUnits:"custom"}:e.value?{...e,valueWithUnits:`${e.value}${this._resizeUnit}`}:{...e,valueWithUnits:null}));for(const e of i){let r=null;if(o.plugins.has("ImageCustomResizeUI")&&SA(e)){const n=o.plugins.get("ImageCustomResizeUI");r={type:"button",model:new Db({label:this._getOptionLabelValue(e),role:"menuitemradio",withText:!0,icon:null,onClick:()=>{n._showForm(this._resizeUnit)}})};const s=vA(i,"valueWithUnits");r.model.bind("isOn").to(t,"value",IA(s))}else r={type:"button",model:new Db({commandName:"resizeImage",commandValue:e.valueWithUnits,label:this._getOptionLabelValue(e),role:"menuitemradio",withText:!0,icon:null})},r.model.bind("isOn").to(t,"value",TA(e.valueWithUnits));r.model.bind("isEnabled").to(t,"isEnabled"),n.add(r)}return n}}function SA(e){return"custom"===e.value}function TA(e){return t=>null===e&&t===e||null!==t&&t.width===e}function IA(e){return t=>!e.some((e=>TA(e)(t)))}const PA="image_resized";class FA extends lr{static get requires(){return[s_,wy]}static get pluginName(){return"ImageResizeHandles"}init(){const e=this.editor.commands.get("resizeImage");this.bind("isEnabled").to(e),this._setupResizerCreator()}_setupResizerCreator(){const e=this.editor,t=e.editing.view,o=e.plugins.get("ImageUtils");t.addObserver(Fy),this.listenTo(t.document,"imageLoaded",((n,i)=>{if(!i.target.matches("figure.image.ck-widget > img,figure.image.ck-widget > picture > img,figure.image.ck-widget > a > img,figure.image.ck-widget > a > picture > img,span.image-inline.ck-widget > img,span.image-inline.ck-widget > picture > img"))return;const r=e.editing.view.domConverter,s=r.domToView(i.target),a=o.getImageWidgetFromImageView(s);let l=this.editor.plugins.get(s_).getResizerByViewElement(a);if(l)return void l.redraw();const c=e.editing.mapper,d=c.toModelElement(a);l=e.plugins.get(s_).attachTo({unit:e.config.get("image.resizeUnit"),modelElement:d,viewElement:a,editor:e,getHandleHost:e=>e.querySelector("img"),getResizeHost:()=>r.mapViewToDom(c.toViewElement(d)),isCentered:()=>"alignCenter"==d.getAttribute("imageStyle"),onCommit(o){t.change((e=>{e.removeClass(PA,a)})),e.execute("resizeImage",{width:o})}}),l.on("updateSize",(()=>{a.hasClass(PA)||t.change((e=>{e.addClass(PA,a)}));const e="imageInline"===d.name?s:a;e.getStyle("height")&&t.change((t=>{t.removeStyle("height",e)}))})),l.bind("isEnabled").to(this)}))}}function MA(e){if(!e)return null;const[,t,o]=e.trim().match(/([.,\d]+)(%|px)$/)||[],n=Number.parseFloat(t);return Number.isNaN(n)?null:{value:n,unit:o}}function RA(e,t,o){return"px"===o?{value:t.value,unit:"px"}:{value:t.value/e*100,unit:"%"}}function zA(e){const{editing:t}=e,o=e.plugins.get("ImageUtils").getClosestSelectedImageElement(e.model.document.selection);if(!o)return null;const n=t.mapper.toViewElement(o);return{model:o,view:n,dom:t.view.domConverter.mapViewToDom(n)}}var VA=i(1173),OA={attributes:{"data-cke":!0}};OA.setAttributes=Ar(),OA.insert=_r().bind(null,"head"),OA.domAPI=kr(),OA.insertStyleElement=vr();fr()(VA.A,OA);VA.A&&VA.A.locals&&VA.A.locals;class NA extends pm{constructor(e,t,o){super(e);const n=this.locale.t;this.focusTracker=new Xi,this.keystrokes=new er,this.unit=t,this.labeledInput=this._createLabeledInputView(),this.saveButtonView=this._createButton(n("Save"),qh.check,"ck-button-save"),this.saveButtonView.type="submit",this.cancelButtonView=this._createButton(n("Cancel"),qh.cancel,"ck-button-cancel","cancel"),this._focusables=new Uh,this._validators=o,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.setTemplate({tag:"form",attributes:{class:["ck","ck-image-custom-resize-form","ck-responsive-form"],tabindex:"-1"},children:[this.labeledInput,this.saveButtonView,this.cancelButtonView]})}render(){super.render(),this.keystrokes.listenTo(this.element),bm({view:this}),[this.labeledInput,this.saveButtonView,this.cancelButtonView].forEach((e=>{this._focusables.add(e),this.focusTracker.add(e.element)}))}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}_createButton(e,t,o,n){const i=new Em(this.locale);return i.set({label:e,icon:t,tooltip:!0}),i.extendTemplate({attributes:{class:o}}),n&&i.delegate("execute").to(this,n),i}_createLabeledInputView(){const e=this.locale.t,t=new jp(this.locale,Mg);return t.label=e("Resize image (in %0)",this.unit),t.fieldView.set({step:.1}),t}isValid(){this.resetFormStatus();for(const e of this._validators){const t=e(this);if(t)return this.labeledInput.errorText=t,!1}return!0}resetFormStatus(){this.labeledInput.errorText=null}get rawSize(){const{element:e}=this.labeledInput.fieldView;return e?e.value:null}get parsedSize(){const{rawSize:e}=this;if(null===e)return null;const t=Number.parseFloat(e);return Number.isNaN(t)?null:t}get sizeWithUnits(){const{parsedSize:e,unit:t}=this;return null===e?null:`${e}${t}`}}class LA extends lr{static get requires(){return[Fb]}static get pluginName(){return"ImageCustomResizeUI"}destroy(){super.destroy(),this._form&&this._form.destroy()}_createForm(e){const t=this.editor;this._balloon=this.editor.plugins.get("ContextualBalloon"),this._form=new(fm(NA))(t.locale,e,function(e){const t=e.t;return[e=>""===e.rawSize.trim()?t("The value must not be empty."):null===e.parsedSize?t("The value should be a plain number."):void 0]}(t)),this._form.render(),this.listenTo(this._form,"submit",(()=>{this._form.isValid()&&(t.execute("resizeImage",{width:this._form.sizeWithUnits}),this._hideForm(!0))})),this.listenTo(this._form.labeledInput,"change:errorText",(()=>{t.ui.update()})),this.listenTo(this._form,"cancel",(()=>{this._hideForm(!0)})),this._form.keystrokes.set("Esc",((e,t)=>{this._hideForm(!0),t()})),gm({emitter:this._form,activator:()=>this._isVisible,contextElements:()=>[this._balloon.view.element],callback:()=>this._hideForm()})}_showForm(e){if(this._isVisible)return;this._form||this._createForm(e);const t=this.editor,o=this._form.labeledInput;this._form.disableCssTransitions(),this._form.resetFormStatus(),this._isInBalloon||this._balloon.add({view:this._form,position:By(t)});const n=function(e,t){const o=zA(e);if(!o)return null;const n=MA(o.model.getAttribute("resizedWidth")||null);return n?n.unit===t?n:RA(jk(o.dom),{unit:"px",value:new qn(o.dom).width},t):null}(t,e),i=n?n.value.toFixed(1):"",r=function(e,t){const o=zA(e);if(!o)return null;const n=jk(o.dom),i=MA(window.getComputedStyle(o.dom).minWidth)||{value:1,unit:"px"};return{unit:t,lower:Math.max(.1,RA(n,i,t).value),upper:"px"===t?n:100}}(t,e);o.fieldView.value=o.fieldView.element.value=i,r&&Object.assign(o.fieldView,{min:r.lower.toFixed(1),max:Math.ceil(r.upper).toFixed(1)}),this._form.labeledInput.fieldView.select(),this._form.enableCssTransitions()}_hideForm(e=!1){this._isInBalloon&&(this._form.focusTracker.isFocused&&this._form.saveButtonView.focus(),this._balloon.remove(this._form),e&&this.editor.editing.view.focus())}get _isVisible(){return!!this._balloon&&this._balloon.visibleView===this._form}get _isInBalloon(){return!!this._balloon&&this._balloon.hasView(this._form)}}var HA=i(4214),jA={attributes:{"data-cke":!0}};jA.setAttributes=Ar(),jA.insert=_r().bind(null,"head"),jA.domAPI=kr(),jA.insertStyleElement=vr();fr()(HA.A,jA);HA.A&&HA.A.locals&&HA.A.locals;class qA extends dr{constructor(e,t){super(e),this._defaultStyles={imageBlock:!1,imageInline:!1},this._styles=new Map(t.map((e=>{if(e.isDefault)for(const t of e.modelElements)this._defaultStyles[t]=e.name;return[e.name,e]})))}refresh(){const e=this.editor.plugins.get("ImageUtils").getClosestSelectedImageElement(this.editor.model.document.selection);this.isEnabled=!!e,this.isEnabled?e.hasAttribute("imageStyle")?this.value=e.getAttribute("imageStyle"):this.value=this._defaultStyles[e.name]:this.value=!1}execute(e={}){const t=this.editor,o=t.model,n=t.plugins.get("ImageUtils");o.change((t=>{const i=e.value,{setImageSizes:r=!0}=e;let s=n.getClosestSelectedImageElement(o.document.selection);i&&this.shouldConvertImageType(i,s)&&(this.editor.execute(n.isBlockImage(s)?"imageTypeInline":"imageTypeBlock",{setImageSizes:r}),s=n.getClosestSelectedImageElement(o.document.selection)),!i||this._styles.get(i).isDefault?t.removeAttribute("imageStyle",s):t.setAttribute("imageStyle",i,s),r&&n.setImageNaturalSizeAttributes(s)}))}shouldConvertImageType(e,t){return!this._styles.get(e).modelElements.includes(t.name)}}const UA={get inline(){return{name:"inline",title:"In line",icon:qh.objectInline,modelElements:["imageInline"],isDefault:!0}},get alignLeft(){return{name:"alignLeft",title:"Left aligned image",icon:qh.objectLeft,modelElements:["imageBlock","imageInline"],className:"image-style-align-left"}},get alignBlockLeft(){return{name:"alignBlockLeft",title:"Left aligned image",icon:qh.objectBlockLeft,modelElements:["imageBlock"],className:"image-style-block-align-left"}},get alignCenter(){return{name:"alignCenter",title:"Centered image",icon:qh.objectCenter,modelElements:["imageBlock"],className:"image-style-align-center"}},get alignRight(){return{name:"alignRight",title:"Right aligned image",icon:qh.objectRight,modelElements:["imageBlock","imageInline"],className:"image-style-align-right"}},get alignBlockRight(){return{name:"alignBlockRight",title:"Right aligned image",icon:qh.objectBlockRight,modelElements:["imageBlock"],className:"image-style-block-align-right"}},get block(){return{name:"block",title:"Centered image",icon:qh.objectCenter,modelElements:["imageBlock"],isDefault:!0}},get side(){return{name:"side",title:"Side image",icon:qh.objectRight,modelElements:["imageBlock"],className:"image-style-side"}}},WA=(()=>({full:qh.objectFullWidth,left:qh.objectBlockLeft,right:qh.objectBlockRight,center:qh.objectCenter,inlineLeft:qh.objectLeft,inlineRight:qh.objectRight,inline:qh.objectInline}))(),$A=[{name:"imageStyle:wrapText",title:"Wrap text",defaultItem:"imageStyle:alignLeft",items:["imageStyle:alignLeft","imageStyle:alignRight"]},{name:"imageStyle:breakText",title:"Break text",defaultItem:"imageStyle:block",items:["imageStyle:alignBlockLeft","imageStyle:block","imageStyle:alignBlockRight"]}];function GA(e){D("image-style-configuration-definition-invalid",e)}const KA={normalizeStyles:function(e){const t=(e.configuredStyles.options||[]).map((e=>function(e){e="string"==typeof e?UA[e]?{...UA[e]}:{name:e}:function(e,t){const o={...t};for(const n in e)Object.prototype.hasOwnProperty.call(t,n)||(o[n]=e[n]);return o}(UA[e.name],e);"string"==typeof e.icon&&(e.icon=WA[e.icon]||e.icon);return e}(e))).filter((t=>function(e,{isBlockPluginLoaded:t,isInlinePluginLoaded:o}){const{modelElements:n,name:i}=e;if(!(n&&n.length&&i))return GA({style:e}),!1;{const i=[t?"imageBlock":null,o?"imageInline":null];if(!n.some((e=>i.includes(e))))return D("image-style-missing-dependency",{style:e,missingPlugins:n.map((e=>"imageBlock"===e?"ImageBlockEditing":"ImageInlineEditing"))}),!1}return!0}(t,e)));return t},getDefaultStylesConfiguration:function(e,t){return e&&t?{options:["inline","alignLeft","alignRight","alignCenter","alignBlockLeft","alignBlockRight","block","side"]}:e?{options:["block","side"]}:t?{options:["inline","alignLeft","alignRight"]}:{}},getDefaultDropdownDefinitions:function(e){return e.has("ImageBlockEditing")&&e.has("ImageInlineEditing")?[...$A]:[]},warnInvalidStyle:GA,DEFAULT_OPTIONS:UA,DEFAULT_ICONS:WA,DEFAULT_DROPDOWN_DEFINITIONS:$A};function ZA(e,t){for(const o of t)if(o.name===e)return o}class JA extends lr{static get pluginName(){return"ImageStyleEditing"}static get requires(){return[wy]}init(){const{normalizeStyles:e,getDefaultStylesConfiguration:t}=KA,o=this.editor,n=o.plugins.has("ImageBlockEditing"),i=o.plugins.has("ImageInlineEditing");o.config.define("image.styles",t(n,i)),this.normalizedStyles=e({configuredStyles:o.config.get("image.styles"),isBlockPluginLoaded:n,isInlinePluginLoaded:i}),this._setupConversion(n,i),this._setupPostFixer(),o.commands.add("imageStyle",new qA(o,this.normalizedStyles))}_setupConversion(e,t){const o=this.editor,n=o.model.schema,i=(r=this.normalizedStyles,(e,t,o)=>{if(!o.consumable.consume(t.item,e.name))return;const n=ZA(t.attributeNewValue,r),i=ZA(t.attributeOldValue,r),s=o.mapper.toViewElement(t.item),a=o.writer;i&&a.removeClass(i.className,s),n&&a.addClass(n.className,s)});var r;const s=function(e){const t={imageInline:e.filter((e=>!e.isDefault&&e.modelElements.includes("imageInline"))),imageBlock:e.filter((e=>!e.isDefault&&e.modelElements.includes("imageBlock")))};return(e,o,n)=>{if(!o.modelRange)return;const i=o.viewItem,r=Qi(o.modelRange.getItems());if(r&&n.schema.checkAttribute(r,"imageStyle"))for(const e of t[r.name])n.consumable.consume(i,{classes:e.className})&&n.writer.setAttribute("imageStyle",e.name,r)}}(this.normalizedStyles);o.editing.downcastDispatcher.on("attribute:imageStyle",i),o.data.downcastDispatcher.on("attribute:imageStyle",i),e&&(n.extend("imageBlock",{allowAttributes:"imageStyle"}),o.data.upcastDispatcher.on("element:figure",s,{priority:"low"})),t&&(n.extend("imageInline",{allowAttributes:"imageStyle"}),o.data.upcastDispatcher.on("element:img",s,{priority:"low"}))}_setupPostFixer(){const e=this.editor,t=e.model.document,o=e.plugins.get(wy),n=new Map(this.normalizedStyles.map((e=>[e.name,e])));t.registerPostFixer((e=>{let i=!1;for(const r of t.differ.getChanges())if("insert"==r.type||"attribute"==r.type&&"imageStyle"==r.attributeKey){let t="insert"==r.type?r.position.nodeAfter:r.range.start.nodeAfter;if(t&&t.is("element","paragraph")&&t.childCount>0&&(t=t.getChild(0)),!o.isImage(t))continue;const s=t.getAttribute("imageStyle");if(!s)continue;const a=n.get(s);a&&a.modelElements.includes(t.name)||(e.removeAttribute("imageStyle",t),i=!0)}return i}))}}var YA=i(7879),QA={attributes:{"data-cke":!0}};QA.setAttributes=Ar(),QA.insert=_r().bind(null,"head"),QA.domAPI=kr(),QA.insertStyleElement=vr();fr()(YA.A,QA);YA.A&&YA.A.locals&&YA.A.locals;class XA extends lr{static get requires(){return[JA]}static get pluginName(){return"ImageStyleUI"}get localizedDefaultStylesTitles(){const e=this.editor.t;return{"Wrap text":e("Wrap text"),"Break text":e("Break text"),"In line":e("In line"),"Full size image":e("Full size image"),"Side image":e("Side image"),"Left aligned image":e("Left aligned image"),"Centered image":e("Centered image"),"Right aligned image":e("Right aligned image")}}init(){const e=this.editor.plugins,t=this.editor.config.get("image.toolbar")||[],o=eC(e.get("ImageStyleEditing").normalizedStyles,this.localizedDefaultStylesTitles);for(const e of o)this._createButton(e);const n=eC([...t.filter(U),...KA.getDefaultDropdownDefinitions(e)],this.localizedDefaultStylesTitles);for(const e of n)this._createDropdown(e,o)}_createDropdown(e,t){const o=this.editor.ui.componentFactory;o.add(e.name,(n=>{let i;const{defaultItem:r,items:s,title:a}=e,l=s.filter((e=>t.find((({name:t})=>tC(t)===e)))).map((e=>{const t=o.create(e);return e===r&&(i=t),t}));s.length!==l.length&&KA.warnInvalidStyle({dropdown:e});const c=Eg(n,yg),d=c.buttonView,u=d.arrowView;return Dg(c,l,{enableActiveItemFocusOnDropdownOpen:!0}),d.set({label:oC(a,i.label),class:null,tooltip:!0}),u.unbind("label"),u.set({label:a}),d.bind("icon").toMany(l,"isOn",((...e)=>{const t=e.findIndex(Fi);return t<0?i.icon:l[t].icon})),d.bind("label").toMany(l,"isOn",((...e)=>{const t=e.findIndex(Fi);return oC(a,t<0?i.label:l[t].label)})),d.bind("isOn").toMany(l,"isOn",((...e)=>e.some(Fi))),d.bind("class").toMany(l,"isOn",((...e)=>e.some(Fi)?"ck-splitbutton_flatten":void 0)),d.on("execute",(()=>{l.some((({isOn:e})=>e))?c.isOpen=!c.isOpen:i.fire("execute")})),c.bind("isEnabled").toMany(l,"isEnabled",((...e)=>e.some(Fi))),this.listenTo(c,"execute",(()=>{this.editor.editing.view.focus()})),c}))}_createButton(e){const t=e.name;this.editor.ui.componentFactory.add(tC(t),(o=>{const n=this.editor.commands.get("imageStyle"),i=new Em(o);return i.set({label:e.title,icon:e.icon,tooltip:!0,isToggleable:!0}),i.bind("isEnabled").to(n,"isEnabled"),i.bind("isOn").to(n,"value",(e=>e===t)),i.on("execute",this._executeCommand.bind(this,t)),i}))}_executeCommand(e){this.editor.execute("imageStyle",{value:e}),this.editor.editing.view.focus()}}function eC(e,t){for(const o of e)t[o.title]&&(o.title=t[o.title]);return e}function tC(e){return`imageStyle:${e}`}function oC(e,t){return(e?e+": ":"")+t}const nC=Symbol("isWpButtonMacroSymbol");function iC(e){const t=e.getSelectedElement();return!(!t||!function(e){return!!e.getCustomProperty(nC)&&Rk(e)}(t))}class rC extends lr{static get pluginName(){return"OPChildPagesEditing"}static get buttonName(){return"insertChildPages"}init(){const e=this.editor,t=e.model,o=e.conversion;t.schema.register("op-macro-child-pages",{allowWhere:["$block"],allowAttributes:["page"],isBlock:!0,isLimit:!0}),o.for("upcast").elementToElement({view:{name:"macro",classes:"child_pages"},model:(e,{writer:t})=>{const o=e.getAttribute("data-page")||"",n="true"==e.getAttribute("data-include-parent");return t.createElement("op-macro-child-pages",{page:o,includeParent:n})}}),o.for("editingDowncast").elementToElement({model:"op-macro-child-pages",view:(e,{writer:t})=>this.createMacroViewElement(e,t)}).add((e=>e.on("attribute:page",this.modelAttributeToView.bind(this)))).add((e=>e.on("attribute:includeParent",this.modelAttributeToView.bind(this)))),o.for("dataDowncast").elementToElement({model:"op-macro-child-pages",view:(e,{writer:t})=>t.createContainerElement("macro",{class:"child_pages","data-page":e.getAttribute("page")||"","data-include-parent":e.getAttribute("includeParent")||""})}),e.ui.componentFactory.add(rC.buttonName,(t=>{const o=new Em(t);return o.set({label:window.I18n.t("js.editor.macro.child_pages.button"),withText:!0}),o.on("execute",(()=>{e.model.change((t=>{const o=t.createElement("op-macro-child-pages",{});e.model.insertContent(o,e.model.document.selection)}))})),o}))}modelAttributeToView(e,t,o){const n=t.item;if(!n.is("element","op-macro-child-pages"))return;o.consumable.consume(t.item,e.name);const i=o.mapper.toViewElement(n);o.writer.remove(o.writer.createRangeIn(i)),this.setPlaceholderContent(o.writer,n,i)}macroLabel(){return window.I18n.t("js.editor.macro.child_pages.text")}pageLabel(e){return e&&e.length>0?e:window.I18n.t("js.editor.macro.child_pages.this_page")}includeParentText(e){return e?` (${window.I18n.t("js.editor.macro.child_pages.include_parent")})`:""}createMacroViewElement(e,t){const o=t.createContainerElement("div");return this.setPlaceholderContent(t,e,o),function(e,t,o){return t.setCustomProperty(nC,!0,e),zk(e,t,{label:o})}(o,t,{label:this.macroLabel()})}setPlaceholderContent(e,t,o){const n=t.getAttribute("page"),i=t.getAttribute("includeParent"),r=this.macroLabel(),s=this.pageLabel(n),a=e.createContainerElement("span",{class:"macro-value"});let l=[e.createText(`${r} `)];e.insert(e.createPositionAt(a,0),e.createText(`${s}`)),l.push(a),l.push(e.createText(this.includeParentText(i))),e.insert(e.createPositionAt(o,0),l)}}class sC extends lr{static get requires(){return[Fb]}static get pluginName(){return"OPChildPagesToolbar"}init(){const e=this.editor,t=this.editor.model,o=Gk(e);a_(e,"opEditChildPagesMacroButton",(e=>{const n=o.services.macros,i=e.getAttribute("page"),r=e.getAttribute("includeParent"),s=i&&i.length>0?i:"";n.configureChildPages(s,r).then((o=>t.change((t=>{t.setAttribute("page",o.page,e),t.setAttribute("includeParent",o.includeParent,e)}))))}))}afterInit(){c_(this,this.editor,"OPChildPages",iC)}}class aC extends dr{constructor(e){super(e),this.affectsData=!1}execute(){const e=this.editor.model,t=e.document.selection;let o=e.schema.getLimitElement(t);if(t.containsEntireContent(o)||!lC(e.schema,o))do{if(o=o.parent,!o)return}while(!lC(e.schema,o));e.change((e=>{e.setSelection(o,"in")}))}}function lC(e,t){return e.isLimit(t)&&(e.checkChild(t,"$text")||e.checkChild(t,"paragraph"))}const cC=yi("Ctrl+A");class dC extends lr{static get pluginName(){return"SelectAllEditing"}init(){const e=this.editor,t=e.t,o=e.editing.view.document;e.commands.add("selectAll",new aC(e)),this.listenTo(o,"keydown",((t,o)=>{_i(o)===cC&&(e.execute("selectAll"),o.preventDefault())})),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Select all"),keystroke:"CTRL+A"}]})}}class uC extends lr{static get pluginName(){return"SelectAllUI"}init(){const e=this.editor;e.ui.componentFactory.add("selectAll",(()=>{const e=this._createButton(Em);return e.set({tooltip:!0}),e})),e.ui.componentFactory.add("menuBar:selectAll",(()=>this._createButton(ip)))}_createButton(e){const t=this.editor,o=t.locale,n=t.commands.get("selectAll"),i=new e(t.locale),r=o.t;return i.set({label:r("Select all"),icon:'',keystroke:"Ctrl+A"}),i.bind("isEnabled").to(n,"isEnabled"),this.listenTo(i,"execute",(()=>{t.execute("selectAll"),t.editing.view.focus()})),i}}class hC extends lr{static get requires(){return[dC,uC]}static get pluginName(){return"SelectAll"}}const mC="ckCsrfToken",pC="abcdefghijklmnopqrstuvwxyz0123456789";function gC(){let e=function(e){e=e.toLowerCase();const t=document.cookie.split(";");for(const o of t){const t=o.split("=");if(decodeURIComponent(t[0].trim().toLowerCase())===e)return decodeURIComponent(t[1])}return null}(mC);var t,o;return e&&40==e.length||(e=function(e){let t="";const o=new Uint8Array(e);window.crypto.getRandomValues(o);for(let e=0;e.5?n.toUpperCase():n}return t}(40),t=mC,o=e,document.cookie=encodeURIComponent(t)+"="+encodeURIComponent(o)+";path=/"),e}class fC{constructor(e,t,o){this.loader=e,this.url=t,this.t=o}upload(){return this.loader.file.then((e=>new Promise(((t,o)=>{this._initRequest(),this._initListeners(t,o,e),this._sendRequest(e)}))))}abort(){this.xhr&&this.xhr.abort()}_initRequest(){const e=this.xhr=new XMLHttpRequest;e.open("POST",this.url,!0),e.responseType="json"}_initListeners(e,t,o){const n=this.xhr,i=this.loader,r=(0,this.t)("Cannot upload file:")+` ${o.name}.`;n.addEventListener("error",(()=>t(r))),n.addEventListener("abort",(()=>t())),n.addEventListener("load",(()=>{const o=n.response;if(!o||!o.uploaded)return t(o&&o.error&&o.error.message?o.error.message:r);e({default:o.url})})),n.upload&&n.upload.addEventListener("progress",(e=>{e.lengthComputable&&(i.uploadTotal=e.total,i.uploaded=e.loaded)}))}_sendRequest(e){const t=new FormData;t.append("upload",e),t.append("ckCsrfToken",gC()),this.xhr.send(t)}}function bC(e,t,o,n){let i,r=null;"function"==typeof n?i=n:(r=e.commands.get(n),i=()=>{e.execute(n)}),e.model.document.on("change:data",((s,a)=>{if(r&&!r.isEnabled||!t.isEnabled)return;const l=Qi(e.model.document.selection.getRanges());if(!l.isCollapsed)return;if(a.isUndo||!a.isLocal)return;const c=Array.from(e.model.document.differ.getChanges()),d=c[0];if(1!=c.length||"insert"!==d.type||"$text"!=d.name||1!=d.length)return;const u=d.position.parent;if(u.is("element","codeBlock"))return;if(u.is("element","listItem")&&"function"!=typeof n&&!["numberedList","bulletedList","todoList"].includes(n))return;if(r&&!0===r.value)return;const h=u.getChild(0),m=e.model.createRangeOn(h);if(!m.containsRange(l)&&!l.end.isEqual(m.end))return;const p=o.exec(h.data.substr(0,l.end.offset));p&&e.model.enqueueChange((t=>{const o=t.createPositionAt(u,0),n=t.createPositionAt(u,p[0].length),r=new cc(o,n);if(!1!==i({match:p})){t.remove(r);const o=e.model.document.selection.getFirstRange(),n=t.createRangeIn(u);!u.isEmpty||n.isEqual(o)||n.containsRange(o,!0)||t.remove(u)}r.detach(),e.model.enqueueChange((()=>{e.plugins.get("Delete").requestUndoOnBackspace()}))}))}))}function kC(e,t,o,n){let i,r;o instanceof RegExp?i=o:r=o,r=r||(e=>{let t;const o=[],n=[];for(;null!==(t=i.exec(e))&&!(t&&t.length<4);){let{index:e,1:i,2:r,3:s}=t;const a=i+r+s;e+=t[0].length-a.length;const l=[e,e+i.length],c=[e+i.length+r.length,e+i.length+r.length+s.length];o.push(l),o.push(c),n.push([e+i.length,e+i.length+r.length])}return{remove:o,format:n}}),e.model.document.on("change:data",((o,i)=>{if(i.isUndo||!i.isLocal||!t.isEnabled)return;const s=e.model,a=s.document.selection;if(!a.isCollapsed)return;const l=Array.from(s.document.differ.getChanges()),c=l[0];if(1!=l.length||"insert"!==c.type||"$text"!=c.name||1!=c.length)return;const d=a.focus,u=d.parent,{text:h,range:m}=function(e,t){let o=e.start;const n=Array.from(e.getItems()).reduce(((e,n)=>!n.is("$text")&&!n.is("$textProxy")||n.getAttribute("code")?(o=t.createPositionAfter(n),""):e+n.data),"");return{text:n,range:t.createRange(o,e.end)}}(s.createRange(s.createPositionAt(u,0),d),s),p=r(h),g=wC(m.start,p.format,s),f=wC(m.start,p.remove,s);g.length&&f.length&&s.enqueueChange((t=>{if(!1!==n(t,g)){for(const e of f.reverse())t.remove(e);s.enqueueChange((()=>{e.plugins.get("Delete").requestUndoOnBackspace()}))}}))}))}function wC(e,t,o){return t.filter((e=>void 0!==e[0]&&void 0!==e[1])).map((t=>o.createRange(e.getShiftedBy(t[0]),e.getShiftedBy(t[1]))))}function _C(e,t){return(o,n)=>{if(!e.commands.get(t).isEnabled)return!1;const i=e.model.schema.getValidRanges(n,t);for(const e of i)o.setAttribute(t,!0,e);o.removeSelectionAttribute(t)}}class yC extends dr{constructor(e,t){super(e),this.attributeKey=t}refresh(){const e=this.editor.model,t=e.document;this.value=this._getValueFromFirstAllowedNode(),this.isEnabled=e.schema.checkAttributeInSelection(t.selection,this.attributeKey)}execute(e={}){const t=this.editor.model,o=t.document.selection,n=void 0===e.forceValue?!this.value:e.forceValue;t.change((e=>{if(o.isCollapsed)n?e.setSelectionAttribute(this.attributeKey,!0):e.removeSelectionAttribute(this.attributeKey);else{const i=t.schema.getValidRanges(o.getRanges(),this.attributeKey);for(const t of i)n?e.setAttribute(this.attributeKey,n,t):e.removeAttribute(this.attributeKey,t)}}))}_getValueFromFirstAllowedNode(){const e=this.editor.model,t=e.schema,o=e.document.selection;if(o.isCollapsed)return o.hasAttribute(this.attributeKey);for(const e of o.getRanges())for(const o of e.getItems())if(t.checkAttribute(o,this.attributeKey))return o.hasAttribute(this.attributeKey);return!1}}const AC="bold";class CC extends lr{static get pluginName(){return"BoldEditing"}init(){const e=this.editor,t=this.editor.t;e.model.schema.extend("$text",{allowAttributes:AC}),e.model.schema.setAttributeProperties(AC,{isFormatting:!0,copyOnEnter:!0}),e.conversion.attributeToElement({model:AC,view:"strong",upcastAlso:["b",e=>{const t=e.getStyle("font-weight");return t&&("bold"==t||Number(t)>=600)?{name:!0,styles:["font-weight"]}:null}]}),e.commands.add(AC,new yC(e,AC)),e.keystrokes.set("CTRL+B",AC),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Bold text"),keystroke:"CTRL+B"}]})}}function vC({editor:e,commandName:t,plugin:o,icon:n,label:i,keystroke:r}){return s=>{const a=e.commands.get(t),l=new s(e.locale);return l.set({label:i,icon:n,keystroke:r,isToggleable:!0}),l.bind("isEnabled").to(a,"isEnabled"),l.bind("isOn").to(a,"value"),l instanceof ip?l.set({role:"menuitemcheckbox"}):l.set({tooltip:!0}),o.listenTo(l,"execute",(()=>{e.execute(t),e.editing.view.focus()})),l}}const xC="bold";class EC extends lr{static get pluginName(){return"BoldUI"}init(){const e=this.editor,t=e.locale.t,o=vC({editor:e,commandName:xC,plugin:this,icon:qh.bold,label:t("Bold"),keystroke:"CTRL+B"});e.ui.componentFactory.add(xC,(()=>o(Em))),e.ui.componentFactory.add("menuBar:"+xC,(()=>o(ip)))}}const DC="code";class BC extends lr{static get pluginName(){return"CodeEditing"}static get requires(){return[bw]}init(){const e=this.editor,t=this.editor.t;e.model.schema.extend("$text",{allowAttributes:DC}),e.model.schema.setAttributeProperties(DC,{isFormatting:!0,copyOnEnter:!1}),e.conversion.attributeToElement({model:DC,view:"code",upcastAlso:{styles:{"word-wrap":"break-word"}}}),e.commands.add(DC,new yC(e,DC)),e.plugins.get(bw).registerAttribute(DC),Dw(e,DC,"code","ck-code_selected"),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Move out of an inline code style"),keystroke:[["arrowleft","arrowleft"],["arrowright","arrowright"]]}]})}}var SC=i(9248),TC={attributes:{"data-cke":!0}};TC.setAttributes=Ar(),TC.insert=_r().bind(null,"head"),TC.domAPI=kr(),TC.insertStyleElement=vr();fr()(SC.A,TC);SC.A&&SC.A.locals&&SC.A.locals;const IC="code";class PC extends lr{static get pluginName(){return"CodeUI"}init(){const e=this.editor,t=e.locale.t,o=vC({editor:e,commandName:IC,plugin:this,icon:'',label:t("Code")});e.ui.componentFactory.add(IC,(()=>o(Em))),e.ui.componentFactory.add("menuBar:"+IC,(()=>o(ip)))}}const FC="italic";class MC extends lr{static get pluginName(){return"ItalicEditing"}init(){const e=this.editor,t=this.editor.t;e.model.schema.extend("$text",{allowAttributes:FC}),e.model.schema.setAttributeProperties(FC,{isFormatting:!0,copyOnEnter:!0}),e.conversion.attributeToElement({model:FC,view:"i",upcastAlso:["em",{styles:{"font-style":"italic"}}]}),e.commands.add(FC,new yC(e,FC)),e.keystrokes.set("CTRL+I",FC),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Italic text"),keystroke:"CTRL+I"}]})}}const RC="italic";class zC extends lr{static get pluginName(){return"ItalicUI"}init(){const e=this.editor,t=e.locale.t,o=vC({editor:e,commandName:RC,plugin:this,icon:'',keystroke:"CTRL+I",label:t("Italic")});e.ui.componentFactory.add(RC,(()=>o(Em))),e.ui.componentFactory.add("menuBar:"+RC,(()=>o(ip)))}}const VC="strikethrough";class OC extends lr{static get pluginName(){return"StrikethroughEditing"}init(){const e=this.editor,t=this.editor.t;e.model.schema.extend("$text",{allowAttributes:VC}),e.model.schema.setAttributeProperties(VC,{isFormatting:!0,copyOnEnter:!0}),e.conversion.attributeToElement({model:VC,view:"s",upcastAlso:["del","strike",{styles:{"text-decoration":"line-through"}}]}),e.commands.add(VC,new yC(e,VC)),e.keystrokes.set("CTRL+SHIFT+X","strikethrough"),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Strikethrough text"),keystroke:"CTRL+SHIFT+X"}]})}}const NC="strikethrough";class LC extends lr{static get pluginName(){return"StrikethroughUI"}init(){const e=this.editor,t=e.locale.t,o=vC({editor:e,commandName:NC,plugin:this,icon:'',keystroke:"CTRL+SHIFT+X",label:t("Strikethrough")});e.ui.componentFactory.add(NC,(()=>o(Em))),e.ui.componentFactory.add("menuBar:"+NC,(()=>o(ip)))}}class HC extends dr{refresh(){this.value=this._getValue(),this.isEnabled=this._checkEnabled()}execute(e={}){const t=this.editor.model,o=t.schema,n=t.document.selection,i=Array.from(n.getSelectedBlocks()),r=void 0===e.forceValue?!this.value:e.forceValue;t.change((e=>{if(r){const t=i.filter((e=>jC(e)||UC(o,e)));this._applyQuote(e,t)}else this._removeQuote(e,i.filter(jC))}))}_getValue(){const e=Qi(this.editor.model.document.selection.getSelectedBlocks());return!(!e||!jC(e))}_checkEnabled(){if(this.value)return!0;const e=this.editor.model.document.selection,t=this.editor.model.schema,o=Qi(e.getSelectedBlocks());return!!o&&UC(t,o)}_removeQuote(e,t){qC(e,t).reverse().forEach((t=>{if(t.start.isAtStart&&t.end.isAtEnd)return void e.unwrap(t.start.parent);if(t.start.isAtStart){const o=e.createPositionBefore(t.start.parent);return void e.move(t,o)}t.end.isAtEnd||e.split(t.end);const o=e.createPositionAfter(t.end.parent);e.move(t,o)}))}_applyQuote(e,t){const o=[];qC(e,t).reverse().forEach((t=>{let n=jC(t.start);n||(n=e.createElement("blockQuote"),e.wrap(t,n)),o.push(n)})),o.reverse().reduce(((t,o)=>t.nextSibling==o?(e.merge(e.createPositionAfter(t)),t):o))}}function jC(e){return"blockQuote"==e.parent.name?e.parent:null}function qC(e,t){let o,n=0;const i=[];for(;n{const n=e.model.document.differ.getChanges();for(const e of n)if("insert"==e.type){const n=e.position.nodeAfter;if(!n)continue;if(n.is("element","blockQuote")&&n.isEmpty)return o.remove(n),!0;if(n.is("element","blockQuote")&&!t.checkChild(e.position,n))return o.unwrap(n),!0;if(n.is("element")){const e=o.createRangeIn(n);for(const n of e.getItems())if(n.is("element","blockQuote")&&!t.checkChild(o.createPositionBefore(n),n))return o.unwrap(n),!0}}else if("remove"==e.type){const t=e.position.parent;if(t.is("element","blockQuote")&&t.isEmpty)return o.remove(t),!0}return!1}));const o=this.editor.editing.view.document,n=e.model.document.selection,i=e.commands.get("blockQuote");this.listenTo(o,"enter",((t,o)=>{if(!n.isCollapsed||!i.value)return;n.getLastPosition().parent.isEmpty&&(e.execute("blockQuote"),e.editing.view.scrollToTheSelection(),o.preventDefault(),t.stop())}),{context:"blockquote"}),this.listenTo(o,"delete",((t,o)=>{if("backward"!=o.direction||!n.isCollapsed||!i.value)return;const r=n.getLastPosition().parent;r.isEmpty&&!r.previousSibling&&(e.execute("blockQuote"),e.editing.view.scrollToTheSelection(),o.preventDefault(),t.stop())}),{context:"blockquote"})}}var $C=i(1501),GC={attributes:{"data-cke":!0}};GC.setAttributes=Ar(),GC.insert=_r().bind(null,"head"),GC.domAPI=kr(),GC.insertStyleElement=vr();fr()($C.A,GC);$C.A&&$C.A.locals&&$C.A.locals;class KC extends lr{static get pluginName(){return"BlockQuoteUI"}init(){const e=this.editor;e.ui.componentFactory.add("blockQuote",(()=>{const e=this._createButton(Em);return e.set({tooltip:!0}),e})),e.ui.componentFactory.add("menuBar:blockQuote",(()=>{const e=this._createButton(ip);return e.set({role:"menuitemcheckbox"}),e}))}_createButton(e){const t=this.editor,o=t.locale,n=t.commands.get("blockQuote"),i=new e(t.locale),r=o.t;return i.set({label:r("Block quote"),icon:qh.quote,isToggleable:!0}),i.bind("isEnabled").to(n,"isEnabled"),i.bind("isOn").to(n,"value"),this.listenTo(i,"execute",(()=>{t.execute("blockQuote"),t.editing.view.focus()})),i}}class ZC extends dr{constructor(e){super(e),this._isEnabledBasedOnSelection=!1}refresh(){const e=this.editor.model,t=Qi(e.document.selection.getSelectedBlocks());this.value=!!t&&t.is("element","paragraph"),this.isEnabled=!!t&&JC(t,e.schema)}execute(e={}){const t=this.editor.model,o=t.document,n=e.selection||o.selection;t.canEditAt(n)&&t.change((e=>{const o=n.getSelectedBlocks();for(const n of o)!n.is("element","paragraph")&&JC(n,t.schema)&&e.rename(n,"paragraph")}))}}function JC(e,t){return t.checkChild(e.parent,"paragraph")&&!t.isObject(e)}class YC extends dr{constructor(e){super(e),this._isEnabledBasedOnSelection=!1}execute(e){const t=this.editor.model,o=e.attributes;let n=e.position;t.canEditAt(n)&&t.change((e=>{if(n=this._findPositionToInsertParagraph(n,e),!n)return;const i=e.createElement("paragraph");o&&t.schema.setAllowedAttributes(i,o,e),t.insertContent(i,n),e.setSelection(i,"in")}))}_findPositionToInsertParagraph(e,t){const o=this.editor.model;if(o.schema.checkChild(e,"paragraph"))return e;const n=o.schema.findAllowedParent(e,"paragraph");if(!n)return null;const i=e.parent,r=o.schema.checkChild(i,"$text");return i.isEmpty||r&&e.isAtEnd?o.createPositionAfter(i):!i.isEmpty&&r&&e.isAtStart?o.createPositionBefore(i):t.split(e,n).position}}class QC extends lr{static get pluginName(){return"Paragraph"}init(){const e=this.editor,t=e.model;e.commands.add("paragraph",new ZC(e)),e.commands.add("insertParagraph",new YC(e)),t.schema.register("paragraph",{inheritAllFrom:"$block"}),e.conversion.elementToElement({model:"paragraph",view:"p"}),e.conversion.for("upcast").elementToElement({model:(e,{writer:t})=>QC.paragraphLikeElements.has(e.name)?e.isEmpty?null:t.createElement("paragraph"):null,view:/.+/,converterPriority:"low"})}}QC.paragraphLikeElements=new Set(["blockquote","dd","div","dt","h1","h2","h3","h4","h5","h6","li","p","td","th"]);const XC=QC;class ev extends dr{constructor(e,t){super(e),this.modelElements=t}refresh(){const e=Qi(this.editor.model.document.selection.getSelectedBlocks());this.value=!!e&&this.modelElements.includes(e.name)&&e.name,this.isEnabled=!!e&&this.modelElements.some((t=>tv(e,t,this.editor.model.schema)))}execute(e){const t=this.editor.model,o=t.document,n=e.value;t.change((e=>{const i=Array.from(o.selection.getSelectedBlocks()).filter((e=>tv(e,n,t.schema)));for(const t of i)t.is("element",n)||e.rename(t,n)}))}}function tv(e,t,o){return o.checkChild(e.parent,t)&&!o.isObject(e)}const ov="paragraph";class nv extends lr{static get pluginName(){return"HeadingEditing"}constructor(e){super(e),e.config.define("heading",{options:[{model:"paragraph",title:"Paragraph",class:"ck-heading_paragraph"},{model:"heading1",view:"h2",title:"Heading 1",class:"ck-heading_heading1"},{model:"heading2",view:"h3",title:"Heading 2",class:"ck-heading_heading2"},{model:"heading3",view:"h4",title:"Heading 3",class:"ck-heading_heading3"}]})}static get requires(){return[XC]}init(){const e=this.editor,t=e.config.get("heading.options"),o=[];for(const n of t)"paragraph"!==n.model&&(e.model.schema.register(n.model,{inheritAllFrom:"$block"}),e.conversion.elementToElement(n),o.push(n.model));this._addDefaultH1Conversion(e),e.commands.add("heading",new ev(e,o))}afterInit(){const e=this.editor,t=e.commands.get("enter"),o=e.config.get("heading.options");t&&this.listenTo(t,"afterExecute",((t,n)=>{const i=e.model.document.selection.getFirstPosition().parent;o.some((e=>i.is("element",e.model)))&&!i.is("element",ov)&&0===i.childCount&&n.writer.rename(i,ov)}))}_addDefaultH1Conversion(e){e.conversion.for("upcast").elementToElement({model:"heading1",view:"h1",converterPriority:C.low+1})}}var iv=i(6186),rv={attributes:{"data-cke":!0}};rv.setAttributes=Ar(),rv.insert=_r().bind(null,"head"),rv.domAPI=kr(),rv.insertStyleElement=vr();fr()(iv.A,rv);iv.A&&iv.A.locals&&iv.A.locals;class sv extends lr{static get pluginName(){return"HeadingUI"}init(){const e=this.editor,t=e.t,o=function(e){const t=e.t,o={Paragraph:t("Paragraph"),"Heading 1":t("Heading 1"),"Heading 2":t("Heading 2"),"Heading 3":t("Heading 3"),"Heading 4":t("Heading 4"),"Heading 5":t("Heading 5"),"Heading 6":t("Heading 6")};return e.config.get("heading.options").map((e=>{const t=o[e.title];return t&&t!=e.title&&(e.title=t),e}))}(e),n=t("Choose heading"),i=t("Heading");e.ui.componentFactory.add("heading",(t=>{const r={},s=new Yi,a=e.commands.get("heading"),l=e.commands.get("paragraph"),c=[a];for(const e of o){const t={type:"button",model:new Db({label:e.title,class:e.class,role:"menuitemradio",withText:!0})};"paragraph"===e.model?(t.model.bind("isOn").to(l,"value"),t.model.set("commandName","paragraph"),c.push(l)):(t.model.bind("isOn").to(a,"value",(t=>t===e.model)),t.model.set({commandName:"heading",commandValue:e.model})),s.add(t),r[e.model]=e.title}const d=Eg(t);return Sg(d,s,{ariaLabel:i,role:"menu"}),d.buttonView.set({ariaLabel:i,ariaLabelledBy:void 0,isOn:!1,withText:!0,tooltip:i}),d.extendTemplate({attributes:{class:["ck-heading-dropdown"]}}),d.bind("isEnabled").toMany(c,"isEnabled",((...e)=>e.some((e=>e)))),d.buttonView.bind("label").to(a,"value",l,"value",((e,t)=>{const o=t?"paragraph":e;return"boolean"==typeof o?n:r[o]?r[o]:n})),d.buttonView.bind("ariaLabel").to(a,"value",l,"value",((e,t)=>{const o=t?"paragraph":e;return"boolean"==typeof o?i:r[o]?`${r[o]}, ${i}`:i})),this.listenTo(d,"execute",(t=>{const{commandName:o,commandValue:n}=t.source;e.execute(o,n?{value:n}:void 0),e.editing.view.focus()})),d})),e.ui.componentFactory.add("menuBar:heading",(n=>{const i=new mk(n),r=e.commands.get("heading"),s=e.commands.get("paragraph"),a=[r],l=new pk(n);i.set({class:"ck-heading-dropdown"}),l.set({ariaLabel:t("Heading"),role:"menu"}),i.buttonView.set({label:t("Heading")}),i.panelView.children.add(l);for(const t of o){const o=new nb(n,i),c=new ip(n);o.children.add(c),l.items.add(o),c.set({isToggleable:!0,label:t.title,role:"menuitemradio",class:t.class}),c.delegate("execute").to(i),c.on("execute",(()=>{const o="paragraph"===t.model?"paragraph":"heading";e.execute(o,{value:t.model}),e.editing.view.focus()})),"paragraph"===t.model?(c.bind("isOn").to(s,"value"),a.push(s)):c.bind("isOn").to(r,"value",(e=>e===t.model))}return i.bind("isEnabled").toMany(a,"isEnabled",((...e)=>e.some((e=>e)))),i}))}}new Set(["paragraph","heading1","heading2","heading3","heading4","heading5","heading6"]);class av{constructor(){this._definitions=new Set}get length(){return this._definitions.size}add(e){Array.isArray(e)?e.forEach((e=>this._definitions.add(e))):this._definitions.add(e)}getDispatcher(){return e=>{e.on("attribute:linkHref",((e,t,o)=>{if(!o.consumable.test(t.item,"attribute:linkHref"))return;if(!t.item.is("selection")&&!o.schema.isInline(t.item))return;const n=o.writer,i=n.document.selection;for(const e of this._definitions){const r=n.createAttributeElement("a",e.attributes,{priority:5});e.classes&&n.addClass(e.classes,r);for(const t in e.styles)n.setStyle(t,e.styles[t],r);n.setCustomProperty("link",!0,r),e.callback(t.attributeNewValue)?t.item.is("selection")?n.wrap(i.getFirstRange(),r):n.wrap(o.mapper.toViewRange(t.range),r):n.unwrap(o.mapper.toViewRange(t.range),r)}}),{priority:"high"})}}getDispatcherForLinkedImage(){return e=>{e.on("attribute:linkHref:imageBlock",((e,t,{writer:o,mapper:n})=>{const i=n.toViewElement(t.item),r=Array.from(i.getChildren()).find((e=>e.is("element","a")));for(const e of this._definitions){const n=tr(e.attributes);if(e.callback(t.attributeNewValue)){for(const[e,t]of n)"class"===e?o.addClass(t,r):o.setAttribute(e,t,r);e.classes&&o.addClass(e.classes,r);for(const t in e.styles)o.setStyle(t,e.styles[t],r)}else{for(const[e,t]of n)"class"===e?o.removeClass(t,r):o.removeAttribute(e,r);e.classes&&o.removeClass(e.classes,r);for(const t in e.styles)o.removeStyle(t,r)}}}))}}}const lv=function(e,t,o){var n=e.length;return o=void 0===o?n:o,!t&&o>=n?e:ds(e,t,o)};var cv=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");const dv=function(e){return cv.test(e)};const uv=function(e){return e.split("")};var hv="\\ud800-\\udfff",mv="["+hv+"]",pv="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",gv="\\ud83c[\\udffb-\\udfff]",fv="[^"+hv+"]",bv="(?:\\ud83c[\\udde6-\\uddff]){2}",kv="[\\ud800-\\udbff][\\udc00-\\udfff]",wv="(?:"+pv+"|"+gv+")"+"?",_v="[\\ufe0e\\ufe0f]?",yv=_v+wv+("(?:\\u200d(?:"+[fv,bv,kv].join("|")+")"+_v+wv+")*"),Av="(?:"+[fv+pv+"?",pv,bv,kv,mv].join("|")+")",Cv=RegExp(gv+"(?="+gv+")|"+Av+yv,"g");const vv=function(e){return e.match(Cv)||[]};const xv=function(e){return dv(e)?vv(e):uv(e)};const Ev=function(e){return function(t){t=rs(t);var o=dv(t)?xv(t):void 0,n=o?o[0]:t.charAt(0),i=o?lv(o,1).join(""):t.slice(1);return n[e]()+i}}("toUpperCase"),Dv=/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205f\u3000]/g,Bv=/^[\S]+@((?![-_])(?:[-\w\u00a1-\uffff]{0,63}[^-_]\.))+(?:[a-z\u00a1-\uffff]{2,})$/i,Sv=/^((\w+:(\/{2,})?)|(\W))/i,Tv=["https?","ftps?","mailto"],Iv="Ctrl+K";function Pv(e,{writer:t}){const o=t.createAttributeElement("a",{href:e},{priority:5});return t.setCustomProperty("link",!0,o),o}function Fv(e,t=Tv){const o=String(e),n=t.join("|");return function(e,t){const o=e.replace(Dv,"");return!!o.match(t)}(o,new RegExp(`${"^(?:(?:):|[^a-z]|[a-z+.-]+(?:[^a-z+.:-]|$))".replace("",n)}`,"i"))?o:"#"}function Mv(e,t){return!!e&&t.checkAttribute(e.name,"linkHref")}function Rv(e,t){const o=(n=e,Bv.test(n)?"mailto:":t);var n;const i=!!o&&!zv(e);return e&&i?o+e:e}function zv(e){return Sv.test(e)}function Vv(e){window.open(e,"_blank","noopener")}class Ov extends dr{constructor(){super(...arguments),this.manualDecorators=new Yi,this.automaticDecorators=new av}restoreManualDecoratorStates(){for(const e of this.manualDecorators)e.value=this._getDecoratorStateFromModel(e.id)}refresh(){const e=this.editor.model,t=e.document.selection,o=t.getSelectedElement()||Qi(t.getSelectedBlocks());Mv(o,e.schema)?(this.value=o.getAttribute("linkHref"),this.isEnabled=e.schema.checkAttribute(o,"linkHref")):(this.value=t.getAttribute("linkHref"),this.isEnabled=e.schema.checkAttributeInSelection(t,"linkHref"));for(const e of this.manualDecorators)e.value=this._getDecoratorStateFromModel(e.id)}execute(e,t={}){const o=this.editor.model,n=o.document.selection,i=[],r=[];for(const e in t)t[e]?i.push(e):r.push(e);o.change((t=>{if(n.isCollapsed){const s=n.getFirstPosition();if(n.hasAttribute("linkHref")){const a=Nv(n);let l=xw(s,"linkHref",n.getAttribute("linkHref"),o);n.getAttribute("linkHref")===a&&(l=this._updateLinkContent(o,t,l,e)),t.setAttribute("linkHref",e,l),i.forEach((e=>{t.setAttribute(e,!0,l)})),r.forEach((e=>{t.removeAttribute(e,l)})),t.setSelection(t.createPositionAfter(l.end.nodeBefore))}else if(""!==e){const r=tr(n.getAttributes());r.set("linkHref",e),i.forEach((e=>{r.set(e,!0)}));const{end:a}=o.insertContent(t.createText(e,r),s);t.setSelection(a)}["linkHref",...i,...r].forEach((e=>{t.removeSelectionAttribute(e)}))}else{const s=o.schema.getValidRanges(n.getRanges(),"linkHref"),a=[];for(const e of n.getSelectedBlocks())o.schema.checkAttribute(e,"linkHref")&&a.push(t.createRangeOn(e));const l=a.slice();for(const e of s)this._isRangeToUpdate(e,a)&&l.push(e);for(const s of l){let a=s;if(1===l.length){const i=Nv(n);n.getAttribute("linkHref")===i&&(a=this._updateLinkContent(o,t,s,e),t.setSelection(t.createSelection(a)))}t.setAttribute("linkHref",e,a),i.forEach((e=>{t.setAttribute(e,!0,a)})),r.forEach((e=>{t.removeAttribute(e,a)}))}}}))}_getDecoratorStateFromModel(e){const t=this.editor.model,o=t.document.selection,n=o.getSelectedElement();return Mv(n,t.schema)?n.getAttribute(e):o.getAttribute(e)}_isRangeToUpdate(e,t){for(const o of t)if(o.containsRange(e))return!1;return!0}_updateLinkContent(e,t,o,n){const i=t.createText(n,{linkHref:n});return e.insertContent(i,o)}}function Nv(e){if(e.isCollapsed){const t=e.getFirstPosition();return t.textNode&&t.textNode.data}{const t=Array.from(e.getFirstRange().getItems());if(t.length>1)return null;const o=t[0];return o.is("$text")||o.is("$textProxy")?o.data:null}}class Lv extends dr{refresh(){const e=this.editor.model,t=e.document.selection,o=t.getSelectedElement();Mv(o,e.schema)?this.isEnabled=e.schema.checkAttribute(o,"linkHref"):this.isEnabled=e.schema.checkAttributeInSelection(t,"linkHref")}execute(){const e=this.editor,t=this.editor.model,o=t.document.selection,n=e.commands.get("link");t.change((e=>{const i=o.isCollapsed?[xw(o.getFirstPosition(),"linkHref",o.getAttribute("linkHref"),t)]:t.schema.getValidRanges(o.getRanges(),"linkHref");for(const t of i)if(e.removeAttribute("linkHref",t),n)for(const o of n.manualDecorators)e.removeAttribute(o.id,t)}))}}class Hv extends(Y()){constructor({id:e,label:t,attributes:o,classes:n,styles:i,defaultValue:r}){super(),this.id=e,this.set("value",void 0),this.defaultValue=r,this.label=t,this.attributes=o,this.classes=n,this.styles=i}_createPattern(){return{attributes:this.attributes,classes:this.classes,styles:this.styles}}}var jv=i(7456),qv={attributes:{"data-cke":!0}};qv.setAttributes=Ar(),qv.insert=_r().bind(null,"head"),qv.domAPI=kr(),qv.insertStyleElement=vr();fr()(jv.A,qv);jv.A&&jv.A.locals&&jv.A.locals;const Uv="automatic",Wv=/^(https?:)?\/\//;class $v extends lr{static get pluginName(){return"LinkEditing"}static get requires(){return[bw,ow,H_]}constructor(e){super(e),e.config.define("link",{allowCreatingEmptyLinks:!1,addTargetToExternalLinks:!1})}init(){const e=this.editor,t=this.editor.config.get("link.allowedProtocols");e.model.schema.extend("$text",{allowAttributes:"linkHref"}),e.conversion.for("dataDowncast").attributeToElement({model:"linkHref",view:Pv}),e.conversion.for("editingDowncast").attributeToElement({model:"linkHref",view:(e,o)=>Pv(Fv(e,t),o)}),e.conversion.for("upcast").elementToAttribute({view:{name:"a",attributes:{href:!0}},model:{key:"linkHref",value:e=>e.getAttribute("href")}}),e.commands.add("link",new Ov(e)),e.commands.add("unlink",new Lv(e));const o=function(e,t){const o={"Open in a new tab":e("Open in a new tab"),Downloadable:e("Downloadable")};return t.forEach((e=>("label"in e&&o[e.label]&&(e.label=o[e.label]),e))),t}(e.t,function(e){const t=[];if(e)for(const[o,n]of Object.entries(e)){const e=Object.assign({},n,{id:`link${Ev(o)}`});t.push(e)}return t}(e.config.get("link.decorators")));this._enableAutomaticDecorators(o.filter((e=>e.mode===Uv))),this._enableManualDecorators(o.filter((e=>"manual"===e.mode)));e.plugins.get(bw).registerAttribute("linkHref"),Dw(e,"linkHref","a","ck-link_selected"),this._enableLinkOpen(),this._enableSelectionAttributesFixer(),this._enableClipboardIntegration()}_enableAutomaticDecorators(e){const t=this.editor,o=t.commands.get("link").automaticDecorators;t.config.get("link.addTargetToExternalLinks")&&o.add({id:"linkIsExternal",mode:Uv,callback:e=>!!e&&Wv.test(e),attributes:{target:"_blank",rel:"noopener noreferrer"}}),o.add(e),o.length&&t.conversion.for("downcast").add(o.getDispatcher())}_enableManualDecorators(e){if(!e.length)return;const t=this.editor,o=t.commands.get("link").manualDecorators;e.forEach((e=>{t.model.schema.extend("$text",{allowAttributes:e.id});const n=new Hv(e);o.add(n),t.conversion.for("downcast").attributeToElement({model:n.id,view:(e,{writer:t,schema:o},{item:i})=>{if((i.is("selection")||o.isInline(i))&&e){const e=t.createAttributeElement("a",n.attributes,{priority:5});n.classes&&t.addClass(n.classes,e);for(const o in n.styles)t.setStyle(o,n.styles[o],e);return t.setCustomProperty("link",!0,e),e}}}),t.conversion.for("upcast").elementToAttribute({view:{name:"a",...n._createPattern()},model:{key:n.id}})}))}_enableLinkOpen(){const e=this.editor,t=e.editing.view.document;this.listenTo(t,"click",((e,t)=>{if(!(r.isMac?t.domEvent.metaKey:t.domEvent.ctrlKey))return;let o=t.domTarget;if("a"!=o.tagName.toLowerCase()&&(o=o.closest("a")),!o)return;const n=o.getAttribute("href");n&&(e.stop(),t.preventDefault(),Vv(n))}),{context:"$capture"}),this.listenTo(t,"keydown",((t,o)=>{const n=e.commands.get("link").value;!!n&&o.keyCode===ki.enter&&o.altKey&&(t.stop(),Vv(n))}))}_enableSelectionAttributesFixer(){const e=this.editor.model,t=e.document.selection;this.listenTo(t,"change:attribute",((o,{attributeKeys:n})=>{n.includes("linkHref")&&!t.hasAttribute("linkHref")&&e.change((t=>{var o;!function(e,t){e.removeSelectionAttribute("linkHref");for(const o of t)e.removeSelectionAttribute(o)}(t,(o=e.schema,o.getDefinition("$text").allowAttributes.filter((e=>e.startsWith("link")))))}))}))}_enableClipboardIntegration(){const e=this.editor,t=e.model,o=this.editor.config.get("link.defaultProtocol");o&&this.listenTo(e.plugins.get("ClipboardPipeline"),"contentInsertion",((e,n)=>{t.change((e=>{const t=e.createRangeIn(n.content);for(const n of t.getItems())if(n.hasAttribute("linkHref")){const t=Rv(n.getAttribute("linkHref"),o);e.setAttribute("linkHref",t,n)}}))}))}}var Gv=i(2350),Kv={attributes:{"data-cke":!0}};Kv.setAttributes=Ar(),Kv.insert=_r().bind(null,"head"),Kv.domAPI=kr(),Kv.insertStyleElement=vr();fr()(Gv.A,Kv);Gv.A&&Gv.A.locals&&Gv.A.locals;class Zv extends pm{constructor(e,t,o){super(e),this.focusTracker=new Xi,this.keystrokes=new er,this._focusables=new Uh;const n=e.t;this._validators=o,this.urlInputView=this._createUrlInput(),this.saveButtonView=this._createButton(n("Save"),qh.check,"ck-button-save"),this.saveButtonView.type="submit",this.cancelButtonView=this._createButton(n("Cancel"),qh.cancel,"ck-button-cancel","cancel"),this._manualDecoratorSwitches=this._createManualDecoratorSwitches(t),this.children=this._createFormChildren(t.manualDecorators),this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}});const i=["ck","ck-link-form","ck-responsive-form"];t.manualDecorators.length&&i.push("ck-link-form_layout-vertical","ck-vertical-form"),this.setTemplate({tag:"form",attributes:{class:i,tabindex:"-1"},children:this.children})}getDecoratorSwitchesState(){return Array.from(this._manualDecoratorSwitches).reduce(((e,t)=>(e[t.name]=t.isOn,e)),{})}render(){super.render(),bm({view:this});[this.urlInputView,...this._manualDecoratorSwitches,this.saveButtonView,this.cancelButtonView].forEach((e=>{this._focusables.add(e),this.focusTracker.add(e.element)})),this.keystrokes.listenTo(this.element)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this._focusCycler.focusFirst()}isValid(){this.resetFormStatus();for(const e of this._validators){const t=e(this);if(t)return this.urlInputView.errorText=t,!1}return!0}resetFormStatus(){this.urlInputView.errorText=null}_createUrlInput(){const e=this.locale.t,t=new jp(this.locale,Fg);return t.fieldView.inputMode="url",t.label=e("Link URL"),t}_createButton(e,t,o,n){const i=new Em(this.locale);return i.set({label:e,icon:t,tooltip:!0}),i.extendTemplate({attributes:{class:o}}),n&&i.delegate("execute").to(this,n),i}_createManualDecoratorSwitches(e){const t=this.createCollection();for(const o of e.manualDecorators){const n=new bp(this.locale);n.set({name:o.id,label:o.label,withText:!0}),n.bind("isOn").toMany([o,e],"value",((e,t)=>void 0===t&&void 0===e?!!o.defaultValue:!!e)),n.on("execute",(()=>{o.set("value",!n.isOn)})),t.add(n)}return t}_createFormChildren(e){const t=this.createCollection();if(t.add(this.urlInputView),e.length){const e=new pm;e.setTemplate({tag:"ul",children:this._manualDecoratorSwitches.map((e=>({tag:"li",children:[e],attributes:{class:["ck","ck-list__item"]}}))),attributes:{class:["ck","ck-reset","ck-list"]}}),t.add(e)}return t.add(this.saveButtonView),t.add(this.cancelButtonView),t}get url(){const{element:e}=this.urlInputView.fieldView;return e?e.value.trim():null}}var Jv=i(8040),Yv={attributes:{"data-cke":!0}};Yv.setAttributes=Ar(),Yv.insert=_r().bind(null,"head"),Yv.domAPI=kr(),Yv.insertStyleElement=vr();fr()(Jv.A,Yv);Jv.A&&Jv.A.locals&&Jv.A.locals;class Qv extends pm{constructor(e,t={}){super(e),this.focusTracker=new Xi,this.keystrokes=new er,this._focusables=new Uh;const o=e.t;this.previewButtonView=this._createPreviewButton(),this.unlinkButtonView=this._createButton(o("Unlink"),'',"unlink"),this.editButtonView=this._createButton(o("Edit link"),qh.pencil,"edit"),this.set("href",void 0),this._linkConfig=t,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-link-actions","ck-responsive-form"],tabindex:"-1"},children:[this.previewButtonView,this.editButtonView,this.unlinkButtonView]})}render(){super.render();[this.previewButtonView,this.editButtonView,this.unlinkButtonView].forEach((e=>{this._focusables.add(e),this.focusTracker.add(e.element)})),this.keystrokes.listenTo(this.element)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this._focusCycler.focusFirst()}_createButton(e,t,o){const n=new Em(this.locale);return n.set({label:e,icon:t,tooltip:!0}),n.delegate("execute").to(this,o),n}_createPreviewButton(){const e=new Em(this.locale),t=this.bindTemplate,o=this.t;return e.set({withText:!0,tooltip:o("Open link in new tab")}),e.extendTemplate({attributes:{class:["ck","ck-link-actions__preview"],href:t.to("href",(e=>e&&Fv(e,this._linkConfig.allowedProtocols))),target:"_blank",rel:"noopener noreferrer"}}),e.bind("label").to(this,"href",(e=>e||o("This link has no URL"))),e.bind("isEnabled").to(this,"href",(e=>!!e)),e.template.tag="a",e.template.eventListeners={},e}}const Xv="link-ui";class ex extends lr{constructor(){super(...arguments),this.actionsView=null,this.formView=null}static get requires(){return[Fb]}static get pluginName(){return"LinkUI"}init(){const e=this.editor,t=this.editor.t;e.editing.view.addObserver(Ou),this._balloon=e.plugins.get(Fb),this._createToolbarLinkButton(),this._enableBalloonActivators(),e.conversion.for("editingDowncast").markerToHighlight({model:Xv,view:{classes:["ck-fake-link-selection"]}}),e.conversion.for("editingDowncast").markerToElement({model:Xv,view:(e,{writer:t})=>{if(!e.markerRange.isCollapsed)return null;const o=t.createUIElement("span");return t.addClass(["ck-fake-link-selection","ck-fake-link-selection_collapsed"],o),o}}),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Create link"),keystroke:Iv},{label:t("Move out of a link"),keystroke:[["arrowleft","arrowleft"],["arrowright","arrowright"]]}]})}destroy(){super.destroy(),this.formView&&this.formView.destroy(),this.actionsView&&this.actionsView.destroy()}_createViews(){this.actionsView=this._createActionsView(),this.formView=this._createFormView(),this._enableUserBalloonInteractions()}_createActionsView(){const e=this.editor,t=new Qv(e.locale,e.config.get("link")),o=e.commands.get("link"),n=e.commands.get("unlink");return t.bind("href").to(o,"value"),t.editButtonView.bind("isEnabled").to(o),t.unlinkButtonView.bind("isEnabled").to(n),this.listenTo(t,"edit",(()=>{this._addFormView()})),this.listenTo(t,"unlink",(()=>{e.execute("unlink"),this._hideUI()})),t.keystrokes.set("Esc",((e,t)=>{this._hideUI(),t()})),t.keystrokes.set(Iv,((e,t)=>{this._addFormView(),t()})),t}_createFormView(){const e=this.editor,t=e.commands.get("link"),o=e.config.get("link.defaultProtocol"),n=new(fm(Zv))(e.locale,t,function(e){const t=e.t,o=e.config.get("link.allowCreatingEmptyLinks");return[e=>{if(!o&&!e.url.length)return t("Link URL must not be empty.")}]}(e));return n.urlInputView.fieldView.bind("value").to(t,"value"),n.urlInputView.bind("isEnabled").to(t,"isEnabled"),n.saveButtonView.bind("isEnabled").to(t,"isEnabled"),this.listenTo(n,"submit",(()=>{if(n.isValid()){const{value:t}=n.urlInputView.fieldView.element,i=Rv(t,o);e.execute("link",i,n.getDecoratorSwitchesState()),this._closeFormView()}})),this.listenTo(n.urlInputView,"change:errorText",(()=>{e.ui.update()})),this.listenTo(n,"cancel",(()=>{this._closeFormView()})),n.keystrokes.set("Esc",((e,t)=>{this._closeFormView(),t()})),n}_createToolbarLinkButton(){const e=this.editor;e.ui.componentFactory.add("link",(()=>{const e=this._createButton(Em);return e.set({tooltip:!0}),e})),e.ui.componentFactory.add("menuBar:link",(()=>{const e=this._createButton(ip);return e.set({role:"menuitemcheckbox"}),e}))}_createButton(e){const t=this.editor,o=t.locale,n=t.commands.get("link"),i=new e(t.locale),r=o.t;return i.set({label:r("Link"),icon:'',keystroke:Iv,isToggleable:!0}),i.bind("isEnabled").to(n,"isEnabled"),i.bind("isOn").to(n,"value",(e=>!!e)),this.listenTo(i,"execute",(()=>this._showUI(!0))),i}_enableBalloonActivators(){const e=this.editor,t=e.editing.view.document;this.listenTo(t,"click",(()=>{this._getSelectedLinkElement()&&this._showUI()})),e.keystrokes.set(Iv,((t,o)=>{o(),e.commands.get("link").isEnabled&&this._showUI(!0)}))}_enableUserBalloonInteractions(){this.editor.keystrokes.set("Tab",((e,t)=>{this._areActionsVisible&&!this.actionsView.focusTracker.isFocused&&(this.actionsView.focus(),t())}),{priority:"high"}),this.editor.keystrokes.set("Esc",((e,t)=>{this._isUIVisible&&(this._hideUI(),t())})),gm({emitter:this.formView,activator:()=>this._isUIInPanel,contextElements:()=>[this._balloon.view.element],callback:()=>this._hideUI()})}_addActionsView(){this.actionsView||this._createViews(),this._areActionsInPanel||this._balloon.add({view:this.actionsView,position:this._getBalloonPositionData()})}_addFormView(){if(this.formView||this._createViews(),this._isFormInPanel)return;const e=this.editor.commands.get("link");this.formView.disableCssTransitions(),this.formView.resetFormStatus(),this._balloon.add({view:this.formView,position:this._getBalloonPositionData()}),this.formView.urlInputView.fieldView.value=e.value||"",this._balloon.visibleView===this.formView&&this.formView.urlInputView.fieldView.select(),this.formView.enableCssTransitions()}_closeFormView(){const e=this.editor.commands.get("link");e.restoreManualDecoratorStates(),void 0!==e.value?this._removeFormView():this._hideUI()}_removeFormView(){this._isFormInPanel&&(this.formView.saveButtonView.focus(),this.formView.urlInputView.fieldView.reset(),this._balloon.remove(this.formView),this.editor.editing.view.focus(),this._hideFakeVisualSelection())}_showUI(e=!1){this.formView||this._createViews(),this._getSelectedLinkElement()?(this._areActionsVisible?this._addFormView():this._addActionsView(),e&&this._balloon.showStack("main")):(this._showFakeVisualSelection(),this._addActionsView(),e&&this._balloon.showStack("main"),this._addFormView()),this._startUpdatingUI()}_hideUI(){if(!this._isUIInPanel)return;const e=this.editor;this.stopListening(e.ui,"update"),this.stopListening(this._balloon,"change:visibleView"),e.editing.view.focus(),this._removeFormView(),this._balloon.remove(this.actionsView),this._hideFakeVisualSelection()}_startUpdatingUI(){const e=this.editor,t=e.editing.view.document;let o=this._getSelectedLinkElement(),n=r();const i=()=>{const e=this._getSelectedLinkElement(),t=r();o&&!e||!o&&t!==n?this._hideUI():this._isUIVisible&&this._balloon.updatePosition(this._getBalloonPositionData()),o=e,n=t};function r(){return t.selection.focus.getAncestors().reverse().find((e=>e.is("element")))}this.listenTo(e.ui,"update",i),this.listenTo(this._balloon,"change:visibleView",i)}get _isFormInPanel(){return!!this.formView&&this._balloon.hasView(this.formView)}get _areActionsInPanel(){return!!this.actionsView&&this._balloon.hasView(this.actionsView)}get _areActionsVisible(){return!!this.actionsView&&this._balloon.visibleView===this.actionsView}get _isUIInPanel(){return this._isFormInPanel||this._areActionsInPanel}get _isUIVisible(){const e=this._balloon.visibleView;return!!this.formView&&e==this.formView||this._areActionsVisible}_getBalloonPositionData(){const e=this.editor.editing.view,t=this.editor.model,o=e.document;let n;if(t.markers.has(Xv)){const t=Array.from(this.editor.editing.mapper.markerNameToElements(Xv)),o=e.createRange(e.createPositionBefore(t[0]),e.createPositionAfter(t[t.length-1]));n=e.domConverter.viewRangeToDom(o)}else n=()=>{const t=this._getSelectedLinkElement();return t?e.domConverter.mapViewToDom(t):e.domConverter.viewRangeToDom(o.selection.getFirstRange())};return{target:n}}_getSelectedLinkElement(){const e=this.editor.editing.view,t=e.document.selection,o=t.getSelectedElement();if(t.isCollapsed||o&&Rk(o))return tx(t.getFirstPosition());{const o=t.getFirstRange().getTrimmed(),n=tx(o.start),i=tx(o.end);return n&&n==i&&e.createRangeIn(n).getTrimmed().isEqual(o)?n:null}}_showFakeVisualSelection(){const e=this.editor.model;e.change((t=>{const o=e.document.selection.getFirstRange();if(e.markers.has(Xv))t.updateMarker(Xv,{range:o});else if(o.start.isAtEnd){const n=o.start.getLastMatchingPosition((({item:t})=>!e.schema.isContent(t)),{boundaries:o});t.addMarker(Xv,{usingOperation:!1,affectsData:!1,range:t.createRange(n,o.end)})}else t.addMarker(Xv,{usingOperation:!1,affectsData:!1,range:o})}))}_hideFakeVisualSelection(){const e=this.editor.model;e.markers.has(Xv)&&e.change((e=>{e.removeMarker(Xv)}))}}function tx(e){return e.getAncestors().find((e=>{return(t=e).is("attributeElement")&&!!t.getCustomProperty("link");var t}))||null}const ox=new RegExp("(^|\\s)(((?:(?:(?:https?|ftp):)?\\/\\/)(?:\\S+(?::\\S*)?@)?(?:(?:[1-9]\\d?|1\\d\\d|2[01]\\d|22[0-3])(?:\\.(?:1?\\d{1,2}|2[0-4]\\d|25[0-5])){2}(?:\\.(?:[1-9]\\d?|1\\d\\d|2[0-4]\\d|25[0-4]))|(((?!www\\.)|(www\\.))(?![-_])(?:[-_a-z0-9\\u00a1-\\uffff]{1,63}\\.)+(?:[a-z\\u00a1-\\uffff]{2,63})))(?::\\d{2,5})?(?:[/?#]\\S*)?)|((www.|(\\S+@))((?![-_])(?:[-_a-z0-9\\u00a1-\\uffff]{1,63}\\.))+(?:[a-z\\u00a1-\\uffff]{2,63})))$","i");class nx extends lr{static get requires(){return[mw,$v]}static get pluginName(){return"AutoLink"}init(){const e=this.editor.model.document.selection;e.on("change:range",(()=>{this.isEnabled=!e.anchor.parent.is("element","codeBlock")})),this._enableTypingHandling()}afterInit(){this._enableEnterHandling(),this._enableShiftEnterHandling(),this._enablePasteLinking()}_expandLinkRange(e,t){return t.textNode&&t.textNode.hasAttribute("linkHref")?xw(t,"linkHref",t.textNode.getAttribute("linkHref"),e):null}_selectEntireLinks(e,t){const o=this.editor.model,n=o.document.selection,i=n.getFirstPosition(),r=n.getLastPosition();let s=t.getJoined(this._expandLinkRange(o,i)||t);s&&(s=s.getJoined(this._expandLinkRange(o,r)||t)),s&&(s.start.isBefore(i)||s.end.isAfter(r))&&e.setSelection(s)}_enablePasteLinking(){const e=this.editor,t=e.model,o=t.document.selection,n=e.plugins.get("ClipboardPipeline"),i=e.commands.get("link");n.on("inputTransformation",((e,n)=>{if(!this.isEnabled||!i.isEnabled||o.isCollapsed||"paste"!==n.method)return;if(o.rangeCount>1)return;const r=o.getFirstRange(),s=n.dataTransfer.getData("text/plain");if(!s)return;const a=s.match(ox);a&&a[2]===s&&(t.change((e=>{this._selectEntireLinks(e,r),i.execute(s)})),e.stop())}),{priority:"high"})}_enableTypingHandling(){const e=this.editor,t=new fw(e.model,(e=>{if(!function(e){return e.length>4&&" "===e[e.length-1]&&" "!==e[e.length-2]}(e))return;const t=ix(e.substr(0,e.length-1));return t?{url:t}:void 0}));t.on("matched:data",((t,o)=>{const{batch:n,range:i,url:r}=o;if(!n.isTyping)return;const s=i.end.getShiftedBy(-1),a=s.getShiftedBy(-r.length),l=e.model.createRange(a,s);this._applyAutoLink(r,l)})),t.bind("isEnabled").to(this)}_enableEnterHandling(){const e=this.editor,t=e.model,o=e.commands.get("enter");o&&o.on("execute",(()=>{const e=t.document.selection.getFirstPosition();if(!e.parent.previousSibling)return;const o=t.createRangeIn(e.parent.previousSibling);this._checkAndApplyAutoLinkOnRange(o)}))}_enableShiftEnterHandling(){const e=this.editor,t=e.model,o=e.commands.get("shiftEnter");o&&o.on("execute",(()=>{const e=t.document.selection.getFirstPosition(),o=t.createRange(t.createPositionAt(e.parent,0),e.getShiftedBy(-1));this._checkAndApplyAutoLinkOnRange(o)}))}_checkAndApplyAutoLinkOnRange(e){const t=this.editor.model,{text:o,range:n}=gw(e,t),i=ix(o);if(i){const e=t.createRange(n.end.getShiftedBy(-i.length),n.end);this._applyAutoLink(i,e)}}_applyAutoLink(e,t){const o=this.editor.model,n=Rv(e,this.editor.config.get("link.defaultProtocol"));this.isEnabled&&function(e,t){return t.schema.checkAttributeInSelection(t.createSelection(e),"linkHref")}(t,o)&&zv(n)&&!function(e){const t=e.start.nodeAfter;return!!t&&t.hasAttribute("linkHref")}(t)&&this._persistAutoLink(n,t)}_persistAutoLink(e,t){const o=this.editor.model,n=this.editor.plugins.get("Delete");o.enqueueChange((i=>{i.setAttribute("linkHref",e,t),o.enqueueChange((()=>{n.requestUndoOnBackspace()}))}))}}function ix(e){const t=ox.exec(e);return t?t[2]:null}var rx=i(3669),sx={attributes:{"data-cke":!0}};sx.setAttributes=Ar(),sx.insert=_r().bind(null,"head"),sx.domAPI=kr(),sx.insertStyleElement=vr();fr()(rx.A,sx);rx.A&&rx.A.locals&&rx.A.locals;class ax{constructor(e,t){this._startElement=e,this._referenceIndent=e.getAttribute("listIndent"),this._isForward="forward"==t.direction,this._includeSelf=!!t.includeSelf,this._sameAttributes=xi(t.sameAttributes||[]),this._sameIndent=!!t.sameIndent,this._lowerIndent=!!t.lowerIndent,this._higherIndent=!!t.higherIndent}static first(e,t){return Qi(new this(e,t)[Symbol.iterator]())}*[Symbol.iterator](){const e=[];for(const{node:t}of lx(this._getStartNode(),this._isForward?"forward":"backward")){const o=t.getAttribute("listIndent");if(othis._referenceIndent){if(!this._higherIndent)continue;if(!this._isForward){e.push(t);continue}}else{if(!this._sameIndent){if(this._higherIndent){e.length&&(yield*e,e.length=0);break}continue}if(this._sameAttributes.some((e=>t.getAttribute(e)!==this._startElement.getAttribute(e))))break}e.length&&(yield*e,e.length=0),yield t}}_getStartNode(){return this._includeSelf?this._startElement:this._isForward?this._startElement.nextSibling:this._startElement.previousSibling}}function*lx(e,t="forward"){const o="forward"==t,n=[];let i=null;for(;ux(e);){let t=null;if(i){const o=e.getAttribute("listIndent"),r=i.getAttribute("listIndent");o>r?n[r]=i:oe.getAttribute("listItemId")!=t))}function vx(e){return Array.from(e).filter((e=>"$graveyard"!==e.root.rootName)).sort(((e,t)=>e.index-t.index))}function xx(e){const t=e.document.selection.getSelectedElement();return t&&e.schema.isObject(t)&&e.schema.isBlock(t)?t:null}function Ex(e,t){return t.checkChild(e.parent,"listItem")&&t.checkChild(e,"$text")&&!t.isObject(e)}function Dx(e){return"numbered"==e||"customNumbered"==e}function Bx(e,t,o){return mx(t,{direction:"forward"}).pop().index>e.index?_x(e,t,o):[]}class Sx extends dr{constructor(e,t){super(e),this._direction=t}refresh(){this.isEnabled=this._checkEnabled()}execute(){const e=this.editor.model,t=Tx(e.document.selection);e.change((e=>{const o=[];Cx(t)&&!gx(t[0])?("forward"==this._direction&&o.push(...yx(t,e)),o.push(...wx(t[0],e))):"forward"==this._direction?o.push(...yx(t,e,{expand:!0})):o.push(...function(e,t){const o=bx(e=xi(e)),n=new Set,i=Math.min(...o.map((e=>e.getAttribute("listIndent")))),r=new Map;for(const e of o)r.set(e,ax.first(e,{lowerIndent:!0}));for(const e of o){if(n.has(e))continue;n.add(e);const o=e.getAttribute("listIndent")-1;if(o<0)Ax(e,t);else{if(e.getAttribute("listIndent")==i){const o=Bx(e,r.get(e),t);for(const e of o)n.add(e);if(o.length)continue}t.setAttribute("listIndent",o,e)}}return vx(n)}(t,e));for(const t of o){if(!t.hasAttribute("listType"))continue;const o=ax.first(t,{sameIndent:!0});o&&e.setAttribute("listType",o.getAttribute("listType"),t)}this._fireAfterExecute(o)}))}_fireAfterExecute(e){this.fire("afterExecute",vx(new Set(e)))}_checkEnabled(){let e=Tx(this.editor.model.document.selection),t=e[0];if(!t)return!1;if("backward"==this._direction)return!0;if(Cx(e)&&!gx(e[0]))return!0;e=bx(e),t=e[0];const o=ax.first(t,{sameIndent:!0});return!!o&&o.getAttribute("listType")==t.getAttribute("listType")}}function Tx(e){const t=Array.from(e.getSelectedBlocks()),o=t.findIndex((e=>!ux(e)));return-1!=o&&(t.length=o),t}class Ix extends dr{constructor(e,t,o={}){super(e),this.type=t,this._listWalkerOptions=o.multiLevel?{higherIndent:!0,lowerIndent:!0,sameAttributes:[]}:void 0}refresh(){this.value=this._getValue(),this.isEnabled=this._checkEnabled()}execute(e={}){const t=this.editor.model,o=t.document,n=xx(t),i=Array.from(o.selection.getSelectedBlocks()).filter((e=>t.schema.checkAttribute(e,"listType")||Ex(e,t.schema))),r=void 0!==e.forceValue?!e.forceValue:this.value;t.change((s=>{if(r){const e=i[i.length-1],t=mx(e,{direction:"forward"}),o=[];t.length>1&&o.push(...wx(t[1],s)),o.push(...Ax(i,s)),o.push(...function(e,t){const o=[];let n=Number.POSITIVE_INFINITY;for(const{node:i}of lx(e.nextSibling,"forward")){const e=i.getAttribute("listIndent");if(0==e)break;e{const{firstElement:r,lastElement:s}=this._getMergeSubjectElements(o,e),a=r.getAttribute("listIndent")||0,l=s.getAttribute("listIndent"),c=s.getAttribute("listItemId");if(a!=l){const e=(d=s,Array.from(new ax(d,{direction:"forward",higherIndent:!0})));n.push(...yx([s,...e],i,{indentBy:a-l,expand:a{const t=wx(this._getStartBlock(),e);this._fireAfterExecute(t)}))}_fireAfterExecute(e){this.fire("afterExecute",vx(new Set(e)))}_checkEnabled(){const e=this.editor.model.document.selection,t=this._getStartBlock();return e.isCollapsed&&ux(t)&&!gx(t)}_getStartBlock(){const e=this.editor.model.document.selection.getFirstPosition().parent;return"before"==this._direction?e:e.nextSibling}}class Mx extends lr{static get pluginName(){return"ListUtils"}expandListBlocksToCompleteList(e){return kx(e)}isFirstBlockOfListItem(e){return gx(e)}isListItemBlock(e){return ux(e)}expandListBlocksToCompleteItems(e,t={}){return bx(e,t)}isNumberedListType(e){return Dx(e)}}function Rx(e){return e.is("element","ol")||e.is("element","ul")}function zx(e){return e.is("element","li")}function Vx(e,t,o,n=Lx(o,t)){return e.createAttributeElement(Nx(o),null,{priority:2*t/100-100,id:n})}function Ox(e,t,o){return e.createAttributeElement("li",null,{priority:(2*t+1)/100-100,id:o})}function Nx(e){return"numbered"==e||"customNumbered"==e?"ol":"ul"}function Lx(e,t){return`list-${e}-${t}`}function Hx(e,t){const o=e.nodeBefore;if(ux(o)){let e=o;for(const{node:o}of lx(e,"backward"))if(e=o,t.has(e))return;t.set(o,e)}else{const o=e.nodeAfter;ux(o)&&t.set(o,o)}}function jx(){return(e,t,o)=>{const{writer:n,schema:i}=o;if(!t.modelRange)return;const r=Array.from(t.modelRange.getItems({shallow:!0})).filter((e=>i.checkAttribute(e,"listItemId")));if(!r.length)return;const s=dx.next(),a=function(e){let t=0,o=e.parent;for(;o;){if(zx(o))t++;else{const e=o.previousSibling;e&&zx(e)&&t++}o=o.parent}return t}(t.viewItem);let l=t.viewItem.parent&&t.viewItem.parent.is("element","ol")?"numbered":"bulleted";const c=r[0].getAttribute("listType");c&&(l=c);const d={listItemId:s,listIndent:a,listType:l};for(const e of r)e.hasAttribute("listItemId")||n.setAttributes(d,e);r.length>1&&r[1].getAttribute("listItemId")!=d.listItemId&&o.keepEmptyElement(r[0])}}function qx(e,t,o,{dataPipeline:n}={}){const i=function(e){return(t,o)=>{const n=[];for(const o of e)t.hasAttribute(o)&&n.push(`attribute:${o}`);return!!n.every((e=>!1!==o.test(t,e)))&&(n.forEach((e=>o.consume(t,e))),!0)}}(e);return(r,s,a)=>{const{writer:l,mapper:c,consumable:d}=a,u=s.item;if(!e.includes(s.attributeKey))return;if(!i(u,d))return;const h=function(e,t,o){const n=o.createRangeOn(e),i=t.toViewRange(n).getTrimmed();return i.end.nodeBefore}(u,c,o);Wx(h,l,c),function(e,t){let o=e.parent;for(;o.is("attributeElement")&&["ul","ol","li"].includes(o.name);){const n=o.parent;t.unwrap(t.createRangeOn(e),o),o=n}}(h,l);const m=function(e,t,o,n,{dataPipeline:i}){let r=n.createRangeOn(t);if(!gx(e))return r;for(const s of o){if("itemMarker"!=s.scope)continue;const o=s.createElement(n,e,{dataPipeline:i});if(!o)continue;if(n.setCustomProperty("listItemMarker",!0,o),s.canInjectMarkerIntoElement&&s.canInjectMarkerIntoElement(e)?n.insert(n.createPositionAt(t,0),o):(n.insert(r.start,o),r=n.createRange(n.createPositionBefore(o),n.createPositionAfter(t))),!s.createWrapperElement||!s.canWrapElement)continue;const a=s.createWrapperElement(n,e,{dataPipeline:i});n.setCustomProperty("listItemWrapper",!0,a),s.canWrapElement(e)?r=n.wrap(r,a):(r=n.wrap(n.createRangeOn(o),a),r=n.createRange(r.start,n.createPositionAfter(t)))}return r}(u,h,t,l,{dataPipeline:n});!function(e,t,o,n){if(!e.hasAttribute("listIndent"))return;const i=e.getAttribute("listIndent");let r=e;for(let e=i;e>=0;e--){const i=Ox(n,e,r.getAttribute("listItemId")),s=Vx(n,e,r.getAttribute("listType"));for(const e of o)"list"!=e.scope&&"item"!=e.scope||!r.hasAttribute(e.attributeName)||e.setAttributeOnDowncast(n,r.getAttribute(e.attributeName),"list"==e.scope?s:i);if(t=n.wrap(t,i),t=n.wrap(t,s),0==e)break;if(r=ax.first(r,{lowerIndent:!0}),!r)break}}(u,m,t,l)}}function Ux(e,{dataPipeline:t}={}){return(o,{writer:n})=>{if(!$x(o,e))return null;if(!t)return n.createContainerElement("span",{class:"ck-list-bogus-paragraph"});const i=n.createContainerElement("p");return n.setCustomProperty("dataPipeline:transparentRendering",!0,i),i}}function Wx(e,t,o){for(;e.parent.is("attributeElement")&&e.parent.getCustomProperty("listItemWrapper");)t.unwrap(t.createRangeOn(e),e.parent);const n=[];i(t.createPositionBefore(e).getWalker({direction:"backward"})),i(t.createRangeIn(e).getWalker());for(const e of n)t.remove(e);function i(e){for(const{item:t}of e){if(t.is("element")&&o.toModelElement(t))break;t.is("element")&&t.getCustomProperty("listItemMarker")&&n.push(t)}}}function $x(e,t,o=hx(e)){if(!ux(e))return!1;for(const o of e.getAttributeKeys())if(!o.startsWith("selection:")&&!t.includes(o))return!1;return o.length<2}var Gx=i(7875),Kx={attributes:{"data-cke":!0}};Kx.setAttributes=Ar(),Kx.insert=_r().bind(null,"head"),Kx.domAPI=kr(),Kx.insertStyleElement=vr();fr()(Gx.A,Kx);Gx.A&&Gx.A.locals&&Gx.A.locals;var Zx=i(532),Jx={attributes:{"data-cke":!0}};Jx.setAttributes=Ar(),Jx.insert=_r().bind(null,"head"),Jx.domAPI=kr(),Jx.insertStyleElement=vr();fr()(Zx.A,Jx);Zx.A&&Zx.A.locals&&Zx.A.locals;const Yx=["listType","listIndent","listItemId"];class Qx extends lr{static get pluginName(){return"ListEditing"}static get requires(){return[Fw,mw,Mx,H_]}constructor(e){super(e),this._downcastStrategies=[],e.config.define("list.multiBlock",!0)}init(){const e=this.editor,t=e.model,o=e.config.get("list.multiBlock");if(e.plugins.has("LegacyListEditing"))throw new E("list-feature-conflict",this,{conflictPlugin:"LegacyListEditing"});t.schema.register("$listItem",{allowAttributes:Yx}),o?(t.schema.extend("$container",{allowAttributesOf:"$listItem"}),t.schema.extend("$block",{allowAttributesOf:"$listItem"}),t.schema.extend("$blockObject",{allowAttributesOf:"$listItem"})):t.schema.register("listItem",{inheritAllFrom:"$block",allowAttributesOf:"$listItem"});for(const e of Yx)t.schema.setAttributeProperties(e,{copyOnReplace:!0});e.commands.add("numberedList",new Ix(e,"numbered")),e.commands.add("bulletedList",new Ix(e,"bulleted")),e.commands.add("customNumberedList",new Ix(e,"customNumbered",{multiLevel:!0})),e.commands.add("customBulletedList",new Ix(e,"customBulleted",{multiLevel:!0})),e.commands.add("indentList",new Sx(e,"forward")),e.commands.add("outdentList",new Sx(e,"backward")),e.commands.add("splitListItemBefore",new Fx(e,"before")),e.commands.add("splitListItemAfter",new Fx(e,"after")),o&&(e.commands.add("mergeListItemBackward",new Px(e,"backward")),e.commands.add("mergeListItemForward",new Px(e,"forward"))),this._setupDeleteIntegration(),this._setupEnterIntegration(),this._setupTabIntegration(),this._setupClipboardIntegration(),this._setupAccessibilityIntegration()}afterInit(){const e=this.editor.commands,t=e.get("indent"),o=e.get("outdent");t&&t.registerChildCommand(e.get("indentList"),{priority:"high"}),o&&o.registerChildCommand(e.get("outdentList"),{priority:"lowest"}),this._setupModelPostFixing(),this._setupConversion()}registerDowncastStrategy(e){this._downcastStrategies.push(e)}getListAttributeNames(){return[...Yx,...this._downcastStrategies.map((e=>e.attributeName))]}_setupDeleteIntegration(){const e=this.editor,t=e.commands.get("mergeListItemBackward"),o=e.commands.get("mergeListItemForward");this.listenTo(e.editing.view.document,"delete",((n,i)=>{const r=e.model.document.selection;xx(e.model)||e.model.change((()=>{const s=r.getFirstPosition();if(r.isCollapsed&&"backward"==i.direction){if(!s.isAtStart)return;const o=s.parent;if(!ux(o))return;if(ax.first(o,{sameAttributes:"listType",sameIndent:!0})||0!==o.getAttribute("listIndent")){if(!t||!t.isEnabled)return;t.execute({shouldMergeOnBlocksContentLevel:Xx(e.model,"backward")})}else fx(o)||e.execute("splitListItemAfter"),e.execute("outdentList");i.preventDefault(),n.stop()}else{if(r.isCollapsed&&!r.getLastPosition().isAtEnd)return;if(!o||!o.isEnabled)return;o.execute({shouldMergeOnBlocksContentLevel:Xx(e.model,"forward")}),i.preventDefault(),n.stop()}}))}),{context:"li"})}_setupEnterIntegration(){const e=this.editor,t=e.model,o=e.commands,n=o.get("enter");this.listenTo(e.editing.view.document,"enter",((o,n)=>{const i=t.document,r=i.selection.getFirstPosition().parent;if(i.selection.isCollapsed&&ux(r)&&r.isEmpty&&!n.isSoft){const t=gx(r),i=fx(r);t&&i?(e.execute("outdentList"),n.preventDefault(),o.stop()):t&&!i?(e.execute("splitListItemAfter"),n.preventDefault(),o.stop()):i&&(e.execute("splitListItemBefore"),n.preventDefault(),o.stop())}}),{context:"li"}),this.listenTo(n,"afterExecute",(()=>{const t=o.get("splitListItemBefore");if(t.refresh(),!t.isEnabled)return;2===hx(e.model.document.selection.getLastPosition().parent).length&&t.execute()}))}_setupTabIntegration(){const e=this.editor;this.listenTo(e.editing.view.document,"tab",((t,o)=>{const n=o.shiftKey?"outdentList":"indentList";this.editor.commands.get(n).isEnabled&&(e.execute(n),o.stopPropagation(),o.preventDefault(),t.stop())}),{context:"li"})}_setupConversion(){const e=this.editor,t=e.model,o=this.getListAttributeNames(),n=e.config.get("list.multiBlock"),i=n?"paragraph":"listItem";e.conversion.for("upcast").elementToElement({view:"li",model:(e,{writer:t})=>t.createElement(i,{listType:""})}).elementToElement({view:"p",model:(e,{writer:t})=>e.parent&&e.parent.is("element","li")?t.createElement(i,{listType:""}):null,converterPriority:"high"}).add((e=>{e.on("element:li",jx())})),n||e.conversion.for("downcast").elementToElement({model:"listItem",view:"p"}),e.conversion.for("editingDowncast").elementToElement({model:i,view:Ux(o),converterPriority:"high"}).add((e=>{var n;e.on("attribute",qx(o,this._downcastStrategies,t)),e.on("remove",(n=t.schema,(e,t,o)=>{const{writer:i,mapper:r}=o,s=e.name.split(":")[1];if(!n.checkAttribute(s,"listItemId"))return;const a=r.toViewPosition(t.position),l=t.position.getShiftedBy(t.length),c=r.toViewPosition(l,{isPhantom:!0}),d=i.createRange(a,c).getTrimmed().end.nodeBefore;d&&Wx(d,i,r)}))})),e.conversion.for("dataDowncast").elementToElement({model:i,view:Ux(o,{dataPipeline:!0}),converterPriority:"high"}).add((e=>{e.on("attribute",qx(o,this._downcastStrategies,t,{dataPipeline:!0}))}));const r=(s=this._downcastStrategies,a=e.editing.view,(e,t)=>{if(t.modelPosition.offset>0)return;const o=t.modelPosition.parent;if(!ux(o))return;if(!s.some((e=>"itemMarker"==e.scope&&e.canInjectMarkerIntoElement&&e.canInjectMarkerIntoElement(o))))return;const n=t.mapper.toViewElement(o),i=a.createRangeIn(n),r=i.getWalker();let l=i.start;for(const{item:e}of r){if(e.is("element")&&t.mapper.toModelElement(e)||e.is("$textProxy"))break;e.is("element")&&e.getCustomProperty("listItemMarker")&&(l=a.createPositionAfter(e),r.skip((({previousPosition:e})=>!e.isEqual(l))))}t.viewPosition=l});var s,a;e.editing.mapper.on("modelToViewPosition",r),e.data.mapper.on("modelToViewPosition",r),this.listenTo(t.document,"change:data",function(e,t,o,n){return()=>{const n=e.document.differ.getChanges(),s=[],a=new Map,l=new Set;for(const e of n)if("insert"==e.type&&"$text"!=e.name)Hx(e.position,a),e.attributes.has("listItemId")?l.add(e.position.nodeAfter):Hx(e.position.getShiftedBy(e.length),a);else if("remove"==e.type&&e.attributes.has("listItemId"))Hx(e.position,a);else if("attribute"==e.type){const t=e.range.start.nodeAfter;o.includes(e.attributeKey)?(Hx(e.range.start,a),null===e.attributeNewValue?(Hx(e.range.start.getShiftedBy(1),a),r(t)&&s.push(t)):l.add(t)):ux(t)&&r(t)&&s.push(t)}for(const e of a.values())s.push(...i(e,l));for(const e of new Set(s))t.reconvertItem(e)};function i(e,t){const n=[],i=new Set,a=[];for(const{node:l,previous:c}of lx(e,"forward")){if(i.has(l))continue;const e=l.getAttribute("listIndent");c&&eo.includes(e))));const d=mx(l,{direction:"forward"});for(const e of d)i.add(e),(r(e,d)||s(e,a,t))&&n.push(e)}return n}function r(e,i){const r=t.mapper.toViewElement(e);if(!r)return!1;if(n.fire("checkElement",{modelElement:e,viewElement:r}))return!0;if(!e.is("element","paragraph")&&!e.is("element","listItem"))return!1;const s=$x(e,o,i);return!(!s||!r.is("element","p"))||!(s||!r.is("element","span"))}function s(e,o,i){if(i.has(e))return!1;const r=t.mapper.toViewElement(e);let s=o.length-1;for(let e=r.parent;!e.is("editableElement");e=e.parent){const t=zx(e),i=Rx(e);if(!i&&!t)continue;const r="checkAttributes:"+(t?"item":"list");if(n.fire(r,{viewElement:e,modelAttributes:o[s]}))break;if(i&&(s--,s<0))return!1}return!0}}(t,e.editing,o,this),{priority:"high"}),this.on("checkAttributes:item",((e,{viewElement:t,modelAttributes:o})=>{t.id!=o.listItemId&&(e.return=!0,e.stop())})),this.on("checkAttributes:list",((e,{viewElement:t,modelAttributes:o})=>{t.name==Nx(o.listType)&&t.id==Lx(o.listType,o.listIndent)||(e.return=!0,e.stop())}))}_setupModelPostFixing(){const e=this.editor.model,t=this.getListAttributeNames();e.document.registerPostFixer((o=>function(e,t,o,n){const i=e.document.differ.getChanges(),r=new Map,s=n.editor.config.get("list.multiBlock");let a=!1;for(const n of i){if("insert"==n.type&&"$text"!=n.name){const i=n.position.nodeAfter;if(!e.schema.checkAttribute(i,"listItemId"))for(const e of Array.from(i.getAttributeKeys()))o.includes(e)&&(t.removeAttribute(e,i),a=!0);Hx(n.position,r),n.attributes.has("listItemId")||Hx(n.position.getShiftedBy(n.length),r);for(const{item:t,previousPosition:o}of e.createRangeIn(i))ux(t)&&Hx(o,r)}else"remove"==n.type?Hx(n.position,r):"attribute"==n.type&&o.includes(n.attributeKey)&&(Hx(n.range.start,r),null===n.attributeNewValue&&Hx(n.range.start.getShiftedBy(1),r));if(!s&&"attribute"==n.type&&Yx.includes(n.attributeKey)){const e=n.range.start.nodeAfter;null===n.attributeNewValue&&e&&e.is("element","listItem")?(t.rename(e,"paragraph"),a=!0):null===n.attributeOldValue&&e&&e.is("element")&&"listItem"!=e.name&&(t.rename(e,"listItem"),a=!0)}}const l=new Set;for(const e of r.values())a=n.fire("postFixer",{listNodes:new cx(e),listHead:e,writer:t,seenIds:l})||a;return a}(e,o,t,this))),this.on("postFixer",((e,{listNodes:t,writer:o})=>{e.return=function(e,t){let o=0,n=-1,i=null,r=!1;for(const{node:s}of e){const e=s.getAttribute("listIndent");if(e>o){let a;null===i?(i=e-o,a=o):(i>e&&(i=e),a=e-i),a>n+1&&(a=n+1),t.setAttribute("listIndent",a,s),r=!0,n=a}else i=null,o=e+1,n=e}return r}(t,o)||e.return}),{priority:"high"}),this.on("postFixer",((e,{listNodes:t,writer:o,seenIds:n})=>{e.return=function(e,t,o){const n=new Set;let i=!1;for(const{node:r}of e){if(n.has(r))continue;let e=r.getAttribute("listType"),s=r.getAttribute("listItemId");if(t.has(s)&&(s=dx.next()),t.add(s),r.is("element","listItem"))r.getAttribute("listItemId")!=s&&(o.setAttribute("listItemId",s,r),i=!0);else for(const t of mx(r,{direction:"forward"}))n.add(t),t.getAttribute("listType")!=e&&(s=dx.next(),e=t.getAttribute("listType")),t.getAttribute("listItemId")!=s&&(o.setAttribute("listItemId",s,t),i=!0)}return i}(t,n,o)||e.return}),{priority:"high"})}_setupClipboardIntegration(){const e=this.editor.model,t=this.editor.plugins.get("ClipboardPipeline");this.listenTo(e,"insertContent",function(e){return(t,[o,n])=>{const i=o.is("documentFragment")?Array.from(o.getChildren()):[o];if(!i.length)return;const r=(n?e.createSelection(n):e.document.selection).getFirstPosition();let s;if(ux(r.parent))s=r.parent;else{if(!ux(r.nodeBefore))return;s=r.nodeBefore}e.change((e=>{const t=s.getAttribute("listType"),o=s.getAttribute("listIndent"),n=i[0].getAttribute("listIndent")||0,r=Math.max(o-n,0);for(const o of i){const n=ux(o);s.is("element","listItem")&&o.is("element","paragraph")&&e.rename(o,"listItem"),e.setAttributes({listIndent:(n?o.getAttribute("listIndent"):0)+r,listItemId:n?o.getAttribute("listItemId"):dx.next(),listType:t},o)}}))}}(e),{priority:"high"}),this.listenTo(t,"outputTransformation",((t,o)=>{e.change((e=>{const t=Array.from(o.content.getChildren()),n=t[t.length-1];if(t.length>1&&n.is("element")&&n.isEmpty){t.slice(0,-1).every(ux)&&e.remove(n)}if("copy"==o.method||"cut"==o.method){const t=Array.from(o.content.getChildren());Cx(t)&&Ax(t,e)}}))}))}_setupAccessibilityIntegration(){const e=this.editor,t=e.t;e.accessibility.addKeystrokeInfoGroup({id:"list",label:t("Keystrokes that can be used in a list"),keystrokes:[{label:t("Increase list item indent"),keystroke:"Tab"},{label:t("Decrease list item indent"),keystroke:"Shift+Tab"}]})}}function Xx(e,t){const o=e.document.selection;if(!o.isCollapsed)return!xx(e);if("forward"===t)return!0;const n=o.getFirstPosition().parent,i=n.previousSibling;return!e.schema.isObject(i)&&(!!i.isEmpty||Cx([n,i]))}function eE(e,t,o,n){e.ui.componentFactory.add(t,(()=>{const i=tE(Em,e,t,o,n);return i.set({tooltip:!0,isToggleable:!0}),i})),e.ui.componentFactory.add(`menuBar:${t}`,(()=>{const i=tE(ip,e,t,o,n);return i.set({role:"menuitemcheckbox",isToggleable:!0}),i}))}function tE(e,t,o,n,i){const r=t.commands.get(o),s=new e(t.locale);return s.set({label:n,icon:i}),s.bind("isOn","isEnabled").to(r,"value","isEnabled"),s.on("execute",(()=>{t.execute(o),t.editing.view.focus()})),s}class oE extends lr{static get pluginName(){return"ListUI"}init(){const e=this.editor.t;this.editor.ui.componentFactory.has("numberedList")||eE(this.editor,"numberedList",e("Numbered List"),qh.numberedList),this.editor.ui.componentFactory.has("bulletedList")||eE(this.editor,"bulletedList",e("Bulleted List"),qh.bulletedList)}}class nE extends lr{static get requires(){return[Qx,oE]}static get pluginName(){return"List"}}const iE={},rE={},sE={},aE=[{listStyle:"disc",typeAttribute:"disc",listType:"bulleted"},{listStyle:"circle",typeAttribute:"circle",listType:"bulleted"},{listStyle:"square",typeAttribute:"square",listType:"bulleted"},{listStyle:"decimal",typeAttribute:"1",listType:"numbered"},{listStyle:"decimal-leading-zero",typeAttribute:null,listType:"numbered"},{listStyle:"lower-roman",typeAttribute:"i",listType:"numbered"},{listStyle:"upper-roman",typeAttribute:"I",listType:"numbered"},{listStyle:"lower-alpha",typeAttribute:"a",listType:"numbered"},{listStyle:"upper-alpha",typeAttribute:"A",listType:"numbered"},{listStyle:"lower-latin",typeAttribute:"a",listType:"numbered"},{listStyle:"upper-latin",typeAttribute:"A",listType:"numbered"}];for(const{listStyle:e,typeAttribute:t,listType:o}of aE)iE[e]=o,rE[e]=t,t&&(sE[t]=e);var lE=i(1911),cE={attributes:{"data-cke":!0}};cE.setAttributes=Ar(),cE.insert=_r().bind(null,"head"),cE.domAPI=kr(),cE.insertStyleElement=vr();fr()(lE.A,cE);lE.A&&lE.A.locals&&lE.A.locals;var dE=i(1330),uE={attributes:{"data-cke":!0}};uE.setAttributes=Ar(),uE.insert=_r().bind(null,"head"),uE.domAPI=kr(),uE.insertStyleElement=vr();fr()(dE.A,uE);dE.A&&dE.A.locals&&dE.A.locals;class hE extends dr{constructor(e){super(e),this.on("execute",(()=>{this.refresh()}),{priority:"highest"})}refresh(){const e=this._getSelectedItems();this.value=this._getValue(e),this.isEnabled=!!e.length}execute(e={}){this.editor.model.change((t=>{const o=this._getSelectedItems(),n=void 0===e.forceValue?!this._getValue(o):e.forceValue;for(const e of o)n?t.setAttribute("todoListChecked",!0,e):t.removeAttribute("todoListChecked",e)}))}_getValue(e){return e.every((e=>e.getAttribute("todoListChecked")))}_getSelectedItems(){const e=this.editor.model,t=e.schema,o=e.document.selection.getFirstRange(),n=o.start.parent,i=[];t.checkAttribute(n,"todoListChecked")&&i.push(...hx(n));for(const e of o.getItems({shallow:!0}))t.checkAttribute(e,"todoListChecked")&&!i.includes(e)&&i.push(...hx(e));return i}}class mE extends La{constructor(){super(...arguments),this.domEventType=["change"]}onDomEvent(e){if(e.target){const t=this.view.domConverter.mapDomToView(e.target);t&&t.is("element","input")&&"checkbox"==t.getAttribute("type")&&t.findAncestor({classes:"todo-list__label"})&&this.fire("todoCheckboxChange",e)}}}const pE=yi("Ctrl+Enter");class gE extends lr{static get pluginName(){return"TodoListEditing"}static get requires(){return[Qx]}init(){const e=this.editor,t=e.model,o=e.editing,n=e.plugins.get(Qx),i=e.config.get("list.multiBlock")?"paragraph":"listItem";e.commands.add("todoList",new Ix(e,"todo")),e.commands.add("checkTodoList",new hE(e)),o.view.addObserver(mE),t.schema.extend("$listItem",{allowAttributes:"todoListChecked"}),t.schema.addAttributeCheck((e=>{const t=e.last;if(!t.getAttribute("listItemId")||"todo"!=t.getAttribute("listType"))return!1}),"todoListChecked"),e.conversion.for("upcast").add((e=>{e.on("element:input",((e,t,o)=>{const n=t.modelCursor,i=n.parent,r=t.viewItem;if(!o.consumable.test(r,{name:!0}))return;if("checkbox"!=r.getAttribute("type")||!n.isAtStart||!i.hasAttribute("listType"))return;o.consumable.consume(r,{name:!0});const s=o.writer;s.setAttribute("listType","todo",i),t.viewItem.hasAttribute("checked")&&s.setAttribute("todoListChecked",!0,i),t.modelRange=s.createRange(n)})),e.on("element:label",fE({name:"label",classes:"todo-list__label"})),e.on("element:label",fE({name:"label",classes:["todo-list__label","todo-list__label_without-description"]})),e.on("element:span",fE({name:"span",classes:"todo-list__label__description"})),e.on("element:ul",function(e){const t=new Hr(e);return(e,o,n)=>{const i=t.match(o.viewItem);if(!i)return;const r=i.match;r.name=!1,n.consumable.consume(o.viewItem,r)}}({name:"ul",classes:"todo-list"}))})),e.conversion.for("downcast").elementToElement({model:i,view:(e,{writer:t})=>{if(bE(e,n.getListAttributeNames()))return t.createContainerElement("span",{class:"todo-list__label__description"})},converterPriority:"highest"}),n.registerDowncastStrategy({scope:"list",attributeName:"listType",setAttributeOnDowncast(e,t,o){"todo"==t?e.addClass("todo-list",o):e.removeClass("todo-list",o)}}),n.registerDowncastStrategy({scope:"itemMarker",attributeName:"todoListChecked",createElement(e,t,{dataPipeline:o}){if("todo"!=t.getAttribute("listType"))return null;const n=e.createUIElement("input",{type:"checkbox",...t.getAttribute("todoListChecked")?{checked:"checked"}:null,...o?{disabled:"disabled"}:{tabindex:"-1"}});if(o)return n;const i=e.createContainerElement("span",{contenteditable:"false"},n);return i.getFillerOffset=()=>null,i},canWrapElement:e=>bE(e,n.getListAttributeNames()),createWrapperElement(e,t,{dataPipeline:o}){const i=["todo-list__label"];return bE(t,n.getListAttributeNames())||i.push("todo-list__label_without-description"),e.createAttributeElement(o?"label":"span",{class:i.join(" ")})}}),n.on("checkElement",((e,{modelElement:t,viewElement:o})=>{const i=bE(t,n.getListAttributeNames());o.hasClass("todo-list__label__description")!=i&&(e.return=!0,e.stop())})),n.on("checkElement",((t,{modelElement:o,viewElement:n})=>{const i="todo"==o.getAttribute("listType")&&gx(o);let r=!1;const s=e.editing.view.createPositionBefore(n).getWalker({direction:"backward"});for(const{item:t}of s){if(t.is("element")&&e.editing.mapper.toModelElement(t))break;t.is("element","input")&&"checkbox"==t.getAttribute("type")&&(r=!0)}r!=i&&(t.return=!0,t.stop())})),n.on("postFixer",((e,{listNodes:t,writer:o})=>{for(const{node:n,previousNodeInList:i}of t){if(!i)continue;if(i.getAttribute("listItemId")!=n.getAttribute("listItemId"))continue;const t=i.hasAttribute("todoListChecked"),r=n.hasAttribute("todoListChecked");r&&!t?(o.removeAttribute("todoListChecked",n),e.return=!0):!r&&t&&(o.setAttribute("todoListChecked",!0,n),e.return=!0)}})),t.document.registerPostFixer((e=>{const o=t.document.differ.getChanges();let n=!1;for(const t of o)if("attribute"==t.type&&"listType"==t.attributeKey){const o=t.range.start.nodeAfter;"todo"==t.attributeOldValue&&o.hasAttribute("todoListChecked")&&(e.removeAttribute("todoListChecked",o),n=!0)}else if("insert"==t.type&&"$text"!=t.name)for(const{item:o}of e.createRangeOn(t.position.nodeAfter))o.is("element")&&"todo"!=o.getAttribute("listType")&&o.hasAttribute("todoListChecked")&&(e.removeAttribute("todoListChecked",o),n=!0);return n})),this.listenTo(o.view.document,"keydown",((t,o)=>{_i(o)===pE&&(e.execute("checkTodoList"),t.stop())}),{priority:"high"}),this.listenTo(o.view.document,"todoCheckboxChange",((e,t)=>{const n=t.target;if(!n||!n.is("element","input"))return;const i=o.view.createPositionAfter(n),r=o.mapper.toModelPosition(i).parent;r&&ux(r)&&"todo"==r.getAttribute("listType")&&this._handleCheckmarkChange(r)})),this.listenTo(o.view.document,"arrowKey",function(e,t){return(o,n)=>{const i=Ci(n.keyCode,t.contentLanguageDirection),r=e.schema,s=e.document.selection;if(!s.isCollapsed)return;const a=s.getFirstPosition(),l=a.parent;if("right"==i&&a.isAtEnd){const t=r.getNearestSelectionRange(e.createPositionAfter(l),"forward");if(!t)return;const i=t.start.parent;i&&ux(i)&&"todo"==i.getAttribute("listType")&&(e.change((e=>e.setSelection(t))),n.preventDefault(),n.stopPropagation(),o.stop())}else if("left"==i&&a.isAtStart&&ux(l)&&"todo"==l.getAttribute("listType")){const t=r.getNearestSelectionRange(e.createPositionBefore(l),"backward");if(!t)return;e.change((e=>e.setSelection(t))),n.preventDefault(),n.stopPropagation(),o.stop()}}}(t,e.locale),{context:"$text"}),this.listenTo(o.mapper,"viewToModelPosition",((e,o)=>{const n=o.viewPosition.parent,i=n.is("attributeElement","li")&&0==o.viewPosition.offset,r=kE(n)&&o.viewPosition.offset<=1,s=n.is("element","span")&&"false"==n.getAttribute("contenteditable")&&kE(n.parent);if(!i&&!r&&!s)return;const a=o.modelPosition.nodeAfter;a&&"todo"==a.getAttribute("listType")&&(o.modelPosition=t.createPositionAt(a,0))}),{priority:"low"}),this._initAriaAnnouncements()}_handleCheckmarkChange(e){const t=this.editor,o=t.model,n=Array.from(o.document.selection.getRanges());o.change((o=>{o.setSelection(e,"end"),t.execute("checkTodoList"),o.setSelection(n)}))}_initAriaAnnouncements(){const{model:e,ui:t,t:o}=this.editor;let n=null;t&&e.document.selection.on("change:range",(()=>{const i=e.document.selection.focus.parent,r=wE(n),s=wE(i);r&&!s?t.ariaLiveAnnouncer.announce(o("Leaving a to-do list")):!r&&s&&t.ariaLiveAnnouncer.announce(o("Entering a to-do list")),n=i}))}}function fE(e){const t=new Hr(e);return(e,o,n)=>{const i=t.match(o.viewItem);i&&n.consumable.consume(o.viewItem,i.match)&&Object.assign(o,n.convertChildren(o.viewItem,o.modelCursor))}}function bE(e,t){return(e.is("element","paragraph")||e.is("element","listItem"))&&"todo"==e.getAttribute("listType")&&gx(e)&&function(e,t){for(const o of e.getAttributeKeys())if(!o.startsWith("selection:")&&!t.includes(o))return!1;return!0}(e,t)}function kE(e){return!!e&&e.is("attributeElement")&&e.hasClass("todo-list__label")}function wE(e){return!!e&&(!(!e.is("element","paragraph")&&!e.is("element","listItem"))&&"todo"==e.getAttribute("listType"))}class _E extends lr{static get pluginName(){return"TodoListUI"}init(){const e=this.editor.t;eE(this.editor,"todoList",e("To-do List"),qh.todoList)}}var yE=i(5484),AE={attributes:{"data-cke":!0}};AE.setAttributes=Ar(),AE.insert=_r().bind(null,"head"),AE.domAPI=kr(),AE.insertStyleElement=vr();fr()(yE.A,AE);yE.A&&yE.A.locals&&yE.A.locals;class CE extends lr{static get requires(){return[gE,_E]}static get pluginName(){return"TodoList"}}const vE=Symbol("isOPCodeBlock");function xE(e){return!!e.getCustomProperty(vE)&&Rk(e)}function EE(e){const t=e.getSelectedElement();return!(!t||!xE(t))}function DE(e,t,o){const n=t.createContainerElement("pre",{title:window.I18n.t("js.editor.macro.toolbar_help")});return BE(t,e,n),function(e,t,o){return t.setCustomProperty(vE,!0,e),zk(e,t,{label:o})}(n,t,o)}function BE(e,t,o){const n=(t.getAttribute("opCodeblockLanguage")||"language-text").replace(/^language-/,""),i=e.createContainerElement("div",{class:"op-uc-code-block--language"});SE(e,n,i,"text"),e.insert(e.createPositionAt(o,0),i);SE(e,t.getAttribute("opCodeblockContent"),o,"(empty)")}function SE(e,t,o,n){const i=e.createText(t||n);e.insert(e.createPositionAt(o,0),i)}class TE extends La{constructor(e){super(e),this.domEventType="dblclick"}onDomEvent(e){this.fire(e.type,e)}}class IE extends lr{static get pluginName(){return"CodeBlockEditing"}init(){const e=this.editor,t=e.model.schema,o=e.conversion,n=e.editing.view,i=n.document,r=Gk(e);var s,a;t.register("codeblock",{isObject:!0,isBlock:!0,allowContentOf:"$block",allowWhere:["$root","$block"],allowIn:["$root"],allowAttributes:["opCodeblockLanguage","opCodeblockContent"]}),o.for("upcast").add(function(){return t=>{t.on("element:pre",e,{priority:"high"})};function e(e,t,o){if(!o.consumable.test(t.viewItem,{name:!0}))return;const n=Array.from(t.viewItem.getChildren()).find((e=>e.is("element","code")));if(!n||!o.consumable.consume(n,{name:!0}))return;const i=o.writer.createElement("codeblock");o.writer.setAttribute("opCodeblockLanguage",n.getAttribute("class"),i);const r=o.splitToAllowedParent(i,t.modelCursor);if(r){o.writer.insert(i,r.position);const e=n.getChild(0);o.consumable.consume(e,{name:!0});const s=e.data.replace(/\n$/,"");o.writer.setAttribute("opCodeblockContent",s,i),t.modelRange=new Zl(o.writer.createPositionBefore(i),o.writer.createPositionAfter(i)),t.modelCursor=t.modelRange.end}}}()),o.for("editingDowncast").elementToElement({model:"codeblock",view:(e,{writer:t})=>DE(e,t,"Code block")}).add(function(){return t=>{t.on("attribute:opCodeblockContent",e),t.on("attribute:opCodeblockLanguage",e)};function e(e,t,o){const n=t.item;o.consumable.consume(t.item,e.name);const i=o.mapper.toViewElement(n);o.writer.remove(o.writer.createRangeOn(i.getChild(1))),o.writer.remove(o.writer.createRangeOn(i.getChild(0))),BE(o.writer,n,i)}}()),o.for("dataDowncast").add(function(){return t=>{t.on("insert:codeblock",e,{priority:"high"})};function e(e,t,o){const n=t.item,i=n.getAttribute("opCodeblockLanguage")||"language-text",r=n.getAttribute("opCodeblockContent");o.consumable.consume(n,"insert");const s=o.writer,a=s.createContainerElement("pre"),l=s.createContainerElement("div",{class:"op-uc-code-block--language"}),c=s.createContainerElement("code",{class:i}),d=s.createText(i),u=s.createText(r);s.insert(s.createPositionAt(c,0),u),s.insert(s.createPositionAt(l,0),d),s.insert(s.createPositionAt(a,0),l),s.insert(s.createPositionAt(a,0),c),o.mapper.bindElements(n,c),o.mapper.bindElements(n,a),o.mapper.bindElements(n,l);const h=o.mapper.toViewPosition(t.range.start);s.insert(h,a),e.stop()}}()),this.editor.editing.mapper.on("viewToModelPosition",(s=this.editor.model,a=e=>e.hasClass("op-uc-code-block"),(e,t)=>{const{mapper:o,viewPosition:n}=t,i=o.findMappedViewAncestor(n);if(!a(i))return;const r=o.toModelElement(i);t.modelPosition=s.createPositionAt(r,n.isAtStart?"before":"after")})),n.addObserver(TE),this.listenTo(i,"dblclick",((t,o)=>{let n=o.target,i=o.domEvent;if(i.shiftKey||i.altKey||i.metaKey)return;if(!xE(n)&&(n=n.findAncestor(xE),!n))return;o.preventDefault(),o.stopPropagation();const s=e.editing.mapper.toModelElement(n),a=r.services.macros,l=s.getAttribute("opCodeblockLanguage"),c=s.getAttribute("opCodeblockContent");a.editCodeBlock(c,l).then((t=>e.model.change((e=>{e.setAttribute("opCodeblockLanguage",t.languageClass,s),e.setAttribute("opCodeblockContent",t.content,s)}))))})),e.ui.componentFactory.add("insertCodeBlock",(t=>{const o=new Em(t);return o.set({label:window.I18n.t("js.editor.macro.code_block.button"),icon:'\n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n image/svg+xml\n \n \n \n \n\n',tooltip:!0}),o.on("execute",(()=>{r.services.macros.editCodeBlock().then((t=>e.model.change((o=>{const n=o.createElement("codeblock");o.setAttribute("opCodeblockLanguage",t.languageClass,n),o.setAttribute("opCodeblockContent",t.content,n),e.model.insertContent(n,e.model.document.selection)}))))})),o}))}}class PE extends lr{static get requires(){return[Fb]}static get pluginName(){return"CodeBlockToolbar"}init(){const e=this.editor,t=this.editor.model,o=Gk(e);a_(e,"opEditCodeBlock",(e=>{const n=o.services.macros,i=e.getAttribute("opCodeblockLanguage"),r=e.getAttribute("opCodeblockContent");n.editCodeBlock(r,i).then((o=>t.change((t=>{t.setAttribute("opCodeblockLanguage",o.languageClass,e),t.setAttribute("opCodeblockContent",o.content,e)}))))}))}afterInit(){c_(this,this.editor,"OPCodeBlock",EE)}}function FE(e){return e.__currentlyDisabled=e.__currentlyDisabled||[],e.ui.view.toolbar?e.ui.view.toolbar.items._items:[]}function ME(e,t){jQuery.each(FE(e),(function(o,n){let i=n;n instanceof kp?i=n.buttonView:n!==t&&n.hasOwnProperty("isEnabled")||(i=null),i&&(i.isEnabled?i.isEnabled=!1:e.__currentlyDisabled.push(i))}))}function RE(e){jQuery.each(FE(e),(function(t,o){let n=o;o instanceof kp&&(n=o.buttonView),e.__currentlyDisabled.indexOf(n)<0&&(n.isEnabled=!0)})),e.__currentlyDisabled=[]}function zE(e,t){const{modelAttribute:o,styleName:n,viewElement:i,defaultValue:r,reduceBoxSides:s=!1,shouldUpcast:a=(()=>!0)}=t;e.for("upcast").attributeToAttribute({view:{name:i,styles:{[n]:/[\s\S]+/}},model:{key:o,value:e=>{if(!a(e))return;const t=e.getNormalizedStyle(n),o=s?LE(t):t;return r!==o?o:void 0}}})}function VE(e,t,o,n){e.for("upcast").add((e=>e.on("element:"+t,((e,t,i)=>{if(!t.modelRange)return;const r=["border-top-width","border-top-color","border-top-style","border-bottom-width","border-bottom-color","border-bottom-style","border-right-width","border-right-color","border-right-style","border-left-width","border-left-color","border-left-style"].filter((e=>t.viewItem.hasStyle(e)));if(!r.length)return;const s={styles:r};if(!i.consumable.test(t.viewItem,s))return;const a=[...t.modelRange.getItems({shallow:!0})].pop();i.consumable.consume(t.viewItem,s);const l={style:t.viewItem.getNormalizedStyle("border-style"),color:t.viewItem.getNormalizedStyle("border-color"),width:t.viewItem.getNormalizedStyle("border-width")},c={style:LE(l.style),color:LE(l.color),width:LE(l.width)};c.style!==n.style&&i.writer.setAttribute(o.style,c.style,a),c.color!==n.color&&i.writer.setAttribute(o.color,c.color,a),c.width!==n.width&&i.writer.setAttribute(o.width,c.width,a)}))))}function OE(e,t){const{modelElement:o,modelAttribute:n,styleName:i}=t;e.for("downcast").attributeToAttribute({model:{name:o,key:n},view:e=>({key:"style",value:{[i]:e}})})}function NE(e,t){const{modelAttribute:o,styleName:n}=t;e.for("downcast").add((e=>e.on(`attribute:${o}:table`,((e,t,o)=>{const{item:i,attributeNewValue:r}=t,{mapper:s,writer:a}=o;if(!o.consumable.consume(t.item,e.name))return;const l=[...s.toViewElement(i).getChildren()].find((e=>e.is("element","table")));r?a.setStyle(n,r,l):a.removeStyle(n,l)}))))}function LE(e){if(!e)return;const t=["top","right","bottom","left"];if(!t.every((t=>e[t])))return e;const o=e.top;return t.every((t=>e[t]===o))?o:e}function HE(e,t,o,n,i=1){null!=t&&null!=i&&t>i?n.setAttribute(e,t,o):n.removeAttribute(e,o)}function jE(e,t,o={}){const n=e.createElement("tableCell",o);return e.insertElement("paragraph",n),e.insert(n,t),n}function qE(e,t){const o=t.parent.parent,n=parseInt(o.getAttribute("headingColumns")||"0"),{column:i}=e.getCellLocation(t);return!!n&&i{e.on("element:table",((e,t,o)=>{const n=t.viewItem;if(!o.consumable.test(n,{name:!0}))return;const{rows:i,headingRows:r,headingColumns:s}=function(e){let t,o=0;const n=[],i=[];let r;for(const s of Array.from(e.getChildren())){if("tbody"!==s.name&&"thead"!==s.name&&"tfoot"!==s.name)continue;"thead"!==s.name||r||(r=s);const e=Array.from(s.getChildren()).filter((e=>e.is("element","tr")));for(const a of e)if(r&&s===r||"tbody"===s.name&&Array.from(a.getChildren()).length&&Array.from(a.getChildren()).every((e=>e.is("element","th"))))o++,n.push(a);else{i.push(a);const e=KE(a);(!t||eo.convertItem(e,o.writer.createPositionAt(l,"end")))),o.convertChildren(n,o.writer.createPositionAt(l,"end")),l.isEmpty){const e=o.writer.createElement("tableRow");o.writer.insert(e,o.writer.createPositionAt(l,"end")),jE(o.writer,o.writer.createPositionAt(e,"end"))}o.updateConversionResult(l,t)}}))}}function GE(e){return t=>{t.on(`element:${e}`,((e,t,{writer:o})=>{if(!t.modelRange)return;const n=t.modelRange.start.nodeAfter,i=o.createPositionAt(n,0);if(t.viewItem.isEmpty)return void o.insertElement("paragraph",i);const r=Array.from(n.getChildren());if(r.every((e=>e.is("element","$marker")))){const e=o.createElement("paragraph");o.insert(e,o.createPositionAt(n,0));for(const t of r)o.move(o.createRangeOn(t),o.createPositionAt(e,"end"))}}),{priority:"low"})}}function KE(e){let t=0,o=0;const n=Array.from(e.getChildren()).filter((e=>"th"===e.name||"td"===e.name));for(;o1||i>1)&&this._recordSpans(o,i,n),this._shouldSkipSlot()||(t=this._formatOutValue(o)),this._nextCellAtColumn=this._column+n}return this._column++,this._column==this._nextCellAtColumn&&this._cellIndex++,t||this.next()}skipRow(e){this._skipRows.add(e)}_advanceToNextRow(){return this._row++,this._rowIndex++,this._column=0,this._cellIndex=0,this._nextCellAtColumn=-1,this.next()}_isOverEndRow(){return void 0!==this._endRow&&this._row>this._endRow}_isOverEndColumn(){return void 0!==this._endColumn&&this._column>this._endColumn}_formatOutValue(e,t=this._row,o=this._column){return{done:!1,value:new JE(this,e,t,o)}}_shouldSkipSlot(){const e=this._skipRows.has(this._row),t=this._rowthis._endColumn;return e||t||o||n}_getSpanned(){const e=this._spannedCells.get(this._row);return e&&e.get(this._column)||null}_recordSpans(e,t,o){const n={cell:e,row:this._row,column:this._column};for(let e=this._row;e0&&!this._jumpedToStartRow}_jumpToNonSpannedRowClosestToStartRow(){const e=this._getRowLength(0);for(let t=this._startRow;!this._jumpedToStartRow;t--)e===this._getRowLength(t)&&(this._row=t,this._rowIndex=t,this._jumpedToStartRow=!0)}_getRowLength(e){return[...this._table.getChild(e).getChildren()].reduce(((e,t)=>e+parseInt(t.getAttribute("colspan")||"1")),0)}}class JE{constructor(e,t,o,n){this.cell=t,this.row=e._row,this.column=e._column,this.cellAnchorRow=o,this.cellAnchorColumn=n,this._cellIndex=e._cellIndex,this._rowIndex=e._rowIndex,this._table=e._table}get isAnchor(){return this.row===this.cellAnchorRow&&this.column===this.cellAnchorColumn}get cellWidth(){return parseInt(this.cell.getAttribute("colspan")||"1")}get cellHeight(){return parseInt(this.cell.getAttribute("rowspan")||"1")}get rowIndex(){return this._rowIndex}getPositionBefore(){return this._table.root.document.model.createPositionAt(this._table.getChild(this.row),this._cellIndex)}}function YE(e,t){return(o,{writer:n})=>{const i=o.getAttribute("headingRows")||0,r=n.createContainerElement("table",null,[]),s=n.createContainerElement("figure",{class:"table"},r);i>0&&n.insert(n.createPositionAt(r,"end"),n.createContainerElement("thead",null,n.createSlot((e=>e.is("element","tableRow")&&e.indexe.is("element","tableRow")&&e.index>=i))));for(const{positionOffset:e,filter:o}of t.additionalSlots)n.insert(n.createPositionAt(r,e),n.createSlot(o));return n.insert(n.createPositionAt(r,"after"),n.createSlot((e=>!e.is("element","tableRow")&&!t.additionalSlots.some((({filter:t})=>t(e)))))),t.asWidget?function(e,t){return t.setCustomProperty("table",!0,e),zk(e,t,{hasSelectionHandle:!0})}(s,n):s}}function QE(e={}){return(t,{writer:o})=>{const n=t.parent,i=n.parent,r=i.getChildIndex(n),s=new ZE(i,{row:r}),a=i.getAttribute("headingRows")||0,l=i.getAttribute("headingColumns")||0;let c=null;for(const n of s)if(n.cell==t){const t=n.row{if(!t.parent.is("element","tableCell"))return null;if(!eD(t))return null;if(e.asWidget)return o.createContainerElement("span",{class:"ck-table-bogus-paragraph"});{const e=o.createContainerElement("p");return o.setCustomProperty("dataPipeline:transparentRendering",!0,e),e}}}function eD(e){return 1==e.parent.childCount&&!!e.getAttributeKeys().next().done}class tD extends dr{refresh(){const e=this.editor.model,t=e.document.selection,o=e.schema;this.isEnabled=function(e,t){const o=e.getFirstPosition().parent,n=o===o.root?o:o.parent;return t.checkChild(n,"table")}(t,o)}execute(e={}){const t=this.editor,o=t.model,n=t.plugins.get("TableUtils"),i=t.config.get("table.defaultHeadings.rows"),r=t.config.get("table.defaultHeadings.columns");void 0===e.headingRows&&i&&(e.headingRows=i),void 0===e.headingColumns&&r&&(e.headingColumns=r),o.change((t=>{const i=n.createTable(t,e);o.insertObject(i,null,null,{findOptimalPosition:"auto"}),t.setSelection(t.createPositionAt(i.getNodeByPath([0,0,0]),0))}))}}class oD extends dr{constructor(e,t={}){super(e),this.order=t.order||"below"}refresh(){const e=this.editor.model.document.selection,t=!!this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(e).length;this.isEnabled=t}execute(){const e=this.editor,t=e.model.document.selection,o=e.plugins.get("TableUtils"),n="above"===this.order,i=o.getSelectionAffectedTableCells(t),r=o.getRowIndexes(i),s=n?r.first:r.last,a=i[0].findAncestor("table");o.insertRows(a,{at:n?s:s+1,copyStructureFromAbove:!n})}}class nD extends dr{constructor(e,t={}){super(e),this.order=t.order||"right"}refresh(){const e=this.editor.model.document.selection,t=!!this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(e).length;this.isEnabled=t}execute(){const e=this.editor,t=e.model.document.selection,o=e.plugins.get("TableUtils"),n="left"===this.order,i=o.getSelectionAffectedTableCells(t),r=o.getColumnIndexes(i),s=n?r.first:r.last,a=i[0].findAncestor("table");o.insertColumns(a,{columns:1,at:n?s:s+1})}}class iD extends dr{constructor(e,t={}){super(e),this.direction=t.direction||"horizontally"}refresh(){const e=this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(this.editor.model.document.selection);this.isEnabled=1===e.length}execute(){const e=this.editor.plugins.get("TableUtils"),t=e.getSelectionAffectedTableCells(this.editor.model.document.selection)[0];"horizontally"===this.direction?e.splitCellHorizontally(t,2):e.splitCellVertically(t,2)}}function rD(e,t,o){const{startRow:n,startColumn:i,endRow:r,endColumn:s}=t,a=o.createElement("table"),l=r-n+1;for(let e=0;e0){HE("headingRows",r-o,e,i,0)}const s=parseInt(t.getAttribute("headingColumns")||"0");if(s>0){HE("headingColumns",s-n,e,i,0)}}(a,e,n,i,o),a}function sD(e,t,o=0){const n=[],i=new ZE(e,{startRow:o,endRow:t-1});for(const e of i){const{row:o,cellHeight:i}=e;o1&&(a.rowspan=l);const c=parseInt(e.getAttribute("colspan")||"1");c>1&&(a.colspan=c);const d=r+s,u=[...new ZE(i,{startRow:r,endRow:d,includeAllSlots:!0})];let h,m=null;for(const t of u){const{row:n,column:i,cell:r}=t;r===e&&void 0===h&&(h=i),void 0!==h&&h===i&&n===d&&(m=jE(o,t.getPositionBefore(),a))}return HE("rowspan",s,e,o),m}function lD(e,t){const o=[],n=new ZE(e);for(const e of n){const{column:n,cellWidth:i}=e;n1&&(r.colspan=s);const a=parseInt(e.getAttribute("rowspan")||"1");a>1&&(r.rowspan=a);const l=jE(n,n.createPositionAfter(e),r);return HE("colspan",i,e,n),l}function dD(e,t,o,n,i,r){const s=parseInt(e.getAttribute("colspan")||"1"),a=parseInt(e.getAttribute("rowspan")||"1");if(o+s-1>i){HE("colspan",i-o+1,e,r,1)}if(t+a-1>n){HE("rowspan",n-t+1,e,r,1)}}function uD(e,t){const o=t.getColumns(e),n=new Array(o).fill(0);for(const{column:t}of new ZE(e))n[t]++;const i=n.reduce(((e,t,o)=>t?e:[...e,o]),[]);if(i.length>0){const o=i[i.length-1];return t.removeColumns(e,{at:o}),!0}return!1}function hD(e,t){const o=[],n=t.getRows(e);for(let t=0;t0){const n=o[o.length-1];return t.removeRows(e,{at:n}),!0}return!1}function mD(e,t){uD(e,t)||hD(e,t)}function pD(e,t){const o=Array.from(new ZE(e,{startColumn:t.firstColumn,endColumn:t.lastColumn,row:t.lastRow}));if(o.every((({cellHeight:e})=>1===e)))return t.lastRow;const n=o[0].cellHeight-1;return t.lastRow+n}function gD(e,t){const o=Array.from(new ZE(e,{startRow:t.firstRow,endRow:t.lastRow,column:t.lastColumn}));if(o.every((({cellWidth:e})=>1===e)))return t.lastColumn;const n=o[0].cellWidth-1;return t.lastColumn+n}class fD extends dr{constructor(e,t){super(e),this.direction=t.direction,this.isHorizontal="right"==this.direction||"left"==this.direction}refresh(){const e=this._getMergeableCell();this.value=e,this.isEnabled=!!e}execute(){const e=this.editor.model,t=e.document,o=this.editor.plugins.get("TableUtils").getTableCellsContainingSelection(t.selection)[0],n=this.value,i=this.direction;e.change((e=>{const t="right"==i||"down"==i,r=t?o:n,s=t?n:o,a=s.parent;!function(e,t,o){bD(e)||(bD(t)&&o.remove(o.createRangeIn(t)),o.move(o.createRangeIn(e),o.createPositionAt(t,"end")));o.remove(e)}(s,r,e);const l=this.isHorizontal?"colspan":"rowspan",c=parseInt(o.getAttribute(l)||"1"),d=parseInt(n.getAttribute(l)||"1");e.setAttribute(l,c+d,r),e.setSelection(e.createRangeIn(r));const u=this.editor.plugins.get("TableUtils");mD(a.findAncestor("table"),u)}))}_getMergeableCell(){const e=this.editor.model.document,t=this.editor.plugins.get("TableUtils"),o=t.getTableCellsContainingSelection(e.selection)[0];if(!o)return;const n=this.isHorizontal?function(e,t,o){const n=e.parent,i=n.parent,r="right"==t?e.nextSibling:e.previousSibling,s=(i.getAttribute("headingColumns")||0)>0;if(!r)return;const a="right"==t?e:r,l="right"==t?r:e,{column:c}=o.getCellLocation(a),{column:d}=o.getCellLocation(l),u=parseInt(a.getAttribute("colspan")||"1"),h=qE(o,a),m=qE(o,l);if(s&&h!=m)return;return c+u===d?r:void 0}(o,this.direction,t):function(e,t,o){const n=e.parent,i=n.parent,r=i.getChildIndex(n);if("down"==t&&r===o.getRows(i)-1||"up"==t&&0===r)return null;const s=parseInt(e.getAttribute("rowspan")||"1"),a=i.getAttribute("headingRows")||0,l="down"==t&&r+s===a,c="up"==t&&r===a;if(a&&(l||c))return null;const d=parseInt(e.getAttribute("rowspan")||"1"),u="down"==t?r+d:r,h=[...new ZE(i,{endRow:u})],m=h.find((t=>t.cell===e)),p=m.column,g=h.find((({row:e,cellHeight:o,column:n})=>n===p&&("down"==t?e===u:u===e+o)));return g&&g.cell?g.cell:null}(o,this.direction,t);if(!n)return;const i=this.isHorizontal?"rowspan":"colspan",r=parseInt(o.getAttribute(i)||"1");return parseInt(n.getAttribute(i)||"1")===r?n:void 0}}function bD(e){const t=e.getChild(0);return 1==e.childCount&&t.is("element","paragraph")&&t.isEmpty}class kD extends dr{refresh(){const e=this.editor.plugins.get("TableUtils"),t=e.getSelectionAffectedTableCells(this.editor.model.document.selection),o=t[0];if(o){const n=o.findAncestor("table"),i=e.getRows(n)-1,r=e.getRowIndexes(t),s=0===r.first&&r.last===i;this.isEnabled=!s}else this.isEnabled=!1}execute(){const e=this.editor.model,t=this.editor.plugins.get("TableUtils"),o=t.getSelectionAffectedTableCells(e.document.selection),n=t.getRowIndexes(o),i=o[0],r=i.findAncestor("table"),s=t.getCellLocation(i).column;e.change((e=>{const o=n.last-n.first+1;t.removeRows(r,{at:n.first,rows:o});const i=function(e,t,o,n){const i=e.getChild(Math.min(t,n-1));let r=i.getChild(0),s=0;for(const e of i.getChildren()){if(s>o)return r;r=e,s+=parseInt(e.getAttribute("colspan")||"1")}return r}(r,n.first,s,t.getRows(r));e.setSelection(e.createPositionAt(i,0))}))}}class wD extends dr{refresh(){const e=this.editor.plugins.get("TableUtils"),t=e.getSelectionAffectedTableCells(this.editor.model.document.selection),o=t[0];if(o){const n=o.findAncestor("table"),i=e.getColumns(n),{first:r,last:s}=e.getColumnIndexes(t);this.isEnabled=s-re.cell===t)).column,last:i.find((e=>e.cell===o)).column},s=function(e,t,o,n){const i=parseInt(o.getAttribute("colspan")||"1");return i>1?o:t.previousSibling||o.nextSibling?o.nextSibling||t.previousSibling:n.first?e.reverse().find((({column:e})=>ee>n.last)).cell}(i,t,o,r);this.editor.model.change((t=>{const o=r.last-r.first+1;e.removeColumns(n,{at:r.first,columns:o}),t.setSelection(t.createPositionAt(s,0))}))}}class _D extends dr{refresh(){const e=this.editor.plugins.get("TableUtils"),t=this.editor.model,o=e.getSelectionAffectedTableCells(t.document.selection),n=o.length>0;this.isEnabled=n,this.value=n&&o.every((e=>this._isInHeading(e,e.parent.parent)))}execute(e={}){if(e.forceValue===this.value)return;const t=this.editor.plugins.get("TableUtils"),o=this.editor.model,n=t.getSelectionAffectedTableCells(o.document.selection),i=n[0].findAncestor("table"),{first:r,last:s}=t.getRowIndexes(n),a=this.value?r:s+1,l=i.getAttribute("headingRows")||0;o.change((e=>{if(a){const t=sD(i,a,a>l?l:0);for(const{cell:o}of t)aD(o,a,e)}HE("headingRows",a,i,e,0)}))}_isInHeading(e,t){const o=parseInt(t.getAttribute("headingRows")||"0");return!!o&&e.parent.index0;this.isEnabled=n,this.value=n&&o.every((e=>qE(t,e)))}execute(e={}){if(e.forceValue===this.value)return;const t=this.editor.plugins.get("TableUtils"),o=this.editor.model,n=t.getSelectionAffectedTableCells(o.document.selection),i=n[0].findAncestor("table"),{first:r,last:s}=t.getColumnIndexes(n),a=this.value?r:s+1;o.change((e=>{if(a){const t=lD(i,a);for(const{cell:o,column:n}of t)cD(o,n,a,e)}HE("headingColumns",a,i,e,0)}))}}function AD(e){if(e.is("element","tableColumnGroup"))return e;const t=e.getChildren();return Array.from(t).find((e=>e.is("element","tableColumnGroup")))}function CD(e){const t=AD(e);return t?Array.from(t.getChildren()):[]}class vD extends lr{static get pluginName(){return"TableUtils"}init(){this.decorate("insertColumns"),this.decorate("insertRows")}getCellLocation(e){const t=e.parent,o=t.parent,n=o.getChildIndex(t),i=new ZE(o,{row:n});for(const{cell:t,row:o,column:n}of i)if(t===e)return{row:o,column:n}}createTable(e,t){const o=e.createElement("table"),n=t.rows||2,i=t.columns||2;return xD(e,o,0,n,i),t.headingRows&&HE("headingRows",Math.min(t.headingRows,n),o,e,0),t.headingColumns&&HE("headingColumns",Math.min(t.headingColumns,i),o,e,0),o}insertRows(e,t={}){const o=this.editor.model,n=t.at||0,i=t.rows||1,r=void 0!==t.copyStructureFromAbove,s=t.copyStructureFromAbove?n-1:n,a=this.getRows(e),l=this.getColumns(e);if(n>a)throw new E("tableutils-insertrows-insert-out-of-range",this,{options:t});o.change((t=>{const o=e.getAttribute("headingRows")||0;if(o>n&&HE("headingRows",o+i,e,t,0),!r&&(0===n||n===a))return void xD(t,e,n,i,l);const c=r?Math.max(n,s):n,d=new ZE(e,{endRow:c}),u=new Array(l).fill(1);for(const{row:e,column:o,cellHeight:a,cellWidth:l,cell:c}of d){const d=e+a-1,h=e<=s&&s<=d;e0&&jE(t,i,n>1?{colspan:n}:void 0),e+=Math.abs(n)-1}}}))}insertColumns(e,t={}){const o=this.editor.model,n=t.at||0,i=t.columns||1;o.change((t=>{const o=e.getAttribute("headingColumns");ni-1)throw new E("tableutils-removerows-row-index-out-of-range",this,{table:e,options:t});o.change((t=>{const o={first:r,last:s},{cellsToMove:n,cellsToTrim:i}=function(e,{first:t,last:o}){const n=new Map,i=[];for(const{row:r,column:s,cellHeight:a,cell:l}of new ZE(e,{endRow:o})){const e=r+a-1;if(r>=t&&r<=o&&e>o){const e=a-(o-r+1);n.set(s,{cell:l,rowspan:e})}if(r=t){let n;n=e>=o?o-t+1:e-t+1,i.push({cell:l,rowspan:a-n})}}return{cellsToMove:n,cellsToTrim:i}}(e,o);if(n.size){!function(e,t,o,n){const i=new ZE(e,{includeAllSlots:!0,row:t}),r=[...i],s=e.getChild(t);let a;for(const{column:e,cell:t,isAnchor:i}of r)if(o.has(e)){const{cell:t,rowspan:i}=o.get(e),r=a?n.createPositionAfter(a):n.createPositionAt(s,0);n.move(n.createRangeOn(t),r),HE("rowspan",i,t,n),a=t}else i&&(a=t)}(e,s+1,n,t)}for(let o=s;o>=r;o--)t.remove(e.getChild(o));for(const{rowspan:e,cell:o}of i)HE("rowspan",e,o,t);!function(e,{first:t,last:o},n){const i=e.getAttribute("headingRows")||0;if(t{!function(e,t,o){const n=e.getAttribute("headingColumns")||0;if(n&&t.first=n;i--){for(const{cell:o,column:n,cellWidth:r}of[...new ZE(e)])n<=i&&r>1&&n+r>i?HE("colspan",r-1,o,t):n===i&&t.remove(o);if(o[i]){const e=0===i?o[1]:o[i-1],n=parseFloat(o[i].getAttribute("columnWidth")),r=parseFloat(e.getAttribute("columnWidth"));t.remove(o[i]),t.setAttribute("columnWidth",n+r+"%",e)}}hD(e,this)||uD(e,this)}))}splitCellVertically(e,t=2){const o=this.editor.model,n=e.parent.parent,i=parseInt(e.getAttribute("rowspan")||"1"),r=parseInt(e.getAttribute("colspan")||"1");o.change((o=>{if(r>1){const{newCellsSpan:n,updatedSpan:s}=DD(r,t);HE("colspan",s,e,o);const a={};n>1&&(a.colspan=n),i>1&&(a.rowspan=i);ED(r>t?t-1:r-1,o,o.createPositionAfter(e),a)}if(rt===e)),c=a.filter((({cell:t,cellWidth:o,column:n})=>t!==e&&n===l||nl));for(const{cell:e,cellWidth:t}of c)o.setAttribute("colspan",t+s,e);const d={};i>1&&(d.rowspan=i),ED(s,o,o.createPositionAfter(e),d);const u=n.getAttribute("headingColumns")||0;u>l&&HE("headingColumns",u+s,n,o)}}))}splitCellHorizontally(e,t=2){const o=this.editor.model,n=e.parent,i=n.parent,r=i.getChildIndex(n),s=parseInt(e.getAttribute("rowspan")||"1"),a=parseInt(e.getAttribute("colspan")||"1");o.change((o=>{if(s>1){const n=[...new ZE(i,{startRow:r,endRow:r+s-1,includeAllSlots:!0})],{newCellsSpan:l,updatedSpan:c}=DD(s,t);HE("rowspan",c,e,o);const{column:d}=n.find((({cell:t})=>t===e)),u={};l>1&&(u.rowspan=l),a>1&&(u.colspan=a);let h=0;for(const e of n){const{column:t,row:n}=e,i=t===d;h>=l&&i&&(h=0),n>=r+c&&i&&(h||ED(1,o,e.getPositionBefore(),u),h++)}}if(sr){const e=i+n;o.setAttribute("rowspan",e,t)}const c={};a>1&&(c.colspan=a),xD(o,i,r+1,n,1,c);const d=i.getAttribute("headingRows")||0;d>r&&HE("headingRows",d+n,i,o)}}))}getColumns(e){return[...e.getChild(0).getChildren()].filter((e=>e.is("element","tableCell"))).reduce(((e,t)=>e+parseInt(t.getAttribute("colspan")||"1")),0)}getRows(e){return Array.from(e.getChildren()).reduce(((e,t)=>t.is("element","tableRow")?e+1:e),0)}createTableWalker(e,t={}){return new ZE(e,t)}getSelectedTableCells(e){const t=[];for(const o of this.sortRanges(e.getRanges())){const e=o.getContainedElement();e&&e.is("element","tableCell")&&t.push(e)}return t}getTableCellsContainingSelection(e){const t=[];for(const o of e.getRanges()){const e=o.start.findAncestor("tableCell");e&&t.push(e)}return t}getSelectionAffectedTableCells(e){const t=this.getSelectedTableCells(e);return t.length?t:this.getTableCellsContainingSelection(e)}getRowIndexes(e){const t=e.map((e=>e.parent.index));return this._getFirstLastIndexesObject(t)}getColumnIndexes(e){const t=e[0].findAncestor("table"),o=[...new ZE(t)].filter((t=>e.includes(t.cell))).map((e=>e.column));return this._getFirstLastIndexesObject(o)}isSelectionRectangular(e){if(e.length<2||!this._areCellInTheSameTableSection(e))return!1;const t=new Set,o=new Set;let n=0;for(const i of e){const{row:e,column:r}=this.getCellLocation(i),s=parseInt(i.getAttribute("rowspan"))||1,a=parseInt(i.getAttribute("colspan"))||1;t.add(e),o.add(r),s>1&&t.add(e+s-1),a>1&&o.add(r+a-1),n+=s*a}const i=function(e,t){const o=Array.from(e.values()),n=Array.from(t.values()),i=Math.max(...o),r=Math.min(...o),s=Math.max(...n),a=Math.min(...n);return(i-r+1)*(s-a+1)}(t,o);return i==n}sortRanges(e){return Array.from(e).sort(BD)}_getFirstLastIndexesObject(e){const t=e.sort(((e,t)=>e-t));return{first:t[0],last:t[t.length-1]}}_areCellInTheSameTableSection(e){const t=e[0].findAncestor("table"),o=this.getRowIndexes(e),n=parseInt(t.getAttribute("headingRows"))||0;if(!this._areIndexesInSameSection(o,n))return!1;const i=this.getColumnIndexes(e),r=parseInt(t.getAttribute("headingColumns"))||0;return this._areIndexesInSameSection(i,r)}_areIndexesInSameSection({first:e,last:t},o){return e{const n=t.getSelectedTableCells(e.document.selection),i=n.shift(),{mergeWidth:r,mergeHeight:s}=function(e,t,o){let n=0,i=0;for(const e of t){const{row:t,column:r}=o.getCellLocation(e);n=PD(e,r,n,"colspan"),i=PD(e,t,i,"rowspan")}const{row:r,column:s}=o.getCellLocation(e),a=n-s,l=i-r;return{mergeWidth:a,mergeHeight:l}}(i,n,t);HE("colspan",r,i,o),HE("rowspan",s,i,o);for(const e of n)TD(e,i,o);mD(i.findAncestor("table"),t),o.setSelection(i,"in")}))}}function TD(e,t,o){ID(e)||(ID(t)&&o.remove(o.createRangeIn(t)),o.move(o.createRangeIn(e),o.createPositionAt(t,"end"))),o.remove(e)}function ID(e){const t=e.getChild(0);return 1==e.childCount&&t.is("element","paragraph")&&t.isEmpty}function PD(e,t,o,n){const i=parseInt(e.getAttribute(n)||"1");return Math.max(o,t+i)}class FD extends dr{constructor(e){super(e),this.affectsData=!1}refresh(){const e=this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(this.editor.model.document.selection);this.isEnabled=e.length>0}execute(){const e=this.editor.model,t=this.editor.plugins.get("TableUtils"),o=t.getSelectionAffectedTableCells(e.document.selection),n=t.getRowIndexes(o),i=o[0].findAncestor("table"),r=[];for(let t=n.first;t<=n.last;t++)for(const o of i.getChild(t).getChildren())r.push(e.createRangeOn(o));e.change((e=>{e.setSelection(r)}))}}class MD extends dr{constructor(e){super(e),this.affectsData=!1}refresh(){const e=this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(this.editor.model.document.selection);this.isEnabled=e.length>0}execute(){const e=this.editor.plugins.get("TableUtils"),t=this.editor.model,o=e.getSelectionAffectedTableCells(t.document.selection),n=o[0],i=o.pop(),r=n.findAncestor("table"),s=e.getCellLocation(n),a=e.getCellLocation(i),l=Math.min(s.column,a.column),c=Math.max(s.column,a.column),d=[];for(const e of new ZE(r,{startColumn:l,endColumn:c}))d.push(t.createRangeOn(e.cell));t.change((e=>{e.setSelection(d)}))}}function RD(e){e.document.registerPostFixer((t=>function(e,t){const o=t.document.differ.getChanges();let n=!1;const i=new Set;for(const t of o){let o=null;"insert"==t.type&&"table"==t.name&&(o=t.position.nodeAfter),"insert"!=t.type&&"remove"!=t.type||"tableRow"!=t.name&&"tableCell"!=t.name||(o=t.position.findAncestor("table")),OD(t)&&(o=t.range.start.findAncestor("table")),o&&!i.has(o)&&(n=zD(o,e)||n,n=VD(o,e)||n,i.add(o))}return n}(t,e)))}function zD(e,t){let o=!1;const n=function(e){const t=parseInt(e.getAttribute("headingRows")||"0"),o=Array.from(e.getChildren()).reduce(((e,t)=>t.is("element","tableRow")?e+1:e),0),n=[];for(const{row:i,cell:r,cellHeight:s}of new ZE(e)){if(s<2)continue;const e=ie){const t=e-i;n.push({cell:r,rowspan:t})}}return n}(e);if(n.length){o=!0;for(const e of n)HE("rowspan",e.rowspan,e.cell,t,1)}return o}function VD(e,t){let o=!1;const n=function(e){const t=new Array(e.childCount).fill(0);for(const{rowIndex:o}of new ZE(e,{includeAllSlots:!0}))t[o]++;return t}(e),i=[];for(const[t,o]of n.entries())!o&&e.getChild(t).is("element","tableRow")&&i.push(t);if(i.length){o=!0;for(const o of i.reverse())t.remove(e.getChild(o)),n.splice(o,1)}const r=n.filter(((t,o)=>e.getChild(o).is("element","tableRow"))),s=r[0];if(!r.every((e=>e===s))){const n=r.reduce(((e,t)=>t>e?t:e),0);for(const[i,s]of r.entries()){const r=n-s;if(r){for(let o=0;ofunction(e,t){const o=t.document.differ.getChanges();let n=!1;for(const t of o)"insert"==t.type&&"table"==t.name&&(n=LD(t.position.nodeAfter,e)||n),"insert"==t.type&&"tableRow"==t.name&&(n=HD(t.position.nodeAfter,e)||n),"insert"==t.type&&"tableCell"==t.name&&(n=jD(t.position.nodeAfter,e)||n),"remove"!=t.type&&"insert"!=t.type||!qD(t)||(n=jD(t.position.parent,e)||n);return n}(t,e)))}function LD(e,t){let o=!1;for(const n of e.getChildren())n.is("element","tableRow")&&(o=HD(n,t)||o);return o}function HD(e,t){let o=!1;for(const n of e.getChildren())o=jD(n,t)||o;return o}function jD(e,t){if(0==e.childCount)return t.insertElement("paragraph",e),!0;const o=Array.from(e.getChildren()).filter((e=>e.is("$text")));for(const e of o)t.wrap(t.createRangeOn(e),"paragraph");return!!o.length}function qD(e){return!!e.position.parent.is("element","tableCell")&&("insert"==e.type&&"$text"==e.name||"remove"==e.type)}function UD(e,t){if(!e.is("element","paragraph"))return!1;const o=t.toViewElement(e);return!!o&&eD(e)!==o.is("element","span")}var WD=i(8864),$D={attributes:{"data-cke":!0}};$D.setAttributes=Ar(),$D.insert=_r().bind(null,"head"),$D.domAPI=kr(),$D.insertStyleElement=vr();fr()(WD.A,$D);WD.A&&WD.A.locals&&WD.A.locals;class GD extends lr{static get pluginName(){return"TableEditing"}static get requires(){return[vD]}constructor(e){super(e),this._additionalSlots=[]}init(){const e=this.editor,t=e.model,o=t.schema,n=e.conversion,i=e.plugins.get(vD);o.register("table",{inheritAllFrom:"$blockObject",allowAttributes:["headingRows","headingColumns"]}),o.register("tableRow",{allowIn:"table",isLimit:!0}),o.register("tableCell",{allowContentOf:"$container",allowIn:"tableRow",allowAttributes:["colspan","rowspan"],isLimit:!0,isSelectable:!0}),n.for("upcast").add((e=>{e.on("element:figure",((e,t,o)=>{if(!o.consumable.test(t.viewItem,{name:!0,classes:"table"}))return;const n=function(e){for(const t of e.getChildren())if(t.is("element","table"))return t}(t.viewItem);if(!n||!o.consumable.test(n,{name:!0}))return;o.consumable.consume(t.viewItem,{name:!0,classes:"table"});const i=Qi(o.convertItem(n,t.modelCursor).modelRange.getItems());i?(o.convertChildren(t.viewItem,o.writer.createPositionAt(i,"end")),o.updateConversionResult(i,t)):o.consumable.revert(t.viewItem,{name:!0,classes:"table"})}))})),n.for("upcast").add($E()),n.for("editingDowncast").elementToStructure({model:{name:"table",attributes:["headingRows"]},view:YE(i,{asWidget:!0,additionalSlots:this._additionalSlots})}),n.for("dataDowncast").elementToStructure({model:{name:"table",attributes:["headingRows"]},view:YE(i,{additionalSlots:this._additionalSlots})}),n.for("upcast").elementToElement({model:"tableRow",view:"tr"}),n.for("upcast").add((e=>{e.on("element:tr",((e,t)=>{t.viewItem.isEmpty&&0==t.modelCursor.index&&e.stop()}),{priority:"high"})})),n.for("downcast").elementToElement({model:"tableRow",view:(e,{writer:t})=>e.isEmpty?t.createEmptyElement("tr"):t.createContainerElement("tr")}),n.for("upcast").elementToElement({model:"tableCell",view:"td"}),n.for("upcast").elementToElement({model:"tableCell",view:"th"}),n.for("upcast").add(GE("td")),n.for("upcast").add(GE("th")),n.for("editingDowncast").elementToElement({model:"tableCell",view:QE({asWidget:!0})}),n.for("dataDowncast").elementToElement({model:"tableCell",view:QE()}),n.for("editingDowncast").elementToElement({model:"paragraph",view:XE({asWidget:!0}),converterPriority:"high"}),n.for("dataDowncast").elementToElement({model:"paragraph",view:XE(),converterPriority:"high"}),n.for("downcast").attributeToAttribute({model:"colspan",view:"colspan"}),n.for("upcast").attributeToAttribute({model:{key:"colspan",value:KD("colspan")},view:"colspan"}),n.for("downcast").attributeToAttribute({model:"rowspan",view:"rowspan"}),n.for("upcast").attributeToAttribute({model:{key:"rowspan",value:KD("rowspan")},view:"rowspan"}),e.config.define("table.defaultHeadings.rows",0),e.config.define("table.defaultHeadings.columns",0),e.commands.add("insertTable",new tD(e)),e.commands.add("insertTableRowAbove",new oD(e,{order:"above"})),e.commands.add("insertTableRowBelow",new oD(e,{order:"below"})),e.commands.add("insertTableColumnLeft",new nD(e,{order:"left"})),e.commands.add("insertTableColumnRight",new nD(e,{order:"right"})),e.commands.add("removeTableRow",new kD(e)),e.commands.add("removeTableColumn",new wD(e)),e.commands.add("splitTableCellVertically",new iD(e,{direction:"vertically"})),e.commands.add("splitTableCellHorizontally",new iD(e,{direction:"horizontally"})),e.commands.add("mergeTableCells",new SD(e)),e.commands.add("mergeTableCellRight",new fD(e,{direction:"right"})),e.commands.add("mergeTableCellLeft",new fD(e,{direction:"left"})),e.commands.add("mergeTableCellDown",new fD(e,{direction:"down"})),e.commands.add("mergeTableCellUp",new fD(e,{direction:"up"})),e.commands.add("setTableColumnHeader",new yD(e)),e.commands.add("setTableRowHeader",new _D(e)),e.commands.add("selectTableRow",new FD(e)),e.commands.add("selectTableColumn",new MD(e)),RD(t),ND(t),this.listenTo(t.document,"change:data",(()=>{!function(e,t){const o=e.document.differ;for(const e of o.getChanges()){let o,n=!1;if("attribute"==e.type){const t=e.range.start.nodeAfter;if(!t||!t.is("element","table"))continue;if("headingRows"!=e.attributeKey&&"headingColumns"!=e.attributeKey)continue;o=t,n="headingRows"==e.attributeKey}else"tableRow"!=e.name&&"tableCell"!=e.name||(o=e.position.findAncestor("table"),n="tableRow"==e.name);if(!o)continue;const i=o.getAttribute("headingRows")||0,r=o.getAttribute("headingColumns")||0,s=new ZE(o);for(const e of s){const o=e.rowUD(e,t.mapper)));for(const e of o)t.reconvertItem(e)}}(t,e.editing)}))}registerAdditionalSlot(e){this._additionalSlots.push(e)}}function KD(e){return t=>{const o=parseInt(t.getAttribute(e));return Number.isNaN(o)||o<=0?null:o}}var ZD=i(8603),JD={attributes:{"data-cke":!0}};JD.setAttributes=Ar(),JD.insert=_r().bind(null,"head"),JD.domAPI=kr(),JD.insertStyleElement=vr();fr()(ZD.A,JD);ZD.A&&ZD.A.locals&&ZD.A.locals;class YD extends pm{constructor(e){super(e);const t=this.bindTemplate;this.items=this._createGridCollection(),this.keystrokes=new er,this.focusTracker=new Xi,this.set("rows",0),this.set("columns",0),this.bind("label").to(this,"columns",this,"rows",((e,t)=>`${t} × ${e}`)),this.setTemplate({tag:"div",attributes:{class:["ck"]},children:[{tag:"div",attributes:{class:["ck-insert-table-dropdown__grid"]},on:{"mouseover@.ck-insert-table-dropdown-grid-box":t.to("boxover")},children:this.items},{tag:"div",attributes:{class:["ck","ck-insert-table-dropdown__label"],"aria-hidden":!0},children:[{text:t.to("label")}]}],on:{mousedown:t.to((e=>{e.preventDefault()})),click:t.to((()=>{this.fire("execute")}))}}),this.on("boxover",((e,t)=>{const{row:o,column:n}=t.target.dataset;this.items.get(10*(parseInt(o,10)-1)+(parseInt(n,10)-1)).focus()})),this.focusTracker.on("change:focusedElement",((e,t,o)=>{if(!o)return;const{row:n,column:i}=o.dataset;this.set({rows:parseInt(n),columns:parseInt(i)})})),this.on("change:columns",(()=>this._highlightGridBoxes())),this.on("change:rows",(()=>this._highlightGridBoxes()))}render(){super.render(),km({keystrokeHandler:this.keystrokes,focusTracker:this.focusTracker,gridItems:this.items,numberOfColumns:10,uiLanguageDirection:this.locale&&this.locale.uiLanguageDirection});for(const e of this.items)this.focusTracker.add(e.element);this.keystrokes.listenTo(this.element)}reset(){this.set({rows:1,columns:1})}focus(){this.items.get(0).focus()}focusLast(){this.items.get(0).focus()}_highlightGridBoxes(){const e=this.rows,t=this.columns;this.items.map(((o,n)=>{const i=Math.floor(n/10){const n=e.commands.get("insertTable"),i=Eg(o);let r;return i.bind("isEnabled").to(n),i.buttonView.set({icon:qh.table,label:t("Insert table"),tooltip:!0}),i.on("change:isOpen",(()=>{r||(r=new YD(o),i.panelView.children.add(r),r.delegate("execute").to(i),i.on("execute",(()=>{e.execute("insertTable",{rows:r.rows,columns:r.columns}),e.editing.view.focus()})))})),i})),e.ui.componentFactory.add("menuBar:insertTable",(o=>{const n=e.commands.get("insertTable"),i=new mk(o),r=new YD(o);return r.delegate("execute").to(i),i.on("change:isOpen",((e,t,o)=>{o||r.reset()})),r.on("execute",(()=>{e.execute("insertTable",{rows:r.rows,columns:r.columns}),e.editing.view.focus()})),i.buttonView.set({label:t("Table"),icon:qh.table}),i.panelView.children.add(r),i.bind("isEnabled").to(n),i})),e.ui.componentFactory.add("tableColumn",(e=>{const n=[{type:"switchbutton",model:{commandName:"setTableColumnHeader",label:t("Header column"),bindIsOn:!0}},{type:"separator"},{type:"button",model:{commandName:o?"insertTableColumnLeft":"insertTableColumnRight",label:t("Insert column left")}},{type:"button",model:{commandName:o?"insertTableColumnRight":"insertTableColumnLeft",label:t("Insert column right")}},{type:"button",model:{commandName:"removeTableColumn",label:t("Delete column")}},{type:"button",model:{commandName:"selectTableColumn",label:t("Select column")}}];return this._prepareDropdown(t("Column"),'',n,e)})),e.ui.componentFactory.add("tableRow",(e=>{const o=[{type:"switchbutton",model:{commandName:"setTableRowHeader",label:t("Header row"),bindIsOn:!0}},{type:"separator"},{type:"button",model:{commandName:"insertTableRowAbove",label:t("Insert row above")}},{type:"button",model:{commandName:"insertTableRowBelow",label:t("Insert row below")}},{type:"button",model:{commandName:"removeTableRow",label:t("Delete row")}},{type:"button",model:{commandName:"selectTableRow",label:t("Select row")}}];return this._prepareDropdown(t("Row"),'',o,e)})),e.ui.componentFactory.add("mergeTableCells",(e=>{const n=[{type:"button",model:{commandName:"mergeTableCellUp",label:t("Merge cell up")}},{type:"button",model:{commandName:o?"mergeTableCellRight":"mergeTableCellLeft",label:t("Merge cell right")}},{type:"button",model:{commandName:"mergeTableCellDown",label:t("Merge cell down")}},{type:"button",model:{commandName:o?"mergeTableCellLeft":"mergeTableCellRight",label:t("Merge cell left")}},{type:"separator"},{type:"button",model:{commandName:"splitTableCellVertically",label:t("Split cell vertically")}},{type:"button",model:{commandName:"splitTableCellHorizontally",label:t("Split cell horizontally")}}];return this._prepareMergeSplitButtonDropdown(t("Merge cells"),'',n,e)}))}_prepareDropdown(e,t,o,n){const i=this.editor,r=Eg(n),s=this._fillDropdownWithListOptions(r,o);return r.buttonView.set({label:e,icon:t,tooltip:!0}),r.bind("isEnabled").toMany(s,"isEnabled",((...e)=>e.some((e=>e)))),this.listenTo(r,"execute",(e=>{i.execute(e.source.commandName),e.source instanceof bp||i.editing.view.focus()})),r}_prepareMergeSplitButtonDropdown(e,t,o,n){const i=this.editor,r=Eg(n,yg),s="mergeTableCells",a=i.commands.get(s),l=this._fillDropdownWithListOptions(r,o);return r.buttonView.set({label:e,icon:t,tooltip:!0,isEnabled:!0}),r.bind("isEnabled").toMany([a,...l],"isEnabled",((...e)=>e.some((e=>e)))),this.listenTo(r.buttonView,"execute",(()=>{i.execute(s),i.editing.view.focus()})),this.listenTo(r,"execute",(e=>{i.execute(e.source.commandName),i.editing.view.focus()})),r}_fillDropdownWithListOptions(e,t){const o=this.editor,n=[],i=new Yi;for(const e of t)XD(e,o,n,i);return Sg(e,i),n}}function XD(e,t,o,n){if("button"===e.type||"switchbutton"===e.type){const n=e.model=new Db(e.model),{commandName:i,bindIsOn:r}=e.model,s=t.commands.get(i);o.push(s),n.set({commandName:i}),n.bind("isEnabled").to(s),r&&n.bind("isOn").to(s,"value"),n.set({withText:!0})}n.add(e)}var eB=i(2850),tB={attributes:{"data-cke":!0}};tB.setAttributes=Ar(),tB.insert=_r().bind(null,"head"),tB.domAPI=kr(),tB.insertStyleElement=vr();fr()(eB.A,tB);eB.A&&eB.A.locals&&eB.A.locals;class oB extends lr{static get pluginName(){return"TableSelection"}static get requires(){return[vD,vD]}init(){const e=this.editor,t=e.model,o=e.editing.view;this.listenTo(t,"deleteContent",((e,t)=>this._handleDeleteContent(e,t)),{priority:"high"}),this.listenTo(o.document,"insertText",((e,t)=>this._handleInsertTextEvent(e,t)),{priority:"high"}),this._defineSelectionConverter(),this._enablePluginDisabling()}getSelectedTableCells(){const e=this.editor.plugins.get(vD),t=this.editor.model.document.selection,o=e.getSelectedTableCells(t);return 0==o.length?null:o}getSelectionAsFragment(){const e=this.editor.plugins.get(vD),t=this.getSelectedTableCells();return t?this.editor.model.change((o=>{const n=o.createDocumentFragment(),{first:i,last:r}=e.getColumnIndexes(t),{first:s,last:a}=e.getRowIndexes(t),l=t[0].findAncestor("table");let c=a,d=r;if(e.isSelectionRectangular(t)){const e={firstColumn:i,lastColumn:r,firstRow:s,lastRow:a};c=pD(l,e),d=gD(l,e)}const u=rD(l,{startRow:s,startColumn:i,endRow:c,endColumn:d},o);return o.insert(u,n,0),n})):null}setCellSelection(e,t){const o=this._getCellsToSelect(e,t);this.editor.model.change((e=>{e.setSelection(o.cells.map((t=>e.createRangeOn(t))),{backward:o.backward})}))}getFocusCell(){const e=[...this.editor.model.document.selection.getRanges()].pop().getContainedElement();return e&&e.is("element","tableCell")?e:null}getAnchorCell(){const e=Qi(this.editor.model.document.selection.getRanges()).getContainedElement();return e&&e.is("element","tableCell")?e:null}_defineSelectionConverter(){const e=this.editor,t=new Set;e.conversion.for("editingDowncast").add((e=>e.on("selection",((e,o,n)=>{const i=n.writer;!function(e){for(const o of t)e.removeClass("ck-editor__editable_selected",o);t.clear()}(i);const r=this.getSelectedTableCells();if(!r)return;for(const e of r){const o=n.mapper.toViewElement(e);i.addClass("ck-editor__editable_selected",o),t.add(o)}const s=n.mapper.toViewElement(r[r.length-1]);i.setSelection(s,0)}),{priority:"lowest"})))}_enablePluginDisabling(){const e=this.editor;this.on("change:isEnabled",(()=>{if(!this.isEnabled){const t=this.getSelectedTableCells();if(!t)return;e.model.change((o=>{const n=o.createPositionAt(t[0],0),i=e.model.schema.getNearestSelectionRange(n);o.setSelection(i)}))}}))}_handleDeleteContent(e,t){const o=this.editor.plugins.get(vD),n=t[0],i=t[1],r=this.editor.model,s=!i||"backward"==i.direction,a=o.getSelectedTableCells(n);a.length&&(e.stop(),r.change((e=>{const t=a[s?a.length-1:0];r.change((e=>{for(const t of a)r.deleteContent(e.createSelection(t,"in"))}));const o=r.schema.getNearestSelectionRange(e.createPositionAt(t,0));n.is("documentSelection")?e.setSelection(o):n.setTo(o)})))}_handleInsertTextEvent(e,t){const o=this.editor,n=this.getSelectedTableCells();if(!n)return;const i=o.editing.view,r=o.editing.mapper,s=n.map((e=>i.createRangeOn(r.toViewElement(e))));t.selection=i.createSelection(s)}_getCellsToSelect(e,t){const o=this.editor.plugins.get("TableUtils"),n=o.getCellLocation(e),i=o.getCellLocation(t),r=Math.min(n.row,i.row),s=Math.max(n.row,i.row),a=Math.min(n.column,i.column),l=Math.max(n.column,i.column),c=new Array(s-r+1).fill(null).map((()=>[])),d={startRow:r,endRow:s,startColumn:a,endColumn:l};for(const{row:t,cell:o}of new ZE(e.findAncestor("table"),d))c[t-r].push(o);const u=i.rowe.reverse())),{cells:c.flat(),backward:u||h}}}class nB extends lr{static get pluginName(){return"TableClipboard"}static get requires(){return[L_,H_,oB,vD]}init(){const e=this.editor,t=e.editing.view.document;this.listenTo(t,"copy",((e,t)=>this._onCopyCut(e,t))),this.listenTo(t,"cut",((e,t)=>this._onCopyCut(e,t))),this.listenTo(e.model,"insertContent",((e,[t,o])=>this._onInsertContent(e,t,o)),{priority:"high"}),this.decorate("_replaceTableSlotCell")}_onCopyCut(e,t){const o=this.editor.editing.view,n=this.editor.plugins.get(oB),i=this.editor.plugins.get(L_);n.getSelectedTableCells()&&("cut"!=e.name||this.editor.model.canEditAt(this.editor.model.document.selection))&&(t.preventDefault(),e.stop(),this.editor.model.enqueueChange({isUndoable:"cut"===e.name},(()=>{const r=i._copySelectedFragmentWithMarkers(e.name,this.editor.model.document.selection,(()=>n.getSelectionAsFragment()));o.document.fire("clipboardOutput",{dataTransfer:t.dataTransfer,content:this.editor.data.toView(r),method:e.name})})))}_onInsertContent(e,t,o){if(o&&!o.is("documentSelection"))return;const n=this.editor.model,i=this.editor.plugins.get(vD),r=this.editor.plugins.get(L_),s=this.getTableIfOnlyTableInContent(t,n);if(!s)return;const a=i.getSelectionAffectedTableCells(n.document.selection);a.length?(e.stop(),t.is("documentFragment")?r._pasteMarkersIntoTransformedElement(t.markers,(e=>this._replaceSelectedCells(s,a,e))):this.editor.model.change((e=>{this._replaceSelectedCells(s,a,e)}))):mD(s,i)}_replaceSelectedCells(e,t,o){const n=this.editor.plugins.get(vD),i={width:n.getColumns(e),height:n.getRows(e)},r=function(e,t,o,n){const i=e[0].findAncestor("table"),r=n.getColumnIndexes(e),s=n.getRowIndexes(e),a={firstColumn:r.first,lastColumn:r.last,firstRow:s.first,lastRow:s.last},l=1===e.length;l&&(a.lastRow+=t.height-1,a.lastColumn+=t.width-1,function(e,t,o,n){const i=n.getColumns(e),r=n.getRows(e);o>i&&n.insertColumns(e,{at:i,columns:o-i});t>r&&n.insertRows(e,{at:r,rows:t-r})}(i,a.lastRow+1,a.lastColumn+1,n));l||!n.isSelectionRectangular(e)?function(e,t,o){const{firstRow:n,lastRow:i,firstColumn:r,lastColumn:s}=t,a={first:n,last:i},l={first:r,last:s};rB(e,r,a,o),rB(e,s+1,a,o),iB(e,n,l,o),iB(e,i+1,l,o,n)}(i,a,o):(a.lastRow=pD(i,a),a.lastColumn=gD(i,a));return a}(t,i,o,n),s=r.lastRow-r.firstRow+1,a=r.lastColumn-r.firstColumn+1;e=rD(e,{startRow:0,startColumn:0,endRow:Math.min(s,i.height)-1,endColumn:Math.min(a,i.width)-1},o);const l=t[0].findAncestor("table"),c=this._replaceSelectedCellsWithPasted(e,i,l,r,o);if(this.editor.plugins.get("TableSelection").isEnabled){const e=n.sortRanges(c.map((e=>o.createRangeOn(e))));o.setSelection(e)}else o.setSelection(c[0],0);return l}_replaceSelectedCellsWithPasted(e,t,o,n,i){const{width:r,height:s}=t,a=function(e,t,o){const n=new Array(o).fill(null).map((()=>new Array(t).fill(null)));for(const{column:t,row:o,cell:i}of new ZE(e))n[o][t]=i;return n}(e,r,s),l=[...new ZE(o,{startRow:n.firstRow,endRow:n.lastRow,startColumn:n.firstColumn,endColumn:n.lastColumn,includeAllSlots:!0})],c=[];let d;for(const e of l){const{row:t,column:o}=e;o===n.firstColumn&&(d=e.getPositionBefore());const l=t-n.firstRow,u=o-n.firstColumn,h=a[l%s][u%r],m=h?i.cloneElement(h):null,p=this._replaceTableSlotCell(e,m,d,i);p&&(dD(p,t,o,n.lastRow,n.lastColumn,i),c.push(p),d=i.createPositionAfter(p))}const u=parseInt(o.getAttribute("headingRows")||"0"),h=parseInt(o.getAttribute("headingColumns")||"0"),m=n.firstRowsB(e,t,o))).map((({cell:e})=>aD(e,t,n)))}function rB(e,t,o,n){if(t<1)return;return lD(e,t).filter((({row:e,cellHeight:t})=>sB(e,t,o))).map((({cell:e,column:o})=>cD(e,o,t,n)))}function sB(e,t,o){const n=e+t-1,{first:i,last:r}=o;return e>=i&&e<=r||e=i}class aB extends lr{static get pluginName(){return"TableKeyboard"}static get requires(){return[oB,vD]}init(){const e=this.editor,t=e.editing.view.document,o=e.t;this.listenTo(t,"arrowKey",((...e)=>this._onArrowKey(...e)),{context:"table"}),this.listenTo(t,"tab",((...e)=>this._handleTabOnSelectedTable(...e)),{context:"figure"}),this.listenTo(t,"tab",((...e)=>this._handleTab(...e)),{context:["th","td"]}),e.accessibility.addKeystrokeInfoGroup({id:"table",label:o("Keystrokes that can be used in a table cell"),keystrokes:[{label:o("Move the selection to the next cell"),keystroke:"Tab"},{label:o("Move the selection to the previous cell"),keystroke:"Shift+Tab"},{label:o("Insert a new table row (when in the last cell of a table)"),keystroke:"Tab"},{label:o("Navigate through the table"),keystroke:[["arrowup"],["arrowright"],["arrowdown"],["arrowleft"]]}]})}_handleTabOnSelectedTable(e,t){const o=this.editor,n=o.model.document.selection.getSelectedElement();n&&n.is("element","table")&&(t.preventDefault(),t.stopPropagation(),e.stop(),o.model.change((e=>{e.setSelection(e.createRangeIn(n.getChild(0).getChild(0)))})))}_handleTab(e,t){const o=this.editor,n=this.editor.plugins.get(vD),i=this.editor.plugins.get("TableSelection"),r=o.model.document.selection,s=!t.shiftKey;let a=n.getTableCellsContainingSelection(r)[0];if(a||(a=i.getFocusCell()),!a)return;t.preventDefault(),t.stopPropagation(),e.stop();const l=a.parent,c=l.parent,d=c.getChildIndex(l),u=l.getChildIndex(a),h=0===u;if(!s&&h&&0===d)return void o.model.change((e=>{e.setSelection(e.createRangeOn(c))}));const m=u===l.childCount-1,p=d===n.getRows(c)-1;if(s&&p&&m&&(o.execute("insertTableRowBelow"),d===n.getRows(c)-1))return void o.model.change((e=>{e.setSelection(e.createRangeOn(c))}));let g;if(s&&m){const e=c.getChild(d+1);g=e.getChild(0)}else if(!s&&h){const e=c.getChild(d-1);g=e.getChild(e.childCount-1)}else g=l.getChild(u+(s?1:-1));o.model.change((e=>{e.setSelection(e.createRangeIn(g))}))}_onArrowKey(e,t){const o=this.editor,n=Ci(t.keyCode,o.locale.contentLanguageDirection);this._handleArrowKeys(n,t.shiftKey)&&(t.preventDefault(),t.stopPropagation(),e.stop())}_handleArrowKeys(e,t){const o=this.editor.plugins.get(vD),n=this.editor.plugins.get("TableSelection"),i=this.editor.model,r=i.document.selection,s=["right","down"].includes(e),a=o.getSelectedTableCells(r);if(a.length){let o;return o=t?n.getFocusCell():s?a[a.length-1]:a[0],this._navigateFromCellInDirection(o,e,t),!0}const l=r.focus.findAncestor("tableCell");if(!l)return!1;if(!r.isCollapsed)if(t){if(r.isBackward==s&&!r.containsEntireContent(l))return!1}else{const e=r.getSelectedElement();if(!e||!i.schema.isObject(e))return!1}return!!this._isSelectionAtCellEdge(r,l,s)&&(this._navigateFromCellInDirection(l,e,t),!0)}_isSelectionAtCellEdge(e,t,o){const n=this.editor.model,i=this.editor.model.schema,r=o?e.getLastPosition():e.getFirstPosition();if(!i.getLimitElement(r).is("element","tableCell")){return n.createPositionAt(t,o?"end":0).isTouching(r)}const s=n.createSelection(r);return n.modifySelection(s,{direction:o?"forward":"backward"}),r.isEqual(s.focus)}_navigateFromCellInDirection(e,t,o=!1){const n=this.editor.model,i=e.findAncestor("table"),r=[...new ZE(i,{includeAllSlots:!0})],{row:s,column:a}=r[r.length-1],l=r.find((({cell:t})=>t==e));let{row:c,column:d}=l;switch(t){case"left":d--;break;case"up":c--;break;case"right":d+=l.cellWidth;break;case"down":c+=l.cellHeight}if(c<0||c>s||d<0&&c<=0||d>a&&c>=s)return void n.change((e=>{e.setSelection(e.createRangeOn(i))}));d<0?(d=o?0:a,c--):d>a&&(d=o?a:0,c++);const u=r.find((e=>e.row==c&&e.column==d)).cell,h=["right","down"].includes(t),m=this.editor.plugins.get("TableSelection");if(o&&m.isEnabled){const t=m.getAnchorCell()||e;m.setCellSelection(t,u)}else{const e=n.createPositionAt(u,h?0:"end");n.change((t=>{t.setSelection(e)}))}}}class lB extends La{constructor(){super(...arguments),this.domEventType=["mousemove","mouseleave"]}onDomEvent(e){this.fire(e.type,e)}}class cB extends lr{static get pluginName(){return"TableMouse"}static get requires(){return[oB,vD]}init(){this.editor.editing.view.addObserver(lB),this._enableShiftClickSelection(),this._enableMouseDragSelection()}_enableShiftClickSelection(){const e=this.editor,t=e.plugins.get(vD);let o=!1;const n=e.plugins.get(oB);this.listenTo(e.editing.view.document,"mousedown",((i,r)=>{const s=e.model.document.selection;if(!this.isEnabled||!n.isEnabled)return;if(!r.domEvent.shiftKey)return;const a=n.getAnchorCell()||t.getTableCellsContainingSelection(s)[0];if(!a)return;const l=this._getModelTableCellFromDomEvent(r);l&&dB(a,l)&&(o=!0,n.setCellSelection(a,l),r.preventDefault())})),this.listenTo(e.editing.view.document,"mouseup",(()=>{o=!1})),this.listenTo(e.editing.view.document,"selectionChange",(e=>{o&&e.stop()}),{priority:"highest"})}_enableMouseDragSelection(){const e=this.editor;let t,o,n=!1,i=!1;const r=e.plugins.get(oB);this.listenTo(e.editing.view.document,"mousedown",((e,o)=>{this.isEnabled&&r.isEnabled&&(o.domEvent.shiftKey||o.domEvent.ctrlKey||o.domEvent.altKey||(t=this._getModelTableCellFromDomEvent(o)))})),this.listenTo(e.editing.view.document,"mousemove",((e,s)=>{if(!s.domEvent.buttons)return;if(!t)return;const a=this._getModelTableCellFromDomEvent(s);a&&dB(t,a)&&(o=a,n||o==t||(n=!0)),n&&(i=!0,r.setCellSelection(t,o),s.preventDefault())})),this.listenTo(e.editing.view.document,"mouseup",(()=>{n=!1,i=!1,t=null,o=null})),this.listenTo(e.editing.view.document,"selectionChange",(e=>{i&&e.stop()}),{priority:"highest"})}_getModelTableCellFromDomEvent(e){const t=e.target,o=this.editor.editing.view.createPositionAt(t,0);return this.editor.editing.mapper.toModelPosition(o).parent.findAncestor("tableCell",{includeSelf:!0})}}function dB(e,t){return e.parent.parent==t.parent.parent}var uB=i(9969),hB={attributes:{"data-cke":!0}};hB.setAttributes=Ar(),hB.insert=_r().bind(null,"head"),hB.domAPI=kr(),hB.insertStyleElement=vr();fr()(uB.A,hB);uB.A&&uB.A.locals&&uB.A.locals;function mB(e){const t=pB(e);return t||gB(e)}function pB(e){const t=e.getSelectedElement();return t&&fB(t)?t:null}function gB(e){const t=e.getFirstPosition();if(!t)return null;let o=t.parent;for(;o;){if(o.is("element")&&fB(o))return o;o=o.parent}return null}function fB(e){return!!e.getCustomProperty("table")&&Rk(e)}var bB=i(4307),kB={attributes:{"data-cke":!0}};kB.setAttributes=Ar(),kB.insert=_r().bind(null,"head"),kB.domAPI=kr(),kB.insertStyleElement=vr();fr()(bB.A,kB);bB.A&&bB.A.locals&&bB.A.locals;class wB extends pm{constructor(e,t){super(e),this.set("value",""),this.set("isReadOnly",!1),this.set("isFocused",!1),this.set("isEmpty",!0),this.options=t,this.focusTracker=new Xi,this._focusables=new Uh,this.dropdownView=this._createDropdownView(),this.inputView=this._createInputTextView(),this.keystrokes=new er,this._stillTyping=!1,this.focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-input-color"]},children:[this.dropdownView,this.inputView]}),this.on("change:value",((e,t,o)=>this._setInputValue(o)))}render(){super.render(),[this.inputView,this.dropdownView.buttonView].forEach((e=>{this.focusTracker.add(e.element),this._focusables.add(e)})),this.keystrokes.listenTo(this.element)}focus(e){-1===e?this.focusCycler.focusLast():this.focusCycler.focusFirst()}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}_createDropdownView(){const e=this.locale,t=e.t,o=this.bindTemplate,n=this._createColorSelector(e),i=Eg(e),r=new pm;return r.setTemplate({tag:"span",attributes:{class:["ck","ck-input-color__button__preview"],style:{backgroundColor:o.to("value")}},children:[{tag:"span",attributes:{class:["ck","ck-input-color__button__preview__no-color-indicator",o.if("value","ck-hidden",(e=>""!=e))]}}]}),i.buttonView.extendTemplate({attributes:{class:"ck-input-color__button"}}),i.buttonView.children.add(r),i.buttonView.label=t("Color picker"),i.buttonView.tooltip=!0,i.panelPosition="rtl"===e.uiLanguageDirection?"se":"sw",i.panelView.children.add(n),i.bind("isEnabled").to(this,"isReadOnly",(e=>!e)),i.on("change:isOpen",((e,t,o)=>{o&&(n.updateSelectedColors(),n.showColorGridsFragment())})),i}_createInputTextView(){const e=this.locale,t=new Gp(e);return t.extendTemplate({on:{blur:t.bindTemplate.to("blur")}}),t.value=this.value,t.bind("isReadOnly","hasError").to(this),this.bind("isFocused","isEmpty").to(t),t.on("input",(()=>{const e=t.element.value,o=this.options.colorDefinitions.find((t=>e===t.label));this._stillTyping=!0,this.value=o&&o.color||e})),t.on("blur",(()=>{this._stillTyping=!1,this._setInputValue(t.element.value)})),t.delegate("input").to(this),t}_createColorSelector(e){const t=e.t,o=this.options.defaultColorValue||"",n=t(o?"Restore default":"Remove color"),i=new xf(e,{colors:this.options.colorDefinitions,columns:this.options.columns,removeButtonLabel:n,colorPickerLabel:t("Color picker"),colorPickerViewConfig:!1!==this.options.colorPickerConfig&&{...this.options.colorPickerConfig,hideInput:!0}});i.appendUI(),i.on("execute",((e,t)=>{"colorPickerSaveButton"!==t.source?(this.value=t.value||o,this.fire("input"),"colorPicker"!==t.source&&(this.dropdownView.isOpen=!1)):this.dropdownView.isOpen=!1}));let r=this.value;return i.on("colorPicker:cancel",(()=>{this.value=r,this.fire("input"),this.dropdownView.isOpen=!1})),i.colorGridsFragmentView.colorPickerButtonView.on("execute",(()=>{r=this.value})),i.bind("selectedColor").to(this,"value"),i}_setInputValue(e){if(!this._stillTyping){const t=_B(e),o=this.options.colorDefinitions.find((e=>t===_B(e.color)));this.inputView.value=o?o.label:e||""}}}function _B(e){return e.replace(/([(,])\s+/g,"$1").replace(/^\s+|\s+(?=[),\s]|$)/g,"").replace(/,|\s/g," ")}const yB=e=>""===e;function AB(e){return{none:e("None"),solid:e("Solid"),dotted:e("Dotted"),dashed:e("Dashed"),double:e("Double"),groove:e("Groove"),ridge:e("Ridge"),inset:e("Inset"),outset:e("Outset")}}function CB(e){return e('The color is invalid. Try "#FF0000" or "rgb(255,0,0)" or "red".')}function vB(e){return e('The value is invalid. Try "10px" or "2em" or simply "2".')}function xB(e){return e=e.trim().toLowerCase(),yB(e)||Ku(e)}function EB(e){return e=e.trim(),yB(e)||PB(e)||Qu(e)||(t=e,Xu.test(t));var t}function DB(e){return e=e.trim(),yB(e)||PB(e)||Qu(e)}function BB(e,t){const o=new Yi,n=AB(e.t);for(const i in n){const r={type:"button",model:new Db({_borderStyleValue:i,label:n[i],role:"menuitemradio",withText:!0})};"none"===i?r.model.bind("isOn").to(e,"borderStyle",(e=>"none"===t?!e:e===i)):r.model.bind("isOn").to(e,"borderStyle",(e=>e===i)),o.add(r)}return o}function SB(e){const{view:t,icons:o,toolbar:n,labels:i,propertyName:r,nameToValue:s,defaultValue:a}=e;for(const e in i){const l=new Em(t.locale);l.set({label:i[e],icon:o[e],tooltip:i[e]});const c=s?s(e):e;l.bind("isOn").to(t,r,(e=>{let t=e;return""===e&&a&&(t=a),c===t})),l.on("execute",(()=>{t[r]=c})),n.items.add(l)}}const TB=[{color:"hsl(0, 0%, 0%)",label:"Black"},{color:"hsl(0, 0%, 30%)",label:"Dim grey"},{color:"hsl(0, 0%, 60%)",label:"Grey"},{color:"hsl(0, 0%, 90%)",label:"Light grey"},{color:"hsl(0, 0%, 100%)",label:"White",hasBorder:!0},{color:"hsl(0, 75%, 60%)",label:"Red"},{color:"hsl(30, 75%, 60%)",label:"Orange"},{color:"hsl(60, 75%, 60%)",label:"Yellow"},{color:"hsl(90, 75%, 60%)",label:"Light green"},{color:"hsl(120, 75%, 60%)",label:"Green"},{color:"hsl(150, 75%, 60%)",label:"Aquamarine"},{color:"hsl(180, 75%, 60%)",label:"Turquoise"},{color:"hsl(210, 75%, 60%)",label:"Light blue"},{color:"hsl(240, 75%, 60%)",label:"Blue"},{color:"hsl(270, 75%, 60%)",label:"Purple"}];function IB(e){return(t,o,n)=>{const i=new wB(t.locale,{colorDefinitions:(r=e.colorConfig,r.map((e=>({color:e.model,label:e.label,options:{hasBorder:e.hasBorder}})))),columns:e.columns,defaultColorValue:e.defaultColorValue,colorPickerConfig:e.colorPickerConfig});var r;return i.inputView.set({id:o,ariaDescribedById:n}),i.bind("isReadOnly").to(t,"isEnabled",(e=>!e)),i.bind("hasError").to(t,"errorText",(e=>!!e)),i.on("input",(()=>{t.errorText=null})),t.bind("isEmpty","isFocused").to(i),i}}function PB(e){const t=parseFloat(e);return!Number.isNaN(t)&&e===String(t)}var FB=i(6016),MB={attributes:{"data-cke":!0}};MB.setAttributes=Ar(),MB.insert=_r().bind(null,"head"),MB.domAPI=kr(),MB.insertStyleElement=vr();fr()(FB.A,MB);FB.A&&FB.A.locals&&FB.A.locals;class RB extends pm{constructor(e,t={}){super(e);const o=this.bindTemplate;this.set("class",t.class||null),this.children=this.createCollection(),t.children&&t.children.forEach((e=>this.children.add(e))),this.set("_role",null),this.set("_ariaLabelledBy",null),t.labelView&&this.set({_role:"group",_ariaLabelledBy:t.labelView.id}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-form__row",o.to("class")],role:o.to("_role"),"aria-labelledby":o.to("_ariaLabelledBy")},children:this.children})}}var zB=i(1806),VB={attributes:{"data-cke":!0}};VB.setAttributes=Ar(),VB.insert=_r().bind(null,"head"),VB.domAPI=kr(),VB.insertStyleElement=vr();fr()(zB.A,VB);zB.A&&zB.A.locals&&zB.A.locals;var OB=i(5704),NB={attributes:{"data-cke":!0}};NB.setAttributes=Ar(),NB.insert=_r().bind(null,"head"),NB.domAPI=kr(),NB.insertStyleElement=vr();fr()(OB.A,NB);OB.A&&OB.A.locals&&OB.A.locals;var LB=i(6701),HB={attributes:{"data-cke":!0}};HB.setAttributes=Ar(),HB.insert=_r().bind(null,"head"),HB.domAPI=kr(),HB.insertStyleElement=vr();fr()(LB.A,HB);LB.A&&LB.A.locals&&LB.A.locals;class jB extends pm{constructor(e,t){super(e),this.set({borderStyle:"",borderWidth:"",borderColor:"",padding:"",backgroundColor:"",width:"",height:"",horizontalAlignment:"",verticalAlignment:""}),this.options=t;const{borderStyleDropdown:o,borderWidthInput:n,borderColorInput:i,borderRowLabel:r}=this._createBorderFields(),{backgroundRowLabel:s,backgroundInput:a}=this._createBackgroundFields(),{widthInput:l,operatorLabel:c,heightInput:d,dimensionsLabel:u}=this._createDimensionFields(),{horizontalAlignmentToolbar:h,verticalAlignmentToolbar:m,alignmentLabel:p}=this._createAlignmentFields();this.focusTracker=new Xi,this.keystrokes=new er,this.children=this.createCollection(),this.borderStyleDropdown=o,this.borderWidthInput=n,this.borderColorInput=i,this.backgroundInput=a,this.paddingInput=this._createPaddingField(),this.widthInput=l,this.heightInput=d,this.horizontalAlignmentToolbar=h,this.verticalAlignmentToolbar=m;const{saveButtonView:g,cancelButtonView:f}=this._createActionButtons();this.saveButtonView=g,this.cancelButtonView=f,this._focusables=new Uh,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.children.add(new Tm(e,{label:this.t("Cell properties")})),this.children.add(new RB(e,{labelView:r,children:[r,o,i,n],class:"ck-table-form__border-row"})),this.children.add(new RB(e,{labelView:s,children:[s,a],class:"ck-table-form__background-row"})),this.children.add(new RB(e,{children:[new RB(e,{labelView:u,children:[u,l,c,d],class:"ck-table-form__dimensions-row"}),new RB(e,{children:[this.paddingInput],class:"ck-table-cell-properties-form__padding-row"})]})),this.children.add(new RB(e,{labelView:p,children:[p,h,m],class:"ck-table-cell-properties-form__alignment-row"})),this.children.add(new RB(e,{children:[this.saveButtonView,this.cancelButtonView],class:"ck-table-form__action-row"})),this.setTemplate({tag:"form",attributes:{class:["ck","ck-form","ck-table-form","ck-table-cell-properties-form"],tabindex:"-1"},children:this.children})}render(){super.render(),bm({view:this}),[this.borderColorInput,this.backgroundInput].forEach((e=>{this._focusCycler.chain(e.fieldView.focusCycler)})),[this.borderStyleDropdown,this.borderColorInput,this.borderWidthInput,this.backgroundInput,this.widthInput,this.heightInput,this.paddingInput,this.horizontalAlignmentToolbar,this.verticalAlignmentToolbar,this.saveButtonView,this.cancelButtonView].forEach((e=>{this._focusables.add(e),this.focusTracker.add(e.element)})),this.keystrokes.listenTo(this.element)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this._focusCycler.focusFirst()}_createBorderFields(){const e=this.options.defaultTableCellProperties,t={style:e.borderStyle,width:e.borderWidth,color:e.borderColor},o=IB({colorConfig:this.options.borderColors,columns:5,defaultColorValue:t.color,colorPickerConfig:this.options.colorPickerConfig}),n=this.locale,i=this.t,r=i("Style"),s=new ap(n);s.text=i("Border");const a=AB(i),l=new jp(n,Rg);l.set({label:r,class:"ck-table-form__border-style"}),l.fieldView.buttonView.set({ariaLabel:r,ariaLabelledBy:void 0,isOn:!1,withText:!0,tooltip:r}),l.fieldView.buttonView.bind("label").to(this,"borderStyle",(e=>a[e||"none"])),l.fieldView.on("execute",(e=>{this.borderStyle=e.source._borderStyleValue})),l.bind("isEmpty").to(this,"borderStyle",(e=>!e)),Sg(l.fieldView,BB(this,t.style),{role:"menu",ariaLabel:r});const c=new jp(n,Fg);c.set({label:i("Width"),class:"ck-table-form__border-width"}),c.fieldView.bind("value").to(this,"borderWidth"),c.bind("isEnabled").to(this,"borderStyle",qB),c.fieldView.on("input",(()=>{this.borderWidth=c.fieldView.element.value}));const d=new jp(n,o);return d.set({label:i("Color"),class:"ck-table-form__border-color"}),d.fieldView.bind("value").to(this,"borderColor"),d.bind("isEnabled").to(this,"borderStyle",qB),d.fieldView.on("input",(()=>{this.borderColor=d.fieldView.value})),this.on("change:borderStyle",((e,o,n,i)=>{qB(n)||(this.borderColor="",this.borderWidth=""),qB(i)||(this.borderColor=t.color,this.borderWidth=t.width)})),{borderRowLabel:s,borderStyleDropdown:l,borderColorInput:d,borderWidthInput:c}}_createBackgroundFields(){const e=this.locale,t=this.t,o=new ap(e);o.text=t("Background");const n=IB({colorConfig:this.options.backgroundColors,columns:5,defaultColorValue:this.options.defaultTableCellProperties.backgroundColor,colorPickerConfig:this.options.colorPickerConfig}),i=new jp(e,n);return i.set({label:t("Color"),class:"ck-table-cell-properties-form__background"}),i.fieldView.bind("value").to(this,"backgroundColor"),i.fieldView.on("input",(()=>{this.backgroundColor=i.fieldView.value})),{backgroundRowLabel:o,backgroundInput:i}}_createDimensionFields(){const e=this.locale,t=this.t,o=new ap(e);o.text=t("Dimensions");const n=new jp(e,Fg);n.set({label:t("Width"),class:"ck-table-form__dimensions-row__width"}),n.fieldView.bind("value").to(this,"width"),n.fieldView.on("input",(()=>{this.width=n.fieldView.element.value}));const i=new pm(e);i.setTemplate({tag:"span",attributes:{class:["ck-table-form__dimension-operator"]},children:[{text:"×"}]});const r=new jp(e,Fg);return r.set({label:t("Height"),class:"ck-table-form__dimensions-row__height"}),r.fieldView.bind("value").to(this,"height"),r.fieldView.on("input",(()=>{this.height=r.fieldView.element.value})),{dimensionsLabel:o,widthInput:n,operatorLabel:i,heightInput:r}}_createPaddingField(){const e=this.locale,t=this.t,o=new jp(e,Fg);return o.set({label:t("Padding"),class:"ck-table-cell-properties-form__padding"}),o.fieldView.bind("value").to(this,"padding"),o.fieldView.on("input",(()=>{this.padding=o.fieldView.element.value})),o}_createAlignmentFields(){const e=this.locale,t=this.t,o=new ap(e),n={left:qh.alignLeft,center:qh.alignCenter,right:qh.alignRight,justify:qh.alignJustify,top:qh.alignTop,middle:qh.alignMiddle,bottom:qh.alignBottom};o.text=t("Table cell text alignment");const i=new cg(e),r="rtl"===e.contentLanguageDirection;i.set({isCompact:!0,ariaLabel:t("Horizontal text alignment toolbar")}),SB({view:this,icons:n,toolbar:i,labels:this._horizontalAlignmentLabels,propertyName:"horizontalAlignment",nameToValue:e=>{if(r){if("left"===e)return"right";if("right"===e)return"left"}return e},defaultValue:this.options.defaultTableCellProperties.horizontalAlignment});const s=new cg(e);return s.set({isCompact:!0,ariaLabel:t("Vertical text alignment toolbar")}),SB({view:this,icons:n,toolbar:s,labels:this._verticalAlignmentLabels,propertyName:"verticalAlignment",defaultValue:this.options.defaultTableCellProperties.verticalAlignment}),{horizontalAlignmentToolbar:i,verticalAlignmentToolbar:s,alignmentLabel:o}}_createActionButtons(){const e=this.locale,t=this.t,o=new Em(e),n=new Em(e),i=[this.borderWidthInput,this.borderColorInput,this.backgroundInput,this.paddingInput];return o.set({label:t("Save"),icon:qh.check,class:"ck-button-save",type:"submit",withText:!0}),o.bind("isEnabled").toMany(i,"errorText",((...e)=>e.every((e=>!e)))),n.set({label:t("Cancel"),icon:qh.cancel,class:"ck-button-cancel",withText:!0}),n.delegate("execute").to(this,"cancel"),{saveButtonView:o,cancelButtonView:n}}get _horizontalAlignmentLabels(){const e=this.locale,t=this.t,o=t("Align cell text to the left"),n=t("Align cell text to the center"),i=t("Align cell text to the right"),r=t("Justify cell text");return"rtl"===e.uiLanguageDirection?{right:i,center:n,left:o,justify:r}:{left:o,center:n,right:i,justify:r}}get _verticalAlignmentLabels(){const e=this.t;return{top:e("Align cell text to the top"),middle:e("Align cell text to the middle"),bottom:e("Align cell text to the bottom")}}}function qB(e){return"none"!==e}const UB=(()=>[Ff.defaultPositions.northArrowSouth,Ff.defaultPositions.northArrowSouthWest,Ff.defaultPositions.northArrowSouthEast,Ff.defaultPositions.southArrowNorth,Ff.defaultPositions.southArrowNorthWest,Ff.defaultPositions.southArrowNorthEast,Ff.defaultPositions.viewportStickyNorth])();function WB(e,t){const o=e.plugins.get("ContextualBalloon"),n=e.editing.view.document.selection;let i;"cell"===t?gB(n)&&(i=GB(e)):mB(n)&&(i=$B(e)),i&&o.updatePosition(i)}function $B(e){const t=WE(e.model.document.selection),o=e.editing.mapper.toViewElement(t);return{target:e.editing.view.domConverter.mapViewToDom(o),positions:UB}}function GB(e){const t=e.editing.mapper,o=e.editing.view.domConverter,n=e.model.document.selection;if(n.rangeCount>1)return{target:()=>function(e,t){const o=t.editing.mapper,n=t.editing.view.domConverter,i=Array.from(e).map((e=>{const t=KB(e.start),i=o.toViewElement(t);return new qn(n.mapViewToDom(i))}));return qn.getBoundingRect(i)}(n.getRanges(),e),positions:UB};const i=KB(n.getFirstPosition()),r=t.toViewElement(i);return{target:o.mapViewToDom(r),positions:UB}}function KB(e){return e.nodeAfter&&e.nodeAfter.is("element","tableCell")?e.nodeAfter:e.findAncestor("tableCell")}function ZB(e){if(!e||!U(e))return e;const{top:t,right:o,bottom:n,left:i}=e;return t==o&&o==n&&n==i?t:void 0}function JB(e,t){const o=parseFloat(e);return Number.isNaN(o)||String(o)!==String(e)?e:`${o}${t}`}function YB(e,t={}){const o={borderStyle:"none",borderWidth:"",borderColor:"",backgroundColor:"",width:"",height:"",...e};return t.includeAlignmentProperty&&!o.alignment&&(o.alignment="center"),t.includePaddingProperty&&!o.padding&&(o.padding=""),t.includeVerticalAlignmentProperty&&!o.verticalAlignment&&(o.verticalAlignment="middle"),t.includeHorizontalAlignmentProperty&&!o.horizontalAlignment&&(o.horizontalAlignment=t.isRightToLeftContent?"right":"left"),o}const QB={borderStyle:"tableCellBorderStyle",borderColor:"tableCellBorderColor",borderWidth:"tableCellBorderWidth",height:"tableCellHeight",width:"tableCellWidth",padding:"tableCellPadding",backgroundColor:"tableCellBackgroundColor",horizontalAlignment:"tableCellHorizontalAlignment",verticalAlignment:"tableCellVerticalAlignment"};class XB extends lr{static get requires(){return[Fb]}static get pluginName(){return"TableCellPropertiesUI"}constructor(e){super(e),e.config.define("table.tableCellProperties",{borderColors:TB,backgroundColors:TB})}init(){const e=this.editor,t=e.t;this._defaultTableCellProperties=YB(e.config.get("table.tableCellProperties.defaultProperties"),{includeVerticalAlignmentProperty:!0,includeHorizontalAlignmentProperty:!0,includePaddingProperty:!0,isRightToLeftContent:"rtl"===e.locale.contentLanguageDirection}),this._balloon=e.plugins.get(Fb),this.view=null,this._isReady=!1,e.ui.componentFactory.add("tableCellProperties",(o=>{const n=new Em(o);n.set({label:t("Cell properties"),icon:'',tooltip:!0}),this.listenTo(n,"execute",(()=>this._showView()));const i=Object.values(QB).map((t=>e.commands.get(t)));return n.bind("isEnabled").toMany(i,"isEnabled",((...e)=>e.some((e=>e)))),n}))}destroy(){super.destroy(),this.view&&this.view.destroy()}_createPropertiesView(){const e=this.editor,t=e.config.get("table.tableCellProperties"),o=Dp(t.borderColors),n=Ep(e.locale,o),i=Dp(t.backgroundColors),r=Ep(e.locale,i),s=!1!==t.colorPicker,a=new jB(e.locale,{borderColors:n,backgroundColors:r,defaultTableCellProperties:this._defaultTableCellProperties,colorPickerConfig:!!s&&(t.colorPicker||{})}),l=e.t;a.render(),this.listenTo(a,"submit",(()=>{this._hideView()})),this.listenTo(a,"cancel",(()=>{this._undoStepBatch.operations.length&&e.execute("undo",this._undoStepBatch),this._hideView()})),a.keystrokes.set("Esc",((e,t)=>{this._hideView(),t()})),gm({emitter:a,activator:()=>this._isViewInBalloon,contextElements:[this._balloon.view.element],callback:()=>this._hideView()});const c=CB(l),d=vB(l);return a.on("change:borderStyle",this._getPropertyChangeCallback("tableCellBorderStyle")),a.on("change:borderColor",this._getValidatedPropertyChangeCallback({viewField:a.borderColorInput,commandName:"tableCellBorderColor",errorText:c,validator:xB})),a.on("change:borderWidth",this._getValidatedPropertyChangeCallback({viewField:a.borderWidthInput,commandName:"tableCellBorderWidth",errorText:d,validator:DB})),a.on("change:padding",this._getValidatedPropertyChangeCallback({viewField:a.paddingInput,commandName:"tableCellPadding",errorText:d,validator:EB})),a.on("change:width",this._getValidatedPropertyChangeCallback({viewField:a.widthInput,commandName:"tableCellWidth",errorText:d,validator:EB})),a.on("change:height",this._getValidatedPropertyChangeCallback({viewField:a.heightInput,commandName:"tableCellHeight",errorText:d,validator:EB})),a.on("change:backgroundColor",this._getValidatedPropertyChangeCallback({viewField:a.backgroundInput,commandName:"tableCellBackgroundColor",errorText:c,validator:xB})),a.on("change:horizontalAlignment",this._getPropertyChangeCallback("tableCellHorizontalAlignment")),a.on("change:verticalAlignment",this._getPropertyChangeCallback("tableCellVerticalAlignment")),a}_fillViewFormFromCommandValues(){const e=this.editor.commands,t=e.get("tableCellBorderStyle");Object.entries(QB).map((([t,o])=>{const n=this._defaultTableCellProperties[t]||"";return[t,e.get(o).value||n]})).forEach((([e,o])=>{("borderColor"!==e&&"borderWidth"!==e||"none"!==t.value)&&this.view.set(e,o)})),this._isReady=!0}_showView(){const e=this.editor;this.view||(this.view=this._createPropertiesView()),this.listenTo(e.ui,"update",(()=>{this._updateView()})),this._fillViewFormFromCommandValues(),this._balloon.add({view:this.view,position:GB(e)}),this._undoStepBatch=e.model.createBatch(),this.view.focus()}_hideView(){const e=this.editor;this.stopListening(e.ui,"update"),this._isReady=!1,this.view.saveButtonView.focus(),this._balloon.remove(this.view),this.editor.editing.view.focus()}_updateView(){const e=this.editor;gB(e.editing.view.document.selection)?this._isViewVisible&&WB(e,"cell"):this._hideView()}get _isViewVisible(){return!!this.view&&this._balloon.visibleView===this.view}get _isViewInBalloon(){return!!this.view&&this._balloon.hasView(this.view)}_getPropertyChangeCallback(e){return(t,o,n)=>{this._isReady&&this.editor.execute(e,{value:n,batch:this._undoStepBatch})}}_getValidatedPropertyChangeCallback(e){const{commandName:t,viewField:o,validator:n,errorText:i}=e,r=el((()=>{o.errorText=i}),500);return(e,i,s)=>{r.cancel(),this._isReady&&(n(s)?(this.editor.execute(t,{value:s,batch:this._undoStepBatch}),o.errorText=null):r())}}}class eS extends dr{constructor(e,t,o){super(e),this.attributeName=t,this._defaultValue=o}refresh(){const e=this.editor,t=this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(e.model.document.selection);this.isEnabled=!!t.length,this.value=this._getSingleValue(t)}execute(e={}){const{value:t,batch:o}=e,n=this.editor.model,i=this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(n.document.selection),r=this._getValueToSet(t);n.enqueueChange(o,(e=>{r?i.forEach((t=>e.setAttribute(this.attributeName,r,t))):i.forEach((t=>e.removeAttribute(this.attributeName,t)))}))}_getAttribute(e){if(!e)return;const t=e.getAttribute(this.attributeName);return t!==this._defaultValue?t:void 0}_getValueToSet(e){if(e!==this._defaultValue)return e}_getSingleValue(e){const t=this._getAttribute(e[0]);return e.every((e=>this._getAttribute(e)===t))?t:void 0}}class tS extends eS{constructor(e,t){super(e,"tableCellWidth",t)}_getValueToSet(e){if((e=JB(e,"px"))!==this._defaultValue)return e}}class oS extends lr{static get pluginName(){return"TableCellWidthEditing"}static get requires(){return[GD]}init(){const e=this.editor,t=YB(e.config.get("table.tableCellProperties.defaultProperties"));UE(e.model.schema,e.conversion,{modelAttribute:"tableCellWidth",styleName:"width",defaultValue:t.width}),e.commands.add("tableCellWidth",new tS(e,t.width))}}class nS extends eS{constructor(e,t){super(e,"tableCellPadding",t)}_getAttribute(e){if(!e)return;const t=ZB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}_getValueToSet(e){const t=JB(e,"px");if(t!==this._defaultValue)return t}}class iS extends eS{constructor(e,t){super(e,"tableCellHeight",t)}_getValueToSet(e){const t=JB(e,"px");if(t!==this._defaultValue)return t}}class rS extends eS{constructor(e,t){super(e,"tableCellBackgroundColor",t)}}class sS extends eS{constructor(e,t){super(e,"tableCellVerticalAlignment",t)}}class aS extends eS{constructor(e,t){super(e,"tableCellHorizontalAlignment",t)}}class lS extends eS{constructor(e,t){super(e,"tableCellBorderStyle",t)}_getAttribute(e){if(!e)return;const t=ZB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}}class cS extends eS{constructor(e,t){super(e,"tableCellBorderColor",t)}_getAttribute(e){if(!e)return;const t=ZB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}}class dS extends eS{constructor(e,t){super(e,"tableCellBorderWidth",t)}_getAttribute(e){if(!e)return;const t=ZB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}_getValueToSet(e){const t=JB(e,"px");if(t!==this._defaultValue)return t}}const uS=/^(top|middle|bottom)$/,hS=/^(left|center|right|justify)$/;class mS extends lr{static get pluginName(){return"TableCellPropertiesEditing"}static get requires(){return[GD,oS]}init(){const e=this.editor,t=e.model.schema,o=e.conversion;e.config.define("table.tableCellProperties.defaultProperties",{});const n=YB(e.config.get("table.tableCellProperties.defaultProperties"),{includeVerticalAlignmentProperty:!0,includeHorizontalAlignmentProperty:!0,includePaddingProperty:!0,isRightToLeftContent:"rtl"===e.locale.contentLanguageDirection});e.data.addStyleProcessorRules(mh),function(e,t,o){const n={width:"tableCellBorderWidth",color:"tableCellBorderColor",style:"tableCellBorderStyle"};e.extend("tableCell",{allowAttributes:Object.values(n)}),VE(t,"td",n,o),VE(t,"th",n,o),OE(t,{modelElement:"tableCell",modelAttribute:n.style,styleName:"border-style"}),OE(t,{modelElement:"tableCell",modelAttribute:n.color,styleName:"border-color"}),OE(t,{modelElement:"tableCell",modelAttribute:n.width,styleName:"border-width"})}(t,o,{color:n.borderColor,style:n.borderStyle,width:n.borderWidth}),e.commands.add("tableCellBorderStyle",new lS(e,n.borderStyle)),e.commands.add("tableCellBorderColor",new cS(e,n.borderColor)),e.commands.add("tableCellBorderWidth",new dS(e,n.borderWidth)),UE(t,o,{modelAttribute:"tableCellHeight",styleName:"height",defaultValue:n.height}),e.commands.add("tableCellHeight",new iS(e,n.height)),e.data.addStyleProcessorRules(Ch),UE(t,o,{modelAttribute:"tableCellPadding",styleName:"padding",reduceBoxSides:!0,defaultValue:n.padding}),e.commands.add("tableCellPadding",new nS(e,n.padding)),e.data.addStyleProcessorRules(hh),UE(t,o,{modelAttribute:"tableCellBackgroundColor",styleName:"background-color",defaultValue:n.backgroundColor}),e.commands.add("tableCellBackgroundColor",new rS(e,n.backgroundColor)),function(e,t,o){e.extend("tableCell",{allowAttributes:["tableCellHorizontalAlignment"]}),t.for("downcast").attributeToAttribute({model:{name:"tableCell",key:"tableCellHorizontalAlignment"},view:e=>({key:"style",value:{"text-align":e}})}),t.for("upcast").attributeToAttribute({view:{name:/^(td|th)$/,styles:{"text-align":hS}},model:{key:"tableCellHorizontalAlignment",value:e=>{const t=e.getStyle("text-align");return t===o?null:t}}}).attributeToAttribute({view:{name:/^(td|th)$/,attributes:{align:hS}},model:{key:"tableCellHorizontalAlignment",value:e=>{const t=e.getAttribute("align");return t===o?null:t}}})}(t,o,n.horizontalAlignment),e.commands.add("tableCellHorizontalAlignment",new aS(e,n.horizontalAlignment)),function(e,t,o){e.extend("tableCell",{allowAttributes:["tableCellVerticalAlignment"]}),t.for("downcast").attributeToAttribute({model:{name:"tableCell",key:"tableCellVerticalAlignment"},view:e=>({key:"style",value:{"vertical-align":e}})}),t.for("upcast").attributeToAttribute({view:{name:/^(td|th)$/,styles:{"vertical-align":uS}},model:{key:"tableCellVerticalAlignment",value:e=>{const t=e.getStyle("vertical-align");return t===o?null:t}}}).attributeToAttribute({view:{name:/^(td|th)$/,attributes:{valign:uS}},model:{key:"tableCellVerticalAlignment",value:e=>{const t=e.getAttribute("valign");return t===o?null:t}}})}(t,o,n.verticalAlignment),e.commands.add("tableCellVerticalAlignment",new sS(e,n.verticalAlignment))}}class pS extends dr{constructor(e,t,o){super(e),this.attributeName=t,this._defaultValue=o}refresh(){const e=WE(this.editor.model.document.selection);this.isEnabled=!!e,this.value=this._getValue(e)}execute(e={}){const t=this.editor.model,o=t.document.selection,{value:n,batch:i}=e,r=WE(o),s=this._getValueToSet(n);t.enqueueChange(i,(e=>{s?e.setAttribute(this.attributeName,s,r):e.removeAttribute(this.attributeName,r)}))}_getValue(e){if(!e)return;const t=e.getAttribute(this.attributeName);return t!==this._defaultValue?t:void 0}_getValueToSet(e){if(e!==this._defaultValue)return e}}class gS extends pS{constructor(e,t){super(e,"tableBackgroundColor",t)}}class fS extends pS{constructor(e,t){super(e,"tableBorderColor",t)}_getValue(e){if(!e)return;const t=ZB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}}class bS extends pS{constructor(e,t){super(e,"tableBorderStyle",t)}_getValue(e){if(!e)return;const t=ZB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}}class kS extends pS{constructor(e,t){super(e,"tableBorderWidth",t)}_getValue(e){if(!e)return;const t=ZB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}_getValueToSet(e){const t=JB(e,"px");if(t!==this._defaultValue)return t}}class wS extends pS{constructor(e,t){super(e,"tableWidth",t)}_getValueToSet(e){if((e=JB(e,"px"))!==this._defaultValue)return e}}class _S extends pS{constructor(e,t){super(e,"tableHeight",t)}_getValueToSet(e){if((e=JB(e,"px"))!==this._defaultValue)return e}}class yS extends pS{constructor(e,t){super(e,"tableAlignment",t)}}const AS=/^(left|center|right)$/,CS=/^(left|none|right)$/;class vS extends lr{static get pluginName(){return"TablePropertiesEditing"}static get requires(){return[GD]}init(){const e=this.editor,t=e.model.schema,o=e.conversion;e.config.define("table.tableProperties.defaultProperties",{});const n=YB(e.config.get("table.tableProperties.defaultProperties"),{includeAlignmentProperty:!0});e.data.addStyleProcessorRules(mh),function(e,t,o){const n={width:"tableBorderWidth",color:"tableBorderColor",style:"tableBorderStyle"};e.extend("table",{allowAttributes:Object.values(n)}),VE(t,"table",n,o),NE(t,{modelAttribute:n.color,styleName:"border-color"}),NE(t,{modelAttribute:n.style,styleName:"border-style"}),NE(t,{modelAttribute:n.width,styleName:"border-width"})}(t,o,{color:n.borderColor,style:n.borderStyle,width:n.borderWidth}),e.commands.add("tableBorderColor",new fS(e,n.borderColor)),e.commands.add("tableBorderStyle",new bS(e,n.borderStyle)),e.commands.add("tableBorderWidth",new kS(e,n.borderWidth)),function(e,t,o){e.extend("table",{allowAttributes:["tableAlignment"]}),t.for("downcast").attributeToAttribute({model:{name:"table",key:"tableAlignment"},view:e=>({key:"style",value:{float:"center"===e?"none":e}}),converterPriority:"high"}),t.for("upcast").attributeToAttribute({view:{name:/^(table|figure)$/,styles:{float:CS}},model:{key:"tableAlignment",value:e=>{let t=e.getStyle("float");return"none"===t&&(t="center"),t===o?null:t}}}).attributeToAttribute({view:{attributes:{align:AS}},model:{name:"table",key:"tableAlignment",value:e=>{const t=e.getAttribute("align");return t===o?null:t}}})}(t,o,n.alignment),e.commands.add("tableAlignment",new yS(e,n.alignment)),xS(t,o,{modelAttribute:"tableWidth",styleName:"width",defaultValue:n.width}),e.commands.add("tableWidth",new wS(e,n.width)),xS(t,o,{modelAttribute:"tableHeight",styleName:"height",defaultValue:n.height}),e.commands.add("tableHeight",new _S(e,n.height)),e.data.addStyleProcessorRules(hh),function(e,t,o){const{modelAttribute:n}=o;e.extend("table",{allowAttributes:[n]}),zE(t,{viewElement:"table",...o}),NE(t,o)}(t,o,{modelAttribute:"tableBackgroundColor",styleName:"background-color",defaultValue:n.backgroundColor}),e.commands.add("tableBackgroundColor",new gS(e,n.backgroundColor))}}function xS(e,t,o){const{modelAttribute:n}=o;e.extend("table",{allowAttributes:[n]}),zE(t,{viewElement:/^(table|figure)$/,shouldUpcast:e=>!("table"==e.name&&"figure"==e.parent.name),...o}),OE(t,{modelElement:"table",...o})}var ES=i(4001),DS={attributes:{"data-cke":!0}};DS.setAttributes=Ar(),DS.insert=_r().bind(null,"head"),DS.domAPI=kr(),DS.insertStyleElement=vr();fr()(ES.A,DS);ES.A&&ES.A.locals&&ES.A.locals;class BS extends pm{constructor(e,t){super(e),this.set({borderStyle:"",borderWidth:"",borderColor:"",backgroundColor:"",width:"",height:"",alignment:""}),this.options=t;const{borderStyleDropdown:o,borderWidthInput:n,borderColorInput:i,borderRowLabel:r}=this._createBorderFields(),{backgroundRowLabel:s,backgroundInput:a}=this._createBackgroundFields(),{widthInput:l,operatorLabel:c,heightInput:d,dimensionsLabel:u}=this._createDimensionFields(),{alignmentToolbar:h,alignmentLabel:m}=this._createAlignmentFields();this.focusTracker=new Xi,this.keystrokes=new er,this.children=this.createCollection(),this.borderStyleDropdown=o,this.borderWidthInput=n,this.borderColorInput=i,this.backgroundInput=a,this.widthInput=l,this.heightInput=d,this.alignmentToolbar=h;const{saveButtonView:p,cancelButtonView:g}=this._createActionButtons();this.saveButtonView=p,this.cancelButtonView=g,this._focusables=new Uh,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.children.add(new Tm(e,{label:this.t("Table properties")})),this.children.add(new RB(e,{labelView:r,children:[r,o,i,n],class:"ck-table-form__border-row"})),this.children.add(new RB(e,{labelView:s,children:[s,a],class:"ck-table-form__background-row"})),this.children.add(new RB(e,{children:[new RB(e,{labelView:u,children:[u,l,c,d],class:"ck-table-form__dimensions-row"}),new RB(e,{labelView:m,children:[m,h],class:"ck-table-properties-form__alignment-row"})]})),this.children.add(new RB(e,{children:[this.saveButtonView,this.cancelButtonView],class:"ck-table-form__action-row"})),this.setTemplate({tag:"form",attributes:{class:["ck","ck-form","ck-table-form","ck-table-properties-form"],tabindex:"-1"},children:this.children})}render(){super.render(),bm({view:this}),[this.borderColorInput,this.backgroundInput].forEach((e=>{this._focusCycler.chain(e.fieldView.focusCycler)})),[this.borderStyleDropdown,this.borderColorInput,this.borderWidthInput,this.backgroundInput,this.widthInput,this.heightInput,this.alignmentToolbar,this.saveButtonView,this.cancelButtonView].forEach((e=>{this._focusables.add(e),this.focusTracker.add(e.element)})),this.keystrokes.listenTo(this.element)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this._focusCycler.focusFirst()}_createBorderFields(){const e=this.options.defaultTableProperties,t={style:e.borderStyle,width:e.borderWidth,color:e.borderColor},o=IB({colorConfig:this.options.borderColors,columns:5,defaultColorValue:t.color,colorPickerConfig:this.options.colorPickerConfig}),n=this.locale,i=this.t,r=i("Style"),s=new ap(n);s.text=i("Border");const a=AB(i),l=new jp(n,Rg);l.set({label:r,class:"ck-table-form__border-style"}),l.fieldView.buttonView.set({ariaLabel:r,ariaLabelledBy:void 0,isOn:!1,withText:!0,tooltip:r}),l.fieldView.buttonView.bind("label").to(this,"borderStyle",(e=>a[e||"none"])),l.fieldView.on("execute",(e=>{this.borderStyle=e.source._borderStyleValue})),l.bind("isEmpty").to(this,"borderStyle",(e=>!e)),Sg(l.fieldView,BB(this,t.style),{role:"menu",ariaLabel:r});const c=new jp(n,Fg);c.set({label:i("Width"),class:"ck-table-form__border-width"}),c.fieldView.bind("value").to(this,"borderWidth"),c.bind("isEnabled").to(this,"borderStyle",SS),c.fieldView.on("input",(()=>{this.borderWidth=c.fieldView.element.value}));const d=new jp(n,o);return d.set({label:i("Color"),class:"ck-table-form__border-color"}),d.fieldView.bind("value").to(this,"borderColor"),d.bind("isEnabled").to(this,"borderStyle",SS),d.fieldView.on("input",(()=>{this.borderColor=d.fieldView.value})),this.on("change:borderStyle",((e,o,n,i)=>{SS(n)||(this.borderColor="",this.borderWidth=""),SS(i)||(this.borderColor=t.color,this.borderWidth=t.width)})),{borderRowLabel:s,borderStyleDropdown:l,borderColorInput:d,borderWidthInput:c}}_createBackgroundFields(){const e=this.locale,t=this.t,o=new ap(e);o.text=t("Background");const n=IB({colorConfig:this.options.backgroundColors,columns:5,defaultColorValue:this.options.defaultTableProperties.backgroundColor,colorPickerConfig:this.options.colorPickerConfig}),i=new jp(e,n);return i.set({label:t("Color"),class:"ck-table-properties-form__background"}),i.fieldView.bind("value").to(this,"backgroundColor"),i.fieldView.on("input",(()=>{this.backgroundColor=i.fieldView.value})),{backgroundRowLabel:o,backgroundInput:i}}_createDimensionFields(){const e=this.locale,t=this.t,o=new ap(e);o.text=t("Dimensions");const n=new jp(e,Fg);n.set({label:t("Width"),class:"ck-table-form__dimensions-row__width"}),n.fieldView.bind("value").to(this,"width"),n.fieldView.on("input",(()=>{this.width=n.fieldView.element.value}));const i=new pm(e);i.setTemplate({tag:"span",attributes:{class:["ck-table-form__dimension-operator"]},children:[{text:"×"}]});const r=new jp(e,Fg);return r.set({label:t("Height"),class:"ck-table-form__dimensions-row__height"}),r.fieldView.bind("value").to(this,"height"),r.fieldView.on("input",(()=>{this.height=r.fieldView.element.value})),{dimensionsLabel:o,widthInput:n,operatorLabel:i,heightInput:r}}_createAlignmentFields(){const e=this.locale,t=this.t,o=new ap(e);o.text=t("Alignment");const n=new cg(e);return n.set({isCompact:!0,ariaLabel:t("Table alignment toolbar")}),SB({view:this,icons:{left:qh.objectLeft,center:qh.objectCenter,right:qh.objectRight},toolbar:n,labels:this._alignmentLabels,propertyName:"alignment",defaultValue:this.options.defaultTableProperties.alignment}),{alignmentLabel:o,alignmentToolbar:n}}_createActionButtons(){const e=this.locale,t=this.t,o=new Em(e),n=new Em(e),i=[this.borderWidthInput,this.borderColorInput,this.backgroundInput,this.widthInput,this.heightInput];return o.set({label:t("Save"),icon:qh.check,class:"ck-button-save",type:"submit",withText:!0}),o.bind("isEnabled").toMany(i,"errorText",((...e)=>e.every((e=>!e)))),n.set({label:t("Cancel"),icon:qh.cancel,class:"ck-button-cancel",withText:!0}),n.delegate("execute").to(this,"cancel"),{saveButtonView:o,cancelButtonView:n}}get _alignmentLabels(){const e=this.locale,t=this.t,o=t("Align table to the left"),n=t("Center table"),i=t("Align table to the right");return"rtl"===e.uiLanguageDirection?{right:i,center:n,left:o}:{left:o,center:n,right:i}}}function SS(e){return"none"!==e}const TS={borderStyle:"tableBorderStyle",borderColor:"tableBorderColor",borderWidth:"tableBorderWidth",backgroundColor:"tableBackgroundColor",width:"tableWidth",height:"tableHeight",alignment:"tableAlignment"};class IS extends lr{static get requires(){return[Fb]}static get pluginName(){return"TablePropertiesUI"}constructor(e){super(e),this.view=null,e.config.define("table.tableProperties",{borderColors:TB,backgroundColors:TB})}init(){const e=this.editor,t=e.t;this._defaultTableProperties=YB(e.config.get("table.tableProperties.defaultProperties"),{includeAlignmentProperty:!0}),this._balloon=e.plugins.get(Fb),e.ui.componentFactory.add("tableProperties",(o=>{const n=new Em(o);n.set({label:t("Table properties"),icon:'',tooltip:!0}),this.listenTo(n,"execute",(()=>this._showView()));const i=Object.values(TS).map((t=>e.commands.get(t)));return n.bind("isEnabled").toMany(i,"isEnabled",((...e)=>e.some((e=>e)))),n}))}destroy(){super.destroy(),this.view&&this.view.destroy()}_createPropertiesView(){const e=this.editor,t=e.config.get("table.tableProperties"),o=Dp(t.borderColors),n=Ep(e.locale,o),i=Dp(t.backgroundColors),r=Ep(e.locale,i),s=!1!==t.colorPicker,a=new BS(e.locale,{borderColors:n,backgroundColors:r,defaultTableProperties:this._defaultTableProperties,colorPickerConfig:!!s&&(t.colorPicker||{})}),l=e.t;a.render(),this.listenTo(a,"submit",(()=>{this._hideView()})),this.listenTo(a,"cancel",(()=>{this._undoStepBatch.operations.length&&e.execute("undo",this._undoStepBatch),this._hideView()})),a.keystrokes.set("Esc",((e,t)=>{this._hideView(),t()})),gm({emitter:a,activator:()=>this._isViewInBalloon,contextElements:[this._balloon.view.element],callback:()=>this._hideView()});const c=CB(l),d=vB(l);return a.on("change:borderStyle",this._getPropertyChangeCallback("tableBorderStyle")),a.on("change:borderColor",this._getValidatedPropertyChangeCallback({viewField:a.borderColorInput,commandName:"tableBorderColor",errorText:c,validator:xB})),a.on("change:borderWidth",this._getValidatedPropertyChangeCallback({viewField:a.borderWidthInput,commandName:"tableBorderWidth",errorText:d,validator:DB})),a.on("change:backgroundColor",this._getValidatedPropertyChangeCallback({viewField:a.backgroundInput,commandName:"tableBackgroundColor",errorText:c,validator:xB})),a.on("change:width",this._getValidatedPropertyChangeCallback({viewField:a.widthInput,commandName:"tableWidth",errorText:d,validator:EB})),a.on("change:height",this._getValidatedPropertyChangeCallback({viewField:a.heightInput,commandName:"tableHeight",errorText:d,validator:EB})),a.on("change:alignment",this._getPropertyChangeCallback("tableAlignment")),a}_fillViewFormFromCommandValues(){const e=this.editor.commands,t=e.get("tableBorderStyle");Object.entries(TS).map((([t,o])=>{const n=t,i=this._defaultTableProperties[n]||"";return[n,e.get(o).value||i]})).forEach((([e,o])=>{("borderColor"!==e&&"borderWidth"!==e||"none"!==t.value)&&this.view.set(e,o)})),this._isReady=!0}_showView(){const e=this.editor;this.view||(this.view=this._createPropertiesView()),this.listenTo(e.ui,"update",(()=>{this._updateView()})),this._fillViewFormFromCommandValues(),this._balloon.add({view:this.view,position:$B(e)}),this._undoStepBatch=e.model.createBatch(),this.view.focus()}_hideView(){const e=this.editor;this.stopListening(e.ui,"update"),this._isReady=!1,this.view.saveButtonView.focus(),this._balloon.remove(this.view),this.editor.editing.view.focus()}_updateView(){const e=this.editor;mB(e.editing.view.document.selection)?this._isViewVisible&&WB(e,"table"):this._hideView()}get _isViewVisible(){return!!this.view&&this._balloon.visibleView===this.view}get _isViewInBalloon(){return!!this.view&&this._balloon.hasView(this.view)}_getPropertyChangeCallback(e){return(t,o,n)=>{this._isReady&&this.editor.execute(e,{value:n,batch:this._undoStepBatch})}}_getValidatedPropertyChangeCallback(e){const{commandName:t,viewField:o,validator:n,errorText:i}=e,r=el((()=>{o.errorText=i}),500);return(e,i,s)=>{r.cancel(),this._isReady&&(n(s)?(this.editor.execute(t,{value:s,batch:this._undoStepBatch}),o.errorText=null):r())}}}var PS=i(7406),FS={attributes:{"data-cke":!0}};FS.setAttributes=Ar(),FS.insert=_r().bind(null,"head"),FS.domAPI=kr(),FS.insertStyleElement=vr();fr()(PS.A,FS);PS.A&&PS.A.locals&&PS.A.locals;var MS=i(4204),RS={attributes:{"data-cke":!0}};RS.setAttributes=Ar(),RS.insert=_r().bind(null,"head"),RS.domAPI=kr(),RS.insertStyleElement=vr();fr()(MS.A,RS);MS.A&&MS.A.locals&&MS.A.locals;function zS(e){return void 0!==e&&e.endsWith("px")}function VS(e){return e.toFixed(2).replace(/\.?0+$/,"")+"px"}function OS(e,t,o){if(!e.childCount)return;const n=new Lu(e.document),i=function(e,t){const o=t.createRangeIn(e),n=[],i=new Set;for(const e of o.getItems()){if(!e.is("element")||!e.name.match(/^(p|h\d+|li|div)$/))continue;let t=$S(e);if(void 0===t||0!=parseFloat(t)||Array.from(e.getClassNames()).find((e=>e.startsWith("MsoList")))||(t=void 0),e.hasStyle("mso-list")||void 0!==t&&i.has(t)){const o=US(e);n.push({element:e,id:o.id,order:o.order,indent:o.indent,marginLeft:t}),void 0!==t&&i.add(t)}else i.clear()}return n}(e,n);if(!i.length)return;const r={},s=[];for(const e of i)if(void 0!==e.indent){NS(e)||(s.length=0);const i=`${e.id}:${e.indent}`,a=Math.min(e.indent-1,s.length);if(as.length-1||s[a].listElement.name!=l.type){0==a&&"ol"==l.type&&void 0!==e.id&&r[i]&&(l.startIndex=r[i]);const t=qS(l,n,o);if(zS(e.marginLeft)&&(0==a||zS(s[a-1].marginLeft))){let o=e.marginLeft;a>0&&(o=VS(parseFloat(o)-parseFloat(s[a-1].marginLeft))),n.setStyle("padding-left",o,t)}if(0==s.length){const o=e.element.parent,i=o.getChildIndex(e.element)+1;n.insertChild(i,t,o)}else{const e=s[a-1].listItemElements;n.appendChild(t,e[e.length-1])}s[a]={...e,listElement:t,listItemElements:[]},0==a&&void 0!==e.id&&(r[i]=l.startIndex||1)}}const l="li"==e.element.name?e.element:n.createElement("li");n.appendChild(l,s[a].listElement),s[a].listItemElements.push(l),0==a&&void 0!==e.id&&r[i]++,e.element!=l&&n.appendChild(e.element,l),WS(e.element,n),n.removeStyle("text-indent",e.element),n.removeStyle("margin-left",e.element)}else{const t=s.find((t=>t.marginLeft==e.marginLeft));if(t){const o=t.listItemElements;n.appendChild(e.element,o[o.length-1]),n.removeStyle("margin-left",e.element)}else s.length=0}}function NS(e){const t=e.element.previousSibling;return LS(t||e.element.parent)}function LS(e){return e.is("element","ol")||e.is("element","ul")}function HS(e,t){const o=new RegExp(`@list l${e.id}:level${e.indent}\\s*({[^}]*)`,"gi"),n=/mso-level-number-format:([^;]{0,100});/gi,i=/mso-level-start-at:\s{0,100}([0-9]{0,10})\s{0,100};/gi,r=new RegExp(`@list\\s+l${e.id}:level\\d\\s*{[^{]*mso-level-text:"%\\d\\\\.`,"gi"),s=new RegExp(`@list l${e.id}:level\\d\\s*{[^{]*mso-level-number-format:`,"gi"),a=r.exec(t),l=s.exec(t),c=a&&!l,d=o.exec(t);let u="decimal",h="ol",m=null;if(d&&d[1]){const t=n.exec(d[1]);if(t&&t[1]&&(u=t[1].trim(),h="bullet"!==u&&"image"!==u?"ol":"ul"),"bullet"===u){const t=function(e){if("li"==e.name&&"ul"==e.parent.name&&e.parent.hasAttribute("type"))return e.parent.getAttribute("type");const t=function(e){if(e.getChild(0).is("$text"))return null;for(const t of e.getChildren()){if(!t.is("element","span"))continue;const e=t.getChild(0);if(e)return e.is("$text")?e:e.getChild(0)}return null}(e);if(!t)return null;const o=t._data;if("o"===o)return"circle";if("·"===o)return"disc";if("§"===o)return"square";return null}(e.element);t&&(u=t)}else{const e=i.exec(d[1]);e&&e[1]&&(m=parseInt(e[1]))}c&&(h="ol")}return{type:h,startIndex:m,style:jS(u),isLegalStyleList:c}}function jS(e){if(e.startsWith("arabic-leading-zero"))return"decimal-leading-zero";switch(e){case"alpha-upper":return"upper-alpha";case"alpha-lower":return"lower-alpha";case"roman-upper":return"upper-roman";case"roman-lower":return"lower-roman";case"circle":case"disc":case"square":return e;default:return null}}function qS(e,t,o){const n=t.createElement(e.type);return e.style&&t.setStyle("list-style-type",e.style,n),e.startIndex&&e.startIndex>1&&t.setAttribute("start",e.startIndex,n),e.isLegalStyleList&&o&&t.addClass("legal-list",n),n}function US(e){const t=e.getStyle("mso-list");if(void 0===t)return{};const o=t.match(/(^|\s{1,100})l(\d+)/i),n=t.match(/\s{0,100}lfo(\d+)/i),i=t.match(/\s{0,100}level(\d+)/i);return o&&n&&i?{id:o[2],order:n[1],indent:parseInt(i[1])}:{indent:1}}function WS(e,t){const o=new Hr({name:"span",styles:{"mso-list":"Ignore"}}),n=t.createRangeIn(e);for(const e of n)"elementStart"===e.type&&o.match(e.item)&&t.remove(e.item)}function $S(e){const t=e.getStyle("margin-left");return void 0===t||t.endsWith("px")?t:function(e){const t=parseFloat(e);return e.endsWith("pt")?VS(96*t/72):e.endsWith("pc")?VS(12*t*96/72):e.endsWith("in")?VS(96*t):e.endsWith("cm")?VS(96*t/2.54):e.endsWith("mm")?VS(t/10*96/2.54):e}(t)}function GS(e,t){if(!e.childCount)return;const o=new Lu(e.document),n=function(e,t){const o=t.createRangeIn(e),n=new Hr({name:/v:(.+)/}),i=[];for(const e of o){if("elementStart"!=e.type)continue;const t=e.item,o=t.previousSibling,r=o&&o.is("element")?o.name:null,s=["Chart"],a=n.match(t),l=t.getAttribute("o:gfxdata"),c="v:shapetype"===r,d=l&&s.some((e=>t.getAttribute("id").includes(e)));a&&l&&!c&&!d&&i.push(e.item.getAttribute("id"))}return i}(e,o);!function(e,t,o){const n=o.createRangeIn(t),i=new Hr({name:"img"}),r=[];for(const t of n)if(t.item.is("element")&&i.match(t.item)){const o=t.item,n=o.getAttribute("v:shapes")?o.getAttribute("v:shapes").split(" "):[];n.length&&n.every((t=>e.indexOf(t)>-1))?r.push(o):o.getAttribute("src")||r.push(o)}for(const e of r)o.remove(e)}(n,e,o),function(e,t,o){const n=o.createRangeIn(t),i=[];for(const t of n)if("elementStart"==t.type&&t.item.is("element","v:shape")){const o=t.item.getAttribute("id");if(e.includes(o))continue;r(t.item.parent.getChildren(),o)||i.push(t.item)}for(const e of i){const t={src:s(e)};e.hasAttribute("alt")&&(t.alt=e.getAttribute("alt"));const n=o.createElement("img",t);o.insertChild(e.index+1,n,e.parent)}function r(e,t){for(const o of e)if(o.is("element")){if("img"==o.name&&o.getAttribute("v:shapes")==t)return!0;if(r(o.getChildren(),t))return!0}return!1}function s(e){for(const t of e.getChildren())if(t.is("element")&&t.getAttribute("src"))return t.getAttribute("src")}}(n,e,o),function(e,t){const o=t.createRangeIn(e),n=new Hr({name:/v:(.+)/}),i=[];for(const e of o)"elementStart"==e.type&&n.match(e.item)&&i.push(e.item);for(const e of i)t.remove(e)}(e,o);const i=function(e,t){const o=t.createRangeIn(e),n=new Hr({name:"img"}),i=[];for(const e of o)e.item.is("element")&&n.match(e.item)&&e.item.getAttribute("src").startsWith("file://")&&i.push(e.item);return i}(e,o);i.length&&function(e,t,o){if(e.length===t.length)for(let n=0;nString.fromCharCode(parseInt(e,16)))).join(""))}const ZS=//i,JS=/xmlns:o="urn:schemas-microsoft-com/i;class YS{constructor(e,t=!1){this.document=e,this.hasMultiLevelListPlugin=t}isActive(e){return ZS.test(e)||JS.test(e)}execute(e){const{body:t,stylesString:o}=e._parsedData;OS(t,o,this.hasMultiLevelListPlugin),GS(t,e.dataTransfer.getData("text/rtf")),function(e){const t=[],o=new Lu(e.document);for(const{item:n}of o.createRangeIn(e))if(n.is("element")){for(const e of n.getClassNames())/\bmso/gi.exec(e)&&o.removeClass(e,n);for(const e of n.getStyleNames())/\bmso/gi.exec(e)&&o.removeStyle(e,n);(n.is("element","w:sdt")||n.is("element","w:sdtpr")&&n.isEmpty||n.is("element","o:p")&&n.isEmpty)&&t.push(n)}for(const e of t){const t=e.parent,n=t.getChildIndex(e);o.insertChild(n,e.getChildren(),t),o.remove(e)}}(t),e.content=t}}function QS(e,t,o,{blockElements:n,inlineObjectElements:i}){let r=o.createPositionAt(e,"forward"==t?"after":"before");return r=r.getLastMatchingPosition((({item:e})=>e.is("element")&&!n.includes(e.name)&&!i.includes(e.name)),{direction:t}),"forward"==t?r.nodeAfter:r.nodeBefore}function XS(e,t){return!!e&&e.is("element")&&t.includes(e.name)}const eT=/id=("|')docs-internal-guid-[-0-9a-f]+("|')/i;class tT{constructor(e){this.document=e}isActive(e){return eT.test(e)}execute(e){const t=new Lu(this.document),{body:o}=e._parsedData;!function(e,t){for(const o of e.getChildren())if(o.is("element","b")&&"normal"===o.getStyle("font-weight")){const n=e.getChildIndex(o);t.remove(o),t.insertChild(n,o.getChildren(),e)}}(o,t),function(e,t){for(const o of t.createRangeIn(e)){const e=o.item;if(e.is("element","li")){const o=e.getChild(0);o&&o.is("element","p")&&t.unwrapElement(o)}}}(o,t),function(e,t){const o=new Hs(t.document.stylesProcessor),n=new Pa(o,{renderingMode:"data"}),i=n.blockElements,r=n.inlineObjectElements,s=[];for(const o of t.createRangeIn(e)){const e=o.item;if(e.is("element","br")){const o=QS(e,"forward",t,{blockElements:i,inlineObjectElements:r}),n=QS(e,"backward",t,{blockElements:i,inlineObjectElements:r}),a=XS(o,i);(XS(n,i)||a)&&s.push(e)}}for(const e of s)e.hasClass("Apple-interchange-newline")?t.remove(e):t.replace(e,t.createElement("p"))}(o,t),e.content=o}}const oT=/(\s+)<\/span>/g,((e,t)=>1===t.length?" ":Array(t.length+1).join("  ").substr(0,t.length)))}function rT(e,t){const o=new DOMParser,n=function(e){return iT(iT(e)).replace(/([^\S\r\n]*?)[\r\n]+([^\S\r\n]*<\/span>)/g,"$1$2").replace(/<\/span>/g,"").replace(/()[\r\n]+(<\/span>)/g,"$1 $2").replace(/ <\//g," <\/o:p>/g," ").replace(/( |\u00A0)<\/o:p>/g,"").replace(/>([^\S\r\n]*[\r\n]\s*)<")}(function(e){const t="",o="",n=e.indexOf(t);if(n<0)return e;const i=e.indexOf(o,n+t.length);return e.substring(0,n+t.length)+(i>=0?e.substring(i):"")}(e=(e=e.replace(//,!0],[/^<\?/,/\?>/,!0],[/^/,!0],[/^/,!0],[new RegExp("^|$))","i"),/^$/,!0],[new RegExp(ue.source+"\\s*$"),/^$/,!1]];const me=[["table",function(e,t,o,n){if(t+2>o)return!1;let i=t+1;if(e.sCount[i]=4)return!1;let r=e.bMarks[i]+e.tShift[i];if(r>=e.eMarks[i])return!1;const s=e.src.charCodeAt(r++);if(124!==s&&45!==s&&58!==s)return!1;if(r>=e.eMarks[i])return!1;const a=e.src.charCodeAt(r++);if(124!==a&&45!==a&&58!==a&&!D(a))return!1;if(45===s&&D(a))return!1;for(;r=4)return!1;c=re(l),c.length&&""===c[0]&&c.shift(),c.length&&""===c[c.length-1]&&c.pop();const u=c.length;if(0===u||u!==d.length)return!1;if(n)return!0;const h=e.parentType;e.parentType="table";const m=e.md.block.ruler.getRules("blockquote"),p=[t,0];e.push("table_open","table",1).map=p,e.push("thead_open","thead",1).map=[t,t+1],e.push("tr_open","tr",1).map=[t,t+1];for(let t=0;t=4)break;if(c=re(l),c.length&&""===c[0]&&c.shift(),c.length&&""===c[c.length-1]&&c.pop(),f+=u-c.length,f>65536)break;if(i===t+2){e.push("tbody_open","tbody",1).map=g=[t+2,0]}e.push("tr_open","tr",1).map=[i,i+1];for(let t=0;t=4))break;n++,i=n}e.line=i;const r=e.push("code_block","code",0);return r.content=e.getLines(t,i,4+e.blkIndent,!1)+"\n",r.map=[t,e.line],!0}],["fence",function(e,t,o,n){let i=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;if(i+3>r)return!1;const s=e.src.charCodeAt(i);if(126!==s&&96!==s)return!1;let a=i;i=e.skipChars(i,s);let l=i-a;if(l<3)return!1;const c=e.src.slice(a,i),d=e.src.slice(i,r);if(96===s&&d.indexOf(String.fromCharCode(s))>=0)return!1;if(n)return!0;let u=t,h=!1;for(;(u++,!(u>=o))&&(i=a=e.bMarks[u]+e.tShift[u],r=e.eMarks[u],!(i=4||(i=e.skipChars(i,s),i-a=4)return!1;if(62!==e.src.charCodeAt(i))return!1;if(n)return!0;const a=[],l=[],c=[],d=[],u=e.md.block.ruler.getRules("blockquote"),h=e.parentType;e.parentType="blockquote";let m,p=!1;for(m=t;m=r)break;if(62===e.src.charCodeAt(i++)&&!t){let t,o,n=e.sCount[m]+1;32===e.src.charCodeAt(i)?(i++,n++,o=!1,t=!0):9===e.src.charCodeAt(i)?(t=!0,(e.bsCount[m]+n)%4==3?(i++,n++,o=!1):o=!0):t=!1;let s=n;for(a.push(e.bMarks[m]),e.bMarks[m]=i;i=r,l.push(e.bsCount[m]),e.bsCount[m]=e.sCount[m]+1+(t?1:0),c.push(e.sCount[m]),e.sCount[m]=s-n,d.push(e.tShift[m]),e.tShift[m]=i-e.bMarks[m];continue}if(p)break;let n=!1;for(let t=0,i=u.length;t";const b=[t,0];f.map=b,e.md.block.tokenize(e,t,m),e.push("blockquote_close","blockquote",-1).markup=">",e.lineMax=s,e.parentType=h,b[1]=e.line;for(let o=0;o=4)return!1;let r=e.bMarks[t]+e.tShift[t];const s=e.src.charCodeAt(r++);if(42!==s&&45!==s&&95!==s)return!1;let a=1;for(;r=4)return!1;if(e.listIndent>=0&&e.sCount[l]-e.listIndent>=4&&e.sCount[l]=e.blkIndent&&(m=!0),(h=ae(e,l))>=0){if(d=!0,s=e.bMarks[l]+e.tShift[l],u=Number(e.src.slice(s,h-1)),m&&1!==u)return!1}else{if(!((h=se(e,l))>=0))return!1;d=!1}if(m&&e.skipSpaces(h)>=e.eMarks[l])return!1;if(n)return!0;const p=e.src.charCodeAt(h-1),g=e.tokens.length;d?(a=e.push("ordered_list_open","ol",1),1!==u&&(a.attrs=[["start",u]])):a=e.push("bullet_list_open","ul",1);const f=[l,0];a.map=f,a.markup=String.fromCharCode(p);let b=!1;const k=e.md.block.ruler.getRules("list"),w=e.parentType;for(e.parentType="list";l=i?1:n-t,m>4&&(m=1);const g=t+m;a=e.push("list_item_open","li",1),a.markup=String.fromCharCode(p);const f=[l,0];a.map=f,d&&(a.info=e.src.slice(s,h-1));const w=e.tight,_=e.tShift[l],y=e.sCount[l],A=e.listIndent;if(e.listIndent=e.blkIndent,e.blkIndent=g,e.tight=!0,e.tShift[l]=u-e.bMarks[l],e.sCount[l]=n,u>=i&&e.isEmpty(l+1)?e.line=Math.min(e.line+2,o):e.md.block.tokenize(e,l,o,!0),e.tight&&!b||(c=!1),b=e.line-l>1&&e.isEmpty(e.line-1),e.blkIndent=e.listIndent,e.listIndent=A,e.tShift[l]=_,e.sCount[l]=y,e.tight=w,a=e.push("list_item_close","li",-1),a.markup=String.fromCharCode(p),l=e.line,f[1]=l,l>=o)break;if(e.sCount[l]=4)break;let C=!1;for(let t=0,n=k.length;t=4)return!1;if(91!==e.src.charCodeAt(i))return!1;function a(t){const o=e.lineMax;if(t>=o||e.isEmpty(t))return null;let n=!1;if(e.sCount[t]-e.blkIndent>3&&(n=!0),e.sCount[t]<0&&(n=!0),!n){const n=e.md.block.ruler.getRules("reference"),i=e.parentType;e.parentType="reference";let r=!1;for(let i=0,s=n.length;i=4)return!1;if(!e.md.options.html)return!1;if(60!==e.src.charCodeAt(i))return!1;let s=e.src.slice(i,r),a=0;for(;a=4)return!1;let s=e.src.charCodeAt(i);if(35!==s||i>=r)return!1;let a=1;for(s=e.src.charCodeAt(++i);35===s&&i6||ii&&D(e.src.charCodeAt(l-1))&&(r=l),e.line=t+1;const c=e.push("heading_open","h"+String(a),1);c.markup="########".slice(0,a),c.map=[t,e.line];const d=e.push("inline","",0);return d.content=e.src.slice(i,r).trim(),d.map=[t,e.line],d.children=[],e.push("heading_close","h"+String(a),-1).markup="########".slice(0,a),!0},["paragraph","reference","blockquote"]],["lheading",function(e,t,o){const n=e.md.block.ruler.getRules("paragraph");if(e.sCount[t]-e.blkIndent>=4)return!1;const i=e.parentType;e.parentType="paragraph";let r,s=0,a=t+1;for(;a3)continue;if(e.sCount[a]>=e.blkIndent){let t=e.bMarks[a]+e.tShift[a];const o=e.eMarks[a];if(t=o))){s=61===r?1:2;break}}if(e.sCount[a]<0)continue;let t=!1;for(let i=0,r=n.length;i3)continue;if(e.sCount[r]<0)continue;let t=!1;for(let i=0,s=n.length;i=o))&&!(e.sCount[s]=r){e.line=o;break}const t=e.line;let l=!1;for(let r=0;r=e.line)throw new Error("block rule didn't increment state.line");break}if(!l)throw new Error("none of the block rules matched");e.tight=!a,e.isEmpty(e.line-1)&&(a=!0),s=e.line,s0&&(this.level++,this._prev_delimiters.push(this.delimiters),this.delimiters=[],i={delimiters:this.delimiters}),this.pendingLevel=this.level,this.tokens.push(n),this.tokens_meta.push(i),n},ge.prototype.scanDelims=function(e,t){const o=this.posMax,n=this.src.charCodeAt(e),i=e>0?this.src.charCodeAt(e-1):32;let r=e;for(;r?@[]^_`{|}~-".split("").forEach((function(e){ke[e.charCodeAt(0)]=1}));var _e={tokenize:function(e,t){const o=e.pos,n=e.src.charCodeAt(o);if(t)return!1;if(126!==n)return!1;const i=e.scanDelims(e.pos,!0);let r=i.length;const s=String.fromCharCode(n);if(r<2)return!1;let a;r%2&&(a=e.push("text","",0),a.content=s,r--);for(let t=0;t=0;o--){const n=t[o];if(95!==n.marker&&42!==n.marker)continue;if(-1===n.end)continue;const i=t[n.end],r=o>0&&t[o-1].end===n.end+1&&t[o-1].marker===n.marker&&t[o-1].token===n.token-1&&t[n.end+1].token===i.token+1,s=String.fromCharCode(n.marker),a=e.tokens[n.token];a.type=r?"strong_open":"em_open",a.tag=r?"strong":"em",a.nesting=1,a.markup=r?s+s:s,a.content="";const l=e.tokens[i.token];l.type=r?"strong_close":"em_close",l.tag=r?"strong":"em",l.nesting=-1,l.markup=r?s+s:s,l.content="",r&&(e.tokens[t[o-1].token].content="",e.tokens[t[n.end+1].token].content="",o--)}}var Ae={tokenize:function(e,t){const o=e.pos,n=e.src.charCodeAt(o);if(t)return!1;if(95!==n&&42!==n)return!1;const i=e.scanDelims(e.pos,42===n);for(let t=0;t\x00-\x20]*)$/;const xe=/^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i,Ee=/^&([a-z][a-z0-9]{1,31});/i;function De(e){const t={},o=e.length;if(!o)return;let n=0,i=-2;const r=[];for(let s=0;sa;l-=r[l]+1){const t=e[l];if(t.marker===o.marker&&(t.open&&t.end<0)){let n=!1;if((t.close||o.open)&&(t.length+o.length)%3==0&&(t.length%3==0&&o.length%3==0||(n=!0)),!n){const n=l>0&&!e[l-1].open?r[l-1]+1:0;r[s]=s-l+n,r[l]=n,o.open=!1,t.end=s,t.close=!1,c=-1,i=-2;break}}}-1!==c&&(t[o.marker][(o.open?3:0)+(o.length||0)%3]=c)}}const Be=[["text",function(e,t){let o=e.pos;for(;o0)return!1;const o=e.pos;if(o+3>e.posMax)return!1;if(58!==e.src.charCodeAt(o))return!1;if(47!==e.src.charCodeAt(o+1))return!1;if(47!==e.src.charCodeAt(o+2))return!1;const n=e.pending.match(be);if(!n)return!1;const i=n[1],r=e.md.linkify.matchAtStart(e.src.slice(o-i.length));if(!r)return!1;let s=r.url;if(s.length<=i.length)return!1;s=s.replace(/\*+$/,"");const a=e.md.normalizeLink(s);if(!e.md.validateLink(a))return!1;if(!t){e.pending=e.pending.slice(0,-i.length);const t=e.push("link_open","a",1);t.attrs=[["href",a]],t.markup="linkify",t.info="auto";e.push("text","",0).content=e.md.normalizeLinkText(s);const o=e.push("link_close","a",-1);o.markup="linkify",o.info="auto"}return e.pos+=s.length-i.length,!0}],["newline",function(e,t){let o=e.pos;if(10!==e.src.charCodeAt(o))return!1;const n=e.pending.length-1,i=e.posMax;if(!t)if(n>=0&&32===e.pending.charCodeAt(n))if(n>=1&&32===e.pending.charCodeAt(n-1)){let t=n-1;for(;t>=1&&32===e.pending.charCodeAt(t-1);)t--;e.pending=e.pending.slice(0,t),e.push("hardbreak","br",0)}else e.pending=e.pending.slice(0,-1),e.push("softbreak","br",0);else e.push("softbreak","br",0);for(o++;o=n)return!1;let i=e.src.charCodeAt(o);if(10===i){for(t||e.push("hardbreak","br",0),o++;o=55296&&i<=56319&&o+1=56320&&t<=57343&&(r+=e.src[o+1],o++)}const s="\\"+r;if(!t){const t=e.push("text_special","",0);i<256&&0!==ke[i]?t.content=r:t.content=s,t.markup=s,t.info="escape"}return e.pos=o+1,!0}],["backticks",function(e,t){let o=e.pos;if(96!==e.src.charCodeAt(o))return!1;const n=o;o++;const i=e.posMax;for(;o=u)return!1;if(l=p,i=e.md.helpers.parseLinkDestination(e.src,p,e.posMax),i.ok){for(s=e.md.normalizeLink(i.str),e.md.validateLink(s)?p=i.pos:s="",l=p;p=u||41!==e.src.charCodeAt(p))&&(c=!0),p++}if(c){if(void 0===e.env.references)return!1;if(p=0?n=e.src.slice(l,p++):p=m+1):p=m+1,n||(n=e.src.slice(h,m)),r=e.env.references[I(n)],!r)return e.pos=d,!1;s=r.href,a=r.title}if(!t){e.pos=h,e.posMax=m;const t=[["href",s]];e.push("link_open","a",1).attrs=t,a&&t.push(["title",a]),e.linkLevel++,e.md.inline.tokenize(e),e.linkLevel--,e.push("link_close","a",-1)}return e.pos=p,e.posMax=u,!0}],["image",function(e,t){let o,n,i,r,s,a,l,c,d="";const u=e.pos,h=e.posMax;if(33!==e.src.charCodeAt(e.pos))return!1;if(91!==e.src.charCodeAt(e.pos+1))return!1;const m=e.pos+2,p=e.md.helpers.parseLinkLabel(e,e.pos+1,!1);if(p<0)return!1;if(r=p+1,r=h)return!1;for(c=r,a=e.md.helpers.parseLinkDestination(e.src,r,e.posMax),a.ok&&(d=e.md.normalizeLink(a.str),e.md.validateLink(d)?r=a.pos:d=""),c=r;r=h||41!==e.src.charCodeAt(r))return e.pos=u,!1;r++}else{if(void 0===e.env.references)return!1;if(r=0?i=e.src.slice(c,r++):r=p+1):r=p+1,i||(i=e.src.slice(m,p)),s=e.env.references[I(i)],!s)return e.pos=u,!1;d=s.href,l=s.title}if(!t){n=e.src.slice(m,p);const t=[];e.md.inline.parse(n,e.md,e.env,t);const o=e.push("image","img",0),i=[["src",d],["alt",""]];o.attrs=i,o.children=t,o.content=n,l&&i.push(["title",l])}return e.pos=r,e.posMax=h,!0}],["autolink",function(e,t){let o=e.pos;if(60!==e.src.charCodeAt(o))return!1;const n=e.pos,i=e.posMax;for(;;){if(++o>=i)return!1;const t=e.src.charCodeAt(o);if(60===t)return!1;if(62===t)break}const r=e.src.slice(n+1,o);if(ve.test(r)){const o=e.md.normalizeLink(r);if(!e.md.validateLink(o))return!1;if(!t){const t=e.push("link_open","a",1);t.attrs=[["href",o]],t.markup="autolink",t.info="auto";e.push("text","",0).content=e.md.normalizeLinkText(r);const n=e.push("link_close","a",-1);n.markup="autolink",n.info="auto"}return e.pos+=r.length+2,!0}if(Ce.test(r)){const o=e.md.normalizeLink("mailto:"+r);if(!e.md.validateLink(o))return!1;if(!t){const t=e.push("link_open","a",1);t.attrs=[["href",o]],t.markup="autolink",t.info="auto";e.push("text","",0).content=e.md.normalizeLinkText(r);const n=e.push("link_close","a",-1);n.markup="autolink",n.info="auto"}return e.pos+=r.length+2,!0}return!1}],["html_inline",function(e,t){if(!e.md.options.html)return!1;const o=e.posMax,n=e.pos;if(60!==e.src.charCodeAt(n)||n+2>=o)return!1;const i=e.src.charCodeAt(n+1);if(33!==i&&63!==i&&47!==i&&!function(e){const t=32|e;return t>=97&&t<=122}(i))return!1;const r=e.src.slice(n).match(de);if(!r)return!1;if(!t){const t=e.push("html_inline","",0);t.content=r[0],s=t.content,/^\s]/i.test(s)&&e.linkLevel++,function(e){return/^<\/a\s*>/i.test(e)}(t.content)&&e.linkLevel--}var s;return e.pos+=r[0].length,!0}],["entity",function(e,t){const o=e.pos,n=e.posMax;if(38!==e.src.charCodeAt(o))return!1;if(o+1>=n)return!1;if(35===e.src.charCodeAt(o+1)){const n=e.src.slice(o).match(xe);if(n){if(!t){const t="x"===n[1][0].toLowerCase()?parseInt(n[1].slice(1),16):parseInt(n[1],10),o=e.push("text_special","",0);o.content=g(t)?f(t):f(65533),o.markup=n[0],o.info="entity"}return e.pos+=n[0].length,!0}}else{const n=e.src.slice(o).match(Ee);if(n){const o=r.decodeHTML(n[0]);if(o!==n[0]){if(!t){const t=e.push("text_special","",0);t.content=o,t.markup=n[0],t.info="entity"}return e.pos+=n[0].length,!0}}}return!1}]],Se=[["balance_pairs",function(e){const t=e.tokens_meta,o=e.tokens_meta.length;De(e.delimiters);for(let e=0;e0&&n++,"text"===i[t].type&&t+1=e.pos)throw new Error("inline rule didn't increment state.pos");break}}else e.pos=e.posMax;s||e.pos++,r[t]=e.pos},Te.prototype.tokenize=function(e){const t=this.ruler.getRules(""),o=t.length,n=e.posMax,i=e.md.options.maxNesting;for(;e.pos=e.pos)throw new Error("inline rule didn't increment state.pos");break}if(s){if(e.pos>=n)break}else e.pending+=e.src[e.pos++]}e.pending&&e.pushPending()},Te.prototype.parse=function(e,t,o,n){const i=new this.State(e,t,o,n);this.tokenize(i);const r=this.ruler2.getRules(""),s=r.length;for(let e=0;e=0))try{t.hostname=a.toASCII(t.hostname)}catch(e){}return c.encode(c.format(t))}function Ve(e){const t=c.parse(e,!0);if(t.hostname&&(!t.protocol||Re.indexOf(t.protocol)>=0))try{t.hostname=a.toUnicode(t.hostname)}catch(e){}return c.decode(c.format(t),c.decode.defaultChars+"%")}function Oe(e,t){if(!(this instanceof Oe))return new Oe(e,t);t||u(e)||(t=e||{},e="default"),this.inline=new Te,this.block=new pe,this.core=new oe,this.renderer=new z,this.linkify=new s,this.validateLink=Me,this.normalizeLink=ze,this.normalizeLinkText=Ve,this.utils=F,this.helpers=m({},M),this.options={},this.configure(e),t&&this.set(t)}Oe.prototype.set=function(e){return m(this.options,e),this},Oe.prototype.configure=function(e){const t=this;if(u(e)){const t=e;if(!(e=Ie[t]))throw new Error('Wrong `markdown-it` preset "'+t+'", check name')}if(!e)throw new Error("Wrong `markdown-it` preset, can't be empty");return e.options&&t.set(e.options),e.components&&Object.keys(e.components).forEach((function(o){e.components[o].rules&&t[o].ruler.enableOnly(e.components[o].rules),e.components[o].rules2&&t[o].ruler2.enableOnly(e.components[o].rules2)})),this},Oe.prototype.enable=function(e,t){let o=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach((function(t){o=o.concat(this[t].ruler.enable(e,!0))}),this),o=o.concat(this.inline.ruler2.enable(e,!0));const n=e.filter((function(e){return o.indexOf(e)<0}));if(n.length&&!t)throw new Error("MarkdownIt. Failed to enable unknown rule(s): "+n);return this},Oe.prototype.disable=function(e,t){let o=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach((function(t){o=o.concat(this[t].ruler.disable(e,!0))}),this),o=o.concat(this.inline.ruler2.disable(e,!0));const n=e.filter((function(e){return o.indexOf(e)<0}));if(n.length&&!t)throw new Error("MarkdownIt. Failed to disable unknown rule(s): "+n);return this},Oe.prototype.use=function(e){const t=[this].concat(Array.prototype.slice.call(arguments,1));return e.apply(e,t),this},Oe.prototype.parse=function(e,t){if("string"!=typeof e)throw new Error("Input data should be a String");const o=new this.core.State(e,this,t);return this.core.process(o),o.tokens},Oe.prototype.render=function(e,t){return t=t||{},this.renderer.render(this.parse(e,t),this.options,t)},Oe.prototype.parseInline=function(e,t){const o=new this.core.State(e,this,t);return o.inlineMode=!0,this.core.process(o),o.tokens},Oe.prototype.renderInline=function(e,t){return t=t||{},this.renderer.render(this.parseInline(e,t),this.options,t)},e.exports=Oe},5778:(e,t)=>{"use strict";const o={};function n(e,t){"string"!=typeof t&&(t=n.defaultChars);const i=function(e){let t=o[e];if(t)return t;t=o[e]=[];for(let e=0;e<128;e++){const o=String.fromCharCode(e);t.push(o)}for(let o=0;o=55296&&e<=57343?"���":String.fromCharCode(e),o+=6;continue}}if(240==(248&r)&&o+91114111?t+="����":(e-=65536,t+=String.fromCharCode(55296+(e>>10),56320+(1023&e))),o+=9;continue}}t+="�"}}return t}))}n.defaultChars=";/?:@&=+$,#",n.componentChars="";const i={};function r(e,t,o){"string"!=typeof t&&(o=t,t=r.defaultChars),void 0===o&&(o=!0);const n=function(e){let t=i[e];if(t)return t;t=i[e]=[];for(let e=0;e<128;e++){const o=String.fromCharCode(e);/^[0-9a-z]$/i.test(o)?t.push(o):t.push("%"+("0"+e.toString(16).toUpperCase()).slice(-2))}for(let o=0;o=55296&&r<=57343){if(r>=55296&&r<=56319&&t+1=56320&&o<=57343){s+=encodeURIComponent(e[t]+e[t+1]),t++;continue}}s+="%EF%BF%BD"}else s+=encodeURIComponent(e[t])}return s}function s(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}r.defaultChars=";/?:@&=+$,-_.!~*'()#",r.componentChars="-_.!~*'()";const a=/^([a-z0-9.+-]+:)/i,l=/:[0-9]*$/,c=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,d=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),u=["'"].concat(d),h=["%","/","?",";","#"].concat(u),m=["/","?","#"],p=/^[+a-z0-9A-Z_-]{0,63}$/,g=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,f={javascript:!0,"javascript:":!0},b={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};s.prototype.parse=function(e,t){let o,n,i,r=e;if(r=r.trim(),!t&&1===e.split("#").length){const e=c.exec(r);if(e)return this.pathname=e[1],e[2]&&(this.search=e[2]),this}let s=a.exec(r);if(s&&(s=s[0],o=s.toLowerCase(),this.protocol=s,r=r.substr(s.length)),(t||s||r.match(/^\/\/[^@\/]+@[^@\/]+/))&&(i="//"===r.substr(0,2),!i||s&&f[s]||(r=r.substr(2),this.slashes=!0)),!f[s]&&(i||s&&!b[s])){let e,t,o=-1;for(let e=0;e127?n+="x":n+=o[e];if(!n.match(p)){const n=e.slice(0,t),i=e.slice(t+1),s=o.match(g);s&&(n.push(s[1]),i.unshift(s[2])),i.length&&(r=i.join(".")+r),this.hostname=n.join(".");break}}}}this.hostname.length>255&&(this.hostname=""),s&&(this.hostname=this.hostname.substr(1,this.hostname.length-2))}const l=r.indexOf("#");-1!==l&&(this.hash=r.substr(l),r=r.slice(0,l));const d=r.indexOf("?");return-1!==d&&(this.search=r.substr(d),r=r.slice(0,d)),r&&(this.pathname=r),b[o]&&this.hostname&&!this.pathname&&(this.pathname=""),this},s.prototype.parseHost=function(e){let t=l.exec(e);t&&(t=t[0],":"!==t&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)},t.decode=n,t.encode=r,t.format=function(e){let t="";return t+=e.protocol||"",t+=e.slashes?"//":"",t+=e.auth?e.auth+"@":"",e.hostname&&-1!==e.hostname.indexOf(":")?t+="["+e.hostname+"]":t+=e.hostname||"",t+=e.port?":"+e.port:"",t+=e.pathname||"",t+=e.search||"",t+=e.hash||"",t},t.parse=function(e,t){if(e&&e instanceof s)return e;const o=new s;return o.parse(e,t),o}},7444:(e,t,o)=>{"use strict";o.r(t),o.d(t,{decode:()=>b,default:()=>y,encode:()=>k,toASCII:()=>_,toUnicode:()=>w,ucs2decode:()=>m,ucs2encode:()=>p});const n=2147483647,i=36,r=/^xn--/,s=/[^\0-\x7F]/,a=/[\x2E\u3002\uFF0E\uFF61]/g,l={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},c=Math.floor,d=String.fromCharCode;function u(e){throw new RangeError(l[e])}function h(e,t){const o=e.split("@");let n="";o.length>1&&(n=o[0]+"@",e=o[1]);const i=function(e,t){const o=[];let n=e.length;for(;n--;)o[n]=t(e[n]);return o}((e=e.replace(a,".")).split("."),t).join(".");return n+i}function m(e){const t=[];let o=0;const n=e.length;for(;o=55296&&i<=56319&&oString.fromCodePoint(...e),g=function(e,t){return e+22+75*(e<26)-((0!=t)<<5)},f=function(e,t,o){let n=0;for(e=o?c(e/700):e>>1,e+=c(e/t);e>455;n+=i)e=c(e/35);return c(n+36*e/(e+38))},b=function(e){const t=[],o=e.length;let r=0,s=128,a=72,l=e.lastIndexOf("-");l<0&&(l=0);for(let o=0;o=128&&u("not-basic"),t.push(e.charCodeAt(o));for(let h=l>0?l+1:0;h=o&&u("invalid-input");const l=(d=e.charCodeAt(h++))>=48&&d<58?d-48+26:d>=65&&d<91?d-65:d>=97&&d<123?d-97:i;l>=i&&u("invalid-input"),l>c((n-r)/t)&&u("overflow"),r+=l*t;const m=s<=a?1:s>=a+26?26:s-a;if(lc(n/p)&&u("overflow"),t*=p}const m=t.length+1;a=f(r-l,m,0==l),c(r/m)>n-s&&u("overflow"),s+=c(r/m),r%=m,t.splice(r++,0,s)}var d;return String.fromCodePoint(...t)},k=function(e){const t=[],o=(e=m(e)).length;let r=128,s=0,a=72;for(const o of e)o<128&&t.push(d(o));const l=t.length;let h=l;for(l&&t.push("-");h=r&&tc((n-s)/m)&&u("overflow"),s+=(o-r)*m,r=o;for(const o of e)if(on&&u("overflow"),o===r){let e=s;for(let o=i;;o+=i){const n=o<=a?1:o>=a+26?26:o-a;if(e{"use strict";var t=[];function o(e){for(var o=-1,n=0;n{"use strict";var t={};e.exports=function(e,o){var n=function(e){if(void 0===t[e]){var o=document.querySelector(e);if(window.HTMLIFrameElement&&o instanceof window.HTMLIFrameElement)try{o=o.contentDocument.head}catch(e){o=null}t[e]=o}return t[e]}(e);if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");n.appendChild(o)}},540:e=>{"use strict";e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},4868:e=>{"use strict";e.exports=function(e,t){Object.keys(t).forEach((function(o){e.setAttribute(o,t[o])}))}},4284:e=>{"use strict";var t,o=(t=[],function(e,o){return t[e]=o,t.filter(Boolean).join("\n")});function n(e,t,n,i){var r;if(n)r="";else{r="",i.supports&&(r+="@supports (".concat(i.supports,") {")),i.media&&(r+="@media ".concat(i.media," {"));var s=void 0!==i.layer;s&&(r+="@layer".concat(i.layer.length>0?" ".concat(i.layer):""," {")),r+=i.css,s&&(r+="}"),i.media&&(r+="}"),i.supports&&(r+="}")}if(e.styleSheet)e.styleSheet.cssText=o(t,r);else{var a=document.createTextNode(r),l=e.childNodes;l[t]&&e.removeChild(l[t]),l.length?e.insertBefore(a,l[t]):e.appendChild(a)}}var i={singleton:null,singletonCounter:0};e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=i.singletonCounter++,o=i.singleton||(i.singleton=e.insertStyleElement(e));return{update:function(e){n(o,t,!1,e)},remove:function(e){n(o,t,!0,e)}}}},3492:(e,t)=>{"use strict";t.Any=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,t.Cc=/[\0-\x1F\x7F-\x9F]/,t.Cf=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u0890\u0891\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD80D[\uDC30-\uDC3F]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/,t.P=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1B7D\u1B7E\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDEAD\uDF55-\uDF59\uDF86-\uDF89]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDC4B-\uDC4F\uDC5A\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDEB9\uDF3C-\uDF3E]|\uD806[\uDC3B\uDD44-\uDD46\uDDE2\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2\uDF00-\uDF09]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8\uDF43-\uDF4F\uDFFF]|\uD809[\uDC70-\uDC74]|\uD80B[\uDFF1\uDFF2]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDE97-\uDE9A\uDFE2]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD83A[\uDD5E\uDD5F]/,t.S=/[\$\+<->\^`\|~\xA2-\xA6\xA8\xA9\xAC\xAE-\xB1\xB4\xB8\xD7\xF7\u02C2-\u02C5\u02D2-\u02DF\u02E5-\u02EB\u02ED\u02EF-\u02FF\u0375\u0384\u0385\u03F6\u0482\u058D-\u058F\u0606-\u0608\u060B\u060E\u060F\u06DE\u06E9\u06FD\u06FE\u07F6\u07FE\u07FF\u0888\u09F2\u09F3\u09FA\u09FB\u0AF1\u0B70\u0BF3-\u0BFA\u0C7F\u0D4F\u0D79\u0E3F\u0F01-\u0F03\u0F13\u0F15-\u0F17\u0F1A-\u0F1F\u0F34\u0F36\u0F38\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE\u0FCF\u0FD5-\u0FD8\u109E\u109F\u1390-\u1399\u166D\u17DB\u1940\u19DE-\u19FF\u1B61-\u1B6A\u1B74-\u1B7C\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u2044\u2052\u207A-\u207C\u208A-\u208C\u20A0-\u20C0\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u214F\u218A\u218B\u2190-\u2307\u230C-\u2328\u232B-\u2426\u2440-\u244A\u249C-\u24E9\u2500-\u2767\u2794-\u27C4\u27C7-\u27E5\u27F0-\u2982\u2999-\u29D7\u29DC-\u29FB\u29FE-\u2B73\u2B76-\u2B95\u2B97-\u2BFF\u2CE5-\u2CEA\u2E50\u2E51\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3004\u3012\u3013\u3020\u3036\u3037\u303E\u303F\u309B\u309C\u3190\u3191\u3196-\u319F\u31C0-\u31E3\u31EF\u3200-\u321E\u322A-\u3247\u3250\u3260-\u327F\u328A-\u32B0\u32C0-\u33FF\u4DC0-\u4DFF\uA490-\uA4C6\uA700-\uA716\uA720\uA721\uA789\uA78A\uA828-\uA82B\uA836-\uA839\uAA77-\uAA79\uAB5B\uAB6A\uAB6B\uFB29\uFBB2-\uFBC2\uFD40-\uFD4F\uFDCF\uFDFC-\uFDFF\uFE62\uFE64-\uFE66\uFE69\uFF04\uFF0B\uFF1C-\uFF1E\uFF3E\uFF40\uFF5C\uFF5E\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFFC\uFFFD]|\uD800[\uDD37-\uDD3F\uDD79-\uDD89\uDD8C-\uDD8E\uDD90-\uDD9C\uDDA0\uDDD0-\uDDFC]|\uD802[\uDC77\uDC78\uDEC8]|\uD805\uDF3F|\uD807[\uDFD5-\uDFF1]|\uD81A[\uDF3C-\uDF3F\uDF45]|\uD82F\uDC9C|\uD833[\uDF50-\uDFC3]|\uD834[\uDC00-\uDCF5\uDD00-\uDD26\uDD29-\uDD64\uDD6A-\uDD6C\uDD83\uDD84\uDD8C-\uDDA9\uDDAE-\uDDEA\uDE00-\uDE41\uDE45\uDF00-\uDF56]|\uD835[\uDEC1\uDEDB\uDEFB\uDF15\uDF35\uDF4F\uDF6F\uDF89\uDFA9\uDFC3]|\uD836[\uDC00-\uDDFF\uDE37-\uDE3A\uDE6D-\uDE74\uDE76-\uDE83\uDE85\uDE86]|\uD838[\uDD4F\uDEFF]|\uD83B[\uDCAC\uDCB0\uDD2E\uDEF0\uDEF1]|\uD83C[\uDC00-\uDC2B\uDC30-\uDC93\uDCA0-\uDCAE\uDCB1-\uDCBF\uDCC1-\uDCCF\uDCD1-\uDCF5\uDD0D-\uDDAD\uDDE6-\uDE02\uDE10-\uDE3B\uDE40-\uDE48\uDE50\uDE51\uDE60-\uDE65\uDF00-\uDFFF]|\uD83D[\uDC00-\uDED7\uDEDC-\uDEEC\uDEF0-\uDEFC\uDF00-\uDF76\uDF7B-\uDFD9\uDFE0-\uDFEB\uDFF0]|\uD83E[\uDC00-\uDC0B\uDC10-\uDC47\uDC50-\uDC59\uDC60-\uDC87\uDC90-\uDCAD\uDCB0\uDCB1\uDD00-\uDE53\uDE60-\uDE6D\uDE70-\uDE7C\uDE80-\uDE88\uDE90-\uDEBD\uDEBF-\uDEC5\uDECE-\uDEDB\uDEE0-\uDEE8\uDEF0-\uDEF8\uDF00-\uDF92\uDF94-\uDFCA]/,t.Z=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/},2401:e=>{"use strict";e.exports="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAyMCI+PHBhdGggZmlsbD0iI2ZmZiIgZD0ibTExLjA3NyAxNSAuOTkxLTEuNDE2YS43NS43NSAwIDEgMSAxLjIyOS44NmwtMS4xNDggMS42NGEuNzUuNzUgMCAwIDEtLjIxNy4yMDYgNS4yNTEgNS4yNTEgMCAwIDEtOC41MDMtNS45NTUuNy43IDAgMCAxIC4xMi0uMjc0bDEuMTQ3LTEuNjM5YS43NS43NSAwIDEgMSAxLjIyOC44Nkw0LjkzMyAxMC43bC4wMDYuMDAzYTMuNzUgMy43NSAwIDAgMCA2LjEzMiA0LjI5NHptNS40OTQtNS4zMzVhLjc1Ljc1IDAgMCAxLS4xMi4yNzRsLTEuMTQ3IDEuNjM5YS43NS43NSAwIDEgMS0xLjIyOC0uODZsLjg2LTEuMjNhMy43NSAzLjc1IDAgMCAwLTYuMTQ0LTQuMzAxbC0uODYgMS4yMjlhLjc1Ljc1IDAgMCAxLTEuMjI5LS44NmwxLjE0OC0xLjY0YS43NS43NSAwIDAgMSAuMjE3LS4yMDYgNS4yNTEgNS4yNTEgMCAwIDEgOC41MDMgNS45NTVtLTQuNTYzLTIuNTMyYS43NS43NSAwIDAgMSAuMTg0IDEuMDQ1bC0zLjE1NSA0LjUwNWEuNzUuNzUgMCAxIDEtMS4yMjktLjg2bDMuMTU1LTQuNTA2YS43NS43NSAwIDAgMSAxLjA0NS0uMTg0Ii8+PC9zdmc+"}},n={};function i(e){var t=n[e];if(void 0!==t)return t.exports;var r=n[e]={id:e,exports:{}};return o[e].call(r.exports,r,r.exports,i),r.exports}i.m=o,i.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return i.d(t,{a:t}),t},t=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,i.t=function(o,n){if(1&n&&(o=this(o)),8&n)return o;if("object"==typeof o&&o){if(4&n&&o.__esModule)return o;if(16&n&&"function"==typeof o.then)return o}var r=Object.create(null);i.r(r);var s={};e=e||[null,t({}),t([]),t(t)];for(var a=2&n&&o;"object"==typeof a&&!~e.indexOf(a);a=t(a))Object.getOwnPropertyNames(a).forEach((e=>s[e]=()=>o[e]));return s.default=()=>o,i.d(r,s),r},i.d=(e,t)=>{for(var o in t)i.o(t,o)&&!i.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},i.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.b=document.baseURI||self.location.href;var r={};return(()=>{"use strict";let e;try{e={window,document}}catch(t){e={window:{},document:{}}}const t=e;function o(){try{return navigator.userAgent.toLowerCase()}catch(e){return""}}const n=o(),r={isMac:s(n),isWindows:a(n),isGecko:l(n),isSafari:c(n),isiOS:d(n),isAndroid:u(n),isBlink:h(n),get isMediaForcedColors(){return!!t.window.matchMedia&&t.window.matchMedia("(forced-colors: active)").matches},get isMotionReduced(){return!!t.window.matchMedia&&t.window.matchMedia("(prefers-reduced-motion)").matches},features:{isRegExpUnicodePropertySupported:m()}};function s(e){return e.indexOf("macintosh")>-1}function a(e){return e.indexOf("windows")>-1}function l(e){return!!e.match(/gecko\/\d+/)}function c(e){return e.indexOf(" applewebkit/")>-1&&-1===e.indexOf("chrome")}function d(e){return!!e.match(/iphone|ipad/i)||s(e)&&navigator.maxTouchPoints>0}function u(e){return e.indexOf("android")>-1}function h(e){return e.indexOf("chrome/")>-1&&e.indexOf("edge/")<0}function m(){let e=!1;try{e=0==="ć".search(new RegExp("[\\p{L}]","u"))}catch(e){}return e}function p(e,t,o,n){o=o||function(e,t){return e===t};const i=Array.isArray(e)?e:Array.prototype.slice.call(e),r=Array.isArray(t)?t:Array.prototype.slice.call(t),s=function(e,t,o){const n=g(e,t,o);if(-1===n)return{firstIndex:-1,lastIndexOld:-1,lastIndexNew:-1};const i=f(e,n),r=f(t,n),s=g(i,r,o),a=e.length-s,l=t.length-s;return{firstIndex:n,lastIndexOld:a,lastIndexNew:l}}(i,r,o),a=n?function(e,t){const{firstIndex:o,lastIndexOld:n,lastIndexNew:i}=e;if(-1===o)return Array(t).fill("equal");let r=[];o>0&&(r=r.concat(Array(o).fill("equal")));i-o>0&&(r=r.concat(Array(i-o).fill("insert")));n-o>0&&(r=r.concat(Array(n-o).fill("delete")));i0&&o.push({index:n,type:"insert",values:e.slice(n,r)});i-n>0&&o.push({index:n+(r-n),type:"delete",howMany:i-n});return o}(r,s);return a}function g(e,t,o){for(let n=0;n200||i>200||n+i>300)return b.fastDiff(e,t,o,!0);let r,s;if(ic?-1:1;d[n+h]&&(d[n]=d[n+h].slice(0)),d[n]||(d[n]=[]),d[n].push(i>c?r:s);let m=Math.max(i,c),p=m-n;for(;pc;m--)u[m]=h(m);u[c]=h(c),p++}while(u[c]!==l);return d[c].slice(1)}b.fastDiff=p;const k=function(){return function e(){e.called=!0}};class w{constructor(e,t){this.source=e,this.name=t,this.path=[],this.stop=k(),this.off=k()}}const y=new Array(256).fill("").map(((e,t)=>("0"+t.toString(16)).slice(-2)));function A(){const e=4294967296*Math.random()>>>0,t=4294967296*Math.random()>>>0,o=4294967296*Math.random()>>>0,n=4294967296*Math.random()>>>0;return"e"+y[e>>0&255]+y[e>>8&255]+y[e>>16&255]+y[e>>24&255]+y[t>>0&255]+y[t>>8&255]+y[t>>16&255]+y[t>>24&255]+y[o>>0&255]+y[o>>8&255]+y[o>>16&255]+y[o>>24&255]+y[n>>0&255]+y[n>>8&255]+y[n>>16&255]+y[n>>24&255]}const C={get(e="normal"){return"number"!=typeof e?this[e]||this.normal:e},highest:1e5,high:1e3,normal:0,low:-1e3,lowest:-1e5};function v(e,t){const o=C.get(t.priority);for(let n=0;n{if("object"==typeof t&&null!==t){if(o.has(t))return`[object ${t.constructor.name}]`;o.add(t)}return t},i=t?` ${JSON.stringify(t,n)}`:"",r=B(e);return e+i+r}(e,o)),this.name="CKEditorError",this.context=t,this.data=o}is(e){return"CKEditorError"===e}static rethrowUnexpectedError(e,t){if(e.is&&e.is("CKEditorError"))throw e;const o=new E(e.message,t);throw o.stack=e.stack,o}}function D(e,t){console.warn(...S(e,t))}function B(e){return`\nRead more: ${x}#error-${e}`}function S(e,t){const o=B(e);return t?[e,t,o]:[e,o]}const T="43.0.0",I=new Date(2024,7,7);if(globalThis.CKEDITOR_VERSION)throw new E("ckeditor-duplicated-modules",null);globalThis.CKEDITOR_VERSION=T;const P=Symbol("listeningTo"),F=Symbol("emitterId"),M=Symbol("delegations"),R=z(Object);function z(e){if(!e)return R;return class extends e{on(e,t,o){this.listenTo(this,e,t,o)}once(e,t,o){let n=!1;this.listenTo(this,e,((e,...o)=>{n||(n=!0,e.off(),t.call(this,e,...o))}),o)}off(e,t){this.stopListening(this,e,t)}listenTo(e,t,o,n={}){let i,r;this[P]||(this[P]={});const s=this[P];O(e)||V(e);const a=O(e);(i=s[a])||(i=s[a]={emitter:e,callbacks:{}}),(r=i.callbacks[t])||(r=i.callbacks[t]=[]),r.push(o),function(e,t,o,n,i){t._addEventListener?t._addEventListener(o,n,i):e._addEventListener.call(t,o,n,i)}(this,e,t,o,n)}stopListening(e,t,o){const n=this[P];let i=e&&O(e);const r=n&&i?n[i]:void 0,s=r&&t?r.callbacks[t]:void 0;if(!(!n||e&&!r||t&&!s))if(o){q(this,e,t,o);-1!==s.indexOf(o)&&(1===s.length?delete r.callbacks[t]:q(this,e,t,o))}else if(s){for(;o=s.pop();)q(this,e,t,o);delete r.callbacks[t]}else if(r){for(t in r.callbacks)this.stopListening(e,t);delete n[i]}else{for(i in n)this.stopListening(n[i].emitter);delete this[P]}}fire(e,...t){try{const o=e instanceof w?e:new w(this,e),n=o.name;let i=H(this,n);if(o.path.push(this),i){const e=[o,...t];i=Array.from(i);for(let t=0;t{this[M]||(this[M]=new Map),e.forEach((e=>{const n=this[M].get(e);n?n.set(t,o):this[M].set(e,new Map([[t,o]]))}))}}}stopDelegating(e,t){if(this[M])if(e)if(t){const o=this[M].get(e);o&&o.delete(t)}else this[M].delete(e);else this[M].clear()}_addEventListener(e,t,o){!function(e,t){const o=N(e);if(o[t])return;let n=t,i=null;const r=[];for(;""!==n&&!o[n];)o[n]={callbacks:[],childEvents:[]},r.push(o[n]),i&&o[n].childEvents.push(i),i=n,n=n.substr(0,n.lastIndexOf(":"));if(""!==n){for(const e of r)e.callbacks=o[n].callbacks.slice();o[n].childEvents.push(i)}}(this,e);const n=L(this,e),i={callback:t,priority:C.get(o.priority)};for(const e of n)v(e,i)}_removeEventListener(e,t){const o=L(this,e);for(const e of o)for(let o=0;o-1?H(e,t.substr(0,t.lastIndexOf(":"))):null}function j(e,t,o){for(let[n,i]of e){i?"function"==typeof i&&(i=i(t.name)):i=t.name;const e=new w(t.source,i);e.path=[...t.path],n.fire(e,...o)}}function q(e,t,o,n){t._removeEventListener?t._removeEventListener(o,n):e._removeEventListener.call(t,o,n)}["on","once","off","listenTo","stopListening","fire","delegate","stopDelegating","_addEventListener","_removeEventListener"].forEach((e=>{z[e]=R.prototype[e]}));const U=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)},W=Symbol("observableProperties"),$=Symbol("boundObservables"),G=Symbol("boundProperties"),K=Symbol("decoratedMethods"),Z=Symbol("decoratedOriginal"),J=Y(z());function Y(e){if(!e)return J;return class extends e{set(e,t){if(U(e))return void Object.keys(e).forEach((t=>{this.set(t,e[t])}),this);Q(this);const o=this[W];if(e in this&&!o.has(e))throw new E("observable-set-cannot-override",this);Object.defineProperty(this,e,{enumerable:!0,configurable:!0,get:()=>o.get(e),set(t){const n=o.get(e);let i=this.fire(`set:${e}`,e,t,n);void 0===i&&(i=t),n===i&&o.has(e)||(o.set(e,i),this.fire(`change:${e}`,e,i,n))}}),this[e]=t}bind(...e){if(!e.length||!te(e))throw new E("observable-bind-wrong-properties",this);if(new Set(e).size!==e.length)throw new E("observable-bind-duplicate-properties",this);Q(this);const t=this[G];e.forEach((e=>{if(t.has(e))throw new E("observable-bind-rebind",this)}));const o=new Map;return e.forEach((e=>{const n={property:e,to:[]};t.set(e,n),o.set(e,n)})),{to:X,toMany:ee,_observable:this,_bindProperties:e,_to:[],_bindings:o}}unbind(...e){if(!this[W])return;const t=this[G],o=this[$];if(e.length){if(!te(e))throw new E("observable-unbind-wrong-properties",this);e.forEach((e=>{const n=t.get(e);n&&(n.to.forEach((([e,t])=>{const i=o.get(e),r=i[t];r.delete(n),r.size||delete i[t],Object.keys(i).length||(o.delete(e),this.stopListening(e,"change"))})),t.delete(e))}))}else o.forEach(((e,t)=>{this.stopListening(t,"change")})),o.clear(),t.clear()}decorate(e){Q(this);const t=this[e];if(!t)throw new E("observablemixin-cannot-decorate-undefined",this,{object:this,methodName:e});this.on(e,((e,o)=>{e.return=t.apply(this,o)})),this[e]=function(...t){return this.fire(e,t)},this[e][Z]=t,this[K]||(this[K]=[]),this[K].push(e)}stopListening(e,t,o){if(!e&&this[K]){for(const e of this[K])this[e]=this[e][Z];delete this[K]}super.stopListening(e,t,o)}}}function Q(e){e[W]||(Object.defineProperty(e,W,{value:new Map}),Object.defineProperty(e,$,{value:new Map}),Object.defineProperty(e,G,{value:new Map}))}function X(...e){const t=function(...e){if(!e.length)throw new E("observable-bind-to-parse-error",null);const t={to:[]};let o;"function"==typeof e[e.length-1]&&(t.callback=e.pop());return e.forEach((e=>{if("string"==typeof e)o.properties.push(e);else{if("object"!=typeof e)throw new E("observable-bind-to-parse-error",null);o={observable:e,properties:[]},t.to.push(o)}})),t}(...e),o=Array.from(this._bindings.keys()),n=o.length;if(!t.callback&&t.to.length>1)throw new E("observable-bind-to-no-callback",this);if(n>1&&t.callback)throw new E("observable-bind-to-extra-callback",this);var i;t.to.forEach((e=>{if(e.properties.length&&e.properties.length!==n)throw new E("observable-bind-to-properties-length",this);e.properties.length||(e.properties=this._bindProperties)})),this._to=t.to,t.callback&&(this._bindings.get(o[0]).callback=t.callback),i=this._observable,this._to.forEach((e=>{const t=i[$];let o;t.get(e.observable)||i.listenTo(e.observable,"change",((n,r)=>{o=t.get(e.observable)[r],o&&o.forEach((e=>{oe(i,e.property)}))}))})),function(e){let t;e._bindings.forEach(((o,n)=>{e._to.forEach((i=>{t=i.properties[o.callback?0:e._bindProperties.indexOf(n)],o.to.push([i.observable,t]),function(e,t,o,n){const i=e[$],r=i.get(o),s=r||{};s[n]||(s[n]=new Set);s[n].add(t),r||i.set(o,s)}(e._observable,o,i.observable,t)}))}))}(this),this._bindProperties.forEach((e=>{oe(this._observable,e)}))}function ee(e,t,o){if(this._bindings.size>1)throw new E("observable-bind-to-many-not-one-binding",this);this.to(...function(e,t){const o=e.map((e=>[e,t]));return Array.prototype.concat.apply([],o)}(e,t),o)}function te(e){return e.every((e=>"string"==typeof e))}function oe(e,t){const o=e[G].get(t);let n;o.callback?n=o.callback.apply(e,o.to.map((e=>e[0][e[1]]))):(n=o.to[0],n=n[0][n[1]]),Object.prototype.hasOwnProperty.call(e,t)?e[t]=n:e.set(t,n)}function ne(e){let t=0;for(const o of e)t++;return t}function ie(e,t){const o=Math.min(e.length,t.length);for(let n=0;n{Y[e]=J.prototype[e]}));const se="object"==typeof global&&global&&global.Object===Object&&global;var ae="object"==typeof self&&self&&self.Object===Object&&self;const le=se||ae||Function("return this")();const ce=le.Symbol;var de=Object.prototype,ue=de.hasOwnProperty,he=de.toString,me=ce?ce.toStringTag:void 0;const pe=function(e){var t=ue.call(e,me),o=e[me];try{e[me]=void 0;var n=!0}catch(e){}var i=he.call(e);return n&&(t?e[me]=o:delete e[me]),i};var ge=Object.prototype.toString;const fe=function(e){return ge.call(e)};var be=ce?ce.toStringTag:void 0;const ke=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":be&&be in Object(e)?pe(e):fe(e)};const we=Array.isArray;const _e=function(e){return null!=e&&"object"==typeof e};const ye=function(e){return"string"==typeof e||!we(e)&&_e(e)&&"[object String]"==ke(e)};function Ae(e,t,o={},n=[]){const i=o&&o.xmlns,r=i?e.createElementNS(i,t):e.createElement(t);for(const e in o)r.setAttribute(e,o[e]);!ye(n)&&re(n)||(n=[n]);for(let t of n)ye(t)&&(t=e.createTextNode(t)),r.appendChild(t);return r}const Ce=function(e,t){return function(o){return e(t(o))}};const ve=Ce(Object.getPrototypeOf,Object);var xe=Function.prototype,Ee=Object.prototype,De=xe.toString,Be=Ee.hasOwnProperty,Se=De.call(Object);const Te=function(e){if(!_e(e)||"[object Object]"!=ke(e))return!1;var t=ve(e);if(null===t)return!0;var o=Be.call(t,"constructor")&&t.constructor;return"function"==typeof o&&o instanceof o&&De.call(o)==Se};const Ie=function(){this.__data__=[],this.size=0};const Pe=function(e,t){return e===t||e!=e&&t!=t};const Fe=function(e,t){for(var o=e.length;o--;)if(Pe(e[o][0],t))return o;return-1};var Me=Array.prototype.splice;const Re=function(e){var t=this.__data__,o=Fe(t,e);return!(o<0)&&(o==t.length-1?t.pop():Me.call(t,o,1),--this.size,!0)};const ze=function(e){var t=this.__data__,o=Fe(t,e);return o<0?void 0:t[o][1]};const Ve=function(e){return Fe(this.__data__,e)>-1};const Oe=function(e,t){var o=this.__data__,n=Fe(o,e);return n<0?(++this.size,o.push([e,t])):o[n][1]=t,this};function Ne(e){var t=-1,o=null==e?0:e.length;for(this.clear();++t-1&&e%1==0&&e-1&&e%1==0&&e<=9007199254740991};var Zt={};Zt["[object Float32Array]"]=Zt["[object Float64Array]"]=Zt["[object Int8Array]"]=Zt["[object Int16Array]"]=Zt["[object Int32Array]"]=Zt["[object Uint8Array]"]=Zt["[object Uint8ClampedArray]"]=Zt["[object Uint16Array]"]=Zt["[object Uint32Array]"]=!0,Zt["[object Arguments]"]=Zt["[object Array]"]=Zt["[object ArrayBuffer]"]=Zt["[object Boolean]"]=Zt["[object DataView]"]=Zt["[object Date]"]=Zt["[object Error]"]=Zt["[object Function]"]=Zt["[object Map]"]=Zt["[object Number]"]=Zt["[object Object]"]=Zt["[object RegExp]"]=Zt["[object Set]"]=Zt["[object String]"]=Zt["[object WeakMap]"]=!1;const Jt=function(e){return _e(e)&&Kt(e.length)&&!!Zt[ke(e)]};const Yt=function(e){return function(t){return e(t)}};var Qt="object"==typeof exports&&exports&&!exports.nodeType&&exports,Xt=Qt&&"object"==typeof module&&module&&!module.nodeType&&module,eo=Xt&&Xt.exports===Qt&&se.process;const to=function(){try{var e=Xt&&Xt.require&&Xt.require("util").types;return e||eo&&eo.binding&&eo.binding("util")}catch(e){}}();var oo=to&&to.isTypedArray;const no=oo?Yt(oo):Jt;var io=Object.prototype.hasOwnProperty;const ro=function(e,t){var o=we(e),n=!o&&Lt(e),i=!o&&!n&&Wt(e),r=!o&&!n&&!i&&no(e),s=o||n||i||r,a=s?Rt(e.length,String):[],l=a.length;for(var c in e)!t&&!io.call(e,c)||s&&("length"==c||i&&("offset"==c||"parent"==c)||r&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||Gt(c,l))||a.push(c);return a};var so=Object.prototype;const ao=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||so)};const lo=Ce(Object.keys,Object);var co=Object.prototype.hasOwnProperty;const uo=function(e){if(!ao(e))return lo(e);var t=[];for(var o in Object(e))co.call(e,o)&&"constructor"!=o&&t.push(o);return t};const ho=function(e){return null!=e&&Kt(e.length)&&!We(e)};const mo=function(e){return ho(e)?ro(e):uo(e)};const po=function(e,t){return e&&Mt(t,mo(t),e)};const go=function(e){var t=[];if(null!=e)for(var o in Object(e))t.push(o);return t};var fo=Object.prototype.hasOwnProperty;const bo=function(e){if(!U(e))return go(e);var t=ao(e),o=[];for(var n in e)("constructor"!=n||!t&&fo.call(e,n))&&o.push(n);return o};const ko=function(e){return ho(e)?ro(e,!0):bo(e)};const wo=function(e,t){return e&&Mt(t,ko(t),e)};var _o="object"==typeof exports&&exports&&!exports.nodeType&&exports,yo=_o&&"object"==typeof module&&module&&!module.nodeType&&module,Ao=yo&&yo.exports===_o?le.Buffer:void 0,Co=Ao?Ao.allocUnsafe:void 0;const vo=function(e,t){if(t)return e.slice();var o=e.length,n=Co?Co(o):new e.constructor(o);return e.copy(n),n};const xo=function(e,t){var o=-1,n=e.length;for(t||(t=Array(n));++o{this._setToTarget(e,n,t[n],o)}))}}function Tn(e){return Dn(e,In)}function In(e){return Bn(e)||"function"==typeof e?e:void 0}function Pn(e){if(e){if(e.defaultView)return e instanceof e.defaultView.Document;if(e.ownerDocument&&e.ownerDocument.defaultView)return e instanceof e.ownerDocument.defaultView.Node}return!1}function Fn(e){const t=Object.prototype.toString.apply(e);return"[object Window]"==t||"[object global]"==t}const Mn=Rn(z());function Rn(e){if(!e)return Mn;return class extends e{listenTo(e,t,o,n={}){if(Pn(e)||Fn(e)){const i={capture:!!n.useCapture,passive:!!n.usePassive},r=this._getProxyEmitter(e,i)||new zn(e,i);this.listenTo(r,t,o,n)}else super.listenTo(e,t,o,n)}stopListening(e,t,o){if(Pn(e)||Fn(e)){const n=this._getAllProxyEmitters(e);for(const e of n)this.stopListening(e,t,o)}else super.stopListening(e,t,o)}_getProxyEmitter(e,t){return function(e,t){const o=e[P];return o&&o[t]?o[t].emitter:null}(this,Vn(e,t))}_getAllProxyEmitters(e){return[{capture:!1,passive:!1},{capture:!1,passive:!0},{capture:!0,passive:!1},{capture:!0,passive:!0}].map((t=>this._getProxyEmitter(e,t))).filter((e=>!!e))}}}["_getProxyEmitter","_getAllProxyEmitters","on","once","off","listenTo","stopListening","fire","delegate","stopDelegating","_addEventListener","_removeEventListener"].forEach((e=>{Rn[e]=Mn.prototype[e]}));class zn extends(z()){constructor(e,t){super(),V(this,Vn(e,t)),this._domNode=e,this._options=t}attach(e){if(this._domListeners&&this._domListeners[e])return;const t=this._createDomListener(e);this._domNode.addEventListener(e,t,this._options),this._domListeners||(this._domListeners={}),this._domListeners[e]=t}detach(e){let t;!this._domListeners[e]||(t=this._events[e])&&t.callbacks.length||this._domListeners[e].removeListener()}_addEventListener(e,t,o){this.attach(e),z().prototype._addEventListener.call(this,e,t,o)}_removeEventListener(e,t){z().prototype._removeEventListener.call(this,e,t),this.detach(e)}_createDomListener(e){const t=t=>{this.fire(e,t)};return t.removeListener=()=>{this._domNode.removeEventListener(e,t,this._options),delete this._domListeners[e]},t}}function Vn(e,t){let o=function(e){return e["data-ck-expando"]||(e["data-ck-expando"]=A())}(e);for(const e of Object.keys(t).sort())t[e]&&(o+="-"+e);return o}function On(e){const t=e.ownerDocument.defaultView.getComputedStyle(e);return{top:parseInt(t.borderTopWidth,10),right:parseInt(t.borderRightWidth,10),bottom:parseInt(t.borderBottomWidth,10),left:parseInt(t.borderLeftWidth,10)}}function Nn(e){return"[object Text]"==Object.prototype.toString.call(e)}function Ln(e){return"[object Range]"==Object.prototype.toString.apply(e)}function Hn(e){return e&&e.parentNode?e.offsetParent===t.document.body?null:e.offsetParent:null}const jn=["top","right","bottom","left","width","height"];class qn{constructor(e){const t=Ln(e);if(Object.defineProperty(this,"_source",{value:e._source||e,writable:!0,enumerable:!1}),$n(e)||t)if(t){const t=qn.getDomRangeRects(e);Un(this,qn.getBoundingRect(t))}else Un(this,e.getBoundingClientRect());else if(Fn(e)){const{innerWidth:t,innerHeight:o}=e;Un(this,{top:0,right:t,bottom:o,left:0,width:t,height:o})}else Un(this,e)}clone(){return new qn(this)}moveTo(e,t){return this.top=t,this.right=e+this.width,this.bottom=t+this.height,this.left=e,this}moveBy(e,t){return this.top+=t,this.right+=e,this.left+=e,this.bottom+=t,this}getIntersection(e){const t={top:Math.max(this.top,e.top),right:Math.min(this.right,e.right),bottom:Math.min(this.bottom,e.bottom),left:Math.max(this.left,e.left),width:0,height:0};if(t.width=t.right-t.left,t.height=t.bottom-t.top,t.width<0||t.height<0)return null;{const e=new qn(t);return e._source=this._source,e}}getIntersectionArea(e){const t=this.getIntersection(e);return t?t.getArea():0}getArea(){return this.width*this.height}getVisible(){const e=this._source;let t=this.clone();if(Wn(e))return t;let o,n=e,i=e.parentNode||e.commonAncestorContainer;for(;i&&!Wn(i);){const e="visible"===((r=i)instanceof HTMLElement?r.ownerDocument.defaultView.getComputedStyle(r).overflow:"visible");n instanceof HTMLElement&&"absolute"===Gn(n)&&(o=n);const s=Gn(i);if(e||o&&("relative"===s&&e||"relative"!==s)){n=i,i=i.parentNode;continue}const a=new qn(i),l=t.getIntersection(a);if(!l)return null;l.getArea(){for(const t of e){const e=Kn._getElementCallbacks(t.target);if(e)for(const o of e)o(t)}}))}}Kn._observerInstance=null,Kn._elementCallbacks=null;const Zn=Kn;function Jn(e,t){e instanceof HTMLTextAreaElement&&(e.value=t),e.innerHTML=t}function Yn(e){return t=>t+e}function Qn(e){let t=0;for(;e.previousSibling;)e=e.previousSibling,t++;return t}function Xn(e,t,o){e.insertBefore(o,e.childNodes[t]||null)}function ei(e){return e&&e.nodeType===Node.COMMENT_NODE}function ti(e){return!!(e&&e.getClientRects&&e.getClientRects().length)}function oi({element:e,target:o,positions:n,limiter:i,fitInViewport:r,viewportOffsetConfig:s}){We(o)&&(o=o()),We(i)&&(i=i());const a=Hn(e),l=function(e){e=Object.assign({top:0,bottom:0,left:0,right:0},e);const o=new qn(t.window);return o.top+=e.top,o.height-=e.top,o.bottom-=e.bottom,o.height-=e.bottom,o}(s),c=new qn(e),d=ni(o,l);let u;if(!d||!l.getIntersection(d))return null;const h={targetRect:d,elementRect:c,positionedElementAncestor:a,viewportRect:l};if(i||r){if(i){const e=ni(i,l);e&&(h.limiterRect=e)}u=function(e,t){const{elementRect:o}=t,n=o.getArea(),i=e.map((e=>new ii(e,t))).filter((e=>!!e.name));let r=0,s=null;for(const e of i){const{limiterIntersectionArea:t,viewportIntersectionArea:o}=e;if(t===n)return e;const i=o**2+t**2;i>r&&(r=i,s=e)}return s}(n,h)}else u=new ii(n[0],h);return u}function ni(e,t){const o=new qn(e).getVisible();return o?o.getIntersection(t):null}class ii{constructor(e,t){const o=e(t.targetRect,t.elementRect,t.viewportRect,t.limiterRect);if(!o)return;const{left:n,top:i,name:r,config:s}=o;this.name=r,this.config=s,this._positioningFunctionCoordinates={left:n,top:i},this._options=t}get left(){return this._absoluteRect.left}get top(){return this._absoluteRect.top}get limiterIntersectionArea(){const e=this._options.limiterRect;return e?e.getIntersectionArea(this._rect):0}get viewportIntersectionArea(){return this._options.viewportRect.getIntersectionArea(this._rect)}get _rect(){return this._cachedRect||(this._cachedRect=this._options.elementRect.clone().moveTo(this._positioningFunctionCoordinates.left,this._positioningFunctionCoordinates.top)),this._cachedRect}get _absoluteRect(){return this._cachedAbsoluteRect||(this._cachedAbsoluteRect=this._rect.toAbsoluteRect()),this._cachedAbsoluteRect}}function ri(e){const t=e.parentNode;t&&t.removeChild(e)}function si({window:e,rect:t,alignToTop:o,forceScroll:n,viewportOffset:i}){const r=t.clone().moveBy(0,i.bottom),s=t.clone().moveBy(0,-i.top),a=new qn(e).excludeScrollbarsAndBorders(),l=o&&n,c=[s,r].every((e=>a.contains(e)));let{scrollX:d,scrollY:u}=e;const h=d,m=u;l?u-=a.top-t.top+i.top:c||(ci(s,a)?u-=a.top-t.top+i.top:li(r,a)&&(u+=o?t.top-a.top-i.top:t.bottom-a.bottom+i.bottom)),c||(di(t,a)?d-=a.left-t.left+i.left:ui(t,a)&&(d+=t.right-a.right+i.right)),d==h&&u===m||e.scrollTo(d,u)}function ai({parent:e,getRect:t,alignToTop:o,forceScroll:n,ancestorOffset:i=0,limiterElement:r}){const s=hi(e),a=o&&n;let l,c,d;const u=r||s.document.body;for(;e!=u;)c=t(),l=new qn(e).excludeScrollbarsAndBorders(),d=l.contains(c),a?e.scrollTop-=l.top-c.top+i:d||(ci(c,l)?e.scrollTop-=l.top-c.top+i:li(c,l)&&(e.scrollTop+=o?c.top-l.top-i:c.bottom-l.bottom+i)),d||(di(c,l)?e.scrollLeft-=l.left-c.left+i:ui(c,l)&&(e.scrollLeft+=c.right-l.right+i)),e=e.parentNode}function li(e,t){return e.bottom>t.bottom}function ci(e,t){return e.topt.right}function hi(e){return Ln(e)?e.startContainer.ownerDocument.defaultView:e.ownerDocument.defaultView}function mi(e){if(Ln(e)){let t=e.commonAncestorContainer;return Nn(t)&&(t=t.parentNode),t}return e.parentNode}function pi(e,t){const o=hi(e),n=new qn(e);if(o===t)return n;{let e=o;for(;e!=t;){const t=e.frameElement,o=new qn(t).excludeScrollbarsAndBorders();n.moveBy(o.left,o.top),e=e.parent}}return n}const gi={ctrl:"⌃",cmd:"⌘",alt:"⌥",shift:"⇧"},fi={ctrl:"Ctrl+",alt:"Alt+",shift:"Shift+"},bi={37:"←",38:"↑",39:"→",40:"↓",9:"⇥",33:"Page Up",34:"Page Down"},ki=vi(),wi=Object.fromEntries(Object.entries(ki).map((([e,t])=>{let o;return o=t in bi?bi[t]:e.charAt(0).toUpperCase()+e.slice(1),[t,o]})));function _i(e){let t;if("string"==typeof e){if(t=ki[e.toLowerCase()],!t)throw new E("keyboard-unknown-key",null,{key:e})}else t=e.keyCode+(e.altKey?ki.alt:0)+(e.ctrlKey?ki.ctrl:0)+(e.shiftKey?ki.shift:0)+(e.metaKey?ki.cmd:0);return t}function yi(e){return"string"==typeof e&&(e=function(e){return e.split("+").map((e=>e.trim()))}(e)),e.map((e=>"string"==typeof e?function(e){if(e.endsWith("!"))return _i(e.slice(0,-1));const t=_i(e);return(r.isMac||r.isiOS)&&t==ki.ctrl?ki.cmd:t}(e):e)).reduce(((e,t)=>t+e),0)}function Ai(e){let t=yi(e);return Object.entries(r.isMac||r.isiOS?gi:fi).reduce(((e,[o,n])=>(0!=(t&ki[o])&&(t&=~ki[o],e+=n),e)),"")+(t?wi[t]:"")}function Ci(e,t){const o="ltr"===t;switch(e){case ki.arrowleft:return o?"left":"right";case ki.arrowright:return o?"right":"left";case ki.arrowup:return"up";case ki.arrowdown:return"down"}}function vi(){const e={pageup:33,pagedown:34,arrowleft:37,arrowup:38,arrowright:39,arrowdown:40,backspace:8,delete:46,enter:13,space:32,esc:27,tab:9,ctrl:1114112,shift:2228224,alt:4456448,cmd:8912896};for(let t=65;t<=90;t++){e[String.fromCharCode(t).toLowerCase()]=t}for(let t=48;t<=57;t++)e[t-48]=t;for(let t=112;t<=123;t++)e["f"+(t-111)]=t;return Object.assign(e,{"'":222,",":108,"-":109,".":110,"/":111,";":186,"=":187,"[":219,"\\":220,"]":221,"`":223}),e}function xi(e){return Array.isArray(e)?e:[e]}const Ei=function(e,t,o){(void 0!==o&&!Pe(e[t],o)||void 0===o&&!(t in e))&&It(e,t,o)};const Di=function(e){return function(t,o,n){for(var i=-1,r=Object(t),s=n(t),a=s.length;a--;){var l=s[e?a:++i];if(!1===o(r[l],l,r))break}return t}}();const Bi=function(e){return _e(e)&&ho(e)};const Si=function(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]};const Ti=function(e){return Mt(e,ko(e))};const Ii=function(e,t,o,n,i,r,s){var a=Si(e,o),l=Si(t,o),c=s.get(l);if(c)Ei(e,o,c);else{var d=r?r(a,l,o+"",e,t,s):void 0,u=void 0===d;if(u){var h=we(l),m=!h&&Wt(l),p=!h&&!m&&no(l);d=l,h||m||p?we(a)?d=a:Bi(a)?d=xo(a):m?(u=!1,d=vo(l,!0)):p?(u=!1,d=un(l,!0)):d=[]:Te(l)||Lt(l)?(d=a,Lt(a)?d=Ti(a):U(a)&&!We(a)||(d=gn(l))):u=!1}u&&(s.set(l,d),i(d,l,n,r,s),s.delete(l)),Ei(e,o,d)}};const Pi=function e(t,o,n,i,r){t!==o&&Di(o,(function(s,a){if(r||(r=new Bt),U(s))Ii(t,o,a,n,e,i,r);else{var l=i?i(Si(t,a),s,a+"",t,o,r):void 0;void 0===l&&(l=s),Ei(t,a,l)}}),ko)};const Fi=function(e){return e};const Mi=function(e,t,o){switch(o.length){case 0:return e.call(t);case 1:return e.call(t,o[0]);case 2:return e.call(t,o[0],o[1]);case 3:return e.call(t,o[0],o[1],o[2])}return e.apply(t,o)};var Ri=Math.max;const zi=function(e,t,o){return t=Ri(void 0===t?e.length-1:t,0),function(){for(var n=arguments,i=-1,r=Ri(n.length-t,0),s=Array(r);++i0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}};const Hi=Li(Oi);const ji=function(e,t){return Hi(zi(e,t,Fi),e+"")};const qi=function(e,t,o){if(!U(o))return!1;var n=typeof t;return!!("number"==n?ho(o)&&Gt(t,o.length):"string"==n&&t in o)&&Pe(o[t],e)};const Ui=function(e){return ji((function(t,o){var n=-1,i=o.length,r=i>1?o[i-1]:void 0,s=i>2?o[2]:void 0;for(r=e.length>3&&"function"==typeof r?(i--,r):void 0,s&&qi(o[0],o[1],s)&&(r=i<3?void 0:r,i=1),t=Object(t);++n1===e?0:1),d=l[a];if("string"==typeof d)return d;return d[Number(c(n))]}t.window.CKEDITOR_TRANSLATIONS||(t.window.CKEDITOR_TRANSLATIONS={});const Ki=["ar","ara","dv","div","fa","per","fas","he","heb","ku","kur","ug","uig"];function Zi(e){return Ki.includes(e)?"rtl":"ltr"}class Ji{constructor({uiLanguage:e="en",contentLanguage:t,translations:o}={}){this.uiLanguage=e,this.contentLanguage=t||this.uiLanguage,this.uiLanguageDirection=Zi(this.uiLanguage),this.contentLanguageDirection=Zi(this.contentLanguage),this.translations=function(e){return Array.isArray(e)?e.reduce(((e,t)=>$i(e,t))):e}(o),this.t=(e,t)=>this._t(e,t)}get language(){return console.warn("locale-deprecated-language-property: The Locale#language property has been deprecated and will be removed in the near future. Please use #uiLanguage and #contentLanguage properties instead."),this.uiLanguage}_t(e,t=[]){t=xi(t),"string"==typeof e&&(e={string:e});const o=!!e.plural?t[0]:1;return function(e,t){return e.replace(/%(\d+)/g,((e,o)=>othis._items.length||t<0)throw new E("collection-add-item-invalid-index",this);let o=0;for(const n of e){const e=this._getItemIdBeforeAdding(n),i=t+o;this._items.splice(i,0,n),this._itemMap.set(e,n),this.fire("add",n,i),o++}return this.fire("change",{added:e,removed:[],index:t}),this}get(e){let t;if("string"==typeof e)t=this._itemMap.get(e);else{if("number"!=typeof e)throw new E("collection-get-invalid-arg",this);t=this._items[e]}return t||null}has(e){if("string"==typeof e)return this._itemMap.has(e);{const t=e[this._idProperty];return t&&this._itemMap.has(t)}}getIndex(e){let t;return t="string"==typeof e?this._itemMap.get(e):e,t?this._items.indexOf(t):-1}remove(e){const[t,o]=this._remove(e);return this.fire("change",{added:[],removed:[t],index:o}),t}map(e,t){return this._items.map(e,t)}forEach(e,t){this._items.forEach(e,t)}find(e,t){return this._items.find(e,t)}filter(e,t){return this._items.filter(e,t)}clear(){this._bindToCollection&&(this.stopListening(this._bindToCollection),this._bindToCollection=null);const e=Array.from(this._items);for(;this.length;)this._remove(0);this.fire("change",{added:[],removed:e,index:0})}bindTo(e){if(this._bindToCollection)throw new E("collection-bind-to-rebind",this);return this._bindToCollection=e,{as:e=>{this._setUpBindToBinding((t=>new e(t)))},using:e=>{"function"==typeof e?this._setUpBindToBinding(e):this._setUpBindToBinding((t=>t[e]))}}}_setUpBindToBinding(e){const t=this._bindToCollection,o=(o,n,i)=>{const r=t._bindToCollection==this,s=t._bindToInternalToExternalMap.get(n);if(r&&s)this._bindToExternalToInternalMap.set(n,s),this._bindToInternalToExternalMap.set(s,n);else{const o=e(n);if(!o)return void this._skippedIndexesFromExternal.push(i);let r=i;for(const e of this._skippedIndexesFromExternal)i>e&&r--;for(const e of t._skippedIndexesFromExternal)r>=e&&r++;this._bindToExternalToInternalMap.set(n,o),this._bindToInternalToExternalMap.set(o,n),this.add(o,r);for(let e=0;e{const n=this._bindToExternalToInternalMap.get(t);n&&this.remove(n),this._skippedIndexesFromExternal=this._skippedIndexesFromExternal.reduce(((e,t)=>(ot&&e.push(t),e)),[])}))}_getItemIdBeforeAdding(e){const t=this._idProperty;let o;if(t in e){if(o=e[t],"string"!=typeof o)throw new E("collection-add-invalid-id",this);if(this.get(o))throw new E("collection-add-item-already-exists",this)}else e[t]=o=A();return o}_remove(e){let t,o,n,i=!1;const r=this._idProperty;if("string"==typeof e?(o=e,n=this._itemMap.get(o),i=!n,n&&(t=this._items.indexOf(n))):"number"==typeof e?(t=e,n=this._items[t],i=!n,n&&(o=n[r])):(n=e,o=n[r],t=this._items.indexOf(n),i=-1==t||!this._itemMap.get(o)),i)throw new E("collection-remove-404",this);this._items.splice(t,1),this._itemMap.delete(o);const s=this._bindToInternalToExternalMap.get(n);return this._bindToInternalToExternalMap.delete(n),this._bindToExternalToInternalMap.delete(s),this.fire("remove",n,t),[n,t]}[Symbol.iterator](){return this._items[Symbol.iterator]()}}function Qi(e){const t=e.next();return t.done?null:t.value}class Xi extends(Rn(Y())){constructor(){super(),this._elements=new Set,this._nextEventLoopTimeout=null,this.set("isFocused",!1),this.set("focusedElement",null)}add(e){if(this._elements.has(e))throw new E("focustracker-add-element-already-exist",this);this.listenTo(e,"focus",(()=>this._focus(e)),{useCapture:!0}),this.listenTo(e,"blur",(()=>this._blur()),{useCapture:!0}),this._elements.add(e)}remove(e){e===this.focusedElement&&this._blur(),this._elements.has(e)&&(this.stopListening(e),this._elements.delete(e))}destroy(){this.stopListening()}_focus(e){clearTimeout(this._nextEventLoopTimeout),this.focusedElement=e,this.isFocused=!0}_blur(){clearTimeout(this._nextEventLoopTimeout),this._nextEventLoopTimeout=setTimeout((()=>{this.focusedElement=null,this.isFocused=!1}),0)}}class er{constructor(){this._listener=new(Rn())}listenTo(e){this._listener.listenTo(e,"keydown",((e,t)=>{this._listener.fire("_keydown:"+_i(t),t)}))}set(e,t,o={}){const n=yi(e),i=o.priority;this._listener.listenTo(this._listener,"_keydown:"+n,((e,n)=>{o.filter&&!o.filter(n)||(t(n,(()=>{n.preventDefault(),n.stopPropagation(),e.stop()})),e.return=!0)}),{priority:i})}press(e){return!!this._listener.fire("_keydown:"+_i(e),e)}stopListening(e){this._listener.stopListening(e)}destroy(){this.stopListening()}}function tr(e){return re(e)?new Map(e):function(e){const t=new Map;for(const o in e)t.set(o,e[o]);return t}(e)}function or(e,t){let o;function n(...i){n.cancel(),o=setTimeout((()=>e(...i)),t)}return n.cancel=()=>{clearTimeout(o)},n}function nr(e,t){return!!(o=e.charAt(t-1))&&1==o.length&&/[\ud800-\udbff]/.test(o)&&function(e){return!!e&&1==e.length&&/[\udc00-\udfff]/.test(e)}(e.charAt(t));var o}function ir(e,t){return!!(o=e.charAt(t))&&1==o.length&&/[\u0300-\u036f\u1ab0-\u1aff\u1dc0-\u1dff\u20d0-\u20ff\ufe20-\ufe2f]/.test(o);var o}const rr=ar();function sr(e,t){const o=String(e).matchAll(rr);return Array.from(o).some((e=>e.indexe.source)).join("|")+")";return new RegExp(`${e}|${t}(?:‍${t})*`,"ug")}class lr extends(Y()){constructor(e){super(),this._disableStack=new Set,this.editor=e,this.set("isEnabled",!0)}forceDisabled(e){this._disableStack.add(e),1==this._disableStack.size&&(this.on("set:isEnabled",cr,{priority:"highest"}),this.isEnabled=!1)}clearForceDisabled(e){this._disableStack.delete(e),0==this._disableStack.size&&(this.off("set:isEnabled",cr),this.isEnabled=!0)}destroy(){this.stopListening()}static get isContextPlugin(){return!1}}function cr(e){e.return=!1,e.stop()}class dr extends(Y()){constructor(e){super(),this.editor=e,this.set("value",void 0),this.set("isEnabled",!1),this._affectsData=!0,this._isEnabledBasedOnSelection=!0,this._disableStack=new Set,this.decorate("execute"),this.listenTo(this.editor.model.document,"change",(()=>{this.refresh()})),this.listenTo(e,"change:isReadOnly",(()=>{this.refresh()})),this.on("set:isEnabled",(t=>{if(!this.affectsData)return;const o=e.model.document.selection,n=!("$graveyard"==o.getFirstPosition().root.rootName)&&e.model.canEditAt(o);(e.isReadOnly||this._isEnabledBasedOnSelection&&!n)&&(t.return=!1,t.stop())}),{priority:"highest"}),this.on("execute",(e=>{this.isEnabled||e.stop()}),{priority:"high"})}get affectsData(){return this._affectsData}set affectsData(e){this._affectsData=e}refresh(){this.isEnabled=!0}forceDisabled(e){this._disableStack.add(e),1==this._disableStack.size&&(this.on("set:isEnabled",ur,{priority:"highest"}),this.isEnabled=!1)}clearForceDisabled(e){this._disableStack.delete(e),0==this._disableStack.size&&(this.off("set:isEnabled",ur),this.refresh())}execute(...e){}destroy(){this.stopListening()}}function ur(e){e.return=!1,e.stop()}class hr extends(z()){constructor(e,t=[],o=[]){super(),this._plugins=new Map,this._context=e,this._availablePlugins=new Map;for(const e of t)e.pluginName&&this._availablePlugins.set(e.pluginName,e);this._contextPlugins=new Map;for(const[e,t]of o)this._contextPlugins.set(e,t),this._contextPlugins.set(t,e),e.pluginName&&this._availablePlugins.set(e.pluginName,e)}*[Symbol.iterator](){for(const e of this._plugins)"function"==typeof e[0]&&(yield e)}get(e){const t=this._plugins.get(e);if(!t){let t=e;throw"function"==typeof e&&(t=e.pluginName||e.name),new E("plugincollection-plugin-not-loaded",this._context,{plugin:t})}return t}has(e){return this._plugins.has(e)}init(e,t=[],o=[]){const n=this,i=this._context;!function e(t,o=new Set){t.forEach((t=>{a(t)&&(o.has(t)||(o.add(t),t.pluginName&&!n._availablePlugins.has(t.pluginName)&&n._availablePlugins.set(t.pluginName,t),t.requires&&e(t.requires,o)))}))}(e),u(e);const r=[...function e(t,o=new Set){return t.map((e=>a(e)?e:n._availablePlugins.get(e))).reduce(((t,n)=>o.has(n)?t:(o.add(n),n.requires&&(u(n.requires,n),e(n.requires,o).forEach((e=>t.add(e)))),t.add(n))),new Set)}(e.filter((e=>!c(e,t))))];!function(e,t){for(const o of t){if("function"!=typeof o)throw new E("plugincollection-replace-plugin-invalid-type",null,{pluginItem:o});const t=o.pluginName;if(!t)throw new E("plugincollection-replace-plugin-missing-name",null,{pluginItem:o});if(o.requires&&o.requires.length)throw new E("plugincollection-plugin-for-replacing-cannot-have-dependencies",null,{pluginName:t});const i=n._availablePlugins.get(t);if(!i)throw new E("plugincollection-plugin-for-replacing-not-exist",null,{pluginName:t});const r=e.indexOf(i);if(-1===r){if(n._contextPlugins.has(i))return;throw new E("plugincollection-plugin-for-replacing-not-loaded",null,{pluginName:t})}if(i.requires&&i.requires.length)throw new E("plugincollection-replaced-plugin-cannot-have-dependencies",null,{pluginName:t});e.splice(r,1,o),n._availablePlugins.set(t,o)}}(r,o);const s=function(e){return e.map((e=>{let t=n._contextPlugins.get(e);return t=t||new e(i),n._add(e,t),t}))}(r);return h(s,"init").then((()=>h(s,"afterInit"))).then((()=>s));function a(e){return"function"==typeof e}function l(e){return a(e)&&!!e.isContextPlugin}function c(e,t){return t.some((t=>t===e||(d(e)===t||d(t)===e)))}function d(e){return a(e)?e.pluginName||e.name:e}function u(e,o=null){e.map((e=>a(e)?e:n._availablePlugins.get(e)||e)).forEach((e=>{!function(e,t){if(a(e))return;if(t)throw new E("plugincollection-soft-required",i,{missingPlugin:e,requiredBy:d(t)});throw new E("plugincollection-plugin-not-found",i,{plugin:e})}(e,o),function(e,t){if(!l(t))return;if(l(e))return;throw new E("plugincollection-context-required",i,{plugin:d(e),requiredBy:d(t)})}(e,o),function(e,o){if(!o)return;if(!c(e,t))return;throw new E("plugincollection-required",i,{plugin:d(e),requiredBy:d(o)})}(e,o)}))}function h(e,t){return e.reduce(((e,o)=>o[t]?n._contextPlugins.has(o)?e:e.then(o[t].bind(o)):e),Promise.resolve())}}destroy(){const e=[];for(const[,t]of this)"function"!=typeof t.destroy||this._contextPlugins.has(t)||e.push(t.destroy());return Promise.all(e)}_add(e,t){this._plugins.set(e,t);const o=e.pluginName;if(o){if(this._plugins.has(o))throw new E("plugincollection-plugin-name-conflict",null,{pluginName:o,plugin1:this._plugins.get(o).constructor,plugin2:e});this._plugins.set(o,t)}}}class mr{constructor(e){this._contextOwner=null;const{translations:t,...o}=e||{};this.config=new Sn(o,this.constructor.defaultConfig);const n=this.constructor.builtinPlugins;this.config.define("plugins",n),this.plugins=new hr(this,n);const i=this.config.get("language")||{};this.locale=new Ji({uiLanguage:"string"==typeof i?i:i.ui,contentLanguage:this.config.get("language.content"),translations:t}),this.t=this.locale.t,this.editors=new Yi}initPlugins(){const e=this.config.get("plugins")||[],t=this.config.get("substitutePlugins")||[];for(const o of e.concat(t)){if("function"!=typeof o)throw new E("context-initplugins-constructor-only",null,{Plugin:o});if(!0!==o.isContextPlugin)throw new E("context-initplugins-invalid-plugin",null,{Plugin:o})}return this.plugins.init(e,[],t)}destroy(){return Promise.all(Array.from(this.editors,(e=>e.destroy()))).then((()=>this.plugins.destroy()))}_addEditor(e,t){if(this._contextOwner)throw new E("context-addeditor-private-context");this.editors.add(e),t&&(this._contextOwner=e)}_removeEditor(e){return this.editors.has(e)&&this.editors.remove(e),this._contextOwner===e?this.destroy():Promise.resolve()}_getEditorConfig(){const e={};for(const t of this.config.names())["plugins","removePlugins","extraPlugins"].includes(t)||(e[t]=this.config.get(t));return e}static create(e){return new Promise((t=>{const o=new this(e);t(o.initPlugins().then((()=>o)))}))}}class pr extends(Y()){constructor(e){super(),this.context=e}destroy(){this.stopListening()}static get isContextPlugin(){return!0}}var gr=i(5072),fr=i.n(gr),br=i(4284),kr=i.n(br),wr=i(7659),_r=i.n(wr),yr=i(4868),Ar=i.n(yr),Cr=i(540),vr=i.n(Cr),xr=i(1111),Er={attributes:{"data-cke":!0}};Er.setAttributes=Ar(),Er.insert=_r().bind(null,"head"),Er.domAPI=kr(),Er.insertStyleElement=vr();fr()(xr.A,Er);xr.A&&xr.A.locals&&xr.A.locals;const Dr=new WeakMap;let Br=!1;function Sr({view:e,element:t,text:o,isDirectHost:n=!0,keepOnFocus:i=!1}){const r=e.document;function s(o){Dr.get(r).set(t,{text:o,isDirectHost:n,keepOnFocus:i,hostElement:n?t:null}),e.change((e=>Fr(r,e)))}Dr.has(r)||(Dr.set(r,new Map),r.registerPostFixer((e=>Fr(r,e))),r.on("change:isComposing",(()=>{e.change((e=>Fr(r,e)))}),{priority:"high"})),t.is("editableElement")&&t.on("change:placeholder",((e,t,o)=>{s(o)})),t.placeholder?s(t.placeholder):o&&s(o),o&&function(){Br||D("enableplaceholder-deprecated-text-option");Br=!0}()}function Tr(e,t){return!t.hasClass("ck-placeholder")&&(e.addClass("ck-placeholder",t),!0)}function Ir(e,t){return!!t.hasClass("ck-placeholder")&&(e.removeClass("ck-placeholder",t),!0)}function Pr(e,t){if(!e.isAttached())return!1;const o=Array.from(e.getChildren()).some((e=>!e.is("uiElement")));if(o)return!1;const n=e.document,i=n.selection.anchor;return(!n.isComposing||!i||i.parent!==e)&&(!!t||(!n.isFocused||!!i&&i.parent!==e))}function Fr(e,t){const o=Dr.get(e),n=[];let i=!1;for(const[e,r]of o)r.isDirectHost&&(n.push(e),Mr(t,e,r)&&(i=!0));for(const[e,r]of o){if(r.isDirectHost)continue;const o=Rr(e);o&&(n.includes(o)||(r.hostElement=o,Mr(t,e,r)&&(i=!0)))}return i}function Mr(e,t,o){const{text:n,isDirectHost:i,hostElement:r}=o;let s=!1;r.getAttribute("data-placeholder")!==n&&(e.setAttribute("data-placeholder",n,r),s=!0);return(i||1==t.childCount)&&Pr(r,o.keepOnFocus)?Tr(e,r)&&(s=!0):Ir(e,r)&&(s=!0),s}function Rr(e){if(e.childCount){const t=e.getChild(0);if(t.is("element")&&!t.is("uiElement")&&!t.is("attributeElement"))return t}return null}class zr{is(){throw new Error("is() method is abstract")}}const Vr=function(e){return En(e,4)};class Or extends(z(zr)){constructor(e){super(),this.document=e,this.parent=null}get index(){let e;if(!this.parent)return null;if(-1==(e=this.parent.getChildIndex(this)))throw new E("view-node-not-found-in-parent",this);return e}get nextSibling(){const e=this.index;return null!==e&&this.parent.getChild(e+1)||null}get previousSibling(){const e=this.index;return null!==e&&this.parent.getChild(e-1)||null}get root(){let e=this;for(;e.parent;)e=e.parent;return e}isAttached(){return this.root.is("rootElement")}getPath(){const e=[];let t=this;for(;t.parent;)e.unshift(t.index),t=t.parent;return e}getAncestors(e={}){const t=[];let o=e.includeSelf?this:this.parent;for(;o;)t[e.parentFirst?"push":"unshift"](o),o=o.parent;return t}getCommonAncestor(e,t={}){const o=this.getAncestors(t),n=e.getAncestors(t);let i=0;for(;o[i]==n[i]&&o[i];)i++;return 0===i?null:o[i-1]}isBefore(e){if(this==e)return!1;if(this.root!==e.root)return!1;const t=this.getPath(),o=e.getPath(),n=ie(t,o);switch(n){case"prefix":return!0;case"extension":return!1;default:return t[n]e.data.length)throw new E("view-textproxy-wrong-offsetintext",this);if(o<0||t+o>e.data.length)throw new E("view-textproxy-wrong-length",this);this.data=e.data.substring(t,t+o),this.offsetInText=t}get offsetSize(){return this.data.length}get isPartial(){return this.data.length!==this.textNode.data.length}get parent(){return this.textNode.parent}get root(){return this.textNode.root}get document(){return this.textNode.document}getAncestors(e={}){const t=[];let o=e.includeSelf?this.textNode:this.parent;for(;null!==o;)t[e.parentFirst?"push":"unshift"](o),o=o.parent;return t}}Lr.prototype.is=function(e){return"$textProxy"===e||"view:$textProxy"===e||"textProxy"===e||"view:textProxy"===e};class Hr{constructor(...e){this._patterns=[],this.add(...e)}add(...e){for(let t of e)("string"==typeof t||t instanceof RegExp)&&(t={name:t}),this._patterns.push(t)}match(...e){for(const t of e)for(const e of this._patterns){const o=jr(t,e);if(o)return{element:t,pattern:e,match:o}}return null}matchAll(...e){const t=[];for(const o of e)for(const e of this._patterns){const n=jr(o,e);n&&t.push({element:o,pattern:e,match:n})}return t.length>0?t:null}getElementName(){if(1!==this._patterns.length)return null;const e=this._patterns[0],t=e.name;return"function"==typeof e||!t||t instanceof RegExp?null:t}}function jr(e,t){if("function"==typeof t)return t(e);const o={};return t.name&&(o.name=function(e,t){if(e instanceof RegExp)return!!t.match(e);return e===t}(t.name,e.name),!o.name)||t.attributes&&(o.attributes=function(e,t){const o=new Set(t.getAttributeKeys());Te(e)?(void 0!==e.style&&D("matcher-pattern-deprecated-attributes-style-key",e),void 0!==e.class&&D("matcher-pattern-deprecated-attributes-class-key",e)):(o.delete("style"),o.delete("class"));return qr(e,o,(e=>t.getAttribute(e)))}(t.attributes,e),!o.attributes)||t.classes&&(o.classes=function(e,t){return qr(e,t.getClassNames(),(()=>{}))}(t.classes,e),!o.classes)||t.styles&&(o.styles=function(e,t){return qr(e,t.getStyleNames(!0),(e=>t.getStyle(e)))}(t.styles,e),!o.styles)?null:o}function qr(e,t,o){const n=function(e){if(Array.isArray(e))return e.map((e=>Te(e)?(void 0!==e.key&&void 0!==e.value||D("matcher-pattern-missing-key-or-value",e),[e.key,e.value]):[e,!0]));if(Te(e))return Object.entries(e);return[[e,!0]]}(e),i=Array.from(t),r=[];if(n.forEach((([e,t])=>{i.forEach((n=>{(function(e,t){return!0===e||e===t||e instanceof RegExp&&t.match(e)})(e,n)&&function(e,t,o){if(!0===e)return!0;const n=o(t);return e===n||e instanceof RegExp&&!!String(n).match(e)}(t,n,o)&&r.push(n)}))})),n.length&&!(r.lengthi?0:i+t),(o=o>i?i:o)<0&&(o+=i),i=t>o?0:o-t>>>0,t>>>=0;for(var r=Array(i);++nt===e));return Array.isArray(t)}set(e,t){if(U(e))for(const[t,o]of Object.entries(e))this._styleProcessor.toNormalizedForm(t,o,this._styles);else this._styleProcessor.toNormalizedForm(e,t,this._styles)}remove(e){const t=ws(e);ms(this._styles,t),delete this._styles[e],this._cleanEmptyObjectsOnPath(t)}getNormalized(e){return this._styleProcessor.getNormalized(e,this._styles)}toString(){return this.isEmpty?"":this.getStylesEntries().map((e=>e.join(":"))).sort().join(";")+";"}getAsString(e){if(this.isEmpty)return;if(this._styles[e]&&!U(this._styles[e]))return this._styles[e];const t=this._styleProcessor.getReducedForm(e,this._styles).find((([t])=>t===e));return Array.isArray(t)?t[1]:void 0}getStyleNames(e=!1){if(this.isEmpty)return[];if(e)return this._styleProcessor.getStyleNames(this._styles);return this.getStylesEntries().map((([e])=>e))}clear(){this._styles={}}getStylesEntries(){const e=[],t=Object.keys(this._styles);for(const o of t)e.push(...this._styleProcessor.getReducedForm(o,this._styles));return e}_cleanEmptyObjectsOnPath(e){const t=e.split(".");if(!(t.length>1))return;const o=t.splice(0,t.length-1).join("."),n=ps(this._styles,o);if(!n)return;!Object.keys(n).length&&this.remove(o)}}class ks{constructor(){this._normalizers=new Map,this._extractors=new Map,this._reducers=new Map,this._consumables=new Map}toNormalizedForm(e,t,o){if(U(t))_s(o,ws(e),t);else if(this._normalizers.has(e)){const n=this._normalizers.get(e),{path:i,value:r}=n(t);_s(o,i,r)}else _s(o,e,t)}getNormalized(e,t){if(!e)return $i({},t);if(void 0!==t[e])return t[e];if(this._extractors.has(e)){const o=this._extractors.get(e);if("string"==typeof o)return ps(t,o);const n=o(e,t);if(n)return n}return ps(t,ws(e))}getReducedForm(e,t){const o=this.getNormalized(e,t);if(void 0===o)return[];if(this._reducers.has(e)){return this._reducers.get(e)(o)}return[[e,o]]}getStyleNames(e){const t=Array.from(this._consumables.keys()).filter((t=>{const o=this.getNormalized(t,e);return o&&"object"==typeof o?Object.keys(o).length:o})),o=new Set([...t,...Object.keys(e)]);return Array.from(o)}getRelatedStyles(e){return this._consumables.get(e)||[]}setNormalizer(e,t){this._normalizers.set(e,t)}setExtractor(e,t){this._extractors.set(e,t)}setReducer(e,t){this._reducers.set(e,t)}setStyleRelation(e,t){this._mapStyleNames(e,t);for(const o of t)this._mapStyleNames(o,[e])}_mapStyleNames(e,t){this._consumables.has(e)||this._consumables.set(e,[]),this._consumables.get(e).push(...t)}}function ws(e){return e.replace("-",".")}function _s(e,t,o){let n=o;U(o)&&(n=$i({},ps(e,t),o)),fs(e,t,n)}class ys extends Or{constructor(e,t,o,n){if(super(e),this._unsafeAttributesToRender=[],this._customProperties=new Map,this.name=t,this._attrs=function(e){const t=tr(e);for(const[e,o]of t)null===o?t.delete(e):"string"!=typeof o&&t.set(e,String(o));return t}(o),this._children=[],n&&this._insertChild(0,n),this._classes=new Set,this._attrs.has("class")){const e=this._attrs.get("class");As(this._classes,e),this._attrs.delete("class")}this._styles=new bs(this.document.stylesProcessor),this._attrs.has("style")&&(this._styles.setTo(this._attrs.get("style")),this._attrs.delete("style"))}get childCount(){return this._children.length}get isEmpty(){return 0===this._children.length}getChild(e){return this._children[e]}getChildIndex(e){return this._children.indexOf(e)}getChildren(){return this._children[Symbol.iterator]()}*getAttributeKeys(){this._classes.size>0&&(yield"class"),this._styles.isEmpty||(yield"style"),yield*this._attrs.keys()}*getAttributes(){yield*this._attrs.entries(),this._classes.size>0&&(yield["class",this.getAttribute("class")]),this._styles.isEmpty||(yield["style",this.getAttribute("style")])}getAttribute(e){if("class"==e)return this._classes.size>0?[...this._classes].join(" "):void 0;if("style"==e){const e=this._styles.toString();return""==e?void 0:e}return this._attrs.get(e)}hasAttribute(e){return"class"==e?this._classes.size>0:"style"==e?!this._styles.isEmpty:this._attrs.has(e)}isSimilar(e){if(!(e instanceof ys))return!1;if(this===e)return!0;if(this.name!=e.name)return!1;if(this._attrs.size!==e._attrs.size||this._classes.size!==e._classes.size||this._styles.size!==e._styles.size)return!1;for(const[t,o]of this._attrs)if(!e._attrs.has(t)||e._attrs.get(t)!==o)return!1;for(const t of this._classes)if(!e._classes.has(t))return!1;for(const t of this._styles.getStyleNames())if(!e._styles.has(t)||e._styles.getAsString(t)!==this._styles.getAsString(t))return!1;return!0}hasClass(...e){for(const t of e)if(!this._classes.has(t))return!1;return!0}getClassNames(){return this._classes.keys()}getStyle(e){return this._styles.getAsString(e)}getNormalizedStyle(e){return this._styles.getNormalized(e)}getStyleNames(e){return this._styles.getStyleNames(e)}hasStyle(...e){for(const t of e)if(!this._styles.has(t))return!1;return!0}findAncestor(...e){const t=new Hr(...e);let o=this.parent;for(;o&&!o.is("documentFragment");){if(t.match(o))return o;o=o.parent}return null}getCustomProperty(e){return this._customProperties.get(e)}*getCustomProperties(){yield*this._customProperties.entries()}getIdentity(){const e=Array.from(this._classes).sort().join(","),t=this._styles.toString(),o=Array.from(this._attrs).map((e=>`${e[0]}="${e[1]}"`)).sort().join(" ");return this.name+(""==e?"":` class="${e}"`)+(t?` style="${t}"`:"")+(""==o?"":` ${o}`)}shouldRenderUnsafeAttribute(e){return this._unsafeAttributesToRender.includes(e)}_clone(e=!1){const t=[];if(e)for(const o of this.getChildren())t.push(o._clone(e));const o=new this.constructor(this.document,this.name,this._attrs,t);return o._classes=new Set(this._classes),o._styles.set(this._styles.getNormalized()),o._customProperties=new Map(this._customProperties),o.getFillerOffset=this.getFillerOffset,o._unsafeAttributesToRender=this._unsafeAttributesToRender,o}_appendChild(e){return this._insertChild(this.childCount,e)}_insertChild(e,t){this._fireChange("children",this);let o=0;const n=function(e,t){if("string"==typeof t)return[new Nr(e,t)];re(t)||(t=[t]);return Array.from(t).map((t=>"string"==typeof t?new Nr(e,t):t instanceof Lr?new Nr(e,t.data):t))}(this.document,t);for(const t of n)null!==t.parent&&t._remove(),t.parent=this,t.document=this.document,this._children.splice(e,0,t),e++,o++;return o}_removeChildren(e,t=1){this._fireChange("children",this);for(let o=e;o0&&(this._classes.clear(),!0):"style"==e?!this._styles.isEmpty&&(this._styles.clear(),!0):this._attrs.delete(e)}_addClass(e){this._fireChange("attributes",this);for(const t of xi(e))this._classes.add(t)}_removeClass(e){this._fireChange("attributes",this);for(const t of xi(e))this._classes.delete(t)}_setStyle(e,t){this._fireChange("attributes",this),"string"!=typeof e?this._styles.set(e):this._styles.set(e,t)}_removeStyle(e){this._fireChange("attributes",this);for(const t of xi(e))this._styles.remove(t)}_setCustomProperty(e,t){this._customProperties.set(e,t)}_removeCustomProperty(e){return this._customProperties.delete(e)}}function As(e,t){const o=t.split(/\s+/);e.clear(),o.forEach((t=>e.add(t)))}ys.prototype.is=function(e,t){return t?t===this.name&&("element"===e||"view:element"===e):"element"===e||"view:element"===e||"node"===e||"view:node"===e};class Cs extends ys{constructor(e,t,o,n){super(e,t,o,n),this.getFillerOffset=vs}}function vs(){const e=[...this.getChildren()],t=e[this.childCount-1];if(t&&t.is("element","br"))return this.childCount;for(const t of e)if(!t.is("uiElement"))return null;return this.childCount}Cs.prototype.is=function(e,t){return t?t===this.name&&("containerElement"===e||"view:containerElement"===e||"element"===e||"view:element"===e):"containerElement"===e||"view:containerElement"===e||"element"===e||"view:element"===e||"node"===e||"view:node"===e};class xs extends(Y(Cs)){constructor(e,t,o,n){super(e,t,o,n),this.set("isReadOnly",!1),this.set("isFocused",!1),this.set("placeholder",void 0),this.bind("isReadOnly").to(e),this.bind("isFocused").to(e,"isFocused",(t=>t&&e.selection.editableElement==this)),this.listenTo(e.selection,"change",(()=>{this.isFocused=e.isFocused&&e.selection.editableElement==this}))}destroy(){this.stopListening()}}xs.prototype.is=function(e,t){return t?t===this.name&&("editableElement"===e||"view:editableElement"===e||"containerElement"===e||"view:containerElement"===e||"element"===e||"view:element"===e):"editableElement"===e||"view:editableElement"===e||"containerElement"===e||"view:containerElement"===e||"element"===e||"view:element"===e||"node"===e||"view:node"===e};const Es=Symbol("rootName");class Ds extends xs{constructor(e,t){super(e,t),this.rootName="main"}get rootName(){return this.getCustomProperty(Es)}set rootName(e){this._setCustomProperty(Es,e)}set _name(e){this.name=e}}Ds.prototype.is=function(e,t){return t?t===this.name&&("rootElement"===e||"view:rootElement"===e||"editableElement"===e||"view:editableElement"===e||"containerElement"===e||"view:containerElement"===e||"element"===e||"view:element"===e):"rootElement"===e||"view:rootElement"===e||"editableElement"===e||"view:editableElement"===e||"containerElement"===e||"view:containerElement"===e||"element"===e||"view:element"===e||"node"===e||"view:node"===e};class Bs{constructor(e={}){if(!e.boundaries&&!e.startPosition)throw new E("view-tree-walker-no-start-position",null);if(e.direction&&"forward"!=e.direction&&"backward"!=e.direction)throw new E("view-tree-walker-unknown-direction",e.startPosition,{direction:e.direction});this.boundaries=e.boundaries||null,e.startPosition?this._position=Ss._createAt(e.startPosition):this._position=Ss._createAt(e.boundaries["backward"==e.direction?"end":"start"]),this.direction=e.direction||"forward",this.singleCharacters=!!e.singleCharacters,this.shallow=!!e.shallow,this.ignoreElementEnd=!!e.ignoreElementEnd,this._boundaryStartParent=this.boundaries?this.boundaries.start.parent:null,this._boundaryEndParent=this.boundaries?this.boundaries.end.parent:null}[Symbol.iterator](){return this}get position(){return this._position}skip(e){let t,o;do{o=this.position,t=this.next()}while(!t.done&&e(t.value));t.done||(this._position=o)}next(){return"forward"==this.direction?this._next():this._previous()}_next(){let e=this.position.clone();const t=this.position,o=e.parent;if(null===o.parent&&e.offset===o.childCount)return{done:!0,value:void 0};if(o===this._boundaryEndParent&&e.offset==this.boundaries.end.offset)return{done:!0,value:void 0};let n;if(o instanceof Nr){if(e.isAtEnd)return this._position=Ss._createAfter(o),this._next();n=o.data[e.offset]}else n=o.getChild(e.offset);if(n instanceof ys){if(this.shallow){if(this.boundaries&&this.boundaries.end.isBefore(e))return{done:!0,value:void 0};e.offset++}else e=new Ss(n,0);return this._position=e,this._formatReturnValue("elementStart",n,t,e,1)}if(n instanceof Nr){if(this.singleCharacters)return e=new Ss(n,0),this._position=e,this._next();let o,i=n.data.length;return n==this._boundaryEndParent?(i=this.boundaries.end.offset,o=new Lr(n,0,i),e=Ss._createAfter(o)):(o=new Lr(n,0,n.data.length),e.offset++),this._position=e,this._formatReturnValue("text",o,t,e,i)}if("string"==typeof n){let n;if(this.singleCharacters)n=1;else{n=(o===this._boundaryEndParent?this.boundaries.end.offset:o.data.length)-e.offset}const i=new Lr(o,e.offset,n);return e.offset+=n,this._position=e,this._formatReturnValue("text",i,t,e,n)}return e=Ss._createAfter(o),this._position=e,this.ignoreElementEnd?this._next():this._formatReturnValue("elementEnd",o,t,e)}_previous(){let e=this.position.clone();const t=this.position,o=e.parent;if(null===o.parent&&0===e.offset)return{done:!0,value:void 0};if(o==this._boundaryStartParent&&e.offset==this.boundaries.start.offset)return{done:!0,value:void 0};let n;if(o instanceof Nr){if(e.isAtStart)return this._position=Ss._createBefore(o),this._previous();n=o.data[e.offset-1]}else n=o.getChild(e.offset-1);if(n instanceof ys)return this.shallow?(e.offset--,this._position=e,this._formatReturnValue("elementStart",n,t,e,1)):(e=new Ss(n,n.childCount),this._position=e,this.ignoreElementEnd?this._previous():this._formatReturnValue("elementEnd",n,t,e));if(n instanceof Nr){if(this.singleCharacters)return e=new Ss(n,n.data.length),this._position=e,this._previous();let o,i=n.data.length;if(n==this._boundaryStartParent){const t=this.boundaries.start.offset;o=new Lr(n,t,n.data.length-t),i=o.data.length,e=Ss._createBefore(o)}else o=new Lr(n,0,n.data.length),e.offset--;return this._position=e,this._formatReturnValue("text",o,t,e,i)}if("string"==typeof n){let n;if(this.singleCharacters)n=1;else{const t=o===this._boundaryStartParent?this.boundaries.start.offset:0;n=e.offset-t}e.offset-=n;const i=new Lr(o,e.offset,n);return this._position=e,this._formatReturnValue("text",i,t,e,n)}return e=Ss._createBefore(o),this._position=e,this._formatReturnValue("elementStart",o,t,e,1)}_formatReturnValue(e,t,o,n,i){return t instanceof Lr&&(t.offsetInText+t.data.length==t.textNode.data.length&&("forward"!=this.direction||this.boundaries&&this.boundaries.end.isEqual(this.position)?o=Ss._createAfter(t.textNode):(n=Ss._createAfter(t.textNode),this._position=n)),0===t.offsetInText&&("backward"!=this.direction||this.boundaries&&this.boundaries.start.isEqual(this.position)?o=Ss._createBefore(t.textNode):(n=Ss._createBefore(t.textNode),this._position=n))),{done:!1,value:{type:e,item:t,previousPosition:o,nextPosition:n,length:i}}}}class Ss extends zr{constructor(e,t){super(),this.parent=e,this.offset=t}get nodeAfter(){return this.parent.is("$text")?null:this.parent.getChild(this.offset)||null}get nodeBefore(){return this.parent.is("$text")?null:this.parent.getChild(this.offset-1)||null}get isAtStart(){return 0===this.offset}get isAtEnd(){const e=this.parent.is("$text")?this.parent.data.length:this.parent.childCount;return this.offset===e}get root(){return this.parent.root}get editableElement(){let e=this.parent;for(;!(e instanceof xs);){if(!e.parent)return null;e=e.parent}return e}getShiftedBy(e){const t=Ss._createAt(this),o=t.offset+e;return t.offset=o<0?0:o,t}getLastMatchingPosition(e,t={}){t.startPosition=this;const o=new Bs(t);return o.skip(e),o.position}getAncestors(){return this.parent.is("documentFragment")?[this.parent]:this.parent.getAncestors({includeSelf:!0})}getCommonAncestor(e){const t=this.getAncestors(),o=e.getAncestors();let n=0;for(;t[n]==o[n]&&t[n];)n++;return 0===n?null:t[n-1]}isEqual(e){return this.parent==e.parent&&this.offset==e.offset}isBefore(e){return"before"==this.compareWith(e)}isAfter(e){return"after"==this.compareWith(e)}compareWith(e){if(this.root!==e.root)return"different";if(this.isEqual(e))return"same";const t=this.parent.is("node")?this.parent.getPath():[],o=e.parent.is("node")?e.parent.getPath():[];t.push(this.offset),o.push(e.offset);const n=ie(t,o);switch(n){case"prefix":return"before";case"extension":return"after";default:return t[n]0?new this(o,n):new this(n,o)}static _createIn(e){return this._createFromParentsAndOffsets(e,0,e,e.childCount)}static _createOn(e){const t=e.is("$textProxy")?e.offsetSize:1;return this._createFromPositionAndShift(Ss._createBefore(e),t)}}function Is(e){return!(!e.item.is("attributeElement")&&!e.item.is("uiElement"))}Ts.prototype.is=function(e){return"range"===e||"view:range"===e};class Ps extends(z(zr)){constructor(...e){super(),this._ranges=[],this._lastRangeBackward=!1,this._isFake=!1,this._fakeSelectionLabel="",e.length&&this.setTo(...e)}get isFake(){return this._isFake}get fakeSelectionLabel(){return this._fakeSelectionLabel}get anchor(){if(!this._ranges.length)return null;const e=this._ranges[this._ranges.length-1];return(this._lastRangeBackward?e.end:e.start).clone()}get focus(){if(!this._ranges.length)return null;const e=this._ranges[this._ranges.length-1];return(this._lastRangeBackward?e.start:e.end).clone()}get isCollapsed(){return 1===this.rangeCount&&this._ranges[0].isCollapsed}get rangeCount(){return this._ranges.length}get isBackward(){return!this.isCollapsed&&this._lastRangeBackward}get editableElement(){return this.anchor?this.anchor.editableElement:null}*getRanges(){for(const e of this._ranges)yield e.clone()}getFirstRange(){let e=null;for(const t of this._ranges)e&&!t.start.isBefore(e.start)||(e=t);return e?e.clone():null}getLastRange(){let e=null;for(const t of this._ranges)e&&!t.end.isAfter(e.end)||(e=t);return e?e.clone():null}getFirstPosition(){const e=this.getFirstRange();return e?e.start.clone():null}getLastPosition(){const e=this.getLastRange();return e?e.end.clone():null}isEqual(e){if(this.isFake!=e.isFake)return!1;if(this.isFake&&this.fakeSelectionLabel!=e.fakeSelectionLabel)return!1;if(this.rangeCount!=e.rangeCount)return!1;if(0===this.rangeCount)return!0;if(!this.anchor.isEqual(e.anchor)||!this.focus.isEqual(e.focus))return!1;for(const t of this._ranges){let o=!1;for(const n of e._ranges)if(t.isEqual(n)){o=!0;break}if(!o)return!1}return!0}isSimilar(e){if(this.isBackward!=e.isBackward)return!1;const t=ne(this.getRanges());if(t!=ne(e.getRanges()))return!1;if(0==t)return!0;for(let t of this.getRanges()){t=t.getTrimmed();let o=!1;for(let n of e.getRanges())if(n=n.getTrimmed(),t.start.isEqual(n.start)&&t.end.isEqual(n.end)){o=!0;break}if(!o)return!1}return!0}getSelectedElement(){return 1!==this.rangeCount?null:this.getFirstRange().getContainedElement()}setTo(...e){let[t,o,n]=e;if("object"==typeof o&&(n=o,o=void 0),null===t)this._setRanges([]),this._setFakeOptions(n);else if(t instanceof Ps||t instanceof Fs)this._setRanges(t.getRanges(),t.isBackward),this._setFakeOptions({fake:t.isFake,label:t.fakeSelectionLabel});else if(t instanceof Ts)this._setRanges([t],n&&n.backward),this._setFakeOptions(n);else if(t instanceof Ss)this._setRanges([new Ts(t)]),this._setFakeOptions(n);else if(t instanceof Or){const e=!!n&&!!n.backward;let i;if(void 0===o)throw new E("view-selection-setto-required-second-parameter",this);i="in"==o?Ts._createIn(t):"on"==o?Ts._createOn(t):new Ts(Ss._createAt(t,o)),this._setRanges([i],e),this._setFakeOptions(n)}else{if(!re(t))throw new E("view-selection-setto-not-selectable",this);this._setRanges(t,n&&n.backward),this._setFakeOptions(n)}this.fire("change")}setFocus(e,t){if(null===this.anchor)throw new E("view-selection-setfocus-no-ranges",this);const o=Ss._createAt(e,t);if("same"==o.compareWith(this.focus))return;const n=this.anchor;this._ranges.pop(),"before"==o.compareWith(n)?this._addRange(new Ts(o,n),!0):this._addRange(new Ts(n,o)),this.fire("change")}_setRanges(e,t=!1){e=Array.from(e),this._ranges=[];for(const t of e)this._addRange(t);this._lastRangeBackward=!!t}_setFakeOptions(e={}){this._isFake=!!e.fake,this._fakeSelectionLabel=e.fake&&e.label||""}_addRange(e,t=!1){if(!(e instanceof Ts))throw new E("view-selection-add-range-not-range",this);this._pushRange(e),this._lastRangeBackward=!!t}_pushRange(e){for(const t of this._ranges)if(e.isIntersecting(t))throw new E("view-selection-range-intersects",this,{addedRange:e,intersectingRange:t});this._ranges.push(new Ts(e.start,e.end))}}Ps.prototype.is=function(e){return"selection"===e||"view:selection"===e};class Fs extends(z(zr)){constructor(...e){super(),this._selection=new Ps,this._selection.delegate("change").to(this),e.length&&this._selection.setTo(...e)}get isFake(){return this._selection.isFake}get fakeSelectionLabel(){return this._selection.fakeSelectionLabel}get anchor(){return this._selection.anchor}get focus(){return this._selection.focus}get isCollapsed(){return this._selection.isCollapsed}get rangeCount(){return this._selection.rangeCount}get isBackward(){return this._selection.isBackward}get editableElement(){return this._selection.editableElement}get _ranges(){return this._selection._ranges}*getRanges(){yield*this._selection.getRanges()}getFirstRange(){return this._selection.getFirstRange()}getLastRange(){return this._selection.getLastRange()}getFirstPosition(){return this._selection.getFirstPosition()}getLastPosition(){return this._selection.getLastPosition()}getSelectedElement(){return this._selection.getSelectedElement()}isEqual(e){return this._selection.isEqual(e)}isSimilar(e){return this._selection.isSimilar(e)}_setTo(...e){this._selection.setTo(...e)}_setFocus(e,t){this._selection.setFocus(e,t)}}Fs.prototype.is=function(e){return"selection"===e||"documentSelection"==e||"view:selection"==e||"view:documentSelection"==e};class Ms extends w{constructor(e,t,o){super(e,t),this.startRange=o,this._eventPhase="none",this._currentTarget=null}get eventPhase(){return this._eventPhase}get currentTarget(){return this._currentTarget}}const Rs=Symbol("bubbling contexts");function zs(e){return class extends e{fire(e,...t){try{const o=e instanceof w?e:new w(this,e),n=Ls(this);if(!n.size)return;if(Vs(o,"capturing",this),Os(n,"$capture",o,...t))return o.return;const i=o.startRange||this.selection.getFirstRange(),r=i?i.getContainedElement():null,s=!!r&&Boolean(Ns(n,r));let a=r||function(e){if(!e)return null;const t=e.start.parent,o=e.end.parent,n=t.getPath(),i=o.getPath();return n.length>i.length?t:o}(i);if(Vs(o,"atTarget",a),!s){if(Os(n,"$text",o,...t))return o.return;Vs(o,"bubbling",a)}for(;a;){if(a.is("rootElement")){if(Os(n,"$root",o,...t))return o.return}else if(a.is("element")&&Os(n,a.name,o,...t))return o.return;if(Os(n,a,o,...t))return o.return;a=a.parent,Vs(o,"bubbling",a)}return Vs(o,"bubbling",this),Os(n,"$document",o,...t),o.return}catch(e){E.rethrowUnexpectedError(e,this)}}_addEventListener(e,t,o){const n=xi(o.context||"$document"),i=Ls(this);for(const r of n){let n=i.get(r);n||(n=new(z()),i.set(r,n)),this.listenTo(n,e,t,o)}}_removeEventListener(e,t){const o=Ls(this);for(const n of o.values())this.stopListening(n,e,t)}}}{const e=zs(Object);["fire","_addEventListener","_removeEventListener"].forEach((t=>{zs[t]=e.prototype[t]}))}function Vs(e,t,o){e instanceof Ms&&(e._eventPhase=t,e._currentTarget=o)}function Os(e,t,o,...n){const i="string"==typeof t?e.get(t):Ns(e,t);return!!i&&(i.fire(o,...n),o.stop.called)}function Ns(e,t){for(const[o,n]of e)if("function"==typeof o&&o(t))return n;return null}function Ls(e){return e[Rs]||(e[Rs]=new Map),e[Rs]}class Hs extends(zs(Y())){constructor(e){super(),this._postFixers=new Set,this.selection=new Fs,this.roots=new Yi({idProperty:"rootName"}),this.stylesProcessor=e,this.set("isReadOnly",!1),this.set("isFocused",!1),this.set("isSelecting",!1),this.set("isComposing",!1)}getRoot(e="main"){return this.roots.get(e)}registerPostFixer(e){this._postFixers.add(e)}destroy(){this.roots.forEach((e=>e.destroy())),this.stopListening()}_callPostFixers(e){let t=!1;do{for(const o of this._postFixers)if(t=o(e),t)break}while(t)}}class js extends ys{constructor(e,t,o,n){super(e,t,o,n),this._priority=10,this._id=null,this._clonesGroup=null,this.getFillerOffset=Us}get priority(){return this._priority}get id(){return this._id}getElementsWithSameId(){if(null===this.id)throw new E("attribute-element-get-elements-with-same-id-no-id",this);return new Set(this._clonesGroup)}isSimilar(e){return null!==this.id||null!==e.id?this.id===e.id:super.isSimilar(e)&&this.priority==e.priority}_clone(e=!1){const t=super._clone(e);return t._priority=this._priority,t._id=this._id,t}}js.DEFAULT_PRIORITY=10;const qs=js;function Us(){if(Ws(this))return null;let e=this.parent;for(;e&&e.is("attributeElement");){if(Ws(e)>1)return null;e=e.parent}return!e||Ws(e)>1?null:this.childCount}function Ws(e){return Array.from(e.getChildren()).filter((e=>!e.is("uiElement"))).length}js.prototype.is=function(e,t){return t?t===this.name&&("attributeElement"===e||"view:attributeElement"===e||"element"===e||"view:element"===e):"attributeElement"===e||"view:attributeElement"===e||"element"===e||"view:element"===e||"node"===e||"view:node"===e};class $s extends ys{constructor(e,t,o,n){super(e,t,o,n),this.getFillerOffset=Gs}_insertChild(e,t){if(t&&(t instanceof Or||Array.from(t).length>0))throw new E("view-emptyelement-cannot-add",[this,t]);return 0}}function Gs(){return null}$s.prototype.is=function(e,t){return t?t===this.name&&("emptyElement"===e||"view:emptyElement"===e||"element"===e||"view:element"===e):"emptyElement"===e||"view:emptyElement"===e||"element"===e||"view:element"===e||"node"===e||"view:node"===e};class Ks extends ys{constructor(e,t,o,n){super(e,t,o,n),this.getFillerOffset=Js}_insertChild(e,t){if(t&&(t instanceof Or||Array.from(t).length>0))throw new E("view-uielement-cannot-add",[this,t]);return 0}render(e,t){return this.toDomElement(e)}toDomElement(e){const t=e.createElement(this.name);for(const e of this.getAttributeKeys())t.setAttribute(e,this.getAttribute(e));return t}}function Zs(e){e.document.on("arrowKey",((t,o)=>function(e,t,o){if(t.keyCode==ki.arrowright){const e=t.domTarget.ownerDocument.defaultView.getSelection(),n=1==e.rangeCount&&e.getRangeAt(0).collapsed;if(n||t.shiftKey){const t=e.focusNode,i=e.focusOffset,r=o.domPositionToView(t,i);if(null===r)return;let s=!1;const a=r.getLastMatchingPosition((e=>(e.item.is("uiElement")&&(s=!0),!(!e.item.is("uiElement")&&!e.item.is("attributeElement")))));if(s){const t=o.viewPositionToDom(a);n?e.collapse(t.parent,t.offset):e.extend(t.parent,t.offset)}}}}(0,o,e.domConverter)),{priority:"low"})}function Js(){return null}Ks.prototype.is=function(e,t){return t?t===this.name&&("uiElement"===e||"view:uiElement"===e||"element"===e||"view:element"===e):"uiElement"===e||"view:uiElement"===e||"element"===e||"view:element"===e||"node"===e||"view:node"===e};class Ys extends ys{constructor(e,t,o,n){super(e,t,o,n),this.getFillerOffset=Qs}_insertChild(e,t){if(t&&(t instanceof Or||Array.from(t).length>0))throw new E("view-rawelement-cannot-add",[this,t]);return 0}render(e,t){}}function Qs(){return null}Ys.prototype.is=function(e,t){return t?t===this.name&&("rawElement"===e||"view:rawElement"===e||"element"===e||"view:element"===e):"rawElement"===e||"view:rawElement"===e||e===this.name||e==="view:"+this.name||"element"===e||"view:element"===e||"node"===e||"view:node"===e};class Xs extends(z(zr)){constructor(e,t){super(),this._children=[],this._customProperties=new Map,this.document=e,t&&this._insertChild(0,t)}[Symbol.iterator](){return this._children[Symbol.iterator]()}get childCount(){return this._children.length}get isEmpty(){return 0===this.childCount}get root(){return this}get parent(){return null}get name(){}get getFillerOffset(){}getCustomProperty(e){return this._customProperties.get(e)}*getCustomProperties(){yield*this._customProperties.entries()}_appendChild(e){return this._insertChild(this.childCount,e)}getChild(e){return this._children[e]}getChildIndex(e){return this._children.indexOf(e)}getChildren(){return this._children[Symbol.iterator]()}_insertChild(e,t){this._fireChange("children",this);let o=0;const n=function(e,t){if("string"==typeof t)return[new Nr(e,t)];re(t)||(t=[t]);return Array.from(t).map((t=>"string"==typeof t?new Nr(e,t):t instanceof Lr?new Nr(e,t.data):t))}(this.document,t);for(const t of n)null!==t.parent&&t._remove(),t.parent=this,this._children.splice(e,0,t),e++,o++;return o}_removeChildren(e,t=1){this._fireChange("children",this);for(let o=e;o{const o=e[e.length-1],n=!t.is("uiElement");return o&&o.breakAttributes==n?o.nodes.push(t):e.push({breakAttributes:n,nodes:[t]}),e}),[]);let n=null,i=e;for(const{nodes:e,breakAttributes:t}of o){const o=this._insertNodes(i,e,t);n||(n=o.start),i=o.end}return n?new Ts(n,i):new Ts(e)}remove(e){const t=e instanceof Ts?e:Ts._createOn(e);if(ca(t,this.document),t.isCollapsed)return new Xs(this.document);const{start:o,end:n}=this._breakAttributesRange(t,!0),i=o.parent,r=n.offset-o.offset,s=i._removeChildren(o.offset,r);for(const e of s)this._removeFromClonedElementsGroup(e);const a=this.mergeAttributes(o);return t.start=a,t.end=a.clone(),new Xs(this.document,s)}clear(e,t){ca(e,this.document);const o=e.getWalker({direction:"backward",ignoreElementEnd:!0});for(const n of o){const o=n.item;let i;if(o.is("element")&&t.isSimilar(o))i=Ts._createOn(o);else if(!n.nextPosition.isAfter(e.start)&&o.is("$textProxy")){const e=o.getAncestors().find((e=>e.is("element")&&t.isSimilar(e)));e&&(i=Ts._createIn(e))}i&&(i.end.isAfter(e.end)&&(i.end=e.end),i.start.isBefore(e.start)&&(i.start=e.start),this.remove(i))}}move(e,t){let o;if(t.isAfter(e.end)){const n=(t=this._breakAttributes(t,!0)).parent,i=n.childCount;e=this._breakAttributesRange(e,!0),o=this.remove(e),t.offset+=n.childCount-i}else o=this.remove(e);return this.insert(t,o)}wrap(e,t){if(!(t instanceof qs))throw new E("view-writer-wrap-invalid-attribute",this.document);if(ca(e,this.document),e.isCollapsed){let n=e.start;n.parent.is("element")&&(o=n.parent,!Array.from(o.getChildren()).some((e=>!e.is("uiElement"))))&&(n=n.getLastMatchingPosition((e=>e.item.is("uiElement")))),n=this._wrapPosition(n,t);const i=this.document.selection;return i.isCollapsed&&i.getFirstPosition().isEqual(e.start)&&this.setSelection(n),new Ts(n)}return this._wrapRange(e,t);var o}unwrap(e,t){if(!(t instanceof qs))throw new E("view-writer-unwrap-invalid-attribute",this.document);if(ca(e,this.document),e.isCollapsed)return e;const{start:o,end:n}=this._breakAttributesRange(e,!0),i=o.parent,r=this._unwrapChildren(i,o.offset,n.offset,t),s=this.mergeAttributes(r.start);s.isEqual(r.start)||r.end.offset--;const a=this.mergeAttributes(r.end);return new Ts(s,a)}rename(e,t){const o=new Cs(this.document,e,t.getAttributes());return this.insert(Ss._createAfter(t),o),this.move(Ts._createIn(t),Ss._createAt(o,0)),this.remove(Ts._createOn(t)),o}clearClonedElementsGroup(e){this._cloneGroups.delete(e)}createPositionAt(e,t){return Ss._createAt(e,t)}createPositionAfter(e){return Ss._createAfter(e)}createPositionBefore(e){return Ss._createBefore(e)}createRange(e,t){return new Ts(e,t)}createRangeOn(e){return Ts._createOn(e)}createRangeIn(e){return Ts._createIn(e)}createSelection(...e){return new Ps(...e)}createSlot(e="children"){if(!this._slotFactory)throw new E("view-writer-invalid-create-slot-context",this.document);return this._slotFactory(this,e)}_registerSlotFactory(e){this._slotFactory=e}_clearSlotFactory(){this._slotFactory=null}_insertNodes(e,t,o){let n,i;if(n=o?ta(e):e.parent.is("$text")?e.parent.parent:e.parent,!n)throw new E("view-writer-invalid-position-container",this.document);i=o?this._breakAttributes(e,!0):e.parent.is("$text")?ia(e):e;const r=n._insertChild(i.offset,t);for(const e of t)this._addToClonedElementsGroup(e);const s=i.getShiftedBy(r),a=this.mergeAttributes(i);a.isEqual(i)||s.offset--;const l=this.mergeAttributes(s);return new Ts(a,l)}_wrapChildren(e,t,o,n){let i=t;const r=[];for(;i!1,e.parent._insertChild(e.offset,o);const n=new Ts(e,e.getShiftedBy(1));this.wrap(n,t);const i=new Ss(o.parent,o.index);o._remove();const r=i.nodeBefore,s=i.nodeAfter;return r instanceof Nr&&s instanceof Nr?ra(r,s):na(i)}_wrapAttributeElement(e,t){if(!da(e,t))return!1;if(e.name!==t.name||e.priority!==t.priority)return!1;for(const o of e.getAttributeKeys())if("class"!==o&&"style"!==o&&t.hasAttribute(o)&&t.getAttribute(o)!==e.getAttribute(o))return!1;for(const o of e.getStyleNames())if(t.hasStyle(o)&&t.getStyle(o)!==e.getStyle(o))return!1;for(const o of e.getAttributeKeys())"class"!==o&&"style"!==o&&(t.hasAttribute(o)||this.setAttribute(o,e.getAttribute(o),t));for(const o of e.getStyleNames())t.hasStyle(o)||this.setStyle(o,e.getStyle(o),t);for(const o of e.getClassNames())t.hasClass(o)||this.addClass(o,t);return!0}_unwrapAttributeElement(e,t){if(!da(e,t))return!1;if(e.name!==t.name||e.priority!==t.priority)return!1;for(const o of e.getAttributeKeys())if("class"!==o&&"style"!==o&&(!t.hasAttribute(o)||t.getAttribute(o)!==e.getAttribute(o)))return!1;if(!t.hasClass(...e.getClassNames()))return!1;for(const o of e.getStyleNames())if(!t.hasStyle(o)||t.getStyle(o)!==e.getStyle(o))return!1;for(const o of e.getAttributeKeys())"class"!==o&&"style"!==o&&this.removeAttribute(o,t);return this.removeClass(Array.from(e.getClassNames()),t),this.removeStyle(Array.from(e.getStyleNames()),t),!0}_breakAttributesRange(e,t=!1){const o=e.start,n=e.end;if(ca(e,this.document),e.isCollapsed){const o=this._breakAttributes(e.start,t);return new Ts(o,o)}const i=this._breakAttributes(n,t),r=i.parent.childCount,s=this._breakAttributes(o,t);return i.offset+=i.parent.childCount-r,new Ts(s,i)}_breakAttributes(e,t=!1){const o=e.offset,n=e.parent;if(e.parent.is("emptyElement"))throw new E("view-writer-cannot-break-empty-element",this.document);if(e.parent.is("uiElement"))throw new E("view-writer-cannot-break-ui-element",this.document);if(e.parent.is("rawElement"))throw new E("view-writer-cannot-break-raw-element",this.document);if(!t&&n.is("$text")&&la(n.parent))return e.clone();if(la(n))return e.clone();if(n.is("$text"))return this._breakAttributes(ia(e),t);if(o==n.childCount){const e=new Ss(n.parent,n.index+1);return this._breakAttributes(e,t)}if(0===o){const e=new Ss(n.parent,n.index);return this._breakAttributes(e,t)}{const e=n.index+1,i=n._clone();n.parent._insertChild(e,i),this._addToClonedElementsGroup(i);const r=n.childCount-o,s=n._removeChildren(o,r);i._appendChild(s);const a=new Ss(n.parent,e);return this._breakAttributes(a,t)}}_addToClonedElementsGroup(e){if(!e.root.is("rootElement"))return;if(e.is("element"))for(const t of e.getChildren())this._addToClonedElementsGroup(t);const t=e.id;if(!t)return;let o=this._cloneGroups.get(t);o||(o=new Set,this._cloneGroups.set(t,o)),o.add(e),e._clonesGroup=o}_removeFromClonedElementsGroup(e){if(e.is("element"))for(const t of e.getChildren())this._removeFromClonedElementsGroup(t);const t=e.id;if(!t)return;const o=this._cloneGroups.get(t);o&&o.delete(e)}}function ta(e){let t=e.parent;for(;!la(t);){if(!t)return;t=t.parent}return t}function oa(e,t){return e.priorityt.priority)&&e.getIdentity()o instanceof e)))throw new E("view-writer-insert-invalid-node-type",t);o.is("$text")||aa(o.getChildren(),t)}}function la(e){return e&&(e.is("containerElement")||e.is("documentFragment"))}function ca(e,t){const o=ta(e.start),n=ta(e.end);if(!o||!n||o!==n)throw new E("view-writer-invalid-range-container",t)}function da(e,t){return null===e.id&&null===t.id}const ua=e=>e.createTextNode(" "),ha=e=>{const t=e.createElement("span");return t.dataset.ckeFiller="true",t.innerText=" ",t},ma=e=>{const t=e.createElement("br");return t.dataset.ckeFiller="true",t},pa=7,ga="⁠".repeat(pa);function fa(e){return"string"==typeof e?e.substr(0,pa)===ga:Nn(e)&&e.data.substr(0,pa)===ga}function ba(e){return e.data.length==pa&&fa(e)}function ka(e){const t="string"==typeof e?e:e.data;return fa(e)?t.slice(pa):t}function wa(e,t){if(t.keyCode==ki.arrowleft){const e=t.domTarget.ownerDocument.defaultView.getSelection();if(1==e.rangeCount&&e.getRangeAt(0).collapsed){const t=e.getRangeAt(0).startContainer,o=e.getRangeAt(0).startOffset;fa(t)&&o<=pa&&e.collapse(t,0)}}}var _a=i(6531),ya={attributes:{"data-cke":!0}};ya.setAttributes=Ar(),ya.insert=_r().bind(null,"head"),ya.domAPI=kr(),ya.insertStyleElement=vr();fr()(_a.A,ya);_a.A&&_a.A.locals&&_a.A.locals;class Aa extends(Y()){constructor(e,t){super(),this.domDocuments=new Set,this.markedAttributes=new Set,this.markedChildren=new Set,this.markedTexts=new Set,this._inlineFiller=null,this._fakeSelectionContainer=null,this.domConverter=e,this.selection=t,this.set("isFocused",!1),this.set("isSelecting",!1),this.set("isComposing",!1),r.isBlink&&!r.isAndroid&&this.on("change:isSelecting",(()=>{this.isSelecting||this.render()}))}markToSync(e,t){if("text"===e)this.domConverter.mapViewToDom(t.parent)&&this.markedTexts.add(t);else{if(!this.domConverter.mapViewToDom(t))return;if("attributes"===e)this.markedAttributes.add(t);else{if("children"!==e){throw new E("view-renderer-unknown-type",this)}this.markedChildren.add(t)}}}render(){if(this.isComposing&&!r.isAndroid)return;let e=null;const t=!(r.isBlink&&!r.isAndroid)||!this.isSelecting;for(const e of this.markedChildren)this._updateChildrenMappings(e);t?(this._inlineFiller&&!this._isSelectionInInlineFiller()&&this._removeInlineFiller(),this._inlineFiller?e=this._getInlineFillerPosition():this._needsInlineFillerAtSelection()&&(e=this.selection.getFirstPosition(),this.markedChildren.add(e.parent))):this._inlineFiller&&this._inlineFiller.parentNode&&(e=this.domConverter.domPositionToView(this._inlineFiller),e&&e.parent.is("$text")&&(e=Ss._createBefore(e.parent)));for(const e of this.markedAttributes)this._updateAttrs(e);for(const t of this.markedChildren)this._updateChildren(t,{inlineFillerPosition:e});for(const t of this.markedTexts)!this.markedChildren.has(t.parent)&&this.domConverter.mapViewToDom(t.parent)&&this._updateText(t,{inlineFillerPosition:e});if(t)if(e){const t=this.domConverter.viewPositionToDom(e),o=t.parent.ownerDocument;fa(t.parent)?this._inlineFiller=t.parent:this._inlineFiller=Ca(o,t.parent,t.offset)}else this._inlineFiller=null;this._updateFocus(),this._updateSelection(),this.domConverter._clearTemporaryCustomProperties(),this.markedTexts.clear(),this.markedAttributes.clear(),this.markedChildren.clear()}_updateChildrenMappings(e){const t=this.domConverter.mapViewToDom(e);if(!t)return;const o=Array.from(t.childNodes),n=Array.from(this.domConverter.viewChildrenToDom(e,{withChildren:!1})),i=this._diffNodeLists(o,n),r=this._findUpdateActions(i,o,n,va);if(-1!==r.indexOf("update")){const t={equal:0,insert:0,delete:0};for(const i of r)if("update"===i){const i=t.equal+t.insert,r=t.equal+t.delete,s=e.getChild(i);!s||s.is("uiElement")||s.is("rawElement")||this._updateElementMappings(s,o[r]),ri(n[i]),t.equal++}else t[i]++}}_updateElementMappings(e,t){this.domConverter.unbindDomElement(t),this.domConverter.bindElements(t,e),this.markedChildren.add(e),this.markedAttributes.add(e)}_getInlineFillerPosition(){const e=this.selection.getFirstPosition();return e.parent.is("$text")?Ss._createBefore(e.parent):e}_isSelectionInInlineFiller(){if(1!=this.selection.rangeCount||!this.selection.isCollapsed)return!1;const e=this.selection.getFirstPosition(),t=this.domConverter.viewPositionToDom(e);return!!(t&&Nn(t.parent)&&fa(t.parent))}_removeInlineFiller(){const e=this._inlineFiller;if(!fa(e))throw new E("view-renderer-filler-was-lost",this);ba(e)?e.remove():e.data=e.data.substr(pa),this._inlineFiller=null}_needsInlineFillerAtSelection(){if(1!=this.selection.rangeCount||!this.selection.isCollapsed)return!1;const e=this.selection.getFirstPosition(),t=e.parent,o=e.offset;if(!this.domConverter.mapViewToDom(t.root))return!1;if(!t.is("element"))return!1;if(!function(e){if("false"==e.getAttribute("contenteditable"))return!1;const t=e.findAncestor((e=>e.hasAttribute("contenteditable")));return!t||"true"==t.getAttribute("contenteditable")}(t))return!1;const n=e.nodeBefore,i=e.nodeAfter;return!(n instanceof Nr||i instanceof Nr)&&(!!(o!==t.getFillerOffset()||n&&n.is("element","br"))&&(!r.isAndroid||!n&&!i))}_updateText(e,t){const o=this.domConverter.findCorrespondingDomText(e);let n=this.domConverter.viewToDom(e).data;const i=t.inlineFillerPosition;i&&i.parent==e.parent&&i.offset==e.index&&(n=ga+n),this._updateTextNode(o,n)}_updateAttrs(e){const t=this.domConverter.mapViewToDom(e);if(!t)return;const o=Array.from(t.attributes).map((e=>e.name)),n=e.getAttributeKeys();for(const o of n)this.domConverter.setDomElementAttribute(t,o,e.getAttribute(o),e);for(const n of o)e.hasAttribute(n)||this.domConverter.removeDomElementAttribute(t,n)}_updateChildren(e,t){const o=this.domConverter.mapViewToDom(e);if(!o)return;if(r.isAndroid){let e=null;for(const t of Array.from(o.childNodes)){if(e&&Nn(e)&&Nn(t)){o.normalize();break}e=t}}const n=t.inlineFillerPosition,i=o.childNodes,s=Array.from(this.domConverter.viewChildrenToDom(e,{bind:!0}));n&&n.parent===e&&Ca(o.ownerDocument,s,n.offset);const a=this._diffNodeLists(i,s),l=this._findUpdateActions(a,i,s,xa);let c=0;const d=new Set;for(const e of l)"delete"===e?(d.add(i[c]),ri(i[c])):"equal"!==e&&"update"!==e||c++;c=0;for(const e of l)"insert"===e?(Xn(o,c,s[c]),c++):"update"===e?(this._updateTextNode(i[c],s[c].data),c++):"equal"===e&&(this._markDescendantTextToSync(this.domConverter.domToView(s[c])),c++);for(const e of d)e.parentNode||this.domConverter.unbindDomElement(e)}_diffNodeLists(e,t){return e=function(e,t){const o=Array.from(e);if(0==o.length||!t)return o;const n=o[o.length-1];n==t&&o.pop();return o}(e,this._fakeSelectionContainer),b(e,t,Ea.bind(null,this.domConverter))}_findUpdateActions(e,t,o,n){if(-1===e.indexOf("insert")||-1===e.indexOf("delete"))return e;let i=[],r=[],s=[];const a={equal:0,insert:0,delete:0};for(const l of e)"insert"===l?s.push(o[a.equal+a.insert]):"delete"===l?r.push(t[a.equal+a.delete]):(i=i.concat(b(r,s,n).map((e=>"equal"===e?"update":e))),i.push("equal"),r=[],s=[]),a[l]++;return i.concat(b(r,s,n).map((e=>"equal"===e?"update":e)))}_updateTextNode(e,t){const o=e.data;o!=t&&(r.isAndroid&&this.isComposing&&o.replace(/\u00A0/g," ")==t.replace(/\u00A0/g," ")||this._updateTextNodeInternal(e,t))}_updateTextNodeInternal(e,t){const o=p(e.data,t);for(const t of o)"insert"===t.type?e.insertData(t.index,t.values.join("")):e.deleteData(t.index,t.howMany)}_markDescendantTextToSync(e){if(e)if(e.is("$text"))this.markedTexts.add(e);else if(e.is("element"))for(const t of e.getChildren())this._markDescendantTextToSync(t)}_updateSelection(){if(r.isBlink&&!r.isAndroid&&this.isSelecting&&!this.markedChildren.size)return;if(0===this.selection.rangeCount)return this._removeDomSelection(),void this._removeFakeSelection();const e=this.domConverter.mapViewToDom(this.selection.editableElement);this.isFocused&&e&&(this.selection.isFake?this._updateFakeSelection(e):this._fakeSelectionContainer&&this._fakeSelectionContainer.isConnected?(this._removeFakeSelection(),this._updateDomSelection(e)):this.isComposing&&r.isAndroid||this._updateDomSelection(e))}_updateFakeSelection(e){const t=e.ownerDocument;this._fakeSelectionContainer||(this._fakeSelectionContainer=function(e){const t=e.createElement("div");return t.className="ck-fake-selection-container",Object.assign(t.style,{position:"fixed",top:0,left:"-9999px",width:"42px"}),t.textContent=" ",t}(t));const o=this._fakeSelectionContainer;if(this.domConverter.bindFakeSelection(o,this.selection),!this._fakeSelectionNeedsUpdate(e))return;o.parentElement&&o.parentElement==e||e.appendChild(o),o.textContent=this.selection.fakeSelectionLabel||" ";const n=t.getSelection(),i=t.createRange();n.removeAllRanges(),i.selectNodeContents(o),n.addRange(i)}_updateDomSelection(e){const t=e.ownerDocument.defaultView.getSelection();if(!this._domSelectionNeedsUpdate(t))return;const o=this.domConverter.viewPositionToDom(this.selection.anchor),n=this.domConverter.viewPositionToDom(this.selection.focus);t.setBaseAndExtent(o.parent,o.offset,n.parent,n.offset),r.isGecko&&function(e,t){let o=e.parent,n=e.offset;Nn(o)&&ba(o)&&(n=Qn(o)+1,o=o.parentNode);if(o.nodeType!=Node.ELEMENT_NODE||n!=o.childNodes.length-1)return;const i=o.childNodes[n];i&&"BR"==i.tagName&&t.addRange(t.getRangeAt(0))}(n,t)}_domSelectionNeedsUpdate(e){if(!this.domConverter.isDomSelectionCorrect(e))return!0;const t=e&&this.domConverter.domSelectionToView(e);return(!t||!this.selection.isEqual(t))&&!(!this.selection.isCollapsed&&this.selection.isSimilar(t))}_fakeSelectionNeedsUpdate(e){const t=this._fakeSelectionContainer,o=e.ownerDocument.getSelection();return!t||t.parentElement!==e||(o.anchorNode!==t&&!t.contains(o.anchorNode)||t.textContent!==this.selection.fakeSelectionLabel)}_removeDomSelection(){for(const e of this.domDocuments){const t=e.getSelection();if(t.rangeCount){const o=e.activeElement,n=this.domConverter.mapDomToView(o);o&&n&&t.removeAllRanges()}}}_removeFakeSelection(){const e=this._fakeSelectionContainer;e&&e.remove()}_updateFocus(){if(this.isFocused){const e=this.selection.editableElement;e&&this.domConverter.focus(e)}}}function Ca(e,t,o){const n=t instanceof Array?t:t.childNodes,i=n[o];if(Nn(i))return i.data=ga+i.data,i;{const i=e.createTextNode(ga);return Array.isArray(t)?n.splice(o,0,i):Xn(t,o,i),i}}function va(e,t){return Pn(e)&&Pn(t)&&!Nn(e)&&!Nn(t)&&!ei(e)&&!ei(t)&&e.tagName.toLowerCase()===t.tagName.toLowerCase()}function xa(e,t){return Pn(e)&&Pn(t)&&Nn(e)&&Nn(t)}function Ea(e,t,o){return t===o||(Nn(t)&&Nn(o)?t.data===o.data:!(!e.isBlockFiller(t)||!e.isBlockFiller(o)))}const Da=ma(t.document),Ba=ua(t.document),Sa=ha(t.document),Ta="data-ck-unsafe-attribute-",Ia="data-ck-unsafe-element";class Pa{constructor(e,{blockFillerMode:o,renderingMode:n="editing"}={}){this._domToViewMapping=new WeakMap,this._viewToDomMapping=new WeakMap,this._fakeSelectionMapping=new WeakMap,this._rawContentElementMatcher=new Hr,this._inlineObjectElementMatcher=new Hr,this._elementsWithTemporaryCustomProperties=new Set,this.document=e,this.renderingMode=n,this.blockFillerMode=o||("editing"===n?"br":"nbsp"),this.preElements=["pre"],this.blockElements=["address","article","aside","blockquote","caption","center","dd","details","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","legend","li","main","menu","nav","ol","p","pre","section","summary","table","tbody","td","tfoot","th","thead","tr","ul"],this.inlineObjectElements=["object","iframe","input","button","textarea","select","option","video","embed","audio","img","canvas"],this.unsafeElements=["script","style"],this._domDocument="editing"===this.renderingMode?t.document:t.document.implementation.createHTMLDocument("")}bindFakeSelection(e,t){this._fakeSelectionMapping.set(e,new Ps(t))}fakeSelectionToView(e){return this._fakeSelectionMapping.get(e)}bindElements(e,t){this._domToViewMapping.set(e,t),this._viewToDomMapping.set(t,e)}unbindDomElement(e){const t=this._domToViewMapping.get(e);if(t){this._domToViewMapping.delete(e),this._viewToDomMapping.delete(t);for(const t of Array.from(e.children))this.unbindDomElement(t)}}bindDocumentFragments(e,t){this._domToViewMapping.set(e,t),this._viewToDomMapping.set(t,e)}shouldRenderAttribute(e,t,o){return"data"===this.renderingMode||!(e=e.toLowerCase()).startsWith("on")&&(("srcdoc"!==e||!t.match(/\bon\S+\s*=|javascript:|<\s*\/*script/i))&&("img"===o&&("src"===e||"srcset"===e)||("source"===o&&"srcset"===e||!t.match(/^\s*(javascript:|data:(image\/svg|text\/x?html))/i))))}setContentOf(e,t){if("data"===this.renderingMode)return void(e.innerHTML=t);const o=(new DOMParser).parseFromString(t,"text/html"),n=o.createDocumentFragment(),i=o.body.childNodes;for(;i.length>0;)n.appendChild(i[0]);const r=o.createTreeWalker(n,NodeFilter.SHOW_ELEMENT),s=[];let a;for(;a=r.nextNode();)s.push(a);for(const e of s){for(const t of e.getAttributeNames())this.setDomElementAttribute(e,t,e.getAttribute(t));const t=e.tagName.toLowerCase();this._shouldRenameElement(t)&&(Ra(t),e.replaceWith(this._createReplacementDomElement(t,e)))}for(;e.firstChild;)e.firstChild.remove();e.append(n)}viewToDom(e,t={}){if(e.is("$text")){const t=this._processDataFromViewText(e);return this._domDocument.createTextNode(t)}{const o=e;if(this.mapViewToDom(o)){if(!o.getCustomProperty("editingPipeline:doNotReuseOnce"))return this.mapViewToDom(o);this._elementsWithTemporaryCustomProperties.add(o)}let n;if(o.is("documentFragment"))n=this._domDocument.createDocumentFragment(),t.bind&&this.bindDocumentFragments(n,o);else{if(o.is("uiElement"))return n="$comment"===o.name?this._domDocument.createComment(o.getCustomProperty("$rawContent")):o.render(this._domDocument,this),t.bind&&this.bindElements(n,o),n;this._shouldRenameElement(o.name)?(Ra(o.name),n=this._createReplacementDomElement(o.name)):n=o.hasAttribute("xmlns")?this._domDocument.createElementNS(o.getAttribute("xmlns"),o.name):this._domDocument.createElement(o.name),o.is("rawElement")&&o.render(n,this),t.bind&&this.bindElements(n,o);for(const e of o.getAttributeKeys())this.setDomElementAttribute(n,e,o.getAttribute(e),o)}if(!1!==t.withChildren)for(const e of this.viewChildrenToDom(o,t))n instanceof HTMLTemplateElement?n.content.appendChild(e):n.appendChild(e);return n}}setDomElementAttribute(e,o,n,i){const r=this.shouldRenderAttribute(o,n,e.tagName.toLowerCase())||i&&i.shouldRenderUnsafeAttribute(o);r||D("domconverter-unsafe-attribute-detected",{domElement:e,key:o,value:n}),function(e){try{t.document.createAttribute(e)}catch(e){return!1}return!0}(o)?(e.hasAttribute(o)&&!r?e.removeAttribute(o):e.hasAttribute(Ta+o)&&r&&e.removeAttribute(Ta+o),e.setAttribute(r?o:Ta+o,n)):D("domconverter-invalid-attribute-detected",{domElement:e,key:o,value:n})}removeDomElementAttribute(e,t){t!=Ia&&(e.removeAttribute(t),e.removeAttribute(Ta+t))}*viewChildrenToDom(e,t={}){const o=e.getFillerOffset&&e.getFillerOffset();let n=0;for(const i of e.getChildren()){o===n&&(yield this._getBlockFiller());const e=i.is("element")&&!!i.getCustomProperty("dataPipeline:transparentRendering")&&!Qi(i.getAttributes());if(e&&"data"==this.renderingMode)if(i.is("rawElement")){const e=this._domDocument.createElement(i.name);i.render(e,this),yield*[...e.childNodes]}else yield*this.viewChildrenToDom(i,t);else e&&D("domconverter-transparent-rendering-unsupported-in-editing-pipeline",{viewElement:i}),yield this.viewToDom(i,t);n++}o===n&&(yield this._getBlockFiller())}viewRangeToDom(e){const t=this.viewPositionToDom(e.start),o=this.viewPositionToDom(e.end),n=this._domDocument.createRange();return n.setStart(t.parent,t.offset),n.setEnd(o.parent,o.offset),n}viewPositionToDom(e){const t=e.parent;if(t.is("$text")){const o=this.findCorrespondingDomText(t);if(!o)return null;let n=e.offset;return fa(o)&&(n+=pa),{parent:o,offset:n}}{let o,n,i;if(0===e.offset){if(o=this.mapViewToDom(t),!o)return null;i=o.childNodes[0]}else{const t=e.nodeBefore;if(n=t.is("$text")?this.findCorrespondingDomText(t):this.mapViewToDom(t),!n)return null;o=n.parentNode,i=n.nextSibling}if(Nn(i)&&fa(i))return{parent:i,offset:pa};return{parent:o,offset:n?Qn(n)+1:0}}}domToView(e,t={}){const o=[],n=this._domToView(e,t,o),i=n.next().value;return i?(n.next(),this._processDomInlineNodes(null,o,t),i.is("$text")&&0==i.data.length?null:i):null}*domChildrenToView(e,t={},o=[]){let n=[];n=e instanceof HTMLTemplateElement?[...e.content.childNodes]:[...e.childNodes];for(let i=0;i{const{scrollLeft:t,scrollTop:o}=e;i.push([t,o])})),o.focus(),Fa(o,(e=>{const[t,o]=i.shift();e.scrollLeft=t,e.scrollTop=o})),t.window.scrollTo(e,n)}}_clearDomSelection(){const e=this.mapViewToDom(this.document.selection.editableElement);if(!e)return;const t=e.ownerDocument.defaultView.getSelection(),o=this.domSelectionToView(t);o&&o.rangeCount>0&&t.removeAllRanges()}isElement(e){return e&&e.nodeType==Node.ELEMENT_NODE}isDocumentFragment(e){return e&&e.nodeType==Node.DOCUMENT_FRAGMENT_NODE}isBlockFiller(e){return"br"==this.blockFillerMode?e.isEqualNode(Da):!("BR"!==e.tagName||!Ma(e,this.blockElements)||1!==e.parentNode.childNodes.length)||(e.isEqualNode(Sa)||function(e,t){const o=e.isEqualNode(Ba);return o&&Ma(e,t)&&1===e.parentNode.childNodes.length}(e,this.blockElements))}isDomSelectionBackward(e){if(e.isCollapsed)return!1;const t=this._domDocument.createRange();try{t.setStart(e.anchorNode,e.anchorOffset),t.setEnd(e.focusNode,e.focusOffset)}catch(e){return!1}const o=t.collapsed;return t.detach(),o}getHostViewElement(e){const t=function(e){const t=[];let o=e;for(;o&&o.nodeType!=Node.DOCUMENT_NODE;)t.unshift(o),o=o.parentNode;return t}(e);for(t.pop();t.length;){const e=t.pop(),o=this._domToViewMapping.get(e);if(o&&(o.is("uiElement")||o.is("rawElement")))return o}return null}isDomSelectionCorrect(e){return this._isDomSelectionPositionCorrect(e.anchorNode,e.anchorOffset)&&this._isDomSelectionPositionCorrect(e.focusNode,e.focusOffset)}registerRawContentMatcher(e){this._rawContentElementMatcher.add(e)}registerInlineObjectMatcher(e){this._inlineObjectElementMatcher.add(e)}_clearTemporaryCustomProperties(){for(const e of this._elementsWithTemporaryCustomProperties)e._removeCustomProperty("editingPipeline:doNotReuseOnce");this._elementsWithTemporaryCustomProperties.clear()}_getBlockFiller(){switch(this.blockFillerMode){case"nbsp":return ua(this._domDocument);case"markedNbsp":return ha(this._domDocument);case"br":return ma(this._domDocument)}}_isDomSelectionPositionCorrect(e,t){if(Nn(e)&&fa(e)&&t0?t[e-1]:null,l=e+1e.is("element")&&t.includes(e.name)))}(e,this.preElements))return!0;for(const t of e.getAncestors({parentFirst:!0}))if(t.is("element")&&t.hasStyle("white-space")&&"inherit"!==t.getStyle("white-space"))return["pre","pre-wrap","break-spaces"].includes(t.getStyle("white-space"));return!1}_getTouchingInlineViewNode(e,t){const o=new Bs({startPosition:t?Ss._createAfter(e):Ss._createBefore(e),direction:t?"forward":"backward"});for(const{item:e}of o){if(e.is("$textProxy"))return e;if(!e.is("element")||!e.getCustomProperty("dataPipeline:transparentRendering")){if(e.is("element","br"))return null;if(this._isInlineObjectElement(e))return e;if(e.is("containerElement"))return null}}return null}_isBlockDomElement(e){return this.isElement(e)&&this.blockElements.includes(e.tagName.toLowerCase())}_isBlockViewElement(e){return e.is("element")&&this.blockElements.includes(e.name)}_isInlineObjectElement(e){return!!e.is("element")&&("br"==e.name||this.inlineObjectElements.includes(e.name)||!!this._inlineObjectElementMatcher.match(e))}_createViewElement(e,t){if(ei(e))return new Ks(this.document,"$comment");const o=t.keepOriginalCase?e.tagName:e.tagName.toLowerCase();return new ys(this.document,o)}_isViewElementWithRawContent(e,t){return!1!==t.withChildren&&e.is("element")&&!!this._rawContentElementMatcher.match(e)}_shouldRenameElement(e){const t=e.toLowerCase();return"editing"===this.renderingMode&&this.unsafeElements.includes(t)}_createReplacementDomElement(e,t){const o=this._domDocument.createElement("span");if(o.setAttribute(Ia,e),t){for(;t.firstChild;)o.appendChild(t.firstChild);for(const e of t.getAttributeNames())o.setAttribute(e,t.getAttribute(e))}return o}}function Fa(e,t){let o=e;for(;o;)t(o),o=o.parentElement}function Ma(e,t){const o=e.parentNode;return!!o&&!!o.tagName&&t.includes(o.tagName.toLowerCase())}function Ra(e){"script"===e&&D("domconverter-unsafe-script-element-detected"),"style"===e&&D("domconverter-unsafe-style-element-detected")}class za extends(Rn()){constructor(e){super(),this._isEnabled=!1,this.view=e,this.document=e.document}get isEnabled(){return this._isEnabled}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}destroy(){this.disable(),this.stopListening()}checkShouldIgnoreEventFromTarget(e){return e&&3===e.nodeType&&(e=e.parentNode),!(!e||1!==e.nodeType)&&e.matches("[data-cke-ignore-events], [data-cke-ignore-events] *")}}var Va=Ui((function(e,t){Mt(t,ko(t),e)}));const Oa=Va;class Na{constructor(e,t,o){this.view=e,this.document=e.document,this.domEvent=t,this.domTarget=t.target,Oa(this,o)}get target(){return this.view.domConverter.mapDomToView(this.domTarget)}preventDefault(){this.domEvent.preventDefault()}stopPropagation(){this.domEvent.stopPropagation()}}class La extends za{constructor(){super(...arguments),this.useCapture=!1}observe(e){("string"==typeof this.domEventType?[this.domEventType]:this.domEventType).forEach((t=>{this.listenTo(e,t,((e,t)=>{this.isEnabled&&!this.checkShouldIgnoreEventFromTarget(t.target)&&this.onDomEvent(t)}),{useCapture:this.useCapture})}))}stopObserving(e){this.stopListening(e)}fire(e,t,o){this.isEnabled&&this.document.fire(e,new Na(this.view,t,o))}}class Ha extends La{constructor(){super(...arguments),this.domEventType=["keydown","keyup"]}onDomEvent(e){const t={keyCode:e.keyCode,altKey:e.altKey,ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,metaKey:e.metaKey,get keystroke(){return _i(this)}};this.fire(e.type,e,t)}}const ja=function(){return le.Date.now()};var qa=/\s/;const Ua=function(e){for(var t=e.length;t--&&qa.test(e.charAt(t)););return t};var Wa=/^\s+/;const $a=function(e){return e?e.slice(0,Ua(e)+1).replace(Wa,""):e};var Ga=/^[-+]0x[0-9a-f]+$/i,Ka=/^0b[01]+$/i,Za=/^0o[0-7]+$/i,Ja=parseInt;const Ya=function(e){if("number"==typeof e)return e;if(Ur(e))return NaN;if(U(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=U(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=$a(e);var o=Ka.test(e);return o||Za.test(e)?Ja(e.slice(2),o?2:8):Ga.test(e)?NaN:+e};var Qa=Math.max,Xa=Math.min;const el=function(e,t,o){var n,i,r,s,a,l,c=0,d=!1,u=!1,h=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function m(t){var o=n,r=i;return n=i=void 0,c=t,s=e.apply(r,o)}function p(e){var o=e-l;return void 0===l||o>=t||o<0||u&&e-c>=r}function g(){var e=ja();if(p(e))return f(e);a=setTimeout(g,function(e){var o=t-(e-l);return u?Xa(o,r-(e-c)):o}(e))}function f(e){return a=void 0,h&&n?m(e):(n=i=void 0,s)}function b(){var e=ja(),o=p(e);if(n=arguments,i=this,l=e,o){if(void 0===a)return function(e){return c=e,a=setTimeout(g,t),d?m(e):s}(l);if(u)return clearTimeout(a),a=setTimeout(g,t),m(l)}return void 0===a&&(a=setTimeout(g,t)),s}return t=Ya(t)||0,U(o)&&(d=!!o.leading,r=(u="maxWait"in o)?Qa(Ya(o.maxWait)||0,t):r,h="trailing"in o?!!o.trailing:h),b.cancel=function(){void 0!==a&&clearTimeout(a),c=0,n=l=i=a=void 0},b.flush=function(){return void 0===a?s:f(ja())},b};class tl extends za{constructor(e){super(e),this._fireSelectionChangeDoneDebounced=el((e=>{this.document.fire("selectionChangeDone",e)}),200)}observe(){const e=this.document;e.on("arrowKey",((t,o)=>{e.selection.isFake&&this.isEnabled&&o.preventDefault()}),{context:"$capture"}),e.on("arrowKey",((t,o)=>{e.selection.isFake&&this.isEnabled&&this._handleSelectionMove(o.keyCode)}),{priority:"lowest"})}stopObserving(){}destroy(){super.destroy(),this._fireSelectionChangeDoneDebounced.cancel()}_handleSelectionMove(e){const t=this.document.selection,o=new Ps(t.getRanges(),{backward:t.isBackward,fake:!1});e!=ki.arrowleft&&e!=ki.arrowup||o.setTo(o.getFirstPosition()),e!=ki.arrowright&&e!=ki.arrowdown||o.setTo(o.getLastPosition());const n={oldSelection:t,newSelection:o,domSelection:null};this.document.fire("selectionChange",n),this._fireSelectionChangeDoneDebounced(n)}}const ol=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this};const nl=function(e){return this.__data__.has(e)};function il(e){var t=-1,o=null==e?0:e.length;for(this.__data__=new xt;++ta))return!1;var c=r.get(e),d=r.get(t);if(c&&d)return c==t&&d==e;var u=-1,h=!0,m=2&o?new rl:void 0;for(r.set(e,t),r.set(t,e);++uthis._handleFocus())),t.on("blur",((e,t)=>this._handleBlur(t))),t.on("beforeinput",(()=>{t.isFocused||this._handleFocus()}),{priority:"highest"})}flush(){this._isFocusChanging&&(this._isFocusChanging=!1,this.document.isFocused=!0)}onDomEvent(e){this.fire(e.type,e)}destroy(){this._clearTimeout(),super.destroy()}_handleFocus(){this._clearTimeout(),this._isFocusChanging=!0,this._renderTimeoutId=setTimeout((()=>{this._renderTimeoutId=null,this.flush(),this.view.change((()=>{}))}),50)}_handleBlur(e){const t=this.document.selection.editableElement;null!==t&&t!==e.target||(this.document.isFocused=!1,this._isFocusChanging=!1,this.view.change((()=>{})))}_clearTimeout(){this._renderTimeoutId&&(clearTimeout(this._renderTimeoutId),this._renderTimeoutId=null)}}class El extends za{constructor(e){super(e),this.mutationObserver=e.getObserver(Cl),this.focusObserver=e.getObserver(xl),this.selection=this.document.selection,this.domConverter=e.domConverter,this._documents=new WeakSet,this._fireSelectionChangeDoneDebounced=el((e=>{this.document.fire("selectionChangeDone",e)}),200),this._clearInfiniteLoopInterval=setInterval((()=>this._clearInfiniteLoop()),1e3),this._documentIsSelectingInactivityTimeoutDebounced=el((()=>this.document.isSelecting=!1),5e3),this._loopbackCounter=0}observe(e){const t=e.ownerDocument,o=()=>{this.document.isSelecting&&(this._handleSelectionChange(t),this.document.isSelecting=!1,this._documentIsSelectingInactivityTimeoutDebounced.cancel())};this.listenTo(e,"selectstart",(()=>{this.document.isSelecting=!0,this._documentIsSelectingInactivityTimeoutDebounced()}),{priority:"highest"}),this.listenTo(e,"keydown",o,{priority:"highest",useCapture:!0}),this.listenTo(e,"keyup",o,{priority:"highest",useCapture:!0}),this._documents.has(t)||(this.listenTo(t,"mouseup",o,{priority:"highest",useCapture:!0}),this.listenTo(t,"selectionchange",((e,o)=>{this.document.isComposing&&!r.isAndroid||(this._handleSelectionChange(t),this._documentIsSelectingInactivityTimeoutDebounced())})),this.listenTo(this.view.document,"compositionstart",(()=>{this._handleSelectionChange(t)}),{priority:"lowest"}),this._documents.add(t))}stopObserving(e){this.stopListening(e)}destroy(){super.destroy(),clearInterval(this._clearInfiniteLoopInterval),this._fireSelectionChangeDoneDebounced.cancel(),this._documentIsSelectingInactivityTimeoutDebounced.cancel()}_reportInfiniteLoop(){}_handleSelectionChange(e){if(!this.isEnabled)return;const t=e.defaultView.getSelection();if(this.checkShouldIgnoreEventFromTarget(t.anchorNode))return;this.mutationObserver.flush();const o=this.domConverter.domSelectionToView(t);if(0!=o.rangeCount){if(this.view.hasDomSelection=!0,this.focusObserver.flush(),!this.selection.isEqual(o)||!this.domConverter.isDomSelectionCorrect(t))if(++this._loopbackCounter>60)this._reportInfiniteLoop();else if(this.selection.isSimilar(o))this.view.forceRender();else{const e={oldSelection:this.selection,newSelection:o,domSelection:t};this.document.fire("selectionChange",e),this._fireSelectionChangeDoneDebounced(e)}}else this.view.hasDomSelection=!1}_clearInfiniteLoop(){this._loopbackCounter=0}}class Dl extends La{constructor(e){super(e),this.domEventType=["compositionstart","compositionupdate","compositionend"];const t=this.document;t.on("compositionstart",(()=>{t.isComposing=!0}),{priority:"low"}),t.on("compositionend",(()=>{t.isComposing=!1}),{priority:"low"})}onDomEvent(e){this.fire(e.type,e,{data:e.data})}}class Bl{constructor(e,t={}){this._files=t.cacheFiles?Sl(e):null,this._native=e}get files(){return this._files||(this._files=Sl(this._native)),this._files}get types(){return this._native.types}getData(e){return this._native.getData(e)}setData(e,t){this._native.setData(e,t)}set effectAllowed(e){this._native.effectAllowed=e}get effectAllowed(){return this._native.effectAllowed}set dropEffect(e){this._native.dropEffect=e}get dropEffect(){return this._native.dropEffect}setDragImage(e,t,o){this._native.setDragImage(e,t,o)}get isCanceled(){return"none"==this._native.dropEffect||!!this._native.mozUserCancelled}}function Sl(e){const t=Array.from(e.files||[]),o=Array.from(e.items||[]);return t.length?t:o.filter((e=>"file"===e.kind)).map((e=>e.getAsFile()))}class Tl extends La{constructor(){super(...arguments),this.domEventType="beforeinput"}onDomEvent(e){const t=e.getTargetRanges(),o=this.view,n=o.document;let i=null,s=null,a=[];if(e.dataTransfer&&(i=new Bl(e.dataTransfer)),null!==e.data?s=e.data:i&&(s=i.getData("text/plain")),n.selection.isFake)a=Array.from(n.selection.getRanges());else if(t.length)a=t.map((e=>{const t=o.domConverter.domPositionToView(e.startContainer,e.startOffset),n=o.domConverter.domPositionToView(e.endContainer,e.endOffset);return t?o.createRange(t,n):n?o.createRange(n):void 0})).filter((e=>!!e));else if(r.isAndroid){const t=e.target.ownerDocument.defaultView.getSelection();a=Array.from(o.domConverter.domSelectionToView(t).getRanges())}if(r.isAndroid&&"insertCompositionText"==e.inputType&&s&&s.endsWith("\n"))this.fire(e.type,e,{inputType:"insertParagraph",targetRanges:[o.createRange(a[0].end)]});else if("insertText"==e.inputType&&s&&s.includes("\n")){const t=s.split(/\n{1,2}/g);let o=a;for(let r=0;r{if(this.isEnabled&&((o=t.keyCode)==ki.arrowright||o==ki.arrowleft||o==ki.arrowup||o==ki.arrowdown)){const o=new Ms(this.document,"arrowKey",this.document.selection.getFirstRange());this.document.fire(o,t),o.stop.called&&e.stop()}var o}))}observe(){}stopObserving(){}}class Pl extends za{constructor(e){super(e);const t=this.document;t.on("keydown",((e,o)=>{if(!this.isEnabled||o.keyCode!=ki.tab||o.ctrlKey)return;const n=new Ms(t,"tab",t.selection.getFirstRange());t.fire(n,o),n.stop.called&&e.stop()}))}observe(){}stopObserving(){}}const Fl=function(e){return En(e,5)};class Ml extends(Y()){constructor(e){super(),this.domRoots=new Map,this._initialDomRootAttributes=new WeakMap,this._observers=new Map,this._ongoingChange=!1,this._postFixersInProgress=!1,this._renderingDisabled=!1,this._hasChangedSinceTheLastRendering=!1,this.document=new Hs(e),this.domConverter=new Pa(this.document),this.set("isRenderingInProgress",!1),this.set("hasDomSelection",!1),this._renderer=new Aa(this.domConverter,this.document.selection),this._renderer.bind("isFocused","isSelecting","isComposing").to(this.document,"isFocused","isSelecting","isComposing"),this._writer=new ea(this.document),this.addObserver(Cl),this.addObserver(xl),this.addObserver(El),this.addObserver(Ha),this.addObserver(tl),this.addObserver(Dl),this.addObserver(Il),this.addObserver(Tl),this.addObserver(Pl),this.document.on("arrowKey",wa,{priority:"low"}),Zs(this),this.on("render",(()=>{this._render(),this.document.fire("layoutChanged"),this._hasChangedSinceTheLastRendering=!1})),this.listenTo(this.document.selection,"change",(()=>{this._hasChangedSinceTheLastRendering=!0})),this.listenTo(this.document,"change:isFocused",(()=>{this._hasChangedSinceTheLastRendering=!0})),r.isiOS&&this.listenTo(this.document,"blur",((e,t)=>{this.domConverter.mapDomToView(t.domEvent.relatedTarget)||this.domConverter._clearDomSelection()})),this.listenTo(this.document,"mutations",((e,{mutations:t})=>{t.forEach((e=>this._renderer.markToSync(e.type,e.node)))}),{priority:"low"}),this.listenTo(this.document,"mutations",(()=>{this.forceRender()}),{priority:"lowest"})}attachDomRoot(e,t="main"){const o=this.document.getRoot(t);o._name=e.tagName.toLowerCase();const n={};for(const{name:t,value:i}of Array.from(e.attributes))n[t]=i,"class"===t?this._writer.addClass(i.split(" "),o):this._writer.setAttribute(t,i,o);this._initialDomRootAttributes.set(e,n);const i=()=>{this._writer.setAttribute("contenteditable",(!o.isReadOnly).toString(),o),o.isReadOnly?this._writer.addClass("ck-read-only",o):this._writer.removeClass("ck-read-only",o)};i(),this.domRoots.set(t,e),this.domConverter.bindElements(e,o),this._renderer.markToSync("children",o),this._renderer.markToSync("attributes",o),this._renderer.domDocuments.add(e.ownerDocument),o.on("change:children",((e,t)=>this._renderer.markToSync("children",t))),o.on("change:attributes",((e,t)=>this._renderer.markToSync("attributes",t))),o.on("change:text",((e,t)=>this._renderer.markToSync("text",t))),o.on("change:isReadOnly",(()=>this.change(i))),o.on("change",(()=>{this._hasChangedSinceTheLastRendering=!0}));for(const o of this._observers.values())o.observe(e,t)}detachDomRoot(e){const t=this.domRoots.get(e);Array.from(t.attributes).forEach((({name:e})=>t.removeAttribute(e)));const o=this._initialDomRootAttributes.get(t);for(const e in o)t.setAttribute(e,o[e]);this.domRoots.delete(e),this.domConverter.unbindDomElement(t);for(const e of this._observers.values())e.stopObserving(t)}getDomRoot(e="main"){return this.domRoots.get(e)}addObserver(e){let t=this._observers.get(e);if(t)return t;t=new e(this),this._observers.set(e,t);for(const[e,o]of this.domRoots)t.observe(o,e);return t.enable(),t}getObserver(e){return this._observers.get(e)}disableObservers(){for(const e of this._observers.values())e.disable()}enableObservers(){for(const e of this._observers.values())e.enable()}scrollToTheSelection({alignToTop:e,forceScroll:t,viewportOffset:o=20,ancestorOffset:n=20}={}){const i=this.document.selection.getFirstRange();if(!i)return;const r=Fl({alignToTop:e,forceScroll:t,viewportOffset:o,ancestorOffset:n});"number"==typeof o&&(o={top:o,bottom:o,left:o,right:o});const s={target:this.domConverter.viewRangeToDom(i),viewportOffset:o,ancestorOffset:n,alignToTop:e,forceScroll:t};this.fire("scrollToTheSelection",s,r),function({target:e,viewportOffset:t=0,ancestorOffset:o=0,alignToTop:n,forceScroll:i}){const r=hi(e);let s=r,a=null;for(t=function(e){return"number"==typeof e?{top:e,bottom:e,left:e,right:e}:e}(t);s;){let l;l=mi(s==r?e:a),ai({parent:l,getRect:()=>pi(e,s),alignToTop:n,ancestorOffset:o,forceScroll:i});const c=pi(e,s);if(si({window:s,rect:c,viewportOffset:t,alignToTop:n,forceScroll:i}),s.parent!=s){if(a=s.frameElement,s=s.parent,!a)return}else s=null}}(s)}focus(){if(!this.document.isFocused){const e=this.document.selection.editableElement;e&&(this.domConverter.focus(e),this.forceRender())}}change(e){if(this.isRenderingInProgress||this._postFixersInProgress)throw new E("cannot-change-view-tree",this);try{if(this._ongoingChange)return e(this._writer);this._ongoingChange=!0;const t=e(this._writer);return this._ongoingChange=!1,!this._renderingDisabled&&this._hasChangedSinceTheLastRendering&&(this._postFixersInProgress=!0,this.document._callPostFixers(this._writer),this._postFixersInProgress=!1,this.fire("render")),t}catch(e){E.rethrowUnexpectedError(e,this)}}forceRender(){this._hasChangedSinceTheLastRendering=!0,this.getObserver(xl).flush(),this.change((()=>{}))}destroy(){for(const e of this._observers.values())e.destroy();this.document.destroy(),this.stopListening()}createPositionAt(e,t){return Ss._createAt(e,t)}createPositionAfter(e){return Ss._createAfter(e)}createPositionBefore(e){return Ss._createBefore(e)}createRange(e,t){return new Ts(e,t)}createRangeOn(e){return Ts._createOn(e)}createRangeIn(e){return Ts._createIn(e)}createSelection(...e){return new Ps(...e)}_disableRendering(e){this._renderingDisabled=e,0==e&&this.change((()=>{}))}_render(){this.isRenderingInProgress=!0,this.disableObservers(),this._renderer.render(),this.enableObservers(),this.isRenderingInProgress=!1}}class Rl{is(){throw new Error("is() method is abstract")}}class zl extends Rl{constructor(e){super(),this.parent=null,this._attrs=tr(e)}get document(){return null}get index(){let e;if(!this.parent)return null;if(null===(e=this.parent.getChildIndex(this)))throw new E("model-node-not-found-in-parent",this);return e}get startOffset(){let e;if(!this.parent)return null;if(null===(e=this.parent.getChildStartOffset(this)))throw new E("model-node-not-found-in-parent",this);return e}get offsetSize(){return 1}get endOffset(){return this.parent?this.startOffset+this.offsetSize:null}get nextSibling(){const e=this.index;return null!==e&&this.parent.getChild(e+1)||null}get previousSibling(){const e=this.index;return null!==e&&this.parent.getChild(e-1)||null}get root(){let e=this;for(;e.parent;)e=e.parent;return e}isAttached(){return null!==this.parent&&this.root.isAttached()}getPath(){const e=[];let t=this;for(;t.parent;)e.unshift(t.startOffset),t=t.parent;return e}getAncestors(e={}){const t=[];let o=e.includeSelf?this:this.parent;for(;o;)t[e.parentFirst?"push":"unshift"](o),o=o.parent;return t}getCommonAncestor(e,t={}){const o=this.getAncestors(t),n=e.getAncestors(t);let i=0;for(;o[i]==n[i]&&o[i];)i++;return 0===i?null:o[i-1]}isBefore(e){if(this==e)return!1;if(this.root!==e.root)return!1;const t=this.getPath(),o=e.getPath(),n=ie(t,o);switch(n){case"prefix":return!0;case"extension":return!1;default:return t[n](e[t[0]]=t[1],e)),{})),e}_clone(e){return new this.constructor(this._attrs)}_remove(){this.parent._removeChildren(this.index)}_setAttribute(e,t){this._attrs.set(e,t)}_setAttributesTo(e){this._attrs=tr(e)}_removeAttribute(e){return this._attrs.delete(e)}_clearAttributes(){this._attrs.clear()}}zl.prototype.is=function(e){return"node"===e||"model:node"===e};class Vl{constructor(e){this._nodes=[],e&&this._insertNodes(0,e)}[Symbol.iterator](){return this._nodes[Symbol.iterator]()}get length(){return this._nodes.length}get maxOffset(){return this._nodes.reduce(((e,t)=>e+t.offsetSize),0)}getNode(e){return this._nodes[e]||null}getNodeIndex(e){const t=this._nodes.indexOf(e);return-1==t?null:t}getNodeStartOffset(e){const t=this.getNodeIndex(e);return null===t?null:this._nodes.slice(0,t).reduce(((e,t)=>e+t.offsetSize),0)}indexToOffset(e){if(e==this._nodes.length)return this.maxOffset;const t=this._nodes[e];if(!t)throw new E("model-nodelist-index-out-of-bounds",this);return this.getNodeStartOffset(t)}offsetToIndex(e){let t=0;for(const o of this._nodes){if(e>=t&&e1e4)return e.slice(0,o).concat(t).concat(e.slice(o+n,e.length));{const i=Array.from(e);return i.splice(o,n,...t),i}}(this._nodes,Array.from(t),e,0)}_removeNodes(e,t=1){return this._nodes.splice(e,t)}toJSON(){return this._nodes.map((e=>e.toJSON()))}}class Ol extends zl{constructor(e,t){super(t),this._data=e||""}get offsetSize(){return this.data.length}get data(){return this._data}toJSON(){const e=super.toJSON();return e.data=this.data,e}_clone(){return new Ol(this.data,this.getAttributes())}static fromJSON(e){return new Ol(e.data,e.attributes)}}Ol.prototype.is=function(e){return"$text"===e||"model:$text"===e||"text"===e||"model:text"===e||"node"===e||"model:node"===e};class Nl extends Rl{constructor(e,t,o){if(super(),this.textNode=e,t<0||t>e.offsetSize)throw new E("model-textproxy-wrong-offsetintext",this);if(o<0||t+o>e.offsetSize)throw new E("model-textproxy-wrong-length",this);this.data=e.data.substring(t,t+o),this.offsetInText=t}get startOffset(){return null!==this.textNode.startOffset?this.textNode.startOffset+this.offsetInText:null}get offsetSize(){return this.data.length}get endOffset(){return null!==this.startOffset?this.startOffset+this.offsetSize:null}get isPartial(){return this.offsetSize!==this.textNode.offsetSize}get parent(){return this.textNode.parent}get root(){return this.textNode.root}getPath(){const e=this.textNode.getPath();return e.length>0&&(e[e.length-1]+=this.offsetInText),e}getAncestors(e={}){const t=[];let o=e.includeSelf?this:this.parent;for(;o;)t[e.parentFirst?"push":"unshift"](o),o=o.parent;return t}hasAttribute(e){return this.textNode.hasAttribute(e)}getAttribute(e){return this.textNode.getAttribute(e)}getAttributes(){return this.textNode.getAttributes()}getAttributeKeys(){return this.textNode.getAttributeKeys()}}Nl.prototype.is=function(e){return"$textProxy"===e||"model:$textProxy"===e||"textProxy"===e||"model:textProxy"===e};class Ll extends zl{constructor(e,t,o){super(t),this._children=new Vl,this.name=e,o&&this._insertChild(0,o)}get childCount(){return this._children.length}get maxOffset(){return this._children.maxOffset}get isEmpty(){return 0===this.childCount}getChild(e){return this._children.getNode(e)}getChildren(){return this._children[Symbol.iterator]()}getChildIndex(e){return this._children.getNodeIndex(e)}getChildStartOffset(e){return this._children.getNodeStartOffset(e)}offsetToIndex(e){return this._children.offsetToIndex(e)}getNodeByPath(e){let t=this;for(const o of e)t=t.getChild(t.offsetToIndex(o));return t}findAncestor(e,t={}){let o=t.includeSelf?this:this.parent;for(;o;){if(o.name===e)return o;o=o.parent}return null}toJSON(){const e=super.toJSON();if(e.name=this.name,this._children.length>0){e.children=[];for(const t of this._children)e.children.push(t.toJSON())}return e}_clone(e=!1){const t=e?Array.from(this._children).map((e=>e._clone(!0))):void 0;return new Ll(this.name,this.getAttributes(),t)}_appendChild(e){this._insertChild(this.childCount,e)}_insertChild(e,t){const o=function(e){if("string"==typeof e)return[new Ol(e)];re(e)||(e=[e]);return Array.from(e).map((e=>"string"==typeof e?new Ol(e):e instanceof Nl?new Ol(e.data,e.getAttributes()):e))}(t);for(const e of o)null!==e.parent&&e._remove(),e.parent=this;this._children._insertNodes(e,o)}_removeChildren(e,t=1){const o=this._children._removeNodes(e,t);for(const e of o)e.parent=null;return o}static fromJSON(e){let t;if(e.children){t=[];for(const o of e.children)o.name?t.push(Ll.fromJSON(o)):t.push(Ol.fromJSON(o))}return new Ll(e.name,e.attributes,t)}}Ll.prototype.is=function(e,t){return t?t===this.name&&("element"===e||"model:element"===e):"element"===e||"model:element"===e||"node"===e||"model:node"===e};class Hl{constructor(e){if(!e||!e.boundaries&&!e.startPosition)throw new E("model-tree-walker-no-start-position",null);const t=e.direction||"forward";if("forward"!=t&&"backward"!=t)throw new E("model-tree-walker-unknown-direction",e,{direction:t});this.direction=t,this.boundaries=e.boundaries||null,e.startPosition?this._position=e.startPosition.clone():this._position=ql._createAt(this.boundaries["backward"==this.direction?"end":"start"]),this.position.stickiness="toNone",this.singleCharacters=!!e.singleCharacters,this.shallow=!!e.shallow,this.ignoreElementEnd=!!e.ignoreElementEnd,this._boundaryStartParent=this.boundaries?this.boundaries.start.parent:null,this._boundaryEndParent=this.boundaries?this.boundaries.end.parent:null,this._visitedParent=this.position.parent}[Symbol.iterator](){return this}get position(){return this._position}skip(e){let t,o,n,i;do{n=this.position,i=this._visitedParent,({done:t,value:o}=this.next())}while(!t&&e(o));t||(this._position=n,this._visitedParent=i)}next(){return"forward"==this.direction?this._next():this._previous()}_next(){const e=this.position,t=this.position.clone(),o=this._visitedParent;if(null===o.parent&&t.offset===o.maxOffset)return{done:!0,value:void 0};if(o===this._boundaryEndParent&&t.offset==this.boundaries.end.offset)return{done:!0,value:void 0};const n=Ul(t,o),i=n||Wl(t,o,n);if(i instanceof Ll){if(this.shallow){if(this.boundaries&&this.boundaries.end.isBefore(t))return{done:!0,value:void 0};t.offset++}else t.path.push(0),this._visitedParent=i;return this._position=t,jl("elementStart",i,e,t,1)}if(i instanceof Ol){let n;if(this.singleCharacters)n=1;else{let e=i.endOffset;this._boundaryEndParent==o&&this.boundaries.end.offsete&&(e=this.boundaries.start.offset),n=t.offset-e}const i=t.offset-r.startOffset,s=new Nl(r,i-n,n);return t.offset-=n,this._position=t,jl("text",s,e,t,n)}return t.path.pop(),this._position=t,this._visitedParent=o.parent,jl("elementStart",o,e,t,1)}}function jl(e,t,o,n,i){return{done:!1,value:{type:e,item:t,previousPosition:o,nextPosition:n,length:i}}}class ql extends Rl{constructor(e,t,o="toNone"){if(super(),!e.is("element")&&!e.is("documentFragment"))throw new E("model-position-root-invalid",e);if(!(t instanceof Array)||0===t.length)throw new E("model-position-path-incorrect-format",e,{path:t});e.is("rootElement")?t=t.slice():(t=[...e.getPath(),...t],e=e.root),this.root=e,this.path=t,this.stickiness=o}get offset(){return this.path[this.path.length-1]}set offset(e){this.path[this.path.length-1]=e}get parent(){let e=this.root;for(let t=0;t1)return!1;if(1===t)return Gl(e,this,o);if(-1===t)return Gl(this,e,o)}return this.path.length===e.path.length||(this.path.length>e.path.length?Kl(this.path,t):Kl(e.path,t))}hasSameParentAs(e){if(this.root!==e.root)return!1;return"same"==ie(this.getParentPath(),e.getParentPath())}getTransformedByOperation(e){let t;switch(e.type){case"insert":t=this._getTransformedByInsertOperation(e);break;case"move":case"remove":case"reinsert":t=this._getTransformedByMoveOperation(e);break;case"split":t=this._getTransformedBySplitOperation(e);break;case"merge":t=this._getTransformedByMergeOperation(e);break;default:t=ql._createAt(this)}return t}_getTransformedByInsertOperation(e){return this._getTransformedByInsertion(e.position,e.howMany)}_getTransformedByMoveOperation(e){return this._getTransformedByMove(e.sourcePosition,e.targetPosition,e.howMany)}_getTransformedBySplitOperation(e){const t=e.movedRange;return t.containsPosition(this)||t.start.isEqual(this)&&"toNext"==this.stickiness?this._getCombined(e.splitPosition,e.moveTargetPosition):e.graveyardPosition?this._getTransformedByMove(e.graveyardPosition,e.insertionPosition,1):this._getTransformedByInsertion(e.insertionPosition,1)}_getTransformedByMergeOperation(e){const t=e.movedRange;let o;return t.containsPosition(this)||t.start.isEqual(this)?(o=this._getCombined(e.sourcePosition,e.targetPosition),e.sourcePosition.isBefore(e.targetPosition)&&(o=o._getTransformedByDeletion(e.deletionPosition,1))):o=this.isEqual(e.deletionPosition)?ql._createAt(e.deletionPosition):this._getTransformedByMove(e.deletionPosition,e.graveyardPosition,1),o}_getTransformedByDeletion(e,t){const o=ql._createAt(this);if(this.root!=e.root)return o;if("same"==ie(e.getParentPath(),this.getParentPath())){if(e.offsetthis.offset)return null;o.offset-=t}}else if("prefix"==ie(e.getParentPath(),this.getParentPath())){const n=e.path.length-1;if(e.offset<=this.path[n]){if(e.offset+t>this.path[n])return null;o.path[n]-=t}}return o}_getTransformedByInsertion(e,t){const o=ql._createAt(this);if(this.root!=e.root)return o;if("same"==ie(e.getParentPath(),this.getParentPath()))(e.offset=t;){if(e.path[n]+i!==o.maxOffset)return!1;i=1,n--,o=o.parent}return!0}(e,o+1))}function Kl(e,t){for(;tt+1;){const t=n.maxOffset-o.offset;0!==t&&e.push(new Zl(o,o.getShiftedBy(t))),o.path=o.path.slice(0,-1),o.offset++,n=n.parent}for(;o.path.length<=this.end.path.length;){const t=this.end.path[o.path.length-1],n=t-o.offset;0!==n&&e.push(new Zl(o,o.getShiftedBy(n))),o.offset=t,o.path.push(0)}return e}getWalker(e={}){return e.boundaries=this,new Hl(e)}*getItems(e={}){e.boundaries=this,e.ignoreElementEnd=!0;const t=new Hl(e);for(const e of t)yield e.item}*getPositions(e={}){e.boundaries=this;const t=new Hl(e);yield t.position;for(const e of t)yield e.nextPosition}getTransformedByOperation(e){switch(e.type){case"insert":return this._getTransformedByInsertOperation(e);case"move":case"remove":case"reinsert":return this._getTransformedByMoveOperation(e);case"split":return[this._getTransformedBySplitOperation(e)];case"merge":return[this._getTransformedByMergeOperation(e)]}return[new Zl(this.start,this.end)]}getTransformedByOperations(e){const t=[new Zl(this.start,this.end)];for(const o of e)for(let e=0;e0?new this(o,n):new this(n,o)}static _createIn(e){return new this(ql._createAt(e,0),ql._createAt(e,e.maxOffset))}static _createOn(e){return this._createFromPositionAndShift(ql._createBefore(e),e.offsetSize)}static _createFromRanges(e){if(0===e.length)throw new E("range-create-from-ranges-empty-array",null);if(1==e.length)return e[0].clone();const t=e[0];e.sort(((e,t)=>e.start.isAfter(t.start)?1:-1));const o=e.indexOf(t),n=new this(t.start,t.end);if(o>0)for(let t=o-1;e[t].end.isEqual(n.start);t++)n.start=ql._createAt(e[t].start);for(let t=o+1;t{if(t.viewPosition)return;const o=this._modelToViewMapping.get(t.modelPosition.parent);if(!o)throw new E("mapping-model-position-view-parent-not-found",this,{modelPosition:t.modelPosition});t.viewPosition=this.findPositionIn(o,t.modelPosition.offset)}),{priority:"low"}),this.on("viewToModelPosition",((e,t)=>{if(t.modelPosition)return;const o=this.findMappedViewAncestor(t.viewPosition),n=this._viewToModelMapping.get(o),i=this._toModelOffset(t.viewPosition.parent,t.viewPosition.offset,o);t.modelPosition=ql._createAt(n,i)}),{priority:"low"})}bindElements(e,t){this._modelToViewMapping.set(e,t),this._viewToModelMapping.set(t,e)}unbindViewElement(e,t={}){const o=this.toModelElement(e);if(this._elementToMarkerNames.has(e))for(const t of this._elementToMarkerNames.get(e))this._unboundMarkerNames.add(t);t.defer?this._deferredBindingRemovals.set(e,e.root):(this._viewToModelMapping.delete(e),this._modelToViewMapping.get(o)==e&&this._modelToViewMapping.delete(o))}unbindModelElement(e){const t=this.toViewElement(e);this._modelToViewMapping.delete(e),this._viewToModelMapping.get(t)==e&&this._viewToModelMapping.delete(t)}bindElementToMarker(e,t){const o=this._markerNameToElements.get(t)||new Set;o.add(e);const n=this._elementToMarkerNames.get(e)||new Set;n.add(t),this._markerNameToElements.set(t,o),this._elementToMarkerNames.set(e,n)}unbindElementFromMarkerName(e,t){const o=this._markerNameToElements.get(t);o&&(o.delete(e),0==o.size&&this._markerNameToElements.delete(t));const n=this._elementToMarkerNames.get(e);n&&(n.delete(t),0==n.size&&this._elementToMarkerNames.delete(e))}flushUnboundMarkerNames(){const e=Array.from(this._unboundMarkerNames);return this._unboundMarkerNames.clear(),e}flushDeferredBindings(){for(const[e,t]of this._deferredBindingRemovals)e.root==t&&this.unbindViewElement(e);this._deferredBindingRemovals=new Map}clearBindings(){this._modelToViewMapping=new WeakMap,this._viewToModelMapping=new WeakMap,this._markerNameToElements=new Map,this._elementToMarkerNames=new Map,this._unboundMarkerNames=new Set,this._deferredBindingRemovals=new Map}toModelElement(e){return this._viewToModelMapping.get(e)}toViewElement(e){return this._modelToViewMapping.get(e)}toModelRange(e){return new Zl(this.toModelPosition(e.start),this.toModelPosition(e.end))}toViewRange(e){return new Ts(this.toViewPosition(e.start),this.toViewPosition(e.end))}toModelPosition(e){const t={viewPosition:e,mapper:this};return this.fire("viewToModelPosition",t),t.modelPosition}toViewPosition(e,t={}){const o={modelPosition:e,mapper:this,isPhantom:t.isPhantom};return this.fire("modelToViewPosition",o),o.viewPosition}markerNameToElements(e){const t=this._markerNameToElements.get(e);if(!t)return null;const o=new Set;for(const e of t)if(e.is("attributeElement"))for(const t of e.getElementsWithSameId())o.add(t);else o.add(e);return o}registerViewToModelLength(e,t){this._viewToModelLengthCallbacks.set(e,t)}findMappedViewAncestor(e){let t=e.parent;for(;!this._viewToModelMapping.has(t);)t=t.parent;return t}_toModelOffset(e,t,o){if(o!=e){return this._toModelOffset(e.parent,e.index,o)+this._toModelOffset(e,t,e)}if(e.is("$text"))return t;let n=0;for(let o=0;o1?t[0]+":"+t[1]:t[0]}class Xl extends(z()){constructor(e){super(),this._conversionApi={dispatcher:this,...e},this._firedEventsMap=new WeakMap}convertChanges(e,t,o){const n=this._createConversionApi(o,e.getRefreshedItems());for(const t of e.getMarkersToRemove())this._convertMarkerRemove(t.name,t.range,n);const i=this._reduceChanges(e.getChanges());for(const e of i)"insert"===e.type?this._convertInsert(Zl._createFromPositionAndShift(e.position,e.length),n):"reinsert"===e.type?this._convertReinsert(Zl._createFromPositionAndShift(e.position,e.length),n):"remove"===e.type?this._convertRemove(e.position,e.length,e.name,n):this._convertAttribute(e.range,e.attributeKey,e.attributeOldValue,e.attributeNewValue,n);n.mapper.flushDeferredBindings();for(const e of n.mapper.flushUnboundMarkerNames()){const o=t.get(e).getRange();this._convertMarkerRemove(e,o,n),this._convertMarkerAdd(e,o,n)}for(const t of e.getMarkersToAdd())this._convertMarkerAdd(t.name,t.range,n);n.consumable.verifyAllConsumed("insert")}convert(e,t,o,n={}){const i=this._createConversionApi(o,void 0,n);this._convertInsert(e,i);for(const[e,o]of t)this._convertMarkerAdd(e,o,i);i.consumable.verifyAllConsumed("insert")}convertSelection(e,t,o){const n=this._createConversionApi(o);this.fire("cleanSelection",{selection:e},n);const i=e.getFirstPosition().root;if(!n.mapper.toViewElement(i))return;const r=Array.from(t.getMarkersAtPosition(e.getFirstPosition()));if(this._addConsumablesForSelection(n.consumable,e,r),this.fire("selection",{selection:e},n),e.isCollapsed){for(const t of r)if(n.consumable.test(e,"addMarker:"+t.name)){const o=t.getRange();if(!ec(e.getFirstPosition(),t,n.mapper))continue;const i={item:e,markerName:t.name,markerRange:o};this.fire(`addMarker:${t.name}`,i,n)}for(const t of e.getAttributeKeys())if(n.consumable.test(e,"attribute:"+t)){const o={item:e,range:e.getFirstRange(),attributeKey:t,attributeOldValue:null,attributeNewValue:e.getAttribute(t)};this.fire(`attribute:${t}:$text`,o,n)}}}_convertInsert(e,t,o={}){o.doNotAddConsumables||this._addConsumablesForInsert(t.consumable,e);for(const o of Array.from(e.getWalker({shallow:!0})).map(tc))this._testAndFire("insert",o,t)}_convertRemove(e,t,o,n){this.fire(`remove:${o}`,{position:e,length:t},n)}_convertAttribute(e,t,o,n,i){this._addConsumablesForRange(i.consumable,e,`attribute:${t}`);for(const r of e){const e={item:r.item,range:Zl._createFromPositionAndShift(r.previousPosition,r.length),attributeKey:t,attributeOldValue:o,attributeNewValue:n};this._testAndFire(`attribute:${t}`,e,i)}}_convertReinsert(e,t){const o=Array.from(e.getWalker({shallow:!0}));this._addConsumablesForInsert(t.consumable,o);for(const e of o.map(tc))this._testAndFire("insert",{...e,reconversion:!0},t)}_convertMarkerAdd(e,t,o){if("$graveyard"==t.root.rootName)return;const n=`addMarker:${e}`;if(o.consumable.add(t,n),this.fire(n,{markerName:e,markerRange:t},o),o.consumable.consume(t,n)){this._addConsumablesForRange(o.consumable,t,n);for(const i of t.getItems()){if(!o.consumable.test(i,n))continue;const r={item:i,range:Zl._createOn(i),markerName:e,markerRange:t};this.fire(n,r,o)}}}_convertMarkerRemove(e,t,o){"$graveyard"!=t.root.rootName&&this.fire(`removeMarker:${e}`,{markerName:e,markerRange:t},o)}_reduceChanges(e){const t={changes:e};return this.fire("reduceChanges",t),t.changes}_addConsumablesForInsert(e,t){for(const o of t){const t=o.item;if(null===e.test(t,"insert")){e.add(t,"insert");for(const o of t.getAttributeKeys())e.add(t,"attribute:"+o)}}return e}_addConsumablesForRange(e,t,o){for(const n of t.getItems())e.add(n,o);return e}_addConsumablesForSelection(e,t,o){e.add(t,"selection");for(const n of o)e.add(t,"addMarker:"+n.name);for(const o of t.getAttributeKeys())e.add(t,"attribute:"+o);return e}_testAndFire(e,t,o){const n=function(e,t){const o=t.item.is("element")?t.item.name:"$text";return`${e}:${o}`}(e,t),i=t.item.is("$textProxy")?o.consumable._getSymbolForTextProxy(t.item):t.item,r=this._firedEventsMap.get(o),s=r.get(i);if(s){if(s.has(n))return;s.add(n)}else r.set(i,new Set([n]));this.fire(n,t,o)}_testAndFireAddAttributes(e,t){const o={item:e,range:Zl._createOn(e)};for(const e of o.item.getAttributeKeys())o.attributeKey=e,o.attributeOldValue=null,o.attributeNewValue=o.item.getAttribute(e),this._testAndFire(`attribute:${e}`,o,t)}_createConversionApi(e,t=new Set,o={}){const n={...this._conversionApi,consumable:new Yl,writer:e,options:o,convertItem:e=>this._convertInsert(Zl._createOn(e),n),convertChildren:e=>this._convertInsert(Zl._createIn(e),n,{doNotAddConsumables:!0}),convertAttributes:e=>this._testAndFireAddAttributes(e,n),canReuseView:e=>!t.has(n.mapper.toModelElement(e))};return this._firedEventsMap.set(n,new Map),n}}function ec(e,t,o){const n=t.getRange(),i=Array.from(e.getAncestors());i.shift(),i.reverse();return!i.some((e=>{if(n.containsItem(e)){return!!o.toViewElement(e).getCustomProperty("addHighlight")}}))}function tc(e){return{item:e.item,range:Zl._createFromPositionAndShift(e.previousPosition,e.length)}}class oc extends(z(Rl)){constructor(...e){super(),this._lastRangeBackward=!1,this._attrs=new Map,this._ranges=[],e.length&&this.setTo(...e)}get anchor(){if(this._ranges.length>0){const e=this._ranges[this._ranges.length-1];return this._lastRangeBackward?e.end:e.start}return null}get focus(){if(this._ranges.length>0){const e=this._ranges[this._ranges.length-1];return this._lastRangeBackward?e.start:e.end}return null}get isCollapsed(){return 1===this._ranges.length&&this._ranges[0].isCollapsed}get rangeCount(){return this._ranges.length}get isBackward(){return!this.isCollapsed&&this._lastRangeBackward}isEqual(e){if(this.rangeCount!=e.rangeCount)return!1;if(0===this.rangeCount)return!0;if(!this.anchor.isEqual(e.anchor)||!this.focus.isEqual(e.focus))return!1;for(const t of this._ranges){let o=!1;for(const n of e._ranges)if(t.isEqual(n)){o=!0;break}if(!o)return!1}return!0}*getRanges(){for(const e of this._ranges)yield new Zl(e.start,e.end)}getFirstRange(){let e=null;for(const t of this._ranges)e&&!t.start.isBefore(e.start)||(e=t);return e?new Zl(e.start,e.end):null}getLastRange(){let e=null;for(const t of this._ranges)e&&!t.end.isAfter(e.end)||(e=t);return e?new Zl(e.start,e.end):null}getFirstPosition(){const e=this.getFirstRange();return e?e.start.clone():null}getLastPosition(){const e=this.getLastRange();return e?e.end.clone():null}setTo(...e){let[t,o,n]=e;if("object"==typeof o&&(n=o,o=void 0),null===t)this._setRanges([]);else if(t instanceof oc)this._setRanges(t.getRanges(),t.isBackward);else if(t&&"function"==typeof t.getRanges)this._setRanges(t.getRanges(),t.isBackward);else if(t instanceof Zl)this._setRanges([t],!!n&&!!n.backward);else if(t instanceof ql)this._setRanges([new Zl(t)]);else if(t instanceof zl){const e=!!n&&!!n.backward;let i;if("in"==o)i=Zl._createIn(t);else if("on"==o)i=Zl._createOn(t);else{if(void 0===o)throw new E("model-selection-setto-required-second-parameter",[this,t]);i=new Zl(ql._createAt(t,o))}this._setRanges([i],e)}else{if(!re(t))throw new E("model-selection-setto-not-selectable",[this,t]);this._setRanges(t,n&&!!n.backward)}}_setRanges(e,t=!1){const o=Array.from(e),n=o.some((t=>{if(!(t instanceof Zl))throw new E("model-selection-set-ranges-not-range",[this,e]);return this._ranges.every((e=>!e.isEqual(t)))}));(o.length!==this._ranges.length||n)&&(this._replaceAllRanges(o),this._lastRangeBackward=!!t,this.fire("change:range",{directChange:!0}))}setFocus(e,t){if(null===this.anchor)throw new E("model-selection-setfocus-no-ranges",[this,e]);const o=ql._createAt(e,t);if("same"==o.compareWith(this.focus))return;const n=this.anchor;this._ranges.length&&this._popRange(),"before"==o.compareWith(n)?(this._pushRange(new Zl(o,n)),this._lastRangeBackward=!0):(this._pushRange(new Zl(n,o)),this._lastRangeBackward=!1),this.fire("change:range",{directChange:!0})}getAttribute(e){return this._attrs.get(e)}getAttributes(){return this._attrs.entries()}getAttributeKeys(){return this._attrs.keys()}hasAttribute(e){return this._attrs.has(e)}removeAttribute(e){this.hasAttribute(e)&&(this._attrs.delete(e),this.fire("change:attribute",{attributeKeys:[e],directChange:!0}))}setAttribute(e,t){this.getAttribute(e)!==t&&(this._attrs.set(e,t),this.fire("change:attribute",{attributeKeys:[e],directChange:!0}))}getSelectedElement(){return 1!==this.rangeCount?null:this.getFirstRange().getContainedElement()}*getSelectedBlocks(){const e=new WeakSet;for(const t of this.getRanges()){const o=rc(t.start,e);ac(o,t)&&(yield o);for(const o of t.getWalker()){const n=o.item;"elementEnd"==o.type&&ic(n,e,t)&&(yield n)}const n=rc(t.end,e);lc(n,t)&&(yield n)}}containsEntireContent(e=this.anchor.root){const t=ql._createAt(e,0),o=ql._createAt(e,"end");return t.isTouching(this.getFirstPosition())&&o.isTouching(this.getLastPosition())}_pushRange(e){this._checkRange(e),this._ranges.push(new Zl(e.start,e.end))}_checkRange(e){for(let t=0;t0;)this._popRange()}_popRange(){this._ranges.pop()}}function nc(e,t){return!t.has(e)&&(t.add(e),e.root.document.model.schema.isBlock(e)&&!!e.parent)}function ic(e,t,o){return nc(e,t)&&sc(e,o)}function rc(e,t){const o=e.parent.root.document.model.schema,n=e.parent.getAncestors({parentFirst:!0,includeSelf:!0});let i=!1;const r=n.find((e=>!i&&(i=o.isLimit(e),!i&&nc(e,t))));return n.forEach((e=>t.add(e))),r}function sc(e,t){const o=function(e){const t=e.root.document.model.schema;let o=e.parent;for(;o;){if(t.isBlock(o))return o;o=o.parent}}(e);if(!o)return!0;return!t.containsRange(Zl._createOn(o),!0)}function ac(e,t){return!!e&&(!(!t.isCollapsed&&!e.isEmpty)||!t.start.isTouching(ql._createAt(e,e.maxOffset))&&sc(e,t))}function lc(e,t){return!!e&&(!(!t.isCollapsed&&!e.isEmpty)||!t.end.isTouching(ql._createAt(e,0))&&sc(e,t))}oc.prototype.is=function(e){return"selection"===e||"model:selection"===e};class cc extends(z(Zl)){constructor(e,t){super(e,t),dc.call(this)}detach(){this.stopListening()}toRange(){return new Zl(this.start,this.end)}static fromRange(e){return new cc(e.start,e.end)}}function dc(){this.listenTo(this.root.document.model,"applyOperation",((e,t)=>{const o=t[0];o.isDocumentOperation&&uc.call(this,o)}),{priority:"low"})}function uc(e){const t=this.getTransformedByOperation(e),o=Zl._createFromRanges(t),n=!o.isEqual(this),i=function(e,t){switch(t.type){case"insert":return e.containsPosition(t.position);case"move":case"remove":case"reinsert":case"merge":return e.containsPosition(t.sourcePosition)||e.start.isEqual(t.sourcePosition)||e.containsPosition(t.targetPosition);case"split":return e.containsPosition(t.splitPosition)||e.containsPosition(t.insertionPosition)}return!1}(this,e);let r=null;if(n){"$graveyard"==o.root.rootName&&(r="remove"==e.type?e.sourcePosition:e.deletionPosition);const t=this.toRange();this.start=o.start,this.end=o.end,this.fire("change:range",t,{deletionPosition:r})}else i&&this.fire("change:content",this.toRange(),{deletionPosition:r})}cc.prototype.is=function(e){return"liveRange"===e||"model:liveRange"===e||"range"==e||"model:range"===e};const hc="selection:";class mc extends(z(Rl)){constructor(e){super(),this._selection=new pc(e),this._selection.delegate("change:range").to(this),this._selection.delegate("change:attribute").to(this),this._selection.delegate("change:marker").to(this)}get isCollapsed(){return this._selection.isCollapsed}get anchor(){return this._selection.anchor}get focus(){return this._selection.focus}get rangeCount(){return this._selection.rangeCount}get hasOwnRange(){return this._selection.hasOwnRange}get isBackward(){return this._selection.isBackward}get isGravityOverridden(){return this._selection.isGravityOverridden}get markers(){return this._selection.markers}get _ranges(){return this._selection._ranges}getRanges(){return this._selection.getRanges()}getFirstPosition(){return this._selection.getFirstPosition()}getLastPosition(){return this._selection.getLastPosition()}getFirstRange(){return this._selection.getFirstRange()}getLastRange(){return this._selection.getLastRange()}getSelectedBlocks(){return this._selection.getSelectedBlocks()}getSelectedElement(){return this._selection.getSelectedElement()}containsEntireContent(e){return this._selection.containsEntireContent(e)}destroy(){this._selection.destroy()}getAttributeKeys(){return this._selection.getAttributeKeys()}getAttributes(){return this._selection.getAttributes()}getAttribute(e){return this._selection.getAttribute(e)}hasAttribute(e){return this._selection.hasAttribute(e)}refresh(){this._selection.updateMarkers(),this._selection._updateAttributes(!1)}observeMarkers(e){this._selection.observeMarkers(e)}_setFocus(e,t){this._selection.setFocus(e,t)}_setTo(...e){this._selection.setTo(...e)}_setAttribute(e,t){this._selection.setAttribute(e,t)}_removeAttribute(e){this._selection.removeAttribute(e)}_getStoredAttributes(){return this._selection.getStoredAttributes()}_overrideGravity(){return this._selection.overrideGravity()}_restoreGravity(e){this._selection.restoreGravity(e)}static _getStoreAttributeKey(e){return hc+e}static _isStoreAttributeKey(e){return e.startsWith(hc)}}mc.prototype.is=function(e){return"selection"===e||"model:selection"==e||"documentSelection"==e||"model:documentSelection"==e};class pc extends oc{constructor(e){super(),this.markers=new Yi({idProperty:"name"}),this._attributePriority=new Map,this._selectionRestorePosition=null,this._hasChangedRange=!1,this._overriddenGravityRegister=new Set,this._observedMarkers=new Set,this._model=e.model,this._document=e,this.listenTo(this._model,"applyOperation",((e,t)=>{const o=t[0];o.isDocumentOperation&&"marker"!=o.type&&"rename"!=o.type&&"noop"!=o.type&&(0==this._ranges.length&&this._selectionRestorePosition&&this._fixGraveyardSelection(this._selectionRestorePosition),this._selectionRestorePosition=null,this._hasChangedRange&&(this._hasChangedRange=!1,this.fire("change:range",{directChange:!1})))}),{priority:"lowest"}),this.on("change:range",(()=>{this._validateSelectionRanges(this.getRanges())})),this.listenTo(this._model.markers,"update",((e,t,o,n)=>{this._updateMarker(t,n)})),this.listenTo(this._document,"change",((e,t)=>{!function(e,t){const o=e.document.differ;for(const n of o.getChanges()){if("insert"!=n.type)continue;const o=n.position.parent;n.length===o.maxOffset&&e.enqueueChange(t,(e=>{const t=Array.from(o.getAttributeKeys()).filter((e=>e.startsWith(hc)));for(const n of t)e.removeAttribute(n,o)}))}}(this._model,t)}))}get isCollapsed(){return 0===this._ranges.length?this._document._getDefaultRange().isCollapsed:super.isCollapsed}get anchor(){return super.anchor||this._document._getDefaultRange().start}get focus(){return super.focus||this._document._getDefaultRange().end}get rangeCount(){return this._ranges.length?this._ranges.length:1}get hasOwnRange(){return this._ranges.length>0}get isGravityOverridden(){return!!this._overriddenGravityRegister.size}destroy(){for(let e=0;e{if(this._hasChangedRange=!0,t.root==this._document.graveyard){this._selectionRestorePosition=n.deletionPosition;const e=this._ranges.indexOf(t);this._ranges.splice(e,1),t.detach()}})),t}updateMarkers(){if(!this._observedMarkers.size)return;const e=[];let t=!1;for(const t of this._model.markers){const o=t.name.split(":",1)[0];if(!this._observedMarkers.has(o))continue;const n=t.getRange();for(const o of this.getRanges())n.containsRange(o,!o.isCollapsed)&&e.push(t)}const o=Array.from(this.markers);for(const o of e)this.markers.has(o)||(this.markers.add(o),t=!0);for(const o of Array.from(this.markers))e.includes(o)||(this.markers.remove(o),t=!0);t&&this.fire("change:marker",{oldMarkers:o,directChange:!1})}_updateMarker(e,t){const o=e.name.split(":",1)[0];if(!this._observedMarkers.has(o))return;let n=!1;const i=Array.from(this.markers),r=this.markers.has(e);if(t){let o=!1;for(const e of this.getRanges())if(t.containsRange(e,!e.isCollapsed)){o=!0;break}o&&!r?(this.markers.add(e),n=!0):!o&&r&&(this.markers.remove(e),n=!0)}else r&&(this.markers.remove(e),n=!0);n&&this.fire("change:marker",{oldMarkers:i,directChange:!1})}_updateAttributes(e){const t=tr(this._getSurroundingAttributes()),o=tr(this.getAttributes());if(e)this._attributePriority=new Map,this._attrs=new Map;else for(const[e,t]of this._attributePriority)"low"==t&&(this._attrs.delete(e),this._attributePriority.delete(e));this._setAttributesTo(t);const n=[];for(const[e,t]of this.getAttributes())o.has(e)&&o.get(e)===t||n.push(e);for(const[e]of o)this.hasAttribute(e)||n.push(e);n.length>0&&this.fire("change:attribute",{attributeKeys:n,directChange:!1})}_setAttribute(e,t,o=!0){const n=o?"normal":"low";if("low"==n&&"normal"==this._attributePriority.get(e))return!1;return super.getAttribute(e)!==t&&(this._attrs.set(e,t),this._attributePriority.set(e,n),!0)}_removeAttribute(e,t=!0){const o=t?"normal":"low";return("low"!=o||"normal"!=this._attributePriority.get(e))&&(this._attributePriority.set(e,o),!!super.hasAttribute(e)&&(this._attrs.delete(e),!0))}_setAttributesTo(e){const t=new Set;for(const[t,o]of this.getAttributes())e.get(t)!==o&&this._removeAttribute(t,!1);for(const[o,n]of e){this._setAttribute(o,n,!1)&&t.add(o)}return t}*getStoredAttributes(){const e=this.getFirstPosition().parent;if(this.isCollapsed&&e.isEmpty)for(const t of e.getAttributeKeys())if(t.startsWith(hc)){const o=t.substr(10);yield[o,e.getAttribute(t)]}}_getSurroundingAttributes(){const e=this.getFirstPosition(),t=this._model.schema;if("$graveyard"==e.root.rootName)return null;let o=null;if(this.isCollapsed){const n=e.textNode?e.textNode:e.nodeBefore,i=e.textNode?e.textNode:e.nodeAfter;if(this.isGravityOverridden||(o=gc(n,t)),o||(o=gc(i,t)),!this.isGravityOverridden&&!o){let e=n;for(;e&&!o;)e=e.previousSibling,o=gc(e,t)}if(!o){let e=i;for(;e&&!o;)e=e.nextSibling,o=gc(e,t)}o||(o=this.getStoredAttributes())}else{const e=this.getFirstRange();for(const n of e){if(n.item.is("element")&&t.isObject(n.item)){o=gc(n.item,t);break}if("text"==n.type){o=n.item.getAttributes();break}}}return o}_fixGraveyardSelection(e){const t=this._model.schema.getNearestSelectionRange(e);t&&this._pushRange(t)}}function gc(e,t){if(!e)return null;if(e instanceof Nl||e instanceof Ol)return e.getAttributes();if(!t.isInline(e))return null;if(!t.isObject(e))return[];const o=[];for(const[n,i]of e.getAttributes())t.checkAttribute("$text",n)&&!1!==t.getAttributeProperties(n).copyFromObject&&o.push([n,i]);return o}class fc{constructor(e){this._dispatchers=e}add(e){for(const t of this._dispatchers)e(t);return this}}class bc extends fc{elementToElement(e){return this.add(function(e){const t=Cc(e.model),o=vc(e.view,"container");t.attributes.length&&(t.children=!0);return n=>{n.on(`insert:${t.name}`,_c(o,Sc(t)),{priority:e.converterPriority||"normal"}),(t.children||t.attributes.length)&&n.on("reduceChanges",Bc(t),{priority:"low"})}}(e))}elementToStructure(e){return this.add(function(e){const t=Cc(e.model),o=vc(e.view,"container");return t.children=!0,n=>{if(n._conversionApi.schema.checkChild(t.name,"$text"))throw new E("conversion-element-to-structure-disallowed-text",n,{elementName:t.name});var i,r;n.on(`insert:${t.name}`,(i=o,r=Sc(t),(e,t,o)=>{if(!r(t.item,o.consumable,{preflight:!0}))return;const n=new Map;o.writer._registerSlotFactory(function(e,t,o){return(n,i)=>{const r=n.createContainerElement("$slot");let s=null;if("children"===i)s=Array.from(e.getChildren());else{if("function"!=typeof i)throw new E("conversion-slot-mode-unknown",o.dispatcher,{modeOrFilter:i});s=Array.from(e.getChildren()).filter((e=>i(e)))}return t.set(r,s),r}}(t.item,n,o));const s=i(t.item,o,t);if(o.writer._clearSlotFactory(),!s)return;!function(e,t,o){const n=Array.from(t.values()).flat(),i=new Set(n);if(i.size!=n.length)throw new E("conversion-slot-filter-overlap",o.dispatcher,{element:e});if(i.size!=e.childCount)throw new E("conversion-slot-filter-incomplete",o.dispatcher,{element:e})}(t.item,n,o),r(t.item,o.consumable);const a=o.mapper.toViewPosition(t.range.start);o.mapper.bindElements(t.item,s),o.writer.insert(a,s),o.convertAttributes(t.item),function(e,t,o,n){o.mapper.on("modelToViewPosition",s,{priority:"highest"});let i=null,r=null;for([i,r]of t)Tc(e,r,o,n),o.writer.move(o.writer.createRangeIn(i),o.writer.createPositionBefore(i)),o.writer.remove(i);function s(e,t){const o=t.modelPosition.nodeAfter,n=r.indexOf(o);n<0||(t.viewPosition=t.mapper.findPositionIn(i,n))}o.mapper.off("modelToViewPosition",s)}(s,n,o,{reconversion:t.reconversion})}),{priority:e.converterPriority||"normal"}),n.on("reduceChanges",Bc(t),{priority:"low"})}}(e))}attributeToElement(e){return this.add(function(e){e=Fl(e);let t=e.model;"string"==typeof t&&(t={key:t});let o=`attribute:${t.key}`;t.name&&(o+=":"+t.name);if(t.values)for(const o of t.values)e.view[o]=vc(e.view[o],"attribute");else e.view=vc(e.view,"attribute");const n=xc(e);return t=>{t.on(o,wc(n),{priority:e.converterPriority||"normal"})}}(e))}attributeToAttribute(e){return this.add(function(e){e=Fl(e);let t=e.model;"string"==typeof t&&(t={key:t});let o=`attribute:${t.key}`;t.name&&(o+=":"+t.name);if(t.values)for(const o of t.values)e.view[o]=Ec(e.view[o]);else e.view=Ec(e.view);const n=xc(e);return t=>{var i;t.on(o,(i=n,(e,t,o)=>{if(!o.consumable.test(t.item,e.name))return;const n=i(t.attributeOldValue,o,t),r=i(t.attributeNewValue,o,t);if(!n&&!r)return;o.consumable.consume(t.item,e.name);const s=o.mapper.toViewElement(t.item),a=o.writer;if(!s)throw new E("conversion-attribute-to-attribute-on-text",o.dispatcher,t);if(null!==t.attributeOldValue&&n)if("class"==n.key){const e="string"==typeof n.value?n.value.split(/\s+/):n.value;for(const t of e)a.removeClass(t,s)}else if("style"==n.key)if("string"==typeof n.value){const e=new bs(a.document.stylesProcessor);e.setTo(n.value);for(const[t]of e.getStylesEntries())a.removeStyle(t,s)}else{const e=Object.keys(n.value);for(const t of e)a.removeStyle(t,s)}else a.removeAttribute(n.key,s);if(null!==t.attributeNewValue&&r)if("class"==r.key){const e="string"==typeof r.value?r.value.split(/\s+/):r.value;for(const t of e)a.addClass(t,s)}else if("style"==r.key)if("string"==typeof r.value){const e=new bs(a.document.stylesProcessor);e.setTo(r.value);for(const[t,o]of e.getStylesEntries())a.setStyle(t,o,s)}else{const e=Object.keys(r.value);for(const t of e)a.setStyle(t,r.value[t],s)}else a.setAttribute(r.key,r.value,s)}),{priority:e.converterPriority||"normal"})}}(e))}markerToElement(e){return this.add(function(e){const t=vc(e.view,"ui");return o=>{o.on(`addMarker:${e.model}`,yc(t),{priority:e.converterPriority||"normal"}),o.on(`removeMarker:${e.model}`,((e,t,o)=>{const n=o.mapper.markerNameToElements(t.markerName);if(n){for(const e of n)o.mapper.unbindElementFromMarkerName(e,t.markerName),o.writer.clear(o.writer.createRangeOn(e),e);o.writer.clearClonedElementsGroup(t.markerName),e.stop()}}),{priority:e.converterPriority||"normal"})}}(e))}markerToHighlight(e){return this.add(function(e){return t=>{var o;t.on(`addMarker:${e.model}`,(o=e.view,(e,t,n)=>{if(!t.item)return;if(!(t.item instanceof oc||t.item instanceof mc||t.item.is("$textProxy")))return;const i=Dc(o,t,n);if(!i)return;if(!n.consumable.consume(t.item,e.name))return;const r=n.writer,s=kc(r,i),a=r.document.selection;if(t.item instanceof oc||t.item instanceof mc)r.wrap(a.getFirstRange(),s);else{const e=n.mapper.toViewRange(t.range),o=r.wrap(e,s);for(const e of o.getItems())if(e.is("attributeElement")&&e.isSimilar(s)){n.mapper.bindElementToMarker(e,t.markerName);break}}}),{priority:e.converterPriority||"normal"}),t.on(`addMarker:${e.model}`,function(e){return(t,o,n)=>{if(!o.item)return;if(!(o.item instanceof Ll))return;const i=Dc(e,o,n);if(!i)return;if(!n.consumable.test(o.item,t.name))return;const r=n.mapper.toViewElement(o.item);if(r&&r.getCustomProperty("addHighlight")){n.consumable.consume(o.item,t.name);for(const e of Zl._createIn(o.item))n.consumable.consume(e.item,t.name);r.getCustomProperty("addHighlight")(r,i,n.writer),n.mapper.bindElementToMarker(r,o.markerName)}}}(e.view),{priority:e.converterPriority||"normal"}),t.on(`removeMarker:${e.model}`,function(e){return(t,o,n)=>{if(o.markerRange.isCollapsed)return;const i=Dc(e,o,n);if(!i)return;const r=kc(n.writer,i),s=n.mapper.markerNameToElements(o.markerName);if(s){for(const e of s)if(n.mapper.unbindElementFromMarkerName(e,o.markerName),e.is("attributeElement"))n.writer.unwrap(n.writer.createRangeOn(e),r);else{e.getCustomProperty("removeHighlight")(e,i.id,n.writer)}n.writer.clearClonedElementsGroup(o.markerName),t.stop()}}}(e.view),{priority:e.converterPriority||"normal"})}}(e))}markerToData(e){return this.add(function(e){e=Fl(e);const t=e.model;let o=e.view;o||(o=o=>({group:t,name:o.substr(e.model.length+1)}));return n=>{var i;n.on(`addMarker:${t}`,(i=o,(e,t,o)=>{const n=i(t.markerName,o);if(!n)return;const r=t.markerRange;o.consumable.consume(r,e.name)&&(Ac(r,!1,o,t,n),Ac(r,!0,o,t,n),e.stop())}),{priority:e.converterPriority||"normal"}),n.on(`removeMarker:${t}`,function(e){return(t,o,n)=>{const i=e(o.markerName,n);if(!i)return;const r=n.mapper.markerNameToElements(o.markerName);if(r){for(const e of r)n.mapper.unbindElementFromMarkerName(e,o.markerName),e.is("containerElement")?(s(`data-${i.group}-start-before`,e),s(`data-${i.group}-start-after`,e),s(`data-${i.group}-end-before`,e),s(`data-${i.group}-end-after`,e)):n.writer.clear(n.writer.createRangeOn(e),e);n.writer.clearClonedElementsGroup(o.markerName),t.stop()}function s(e,t){if(t.hasAttribute(e)){const o=new Set(t.getAttribute(e).split(","));o.delete(i.name),0==o.size?n.writer.removeAttribute(e,t):n.writer.setAttribute(e,Array.from(o).join(","),t)}}}}(o),{priority:e.converterPriority||"normal"})}}(e))}}function kc(e,t){const o=e.createAttributeElement("span",t.attributes);return t.classes&&o._addClass(t.classes),"number"==typeof t.priority&&(o._priority=t.priority),o._id=t.id,o}function wc(e){return(t,o,n)=>{if(!n.consumable.test(o.item,t.name))return;const i=e(o.attributeOldValue,n,o),r=e(o.attributeNewValue,n,o);if(!i&&!r)return;n.consumable.consume(o.item,t.name);const s=n.writer,a=s.document.selection;if(o.item instanceof oc||o.item instanceof mc)s.wrap(a.getFirstRange(),r);else{let e=n.mapper.toViewRange(o.range);null!==o.attributeOldValue&&i&&(e=s.unwrap(e,i)),null!==o.attributeNewValue&&r&&s.wrap(e,r)}}}function _c(e,t=Pc){return(o,n,i)=>{if(!t(n.item,i.consumable,{preflight:!0}))return;const r=e(n.item,i,n);if(!r)return;t(n.item,i.consumable);const s=i.mapper.toViewPosition(n.range.start);i.mapper.bindElements(n.item,r),i.writer.insert(s,r),i.convertAttributes(n.item),Tc(r,n.item.getChildren(),i,{reconversion:n.reconversion})}}function yc(e){return(t,o,n)=>{o.isOpening=!0;const i=e(o,n);o.isOpening=!1;const r=e(o,n);if(!i||!r)return;const s=o.markerRange;if(s.isCollapsed&&!n.consumable.consume(s,t.name))return;for(const e of s)if(!n.consumable.consume(e.item,t.name))return;const a=n.mapper,l=n.writer;l.insert(a.toViewPosition(s.start),i),n.mapper.bindElementToMarker(i,o.markerName),s.isCollapsed||(l.insert(a.toViewPosition(s.end),r),n.mapper.bindElementToMarker(r,o.markerName)),t.stop()}}function Ac(e,t,o,n,i){const r=t?e.start:e.end,s=r.nodeAfter&&r.nodeAfter.is("element")?r.nodeAfter:null,a=r.nodeBefore&&r.nodeBefore.is("element")?r.nodeBefore:null;if(s||a){let e,r;t&&s||!t&&!a?(e=s,r=!0):(e=a,r=!1);const l=o.mapper.toViewElement(e);if(l)return void function(e,t,o,n,i,r){const s=`data-${r.group}-${t?"start":"end"}-${o?"before":"after"}`,a=e.hasAttribute(s)?e.getAttribute(s).split(","):[];a.unshift(r.name),n.writer.setAttribute(s,a.join(","),e),n.mapper.bindElementToMarker(e,i.markerName)}(l,t,r,o,n,i)}!function(e,t,o,n,i){const r=`${i.group}-${t?"start":"end"}`,s=i.name?{name:i.name}:null,a=o.writer.createUIElement(r,s);o.writer.insert(e,a),o.mapper.bindElementToMarker(a,n.markerName)}(o.mapper.toViewPosition(r),t,o,n,i)}function Cc(e){return"string"==typeof e&&(e={name:e}),{name:e.name,attributes:e.attributes?xi(e.attributes):[],children:!!e.children}}function vc(e,t){return"function"==typeof e?e:(o,n)=>function(e,t,o){"string"==typeof e&&(e={name:e});let n;const i=t.writer,r=Object.assign({},e.attributes);if("container"==o)n=i.createContainerElement(e.name,r);else if("attribute"==o){const t={priority:e.priority||qs.DEFAULT_PRIORITY};n=i.createAttributeElement(e.name,r,t)}else n=i.createUIElement(e.name,r);if(e.styles){const t=Object.keys(e.styles);for(const o of t)i.setStyle(o,e.styles[o],n)}if(e.classes){const t=e.classes;if("string"==typeof t)i.addClass(t,n);else for(const e of t)i.addClass(e,n)}return n}(e,n,t)}function xc(e){return e.model.values?(t,o,n)=>{const i=e.view[t];return i?i(t,o,n):null}:e.view}function Ec(e){return"string"==typeof e?t=>({key:e,value:t}):"object"==typeof e?e.value?()=>e:t=>({key:e.key,value:t}):e}function Dc(e,t,o){const n="function"==typeof e?e(t,o):e;return n?(n.priority||(n.priority=10),n.id||(n.id=t.markerName),n):null}function Bc(e){const t=function(e){return(t,o)=>{if(!t.is("element",e.name))return!1;if("attribute"==o.type){if(e.attributes.includes(o.attributeKey))return!0}else if(e.children)return!0;return!1}}(e);return(e,o)=>{const n=[];o.reconvertedElements||(o.reconvertedElements=new Set);for(const e of o.changes){const i="attribute"==e.type?e.range.start.nodeAfter:e.position.parent;if(i&&t(i,e)){if(!o.reconvertedElements.has(i)){o.reconvertedElements.add(i);const e=ql._createBefore(i);let t=n.length;for(let o=n.length-1;o>=0;o--){const i=n[o],r=("attribute"==i.type?i.range.start:i.position).compareWith(e);if("before"==r||"remove"==i.type&&"same"==r)break;t=o}n.splice(t,0,{type:"remove",name:i.name,position:e,length:1},{type:"reinsert",name:i.name,position:e,length:1})}}else n.push(e)}o.changes=n}}function Sc(e){return(t,o,n={})=>{const i=["insert"];for(const o of e.attributes)t.hasAttribute(o)&&i.push(`attribute:${o}`);return!!i.every((e=>o.test(t,e)))&&(n.preflight||i.forEach((e=>o.consume(t,e))),!0)}}function Tc(e,t,o,n){for(const i of t)Ic(e.root,i,o,n)||o.convertItem(i)}function Ic(e,t,o,n){const{writer:i,mapper:r}=o;if(!n.reconversion)return!1;const s=r.toViewElement(t);return!(!s||s.root==e)&&(!!o.canReuseView(s)&&(i.move(i.createRangeOn(s),r.toViewPosition(ql._createBefore(t))),!0))}function Pc(e,t,{preflight:o}={}){return o?t.test(e,"insert"):t.consume(e,"insert")}function Fc(e){const{schema:t,document:o}=e.model;for(const n of o.getRoots())if(n.isEmpty&&!t.checkChild(n,"$text")&&t.checkChild(n,"paragraph"))return e.insertElement("paragraph",n),!0;return!1}function Mc(e,t,o){const n=o.createContext(e);return!!o.checkChild(n,"paragraph")&&!!o.checkChild(n.push("paragraph"),t)}function Rc(e,t){const o=t.createElement("paragraph");return t.insert(o,e),t.createPositionAt(o,0)}class zc extends fc{elementToElement(e){return this.add(Vc(e))}elementToAttribute(e){return this.add(function(e){e=Fl(e),Lc(e);const t=Hc(e,!1),o=Oc(e.view),n=o?`element:${o}`:"element";return o=>{o.on(n,t,{priority:e.converterPriority||"low"})}}(e))}attributeToAttribute(e){return this.add(function(e){e=Fl(e);let t=null;("string"==typeof e.view||e.view.key)&&(t=function(e){"string"==typeof e.view&&(e.view={key:e.view});const t=e.view.key,o=void 0===e.view.value?/[\s\S]*/:e.view.value;let n;if("class"==t||"style"==t){n={["class"==t?"classes":"styles"]:o}}else n={attributes:{[t]:o}};e.view.name&&(n.name=e.view.name);return e.view=n,t}(e));Lc(e,t);const o=Hc(e,!0);return t=>{t.on("element",o,{priority:e.converterPriority||"low"})}}(e))}elementToMarker(e){return this.add(function(e){const t=function(e){return(t,o)=>{const n="string"==typeof e?e:e(t,o);return o.writer.createElement("$marker",{"data-name":n})}}(e.model);return Vc({...e,model:t})}(e))}dataToMarker(e){return this.add(function(e){e=Fl(e),e.model||(e.model=t=>t?e.view+":"+t:e.view);const t={view:e.view,model:e.model},o=Nc(jc(t,"start")),n=Nc(jc(t,"end"));return i=>{i.on(`element:${e.view}-start`,o,{priority:e.converterPriority||"normal"}),i.on(`element:${e.view}-end`,n,{priority:e.converterPriority||"normal"});const r=C.low,s=C.highest,a=C.get(e.converterPriority)/s;i.on("element",function(e){return(t,o,n)=>{const i=`data-${e.view}`;function r(t,i){for(const r of i){const i=e.model(r,n),s=n.writer.createElement("$marker",{"data-name":i});n.writer.insert(s,t),o.modelCursor.isEqual(t)?o.modelCursor=o.modelCursor.getShiftedBy(1):o.modelCursor=o.modelCursor._getTransformedByInsertion(t,1),o.modelRange=o.modelRange._getTransformedByInsertion(t,1)[0]}}(n.consumable.test(o.viewItem,{attributes:i+"-end-after"})||n.consumable.test(o.viewItem,{attributes:i+"-start-after"})||n.consumable.test(o.viewItem,{attributes:i+"-end-before"})||n.consumable.test(o.viewItem,{attributes:i+"-start-before"}))&&(o.modelRange||Object.assign(o,n.convertChildren(o.viewItem,o.modelCursor)),n.consumable.consume(o.viewItem,{attributes:i+"-end-after"})&&r(o.modelRange.end,o.viewItem.getAttribute(i+"-end-after").split(",")),n.consumable.consume(o.viewItem,{attributes:i+"-start-after"})&&r(o.modelRange.end,o.viewItem.getAttribute(i+"-start-after").split(",")),n.consumable.consume(o.viewItem,{attributes:i+"-end-before"})&&r(o.modelRange.start,o.viewItem.getAttribute(i+"-end-before").split(",")),n.consumable.consume(o.viewItem,{attributes:i+"-start-before"})&&r(o.modelRange.start,o.viewItem.getAttribute(i+"-start-before").split(",")))}}(t),{priority:r+a})}}(e))}}function Vc(e){const t=Nc(e=Fl(e)),o=Oc(e.view),n=o?`element:${o}`:"element";return o=>{o.on(n,t,{priority:e.converterPriority||"normal"})}}function Oc(e){return"string"==typeof e?e:"object"==typeof e&&"string"==typeof e.name?e.name:null}function Nc(e){const t=new Hr(e.view);return(o,n,i)=>{const r=t.match(n.viewItem);if(!r)return;const s=r.match;if(s.name=!0,!i.consumable.test(n.viewItem,s))return;const a=function(e,t,o){return e instanceof Function?e(t,o):o.writer.createElement(e)}(e.model,n.viewItem,i);a&&i.safeInsert(a,n.modelCursor)&&(i.consumable.consume(n.viewItem,s),i.convertChildren(n.viewItem,a),i.updateConversionResult(a,n))}}function Lc(e,t=null){const o=null===t||(e=>e.getAttribute(t)),n="object"!=typeof e.model?e.model:e.model.key,i="object"!=typeof e.model||void 0===e.model.value?o:e.model.value;e.model={key:n,value:i}}function Hc(e,t){const o=new Hr(e.view);return(n,i,r)=>{if(!i.modelRange&&t)return;const s=o.match(i.viewItem);if(!s)return;if(!function(e,t){const o="function"==typeof e?e(t):e;if("object"==typeof o&&!Oc(o))return!1;return!o.classes&&!o.attributes&&!o.styles}(e.view,i.viewItem)?delete s.match.name:s.match.name=!0,!r.consumable.test(i.viewItem,s.match))return;const a=e.model.key,l="function"==typeof e.model.value?e.model.value(i.viewItem,r):e.model.value;if(null===l)return;i.modelRange||Object.assign(i,r.convertChildren(i.viewItem,i.modelCursor));const c=function(e,t,o,n){let i=!1;for(const r of Array.from(e.getItems({shallow:o})))n.schema.checkAttribute(r,t.key)&&(i=!0,r.hasAttribute(t.key)||n.writer.setAttribute(t.key,t.value,r));return i}(i.modelRange,{key:a,value:l},t,r);c&&(r.consumable.test(i.viewItem,{name:!0})&&(s.match.name=!0),r.consumable.consume(i.viewItem,s.match))}}function jc(e,t){return{view:`${e.view}-${t}`,model:(t,o)=>{const n=t.getAttribute("name"),i=e.model(n,o);return o.writer.createElement("$marker",{"data-name":i})}}}function qc(e){e.document.registerPostFixer((t=>function(e,t){const o=t.document.selection,n=t.schema,i=[];let r=!1;for(const e of o.getRanges()){const t=Uc(e,n);t&&!t.isEqual(e)?(i.push(t),r=!0):i.push(e)}r&&e.setSelection(function(e){const t=[...e],o=new Set;let n=1;for(;n!o.has(t)))}(i),{backward:o.isBackward});return!1}(t,e)))}function Uc(e,t){return e.isCollapsed?function(e,t){const o=e.start,n=t.getNearestSelectionRange(o);if(!n){const e=o.getAncestors().reverse().find((e=>t.isObject(e)));return e?Zl._createOn(e):null}if(!n.isCollapsed)return n;const i=n.start;if(o.isEqual(i))return null;return new Zl(i)}(e,t):function(e,t){const{start:o,end:n}=e,i=t.checkChild(o,"$text"),r=t.checkChild(n,"$text"),s=t.getLimitElement(o),a=t.getLimitElement(n);if(s===a){if(i&&r)return null;if(function(e,t,o){const n=e.nodeAfter&&!o.isLimit(e.nodeAfter)||o.checkChild(e,"$text"),i=t.nodeBefore&&!o.isLimit(t.nodeBefore)||o.checkChild(t,"$text");return n||i}(o,n,t)){const e=o.nodeAfter&&t.isSelectable(o.nodeAfter)?null:t.getNearestSelectionRange(o,"forward"),i=n.nodeBefore&&t.isSelectable(n.nodeBefore)?null:t.getNearestSelectionRange(n,"backward"),r=e?e.start:o,s=i?i.end:n;return new Zl(r,s)}}const l=s&&!s.is("rootElement"),c=a&&!a.is("rootElement");if(l||c){const e=o.nodeAfter&&n.nodeBefore&&o.nodeAfter.parent===n.nodeBefore.parent,i=l&&(!e||!$c(o.nodeAfter,t)),r=c&&(!e||!$c(n.nodeBefore,t));let d=o,u=n;return i&&(d=ql._createBefore(Wc(s,t))),r&&(u=ql._createAfter(Wc(a,t))),new Zl(d,u)}return null}(e,t)}function Wc(e,t){let o=e,n=o;for(;t.isLimit(n)&&n.parent;)o=n,n=n.parent;return o}function $c(e,t){return e&&t.isSelectable(e)}class Gc extends(Y()){constructor(e,t){super(),this.model=e,this.view=new Ml(t),this.mapper=new Jl,this.downcastDispatcher=new Xl({mapper:this.mapper,schema:e.schema});const o=this.model.document,n=o.selection,i=this.model.markers;var s,a,l;this.listenTo(this.model,"_beforeChanges",(()=>{this.view._disableRendering(!0)}),{priority:"highest"}),this.listenTo(this.model,"_afterChanges",(()=>{this.view._disableRendering(!1)}),{priority:"lowest"}),this.listenTo(o,"change",(()=>{this.view.change((e=>{this.downcastDispatcher.convertChanges(o.differ,i,e),this.downcastDispatcher.convertSelection(n,i,e)}))}),{priority:"low"}),this.listenTo(this.view.document,"selectionChange",function(e,t){return(o,n)=>{const i=n.newSelection,r=[];for(const e of i.getRanges())r.push(t.toModelRange(e));const s=e.createSelection(r,{backward:i.isBackward});s.isEqual(e.document.selection)||e.change((e=>{e.setSelection(s)}))}}(this.model,this.mapper)),this.listenTo(this.view.document,"beforeinput",(s=this.mapper,a=this.model.schema,l=this.view,(e,t)=>{if(!l.document.isComposing||r.isAndroid)for(let e=0;e{if(!o.consumable.consume(t.item,e.name))return;const n=o.writer,i=o.mapper.toViewPosition(t.range.start),r=n.createText(t.item.data);n.insert(i,r)}),{priority:"lowest"}),this.downcastDispatcher.on("insert",((e,t,o)=>{o.convertAttributes(t.item),t.reconversion||!t.item.is("element")||t.item.isEmpty||o.convertChildren(t.item)}),{priority:"lowest"}),this.downcastDispatcher.on("remove",((e,t,o)=>{const n=o.mapper.toViewPosition(t.position),i=t.position.getShiftedBy(t.length),r=o.mapper.toViewPosition(i,{isPhantom:!0}),s=o.writer.createRange(n,r),a=o.writer.remove(s.getTrimmed());for(const e of o.writer.createRangeIn(a).getItems())o.mapper.unbindViewElement(e,{defer:!0})}),{priority:"low"}),this.downcastDispatcher.on("cleanSelection",((e,t,o)=>{const n=o.writer,i=n.document.selection;for(const e of i.getRanges())e.isCollapsed&&e.end.parent.isAttached()&&o.writer.mergeAttributes(e.start);n.setSelection(null)})),this.downcastDispatcher.on("selection",((e,t,o)=>{const n=t.selection;if(n.isCollapsed)return;if(!o.consumable.consume(n,"selection"))return;const i=[];for(const e of n.getRanges())i.push(o.mapper.toViewRange(e));o.writer.setSelection(i,{backward:n.isBackward})}),{priority:"low"}),this.downcastDispatcher.on("selection",((e,t,o)=>{const n=t.selection;if(!n.isCollapsed)return;if(!o.consumable.consume(n,"selection"))return;const i=o.writer,r=n.getFirstPosition(),s=o.mapper.toViewPosition(r),a=i.breakAttributes(s);i.setSelection(a)}),{priority:"low"}),this.view.document.roots.bindTo(this.model.document.roots).using((e=>{if("$graveyard"==e.rootName)return null;const t=new Ds(this.view.document,e.name);return t.rootName=e.rootName,this.mapper.bindElements(e,t),t}))}destroy(){this.view.destroy(),this.stopListening()}reconvertMarker(e){const t="string"==typeof e?e:e.name,o=this.model.markers.get(t);if(!o)throw new E("editingcontroller-reconvertmarker-marker-not-exist",this,{markerName:t});this.model.change((()=>{this.model.markers._refresh(o)}))}reconvertItem(e){this.model.change((()=>{this.model.document.differ._refreshItem(e)}))}}class Kc{constructor(){this._consumables=new Map}add(e,t){let o;e.is("$text")||e.is("documentFragment")?this._consumables.set(e,!0):(this._consumables.has(e)?o=this._consumables.get(e):(o=new Jc(e),this._consumables.set(e,o)),o.add(t))}test(e,t){const o=this._consumables.get(e);return void 0===o?null:e.is("$text")||e.is("documentFragment")?o:o.test(t)}consume(e,t){return!!this.test(e,t)&&(e.is("$text")||e.is("documentFragment")?this._consumables.set(e,!1):this._consumables.get(e).consume(t),!0)}revert(e,t){const o=this._consumables.get(e);void 0!==o&&(e.is("$text")||e.is("documentFragment")?this._consumables.set(e,!0):o.revert(t))}static consumablesFromElement(e){const t={element:e,name:!0,attributes:[],classes:[],styles:[]},o=e.getAttributeKeys();for(const e of o)"style"!=e&&"class"!=e&&t.attributes.push(e);const n=e.getClassNames();for(const e of n)t.classes.push(e);const i=e.getStyleNames();for(const e of i)t.styles.push(e);return t}static createFrom(e,t){if(t||(t=new Kc),e.is("$text"))return t.add(e),t;e.is("element")&&t.add(e,Kc.consumablesFromElement(e)),e.is("documentFragment")&&t.add(e);for(const o of e.getChildren())t=Kc.createFrom(o,t);return t}}const Zc=["attributes","classes","styles"];class Jc{constructor(e){this.element=e,this._canConsumeName=null,this._consumables={attributes:new Map,styles:new Map,classes:new Map}}add(e){e.name&&(this._canConsumeName=!0);for(const t of Zc)t in e&&this._add(t,e[t])}test(e){if(e.name&&!this._canConsumeName)return this._canConsumeName;for(const t of Zc)if(t in e){const o=this._test(t,e[t]);if(!0!==o)return o}return!0}consume(e){e.name&&(this._canConsumeName=!1);for(const t of Zc)t in e&&this._consume(t,e[t])}revert(e){e.name&&(this._canConsumeName=!0);for(const t of Zc)t in e&&this._revert(t,e[t])}_add(e,t){const o=xi(t),n=this._consumables[e];for(const t of o){if("attributes"===e&&("class"===t||"style"===t))throw new E("viewconsumable-invalid-attribute",this);if(n.set(t,!0),"styles"===e)for(const e of this.element.document.stylesProcessor.getRelatedStyles(t))n.set(e,!0)}}_test(e,t){const o=xi(t),n=this._consumables[e];for(const t of o)if("attributes"!==e||"class"!==t&&"style"!==t){const e=n.get(t);if(void 0===e)return null;if(!e)return!1}else{const e="class"==t?"classes":"styles",o=this._test(e,[...this._consumables[e].keys()]);if(!0!==o)return o}return!0}_consume(e,t){const o=xi(t),n=this._consumables[e];for(const t of o)if("attributes"!==e||"class"!==t&&"style"!==t){if(n.set(t,!1),"styles"==e)for(const e of this.element.document.stylesProcessor.getRelatedStyles(t))n.set(e,!1)}else{const e="class"==t?"classes":"styles";this._consume(e,[...this._consumables[e].keys()])}}_revert(e,t){const o=xi(t),n=this._consumables[e];for(const t of o)if("attributes"!==e||"class"!==t&&"style"!==t){!1===n.get(t)&&n.set(t,!0)}else{const e="class"==t?"classes":"styles";this._revert(e,[...this._consumables[e].keys()])}}}class Yc extends(Y()){constructor(){super(),this._sourceDefinitions={},this._attributeProperties={},this._customChildChecks=new Map,this._customAttributeChecks=new Map,this._genericCheckSymbol=Symbol("$generic"),this.decorate("checkChild"),this.decorate("checkAttribute"),this.on("checkAttribute",((e,t)=>{t[0]=new Qc(t[0])}),{priority:"highest"}),this.on("checkChild",((e,t)=>{t[0]=new Qc(t[0]),t[1]=this.getDefinition(t[1])}),{priority:"highest"})}register(e,t){if(this._sourceDefinitions[e])throw new E("schema-cannot-register-item-twice",this,{itemName:e});this._sourceDefinitions[e]=[Object.assign({},t)],this._clearCache()}extend(e,t){if(!this._sourceDefinitions[e])throw new E("schema-cannot-extend-missing-item",this,{itemName:e});this._sourceDefinitions[e].push(Object.assign({},t)),this._clearCache()}getDefinitions(){return this._compiledDefinitions||this._compile(),this._compiledDefinitions}getDefinition(e){let t;return t="string"==typeof e?e:"is"in e&&(e.is("$text")||e.is("$textProxy"))?"$text":e.name,this.getDefinitions()[t]}isRegistered(e){return!!this.getDefinition(e)}isBlock(e){const t=this.getDefinition(e);return!(!t||!t.isBlock)}isLimit(e){const t=this.getDefinition(e);return!!t&&!(!t.isLimit&&!t.isObject)}isObject(e){const t=this.getDefinition(e);return!!t&&!!(t.isObject||t.isLimit&&t.isSelectable&&t.isContent)}isInline(e){const t=this.getDefinition(e);return!(!t||!t.isInline)}isSelectable(e){const t=this.getDefinition(e);return!!t&&!(!t.isSelectable&&!t.isObject)}isContent(e){const t=this.getDefinition(e);return!!t&&!(!t.isContent&&!t.isObject)}checkChild(e,t){return!!t&&this._checkContextMatch(e,t)}checkAttribute(e,t){const o=this.getDefinition(e.last);if(!o)return!1;const n=this._evaluateAttributeChecks(e,t);return void 0!==n?n:o.allowAttributes.includes(t)}checkMerge(e,t){if(e instanceof ql){const t=e.nodeBefore,o=e.nodeAfter;if(!(t instanceof Ll))throw new E("schema-check-merge-no-element-before",this);if(!(o instanceof Ll))throw new E("schema-check-merge-no-element-after",this);return this.checkMerge(t,o)}if(this.isLimit(e)||this.isLimit(t))return!1;for(const o of t.getChildren())if(!this.checkChild(e,o))return!1;return!0}addChildCheck(e,t){const o=void 0!==t?t:this._genericCheckSymbol,n=this._customChildChecks.get(o)||[];n.push(e),this._customChildChecks.set(o,n)}addAttributeCheck(e,t){const o=void 0!==t?t:this._genericCheckSymbol,n=this._customAttributeChecks.get(o)||[];n.push(e),this._customAttributeChecks.set(o,n)}setAttributeProperties(e,t){this._attributeProperties[e]=Object.assign(this.getAttributeProperties(e),t)}getAttributeProperties(e){return this._attributeProperties[e]||{}}getLimitElement(e){let t;if(e instanceof ql)t=e.parent;else{t=(e instanceof Zl?[e]:Array.from(e.getRanges())).reduce(((e,t)=>{const o=t.getCommonAncestor();return e?e.getCommonAncestor(o,{includeSelf:!0}):o}),null)}for(;!this.isLimit(t)&&t.parent;)t=t.parent;return t}checkAttributeInSelection(e,t){if(e.isCollapsed){const o=[...e.getFirstPosition().getAncestors(),new Ol("",e.getAttributes())];return this.checkAttribute(o,t)}{const o=e.getRanges();for(const e of o)for(const o of e)if(this.checkAttribute(o.item,t))return!0}return!1}*getValidRanges(e,t){e=function*(e){for(const t of e)yield*t.getMinimalFlatRanges()}(e);for(const o of e)yield*this._getValidRangesForRange(o,t)}getNearestSelectionRange(e,t="both"){if("$graveyard"==e.root.rootName)return null;if(this.checkChild(e,"$text"))return new Zl(e);let o,n;const i=e.getAncestors().reverse().find((e=>this.isLimit(e)))||e.root;"both"!=t&&"backward"!=t||(o=new Hl({boundaries:Zl._createIn(i),startPosition:e,direction:"backward"})),"both"!=t&&"forward"!=t||(n=new Hl({boundaries:Zl._createIn(i),startPosition:e}));for(const e of function*(e,t){let o=!1;for(;!o;){if(o=!0,e){const t=e.next();t.done||(o=!1,yield{walker:e,value:t.value})}if(t){const e=t.next();e.done||(o=!1,yield{walker:t,value:e.value})}}}(o,n)){const t=e.walker==o?"elementEnd":"elementStart",n=e.value;if(n.type==t&&this.isObject(n.item))return Zl._createOn(n.item);if(this.checkChild(n.nextPosition,"$text"))return new Zl(n.nextPosition)}return null}findAllowedParent(e,t){let o=e.parent;for(;o;){if(this.checkChild(o,t))return o;if(this.isLimit(o))return null;o=o.parent}return null}setAllowedAttributes(e,t,o){const n=o.model;for(const[i,r]of Object.entries(t))n.schema.checkAttribute(e,i)&&o.setAttribute(i,r,e)}removeDisallowedAttributes(e,t){for(const o of e)if(o.is("$text"))ud(this,o,t);else{const e=Zl._createIn(o).getPositions();for(const o of e){ud(this,o.nodeBefore||o.parent,t)}}}getAttributesWithProperty(e,t,o){const n={};for(const[i,r]of e.getAttributes()){const e=this.getAttributeProperties(i);void 0!==e[t]&&(void 0!==o&&o!==e[t]||(n[i]=r))}return n}createContext(e){return new Qc(e)}_clearCache(){this._compiledDefinitions=null}_compile(){const e={},t=this._sourceDefinitions,o=Object.keys(t);for(const n of o)e[n]=Xc(t[n],n);const n=Object.values(e);for(const t of n)ed(e,t),td(e,t),od(e,t),nd(e,t);for(const t of n)id(e,t);for(const t of n)rd(e,t);for(const t of n)sd(e,t);for(const t of n)ad(e,t);for(const t of n)ld(e,t);this._compiledDefinitions=function(e){const t={};for(const o of Object.values(e))t[o.name]={name:o.name,isBlock:!!o.isBlock,isContent:!!o.isContent,isInline:!!o.isInline,isLimit:!!o.isLimit,isObject:!!o.isObject,isSelectable:!!o.isSelectable,allowIn:Array.from(o.allowIn).filter((t=>!!e[t])),allowChildren:Array.from(o.allowChildren).filter((t=>!!e[t])),allowAttributes:Array.from(o.allowAttributes)};return t}(e)}_checkContextMatch(e,t){const o=e.last;let n=this._evaluateChildChecks(e,t);if(n=void 0!==n?n:t.allowIn.includes(o.name),!n)return!1;const i=this.getDefinition(o),r=e.trimLast();return!!i&&(0==r.length||this._checkContextMatch(r,i))}_evaluateChildChecks(e,t){const o=this._customChildChecks.get(this._genericCheckSymbol)||[],n=this._customChildChecks.get(t.name)||[];for(const i of[...o,...n]){const o=i(e,t);if(void 0!==o)return o}}_evaluateAttributeChecks(e,t){const o=this._customAttributeChecks.get(this._genericCheckSymbol)||[],n=this._customAttributeChecks.get(t)||[];for(const i of[...o,...n]){const o=i(e,t);if(void 0!==o)return o}}*_getValidRangesForRange(e,t){let o=e.start,n=e.start;for(const i of e.getItems({shallow:!0}))i.is("element")&&(yield*this._getValidRangesForRange(Zl._createIn(i),t)),this.checkAttribute(i,t)||(o.isEqual(n)||(yield new Zl(o,n)),o=ql._createAfter(i)),n=ql._createAfter(i);o.isEqual(n)||(yield new Zl(o,n))}findOptimalInsertionRange(e,t){const o=e.getSelectedElement();if(o&&this.isObject(o)&&!this.isInline(o))return"before"==t||"after"==t?new Zl(ql._createAt(o,t)):Zl._createOn(o);const n=Qi(e.getSelectedBlocks());if(!n)return new Zl(e.focus);if(n.isEmpty)return new Zl(ql._createAt(n,0));const i=ql._createAfter(n);return e.focus.isTouching(i)?new Zl(i):new Zl(ql._createBefore(n))}}class Qc{constructor(e){if(e instanceof Qc)return e;let t;t="string"==typeof e?[e]:Array.isArray(e)?e:e.getAncestors({includeSelf:!0}),this._items=t.map(dd)}get length(){return this._items.length}get last(){return this._items[this._items.length-1]}[Symbol.iterator](){return this._items[Symbol.iterator]()}push(e){const t=new Qc([e]);return t._items=[...this._items,...t._items],t}trimLast(){const e=new Qc([]);return e._items=this._items.slice(0,-1),e}getItem(e){return this._items[e]}*getNames(){yield*this._items.map((e=>e.name))}endsWith(e){return Array.from(this.getNames()).join(" ").endsWith(e)}startsWith(e){return Array.from(this.getNames()).join(" ").startsWith(e)}}function Xc(e,t){const o={name:t,allowIn:new Set,allowChildren:new Set,disallowIn:new Set,disallowChildren:new Set,allowContentOf:new Set,allowWhere:new Set,allowAttributes:new Set,disallowAttributes:new Set,allowAttributesOf:new Set,inheritTypesFrom:new Set};return function(e,t){for(const o of e){const e=Object.keys(o).filter((e=>e.startsWith("is")));for(const n of e)t[n]=!!o[n]}}(e,o),cd(e,o,"allowIn"),cd(e,o,"allowChildren"),cd(e,o,"disallowIn"),cd(e,o,"disallowChildren"),cd(e,o,"allowContentOf"),cd(e,o,"allowWhere"),cd(e,o,"allowAttributes"),cd(e,o,"disallowAttributes"),cd(e,o,"allowAttributesOf"),cd(e,o,"inheritTypesFrom"),function(e,t){for(const o of e){const e=o.inheritAllFrom;e&&(t.allowContentOf.add(e),t.allowWhere.add(e),t.allowAttributesOf.add(e),t.inheritTypesFrom.add(e))}}(e,o),o}function ed(e,t){for(const o of t.allowIn){const n=e[o];n?n.allowChildren.add(t.name):t.allowIn.delete(o)}}function td(e,t){for(const o of t.allowChildren){const n=e[o];n?n.allowIn.add(t.name):t.allowChildren.delete(o)}}function od(e,t){for(const o of t.disallowIn){const n=e[o];n?n.disallowChildren.add(t.name):t.disallowIn.delete(o)}}function nd(e,t){for(const o of t.disallowChildren){const n=e[o];n?n.disallowIn.add(t.name):t.disallowChildren.delete(o)}}function id(e,t){for(const e of t.disallowChildren)t.allowChildren.delete(e);for(const e of t.disallowIn)t.allowIn.delete(e);for(const e of t.disallowAttributes)t.allowAttributes.delete(e)}function rd(e,t){for(const o of t.allowContentOf){const n=e[o];n&&(n.disallowChildren.forEach((o=>{t.allowChildren.has(o)||(t.disallowChildren.add(o),e[o].disallowIn.add(t.name))})),n.allowChildren.forEach((o=>{t.disallowChildren.has(o)||(t.allowChildren.add(o),e[o].allowIn.add(t.name))})))}}function sd(e,t){for(const o of t.allowWhere){const n=e[o];n&&(n.disallowIn.forEach((o=>{t.allowIn.has(o)||(t.disallowIn.add(o),e[o].disallowChildren.add(t.name))})),n.allowIn.forEach((o=>{t.disallowIn.has(o)||(t.allowIn.add(o),e[o].allowChildren.add(t.name))})))}}function ad(e,t){for(const o of t.allowAttributesOf){const n=e[o];if(!n)return;n.allowAttributes.forEach((e=>{t.disallowAttributes.has(e)||t.allowAttributes.add(e)}))}}function ld(e,t){for(const o of t.inheritTypesFrom){const n=e[o];if(n){const e=Object.keys(n).filter((e=>e.startsWith("is")));for(const o of e)o in t||(t[o]=n[o])}}}function cd(e,t,o){for(const n of e){let e=n[o];"string"==typeof e&&(e=[e]),Array.isArray(e)&&e.forEach((e=>t[o].add(e)))}}function dd(e){return"string"==typeof e||e.is("documentFragment")?{name:"string"==typeof e?e:"$documentFragment",*getAttributeKeys(){},getAttribute(){}}:{name:e.is("element")?e.name:"$text",*getAttributeKeys(){yield*e.getAttributeKeys()},getAttribute:t=>e.getAttribute(t)}}function ud(e,t,o){for(const n of t.getAttributeKeys())e.checkAttribute(t,n)||o.removeAttribute(n,t)}class hd extends(z()){constructor(e){super(),this._splitParts=new Map,this._cursorParents=new Map,this._modelCursor=null,this._emptyElementsToKeep=new Set,this.conversionApi={...e,consumable:null,writer:null,store:null,convertItem:(e,t)=>this._convertItem(e,t),convertChildren:(e,t)=>this._convertChildren(e,t),safeInsert:(e,t)=>this._safeInsert(e,t),updateConversionResult:(e,t)=>this._updateConversionResult(e,t),splitToAllowedParent:(e,t)=>this._splitToAllowedParent(e,t),getSplitParts:e=>this._getSplitParts(e),keepEmptyElement:e=>this._keepEmptyElement(e)}}convert(e,t,o=["$root"]){this.fire("viewCleanup",e),this._modelCursor=function(e,t){let o;for(const n of new Qc(e)){const e={};for(const t of n.getAttributeKeys())e[t]=n.getAttribute(t);const i=t.createElement(n.name,e);o&&t.insert(i,o),o=ql._createAt(i,0)}return o}(o,t),this.conversionApi.writer=t,this.conversionApi.consumable=Kc.createFrom(e),this.conversionApi.store={};const{modelRange:n}=this._convertItem(e,this._modelCursor),i=t.createDocumentFragment();if(n){this._removeEmptyElements();for(const e of Array.from(this._modelCursor.parent.getChildren()))t.append(e,i);i.markers=function(e,t){const o=new Set,n=new Map,i=Zl._createIn(e).getItems();for(const e of i)e.is("element","$marker")&&o.add(e);for(const e of o){const o=e.getAttribute("data-name"),i=t.createPositionBefore(e);n.has(o)?n.get(o).end=i.clone():n.set(o,new Zl(i.clone())),t.remove(e)}return n}(i,t)}return this._modelCursor=null,this._splitParts.clear(),this._cursorParents.clear(),this._emptyElementsToKeep.clear(),this.conversionApi.writer=null,this.conversionApi.store=null,i}_convertItem(e,t){const o={viewItem:e,modelCursor:t,modelRange:null};if(e.is("element")?this.fire(`element:${e.name}`,o,this.conversionApi):e.is("$text")?this.fire("text",o,this.conversionApi):this.fire("documentFragment",o,this.conversionApi),o.modelRange&&!(o.modelRange instanceof Zl))throw new E("view-conversion-dispatcher-incorrect-result",this);return{modelRange:o.modelRange,modelCursor:o.modelCursor}}_convertChildren(e,t){let o=t.is("position")?t:ql._createAt(t,0);const n=new Zl(o);for(const t of Array.from(e.getChildren())){const e=this._convertItem(t,o);e.modelRange instanceof Zl&&(n.end=e.modelRange.end,o=e.modelCursor)}return{modelRange:n,modelCursor:o}}_safeInsert(e,t){const o=this._splitToAllowedParent(e,t);return!!o&&(this.conversionApi.writer.insert(e,o.position),!0)}_updateConversionResult(e,t){const o=this._getSplitParts(e),n=this.conversionApi.writer;t.modelRange||(t.modelRange=n.createRange(n.createPositionBefore(e),n.createPositionAfter(o[o.length-1])));const i=this._cursorParents.get(e);t.modelCursor=i?n.createPositionAt(i,0):t.modelRange.end}_splitToAllowedParent(e,t){const{schema:o,writer:n}=this.conversionApi;let i=o.findAllowedParent(t,e);if(i){if(i===t.parent)return{position:t};this._modelCursor.parent.getAncestors().includes(i)&&(i=null)}if(!i)return Mc(t,e,o)?{position:Rc(t,n)}:null;const r=this.conversionApi.writer.split(t,i),s=[];for(const e of r.range.getWalker())if("elementEnd"==e.type)s.push(e.item);else{const t=s.pop(),o=e.item;this._registerSplitPair(t,o)}const a=r.range.end.parent;return this._cursorParents.set(e,a),{position:r.position,cursorParent:a}}_registerSplitPair(e,t){this._splitParts.has(e)||this._splitParts.set(e,[e]);const o=this._splitParts.get(e);this._splitParts.set(t,o),o.push(t)}_getSplitParts(e){let t;return t=this._splitParts.has(e)?this._splitParts.get(e):[e],t}_keepEmptyElement(e){this._emptyElementsToKeep.add(e)}_removeEmptyElements(){let e=!1;for(const t of this._splitParts.keys())t.isEmpty&&!this._emptyElementsToKeep.has(t)&&(this.conversionApi.writer.remove(t),this._splitParts.delete(t),e=!0);e&&this._removeEmptyElements()}}class md{getHtml(e){const o=t.document.implementation.createHTMLDocument("").createElement("div");return o.appendChild(e),o.innerHTML}}class pd{constructor(e){this.skipComments=!0,this.domParser=new DOMParser,this.domConverter=new Pa(e,{renderingMode:"data"}),this.htmlWriter=new md}toData(e){const t=this.domConverter.viewToDom(e);return this.htmlWriter.getHtml(t)}toView(e){const t=this._toDom(e);return this.domConverter.domToView(t,{skipComments:this.skipComments})}registerRawContentMatcher(e){this.domConverter.registerRawContentMatcher(e)}useFillerType(e){this.domConverter.blockFillerMode="marked"==e?"markedNbsp":"nbsp"}_toDom(e){e.match(/<(?:html|body|head|meta)(?:\s[^>]*)?>/i)||(e=`${e}`);const t=this.domParser.parseFromString(e,"text/html"),o=t.createDocumentFragment(),n=t.body.childNodes;for(;n.length>0;)o.appendChild(n[0]);return o}}class gd extends(z()){constructor(e,t){super(),this.model=e,this.mapper=new Jl,this.downcastDispatcher=new Xl({mapper:this.mapper,schema:e.schema}),this.downcastDispatcher.on("insert:$text",((e,t,o)=>{if(!o.consumable.consume(t.item,e.name))return;const n=o.writer,i=o.mapper.toViewPosition(t.range.start),r=n.createText(t.item.data);n.insert(i,r)}),{priority:"lowest"}),this.downcastDispatcher.on("insert",((e,t,o)=>{o.convertAttributes(t.item),t.reconversion||!t.item.is("element")||t.item.isEmpty||o.convertChildren(t.item)}),{priority:"lowest"}),this.upcastDispatcher=new hd({schema:e.schema}),this.viewDocument=new Hs(t),this.stylesProcessor=t,this.htmlProcessor=new pd(this.viewDocument),this.processor=this.htmlProcessor,this._viewWriter=new ea(this.viewDocument),this.upcastDispatcher.on("text",((e,t,{schema:o,consumable:n,writer:i})=>{let r=t.modelCursor;if(!n.test(t.viewItem))return;if(!o.checkChild(r,"$text")){if(!Mc(r,"$text",o))return;if(0==t.viewItem.data.trim().length)return;r=Rc(r,i)}n.consume(t.viewItem);const s=i.createText(t.viewItem.data);i.insert(s,r),t.modelRange=i.createRange(r,r.getShiftedBy(s.offsetSize)),t.modelCursor=t.modelRange.end}),{priority:"lowest"}),this.upcastDispatcher.on("element",((e,t,o)=>{if(!t.modelRange&&o.consumable.consume(t.viewItem,{name:!0})){const{modelRange:e,modelCursor:n}=o.convertChildren(t.viewItem,t.modelCursor);t.modelRange=e,t.modelCursor=n}}),{priority:"lowest"}),this.upcastDispatcher.on("documentFragment",((e,t,o)=>{if(!t.modelRange&&o.consumable.consume(t.viewItem,{name:!0})){const{modelRange:e,modelCursor:n}=o.convertChildren(t.viewItem,t.modelCursor);t.modelRange=e,t.modelCursor=n}}),{priority:"lowest"}),Y().prototype.decorate.call(this,"init"),Y().prototype.decorate.call(this,"set"),Y().prototype.decorate.call(this,"get"),Y().prototype.decorate.call(this,"toView"),Y().prototype.decorate.call(this,"toModel"),this.on("init",(()=>{this.fire("ready")}),{priority:"lowest"}),this.on("ready",(()=>{this.model.enqueueChange({isUndoable:!1},Fc)}),{priority:"lowest"})}get(e={}){const{rootName:t="main",trim:o="empty"}=e;if(!this._checkIfRootsExists([t]))throw new E("datacontroller-get-non-existent-root",this);const n=this.model.document.getRoot(t);return n.isAttached()||D("datacontroller-get-detached-root",this),"empty"!==o||this.model.hasContent(n,{ignoreWhitespaces:!0})?this.stringify(n,e):""}stringify(e,t={}){const o=this.toView(e,t);return this.processor.toData(o)}toView(e,t={}){const o=this.viewDocument,n=this._viewWriter;this.mapper.clearBindings();const i=Zl._createIn(e),r=new Xs(o);this.mapper.bindElements(e,r);const s=e.is("documentFragment")?e.markers:function(e){const t=[],o=e.root.document;if(!o)return new Map;const n=Zl._createIn(e);for(const e of o.model.markers){const o=e.getRange(),i=o.isCollapsed,r=o.start.isEqual(n.start)||o.end.isEqual(n.end);if(i&&r)t.push([e.name,o]);else{const i=n.getIntersection(o);i&&t.push([e.name,i])}}return t.sort((([e,t],[o,n])=>{if("after"!==t.end.compareWith(n.start))return 1;if("before"!==t.start.compareWith(n.end))return-1;switch(t.start.compareWith(n.start)){case"before":return 1;case"after":return-1;default:switch(t.end.compareWith(n.end)){case"before":return 1;case"after":return-1;default:return o.localeCompare(e)}}})),new Map(t)}(e);return this.downcastDispatcher.convert(i,s,n,t),r}init(e){if(this.model.document.version)throw new E("datacontroller-init-document-not-empty",this);let t={};if("string"==typeof e?t.main=e:t=e,!this._checkIfRootsExists(Object.keys(t)))throw new E("datacontroller-init-non-existent-root",this);return this.model.enqueueChange({isUndoable:!1},(e=>{for(const o of Object.keys(t)){const n=this.model.document.getRoot(o);e.insert(this.parse(t[o],n),n,0)}})),Promise.resolve()}set(e,t={}){let o={};if("string"==typeof e?o.main=e:o=e,!this._checkIfRootsExists(Object.keys(o)))throw new E("datacontroller-set-non-existent-root",this);this.model.enqueueChange(t.batchType||{},(e=>{e.setSelection(null),e.removeSelectionAttribute(this.model.document.selection.getAttributeKeys());for(const t of Object.keys(o)){const n=this.model.document.getRoot(t);e.remove(e.createRangeIn(n)),e.insert(this.parse(o[t],n),n,0)}}))}parse(e,t="$root"){const o=this.processor.toView(e);return this.toModel(o,t)}toModel(e,t="$root"){return this.model.change((o=>this.upcastDispatcher.convert(e,o,t)))}addStyleProcessorRules(e){e(this.stylesProcessor)}registerRawContentMatcher(e){this.processor&&this.processor!==this.htmlProcessor&&this.processor.registerRawContentMatcher(e),this.htmlProcessor.registerRawContentMatcher(e)}destroy(){this.stopListening()}_checkIfRootsExists(e){for(const t of e)if(!this.model.document.getRoot(t))return!1;return!0}}class fd{constructor(e,t){this._helpers=new Map,this._downcast=xi(e),this._createConversionHelpers({name:"downcast",dispatchers:this._downcast,isDowncast:!0}),this._upcast=xi(t),this._createConversionHelpers({name:"upcast",dispatchers:this._upcast,isDowncast:!1})}addAlias(e,t){const o=this._downcast.includes(t);if(!this._upcast.includes(t)&&!o)throw new E("conversion-add-alias-dispatcher-not-registered",this);this._createConversionHelpers({name:e,dispatchers:[t],isDowncast:o})}for(e){if(!this._helpers.has(e))throw new E("conversion-for-unknown-group",this);return this._helpers.get(e)}elementToElement(e){this.for("downcast").elementToElement(e);for(const{model:t,view:o}of bd(e))this.for("upcast").elementToElement({model:t,view:o,converterPriority:e.converterPriority})}attributeToElement(e){this.for("downcast").attributeToElement(e);for(const{model:t,view:o}of bd(e))this.for("upcast").elementToAttribute({view:o,model:t,converterPriority:e.converterPriority})}attributeToAttribute(e){this.for("downcast").attributeToAttribute(e);for(const{model:t,view:o}of bd(e))this.for("upcast").attributeToAttribute({view:o,model:t})}_createConversionHelpers({name:e,dispatchers:t,isDowncast:o}){if(this._helpers.has(e))throw new E("conversion-group-exists",this);const n=o?new bc(t):new zc(t);this._helpers.set(e,n)}}function*bd(e){if(e.model.values)for(const t of e.model.values){const o={key:e.model.key,value:t},n=e.view[t],i=e.upcastAlso?e.upcastAlso[t]:void 0;yield*kd(o,n,i)}else yield*kd(e.model,e.view,e.upcastAlso)}function*kd(e,t,o){if(yield{model:e,view:t},o)for(const t of xi(o))yield{model:e,view:t}}class wd{constructor(e){this.baseVersion=e,this.isDocumentOperation=null!==this.baseVersion,this.batch=null}_validate(){}toJSON(){const e=Object.assign({},this);return e.__className=this.constructor.className,delete e.batch,delete e.isDocumentOperation,e}static get className(){return"Operation"}static fromJSON(e,t){return new this(e.baseVersion)}}function _d(e,t){const o=Cd(t),n=o.reduce(((e,t)=>e+t.offsetSize),0),i=e.parent;xd(e);const r=e.index;return i._insertChild(r,o),vd(i,r+o.length),vd(i,r),new Zl(e,e.getShiftedBy(n))}function yd(e){if(!e.isFlat)throw new E("operation-utils-remove-range-not-flat",this);const t=e.start.parent;xd(e.start),xd(e.end);const o=t._removeChildren(e.start.index,e.end.index-e.start.index);return vd(t,e.start.index),o}function Ad(e,t){if(!e.isFlat)throw new E("operation-utils-move-range-not-flat",this);const o=yd(e);return _d(t=t._getTransformedByDeletion(e.start,e.end.offset-e.start.offset),o)}function Cd(e){const t=[];!function e(o){if("string"==typeof o)t.push(new Ol(o));else if(o instanceof Nl)t.push(new Ol(o.data,o.getAttributes()));else if(o instanceof zl)t.push(o);else if(re(o))for(const t of o)e(t);else{}}(e);for(let e=1;ee.maxOffset)throw new E("move-operation-nodes-do-not-exist",this);if(e===t&&o=o&&this.targetPosition.path[e]e._clone(!0)))),t=new Bd(this.position,e,this.baseVersion);return t.shouldReceiveAttributes=this.shouldReceiveAttributes,t}getReversed(){const e=this.position.root.document.graveyard,t=new ql(e,[0]);return new Dd(this.position,this.nodes.maxOffset,t,this.baseVersion+1)}_validate(){const e=this.position.parent;if(!e||e.maxOffsete._clone(!0)))),_d(this.position,e)}toJSON(){const e=super.toJSON();return e.position=this.position.toJSON(),e.nodes=this.nodes.toJSON(),e}static get className(){return"InsertOperation"}static fromJSON(e,t){const o=[];for(const t of e.nodes)t.name?o.push(Ll.fromJSON(t)):o.push(Ol.fromJSON(t));const n=new Bd(ql.fromJSON(e.position,t),o,e.baseVersion);return n.shouldReceiveAttributes=e.shouldReceiveAttributes,n}}class Sd extends wd{constructor(e,t,o,n,i){super(i),this.splitPosition=e.clone(),this.splitPosition.stickiness="toNext",this.howMany=t,this.insertionPosition=o,this.graveyardPosition=n?n.clone():null,this.graveyardPosition&&(this.graveyardPosition.stickiness="toNext")}get type(){return"split"}get moveTargetPosition(){const e=this.insertionPosition.path.slice();return e.push(0),new ql(this.insertionPosition.root,e)}get movedRange(){const e=this.splitPosition.getShiftedBy(Number.POSITIVE_INFINITY);return new Zl(this.splitPosition,e)}get affectedSelectable(){const e=[Zl._createFromPositionAndShift(this.splitPosition,0),Zl._createFromPositionAndShift(this.insertionPosition,0)];return this.graveyardPosition&&e.push(Zl._createFromPositionAndShift(this.graveyardPosition,0)),e}clone(){return new Sd(this.splitPosition,this.howMany,this.insertionPosition,this.graveyardPosition,this.baseVersion)}getReversed(){const e=this.splitPosition.root.document.graveyard,t=new ql(e,[0]);return new Td(this.moveTargetPosition,this.howMany,this.splitPosition,t,this.baseVersion+1)}_validate(){const e=this.splitPosition.parent,t=this.splitPosition.offset;if(!e||e.maxOffset0&&(e.sourcePosition.isEqual(t.sourcePosition.getShiftedBy(t.howMany))&&this._setRelation(e,t,"mergeSourceAffected"),e.targetPosition.isEqual(t.sourcePosition)&&this._setRelation(e,t,"mergeTargetWasBefore"));else if(e instanceof Id){const o=e.newRange;if(!o)return;if(t instanceof Dd){const n=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany),i=n.containsPosition(o.start)||n.start.isEqual(o.start),r=n.containsPosition(o.end)||n.end.isEqual(o.end);!i&&!r||n.containsRange(o)||this._setRelation(e,t,{side:i?"left":"right",path:i?o.start.path.slice():o.end.path.slice()})}else if(t instanceof Td){const n=o.start.isEqual(t.targetPosition),i=o.start.isEqual(t.deletionPosition),r=o.end.isEqual(t.deletionPosition),s=o.end.isEqual(t.sourcePosition);(n||i||r||s)&&this._setRelation(e,t,{wasInLeftElement:n,wasStartBeforeMergedElement:i,wasEndBeforeMergedElement:r,wasInRightElement:s})}}}getContext(e,t,o){return{aIsStrong:o,aWasUndone:this._wasUndone(e),bWasUndone:this._wasUndone(t),abRelation:this._useRelations?this._getRelation(e,t):null,baRelation:this._useRelations?this._getRelation(t,e):null,forceWeakRemove:this._forceWeakRemove}}_wasUndone(e){const t=this.originalOperations.get(e);return t.wasUndone||this._history.isUndoneOperation(t)}_getRelation(e,t){const o=this.originalOperations.get(t),n=this._history.getUndoneOperation(o);if(!n)return null;const i=this.originalOperations.get(e),r=this._relations.get(i);return r&&r.get(n)||null}_setRelation(e,t,o){const n=this.originalOperations.get(e),i=this.originalOperations.get(t);let r=this._relations.get(n);r||(r=new Map,this._relations.set(n,r)),r.set(i,o)}}function $d(e,t){for(const o of e)o.baseVersion=t++}function Gd(e,t){for(let o=0;o{if(e.key===t.key&&e.range.start.hasSameParentAs(t.range.start)){const n=e.range.getDifference(t.range).map((t=>new Fd(t,e.key,e.oldValue,e.newValue,0))),i=e.range.getIntersection(t.range);return i&&o.aIsStrong&&n.push(new Fd(i,t.key,t.newValue,e.newValue,0)),0==n.length?[new Md(0)]:n}return[e]})),Hd(Fd,Bd,((e,t)=>{if(e.range.start.hasSameParentAs(t.position)&&e.range.containsPosition(t.position)){const o=e.range._getTransformedByInsertion(t.position,t.howMany,!t.shouldReceiveAttributes).map((t=>new Fd(t,e.key,e.oldValue,e.newValue,e.baseVersion)));if(t.shouldReceiveAttributes){const n=Kd(t,e.key,e.oldValue);n&&o.unshift(n)}return o}return e.range=e.range._getTransformedByInsertion(t.position,t.howMany,!1)[0],[e]})),Hd(Fd,Td,((e,t)=>{const o=[];e.range.start.hasSameParentAs(t.deletionPosition)&&(e.range.containsPosition(t.deletionPosition)||e.range.start.isEqual(t.deletionPosition))&&o.push(Zl._createFromPositionAndShift(t.graveyardPosition,1));const n=e.range._getTransformedByMergeOperation(t);return n.isCollapsed||o.push(n),o.map((t=>new Fd(t,e.key,e.oldValue,e.newValue,e.baseVersion)))})),Hd(Fd,Dd,((e,t)=>{const o=function(e,t){const o=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany);let n=null,i=[];o.containsRange(e,!0)?n=e:e.start.hasSameParentAs(o.start)?(i=e.getDifference(o),n=e.getIntersection(o)):i=[e];const r=[];for(let e of i){e=e._getTransformedByDeletion(t.sourcePosition,t.howMany);const o=t.getMovedRangeStart(),n=e.start.hasSameParentAs(o),i=e._getTransformedByInsertion(o,t.howMany,n);r.push(...i)}n&&r.push(n._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany,!1)[0]);return r}(e.range,t);return o.map((t=>new Fd(t,e.key,e.oldValue,e.newValue,e.baseVersion)))})),Hd(Fd,Sd,((e,t)=>{if(e.range.end.isEqual(t.insertionPosition))return t.graveyardPosition||e.range.end.offset++,[e];if(e.range.start.hasSameParentAs(t.splitPosition)&&e.range.containsPosition(t.splitPosition)){const o=e.clone();return o.range=new Zl(t.moveTargetPosition.clone(),e.range.end._getCombined(t.splitPosition,t.moveTargetPosition)),e.range.end=t.splitPosition.clone(),e.range.end.stickiness="toPrevious",[e,o]}return e.range=e.range._getTransformedBySplitOperation(t),[e]})),Hd(Bd,Fd,((e,t)=>{const o=[e];if(e.shouldReceiveAttributes&&e.position.hasSameParentAs(t.range.start)&&t.range.containsPosition(e.position)){const n=Kd(e,t.key,t.newValue);n&&o.push(n)}return o})),Hd(Bd,Bd,((e,t,o)=>(e.position.isEqual(t.position)&&o.aIsStrong||(e.position=e.position._getTransformedByInsertOperation(t)),[e]))),Hd(Bd,Dd,((e,t)=>(e.position=e.position._getTransformedByMoveOperation(t),[e]))),Hd(Bd,Sd,((e,t)=>(e.position=e.position._getTransformedBySplitOperation(t),[e]))),Hd(Bd,Td,((e,t)=>(e.position=e.position._getTransformedByMergeOperation(t),[e]))),Hd(Id,Bd,((e,t)=>(e.oldRange&&(e.oldRange=e.oldRange._getTransformedByInsertOperation(t)[0]),e.newRange&&(e.newRange=e.newRange._getTransformedByInsertOperation(t)[0]),[e]))),Hd(Id,Id,((e,t,o)=>{if(e.name==t.name){if(!o.aIsStrong)return[new Md(0)];e.oldRange=t.newRange?t.newRange.clone():null}return[e]})),Hd(Id,Td,((e,t)=>(e.oldRange&&(e.oldRange=e.oldRange._getTransformedByMergeOperation(t)),e.newRange&&(e.newRange=e.newRange._getTransformedByMergeOperation(t)),[e]))),Hd(Id,Dd,((e,t,o)=>{if(e.oldRange&&(e.oldRange=Zl._createFromRanges(e.oldRange._getTransformedByMoveOperation(t))),e.newRange){if(o.abRelation){const n=Zl._createFromRanges(e.newRange._getTransformedByMoveOperation(t));if("left"==o.abRelation.side&&t.targetPosition.isEqual(e.newRange.start))return e.newRange.end=n.end,e.newRange.start.path=o.abRelation.path,[e];if("right"==o.abRelation.side&&t.targetPosition.isEqual(e.newRange.end))return e.newRange.start=n.start,e.newRange.end.path=o.abRelation.path,[e]}e.newRange=Zl._createFromRanges(e.newRange._getTransformedByMoveOperation(t))}return[e]})),Hd(Id,Sd,((e,t,o)=>{if(e.oldRange&&(e.oldRange=e.oldRange._getTransformedBySplitOperation(t)),e.newRange){if(o.abRelation){const n=e.newRange._getTransformedBySplitOperation(t);return e.newRange.start.isEqual(t.splitPosition)&&o.abRelation.wasStartBeforeMergedElement?e.newRange.start=ql._createAt(t.insertionPosition):e.newRange.start.isEqual(t.splitPosition)&&!o.abRelation.wasInLeftElement&&(e.newRange.start=ql._createAt(t.moveTargetPosition)),e.newRange.end.isEqual(t.splitPosition)&&o.abRelation.wasInRightElement?e.newRange.end=ql._createAt(t.moveTargetPosition):e.newRange.end.isEqual(t.splitPosition)&&o.abRelation.wasEndBeforeMergedElement?e.newRange.end=ql._createAt(t.insertionPosition):e.newRange.end=n.end,[e]}e.newRange=e.newRange._getTransformedBySplitOperation(t)}return[e]})),Hd(Td,Bd,((e,t)=>(e.sourcePosition.hasSameParentAs(t.position)&&(e.howMany+=t.howMany),e.sourcePosition=e.sourcePosition._getTransformedByInsertOperation(t),e.targetPosition=e.targetPosition._getTransformedByInsertOperation(t),[e]))),Hd(Td,Td,((e,t,o)=>{if(e.sourcePosition.isEqual(t.sourcePosition)&&e.targetPosition.isEqual(t.targetPosition)){if(o.bWasUndone){const o=t.graveyardPosition.path.slice();return o.push(0),e.sourcePosition=new ql(t.graveyardPosition.root,o),e.howMany=0,[e]}return[new Md(0)]}if(e.sourcePosition.isEqual(t.sourcePosition)&&!e.targetPosition.isEqual(t.targetPosition)&&!o.bWasUndone&&"splitAtSource"!=o.abRelation){const n="$graveyard"==e.targetPosition.root.rootName,i="$graveyard"==t.targetPosition.root.rootName;if(i&&!n||!(n&&!i)&&o.aIsStrong){const o=t.targetPosition._getTransformedByMergeOperation(t),n=e.targetPosition._getTransformedByMergeOperation(t);return[new Dd(o,e.howMany,n,0)]}return[new Md(0)]}return e.sourcePosition.hasSameParentAs(t.targetPosition)&&(e.howMany+=t.howMany),e.sourcePosition=e.sourcePosition._getTransformedByMergeOperation(t),e.targetPosition=e.targetPosition._getTransformedByMergeOperation(t),e.graveyardPosition.isEqual(t.graveyardPosition)&&o.aIsStrong||(e.graveyardPosition=e.graveyardPosition._getTransformedByMergeOperation(t)),[e]})),Hd(Td,Dd,((e,t,o)=>{const n=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany);return"remove"==t.type&&!o.bWasUndone&&!o.forceWeakRemove&&e.deletionPosition.hasSameParentAs(t.sourcePosition)&&n.containsPosition(e.sourcePosition)?[new Md(0)]:(t.sourcePosition.getShiftedBy(t.howMany).isEqual(e.sourcePosition)?e.sourcePosition.stickiness="toNone":t.targetPosition.isEqual(e.sourcePosition)&&"mergeSourceAffected"==o.abRelation?e.sourcePosition.stickiness="toNext":t.sourcePosition.isEqual(e.targetPosition)?(e.targetPosition.stickiness="toNone",e.howMany-=t.howMany):t.targetPosition.isEqual(e.targetPosition)&&"mergeTargetWasBefore"==o.abRelation?(e.targetPosition.stickiness="toPrevious",e.howMany+=t.howMany):(e.sourcePosition.hasSameParentAs(t.targetPosition)&&(e.howMany+=t.howMany),e.sourcePosition.hasSameParentAs(t.sourcePosition)&&(e.howMany-=t.howMany)),e.sourcePosition=e.sourcePosition._getTransformedByMoveOperation(t),e.targetPosition=e.targetPosition._getTransformedByMoveOperation(t),e.sourcePosition.stickiness="toPrevious",e.targetPosition.stickiness="toNext",e.graveyardPosition.isEqual(t.targetPosition)||(e.graveyardPosition=e.graveyardPosition._getTransformedByMoveOperation(t)),[e])})),Hd(Td,Sd,((e,t,o)=>{if(t.graveyardPosition&&(e.graveyardPosition=e.graveyardPosition._getTransformedByDeletion(t.graveyardPosition,1),e.deletionPosition.isEqual(t.graveyardPosition)&&(e.howMany=t.howMany)),e.targetPosition.isEqual(t.splitPosition)){const n=0!=t.howMany,i=t.graveyardPosition&&e.deletionPosition.isEqual(t.graveyardPosition);if(n||i||"mergeTargetNotMoved"==o.abRelation)return e.sourcePosition=e.sourcePosition._getTransformedBySplitOperation(t),[e]}if(e.sourcePosition.isEqual(t.splitPosition)){if("mergeSourceNotMoved"==o.abRelation)return e.howMany=0,e.targetPosition=e.targetPosition._getTransformedBySplitOperation(t),[e];if("mergeSameElement"==o.abRelation||e.sourcePosition.offset>0)return e.sourcePosition=t.moveTargetPosition.clone(),e.targetPosition=e.targetPosition._getTransformedBySplitOperation(t),[e]}return e.sourcePosition.hasSameParentAs(t.splitPosition)&&(e.howMany=t.splitPosition.offset),e.sourcePosition=e.sourcePosition._getTransformedBySplitOperation(t),e.targetPosition=e.targetPosition._getTransformedBySplitOperation(t),[e]})),Hd(Dd,Bd,((e,t)=>{const o=Zl._createFromPositionAndShift(e.sourcePosition,e.howMany)._getTransformedByInsertOperation(t,!1)[0];return e.sourcePosition=o.start,e.howMany=o.end.offset-o.start.offset,e.targetPosition.isEqual(t.position)||(e.targetPosition=e.targetPosition._getTransformedByInsertOperation(t)),[e]})),Hd(Dd,Dd,((e,t,o)=>{const n=Zl._createFromPositionAndShift(e.sourcePosition,e.howMany),i=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany);let r,s=o.aIsStrong,a=!o.aIsStrong;if("insertBefore"==o.abRelation||"insertAfter"==o.baRelation?a=!0:"insertAfter"!=o.abRelation&&"insertBefore"!=o.baRelation||(a=!1),r=e.targetPosition.isEqual(t.targetPosition)&&a?e.targetPosition._getTransformedByDeletion(t.sourcePosition,t.howMany):e.targetPosition._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany),Zd(e,t)&&Zd(t,e))return[t.getReversed()];if(n.containsPosition(t.targetPosition)&&n.containsRange(i,!0))return n.start=n.start._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany),n.end=n.end._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany),Jd([n],r);if(i.containsPosition(e.targetPosition)&&i.containsRange(n,!0))return n.start=n.start._getCombined(t.sourcePosition,t.getMovedRangeStart()),n.end=n.end._getCombined(t.sourcePosition,t.getMovedRangeStart()),Jd([n],r);const l=ie(e.sourcePosition.getParentPath(),t.sourcePosition.getParentPath());if("prefix"==l||"extension"==l)return n.start=n.start._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany),n.end=n.end._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany),Jd([n],r);"remove"!=e.type||"remove"==t.type||o.aWasUndone||o.forceWeakRemove?"remove"==e.type||"remove"!=t.type||o.bWasUndone||o.forceWeakRemove||(s=!1):s=!0;const c=[],d=n.getDifference(i);for(const e of d){e.start=e.start._getTransformedByDeletion(t.sourcePosition,t.howMany),e.end=e.end._getTransformedByDeletion(t.sourcePosition,t.howMany);const o="same"==ie(e.start.getParentPath(),t.getMovedRangeStart().getParentPath()),n=e._getTransformedByInsertion(t.getMovedRangeStart(),t.howMany,o);c.push(...n)}const u=n.getIntersection(i);return null!==u&&s&&(u.start=u.start._getCombined(t.sourcePosition,t.getMovedRangeStart()),u.end=u.end._getCombined(t.sourcePosition,t.getMovedRangeStart()),0===c.length?c.push(u):1==c.length?i.start.isBefore(n.start)||i.start.isEqual(n.start)?c.unshift(u):c.push(u):c.splice(1,0,u)),0===c.length?[new Md(e.baseVersion)]:Jd(c,r)})),Hd(Dd,Sd,((e,t,o)=>{let n=e.targetPosition.clone();e.targetPosition.isEqual(t.insertionPosition)&&t.graveyardPosition&&"moveTargetAfter"!=o.abRelation||(n=e.targetPosition._getTransformedBySplitOperation(t));const i=Zl._createFromPositionAndShift(e.sourcePosition,e.howMany);if(i.end.isEqual(t.insertionPosition))return t.graveyardPosition||e.howMany++,e.targetPosition=n,[e];if(i.start.hasSameParentAs(t.splitPosition)&&i.containsPosition(t.splitPosition)){let e=new Zl(t.splitPosition,i.end);e=e._getTransformedBySplitOperation(t);return Jd([new Zl(i.start,t.splitPosition),e],n)}e.targetPosition.isEqual(t.splitPosition)&&"insertAtSource"==o.abRelation&&(n=t.moveTargetPosition),e.targetPosition.isEqual(t.insertionPosition)&&"insertBetween"==o.abRelation&&(n=e.targetPosition);const r=[i._getTransformedBySplitOperation(t)];if(t.graveyardPosition){const n=i.start.isEqual(t.graveyardPosition)||i.containsPosition(t.graveyardPosition);e.howMany>1&&n&&!o.aWasUndone&&r.push(Zl._createFromPositionAndShift(t.insertionPosition,1))}return Jd(r,n)})),Hd(Dd,Td,((e,t,o)=>{const n=Zl._createFromPositionAndShift(e.sourcePosition,e.howMany);if(t.deletionPosition.hasSameParentAs(e.sourcePosition)&&n.containsPosition(t.sourcePosition))if("remove"!=e.type||o.forceWeakRemove){if(1==e.howMany)return o.bWasUndone?(e.sourcePosition=t.graveyardPosition.clone(),e.targetPosition=e.targetPosition._getTransformedByMergeOperation(t),[e]):[new Md(0)]}else if(!o.aWasUndone){const o=[];let n=t.graveyardPosition.clone(),i=t.targetPosition._getTransformedByMergeOperation(t);e.howMany>1&&(o.push(new Dd(e.sourcePosition,e.howMany-1,e.targetPosition,0)),n=n._getTransformedByMove(e.sourcePosition,e.targetPosition,e.howMany-1),i=i._getTransformedByMove(e.sourcePosition,e.targetPosition,e.howMany-1));const r=t.deletionPosition._getCombined(e.sourcePosition,e.targetPosition),s=new Dd(n,1,r,0),a=s.getMovedRangeStart().path.slice();a.push(0);const l=new ql(s.targetPosition.root,a);i=i._getTransformedByMove(n,r,1);const c=new Dd(i,t.howMany,l,0);return o.push(s),o.push(c),o}const i=Zl._createFromPositionAndShift(e.sourcePosition,e.howMany)._getTransformedByMergeOperation(t);return e.sourcePosition=i.start,e.howMany=i.end.offset-i.start.offset,e.targetPosition=e.targetPosition._getTransformedByMergeOperation(t),[e]})),Hd(Rd,Bd,((e,t)=>(e.position=e.position._getTransformedByInsertOperation(t),[e]))),Hd(Rd,Td,((e,t)=>e.position.isEqual(t.deletionPosition)?(e.position=t.graveyardPosition.clone(),e.position.stickiness="toNext",[e]):(e.position=e.position._getTransformedByMergeOperation(t),[e]))),Hd(Rd,Dd,((e,t)=>(e.position=e.position._getTransformedByMoveOperation(t),[e]))),Hd(Rd,Rd,((e,t,o)=>{if(e.position.isEqual(t.position)){if(!o.aIsStrong)return[new Md(0)];e.oldName=t.newName}return[e]})),Hd(Rd,Sd,((e,t)=>{if("same"==ie(e.position.path,t.splitPosition.getParentPath())&&!t.graveyardPosition){const t=new Rd(e.position.getShiftedBy(1),e.oldName,e.newName,0);return[e,t]}return e.position=e.position._getTransformedBySplitOperation(t),[e]})),Hd(zd,zd,((e,t,o)=>{if(e.root===t.root&&e.key===t.key){if(!o.aIsStrong||e.newValue===t.newValue)return[new Md(0)];e.oldValue=t.newValue}return[e]})),Hd(Vd,Vd,((e,t)=>e.rootName===t.rootName&&e.isAdd===t.isAdd?[new Md(0)]:[e])),Hd(Sd,Bd,((e,t)=>(e.splitPosition.hasSameParentAs(t.position)&&e.splitPosition.offset{if(!e.graveyardPosition&&!o.bWasUndone&&e.splitPosition.hasSameParentAs(t.sourcePosition)){const o=t.graveyardPosition.path.slice();o.push(0);const n=new ql(t.graveyardPosition.root,o),i=Sd.getInsertionPosition(new ql(t.graveyardPosition.root,o)),r=new Sd(n,0,i,null,0);return e.splitPosition=e.splitPosition._getTransformedByMergeOperation(t),e.insertionPosition=Sd.getInsertionPosition(e.splitPosition),e.graveyardPosition=r.insertionPosition.clone(),e.graveyardPosition.stickiness="toNext",[r,e]}return e.splitPosition.hasSameParentAs(t.deletionPosition)&&!e.splitPosition.isAfter(t.deletionPosition)&&e.howMany--,e.splitPosition.hasSameParentAs(t.targetPosition)&&(e.howMany+=t.howMany),e.splitPosition=e.splitPosition._getTransformedByMergeOperation(t),e.insertionPosition=Sd.getInsertionPosition(e.splitPosition),e.graveyardPosition&&(e.graveyardPosition=e.graveyardPosition._getTransformedByMergeOperation(t)),[e]})),Hd(Sd,Dd,((e,t,o)=>{const n=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany);if(e.graveyardPosition){const i=n.start.isEqual(e.graveyardPosition)||n.containsPosition(e.graveyardPosition);if(!o.bWasUndone&&i){const o=e.splitPosition._getTransformedByMoveOperation(t),n=e.graveyardPosition._getTransformedByMoveOperation(t),i=n.path.slice();i.push(0);const r=new ql(n.root,i);return[new Dd(o,e.howMany,r,0)]}e.graveyardPosition=e.graveyardPosition._getTransformedByMoveOperation(t)}const i=e.splitPosition.isEqual(t.targetPosition);if(i&&("insertAtSource"==o.baRelation||"splitBefore"==o.abRelation))return e.howMany+=t.howMany,e.splitPosition=e.splitPosition._getTransformedByDeletion(t.sourcePosition,t.howMany),e.insertionPosition=Sd.getInsertionPosition(e.splitPosition),[e];if(i&&o.abRelation&&o.abRelation.howMany){const{howMany:t,offset:n}=o.abRelation;return e.howMany+=t,e.splitPosition=e.splitPosition.getShiftedBy(n),[e]}if(e.splitPosition.hasSameParentAs(t.sourcePosition)&&n.containsPosition(e.splitPosition)){const o=t.howMany-(e.splitPosition.offset-t.sourcePosition.offset);return e.howMany-=o,e.splitPosition.hasSameParentAs(t.targetPosition)&&e.splitPosition.offset{if(e.splitPosition.isEqual(t.splitPosition)){if(!e.graveyardPosition&&!t.graveyardPosition)return[new Md(0)];if(e.graveyardPosition&&t.graveyardPosition&&e.graveyardPosition.isEqual(t.graveyardPosition))return[new Md(0)];if("splitBefore"==o.abRelation)return e.howMany=0,e.graveyardPosition=e.graveyardPosition._getTransformedBySplitOperation(t),[e]}if(e.graveyardPosition&&t.graveyardPosition&&e.graveyardPosition.isEqual(t.graveyardPosition)){const n="$graveyard"==e.splitPosition.root.rootName,i="$graveyard"==t.splitPosition.root.rootName;if(i&&!n||!(n&&!i)&&o.aIsStrong){const o=[];return t.howMany&&o.push(new Dd(t.moveTargetPosition,t.howMany,t.splitPosition,0)),e.howMany&&o.push(new Dd(e.splitPosition,e.howMany,e.moveTargetPosition,0)),o}return[new Md(0)]}if(e.graveyardPosition&&(e.graveyardPosition=e.graveyardPosition._getTransformedBySplitOperation(t)),e.splitPosition.isEqual(t.insertionPosition)&&"splitBefore"==o.abRelation)return e.howMany++,[e];if(t.splitPosition.isEqual(e.insertionPosition)&&"splitBefore"==o.baRelation){const o=t.insertionPosition.path.slice();o.push(0);const n=new ql(t.insertionPosition.root,o);return[e,new Dd(e.insertionPosition,1,n,0)]}return e.splitPosition.hasSameParentAs(t.splitPosition)&&e.splitPosition.offset{const o=t[0];o.isDocumentOperation&&Xd.call(this,o)}),{priority:"low"})}function Xd(e){const t=this.getTransformedByOperation(e);if(!this.isEqual(t)){const e=this.toPosition();this.path=t.path,this.root=t.root,this.fire("change",e)}}Yd.prototype.is=function(e){return"livePosition"===e||"model:livePosition"===e||"position"==e||"model:position"===e};class eu{constructor(e={}){"string"==typeof e&&(e="transparent"===e?{isUndoable:!1}:{},D("batch-constructor-deprecated-string-type"));const{isUndoable:t=!0,isLocal:o=!0,isUndo:n=!1,isTyping:i=!1}=e;this.operations=[],this.isUndoable=t,this.isLocal=o,this.isUndo=n,this.isTyping=i}get type(){return D("batch-type-deprecated"),"default"}get baseVersion(){for(const e of this.operations)if(null!==e.baseVersion)return e.baseVersion;return null}addOperation(e){return e.batch=this,this.operations.push(e),e}}class tu{constructor(e){this._changesInElement=new Map,this._elementsSnapshots=new Map,this._elementChildrenSnapshots=new Map,this._elementState=new Map,this._changedMarkers=new Map,this._changedRoots=new Map,this._changeCount=0,this._cachedChanges=null,this._cachedChangesWithGraveyard=null,this._refreshedItems=new Set,this._markerCollection=e}get isEmpty(){return 0==this._changesInElement.size&&0==this._changedMarkers.size&&0==this._changedRoots.size}bufferOperation(e){const t=e;switch(t.type){case"insert":if(this._isInInsertedElement(t.position.parent))return;this._markInsert(t.position.parent,t.position.offset,t.nodes.maxOffset);break;case"addAttribute":case"removeAttribute":case"changeAttribute":for(const e of t.range.getItems({shallow:!0}))this._isInInsertedElement(e.parent)||this._markAttribute(e);break;case"remove":case"move":case"reinsert":{if(t.sourcePosition.isEqual(t.targetPosition)||t.sourcePosition.getShiftedBy(t.howMany).isEqual(t.targetPosition))return;const e=this._isInInsertedElement(t.sourcePosition.parent),o=this._isInInsertedElement(t.targetPosition.parent);e||this._markRemove(t.sourcePosition.parent,t.sourcePosition.offset,t.howMany),o||this._markInsert(t.targetPosition.parent,t.getMovedRangeStart().offset,t.howMany);const n=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany);for(const e of n.getItems({shallow:!0}))this._setElementState(e,"move");break}case"rename":{if(this._isInInsertedElement(t.position.parent))return;this._markRemove(t.position.parent,t.position.offset,1),this._markInsert(t.position.parent,t.position.offset,1);const e=Zl._createFromPositionAndShift(t.position,1);for(const t of this._markerCollection.getMarkersIntersectingRange(e)){const e=t.getData();this.bufferMarkerChange(t.name,e,e)}this._setElementState(t.position.nodeAfter,"rename");break}case"split":{const e=t.splitPosition.parent;if(!this._isInInsertedElement(e)){this._markRemove(e,t.splitPosition.offset,t.howMany);const o=Zl._createFromPositionAndShift(t.splitPosition,t.howMany);for(const e of o.getItems({shallow:!0}))this._setElementState(e,"move")}this._isInInsertedElement(t.insertionPosition.parent)||this._markInsert(t.insertionPosition.parent,t.insertionPosition.offset,1),t.graveyardPosition&&(this._markRemove(t.graveyardPosition.parent,t.graveyardPosition.offset,1),this._setElementState(t.graveyardPosition.nodeAfter,"move"));break}case"merge":{const e=t.sourcePosition.parent;this._isInInsertedElement(e.parent)||this._markRemove(e.parent,e.startOffset,1);const o=t.graveyardPosition.parent;this._markInsert(o,t.graveyardPosition.offset,1),this._setElementState(e,"move");const n=t.targetPosition.parent;if(!this._isInInsertedElement(n)){this._markInsert(n,t.targetPosition.offset,e.maxOffset);const o=Zl._createFromPositionAndShift(t.sourcePosition,t.howMany);for(const e of o.getItems({shallow:!0}))this._setElementState(e,"move")}break}case"detachRoot":case"addRoot":{const e=t.affectedSelectable;if(!e._isLoaded)return;if(e.isAttached()==t.isAdd)return;this._bufferRootStateChange(t.rootName,t.isAdd);break}case"addRootAttribute":case"removeRootAttribute":case"changeRootAttribute":{if(!t.root._isLoaded)return;const e=t.root.rootName;this._bufferRootAttributeChange(e,t.key,t.oldValue,t.newValue);break}}this._cachedChanges=null}bufferMarkerChange(e,t,o){t.range&&t.range.root.is("rootElement")&&!t.range.root._isLoaded&&(t.range=null),o.range&&o.range.root.is("rootElement")&&!o.range.root._isLoaded&&(o.range=null);let n=this._changedMarkers.get(e);n?n.newMarkerData=o:(n={newMarkerData:o,oldMarkerData:t},this._changedMarkers.set(e,n)),null==n.oldMarkerData.range&&null==o.range&&this._changedMarkers.delete(e)}getMarkersToRemove(){const e=[];for(const[t,o]of this._changedMarkers)null!=o.oldMarkerData.range&&e.push({name:t,range:o.oldMarkerData.range});return e}getMarkersToAdd(){const e=[];for(const[t,o]of this._changedMarkers)null!=o.newMarkerData.range&&e.push({name:t,range:o.newMarkerData.range});return e}getChangedMarkers(){return Array.from(this._changedMarkers).map((([e,t])=>({name:e,data:{oldRange:t.oldMarkerData.range,newRange:t.newMarkerData.range}})))}hasDataChanges(){if(this.getChanges().length)return!0;if(this._changedRoots.size>0)return!0;for(const{newMarkerData:e,oldMarkerData:t}of this._changedMarkers.values()){if(e.affectsData!==t.affectsData)return!0;if(e.affectsData){const o=e.range&&!t.range,n=!e.range&&t.range,i=e.range&&t.range&&!e.range.isEqual(t.range);if(o||n||i)return!0}}return!1}getChanges(e={}){if(this._cachedChanges)return e.includeChangesInGraveyard?this._cachedChangesWithGraveyard.slice():this._cachedChanges.slice();let t=[];for(const e of this._changesInElement.keys()){const o=this._changesInElement.get(e).sort(((e,t)=>e.offset===t.offset?e.type!=t.type?"remove"==e.type?-1:1:0:e.offsete.position.root!=t.position.root?e.position.root.rootNamee));for(const e of t)delete e.changeCount,"attribute"==e.type&&(delete e.position,delete e.length);return this._changeCount=0,this._cachedChangesWithGraveyard=t,this._cachedChanges=t.filter(su),e.includeChangesInGraveyard?this._cachedChangesWithGraveyard.slice():this._cachedChanges.slice()}getChangedRoots(){return Array.from(this._changedRoots.values()).map((e=>{const t={...e};return void 0!==t.state&&delete t.attributes,t}))}getRefreshedItems(){return new Set(this._refreshedItems)}reset(){this._changesInElement.clear(),this._elementChildrenSnapshots.clear(),this._elementsSnapshots.clear(),this._elementState.clear(),this._changedMarkers.clear(),this._changedRoots.clear(),this._refreshedItems.clear(),this._cachedChanges=null}_refreshItem(e){if(this._isInInsertedElement(e.parent))return;this._markRemove(e.parent,e.startOffset,e.offsetSize),this._markInsert(e.parent,e.startOffset,e.offsetSize),this._refreshedItems.add(e),this._setElementState(e,"refresh");const t=Zl._createOn(e);for(const e of this._markerCollection.getMarkersIntersectingRange(t)){const t=e.getData();this.bufferMarkerChange(e.name,t,t)}this._cachedChanges=null}_bufferRootLoad(e){if(e.isAttached()){this._bufferRootStateChange(e.rootName,!0),this._markInsert(e,0,e.maxOffset);for(const t of e.getAttributeKeys())this._bufferRootAttributeChange(e.rootName,t,null,e.getAttribute(t));for(const t of this._markerCollection)if(t.getRange().root==e){const e=t.getData();this.bufferMarkerChange(t.name,{...e,range:null},e)}}}_bufferRootStateChange(e,t){if(!this._changedRoots.has(e))return void this._changedRoots.set(e,{name:e,state:t?"attached":"detached"});const o=this._changedRoots.get(e);void 0!==o.state?(delete o.state,void 0===o.attributes&&this._changedRoots.delete(e)):o.state=t?"attached":"detached"}_bufferRootAttributeChange(e,t,o,n){const i=this._changedRoots.get(e)||{name:e},r=i.attributes||{};if(r[t]){const e=r[t];n===e.oldValue?delete r[t]:e.newValue=n}else r[t]={oldValue:o,newValue:n};0===Object.entries(r).length?(delete i.attributes,void 0===i.state&&this._changedRoots.delete(e)):(i.attributes=r,this._changedRoots.set(e,i))}_markInsert(e,t,o){if(e.root.is("rootElement")&&!e.root._isLoaded)return;const n={type:"insert",offset:t,howMany:o,count:this._changeCount++};this._markChange(e,n)}_markRemove(e,t,o){if(e.root.is("rootElement")&&!e.root._isLoaded)return;const n={type:"remove",offset:t,howMany:o,count:this._changeCount++};this._markChange(e,n),this._removeAllNestedChanges(e,t,o)}_markAttribute(e){if(e.root.is("rootElement")&&!e.root._isLoaded)return;const t={type:"attribute",offset:e.startOffset,howMany:e.offsetSize,count:this._changeCount++};this._markChange(e.parent,t)}_markChange(e,t){this._makeSnapshots(e);const o=this._getChangesForElement(e);this._handleChange(t,o),o.push(t);for(let e=0;eo&&this._elementState.set(e,t)}_getDiffActionForNode(e,t){if(!e.is("element"))return t;if(!this._elementsSnapshots.has(e))return t;const o=this._elementState.get(e);return o&&"move"!=o?o:t}_getChangesForElement(e){let t;return this._changesInElement.has(e)?t=this._changesInElement.get(e):(t=[],this._changesInElement.set(e,t)),t}_makeSnapshots(e){if(this._elementChildrenSnapshots.has(e))return;const t=iu(e.getChildren());this._elementChildrenSnapshots.set(e,t);for(const e of t)this._elementsSnapshots.set(e.node,e)}_handleChange(e,t){e.nodesToHandle=e.howMany;for(const o of t){const n=e.offset+e.howMany,i=o.offset+o.howMany;if("insert"==e.type&&("insert"==o.type&&(e.offset<=o.offset?o.offset+=e.howMany:e.offseto.offset){if(n>i){const e={type:"attribute",offset:i,howMany:n-i,count:this._changeCount++};this._handleChange(e,t),t.push(e)}e.nodesToHandle=o.offset-e.offset,e.howMany=e.nodesToHandle}else e.offset>=o.offset&&e.offseti?(e.nodesToHandle=n-i,e.offset=i):e.nodesToHandle=0);if("remove"==o.type&&e.offseto.offset){const i={type:"attribute",offset:o.offset,howMany:n-o.offset,count:this._changeCount++};this._handleChange(i,t),t.push(i),e.nodesToHandle=o.offset-e.offset,e.howMany=e.nodesToHandle}"attribute"==o.type&&(e.offset>=o.offset&&n<=i?(e.nodesToHandle=0,e.howMany=0,e.offset=0):e.offset<=o.offset&&n>=i&&(o.howMany=0))}}e.howMany=e.nodesToHandle,delete e.nodesToHandle}_getInsertDiff(e,t,o,n,i){const r={type:"insert",position:ql._createAt(e,t),name:n.name,attributes:new Map(n.attributes),length:1,changeCount:this._changeCount++,action:o};return"insert"!=o&&i&&(r.before={name:i.name,attributes:new Map(i.attributes)}),r}_getRemoveDiff(e,t,o,n){return{type:"remove",action:o,position:ql._createAt(e,t),name:n.name,attributes:new Map(n.attributes),length:1,changeCount:this._changeCount++}}_getAttributesDiff(e,t,o){const n=[];o=new Map(o);for(const[i,r]of t){const t=o.has(i)?o.get(i):null;t!==r&&n.push({type:"attribute",position:e.start,range:e.clone(),length:1,attributeKey:i,attributeOldValue:r,attributeNewValue:t,changeCount:this._changeCount++}),o.delete(i)}for(const[t,i]of o)n.push({type:"attribute",position:e.start,range:e.clone(),length:1,attributeKey:t,attributeOldValue:null,attributeNewValue:i,changeCount:this._changeCount++});return n}_isInInsertedElement(e){const t=e.parent;if(!t)return!1;const o=this._changesInElement.get(t),n=e.startOffset;if(o)for(const e of o)if("insert"==e.type&&n>=e.offset&&nn){for(let t=0;tthis._version+1&&this._gaps.set(this._version,e),this._version=e}get lastOperation(){return this._operations[this._operations.length-1]}addOperation(e){if(e.baseVersion!==this.version)throw new E("model-document-history-addoperation-incorrect-version",this,{operation:e,historyVersion:this.version});this._operations.push(e),this._version++,this._baseVersionToOperationIndex.set(e.baseVersion,this._operations.length-1)}getOperations(e,t=this.version){if(!this._operations.length)return[];const o=this._operations[0];void 0===e&&(e=o.baseVersion);let n=t-1;for(const[t,o]of this._gaps)e>t&&et&&nthis.lastOperation.baseVersion)return[];let i=this._baseVersionToOperationIndex.get(e);void 0===i&&(i=0);let r=this._baseVersionToOperationIndex.get(n);return void 0===r&&(r=this._operations.length-1),this._operations.slice(i,r+1)}getOperation(e){const t=this._baseVersionToOperationIndex.get(e);if(void 0!==t)return this._operations[t]}setOperationAsUndone(e,t){this._undoPairs.set(t,e),this._undoneOperations.add(e)}isUndoingOperation(e){return this._undoPairs.has(e)}isUndoneOperation(e){return this._undoneOperations.has(e)}getUndoneOperation(e){return this._undoPairs.get(e)}reset(){this._version=0,this._undoPairs=new Map,this._operations=[],this._undoneOperations=new Set,this._gaps=new Map,this._baseVersionToOperationIndex=new Map}}class lu extends Ll{constructor(e,t,o="main"){super(t),this._isAttached=!0,this._isLoaded=!0,this._document=e,this.rootName=o}get document(){return this._document}isAttached(){return this._isAttached}toJSON(){return this.rootName}}lu.prototype.is=function(e,t){return t?t===this.name&&("rootElement"===e||"model:rootElement"===e||"element"===e||"model:element"===e):"rootElement"===e||"model:rootElement"===e||"element"===e||"model:element"===e||"node"===e||"model:node"===e};const cu="$graveyard";class du extends(z()){constructor(e){super(),this.model=e,this.history=new au,this.selection=new mc(this),this.roots=new Yi({idProperty:"rootName"}),this.differ=new ou(e.markers),this.isReadOnly=!1,this._postFixers=new Set,this._hasSelectionChangedFromTheLastChangeBlock=!1,this.createRoot("$root",cu),this.listenTo(e,"applyOperation",((e,t)=>{const o=t[0];o.isDocumentOperation&&this.differ.bufferOperation(o)}),{priority:"high"}),this.listenTo(e,"applyOperation",((e,t)=>{const o=t[0];o.isDocumentOperation&&this.history.addOperation(o)}),{priority:"low"}),this.listenTo(this.selection,"change",(()=>{this._hasSelectionChangedFromTheLastChangeBlock=!0})),this.listenTo(e.markers,"update",((e,t,o,n,i)=>{const r={...t.getData(),range:n};this.differ.bufferMarkerChange(t.name,i,r),null===o&&t.on("change",((e,o)=>{const n=t.getData();this.differ.bufferMarkerChange(t.name,{...n,range:o},n)}))})),this.registerPostFixer((e=>{let t=!1;for(const o of this.roots)o.isAttached()||o.isEmpty||(e.remove(e.createRangeIn(o)),t=!0);for(const o of this.model.markers)o.getRange().root.isAttached()||(e.removeMarker(o),t=!0);return t}))}get version(){return this.history.version}set version(e){this.history.version=e}get graveyard(){return this.getRoot(cu)}createRoot(e="$root",t="main"){if(this.roots.get(t))throw new E("model-document-createroot-name-exists",this,{name:t});const o=new lu(this,e,t);return this.roots.add(o),o}destroy(){this.selection.destroy(),this.stopListening()}getRoot(e="main"){return this.roots.get(e)}getRootNames(e=!1){return this.getRoots(e).map((e=>e.rootName))}getRoots(e=!1){return this.roots.filter((t=>t!=this.graveyard&&(e||t.isAttached())&&t._isLoaded))}registerPostFixer(e){this._postFixers.add(e)}toJSON(){const e=Vr(this);return e.selection="[engine.model.DocumentSelection]",e.model="[engine.model.Model]",e}_handleChangeBlock(e){this._hasDocumentChangedFromTheLastChangeBlock()&&(this._callPostFixers(e),this.selection.refresh(),this.differ.hasDataChanges()?this.fire("change:data",e.batch):this.fire("change",e.batch),this.selection.refresh(),this.differ.reset()),this._hasSelectionChangedFromTheLastChangeBlock=!1}_hasDocumentChangedFromTheLastChangeBlock(){return!this.differ.isEmpty||this._hasSelectionChangedFromTheLastChangeBlock}_getDefaultRoot(){const e=this.getRoots();return e.length?e[0]:this.graveyard}_getDefaultRange(){const e=this._getDefaultRoot(),t=this.model,o=t.schema,n=t.createPositionFromPath(e,[0]);return o.getNearestSelectionRange(n)||t.createRange(n)}_validateSelectionRange(e){return uu(e.start)&&uu(e.end)}_callPostFixers(e){let t=!1;do{for(const o of this._postFixers)if(this.selection.refresh(),t=o(e),t)break}while(t)}}function uu(e){const t=e.textNode;if(t){const o=t.data,n=e.offset-t.startOffset;return!nr(o,n)&&!ir(o,n)}return!0}class hu extends(z()){constructor(){super(...arguments),this._markers=new Map}[Symbol.iterator](){return this._markers.values()}has(e){const t=e instanceof mu?e.name:e;return this._markers.has(t)}get(e){return this._markers.get(e)||null}_set(e,t,o=!1,n=!1){const i=e instanceof mu?e.name:e;if(i.includes(","))throw new E("markercollection-incorrect-marker-name",this);const r=this._markers.get(i);if(r){const e=r.getData(),s=r.getRange();let a=!1;return s.isEqual(t)||(r._attachLiveRange(cc.fromRange(t)),a=!0),o!=r.managedUsingOperations&&(r._managedUsingOperations=o,a=!0),"boolean"==typeof n&&n!=r.affectsData&&(r._affectsData=n,a=!0),a&&this.fire(`update:${i}`,r,s,t,e),r}const s=cc.fromRange(t),a=new mu(i,s,o,n);return this._markers.set(i,a),this.fire(`update:${i}`,a,null,t,{...a.getData(),range:null}),a}_remove(e){const t=e instanceof mu?e.name:e,o=this._markers.get(t);return!!o&&(this._markers.delete(t),this.fire(`update:${t}`,o,o.getRange(),null,o.getData()),this._destroyMarker(o),!0)}_refresh(e){const t=e instanceof mu?e.name:e,o=this._markers.get(t);if(!o)throw new E("markercollection-refresh-marker-not-exists",this);const n=o.getRange();this.fire(`update:${t}`,o,n,n,o.getData())}*getMarkersAtPosition(e){for(const t of this)t.getRange().containsPosition(e)&&(yield t)}*getMarkersIntersectingRange(e){for(const t of this)null!==t.getRange().getIntersection(e)&&(yield t)}destroy(){for(const e of this._markers.values())this._destroyMarker(e);this._markers=null,this.stopListening()}*getMarkersGroup(e){for(const t of this._markers.values())t.name.startsWith(e+":")&&(yield t)}_destroyMarker(e){e.stopListening(),e._detachLiveRange()}}class mu extends(z(Rl)){constructor(e,t,o,n){super(),this.name=e,this._liveRange=this._attachLiveRange(t),this._managedUsingOperations=o,this._affectsData=n}get managedUsingOperations(){if(!this._liveRange)throw new E("marker-destroyed",this);return this._managedUsingOperations}get affectsData(){if(!this._liveRange)throw new E("marker-destroyed",this);return this._affectsData}getData(){return{range:this.getRange(),affectsData:this.affectsData,managedUsingOperations:this.managedUsingOperations}}getStart(){if(!this._liveRange)throw new E("marker-destroyed",this);return this._liveRange.start.clone()}getEnd(){if(!this._liveRange)throw new E("marker-destroyed",this);return this._liveRange.end.clone()}getRange(){if(!this._liveRange)throw new E("marker-destroyed",this);return this._liveRange.toRange()}_attachLiveRange(e){return this._liveRange&&this._detachLiveRange(),e.delegate("change:range").to(this),e.delegate("change:content").to(this),this._liveRange=e,e}_detachLiveRange(){this._liveRange.stopDelegating("change:range",this),this._liveRange.stopDelegating("change:content",this),this._liveRange.detach(),this._liveRange=null}}mu.prototype.is=function(e){return"marker"===e||"model:marker"===e};class pu extends wd{constructor(e,t){super(null),this.sourcePosition=e.clone(),this.howMany=t}get type(){return"detach"}get affectedSelectable(){return null}toJSON(){const e=super.toJSON();return e.sourcePosition=this.sourcePosition.toJSON(),e}_validate(){if(this.sourcePosition.root.document)throw new E("detach-operation-on-document-node",this)}_execute(){yd(Zl._createFromPositionAndShift(this.sourcePosition,this.howMany))}static get className(){return"DetachOperation"}}class gu extends Rl{constructor(e){super(),this.markers=new Map,this._children=new Vl,e&&this._insertChild(0,e)}[Symbol.iterator](){return this.getChildren()}get childCount(){return this._children.length}get maxOffset(){return this._children.maxOffset}get isEmpty(){return 0===this.childCount}get nextSibling(){return null}get previousSibling(){return null}get root(){return this}get parent(){return null}get document(){return null}isAttached(){return!1}getAncestors(){return[]}getChild(e){return this._children.getNode(e)}getChildren(){return this._children[Symbol.iterator]()}getChildIndex(e){return this._children.getNodeIndex(e)}getChildStartOffset(e){return this._children.getNodeStartOffset(e)}getPath(){return[]}getNodeByPath(e){let t=this;for(const o of e)t=t.getChild(t.offsetToIndex(o));return t}offsetToIndex(e){return this._children.offsetToIndex(e)}toJSON(){const e=[];for(const t of this._children)e.push(t.toJSON());return e}static fromJSON(e){const t=[];for(const o of e)o.name?t.push(Ll.fromJSON(o)):t.push(Ol.fromJSON(o));return new gu(t)}_appendChild(e){this._insertChild(this.childCount,e)}_insertChild(e,t){const o=function(e){if("string"==typeof e)return[new Ol(e)];re(e)||(e=[e]);return Array.from(e).map((e=>"string"==typeof e?new Ol(e):e instanceof Nl?new Ol(e.data,e.getAttributes()):e))}(t);for(const e of o)null!==e.parent&&e._remove(),e.parent=this;this._children._insertNodes(e,o)}_removeChildren(e,t=1){const o=this._children._removeNodes(e,t);for(const e of o)e.parent=null;return o}}gu.prototype.is=function(e){return"documentFragment"===e||"model:documentFragment"===e};class fu{constructor(e,t){this.model=e,this.batch=t}createText(e,t){return new Ol(e,t)}createElement(e,t){return new Ll(e,t)}createDocumentFragment(){return new gu}cloneElement(e,t=!0){return e._clone(t)}insert(e,t,o=0){if(this._assertWriterUsedCorrectly(),e instanceof Ol&&""==e.data)return;const n=ql._createAt(t,o);if(e.parent){if(yu(e.root,n.root))return void this.move(Zl._createOn(e),n);if(e.root.document)throw new E("model-writer-insert-forbidden-move",this);this.remove(e)}const i=n.root.document?n.root.document.version:null,r=new Bd(n,e,i);if(e instanceof Ol&&(r.shouldReceiveAttributes=!0),this.batch.addOperation(r),this.model.applyOperation(r),e instanceof gu)for(const[t,o]of e.markers){const e=ql._createAt(o.root,0),i={range:new Zl(o.start._getCombined(e,n),o.end._getCombined(e,n)),usingOperation:!0,affectsData:!0};this.model.markers.has(t)?this.updateMarker(t,i):this.addMarker(t,i)}}insertText(e,t,o,n){t instanceof gu||t instanceof Ll||t instanceof ql?this.insert(this.createText(e),t,o):this.insert(this.createText(e,t),o,n)}insertElement(e,t,o,n){t instanceof gu||t instanceof Ll||t instanceof ql?this.insert(this.createElement(e),t,o):this.insert(this.createElement(e,t),o,n)}append(e,t){this.insert(e,t,"end")}appendText(e,t,o){t instanceof gu||t instanceof Ll?this.insert(this.createText(e),t,"end"):this.insert(this.createText(e,t),o,"end")}appendElement(e,t,o){t instanceof gu||t instanceof Ll?this.insert(this.createElement(e),t,"end"):this.insert(this.createElement(e,t),o,"end")}setAttribute(e,t,o){if(this._assertWriterUsedCorrectly(),o instanceof Zl){const n=o.getMinimalFlatRanges();for(const o of n)bu(this,e,t,o)}else ku(this,e,t,o)}setAttributes(e,t){for(const[o,n]of tr(e))this.setAttribute(o,n,t)}removeAttribute(e,t){if(this._assertWriterUsedCorrectly(),t instanceof Zl){const o=t.getMinimalFlatRanges();for(const t of o)bu(this,e,null,t)}else ku(this,e,null,t)}clearAttributes(e){this._assertWriterUsedCorrectly();const t=e=>{for(const t of e.getAttributeKeys())this.removeAttribute(t,e)};if(e instanceof Zl)for(const o of e.getItems())t(o);else t(e)}move(e,t,o){if(this._assertWriterUsedCorrectly(),!(e instanceof Zl))throw new E("writer-move-invalid-range",this);if(!e.isFlat)throw new E("writer-move-range-not-flat",this);const n=ql._createAt(t,o);if(n.isEqual(e.start))return;if(this._addOperationForAffectedMarkers("move",e),!yu(e.root,n.root))throw new E("writer-move-different-document",this);const i=e.root.document?e.root.document.version:null,r=new Dd(e.start,e.end.offset-e.start.offset,n,i);this.batch.addOperation(r),this.model.applyOperation(r)}remove(e){this._assertWriterUsedCorrectly();const t=(e instanceof Zl?e:Zl._createOn(e)).getMinimalFlatRanges().reverse();for(const e of t)this._addOperationForAffectedMarkers("move",e),_u(e.start,e.end.offset-e.start.offset,this.batch,this.model)}merge(e){this._assertWriterUsedCorrectly();const t=e.nodeBefore,o=e.nodeAfter;if(this._addOperationForAffectedMarkers("merge",e),!(t instanceof Ll))throw new E("writer-merge-no-element-before",this);if(!(o instanceof Ll))throw new E("writer-merge-no-element-after",this);e.root.document?this._merge(e):this._mergeDetached(e)}createPositionFromPath(e,t,o){return this.model.createPositionFromPath(e,t,o)}createPositionAt(e,t){return this.model.createPositionAt(e,t)}createPositionAfter(e){return this.model.createPositionAfter(e)}createPositionBefore(e){return this.model.createPositionBefore(e)}createRange(e,t){return this.model.createRange(e,t)}createRangeIn(e){return this.model.createRangeIn(e)}createRangeOn(e){return this.model.createRangeOn(e)}createSelection(...e){return this.model.createSelection(...e)}_mergeDetached(e){const t=e.nodeBefore,o=e.nodeAfter;this.move(Zl._createIn(o),ql._createAt(t,"end")),this.remove(o)}_merge(e){const t=ql._createAt(e.nodeBefore,"end"),o=ql._createAt(e.nodeAfter,0),n=e.root.document.graveyard,i=new ql(n,[0]),r=e.root.document.version,s=new Td(o,e.nodeAfter.maxOffset,t,i,r);this.batch.addOperation(s),this.model.applyOperation(s)}rename(e,t){if(this._assertWriterUsedCorrectly(),!(e instanceof Ll))throw new E("writer-rename-not-element-instance",this);const o=e.root.document?e.root.document.version:null,n=new Rd(ql._createBefore(e),e.name,t,o);this.batch.addOperation(n),this.model.applyOperation(n)}split(e,t){this._assertWriterUsedCorrectly();let o,n,i=e.parent;if(!i.parent)throw new E("writer-split-element-no-parent",this);if(t||(t=i.parent),!e.parent.getAncestors({includeSelf:!0}).includes(t))throw new E("writer-split-invalid-limit-element",this);do{const t=i.root.document?i.root.document.version:null,r=i.maxOffset-e.offset,s=Sd.getInsertionPosition(e),a=new Sd(e,r,s,null,t);this.batch.addOperation(a),this.model.applyOperation(a),o||n||(o=i,n=e.parent.nextSibling),i=(e=this.createPositionAfter(e.parent)).parent}while(i!==t);return{position:e,range:new Zl(ql._createAt(o,"end"),ql._createAt(n,0))}}wrap(e,t){if(this._assertWriterUsedCorrectly(),!e.isFlat)throw new E("writer-wrap-range-not-flat",this);const o=t instanceof Ll?t:new Ll(t);if(o.childCount>0)throw new E("writer-wrap-element-not-empty",this);if(null!==o.parent)throw new E("writer-wrap-element-attached",this);this.insert(o,e.start);const n=new Zl(e.start.getShiftedBy(1),e.end.getShiftedBy(1));this.move(n,ql._createAt(o,0))}unwrap(e){if(this._assertWriterUsedCorrectly(),null===e.parent)throw new E("writer-unwrap-element-no-parent",this);this.move(Zl._createIn(e),this.createPositionAfter(e)),this.remove(e)}addMarker(e,t){if(this._assertWriterUsedCorrectly(),!t||"boolean"!=typeof t.usingOperation)throw new E("writer-addmarker-no-usingoperation",this);const o=t.usingOperation,n=t.range,i=void 0!==t.affectsData&&t.affectsData;if(this.model.markers.has(e))throw new E("writer-addmarker-marker-exists",this);if(!n)throw new E("writer-addmarker-no-range",this);return o?(wu(this,e,null,n,i),this.model.markers.get(e)):this.model.markers._set(e,n,o,i)}updateMarker(e,t){this._assertWriterUsedCorrectly();const o="string"==typeof e?e:e.name,n=this.model.markers.get(o);if(!n)throw new E("writer-updatemarker-marker-not-exists",this);if(!t)return D("writer-updatemarker-reconvert-using-editingcontroller",{markerName:o}),void this.model.markers._refresh(n);const i="boolean"==typeof t.usingOperation,r="boolean"==typeof t.affectsData,s=r?t.affectsData:n.affectsData;if(!i&&!t.range&&!r)throw new E("writer-updatemarker-wrong-options",this);const a=n.getRange(),l=t.range?t.range:a;i&&t.usingOperation!==n.managedUsingOperations?t.usingOperation?wu(this,o,null,l,s):(wu(this,o,a,null,s),this.model.markers._set(o,l,void 0,s)):n.managedUsingOperations?wu(this,o,a,l,s):this.model.markers._set(o,l,void 0,s)}removeMarker(e){this._assertWriterUsedCorrectly();const t="string"==typeof e?e:e.name;if(!this.model.markers.has(t))throw new E("writer-removemarker-no-marker",this);const o=this.model.markers.get(t);if(!o.managedUsingOperations)return void this.model.markers._remove(t);wu(this,t,o.getRange(),null,o.affectsData)}addRoot(e,t="$root"){this._assertWriterUsedCorrectly();const o=this.model.document.getRoot(e);if(o&&o.isAttached())throw new E("writer-addroot-root-exists",this);const n=this.model.document,i=new Vd(e,t,!0,n,n.version);return this.batch.addOperation(i),this.model.applyOperation(i),this.model.document.getRoot(e)}detachRoot(e){this._assertWriterUsedCorrectly();const t="string"==typeof e?this.model.document.getRoot(e):e;if(!t||!t.isAttached())throw new E("writer-detachroot-no-root",this);for(const e of this.model.markers)e.getRange().root===t&&this.removeMarker(e);for(const e of t.getAttributeKeys())this.removeAttribute(e,t);this.remove(this.createRangeIn(t));const o=this.model.document,n=new Vd(t.rootName,t.name,!1,o,o.version);this.batch.addOperation(n),this.model.applyOperation(n)}setSelection(...e){this._assertWriterUsedCorrectly(),this.model.document.selection._setTo(...e)}setSelectionFocus(e,t){this._assertWriterUsedCorrectly(),this.model.document.selection._setFocus(e,t)}setSelectionAttribute(e,t){if(this._assertWriterUsedCorrectly(),"string"==typeof e)this._setSelectionAttribute(e,t);else for(const[t,o]of tr(e))this._setSelectionAttribute(t,o)}removeSelectionAttribute(e){if(this._assertWriterUsedCorrectly(),"string"==typeof e)this._removeSelectionAttribute(e);else for(const t of e)this._removeSelectionAttribute(t)}overrideSelectionGravity(){return this.model.document.selection._overrideGravity()}restoreSelectionGravity(e){this.model.document.selection._restoreGravity(e)}_setSelectionAttribute(e,t){const o=this.model.document.selection;if(o.isCollapsed&&o.anchor.parent.isEmpty){const n=mc._getStoreAttributeKey(e);this.setAttribute(n,t,o.anchor.parent)}o._setAttribute(e,t)}_removeSelectionAttribute(e){const t=this.model.document.selection;if(t.isCollapsed&&t.anchor.parent.isEmpty){const o=mc._getStoreAttributeKey(e);this.removeAttribute(o,t.anchor.parent)}t._removeAttribute(e)}_assertWriterUsedCorrectly(){if(this.model._currentWriter!==this)throw new E("writer-incorrect-use",this)}_addOperationForAffectedMarkers(e,t){for(const o of this.model.markers){if(!o.managedUsingOperations)continue;const n=o.getRange();let i=!1;if("move"===e){const e=t;i=e.containsPosition(n.start)||e.start.isEqual(n.start)||e.containsPosition(n.end)||e.end.isEqual(n.end)}else{const e=t,o=e.nodeBefore,r=e.nodeAfter,s=n.start.parent==o&&n.start.isAtEnd,a=n.end.parent==r&&0==n.end.offset,l=n.end.nodeAfter==r,c=n.start.nodeAfter==r;i=s||a||l||c}i&&this.updateMarker(o.name,{range:n})}}}function bu(e,t,o,n){const i=e.model,r=i.document;let s,a,l,c=n.start;for(const e of n.getWalker({shallow:!0}))l=e.item.getAttribute(t),s&&a!=l&&(a!=o&&d(),c=s),s=e.nextPosition,a=l;function d(){const n=new Zl(c,s),l=n.root.document?r.version:null,d=new Fd(n,t,a,o,l);e.batch.addOperation(d),i.applyOperation(d)}s instanceof ql&&s!=c&&a!=o&&d()}function ku(e,t,o,n){const i=e.model,r=i.document,s=n.getAttribute(t);let a,l;if(s!=o){if(n.root===n){const e=n.document?r.version:null;l=new zd(n,t,s,o,e)}else{a=new Zl(ql._createBefore(n),e.createPositionAfter(n));const i=a.root.document?r.version:null;l=new Fd(a,t,s,o,i)}e.batch.addOperation(l),i.applyOperation(l)}}function wu(e,t,o,n,i){const r=e.model,s=r.document,a=new Id(t,o,n,r.markers,!!i,s.version);e.batch.addOperation(a),r.applyOperation(a)}function _u(e,t,o,n){let i;if(e.root.document){const o=n.document,r=new ql(o.graveyard,[0]);i=new Dd(e,t,r,o.version)}else i=new pu(e,t);o.addOperation(i),n.applyOperation(i)}function yu(e,t){return e===t||e instanceof lu&&t instanceof lu}function Au(e,t,o={}){if(t.isCollapsed)return;const n=t.getFirstRange();if("$graveyard"==n.root.rootName)return;const i=e.schema;e.change((e=>{if(!o.doNotResetEntireContent&&function(e,t){const o=e.getLimitElement(t);if(!t.containsEntireContent(o))return!1;const n=t.getFirstRange();if(n.start.parent==n.end.parent)return!1;return e.checkChild(o,"paragraph")}(i,t))return void function(e,t){const o=e.model.schema.getLimitElement(t);e.remove(e.createRangeIn(o)),Eu(e,e.createPositionAt(o,0),t)}(e,t);const r={};if(!o.doNotAutoparagraph){const e=t.getSelectedElement();e&&Object.assign(r,i.getAttributesWithProperty(e,"copyOnReplace",!0))}const[s,a]=function(e){const t=e.root.document.model,o=e.start;let n=e.end;if(t.hasContent(e,{ignoreMarkers:!0})){const o=function(e){const t=e.parent,o=t.root.document.model.schema,n=t.getAncestors({parentFirst:!0,includeSelf:!0});for(const e of n){if(o.isLimit(e))return null;if(o.isBlock(e))return e}}(n);if(o&&n.isTouching(t.createPositionAt(o,0))){const o=t.createSelection(e);t.modifySelection(o,{direction:"backward"});const i=o.getLastPosition(),r=t.createRange(i,n);t.hasContent(r,{ignoreMarkers:!0})||(n=i)}}return[Yd.fromPosition(o,"toPrevious"),Yd.fromPosition(n,"toNext")]}(n);s.isTouching(a)||e.remove(e.createRange(s,a)),o.leaveUnmerged||(!function(e,t,o){const n=e.model;if(!xu(e.model.schema,t,o))return;const[i,r]=function(e,t){const o=e.getAncestors(),n=t.getAncestors();let i=0;for(;o[i]&&o[i]==n[i];)i++;return[o[i],n[i]]}(t,o);if(!i||!r)return;!n.hasContent(i,{ignoreMarkers:!0})&&n.hasContent(r,{ignoreMarkers:!0})?vu(e,t,o,i.parent):Cu(e,t,o,i.parent)}(e,s,a),i.removeDisallowedAttributes(s.parent.getChildren(),e)),Du(e,t,s),!o.doNotAutoparagraph&&function(e,t){const o=e.checkChild(t,"$text"),n=e.checkChild(t,"paragraph");return!o&&n}(i,s)&&Eu(e,s,t,r),s.detach(),a.detach()}))}function Cu(e,t,o,n){const i=t.parent,r=o.parent;if(i!=n&&r!=n){for(t=e.createPositionAfter(i),(o=e.createPositionBefore(r)).isEqual(t)||e.insert(r,t),e.merge(t);o.parent.isEmpty;){const t=o.parent;o=e.createPositionBefore(t),e.remove(t)}xu(e.model.schema,t,o)&&Cu(e,t,o,n)}}function vu(e,t,o,n){const i=t.parent,r=o.parent;if(i!=n&&r!=n){for(t=e.createPositionAfter(i),(o=e.createPositionBefore(r)).isEqual(t)||e.insert(i,o);t.parent.isEmpty;){const o=t.parent;t=e.createPositionBefore(o),e.remove(o)}o=e.createPositionBefore(r),function(e,t){const o=t.nodeBefore,n=t.nodeAfter;o.name!=n.name&&e.rename(o,n.name);e.clearAttributes(o),e.setAttributes(Object.fromEntries(n.getAttributes()),o),e.merge(t)}(e,o),xu(e.model.schema,t,o)&&vu(e,t,o,n)}}function xu(e,t,o){const n=t.parent,i=o.parent;return n!=i&&(!e.isLimit(n)&&!e.isLimit(i)&&function(e,t,o){const n=new Zl(e,t);for(const e of n.getWalker())if(o.isLimit(e.item))return!1;return!0}(t,o,e))}function Eu(e,t,o,n={}){const i=e.createElement("paragraph");e.model.schema.setAllowedAttributes(i,n,e),e.insert(i,t),Du(e,o,e.createPositionAt(i,0))}function Du(e,t,o){t instanceof mc?e.setSelection(o):t.setTo(o)}function Bu(e,t){const o=[];Array.from(e.getItems({direction:"backward"})).map((e=>t.createRangeOn(e))).filter((t=>(t.start.isAfter(e.start)||t.start.isEqual(e.start))&&(t.end.isBefore(e.end)||t.end.isEqual(e.end)))).forEach((e=>{o.push(e.start.parent),t.remove(e)})),o.forEach((e=>{let o=e;for(;o.parent&&o.isEmpty;){const e=t.createRangeOn(o);o=o.parent,t.remove(e)}}))}class Su{constructor(e,t,o){this._firstNode=null,this._lastNode=null,this._lastAutoParagraph=null,this._filterAttributesOf=[],this._affectedStart=null,this._affectedEnd=null,this._nodeToSelect=null,this.model=e,this.writer=t,this.position=o,this.canMergeWith=new Set([this.position.parent]),this.schema=e.schema,this._documentFragment=t.createDocumentFragment(),this._documentFragmentPosition=t.createPositionAt(this._documentFragment,0)}handleNodes(e){for(const t of Array.from(e))this._handleNode(t);this._insertPartialFragment(),this._lastAutoParagraph&&this._updateLastNodeFromAutoParagraph(this._lastAutoParagraph),this._mergeOnRight(),this.schema.removeDisallowedAttributes(this._filterAttributesOf,this.writer),this._filterAttributesOf=[]}_updateLastNodeFromAutoParagraph(e){const t=this.writer.createPositionAfter(this._lastNode),o=this.writer.createPositionAfter(e);if(o.isAfter(t)){if(this._lastNode=e,this.position.parent!=e||!this.position.isAtEnd)throw new E("insertcontent-invalid-insertion-position",this);this.position=o,this._setAffectedBoundaries(this.position)}}getSelectionRange(){return this._nodeToSelect?Zl._createOn(this._nodeToSelect):this.model.schema.getNearestSelectionRange(this.position)}getAffectedRange(){return this._affectedStart?new Zl(this._affectedStart,this._affectedEnd):null}destroy(){this._affectedStart&&this._affectedStart.detach(),this._affectedEnd&&this._affectedEnd.detach()}_handleNode(e){this._checkAndSplitToAllowedPosition(e)?(this._appendToFragment(e),this._firstNode||(this._firstNode=e),this._lastNode=e):this.schema.isObject(e)||this._handleDisallowedNode(e)}_insertPartialFragment(){if(this._documentFragment.isEmpty)return;const e=Yd.fromPosition(this.position,"toNext");this._setAffectedBoundaries(this.position),this._documentFragment.getChild(0)==this._firstNode&&(this.writer.insert(this._firstNode,this.position),this._mergeOnLeft(),this.position=e.toPosition()),this._documentFragment.isEmpty||this.writer.insert(this._documentFragment,this.position),this._documentFragmentPosition=this.writer.createPositionAt(this._documentFragment,0),this.position=e.toPosition(),e.detach()}_handleDisallowedNode(e){e.is("element")&&this.handleNodes(e.getChildren())}_appendToFragment(e){if(!this.schema.checkChild(this.position,e))throw new E("insertcontent-wrong-position",this,{node:e,position:this.position});this.writer.insert(e,this._documentFragmentPosition),this._documentFragmentPosition=this._documentFragmentPosition.getShiftedBy(e.offsetSize),this.schema.isObject(e)&&!this.schema.checkChild(this.position,"$text")?this._nodeToSelect=e:this._nodeToSelect=null,this._filterAttributesOf.push(e)}_setAffectedBoundaries(e){this._affectedStart||(this._affectedStart=Yd.fromPosition(e,"toPrevious")),this._affectedEnd&&!this._affectedEnd.isBefore(e)||(this._affectedEnd&&this._affectedEnd.detach(),this._affectedEnd=Yd.fromPosition(e,"toNext"))}_mergeOnLeft(){const e=this._firstNode;if(!(e instanceof Ll))return;if(!this._canMergeLeft(e))return;const t=Yd._createBefore(e);t.stickiness="toNext";const o=Yd.fromPosition(this.position,"toNext");this._affectedStart.isEqual(t)&&(this._affectedStart.detach(),this._affectedStart=Yd._createAt(t.nodeBefore,"end","toPrevious")),this._firstNode===this._lastNode&&(this._firstNode=t.nodeBefore,this._lastNode=t.nodeBefore),this.writer.merge(t),t.isEqual(this._affectedEnd)&&this._firstNode===this._lastNode&&(this._affectedEnd.detach(),this._affectedEnd=Yd._createAt(t.nodeBefore,"end","toNext")),this.position=o.toPosition(),o.detach(),this._filterAttributesOf.push(this.position.parent),t.detach()}_mergeOnRight(){const e=this._lastNode;if(!(e instanceof Ll))return;if(!this._canMergeRight(e))return;const t=Yd._createAfter(e);if(t.stickiness="toNext",!this.position.isEqual(t))throw new E("insertcontent-invalid-insertion-position",this);this.position=ql._createAt(t.nodeBefore,"end");const o=Yd.fromPosition(this.position,"toPrevious");this._affectedEnd.isEqual(t)&&(this._affectedEnd.detach(),this._affectedEnd=Yd._createAt(t.nodeBefore,"end","toNext")),this._firstNode===this._lastNode&&(this._firstNode=t.nodeBefore,this._lastNode=t.nodeBefore),this.writer.merge(t),t.getShiftedBy(-1).isEqual(this._affectedStart)&&this._firstNode===this._lastNode&&(this._affectedStart.detach(),this._affectedStart=Yd._createAt(t.nodeBefore,0,"toPrevious")),this.position=o.toPosition(),o.detach(),this._filterAttributesOf.push(this.position.parent),t.detach()}_canMergeLeft(e){const t=e.previousSibling;return t instanceof Ll&&this.canMergeWith.has(t)&&this.model.schema.checkMerge(t,e)}_canMergeRight(e){const t=e.nextSibling;return t instanceof Ll&&this.canMergeWith.has(t)&&this.model.schema.checkMerge(e,t)}_insertAutoParagraph(){this._insertPartialFragment();const e=this.writer.createElement("paragraph");this.writer.insert(e,this.position),this._setAffectedBoundaries(this.position),this._lastAutoParagraph=e,this.position=this.writer.createPositionAt(e,0)}_checkAndSplitToAllowedPosition(e){const t=this._getAllowedIn(this.position.parent,e);if(!t)return!1;for(t!=this.position.parent&&this._insertPartialFragment();t!=this.position.parent;)if(this.position.isAtStart){const e=this.position.parent;this.position=this.writer.createPositionBefore(e),e.isEmpty&&e.parent===t&&this.writer.remove(e)}else if(this.position.isAtEnd)this.position=this.writer.createPositionAfter(this.position.parent);else{const e=this.writer.createPositionAfter(this.position.parent);this._setAffectedBoundaries(this.position),this.writer.split(this.position),this.position=e,this.canMergeWith.add(this.position.nodeAfter)}return this.schema.checkChild(this.position.parent,e)||this._insertAutoParagraph(),!0}_getAllowedIn(e,t){return this.schema.checkChild(e,t)||this.schema.checkChild(e,"paragraph")&&this.schema.checkChild("paragraph",t)?e:this.schema.isLimit(e)?null:this._getAllowedIn(e.parent,t)}}function Tu(e,t,o,n={}){if(!e.schema.isObject(t))throw new E("insertobject-element-not-an-object",e,{object:t});const i=o||e.document.selection;let r=i;n.findOptimalPosition&&e.schema.isBlock(t)&&(r=e.createSelection(e.schema.findOptimalInsertionRange(i,n.findOptimalPosition)));const s=Qi(i.getSelectedBlocks()),a={};return s&&Object.assign(a,e.schema.getAttributesWithProperty(s,"copyOnReplace",!0)),e.change((o=>{r.isCollapsed||e.deleteContent(r,{doNotAutoparagraph:!0});let i=t;const s=r.anchor.parent;!e.schema.checkChild(s,t)&&e.schema.checkChild(s,"paragraph")&&e.schema.checkChild("paragraph",t)&&(i=o.createElement("paragraph"),o.insert(t,i)),e.schema.setAllowedAttributes(i,a,o);const l=e.insertContent(i,r);return l.isCollapsed||n.setSelection&&function(e,t,o,n){const i=e.model;if("on"==o)return void e.setSelection(t,"on");if("after"!=o)throw new E("insertobject-invalid-place-parameter-value",i);let r=t.nextSibling;if(i.schema.isInline(t))return void e.setSelection(t,"after");const s=r&&i.schema.checkChild(r,"$text");!s&&i.schema.checkChild(t.parent,"paragraph")&&(r=e.createElement("paragraph"),i.schema.setAllowedAttributes(r,n,e),i.insertContent(r,e.createPositionAfter(t)));r&&e.setSelection(r,0)}(o,t,n.setSelection,a),l}))}const Iu=' ,.?!:;"-()';function Pu(e,t){const{isForward:o,walker:n,unit:i,schema:r,treatEmojiAsSingleUnit:s}=e,{type:a,item:l,nextPosition:c}=t;if("text"==a)return"word"===e.unit?function(e,t){let o=e.position.textNode;o||(o=t?e.position.nodeAfter:e.position.nodeBefore);for(;o&&o.is("$text");){const n=e.position.offset-o.startOffset;if(Ru(o,n,t))o=t?e.position.nodeAfter:e.position.nodeBefore;else{if(Mu(o.data,n,t))break;e.next()}}return e.position}(n,o):function(e,t,o){const n=e.position.textNode;if(n){const i=n.data;let r=e.position.offset-n.startOffset;for(;nr(i,r)||"character"==t&&ir(i,r)||o&&sr(i,r);)e.next(),r=e.position.offset-n.startOffset}return e.position}(n,i,s);if(a==(o?"elementStart":"elementEnd")){if(r.isSelectable(l))return ql._createAt(l,o?"after":"before");if(r.checkChild(c,"$text"))return c}else{if(r.isLimit(l))return void n.skip((()=>!0));if(r.checkChild(c,"$text"))return c}}function Fu(e,t){const o=e.root,n=ql._createAt(o,t?"end":0);return t?new Zl(e,n):new Zl(n,e)}function Mu(e,t,o){const n=t+(o?0:-1);return Iu.includes(e.charAt(n))}function Ru(e,t,o){return t===(o?e.offsetSize:0)}class zu extends(Y()){constructor(){super(),this.markers=new hu,this.document=new du(this),this.schema=new Yc,this._pendingChanges=[],this._currentWriter=null,["deleteContent","modifySelection","getSelectedContent","applyOperation"].forEach((e=>this.decorate(e))),this.on("applyOperation",((e,t)=>{t[0]._validate()}),{priority:"highest"}),this.schema.register("$root",{isLimit:!0}),this.schema.register("$container",{allowIn:["$root","$container"]}),this.schema.register("$block",{allowIn:["$root","$container"],isBlock:!0}),this.schema.register("$blockObject",{allowWhere:"$block",isBlock:!0,isObject:!0}),this.schema.register("$inlineObject",{allowWhere:"$text",allowAttributesOf:"$text",isInline:!0,isObject:!0}),this.schema.register("$text",{allowIn:"$block",isInline:!0,isContent:!0}),this.schema.register("$clipboardHolder",{allowContentOf:"$root",allowChildren:"$text",isLimit:!0}),this.schema.register("$documentFragment",{allowContentOf:"$root",allowChildren:"$text",isLimit:!0}),this.schema.register("$marker"),this.schema.addChildCheck((()=>!0),"$marker"),qc(this),this.document.registerPostFixer(Fc),this.on("insertContent",((e,[t,o])=>{e.return=function(e,t,o){return e.change((n=>{const i=o||e.document.selection;i.isCollapsed||e.deleteContent(i,{doNotAutoparagraph:!0});const r=new Su(e,n,i.anchor),s=[];let a;if(t.is("documentFragment")){if(t.markers.size){const e=[];for(const[o,n]of t.markers){const{start:t,end:i}=n,r=t.isEqual(i);e.push({position:t,name:o,isCollapsed:r},{position:i,name:o,isCollapsed:r})}e.sort((({position:e},{position:t})=>e.isBefore(t)?1:-1));for(const{position:o,name:i,isCollapsed:r}of e){let e=null,a=null;const l=o.parent===t&&o.isAtStart,c=o.parent===t&&o.isAtEnd;l||c?r&&(a=l?"start":"end"):(e=n.createElement("$marker"),n.insert(e,o)),s.push({name:i,element:e,collapsed:a})}}a=t.getChildren()}else a=[t];r.handleNodes(a);let l=r.getSelectionRange();if(t.is("documentFragment")&&s.length){const e=l?cc.fromRange(l):null,t={};for(let e=s.length-1;e>=0;e--){const{name:o,element:i,collapsed:a}=s[e],l=!t[o];if(l&&(t[o]=[]),i){const e=n.createPositionAt(i,"before");t[o].push(e),n.remove(i)}else{const e=r.getAffectedRange();if(!e){a&&t[o].push(r.position);continue}a?t[o].push(e[a]):t[o].push(l?e.start:e.end)}}for(const[e,[o,i]]of Object.entries(t))o&&i&&o.root===i.root&&o.root.document&&!n.model.markers.has(e)&&n.addMarker(e,{usingOperation:!0,affectsData:!0,range:new Zl(o,i)});e&&(l=e.toRange(),e.detach())}l&&(i instanceof mc?n.setSelection(l):i.setTo(l));const c=r.getAffectedRange()||e.createRange(i.anchor);return r.destroy(),c}))}(this,t,o)})),this.on("insertObject",((e,[t,o,n])=>{e.return=Tu(this,t,o,n)})),this.on("canEditAt",(e=>{const t=!this.document.isReadOnly;e.return=t,t||e.stop()}))}change(e){try{return 0===this._pendingChanges.length?(this._pendingChanges.push({batch:new eu,callback:e}),this._runPendingChanges()[0]):e(this._currentWriter)}catch(e){E.rethrowUnexpectedError(e,this)}}enqueueChange(e,t){try{e?"function"==typeof e?(t=e,e=new eu):e instanceof eu||(e=new eu(e)):e=new eu,this._pendingChanges.push({batch:e,callback:t}),1==this._pendingChanges.length&&this._runPendingChanges()}catch(e){E.rethrowUnexpectedError(e,this)}}applyOperation(e){e._execute()}insertContent(e,t,o,...n){const i=Vu(t,o);return this.fire("insertContent",[e,i,o,...n])}insertObject(e,t,o,n,...i){const r=Vu(t,o);return this.fire("insertObject",[e,r,n,n,...i])}deleteContent(e,t){Au(this,e,t)}modifySelection(e,t){!function(e,t,o={}){const n=e.schema,i="backward"!=o.direction,r=o.unit?o.unit:"character",s=!!o.treatEmojiAsSingleUnit,a=t.focus,l=new Hl({boundaries:Fu(a,i),singleCharacters:!0,direction:i?"forward":"backward"}),c={walker:l,schema:n,isForward:i,unit:r,treatEmojiAsSingleUnit:s};let d;for(;d=l.next();){if(d.done)return;const o=Pu(c,d.value);if(o)return void(t instanceof mc?e.change((e=>{e.setSelectionFocus(o)})):t.setFocus(o))}}(this,e,t)}getSelectedContent(e){return function(e,t){return e.change((e=>{const o=e.createDocumentFragment(),n=t.getFirstRange();if(!n||n.isCollapsed)return o;const i=n.start.root,r=n.start.getCommonPath(n.end),s=i.getNodeByPath(r);let a;a=n.start.parent==n.end.parent?n:e.createRange(e.createPositionAt(s,n.start.path[r.length]),e.createPositionAt(s,n.end.path[r.length]+1));const l=a.end.offset-a.start.offset;for(const t of a.getItems({shallow:!0}))t.is("$textProxy")?e.appendText(t.data,t.getAttributes(),o):e.append(e.cloneElement(t,!0),o);if(a!=n){const t=n._getTransformedByMove(a.start,e.createPositionAt(o,0),l)[0],i=e.createRange(e.createPositionAt(o,0),t.start);Bu(e.createRange(t.end,e.createPositionAt(o,"end")),e),Bu(i,e)}return o}))}(this,e)}hasContent(e,t={}){const o=e instanceof Zl?e:Zl._createIn(e);if(o.isCollapsed)return!1;const{ignoreWhitespaces:n=!1,ignoreMarkers:i=!1}=t;if(!i)for(const e of this.markers.getMarkersIntersectingRange(o))if(e.affectsData)return!0;for(const e of o.getItems())if(this.schema.isContent(e)){if(!e.is("$textProxy"))return!0;if(!n)return!0;if(-1!==e.data.search(/\S/))return!0}return!1}canEditAt(e){const t=Vu(e);return this.fire("canEditAt",[t])}createPositionFromPath(e,t,o){return new ql(e,t,o)}createPositionAt(e,t){return ql._createAt(e,t)}createPositionAfter(e){return ql._createAfter(e)}createPositionBefore(e){return ql._createBefore(e)}createRange(e,t){return new Zl(e,t)}createRangeIn(e){return Zl._createIn(e)}createRangeOn(e){return Zl._createOn(e)}createSelection(...e){return new oc(...e)}createBatch(e){return new eu(e)}createOperationFromJSON(e){return Nd.fromJSON(e,this.document)}destroy(){this.document.destroy(),this.stopListening()}_runPendingChanges(){const e=[];this.fire("_beforeChanges");try{for(;this._pendingChanges.length;){const t=this._pendingChanges[0].batch;this._currentWriter=new fu(this,t);const o=this._pendingChanges[0].callback(this._currentWriter);e.push(o),this.document._handleChangeBlock(this._currentWriter),this._pendingChanges.shift(),this._currentWriter=null}}finally{this._pendingChanges.length=0,this._currentWriter=null,this.fire("_afterChanges")}return e}}function Vu(e,t){if(e)return e instanceof oc||e instanceof mc?e:e instanceof zl?t||0===t?new oc(e,t):e.is("rootElement")?new oc(e,"in"):new oc(e,"on"):new oc(e)}class Ou extends La{constructor(){super(...arguments),this.domEventType="click"}onDomEvent(e){this.fire(e.type,e)}}class Nu extends La{constructor(){super(...arguments),this.domEventType=["mousedown","mouseup","mouseover","mouseout"]}onDomEvent(e){this.fire(e.type,e)}}class Lu{constructor(e){this.document=e}createDocumentFragment(e){return new Xs(this.document,e)}createElement(e,t,o){return new ys(this.document,e,t,o)}createText(e){return new Nr(this.document,e)}clone(e,t=!1){return e._clone(t)}appendChild(e,t){return t._appendChild(e)}insertChild(e,t,o){return o._insertChild(e,t)}removeChildren(e,t,o){return o._removeChildren(e,t)}remove(e){const t=e.parent;return t?this.removeChildren(t.getChildIndex(e),1,t):[]}replace(e,t){const o=e.parent;if(o){const n=o.getChildIndex(e);return this.removeChildren(n,1,o),this.insertChild(n,t,o),!0}return!1}unwrapElement(e){const t=e.parent;if(t){const o=t.getChildIndex(e);this.remove(e),this.insertChild(o,e.getChildren(),t)}}rename(e,t){const o=new ys(this.document,e,t.getAttributes(),t.getChildren());return this.replace(t,o)?o:null}setAttribute(e,t,o){o._setAttribute(e,t)}removeAttribute(e,t){t._removeAttribute(e)}addClass(e,t){t._addClass(e)}removeClass(e,t){t._removeClass(e)}setStyle(e,t,o){Te(e)&&void 0===o?t._setStyle(e):o._setStyle(e,t)}removeStyle(e,t){t._removeStyle(e)}setCustomProperty(e,t,o){o._setCustomProperty(e,t)}removeCustomProperty(e,t){return t._removeCustomProperty(e)}createPositionAt(e,t){return Ss._createAt(e,t)}createPositionAfter(e){return Ss._createAfter(e)}createPositionBefore(e){return Ss._createBefore(e)}createRange(e,t){return new Ts(e,t)}createRangeOn(e){return Ts._createOn(e)}createRangeIn(e){return Ts._createIn(e)}createSelection(...e){return new Ps(...e)}}const Hu=/^#([0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/i,ju=/^rgb\([ ]?([0-9]{1,3}[ %]?,[ ]?){2,3}[0-9]{1,3}[ %]?\)$/i,qu=/^rgba\([ ]?([0-9]{1,3}[ %]?,[ ]?){3}(1|[0-9]+%|[0]?\.?[0-9]+)\)$/i,Uu=/^hsl\([ ]?([0-9]{1,3}[ %]?[,]?[ ]*){3}(1|[0-9]+%|[0]?\.?[0-9]+)?\)$/i,Wu=/^hsla\([ ]?([0-9]{1,3}[ %]?,[ ]?){2,3}(1|[0-9]+%|[0]?\.?[0-9]+)\)$/i,$u=/\w+\((?:[^()]|\([^()]*\))*\)|\S+/gi,Gu=new Set(["black","silver","gray","white","maroon","red","purple","fuchsia","green","lime","olive","yellow","navy","blue","teal","aqua","orange","aliceblue","antiquewhite","aquamarine","azure","beige","bisque","blanchedalmond","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkgrey","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkslategrey","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dimgrey","dodgerblue","firebrick","floralwhite","forestgreen","gainsboro","ghostwhite","gold","goldenrod","greenyellow","grey","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightgrey","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightslategrey","lightsteelblue","lightyellow","limegreen","linen","magenta","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","oldlace","olivedrab","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","skyblue","slateblue","slategray","slategrey","snow","springgreen","steelblue","tan","thistle","tomato","turquoise","violet","wheat","whitesmoke","yellowgreen","activeborder","activecaption","appworkspace","background","buttonface","buttonhighlight","buttonshadow","buttontext","captiontext","graytext","highlight","highlighttext","inactiveborder","inactivecaption","inactivecaptiontext","infobackground","infotext","menu","menutext","scrollbar","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","window","windowframe","windowtext","rebeccapurple","currentcolor","transparent"]);function Ku(e){return e.startsWith("#")?Hu.test(e):e.startsWith("rgb")?ju.test(e)||qu.test(e):e.startsWith("hsl")?Uu.test(e)||Wu.test(e):Gu.has(e.toLowerCase())}const Zu=["none","hidden","dotted","dashed","solid","double","groove","ridge","inset","outset"];function Ju(e){return Zu.includes(e)}const Yu=/^([+-]?[0-9]*([.][0-9]+)?(px|cm|mm|in|pc|pt|ch|em|ex|rem|vh|vw|vmin|vmax)|0)$/;function Qu(e){return Yu.test(e)}const Xu=/^[+-]?[0-9]*([.][0-9]+)?%$/;const eh=["repeat-x","repeat-y","repeat","space","round","no-repeat"];function th(e){return eh.includes(e)}const oh=["center","top","bottom","left","right"];function nh(e){return oh.includes(e)}const ih=["fixed","scroll","local"];function rh(e){return ih.includes(e)}const sh=/^url\(/;function ah(e){return sh.test(e)}function lh(e=""){if(""===e)return{top:void 0,right:void 0,bottom:void 0,left:void 0};const t=uh(e),o=t[0],n=t[2]||o,i=t[1]||o;return{top:o,bottom:n,right:i,left:t[3]||i}}function ch(e){return t=>{const{top:o,right:n,bottom:i,left:r}=t,s=[];return[o,n,r,i].every((e=>!!e))?s.push([e,dh(t)]):(o&&s.push([e+"-top",o]),n&&s.push([e+"-right",n]),i&&s.push([e+"-bottom",i]),r&&s.push([e+"-left",r])),s}}function dh({top:e,right:t,bottom:o,left:n}){const i=[];return n!==t?i.push(e,t,o,n):o!==e?i.push(e,t,o):t!==e?i.push(e,t):i.push(e),i.join(" ")}function uh(e){const t=e.matchAll($u);return Array.from(t).map((e=>e[0]))}function hh(e){e.setNormalizer("background",(e=>{const t={},o=uh(e);for(const e of o)th(e)?(t.repeat=t.repeat||[],t.repeat.push(e)):nh(e)?(t.position=t.position||[],t.position.push(e)):rh(e)?t.attachment=e:Ku(e)?t.color=e:ah(e)&&(t.image=e);return{path:"background",value:t}})),e.setNormalizer("background-color",(e=>({path:"background.color",value:e}))),e.setReducer("background",(e=>{const t=[];return t.push(["background-color",e.color]),t})),e.setStyleRelation("background",["background-color"])}function mh(e){e.setNormalizer("border",(e=>{const{color:t,style:o,width:n}=_h(e);return{path:"border",value:{color:lh(t),style:lh(o),width:lh(n)}}})),e.setNormalizer("border-top",ph("top")),e.setNormalizer("border-right",ph("right")),e.setNormalizer("border-bottom",ph("bottom")),e.setNormalizer("border-left",ph("left")),e.setNormalizer("border-color",gh("color")),e.setNormalizer("border-width",gh("width")),e.setNormalizer("border-style",gh("style")),e.setNormalizer("border-top-color",bh("color","top")),e.setNormalizer("border-top-style",bh("style","top")),e.setNormalizer("border-top-width",bh("width","top")),e.setNormalizer("border-right-color",bh("color","right")),e.setNormalizer("border-right-style",bh("style","right")),e.setNormalizer("border-right-width",bh("width","right")),e.setNormalizer("border-bottom-color",bh("color","bottom")),e.setNormalizer("border-bottom-style",bh("style","bottom")),e.setNormalizer("border-bottom-width",bh("width","bottom")),e.setNormalizer("border-left-color",bh("color","left")),e.setNormalizer("border-left-style",bh("style","left")),e.setNormalizer("border-left-width",bh("width","left")),e.setExtractor("border-top",kh("top")),e.setExtractor("border-right",kh("right")),e.setExtractor("border-bottom",kh("bottom")),e.setExtractor("border-left",kh("left")),e.setExtractor("border-top-color","border.color.top"),e.setExtractor("border-right-color","border.color.right"),e.setExtractor("border-bottom-color","border.color.bottom"),e.setExtractor("border-left-color","border.color.left"),e.setExtractor("border-top-width","border.width.top"),e.setExtractor("border-right-width","border.width.right"),e.setExtractor("border-bottom-width","border.width.bottom"),e.setExtractor("border-left-width","border.width.left"),e.setExtractor("border-top-style","border.style.top"),e.setExtractor("border-right-style","border.style.right"),e.setExtractor("border-bottom-style","border.style.bottom"),e.setExtractor("border-left-style","border.style.left"),e.setReducer("border-color",ch("border-color")),e.setReducer("border-style",ch("border-style")),e.setReducer("border-width",ch("border-width")),e.setReducer("border-top",yh("top")),e.setReducer("border-right",yh("right")),e.setReducer("border-bottom",yh("bottom")),e.setReducer("border-left",yh("left")),e.setReducer("border",function(){return t=>{const o=wh(t,"top"),n=wh(t,"right"),i=wh(t,"bottom"),r=wh(t,"left"),s=[o,n,i,r],a={width:e(s,"width"),style:e(s,"style"),color:e(s,"color")},l=Ah(a,"all");if(l.length)return l;const c=Object.entries(a).reduce(((e,[t,o])=>(o&&(e.push([`border-${t}`,o]),s.forEach((e=>delete e[t]))),e)),[]);return[...c,...Ah(o,"top"),...Ah(n,"right"),...Ah(i,"bottom"),...Ah(r,"left")]};function e(e,t){return e.map((e=>e[t])).reduce(((e,t)=>e==t?e:null))}}()),e.setStyleRelation("border",["border-color","border-style","border-width","border-top","border-right","border-bottom","border-left","border-top-color","border-right-color","border-bottom-color","border-left-color","border-top-style","border-right-style","border-bottom-style","border-left-style","border-top-width","border-right-width","border-bottom-width","border-left-width"]),e.setStyleRelation("border-color",["border-top-color","border-right-color","border-bottom-color","border-left-color"]),e.setStyleRelation("border-style",["border-top-style","border-right-style","border-bottom-style","border-left-style"]),e.setStyleRelation("border-width",["border-top-width","border-right-width","border-bottom-width","border-left-width"]),e.setStyleRelation("border-top",["border-top-color","border-top-style","border-top-width"]),e.setStyleRelation("border-right",["border-right-color","border-right-style","border-right-width"]),e.setStyleRelation("border-bottom",["border-bottom-color","border-bottom-style","border-bottom-width"]),e.setStyleRelation("border-left",["border-left-color","border-left-style","border-left-width"])}function ph(e){return t=>{const{color:o,style:n,width:i}=_h(t),r={};return void 0!==o&&(r.color={[e]:o}),void 0!==n&&(r.style={[e]:n}),void 0!==i&&(r.width={[e]:i}),{path:"border",value:r}}}function gh(e){return t=>({path:"border",value:fh(t,e)})}function fh(e,t){return{[t]:lh(e)}}function bh(e,t){return o=>({path:"border",value:{[e]:{[t]:o}}})}function kh(e){return(t,o)=>{if(o.border)return wh(o.border,e)}}function wh(e,t){const o={};return e.width&&e.width[t]&&(o.width=e.width[t]),e.style&&e.style[t]&&(o.style=e.style[t]),e.color&&e.color[t]&&(o.color=e.color[t]),o}function _h(e){const t={},o=uh(e);for(const e of o)Qu(e)||/thin|medium|thick/.test(e)?t.width=e:Ju(e)?t.style=e:t.color=e;return t}function yh(e){return t=>Ah(t,e)}function Ah(e,t){const o=[];if(e&&e.width&&o.push("width"),e&&e.style&&o.push("style"),e&&e.color&&o.push("color"),3==o.length){const n=o.map((t=>e[t])).join(" ");return["all"==t?["border",n]:[`border-${t}`,n]]}return"all"==t?[]:o.map((o=>[`border-${t}-${o}`,e[o]]))}function Ch(e){var t;e.setNormalizer("padding",(t="padding",e=>({path:t,value:lh(e)}))),e.setNormalizer("padding-top",(e=>({path:"padding.top",value:e}))),e.setNormalizer("padding-right",(e=>({path:"padding.right",value:e}))),e.setNormalizer("padding-bottom",(e=>({path:"padding.bottom",value:e}))),e.setNormalizer("padding-left",(e=>({path:"padding.left",value:e}))),e.setReducer("padding",ch("padding")),e.setStyleRelation("padding",["padding-top","padding-right","padding-bottom","padding-left"])}class vh{constructor(e){if(this.crashes=[],this.state="initializing",this._now=Date.now,this.crashes=[],this._crashNumberLimit="number"==typeof e.crashNumberLimit?e.crashNumberLimit:3,this._minimumNonErrorTimePeriod="number"==typeof e.minimumNonErrorTimePeriod?e.minimumNonErrorTimePeriod:5e3,this._boundErrorHandler=e=>{const t="error"in e?e.error:e.reason;t instanceof Error&&this._handleError(t,e)},this._listeners={},!this._restart)throw new Error("The Watchdog class was split into the abstract `Watchdog` class and the `EditorWatchdog` class. Please, use `EditorWatchdog` if you have used the `Watchdog` class previously.")}destroy(){this._stopErrorHandling(),this._listeners={}}on(e,t){this._listeners[e]||(this._listeners[e]=[]),this._listeners[e].push(t)}off(e,t){this._listeners[e]=this._listeners[e].filter((e=>e!==t))}_fire(e,...t){const o=this._listeners[e]||[];for(const e of o)e.apply(this,[null,...t])}_startErrorHandling(){window.addEventListener("error",this._boundErrorHandler),window.addEventListener("unhandledrejection",this._boundErrorHandler)}_stopErrorHandling(){window.removeEventListener("error",this._boundErrorHandler),window.removeEventListener("unhandledrejection",this._boundErrorHandler)}_handleError(e,t){if(this._shouldReactToError(e)){this.crashes.push({message:e.message,stack:e.stack,filename:t instanceof ErrorEvent?t.filename:void 0,lineno:t instanceof ErrorEvent?t.lineno:void 0,colno:t instanceof ErrorEvent?t.colno:void 0,date:this._now()});const o=this._shouldRestart();this.state="crashed",this._fire("stateChange"),this._fire("error",{error:e,causesRestart:o}),o?this._restart():(this.state="crashedPermanently",this._fire("stateChange"))}}_shouldReactToError(e){return e.is&&e.is("CKEditorError")&&void 0!==e.context&&null!==e.context&&"ready"===this.state&&this._isErrorComingFromThisItem(e)}_shouldRestart(){if(this.crashes.length<=this._crashNumberLimit)return!0;return(this.crashes[this.crashes.length-1].date-this.crashes[this.crashes.length-1-this._crashNumberLimit].date)/this._crashNumberLimit>this._minimumNonErrorTimePeriod}}function xh(e,t=new Set){const o=[e],n=new Set;let i=0;for(;o.length>i;){const e=o[i++];if(!n.has(e)&&Eh(e)&&!t.has(e))if(n.add(e),Symbol.iterator in e)try{for(const t of e)o.push(t)}catch(e){}else for(const t in e)"defaultValue"!==t&&o.push(e[t])}return n}function Eh(e){const t=Object.prototype.toString.call(e),o=typeof e;return!("number"===o||"boolean"===o||"string"===o||"symbol"===o||"function"===o||"[object Date]"===t||"[object RegExp]"===t||"[object Module]"===t||null==e||e._watchdogExcluded||e instanceof EventTarget||e instanceof Event)}function Dh(e,t,o=new Set){if(e===t&&("object"==typeof(n=e)&&null!==n))return!0;var n;const i=xh(e,o),r=xh(t,o);for(const e of i)if(r.has(e))return!0;return!1}const Bh=function(e,t,o){var n=!0,i=!0;if("function"!=typeof e)throw new TypeError("Expected a function");return U(o)&&(n="leading"in o?!!o.leading:n,i="trailing"in o?!!o.trailing:i),el(e,t,{leading:n,maxWait:t,trailing:i})};class Sh extends vh{constructor(e,t={}){super(t),this._editor=null,this._lifecyclePromise=null,this._initUsingData=!0,this._editables={},this._throttledSave=Bh(this._save.bind(this),"number"==typeof t.saveInterval?t.saveInterval:5e3),e&&(this._creator=(t,o)=>e.create(t,o)),this._destructor=e=>e.destroy()}get editor(){return this._editor}get _item(){return this._editor}setCreator(e){this._creator=e}setDestructor(e){this._destructor=e}_restart(){return Promise.resolve().then((()=>(this.state="initializing",this._fire("stateChange"),this._destroy()))).catch((e=>{console.error("An error happened during the editor destroying.",e)})).then((()=>{const e={},t=[],o=this._config.rootsAttributes||{},n={};for(const[i,r]of Object.entries(this._data.roots))r.isLoaded?(e[i]="",n[i]=o[i]||{}):t.push(i);const i={...this._config,extraPlugins:this._config.extraPlugins||[],lazyRoots:t,rootsAttributes:n,_watchdogInitialData:this._data};return delete i.initialData,i.extraPlugins.push(Th),this._initUsingData?this.create(e,i,i.context):Bn(this._elementOrData)?this.create(this._elementOrData,i,i.context):this.create(this._editables,i,i.context)})).then((()=>{this._fire("restart")}))}create(e=this._elementOrData,t=this._config,o){return this._lifecyclePromise=Promise.resolve(this._lifecyclePromise).then((()=>(super._startErrorHandling(),this._elementOrData=e,this._initUsingData="string"==typeof e||Object.keys(e).length>0&&"string"==typeof Object.values(e)[0],this._config=this._cloneEditorConfiguration(t)||{},this._config.context=o,this._creator(e,this._config)))).then((e=>{this._editor=e,e.model.document.on("change:data",this._throttledSave),this._lastDocumentVersion=e.model.document.version,this._data=this._getData(),this._initUsingData||(this._editables=this._getEditables()),this.state="ready",this._fire("stateChange")})).finally((()=>{this._lifecyclePromise=null})),this._lifecyclePromise}destroy(){return this._lifecyclePromise=Promise.resolve(this._lifecyclePromise).then((()=>(this.state="destroyed",this._fire("stateChange"),super.destroy(),this._destroy()))).finally((()=>{this._lifecyclePromise=null})),this._lifecyclePromise}_destroy(){return Promise.resolve().then((()=>{this._stopErrorHandling(),this._throttledSave.cancel();const e=this._editor;return this._editor=null,e.model.document.off("change:data",this._throttledSave),this._destructor(e)}))}_save(){const e=this._editor.model.document.version;try{this._data=this._getData(),this._initUsingData||(this._editables=this._getEditables()),this._lastDocumentVersion=e}catch(e){console.error(e,"An error happened during restoring editor data. Editor will be restored from the previously saved data.")}}_setExcludedProperties(e){this._excludedProps=e}_getData(){const e=this._editor,t=e.model.document.roots.filter((e=>e.isAttached()&&"$graveyard"!=e.rootName)),{plugins:o}=e,n=o.has("CommentsRepository")&&o.get("CommentsRepository"),i=o.has("TrackChanges")&&o.get("TrackChanges"),r={roots:{},markers:{},commentThreads:JSON.stringify([]),suggestions:JSON.stringify([])};t.forEach((e=>{r.roots[e.rootName]={content:JSON.stringify(Array.from(e.getChildren())),attributes:JSON.stringify(Array.from(e.getAttributes())),isLoaded:e._isLoaded}}));for(const t of e.model.markers)t._affectsData&&(r.markers[t.name]={rangeJSON:t.getRange().toJSON(),usingOperation:t._managedUsingOperations,affectsData:t._affectsData});return n&&(r.commentThreads=JSON.stringify(n.getCommentThreads({toJSON:!0,skipNotAttached:!0}))),i&&(r.suggestions=JSON.stringify(i.getSuggestions({toJSON:!0,skipNotAttached:!0}))),r}_getEditables(){const e={};for(const t of this.editor.model.document.getRootNames()){const o=this.editor.ui.getEditableElement(t);o&&(e[t]=o)}return e}_isErrorComingFromThisItem(e){return Dh(this._editor,e.context,this._excludedProps)}_cloneEditorConfiguration(e){return Dn(e,((e,t)=>Bn(e)||"context"===t?e:void 0))}}class Th{constructor(e){this.editor=e,this._data=e.config.get("_watchdogInitialData")}init(){this.editor.data.on("init",(e=>{e.stop(),this.editor.model.enqueueChange({isUndoable:!1},(e=>{this._restoreCollaborationData(),this._restoreEditorData(e)})),this.editor.data.fire("ready")}),{priority:999})}_createNode(e,t){if("name"in t){const o=e.createElement(t.name,t.attributes);if(t.children)for(const n of t.children)o._appendChild(this._createNode(e,n));return o}return e.createText(t.data,t.attributes)}_restoreEditorData(e){const t=this.editor;Object.entries(this._data.roots).forEach((([o,{content:n,attributes:i}])=>{const r=JSON.parse(n),s=JSON.parse(i),a=t.model.document.getRoot(o);for(const[t,o]of s)e.setAttribute(t,o,a);for(const t of r){const o=this._createNode(e,t);e.insert(o,a,"end")}})),Object.entries(this._data.markers).forEach((([o,n])=>{const{document:i}=t.model,{rangeJSON:{start:r,end:s},...a}=n,l=i.getRoot(r.root),c=e.createPositionFromPath(l,r.path,r.stickiness),d=e.createPositionFromPath(l,s.path,s.stickiness),u=e.createRange(c,d);e.addMarker(o,{range:u,...a})}))}_restoreCollaborationData(){const e=JSON.parse(this._data.commentThreads),t=JSON.parse(this._data.suggestions);e.forEach((e=>{const t=this.editor.config.get("collaboration.channelId"),o=this.editor.plugins.get("CommentsRepository");if(o.hasCommentThread(e.threadId)){o.getCommentThread(e.threadId).remove()}o.addCommentThread({channelId:t,...e})})),t.forEach((e=>{const t=this.editor.plugins.get("TrackChangesEditing");if(t.hasSuggestion(e.id)){t.getSuggestion(e.id).attributes=e.attributes}else t.addSuggestionData(e)}))}}const Ih=Symbol("MainQueueId");class Ph{constructor(){this._onEmptyCallbacks=[],this._queues=new Map,this._activeActions=0}onEmpty(e){this._onEmptyCallbacks.push(e)}enqueue(e,t){const o=e===Ih;this._activeActions++,this._queues.get(e)||this._queues.set(e,Promise.resolve());const n=(o?Promise.all(this._queues.values()):Promise.all([this._queues.get(Ih),this._queues.get(e)])).then(t),i=n.catch((()=>{}));return this._queues.set(e,i),n.finally((()=>{this._activeActions--,this._queues.get(e)===i&&0===this._activeActions&&this._onEmptyCallbacks.forEach((e=>e()))}))}}function Fh(e){return Array.isArray(e)?e:[e]}class Mh{constructor(){this._commands=new Map}add(e,t){this._commands.set(e,t)}get(e){return this._commands.get(e)}execute(e,...t){const o=this.get(e);if(!o)throw new E("commandcollection-command-not-found",this,{commandName:e});return o.execute(...t)}*names(){yield*this._commands.keys()}*commands(){yield*this._commands.values()}[Symbol.iterator](){return this._commands[Symbol.iterator]()}destroy(){for(const e of this.commands())e.destroy()}}class Rh extends er{constructor(e){super(),this.editor=e}set(e,t,o={}){if("string"==typeof t){const e=t;t=(t,o)=>{this.editor.execute(e),o()}}super.set(e,t,o)}}const zh="contentEditing",Vh="common";class Oh{constructor(e){this.keystrokeInfos=new Map,this._editor=e;const t=e.config.get("menuBar.isVisible"),o=e.locale.t;this.addKeystrokeInfoCategory({id:zh,label:o("Content editing keystrokes"),description:o("These keyboard shortcuts allow for quick access to content editing features.")});const n=[{label:o("Close contextual balloons, dropdowns, and dialogs"),keystroke:"Esc"},{label:o("Open the accessibility help dialog"),keystroke:"Alt+0"},{label:o("Move focus between form fields (inputs, buttons, etc.)"),keystroke:[["Tab"],["Shift+Tab"]]},{label:o("Move focus to the toolbar, navigate between toolbars"),keystroke:"Alt+F10",mayRequireFn:!0},{label:o("Navigate through the toolbar or menu bar"),keystroke:[["arrowup"],["arrowright"],["arrowdown"],["arrowleft"]]},{label:o("Execute the currently focused button. Executing buttons that interact with the editor content moves the focus back to the content."),keystroke:[["Enter"],["Space"]]}];t&&n.push({label:o("Move focus to the menu bar, navigate between menu bars"),keystroke:"Alt+F9",mayRequireFn:!0}),this.addKeystrokeInfoCategory({id:"navigation",label:o("User interface and content navigation keystrokes"),description:o("Use the following keystrokes for more efficient navigation in the CKEditor 5 user interface."),groups:[{id:"common",keystrokes:n}]})}addKeystrokeInfoCategory({id:e,label:t,description:o,groups:n}){this.keystrokeInfos.set(e,{id:e,label:t,description:o,groups:new Map}),this.addKeystrokeInfoGroup({categoryId:e,id:Vh}),n&&n.forEach((t=>{this.addKeystrokeInfoGroup({categoryId:e,...t})}))}addKeystrokeInfoGroup({categoryId:e=zh,id:t,label:o,keystrokes:n}){const i=this.keystrokeInfos.get(e);if(!i)throw new E("accessibility-unknown-keystroke-info-category",this._editor,{groupId:t,categoryId:e});i.groups.set(t,{id:t,label:o,keystrokes:n||[]})}addKeystrokeInfos({categoryId:e=zh,groupId:t=Vh,keystrokes:o}){if(!this.keystrokeInfos.has(e))throw new E("accessibility-unknown-keystroke-info-category",this._editor,{categoryId:e,keystrokes:o});const n=this.keystrokeInfos.get(e);if(!n.groups.has(t))throw new E("accessibility-unknown-keystroke-info-group",this._editor,{groupId:t,categoryId:e,keystrokes:o});n.groups.get(t).keystrokes.push(...o)}}class Nh extends(Y()){constructor(e={}){super();const t=this.constructor,{translations:o,...n}=t.defaultConfig||{},{translations:i=o,...r}=e,s=e.language||n.language;this._context=e.context||new mr({language:s,translations:i}),this._context._addEditor(this,!e.context);const a=Array.from(t.builtinPlugins||[]);this.config=new Sn(r,n),this.config.define("plugins",a),this.config.define(this._context._getEditorConfig()),this.plugins=new hr(this,a,this._context.plugins),this.locale=this._context.locale,this.t=this.locale.t,this._readOnlyLocks=new Set,this.commands=new Mh,this.set("state","initializing"),this.once("ready",(()=>this.state="ready"),{priority:"high"}),this.once("destroy",(()=>this.state="destroyed"),{priority:"high"}),this.model=new zu,this.on("change:isReadOnly",(()=>{this.model.document.isReadOnly=this.isReadOnly}));const l=new ks;this.data=new gd(this.model,l),this.editing=new Gc(this.model,l),this.editing.view.document.bind("isReadOnly").to(this),this.conversion=new fd([this.editing.downcastDispatcher,this.data.downcastDispatcher],this.data.upcastDispatcher),this.conversion.addAlias("dataDowncast",this.data.downcastDispatcher),this.conversion.addAlias("editingDowncast",this.editing.downcastDispatcher),this.keystrokes=new Rh(this),this.keystrokes.listenTo(this.editing.view.document),this.accessibility=new Oh(this)}get isReadOnly(){return this._readOnlyLocks.size>0}set isReadOnly(e){throw new E("editor-isreadonly-has-no-setter")}enableReadOnlyMode(e){if("string"!=typeof e&&"symbol"!=typeof e)throw new E("editor-read-only-lock-id-invalid",null,{lockId:e});this._readOnlyLocks.has(e)||(this._readOnlyLocks.add(e),1===this._readOnlyLocks.size&&this.fire("change:isReadOnly","isReadOnly",!0,!1))}disableReadOnlyMode(e){if("string"!=typeof e&&"symbol"!=typeof e)throw new E("editor-read-only-lock-id-invalid",null,{lockId:e});this._readOnlyLocks.has(e)&&(this._readOnlyLocks.delete(e),0===this._readOnlyLocks.size&&this.fire("change:isReadOnly","isReadOnly",!1,!0))}setData(e){this.data.set(e)}getData(e){return this.data.get(e)}initPlugins(){const e=this.config,t=e.get("plugins"),o=e.get("removePlugins")||[],n=e.get("extraPlugins")||[],i=e.get("substitutePlugins")||[];return this.plugins.init(t.concat(n),o,i)}destroy(){let e=Promise.resolve();return"initializing"==this.state&&(e=new Promise((e=>this.once("ready",e)))),e.then((()=>{this.fire("destroy"),this.stopListening(),this.commands.destroy()})).then((()=>this.plugins.destroy())).then((()=>{this.model.destroy(),this.data.destroy(),this.editing.destroy(),this.keystrokes.destroy()})).then((()=>this._context._removeEditor(this)))}execute(e,...t){try{return this.commands.execute(e,...t)}catch(e){E.rethrowUnexpectedError(e,this)}}focus(){this.editing.view.focus()}static create(...e){throw new Error("This is an abstract method.")}}Nh.Context=mr,Nh.EditorWatchdog=Sh,Nh.ContextWatchdog=class extends vh{constructor(e,t={}){super(t),this._watchdogs=new Map,this._context=null,this._contextProps=new Set,this._actionQueues=new Ph,this._watchdogConfig=t,this._creator=t=>e.create(t),this._destructor=e=>e.destroy(),this._actionQueues.onEmpty((()=>{"initializing"===this.state&&(this.state="ready",this._fire("stateChange"))}))}setCreator(e){this._creator=e}setDestructor(e){this._destructor=e}get context(){return this._context}create(e={}){return this._actionQueues.enqueue(Ih,(()=>(this._contextConfig=e,this._create())))}getItem(e){return this._getWatchdog(e)._item}getItemState(e){return this._getWatchdog(e).state}add(e){const t=Fh(e);return Promise.all(t.map((e=>this._actionQueues.enqueue(e.id,(()=>{if("destroyed"===this.state)throw new Error("Cannot add items to destroyed watchdog.");if(!this._context)throw new Error("Context was not created yet. You should call the `ContextWatchdog#create()` method first.");let t;if(this._watchdogs.has(e.id))throw new Error(`Item with the given id is already added: '${e.id}'.`);if("editor"===e.type)return t=new Sh(null,this._watchdogConfig),t.setCreator(e.creator),t._setExcludedProperties(this._contextProps),e.destructor&&t.setDestructor(e.destructor),this._watchdogs.set(e.id,t),t.on("error",((o,{error:n,causesRestart:i})=>{this._fire("itemError",{itemId:e.id,error:n}),i&&this._actionQueues.enqueue(e.id,(()=>new Promise((o=>{const n=()=>{t.off("restart",n),this._fire("itemRestart",{itemId:e.id}),o()};t.on("restart",n)}))))})),t.create(e.sourceElementOrData,e.config,this._context);throw new Error(`Not supported item type: '${e.type}'.`)})))))}remove(e){const t=Fh(e);return Promise.all(t.map((e=>this._actionQueues.enqueue(e,(()=>{const t=this._getWatchdog(e);return this._watchdogs.delete(e),t.destroy()})))))}destroy(){return this._actionQueues.enqueue(Ih,(()=>(this.state="destroyed",this._fire("stateChange"),super.destroy(),this._destroy())))}_restart(){return this._actionQueues.enqueue(Ih,(()=>(this.state="initializing",this._fire("stateChange"),this._destroy().catch((e=>{console.error("An error happened during destroying the context or items.",e)})).then((()=>this._create())).then((()=>this._fire("restart"))))))}_create(){return Promise.resolve().then((()=>(this._startErrorHandling(),this._creator(this._contextConfig)))).then((e=>(this._context=e,this._contextProps=xh(this._context),Promise.all(Array.from(this._watchdogs.values()).map((e=>(e._setExcludedProperties(this._contextProps),e.create(void 0,void 0,this._context))))))))}_destroy(){return Promise.resolve().then((()=>{this._stopErrorHandling();const e=this._context;return this._context=null,this._contextProps=new Set,Promise.all(Array.from(this._watchdogs.values()).map((e=>e.destroy()))).then((()=>this._destructor(e)))}))}_getWatchdog(e){const t=this._watchdogs.get(e);if(!t)throw new Error(`Item with the given id was not registered: ${e}.`);return t}_isErrorComingFromThisItem(e){for(const t of this._watchdogs.values())if(t._isErrorComingFromThisItem(e))return!1;return Dh(this._context,e.context)}};const Lh=Nh;function Hh(e){return class extends e{updateSourceElement(e){if(!this.sourceElement)throw new E("editor-missing-sourceelement",this);const t=this.config.get("updateSourceElementOnDestroy"),o=this.sourceElement instanceof HTMLTextAreaElement;if(!t&&!o)return void Jn(this.sourceElement,"");const n="string"==typeof e?e:this.data.get();Jn(this.sourceElement,n)}}}Hh.updateSourceElement=Hh(Object).prototype.updateSourceElement;class jh extends pr{static get pluginName(){return"PendingActions"}init(){this.set("hasAny",!1),this._actions=new Yi({idProperty:"_id"}),this._actions.delegate("add","remove").to(this)}add(e){if("string"!=typeof e)throw new E("pendingactions-add-invalid-message",this);const t=new(Y());return t.set("message",e),this._actions.add(t),this.hasAny=!0,t}remove(e){this._actions.remove(e),this.hasAny=!!this._actions.length}get first(){return this._actions.get(0)}[Symbol.iterator](){return this._actions[Symbol.iterator]()}}const qh={bold:'',cancel:'',caption:'',check:'',cog:'',colorPalette:'',eraser:'',history:'',image:'',imageUpload:'',imageAssetManager:'',imageUrl:'',lowVision:'',textAlternative:'',loupe:'',previousArrow:'',nextArrow:'',importExport:'',paragraph:'',plus:'',text:'',alignBottom:'',alignMiddle:'',alignTop:'',alignLeft:'',alignCenter:'',alignRight:'',alignJustify:'',objectLeft:'',objectCenter:'',objectRight:'',objectFullWidth:'',objectInline:'',objectBlockLeft:'',objectBlockRight:'',objectSizeCustom:'',objectSizeFull:'',objectSizeLarge:'',objectSizeSmall:'',objectSizeMedium:'',pencil:'',pilcrow:'',quote:'',threeVerticalDots:'',dragIndicator:'',redo:'',undo:'',bulletedList:'',numberedList:'',todoList:'',codeBlock:'',browseFiles:'',heading1:'',heading2:'',heading3:'',heading4:'',heading5:'',heading6:'',horizontalLine:'',html:'',indent:'',outdent:'',table:''};class Uh extends Yi{constructor(e=[]){super(e,{idProperty:"viewUid"}),this.on("add",((e,t,o)=>{this._renderViewIntoCollectionParent(t,o)})),this.on("remove",((e,t)=>{t.element&&this._parentElement&&t.element.remove()})),this._parentElement=null}destroy(){this.map((e=>e.destroy()))}setParent(e){this._parentElement=e;for(const e of this)this._renderViewIntoCollectionParent(e)}delegate(...e){if(!e.length||!e.every((e=>"string"==typeof e)))throw new E("ui-viewcollection-delegate-wrong-events",this);return{to:t=>{for(const o of this)for(const n of e)o.delegate(n).to(t);this.on("add",((o,n)=>{for(const o of e)n.delegate(o).to(t)})),this.on("remove",((o,n)=>{for(const o of e)n.stopDelegating(o,t)}))}}}_renderViewIntoCollectionParent(e,t){e.isRendered||e.render(),e.element&&this._parentElement&&this._parentElement.insertBefore(e.element,this._parentElement.children[t])}remove(e){return super.remove(e)}}class Wh extends(z()){constructor(e){super(),Object.assign(this,tm(em(e))),this._isRendered=!1,this._revertData=null}render(){const e=this._renderNode({intoFragment:!0});return this._isRendered=!0,e}apply(e){return this._revertData={children:[],bindings:[],attributes:{}},this._renderNode({node:e,intoFragment:!1,isApplying:!0,revertData:this._revertData}),e}revert(e){if(!this._revertData)throw new E("ui-template-revert-not-applied",[this,e]);this._revertTemplateFromNode(e,this._revertData)}*getViews(){yield*function*e(t){if(t.children)for(const o of t.children)am(o)?yield o:lm(o)&&(yield*e(o))}(this)}static bind(e,t){return{to:(o,n)=>new Gh({eventNameOrFunction:o,attribute:o,observable:e,emitter:t,callback:n}),if:(o,n,i)=>new Kh({observable:e,emitter:t,attribute:o,valueIfTrue:n,callback:i})}}static extend(e,t){if(e._isRendered)throw new E("template-extend-render",[this,e]);rm(e,tm(em(t)))}_renderNode(e){let t;if(t=e.node?this.tag&&this.text:this.tag?this.text:!this.text,t)throw new E("ui-template-wrong-syntax",this);return this.text?this._renderText(e):this._renderElement(e)}_renderElement(e){let t=e.node;return t||(t=e.node=document.createElementNS(this.ns||"http://www.w3.org/1999/xhtml",this.tag)),this._renderAttributes(e),this._renderElementChildren(e),this._setUpListeners(e),t}_renderText(e){let t=e.node;return t?e.revertData.text=t.textContent:t=e.node=document.createTextNode(""),Zh(this.text)?this._bindToObservable({schema:this.text,updater:Yh(t),data:e}):t.textContent=this.text.join(""),t}_renderAttributes(e){if(!this.attributes)return;const t=e.node,o=e.revertData;for(const n in this.attributes){const i=t.getAttribute(n),r=this.attributes[n];o&&(o.attributes[n]=i);const s=dm(r)?r[0].ns:null;if(Zh(r)){const a=dm(r)?r[0].value:r;o&&um(n)&&a.unshift(i),this._bindToObservable({schema:a,updater:Qh(t,n,s),data:e})}else if("style"==n&&"string"!=typeof r[0])this._renderStyleAttribute(r[0],e);else{o&&i&&um(n)&&r.unshift(i);const e=r.map((e=>e&&e.value||e)).reduce(((e,t)=>e.concat(t)),[]).reduce(nm,"");sm(e)||t.setAttributeNS(s,n,e)}}}_renderStyleAttribute(e,t){const o=t.node;for(const n in e){const i=e[n];Zh(i)?this._bindToObservable({schema:[i],updater:Xh(o,n),data:t}):o.style[n]=i}}_renderElementChildren(e){const t=e.node,o=e.intoFragment?document.createDocumentFragment():t,n=e.isApplying;let i=0;for(const r of this.children)if(cm(r)){if(!n){r.setParent(t);for(const e of r)o.appendChild(e.element)}}else if(am(r))n||(r.isRendered||r.render(),o.appendChild(r.element));else if(Pn(r))o.appendChild(r);else if(n){const t={children:[],bindings:[],attributes:{}};e.revertData.children.push(t),r._renderNode({intoFragment:!1,node:o.childNodes[i++],isApplying:!0,revertData:t})}else o.appendChild(r.render());e.intoFragment&&t.appendChild(o)}_setUpListeners(e){if(this.eventListeners)for(const t in this.eventListeners){const o=this.eventListeners[t].map((o=>{const[n,i]=t.split("@");return o.activateDomEventListener(n,i,e)}));e.revertData&&e.revertData.bindings.push(o)}}_bindToObservable({schema:e,updater:t,data:o}){const n=o.revertData;Jh(e,t,o);const i=e.filter((e=>!sm(e))).filter((e=>e.observable)).map((n=>n.activateAttributeListener(e,t,o)));n&&n.bindings.push(i)}_revertTemplateFromNode(e,t){for(const e of t.bindings)for(const t of e)t();if(t.text)return void(e.textContent=t.text);const o=e;for(const e in t.attributes){const n=t.attributes[e];null===n?o.removeAttribute(e):o.setAttribute(e,n)}for(let e=0;eJh(e,t,o);return this.emitter.listenTo(this.observable,`change:${this.attribute}`,n),()=>{this.emitter.stopListening(this.observable,`change:${this.attribute}`,n)}}}class Gh extends $h{constructor(e){super(e),this.eventNameOrFunction=e.eventNameOrFunction}activateDomEventListener(e,t,o){const n=(e,o)=>{t&&!o.target.matches(t)||("function"==typeof this.eventNameOrFunction?this.eventNameOrFunction(o):this.observable.fire(this.eventNameOrFunction,o))};return this.emitter.listenTo(o.node,e,n),()=>{this.emitter.stopListening(o.node,e,n)}}}class Kh extends $h{constructor(e){super(e),this.valueIfTrue=e.valueIfTrue}getValue(e){return!sm(super.getValue(e))&&(this.valueIfTrue||!0)}}function Zh(e){return!!e&&(e.value&&(e=e.value),Array.isArray(e)?e.some(Zh):e instanceof $h)}function Jh(e,t,{node:o}){const n=function(e,t){return e.map((e=>e instanceof $h?e.getValue(t):e))}(e,o);let i;i=1==e.length&&e[0]instanceof Kh?n[0]:n.reduce(nm,""),sm(i)?t.remove():t.set(i)}function Yh(e){return{set(t){e.textContent=t},remove(){e.textContent=""}}}function Qh(e,t,o){return{set(n){e.setAttributeNS(o,t,n)},remove(){e.removeAttributeNS(o,t)}}}function Xh(e,t){return{set(o){e.style[t]=o},remove(){e.style[t]=null}}}function em(e){return Dn(e,(e=>{if(e&&(e instanceof $h||lm(e)||am(e)||cm(e)))return e}))}function tm(e){if("string"==typeof e?e=function(e){return{text:[e]}}(e):e.text&&function(e){e.text=xi(e.text)}(e),e.on&&(e.eventListeners=function(e){for(const t in e)om(e,t);return e}(e.on),delete e.on),!e.text){e.attributes&&function(e){for(const t in e)e[t].value&&(e[t].value=xi(e[t].value)),om(e,t)}(e.attributes);const t=[];if(e.children)if(cm(e.children))t.push(e.children);else for(const o of e.children)lm(o)||am(o)||Pn(o)?t.push(o):t.push(new Wh(o));e.children=t}return e}function om(e,t){e[t]=xi(e[t])}function nm(e,t){return sm(t)?e:sm(e)?t:`${e} ${t}`}function im(e,t){for(const o in t)e[o]?e[o].push(...t[o]):e[o]=t[o]}function rm(e,t){if(t.attributes&&(e.attributes||(e.attributes={}),im(e.attributes,t.attributes)),t.eventListeners&&(e.eventListeners||(e.eventListeners={}),im(e.eventListeners,t.eventListeners)),t.text&&e.text.push(...t.text),t.children&&t.children.length){if(e.children.length!=t.children.length)throw new E("ui-template-extend-children-mismatch",e);let o=0;for(const n of t.children)rm(e.children[o++],n)}}function sm(e){return!e&&0!==e}function am(e){return e instanceof pm}function lm(e){return e instanceof Wh}function cm(e){return e instanceof Uh}function dm(e){return U(e[0])&&e[0].ns}function um(e){return"class"==e||"style"==e}var hm=i(601),mm={attributes:{"data-cke":!0}};mm.setAttributes=Ar(),mm.insert=_r().bind(null,"head"),mm.domAPI=kr(),mm.insertStyleElement=vr();fr()(hm.A,mm);hm.A&&hm.A.locals&&hm.A.locals;class pm extends(Rn(Y())){constructor(e){super(),this.element=null,this.isRendered=!1,this.locale=e,this.t=e&&e.t,this._viewCollections=new Yi,this._unboundChildren=this.createCollection(),this._viewCollections.on("add",((t,o)=>{o.locale=e,o.t=e&&e.t})),this.decorate("render")}get bindTemplate(){return this._bindTemplate?this._bindTemplate:this._bindTemplate=Wh.bind(this,this)}createCollection(e){const t=new Uh(e);return this._viewCollections.add(t),t}registerChild(e){re(e)||(e=[e]);for(const t of e)this._unboundChildren.add(t)}deregisterChild(e){re(e)||(e=[e]);for(const t of e)this._unboundChildren.remove(t)}setTemplate(e){this.template=new Wh(e)}extendTemplate(e){Wh.extend(this.template,e)}render(){if(this.isRendered)throw new E("ui-view-render-already-rendered",this);this.template&&(this.element=this.template.render(),this.registerChild(this.template.getViews())),this.isRendered=!0}destroy(){this.stopListening(),this._viewCollections.map((e=>e.destroy())),this.template&&this.template._revertData&&this.template.revert(this.element)}}function gm({emitter:e,activator:t,callback:o,contextElements:n}){e.listenTo(document,"mousedown",((e,i)=>{if(!t())return;const r="function"==typeof i.composedPath?i.composedPath():[],s="function"==typeof n?n():n;for(const e of s)if(e.contains(i.target)||r.includes(e))return;o()}))}function fm(e){return class extends e{disableCssTransitions(){this._isCssTransitionsDisabled=!0}enableCssTransitions(){this._isCssTransitionsDisabled=!1}constructor(...e){super(...e),this.set("_isCssTransitionsDisabled",!1),this.initializeCssTransitionDisablerMixin()}initializeCssTransitionDisablerMixin(){this.extendTemplate({attributes:{class:[this.bindTemplate.if("_isCssTransitionsDisabled","ck-transitions-disabled")]}})}}}function bm({view:e}){e.listenTo(e.element,"submit",((t,o)=>{o.preventDefault(),e.fire("submit")}),{useCapture:!0})}function km({keystrokeHandler:e,focusTracker:t,gridItems:o,numberOfColumns:n,uiLanguageDirection:i}){const r="number"==typeof n?()=>n:n;function s(e){return n=>{const i=o.find((e=>e.element===t.focusedElement)),r=o.getIndex(i),s=e(r,o);o.get(s).focus(),n.stopPropagation(),n.preventDefault()}}function a(e,t){return e===t-1?0:e+1}function l(e,t){return 0===e?t-1:e-1}e.set("arrowright",s(((e,t)=>"rtl"===i?l(e,t.length):a(e,t.length)))),e.set("arrowleft",s(((e,t)=>"rtl"===i?a(e,t.length):l(e,t.length)))),e.set("arrowup",s(((e,t)=>{let o=e-r();return o<0&&(o=e+r()*Math.floor(t.length/r()),o>t.length-1&&(o-=r())),o}))),e.set("arrowdown",s(((e,t)=>{let o=e+r();return o>t.length-1&&(o=e%r()),o})))}var wm=i(4106),_m={attributes:{"data-cke":!0}};_m.setAttributes=Ar(),_m.insert=_r().bind(null,"head"),_m.domAPI=kr(),_m.insertStyleElement=vr();fr()(wm.A,_m);wm.A&&wm.A.locals&&wm.A.locals;class ym extends pm{constructor(){super();const e=this.bindTemplate;this.set("content",""),this.set("viewBox","0 0 20 20"),this.set("fillColor",""),this.set("isColorInherited",!0),this.set("isVisible",!0),this.setTemplate({tag:"svg",ns:"http://www.w3.org/2000/svg",attributes:{class:["ck","ck-icon",e.if("isVisible","ck-hidden",(e=>!e)),"ck-reset_all-excluded",e.if("isColorInherited","ck-icon_inherit-color")],viewBox:e.to("viewBox")}})}render(){super.render(),this._updateXMLContent(),this._colorFillPaths(),this.on("change:content",(()=>{this._updateXMLContent(),this._colorFillPaths()})),this.on("change:fillColor",(()=>{this._colorFillPaths()}))}_updateXMLContent(){if(this.content){const e=(new DOMParser).parseFromString(this.content.trim(),"image/svg+xml").querySelector("svg"),t=e.getAttribute("viewBox");t&&(this.viewBox=t);for(const{name:t,value:o}of Array.from(e.attributes))ym.presentationalAttributeNames.includes(t)&&this.element.setAttribute(t,o);for(;this.element.firstChild;)this.element.removeChild(this.element.firstChild);for(;e.childNodes.length>0;)this.element.appendChild(e.childNodes[0])}}_colorFillPaths(){this.fillColor&&this.element.querySelectorAll(".ck-icon__fill").forEach((e=>{e.style.fill=this.fillColor}))}}ym.presentationalAttributeNames=["alignment-baseline","baseline-shift","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-rendering","cursor","direction","display","dominant-baseline","fill","fill-opacity","fill-rule","filter","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","image-rendering","letter-spacing","lighting-color","marker-end","marker-mid","marker-start","mask","opacity","overflow","paint-order","pointer-events","shape-rendering","stop-color","stop-opacity","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-decoration","text-overflow","text-rendering","transform","unicode-bidi","vector-effect","visibility","white-space","word-spacing","writing-mode"];const Am=ym;class Cm extends pm{constructor(){super(),this.set({style:void 0,text:void 0,id:void 0});const e=this.bindTemplate;this.setTemplate({tag:"span",attributes:{class:["ck","ck-button__label"],style:e.to("style"),id:e.to("id")},children:[{text:e.to("text")}]})}}var vm=i(8948),xm={attributes:{"data-cke":!0}};xm.setAttributes=Ar(),xm.insert=_r().bind(null,"head"),xm.domAPI=kr(),xm.insertStyleElement=vr();fr()(vm.A,xm);vm.A&&vm.A.locals&&vm.A.locals;class Em extends pm{constructor(e,t=new Cm){super(e),this._focusDelayed=null;const o=this.bindTemplate,n=A();this.set("_ariaPressed",!1),this.set("_ariaChecked",!1),this.set("ariaLabel",void 0),this.set("ariaLabelledBy",`ck-editor__aria-label_${n}`),this.set("class",void 0),this.set("labelStyle",void 0),this.set("icon",void 0),this.set("isEnabled",!0),this.set("isOn",!1),this.set("isVisible",!0),this.set("isToggleable",!1),this.set("keystroke",void 0),this.set("label",void 0),this.set("role",void 0),this.set("tabindex",-1),this.set("tooltip",!1),this.set("tooltipPosition","s"),this.set("type","button"),this.set("withText",!1),this.set("withKeystroke",!1),this.children=this.createCollection(),this.labelView=this._setupLabelView(t),this.iconView=new Am,this.iconView.extendTemplate({attributes:{class:"ck-button__icon"}}),this.keystrokeView=this._createKeystrokeView(),this.bind("_tooltipString").to(this,"tooltip",this,"label",this,"keystroke",this._getTooltipString.bind(this));const i={tag:"button",attributes:{class:["ck","ck-button",o.to("class"),o.if("isEnabled","ck-disabled",(e=>!e)),o.if("isVisible","ck-hidden",(e=>!e)),o.to("isOn",(e=>e?"ck-on":"ck-off")),o.if("withText","ck-button_with-text"),o.if("withKeystroke","ck-button_with-keystroke")],role:o.to("role"),type:o.to("type",(e=>e||"button")),tabindex:o.to("tabindex"),"aria-checked":o.to("_ariaChecked"),"aria-pressed":o.to("_ariaPressed"),"aria-label":o.to("ariaLabel"),"aria-labelledby":o.to("ariaLabelledBy"),"aria-disabled":o.if("isEnabled",!0,(e=>!e)),"data-cke-tooltip-text":o.to("_tooltipString"),"data-cke-tooltip-position":o.to("tooltipPosition")},children:this.children,on:{click:o.to((e=>{this.isEnabled?this.fire("execute"):e.preventDefault()}))}};this.bind("_ariaPressed").to(this,"isOn",this,"isToggleable",this,"role",((e,t,o)=>!(!t||Dm(o))&&String(!!e))),this.bind("_ariaChecked").to(this,"isOn",this,"isToggleable",this,"role",((e,t,o)=>!(!t||!Dm(o))&&String(!!e))),r.isSafari&&(this._focusDelayed||(this._focusDelayed=or((()=>this.focus()),0)),i.on.mousedown=o.to((()=>{this._focusDelayed()})),i.on.mouseup=o.to((()=>{this._focusDelayed.cancel()}))),this.setTemplate(i)}render(){super.render(),this.icon&&(this.iconView.bind("content").to(this,"icon"),this.children.add(this.iconView)),this.children.add(this.labelView),this.withKeystroke&&this.keystroke&&this.children.add(this.keystrokeView)}focus(){this.element.focus()}destroy(){this._focusDelayed&&this._focusDelayed.cancel(),super.destroy()}_setupLabelView(e){return e.bind("text","style","id").to(this,"label","labelStyle","ariaLabelledBy"),e}_createKeystrokeView(){const e=new pm;return e.setTemplate({tag:"span",attributes:{class:["ck","ck-button__keystroke"]},children:[{text:this.bindTemplate.to("keystroke",(e=>Ai(e)))}]}),e}_getTooltipString(e,t,o){return e?"string"==typeof e?e:(o&&(o=Ai(o)),e instanceof Function?e(t,o):`${t}${o?` (${o})`:""}`):""}}function Dm(e){switch(e){case"radio":case"checkbox":case"option":case"switch":case"menuitemcheckbox":case"menuitemradio":return!0;default:return!1}}var Bm=i(4866),Sm={attributes:{"data-cke":!0}};Sm.setAttributes=Ar(),Sm.insert=_r().bind(null,"head"),Sm.domAPI=kr(),Sm.insertStyleElement=vr();fr()(Bm.A,Sm);Bm.A&&Bm.A.locals&&Bm.A.locals;class Tm extends pm{constructor(e,t={}){super(e);const o=this.bindTemplate;this.set("label",t.label||""),this.set("class",t.class||null),this.children=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-form__header",o.to("class")]},children:this.children}),t.icon&&(this.iconView=new Am,this.iconView.content=t.icon,this.children.add(this.iconView));const n=new pm(e);n.setTemplate({tag:"h2",attributes:{class:["ck","ck-form__header__label"],role:"presentation"},children:[{text:o.to("label")}]}),this.children.add(n)}}class Im extends(z()){constructor(e){if(super(),this.focusables=e.focusables,this.focusTracker=e.focusTracker,this.keystrokeHandler=e.keystrokeHandler,this.actions=e.actions,e.actions&&e.keystrokeHandler)for(const t in e.actions){let o=e.actions[t];"string"==typeof o&&(o=[o]);for(const n of o)e.keystrokeHandler.set(n,((e,o)=>{this[t](),o()}),e.keystrokeHandlerOptions)}this.on("forwardCycle",(()=>this.focusFirst()),{priority:"low"}),this.on("backwardCycle",(()=>this.focusLast()),{priority:"low"})}get first(){return this.focusables.find(Pm)||null}get last(){return this.focusables.filter(Pm).slice(-1)[0]||null}get next(){return this._getDomFocusableItem(1)}get previous(){return this._getDomFocusableItem(-1)}get current(){let e=null;return null===this.focusTracker.focusedElement?null:(this.focusables.find(((t,o)=>{const n=t.element===this.focusTracker.focusedElement;return n&&(e=o),n})),e)}focusFirst(){this._focus(this.first,1)}focusLast(){this._focus(this.last,-1)}focusNext(){const e=this.next;e&&this.focusables.getIndex(e)===this.current||e===this.first?this.fire("forwardCycle"):this._focus(e,1)}focusPrevious(){const e=this.previous;e&&this.focusables.getIndex(e)===this.current||e===this.last?this.fire("backwardCycle"):this._focus(e,-1)}chain(e){const t=()=>null===this.current?null:this.focusables.get(this.current);this.listenTo(e,"forwardCycle",(e=>{const o=t();this.focusNext(),o!==t()&&e.stop()}),{priority:"low"}),this.listenTo(e,"backwardCycle",(e=>{const o=t();this.focusPrevious(),o!==t()&&e.stop()}),{priority:"low"})}unchain(e){this.stopListening(e)}_focus(e,t){e&&this.focusTracker.focusedElement!==e.element&&e.focus(t)}_getDomFocusableItem(e){const t=this.focusables.length;if(!t)return null;const o=this.current;if(null===o)return this[1===e?"first":"last"];let n=this.focusables.get(o),i=(o+t+e)%t;do{const o=this.focusables.get(i);if(Pm(o)){n=o;break}i=(i+t+e)%t}while(i!==o);return n}}function Pm(e){return Fm(e)&&ti(e.element)}function Fm(e){return!(!("focus"in e)||"function"!=typeof e.focus)}function Mm(e){return class extends e{constructor(...e){super(...e),this._onDragBound=this._onDrag.bind(this),this._onDragEndBound=this._onDragEnd.bind(this),this._lastDraggingCoordinates={x:0,y:0},this.on("render",(()=>{this._attachListeners()})),this.set("isDragging",!1)}_attachListeners(){this.listenTo(this.element,"mousedown",this._onDragStart.bind(this)),this.listenTo(this.element,"touchstart",this._onDragStart.bind(this))}_attachDragListeners(){this.listenTo(t.document,"mouseup",this._onDragEndBound),this.listenTo(t.document,"touchend",this._onDragEndBound),this.listenTo(t.document,"mousemove",this._onDragBound),this.listenTo(t.document,"touchmove",this._onDragBound)}_detachDragListeners(){this.stopListening(t.document,"mouseup",this._onDragEndBound),this.stopListening(t.document,"touchend",this._onDragEndBound),this.stopListening(t.document,"mousemove",this._onDragBound),this.stopListening(t.document,"touchmove",this._onDragBound)}_onDragStart(e,t){if(!this._isHandleElementPressed(t))return;this._attachDragListeners();let o=0,n=0;t instanceof MouseEvent?(o=t.clientX,n=t.clientY):(o=t.touches[0].clientX,n=t.touches[0].clientY),this._lastDraggingCoordinates={x:o,y:n},this.isDragging=!0}_onDrag(e,t){if(!this.isDragging)return void this._detachDragListeners();let o=0,n=0;t instanceof MouseEvent?(o=t.clientX,n=t.clientY):(o=t.touches[0].clientX,n=t.touches[0].clientY),t.preventDefault(),this.fire("drag",{deltaX:Math.round(o-this._lastDraggingCoordinates.x),deltaY:Math.round(n-this._lastDraggingCoordinates.y)}),this._lastDraggingCoordinates={x:o,y:n}}_onDragEnd(){this._detachDragListeners(),this.isDragging=!1}_isHandleElementPressed(e){return!!this.dragHandleElement&&(this.dragHandleElement===e.target||e.target instanceof HTMLElement&&this.dragHandleElement.contains(e.target))}}}var Rm=i(8091),zm={attributes:{"data-cke":!0}};zm.setAttributes=Ar(),zm.insert=_r().bind(null,"head"),zm.domAPI=kr(),zm.insertStyleElement=vr();fr()(Rm.A,zm);Rm.A&&Rm.A.locals&&Rm.A.locals;class Vm extends pm{constructor(e){super(e),this.children=this.createCollection(),this.keystrokes=new er,this._focusTracker=new Xi,this._focusables=new Uh,this.focusCycler=new Im({focusables:this._focusables,focusTracker:this._focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-dialog__actions"]},children:this.children})}render(){super.render(),this.keystrokes.listenTo(this.element)}setButtons(e){for(const t of e){const e=new Em(this.locale);let o;for(o in e.on("execute",(()=>t.onExecute())),t.onCreate&&t.onCreate(e),t)"onExecute"!=o&&"onCreate"!=o&&e.set(o,t[o]);this.children.add(e)}this._updateFocusCyclableItems()}focus(e){-1===e?this.focusCycler.focusLast():this.focusCycler.focusFirst()}_updateFocusCyclableItems(){Array.from(this.children).forEach((e=>{this._focusables.add(e),this._focusTracker.add(e.element)}))}}class Om extends pm{constructor(e){super(e),this.children=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-dialog__content"]},children:this.children})}reset(){for(;this.children.length;)this.children.remove(0)}}var Nm=i(880),Lm={attributes:{"data-cke":!0}};Lm.setAttributes=Ar(),Lm.insert=_r().bind(null,"head"),Lm.domAPI=kr(),Lm.insertStyleElement=vr();fr()(Nm.A,Lm);Nm.A&&Nm.A.locals&&Nm.A.locals;const Hm="screen-center",jm="editor-center",qm="editor-top-side",Um="editor-top-center",Wm="editor-bottom-center",$m="editor-above-center",Gm="editor-below-center",Km=Yn("px");class Zm extends(Mm(pm)){constructor(e,{getCurrentDomRoot:t,getViewportOffset:o}){super(e),this.wasMoved=!1;const n=this.bindTemplate,i=e.t;this.set("className",""),this.set("ariaLabel",i("Editor dialog")),this.set("isModal",!1),this.set("position",Hm),this.set("_isVisible",!1),this.set("_isTransparent",!1),this.set("_top",0),this.set("_left",0),this._getCurrentDomRoot=t,this._getViewportOffset=o,this.decorate("moveTo"),this.parts=this.createCollection(),this.keystrokes=new er,this.focusTracker=new Xi,this._focusables=new Uh,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-dialog-overlay",n.if("isModal","ck-dialog-overlay__transparent",(e=>!e)),n.if("_isVisible","ck-hidden",(e=>!e))],tabindex:"-1"},children:[{tag:"div",attributes:{tabindex:"-1",class:["ck","ck-dialog",n.to("className")],role:"dialog","aria-label":n.to("ariaLabel"),style:{top:n.to("_top",(e=>Km(e))),left:n.to("_left",(e=>Km(e))),visibility:n.if("_isTransparent","hidden")}},children:this.parts}]})}render(){super.render(),this.keystrokes.set("Esc",((e,t)=>{this.fire("close",{source:"escKeyPress"}),t()})),this.on("drag",((e,{deltaX:t,deltaY:o})=>{this.wasMoved=!0,this.moveBy(t,o)})),this.listenTo(t.window,"resize",(()=>{this._isVisible&&!this.wasMoved&&this.updatePosition()})),this.listenTo(t.document,"scroll",(()=>{this._isVisible&&!this.wasMoved&&this.updatePosition()})),this.on("change:_isVisible",((e,t,o)=>{o&&(this._isTransparent=!0,setTimeout((()=>{this.updatePosition(),this._isTransparent=!1,this.focus()}),10))})),this.keystrokes.listenTo(this.element)}get dragHandleElement(){return this.headerView?this.headerView.element:null}setupParts({icon:e,title:t,hasCloseButton:o=!0,content:n,actionButtons:i}){t&&(this.headerView=new Tm(this.locale,{icon:e}),o&&(this.closeButtonView=this._createCloseButton(),this.headerView.children.add(this.closeButtonView)),this.headerView.label=t,this.ariaLabel=t,this.parts.add(this.headerView,0)),n&&(n instanceof pm&&(n=[n]),this.contentView=new Om(this.locale),this.contentView.children.addMany(n),this.parts.add(this.contentView)),i&&(this.actionsView=new Vm(this.locale),this.actionsView.setButtons(i),this.parts.add(this.actionsView)),this._updateFocusCyclableItems()}focus(){this._focusCycler.focusFirst()}moveTo(e,t){const o=this._getViewportRect(),n=this._getDialogRect();e+n.width>o.right&&(e=o.right-n.width),e{var t;this._focusables.add(e),this.focusTracker.add(e.element),Fm(t=e)&&"focusCycler"in t&&t.focusCycler instanceof Im&&this._focusCycler.chain(e.focusCycler)}))}_createCloseButton(){const e=new Em(this.locale),t=this.locale.t;return e.set({label:t("Close"),tooltip:!0,icon:qh.cancel}),e.on("execute",(()=>this.fire("close",{source:"closeButton"}))),e}}Zm.defaultOffset=15;const Jm=Zm;class Ym extends lr{static get pluginName(){return"Dialog"}constructor(e){super(e);const t=e.t;this._initShowHideListeners(),this._initFocusToggler(),this._initMultiRootIntegration(),this.set({id:null,isOpen:!1}),e.accessibility.addKeystrokeInfos({categoryId:"navigation",keystrokes:[{label:t("Move focus in and out of an active dialog window"),keystroke:"Ctrl+F6",mayRequireFn:!0}]})}_initShowHideListeners(){this.on("show",((e,t)=>{this._show(t)})),this.on("show",((e,t)=>{t.onShow&&t.onShow(this)}),{priority:"low"}),this.on("hide",(()=>{Ym._visibleDialogPlugin&&Ym._visibleDialogPlugin._hide()})),this.on("hide",(()=>{this._onHide&&(this._onHide(this),this._onHide=void 0)}),{priority:"low"})}_initFocusToggler(){const e=this.editor;e.keystrokes.set("Ctrl+F6",((t,o)=>{this.isOpen&&!this.view.isModal&&(this.view.focusTracker.isFocused?e.editing.view.focus():this.view.focus(),o())}))}_initMultiRootIntegration(){const e=this.editor.model;e.document.on("change:data",(()=>{if(!this.view)return;const t=e.document.differ.getChangedRoots();for(const e of t)e.state&&this.view.updatePosition()}))}show(e){this.hide(),this.fire(`show:${e.id}`,e)}_show({id:e,icon:t,title:o,hasCloseButton:n=!0,content:i,actionButtons:r,className:s,isModal:a,position:l,onHide:c}){const d=this.editor;this.view=new Jm(d.locale,{getCurrentDomRoot:()=>d.editing.view.getDomRoot(d.model.document.selection.anchor.root.rootName),getViewportOffset:()=>d.ui.viewportOffset});const u=this.view;u.on("close",(()=>{this.hide()})),d.ui.view.body.add(u),d.ui.focusTracker.add(u.element),d.keystrokes.listenTo(u.element),l||(l=a?Hm:jm),u.set({position:l,_isVisible:!0,className:s,isModal:a}),u.setupParts({icon:t,title:o,hasCloseButton:n,content:i,actionButtons:r}),this.id=e,c&&(this._onHide=c),this.isOpen=!0,Ym._visibleDialogPlugin=this}hide(){Ym._visibleDialogPlugin&&Ym._visibleDialogPlugin.fire(`hide:${Ym._visibleDialogPlugin.id}`)}_hide(){if(!this.view)return;const e=this.editor,t=this.view;t.contentView&&t.contentView.reset(),e.ui.view.body.remove(t),e.ui.focusTracker.remove(t.element),e.keystrokes.stopListening(t.element),t.destroy(),e.editing.view.focus(),this.id=null,this.isOpen=!1,Ym._visibleDialogPlugin=null}}var Qm=i(3389),Xm={attributes:{"data-cke":!0}};Xm.setAttributes=Ar(),Xm.insert=_r().bind(null,"head"),Xm.domAPI=kr(),Xm.insertStyleElement=vr();fr()(Qm.A,Xm);Qm.A&&Qm.A.locals&&Qm.A.locals;class ep extends Em{constructor(e,t=new Cm){super(e,t),this._checkIconHolderView=new tp,this.set({hasCheckSpace:!1,_hasCheck:this.isToggleable});const o=this.bindTemplate;this.extendTemplate({attributes:{class:["ck-list-item-button",o.if("isToggleable","ck-list-item-button_toggleable")]}}),this.bind("_hasCheck").to(this,"hasCheckSpace",this,"isToggleable",((e,t)=>e||t))}render(){super.render(),this._hasCheck&&this.children.add(this._checkIconHolderView,0),this._watchCheckIconHolderMount()}_watchCheckIconHolderMount(){this._checkIconHolderView.bind("isOn").to(this,"isOn",(e=>this.isToggleable&&e)),this.on("change:_hasCheck",((e,t,o)=>{const{children:n,_checkIconHolderView:i}=this;o?n.add(i,0):n.remove(i)}))}}class tp extends pm{constructor(){super(),this._checkIconView=this._createCheckIconView();const e=this.bindTemplate;this.children=this.createCollection(),this.set("isOn",!1),this.setTemplate({tag:"span",children:this.children,attributes:{class:["ck","ck-list-item-button__check-holder",e.to("isOn",(e=>e?"ck-on":"ck-off"))]}})}render(){super.render(),this.isOn&&this.children.add(this._checkIconView,0),this._watchCheckIconMount()}_watchCheckIconMount(){this.on("change:isOn",((e,t,o)=>{const{children:n,_checkIconView:i}=this;o&&!n.has(i)?n.add(i):!o&&n.has(i)&&n.remove(i)}))}_createCheckIconView(){const e=new Am;return e.content=qh.check,e.extendTemplate({attributes:{class:"ck-list-item-button__check-icon"}}),e}}var op=i(5078),np={attributes:{"data-cke":!0}};np.setAttributes=Ar(),np.insert=_r().bind(null,"head"),np.domAPI=kr(),np.insertStyleElement=vr();fr()(op.A,np);op.A&&op.A.locals&&op.A.locals;class ip extends ep{constructor(e){super(e),this.set({withText:!0,withKeystroke:!0,tooltip:!1,role:"menuitem"}),this.extendTemplate({attributes:{class:["ck-menu-bar__menu__item__button"]}})}}var rp=i(4606),sp={attributes:{"data-cke":!0}};sp.setAttributes=Ar(),sp.insert=_r().bind(null,"head"),sp.domAPI=kr(),sp.insertStyleElement=vr();fr()(rp.A,sp);rp.A&&rp.A.locals&&rp.A.locals;class ap extends pm{constructor(e){super(e),this.set("text",void 0),this.set("for",void 0),this.id=`ck-editor__label_${A()}`;const t=this.bindTemplate;this.setTemplate({tag:"label",attributes:{class:["ck","ck-label"],id:this.id,for:t.to("for")},children:[{text:t.to("text")}]})}}class lp extends pm{constructor(e,t){super(e);const o=e.t,n=new ap;n.text=o("Help Contents. To close this dialog press ESC."),this.setTemplate({tag:"div",attributes:{class:["ck","ck-accessibility-help-dialog__content"],"aria-labelledby":n.id,role:"document",tabindex:-1},children:[Ae(document,"p",{},o("Below, you can find a list of keyboard shortcuts that can be used in the editor.")),...this._createCategories(Array.from(t.values())),n]})}focus(){this.element.focus()}_createCategories(e){return e.map((e=>{const t=[Ae(document,"h3",{},e.label),...Array.from(e.groups.values()).map((e=>this._createGroup(e))).flat()];return e.description&&t.splice(1,0,Ae(document,"p",{},e.description)),Ae(document,"section",{},t)}))}_createGroup(e){const t=e.keystrokes.sort(((e,t)=>e.label.localeCompare(t.label))).map((e=>this._createGroupRow(e))).flat(),o=[Ae(document,"dl",{},t)];return e.label&&o.unshift(Ae(document,"h4",{},e.label)),o}_createGroupRow(e){const t=this.locale.t,o=Ae(document,"dt"),n=Ae(document,"dd"),i=function(e){if("string"==typeof e)return[[e]];if("string"==typeof e[0])return[e];return e}(e.keystroke),s=[];for(const e of i)s.push(e.map(cp).join(""));return o.innerHTML=e.label,n.innerHTML=s.join(", ")+(e.mayRequireFn&&r.isMac?` ${t("(may require Fn)")}`:""),[o,n]}}function cp(e){return Ai(e).split("+").map((e=>`${e}`)).join("+")}const dp='';var up=i(9550),hp={attributes:{"data-cke":!0}};hp.setAttributes=Ar(),hp.insert=_r().bind(null,"head"),hp.domAPI=kr(),hp.insertStyleElement=vr();fr()(up.A,hp);up.A&&up.A.locals&&up.A.locals;class mp extends lr{constructor(){super(...arguments),this.contentView=null}static get requires(){return[Ym]}static get pluginName(){return"AccessibilityHelp"}init(){const e=this.editor,t=e.locale.t;e.ui.componentFactory.add("accessibilityHelp",(()=>{const e=this._createButton(Em);return e.set({tooltip:!0,withText:!1,label:t("Accessibility help")}),e})),e.ui.componentFactory.add("menuBar:accessibilityHelp",(()=>{const e=this._createButton(ip);return e.label=t("Accessibility"),e})),e.keystrokes.set("Alt+0",((e,t)=>{this._toggleDialog(),t()})),this._setupRootLabels()}_createButton(e){const t=this.editor,o=t.plugins.get("Dialog"),n=new e(t.locale);return n.set({keystroke:"Alt+0",icon:dp,isToggleable:!0}),n.on("execute",(()=>this._toggleDialog())),n.bind("isOn").to(o,"id",(e=>"accessibilityHelp"===e)),n}_setupRootLabels(){const e=this.editor,t=e.editing.view,o=e.t;function n(e,t){const n=`${t.getAttribute("aria-label")}. ${o("Press %0 for help.",[Ai("Alt+0")])}`;e.setAttribute("aria-label",n,t)}e.ui.on("ready",(()=>{t.change((e=>{for(const o of t.document.roots)n(e,o)})),e.on("addRoot",((o,i)=>{const r=e.editing.view.document.getRoot(i.rootName);t.change((e=>n(e,r)))}),{priority:"low"})}))}_toggleDialog(){const e=this.editor,t=e.plugins.get("Dialog"),o=e.locale.t;this.contentView||(this.contentView=new lp(e.locale,e.accessibility.keystrokeInfos)),"accessibilityHelp"===t.id?t.hide():t.show({id:"accessibilityHelp",className:"ck-accessibility-help-dialog",title:o("Accessibility help"),icon:dp,hasCloseButton:!0,content:this.contentView})}}class pp extends Uh{constructor(e,t=[]){super(t),this.locale=e}get bodyCollectionContainer(){return this._bodyCollectionContainer}attachToDom(){this._bodyCollectionContainer=new Wh({tag:"div",attributes:{class:["ck","ck-reset_all","ck-body","ck-rounded-corners"],dir:this.locale.uiLanguageDirection,role:"application"},children:this}).render();let e=document.querySelector(".ck-body-wrapper");e||(e=Ae(document,"div",{class:"ck-body-wrapper"}),document.body.appendChild(e)),e.appendChild(this._bodyCollectionContainer)}detachFromDom(){super.destroy(),this._bodyCollectionContainer&&this._bodyCollectionContainer.remove();const e=document.querySelector(".ck-body-wrapper");e&&0==e.childElementCount&&e.remove()}}var gp=i(9624),fp={attributes:{"data-cke":!0}};fp.setAttributes=Ar(),fp.insert=_r().bind(null,"head"),fp.domAPI=kr(),fp.insertStyleElement=vr();fr()(gp.A,fp);gp.A&&gp.A.locals&&gp.A.locals;class bp extends Em{constructor(e){super(e),this.isToggleable=!0,this.toggleSwitchView=this._createToggleView(),this.extendTemplate({attributes:{class:"ck-switchbutton"}})}render(){super.render(),this.children.add(this.toggleSwitchView)}_createToggleView(){const e=new pm;return e.setTemplate({tag:"span",attributes:{class:["ck","ck-button__toggle"]},children:[{tag:"span",attributes:{class:["ck","ck-button__toggle__inner"]}}]}),e}}class kp extends(_p(Em)){}class wp extends(_p(ep)){}function _p(e){return class extends e{constructor(...e){super(...e),this.buttonView=this,this._fileInputView=new yp(this.locale),this._fileInputView.bind("acceptedType").to(this),this._fileInputView.bind("allowMultipleFiles").to(this),this._fileInputView.delegate("done").to(this),this.on("execute",(()=>{this._fileInputView.open()})),this.extendTemplate({attributes:{class:"ck-file-dialog-button"}})}render(){super.render(),this.children.add(this._fileInputView)}}}class yp extends pm{constructor(e){super(e),this.set("acceptedType",void 0),this.set("allowMultipleFiles",!1);const t=this.bindTemplate;this.setTemplate({tag:"input",attributes:{class:["ck-hidden"],type:"file",tabindex:"-1",accept:t.to("acceptedType"),multiple:t.to("allowMultipleFiles")},on:{change:t.to((()=>{this.element&&this.element.files&&this.element.files.length&&this.fire("done",this.element.files),this.element.value=""}))}})}open(){this.element.click()}}const Ap='';var Cp=i(1750),vp={attributes:{"data-cke":!0}};vp.setAttributes=Ar(),vp.insert=_r().bind(null,"head"),vp.domAPI=kr(),vp.insertStyleElement=vr();fr()(Cp.A,vp);Cp.A&&Cp.A.locals&&Cp.A.locals;class xp extends pm{constructor(e,t){super(e);const o=this.bindTemplate;this.set("isCollapsed",!1),this.set("label",""),this.buttonView=this._createButtonView(),this.children=this.createCollection(),this.set("_collapsibleAriaLabelUid",void 0),t&&this.children.addMany(t),this.setTemplate({tag:"div",attributes:{class:["ck","ck-collapsible",o.if("isCollapsed","ck-collapsible_collapsed")]},children:[this.buttonView,{tag:"div",attributes:{class:["ck","ck-collapsible__children"],role:"region",hidden:o.if("isCollapsed","hidden"),"aria-labelledby":o.to("_collapsibleAriaLabelUid")},children:this.children}]})}render(){super.render(),this._collapsibleAriaLabelUid=this.buttonView.labelView.element.id}focus(){this.buttonView.focus()}_createButtonView(){const e=new Em(this.locale),t=e.bindTemplate;return e.set({withText:!0,icon:Ap}),e.extendTemplate({attributes:{"aria-expanded":t.to("isOn",(e=>String(e)))}}),e.bind("label").to(this),e.bind("isOn").to(this,"isCollapsed",(e=>!e)),e.on("execute",(()=>{this.isCollapsed=!this.isCollapsed})),e}}function Ep(e,t){const o=e.t,n={Black:o("Black"),"Dim grey":o("Dim grey"),Grey:o("Grey"),"Light grey":o("Light grey"),White:o("White"),Red:o("Red"),Orange:o("Orange"),Yellow:o("Yellow"),"Light green":o("Light green"),Green:o("Green"),Aquamarine:o("Aquamarine"),Turquoise:o("Turquoise"),"Light blue":o("Light blue"),Blue:o("Blue"),Purple:o("Purple")};return t.map((e=>{const t=n[e.label];return t&&t!=e.label&&(e.label=t),e}))}function Dp(e){return e.map(Bp).filter((e=>!!e))}function Bp(e){return"string"==typeof e?{model:e,label:e,hasBorder:!1,view:{name:"span",styles:{color:e}}}:{model:e.color,label:e.label||e.color,hasBorder:void 0!==e.hasBorder&&e.hasBorder,view:{name:"span",styles:{color:`${e.color}`}}}}class Sp extends Em{constructor(e){super(e);const t=this.bindTemplate;this.set("color",void 0),this.set("hasBorder",!1),this.icon='',this.extendTemplate({attributes:{style:{backgroundColor:t.to("color",(e=>r.isMediaForcedColors?null:e))},class:["ck","ck-color-grid__tile",t.if("hasBorder","ck-color-selector__color-tile_bordered")]}})}render(){super.render(),this.iconView.fillColor="hsl(0, 0%, 100%)"}}var Tp=i(7962),Ip={attributes:{"data-cke":!0}};Ip.setAttributes=Ar(),Ip.insert=_r().bind(null,"head"),Ip.domAPI=kr(),Ip.insertStyleElement=vr();fr()(Tp.A,Ip);Tp.A&&Tp.A.locals&&Tp.A.locals;class Pp extends pm{constructor(e,t){super(e);const o=t&&t.colorDefinitions?t.colorDefinitions:[];this.columns=t&&t.columns?t.columns:5;const n={gridTemplateColumns:`repeat( ${this.columns}, 1fr)`};this.set("selectedColor",void 0),this.items=this.createCollection(),this.focusTracker=new Xi,this.keystrokes=new er,this.items.on("add",((e,t)=>{t.isOn=t.color===this.selectedColor})),o.forEach((e=>{const t=new Sp;t.set({color:e.color,label:e.label,tooltip:!0,hasBorder:e.options.hasBorder}),t.on("execute",(()=>{this.fire("execute",{value:e.color,hasBorder:e.options.hasBorder,label:e.label})})),this.items.add(t)})),this.setTemplate({tag:"div",children:this.items,attributes:{class:["ck","ck-color-grid"],style:n}}),this.on("change:selectedColor",((e,t,o)=>{for(const e of this.items)e.isOn=e.color===o}))}focus(){this.items.length&&this.items.first.focus()}focusLast(){this.items.length&&this.items.last.focus()}render(){super.render();for(const e of this.items)this.focusTracker.add(e.element);this.items.on("add",((e,t)=>{this.focusTracker.add(t.element)})),this.items.on("remove",((e,t)=>{this.focusTracker.remove(t.element)})),this.keystrokes.listenTo(this.element),km({keystrokeHandler:this.keystrokes,focusTracker:this.focusTracker,gridItems:this.items,numberOfColumns:this.columns,uiLanguageDirection:this.locale&&this.locale.uiLanguageDirection})}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}}var Fp=i(8156);const Mp=function(e){var t,o,n=[],i=1;if("string"==typeof e)if(Fp[e])n=Fp[e].slice(),o="rgb";else if("transparent"===e)i=0,o="rgb",n=[0,0,0];else if(/^#[A-Fa-f0-9]+$/.test(e)){var r=e.slice(1);i=1,(l=r.length)<=4?(n=[parseInt(r[0]+r[0],16),parseInt(r[1]+r[1],16),parseInt(r[2]+r[2],16)],4===l&&(i=parseInt(r[3]+r[3],16)/255)):(n=[parseInt(r[0]+r[1],16),parseInt(r[2]+r[3],16),parseInt(r[4]+r[5],16)],8===l&&(i=parseInt(r[6]+r[7],16)/255)),n[0]||(n[0]=0),n[1]||(n[1]=0),n[2]||(n[2]=0),o="rgb"}else if(t=/^((?:rgb|hs[lvb]|hwb|cmyk?|xy[zy]|gray|lab|lchu?v?|[ly]uv|lms)a?)\s*\(([^\)]*)\)/.exec(e)){var s=t[1],a="rgb"===s;o=r=s.replace(/a$/,"");var l="cmyk"===r?4:"gray"===r?1:3;n=t[2].trim().split(/\s*[,\/]\s*|\s+/).map((function(e,t){if(/%$/.test(e))return t===l?parseFloat(e)/100:"rgb"===r?255*parseFloat(e)/100:parseFloat(e);if("h"===r[t]){if(/deg$/.test(e))return parseFloat(e);if(void 0!==Rp[e])return Rp[e]}return parseFloat(e)})),s===r&&n.push(1),i=a||void 0===n[l]?1:n[l],n=n.slice(0,l)}else e.length>10&&/[0-9](?:\s|\/)/.test(e)&&(n=e.match(/([0-9]+)/g).map((function(e){return parseFloat(e)})),o=e.match(/([a-z])/gi).join("").toLowerCase());else isNaN(e)?Array.isArray(e)||e.length?(n=[e[0],e[1],e[2]],o="rgb",i=4===e.length?e[3]:1):e instanceof Object&&(null!=e.r||null!=e.red||null!=e.R?(o="rgb",n=[e.r||e.red||e.R||0,e.g||e.green||e.G||0,e.b||e.blue||e.B||0]):(o="hsl",n=[e.h||e.hue||e.H||0,e.s||e.saturation||e.S||0,e.l||e.lightness||e.L||e.b||e.brightness]),i=e.a||e.alpha||e.opacity||1,null!=e.opacity&&(i/=100)):(o="rgb",n=[e>>>16,(65280&e)>>>8,255&e]);return{space:o,values:n,alpha:i}};var Rp={red:0,orange:60,yellow:120,green:180,blue:240,purple:300};var zp=i(734),Vp=i.t(zp,2);function Op(e,t){if(!e)return"";const o=Np(e);if(!o)return"";if(o.space===t)return e;if(n=o,!Object.keys(Vp).includes(n.space))return"";var n;const i=Vp[o.space][t];if(!i)return"";return function(e,t){switch(t){case"hex":return`#${e}`;case"rgb":return`rgb( ${e[0]}, ${e[1]}, ${e[2]} )`;case"hsl":return`hsl( ${e[0]}, ${e[1]}%, ${e[2]}% )`;case"hwb":return`hwb( ${e[0]}, ${e[1]}, ${e[2]} )`;case"lab":return`lab( ${e[0]}% ${e[1]} ${e[2]} )`;case"lch":return`lch( ${e[0]}% ${e[1]} ${e[2]} )`;default:return""}}(i("hex"===o.space?o.hexValue:o.values),t)}function Np(e){if(e.startsWith("#")){const t=Mp(e);return{space:"hex",values:t.values,hexValue:e,alpha:t.alpha}}const t=Mp(e);return t.space?t:null}var Lp=i(6365),Hp={attributes:{"data-cke":!0}};Hp.setAttributes=Ar(),Hp.insert=_r().bind(null,"head"),Hp.domAPI=kr(),Hp.insertStyleElement=vr();fr()(Lp.A,Hp);Lp.A&&Lp.A.locals&&Lp.A.locals;class jp extends pm{constructor(e,t){super(e);const o=`ck-labeled-field-view-${A()}`,n=`ck-labeled-field-view-status-${A()}`;this.fieldView=t(this,o,n),this.set("label",void 0),this.set("isEnabled",!0),this.set("isEmpty",!0),this.set("isFocused",!1),this.set("errorText",null),this.set("infoText",null),this.set("class",void 0),this.set("placeholder",void 0),this.labelView=this._createLabelView(o),this.statusView=this._createStatusView(n),this.fieldWrapperChildren=this.createCollection([this.fieldView,this.labelView]),this.bind("_statusText").to(this,"errorText",this,"infoText",((e,t)=>e||t));const i=this.bindTemplate;this.setTemplate({tag:"div",attributes:{class:["ck","ck-labeled-field-view",i.to("class"),i.if("isEnabled","ck-disabled",(e=>!e)),i.if("isEmpty","ck-labeled-field-view_empty"),i.if("isFocused","ck-labeled-field-view_focused"),i.if("placeholder","ck-labeled-field-view_placeholder"),i.if("errorText","ck-error")]},children:[{tag:"div",attributes:{class:["ck","ck-labeled-field-view__input-wrapper"]},children:this.fieldWrapperChildren},this.statusView]})}_createLabelView(e){const t=new ap(this.locale);return t.for=e,t.bind("text").to(this,"label"),t}_createStatusView(e){const t=new pm(this.locale),o=this.bindTemplate;return t.setTemplate({tag:"div",attributes:{class:["ck","ck-labeled-field-view__status",o.if("errorText","ck-labeled-field-view__status_error"),o.if("_statusText","ck-hidden",(e=>!e))],id:e,role:o.if("errorText","alert")},children:[{text:o.to("_statusText")}]}),t}focus(e){this.fieldView.focus(e)}}class qp extends pm{constructor(e){super(e),this.set("value",void 0),this.set("id",void 0),this.set("placeholder",void 0),this.set("tabIndex",void 0),this.set("isReadOnly",!1),this.set("hasError",!1),this.set("ariaDescribedById",void 0),this.set("ariaLabel",void 0),this.focusTracker=new Xi,this.bind("isFocused").to(this.focusTracker),this.set("isEmpty",!0);const t=this.bindTemplate;this.setTemplate({tag:"input",attributes:{class:["ck","ck-input",t.if("isFocused","ck-input_focused"),t.if("isEmpty","ck-input-text_empty"),t.if("hasError","ck-error")],id:t.to("id"),placeholder:t.to("placeholder"),tabindex:t.to("tabIndex"),readonly:t.to("isReadOnly"),"aria-invalid":t.if("hasError",!0),"aria-describedby":t.to("ariaDescribedById"),"aria-label":t.to("ariaLabel")},on:{input:t.to(((...e)=>{this.fire("input",...e),this._updateIsEmpty()})),change:t.to(this._updateIsEmpty.bind(this))}})}render(){super.render(),this.focusTracker.add(this.element),this._setDomElementValue(this.value),this._updateIsEmpty(),this.on("change:value",((e,t,o)=>{this._setDomElementValue(o),this._updateIsEmpty()}))}destroy(){super.destroy(),this.focusTracker.destroy()}select(){this.element.select()}focus(){this.element.focus()}reset(){this.value=this.element.value="",this._updateIsEmpty()}_updateIsEmpty(){this.isEmpty=!this.element.value}_setDomElementValue(e){this.element.value=e||0===e?e:""}}var Up=i(1546),Wp={attributes:{"data-cke":!0}};Wp.setAttributes=Ar(),Wp.insert=_r().bind(null,"head"),Wp.domAPI=kr(),Wp.insertStyleElement=vr();fr()(Up.A,Wp);Up.A&&Up.A.locals&&Up.A.locals;class $p extends qp{constructor(e){super(e),this.set("inputMode","text");const t=this.bindTemplate;this.extendTemplate({attributes:{inputmode:t.to("inputMode")}})}}class Gp extends $p{constructor(e){super(e),this.extendTemplate({attributes:{type:"text",class:["ck-input-text"]}})}}class Kp extends $p{constructor(e,{min:t,max:o,step:n}={}){super(e);const i=this.bindTemplate;this.set("min",t),this.set("max",o),this.set("step",n),this.extendTemplate({attributes:{type:"number",class:["ck-input-number"],min:i.to("min"),max:i.to("max"),step:i.to("step")}})}}var Zp=i(8368),Jp={attributes:{"data-cke":!0}};Jp.setAttributes=Ar(),Jp.insert=_r().bind(null,"head"),Jp.domAPI=kr(),Jp.insertStyleElement=vr();fr()(Zp.A,Jp);Zp.A&&Zp.A.locals&&Zp.A.locals;class Yp extends pm{constructor(e){super(e);const t=this.bindTemplate;this.set("isVisible",!1),this.set("position","se"),this.children=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-reset","ck-dropdown__panel",t.to("position",(e=>`ck-dropdown__panel_${e}`)),t.if("isVisible","ck-dropdown__panel-visible")],tabindex:"-1"},children:this.children,on:{selectstart:t.to((e=>{"input"!==e.target.tagName.toLocaleLowerCase()&&e.preventDefault()}))}})}focus(){if(this.children.length){const e=this.children.first;"function"==typeof e.focus?e.focus():D("ui-dropdown-panel-focus-child-missing-focus",{childView:this.children.first,dropdownPanel:this})}}focusLast(){if(this.children.length){const e=this.children.last;"function"==typeof e.focusLast?e.focusLast():e.focus()}}}var Qp=i(426),Xp={attributes:{"data-cke":!0}};Xp.setAttributes=Ar(),Xp.insert=_r().bind(null,"head"),Xp.domAPI=kr(),Xp.insertStyleElement=vr();fr()(Qp.A,Xp);Qp.A&&Qp.A.locals&&Qp.A.locals;class eg extends pm{constructor(e,t,o){super(e);const n=this.bindTemplate;this.buttonView=t,this.panelView=o,this.set("isOpen",!1),this.set("isEnabled",!0),this.set("class",void 0),this.set("id",void 0),this.set("panelPosition","auto"),this.panelView.bind("isVisible").to(this,"isOpen"),this.keystrokes=new er,this.focusTracker=new Xi,this.setTemplate({tag:"div",attributes:{class:["ck","ck-dropdown",n.to("class"),n.if("isEnabled","ck-disabled",(e=>!e))],id:n.to("id"),"aria-describedby":n.to("ariaDescribedById")},children:[t,o]}),t.extendTemplate({attributes:{class:["ck-dropdown__button"],"data-cke-tooltip-disabled":n.to("isOpen")}})}render(){super.render(),this.focusTracker.add(this.buttonView.element),this.focusTracker.add(this.panelView.element),this.listenTo(this.buttonView,"open",(()=>{this.isOpen=!this.isOpen})),this.on("change:isOpen",((e,t,o)=>{if(o)if("auto"===this.panelPosition){const e=eg._getOptimalPosition({element:this.panelView.element,target:this.buttonView.element,fitInViewport:!0,positions:this._panelPositions});this.panelView.position=e?e.name:this._panelPositions[0].name}else this.panelView.position=this.panelPosition})),this.keystrokes.listenTo(this.element);const e=(e,t)=>{this.isOpen&&(this.isOpen=!1,t())};this.keystrokes.set("arrowdown",((e,t)=>{this.buttonView.isEnabled&&!this.isOpen&&(this.isOpen=!0,t())})),this.keystrokes.set("arrowright",((e,t)=>{this.isOpen&&t()})),this.keystrokes.set("arrowleft",e),this.keystrokes.set("esc",e)}focus(){this.buttonView.focus()}get _panelPositions(){const{south:e,north:t,southEast:o,southWest:n,northEast:i,northWest:r,southMiddleEast:s,southMiddleWest:a,northMiddleEast:l,northMiddleWest:c}=eg.defaultPanelPositions;return"rtl"!==this.locale.uiLanguageDirection?[o,n,s,a,e,i,r,l,c,t]:[n,o,a,s,e,r,i,c,l,t]}}eg.defaultPanelPositions={south:(e,t)=>({top:e.bottom,left:e.left-(t.width-e.width)/2,name:"s"}),southEast:e=>({top:e.bottom,left:e.left,name:"se"}),southWest:(e,t)=>({top:e.bottom,left:e.left-t.width+e.width,name:"sw"}),southMiddleEast:(e,t)=>({top:e.bottom,left:e.left-(t.width-e.width)/4,name:"sme"}),southMiddleWest:(e,t)=>({top:e.bottom,left:e.left-3*(t.width-e.width)/4,name:"smw"}),north:(e,t)=>({top:e.top-t.height,left:e.left-(t.width-e.width)/2,name:"n"}),northEast:(e,t)=>({top:e.top-t.height,left:e.left,name:"ne"}),northWest:(e,t)=>({top:e.top-t.height,left:e.left-t.width+e.width,name:"nw"}),northMiddleEast:(e,t)=>({top:e.top-t.height,left:e.left-(t.width-e.width)/4,name:"nme"}),northMiddleWest:(e,t)=>({top:e.top-t.height,left:e.left-3*(t.width-e.width)/4,name:"nmw"})},eg._getOptimalPosition=oi;const tg=eg;class og extends Em{constructor(e){super(e),this.arrowView=this._createArrowView(),this.extendTemplate({attributes:{"aria-haspopup":!0,"aria-expanded":this.bindTemplate.to("isOn",(e=>String(e)))}}),this.delegate("execute").to(this,"open")}render(){super.render(),this.children.add(this.arrowView)}_createArrowView(){const e=new Am;return e.content=Ap,e.extendTemplate({attributes:{class:"ck-dropdown__arrow"}}),e}}class ng extends pm{constructor(e){super(e),this.setTemplate({tag:"span",attributes:{class:["ck","ck-toolbar__separator"]}})}}class ig extends pm{constructor(e){super(e),this.setTemplate({tag:"span",attributes:{class:["ck","ck-toolbar__line-break"]}})}}function rg(e){if(Array.isArray(e))return{items:e,removeItems:[]};const t={items:[],removeItems:[]};return e?{...t,...e}:t}var sg=i(66),ag={attributes:{"data-cke":!0}};ag.setAttributes=Ar(),ag.insert=_r().bind(null,"head"),ag.domAPI=kr(),ag.insertStyleElement=vr();fr()(sg.A,ag);sg.A&&sg.A.locals&&sg.A.locals;const lg=(()=>({alignLeft:qh.alignLeft,bold:qh.bold,importExport:qh.importExport,paragraph:qh.paragraph,plus:qh.plus,text:qh.text,threeVerticalDots:qh.threeVerticalDots,pilcrow:qh.pilcrow,dragIndicator:qh.dragIndicator}))();class cg extends pm{constructor(e,t){super(e);const o=this.bindTemplate,n=this.t;this.options=t||{},this.set("ariaLabel",n("Editor toolbar")),this.set("maxWidth","auto"),this.items=this.createCollection(),this.focusTracker=new Xi,this.keystrokes=new er,this.set("class",void 0),this.set("isCompact",!1),this.itemsView=new dg(e),this.children=this.createCollection(),this.children.add(this.itemsView),this.focusables=this.createCollection();const i="rtl"===e.uiLanguageDirection;this._focusCycler=new Im({focusables:this.focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:[i?"arrowright":"arrowleft","arrowup"],focusNext:[i?"arrowleft":"arrowright","arrowdown"]}});const r=["ck","ck-toolbar",o.to("class"),o.if("isCompact","ck-toolbar_compact")];var s;this.options.shouldGroupWhenFull&&this.options.isFloating&&r.push("ck-toolbar_floating"),this.setTemplate({tag:"div",attributes:{class:r,role:"toolbar","aria-label":o.to("ariaLabel"),style:{maxWidth:o.to("maxWidth")},tabindex:-1},children:this.children,on:{mousedown:(s=this,s.bindTemplate.to((e=>{e.target===s.element&&e.preventDefault()})))}}),this._behavior=this.options.shouldGroupWhenFull?new hg(this):new ug(this)}render(){super.render(),this.focusTracker.add(this.element);for(const e of this.items)this.focusTracker.add(e.element);this.items.on("add",((e,t)=>{this.focusTracker.add(t.element)})),this.items.on("remove",((e,t)=>{this.focusTracker.remove(t.element)})),this.keystrokes.listenTo(this.element),this._behavior.render(this)}destroy(){return this._behavior.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy(),super.destroy()}focus(){this._focusCycler.focusFirst()}focusLast(){this._focusCycler.focusLast()}fillFromConfig(e,t,o){this.items.addMany(this._buildItemsFromConfig(e,t,o))}_buildItemsFromConfig(e,t,o){const n=rg(e),i=o||n.removeItems;return this._cleanItemsConfiguration(n.items,t,i).map((e=>U(e)?this._createNestedToolbarDropdown(e,t,i):"|"===e?new ng:"-"===e?new ig:t.create(e))).filter((e=>!!e))}_cleanItemsConfiguration(e,t,o){const n=e.filter(((e,n,i)=>"|"===e||-1===o.indexOf(e)&&("-"===e?!this.options.shouldGroupWhenFull||(D("toolbarview-line-break-ignored-when-grouping-items",i),!1):!(!U(e)&&!t.has(e))||(D("toolbarview-item-unavailable",{item:e}),!1))));return this._cleanSeparatorsAndLineBreaks(n)}_cleanSeparatorsAndLineBreaks(e){const t=e=>"-"!==e&&"|"!==e,o=e.length,n=e.findIndex(t);if(-1===n)return[];const i=o-e.slice().reverse().findIndex(t);return e.slice(n,i).filter(((e,o,n)=>{if(t(e))return!0;return!(o>0&&n[o-1]===e)}))}_createNestedToolbarDropdown(e,t,o){let{label:n,icon:i,items:r,tooltip:s=!0,withText:a=!1}=e;if(r=this._cleanItemsConfiguration(r,t,o),!r.length)return null;const l=Eg(this.locale);return n||D("toolbarview-nested-toolbar-dropdown-missing-label",e),l.class="ck-toolbar__nested-toolbar-dropdown",l.buttonView.set({label:n,tooltip:s,withText:!!a}),!1!==i?l.buttonView.icon=lg[i]||i||qh.threeVerticalDots:l.buttonView.withText=!0,Dg(l,(()=>l.toolbarView._buildItemsFromConfig(r,t,o))),l}}class dg extends pm{constructor(e){super(e),this.children=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-toolbar__items"]},children:this.children})}}class ug{constructor(e){const t=e.bindTemplate;e.set("isVertical",!1),e.itemsView.children.bindTo(e.items).using((e=>e)),e.focusables.bindTo(e.items).using((e=>Fm(e)?e:null)),e.extendTemplate({attributes:{class:[t.if("isVertical","ck-toolbar_vertical")]}})}render(){}destroy(){}}class hg{constructor(e){this.resizeObserver=null,this.cachedPadding=null,this.shouldUpdateGroupingOnNextResize=!1,this.view=e,this.viewChildren=e.children,this.viewFocusables=e.focusables,this.viewItemsView=e.itemsView,this.viewFocusTracker=e.focusTracker,this.viewLocale=e.locale,this.ungroupedItems=e.createCollection(),this.groupedItems=e.createCollection(),this.groupedItemsDropdown=this._createGroupedItemsDropdown(),e.itemsView.children.bindTo(this.ungroupedItems).using((e=>e)),this.ungroupedItems.on("change",this._updateFocusCyclableItems.bind(this)),e.children.on("change",this._updateFocusCyclableItems.bind(this)),e.items.on("change",((e,t)=>{const o=t.index,n=Array.from(t.added);for(const e of t.removed)o>=this.ungroupedItems.length?this.groupedItems.remove(e):this.ungroupedItems.remove(e);for(let e=o;ethis.ungroupedItems.length?this.groupedItems.add(t,e-this.ungroupedItems.length):this.ungroupedItems.add(t,e)}this._updateGrouping()})),e.extendTemplate({attributes:{class:["ck-toolbar_grouping"]}})}render(e){this.viewElement=e.element,this._enableGroupingOnResize(),this._enableGroupingOnMaxWidthChange(e)}destroy(){this.groupedItemsDropdown.destroy(),this.resizeObserver.destroy()}_updateGrouping(){if(!this.viewElement.ownerDocument.body.contains(this.viewElement))return;if(!ti(this.viewElement))return void(this.shouldUpdateGroupingOnNextResize=!0);const e=this.groupedItems.length;let t;for(;this._areItemsOverflowing;)this._groupLastItem(),t=!0;if(!t&&this.groupedItems.length){for(;this.groupedItems.length&&!this._areItemsOverflowing;)this._ungroupFirstItem();this._areItemsOverflowing&&this._groupLastItem()}this.groupedItems.length!==e&&this.view.fire("groupedItemsUpdate")}get _areItemsOverflowing(){if(!this.ungroupedItems.length)return!1;const e=this.viewElement,o=this.viewLocale.uiLanguageDirection,n=new qn(e.lastChild),i=new qn(e);if(!this.cachedPadding){const n=t.window.getComputedStyle(e),i="ltr"===o?"paddingRight":"paddingLeft";this.cachedPadding=Number.parseInt(n[i])}return"ltr"===o?n.right>i.right-this.cachedPadding:n.left{e&&e===t.contentRect.width&&!this.shouldUpdateGroupingOnNextResize||(this.shouldUpdateGroupingOnNextResize=!1,this._updateGrouping(),e=t.contentRect.width)})),this._updateGrouping()}_enableGroupingOnMaxWidthChange(e){e.on("change:maxWidth",(()=>{this._updateGrouping()}))}_groupLastItem(){this.groupedItems.length||(this.viewChildren.add(new ng),this.viewChildren.add(this.groupedItemsDropdown),this.viewFocusTracker.add(this.groupedItemsDropdown.element)),this.groupedItems.add(this.ungroupedItems.remove(this.ungroupedItems.last),0)}_ungroupFirstItem(){this.ungroupedItems.add(this.groupedItems.remove(this.groupedItems.first)),this.groupedItems.length||(this.viewChildren.remove(this.groupedItemsDropdown),this.viewChildren.remove(this.viewChildren.last),this.viewFocusTracker.remove(this.groupedItemsDropdown.element))}_createGroupedItemsDropdown(){const e=this.viewLocale,t=e.t,o=Eg(e);return o.class="ck-toolbar__grouped-dropdown",o.panelPosition="ltr"===e.uiLanguageDirection?"sw":"se",Dg(o,this.groupedItems),o.buttonView.set({label:t("Show more items"),tooltip:!0,tooltipPosition:"rtl"===e.uiLanguageDirection?"se":"sw",icon:qh.threeVerticalDots}),o}_updateFocusCyclableItems(){this.viewFocusables.clear(),this.ungroupedItems.map((e=>{Fm(e)&&this.viewFocusables.add(e)})),this.groupedItems.length&&this.viewFocusables.add(this.groupedItemsDropdown)}}class mg extends pm{constructor(e){super(e);const t=this.bindTemplate;this.set("isVisible",!0),this.children=this.createCollection(),this.setTemplate({tag:"li",attributes:{class:["ck","ck-list__item",t.if("isVisible","ck-hidden",(e=>!e))],role:"presentation"},children:this.children})}focus(){this.children.first&&this.children.first.focus()}}class pg extends pm{constructor(e){super(e),this.setTemplate({tag:"li",attributes:{class:["ck","ck-list__separator"]}})}}class gg extends pm{constructor(e,t=new ap){super(e);const o=this.bindTemplate,n=new kg(e);this.set({label:"",isVisible:!0}),this.labelView=t,this.labelView.bind("text").to(this,"label"),this.children=this.createCollection(),this.children.addMany([this.labelView,n]),n.set({role:"group",ariaLabelledBy:t.id}),n.focusTracker.destroy(),n.keystrokes.destroy(),this.items=n.items,this.setTemplate({tag:"li",attributes:{role:"presentation",class:["ck","ck-list__group",o.if("isVisible","ck-hidden",(e=>!e))]},children:this.children})}focus(){if(this.items){const e=this.items.find((e=>!(e instanceof pg)));e&&e.focus()}}}var fg=i(6048),bg={attributes:{"data-cke":!0}};bg.setAttributes=Ar(),bg.insert=_r().bind(null,"head"),bg.domAPI=kr(),bg.insertStyleElement=vr();fr()(fg.A,bg);fg.A&&fg.A.locals&&fg.A.locals;class kg extends pm{constructor(e){super(e),this._listItemGroupToChangeListeners=new WeakMap;const t=this.bindTemplate;this.focusables=new Uh,this.items=this.createCollection(),this.focusTracker=new Xi,this.keystrokes=new er,this._focusCycler=new Im({focusables:this.focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"arrowup",focusNext:"arrowdown"}}),this.set("ariaLabel",void 0),this.set("ariaLabelledBy",void 0),this.set("role",void 0),this.setTemplate({tag:"ul",attributes:{class:["ck","ck-reset","ck-list"],role:t.to("role"),"aria-label":t.to("ariaLabel"),"aria-labelledby":t.to("ariaLabelledBy")},children:this.items})}render(){super.render();for(const e of this.items)e instanceof gg?this._registerFocusableItemsGroup(e):e instanceof mg&&this._registerFocusableListItem(e);this.items.on("change",((e,t)=>{for(const e of t.removed)e instanceof gg?this._deregisterFocusableItemsGroup(e):e instanceof mg&&this._deregisterFocusableListItem(e);for(const e of Array.from(t.added).reverse())e instanceof gg?this._registerFocusableItemsGroup(e,t.index):this._registerFocusableListItem(e,t.index)})),this.keystrokes.listenTo(this.element)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this._focusCycler.focusFirst()}focusFirst(){this._focusCycler.focusFirst()}focusLast(){this._focusCycler.focusLast()}_registerFocusableListItem(e,t){this.focusTracker.add(e.element),this.focusables.add(e,t)}_deregisterFocusableListItem(e){this.focusTracker.remove(e.element),this.focusables.remove(e)}_getOnGroupItemsChangeCallback(e){return(t,o)=>{for(const e of o.removed)this._deregisterFocusableListItem(e);for(const t of Array.from(o.added).reverse())this._registerFocusableListItem(t,this.items.getIndex(e)+o.index)}}_registerFocusableItemsGroup(e,t){Array.from(e.items).forEach(((e,o)=>{const n=void 0!==t?t+o:void 0;this._registerFocusableListItem(e,n)}));const o=this._getOnGroupItemsChangeCallback(e);this._listItemGroupToChangeListeners.set(e,o),e.items.on("change",o)}_deregisterFocusableItemsGroup(e){for(const t of e.items)this._deregisterFocusableListItem(t);e.items.off("change",this._listItemGroupToChangeListeners.get(e)),this._listItemGroupToChangeListeners.delete(e)}}var wg=i(7133),_g={attributes:{"data-cke":!0}};_g.setAttributes=Ar(),_g.insert=_r().bind(null,"head"),_g.domAPI=kr(),_g.insertStyleElement=vr();fr()(wg.A,_g);wg.A&&wg.A.locals&&wg.A.locals;class yg extends pm{constructor(e,t){super(e);const o=this.bindTemplate;this.set("class",void 0),this.set("labelStyle",void 0),this.set("icon",void 0),this.set("isEnabled",!0),this.set("isOn",!1),this.set("isToggleable",!1),this.set("isVisible",!0),this.set("keystroke",void 0),this.set("withKeystroke",!1),this.set("label",void 0),this.set("tabindex",-1),this.set("tooltip",!1),this.set("tooltipPosition","s"),this.set("type","button"),this.set("withText",!1),this.children=this.createCollection(),this.actionView=this._createActionView(t),this.arrowView=this._createArrowView(),this.keystrokes=new er,this.focusTracker=new Xi,this.setTemplate({tag:"div",attributes:{class:["ck","ck-splitbutton",o.to("class"),o.if("isVisible","ck-hidden",(e=>!e)),this.arrowView.bindTemplate.if("isOn","ck-splitbutton_open")]},children:this.children})}render(){super.render(),this.children.add(this.actionView),this.children.add(this.arrowView),this.focusTracker.add(this.actionView.element),this.focusTracker.add(this.arrowView.element),this.keystrokes.listenTo(this.element),this.keystrokes.set("arrowright",((e,t)=>{this.focusTracker.focusedElement===this.actionView.element&&(this.arrowView.focus(),t())})),this.keystrokes.set("arrowleft",((e,t)=>{this.focusTracker.focusedElement===this.arrowView.element&&(this.actionView.focus(),t())}))}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this.actionView.focus()}_createActionView(e){const t=e||new Em;return e||t.bind("icon","isEnabled","isOn","isToggleable","keystroke","label","tabindex","tooltip","tooltipPosition","type","withText").to(this),t.extendTemplate({attributes:{class:"ck-splitbutton__action"}}),t.delegate("execute").to(this),t}_createArrowView(){const e=new Em,t=e.bindTemplate;return e.icon=Ap,e.extendTemplate({attributes:{class:["ck-splitbutton__arrow"],"data-cke-tooltip-disabled":t.to("isOn"),"aria-haspopup":!0,"aria-expanded":t.to("isOn",(e=>String(e)))}}),e.bind("isEnabled").to(this),e.bind("label").to(this),e.bind("tooltip").to(this),e.delegate("execute").to(this,"open"),e}}var Ag=i(7475),Cg={attributes:{"data-cke":!0}};Cg.setAttributes=Ar(),Cg.insert=_r().bind(null,"head"),Cg.domAPI=kr(),Cg.insertStyleElement=vr();fr()(Ag.A,Cg);Ag.A&&Ag.A.locals&&Ag.A.locals;var vg=i(2454),xg={attributes:{"data-cke":!0}};xg.setAttributes=Ar(),xg.insert=_r().bind(null,"head"),xg.domAPI=kr(),xg.insertStyleElement=vr();fr()(vg.A,xg);vg.A&&vg.A.locals&&vg.A.locals;function Eg(e,o=og){const n="function"==typeof o?new o(e):o,i=new Yp(e),r=new tg(e,n,i);return n.bind("isEnabled").to(r),n instanceof yg?n.arrowView.bind("isOn").to(r,"isOpen"):n.bind("isOn").to(r,"isOpen"),function(e){(function(e){e.on("render",(()=>{gm({emitter:e,activator:()=>e.isOpen,callback:()=>{e.isOpen=!1},contextElements:()=>[e.element,...e.focusTracker._elements]})}))})(e),function(e){e.on("execute",(t=>{t.source instanceof bp||(e.isOpen=!1)}))}(e),function(e){e.focusTracker.on("change:isFocused",((t,o,n)=>{e.isOpen&&!n&&(e.isOpen=!1)}))}(e),function(e){e.keystrokes.set("arrowdown",((t,o)=>{e.isOpen&&(e.panelView.focus(),o())})),e.keystrokes.set("arrowup",((t,o)=>{e.isOpen&&(e.panelView.focusLast(),o())}))}(e),function(e){e.on("change:isOpen",((o,n,i)=>{if(i)return;const r=e.panelView.element;r&&r.contains(t.document.activeElement)&&e.buttonView.focus()}))}(e),function(e){e.on("change:isOpen",((t,o,n)=>{n&&e.panelView.focus()}),{priority:"low"})}(e)}(r),r}function Dg(e,t,o={}){e.extendTemplate({attributes:{class:["ck-toolbar-dropdown"]}}),e.isOpen?Bg(e,t,o):e.once("change:isOpen",(()=>Bg(e,t,o)),{priority:"highest"}),o.enableActiveItemFocusOnDropdownOpen&&Ig(e,(()=>e.toolbarView.items.find((e=>e.isOn))))}function Bg(e,t,o){const n=e.locale,i=n.t,r=e.toolbarView=new cg(n),s="function"==typeof t?t():t;r.ariaLabel=o.ariaLabel||i("Dropdown toolbar"),o.maxWidth&&(r.maxWidth=o.maxWidth),o.class&&(r.class=o.class),o.isCompact&&(r.isCompact=o.isCompact),o.isVertical&&(r.isVertical=!0),s instanceof Uh?r.items.bindTo(s).using((e=>e)):r.items.addMany(s),e.panelView.children.add(r),r.items.delegate("execute").to(e)}function Sg(e,t,o={}){e.isOpen?Tg(e,t,o):e.once("change:isOpen",(()=>Tg(e,t,o)),{priority:"highest"}),Ig(e,(()=>e.listView.items.find((e=>e instanceof mg&&e.children.first.isOn))))}function Tg(e,t,o){const n=e.locale,i=e.listView=new kg(n),r="function"==typeof t?t():t;i.ariaLabel=o.ariaLabel,i.role=o.role,Pg(e,i.items,r,n),e.panelView.children.add(i),i.items.delegate("execute").to(e)}function Ig(e,t){e.on("change:isOpen",(()=>{if(!e.isOpen)return;const o=t();o&&("function"==typeof o.focus?o.focus():D("ui-dropdown-focus-child-on-open-child-missing-focus",{view:o}))}),{priority:C.low-10})}function Pg(e,t,o,n){t.on("change",(()=>{const e=[...t].reduce(((e,t)=>(t instanceof mg&&t.children.first instanceof ep&&e.push(t.children.first),e)),[]),o=e.some((e=>e.isToggleable));e.forEach((e=>{e.hasCheckSpace=o}))})),t.bindTo(o).using((t=>{if("separator"===t.type)return new pg(n);if("group"===t.type){const o=new gg(n);return o.set({label:t.label}),Pg(e,o.items,t.items,n),o.items.delegate("execute").to(e),o}if("button"===t.type||"switchbutton"===t.type){const e="menuitemcheckbox"===t.model.role||"menuitemradio"===t.model.role,o=new mg(n);let i;return"button"===t.type?(i=new ep(n),i.set({isToggleable:e})):i=new bp(n),i.bind(...Object.keys(t.model)).to(t.model),i.delegate("execute").to(o),o.children.add(i),o}return null}))}const Fg=(e,t,o)=>{const n=new Gp(e.locale);return n.set({id:t,ariaDescribedById:o}),n.bind("isReadOnly").to(e,"isEnabled",(e=>!e)),n.bind("hasError").to(e,"errorText",(e=>!!e)),n.on("input",(()=>{e.errorText=null})),e.bind("isEmpty","isFocused","placeholder").to(n),n},Mg=(e,t,o)=>{const n=new Kp(e.locale);return n.set({id:t,ariaDescribedById:o,inputMode:"numeric"}),n.bind("isReadOnly").to(e,"isEnabled",(e=>!e)),n.bind("hasError").to(e,"errorText",(e=>!!e)),n.on("input",(()=>{e.errorText=null})),e.bind("isEmpty","isFocused","placeholder").to(n),n},Rg=(e,t,o)=>{const n=Eg(e.locale);return n.set({id:t,ariaDescribedById:o}),n.bind("isEnabled").to(e),n},zg=(e,t=0,o=1)=>e>o?o:eMath.round(o*e)/o,Og=(Math.PI,e=>("#"===e[0]&&(e=e.substring(1)),e.length<6?{r:parseInt(e[0]+e[0],16),g:parseInt(e[1]+e[1],16),b:parseInt(e[2]+e[2],16),a:4===e.length?Vg(parseInt(e[3]+e[3],16)/255,2):1}:{r:parseInt(e.substring(0,2),16),g:parseInt(e.substring(2,4),16),b:parseInt(e.substring(4,6),16),a:8===e.length?Vg(parseInt(e.substring(6,8),16)/255,2):1})),Ng=({h:e,s:t,v:o,a:n})=>{const i=(200-t)*o/100;return{h:Vg(e),s:Vg(i>0&&i<200?t*o/100/(i<=100?i:200-i)*100:0),l:Vg(i/2),a:Vg(n,2)}},Lg=e=>{const{h:t,s:o,l:n}=Ng(e);return`hsl(${t}, ${o}%, ${n}%)`},Hg=({h:e,s:t,v:o,a:n})=>{e=e/360*6,t/=100,o/=100;const i=Math.floor(e),r=o*(1-t),s=o*(1-(e-i)*t),a=o*(1-(1-e+i)*t),l=i%6;return{r:Vg(255*[o,s,r,r,a,o][l]),g:Vg(255*[a,o,o,s,r,r][l]),b:Vg(255*[r,r,a,o,o,s][l]),a:Vg(n,2)}},jg=e=>{const t=e.toString(16);return t.length<2?"0"+t:t},qg=({r:e,g:t,b:o,a:n})=>{const i=n<1?jg(Vg(255*n)):"";return"#"+jg(e)+jg(t)+jg(o)+i},Ug=({r:e,g:t,b:o,a:n})=>{const i=Math.max(e,t,o),r=i-Math.min(e,t,o),s=r?i===e?(t-o)/r:i===t?2+(o-e)/r:4+(e-t)/r:0;return{h:Vg(60*(s<0?s+6:s)),s:Vg(i?r/i*100:0),v:Vg(i/255*100),a:n}},Wg=(e,t)=>{if(e===t)return!0;for(const o in e)if(e[o]!==t[o])return!1;return!0},$g={},Gg=e=>{let t=$g[e];return t||(t=document.createElement("template"),t.innerHTML=e,$g[e]=t),t},Kg=(e,t,o)=>{e.dispatchEvent(new CustomEvent(t,{bubbles:!0,detail:o}))};let Zg=!1;const Jg=e=>"touches"in e,Yg=(e,t)=>{const o=Jg(t)?t.touches[0]:t,n=e.el.getBoundingClientRect();Kg(e.el,"move",e.getMove({x:zg((o.pageX-(n.left+window.pageXOffset))/n.width),y:zg((o.pageY-(n.top+window.pageYOffset))/n.height)}))};class Qg{constructor(e,t,o,n){const i=Gg(`
    `);e.appendChild(i.content.cloneNode(!0));const r=e.querySelector(`[part=${t}]`);r.addEventListener("mousedown",this),r.addEventListener("touchstart",this),r.addEventListener("keydown",this),this.el=r,this.xy=n,this.nodes=[r.firstChild,r]}set dragging(e){const t=e?document.addEventListener:document.removeEventListener;t(Zg?"touchmove":"mousemove",this),t(Zg?"touchend":"mouseup",this)}handleEvent(e){switch(e.type){case"mousedown":case"touchstart":if(e.preventDefault(),!(e=>!(Zg&&!Jg(e)||(Zg||(Zg=Jg(e)),0)))(e)||!Zg&&0!=e.button)return;this.el.focus(),Yg(this,e),this.dragging=!0;break;case"mousemove":case"touchmove":e.preventDefault(),Yg(this,e);break;case"mouseup":case"touchend":this.dragging=!1;break;case"keydown":((e,t)=>{const o=t.keyCode;o>40||e.xy&&o<37||o<33||(t.preventDefault(),Kg(e.el,"move",e.getMove({x:39===o?.01:37===o?-.01:34===o?.05:33===o?-.05:35===o?1:36===o?-1:0,y:40===o?.01:38===o?-.01:0},!0)))})(this,e)}}style(e){e.forEach(((e,t)=>{for(const o in e)this.nodes[t].style.setProperty(o,e[o])}))}}class Xg extends Qg{constructor(e){super(e,"hue",'aria-label="Hue" aria-valuemin="0" aria-valuemax="360"',!1)}update({h:e}){this.h=e,this.style([{left:e/360*100+"%",color:Lg({h:e,s:100,v:100,a:1})}]),this.el.setAttribute("aria-valuenow",`${Vg(e)}`)}getMove(e,t){return{h:t?zg(this.h+360*e.x,0,360):360*e.x}}}class ef extends Qg{constructor(e){super(e,"saturation",'aria-label="Color"',!0)}update(e){this.hsva=e,this.style([{top:100-e.v+"%",left:`${e.s}%`,color:Lg(e)},{"background-color":Lg({h:e.h,s:100,v:100,a:1})}]),this.el.setAttribute("aria-valuetext",`Saturation ${Vg(e.s)}%, Brightness ${Vg(e.v)}%`)}getMove(e,t){return{s:t?zg(this.hsva.s+100*e.x,0,100):100*e.x,v:t?zg(this.hsva.v-100*e.y,0,100):Math.round(100-100*e.y)}}}const tf=Symbol("same"),of=Symbol("color"),nf=Symbol("hsva"),rf=Symbol("update"),sf=Symbol("parts"),af=Symbol("css"),lf=Symbol("sliders");class cf extends HTMLElement{static get observedAttributes(){return["color"]}get[af](){return[':host{display:flex;flex-direction:column;position:relative;width:200px;height:200px;user-select:none;-webkit-user-select:none;cursor:default}:host([hidden]){display:none!important}[role=slider]{position:relative;touch-action:none;user-select:none;-webkit-user-select:none;outline:0}[role=slider]:last-child{border-radius:0 0 8px 8px}[part$=pointer]{position:absolute;z-index:1;box-sizing:border-box;width:28px;height:28px;display:flex;place-content:center center;transform:translate(-50%,-50%);background-color:#fff;border:2px solid #fff;border-radius:50%;box-shadow:0 2px 4px rgba(0,0,0,.2)}[part$=pointer]::after{content:"";width:100%;height:100%;border-radius:inherit;background-color:currentColor}[role=slider]:focus [part$=pointer]{transform:translate(-50%,-50%) scale(1.1)}',"[part=hue]{flex:0 0 24px;background:linear-gradient(to right,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red 100%)}[part=hue-pointer]{top:50%;z-index:2}","[part=saturation]{flex-grow:1;border-color:transparent;border-bottom:12px solid #000;border-radius:8px 8px 0 0;background-image:linear-gradient(to top,#000,transparent),linear-gradient(to right,#fff,rgba(255,255,255,0));box-shadow:inset 0 0 0 1px rgba(0,0,0,.05)}[part=saturation-pointer]{z-index:3}"]}get[lf](){return[ef,Xg]}get color(){return this[of]}set color(e){if(!this[tf](e)){const t=this.colorModel.toHsva(e);this[rf](t),this[of]=e}}constructor(){super();const e=Gg(``),t=this.attachShadow({mode:"open"});t.appendChild(e.content.cloneNode(!0)),t.addEventListener("move",this),this[sf]=this[lf].map((e=>new e(t)))}connectedCallback(){if(this.hasOwnProperty("color")){const e=this.color;delete this.color,this.color=e}else this.color||(this.color=this.colorModel.defaultColor)}attributeChangedCallback(e,t,o){const n=this.colorModel.fromAttr(o);this[tf](n)||(this.color=n)}handleEvent(e){const t=this[nf],o={...t,...e.detail};let n;this[rf](o),Wg(o,t)||this[tf](n=this.colorModel.fromHsva(o))||(this[of]=n,Kg(this,"color-changed",{value:n}))}[tf](e){return this.color&&this.colorModel.equal(e,this.color)}[rf](e){this[nf]=e,this[sf].forEach((t=>t.update(e)))}}const df={defaultColor:"#000",toHsva:e=>Ug(Og(e)),fromHsva:({h:e,s:t,v:o})=>qg(Hg({h:e,s:t,v:o,a:1})),equal:(e,t)=>e.toLowerCase()===t.toLowerCase()||Wg(Og(e),Og(t)),fromAttr:e=>e};class uf extends cf{get colorModel(){return df}}var hf=i(3086),mf={attributes:{"data-cke":!0}};mf.setAttributes=Ar(),mf.insert=_r().bind(null,"head"),mf.domAPI=kr(),mf.insertStyleElement=vr();fr()(hf.A,mf);hf.A&&hf.A.locals&&hf.A.locals;class pf extends pm{constructor(e,t={}){super(e),this.set({color:"",_hexColor:""}),this.hexInputRow=this._createInputRow();const o=this.createCollection();t.hideInput||o.add(this.hexInputRow),this.setTemplate({tag:"div",attributes:{class:["ck","ck-color-picker"],tabindex:-1},children:o}),this._config=t,this._debounceColorPickerEvent=el((e=>{this.set("color",e),this.fire("colorSelected",{color:this.color})}),150,{leading:!0}),this.on("set:color",((e,t,o)=>{e.return=Op(o,this._config.format||"hsl")})),this.on("change:color",(()=>{this._hexColor=gf(this.color)})),this.on("change:_hexColor",(()=>{document.activeElement!==this.picker&&this.picker.setAttribute("color",this._hexColor),gf(this.color)!=gf(this._hexColor)&&(this.color=this._hexColor)}))}render(){var e,o;if(super.render(),e="hex-color-picker",o=uf,void 0===customElements.get(e)&&customElements.define(e,o),this.picker=t.document.createElement("hex-color-picker"),this.picker.setAttribute("class","hex-color-picker"),this.picker.setAttribute("tabindex","-1"),this._createSlidersView(),this.element){this.hexInputRow.element?this.element.insertBefore(this.picker,this.hexInputRow.element):this.element.appendChild(this.picker);const e=document.createElement("style");e.textContent='[role="slider"]:focus [part$="pointer"] {border: 1px solid #fff;outline: 1px solid var(--ck-color-focus-border);box-shadow: 0 0 0 2px #fff;}',this.picker.shadowRoot.appendChild(e)}this.picker.addEventListener("color-changed",(e=>{const t=e.detail.value;this._debounceColorPickerEvent(t)}))}focus(){if(!this._config.hideInput&&(r.isGecko||r.isiOS||r.isSafari)){this.hexInputRow.children.get(1).focus()}this.slidersView.first.focus()}_createSlidersView(){const e=[...this.picker.shadowRoot.children].filter((e=>"slider"===e.getAttribute("role"))).map((e=>new ff(e)));this.slidersView=this.createCollection(),e.forEach((e=>{this.slidersView.add(e)}))}_createInputRow(){const e=this._createColorInput();return new kf(this.locale,e)}_createColorInput(){const e=new jp(this.locale,Fg),{t}=this.locale;return e.set({label:t("HEX"),class:"color-picker-hex-input"}),e.fieldView.bind("value").to(this,"_hexColor",(t=>e.isFocused?e.fieldView.value:t.startsWith("#")?t.substring(1):t)),e.fieldView.on("input",(()=>{const t=e.fieldView.element.value;if(t){const e=wf(t);e&&this._debounceColorPickerEvent(e)}})),e}isValid(){const{t:e}=this.locale;return!!this._config.hideInput||(this.resetValidationStatus(),!!this.hexInputRow.getParsedColor()||(this.hexInputRow.inputView.errorText=e('Please enter a valid color (e.g. "ff0000").'),!1))}resetValidationStatus(){this.hexInputRow.inputView.errorText=null}}function gf(e){let t=function(e){if(!e)return"";const t=Np(e);return t?"hex"===t.space?t.hexValue:Op(e,"hex"):"#000"}(e);return t||(t="#000"),4===t.length&&(t="#"+[t[1],t[1],t[2],t[2],t[3],t[3]].join("")),t.toLowerCase()}class ff extends pm{constructor(e){super(),this.element=e}focus(){this.element.focus()}}class bf extends pm{constructor(e){super(e),this.setTemplate({tag:"div",attributes:{class:["ck","ck-color-picker__hash-view"]},children:"#"})}}class kf extends pm{constructor(e,t){super(e),this.inputView=t,this.children=this.createCollection([new bf,this.inputView]),this.setTemplate({tag:"div",attributes:{class:["ck","ck-color-picker__row"]},children:this.children})}getParsedColor(){return wf(this.inputView.fieldView.element.value)}}function wf(e){if(!e)return null;const t=e.trim().replace(/^#/,"");return[3,4,6,8].includes(t.length)&&/^(([0-9a-fA-F]{2}){3,4}|([0-9a-fA-F]){3,4})$/.test(t)?`#${t}`:null}class _f extends(Y(Yi)){constructor(e){super(e),this.set("isEmpty",!0),this.on("change",(()=>{this.set("isEmpty",0===this.length)}))}add(e,t){return this.find((t=>t.color===e.color))?this:super.add(e,t)}hasColor(e){return!!this.find((t=>t.color===e))}}class yf extends pm{constructor(e,{colors:t,columns:o,removeButtonLabel:n,documentColorsLabel:i,documentColorsCount:r,colorPickerLabel:s,focusTracker:a,focusables:l}){super(e);const c=this.bindTemplate;this.set("isVisible",!0),this.focusTracker=a,this.items=this.createCollection(),this.colorDefinitions=t,this.columns=o,this.documentColors=new _f,this.documentColorsCount=r,this._focusables=l,this._removeButtonLabel=n,this._colorPickerLabel=s,this._documentColorsLabel=i,this.setTemplate({tag:"div",attributes:{class:["ck-color-grids-fragment",c.if("isVisible","ck-hidden",(e=>!e))]},children:this.items}),this.removeColorButtonView=this._createRemoveColorButton(),this.items.add(this.removeColorButtonView)}updateDocumentColors(e,t){const o=e.document,n=this.documentColorsCount;this.documentColors.clear();for(const i of o.getRoots()){const o=e.createRangeIn(i);for(const e of o.getItems())if(e.is("$textProxy")&&e.hasAttribute(t)&&(this._addColorToDocumentColors(e.getAttribute(t)),this.documentColors.length>=n))return}}updateSelectedColors(){const e=this.documentColorsGrid,t=this.staticColorsGrid,o=this.selectedColor;t.selectedColor=o,e&&(e.selectedColor=o)}render(){if(super.render(),this.staticColorsGrid=this._createStaticColorsGrid(),this.items.add(this.staticColorsGrid),this.documentColorsCount){const e=Wh.bind(this.documentColors,this.documentColors),t=new pm(this.locale);t.setTemplate({tag:"span",attributes:{class:["ck","ck-color-grid__label",e.if("isEmpty","ck-hidden")]},children:[{text:this._documentColorsLabel}]}),this.items.add(t),this.documentColorsGrid=this._createDocumentColorsGrid(),this.items.add(this.documentColorsGrid)}this._createColorPickerButton(),this._addColorSelectorElementsToFocusTracker()}focus(){this.removeColorButtonView.focus()}destroy(){super.destroy()}addColorPickerButton(){this.colorPickerButtonView&&(this.items.add(this.colorPickerButtonView),this.focusTracker.add(this.colorPickerButtonView.element),this._focusables.add(this.colorPickerButtonView))}_addColorSelectorElementsToFocusTracker(){this.focusTracker.add(this.removeColorButtonView.element),this._focusables.add(this.removeColorButtonView),this.staticColorsGrid&&(this.focusTracker.add(this.staticColorsGrid.element),this._focusables.add(this.staticColorsGrid)),this.documentColorsGrid&&(this.focusTracker.add(this.documentColorsGrid.element),this._focusables.add(this.documentColorsGrid))}_createColorPickerButton(){this.colorPickerButtonView=new Em,this.colorPickerButtonView.set({label:this._colorPickerLabel,withText:!0,icon:qh.colorPalette,class:"ck-color-selector__color-picker"}),this.colorPickerButtonView.on("execute",(()=>{this.fire("colorPicker:show")}))}_createRemoveColorButton(){const e=new Em;return e.set({withText:!0,icon:qh.eraser,label:this._removeButtonLabel}),e.class="ck-color-selector__remove-color",e.on("execute",(()=>{this.fire("execute",{value:null,source:"removeColorButton"})})),e.render(),e}_createStaticColorsGrid(){const e=new Pp(this.locale,{colorDefinitions:this.colorDefinitions,columns:this.columns});return e.on("execute",((e,t)=>{this.fire("execute",{value:t.value,source:"staticColorsGrid"})})),e}_createDocumentColorsGrid(){const e=Wh.bind(this.documentColors,this.documentColors),t=new Pp(this.locale,{columns:this.columns});return t.extendTemplate({attributes:{class:e.if("isEmpty","ck-hidden")}}),t.items.bindTo(this.documentColors).using((e=>{const t=new Sp;return t.set({color:e.color,hasBorder:e.options&&e.options.hasBorder}),e.label&&t.set({label:e.label,tooltip:!0}),t.on("execute",(()=>{this.fire("execute",{value:e.color,source:"documentColorsGrid"})})),t})),this.documentColors.on("change:isEmpty",((e,o,n)=>{n&&(t.selectedColor=null)})),t}_addColorToDocumentColors(e){const t=this.colorDefinitions.find((t=>t.color===e));t?this.documentColors.add(Object.assign({},t)):this.documentColors.add({color:e,label:e,options:{hasBorder:!1}})}}class Af extends pm{constructor(e,{focusTracker:t,focusables:o,keystrokes:n,colorPickerViewConfig:i}){super(e),this.items=this.createCollection(),this.focusTracker=t,this.keystrokes=n,this.set("isVisible",!1),this.set("selectedColor",void 0),this._focusables=o,this._colorPickerViewConfig=i;const r=this.bindTemplate,{saveButtonView:s,cancelButtonView:a}=this._createActionButtons();this.saveButtonView=s,this.cancelButtonView=a,this.actionBarView=this._createActionBarView({saveButtonView:s,cancelButtonView:a}),this.setTemplate({tag:"div",attributes:{class:["ck-color-picker-fragment",r.if("isVisible","ck-hidden",(e=>!e))]},children:this.items})}render(){super.render();const e=new pf(this.locale,{...this._colorPickerViewConfig});this.colorPickerView=e,this.colorPickerView.render(),this.selectedColor&&(e.color=this.selectedColor),this.listenTo(this,"change:selectedColor",((t,o,n)=>{e.color=n})),this.items.add(this.colorPickerView),this.items.add(this.actionBarView),this._addColorPickersElementsToFocusTracker(),this._stopPropagationOnArrowsKeys(),this._executeOnEnterPress(),this._executeUponColorChange()}destroy(){super.destroy()}focus(){this.colorPickerView.focus()}resetValidationStatus(){this.colorPickerView.resetValidationStatus()}_executeOnEnterPress(){this.keystrokes.set("enter",(e=>{this.isVisible&&this.focusTracker.focusedElement!==this.cancelButtonView.element&&this.colorPickerView.isValid()&&(this.fire("execute",{value:this.selectedColor}),e.stopPropagation(),e.preventDefault())}))}_stopPropagationOnArrowsKeys(){const e=e=>e.stopPropagation();this.keystrokes.set("arrowright",e),this.keystrokes.set("arrowleft",e),this.keystrokes.set("arrowup",e),this.keystrokes.set("arrowdown",e)}_addColorPickersElementsToFocusTracker(){for(const e of this.colorPickerView.slidersView)this.focusTracker.add(e.element),this._focusables.add(e);const e=this.colorPickerView.hexInputRow.children.get(1);e.element&&(this.focusTracker.add(e.element),this._focusables.add(e)),this.focusTracker.add(this.saveButtonView.element),this._focusables.add(this.saveButtonView),this.focusTracker.add(this.cancelButtonView.element),this._focusables.add(this.cancelButtonView)}_createActionBarView({saveButtonView:e,cancelButtonView:t}){const o=new pm,n=this.createCollection();return n.add(e),n.add(t),o.setTemplate({tag:"div",attributes:{class:["ck","ck-color-selector_action-bar"]},children:n}),o}_createActionButtons(){const e=this.locale,t=e.t,o=new Em(e),n=new Em(e);return o.set({icon:qh.check,class:"ck-button-save",type:"button",withText:!1,label:t("Accept")}),n.set({icon:qh.cancel,class:"ck-button-cancel",type:"button",withText:!1,label:t("Cancel")}),o.on("execute",(()=>{this.colorPickerView.isValid()&&this.fire("execute",{source:"colorPickerSaveButton",value:this.selectedColor})})),n.on("execute",(()=>{this.fire("colorPicker:cancel")})),{saveButtonView:o,cancelButtonView:n}}_executeUponColorChange(){this.colorPickerView.on("colorSelected",((e,t)=>{this.fire("execute",{value:t.color,source:"colorPicker"}),this.set("selectedColor",t.color)}))}}var Cf=i(2922),vf={attributes:{"data-cke":!0}};vf.setAttributes=Ar(),vf.insert=_r().bind(null,"head"),vf.domAPI=kr(),vf.insertStyleElement=vr();fr()(Cf.A,vf);Cf.A&&Cf.A.locals&&Cf.A.locals;class xf extends pm{constructor(e,{colors:t,columns:o,removeButtonLabel:n,documentColorsLabel:i,documentColorsCount:r,colorPickerLabel:s,colorPickerViewConfig:a}){super(e),this.items=this.createCollection(),this.focusTracker=new Xi,this.keystrokes=new er,this._focusables=new Uh,this._colorPickerViewConfig=a,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.colorGridsFragmentView=new yf(e,{colors:t,columns:o,removeButtonLabel:n,documentColorsLabel:i,documentColorsCount:r,colorPickerLabel:s,focusTracker:this.focusTracker,focusables:this._focusables}),this.colorPickerFragmentView=new Af(e,{focusables:this._focusables,focusTracker:this.focusTracker,keystrokes:this.keystrokes,colorPickerViewConfig:a}),this.set("_isColorGridsFragmentVisible",!0),this.set("_isColorPickerFragmentVisible",!1),this.set("selectedColor",void 0),this.colorGridsFragmentView.bind("isVisible").to(this,"_isColorGridsFragmentVisible"),this.colorPickerFragmentView.bind("isVisible").to(this,"_isColorPickerFragmentVisible"),this.on("change:selectedColor",((e,t,o)=>{this.colorGridsFragmentView.set("selectedColor",o),this.colorPickerFragmentView.set("selectedColor",o)})),this.colorGridsFragmentView.on("change:selectedColor",((e,t,o)=>{this.set("selectedColor",o)})),this.colorPickerFragmentView.on("change:selectedColor",((e,t,o)=>{this.set("selectedColor",o)})),this.setTemplate({tag:"div",attributes:{class:["ck","ck-color-selector"]},children:this.items})}render(){super.render(),this.keystrokes.listenTo(this.element)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}appendUI(){this._appendColorGridsFragment(),this._colorPickerViewConfig&&this._appendColorPickerFragment()}showColorPickerFragment(){this.colorPickerFragmentView.colorPickerView&&!this._isColorPickerFragmentVisible&&(this._isColorPickerFragmentVisible=!0,this.colorPickerFragmentView.focus(),this.colorPickerFragmentView.resetValidationStatus(),this._isColorGridsFragmentVisible=!1)}showColorGridsFragment(){this._isColorGridsFragmentVisible||(this._isColorGridsFragmentVisible=!0,this.colorGridsFragmentView.focus(),this._isColorPickerFragmentVisible=!1)}focus(){this._focusCycler.focusFirst()}focusLast(){this._focusCycler.focusLast()}updateDocumentColors(e,t){this.colorGridsFragmentView.updateDocumentColors(e,t)}updateSelectedColors(){this.colorGridsFragmentView.updateSelectedColors()}_appendColorGridsFragment(){this.items.length||(this.items.add(this.colorGridsFragmentView),this.colorGridsFragmentView.delegate("execute").to(this),this.colorGridsFragmentView.delegate("colorPicker:show").to(this))}_appendColorPickerFragment(){2!==this.items.length&&(this.items.add(this.colorPickerFragmentView),this.colorGridsFragmentView.colorPickerButtonView&&this.colorGridsFragmentView.colorPickerButtonView.on("execute",(()=>{this.showColorPickerFragment()})),this.colorGridsFragmentView.addColorPickerButton(),this.colorPickerFragmentView.delegate("execute").to(this),this.colorPickerFragmentView.delegate("colorPicker:cancel").to(this))}}class Ef{constructor(e){this._components=new Map,this.editor=e}*names(){for(const e of this._components.values())yield e.originalName}add(e,t){this._components.set(Df(e),{callback:t,originalName:e})}create(e){if(!this.has(e))throw new E("componentfactory-item-missing",this,{name:e});return this._components.get(Df(e)).callback(this.editor.locale)}has(e){return this._components.has(Df(e))}}function Df(e){return String(e).toLowerCase()}var Bf=i(5615),Sf={attributes:{"data-cke":!0}};Sf.setAttributes=Ar(),Sf.insert=_r().bind(null,"head"),Sf.domAPI=kr(),Sf.insertStyleElement=vr();fr()(Bf.A,Sf);Bf.A&&Bf.A.locals&&Bf.A.locals;const Tf=Yn("px"),If={top:-99999,left:-99999,name:"arrowless",config:{withArrow:!1}};class Pf extends pm{constructor(e){super(e);const t=this.bindTemplate;this.set("top",0),this.set("left",0),this.set("position","arrow_nw"),this.set("isVisible",!1),this.set("withArrow",!0),this.set("class",void 0),this._pinWhenIsVisibleCallback=null,this._resizeObserver=null,this.content=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-balloon-panel",t.to("position",(e=>`ck-balloon-panel_${e}`)),t.if("isVisible","ck-balloon-panel_visible"),t.if("withArrow","ck-balloon-panel_with-arrow"),t.to("class")],style:{top:t.to("top",Tf),left:t.to("left",Tf)}},children:this.content})}destroy(){this.hide(),super.destroy()}show(){this.isVisible=!0}hide(){this.isVisible=!1}attachTo(e){const o=Mf(e.target);if(o&&!ti(o))return!1;this.show();const n=Pf.defaultPositions,i=Object.assign({},{element:this.element,positions:[n.southArrowNorth,n.southArrowNorthMiddleWest,n.southArrowNorthMiddleEast,n.southArrowNorthWest,n.southArrowNorthEast,n.northArrowSouth,n.northArrowSouthMiddleWest,n.northArrowSouthMiddleEast,n.northArrowSouthWest,n.northArrowSouthEast,n.viewportStickyNorth],limiter:t.document.body,fitInViewport:!0},e),r=Pf._getOptimalPosition(i)||If,s=parseInt(r.left),a=parseInt(r.top),l=r.name,c=r.config||{},{withArrow:d=!0}=c;return this.top=a,this.left=s,this.position=l,this.withArrow=d,!0}pin(e){this.unpin(),this._startPinning(e)&&(this._pinWhenIsVisibleCallback=()=>{this.isVisible?this._startPinning(e):this._stopPinning()},this.listenTo(this,"change:isVisible",this._pinWhenIsVisibleCallback))}unpin(){this._pinWhenIsVisibleCallback&&(this._stopPinning(),this.stopListening(this,"change:isVisible",this._pinWhenIsVisibleCallback),this._pinWhenIsVisibleCallback=null,this.hide())}_startPinning(e){if(!this.attachTo(e))return!1;const o=Mf(e.target),n=e.limiter?Mf(e.limiter):t.document.body;if(this.listenTo(t.document,"scroll",((t,i)=>{const r=i.target,s=o&&r.contains(o),a=n&&r.contains(n);!s&&!a&&o&&n||this.attachTo(e)}),{useCapture:!0}),this.listenTo(t.window,"resize",(()=>{this.attachTo(e)})),o&&!this._resizeObserver){const e=()=>{ti(o)||this.unpin()};this._resizeObserver=new Zn(o,e)}return!0}_stopPinning(){this.stopListening(t.document,"scroll"),this.stopListening(t.window,"resize"),this._resizeObserver&&(this._resizeObserver.destroy(),this._resizeObserver=null)}static generatePositions(e={}){const{sideOffset:t=Pf.arrowSideOffset,heightOffset:o=Pf.arrowHeightOffset,stickyVerticalOffset:n=Pf.stickyVerticalOffset,config:i}=e;return{northWestArrowSouthWest:(e,o)=>({top:r(e,o),left:e.left-t,name:"arrow_sw",...i&&{config:i}}),northWestArrowSouthMiddleWest:(e,o)=>({top:r(e,o),left:e.left-.25*o.width-t,name:"arrow_smw",...i&&{config:i}}),northWestArrowSouth:(e,t)=>({top:r(e,t),left:e.left-t.width/2,name:"arrow_s",...i&&{config:i}}),northWestArrowSouthMiddleEast:(e,o)=>({top:r(e,o),left:e.left-.75*o.width+t,name:"arrow_sme",...i&&{config:i}}),northWestArrowSouthEast:(e,o)=>({top:r(e,o),left:e.left-o.width+t,name:"arrow_se",...i&&{config:i}}),northArrowSouthWest:(e,o)=>({top:r(e,o),left:e.left+e.width/2-t,name:"arrow_sw",...i&&{config:i}}),northArrowSouthMiddleWest:(e,o)=>({top:r(e,o),left:e.left+e.width/2-.25*o.width-t,name:"arrow_smw",...i&&{config:i}}),northArrowSouth:(e,t)=>({top:r(e,t),left:e.left+e.width/2-t.width/2,name:"arrow_s",...i&&{config:i}}),northArrowSouthMiddleEast:(e,o)=>({top:r(e,o),left:e.left+e.width/2-.75*o.width+t,name:"arrow_sme",...i&&{config:i}}),northArrowSouthEast:(e,o)=>({top:r(e,o),left:e.left+e.width/2-o.width+t,name:"arrow_se",...i&&{config:i}}),northEastArrowSouthWest:(e,o)=>({top:r(e,o),left:e.right-t,name:"arrow_sw",...i&&{config:i}}),northEastArrowSouthMiddleWest:(e,o)=>({top:r(e,o),left:e.right-.25*o.width-t,name:"arrow_smw",...i&&{config:i}}),northEastArrowSouth:(e,t)=>({top:r(e,t),left:e.right-t.width/2,name:"arrow_s",...i&&{config:i}}),northEastArrowSouthMiddleEast:(e,o)=>({top:r(e,o),left:e.right-.75*o.width+t,name:"arrow_sme",...i&&{config:i}}),northEastArrowSouthEast:(e,o)=>({top:r(e,o),left:e.right-o.width+t,name:"arrow_se",...i&&{config:i}}),southWestArrowNorthWest:e=>({top:s(e),left:e.left-t,name:"arrow_nw",...i&&{config:i}}),southWestArrowNorthMiddleWest:(e,o)=>({top:s(e),left:e.left-.25*o.width-t,name:"arrow_nmw",...i&&{config:i}}),southWestArrowNorth:(e,t)=>({top:s(e),left:e.left-t.width/2,name:"arrow_n",...i&&{config:i}}),southWestArrowNorthMiddleEast:(e,o)=>({top:s(e),left:e.left-.75*o.width+t,name:"arrow_nme",...i&&{config:i}}),southWestArrowNorthEast:(e,o)=>({top:s(e),left:e.left-o.width+t,name:"arrow_ne",...i&&{config:i}}),southArrowNorthWest:e=>({top:s(e),left:e.left+e.width/2-t,name:"arrow_nw",...i&&{config:i}}),southArrowNorthMiddleWest:(e,o)=>({top:s(e),left:e.left+e.width/2-.25*o.width-t,name:"arrow_nmw",...i&&{config:i}}),southArrowNorth:(e,t)=>({top:s(e),left:e.left+e.width/2-t.width/2,name:"arrow_n",...i&&{config:i}}),southArrowNorthMiddleEast:(e,o)=>({top:s(e),left:e.left+e.width/2-.75*o.width+t,name:"arrow_nme",...i&&{config:i}}),southArrowNorthEast:(e,o)=>({top:s(e),left:e.left+e.width/2-o.width+t,name:"arrow_ne",...i&&{config:i}}),southEastArrowNorthWest:e=>({top:s(e),left:e.right-t,name:"arrow_nw",...i&&{config:i}}),southEastArrowNorthMiddleWest:(e,o)=>({top:s(e),left:e.right-.25*o.width-t,name:"arrow_nmw",...i&&{config:i}}),southEastArrowNorth:(e,t)=>({top:s(e),left:e.right-t.width/2,name:"arrow_n",...i&&{config:i}}),southEastArrowNorthMiddleEast:(e,o)=>({top:s(e),left:e.right-.75*o.width+t,name:"arrow_nme",...i&&{config:i}}),southEastArrowNorthEast:(e,o)=>({top:s(e),left:e.right-o.width+t,name:"arrow_ne",...i&&{config:i}}),westArrowEast:(e,t)=>({top:e.top+e.height/2-t.height/2,left:e.left-t.width-o,name:"arrow_e",...i&&{config:i}}),eastArrowWest:(e,t)=>({top:e.top+e.height/2-t.height/2,left:e.right+o,name:"arrow_w",...i&&{config:i}}),viewportStickyNorth:(e,t,o,r)=>{const s=r||o;return e.getIntersection(s)?s.height-e.height>n?null:{top:s.top+n,left:e.left+e.width/2-t.width/2,name:"arrowless",config:{withArrow:!1,...i}}:null}};function r(e,t){return e.top-t.height-o}function s(e){return e.bottom+o}}}Pf.arrowSideOffset=25,Pf.arrowHeightOffset=10,Pf.stickyVerticalOffset=20,Pf._getOptimalPosition=oi,Pf.defaultPositions=Pf.generatePositions();const Ff=Pf;function Mf(e){return Bn(e)?e:Ln(e)?e.commonAncestorContainer:"function"==typeof e?Mf(e()):null}var Rf=i(4650),zf={attributes:{"data-cke":!0}};zf.setAttributes=Ar(),zf.insert=_r().bind(null,"head"),zf.domAPI=kr(),zf.insertStyleElement=vr();fr()(Rf.A,zf);Rf.A&&Rf.A.locals&&Rf.A.locals;const Vf="ck-tooltip";class Of extends(Rn()){constructor(e){if(super(),this._currentElementWithTooltip=null,this._currentTooltipPosition=null,this._mutationObserver=null,Of._editors.add(e),Of._instance)return Of._instance;Of._instance=this,this.tooltipTextView=new pm(e.locale),this.tooltipTextView.set("text",""),this.tooltipTextView.setTemplate({tag:"span",attributes:{class:["ck","ck-tooltip__text"]},children:[{text:this.tooltipTextView.bindTemplate.to("text")}]}),this.balloonPanelView=new Ff(e.locale),this.balloonPanelView.class=Vf,this.balloonPanelView.content.add(this.tooltipTextView),this._mutationObserver=function(e){const t=new MutationObserver((()=>{e()}));return{attach(e){t.observe(e,{attributes:!0,attributeFilter:["data-cke-tooltip-text","data-cke-tooltip-position"]})},detach(){t.disconnect()}}}((()=>{this._updateTooltipPosition()})),this._pinTooltipDebounced=el(this._pinTooltip,600),this._unpinTooltipDebounced=el(this._unpinTooltip,400),this.listenTo(t.document,"keydown",this._onKeyDown.bind(this),{useCapture:!0}),this.listenTo(t.document,"mouseenter",this._onEnterOrFocus.bind(this),{useCapture:!0}),this.listenTo(t.document,"mouseleave",this._onLeaveOrBlur.bind(this),{useCapture:!0}),this.listenTo(t.document,"focus",this._onEnterOrFocus.bind(this),{useCapture:!0}),this.listenTo(t.document,"blur",this._onLeaveOrBlur.bind(this),{useCapture:!0}),this.listenTo(t.document,"scroll",this._onScroll.bind(this),{useCapture:!0}),this._watchdogExcluded=!0}destroy(e){const t=e.ui.view&&e.ui.view.body;Of._editors.delete(e),this.stopListening(e.ui),t&&t.has(this.balloonPanelView)&&t.remove(this.balloonPanelView),Of._editors.size||(this._unpinTooltip(),this.balloonPanelView.destroy(),this.stopListening(),Of._instance=null)}static getPositioningFunctions(e){const t=Of.defaultBalloonPositions;return{s:[t.southArrowNorth,t.southArrowNorthEast,t.southArrowNorthWest],n:[t.northArrowSouth],e:[t.eastArrowWest],w:[t.westArrowEast],sw:[t.southArrowNorthEast],se:[t.southArrowNorthWest]}[e]}_onKeyDown(e,t){"Escape"===t.key&&this._currentElementWithTooltip&&(this._unpinTooltip(),t.stopPropagation())}_onEnterOrFocus(e,{target:t}){const o=Lf(t);o?o!==this._currentElementWithTooltip&&(this._unpinTooltip(),"focus"!==e.name||o.matches(":hover")?this._pinTooltipDebounced(o,Hf(o)):this._pinTooltip(o,Hf(o))):"focus"===e.name&&this._unpinTooltip()}_onLeaveOrBlur(e,{target:t,relatedTarget:o}){if("mouseleave"===e.name){if(!Bn(t))return;const e=this.balloonPanelView.element,n=e&&(e===o||e.contains(o)),i=!n&&t===e;if(n)return void this._unpinTooltipDebounced.cancel();if(!i&&this._currentElementWithTooltip&&t!==this._currentElementWithTooltip)return;const r=Lf(t),s=Lf(o);(i||r&&r!==s)&&this._unpinTooltipDebounced()}else{if(this._currentElementWithTooltip&&t!==this._currentElementWithTooltip)return;this._unpinTooltipDebounced()}}_onScroll(e,{target:t}){this._currentElementWithTooltip&&(t.contains(this.balloonPanelView.element)&&t.contains(this._currentElementWithTooltip)||this._unpinTooltip())}_pinTooltip(e,{text:t,position:o,cssClass:n}){this._unpinTooltip();const i=Qi(Of._editors.values()).ui.view.body;i.has(this.balloonPanelView)||i.add(this.balloonPanelView),this.tooltipTextView.text=t,this.balloonPanelView.class=[Vf,n].filter((e=>e)).join(" "),this.balloonPanelView.pin({target:e,positions:Of.getPositioningFunctions(o)}),this._mutationObserver.attach(e);for(const e of Of._editors)this.listenTo(e.ui,"update",this._updateTooltipPosition.bind(this),{priority:"low"});this._currentElementWithTooltip=e,this._currentTooltipPosition=o}_unpinTooltip(){this._unpinTooltipDebounced.cancel(),this._pinTooltipDebounced.cancel(),this.balloonPanelView.unpin();for(const e of Of._editors)this.stopListening(e.ui,"update");this._currentElementWithTooltip=null,this._currentTooltipPosition=null,this.tooltipTextView.text="",this._mutationObserver.detach()}_updateTooltipPosition(){if(!this._currentElementWithTooltip)return;const e=Hf(this._currentElementWithTooltip);ti(this._currentElementWithTooltip)&&e.text?this.balloonPanelView.pin({target:this._currentElementWithTooltip,positions:Of.getPositioningFunctions(e.position)}):this._unpinTooltip()}}Of.defaultBalloonPositions=Ff.generatePositions({heightOffset:5,sideOffset:13}),Of._editors=new Set,Of._instance=null;const Nf=Of;function Lf(e){return Bn(e)?e.closest("[data-cke-tooltip-text]:not([data-cke-tooltip-disabled])"):null}function Hf(e){return{text:e.dataset.ckeTooltipText,position:e.dataset.ckeTooltipPosition||"s",cssClass:e.dataset.ckeTooltipClass||""}}const jf=50,qf=350,Uf="Powered by";class Wf extends(Rn()){constructor(e){super(),this.editor=e,this._balloonView=null,this._lastFocusedEditableElement=null,this._showBalloonThrottled=Bh(this._showBalloon.bind(this),50,{leading:!0}),e.on("ready",this._handleEditorReady.bind(this))}destroy(){const e=this._balloonView;e&&(e.unpin(),this._balloonView=null),this._showBalloonThrottled.cancel(),this.stopListening()}_handleEditorReady(){const e=this.editor;(!!e.config.get("ui.poweredBy.forceVisible")||"VALID"!==function(e){function t(e){return e.length>=40&&e.length<=255?"VALID":"INVALID"}if(!e)return"INVALID";let o="";try{o=atob(e)}catch(e){return"INVALID"}const n=o.split("-"),i=n[0],r=n[1];if(!r)return t(e);try{atob(r)}catch(o){try{if(atob(i),!atob(i).length)return t(e)}catch(o){return t(e)}}if(i.length<40||i.length>255)return"INVALID";let s="";try{atob(i),s=atob(r)}catch(e){return"INVALID"}if(8!==s.length)return"INVALID";const a=Number(s.substring(0,4)),l=Number(s.substring(4,6))-1,c=Number(s.substring(6,8)),d=new Date(a,l,c);return d{this._updateLastFocusedEditableElement(),o?this._showBalloon():this._hideBalloon()})),e.ui.focusTracker.on("change:focusedElement",((e,t,o)=>{this._updateLastFocusedEditableElement(),o&&this._showBalloon()})),e.ui.on("update",(()=>{this._showBalloonThrottled()})))}_createBalloonView(){const e=this.editor,t=this._balloonView=new Ff,o=Kf(e),n=new $f(e.locale,o.label);t.content.add(n),t.set({class:"ck-powered-by-balloon"}),e.ui.view.body.add(t),e.ui.focusTracker.add(t.element),this._balloonView=t}_showBalloon(){if(!this._lastFocusedEditableElement)return;const e=function(e,t){const o=Kf(e),n="right"===o.side?function(e,t){return Gf(e,t,((e,o)=>e.left+e.width-o.width-t.horizontalOffset))}(t,o):function(e,t){return Gf(e,t,(e=>e.left+t.horizontalOffset))}(t,o);return{target:t,positions:[n]}}(this.editor,this._lastFocusedEditableElement);e&&(this._balloonView||this._createBalloonView(),this._balloonView.pin(e))}_hideBalloon(){this._balloonView&&this._balloonView.unpin()}_updateLastFocusedEditableElement(){const e=this.editor,t=e.ui.focusTracker.isFocused,o=e.ui.focusTracker.focusedElement;if(!t||!o)return void(this._lastFocusedEditableElement=null);const n=Array.from(e.ui.getEditableElementsNames()).map((t=>e.ui.getEditableElement(t)));n.includes(o)?this._lastFocusedEditableElement=o:this._lastFocusedEditableElement=n[0]}}class $f extends pm{constructor(e,t){super(e);const o=new Am,n=this.bindTemplate;o.set({content:'\n',isColorInherited:!1}),o.extendTemplate({attributes:{style:{width:"53px",height:"10px"}}}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-powered-by"],"aria-hidden":!0},children:[{tag:"a",attributes:{href:"https://ckeditor.com/?utm_source=ckeditor&utm_medium=referral&utm_campaign=701Dn000000hVgmIAE_powered_by_ckeditor_logo",target:"_blank",tabindex:"-1"},children:[...t?[{tag:"span",attributes:{class:["ck","ck-powered-by__label"]},children:[t]}]:[],o],on:{dragstart:n.to((e=>e.preventDefault()))}}]})}}function Gf(e,t,o){return(n,i)=>{const r=new qn(e);if(r.width{for(const e of Object.values(Yf))this.announce("",e)}))}announce(e,t=Yf.POLITE){const o=this.editor;if(!o.ui.view)return;this.view||(this.view=new Xf(o.locale),o.ui.view.body.add(this.view));const{politeness:n,isUnsafeHTML:i}="string"==typeof t?{politeness:t}:t;let r=this.view.regionViews.find((e=>e.politeness===n));r||(r=new eb(o,n),this.view.regionViews.add(r)),r.announce({announcement:e,isUnsafeHTML:i})}}class Xf extends pm{constructor(e){super(e),this.regionViews=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-aria-live-announcer"]},children:this.regionViews})}}class eb extends pm{constructor(e,t){super(e.locale),this.setTemplate({tag:"div",attributes:{"aria-live":t,"aria-relevant":"additions"},children:[{tag:"ul",attributes:{class:["ck","ck-aria-live-region-list"]}}]}),e.on("destroy",(()=>{null!==this._pruneAnnouncementsInterval&&(clearInterval(this._pruneAnnouncementsInterval),this._pruneAnnouncementsInterval=null)})),this.politeness=t,this._domConverter=e.data.htmlProcessor.domConverter,this._pruneAnnouncementsInterval=setInterval((()=>{this.element&&this._listElement.firstChild&&this._listElement.firstChild.remove()}),5e3)}announce({announcement:e,isUnsafeHTML:t}){if(!e.trim().length)return;const o=document.createElement("li");t?this._domConverter.setContentOf(o,e):o.innerText=e,this._listElement.appendChild(o)}get _listElement(){return this.element.querySelector("ul")}}var tb=i(1214),ob={attributes:{"data-cke":!0}};ob.setAttributes=Ar(),ob.insert=_r().bind(null,"head"),ob.domAPI=kr(),ob.insertStyleElement=vr();fr()(tb.A,ob);tb.A&&tb.A.locals&&tb.A.locals;class nb extends mg{constructor(e,t){super(e);const o=this.bindTemplate;this.extendTemplate({attributes:{class:["ck-menu-bar__menu__item"]},on:{mouseenter:o.to("mouseenter")}}),this.delegate("mouseenter").to(t)}}const ib={toggleMenusAndFocusItemsOnHover(e){e.on("menu:mouseenter",(t=>{if(e.isFocusBorderEnabled||e.isOpen){if(e.isOpen)for(const o of e.menus){const e=t.path[0],n=e instanceof nb&&e.children.first===o;o.isOpen=(t.path.includes(o)||n)&&o.isEnabled}t.source.focus()}}))},focusCycleMenusOnArrows(e){const t="rtl"===e.locale.uiLanguageDirection;function o(t,o){const n=e.children.getIndex(t),i=t.isOpen,r=e.children.length,s=e.children.get((n+r+o)%r);t.isOpen=!1,i&&(s.isOpen=!0),s.buttonView.focus()}e.on("menu:arrowright",(e=>{o(e.source,t?-1:1)})),e.on("menu:arrowleft",(e=>{o(e.source,t?1:-1)}))},closeMenusWhenTheBarCloses(e){e.on("change:isOpen",(()=>{e.isOpen||e.menus.forEach((e=>{e.isOpen=!1}))}))},closeMenuWhenAnotherOnTheSameLevelOpens(e){e.on("menu:change:isOpen",((t,o,n)=>{n&&e.menus.filter((e=>t.source.parentMenuView===e.parentMenuView&&t.source!==e&&e.isOpen)).forEach((e=>{e.isOpen=!1}))}))},closeOnClickOutside(e){gm({emitter:e,activator:()=>e.isOpen,callback:()=>e.close(),contextElements:()=>e.children.map((e=>e.element))})},enableFocusHighlightOnInteraction(e){let t=!1;e.on("change:isOpen",((o,n,i)=>{i||(e.isFocusBorderEnabled=!1,t=!1)})),e.listenTo(e.element,"click",(()=>{e.isOpen&&e.element.matches(":focus-within")&&(e.isFocusBorderEnabled=!0)}),{useCapture:!0}),e.listenTo(e.element,"keydown",(()=>{t=!0}),{useCapture:!0}),e.listenTo(e.element,"keyup",(()=>{t=!1}),{useCapture:!0}),e.listenTo(e.element,"focus",(()=>{t&&(e.isFocusBorderEnabled=!0)}),{useCapture:!0})}},rb={openAndFocusPanelOnArrowDownKey(e){e.keystrokes.set("arrowdown",((t,o)=>{e.focusTracker.focusedElement===e.buttonView.element&&(e.isOpen||(e.isOpen=!0),e.panelView.focus(),o())}))},openOnArrowRightKey(e){const t="rtl"===e.locale.uiLanguageDirection?"arrowleft":"arrowright";e.keystrokes.set(t,((t,o)=>{e.focusTracker.focusedElement===e.buttonView.element&&e.isEnabled&&(e.isOpen||(e.isOpen=!0),e.panelView.focus(),o())}))},openOnButtonClick(e){e.buttonView.on("execute",(()=>{e.isOpen=!0,e.parentMenuView&&e.panelView.focus()}))},toggleOnButtonClick(e){e.buttonView.on("execute",(()=>{e.isOpen=!e.isOpen}))},closeOnArrowLeftKey(e){const t="rtl"===e.locale.uiLanguageDirection?"arrowright":"arrowleft";e.keystrokes.set(t,((t,o)=>{e.isOpen&&(e.isOpen=!1,e.focus(),o())}))},closeOnEscKey(e){e.keystrokes.set("esc",((t,o)=>{e.isOpen&&(e.isOpen=!1,e.focus(),o())}))},closeOnParentClose(e){e.parentMenuView.on("change:isOpen",((t,o,n)=>{n||t.source!==e.parentMenuView||(e.isOpen=!1)}))}},sb={southEast:e=>({top:e.bottom,left:e.left,name:"se"}),southWest:(e,t)=>({top:e.bottom,left:e.left-t.width+e.width,name:"sw"}),northEast:(e,t)=>({top:e.top-t.height,left:e.left,name:"ne"}),northWest:(e,t)=>({top:e.top-t.height,left:e.left-t.width+e.width,name:"nw"}),eastSouth:e=>({top:e.top,left:e.right-5,name:"es"}),eastNorth:(e,t)=>({top:e.top-t.height,left:e.right-5,name:"en"}),westSouth:(e,t)=>({top:e.top,left:e.left-t.width+5,name:"ws"}),westNorth:(e,t)=>({top:e.top-t.height,left:e.left-t.width+5,name:"wn"})},ab=[{menuId:"file",label:"File",groups:[{groupId:"export",items:["menuBar:exportPdf","menuBar:exportWord"]},{groupId:"import",items:["menuBar:importWord"]},{groupId:"revisionHistory",items:["menuBar:revisionHistory"]}]},{menuId:"edit",label:"Edit",groups:[{groupId:"undo",items:["menuBar:undo","menuBar:redo"]},{groupId:"selectAll",items:["menuBar:selectAll"]},{groupId:"findAndReplace",items:["menuBar:findAndReplace"]}]},{menuId:"view",label:"View",groups:[{groupId:"sourceEditing",items:["menuBar:sourceEditing"]},{groupId:"showBlocks",items:["menuBar:showBlocks"]},{groupId:"previewMergeFields",items:["menuBar:previewMergeFields"]},{groupId:"restrictedEditing",items:["menuBar:restrictedEditing"]}]},{menuId:"insert",label:"Insert",groups:[{groupId:"insertMainWidgets",items:["menuBar:insertImage","menuBar:ckbox","menuBar:ckfinder","menuBar:insertTable"]},{groupId:"insertInline",items:["menuBar:link","menuBar:comment","menuBar:insertMergeField"]},{groupId:"insertMinorWidgets",items:["menuBar:mediaEmbed","menuBar:insertTemplate","menuBar:specialCharacters","menuBar:blockQuote","menuBar:codeBlock","menuBar:htmlEmbed"]},{groupId:"insertStructureWidgets",items:["menuBar:horizontalLine","menuBar:pageBreak","menuBar:tableOfContents"]},{groupId:"restrictedEditingException",items:["menuBar:restrictedEditingException"]}]},{menuId:"format",label:"Format",groups:[{groupId:"textAndFont",items:[{menuId:"text",label:"Text",groups:[{groupId:"basicStyles",items:["menuBar:bold","menuBar:italic","menuBar:underline","menuBar:strikethrough","menuBar:superscript","menuBar:subscript","menuBar:code"]},{groupId:"textPartLanguage",items:["menuBar:textPartLanguage"]}]},{menuId:"font",label:"Font",groups:[{groupId:"fontProperties",items:["menuBar:fontSize","menuBar:fontFamily"]},{groupId:"fontColors",items:["menuBar:fontColor","menuBar:fontBackgroundColor"]},{groupId:"highlight",items:["menuBar:highlight"]}]},"menuBar:heading"]},{groupId:"list",items:["menuBar:bulletedList","menuBar:numberedList","menuBar:multiLevelList","menuBar:todoList"]},{groupId:"indent",items:["menuBar:alignment","menuBar:indent","menuBar:outdent"]},{groupId:"caseChange",items:["menuBar:caseChange"]},{groupId:"removeFormat",items:["menuBar:removeFormat"]}]},{menuId:"tools",label:"Tools",groups:[{groupId:"aiTools",items:["menuBar:aiAssistant","menuBar:aiCommands"]},{groupId:"tools",items:["menuBar:trackChanges","menuBar:commentsArchive"]}]},{menuId:"help",label:"Help",groups:[{groupId:"help",items:["menuBar:accessibilityHelp"]}]}];function lb({normalizedConfig:e,locale:t,componentFactory:o,extraItems:n}){const i=Fl(e);return cb(e,i,n),function(e,t){const o=t.removeItems,n=[];t.items=t.items.filter((({menuId:e})=>!o.includes(e)||(n.push(e),!1))),mb(t.items,(e=>{e.groups=e.groups.filter((({groupId:e})=>!o.includes(e)||(n.push(e),!1)));for(const t of e.groups)t.items=t.items.filter((e=>{const t=bb(e);return!o.includes(t)||(n.push(t),!1)}))}));for(const t of o)n.includes(t)||D("menu-bar-item-could-not-be-removed",{menuBarConfig:e,itemName:t})}(e,i),cb(e,i,i.addItems),function(e,t,o){mb(t.items,(n=>{for(const i of n.groups)i.items=i.items.filter((i=>{const r="string"==typeof i&&!o.has(i);return r&&!t.isUsingDefaultConfig&&D("menu-bar-item-unavailable",{menuBarConfig:e,parentMenuConfig:Fl(n),componentName:i}),!r}))}))}(e,i,o),ub(e,i),function(e,t){const o=t.t,n={File:o({string:"File",id:"MENU_BAR_MENU_FILE"}),Edit:o({string:"Edit",id:"MENU_BAR_MENU_EDIT"}),View:o({string:"View",id:"MENU_BAR_MENU_VIEW"}),Insert:o({string:"Insert",id:"MENU_BAR_MENU_INSERT"}),Format:o({string:"Format",id:"MENU_BAR_MENU_FORMAT"}),Tools:o({string:"Tools",id:"MENU_BAR_MENU_TOOLS"}),Help:o({string:"Help",id:"MENU_BAR_MENU_HELP"}),Text:o({string:"Text",id:"MENU_BAR_MENU_TEXT"}),Font:o({string:"Font",id:"MENU_BAR_MENU_FONT"})};mb(e.items,(e=>{e.label in n&&(e.label=n[e.label])}))}(i,t),i}function cb(e,t,o){const n=[];if(0!=o.length){for(const e of o){const o=gb(e.position),r=fb(e.position);if("object"==typeof(i=e)&&"menu"in i)if(r){const i=t.items.findIndex((e=>e.menuId===r));if(-1!=i)"before"===o?(t.items.splice(i,0,e.menu),n.push(e)):"after"===o&&(t.items.splice(i+1,0,e.menu),n.push(e));else{db(t,e.menu,r,o)&&n.push(e)}}else"start"===o?(t.items.unshift(e.menu),n.push(e)):"end"===o&&(t.items.push(e.menu),n.push(e));else if(pb(e))mb(t.items,(t=>{if(t.menuId===r)"start"===o?(t.groups.unshift(e.group),n.push(e)):"end"===o&&(t.groups.push(e.group),n.push(e));else{const i=t.groups.findIndex((e=>e.groupId===r));-1!==i&&("before"===o?(t.groups.splice(i,0,e.group),n.push(e)):"after"===o&&(t.groups.splice(i+1,0,e.group),n.push(e)))}}));else{db(t,e.item,r,o)&&n.push(e)}}var i;for(const t of o)n.includes(t)||D("menu-bar-item-could-not-be-added",{menuBarConfig:e,addedItemConfig:t})}}function db(e,t,o,n){let i=!1;return mb(e.items,(e=>{for(const{groupId:r,items:s}of e.groups){if(i)return;if(r===o)"start"===n?(s.unshift(t),i=!0):"end"===n&&(s.push(t),i=!0);else{const e=s.findIndex((e=>bb(e)===o));-1!==e&&("before"===n?(s.splice(e,0,t),i=!0):"after"===n&&(s.splice(e+1,0,t),i=!0))}}})),i}function ub(e,t){const o=t.isUsingDefaultConfig;let n=!1;t.items=t.items.filter((t=>!!t.groups.length||(hb(e,t,o),!1))),t.items.length?(mb(t.items,(t=>{t.groups=t.groups.filter((e=>!!e.items.length||(n=!0,!1)));for(const i of t.groups)i.items=i.items.filter((t=>!(kb(t)&&!t.groups.length)||(hb(e,t,o),n=!0,!1)))})),n&&ub(e,t)):hb(e,e,o)}function hb(e,t,o){o||D("menu-bar-menu-empty",{menuBarConfig:e,emptyMenuConfig:t})}function mb(e,t){if(Array.isArray(e))for(const t of e)o(t);function o(e){t(e);for(const t of e.groups)for(const e of t.items)kb(e)&&o(e)}}function pb(e){return"object"==typeof e&&"group"in e}function gb(e){return e.startsWith("start")?"start":e.startsWith("end")?"end":e.startsWith("after")?"after":"before"}function fb(e){const t=e.match(/^[^:]+:(.+)/);return t?t[1]:null}function bb(e){return"string"==typeof e?e:e.menuId}function kb(e){return"object"==typeof e&&"menuId"in e}class wb extends(Y()){constructor(e){super(),this.isReady=!1,this._editableElementsMap=new Map,this._focusableToolbarDefinitions=[],this._extraMenuBarElements=[],this._lastFocusedForeignElement=null;const t=e.editing.view;this.editor=e,this.componentFactory=new Ef(e),this.focusTracker=new Xi,this.tooltipManager=new Nf(e),this.poweredBy=new Wf(e),this.ariaLiveAnnouncer=new Qf(e),this.set("viewportOffset",this._readViewportOffsetFromConfig()),this.once("ready",(()=>{this.isReady=!0})),this.listenTo(t.document,"layoutChanged",this.update.bind(this)),this.listenTo(t,"scrollToTheSelection",this._handleScrollToTheSelection.bind(this)),this._initFocusTracking()}get element(){return null}update(){this.fire("update")}destroy(){this.stopListening(),this.focusTracker.destroy(),this.tooltipManager.destroy(this.editor),this.poweredBy.destroy();for(const e of this._editableElementsMap.values())e.ckeditorInstance=null,this.editor.keystrokes.stopListening(e);this._editableElementsMap=new Map,this._focusableToolbarDefinitions=[]}setEditableElement(e,t){this._editableElementsMap.set(e,t),t.ckeditorInstance||(t.ckeditorInstance=this.editor),this.focusTracker.add(t);const o=()=>{this.editor.editing.view.getDomRoot(e)||this.editor.keystrokes.listenTo(t)};this.isReady?o():this.once("ready",o)}removeEditableElement(e){const t=this._editableElementsMap.get(e);t&&(this._editableElementsMap.delete(e),this.editor.keystrokes.stopListening(t),this.focusTracker.remove(t),t.ckeditorInstance=null)}getEditableElement(e="main"){return this._editableElementsMap.get(e)}getEditableElementsNames(){return this._editableElementsMap.keys()}addToolbar(e,t={}){e.isRendered?(this.focusTracker.add(e.element),this.editor.keystrokes.listenTo(e.element)):e.once("render",(()=>{this.focusTracker.add(e.element),this.editor.keystrokes.listenTo(e.element)})),this._focusableToolbarDefinitions.push({toolbarView:e,options:t})}extendMenuBar(e){this._extraMenuBarElements.push(e)}get _editableElements(){return console.warn("editor-ui-deprecated-editable-elements: The EditorUI#_editableElements property has been deprecated and will be removed in the near future.",{editorUI:this}),this._editableElementsMap}_initMenuBar(e){const t=e.element;this.focusTracker.add(t),this.editor.keystrokes.listenTo(t);const o=function(e){let t;return t="items"in e&&e.items?{items:e.items,removeItems:[],addItems:[],isVisible:!0,isUsingDefaultConfig:!1,...e}:{items:Fl(ab),addItems:[],removeItems:[],isVisible:!0,isUsingDefaultConfig:!0,...e},t}(this.editor.config.get("menuBar")||{});e.fillFromConfig(o,this.componentFactory,this._extraMenuBarElements),this.editor.keystrokes.set("Esc",((e,o)=>{t.contains(this.editor.ui.focusTracker.focusedElement)&&(this._lastFocusedForeignElement?(this._lastFocusedForeignElement.focus(),this._lastFocusedForeignElement=null):this.editor.editing.view.focus(),o())})),this.editor.keystrokes.set("Alt+F9",((o,n)=>{t.contains(this.editor.ui.focusTracker.focusedElement)||(this._saveLastFocusedForeignElement(),e.isFocusBorderEnabled=!0,e.focus(),n())}))}_readViewportOffsetFromConfig(){const e=this.editor,t=e.config.get("ui.viewportOffset");if(t)return t;const o=e.config.get("toolbar.viewportTopOffset");return o?(console.warn("editor-ui-deprecated-viewport-offset-config: The `toolbar.vieportTopOffset` configuration option is deprecated. It will be removed from future CKEditor versions. Use `ui.viewportOffset.top` instead."),{top:o}):{top:0}}_initFocusTracking(){const e=this.editor;e.editing.view;let t;e.keystrokes.set("Alt+F10",((e,o)=>{this._saveLastFocusedForeignElement();const n=this._getCurrentFocusedToolbarDefinition();n&&t||(t=this._getFocusableCandidateToolbarDefinitions());for(let e=0;e{const n=this._getCurrentFocusedToolbarDefinition();n&&(this._lastFocusedForeignElement?(this._lastFocusedForeignElement.focus(),this._lastFocusedForeignElement=null):e.editing.view.focus(),n.options.afterBlur&&n.options.afterBlur(),o())}))}_saveLastFocusedForeignElement(){const e=this.focusTracker.focusedElement;Array.from(this._editableElementsMap.values()).includes(e)&&!Array.from(this.editor.editing.view.domRoots.values()).includes(e)&&(this._lastFocusedForeignElement=e)}_getFocusableCandidateToolbarDefinitions(){const e=[];for(const t of this._focusableToolbarDefinitions){const{toolbarView:o,options:n}=t;(ti(o.element)||n.beforeFocus)&&e.push(t)}return e.sort(((e,t)=>_b(e)-_b(t))),e}_getCurrentFocusedToolbarDefinition(){for(const e of this._focusableToolbarDefinitions)if(e.toolbarView.element&&e.toolbarView.element.contains(this.focusTracker.focusedElement))return e;return null}_focusFocusableCandidateToolbar(e){const{toolbarView:t,options:{beforeFocus:o}}=e;return o&&o(),!!ti(t.element)&&(t.focus(),!0)}_handleScrollToTheSelection(e,t){const o={top:0,bottom:0,left:0,right:0,...this.viewportOffset};t.viewportOffset.top+=o.top,t.viewportOffset.bottom+=o.bottom,t.viewportOffset.left+=o.left,t.viewportOffset.right+=o.right}}function _b(e){const{toolbarView:t,options:o}=e;let n=10;return ti(t.element)&&n--,o.isContextual&&n--,n}var yb=i(178),Ab={attributes:{"data-cke":!0}};Ab.setAttributes=Ar(),Ab.insert=_r().bind(null,"head"),Ab.domAPI=kr(),Ab.insertStyleElement=vr();fr()(yb.A,Ab);yb.A&&yb.A.locals&&yb.A.locals;class Cb extends pm{constructor(e){super(e),this.body=new pp(e)}render(){super.render(),this.body.attachToDom()}destroy(){return this.body.detachFromDom(),super.destroy()}}class vb extends pm{constructor(e,t,o){super(e),this.name=null,this.setTemplate({tag:"div",attributes:{class:["ck","ck-content","ck-editor__editable","ck-rounded-corners"],lang:e.contentLanguage,dir:e.contentLanguageDirection}}),this.set("isFocused",!1),this._editableElement=o,this._hasExternalElement=!!this._editableElement,this._editingView=t}render(){super.render(),this._hasExternalElement?this.template.apply(this.element=this._editableElement):this._editableElement=this.element,this.on("change:isFocused",(()=>this._updateIsFocusedClasses())),this._updateIsFocusedClasses()}destroy(){this._hasExternalElement&&this.template.revert(this._editableElement),super.destroy()}get hasExternalElement(){return this._hasExternalElement}_updateIsFocusedClasses(){const e=this._editingView;function t(t){e.change((o=>{const n=e.document.getRoot(t.name);o.addClass(t.isFocused?"ck-focused":"ck-blurred",n),o.removeClass(t.isFocused?"ck-blurred":"ck-focused",n)}))}e.isRenderingInProgress?function o(n){e.once("change:isRenderingInProgress",((e,i,r)=>{r?o(n):t(n)}))}(this):t(this)}}class xb extends vb{constructor(e,t,o,n={}){super(e,t,o);const i=e.t;this.extendTemplate({attributes:{role:"textbox",class:"ck-editor__editable_inline"}}),this._generateLabel=n.label||(()=>i("Editor editing area: %0",this.name))}render(){super.render();const e=this._editingView;e.change((t=>{const o=e.document.getRoot(this.name);t.setAttribute("aria-label",this._generateLabel(this),o)}))}}class Eb extends pr{static get pluginName(){return"Notification"}init(){this.on("show:warning",((e,t)=>{window.alert(t.message)}),{priority:"lowest"})}showSuccess(e,t={}){this._showNotification({message:e,type:"success",namespace:t.namespace,title:t.title})}showInfo(e,t={}){this._showNotification({message:e,type:"info",namespace:t.namespace,title:t.title})}showWarning(e,t={}){this._showNotification({message:e,type:"warning",namespace:t.namespace,title:t.title})}_showNotification(e){const t=e.namespace?`show:${e.type}:${e.namespace}`:`show:${e.type}`;this.fire(t,{message:e.message,type:e.type,title:e.title||""})}}class Db extends(Y()){constructor(e,t){super(),t&&Oa(this,t),e&&this.set(e)}}var Bb=i(9938),Sb={attributes:{"data-cke":!0}};Sb.setAttributes=Ar(),Sb.insert=_r().bind(null,"head"),Sb.domAPI=kr(),Sb.insertStyleElement=vr();fr()(Bb.A,Sb);Bb.A&&Bb.A.locals&&Bb.A.locals;var Tb=i(3579),Ib={attributes:{"data-cke":!0}};Ib.setAttributes=Ar(),Ib.insert=_r().bind(null,"head"),Ib.domAPI=kr(),Ib.insertStyleElement=vr();fr()(Tb.A,Ib);Tb.A&&Tb.A.locals&&Tb.A.locals;const Pb=Yn("px");class Fb extends lr{static get pluginName(){return"ContextualBalloon"}constructor(e){super(e),this._viewToStack=new Map,this._idToStack=new Map,this._view=null,this._rotatorView=null,this._fakePanelsView=null,this.positionLimiter=()=>{const e=this.editor.editing.view,t=e.document.selection.editableElement;return t?e.domConverter.mapViewToDom(t.root):null},this.set("visibleView",null),this.set("_numberOfStacks",0),this.set("_singleViewMode",!1)}destroy(){super.destroy(),this._view&&this._view.destroy(),this._rotatorView&&this._rotatorView.destroy(),this._fakePanelsView&&this._fakePanelsView.destroy()}get view(){return this._view||this._createPanelView(),this._view}hasView(e){return Array.from(this._viewToStack.keys()).includes(e)}add(e){if(this._view||this._createPanelView(),this.hasView(e.view))throw new E("contextualballoon-add-view-exist",[this,e]);const t=e.stackId||"main";if(!this._idToStack.has(t))return this._idToStack.set(t,new Map([[e.view,e]])),this._viewToStack.set(e.view,this._idToStack.get(t)),this._numberOfStacks=this._idToStack.size,void(this._visibleStack&&!e.singleViewMode||this.showStack(t));const o=this._idToStack.get(t);e.singleViewMode&&this.showStack(t),o.set(e.view,e),this._viewToStack.set(e.view,o),o===this._visibleStack&&this._showView(e)}remove(e){if(!this.hasView(e))throw new E("contextualballoon-remove-view-not-exist",[this,e]);const t=this._viewToStack.get(e);this._singleViewMode&&this.visibleView===e&&(this._singleViewMode=!1),this.visibleView===e&&(1===t.size?this._idToStack.size>1?this._showNextStack():(this.view.hide(),this.visibleView=null,this._rotatorView.hideView()):this._showView(Array.from(t.values())[t.size-2])),1===t.size?(this._idToStack.delete(this._getStackId(t)),this._numberOfStacks=this._idToStack.size):t.delete(e),this._viewToStack.delete(e)}updatePosition(e){e&&(this._visibleStack.get(this.visibleView).position=e),this.view.pin(this._getBalloonPosition()),this._fakePanelsView.updatePosition()}showStack(e){this.visibleStack=e;const t=this._idToStack.get(e);if(!t)throw new E("contextualballoon-showstack-stack-not-exist",this);this._visibleStack!==t&&this._showView(Array.from(t.values()).pop())}_createPanelView(){this._view=new Ff(this.editor.locale),this.editor.ui.view.body.add(this._view),this.editor.ui.focusTracker.add(this._view.element),this._rotatorView=this._createRotatorView(),this._fakePanelsView=this._createFakePanelsView()}get _visibleStack(){return this._viewToStack.get(this.visibleView)}_getStackId(e){return Array.from(this._idToStack.entries()).find((t=>t[1]===e))[0]}_showNextStack(){const e=Array.from(this._idToStack.values());let t=e.indexOf(this._visibleStack)+1;e[t]||(t=0),this.showStack(this._getStackId(e[t]))}_showPrevStack(){const e=Array.from(this._idToStack.values());let t=e.indexOf(this._visibleStack)-1;e[t]||(t=e.length-1),this.showStack(this._getStackId(e[t]))}_createRotatorView(){const e=new Mb(this.editor.locale),t=this.editor.locale.t;return this.view.content.add(e),e.bind("isNavigationVisible").to(this,"_numberOfStacks",this,"_singleViewMode",((e,t)=>!t&&e>1)),e.on("change:isNavigationVisible",(()=>this.updatePosition()),{priority:"low"}),e.bind("counter").to(this,"visibleView",this,"_numberOfStacks",((e,o)=>{if(o<2)return"";const n=Array.from(this._idToStack.values()).indexOf(this._visibleStack)+1;return t("%0 of %1",[n,o])})),e.buttonNextView.on("execute",(()=>{e.focusTracker.isFocused&&this.editor.editing.view.focus(),this._showNextStack()})),e.buttonPrevView.on("execute",(()=>{e.focusTracker.isFocused&&this.editor.editing.view.focus(),this._showPrevStack()})),e}_createFakePanelsView(){const e=new Rb(this.editor.locale,this.view);return e.bind("numberOfPanels").to(this,"_numberOfStacks",this,"_singleViewMode",((e,t)=>!t&&e>=2?Math.min(e-1,2):0)),e.listenTo(this.view,"change:top",(()=>e.updatePosition())),e.listenTo(this.view,"change:left",(()=>e.updatePosition())),this.editor.ui.view.body.add(e),e}_showView({view:e,balloonClassName:t="",withArrow:o=!0,singleViewMode:n=!1}){this.view.class=t,this.view.withArrow=o,this._rotatorView.showView(e),this.visibleView=e,this.view.pin(this._getBalloonPosition()),this._fakePanelsView.updatePosition(),n&&(this._singleViewMode=!0)}_getBalloonPosition(){let e=Array.from(this._visibleStack.values()).pop().position;return e&&(e.limiter||(e=Object.assign({},e,{limiter:this.positionLimiter})),e=Object.assign({},e,{viewportOffsetConfig:this.editor.ui.viewportOffset})),e}}class Mb extends pm{constructor(e){super(e);const t=e.t,o=this.bindTemplate;this.set("isNavigationVisible",!0),this.focusTracker=new Xi,this.buttonPrevView=this._createButtonView(t("Previous"),qh.previousArrow),this.buttonNextView=this._createButtonView(t("Next"),qh.nextArrow),this.content=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-balloon-rotator"],"z-index":"-1"},children:[{tag:"div",attributes:{class:["ck-balloon-rotator__navigation",o.to("isNavigationVisible",(e=>e?"":"ck-hidden"))]},children:[this.buttonPrevView,{tag:"span",attributes:{class:["ck-balloon-rotator__counter"]},children:[{text:o.to("counter")}]},this.buttonNextView]},{tag:"div",attributes:{class:"ck-balloon-rotator__content"},children:this.content}]})}render(){super.render(),this.focusTracker.add(this.element)}destroy(){super.destroy(),this.focusTracker.destroy()}showView(e){this.hideView(),this.content.add(e)}hideView(){this.content.clear()}_createButtonView(e,t){const o=new Em(this.locale);return o.set({label:e,icon:t,tooltip:!0}),o}}class Rb extends pm{constructor(e,t){super(e);const o=this.bindTemplate;this.set("top",0),this.set("left",0),this.set("height",0),this.set("width",0),this.set("numberOfPanels",0),this.content=this.createCollection(),this._balloonPanelView=t,this.setTemplate({tag:"div",attributes:{class:["ck-fake-panel",o.to("numberOfPanels",(e=>e?"":"ck-hidden"))],style:{top:o.to("top",Pb),left:o.to("left",Pb),width:o.to("width",Pb),height:o.to("height",Pb)}},children:this.content}),this.on("change:numberOfPanels",((e,t,o,n)=>{o>n?this._addPanels(o-n):this._removePanels(n-o),this.updatePosition()}))}_addPanels(e){for(;e--;){const e=new pm;e.setTemplate({tag:"div"}),this.content.add(e),this.registerChild(e)}}_removePanels(e){for(;e--;){const e=this.content.last;this.content.remove(e),this.deregisterChild(e),e.destroy()}}updatePosition(){if(this.numberOfPanels){const{top:e,left:t}=this._balloonPanelView,{width:o,height:n}=new qn(this._balloonPanelView.element);Object.assign(this,{top:e,left:t,width:o,height:n})}}}var zb=i(7289),Vb={attributes:{"data-cke":!0}};Vb.setAttributes=Ar(),Vb.insert=_r().bind(null,"head"),Vb.domAPI=kr(),Vb.insertStyleElement=vr();fr()(zb.A,Vb);zb.A&&zb.A.locals&&zb.A.locals;class Ob extends jp{constructor(e,t){const o=e.t,n=Object.assign({},{showResetButton:!0,showIcon:!0,creator:Fg},t);super(e,n.creator),this.label=t.label,this._viewConfig=n,this._viewConfig.showIcon&&(this.iconView=new Am,this.iconView.content=qh.loupe,this.fieldWrapperChildren.add(this.iconView,0),this.extendTemplate({attributes:{class:"ck-search__query_with-icon"}})),this._viewConfig.showResetButton&&(this.resetButtonView=new Em(e),this.resetButtonView.set({label:o("Clear"),icon:qh.cancel,class:"ck-search__reset",isVisible:!1,tooltip:!0}),this.resetButtonView.on("execute",(()=>{this.reset(),this.focus(),this.fire("reset")})),this.resetButtonView.bind("isVisible").to(this.fieldView,"isEmpty",(e=>!e)),this.fieldWrapperChildren.add(this.resetButtonView),this.extendTemplate({attributes:{class:"ck-search__query_with-reset"}}))}reset(){this.fieldView.reset(),this._viewConfig.showResetButton&&(this.resetButtonView.isVisible=!1)}}class Nb extends pm{constructor(){super();const e=this.bindTemplate;this.set({isVisible:!1,primaryText:"",secondaryText:""}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-search__info",e.if("isVisible","ck-hidden",(e=>!e))],tabindex:-1},children:[{tag:"span",children:[{text:[e.to("primaryText")]}]},{tag:"span",children:[{text:[e.to("secondaryText")]}]}]})}focus(){this.element.focus()}}class Lb extends pm{constructor(e){super(e),this.children=this.createCollection(),this.focusTracker=new Xi,this.setTemplate({tag:"div",attributes:{class:["ck","ck-search__results"],tabindex:-1},children:this.children}),this._focusCycler=new Im({focusables:this.children,focusTracker:this.focusTracker})}render(){super.render();for(const e of this.children)this.focusTracker.add(e.element)}focus(){this._focusCycler.focusFirst()}focusFirst(){this._focusCycler.focusFirst()}focusLast(){this._focusCycler.focusLast()}}var Hb=/[\\^$.*+?()[\]{}|]/g,jb=RegExp(Hb.source);const qb=function(e){return(e=rs(e))&&jb.test(e)?e.replace(Hb,"\\$&"):e};var Ub=i(5540),Wb={attributes:{"data-cke":!0}};Wb.setAttributes=Ar(),Wb.insert=_r().bind(null,"head"),Wb.domAPI=kr(),Wb.insertStyleElement=vr();fr()(Ub.A,Wb);Ub.A&&Ub.A.locals&&Ub.A.locals;class $b extends pm{constructor(e,t){super(e),this._config=t,this.filteredView=t.filteredView,this.queryView=this._createSearchTextQueryView(),this.focusTracker=new Xi,this.keystrokes=new er,this.resultsView=new Lb(e),this.children=this.createCollection(),this.focusableChildren=this.createCollection([this.queryView,this.resultsView]),this.set("isEnabled",!0),this.set("resultsCount",0),this.set("totalItemsCount",0),t.infoView&&t.infoView.instance?this.infoView=t.infoView.instance:(this.infoView=new Nb,this._enableDefaultInfoViewBehavior(),this.on("render",(()=>{this.search("")}))),this.resultsView.children.addMany([this.infoView,this.filteredView]),this.focusCycler=new Im({focusables:this.focusableChildren,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.on("search",((e,{resultsCount:t,totalItemsCount:o})=>{this.resultsCount=t,this.totalItemsCount=o})),this.setTemplate({tag:"div",attributes:{class:["ck","ck-search",t.class||null],tabindex:"-1"},children:this.children})}render(){super.render(),this.children.addMany([this.queryView,this.resultsView]);const e=e=>e.stopPropagation();for(const e of this.focusableChildren)this.focusTracker.add(e.element);this.keystrokes.listenTo(this.element),this.keystrokes.set("arrowright",e),this.keystrokes.set("arrowleft",e),this.keystrokes.set("arrowup",e),this.keystrokes.set("arrowdown",e)}focus(){this.queryView.focus()}reset(){this.queryView.reset(),this.search(""),this.filteredView.element.scrollTo(0,0)}search(e){const t=e?new RegExp(qb(e),"ig"):null,o=this.filteredView.filter(t);this.fire("search",{query:e,...o})}_createSearchTextQueryView(){const e=new Ob(this.locale,this._config.queryView);return this.listenTo(e.fieldView,"input",(()=>{this.search(e.fieldView.element.value)})),e.on("reset",(()=>this.reset())),e.bind("isEnabled").to(this),e}_enableDefaultInfoViewBehavior(){const e=this.locale.t,t=this.infoView;function o(e,{query:t,resultsCount:o,totalItemsCount:n}){return"function"==typeof e?e(t,o,n):e}this.on("search",((n,i)=>{if(i.resultsCount)t.set({isVisible:!1});else{const n=this._config.infoView&&this._config.infoView.text;let r,s;i.totalItemsCount?n&&n.notFound?(r=n.notFound.primary,s=n.notFound.secondary):(r=e("No results found"),s=""):n&&n.noSearchableItems?(r=n.noSearchableItems.primary,s=n.noSearchableItems.secondary):(r=e("No searchable items"),s=""),t.set({primaryText:o(r,i),secondaryText:o(s,i),isVisible:!0})}}))}}var Gb=i(2688),Kb={attributes:{"data-cke":!0}};Kb.setAttributes=Ar(),Kb.insert=_r().bind(null,"head"),Kb.domAPI=kr(),Kb.insertStyleElement=vr();fr()(Gb.A,Kb);Gb.A&&Gb.A.locals&&Gb.A.locals;class Zb extends $b{constructor(e,o){super(e,o),this._config=o;const n=Yn("px");this.extendTemplate({attributes:{class:["ck-autocomplete"]}});const i=this.resultsView.bindTemplate;this.resultsView.set("isVisible",!1),this.resultsView.set("_position","s"),this.resultsView.set("_width",0),this.resultsView.extendTemplate({attributes:{class:[i.if("isVisible","ck-hidden",(e=>!e)),i.to("_position",(e=>`ck-search__results_${e}`))],style:{width:i.to("_width",n)}}}),this.focusTracker.on("change:isFocused",((e,t,n)=>{this._updateResultsVisibility(),n?this.resultsView.element.scrollTop=0:o.resetOnBlur&&this.queryView.reset()})),this.on("search",(()=>{this._updateResultsVisibility(),this._updateResultsViewWidthAndPosition()})),this.keystrokes.set("esc",((e,t)=>{this.resultsView.isVisible&&(this.queryView.focus(),this.resultsView.isVisible=!1,t())})),this.listenTo(t.document,"scroll",(()=>{this._updateResultsViewWidthAndPosition()})),this.on("change:isEnabled",(()=>{this._updateResultsVisibility()})),this.filteredView.on("execute",((e,{value:t})=>{this.focus(),this.reset(),this.queryView.fieldView.value=this.queryView.fieldView.element.value=t,this.resultsView.isVisible=!1})),this.resultsView.on("change:isVisible",(()=>{this._updateResultsViewWidthAndPosition()}))}_updateResultsViewWidthAndPosition(){if(!this.resultsView.isVisible)return;this.resultsView._width=new qn(this.queryView.fieldView.element).width;const e=Zb._getOptimalPosition({element:this.resultsView.element,target:this.queryView.element,fitInViewport:!0,positions:Zb.defaultResultsPositions});this.resultsView._position=e?e.name:"s"}_updateResultsVisibility(){const e=void 0===this._config.queryMinChars?0:this._config.queryMinChars,t=this.queryView.fieldView.element.value.length;this.resultsView.isVisible=this.focusTracker.isFocused&&this.isEnabled&&t>=e}}Zb.defaultResultsPositions=[e=>({top:e.bottom,left:e.left,name:"s"}),(e,t)=>({top:e.top-t.height,left:e.left,name:"n"})],Zb._getOptimalPosition=oi;Jb={"&":"&","<":"<",">":">",'"':""","'":"'"};var Jb;var Yb=/[&<>"']/g;RegExp(Yb.source);var Qb=i(1998),Xb={attributes:{"data-cke":!0}};Xb.setAttributes=Ar(),Xb.insert=_r().bind(null,"head"),Xb.domAPI=kr(),Xb.insertStyleElement=vr();fr()(Qb.A,Xb);Qb.A&&Qb.A.locals&&Qb.A.locals;var ek=i(5706),tk={attributes:{"data-cke":!0}};tk.setAttributes=Ar(),tk.insert=_r().bind(null,"head"),tk.domAPI=kr(),tk.insertStyleElement=vr();fr()(ek.A,tk);ek.A&&ek.A.locals&&ek.A.locals;var ok=i(9939),nk={attributes:{"data-cke":!0}};nk.setAttributes=Ar(),nk.insert=_r().bind(null,"head"),nk.domAPI=kr(),nk.insertStyleElement=vr();fr()(ok.A,nk);ok.A&&ok.A.locals&&ok.A.locals;var ik=i(5667),rk={attributes:{"data-cke":!0}};rk.setAttributes=Ar(),rk.insert=_r().bind(null,"head"),rk.domAPI=kr(),rk.insertStyleElement=vr();fr()(ik.A,rk);ik.A&&ik.A.locals&&ik.A.locals;class sk extends ep{constructor(e){super(e);const t=this.bindTemplate;this.set({withText:!0,role:"menuitem"}),this.arrowView=this._createArrowView(),this.extendTemplate({attributes:{class:["ck-menu-bar__menu__button"],"aria-haspopup":!0,"aria-expanded":this.bindTemplate.to("isOn",(e=>String(e))),"data-cke-tooltip-disabled":t.to("isOn")},on:{mouseenter:t.to("mouseenter")}})}render(){super.render(),this.children.add(this.arrowView)}_createArrowView(){const e=new Am;return e.content=Ap,e.extendTemplate({attributes:{class:"ck-menu-bar__menu__button__arrow"}}),e}}var ak=i(4873),lk={attributes:{"data-cke":!0}};lk.setAttributes=Ar(),lk.insert=_r().bind(null,"head"),lk.domAPI=kr(),lk.insertStyleElement=vr();fr()(ak.A,lk);ak.A&&ak.A.locals&&ak.A.locals;class ck extends pm{constructor(e){super(e);const t=this.bindTemplate;this.set("isVisible",!1),this.set("position","se"),this.children=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-reset","ck-menu-bar__menu__panel",t.to("position",(e=>`ck-menu-bar__menu__panel_position_${e}`)),t.if("isVisible","ck-hidden",(e=>!e))],tabindex:"-1"},children:this.children,on:{selectstart:t.to((e=>{"input"!==e.target.tagName.toLocaleLowerCase()&&e.preventDefault()}))}})}focus(e=1){this.children.length&&(1===e?this.children.first.focus():this.children.last.focus())}}var dk=i(55),uk={attributes:{"data-cke":!0}};uk.setAttributes=Ar(),uk.insert=_r().bind(null,"head"),uk.domAPI=kr(),uk.insertStyleElement=vr();fr()(dk.A,uk);dk.A&&dk.A.locals&&dk.A.locals;class hk extends pm{constructor(e){super(e);const t=this.bindTemplate;this.buttonView=new sk(e),this.buttonView.delegate("mouseenter").to(this),this.buttonView.bind("isOn","isEnabled").to(this,"isOpen","isEnabled"),this.panelView=new ck(e),this.panelView.bind("isVisible").to(this,"isOpen"),this.keystrokes=new er,this.focusTracker=new Xi,this.set("isOpen",!1),this.set("isEnabled",!0),this.set("panelPosition","w"),this.set("class",void 0),this.set("parentMenuView",null),this.setTemplate({tag:"div",attributes:{class:["ck","ck-menu-bar__menu",t.to("class"),t.if("isEnabled","ck-disabled",(e=>!e)),t.if("parentMenuView","ck-menu-bar__menu_top-level",(e=>!e))]},children:[this.buttonView,this.panelView]})}render(){super.render(),this.focusTracker.add(this.buttonView.element),this.focusTracker.add(this.panelView.element),this.keystrokes.listenTo(this.element),rb.closeOnEscKey(this),this._repositionPanelOnOpen()}_attachBehaviors(){this.parentMenuView?(rb.openOnButtonClick(this),rb.openOnArrowRightKey(this),rb.closeOnArrowLeftKey(this),rb.closeOnParentClose(this)):(this._propagateArrowKeystrokeEvents(),rb.openAndFocusPanelOnArrowDownKey(this),rb.toggleOnButtonClick(this))}_propagateArrowKeystrokeEvents(){this.keystrokes.set("arrowright",((e,t)=>{this.fire("arrowright"),t()})),this.keystrokes.set("arrowleft",((e,t)=>{this.fire("arrowleft"),t()}))}_repositionPanelOnOpen(){this.on("change:isOpen",((e,t,o)=>{if(!o)return;const n=hk._getOptimalPosition({element:this.panelView.element,target:this.buttonView.element,fitInViewport:!0,positions:this._panelPositions});this.panelView.position=n?n.name:this._panelPositions[0].name}))}focus(){this.buttonView.focus()}get _panelPositions(){const{southEast:e,southWest:t,northEast:o,northWest:n,westSouth:i,eastSouth:r,westNorth:s,eastNorth:a}=sb;return"ltr"===this.locale.uiLanguageDirection?this.parentMenuView?[r,a,i,s]:[e,t,o,n]:this.parentMenuView?[i,s,r,a]:[t,e,n,o]}}hk._getOptimalPosition=oi;const mk=hk;class pk extends kg{constructor(e){super(e),this.role="menu",this.items.on("change",this._setItemsCheckSpace.bind(this))}_setItemsCheckSpace(){const e=Array.from(this.items).some((e=>{const t=gk(e);return t&&t.isToggleable}));this.items.forEach((t=>{const o=gk(t);o&&(o.hasCheckSpace=e)}))}}function gk(e){return e instanceof mg?e.children.map((e=>function(e){return"object"==typeof e&&"buttonView"in e&&e.buttonView instanceof Em}(e)?e.buttonView:e)).find((e=>e instanceof ep)):null}class fk extends wp{constructor(e){super(e),this.set({withText:!0,withKeystroke:!0,tooltip:!1,role:"menuitem"}),this.extendTemplate({attributes:{class:["ck-menu-bar__menu__item__button"]}})}}var bk=i(4782),kk={attributes:{"data-cke":!0}};kk.setAttributes=Ar(),kk.insert=_r().bind(null,"head"),kk.domAPI=kr(),kk.insertStyleElement=vr();fr()(bk.A,kk);bk.A&&bk.A.locals&&bk.A.locals;const wk=["mouseenter","arrowleft","arrowright","change:isOpen"];class _k extends pm{constructor(e){super(e),this.menus=[];const t=e.t,o=this.bindTemplate;this.set({isOpen:!1,isFocusBorderEnabled:!1}),this._setupIsOpenUpdater(),this.children=this.createCollection(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-menu-bar",o.if("isFocusBorderEnabled","ck-menu-bar_focus-border-enabled")],"aria-label":t("Editor menu bar"),role:"menubar"},children:this.children})}fillFromConfig(e,t,o=[]){const n=lb({normalizedConfig:e,locale:this.locale,componentFactory:t,extraItems:o}).items.map((e=>this._createMenu({componentFactory:t,menuDefinition:e})));this.children.addMany(n)}render(){super.render(),ib.toggleMenusAndFocusItemsOnHover(this),ib.closeMenusWhenTheBarCloses(this),ib.closeMenuWhenAnotherOnTheSameLevelOpens(this),ib.focusCycleMenusOnArrows(this),ib.closeOnClickOutside(this),ib.enableFocusHighlightOnInteraction(this)}focus(){this.children.first&&this.children.first.focus()}close(){for(const e of this.children)e.isOpen=!1}registerMenu(e,t=null){t?(e.delegate(...wk).to(t),e.parentMenuView=t):e.delegate(...wk).to(this,(e=>"menu:"+e)),e._attachBehaviors(),this.menus.push(e)}_createMenu({componentFactory:e,menuDefinition:t,parentMenuView:o}){const n=this.locale,i=new mk(n);return this.registerMenu(i,o),i.buttonView.set({label:t.label}),i.once("change:isOpen",(()=>{const o=new pk(n);o.ariaLabel=t.label,i.panelView.children.add(o),o.items.addMany(this._createMenuItems({menuDefinition:t,parentMenuView:i,componentFactory:e}))})),i}_createMenuItems({menuDefinition:e,parentMenuView:t,componentFactory:o}){const n=this.locale,i=[];for(const r of e.groups){for(const e of r.items){const r=new nb(n,t);if(U(e))r.children.add(this._createMenu({componentFactory:o,menuDefinition:e,parentMenuView:t}));else{const n=this._createMenuItemContentFromFactory({componentName:e,componentFactory:o,parentMenuView:t});if(!n)continue;r.children.add(n)}i.push(r)}r!==e.groups[e.groups.length-1]&&i.push(new pg(n))}return i}_createMenuItemContentFromFactory({componentName:e,parentMenuView:t,componentFactory:o}){const n=o.create(e);return n instanceof mk||n instanceof ip||n instanceof fk?(this._registerMenuTree(n,t),n.on("execute",(()=>{this.close()})),n):(D("menu-bar-component-unsupported",{componentName:e,componentView:n}),null)}_registerMenuTree(e,t){if(!(e instanceof mk))return void e.delegate("mouseenter").to(t);this.registerMenu(e,t);const o=e.panelView.children.filter((e=>e instanceof pk))[0];if(!o)return void e.delegate("mouseenter").to(t);const n=o.items.filter((e=>e instanceof mg));for(const t of n)this._registerMenuTree(t.children.get(0),e)}_setupIsOpenUpdater(){let e;this.on("menu:change:isOpen",((t,o,n)=>{clearTimeout(e),n?this.isOpen=!0:e=setTimeout((()=>{this.isOpen=Array.from(this.children).some((e=>e.isOpen))}),0)}))}}class yk extends wb{constructor(e,t){super(e),this.view=t}init(){const e=this.editor,t=this.view,o=e.editing.view,n=t.editable,i=o.document.getRoot();n.name=i.rootName,t.render();const r=n.element;this.setEditableElement(n.name,r),t.editable.bind("isFocused").to(this.focusTracker),o.attachDomRoot(r),this._initPlaceholder(),this._initToolbar(),this._initMenuBar(this.view.menuBarView),this.fire("ready")}destroy(){super.destroy();const e=this.view;this.editor.editing.view.detachDomRoot(e.editable.name),e.destroy()}_initToolbar(){const e=this.editor,t=this.view;t.toolbar.fillFromConfig(e.config.get("toolbar"),this.componentFactory),this.addToolbar(t.toolbar)}_initPlaceholder(){const e=this.editor,t=e.editing.view,o=t.document.getRoot(),n=e.config.get("placeholder");if(n){const e="string"==typeof n?n:n[o.rootName];e&&(o.placeholder=e)}Sr({view:t,element:o,isDirectHost:!1,keepOnFocus:!0})}}class Ak extends Cb{constructor(e,t,o={}){super(e);const n=e.t;this.toolbar=new cg(e,{shouldGroupWhenFull:o.shouldToolbarGroupWhenFull}),this.menuBarView=new _k(e),this.editable=new xb(e,t,o.editableElement,{label:e=>n("Rich Text Editor. Editing area: %0",e.name)}),this.toolbar.extendTemplate({attributes:{class:["ck-reset_all","ck-rounded-corners"],dir:e.uiLanguageDirection}}),this.menuBarView.extendTemplate({attributes:{class:["ck-reset_all","ck-rounded-corners"],dir:e.uiLanguageDirection}})}render(){super.render(),this.registerChild([this.menuBarView,this.toolbar,this.editable])}}class Ck extends(Hh(Lh)){constructor(e,t={}){if(!vk(e)&&void 0!==t.initialData)throw new E("editor-create-initial-data",null);super(t),void 0===this.config.get("initialData")&&this.config.set("initialData",function(e){return vk(e)?(t=e,t instanceof HTMLTextAreaElement?t.value:t.innerHTML):e;var t}(e)),vk(e)&&(this.sourceElement=e,function(e,t){if(t.ckeditorInstance)throw new E("editor-source-element-already-used",e);t.ckeditorInstance=e,e.once("destroy",(()=>{delete t.ckeditorInstance}))}(this,e)),this.model.document.createRoot();const o=!this.config.get("toolbar.shouldNotGroupWhenFull"),n=new Ak(this.locale,this.editing.view,{editableElement:this.sourceElement,shouldToolbarGroupWhenFull:o});this.ui=new yk(this,n)}destroy(){const e=this.getData();return this.ui.destroy(),super.destroy().then((()=>{this.sourceElement&&this.updateSourceElement(e)}))}static create(e,t={}){return new Promise((o=>{if(vk(e)&&"TEXTAREA"===e.tagName)throw new E("editor-wrong-element",null);const n=new this(e,t);o(n.initPlugins().then((()=>n.ui.init())).then((()=>n.data.init(n.config.get("initialData")))).then((()=>n.fire("ready"))).then((()=>n)))}))}}function vk(e){return Bn(e)}class xk extends(z()){constructor(){super(...arguments),this._stack=[]}add(e,t){const o=this._stack,n=o[0];this._insertDescriptor(e);const i=o[0];n===i||Ek(n,i)||this.fire("change:top",{oldDescriptor:n,newDescriptor:i,writer:t})}remove(e,t){const o=this._stack,n=o[0];this._removeDescriptor(e);const i=o[0];n===i||Ek(n,i)||this.fire("change:top",{oldDescriptor:n,newDescriptor:i,writer:t})}_insertDescriptor(e){const t=this._stack,o=t.findIndex((t=>t.id===e.id));if(Ek(e,t[o]))return;o>-1&&t.splice(o,1);let n=0;for(;t[n]&&Dk(t[n],e);)n++;t.splice(n,0,e)}_removeDescriptor(e){const t=this._stack,o=t.findIndex((t=>t.id===e));o>-1&&t.splice(o,1)}}function Ek(e,t){return e&&t&&e.priority==t.priority&&Bk(e.classes)==Bk(t.classes)}function Dk(e,t){return e.priority>t.priority||!(e.priorityBk(t.classes)}function Bk(e){return Array.isArray(e)?e.sort().join(","):e}const Sk="widget-type-around";function Tk(e,t,o){return!!e&&Rk(e)&&!o.isInline(t)}function Ik(e){return e.getAttribute(Sk)}const Pk='',Fk="ck-widget",Mk="ck-widget_selected";function Rk(e){return!!e.is("element")&&!!e.getCustomProperty("widget")}function zk(e,t,o={}){if(!e.is("containerElement"))throw new E("widget-to-widget-wrong-element-type",null,{element:e});return t.setAttribute("contenteditable","false",e),t.addClass(Fk,e),t.setCustomProperty("widget",!0,e),e.getFillerOffset=Hk,t.setCustomProperty("widgetLabel",[],e),o.label&&function(e,t){const o=e.getCustomProperty("widgetLabel");o.push(t)}(e,o.label),o.hasSelectionHandle&&function(e,t){const o=t.createUIElement("div",{class:"ck ck-widget__selection-handle"},(function(e){const t=this.toDomElement(e),o=new Am;return o.set("content",Pk),o.render(),t.appendChild(o.element),t}));t.insert(t.createPositionAt(e,0),o),t.addClass(["ck-widget_with-selection-handle"],e)}(e,t),Nk(e,t),e}function Vk(e,t,o){if(t.classes&&o.addClass(xi(t.classes),e),t.attributes)for(const n in t.attributes)o.setAttribute(n,t.attributes[n],e)}function Ok(e,t,o){if(t.classes&&o.removeClass(xi(t.classes),e),t.attributes)for(const n in t.attributes)o.removeAttribute(n,e)}function Nk(e,t,o=Vk,n=Ok){const i=new xk;i.on("change:top",((t,i)=>{i.oldDescriptor&&n(e,i.oldDescriptor,i.writer),i.newDescriptor&&o(e,i.newDescriptor,i.writer)}));t.setCustomProperty("addHighlight",((e,t,o)=>i.add(t,o)),e),t.setCustomProperty("removeHighlight",((e,t,o)=>i.remove(t,o)),e)}function Lk(e,t,o={}){return t.addClass(["ck-editor__editable","ck-editor__nested-editable"],e),t.setAttribute("role","textbox",e),t.setAttribute("tabindex","-1",e),o.label&&t.setAttribute("aria-label",o.label,e),t.setAttribute("contenteditable",e.isReadOnly?"false":"true",e),e.on("change:isReadOnly",((o,n,i)=>{t.setAttribute("contenteditable",i?"false":"true",e)})),e.on("change:isFocused",((o,n,i)=>{i?t.addClass("ck-editor__nested-editable_focused",e):t.removeClass("ck-editor__nested-editable_focused",e)})),Nk(e,t),e}function Hk(){return null}function jk(e){const t=e=>{const{width:t,paddingLeft:o,paddingRight:n}=e.ownerDocument.defaultView.getComputedStyle(e);return parseFloat(t)-(parseFloat(o)||0)-(parseFloat(n)||0)},o=e.parentElement;if(!o)return 0;let n=t(o);let i=0,r=o;for(;isNaN(n);){if(r=r.parentElement,++i>5)return 0;n=t(r)}return n}class qk extends lr{static get pluginName(){return"OPMacroToc"}static get buttonName(){return"insertToc"}init(){const e=this.editor,t=e.model,o=e.conversion;t.schema.register("op-macro-toc",{allowWhere:"$block",isBlock:!0,isLimit:!0}),o.for("upcast").elementToElement({view:{name:"macro",classes:"toc"},model:"op-macro-toc"}),o.for("editingDowncast").elementToElement({model:"op-macro-toc",view:(e,{writer:t})=>zk(this.createTocViewElement(t),t,{label:this.label})}),o.for("dataDowncast").elementToElement({model:"op-macro-toc",view:(e,{writer:t})=>this.createTocDataElement(t)}),e.ui.componentFactory.add(qk.buttonName,(t=>{const o=new Em(t);return o.set({label:this.label,withText:!0}),o.on("execute",(()=>{e.model.change((t=>{const o=t.createElement("op-macro-toc",{});e.model.insertContent(o,e.model.document.selection)}))})),o}))}get label(){return window.I18n.t("js.editor.macro.toc")}createTocViewElement(e){const t=e.createText(this.label),o=e.createContainerElement("div");return e.insert(e.createPositionAt(o,0),t),o}createTocDataElement(e){return e.createContainerElement("macro",{class:"toc"})}}const Uk=Symbol("isOPEmbeddedTable");function Wk(e){const t=e.getSelectedElement();return!(!t||!function(e){return!!e.getCustomProperty(Uk)&&Rk(e)}(t))}function $k(e){return _.get(e.config,"_config.openProject.context.resource")}function Gk(e){return _.get(e.config,"_config.openProject.pluginContext")}function Kk(e,t){return Gk(e).services[t]}function Zk(e){return Kk(e,"pathHelperService")}function Jk(e){return Kk(e,"i18n")}class Yk extends lr{static get pluginName(){return"EmbeddedTableEditing"}static get buttonName(){return"insertEmbeddedTable"}init(){const e=this.editor,t=e.model,o=e.conversion,n=Gk(e);this.text={button:window.I18n.t("js.editor.macro.embedded_table.button"),macro_text:window.I18n.t("js.editor.macro.embedded_table.text")},t.schema.register("op-macro-embedded-table",{allowWhere:"$block",allowAttributes:["opEmbeddedTableQuery"],isBlock:!0,isObject:!0}),o.for("upcast").elementToElement({view:{name:"macro",classes:"embedded-table"},model:(e,{writer:t})=>{const o=e.getAttribute("data-query-props");return t.createElement("op-macro-embedded-table",{opEmbeddedTableQuery:o?JSON.parse(o):{}})}}),o.for("editingDowncast").elementToElement({model:"op-macro-embedded-table",view:(e,{writer:t})=>{return o=this.createEmbeddedTableView(t),n=t,this.label,n.setCustomProperty(Uk,!0,o),zk(o,n,{label:"your label here"});var o,n}}),o.for("dataDowncast").elementToElement({model:"op-macro-embedded-table",view:(e,{writer:t})=>this.createEmbeddedTableDataElement(e,t)}),e.ui.componentFactory.add(Yk.buttonName,(t=>{const o=new Em(t);return o.set({label:this.text.button,withText:!0}),o.on("execute",(()=>n.runInZone((()=>{n.services.externalQueryConfiguration.show({currentQuery:{},callback:t=>e.model.change((o=>{const n=o.createElement("op-macro-embedded-table",{opEmbeddedTableQuery:t});e.model.insertContent(n,e.model.document.selection)}))})})))),o}))}createEmbeddedTableView(e){const t=e.createText(this.text.macro_text),o=e.createContainerElement("div");return e.insert(e.createPositionAt(o,0),t),o}createEmbeddedTableDataElement(e,t){const o=e.getAttribute("opEmbeddedTableQuery")||{};return t.createContainerElement("macro",{class:"embedded-table","data-query-props":JSON.stringify(o)})}}class Qk{constructor(e,t=20){this._batch=null,this.model=e,this._size=0,this.limit=t,this._isLocked=!1,this._changeCallback=(e,t)=>{t.isLocal&&t.isUndoable&&t!==this._batch&&this._reset(!0)},this._selectionChangeCallback=()=>{this._reset()},this.model.document.on("change",this._changeCallback),this.model.document.selection.on("change:range",this._selectionChangeCallback),this.model.document.selection.on("change:attribute",this._selectionChangeCallback)}get batch(){return this._batch||(this._batch=this.model.createBatch({isTyping:!0})),this._batch}get size(){return this._size}input(e){this._size+=e,this._size>=this.limit&&this._reset(!0)}get isLocked(){return this._isLocked}lock(){this._isLocked=!0}unlock(){this._isLocked=!1}destroy(){this.model.document.off("change",this._changeCallback),this.model.document.selection.off("change:range",this._selectionChangeCallback),this.model.document.selection.off("change:attribute",this._selectionChangeCallback)}_reset(e=!1){this.isLocked&&!e||(this._batch=null,this._size=0)}}class Xk extends dr{constructor(e,t){super(e),this._buffer=new Qk(e.model,t),this._isEnabledBasedOnSelection=!1}get buffer(){return this._buffer}destroy(){super.destroy(),this._buffer.destroy()}execute(e={}){const t=this.editor.model,o=t.document,n=e.text||"",i=n.length;let r=o.selection;if(e.selection?r=e.selection:e.range&&(r=t.createSelection(e.range)),!t.canEditAt(r))return;const s=e.resultRange;t.enqueueChange(this._buffer.batch,(e=>{this._buffer.lock();const a=Array.from(o.selection.getAttributes());t.deleteContent(r),n&&t.insertContent(e.createText(n,a),r),s?e.setSelection(s):r.is("documentSelection")||e.setSelection(r),this._buffer.unlock(),this._buffer.input(i)}))}}const ew=["insertText","insertReplacementText"],tw=[...ew,"insertCompositionText"];class ow extends za{constructor(e){super(e),this.focusObserver=e.getObserver(xl);const t=r.isAndroid?tw:ew,o=e.document;o.on("beforeinput",((n,i)=>{if(!this.isEnabled)return;const{data:r,targetRanges:s,inputType:a,domEvent:l}=i;if(!t.includes(a))return;this.focusObserver.flush();const c=new w(o,"insertText");o.fire(c,new Na(e,l,{text:r,selection:e.createSelection(s)})),c.stop.called&&n.stop()})),r.isAndroid||o.on("compositionend",((t,{data:n,domEvent:i})=>{this.isEnabled&&n&&o.fire("insertText",new Na(e,i,{text:n}))}),{priority:"lowest"})}observe(){}stopObserving(){}}class nw extends lr{static get pluginName(){return"Input"}init(){const e=this.editor,t=e.model,o=e.editing.view,n=e.editing.mapper,i=t.document.selection;this._compositionQueue=new iw(e),o.addObserver(ow);const s=new Xk(e,e.config.get("typing.undoStep")||20);e.commands.add("insertText",s),e.commands.add("input",s),this.listenTo(o.document,"insertText",((s,a)=>{o.document.isComposing||a.preventDefault(),r.isAndroid&&o.document.isComposing&&this._compositionQueue.flush("next beforeinput");const{text:l,selection:c}=a;let d;d=c?Array.from(c.getRanges()).map((e=>n.toModelRange(e))):Array.from(i.getRanges());let u=l;if(r.isAndroid){const e=Array.from(d[0].getItems()).reduce(((e,t)=>e+(t.is("$textProxy")?t.data:"")),"");if(e&&(e.length<=u.length?u.startsWith(e)&&(u=u.substring(e.length),d[0].start=d[0].start.getShiftedBy(e.length)):e.startsWith(u)&&(d[0].start=d[0].start.getShiftedBy(u.length),u="")),0==u.length&&d[0].isCollapsed)return}const h={text:u,selection:t.createSelection(d)};r.isAndroid&&o.document.isComposing?this._compositionQueue.push(h):(e.execute("insertText",h),o.scrollToTheSelection())})),r.isAndroid?this.listenTo(o.document,"keydown",((e,n)=>{!i.isCollapsed&&229==n.keyCode&&o.document.isComposing&&rw(t,s)})):this.listenTo(o.document,"compositionstart",(()=>{i.isCollapsed||rw(t,s)})),r.isAndroid?(this.listenTo(o.document,"mutations",((e,{mutations:t})=>{if(o.document.isComposing)for(const{node:e}of t){const t=sw(e,n),o=n.toModelElement(t);if(this._compositionQueue.isComposedElement(o))return void this._compositionQueue.flush("mutations")}})),this.listenTo(o.document,"compositionend",(()=>{this._compositionQueue.flush("composition end")})),this.listenTo(o.document,"compositionend",(()=>{const e=[];for(const t of this._compositionQueue.flushComposedElements()){const o=n.toViewElement(t);o&&e.push({type:"children",node:o})}e.length&&o.document.fire("mutations",{mutations:e})}),{priority:"lowest"})):this.listenTo(o.document,"compositionend",(()=>{o.document.fire("mutations",{mutations:[]})}),{priority:"lowest"})}destroy(){super.destroy(),this._compositionQueue.destroy()}}class iw{constructor(e){this.flushDebounced=el((()=>this.flush("timeout")),50),this._queue=[],this._compositionElements=new Set,this.editor=e}destroy(){for(this.flushDebounced.cancel(),this._compositionElements.clear();this._queue.length;)this.shift()}get length(){return this._queue.length}push(e){const t={text:e.text};if(e.selection){t.selectionRanges=[];for(const o of e.selection.getRanges())t.selectionRanges.push(cc.fromRange(o)),this._compositionElements.add(o.start.parent)}this._queue.push(t),this.flushDebounced()}shift(){const e=this._queue.shift(),t={text:e.text};if(e.selectionRanges){const o=e.selectionRanges.map((e=>function(e){const t=e.toRange();if(e.detach(),"$graveyard"==t.root.rootName)return null;return t}(e))).filter((e=>!!e));o.length&&(t.selection=this.editor.model.createSelection(o))}return t}flush(e){const t=this.editor,o=t.model,n=t.editing.view;if(this.flushDebounced.cancel(),!this._queue.length)return;const i=t.commands.get("insertText").buffer;o.enqueueChange(i.batch,(()=>{for(i.lock();this._queue.length;){const e=this.shift();t.execute("insertText",e)}i.unlock()})),n.scrollToTheSelection()}isComposedElement(e){return this._compositionElements.has(e)}flushComposedElements(){const e=Array.from(this._compositionElements);return this._compositionElements.clear(),e}}function rw(e,t){if(!t.isEnabled)return;const o=t.buffer;o.lock(),e.enqueueChange(o.batch,(()=>{e.deleteContent(e.document.selection)})),o.unlock()}function sw(e,t){let o=e.is("$text")?e.parent:e;for(;!t.toModelElement(o);)o=o.parent;return o}class aw extends dr{constructor(e,t){super(e),this.direction=t,this._buffer=new Qk(e.model,e.config.get("typing.undoStep")),this._isEnabledBasedOnSelection=!1}get buffer(){return this._buffer}execute(e={}){const t=this.editor.model,o=t.document;t.enqueueChange(this._buffer.batch,(n=>{this._buffer.lock();const i=n.createSelection(e.selection||o.selection);if(!t.canEditAt(i))return;const r=e.sequence||1,s=i.isCollapsed;if(i.isCollapsed&&t.modifySelection(i,{direction:this.direction,unit:e.unit,treatEmojiAsSingleUnit:!0}),this._shouldEntireContentBeReplacedWithParagraph(r))return void this._replaceEntireContentWithParagraph(n);if(this._shouldReplaceFirstBlockWithParagraph(i,r))return void this.editor.execute("paragraph",{selection:i});if(i.isCollapsed)return;let a=0;i.getFirstRange().getMinimalFlatRanges().forEach((e=>{a+=ne(e.getWalker({singleCharacters:!0,ignoreElementEnd:!0,shallow:!0}))})),t.deleteContent(i,{doNotResetEntireContent:s,direction:this.direction}),this._buffer.input(a),n.setSelection(i),this._buffer.unlock()}))}_shouldEntireContentBeReplacedWithParagraph(e){if(e>1)return!1;const t=this.editor.model,o=t.document.selection,n=t.schema.getLimitElement(o);if(!(o.isCollapsed&&o.containsEntireContent(n)))return!1;if(!t.schema.checkChild(n,"paragraph"))return!1;const i=n.getChild(0);return!i||!i.is("element","paragraph")}_replaceEntireContentWithParagraph(e){const t=this.editor.model,o=t.document.selection,n=t.schema.getLimitElement(o),i=e.createElement("paragraph");e.remove(e.createRangeIn(n)),e.insert(i,n),e.setSelection(i,0)}_shouldReplaceFirstBlockWithParagraph(e,t){const o=this.editor.model;if(t>1||"backward"!=this.direction)return!1;if(!e.isCollapsed)return!1;const n=e.getFirstPosition(),i=o.schema.getLimitElement(n),r=i.getChild(0);return n.parent==r&&(!!e.containsEntireContent(r)&&(!!o.schema.checkChild(i,"paragraph")&&"paragraph"!=r.name))}}const lw="word",cw="selection",dw="backward",uw="forward",hw={deleteContent:{unit:cw,direction:dw},deleteContentBackward:{unit:"codePoint",direction:dw},deleteWordBackward:{unit:lw,direction:dw},deleteHardLineBackward:{unit:cw,direction:dw},deleteSoftLineBackward:{unit:cw,direction:dw},deleteContentForward:{unit:"character",direction:uw},deleteWordForward:{unit:lw,direction:uw},deleteHardLineForward:{unit:cw,direction:uw},deleteSoftLineForward:{unit:cw,direction:uw}};class mw extends za{constructor(e){super(e);const t=e.document;let o=0;t.on("keydown",(()=>{o++})),t.on("keyup",(()=>{o=0})),t.on("beforeinput",((n,i)=>{if(!this.isEnabled)return;const{targetRanges:s,domEvent:a,inputType:l}=i,c=hw[l];if(!c)return;const d={direction:c.direction,unit:c.unit,sequence:o};d.unit==cw&&(d.selectionToRemove=e.createSelection(s[0])),"deleteContentBackward"===l&&(r.isAndroid&&(d.sequence=1),function(e){if(1!=e.length||e[0].isCollapsed)return!1;const t=e[0].getWalker({direction:"backward",singleCharacters:!0,ignoreElementEnd:!0});let o=0;for(const{nextPosition:e,item:n}of t){if(e.parent.is("$text")){const t=e.parent.data,n=e.offset;if(nr(t,n)||ir(t,n)||sr(t,n))continue;o++}else(n.is("containerElement")||n.is("emptyElement"))&&o++;if(o>1)return!0}return!1}(s)&&(d.unit=cw,d.selectionToRemove=e.createSelection(s)));const u=new Ms(t,"delete",s[0]);t.fire(u,new Na(e,a,d)),u.stop.called&&n.stop()})),r.isBlink&&function(e){const t=e.view,o=t.document;let n=null,i=!1;function r(e){return e==ki.backspace||e==ki.delete}function s(e){return e==ki.backspace?dw:uw}o.on("keydown",((e,{keyCode:t})=>{n=t,i=!1})),o.on("keyup",((a,{keyCode:l,domEvent:c})=>{const d=o.selection,u=e.isEnabled&&l==n&&r(l)&&!d.isCollapsed&&!i;if(n=null,u){const e=d.getFirstRange(),n=new Ms(o,"delete",e),i={unit:cw,direction:s(l),selectionToRemove:d};o.fire(n,new Na(t,c,i))}})),o.on("beforeinput",((e,{inputType:t})=>{const o=hw[t];r(n)&&o&&o.direction==s(n)&&(i=!0)}),{priority:"high"}),o.on("beforeinput",((e,{inputType:t,data:o})=>{n==ki.delete&&"insertText"==t&&""==o&&e.stop()}),{priority:"high"})}(this)}observe(){}stopObserving(){}}class pw extends lr{static get pluginName(){return"Delete"}init(){const e=this.editor,t=e.editing.view,o=t.document,n=e.model.document;t.addObserver(mw),this._undoOnBackspace=!1;const i=new aw(e,"forward");e.commands.add("deleteForward",i),e.commands.add("forwardDelete",i),e.commands.add("delete",new aw(e,"backward")),this.listenTo(o,"delete",((n,i)=>{o.isComposing||i.preventDefault();const{direction:r,sequence:s,selectionToRemove:a,unit:l}=i,c="forward"===r?"deleteForward":"delete",d={sequence:s};if("selection"==l){const t=Array.from(a.getRanges()).map((t=>e.editing.mapper.toModelRange(t)));d.selection=e.model.createSelection(t)}else d.unit=l;e.execute(c,d),t.scrollToTheSelection()}),{priority:"low"}),this.editor.plugins.has("UndoEditing")&&(this.listenTo(o,"delete",((t,o)=>{this._undoOnBackspace&&"backward"==o.direction&&1==o.sequence&&"codePoint"==o.unit&&(this._undoOnBackspace=!1,e.execute("undo"),o.preventDefault(),t.stop())}),{context:"$capture"}),this.listenTo(n,"change",(()=>{this._undoOnBackspace=!1})))}requestUndoOnBackspace(){this.editor.plugins.has("UndoEditing")&&(this._undoOnBackspace=!0)}}class gw extends lr{static get requires(){return[nw,pw]}static get pluginName(){return"Typing"}}function fw(e,t){let o=e.start;return{text:Array.from(e.getWalker({ignoreElementEnd:!1})).reduce(((e,{item:n})=>n.is("$text")||n.is("$textProxy")?e+n.data:(o=t.createPositionAfter(n),"")),""),range:t.createRange(o,e.end)}}class bw extends(Y()){constructor(e,t){super(),this.model=e,this.testCallback=t,this._hasMatch=!1,this.set("isEnabled",!0),this.on("change:isEnabled",(()=>{this.isEnabled?this._startListening():(this.stopListening(e.document.selection),this.stopListening(e.document))})),this._startListening()}get hasMatch(){return this._hasMatch}_startListening(){const e=this.model.document;this.listenTo(e.selection,"change:range",((t,{directChange:o})=>{o&&(e.selection.isCollapsed?this._evaluateTextBeforeSelection("selection"):this.hasMatch&&(this.fire("unmatched"),this._hasMatch=!1))})),this.listenTo(e,"change:data",((e,t)=>{!t.isUndo&&t.isLocal&&this._evaluateTextBeforeSelection("data",{batch:t})}))}_evaluateTextBeforeSelection(e,t={}){const o=this.model,n=o.document.selection,i=o.createRange(o.createPositionAt(n.focus.parent,0),n.focus),{text:r,range:s}=fw(i,o),a=this.testCallback(r);if(!a&&this.hasMatch&&this.fire("unmatched"),this._hasMatch=!!a,a){const o=Object.assign(t,{text:r,range:s});"object"==typeof a&&Object.assign(o,a),this.fire(`matched:${e}`,o)}}}class kw extends lr{static get pluginName(){return"TwoStepCaretMovement"}constructor(e){super(e),this._isNextGravityRestorationSkipped=!1,this.attributes=new Set,this._overrideUid=null}init(){const e=this.editor,t=e.model,o=e.editing.view,n=e.locale,i=t.document.selection;this.listenTo(o.document,"arrowKey",((e,t)=>{if(!i.isCollapsed)return;if(t.shiftKey||t.altKey||t.ctrlKey)return;const o=t.keyCode==ki.arrowright,r=t.keyCode==ki.arrowleft;if(!o&&!r)return;const s=n.contentLanguageDirection;let a=!1;a="ltr"===s&&o||"rtl"===s&&r?this._handleForwardMovement(t):this._handleBackwardMovement(t),!0===a&&e.stop()}),{context:"$text",priority:"highest"}),this.listenTo(i,"change:range",((e,t)=>{this._isNextGravityRestorationSkipped?this._isNextGravityRestorationSkipped=!1:this._isGravityOverridden&&(!t.directChange&&vw(i.getFirstPosition(),this.attributes)||this._restoreGravity())})),this._enableClickingAfterNode(),this._enableInsertContentSelectionAttributesFixer(),this._handleDeleteContentAfterNode()}registerAttribute(e){this.attributes.add(e)}_handleForwardMovement(e){const t=this.attributes,o=this.editor.model,n=o.document.selection,i=n.getFirstPosition();return!this._isGravityOverridden&&((!i.isAtStart||!ww(n,t))&&(!!vw(i,t)&&(Aw(e),ww(n,t)&&vw(i,t,!0)?yw(o,t):this._overrideGravity(),!0)))}_handleBackwardMovement(e){const t=this.attributes,o=this.editor.model,n=o.document.selection,i=n.getFirstPosition();return this._isGravityOverridden?(Aw(e),this._restoreGravity(),vw(i,t,!0)?yw(o,t):_w(o,t,i),!0):i.isAtStart?!!ww(n,t)&&(Aw(e),_w(o,t,i),!0):!ww(n,t)&&vw(i,t,!0)?(Aw(e),_w(o,t,i),!0):!!Cw(i,t)&&(i.isAtEnd&&!ww(n,t)&&vw(i,t)?(Aw(e),_w(o,t,i),!0):(this._isNextGravityRestorationSkipped=!0,this._overrideGravity(),!1))}_enableClickingAfterNode(){const e=this.editor,t=e.model,o=t.document.selection,n=e.editing.view.document;e.editing.view.addObserver(Nu);let i=!1;this.listenTo(n,"mousedown",(()=>{i=!0})),this.listenTo(n,"selectionChange",(()=>{const e=this.attributes;if(!i)return;if(i=!1,!o.isCollapsed)return;if(!ww(o,e))return;const n=o.getFirstPosition();vw(n,e)&&(n.isAtStart||vw(n,e,!0)?yw(t,e):this._isGravityOverridden||this._overrideGravity())}))}_enableInsertContentSelectionAttributesFixer(){const e=this.editor.model,t=e.document.selection,o=this.attributes;this.listenTo(e,"insertContent",(()=>{const n=t.getFirstPosition();ww(t,o)&&vw(n,o)&&yw(e,o)}),{priority:"low"})}_handleDeleteContentAfterNode(){const e=this.editor,t=e.model,o=t.document.selection,n=e.editing.view;let i=!1,r=!1;this.listenTo(n.document,"delete",((e,t)=>{i="backward"===t.direction}),{priority:"high"}),this.listenTo(t,"deleteContent",(()=>{if(!i)return;const e=o.getFirstPosition();r=ww(o,this.attributes)&&!Cw(e,this.attributes)}),{priority:"high"}),this.listenTo(t,"deleteContent",(()=>{i&&(i=!1,r||e.model.enqueueChange((()=>{const e=o.getFirstPosition();ww(o,this.attributes)&&vw(e,this.attributes)&&(e.isAtStart||vw(e,this.attributes,!0)?yw(t,this.attributes):this._isGravityOverridden||this._overrideGravity())})))}),{priority:"low"})}get _isGravityOverridden(){return!!this._overrideUid}_overrideGravity(){this._overrideUid=this.editor.model.change((e=>e.overrideSelectionGravity()))}_restoreGravity(){this.editor.model.change((e=>{e.restoreSelectionGravity(this._overrideUid),this._overrideUid=null}))}}function ww(e,t){for(const o of t)if(e.hasAttribute(o))return!0;return!1}function _w(e,t,o){const n=o.nodeBefore;e.change((o=>{if(n){const t=[],i=e.schema.isObject(n)&&e.schema.isInline(n);for(const[o,r]of n.getAttributes())!e.schema.checkAttribute("$text",o)||i&&!1===e.schema.getAttributeProperties(o).copyFromObject||t.push([o,r]);o.setSelectionAttribute(t)}else o.removeSelectionAttribute(t)}))}function yw(e,t){e.change((e=>{e.removeSelectionAttribute(t)}))}function Aw(e){e.preventDefault()}function Cw(e,t){return vw(e.getShiftedBy(-1),t)}function vw(e,t,o=!1){const{nodeBefore:n,nodeAfter:i}=e;for(const e of t){const t=n?n.getAttribute(e):void 0,r=i?i.getAttribute(e):void 0;if((!o||void 0!==t&&void 0!==r)&&r!==t)return!0}return!1}xw('"'),xw("'"),xw("'"),xw('"'),xw('"'),xw("'");function xw(e){return new RegExp(`(^|\\s)(${e})([^${e}]*)(${e})$`)}function Ew(e,t,o,n){return n.createRange(Dw(e,t,o,!0,n),Dw(e,t,o,!1,n))}function Dw(e,t,o,n,i){let r=e.textNode||(n?e.nodeBefore:e.nodeAfter),s=null;for(;r&&r.getAttribute(t)==o;)s=r,r=n?r.previousSibling:r.nextSibling;return s?i.createPositionAt(s,n?"before":"after"):e}function Bw(e,t,o,n){const i=e.editing.view,r=new Set;i.document.registerPostFixer((i=>{const s=e.model.document.selection;let a=!1;if(s.hasAttribute(t)){const l=Ew(s.getFirstPosition(),t,s.getAttribute(t),e.model),c=e.editing.mapper.toViewRange(l);for(const e of c.getItems())e.is("element",o)&&!e.hasClass(n)&&(i.addClass(n,e),r.add(e),a=!0)}return a})),e.conversion.for("editingDowncast").add((e=>{function t(){i.change((e=>{for(const t of r.values())e.removeClass(n,t),r.delete(t)}))}e.on("insert",t,{priority:"highest"}),e.on("remove",t,{priority:"highest"}),e.on("attribute",t,{priority:"highest"}),e.on("selection",t,{priority:"highest"})}))}function*Sw(e,t){for(const o of t)o&&e.getAttributeProperties(o[0]).copyOnEnter&&(yield o)}class Tw extends dr{execute(){this.editor.model.change((e=>{this.enterBlock(e),this.fire("afterExecute",{writer:e})}))}enterBlock(e){const t=this.editor.model,o=t.document.selection,n=t.schema,i=o.isCollapsed,r=o.getFirstRange(),s=r.start.parent,a=r.end.parent;if(n.isLimit(s)||n.isLimit(a))return i||s!=a||t.deleteContent(o),!1;if(i){const t=Sw(e.model.schema,o.getAttributes());return Iw(e,r.start),e.setSelectionAttribute(t),!0}{const n=!(r.start.isAtStart&&r.end.isAtEnd),i=s==a;if(t.deleteContent(o,{leaveUnmerged:n}),n){if(i)return Iw(e,o.focus),!0;e.setSelection(a,0)}}return!1}}function Iw(e,t){e.split(t),e.setSelection(t.parent.nextSibling,0)}const Pw={insertParagraph:{isSoft:!1},insertLineBreak:{isSoft:!0}};class Fw extends za{constructor(e){super(e);const t=this.document;let o=!1;t.on("keydown",((e,t)=>{o=t.shiftKey})),t.on("beforeinput",((n,i)=>{if(!this.isEnabled)return;let s=i.inputType;r.isSafari&&o&&"insertParagraph"==s&&(s="insertLineBreak");const a=i.domEvent,l=Pw[s];if(!l)return;const c=new Ms(t,"enter",i.targetRanges[0]);t.fire(c,new Na(e,a,{isSoft:l.isSoft})),c.stop.called&&n.stop()}))}observe(){}stopObserving(){}}class Mw extends lr{static get pluginName(){return"Enter"}init(){const e=this.editor,t=e.editing.view,o=t.document,n=this.editor.t;t.addObserver(Fw),e.commands.add("enter",new Tw(e)),this.listenTo(o,"enter",((n,i)=>{o.isComposing||i.preventDefault(),i.isSoft||(e.execute("enter"),t.scrollToTheSelection())}),{priority:"low"}),e.accessibility.addKeystrokeInfos({keystrokes:[{label:n("Insert a hard break (a new paragraph)"),keystroke:"Enter"}]})}}class Rw extends dr{execute(){const e=this.editor.model,t=e.document;e.change((o=>{!function(e,t,o){const n=o.isCollapsed,i=o.getFirstRange(),r=i.start.parent,s=i.end.parent,a=r==s;if(n){const n=Sw(e.schema,o.getAttributes());zw(e,t,i.end),t.removeSelectionAttribute(o.getAttributeKeys()),t.setSelectionAttribute(n)}else{const n=!(i.start.isAtStart&&i.end.isAtEnd);e.deleteContent(o,{leaveUnmerged:n}),a?zw(e,t,o.focus):n&&t.setSelection(s,0)}}(e,o,t.selection),this.fire("afterExecute",{writer:o})}))}refresh(){const e=this.editor.model,t=e.document;this.isEnabled=function(e,t){if(t.rangeCount>1)return!1;const o=t.anchor;if(!o||!e.checkChild(o,"softBreak"))return!1;const n=t.getFirstRange(),i=n.start.parent,r=n.end.parent;if((Vw(i,e)||Vw(r,e))&&i!==r)return!1;return!0}(e.schema,t.selection)}}function zw(e,t,o){const n=t.createElement("softBreak");e.insertContent(n,o),t.setSelection(n,"after")}function Vw(e,t){return!e.is("rootElement")&&(t.isLimit(e)||Vw(e.parent,t))}class Ow extends lr{static get pluginName(){return"ShiftEnter"}init(){const e=this.editor,t=e.model.schema,o=e.conversion,n=e.editing.view,i=n.document,r=this.editor.t;t.register("softBreak",{allowWhere:"$text",isInline:!0}),o.for("upcast").elementToElement({model:"softBreak",view:"br"}),o.for("downcast").elementToElement({model:"softBreak",view:(e,{writer:t})=>t.createEmptyElement("br")}),n.addObserver(Fw),e.commands.add("shiftEnter",new Rw(e)),this.listenTo(i,"enter",((t,o)=>{i.isComposing||o.preventDefault(),o.isSoft&&(e.execute("shiftEnter"),n.scrollToTheSelection())}),{priority:"low"}),e.accessibility.addKeystrokeInfos({keystrokes:[{label:r("Insert a soft break (a <br> element)"),keystroke:"Shift+Enter"}]})}}var Nw=i(6779),Lw={attributes:{"data-cke":!0}};Lw.setAttributes=Ar(),Lw.insert=_r().bind(null,"head"),Lw.domAPI=kr(),Lw.insertStyleElement=vr();fr()(Nw.A,Lw);Nw.A&&Nw.A.locals&&Nw.A.locals;const Hw=["before","after"],jw=(new DOMParser).parseFromString('',"image/svg+xml").firstChild,qw="ck-widget__type-around_disabled";class Uw extends lr{constructor(){super(...arguments),this._currentFakeCaretModelElement=null}static get pluginName(){return"WidgetTypeAround"}static get requires(){return[Mw,pw]}init(){const e=this.editor,t=e.editing.view;this.on("change:isEnabled",((o,n,i)=>{t.change((e=>{for(const o of t.document.roots)i?e.removeClass(qw,o):e.addClass(qw,o)})),i||e.model.change((e=>{e.removeSelectionAttribute(Sk)}))})),this._enableTypeAroundUIInjection(),this._enableInsertingParagraphsOnButtonClick(),this._enableInsertingParagraphsOnEnterKeypress(),this._enableInsertingParagraphsOnTypingKeystroke(),this._enableTypeAroundFakeCaretActivationUsingKeyboardArrows(),this._enableDeleteIntegration(),this._enableInsertContentIntegration(),this._enableInsertObjectIntegration(),this._enableDeleteContentIntegration()}destroy(){super.destroy(),this._currentFakeCaretModelElement=null}_insertParagraph(e,t){const o=this.editor,n=o.editing.view,i=o.model.schema.getAttributesWithProperty(e,"copyOnReplace",!0);o.execute("insertParagraph",{position:o.model.createPositionAt(e,t),attributes:i}),n.focus(),n.scrollToTheSelection()}_listenToIfEnabled(e,t,o,n){this.listenTo(e,t,((...e)=>{this.isEnabled&&o(...e)}),n)}_insertParagraphAccordingToFakeCaretPosition(){const e=this.editor.model.document.selection,t=Ik(e);if(!t)return!1;const o=e.getSelectedElement();return this._insertParagraph(o,t),!0}_enableTypeAroundUIInjection(){const e=this.editor,t=e.model.schema,o=e.locale.t,n={before:o("Insert paragraph before block"),after:o("Insert paragraph after block")};e.editing.downcastDispatcher.on("insert",((e,i,r)=>{const s=r.mapper.toViewElement(i.item);if(s&&Tk(s,i.item,t)){!function(e,t,o){const n=e.createUIElement("div",{class:"ck ck-reset_all ck-widget__type-around"},(function(e){const o=this.toDomElement(e);return function(e,t){for(const o of Hw){const n=new Wh({tag:"div",attributes:{class:["ck","ck-widget__type-around__button",`ck-widget__type-around__button_${o}`],title:t[o],"aria-hidden":"true"},children:[e.ownerDocument.importNode(jw,!0)]});e.appendChild(n.render())}}(o,t),function(e){const t=new Wh({tag:"div",attributes:{class:["ck","ck-widget__type-around__fake-caret"]}});e.appendChild(t.render())}(o),o}));e.insert(e.createPositionAt(o,"end"),n)}(r.writer,n,s);s.getCustomProperty("widgetLabel").push((()=>this.isEnabled?o("Press Enter to type after or press Shift + Enter to type before the widget"):""))}}),{priority:"low"})}_enableTypeAroundFakeCaretActivationUsingKeyboardArrows(){const e=this.editor,t=e.model,o=t.document.selection,n=t.schema,i=e.editing.view;function r(e){return`ck-widget_type-around_show-fake-caret_${e}`}this._listenToIfEnabled(i.document,"arrowKey",((e,t)=>{this._handleArrowKeyPress(e,t)}),{context:[Rk,"$text"],priority:"high"}),this._listenToIfEnabled(o,"change:range",((t,o)=>{o.directChange&&e.model.change((e=>{e.removeSelectionAttribute(Sk)}))})),this._listenToIfEnabled(t.document,"change:data",(()=>{const t=o.getSelectedElement();if(t){if(Tk(e.editing.mapper.toViewElement(t),t,n))return}e.model.change((e=>{e.removeSelectionAttribute(Sk)}))})),this._listenToIfEnabled(e.editing.downcastDispatcher,"selection",((e,t,o)=>{const i=o.writer;if(this._currentFakeCaretModelElement){const e=o.mapper.toViewElement(this._currentFakeCaretModelElement);e&&(i.removeClass(Hw.map(r),e),this._currentFakeCaretModelElement=null)}const s=t.selection.getSelectedElement();if(!s)return;const a=o.mapper.toViewElement(s);if(!Tk(a,s,n))return;const l=Ik(t.selection);l&&(i.addClass(r(l),a),this._currentFakeCaretModelElement=s)})),this._listenToIfEnabled(e.ui.focusTracker,"change:isFocused",((t,o,n)=>{n||e.model.change((e=>{e.removeSelectionAttribute(Sk)}))}))}_handleArrowKeyPress(e,t){const o=this.editor,n=o.model,i=n.document.selection,r=n.schema,s=o.editing.view,a=function(e,t){const o=Ci(e,t);return"down"===o||"right"===o}(t.keyCode,o.locale.contentLanguageDirection),l=s.document.selection.getSelectedElement();let c;Tk(l,o.editing.mapper.toModelElement(l),r)?c=this._handleArrowKeyPressOnSelectedWidget(a):i.isCollapsed?c=this._handleArrowKeyPressWhenSelectionNextToAWidget(a):t.shiftKey||(c=this._handleArrowKeyPressWhenNonCollapsedSelection(a)),c&&(t.preventDefault(),e.stop())}_handleArrowKeyPressOnSelectedWidget(e){const t=this.editor.model,o=Ik(t.document.selection);return t.change((t=>{if(!o)return t.setSelectionAttribute(Sk,e?"after":"before"),!0;if(!(o===(e?"after":"before")))return t.removeSelectionAttribute(Sk),!0;return!1}))}_handleArrowKeyPressWhenSelectionNextToAWidget(e){const t=this.editor,o=t.model,n=o.schema,i=t.plugins.get("Widget"),r=i._getObjectElementNextToSelection(e);return!!Tk(t.editing.mapper.toViewElement(r),r,n)&&(o.change((t=>{i._setSelectionOverElement(r),t.setSelectionAttribute(Sk,e?"before":"after")})),!0)}_handleArrowKeyPressWhenNonCollapsedSelection(e){const t=this.editor,o=t.model,n=o.schema,i=t.editing.mapper,r=o.document.selection,s=e?r.getLastPosition().nodeBefore:r.getFirstPosition().nodeAfter;return!!Tk(i.toViewElement(s),s,n)&&(o.change((t=>{t.setSelection(s,"on"),t.setSelectionAttribute(Sk,e?"after":"before")})),!0)}_enableInsertingParagraphsOnButtonClick(){const e=this.editor,t=e.editing.view;this._listenToIfEnabled(t.document,"mousedown",((o,n)=>{const i=n.domTarget.closest(".ck-widget__type-around__button");if(!i)return;const r=function(e){return e.classList.contains("ck-widget__type-around__button_before")?"before":"after"}(i),s=function(e,t){const o=e.closest(".ck-widget");return t.mapDomToView(o)}(i,t.domConverter),a=e.editing.mapper.toModelElement(s);this._insertParagraph(a,r),n.preventDefault(),o.stop()}))}_enableInsertingParagraphsOnEnterKeypress(){const e=this.editor,t=e.model.document.selection,o=e.editing.view;this._listenToIfEnabled(o.document,"enter",((o,n)=>{if("atTarget"!=o.eventPhase)return;const i=t.getSelectedElement(),r=e.editing.mapper.toViewElement(i),s=e.model.schema;let a;this._insertParagraphAccordingToFakeCaretPosition()?a=!0:Tk(r,i,s)&&(this._insertParagraph(i,n.isSoft?"before":"after"),a=!0),a&&(n.preventDefault(),o.stop())}),{context:Rk})}_enableInsertingParagraphsOnTypingKeystroke(){const e=this.editor.editing.view.document;this._listenToIfEnabled(e,"insertText",((t,o)=>{this._insertParagraphAccordingToFakeCaretPosition()&&(o.selection=e.selection)}),{priority:"high"}),r.isAndroid?this._listenToIfEnabled(e,"keydown",((e,t)=>{229==t.keyCode&&this._insertParagraphAccordingToFakeCaretPosition()})):this._listenToIfEnabled(e,"compositionstart",(()=>{this._insertParagraphAccordingToFakeCaretPosition()}),{priority:"high"})}_enableDeleteIntegration(){const e=this.editor,t=e.editing.view,o=e.model,n=o.schema;this._listenToIfEnabled(t.document,"delete",((t,i)=>{if("atTarget"!=t.eventPhase)return;const r=Ik(o.document.selection);if(!r)return;const s=i.direction,a=o.document.selection.getSelectedElement(),l="forward"==s;if("before"===r===l)e.execute("delete",{selection:o.createSelection(a,"on")});else{const t=n.getNearestSelectionRange(o.createPositionAt(a,r),s);if(t)if(t.isCollapsed){const i=o.createSelection(t.start);if(o.modifySelection(i,{direction:s}),i.focus.isEqual(t.start)){const e=function(e,t){let o=t;for(const n of t.getAncestors({parentFirst:!0})){if(n.childCount>1||e.isLimit(n))break;o=n}return o}(n,t.start.parent);o.deleteContent(o.createSelection(e,"on"),{doNotAutoparagraph:!0})}else o.change((o=>{o.setSelection(t),e.execute(l?"deleteForward":"delete")}))}else o.change((o=>{o.setSelection(t),e.execute(l?"deleteForward":"delete")}))}i.preventDefault(),t.stop()}),{context:Rk})}_enableInsertContentIntegration(){const e=this.editor,t=this.editor.model,o=t.document.selection;this._listenToIfEnabled(e.model,"insertContent",((e,[n,i])=>{if(i&&!i.is("documentSelection"))return;const r=Ik(o);return r?(e.stop(),t.change((e=>{const i=o.getSelectedElement(),s=t.createPositionAt(i,r),a=e.createSelection(s),l=t.insertContent(n,a);return e.setSelection(a),l}))):void 0}),{priority:"high"})}_enableInsertObjectIntegration(){const e=this.editor,t=this.editor.model.document.selection;this._listenToIfEnabled(e.model,"insertObject",((e,o)=>{const[,n,i={}]=o;if(n&&!n.is("documentSelection"))return;const r=Ik(t);r&&(i.findOptimalPosition=r,o[3]=i)}),{priority:"high"})}_enableDeleteContentIntegration(){const e=this.editor,t=this.editor.model.document.selection;this._listenToIfEnabled(e.model,"deleteContent",((e,[o])=>{if(o&&!o.is("documentSelection"))return;Ik(t)&&e.stop()}),{priority:"high"})}}function Ww(e){const t=e.model;return(o,n)=>{const i=n.keyCode==ki.arrowup,r=n.keyCode==ki.arrowdown,s=n.shiftKey,a=t.document.selection;if(!i&&!r)return;const l=r;if(s&&function(e,t){return!e.isCollapsed&&e.isBackward==t}(a,l))return;const c=function(e,t,o){const n=e.model;if(o){const e=t.isCollapsed?t.focus:t.getLastPosition(),o=$w(n,e,"forward");if(!o)return null;const i=n.createRange(e,o),r=Gw(n.schema,i,"backward");return r?n.createRange(e,r):null}{const e=t.isCollapsed?t.focus:t.getFirstPosition(),o=$w(n,e,"backward");if(!o)return null;const i=n.createRange(o,e),r=Gw(n.schema,i,"forward");return r?n.createRange(r,e):null}}(e,a,l);if(c){if(c.isCollapsed){if(a.isCollapsed)return;if(s)return}(c.isCollapsed||function(e,t,o){const n=e.model,i=e.view.domConverter;if(o){const e=n.createSelection(t.start);n.modifySelection(e),e.focus.isAtEnd||t.start.isEqual(e.focus)||(t=n.createRange(e.focus,t.end))}const r=e.mapper.toViewRange(t),s=i.viewRangeToDom(r),a=qn.getDomRangeRects(s);let l;for(const e of a)if(void 0!==l){if(Math.round(e.top)>=l)return!1;l=Math.max(l,Math.round(e.bottom))}else l=Math.round(e.bottom);return!0}(e,c,l))&&(t.change((e=>{const o=l?c.end:c.start;if(s){const n=t.createSelection(a.anchor);n.setFocus(o),e.setSelection(n)}else e.setSelection(o)})),o.stop(),n.preventDefault(),n.stopPropagation())}}}function $w(e,t,o){const n=e.schema,i=e.createRangeIn(t.root),r="forward"==o?"elementStart":"elementEnd";for(const{previousPosition:e,item:s,type:a}of i.getWalker({startPosition:t,direction:o})){if(n.isLimit(s)&&!n.isInline(s))return e;if(a==r&&n.isBlock(s))return null}return null}function Gw(e,t,o){const n="backward"==o?t.end:t.start;if(e.checkChild(n,"$text"))return n;for(const{nextPosition:n}of t.getWalker({direction:o}))if(e.checkChild(n,"$text"))return n;return null}var Kw=i(1216),Zw={attributes:{"data-cke":!0}};Zw.setAttributes=Ar(),Zw.insert=_r().bind(null,"head"),Zw.domAPI=kr(),Zw.insertStyleElement=vr();fr()(Kw.A,Zw);Kw.A&&Kw.A.locals&&Kw.A.locals;class Jw extends lr{constructor(){super(...arguments),this._previouslySelected=new Set}static get pluginName(){return"Widget"}static get requires(){return[Uw,pw]}init(){const e=this.editor,t=e.editing.view,o=t.document,n=e.t;this.editor.editing.downcastDispatcher.on("selection",((t,o,n)=>{const i=n.writer,r=o.selection;if(r.isCollapsed)return;const s=r.getSelectedElement();if(!s)return;const a=e.editing.mapper.toViewElement(s);var l;Rk(a)&&(n.consumable.consume(r,"selection")&&i.setSelection(i.createRangeOn(a),{fake:!0,label:(l=a,l.getCustomProperty("widgetLabel").reduce(((e,t)=>"function"==typeof t?e?e+". "+t():t():e?e+". "+t:t),""))}))})),this.editor.editing.downcastDispatcher.on("selection",((e,t,o)=>{this._clearPreviouslySelectedWidgets(o.writer);const n=o.writer,i=n.document.selection;let r=null;for(const e of i.getRanges())for(const t of e){const e=t.item;Rk(e)&&!Yw(e,r)&&(n.addClass(Mk,e),this._previouslySelected.add(e),r=e)}}),{priority:"low"}),t.addObserver(Nu),this.listenTo(o,"mousedown",((...e)=>this._onMousedown(...e))),this.listenTo(o,"arrowKey",((...e)=>{this._handleSelectionChangeOnArrowKeyPress(...e)}),{context:[Rk,"$text"]}),this.listenTo(o,"arrowKey",((...e)=>{this._preventDefaultOnArrowKeyPress(...e)}),{context:"$root"}),this.listenTo(o,"arrowKey",Ww(this.editor.editing),{context:"$text"}),this.listenTo(o,"delete",((e,t)=>{this._handleDelete("forward"==t.direction)&&(t.preventDefault(),e.stop())}),{context:"$root"}),this.listenTo(o,"tab",((e,t)=>{"atTarget"==e.eventPhase&&(t.shiftKey||this._selectFirstNestedEditable()&&(t.preventDefault(),e.stop()))}),{context:Rk,priority:"low"}),this.listenTo(o,"tab",((e,t)=>{t.shiftKey&&this._selectAncestorWidget()&&(t.preventDefault(),e.stop())}),{priority:"low"}),this.listenTo(o,"keydown",((e,t)=>{t.keystroke==ki.esc&&this._selectAncestorWidget()&&(t.preventDefault(),e.stop())}),{priority:"low"}),e.accessibility.addKeystrokeInfoGroup({id:"widget",label:n("Keystrokes that can be used when a widget is selected (for example: image, table, etc.)"),keystrokes:[{label:n("Move focus from an editable area back to the parent widget"),keystroke:"Esc"},{label:n("Insert a new paragraph directly after a widget"),keystroke:"Enter"},{label:n("Insert a new paragraph directly before a widget"),keystroke:"Shift+Enter"},{label:n("Move the caret to allow typing directly before a widget"),keystroke:[["arrowup"],["arrowleft"]]},{label:n("Move the caret to allow typing directly after a widget"),keystroke:[["arrowdown"],["arrowright"]]}]})}_onMousedown(e,t){const o=this.editor,n=o.editing.view,i=n.document;let s=t.target;if(t.domEvent.detail>=3)return void(this._selectBlockContent(s)&&t.preventDefault());if(function(e){let t=e;for(;t;){if(t.is("editableElement")&&!t.is("rootElement"))return!0;if(Rk(t))return!1;t=t.parent}return!1}(s))return;if(!Rk(s)&&(s=s.findAncestor(Rk),!s))return;r.isAndroid&&t.preventDefault(),i.isFocused||n.focus();const a=o.editing.mapper.toModelElement(s);this._setSelectionOverElement(a)}_selectBlockContent(e){const t=this.editor,o=t.model,n=t.editing.mapper,i=o.schema,r=n.findMappedViewAncestor(this.editor.editing.view.createPositionAt(e,0)),s=function(e,t){for(const o of e.getAncestors({includeSelf:!0,parentFirst:!0})){if(t.checkChild(o,"$text"))return o;if(t.isLimit(o)&&!t.isObject(o))break}return null}(n.toModelElement(r),o.schema);return!!s&&(o.change((e=>{const t=i.isLimit(s)?null:function(e,t){const o=new Hl({startPosition:e});for(const{item:e}of o){if(t.isLimit(e)||!e.is("element"))return null;if(t.checkChild(e,"$text"))return e}return null}(e.createPositionAfter(s),i),o=e.createPositionAt(s,0),n=t?e.createPositionAt(t,0):e.createPositionAt(s,"end");e.setSelection(e.createRange(o,n))})),!0)}_handleSelectionChangeOnArrowKeyPress(e,t){const o=t.keyCode,n=this.editor.model,i=n.schema,r=n.document.selection,s=r.getSelectedElement(),a=Ci(o,this.editor.locale.contentLanguageDirection),l="down"==a||"right"==a,c="up"==a||"down"==a;if(s&&i.isObject(s)){const o=l?r.getLastPosition():r.getFirstPosition(),s=i.getNearestSelectionRange(o,l?"forward":"backward");return void(s&&(n.change((e=>{e.setSelection(s)})),t.preventDefault(),e.stop()))}if(!r.isCollapsed&&!t.shiftKey){const o=r.getFirstPosition(),s=r.getLastPosition(),a=o.nodeAfter,c=s.nodeBefore;return void((a&&i.isObject(a)||c&&i.isObject(c))&&(n.change((e=>{e.setSelection(l?s:o)})),t.preventDefault(),e.stop()))}if(!r.isCollapsed)return;const d=this._getObjectElementNextToSelection(l);if(d&&i.isObject(d)){if(i.isInline(d)&&c)return;this._setSelectionOverElement(d),t.preventDefault(),e.stop()}}_preventDefaultOnArrowKeyPress(e,t){const o=this.editor.model,n=o.schema,i=o.document.selection.getSelectedElement();i&&n.isObject(i)&&(t.preventDefault(),e.stop())}_handleDelete(e){const t=this.editor.model.document.selection;if(!this.editor.model.canEditAt(t))return;if(!t.isCollapsed)return;const o=this._getObjectElementNextToSelection(e);return o?(this.editor.model.change((e=>{let n=t.anchor.parent;for(;n.isEmpty;){const t=n;n=t.parent,e.remove(t)}this._setSelectionOverElement(o)})),!0):void 0}_setSelectionOverElement(e){this.editor.model.change((t=>{t.setSelection(t.createRangeOn(e))}))}_getObjectElementNextToSelection(e){const t=this.editor.model,o=t.schema,n=t.document.selection,i=t.createSelection(n);if(t.modifySelection(i,{direction:e?"forward":"backward"}),i.isEqual(n))return null;const r=e?i.focus.nodeBefore:i.focus.nodeAfter;return r&&o.isObject(r)?r:null}_clearPreviouslySelectedWidgets(e){for(const t of this._previouslySelected)e.removeClass(Mk,t);this._previouslySelected.clear()}_selectFirstNestedEditable(){const e=this.editor,t=this.editor.editing.view.document;for(const o of t.selection.getFirstRange().getItems())if(o.is("editableElement")){const t=e.editing.mapper.toModelElement(o);if(!t)continue;const n=e.model.createPositionAt(t,0),i=e.model.schema.getNearestSelectionRange(n,"forward");return e.model.change((e=>{e.setSelection(i)})),!0}return!1}_selectAncestorWidget(){const e=this.editor,t=e.editing.mapper,o=e.editing.view.document.selection.getFirstPosition().parent,n=(o.is("$text")?o.parent:o).findAncestor(Rk);if(!n)return!1;const i=t.toModelElement(n);return!!i&&(e.model.change((e=>{e.setSelection(i,"on")})),!0)}}function Yw(e,t){return!!t&&Array.from(e.getAncestors()).includes(t)}class Qw extends lr{constructor(){super(...arguments),this._toolbarDefinitions=new Map}static get requires(){return[Fb]}static get pluginName(){return"WidgetToolbarRepository"}init(){const e=this.editor;if(e.plugins.has("BalloonToolbar")){const t=e.plugins.get("BalloonToolbar");this.listenTo(t,"show",(t=>{(function(e){const t=e.getSelectedElement();return!(!t||!Rk(t))})(e.editing.view.document.selection)&&t.stop()}),{priority:"high"})}this._balloon=this.editor.plugins.get("ContextualBalloon"),this.on("change:isEnabled",(()=>{this._updateToolbarsVisibility()})),this.listenTo(e.ui,"update",(()=>{this._updateToolbarsVisibility()})),this.listenTo(e.ui.focusTracker,"change:isFocused",(()=>{this._updateToolbarsVisibility()}),{priority:"low"})}destroy(){super.destroy();for(const e of this._toolbarDefinitions.values())e.view.destroy()}register(e,{ariaLabel:t,items:o,getRelatedElement:n,balloonClassName:i="ck-toolbar-container"}){if(!o.length)return void D("widget-toolbar-no-items",{toolbarId:e});const r=this.editor,s=r.t,a=new cg(r.locale);if(a.ariaLabel=t||s("Widget toolbar"),this._toolbarDefinitions.has(e))throw new E("widget-toolbar-duplicated",this,{toolbarId:e});const l={view:a,getRelatedElement:n,balloonClassName:i,itemsConfig:o,initialized:!1};r.ui.addToolbar(a,{isContextual:!0,beforeFocus:()=>{const e=n(r.editing.view.document.selection);e&&this._showToolbar(l,e)},afterBlur:()=>{this._hideToolbar(l)}}),this._toolbarDefinitions.set(e,l)}_updateToolbarsVisibility(){let e=0,t=null,o=null;for(const n of this._toolbarDefinitions.values()){const i=n.getRelatedElement(this.editor.editing.view.document.selection);if(this.isEnabled&&i)if(this.editor.ui.focusTracker.isFocused){const r=i.getAncestors().length;r>e&&(e=r,t=i,o=n)}else this._isToolbarVisible(n)&&this._hideToolbar(n);else this._isToolbarInBalloon(n)&&this._hideToolbar(n)}o&&this._showToolbar(o,t)}_hideToolbar(e){this._balloon.remove(e.view),this.stopListening(this._balloon,"change:visibleView")}_showToolbar(e,t){this._isToolbarVisible(e)?Xw(this.editor,t):this._isToolbarInBalloon(e)||(e.initialized||(e.initialized=!0,e.view.fillFromConfig(e.itemsConfig,this.editor.ui.componentFactory)),this._balloon.add({view:e.view,position:e_(this.editor,t),balloonClassName:e.balloonClassName}),this.listenTo(this._balloon,"change:visibleView",(()=>{for(const e of this._toolbarDefinitions.values())if(this._isToolbarVisible(e)){const t=e.getRelatedElement(this.editor.editing.view.document.selection);Xw(this.editor,t)}})))}_isToolbarVisible(e){return this._balloon.visibleView===e.view}_isToolbarInBalloon(e){return this._balloon.hasView(e.view)}}function Xw(e,t){const o=e.plugins.get("ContextualBalloon"),n=e_(e,t);o.updatePosition(n)}function e_(e,t){const o=e.editing.view,n=Ff.defaultPositions;return{target:o.domConverter.mapViewToDom(t),positions:[n.northArrowSouth,n.northArrowSouthWest,n.northArrowSouthEast,n.southArrowNorth,n.southArrowNorthWest,n.southArrowNorthEast,n.viewportStickyNorth]}}class t_ extends(Y()){constructor(e){super(),this.set("activeHandlePosition",null),this.set("proposedWidthPercents",null),this.set("proposedWidth",null),this.set("proposedHeight",null),this.set("proposedHandleHostWidth",null),this.set("proposedHandleHostHeight",null),this._options=e,this._referenceCoordinates=null}get originalWidth(){return this._originalWidth}get originalHeight(){return this._originalHeight}get originalWidthPercents(){return this._originalWidthPercents}get aspectRatio(){return this._aspectRatio}begin(e,t,o){const n=new qn(t);this.activeHandlePosition=function(e){const t=["top-left","top-right","bottom-right","bottom-left"];for(const o of t)if(e.classList.contains(o_(o)))return o}(e),this._referenceCoordinates=function(e,t){const o=new qn(e),n=t.split("-"),i={x:"right"==n[1]?o.right:o.left,y:"bottom"==n[0]?o.bottom:o.top};return i.x+=e.ownerDocument.defaultView.scrollX,i.y+=e.ownerDocument.defaultView.scrollY,i}(t,function(e){const t=e.split("-"),o={top:"bottom",bottom:"top",left:"right",right:"left"};return`${o[t[0]]}-${o[t[1]]}`}(this.activeHandlePosition)),this._originalWidth=n.width,this._originalHeight=n.height,this._aspectRatio=n.width/n.height;const i=o.style.width;i&&i.match(/^\d+(\.\d*)?%$/)?this._originalWidthPercents=parseFloat(i):this._originalWidthPercents=function(e,t=new qn(e)){const o=jk(e);return o?t.width/o*100:0}(o,n)}update(e){this.proposedWidth=e.width,this.proposedHeight=e.height,this.proposedWidthPercents=e.widthPercents,this.proposedHandleHostWidth=e.handleHostWidth,this.proposedHandleHostHeight=e.handleHostHeight}}function o_(e){return`ck-widget__resizer__handle-${e}`}class n_ extends pm{constructor(){super();const e=this.bindTemplate;this.setTemplate({tag:"div",attributes:{class:["ck","ck-size-view",e.to("_viewPosition",(e=>e?`ck-orientation-${e}`:""))],style:{display:e.if("_isVisible","none",(e=>!e))}},children:[{text:e.to("_label")}]})}_bindToState(e,t){this.bind("_isVisible").to(t,"proposedWidth",t,"proposedHeight",((e,t)=>null!==e&&null!==t)),this.bind("_label").to(t,"proposedHandleHostWidth",t,"proposedHandleHostHeight",t,"proposedWidthPercents",((t,o,n)=>"px"===e.unit?`${t}×${o}`:`${n}%`)),this.bind("_viewPosition").to(t,"activeHandlePosition",t,"proposedHandleHostWidth",t,"proposedHandleHostHeight",((e,t,o)=>t<50||o<50?"above-center":e))}_dismiss(){this.unbind(),this._isVisible=!1}}class i_ extends(Y()){constructor(e){super(),this._viewResizerWrapper=null,this._options=e,this.set("isEnabled",!0),this.set("isSelected",!1),this.bind("isVisible").to(this,"isEnabled",this,"isSelected",((e,t)=>e&&t)),this.decorate("begin"),this.decorate("cancel"),this.decorate("commit"),this.decorate("updateSize"),this.on("commit",(e=>{this.state.proposedWidth||this.state.proposedWidthPercents||(this._cleanup(),e.stop())}),{priority:"high"})}get state(){return this._state}show(){this._options.editor.editing.view.change((e=>{e.removeClass("ck-hidden",this._viewResizerWrapper)}))}hide(){this._options.editor.editing.view.change((e=>{e.addClass("ck-hidden",this._viewResizerWrapper)}))}attach(){const e=this,t=this._options.viewElement;this._options.editor.editing.view.change((o=>{const n=o.createUIElement("div",{class:"ck ck-reset_all ck-widget__resizer"},(function(t){const o=this.toDomElement(t);return e._appendHandles(o),e._appendSizeUI(o),o}));o.insert(o.createPositionAt(t,"end"),n),o.addClass("ck-widget_with-resizer",t),this._viewResizerWrapper=n,this.isVisible||this.hide()})),this.on("change:isVisible",(()=>{this.isVisible?(this.show(),this.redraw()):this.hide()}))}begin(e){this._state=new t_(this._options),this._sizeView._bindToState(this._options,this.state),this._initialViewWidth=this._options.viewElement.getStyle("width"),this.state.begin(e,this._getHandleHost(),this._getResizeHost())}updateSize(e){const t=this._proposeNewSize(e);this._options.editor.editing.view.change((e=>{const o=this._options.unit||"%",n=("%"===o?t.widthPercents:t.width)+o;e.setStyle("width",n,this._options.viewElement)}));const o=this._getHandleHost(),n=new qn(o),i=Math.round(n.width),r=Math.round(n.height),s=new qn(o);t.width=Math.round(s.width),t.height=Math.round(s.height),this.redraw(n),this.state.update({...t,handleHostWidth:i,handleHostHeight:r})}commit(){const e=this._options.unit||"%",t=("%"===e?this.state.proposedWidthPercents:this.state.proposedWidth)+e;this._options.editor.editing.view.change((()=>{this._cleanup(),this._options.onCommit(t)}))}cancel(){this._cleanup()}destroy(){this.cancel()}redraw(e){const t=this._domResizerWrapper;if(!((o=t)&&o.ownerDocument&&o.ownerDocument.contains(o)))return;var o;const n=t.parentElement,i=this._getHandleHost(),r=this._viewResizerWrapper,s=[r.getStyle("width"),r.getStyle("height"),r.getStyle("left"),r.getStyle("top")];let a;if(n.isSameNode(i)){const t=e||new qn(i);a=[t.width+"px",t.height+"px",void 0,void 0]}else a=[i.offsetWidth+"px",i.offsetHeight+"px",i.offsetLeft+"px",i.offsetTop+"px"];"same"!==ie(s,a)&&this._options.editor.editing.view.change((e=>{e.setStyle({width:a[0],height:a[1],left:a[2],top:a[3]},r)}))}containsHandle(e){return this._domResizerWrapper.contains(e)}static isResizeHandle(e){return e.classList.contains("ck-widget__resizer__handle")}_cleanup(){this._sizeView._dismiss();this._options.editor.editing.view.change((e=>{e.setStyle("width",this._initialViewWidth,this._options.viewElement)}))}_proposeNewSize(e){const t=this.state,o={x:(n=e).pageX,y:n.pageY};var n;const i=!this._options.isCentered||this._options.isCentered(this),r={x:t._referenceCoordinates.x-(o.x+t.originalWidth),y:o.y-t.originalHeight-t._referenceCoordinates.y};i&&t.activeHandlePosition.endsWith("-right")&&(r.x=o.x-(t._referenceCoordinates.x+t.originalWidth)),i&&(r.x*=2);let s=Math.abs(t.originalWidth+r.x),a=Math.abs(t.originalHeight+r.y);return"width"==(s/t.aspectRatio>a?"width":"height")?a=s/t.aspectRatio:s=a*t.aspectRatio,{width:Math.round(s),height:Math.round(a),widthPercents:Math.min(Math.round(t.originalWidthPercents/t.originalWidth*s*100)/100,100)}}_getResizeHost(){const e=this._domResizerWrapper.parentElement;return this._options.getResizeHost(e)}_getHandleHost(){const e=this._domResizerWrapper.parentElement;return this._options.getHandleHost(e)}get _domResizerWrapper(){return this._options.editor.editing.view.domConverter.mapViewToDom(this._viewResizerWrapper)}_appendHandles(e){const t=["top-left","top-right","bottom-right","bottom-left"];for(const n of t)e.appendChild(new Wh({tag:"div",attributes:{class:"ck-widget__resizer__handle "+(o=n,`ck-widget__resizer__handle-${o}`)}}).render());var o}_appendSizeUI(e){this._sizeView=new n_,this._sizeView.render(),e.appendChild(this._sizeView.element)}}var r_=i(2060),s_={attributes:{"data-cke":!0}};s_.setAttributes=Ar(),s_.insert=_r().bind(null,"head"),s_.domAPI=kr(),s_.insertStyleElement=vr();fr()(r_.A,s_);r_.A&&r_.A.locals&&r_.A.locals;class a_ extends lr{constructor(){super(...arguments),this._resizers=new Map}static get pluginName(){return"WidgetResize"}init(){const e=this.editor.editing,o=t.window.document;this.set("selectedResizer",null),this.set("_activeResizer",null),e.view.addObserver(Nu),this._observer=new(Rn()),this.listenTo(e.view.document,"mousedown",this._mouseDownListener.bind(this),{priority:"high"}),this._observer.listenTo(o,"mousemove",this._mouseMoveListener.bind(this)),this._observer.listenTo(o,"mouseup",this._mouseUpListener.bind(this)),this._redrawSelectedResizerThrottled=Bh((()=>this.redrawSelectedResizer()),200),this.editor.ui.on("update",this._redrawSelectedResizerThrottled),this.editor.model.document.on("change",(()=>{for(const[e,t]of this._resizers)e.isAttached()||(this._resizers.delete(e),t.destroy())}),{priority:"lowest"}),this._observer.listenTo(t.window,"resize",this._redrawSelectedResizerThrottled);const n=this.editor.editing.view.document.selection;n.on("change",(()=>{const e=n.getSelectedElement(),t=this.getResizerByViewElement(e)||null;t?this.select(t):this.deselect()}))}redrawSelectedResizer(){this.selectedResizer&&this.selectedResizer.isVisible&&this.selectedResizer.redraw()}destroy(){super.destroy(),this._observer.stopListening();for(const e of this._resizers.values())e.destroy();this._redrawSelectedResizerThrottled.cancel()}select(e){this.deselect(),this.selectedResizer=e,this.selectedResizer.isSelected=!0}deselect(){this.selectedResizer&&(this.selectedResizer.isSelected=!1),this.selectedResizer=null}attachTo(e){const t=new i_(e),o=this.editor.plugins;if(t.attach(),o.has("WidgetToolbarRepository")){const e=o.get("WidgetToolbarRepository");t.on("begin",(()=>{e.forceDisabled("resize")}),{priority:"lowest"}),t.on("cancel",(()=>{e.clearForceDisabled("resize")}),{priority:"highest"}),t.on("commit",(()=>{e.clearForceDisabled("resize")}),{priority:"highest"})}this._resizers.set(e.viewElement,t);const n=this.editor.editing.view.document.selection.getSelectedElement();return this.getResizerByViewElement(n)==t&&this.select(t),t}getResizerByViewElement(e){return this._resizers.get(e)}_getResizerByHandle(e){for(const t of this._resizers.values())if(t.containsHandle(e))return t}_mouseDownListener(e,t){const o=t.domTarget;i_.isResizeHandle(o)&&(this._activeResizer=this._getResizerByHandle(o)||null,this._activeResizer&&(this._activeResizer.begin(o),e.stop(),t.preventDefault()))}_mouseMoveListener(e,t){this._activeResizer&&this._activeResizer.updateSize(t)}_mouseUpListener(){this._activeResizer&&(this._activeResizer.commit(),this._activeResizer=null)}}function l_(e,t,o){e.ui.componentFactory.add(t,(t=>{const n=new Em(t);return n.set({label:I18n.t("js.button_edit"),icon:'\n',tooltip:!0}),n.on("execute",(()=>{const t=e.model.document.selection.getSelectedElement();t&&o(t)})),n}))}const c_="ck-toolbar-container";function d_(e,t,o,n){const i=t.config.get(o+".toolbar");if(!i||!i.length)return;const r=t.plugins.get("ContextualBalloon"),s=new cg(t.locale);function a(){t.ui.focusTracker.isFocused&&n(t.editing.view.document.selection)?c()?function(e,t){const o=e.plugins.get("ContextualBalloon");if(t(e.editing.view.document.selection)){const t=u_(e);o.updatePosition(t)}}(t,n):r.hasView(s)||r.add({view:s,position:u_(t),balloonClassName:c_}):l()}function l(){c()&&r.remove(s)}function c(){return r.visibleView==s}s.fillFromConfig(i,t.ui.componentFactory),e.listenTo(t.editing.view,"render",a),e.listenTo(t.ui.focusTracker,"change:isFocused",a,{priority:"low"})}function u_(e){const t=e.editing.view,o=Ff.defaultPositions;return{target:t.domConverter.viewToDom(t.document.selection.getSelectedElement()),positions:[o.northArrowSouth,o.northArrowSouthWest,o.northArrowSouthEast,o.southArrowNorth,o.southArrowNorthWest,o.southArrowNorthEast]}}class h_ extends lr{static get requires(){return[Fb]}static get pluginName(){return"EmbeddedTableToolbar"}init(){const e=this.editor,t=this.editor.model,o=Gk(e);l_(e,"opEditEmbeddedTableQuery",(e=>{const n=o.services.externalQueryConfiguration,i=e.getAttribute("opEmbeddedTableQuery")||{};o.runInZone((()=>{n.show({currentQuery:i,callback:o=>t.change((t=>{t.setAttribute("opEmbeddedTableQuery",o,e)}))})}))}))}afterInit(){d_(this,this.editor,"OPMacroEmbeddedTable",Wk)}}const m_=Symbol("isWpButtonMacroSymbol");function p_(e){const t=e.getSelectedElement();return!(!t||!function(e){return!!e.getCustomProperty(m_)&&Rk(e)}(t))}class g_ extends lr{static get pluginName(){return"OPMacroWpButtonEditing"}static get buttonName(){return"insertWorkPackageButton"}init(){const e=this.editor,t=e.model,o=e.conversion,n=Gk(e);t.schema.register("op-macro-wp-button",{allowWhere:["$block"],allowAttributes:["type","classes"],isBlock:!0,isLimit:!0}),o.for("upcast").elementToElement({view:{name:"macro",classes:"create_work_package_link"},model:(e,{writer:t})=>{const o=e.getAttribute("data-type")||"",n=e.getAttribute("data-classes")||"";return t.createElement("op-macro-wp-button",{type:o,classes:n})}}),o.for("editingDowncast").elementToElement({model:"op-macro-wp-button",view:(e,{writer:t})=>this.createMacroViewElement(e,t)}),o.for("dataDowncast").elementToElement({model:"op-macro-wp-button",view:(e,{writer:t})=>t.createContainerElement("macro",{class:"create_work_package_link","data-type":e.getAttribute("type")||"","data-classes":e.getAttribute("classes")||""})}),e.ui.componentFactory.add(g_.buttonName,(t=>{const o=new Em(t);return o.set({label:window.I18n.t("js.editor.macro.work_package_button.button"),withText:!0}),o.on("execute",(()=>{n.services.macros.configureWorkPackageButton().then((t=>e.model.change((o=>{const n=o.createElement("op-macro-wp-button",{});o.setAttribute("type",t.type,n),o.setAttribute("classes",t.classes,n),e.model.insertContent(n,e.model.document.selection)}))))})),o}))}macroLabel(e){return e?window.I18n.t("js.editor.macro.work_package_button.with_type",{typename:e}):window.I18n.t("js.editor.macro.work_package_button.without_type")}createMacroViewElement(e,t){e.getAttribute("type");const o=e.getAttribute("classes")||"",n=this.macroLabel(),i=t.createText(n),r=t.createContainerElement("span",{class:o});return t.insert(t.createPositionAt(r,0),i),function(e,t,o){return t.setCustomProperty(m_,!0,e),zk(e,t,{label:o})}(r,t,{label:n})}}class f_ extends lr{static get requires(){return[Fb]}static get pluginName(){return"OPMacroWpButtonToolbar"}init(){const e=this.editor,t=(this.editor.model,Gk(e));l_(e,"opEditWpMacroButton",(o=>{const n=t.services.macros,i=o.getAttribute("type"),r=o.getAttribute("classes");n.configureWorkPackageButton(i,r).then((t=>e.model.change((e=>{e.setAttribute("classes",t.classes,o),e.setAttribute("type",t.type,o)}))))}))}afterInit(){d_(this,this.editor,"OPMacroWpButton",p_)}}class b_ extends(Y()){constructor(){super();const e=new window.FileReader;this._reader=e,this._data=void 0,this.set("loaded",0),e.onprogress=e=>{this.loaded=e.loaded}}get error(){return this._reader.error}get data(){return this._data}read(e){const t=this._reader;return this.total=e.size,new Promise(((o,n)=>{t.onload=()=>{const e=t.result;this._data=e,o(e)},t.onerror=()=>{n("error")},t.onabort=()=>{n("aborted")},this._reader.readAsDataURL(e)}))}abort(){this._reader.abort()}}class k_ extends lr{constructor(){super(...arguments),this.loaders=new Yi,this._loadersMap=new Map,this._pendingAction=null}static get pluginName(){return"FileRepository"}static get requires(){return[jh]}init(){this.loaders.on("change",(()=>this._updatePendingAction())),this.set("uploaded",0),this.set("uploadTotal",null),this.bind("uploadedPercent").to(this,"uploaded",this,"uploadTotal",((e,t)=>t?e/t*100:0))}getLoader(e){return this._loadersMap.get(e)||null}createLoader(e){if(!this.createUploadAdapter)return D("filerepository-no-upload-adapter"),null;const t=new w_(Promise.resolve(e),this.createUploadAdapter);return this.loaders.add(t),this._loadersMap.set(e,t),e instanceof Promise&&t.file.then((e=>{this._loadersMap.set(e,t)})).catch((()=>{})),t.on("change:uploaded",(()=>{let e=0;for(const t of this.loaders)e+=t.uploaded;this.uploaded=e})),t.on("change:uploadTotal",(()=>{let e=0;for(const t of this.loaders)t.uploadTotal&&(e+=t.uploadTotal);this.uploadTotal=e})),t}destroyLoader(e){const t=e instanceof w_?e:this.getLoader(e);t._destroy(),this.loaders.remove(t),this._loadersMap.forEach(((e,o)=>{e===t&&this._loadersMap.delete(o)}))}_updatePendingAction(){const e=this.editor.plugins.get(jh);if(this.loaders.length){if(!this._pendingAction){const t=this.editor.t,o=e=>`${t("Upload in progress")} ${parseInt(e)}%.`;this._pendingAction=e.add(o(this.uploadedPercent)),this._pendingAction.bind("message").to(this,"uploadedPercent",o)}}else e.remove(this._pendingAction),this._pendingAction=null}}class w_ extends(Y()){constructor(e,t){super(),this.id=A(),this._filePromiseWrapper=this._createFilePromiseWrapper(e),this._adapter=t(this),this._reader=new b_,this.set("status","idle"),this.set("uploaded",0),this.set("uploadTotal",null),this.bind("uploadedPercent").to(this,"uploaded",this,"uploadTotal",((e,t)=>t?e/t*100:0)),this.set("uploadResponse",null)}get file(){return this._filePromiseWrapper?this._filePromiseWrapper.promise.then((e=>this._filePromiseWrapper?e:null)):Promise.resolve(null)}get data(){return this._reader.data}read(){if("idle"!=this.status)throw new E("filerepository-read-wrong-status",this);return this.status="reading",this.file.then((e=>this._reader.read(e))).then((e=>{if("reading"!==this.status)throw this.status;return this.status="idle",e})).catch((e=>{if("aborted"===e)throw this.status="aborted","aborted";throw this.status="error",this._reader.error?this._reader.error:e}))}upload(){if("idle"!=this.status)throw new E("filerepository-upload-wrong-status",this);return this.status="uploading",this.file.then((()=>this._adapter.upload())).then((e=>(this.uploadResponse=e,this.status="idle",e))).catch((e=>{if("aborted"===this.status)throw"aborted";throw this.status="error",e}))}abort(){const e=this.status;this.status="aborted",this._filePromiseWrapper.isFulfilled?"reading"==e?this._reader.abort():"uploading"==e&&this._adapter.abort&&this._adapter.abort():(this._filePromiseWrapper.promise.catch((()=>{})),this._filePromiseWrapper.rejecter("aborted")),this._destroy()}_destroy(){this._filePromiseWrapper=void 0,this._reader=void 0,this._adapter=void 0,this.uploadResponse=void 0}_createFilePromiseWrapper(e){const t={};return t.promise=new Promise(((o,n)=>{t.rejecter=n,t.isFulfilled=!1,e.then((e=>{t.isFulfilled=!0,o(e)})).catch((e=>{t.isFulfilled=!0,n(e)}))})),t}}class __{constructor(e,t,o){this.loader=e,this.resource=t,this.editor=o}upload(){const e=this.resource,t=Kk(this.editor,"attachmentsResourceService");return e?this.loader.file.then((o=>t.attachFiles(e,[o]).toPromise().then((e=>(this.editor.model.fire("op:attachment-added",e),this.buildResponse(e[0])))).catch((e=>{console.error("Failed upload %O",e)})))):(console.warn("resource not available in this CKEditor instance"),Promise.reject("Not possible to upload attachments without resource"))}buildResponse(e){return{default:e._links.staticDownloadLocation.href}}abort(){return!1}}class y_ extends La{constructor(e){super(e),this.domEventType=["paste","copy","cut","drop","dragover","dragstart","dragend","dragenter","dragleave"];const t=this.document;function o(e){return(o,n)=>{n.preventDefault();const i=n.dropRange?[n.dropRange]:null,r=new w(t,e);t.fire(r,{dataTransfer:n.dataTransfer,method:o.name,targetRanges:i,target:n.target,domEvent:n.domEvent}),r.stop.called&&n.stopPropagation()}}this.listenTo(t,"paste",o("clipboardInput"),{priority:"low"}),this.listenTo(t,"drop",o("clipboardInput"),{priority:"low"}),this.listenTo(t,"dragover",o("dragging"),{priority:"low"})}onDomEvent(e){const t="clipboardData"in e?e.clipboardData:e.dataTransfer,o="drop"==e.type||"paste"==e.type,n={dataTransfer:new Bl(t,{cacheFiles:o})};"drop"!=e.type&&"dragover"!=e.type||(n.dropRange=function(e,t){const o=t.target.ownerDocument,n=t.clientX,i=t.clientY;let r;o.caretRangeFromPoint&&o.caretRangeFromPoint(n,i)?r=o.caretRangeFromPoint(n,i):t.rangeParent&&(r=o.createRange(),r.setStart(t.rangeParent,t.rangeOffset),r.collapse(!0));if(r)return e.domConverter.domRangeToView(r);return null}(this.view,e)),this.fire(e.type,e,n)}}const A_=["figcaption","li"],C_=["ol","ul"];function v_(e){if(e.is("$text")||e.is("$textProxy"))return e.data;if(e.is("element","img")&&e.hasAttribute("alt"))return e.getAttribute("alt");if(e.is("element","br"))return"\n";let t="",o=null;for(const n of e.getChildren())t+=x_(n,o)+v_(n),o=n;return t}function x_(e,t){return t?e.is("element","li")&&!e.isEmpty&&e.getChild(0).is("containerElement")||C_.includes(e.name)&&C_.includes(t.name)?"\n\n":e.is("containerElement")||t.is("containerElement")?A_.includes(e.name)||A_.includes(t.name)?"\n":e.is("element")&&e.getCustomProperty("dataPipeline:transparentRendering")||t.is("element")&&t.getCustomProperty("dataPipeline:transparentRendering")?"":"\n\n":"":""}const E_=function(e,t){return e&&Di(e,t,mo)};const D_=function(e,t,o,n){var i=o.length,r=i,s=!n;if(null==e)return!r;for(e=Object(e);i--;){var a=o[i];if(s&&a[2]?a[1]!==e[a[0]]:!(a[0]in e))return!1}for(;++ie.model.getSelectedContent(e.model.document.selection))){return this.editor.model.change((n=>{const i=n.model.document.selection;n.setSelection(t);const r=this._insertFakeMarkersIntoSelection(n,n.model.document.selection,e),s=o(n),a=this._removeFakeMarkersInsideElement(n,s);for(const[e,t]of Object.entries(r)){a[e]||(a[e]=n.createRangeIn(s));for(const e of t)n.remove(e)}s.markers.clear();for(const[e,t]of Object.entries(a))s.markers.set(e,t);return n.setSelection(i),s}))}_pasteMarkersIntoTransformedElement(e,t){const o=this._getPasteMarkersFromRangeMap(e);return this.editor.model.change((e=>{const n=this._insertFakeMarkersElements(e,o),i=t(e),r=this._removeFakeMarkersInsideElement(e,i);for(const t of Object.values(n).flat())e.remove(t);for(const[t,o]of Object.entries(r))e.model.markers.has(t)||e.addMarker(t,{usingOperation:!0,affectsData:!0,range:o});return i}))}_pasteFragmentWithMarkers(e){const t=this._getPasteMarkersFromRangeMap(e.markers);e.markers.clear();for(const o of t)e.markers.set(o.name,o.range);return this.editor.model.insertContent(e)}_forceMarkersCopy(e,t,o={allowedActions:"all",copyPartiallySelected:!0,duplicateOnPaste:!0}){const n=this._markersToCopy.get(e);this._markersToCopy.set(e,o),t(),n?this._markersToCopy.set(e,n):this._markersToCopy.delete(e)}_isMarkerCopyable(e,t){const o=this._getMarkerClipboardConfig(e);if(!o)return!1;if(!t)return!0;const{allowedActions:n}=o;return"all"===n||n.includes(t)}_hasMarkerConfiguration(e){return!!this._getMarkerClipboardConfig(e)}_getMarkerClipboardConfig(e){const[t]=e.split(":");return this._markersToCopy.get(t)||null}_insertFakeMarkersIntoSelection(e,t,o){const n=this._getCopyableMarkersFromSelection(e,t,o);return this._insertFakeMarkersElements(e,n)}_getCopyableMarkersFromSelection(e,t,o){const n=Array.from(t.getRanges()),i=new Set(n.flatMap((t=>Array.from(e.model.markers.getMarkersIntersectingRange(t)))));return Array.from(i).filter((e=>{if(!this._isMarkerCopyable(e.name,o))return!1;const{copyPartiallySelected:t}=this._getMarkerClipboardConfig(e.name);if(!t){const t=e.getRange();return n.some((e=>e.containsRange(t,!0)))}return!0})).map((e=>({name:"dragstart"===o?this._getUniqueMarkerName(e.name):e.name,range:e.getRange()})))}_getPasteMarkersFromRangeMap(e,t=null){const{model:o}=this.editor;return(e instanceof Map?Array.from(e.entries()):Object.entries(e)).flatMap((([e,n])=>{if(!this._hasMarkerConfiguration(e))return[{name:e,range:n}];if(this._isMarkerCopyable(e,t)){const t=this._getMarkerClipboardConfig(e),i=o.markers.has(e)&&"$graveyard"===o.markers.get(e).getRange().root.rootName;return(t.duplicateOnPaste||i)&&(e=this._getUniqueMarkerName(e)),[{name:e,range:n}]}return[]}))}_insertFakeMarkersElements(e,t){const o={},n=t.flatMap((e=>{const{start:t,end:o}=e.range;return[{position:t,marker:e,type:"start"},{position:o,marker:e,type:"end"}]})).sort((({position:e},{position:t})=>e.isBefore(t)?1:-1));for(const{position:t,marker:i,type:r}of n){const n=e.createElement("$marker",{"data-name":i.name,"data-type":r});o[i.name]||(o[i.name]=[]),o[i.name].push(n),e.insert(n,t)}return o}_removeFakeMarkersInsideElement(e,t){const o=this._getAllFakeMarkersFromElement(e,t).reduce(((t,o)=>{const n=o.markerElement&&e.createPositionBefore(o.markerElement);let i=t[o.name],r=!1;if(i&&i.start&&i.end){this._getMarkerClipboardConfig(o.name).duplicateOnPaste?t[this._getUniqueMarkerName(o.name)]=t[o.name]:r=!0,i=null}return r||(t[o.name]={...i,[o.type]:n}),o.markerElement&&e.remove(o.markerElement),t}),{});return L_(o,(o=>new Zl(o.start||e.createPositionFromPath(t,[0]),o.end||e.createPositionAt(t,"end"))))}_getAllFakeMarkersFromElement(e,t){const o=Array.from(e.createRangeIn(t)).flatMap((({item:e})=>{if(!e.is("element","$marker"))return[];const t=e.getAttribute("data-name"),o=e.getAttribute("data-type");return[{markerElement:e,name:t,type:o}]})),n=[],i=[];for(const e of o){if("end"===e.type){o.some((t=>t.name===e.name&&"start"===t.type))||n.push({markerElement:null,name:e.name,type:"start"})}if("start"===e.type){o.some((t=>t.name===e.name&&"end"===t.type))||i.unshift({markerElement:null,name:e.name,type:"end"})}}return[...n,...o,...i]}_getUniqueMarkerName(e){const t=e.split(":"),o=A().substring(1,6);return 3===t.length?`${t.slice(0,2).join(":")}:${o}`:`${t.join(":")}:${o}`}}class j_ extends lr{static get pluginName(){return"ClipboardPipeline"}static get requires(){return[H_]}init(){this.editor.editing.view.addObserver(y_),this._setupPasteDrop(),this._setupCopyCut()}_fireOutputTransformationEvent(e,t,o){const n=this.editor.plugins.get("ClipboardMarkersUtils");this.editor.model.enqueueChange({isUndoable:"cut"===o},(()=>{const i=n._copySelectedFragmentWithMarkers(o,t);this.fire("outputTransformation",{dataTransfer:e,content:i,method:o})}))}_setupPasteDrop(){const e=this.editor,t=e.model,o=e.editing.view,n=o.document,i=this.editor.plugins.get("ClipboardMarkersUtils");this.listenTo(n,"clipboardInput",((t,o)=>{"paste"!=o.method||e.model.canEditAt(e.model.document.selection)||t.stop()}),{priority:"highest"}),this.listenTo(n,"clipboardInput",((e,t)=>{const n=t.dataTransfer;let i;if(t.content)i=t.content;else{let e="";n.getData("text/html")?e=function(e){return e.replace(/(\s+)<\/span>/g,((e,t)=>1==t.length?" ":t)).replace(//g,"")}(n.getData("text/html")):n.getData("text/plain")&&(((r=(r=n.getData("text/plain")).replace(/&/g,"&").replace(//g,">").replace(/\r?\n\r?\n/g,"

    ").replace(/\r?\n/g,"
    ").replace(/\t/g,"    ").replace(/^\s/," ").replace(/\s$/," ").replace(/\s\s/g,"  ")).includes("

    ")||r.includes("
    "))&&(r=`

    ${r}

    `),e=r),i=this.editor.data.htmlProcessor.toView(e)}var r;const s=new w(this,"inputTransformation");this.fire(s,{content:i,dataTransfer:n,targetRanges:t.targetRanges,method:t.method}),s.stop.called&&e.stop(),o.scrollToTheSelection()}),{priority:"low"}),this.listenTo(this,"inputTransformation",((e,o)=>{if(o.content.isEmpty)return;const n=this.editor.data.toModel(o.content,"$clipboardHolder");0!=n.childCount&&(e.stop(),t.change((()=>{this.fire("contentInsertion",{content:n,method:o.method,dataTransfer:o.dataTransfer,targetRanges:o.targetRanges})})))}),{priority:"low"}),this.listenTo(this,"contentInsertion",((e,t)=>{t.resultRange=i._pasteFragmentWithMarkers(t.content)}),{priority:"low"})}_setupCopyCut(){const e=this.editor,t=e.model.document,o=e.editing.view.document,n=(e,o)=>{const n=o.dataTransfer;o.preventDefault(),this._fireOutputTransformationEvent(n,t.selection,e.name)};this.listenTo(o,"copy",n,{priority:"low"}),this.listenTo(o,"cut",((t,o)=>{e.model.canEditAt(e.model.document.selection)?n(t,o):o.preventDefault()}),{priority:"low"}),this.listenTo(this,"outputTransformation",((t,n)=>{const i=e.data.toView(n.content);o.fire("clipboardOutput",{dataTransfer:n.dataTransfer,content:i,method:n.method})}),{priority:"low"}),this.listenTo(o,"clipboardOutput",((o,n)=>{n.content.isEmpty||(n.dataTransfer.setData("text/html",this.editor.data.htmlProcessor.toData(n.content)),n.dataTransfer.setData("text/plain",v_(n.content))),"cut"==n.method&&e.model.deleteContent(t.selection)}),{priority:"low"})}}const q_=Yn("px");class U_ extends pm{constructor(){super();const e=this.bindTemplate;this.set({isVisible:!1,left:null,top:null,width:null}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-clipboard-drop-target-line",e.if("isVisible","ck-hidden",(e=>!e))],style:{left:e.to("left",(e=>q_(e))),top:e.to("top",(e=>q_(e))),width:e.to("width",(e=>q_(e)))}}})}}class W_ extends lr{constructor(){super(...arguments),this.removeDropMarkerDelayed=or((()=>this.removeDropMarker()),40),this._updateDropMarkerThrottled=Bh((e=>this._updateDropMarker(e)),40),this._reconvertMarkerThrottled=Bh((()=>{this.editor.model.markers.has("drop-target")&&this.editor.editing.reconvertMarker("drop-target")}),0),this._dropTargetLineView=new U_,this._domEmitter=new(Rn()),this._scrollables=new Map}static get pluginName(){return"DragDropTarget"}init(){this._setupDropMarker()}destroy(){this._domEmitter.stopListening();for(const{resizeObserver:e}of this._scrollables.values())e.destroy();return this._updateDropMarkerThrottled.cancel(),this.removeDropMarkerDelayed.cancel(),this._reconvertMarkerThrottled.cancel(),super.destroy()}updateDropMarker(e,t,o,n,i,r){this.removeDropMarkerDelayed.cancel();const s=$_(this.editor,e,t,o,n,i,r);if(s)return r&&r.containsRange(s)?this.removeDropMarker():void this._updateDropMarkerThrottled(s)}getFinalDropRange(e,t,o,n,i,r){const s=$_(this.editor,e,t,o,n,i,r);return this.removeDropMarker(),s}removeDropMarker(){const e=this.editor.model;this.removeDropMarkerDelayed.cancel(),this._updateDropMarkerThrottled.cancel(),this._dropTargetLineView.isVisible=!1,e.markers.has("drop-target")&&e.change((e=>{e.removeMarker("drop-target")}))}_setupDropMarker(){const e=this.editor;e.ui.view.body.add(this._dropTargetLineView),e.conversion.for("editingDowncast").markerToHighlight({model:"drop-target",view:{classes:["ck-clipboard-drop-target-range"]}}),e.conversion.for("editingDowncast").markerToElement({model:"drop-target",view:(t,{writer:o})=>{if(e.model.schema.checkChild(t.markerRange.start,"$text"))return this._dropTargetLineView.isVisible=!1,this._createDropTargetPosition(o);t.markerRange.isCollapsed?this._updateDropTargetLine(t.markerRange):this._dropTargetLineView.isVisible=!1}})}_updateDropMarker(e){const t=this.editor,o=t.model.markers;t.model.change((t=>{o.has("drop-target")?o.get("drop-target").getRange().isEqual(e)||t.updateMarker("drop-target",{range:e}):t.addMarker("drop-target",{range:e,usingOperation:!1,affectsData:!1})}))}_createDropTargetPosition(e){return e.createUIElement("span",{class:"ck ck-clipboard-drop-target-position"},(function(e){const t=this.toDomElement(e);return t.append("⁠",e.createElement("span"),"⁠"),t}))}_updateDropTargetLine(e){const o=this.editor.editing,n=e.start.nodeBefore,i=e.start.nodeAfter,r=e.start.parent,s=n?o.mapper.toViewElement(n):null,a=s?o.view.domConverter.mapViewToDom(s):null,l=i?o.mapper.toViewElement(i):null,c=l?o.view.domConverter.mapViewToDom(l):null,d=o.mapper.toViewElement(r);if(!d)return;const u=o.view.domConverter.mapViewToDom(d),h=this._getScrollableRect(d),{scrollX:m,scrollY:p}=t.window,g=a?new qn(a):null,f=c?new qn(c):null,b=new qn(u).excludeScrollbarsAndBorders(),k=g?g.bottom:b.top,w=f?f.top:b.bottom,_=t.window.getComputedStyle(u),y=k<=w?(k+w)/2:w;if(h.topa.schema.checkChild(r,e)))){if(a.schema.checkChild(r,"$text"))return a.createRange(r);if(t)return K_(e,J_(e,t.parent),n,i)}}}else if(a.schema.isInline(c))return K_(e,c,n,i);if(a.schema.isBlock(c))return K_(e,c,n,i);if(a.schema.checkChild(c,"$block")){const t=Array.from(c.getChildren()).filter((t=>t.is("element")&&!G_(e,t)));let o=0,r=t.length;if(0==r)return a.createRange(a.createPositionAt(c,"end"));for(;o{o?(this.forceDisabled("readOnlyMode"),this._isBlockDragging=!1):this.clearForceDisabled("readOnlyMode")})),r.isAndroid&&this.forceDisabled("noAndroidSupport"),e.plugins.has("BlockToolbar")){const o=e.plugins.get("BlockToolbar").buttonView.element;this._domEmitter.listenTo(o,"dragstart",((e,t)=>this._handleBlockDragStart(t))),this._domEmitter.listenTo(t.document,"dragover",((e,t)=>this._handleBlockDragging(t))),this._domEmitter.listenTo(t.document,"drop",((e,t)=>this._handleBlockDragging(t))),this._domEmitter.listenTo(t.document,"dragend",(()=>this._handleBlockDragEnd()),{useCapture:!0}),this.isEnabled&&o.setAttribute("draggable","true"),this.on("change:isEnabled",((e,t,n)=>{o.setAttribute("draggable",n?"true":"false")}))}}destroy(){return this._domEmitter.stopListening(),super.destroy()}_handleBlockDragStart(e){if(!this.isEnabled)return;const t=this.editor.model,o=t.document.selection,n=this.editor.editing.view,i=Array.from(o.getSelectedBlocks()),r=t.createRange(t.createPositionBefore(i[0]),t.createPositionAfter(i[i.length-1]));t.change((e=>e.setSelection(r))),this._isBlockDragging=!0,n.focus(),n.getObserver(y_).onDomEvent(e)}_handleBlockDragging(e){if(!this.isEnabled||!this._isBlockDragging)return;const t=e.clientX+("ltr"==this.editor.locale.contentLanguageDirection?100:-100),o=e.clientY,n=document.elementFromPoint(t,o),i=this.editor.editing.view;n&&n.closest(".ck-editor__editable")&&i.getObserver(y_).onDomEvent({...e,type:e.type,dataTransfer:e.dataTransfer,target:n,clientX:t,clientY:o,preventDefault:()=>e.preventDefault(),stopPropagation:()=>e.stopPropagation()})}_handleBlockDragEnd(){this._isBlockDragging=!1}}var Q_=i(9262),X_={attributes:{"data-cke":!0}};X_.setAttributes=Ar(),X_.insert=_r().bind(null,"head"),X_.domAPI=kr(),X_.insertStyleElement=vr();fr()(Q_.A,X_);Q_.A&&Q_.A.locals&&Q_.A.locals;class ey extends lr{constructor(){super(...arguments),this._clearDraggableAttributesDelayed=or((()=>this._clearDraggableAttributes()),40),this._blockMode=!1,this._domEmitter=new(Rn())}static get pluginName(){return"DragDrop"}static get requires(){return[j_,Jw,W_,Y_]}init(){const e=this.editor,t=e.editing.view;this._draggedRange=null,this._draggingUid="",this._draggableElement=null,t.addObserver(y_),t.addObserver(Nu),this._setupDragging(),this._setupContentInsertionIntegration(),this._setupClipboardInputIntegration(),this._setupDraggableAttributeHandling(),this.listenTo(e,"change:isReadOnly",((e,t,o)=>{o?this.forceDisabled("readOnlyMode"):this.clearForceDisabled("readOnlyMode")})),this.on("change:isEnabled",((e,t,o)=>{o||this._finalizeDragging(!1)})),r.isAndroid&&this.forceDisabled("noAndroidSupport")}destroy(){return this._draggedRange&&(this._draggedRange.detach(),this._draggedRange=null),this._previewContainer&&this._previewContainer.remove(),this._domEmitter.stopListening(),this._clearDraggableAttributesDelayed.cancel(),super.destroy()}_setupDragging(){const e=this.editor,o=e.model,n=e.editing.view,i=n.document,s=e.plugins.get(W_);this.listenTo(i,"dragstart",((e,t)=>{if(t.target&&t.target.is("editableElement"))return void t.preventDefault();if(this._prepareDraggedRange(t.target),!this._draggedRange)return void t.preventDefault();this._draggingUid=A(),t.dataTransfer.effectAllowed=this.isEnabled?"copyMove":"copy",t.dataTransfer.setData("application/ckeditor5-dragging-uid",this._draggingUid);const n=o.createSelection(this._draggedRange.toRange());this.editor.plugins.get("ClipboardPipeline")._fireOutputTransformationEvent(t.dataTransfer,n,"dragstart");const{dataTransfer:i,domTarget:r,domEvent:s}=t,{clientX:a}=s;this._updatePreview({dataTransfer:i,domTarget:r,clientX:a}),t.stopPropagation(),this.isEnabled||(this._draggedRange.detach(),this._draggedRange=null,this._draggingUid="")}),{priority:"low"}),this.listenTo(i,"dragend",((e,t)=>{this._finalizeDragging(!t.dataTransfer.isCanceled&&"move"==t.dataTransfer.dropEffect)}),{priority:"low"}),this._domEmitter.listenTo(t.document,"dragend",(()=>{this._blockMode=!1}),{useCapture:!0}),this.listenTo(i,"dragenter",(()=>{this.isEnabled&&n.focus()})),this.listenTo(i,"dragleave",(()=>{s.removeDropMarkerDelayed()})),this.listenTo(i,"dragging",((e,t)=>{if(!this.isEnabled)return void(t.dataTransfer.dropEffect="none");const{clientX:o,clientY:n}=t.domEvent;s.updateDropMarker(t.target,t.targetRanges,o,n,this._blockMode,this._draggedRange),this._draggedRange||(t.dataTransfer.dropEffect="copy"),r.isGecko||("copy"==t.dataTransfer.effectAllowed?t.dataTransfer.dropEffect="copy":["all","copyMove"].includes(t.dataTransfer.effectAllowed)&&(t.dataTransfer.dropEffect="move")),e.stop()}),{priority:"low"})}_setupClipboardInputIntegration(){const e=this.editor,t=e.editing.view.document,o=e.plugins.get(W_);this.listenTo(t,"clipboardInput",((t,n)=>{if("drop"!=n.method)return;const{clientX:i,clientY:r}=n.domEvent,s=o.getFinalDropRange(n.target,n.targetRanges,i,r,this._blockMode,this._draggedRange);if(!s)return this._finalizeDragging(!1),void t.stop();this._draggedRange&&this._draggingUid!=n.dataTransfer.getData("application/ckeditor5-dragging-uid")&&(this._draggedRange.detach(),this._draggedRange=null,this._draggingUid="");if("move"==ty(n.dataTransfer)&&this._draggedRange&&this._draggedRange.containsRange(s,!0))return this._finalizeDragging(!1),void t.stop();n.targetRanges=[e.editing.mapper.toViewRange(s)]}),{priority:"high"})}_setupContentInsertionIntegration(){const e=this.editor.plugins.get(j_);e.on("contentInsertion",((e,t)=>{if(!this.isEnabled||"drop"!==t.method)return;const o=t.targetRanges.map((e=>this.editor.editing.mapper.toModelRange(e)));this.editor.model.change((e=>e.setSelection(o)))}),{priority:"high"}),e.on("contentInsertion",((e,t)=>{if(!this.isEnabled||"drop"!==t.method)return;const o="move"==ty(t.dataTransfer),n=!t.resultRange||!t.resultRange.isCollapsed;this._finalizeDragging(n&&o)}),{priority:"lowest"})}_setupDraggableAttributeHandling(){const e=this.editor,t=e.editing.view,o=t.document;this.listenTo(o,"mousedown",((n,i)=>{if(r.isAndroid||!i)return;this._clearDraggableAttributesDelayed.cancel();let s=oy(i.target);if(r.isBlink&&!e.isReadOnly&&!s&&!o.selection.isCollapsed){const e=o.selection.getSelectedElement();e&&Rk(e)||(s=o.selection.editableElement)}s&&(t.change((e=>{e.setAttribute("draggable","true",s)})),this._draggableElement=e.editing.mapper.toModelElement(s))})),this.listenTo(o,"mouseup",(()=>{r.isAndroid||this._clearDraggableAttributesDelayed()}))}_clearDraggableAttributes(){const e=this.editor.editing;e.view.change((t=>{this._draggableElement&&"$graveyard"!=this._draggableElement.root.rootName&&t.removeAttribute("draggable",e.mapper.toViewElement(this._draggableElement)),this._draggableElement=null}))}_finalizeDragging(e){const t=this.editor,o=t.model;if(t.plugins.get(W_).removeDropMarker(),this._clearDraggableAttributes(),t.plugins.has("WidgetToolbarRepository")){t.plugins.get("WidgetToolbarRepository").clearForceDisabled("dragDrop")}this._draggingUid="",this._previewContainer&&(this._previewContainer.remove(),this._previewContainer=void 0),this._draggedRange&&(e&&this.isEnabled&&o.change((e=>{const t=o.createSelection(this._draggedRange);o.deleteContent(t,{doNotAutoparagraph:!0});const n=t.getFirstPosition().parent;n.isEmpty&&!o.schema.checkChild(n,"$text")&&o.schema.checkChild(n,"paragraph")&&e.insertElement("paragraph",n,0)})),this._draggedRange.detach(),this._draggedRange=null)}_prepareDraggedRange(e){const t=this.editor,o=t.model,n=o.document.selection,i=e?oy(e):null;if(i){const e=t.editing.mapper.toModelElement(i);if(this._draggedRange=cc.fromRange(o.createRangeOn(e)),this._blockMode=o.schema.isBlock(e),t.plugins.has("WidgetToolbarRepository")){t.plugins.get("WidgetToolbarRepository").forceDisabled("dragDrop")}return}if(n.isCollapsed&&!n.getFirstPosition().parent.isEmpty)return;const r=Array.from(n.getSelectedBlocks()),s=n.getFirstRange();if(0==r.length)return void(this._draggedRange=cc.fromRange(s));const a=ny(o,r);if(r.length>1)this._draggedRange=cc.fromRange(a),this._blockMode=!0;else if(1==r.length){const e=s.start.isTouching(a.start)&&s.end.isTouching(a.end);this._draggedRange=cc.fromRange(e?a:s),this._blockMode=e}o.change((e=>e.setSelection(this._draggedRange.toRange())))}_updatePreview({dataTransfer:e,domTarget:o,clientX:n}){const i=this.editor.editing.view,s=i.document.selection.editableElement,a=i.domConverter.mapViewToDom(s),l=t.window.getComputedStyle(a);this._previewContainer?this._previewContainer.firstElementChild&&this._previewContainer.removeChild(this._previewContainer.firstElementChild):(this._previewContainer=Ae(t.document,"div",{style:"position: fixed; left: -999999px;"}),t.document.body.appendChild(this._previewContainer));const c=new qn(a);if(a.contains(o))return;const d=parseFloat(l.paddingLeft),u=Ae(t.document,"div");u.className="ck ck-content",u.style.width=l.width,u.style.paddingLeft=`${c.left-n+d}px`,r.isiOS&&(u.style.backgroundColor="white"),u.innerHTML=e.getData("text/html"),e.setDragImage(u,0,0),this._previewContainer.appendChild(u)}}function ty(e){return r.isGecko?e.dropEffect:["all","copyMove"].includes(e.effectAllowed)?"move":"copy"}function oy(e){if(e.is("editableElement"))return null;if(e.hasClass("ck-widget__selection-handle"))return e.findAncestor(Rk);if(Rk(e))return e;const t=e.findAncestor((e=>Rk(e)||e.is("editableElement")));return Rk(t)?t:null}function ny(e,t){const o=t[0],n=t[t.length-1],i=o.getCommonAncestor(n),r=e.createPositionBefore(o),s=e.createPositionAfter(n);if(i&&i.is("element")&&!e.schema.isLimit(i)){const t=e.createRangeOn(i),o=r.isTouching(t.start),n=s.isTouching(t.end);if(o&&n)return ny(e,[i])}return e.createRange(r,s)}class iy extends lr{static get pluginName(){return"PastePlainText"}static get requires(){return[j_]}init(){const e=this.editor,t=e.model,o=e.editing.view,n=t.document.selection;o.addObserver(y_),e.plugins.get(j_).on("contentInsertion",((e,o)=>{(function(e,t){let o=t.createRangeIn(e);if(1==e.childCount){const n=e.getChild(0);n.is("element")&&t.schema.isBlock(n)&&!t.schema.isObject(n)&&!t.schema.isLimit(n)&&(o=t.createRangeIn(n))}for(const e of o.getItems()){if(!t.schema.isInline(e))return!1;if(Array.from(e.getAttributeKeys()).find((e=>t.schema.getAttributeProperties(e).isFormatting)))return!1}return!0})(o.content,t)&&t.change((e=>{const i=Array.from(n.getAttributes()).filter((([e])=>t.schema.getAttributeProperties(e).isFormatting));n.isCollapsed||t.deleteContent(n,{doNotAutoparagraph:!0}),i.push(...n.getAttributes());const r=e.createRangeIn(o.content);for(const o of r.getItems())for(const n of i)t.schema.checkAttribute(o,n[0])&&e.setAttribute(n[0],n[1],o)}))}))}}class ry extends lr{static get pluginName(){return"Clipboard"}static get requires(){return[H_,j_,ey,iy]}init(){const e=this.editor,t=this.editor.t;e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Copy selected content"),keystroke:"CTRL+C"},{label:t("Paste content"),keystroke:"CTRL+V"},{label:t("Paste content as plain text"),keystroke:"CTRL+SHIFT+V"}]})}}class sy extends dr{constructor(e){super(e),this._stack=[],this._createdBatches=new WeakSet,this.refresh(),this._isEnabledBasedOnSelection=!1,this.listenTo(e.data,"set",((e,t)=>{t[1]={...t[1]};const o=t[1];o.batchType||(o.batchType={isUndoable:!1})}),{priority:"high"}),this.listenTo(e.data,"set",((e,t)=>{t[1].batchType.isUndoable||this.clearStack()}))}refresh(){this.isEnabled=this._stack.length>0}get createdBatches(){return this._createdBatches}addBatch(e){const t=this.editor.model.document.selection,o={ranges:t.hasOwnRange?Array.from(t.getRanges()):[],isBackward:t.isBackward};this._stack.push({batch:e,selection:o}),this.refresh()}clearStack(){this._stack=[],this.refresh()}_restoreSelection(e,t,o){const n=this.editor.model,i=n.document,r=[],s=e.map((e=>e.getTransformedByOperations(o))),a=s.flat();for(const e of s){const t=e.filter((e=>e.root!=i.graveyard)).filter((e=>!ly(e,a)));t.length&&(ay(t),r.push(t[0]))}r.length&&n.change((e=>{e.setSelection(r,{backward:t})}))}_undo(e,t){const o=this.editor.model,n=o.document;this._createdBatches.add(t);const i=e.operations.slice().filter((e=>e.isDocumentOperation));i.reverse();for(const e of i){const i=e.baseVersion+1,r=Array.from(n.history.getOperations(i)),s=Ud([e.getReversed()],r,{useRelations:!0,document:this.editor.model.document,padWithNoOps:!1,forceWeakRemove:!0}).operationsA;for(let i of s){const r=i.affectedSelectable;r&&!o.canEditAt(r)&&(i=new Md(i.baseVersion)),t.addOperation(i),o.applyOperation(i),n.history.setOperationAsUndone(e,i)}}}}function ay(e){e.sort(((e,t)=>e.start.isBefore(t.start)?-1:1));for(let t=1;tt!==e&&t.containsRange(e,!0)))}class cy extends sy{execute(e=null){const t=e?this._stack.findIndex((t=>t.batch==e)):this._stack.length-1,o=this._stack.splice(t,1)[0],n=this.editor.model.createBatch({isUndo:!0});this.editor.model.enqueueChange(n,(()=>{this._undo(o.batch,n);const e=this.editor.model.document.history.getOperations(o.batch.baseVersion);this._restoreSelection(o.selection.ranges,o.selection.isBackward,e)})),this.fire("revert",o.batch,n),this.refresh()}}class dy extends sy{execute(){const e=this._stack.pop(),t=this.editor.model.createBatch({isUndo:!0});this.editor.model.enqueueChange(t,(()=>{const o=e.batch.operations[e.batch.operations.length-1].baseVersion+1,n=this.editor.model.document.history.getOperations(o);this._restoreSelection(e.selection.ranges,e.selection.isBackward,n),this._undo(e.batch,t)})),this.refresh()}}class uy extends lr{constructor(){super(...arguments),this._batchRegistry=new WeakSet}static get pluginName(){return"UndoEditing"}init(){const e=this.editor,t=e.t;this._undoCommand=new cy(e),this._redoCommand=new dy(e),e.commands.add("undo",this._undoCommand),e.commands.add("redo",this._redoCommand),this.listenTo(e.model,"applyOperation",((e,t)=>{const o=t[0];if(!o.isDocumentOperation)return;const n=o.batch,i=this._redoCommand.createdBatches.has(n),r=this._undoCommand.createdBatches.has(n);this._batchRegistry.has(n)||(this._batchRegistry.add(n),n.isUndoable&&(i?this._undoCommand.addBatch(n):r||(this._undoCommand.addBatch(n),this._redoCommand.clearStack())))}),{priority:"highest"}),this.listenTo(this._undoCommand,"revert",((e,t,o)=>{this._redoCommand.addBatch(o)})),e.keystrokes.set("CTRL+Z","undo"),e.keystrokes.set("CTRL+Y","redo"),e.keystrokes.set("CTRL+SHIFT+Z","redo"),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Undo"),keystroke:"CTRL+Z"},{label:t("Redo"),keystroke:[["CTRL+Y"],["CTRL+SHIFT+Z"]]}]})}}class hy extends lr{static get pluginName(){return"UndoUI"}init(){const e=this.editor,t=e.locale,o=e.t,n="ltr"==t.uiLanguageDirection?qh.undo:qh.redo,i="ltr"==t.uiLanguageDirection?qh.redo:qh.undo;this._addButtonsToFactory("undo",o("Undo"),"CTRL+Z",n),this._addButtonsToFactory("redo",o("Redo"),"CTRL+Y",i)}_addButtonsToFactory(e,t,o,n){const i=this.editor;i.ui.componentFactory.add(e,(()=>{const i=this._createButton(Em,e,t,o,n);return i.set({tooltip:!0}),i})),i.ui.componentFactory.add("menuBar:"+e,(()=>this._createButton(ip,e,t,o,n)))}_createButton(e,t,o,n,i){const r=this.editor,s=r.locale,a=r.commands.get(t),l=new e(s);return l.set({label:o,icon:i,keystroke:n}),l.bind("isEnabled").to(a,"isEnabled"),this.listenTo(l,"execute",(()=>{r.execute(t),r.editing.view.focus()})),l}}class my extends lr{static get requires(){return[uy,hy]}static get pluginName(){return"Undo"}}function py(e){return e.createContainerElement("figure",{class:"image"},[e.createEmptyElement("img"),e.createSlot("children")])}function gy(e,t){const o=e.plugins.get("ImageUtils"),n=e.plugins.has("ImageInlineEditing")&&e.plugins.has("ImageBlockEditing");return e=>{if(!o.isInlineImageView(e))return null;if(!n)return i(e);return("block"==e.getStyle("display")||e.findAncestor(o.isBlockImageView)?"imageBlock":"imageInline")!==t?null:i(e)};function i(e){const t={name:!0};return e.hasAttribute("src")&&(t.attributes=["src"]),t}}function fy(e,t){const o=Qi(t.getSelectedBlocks());return!o||e.isObject(o)||o.isEmpty&&"listItem"!=o.name?"imageBlock":"imageInline"}function by(e){return e&&e.endsWith("px")?parseInt(e):null}function ky(e){const t=by(e.getStyle("width")),o=by(e.getStyle("height"));return!(!t||!o)}const wy=/^(image|image-inline)$/;class _y extends lr{constructor(){super(...arguments),this._domEmitter=new(Rn())}static get pluginName(){return"ImageUtils"}isImage(e){return this.isInlineImage(e)||this.isBlockImage(e)}isInlineImageView(e){return!!e&&e.is("element","img")}isBlockImageView(e){return!!e&&e.is("element","figure")&&e.hasClass("image")}insertImage(e={},t=null,o=null,n={}){const i=this.editor,r=i.model,s=r.document.selection,a=yy(i,t||s,o);e={...Object.fromEntries(s.getAttributes()),...e};for(const t in e)r.schema.checkAttribute(a,t)||delete e[t];return r.change((o=>{const{setImageSizes:i=!0}=n,s=o.createElement(a,e);return r.insertObject(s,t,null,{setSelection:"on",findOptimalPosition:t||"imageInline"==a?void 0:"auto"}),s.parent?(i&&this.setImageNaturalSizeAttributes(s),s):null}))}setImageNaturalSizeAttributes(e){const o=e.getAttribute("src");o&&(e.getAttribute("width")||e.getAttribute("height")||this.editor.model.change((n=>{const i=new t.window.Image;this._domEmitter.listenTo(i,"load",(()=>{e.getAttribute("width")||e.getAttribute("height")||this.editor.model.enqueueChange(n.batch,(t=>{t.setAttribute("width",i.naturalWidth,e),t.setAttribute("height",i.naturalHeight,e)})),this._domEmitter.stopListening(i,"load")})),i.src=o})))}getClosestSelectedImageWidget(e){const t=e.getFirstPosition();if(!t)return null;const o=e.getSelectedElement();if(o&&this.isImageWidget(o))return o;let n=t.parent;for(;n;){if(n.is("element")&&this.isImageWidget(n))return n;n=n.parent}return null}getClosestSelectedImageElement(e){const t=e.getSelectedElement();return this.isImage(t)?t:e.getFirstPosition().findAncestor("imageBlock")}getImageWidgetFromImageView(e){return e.findAncestor({classes:wy})}isImageAllowed(){const e=this.editor.model.document.selection;return function(e,t){const o=yy(e,t,null);if("imageBlock"==o){const o=function(e,t){const o=function(e,t){const o=e.getSelectedElement();if(o){const n=Ik(e);if(n)return t.createRange(t.createPositionAt(o,n))}return t.schema.findOptimalInsertionRange(e)}(e,t),n=o.start.parent;if(n.isEmpty&&!n.is("element","$root"))return n.parent;return n}(t,e.model);if(e.model.schema.checkChild(o,"imageBlock"))return!0}else if(e.model.schema.checkChild(t.focus,"imageInline"))return!0;return!1}(this.editor,e)&&function(e){return[...e.focus.getAncestors()].every((e=>!e.is("element","imageBlock")))}(e)}toImageWidget(e,t,o){t.setCustomProperty("image",!0,e);return zk(e,t,{label:()=>{const t=this.findViewImgElement(e).getAttribute("alt");return t?`${t} ${o}`:o}})}isImageWidget(e){return!!e.getCustomProperty("image")&&Rk(e)}isBlockImage(e){return!!e&&e.is("element","imageBlock")}isInlineImage(e){return!!e&&e.is("element","imageInline")}findViewImgElement(e){if(this.isInlineImageView(e))return e;const t=this.editor.editing.view;for(const{item:o}of t.createRangeIn(e))if(this.isInlineImageView(o))return o}destroy(){return this._domEmitter.stopListening(),super.destroy()}}function yy(e,t,o){const n=e.model.schema,i=e.config.get("image.insert.type");return e.plugins.has("ImageBlockEditing")?e.plugins.has("ImageInlineEditing")?o||("inline"===i?"imageInline":"auto"!==i?"imageBlock":t.is("selection")?fy(n,t):n.checkChild(t,"imageInline")?"imageInline":"imageBlock"):"imageBlock":"imageInline"}new RegExp(String(/^(http(s)?:\/\/)?[\w-]+\.[\w.~:/[\]@!$&'()*+,;=%-]+/.source+/\.(jpg|jpeg|png|gif|ico|webp|JPG|JPEG|PNG|GIF|ICO|WEBP)/.source+/(\?[\w.~:/[\]@!$&'()*+,;=%-]*)?/.source+/(#[\w.~:/[\]@!$&'()*+,;=%-]*)?$/.source));class Ay extends dr{refresh(){const e=this.editor.plugins.get("ImageUtils").getClosestSelectedImageElement(this.editor.model.document.selection);this.isEnabled=!!e,this.isEnabled&&e.hasAttribute("alt")?this.value=e.getAttribute("alt"):this.value=!1}execute(e){const t=this.editor,o=t.plugins.get("ImageUtils"),n=t.model,i=o.getClosestSelectedImageElement(n.document.selection);n.change((t=>{t.setAttribute("alt",e.newValue,i)}))}}class Cy extends lr{static get requires(){return[_y]}static get pluginName(){return"ImageTextAlternativeEditing"}init(){this.editor.commands.add("imageTextAlternative",new Ay(this.editor))}}var vy=i(8429),xy={attributes:{"data-cke":!0}};xy.setAttributes=Ar(),xy.insert=_r().bind(null,"head"),xy.domAPI=kr(),xy.insertStyleElement=vr();fr()(vy.A,xy);vy.A&&vy.A.locals&&vy.A.locals;var Ey=i(871),Dy={attributes:{"data-cke":!0}};Dy.setAttributes=Ar(),Dy.insert=_r().bind(null,"head"),Dy.domAPI=kr(),Dy.insertStyleElement=vr();fr()(Ey.A,Dy);Ey.A&&Ey.A.locals&&Ey.A.locals;class By extends pm{constructor(e){super(e);const t=this.locale.t;this.focusTracker=new Xi,this.keystrokes=new er,this.labeledInput=this._createLabeledInputView(),this.saveButtonView=this._createButton(t("Save"),qh.check,"ck-button-save"),this.saveButtonView.type="submit",this.cancelButtonView=this._createButton(t("Cancel"),qh.cancel,"ck-button-cancel","cancel"),this._focusables=new Uh,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.setTemplate({tag:"form",attributes:{class:["ck","ck-text-alternative-form","ck-responsive-form"],tabindex:"-1"},children:[this.labeledInput,this.saveButtonView,this.cancelButtonView]})}render(){super.render(),this.keystrokes.listenTo(this.element),bm({view:this}),[this.labeledInput,this.saveButtonView,this.cancelButtonView].forEach((e=>{this._focusables.add(e),this.focusTracker.add(e.element)}))}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}_createButton(e,t,o,n){const i=new Em(this.locale);return i.set({label:e,icon:t,tooltip:!0}),i.extendTemplate({attributes:{class:o}}),n&&i.delegate("execute").to(this,n),i}_createLabeledInputView(){const e=this.locale.t,t=new jp(this.locale,Fg);return t.label=e("Text alternative"),t}}function Sy(e){const t=e.editing.view,o=Ff.defaultPositions,n=e.plugins.get("ImageUtils");return{target:t.domConverter.mapViewToDom(n.getClosestSelectedImageWidget(t.document.selection)),positions:[o.northArrowSouth,o.northArrowSouthWest,o.northArrowSouthEast,o.southArrowNorth,o.southArrowNorthWest,o.southArrowNorthEast,o.viewportStickyNorth]}}class Ty extends lr{static get requires(){return[Fb]}static get pluginName(){return"ImageTextAlternativeUI"}init(){this._createButton()}destroy(){super.destroy(),this._form&&this._form.destroy()}_createButton(){const e=this.editor,t=e.t;e.ui.componentFactory.add("imageTextAlternative",(o=>{const n=e.commands.get("imageTextAlternative"),i=new Em(o);return i.set({label:t("Change image text alternative"),icon:qh.textAlternative,tooltip:!0}),i.bind("isEnabled").to(n,"isEnabled"),i.bind("isOn").to(n,"value",(e=>!!e)),this.listenTo(i,"execute",(()=>{this._showForm()})),i}))}_createForm(){const e=this.editor,t=e.editing.view.document,o=e.plugins.get("ImageUtils");this._balloon=this.editor.plugins.get("ContextualBalloon"),this._form=new(fm(By))(e.locale),this._form.render(),this.listenTo(this._form,"submit",(()=>{e.execute("imageTextAlternative",{newValue:this._form.labeledInput.fieldView.element.value}),this._hideForm(!0)})),this.listenTo(this._form,"cancel",(()=>{this._hideForm(!0)})),this._form.keystrokes.set("Esc",((e,t)=>{this._hideForm(!0),t()})),this.listenTo(e.ui,"update",(()=>{o.getClosestSelectedImageWidget(t.selection)?this._isVisible&&function(e){const t=e.plugins.get("ContextualBalloon");if(e.plugins.get("ImageUtils").getClosestSelectedImageWidget(e.editing.view.document.selection)){const o=Sy(e);t.updatePosition(o)}}(e):this._hideForm(!0)})),gm({emitter:this._form,activator:()=>this._isVisible,contextElements:()=>[this._balloon.view.element],callback:()=>this._hideForm()})}_showForm(){if(this._isVisible)return;this._form||this._createForm();const e=this.editor,t=e.commands.get("imageTextAlternative"),o=this._form.labeledInput;this._form.disableCssTransitions(),this._isInBalloon||this._balloon.add({view:this._form,position:Sy(e)}),o.fieldView.value=o.fieldView.element.value=t.value||"",this._form.labeledInput.fieldView.select(),this._form.enableCssTransitions()}_hideForm(e=!1){this._isInBalloon&&(this._form.focusTracker.isFocused&&this._form.saveButtonView.focus(),this._balloon.remove(this._form),e&&this.editor.editing.view.focus())}get _isVisible(){return!!this._balloon&&this._balloon.visibleView===this._form}get _isInBalloon(){return!!this._balloon&&this._balloon.hasView(this._form)}}class Iy extends lr{static get requires(){return[Cy,Ty]}static get pluginName(){return"ImageTextAlternative"}}function Py(e,t){const o=(t,o,n)=>{if(!n.consumable.consume(o.item,t.name))return;const i=n.writer,r=n.mapper.toViewElement(o.item),s=e.findViewImgElement(r);null===o.attributeNewValue?(i.removeAttribute("srcset",s),i.removeAttribute("sizes",s)):o.attributeNewValue&&(i.setAttribute("srcset",o.attributeNewValue,s),i.setAttribute("sizes","100vw",s))};return e=>{e.on(`attribute:srcset:${t}`,o)}}function Fy(e,t,o){const n=(t,o,n)=>{if(!n.consumable.consume(o.item,t.name))return;const i=n.writer,r=n.mapper.toViewElement(o.item),s=e.findViewImgElement(r);i.setAttribute(o.attributeKey,o.attributeNewValue||"",s)};return e=>{e.on(`attribute:${o}:${t}`,n)}}class My extends za{observe(e){this.listenTo(e,"load",((e,t)=>{const o=t.target;this.checkShouldIgnoreEventFromTarget(o)||"IMG"==o.tagName&&this._fireEvents(t)}),{useCapture:!0})}stopObserving(e){this.stopListening(e)}_fireEvents(e){this.isEnabled&&(this.document.fire("layoutChanged"),this.document.fire("imageLoaded",e))}}class Ry extends dr{constructor(e){super(e);const t=e.config.get("image.insert.type");e.plugins.has("ImageBlockEditing")||"block"===t&&D("image-block-plugin-required"),e.plugins.has("ImageInlineEditing")||"inline"===t&&D("image-inline-plugin-required")}refresh(){const e=this.editor.plugins.get("ImageUtils");this.isEnabled=e.isImageAllowed()}execute(e){const t=xi(e.source),o=this.editor.model.document.selection,n=this.editor.plugins.get("ImageUtils"),i=Object.fromEntries(o.getAttributes());t.forEach(((e,t)=>{const r=o.getSelectedElement();if("string"==typeof e&&(e={src:e}),t&&r&&n.isImage(r)){const t=this.editor.model.createPositionAfter(r);n.insertImage({...e,...i},t)}else n.insertImage({...e,...i})}))}}class zy extends dr{constructor(e){super(e),this.decorate("cleanupImage")}refresh(){const e=this.editor.plugins.get("ImageUtils"),t=this.editor.model.document.selection.getSelectedElement();this.isEnabled=e.isImage(t),this.value=this.isEnabled?t.getAttribute("src"):null}execute(e){const t=this.editor.model.document.selection.getSelectedElement(),o=this.editor.plugins.get("ImageUtils");this.editor.model.change((n=>{n.setAttribute("src",e.source,t),this.cleanupImage(n,t),o.setImageNaturalSizeAttributes(t)}))}cleanupImage(e,t){e.removeAttribute("srcset",t),e.removeAttribute("sizes",t),e.removeAttribute("sources",t),e.removeAttribute("width",t),e.removeAttribute("height",t),e.removeAttribute("alt",t)}}class Vy extends lr{static get requires(){return[_y]}static get pluginName(){return"ImageEditing"}init(){const e=this.editor,t=e.conversion;e.editing.view.addObserver(My),t.for("upcast").attributeToAttribute({view:{name:"img",key:"alt"},model:"alt"}).attributeToAttribute({view:{name:"img",key:"srcset"},model:"srcset"});const o=new Ry(e),n=new zy(e);e.commands.add("insertImage",o),e.commands.add("replaceImageSource",n),e.commands.add("imageInsert",o)}}class Oy extends lr{static get requires(){return[_y]}static get pluginName(){return"ImageSizeAttributes"}afterInit(){this._registerSchema(),this._registerConverters("imageBlock"),this._registerConverters("imageInline")}_registerSchema(){this.editor.plugins.has("ImageBlockEditing")&&this.editor.model.schema.extend("imageBlock",{allowAttributes:["width","height"]}),this.editor.plugins.has("ImageInlineEditing")&&this.editor.model.schema.extend("imageInline",{allowAttributes:["width","height"]})}_registerConverters(e){const t=this.editor,o=t.plugins.get("ImageUtils"),n="imageBlock"===e?"figure":"img";function i(t,n,i,r){t.on(`attribute:${n}:${e}`,((t,n,s)=>{if(!s.consumable.consume(n.item,t.name))return;const a=s.writer,l=s.mapper.toViewElement(n.item),c=o.findViewImgElement(l);if(null!==n.attributeNewValue?a.setAttribute(i,n.attributeNewValue,c):a.removeAttribute(i,c),n.item.hasAttribute("sources"))return;const d=n.item.hasAttribute("resizedWidth");if("imageInline"===e&&!d&&!r)return;const u=n.item.getAttribute("width"),h=n.item.getAttribute("height");u&&h&&a.setStyle("aspect-ratio",`${u}/${h}`,c)}))}t.conversion.for("upcast").attributeToAttribute({view:{name:n,styles:{width:/.+/}},model:{key:"width",value:e=>ky(e)?by(e.getStyle("width")):null}}).attributeToAttribute({view:{name:n,key:"width"},model:"width"}).attributeToAttribute({view:{name:n,styles:{height:/.+/}},model:{key:"height",value:e=>ky(e)?by(e.getStyle("height")):null}}).attributeToAttribute({view:{name:n,key:"height"},model:"height"}),t.conversion.for("editingDowncast").add((e=>{i(e,"width","width",!0),i(e,"height","height",!0)})),t.conversion.for("dataDowncast").add((e=>{i(e,"width","width",!1),i(e,"height","height",!1)}))}}class Ny extends dr{constructor(e,t){super(e),this._modelElementName=t}refresh(){const e=this.editor.plugins.get("ImageUtils"),t=e.getClosestSelectedImageElement(this.editor.model.document.selection);"imageBlock"===this._modelElementName?this.isEnabled=e.isInlineImage(t):this.isEnabled=e.isBlockImage(t)}execute(e={}){const t=this.editor,o=this.editor.model,n=t.plugins.get("ImageUtils"),i=n.getClosestSelectedImageElement(o.document.selection),r=Object.fromEntries(i.getAttributes());return r.src||r.uploadId?o.change((t=>{const{setImageSizes:s=!0}=e,a=Array.from(o.markers).filter((e=>e.getRange().containsItem(i))),l=n.insertImage(r,o.createSelection(i,"on"),this._modelElementName,{setImageSizes:s});if(!l)return null;const c=t.createRangeOn(l);for(const e of a){const o=e.getRange(),n="$graveyard"!=o.root.rootName?o.getJoined(c,!0):c;t.updateMarker(e,{range:n})}return{oldElement:i,newElement:l}})):null}}var Ly=i(1091),Hy={attributes:{"data-cke":!0}};Hy.setAttributes=Ar(),Hy.insert=_r().bind(null,"head"),Hy.domAPI=kr(),Hy.insertStyleElement=vr();fr()(Ly.A,Hy);Ly.A&&Ly.A.locals&&Ly.A.locals;class jy extends lr{static get requires(){return[_y]}static get pluginName(){return"ImagePlaceholder"}afterInit(){this._setupSchema(),this._setupConversion(),this._setupLoadListener()}_setupSchema(){const e=this.editor.model.schema;e.isRegistered("imageBlock")&&e.extend("imageBlock",{allowAttributes:["placeholder"]}),e.isRegistered("imageInline")&&e.extend("imageInline",{allowAttributes:["placeholder"]})}_setupConversion(){const e=this.editor,t=e.conversion,o=e.plugins.get("ImageUtils");t.for("editingDowncast").add((e=>{e.on("attribute:placeholder",((e,t,n)=>{if(!n.consumable.test(t.item,e.name))return;if(!t.item.is("element","imageBlock")&&!t.item.is("element","imageInline"))return;n.consumable.consume(t.item,e.name);const i=n.writer,r=n.mapper.toViewElement(t.item),s=o.findViewImgElement(r);t.attributeNewValue?(i.addClass("image_placeholder",s),i.setStyle("background-image",`url(${t.attributeNewValue})`,s),i.setCustomProperty("editingPipeline:doNotReuseOnce",!0,s)):(i.removeClass("image_placeholder",s),i.removeStyle("background-image",s))}))}))}_setupLoadListener(){const e=this.editor,t=e.model,o=e.editing,n=o.view,i=e.plugins.get("ImageUtils");n.addObserver(My),this.listenTo(n.document,"imageLoaded",((e,r)=>{const s=n.domConverter.mapDomToView(r.target);if(!s)return;const a=i.getImageWidgetFromImageView(s);if(!a)return;const l=o.mapper.toModelElement(a);l&&l.hasAttribute("placeholder")&&t.enqueueChange({isUndoable:!1},(e=>{e.removeAttribute("placeholder",l)}))}))}}class qy extends lr{static get requires(){return[Vy,Oy,_y,jy,j_]}static get pluginName(){return"ImageBlockEditing"}init(){const e=this.editor;e.model.schema.register("imageBlock",{inheritAllFrom:"$blockObject",allowAttributes:["alt","src","srcset"]}),this._setupConversion(),e.plugins.has("ImageInlineEditing")&&(e.commands.add("imageTypeBlock",new Ny(this.editor,"imageBlock")),this._setupClipboardIntegration())}_setupConversion(){const e=this.editor,t=e.t,o=e.conversion,n=e.plugins.get("ImageUtils");o.for("dataDowncast").elementToStructure({model:"imageBlock",view:(e,{writer:t})=>py(t)}),o.for("editingDowncast").elementToStructure({model:"imageBlock",view:(e,{writer:o})=>n.toImageWidget(py(o),o,t("image widget"))}),o.for("downcast").add(Fy(n,"imageBlock","src")).add(Fy(n,"imageBlock","alt")).add(Py(n,"imageBlock")),o.for("upcast").elementToElement({view:gy(e,"imageBlock"),model:(e,{writer:t})=>t.createElement("imageBlock",e.hasAttribute("src")?{src:e.getAttribute("src")}:void 0)}).add(function(e){const t=(t,o,n)=>{if(!n.consumable.test(o.viewItem,{name:!0,classes:"image"}))return;const i=e.findViewImgElement(o.viewItem);if(!i||!n.consumable.test(i,{name:!0}))return;n.consumable.consume(o.viewItem,{name:!0,classes:"image"});const r=Qi(n.convertItem(i,o.modelCursor).modelRange.getItems());r?(n.convertChildren(o.viewItem,r),n.updateConversionResult(r,o)):n.consumable.revert(o.viewItem,{name:!0,classes:"image"})};return e=>{e.on("element:figure",t)}}(n))}_setupClipboardIntegration(){const e=this.editor,t=e.model,o=e.editing.view,n=e.plugins.get("ImageUtils"),i=e.plugins.get("ClipboardPipeline");this.listenTo(i,"inputTransformation",((i,r)=>{const s=Array.from(r.content.getChildren());let a;if(!s.every(n.isInlineImageView))return;a=r.targetRanges?e.editing.mapper.toModelRange(r.targetRanges[0]):t.document.selection.getFirstRange();const l=t.createSelection(a);if("imageBlock"===fy(t.schema,l)){const e=new Lu(o.document),t=s.map((t=>e.createElement("figure",{class:"image"},t)));r.content=e.createDocumentFragment(t)}})),this.listenTo(i,"contentInsertion",((e,o)=>{"paste"===o.method&&t.change((e=>{const t=e.createRangeIn(o.content);for(const e of t.getItems())e.is("element","imageBlock")&&n.setImageNaturalSizeAttributes(e)}))}))}}var Uy=i(1545),Wy={attributes:{"data-cke":!0}};Wy.setAttributes=Ar(),Wy.insert=_r().bind(null,"head"),Wy.domAPI=kr(),Wy.insertStyleElement=vr();fr()(Uy.A,Wy);Uy.A&&Uy.A.locals&&Uy.A.locals;class $y extends pm{constructor(e,t=[]){super(e),this.focusTracker=new Xi,this.keystrokes=new er,this._focusables=new Uh,this.children=this.createCollection(),this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}});for(const e of t)this.children.add(e),this._focusables.add(e),e instanceof xp&&this._focusables.addMany(e.children);this.setTemplate({tag:"form",attributes:{class:["ck","ck-image-insert-form"],tabindex:-1},children:this.children})}render(){super.render(),bm({view:this});for(const e of this._focusables)this.focusTracker.add(e.element);this.keystrokes.listenTo(this.element);const e=e=>e.stopPropagation();this.keystrokes.set("arrowright",e),this.keystrokes.set("arrowleft",e),this.keystrokes.set("arrowup",e),this.keystrokes.set("arrowdown",e)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this._focusCycler.focusFirst()}}class Gy extends lr{static get pluginName(){return"ImageInsertUI"}static get requires(){return[_y]}constructor(e){super(e),this._integrations=new Map,e.config.define("image.insert.integrations",["upload","assetManager","url"])}init(){const e=this.editor,t=e.model.document.selection,o=e.plugins.get("ImageUtils");this.set("isImageSelected",!1),this.listenTo(e.model.document,"change",(()=>{this.isImageSelected=o.isImage(t.getSelectedElement())}));const n=e=>this._createToolbarComponent(e);e.ui.componentFactory.add("insertImage",n),e.ui.componentFactory.add("imageInsert",n),e.ui.componentFactory.add("menuBar:insertImage",(e=>this._createMenuBarComponent(e)))}registerIntegration({name:e,observable:t,buttonViewCreator:o,formViewCreator:n,menuBarButtonViewCreator:i,requiresForm:r=!1}){this._integrations.has(e)&&D("image-insert-integration-exists",{name:e}),this._integrations.set(e,{observable:t,buttonViewCreator:o,menuBarButtonViewCreator:i,formViewCreator:n,requiresForm:r})}_createToolbarComponent(e){const t=this.editor,o=e.t,n=this._prepareIntegrations();if(!n.length)return null;let i;const r=n[0];if(1==n.length){if(!r.requiresForm)return r.buttonViewCreator(!0);i=r.buttonViewCreator(!0)}else{const t=r.buttonViewCreator(!1);i=new yg(e,t),i.tooltip=!0,i.bind("label").to(this,"isImageSelected",(e=>o(e?"Replace image":"Insert image")))}const s=this.dropdownView=Eg(e,i),a=n.map((({observable:e})=>"function"==typeof e?e():e));return s.bind("isEnabled").toMany(a,"isEnabled",((...e)=>e.some((e=>e)))),s.once("change:isOpen",(()=>{const e=n.map((({formViewCreator:e})=>e(1==n.length))),o=new $y(t.locale,e);s.panelView.children.add(o)})),s}_createMenuBarComponent(e){const t=e.t,o=this._prepareIntegrations();if(!o.length)return null;let n;const i=o[0];if(1==o.length)n=i.menuBarButtonViewCreator(!0);else{n=new mk(e);const i=new pk(e);n.panelView.children.add(i),n.buttonView.set({icon:qh.image,label:t("Image")});for(const t of o){const o=new nb(e,n),r=t.menuBarButtonViewCreator(!1);o.children.add(r),i.items.add(o)}}return n}_prepareIntegrations(){const e=this.editor.config.get("image.insert.integrations"),t=[];if(!e.length)return D("image-insert-integrations-not-specified"),t;for(const o of e)this._integrations.has(o)?t.push(this._integrations.get(o)):["upload","assetManager","url"].includes(o)||D("image-insert-unknown-integration",{item:o});return t.length||D("image-insert-integrations-not-registered"),t}}var Ky=i(8574),Zy={attributes:{"data-cke":!0}};Zy.setAttributes=Ar(),Zy.insert=_r().bind(null,"head"),Zy.domAPI=kr(),Zy.insertStyleElement=vr();fr()(Ky.A,Zy);Ky.A&&Ky.A.locals&&Ky.A.locals;class Jy extends lr{static get requires(){return[Vy,Oy,_y,jy,j_]}static get pluginName(){return"ImageInlineEditing"}init(){const e=this.editor;e.model.schema.register("imageInline",{inheritAllFrom:"$inlineObject",allowAttributes:["alt","src","srcset"],disallowIn:["caption"]}),this._setupConversion(),e.plugins.has("ImageBlockEditing")&&(e.commands.add("imageTypeInline",new Ny(this.editor,"imageInline")),this._setupClipboardIntegration())}_setupConversion(){const e=this.editor,t=e.t,o=e.conversion,n=e.plugins.get("ImageUtils");o.for("dataDowncast").elementToElement({model:"imageInline",view:(e,{writer:t})=>t.createEmptyElement("img")}),o.for("editingDowncast").elementToStructure({model:"imageInline",view:(e,{writer:o})=>n.toImageWidget(function(e){return e.createContainerElement("span",{class:"image-inline"},e.createEmptyElement("img"))}(o),o,t("image widget"))}),o.for("downcast").add(Fy(n,"imageInline","src")).add(Fy(n,"imageInline","alt")).add(Py(n,"imageInline")),o.for("upcast").elementToElement({view:gy(e,"imageInline"),model:(e,{writer:t})=>t.createElement("imageInline",e.hasAttribute("src")?{src:e.getAttribute("src")}:void 0)})}_setupClipboardIntegration(){const e=this.editor,t=e.model,o=e.editing.view,n=e.plugins.get("ImageUtils"),i=e.plugins.get("ClipboardPipeline");this.listenTo(i,"inputTransformation",((i,r)=>{const s=Array.from(r.content.getChildren());let a;if(!s.every(n.isBlockImageView))return;a=r.targetRanges?e.editing.mapper.toModelRange(r.targetRanges[0]):t.document.selection.getFirstRange();const l=t.createSelection(a);if("imageInline"===fy(t.schema,l)){const e=new Lu(o.document),t=s.map((t=>1===t.childCount?(Array.from(t.getAttributes()).forEach((o=>e.setAttribute(...o,n.findViewImgElement(t)))),t.getChild(0)):t));r.content=e.createDocumentFragment(t)}})),this.listenTo(i,"contentInsertion",((e,o)=>{"paste"===o.method&&t.change((e=>{const t=e.createRangeIn(o.content);for(const e of t.getItems())e.is("element","imageInline")&&n.setImageNaturalSizeAttributes(e)}))}))}}class Yy extends lr{static get pluginName(){return"ImageCaptionUtils"}static get requires(){return[_y]}getCaptionFromImageModelElement(e){for(const t of e.getChildren())if(t&&t.is("element","caption"))return t;return null}getCaptionFromModelSelection(e){const t=this.editor.plugins.get("ImageUtils"),o=e.getFirstPosition().findAncestor("caption");return o&&t.isBlockImage(o.parent)?o:null}matchImageCaptionViewElement(e){const t=this.editor.plugins.get("ImageUtils");return"figcaption"==e.name&&t.isBlockImageView(e.parent)?{name:!0}:null}}class Qy extends dr{refresh(){const e=this.editor,t=e.plugins.get("ImageCaptionUtils"),o=e.plugins.get("ImageUtils");if(!e.plugins.has(qy))return this.isEnabled=!1,void(this.value=!1);const n=e.model.document.selection,i=n.getSelectedElement();if(!i){const e=t.getCaptionFromModelSelection(n);return this.isEnabled=!!e,void(this.value=!!e)}this.isEnabled=o.isImage(i),this.isEnabled?this.value=!!t.getCaptionFromImageModelElement(i):this.value=!1}execute(e={}){const{focusCaptionOnShow:t}=e;this.editor.model.change((e=>{this.value?this._hideImageCaption(e):this._showImageCaption(e,t)}))}_showImageCaption(e,t){const o=this.editor.model.document.selection,n=this.editor.plugins.get("ImageCaptionEditing"),i=this.editor.plugins.get("ImageUtils");let r=o.getSelectedElement();const s=n._getSavedCaption(r);i.isInlineImage(r)&&(this.editor.execute("imageTypeBlock"),r=o.getSelectedElement());const a=s||e.createElement("caption");e.append(a,r),t&&e.setSelection(a,"in")}_hideImageCaption(e){const t=this.editor,o=t.model.document.selection,n=t.plugins.get("ImageCaptionEditing"),i=t.plugins.get("ImageCaptionUtils");let r,s=o.getSelectedElement();s?r=i.getCaptionFromImageModelElement(s):(r=i.getCaptionFromModelSelection(o),s=r.parent),n._saveCaption(s,r),e.setSelection(s,"on"),e.remove(r)}}class Xy extends lr{static get requires(){return[_y,Yy]}static get pluginName(){return"ImageCaptionEditing"}constructor(e){super(e),this._savedCaptionsMap=new WeakMap}init(){const e=this.editor,t=e.model.schema;t.isRegistered("caption")?t.extend("caption",{allowIn:"imageBlock"}):t.register("caption",{allowIn:"imageBlock",allowContentOf:"$block",isLimit:!0}),e.commands.add("toggleImageCaption",new Qy(this.editor)),this._setupConversion(),this._setupImageTypeCommandsIntegration(),this._registerCaptionReconversion()}_setupConversion(){const e=this.editor,t=e.editing.view,o=e.plugins.get("ImageUtils"),n=e.plugins.get("ImageCaptionUtils"),i=e.t;e.conversion.for("upcast").elementToElement({view:e=>n.matchImageCaptionViewElement(e),model:"caption"}),e.conversion.for("dataDowncast").elementToElement({model:"caption",view:(e,{writer:t})=>o.isBlockImage(e.parent)?t.createContainerElement("figcaption"):null}),e.conversion.for("editingDowncast").elementToElement({model:"caption",view:(e,{writer:n})=>{if(!o.isBlockImage(e.parent))return null;const r=n.createEditableElement("figcaption");n.setCustomProperty("imageCaption",!0,r),r.placeholder=i("Enter image caption"),Sr({view:t,element:r,keepOnFocus:!0});const s=e.parent.getAttribute("alt");return Lk(r,n,{label:s?i("Caption for image: %0",[s]):i("Caption for the image")})}})}_setupImageTypeCommandsIntegration(){const e=this.editor,t=e.plugins.get("ImageUtils"),o=e.plugins.get("ImageCaptionUtils"),n=e.commands.get("imageTypeInline"),i=e.commands.get("imageTypeBlock"),r=e=>{if(!e.return)return;const{oldElement:n,newElement:i}=e.return;if(!n)return;if(t.isBlockImage(n)){const e=o.getCaptionFromImageModelElement(n);if(e)return void this._saveCaption(i,e)}const r=this._getSavedCaption(n);r&&this._saveCaption(i,r)};n&&this.listenTo(n,"execute",r,{priority:"low"}),i&&this.listenTo(i,"execute",r,{priority:"low"})}_getSavedCaption(e){const t=this._savedCaptionsMap.get(e);return t?Ll.fromJSON(t):null}_saveCaption(e,t){this._savedCaptionsMap.set(e,t.toJSON())}_registerCaptionReconversion(){const e=this.editor,t=e.model,o=e.plugins.get("ImageUtils"),n=e.plugins.get("ImageCaptionUtils");t.document.on("change:data",(()=>{const i=t.document.differ.getChanges();for(const t of i){if("alt"!==t.attributeKey)continue;const i=t.range.start.nodeAfter;if(o.isBlockImage(i)){const t=n.getCaptionFromImageModelElement(i);if(!t)return;e.editing.reconvertItem(t)}}}))}}class eA extends lr{static get requires(){return[Yy]}static get pluginName(){return"ImageCaptionUI"}init(){const e=this.editor,t=e.editing.view,o=e.plugins.get("ImageCaptionUtils"),n=e.t;e.ui.componentFactory.add("toggleImageCaption",(i=>{const r=e.commands.get("toggleImageCaption"),s=new Em(i);return s.set({icon:qh.caption,tooltip:!0,isToggleable:!0}),s.bind("isOn","isEnabled").to(r,"value","isEnabled"),s.bind("label").to(r,"value",(e=>n(e?"Toggle caption off":"Toggle caption on"))),this.listenTo(s,"execute",(()=>{e.execute("toggleImageCaption",{focusCaptionOnShow:!0});const n=o.getCaptionFromModelSelection(e.model.document.selection);if(n){const o=e.editing.mapper.toViewElement(n);t.scrollToTheSelection(),t.change((e=>{e.addClass("image__caption_highlighted",o)}))}e.editing.view.focus()})),s}))}}var tA=i(3038),oA={attributes:{"data-cke":!0}};oA.setAttributes=Ar(),oA.insert=_r().bind(null,"head"),oA.domAPI=kr(),oA.insertStyleElement=vr();fr()(tA.A,oA);tA.A&&tA.A.locals&&tA.A.locals;function nA(e){const t=e.map((e=>e.replace("+","\\+")));return new RegExp(`^image\\/(${t.join("|")})$`)}function iA(e){return new Promise(((o,n)=>{const i=e.getAttribute("src");fetch(i).then((e=>e.blob())).then((e=>{const t=rA(e,i),n=t.replace("image/",""),r=new File([e],`image.${n}`,{type:t});o(r)})).catch((e=>e&&"TypeError"===e.name?function(e){return function(e){return new Promise(((o,n)=>{const i=t.document.createElement("img");i.addEventListener("load",(()=>{const e=t.document.createElement("canvas");e.width=i.width,e.height=i.height;e.getContext("2d").drawImage(i,0,0),e.toBlob((e=>e?o(e):n()))})),i.addEventListener("error",(()=>n())),i.src=e}))}(e).then((t=>{const o=rA(t,e),n=o.replace("image/","");return new File([t],`image.${n}`,{type:o})}))}(i).then(o).catch(n):n(e)))}))}function rA(e,t){return e.type?e.type:t.match(/data:(image\/\w+);base64/)?t.match(/data:(image\/\w+);base64/)[1].toLowerCase():"image/jpeg"}class sA extends lr{static get pluginName(){return"ImageUploadUI"}init(){const e=this.editor;e.ui.componentFactory.add("uploadImage",(()=>this._createToolbarButton())),e.ui.componentFactory.add("imageUpload",(()=>this._createToolbarButton())),e.ui.componentFactory.add("menuBar:uploadImage",(()=>this._createMenuBarButton("standalone"))),e.plugins.has("ImageInsertUI")&&e.plugins.get("ImageInsertUI").registerIntegration({name:"upload",observable:()=>e.commands.get("uploadImage"),buttonViewCreator:()=>this._createToolbarButton(),formViewCreator:()=>this._createDropdownButton(),menuBarButtonViewCreator:e=>this._createMenuBarButton(e?"insertOnly":"insertNested")})}_createButton(e){const t=this.editor,o=t.locale,n=t.commands.get("uploadImage"),i=t.config.get("image.upload.types"),r=nA(i),s=new e(t.locale),a=o.t;return s.set({acceptedType:i.map((e=>`image/${e}`)).join(","),allowMultipleFiles:!0,label:a("Upload from computer"),icon:qh.imageUpload}),s.bind("isEnabled").to(n),s.on("done",((e,o)=>{const n=Array.from(o).filter((e=>r.test(e.type)));n.length&&(t.execute("uploadImage",{file:n}),t.editing.view.focus())})),s}_createToolbarButton(){const e=this.editor.locale.t,t=this.editor.plugins.get("ImageInsertUI"),o=this.editor.commands.get("uploadImage"),n=this._createButton(kp);return n.tooltip=!0,n.bind("label").to(t,"isImageSelected",o,"isAccessAllowed",((t,o)=>e(o?t?"Replace image from computer":"Upload image from computer":"You have no image upload permissions."))),n}_createDropdownButton(){const e=this.editor.locale.t,t=this.editor.plugins.get("ImageInsertUI"),o=this._createButton(kp);return o.withText=!0,o.bind("label").to(t,"isImageSelected",(t=>e(t?"Replace from computer":"Upload from computer"))),o.on("execute",(()=>{t.dropdownView.isOpen=!1})),o}_createMenuBarButton(e){const t=this.editor.locale.t,o=this._createButton(fk);switch(o.withText=!0,e){case"standalone":o.label=t("Image from computer");break;case"insertOnly":o.label=t("Image");break;case"insertNested":o.label=t("From computer")}return o}}var aA=i(7504),lA={attributes:{"data-cke":!0}};lA.setAttributes=Ar(),lA.insert=_r().bind(null,"head"),lA.domAPI=kr(),lA.insertStyleElement=vr();fr()(aA.A,lA);aA.A&&aA.A.locals&&aA.A.locals;var cA=i(1230),dA={attributes:{"data-cke":!0}};dA.setAttributes=Ar(),dA.insert=_r().bind(null,"head"),dA.domAPI=kr(),dA.insertStyleElement=vr();fr()(cA.A,dA);cA.A&&cA.A.locals&&cA.A.locals;var uA=i(1160),hA={attributes:{"data-cke":!0}};hA.setAttributes=Ar(),hA.insert=_r().bind(null,"head"),hA.domAPI=kr(),hA.insertStyleElement=vr();fr()(uA.A,hA);uA.A&&uA.A.locals&&uA.A.locals;class mA extends lr{static get pluginName(){return"ImageUploadProgress"}constructor(e){super(e),this.uploadStatusChange=(e,t,o)=>{const n=this.editor,i=t.item,r=i.getAttribute("uploadId");if(!o.consumable.consume(t.item,e.name))return;const s=n.plugins.get("ImageUtils"),a=n.plugins.get(k_),l=r?t.attributeNewValue:null,c=this.placeholder,d=n.editing.mapper.toViewElement(i),u=o.writer;if("reading"==l)return pA(d,u),void gA(s,c,d,u);if("uploading"==l){const e=a.loaders.get(r);return pA(d,u),void(e?(fA(d,u),function(e,t,o,n){const i=function(e){const t=e.createUIElement("div",{class:"ck-progress-bar"});return e.setCustomProperty("progressBar",!0,t),t}(t);t.insert(t.createPositionAt(e,"end"),i),o.on("change:uploadedPercent",((e,t,o)=>{n.change((e=>{e.setStyle("width",o+"%",i)}))}))}(d,u,e,n.editing.view),function(e,t,o,n){if(n.data){const i=e.findViewImgElement(t);o.setAttribute("src",n.data,i)}}(s,d,u,e)):gA(s,c,d,u))}"complete"==l&&a.loaders.get(r)&&function(e,t,o){const n=t.createUIElement("div",{class:"ck-image-upload-complete-icon"});t.insert(t.createPositionAt(e,"end"),n),setTimeout((()=>{o.change((e=>e.remove(e.createRangeOn(n))))}),3e3)}(d,u,n.editing.view),function(e,t){kA(e,t,"progressBar")}(d,u),fA(d,u),function(e,t){t.removeClass("ck-appear",e)}(d,u)},this.placeholder="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw=="}init(){const e=this.editor;e.plugins.has("ImageBlockEditing")&&e.editing.downcastDispatcher.on("attribute:uploadStatus:imageBlock",this.uploadStatusChange),e.plugins.has("ImageInlineEditing")&&e.editing.downcastDispatcher.on("attribute:uploadStatus:imageInline",this.uploadStatusChange)}}function pA(e,t){e.hasClass("ck-appear")||t.addClass("ck-appear",e)}function gA(e,t,o,n){o.hasClass("ck-image-upload-placeholder")||n.addClass("ck-image-upload-placeholder",o);const i=e.findViewImgElement(o);i.getAttribute("src")!==t&&n.setAttribute("src",t,i),bA(o,"placeholder")||n.insert(n.createPositionAfter(i),function(e){const t=e.createUIElement("div",{class:"ck-upload-placeholder-loader"});return e.setCustomProperty("placeholder",!0,t),t}(n))}function fA(e,t){e.hasClass("ck-image-upload-placeholder")&&t.removeClass("ck-image-upload-placeholder",e),kA(e,t,"placeholder")}function bA(e,t){for(const o of e.getChildren())if(o.getCustomProperty(t))return o}function kA(e,t,o){const n=bA(e,o);n&&t.remove(t.createRangeOn(n))}class wA extends dr{constructor(e){super(e),this.set("isAccessAllowed",!0)}refresh(){const e=this.editor,t=e.plugins.get("ImageUtils"),o=e.model.document.selection.getSelectedElement();this.isEnabled=t.isImageAllowed()||t.isImage(o)}execute(e){const t=xi(e.file),o=this.editor.model.document.selection,n=this.editor.plugins.get("ImageUtils"),i=Object.fromEntries(o.getAttributes());t.forEach(((e,t)=>{const r=o.getSelectedElement();if(t&&r&&n.isImage(r)){const t=this.editor.model.createPositionAfter(r);this._uploadImage(e,i,t)}else this._uploadImage(e,i)}))}_uploadImage(e,t,o){const n=this.editor,i=n.plugins.get(k_).createLoader(e),r=n.plugins.get("ImageUtils");i&&r.insertImage({...t,uploadId:i.id},o)}}class _A extends lr{static get requires(){return[k_,Eb,j_,_y]}static get pluginName(){return"ImageUploadEditing"}constructor(e){super(e),e.config.define("image",{upload:{types:["jpeg","png","gif","bmp","webp","tiff"]}}),this._uploadImageElements=new Map}init(){const e=this.editor,t=e.model.document,o=e.conversion,n=e.plugins.get(k_),i=e.plugins.get("ImageUtils"),r=e.plugins.get("ClipboardPipeline"),s=nA(e.config.get("image.upload.types")),a=new wA(e);e.commands.add("uploadImage",a),e.commands.add("imageUpload",a),o.for("upcast").attributeToAttribute({view:{name:"img",key:"uploadId"},model:"uploadId"}),this.listenTo(e.editing.view.document,"clipboardInput",((t,o)=>{if(n=o.dataTransfer,Array.from(n.types).includes("text/html")&&""!==n.getData("text/html"))return;var n;const i=Array.from(o.dataTransfer.files).filter((e=>!!e&&s.test(e.type)));if(!i.length)return;t.stop(),e.model.change((t=>{o.targetRanges&&t.setSelection(o.targetRanges.map((t=>e.editing.mapper.toModelRange(t)))),e.execute("uploadImage",{file:i})}));if(!e.commands.get("uploadImage").isAccessAllowed){const t=e.plugins.get("Notification"),o=e.locale.t;t.showWarning(o("You have no image upload permissions."),{namespace:"image"})}})),this.listenTo(r,"inputTransformation",((t,o)=>{const r=Array.from(e.editing.view.createRangeIn(o.content)).map((e=>e.item)).filter((e=>function(e,t){return!(!e.isInlineImageView(t)||!t.getAttribute("src")||!t.getAttribute("src").match(/^data:image\/\w+;base64,/g)&&!t.getAttribute("src").match(/^blob:/g))}(i,e)&&!e.getAttribute("uploadProcessed"))).map((e=>({promise:iA(e),imageElement:e})));if(!r.length)return;const s=new Lu(e.editing.view.document);for(const e of r){s.setAttribute("uploadProcessed",!0,e.imageElement);const t=n.createLoader(e.promise);t&&(s.setAttribute("src","",e.imageElement),s.setAttribute("uploadId",t.id,e.imageElement))}})),e.editing.view.document.on("dragover",((e,t)=>{t.preventDefault()})),t.on("change",(()=>{const o=t.differ.getChanges({includeChangesInGraveyard:!0}).reverse(),i=new Set;for(const t of o)if("insert"==t.type&&"$text"!=t.name){const o=t.position.nodeAfter,r="$graveyard"==t.position.root.rootName;for(const t of yA(e,o)){const e=t.getAttribute("uploadId");if(!e)continue;const o=n.loaders.get(e);o&&(r?i.has(e)||o.abort():(i.add(e),this._uploadImageElements.set(e,t),"idle"==o.status&&this._readAndUpload(o)))}}})),this.on("uploadComplete",((e,{imageElement:t,data:o})=>{const n=o.urls?o.urls:o;this.editor.model.change((e=>{e.setAttribute("src",n.default,t),this._parseAndSetSrcsetAttributeOnImage(n,t,e),i.setImageNaturalSizeAttributes(t)}))}),{priority:"low"})}afterInit(){const e=this.editor.model.schema;this.editor.plugins.has("ImageBlockEditing")&&e.extend("imageBlock",{allowAttributes:["uploadId","uploadStatus"]}),this.editor.plugins.has("ImageInlineEditing")&&e.extend("imageInline",{allowAttributes:["uploadId","uploadStatus"]})}_readAndUpload(e){const t=this.editor,o=t.model,n=t.locale.t,i=t.plugins.get(k_),s=t.plugins.get(Eb),a=t.plugins.get("ImageUtils"),l=this._uploadImageElements;return o.enqueueChange({isUndoable:!1},(t=>{t.setAttribute("uploadStatus","reading",l.get(e.id))})),e.read().then((()=>{const i=e.upload(),s=l.get(e.id);if(r.isSafari){const e=t.editing.mapper.toViewElement(s),o=a.findViewImgElement(e);t.editing.view.once("render",(()=>{if(!o.parent)return;const e=t.editing.view.domConverter.mapViewToDom(o.parent);if(!e)return;const n=e.style.display;e.style.display="none",e._ckHack=e.offsetHeight,e.style.display=n}))}return t.ui&&t.ui.ariaLiveAnnouncer.announce(n("Uploading image")),o.enqueueChange({isUndoable:!1},(e=>{e.setAttribute("uploadStatus","uploading",s)})),i})).then((i=>{o.enqueueChange({isUndoable:!1},(o=>{const r=l.get(e.id);o.setAttribute("uploadStatus","complete",r),t.ui&&t.ui.ariaLiveAnnouncer.announce(n("Image upload complete")),this.fire("uploadComplete",{data:i,imageElement:r})})),c()})).catch((i=>{if(t.ui&&t.ui.ariaLiveAnnouncer.announce(n("Error during image upload")),"error"!==e.status&&"aborted"!==e.status)throw i;"error"==e.status&&i&&s.showWarning(i,{title:n("Upload failed"),namespace:"upload"}),o.enqueueChange({isUndoable:!1},(t=>{t.remove(l.get(e.id))})),c()}));function c(){o.enqueueChange({isUndoable:!1},(t=>{const o=l.get(e.id);t.removeAttribute("uploadId",o),t.removeAttribute("uploadStatus",o),l.delete(e.id)})),i.destroyLoader(e)}}_parseAndSetSrcsetAttributeOnImage(e,t,o){let n=0;const i=Object.keys(e).filter((e=>{const t=parseInt(e,10);if(!isNaN(t))return n=Math.max(n,t),!0})).map((t=>`${e[t]} ${t}w`)).join(", ");if(""!=i){const e={srcset:i};t.hasAttribute("width")||t.hasAttribute("height")||(e.width=n),o.setAttributes(e,t)}}}function yA(e,t){const o=e.plugins.get("ImageUtils");return Array.from(e.model.createRangeOn(t)).filter((e=>o.isImage(e.item))).map((e=>e.item))}class AA extends lr{static get pluginName(){return"ImageUpload"}static get requires(){return[_A,sA,mA]}}const CA=function(e,t){return function(o,n){if(null==o)return o;if(!ho(o))return e(o,n);for(var i=o.length,r=t?i:-1,s=Object(o);(t?r--:++r{t.setAttribute("resizedWidth",e.width,i),t.removeAttribute("resizedHeight",i),n.setImageNaturalSizeAttributes(i)}))}}class DA extends lr{static get requires(){return[_y]}static get pluginName(){return"ImageResizeEditing"}constructor(e){super(e),e.config.define("image",{resizeUnit:"%",resizeOptions:[{name:"resizeImage:original",value:null,icon:"original"},{name:"resizeImage:custom",value:"custom",icon:"custom"},{name:"resizeImage:25",value:"25",icon:"small"},{name:"resizeImage:50",value:"50",icon:"medium"},{name:"resizeImage:75",value:"75",icon:"large"}]})}init(){const e=this.editor,t=new EA(e);this._registerConverters("imageBlock"),this._registerConverters("imageInline"),e.commands.add("resizeImage",t),e.commands.add("imageResize",t)}afterInit(){this._registerSchema()}_registerSchema(){this.editor.plugins.has("ImageBlockEditing")&&this.editor.model.schema.extend("imageBlock",{allowAttributes:["resizedWidth","resizedHeight"]}),this.editor.plugins.has("ImageInlineEditing")&&this.editor.model.schema.extend("imageInline",{allowAttributes:["resizedWidth","resizedHeight"]})}_registerConverters(e){const t=this.editor,o=t.plugins.get("ImageUtils");t.conversion.for("downcast").add((t=>t.on(`attribute:resizedWidth:${e}`,((e,t,o)=>{if(!o.consumable.consume(t.item,e.name))return;const n=o.writer,i=o.mapper.toViewElement(t.item);null!==t.attributeNewValue?(n.setStyle("width",t.attributeNewValue,i),n.addClass("image_resized",i)):(n.removeStyle("width",i),n.removeClass("image_resized",i))})))),t.conversion.for("dataDowncast").attributeToAttribute({model:{name:e,key:"resizedHeight"},view:e=>({key:"style",value:{height:e}})}),t.conversion.for("editingDowncast").add((t=>t.on(`attribute:resizedHeight:${e}`,((t,n,i)=>{if(!i.consumable.consume(n.item,t.name))return;const r=i.writer,s=i.mapper.toViewElement(n.item),a="imageInline"===e?o.findViewImgElement(s):s;null!==n.attributeNewValue?r.setStyle("height",n.attributeNewValue,a):r.removeStyle("height",a)})))),t.conversion.for("upcast").attributeToAttribute({view:{name:"imageBlock"===e?"figure":"img",styles:{width:/.+/}},model:{key:"resizedWidth",value:e=>ky(e)?null:e.getStyle("width")}}),t.conversion.for("upcast").attributeToAttribute({view:{name:"imageBlock"===e?"figure":"img",styles:{height:/.+/}},model:{key:"resizedHeight",value:e=>ky(e)?null:e.getStyle("height")}})}}const BA=(()=>({small:qh.objectSizeSmall,medium:qh.objectSizeMedium,large:qh.objectSizeLarge,custom:qh.objectSizeCustom,original:qh.objectSizeFull}))();class SA extends lr{static get requires(){return[DA]}static get pluginName(){return"ImageResizeButtons"}constructor(e){super(e),this._resizeUnit=e.config.get("image.resizeUnit")}init(){const e=this.editor,t=e.config.get("image.resizeOptions"),o=e.commands.get("resizeImage");this.bind("isEnabled").to(o);for(const e of t)this._registerImageResizeButton(e);this._registerImageResizeDropdown(t)}_registerImageResizeButton(e){const t=this.editor,{name:o,value:n,icon:i}=e;t.ui.componentFactory.add(o,(o=>{const r=new Em(o),s=t.commands.get("resizeImage"),a=this._getOptionLabelValue(e,!0);if(!BA[i])throw new E("imageresizebuttons-missing-icon",t,e);if(r.set({label:a,icon:BA[i],tooltip:a,isToggleable:!0}),r.bind("isEnabled").to(this),t.plugins.has("ImageCustomResizeUI")&&TA(e)){const e=t.plugins.get("ImageCustomResizeUI");this.listenTo(r,"execute",(()=>{e._showForm(this._resizeUnit)}))}else{const e=n?n+this._resizeUnit:null;r.bind("isOn").to(s,"value",IA(e)),this.listenTo(r,"execute",(()=>{t.execute("resizeImage",{width:e})}))}return r}))}_registerImageResizeDropdown(e){const t=this.editor,o=t.t,n=e.find((e=>!e.value)),i=i=>{const r=t.commands.get("resizeImage"),s=Eg(i,og),a=s.buttonView,l=o("Resize image");return a.set({tooltip:l,commandValue:n.value,icon:BA.medium,isToggleable:!0,label:this._getOptionLabelValue(n),withText:!0,class:"ck-resize-image-button",ariaLabel:l,ariaLabelledBy:void 0}),a.bind("label").to(r,"value",(e=>e&&e.width?e.width:this._getOptionLabelValue(n))),s.bind("isEnabled").to(this),Sg(s,(()=>this._getResizeDropdownListItemDefinitions(e,r)),{ariaLabel:o("Image resize list"),role:"menu"}),this.listenTo(s,"execute",(e=>{"onClick"in e.source?e.source.onClick():(t.execute(e.source.commandName,{width:e.source.commandValue}),t.editing.view.focus())})),s};t.ui.componentFactory.add("resizeImage",i),t.ui.componentFactory.add("imageResize",i)}_getOptionLabelValue(e,t=!1){const o=this.editor.t;return e.label?e.label:t?TA(e)?o("Custom image size"):e.value?o("Resize image to %0",e.value+this._resizeUnit):o("Resize image to the original size"):TA(e)?o("Custom"):e.value?e.value+this._resizeUnit:o("Original")}_getResizeDropdownListItemDefinitions(e,t){const{editor:o}=this,n=new Yi,i=e.map((e=>TA(e)?{...e,valueWithUnits:"custom"}:e.value?{...e,valueWithUnits:`${e.value}${this._resizeUnit}`}:{...e,valueWithUnits:null}));for(const e of i){let r=null;if(o.plugins.has("ImageCustomResizeUI")&&TA(e)){const n=o.plugins.get("ImageCustomResizeUI");r={type:"button",model:new Db({label:this._getOptionLabelValue(e),role:"menuitemradio",withText:!0,icon:null,onClick:()=>{n._showForm(this._resizeUnit)}})};const s=xA(i,"valueWithUnits");r.model.bind("isOn").to(t,"value",PA(s))}else r={type:"button",model:new Db({commandName:"resizeImage",commandValue:e.valueWithUnits,label:this._getOptionLabelValue(e),role:"menuitemradio",withText:!0,icon:null})},r.model.bind("isOn").to(t,"value",IA(e.valueWithUnits));r.model.bind("isEnabled").to(t,"isEnabled"),n.add(r)}return n}}function TA(e){return"custom"===e.value}function IA(e){return t=>null===e&&t===e||null!==t&&t.width===e}function PA(e){return t=>!e.some((e=>IA(e)(t)))}const FA="image_resized";class MA extends lr{static get requires(){return[a_,_y]}static get pluginName(){return"ImageResizeHandles"}init(){const e=this.editor.commands.get("resizeImage");this.bind("isEnabled").to(e),this._setupResizerCreator()}_setupResizerCreator(){const e=this.editor,t=e.editing.view,o=e.plugins.get("ImageUtils");t.addObserver(My),this.listenTo(t.document,"imageLoaded",((n,i)=>{if(!i.target.matches("figure.image.ck-widget > img,figure.image.ck-widget > picture > img,figure.image.ck-widget > a > img,figure.image.ck-widget > a > picture > img,span.image-inline.ck-widget > img,span.image-inline.ck-widget > picture > img"))return;const r=e.editing.view.domConverter,s=r.domToView(i.target),a=o.getImageWidgetFromImageView(s);let l=this.editor.plugins.get(a_).getResizerByViewElement(a);if(l)return void l.redraw();const c=e.editing.mapper,d=c.toModelElement(a);l=e.plugins.get(a_).attachTo({unit:e.config.get("image.resizeUnit"),modelElement:d,viewElement:a,editor:e,getHandleHost:e=>e.querySelector("img"),getResizeHost:()=>r.mapViewToDom(c.toViewElement(d)),isCentered:()=>"alignCenter"==d.getAttribute("imageStyle"),onCommit(o){t.change((e=>{e.removeClass(FA,a)})),e.execute("resizeImage",{width:o})}}),l.on("updateSize",(()=>{a.hasClass(FA)||t.change((e=>{e.addClass(FA,a)}));const e="imageInline"===d.name?s:a;e.getStyle("height")&&t.change((t=>{t.removeStyle("height",e)}))})),l.bind("isEnabled").to(this)}))}}function RA(e){if(!e)return null;const[,t,o]=e.trim().match(/([.,\d]+)(%|px)$/)||[],n=Number.parseFloat(t);return Number.isNaN(n)?null:{value:n,unit:o}}function zA(e,t,o){return"px"===o?{value:t.value,unit:"px"}:{value:t.value/e*100,unit:"%"}}function VA(e){const{editing:t}=e,o=e.plugins.get("ImageUtils").getClosestSelectedImageElement(e.model.document.selection);if(!o)return null;const n=t.mapper.toViewElement(o);return{model:o,view:n,dom:t.view.domConverter.mapViewToDom(n)}}var OA=i(1173),NA={attributes:{"data-cke":!0}};NA.setAttributes=Ar(),NA.insert=_r().bind(null,"head"),NA.domAPI=kr(),NA.insertStyleElement=vr();fr()(OA.A,NA);OA.A&&OA.A.locals&&OA.A.locals;class LA extends pm{constructor(e,t,o){super(e);const n=this.locale.t;this.focusTracker=new Xi,this.keystrokes=new er,this.unit=t,this.labeledInput=this._createLabeledInputView(),this.saveButtonView=this._createButton(n("Save"),qh.check,"ck-button-save"),this.saveButtonView.type="submit",this.cancelButtonView=this._createButton(n("Cancel"),qh.cancel,"ck-button-cancel","cancel"),this._focusables=new Uh,this._validators=o,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.setTemplate({tag:"form",attributes:{class:["ck","ck-image-custom-resize-form","ck-responsive-form"],tabindex:"-1"},children:[this.labeledInput,this.saveButtonView,this.cancelButtonView]})}render(){super.render(),this.keystrokes.listenTo(this.element),bm({view:this}),[this.labeledInput,this.saveButtonView,this.cancelButtonView].forEach((e=>{this._focusables.add(e),this.focusTracker.add(e.element)}))}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}_createButton(e,t,o,n){const i=new Em(this.locale);return i.set({label:e,icon:t,tooltip:!0}),i.extendTemplate({attributes:{class:o}}),n&&i.delegate("execute").to(this,n),i}_createLabeledInputView(){const e=this.locale.t,t=new jp(this.locale,Mg);return t.label=e("Resize image (in %0)",this.unit),t.fieldView.set({step:.1}),t}isValid(){this.resetFormStatus();for(const e of this._validators){const t=e(this);if(t)return this.labeledInput.errorText=t,!1}return!0}resetFormStatus(){this.labeledInput.errorText=null}get rawSize(){const{element:e}=this.labeledInput.fieldView;return e?e.value:null}get parsedSize(){const{rawSize:e}=this;if(null===e)return null;const t=Number.parseFloat(e);return Number.isNaN(t)?null:t}get sizeWithUnits(){const{parsedSize:e,unit:t}=this;return null===e?null:`${e}${t}`}}class HA extends lr{static get requires(){return[Fb]}static get pluginName(){return"ImageCustomResizeUI"}destroy(){super.destroy(),this._form&&this._form.destroy()}_createForm(e){const t=this.editor;this._balloon=this.editor.plugins.get("ContextualBalloon"),this._form=new(fm(LA))(t.locale,e,function(e){const t=e.t;return[e=>""===e.rawSize.trim()?t("The value must not be empty."):null===e.parsedSize?t("The value should be a plain number."):void 0]}(t)),this._form.render(),this.listenTo(this._form,"submit",(()=>{this._form.isValid()&&(t.execute("resizeImage",{width:this._form.sizeWithUnits}),this._hideForm(!0))})),this.listenTo(this._form.labeledInput,"change:errorText",(()=>{t.ui.update()})),this.listenTo(this._form,"cancel",(()=>{this._hideForm(!0)})),this._form.keystrokes.set("Esc",((e,t)=>{this._hideForm(!0),t()})),gm({emitter:this._form,activator:()=>this._isVisible,contextElements:()=>[this._balloon.view.element],callback:()=>this._hideForm()})}_showForm(e){if(this._isVisible)return;this._form||this._createForm(e);const t=this.editor,o=this._form.labeledInput;this._form.disableCssTransitions(),this._form.resetFormStatus(),this._isInBalloon||this._balloon.add({view:this._form,position:Sy(t)});const n=function(e,t){const o=VA(e);if(!o)return null;const n=RA(o.model.getAttribute("resizedWidth")||null);return n?n.unit===t?n:zA(jk(o.dom),{unit:"px",value:new qn(o.dom).width},t):null}(t,e),i=n?n.value.toFixed(1):"",r=function(e,t){const o=VA(e);if(!o)return null;const n=jk(o.dom),i=RA(window.getComputedStyle(o.dom).minWidth)||{value:1,unit:"px"};return{unit:t,lower:Math.max(.1,zA(n,i,t).value),upper:"px"===t?n:100}}(t,e);o.fieldView.value=o.fieldView.element.value=i,r&&Object.assign(o.fieldView,{min:r.lower.toFixed(1),max:Math.ceil(r.upper).toFixed(1)}),this._form.labeledInput.fieldView.select(),this._form.enableCssTransitions()}_hideForm(e=!1){this._isInBalloon&&(this._form.focusTracker.isFocused&&this._form.saveButtonView.focus(),this._balloon.remove(this._form),e&&this.editor.editing.view.focus())}get _isVisible(){return!!this._balloon&&this._balloon.visibleView===this._form}get _isInBalloon(){return!!this._balloon&&this._balloon.hasView(this._form)}}var jA=i(4214),qA={attributes:{"data-cke":!0}};qA.setAttributes=Ar(),qA.insert=_r().bind(null,"head"),qA.domAPI=kr(),qA.insertStyleElement=vr();fr()(jA.A,qA);jA.A&&jA.A.locals&&jA.A.locals;class UA extends dr{constructor(e,t){super(e),this._defaultStyles={imageBlock:!1,imageInline:!1},this._styles=new Map(t.map((e=>{if(e.isDefault)for(const t of e.modelElements)this._defaultStyles[t]=e.name;return[e.name,e]})))}refresh(){const e=this.editor.plugins.get("ImageUtils").getClosestSelectedImageElement(this.editor.model.document.selection);this.isEnabled=!!e,this.isEnabled?e.hasAttribute("imageStyle")?this.value=e.getAttribute("imageStyle"):this.value=this._defaultStyles[e.name]:this.value=!1}execute(e={}){const t=this.editor,o=t.model,n=t.plugins.get("ImageUtils");o.change((t=>{const i=e.value,{setImageSizes:r=!0}=e;let s=n.getClosestSelectedImageElement(o.document.selection);i&&this.shouldConvertImageType(i,s)&&(this.editor.execute(n.isBlockImage(s)?"imageTypeInline":"imageTypeBlock",{setImageSizes:r}),s=n.getClosestSelectedImageElement(o.document.selection)),!i||this._styles.get(i).isDefault?t.removeAttribute("imageStyle",s):t.setAttribute("imageStyle",i,s),r&&n.setImageNaturalSizeAttributes(s)}))}shouldConvertImageType(e,t){return!this._styles.get(e).modelElements.includes(t.name)}}const WA={get inline(){return{name:"inline",title:"In line",icon:qh.objectInline,modelElements:["imageInline"],isDefault:!0}},get alignLeft(){return{name:"alignLeft",title:"Left aligned image",icon:qh.objectLeft,modelElements:["imageBlock","imageInline"],className:"image-style-align-left"}},get alignBlockLeft(){return{name:"alignBlockLeft",title:"Left aligned image",icon:qh.objectBlockLeft,modelElements:["imageBlock"],className:"image-style-block-align-left"}},get alignCenter(){return{name:"alignCenter",title:"Centered image",icon:qh.objectCenter,modelElements:["imageBlock"],className:"image-style-align-center"}},get alignRight(){return{name:"alignRight",title:"Right aligned image",icon:qh.objectRight,modelElements:["imageBlock","imageInline"],className:"image-style-align-right"}},get alignBlockRight(){return{name:"alignBlockRight",title:"Right aligned image",icon:qh.objectBlockRight,modelElements:["imageBlock"],className:"image-style-block-align-right"}},get block(){return{name:"block",title:"Centered image",icon:qh.objectCenter,modelElements:["imageBlock"],isDefault:!0}},get side(){return{name:"side",title:"Side image",icon:qh.objectRight,modelElements:["imageBlock"],className:"image-style-side"}}},$A=(()=>({full:qh.objectFullWidth,left:qh.objectBlockLeft,right:qh.objectBlockRight,center:qh.objectCenter,inlineLeft:qh.objectLeft,inlineRight:qh.objectRight,inline:qh.objectInline}))(),GA=[{name:"imageStyle:wrapText",title:"Wrap text",defaultItem:"imageStyle:alignLeft",items:["imageStyle:alignLeft","imageStyle:alignRight"]},{name:"imageStyle:breakText",title:"Break text",defaultItem:"imageStyle:block",items:["imageStyle:alignBlockLeft","imageStyle:block","imageStyle:alignBlockRight"]}];function KA(e){D("image-style-configuration-definition-invalid",e)}const ZA={normalizeStyles:function(e){const t=(e.configuredStyles.options||[]).map((e=>function(e){e="string"==typeof e?WA[e]?{...WA[e]}:{name:e}:function(e,t){const o={...t};for(const n in e)Object.prototype.hasOwnProperty.call(t,n)||(o[n]=e[n]);return o}(WA[e.name],e);"string"==typeof e.icon&&(e.icon=$A[e.icon]||e.icon);return e}(e))).filter((t=>function(e,{isBlockPluginLoaded:t,isInlinePluginLoaded:o}){const{modelElements:n,name:i}=e;if(!(n&&n.length&&i))return KA({style:e}),!1;{const i=[t?"imageBlock":null,o?"imageInline":null];if(!n.some((e=>i.includes(e))))return D("image-style-missing-dependency",{style:e,missingPlugins:n.map((e=>"imageBlock"===e?"ImageBlockEditing":"ImageInlineEditing"))}),!1}return!0}(t,e)));return t},getDefaultStylesConfiguration:function(e,t){return e&&t?{options:["inline","alignLeft","alignRight","alignCenter","alignBlockLeft","alignBlockRight","block","side"]}:e?{options:["block","side"]}:t?{options:["inline","alignLeft","alignRight"]}:{}},getDefaultDropdownDefinitions:function(e){return e.has("ImageBlockEditing")&&e.has("ImageInlineEditing")?[...GA]:[]},warnInvalidStyle:KA,DEFAULT_OPTIONS:WA,DEFAULT_ICONS:$A,DEFAULT_DROPDOWN_DEFINITIONS:GA};function JA(e,t){for(const o of t)if(o.name===e)return o}class YA extends lr{static get pluginName(){return"ImageStyleEditing"}static get requires(){return[_y]}init(){const{normalizeStyles:e,getDefaultStylesConfiguration:t}=ZA,o=this.editor,n=o.plugins.has("ImageBlockEditing"),i=o.plugins.has("ImageInlineEditing");o.config.define("image.styles",t(n,i)),this.normalizedStyles=e({configuredStyles:o.config.get("image.styles"),isBlockPluginLoaded:n,isInlinePluginLoaded:i}),this._setupConversion(n,i),this._setupPostFixer(),o.commands.add("imageStyle",new UA(o,this.normalizedStyles))}_setupConversion(e,t){const o=this.editor,n=o.model.schema,i=(r=this.normalizedStyles,(e,t,o)=>{if(!o.consumable.consume(t.item,e.name))return;const n=JA(t.attributeNewValue,r),i=JA(t.attributeOldValue,r),s=o.mapper.toViewElement(t.item),a=o.writer;i&&a.removeClass(i.className,s),n&&a.addClass(n.className,s)});var r;const s=function(e){const t={imageInline:e.filter((e=>!e.isDefault&&e.modelElements.includes("imageInline"))),imageBlock:e.filter((e=>!e.isDefault&&e.modelElements.includes("imageBlock")))};return(e,o,n)=>{if(!o.modelRange)return;const i=o.viewItem,r=Qi(o.modelRange.getItems());if(r&&n.schema.checkAttribute(r,"imageStyle"))for(const e of t[r.name])n.consumable.consume(i,{classes:e.className})&&n.writer.setAttribute("imageStyle",e.name,r)}}(this.normalizedStyles);o.editing.downcastDispatcher.on("attribute:imageStyle",i),o.data.downcastDispatcher.on("attribute:imageStyle",i),e&&(n.extend("imageBlock",{allowAttributes:"imageStyle"}),o.data.upcastDispatcher.on("element:figure",s,{priority:"low"})),t&&(n.extend("imageInline",{allowAttributes:"imageStyle"}),o.data.upcastDispatcher.on("element:img",s,{priority:"low"}))}_setupPostFixer(){const e=this.editor,t=e.model.document,o=e.plugins.get(_y),n=new Map(this.normalizedStyles.map((e=>[e.name,e])));t.registerPostFixer((e=>{let i=!1;for(const r of t.differ.getChanges())if("insert"==r.type||"attribute"==r.type&&"imageStyle"==r.attributeKey){let t="insert"==r.type?r.position.nodeAfter:r.range.start.nodeAfter;if(t&&t.is("element","paragraph")&&t.childCount>0&&(t=t.getChild(0)),!o.isImage(t))continue;const s=t.getAttribute("imageStyle");if(!s)continue;const a=n.get(s);a&&a.modelElements.includes(t.name)||(e.removeAttribute("imageStyle",t),i=!0)}return i}))}}var QA=i(7879),XA={attributes:{"data-cke":!0}};XA.setAttributes=Ar(),XA.insert=_r().bind(null,"head"),XA.domAPI=kr(),XA.insertStyleElement=vr();fr()(QA.A,XA);QA.A&&QA.A.locals&&QA.A.locals;class eC extends lr{static get requires(){return[YA]}static get pluginName(){return"ImageStyleUI"}get localizedDefaultStylesTitles(){const e=this.editor.t;return{"Wrap text":e("Wrap text"),"Break text":e("Break text"),"In line":e("In line"),"Full size image":e("Full size image"),"Side image":e("Side image"),"Left aligned image":e("Left aligned image"),"Centered image":e("Centered image"),"Right aligned image":e("Right aligned image")}}init(){const e=this.editor.plugins,t=this.editor.config.get("image.toolbar")||[],o=tC(e.get("ImageStyleEditing").normalizedStyles,this.localizedDefaultStylesTitles);for(const e of o)this._createButton(e);const n=tC([...t.filter(U),...ZA.getDefaultDropdownDefinitions(e)],this.localizedDefaultStylesTitles);for(const e of n)this._createDropdown(e,o)}_createDropdown(e,t){const o=this.editor.ui.componentFactory;o.add(e.name,(n=>{let i;const{defaultItem:r,items:s,title:a}=e,l=s.filter((e=>t.find((({name:t})=>oC(t)===e)))).map((e=>{const t=o.create(e);return e===r&&(i=t),t}));s.length!==l.length&&ZA.warnInvalidStyle({dropdown:e});const c=Eg(n,yg),d=c.buttonView,u=d.arrowView;return Dg(c,l,{enableActiveItemFocusOnDropdownOpen:!0}),d.set({label:nC(a,i.label),class:null,tooltip:!0}),u.unbind("label"),u.set({label:a}),d.bind("icon").toMany(l,"isOn",((...e)=>{const t=e.findIndex(Fi);return t<0?i.icon:l[t].icon})),d.bind("label").toMany(l,"isOn",((...e)=>{const t=e.findIndex(Fi);return nC(a,t<0?i.label:l[t].label)})),d.bind("isOn").toMany(l,"isOn",((...e)=>e.some(Fi))),d.bind("class").toMany(l,"isOn",((...e)=>e.some(Fi)?"ck-splitbutton_flatten":void 0)),d.on("execute",(()=>{l.some((({isOn:e})=>e))?c.isOpen=!c.isOpen:i.fire("execute")})),c.bind("isEnabled").toMany(l,"isEnabled",((...e)=>e.some(Fi))),this.listenTo(c,"execute",(()=>{this.editor.editing.view.focus()})),c}))}_createButton(e){const t=e.name;this.editor.ui.componentFactory.add(oC(t),(o=>{const n=this.editor.commands.get("imageStyle"),i=new Em(o);return i.set({label:e.title,icon:e.icon,tooltip:!0,isToggleable:!0}),i.bind("isEnabled").to(n,"isEnabled"),i.bind("isOn").to(n,"value",(e=>e===t)),i.on("execute",this._executeCommand.bind(this,t)),i}))}_executeCommand(e){this.editor.execute("imageStyle",{value:e}),this.editor.editing.view.focus()}}function tC(e,t){for(const o of e)t[o.title]&&(o.title=t[o.title]);return e}function oC(e){return`imageStyle:${e}`}function nC(e,t){return(e?e+": ":"")+t}const iC=Symbol("isWpButtonMacroSymbol");function rC(e){const t=e.getSelectedElement();return!(!t||!function(e){return!!e.getCustomProperty(iC)&&Rk(e)}(t))}class sC extends lr{static get pluginName(){return"OPChildPagesEditing"}static get buttonName(){return"insertChildPages"}init(){const e=this.editor,t=e.model,o=e.conversion;t.schema.register("op-macro-child-pages",{allowWhere:["$block"],allowAttributes:["page"],isBlock:!0,isLimit:!0}),o.for("upcast").elementToElement({view:{name:"macro",classes:"child_pages"},model:(e,{writer:t})=>{const o=e.getAttribute("data-page")||"",n="true"==e.getAttribute("data-include-parent");return t.createElement("op-macro-child-pages",{page:o,includeParent:n})}}),o.for("editingDowncast").elementToElement({model:"op-macro-child-pages",view:(e,{writer:t})=>this.createMacroViewElement(e,t)}).add((e=>e.on("attribute:page",this.modelAttributeToView.bind(this)))).add((e=>e.on("attribute:includeParent",this.modelAttributeToView.bind(this)))),o.for("dataDowncast").elementToElement({model:"op-macro-child-pages",view:(e,{writer:t})=>t.createContainerElement("macro",{class:"child_pages","data-page":e.getAttribute("page")||"","data-include-parent":e.getAttribute("includeParent")||""})}),e.ui.componentFactory.add(sC.buttonName,(t=>{const o=new Em(t);return o.set({label:window.I18n.t("js.editor.macro.child_pages.button"),withText:!0}),o.on("execute",(()=>{e.model.change((t=>{const o=t.createElement("op-macro-child-pages",{});e.model.insertContent(o,e.model.document.selection)}))})),o}))}modelAttributeToView(e,t,o){const n=t.item;if(!n.is("element","op-macro-child-pages"))return;o.consumable.consume(t.item,e.name);const i=o.mapper.toViewElement(n);o.writer.remove(o.writer.createRangeIn(i)),this.setPlaceholderContent(o.writer,n,i)}macroLabel(){return window.I18n.t("js.editor.macro.child_pages.text")}pageLabel(e){return e&&e.length>0?e:window.I18n.t("js.editor.macro.child_pages.this_page")}includeParentText(e){return e?` (${window.I18n.t("js.editor.macro.child_pages.include_parent")})`:""}createMacroViewElement(e,t){const o=t.createContainerElement("div");return this.setPlaceholderContent(t,e,o),function(e,t,o){return t.setCustomProperty(iC,!0,e),zk(e,t,{label:o})}(o,t,{label:this.macroLabel()})}setPlaceholderContent(e,t,o){const n=t.getAttribute("page"),i=t.getAttribute("includeParent"),r=this.macroLabel(),s=this.pageLabel(n),a=e.createContainerElement("span",{class:"macro-value"});let l=[e.createText(`${r} `)];e.insert(e.createPositionAt(a,0),e.createText(`${s}`)),l.push(a),l.push(e.createText(this.includeParentText(i))),e.insert(e.createPositionAt(o,0),l)}}class aC extends lr{static get requires(){return[Fb]}static get pluginName(){return"OPChildPagesToolbar"}init(){const e=this.editor,t=this.editor.model,o=Gk(e);l_(e,"opEditChildPagesMacroButton",(e=>{const n=o.services.macros,i=e.getAttribute("page"),r=e.getAttribute("includeParent"),s=i&&i.length>0?i:"";n.configureChildPages(s,r).then((o=>t.change((t=>{t.setAttribute("page",o.page,e),t.setAttribute("includeParent",o.includeParent,e)}))))}))}afterInit(){d_(this,this.editor,"OPChildPages",rC)}}class lC extends dr{constructor(e){super(e),this.affectsData=!1}execute(){const e=this.editor.model,t=e.document.selection;let o=e.schema.getLimitElement(t);if(t.containsEntireContent(o)||!cC(e.schema,o))do{if(o=o.parent,!o)return}while(!cC(e.schema,o));e.change((e=>{e.setSelection(o,"in")}))}}function cC(e,t){return e.isLimit(t)&&(e.checkChild(t,"$text")||e.checkChild(t,"paragraph"))}const dC=yi("Ctrl+A");class uC extends lr{static get pluginName(){return"SelectAllEditing"}init(){const e=this.editor,t=e.t,o=e.editing.view.document;e.commands.add("selectAll",new lC(e)),this.listenTo(o,"keydown",((t,o)=>{_i(o)===dC&&(e.execute("selectAll"),o.preventDefault())})),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Select all"),keystroke:"CTRL+A"}]})}}class hC extends lr{static get pluginName(){return"SelectAllUI"}init(){const e=this.editor;e.ui.componentFactory.add("selectAll",(()=>{const e=this._createButton(Em);return e.set({tooltip:!0}),e})),e.ui.componentFactory.add("menuBar:selectAll",(()=>this._createButton(ip)))}_createButton(e){const t=this.editor,o=t.locale,n=t.commands.get("selectAll"),i=new e(t.locale),r=o.t;return i.set({label:r("Select all"),icon:'',keystroke:"Ctrl+A"}),i.bind("isEnabled").to(n,"isEnabled"),this.listenTo(i,"execute",(()=>{t.execute("selectAll"),t.editing.view.focus()})),i}}class mC extends lr{static get requires(){return[uC,hC]}static get pluginName(){return"SelectAll"}}const pC="ckCsrfToken",gC="abcdefghijklmnopqrstuvwxyz0123456789";function fC(){let e=function(e){e=e.toLowerCase();const t=document.cookie.split(";");for(const o of t){const t=o.split("=");if(decodeURIComponent(t[0].trim().toLowerCase())===e)return decodeURIComponent(t[1])}return null}(pC);var t,o;return e&&40==e.length||(e=function(e){let t="";const o=new Uint8Array(e);window.crypto.getRandomValues(o);for(let e=0;e.5?n.toUpperCase():n}return t}(40),t=pC,o=e,document.cookie=encodeURIComponent(t)+"="+encodeURIComponent(o)+";path=/"),e}class bC{constructor(e,t,o){this.loader=e,this.url=t,this.t=o}upload(){return this.loader.file.then((e=>new Promise(((t,o)=>{this._initRequest(),this._initListeners(t,o,e),this._sendRequest(e)}))))}abort(){this.xhr&&this.xhr.abort()}_initRequest(){const e=this.xhr=new XMLHttpRequest;e.open("POST",this.url,!0),e.responseType="json"}_initListeners(e,t,o){const n=this.xhr,i=this.loader,r=(0,this.t)("Cannot upload file:")+` ${o.name}.`;n.addEventListener("error",(()=>t(r))),n.addEventListener("abort",(()=>t())),n.addEventListener("load",(()=>{const o=n.response;if(!o||!o.uploaded)return t(o&&o.error&&o.error.message?o.error.message:r);e({default:o.url})})),n.upload&&n.upload.addEventListener("progress",(e=>{e.lengthComputable&&(i.uploadTotal=e.total,i.uploaded=e.loaded)}))}_sendRequest(e){const t=new FormData;t.append("upload",e),t.append("ckCsrfToken",fC()),this.xhr.send(t)}}function kC(e,t,o,n){let i,r=null;"function"==typeof n?i=n:(r=e.commands.get(n),i=()=>{e.execute(n)}),e.model.document.on("change:data",((s,a)=>{if(r&&!r.isEnabled||!t.isEnabled)return;const l=Qi(e.model.document.selection.getRanges());if(!l.isCollapsed)return;if(a.isUndo||!a.isLocal)return;const c=Array.from(e.model.document.differ.getChanges()),d=c[0];if(1!=c.length||"insert"!==d.type||"$text"!=d.name||1!=d.length)return;const u=d.position.parent;if(u.is("element","codeBlock"))return;if(u.is("element","listItem")&&"function"!=typeof n&&!["numberedList","bulletedList","todoList"].includes(n))return;if(r&&!0===r.value)return;const h=u.getChild(0),m=e.model.createRangeOn(h);if(!m.containsRange(l)&&!l.end.isEqual(m.end))return;const p=o.exec(h.data.substr(0,l.end.offset));p&&e.model.enqueueChange((t=>{const o=t.createPositionAt(u,0),n=t.createPositionAt(u,p[0].length),r=new cc(o,n);if(!1!==i({match:p})){t.remove(r);const o=e.model.document.selection.getFirstRange(),n=t.createRangeIn(u);!u.isEmpty||n.isEqual(o)||n.containsRange(o,!0)||t.remove(u)}r.detach(),e.model.enqueueChange((()=>{e.plugins.get("Delete").requestUndoOnBackspace()}))}))}))}function wC(e,t,o,n){let i,r;o instanceof RegExp?i=o:r=o,r=r||(e=>{let t;const o=[],n=[];for(;null!==(t=i.exec(e))&&!(t&&t.length<4);){let{index:e,1:i,2:r,3:s}=t;const a=i+r+s;e+=t[0].length-a.length;const l=[e,e+i.length],c=[e+i.length+r.length,e+i.length+r.length+s.length];o.push(l),o.push(c),n.push([e+i.length,e+i.length+r.length])}return{remove:o,format:n}}),e.model.document.on("change:data",((o,i)=>{if(i.isUndo||!i.isLocal||!t.isEnabled)return;const s=e.model,a=s.document.selection;if(!a.isCollapsed)return;const l=Array.from(s.document.differ.getChanges()),c=l[0];if(1!=l.length||"insert"!==c.type||"$text"!=c.name||1!=c.length)return;const d=a.focus,u=d.parent,{text:h,range:m}=function(e,t){let o=e.start;const n=Array.from(e.getItems()).reduce(((e,n)=>!n.is("$text")&&!n.is("$textProxy")||n.getAttribute("code")?(o=t.createPositionAfter(n),""):e+n.data),"");return{text:n,range:t.createRange(o,e.end)}}(s.createRange(s.createPositionAt(u,0),d),s),p=r(h),g=_C(m.start,p.format,s),f=_C(m.start,p.remove,s);g.length&&f.length&&s.enqueueChange((t=>{if(!1!==n(t,g)){for(const e of f.reverse())t.remove(e);s.enqueueChange((()=>{e.plugins.get("Delete").requestUndoOnBackspace()}))}}))}))}function _C(e,t,o){return t.filter((e=>void 0!==e[0]&&void 0!==e[1])).map((t=>o.createRange(e.getShiftedBy(t[0]),e.getShiftedBy(t[1]))))}function yC(e,t){return(o,n)=>{if(!e.commands.get(t).isEnabled)return!1;const i=e.model.schema.getValidRanges(n,t);for(const e of i)o.setAttribute(t,!0,e);o.removeSelectionAttribute(t)}}class AC extends dr{constructor(e,t){super(e),this.attributeKey=t}refresh(){const e=this.editor.model,t=e.document;this.value=this._getValueFromFirstAllowedNode(),this.isEnabled=e.schema.checkAttributeInSelection(t.selection,this.attributeKey)}execute(e={}){const t=this.editor.model,o=t.document.selection,n=void 0===e.forceValue?!this.value:e.forceValue;t.change((e=>{if(o.isCollapsed)n?e.setSelectionAttribute(this.attributeKey,!0):e.removeSelectionAttribute(this.attributeKey);else{const i=t.schema.getValidRanges(o.getRanges(),this.attributeKey);for(const t of i)n?e.setAttribute(this.attributeKey,n,t):e.removeAttribute(this.attributeKey,t)}}))}_getValueFromFirstAllowedNode(){const e=this.editor.model,t=e.schema,o=e.document.selection;if(o.isCollapsed)return o.hasAttribute(this.attributeKey);for(const e of o.getRanges())for(const o of e.getItems())if(t.checkAttribute(o,this.attributeKey))return o.hasAttribute(this.attributeKey);return!1}}const CC="bold";class vC extends lr{static get pluginName(){return"BoldEditing"}init(){const e=this.editor,t=this.editor.t;e.model.schema.extend("$text",{allowAttributes:CC}),e.model.schema.setAttributeProperties(CC,{isFormatting:!0,copyOnEnter:!0}),e.conversion.attributeToElement({model:CC,view:"strong",upcastAlso:["b",e=>{const t=e.getStyle("font-weight");return t&&("bold"==t||Number(t)>=600)?{name:!0,styles:["font-weight"]}:null}]}),e.commands.add(CC,new AC(e,CC)),e.keystrokes.set("CTRL+B",CC),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Bold text"),keystroke:"CTRL+B"}]})}}function xC({editor:e,commandName:t,plugin:o,icon:n,label:i,keystroke:r}){return s=>{const a=e.commands.get(t),l=new s(e.locale);return l.set({label:i,icon:n,keystroke:r,isToggleable:!0}),l.bind("isEnabled").to(a,"isEnabled"),l.bind("isOn").to(a,"value"),l instanceof ip?l.set({role:"menuitemcheckbox"}):l.set({tooltip:!0}),o.listenTo(l,"execute",(()=>{e.execute(t),e.editing.view.focus()})),l}}const EC="bold";class DC extends lr{static get pluginName(){return"BoldUI"}init(){const e=this.editor,t=e.locale.t,o=xC({editor:e,commandName:EC,plugin:this,icon:qh.bold,label:t("Bold"),keystroke:"CTRL+B"});e.ui.componentFactory.add(EC,(()=>o(Em))),e.ui.componentFactory.add("menuBar:"+EC,(()=>o(ip)))}}const BC="code";class SC extends lr{static get pluginName(){return"CodeEditing"}static get requires(){return[kw]}init(){const e=this.editor,t=this.editor.t;e.model.schema.extend("$text",{allowAttributes:BC}),e.model.schema.setAttributeProperties(BC,{isFormatting:!0,copyOnEnter:!1}),e.conversion.attributeToElement({model:BC,view:"code",upcastAlso:{styles:{"word-wrap":"break-word"}}}),e.commands.add(BC,new AC(e,BC)),e.plugins.get(kw).registerAttribute(BC),Bw(e,BC,"code","ck-code_selected"),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Move out of an inline code style"),keystroke:[["arrowleft","arrowleft"],["arrowright","arrowright"]]}]})}}var TC=i(9248),IC={attributes:{"data-cke":!0}};IC.setAttributes=Ar(),IC.insert=_r().bind(null,"head"),IC.domAPI=kr(),IC.insertStyleElement=vr();fr()(TC.A,IC);TC.A&&TC.A.locals&&TC.A.locals;const PC="code";class FC extends lr{static get pluginName(){return"CodeUI"}init(){const e=this.editor,t=e.locale.t,o=xC({editor:e,commandName:PC,plugin:this,icon:'',label:t("Code")});e.ui.componentFactory.add(PC,(()=>o(Em))),e.ui.componentFactory.add("menuBar:"+PC,(()=>o(ip)))}}const MC="italic";class RC extends lr{static get pluginName(){return"ItalicEditing"}init(){const e=this.editor,t=this.editor.t;e.model.schema.extend("$text",{allowAttributes:MC}),e.model.schema.setAttributeProperties(MC,{isFormatting:!0,copyOnEnter:!0}),e.conversion.attributeToElement({model:MC,view:"i",upcastAlso:["em",{styles:{"font-style":"italic"}}]}),e.commands.add(MC,new AC(e,MC)),e.keystrokes.set("CTRL+I",MC),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Italic text"),keystroke:"CTRL+I"}]})}}const zC="italic";class VC extends lr{static get pluginName(){return"ItalicUI"}init(){const e=this.editor,t=e.locale.t,o=xC({editor:e,commandName:zC,plugin:this,icon:'',keystroke:"CTRL+I",label:t("Italic")});e.ui.componentFactory.add(zC,(()=>o(Em))),e.ui.componentFactory.add("menuBar:"+zC,(()=>o(ip)))}}const OC="strikethrough";class NC extends lr{static get pluginName(){return"StrikethroughEditing"}init(){const e=this.editor,t=this.editor.t;e.model.schema.extend("$text",{allowAttributes:OC}),e.model.schema.setAttributeProperties(OC,{isFormatting:!0,copyOnEnter:!0}),e.conversion.attributeToElement({model:OC,view:"s",upcastAlso:["del","strike",{styles:{"text-decoration":"line-through"}}]}),e.commands.add(OC,new AC(e,OC)),e.keystrokes.set("CTRL+SHIFT+X","strikethrough"),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Strikethrough text"),keystroke:"CTRL+SHIFT+X"}]})}}const LC="strikethrough";class HC extends lr{static get pluginName(){return"StrikethroughUI"}init(){const e=this.editor,t=e.locale.t,o=xC({editor:e,commandName:LC,plugin:this,icon:'',keystroke:"CTRL+SHIFT+X",label:t("Strikethrough")});e.ui.componentFactory.add(LC,(()=>o(Em))),e.ui.componentFactory.add("menuBar:"+LC,(()=>o(ip)))}}class jC extends dr{refresh(){this.value=this._getValue(),this.isEnabled=this._checkEnabled()}execute(e={}){const t=this.editor.model,o=t.schema,n=t.document.selection,i=Array.from(n.getSelectedBlocks()),r=void 0===e.forceValue?!this.value:e.forceValue;t.change((e=>{if(r){const t=i.filter((e=>qC(e)||WC(o,e)));this._applyQuote(e,t)}else this._removeQuote(e,i.filter(qC))}))}_getValue(){const e=Qi(this.editor.model.document.selection.getSelectedBlocks());return!(!e||!qC(e))}_checkEnabled(){if(this.value)return!0;const e=this.editor.model.document.selection,t=this.editor.model.schema,o=Qi(e.getSelectedBlocks());return!!o&&WC(t,o)}_removeQuote(e,t){UC(e,t).reverse().forEach((t=>{if(t.start.isAtStart&&t.end.isAtEnd)return void e.unwrap(t.start.parent);if(t.start.isAtStart){const o=e.createPositionBefore(t.start.parent);return void e.move(t,o)}t.end.isAtEnd||e.split(t.end);const o=e.createPositionAfter(t.end.parent);e.move(t,o)}))}_applyQuote(e,t){const o=[];UC(e,t).reverse().forEach((t=>{let n=qC(t.start);n||(n=e.createElement("blockQuote"),e.wrap(t,n)),o.push(n)})),o.reverse().reduce(((t,o)=>t.nextSibling==o?(e.merge(e.createPositionAfter(t)),t):o))}}function qC(e){return"blockQuote"==e.parent.name?e.parent:null}function UC(e,t){let o,n=0;const i=[];for(;n{const n=e.model.document.differ.getChanges();for(const e of n)if("insert"==e.type){const n=e.position.nodeAfter;if(!n)continue;if(n.is("element","blockQuote")&&n.isEmpty)return o.remove(n),!0;if(n.is("element","blockQuote")&&!t.checkChild(e.position,n))return o.unwrap(n),!0;if(n.is("element")){const e=o.createRangeIn(n);for(const n of e.getItems())if(n.is("element","blockQuote")&&!t.checkChild(o.createPositionBefore(n),n))return o.unwrap(n),!0}}else if("remove"==e.type){const t=e.position.parent;if(t.is("element","blockQuote")&&t.isEmpty)return o.remove(t),!0}return!1}));const o=this.editor.editing.view.document,n=e.model.document.selection,i=e.commands.get("blockQuote");this.listenTo(o,"enter",((t,o)=>{if(!n.isCollapsed||!i.value)return;n.getLastPosition().parent.isEmpty&&(e.execute("blockQuote"),e.editing.view.scrollToTheSelection(),o.preventDefault(),t.stop())}),{context:"blockquote"}),this.listenTo(o,"delete",((t,o)=>{if("backward"!=o.direction||!n.isCollapsed||!i.value)return;const r=n.getLastPosition().parent;r.isEmpty&&!r.previousSibling&&(e.execute("blockQuote"),e.editing.view.scrollToTheSelection(),o.preventDefault(),t.stop())}),{context:"blockquote"})}}var GC=i(1501),KC={attributes:{"data-cke":!0}};KC.setAttributes=Ar(),KC.insert=_r().bind(null,"head"),KC.domAPI=kr(),KC.insertStyleElement=vr();fr()(GC.A,KC);GC.A&&GC.A.locals&&GC.A.locals;class ZC extends lr{static get pluginName(){return"BlockQuoteUI"}init(){const e=this.editor;e.ui.componentFactory.add("blockQuote",(()=>{const e=this._createButton(Em);return e.set({tooltip:!0}),e})),e.ui.componentFactory.add("menuBar:blockQuote",(()=>{const e=this._createButton(ip);return e.set({role:"menuitemcheckbox"}),e}))}_createButton(e){const t=this.editor,o=t.locale,n=t.commands.get("blockQuote"),i=new e(t.locale),r=o.t;return i.set({label:r("Block quote"),icon:qh.quote,isToggleable:!0}),i.bind("isEnabled").to(n,"isEnabled"),i.bind("isOn").to(n,"value"),this.listenTo(i,"execute",(()=>{t.execute("blockQuote"),t.editing.view.focus()})),i}}class JC extends dr{constructor(e){super(e),this._isEnabledBasedOnSelection=!1}refresh(){const e=this.editor.model,t=Qi(e.document.selection.getSelectedBlocks());this.value=!!t&&t.is("element","paragraph"),this.isEnabled=!!t&&YC(t,e.schema)}execute(e={}){const t=this.editor.model,o=t.document,n=e.selection||o.selection;t.canEditAt(n)&&t.change((e=>{const o=n.getSelectedBlocks();for(const n of o)!n.is("element","paragraph")&&YC(n,t.schema)&&e.rename(n,"paragraph")}))}}function YC(e,t){return t.checkChild(e.parent,"paragraph")&&!t.isObject(e)}class QC extends dr{constructor(e){super(e),this._isEnabledBasedOnSelection=!1}execute(e){const t=this.editor.model,o=e.attributes;let n=e.position;t.canEditAt(n)&&t.change((e=>{if(n=this._findPositionToInsertParagraph(n,e),!n)return;const i=e.createElement("paragraph");o&&t.schema.setAllowedAttributes(i,o,e),t.insertContent(i,n),e.setSelection(i,"in")}))}_findPositionToInsertParagraph(e,t){const o=this.editor.model;if(o.schema.checkChild(e,"paragraph"))return e;const n=o.schema.findAllowedParent(e,"paragraph");if(!n)return null;const i=e.parent,r=o.schema.checkChild(i,"$text");return i.isEmpty||r&&e.isAtEnd?o.createPositionAfter(i):!i.isEmpty&&r&&e.isAtStart?o.createPositionBefore(i):t.split(e,n).position}}class XC extends lr{static get pluginName(){return"Paragraph"}init(){const e=this.editor,t=e.model;e.commands.add("paragraph",new JC(e)),e.commands.add("insertParagraph",new QC(e)),t.schema.register("paragraph",{inheritAllFrom:"$block"}),e.conversion.elementToElement({model:"paragraph",view:"p"}),e.conversion.for("upcast").elementToElement({model:(e,{writer:t})=>XC.paragraphLikeElements.has(e.name)?e.isEmpty?null:t.createElement("paragraph"):null,view:/.+/,converterPriority:"low"})}}XC.paragraphLikeElements=new Set(["blockquote","dd","div","dt","h1","h2","h3","h4","h5","h6","li","p","td","th"]);const ev=XC;class tv extends dr{constructor(e,t){super(e),this.modelElements=t}refresh(){const e=Qi(this.editor.model.document.selection.getSelectedBlocks());this.value=!!e&&this.modelElements.includes(e.name)&&e.name,this.isEnabled=!!e&&this.modelElements.some((t=>ov(e,t,this.editor.model.schema)))}execute(e){const t=this.editor.model,o=t.document,n=e.value;t.change((e=>{const i=Array.from(o.selection.getSelectedBlocks()).filter((e=>ov(e,n,t.schema)));for(const t of i)t.is("element",n)||e.rename(t,n)}))}}function ov(e,t,o){return o.checkChild(e.parent,t)&&!o.isObject(e)}const nv="paragraph";class iv extends lr{static get pluginName(){return"HeadingEditing"}constructor(e){super(e),e.config.define("heading",{options:[{model:"paragraph",title:"Paragraph",class:"ck-heading_paragraph"},{model:"heading1",view:"h2",title:"Heading 1",class:"ck-heading_heading1"},{model:"heading2",view:"h3",title:"Heading 2",class:"ck-heading_heading2"},{model:"heading3",view:"h4",title:"Heading 3",class:"ck-heading_heading3"}]})}static get requires(){return[ev]}init(){const e=this.editor,t=e.config.get("heading.options"),o=[];for(const n of t)"paragraph"!==n.model&&(e.model.schema.register(n.model,{inheritAllFrom:"$block"}),e.conversion.elementToElement(n),o.push(n.model));this._addDefaultH1Conversion(e),e.commands.add("heading",new tv(e,o))}afterInit(){const e=this.editor,t=e.commands.get("enter"),o=e.config.get("heading.options");t&&this.listenTo(t,"afterExecute",((t,n)=>{const i=e.model.document.selection.getFirstPosition().parent;o.some((e=>i.is("element",e.model)))&&!i.is("element",nv)&&0===i.childCount&&n.writer.rename(i,nv)}))}_addDefaultH1Conversion(e){e.conversion.for("upcast").elementToElement({model:"heading1",view:"h1",converterPriority:C.low+1})}}var rv=i(6186),sv={attributes:{"data-cke":!0}};sv.setAttributes=Ar(),sv.insert=_r().bind(null,"head"),sv.domAPI=kr(),sv.insertStyleElement=vr();fr()(rv.A,sv);rv.A&&rv.A.locals&&rv.A.locals;class av extends lr{static get pluginName(){return"HeadingUI"}init(){const e=this.editor,t=e.t,o=function(e){const t=e.t,o={Paragraph:t("Paragraph"),"Heading 1":t("Heading 1"),"Heading 2":t("Heading 2"),"Heading 3":t("Heading 3"),"Heading 4":t("Heading 4"),"Heading 5":t("Heading 5"),"Heading 6":t("Heading 6")};return e.config.get("heading.options").map((e=>{const t=o[e.title];return t&&t!=e.title&&(e.title=t),e}))}(e),n=t("Choose heading"),i=t("Heading");e.ui.componentFactory.add("heading",(t=>{const r={},s=new Yi,a=e.commands.get("heading"),l=e.commands.get("paragraph"),c=[a];for(const e of o){const t={type:"button",model:new Db({label:e.title,class:e.class,role:"menuitemradio",withText:!0})};"paragraph"===e.model?(t.model.bind("isOn").to(l,"value"),t.model.set("commandName","paragraph"),c.push(l)):(t.model.bind("isOn").to(a,"value",(t=>t===e.model)),t.model.set({commandName:"heading",commandValue:e.model})),s.add(t),r[e.model]=e.title}const d=Eg(t);return Sg(d,s,{ariaLabel:i,role:"menu"}),d.buttonView.set({ariaLabel:i,ariaLabelledBy:void 0,isOn:!1,withText:!0,tooltip:i}),d.extendTemplate({attributes:{class:["ck-heading-dropdown"]}}),d.bind("isEnabled").toMany(c,"isEnabled",((...e)=>e.some((e=>e)))),d.buttonView.bind("label").to(a,"value",l,"value",((e,t)=>{const o=t?"paragraph":e;return"boolean"==typeof o?n:r[o]?r[o]:n})),d.buttonView.bind("ariaLabel").to(a,"value",l,"value",((e,t)=>{const o=t?"paragraph":e;return"boolean"==typeof o?i:r[o]?`${r[o]}, ${i}`:i})),this.listenTo(d,"execute",(t=>{const{commandName:o,commandValue:n}=t.source;e.execute(o,n?{value:n}:void 0),e.editing.view.focus()})),d})),e.ui.componentFactory.add("menuBar:heading",(n=>{const i=new mk(n),r=e.commands.get("heading"),s=e.commands.get("paragraph"),a=[r],l=new pk(n);i.set({class:"ck-heading-dropdown"}),l.set({ariaLabel:t("Heading"),role:"menu"}),i.buttonView.set({label:t("Heading")}),i.panelView.children.add(l);for(const t of o){const o=new nb(n,i),c=new ip(n);o.children.add(c),l.items.add(o),c.set({isToggleable:!0,label:t.title,role:"menuitemradio",class:t.class}),c.delegate("execute").to(i),c.on("execute",(()=>{const o="paragraph"===t.model?"paragraph":"heading";e.execute(o,{value:t.model}),e.editing.view.focus()})),"paragraph"===t.model?(c.bind("isOn").to(s,"value"),a.push(s)):c.bind("isOn").to(r,"value",(e=>e===t.model))}return i.bind("isEnabled").toMany(a,"isEnabled",((...e)=>e.some((e=>e)))),i}))}}new Set(["paragraph","heading1","heading2","heading3","heading4","heading5","heading6"]);class lv{constructor(){this._definitions=new Set}get length(){return this._definitions.size}add(e){Array.isArray(e)?e.forEach((e=>this._definitions.add(e))):this._definitions.add(e)}getDispatcher(){return e=>{e.on("attribute:linkHref",((e,t,o)=>{if(!o.consumable.test(t.item,"attribute:linkHref"))return;if(!t.item.is("selection")&&!o.schema.isInline(t.item))return;const n=o.writer,i=n.document.selection;for(const e of this._definitions){const r=n.createAttributeElement("a",e.attributes,{priority:5});e.classes&&n.addClass(e.classes,r);for(const t in e.styles)n.setStyle(t,e.styles[t],r);n.setCustomProperty("link",!0,r),e.callback(t.attributeNewValue)?t.item.is("selection")?n.wrap(i.getFirstRange(),r):n.wrap(o.mapper.toViewRange(t.range),r):n.unwrap(o.mapper.toViewRange(t.range),r)}}),{priority:"high"})}}getDispatcherForLinkedImage(){return e=>{e.on("attribute:linkHref:imageBlock",((e,t,{writer:o,mapper:n})=>{const i=n.toViewElement(t.item),r=Array.from(i.getChildren()).find((e=>e.is("element","a")));for(const e of this._definitions){const n=tr(e.attributes);if(e.callback(t.attributeNewValue)){for(const[e,t]of n)"class"===e?o.addClass(t,r):o.setAttribute(e,t,r);e.classes&&o.addClass(e.classes,r);for(const t in e.styles)o.setStyle(t,e.styles[t],r)}else{for(const[e,t]of n)"class"===e?o.removeClass(t,r):o.removeAttribute(e,r);e.classes&&o.removeClass(e.classes,r);for(const t in e.styles)o.removeStyle(t,r)}}}))}}}const cv=function(e,t,o){var n=e.length;return o=void 0===o?n:o,!t&&o>=n?e:ds(e,t,o)};var dv=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");const uv=function(e){return dv.test(e)};const hv=function(e){return e.split("")};var mv="\\ud800-\\udfff",pv="["+mv+"]",gv="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",fv="\\ud83c[\\udffb-\\udfff]",bv="[^"+mv+"]",kv="(?:\\ud83c[\\udde6-\\uddff]){2}",wv="[\\ud800-\\udbff][\\udc00-\\udfff]",_v="(?:"+gv+"|"+fv+")"+"?",yv="[\\ufe0e\\ufe0f]?",Av=yv+_v+("(?:\\u200d(?:"+[bv,kv,wv].join("|")+")"+yv+_v+")*"),Cv="(?:"+[bv+gv+"?",gv,kv,wv,pv].join("|")+")",vv=RegExp(fv+"(?="+fv+")|"+Cv+Av,"g");const xv=function(e){return e.match(vv)||[]};const Ev=function(e){return uv(e)?xv(e):hv(e)};const Dv=function(e){return function(t){t=rs(t);var o=uv(t)?Ev(t):void 0,n=o?o[0]:t.charAt(0),i=o?cv(o,1).join(""):t.slice(1);return n[e]()+i}}("toUpperCase"),Bv=/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205f\u3000]/g,Sv=/^[\S]+@((?![-_])(?:[-\w\u00a1-\uffff]{0,63}[^-_]\.))+(?:[a-z\u00a1-\uffff]{2,})$/i,Tv=/^((\w+:(\/{2,})?)|(\W))/i,Iv=["https?","ftps?","mailto"],Pv="Ctrl+K";function Fv(e,{writer:t}){const o=t.createAttributeElement("a",{href:e},{priority:5});return t.setCustomProperty("link",!0,o),o}function Mv(e,t=Iv){const o=String(e),n=t.join("|");return function(e,t){const o=e.replace(Bv,"");return!!o.match(t)}(o,new RegExp(`${"^(?:(?:):|[^a-z]|[a-z+.-]+(?:[^a-z+.:-]|$))".replace("",n)}`,"i"))?o:"#"}function Rv(e,t){return!!e&&t.checkAttribute(e.name,"linkHref")}function zv(e,t){const o=(n=e,Sv.test(n)?"mailto:":t);var n;const i=!!o&&!Vv(e);return e&&i?o+e:e}function Vv(e){return Tv.test(e)}function Ov(e){window.open(e,"_blank","noopener")}class Nv extends dr{constructor(){super(...arguments),this.manualDecorators=new Yi,this.automaticDecorators=new lv}restoreManualDecoratorStates(){for(const e of this.manualDecorators)e.value=this._getDecoratorStateFromModel(e.id)}refresh(){const e=this.editor.model,t=e.document.selection,o=t.getSelectedElement()||Qi(t.getSelectedBlocks());Rv(o,e.schema)?(this.value=o.getAttribute("linkHref"),this.isEnabled=e.schema.checkAttribute(o,"linkHref")):(this.value=t.getAttribute("linkHref"),this.isEnabled=e.schema.checkAttributeInSelection(t,"linkHref"));for(const e of this.manualDecorators)e.value=this._getDecoratorStateFromModel(e.id)}execute(e,t={}){const o=this.editor.model,n=o.document.selection,i=[],r=[];for(const e in t)t[e]?i.push(e):r.push(e);o.change((t=>{if(n.isCollapsed){const s=n.getFirstPosition();if(n.hasAttribute("linkHref")){const a=Lv(n);let l=Ew(s,"linkHref",n.getAttribute("linkHref"),o);n.getAttribute("linkHref")===a&&(l=this._updateLinkContent(o,t,l,e)),t.setAttribute("linkHref",e,l),i.forEach((e=>{t.setAttribute(e,!0,l)})),r.forEach((e=>{t.removeAttribute(e,l)})),t.setSelection(t.createPositionAfter(l.end.nodeBefore))}else if(""!==e){const r=tr(n.getAttributes());r.set("linkHref",e),i.forEach((e=>{r.set(e,!0)}));const{end:a}=o.insertContent(t.createText(e,r),s);t.setSelection(a)}["linkHref",...i,...r].forEach((e=>{t.removeSelectionAttribute(e)}))}else{const s=o.schema.getValidRanges(n.getRanges(),"linkHref"),a=[];for(const e of n.getSelectedBlocks())o.schema.checkAttribute(e,"linkHref")&&a.push(t.createRangeOn(e));const l=a.slice();for(const e of s)this._isRangeToUpdate(e,a)&&l.push(e);for(const s of l){let a=s;if(1===l.length){const i=Lv(n);n.getAttribute("linkHref")===i&&(a=this._updateLinkContent(o,t,s,e),t.setSelection(t.createSelection(a)))}t.setAttribute("linkHref",e,a),i.forEach((e=>{t.setAttribute(e,!0,a)})),r.forEach((e=>{t.removeAttribute(e,a)}))}}}))}_getDecoratorStateFromModel(e){const t=this.editor.model,o=t.document.selection,n=o.getSelectedElement();return Rv(n,t.schema)?n.getAttribute(e):o.getAttribute(e)}_isRangeToUpdate(e,t){for(const o of t)if(o.containsRange(e))return!1;return!0}_updateLinkContent(e,t,o,n){const i=t.createText(n,{linkHref:n});return e.insertContent(i,o)}}function Lv(e){if(e.isCollapsed){const t=e.getFirstPosition();return t.textNode&&t.textNode.data}{const t=Array.from(e.getFirstRange().getItems());if(t.length>1)return null;const o=t[0];return o.is("$text")||o.is("$textProxy")?o.data:null}}class Hv extends dr{refresh(){const e=this.editor.model,t=e.document.selection,o=t.getSelectedElement();Rv(o,e.schema)?this.isEnabled=e.schema.checkAttribute(o,"linkHref"):this.isEnabled=e.schema.checkAttributeInSelection(t,"linkHref")}execute(){const e=this.editor,t=this.editor.model,o=t.document.selection,n=e.commands.get("link");t.change((e=>{const i=o.isCollapsed?[Ew(o.getFirstPosition(),"linkHref",o.getAttribute("linkHref"),t)]:t.schema.getValidRanges(o.getRanges(),"linkHref");for(const t of i)if(e.removeAttribute("linkHref",t),n)for(const o of n.manualDecorators)e.removeAttribute(o.id,t)}))}}class jv extends(Y()){constructor({id:e,label:t,attributes:o,classes:n,styles:i,defaultValue:r}){super(),this.id=e,this.set("value",void 0),this.defaultValue=r,this.label=t,this.attributes=o,this.classes=n,this.styles=i}_createPattern(){return{attributes:this.attributes,classes:this.classes,styles:this.styles}}}var qv=i(7456),Uv={attributes:{"data-cke":!0}};Uv.setAttributes=Ar(),Uv.insert=_r().bind(null,"head"),Uv.domAPI=kr(),Uv.insertStyleElement=vr();fr()(qv.A,Uv);qv.A&&qv.A.locals&&qv.A.locals;const Wv="automatic",$v=/^(https?:)?\/\//;class Gv extends lr{static get pluginName(){return"LinkEditing"}static get requires(){return[kw,nw,j_]}constructor(e){super(e),e.config.define("link",{allowCreatingEmptyLinks:!1,addTargetToExternalLinks:!1})}init(){const e=this.editor,t=this.editor.config.get("link.allowedProtocols");e.model.schema.extend("$text",{allowAttributes:"linkHref"}),e.conversion.for("dataDowncast").attributeToElement({model:"linkHref",view:Fv}),e.conversion.for("editingDowncast").attributeToElement({model:"linkHref",view:(e,o)=>Fv(Mv(e,t),o)}),e.conversion.for("upcast").elementToAttribute({view:{name:"a",attributes:{href:!0}},model:{key:"linkHref",value:e=>e.getAttribute("href")}}),e.commands.add("link",new Nv(e)),e.commands.add("unlink",new Hv(e));const o=function(e,t){const o={"Open in a new tab":e("Open in a new tab"),Downloadable:e("Downloadable")};return t.forEach((e=>("label"in e&&o[e.label]&&(e.label=o[e.label]),e))),t}(e.t,function(e){const t=[];if(e)for(const[o,n]of Object.entries(e)){const e=Object.assign({},n,{id:`link${Dv(o)}`});t.push(e)}return t}(e.config.get("link.decorators")));this._enableAutomaticDecorators(o.filter((e=>e.mode===Wv))),this._enableManualDecorators(o.filter((e=>"manual"===e.mode)));e.plugins.get(kw).registerAttribute("linkHref"),Bw(e,"linkHref","a","ck-link_selected"),this._enableLinkOpen(),this._enableSelectionAttributesFixer(),this._enableClipboardIntegration()}_enableAutomaticDecorators(e){const t=this.editor,o=t.commands.get("link").automaticDecorators;t.config.get("link.addTargetToExternalLinks")&&o.add({id:"linkIsExternal",mode:Wv,callback:e=>!!e&&$v.test(e),attributes:{target:"_blank",rel:"noopener noreferrer"}}),o.add(e),o.length&&t.conversion.for("downcast").add(o.getDispatcher())}_enableManualDecorators(e){if(!e.length)return;const t=this.editor,o=t.commands.get("link").manualDecorators;e.forEach((e=>{t.model.schema.extend("$text",{allowAttributes:e.id});const n=new jv(e);o.add(n),t.conversion.for("downcast").attributeToElement({model:n.id,view:(e,{writer:t,schema:o},{item:i})=>{if((i.is("selection")||o.isInline(i))&&e){const e=t.createAttributeElement("a",n.attributes,{priority:5});n.classes&&t.addClass(n.classes,e);for(const o in n.styles)t.setStyle(o,n.styles[o],e);return t.setCustomProperty("link",!0,e),e}}}),t.conversion.for("upcast").elementToAttribute({view:{name:"a",...n._createPattern()},model:{key:n.id}})}))}_enableLinkOpen(){const e=this.editor,t=e.editing.view.document;this.listenTo(t,"click",((e,t)=>{if(!(r.isMac?t.domEvent.metaKey:t.domEvent.ctrlKey))return;let o=t.domTarget;if("a"!=o.tagName.toLowerCase()&&(o=o.closest("a")),!o)return;const n=o.getAttribute("href");n&&(e.stop(),t.preventDefault(),Ov(n))}),{context:"$capture"}),this.listenTo(t,"keydown",((t,o)=>{const n=e.commands.get("link").value;!!n&&o.keyCode===ki.enter&&o.altKey&&(t.stop(),Ov(n))}))}_enableSelectionAttributesFixer(){const e=this.editor.model,t=e.document.selection;this.listenTo(t,"change:attribute",((o,{attributeKeys:n})=>{n.includes("linkHref")&&!t.hasAttribute("linkHref")&&e.change((t=>{var o;!function(e,t){e.removeSelectionAttribute("linkHref");for(const o of t)e.removeSelectionAttribute(o)}(t,(o=e.schema,o.getDefinition("$text").allowAttributes.filter((e=>e.startsWith("link")))))}))}))}_enableClipboardIntegration(){const e=this.editor,t=e.model,o=this.editor.config.get("link.defaultProtocol");o&&this.listenTo(e.plugins.get("ClipboardPipeline"),"contentInsertion",((e,n)=>{t.change((e=>{const t=e.createRangeIn(n.content);for(const n of t.getItems())if(n.hasAttribute("linkHref")){const t=zv(n.getAttribute("linkHref"),o);e.setAttribute("linkHref",t,n)}}))}))}}var Kv=i(2350),Zv={attributes:{"data-cke":!0}};Zv.setAttributes=Ar(),Zv.insert=_r().bind(null,"head"),Zv.domAPI=kr(),Zv.insertStyleElement=vr();fr()(Kv.A,Zv);Kv.A&&Kv.A.locals&&Kv.A.locals;class Jv extends pm{constructor(e,t,o){super(e),this.focusTracker=new Xi,this.keystrokes=new er,this._focusables=new Uh;const n=e.t;this._validators=o,this.urlInputView=this._createUrlInput(),this.saveButtonView=this._createButton(n("Save"),qh.check,"ck-button-save"),this.saveButtonView.type="submit",this.cancelButtonView=this._createButton(n("Cancel"),qh.cancel,"ck-button-cancel","cancel"),this._manualDecoratorSwitches=this._createManualDecoratorSwitches(t),this.children=this._createFormChildren(t.manualDecorators),this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}});const i=["ck","ck-link-form","ck-responsive-form"];t.manualDecorators.length&&i.push("ck-link-form_layout-vertical","ck-vertical-form"),this.setTemplate({tag:"form",attributes:{class:i,tabindex:"-1"},children:this.children})}getDecoratorSwitchesState(){return Array.from(this._manualDecoratorSwitches).reduce(((e,t)=>(e[t.name]=t.isOn,e)),{})}render(){super.render(),bm({view:this});[this.urlInputView,...this._manualDecoratorSwitches,this.saveButtonView,this.cancelButtonView].forEach((e=>{this._focusables.add(e),this.focusTracker.add(e.element)})),this.keystrokes.listenTo(this.element)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this._focusCycler.focusFirst()}isValid(){this.resetFormStatus();for(const e of this._validators){const t=e(this);if(t)return this.urlInputView.errorText=t,!1}return!0}resetFormStatus(){this.urlInputView.errorText=null}_createUrlInput(){const e=this.locale.t,t=new jp(this.locale,Fg);return t.fieldView.inputMode="url",t.label=e("Link URL"),t}_createButton(e,t,o,n){const i=new Em(this.locale);return i.set({label:e,icon:t,tooltip:!0}),i.extendTemplate({attributes:{class:o}}),n&&i.delegate("execute").to(this,n),i}_createManualDecoratorSwitches(e){const t=this.createCollection();for(const o of e.manualDecorators){const n=new bp(this.locale);n.set({name:o.id,label:o.label,withText:!0}),n.bind("isOn").toMany([o,e],"value",((e,t)=>void 0===t&&void 0===e?!!o.defaultValue:!!e)),n.on("execute",(()=>{o.set("value",!n.isOn)})),t.add(n)}return t}_createFormChildren(e){const t=this.createCollection();if(t.add(this.urlInputView),e.length){const e=new pm;e.setTemplate({tag:"ul",children:this._manualDecoratorSwitches.map((e=>({tag:"li",children:[e],attributes:{class:["ck","ck-list__item"]}}))),attributes:{class:["ck","ck-reset","ck-list"]}}),t.add(e)}return t.add(this.saveButtonView),t.add(this.cancelButtonView),t}get url(){const{element:e}=this.urlInputView.fieldView;return e?e.value.trim():null}}var Yv=i(8040),Qv={attributes:{"data-cke":!0}};Qv.setAttributes=Ar(),Qv.insert=_r().bind(null,"head"),Qv.domAPI=kr(),Qv.insertStyleElement=vr();fr()(Yv.A,Qv);Yv.A&&Yv.A.locals&&Yv.A.locals;class Xv extends pm{constructor(e,t={}){super(e),this.focusTracker=new Xi,this.keystrokes=new er,this._focusables=new Uh;const o=e.t;this.previewButtonView=this._createPreviewButton(),this.unlinkButtonView=this._createButton(o("Unlink"),'',"unlink"),this.editButtonView=this._createButton(o("Edit link"),qh.pencil,"edit"),this.set("href",void 0),this._linkConfig=t,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-link-actions","ck-responsive-form"],tabindex:"-1"},children:[this.previewButtonView,this.editButtonView,this.unlinkButtonView]})}render(){super.render();[this.previewButtonView,this.editButtonView,this.unlinkButtonView].forEach((e=>{this._focusables.add(e),this.focusTracker.add(e.element)})),this.keystrokes.listenTo(this.element)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this._focusCycler.focusFirst()}_createButton(e,t,o){const n=new Em(this.locale);return n.set({label:e,icon:t,tooltip:!0}),n.delegate("execute").to(this,o),n}_createPreviewButton(){const e=new Em(this.locale),t=this.bindTemplate,o=this.t;return e.set({withText:!0,tooltip:o("Open link in new tab")}),e.extendTemplate({attributes:{class:["ck","ck-link-actions__preview"],href:t.to("href",(e=>e&&Mv(e,this._linkConfig.allowedProtocols))),target:"_blank",rel:"noopener noreferrer"}}),e.bind("label").to(this,"href",(e=>e||o("This link has no URL"))),e.bind("isEnabled").to(this,"href",(e=>!!e)),e.template.tag="a",e.template.eventListeners={},e}}const ex="link-ui";class tx extends lr{constructor(){super(...arguments),this.actionsView=null,this.formView=null}static get requires(){return[Fb]}static get pluginName(){return"LinkUI"}init(){const e=this.editor,t=this.editor.t;e.editing.view.addObserver(Ou),this._balloon=e.plugins.get(Fb),this._createToolbarLinkButton(),this._enableBalloonActivators(),e.conversion.for("editingDowncast").markerToHighlight({model:ex,view:{classes:["ck-fake-link-selection"]}}),e.conversion.for("editingDowncast").markerToElement({model:ex,view:(e,{writer:t})=>{if(!e.markerRange.isCollapsed)return null;const o=t.createUIElement("span");return t.addClass(["ck-fake-link-selection","ck-fake-link-selection_collapsed"],o),o}}),e.accessibility.addKeystrokeInfos({keystrokes:[{label:t("Create link"),keystroke:Pv},{label:t("Move out of a link"),keystroke:[["arrowleft","arrowleft"],["arrowright","arrowright"]]}]})}destroy(){super.destroy(),this.formView&&this.formView.destroy(),this.actionsView&&this.actionsView.destroy()}_createViews(){this.actionsView=this._createActionsView(),this.formView=this._createFormView(),this._enableUserBalloonInteractions()}_createActionsView(){const e=this.editor,t=new Xv(e.locale,e.config.get("link")),o=e.commands.get("link"),n=e.commands.get("unlink");return t.bind("href").to(o,"value"),t.editButtonView.bind("isEnabled").to(o),t.unlinkButtonView.bind("isEnabled").to(n),this.listenTo(t,"edit",(()=>{this._addFormView()})),this.listenTo(t,"unlink",(()=>{e.execute("unlink"),this._hideUI()})),t.keystrokes.set("Esc",((e,t)=>{this._hideUI(),t()})),t.keystrokes.set(Pv,((e,t)=>{this._addFormView(),t()})),t}_createFormView(){const e=this.editor,t=e.commands.get("link"),o=e.config.get("link.defaultProtocol"),n=new(fm(Jv))(e.locale,t,function(e){const t=e.t,o=e.config.get("link.allowCreatingEmptyLinks");return[e=>{if(!o&&!e.url.length)return t("Link URL must not be empty.")}]}(e));return n.urlInputView.fieldView.bind("value").to(t,"value"),n.urlInputView.bind("isEnabled").to(t,"isEnabled"),n.saveButtonView.bind("isEnabled").to(t,"isEnabled"),this.listenTo(n,"submit",(()=>{if(n.isValid()){const{value:t}=n.urlInputView.fieldView.element,i=zv(t,o);e.execute("link",i,n.getDecoratorSwitchesState()),this._closeFormView()}})),this.listenTo(n.urlInputView,"change:errorText",(()=>{e.ui.update()})),this.listenTo(n,"cancel",(()=>{this._closeFormView()})),n.keystrokes.set("Esc",((e,t)=>{this._closeFormView(),t()})),n}_createToolbarLinkButton(){const e=this.editor;e.ui.componentFactory.add("link",(()=>{const e=this._createButton(Em);return e.set({tooltip:!0}),e})),e.ui.componentFactory.add("menuBar:link",(()=>{const e=this._createButton(ip);return e.set({role:"menuitemcheckbox"}),e}))}_createButton(e){const t=this.editor,o=t.locale,n=t.commands.get("link"),i=new e(t.locale),r=o.t;return i.set({label:r("Link"),icon:'',keystroke:Pv,isToggleable:!0}),i.bind("isEnabled").to(n,"isEnabled"),i.bind("isOn").to(n,"value",(e=>!!e)),this.listenTo(i,"execute",(()=>this._showUI(!0))),i}_enableBalloonActivators(){const e=this.editor,t=e.editing.view.document;this.listenTo(t,"click",(()=>{this._getSelectedLinkElement()&&this._showUI()})),e.keystrokes.set(Pv,((t,o)=>{o(),e.commands.get("link").isEnabled&&this._showUI(!0)}))}_enableUserBalloonInteractions(){this.editor.keystrokes.set("Tab",((e,t)=>{this._areActionsVisible&&!this.actionsView.focusTracker.isFocused&&(this.actionsView.focus(),t())}),{priority:"high"}),this.editor.keystrokes.set("Esc",((e,t)=>{this._isUIVisible&&(this._hideUI(),t())})),gm({emitter:this.formView,activator:()=>this._isUIInPanel,contextElements:()=>[this._balloon.view.element],callback:()=>this._hideUI()})}_addActionsView(){this.actionsView||this._createViews(),this._areActionsInPanel||this._balloon.add({view:this.actionsView,position:this._getBalloonPositionData()})}_addFormView(){if(this.formView||this._createViews(),this._isFormInPanel)return;const e=this.editor.commands.get("link");this.formView.disableCssTransitions(),this.formView.resetFormStatus(),this._balloon.add({view:this.formView,position:this._getBalloonPositionData()}),this.formView.urlInputView.fieldView.value=e.value||"",this._balloon.visibleView===this.formView&&this.formView.urlInputView.fieldView.select(),this.formView.enableCssTransitions()}_closeFormView(){const e=this.editor.commands.get("link");e.restoreManualDecoratorStates(),void 0!==e.value?this._removeFormView():this._hideUI()}_removeFormView(){this._isFormInPanel&&(this.formView.saveButtonView.focus(),this.formView.urlInputView.fieldView.reset(),this._balloon.remove(this.formView),this.editor.editing.view.focus(),this._hideFakeVisualSelection())}_showUI(e=!1){this.formView||this._createViews(),this._getSelectedLinkElement()?(this._areActionsVisible?this._addFormView():this._addActionsView(),e&&this._balloon.showStack("main")):(this._showFakeVisualSelection(),this._addActionsView(),e&&this._balloon.showStack("main"),this._addFormView()),this._startUpdatingUI()}_hideUI(){if(!this._isUIInPanel)return;const e=this.editor;this.stopListening(e.ui,"update"),this.stopListening(this._balloon,"change:visibleView"),e.editing.view.focus(),this._removeFormView(),this._balloon.remove(this.actionsView),this._hideFakeVisualSelection()}_startUpdatingUI(){const e=this.editor,t=e.editing.view.document;let o=this._getSelectedLinkElement(),n=r();const i=()=>{const e=this._getSelectedLinkElement(),t=r();o&&!e||!o&&t!==n?this._hideUI():this._isUIVisible&&this._balloon.updatePosition(this._getBalloonPositionData()),o=e,n=t};function r(){return t.selection.focus.getAncestors().reverse().find((e=>e.is("element")))}this.listenTo(e.ui,"update",i),this.listenTo(this._balloon,"change:visibleView",i)}get _isFormInPanel(){return!!this.formView&&this._balloon.hasView(this.formView)}get _areActionsInPanel(){return!!this.actionsView&&this._balloon.hasView(this.actionsView)}get _areActionsVisible(){return!!this.actionsView&&this._balloon.visibleView===this.actionsView}get _isUIInPanel(){return this._isFormInPanel||this._areActionsInPanel}get _isUIVisible(){const e=this._balloon.visibleView;return!!this.formView&&e==this.formView||this._areActionsVisible}_getBalloonPositionData(){const e=this.editor.editing.view,t=this.editor.model,o=e.document;let n;if(t.markers.has(ex)){const t=Array.from(this.editor.editing.mapper.markerNameToElements(ex)),o=e.createRange(e.createPositionBefore(t[0]),e.createPositionAfter(t[t.length-1]));n=e.domConverter.viewRangeToDom(o)}else n=()=>{const t=this._getSelectedLinkElement();return t?e.domConverter.mapViewToDom(t):e.domConverter.viewRangeToDom(o.selection.getFirstRange())};return{target:n}}_getSelectedLinkElement(){const e=this.editor.editing.view,t=e.document.selection,o=t.getSelectedElement();if(t.isCollapsed||o&&Rk(o))return ox(t.getFirstPosition());{const o=t.getFirstRange().getTrimmed(),n=ox(o.start),i=ox(o.end);return n&&n==i&&e.createRangeIn(n).getTrimmed().isEqual(o)?n:null}}_showFakeVisualSelection(){const e=this.editor.model;e.change((t=>{const o=e.document.selection.getFirstRange();if(e.markers.has(ex))t.updateMarker(ex,{range:o});else if(o.start.isAtEnd){const n=o.start.getLastMatchingPosition((({item:t})=>!e.schema.isContent(t)),{boundaries:o});t.addMarker(ex,{usingOperation:!1,affectsData:!1,range:t.createRange(n,o.end)})}else t.addMarker(ex,{usingOperation:!1,affectsData:!1,range:o})}))}_hideFakeVisualSelection(){const e=this.editor.model;e.markers.has(ex)&&e.change((e=>{e.removeMarker(ex)}))}}function ox(e){return e.getAncestors().find((e=>{return(t=e).is("attributeElement")&&!!t.getCustomProperty("link");var t}))||null}const nx=new RegExp("(^|\\s)(((?:(?:(?:https?|ftp):)?\\/\\/)(?:\\S+(?::\\S*)?@)?(?:(?:[1-9]\\d?|1\\d\\d|2[01]\\d|22[0-3])(?:\\.(?:1?\\d{1,2}|2[0-4]\\d|25[0-5])){2}(?:\\.(?:[1-9]\\d?|1\\d\\d|2[0-4]\\d|25[0-4]))|(((?!www\\.)|(www\\.))(?![-_])(?:[-_a-z0-9\\u00a1-\\uffff]{1,63}\\.)+(?:[a-z\\u00a1-\\uffff]{2,63})))(?::\\d{2,5})?(?:[/?#]\\S*)?)|((www.|(\\S+@))((?![-_])(?:[-_a-z0-9\\u00a1-\\uffff]{1,63}\\.))+(?:[a-z\\u00a1-\\uffff]{2,63})))$","i");class ix extends lr{static get requires(){return[pw,Gv]}static get pluginName(){return"AutoLink"}init(){const e=this.editor.model.document.selection;e.on("change:range",(()=>{this.isEnabled=!e.anchor.parent.is("element","codeBlock")})),this._enableTypingHandling()}afterInit(){this._enableEnterHandling(),this._enableShiftEnterHandling(),this._enablePasteLinking()}_expandLinkRange(e,t){return t.textNode&&t.textNode.hasAttribute("linkHref")?Ew(t,"linkHref",t.textNode.getAttribute("linkHref"),e):null}_selectEntireLinks(e,t){const o=this.editor.model,n=o.document.selection,i=n.getFirstPosition(),r=n.getLastPosition();let s=t.getJoined(this._expandLinkRange(o,i)||t);s&&(s=s.getJoined(this._expandLinkRange(o,r)||t)),s&&(s.start.isBefore(i)||s.end.isAfter(r))&&e.setSelection(s)}_enablePasteLinking(){const e=this.editor,t=e.model,o=t.document.selection,n=e.plugins.get("ClipboardPipeline"),i=e.commands.get("link");n.on("inputTransformation",((e,n)=>{if(!this.isEnabled||!i.isEnabled||o.isCollapsed||"paste"!==n.method)return;if(o.rangeCount>1)return;const r=o.getFirstRange(),s=n.dataTransfer.getData("text/plain");if(!s)return;const a=s.match(nx);a&&a[2]===s&&(t.change((e=>{this._selectEntireLinks(e,r),i.execute(s)})),e.stop())}),{priority:"high"})}_enableTypingHandling(){const e=this.editor,t=new bw(e.model,(e=>{if(!function(e){return e.length>4&&" "===e[e.length-1]&&" "!==e[e.length-2]}(e))return;const t=rx(e.substr(0,e.length-1));return t?{url:t}:void 0}));t.on("matched:data",((t,o)=>{const{batch:n,range:i,url:r}=o;if(!n.isTyping)return;const s=i.end.getShiftedBy(-1),a=s.getShiftedBy(-r.length),l=e.model.createRange(a,s);this._applyAutoLink(r,l)})),t.bind("isEnabled").to(this)}_enableEnterHandling(){const e=this.editor,t=e.model,o=e.commands.get("enter");o&&o.on("execute",(()=>{const e=t.document.selection.getFirstPosition();if(!e.parent.previousSibling)return;const o=t.createRangeIn(e.parent.previousSibling);this._checkAndApplyAutoLinkOnRange(o)}))}_enableShiftEnterHandling(){const e=this.editor,t=e.model,o=e.commands.get("shiftEnter");o&&o.on("execute",(()=>{const e=t.document.selection.getFirstPosition(),o=t.createRange(t.createPositionAt(e.parent,0),e.getShiftedBy(-1));this._checkAndApplyAutoLinkOnRange(o)}))}_checkAndApplyAutoLinkOnRange(e){const t=this.editor.model,{text:o,range:n}=fw(e,t),i=rx(o);if(i){const e=t.createRange(n.end.getShiftedBy(-i.length),n.end);this._applyAutoLink(i,e)}}_applyAutoLink(e,t){const o=this.editor.model,n=zv(e,this.editor.config.get("link.defaultProtocol"));this.isEnabled&&function(e,t){return t.schema.checkAttributeInSelection(t.createSelection(e),"linkHref")}(t,o)&&Vv(n)&&!function(e){const t=e.start.nodeAfter;return!!t&&t.hasAttribute("linkHref")}(t)&&this._persistAutoLink(n,t)}_persistAutoLink(e,t){const o=this.editor.model,n=this.editor.plugins.get("Delete");o.enqueueChange((i=>{i.setAttribute("linkHref",e,t),o.enqueueChange((()=>{n.requestUndoOnBackspace()}))}))}}function rx(e){const t=nx.exec(e);return t?t[2]:null}var sx=i(3669),ax={attributes:{"data-cke":!0}};ax.setAttributes=Ar(),ax.insert=_r().bind(null,"head"),ax.domAPI=kr(),ax.insertStyleElement=vr();fr()(sx.A,ax);sx.A&&sx.A.locals&&sx.A.locals;class lx{constructor(e,t){this._startElement=e,this._referenceIndent=e.getAttribute("listIndent"),this._isForward="forward"==t.direction,this._includeSelf=!!t.includeSelf,this._sameAttributes=xi(t.sameAttributes||[]),this._sameIndent=!!t.sameIndent,this._lowerIndent=!!t.lowerIndent,this._higherIndent=!!t.higherIndent}static first(e,t){return Qi(new this(e,t)[Symbol.iterator]())}*[Symbol.iterator](){const e=[];for(const{node:t}of cx(this._getStartNode(),this._isForward?"forward":"backward")){const o=t.getAttribute("listIndent");if(othis._referenceIndent){if(!this._higherIndent)continue;if(!this._isForward){e.push(t);continue}}else{if(!this._sameIndent){if(this._higherIndent){e.length&&(yield*e,e.length=0);break}continue}if(this._sameAttributes.some((e=>t.getAttribute(e)!==this._startElement.getAttribute(e))))break}e.length&&(yield*e,e.length=0),yield t}}_getStartNode(){return this._includeSelf?this._startElement:this._isForward?this._startElement.nextSibling:this._startElement.previousSibling}}function*cx(e,t="forward"){const o="forward"==t,n=[];let i=null;for(;hx(e);){let t=null;if(i){const o=e.getAttribute("listIndent"),r=i.getAttribute("listIndent");o>r?n[r]=i:oe.getAttribute("listItemId")!=t))}function xx(e){return Array.from(e).filter((e=>"$graveyard"!==e.root.rootName)).sort(((e,t)=>e.index-t.index))}function Ex(e){const t=e.document.selection.getSelectedElement();return t&&e.schema.isObject(t)&&e.schema.isBlock(t)?t:null}function Dx(e,t){return t.checkChild(e.parent,"listItem")&&t.checkChild(e,"$text")&&!t.isObject(e)}function Bx(e){return"numbered"==e||"customNumbered"==e}function Sx(e,t,o){return px(t,{direction:"forward"}).pop().index>e.index?yx(e,t,o):[]}class Tx extends dr{constructor(e,t){super(e),this._direction=t}refresh(){this.isEnabled=this._checkEnabled()}execute(){const e=this.editor.model,t=Ix(e.document.selection);e.change((e=>{const o=[];vx(t)&&!fx(t[0])?("forward"==this._direction&&o.push(...Ax(t,e)),o.push(..._x(t[0],e))):"forward"==this._direction?o.push(...Ax(t,e,{expand:!0})):o.push(...function(e,t){const o=kx(e=xi(e)),n=new Set,i=Math.min(...o.map((e=>e.getAttribute("listIndent")))),r=new Map;for(const e of o)r.set(e,lx.first(e,{lowerIndent:!0}));for(const e of o){if(n.has(e))continue;n.add(e);const o=e.getAttribute("listIndent")-1;if(o<0)Cx(e,t);else{if(e.getAttribute("listIndent")==i){const o=Sx(e,r.get(e),t);for(const e of o)n.add(e);if(o.length)continue}t.setAttribute("listIndent",o,e)}}return xx(n)}(t,e));for(const t of o){if(!t.hasAttribute("listType"))continue;const o=lx.first(t,{sameIndent:!0});o&&e.setAttribute("listType",o.getAttribute("listType"),t)}this._fireAfterExecute(o)}))}_fireAfterExecute(e){this.fire("afterExecute",xx(new Set(e)))}_checkEnabled(){let e=Ix(this.editor.model.document.selection),t=e[0];if(!t)return!1;if("backward"==this._direction)return!0;if(vx(e)&&!fx(e[0]))return!0;e=kx(e),t=e[0];const o=lx.first(t,{sameIndent:!0});return!!o&&o.getAttribute("listType")==t.getAttribute("listType")}}function Ix(e){const t=Array.from(e.getSelectedBlocks()),o=t.findIndex((e=>!hx(e)));return-1!=o&&(t.length=o),t}class Px extends dr{constructor(e,t,o={}){super(e),this.type=t,this._listWalkerOptions=o.multiLevel?{higherIndent:!0,lowerIndent:!0,sameAttributes:[]}:void 0}refresh(){this.value=this._getValue(),this.isEnabled=this._checkEnabled()}execute(e={}){const t=this.editor.model,o=t.document,n=Ex(t),i=Array.from(o.selection.getSelectedBlocks()).filter((e=>t.schema.checkAttribute(e,"listType")||Dx(e,t.schema))),r=void 0!==e.forceValue?!e.forceValue:this.value;t.change((s=>{if(r){const e=i[i.length-1],t=px(e,{direction:"forward"}),o=[];t.length>1&&o.push(..._x(t[1],s)),o.push(...Cx(i,s)),o.push(...function(e,t){const o=[];let n=Number.POSITIVE_INFINITY;for(const{node:i}of cx(e.nextSibling,"forward")){const e=i.getAttribute("listIndent");if(0==e)break;e{const{firstElement:r,lastElement:s}=this._getMergeSubjectElements(o,e),a=r.getAttribute("listIndent")||0,l=s.getAttribute("listIndent"),c=s.getAttribute("listItemId");if(a!=l){const e=(d=s,Array.from(new lx(d,{direction:"forward",higherIndent:!0})));n.push(...Ax([s,...e],i,{indentBy:a-l,expand:a{const t=_x(this._getStartBlock(),e);this._fireAfterExecute(t)}))}_fireAfterExecute(e){this.fire("afterExecute",xx(new Set(e)))}_checkEnabled(){const e=this.editor.model.document.selection,t=this._getStartBlock();return e.isCollapsed&&hx(t)&&!fx(t)}_getStartBlock(){const e=this.editor.model.document.selection.getFirstPosition().parent;return"before"==this._direction?e:e.nextSibling}}class Rx extends lr{static get pluginName(){return"ListUtils"}expandListBlocksToCompleteList(e){return wx(e)}isFirstBlockOfListItem(e){return fx(e)}isListItemBlock(e){return hx(e)}expandListBlocksToCompleteItems(e,t={}){return kx(e,t)}isNumberedListType(e){return Bx(e)}}function zx(e){return e.is("element","ol")||e.is("element","ul")}function Vx(e){return e.is("element","li")}function Ox(e,t,o,n=Hx(o,t)){return e.createAttributeElement(Lx(o),null,{priority:2*t/100-100,id:n})}function Nx(e,t,o){return e.createAttributeElement("li",null,{priority:(2*t+1)/100-100,id:o})}function Lx(e){return"numbered"==e||"customNumbered"==e?"ol":"ul"}function Hx(e,t){return`list-${e}-${t}`}function jx(e,t){const o=e.nodeBefore;if(hx(o)){let e=o;for(const{node:o}of cx(e,"backward"))if(e=o,t.has(e))return;t.set(o,e)}else{const o=e.nodeAfter;hx(o)&&t.set(o,o)}}function qx(){return(e,t,o)=>{const{writer:n,schema:i}=o;if(!t.modelRange)return;const r=Array.from(t.modelRange.getItems({shallow:!0})).filter((e=>i.checkAttribute(e,"listItemId")));if(!r.length)return;const s=ux.next(),a=function(e){let t=0,o=e.parent;for(;o;){if(Vx(o))t++;else{const e=o.previousSibling;e&&Vx(e)&&t++}o=o.parent}return t}(t.viewItem);let l=t.viewItem.parent&&t.viewItem.parent.is("element","ol")?"numbered":"bulleted";const c=r[0].getAttribute("listType");c&&(l=c);const d={listItemId:s,listIndent:a,listType:l};for(const e of r)e.hasAttribute("listItemId")||n.setAttributes(d,e);r.length>1&&r[1].getAttribute("listItemId")!=d.listItemId&&o.keepEmptyElement(r[0])}}function Ux(e,t,o,{dataPipeline:n}={}){const i=function(e){return(t,o)=>{const n=[];for(const o of e)t.hasAttribute(o)&&n.push(`attribute:${o}`);return!!n.every((e=>!1!==o.test(t,e)))&&(n.forEach((e=>o.consume(t,e))),!0)}}(e);return(r,s,a)=>{const{writer:l,mapper:c,consumable:d}=a,u=s.item;if(!e.includes(s.attributeKey))return;if(!i(u,d))return;const h=function(e,t,o){const n=o.createRangeOn(e),i=t.toViewRange(n).getTrimmed();return i.end.nodeBefore}(u,c,o);$x(h,l,c),function(e,t){let o=e.parent;for(;o.is("attributeElement")&&["ul","ol","li"].includes(o.name);){const n=o.parent;t.unwrap(t.createRangeOn(e),o),o=n}}(h,l);const m=function(e,t,o,n,{dataPipeline:i}){let r=n.createRangeOn(t);if(!fx(e))return r;for(const s of o){if("itemMarker"!=s.scope)continue;const o=s.createElement(n,e,{dataPipeline:i});if(!o)continue;if(n.setCustomProperty("listItemMarker",!0,o),s.canInjectMarkerIntoElement&&s.canInjectMarkerIntoElement(e)?n.insert(n.createPositionAt(t,0),o):(n.insert(r.start,o),r=n.createRange(n.createPositionBefore(o),n.createPositionAfter(t))),!s.createWrapperElement||!s.canWrapElement)continue;const a=s.createWrapperElement(n,e,{dataPipeline:i});n.setCustomProperty("listItemWrapper",!0,a),s.canWrapElement(e)?r=n.wrap(r,a):(r=n.wrap(n.createRangeOn(o),a),r=n.createRange(r.start,n.createPositionAfter(t)))}return r}(u,h,t,l,{dataPipeline:n});!function(e,t,o,n){if(!e.hasAttribute("listIndent"))return;const i=e.getAttribute("listIndent");let r=e;for(let e=i;e>=0;e--){const i=Nx(n,e,r.getAttribute("listItemId")),s=Ox(n,e,r.getAttribute("listType"));for(const e of o)"list"!=e.scope&&"item"!=e.scope||!r.hasAttribute(e.attributeName)||e.setAttributeOnDowncast(n,r.getAttribute(e.attributeName),"list"==e.scope?s:i);if(t=n.wrap(t,i),t=n.wrap(t,s),0==e)break;if(r=lx.first(r,{lowerIndent:!0}),!r)break}}(u,m,t,l)}}function Wx(e,{dataPipeline:t}={}){return(o,{writer:n})=>{if(!Gx(o,e))return null;if(!t)return n.createContainerElement("span",{class:"ck-list-bogus-paragraph"});const i=n.createContainerElement("p");return n.setCustomProperty("dataPipeline:transparentRendering",!0,i),i}}function $x(e,t,o){for(;e.parent.is("attributeElement")&&e.parent.getCustomProperty("listItemWrapper");)t.unwrap(t.createRangeOn(e),e.parent);const n=[];i(t.createPositionBefore(e).getWalker({direction:"backward"})),i(t.createRangeIn(e).getWalker());for(const e of n)t.remove(e);function i(e){for(const{item:t}of e){if(t.is("element")&&o.toModelElement(t))break;t.is("element")&&t.getCustomProperty("listItemMarker")&&n.push(t)}}}function Gx(e,t,o=mx(e)){if(!hx(e))return!1;for(const o of e.getAttributeKeys())if(!o.startsWith("selection:")&&!t.includes(o))return!1;return o.length<2}var Kx=i(7875),Zx={attributes:{"data-cke":!0}};Zx.setAttributes=Ar(),Zx.insert=_r().bind(null,"head"),Zx.domAPI=kr(),Zx.insertStyleElement=vr();fr()(Kx.A,Zx);Kx.A&&Kx.A.locals&&Kx.A.locals;var Jx=i(532),Yx={attributes:{"data-cke":!0}};Yx.setAttributes=Ar(),Yx.insert=_r().bind(null,"head"),Yx.domAPI=kr(),Yx.insertStyleElement=vr();fr()(Jx.A,Yx);Jx.A&&Jx.A.locals&&Jx.A.locals;const Qx=["listType","listIndent","listItemId"];class Xx extends lr{static get pluginName(){return"ListEditing"}static get requires(){return[Mw,pw,Rx,j_]}constructor(e){super(e),this._downcastStrategies=[],e.config.define("list.multiBlock",!0)}init(){const e=this.editor,t=e.model,o=e.config.get("list.multiBlock");if(e.plugins.has("LegacyListEditing"))throw new E("list-feature-conflict",this,{conflictPlugin:"LegacyListEditing"});t.schema.register("$listItem",{allowAttributes:Qx}),o?(t.schema.extend("$container",{allowAttributesOf:"$listItem"}),t.schema.extend("$block",{allowAttributesOf:"$listItem"}),t.schema.extend("$blockObject",{allowAttributesOf:"$listItem"})):t.schema.register("listItem",{inheritAllFrom:"$block",allowAttributesOf:"$listItem"});for(const e of Qx)t.schema.setAttributeProperties(e,{copyOnReplace:!0});e.commands.add("numberedList",new Px(e,"numbered")),e.commands.add("bulletedList",new Px(e,"bulleted")),e.commands.add("customNumberedList",new Px(e,"customNumbered",{multiLevel:!0})),e.commands.add("customBulletedList",new Px(e,"customBulleted",{multiLevel:!0})),e.commands.add("indentList",new Tx(e,"forward")),e.commands.add("outdentList",new Tx(e,"backward")),e.commands.add("splitListItemBefore",new Mx(e,"before")),e.commands.add("splitListItemAfter",new Mx(e,"after")),o&&(e.commands.add("mergeListItemBackward",new Fx(e,"backward")),e.commands.add("mergeListItemForward",new Fx(e,"forward"))),this._setupDeleteIntegration(),this._setupEnterIntegration(),this._setupTabIntegration(),this._setupClipboardIntegration(),this._setupAccessibilityIntegration()}afterInit(){const e=this.editor.commands,t=e.get("indent"),o=e.get("outdent");t&&t.registerChildCommand(e.get("indentList"),{priority:"high"}),o&&o.registerChildCommand(e.get("outdentList"),{priority:"lowest"}),this._setupModelPostFixing(),this._setupConversion()}registerDowncastStrategy(e){this._downcastStrategies.push(e)}getListAttributeNames(){return[...Qx,...this._downcastStrategies.map((e=>e.attributeName))]}_setupDeleteIntegration(){const e=this.editor,t=e.commands.get("mergeListItemBackward"),o=e.commands.get("mergeListItemForward");this.listenTo(e.editing.view.document,"delete",((n,i)=>{const r=e.model.document.selection;Ex(e.model)||e.model.change((()=>{const s=r.getFirstPosition();if(r.isCollapsed&&"backward"==i.direction){if(!s.isAtStart)return;const o=s.parent;if(!hx(o))return;if(lx.first(o,{sameAttributes:"listType",sameIndent:!0})||0!==o.getAttribute("listIndent")){if(!t||!t.isEnabled)return;t.execute({shouldMergeOnBlocksContentLevel:eE(e.model,"backward")})}else bx(o)||e.execute("splitListItemAfter"),e.execute("outdentList");i.preventDefault(),n.stop()}else{if(r.isCollapsed&&!r.getLastPosition().isAtEnd)return;if(!o||!o.isEnabled)return;o.execute({shouldMergeOnBlocksContentLevel:eE(e.model,"forward")}),i.preventDefault(),n.stop()}}))}),{context:"li"})}_setupEnterIntegration(){const e=this.editor,t=e.model,o=e.commands,n=o.get("enter");this.listenTo(e.editing.view.document,"enter",((o,n)=>{const i=t.document,r=i.selection.getFirstPosition().parent;if(i.selection.isCollapsed&&hx(r)&&r.isEmpty&&!n.isSoft){const t=fx(r),i=bx(r);t&&i?(e.execute("outdentList"),n.preventDefault(),o.stop()):t&&!i?(e.execute("splitListItemAfter"),n.preventDefault(),o.stop()):i&&(e.execute("splitListItemBefore"),n.preventDefault(),o.stop())}}),{context:"li"}),this.listenTo(n,"afterExecute",(()=>{const t=o.get("splitListItemBefore");if(t.refresh(),!t.isEnabled)return;2===mx(e.model.document.selection.getLastPosition().parent).length&&t.execute()}))}_setupTabIntegration(){const e=this.editor;this.listenTo(e.editing.view.document,"tab",((t,o)=>{const n=o.shiftKey?"outdentList":"indentList";this.editor.commands.get(n).isEnabled&&(e.execute(n),o.stopPropagation(),o.preventDefault(),t.stop())}),{context:"li"})}_setupConversion(){const e=this.editor,t=e.model,o=this.getListAttributeNames(),n=e.config.get("list.multiBlock"),i=n?"paragraph":"listItem";e.conversion.for("upcast").elementToElement({view:"li",model:(e,{writer:t})=>t.createElement(i,{listType:""})}).elementToElement({view:"p",model:(e,{writer:t})=>e.parent&&e.parent.is("element","li")?t.createElement(i,{listType:""}):null,converterPriority:"high"}).add((e=>{e.on("element:li",qx())})),n||e.conversion.for("downcast").elementToElement({model:"listItem",view:"p"}),e.conversion.for("editingDowncast").elementToElement({model:i,view:Wx(o),converterPriority:"high"}).add((e=>{var n;e.on("attribute",Ux(o,this._downcastStrategies,t)),e.on("remove",(n=t.schema,(e,t,o)=>{const{writer:i,mapper:r}=o,s=e.name.split(":")[1];if(!n.checkAttribute(s,"listItemId"))return;const a=r.toViewPosition(t.position),l=t.position.getShiftedBy(t.length),c=r.toViewPosition(l,{isPhantom:!0}),d=i.createRange(a,c).getTrimmed().end.nodeBefore;d&&$x(d,i,r)}))})),e.conversion.for("dataDowncast").elementToElement({model:i,view:Wx(o,{dataPipeline:!0}),converterPriority:"high"}).add((e=>{e.on("attribute",Ux(o,this._downcastStrategies,t,{dataPipeline:!0}))}));const r=(s=this._downcastStrategies,a=e.editing.view,(e,t)=>{if(t.modelPosition.offset>0)return;const o=t.modelPosition.parent;if(!hx(o))return;if(!s.some((e=>"itemMarker"==e.scope&&e.canInjectMarkerIntoElement&&e.canInjectMarkerIntoElement(o))))return;const n=t.mapper.toViewElement(o),i=a.createRangeIn(n),r=i.getWalker();let l=i.start;for(const{item:e}of r){if(e.is("element")&&t.mapper.toModelElement(e)||e.is("$textProxy"))break;e.is("element")&&e.getCustomProperty("listItemMarker")&&(l=a.createPositionAfter(e),r.skip((({previousPosition:e})=>!e.isEqual(l))))}t.viewPosition=l});var s,a;e.editing.mapper.on("modelToViewPosition",r),e.data.mapper.on("modelToViewPosition",r),this.listenTo(t.document,"change:data",function(e,t,o,n){return()=>{const n=e.document.differ.getChanges(),s=[],a=new Map,l=new Set;for(const e of n)if("insert"==e.type&&"$text"!=e.name)jx(e.position,a),e.attributes.has("listItemId")?l.add(e.position.nodeAfter):jx(e.position.getShiftedBy(e.length),a);else if("remove"==e.type&&e.attributes.has("listItemId"))jx(e.position,a);else if("attribute"==e.type){const t=e.range.start.nodeAfter;o.includes(e.attributeKey)?(jx(e.range.start,a),null===e.attributeNewValue?(jx(e.range.start.getShiftedBy(1),a),r(t)&&s.push(t)):l.add(t)):hx(t)&&r(t)&&s.push(t)}for(const e of a.values())s.push(...i(e,l));for(const e of new Set(s))t.reconvertItem(e)};function i(e,t){const n=[],i=new Set,a=[];for(const{node:l,previous:c}of cx(e,"forward")){if(i.has(l))continue;const e=l.getAttribute("listIndent");c&&eo.includes(e))));const d=px(l,{direction:"forward"});for(const e of d)i.add(e),(r(e,d)||s(e,a,t))&&n.push(e)}return n}function r(e,i){const r=t.mapper.toViewElement(e);if(!r)return!1;if(n.fire("checkElement",{modelElement:e,viewElement:r}))return!0;if(!e.is("element","paragraph")&&!e.is("element","listItem"))return!1;const s=Gx(e,o,i);return!(!s||!r.is("element","p"))||!(s||!r.is("element","span"))}function s(e,o,i){if(i.has(e))return!1;const r=t.mapper.toViewElement(e);let s=o.length-1;for(let e=r.parent;!e.is("editableElement");e=e.parent){const t=Vx(e),i=zx(e);if(!i&&!t)continue;const r="checkAttributes:"+(t?"item":"list");if(n.fire(r,{viewElement:e,modelAttributes:o[s]}))break;if(i&&(s--,s<0))return!1}return!0}}(t,e.editing,o,this),{priority:"high"}),this.on("checkAttributes:item",((e,{viewElement:t,modelAttributes:o})=>{t.id!=o.listItemId&&(e.return=!0,e.stop())})),this.on("checkAttributes:list",((e,{viewElement:t,modelAttributes:o})=>{t.name==Lx(o.listType)&&t.id==Hx(o.listType,o.listIndent)||(e.return=!0,e.stop())}))}_setupModelPostFixing(){const e=this.editor.model,t=this.getListAttributeNames();e.document.registerPostFixer((o=>function(e,t,o,n){const i=e.document.differ.getChanges(),r=new Map,s=n.editor.config.get("list.multiBlock");let a=!1;for(const n of i){if("insert"==n.type&&"$text"!=n.name){const i=n.position.nodeAfter;if(!e.schema.checkAttribute(i,"listItemId"))for(const e of Array.from(i.getAttributeKeys()))o.includes(e)&&(t.removeAttribute(e,i),a=!0);jx(n.position,r),n.attributes.has("listItemId")||jx(n.position.getShiftedBy(n.length),r);for(const{item:t,previousPosition:o}of e.createRangeIn(i))hx(t)&&jx(o,r)}else"remove"==n.type?jx(n.position,r):"attribute"==n.type&&o.includes(n.attributeKey)&&(jx(n.range.start,r),null===n.attributeNewValue&&jx(n.range.start.getShiftedBy(1),r));if(!s&&"attribute"==n.type&&Qx.includes(n.attributeKey)){const e=n.range.start.nodeAfter;null===n.attributeNewValue&&e&&e.is("element","listItem")?(t.rename(e,"paragraph"),a=!0):null===n.attributeOldValue&&e&&e.is("element")&&"listItem"!=e.name&&(t.rename(e,"listItem"),a=!0)}}const l=new Set;for(const e of r.values())a=n.fire("postFixer",{listNodes:new dx(e),listHead:e,writer:t,seenIds:l})||a;return a}(e,o,t,this))),this.on("postFixer",((e,{listNodes:t,writer:o})=>{e.return=function(e,t){let o=0,n=-1,i=null,r=!1;for(const{node:s}of e){const e=s.getAttribute("listIndent");if(e>o){let a;null===i?(i=e-o,a=o):(i>e&&(i=e),a=e-i),a>n+1&&(a=n+1),t.setAttribute("listIndent",a,s),r=!0,n=a}else i=null,o=e+1,n=e}return r}(t,o)||e.return}),{priority:"high"}),this.on("postFixer",((e,{listNodes:t,writer:o,seenIds:n})=>{e.return=function(e,t,o){const n=new Set;let i=!1;for(const{node:r}of e){if(n.has(r))continue;let e=r.getAttribute("listType"),s=r.getAttribute("listItemId");if(t.has(s)&&(s=ux.next()),t.add(s),r.is("element","listItem"))r.getAttribute("listItemId")!=s&&(o.setAttribute("listItemId",s,r),i=!0);else for(const t of px(r,{direction:"forward"}))n.add(t),t.getAttribute("listType")!=e&&(s=ux.next(),e=t.getAttribute("listType")),t.getAttribute("listItemId")!=s&&(o.setAttribute("listItemId",s,t),i=!0)}return i}(t,n,o)||e.return}),{priority:"high"})}_setupClipboardIntegration(){const e=this.editor.model,t=this.editor.plugins.get("ClipboardPipeline");this.listenTo(e,"insertContent",function(e){return(t,[o,n])=>{const i=o.is("documentFragment")?Array.from(o.getChildren()):[o];if(!i.length)return;const r=(n?e.createSelection(n):e.document.selection).getFirstPosition();let s;if(hx(r.parent))s=r.parent;else{if(!hx(r.nodeBefore))return;s=r.nodeBefore}e.change((e=>{const t=s.getAttribute("listType"),o=s.getAttribute("listIndent"),n=i[0].getAttribute("listIndent")||0,r=Math.max(o-n,0);for(const o of i){const n=hx(o);s.is("element","listItem")&&o.is("element","paragraph")&&e.rename(o,"listItem"),e.setAttributes({listIndent:(n?o.getAttribute("listIndent"):0)+r,listItemId:n?o.getAttribute("listItemId"):ux.next(),listType:t},o)}}))}}(e),{priority:"high"}),this.listenTo(t,"outputTransformation",((t,o)=>{e.change((e=>{const t=Array.from(o.content.getChildren()),n=t[t.length-1];if(t.length>1&&n.is("element")&&n.isEmpty){t.slice(0,-1).every(hx)&&e.remove(n)}if("copy"==o.method||"cut"==o.method){const t=Array.from(o.content.getChildren());vx(t)&&Cx(t,e)}}))}))}_setupAccessibilityIntegration(){const e=this.editor,t=e.t;e.accessibility.addKeystrokeInfoGroup({id:"list",label:t("Keystrokes that can be used in a list"),keystrokes:[{label:t("Increase list item indent"),keystroke:"Tab"},{label:t("Decrease list item indent"),keystroke:"Shift+Tab"}]})}}function eE(e,t){const o=e.document.selection;if(!o.isCollapsed)return!Ex(e);if("forward"===t)return!0;const n=o.getFirstPosition().parent,i=n.previousSibling;return!e.schema.isObject(i)&&(!!i.isEmpty||vx([n,i]))}function tE(e,t,o,n){e.ui.componentFactory.add(t,(()=>{const i=oE(Em,e,t,o,n);return i.set({tooltip:!0,isToggleable:!0}),i})),e.ui.componentFactory.add(`menuBar:${t}`,(()=>{const i=oE(ip,e,t,o,n);return i.set({role:"menuitemcheckbox",isToggleable:!0}),i}))}function oE(e,t,o,n,i){const r=t.commands.get(o),s=new e(t.locale);return s.set({label:n,icon:i}),s.bind("isOn","isEnabled").to(r,"value","isEnabled"),s.on("execute",(()=>{t.execute(o),t.editing.view.focus()})),s}class nE extends lr{static get pluginName(){return"ListUI"}init(){const e=this.editor.t;this.editor.ui.componentFactory.has("numberedList")||tE(this.editor,"numberedList",e("Numbered List"),qh.numberedList),this.editor.ui.componentFactory.has("bulletedList")||tE(this.editor,"bulletedList",e("Bulleted List"),qh.bulletedList)}}class iE extends lr{static get requires(){return[Xx,nE]}static get pluginName(){return"List"}}const rE={},sE={},aE={},lE=[{listStyle:"disc",typeAttribute:"disc",listType:"bulleted"},{listStyle:"circle",typeAttribute:"circle",listType:"bulleted"},{listStyle:"square",typeAttribute:"square",listType:"bulleted"},{listStyle:"decimal",typeAttribute:"1",listType:"numbered"},{listStyle:"decimal-leading-zero",typeAttribute:null,listType:"numbered"},{listStyle:"lower-roman",typeAttribute:"i",listType:"numbered"},{listStyle:"upper-roman",typeAttribute:"I",listType:"numbered"},{listStyle:"lower-alpha",typeAttribute:"a",listType:"numbered"},{listStyle:"upper-alpha",typeAttribute:"A",listType:"numbered"},{listStyle:"lower-latin",typeAttribute:"a",listType:"numbered"},{listStyle:"upper-latin",typeAttribute:"A",listType:"numbered"}];for(const{listStyle:e,typeAttribute:t,listType:o}of lE)rE[e]=o,sE[e]=t,t&&(aE[t]=e);var cE=i(1911),dE={attributes:{"data-cke":!0}};dE.setAttributes=Ar(),dE.insert=_r().bind(null,"head"),dE.domAPI=kr(),dE.insertStyleElement=vr();fr()(cE.A,dE);cE.A&&cE.A.locals&&cE.A.locals;var uE=i(1330),hE={attributes:{"data-cke":!0}};hE.setAttributes=Ar(),hE.insert=_r().bind(null,"head"),hE.domAPI=kr(),hE.insertStyleElement=vr();fr()(uE.A,hE);uE.A&&uE.A.locals&&uE.A.locals;class mE extends dr{constructor(e){super(e),this.on("execute",(()=>{this.refresh()}),{priority:"highest"})}refresh(){const e=this._getSelectedItems();this.value=this._getValue(e),this.isEnabled=!!e.length}execute(e={}){this.editor.model.change((t=>{const o=this._getSelectedItems(),n=void 0===e.forceValue?!this._getValue(o):e.forceValue;for(const e of o)n?t.setAttribute("todoListChecked",!0,e):t.removeAttribute("todoListChecked",e)}))}_getValue(e){return e.every((e=>e.getAttribute("todoListChecked")))}_getSelectedItems(){const e=this.editor.model,t=e.schema,o=e.document.selection.getFirstRange(),n=o.start.parent,i=[];t.checkAttribute(n,"todoListChecked")&&i.push(...mx(n));for(const e of o.getItems({shallow:!0}))t.checkAttribute(e,"todoListChecked")&&!i.includes(e)&&i.push(...mx(e));return i}}class pE extends La{constructor(){super(...arguments),this.domEventType=["change"]}onDomEvent(e){if(e.target){const t=this.view.domConverter.mapDomToView(e.target);t&&t.is("element","input")&&"checkbox"==t.getAttribute("type")&&t.findAncestor({classes:"todo-list__label"})&&this.fire("todoCheckboxChange",e)}}}const gE=yi("Ctrl+Enter");class fE extends lr{static get pluginName(){return"TodoListEditing"}static get requires(){return[Xx]}init(){const e=this.editor,t=e.model,o=e.editing,n=e.plugins.get(Xx),i=e.config.get("list.multiBlock")?"paragraph":"listItem";e.commands.add("todoList",new Px(e,"todo")),e.commands.add("checkTodoList",new mE(e)),o.view.addObserver(pE),t.schema.extend("$listItem",{allowAttributes:"todoListChecked"}),t.schema.addAttributeCheck((e=>{const t=e.last;if(!t.getAttribute("listItemId")||"todo"!=t.getAttribute("listType"))return!1}),"todoListChecked"),e.conversion.for("upcast").add((e=>{e.on("element:input",((e,t,o)=>{const n=t.modelCursor,i=n.parent,r=t.viewItem;if(!o.consumable.test(r,{name:!0}))return;if("checkbox"!=r.getAttribute("type")||!n.isAtStart||!i.hasAttribute("listType"))return;o.consumable.consume(r,{name:!0});const s=o.writer;s.setAttribute("listType","todo",i),t.viewItem.hasAttribute("checked")&&s.setAttribute("todoListChecked",!0,i),t.modelRange=s.createRange(n)})),e.on("element:label",bE({name:"label",classes:"todo-list__label"})),e.on("element:label",bE({name:"label",classes:["todo-list__label","todo-list__label_without-description"]})),e.on("element:span",bE({name:"span",classes:"todo-list__label__description"})),e.on("element:ul",function(e){const t=new Hr(e);return(e,o,n)=>{const i=t.match(o.viewItem);if(!i)return;const r=i.match;r.name=!1,n.consumable.consume(o.viewItem,r)}}({name:"ul",classes:"todo-list"}))})),e.conversion.for("downcast").elementToElement({model:i,view:(e,{writer:t})=>{if(kE(e,n.getListAttributeNames()))return t.createContainerElement("span",{class:"todo-list__label__description"})},converterPriority:"highest"}),n.registerDowncastStrategy({scope:"list",attributeName:"listType",setAttributeOnDowncast(e,t,o){"todo"==t?e.addClass("todo-list",o):e.removeClass("todo-list",o)}}),n.registerDowncastStrategy({scope:"itemMarker",attributeName:"todoListChecked",createElement(e,t,{dataPipeline:o}){if("todo"!=t.getAttribute("listType"))return null;const n=e.createUIElement("input",{type:"checkbox",...t.getAttribute("todoListChecked")?{checked:"checked"}:null,...o?{disabled:"disabled"}:{tabindex:"-1"}});if(o)return n;const i=e.createContainerElement("span",{contenteditable:"false"},n);return i.getFillerOffset=()=>null,i},canWrapElement:e=>kE(e,n.getListAttributeNames()),createWrapperElement(e,t,{dataPipeline:o}){const i=["todo-list__label"];return kE(t,n.getListAttributeNames())||i.push("todo-list__label_without-description"),e.createAttributeElement(o?"label":"span",{class:i.join(" ")})}}),n.on("checkElement",((e,{modelElement:t,viewElement:o})=>{const i=kE(t,n.getListAttributeNames());o.hasClass("todo-list__label__description")!=i&&(e.return=!0,e.stop())})),n.on("checkElement",((t,{modelElement:o,viewElement:n})=>{const i="todo"==o.getAttribute("listType")&&fx(o);let r=!1;const s=e.editing.view.createPositionBefore(n).getWalker({direction:"backward"});for(const{item:t}of s){if(t.is("element")&&e.editing.mapper.toModelElement(t))break;t.is("element","input")&&"checkbox"==t.getAttribute("type")&&(r=!0)}r!=i&&(t.return=!0,t.stop())})),n.on("postFixer",((e,{listNodes:t,writer:o})=>{for(const{node:n,previousNodeInList:i}of t){if(!i)continue;if(i.getAttribute("listItemId")!=n.getAttribute("listItemId"))continue;const t=i.hasAttribute("todoListChecked"),r=n.hasAttribute("todoListChecked");r&&!t?(o.removeAttribute("todoListChecked",n),e.return=!0):!r&&t&&(o.setAttribute("todoListChecked",!0,n),e.return=!0)}})),t.document.registerPostFixer((e=>{const o=t.document.differ.getChanges();let n=!1;for(const t of o)if("attribute"==t.type&&"listType"==t.attributeKey){const o=t.range.start.nodeAfter;"todo"==t.attributeOldValue&&o.hasAttribute("todoListChecked")&&(e.removeAttribute("todoListChecked",o),n=!0)}else if("insert"==t.type&&"$text"!=t.name)for(const{item:o}of e.createRangeOn(t.position.nodeAfter))o.is("element")&&"todo"!=o.getAttribute("listType")&&o.hasAttribute("todoListChecked")&&(e.removeAttribute("todoListChecked",o),n=!0);return n})),this.listenTo(o.view.document,"keydown",((t,o)=>{_i(o)===gE&&(e.execute("checkTodoList"),t.stop())}),{priority:"high"}),this.listenTo(o.view.document,"todoCheckboxChange",((e,t)=>{const n=t.target;if(!n||!n.is("element","input"))return;const i=o.view.createPositionAfter(n),r=o.mapper.toModelPosition(i).parent;r&&hx(r)&&"todo"==r.getAttribute("listType")&&this._handleCheckmarkChange(r)})),this.listenTo(o.view.document,"arrowKey",function(e,t){return(o,n)=>{const i=Ci(n.keyCode,t.contentLanguageDirection),r=e.schema,s=e.document.selection;if(!s.isCollapsed)return;const a=s.getFirstPosition(),l=a.parent;if("right"==i&&a.isAtEnd){const t=r.getNearestSelectionRange(e.createPositionAfter(l),"forward");if(!t)return;const i=t.start.parent;i&&hx(i)&&"todo"==i.getAttribute("listType")&&(e.change((e=>e.setSelection(t))),n.preventDefault(),n.stopPropagation(),o.stop())}else if("left"==i&&a.isAtStart&&hx(l)&&"todo"==l.getAttribute("listType")){const t=r.getNearestSelectionRange(e.createPositionBefore(l),"backward");if(!t)return;e.change((e=>e.setSelection(t))),n.preventDefault(),n.stopPropagation(),o.stop()}}}(t,e.locale),{context:"$text"}),this.listenTo(o.mapper,"viewToModelPosition",((e,o)=>{const n=o.viewPosition.parent,i=n.is("attributeElement","li")&&0==o.viewPosition.offset,r=wE(n)&&o.viewPosition.offset<=1,s=n.is("element","span")&&"false"==n.getAttribute("contenteditable")&&wE(n.parent);if(!i&&!r&&!s)return;const a=o.modelPosition.nodeAfter;a&&"todo"==a.getAttribute("listType")&&(o.modelPosition=t.createPositionAt(a,0))}),{priority:"low"}),this._initAriaAnnouncements()}_handleCheckmarkChange(e){const t=this.editor,o=t.model,n=Array.from(o.document.selection.getRanges());o.change((o=>{o.setSelection(e,"end"),t.execute("checkTodoList"),o.setSelection(n)}))}_initAriaAnnouncements(){const{model:e,ui:t,t:o}=this.editor;let n=null;t&&e.document.selection.on("change:range",(()=>{const i=e.document.selection.focus.parent,r=_E(n),s=_E(i);r&&!s?t.ariaLiveAnnouncer.announce(o("Leaving a to-do list")):!r&&s&&t.ariaLiveAnnouncer.announce(o("Entering a to-do list")),n=i}))}}function bE(e){const t=new Hr(e);return(e,o,n)=>{const i=t.match(o.viewItem);i&&n.consumable.consume(o.viewItem,i.match)&&Object.assign(o,n.convertChildren(o.viewItem,o.modelCursor))}}function kE(e,t){return(e.is("element","paragraph")||e.is("element","listItem"))&&"todo"==e.getAttribute("listType")&&fx(e)&&function(e,t){for(const o of e.getAttributeKeys())if(!o.startsWith("selection:")&&!t.includes(o))return!1;return!0}(e,t)}function wE(e){return!!e&&e.is("attributeElement")&&e.hasClass("todo-list__label")}function _E(e){return!!e&&(!(!e.is("element","paragraph")&&!e.is("element","listItem"))&&"todo"==e.getAttribute("listType"))}class yE extends lr{static get pluginName(){return"TodoListUI"}init(){const e=this.editor.t;tE(this.editor,"todoList",e("To-do List"),qh.todoList)}}var AE=i(5484),CE={attributes:{"data-cke":!0}};CE.setAttributes=Ar(),CE.insert=_r().bind(null,"head"),CE.domAPI=kr(),CE.insertStyleElement=vr();fr()(AE.A,CE);AE.A&&AE.A.locals&&AE.A.locals;class vE extends lr{static get requires(){return[fE,yE]}static get pluginName(){return"TodoList"}}const xE=Symbol("isOPCodeBlock");function EE(e){return!!e.getCustomProperty(xE)&&Rk(e)}function DE(e){const t=e.getSelectedElement();return!(!t||!EE(t))}function BE(e,t,o){const n=t.createContainerElement("pre",{title:window.I18n.t("js.editor.macro.toolbar_help")});return SE(t,e,n),function(e,t,o){return t.setCustomProperty(xE,!0,e),zk(e,t,{label:o})}(n,t,o)}function SE(e,t,o){const n=(t.getAttribute("opCodeblockLanguage")||"language-text").replace(/^language-/,""),i=e.createContainerElement("div",{class:"op-uc-code-block--language"});TE(e,n,i,"text"),e.insert(e.createPositionAt(o,0),i);TE(e,t.getAttribute("opCodeblockContent"),o,"(empty)")}function TE(e,t,o,n){const i=e.createText(t||n);e.insert(e.createPositionAt(o,0),i)}class IE extends La{constructor(e){super(e),this.domEventType="dblclick"}onDomEvent(e){this.fire(e.type,e)}}class PE extends lr{static get pluginName(){return"CodeBlockEditing"}init(){const e=this.editor,t=e.model.schema,o=e.conversion,n=e.editing.view,i=n.document,r=Gk(e);var s,a;t.register("codeblock",{isObject:!0,isBlock:!0,allowContentOf:"$block",allowWhere:["$root","$block"],allowIn:["$root"],allowAttributes:["opCodeblockLanguage","opCodeblockContent"]}),o.for("upcast").add(function(){return t=>{t.on("element:pre",e,{priority:"high"})};function e(e,t,o){if(!o.consumable.test(t.viewItem,{name:!0}))return;const n=Array.from(t.viewItem.getChildren()).find((e=>e.is("element","code")));if(!n||!o.consumable.consume(n,{name:!0}))return;const i=o.writer.createElement("codeblock");o.writer.setAttribute("opCodeblockLanguage",n.getAttribute("class"),i);const r=o.splitToAllowedParent(i,t.modelCursor);if(r){o.writer.insert(i,r.position);const e=n.getChild(0);o.consumable.consume(e,{name:!0});const s=e.data.replace(/\n$/,"");o.writer.setAttribute("opCodeblockContent",s,i),t.modelRange=new Zl(o.writer.createPositionBefore(i),o.writer.createPositionAfter(i)),t.modelCursor=t.modelRange.end}}}()),o.for("editingDowncast").elementToElement({model:"codeblock",view:(e,{writer:t})=>BE(e,t,"Code block")}).add(function(){return t=>{t.on("attribute:opCodeblockContent",e),t.on("attribute:opCodeblockLanguage",e)};function e(e,t,o){const n=t.item;o.consumable.consume(t.item,e.name);const i=o.mapper.toViewElement(n);o.writer.remove(o.writer.createRangeOn(i.getChild(1))),o.writer.remove(o.writer.createRangeOn(i.getChild(0))),SE(o.writer,n,i)}}()),o.for("dataDowncast").add(function(){return t=>{t.on("insert:codeblock",e,{priority:"high"})};function e(e,t,o){const n=t.item,i=n.getAttribute("opCodeblockLanguage")||"language-text",r=n.getAttribute("opCodeblockContent");o.consumable.consume(n,"insert");const s=o.writer,a=s.createContainerElement("pre"),l=s.createContainerElement("div",{class:"op-uc-code-block--language"}),c=s.createContainerElement("code",{class:i}),d=s.createText(i),u=s.createText(r);s.insert(s.createPositionAt(c,0),u),s.insert(s.createPositionAt(l,0),d),s.insert(s.createPositionAt(a,0),l),s.insert(s.createPositionAt(a,0),c),o.mapper.bindElements(n,c),o.mapper.bindElements(n,a),o.mapper.bindElements(n,l);const h=o.mapper.toViewPosition(t.range.start);s.insert(h,a),e.stop()}}()),this.editor.editing.mapper.on("viewToModelPosition",(s=this.editor.model,a=e=>e.hasClass("op-uc-code-block"),(e,t)=>{const{mapper:o,viewPosition:n}=t,i=o.findMappedViewAncestor(n);if(!a(i))return;const r=o.toModelElement(i);t.modelPosition=s.createPositionAt(r,n.isAtStart?"before":"after")})),n.addObserver(IE),this.listenTo(i,"dblclick",((t,o)=>{let n=o.target,i=o.domEvent;if(i.shiftKey||i.altKey||i.metaKey)return;if(!EE(n)&&(n=n.findAncestor(EE),!n))return;o.preventDefault(),o.stopPropagation();const s=e.editing.mapper.toModelElement(n),a=r.services.macros,l=s.getAttribute("opCodeblockLanguage"),c=s.getAttribute("opCodeblockContent");a.editCodeBlock(c,l).then((t=>e.model.change((e=>{e.setAttribute("opCodeblockLanguage",t.languageClass,s),e.setAttribute("opCodeblockContent",t.content,s)}))))})),e.ui.componentFactory.add("insertCodeBlock",(t=>{const o=new Em(t);return o.set({label:window.I18n.t("js.editor.macro.code_block.button"),icon:'\n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n image/svg+xml\n \n \n \n \n\n',tooltip:!0}),o.on("execute",(()=>{r.services.macros.editCodeBlock().then((t=>e.model.change((o=>{const n=o.createElement("codeblock");o.setAttribute("opCodeblockLanguage",t.languageClass,n),o.setAttribute("opCodeblockContent",t.content,n),e.model.insertContent(n,e.model.document.selection)}))))})),o}))}}class FE extends lr{static get requires(){return[Fb]}static get pluginName(){return"CodeBlockToolbar"}init(){const e=this.editor,t=this.editor.model,o=Gk(e);l_(e,"opEditCodeBlock",(e=>{const n=o.services.macros,i=e.getAttribute("opCodeblockLanguage"),r=e.getAttribute("opCodeblockContent");n.editCodeBlock(r,i).then((o=>t.change((t=>{t.setAttribute("opCodeblockLanguage",o.languageClass,e),t.setAttribute("opCodeblockContent",o.content,e)}))))}))}afterInit(){d_(this,this.editor,"OPCodeBlock",DE)}}function ME(e){return e.__currentlyDisabled=e.__currentlyDisabled||[],e.ui.view.toolbar?e.ui.view.toolbar.items._items:[]}function RE(e,t){jQuery.each(ME(e),(function(o,n){let i=n;n instanceof kp?i=n.buttonView:n!==t&&n.hasOwnProperty("isEnabled")||(i=null),i&&(i.isEnabled?i.isEnabled=!1:e.__currentlyDisabled.push(i))}))}function zE(e){jQuery.each(ME(e),(function(t,o){let n=o;o instanceof kp&&(n=o.buttonView),e.__currentlyDisabled.indexOf(n)<0&&(n.isEnabled=!0)})),e.__currentlyDisabled=[]}function VE(e,t){const{modelAttribute:o,styleName:n,viewElement:i,defaultValue:r,reduceBoxSides:s=!1,shouldUpcast:a=(()=>!0)}=t;e.for("upcast").attributeToAttribute({view:{name:i,styles:{[n]:/[\s\S]+/}},model:{key:o,value:e=>{if(!a(e))return;const t=e.getNormalizedStyle(n),o=s?HE(t):t;return r!==o?o:void 0}}})}function OE(e,t,o,n){e.for("upcast").add((e=>e.on("element:"+t,((e,t,i)=>{if(!t.modelRange)return;const r=["border-top-width","border-top-color","border-top-style","border-bottom-width","border-bottom-color","border-bottom-style","border-right-width","border-right-color","border-right-style","border-left-width","border-left-color","border-left-style"].filter((e=>t.viewItem.hasStyle(e)));if(!r.length)return;const s={styles:r};if(!i.consumable.test(t.viewItem,s))return;const a=[...t.modelRange.getItems({shallow:!0})].pop();i.consumable.consume(t.viewItem,s);const l={style:t.viewItem.getNormalizedStyle("border-style"),color:t.viewItem.getNormalizedStyle("border-color"),width:t.viewItem.getNormalizedStyle("border-width")},c={style:HE(l.style),color:HE(l.color),width:HE(l.width)};c.style!==n.style&&i.writer.setAttribute(o.style,c.style,a),c.color!==n.color&&i.writer.setAttribute(o.color,c.color,a),c.width!==n.width&&i.writer.setAttribute(o.width,c.width,a)}))))}function NE(e,t){const{modelElement:o,modelAttribute:n,styleName:i}=t;e.for("downcast").attributeToAttribute({model:{name:o,key:n},view:e=>({key:"style",value:{[i]:e}})})}function LE(e,t){const{modelAttribute:o,styleName:n}=t;e.for("downcast").add((e=>e.on(`attribute:${o}:table`,((e,t,o)=>{const{item:i,attributeNewValue:r}=t,{mapper:s,writer:a}=o;if(!o.consumable.consume(t.item,e.name))return;const l=[...s.toViewElement(i).getChildren()].find((e=>e.is("element","table")));r?a.setStyle(n,r,l):a.removeStyle(n,l)}))))}function HE(e){if(!e)return;const t=["top","right","bottom","left"];if(!t.every((t=>e[t])))return e;const o=e.top;return t.every((t=>e[t]===o))?o:e}function jE(e,t,o,n,i=1){null!=t&&null!=i&&t>i?n.setAttribute(e,t,o):n.removeAttribute(e,o)}function qE(e,t,o={}){const n=e.createElement("tableCell",o);return e.insertElement("paragraph",n),e.insert(n,t),n}function UE(e,t){const o=t.parent.parent,n=parseInt(o.getAttribute("headingColumns")||"0"),{column:i}=e.getCellLocation(t);return!!n&&i{e.on("element:table",((e,t,o)=>{const n=t.viewItem;if(!o.consumable.test(n,{name:!0}))return;const{rows:i,headingRows:r,headingColumns:s}=function(e){let t,o=0;const n=[],i=[];let r;for(const s of Array.from(e.getChildren())){if("tbody"!==s.name&&"thead"!==s.name&&"tfoot"!==s.name)continue;"thead"!==s.name||r||(r=s);const e=Array.from(s.getChildren()).filter((e=>e.is("element","tr")));for(const a of e)if(r&&s===r||"tbody"===s.name&&Array.from(a.getChildren()).length&&Array.from(a.getChildren()).every((e=>e.is("element","th"))))o++,n.push(a);else{i.push(a);const e=ZE(a);(!t||eo.convertItem(e,o.writer.createPositionAt(l,"end")))),o.convertChildren(n,o.writer.createPositionAt(l,"end")),l.isEmpty){const e=o.writer.createElement("tableRow");o.writer.insert(e,o.writer.createPositionAt(l,"end")),qE(o.writer,o.writer.createPositionAt(e,"end"))}o.updateConversionResult(l,t)}}))}}function KE(e){return t=>{t.on(`element:${e}`,((e,t,{writer:o})=>{if(!t.modelRange)return;const n=t.modelRange.start.nodeAfter,i=o.createPositionAt(n,0);if(t.viewItem.isEmpty)return void o.insertElement("paragraph",i);const r=Array.from(n.getChildren());if(r.every((e=>e.is("element","$marker")))){const e=o.createElement("paragraph");o.insert(e,o.createPositionAt(n,0));for(const t of r)o.move(o.createRangeOn(t),o.createPositionAt(e,"end"))}}),{priority:"low"})}}function ZE(e){let t=0,o=0;const n=Array.from(e.getChildren()).filter((e=>"th"===e.name||"td"===e.name));for(;o1||i>1)&&this._recordSpans(o,i,n),this._shouldSkipSlot()||(t=this._formatOutValue(o)),this._nextCellAtColumn=this._column+n}return this._column++,this._column==this._nextCellAtColumn&&this._cellIndex++,t||this.next()}skipRow(e){this._skipRows.add(e)}_advanceToNextRow(){return this._row++,this._rowIndex++,this._column=0,this._cellIndex=0,this._nextCellAtColumn=-1,this.next()}_isOverEndRow(){return void 0!==this._endRow&&this._row>this._endRow}_isOverEndColumn(){return void 0!==this._endColumn&&this._column>this._endColumn}_formatOutValue(e,t=this._row,o=this._column){return{done:!1,value:new YE(this,e,t,o)}}_shouldSkipSlot(){const e=this._skipRows.has(this._row),t=this._rowthis._endColumn;return e||t||o||n}_getSpanned(){const e=this._spannedCells.get(this._row);return e&&e.get(this._column)||null}_recordSpans(e,t,o){const n={cell:e,row:this._row,column:this._column};for(let e=this._row;e0&&!this._jumpedToStartRow}_jumpToNonSpannedRowClosestToStartRow(){const e=this._getRowLength(0);for(let t=this._startRow;!this._jumpedToStartRow;t--)e===this._getRowLength(t)&&(this._row=t,this._rowIndex=t,this._jumpedToStartRow=!0)}_getRowLength(e){return[...this._table.getChild(e).getChildren()].reduce(((e,t)=>e+parseInt(t.getAttribute("colspan")||"1")),0)}}class YE{constructor(e,t,o,n){this.cell=t,this.row=e._row,this.column=e._column,this.cellAnchorRow=o,this.cellAnchorColumn=n,this._cellIndex=e._cellIndex,this._rowIndex=e._rowIndex,this._table=e._table}get isAnchor(){return this.row===this.cellAnchorRow&&this.column===this.cellAnchorColumn}get cellWidth(){return parseInt(this.cell.getAttribute("colspan")||"1")}get cellHeight(){return parseInt(this.cell.getAttribute("rowspan")||"1")}get rowIndex(){return this._rowIndex}getPositionBefore(){return this._table.root.document.model.createPositionAt(this._table.getChild(this.row),this._cellIndex)}}function QE(e,t){return(o,{writer:n})=>{const i=o.getAttribute("headingRows")||0,r=n.createContainerElement("table",null,[]),s=n.createContainerElement("figure",{class:"table"},r);i>0&&n.insert(n.createPositionAt(r,"end"),n.createContainerElement("thead",null,n.createSlot((e=>e.is("element","tableRow")&&e.indexe.is("element","tableRow")&&e.index>=i))));for(const{positionOffset:e,filter:o}of t.additionalSlots)n.insert(n.createPositionAt(r,e),n.createSlot(o));return n.insert(n.createPositionAt(r,"after"),n.createSlot((e=>!e.is("element","tableRow")&&!t.additionalSlots.some((({filter:t})=>t(e)))))),t.asWidget?function(e,t){return t.setCustomProperty("table",!0,e),zk(e,t,{hasSelectionHandle:!0})}(s,n):s}}function XE(e={}){return(t,{writer:o})=>{const n=t.parent,i=n.parent,r=i.getChildIndex(n),s=new JE(i,{row:r}),a=i.getAttribute("headingRows")||0,l=i.getAttribute("headingColumns")||0;let c=null;for(const n of s)if(n.cell==t){const t=n.row{if(!t.parent.is("element","tableCell"))return null;if(!tD(t))return null;if(e.asWidget)return o.createContainerElement("span",{class:"ck-table-bogus-paragraph"});{const e=o.createContainerElement("p");return o.setCustomProperty("dataPipeline:transparentRendering",!0,e),e}}}function tD(e){return 1==e.parent.childCount&&!!e.getAttributeKeys().next().done}class oD extends dr{refresh(){const e=this.editor.model,t=e.document.selection,o=e.schema;this.isEnabled=function(e,t){const o=e.getFirstPosition().parent,n=o===o.root?o:o.parent;return t.checkChild(n,"table")}(t,o)}execute(e={}){const t=this.editor,o=t.model,n=t.plugins.get("TableUtils"),i=t.config.get("table.defaultHeadings.rows"),r=t.config.get("table.defaultHeadings.columns");void 0===e.headingRows&&i&&(e.headingRows=i),void 0===e.headingColumns&&r&&(e.headingColumns=r),o.change((t=>{const i=n.createTable(t,e);o.insertObject(i,null,null,{findOptimalPosition:"auto"}),t.setSelection(t.createPositionAt(i.getNodeByPath([0,0,0]),0))}))}}class nD extends dr{constructor(e,t={}){super(e),this.order=t.order||"below"}refresh(){const e=this.editor.model.document.selection,t=!!this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(e).length;this.isEnabled=t}execute(){const e=this.editor,t=e.model.document.selection,o=e.plugins.get("TableUtils"),n="above"===this.order,i=o.getSelectionAffectedTableCells(t),r=o.getRowIndexes(i),s=n?r.first:r.last,a=i[0].findAncestor("table");o.insertRows(a,{at:n?s:s+1,copyStructureFromAbove:!n})}}class iD extends dr{constructor(e,t={}){super(e),this.order=t.order||"right"}refresh(){const e=this.editor.model.document.selection,t=!!this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(e).length;this.isEnabled=t}execute(){const e=this.editor,t=e.model.document.selection,o=e.plugins.get("TableUtils"),n="left"===this.order,i=o.getSelectionAffectedTableCells(t),r=o.getColumnIndexes(i),s=n?r.first:r.last,a=i[0].findAncestor("table");o.insertColumns(a,{columns:1,at:n?s:s+1})}}class rD extends dr{constructor(e,t={}){super(e),this.direction=t.direction||"horizontally"}refresh(){const e=this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(this.editor.model.document.selection);this.isEnabled=1===e.length}execute(){const e=this.editor.plugins.get("TableUtils"),t=e.getSelectionAffectedTableCells(this.editor.model.document.selection)[0];"horizontally"===this.direction?e.splitCellHorizontally(t,2):e.splitCellVertically(t,2)}}function sD(e,t,o){const{startRow:n,startColumn:i,endRow:r,endColumn:s}=t,a=o.createElement("table"),l=r-n+1;for(let e=0;e0){jE("headingRows",r-o,e,i,0)}const s=parseInt(t.getAttribute("headingColumns")||"0");if(s>0){jE("headingColumns",s-n,e,i,0)}}(a,e,n,i,o),a}function aD(e,t,o=0){const n=[],i=new JE(e,{startRow:o,endRow:t-1});for(const e of i){const{row:o,cellHeight:i}=e;o1&&(a.rowspan=l);const c=parseInt(e.getAttribute("colspan")||"1");c>1&&(a.colspan=c);const d=r+s,u=[...new JE(i,{startRow:r,endRow:d,includeAllSlots:!0})];let h,m=null;for(const t of u){const{row:n,column:i,cell:r}=t;r===e&&void 0===h&&(h=i),void 0!==h&&h===i&&n===d&&(m=qE(o,t.getPositionBefore(),a))}return jE("rowspan",s,e,o),m}function cD(e,t){const o=[],n=new JE(e);for(const e of n){const{column:n,cellWidth:i}=e;n1&&(r.colspan=s);const a=parseInt(e.getAttribute("rowspan")||"1");a>1&&(r.rowspan=a);const l=qE(n,n.createPositionAfter(e),r);return jE("colspan",i,e,n),l}function uD(e,t,o,n,i,r){const s=parseInt(e.getAttribute("colspan")||"1"),a=parseInt(e.getAttribute("rowspan")||"1");if(o+s-1>i){jE("colspan",i-o+1,e,r,1)}if(t+a-1>n){jE("rowspan",n-t+1,e,r,1)}}function hD(e,t){const o=t.getColumns(e),n=new Array(o).fill(0);for(const{column:t}of new JE(e))n[t]++;const i=n.reduce(((e,t,o)=>t?e:[...e,o]),[]);if(i.length>0){const o=i[i.length-1];return t.removeColumns(e,{at:o}),!0}return!1}function mD(e,t){const o=[],n=t.getRows(e);for(let t=0;t0){const n=o[o.length-1];return t.removeRows(e,{at:n}),!0}return!1}function pD(e,t){hD(e,t)||mD(e,t)}function gD(e,t){const o=Array.from(new JE(e,{startColumn:t.firstColumn,endColumn:t.lastColumn,row:t.lastRow}));if(o.every((({cellHeight:e})=>1===e)))return t.lastRow;const n=o[0].cellHeight-1;return t.lastRow+n}function fD(e,t){const o=Array.from(new JE(e,{startRow:t.firstRow,endRow:t.lastRow,column:t.lastColumn}));if(o.every((({cellWidth:e})=>1===e)))return t.lastColumn;const n=o[0].cellWidth-1;return t.lastColumn+n}class bD extends dr{constructor(e,t){super(e),this.direction=t.direction,this.isHorizontal="right"==this.direction||"left"==this.direction}refresh(){const e=this._getMergeableCell();this.value=e,this.isEnabled=!!e}execute(){const e=this.editor.model,t=e.document,o=this.editor.plugins.get("TableUtils").getTableCellsContainingSelection(t.selection)[0],n=this.value,i=this.direction;e.change((e=>{const t="right"==i||"down"==i,r=t?o:n,s=t?n:o,a=s.parent;!function(e,t,o){kD(e)||(kD(t)&&o.remove(o.createRangeIn(t)),o.move(o.createRangeIn(e),o.createPositionAt(t,"end")));o.remove(e)}(s,r,e);const l=this.isHorizontal?"colspan":"rowspan",c=parseInt(o.getAttribute(l)||"1"),d=parseInt(n.getAttribute(l)||"1");e.setAttribute(l,c+d,r),e.setSelection(e.createRangeIn(r));const u=this.editor.plugins.get("TableUtils");pD(a.findAncestor("table"),u)}))}_getMergeableCell(){const e=this.editor.model.document,t=this.editor.plugins.get("TableUtils"),o=t.getTableCellsContainingSelection(e.selection)[0];if(!o)return;const n=this.isHorizontal?function(e,t,o){const n=e.parent,i=n.parent,r="right"==t?e.nextSibling:e.previousSibling,s=(i.getAttribute("headingColumns")||0)>0;if(!r)return;const a="right"==t?e:r,l="right"==t?r:e,{column:c}=o.getCellLocation(a),{column:d}=o.getCellLocation(l),u=parseInt(a.getAttribute("colspan")||"1"),h=UE(o,a),m=UE(o,l);if(s&&h!=m)return;return c+u===d?r:void 0}(o,this.direction,t):function(e,t,o){const n=e.parent,i=n.parent,r=i.getChildIndex(n);if("down"==t&&r===o.getRows(i)-1||"up"==t&&0===r)return null;const s=parseInt(e.getAttribute("rowspan")||"1"),a=i.getAttribute("headingRows")||0,l="down"==t&&r+s===a,c="up"==t&&r===a;if(a&&(l||c))return null;const d=parseInt(e.getAttribute("rowspan")||"1"),u="down"==t?r+d:r,h=[...new JE(i,{endRow:u})],m=h.find((t=>t.cell===e)),p=m.column,g=h.find((({row:e,cellHeight:o,column:n})=>n===p&&("down"==t?e===u:u===e+o)));return g&&g.cell?g.cell:null}(o,this.direction,t);if(!n)return;const i=this.isHorizontal?"rowspan":"colspan",r=parseInt(o.getAttribute(i)||"1");return parseInt(n.getAttribute(i)||"1")===r?n:void 0}}function kD(e){const t=e.getChild(0);return 1==e.childCount&&t.is("element","paragraph")&&t.isEmpty}class wD extends dr{refresh(){const e=this.editor.plugins.get("TableUtils"),t=e.getSelectionAffectedTableCells(this.editor.model.document.selection),o=t[0];if(o){const n=o.findAncestor("table"),i=e.getRows(n)-1,r=e.getRowIndexes(t),s=0===r.first&&r.last===i;this.isEnabled=!s}else this.isEnabled=!1}execute(){const e=this.editor.model,t=this.editor.plugins.get("TableUtils"),o=t.getSelectionAffectedTableCells(e.document.selection),n=t.getRowIndexes(o),i=o[0],r=i.findAncestor("table"),s=t.getCellLocation(i).column;e.change((e=>{const o=n.last-n.first+1;t.removeRows(r,{at:n.first,rows:o});const i=function(e,t,o,n){const i=e.getChild(Math.min(t,n-1));let r=i.getChild(0),s=0;for(const e of i.getChildren()){if(s>o)return r;r=e,s+=parseInt(e.getAttribute("colspan")||"1")}return r}(r,n.first,s,t.getRows(r));e.setSelection(e.createPositionAt(i,0))}))}}class _D extends dr{refresh(){const e=this.editor.plugins.get("TableUtils"),t=e.getSelectionAffectedTableCells(this.editor.model.document.selection),o=t[0];if(o){const n=o.findAncestor("table"),i=e.getColumns(n),{first:r,last:s}=e.getColumnIndexes(t);this.isEnabled=s-re.cell===t)).column,last:i.find((e=>e.cell===o)).column},s=function(e,t,o,n){const i=parseInt(o.getAttribute("colspan")||"1");return i>1?o:t.previousSibling||o.nextSibling?o.nextSibling||t.previousSibling:n.first?e.reverse().find((({column:e})=>ee>n.last)).cell}(i,t,o,r);this.editor.model.change((t=>{const o=r.last-r.first+1;e.removeColumns(n,{at:r.first,columns:o}),t.setSelection(t.createPositionAt(s,0))}))}}class yD extends dr{refresh(){const e=this.editor.plugins.get("TableUtils"),t=this.editor.model,o=e.getSelectionAffectedTableCells(t.document.selection),n=o.length>0;this.isEnabled=n,this.value=n&&o.every((e=>this._isInHeading(e,e.parent.parent)))}execute(e={}){if(e.forceValue===this.value)return;const t=this.editor.plugins.get("TableUtils"),o=this.editor.model,n=t.getSelectionAffectedTableCells(o.document.selection),i=n[0].findAncestor("table"),{first:r,last:s}=t.getRowIndexes(n),a=this.value?r:s+1,l=i.getAttribute("headingRows")||0;o.change((e=>{if(a){const t=aD(i,a,a>l?l:0);for(const{cell:o}of t)lD(o,a,e)}jE("headingRows",a,i,e,0)}))}_isInHeading(e,t){const o=parseInt(t.getAttribute("headingRows")||"0");return!!o&&e.parent.index0;this.isEnabled=n,this.value=n&&o.every((e=>UE(t,e)))}execute(e={}){if(e.forceValue===this.value)return;const t=this.editor.plugins.get("TableUtils"),o=this.editor.model,n=t.getSelectionAffectedTableCells(o.document.selection),i=n[0].findAncestor("table"),{first:r,last:s}=t.getColumnIndexes(n),a=this.value?r:s+1;o.change((e=>{if(a){const t=cD(i,a);for(const{cell:o,column:n}of t)dD(o,n,a,e)}jE("headingColumns",a,i,e,0)}))}}function CD(e){if(e.is("element","tableColumnGroup"))return e;const t=e.getChildren();return Array.from(t).find((e=>e.is("element","tableColumnGroup")))}function vD(e){const t=CD(e);return t?Array.from(t.getChildren()):[]}class xD extends lr{static get pluginName(){return"TableUtils"}init(){this.decorate("insertColumns"),this.decorate("insertRows")}getCellLocation(e){const t=e.parent,o=t.parent,n=o.getChildIndex(t),i=new JE(o,{row:n});for(const{cell:t,row:o,column:n}of i)if(t===e)return{row:o,column:n}}createTable(e,t){const o=e.createElement("table"),n=t.rows||2,i=t.columns||2;return ED(e,o,0,n,i),t.headingRows&&jE("headingRows",Math.min(t.headingRows,n),o,e,0),t.headingColumns&&jE("headingColumns",Math.min(t.headingColumns,i),o,e,0),o}insertRows(e,t={}){const o=this.editor.model,n=t.at||0,i=t.rows||1,r=void 0!==t.copyStructureFromAbove,s=t.copyStructureFromAbove?n-1:n,a=this.getRows(e),l=this.getColumns(e);if(n>a)throw new E("tableutils-insertrows-insert-out-of-range",this,{options:t});o.change((t=>{const o=e.getAttribute("headingRows")||0;if(o>n&&jE("headingRows",o+i,e,t,0),!r&&(0===n||n===a))return void ED(t,e,n,i,l);const c=r?Math.max(n,s):n,d=new JE(e,{endRow:c}),u=new Array(l).fill(1);for(const{row:e,column:o,cellHeight:a,cellWidth:l,cell:c}of d){const d=e+a-1,h=e<=s&&s<=d;e0&&qE(t,i,n>1?{colspan:n}:void 0),e+=Math.abs(n)-1}}}))}insertColumns(e,t={}){const o=this.editor.model,n=t.at||0,i=t.columns||1;o.change((t=>{const o=e.getAttribute("headingColumns");ni-1)throw new E("tableutils-removerows-row-index-out-of-range",this,{table:e,options:t});o.change((t=>{const o={first:r,last:s},{cellsToMove:n,cellsToTrim:i}=function(e,{first:t,last:o}){const n=new Map,i=[];for(const{row:r,column:s,cellHeight:a,cell:l}of new JE(e,{endRow:o})){const e=r+a-1;if(r>=t&&r<=o&&e>o){const e=a-(o-r+1);n.set(s,{cell:l,rowspan:e})}if(r=t){let n;n=e>=o?o-t+1:e-t+1,i.push({cell:l,rowspan:a-n})}}return{cellsToMove:n,cellsToTrim:i}}(e,o);if(n.size){!function(e,t,o,n){const i=new JE(e,{includeAllSlots:!0,row:t}),r=[...i],s=e.getChild(t);let a;for(const{column:e,cell:t,isAnchor:i}of r)if(o.has(e)){const{cell:t,rowspan:i}=o.get(e),r=a?n.createPositionAfter(a):n.createPositionAt(s,0);n.move(n.createRangeOn(t),r),jE("rowspan",i,t,n),a=t}else i&&(a=t)}(e,s+1,n,t)}for(let o=s;o>=r;o--)t.remove(e.getChild(o));for(const{rowspan:e,cell:o}of i)jE("rowspan",e,o,t);!function(e,{first:t,last:o},n){const i=e.getAttribute("headingRows")||0;if(t{!function(e,t,o){const n=e.getAttribute("headingColumns")||0;if(n&&t.first=n;i--){for(const{cell:o,column:n,cellWidth:r}of[...new JE(e)])n<=i&&r>1&&n+r>i?jE("colspan",r-1,o,t):n===i&&t.remove(o);if(o[i]){const e=0===i?o[1]:o[i-1],n=parseFloat(o[i].getAttribute("columnWidth")),r=parseFloat(e.getAttribute("columnWidth"));t.remove(o[i]),t.setAttribute("columnWidth",n+r+"%",e)}}mD(e,this)||hD(e,this)}))}splitCellVertically(e,t=2){const o=this.editor.model,n=e.parent.parent,i=parseInt(e.getAttribute("rowspan")||"1"),r=parseInt(e.getAttribute("colspan")||"1");o.change((o=>{if(r>1){const{newCellsSpan:n,updatedSpan:s}=BD(r,t);jE("colspan",s,e,o);const a={};n>1&&(a.colspan=n),i>1&&(a.rowspan=i);DD(r>t?t-1:r-1,o,o.createPositionAfter(e),a)}if(rt===e)),c=a.filter((({cell:t,cellWidth:o,column:n})=>t!==e&&n===l||nl));for(const{cell:e,cellWidth:t}of c)o.setAttribute("colspan",t+s,e);const d={};i>1&&(d.rowspan=i),DD(s,o,o.createPositionAfter(e),d);const u=n.getAttribute("headingColumns")||0;u>l&&jE("headingColumns",u+s,n,o)}}))}splitCellHorizontally(e,t=2){const o=this.editor.model,n=e.parent,i=n.parent,r=i.getChildIndex(n),s=parseInt(e.getAttribute("rowspan")||"1"),a=parseInt(e.getAttribute("colspan")||"1");o.change((o=>{if(s>1){const n=[...new JE(i,{startRow:r,endRow:r+s-1,includeAllSlots:!0})],{newCellsSpan:l,updatedSpan:c}=BD(s,t);jE("rowspan",c,e,o);const{column:d}=n.find((({cell:t})=>t===e)),u={};l>1&&(u.rowspan=l),a>1&&(u.colspan=a);let h=0;for(const e of n){const{column:t,row:n}=e,i=t===d;h>=l&&i&&(h=0),n>=r+c&&i&&(h||DD(1,o,e.getPositionBefore(),u),h++)}}if(sr){const e=i+n;o.setAttribute("rowspan",e,t)}const c={};a>1&&(c.colspan=a),ED(o,i,r+1,n,1,c);const d=i.getAttribute("headingRows")||0;d>r&&jE("headingRows",d+n,i,o)}}))}getColumns(e){return[...e.getChild(0).getChildren()].filter((e=>e.is("element","tableCell"))).reduce(((e,t)=>e+parseInt(t.getAttribute("colspan")||"1")),0)}getRows(e){return Array.from(e.getChildren()).reduce(((e,t)=>t.is("element","tableRow")?e+1:e),0)}createTableWalker(e,t={}){return new JE(e,t)}getSelectedTableCells(e){const t=[];for(const o of this.sortRanges(e.getRanges())){const e=o.getContainedElement();e&&e.is("element","tableCell")&&t.push(e)}return t}getTableCellsContainingSelection(e){const t=[];for(const o of e.getRanges()){const e=o.start.findAncestor("tableCell");e&&t.push(e)}return t}getSelectionAffectedTableCells(e){const t=this.getSelectedTableCells(e);return t.length?t:this.getTableCellsContainingSelection(e)}getRowIndexes(e){const t=e.map((e=>e.parent.index));return this._getFirstLastIndexesObject(t)}getColumnIndexes(e){const t=e[0].findAncestor("table"),o=[...new JE(t)].filter((t=>e.includes(t.cell))).map((e=>e.column));return this._getFirstLastIndexesObject(o)}isSelectionRectangular(e){if(e.length<2||!this._areCellInTheSameTableSection(e))return!1;const t=new Set,o=new Set;let n=0;for(const i of e){const{row:e,column:r}=this.getCellLocation(i),s=parseInt(i.getAttribute("rowspan"))||1,a=parseInt(i.getAttribute("colspan"))||1;t.add(e),o.add(r),s>1&&t.add(e+s-1),a>1&&o.add(r+a-1),n+=s*a}const i=function(e,t){const o=Array.from(e.values()),n=Array.from(t.values()),i=Math.max(...o),r=Math.min(...o),s=Math.max(...n),a=Math.min(...n);return(i-r+1)*(s-a+1)}(t,o);return i==n}sortRanges(e){return Array.from(e).sort(SD)}_getFirstLastIndexesObject(e){const t=e.sort(((e,t)=>e-t));return{first:t[0],last:t[t.length-1]}}_areCellInTheSameTableSection(e){const t=e[0].findAncestor("table"),o=this.getRowIndexes(e),n=parseInt(t.getAttribute("headingRows"))||0;if(!this._areIndexesInSameSection(o,n))return!1;const i=this.getColumnIndexes(e),r=parseInt(t.getAttribute("headingColumns"))||0;return this._areIndexesInSameSection(i,r)}_areIndexesInSameSection({first:e,last:t},o){return e{const n=t.getSelectedTableCells(e.document.selection),i=n.shift(),{mergeWidth:r,mergeHeight:s}=function(e,t,o){let n=0,i=0;for(const e of t){const{row:t,column:r}=o.getCellLocation(e);n=FD(e,r,n,"colspan"),i=FD(e,t,i,"rowspan")}const{row:r,column:s}=o.getCellLocation(e),a=n-s,l=i-r;return{mergeWidth:a,mergeHeight:l}}(i,n,t);jE("colspan",r,i,o),jE("rowspan",s,i,o);for(const e of n)ID(e,i,o);pD(i.findAncestor("table"),t),o.setSelection(i,"in")}))}}function ID(e,t,o){PD(e)||(PD(t)&&o.remove(o.createRangeIn(t)),o.move(o.createRangeIn(e),o.createPositionAt(t,"end"))),o.remove(e)}function PD(e){const t=e.getChild(0);return 1==e.childCount&&t.is("element","paragraph")&&t.isEmpty}function FD(e,t,o,n){const i=parseInt(e.getAttribute(n)||"1");return Math.max(o,t+i)}class MD extends dr{constructor(e){super(e),this.affectsData=!1}refresh(){const e=this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(this.editor.model.document.selection);this.isEnabled=e.length>0}execute(){const e=this.editor.model,t=this.editor.plugins.get("TableUtils"),o=t.getSelectionAffectedTableCells(e.document.selection),n=t.getRowIndexes(o),i=o[0].findAncestor("table"),r=[];for(let t=n.first;t<=n.last;t++)for(const o of i.getChild(t).getChildren())r.push(e.createRangeOn(o));e.change((e=>{e.setSelection(r)}))}}class RD extends dr{constructor(e){super(e),this.affectsData=!1}refresh(){const e=this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(this.editor.model.document.selection);this.isEnabled=e.length>0}execute(){const e=this.editor.plugins.get("TableUtils"),t=this.editor.model,o=e.getSelectionAffectedTableCells(t.document.selection),n=o[0],i=o.pop(),r=n.findAncestor("table"),s=e.getCellLocation(n),a=e.getCellLocation(i),l=Math.min(s.column,a.column),c=Math.max(s.column,a.column),d=[];for(const e of new JE(r,{startColumn:l,endColumn:c}))d.push(t.createRangeOn(e.cell));t.change((e=>{e.setSelection(d)}))}}function zD(e){e.document.registerPostFixer((t=>function(e,t){const o=t.document.differ.getChanges();let n=!1;const i=new Set;for(const t of o){let o=null;"insert"==t.type&&"table"==t.name&&(o=t.position.nodeAfter),"insert"!=t.type&&"remove"!=t.type||"tableRow"!=t.name&&"tableCell"!=t.name||(o=t.position.findAncestor("table")),ND(t)&&(o=t.range.start.findAncestor("table")),o&&!i.has(o)&&(n=VD(o,e)||n,n=OD(o,e)||n,i.add(o))}return n}(t,e)))}function VD(e,t){let o=!1;const n=function(e){const t=parseInt(e.getAttribute("headingRows")||"0"),o=Array.from(e.getChildren()).reduce(((e,t)=>t.is("element","tableRow")?e+1:e),0),n=[];for(const{row:i,cell:r,cellHeight:s}of new JE(e)){if(s<2)continue;const e=ie){const t=e-i;n.push({cell:r,rowspan:t})}}return n}(e);if(n.length){o=!0;for(const e of n)jE("rowspan",e.rowspan,e.cell,t,1)}return o}function OD(e,t){let o=!1;const n=function(e){const t=new Array(e.childCount).fill(0);for(const{rowIndex:o}of new JE(e,{includeAllSlots:!0}))t[o]++;return t}(e),i=[];for(const[t,o]of n.entries())!o&&e.getChild(t).is("element","tableRow")&&i.push(t);if(i.length){o=!0;for(const o of i.reverse())t.remove(e.getChild(o)),n.splice(o,1)}const r=n.filter(((t,o)=>e.getChild(o).is("element","tableRow"))),s=r[0];if(!r.every((e=>e===s))){const n=r.reduce(((e,t)=>t>e?t:e),0);for(const[i,s]of r.entries()){const r=n-s;if(r){for(let o=0;ofunction(e,t){const o=t.document.differ.getChanges();let n=!1;for(const t of o)"insert"==t.type&&"table"==t.name&&(n=HD(t.position.nodeAfter,e)||n),"insert"==t.type&&"tableRow"==t.name&&(n=jD(t.position.nodeAfter,e)||n),"insert"==t.type&&"tableCell"==t.name&&(n=qD(t.position.nodeAfter,e)||n),"remove"!=t.type&&"insert"!=t.type||!UD(t)||(n=qD(t.position.parent,e)||n);return n}(t,e)))}function HD(e,t){let o=!1;for(const n of e.getChildren())n.is("element","tableRow")&&(o=jD(n,t)||o);return o}function jD(e,t){let o=!1;for(const n of e.getChildren())o=qD(n,t)||o;return o}function qD(e,t){if(0==e.childCount)return t.insertElement("paragraph",e),!0;const o=Array.from(e.getChildren()).filter((e=>e.is("$text")));for(const e of o)t.wrap(t.createRangeOn(e),"paragraph");return!!o.length}function UD(e){return!!e.position.parent.is("element","tableCell")&&("insert"==e.type&&"$text"==e.name||"remove"==e.type)}function WD(e,t){if(!e.is("element","paragraph"))return!1;const o=t.toViewElement(e);return!!o&&tD(e)!==o.is("element","span")}var $D=i(8864),GD={attributes:{"data-cke":!0}};GD.setAttributes=Ar(),GD.insert=_r().bind(null,"head"),GD.domAPI=kr(),GD.insertStyleElement=vr();fr()($D.A,GD);$D.A&&$D.A.locals&&$D.A.locals;class KD extends lr{static get pluginName(){return"TableEditing"}static get requires(){return[xD]}constructor(e){super(e),this._additionalSlots=[]}init(){const e=this.editor,t=e.model,o=t.schema,n=e.conversion,i=e.plugins.get(xD);o.register("table",{inheritAllFrom:"$blockObject",allowAttributes:["headingRows","headingColumns"]}),o.register("tableRow",{allowIn:"table",isLimit:!0}),o.register("tableCell",{allowContentOf:"$container",allowIn:"tableRow",allowAttributes:["colspan","rowspan"],isLimit:!0,isSelectable:!0}),n.for("upcast").add((e=>{e.on("element:figure",((e,t,o)=>{if(!o.consumable.test(t.viewItem,{name:!0,classes:"table"}))return;const n=function(e){for(const t of e.getChildren())if(t.is("element","table"))return t}(t.viewItem);if(!n||!o.consumable.test(n,{name:!0}))return;o.consumable.consume(t.viewItem,{name:!0,classes:"table"});const i=Qi(o.convertItem(n,t.modelCursor).modelRange.getItems());i?(o.convertChildren(t.viewItem,o.writer.createPositionAt(i,"end")),o.updateConversionResult(i,t)):o.consumable.revert(t.viewItem,{name:!0,classes:"table"})}))})),n.for("upcast").add(GE()),n.for("editingDowncast").elementToStructure({model:{name:"table",attributes:["headingRows"]},view:QE(i,{asWidget:!0,additionalSlots:this._additionalSlots})}),n.for("dataDowncast").elementToStructure({model:{name:"table",attributes:["headingRows"]},view:QE(i,{additionalSlots:this._additionalSlots})}),n.for("upcast").elementToElement({model:"tableRow",view:"tr"}),n.for("upcast").add((e=>{e.on("element:tr",((e,t)=>{t.viewItem.isEmpty&&0==t.modelCursor.index&&e.stop()}),{priority:"high"})})),n.for("downcast").elementToElement({model:"tableRow",view:(e,{writer:t})=>e.isEmpty?t.createEmptyElement("tr"):t.createContainerElement("tr")}),n.for("upcast").elementToElement({model:"tableCell",view:"td"}),n.for("upcast").elementToElement({model:"tableCell",view:"th"}),n.for("upcast").add(KE("td")),n.for("upcast").add(KE("th")),n.for("editingDowncast").elementToElement({model:"tableCell",view:XE({asWidget:!0})}),n.for("dataDowncast").elementToElement({model:"tableCell",view:XE()}),n.for("editingDowncast").elementToElement({model:"paragraph",view:eD({asWidget:!0}),converterPriority:"high"}),n.for("dataDowncast").elementToElement({model:"paragraph",view:eD(),converterPriority:"high"}),n.for("downcast").attributeToAttribute({model:"colspan",view:"colspan"}),n.for("upcast").attributeToAttribute({model:{key:"colspan",value:ZD("colspan")},view:"colspan"}),n.for("downcast").attributeToAttribute({model:"rowspan",view:"rowspan"}),n.for("upcast").attributeToAttribute({model:{key:"rowspan",value:ZD("rowspan")},view:"rowspan"}),e.config.define("table.defaultHeadings.rows",0),e.config.define("table.defaultHeadings.columns",0),e.commands.add("insertTable",new oD(e)),e.commands.add("insertTableRowAbove",new nD(e,{order:"above"})),e.commands.add("insertTableRowBelow",new nD(e,{order:"below"})),e.commands.add("insertTableColumnLeft",new iD(e,{order:"left"})),e.commands.add("insertTableColumnRight",new iD(e,{order:"right"})),e.commands.add("removeTableRow",new wD(e)),e.commands.add("removeTableColumn",new _D(e)),e.commands.add("splitTableCellVertically",new rD(e,{direction:"vertically"})),e.commands.add("splitTableCellHorizontally",new rD(e,{direction:"horizontally"})),e.commands.add("mergeTableCells",new TD(e)),e.commands.add("mergeTableCellRight",new bD(e,{direction:"right"})),e.commands.add("mergeTableCellLeft",new bD(e,{direction:"left"})),e.commands.add("mergeTableCellDown",new bD(e,{direction:"down"})),e.commands.add("mergeTableCellUp",new bD(e,{direction:"up"})),e.commands.add("setTableColumnHeader",new AD(e)),e.commands.add("setTableRowHeader",new yD(e)),e.commands.add("selectTableRow",new MD(e)),e.commands.add("selectTableColumn",new RD(e)),zD(t),LD(t),this.listenTo(t.document,"change:data",(()=>{!function(e,t){const o=e.document.differ;for(const e of o.getChanges()){let o,n=!1;if("attribute"==e.type){const t=e.range.start.nodeAfter;if(!t||!t.is("element","table"))continue;if("headingRows"!=e.attributeKey&&"headingColumns"!=e.attributeKey)continue;o=t,n="headingRows"==e.attributeKey}else"tableRow"!=e.name&&"tableCell"!=e.name||(o=e.position.findAncestor("table"),n="tableRow"==e.name);if(!o)continue;const i=o.getAttribute("headingRows")||0,r=o.getAttribute("headingColumns")||0,s=new JE(o);for(const e of s){const o=e.rowWD(e,t.mapper)));for(const e of o)t.reconvertItem(e)}}(t,e.editing)}))}registerAdditionalSlot(e){this._additionalSlots.push(e)}}function ZD(e){return t=>{const o=parseInt(t.getAttribute(e));return Number.isNaN(o)||o<=0?null:o}}var JD=i(8603),YD={attributes:{"data-cke":!0}};YD.setAttributes=Ar(),YD.insert=_r().bind(null,"head"),YD.domAPI=kr(),YD.insertStyleElement=vr();fr()(JD.A,YD);JD.A&&JD.A.locals&&JD.A.locals;class QD extends pm{constructor(e){super(e);const t=this.bindTemplate;this.items=this._createGridCollection(),this.keystrokes=new er,this.focusTracker=new Xi,this.set("rows",0),this.set("columns",0),this.bind("label").to(this,"columns",this,"rows",((e,t)=>`${t} × ${e}`)),this.setTemplate({tag:"div",attributes:{class:["ck"]},children:[{tag:"div",attributes:{class:["ck-insert-table-dropdown__grid"]},on:{"mouseover@.ck-insert-table-dropdown-grid-box":t.to("boxover")},children:this.items},{tag:"div",attributes:{class:["ck","ck-insert-table-dropdown__label"],"aria-hidden":!0},children:[{text:t.to("label")}]}],on:{mousedown:t.to((e=>{e.preventDefault()})),click:t.to((()=>{this.fire("execute")}))}}),this.on("boxover",((e,t)=>{const{row:o,column:n}=t.target.dataset;this.items.get(10*(parseInt(o,10)-1)+(parseInt(n,10)-1)).focus()})),this.focusTracker.on("change:focusedElement",((e,t,o)=>{if(!o)return;const{row:n,column:i}=o.dataset;this.set({rows:parseInt(n),columns:parseInt(i)})})),this.on("change:columns",(()=>this._highlightGridBoxes())),this.on("change:rows",(()=>this._highlightGridBoxes()))}render(){super.render(),km({keystrokeHandler:this.keystrokes,focusTracker:this.focusTracker,gridItems:this.items,numberOfColumns:10,uiLanguageDirection:this.locale&&this.locale.uiLanguageDirection});for(const e of this.items)this.focusTracker.add(e.element);this.keystrokes.listenTo(this.element)}reset(){this.set({rows:1,columns:1})}focus(){this.items.get(0).focus()}focusLast(){this.items.get(0).focus()}_highlightGridBoxes(){const e=this.rows,t=this.columns;this.items.map(((o,n)=>{const i=Math.floor(n/10){const n=e.commands.get("insertTable"),i=Eg(o);let r;return i.bind("isEnabled").to(n),i.buttonView.set({icon:qh.table,label:t("Insert table"),tooltip:!0}),i.on("change:isOpen",(()=>{r||(r=new QD(o),i.panelView.children.add(r),r.delegate("execute").to(i),i.on("execute",(()=>{e.execute("insertTable",{rows:r.rows,columns:r.columns}),e.editing.view.focus()})))})),i})),e.ui.componentFactory.add("menuBar:insertTable",(o=>{const n=e.commands.get("insertTable"),i=new mk(o),r=new QD(o);return r.delegate("execute").to(i),i.on("change:isOpen",((e,t,o)=>{o||r.reset()})),r.on("execute",(()=>{e.execute("insertTable",{rows:r.rows,columns:r.columns}),e.editing.view.focus()})),i.buttonView.set({label:t("Table"),icon:qh.table}),i.panelView.children.add(r),i.bind("isEnabled").to(n),i})),e.ui.componentFactory.add("tableColumn",(e=>{const n=[{type:"switchbutton",model:{commandName:"setTableColumnHeader",label:t("Header column"),bindIsOn:!0}},{type:"separator"},{type:"button",model:{commandName:o?"insertTableColumnLeft":"insertTableColumnRight",label:t("Insert column left")}},{type:"button",model:{commandName:o?"insertTableColumnRight":"insertTableColumnLeft",label:t("Insert column right")}},{type:"button",model:{commandName:"removeTableColumn",label:t("Delete column")}},{type:"button",model:{commandName:"selectTableColumn",label:t("Select column")}}];return this._prepareDropdown(t("Column"),'',n,e)})),e.ui.componentFactory.add("tableRow",(e=>{const o=[{type:"switchbutton",model:{commandName:"setTableRowHeader",label:t("Header row"),bindIsOn:!0}},{type:"separator"},{type:"button",model:{commandName:"insertTableRowAbove",label:t("Insert row above")}},{type:"button",model:{commandName:"insertTableRowBelow",label:t("Insert row below")}},{type:"button",model:{commandName:"removeTableRow",label:t("Delete row")}},{type:"button",model:{commandName:"selectTableRow",label:t("Select row")}}];return this._prepareDropdown(t("Row"),'',o,e)})),e.ui.componentFactory.add("mergeTableCells",(e=>{const n=[{type:"button",model:{commandName:"mergeTableCellUp",label:t("Merge cell up")}},{type:"button",model:{commandName:o?"mergeTableCellRight":"mergeTableCellLeft",label:t("Merge cell right")}},{type:"button",model:{commandName:"mergeTableCellDown",label:t("Merge cell down")}},{type:"button",model:{commandName:o?"mergeTableCellLeft":"mergeTableCellRight",label:t("Merge cell left")}},{type:"separator"},{type:"button",model:{commandName:"splitTableCellVertically",label:t("Split cell vertically")}},{type:"button",model:{commandName:"splitTableCellHorizontally",label:t("Split cell horizontally")}}];return this._prepareMergeSplitButtonDropdown(t("Merge cells"),'',n,e)}))}_prepareDropdown(e,t,o,n){const i=this.editor,r=Eg(n),s=this._fillDropdownWithListOptions(r,o);return r.buttonView.set({label:e,icon:t,tooltip:!0}),r.bind("isEnabled").toMany(s,"isEnabled",((...e)=>e.some((e=>e)))),this.listenTo(r,"execute",(e=>{i.execute(e.source.commandName),e.source instanceof bp||i.editing.view.focus()})),r}_prepareMergeSplitButtonDropdown(e,t,o,n){const i=this.editor,r=Eg(n,yg),s="mergeTableCells",a=i.commands.get(s),l=this._fillDropdownWithListOptions(r,o);return r.buttonView.set({label:e,icon:t,tooltip:!0,isEnabled:!0}),r.bind("isEnabled").toMany([a,...l],"isEnabled",((...e)=>e.some((e=>e)))),this.listenTo(r.buttonView,"execute",(()=>{i.execute(s),i.editing.view.focus()})),this.listenTo(r,"execute",(e=>{i.execute(e.source.commandName),i.editing.view.focus()})),r}_fillDropdownWithListOptions(e,t){const o=this.editor,n=[],i=new Yi;for(const e of t)eB(e,o,n,i);return Sg(e,i),n}}function eB(e,t,o,n){if("button"===e.type||"switchbutton"===e.type){const n=e.model=new Db(e.model),{commandName:i,bindIsOn:r}=e.model,s=t.commands.get(i);o.push(s),n.set({commandName:i}),n.bind("isEnabled").to(s),r&&n.bind("isOn").to(s,"value"),n.set({withText:!0})}n.add(e)}var tB=i(2850),oB={attributes:{"data-cke":!0}};oB.setAttributes=Ar(),oB.insert=_r().bind(null,"head"),oB.domAPI=kr(),oB.insertStyleElement=vr();fr()(tB.A,oB);tB.A&&tB.A.locals&&tB.A.locals;class nB extends lr{static get pluginName(){return"TableSelection"}static get requires(){return[xD,xD]}init(){const e=this.editor,t=e.model,o=e.editing.view;this.listenTo(t,"deleteContent",((e,t)=>this._handleDeleteContent(e,t)),{priority:"high"}),this.listenTo(o.document,"insertText",((e,t)=>this._handleInsertTextEvent(e,t)),{priority:"high"}),this._defineSelectionConverter(),this._enablePluginDisabling()}getSelectedTableCells(){const e=this.editor.plugins.get(xD),t=this.editor.model.document.selection,o=e.getSelectedTableCells(t);return 0==o.length?null:o}getSelectionAsFragment(){const e=this.editor.plugins.get(xD),t=this.getSelectedTableCells();return t?this.editor.model.change((o=>{const n=o.createDocumentFragment(),{first:i,last:r}=e.getColumnIndexes(t),{first:s,last:a}=e.getRowIndexes(t),l=t[0].findAncestor("table");let c=a,d=r;if(e.isSelectionRectangular(t)){const e={firstColumn:i,lastColumn:r,firstRow:s,lastRow:a};c=gD(l,e),d=fD(l,e)}const u=sD(l,{startRow:s,startColumn:i,endRow:c,endColumn:d},o);return o.insert(u,n,0),n})):null}setCellSelection(e,t){const o=this._getCellsToSelect(e,t);this.editor.model.change((e=>{e.setSelection(o.cells.map((t=>e.createRangeOn(t))),{backward:o.backward})}))}getFocusCell(){const e=[...this.editor.model.document.selection.getRanges()].pop().getContainedElement();return e&&e.is("element","tableCell")?e:null}getAnchorCell(){const e=Qi(this.editor.model.document.selection.getRanges()).getContainedElement();return e&&e.is("element","tableCell")?e:null}_defineSelectionConverter(){const e=this.editor,t=new Set;e.conversion.for("editingDowncast").add((e=>e.on("selection",((e,o,n)=>{const i=n.writer;!function(e){for(const o of t)e.removeClass("ck-editor__editable_selected",o);t.clear()}(i);const r=this.getSelectedTableCells();if(!r)return;for(const e of r){const o=n.mapper.toViewElement(e);i.addClass("ck-editor__editable_selected",o),t.add(o)}const s=n.mapper.toViewElement(r[r.length-1]);i.setSelection(s,0)}),{priority:"lowest"})))}_enablePluginDisabling(){const e=this.editor;this.on("change:isEnabled",(()=>{if(!this.isEnabled){const t=this.getSelectedTableCells();if(!t)return;e.model.change((o=>{const n=o.createPositionAt(t[0],0),i=e.model.schema.getNearestSelectionRange(n);o.setSelection(i)}))}}))}_handleDeleteContent(e,t){const o=this.editor.plugins.get(xD),n=t[0],i=t[1],r=this.editor.model,s=!i||"backward"==i.direction,a=o.getSelectedTableCells(n);a.length&&(e.stop(),r.change((e=>{const t=a[s?a.length-1:0];r.change((e=>{for(const t of a)r.deleteContent(e.createSelection(t,"in"))}));const o=r.schema.getNearestSelectionRange(e.createPositionAt(t,0));n.is("documentSelection")?e.setSelection(o):n.setTo(o)})))}_handleInsertTextEvent(e,t){const o=this.editor,n=this.getSelectedTableCells();if(!n)return;const i=o.editing.view,r=o.editing.mapper,s=n.map((e=>i.createRangeOn(r.toViewElement(e))));t.selection=i.createSelection(s)}_getCellsToSelect(e,t){const o=this.editor.plugins.get("TableUtils"),n=o.getCellLocation(e),i=o.getCellLocation(t),r=Math.min(n.row,i.row),s=Math.max(n.row,i.row),a=Math.min(n.column,i.column),l=Math.max(n.column,i.column),c=new Array(s-r+1).fill(null).map((()=>[])),d={startRow:r,endRow:s,startColumn:a,endColumn:l};for(const{row:t,cell:o}of new JE(e.findAncestor("table"),d))c[t-r].push(o);const u=i.rowe.reverse())),{cells:c.flat(),backward:u||h}}}class iB extends lr{static get pluginName(){return"TableClipboard"}static get requires(){return[H_,j_,nB,xD]}init(){const e=this.editor,t=e.editing.view.document;this.listenTo(t,"copy",((e,t)=>this._onCopyCut(e,t))),this.listenTo(t,"cut",((e,t)=>this._onCopyCut(e,t))),this.listenTo(e.model,"insertContent",((e,[t,o])=>this._onInsertContent(e,t,o)),{priority:"high"}),this.decorate("_replaceTableSlotCell")}_onCopyCut(e,t){const o=this.editor.editing.view,n=this.editor.plugins.get(nB),i=this.editor.plugins.get(H_);n.getSelectedTableCells()&&("cut"!=e.name||this.editor.model.canEditAt(this.editor.model.document.selection))&&(t.preventDefault(),e.stop(),this.editor.model.enqueueChange({isUndoable:"cut"===e.name},(()=>{const r=i._copySelectedFragmentWithMarkers(e.name,this.editor.model.document.selection,(()=>n.getSelectionAsFragment()));o.document.fire("clipboardOutput",{dataTransfer:t.dataTransfer,content:this.editor.data.toView(r),method:e.name})})))}_onInsertContent(e,t,o){if(o&&!o.is("documentSelection"))return;const n=this.editor.model,i=this.editor.plugins.get(xD),r=this.editor.plugins.get(H_),s=this.getTableIfOnlyTableInContent(t,n);if(!s)return;const a=i.getSelectionAffectedTableCells(n.document.selection);a.length?(e.stop(),t.is("documentFragment")?r._pasteMarkersIntoTransformedElement(t.markers,(e=>this._replaceSelectedCells(s,a,e))):this.editor.model.change((e=>{this._replaceSelectedCells(s,a,e)}))):pD(s,i)}_replaceSelectedCells(e,t,o){const n=this.editor.plugins.get(xD),i={width:n.getColumns(e),height:n.getRows(e)},r=function(e,t,o,n){const i=e[0].findAncestor("table"),r=n.getColumnIndexes(e),s=n.getRowIndexes(e),a={firstColumn:r.first,lastColumn:r.last,firstRow:s.first,lastRow:s.last},l=1===e.length;l&&(a.lastRow+=t.height-1,a.lastColumn+=t.width-1,function(e,t,o,n){const i=n.getColumns(e),r=n.getRows(e);o>i&&n.insertColumns(e,{at:i,columns:o-i});t>r&&n.insertRows(e,{at:r,rows:t-r})}(i,a.lastRow+1,a.lastColumn+1,n));l||!n.isSelectionRectangular(e)?function(e,t,o){const{firstRow:n,lastRow:i,firstColumn:r,lastColumn:s}=t,a={first:n,last:i},l={first:r,last:s};sB(e,r,a,o),sB(e,s+1,a,o),rB(e,n,l,o),rB(e,i+1,l,o,n)}(i,a,o):(a.lastRow=gD(i,a),a.lastColumn=fD(i,a));return a}(t,i,o,n),s=r.lastRow-r.firstRow+1,a=r.lastColumn-r.firstColumn+1;e=sD(e,{startRow:0,startColumn:0,endRow:Math.min(s,i.height)-1,endColumn:Math.min(a,i.width)-1},o);const l=t[0].findAncestor("table"),c=this._replaceSelectedCellsWithPasted(e,i,l,r,o);if(this.editor.plugins.get("TableSelection").isEnabled){const e=n.sortRanges(c.map((e=>o.createRangeOn(e))));o.setSelection(e)}else o.setSelection(c[0],0);return l}_replaceSelectedCellsWithPasted(e,t,o,n,i){const{width:r,height:s}=t,a=function(e,t,o){const n=new Array(o).fill(null).map((()=>new Array(t).fill(null)));for(const{column:t,row:o,cell:i}of new JE(e))n[o][t]=i;return n}(e,r,s),l=[...new JE(o,{startRow:n.firstRow,endRow:n.lastRow,startColumn:n.firstColumn,endColumn:n.lastColumn,includeAllSlots:!0})],c=[];let d;for(const e of l){const{row:t,column:o}=e;o===n.firstColumn&&(d=e.getPositionBefore());const l=t-n.firstRow,u=o-n.firstColumn,h=a[l%s][u%r],m=h?i.cloneElement(h):null,p=this._replaceTableSlotCell(e,m,d,i);p&&(uD(p,t,o,n.lastRow,n.lastColumn,i),c.push(p),d=i.createPositionAfter(p))}const u=parseInt(o.getAttribute("headingRows")||"0"),h=parseInt(o.getAttribute("headingColumns")||"0"),m=n.firstRowaB(e,t,o))).map((({cell:e})=>lD(e,t,n)))}function sB(e,t,o,n){if(t<1)return;return cD(e,t).filter((({row:e,cellHeight:t})=>aB(e,t,o))).map((({cell:e,column:o})=>dD(e,o,t,n)))}function aB(e,t,o){const n=e+t-1,{first:i,last:r}=o;return e>=i&&e<=r||e=i}class lB extends lr{static get pluginName(){return"TableKeyboard"}static get requires(){return[nB,xD]}init(){const e=this.editor,t=e.editing.view.document,o=e.t;this.listenTo(t,"arrowKey",((...e)=>this._onArrowKey(...e)),{context:"table"}),this.listenTo(t,"tab",((...e)=>this._handleTabOnSelectedTable(...e)),{context:"figure"}),this.listenTo(t,"tab",((...e)=>this._handleTab(...e)),{context:["th","td"]}),e.accessibility.addKeystrokeInfoGroup({id:"table",label:o("Keystrokes that can be used in a table cell"),keystrokes:[{label:o("Move the selection to the next cell"),keystroke:"Tab"},{label:o("Move the selection to the previous cell"),keystroke:"Shift+Tab"},{label:o("Insert a new table row (when in the last cell of a table)"),keystroke:"Tab"},{label:o("Navigate through the table"),keystroke:[["arrowup"],["arrowright"],["arrowdown"],["arrowleft"]]}]})}_handleTabOnSelectedTable(e,t){const o=this.editor,n=o.model.document.selection.getSelectedElement();n&&n.is("element","table")&&(t.preventDefault(),t.stopPropagation(),e.stop(),o.model.change((e=>{e.setSelection(e.createRangeIn(n.getChild(0).getChild(0)))})))}_handleTab(e,t){const o=this.editor,n=this.editor.plugins.get(xD),i=this.editor.plugins.get("TableSelection"),r=o.model.document.selection,s=!t.shiftKey;let a=n.getTableCellsContainingSelection(r)[0];if(a||(a=i.getFocusCell()),!a)return;t.preventDefault(),t.stopPropagation(),e.stop();const l=a.parent,c=l.parent,d=c.getChildIndex(l),u=l.getChildIndex(a),h=0===u;if(!s&&h&&0===d)return void o.model.change((e=>{e.setSelection(e.createRangeOn(c))}));const m=u===l.childCount-1,p=d===n.getRows(c)-1;if(s&&p&&m&&(o.execute("insertTableRowBelow"),d===n.getRows(c)-1))return void o.model.change((e=>{e.setSelection(e.createRangeOn(c))}));let g;if(s&&m){const e=c.getChild(d+1);g=e.getChild(0)}else if(!s&&h){const e=c.getChild(d-1);g=e.getChild(e.childCount-1)}else g=l.getChild(u+(s?1:-1));o.model.change((e=>{e.setSelection(e.createRangeIn(g))}))}_onArrowKey(e,t){const o=this.editor,n=Ci(t.keyCode,o.locale.contentLanguageDirection);this._handleArrowKeys(n,t.shiftKey)&&(t.preventDefault(),t.stopPropagation(),e.stop())}_handleArrowKeys(e,t){const o=this.editor.plugins.get(xD),n=this.editor.plugins.get("TableSelection"),i=this.editor.model,r=i.document.selection,s=["right","down"].includes(e),a=o.getSelectedTableCells(r);if(a.length){let o;return o=t?n.getFocusCell():s?a[a.length-1]:a[0],this._navigateFromCellInDirection(o,e,t),!0}const l=r.focus.findAncestor("tableCell");if(!l)return!1;if(!r.isCollapsed)if(t){if(r.isBackward==s&&!r.containsEntireContent(l))return!1}else{const e=r.getSelectedElement();if(!e||!i.schema.isObject(e))return!1}return!!this._isSelectionAtCellEdge(r,l,s)&&(this._navigateFromCellInDirection(l,e,t),!0)}_isSelectionAtCellEdge(e,t,o){const n=this.editor.model,i=this.editor.model.schema,r=o?e.getLastPosition():e.getFirstPosition();if(!i.getLimitElement(r).is("element","tableCell")){return n.createPositionAt(t,o?"end":0).isTouching(r)}const s=n.createSelection(r);return n.modifySelection(s,{direction:o?"forward":"backward"}),r.isEqual(s.focus)}_navigateFromCellInDirection(e,t,o=!1){const n=this.editor.model,i=e.findAncestor("table"),r=[...new JE(i,{includeAllSlots:!0})],{row:s,column:a}=r[r.length-1],l=r.find((({cell:t})=>t==e));let{row:c,column:d}=l;switch(t){case"left":d--;break;case"up":c--;break;case"right":d+=l.cellWidth;break;case"down":c+=l.cellHeight}if(c<0||c>s||d<0&&c<=0||d>a&&c>=s)return void n.change((e=>{e.setSelection(e.createRangeOn(i))}));d<0?(d=o?0:a,c--):d>a&&(d=o?a:0,c++);const u=r.find((e=>e.row==c&&e.column==d)).cell,h=["right","down"].includes(t),m=this.editor.plugins.get("TableSelection");if(o&&m.isEnabled){const t=m.getAnchorCell()||e;m.setCellSelection(t,u)}else{const e=n.createPositionAt(u,h?0:"end");n.change((t=>{t.setSelection(e)}))}}}class cB extends La{constructor(){super(...arguments),this.domEventType=["mousemove","mouseleave"]}onDomEvent(e){this.fire(e.type,e)}}class dB extends lr{static get pluginName(){return"TableMouse"}static get requires(){return[nB,xD]}init(){this.editor.editing.view.addObserver(cB),this._enableShiftClickSelection(),this._enableMouseDragSelection()}_enableShiftClickSelection(){const e=this.editor,t=e.plugins.get(xD);let o=!1;const n=e.plugins.get(nB);this.listenTo(e.editing.view.document,"mousedown",((i,r)=>{const s=e.model.document.selection;if(!this.isEnabled||!n.isEnabled)return;if(!r.domEvent.shiftKey)return;const a=n.getAnchorCell()||t.getTableCellsContainingSelection(s)[0];if(!a)return;const l=this._getModelTableCellFromDomEvent(r);l&&uB(a,l)&&(o=!0,n.setCellSelection(a,l),r.preventDefault())})),this.listenTo(e.editing.view.document,"mouseup",(()=>{o=!1})),this.listenTo(e.editing.view.document,"selectionChange",(e=>{o&&e.stop()}),{priority:"highest"})}_enableMouseDragSelection(){const e=this.editor;let t,o,n=!1,i=!1;const r=e.plugins.get(nB);this.listenTo(e.editing.view.document,"mousedown",((e,o)=>{this.isEnabled&&r.isEnabled&&(o.domEvent.shiftKey||o.domEvent.ctrlKey||o.domEvent.altKey||(t=this._getModelTableCellFromDomEvent(o)))})),this.listenTo(e.editing.view.document,"mousemove",((e,s)=>{if(!s.domEvent.buttons)return;if(!t)return;const a=this._getModelTableCellFromDomEvent(s);a&&uB(t,a)&&(o=a,n||o==t||(n=!0)),n&&(i=!0,r.setCellSelection(t,o),s.preventDefault())})),this.listenTo(e.editing.view.document,"mouseup",(()=>{n=!1,i=!1,t=null,o=null})),this.listenTo(e.editing.view.document,"selectionChange",(e=>{i&&e.stop()}),{priority:"highest"})}_getModelTableCellFromDomEvent(e){const t=e.target,o=this.editor.editing.view.createPositionAt(t,0);return this.editor.editing.mapper.toModelPosition(o).parent.findAncestor("tableCell",{includeSelf:!0})}}function uB(e,t){return e.parent.parent==t.parent.parent}var hB=i(9969),mB={attributes:{"data-cke":!0}};mB.setAttributes=Ar(),mB.insert=_r().bind(null,"head"),mB.domAPI=kr(),mB.insertStyleElement=vr();fr()(hB.A,mB);hB.A&&hB.A.locals&&hB.A.locals;function pB(e){const t=gB(e);return t||fB(e)}function gB(e){const t=e.getSelectedElement();return t&&bB(t)?t:null}function fB(e){const t=e.getFirstPosition();if(!t)return null;let o=t.parent;for(;o;){if(o.is("element")&&bB(o))return o;o=o.parent}return null}function bB(e){return!!e.getCustomProperty("table")&&Rk(e)}var kB=i(4307),wB={attributes:{"data-cke":!0}};wB.setAttributes=Ar(),wB.insert=_r().bind(null,"head"),wB.domAPI=kr(),wB.insertStyleElement=vr();fr()(kB.A,wB);kB.A&&kB.A.locals&&kB.A.locals;class _B extends pm{constructor(e,t){super(e),this.set("value",""),this.set("isReadOnly",!1),this.set("isFocused",!1),this.set("isEmpty",!0),this.options=t,this.focusTracker=new Xi,this._focusables=new Uh,this.dropdownView=this._createDropdownView(),this.inputView=this._createInputTextView(),this.keystrokes=new er,this._stillTyping=!1,this.focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-input-color"]},children:[this.dropdownView,this.inputView]}),this.on("change:value",((e,t,o)=>this._setInputValue(o)))}render(){super.render(),[this.inputView,this.dropdownView.buttonView].forEach((e=>{this.focusTracker.add(e.element),this._focusables.add(e)})),this.keystrokes.listenTo(this.element)}focus(e){-1===e?this.focusCycler.focusLast():this.focusCycler.focusFirst()}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}_createDropdownView(){const e=this.locale,t=e.t,o=this.bindTemplate,n=this._createColorSelector(e),i=Eg(e),r=new pm;return r.setTemplate({tag:"span",attributes:{class:["ck","ck-input-color__button__preview"],style:{backgroundColor:o.to("value")}},children:[{tag:"span",attributes:{class:["ck","ck-input-color__button__preview__no-color-indicator",o.if("value","ck-hidden",(e=>""!=e))]}}]}),i.buttonView.extendTemplate({attributes:{class:"ck-input-color__button"}}),i.buttonView.children.add(r),i.buttonView.label=t("Color picker"),i.buttonView.tooltip=!0,i.panelPosition="rtl"===e.uiLanguageDirection?"se":"sw",i.panelView.children.add(n),i.bind("isEnabled").to(this,"isReadOnly",(e=>!e)),i.on("change:isOpen",((e,t,o)=>{o&&(n.updateSelectedColors(),n.showColorGridsFragment())})),i}_createInputTextView(){const e=this.locale,t=new Gp(e);return t.extendTemplate({on:{blur:t.bindTemplate.to("blur")}}),t.value=this.value,t.bind("isReadOnly","hasError").to(this),this.bind("isFocused","isEmpty").to(t),t.on("input",(()=>{const e=t.element.value,o=this.options.colorDefinitions.find((t=>e===t.label));this._stillTyping=!0,this.value=o&&o.color||e})),t.on("blur",(()=>{this._stillTyping=!1,this._setInputValue(t.element.value)})),t.delegate("input").to(this),t}_createColorSelector(e){const t=e.t,o=this.options.defaultColorValue||"",n=t(o?"Restore default":"Remove color"),i=new xf(e,{colors:this.options.colorDefinitions,columns:this.options.columns,removeButtonLabel:n,colorPickerLabel:t("Color picker"),colorPickerViewConfig:!1!==this.options.colorPickerConfig&&{...this.options.colorPickerConfig,hideInput:!0}});i.appendUI(),i.on("execute",((e,t)=>{"colorPickerSaveButton"!==t.source?(this.value=t.value||o,this.fire("input"),"colorPicker"!==t.source&&(this.dropdownView.isOpen=!1)):this.dropdownView.isOpen=!1}));let r=this.value;return i.on("colorPicker:cancel",(()=>{this.value=r,this.fire("input"),this.dropdownView.isOpen=!1})),i.colorGridsFragmentView.colorPickerButtonView.on("execute",(()=>{r=this.value})),i.bind("selectedColor").to(this,"value"),i}_setInputValue(e){if(!this._stillTyping){const t=yB(e),o=this.options.colorDefinitions.find((e=>t===yB(e.color)));this.inputView.value=o?o.label:e||""}}}function yB(e){return e.replace(/([(,])\s+/g,"$1").replace(/^\s+|\s+(?=[),\s]|$)/g,"").replace(/,|\s/g," ")}const AB=e=>""===e;function CB(e){return{none:e("None"),solid:e("Solid"),dotted:e("Dotted"),dashed:e("Dashed"),double:e("Double"),groove:e("Groove"),ridge:e("Ridge"),inset:e("Inset"),outset:e("Outset")}}function vB(e){return e('The color is invalid. Try "#FF0000" or "rgb(255,0,0)" or "red".')}function xB(e){return e('The value is invalid. Try "10px" or "2em" or simply "2".')}function EB(e){return e=e.trim().toLowerCase(),AB(e)||Ku(e)}function DB(e){return e=e.trim(),AB(e)||FB(e)||Qu(e)||(t=e,Xu.test(t));var t}function BB(e){return e=e.trim(),AB(e)||FB(e)||Qu(e)}function SB(e,t){const o=new Yi,n=CB(e.t);for(const i in n){const r={type:"button",model:new Db({_borderStyleValue:i,label:n[i],role:"menuitemradio",withText:!0})};"none"===i?r.model.bind("isOn").to(e,"borderStyle",(e=>"none"===t?!e:e===i)):r.model.bind("isOn").to(e,"borderStyle",(e=>e===i)),o.add(r)}return o}function TB(e){const{view:t,icons:o,toolbar:n,labels:i,propertyName:r,nameToValue:s,defaultValue:a}=e;for(const e in i){const l=new Em(t.locale);l.set({label:i[e],icon:o[e],tooltip:i[e]});const c=s?s(e):e;l.bind("isOn").to(t,r,(e=>{let t=e;return""===e&&a&&(t=a),c===t})),l.on("execute",(()=>{t[r]=c})),n.items.add(l)}}const IB=[{color:"hsl(0, 0%, 0%)",label:"Black"},{color:"hsl(0, 0%, 30%)",label:"Dim grey"},{color:"hsl(0, 0%, 60%)",label:"Grey"},{color:"hsl(0, 0%, 90%)",label:"Light grey"},{color:"hsl(0, 0%, 100%)",label:"White",hasBorder:!0},{color:"hsl(0, 75%, 60%)",label:"Red"},{color:"hsl(30, 75%, 60%)",label:"Orange"},{color:"hsl(60, 75%, 60%)",label:"Yellow"},{color:"hsl(90, 75%, 60%)",label:"Light green"},{color:"hsl(120, 75%, 60%)",label:"Green"},{color:"hsl(150, 75%, 60%)",label:"Aquamarine"},{color:"hsl(180, 75%, 60%)",label:"Turquoise"},{color:"hsl(210, 75%, 60%)",label:"Light blue"},{color:"hsl(240, 75%, 60%)",label:"Blue"},{color:"hsl(270, 75%, 60%)",label:"Purple"}];function PB(e){return(t,o,n)=>{const i=new _B(t.locale,{colorDefinitions:(r=e.colorConfig,r.map((e=>({color:e.model,label:e.label,options:{hasBorder:e.hasBorder}})))),columns:e.columns,defaultColorValue:e.defaultColorValue,colorPickerConfig:e.colorPickerConfig});var r;return i.inputView.set({id:o,ariaDescribedById:n}),i.bind("isReadOnly").to(t,"isEnabled",(e=>!e)),i.bind("hasError").to(t,"errorText",(e=>!!e)),i.on("input",(()=>{t.errorText=null})),t.bind("isEmpty","isFocused").to(i),i}}function FB(e){const t=parseFloat(e);return!Number.isNaN(t)&&e===String(t)}var MB=i(6016),RB={attributes:{"data-cke":!0}};RB.setAttributes=Ar(),RB.insert=_r().bind(null,"head"),RB.domAPI=kr(),RB.insertStyleElement=vr();fr()(MB.A,RB);MB.A&&MB.A.locals&&MB.A.locals;class zB extends pm{constructor(e,t={}){super(e);const o=this.bindTemplate;this.set("class",t.class||null),this.children=this.createCollection(),t.children&&t.children.forEach((e=>this.children.add(e))),this.set("_role",null),this.set("_ariaLabelledBy",null),t.labelView&&this.set({_role:"group",_ariaLabelledBy:t.labelView.id}),this.setTemplate({tag:"div",attributes:{class:["ck","ck-form__row",o.to("class")],role:o.to("_role"),"aria-labelledby":o.to("_ariaLabelledBy")},children:this.children})}}var VB=i(1806),OB={attributes:{"data-cke":!0}};OB.setAttributes=Ar(),OB.insert=_r().bind(null,"head"),OB.domAPI=kr(),OB.insertStyleElement=vr();fr()(VB.A,OB);VB.A&&VB.A.locals&&VB.A.locals;var NB=i(5704),LB={attributes:{"data-cke":!0}};LB.setAttributes=Ar(),LB.insert=_r().bind(null,"head"),LB.domAPI=kr(),LB.insertStyleElement=vr();fr()(NB.A,LB);NB.A&&NB.A.locals&&NB.A.locals;var HB=i(6701),jB={attributes:{"data-cke":!0}};jB.setAttributes=Ar(),jB.insert=_r().bind(null,"head"),jB.domAPI=kr(),jB.insertStyleElement=vr();fr()(HB.A,jB);HB.A&&HB.A.locals&&HB.A.locals;class qB extends pm{constructor(e,t){super(e),this.set({borderStyle:"",borderWidth:"",borderColor:"",padding:"",backgroundColor:"",width:"",height:"",horizontalAlignment:"",verticalAlignment:""}),this.options=t;const{borderStyleDropdown:o,borderWidthInput:n,borderColorInput:i,borderRowLabel:r}=this._createBorderFields(),{backgroundRowLabel:s,backgroundInput:a}=this._createBackgroundFields(),{widthInput:l,operatorLabel:c,heightInput:d,dimensionsLabel:u}=this._createDimensionFields(),{horizontalAlignmentToolbar:h,verticalAlignmentToolbar:m,alignmentLabel:p}=this._createAlignmentFields();this.focusTracker=new Xi,this.keystrokes=new er,this.children=this.createCollection(),this.borderStyleDropdown=o,this.borderWidthInput=n,this.borderColorInput=i,this.backgroundInput=a,this.paddingInput=this._createPaddingField(),this.widthInput=l,this.heightInput=d,this.horizontalAlignmentToolbar=h,this.verticalAlignmentToolbar=m;const{saveButtonView:g,cancelButtonView:f}=this._createActionButtons();this.saveButtonView=g,this.cancelButtonView=f,this._focusables=new Uh,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.children.add(new Tm(e,{label:this.t("Cell properties")})),this.children.add(new zB(e,{labelView:r,children:[r,o,i,n],class:"ck-table-form__border-row"})),this.children.add(new zB(e,{labelView:s,children:[s,a],class:"ck-table-form__background-row"})),this.children.add(new zB(e,{children:[new zB(e,{labelView:u,children:[u,l,c,d],class:"ck-table-form__dimensions-row"}),new zB(e,{children:[this.paddingInput],class:"ck-table-cell-properties-form__padding-row"})]})),this.children.add(new zB(e,{labelView:p,children:[p,h,m],class:"ck-table-cell-properties-form__alignment-row"})),this.children.add(new zB(e,{children:[this.saveButtonView,this.cancelButtonView],class:"ck-table-form__action-row"})),this.setTemplate({tag:"form",attributes:{class:["ck","ck-form","ck-table-form","ck-table-cell-properties-form"],tabindex:"-1"},children:this.children})}render(){super.render(),bm({view:this}),[this.borderColorInput,this.backgroundInput].forEach((e=>{this._focusCycler.chain(e.fieldView.focusCycler)})),[this.borderStyleDropdown,this.borderColorInput,this.borderWidthInput,this.backgroundInput,this.widthInput,this.heightInput,this.paddingInput,this.horizontalAlignmentToolbar,this.verticalAlignmentToolbar,this.saveButtonView,this.cancelButtonView].forEach((e=>{this._focusables.add(e),this.focusTracker.add(e.element)})),this.keystrokes.listenTo(this.element)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this._focusCycler.focusFirst()}_createBorderFields(){const e=this.options.defaultTableCellProperties,t={style:e.borderStyle,width:e.borderWidth,color:e.borderColor},o=PB({colorConfig:this.options.borderColors,columns:5,defaultColorValue:t.color,colorPickerConfig:this.options.colorPickerConfig}),n=this.locale,i=this.t,r=i("Style"),s=new ap(n);s.text=i("Border");const a=CB(i),l=new jp(n,Rg);l.set({label:r,class:"ck-table-form__border-style"}),l.fieldView.buttonView.set({ariaLabel:r,ariaLabelledBy:void 0,isOn:!1,withText:!0,tooltip:r}),l.fieldView.buttonView.bind("label").to(this,"borderStyle",(e=>a[e||"none"])),l.fieldView.on("execute",(e=>{this.borderStyle=e.source._borderStyleValue})),l.bind("isEmpty").to(this,"borderStyle",(e=>!e)),Sg(l.fieldView,SB(this,t.style),{role:"menu",ariaLabel:r});const c=new jp(n,Fg);c.set({label:i("Width"),class:"ck-table-form__border-width"}),c.fieldView.bind("value").to(this,"borderWidth"),c.bind("isEnabled").to(this,"borderStyle",UB),c.fieldView.on("input",(()=>{this.borderWidth=c.fieldView.element.value}));const d=new jp(n,o);return d.set({label:i("Color"),class:"ck-table-form__border-color"}),d.fieldView.bind("value").to(this,"borderColor"),d.bind("isEnabled").to(this,"borderStyle",UB),d.fieldView.on("input",(()=>{this.borderColor=d.fieldView.value})),this.on("change:borderStyle",((e,o,n,i)=>{UB(n)||(this.borderColor="",this.borderWidth=""),UB(i)||(this.borderColor=t.color,this.borderWidth=t.width)})),{borderRowLabel:s,borderStyleDropdown:l,borderColorInput:d,borderWidthInput:c}}_createBackgroundFields(){const e=this.locale,t=this.t,o=new ap(e);o.text=t("Background");const n=PB({colorConfig:this.options.backgroundColors,columns:5,defaultColorValue:this.options.defaultTableCellProperties.backgroundColor,colorPickerConfig:this.options.colorPickerConfig}),i=new jp(e,n);return i.set({label:t("Color"),class:"ck-table-cell-properties-form__background"}),i.fieldView.bind("value").to(this,"backgroundColor"),i.fieldView.on("input",(()=>{this.backgroundColor=i.fieldView.value})),{backgroundRowLabel:o,backgroundInput:i}}_createDimensionFields(){const e=this.locale,t=this.t,o=new ap(e);o.text=t("Dimensions");const n=new jp(e,Fg);n.set({label:t("Width"),class:"ck-table-form__dimensions-row__width"}),n.fieldView.bind("value").to(this,"width"),n.fieldView.on("input",(()=>{this.width=n.fieldView.element.value}));const i=new pm(e);i.setTemplate({tag:"span",attributes:{class:["ck-table-form__dimension-operator"]},children:[{text:"×"}]});const r=new jp(e,Fg);return r.set({label:t("Height"),class:"ck-table-form__dimensions-row__height"}),r.fieldView.bind("value").to(this,"height"),r.fieldView.on("input",(()=>{this.height=r.fieldView.element.value})),{dimensionsLabel:o,widthInput:n,operatorLabel:i,heightInput:r}}_createPaddingField(){const e=this.locale,t=this.t,o=new jp(e,Fg);return o.set({label:t("Padding"),class:"ck-table-cell-properties-form__padding"}),o.fieldView.bind("value").to(this,"padding"),o.fieldView.on("input",(()=>{this.padding=o.fieldView.element.value})),o}_createAlignmentFields(){const e=this.locale,t=this.t,o=new ap(e),n={left:qh.alignLeft,center:qh.alignCenter,right:qh.alignRight,justify:qh.alignJustify,top:qh.alignTop,middle:qh.alignMiddle,bottom:qh.alignBottom};o.text=t("Table cell text alignment");const i=new cg(e),r="rtl"===e.contentLanguageDirection;i.set({isCompact:!0,ariaLabel:t("Horizontal text alignment toolbar")}),TB({view:this,icons:n,toolbar:i,labels:this._horizontalAlignmentLabels,propertyName:"horizontalAlignment",nameToValue:e=>{if(r){if("left"===e)return"right";if("right"===e)return"left"}return e},defaultValue:this.options.defaultTableCellProperties.horizontalAlignment});const s=new cg(e);return s.set({isCompact:!0,ariaLabel:t("Vertical text alignment toolbar")}),TB({view:this,icons:n,toolbar:s,labels:this._verticalAlignmentLabels,propertyName:"verticalAlignment",defaultValue:this.options.defaultTableCellProperties.verticalAlignment}),{horizontalAlignmentToolbar:i,verticalAlignmentToolbar:s,alignmentLabel:o}}_createActionButtons(){const e=this.locale,t=this.t,o=new Em(e),n=new Em(e),i=[this.borderWidthInput,this.borderColorInput,this.backgroundInput,this.paddingInput];return o.set({label:t("Save"),icon:qh.check,class:"ck-button-save",type:"submit",withText:!0}),o.bind("isEnabled").toMany(i,"errorText",((...e)=>e.every((e=>!e)))),n.set({label:t("Cancel"),icon:qh.cancel,class:"ck-button-cancel",withText:!0}),n.delegate("execute").to(this,"cancel"),{saveButtonView:o,cancelButtonView:n}}get _horizontalAlignmentLabels(){const e=this.locale,t=this.t,o=t("Align cell text to the left"),n=t("Align cell text to the center"),i=t("Align cell text to the right"),r=t("Justify cell text");return"rtl"===e.uiLanguageDirection?{right:i,center:n,left:o,justify:r}:{left:o,center:n,right:i,justify:r}}get _verticalAlignmentLabels(){const e=this.t;return{top:e("Align cell text to the top"),middle:e("Align cell text to the middle"),bottom:e("Align cell text to the bottom")}}}function UB(e){return"none"!==e}const WB=(()=>[Ff.defaultPositions.northArrowSouth,Ff.defaultPositions.northArrowSouthWest,Ff.defaultPositions.northArrowSouthEast,Ff.defaultPositions.southArrowNorth,Ff.defaultPositions.southArrowNorthWest,Ff.defaultPositions.southArrowNorthEast,Ff.defaultPositions.viewportStickyNorth])();function $B(e,t){const o=e.plugins.get("ContextualBalloon"),n=e.editing.view.document.selection;let i;"cell"===t?fB(n)&&(i=KB(e)):pB(n)&&(i=GB(e)),i&&o.updatePosition(i)}function GB(e){const t=$E(e.model.document.selection),o=e.editing.mapper.toViewElement(t);return{target:e.editing.view.domConverter.mapViewToDom(o),positions:WB}}function KB(e){const t=e.editing.mapper,o=e.editing.view.domConverter,n=e.model.document.selection;if(n.rangeCount>1)return{target:()=>function(e,t){const o=t.editing.mapper,n=t.editing.view.domConverter,i=Array.from(e).map((e=>{const t=ZB(e.start),i=o.toViewElement(t);return new qn(n.mapViewToDom(i))}));return qn.getBoundingRect(i)}(n.getRanges(),e),positions:WB};const i=ZB(n.getFirstPosition()),r=t.toViewElement(i);return{target:o.mapViewToDom(r),positions:WB}}function ZB(e){return e.nodeAfter&&e.nodeAfter.is("element","tableCell")?e.nodeAfter:e.findAncestor("tableCell")}function JB(e){if(!e||!U(e))return e;const{top:t,right:o,bottom:n,left:i}=e;return t==o&&o==n&&n==i?t:void 0}function YB(e,t){const o=parseFloat(e);return Number.isNaN(o)||String(o)!==String(e)?e:`${o}${t}`}function QB(e,t={}){const o={borderStyle:"none",borderWidth:"",borderColor:"",backgroundColor:"",width:"",height:"",...e};return t.includeAlignmentProperty&&!o.alignment&&(o.alignment="center"),t.includePaddingProperty&&!o.padding&&(o.padding=""),t.includeVerticalAlignmentProperty&&!o.verticalAlignment&&(o.verticalAlignment="middle"),t.includeHorizontalAlignmentProperty&&!o.horizontalAlignment&&(o.horizontalAlignment=t.isRightToLeftContent?"right":"left"),o}const XB={borderStyle:"tableCellBorderStyle",borderColor:"tableCellBorderColor",borderWidth:"tableCellBorderWidth",height:"tableCellHeight",width:"tableCellWidth",padding:"tableCellPadding",backgroundColor:"tableCellBackgroundColor",horizontalAlignment:"tableCellHorizontalAlignment",verticalAlignment:"tableCellVerticalAlignment"};class eS extends lr{static get requires(){return[Fb]}static get pluginName(){return"TableCellPropertiesUI"}constructor(e){super(e),e.config.define("table.tableCellProperties",{borderColors:IB,backgroundColors:IB})}init(){const e=this.editor,t=e.t;this._defaultTableCellProperties=QB(e.config.get("table.tableCellProperties.defaultProperties"),{includeVerticalAlignmentProperty:!0,includeHorizontalAlignmentProperty:!0,includePaddingProperty:!0,isRightToLeftContent:"rtl"===e.locale.contentLanguageDirection}),this._balloon=e.plugins.get(Fb),this.view=null,this._isReady=!1,e.ui.componentFactory.add("tableCellProperties",(o=>{const n=new Em(o);n.set({label:t("Cell properties"),icon:'',tooltip:!0}),this.listenTo(n,"execute",(()=>this._showView()));const i=Object.values(XB).map((t=>e.commands.get(t)));return n.bind("isEnabled").toMany(i,"isEnabled",((...e)=>e.some((e=>e)))),n}))}destroy(){super.destroy(),this.view&&this.view.destroy()}_createPropertiesView(){const e=this.editor,t=e.config.get("table.tableCellProperties"),o=Dp(t.borderColors),n=Ep(e.locale,o),i=Dp(t.backgroundColors),r=Ep(e.locale,i),s=!1!==t.colorPicker,a=new qB(e.locale,{borderColors:n,backgroundColors:r,defaultTableCellProperties:this._defaultTableCellProperties,colorPickerConfig:!!s&&(t.colorPicker||{})}),l=e.t;a.render(),this.listenTo(a,"submit",(()=>{this._hideView()})),this.listenTo(a,"cancel",(()=>{this._undoStepBatch.operations.length&&e.execute("undo",this._undoStepBatch),this._hideView()})),a.keystrokes.set("Esc",((e,t)=>{this._hideView(),t()})),gm({emitter:a,activator:()=>this._isViewInBalloon,contextElements:[this._balloon.view.element],callback:()=>this._hideView()});const c=vB(l),d=xB(l);return a.on("change:borderStyle",this._getPropertyChangeCallback("tableCellBorderStyle")),a.on("change:borderColor",this._getValidatedPropertyChangeCallback({viewField:a.borderColorInput,commandName:"tableCellBorderColor",errorText:c,validator:EB})),a.on("change:borderWidth",this._getValidatedPropertyChangeCallback({viewField:a.borderWidthInput,commandName:"tableCellBorderWidth",errorText:d,validator:BB})),a.on("change:padding",this._getValidatedPropertyChangeCallback({viewField:a.paddingInput,commandName:"tableCellPadding",errorText:d,validator:DB})),a.on("change:width",this._getValidatedPropertyChangeCallback({viewField:a.widthInput,commandName:"tableCellWidth",errorText:d,validator:DB})),a.on("change:height",this._getValidatedPropertyChangeCallback({viewField:a.heightInput,commandName:"tableCellHeight",errorText:d,validator:DB})),a.on("change:backgroundColor",this._getValidatedPropertyChangeCallback({viewField:a.backgroundInput,commandName:"tableCellBackgroundColor",errorText:c,validator:EB})),a.on("change:horizontalAlignment",this._getPropertyChangeCallback("tableCellHorizontalAlignment")),a.on("change:verticalAlignment",this._getPropertyChangeCallback("tableCellVerticalAlignment")),a}_fillViewFormFromCommandValues(){const e=this.editor.commands,t=e.get("tableCellBorderStyle");Object.entries(XB).map((([t,o])=>{const n=this._defaultTableCellProperties[t]||"";return[t,e.get(o).value||n]})).forEach((([e,o])=>{("borderColor"!==e&&"borderWidth"!==e||"none"!==t.value)&&this.view.set(e,o)})),this._isReady=!0}_showView(){const e=this.editor;this.view||(this.view=this._createPropertiesView()),this.listenTo(e.ui,"update",(()=>{this._updateView()})),this._fillViewFormFromCommandValues(),this._balloon.add({view:this.view,position:KB(e)}),this._undoStepBatch=e.model.createBatch(),this.view.focus()}_hideView(){const e=this.editor;this.stopListening(e.ui,"update"),this._isReady=!1,this.view.saveButtonView.focus(),this._balloon.remove(this.view),this.editor.editing.view.focus()}_updateView(){const e=this.editor;fB(e.editing.view.document.selection)?this._isViewVisible&&$B(e,"cell"):this._hideView()}get _isViewVisible(){return!!this.view&&this._balloon.visibleView===this.view}get _isViewInBalloon(){return!!this.view&&this._balloon.hasView(this.view)}_getPropertyChangeCallback(e){return(t,o,n)=>{this._isReady&&this.editor.execute(e,{value:n,batch:this._undoStepBatch})}}_getValidatedPropertyChangeCallback(e){const{commandName:t,viewField:o,validator:n,errorText:i}=e,r=el((()=>{o.errorText=i}),500);return(e,i,s)=>{r.cancel(),this._isReady&&(n(s)?(this.editor.execute(t,{value:s,batch:this._undoStepBatch}),o.errorText=null):r())}}}class tS extends dr{constructor(e,t,o){super(e),this.attributeName=t,this._defaultValue=o}refresh(){const e=this.editor,t=this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(e.model.document.selection);this.isEnabled=!!t.length,this.value=this._getSingleValue(t)}execute(e={}){const{value:t,batch:o}=e,n=this.editor.model,i=this.editor.plugins.get("TableUtils").getSelectionAffectedTableCells(n.document.selection),r=this._getValueToSet(t);n.enqueueChange(o,(e=>{r?i.forEach((t=>e.setAttribute(this.attributeName,r,t))):i.forEach((t=>e.removeAttribute(this.attributeName,t)))}))}_getAttribute(e){if(!e)return;const t=e.getAttribute(this.attributeName);return t!==this._defaultValue?t:void 0}_getValueToSet(e){if(e!==this._defaultValue)return e}_getSingleValue(e){const t=this._getAttribute(e[0]);return e.every((e=>this._getAttribute(e)===t))?t:void 0}}class oS extends tS{constructor(e,t){super(e,"tableCellWidth",t)}_getValueToSet(e){if((e=YB(e,"px"))!==this._defaultValue)return e}}class nS extends lr{static get pluginName(){return"TableCellWidthEditing"}static get requires(){return[KD]}init(){const e=this.editor,t=QB(e.config.get("table.tableCellProperties.defaultProperties"));WE(e.model.schema,e.conversion,{modelAttribute:"tableCellWidth",styleName:"width",defaultValue:t.width}),e.commands.add("tableCellWidth",new oS(e,t.width))}}class iS extends tS{constructor(e,t){super(e,"tableCellPadding",t)}_getAttribute(e){if(!e)return;const t=JB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}_getValueToSet(e){const t=YB(e,"px");if(t!==this._defaultValue)return t}}class rS extends tS{constructor(e,t){super(e,"tableCellHeight",t)}_getValueToSet(e){const t=YB(e,"px");if(t!==this._defaultValue)return t}}class sS extends tS{constructor(e,t){super(e,"tableCellBackgroundColor",t)}}class aS extends tS{constructor(e,t){super(e,"tableCellVerticalAlignment",t)}}class lS extends tS{constructor(e,t){super(e,"tableCellHorizontalAlignment",t)}}class cS extends tS{constructor(e,t){super(e,"tableCellBorderStyle",t)}_getAttribute(e){if(!e)return;const t=JB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}}class dS extends tS{constructor(e,t){super(e,"tableCellBorderColor",t)}_getAttribute(e){if(!e)return;const t=JB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}}class uS extends tS{constructor(e,t){super(e,"tableCellBorderWidth",t)}_getAttribute(e){if(!e)return;const t=JB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}_getValueToSet(e){const t=YB(e,"px");if(t!==this._defaultValue)return t}}const hS=/^(top|middle|bottom)$/,mS=/^(left|center|right|justify)$/;class pS extends lr{static get pluginName(){return"TableCellPropertiesEditing"}static get requires(){return[KD,nS]}init(){const e=this.editor,t=e.model.schema,o=e.conversion;e.config.define("table.tableCellProperties.defaultProperties",{});const n=QB(e.config.get("table.tableCellProperties.defaultProperties"),{includeVerticalAlignmentProperty:!0,includeHorizontalAlignmentProperty:!0,includePaddingProperty:!0,isRightToLeftContent:"rtl"===e.locale.contentLanguageDirection});e.data.addStyleProcessorRules(mh),function(e,t,o){const n={width:"tableCellBorderWidth",color:"tableCellBorderColor",style:"tableCellBorderStyle"};e.extend("tableCell",{allowAttributes:Object.values(n)}),OE(t,"td",n,o),OE(t,"th",n,o),NE(t,{modelElement:"tableCell",modelAttribute:n.style,styleName:"border-style"}),NE(t,{modelElement:"tableCell",modelAttribute:n.color,styleName:"border-color"}),NE(t,{modelElement:"tableCell",modelAttribute:n.width,styleName:"border-width"})}(t,o,{color:n.borderColor,style:n.borderStyle,width:n.borderWidth}),e.commands.add("tableCellBorderStyle",new cS(e,n.borderStyle)),e.commands.add("tableCellBorderColor",new dS(e,n.borderColor)),e.commands.add("tableCellBorderWidth",new uS(e,n.borderWidth)),WE(t,o,{modelAttribute:"tableCellHeight",styleName:"height",defaultValue:n.height}),e.commands.add("tableCellHeight",new rS(e,n.height)),e.data.addStyleProcessorRules(Ch),WE(t,o,{modelAttribute:"tableCellPadding",styleName:"padding",reduceBoxSides:!0,defaultValue:n.padding}),e.commands.add("tableCellPadding",new iS(e,n.padding)),e.data.addStyleProcessorRules(hh),WE(t,o,{modelAttribute:"tableCellBackgroundColor",styleName:"background-color",defaultValue:n.backgroundColor}),e.commands.add("tableCellBackgroundColor",new sS(e,n.backgroundColor)),function(e,t,o){e.extend("tableCell",{allowAttributes:["tableCellHorizontalAlignment"]}),t.for("downcast").attributeToAttribute({model:{name:"tableCell",key:"tableCellHorizontalAlignment"},view:e=>({key:"style",value:{"text-align":e}})}),t.for("upcast").attributeToAttribute({view:{name:/^(td|th)$/,styles:{"text-align":mS}},model:{key:"tableCellHorizontalAlignment",value:e=>{const t=e.getStyle("text-align");return t===o?null:t}}}).attributeToAttribute({view:{name:/^(td|th)$/,attributes:{align:mS}},model:{key:"tableCellHorizontalAlignment",value:e=>{const t=e.getAttribute("align");return t===o?null:t}}})}(t,o,n.horizontalAlignment),e.commands.add("tableCellHorizontalAlignment",new lS(e,n.horizontalAlignment)),function(e,t,o){e.extend("tableCell",{allowAttributes:["tableCellVerticalAlignment"]}),t.for("downcast").attributeToAttribute({model:{name:"tableCell",key:"tableCellVerticalAlignment"},view:e=>({key:"style",value:{"vertical-align":e}})}),t.for("upcast").attributeToAttribute({view:{name:/^(td|th)$/,styles:{"vertical-align":hS}},model:{key:"tableCellVerticalAlignment",value:e=>{const t=e.getStyle("vertical-align");return t===o?null:t}}}).attributeToAttribute({view:{name:/^(td|th)$/,attributes:{valign:hS}},model:{key:"tableCellVerticalAlignment",value:e=>{const t=e.getAttribute("valign");return t===o?null:t}}})}(t,o,n.verticalAlignment),e.commands.add("tableCellVerticalAlignment",new aS(e,n.verticalAlignment))}}class gS extends dr{constructor(e,t,o){super(e),this.attributeName=t,this._defaultValue=o}refresh(){const e=$E(this.editor.model.document.selection);this.isEnabled=!!e,this.value=this._getValue(e)}execute(e={}){const t=this.editor.model,o=t.document.selection,{value:n,batch:i}=e,r=$E(o),s=this._getValueToSet(n);t.enqueueChange(i,(e=>{s?e.setAttribute(this.attributeName,s,r):e.removeAttribute(this.attributeName,r)}))}_getValue(e){if(!e)return;const t=e.getAttribute(this.attributeName);return t!==this._defaultValue?t:void 0}_getValueToSet(e){if(e!==this._defaultValue)return e}}class fS extends gS{constructor(e,t){super(e,"tableBackgroundColor",t)}}class bS extends gS{constructor(e,t){super(e,"tableBorderColor",t)}_getValue(e){if(!e)return;const t=JB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}}class kS extends gS{constructor(e,t){super(e,"tableBorderStyle",t)}_getValue(e){if(!e)return;const t=JB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}}class wS extends gS{constructor(e,t){super(e,"tableBorderWidth",t)}_getValue(e){if(!e)return;const t=JB(e.getAttribute(this.attributeName));return t!==this._defaultValue?t:void 0}_getValueToSet(e){const t=YB(e,"px");if(t!==this._defaultValue)return t}}class _S extends gS{constructor(e,t){super(e,"tableWidth",t)}_getValueToSet(e){if((e=YB(e,"px"))!==this._defaultValue)return e}}class yS extends gS{constructor(e,t){super(e,"tableHeight",t)}_getValueToSet(e){if((e=YB(e,"px"))!==this._defaultValue)return e}}class AS extends gS{constructor(e,t){super(e,"tableAlignment",t)}}const CS=/^(left|center|right)$/,vS=/^(left|none|right)$/;class xS extends lr{static get pluginName(){return"TablePropertiesEditing"}static get requires(){return[KD]}init(){const e=this.editor,t=e.model.schema,o=e.conversion;e.config.define("table.tableProperties.defaultProperties",{});const n=QB(e.config.get("table.tableProperties.defaultProperties"),{includeAlignmentProperty:!0});e.data.addStyleProcessorRules(mh),function(e,t,o){const n={width:"tableBorderWidth",color:"tableBorderColor",style:"tableBorderStyle"};e.extend("table",{allowAttributes:Object.values(n)}),OE(t,"table",n,o),LE(t,{modelAttribute:n.color,styleName:"border-color"}),LE(t,{modelAttribute:n.style,styleName:"border-style"}),LE(t,{modelAttribute:n.width,styleName:"border-width"})}(t,o,{color:n.borderColor,style:n.borderStyle,width:n.borderWidth}),e.commands.add("tableBorderColor",new bS(e,n.borderColor)),e.commands.add("tableBorderStyle",new kS(e,n.borderStyle)),e.commands.add("tableBorderWidth",new wS(e,n.borderWidth)),function(e,t,o){e.extend("table",{allowAttributes:["tableAlignment"]}),t.for("downcast").attributeToAttribute({model:{name:"table",key:"tableAlignment"},view:e=>({key:"style",value:{float:"center"===e?"none":e}}),converterPriority:"high"}),t.for("upcast").attributeToAttribute({view:{name:/^(table|figure)$/,styles:{float:vS}},model:{key:"tableAlignment",value:e=>{let t=e.getStyle("float");return"none"===t&&(t="center"),t===o?null:t}}}).attributeToAttribute({view:{attributes:{align:CS}},model:{name:"table",key:"tableAlignment",value:e=>{const t=e.getAttribute("align");return t===o?null:t}}})}(t,o,n.alignment),e.commands.add("tableAlignment",new AS(e,n.alignment)),ES(t,o,{modelAttribute:"tableWidth",styleName:"width",defaultValue:n.width}),e.commands.add("tableWidth",new _S(e,n.width)),ES(t,o,{modelAttribute:"tableHeight",styleName:"height",defaultValue:n.height}),e.commands.add("tableHeight",new yS(e,n.height)),e.data.addStyleProcessorRules(hh),function(e,t,o){const{modelAttribute:n}=o;e.extend("table",{allowAttributes:[n]}),VE(t,{viewElement:"table",...o}),LE(t,o)}(t,o,{modelAttribute:"tableBackgroundColor",styleName:"background-color",defaultValue:n.backgroundColor}),e.commands.add("tableBackgroundColor",new fS(e,n.backgroundColor))}}function ES(e,t,o){const{modelAttribute:n}=o;e.extend("table",{allowAttributes:[n]}),VE(t,{viewElement:/^(table|figure)$/,shouldUpcast:e=>!("table"==e.name&&"figure"==e.parent.name),...o}),NE(t,{modelElement:"table",...o})}var DS=i(4001),BS={attributes:{"data-cke":!0}};BS.setAttributes=Ar(),BS.insert=_r().bind(null,"head"),BS.domAPI=kr(),BS.insertStyleElement=vr();fr()(DS.A,BS);DS.A&&DS.A.locals&&DS.A.locals;class SS extends pm{constructor(e,t){super(e),this.set({borderStyle:"",borderWidth:"",borderColor:"",backgroundColor:"",width:"",height:"",alignment:""}),this.options=t;const{borderStyleDropdown:o,borderWidthInput:n,borderColorInput:i,borderRowLabel:r}=this._createBorderFields(),{backgroundRowLabel:s,backgroundInput:a}=this._createBackgroundFields(),{widthInput:l,operatorLabel:c,heightInput:d,dimensionsLabel:u}=this._createDimensionFields(),{alignmentToolbar:h,alignmentLabel:m}=this._createAlignmentFields();this.focusTracker=new Xi,this.keystrokes=new er,this.children=this.createCollection(),this.borderStyleDropdown=o,this.borderWidthInput=n,this.borderColorInput=i,this.backgroundInput=a,this.widthInput=l,this.heightInput=d,this.alignmentToolbar=h;const{saveButtonView:p,cancelButtonView:g}=this._createActionButtons();this.saveButtonView=p,this.cancelButtonView=g,this._focusables=new Uh,this._focusCycler=new Im({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.children.add(new Tm(e,{label:this.t("Table properties")})),this.children.add(new zB(e,{labelView:r,children:[r,o,i,n],class:"ck-table-form__border-row"})),this.children.add(new zB(e,{labelView:s,children:[s,a],class:"ck-table-form__background-row"})),this.children.add(new zB(e,{children:[new zB(e,{labelView:u,children:[u,l,c,d],class:"ck-table-form__dimensions-row"}),new zB(e,{labelView:m,children:[m,h],class:"ck-table-properties-form__alignment-row"})]})),this.children.add(new zB(e,{children:[this.saveButtonView,this.cancelButtonView],class:"ck-table-form__action-row"})),this.setTemplate({tag:"form",attributes:{class:["ck","ck-form","ck-table-form","ck-table-properties-form"],tabindex:"-1"},children:this.children})}render(){super.render(),bm({view:this}),[this.borderColorInput,this.backgroundInput].forEach((e=>{this._focusCycler.chain(e.fieldView.focusCycler)})),[this.borderStyleDropdown,this.borderColorInput,this.borderWidthInput,this.backgroundInput,this.widthInput,this.heightInput,this.alignmentToolbar,this.saveButtonView,this.cancelButtonView].forEach((e=>{this._focusables.add(e),this.focusTracker.add(e.element)})),this.keystrokes.listenTo(this.element)}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}focus(){this._focusCycler.focusFirst()}_createBorderFields(){const e=this.options.defaultTableProperties,t={style:e.borderStyle,width:e.borderWidth,color:e.borderColor},o=PB({colorConfig:this.options.borderColors,columns:5,defaultColorValue:t.color,colorPickerConfig:this.options.colorPickerConfig}),n=this.locale,i=this.t,r=i("Style"),s=new ap(n);s.text=i("Border");const a=CB(i),l=new jp(n,Rg);l.set({label:r,class:"ck-table-form__border-style"}),l.fieldView.buttonView.set({ariaLabel:r,ariaLabelledBy:void 0,isOn:!1,withText:!0,tooltip:r}),l.fieldView.buttonView.bind("label").to(this,"borderStyle",(e=>a[e||"none"])),l.fieldView.on("execute",(e=>{this.borderStyle=e.source._borderStyleValue})),l.bind("isEmpty").to(this,"borderStyle",(e=>!e)),Sg(l.fieldView,SB(this,t.style),{role:"menu",ariaLabel:r});const c=new jp(n,Fg);c.set({label:i("Width"),class:"ck-table-form__border-width"}),c.fieldView.bind("value").to(this,"borderWidth"),c.bind("isEnabled").to(this,"borderStyle",TS),c.fieldView.on("input",(()=>{this.borderWidth=c.fieldView.element.value}));const d=new jp(n,o);return d.set({label:i("Color"),class:"ck-table-form__border-color"}),d.fieldView.bind("value").to(this,"borderColor"),d.bind("isEnabled").to(this,"borderStyle",TS),d.fieldView.on("input",(()=>{this.borderColor=d.fieldView.value})),this.on("change:borderStyle",((e,o,n,i)=>{TS(n)||(this.borderColor="",this.borderWidth=""),TS(i)||(this.borderColor=t.color,this.borderWidth=t.width)})),{borderRowLabel:s,borderStyleDropdown:l,borderColorInput:d,borderWidthInput:c}}_createBackgroundFields(){const e=this.locale,t=this.t,o=new ap(e);o.text=t("Background");const n=PB({colorConfig:this.options.backgroundColors,columns:5,defaultColorValue:this.options.defaultTableProperties.backgroundColor,colorPickerConfig:this.options.colorPickerConfig}),i=new jp(e,n);return i.set({label:t("Color"),class:"ck-table-properties-form__background"}),i.fieldView.bind("value").to(this,"backgroundColor"),i.fieldView.on("input",(()=>{this.backgroundColor=i.fieldView.value})),{backgroundRowLabel:o,backgroundInput:i}}_createDimensionFields(){const e=this.locale,t=this.t,o=new ap(e);o.text=t("Dimensions");const n=new jp(e,Fg);n.set({label:t("Width"),class:"ck-table-form__dimensions-row__width"}),n.fieldView.bind("value").to(this,"width"),n.fieldView.on("input",(()=>{this.width=n.fieldView.element.value}));const i=new pm(e);i.setTemplate({tag:"span",attributes:{class:["ck-table-form__dimension-operator"]},children:[{text:"×"}]});const r=new jp(e,Fg);return r.set({label:t("Height"),class:"ck-table-form__dimensions-row__height"}),r.fieldView.bind("value").to(this,"height"),r.fieldView.on("input",(()=>{this.height=r.fieldView.element.value})),{dimensionsLabel:o,widthInput:n,operatorLabel:i,heightInput:r}}_createAlignmentFields(){const e=this.locale,t=this.t,o=new ap(e);o.text=t("Alignment");const n=new cg(e);return n.set({isCompact:!0,ariaLabel:t("Table alignment toolbar")}),TB({view:this,icons:{left:qh.objectLeft,center:qh.objectCenter,right:qh.objectRight},toolbar:n,labels:this._alignmentLabels,propertyName:"alignment",defaultValue:this.options.defaultTableProperties.alignment}),{alignmentLabel:o,alignmentToolbar:n}}_createActionButtons(){const e=this.locale,t=this.t,o=new Em(e),n=new Em(e),i=[this.borderWidthInput,this.borderColorInput,this.backgroundInput,this.widthInput,this.heightInput];return o.set({label:t("Save"),icon:qh.check,class:"ck-button-save",type:"submit",withText:!0}),o.bind("isEnabled").toMany(i,"errorText",((...e)=>e.every((e=>!e)))),n.set({label:t("Cancel"),icon:qh.cancel,class:"ck-button-cancel",withText:!0}),n.delegate("execute").to(this,"cancel"),{saveButtonView:o,cancelButtonView:n}}get _alignmentLabels(){const e=this.locale,t=this.t,o=t("Align table to the left"),n=t("Center table"),i=t("Align table to the right");return"rtl"===e.uiLanguageDirection?{right:i,center:n,left:o}:{left:o,center:n,right:i}}}function TS(e){return"none"!==e}const IS={borderStyle:"tableBorderStyle",borderColor:"tableBorderColor",borderWidth:"tableBorderWidth",backgroundColor:"tableBackgroundColor",width:"tableWidth",height:"tableHeight",alignment:"tableAlignment"};class PS extends lr{static get requires(){return[Fb]}static get pluginName(){return"TablePropertiesUI"}constructor(e){super(e),this.view=null,e.config.define("table.tableProperties",{borderColors:IB,backgroundColors:IB})}init(){const e=this.editor,t=e.t;this._defaultTableProperties=QB(e.config.get("table.tableProperties.defaultProperties"),{includeAlignmentProperty:!0}),this._balloon=e.plugins.get(Fb),e.ui.componentFactory.add("tableProperties",(o=>{const n=new Em(o);n.set({label:t("Table properties"),icon:'',tooltip:!0}),this.listenTo(n,"execute",(()=>this._showView()));const i=Object.values(IS).map((t=>e.commands.get(t)));return n.bind("isEnabled").toMany(i,"isEnabled",((...e)=>e.some((e=>e)))),n}))}destroy(){super.destroy(),this.view&&this.view.destroy()}_createPropertiesView(){const e=this.editor,t=e.config.get("table.tableProperties"),o=Dp(t.borderColors),n=Ep(e.locale,o),i=Dp(t.backgroundColors),r=Ep(e.locale,i),s=!1!==t.colorPicker,a=new SS(e.locale,{borderColors:n,backgroundColors:r,defaultTableProperties:this._defaultTableProperties,colorPickerConfig:!!s&&(t.colorPicker||{})}),l=e.t;a.render(),this.listenTo(a,"submit",(()=>{this._hideView()})),this.listenTo(a,"cancel",(()=>{this._undoStepBatch.operations.length&&e.execute("undo",this._undoStepBatch),this._hideView()})),a.keystrokes.set("Esc",((e,t)=>{this._hideView(),t()})),gm({emitter:a,activator:()=>this._isViewInBalloon,contextElements:[this._balloon.view.element],callback:()=>this._hideView()});const c=vB(l),d=xB(l);return a.on("change:borderStyle",this._getPropertyChangeCallback("tableBorderStyle")),a.on("change:borderColor",this._getValidatedPropertyChangeCallback({viewField:a.borderColorInput,commandName:"tableBorderColor",errorText:c,validator:EB})),a.on("change:borderWidth",this._getValidatedPropertyChangeCallback({viewField:a.borderWidthInput,commandName:"tableBorderWidth",errorText:d,validator:BB})),a.on("change:backgroundColor",this._getValidatedPropertyChangeCallback({viewField:a.backgroundInput,commandName:"tableBackgroundColor",errorText:c,validator:EB})),a.on("change:width",this._getValidatedPropertyChangeCallback({viewField:a.widthInput,commandName:"tableWidth",errorText:d,validator:DB})),a.on("change:height",this._getValidatedPropertyChangeCallback({viewField:a.heightInput,commandName:"tableHeight",errorText:d,validator:DB})),a.on("change:alignment",this._getPropertyChangeCallback("tableAlignment")),a}_fillViewFormFromCommandValues(){const e=this.editor.commands,t=e.get("tableBorderStyle");Object.entries(IS).map((([t,o])=>{const n=t,i=this._defaultTableProperties[n]||"";return[n,e.get(o).value||i]})).forEach((([e,o])=>{("borderColor"!==e&&"borderWidth"!==e||"none"!==t.value)&&this.view.set(e,o)})),this._isReady=!0}_showView(){const e=this.editor;this.view||(this.view=this._createPropertiesView()),this.listenTo(e.ui,"update",(()=>{this._updateView()})),this._fillViewFormFromCommandValues(),this._balloon.add({view:this.view,position:GB(e)}),this._undoStepBatch=e.model.createBatch(),this.view.focus()}_hideView(){const e=this.editor;this.stopListening(e.ui,"update"),this._isReady=!1,this.view.saveButtonView.focus(),this._balloon.remove(this.view),this.editor.editing.view.focus()}_updateView(){const e=this.editor;pB(e.editing.view.document.selection)?this._isViewVisible&&$B(e,"table"):this._hideView()}get _isViewVisible(){return!!this.view&&this._balloon.visibleView===this.view}get _isViewInBalloon(){return!!this.view&&this._balloon.hasView(this.view)}_getPropertyChangeCallback(e){return(t,o,n)=>{this._isReady&&this.editor.execute(e,{value:n,batch:this._undoStepBatch})}}_getValidatedPropertyChangeCallback(e){const{commandName:t,viewField:o,validator:n,errorText:i}=e,r=el((()=>{o.errorText=i}),500);return(e,i,s)=>{r.cancel(),this._isReady&&(n(s)?(this.editor.execute(t,{value:s,batch:this._undoStepBatch}),o.errorText=null):r())}}}var FS=i(7406),MS={attributes:{"data-cke":!0}};MS.setAttributes=Ar(),MS.insert=_r().bind(null,"head"),MS.domAPI=kr(),MS.insertStyleElement=vr();fr()(FS.A,MS);FS.A&&FS.A.locals&&FS.A.locals;var RS=i(4204),zS={attributes:{"data-cke":!0}};zS.setAttributes=Ar(),zS.insert=_r().bind(null,"head"),zS.domAPI=kr(),zS.insertStyleElement=vr();fr()(RS.A,zS);RS.A&&RS.A.locals&&RS.A.locals;function VS(e){return void 0!==e&&e.endsWith("px")}function OS(e){return e.toFixed(2).replace(/\.?0+$/,"")+"px"}function NS(e,t,o){if(!e.childCount)return;const n=new Lu(e.document),i=function(e,t){const o=t.createRangeIn(e),n=[],i=new Set;for(const e of o.getItems()){if(!e.is("element")||!e.name.match(/^(p|h\d+|li|div)$/))continue;let t=GS(e);if(void 0===t||0!=parseFloat(t)||Array.from(e.getClassNames()).find((e=>e.startsWith("MsoList")))||(t=void 0),e.hasStyle("mso-list")||void 0!==t&&i.has(t)){const o=WS(e);n.push({element:e,id:o.id,order:o.order,indent:o.indent,marginLeft:t}),void 0!==t&&i.add(t)}else i.clear()}return n}(e,n);if(!i.length)return;const r={},s=[];for(const e of i)if(void 0!==e.indent){LS(e)||(s.length=0);const i=`${e.id}:${e.indent}`,a=Math.min(e.indent-1,s.length);if(as.length-1||s[a].listElement.name!=l.type){0==a&&"ol"==l.type&&void 0!==e.id&&r[i]&&(l.startIndex=r[i]);const t=US(l,n,o);if(VS(e.marginLeft)&&(0==a||VS(s[a-1].marginLeft))){let o=e.marginLeft;a>0&&(o=OS(parseFloat(o)-parseFloat(s[a-1].marginLeft))),n.setStyle("padding-left",o,t)}if(0==s.length){const o=e.element.parent,i=o.getChildIndex(e.element)+1;n.insertChild(i,t,o)}else{const e=s[a-1].listItemElements;n.appendChild(t,e[e.length-1])}s[a]={...e,listElement:t,listItemElements:[]},0==a&&void 0!==e.id&&(r[i]=l.startIndex||1)}}const l="li"==e.element.name?e.element:n.createElement("li");n.appendChild(l,s[a].listElement),s[a].listItemElements.push(l),0==a&&void 0!==e.id&&r[i]++,e.element!=l&&n.appendChild(e.element,l),$S(e.element,n),n.removeStyle("text-indent",e.element),n.removeStyle("margin-left",e.element)}else{const t=s.find((t=>t.marginLeft==e.marginLeft));if(t){const o=t.listItemElements;n.appendChild(e.element,o[o.length-1]),n.removeStyle("margin-left",e.element)}else s.length=0}}function LS(e){const t=e.element.previousSibling;return HS(t||e.element.parent)}function HS(e){return e.is("element","ol")||e.is("element","ul")}function jS(e,t){const o=new RegExp(`@list l${e.id}:level${e.indent}\\s*({[^}]*)`,"gi"),n=/mso-level-number-format:([^;]{0,100});/gi,i=/mso-level-start-at:\s{0,100}([0-9]{0,10})\s{0,100};/gi,r=new RegExp(`@list\\s+l${e.id}:level\\d\\s*{[^{]*mso-level-text:"%\\d\\\\.`,"gi"),s=new RegExp(`@list l${e.id}:level\\d\\s*{[^{]*mso-level-number-format:`,"gi"),a=r.exec(t),l=s.exec(t),c=a&&!l,d=o.exec(t);let u="decimal",h="ol",m=null;if(d&&d[1]){const t=n.exec(d[1]);if(t&&t[1]&&(u=t[1].trim(),h="bullet"!==u&&"image"!==u?"ol":"ul"),"bullet"===u){const t=function(e){if("li"==e.name&&"ul"==e.parent.name&&e.parent.hasAttribute("type"))return e.parent.getAttribute("type");const t=function(e){if(e.getChild(0).is("$text"))return null;for(const t of e.getChildren()){if(!t.is("element","span"))continue;const e=t.getChild(0);if(e)return e.is("$text")?e:e.getChild(0)}return null}(e);if(!t)return null;const o=t._data;if("o"===o)return"circle";if("·"===o)return"disc";if("§"===o)return"square";return null}(e.element);t&&(u=t)}else{const e=i.exec(d[1]);e&&e[1]&&(m=parseInt(e[1]))}c&&(h="ol")}return{type:h,startIndex:m,style:qS(u),isLegalStyleList:c}}function qS(e){if(e.startsWith("arabic-leading-zero"))return"decimal-leading-zero";switch(e){case"alpha-upper":return"upper-alpha";case"alpha-lower":return"lower-alpha";case"roman-upper":return"upper-roman";case"roman-lower":return"lower-roman";case"circle":case"disc":case"square":return e;default:return null}}function US(e,t,o){const n=t.createElement(e.type);return e.style&&t.setStyle("list-style-type",e.style,n),e.startIndex&&e.startIndex>1&&t.setAttribute("start",e.startIndex,n),e.isLegalStyleList&&o&&t.addClass("legal-list",n),n}function WS(e){const t=e.getStyle("mso-list");if(void 0===t)return{};const o=t.match(/(^|\s{1,100})l(\d+)/i),n=t.match(/\s{0,100}lfo(\d+)/i),i=t.match(/\s{0,100}level(\d+)/i);return o&&n&&i?{id:o[2],order:n[1],indent:parseInt(i[1])}:{indent:1}}function $S(e,t){const o=new Hr({name:"span",styles:{"mso-list":"Ignore"}}),n=t.createRangeIn(e);for(const e of n)"elementStart"===e.type&&o.match(e.item)&&t.remove(e.item)}function GS(e){const t=e.getStyle("margin-left");return void 0===t||t.endsWith("px")?t:function(e){const t=parseFloat(e);return e.endsWith("pt")?OS(96*t/72):e.endsWith("pc")?OS(12*t*96/72):e.endsWith("in")?OS(96*t):e.endsWith("cm")?OS(96*t/2.54):e.endsWith("mm")?OS(t/10*96/2.54):e}(t)}function KS(e,t){if(!e.childCount)return;const o=new Lu(e.document),n=function(e,t){const o=t.createRangeIn(e),n=new Hr({name:/v:(.+)/}),i=[];for(const e of o){if("elementStart"!=e.type)continue;const t=e.item,o=t.previousSibling,r=o&&o.is("element")?o.name:null,s=["Chart"],a=n.match(t),l=t.getAttribute("o:gfxdata"),c="v:shapetype"===r,d=l&&s.some((e=>t.getAttribute("id").includes(e)));a&&l&&!c&&!d&&i.push(e.item.getAttribute("id"))}return i}(e,o);!function(e,t,o){const n=o.createRangeIn(t),i=new Hr({name:"img"}),r=[];for(const t of n)if(t.item.is("element")&&i.match(t.item)){const o=t.item,n=o.getAttribute("v:shapes")?o.getAttribute("v:shapes").split(" "):[];n.length&&n.every((t=>e.indexOf(t)>-1))?r.push(o):o.getAttribute("src")||r.push(o)}for(const e of r)o.remove(e)}(n,e,o),function(e,t,o){const n=o.createRangeIn(t),i=[];for(const t of n)if("elementStart"==t.type&&t.item.is("element","v:shape")){const o=t.item.getAttribute("id");if(e.includes(o))continue;r(t.item.parent.getChildren(),o)||i.push(t.item)}for(const e of i){const t={src:s(e)};e.hasAttribute("alt")&&(t.alt=e.getAttribute("alt"));const n=o.createElement("img",t);o.insertChild(e.index+1,n,e.parent)}function r(e,t){for(const o of e)if(o.is("element")){if("img"==o.name&&o.getAttribute("v:shapes")==t)return!0;if(r(o.getChildren(),t))return!0}return!1}function s(e){for(const t of e.getChildren())if(t.is("element")&&t.getAttribute("src"))return t.getAttribute("src")}}(n,e,o),function(e,t){const o=t.createRangeIn(e),n=new Hr({name:/v:(.+)/}),i=[];for(const e of o)"elementStart"==e.type&&n.match(e.item)&&i.push(e.item);for(const e of i)t.remove(e)}(e,o);const i=function(e,t){const o=t.createRangeIn(e),n=new Hr({name:"img"}),i=[];for(const e of o)e.item.is("element")&&n.match(e.item)&&e.item.getAttribute("src").startsWith("file://")&&i.push(e.item);return i}(e,o);i.length&&function(e,t,o){if(e.length===t.length)for(let n=0;nString.fromCharCode(parseInt(e,16)))).join(""))}const JS=//i,YS=/xmlns:o="urn:schemas-microsoft-com/i;class QS{constructor(e,t=!1){this.document=e,this.hasMultiLevelListPlugin=t}isActive(e){return JS.test(e)||YS.test(e)}execute(e){const{body:t,stylesString:o}=e._parsedData;NS(t,o,this.hasMultiLevelListPlugin),KS(t,e.dataTransfer.getData("text/rtf")),function(e){const t=[],o=new Lu(e.document);for(const{item:n}of o.createRangeIn(e))if(n.is("element")){for(const e of n.getClassNames())/\bmso/gi.exec(e)&&o.removeClass(e,n);for(const e of n.getStyleNames())/\bmso/gi.exec(e)&&o.removeStyle(e,n);(n.is("element","w:sdt")||n.is("element","w:sdtpr")&&n.isEmpty||n.is("element","o:p")&&n.isEmpty)&&t.push(n)}for(const e of t){const t=e.parent,n=t.getChildIndex(e);o.insertChild(n,e.getChildren(),t),o.remove(e)}}(t),e.content=t}}function XS(e,t,o,{blockElements:n,inlineObjectElements:i}){let r=o.createPositionAt(e,"forward"==t?"after":"before");return r=r.getLastMatchingPosition((({item:e})=>e.is("element")&&!n.includes(e.name)&&!i.includes(e.name)),{direction:t}),"forward"==t?r.nodeAfter:r.nodeBefore}function eT(e,t){return!!e&&e.is("element")&&t.includes(e.name)}const tT=/id=("|')docs-internal-guid-[-0-9a-f]+("|')/i;class oT{constructor(e){this.document=e}isActive(e){return tT.test(e)}execute(e){const t=new Lu(this.document),{body:o}=e._parsedData;!function(e,t){for(const o of e.getChildren())if(o.is("element","b")&&"normal"===o.getStyle("font-weight")){const n=e.getChildIndex(o);t.remove(o),t.insertChild(n,o.getChildren(),e)}}(o,t),function(e,t){for(const o of t.createRangeIn(e)){const e=o.item;if(e.is("element","li")){const o=e.getChild(0);o&&o.is("element","p")&&t.unwrapElement(o)}}}(o,t),function(e,t){const o=new Hs(t.document.stylesProcessor),n=new Pa(o,{renderingMode:"data"}),i=n.blockElements,r=n.inlineObjectElements,s=[];for(const o of t.createRangeIn(e)){const e=o.item;if(e.is("element","br")){const o=XS(e,"forward",t,{blockElements:i,inlineObjectElements:r}),n=XS(e,"backward",t,{blockElements:i,inlineObjectElements:r}),a=eT(o,i);(eT(n,i)||a)&&s.push(e)}}for(const e of s)e.hasClass("Apple-interchange-newline")?t.remove(e):t.replace(e,t.createElement("p"))}(o,t),e.content=o}}const nT=/(\s+)<\/span>/g,((e,t)=>1===t.length?" ":Array(t.length+1).join("  ").substr(0,t.length)))}function sT(e,t){const o=new DOMParser,n=function(e){return rT(rT(e)).replace(/([^\S\r\n]*?)[\r\n]+([^\S\r\n]*<\/span>)/g,"$1$2").replace(/<\/span>/g,"").replace(/()[\r\n]+(<\/span>)/g,"$1 $2").replace(/ <\//g," <\/o:p>/g," ").replace(/( |\u00A0)<\/o:p>/g,"").replace(/>([^\S\r\n]*[\r\n]\s*)<")}(function(e){const t="",o="",n=e.indexOf(t);if(n<0)return e;const i=e.indexOf(o,n+t.length);return e.substring(0,n+t.length)+(i>=0?e.substring(i):"")}(e=(e=e.replace(/';\nconst processing = '<[?][\\\\s\\\\S]*?[?]>';\nconst declaration = ']*>';\nconst cdata = '';\nconst HTML_TAG_RE = new RegExp('^(?:' + open_tag + '|' + close_tag + '|' + comment + '|' + processing + '|' + declaration + '|' + cdata + ')');\nconst HTML_OPEN_CLOSE_TAG_RE = new RegExp('^(?:' + open_tag + '|' + close_tag + ')');\n\n// HTML block\n\n\n// An array of opening and corresponding closing sequences for html tags,\n// last argument defines whether it can terminate a paragraph or not\n//\nconst HTML_SEQUENCES = [[/^<(script|pre|style|textarea)(?=(\\s|>|$))/i, /<\\/(script|pre|style|textarea)>/i, true], [/^/, true], [/^<\\?/, /\\?>/, true], [/^/, true], [/^/, true], [new RegExp('^|$))', 'i'), /^$/, true], [new RegExp(HTML_OPEN_CLOSE_TAG_RE.source + '\\\\s*$'), /^$/, false]];\nfunction html_block(state, startLine, endLine, silent) {\n let pos = state.bMarks[startLine] + state.tShift[startLine];\n let max = state.eMarks[startLine];\n\n // if it's indented more than 3 spaces, it should be a code block\n if (state.sCount[startLine] - state.blkIndent >= 4) {\n return false;\n }\n if (!state.md.options.html) {\n return false;\n }\n if (state.src.charCodeAt(pos) !== 0x3C /* < */) {\n return false;\n }\n let lineText = state.src.slice(pos, max);\n let i = 0;\n for (; i < HTML_SEQUENCES.length; i++) {\n if (HTML_SEQUENCES[i][0].test(lineText)) {\n break;\n }\n }\n if (i === HTML_SEQUENCES.length) {\n return false;\n }\n if (silent) {\n // true if this sequence can be a terminator, false otherwise\n return HTML_SEQUENCES[i][2];\n }\n let nextLine = startLine + 1;\n\n // If we are here - we detected HTML block.\n // Let's roll down till block end.\n if (!HTML_SEQUENCES[i][1].test(lineText)) {\n for (; nextLine < endLine; nextLine++) {\n if (state.sCount[nextLine] < state.blkIndent) {\n break;\n }\n pos = state.bMarks[nextLine] + state.tShift[nextLine];\n max = state.eMarks[nextLine];\n lineText = state.src.slice(pos, max);\n if (HTML_SEQUENCES[i][1].test(lineText)) {\n if (lineText.length !== 0) {\n nextLine++;\n }\n break;\n }\n }\n }\n state.line = nextLine;\n const token = state.push('html_block', '', 0);\n token.map = [startLine, nextLine];\n token.content = state.getLines(startLine, nextLine, state.blkIndent, true);\n return true;\n}\n\n// heading (#, ##, ...)\n\nfunction heading(state, startLine, endLine, silent) {\n let pos = state.bMarks[startLine] + state.tShift[startLine];\n let max = state.eMarks[startLine];\n\n // if it's indented more than 3 spaces, it should be a code block\n if (state.sCount[startLine] - state.blkIndent >= 4) {\n return false;\n }\n let ch = state.src.charCodeAt(pos);\n if (ch !== 0x23 /* # */ || pos >= max) {\n return false;\n }\n\n // count heading level\n let level = 1;\n ch = state.src.charCodeAt(++pos);\n while (ch === 0x23 /* # */ && pos < max && level <= 6) {\n level++;\n ch = state.src.charCodeAt(++pos);\n }\n if (level > 6 || pos < max && !isSpace(ch)) {\n return false;\n }\n if (silent) {\n return true;\n }\n\n // Let's cut tails like ' ### ' from the end of string\n\n max = state.skipSpacesBack(max, pos);\n const tmp = state.skipCharsBack(max, 0x23, pos); // #\n if (tmp > pos && isSpace(state.src.charCodeAt(tmp - 1))) {\n max = tmp;\n }\n state.line = startLine + 1;\n const token_o = state.push('heading_open', 'h' + String(level), 1);\n token_o.markup = '########'.slice(0, level);\n token_o.map = [startLine, state.line];\n const token_i = state.push('inline', '', 0);\n token_i.content = state.src.slice(pos, max).trim();\n token_i.map = [startLine, state.line];\n token_i.children = [];\n const token_c = state.push('heading_close', 'h' + String(level), -1);\n token_c.markup = '########'.slice(0, level);\n return true;\n}\n\n// lheading (---, ===)\n\nfunction lheading(state, startLine, endLine /*, silent */) {\n const terminatorRules = state.md.block.ruler.getRules('paragraph');\n\n // if it's indented more than 3 spaces, it should be a code block\n if (state.sCount[startLine] - state.blkIndent >= 4) {\n return false;\n }\n const oldParentType = state.parentType;\n state.parentType = 'paragraph'; // use paragraph to match terminatorRules\n\n // jump line-by-line until empty one or EOF\n let level = 0;\n let marker;\n let nextLine = startLine + 1;\n for (; nextLine < endLine && !state.isEmpty(nextLine); nextLine++) {\n // this would be a code block normally, but after paragraph\n // it's considered a lazy continuation regardless of what's there\n if (state.sCount[nextLine] - state.blkIndent > 3) {\n continue;\n }\n\n //\n // Check for underline in setext header\n //\n if (state.sCount[nextLine] >= state.blkIndent) {\n let pos = state.bMarks[nextLine] + state.tShift[nextLine];\n const max = state.eMarks[nextLine];\n if (pos < max) {\n marker = state.src.charCodeAt(pos);\n if (marker === 0x2D /* - */ || marker === 0x3D /* = */) {\n pos = state.skipChars(pos, marker);\n pos = state.skipSpaces(pos);\n if (pos >= max) {\n level = marker === 0x3D /* = */ ? 1 : 2;\n break;\n }\n }\n }\n }\n\n // quirk for blockquotes, this line should already be checked by that rule\n if (state.sCount[nextLine] < 0) {\n continue;\n }\n\n // Some tags can terminate paragraph without empty line.\n let terminate = false;\n for (let i = 0, l = terminatorRules.length; i < l; i++) {\n if (terminatorRules[i](state, nextLine, endLine, true)) {\n terminate = true;\n break;\n }\n }\n if (terminate) {\n break;\n }\n }\n if (!level) {\n // Didn't find valid underline\n return false;\n }\n const content = state.getLines(startLine, nextLine, state.blkIndent, false).trim();\n state.line = nextLine + 1;\n const token_o = state.push('heading_open', 'h' + String(level), 1);\n token_o.markup = String.fromCharCode(marker);\n token_o.map = [startLine, state.line];\n const token_i = state.push('inline', '', 0);\n token_i.content = content;\n token_i.map = [startLine, state.line - 1];\n token_i.children = [];\n const token_c = state.push('heading_close', 'h' + String(level), -1);\n token_c.markup = String.fromCharCode(marker);\n state.parentType = oldParentType;\n return true;\n}\n\n// Paragraph\n\nfunction paragraph(state, startLine, endLine) {\n const terminatorRules = state.md.block.ruler.getRules('paragraph');\n const oldParentType = state.parentType;\n let nextLine = startLine + 1;\n state.parentType = 'paragraph';\n\n // jump line-by-line until empty one or EOF\n for (; nextLine < endLine && !state.isEmpty(nextLine); nextLine++) {\n // this would be a code block normally, but after paragraph\n // it's considered a lazy continuation regardless of what's there\n if (state.sCount[nextLine] - state.blkIndent > 3) {\n continue;\n }\n\n // quirk for blockquotes, this line should already be checked by that rule\n if (state.sCount[nextLine] < 0) {\n continue;\n }\n\n // Some tags can terminate paragraph without empty line.\n let terminate = false;\n for (let i = 0, l = terminatorRules.length; i < l; i++) {\n if (terminatorRules[i](state, nextLine, endLine, true)) {\n terminate = true;\n break;\n }\n }\n if (terminate) {\n break;\n }\n }\n const content = state.getLines(startLine, nextLine, state.blkIndent, false).trim();\n state.line = nextLine;\n const token_o = state.push('paragraph_open', 'p', 1);\n token_o.map = [startLine, state.line];\n const token_i = state.push('inline', '', 0);\n token_i.content = content;\n token_i.map = [startLine, state.line];\n token_i.children = [];\n state.push('paragraph_close', 'p', -1);\n state.parentType = oldParentType;\n return true;\n}\n\n/** internal\n * class ParserBlock\n *\n * Block-level tokenizer.\n **/\n\nconst _rules$1 = [\n// First 2 params - rule name & source. Secondary array - list of rules,\n// which can be terminated by this one.\n['table', table, ['paragraph', 'reference']], ['code', code], ['fence', fence, ['paragraph', 'reference', 'blockquote', 'list']], ['blockquote', blockquote, ['paragraph', 'reference', 'blockquote', 'list']], ['hr', hr, ['paragraph', 'reference', 'blockquote', 'list']], ['list', list, ['paragraph', 'reference', 'blockquote']], ['reference', reference], ['html_block', html_block, ['paragraph', 'reference', 'blockquote']], ['heading', heading, ['paragraph', 'reference', 'blockquote']], ['lheading', lheading], ['paragraph', paragraph]];\n\n/**\n * new ParserBlock()\n **/\nfunction ParserBlock() {\n /**\n * ParserBlock#ruler -> Ruler\n *\n * [[Ruler]] instance. Keep configuration of block rules.\n **/\n this.ruler = new Ruler();\n for (let i = 0; i < _rules$1.length; i++) {\n this.ruler.push(_rules$1[i][0], _rules$1[i][1], {\n alt: (_rules$1[i][2] || []).slice()\n });\n }\n}\n\n// Generate tokens for input range\n//\nParserBlock.prototype.tokenize = function (state, startLine, endLine) {\n const rules = this.ruler.getRules('');\n const len = rules.length;\n const maxNesting = state.md.options.maxNesting;\n let line = startLine;\n let hasEmptyLines = false;\n while (line < endLine) {\n state.line = line = state.skipEmptyLines(line);\n if (line >= endLine) {\n break;\n }\n\n // Termination condition for nested calls.\n // Nested calls currently used for blockquotes & lists\n if (state.sCount[line] < state.blkIndent) {\n break;\n }\n\n // If nesting level exceeded - skip tail to the end. That's not ordinary\n // situation and we should not care about content.\n if (state.level >= maxNesting) {\n state.line = endLine;\n break;\n }\n\n // Try all possible rules.\n // On success, rule should:\n //\n // - update `state.line`\n // - update `state.tokens`\n // - return true\n const prevLine = state.line;\n let ok = false;\n for (let i = 0; i < len; i++) {\n ok = rules[i](state, line, endLine, false);\n if (ok) {\n if (prevLine >= state.line) {\n throw new Error(\"block rule didn't increment state.line\");\n }\n break;\n }\n }\n\n // this can only happen if user disables paragraph rule\n if (!ok) throw new Error('none of the block rules matched');\n\n // set state.tight if we had an empty line before current tag\n // i.e. latest empty line should not count\n state.tight = !hasEmptyLines;\n\n // paragraph might \"eat\" one newline after it in nested lists\n if (state.isEmpty(state.line - 1)) {\n hasEmptyLines = true;\n }\n line = state.line;\n if (line < endLine && state.isEmpty(line)) {\n hasEmptyLines = true;\n line++;\n state.line = line;\n }\n }\n};\n\n/**\n * ParserBlock.parse(str, md, env, outTokens)\n *\n * Process input string and push block tokens into `outTokens`\n **/\nParserBlock.prototype.parse = function (src, md, env, outTokens) {\n if (!src) {\n return;\n }\n const state = new this.State(src, md, env, outTokens);\n this.tokenize(state, state.line, state.lineMax);\n};\nParserBlock.prototype.State = StateBlock;\n\n// Inline parser state\n\nfunction StateInline(src, md, env, outTokens) {\n this.src = src;\n this.env = env;\n this.md = md;\n this.tokens = outTokens;\n this.tokens_meta = Array(outTokens.length);\n this.pos = 0;\n this.posMax = this.src.length;\n this.level = 0;\n this.pending = '';\n this.pendingLevel = 0;\n\n // Stores { start: end } pairs. Useful for backtrack\n // optimization of pairs parse (emphasis, strikes).\n this.cache = {};\n\n // List of emphasis-like delimiters for current tag\n this.delimiters = [];\n\n // Stack of delimiter lists for upper level tags\n this._prev_delimiters = [];\n\n // backtick length => last seen position\n this.backticks = {};\n this.backticksScanned = false;\n\n // Counter used to disable inline linkify-it execution\n // inside and markdown links\n this.linkLevel = 0;\n}\n\n// Flush pending text\n//\nStateInline.prototype.pushPending = function () {\n const token = new Token('text', '', 0);\n token.content = this.pending;\n token.level = this.pendingLevel;\n this.tokens.push(token);\n this.pending = '';\n return token;\n};\n\n// Push new token to \"stream\".\n// If pending text exists - flush it as text token\n//\nStateInline.prototype.push = function (type, tag, nesting) {\n if (this.pending) {\n this.pushPending();\n }\n const token = new Token(type, tag, nesting);\n let token_meta = null;\n if (nesting < 0) {\n // closing tag\n this.level--;\n this.delimiters = this._prev_delimiters.pop();\n }\n token.level = this.level;\n if (nesting > 0) {\n // opening tag\n this.level++;\n this._prev_delimiters.push(this.delimiters);\n this.delimiters = [];\n token_meta = {\n delimiters: this.delimiters\n };\n }\n this.pendingLevel = this.level;\n this.tokens.push(token);\n this.tokens_meta.push(token_meta);\n return token;\n};\n\n// Scan a sequence of emphasis-like markers, and determine whether\n// it can start an emphasis sequence or end an emphasis sequence.\n//\n// - start - position to scan from (it should point at a valid marker);\n// - canSplitWord - determine if these markers can be found inside a word\n//\nStateInline.prototype.scanDelims = function (start, canSplitWord) {\n const max = this.posMax;\n const marker = this.src.charCodeAt(start);\n\n // treat beginning of the line as a whitespace\n const lastChar = start > 0 ? this.src.charCodeAt(start - 1) : 0x20;\n let pos = start;\n while (pos < max && this.src.charCodeAt(pos) === marker) {\n pos++;\n }\n const count = pos - start;\n\n // treat end of the line as a whitespace\n const nextChar = pos < max ? this.src.charCodeAt(pos) : 0x20;\n const isLastPunctChar = isMdAsciiPunct(lastChar) || isPunctChar(String.fromCharCode(lastChar));\n const isNextPunctChar = isMdAsciiPunct(nextChar) || isPunctChar(String.fromCharCode(nextChar));\n const isLastWhiteSpace = isWhiteSpace(lastChar);\n const isNextWhiteSpace = isWhiteSpace(nextChar);\n const left_flanking = !isNextWhiteSpace && (!isNextPunctChar || isLastWhiteSpace || isLastPunctChar);\n const right_flanking = !isLastWhiteSpace && (!isLastPunctChar || isNextWhiteSpace || isNextPunctChar);\n const can_open = left_flanking && (canSplitWord || !right_flanking || isLastPunctChar);\n const can_close = right_flanking && (canSplitWord || !left_flanking || isNextPunctChar);\n return {\n can_open,\n can_close,\n length: count\n };\n};\n\n// re-export Token class to use in block rules\nStateInline.prototype.Token = Token;\n\n// Skip text characters for text token, place those to pending buffer\n// and increment current pos\n\n// Rule to skip pure text\n// '{}$%@~+=:' reserved for extentions\n\n// !, \", #, $, %, &, ', (, ), *, +, ,, -, ., /, :, ;, <, =, >, ?, @, [, \\, ], ^, _, `, {, |, }, or ~\n\n// !!!! Don't confuse with \"Markdown ASCII Punctuation\" chars\n// http://spec.commonmark.org/0.15/#ascii-punctuation-character\nfunction isTerminatorChar(ch) {\n switch (ch) {\n case 0x0A /* \\n */:\n case 0x21 /* ! */:\n case 0x23 /* # */:\n case 0x24 /* $ */:\n case 0x25 /* % */:\n case 0x26 /* & */:\n case 0x2A /* * */:\n case 0x2B /* + */:\n case 0x2D /* - */:\n case 0x3A /* : */:\n case 0x3C /* < */:\n case 0x3D /* = */:\n case 0x3E /* > */:\n case 0x40 /* @ */:\n case 0x5B /* [ */:\n case 0x5C /* \\ */:\n case 0x5D /* ] */:\n case 0x5E /* ^ */:\n case 0x5F /* _ */:\n case 0x60 /* ` */:\n case 0x7B /* { */:\n case 0x7D /* } */:\n case 0x7E /* ~ */:\n return true;\n default:\n return false;\n }\n}\nfunction text(state, silent) {\n let pos = state.pos;\n while (pos < state.posMax && !isTerminatorChar(state.src.charCodeAt(pos))) {\n pos++;\n }\n if (pos === state.pos) {\n return false;\n }\n if (!silent) {\n state.pending += state.src.slice(state.pos, pos);\n }\n state.pos = pos;\n return true;\n}\n\n// Alternative implementation, for memory.\n//\n// It costs 10% of performance, but allows extend terminators list, if place it\n// to `ParserInline` property. Probably, will switch to it sometime, such\n// flexibility required.\n\n/*\nvar TERMINATOR_RE = /[\\n!#$%&*+\\-:<=>@[\\\\\\]^_`{}~]/;\n\nmodule.exports = function text(state, silent) {\n var pos = state.pos,\n idx = state.src.slice(pos).search(TERMINATOR_RE);\n\n // first char is terminator -> empty text\n if (idx === 0) { return false; }\n\n // no terminator -> text till end of string\n if (idx < 0) {\n if (!silent) { state.pending += state.src.slice(pos); }\n state.pos = state.src.length;\n return true;\n }\n\n if (!silent) { state.pending += state.src.slice(pos, pos + idx); }\n\n state.pos += idx;\n\n return true;\n}; */\n\n// Process links like https://example.org/\n\n// RFC3986: scheme = ALPHA *( ALPHA / DIGIT / \"+\" / \"-\" / \".\" )\nconst SCHEME_RE = /(?:^|[^a-z0-9.+-])([a-z][a-z0-9.+-]*)$/i;\nfunction linkify(state, silent) {\n if (!state.md.options.linkify) return false;\n if (state.linkLevel > 0) return false;\n const pos = state.pos;\n const max = state.posMax;\n if (pos + 3 > max) return false;\n if (state.src.charCodeAt(pos) !== 0x3A /* : */) return false;\n if (state.src.charCodeAt(pos + 1) !== 0x2F /* / */) return false;\n if (state.src.charCodeAt(pos + 2) !== 0x2F /* / */) return false;\n const match = state.pending.match(SCHEME_RE);\n if (!match) return false;\n const proto = match[1];\n const link = state.md.linkify.matchAtStart(state.src.slice(pos - proto.length));\n if (!link) return false;\n let url = link.url;\n\n // invalid link, but still detected by linkify somehow;\n // need to check to prevent infinite loop below\n if (url.length <= proto.length) return false;\n\n // disallow '*' at the end of the link (conflicts with emphasis)\n url = url.replace(/\\*+$/, '');\n const fullUrl = state.md.normalizeLink(url);\n if (!state.md.validateLink(fullUrl)) return false;\n if (!silent) {\n state.pending = state.pending.slice(0, -proto.length);\n const token_o = state.push('link_open', 'a', 1);\n token_o.attrs = [['href', fullUrl]];\n token_o.markup = 'linkify';\n token_o.info = 'auto';\n const token_t = state.push('text', '', 0);\n token_t.content = state.md.normalizeLinkText(url);\n const token_c = state.push('link_close', 'a', -1);\n token_c.markup = 'linkify';\n token_c.info = 'auto';\n }\n state.pos += url.length - proto.length;\n return true;\n}\n\n// Proceess '\\n'\n\nfunction newline(state, silent) {\n let pos = state.pos;\n if (state.src.charCodeAt(pos) !== 0x0A /* \\n */) {\n return false;\n }\n const pmax = state.pending.length - 1;\n const max = state.posMax;\n\n // ' \\n' -> hardbreak\n // Lookup in pending chars is bad practice! Don't copy to other rules!\n // Pending string is stored in concat mode, indexed lookups will cause\n // convertion to flat mode.\n if (!silent) {\n if (pmax >= 0 && state.pending.charCodeAt(pmax) === 0x20) {\n if (pmax >= 1 && state.pending.charCodeAt(pmax - 1) === 0x20) {\n // Find whitespaces tail of pending chars.\n let ws = pmax - 1;\n while (ws >= 1 && state.pending.charCodeAt(ws - 1) === 0x20) ws--;\n state.pending = state.pending.slice(0, ws);\n state.push('hardbreak', 'br', 0);\n } else {\n state.pending = state.pending.slice(0, -1);\n state.push('softbreak', 'br', 0);\n }\n } else {\n state.push('softbreak', 'br', 0);\n }\n }\n pos++;\n\n // skip heading spaces for next line\n while (pos < max && isSpace(state.src.charCodeAt(pos))) {\n pos++;\n }\n state.pos = pos;\n return true;\n}\n\n// Process escaped chars and hardbreaks\n\nconst ESCAPED = [];\nfor (let i = 0; i < 256; i++) {\n ESCAPED.push(0);\n}\n'\\\\!\"#$%&\\'()*+,./:;<=>?@[]^_`{|}~-'.split('').forEach(function (ch) {\n ESCAPED[ch.charCodeAt(0)] = 1;\n});\nfunction escape(state, silent) {\n let pos = state.pos;\n const max = state.posMax;\n if (state.src.charCodeAt(pos) !== 0x5C /* \\ */) return false;\n pos++;\n\n // '\\' at the end of the inline block\n if (pos >= max) return false;\n let ch1 = state.src.charCodeAt(pos);\n if (ch1 === 0x0A) {\n if (!silent) {\n state.push('hardbreak', 'br', 0);\n }\n pos++;\n // skip leading whitespaces from next line\n while (pos < max) {\n ch1 = state.src.charCodeAt(pos);\n if (!isSpace(ch1)) break;\n pos++;\n }\n state.pos = pos;\n return true;\n }\n let escapedStr = state.src[pos];\n if (ch1 >= 0xD800 && ch1 <= 0xDBFF && pos + 1 < max) {\n const ch2 = state.src.charCodeAt(pos + 1);\n if (ch2 >= 0xDC00 && ch2 <= 0xDFFF) {\n escapedStr += state.src[pos + 1];\n pos++;\n }\n }\n const origStr = '\\\\' + escapedStr;\n if (!silent) {\n const token = state.push('text_special', '', 0);\n if (ch1 < 256 && ESCAPED[ch1] !== 0) {\n token.content = escapedStr;\n } else {\n token.content = origStr;\n }\n token.markup = origStr;\n token.info = 'escape';\n }\n state.pos = pos + 1;\n return true;\n}\n\n// Parse backticks\n\nfunction backtick(state, silent) {\n let pos = state.pos;\n const ch = state.src.charCodeAt(pos);\n if (ch !== 0x60 /* ` */) {\n return false;\n }\n const start = pos;\n pos++;\n const max = state.posMax;\n\n // scan marker length\n while (pos < max && state.src.charCodeAt(pos) === 0x60 /* ` */) {\n pos++;\n }\n const marker = state.src.slice(start, pos);\n const openerLength = marker.length;\n if (state.backticksScanned && (state.backticks[openerLength] || 0) <= start) {\n if (!silent) state.pending += marker;\n state.pos += openerLength;\n return true;\n }\n let matchEnd = pos;\n let matchStart;\n\n // Nothing found in the cache, scan until the end of the line (or until marker is found)\n while ((matchStart = state.src.indexOf('`', matchEnd)) !== -1) {\n matchEnd = matchStart + 1;\n\n // scan marker length\n while (matchEnd < max && state.src.charCodeAt(matchEnd) === 0x60 /* ` */) {\n matchEnd++;\n }\n const closerLength = matchEnd - matchStart;\n if (closerLength === openerLength) {\n // Found matching closer length.\n if (!silent) {\n const token = state.push('code_inline', 'code', 0);\n token.markup = marker;\n token.content = state.src.slice(pos, matchStart).replace(/\\n/g, ' ').replace(/^ (.+) $/, '$1');\n }\n state.pos = matchEnd;\n return true;\n }\n\n // Some different length found, put it in cache as upper limit of where closer can be found\n state.backticks[closerLength] = matchStart;\n }\n\n // Scanned through the end, didn't find anything\n state.backticksScanned = true;\n if (!silent) state.pending += marker;\n state.pos += openerLength;\n return true;\n}\n\n// ~~strike through~~\n//\n\n// Insert each marker as a separate text token, and add it to delimiter list\n//\nfunction strikethrough_tokenize(state, silent) {\n const start = state.pos;\n const marker = state.src.charCodeAt(start);\n if (silent) {\n return false;\n }\n if (marker !== 0x7E /* ~ */) {\n return false;\n }\n const scanned = state.scanDelims(state.pos, true);\n let len = scanned.length;\n const ch = String.fromCharCode(marker);\n if (len < 2) {\n return false;\n }\n let token;\n if (len % 2) {\n token = state.push('text', '', 0);\n token.content = ch;\n len--;\n }\n for (let i = 0; i < len; i += 2) {\n token = state.push('text', '', 0);\n token.content = ch + ch;\n state.delimiters.push({\n marker,\n length: 0,\n // disable \"rule of 3\" length checks meant for emphasis\n token: state.tokens.length - 1,\n end: -1,\n open: scanned.can_open,\n close: scanned.can_close\n });\n }\n state.pos += scanned.length;\n return true;\n}\nfunction postProcess$1(state, delimiters) {\n let token;\n const loneMarkers = [];\n const max = delimiters.length;\n for (let i = 0; i < max; i++) {\n const startDelim = delimiters[i];\n if (startDelim.marker !== 0x7E /* ~ */) {\n continue;\n }\n if (startDelim.end === -1) {\n continue;\n }\n const endDelim = delimiters[startDelim.end];\n token = state.tokens[startDelim.token];\n token.type = 's_open';\n token.tag = 's';\n token.nesting = 1;\n token.markup = '~~';\n token.content = '';\n token = state.tokens[endDelim.token];\n token.type = 's_close';\n token.tag = 's';\n token.nesting = -1;\n token.markup = '~~';\n token.content = '';\n if (state.tokens[endDelim.token - 1].type === 'text' && state.tokens[endDelim.token - 1].content === '~') {\n loneMarkers.push(endDelim.token - 1);\n }\n }\n\n // If a marker sequence has an odd number of characters, it's splitted\n // like this: `~~~~~` -> `~` + `~~` + `~~`, leaving one marker at the\n // start of the sequence.\n //\n // So, we have to move all those markers after subsequent s_close tags.\n //\n while (loneMarkers.length) {\n const i = loneMarkers.pop();\n let j = i + 1;\n while (j < state.tokens.length && state.tokens[j].type === 's_close') {\n j++;\n }\n j--;\n if (i !== j) {\n token = state.tokens[j];\n state.tokens[j] = state.tokens[i];\n state.tokens[i] = token;\n }\n }\n}\n\n// Walk through delimiter list and replace text tokens with tags\n//\nfunction strikethrough_postProcess(state) {\n const tokens_meta = state.tokens_meta;\n const max = state.tokens_meta.length;\n postProcess$1(state, state.delimiters);\n for (let curr = 0; curr < max; curr++) {\n if (tokens_meta[curr] && tokens_meta[curr].delimiters) {\n postProcess$1(state, tokens_meta[curr].delimiters);\n }\n }\n}\nvar r_strikethrough = {\n tokenize: strikethrough_tokenize,\n postProcess: strikethrough_postProcess\n};\n\n// Process *this* and _that_\n//\n\n// Insert each marker as a separate text token, and add it to delimiter list\n//\nfunction emphasis_tokenize(state, silent) {\n const start = state.pos;\n const marker = state.src.charCodeAt(start);\n if (silent) {\n return false;\n }\n if (marker !== 0x5F /* _ */ && marker !== 0x2A /* * */) {\n return false;\n }\n const scanned = state.scanDelims(state.pos, marker === 0x2A);\n for (let i = 0; i < scanned.length; i++) {\n const token = state.push('text', '', 0);\n token.content = String.fromCharCode(marker);\n state.delimiters.push({\n // Char code of the starting marker (number).\n //\n marker,\n // Total length of these series of delimiters.\n //\n length: scanned.length,\n // A position of the token this delimiter corresponds to.\n //\n token: state.tokens.length - 1,\n // If this delimiter is matched as a valid opener, `end` will be\n // equal to its position, otherwise it's `-1`.\n //\n end: -1,\n // Boolean flags that determine if this delimiter could open or close\n // an emphasis.\n //\n open: scanned.can_open,\n close: scanned.can_close\n });\n }\n state.pos += scanned.length;\n return true;\n}\nfunction postProcess(state, delimiters) {\n const max = delimiters.length;\n for (let i = max - 1; i >= 0; i--) {\n const startDelim = delimiters[i];\n if (startDelim.marker !== 0x5F /* _ */ && startDelim.marker !== 0x2A /* * */) {\n continue;\n }\n\n // Process only opening markers\n if (startDelim.end === -1) {\n continue;\n }\n const endDelim = delimiters[startDelim.end];\n\n // If the previous delimiter has the same marker and is adjacent to this one,\n // merge those into one strong delimiter.\n //\n // `whatever` -> `whatever`\n //\n const isStrong = i > 0 && delimiters[i - 1].end === startDelim.end + 1 &&\n // check that first two markers match and adjacent\n delimiters[i - 1].marker === startDelim.marker && delimiters[i - 1].token === startDelim.token - 1 &&\n // check that last two markers are adjacent (we can safely assume they match)\n delimiters[startDelim.end + 1].token === endDelim.token + 1;\n const ch = String.fromCharCode(startDelim.marker);\n const token_o = state.tokens[startDelim.token];\n token_o.type = isStrong ? 'strong_open' : 'em_open';\n token_o.tag = isStrong ? 'strong' : 'em';\n token_o.nesting = 1;\n token_o.markup = isStrong ? ch + ch : ch;\n token_o.content = '';\n const token_c = state.tokens[endDelim.token];\n token_c.type = isStrong ? 'strong_close' : 'em_close';\n token_c.tag = isStrong ? 'strong' : 'em';\n token_c.nesting = -1;\n token_c.markup = isStrong ? ch + ch : ch;\n token_c.content = '';\n if (isStrong) {\n state.tokens[delimiters[i - 1].token].content = '';\n state.tokens[delimiters[startDelim.end + 1].token].content = '';\n i--;\n }\n }\n}\n\n// Walk through delimiter list and replace text tokens with tags\n//\nfunction emphasis_post_process(state) {\n const tokens_meta = state.tokens_meta;\n const max = state.tokens_meta.length;\n postProcess(state, state.delimiters);\n for (let curr = 0; curr < max; curr++) {\n if (tokens_meta[curr] && tokens_meta[curr].delimiters) {\n postProcess(state, tokens_meta[curr].delimiters);\n }\n }\n}\nvar r_emphasis = {\n tokenize: emphasis_tokenize,\n postProcess: emphasis_post_process\n};\n\n// Process [link]( \"stuff\")\n\nfunction link(state, silent) {\n let code, label, res, ref;\n let href = '';\n let title = '';\n let start = state.pos;\n let parseReference = true;\n if (state.src.charCodeAt(state.pos) !== 0x5B /* [ */) {\n return false;\n }\n const oldPos = state.pos;\n const max = state.posMax;\n const labelStart = state.pos + 1;\n const labelEnd = state.md.helpers.parseLinkLabel(state, state.pos, true);\n\n // parser failed to find ']', so it's not a valid link\n if (labelEnd < 0) {\n return false;\n }\n let pos = labelEnd + 1;\n if (pos < max && state.src.charCodeAt(pos) === 0x28 /* ( */) {\n //\n // Inline link\n //\n\n // might have found a valid shortcut link, disable reference parsing\n parseReference = false;\n\n // [link]( \"title\" )\n // ^^ skipping these spaces\n pos++;\n for (; pos < max; pos++) {\n code = state.src.charCodeAt(pos);\n if (!isSpace(code) && code !== 0x0A) {\n break;\n }\n }\n if (pos >= max) {\n return false;\n }\n\n // [link]( \"title\" )\n // ^^^^^^ parsing link destination\n start = pos;\n res = state.md.helpers.parseLinkDestination(state.src, pos, state.posMax);\n if (res.ok) {\n href = state.md.normalizeLink(res.str);\n if (state.md.validateLink(href)) {\n pos = res.pos;\n } else {\n href = '';\n }\n\n // [link]( \"title\" )\n // ^^ skipping these spaces\n start = pos;\n for (; pos < max; pos++) {\n code = state.src.charCodeAt(pos);\n if (!isSpace(code) && code !== 0x0A) {\n break;\n }\n }\n\n // [link]( \"title\" )\n // ^^^^^^^ parsing link title\n res = state.md.helpers.parseLinkTitle(state.src, pos, state.posMax);\n if (pos < max && start !== pos && res.ok) {\n title = res.str;\n pos = res.pos;\n\n // [link]( \"title\" )\n // ^^ skipping these spaces\n for (; pos < max; pos++) {\n code = state.src.charCodeAt(pos);\n if (!isSpace(code) && code !== 0x0A) {\n break;\n }\n }\n }\n }\n if (pos >= max || state.src.charCodeAt(pos) !== 0x29 /* ) */) {\n // parsing a valid shortcut link failed, fallback to reference\n parseReference = true;\n }\n pos++;\n }\n if (parseReference) {\n //\n // Link reference\n //\n if (typeof state.env.references === 'undefined') {\n return false;\n }\n if (pos < max && state.src.charCodeAt(pos) === 0x5B /* [ */) {\n start = pos + 1;\n pos = state.md.helpers.parseLinkLabel(state, pos);\n if (pos >= 0) {\n label = state.src.slice(start, pos++);\n } else {\n pos = labelEnd + 1;\n }\n } else {\n pos = labelEnd + 1;\n }\n\n // covers label === '' and label === undefined\n // (collapsed reference link and shortcut reference link respectively)\n if (!label) {\n label = state.src.slice(labelStart, labelEnd);\n }\n ref = state.env.references[normalizeReference(label)];\n if (!ref) {\n state.pos = oldPos;\n return false;\n }\n href = ref.href;\n title = ref.title;\n }\n\n //\n // We found the end of the link, and know for a fact it's a valid link;\n // so all that's left to do is to call tokenizer.\n //\n if (!silent) {\n state.pos = labelStart;\n state.posMax = labelEnd;\n const token_o = state.push('link_open', 'a', 1);\n const attrs = [['href', href]];\n token_o.attrs = attrs;\n if (title) {\n attrs.push(['title', title]);\n }\n state.linkLevel++;\n state.md.inline.tokenize(state);\n state.linkLevel--;\n state.push('link_close', 'a', -1);\n }\n state.pos = pos;\n state.posMax = max;\n return true;\n}\n\n// Process ![image]( \"title\")\n\nfunction image(state, silent) {\n let code, content, label, pos, ref, res, title, start;\n let href = '';\n const oldPos = state.pos;\n const max = state.posMax;\n if (state.src.charCodeAt(state.pos) !== 0x21 /* ! */) {\n return false;\n }\n if (state.src.charCodeAt(state.pos + 1) !== 0x5B /* [ */) {\n return false;\n }\n const labelStart = state.pos + 2;\n const labelEnd = state.md.helpers.parseLinkLabel(state, state.pos + 1, false);\n\n // parser failed to find ']', so it's not a valid link\n if (labelEnd < 0) {\n return false;\n }\n pos = labelEnd + 1;\n if (pos < max && state.src.charCodeAt(pos) === 0x28 /* ( */) {\n //\n // Inline link\n //\n\n // [link]( \"title\" )\n // ^^ skipping these spaces\n pos++;\n for (; pos < max; pos++) {\n code = state.src.charCodeAt(pos);\n if (!isSpace(code) && code !== 0x0A) {\n break;\n }\n }\n if (pos >= max) {\n return false;\n }\n\n // [link]( \"title\" )\n // ^^^^^^ parsing link destination\n start = pos;\n res = state.md.helpers.parseLinkDestination(state.src, pos, state.posMax);\n if (res.ok) {\n href = state.md.normalizeLink(res.str);\n if (state.md.validateLink(href)) {\n pos = res.pos;\n } else {\n href = '';\n }\n }\n\n // [link]( \"title\" )\n // ^^ skipping these spaces\n start = pos;\n for (; pos < max; pos++) {\n code = state.src.charCodeAt(pos);\n if (!isSpace(code) && code !== 0x0A) {\n break;\n }\n }\n\n // [link]( \"title\" )\n // ^^^^^^^ parsing link title\n res = state.md.helpers.parseLinkTitle(state.src, pos, state.posMax);\n if (pos < max && start !== pos && res.ok) {\n title = res.str;\n pos = res.pos;\n\n // [link]( \"title\" )\n // ^^ skipping these spaces\n for (; pos < max; pos++) {\n code = state.src.charCodeAt(pos);\n if (!isSpace(code) && code !== 0x0A) {\n break;\n }\n }\n } else {\n title = '';\n }\n if (pos >= max || state.src.charCodeAt(pos) !== 0x29 /* ) */) {\n state.pos = oldPos;\n return false;\n }\n pos++;\n } else {\n //\n // Link reference\n //\n if (typeof state.env.references === 'undefined') {\n return false;\n }\n if (pos < max && state.src.charCodeAt(pos) === 0x5B /* [ */) {\n start = pos + 1;\n pos = state.md.helpers.parseLinkLabel(state, pos);\n if (pos >= 0) {\n label = state.src.slice(start, pos++);\n } else {\n pos = labelEnd + 1;\n }\n } else {\n pos = labelEnd + 1;\n }\n\n // covers label === '' and label === undefined\n // (collapsed reference link and shortcut reference link respectively)\n if (!label) {\n label = state.src.slice(labelStart, labelEnd);\n }\n ref = state.env.references[normalizeReference(label)];\n if (!ref) {\n state.pos = oldPos;\n return false;\n }\n href = ref.href;\n title = ref.title;\n }\n\n //\n // We found the end of the link, and know for a fact it's a valid link;\n // so all that's left to do is to call tokenizer.\n //\n if (!silent) {\n content = state.src.slice(labelStart, labelEnd);\n const tokens = [];\n state.md.inline.parse(content, state.md, state.env, tokens);\n const token = state.push('image', 'img', 0);\n const attrs = [['src', href], ['alt', '']];\n token.attrs = attrs;\n token.children = tokens;\n token.content = content;\n if (title) {\n attrs.push(['title', title]);\n }\n }\n state.pos = pos;\n state.posMax = max;\n return true;\n}\n\n// Process autolinks ''\n\n/* eslint max-len:0 */\nconst EMAIL_RE = /^([a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*)$/;\n/* eslint-disable-next-line no-control-regex */\nconst AUTOLINK_RE = /^([a-zA-Z][a-zA-Z0-9+.-]{1,31}):([^<>\\x00-\\x20]*)$/;\nfunction autolink(state, silent) {\n let pos = state.pos;\n if (state.src.charCodeAt(pos) !== 0x3C /* < */) {\n return false;\n }\n const start = state.pos;\n const max = state.posMax;\n for (;;) {\n if (++pos >= max) return false;\n const ch = state.src.charCodeAt(pos);\n if (ch === 0x3C /* < */) return false;\n if (ch === 0x3E /* > */) break;\n }\n const url = state.src.slice(start + 1, pos);\n if (AUTOLINK_RE.test(url)) {\n const fullUrl = state.md.normalizeLink(url);\n if (!state.md.validateLink(fullUrl)) {\n return false;\n }\n if (!silent) {\n const token_o = state.push('link_open', 'a', 1);\n token_o.attrs = [['href', fullUrl]];\n token_o.markup = 'autolink';\n token_o.info = 'auto';\n const token_t = state.push('text', '', 0);\n token_t.content = state.md.normalizeLinkText(url);\n const token_c = state.push('link_close', 'a', -1);\n token_c.markup = 'autolink';\n token_c.info = 'auto';\n }\n state.pos += url.length + 2;\n return true;\n }\n if (EMAIL_RE.test(url)) {\n const fullUrl = state.md.normalizeLink('mailto:' + url);\n if (!state.md.validateLink(fullUrl)) {\n return false;\n }\n if (!silent) {\n const token_o = state.push('link_open', 'a', 1);\n token_o.attrs = [['href', fullUrl]];\n token_o.markup = 'autolink';\n token_o.info = 'auto';\n const token_t = state.push('text', '', 0);\n token_t.content = state.md.normalizeLinkText(url);\n const token_c = state.push('link_close', 'a', -1);\n token_c.markup = 'autolink';\n token_c.info = 'auto';\n }\n state.pos += url.length + 2;\n return true;\n }\n return false;\n}\n\n// Process html tags\n\nfunction isLinkOpen(str) {\n return /^\\s]/i.test(str);\n}\nfunction isLinkClose(str) {\n return /^<\\/a\\s*>/i.test(str);\n}\nfunction isLetter(ch) {\n /* eslint no-bitwise:0 */\n const lc = ch | 0x20; // to lower case\n return lc >= 0x61 /* a */ && lc <= 0x7a /* z */;\n}\nfunction html_inline(state, silent) {\n if (!state.md.options.html) {\n return false;\n }\n\n // Check start\n const max = state.posMax;\n const pos = state.pos;\n if (state.src.charCodeAt(pos) !== 0x3C /* < */ || pos + 2 >= max) {\n return false;\n }\n\n // Quick fail on second char\n const ch = state.src.charCodeAt(pos + 1);\n if (ch !== 0x21 /* ! */ && ch !== 0x3F /* ? */ && ch !== 0x2F /* / */ && !isLetter(ch)) {\n return false;\n }\n const match = state.src.slice(pos).match(HTML_TAG_RE);\n if (!match) {\n return false;\n }\n if (!silent) {\n const token = state.push('html_inline', '', 0);\n token.content = match[0];\n if (isLinkOpen(token.content)) state.linkLevel++;\n if (isLinkClose(token.content)) state.linkLevel--;\n }\n state.pos += match[0].length;\n return true;\n}\n\n// Process html entity - {, ¯, ", ...\n\nconst DIGITAL_RE = /^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i;\nconst NAMED_RE = /^&([a-z][a-z0-9]{1,31});/i;\nfunction entity(state, silent) {\n const pos = state.pos;\n const max = state.posMax;\n if (state.src.charCodeAt(pos) !== 0x26 /* & */) return false;\n if (pos + 1 >= max) return false;\n const ch = state.src.charCodeAt(pos + 1);\n if (ch === 0x23 /* # */) {\n const match = state.src.slice(pos).match(DIGITAL_RE);\n if (match) {\n if (!silent) {\n const code = match[1][0].toLowerCase() === 'x' ? parseInt(match[1].slice(1), 16) : parseInt(match[1], 10);\n const token = state.push('text_special', '', 0);\n token.content = isValidEntityCode(code) ? fromCodePoint(code) : fromCodePoint(0xFFFD);\n token.markup = match[0];\n token.info = 'entity';\n }\n state.pos += match[0].length;\n return true;\n }\n } else {\n const match = state.src.slice(pos).match(NAMED_RE);\n if (match) {\n const decoded = entities.decodeHTML(match[0]);\n if (decoded !== match[0]) {\n if (!silent) {\n const token = state.push('text_special', '', 0);\n token.content = decoded;\n token.markup = match[0];\n token.info = 'entity';\n }\n state.pos += match[0].length;\n return true;\n }\n }\n }\n return false;\n}\n\n// For each opening emphasis-like marker find a matching closing one\n//\n\nfunction processDelimiters(delimiters) {\n const openersBottom = {};\n const max = delimiters.length;\n if (!max) return;\n\n // headerIdx is the first delimiter of the current (where closer is) delimiter run\n let headerIdx = 0;\n let lastTokenIdx = -2; // needs any value lower than -1\n const jumps = [];\n for (let closerIdx = 0; closerIdx < max; closerIdx++) {\n const closer = delimiters[closerIdx];\n jumps.push(0);\n\n // markers belong to same delimiter run if:\n // - they have adjacent tokens\n // - AND markers are the same\n //\n if (delimiters[headerIdx].marker !== closer.marker || lastTokenIdx !== closer.token - 1) {\n headerIdx = closerIdx;\n }\n lastTokenIdx = closer.token;\n\n // Length is only used for emphasis-specific \"rule of 3\",\n // if it's not defined (in strikethrough or 3rd party plugins),\n // we can default it to 0 to disable those checks.\n //\n closer.length = closer.length || 0;\n if (!closer.close) continue;\n\n // Previously calculated lower bounds (previous fails)\n // for each marker, each delimiter length modulo 3,\n // and for whether this closer can be an opener;\n // https://github.com/commonmark/cmark/commit/34250e12ccebdc6372b8b49c44fab57c72443460\n /* eslint-disable-next-line no-prototype-builtins */\n if (!openersBottom.hasOwnProperty(closer.marker)) {\n openersBottom[closer.marker] = [-1, -1, -1, -1, -1, -1];\n }\n const minOpenerIdx = openersBottom[closer.marker][(closer.open ? 3 : 0) + closer.length % 3];\n let openerIdx = headerIdx - jumps[headerIdx] - 1;\n let newMinOpenerIdx = openerIdx;\n for (; openerIdx > minOpenerIdx; openerIdx -= jumps[openerIdx] + 1) {\n const opener = delimiters[openerIdx];\n if (opener.marker !== closer.marker) continue;\n if (opener.open && opener.end < 0) {\n let isOddMatch = false;\n\n // from spec:\n //\n // If one of the delimiters can both open and close emphasis, then the\n // sum of the lengths of the delimiter runs containing the opening and\n // closing delimiters must not be a multiple of 3 unless both lengths\n // are multiples of 3.\n //\n if (opener.close || closer.open) {\n if ((opener.length + closer.length) % 3 === 0) {\n if (opener.length % 3 !== 0 || closer.length % 3 !== 0) {\n isOddMatch = true;\n }\n }\n }\n if (!isOddMatch) {\n // If previous delimiter cannot be an opener, we can safely skip\n // the entire sequence in future checks. This is required to make\n // sure algorithm has linear complexity (see *_*_*_*_*_... case).\n //\n const lastJump = openerIdx > 0 && !delimiters[openerIdx - 1].open ? jumps[openerIdx - 1] + 1 : 0;\n jumps[closerIdx] = closerIdx - openerIdx + lastJump;\n jumps[openerIdx] = lastJump;\n closer.open = false;\n opener.end = closerIdx;\n opener.close = false;\n newMinOpenerIdx = -1;\n // treat next token as start of run,\n // it optimizes skips in **<...>**a**<...>** pathological case\n lastTokenIdx = -2;\n break;\n }\n }\n }\n if (newMinOpenerIdx !== -1) {\n // If match for this delimiter run failed, we want to set lower bound for\n // future lookups. This is required to make sure algorithm has linear\n // complexity.\n //\n // See details here:\n // https://github.com/commonmark/cmark/issues/178#issuecomment-270417442\n //\n openersBottom[closer.marker][(closer.open ? 3 : 0) + (closer.length || 0) % 3] = newMinOpenerIdx;\n }\n }\n}\nfunction link_pairs(state) {\n const tokens_meta = state.tokens_meta;\n const max = state.tokens_meta.length;\n processDelimiters(state.delimiters);\n for (let curr = 0; curr < max; curr++) {\n if (tokens_meta[curr] && tokens_meta[curr].delimiters) {\n processDelimiters(tokens_meta[curr].delimiters);\n }\n }\n}\n\n// Clean up tokens after emphasis and strikethrough postprocessing:\n// merge adjacent text nodes into one and re-calculate all token levels\n//\n// This is necessary because initially emphasis delimiter markers (*, _, ~)\n// are treated as their own separate text tokens. Then emphasis rule either\n// leaves them as text (needed to merge with adjacent text) or turns them\n// into opening/closing tags (which messes up levels inside).\n//\n\nfunction fragments_join(state) {\n let curr, last;\n let level = 0;\n const tokens = state.tokens;\n const max = state.tokens.length;\n for (curr = last = 0; curr < max; curr++) {\n // re-calculate levels after emphasis/strikethrough turns some text nodes\n // into opening/closing tags\n if (tokens[curr].nesting < 0) level--; // closing tag\n tokens[curr].level = level;\n if (tokens[curr].nesting > 0) level++; // opening tag\n\n if (tokens[curr].type === 'text' && curr + 1 < max && tokens[curr + 1].type === 'text') {\n // collapse two adjacent text nodes\n tokens[curr + 1].content = tokens[curr].content + tokens[curr + 1].content;\n } else {\n if (curr !== last) {\n tokens[last] = tokens[curr];\n }\n last++;\n }\n }\n if (curr !== last) {\n tokens.length = last;\n }\n}\n\n/** internal\n * class ParserInline\n *\n * Tokenizes paragraph content.\n **/\n\n\n// Parser rules\n\nconst _rules = [['text', text], ['linkify', linkify], ['newline', newline], ['escape', escape], ['backticks', backtick], ['strikethrough', r_strikethrough.tokenize], ['emphasis', r_emphasis.tokenize], ['link', link], ['image', image], ['autolink', autolink], ['html_inline', html_inline], ['entity', entity]];\n\n// `rule2` ruleset was created specifically for emphasis/strikethrough\n// post-processing and may be changed in the future.\n//\n// Don't use this for anything except pairs (plugins working with `balance_pairs`).\n//\nconst _rules2 = [['balance_pairs', link_pairs], ['strikethrough', r_strikethrough.postProcess], ['emphasis', r_emphasis.postProcess],\n// rules for pairs separate '**' into its own text tokens, which may be left unused,\n// rule below merges unused segments back with the rest of the text\n['fragments_join', fragments_join]];\n\n/**\n * new ParserInline()\n **/\nfunction ParserInline() {\n /**\n * ParserInline#ruler -> Ruler\n *\n * [[Ruler]] instance. Keep configuration of inline rules.\n **/\n this.ruler = new Ruler();\n for (let i = 0; i < _rules.length; i++) {\n this.ruler.push(_rules[i][0], _rules[i][1]);\n }\n\n /**\n * ParserInline#ruler2 -> Ruler\n *\n * [[Ruler]] instance. Second ruler used for post-processing\n * (e.g. in emphasis-like rules).\n **/\n this.ruler2 = new Ruler();\n for (let i = 0; i < _rules2.length; i++) {\n this.ruler2.push(_rules2[i][0], _rules2[i][1]);\n }\n}\n\n// Skip single token by running all rules in validation mode;\n// returns `true` if any rule reported success\n//\nParserInline.prototype.skipToken = function (state) {\n const pos = state.pos;\n const rules = this.ruler.getRules('');\n const len = rules.length;\n const maxNesting = state.md.options.maxNesting;\n const cache = state.cache;\n if (typeof cache[pos] !== 'undefined') {\n state.pos = cache[pos];\n return;\n }\n let ok = false;\n if (state.level < maxNesting) {\n for (let i = 0; i < len; i++) {\n // Increment state.level and decrement it later to limit recursion.\n // It's harmless to do here, because no tokens are created. But ideally,\n // we'd need a separate private state variable for this purpose.\n //\n state.level++;\n ok = rules[i](state, true);\n state.level--;\n if (ok) {\n if (pos >= state.pos) {\n throw new Error(\"inline rule didn't increment state.pos\");\n }\n break;\n }\n }\n } else {\n // Too much nesting, just skip until the end of the paragraph.\n //\n // NOTE: this will cause links to behave incorrectly in the following case,\n // when an amount of `[` is exactly equal to `maxNesting + 1`:\n //\n // [[[[[[[[[[[[[[[[[[[[[foo]()\n //\n // TODO: remove this workaround when CM standard will allow nested links\n // (we can replace it by preventing links from being parsed in\n // validation mode)\n //\n state.pos = state.posMax;\n }\n if (!ok) {\n state.pos++;\n }\n cache[pos] = state.pos;\n};\n\n// Generate tokens for input range\n//\nParserInline.prototype.tokenize = function (state) {\n const rules = this.ruler.getRules('');\n const len = rules.length;\n const end = state.posMax;\n const maxNesting = state.md.options.maxNesting;\n while (state.pos < end) {\n // Try all possible rules.\n // On success, rule should:\n //\n // - update `state.pos`\n // - update `state.tokens`\n // - return true\n const prevPos = state.pos;\n let ok = false;\n if (state.level < maxNesting) {\n for (let i = 0; i < len; i++) {\n ok = rules[i](state, false);\n if (ok) {\n if (prevPos >= state.pos) {\n throw new Error(\"inline rule didn't increment state.pos\");\n }\n break;\n }\n }\n }\n if (ok) {\n if (state.pos >= end) {\n break;\n }\n continue;\n }\n state.pending += state.src[state.pos++];\n }\n if (state.pending) {\n state.pushPending();\n }\n};\n\n/**\n * ParserInline.parse(str, md, env, outTokens)\n *\n * Process input string and push inline tokens into `outTokens`\n **/\nParserInline.prototype.parse = function (str, md, env, outTokens) {\n const state = new this.State(str, md, env, outTokens);\n this.tokenize(state);\n const rules = this.ruler2.getRules('');\n const len = rules.length;\n for (let i = 0; i < len; i++) {\n rules[i](state);\n }\n};\nParserInline.prototype.State = StateInline;\n\n// markdown-it default options\n\nvar cfg_default = {\n options: {\n // Enable HTML tags in source\n html: false,\n // Use '/' to close single tags (
    )\n xhtmlOut: false,\n // Convert '\\n' in paragraphs into
    \n breaks: false,\n // CSS language prefix for fenced blocks\n langPrefix: 'language-',\n // autoconvert URL-like texts to links\n linkify: false,\n // Enable some language-neutral replacements + quotes beautification\n typographer: false,\n // Double + single quotes replacement pairs, when typographer enabled,\n // and smartquotes on. Could be either a String or an Array.\n //\n // For example, you can use '«»„“' for Russian, '„“‚‘' for German,\n // and ['«\\xA0', '\\xA0»', '‹\\xA0', '\\xA0›'] for French (including nbsp).\n quotes: '\\u201c\\u201d\\u2018\\u2019',\n /* “”‘’ */\n\n // Highlighter function. Should return escaped HTML,\n // or '' if the source string is not changed and should be escaped externaly.\n // If result starts with )\n xhtmlOut: false,\n // Convert '\\n' in paragraphs into
    \n breaks: false,\n // CSS language prefix for fenced blocks\n langPrefix: 'language-',\n // autoconvert URL-like texts to links\n linkify: false,\n // Enable some language-neutral replacements + quotes beautification\n typographer: false,\n // Double + single quotes replacement pairs, when typographer enabled,\n // and smartquotes on. Could be either a String or an Array.\n //\n // For example, you can use '«»„“' for Russian, '„“‚‘' for German,\n // and ['«\\xA0', '\\xA0»', '‹\\xA0', '\\xA0›'] for French (including nbsp).\n quotes: '\\u201c\\u201d\\u2018\\u2019',\n /* “”‘’ */\n\n // Highlighter function. Should return escaped HTML,\n // or '' if the source string is not changed and should be escaped externaly.\n // If result starts with )\n xhtmlOut: true,\n // Convert '\\n' in paragraphs into
    \n breaks: false,\n // CSS language prefix for fenced blocks\n langPrefix: 'language-',\n // autoconvert URL-like texts to links\n linkify: false,\n // Enable some language-neutral replacements + quotes beautification\n typographer: false,\n // Double + single quotes replacement pairs, when typographer enabled,\n // and smartquotes on. Could be either a String or an Array.\n //\n // For example, you can use '«»„“' for Russian, '„“‚‘' for German,\n // and ['«\\xA0', '\\xA0»', '‹\\xA0', '\\xA0›'] for French (including nbsp).\n quotes: '\\u201c\\u201d\\u2018\\u2019',\n /* “”‘’ */\n\n // Highlighter function. Should return escaped HTML,\n // or '' if the source string is not changed and should be escaped externaly.\n // If result starts with = 0) {\n try {\n parsed.hostname = punycode.toASCII(parsed.hostname);\n } catch (er) {/**/}\n }\n }\n return mdurl__namespace.encode(mdurl__namespace.format(parsed));\n}\nfunction normalizeLinkText(url) {\n const parsed = mdurl__namespace.parse(url, true);\n if (parsed.hostname) {\n // Encode hostnames in urls like:\n // `http://host/`, `https://host/`, `mailto:user@host`, `//host/`\n //\n // We don't encode unknown schemas, because it's likely that we encode\n // something we shouldn't (e.g. `skype:name` treated as `skype:host`)\n //\n if (!parsed.protocol || RECODE_HOSTNAME_FOR.indexOf(parsed.protocol) >= 0) {\n try {\n parsed.hostname = punycode.toUnicode(parsed.hostname);\n } catch (er) {/**/}\n }\n }\n\n // add '%' to exclude list because of https://github.com/markdown-it/markdown-it/issues/720\n return mdurl__namespace.decode(mdurl__namespace.format(parsed), mdurl__namespace.decode.defaultChars + '%');\n}\n\n/**\n * class MarkdownIt\n *\n * Main parser/renderer class.\n *\n * ##### Usage\n *\n * ```javascript\n * // node.js, \"classic\" way:\n * var MarkdownIt = require('markdown-it'),\n * md = new MarkdownIt();\n * var result = md.render('# markdown-it rulezz!');\n *\n * // node.js, the same, but with sugar:\n * var md = require('markdown-it')();\n * var result = md.render('# markdown-it rulezz!');\n *\n * // browser without AMD, added to \"window\" on script load\n * // Note, there are no dash.\n * var md = window.markdownit();\n * var result = md.render('# markdown-it rulezz!');\n * ```\n *\n * Single line rendering, without paragraph wrap:\n *\n * ```javascript\n * var md = require('markdown-it')();\n * var result = md.renderInline('__markdown-it__ rulezz!');\n * ```\n **/\n\n/**\n * new MarkdownIt([presetName, options])\n * - presetName (String): optional, `commonmark` / `zero`\n * - options (Object)\n *\n * Creates parser instanse with given config. Can be called without `new`.\n *\n * ##### presetName\n *\n * MarkdownIt provides named presets as a convenience to quickly\n * enable/disable active syntax rules and options for common use cases.\n *\n * - [\"commonmark\"](https://github.com/markdown-it/markdown-it/blob/master/lib/presets/commonmark.mjs) -\n * configures parser to strict [CommonMark](http://commonmark.org/) mode.\n * - [default](https://github.com/markdown-it/markdown-it/blob/master/lib/presets/default.mjs) -\n * similar to GFM, used when no preset name given. Enables all available rules,\n * but still without html, typographer & autolinker.\n * - [\"zero\"](https://github.com/markdown-it/markdown-it/blob/master/lib/presets/zero.mjs) -\n * all rules disabled. Useful to quickly setup your config via `.enable()`.\n * For example, when you need only `bold` and `italic` markup and nothing else.\n *\n * ##### options:\n *\n * - __html__ - `false`. Set `true` to enable HTML tags in source. Be careful!\n * That's not safe! You may need external sanitizer to protect output from XSS.\n * It's better to extend features via plugins, instead of enabling HTML.\n * - __xhtmlOut__ - `false`. Set `true` to add '/' when closing single tags\n * (`
    `). This is needed only for full CommonMark compatibility. In real\n * world you will need HTML output.\n * - __breaks__ - `false`. Set `true` to convert `\\n` in paragraphs into `
    `.\n * - __langPrefix__ - `language-`. CSS language class prefix for fenced blocks.\n * Can be useful for external highlighters.\n * - __linkify__ - `false`. Set `true` to autoconvert URL-like text to links.\n * - __typographer__ - `false`. Set `true` to enable [some language-neutral\n * replacement](https://github.com/markdown-it/markdown-it/blob/master/lib/rules_core/replacements.mjs) +\n * quotes beautification (smartquotes).\n * - __quotes__ - `“”‘’`, String or Array. Double + single quotes replacement\n * pairs, when typographer enabled and smartquotes on. For example, you can\n * use `'«»„“'` for Russian, `'„“‚‘'` for German, and\n * `['«\\xA0', '\\xA0»', '‹\\xA0', '\\xA0›']` for French (including nbsp).\n * - __highlight__ - `null`. Highlighter function for fenced code blocks.\n * Highlighter `function (str, lang)` should return escaped HTML. It can also\n * return empty string if the source was not changed and should be escaped\n * externaly. If result starts with ` or ``):\n *\n * ```javascript\n * var hljs = require('highlight.js') // https://highlightjs.org/\n *\n * // Actual default values\n * var md = require('markdown-it')({\n * highlight: function (str, lang) {\n * if (lang && hljs.getLanguage(lang)) {\n * try {\n * return '
    ' +\n *                hljs.highlight(str, { language: lang, ignoreIllegals: true }).value +\n *                '
    ';\n * } catch (__) {}\n * }\n *\n * return '
    ' + md.utils.escapeHtml(str) + '
    ';\n * }\n * });\n * ```\n *\n **/\nfunction MarkdownIt(presetName, options) {\n if (!(this instanceof MarkdownIt)) {\n return new MarkdownIt(presetName, options);\n }\n if (!options) {\n if (!isString(presetName)) {\n options = presetName || {};\n presetName = 'default';\n }\n }\n\n /**\n * MarkdownIt#inline -> ParserInline\n *\n * Instance of [[ParserInline]]. You may need it to add new rules when\n * writing plugins. For simple rules control use [[MarkdownIt.disable]] and\n * [[MarkdownIt.enable]].\n **/\n this.inline = new ParserInline();\n\n /**\n * MarkdownIt#block -> ParserBlock\n *\n * Instance of [[ParserBlock]]. You may need it to add new rules when\n * writing plugins. For simple rules control use [[MarkdownIt.disable]] and\n * [[MarkdownIt.enable]].\n **/\n this.block = new ParserBlock();\n\n /**\n * MarkdownIt#core -> Core\n *\n * Instance of [[Core]] chain executor. You may need it to add new rules when\n * writing plugins. For simple rules control use [[MarkdownIt.disable]] and\n * [[MarkdownIt.enable]].\n **/\n this.core = new Core();\n\n /**\n * MarkdownIt#renderer -> Renderer\n *\n * Instance of [[Renderer]]. Use it to modify output look. Or to add rendering\n * rules for new token types, generated by plugins.\n *\n * ##### Example\n *\n * ```javascript\n * var md = require('markdown-it')();\n *\n * function myToken(tokens, idx, options, env, self) {\n * //...\n * return result;\n * };\n *\n * md.renderer.rules['my_token'] = myToken\n * ```\n *\n * See [[Renderer]] docs and [source code](https://github.com/markdown-it/markdown-it/blob/master/lib/renderer.mjs).\n **/\n this.renderer = new Renderer();\n\n /**\n * MarkdownIt#linkify -> LinkifyIt\n *\n * [linkify-it](https://github.com/markdown-it/linkify-it) instance.\n * Used by [linkify](https://github.com/markdown-it/markdown-it/blob/master/lib/rules_core/linkify.mjs)\n * rule.\n **/\n this.linkify = new LinkifyIt();\n\n /**\n * MarkdownIt#validateLink(url) -> Boolean\n *\n * Link validation function. CommonMark allows too much in links. By default\n * we disable `javascript:`, `vbscript:`, `file:` schemas, and almost all `data:...` schemas\n * except some embedded image types.\n *\n * You can change this behaviour:\n *\n * ```javascript\n * var md = require('markdown-it')();\n * // enable everything\n * md.validateLink = function () { return true; }\n * ```\n **/\n this.validateLink = validateLink;\n\n /**\n * MarkdownIt#normalizeLink(url) -> String\n *\n * Function used to encode link url to a machine-readable format,\n * which includes url-encoding, punycode, etc.\n **/\n this.normalizeLink = normalizeLink;\n\n /**\n * MarkdownIt#normalizeLinkText(url) -> String\n *\n * Function used to decode link url to a human-readable format`\n **/\n this.normalizeLinkText = normalizeLinkText;\n\n // Expose utils & helpers for easy acces from plugins\n\n /**\n * MarkdownIt#utils -> utils\n *\n * Assorted utility functions, useful to write plugins. See details\n * [here](https://github.com/markdown-it/markdown-it/blob/master/lib/common/utils.mjs).\n **/\n this.utils = utils;\n\n /**\n * MarkdownIt#helpers -> helpers\n *\n * Link components parser functions, useful to write plugins. See details\n * [here](https://github.com/markdown-it/markdown-it/blob/master/lib/helpers).\n **/\n this.helpers = assign({}, helpers);\n this.options = {};\n this.configure(presetName);\n if (options) {\n this.set(options);\n }\n}\n\n/** chainable\n * MarkdownIt.set(options)\n *\n * Set parser options (in the same format as in constructor). Probably, you\n * will never need it, but you can change options after constructor call.\n *\n * ##### Example\n *\n * ```javascript\n * var md = require('markdown-it')()\n * .set({ html: true, breaks: true })\n * .set({ typographer, true });\n * ```\n *\n * __Note:__ To achieve the best possible performance, don't modify a\n * `markdown-it` instance options on the fly. If you need multiple configurations\n * it's best to create multiple instances and initialize each with separate\n * config.\n **/\nMarkdownIt.prototype.set = function (options) {\n assign(this.options, options);\n return this;\n};\n\n/** chainable, internal\n * MarkdownIt.configure(presets)\n *\n * Batch load of all options and compenent settings. This is internal method,\n * and you probably will not need it. But if you will - see available presets\n * and data structure [here](https://github.com/markdown-it/markdown-it/tree/master/lib/presets)\n *\n * We strongly recommend to use presets instead of direct config loads. That\n * will give better compatibility with next versions.\n **/\nMarkdownIt.prototype.configure = function (presets) {\n const self = this;\n if (isString(presets)) {\n const presetName = presets;\n presets = config[presetName];\n if (!presets) {\n throw new Error('Wrong `markdown-it` preset \"' + presetName + '\", check name');\n }\n }\n if (!presets) {\n throw new Error('Wrong `markdown-it` preset, can\\'t be empty');\n }\n if (presets.options) {\n self.set(presets.options);\n }\n if (presets.components) {\n Object.keys(presets.components).forEach(function (name) {\n if (presets.components[name].rules) {\n self[name].ruler.enableOnly(presets.components[name].rules);\n }\n if (presets.components[name].rules2) {\n self[name].ruler2.enableOnly(presets.components[name].rules2);\n }\n });\n }\n return this;\n};\n\n/** chainable\n * MarkdownIt.enable(list, ignoreInvalid)\n * - list (String|Array): rule name or list of rule names to enable\n * - ignoreInvalid (Boolean): set `true` to ignore errors when rule not found.\n *\n * Enable list or rules. It will automatically find appropriate components,\n * containing rules with given names. If rule not found, and `ignoreInvalid`\n * not set - throws exception.\n *\n * ##### Example\n *\n * ```javascript\n * var md = require('markdown-it')()\n * .enable(['sub', 'sup'])\n * .disable('smartquotes');\n * ```\n **/\nMarkdownIt.prototype.enable = function (list, ignoreInvalid) {\n let result = [];\n if (!Array.isArray(list)) {\n list = [list];\n }\n ['core', 'block', 'inline'].forEach(function (chain) {\n result = result.concat(this[chain].ruler.enable(list, true));\n }, this);\n result = result.concat(this.inline.ruler2.enable(list, true));\n const missed = list.filter(function (name) {\n return result.indexOf(name) < 0;\n });\n if (missed.length && !ignoreInvalid) {\n throw new Error('MarkdownIt. Failed to enable unknown rule(s): ' + missed);\n }\n return this;\n};\n\n/** chainable\n * MarkdownIt.disable(list, ignoreInvalid)\n * - list (String|Array): rule name or list of rule names to disable.\n * - ignoreInvalid (Boolean): set `true` to ignore errors when rule not found.\n *\n * The same as [[MarkdownIt.enable]], but turn specified rules off.\n **/\nMarkdownIt.prototype.disable = function (list, ignoreInvalid) {\n let result = [];\n if (!Array.isArray(list)) {\n list = [list];\n }\n ['core', 'block', 'inline'].forEach(function (chain) {\n result = result.concat(this[chain].ruler.disable(list, true));\n }, this);\n result = result.concat(this.inline.ruler2.disable(list, true));\n const missed = list.filter(function (name) {\n return result.indexOf(name) < 0;\n });\n if (missed.length && !ignoreInvalid) {\n throw new Error('MarkdownIt. Failed to disable unknown rule(s): ' + missed);\n }\n return this;\n};\n\n/** chainable\n * MarkdownIt.use(plugin, params)\n *\n * Load specified plugin with given params into current parser instance.\n * It's just a sugar to call `plugin(md, params)` with curring.\n *\n * ##### Example\n *\n * ```javascript\n * var iterator = require('markdown-it-for-inline');\n * var md = require('markdown-it')()\n * .use(iterator, 'foo_replace', 'text', function (tokens, idx) {\n * tokens[idx].content = tokens[idx].content.replace(/foo/g, 'bar');\n * });\n * ```\n **/\nMarkdownIt.prototype.use = function (plugin /*, params, ... */) {\n const args = [this].concat(Array.prototype.slice.call(arguments, 1));\n plugin.apply(plugin, args);\n return this;\n};\n\n/** internal\n * MarkdownIt.parse(src, env) -> Array\n * - src (String): source string\n * - env (Object): environment sandbox\n *\n * Parse input string and return list of block tokens (special token type\n * \"inline\" will contain list of inline tokens). You should not call this\n * method directly, until you write custom renderer (for example, to produce\n * AST).\n *\n * `env` is used to pass data between \"distributed\" rules and return additional\n * metadata like reference info, needed for the renderer. It also can be used to\n * inject data in specific cases. Usually, you will be ok to pass `{}`,\n * and then pass updated object to renderer.\n **/\nMarkdownIt.prototype.parse = function (src, env) {\n if (typeof src !== 'string') {\n throw new Error('Input data should be a String');\n }\n const state = new this.core.State(src, this, env);\n this.core.process(state);\n return state.tokens;\n};\n\n/**\n * MarkdownIt.render(src [, env]) -> String\n * - src (String): source string\n * - env (Object): environment sandbox\n *\n * Render markdown string into html. It does all magic for you :).\n *\n * `env` can be used to inject additional metadata (`{}` by default).\n * But you will not need it with high probability. See also comment\n * in [[MarkdownIt.parse]].\n **/\nMarkdownIt.prototype.render = function (src, env) {\n env = env || {};\n return this.renderer.render(this.parse(src, env), this.options, env);\n};\n\n/** internal\n * MarkdownIt.parseInline(src, env) -> Array\n * - src (String): source string\n * - env (Object): environment sandbox\n *\n * The same as [[MarkdownIt.parse]] but skip all block rules. It returns the\n * block tokens list with the single `inline` element, containing parsed inline\n * tokens in `children` property. Also updates `env` object.\n **/\nMarkdownIt.prototype.parseInline = function (src, env) {\n const state = new this.core.State(src, this, env);\n state.inlineMode = true;\n this.core.process(state);\n return state.tokens;\n};\n\n/**\n * MarkdownIt.renderInline(src [, env]) -> String\n * - src (String): source string\n * - env (Object): environment sandbox\n *\n * Similar to [[MarkdownIt.render]] but for single paragraph content. Result\n * will NOT be wrapped into `

    ` tags.\n **/\nMarkdownIt.prototype.renderInline = function (src, env) {\n env = env || {};\n return this.renderer.render(this.parseInline(src, env), this.options, env);\n};\n\nmodule.exports = MarkdownIt;\n","'use strict';\n\n/* eslint-disable no-bitwise */\n\nconst decodeCache = {};\n\nfunction getDecodeCache (exclude) {\n let cache = decodeCache[exclude];\n if (cache) { return cache }\n\n cache = decodeCache[exclude] = [];\n\n for (let i = 0; i < 128; i++) {\n const ch = String.fromCharCode(i);\n cache.push(ch);\n }\n\n for (let i = 0; i < exclude.length; i++) {\n const ch = exclude.charCodeAt(i);\n cache[ch] = '%' + ('0' + ch.toString(16).toUpperCase()).slice(-2);\n }\n\n return cache\n}\n\n// Decode percent-encoded string.\n//\nfunction decode (string, exclude) {\n if (typeof exclude !== 'string') {\n exclude = decode.defaultChars;\n }\n\n const cache = getDecodeCache(exclude);\n\n return string.replace(/(%[a-f0-9]{2})+/gi, function (seq) {\n let result = '';\n\n for (let i = 0, l = seq.length; i < l; i += 3) {\n const b1 = parseInt(seq.slice(i + 1, i + 3), 16);\n\n if (b1 < 0x80) {\n result += cache[b1];\n continue\n }\n\n if ((b1 & 0xE0) === 0xC0 && (i + 3 < l)) {\n // 110xxxxx 10xxxxxx\n const b2 = parseInt(seq.slice(i + 4, i + 6), 16);\n\n if ((b2 & 0xC0) === 0x80) {\n const chr = ((b1 << 6) & 0x7C0) | (b2 & 0x3F);\n\n if (chr < 0x80) {\n result += '\\ufffd\\ufffd';\n } else {\n result += String.fromCharCode(chr);\n }\n\n i += 3;\n continue\n }\n }\n\n if ((b1 & 0xF0) === 0xE0 && (i + 6 < l)) {\n // 1110xxxx 10xxxxxx 10xxxxxx\n const b2 = parseInt(seq.slice(i + 4, i + 6), 16);\n const b3 = parseInt(seq.slice(i + 7, i + 9), 16);\n\n if ((b2 & 0xC0) === 0x80 && (b3 & 0xC0) === 0x80) {\n const chr = ((b1 << 12) & 0xF000) | ((b2 << 6) & 0xFC0) | (b3 & 0x3F);\n\n if (chr < 0x800 || (chr >= 0xD800 && chr <= 0xDFFF)) {\n result += '\\ufffd\\ufffd\\ufffd';\n } else {\n result += String.fromCharCode(chr);\n }\n\n i += 6;\n continue\n }\n }\n\n if ((b1 & 0xF8) === 0xF0 && (i + 9 < l)) {\n // 111110xx 10xxxxxx 10xxxxxx 10xxxxxx\n const b2 = parseInt(seq.slice(i + 4, i + 6), 16);\n const b3 = parseInt(seq.slice(i + 7, i + 9), 16);\n const b4 = parseInt(seq.slice(i + 10, i + 12), 16);\n\n if ((b2 & 0xC0) === 0x80 && (b3 & 0xC0) === 0x80 && (b4 & 0xC0) === 0x80) {\n let chr = ((b1 << 18) & 0x1C0000) | ((b2 << 12) & 0x3F000) | ((b3 << 6) & 0xFC0) | (b4 & 0x3F);\n\n if (chr < 0x10000 || chr > 0x10FFFF) {\n result += '\\ufffd\\ufffd\\ufffd\\ufffd';\n } else {\n chr -= 0x10000;\n result += String.fromCharCode(0xD800 + (chr >> 10), 0xDC00 + (chr & 0x3FF));\n }\n\n i += 9;\n continue\n }\n }\n\n result += '\\ufffd';\n }\n\n return result\n })\n}\n\ndecode.defaultChars = ';/?:@&=+$,#';\ndecode.componentChars = '';\n\nconst encodeCache = {};\n\n// Create a lookup array where anything but characters in `chars` string\n// and alphanumeric chars is percent-encoded.\n//\nfunction getEncodeCache (exclude) {\n let cache = encodeCache[exclude];\n if (cache) { return cache }\n\n cache = encodeCache[exclude] = [];\n\n for (let i = 0; i < 128; i++) {\n const ch = String.fromCharCode(i);\n\n if (/^[0-9a-z]$/i.test(ch)) {\n // always allow unencoded alphanumeric characters\n cache.push(ch);\n } else {\n cache.push('%' + ('0' + i.toString(16).toUpperCase()).slice(-2));\n }\n }\n\n for (let i = 0; i < exclude.length; i++) {\n cache[exclude.charCodeAt(i)] = exclude[i];\n }\n\n return cache\n}\n\n// Encode unsafe characters with percent-encoding, skipping already\n// encoded sequences.\n//\n// - string - string to encode\n// - exclude - list of characters to ignore (in addition to a-zA-Z0-9)\n// - keepEscaped - don't encode '%' in a correct escape sequence (default: true)\n//\nfunction encode (string, exclude, keepEscaped) {\n if (typeof exclude !== 'string') {\n // encode(string, keepEscaped)\n keepEscaped = exclude;\n exclude = encode.defaultChars;\n }\n\n if (typeof keepEscaped === 'undefined') {\n keepEscaped = true;\n }\n\n const cache = getEncodeCache(exclude);\n let result = '';\n\n for (let i = 0, l = string.length; i < l; i++) {\n const code = string.charCodeAt(i);\n\n if (keepEscaped && code === 0x25 /* % */ && i + 2 < l) {\n if (/^[0-9a-f]{2}$/i.test(string.slice(i + 1, i + 3))) {\n result += string.slice(i, i + 3);\n i += 2;\n continue\n }\n }\n\n if (code < 128) {\n result += cache[code];\n continue\n }\n\n if (code >= 0xD800 && code <= 0xDFFF) {\n if (code >= 0xD800 && code <= 0xDBFF && i + 1 < l) {\n const nextCode = string.charCodeAt(i + 1);\n if (nextCode >= 0xDC00 && nextCode <= 0xDFFF) {\n result += encodeURIComponent(string[i] + string[i + 1]);\n i++;\n continue\n }\n }\n result += '%EF%BF%BD';\n continue\n }\n\n result += encodeURIComponent(string[i]);\n }\n\n return result\n}\n\nencode.defaultChars = \";/?:@&=+$,-_.!~*'()#\";\nencode.componentChars = \"-_.!~*'()\";\n\nfunction format (url) {\n let result = '';\n\n result += url.protocol || '';\n result += url.slashes ? '//' : '';\n result += url.auth ? url.auth + '@' : '';\n\n if (url.hostname && url.hostname.indexOf(':') !== -1) {\n // ipv6 address\n result += '[' + url.hostname + ']';\n } else {\n result += url.hostname || '';\n }\n\n result += url.port ? ':' + url.port : '';\n result += url.pathname || '';\n result += url.search || '';\n result += url.hash || '';\n\n return result\n}\n\n// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// copy of this software and associated documentation files (the\n// \"Software\"), to deal in the Software without restriction, including\n// without limitation the rights to use, copy, modify, merge, publish,\n// distribute, sublicense, and/or sell copies of the Software, and to permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n//\n// Changes from joyent/node:\n//\n// 1. No leading slash in paths,\n// e.g. in `url.parse('http://foo?bar')` pathname is ``, not `/`\n//\n// 2. Backslashes are not replaced with slashes,\n// so `http:\\\\example.org\\` is treated like a relative path\n//\n// 3. Trailing colon is treated like a part of the path,\n// i.e. in `http://example.org:foo` pathname is `:foo`\n//\n// 4. Nothing is URL-encoded in the resulting object,\n// (in joyent/node some chars in auth and paths are encoded)\n//\n// 5. `url.parse()` does not have `parseQueryString` argument\n//\n// 6. Removed extraneous result properties: `host`, `path`, `query`, etc.,\n// which can be constructed using other parts of the url.\n//\n\nfunction Url () {\n this.protocol = null;\n this.slashes = null;\n this.auth = null;\n this.port = null;\n this.hostname = null;\n this.hash = null;\n this.search = null;\n this.pathname = null;\n}\n\n// Reference: RFC 3986, RFC 1808, RFC 2396\n\n// define these here so at least they only have to be\n// compiled once on the first module load.\nconst protocolPattern = /^([a-z0-9.+-]+:)/i;\nconst portPattern = /:[0-9]*$/;\n\n// Special case for a simple path URL\n/* eslint-disable-next-line no-useless-escape */\nconst simplePathPattern = /^(\\/\\/?(?!\\/)[^\\?\\s]*)(\\?[^\\s]*)?$/;\n\n// RFC 2396: characters reserved for delimiting URLs.\n// We actually just auto-escape these.\nconst delims = ['<', '>', '\"', '`', ' ', '\\r', '\\n', '\\t'];\n\n// RFC 2396: characters not allowed for various reasons.\nconst unwise = ['{', '}', '|', '\\\\', '^', '`'].concat(delims);\n\n// Allowed by RFCs, but cause of XSS attacks. Always escape these.\nconst autoEscape = ['\\''].concat(unwise);\n// Characters that are never ever allowed in a hostname.\n// Note that any invalid chars are also handled, but these\n// are the ones that are *expected* to be seen, so we fast-path\n// them.\nconst nonHostChars = ['%', '/', '?', ';', '#'].concat(autoEscape);\nconst hostEndingChars = ['/', '?', '#'];\nconst hostnameMaxLen = 255;\nconst hostnamePartPattern = /^[+a-z0-9A-Z_-]{0,63}$/;\nconst hostnamePartStart = /^([+a-z0-9A-Z_-]{0,63})(.*)$/;\n// protocols that can allow \"unsafe\" and \"unwise\" chars.\n// protocols that never have a hostname.\nconst hostlessProtocol = {\n javascript: true,\n 'javascript:': true\n};\n// protocols that always contain a // bit.\nconst slashedProtocol = {\n http: true,\n https: true,\n ftp: true,\n gopher: true,\n file: true,\n 'http:': true,\n 'https:': true,\n 'ftp:': true,\n 'gopher:': true,\n 'file:': true\n};\n\nfunction urlParse (url, slashesDenoteHost) {\n if (url && url instanceof Url) return url\n\n const u = new Url();\n u.parse(url, slashesDenoteHost);\n return u\n}\n\nUrl.prototype.parse = function (url, slashesDenoteHost) {\n let lowerProto, hec, slashes;\n let rest = url;\n\n // trim before proceeding.\n // This is to support parse stuff like \" http://foo.com \\n\"\n rest = rest.trim();\n\n if (!slashesDenoteHost && url.split('#').length === 1) {\n // Try fast path regexp\n const simplePath = simplePathPattern.exec(rest);\n if (simplePath) {\n this.pathname = simplePath[1];\n if (simplePath[2]) {\n this.search = simplePath[2];\n }\n return this\n }\n }\n\n let proto = protocolPattern.exec(rest);\n if (proto) {\n proto = proto[0];\n lowerProto = proto.toLowerCase();\n this.protocol = proto;\n rest = rest.substr(proto.length);\n }\n\n // figure out if it's got a host\n // user@server is *always* interpreted as a hostname, and url\n // resolution will treat //foo/bar as host=foo,path=bar because that's\n // how the browser resolves relative URLs.\n /* eslint-disable-next-line no-useless-escape */\n if (slashesDenoteHost || proto || rest.match(/^\\/\\/[^@\\/]+@[^@\\/]+/)) {\n slashes = rest.substr(0, 2) === '//';\n if (slashes && !(proto && hostlessProtocol[proto])) {\n rest = rest.substr(2);\n this.slashes = true;\n }\n }\n\n if (!hostlessProtocol[proto] &&\n (slashes || (proto && !slashedProtocol[proto]))) {\n // there's a hostname.\n // the first instance of /, ?, ;, or # ends the host.\n //\n // If there is an @ in the hostname, then non-host chars *are* allowed\n // to the left of the last @ sign, unless some host-ending character\n // comes *before* the @-sign.\n // URLs are obnoxious.\n //\n // ex:\n // http://a@b@c/ => user:a@b host:c\n // http://a@b?@c => user:a host:c path:/?@c\n\n // v0.12 TODO(isaacs): This is not quite how Chrome does things.\n // Review our test case against browsers more comprehensively.\n\n // find the first instance of any hostEndingChars\n let hostEnd = -1;\n for (let i = 0; i < hostEndingChars.length; i++) {\n hec = rest.indexOf(hostEndingChars[i]);\n if (hec !== -1 && (hostEnd === -1 || hec < hostEnd)) {\n hostEnd = hec;\n }\n }\n\n // at this point, either we have an explicit point where the\n // auth portion cannot go past, or the last @ char is the decider.\n let auth, atSign;\n if (hostEnd === -1) {\n // atSign can be anywhere.\n atSign = rest.lastIndexOf('@');\n } else {\n // atSign must be in auth portion.\n // http://a@b/c@d => host:b auth:a path:/c@d\n atSign = rest.lastIndexOf('@', hostEnd);\n }\n\n // Now we have a portion which is definitely the auth.\n // Pull that off.\n if (atSign !== -1) {\n auth = rest.slice(0, atSign);\n rest = rest.slice(atSign + 1);\n this.auth = auth;\n }\n\n // the host is the remaining to the left of the first non-host char\n hostEnd = -1;\n for (let i = 0; i < nonHostChars.length; i++) {\n hec = rest.indexOf(nonHostChars[i]);\n if (hec !== -1 && (hostEnd === -1 || hec < hostEnd)) {\n hostEnd = hec;\n }\n }\n // if we still have not hit it, then the entire thing is a host.\n if (hostEnd === -1) {\n hostEnd = rest.length;\n }\n\n if (rest[hostEnd - 1] === ':') { hostEnd--; }\n const host = rest.slice(0, hostEnd);\n rest = rest.slice(hostEnd);\n\n // pull out port.\n this.parseHost(host);\n\n // we've indicated that there is a hostname,\n // so even if it's empty, it has to be present.\n this.hostname = this.hostname || '';\n\n // if hostname begins with [ and ends with ]\n // assume that it's an IPv6 address.\n const ipv6Hostname = this.hostname[0] === '[' &&\n this.hostname[this.hostname.length - 1] === ']';\n\n // validate a little.\n if (!ipv6Hostname) {\n const hostparts = this.hostname.split(/\\./);\n for (let i = 0, l = hostparts.length; i < l; i++) {\n const part = hostparts[i];\n if (!part) { continue }\n if (!part.match(hostnamePartPattern)) {\n let newpart = '';\n for (let j = 0, k = part.length; j < k; j++) {\n if (part.charCodeAt(j) > 127) {\n // we replace non-ASCII char with a temporary placeholder\n // we need this to make sure size of hostname is not\n // broken by replacing non-ASCII by nothing\n newpart += 'x';\n } else {\n newpart += part[j];\n }\n }\n // we test again with ASCII char only\n if (!newpart.match(hostnamePartPattern)) {\n const validParts = hostparts.slice(0, i);\n const notHost = hostparts.slice(i + 1);\n const bit = part.match(hostnamePartStart);\n if (bit) {\n validParts.push(bit[1]);\n notHost.unshift(bit[2]);\n }\n if (notHost.length) {\n rest = notHost.join('.') + rest;\n }\n this.hostname = validParts.join('.');\n break\n }\n }\n }\n }\n\n if (this.hostname.length > hostnameMaxLen) {\n this.hostname = '';\n }\n\n // strip [ and ] from the hostname\n // the host field still retains them, though\n if (ipv6Hostname) {\n this.hostname = this.hostname.substr(1, this.hostname.length - 2);\n }\n }\n\n // chop off from the tail first.\n const hash = rest.indexOf('#');\n if (hash !== -1) {\n // got a fragment string.\n this.hash = rest.substr(hash);\n rest = rest.slice(0, hash);\n }\n const qm = rest.indexOf('?');\n if (qm !== -1) {\n this.search = rest.substr(qm);\n rest = rest.slice(0, qm);\n }\n if (rest) { this.pathname = rest; }\n if (slashedProtocol[lowerProto] &&\n this.hostname && !this.pathname) {\n this.pathname = '';\n }\n\n return this\n};\n\nUrl.prototype.parseHost = function (host) {\n let port = portPattern.exec(host);\n if (port) {\n port = port[0];\n if (port !== ':') {\n this.port = port.substr(1);\n }\n host = host.substr(0, host.length - port.length);\n }\n if (host) { this.hostname = host; }\n};\n\nexports.decode = decode;\nexports.encode = encode;\nexports.format = format;\nexports.parse = urlParse;\n","'use strict';\n\n/** Highest positive signed 32-bit float value */\nconst maxInt = 2147483647; // aka. 0x7FFFFFFF or 2^31-1\n\n/** Bootstring parameters */\nconst base = 36;\nconst tMin = 1;\nconst tMax = 26;\nconst skew = 38;\nconst damp = 700;\nconst initialBias = 72;\nconst initialN = 128; // 0x80\nconst delimiter = '-'; // '\\x2D'\n\n/** Regular expressions */\nconst regexPunycode = /^xn--/;\nconst regexNonASCII = /[^\\0-\\x7F]/; // Note: U+007F DEL is excluded too.\nconst regexSeparators = /[\\x2E\\u3002\\uFF0E\\uFF61]/g; // RFC 3490 separators\n\n/** Error messages */\nconst errors = {\n\t'overflow': 'Overflow: input needs wider integers to process',\n\t'not-basic': 'Illegal input >= 0x80 (not a basic code point)',\n\t'invalid-input': 'Invalid input'\n};\n\n/** Convenience shortcuts */\nconst baseMinusTMin = base - tMin;\nconst floor = Math.floor;\nconst stringFromCharCode = String.fromCharCode;\n\n/*--------------------------------------------------------------------------*/\n\n/**\n * A generic error utility function.\n * @private\n * @param {String} type The error type.\n * @returns {Error} Throws a `RangeError` with the applicable error message.\n */\nfunction error(type) {\n\tthrow new RangeError(errors[type]);\n}\n\n/**\n * A generic `Array#map` utility function.\n * @private\n * @param {Array} array The array to iterate over.\n * @param {Function} callback The function that gets called for every array\n * item.\n * @returns {Array} A new array of values returned by the callback function.\n */\nfunction map(array, callback) {\n\tconst result = [];\n\tlet length = array.length;\n\twhile (length--) {\n\t\tresult[length] = callback(array[length]);\n\t}\n\treturn result;\n}\n\n/**\n * A simple `Array#map`-like wrapper to work with domain name strings or email\n * addresses.\n * @private\n * @param {String} domain The domain name or email address.\n * @param {Function} callback The function that gets called for every\n * character.\n * @returns {String} A new string of characters returned by the callback\n * function.\n */\nfunction mapDomain(domain, callback) {\n\tconst parts = domain.split('@');\n\tlet result = '';\n\tif (parts.length > 1) {\n\t\t// In email addresses, only the domain name should be punycoded. Leave\n\t\t// the local part (i.e. everything up to `@`) intact.\n\t\tresult = parts[0] + '@';\n\t\tdomain = parts[1];\n\t}\n\t// Avoid `split(regex)` for IE8 compatibility. See #17.\n\tdomain = domain.replace(regexSeparators, '\\x2E');\n\tconst labels = domain.split('.');\n\tconst encoded = map(labels, callback).join('.');\n\treturn result + encoded;\n}\n\n/**\n * Creates an array containing the numeric code points of each Unicode\n * character in the string. While JavaScript uses UCS-2 internally,\n * this function will convert a pair of surrogate halves (each of which\n * UCS-2 exposes as separate characters) into a single code point,\n * matching UTF-16.\n * @see `punycode.ucs2.encode`\n * @see \n * @memberOf punycode.ucs2\n * @name decode\n * @param {String} string The Unicode input string (UCS-2).\n * @returns {Array} The new array of code points.\n */\nfunction ucs2decode(string) {\n\tconst output = [];\n\tlet counter = 0;\n\tconst length = string.length;\n\twhile (counter < length) {\n\t\tconst value = string.charCodeAt(counter++);\n\t\tif (value >= 0xD800 && value <= 0xDBFF && counter < length) {\n\t\t\t// It's a high surrogate, and there is a next character.\n\t\t\tconst extra = string.charCodeAt(counter++);\n\t\t\tif ((extra & 0xFC00) == 0xDC00) { // Low surrogate.\n\t\t\t\toutput.push(((value & 0x3FF) << 10) + (extra & 0x3FF) + 0x10000);\n\t\t\t} else {\n\t\t\t\t// It's an unmatched surrogate; only append this code unit, in case the\n\t\t\t\t// next code unit is the high surrogate of a surrogate pair.\n\t\t\t\toutput.push(value);\n\t\t\t\tcounter--;\n\t\t\t}\n\t\t} else {\n\t\t\toutput.push(value);\n\t\t}\n\t}\n\treturn output;\n}\n\n/**\n * Creates a string based on an array of numeric code points.\n * @see `punycode.ucs2.decode`\n * @memberOf punycode.ucs2\n * @name encode\n * @param {Array} codePoints The array of numeric code points.\n * @returns {String} The new Unicode string (UCS-2).\n */\nconst ucs2encode = codePoints => String.fromCodePoint(...codePoints);\n\n/**\n * Converts a basic code point into a digit/integer.\n * @see `digitToBasic()`\n * @private\n * @param {Number} codePoint The basic numeric code point value.\n * @returns {Number} The numeric value of a basic code point (for use in\n * representing integers) in the range `0` to `base - 1`, or `base` if\n * the code point does not represent a value.\n */\nconst basicToDigit = function(codePoint) {\n\tif (codePoint >= 0x30 && codePoint < 0x3A) {\n\t\treturn 26 + (codePoint - 0x30);\n\t}\n\tif (codePoint >= 0x41 && codePoint < 0x5B) {\n\t\treturn codePoint - 0x41;\n\t}\n\tif (codePoint >= 0x61 && codePoint < 0x7B) {\n\t\treturn codePoint - 0x61;\n\t}\n\treturn base;\n};\n\n/**\n * Converts a digit/integer into a basic code point.\n * @see `basicToDigit()`\n * @private\n * @param {Number} digit The numeric value of a basic code point.\n * @returns {Number} The basic code point whose value (when used for\n * representing integers) is `digit`, which needs to be in the range\n * `0` to `base - 1`. If `flag` is non-zero, the uppercase form is\n * used; else, the lowercase form is used. The behavior is undefined\n * if `flag` is non-zero and `digit` has no uppercase form.\n */\nconst digitToBasic = function(digit, flag) {\n\t// 0..25 map to ASCII a..z or A..Z\n\t// 26..35 map to ASCII 0..9\n\treturn digit + 22 + 75 * (digit < 26) - ((flag != 0) << 5);\n};\n\n/**\n * Bias adaptation function as per section 3.4 of RFC 3492.\n * https://tools.ietf.org/html/rfc3492#section-3.4\n * @private\n */\nconst adapt = function(delta, numPoints, firstTime) {\n\tlet k = 0;\n\tdelta = firstTime ? floor(delta / damp) : delta >> 1;\n\tdelta += floor(delta / numPoints);\n\tfor (/* no initialization */; delta > baseMinusTMin * tMax >> 1; k += base) {\n\t\tdelta = floor(delta / baseMinusTMin);\n\t}\n\treturn floor(k + (baseMinusTMin + 1) * delta / (delta + skew));\n};\n\n/**\n * Converts a Punycode string of ASCII-only symbols to a string of Unicode\n * symbols.\n * @memberOf punycode\n * @param {String} input The Punycode string of ASCII-only symbols.\n * @returns {String} The resulting string of Unicode symbols.\n */\nconst decode = function(input) {\n\t// Don't use UCS-2.\n\tconst output = [];\n\tconst inputLength = input.length;\n\tlet i = 0;\n\tlet n = initialN;\n\tlet bias = initialBias;\n\n\t// Handle the basic code points: let `basic` be the number of input code\n\t// points before the last delimiter, or `0` if there is none, then copy\n\t// the first basic code points to the output.\n\n\tlet basic = input.lastIndexOf(delimiter);\n\tif (basic < 0) {\n\t\tbasic = 0;\n\t}\n\n\tfor (let j = 0; j < basic; ++j) {\n\t\t// if it's not a basic code point\n\t\tif (input.charCodeAt(j) >= 0x80) {\n\t\t\terror('not-basic');\n\t\t}\n\t\toutput.push(input.charCodeAt(j));\n\t}\n\n\t// Main decoding loop: start just after the last delimiter if any basic code\n\t// points were copied; start at the beginning otherwise.\n\n\tfor (let index = basic > 0 ? basic + 1 : 0; index < inputLength; /* no final expression */) {\n\n\t\t// `index` is the index of the next character to be consumed.\n\t\t// Decode a generalized variable-length integer into `delta`,\n\t\t// which gets added to `i`. The overflow checking is easier\n\t\t// if we increase `i` as we go, then subtract off its starting\n\t\t// value at the end to obtain `delta`.\n\t\tconst oldi = i;\n\t\tfor (let w = 1, k = base; /* no condition */; k += base) {\n\n\t\t\tif (index >= inputLength) {\n\t\t\t\terror('invalid-input');\n\t\t\t}\n\n\t\t\tconst digit = basicToDigit(input.charCodeAt(index++));\n\n\t\t\tif (digit >= base) {\n\t\t\t\terror('invalid-input');\n\t\t\t}\n\t\t\tif (digit > floor((maxInt - i) / w)) {\n\t\t\t\terror('overflow');\n\t\t\t}\n\n\t\t\ti += digit * w;\n\t\t\tconst t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);\n\n\t\t\tif (digit < t) {\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tconst baseMinusT = base - t;\n\t\t\tif (w > floor(maxInt / baseMinusT)) {\n\t\t\t\terror('overflow');\n\t\t\t}\n\n\t\t\tw *= baseMinusT;\n\n\t\t}\n\n\t\tconst out = output.length + 1;\n\t\tbias = adapt(i - oldi, out, oldi == 0);\n\n\t\t// `i` was supposed to wrap around from `out` to `0`,\n\t\t// incrementing `n` each time, so we'll fix that now:\n\t\tif (floor(i / out) > maxInt - n) {\n\t\t\terror('overflow');\n\t\t}\n\n\t\tn += floor(i / out);\n\t\ti %= out;\n\n\t\t// Insert `n` at position `i` of the output.\n\t\toutput.splice(i++, 0, n);\n\n\t}\n\n\treturn String.fromCodePoint(...output);\n};\n\n/**\n * Converts a string of Unicode symbols (e.g. a domain name label) to a\n * Punycode string of ASCII-only symbols.\n * @memberOf punycode\n * @param {String} input The string of Unicode symbols.\n * @returns {String} The resulting Punycode string of ASCII-only symbols.\n */\nconst encode = function(input) {\n\tconst output = [];\n\n\t// Convert the input in UCS-2 to an array of Unicode code points.\n\tinput = ucs2decode(input);\n\n\t// Cache the length.\n\tconst inputLength = input.length;\n\n\t// Initialize the state.\n\tlet n = initialN;\n\tlet delta = 0;\n\tlet bias = initialBias;\n\n\t// Handle the basic code points.\n\tfor (const currentValue of input) {\n\t\tif (currentValue < 0x80) {\n\t\t\toutput.push(stringFromCharCode(currentValue));\n\t\t}\n\t}\n\n\tconst basicLength = output.length;\n\tlet handledCPCount = basicLength;\n\n\t// `handledCPCount` is the number of code points that have been handled;\n\t// `basicLength` is the number of basic code points.\n\n\t// Finish the basic string with a delimiter unless it's empty.\n\tif (basicLength) {\n\t\toutput.push(delimiter);\n\t}\n\n\t// Main encoding loop:\n\twhile (handledCPCount < inputLength) {\n\n\t\t// All non-basic code points < n have been handled already. Find the next\n\t\t// larger one:\n\t\tlet m = maxInt;\n\t\tfor (const currentValue of input) {\n\t\t\tif (currentValue >= n && currentValue < m) {\n\t\t\t\tm = currentValue;\n\t\t\t}\n\t\t}\n\n\t\t// Increase `delta` enough to advance the decoder's state to ,\n\t\t// but guard against overflow.\n\t\tconst handledCPCountPlusOne = handledCPCount + 1;\n\t\tif (m - n > floor((maxInt - delta) / handledCPCountPlusOne)) {\n\t\t\terror('overflow');\n\t\t}\n\n\t\tdelta += (m - n) * handledCPCountPlusOne;\n\t\tn = m;\n\n\t\tfor (const currentValue of input) {\n\t\t\tif (currentValue < n && ++delta > maxInt) {\n\t\t\t\terror('overflow');\n\t\t\t}\n\t\t\tif (currentValue === n) {\n\t\t\t\t// Represent delta as a generalized variable-length integer.\n\t\t\t\tlet q = delta;\n\t\t\t\tfor (let k = base; /* no condition */; k += base) {\n\t\t\t\t\tconst t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);\n\t\t\t\t\tif (q < t) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tconst qMinusT = q - t;\n\t\t\t\t\tconst baseMinusT = base - t;\n\t\t\t\t\toutput.push(\n\t\t\t\t\t\tstringFromCharCode(digitToBasic(t + qMinusT % baseMinusT, 0))\n\t\t\t\t\t);\n\t\t\t\t\tq = floor(qMinusT / baseMinusT);\n\t\t\t\t}\n\n\t\t\t\toutput.push(stringFromCharCode(digitToBasic(q, 0)));\n\t\t\t\tbias = adapt(delta, handledCPCountPlusOne, handledCPCount === basicLength);\n\t\t\t\tdelta = 0;\n\t\t\t\t++handledCPCount;\n\t\t\t}\n\t\t}\n\n\t\t++delta;\n\t\t++n;\n\n\t}\n\treturn output.join('');\n};\n\n/**\n * Converts a Punycode string representing a domain name or an email address\n * to Unicode. Only the Punycoded parts of the input will be converted, i.e.\n * it doesn't matter if you call it on a string that has already been\n * converted to Unicode.\n * @memberOf punycode\n * @param {String} input The Punycoded domain name or email address to\n * convert to Unicode.\n * @returns {String} The Unicode representation of the given Punycode\n * string.\n */\nconst toUnicode = function(input) {\n\treturn mapDomain(input, function(string) {\n\t\treturn regexPunycode.test(string)\n\t\t\t? decode(string.slice(4).toLowerCase())\n\t\t\t: string;\n\t});\n};\n\n/**\n * Converts a Unicode string representing a domain name or an email address to\n * Punycode. Only the non-ASCII parts of the domain name will be converted,\n * i.e. it doesn't matter if you call it with a domain that's already in\n * ASCII.\n * @memberOf punycode\n * @param {String} input The domain name or email address to convert, as a\n * Unicode string.\n * @returns {String} The Punycode representation of the given domain name or\n * email address.\n */\nconst toASCII = function(input) {\n\treturn mapDomain(input, function(string) {\n\t\treturn regexNonASCII.test(string)\n\t\t\t? 'xn--' + encode(string)\n\t\t\t: string;\n\t});\n};\n\n/*--------------------------------------------------------------------------*/\n\n/** Define the public API */\nconst punycode = {\n\t/**\n\t * A string representing the current Punycode.js version number.\n\t * @memberOf punycode\n\t * @type String\n\t */\n\t'version': '2.3.1',\n\t/**\n\t * An object of methods to convert from JavaScript's internal character\n\t * representation (UCS-2) to Unicode code points, and back.\n\t * @see \n\t * @memberOf punycode\n\t * @type Object\n\t */\n\t'ucs2': {\n\t\t'decode': ucs2decode,\n\t\t'encode': ucs2encode\n\t},\n\t'decode': decode,\n\t'encode': encode,\n\t'toASCII': toASCII,\n\t'toUnicode': toUnicode\n};\n\nexport { ucs2decode, ucs2encode, decode, encode, toASCII, toUnicode };\nexport default punycode;\n","\"use strict\";\n\nvar stylesInDOM = [];\nfunction getIndexByIdentifier(identifier) {\n var result = -1;\n for (var i = 0; i < stylesInDOM.length; i++) {\n if (stylesInDOM[i].identifier === identifier) {\n result = i;\n break;\n }\n }\n return result;\n}\nfunction modulesToDom(list, options) {\n var idCountMap = {};\n var identifiers = [];\n for (var i = 0; i < list.length; i++) {\n var item = list[i];\n var id = options.base ? item[0] + options.base : item[0];\n var count = idCountMap[id] || 0;\n var identifier = \"\".concat(id, \" \").concat(count);\n idCountMap[id] = count + 1;\n var indexByIdentifier = getIndexByIdentifier(identifier);\n var obj = {\n css: item[1],\n media: item[2],\n sourceMap: item[3],\n supports: item[4],\n layer: item[5]\n };\n if (indexByIdentifier !== -1) {\n stylesInDOM[indexByIdentifier].references++;\n stylesInDOM[indexByIdentifier].updater(obj);\n } else {\n var updater = addElementStyle(obj, options);\n options.byIndex = i;\n stylesInDOM.splice(i, 0, {\n identifier: identifier,\n updater: updater,\n references: 1\n });\n }\n identifiers.push(identifier);\n }\n return identifiers;\n}\nfunction addElementStyle(obj, options) {\n var api = options.domAPI(options);\n api.update(obj);\n var updater = function updater(newObj) {\n if (newObj) {\n if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap && newObj.supports === obj.supports && newObj.layer === obj.layer) {\n return;\n }\n api.update(obj = newObj);\n } else {\n api.remove();\n }\n };\n return updater;\n}\nmodule.exports = function (list, options) {\n options = options || {};\n list = list || [];\n var lastIdentifiers = modulesToDom(list, options);\n return function update(newList) {\n newList = newList || [];\n for (var i = 0; i < lastIdentifiers.length; i++) {\n var identifier = lastIdentifiers[i];\n var index = getIndexByIdentifier(identifier);\n stylesInDOM[index].references--;\n }\n var newLastIdentifiers = modulesToDom(newList, options);\n for (var _i = 0; _i < lastIdentifiers.length; _i++) {\n var _identifier = lastIdentifiers[_i];\n var _index = getIndexByIdentifier(_identifier);\n if (stylesInDOM[_index].references === 0) {\n stylesInDOM[_index].updater();\n stylesInDOM.splice(_index, 1);\n }\n }\n lastIdentifiers = newLastIdentifiers;\n };\n};","\"use strict\";\n\nvar memo = {};\n\n/* istanbul ignore next */\nfunction getTarget(target) {\n if (typeof memo[target] === \"undefined\") {\n var styleTarget = document.querySelector(target);\n\n // Special case to return head of iframe instead of iframe itself\n if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {\n try {\n // This will throw an exception if access to iframe is blocked\n // due to cross-origin restrictions\n styleTarget = styleTarget.contentDocument.head;\n } catch (e) {\n // istanbul ignore next\n styleTarget = null;\n }\n }\n memo[target] = styleTarget;\n }\n return memo[target];\n}\n\n/* istanbul ignore next */\nfunction insertBySelector(insert, style) {\n var target = getTarget(insert);\n if (!target) {\n throw new Error(\"Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.\");\n }\n target.appendChild(style);\n}\nmodule.exports = insertBySelector;","\"use strict\";\n\n/* istanbul ignore next */\nfunction insertStyleElement(options) {\n var element = document.createElement(\"style\");\n options.setAttributes(element, options.attributes);\n options.insert(element, options.options);\n return element;\n}\nmodule.exports = insertStyleElement;","\"use strict\";\n\n/* istanbul ignore next */\nfunction setAttributesWithoutAttributes(styleElement, attributes) {\n Object.keys(attributes).forEach(function (key) {\n styleElement.setAttribute(key, attributes[key]);\n });\n}\nmodule.exports = setAttributesWithoutAttributes;","\"use strict\";\n\n/* istanbul ignore next */\nvar replaceText = function replaceText() {\n var textStore = [];\n return function replace(index, replacement) {\n textStore[index] = replacement;\n return textStore.filter(Boolean).join(\"\\n\");\n };\n}();\n\n/* istanbul ignore next */\nfunction apply(styleElement, index, remove, obj) {\n var css;\n if (remove) {\n css = \"\";\n } else {\n css = \"\";\n if (obj.supports) {\n css += \"@supports (\".concat(obj.supports, \") {\");\n }\n if (obj.media) {\n css += \"@media \".concat(obj.media, \" {\");\n }\n var needLayer = typeof obj.layer !== \"undefined\";\n if (needLayer) {\n css += \"@layer\".concat(obj.layer.length > 0 ? \" \".concat(obj.layer) : \"\", \" {\");\n }\n css += obj.css;\n if (needLayer) {\n css += \"}\";\n }\n if (obj.media) {\n css += \"}\";\n }\n if (obj.supports) {\n css += \"}\";\n }\n }\n\n // For old IE\n /* istanbul ignore if */\n if (styleElement.styleSheet) {\n styleElement.styleSheet.cssText = replaceText(index, css);\n } else {\n var cssNode = document.createTextNode(css);\n var childNodes = styleElement.childNodes;\n if (childNodes[index]) {\n styleElement.removeChild(childNodes[index]);\n }\n if (childNodes.length) {\n styleElement.insertBefore(cssNode, childNodes[index]);\n } else {\n styleElement.appendChild(cssNode);\n }\n }\n}\nvar singletonData = {\n singleton: null,\n singletonCounter: 0\n};\n\n/* istanbul ignore next */\nfunction domAPI(options) {\n if (typeof document === \"undefined\") return {\n update: function update() {},\n remove: function remove() {}\n };\n\n // eslint-disable-next-line no-undef,no-use-before-define\n var styleIndex = singletonData.singletonCounter++;\n var styleElement =\n // eslint-disable-next-line no-undef,no-use-before-define\n singletonData.singleton || (\n // eslint-disable-next-line no-undef,no-use-before-define\n singletonData.singleton = options.insertStyleElement(options));\n return {\n update: function update(obj) {\n apply(styleElement, styleIndex, false, obj);\n },\n remove: function remove(obj) {\n apply(styleElement, styleIndex, true, obj);\n }\n };\n}\nmodule.exports = domAPI;","'use strict';\n\nvar regex$5 = /[\\0-\\uD7FF\\uE000-\\uFFFF]|[\\uD800-\\uDBFF][\\uDC00-\\uDFFF]|[\\uD800-\\uDBFF](?![\\uDC00-\\uDFFF])|(?:[^\\uD800-\\uDBFF]|^)[\\uDC00-\\uDFFF]/;\n\nvar regex$4 = /[\\0-\\x1F\\x7F-\\x9F]/;\n\nvar regex$3 = /[\\xAD\\u0600-\\u0605\\u061C\\u06DD\\u070F\\u0890\\u0891\\u08E2\\u180E\\u200B-\\u200F\\u202A-\\u202E\\u2060-\\u2064\\u2066-\\u206F\\uFEFF\\uFFF9-\\uFFFB]|\\uD804[\\uDCBD\\uDCCD]|\\uD80D[\\uDC30-\\uDC3F]|\\uD82F[\\uDCA0-\\uDCA3]|\\uD834[\\uDD73-\\uDD7A]|\\uDB40[\\uDC01\\uDC20-\\uDC7F]/;\n\nvar regex$2 = /[!-#%-\\*,-\\/:;\\?@\\[-\\]_\\{\\}\\xA1\\xA7\\xAB\\xB6\\xB7\\xBB\\xBF\\u037E\\u0387\\u055A-\\u055F\\u0589\\u058A\\u05BE\\u05C0\\u05C3\\u05C6\\u05F3\\u05F4\\u0609\\u060A\\u060C\\u060D\\u061B\\u061D-\\u061F\\u066A-\\u066D\\u06D4\\u0700-\\u070D\\u07F7-\\u07F9\\u0830-\\u083E\\u085E\\u0964\\u0965\\u0970\\u09FD\\u0A76\\u0AF0\\u0C77\\u0C84\\u0DF4\\u0E4F\\u0E5A\\u0E5B\\u0F04-\\u0F12\\u0F14\\u0F3A-\\u0F3D\\u0F85\\u0FD0-\\u0FD4\\u0FD9\\u0FDA\\u104A-\\u104F\\u10FB\\u1360-\\u1368\\u1400\\u166E\\u169B\\u169C\\u16EB-\\u16ED\\u1735\\u1736\\u17D4-\\u17D6\\u17D8-\\u17DA\\u1800-\\u180A\\u1944\\u1945\\u1A1E\\u1A1F\\u1AA0-\\u1AA6\\u1AA8-\\u1AAD\\u1B5A-\\u1B60\\u1B7D\\u1B7E\\u1BFC-\\u1BFF\\u1C3B-\\u1C3F\\u1C7E\\u1C7F\\u1CC0-\\u1CC7\\u1CD3\\u2010-\\u2027\\u2030-\\u2043\\u2045-\\u2051\\u2053-\\u205E\\u207D\\u207E\\u208D\\u208E\\u2308-\\u230B\\u2329\\u232A\\u2768-\\u2775\\u27C5\\u27C6\\u27E6-\\u27EF\\u2983-\\u2998\\u29D8-\\u29DB\\u29FC\\u29FD\\u2CF9-\\u2CFC\\u2CFE\\u2CFF\\u2D70\\u2E00-\\u2E2E\\u2E30-\\u2E4F\\u2E52-\\u2E5D\\u3001-\\u3003\\u3008-\\u3011\\u3014-\\u301F\\u3030\\u303D\\u30A0\\u30FB\\uA4FE\\uA4FF\\uA60D-\\uA60F\\uA673\\uA67E\\uA6F2-\\uA6F7\\uA874-\\uA877\\uA8CE\\uA8CF\\uA8F8-\\uA8FA\\uA8FC\\uA92E\\uA92F\\uA95F\\uA9C1-\\uA9CD\\uA9DE\\uA9DF\\uAA5C-\\uAA5F\\uAADE\\uAADF\\uAAF0\\uAAF1\\uABEB\\uFD3E\\uFD3F\\uFE10-\\uFE19\\uFE30-\\uFE52\\uFE54-\\uFE61\\uFE63\\uFE68\\uFE6A\\uFE6B\\uFF01-\\uFF03\\uFF05-\\uFF0A\\uFF0C-\\uFF0F\\uFF1A\\uFF1B\\uFF1F\\uFF20\\uFF3B-\\uFF3D\\uFF3F\\uFF5B\\uFF5D\\uFF5F-\\uFF65]|\\uD800[\\uDD00-\\uDD02\\uDF9F\\uDFD0]|\\uD801\\uDD6F|\\uD802[\\uDC57\\uDD1F\\uDD3F\\uDE50-\\uDE58\\uDE7F\\uDEF0-\\uDEF6\\uDF39-\\uDF3F\\uDF99-\\uDF9C]|\\uD803[\\uDEAD\\uDF55-\\uDF59\\uDF86-\\uDF89]|\\uD804[\\uDC47-\\uDC4D\\uDCBB\\uDCBC\\uDCBE-\\uDCC1\\uDD40-\\uDD43\\uDD74\\uDD75\\uDDC5-\\uDDC8\\uDDCD\\uDDDB\\uDDDD-\\uDDDF\\uDE38-\\uDE3D\\uDEA9]|\\uD805[\\uDC4B-\\uDC4F\\uDC5A\\uDC5B\\uDC5D\\uDCC6\\uDDC1-\\uDDD7\\uDE41-\\uDE43\\uDE60-\\uDE6C\\uDEB9\\uDF3C-\\uDF3E]|\\uD806[\\uDC3B\\uDD44-\\uDD46\\uDDE2\\uDE3F-\\uDE46\\uDE9A-\\uDE9C\\uDE9E-\\uDEA2\\uDF00-\\uDF09]|\\uD807[\\uDC41-\\uDC45\\uDC70\\uDC71\\uDEF7\\uDEF8\\uDF43-\\uDF4F\\uDFFF]|\\uD809[\\uDC70-\\uDC74]|\\uD80B[\\uDFF1\\uDFF2]|\\uD81A[\\uDE6E\\uDE6F\\uDEF5\\uDF37-\\uDF3B\\uDF44]|\\uD81B[\\uDE97-\\uDE9A\\uDFE2]|\\uD82F\\uDC9F|\\uD836[\\uDE87-\\uDE8B]|\\uD83A[\\uDD5E\\uDD5F]/;\n\nvar regex$1 = /[\\$\\+<->\\^`\\|~\\xA2-\\xA6\\xA8\\xA9\\xAC\\xAE-\\xB1\\xB4\\xB8\\xD7\\xF7\\u02C2-\\u02C5\\u02D2-\\u02DF\\u02E5-\\u02EB\\u02ED\\u02EF-\\u02FF\\u0375\\u0384\\u0385\\u03F6\\u0482\\u058D-\\u058F\\u0606-\\u0608\\u060B\\u060E\\u060F\\u06DE\\u06E9\\u06FD\\u06FE\\u07F6\\u07FE\\u07FF\\u0888\\u09F2\\u09F3\\u09FA\\u09FB\\u0AF1\\u0B70\\u0BF3-\\u0BFA\\u0C7F\\u0D4F\\u0D79\\u0E3F\\u0F01-\\u0F03\\u0F13\\u0F15-\\u0F17\\u0F1A-\\u0F1F\\u0F34\\u0F36\\u0F38\\u0FBE-\\u0FC5\\u0FC7-\\u0FCC\\u0FCE\\u0FCF\\u0FD5-\\u0FD8\\u109E\\u109F\\u1390-\\u1399\\u166D\\u17DB\\u1940\\u19DE-\\u19FF\\u1B61-\\u1B6A\\u1B74-\\u1B7C\\u1FBD\\u1FBF-\\u1FC1\\u1FCD-\\u1FCF\\u1FDD-\\u1FDF\\u1FED-\\u1FEF\\u1FFD\\u1FFE\\u2044\\u2052\\u207A-\\u207C\\u208A-\\u208C\\u20A0-\\u20C0\\u2100\\u2101\\u2103-\\u2106\\u2108\\u2109\\u2114\\u2116-\\u2118\\u211E-\\u2123\\u2125\\u2127\\u2129\\u212E\\u213A\\u213B\\u2140-\\u2144\\u214A-\\u214D\\u214F\\u218A\\u218B\\u2190-\\u2307\\u230C-\\u2328\\u232B-\\u2426\\u2440-\\u244A\\u249C-\\u24E9\\u2500-\\u2767\\u2794-\\u27C4\\u27C7-\\u27E5\\u27F0-\\u2982\\u2999-\\u29D7\\u29DC-\\u29FB\\u29FE-\\u2B73\\u2B76-\\u2B95\\u2B97-\\u2BFF\\u2CE5-\\u2CEA\\u2E50\\u2E51\\u2E80-\\u2E99\\u2E9B-\\u2EF3\\u2F00-\\u2FD5\\u2FF0-\\u2FFF\\u3004\\u3012\\u3013\\u3020\\u3036\\u3037\\u303E\\u303F\\u309B\\u309C\\u3190\\u3191\\u3196-\\u319F\\u31C0-\\u31E3\\u31EF\\u3200-\\u321E\\u322A-\\u3247\\u3250\\u3260-\\u327F\\u328A-\\u32B0\\u32C0-\\u33FF\\u4DC0-\\u4DFF\\uA490-\\uA4C6\\uA700-\\uA716\\uA720\\uA721\\uA789\\uA78A\\uA828-\\uA82B\\uA836-\\uA839\\uAA77-\\uAA79\\uAB5B\\uAB6A\\uAB6B\\uFB29\\uFBB2-\\uFBC2\\uFD40-\\uFD4F\\uFDCF\\uFDFC-\\uFDFF\\uFE62\\uFE64-\\uFE66\\uFE69\\uFF04\\uFF0B\\uFF1C-\\uFF1E\\uFF3E\\uFF40\\uFF5C\\uFF5E\\uFFE0-\\uFFE6\\uFFE8-\\uFFEE\\uFFFC\\uFFFD]|\\uD800[\\uDD37-\\uDD3F\\uDD79-\\uDD89\\uDD8C-\\uDD8E\\uDD90-\\uDD9C\\uDDA0\\uDDD0-\\uDDFC]|\\uD802[\\uDC77\\uDC78\\uDEC8]|\\uD805\\uDF3F|\\uD807[\\uDFD5-\\uDFF1]|\\uD81A[\\uDF3C-\\uDF3F\\uDF45]|\\uD82F\\uDC9C|\\uD833[\\uDF50-\\uDFC3]|\\uD834[\\uDC00-\\uDCF5\\uDD00-\\uDD26\\uDD29-\\uDD64\\uDD6A-\\uDD6C\\uDD83\\uDD84\\uDD8C-\\uDDA9\\uDDAE-\\uDDEA\\uDE00-\\uDE41\\uDE45\\uDF00-\\uDF56]|\\uD835[\\uDEC1\\uDEDB\\uDEFB\\uDF15\\uDF35\\uDF4F\\uDF6F\\uDF89\\uDFA9\\uDFC3]|\\uD836[\\uDC00-\\uDDFF\\uDE37-\\uDE3A\\uDE6D-\\uDE74\\uDE76-\\uDE83\\uDE85\\uDE86]|\\uD838[\\uDD4F\\uDEFF]|\\uD83B[\\uDCAC\\uDCB0\\uDD2E\\uDEF0\\uDEF1]|\\uD83C[\\uDC00-\\uDC2B\\uDC30-\\uDC93\\uDCA0-\\uDCAE\\uDCB1-\\uDCBF\\uDCC1-\\uDCCF\\uDCD1-\\uDCF5\\uDD0D-\\uDDAD\\uDDE6-\\uDE02\\uDE10-\\uDE3B\\uDE40-\\uDE48\\uDE50\\uDE51\\uDE60-\\uDE65\\uDF00-\\uDFFF]|\\uD83D[\\uDC00-\\uDED7\\uDEDC-\\uDEEC\\uDEF0-\\uDEFC\\uDF00-\\uDF76\\uDF7B-\\uDFD9\\uDFE0-\\uDFEB\\uDFF0]|\\uD83E[\\uDC00-\\uDC0B\\uDC10-\\uDC47\\uDC50-\\uDC59\\uDC60-\\uDC87\\uDC90-\\uDCAD\\uDCB0\\uDCB1\\uDD00-\\uDE53\\uDE60-\\uDE6D\\uDE70-\\uDE7C\\uDE80-\\uDE88\\uDE90-\\uDEBD\\uDEBF-\\uDEC5\\uDECE-\\uDEDB\\uDEE0-\\uDEE8\\uDEF0-\\uDEF8\\uDF00-\\uDF92\\uDF94-\\uDFCA]/;\n\nvar regex = /[ \\xA0\\u1680\\u2000-\\u200A\\u2028\\u2029\\u202F\\u205F\\u3000]/;\n\nexports.Any = regex$5;\nexports.Cc = regex$4;\nexports.Cf = regex$3;\nexports.P = regex$2;\nexports.S = regex$1;\nexports.Z = regex;\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.b = document.baseURI || self.location.href;\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t792: 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n// no on chunks loaded\n\n// no jsonp function","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/**\n * A helper (module) giving an access to the global DOM objects such as `window` and\n * `document`. Accessing these objects using this helper allows easy and bulletproof\n * testing, i.e. stubbing native properties:\n *\n * ```ts\n * import { global } from 'ckeditor5/utils';\n *\n * // This stub will work for any code using global module.\n * testUtils.sinon.stub( global, 'window', {\n * \tinnerWidth: 10000\n * } );\n *\n * console.log( global.window.innerWidth );\n * ```\n */\nlet globalVar; // named globalVar instead of global: https://github.com/ckeditor/ckeditor5/issues/12971\n// In some environments window and document API might not be available.\ntry {\n globalVar = { window, document };\n}\ncatch (e) {\n // It's not possible to mock a window object to simulate lack of a window object without writing extremely convoluted code.\n /* istanbul ignore next -- @preserve */\n // Let's cast it to not change module's API.\n // We only handle this so loading editor in environments without window and document doesn't fail.\n // For better DX we shouldn't introduce mixed types and require developers to check the type manually.\n // This module should not be used on purpose in any environment outside browser.\n globalVar = { window: {}, document: {} };\n}\nexport default globalVar;\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/* globals navigator:false */\n/**\n * @module utils/env\n */\nimport global from './dom/global.js';\n/**\n * Safely returns `userAgent` from browser's navigator API in a lower case.\n * If navigator API is not available it will return an empty string.\n */\nexport function getUserAgent() {\n // In some environments navigator API might not be available.\n try {\n return navigator.userAgent.toLowerCase();\n }\n catch (e) {\n return '';\n }\n}\nconst userAgent = /* #__PURE__ */ getUserAgent();\n/**\n * A namespace containing environment and browser information.\n */\nconst env = {\n isMac: /* #__PURE__ */ isMac(userAgent),\n isWindows: /* #__PURE__ */ isWindows(userAgent),\n isGecko: /* #__PURE__ */ isGecko(userAgent),\n isSafari: /* #__PURE__ */ isSafari(userAgent),\n isiOS: /* #__PURE__ */ isiOS(userAgent),\n isAndroid: /* #__PURE__ */ isAndroid(userAgent),\n isBlink: /* #__PURE__ */ isBlink(userAgent),\n get isMediaForcedColors() {\n return isMediaForcedColors();\n },\n get isMotionReduced() {\n return isMotionReduced();\n },\n features: {\n isRegExpUnicodePropertySupported: /* #__PURE__ */ isRegExpUnicodePropertySupported()\n }\n};\nexport default env;\n/**\n * Checks if User Agent represented by the string is running on Macintosh.\n *\n * @param userAgent **Lowercase** `navigator.userAgent` string.\n * @returns Whether User Agent is running on Macintosh or not.\n */\nexport function isMac(userAgent) {\n return userAgent.indexOf('macintosh') > -1;\n}\n/**\n * Checks if User Agent represented by the string is running on Windows.\n *\n * @param userAgent **Lowercase** `navigator.userAgent` string.\n * @returns Whether User Agent is running on Windows or not.\n */\nexport function isWindows(userAgent) {\n return userAgent.indexOf('windows') > -1;\n}\n/**\n * Checks if User Agent represented by the string is Firefox (Gecko).\n *\n * @param userAgent **Lowercase** `navigator.userAgent` string.\n * @returns Whether User Agent is Firefox or not.\n */\nexport function isGecko(userAgent) {\n return !!userAgent.match(/gecko\\/\\d+/);\n}\n/**\n * Checks if User Agent represented by the string is Safari.\n *\n * @param userAgent **Lowercase** `navigator.userAgent` string.\n * @returns Whether User Agent is Safari or not.\n */\nexport function isSafari(userAgent) {\n return userAgent.indexOf(' applewebkit/') > -1 && userAgent.indexOf('chrome') === -1;\n}\n/**\n * Checks if User Agent represented by the string is running in iOS.\n *\n * @param userAgent **Lowercase** `navigator.userAgent` string.\n * @returns Whether User Agent is running in iOS or not.\n */\nexport function isiOS(userAgent) {\n // \"Request mobile site\" || \"Request desktop site\".\n return !!userAgent.match(/iphone|ipad/i) || (isMac(userAgent) && navigator.maxTouchPoints > 0);\n}\n/**\n * Checks if User Agent represented by the string is Android mobile device.\n *\n * @param userAgent **Lowercase** `navigator.userAgent` string.\n * @returns Whether User Agent is Safari or not.\n */\nexport function isAndroid(userAgent) {\n return userAgent.indexOf('android') > -1;\n}\n/**\n * Checks if User Agent represented by the string is Blink engine.\n *\n * @param userAgent **Lowercase** `navigator.userAgent` string.\n * @returns Whether User Agent is Blink engine or not.\n */\nexport function isBlink(userAgent) {\n // The Edge browser before switching to the Blink engine used to report itself as Chrome (and \"Edge/\")\n // but after switching to the Blink it replaced \"Edge/\" with \"Edg/\".\n return userAgent.indexOf('chrome/') > -1 && userAgent.indexOf('edge/') < 0;\n}\n/**\n * Checks if the current environment supports ES2018 Unicode properties like `\\p{P}` or `\\p{L}`.\n * More information about unicode properties might be found\n * [in Unicode Standard Annex #44](https://www.unicode.org/reports/tr44/#GC_Values_Table).\n */\nexport function isRegExpUnicodePropertySupported() {\n let isSupported = false;\n // Feature detection for Unicode properties. Added in ES2018. Currently Firefox does not support it.\n // See https://github.com/ckeditor/ckeditor5-mention/issues/44#issuecomment-487002174.\n try {\n // Usage of regular expression literal cause error during build (ckeditor/ckeditor5-dev#534).\n isSupported = 'ć'.search(new RegExp('[\\\\p{L}]', 'u')) === 0;\n }\n catch (error) {\n // Firefox throws a SyntaxError when the group is unsupported.\n }\n return isSupported;\n}\n/**\n * Checks if the user agent has enabled a forced colors mode (e.g. Windows High Contrast mode).\n *\n * Returns `false` in environments where `window` global object is not available.\n */\nexport function isMediaForcedColors() {\n return global.window.matchMedia ? global.window.matchMedia('(forced-colors: active)').matches : false;\n}\n/**\n * Checks if the user enabled \"prefers reduced motion\" setting in browser.\n *\n * Returns `false` in environments where `window` global object is not available.\n */\nexport function isMotionReduced() {\n return global.window.matchMedia ? global.window.matchMedia('(prefers-reduced-motion)').matches : false;\n}\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/**\n * @module utils/fastdiff\n */\n/**\n * Finds positions of the first and last change in the given string/array and generates a set of changes:\n *\n * ```ts\n * fastDiff( '12a', '12xyza' );\n * // [ { index: 2, type: 'insert', values: [ 'x', 'y', 'z' ] } ]\n *\n * fastDiff( '12a', '12aa' );\n * // [ { index: 3, type: 'insert', values: [ 'a' ] } ]\n *\n * fastDiff( '12xyza', '12a' );\n * // [ { index: 2, type: 'delete', howMany: 3 } ]\n *\n * fastDiff( [ '1', '2', 'a', 'a' ], [ '1', '2', 'a' ] );\n * // [ { index: 3, type: 'delete', howMany: 1 } ]\n *\n * fastDiff( [ '1', '2', 'a', 'b', 'c', '3' ], [ '2', 'a', 'b' ] );\n * // [ { index: 0, type: 'insert', values: [ '2', 'a', 'b' ] }, { index: 3, type: 'delete', howMany: 6 } ]\n * ```\n *\n * Passed arrays can contain any type of data, however to compare them correctly custom comparator function\n * should be passed as a third parameter:\n *\n * ```ts\n * fastDiff( [ { value: 1 }, { value: 2 } ], [ { value: 1 }, { value: 3 } ], ( a, b ) => {\n * \treturn a.value === b.value;\n * } );\n * // [ { index: 1, type: 'insert', values: [ { value: 3 } ] }, { index: 2, type: 'delete', howMany: 1 } ]\n * ```\n *\n * The resulted set of changes can be applied to the input in order to transform it into the output, for example:\n *\n * ```ts\n * let input = '12abc3';\n * const output = '2ab';\n * const changes = fastDiff( input, output );\n *\n * changes.forEach( change => {\n * \tif ( change.type == 'insert' ) {\n * \t\tinput = input.substring( 0, change.index ) + change.values.join( '' ) + input.substring( change.index );\n * \t} else if ( change.type == 'delete' ) {\n * \t\tinput = input.substring( 0, change.index ) + input.substring( change.index + change.howMany );\n * \t}\n * } );\n *\n * // input equals output now\n * ```\n *\n * or in case of arrays:\n *\n * ```ts\n * let input = [ '1', '2', 'a', 'b', 'c', '3' ];\n * const output = [ '2', 'a', 'b' ];\n * const changes = fastDiff( input, output );\n *\n * changes.forEach( change => {\n * \tif ( change.type == 'insert' ) {\n * \t\tinput = input.slice( 0, change.index ).concat( change.values, input.slice( change.index ) );\n * \t} else if ( change.type == 'delete' ) {\n * \t\tinput = input.slice( 0, change.index ).concat( input.slice( change.index + change.howMany ) );\n * \t}\n * } );\n *\n * // input equals output now\n * ```\n *\n * By passing `true` as the fourth parameter (`atomicChanges`) the output of this function will become compatible with\n * the {@link module:utils/diff~diff `diff()`} function:\n *\n * ```ts\n * fastDiff( '12a', '12xyza', undefined, true );\n * // [ 'equal', 'equal', 'insert', 'insert', 'insert', 'equal' ]\n * ```\n *\n * The default output format of this function is compatible with the output format of\n * {@link module:utils/difftochanges~diffToChanges `diffToChanges()`}. The `diffToChanges()` input format is, in turn,\n * compatible with the output of {@link module:utils/diff~diff `diff()`}:\n *\n * ```ts\n * const a = '1234';\n * const b = '12xyz34';\n *\n * // Both calls will return the same results (grouped changes format).\n * fastDiff( a, b );\n * diffToChanges( diff( a, b ) );\n *\n * // Again, both calls will return the same results (atomic changes format).\n * fastDiff( a, b, undefined, true );\n * diff( a, b );\n * ```\n *\n * @typeParam T The type of array elements.\n * @typeParam AtomicChanges The type of `atomicChanges` parameter (selects the result type).\n * @param a Input array or string.\n * @param b Input array or string.\n * @param cmp Optional function used to compare array values, by default `===` (strict equal operator) is used.\n * @param atomicChanges Whether an array of `inset|delete|equal` operations should\n * be returned instead of changes set. This makes this function compatible with {@link module:utils/diff~diff `diff()`}.\n * Defaults to `false`.\n * @returns Array of changes. The elements are either {@link module:utils/diff~DiffResult} or {@link module:utils/difftochanges~Change},\n * depending on `atomicChanges` parameter.\n */\nexport default function fastDiff(a, b, cmp, atomicChanges) {\n // Set the comparator function.\n cmp = cmp || function (a, b) {\n return a === b;\n };\n // Convert the string (or any array-like object - eg. NodeList) to an array by using the slice() method because,\n // unlike Array.from(), it returns array of UTF-16 code units instead of the code points of a string.\n // One code point might be a surrogate pair of two code units. All text offsets are expected to be in code units.\n // See ckeditor/ckeditor5#3147.\n //\n // We need to make sure here that fastDiff() works identical to diff().\n const arrayA = Array.isArray(a) ? a : Array.prototype.slice.call(a);\n const arrayB = Array.isArray(b) ? b : Array.prototype.slice.call(b);\n // Find first and last change.\n const changeIndexes = findChangeBoundaryIndexes(arrayA, arrayB, cmp);\n // Transform into changes array.\n const result = atomicChanges ?\n changeIndexesToAtomicChanges(changeIndexes, arrayB.length) :\n changeIndexesToChanges(arrayB, changeIndexes);\n return result;\n}\n/**\n * Finds position of the first and last change in the given arrays. For example:\n *\n * ```ts\n * const indexes = findChangeBoundaryIndexes( [ '1', '2', '3', '4' ], [ '1', '3', '4', '2', '4' ] );\n * console.log( indexes ); // { firstIndex: 1, lastIndexOld: 3, lastIndexNew: 4 }\n * ```\n *\n * The above indexes means that in the first array the modified part is `1[23]4` and in the second array it is `1[342]4`.\n * Based on such indexes, array with `insert`/`delete` operations which allows transforming first value into the second one\n * can be generated.\n */\nfunction findChangeBoundaryIndexes(arr1, arr2, cmp) {\n // Find the first difference between passed values.\n const firstIndex = findFirstDifferenceIndex(arr1, arr2, cmp);\n // If arrays are equal return -1 indexes object.\n if (firstIndex === -1) {\n return { firstIndex: -1, lastIndexOld: -1, lastIndexNew: -1 };\n }\n // Remove the common part of each value and reverse them to make it simpler to find the last difference between them.\n const oldArrayReversed = cutAndReverse(arr1, firstIndex);\n const newArrayReversed = cutAndReverse(arr2, firstIndex);\n // Find the first difference between reversed values.\n // It should be treated as \"how many elements from the end the last difference occurred\".\n //\n // For example:\n //\n // \t\t\t\tinitial\t->\tafter cut\t-> reversed:\n // oldValue:\t'321ba'\t->\t'21ba'\t\t-> 'ab12'\n // newValue:\t'31xba'\t->\t'1xba'\t\t-> 'abx1'\n // lastIndex:\t\t\t\t\t\t\t-> 2\n //\n // So the last change occurred two characters from the end of the arrays.\n const lastIndex = findFirstDifferenceIndex(oldArrayReversed, newArrayReversed, cmp);\n // Use `lastIndex` to calculate proper offset, starting from the beginning (`lastIndex` kind of starts from the end).\n const lastIndexOld = arr1.length - lastIndex;\n const lastIndexNew = arr2.length - lastIndex;\n return { firstIndex, lastIndexOld, lastIndexNew };\n}\n/**\n * Returns a first index on which given arrays differ. If both arrays are the same, -1 is returned.\n */\nfunction findFirstDifferenceIndex(arr1, arr2, cmp) {\n for (let i = 0; i < Math.max(arr1.length, arr2.length); i++) {\n if (arr1[i] === undefined || arr2[i] === undefined || !cmp(arr1[i], arr2[i])) {\n return i;\n }\n }\n return -1; // Return -1 if arrays are equal.\n}\n/**\n * Returns a copy of the given array with `howMany` elements removed starting from the beginning and in reversed order.\n *\n * @param arr Array to be processed.\n * @param howMany How many elements from array beginning to remove.\n * @returns Shortened and reversed array.\n */\nfunction cutAndReverse(arr, howMany) {\n return arr.slice(howMany).reverse();\n}\n/**\n * Generates changes array based on change indexes from `findChangeBoundaryIndexes` function. This function will\n * generate array with 0 (no changes), 1 (deletion or insertion) or 2 records (insertion and deletion).\n *\n * @param newArray New array for which change indexes were calculated.\n * @param changeIndexes Change indexes object from `findChangeBoundaryIndexes` function.\n * @returns Array of changes compatible with {@link module:utils/difftochanges~diffToChanges} format.\n */\nfunction changeIndexesToChanges(newArray, changeIndexes) {\n const result = [];\n const { firstIndex, lastIndexOld, lastIndexNew } = changeIndexes;\n // Order operations as 'insert', 'delete' array to keep compatibility with {@link module:utils/difftochanges~diffToChanges}\n // in most cases. However, 'diffToChanges' does not stick to any order so in some cases\n // (for example replacing '12345' with 'abcd') it will generate 'delete', 'insert' order.\n if (lastIndexNew - firstIndex > 0) {\n result.push({\n index: firstIndex,\n type: 'insert',\n values: newArray.slice(firstIndex, lastIndexNew)\n });\n }\n if (lastIndexOld - firstIndex > 0) {\n result.push({\n index: firstIndex + (lastIndexNew - firstIndex),\n type: 'delete',\n howMany: lastIndexOld - firstIndex\n });\n }\n return result;\n}\n/**\n * Generates array with set `equal|insert|delete` operations based on change indexes from `findChangeBoundaryIndexes` function.\n *\n * @param changeIndexes Change indexes object from `findChangeBoundaryIndexes` function.\n * @param newLength Length of the new array on which `findChangeBoundaryIndexes` calculated change indexes.\n * @returns Array of changes compatible with {@link module:utils/diff~diff} format.\n */\nfunction changeIndexesToAtomicChanges(changeIndexes, newLength) {\n const { firstIndex, lastIndexOld, lastIndexNew } = changeIndexes;\n // No changes.\n if (firstIndex === -1) {\n return Array(newLength).fill('equal');\n }\n let result = [];\n if (firstIndex > 0) {\n result = result.concat(Array(firstIndex).fill('equal'));\n }\n if (lastIndexNew - firstIndex > 0) {\n result = result.concat(Array(lastIndexNew - firstIndex).fill('insert'));\n }\n if (lastIndexOld - firstIndex > 0) {\n result = result.concat(Array(lastIndexOld - firstIndex).fill('delete'));\n }\n if (lastIndexNew < newLength) {\n result = result.concat(Array(newLength - lastIndexNew).fill('equal'));\n }\n return result;\n}\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/**\n * @module utils/diff\n */\nimport fastDiff from './fastdiff.js';\n// The following code is based on the \"O(NP) Sequence Comparison Algorithm\"\n// by Sun Wu, Udi Manber, Gene Myers, Webb Miller.\n/**\n * Calculates the difference between two arrays or strings producing an array containing a list of changes\n * necessary to transform input into output.\n *\n * ```ts\n * diff( 'aba', 'acca' ); // [ 'equal', 'insert', 'insert', 'delete', 'equal' ]\n * ```\n *\n * This function is based on the \"O(NP) Sequence Comparison Algorithm\" by Sun Wu, Udi Manber, Gene Myers, Webb Miller.\n * Unfortunately, while it gives the most precise results, its to complex for longer strings/arrow (above 200 items).\n * Therefore, `diff()` automatically switches to {@link module:utils/fastdiff~fastDiff `fastDiff()`} when detecting\n * such a scenario. The return formats of both functions are identical.\n *\n * @param a Input array or string.\n * @param b Output array or string.\n * @param cmp Optional function used to compare array values, by default === is used.\n * @returns Array of changes.\n */\nexport default function diff(a, b, cmp) {\n // Set the comparator function.\n cmp = cmp || function (a, b) {\n return a === b;\n };\n const aLength = a.length;\n const bLength = b.length;\n // Perform `fastDiff` for longer strings/arrays (see #269).\n if (aLength > 200 || bLength > 200 || aLength + bLength > 300) {\n return diff.fastDiff(a, b, cmp, true);\n }\n // Temporary action type statics.\n let _insert, _delete;\n // Swapped the arrays to use the shorter one as the first one.\n if (bLength < aLength) {\n const tmp = a;\n a = b;\n b = tmp;\n // We swap the action types as well.\n _insert = 'delete';\n _delete = 'insert';\n }\n else {\n _insert = 'insert';\n _delete = 'delete';\n }\n const m = a.length;\n const n = b.length;\n const delta = n - m;\n // Edit scripts, for each diagonal.\n const es = {};\n // Furthest points, the furthest y we can get on each diagonal.\n const fp = {};\n function snake(k) {\n // We use -1 as an alternative below to handle initial values ( instead of filling the fp with -1 first ).\n // Furthest points (y) on the diagonal below k.\n const y1 = (fp[k - 1] !== undefined ? fp[k - 1] : -1) + 1;\n // Furthest points (y) on the diagonal above k.\n const y2 = fp[k + 1] !== undefined ? fp[k + 1] : -1;\n // The way we should go to get further.\n const dir = y1 > y2 ? -1 : 1;\n // Clone previous changes array (if any).\n if (es[k + dir]) {\n es[k] = es[k + dir].slice(0);\n }\n // Create changes array.\n if (!es[k]) {\n es[k] = [];\n }\n // Push the action.\n es[k].push(y1 > y2 ? _insert : _delete);\n // Set the beginning coordinates.\n let y = Math.max(y1, y2);\n let x = y - k;\n // Traverse the diagonal as long as the values match.\n while (x < m && y < n && cmp(a[x], b[y])) {\n x++;\n y++;\n // Push no change action.\n es[k].push('equal');\n }\n return y;\n }\n let p = 0;\n let k;\n // Traverse the graph until we reach the end of the longer string.\n do {\n // Updates furthest points and edit scripts for diagonals below delta.\n for (k = -p; k < delta; k++) {\n fp[k] = snake(k);\n }\n // Updates furthest points and edit scripts for diagonals above delta.\n for (k = delta + p; k > delta; k--) {\n fp[k] = snake(k);\n }\n // Updates furthest point and edit script for the delta diagonal.\n // note that the delta diagonal is the one which goes through the sink (m, n).\n fp[delta] = snake(delta);\n p++;\n } while (fp[delta] !== n);\n // Return the final list of edit changes.\n // We remove the first item that represents the action for the injected nulls.\n return es[delta].slice(1);\n}\n// Store the API in static property to easily overwrite it in tests.\n// Too bad dependency injection does not work in Webpack + ES 6 (const) + Babel.\ndiff.fastDiff = fastDiff;\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/**\n * @module utils/spy\n */\n/**\n * Creates a spy function (ala Sinon.js) that can be used to inspect call to it.\n *\n * The following are the present features:\n *\n * * spy.called: property set to `true` if the function has been called at least once.\n *\n * @returns The spy function.\n */\nfunction spy() {\n return function spy() {\n spy.called = true;\n };\n}\nexport default spy;\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/**\n * @module utils/eventinfo\n */\nimport spy from './spy.js';\n/**\n * The event object passed to event callbacks. It is used to provide information about the event as well as a tool to\n * manipulate it.\n */\nexport default class EventInfo {\n /**\n * @param source The emitter.\n * @param name The event name.\n */\n constructor(source, name) {\n this.source = source;\n this.name = name;\n this.path = [];\n // The following methods are defined in the constructor because they must be re-created per instance.\n this.stop = spy();\n this.off = spy();\n }\n}\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/**\n * @module utils/uid\n */\n/**\n * A hash table of hex numbers to avoid using toString() in uid() which is costly.\n * [ '00', '01', '02', ..., 'fe', 'ff' ]\n */\nconst HEX_NUMBERS = new Array(256).fill('')\n .map((_, index) => ('0' + (index).toString(16)).slice(-2));\n/**\n * Returns a unique id. The id starts with an \"e\" character and a randomly generated string of\n * 32 alphanumeric characters.\n *\n * **Note**: The characters the unique id is built from correspond to the hex number notation\n * (from \"0\" to \"9\", from \"a\" to \"f\"). In other words, each id corresponds to an \"e\" followed\n * by 16 8-bit numbers next to each other.\n *\n * @returns An unique id string.\n */\nexport default function uid() {\n // Let's create some positive random 32bit integers first.\n //\n // 1. Math.random() is a float between 0 and 1.\n // 2. 0x100000000 is 2^32 = 4294967296.\n // 3. >>> 0 enforces integer (in JS all numbers are floating point).\n //\n // For instance:\n //\t\tMath.random() * 0x100000000 = 3366450031.853859\n // but\n //\t\tMath.random() * 0x100000000 >>> 0 = 3366450031.\n const r1 = Math.random() * 0x100000000 >>> 0;\n const r2 = Math.random() * 0x100000000 >>> 0;\n const r3 = Math.random() * 0x100000000 >>> 0;\n const r4 = Math.random() * 0x100000000 >>> 0;\n // Make sure that id does not start with number.\n return 'e' +\n HEX_NUMBERS[r1 >> 0 & 0xFF] +\n HEX_NUMBERS[r1 >> 8 & 0xFF] +\n HEX_NUMBERS[r1 >> 16 & 0xFF] +\n HEX_NUMBERS[r1 >> 24 & 0xFF] +\n HEX_NUMBERS[r2 >> 0 & 0xFF] +\n HEX_NUMBERS[r2 >> 8 & 0xFF] +\n HEX_NUMBERS[r2 >> 16 & 0xFF] +\n HEX_NUMBERS[r2 >> 24 & 0xFF] +\n HEX_NUMBERS[r3 >> 0 & 0xFF] +\n HEX_NUMBERS[r3 >> 8 & 0xFF] +\n HEX_NUMBERS[r3 >> 16 & 0xFF] +\n HEX_NUMBERS[r3 >> 24 & 0xFF] +\n HEX_NUMBERS[r4 >> 0 & 0xFF] +\n HEX_NUMBERS[r4 >> 8 & 0xFF] +\n HEX_NUMBERS[r4 >> 16 & 0xFF] +\n HEX_NUMBERS[r4 >> 24 & 0xFF];\n}\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/**\n * Provides group of constants to use instead of hardcoding numeric priority values.\n */\nconst priorities = {\n get(priority = 'normal') {\n if (typeof priority != 'number') {\n return this[priority] || this.normal;\n }\n else {\n return priority;\n }\n },\n highest: 100000,\n high: 1000,\n normal: 0,\n low: -1000,\n lowest: -100000\n};\nexport default priorities;\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\nimport priorities from './priorities.js';\n/**\n * Inserts any object with priority at correct index by priority so registered objects are always sorted from highest to lowest priority.\n *\n * @param objects Array of objects with priority to insert object to.\n * @param objectToInsert Object with `priority` property.\n */\nexport default function insertToPriorityArray(objects, objectToInsert) {\n const priority = priorities.get(objectToInsert.priority);\n for (let i = 0; i < objects.length; i++) {\n if (priorities.get(objects[i].priority) < priority) {\n objects.splice(i, 0, objectToInsert);\n return;\n }\n }\n objects.push(objectToInsert);\n}\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/**\n * @module utils/ckeditorerror\n */\n/* globals console */\n/**\n * URL to the documentation with error codes.\n */\nexport const DOCUMENTATION_URL = 'https://ckeditor.com/docs/ckeditor5/latest/support/error-codes.html';\n/**\n * The CKEditor error class.\n *\n * You should throw `CKEditorError` when:\n *\n * * An unexpected situation occurred and the editor (most probably) will not work properly. Such exception will be handled\n * by the {@link module:watchdog/watchdog~Watchdog watchdog} (if it is integrated),\n * * If the editor is incorrectly integrated or the editor API is used in the wrong way. This way you will give\n * feedback to the developer as soon as possible. Keep in mind that for common integration issues which should not\n * stop editor initialization (like missing upload adapter, wrong name of a toolbar component) we use\n * {@link module:utils/ckeditorerror~logWarning `logWarning()`} and\n * {@link module:utils/ckeditorerror~logError `logError()`}\n * to improve developers experience and let them see the a working editor as soon as possible.\n *\n * ```ts\n * /**\n * * Error thrown when a plugin cannot be loaded due to JavaScript errors, lack of plugins with a given name, etc.\n * *\n * * @error plugin-load\n * * @param pluginName The name of the plugin that could not be loaded.\n * * @param moduleName The name of the module which tried to load this plugin.\n * *\\/\n * throw new CKEditorError( 'plugin-load', {\n * \tpluginName: 'foo',\n * \tmoduleName: 'bar'\n * } );\n * ```\n */\nexport default class CKEditorError extends Error {\n /**\n * Creates an instance of the CKEditorError class.\n *\n * @param errorName The error id in an `error-name` format. A link to this error documentation page will be added\n * to the thrown error's `message`.\n * @param context A context of the error by which the {@link module:watchdog/watchdog~Watchdog watchdog}\n * is able to determine which editor crashed. It should be an editor instance or a property connected to it. It can be also\n * a `null` value if the editor should not be restarted in case of the error (e.g. during the editor initialization).\n * The error context should be checked using the `areConnectedThroughProperties( editor, context )` utility\n * to check if the object works as the context.\n * @param data Additional data describing the error. A stringified version of this object\n * will be appended to the error message, so the data are quickly visible in the console. The original\n * data object will also be later available under the {@link #data} property.\n */\n constructor(errorName, context, data) {\n super(getErrorMessage(errorName, data));\n this.name = 'CKEditorError';\n this.context = context;\n this.data = data;\n }\n /**\n * Checks if the error is of the `CKEditorError` type.\n */\n is(type) {\n return type === 'CKEditorError';\n }\n /**\n * A utility that ensures that the thrown error is a {@link module:utils/ckeditorerror~CKEditorError} one.\n * It is useful when combined with the {@link module:watchdog/watchdog~Watchdog} feature, which can restart the editor in case\n * of a {@link module:utils/ckeditorerror~CKEditorError} error.\n *\n * @param err The error to rethrow.\n * @param context An object connected through properties with the editor instance. This context will be used\n * by the watchdog to verify which editor should be restarted.\n */\n static rethrowUnexpectedError(err, context) {\n if (err.is && err.is('CKEditorError')) {\n throw err;\n }\n /**\n * An unexpected error occurred inside the CKEditor 5 codebase. This error will look like the original one\n * to make the debugging easier.\n *\n * This error is only useful when the editor is initialized using the {@link module:watchdog/watchdog~Watchdog} feature.\n * In case of such error (or any {@link module:utils/ckeditorerror~CKEditorError} error) the watchdog should restart the editor.\n *\n * @error unexpected-error\n */\n const error = new CKEditorError(err.message, context);\n // Restore the original stack trace to make the error look like the original one.\n // See https://github.com/ckeditor/ckeditor5/issues/5595 for more details.\n error.stack = err.stack;\n throw error;\n }\n}\n/**\n * Logs a warning to the console with a properly formatted message and adds a link to the documentation.\n * Use whenever you want to log a warning to the console.\n *\n * ```ts\n * /**\n * * There was a problem processing the configuration of the toolbar. The item with the given\n * * name does not exist, so it was omitted when rendering the toolbar.\n * *\n * * @error toolbarview-item-unavailable\n * * @param {String} name The name of the component.\n * *\\/\n * logWarning( 'toolbarview-item-unavailable', { name } );\n * ```\n *\n * See also {@link module:utils/ckeditorerror~CKEditorError} for an explanation when to throw an error and when to log\n * a warning or an error to the console.\n *\n * @param errorName The error name to be logged.\n * @param data Additional data to be logged.\n */\nexport function logWarning(errorName, data) {\n console.warn(...formatConsoleArguments(errorName, data));\n}\n/**\n * Logs an error to the console with a properly formatted message and adds a link to the documentation.\n * Use whenever you want to log an error to the console.\n *\n * ```ts\n * /**\n * * There was a problem processing the configuration of the toolbar. The item with the given\n * * name does not exist, so it was omitted when rendering the toolbar.\n * *\n * * @error toolbarview-item-unavailable\n * * @param {String} name The name of the component.\n * *\\/\n * logError( 'toolbarview-item-unavailable', { name } );\n * ```\n *\n * **Note**: In most cases logging a warning using {@link module:utils/ckeditorerror~logWarning} is enough.\n *\n * See also {@link module:utils/ckeditorerror~CKEditorError} for an explanation when to use each method.\n *\n * @param errorName The error name to be logged.\n * @param data Additional data to be logged.\n */\nexport function logError(errorName, data) {\n console.error(...formatConsoleArguments(errorName, data));\n}\n/**\n * Returns formatted link to documentation message.\n */\nfunction getLinkToDocumentationMessage(errorName) {\n return `\\nRead more: ${DOCUMENTATION_URL}#error-${errorName}`;\n}\n/**\n * Returns formatted error message.\n */\nfunction getErrorMessage(errorName, data) {\n const processedObjects = new WeakSet();\n const circularReferencesReplacer = (key, value) => {\n if (typeof value === 'object' && value !== null) {\n if (processedObjects.has(value)) {\n return `[object ${value.constructor.name}]`;\n }\n processedObjects.add(value);\n }\n return value;\n };\n const stringifiedData = data ? ` ${JSON.stringify(data, circularReferencesReplacer)}` : '';\n const documentationLink = getLinkToDocumentationMessage(errorName);\n return errorName + stringifiedData + documentationLink;\n}\n/**\n * Returns formatted console error arguments.\n */\nfunction formatConsoleArguments(errorName, data) {\n const documentationMessage = getLinkToDocumentationMessage(errorName);\n return data ? [errorName, data, documentationMessage] : [errorName, documentationMessage];\n}\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/**\n * @module utils/version\n */\nimport CKEditorError from './ckeditorerror.js';\nconst version = '43.0.0';\nexport default version;\n// The second argument is not a month. It is `monthIndex` and starts from `0`.\nexport const releaseDate = new Date(2024, 7, 7);\n/* istanbul ignore next -- @preserve */\nif (globalThis.CKEDITOR_VERSION) {\n /**\n * The best solution to avoid this error is migrating your CKEditor 5 instance to\n * {@glink updating/nim-migration/migration-to-new-installation-methods new installation methods}.\n *\n * Mentioned below are predefined builds, which are a deprecated installation method. The solutions\n * provided are kept here for legacy support only.\n *\n * This error is thrown when due to a mistake in how CKEditor 5 was installed or initialized, some\n * of its modules were duplicated (evaluated and executed twice). Module duplication leads to inevitable runtime\n * errors.\n *\n * There are many situations in which some modules can be loaded twice. In the worst case scenario,\n * you may need to check your project for each of these issues and fix them all.\n *\n * # Trying to add a plugin to an existing build\n *\n * If you import an existing CKEditor 5 build and a plugin like this:\n *\n * ```ts\n * import ClassicEditor from '@ckeditor/ckeditor5-build-classic';\n * import Highlight from '@ckeditor/ckeditor5-highlight/src/highlight';\n * ```\n *\n * Then your project loads some CKEditor 5 packages twice. How does it happen?\n *\n * The build package contains a file which is already compiled with webpack. This means\n * that it contains all the necessary code from e.g. `@ckeditor/ckeditor5-engine` and `@ckeditor/ckeditor5-utils`.\n *\n * However, the `Highlight` plugin imports some of the modules from these packages, too. If you ask webpack to\n * build such a project, you will end up with the modules being included (and run) twice – first, because they are\n * included inside the build package, and second, because they are required by the `Highlight` plugin.\n *\n * Therefore, **you must never add plugins to an existing build** unless your plugin has no dependencies.\n *\n * Adding plugins to a build is done by taking the source version of this build (so, before it was built with webpack)\n * and adding plugins there. In this situation, webpack will know that it only needs to load each plugin once.\n *\n * # Confused an editor build with an editor implementation\n *\n * This scenario is very similar to the previous one, but has a different origin.\n *\n * Let's assume that you wanted to use CKEditor 5 from source.\n *\n * The correct way to do so is to import an editor and plugins and run them together like this:\n *\n * ```ts\n * import ClassicEditor from '@ckeditor/ckeditor5-editor-classic/src/classiceditor';\n * import Essentials from '@ckeditor/ckeditor5-essentials/src/essentials';\n * import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';\n * import Bold from '@ckeditor/ckeditor5-basic-styles/src/bold';\n * import Italic from '@ckeditor/ckeditor5-basic-styles/src/italic';\n *\n * ClassicEditor\n * \t.create( document.querySelector( '#editor' ), {\n * \t\tplugins: [ Essentials, Paragraph, Bold, Italic ],\n * \t\ttoolbar: [ 'bold', 'italic' ]\n * \t} )\n * \t.then( editor => {\n * \t\tconsole.log( 'Editor was initialized', editor );\n * \t} )\n * \t.catch( error => {\n * \t\tconsole.error( error.stack );\n * \t} );\n * ```\n *\n * However, you might have mistakenly imported a build instead of the source `ClassicEditor`. In this case\n * your imports will look like this:\n *\n * ```ts\n * import ClassicEditor from '@ckeditor/ckeditor5-build-classic';\n * import Essentials from '@ckeditor/ckeditor5-essentials/src/essentials';\n * import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';\n * import Bold from '@ckeditor/ckeditor5-basic-styles/src/bold';\n * import Italic from '@ckeditor/ckeditor5-basic-styles/src/italic';\n * ```\n *\n * This creates the same situation as in the previous section because you use a build together with source plugins.\n *\n * Remember: `@ckeditor/ckeditor5-build-*` packages contain editor builds and `@ckeditor/ckeditor5-editor-*` contain source editors.\n *\n * # Loading two or more builds on one page\n *\n * If you use CKEditor 5 builds, you might have loaded two (or more) `ckeditor.js` files on one web page.\n * Check your web page for duplicated `