@atlaskit/editor-common 97.1.2 → 97.2.0
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/CHANGELOG.md +21 -0
- package/dist/cjs/analytics/analytics-queue.js +8 -0
- package/dist/cjs/analytics/linking-utils.js +2 -0
- package/dist/cjs/card/LinkToolbarButtonGroup.js +2 -0
- package/dist/cjs/card/MediaAndEmbedsToolbar/index.js +15 -3
- package/dist/cjs/card/ui/assets/card.js +4 -0
- package/dist/cjs/card/ui/assets/embed.js +4 -0
- package/dist/cjs/card/ui/assets/inline.js +4 -0
- package/dist/cjs/card/ui/assets/url.js +4 -0
- package/dist/cjs/clipboard/index.js +12 -1
- package/dist/cjs/collab/index.js +2 -0
- package/dist/cjs/commands/index.js +50 -42
- package/dist/cjs/commands/insert-block.js +10 -2
- package/dist/cjs/core-utils/document-logger.js +4 -0
- package/dist/cjs/doc-utils/editor-use-only.js +8 -3
- package/dist/cjs/element-browser/ElementBrowser.js +2 -0
- package/dist/cjs/element-browser/ViewMore.js +8 -2
- package/dist/cjs/element-browser/components/CategoryList.js +2 -0
- package/dist/cjs/element-browser/components/ElementList/ElementList.js +12 -0
- package/dist/cjs/element-browser/components/StatelessElementBrowser.js +8 -2
- package/dist/cjs/element-browser/hooks/use-select-and-focus-on-arrow-navigation.js +13 -2
- package/dist/cjs/event-dispatcher/index.js +6 -0
- package/dist/cjs/extensibility/Extension/Extension/index.js +2 -0
- package/dist/cjs/extensibility/Extension/Lozenge/ExtensionLabel.js +10 -2
- package/dist/cjs/extensibility/Extension/Lozenge/index.js +3 -1
- package/dist/cjs/extensibility/Extension.js +2 -0
- package/dist/cjs/extensibility/ExtensionComponent.js +17 -2
- package/dist/cjs/extensibility/MultiBodiedExtension/index.js +4 -0
- package/dist/cjs/extensibility/extensionNodeView.js +2 -1
- package/dist/cjs/extensions/extension-fields-helpers.js +4 -1
- package/dist/cjs/extensions/extension-handlers.js +4 -0
- package/dist/cjs/extensions/module-helpers.js +14 -6
- package/dist/cjs/extensions/types/field-definitions.js +5 -0
- package/dist/cjs/floating-toolbar/index.js +18 -2
- package/dist/cjs/guideline/dynamicGuideline.js +4 -1
- package/dist/cjs/guideline/relativeGuideline.js +12 -3
- package/dist/cjs/guideline/updateGuideline.js +4 -1
- package/dist/cjs/hooks/usePluginStateEffect.js +3 -0
- package/dist/cjs/hooks/useSharedPluginState.js +3 -0
- package/dist/cjs/hooks/useSharedPluginStateSelector/useSharedPluginStateSelector.js +3 -0
- package/dist/cjs/icons/shared/BorderIcon.js +4 -0
- package/dist/cjs/icons/shared/PanelErrorIcon.js +4 -0
- package/dist/cjs/icons/shared/PanelInfoIcon.js +4 -0
- package/dist/cjs/icons/shared/PanelNoteIcon.js +4 -0
- package/dist/cjs/icons/shared/PanelSuccessIcon.js +4 -0
- package/dist/cjs/icons/shared/PanelWarningIcon.js +4 -0
- package/dist/cjs/insert/index.js +6 -1
- package/dist/cjs/keymaps/index.js +48 -5
- package/dist/cjs/keymaps/keymap.js +4 -0
- package/dist/cjs/lazy-node-view/css-helper.js +4 -0
- package/dist/cjs/lazy-node-view/index.js +6 -1
- package/dist/cjs/lazy-node-view/node-view.js +2 -0
- package/dist/cjs/link/ConfigureLinkOverlay/Dropdown.js +2 -0
- package/dist/cjs/link/ConfigureLinkOverlay/StyledButton.js +4 -1
- package/dist/cjs/link/LinkPicker/EditorLinkPicker/index.js +4 -1
- package/dist/cjs/link/LinkPicker/EditorLinkPicker/useEscapeClickaway.js +9 -0
- package/dist/cjs/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.js +16 -1
- package/dist/cjs/link/LinkPicker/HyperlinkAddToolbar/index.js +2 -0
- package/dist/cjs/link/LinkSearch/LinkSearchList.js +2 -0
- package/dist/cjs/link/LinkSearch/LinkSearchListItem.js +2 -0
- package/dist/cjs/link/LinkSearch/index.js +9 -1
- package/dist/cjs/link/LinkSearch/withActivityProvider.js +3 -0
- package/dist/cjs/lists/analytics.js +2 -0
- package/dist/cjs/mark/commands.js +24 -3
- package/dist/cjs/media-inline/inline-image-card.js +4 -2
- package/dist/cjs/media-inline/inline-image-wrapper.js +2 -0
- package/dist/cjs/media-single/MediaBadges.js +2 -0
- package/dist/cjs/media-single/utils.js +5 -0
- package/dist/cjs/monitoring/environment.js +6 -1
- package/dist/cjs/monitoring/error.js +19 -3
- package/dist/cjs/node-width/index.js +6 -1
- package/dist/cjs/normalize-feature-flags.js +4 -1
- package/dist/cjs/paste/clipboard.js +2 -0
- package/dist/cjs/paste/md-plugins/ignore-list-heading-md-plugin.js +5 -0
- package/dist/cjs/paste/md-plugins/linkify-md-plugin.js +20 -0
- package/dist/cjs/paste/md-plugins/newline-md-plugin.js +5 -0
- package/dist/cjs/paste/md-plugins/paragraph-md-plugin.js +5 -0
- package/dist/cjs/portal/common.js +4 -1
- package/dist/cjs/preset/builder.js +8 -0
- package/dist/cjs/preset/core-plugin/index.js +5 -0
- package/dist/cjs/preset/core-plugin/requestDocument.js +3 -0
- package/dist/cjs/preset/plugin-injection-api.js +61 -6
- package/dist/cjs/provider-factory/provider-factory.js +8 -1
- package/dist/cjs/provider-factory/with-providers.js +12 -0
- package/dist/cjs/provider-helpers/combine-providers.js +7 -0
- package/dist/cjs/provider-helpers/promise-helpers.js +3 -0
- package/dist/cjs/quick-insert/assets/index.js +2 -0
- package/dist/cjs/react-node-view/getInlineNodeViewProducer.js +4 -0
- package/dist/cjs/react-node-view/index.js +33 -2
- package/dist/cjs/resizer/BreakoutResizer.js +0 -6
- package/dist/cjs/resizer/Resizer.js +10 -2
- package/dist/cjs/safe-plugin/index.js +3 -0
- package/dist/cjs/selection/gap-cursor/actions.js +11 -2
- package/dist/cjs/selection/gap-cursor/selection.js +8 -0
- package/dist/cjs/selection/index.js +2 -0
- package/dist/cjs/selection-based-node-view/SelectionBasedNodeView.js +10 -1
- package/dist/cjs/styles/shared/lists.js +4 -1
- package/dist/cjs/transforms/code-block.js +6 -0
- package/dist/cjs/transforms/extension.js +14 -2
- package/dist/cjs/transforms/layout.js +6 -0
- package/dist/cjs/types/annotation/emitter.js +8 -2
- package/dist/cjs/types/index.js +3 -1
- package/dist/cjs/ui/Caption/index.js +4 -0
- package/dist/cjs/ui/ContextPanel/context.js +4 -0
- package/dist/cjs/ui/DropList/index.js +11 -1
- package/dist/cjs/ui/Emoji/index.js +2 -0
- package/dist/cjs/ui/ErrorBoundary/index.js +2 -0
- package/dist/cjs/ui/Expand/index.js +13 -6
- package/dist/cjs/ui/FloatingToolbar/Button.js +2 -0
- package/dist/cjs/ui/FloatingToolbar/ButtonSpotlightCard.js +4 -1
- package/dist/cjs/ui/FloatingToolbar/styles.js +3 -0
- package/dist/cjs/ui/IntlErrorBoundary/index.js +3 -0
- package/dist/cjs/ui/Layer/index.js +8 -0
- package/dist/cjs/ui/MediaSingle/grid.js +12 -2
- package/dist/cjs/ui/MediaSingle/index.js +2 -0
- package/dist/cjs/ui/MediaSingle/styled.js +6 -0
- package/dist/cjs/ui/Mention/mention-with-profilecard.js +4 -1
- package/dist/cjs/ui/Mention/mention-with-providers.js +20 -3
- package/dist/cjs/ui/OverflowShadow/index.js +18 -4
- package/dist/cjs/ui/OverflowShadow/shadowObserver.js +12 -2
- package/dist/cjs/ui/PanelTextInput/index.js +16 -1
- package/dist/cjs/ui/Popup/index.js +23 -2
- package/dist/cjs/ui/Popup/utils.js +19 -0
- package/dist/cjs/ui/ResizerLegacy/index.js +7 -0
- package/dist/cjs/ui/unsupported-content-helper.js +6 -1
- package/dist/cjs/ui/with-outer-listeners.js +12 -1
- package/dist/cjs/ui-color/ColorPalette/utils.js +2 -0
- package/dist/cjs/ui-menu/ArrowKeyNavigationProvider/ColorPaletteArrowKeyNavigationProvider/index.js +9 -0
- package/dist/cjs/ui-menu/ArrowKeyNavigationProvider/MenuArrowKeyNavigationProvider/index.js +12 -0
- package/dist/cjs/ui-menu/ArrowKeyNavigationProvider/index.js +4 -0
- package/dist/cjs/ui-menu/Dropdown/index.js +9 -2
- package/dist/cjs/ui-menu/DropdownContainer/index.js +4 -1
- package/dist/cjs/ui-menu/DropdownMenu/index.js +20 -3
- package/dist/cjs/ui-menu/ToolbarArrowKeyNavigationProvider/index.js +17 -0
- package/dist/cjs/ui-menu/ToolbarButton/styles.js +2 -0
- package/dist/cjs/ui-react/with-react-editor-view-outer-listeners.js +29 -4
- package/dist/cjs/utils/breakout.js +4 -0
- package/dist/cjs/utils/browser-extensions.js +4 -0
- package/dist/cjs/utils/browser.js +47 -5
- package/dist/cjs/utils/commands.js +4 -1
- package/dist/cjs/utils/compareNodes.js +7 -0
- package/dist/cjs/utils/compose.js +2 -0
- package/dist/cjs/utils/create-wrap-selection-transaction.js +9 -1
- package/dist/cjs/utils/dom.js +2 -0
- package/dist/cjs/utils/editor-core-utils.js +5 -0
- package/dist/cjs/utils/filter/privacy-filter.js +2 -0
- package/dist/cjs/utils/get-performance-options.js +2 -0
- package/dist/cjs/utils/hyperlink.js +16 -0
- package/dist/cjs/utils/imageLoader.js +23 -0
- package/dist/cjs/utils/index.js +10 -0
- package/dist/cjs/utils/input-rules.js +4 -1
- package/dist/cjs/utils/macro.js +2 -0
- package/dist/cjs/utils/nodes.js +6 -1
- package/dist/cjs/utils/outdated-browsers.js +21 -1
- package/dist/cjs/utils/performance/is-performance-api-available.js +4 -1
- package/dist/cjs/utils/performance/measure-render.js +5 -0
- package/dist/cjs/utils/performance/measure-tti.js +5 -0
- package/dist/cjs/utils/plugin-state-factory.js +4 -0
- package/dist/cjs/utils/processRawValue.js +13 -1
- package/dist/cjs/utils/prosemirror/autojoin.js +2 -0
- package/dist/cjs/utils/referentiality.js +5 -0
- package/dist/cjs/utils/rich-media-utils.js +4 -1
- package/dist/cjs/utils/should-auto-linkify-tld.js +5 -0
- package/dist/cjs/utils/should-force-tracking.js +2 -0
- package/dist/cjs/utils/slice.js +2 -0
- package/dist/cjs/utils/track-unsupported-content.js +15 -2
- package/dist/cjs/utils/traversor.js +6 -0
- package/dist/cjs/utils/validate-using-spec.js +13 -1
- package/dist/cjs/utils/validator.js +19 -0
- package/dist/cjs/utils/withFeatureFlaggedComponent.js +4 -0
- package/dist/cjs/with-plugin-state/index.js +94 -20
- package/dist/es2019/analytics/analytics-queue.js +8 -0
- package/dist/es2019/analytics/linking-utils.js +2 -0
- package/dist/es2019/card/LinkToolbarButtonGroup.js +2 -0
- package/dist/es2019/card/MediaAndEmbedsToolbar/index.js +15 -3
- package/dist/es2019/card/ui/assets/card.js +4 -0
- package/dist/es2019/card/ui/assets/embed.js +4 -0
- package/dist/es2019/card/ui/assets/inline.js +4 -0
- package/dist/es2019/card/ui/assets/url.js +4 -0
- package/dist/es2019/clipboard/index.js +12 -1
- package/dist/es2019/collab/index.js +2 -0
- package/dist/es2019/commands/index.js +8 -2
- package/dist/es2019/commands/insert-block.js +10 -2
- package/dist/es2019/core-utils/document-logger.js +4 -0
- package/dist/es2019/doc-utils/editor-use-only.js +5 -1
- package/dist/es2019/element-browser/ElementBrowser.js +2 -0
- package/dist/es2019/element-browser/ViewMore.js +8 -2
- package/dist/es2019/element-browser/components/CategoryList.js +2 -0
- package/dist/es2019/element-browser/components/ElementList/ElementList.js +12 -0
- package/dist/es2019/element-browser/components/StatelessElementBrowser.js +8 -2
- package/dist/es2019/element-browser/hooks/use-select-and-focus-on-arrow-navigation.js +13 -2
- package/dist/es2019/event-dispatcher/index.js +8 -0
- package/dist/es2019/extensibility/Extension/Extension/index.js +2 -0
- package/dist/es2019/extensibility/Extension/Lozenge/ExtensionLabel.js +10 -2
- package/dist/es2019/extensibility/Extension/Lozenge/index.js +3 -1
- package/dist/es2019/extensibility/Extension.js +2 -0
- package/dist/es2019/extensibility/ExtensionComponent.js +15 -1
- package/dist/es2019/extensibility/MultiBodiedExtension/index.js +4 -0
- package/dist/es2019/extensibility/extensionNodeView.js +3 -0
- package/dist/es2019/extensions/extension-fields-helpers.js +4 -0
- package/dist/es2019/extensions/extension-handlers.js +4 -0
- package/dist/es2019/extensions/module-helpers.js +11 -2
- package/dist/es2019/extensions/types/field-definitions.js +5 -0
- package/dist/es2019/floating-toolbar/index.js +18 -2
- package/dist/es2019/guideline/dynamicGuideline.js +4 -1
- package/dist/es2019/guideline/relativeGuideline.js +12 -3
- package/dist/es2019/guideline/snapping.js +4 -1
- package/dist/es2019/guideline/updateGuideline.js +4 -1
- package/dist/es2019/hooks/usePluginStateEffect.js +4 -0
- package/dist/es2019/hooks/useSharedPluginState.js +4 -0
- package/dist/es2019/hooks/useSharedPluginStateSelector/useSharedPluginStateSelector.js +3 -0
- package/dist/es2019/icons/shared/BorderIcon.js +4 -0
- package/dist/es2019/icons/shared/PanelErrorIcon.js +4 -0
- package/dist/es2019/icons/shared/PanelInfoIcon.js +4 -0
- package/dist/es2019/icons/shared/PanelNoteIcon.js +4 -0
- package/dist/es2019/icons/shared/PanelSuccessIcon.js +4 -0
- package/dist/es2019/icons/shared/PanelWarningIcon.js +4 -0
- package/dist/es2019/insert/index.js +6 -1
- package/dist/es2019/keymaps/index.js +46 -4
- package/dist/es2019/keymaps/keymap.js +4 -0
- package/dist/es2019/lazy-node-view/css-helper.js +4 -0
- package/dist/es2019/lazy-node-view/index.js +6 -1
- package/dist/es2019/lazy-node-view/node-view.js +2 -0
- package/dist/es2019/link/ConfigureLinkOverlay/Dropdown.js +2 -0
- package/dist/es2019/link/ConfigureLinkOverlay/StyledButton.js +4 -1
- package/dist/es2019/link/LinkPicker/EditorLinkPicker/index.js +4 -1
- package/dist/es2019/link/LinkPicker/EditorLinkPicker/useEscapeClickaway.js +9 -0
- package/dist/es2019/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.js +19 -0
- package/dist/es2019/link/LinkPicker/HyperlinkAddToolbar/index.js +2 -0
- package/dist/es2019/link/LinkSearch/LinkSearchList.js +2 -0
- package/dist/es2019/link/LinkSearch/LinkSearchListItem.js +2 -0
- package/dist/es2019/link/LinkSearch/index.js +13 -0
- package/dist/es2019/link/LinkSearch/withActivityProvider.js +3 -0
- package/dist/es2019/lists/analytics.js +2 -0
- package/dist/es2019/mark/commands.js +24 -3
- package/dist/es2019/media-inline/inline-image-card.js +4 -2
- package/dist/es2019/media-inline/inline-image-wrapper.js +2 -0
- package/dist/es2019/media-single/MediaBadges.js +2 -0
- package/dist/es2019/media-single/utils.js +5 -0
- package/dist/es2019/monitoring/environment.js +6 -1
- package/dist/es2019/monitoring/error.js +19 -3
- package/dist/es2019/node-width/index.js +6 -1
- package/dist/es2019/normalize-feature-flags.js +4 -1
- package/dist/es2019/paste/clipboard.js +2 -0
- package/dist/es2019/paste/md-plugins/ignore-list-heading-md-plugin.js +5 -0
- package/dist/es2019/paste/md-plugins/linkify-md-plugin.js +20 -0
- package/dist/es2019/paste/md-plugins/newline-md-plugin.js +5 -0
- package/dist/es2019/paste/md-plugins/paragraph-md-plugin.js +5 -0
- package/dist/es2019/portal/common.js +4 -1
- package/dist/es2019/preset/builder.js +8 -0
- package/dist/es2019/preset/core-plugin/index.js +5 -0
- package/dist/es2019/preset/core-plugin/requestDocument.js +3 -0
- package/dist/es2019/preset/plugin-injection-api.js +62 -6
- package/dist/es2019/provider-factory/provider-factory.js +8 -1
- package/dist/es2019/provider-factory/with-providers.js +12 -0
- package/dist/es2019/provider-helpers/combine-providers.js +7 -0
- package/dist/es2019/provider-helpers/promise-helpers.js +3 -0
- package/dist/es2019/quick-insert/assets/index.js +2 -0
- package/dist/es2019/react-node-view/getInlineNodeViewProducer.js +4 -0
- package/dist/es2019/react-node-view/index.js +32 -2
- package/dist/es2019/resizer/BreakoutResizer.js +1 -7
- package/dist/es2019/resizer/Resizer.js +10 -2
- package/dist/es2019/safe-plugin/index.js +3 -0
- package/dist/es2019/selection/gap-cursor/actions.js +11 -2
- package/dist/es2019/selection/gap-cursor/selection.js +8 -0
- package/dist/es2019/selection/index.js +2 -0
- package/dist/es2019/selection-based-node-view/SelectionBasedNodeView.js +10 -1
- package/dist/es2019/styles/shared/lists.js +4 -1
- package/dist/es2019/transforms/code-block.js +6 -0
- package/dist/es2019/transforms/extension.js +14 -2
- package/dist/es2019/transforms/layout.js +6 -0
- package/dist/es2019/types/annotation/emitter.js +4 -0
- package/dist/es2019/types/index.js +3 -1
- package/dist/es2019/ui/Caption/index.js +4 -0
- package/dist/es2019/ui/ContextPanel/context.js +4 -0
- package/dist/es2019/ui/DropList/index.js +12 -2
- package/dist/es2019/ui/Emoji/index.js +2 -0
- package/dist/es2019/ui/ErrorBoundary/index.js +2 -0
- package/dist/es2019/ui/Expand/index.js +13 -6
- package/dist/es2019/ui/FloatingToolbar/Button.js +2 -0
- package/dist/es2019/ui/FloatingToolbar/ButtonSpotlightCard.js +4 -1
- package/dist/es2019/ui/FloatingToolbar/styles.js +3 -0
- package/dist/es2019/ui/IntlErrorBoundary/index.js +3 -0
- package/dist/es2019/ui/Layer/index.js +8 -0
- package/dist/es2019/ui/MediaSingle/grid.js +12 -2
- package/dist/es2019/ui/MediaSingle/index.js +2 -0
- package/dist/es2019/ui/MediaSingle/styled.js +6 -0
- package/dist/es2019/ui/Mention/mention-with-profilecard.js +4 -1
- package/dist/es2019/ui/Mention/mention-with-providers.js +18 -2
- package/dist/es2019/ui/OverflowShadow/index.js +19 -5
- package/dist/es2019/ui/OverflowShadow/shadowObserver.js +12 -2
- package/dist/es2019/ui/PanelTextInput/index.js +14 -0
- package/dist/es2019/ui/Popup/index.js +21 -1
- package/dist/es2019/ui/Popup/utils.js +19 -0
- package/dist/es2019/ui/ResizerLegacy/index.js +7 -0
- package/dist/es2019/ui/unsupported-content-helper.js +6 -1
- package/dist/es2019/ui/with-outer-listeners.js +12 -1
- package/dist/es2019/ui-color/ColorPalette/utils.js +2 -0
- package/dist/es2019/ui-menu/ArrowKeyNavigationProvider/ColorPaletteArrowKeyNavigationProvider/index.js +9 -0
- package/dist/es2019/ui-menu/ArrowKeyNavigationProvider/MenuArrowKeyNavigationProvider/index.js +12 -0
- package/dist/es2019/ui-menu/ArrowKeyNavigationProvider/index.js +4 -0
- package/dist/es2019/ui-menu/Dropdown/index.js +9 -2
- package/dist/es2019/ui-menu/DropdownContainer/index.js +4 -1
- package/dist/es2019/ui-menu/DropdownMenu/index.js +20 -3
- package/dist/es2019/ui-menu/ToolbarArrowKeyNavigationProvider/index.js +17 -0
- package/dist/es2019/ui-menu/ToolbarButton/styles.js +2 -0
- package/dist/es2019/ui-react/with-react-editor-view-outer-listeners.js +27 -4
- package/dist/es2019/utils/breakout.js +4 -0
- package/dist/es2019/utils/browser-extensions.js +4 -0
- package/dist/es2019/utils/browser.js +47 -5
- package/dist/es2019/utils/commands.js +4 -1
- package/dist/es2019/utils/compare-props.js +4 -1
- package/dist/es2019/utils/compareNodes.js +7 -0
- package/dist/es2019/utils/compose.js +2 -0
- package/dist/es2019/utils/create-wrap-selection-transaction.js +9 -1
- package/dist/es2019/utils/dom.js +2 -0
- package/dist/es2019/utils/editor-core-utils.js +5 -0
- package/dist/es2019/utils/filter/privacy-filter.js +2 -0
- package/dist/es2019/utils/get-performance-options.js +2 -0
- package/dist/es2019/utils/hyperlink.js +16 -0
- package/dist/es2019/utils/imageLoader.js +23 -0
- package/dist/es2019/utils/index.js +11 -0
- package/dist/es2019/utils/input-rules.js +4 -1
- package/dist/es2019/utils/macro.js +2 -0
- package/dist/es2019/utils/nodes.js +6 -1
- package/dist/es2019/utils/outdated-browsers.js +21 -1
- package/dist/es2019/utils/performance/is-performance-api-available.js +4 -1
- package/dist/es2019/utils/performance/measure-render.js +6 -1
- package/dist/es2019/utils/performance/measure-tti.js +6 -0
- package/dist/es2019/utils/plugin-state-factory.js +4 -0
- package/dist/es2019/utils/processRawValue.js +13 -1
- package/dist/es2019/utils/prosemirror/autojoin.js +2 -0
- package/dist/es2019/utils/referentiality.js +5 -0
- package/dist/es2019/utils/rich-media-utils.js +4 -1
- package/dist/es2019/utils/should-auto-linkify-tld.js +5 -0
- package/dist/es2019/utils/should-force-tracking.js +2 -0
- package/dist/es2019/utils/slice.js +2 -0
- package/dist/es2019/utils/track-unsupported-content.js +19 -3
- package/dist/es2019/utils/traversor.js +7 -0
- package/dist/es2019/utils/validate-using-spec.js +13 -1
- package/dist/es2019/utils/validator.js +19 -0
- package/dist/es2019/utils/withFeatureFlaggedComponent.js +4 -0
- package/dist/es2019/with-plugin-state/index.js +77 -3
- package/dist/esm/analytics/analytics-queue.js +8 -0
- package/dist/esm/analytics/linking-utils.js +2 -0
- package/dist/esm/card/LinkToolbarButtonGroup.js +2 -0
- package/dist/esm/card/MediaAndEmbedsToolbar/index.js +15 -3
- package/dist/esm/card/ui/assets/card.js +4 -0
- package/dist/esm/card/ui/assets/embed.js +4 -0
- package/dist/esm/card/ui/assets/inline.js +4 -0
- package/dist/esm/card/ui/assets/url.js +4 -0
- package/dist/esm/clipboard/index.js +11 -1
- package/dist/esm/collab/index.js +2 -0
- package/dist/esm/commands/index.js +50 -42
- package/dist/esm/commands/insert-block.js +10 -2
- package/dist/esm/core-utils/document-logger.js +4 -0
- package/dist/esm/doc-utils/editor-use-only.js +8 -3
- package/dist/esm/element-browser/ElementBrowser.js +2 -0
- package/dist/esm/element-browser/ViewMore.js +8 -2
- package/dist/esm/element-browser/components/CategoryList.js +2 -0
- package/dist/esm/element-browser/components/ElementList/ElementList.js +12 -0
- package/dist/esm/element-browser/components/StatelessElementBrowser.js +8 -2
- package/dist/esm/element-browser/hooks/use-select-and-focus-on-arrow-navigation.js +13 -2
- package/dist/esm/event-dispatcher/index.js +8 -0
- package/dist/esm/extensibility/Extension/Extension/index.js +2 -0
- package/dist/esm/extensibility/Extension/Lozenge/ExtensionLabel.js +10 -2
- package/dist/esm/extensibility/Extension/Lozenge/index.js +3 -1
- package/dist/esm/extensibility/Extension.js +2 -0
- package/dist/esm/extensibility/ExtensionComponent.js +17 -2
- package/dist/esm/extensibility/MultiBodiedExtension/index.js +4 -0
- package/dist/esm/extensibility/extensionNodeView.js +3 -0
- package/dist/esm/extensions/extension-fields-helpers.js +4 -1
- package/dist/esm/extensions/extension-handlers.js +4 -0
- package/dist/esm/extensions/module-helpers.js +15 -5
- package/dist/esm/extensions/types/field-definitions.js +5 -0
- package/dist/esm/floating-toolbar/index.js +18 -2
- package/dist/esm/guideline/dynamicGuideline.js +4 -1
- package/dist/esm/guideline/relativeGuideline.js +12 -3
- package/dist/esm/guideline/updateGuideline.js +4 -1
- package/dist/esm/hooks/usePluginStateEffect.js +4 -0
- package/dist/esm/hooks/useSharedPluginState.js +4 -0
- package/dist/esm/hooks/useSharedPluginStateSelector/useSharedPluginStateSelector.js +3 -0
- package/dist/esm/icons/shared/BorderIcon.js +4 -0
- package/dist/esm/icons/shared/PanelErrorIcon.js +4 -0
- package/dist/esm/icons/shared/PanelInfoIcon.js +4 -0
- package/dist/esm/icons/shared/PanelNoteIcon.js +4 -0
- package/dist/esm/icons/shared/PanelSuccessIcon.js +4 -0
- package/dist/esm/icons/shared/PanelWarningIcon.js +4 -0
- package/dist/esm/insert/index.js +6 -1
- package/dist/esm/keymaps/index.js +48 -5
- package/dist/esm/keymaps/keymap.js +4 -0
- package/dist/esm/lazy-node-view/css-helper.js +4 -0
- package/dist/esm/lazy-node-view/index.js +6 -1
- package/dist/esm/lazy-node-view/node-view.js +2 -0
- package/dist/esm/link/ConfigureLinkOverlay/Dropdown.js +2 -0
- package/dist/esm/link/ConfigureLinkOverlay/StyledButton.js +4 -1
- package/dist/esm/link/LinkPicker/EditorLinkPicker/index.js +4 -1
- package/dist/esm/link/LinkPicker/EditorLinkPicker/useEscapeClickaway.js +9 -0
- package/dist/esm/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.js +16 -1
- package/dist/esm/link/LinkPicker/HyperlinkAddToolbar/index.js +2 -0
- package/dist/esm/link/LinkSearch/LinkSearchList.js +2 -0
- package/dist/esm/link/LinkSearch/LinkSearchListItem.js +2 -0
- package/dist/esm/link/LinkSearch/index.js +9 -1
- package/dist/esm/link/LinkSearch/withActivityProvider.js +3 -0
- package/dist/esm/lists/analytics.js +2 -0
- package/dist/esm/mark/commands.js +24 -3
- package/dist/esm/media-inline/inline-image-card.js +4 -2
- package/dist/esm/media-inline/inline-image-wrapper.js +2 -0
- package/dist/esm/media-single/MediaBadges.js +2 -0
- package/dist/esm/media-single/utils.js +5 -0
- package/dist/esm/monitoring/environment.js +6 -1
- package/dist/esm/monitoring/error.js +19 -3
- package/dist/esm/node-width/index.js +6 -1
- package/dist/esm/normalize-feature-flags.js +4 -1
- package/dist/esm/paste/clipboard.js +2 -0
- package/dist/esm/paste/md-plugins/ignore-list-heading-md-plugin.js +5 -0
- package/dist/esm/paste/md-plugins/linkify-md-plugin.js +20 -0
- package/dist/esm/paste/md-plugins/newline-md-plugin.js +5 -0
- package/dist/esm/paste/md-plugins/paragraph-md-plugin.js +5 -0
- package/dist/esm/portal/common.js +4 -1
- package/dist/esm/preset/builder.js +8 -0
- package/dist/esm/preset/core-plugin/index.js +5 -0
- package/dist/esm/preset/core-plugin/requestDocument.js +3 -0
- package/dist/esm/preset/plugin-injection-api.js +62 -6
- package/dist/esm/provider-factory/provider-factory.js +8 -1
- package/dist/esm/provider-factory/with-providers.js +12 -0
- package/dist/esm/provider-helpers/combine-providers.js +7 -0
- package/dist/esm/provider-helpers/promise-helpers.js +3 -0
- package/dist/esm/quick-insert/assets/index.js +2 -0
- package/dist/esm/react-node-view/getInlineNodeViewProducer.js +4 -0
- package/dist/esm/react-node-view/index.js +33 -2
- package/dist/esm/resizer/BreakoutResizer.js +1 -7
- package/dist/esm/resizer/Resizer.js +10 -2
- package/dist/esm/safe-plugin/index.js +3 -0
- package/dist/esm/selection/gap-cursor/actions.js +11 -2
- package/dist/esm/selection/gap-cursor/selection.js +8 -0
- package/dist/esm/selection/index.js +2 -0
- package/dist/esm/selection-based-node-view/SelectionBasedNodeView.js +10 -1
- package/dist/esm/styles/shared/lists.js +4 -1
- package/dist/esm/transforms/code-block.js +6 -0
- package/dist/esm/transforms/extension.js +14 -2
- package/dist/esm/transforms/layout.js +6 -0
- package/dist/esm/types/annotation/emitter.js +8 -2
- package/dist/esm/types/index.js +3 -1
- package/dist/esm/ui/Caption/index.js +4 -0
- package/dist/esm/ui/ContextPanel/context.js +4 -0
- package/dist/esm/ui/DropList/index.js +11 -1
- package/dist/esm/ui/Emoji/index.js +2 -0
- package/dist/esm/ui/ErrorBoundary/index.js +2 -0
- package/dist/esm/ui/Expand/index.js +13 -6
- package/dist/esm/ui/FloatingToolbar/Button.js +2 -0
- package/dist/esm/ui/FloatingToolbar/ButtonSpotlightCard.js +4 -1
- package/dist/esm/ui/FloatingToolbar/styles.js +3 -0
- package/dist/esm/ui/IntlErrorBoundary/index.js +3 -0
- package/dist/esm/ui/Layer/index.js +8 -0
- package/dist/esm/ui/MediaSingle/grid.js +12 -2
- package/dist/esm/ui/MediaSingle/index.js +2 -0
- package/dist/esm/ui/MediaSingle/styled.js +6 -0
- package/dist/esm/ui/Mention/mention-with-profilecard.js +4 -1
- package/dist/esm/ui/Mention/mention-with-providers.js +20 -3
- package/dist/esm/ui/OverflowShadow/index.js +18 -4
- package/dist/esm/ui/OverflowShadow/shadowObserver.js +12 -2
- package/dist/esm/ui/PanelTextInput/index.js +16 -1
- package/dist/esm/ui/Popup/index.js +23 -2
- package/dist/esm/ui/Popup/utils.js +19 -0
- package/dist/esm/ui/ResizerLegacy/index.js +7 -0
- package/dist/esm/ui/unsupported-content-helper.js +6 -1
- package/dist/esm/ui/with-outer-listeners.js +12 -1
- package/dist/esm/ui-color/ColorPalette/utils.js +2 -0
- package/dist/esm/ui-menu/ArrowKeyNavigationProvider/ColorPaletteArrowKeyNavigationProvider/index.js +9 -0
- package/dist/esm/ui-menu/ArrowKeyNavigationProvider/MenuArrowKeyNavigationProvider/index.js +12 -0
- package/dist/esm/ui-menu/ArrowKeyNavigationProvider/index.js +4 -0
- package/dist/esm/ui-menu/Dropdown/index.js +9 -2
- package/dist/esm/ui-menu/DropdownContainer/index.js +4 -1
- package/dist/esm/ui-menu/DropdownMenu/index.js +20 -3
- package/dist/esm/ui-menu/ToolbarArrowKeyNavigationProvider/index.js +17 -0
- package/dist/esm/ui-menu/ToolbarButton/styles.js +2 -0
- package/dist/esm/ui-react/with-react-editor-view-outer-listeners.js +29 -4
- package/dist/esm/utils/breakout.js +4 -0
- package/dist/esm/utils/browser-extensions.js +4 -0
- package/dist/esm/utils/browser.js +47 -5
- package/dist/esm/utils/commands.js +4 -1
- package/dist/esm/utils/compareNodes.js +7 -0
- package/dist/esm/utils/compose.js +2 -0
- package/dist/esm/utils/create-wrap-selection-transaction.js +9 -1
- package/dist/esm/utils/dom.js +2 -0
- package/dist/esm/utils/editor-core-utils.js +5 -0
- package/dist/esm/utils/filter/privacy-filter.js +2 -0
- package/dist/esm/utils/get-performance-options.js +2 -0
- package/dist/esm/utils/hyperlink.js +16 -0
- package/dist/esm/utils/imageLoader.js +23 -0
- package/dist/esm/utils/index.js +11 -0
- package/dist/esm/utils/input-rules.js +4 -1
- package/dist/esm/utils/macro.js +2 -0
- package/dist/esm/utils/nodes.js +6 -1
- package/dist/esm/utils/outdated-browsers.js +21 -1
- package/dist/esm/utils/performance/is-performance-api-available.js +4 -1
- package/dist/esm/utils/performance/measure-render.js +5 -0
- package/dist/esm/utils/performance/measure-tti.js +6 -0
- package/dist/esm/utils/plugin-state-factory.js +4 -0
- package/dist/esm/utils/processRawValue.js +13 -1
- package/dist/esm/utils/prosemirror/autojoin.js +2 -0
- package/dist/esm/utils/referentiality.js +5 -0
- package/dist/esm/utils/rich-media-utils.js +4 -1
- package/dist/esm/utils/should-auto-linkify-tld.js +5 -0
- package/dist/esm/utils/should-force-tracking.js +2 -0
- package/dist/esm/utils/slice.js +2 -0
- package/dist/esm/utils/track-unsupported-content.js +15 -2
- package/dist/esm/utils/traversor.js +6 -0
- package/dist/esm/utils/validate-using-spec.js +13 -1
- package/dist/esm/utils/validator.js +19 -0
- package/dist/esm/utils/withFeatureFlaggedComponent.js +4 -0
- package/dist/esm/with-plugin-state/index.js +95 -19
- package/dist/types/analytics/types/avatar.d.ts +1 -1
- package/dist/types/analytics/types/toolbar-button.d.ts +1 -1
- package/dist/types/analytics/types/utils.d.ts +2 -2
- package/dist/types/annotation/index.d.ts +1 -1
- package/dist/types/commands/index.d.ts +3 -3
- package/dist/types/guideline/types.d.ts +1 -2
- package/dist/types/hooks/usePluginStateEffect.d.ts +2 -1
- package/dist/types/link/LinkPicker/EditorLinkPicker/index.d.ts +1 -1
- package/dist/types/link/LinkSearch/LinkSearchList.d.ts +1 -1
- package/dist/types/provider-factory/macro-provider.d.ts +1 -1
- package/dist/types/selection/types.d.ts +1 -2
- package/dist/types/types/floating-toolbar.d.ts +16 -16
- package/dist/types/types/hyperlink.d.ts +1 -2
- package/dist/types/ui/Mention/index.d.ts +1 -1
- package/dist/types/ui-react/with-react-editor-view-outer-listeners.d.ts +1 -1
- package/dist/types/utils/imageLoader.d.ts +2 -2
- package/dist/types-ts4.5/analytics/types/avatar.d.ts +1 -1
- package/dist/types-ts4.5/analytics/types/toolbar-button.d.ts +1 -1
- package/dist/types-ts4.5/analytics/types/utils.d.ts +2 -2
- package/dist/types-ts4.5/annotation/index.d.ts +1 -1
- package/dist/types-ts4.5/commands/index.d.ts +3 -3
- package/dist/types-ts4.5/guideline/types.d.ts +1 -2
- package/dist/types-ts4.5/hooks/usePluginStateEffect.d.ts +2 -1
- package/dist/types-ts4.5/link/LinkPicker/EditorLinkPicker/index.d.ts +1 -1
- package/dist/types-ts4.5/link/LinkSearch/LinkSearchList.d.ts +1 -1
- package/dist/types-ts4.5/provider-factory/macro-provider.d.ts +1 -1
- package/dist/types-ts4.5/selection/types.d.ts +1 -2
- package/dist/types-ts4.5/types/floating-toolbar.d.ts +16 -16
- package/dist/types-ts4.5/types/hyperlink.d.ts +1 -2
- package/dist/types-ts4.5/ui/Mention/index.d.ts +1 -1
- package/dist/types-ts4.5/ui-react/with-react-editor-view-outer-listeners.d.ts +1 -1
- package/dist/types-ts4.5/utils/imageLoader.d.ts +2 -2
- package/package.json +7 -7
- package/tsconfig.json +0 -1
|
@@ -24,6 +24,8 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
|
|
|
24
24
|
* @jsxRuntime classic
|
|
25
25
|
* @jsx jsx
|
|
26
26
|
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
27
|
+
// Ignored via go/ees005
|
|
28
|
+
// eslint-disable-next-line @repo/internal/react/no-class-components, @typescript-eslint/no-explicit-any
|
|
27
29
|
var ExtensionLozenge = exports.default = /*#__PURE__*/function (_Component) {
|
|
28
30
|
function ExtensionLozenge() {
|
|
29
31
|
var _this;
|
|
@@ -36,7 +38,7 @@ var ExtensionLozenge = exports.default = /*#__PURE__*/function (_Component) {
|
|
|
36
38
|
var extensionKey = _this.props.node.attrs.extensionKey;
|
|
37
39
|
var url = lozengeData.url,
|
|
38
40
|
rest = (0, _objectWithoutProperties2.default)(lozengeData, _excluded);
|
|
39
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
|
|
41
|
+
// eslint-disable-next-line react/jsx-props-no-spreading, @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
|
|
40
42
|
return (0, _react2.jsx)("img", (0, _extends2.default)({
|
|
41
43
|
css: _styles.styledImage,
|
|
42
44
|
src: url
|
|
@@ -19,6 +19,8 @@ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return
|
|
|
19
19
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
20
20
|
function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); }
|
|
21
21
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
22
|
+
// Ignored via go/ees005
|
|
23
|
+
// eslint-disable-next-line @repo/internal/react/no-class-components, @typescript-eslint/no-explicit-any
|
|
22
24
|
var Extension = exports.Extension = /*#__PURE__*/function (_Component) {
|
|
23
25
|
function Extension(props) {
|
|
24
26
|
var _this;
|
|
@@ -67,6 +67,8 @@ var ExtensionComponentOld = exports.ExtensionComponentOld = /*#__PURE__*/functio
|
|
|
67
67
|
showBodiedExtensionRendererView: showRendererView
|
|
68
68
|
});
|
|
69
69
|
});
|
|
70
|
+
// Ignored via go/ees005
|
|
71
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
70
72
|
(0, _defineProperty2.default)(_this, "setStateFromPromise", function (stateKey, promise) {
|
|
71
73
|
promise && promise.then(function (p) {
|
|
72
74
|
if (!_this.mounted) {
|
|
@@ -188,7 +190,10 @@ var ExtensionComponentOld = exports.ExtensionComponentOld = /*#__PURE__*/functio
|
|
|
188
190
|
(0, _inherits2.default)(ExtensionComponentOld, _Component);
|
|
189
191
|
return (0, _createClass2.default)(ExtensionComponentOld, [{
|
|
190
192
|
key: "UNSAFE_componentWillMount",
|
|
191
|
-
value:
|
|
193
|
+
value:
|
|
194
|
+
// Ignored via go/ees005
|
|
195
|
+
// eslint-disable-next-line react/no-unsafe
|
|
196
|
+
function UNSAFE_componentWillMount() {
|
|
192
197
|
this.mounted = true;
|
|
193
198
|
var _this$props2 = this.props,
|
|
194
199
|
node = _this$props2.node,
|
|
@@ -218,6 +223,9 @@ var ExtensionComponentOld = exports.ExtensionComponentOld = /*#__PURE__*/functio
|
|
|
218
223
|
value: function componentWillUnmount() {
|
|
219
224
|
this.mounted = false;
|
|
220
225
|
}
|
|
226
|
+
|
|
227
|
+
// Ignored via go/ees005
|
|
228
|
+
// eslint-disable-next-line react/no-unsafe
|
|
221
229
|
}, {
|
|
222
230
|
key: "UNSAFE_componentWillReceiveProps",
|
|
223
231
|
value: function UNSAFE_componentWillReceiveProps(nextProps) {
|
|
@@ -347,7 +355,10 @@ var ExtensionComponentNew = exports.ExtensionComponentNew = function ExtensionCo
|
|
|
347
355
|
}
|
|
348
356
|
});
|
|
349
357
|
}, [extensionProviderResolver]);
|
|
350
|
-
return /*#__PURE__*/_react.default.createElement(ExtensionComponentInner
|
|
358
|
+
return /*#__PURE__*/_react.default.createElement(ExtensionComponentInner
|
|
359
|
+
// Ignored via go/ees005
|
|
360
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
361
|
+
, (0, _extends2.default)({}, restProps, {
|
|
351
362
|
extensionProvider: extensionProvider,
|
|
352
363
|
node: node,
|
|
353
364
|
showLivePagesBodiedMacrosRendererView: showLivePagesBodiedMacrosRendererView,
|
|
@@ -588,7 +599,11 @@ var ExtensionComponentInner = /*#__PURE__*/function (_Component2) {
|
|
|
588
599
|
}(_react.Component);
|
|
589
600
|
var ExtensionComponent = exports.ExtensionComponent = function ExtensionComponent(props) {
|
|
590
601
|
if ((0, _platformFeatureFlags.fg)('platform_editor_react18_extension_component_v2')) {
|
|
602
|
+
// Ignored via go/ees005
|
|
603
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
591
604
|
return /*#__PURE__*/_react.default.createElement(ExtensionComponentNew, props);
|
|
592
605
|
}
|
|
606
|
+
// Ignored via go/ees005
|
|
607
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
593
608
|
return /*#__PURE__*/_react.default.createElement(ExtensionComponentOld, props);
|
|
594
609
|
};
|
|
@@ -61,6 +61,8 @@ var getWrapperTitleContent = function getWrapperTitleContent(imageData, title, s
|
|
|
61
61
|
}, (0, _react2.jsx)("img", (0, _extends2.default)({
|
|
62
62
|
css: imageStyles,
|
|
63
63
|
src: url
|
|
64
|
+
// Ignored via go/ees005
|
|
65
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
64
66
|
}, rest, {
|
|
65
67
|
alt: title
|
|
66
68
|
})), title)
|
|
@@ -219,6 +221,8 @@ var MultiBodiedExtension = function MultiBodiedExtension(props) {
|
|
|
219
221
|
var pluginInjectionApi = props.pluginInjectionApi;
|
|
220
222
|
var _useSharedPluginState = (0, _hooks.useSharedPluginState)(pluginInjectionApi, ['width']),
|
|
221
223
|
widthState = _useSharedPluginState.widthState;
|
|
224
|
+
// Ignored via go/ees005
|
|
225
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
222
226
|
return (0, _react2.jsx)(MultiBodiedExtensionWithWidth, (0, _extends2.default)({
|
|
223
227
|
widthState: widthState
|
|
224
228
|
}, props));
|
|
@@ -80,7 +80,8 @@ var ExtensionNode = exports.ExtensionNode = /*#__PURE__*/function (_ReactNodeVie
|
|
|
80
80
|
}));
|
|
81
81
|
}
|
|
82
82
|
}]);
|
|
83
|
-
}(_reactNodeView.default);
|
|
83
|
+
}(_reactNodeView.default); // Ignored via go/ees005
|
|
84
|
+
// eslint-disable-next-line @typescript-eslint/max-params
|
|
84
85
|
function ExtensionNodeView(portalProviderAPI, eventDispatcher, providerFactory, extensionHandlers, extensionNodeViewOptions, pluginInjectionApi, macroInteractionDesignFeatureFlags, showLivePagesBodiedMacrosRendererView, showUpdatedLivePages1PBodiedExtensionUI, rendererExtensionHandlers) {
|
|
85
86
|
return function (node, view, getPos) {
|
|
86
87
|
return new ExtensionNode(node, view, getPos, portalProviderAPI, eventDispatcher, {
|
|
@@ -10,6 +10,8 @@ exports.getFieldSerializer = getFieldSerializer;
|
|
|
10
10
|
exports.getUserFieldContextProvider = getUserFieldContextProvider;
|
|
11
11
|
var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"));
|
|
12
12
|
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
|
|
13
|
+
// Ignored via go/ees005
|
|
14
|
+
// eslint-disable-next-line require-await
|
|
13
15
|
function getExtensionModuleField(_x, _x2, _x3) {
|
|
14
16
|
return _getExtensionModuleField.apply(this, arguments);
|
|
15
17
|
}
|
|
@@ -38,7 +40,8 @@ function _getExtensionModuleField() {
|
|
|
38
40
|
}
|
|
39
41
|
throw new Error("No definition for field type \"".concat(fieldType, "\" on manifest for extension with type \"").concat(manifest.type, "\" and key \"").concat(manifest.key, "\""));
|
|
40
42
|
case 6:
|
|
41
|
-
type = handlerLink.type;
|
|
43
|
+
type = handlerLink.type; // Ignored via go/ees005
|
|
44
|
+
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
42
45
|
handler = manifest.modules.fields[fieldType][type];
|
|
43
46
|
if (handler) {
|
|
44
47
|
_context.next = 10;
|
|
@@ -74,8 +74,12 @@ function _getExtensionModuleNodePrivateProps() {
|
|
|
74
74
|
return _context2.abrupt("return", Object.keys(moduleNode).filter(function (key) {
|
|
75
75
|
return key.startsWith('__');
|
|
76
76
|
}).reduce(function (acc, key) {
|
|
77
|
+
// Ignored via go/ees005
|
|
78
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
77
79
|
acc[key] = moduleNode[key];
|
|
78
80
|
return acc;
|
|
81
|
+
// Ignored via go/ees005
|
|
82
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
79
83
|
}, {}));
|
|
80
84
|
case 4:
|
|
81
85
|
case "end":
|
|
@@ -21,10 +21,14 @@ function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol
|
|
|
21
21
|
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
22
22
|
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
23
23
|
var groupBy = exports.groupBy = function groupBy(arr, attr, keyRenamer) {
|
|
24
|
-
return
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
24
|
+
return (
|
|
25
|
+
// Ignored via go/ees005
|
|
26
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
27
|
+
arr.reduce(function (acc, item) {
|
|
28
|
+
acc[keyRenamer(item[attr])] = item;
|
|
29
|
+
return acc;
|
|
30
|
+
}, {})
|
|
31
|
+
);
|
|
28
32
|
};
|
|
29
33
|
function buildMenuItem(manifest, extensionModule) {
|
|
30
34
|
var title = extensionModule.title || manifest.title;
|
|
@@ -70,7 +74,10 @@ function _getAutoConvertPatternsFromModule() {
|
|
|
70
74
|
while (1) switch (_context2.prev = _context2.next) {
|
|
71
75
|
case 0:
|
|
72
76
|
_context2.next = 2;
|
|
73
|
-
return Promise.all(
|
|
77
|
+
return Promise.all(
|
|
78
|
+
// Ignored via go/ees005
|
|
79
|
+
// eslint-disable-next-line require-await
|
|
80
|
+
extensions.map( /*#__PURE__*/function () {
|
|
74
81
|
var _ref2 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee(manifest) {
|
|
75
82
|
return _regenerator.default.wrap(function _callee$(_context) {
|
|
76
83
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -124,7 +131,8 @@ var createAutoConverterRunner = exports.createAutoConverterRunner = function cre
|
|
|
124
131
|
};
|
|
125
132
|
function getExtensionAutoConvertersFromProvider(_x2) {
|
|
126
133
|
return _getExtensionAutoConvertersFromProvider.apply(this, arguments);
|
|
127
|
-
}
|
|
134
|
+
} // Ignored via go/ees005
|
|
135
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
128
136
|
function _getExtensionAutoConvertersFromProvider() {
|
|
129
137
|
_getExtensionAutoConvertersFromProvider = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee3(extensionProviderPromise) {
|
|
130
138
|
var extensionProvider, extensionAutoConverters;
|
|
@@ -15,12 +15,17 @@ var isFieldset = exports.isFieldset = function isFieldset(field) {
|
|
|
15
15
|
var isTabGroup = exports.isTabGroup = function isTabGroup(field) {
|
|
16
16
|
return field.type === 'tab-group';
|
|
17
17
|
};
|
|
18
|
+
// Ignored via go/ees005
|
|
19
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
18
20
|
var isTabField = exports.isTabField = function isTabField(field) {
|
|
19
21
|
return 'type' in field && field.type === 'tab';
|
|
20
22
|
};
|
|
21
23
|
var isExpand = exports.isExpand = function isExpand(field) {
|
|
22
24
|
return field.type === 'expand';
|
|
23
25
|
};
|
|
26
|
+
|
|
27
|
+
// Ignored via go/ees005
|
|
28
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
24
29
|
var isDateRange = exports.isDateRange = function isDateRange(value) {
|
|
25
30
|
return value && value.hasOwnProperty('type') && value.type === 'date-range';
|
|
26
31
|
};
|
|
@@ -13,6 +13,8 @@ Object.defineProperty(exports, "messages", {
|
|
|
13
13
|
});
|
|
14
14
|
exports.shallowEqual = void 0;
|
|
15
15
|
var _messages = _interopRequireDefault(require("./messages"));
|
|
16
|
+
// Ignored via go/ees005
|
|
17
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
16
18
|
function makeSameType(_a, _b) {
|
|
17
19
|
return true;
|
|
18
20
|
}
|
|
@@ -34,12 +36,18 @@ var shallowEqual = exports.shallowEqual = function shallowEqual(objA, objB) {
|
|
|
34
36
|
if (!bHasOwnProperty(key)) {
|
|
35
37
|
return false;
|
|
36
38
|
}
|
|
39
|
+
|
|
40
|
+
// Ignored via go/ees005
|
|
41
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
37
42
|
if (objA[key] !== objB[key]) {
|
|
38
43
|
return false;
|
|
39
44
|
}
|
|
40
45
|
}
|
|
41
46
|
return true;
|
|
42
47
|
};
|
|
48
|
+
|
|
49
|
+
// Ignored via go/ees005
|
|
50
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
43
51
|
var compareArrays = exports.compareArrays = function compareArrays(left, right) {
|
|
44
52
|
var compareFn = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : shallowEqual;
|
|
45
53
|
if (left.length !== right.length) {
|
|
@@ -57,7 +65,12 @@ var compareItemWithKeys = function compareItemWithKeys(leftItem, rightItem) {
|
|
|
57
65
|
return Object.keys(leftItem).filter(function (key) {
|
|
58
66
|
return excludedKeys.indexOf(key) === -1;
|
|
59
67
|
}).every(function (key) {
|
|
60
|
-
return leftItem[key] instanceof Object ?
|
|
68
|
+
return leftItem[key] instanceof Object ?
|
|
69
|
+
// Ignored via go/ees005
|
|
70
|
+
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
71
|
+
// Ignored via go/ees005
|
|
72
|
+
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
73
|
+
shallowEqual(leftItem[key], rightItem[key]) : leftItem[key] === rightItem[key];
|
|
61
74
|
});
|
|
62
75
|
};
|
|
63
76
|
var isSameItem = exports.isSameItem = function isSameItem(leftItem, rightItem) {
|
|
@@ -74,7 +87,10 @@ var isSameItem = exports.isSameItem = function isSameItem(leftItem, rightItem) {
|
|
|
74
87
|
case 'input':
|
|
75
88
|
return compareItemWithKeys(leftItem, rightItem, ['type', 'onSubmit', 'onBlur']);
|
|
76
89
|
case 'select':
|
|
77
|
-
if (makeSameType(leftItem, rightItem) && Array.isArray(leftItem.options) && Array.isArray(rightItem.options) &&
|
|
90
|
+
if (makeSameType(leftItem, rightItem) && Array.isArray(leftItem.options) && Array.isArray(rightItem.options) &&
|
|
91
|
+
// Ignored via go/ees005
|
|
92
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
93
|
+
!compareArrays(leftItem.options, rightItem.options, function (left, right) {
|
|
78
94
|
return compareItemWithKeys(left, right);
|
|
79
95
|
})) {
|
|
80
96
|
return false;
|
|
@@ -61,7 +61,10 @@ var generateDynamicGuidelines = exports.generateDynamicGuidelines = function gen
|
|
|
61
61
|
dynamicGuides: []
|
|
62
62
|
});
|
|
63
63
|
};
|
|
64
|
-
var getDynamicGuides = function getDynamicGuides(layout, width, offset, key, styles
|
|
64
|
+
var getDynamicGuides = function getDynamicGuides(layout, width, offset, key, styles
|
|
65
|
+
// Ignored via go/ees005
|
|
66
|
+
// eslint-disable-next-line @typescript-eslint/max-params
|
|
67
|
+
) {
|
|
65
68
|
switch (layout) {
|
|
66
69
|
case 'align-start':
|
|
67
70
|
case 'wrap-left':
|
|
@@ -9,7 +9,10 @@ var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers
|
|
|
9
9
|
var _mediaSingle = require("../media-single");
|
|
10
10
|
var _utils = require("./utils");
|
|
11
11
|
var RELATIVE_GUIDES_GAP = 6;
|
|
12
|
-
var getWidthRelativeGuideline = function getWidthRelativeGuideline(key, view, nodeWithPos, editorWidth, topOffset, size
|
|
12
|
+
var getWidthRelativeGuideline = function getWidthRelativeGuideline(key, view, nodeWithPos, editorWidth, topOffset, size
|
|
13
|
+
// Ignored via go/ees005
|
|
14
|
+
// eslint-disable-next-line @typescript-eslint/max-params
|
|
15
|
+
) {
|
|
13
16
|
var node = nodeWithPos.node,
|
|
14
17
|
pos = nodeWithPos.pos;
|
|
15
18
|
var _view$dom$getBounding = view.dom.getBoundingClientRect(),
|
|
@@ -61,7 +64,10 @@ var getWidthRelativeGuideline = function getWidthRelativeGuideline(key, view, no
|
|
|
61
64
|
}
|
|
62
65
|
};
|
|
63
66
|
};
|
|
64
|
-
var getHeightRelativeGuideline = function getHeightRelativeGuideline(key, view, nodeWithPos, editorWidth, topOffset, size
|
|
67
|
+
var getHeightRelativeGuideline = function getHeightRelativeGuideline(key, view, nodeWithPos, editorWidth, topOffset, size
|
|
68
|
+
// Ignored via go/ees005
|
|
69
|
+
// eslint-disable-next-line @typescript-eslint/max-params
|
|
70
|
+
) {
|
|
65
71
|
var node = nodeWithPos.node,
|
|
66
72
|
pos = nodeWithPos.pos;
|
|
67
73
|
var _view$dom$getBounding2 = view.dom.getBoundingClientRect(),
|
|
@@ -125,7 +131,10 @@ var getRelativeGuideSnaps = exports.getRelativeGuideSnaps = function getRelative
|
|
|
125
131
|
});
|
|
126
132
|
return [].concat((0, _toConsumableArray2.default)(snapsWidthFromMatchingWidth), (0, _toConsumableArray2.default)(snapsWidthFromMatchingHeight));
|
|
127
133
|
};
|
|
128
|
-
var getRelativeGuidelines = exports.getRelativeGuidelines = function getRelativeGuidelines(relativeGuides, nodeWithPos, view, editorWidth, topOffset, size
|
|
134
|
+
var getRelativeGuidelines = exports.getRelativeGuidelines = function getRelativeGuidelines(relativeGuides, nodeWithPos, view, editorWidth, topOffset, size
|
|
135
|
+
// Ignored via go/ees005
|
|
136
|
+
// eslint-disable-next-line @typescript-eslint/max-params
|
|
137
|
+
) {
|
|
129
138
|
var matchWidth = relativeGuides.width ? relativeGuides.width[Math.round(size.width)] : [];
|
|
130
139
|
var matchHeight = relativeGuides.height ? relativeGuides.height[Math.round(size.height)] : [];
|
|
131
140
|
var matches = matchWidth || matchHeight;
|
|
@@ -14,7 +14,10 @@ var activeGuidelineStyle = function activeGuidelineStyle(guideline) {
|
|
|
14
14
|
show: true
|
|
15
15
|
});
|
|
16
16
|
};
|
|
17
|
-
var getGuidelinesWithHighlights = exports.getGuidelinesWithHighlights = function getGuidelinesWithHighlights(gap, maxGap, activeGuidelineKeys, guidelines
|
|
17
|
+
var getGuidelinesWithHighlights = exports.getGuidelinesWithHighlights = function getGuidelinesWithHighlights(gap, maxGap, activeGuidelineKeys, guidelines
|
|
18
|
+
// Ignored via go/ees005
|
|
19
|
+
// eslint-disable-next-line @typescript-eslint/max-params
|
|
20
|
+
) {
|
|
18
21
|
if (activeGuidelineKeys.length) {
|
|
19
22
|
return guidelines.map(function (guideline) {
|
|
20
23
|
if (activeGuidelineKeys.includes(guideline.key) && gap < maxGap) {
|
|
@@ -11,6 +11,9 @@ var _react = require("react");
|
|
|
11
11
|
var _debounce = _interopRequireDefault(require("lodash/debounce"));
|
|
12
12
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
13
13
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
14
|
+
// Ignored via go/ees005
|
|
15
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
16
|
+
|
|
14
17
|
/**
|
|
15
18
|
*
|
|
16
19
|
* Directly map object values
|
|
@@ -11,6 +11,9 @@ var _react = require("react");
|
|
|
11
11
|
var _debounce = _interopRequireDefault(require("lodash/debounce"));
|
|
12
12
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
13
13
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
14
|
+
// Ignored via go/ees005
|
|
15
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
16
|
+
|
|
14
17
|
/**
|
|
15
18
|
*
|
|
16
19
|
* Directly map object values
|
|
@@ -11,6 +11,9 @@ var _react = require("react");
|
|
|
11
11
|
var _get = _interopRequireDefault(require("lodash/get"));
|
|
12
12
|
var _isEqual = _interopRequireDefault(require("lodash/isEqual"));
|
|
13
13
|
var _usePluginStateEffect = require("../usePluginStateEffect");
|
|
14
|
+
// Ignored via go/ees005
|
|
15
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
16
|
+
|
|
14
17
|
/**
|
|
15
18
|
* This is designed to iterate through an object to get the path of its result
|
|
16
19
|
* based on separation via "."
|
|
@@ -15,6 +15,8 @@ var BorderIconGlyph = function BorderIconGlyph(props) {
|
|
|
15
15
|
viewBox: "0 0 24 24",
|
|
16
16
|
fill: "none",
|
|
17
17
|
xmlns: "http://www.w3.org/2000/svg"
|
|
18
|
+
// Ignored via go/ees005
|
|
19
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
18
20
|
}, props), /*#__PURE__*/_react.default.createElement("path", {
|
|
19
21
|
d: "M8.33333 8C8.15267 8 8 8.14933 8 8.33333V15.6667C8.0007 15.7549 8.03604 15.8392 8.0984 15.9016C8.16076 15.964 8.24514 15.9993 8.33333 16H15.6667C15.8473 16 16 15.8507 16 15.6667V8.33333C16 8.15267 15.8507 8 15.6667 8H8.33333Z",
|
|
20
22
|
fill: "currentColor"
|
|
@@ -26,6 +28,8 @@ var BorderIconGlyph = function BorderIconGlyph(props) {
|
|
|
26
28
|
}));
|
|
27
29
|
};
|
|
28
30
|
var BorderIcon = exports.BorderIcon = function BorderIcon(props) {
|
|
31
|
+
// Ignored via go/ees005
|
|
32
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
29
33
|
return /*#__PURE__*/_react.default.createElement(_icon.default, (0, _extends2.default)({
|
|
30
34
|
glyph: BorderIconGlyph
|
|
31
35
|
}, props));
|
|
@@ -15,6 +15,8 @@ var PanelErrorGlyph = function PanelErrorGlyph(props) {
|
|
|
15
15
|
viewBox: "0 0 24 24",
|
|
16
16
|
fill: "none",
|
|
17
17
|
xmlns: "http://www.w3.org/2000/svg"
|
|
18
|
+
// Ignored via go/ees005
|
|
19
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
18
20
|
}, props), /*#__PURE__*/_react.default.createElement("path", {
|
|
19
21
|
fillRule: "evenodd",
|
|
20
22
|
clipRule: "evenodd",
|
|
@@ -23,6 +25,8 @@ var PanelErrorGlyph = function PanelErrorGlyph(props) {
|
|
|
23
25
|
}));
|
|
24
26
|
};
|
|
25
27
|
var PanelErrorIcon = exports.PanelErrorIcon = function PanelErrorIcon(props) {
|
|
28
|
+
// Ignored via go/ees005
|
|
29
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
26
30
|
return /*#__PURE__*/_react.default.createElement(_icon.default, (0, _extends2.default)({
|
|
27
31
|
glyph: PanelErrorGlyph
|
|
28
32
|
}, props));
|
|
@@ -15,6 +15,8 @@ var PanelInfoGlyph = function PanelInfoGlyph(props) {
|
|
|
15
15
|
viewBox: "0 0 24 24",
|
|
16
16
|
fill: "none",
|
|
17
17
|
xmlns: "http://www.w3.org/2000/svg"
|
|
18
|
+
// Ignored via go/ees005
|
|
19
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
18
20
|
}, props), /*#__PURE__*/_react.default.createElement("path", {
|
|
19
21
|
fillRule: "evenodd",
|
|
20
22
|
clipRule: "evenodd",
|
|
@@ -23,6 +25,8 @@ var PanelInfoGlyph = function PanelInfoGlyph(props) {
|
|
|
23
25
|
}));
|
|
24
26
|
};
|
|
25
27
|
var PanelInfoIcon = exports.PanelInfoIcon = function PanelInfoIcon(props) {
|
|
28
|
+
// Ignored via go/ees005
|
|
29
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
26
30
|
return /*#__PURE__*/_react.default.createElement(_icon.default, (0, _extends2.default)({
|
|
27
31
|
glyph: PanelInfoGlyph
|
|
28
32
|
}, props));
|
|
@@ -15,6 +15,8 @@ var PanelNoteGlyph = function PanelNoteGlyph(props) {
|
|
|
15
15
|
viewBox: "0 0 24 24",
|
|
16
16
|
fill: "none",
|
|
17
17
|
xmlns: "http://www.w3.org/2000/svg"
|
|
18
|
+
// Ignored via go/ees005
|
|
19
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
18
20
|
}, props), /*#__PURE__*/_react.default.createElement("path", {
|
|
19
21
|
fillRule: "evenodd",
|
|
20
22
|
clipRule: "evenodd",
|
|
@@ -23,6 +25,8 @@ var PanelNoteGlyph = function PanelNoteGlyph(props) {
|
|
|
23
25
|
}));
|
|
24
26
|
};
|
|
25
27
|
var PanelNoteIcon = exports.PanelNoteIcon = function PanelNoteIcon(props) {
|
|
28
|
+
// Ignored via go/ees005
|
|
29
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
26
30
|
return /*#__PURE__*/_react.default.createElement(_icon.default, (0, _extends2.default)({
|
|
27
31
|
glyph: PanelNoteGlyph
|
|
28
32
|
}, props));
|
|
@@ -15,6 +15,8 @@ var PanelSuccessGlyph = function PanelSuccessGlyph(props) {
|
|
|
15
15
|
viewBox: "0 0 24 24",
|
|
16
16
|
fill: "none",
|
|
17
17
|
xmlns: "http://www.w3.org/2000/svg"
|
|
18
|
+
// Ignored via go/ees005
|
|
19
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
18
20
|
}, props), /*#__PURE__*/_react.default.createElement("path", {
|
|
19
21
|
fillRule: "evenodd",
|
|
20
22
|
clipRule: "evenodd",
|
|
@@ -23,6 +25,8 @@ var PanelSuccessGlyph = function PanelSuccessGlyph(props) {
|
|
|
23
25
|
}));
|
|
24
26
|
};
|
|
25
27
|
var PanelSuccessIcon = exports.PanelSuccessIcon = function PanelSuccessIcon(props) {
|
|
28
|
+
// Ignored via go/ees005
|
|
29
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
26
30
|
return /*#__PURE__*/_react.default.createElement(_icon.default, (0, _extends2.default)({
|
|
27
31
|
glyph: PanelSuccessGlyph
|
|
28
32
|
}, props));
|
|
@@ -15,6 +15,8 @@ var PanelWarningGlyph = function PanelWarningGlyph(props) {
|
|
|
15
15
|
viewBox: "0 0 24 24",
|
|
16
16
|
fill: "none",
|
|
17
17
|
xmlns: "http://www.w3.org/2000/svg"
|
|
18
|
+
// Ignored via go/ees005
|
|
19
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
18
20
|
}, props), /*#__PURE__*/_react.default.createElement("path", {
|
|
19
21
|
fillRule: "evenodd",
|
|
20
22
|
clipRule: "evenodd",
|
|
@@ -23,6 +25,8 @@ var PanelWarningGlyph = function PanelWarningGlyph(props) {
|
|
|
23
25
|
}));
|
|
24
26
|
};
|
|
25
27
|
var PanelWarningIcon = exports.PanelWarningIcon = function PanelWarningIcon(props) {
|
|
28
|
+
// Ignored via go/ees005
|
|
29
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
26
30
|
return /*#__PURE__*/_react.default.createElement(_icon.default, (0, _extends2.default)({
|
|
27
31
|
glyph: PanelWarningGlyph
|
|
28
32
|
}, props));
|
package/dist/cjs/insert/index.js
CHANGED
|
@@ -64,7 +64,10 @@ var selectionIsInNestedList = function selectionIsInNestedList(tr) {
|
|
|
64
64
|
}
|
|
65
65
|
return (0, _utils2.isListItemNode)(tr.doc.resolve(parentListNode.pos).parent);
|
|
66
66
|
};
|
|
67
|
-
var insertBeforeOrAfter = function insertBeforeOrAfter(tr, lookDirection, $parentPos, $proposedPosition, content
|
|
67
|
+
var insertBeforeOrAfter = function insertBeforeOrAfter(tr, lookDirection, $parentPos, $proposedPosition, content
|
|
68
|
+
// Ignored via go/ees005
|
|
69
|
+
// eslint-disable-next-line @typescript-eslint/max-params
|
|
70
|
+
) {
|
|
68
71
|
/**
|
|
69
72
|
* This block caters for the first item in a parent with the cursor being at the very start
|
|
70
73
|
* or the last item with the cursor being at the very end
|
|
@@ -83,6 +86,8 @@ var insertBeforeOrAfter = function insertBeforeOrAfter(tr, lookDirection, $paren
|
|
|
83
86
|
};
|
|
84
87
|
|
|
85
88
|
// FIXME: A more sustainable and configurable way to choose when to split
|
|
89
|
+
// Ignored via go/ees005
|
|
90
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
86
91
|
var shouldSplit = function shouldSplit(nodeType, schemaNodes) {
|
|
87
92
|
return [schemaNodes.bulletList, schemaNodes.orderedList, schemaNodes.panel].includes(nodeType);
|
|
88
93
|
};
|
|
@@ -236,8 +236,28 @@ function formatShortcut(keymap) {
|
|
|
236
236
|
var shortcut;
|
|
237
237
|
if (_utils.browser.mac) {
|
|
238
238
|
// for reference: https://wincent.com/wiki/Unicode_representations_of_modifier_keys
|
|
239
|
-
shortcut = keymap.mac
|
|
239
|
+
shortcut = keymap.mac
|
|
240
|
+
// Ignored via go/ees005
|
|
241
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
242
|
+
.replace(/Cmd/i, "\u2318")
|
|
243
|
+
// Ignored via go/ees005
|
|
244
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
245
|
+
.replace(/Shift/i, "\u21E7")
|
|
246
|
+
// Ignored via go/ees005
|
|
247
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
248
|
+
.replace(/Ctrl/i, "\u2303")
|
|
249
|
+
// Ignored via go/ees005
|
|
250
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
251
|
+
.replace(/Alt/i, "\u2325")
|
|
252
|
+
// Ignored via go/ees005
|
|
253
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
254
|
+
.replace(/Backspace/i, "\u232B")
|
|
255
|
+
// Ignored via go/ees005
|
|
256
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
257
|
+
.replace(/Enter/i, "\u23CE");
|
|
240
258
|
} else {
|
|
259
|
+
// Ignored via go/ees005
|
|
260
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
241
261
|
shortcut = keymap.windows.replace(/Backspace/i, "\u232B");
|
|
242
262
|
}
|
|
243
263
|
var keys = shortcut.split('-');
|
|
@@ -269,9 +289,16 @@ var TooltipContentWithMultipleShortcuts = exports.TooltipContentWithMultipleShor
|
|
|
269
289
|
var helpDescriptors = _ref2.helpDescriptors;
|
|
270
290
|
var keymapCount = helpDescriptors.length;
|
|
271
291
|
return (0, _react2.jsx)(_react.Fragment, null, helpDescriptors.map(function (descriptor, index) {
|
|
272
|
-
return (
|
|
273
|
-
|
|
274
|
-
|
|
292
|
+
return (
|
|
293
|
+
// Ignored via go/ees005
|
|
294
|
+
// eslint-disable-next-line react/no-array-index-key
|
|
295
|
+
(0, _react2.jsx)(_react.Fragment, {
|
|
296
|
+
key: index
|
|
297
|
+
}, (0, _react2.jsx)(ToolTipContent
|
|
298
|
+
// Ignored via go/ees005
|
|
299
|
+
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
300
|
+
, descriptor), ' ', index < keymapCount - 1 && (0, _react2.jsx)("br", null))
|
|
301
|
+
);
|
|
275
302
|
}));
|
|
276
303
|
});
|
|
277
304
|
function findKeymapByDescription(description) {
|
|
@@ -334,16 +361,27 @@ function getAriaKeyshortcuts(keymap) {
|
|
|
334
361
|
}
|
|
335
362
|
}
|
|
336
363
|
var ALL = [toggleOrderedList, toggleBulletList, toggleBold, toggleItalic, toggleUnderline, toggleStrikethrough, toggleSubscript, toggleSuperscript, toggleCode, setNormalText, toggleHeading1, toggleHeading2, toggleHeading3, toggleHeading4, toggleHeading5, toggleHeading6, toggleBlockQuote, insertNewLine, insertRule, splitCodeBlock, splitListItem, redo, undo, find, escape, enter, shiftEnter];
|
|
364
|
+
|
|
365
|
+
// Ignored via go/ees005
|
|
366
|
+
// eslint-disable-next-line @typescript-eslint/max-params
|
|
337
367
|
function makeKeymap(description, windows, mac, common) {
|
|
338
368
|
return {
|
|
339
369
|
description: description,
|
|
370
|
+
// Ignored via go/ees005
|
|
371
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
340
372
|
windows: windows.replace(/Mod/i, 'Ctrl'),
|
|
373
|
+
// Ignored via go/ees005
|
|
374
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
341
375
|
mac: mac.replace(/Mod/i, 'Cmd'),
|
|
342
376
|
common: common
|
|
343
377
|
};
|
|
344
378
|
}
|
|
345
379
|
function makeKeyMapWithCommon(description, common) {
|
|
380
|
+
// Ignored via go/ees005
|
|
381
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
346
382
|
var windows = common.replace(/Mod/i, 'Ctrl');
|
|
383
|
+
// Ignored via go/ees005
|
|
384
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
347
385
|
var mac = common.replace(/Mod/i, 'Cmd');
|
|
348
386
|
return makeKeymap(description, windows, mac, common);
|
|
349
387
|
}
|
|
@@ -367,6 +405,8 @@ function bindKeymapWithCommand(shortcut, cmd, keymap) {
|
|
|
367
405
|
// If there is a need to use the same command with several shortcuts
|
|
368
406
|
function bindKeymapArrayWithCommand(shortcutsArray, cmd, keymap) {
|
|
369
407
|
shortcutsArray.forEach(function (shortcut) {
|
|
408
|
+
// Ignored via go/ees005
|
|
409
|
+
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
370
410
|
return bindKeymapWithCommand(shortcut.common, cmd, keymap);
|
|
371
411
|
});
|
|
372
412
|
}
|
|
@@ -391,7 +431,10 @@ function findKeyMapForBrowser(keyMap) {
|
|
|
391
431
|
function isCapsLockOnAndModifyKeyboardEvent(event) {
|
|
392
432
|
var keyboardEvent = event;
|
|
393
433
|
var name = (0, _w3cKeyname.keyName)(event);
|
|
394
|
-
if (event.ctrlKey && event.getModifierState('CapsLock') && !event.getModifierState('Shift') && name.length === 1 &&
|
|
434
|
+
if (event.ctrlKey && event.getModifierState('CapsLock') && !event.getModifierState('Shift') && name.length === 1 &&
|
|
435
|
+
// Ignored via go/ees005
|
|
436
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
437
|
+
/^[A-Z]/.test(name)) {
|
|
395
438
|
keyboardEvent = new KeyboardEvent('keydown', {
|
|
396
439
|
key: _w3cKeyname.base[event.keyCode].toLowerCase(),
|
|
397
440
|
code: event.code,
|
|
@@ -14,6 +14,8 @@ var _safePlugin = require("../safe-plugin");
|
|
|
14
14
|
* @see https://github.com/ProseMirror/prosemirror/issues/957
|
|
15
15
|
* @param bindings
|
|
16
16
|
*/
|
|
17
|
+
// Ignored via go/ees005
|
|
18
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
17
19
|
function keymap(bindings) {
|
|
18
20
|
return new _safePlugin.SafePlugin({
|
|
19
21
|
props: {
|
|
@@ -27,6 +29,8 @@ function keymap(bindings) {
|
|
|
27
29
|
|
|
28
30
|
// Check the unicode of the character to assert that it's not an ASCII character.
|
|
29
31
|
// These are characters outside latin's range.
|
|
32
|
+
// Ignored via go/ees005
|
|
33
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
30
34
|
var isNonLatinKey = name.length === 1 && /[^\u0000-\u007f]/.test(name);
|
|
31
35
|
|
|
32
36
|
// The `Dead` key is a key that combines with a following key to produce a combined character.
|
|
@@ -13,6 +13,10 @@ var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/sli
|
|
|
13
13
|
* @returns Hyphenated CSS property name.
|
|
14
14
|
*/
|
|
15
15
|
function hyphenate(property) {
|
|
16
|
+
// Ignored via go/ees005
|
|
17
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
18
|
+
// Ignored via go/ees005
|
|
19
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
16
20
|
return property.replace(/[A-Z]/g, function (match) {
|
|
17
21
|
return "-".concat(match.toLowerCase());
|
|
18
22
|
}).replace(/^ms/, '-ms');
|