@atlaskit/editor-core 229.1.0 → 229.1.2
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 +29 -0
- package/dist/cjs/create-editor/createPMPlugins.js +2 -1
- package/dist/cjs/presets/universal.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/FullPage.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/FullPageContentArea-compiled.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/FullPageContentArea-emotion.js +1 -1
- package/dist/cjs/ui/EditorContentContainer/EditorContentContainer-compiled.js +1 -1
- package/dist/cjs/ui/EditorContentContainer/EditorContentContainer-emotion.js +2 -2
- package/dist/cjs/ui/EditorContentContainer/styles/mediaStyles.js +1 -1
- package/dist/cjs/ui/Toolbar/ToolbarWithSizeDetector.js +1 -1
- package/dist/cjs/ui/quick-insert/ExtensionQuickInsertIcon.js +3 -3
- package/dist/cjs/ui/quick-insert/getExtensionQuickInsertPreviewImageUrls.js +180 -43
- package/dist/cjs/utils/extensions.js +1 -1
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/actions/index.js +2 -1
- package/dist/es2019/create-editor/createPMPlugins.js +2 -1
- package/dist/es2019/entry-points/CollapsedEditor.js +1 -0
- package/dist/es2019/entry-points/ContextPanel.js +1 -0
- package/dist/es2019/entry-points/EditorContentContainer.js +1 -0
- package/dist/es2019/entry-points/EditorContext.js +1 -0
- package/dist/es2019/entry-points/ReactEditorView.js +1 -0
- package/dist/es2019/entry-points/ToolbarHelp.js +1 -0
- package/dist/es2019/entry-points/ToolbarPortal.js +1 -0
- package/dist/es2019/entry-points/WithEditorActions.js +1 -0
- package/dist/es2019/entry-points/WithHelpTrigger.js +1 -0
- package/dist/es2019/entry-points/actions.js +1 -0
- package/dist/es2019/entry-points/appearance-editor-chromeless.js +1 -0
- package/dist/es2019/entry-points/appearance-editor-comment.js +1 -0
- package/dist/es2019/entry-points/appearance-editor-full-page.js +1 -0
- package/dist/es2019/entry-points/appearance-editor-full-width.js +1 -0
- package/dist/es2019/entry-points/create-plugins-list.js +1 -0
- package/dist/es2019/entry-points/exclude-from-hydration.js +1 -0
- package/dist/es2019/entry-points/feature-flags-from-props.js +1 -0
- package/dist/es2019/entry-points/getNodesCount.js +1 -0
- package/dist/es2019/entry-points/i18n-languages.js +1 -0
- package/dist/es2019/entry-points/measure-enum.js +1 -0
- package/dist/es2019/entry-points/preset-universal-universal.js +1 -0
- package/dist/es2019/entry-points/preset-universal-useUniversalPreset.js +1 -0
- package/dist/es2019/entry-points/test-utils.js +1 -0
- package/dist/es2019/entry-points/use-preset-context.js +1 -0
- package/dist/es2019/entry-points/version-wrapper.js +1 -0
- package/dist/es2019/presets/universal.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/FullPage.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/FullPageContentArea-compiled.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/FullPageContentArea-emotion.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/StyledComponents.js +1 -0
- package/dist/es2019/ui/ChromeCollapsed/styles.js +1 -0
- package/dist/es2019/ui/ContextPanel/index.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/EditorContentContainer-compiled.js +1 -2
- package/dist/es2019/ui/EditorContentContainer/EditorContentContainer-emotion.js +3 -2
- package/dist/es2019/ui/EditorContentContainer/styles/agentShimmerStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/aiPanel.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/annotationStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/backgroundColorStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/baseStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/blockMarksStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/blockSpacingStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/blockTypeStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/codeBlockStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/codeMarkStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/commentEditorStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/containerTypeStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/contributorTagStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/cursorStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/dateStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/editorUGCTokenStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/embedCardStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/emoji.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/expandStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/extensionBreakoutStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/extensionStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/findReplaceStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/firstBlockNodeStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/floatingToolbarStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/fontSizeStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/fullPageEditorStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/gapCursorStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/gridStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/indentationStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/inlineNodeViewSharedStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/link.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/list.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/mediaStyles.js +2 -1
- package/dist/es2019/ui/EditorContentContainer/styles/mentions.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/overflowShadowStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/panelStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/paragraphStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/placeholderStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/resizerStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/rule.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/ruleWithAttrs.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/scrollbarStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/selectionStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/selectionToolbarStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/shadowStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/smartCardStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/statusStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/syncBlockInteractiveCursorStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/syncBlockStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/tableStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/tasksAndDecisionsStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/telepointerStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/textColorStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/textHighlightStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/unsupportedStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/vanillaTooltipStyles.js +1 -0
- package/dist/es2019/ui/EditorContentContainer/styles/whitespaceStyles.js +1 -0
- package/dist/es2019/ui/Toolbar/ToolbarWithSizeDetector.js +1 -1
- package/dist/es2019/ui/quick-insert/ExtensionQuickInsertIcon.js +3 -3
- package/dist/es2019/ui/quick-insert/getExtensionQuickInsertPreviewImageUrls.js +181 -42
- package/dist/es2019/utils/extensions.js +2 -2
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/actions/index.js +2 -1
- package/dist/esm/create-editor/createPMPlugins.js +2 -1
- package/dist/esm/entry-points/CollapsedEditor.js +1 -0
- package/dist/esm/entry-points/ContextPanel.js +1 -0
- package/dist/esm/entry-points/EditorContentContainer.js +1 -0
- package/dist/esm/entry-points/EditorContext.js +1 -0
- package/dist/esm/entry-points/ReactEditorView.js +1 -0
- package/dist/esm/entry-points/ToolbarHelp.js +1 -0
- package/dist/esm/entry-points/ToolbarPortal.js +1 -0
- package/dist/esm/entry-points/WithEditorActions.js +1 -0
- package/dist/esm/entry-points/WithHelpTrigger.js +1 -0
- package/dist/esm/entry-points/actions.js +1 -0
- package/dist/esm/entry-points/appearance-editor-chromeless.js +1 -0
- package/dist/esm/entry-points/appearance-editor-comment.js +1 -0
- package/dist/esm/entry-points/appearance-editor-full-page.js +1 -0
- package/dist/esm/entry-points/appearance-editor-full-width.js +1 -0
- package/dist/esm/entry-points/create-plugins-list.js +1 -0
- package/dist/esm/entry-points/exclude-from-hydration.js +1 -0
- package/dist/esm/entry-points/feature-flags-from-props.js +1 -0
- package/dist/esm/entry-points/getNodesCount.js +1 -0
- package/dist/esm/entry-points/i18n-languages.js +1 -0
- package/dist/esm/entry-points/measure-enum.js +1 -0
- package/dist/esm/entry-points/preset-universal-universal.js +1 -0
- package/dist/esm/entry-points/preset-universal-useUniversalPreset.js +1 -0
- package/dist/esm/entry-points/test-utils.js +1 -0
- package/dist/esm/entry-points/use-preset-context.js +1 -0
- package/dist/esm/entry-points/version-wrapper.js +1 -0
- package/dist/esm/presets/universal.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/FullPage.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/FullPageContentArea-compiled.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/FullPageContentArea-emotion.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/StyledComponents.js +1 -0
- package/dist/esm/ui/ChromeCollapsed/styles.js +1 -0
- package/dist/esm/ui/ContextPanel/index.js +1 -0
- package/dist/esm/ui/EditorContentContainer/EditorContentContainer-compiled.js +1 -2
- package/dist/esm/ui/EditorContentContainer/EditorContentContainer-emotion.js +3 -2
- package/dist/esm/ui/EditorContentContainer/styles/agentShimmerStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/aiPanel.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/annotationStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/backgroundColorStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/baseStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/blockMarksStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/blockSpacingStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/blockTypeStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/codeBlockStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/codeMarkStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/commentEditorStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/containerTypeStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/contributorTagStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/cursorStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/dateStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/editorUGCTokenStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/embedCardStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/emoji.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/expandStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/extensionBreakoutStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/extensionStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/findReplaceStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/firstBlockNodeStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/floatingToolbarStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/fontSizeStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/fullPageEditorStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/gapCursorStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/gridStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/indentationStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/inlineNodeViewSharedStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/link.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/list.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/mediaStyles.js +2 -1
- package/dist/esm/ui/EditorContentContainer/styles/mentions.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/overflowShadowStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/panelStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/paragraphStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/placeholderStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/resizerStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/rule.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/ruleWithAttrs.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/scrollbarStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/selectionStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/selectionToolbarStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/shadowStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/smartCardStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/statusStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/syncBlockInteractiveCursorStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/syncBlockStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/tableStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/tasksAndDecisionsStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/telepointerStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/textColorStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/textHighlightStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/unsupportedStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/vanillaTooltipStyles.js +1 -0
- package/dist/esm/ui/EditorContentContainer/styles/whitespaceStyles.js +1 -0
- package/dist/esm/ui/Toolbar/ToolbarWithSizeDetector.js +1 -1
- package/dist/esm/ui/quick-insert/ExtensionQuickInsertIcon.js +3 -3
- package/dist/esm/ui/quick-insert/getExtensionQuickInsertPreviewImageUrls.js +180 -43
- package/dist/esm/utils/extensions.js +2 -2
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/actions/index.d.ts +1 -1
- package/docs/4-annotations.tsx +1 -0
- package/package.json +9 -9
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
@atlaskit/ui-styling-standard/no-exported-styles */
|
|
4
4
|
/* eslint-disable @atlaskit/ui-styling-standard/no-exported-styles */
|
|
5
5
|
/* eslint-disable @atlaskit/ui-styling-standard/use-compiled */
|
|
6
|
+
|
|
6
7
|
import { css, keyframes } from '@emotion/react';
|
|
7
8
|
const pulseIn = keyframes({
|
|
8
9
|
'0%, 100%': {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/* eslint-disable @atlaskit/ui-styling-standard/use-compiled,
|
|
2
2
|
@repo/internal/deprecations/deprecation-ticket-required,
|
|
3
3
|
@atlaskit/ui-styling-standard/no-exported-styles */
|
|
4
|
+
|
|
4
5
|
import { css } from '@emotion/react';
|
|
5
6
|
/**
|
|
6
7
|
* @deprecated This style has been migrated to Compiled CSS, under experiment platform_editor_core_static_css
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/* eslint-disable @atlaskit/ui-styling-standard/use-compiled,
|
|
2
2
|
@repo/internal/deprecations/deprecation-ticket-required,
|
|
3
3
|
@atlaskit/ui-styling-standard/no-exported-styles */
|
|
4
|
+
|
|
4
5
|
import { css } from '@emotion/react';
|
|
5
6
|
/**
|
|
6
7
|
* @deprecated This style has been migrated to Compiled CSS, under experiment platform_editor_core_static_css
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/* eslint-disable @atlaskit/ui-styling-standard/use-compiled,
|
|
2
2
|
@repo/internal/deprecations/deprecation-ticket-required,
|
|
3
3
|
@atlaskit/ui-styling-standard/no-exported-styles */
|
|
4
|
+
|
|
4
5
|
import { css } from '@emotion/react';
|
|
5
6
|
import { backgroundSelectionStyles, borderSelectionStyles, hideNativeBrowserTextSelectionStyles } from './selectionStyles';
|
|
6
7
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/* eslint-disable @atlaskit/ui-styling-standard/use-compiled,
|
|
2
2
|
@repo/internal/deprecations/deprecation-ticket-required,
|
|
3
3
|
@atlaskit/ui-styling-standard/no-exported-styles */
|
|
4
|
+
|
|
4
5
|
import { css } from '@emotion/react';
|
|
5
6
|
/**
|
|
6
7
|
* Default look for tooltips created by `VanillaTooltip` (`editor-common/vanilla-tooltip`).
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/* eslint-disable @atlaskit/ui-styling-standard/use-compiled,
|
|
2
2
|
@repo/internal/deprecations/deprecation-ticket-required,
|
|
3
3
|
@atlaskit/ui-styling-standard/no-exported-styles */
|
|
4
|
+
|
|
4
5
|
import { css } from '@emotion/react';
|
|
5
6
|
/**
|
|
6
7
|
* @deprecated This style has been migrated to Compiled CSS, under experiment platform_editor_core_static_css
|
|
@@ -2,8 +2,8 @@ import React, { useMemo } from 'react';
|
|
|
2
2
|
import { isSSR } from '@atlaskit/editor-common/core-utils';
|
|
3
3
|
import { ToolbarSize } from '@atlaskit/editor-common/types';
|
|
4
4
|
import { componentWithCondition } from '@atlaskit/platform-feature-flags-react/component-with-condition';
|
|
5
|
-
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
6
5
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
6
|
+
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
7
7
|
import { WidthObserver } from '@atlaskit/width-detector/width-observer';
|
|
8
8
|
import { isFullPage } from '../../utils/is-full-page';
|
|
9
9
|
import { useElementWidth } from './hooks';
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import AppsIcon from '@atlaskit/icon/core/apps';
|
|
3
|
-
import CardIcon from '@atlaskit/icon/core/card';
|
|
4
|
-
import WhiteboardIcon from '@atlaskit/icon/core/whiteboard';
|
|
5
2
|
import CarouselIcon from '@atlaskit/icon-lab/core/carousel';
|
|
6
3
|
import TableOfContentIcon from '@atlaskit/icon-lab/core/table-of-content';
|
|
7
4
|
import TemplateIcon from '@atlaskit/icon-lab/core/template';
|
|
5
|
+
import AppsIcon from '@atlaskit/icon/core/apps';
|
|
6
|
+
import CardIcon from '@atlaskit/icon/core/card';
|
|
7
|
+
import WhiteboardIcon from '@atlaskit/icon/core/whiteboard';
|
|
8
8
|
const lazyExtensionIconCache = new WeakMap();
|
|
9
9
|
const whiteboardQuickInsertItemKeys = new Set(['whiteboard-extension:create-whiteboard', 'whiteboard-extension:create-diagram', 'whiteboard-extension:create-flowchart', 'whiteboard-extension:create-brainstorming', 'whiteboard-extension:create-retrospective', 'whiteboard-extension:create-roadmap']);
|
|
10
10
|
const quickInsertItemIcons = {
|
|
@@ -1,6 +1,26 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { getSnippetPreviewImageUrls } from '@atlaskit/editor-common/quick-insert/snippet-preview-image-urls';
|
|
2
|
+
import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
|
|
3
|
+
const embedPreviewImageUrlsByKey = {
|
|
4
|
+
'third-party-quick-insert-embeds:third-party-embed-amplitude': {
|
|
5
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
|
|
6
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
|
|
7
|
+
},
|
|
8
|
+
'dropbox:item': {
|
|
9
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
|
|
10
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
|
|
11
|
+
},
|
|
12
|
+
'third-party-quick-insert-embeds:third-party-embed-figma': {
|
|
13
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
|
|
14
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
|
|
15
|
+
},
|
|
16
|
+
'third-party-quick-insert-embeds:third-party-embed-google-drive': {
|
|
17
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y01wj4t58w86byx86l6k81a22axud131.png',
|
|
18
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/wi413m0837rjykg23r6y0256b7377185.png'
|
|
19
|
+
},
|
|
20
|
+
'iframe:iframe': {
|
|
21
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
|
|
22
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
|
|
23
|
+
}
|
|
4
24
|
};
|
|
5
25
|
const dataAndChartsPreviewImageUrlsByKey = {
|
|
6
26
|
'quick-insert-assets-menu-item': {
|
|
@@ -108,8 +128,160 @@ const dataAndChartsPreviewImageUrlsByKey = {
|
|
|
108
128
|
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/o2kexap23ijq8jeqhpvi8lgc51dex3wj.png'
|
|
109
129
|
}
|
|
110
130
|
};
|
|
131
|
+
const otherPreviewImageUrlsByKey = {
|
|
132
|
+
'excerpt:excerpt': {
|
|
133
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/1h408wk0e4x6efhby84hbc583nx5b0b5.png',
|
|
134
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/0j5s4a60jjbrq3yoa7kfnkft28403127.png'
|
|
135
|
+
},
|
|
136
|
+
'excerpt-include:excerpt-include': {
|
|
137
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/dg718ggxcx60dj7ng86fpqmwbv7vauny.png',
|
|
138
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y373d21g768gmvjao5db38kw4460m72r.png'
|
|
139
|
+
},
|
|
140
|
+
'include:include': {
|
|
141
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/s12155hkaoc81aa0eh58y54402s8t346.png',
|
|
142
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/61yskd00re82i80b8r6pfxp60pi4852s.png'
|
|
143
|
+
},
|
|
144
|
+
'jirachart:jirachart': {
|
|
145
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/30g82ea1p64616h40s110ysud47dnof6.png',
|
|
146
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/114de8qe6dy877s65xh1a2dil1r86x73.png'
|
|
147
|
+
},
|
|
148
|
+
'jira:jira': {
|
|
149
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/8ttib573524136b5lffq3a1go05x507d.png',
|
|
150
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/pdnn81xj6e8v56nye6rnft3rd4yhnc05.png'
|
|
151
|
+
},
|
|
152
|
+
'portfolioforjiraplan:portfolioforjiraplan': {
|
|
153
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/24g0yt8c54671463162f5q455qcki3id.png',
|
|
154
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/c2hy8b245yg1dt2776ol5sx57n045nv0.png'
|
|
155
|
+
},
|
|
156
|
+
'opsgenie-incident-timeline-eu-macro:opsgenie-incident-timeline-eu-macro': {
|
|
157
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qo0u146811738ixd6l13nud48pv57510.png',
|
|
158
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qnq1bn07a3k0v4m10hoi487p837obx53.png'
|
|
159
|
+
},
|
|
160
|
+
'sharelinks-urlmacro:sharelinks-urlmacro': {
|
|
161
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/0028h1741o411uw4qi8icbg138kus32e.png',
|
|
162
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/myhw531c3748qn4ro51vf450vk0qg481.png'
|
|
163
|
+
},
|
|
164
|
+
'toc-zone:toc-zone': {
|
|
165
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/1p16277ig16wc6kelloa542k33b18mm2.png',
|
|
166
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/s4q2ap8q4135r0r3i1tym1d5koxdonb1.png'
|
|
167
|
+
},
|
|
168
|
+
'viewpdf:viewpdf': {
|
|
169
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/jt685rp527nfo8jqp6o5o0r31l3rpfux.png',
|
|
170
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/30u3v86x652ah52ruhqj1ap0s0ve4ey2.png'
|
|
171
|
+
},
|
|
172
|
+
'viewxls:viewxls': {
|
|
173
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/b11p6ksb8r6j6g2604p67ab53f23u6f5.png',
|
|
174
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/r426m140lbp7gs2gxbe015e21kf23j8l.png'
|
|
175
|
+
},
|
|
176
|
+
'gadget:activity stream': {
|
|
177
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v3a1rvva7gxr874o5qah5k61365hod5.png',
|
|
178
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/nh7404rduyw5tbne4143426evuk7hvg8.png'
|
|
179
|
+
},
|
|
180
|
+
'gadget:agile wallboard gadget': {
|
|
181
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/n611u81ca8fkyv5nk6cl6j1081e805tr.png',
|
|
182
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/3o7vtt14rtpe3sna7mras6oih86nssb6.png'
|
|
183
|
+
},
|
|
184
|
+
'gadget:assigned to me': {
|
|
185
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/d72jy2r18q6v06s13k2f6x3fymrr4on7.png',
|
|
186
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/5c62343jh3411ido38440xx0007cx6ls.png'
|
|
187
|
+
},
|
|
188
|
+
'gadget:average age chart': {
|
|
189
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/i53kn1igq64m5dip4eg1030j15yd7xxe.png',
|
|
190
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/t136146lvs3x60456gnsghtv730uaftn.png'
|
|
191
|
+
},
|
|
192
|
+
'gadget:average number of times in status': {
|
|
193
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u4v77u1lwcy5g08y047q33dbiv42dkit.png',
|
|
194
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/16v2eq2c1df0mrf2jo6xic526527nfh1.png'
|
|
195
|
+
},
|
|
196
|
+
'gadget:days remaining in sprint gadget': {
|
|
197
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/805320gvqd6cbr23yrv271oas2u061s5.png',
|
|
198
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/41j35y64652g06uru332kt2a0pk77j03.png'
|
|
199
|
+
},
|
|
200
|
+
'gadget:filter results': {
|
|
201
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/w0n60p750b2275k226gri2j6i366jt0e.png',
|
|
202
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/j706ug0u5nk40i1lhrt05j63grc36x0u.png'
|
|
203
|
+
},
|
|
204
|
+
'gadget:heat map': {
|
|
205
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qoepx85h21t4u00cht35nc3ssl4i72j5.png',
|
|
206
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/w574xrh77oxbmb18f0ro1bd80x417426.png'
|
|
207
|
+
},
|
|
208
|
+
'gadget:issues in progress': {
|
|
209
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/666u7h3tp16ad4k8u24d4u1155n1v7hg.png',
|
|
210
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/go2d8b1qs7h07b17326lx8r8p28jm011.png'
|
|
211
|
+
},
|
|
212
|
+
'gadget:jira issues calendar': {
|
|
213
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/13o0sk45vlf25x1m3w14gsy146k25b14.png',
|
|
214
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/j23063ot2a014a2a51y6i0o1keo0kanr.png'
|
|
215
|
+
},
|
|
216
|
+
'gadget:jira road map': {
|
|
217
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/h6u3kb7116jr12w3f586stmc850827h3.png',
|
|
218
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/q23v3a23018y2856kew3fsork63bg6p2.png'
|
|
219
|
+
},
|
|
220
|
+
'gadget:labels gadget': {
|
|
221
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7u8gpvv82s3e2833204nm6m1k3301c46.png',
|
|
222
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/42hjlte7y364o8y4e5udkl11o22a2ac3.png'
|
|
223
|
+
},
|
|
224
|
+
'gadget:pie chart': {
|
|
225
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v4b6d7to551136834oe1a0xx66n7mv5e.png',
|
|
226
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/pdq60d803b655il4x3m0co608guc56ub.png'
|
|
227
|
+
},
|
|
228
|
+
'gadget:quick links': {
|
|
229
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/onlh3rc6p0qj15rsysxa3ep5b183hk40.png',
|
|
230
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/k51qkw636t010l5h1vrs05c7i073y0xp.png'
|
|
231
|
+
},
|
|
232
|
+
'gadget:recently created chart': {
|
|
233
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/t5in18tcubtbr18yv1gr0ap26x7d6bh3.png',
|
|
234
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/ia4jrrsg4mw8tu0gtj88d2yr5w6s20fm.png'
|
|
235
|
+
},
|
|
236
|
+
'gadget:resolution time': {
|
|
237
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/3dek0066jn31qfkk2l2hn011um087y72.png',
|
|
238
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/msw0hn3462vvai4l4jkp50xcm87741j6.png'
|
|
239
|
+
},
|
|
240
|
+
'gadget:sprint burndown gadget': {
|
|
241
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2qqrp3vl4rv2p443566826jadj38rfrj.png',
|
|
242
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qic3bcq5sqhd7r00qpj3i6240n3uw3fp.png'
|
|
243
|
+
},
|
|
244
|
+
'gadget:sprint health gadget': {
|
|
245
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/uoqla656675p5wwc3a8v824768lip528.png',
|
|
246
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/pnngo5y00g18eos4je3r20ga0c666c68.png'
|
|
247
|
+
},
|
|
248
|
+
'gadget:time since chart': {
|
|
249
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/f7g8053ww4deogfid2h2pj2nw6n8582u.png',
|
|
250
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/20wj0kb8mjjj7in0hu62j4ska17ug5s3.png'
|
|
251
|
+
},
|
|
252
|
+
'gadget:time to first response': {
|
|
253
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/l4cy50n75hr166cpohxpd3h5038e8sl7.png',
|
|
254
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/8kkdphd2l3gb7w06dboc82rmtm86xk7r.png'
|
|
255
|
+
},
|
|
256
|
+
'gadget:two dimensional filter statistics': {
|
|
257
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/6s1x266h56m7p4q758jem2k03hbu15gb.png',
|
|
258
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/hjt70wg3tds43ev34nxv1r7l50170f4l.png'
|
|
259
|
+
},
|
|
260
|
+
'gadget:version report': {
|
|
261
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2143nj51e834657316q5n5j6kbq3h3m7.png',
|
|
262
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/rgi5il8d845k40f65w0f8a678c1rf51q.png'
|
|
263
|
+
},
|
|
264
|
+
'gadget:voted work items': {
|
|
265
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/0n262m847lgjj174x658ps04k6j513r6.png',
|
|
266
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/rcn6qrr638k1v5y6xrw8g512f2530244.png'
|
|
267
|
+
},
|
|
268
|
+
'gadget:watched issues': {
|
|
269
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v418o500l40ga5gtq6m23x5t17k47wbe.png',
|
|
270
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/mv0w504r53gvkx38g3y74pd65k5hktop.png'
|
|
271
|
+
},
|
|
272
|
+
'gadget:work item statistics': {
|
|
273
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/4315hi70mlh4eqbn6215p10s4il7os34.png',
|
|
274
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/l3120n2755pw6r2o2q24tmsgu6658533.png'
|
|
275
|
+
},
|
|
276
|
+
'gadget:workload pie chart': {
|
|
277
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v5j8p100viey44g61cdc61d53465gda5.png',
|
|
278
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/84tce4xo2nqe0712oil1f08n5160a11v.png'
|
|
279
|
+
}
|
|
280
|
+
};
|
|
111
281
|
const previewImageUrlsByKey = {
|
|
112
282
|
...dataAndChartsPreviewImageUrlsByKey,
|
|
283
|
+
...embedPreviewImageUrlsByKey,
|
|
284
|
+
...otherPreviewImageUrlsByKey,
|
|
113
285
|
'profile-picture:profile-picture': {
|
|
114
286
|
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/35rb2mbxc2dt8p7op8u8lyss5h220428.png',
|
|
115
287
|
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/4o3lpe2eh4nlakav375621i73do50kyx.png'
|
|
@@ -138,24 +310,6 @@ const previewImageUrlsByKey = {
|
|
|
138
310
|
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/4u6tb8343dv71eotl5462nydlq3544ut.png',
|
|
139
311
|
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/k177s112506n0bn788227s0ig45nko57.png'
|
|
140
312
|
},
|
|
141
|
-
'third-party-quick-insert-embeds:third-party-embed-amplitude': {
|
|
142
|
-
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
|
|
143
|
-
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
|
|
144
|
-
},
|
|
145
|
-
'dropbox:item': {
|
|
146
|
-
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
|
|
147
|
-
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
|
|
148
|
-
},
|
|
149
|
-
'third-party-quick-insert-embeds:third-party-embed-figma': {
|
|
150
|
-
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
|
|
151
|
-
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
|
|
152
|
-
},
|
|
153
|
-
'third-party-quick-insert-embeds:third-party-embed-google-drive': googleDrivePreviewImageUrls,
|
|
154
|
-
'google-drive:item': googleDrivePreviewImageUrls,
|
|
155
|
-
'iframe:iframe': {
|
|
156
|
-
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
|
|
157
|
-
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
|
|
158
|
-
},
|
|
159
313
|
'anchor:anchor': {
|
|
160
314
|
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/5f440bb8m37yig3u77s6c8200re8mto0.png',
|
|
161
315
|
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y42w6i56fk22vb3g5120d43qfwte8a78.png'
|
|
@@ -193,27 +347,12 @@ const previewImageUrlsByKey = {
|
|
|
193
347
|
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v8eyy0fvu61fb8a4b4teea4pjs7g2842.png'
|
|
194
348
|
}
|
|
195
349
|
};
|
|
196
|
-
const previewImageUrlsByTitle = {
|
|
197
|
-
amplitude: {
|
|
198
|
-
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
|
|
199
|
-
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
|
|
200
|
-
},
|
|
201
|
-
dropbox: {
|
|
202
|
-
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
|
|
203
|
-
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
|
|
204
|
-
},
|
|
205
|
-
figma: {
|
|
206
|
-
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
|
|
207
|
-
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
|
|
208
|
-
},
|
|
209
|
-
'google drive': googleDrivePreviewImageUrls,
|
|
210
|
-
iframe: {
|
|
211
|
-
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
|
|
212
|
-
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
|
|
213
|
-
}
|
|
214
|
-
};
|
|
215
350
|
export const getExtensionQuickInsertPreviewImageUrls = item => {
|
|
216
|
-
var _ref, _ref2,
|
|
351
|
+
var _item$key, _ref, _ref2, _dataAndChartsPreview;
|
|
352
|
+
const snippetKeyPrefix = 'snippet-extension:snippet-';
|
|
353
|
+
if ((_item$key = item.key) !== null && _item$key !== void 0 && _item$key.startsWith(snippetKeyPrefix)) {
|
|
354
|
+
return isExperimentEnabled('platform_editor_slash_command') ? getSnippetPreviewImageUrls(item.key.slice(snippetKeyPrefix.length)) : undefined;
|
|
355
|
+
}
|
|
217
356
|
const normalizedTitle = item.title.toLowerCase();
|
|
218
|
-
return (_ref = (_ref2 =
|
|
357
|
+
return (_ref = (_ref2 = item.key ? previewImageUrlsByKey[item.key] : undefined) !== null && _ref2 !== void 0 ? _ref2 : item.extensionKey === 'gadget' ? (_dataAndChartsPreview = dataAndChartsPreviewImageUrlsByKey[`${item.extensionKey}:${normalizedTitle}`]) !== null && _dataAndChartsPreview !== void 0 ? _dataAndChartsPreview : otherPreviewImageUrlsByKey[`${item.extensionKey}:${normalizedTitle}`] : undefined) !== null && _ref !== void 0 ? _ref : item.extensionKey ? dataAndChartsPreviewImageUrlsByKey[item.extensionKey] : undefined;
|
|
219
358
|
};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import Loadable from 'react-loadable';
|
|
3
|
+
// oxlint-disable-next-line @atlassian/no-restricted-imports
|
|
4
|
+
import { lazyForPaint, LazySuspense } from 'react-loosely-lazy';
|
|
3
5
|
import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, fireAnalyticsEvent, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
4
6
|
import { getQuickInsertItemsFromModule, resolveImport } from '@atlaskit/editor-common/extensions';
|
|
5
7
|
import { findInsertLocation } from '@atlaskit/editor-common/utils/analytics';
|
|
6
8
|
import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
|
|
7
|
-
// oxlint-disable-next-line @atlassian/no-restricted-imports
|
|
8
|
-
import { lazyForPaint, LazySuspense } from 'react-loosely-lazy';
|
|
9
9
|
import { getExtensionQuickInsertComponents } from '../ui/quick-insert/getExtensionQuickInsertComponents';
|
|
10
10
|
|
|
11
11
|
// Structural shape of the markdown-mode plugin's slice of the injection API.
|
|
@@ -7,6 +7,8 @@ import { ACTION, ACTION_SUBJECT, EVENT_TYPE } from '@atlaskit/editor-common/anal
|
|
|
7
7
|
import { createDispatch } from '@atlaskit/editor-common/event-dispatcher';
|
|
8
8
|
import { processRawFragmentValue, processRawValue } from '@atlaskit/editor-common/process-raw-value';
|
|
9
9
|
import { analyticsEventKey } from '@atlaskit/editor-common/utils/analytics';
|
|
10
|
+
// eslint-disable-next-line import/order
|
|
11
|
+
|
|
10
12
|
import { Node } from '@atlaskit/editor-prosemirror/model';
|
|
11
13
|
import { NodeSelection, TextSelection } from '@atlaskit/editor-prosemirror/state';
|
|
12
14
|
import { findParentNode, safeInsert } from '@atlaskit/editor-prosemirror/utils';
|
|
@@ -17,7 +19,6 @@ import { isEmptyDocument } from './temp-is-empty-document';
|
|
|
17
19
|
import { findNodePosByLocalIds } from './temp-nodes-by-localids';
|
|
18
20
|
// eslint-disable-next-line import/order
|
|
19
21
|
import { toJSON } from './temp-to-json';
|
|
20
|
-
// eslint-disable-next-line import/order
|
|
21
22
|
|
|
22
23
|
// Please, do not copy or use this kind of code below
|
|
23
24
|
// @ts-ignore
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
|
2
2
|
import { sortByOrder } from '@atlaskit/editor-common/legacy-rank-plugins';
|
|
3
|
+
import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
|
|
3
4
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
4
5
|
import { createEditorNativeAnchorSupportPlugin } from './editorNativeAnchorSupportPlugin';
|
|
5
6
|
import { createEditorStateNotificationPlugin } from './editorStateNotificationPlugin';
|
|
@@ -22,7 +23,7 @@ export function createPMPlugins(config) {
|
|
|
22
23
|
}).filter(function (plugin) {
|
|
23
24
|
return typeof plugin !== 'undefined';
|
|
24
25
|
});
|
|
25
|
-
if (expValEquals('platform_editor_native_anchor_with_dnd', 'isEnabled', true)) {
|
|
26
|
+
if (expValEquals('platform_editor_native_anchor_with_dnd', 'isEnabled', true) || isExperimentEnabled('platform_editor_block_control_migration')) {
|
|
26
27
|
pmPlugins.push(createEditorNativeAnchorSupportPlugin(config.schema));
|
|
27
28
|
}
|
|
28
29
|
if (config.onEditorStateUpdated !== undefined) {
|
|
@@ -51,8 +51,8 @@ import { tasksAndDecisionsPlugin } from '@atlaskit/editor-plugins/tasks-and-deci
|
|
|
51
51
|
import { textColorPlugin } from '@atlaskit/editor-plugins/text-color';
|
|
52
52
|
import { toolbarListsIndentationPlugin } from '@atlaskit/editor-plugins/toolbar-lists-indentation';
|
|
53
53
|
import { ufoPlugin } from '@atlaskit/editor-plugins/ufo';
|
|
54
|
-
import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
|
|
55
54
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
55
|
+
import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
|
|
56
56
|
import { isFullPage as fullPageCheck } from '../utils/is-full-page';
|
|
57
57
|
import { version as coreVersion } from '../version-wrapper';
|
|
58
58
|
import { createDefaultPreset } from './default';
|
|
@@ -8,8 +8,8 @@ import { useSharedPluginStateSelector } from '@atlaskit/editor-common/use-shared
|
|
|
8
8
|
import { FULL_PAGE_EDITOR_TOOLBAR_HEIGHT } from '@atlaskit/editor-shared-styles';
|
|
9
9
|
import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
|
|
10
10
|
import { componentWithCondition } from '@atlaskit/platform-feature-flags-react/component-with-condition';
|
|
11
|
-
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
12
11
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
12
|
+
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
13
13
|
import { getPrimaryToolbarComponents } from '../../Toolbar/getPrimaryToolbarComponents';
|
|
14
14
|
import { FullPageEditorWrapperCompiled } from './FullPage-compiled';
|
|
15
15
|
import { FullPageEditorWrapperEmotion } from './FullPage-emotion';
|
|
@@ -7,8 +7,8 @@ import { injectIntl } from 'react-intl';
|
|
|
7
7
|
import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks';
|
|
8
8
|
import { fullPageMessages as messages } from '@atlaskit/editor-common/messages';
|
|
9
9
|
import { akEditorGutterPaddingDynamic, akEditorDefaultLayoutWidth } from '@atlaskit/editor-shared-styles';
|
|
10
|
-
import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
|
|
11
10
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
11
|
+
import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
|
|
12
12
|
|
|
13
13
|
// Ignored via go/ees005
|
|
14
14
|
// eslint-disable-next-line import/no-named-as-default
|
|
@@ -15,9 +15,9 @@ import { taskListSelector } from '@atlaskit/adf-schema/task-list';
|
|
|
15
15
|
import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks';
|
|
16
16
|
import { fullPageMessages as messages } from '@atlaskit/editor-common/messages';
|
|
17
17
|
import { akEditorFullPageNarrowBreakout, akEditorGutterPaddingDynamic, akEditorGutterPaddingReduced, akEditorDefaultLayoutWidth } from '@atlaskit/editor-shared-styles';
|
|
18
|
+
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
18
19
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
19
20
|
import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
|
|
20
|
-
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
21
21
|
// Ignored via go/ees005
|
|
22
22
|
// eslint-disable-next-line import/no-named-as-default
|
|
23
23
|
import ClickAreaBlock from '../../Addon/ClickAreaBlock';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/* eslint-disable @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766 */
|
|
2
|
+
|
|
2
3
|
import { css } from '@emotion/react';
|
|
3
4
|
import { relativeFontSizeToBase16 } from '@atlaskit/editor-shared-styles';
|
|
4
5
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
@@ -10,6 +10,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
10
10
|
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
11
11
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
12
12
|
/* eslint-disable jsdoc/require-jsdoc -- Pre-existing lint debt surfaced by this mechanical type-import-only PR. */
|
|
13
|
+
|
|
13
14
|
import React from 'react';
|
|
14
15
|
import { injectIntl } from 'react-intl';
|
|
15
16
|
import Transition from 'react-transition-group/Transition';
|
|
@@ -13,7 +13,6 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
13
13
|
import React from 'react';
|
|
14
14
|
// eslint-disable-next-line import/order
|
|
15
15
|
import { getBrowserInfo } from '@atlaskit/editor-common/browser';
|
|
16
|
-
|
|
17
16
|
// eslint-disable-next-line @atlaskit/editor/enforce-todo-comment-format
|
|
18
17
|
// TODO: add back tableSharedStyle when migrate table styles
|
|
19
18
|
// import { richMediaClassName, tableSharedStyle } from '@atlaskit/editor-common/styles';
|
|
@@ -24,9 +23,9 @@ import { overflowShadowForCompiled } from '@atlaskit/editor-shared-styles/overfl
|
|
|
24
23
|
import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
|
|
25
24
|
import { UNSAFE_expValNoExposure } from '@atlaskit/platform-feature-experiments/unsafe-exp-val-no-exposure';
|
|
26
25
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
26
|
+
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
27
27
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
28
28
|
import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
|
|
29
|
-
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
30
29
|
import { useThemeObserver } from '@atlaskit/tokens/use-theme-observer';
|
|
31
30
|
import { getBaseFontSize } from '../../composable-editor/utils/getBaseFontSize';
|
|
32
31
|
|