@progress/kendo-angular-editor 3.1.2 → 4.0.0-dev.202204140850
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/kendo-angular-editor.umd.js +5 -0
- package/{dist/es2015/common → common}/active-marks.d.ts +0 -0
- package/{dist/es2015/common → common}/apply-to-word-options.d.ts +0 -0
- package/{dist/es2015/common → common}/commands.d.ts +0 -0
- package/{dist/es2015/common → common}/direction.d.ts +0 -0
- package/{dist/es2015/common → common}/error-messages.d.ts +0 -0
- package/{dist/es2015/common → common}/font-family-item.interface.d.ts +0 -0
- package/{dist/es2015/common → common}/font-size-item.interface.d.ts +0 -0
- package/{dist/es2015/common → common}/format-item.interface.d.ts +0 -0
- package/{dist/es2015/common → common}/image-data.interface.d.ts +0 -0
- package/{dist/es2015/common → common}/link-data.interface.d.ts +0 -0
- package/{dist/es2015/common → common}/paste-cleanup-settings.d.ts +0 -0
- package/{dist/es2015/common → common}/plugins-function.d.ts +0 -1
- package/{dist/es2015/common → common}/predicate.d.ts +0 -0
- package/common/provider.service.d.ts +14 -0
- package/{dist/es2015/common → common}/resizable-options.interface.d.ts +0 -0
- package/{dist/es2015/common → common}/styles.d.ts +0 -0
- package/{dist/es2015/common → common}/table-data.interface.d.ts +0 -0
- package/{dist/es2015/config → config}/command-icons.d.ts +0 -0
- package/{dist/es2015/config → config}/commands.d.ts +0 -0
- package/{dist/es2015/config → config}/schema.d.ts +0 -0
- package/{dist/es2015/config → config}/semantic-nodes.d.ts +0 -0
- package/{dist/es2015/config → config}/table-commands.d.ts +0 -0
- package/{dist/es2015/config → config}/utils.d.ts +8 -8
- package/{dist/es2015/dialogs → dialogs}/colorpicker-dialog.component.d.ts +3 -0
- package/{dist/es2015/dialogs → dialogs}/file-link-dialog.component.d.ts +4 -1
- package/{dist/es2015/dialogs → dialogs}/font-family-dialog.component.d.ts +3 -0
- package/{dist/es2015/dialogs → dialogs}/font-size-dialog.component.d.ts +3 -0
- package/{dist/es2015/dialogs → dialogs}/format-dialog.component.d.ts +4 -1
- package/{dist/es2015/dialogs → dialogs}/image-dialog.component.d.ts +3 -0
- package/{dist/es2015/dialogs → dialogs}/insert-table-dialog.component.d.ts +5 -4
- package/{dist/es2015/dialogs → dialogs}/source-dialog.component.d.ts +3 -0
- package/{dist/es2015/editor-toolbar-state.d.ts → editor-toolbar-state.d.ts} +1 -1
- package/{dist/es2015/editor.component.d.ts → editor.component.d.ts} +32 -20
- package/editor.module.d.ts +113 -0
- package/{dist/es2015 → esm2015}/common/active-marks.js +1 -0
- package/{dist/es2015 → esm2015}/common/apply-to-word-options.js +1 -0
- package/{dist/es → esm2015}/common/commands.js +1 -0
- package/{dist/es2015 → esm2015}/common/direction.js +1 -0
- package/{dist/es2015 → esm2015}/common/error-messages.js +2 -5
- package/{dist/es → esm2015}/common/font-family-item.interface.js +1 -0
- package/{dist/es → esm2015}/common/font-size-item.interface.js +1 -0
- package/{dist/es → esm2015}/common/format-item.interface.js +1 -0
- package/{dist/es → esm2015}/common/image-data.interface.js +1 -0
- package/{dist/es → esm2015}/common/link-data.interface.js +1 -0
- package/{dist/es → esm2015}/common/paste-cleanup-settings.js +1 -0
- package/{dist/es → esm2015}/common/plugins-function.js +1 -0
- package/{dist/es → esm2015}/common/predicate.js +1 -0
- package/esm2015/common/provider.service.js +16 -0
- package/{dist/es → esm2015}/common/resizable-options.interface.js +1 -0
- package/{dist/es2015 → esm2015}/common/styles.js +0 -0
- package/{dist/es → esm2015}/common/table-data.interface.js +1 -0
- package/{dist/es2015 → esm2015}/config/command-icons.js +0 -0
- package/esm2015/config/commands.js +62 -0
- package/{dist/es2015 → esm2015}/config/schema.js +0 -0
- package/{dist/es2015 → esm2015}/config/semantic-nodes.js +1 -4
- package/{dist/es2015 → esm2015}/config/table-commands.js +0 -0
- package/{dist/es2015 → esm2015}/config/utils.js +1 -1
- package/esm2015/dialogs/colorpicker-dialog.component.js +117 -0
- package/esm2015/dialogs/file-link-dialog.component.js +209 -0
- package/esm2015/dialogs/font-family-dialog.component.js +106 -0
- package/esm2015/dialogs/font-size-dialog.component.js +106 -0
- package/esm2015/dialogs/format-dialog.component.js +106 -0
- package/{dist/es2015 → esm2015}/dialogs/image-dialog.component.js +60 -21
- package/esm2015/dialogs/insert-table-dialog.component.js +74 -0
- package/esm2015/dialogs/source-dialog.component.js +89 -0
- package/{dist/es2015 → esm2015}/editor-toolbar-state.js +0 -0
- package/{dist/es2015 → esm2015}/editor.component.js +331 -200
- package/{dist/es2015 → esm2015}/editor.module.js +205 -31
- package/{dist/es/common/active-marks.js → esm2015/kendo-angular-editor.js} +4 -0
- package/esm2015/localization/custom-messages.component.js +41 -0
- package/esm2015/localization/editor-localization.service.js +31 -0
- package/esm2015/localization/localized-messages.directive.js +32 -0
- package/esm2015/localization/messages.js +126 -0
- package/{dist/es2015/index.js → esm2015/main.js} +37 -47
- package/{dist/es2015 → esm2015}/package-metadata.js +1 -1
- package/{dist/es → esm2015}/preventable-events/paste-event-data.js +1 -0
- package/{dist/es2015 → esm2015}/preventable-events/paste-event.js +1 -1
- package/esm2015/preventable-events/preventable-event.js +27 -0
- package/esm2015/tools/alignment/editor-align-center-button.directive.js +42 -0
- package/esm2015/tools/alignment/editor-align-justify-button.directive.js +42 -0
- package/esm2015/tools/alignment/editor-align-left-button.directive.js +42 -0
- package/esm2015/tools/alignment/editor-align-right-button.directive.js +42 -0
- package/esm2015/tools/blockquote/editor-blockquote-button.directive.js +41 -0
- package/esm2015/tools/colorpicker/editor-back-color.directive.js +28 -0
- package/esm2015/tools/colorpicker/editor-colorpicker.component.js +262 -0
- package/esm2015/tools/colorpicker/editor-fore-color.directive.js +28 -0
- package/esm2015/tools/editor-clean-formatting-button.directive.js +41 -0
- package/esm2015/tools/fontfamily/editor-fontfamily-dropdownlist.component.js +104 -0
- package/{dist/es2015 → esm2015}/tools/fontfamily/editor-fontfamily.component.js +73 -57
- package/esm2015/tools/fontsize/editor-fontsize-dropdownlist.component.js +93 -0
- package/{dist/es2015 → esm2015}/tools/fontsize/editor-fontsize.component.js +72 -54
- package/esm2015/tools/format/editor-format-dropdownlist.component.js +160 -0
- package/{dist/es2015 → esm2015}/tools/format/editor-format.component.js +69 -51
- package/esm2015/tools/history/editor-redo-button.directive.js +42 -0
- package/esm2015/tools/history/editor-undo-button.directive.js +42 -0
- package/esm2015/tools/image/editor-insert-image-button.directive.js +41 -0
- package/esm2015/tools/indentation/editor-indent-button.directive.js +42 -0
- package/esm2015/tools/indentation/editor-outdent-button.directive.js +42 -0
- package/esm2015/tools/link/editor-create-link-button.directive.js +42 -0
- package/esm2015/tools/link/editor-insert-file-button.directive.js +34 -0
- package/esm2015/tools/link/editor-unlink-button.directive.js +42 -0
- package/esm2015/tools/list/editor-insert-ordered-list-button.directive.js +42 -0
- package/esm2015/tools/list/editor-insert-unordered-list-button.directive.js +42 -0
- package/{dist/es2015 → esm2015}/tools/print/editor-print-button.directive.js +18 -22
- package/esm2015/tools/select-all/select-all-button.directive.js +45 -0
- package/{dist/es2015 → esm2015}/tools/shared/dropdown-tool.directive.js +10 -10
- package/esm2015/tools/shared/editor-command-base.js +64 -0
- package/{dist/es2015 → esm2015}/tools/shared/editor-command-button.js +5 -5
- package/{dist/es2015 → esm2015}/tools/shared/editor-command-dialog.js +4 -5
- package/esm2015/tools/source/editor-view-source-button.directive.js +41 -0
- package/esm2015/tools/tables/editor-add-column-after-button.directive.js +35 -0
- package/esm2015/tools/tables/editor-add-column-before-button.directive.js +35 -0
- package/esm2015/tools/tables/editor-add-row-after-button.directive.js +35 -0
- package/esm2015/tools/tables/editor-add-row-before-button.directive.js +35 -0
- package/esm2015/tools/tables/editor-delete-column-button.directive.js +35 -0
- package/esm2015/tools/tables/editor-delete-row-button.directive.js +35 -0
- package/esm2015/tools/tables/editor-delete-table-button.directive.js +35 -0
- package/{dist/es2015 → esm2015}/tools/tables/editor-insert-table-button.component.js +66 -45
- package/esm2015/tools/tables/editor-merge-cells-button.directive.js +37 -0
- package/esm2015/tools/tables/editor-split-cell-button.directive.js +37 -0
- package/{dist/es2015 → esm2015}/tools/tables/popup-table-grid.component.js +32 -21
- package/esm2015/tools/tools.service.js +20 -0
- package/esm2015/tools/typographical-emphasis/editor-bold-button.directive.js +42 -0
- package/esm2015/tools/typographical-emphasis/editor-italic-button.directive.js +42 -0
- package/esm2015/tools/typographical-emphasis/editor-strikethrough-button.directive.js +42 -0
- package/esm2015/tools/typographical-emphasis/editor-subscript-button.directive.js +42 -0
- package/esm2015/tools/typographical-emphasis/editor-superscript-button.directive.js +42 -0
- package/esm2015/tools/typographical-emphasis/editor-underline-button.directive.js +42 -0
- package/{dist/es2015 → esm2015}/util.js +8 -0
- package/fesm2015/kendo-angular-editor.js +6396 -0
- package/kendo-angular-editor.d.ts +9 -0
- package/{dist/es2015/localization → localization}/custom-messages.component.d.ts +6 -3
- package/{dist/es2015/localization → localization}/editor-localization.service.d.ts +3 -0
- package/{dist/es2015/localization → localization}/localized-messages.directive.d.ts +5 -2
- package/{dist/es2015/localization → localization}/messages.d.ts +4 -1
- package/{dist/es/index.js → main.d.ts} +39 -47
- package/{dist/es2015/package-metadata.d.ts → package-metadata.d.ts} +0 -0
- package/package.json +44 -121
- package/{dist/es2015/preventable-events → preventable-events}/paste-event-data.d.ts +0 -0
- package/{dist/es2015/preventable-events → preventable-events}/paste-event.d.ts +1 -1
- package/preventable-events/preventable-event.d.ts +21 -0
- package/schematics/ngAdd/index.js +5 -2
- package/schematics/ngAdd/index.js.map +1 -1
- package/{dist/es2015/tools → tools}/alignment/editor-align-center-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/alignment/editor-align-justify-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/alignment/editor-align-left-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/alignment/editor-align-right-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/blockquote/editor-blockquote-button.directive.d.ts +5 -3
- package/{dist/es2015/tools → tools}/colorpicker/editor-back-color.directive.d.ts +3 -0
- package/{dist/es2015/tools → tools}/colorpicker/editor-colorpicker.component.d.ts +10 -6
- package/{dist/es2015/tools → tools}/colorpicker/editor-fore-color.directive.d.ts +3 -0
- package/{dist/es2015/tools → tools}/editor-clean-formatting-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/fontfamily/editor-fontfamily-dropdownlist.component.d.ts +3 -0
- package/{dist/es2015/tools → tools}/fontfamily/editor-fontfamily.component.d.ts +10 -6
- package/{dist/es2015/tools → tools}/fontsize/editor-fontsize-dropdownlist.component.d.ts +3 -0
- package/{dist/es2015/tools → tools}/fontsize/editor-fontsize.component.d.ts +10 -6
- package/{dist/es2015/tools → tools}/format/editor-format-dropdownlist.component.d.ts +3 -0
- package/{dist/es2015/tools → tools}/format/editor-format.component.d.ts +10 -6
- package/{dist/es2015/tools → tools}/history/editor-redo-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/history/editor-undo-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/image/editor-insert-image-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/indentation/editor-indent-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/indentation/editor-outdent-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/link/editor-create-link-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/link/editor-insert-file-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/link/editor-unlink-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/list/editor-insert-ordered-list-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/list/editor-insert-unordered-list-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/print/editor-print-button.directive.d.ts +5 -3
- package/{dist/es2015/tools → tools}/select-all/select-all-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/shared/dropdown-tool.directive.d.ts +4 -1
- package/{dist/es2015/tools → tools}/shared/editor-command-base.d.ts +8 -4
- package/{dist/es2015/tools → tools}/shared/editor-command-button.d.ts +5 -5
- package/{dist/es2015/tools → tools}/shared/editor-command-dialog.d.ts +4 -5
- package/{dist/es2015/tools → tools}/source/editor-view-source-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/tables/editor-add-column-after-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/tables/editor-add-column-before-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/tables/editor-add-row-after-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/tables/editor-add-row-before-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/tables/editor-delete-column-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/tables/editor-delete-row-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/tables/editor-delete-table-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/tables/editor-insert-table-button.component.d.ts +10 -9
- package/{dist/es2015/tools → tools}/tables/editor-merge-cells-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/tables/editor-split-cell-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/tables/popup-table-grid.component.d.ts +7 -6
- package/{dist/es2015/tools → tools}/tools.service.d.ts +3 -0
- package/{dist/es2015/tools → tools}/typographical-emphasis/editor-bold-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/typographical-emphasis/editor-italic-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/typographical-emphasis/editor-strikethrough-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/typographical-emphasis/editor-subscript-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/typographical-emphasis/editor-superscript-button.directive.d.ts +5 -2
- package/{dist/es2015/tools → tools}/typographical-emphasis/editor-underline-button.directive.d.ts +5 -2
- package/{dist/es2015/util.d.ts → util.d.ts} +7 -0
- package/dist/cdn/js/kendo-angular-editor.js +0 -20
- package/dist/cdn/main.js +0 -5
- package/dist/es/common/apply-to-word-options.js +0 -4
- package/dist/es/common/direction.js +0 -4
- package/dist/es/common/error-messages.js +0 -19
- package/dist/es/common/styles.js +0 -16
- package/dist/es/config/command-icons.js +0 -48
- package/dist/es/config/commands.js +0 -71
- package/dist/es/config/schema.js +0 -22
- package/dist/es/config/semantic-nodes.js +0 -32
- package/dist/es/config/table-commands.js +0 -14
- package/dist/es/config/utils.js +0 -102
- package/dist/es/dialogs/colorpicker-dialog.component.js +0 -70
- package/dist/es/dialogs/file-link-dialog.component.js +0 -126
- package/dist/es/dialogs/font-family-dialog.component.js +0 -65
- package/dist/es/dialogs/font-size-dialog.component.js +0 -65
- package/dist/es/dialogs/format-dialog.component.js +0 -65
- package/dist/es/dialogs/image-dialog.component.js +0 -102
- package/dist/es/dialogs/insert-table-dialog.component.js +0 -49
- package/dist/es/dialogs/source-dialog.component.js +0 -72
- package/dist/es/editor-toolbar-state.js +0 -280
- package/dist/es/editor.component.js +0 -1039
- package/dist/es/editor.module.js +0 -241
- package/dist/es/localization/custom-messages.component.js +0 -45
- package/dist/es/localization/editor-localization.service.js +0 -24
- package/dist/es/localization/localized-messages.directive.js +0 -36
- package/dist/es/localization/messages.js +0 -230
- package/dist/es/main.js +0 -9
- package/dist/es/package-metadata.js +0 -15
- package/dist/es/preventable-events/paste-event.js +0 -25
- package/dist/es/tools/alignment/editor-align-center-button.directive.js +0 -47
- package/dist/es/tools/alignment/editor-align-justify-button.directive.js +0 -47
- package/dist/es/tools/alignment/editor-align-left-button.directive.js +0 -47
- package/dist/es/tools/alignment/editor-align-right-button.directive.js +0 -47
- package/dist/es/tools/blockquote/editor-blockquote-button.directive.js +0 -48
- package/dist/es/tools/colorpicker/editor-back-color.directive.js +0 -28
- package/dist/es/tools/colorpicker/editor-colorpicker.component.js +0 -233
- package/dist/es/tools/colorpicker/editor-fore-color.directive.js +0 -28
- package/dist/es/tools/editor-clean-formatting-button.directive.js +0 -46
- package/dist/es/tools/fontfamily/editor-fontfamily-dropdownlist.component.js +0 -71
- package/dist/es/tools/fontfamily/editor-fontfamily.component.js +0 -211
- package/dist/es/tools/fontsize/editor-fontsize-dropdownlist.component.js +0 -71
- package/dist/es/tools/fontsize/editor-fontsize.component.js +0 -206
- package/dist/es/tools/format/editor-format-dropdownlist.component.js +0 -71
- package/dist/es/tools/format/editor-format.component.js +0 -202
- package/dist/es/tools/history/editor-redo-button.directive.js +0 -47
- package/dist/es/tools/history/editor-undo-button.directive.js +0 -47
- package/dist/es/tools/image/editor-insert-image-button.directive.js +0 -46
- package/dist/es/tools/indentation/editor-indent-button.directive.js +0 -47
- package/dist/es/tools/indentation/editor-outdent-button.directive.js +0 -47
- package/dist/es/tools/link/editor-create-link-button.directive.js +0 -47
- package/dist/es/tools/link/editor-insert-file-button.directive.js +0 -39
- package/dist/es/tools/link/editor-unlink-button.directive.js +0 -47
- package/dist/es/tools/list/editor-insert-ordered-list-button.directive.js +0 -47
- package/dist/es/tools/list/editor-insert-unordered-list-button.directive.js +0 -47
- package/dist/es/tools/print/editor-print-button.directive.js +0 -69
- package/dist/es/tools/select-all/select-all-button.directive.js +0 -50
- package/dist/es/tools/shared/dropdown-tool.directive.js +0 -41
- package/dist/es/tools/shared/editor-command-base.js +0 -49
- package/dist/es/tools/shared/editor-command-button.js +0 -34
- package/dist/es/tools/shared/editor-command-dialog.js +0 -30
- package/dist/es/tools/source/editor-view-source-button.directive.js +0 -46
- package/dist/es/tools/tables/editor-add-column-after-button.directive.js +0 -40
- package/dist/es/tools/tables/editor-add-column-before-button.directive.js +0 -40
- package/dist/es/tools/tables/editor-add-row-after-button.directive.js +0 -40
- package/dist/es/tools/tables/editor-add-row-before-button.directive.js +0 -40
- package/dist/es/tools/tables/editor-delete-column-button.directive.js +0 -40
- package/dist/es/tools/tables/editor-delete-row-button.directive.js +0 -40
- package/dist/es/tools/tables/editor-delete-table-button.directive.js +0 -40
- package/dist/es/tools/tables/editor-insert-table-button.component.js +0 -202
- package/dist/es/tools/tables/editor-merge-cells-button.directive.js +0 -42
- package/dist/es/tools/tables/editor-split-cell-button.directive.js +0 -42
- package/dist/es/tools/tables/popup-table-grid.component.js +0 -69
- package/dist/es/tools/tools.service.js +0 -20
- package/dist/es/tools/typographical-emphasis/editor-bold-button.directive.js +0 -47
- package/dist/es/tools/typographical-emphasis/editor-italic-button.directive.js +0 -47
- package/dist/es/tools/typographical-emphasis/editor-strikethrough-button.directive.js +0 -47
- package/dist/es/tools/typographical-emphasis/editor-subscript-button.directive.js +0 -47
- package/dist/es/tools/typographical-emphasis/editor-superscript-button.directive.js +0 -47
- package/dist/es/tools/typographical-emphasis/editor-underline-button.directive.js +0 -47
- package/dist/es/util.js +0 -127
- package/dist/es2015/common/commands.js +0 -4
- package/dist/es2015/common/font-family-item.interface.js +0 -4
- package/dist/es2015/common/font-size-item.interface.js +0 -4
- package/dist/es2015/common/format-item.interface.js +0 -4
- package/dist/es2015/common/image-data.interface.js +0 -4
- package/dist/es2015/common/link-data.interface.js +0 -4
- package/dist/es2015/common/paste-cleanup-settings.js +0 -4
- package/dist/es2015/common/plugins-function.js +0 -4
- package/dist/es2015/common/predicate.js +0 -4
- package/dist/es2015/common/resizable-options.interface.js +0 -4
- package/dist/es2015/common/table-data.interface.js +0 -4
- package/dist/es2015/config/commands.js +0 -67
- package/dist/es2015/dialogs/colorpicker-dialog.component.js +0 -92
- package/dist/es2015/dialogs/file-link-dialog.component.js +0 -163
- package/dist/es2015/dialogs/font-family-dialog.component.js +0 -84
- package/dist/es2015/dialogs/font-size-dialog.component.js +0 -84
- package/dist/es2015/dialogs/format-dialog.component.js +0 -84
- package/dist/es2015/dialogs/insert-table-dialog.component.js +0 -60
- package/dist/es2015/dialogs/source-dialog.component.js +0 -81
- package/dist/es2015/editor.module.d.ts +0 -45
- package/dist/es2015/index.d.ts +0 -72
- package/dist/es2015/index.metadata.json +0 -1
- package/dist/es2015/localization/custom-messages.component.js +0 -37
- package/dist/es2015/localization/editor-localization.service.js +0 -22
- package/dist/es2015/localization/localized-messages.directive.js +0 -32
- package/dist/es2015/localization/messages.js +0 -224
- package/dist/es2015/main.d.ts +0 -13
- package/dist/es2015/main.js +0 -9
- package/dist/es2015/preventable-events/paste-event-data.js +0 -4
- package/dist/es2015/tools/alignment/editor-align-center-button.directive.js +0 -45
- package/dist/es2015/tools/alignment/editor-align-justify-button.directive.js +0 -45
- package/dist/es2015/tools/alignment/editor-align-left-button.directive.js +0 -45
- package/dist/es2015/tools/alignment/editor-align-right-button.directive.js +0 -45
- package/dist/es2015/tools/blockquote/editor-blockquote-button.directive.js +0 -45
- package/dist/es2015/tools/colorpicker/editor-back-color.directive.js +0 -27
- package/dist/es2015/tools/colorpicker/editor-colorpicker.component.js +0 -249
- package/dist/es2015/tools/colorpicker/editor-fore-color.directive.js +0 -27
- package/dist/es2015/tools/editor-clean-formatting-button.directive.js +0 -44
- package/dist/es2015/tools/fontfamily/editor-fontfamily-dropdownlist.component.js +0 -99
- package/dist/es2015/tools/fontsize/editor-fontsize-dropdownlist.component.js +0 -94
- package/dist/es2015/tools/format/editor-format-dropdownlist.component.js +0 -127
- package/dist/es2015/tools/history/editor-redo-button.directive.js +0 -45
- package/dist/es2015/tools/history/editor-undo-button.directive.js +0 -45
- package/dist/es2015/tools/image/editor-insert-image-button.directive.js +0 -44
- package/dist/es2015/tools/indentation/editor-indent-button.directive.js +0 -45
- package/dist/es2015/tools/indentation/editor-outdent-button.directive.js +0 -45
- package/dist/es2015/tools/link/editor-create-link-button.directive.js +0 -45
- package/dist/es2015/tools/link/editor-insert-file-button.directive.js +0 -37
- package/dist/es2015/tools/link/editor-unlink-button.directive.js +0 -45
- package/dist/es2015/tools/list/editor-insert-ordered-list-button.directive.js +0 -45
- package/dist/es2015/tools/list/editor-insert-unordered-list-button.directive.js +0 -45
- package/dist/es2015/tools/select-all/select-all-button.directive.js +0 -48
- package/dist/es2015/tools/shared/editor-command-base.js +0 -46
- package/dist/es2015/tools/source/editor-view-source-button.directive.js +0 -44
- package/dist/es2015/tools/tables/editor-add-column-after-button.directive.js +0 -38
- package/dist/es2015/tools/tables/editor-add-column-before-button.directive.js +0 -38
- package/dist/es2015/tools/tables/editor-add-row-after-button.directive.js +0 -38
- package/dist/es2015/tools/tables/editor-add-row-before-button.directive.js +0 -38
- package/dist/es2015/tools/tables/editor-delete-column-button.directive.js +0 -38
- package/dist/es2015/tools/tables/editor-delete-row-button.directive.js +0 -38
- package/dist/es2015/tools/tables/editor-delete-table-button.directive.js +0 -38
- package/dist/es2015/tools/tables/editor-merge-cells-button.directive.js +0 -40
- package/dist/es2015/tools/tables/editor-split-cell-button.directive.js +0 -40
- package/dist/es2015/tools/tools.service.js +0 -22
- package/dist/es2015/tools/typographical-emphasis/editor-bold-button.directive.js +0 -45
- package/dist/es2015/tools/typographical-emphasis/editor-italic-button.directive.js +0 -45
- package/dist/es2015/tools/typographical-emphasis/editor-strikethrough-button.directive.js +0 -45
- package/dist/es2015/tools/typographical-emphasis/editor-subscript-button.directive.js +0 -45
- package/dist/es2015/tools/typographical-emphasis/editor-superscript-button.directive.js +0 -45
- package/dist/es2015/tools/typographical-emphasis/editor-underline-button.directive.js +0 -45
- package/dist/fesm2015/index.js +0 -5842
- package/dist/fesm5/index.js +0 -5300
- package/dist/npm/common/active-marks.js +0 -6
- package/dist/npm/common/apply-to-word-options.js +0 -6
- package/dist/npm/common/commands.js +0 -6
- package/dist/npm/common/direction.js +0 -6
- package/dist/npm/common/error-messages.js +0 -22
- package/dist/npm/common/font-family-item.interface.js +0 -6
- package/dist/npm/common/font-size-item.interface.js +0 -6
- package/dist/npm/common/format-item.interface.js +0 -6
- package/dist/npm/common/image-data.interface.js +0 -6
- package/dist/npm/common/link-data.interface.js +0 -6
- package/dist/npm/common/paste-cleanup-settings.js +0 -6
- package/dist/npm/common/plugins-function.js +0 -6
- package/dist/npm/common/predicate.js +0 -6
- package/dist/npm/common/resizable-options.interface.js +0 -6
- package/dist/npm/common/styles.js +0 -18
- package/dist/npm/common/table-data.interface.js +0 -6
- package/dist/npm/config/command-icons.js +0 -50
- package/dist/npm/config/commands.js +0 -112
- package/dist/npm/config/schema.js +0 -21
- package/dist/npm/config/semantic-nodes.js +0 -35
- package/dist/npm/config/table-commands.js +0 -16
- package/dist/npm/config/utils.js +0 -104
- package/dist/npm/dialogs/colorpicker-dialog.component.js +0 -72
- package/dist/npm/dialogs/file-link-dialog.component.js +0 -128
- package/dist/npm/dialogs/font-family-dialog.component.js +0 -67
- package/dist/npm/dialogs/font-size-dialog.component.js +0 -67
- package/dist/npm/dialogs/format-dialog.component.js +0 -67
- package/dist/npm/dialogs/image-dialog.component.js +0 -104
- package/dist/npm/dialogs/insert-table-dialog.component.js +0 -51
- package/dist/npm/dialogs/source-dialog.component.js +0 -74
- package/dist/npm/editor-toolbar-state.js +0 -282
- package/dist/npm/editor.component.js +0 -1041
- package/dist/npm/editor.module.js +0 -243
- package/dist/npm/index.js +0 -138
- package/dist/npm/localization/custom-messages.component.js +0 -47
- package/dist/npm/localization/editor-localization.service.js +0 -26
- package/dist/npm/localization/localized-messages.directive.js +0 -38
- package/dist/npm/localization/messages.js +0 -232
- package/dist/npm/main.js +0 -38
- package/dist/npm/package-metadata.js +0 -17
- package/dist/npm/preventable-events/paste-event-data.js +0 -6
- package/dist/npm/preventable-events/paste-event.js +0 -27
- package/dist/npm/tools/alignment/editor-align-center-button.directive.js +0 -49
- package/dist/npm/tools/alignment/editor-align-justify-button.directive.js +0 -49
- package/dist/npm/tools/alignment/editor-align-left-button.directive.js +0 -49
- package/dist/npm/tools/alignment/editor-align-right-button.directive.js +0 -49
- package/dist/npm/tools/blockquote/editor-blockquote-button.directive.js +0 -50
- package/dist/npm/tools/colorpicker/editor-back-color.directive.js +0 -30
- package/dist/npm/tools/colorpicker/editor-colorpicker.component.js +0 -235
- package/dist/npm/tools/colorpicker/editor-fore-color.directive.js +0 -30
- package/dist/npm/tools/editor-clean-formatting-button.directive.js +0 -48
- package/dist/npm/tools/fontfamily/editor-fontfamily-dropdownlist.component.js +0 -73
- package/dist/npm/tools/fontfamily/editor-fontfamily.component.js +0 -213
- package/dist/npm/tools/fontsize/editor-fontsize-dropdownlist.component.js +0 -73
- package/dist/npm/tools/fontsize/editor-fontsize.component.js +0 -208
- package/dist/npm/tools/format/editor-format-dropdownlist.component.js +0 -73
- package/dist/npm/tools/format/editor-format.component.js +0 -204
- package/dist/npm/tools/history/editor-redo-button.directive.js +0 -49
- package/dist/npm/tools/history/editor-undo-button.directive.js +0 -49
- package/dist/npm/tools/image/editor-insert-image-button.directive.js +0 -48
- package/dist/npm/tools/indentation/editor-indent-button.directive.js +0 -49
- package/dist/npm/tools/indentation/editor-outdent-button.directive.js +0 -49
- package/dist/npm/tools/link/editor-create-link-button.directive.js +0 -49
- package/dist/npm/tools/link/editor-insert-file-button.directive.js +0 -41
- package/dist/npm/tools/link/editor-unlink-button.directive.js +0 -49
- package/dist/npm/tools/list/editor-insert-ordered-list-button.directive.js +0 -49
- package/dist/npm/tools/list/editor-insert-unordered-list-button.directive.js +0 -49
- package/dist/npm/tools/print/editor-print-button.directive.js +0 -71
- package/dist/npm/tools/select-all/select-all-button.directive.js +0 -52
- package/dist/npm/tools/shared/dropdown-tool.directive.js +0 -43
- package/dist/npm/tools/shared/editor-command-base.js +0 -51
- package/dist/npm/tools/shared/editor-command-button.js +0 -36
- package/dist/npm/tools/shared/editor-command-dialog.js +0 -32
- package/dist/npm/tools/source/editor-view-source-button.directive.js +0 -48
- package/dist/npm/tools/tables/editor-add-column-after-button.directive.js +0 -42
- package/dist/npm/tools/tables/editor-add-column-before-button.directive.js +0 -42
- package/dist/npm/tools/tables/editor-add-row-after-button.directive.js +0 -42
- package/dist/npm/tools/tables/editor-add-row-before-button.directive.js +0 -42
- package/dist/npm/tools/tables/editor-delete-column-button.directive.js +0 -42
- package/dist/npm/tools/tables/editor-delete-row-button.directive.js +0 -42
- package/dist/npm/tools/tables/editor-delete-table-button.directive.js +0 -42
- package/dist/npm/tools/tables/editor-insert-table-button.component.js +0 -204
- package/dist/npm/tools/tables/editor-merge-cells-button.directive.js +0 -44
- package/dist/npm/tools/tables/editor-split-cell-button.directive.js +0 -44
- package/dist/npm/tools/tables/popup-table-grid.component.js +0 -71
- package/dist/npm/tools/tools.service.js +0 -22
- package/dist/npm/tools/typographical-emphasis/editor-bold-button.directive.js +0 -49
- package/dist/npm/tools/typographical-emphasis/editor-italic-button.directive.js +0 -49
- package/dist/npm/tools/typographical-emphasis/editor-strikethrough-button.directive.js +0 -49
- package/dist/npm/tools/typographical-emphasis/editor-subscript-button.directive.js +0 -49
- package/dist/npm/tools/typographical-emphasis/editor-superscript-button.directive.js +0 -49
- package/dist/npm/tools/typographical-emphasis/editor-underline-button.directive.js +0 -49
- package/dist/npm/util.js +0 -130
- package/dist/systemjs/kendo-angular-editor.js +0 -5
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { alignBlocks, alignLeftRules, alignCenterRules, alignRightRules, alignJustifyRules, alignRemoveRules, indent, outdent, setHtml, getHtml, insertImage, insertText, applyLink, removeLink, expandToWordWrap, blockquote,
|
|
6
|
+
//marks
|
|
7
|
+
bold, italic, underline, strikethrough, subscript, superscript, link, toggleInlineFormat, applyInlineStyle, formatBlockElements, toggleOrderedList, toggleUnorderedList, isAligned, undo, redo, cleanFormatting, selectAll, addColumnBefore, addColumnAfter, addRowBefore, addRowAfter, deleteRow, deleteColumn, deleteTable, mergeCells, splitCell } from '@progress/kendo-editor-common';
|
|
8
|
+
import { insertTable } from './table-commands';
|
|
9
|
+
const alignRemove = (state, dispatch) => alignBlocks(alignRemoveRules)(state, dispatch);
|
|
10
|
+
const inlineCommand = {
|
|
11
|
+
bold: (applyToWord) => expandToWordWrap(toggleInlineFormat, Object.assign(Object.assign({}, bold), { applyToWord })),
|
|
12
|
+
cleanFormatting: (options) => cleanFormatting(options),
|
|
13
|
+
createLink: attrs => expandToWordWrap(applyLink, { mark: 'link', attrs: attrs.value, applyToWord: attrs.applyToWord }),
|
|
14
|
+
fontFamily: attrs => expandToWordWrap(applyInlineStyle, { style: 'font-family', value: attrs.value, applyToWord: attrs.applyToWord }),
|
|
15
|
+
fontSize: attrs => expandToWordWrap(applyInlineStyle, { style: 'font-size', value: attrs.value + 'px', applyToWord: attrs.applyToWord }),
|
|
16
|
+
insertFile: attrs => expandToWordWrap(applyLink, { mark: 'link', attrs: attrs, applyToWord: attrs.applyToWord }),
|
|
17
|
+
insertText: text => insertText(text),
|
|
18
|
+
italic: (applyToWord) => expandToWordWrap(toggleInlineFormat, Object.assign(Object.assign({}, italic), { applyToWord })),
|
|
19
|
+
strikethrough: (applyToWord) => expandToWordWrap(toggleInlineFormat, Object.assign(Object.assign({}, strikethrough), { applyToWord })),
|
|
20
|
+
subscript: (applyToWord) => expandToWordWrap(toggleInlineFormat, Object.assign(Object.assign({}, subscript), { applyToWord })),
|
|
21
|
+
superscript: (applyToWord) => expandToWordWrap(toggleInlineFormat, Object.assign(Object.assign({}, superscript), { applyToWord })),
|
|
22
|
+
underline: (applyToWord) => expandToWordWrap(toggleInlineFormat, Object.assign(Object.assign({}, underline), { applyToWord })),
|
|
23
|
+
unlink: () => removeLink(link),
|
|
24
|
+
foreColor: attrs => expandToWordWrap(applyInlineStyle, { style: 'color', value: attrs.value, applyToWord: attrs.applyToWord }),
|
|
25
|
+
backColor: attrs => expandToWordWrap(applyInlineStyle, { style: 'background-color', value: attrs.value, applyToWord: attrs.applyToWord }),
|
|
26
|
+
selectAll: () => (state, dispatch) => selectAll(state, dispatch)
|
|
27
|
+
};
|
|
28
|
+
const blockCommand = {
|
|
29
|
+
alignCenter: () => (state, dispatch) => isAligned(state, alignCenterRules) ? alignRemove(state, dispatch) : alignBlocks(alignCenterRules)(state, dispatch),
|
|
30
|
+
alignJustify: () => (state, dispatch) => isAligned(state, alignJustifyRules) ? alignRemove(state, dispatch) : alignBlocks(alignJustifyRules)(state, dispatch),
|
|
31
|
+
alignLeft: () => (state, dispatch) => isAligned(state, alignLeftRules) ? alignRemove(state, dispatch) : alignBlocks(alignLeftRules)(state, dispatch),
|
|
32
|
+
alignRight: () => (state, dispatch) => isAligned(state, alignRightRules) ? alignRemove(state, dispatch) : alignBlocks(alignRightRules)(state, dispatch),
|
|
33
|
+
format: formatAttr => formatBlockElements(formatAttr.tag),
|
|
34
|
+
getHTML: () => getHtml,
|
|
35
|
+
indent: () => indent,
|
|
36
|
+
insertImage: attrs => insertImage(attrs),
|
|
37
|
+
// think about changing the command name.
|
|
38
|
+
insertOrderedList: () => toggleOrderedList,
|
|
39
|
+
// think about changing the command name.
|
|
40
|
+
insertUnorderedList: () => toggleUnorderedList,
|
|
41
|
+
outdent: () => outdent,
|
|
42
|
+
redo: () => redo,
|
|
43
|
+
setHTML: ({ content, parseOptions }) => setHtml(content, 'setHTML', parseOptions),
|
|
44
|
+
undo: () => undo,
|
|
45
|
+
blockquote: () => blockquote
|
|
46
|
+
};
|
|
47
|
+
const tableCommand = {
|
|
48
|
+
insertTable: attr => insertTable(attr),
|
|
49
|
+
addColumnBefore: () => addColumnBefore,
|
|
50
|
+
addColumnAfter: () => addColumnAfter,
|
|
51
|
+
addRowBefore: () => addRowBefore,
|
|
52
|
+
addRowAfter: () => addRowAfter,
|
|
53
|
+
deleteRow: () => deleteRow,
|
|
54
|
+
deleteColumn: () => deleteColumn,
|
|
55
|
+
mergeCells: () => mergeCells,
|
|
56
|
+
splitCell: () => splitCell,
|
|
57
|
+
deleteTable: () => deleteTable
|
|
58
|
+
};
|
|
59
|
+
/**
|
|
60
|
+
* @hidden
|
|
61
|
+
*/
|
|
62
|
+
export const editorCommands = Object.assign({}, inlineCommand, blockCommand, tableCommand);
|
|
File without changes
|
|
@@ -15,14 +15,11 @@ const createSemanticNode = (tagName) => ({
|
|
|
15
15
|
}],
|
|
16
16
|
toDOM: node => hasAttrs(node.attrs) ? [tagName, getAttrs(node.attrs), hole] : [tagName, hole]
|
|
17
17
|
});
|
|
18
|
-
const ɵ0 = createSemanticNode;
|
|
19
18
|
/**
|
|
20
19
|
* @hidden
|
|
21
20
|
*/
|
|
22
21
|
export const semanticTagNames = ['article', 'main', 'nav', 'header', 'footer', 'aside', 'section'];
|
|
23
|
-
const ɵ1 = (acc, curr) => Object.assign(acc, { [curr]: createSemanticNode(curr) });
|
|
24
22
|
/**
|
|
25
23
|
* @hidden
|
|
26
24
|
*/
|
|
27
|
-
export const semanticNodes = semanticTagNames.reduce(
|
|
28
|
-
export { ɵ0, ɵ1 };
|
|
25
|
+
export const semanticNodes = semanticTagNames.reduce((acc, curr) => Object.assign(acc, { [curr]: createSemanticNode(curr) }), {});
|
|
File without changes
|
|
@@ -52,7 +52,7 @@ export const commonAttributes = () => {
|
|
|
52
52
|
* @hidden
|
|
53
53
|
*/
|
|
54
54
|
export const createDefaultAttributes = (attrs = []) => {
|
|
55
|
-
return Object.assign({}, attrs.reduce((acc, curr) => (Object.assign({}, acc, { [curr]: { default: null } })), {}));
|
|
55
|
+
return Object.assign({}, attrs.reduce((acc, curr) => (Object.assign(Object.assign({}, acc), { [curr]: { default: null } })), {}));
|
|
56
56
|
};
|
|
57
57
|
/**
|
|
58
58
|
* @hidden
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { Component, Input, ViewChild } from '@angular/core';
|
|
6
|
+
import { DialogContentBase } from '@progress/kendo-angular-dialog';
|
|
7
|
+
import { ColorPickerComponent } from '@progress/kendo-angular-inputs';
|
|
8
|
+
import * as i0 from "@angular/core";
|
|
9
|
+
import * as i1 from "@progress/kendo-angular-dialog";
|
|
10
|
+
import * as i2 from "../localization/editor-localization.service";
|
|
11
|
+
import * as i3 from "@progress/kendo-angular-inputs";
|
|
12
|
+
import * as i4 from "@progress/kendo-angular-buttons";
|
|
13
|
+
/**
|
|
14
|
+
* @hidden
|
|
15
|
+
*/
|
|
16
|
+
export class ColorPickerDialogComponent extends DialogContentBase {
|
|
17
|
+
constructor(dialog, localization) {
|
|
18
|
+
super(dialog);
|
|
19
|
+
this.dialog = dialog;
|
|
20
|
+
this.localization = localization;
|
|
21
|
+
}
|
|
22
|
+
ngAfterViewInit() {
|
|
23
|
+
Promise.resolve(null).then(() => {
|
|
24
|
+
this.colorPicker.focus();
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
handleActiveColorClick(event) {
|
|
28
|
+
event.preventOpen();
|
|
29
|
+
this.value = event.color;
|
|
30
|
+
}
|
|
31
|
+
onCancelAction() {
|
|
32
|
+
this.dialog.close();
|
|
33
|
+
}
|
|
34
|
+
onConfirmAction() {
|
|
35
|
+
if (this.value) {
|
|
36
|
+
this.editor.exec(this.editorCommand, this.value);
|
|
37
|
+
}
|
|
38
|
+
this.dialog.close();
|
|
39
|
+
this.editor.view.focus();
|
|
40
|
+
}
|
|
41
|
+
setData(args) {
|
|
42
|
+
this.editor = args.editor;
|
|
43
|
+
this.value = args.value;
|
|
44
|
+
this.editorCommand = args.editorCommand;
|
|
45
|
+
this.paletteSettings = args.paletteSettings;
|
|
46
|
+
this.icon = args.icon;
|
|
47
|
+
this.views = args.view ? [args.view] : args.views;
|
|
48
|
+
}
|
|
49
|
+
textFor(key) {
|
|
50
|
+
return this.localization.get(key);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
ColorPickerDialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ColorPickerDialogComponent, deps: [{ token: i1.DialogRef }, { token: i2.EditorLocalizationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
54
|
+
ColorPickerDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ColorPickerDialogComponent, selector: "ng-component", inputs: { editor: "editor" }, viewQueries: [{ propertyName: "colorPicker", first: true, predicate: ["colorpicker"], descendants: true, read: ColorPickerComponent, static: true }], usesInheritance: true, ngImport: i0, template: `
|
|
55
|
+
<kendo-dialog-titlebar (close)="onCancelAction()">
|
|
56
|
+
{{ textFor(editorCommand) }}
|
|
57
|
+
</kendo-dialog-titlebar>
|
|
58
|
+
<div class="k-editor-dialog">
|
|
59
|
+
<div class="k-editor-dialog k-popup-edit-form k-window-content k-content">
|
|
60
|
+
<div class="k-edit-form-container k-window-content" style="text-align: center;">
|
|
61
|
+
<kendo-colorpicker
|
|
62
|
+
#colorpicker
|
|
63
|
+
[views]="views"
|
|
64
|
+
[format]="'hex'"
|
|
65
|
+
[attr.title]="title"
|
|
66
|
+
[icon]="icon"
|
|
67
|
+
[(value)]="value"
|
|
68
|
+
[paletteSettings]="paletteSettings"
|
|
69
|
+
(activeColorClick)="handleActiveColorClick($event)"
|
|
70
|
+
>
|
|
71
|
+
</kendo-colorpicker>
|
|
72
|
+
</div>
|
|
73
|
+
</div>
|
|
74
|
+
</div>
|
|
75
|
+
<kendo-dialog-actions>
|
|
76
|
+
<button kendoButton (click)="onCancelAction()">{{ textFor('dialogCancel') }}</button>
|
|
77
|
+
<button kendoButton
|
|
78
|
+
(click)="onConfirmAction()" [primary]="true">{{ textFor('dialogApply') }}</button>
|
|
79
|
+
</kendo-dialog-actions>
|
|
80
|
+
`, isInline: true, components: [{ type: i1.DialogTitleBarComponent, selector: "kendo-dialog-titlebar", inputs: ["id", "closeTitle"], outputs: ["close"] }, { type: i3.ColorPickerComponent, selector: "kendo-colorpicker", inputs: ["views", "view", "activeView", "readonly", "disabled", "format", "value", "popupSettings", "paletteSettings", "gradientSettings", "icon", "iconClass", "clearButton", "tabindex", "preview", "actionsLayout", "size", "rounded", "fillMode"], outputs: ["valueChange", "open", "close", "focus", "blur", "cancel", "activeColorClick", "activeViewChange"], exportAs: ["kendoColorPicker"] }, { type: i1.DialogActionsComponent, selector: "kendo-dialog-actions", inputs: ["actions", "layout"], outputs: ["action"] }], directives: [{ type: i4.ButtonDirective, selector: "button[kendoButton], span[kendoButton]", inputs: ["toggleable", "togglable", "selected", "tabIndex", "icon", "iconClass", "imageUrl", "disabled", "size", "rounded", "fillMode", "themeColor", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }] });
|
|
81
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ColorPickerDialogComponent, decorators: [{
|
|
82
|
+
type: Component,
|
|
83
|
+
args: [{
|
|
84
|
+
template: `
|
|
85
|
+
<kendo-dialog-titlebar (close)="onCancelAction()">
|
|
86
|
+
{{ textFor(editorCommand) }}
|
|
87
|
+
</kendo-dialog-titlebar>
|
|
88
|
+
<div class="k-editor-dialog">
|
|
89
|
+
<div class="k-editor-dialog k-popup-edit-form k-window-content k-content">
|
|
90
|
+
<div class="k-edit-form-container k-window-content" style="text-align: center;">
|
|
91
|
+
<kendo-colorpicker
|
|
92
|
+
#colorpicker
|
|
93
|
+
[views]="views"
|
|
94
|
+
[format]="'hex'"
|
|
95
|
+
[attr.title]="title"
|
|
96
|
+
[icon]="icon"
|
|
97
|
+
[(value)]="value"
|
|
98
|
+
[paletteSettings]="paletteSettings"
|
|
99
|
+
(activeColorClick)="handleActiveColorClick($event)"
|
|
100
|
+
>
|
|
101
|
+
</kendo-colorpicker>
|
|
102
|
+
</div>
|
|
103
|
+
</div>
|
|
104
|
+
</div>
|
|
105
|
+
<kendo-dialog-actions>
|
|
106
|
+
<button kendoButton (click)="onCancelAction()">{{ textFor('dialogCancel') }}</button>
|
|
107
|
+
<button kendoButton
|
|
108
|
+
(click)="onConfirmAction()" [primary]="true">{{ textFor('dialogApply') }}</button>
|
|
109
|
+
</kendo-dialog-actions>
|
|
110
|
+
`
|
|
111
|
+
}]
|
|
112
|
+
}], ctorParameters: function () { return [{ type: i1.DialogRef }, { type: i2.EditorLocalizationService }]; }, propDecorators: { editor: [{
|
|
113
|
+
type: Input
|
|
114
|
+
}], colorPicker: [{
|
|
115
|
+
type: ViewChild,
|
|
116
|
+
args: ['colorpicker', { read: ColorPickerComponent, static: true }]
|
|
117
|
+
}] } });
|
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { Component, Input, ViewChild, ElementRef } from '@angular/core';
|
|
6
|
+
import { FormGroup, FormControl, Validators } from '@angular/forms';
|
|
7
|
+
import { DialogContentBase } from '@progress/kendo-angular-dialog';
|
|
8
|
+
import { getMark, getSelectionText, expandSelection } from '@progress/kendo-editor-common';
|
|
9
|
+
import { isPresent } from '../util';
|
|
10
|
+
import * as i0 from "@angular/core";
|
|
11
|
+
import * as i1 from "@progress/kendo-angular-dialog";
|
|
12
|
+
import * as i2 from "../localization/editor-localization.service";
|
|
13
|
+
import * as i3 from "@angular/forms";
|
|
14
|
+
import * as i4 from "@angular/common";
|
|
15
|
+
import * as i5 from "@progress/kendo-angular-inputs";
|
|
16
|
+
import * as i6 from "@progress/kendo-angular-buttons";
|
|
17
|
+
/**
|
|
18
|
+
* @hidden
|
|
19
|
+
*/
|
|
20
|
+
export class FileLinkDialogComponent extends DialogContentBase {
|
|
21
|
+
constructor(dialog, localization) {
|
|
22
|
+
super(dialog);
|
|
23
|
+
this.dialog = dialog;
|
|
24
|
+
this.localization = localization;
|
|
25
|
+
this.linkForm = new FormGroup({
|
|
26
|
+
'href': new FormControl('', Validators.required),
|
|
27
|
+
'text': new FormControl({ value: '', disabled: true }, Validators.required),
|
|
28
|
+
'title': new FormControl('')
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
ngAfterViewInit() {
|
|
32
|
+
Promise.resolve(null).then(() => {
|
|
33
|
+
this.hrefInput.nativeElement.focus();
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
onCancelAction() {
|
|
37
|
+
this.dialog.close();
|
|
38
|
+
}
|
|
39
|
+
onConfirmAction() {
|
|
40
|
+
const linkData = this.getData();
|
|
41
|
+
this.editor.exec(this.command, linkData);
|
|
42
|
+
this.dialog.close();
|
|
43
|
+
this.editor.view.focus();
|
|
44
|
+
}
|
|
45
|
+
get titleText() {
|
|
46
|
+
return this.localization.get(this.command);
|
|
47
|
+
}
|
|
48
|
+
setData(state, options) {
|
|
49
|
+
if (this.command === 'createLink') {
|
|
50
|
+
this.linkForm.addControl('target', new FormControl());
|
|
51
|
+
}
|
|
52
|
+
const linkMark = getMark(state, state.schema.marks.link);
|
|
53
|
+
if (linkMark) {
|
|
54
|
+
// const linkMarkRange = getMarkRange(state.selection.$cursor, schema.marks.link);
|
|
55
|
+
// const mark = parentNode.child(cursorNodeIndex).marks.find(m => m.type === markType);
|
|
56
|
+
this.linkForm.reset({
|
|
57
|
+
href: linkMark.attrs.href,
|
|
58
|
+
title: linkMark.attrs.title,
|
|
59
|
+
target: isPresent(linkMark.attrs.target),
|
|
60
|
+
text: this.setLinkText(state)
|
|
61
|
+
});
|
|
62
|
+
return;
|
|
63
|
+
}
|
|
64
|
+
if (state.selection.empty) {
|
|
65
|
+
const currentState = options.applyToWord ? expandSelection(state, () => { }, options).state : state;
|
|
66
|
+
if (!currentState.selection.empty) {
|
|
67
|
+
this.linkForm.patchValue({
|
|
68
|
+
'text': getSelectionText(currentState)
|
|
69
|
+
});
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
else {
|
|
73
|
+
this.linkForm.patchValue({
|
|
74
|
+
'text': getSelectionText(state)
|
|
75
|
+
});
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
textForWithPrefix(key) {
|
|
79
|
+
const prefix = this.command === 'createLink' ? 'link' : 'file';
|
|
80
|
+
return this.textFor(prefix + key);
|
|
81
|
+
}
|
|
82
|
+
textFor(key) {
|
|
83
|
+
return this.localization.get(key);
|
|
84
|
+
}
|
|
85
|
+
setLinkText(state) {
|
|
86
|
+
const selection = state.selection;
|
|
87
|
+
if (selection.empty && selection.$cursor) {
|
|
88
|
+
const cursor = selection.$cursor;
|
|
89
|
+
const cursorNodeIndex = cursor.index();
|
|
90
|
+
const parentNode = cursor.parent;
|
|
91
|
+
return parentNode.child(cursorNodeIndex).text;
|
|
92
|
+
}
|
|
93
|
+
else {
|
|
94
|
+
return getSelectionText(state);
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
getData() {
|
|
98
|
+
let linkData = this.linkForm.value;
|
|
99
|
+
if (isPresent(this.linkForm.controls.target)) {
|
|
100
|
+
linkData.target = linkData.target ? '_blank' : null;
|
|
101
|
+
}
|
|
102
|
+
return linkData;
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
FileLinkDialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FileLinkDialogComponent, deps: [{ token: i1.DialogRef }, { token: i2.EditorLocalizationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
106
|
+
FileLinkDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: FileLinkDialogComponent, selector: "ng-component", inputs: { editor: "editor", command: "command" }, viewQueries: [{ propertyName: "hrefInput", first: true, predicate: ["hrefInput"], descendants: true, read: ElementRef, static: true }], usesInheritance: true, ngImport: i0, template: `
|
|
107
|
+
<kendo-dialog-titlebar (close)="onCancelAction()">
|
|
108
|
+
{{ titleText }}
|
|
109
|
+
</kendo-dialog-titlebar>
|
|
110
|
+
<div class="k-editor-dialog">
|
|
111
|
+
<div class="k-editor-dialog k-popup-edit-form k-window-content k-content">
|
|
112
|
+
<div class="k-edit-form-container k-window-content">
|
|
113
|
+
<form novalidate [formGroup]="linkForm">
|
|
114
|
+
<div class="k-edit-label">
|
|
115
|
+
<label (click)="hrefInput.focus()">{{ textForWithPrefix('WebAddress') }}</label>
|
|
116
|
+
</div>
|
|
117
|
+
<div class="k-edit-field">
|
|
118
|
+
<input #hrefInput formControlName="href" type="text" class="k-textbox k-input k-rounded-md" />
|
|
119
|
+
</div>
|
|
120
|
+
|
|
121
|
+
<div class="k-edit-label">
|
|
122
|
+
<label (click)="textInput.focus()">{{ textForWithPrefix('Text') }}</label>
|
|
123
|
+
</div>
|
|
124
|
+
<div class="k-edit-field">
|
|
125
|
+
<input #textInput formControlName="text" type="text" class="k-textbox k-input k-rounded-md" />
|
|
126
|
+
</div>
|
|
127
|
+
|
|
128
|
+
<div class="k-edit-label">
|
|
129
|
+
<label (click)="titleInput.focus()">{{ textForWithPrefix('Title') }}</label>
|
|
130
|
+
</div>
|
|
131
|
+
<div class="k-edit-field">
|
|
132
|
+
<input #titleInput formControlName="title" type="text" class="k-textbox k-input k-rounded-md" />
|
|
133
|
+
</div>
|
|
134
|
+
<ng-container *ngIf="command === 'createLink'">
|
|
135
|
+
<div class="k-edit-label"></div>
|
|
136
|
+
<div class="k-edit-field">
|
|
137
|
+
<input type="checkbox" id="k-target-blank" kendoCheckBox formControlName="target" />
|
|
138
|
+
<label class="k-checkbox-label" for="k-target-blank">{{ textForWithPrefix('OpenInNewWindow') }}</label>
|
|
139
|
+
</div>
|
|
140
|
+
</ng-container>
|
|
141
|
+
</form>
|
|
142
|
+
</div>
|
|
143
|
+
</div>
|
|
144
|
+
</div>
|
|
145
|
+
<kendo-dialog-actions>
|
|
146
|
+
<button kendoButton (click)="onCancelAction()">{{ textFor('dialogCancel') }}</button>
|
|
147
|
+
<button kendoButton [disabled]="linkForm.invalid" (click)="onConfirmAction()" [primary]="true">
|
|
148
|
+
{{ textFor('dialogInsert') }}
|
|
149
|
+
</button>
|
|
150
|
+
</kendo-dialog-actions>
|
|
151
|
+
`, isInline: true, components: [{ type: i1.DialogTitleBarComponent, selector: "kendo-dialog-titlebar", inputs: ["id", "closeTitle"], outputs: ["close"] }, { type: i1.DialogActionsComponent, selector: "kendo-dialog-actions", inputs: ["actions", "layout"], outputs: ["action"] }], directives: [{ type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i3.FormControlName, selector: "[formControlName]", inputs: ["disabled", "formControlName", "ngModel"], outputs: ["ngModelChange"] }, { type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { type: i5.CheckBoxDirective, selector: "input[kendoCheckBox]", inputs: ["size", "rounded"] }, { type: i6.ButtonDirective, selector: "button[kendoButton], span[kendoButton]", inputs: ["toggleable", "togglable", "selected", "tabIndex", "icon", "iconClass", "imageUrl", "disabled", "size", "rounded", "fillMode", "themeColor", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }] });
|
|
152
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FileLinkDialogComponent, decorators: [{
|
|
153
|
+
type: Component,
|
|
154
|
+
args: [{
|
|
155
|
+
template: `
|
|
156
|
+
<kendo-dialog-titlebar (close)="onCancelAction()">
|
|
157
|
+
{{ titleText }}
|
|
158
|
+
</kendo-dialog-titlebar>
|
|
159
|
+
<div class="k-editor-dialog">
|
|
160
|
+
<div class="k-editor-dialog k-popup-edit-form k-window-content k-content">
|
|
161
|
+
<div class="k-edit-form-container k-window-content">
|
|
162
|
+
<form novalidate [formGroup]="linkForm">
|
|
163
|
+
<div class="k-edit-label">
|
|
164
|
+
<label (click)="hrefInput.focus()">{{ textForWithPrefix('WebAddress') }}</label>
|
|
165
|
+
</div>
|
|
166
|
+
<div class="k-edit-field">
|
|
167
|
+
<input #hrefInput formControlName="href" type="text" class="k-textbox k-input k-rounded-md" />
|
|
168
|
+
</div>
|
|
169
|
+
|
|
170
|
+
<div class="k-edit-label">
|
|
171
|
+
<label (click)="textInput.focus()">{{ textForWithPrefix('Text') }}</label>
|
|
172
|
+
</div>
|
|
173
|
+
<div class="k-edit-field">
|
|
174
|
+
<input #textInput formControlName="text" type="text" class="k-textbox k-input k-rounded-md" />
|
|
175
|
+
</div>
|
|
176
|
+
|
|
177
|
+
<div class="k-edit-label">
|
|
178
|
+
<label (click)="titleInput.focus()">{{ textForWithPrefix('Title') }}</label>
|
|
179
|
+
</div>
|
|
180
|
+
<div class="k-edit-field">
|
|
181
|
+
<input #titleInput formControlName="title" type="text" class="k-textbox k-input k-rounded-md" />
|
|
182
|
+
</div>
|
|
183
|
+
<ng-container *ngIf="command === 'createLink'">
|
|
184
|
+
<div class="k-edit-label"></div>
|
|
185
|
+
<div class="k-edit-field">
|
|
186
|
+
<input type="checkbox" id="k-target-blank" kendoCheckBox formControlName="target" />
|
|
187
|
+
<label class="k-checkbox-label" for="k-target-blank">{{ textForWithPrefix('OpenInNewWindow') }}</label>
|
|
188
|
+
</div>
|
|
189
|
+
</ng-container>
|
|
190
|
+
</form>
|
|
191
|
+
</div>
|
|
192
|
+
</div>
|
|
193
|
+
</div>
|
|
194
|
+
<kendo-dialog-actions>
|
|
195
|
+
<button kendoButton (click)="onCancelAction()">{{ textFor('dialogCancel') }}</button>
|
|
196
|
+
<button kendoButton [disabled]="linkForm.invalid" (click)="onConfirmAction()" [primary]="true">
|
|
197
|
+
{{ textFor('dialogInsert') }}
|
|
198
|
+
</button>
|
|
199
|
+
</kendo-dialog-actions>
|
|
200
|
+
`
|
|
201
|
+
}]
|
|
202
|
+
}], ctorParameters: function () { return [{ type: i1.DialogRef }, { type: i2.EditorLocalizationService }]; }, propDecorators: { editor: [{
|
|
203
|
+
type: Input
|
|
204
|
+
}], command: [{
|
|
205
|
+
type: Input
|
|
206
|
+
}], hrefInput: [{
|
|
207
|
+
type: ViewChild,
|
|
208
|
+
args: ['hrefInput', { read: ElementRef, static: true }]
|
|
209
|
+
}] } });
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { Component, Input, ViewChild } from '@angular/core';
|
|
6
|
+
import { DialogContentBase } from '@progress/kendo-angular-dialog';
|
|
7
|
+
import { FontFamilyDropDownListComponent } from '../tools/fontfamily/editor-fontfamily-dropdownlist.component';
|
|
8
|
+
import * as i0 from "@angular/core";
|
|
9
|
+
import * as i1 from "@progress/kendo-angular-dialog";
|
|
10
|
+
import * as i2 from "../localization/editor-localization.service";
|
|
11
|
+
import * as i3 from "../tools/fontfamily/editor-fontfamily-dropdownlist.component";
|
|
12
|
+
import * as i4 from "@progress/kendo-angular-buttons";
|
|
13
|
+
/**
|
|
14
|
+
* @hidden
|
|
15
|
+
*/
|
|
16
|
+
export class FontFamilyDialogComponent extends DialogContentBase {
|
|
17
|
+
constructor(dialog, localization) {
|
|
18
|
+
super(dialog);
|
|
19
|
+
this.dialog = dialog;
|
|
20
|
+
this.localization = localization;
|
|
21
|
+
this.data = [];
|
|
22
|
+
}
|
|
23
|
+
ngAfterViewInit() {
|
|
24
|
+
Promise.resolve(null).then(() => {
|
|
25
|
+
this.fontFamilyDropDownList.dropDownList.focus();
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
onCancelAction() {
|
|
29
|
+
this.dialog.close();
|
|
30
|
+
}
|
|
31
|
+
onConfirmAction() {
|
|
32
|
+
if (this.value) {
|
|
33
|
+
this.editor.exec('fontFamily', this.value);
|
|
34
|
+
}
|
|
35
|
+
this.dialog.close();
|
|
36
|
+
}
|
|
37
|
+
setData(args) {
|
|
38
|
+
this.editor = args.editor;
|
|
39
|
+
this.data = args.data;
|
|
40
|
+
this.defaultItem = args.defaultItem;
|
|
41
|
+
this.value = args.value;
|
|
42
|
+
this.itemDisabled = args.itemDisabled;
|
|
43
|
+
}
|
|
44
|
+
textFor(key) {
|
|
45
|
+
return this.localization.get(key);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
FontFamilyDialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FontFamilyDialogComponent, deps: [{ token: i1.DialogRef }, { token: i2.EditorLocalizationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
49
|
+
FontFamilyDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: FontFamilyDialogComponent, selector: "ng-component", inputs: { editor: "editor" }, viewQueries: [{ propertyName: "fontFamilyDropDownList", first: true, predicate: ["fontFamilyDropDownList"], descendants: true, read: FontFamilyDropDownListComponent, static: true }], usesInheritance: true, ngImport: i0, template: `
|
|
50
|
+
<kendo-dialog-titlebar (close)="onCancelAction()">
|
|
51
|
+
{{ textFor('fontFamily') }}
|
|
52
|
+
</kendo-dialog-titlebar>
|
|
53
|
+
<div class="k-editor-dialog">
|
|
54
|
+
<div class="k-editor-dialog k-popup-edit-form k-window-content k-content">
|
|
55
|
+
<div class="k-edit-form-container k-window-content" style="text-align: center;">
|
|
56
|
+
<kendo-editor-fontfamily-dropdownlist
|
|
57
|
+
#fontFamilyDropDownList
|
|
58
|
+
[defaultItem]="defaultItem"
|
|
59
|
+
[data]="data"
|
|
60
|
+
[(value)]="value"
|
|
61
|
+
[itemDisabled]="itemDisabled"
|
|
62
|
+
>
|
|
63
|
+
</kendo-editor-fontfamily-dropdownlist>
|
|
64
|
+
</div>
|
|
65
|
+
</div>
|
|
66
|
+
</div>
|
|
67
|
+
<kendo-dialog-actions>
|
|
68
|
+
<button kendoButton (click)="onCancelAction()">{{ textFor('dialogCancel') }}</button>
|
|
69
|
+
<button kendoButton
|
|
70
|
+
(click)="onConfirmAction()" [primary]="true">{{ textFor('dialogApply') }}</button>
|
|
71
|
+
</kendo-dialog-actions>
|
|
72
|
+
`, isInline: true, components: [{ type: i1.DialogTitleBarComponent, selector: "kendo-dialog-titlebar", inputs: ["id", "closeTitle"], outputs: ["close"] }, { type: i3.FontFamilyDropDownListComponent, selector: "kendo-editor-fontfamily-dropdownlist", inputs: ["data", "value", "defaultItem", "itemDisabled", "title", "disabled", "tabindex"], outputs: ["valueChange"] }, { type: i1.DialogActionsComponent, selector: "kendo-dialog-actions", inputs: ["actions", "layout"], outputs: ["action"] }], directives: [{ type: i4.ButtonDirective, selector: "button[kendoButton], span[kendoButton]", inputs: ["toggleable", "togglable", "selected", "tabIndex", "icon", "iconClass", "imageUrl", "disabled", "size", "rounded", "fillMode", "themeColor", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }] });
|
|
73
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FontFamilyDialogComponent, decorators: [{
|
|
74
|
+
type: Component,
|
|
75
|
+
args: [{
|
|
76
|
+
template: `
|
|
77
|
+
<kendo-dialog-titlebar (close)="onCancelAction()">
|
|
78
|
+
{{ textFor('fontFamily') }}
|
|
79
|
+
</kendo-dialog-titlebar>
|
|
80
|
+
<div class="k-editor-dialog">
|
|
81
|
+
<div class="k-editor-dialog k-popup-edit-form k-window-content k-content">
|
|
82
|
+
<div class="k-edit-form-container k-window-content" style="text-align: center;">
|
|
83
|
+
<kendo-editor-fontfamily-dropdownlist
|
|
84
|
+
#fontFamilyDropDownList
|
|
85
|
+
[defaultItem]="defaultItem"
|
|
86
|
+
[data]="data"
|
|
87
|
+
[(value)]="value"
|
|
88
|
+
[itemDisabled]="itemDisabled"
|
|
89
|
+
>
|
|
90
|
+
</kendo-editor-fontfamily-dropdownlist>
|
|
91
|
+
</div>
|
|
92
|
+
</div>
|
|
93
|
+
</div>
|
|
94
|
+
<kendo-dialog-actions>
|
|
95
|
+
<button kendoButton (click)="onCancelAction()">{{ textFor('dialogCancel') }}</button>
|
|
96
|
+
<button kendoButton
|
|
97
|
+
(click)="onConfirmAction()" [primary]="true">{{ textFor('dialogApply') }}</button>
|
|
98
|
+
</kendo-dialog-actions>
|
|
99
|
+
`
|
|
100
|
+
}]
|
|
101
|
+
}], ctorParameters: function () { return [{ type: i1.DialogRef }, { type: i2.EditorLocalizationService }]; }, propDecorators: { editor: [{
|
|
102
|
+
type: Input
|
|
103
|
+
}], fontFamilyDropDownList: [{
|
|
104
|
+
type: ViewChild,
|
|
105
|
+
args: ['fontFamilyDropDownList', { read: FontFamilyDropDownListComponent, static: true }]
|
|
106
|
+
}] } });
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { Component, Input, ViewChild } from '@angular/core';
|
|
6
|
+
import { DialogContentBase } from '@progress/kendo-angular-dialog';
|
|
7
|
+
import { FontSizeDropDownListComponent } from '../tools/fontsize/editor-fontsize-dropdownlist.component';
|
|
8
|
+
import * as i0 from "@angular/core";
|
|
9
|
+
import * as i1 from "@progress/kendo-angular-dialog";
|
|
10
|
+
import * as i2 from "../localization/editor-localization.service";
|
|
11
|
+
import * as i3 from "../tools/fontsize/editor-fontsize-dropdownlist.component";
|
|
12
|
+
import * as i4 from "@progress/kendo-angular-buttons";
|
|
13
|
+
/**
|
|
14
|
+
* @hidden
|
|
15
|
+
*/
|
|
16
|
+
export class FontSizeDialogComponent extends DialogContentBase {
|
|
17
|
+
constructor(dialog, localization) {
|
|
18
|
+
super(dialog);
|
|
19
|
+
this.dialog = dialog;
|
|
20
|
+
this.localization = localization;
|
|
21
|
+
this.data = [];
|
|
22
|
+
}
|
|
23
|
+
ngAfterViewInit() {
|
|
24
|
+
Promise.resolve(null).then(() => {
|
|
25
|
+
this.fontSizeDropDownList.dropDownList.focus();
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
onCancelAction() {
|
|
29
|
+
this.dialog.close();
|
|
30
|
+
}
|
|
31
|
+
onConfirmAction() {
|
|
32
|
+
if (this.value) {
|
|
33
|
+
this.editor.exec('fontSize', this.value);
|
|
34
|
+
}
|
|
35
|
+
this.dialog.close();
|
|
36
|
+
}
|
|
37
|
+
setData(args) {
|
|
38
|
+
this.editor = args.editor;
|
|
39
|
+
this.data = args.data;
|
|
40
|
+
this.defaultItem = args.defaultItem;
|
|
41
|
+
this.value = args.value;
|
|
42
|
+
this.itemDisabled = args.itemDisabled;
|
|
43
|
+
}
|
|
44
|
+
textFor(key) {
|
|
45
|
+
return this.localization.get(key);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
FontSizeDialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FontSizeDialogComponent, deps: [{ token: i1.DialogRef }, { token: i2.EditorLocalizationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
49
|
+
FontSizeDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: FontSizeDialogComponent, selector: "ng-component", inputs: { editor: "editor" }, viewQueries: [{ propertyName: "fontSizeDropDownList", first: true, predicate: ["fontSizeDropDownList"], descendants: true, read: FontSizeDropDownListComponent, static: true }], usesInheritance: true, ngImport: i0, template: `
|
|
50
|
+
<kendo-dialog-titlebar (close)="onCancelAction()">
|
|
51
|
+
{{ textFor('fontSize') }}
|
|
52
|
+
</kendo-dialog-titlebar>
|
|
53
|
+
<div class="k-editor-dialog">
|
|
54
|
+
<div class="k-editor-dialog k-popup-edit-form k-window-content k-content">
|
|
55
|
+
<div class="k-edit-form-container k-window-content" style="text-align: center;">
|
|
56
|
+
<kendo-editor-fontsize-dropdownlist
|
|
57
|
+
#fontSizeDropDownList
|
|
58
|
+
[defaultItem]="defaultItem"
|
|
59
|
+
[data]="data"
|
|
60
|
+
[(value)]="value"
|
|
61
|
+
[itemDisabled]="itemDisabled"
|
|
62
|
+
>
|
|
63
|
+
</kendo-editor-fontsize-dropdownlist>
|
|
64
|
+
</div>
|
|
65
|
+
</div>
|
|
66
|
+
</div>
|
|
67
|
+
<kendo-dialog-actions>
|
|
68
|
+
<button kendoButton (click)="onCancelAction()">{{ textFor('dialogCancel') }}</button>
|
|
69
|
+
<button kendoButton
|
|
70
|
+
(click)="onConfirmAction()" [primary]="true">{{ textFor('dialogApply') }}</button>
|
|
71
|
+
</kendo-dialog-actions>
|
|
72
|
+
`, isInline: true, components: [{ type: i1.DialogTitleBarComponent, selector: "kendo-dialog-titlebar", inputs: ["id", "closeTitle"], outputs: ["close"] }, { type: i3.FontSizeDropDownListComponent, selector: "kendo-editor-fontsize-dropdownlist", inputs: ["data", "value", "defaultItem", "itemDisabled", "title", "disabled", "tabindex"], outputs: ["valueChange"] }, { type: i1.DialogActionsComponent, selector: "kendo-dialog-actions", inputs: ["actions", "layout"], outputs: ["action"] }], directives: [{ type: i4.ButtonDirective, selector: "button[kendoButton], span[kendoButton]", inputs: ["toggleable", "togglable", "selected", "tabIndex", "icon", "iconClass", "imageUrl", "disabled", "size", "rounded", "fillMode", "themeColor", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }] });
|
|
73
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FontSizeDialogComponent, decorators: [{
|
|
74
|
+
type: Component,
|
|
75
|
+
args: [{
|
|
76
|
+
template: `
|
|
77
|
+
<kendo-dialog-titlebar (close)="onCancelAction()">
|
|
78
|
+
{{ textFor('fontSize') }}
|
|
79
|
+
</kendo-dialog-titlebar>
|
|
80
|
+
<div class="k-editor-dialog">
|
|
81
|
+
<div class="k-editor-dialog k-popup-edit-form k-window-content k-content">
|
|
82
|
+
<div class="k-edit-form-container k-window-content" style="text-align: center;">
|
|
83
|
+
<kendo-editor-fontsize-dropdownlist
|
|
84
|
+
#fontSizeDropDownList
|
|
85
|
+
[defaultItem]="defaultItem"
|
|
86
|
+
[data]="data"
|
|
87
|
+
[(value)]="value"
|
|
88
|
+
[itemDisabled]="itemDisabled"
|
|
89
|
+
>
|
|
90
|
+
</kendo-editor-fontsize-dropdownlist>
|
|
91
|
+
</div>
|
|
92
|
+
</div>
|
|
93
|
+
</div>
|
|
94
|
+
<kendo-dialog-actions>
|
|
95
|
+
<button kendoButton (click)="onCancelAction()">{{ textFor('dialogCancel') }}</button>
|
|
96
|
+
<button kendoButton
|
|
97
|
+
(click)="onConfirmAction()" [primary]="true">{{ textFor('dialogApply') }}</button>
|
|
98
|
+
</kendo-dialog-actions>
|
|
99
|
+
`
|
|
100
|
+
}]
|
|
101
|
+
}], ctorParameters: function () { return [{ type: i1.DialogRef }, { type: i2.EditorLocalizationService }]; }, propDecorators: { editor: [{
|
|
102
|
+
type: Input
|
|
103
|
+
}], fontSizeDropDownList: [{
|
|
104
|
+
type: ViewChild,
|
|
105
|
+
args: ['fontSizeDropDownList', { read: FontSizeDropDownListComponent, static: true }]
|
|
106
|
+
}] } });
|