@atlaskit/editor-core 241.0.3 → 241.0.5
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 +18 -0
- package/dist/cjs/composable-editor/{editor-internal-compiled.js → editor-internal-container.js} +4 -4
- package/dist/cjs/composable-editor/editor-internal.js +2 -2
- package/dist/cjs/ui/Addon/ClickAreaBlock/{clickAreaBlock-compiled.js → clickAreaBlock.js} +4 -4
- package/dist/cjs/ui/Addon/ClickAreaBlock/index.js +2 -2
- package/dist/cjs/ui/Appearance/Comment/{FixedToolbar-compiled.js → FixedToolbar.js} +4 -4
- package/dist/cjs/ui/Appearance/Comment/{StickyToolbar-compiled.js → StickyToolbar.js} +4 -4
- package/dist/cjs/ui/Appearance/Comment/Toolbar.js +4 -4
- package/dist/cjs/ui/Appearance/FullPage/FullPage.js +2 -2
- package/dist/cjs/ui/Appearance/FullPage/{FullPage-compiled.js → FullPageEditorWrapper.js} +4 -4
- package/dist/cjs/ui/Appearance/FullPage/FullPageToolbar.js +3 -3
- package/dist/cjs/ui/Appearance/FullPage/{MainToolbar-compiled.js → MainToolbarWrappers.js} +6 -6
- package/dist/cjs/ui/ChromeCollapsed/{ChromeCollapsed-compiled.js → ChromeCollapsed.js} +4 -4
- package/dist/cjs/ui/ChromeCollapsed/index.js +2 -2
- package/dist/cjs/ui/ContextPanel/{index-compiled.js → ContextPanelWrappers.js} +5 -5
- package/dist/cjs/ui/ContextPanel/index.js +3 -3
- package/dist/cjs/ui/EditorContentContainer/EditorContentContainer.compiled.css +213 -0
- package/dist/cjs/ui/EditorContentContainer/EditorContentContainer.js +415 -4
- package/dist/cjs/ui/PluginSlot/{PluginSlot-compiled.js → PluginSlot.js} +4 -4
- package/dist/cjs/ui/PluginSlot/index.js +2 -2
- package/dist/cjs/ui/Toolbar/{ToolbarComponentsWrapper-compiled.js → ToolbarComponentsWrapper.js} +4 -4
- package/dist/cjs/ui/Toolbar/ToolbarInner.js +2 -2
- package/dist/cjs/ui/Toolbar/{ToolbarSizeDetectorWrapper-compiled.js → ToolbarSizeDetectorWrapper.js} +4 -4
- package/dist/cjs/ui/Toolbar/ToolbarWithSizeDetector.js +2 -2
- package/dist/cjs/ui/WithFlash/index.js +2 -2
- package/dist/cjs/ui/WithFlash/{withFlash-compiled.js → withFlash.js} +9 -9
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/composable-editor/{editor-internal-compiled.js → editor-internal-container.js} +3 -3
- package/dist/es2019/composable-editor/editor-internal.js +2 -2
- package/dist/es2019/ui/Addon/ClickAreaBlock/{clickAreaBlock-compiled.js → clickAreaBlock.js} +3 -3
- package/dist/es2019/ui/Addon/ClickAreaBlock/index.js +2 -2
- package/dist/es2019/ui/Appearance/Comment/{FixedToolbar-compiled.js → FixedToolbar.js} +3 -3
- package/dist/es2019/ui/Appearance/Comment/{StickyToolbar-compiled.js → StickyToolbar.js} +3 -3
- package/dist/es2019/ui/Appearance/Comment/Toolbar.js +4 -4
- package/dist/es2019/ui/Appearance/FullPage/FullPage.js +2 -2
- package/dist/es2019/ui/Appearance/FullPage/{FullPage-compiled.js → FullPageEditorWrapper.js} +3 -3
- package/dist/es2019/ui/Appearance/FullPage/FullPageToolbar.js +3 -3
- package/dist/es2019/ui/Appearance/FullPage/{MainToolbar-compiled.js → MainToolbarWrappers.js} +5 -5
- package/dist/es2019/ui/ChromeCollapsed/{ChromeCollapsed-compiled.js → ChromeCollapsed.js} +3 -3
- package/dist/es2019/ui/ChromeCollapsed/index.js +2 -2
- package/dist/es2019/ui/ContextPanel/{index-compiled.js → ContextPanelWrappers.js} +4 -4
- package/dist/es2019/ui/ContextPanel/index.js +3 -3
- package/dist/es2019/ui/EditorContentContainer/EditorContentContainer.compiled.css +213 -0
- package/dist/es2019/ui/EditorContentContainer/EditorContentContainer.js +476 -4
- package/dist/es2019/ui/PluginSlot/{PluginSlot-compiled.js → PluginSlot.js} +3 -3
- package/dist/es2019/ui/PluginSlot/index.js +2 -2
- package/dist/es2019/ui/Toolbar/{ToolbarComponentsWrapper-compiled.js → ToolbarComponentsWrapper.js} +3 -3
- package/dist/es2019/ui/Toolbar/ToolbarInner.js +2 -2
- package/dist/es2019/ui/Toolbar/{ToolbarSizeDetectorWrapper-compiled.js → ToolbarSizeDetectorWrapper.js} +3 -3
- package/dist/es2019/ui/Toolbar/ToolbarWithSizeDetector.js +2 -2
- package/dist/es2019/ui/WithFlash/index.js +2 -2
- package/dist/es2019/ui/WithFlash/{withFlash-compiled.js → withFlash.js} +3 -3
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/composable-editor/{editor-internal-compiled.js → editor-internal-container.js} +3 -3
- package/dist/esm/composable-editor/editor-internal.js +2 -2
- package/dist/esm/ui/Addon/ClickAreaBlock/{clickAreaBlock-compiled.js → clickAreaBlock.js} +3 -3
- package/dist/esm/ui/Addon/ClickAreaBlock/index.js +2 -2
- package/dist/esm/ui/Appearance/Comment/{FixedToolbar-compiled.js → FixedToolbar.js} +3 -3
- package/dist/esm/ui/Appearance/Comment/{StickyToolbar-compiled.js → StickyToolbar.js} +3 -3
- package/dist/esm/ui/Appearance/Comment/Toolbar.js +4 -4
- package/dist/esm/ui/Appearance/FullPage/FullPage.js +2 -2
- package/dist/esm/ui/Appearance/FullPage/{FullPage-compiled.js → FullPageEditorWrapper.js} +3 -3
- package/dist/esm/ui/Appearance/FullPage/FullPageToolbar.js +3 -3
- package/dist/esm/ui/Appearance/FullPage/{MainToolbar-compiled.js → MainToolbarWrappers.js} +5 -5
- package/dist/esm/ui/ChromeCollapsed/{ChromeCollapsed-compiled.js → ChromeCollapsed.js} +3 -3
- package/dist/esm/ui/ChromeCollapsed/index.js +2 -2
- package/dist/esm/ui/ContextPanel/{index-compiled.js → ContextPanelWrappers.js} +4 -4
- package/dist/esm/ui/ContextPanel/index.js +3 -3
- package/dist/esm/ui/EditorContentContainer/EditorContentContainer.compiled.css +213 -0
- package/dist/esm/ui/EditorContentContainer/EditorContentContainer.js +419 -4
- package/dist/esm/ui/PluginSlot/{PluginSlot-compiled.js → PluginSlot.js} +3 -3
- package/dist/esm/ui/PluginSlot/index.js +2 -2
- package/dist/esm/ui/Toolbar/{ToolbarComponentsWrapper-compiled.js → ToolbarComponentsWrapper.js} +3 -3
- package/dist/esm/ui/Toolbar/ToolbarInner.js +2 -2
- package/dist/esm/ui/Toolbar/{ToolbarSizeDetectorWrapper-compiled.js → ToolbarSizeDetectorWrapper.js} +3 -3
- package/dist/esm/ui/Toolbar/ToolbarWithSizeDetector.js +2 -2
- package/dist/esm/ui/WithFlash/index.js +2 -2
- package/dist/esm/ui/WithFlash/{withFlash-compiled.js → withFlash.js} +8 -8
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/composable-editor/{editor-internal-compiled.d.ts → editor-internal-container.d.ts} +1 -1
- package/dist/types/ui/Addon/ClickAreaBlock/clickAreaBlock.d.ts +6 -0
- package/dist/types/ui/Appearance/Comment/{FixedToolbar-compiled.d.ts → FixedToolbar.d.ts} +2 -2
- package/dist/types/ui/Appearance/Comment/{StickyToolbar-compiled.d.ts → StickyToolbar.d.ts} +2 -2
- package/dist/types/ui/Appearance/FullPage/FullPageEditorWrapper.d.ts +7 -0
- package/dist/types/ui/Appearance/FullPage/{MainToolbar-compiled.d.ts → MainToolbarWrappers.d.ts} +3 -3
- package/dist/types/ui/ChromeCollapsed/ChromeCollapsed.d.ts +7 -0
- package/dist/types/ui/ContextPanel/{index-compiled.d.ts → ContextPanelWrappers.d.ts} +2 -2
- package/dist/types/ui/EditorContentContainer/EditorContentContainer.d.ts +26 -4
- package/dist/types/ui/PluginSlot/PluginSlot.d.ts +6 -0
- package/dist/types/ui/Toolbar/ToolbarComponentsWrapper.d.ts +11 -0
- package/dist/types/ui/Toolbar/ToolbarSizeDetectorWrapper.d.ts +11 -0
- package/dist/types/ui/WithFlash/{withFlash-compiled.d.ts → withFlash.d.ts} +1 -1
- package/package.json +6 -6
- package/dist/cjs/ui/EditorContentContainer/EditorContentContainer-compiled.compiled.css +0 -212
- package/dist/cjs/ui/EditorContentContainer/EditorContentContainer-compiled.js +0 -421
- package/dist/es2019/ui/EditorContentContainer/EditorContentContainer-compiled.compiled.css +0 -212
- package/dist/es2019/ui/EditorContentContainer/EditorContentContainer-compiled.js +0 -477
- package/dist/esm/ui/EditorContentContainer/EditorContentContainer-compiled.compiled.css +0 -212
- package/dist/esm/ui/EditorContentContainer/EditorContentContainer-compiled.js +0 -420
- package/dist/types/ui/Addon/ClickAreaBlock/clickAreaBlock-compiled.d.ts +0 -6
- package/dist/types/ui/Appearance/FullPage/FullPage-compiled.d.ts +0 -7
- package/dist/types/ui/ChromeCollapsed/ChromeCollapsed-compiled.d.ts +0 -7
- package/dist/types/ui/EditorContentContainer/EditorContentContainer-compiled.d.ts +0 -29
- package/dist/types/ui/PluginSlot/PluginSlot-compiled.d.ts +0 -6
- package/dist/types/ui/Toolbar/ToolbarComponentsWrapper-compiled.d.ts +0 -11
- package/dist/types/ui/Toolbar/ToolbarSizeDetectorWrapper-compiled.d.ts +0 -11
- /package/dist/cjs/composable-editor/{editor-internal-compiled.compiled.css → editor-internal-container.compiled.css} +0 -0
- /package/dist/cjs/ui/Addon/ClickAreaBlock/{clickAreaBlock-compiled.compiled.css → clickAreaBlock.compiled.css} +0 -0
- /package/dist/cjs/ui/Appearance/Comment/{FixedToolbar-compiled.compiled.css → FixedToolbar.compiled.css} +0 -0
- /package/dist/cjs/ui/Appearance/Comment/{StickyToolbar-compiled.compiled.css → StickyToolbar.compiled.css} +0 -0
- /package/dist/cjs/ui/Appearance/FullPage/{FullPage-compiled.compiled.css → FullPageEditorWrapper.compiled.css} +0 -0
- /package/dist/cjs/ui/Appearance/FullPage/{MainToolbar-compiled.compiled.css → MainToolbarWrappers.compiled.css} +0 -0
- /package/dist/cjs/ui/ChromeCollapsed/{ChromeCollapsed-compiled.compiled.css → ChromeCollapsed.compiled.css} +0 -0
- /package/dist/cjs/ui/ContextPanel/{index-compiled.compiled.css → ContextPanelWrappers.compiled.css} +0 -0
- /package/dist/cjs/ui/PluginSlot/{PluginSlot-compiled.compiled.css → PluginSlot.compiled.css} +0 -0
- /package/dist/cjs/ui/Toolbar/{ToolbarComponentsWrapper-compiled.compiled.css → ToolbarComponentsWrapper.compiled.css} +0 -0
- /package/dist/cjs/ui/Toolbar/{ToolbarSizeDetectorWrapper-compiled.compiled.css → ToolbarSizeDetectorWrapper.compiled.css} +0 -0
- /package/dist/cjs/ui/WithFlash/{withFlash-compiled.compiled.css → withFlash.compiled.css} +0 -0
- /package/dist/es2019/composable-editor/{editor-internal-compiled.compiled.css → editor-internal-container.compiled.css} +0 -0
- /package/dist/es2019/ui/Addon/ClickAreaBlock/{clickAreaBlock-compiled.compiled.css → clickAreaBlock.compiled.css} +0 -0
- /package/dist/es2019/ui/Appearance/Comment/{FixedToolbar-compiled.compiled.css → FixedToolbar.compiled.css} +0 -0
- /package/dist/es2019/ui/Appearance/Comment/{StickyToolbar-compiled.compiled.css → StickyToolbar.compiled.css} +0 -0
- /package/dist/es2019/ui/Appearance/FullPage/{FullPage-compiled.compiled.css → FullPageEditorWrapper.compiled.css} +0 -0
- /package/dist/es2019/ui/Appearance/FullPage/{MainToolbar-compiled.compiled.css → MainToolbarWrappers.compiled.css} +0 -0
- /package/dist/es2019/ui/ChromeCollapsed/{ChromeCollapsed-compiled.compiled.css → ChromeCollapsed.compiled.css} +0 -0
- /package/dist/es2019/ui/ContextPanel/{index-compiled.compiled.css → ContextPanelWrappers.compiled.css} +0 -0
- /package/dist/es2019/ui/PluginSlot/{PluginSlot-compiled.compiled.css → PluginSlot.compiled.css} +0 -0
- /package/dist/es2019/ui/Toolbar/{ToolbarComponentsWrapper-compiled.compiled.css → ToolbarComponentsWrapper.compiled.css} +0 -0
- /package/dist/es2019/ui/Toolbar/{ToolbarSizeDetectorWrapper-compiled.compiled.css → ToolbarSizeDetectorWrapper.compiled.css} +0 -0
- /package/dist/es2019/ui/WithFlash/{withFlash-compiled.compiled.css → withFlash.compiled.css} +0 -0
- /package/dist/esm/composable-editor/{editor-internal-compiled.compiled.css → editor-internal-container.compiled.css} +0 -0
- /package/dist/esm/ui/Addon/ClickAreaBlock/{clickAreaBlock-compiled.compiled.css → clickAreaBlock.compiled.css} +0 -0
- /package/dist/esm/ui/Appearance/Comment/{FixedToolbar-compiled.compiled.css → FixedToolbar.compiled.css} +0 -0
- /package/dist/esm/ui/Appearance/Comment/{StickyToolbar-compiled.compiled.css → StickyToolbar.compiled.css} +0 -0
- /package/dist/esm/ui/Appearance/FullPage/{FullPage-compiled.compiled.css → FullPageEditorWrapper.compiled.css} +0 -0
- /package/dist/esm/ui/Appearance/FullPage/{MainToolbar-compiled.compiled.css → MainToolbarWrappers.compiled.css} +0 -0
- /package/dist/esm/ui/ChromeCollapsed/{ChromeCollapsed-compiled.compiled.css → ChromeCollapsed.compiled.css} +0 -0
- /package/dist/esm/ui/ContextPanel/{index-compiled.compiled.css → ContextPanelWrappers.compiled.css} +0 -0
- /package/dist/esm/ui/PluginSlot/{PluginSlot-compiled.compiled.css → PluginSlot.compiled.css} +0 -0
- /package/dist/esm/ui/Toolbar/{ToolbarComponentsWrapper-compiled.compiled.css → ToolbarComponentsWrapper.compiled.css} +0 -0
- /package/dist/esm/ui/Toolbar/{ToolbarSizeDetectorWrapper-compiled.compiled.css → ToolbarSizeDetectorWrapper.compiled.css} +0 -0
- /package/dist/esm/ui/WithFlash/{withFlash-compiled.compiled.css → withFlash.compiled.css} +0 -0
|
@@ -1,8 +1,480 @@
|
|
|
1
|
-
|
|
1
|
+
/* EditorContentContainer.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
|
+
// oxlint-disable-next-line typescript-eslint/triple-slash-reference
|
|
3
|
+
/// <reference path="../../types/compiled-shims.d.ts" />
|
|
4
|
+
// Because we migrated with using cssMapScope API for non atomic css, so these atomic css related eslint suppression no longer needs to be fixed.
|
|
5
|
+
/* eslint-disable @atlaskit/platform/use-motion-token-values, @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/design-system/no-invalid-css-map, @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/platform/expand-spacing-shorthand, @atlaskit/platform/expand-border-shorthand, @atlaskit/platform/expand-background-shorthand */
|
|
6
|
+
import "./EditorContentContainer.compiled.css";
|
|
7
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
8
|
+
import React from 'react';
|
|
9
|
+
// eslint-disable-next-line import/order
|
|
10
|
+
import { getBrowserInfo } from '@atlaskit/editor-common/browser';
|
|
2
11
|
|
|
12
|
+
// eslint-disable-next-line @atlaskit/editor/enforce-todo-comment-format
|
|
13
|
+
// TODO: add back tableSharedStyle when migrate table styles
|
|
14
|
+
// import { richMediaClassName, tableSharedStyle } from '@atlaskit/editor-common/styles';
|
|
15
|
+
|
|
16
|
+
import { tableCellBackgroundColorVariablesForCompiled as tableCellBackgroundColorVariables } from '@atlaskit/editor-common/table-cell-background-for-compiled';
|
|
17
|
+
import { akEditorFullPageDefaultFontSize, akEditorGutterPaddingDynamic } from '@atlaskit/editor-shared-styles/constants';
|
|
18
|
+
import { overflowShadowForCompiled as overflowShadow } from '@atlaskit/editor-shared-styles/overflow-shadow-for-compiled';
|
|
19
|
+
import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
|
|
20
|
+
import { UNSAFE_expValNoExposure } from '@atlaskit/platform-feature-experiments/unsafe-exp-val-no-exposure';
|
|
21
|
+
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
22
|
+
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
23
|
+
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
24
|
+
import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
|
|
25
|
+
import { useThemeObserver } from '@atlaskit/tokens/use-theme-observer';
|
|
26
|
+
import { getBaseFontSize } from '../../composable-editor/utils/getBaseFontSize';
|
|
27
|
+
|
|
28
|
+
// = akEditorDefaultLayoutWidth * breakoutWideScaleRatio = 1010.8 ~ 1011 This is a resulting width value that is applied to nodes that currently use breakouts (except table) and are set to `wide` when the viewport's width is > 1329px.
|
|
29
|
+
const akEditorCalculatedWideLayoutWidth = 1011;
|
|
30
|
+
// from breakoutConsts.calcWideWidth, layoutMaxWidth * breakoutConsts.wideScaleRatio = 904.8 ~ 905 This is a resulting width value that is applied to nodes that currently use breakouts (except table) and are set to `wide` when the viewport's width is <= 1266px.
|
|
31
|
+
const akEditorCalculatedWideLayoutWidthSmallViewport = 905;
|
|
32
|
+
const akEditorGutterPadding = 32;
|
|
33
|
+
const akEditorDefaultLayoutWidth = 760;
|
|
34
|
+
const akEditorFullWidthLayoutWidth = 1800;
|
|
35
|
+
const tableOverflowShadowWidthWide = 32;
|
|
36
|
+
// The breakpoint for small devices is 1266px, copied from getBreakpoint in platform/packages/editor/editor-common/src/ui/WidthProvider/index.tsx
|
|
37
|
+
const akEditorBreakpointForSmallDevice = `1266px`;
|
|
38
|
+
const akEditorGutterPaddingReduced = 24;
|
|
39
|
+
const akEditorFullPageNarrowBreakout = 600;
|
|
40
|
+
const akEditorUltraWideLayoutWidth = 4000;
|
|
41
|
+
// Matches the legacy comment `less-margin` check: WidthProvider width (the editor's border box)
|
|
42
|
+
// below akEditorMobileBreakoutPoint (720). This content area's content box is that width minus
|
|
43
|
+
// the 2 x 1px editor border and 2 x 20px padding.
|
|
44
|
+
const akEditorCommentLessMarginBreakout = 720 - 2 - 40;
|
|
45
|
+
const commentLessMarginContainerQuery = `@container (width < ${akEditorCommentLessMarginBreakout}px)`;
|
|
46
|
+
// Layout responsiveness breakpoints — chosen to align editor layout responsiveness with the renderer.
|
|
47
|
+
// Applied to the editor-area container query (max-width) for layout sections.
|
|
48
|
+
const akEditorLayoutFullWidthBreakpoint = 724;
|
|
49
|
+
const akEditorLayoutFixedWidthBreakpoint = 788;
|
|
50
|
+
const akEditorLayoutResizedBreakpoint = 820;
|
|
51
|
+
|
|
52
|
+
// Originally copied from packages/editor/editor-core/src/ui/Appearance/Comment/Comment.tsx
|
|
53
|
+
const CommentEditorMargin = 14;
|
|
54
|
+
const GRID_GUTTER = 12;
|
|
55
|
+
const blockNodesVerticalMargin = '0.75rem';
|
|
56
|
+
const fontSize14px = `${14 / 16}rem`;
|
|
57
|
+
const scaledBlockNodesVerticalMargin = '0.75em';
|
|
58
|
+
// emoji constants — values inlined from packages/elements/emoji/src/util/constants.ts
|
|
59
|
+
// If you need to update these values, please also update packages/elements/emoji/src/util/constants.ts
|
|
60
|
+
const defaultEmojiHeight = 20;
|
|
61
|
+
const defaultDenseEmojiHeight = 16.25;
|
|
62
|
+
const scaledEmojiHeightH1 = 28;
|
|
63
|
+
const scaledEmojiHeightH2 = 26;
|
|
64
|
+
const scaledEmojiHeightH3 = 24;
|
|
65
|
+
const scaledEmojiHeightH4 = 22;
|
|
66
|
+
const denseEmojiHeightH1 = 24.25;
|
|
67
|
+
const denseEmojiHeightH2 = 22.25;
|
|
68
|
+
const denseEmojiHeightH3 = 20.25;
|
|
69
|
+
const denseEmojiHeightH4 = 18.25;
|
|
70
|
+
const emojiSelectionStyles = null;
|
|
71
|
+
const gutterDangerOverlay = null;
|
|
72
|
+
const blanketSelectionStyles = null;
|
|
73
|
+
// copied from packages/editor/editor-shared-styles/src/consts/consts.ts
|
|
74
|
+
const akEditorLineHeight = 1.714;
|
|
75
|
+
const listsStylesSafariFixMultiSelector = `
|
|
76
|
+
.ProseMirror:not(.blockCardView-content-wrap) > li > p:first-child,
|
|
77
|
+
.ProseMirror:not(.blockCardView-content-wrap) > li > .code-block:first-child,
|
|
78
|
+
.ProseMirror:not(.blockCardView-content-wrap) > li > .ProseMirror-gapcursor:first-child + .code-block`;
|
|
79
|
+
const editorAreaNonSmallDeviceContainerQuery = `@container editor-area (width >= ${akEditorBreakpointForSmallDevice})`;
|
|
80
|
+
const editorAreaNarrowPageContainerQuery = `@container editor-area (max-width: ${akEditorFullPageNarrowBreakout}px)`;
|
|
81
|
+
const editorAreaLayoutFullWidthMaxWidthContainerQuery = `@container editor-area (max-width: ${akEditorLayoutFullWidthBreakpoint}px)`;
|
|
82
|
+
const editorAreaLayoutFixedWidthMaxWidthContainerQuery = `@container editor-area (max-width: ${akEditorLayoutFixedWidthBreakpoint}px)`;
|
|
83
|
+
const editorAreaLayoutResizedMaxWidthContainerQuery = `@container editor-area (max-width: ${akEditorLayoutResizedBreakpoint}px)`;
|
|
84
|
+
const placeholderFadeInKeyframes = null;
|
|
85
|
+
const fadeIn = null;
|
|
86
|
+
const inlineStartShadow = null;
|
|
87
|
+
const inlineEndShadow = null;
|
|
88
|
+
const hideNativeBrowserTextSelectionStyles = null;
|
|
89
|
+
const boxShadowSelectionStyles = null;
|
|
90
|
+
const dangerBorderStyles = null;
|
|
91
|
+
const backgroundSelectionStyles = null;
|
|
92
|
+
const dangerBackgroundStyles = null;
|
|
93
|
+
const mentionsSelectedColor = null;
|
|
94
|
+
const fixVerticalAlignmentSelector = `
|
|
95
|
+
&:first-of-type + ul,
|
|
96
|
+
&:first-of-type + span + ul,
|
|
97
|
+
&:first-of-type + ol,
|
|
98
|
+
&:first-of-type + span + ol,
|
|
99
|
+
&:first-of-type + pre,
|
|
100
|
+
&:first-of-type + span + pre,
|
|
101
|
+
&:first-of-type + blockquote,
|
|
102
|
+
&:first-of-type + span + blockquote
|
|
103
|
+
`;
|
|
104
|
+
const gapCursorTwoImagesSideBySideFixSelector = `
|
|
105
|
+
.ProseMirror-gapcursor[layout="wrap-left"] + span + [layout="wrap-left"],
|
|
106
|
+
.ProseMirror-gapcursor[layout="wrap-right"] + span + [layout="wrap-right"],
|
|
107
|
+
.ProseMirror-gapcursor + [layout="wrap-left"] + [layout="wrap-right"],
|
|
108
|
+
.ProseMirror-gapcursor + [layout="wrap-left"] + span + [layout="wrap-right"],
|
|
109
|
+
.ProseMirror-gapcursor + [layout="wrap-right"] + [layout="wrap-left"],
|
|
110
|
+
.ProseMirror-gapcursor + [layout="wrap-right"] + span + [layout="wrap-left"],
|
|
111
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor + [layout="wrap-right"],
|
|
112
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor + span [layout="wrap-right"],
|
|
113
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor + [layout="wrap-left"],
|
|
114
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor + span + [layout="wrap-left"],
|
|
115
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor`;
|
|
116
|
+
const gapCursorMarginFixSelector = `
|
|
117
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor + [layout="wrap-right"] > div,
|
|
118
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor + span + [layout="wrap-right"] > div,
|
|
119
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor + [layout="wrap-left"] > div,
|
|
120
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor + span + [layout="wrap-left"] > div,
|
|
121
|
+
.ProseMirror-gapcursor + [layout="wrap-right"] + [layout="wrap-left"] > div,
|
|
122
|
+
.ProseMirror-gapcursor + [layout="wrap-right"] + span + [layout="wrap-left"] > div,
|
|
123
|
+
.ProseMirror-gapcursor + [layout="wrap-left"] + [layout="wrap-right"] > div,
|
|
124
|
+
.ProseMirror-gapcursor + [layout="wrap-left"] + span + [layout="wrap-right"] > div`;
|
|
125
|
+
const gapCursorFloatLeftFixSelector = `
|
|
126
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor,
|
|
127
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor`;
|
|
128
|
+
const gapCursorAfterPseudoSelector = `
|
|
129
|
+
.ProseMirror-gapcursor + [layout="wrap-left"] + span + [layout="wrap-right"]::after,
|
|
130
|
+
.ProseMirror-gapcursor + [layout="wrap-right"] + span + [layout="wrap-left"]::after,
|
|
131
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor + [layout="wrap-right"]::after,
|
|
132
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor + span + [layout="wrap-right"]::after,
|
|
133
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor + [layout="wrap-left"]::after,
|
|
134
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor + span + [layout="wrap-left"]::after`;
|
|
135
|
+
const gapCursorMarginDeepChildrenFixSelector = `
|
|
136
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor + [layout="wrap-right"] + *,
|
|
137
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor + [layout="wrap-right"] + span + *,
|
|
138
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor + [layout="wrap-left"] + *,
|
|
139
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor + [layout="wrap-left"] + span + *,
|
|
140
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor + span + [layout="wrap-right"] + *,
|
|
141
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor + span + [layout="wrap-left"] + *,
|
|
142
|
+
.ProseMirror-gapcursor + [layout="wrap-left"] + span + [layout="wrap-right"] + *,
|
|
143
|
+
.ProseMirror-gapcursor + [layout="wrap-right"] + span + [layout="wrap-left"] + *,
|
|
144
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor + [layout="wrap-right"] + * > *,
|
|
145
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor + [layout="wrap-right"] + span + * > *,
|
|
146
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor + [layout="wrap-left"] + * > *,
|
|
147
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor + [layout="wrap-left"] + span + * > *,
|
|
148
|
+
[layout="wrap-left"] + .ProseMirror-gapcursor + span + [layout="wrap-right"] + * > *,
|
|
149
|
+
[layout="wrap-right"] + .ProseMirror-gapcursor + span + [layout="wrap-left"] + * > *,
|
|
150
|
+
.ProseMirror-gapcursor + [layout="wrap-left"] + span + [layout="wrap-right"] + * > *,
|
|
151
|
+
.ProseMirror-gapcursor + [layout="wrap-right"] + span + [layout="wrap-left"] + * > *,
|
|
152
|
+
.ProseMirror-widget:not([data-blocks-decoration-container="true"]):not([data-blocks-drag-handle-container="true"]):not([data-blocks-quick-insert-container="true"]) + .ProseMirror-gapcursor + *,
|
|
153
|
+
.ProseMirror-widget:not([data-blocks-decoration-container="true"]):not([data-blocks-drag-handle-container="true"]):not([data-blocks-quick-insert-container="true"]) + .ProseMirror-gapcursor + span + *`;
|
|
154
|
+
const gapCursorBlink = null;
|
|
155
|
+
const pulseIn = null;
|
|
156
|
+
const pulseOut = null;
|
|
157
|
+
const pulseInDuringTr = null;
|
|
158
|
+
const pulseOutDuringTr = null;
|
|
159
|
+
|
|
160
|
+
// Agent edit shimmer: skeleton-loader sweep across the agent-authored range.
|
|
161
|
+
const agentShimmer = null;
|
|
162
|
+
|
|
163
|
+
// Agent edit purple "just edited" highlight: eases the background and underline in, holds, then eases
|
|
164
|
+
// them back out over the highlight's lifetime (duration set inline per-decoration to match removal).
|
|
165
|
+
const agentEditHighlight = null;
|
|
166
|
+
const syncBlockCreationLoadingKeyframes = null;
|
|
167
|
+
const mentionRunShimmer = null;
|
|
168
|
+
|
|
169
|
+
/**
|
|
170
|
+
* aiPanelStyles
|
|
171
|
+
* was imported from packages/editor/editor-core/src/ui/ContentStyles/ai-panels.ts
|
|
172
|
+
*/
|
|
173
|
+
const rotationAnimation = null;
|
|
174
|
+
const rotationAnimationFirefox = null;
|
|
175
|
+
|
|
176
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values
|
|
177
|
+
const prismBorderBaseBackgroundFirefox = `linear-gradient(90deg, #0065FF 0%, #0469FF 12%, #BF63F3 24%, #FFA900 48%, #BF63F3 64%, #0469FF 80%, #0065FF 100%)`;
|
|
178
|
+
|
|
179
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values
|
|
180
|
+
const prismBorderBaseBackground = `conic-gradient(from var(--panel-gradient-angle, 270deg), #0065FF 0%, #0469FF 20%, #BF63F3 50%, #FFA900 56%, #0065FF 100%)`;
|
|
181
|
+
|
|
182
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values
|
|
183
|
+
const prismBorderDarkBackgroundFirefox = `linear-gradient(90deg, #0065FF80 0%, #0469FF80 12%, #BF63F380 24%, #FFA90080 48%, #BF63F380 64%, #0469FF80 80%, #0065FF80 100%)`;
|
|
184
|
+
|
|
185
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values
|
|
186
|
+
const prismBorderDarkBackground = `conic-gradient(from var(--panel-gradient-angle, 270deg), #0065FF80 0%, #0469FF80 20%, #BF63F380 50%, #FFA90080 56%, #0065FF80 100%)`;
|
|
187
|
+
const borderSelectionStyles = null;
|
|
188
|
+
const overflowShadowStyles = null;
|
|
189
|
+
|
|
190
|
+
/**
|
|
191
|
+
* editorContentStyles contains the Compiled CSS styles migrated from EditorContentContainer/styles.
|
|
192
|
+
* Validate style changes with local VR and integration tests.
|
|
193
|
+
*
|
|
194
|
+
* If you are not sure, please contact #proj-cc-editor-full-compiled-css-migration
|
|
195
|
+
*/
|
|
196
|
+
// eslint-disable-next-line @atlaskit/design-system/no-css-map-scoped
|
|
197
|
+
const editorContentStyles = {
|
|
198
|
+
aiPanelBaseFirefoxStyles: "cc-1gbyxs2",
|
|
199
|
+
aiPanelBaseStyles: "cc-wna58a",
|
|
200
|
+
aiPanelDarkFirefoxStyles: "cc-1f8w0o2",
|
|
201
|
+
aiPanelDarkStyles: "cc-1es53wh",
|
|
202
|
+
alignMultipleWrappedImageInLayoutStyles: "cc-ke86s0",
|
|
203
|
+
annotationStyles: "cc-10az4f7",
|
|
204
|
+
backgroundColorStyles: "cc-1oqgp5j",
|
|
205
|
+
highlightLinksUnsetStyles: "cc-ddasnd",
|
|
206
|
+
baseStyles: "cc-zq7evp",
|
|
207
|
+
baseStylesMaxContainerWidthFixes: "cc-n9evsr",
|
|
208
|
+
blockMarksStyles: "cc-skb4y2",
|
|
209
|
+
extensionWithBreakoutStyles: "cc-1k1v07z",
|
|
210
|
+
blockquoteDangerStyles: "cc-1c68tfx",
|
|
211
|
+
blockquoteSelectedNodeStyles: "cc-qq2e8j",
|
|
212
|
+
blocktypeStyles: "cc-1xxjz1r",
|
|
213
|
+
headingScrollMarginStyles: "cc-z7dqqd",
|
|
214
|
+
blocktypeStylesRtlBlockquote: "cc-19ii5uh",
|
|
215
|
+
blocktypeStylesNestedDnd: "cc-16jdll9",
|
|
216
|
+
blocktypeStyles_fg_platform_editor_typography_ugc: "cc-gxqvk4",
|
|
217
|
+
codeBlockStyles: "cc-onhw5q",
|
|
218
|
+
codeBlockStylesWithEmUnits: "cc-38w9d",
|
|
219
|
+
codeMarkStyles: "cc-io46ye",
|
|
220
|
+
commentEditorStyles: "cc-1x20ugq",
|
|
221
|
+
commentLessMarginStyles: "cc-x78p23",
|
|
222
|
+
nonFullPageContainerTypeStyles: "cc-1ffq68j",
|
|
223
|
+
cursorStyles: "cc-1kqi4s4",
|
|
224
|
+
dangerDateStyles: "cc-19fni7v",
|
|
225
|
+
dangerRuleStyles: "cc-1hbwjkd",
|
|
226
|
+
numberedHeadingsStyles: "cc-17afnv1",
|
|
227
|
+
ruleWithAttrsStyles: "cc-1fue38t",
|
|
228
|
+
dateStyles: "cc-i9wwcr",
|
|
229
|
+
dateVanillaStyles: "cc-1raq80e",
|
|
230
|
+
decisionDangerStyles: "cc-1okuoyi",
|
|
231
|
+
decisionIconWithVisualRefresh: "cc-pr8iob",
|
|
232
|
+
decisionStyles: "cc-1gw4qxk",
|
|
233
|
+
diffListStyles: "cc-hlzh2",
|
|
234
|
+
editorControlsSmartCardStyles: "cc-j2xa8",
|
|
235
|
+
editorGutterPaddingBaseStyles: "cc-gf5osk",
|
|
236
|
+
editorLargeGutterPuddingReducedBaseStyles: "cc-k59244",
|
|
237
|
+
editorUGCTokensRefreshed: "cc-12km4p3",
|
|
238
|
+
editorUGCSmallText: "cc-1thh13r",
|
|
239
|
+
embedCardStyles: "cc-1umnjs6",
|
|
240
|
+
emojiDangerStyles: "cc-1tx6cik",
|
|
241
|
+
emojiStyles: "cc-1sg5wny",
|
|
242
|
+
emojiSelectionStyles: "cc-1frlnkf",
|
|
243
|
+
directEmojiSelectionStyles: "cc-1mtb0gj",
|
|
244
|
+
emojiDenseStyles: "cc-6k45xx",
|
|
245
|
+
expandStyles: "cc-jk1psr",
|
|
246
|
+
expandStylesBase: "cc-1vzxkjp",
|
|
247
|
+
expandStylesMixin_chromeless_expand_fix: "cc-14yvo9k",
|
|
248
|
+
expandStylesMixinNestedDnd: "cc-1hyq18d",
|
|
249
|
+
expandStylesMixin_fg_platform_visual_refresh_icons: "cc-328s3h",
|
|
250
|
+
expandDenseStyles: "cc-hi96s7",
|
|
251
|
+
extensionStyles: "cc-zjy8wl",
|
|
252
|
+
extensionStylesDense: "cc-vpjpue",
|
|
253
|
+
extensionDiffStyles: "cc-f4rnz8",
|
|
254
|
+
bodiedExtensionLayoutShiftFix: "cc-1rpjo6c",
|
|
255
|
+
findReplaceStyles: "cc-1u77fqd",
|
|
256
|
+
findReplaceStylesWithCodeblockColorContrastFix: "cc-1xo10av",
|
|
257
|
+
findReplaceStylesWithRefSyncBlock: "cc-j2i0v3",
|
|
258
|
+
firstBlockNodeStyles: "cc-z9wm5i",
|
|
259
|
+
firstNodeWidgetFixStyles: "cc-14bt53r",
|
|
260
|
+
firstCodeBlockWithNoMargin: "cc-18fy8gw",
|
|
261
|
+
firstFloatingToolbarButtonStyles: "cc-1ywyeuh",
|
|
262
|
+
firstWrappedMediaStyles: "cc-uzohia",
|
|
263
|
+
fontSizeStyles: "cc-386pb6",
|
|
264
|
+
fullPageEditorStyles: "cc-9bbcpz",
|
|
265
|
+
gapCursorStyles: "cc-p4ijkk",
|
|
266
|
+
gapCursorStylesVisibilityFix: "cc-1quskpv",
|
|
267
|
+
gridStyles: "cc-t1y6o4",
|
|
268
|
+
hideCursorWhenHideSelectionStyles: "cc-1yeejiq",
|
|
269
|
+
scopedHideCursorStyles: "cc-1do5apg",
|
|
270
|
+
hideSelectionStyles: "cc-1ed2xg3",
|
|
271
|
+
scopedHideSelectionStyles: "cc-egv7gq",
|
|
272
|
+
hyperLinkFloatingToolbarStyles: "cc-1ce0zwe",
|
|
273
|
+
indentationStyles: "cc-a0s7uy",
|
|
274
|
+
InlineNodeViewSharedStyles: "cc-kinzob",
|
|
275
|
+
layoutBaseStyles: "cc-118fbsr",
|
|
276
|
+
layoutBaseStylesAdvanced: "cc-yplord",
|
|
277
|
+
layoutBaseStylesNestedDndExcludingBodiedSync: "cc-584hkl",
|
|
278
|
+
layoutColumnDividerStyles: "cc-f4nl1b",
|
|
279
|
+
layoutColumnDividerStylesNestedDnD: "cc-l7w95r",
|
|
280
|
+
layoutColumnMartinTopFixes: "cc-wfdvz0",
|
|
281
|
+
layoutColumnResizeStyles: "cc-ou9nw1",
|
|
282
|
+
layoutColumnResponsiveStyles: "cc-sfa3kt",
|
|
283
|
+
layoutColumnStylesAdvanced: "cc-9tb4zl",
|
|
284
|
+
layoutColumnStylesNotAdvanced: "cc-1vz6vni",
|
|
285
|
+
layoutResponsiveBaseStyles: "cc-1vkjs8l",
|
|
286
|
+
layoutResponsiveStylesForView: "cc-5ny41m",
|
|
287
|
+
layoutDragHandleWrapperStylesLegacy: "cc-163ojmv",
|
|
288
|
+
layoutDragHandleWrapperStylesTopLayer: "cc-1fs3sks",
|
|
289
|
+
layoutSectionStylesAdvanced: "cc-1gxecuo",
|
|
290
|
+
layoutSectionStylesNotAdvanced: "cc-zbal4",
|
|
291
|
+
layoutSelectedStylesAdvanced: "cc-qgxq53",
|
|
292
|
+
layoutSelectedStylesAdvancedFix: "cc-1kc2z6k",
|
|
293
|
+
layoutSelectedStylesForViewAdvanced: "cc-wkobhf",
|
|
294
|
+
layoutSelectedStylesForViewNotAdvanced: "cc-yl4xp5",
|
|
295
|
+
layoutSelectedStylesNotAdvanced: "cc-13lofsj",
|
|
296
|
+
layoutStylesForView: "cc-1m0mbsh",
|
|
297
|
+
linkingVisualRefreshV1Styles: "cc-i7yj8d",
|
|
298
|
+
linkStyles: "cc-1eicnt5",
|
|
299
|
+
listDangerStyles: "cc-j17pg5",
|
|
300
|
+
listItemHiddenMarkerStyles: "cc-4inn25",
|
|
301
|
+
listSelectedNodeStyles: "cc-1b6rlbq",
|
|
302
|
+
listSelectedNodeStylesWithHighlightInheritance: "cc-ym0hmm",
|
|
303
|
+
listsStyles: "cc-1g0x84n",
|
|
304
|
+
listsStylesMarginLayoutShiftFix: "cc-nwkbcz",
|
|
305
|
+
listsStylesSafariFix: "cc-jsgz62",
|
|
306
|
+
listsDenseStyles: "cc-15hcq93",
|
|
307
|
+
maxModeReizeFixStyles: "cc-17o8xc4",
|
|
308
|
+
mediaAlignmentStyles: "cc-12o4ob2",
|
|
309
|
+
vanillaCaptionStyles: "cc-1epilu3",
|
|
310
|
+
mediaCaptionStyles: "cc-dmm73n",
|
|
311
|
+
mediaDangerStyles: "cc-1os5yyp",
|
|
312
|
+
mediaGroupStyles: "cc-3tgtow",
|
|
313
|
+
mediaStyles: "cc-16varpz",
|
|
314
|
+
mentionDangerStyles: "cc-oprxj6",
|
|
315
|
+
mentionAvatarNoWrapStyles: "cc-vun9g0",
|
|
316
|
+
mentionNodeStyles: "cc-19p9d8a",
|
|
317
|
+
agentMentionShimmerDarkMode: "cc-56vk54",
|
|
318
|
+
mentionsSelectionStyles: "cc-18t7jqr",
|
|
319
|
+
mentionsStyles: "cc-1xnj1nx",
|
|
320
|
+
nestedPanelBorderStylesMixin: "cc-1ehgjlb",
|
|
321
|
+
nestedPanelDangerStyles: "cc-1bknfwh",
|
|
322
|
+
panelStyles: "cc-1u8xj7",
|
|
323
|
+
panelStylesMixin: "cc-u7aoes",
|
|
324
|
+
panelStylesMixinNestedDnd: "cc-ldsfx5",
|
|
325
|
+
panelViewStyles: "cc-1h42r0",
|
|
326
|
+
paragraphStylesUGCRefreshed: "cc-1sd4buw",
|
|
327
|
+
paragraphStylesWithScaledMargin: "cc-6grtr7",
|
|
328
|
+
placeholderOverflowStyles: "cc-xhwru4",
|
|
329
|
+
placeholderStyles: "cc-3o7t7l",
|
|
330
|
+
placeholderTextStyles: "cc-5f6cgr",
|
|
331
|
+
pragmaticResizerStyles: "cc-aqv28l",
|
|
332
|
+
pragmaticResizerStylesCodeBlockSyncedBlockPatch: "cc-183gdj8",
|
|
333
|
+
pragmaticResizerStylesForTooltip: "cc-r930n9",
|
|
334
|
+
pragmaticResizerStylesSyncedBlock: "cc-16ydu7e",
|
|
335
|
+
pragmaticResizerStylesWithReducedEditorGutter: "cc-17lp2hq",
|
|
336
|
+
pragmaticResizerStylesPanelAndRule: "cc-1p753u3",
|
|
337
|
+
pragmaticResizerStylesPanelAndRuleJsdomFix: "cc-1wvct5b",
|
|
338
|
+
pragmaticResizerStylesExtensions: "cc-u7ux2b",
|
|
339
|
+
pragmaticResizerStylesHiddenForPanelAndRule: "cc-1pgajmv",
|
|
340
|
+
pragmaticResizerStylesHiddenForExtensions: "cc-edozq8",
|
|
341
|
+
pragmaticStylesLayoutFirstNodeResizeHandleFix: "cc-p7ejh0",
|
|
342
|
+
resizerStyles: "cc-o9mp90",
|
|
343
|
+
resizerBottomHandleStyles: "cc-wxw76a",
|
|
344
|
+
ruleStyles: "cc-wdpa1s",
|
|
345
|
+
scaledEmojiStyles: "cc-1fxvudr",
|
|
346
|
+
scaledEmojiDenseStyles: "cc-cxmncl",
|
|
347
|
+
scrollbarStyles: "cc-xy2nze",
|
|
348
|
+
selectedNodeStyles: "cc-e5rny1",
|
|
349
|
+
selectionToolbarAnimationStyles: "cc-6xcn74",
|
|
350
|
+
shadowStyles: "cc-64nyub",
|
|
351
|
+
extensionScrollInlineShadowStyles: "cc-2w3l0t",
|
|
352
|
+
showDiffDeletedNodeStyles: "cc-1orohbk",
|
|
353
|
+
smartCardDiffStyles: "cc-1kwmdli",
|
|
354
|
+
smartCardStylesWithSearchMatch: "cc-1vj8t5e",
|
|
355
|
+
smartCardStylesWithSearchMatchAndBlockMenuDangerStyles: "cc-1ta13nz",
|
|
356
|
+
smartCardStylesWithSearchMatchAndPreviewPanelResponsiveness: "cc-1sh1jof",
|
|
357
|
+
smartLinksInLivePagesStyles: "cc-a5baya",
|
|
358
|
+
syncBlockFirstNodeStyles: "cc-wu1lx6",
|
|
359
|
+
syncBlockTextSelectionStyles: "cc-16ilyoh",
|
|
360
|
+
syncBlockInteractiveCursorStyles: "cc-1sxl2kn",
|
|
361
|
+
syncBlockOverflowStyles: "cc-g40y0r",
|
|
362
|
+
syncBlockStyles: "cc-14ke5o9",
|
|
363
|
+
syncBlockSelectedStyles: "cc-16lkx6o",
|
|
364
|
+
syncBlockStylesBase: "cc-xyxj0q",
|
|
365
|
+
tableCellBackgroundColorOverrides: "cc-18reawy",
|
|
366
|
+
tableCommentEditorStyles: "cc-hwyox5",
|
|
367
|
+
tableContainerStyles: "cc-lqz7ou",
|
|
368
|
+
tableScrollInlineShadowStyles: "cc-xmz7ep",
|
|
369
|
+
tableContentModeStyles: "cc-5x9ixh",
|
|
370
|
+
tableContentModeExtensionContainmentStyles: "cc-3zjodb",
|
|
371
|
+
tableContentModeNestedTableStyles: "cc-12578pj",
|
|
372
|
+
tableEmptyRowStyles: "cc-12r5qnh",
|
|
373
|
+
tableRoundedCornerStyles: "cc-3reuz7",
|
|
374
|
+
tableLayoutFixes: "cc-cf7rbr",
|
|
375
|
+
tableLayoutFixesWithFontSize: "cc-148rcw3",
|
|
376
|
+
tableSharedStyle: "cc-1cz9bvl",
|
|
377
|
+
tableSharedStyleBackgroundClipFix: "cc-1m6fxly",
|
|
378
|
+
tableSharedStyle_with_platform_editor_table_q4_loveability: "cc-xxtdve",
|
|
379
|
+
tableSharedStyle_without_platform_editor_table_q4_loveability: "cc-cz1xtf",
|
|
380
|
+
tableSharedStyle_with_platform_editor_table_menu_updates: "cc-1hsc0qn",
|
|
381
|
+
tableSharedStyle_with_platform_editor_bordered_panel_nested_in_table: "cc-9lpwkq",
|
|
382
|
+
taskItemCheckboxStyles: "cc-g8lqnf",
|
|
383
|
+
taskItemStylesWithBlockTaskItem: "cc-13wkzuf",
|
|
384
|
+
tasksAndDecisionsStyles: "cc-sqk75n",
|
|
385
|
+
tasksAndDecisionsDenseStyles: "cc-47ytxy",
|
|
386
|
+
statusDangerStyles: "cc-106ojo7",
|
|
387
|
+
statusStyles: "cc-1e7cxsr",
|
|
388
|
+
statusStylesMixin_fg_platform_component_visual_refresh_with_search_match: "cc-1p8tqx8",
|
|
389
|
+
statusStylesMixin_without_fg_platform_component_visual_refresh_with_search_match: "cc-1mganf6",
|
|
390
|
+
deletedStatusStrikeStyles: "cc-cqg0se",
|
|
391
|
+
atomicInlineChangedBoxShadowStyles: "cc-1e2dh7c",
|
|
392
|
+
statusStylesTeam26: "cc-jh0xlu",
|
|
393
|
+
statusStylesTeam26TextTrim: "cc-13wc50u",
|
|
394
|
+
statusStylesNamedSemantic: "cc-cvvssp",
|
|
395
|
+
statusStylesNamedAccent: "cc-184gmx3",
|
|
396
|
+
statusStylesHexAccent: "cc-1o240ig",
|
|
397
|
+
telepointerColorAndCommonStyle: "cc-yfngnq",
|
|
398
|
+
telepointerColorAndCommonStyleDarkMode: "cc-18r3qk1",
|
|
399
|
+
agentShimmerStyles: "cc-14zsh1y",
|
|
400
|
+
telepointerStyle: "cc-1ahvzgh",
|
|
401
|
+
textColorStyles: "cc-1trmq1d",
|
|
402
|
+
textDangerStyles: "cc-4n0yol",
|
|
403
|
+
textHighlightPaddingStyles: "cc-4yp2y0",
|
|
404
|
+
textHighlightStyle: "cc-gz6zd4",
|
|
405
|
+
textSelectedNodeStyles: "cc-1ti81ko",
|
|
406
|
+
textSelectedNodeStylesWithHighlightInheritance: "cc-1hsyavw",
|
|
407
|
+
unsupportedStyles: "cc-1u0ji6b",
|
|
408
|
+
vanillaTooltipDefaultStyles: "cc-10jqrnu",
|
|
409
|
+
contributorTagStyles: "cc-15skd4v",
|
|
410
|
+
vanillaUnsupportedStyles: "cc-cwmdaa",
|
|
411
|
+
whitespaceStyles: "cc-1nqdq6u"
|
|
412
|
+
};
|
|
413
|
+
const isFirefox = typeof navigator !== 'undefined' && navigator.userAgent.toLowerCase().indexOf('firefox') > -1;
|
|
3
414
|
/**
|
|
4
|
-
*
|
|
5
|
-
*
|
|
415
|
+
* EditorContentStyles is a wrapper component that applies styles to its children
|
|
416
|
+
* based on the provided feature flags, view mode, and other props.
|
|
417
|
+
* It uses Compiled for styling and supports scrollable content.
|
|
418
|
+
*
|
|
419
|
+
* This will be used in near future to replace the current editor content styles from index.tsx
|
|
6
420
|
*/
|
|
7
|
-
const EditorContentContainer =
|
|
421
|
+
const EditorContentContainer = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
422
|
+
const {
|
|
423
|
+
className,
|
|
424
|
+
children,
|
|
425
|
+
viewMode,
|
|
426
|
+
isScrollable,
|
|
427
|
+
appearance,
|
|
428
|
+
contentMode,
|
|
429
|
+
useStandardNodeWidth
|
|
430
|
+
} = props;
|
|
431
|
+
const {
|
|
432
|
+
colorMode
|
|
433
|
+
} = useThemeObserver();
|
|
434
|
+
const isFullPage = appearance === 'full-page' || appearance === 'full-width' || appearance === 'max';
|
|
435
|
+
const isComment = appearance === 'comment';
|
|
436
|
+
const isChromeless = appearance === 'chromeless';
|
|
437
|
+
const baseFontSize = getBaseFontSize(appearance, contentMode);
|
|
438
|
+
const isDense = !!baseFontSize && baseFontSize !== akEditorFullPageDefaultFontSize;
|
|
439
|
+
const tableOverflowShadow = overflowShadow({
|
|
440
|
+
leftCoverWidth: "var(--ds-space-300, 24px)"
|
|
441
|
+
});
|
|
442
|
+
|
|
443
|
+
// Under the static-CSS experiment, --ak-editor-base-font-size is set earlier on the
|
|
444
|
+
// root div in editor-internal.tsx and inherited via the CSS cascade — do not set it here.
|
|
445
|
+
// For the legacy font-size path, derive it from the editor theme.
|
|
446
|
+
const style = React.useMemo(() => ({
|
|
447
|
+
'--ak-editor--table-overflow-shadow': tableOverflowShadow,
|
|
448
|
+
...tableCellBackgroundColorVariables,
|
|
449
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
450
|
+
...(!editorExperiment('platform_editor_preview_panel_responsiveness', true, {
|
|
451
|
+
exposure: true
|
|
452
|
+
}) && {
|
|
453
|
+
'--ak-editor--large-gutter-padding': `${akEditorGutterPaddingDynamic()}px`
|
|
454
|
+
})
|
|
455
|
+
}), [tableOverflowShadow]);
|
|
456
|
+
const browser = getBrowserInfo();
|
|
457
|
+
const isImproveInpEnabled = isExperimentEnabled('platform_editor_improve_inp');
|
|
458
|
+
// Highlight inheritance shipped in Chromium 134. Keep explicit descendant rules for
|
|
459
|
+
// other engines and older versions; supporting ::selection alone is not sufficient.
|
|
460
|
+
const isSelectionHighlightInheritanceActive = browser.chrome_version >= 134 && isImproveInpEnabled;
|
|
461
|
+
const isFloatingTocEnabled = isExperimentEnabled('platform_editor_floating_toc');
|
|
462
|
+
const isUpdateStatusColorsEnabled = UNSAFE_expValNoExposure('platform_editor_update_status_colors', 'isEnabled', false) || UNSAFE_expValNoExposure('platform_editor_update_status_colors_jira', 'isEnabled', false);
|
|
463
|
+
const isStatusStylesTeam26 = fg('platform-dst-lozenge-tag-badge-visual-uplifts');
|
|
464
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
465
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
466
|
+
className: ax([editorContentStyles.baseStyles, editorContentStyles.maxModeReizeFixStyles, editorContentStyles.baseStylesMaxContainerWidthFixes, editorContentStyles.editorGutterPaddingBaseStyles, editorExperiment('platform_editor_preview_panel_responsiveness', true, {
|
|
467
|
+
exposure: true
|
|
468
|
+
}) && editorContentStyles.editorLargeGutterPuddingReducedBaseStyles, editorContentStyles.whitespaceStyles, editorContentStyles.indentationStyles, editorContentStyles.fontSizeStyles, editorContentStyles.shadowStyles, isExperimentEnabled('platform_editor_reduce_forced_layout_2') && editorContentStyles.extensionScrollInlineShadowStyles, editorContentStyles.InlineNodeViewSharedStyles, isImproveInpEnabled ? editorContentStyles.scopedHideSelectionStyles : editorContentStyles.hideSelectionStyles, isImproveInpEnabled ? editorContentStyles.scopedHideCursorStyles : editorContentStyles.hideCursorWhenHideSelectionStyles, editorContentStyles.selectedNodeStyles, editorContentStyles.cursorStyles, editorContentStyles.firstFloatingToolbarButtonStyles, editorContentStyles.placeholderTextStyles, editorContentStyles.placeholderStyles, editorExperiment('platform_editor_controls', 'variant1') && editorContentStyles.placeholderOverflowStyles, editorContentStyles.codeBlockStyles, contentMode === 'compact' && editorContentStyles.codeBlockStylesWithEmUnits, editorContentStyles.editorUGCTokensRefreshed, editorContentStyles.editorUGCSmallText, editorContentStyles.blocktypeStyles, editorContentStyles.blocktypeStylesRtlBlockquote, isFloatingTocEnabled && editorContentStyles.headingScrollMarginStyles, editorContentStyles.blockquoteSelectedNodeStyles, isSelectionHighlightInheritanceActive ? editorContentStyles.listSelectedNodeStylesWithHighlightInheritance : editorContentStyles.listSelectedNodeStyles, isSelectionHighlightInheritanceActive ? editorContentStyles.textSelectedNodeStylesWithHighlightInheritance : editorContentStyles.textSelectedNodeStyles, editorContentStyles.blocktypeStyles_fg_platform_editor_typography_ugc, editorContentStyles.blocktypeStylesNestedDnd, editorContentStyles.codeMarkStyles, editorContentStyles.textColorStyles, editorContentStyles.backgroundColorStyles, !expValEquals('platform_editor_lovability_text_bg_color', 'isEnabled', true) && editorContentStyles.highlightLinksUnsetStyles, editorContentStyles.textHighlightPaddingStyles, editorContentStyles.listsStyles, editorContentStyles.listItemHiddenMarkerStyles, editorContentStyles.diffListStyles, contentMode === 'compact' && isDense && editorContentStyles.listsDenseStyles, isFullPage && editorContentStyles.listsStylesMarginLayoutShiftFix, editorContentStyles.ruleStyles, isExperimentEnabled('platform_editor_lovability_dividers_attributes') && editorContentStyles.ruleWithAttrsStyles, isExperimentEnabled('platform_editor_numbered_headings') && editorContentStyles.numberedHeadingsStyles, editorContentStyles.smartCardDiffStyles, editorContentStyles.showDiffDeletedNodeStyles, editorContentStyles.mediaStyles, isExperimentEnabled('platform_editor_vanilla_node_views_phase1') && editorContentStyles.vanillaCaptionStyles, contentMode === 'compact' && editorContentStyles.mediaCaptionStyles, editorContentStyles.firstWrappedMediaStyles, editorContentStyles.telepointerStyle, /* This needs to be after telepointer styles as some overlapping rules have equal specificity, and so the order is significant */
|
|
469
|
+
editorContentStyles.telepointerColorAndCommonStyle, colorMode === 'dark' && editorContentStyles.telepointerColorAndCommonStyleDarkMode, expValEqualsNoExposure('platform_editor_agent_be_streaming', 'isEnabled', true) && editorContentStyles.agentShimmerStyles, editorContentStyles.gapCursorStyles, editorContentStyles.gapCursorStylesVisibilityFix, editorContentStyles.panelStyles, editorContentStyles.nestedPanelBorderStylesMixin, editorContentStyles.panelStylesMixinNestedDnd, editorContentStyles.panelStylesMixin, editorContentStyles.mentionsStyles, editorContentStyles.tasksAndDecisionsStyles, contentMode === 'compact' && isDense && editorContentStyles.tasksAndDecisionsDenseStyles, editorContentStyles.gridStyles, editorContentStyles.blockMarksStyles, editorContentStyles.dateStyles, editorContentStyles.extensionStyles, fg('platform_editor_lovability_resize_exts_gracefully') && editorContentStyles.extensionWithBreakoutStyles, contentMode === 'compact' && editorContentStyles.extensionStylesDense, editorContentStyles.bodiedExtensionLayoutShiftFix, editorContentStyles.extensionDiffStyles, editorContentStyles.expandStylesBase, !useStandardNodeWidth && editorContentStyles.expandStyles, contentMode === 'compact' && isDense && editorContentStyles.expandDenseStyles, editorContentStyles.expandStylesMixinNestedDnd, editorContentStyles.expandStylesMixin_fg_platform_visual_refresh_icons, isChromeless && editorContentStyles.expandStylesMixin_chromeless_expand_fix, editorContentStyles.findReplaceStyles, editorContentStyles.findReplaceStylesWithCodeblockColorContrastFix, editorContentStyles.findReplaceStylesWithRefSyncBlock, editorContentStyles.textHighlightStyle, editorContentStyles.decisionStyles, editorContentStyles.taskItemStylesWithBlockTaskItem, editorContentStyles.taskItemCheckboxStyles, editorContentStyles.decisionIconWithVisualRefresh, editorContentStyles.statusStyles, isStatusStylesTeam26 ? editorContentStyles.statusStylesTeam26 : fg('platform-component-visual-refresh') ? editorContentStyles.statusStylesMixin_fg_platform_component_visual_refresh_with_search_match : editorContentStyles.statusStylesMixin_without_fg_platform_component_visual_refresh_with_search_match, isStatusStylesTeam26 && isExperimentEnabled('platform_status_lozenge_fractional_zoom_fix') && editorContentStyles.statusStylesTeam26TextTrim, isStatusStylesTeam26 && isUpdateStatusColorsEnabled && editorContentStyles.statusStylesNamedAccent, isStatusStylesTeam26 && !isUpdateStatusColorsEnabled && editorContentStyles.statusStylesNamedSemantic, editorContentStyles.statusStylesHexAccent, fg('platform_editor_ai_show_diff_patch_2') && editorContentStyles.deletedStatusStrikeStyles, editorContentStyles.annotationStyles, editorContentStyles.smartCardStylesWithSearchMatchAndBlockMenuDangerStyles, editorExperiment('platform_editor_preview_panel_responsiveness', true) && editorContentStyles.smartCardStylesWithSearchMatchAndPreviewPanelResponsiveness, editorContentStyles.editorControlsSmartCardStyles, editorContentStyles.embedCardStyles, editorContentStyles.unsupportedStyles, editorContentStyles.vanillaTooltipDefaultStyles, fg('confluence_ncs_step_diffing_version_history') && editorContentStyles.contributorTagStyles, isExperimentEnabled('platform_editor_vanilla_node_views_phase1') && editorContentStyles.vanillaUnsupportedStyles, editorContentStyles.resizerStyles, expValEqualsNoExposure('cc-maui-experiment', 'isEnabled', true) && expValEquals('databases-native-embeds-v2', 'isEnabled', true) && editorContentStyles.resizerBottomHandleStyles, editorContentStyles.layoutBaseStyles, editorContentStyles.alignMultipleWrappedImageInLayoutStyles, editorContentStyles.syncBlockStylesBase, fg('platform-dst-tokens-finesse') && editorContentStyles.syncBlockSelectedStyles, !useStandardNodeWidth && editorContentStyles.syncBlockStyles, editorContentStyles.syncBlockOverflowStyles, editorContentStyles.syncBlockFirstNodeStyles, editorContentStyles.syncBlockTextSelectionStyles, editorContentStyles.syncBlockInteractiveCursorStyles, editorExperiment('advanced_layouts', true) && editorContentStyles.layoutBaseStylesAdvanced, editorExperiment('advanced_layouts', true) ? editorContentStyles.layoutSectionStylesAdvanced : editorContentStyles.layoutSectionStylesNotAdvanced, editorExperiment('advanced_layouts', true) && !fg('platform-dst-top-layer-tooltip') && editorContentStyles.layoutDragHandleWrapperStylesLegacy, editorExperiment('advanced_layouts', true) && fg('platform-dst-top-layer-tooltip') && editorContentStyles.layoutDragHandleWrapperStylesTopLayer, editorExperiment('advanced_layouts', true) && editorContentStyles.layoutColumnDividerStyles, editorExperiment('advanced_layouts', true) && editorContentStyles.layoutColumnDividerStylesNestedDnD, editorExperiment('advanced_layouts', true) ? editorContentStyles.layoutColumnStylesAdvanced : editorContentStyles.layoutColumnStylesNotAdvanced, editorExperiment('advanced_layouts', true) && editorContentStyles.layoutColumnResizeStyles, editorExperiment('advanced_layouts', true) ? editorContentStyles.layoutSelectedStylesAdvanced : editorContentStyles.layoutSelectedStylesNotAdvanced, editorContentStyles.layoutSelectedStylesAdvancedFix, editorExperiment('advanced_layouts', true) && editorContentStyles.layoutColumnResponsiveStyles, editorExperiment('advanced_layouts', true) && editorContentStyles.layoutResponsiveBaseStyles, editorContentStyles.layoutBaseStylesNestedDndExcludingBodiedSync, editorContentStyles.layoutColumnMartinTopFixes, editorContentStyles.smartLinksInLivePagesStyles, editorContentStyles.linkingVisualRefreshV1Styles, editorContentStyles.dateVanillaStyles, contentMode === 'compact' ? editorContentStyles.paragraphStylesWithScaledMargin : editorContentStyles.paragraphStylesUGCRefreshed, editorContentStyles.linkStyles, browser.safari && editorContentStyles.listsStylesSafariFix, editorContentStyles.pragmaticResizerStylesSyncedBlock, editorContentStyles.pragmaticResizerStyles, expValEqualsNoExposure('platform_editor_lovability_resize_dividers_panels', 'isEnabled', true) && isExperimentEnabled('platform_editor_resizer_selector_jsdom_fix') && editorContentStyles.pragmaticResizerStylesPanelAndRuleJsdomFix, expValEqualsNoExposure('platform_editor_lovability_resize_dividers_panels', 'isEnabled', true) && !isExperimentEnabled('platform_editor_resizer_selector_jsdom_fix') && editorContentStyles.pragmaticResizerStylesPanelAndRule, isExperimentEnabled('platform_editor_lovability_resize_extensions') && editorContentStyles.pragmaticResizerStylesExtensions, editorContentStyles.pragmaticResizerStylesCodeBlockSyncedBlockPatch, isExperimentEnabled('platform_editor_reduce_forced_layout') && !expValEqualsNoExposure('platform_editor_lovability_resize_dividers_panels', 'isEnabled', true) && editorContentStyles.pragmaticResizerStylesHiddenForPanelAndRule, isExperimentEnabled('platform_editor_reduce_forced_layout') && !isExperimentEnabled('platform_editor_lovability_resize_extensions') && editorContentStyles.pragmaticResizerStylesHiddenForExtensions, editorExperiment('advanced_layouts', true) && editorContentStyles.pragmaticStylesLayoutFirstNodeResizeHandleFix, editorContentStyles.pragmaticResizerStylesForTooltip, editorExperiment('platform_editor_preview_panel_responsiveness', true) && editorContentStyles.pragmaticResizerStylesWithReducedEditorGutter, editorContentStyles.aiPanelBaseStyles, isFirefox && editorContentStyles.aiPanelBaseFirefoxStyles, colorMode === 'dark' && editorContentStyles.aiPanelDarkStyles, colorMode === 'dark' && isFirefox && editorContentStyles.aiPanelDarkFirefoxStyles, viewMode === 'view' && editorContentStyles.layoutStylesForView, viewMode === 'view' && editorExperiment('advanced_layouts', true) && editorContentStyles.layoutSelectedStylesForViewAdvanced, viewMode === 'view' && editorExperiment('advanced_layouts', false) && editorContentStyles.layoutSelectedStylesForViewNotAdvanced, viewMode === 'view' && editorExperiment('advanced_layouts', true) && editorContentStyles.layoutResponsiveStylesForView, isComment && editorContentStyles.commentEditorStyles, isComment && editorContentStyles.tableCommentEditorStyles, (isComment || isChromeless) && editorContentStyles.nonFullPageContainerTypeStyles, isComment && (fg('platform_editor_comment_margin_cq') || isExperimentEnabled('work_item_modernization')) && editorContentStyles.commentLessMarginStyles, isFullPage && editorContentStyles.fullPageEditorStyles, isFullPage && editorContentStyles.scrollbarStyles, editorContentStyles.firstCodeBlockWithNoMargin, editorContentStyles.firstBlockNodeStyles, editorContentStyles.firstNodeWidgetFixStyles, editorContentStyles.mentionNodeStyles, isExperimentEnabled('platform_editor_mention_avatar_nowrap') && editorContentStyles.mentionAvatarNoWrapStyles, colorMode === 'dark' && editorContentStyles.agentMentionShimmerDarkMode, editorContentStyles.mentionsSelectionStyles, expValEquals('platform_editor_lovability_emoji_scaling', 'isEnabled', true) ? editorContentStyles.scaledEmojiStyles : editorContentStyles.emojiStyles, isFloatingTocEnabled ? editorContentStyles.directEmojiSelectionStyles : editorContentStyles.emojiSelectionStyles, contentMode === 'compact' && isDense && expValEquals('platform_editor_lovability_emoji_scaling', 'isEnabled', true) && editorContentStyles.scaledEmojiDenseStyles, contentMode === 'compact' && isDense && !expValEquals('platform_editor_lovability_emoji_scaling', 'isEnabled', true) && editorContentStyles.emojiDenseStyles, editorContentStyles.panelViewStyles, editorContentStyles.mediaGroupStyles, editorContentStyles.mediaAlignmentStyles, editorContentStyles.tableLayoutFixesWithFontSize, editorContentStyles.tableContainerStyles, editorContentStyles.tableSharedStyle, isExperimentEnabled('platform_editor_table_css_overflow_shadow') && editorContentStyles.tableScrollInlineShadowStyles, (browser.gecko || browser.ie || browser.mac && browser.chrome) && editorContentStyles.tableSharedStyleBackgroundClipFix, expValEquals('platform_editor_table_q4_loveability', 'isEnabled', true) ? editorContentStyles.tableSharedStyle_with_platform_editor_table_q4_loveability : editorContentStyles.tableSharedStyle_without_platform_editor_table_q4_loveability, expValEquals('platform_editor_table_menu_updates', 'isEnabled', true) && editorContentStyles.tableSharedStyle_with_platform_editor_table_menu_updates, fg('platform_editor_bordered_panel_nested_in_table') && editorContentStyles.tableSharedStyle_with_platform_editor_bordered_panel_nested_in_table, editorContentStyles.tableEmptyRowStyles, expValEquals('platform_editor_table_q4_loveability', 'isEnabled', true) && editorContentStyles.tableRoundedCornerStyles, editorContentStyles.tableContentModeStyles, editorContentStyles.tableContentModeExtensionContainmentStyles, editorContentStyles.tableContentModeNestedTableStyles, editorContentStyles.tableCellBackgroundColorOverrides, editorContentStyles.hyperLinkFloatingToolbarStyles, editorContentStyles.selectionToolbarAnimationStyles, editorContentStyles.blockquoteDangerStyles, editorContentStyles.textDangerStyles, editorContentStyles.listDangerStyles, editorContentStyles.dangerDateStyles, editorContentStyles.emojiDangerStyles, editorContentStyles.mentionDangerStyles, editorContentStyles.decisionDangerStyles, editorContentStyles.statusDangerStyles, fg('platform_editor_ai_show_diff_patch_2') && editorContentStyles.atomicInlineChangedBoxShadowStyles, editorContentStyles.dangerRuleStyles, editorContentStyles.mediaDangerStyles, editorContentStyles.nestedPanelDangerStyles, className || undefined]),
|
|
470
|
+
ref: ref,
|
|
471
|
+
"data-editor-scroll-container": isScrollable ? 'true' : undefined,
|
|
472
|
+
"data-testid": "editor-content-container"
|
|
473
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop
|
|
474
|
+
,
|
|
475
|
+
style: style,
|
|
476
|
+
tabIndex: isScrollable ? 0 : undefined,
|
|
477
|
+
role: isScrollable ? 'region' : undefined
|
|
478
|
+
}, children);
|
|
479
|
+
});
|
|
8
480
|
export default EditorContentContainer;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
/* PluginSlot
|
|
1
|
+
/* PluginSlot.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
|
-
import "./PluginSlot
|
|
3
|
+
import "./PluginSlot.compiled.css";
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
import { ax, ix } from "@compiled/react/runtime";
|
|
6
6
|
const pluginsComponentsWrapperCompiledStyles = {
|
|
7
7
|
root: "_1e0c1txw"
|
|
8
8
|
};
|
|
9
|
-
export const
|
|
9
|
+
export const PluginsComponentsWrapper = ({
|
|
10
10
|
children,
|
|
11
11
|
...rest
|
|
12
12
|
}) => /*#__PURE__*/React.createElement("div", _extends({}, rest, {
|
|
@@ -4,7 +4,7 @@ import { ACTION_SUBJECT } from '@atlaskit/editor-common/analytics/types/enums';
|
|
|
4
4
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
5
5
|
import { ErrorBoundary } from '../ErrorBoundary';
|
|
6
6
|
import { MountPluginHooks } from './mount-plugin-hooks';
|
|
7
|
-
import {
|
|
7
|
+
import { PluginsComponentsWrapper } from './PluginSlot';
|
|
8
8
|
const PluginComponent = ({
|
|
9
9
|
component,
|
|
10
10
|
editorView,
|
|
@@ -65,7 +65,7 @@ const PluginSlot = ({
|
|
|
65
65
|
pluginHooks: pluginHooks,
|
|
66
66
|
containerElement: containerElement,
|
|
67
67
|
wrapperElement: wrapperElement
|
|
68
|
-
}), /*#__PURE__*/React.createElement(
|
|
68
|
+
}), /*#__PURE__*/React.createElement(PluginsComponentsWrapper, {
|
|
69
69
|
"data-testid": "plugins-components-wrapper"
|
|
70
70
|
}, items === null || items === void 0 ? void 0 : items.map((component, index) => {
|
|
71
71
|
if (isolatePluginSlotFailures) {
|
package/dist/es2019/ui/Toolbar/{ToolbarComponentsWrapper-compiled.js → ToolbarComponentsWrapper.js}
RENAMED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
/* ToolbarComponentsWrapper
|
|
2
|
-
import "./ToolbarComponentsWrapper
|
|
1
|
+
/* ToolbarComponentsWrapper.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
|
+
import "./ToolbarComponentsWrapper.compiled.css";
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
5
5
|
const toolbarComponentsWrapperCompiledStyles = {
|
|
6
6
|
root: "_1e0c1txw _1hm21yb4"
|
|
7
7
|
};
|
|
8
|
-
export const
|
|
8
|
+
export const ToolbarComponentsWrapper = ({
|
|
9
9
|
children,
|
|
10
10
|
'data-vc': dataVc
|
|
11
11
|
}) => /*#__PURE__*/React.createElement("div", {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import isEqual from 'lodash/isEqual';
|
|
3
3
|
import { isSSR } from '@atlaskit/editor-common/is-ssr';
|
|
4
|
-
import {
|
|
4
|
+
import { ToolbarComponentsWrapper } from './ToolbarComponentsWrapper';
|
|
5
5
|
|
|
6
6
|
// Ignored via go/ees005
|
|
7
7
|
// eslint-disable-next-line @repo/internal/react/no-class-components
|
|
@@ -34,7 +34,7 @@ export class ToolbarInner extends React.Component {
|
|
|
34
34
|
// Hiding toolbar in SSR until the dependency of screen width is resolved in SSR environment.
|
|
35
35
|
return null;
|
|
36
36
|
}
|
|
37
|
-
return /*#__PURE__*/React.createElement(
|
|
37
|
+
return /*#__PURE__*/React.createElement(ToolbarComponentsWrapper, {
|
|
38
38
|
"data-vc": "toolbar-inner"
|
|
39
39
|
}, items.map((component, key) => {
|
|
40
40
|
const element = component({
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
/* ToolbarSizeDetectorWrapper
|
|
2
|
-
import "./ToolbarSizeDetectorWrapper
|
|
1
|
+
/* ToolbarSizeDetectorWrapper.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
|
+
import "./ToolbarSizeDetectorWrapper.compiled.css";
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
5
5
|
const toolbarSizeDetectorWrapperCompiledStyles = {
|
|
6
6
|
root: "_1bsb1osq _kqswh2mm"
|
|
7
7
|
};
|
|
8
|
-
export const
|
|
8
|
+
export const ToolbarSizeDetectorWrapper = ({
|
|
9
9
|
children,
|
|
10
10
|
style
|
|
11
11
|
}) => /*#__PURE__*/React.createElement("div", {
|
|
@@ -7,7 +7,7 @@ import { isFullPage } from '../../utils/is-full-page';
|
|
|
7
7
|
import { useElementWidth } from './hooks';
|
|
8
8
|
import { Toolbar } from './Toolbar';
|
|
9
9
|
import { toolbarSizeToWidth, widthToToolbarSize } from './toolbar-size';
|
|
10
|
-
import {
|
|
10
|
+
import { ToolbarSizeDetectorWrapper } from './ToolbarSizeDetectorWrapper';
|
|
11
11
|
export const ToolbarWithSizeDetector = props => {
|
|
12
12
|
const ref = React.useRef(null);
|
|
13
13
|
const [width, setWidth] = React.useState(undefined);
|
|
@@ -33,7 +33,7 @@ export const ToolbarWithSizeDetector = props => {
|
|
|
33
33
|
const wrapperStyle = useMemo(() => ({
|
|
34
34
|
minWidth: minWidthValue
|
|
35
35
|
}), [minWidthValue]);
|
|
36
|
-
return /*#__PURE__*/React.createElement(
|
|
36
|
+
return /*#__PURE__*/React.createElement(ToolbarSizeDetectorWrapper
|
|
37
37
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- minWidth is computed dynamically from props.hasMinWidth, props.appearance, props.twoLineEditorToolbar, and the platform_editor_preview_panel_responsiveness experiment, so it cannot be expressed as a static css value.
|
|
38
38
|
, {
|
|
39
39
|
style: wrapperStyle
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import {
|
|
2
|
-
const WithFlash =
|
|
1
|
+
import { WithFlash as WithFlashComponent } from './withFlash';
|
|
2
|
+
const WithFlash = WithFlashComponent;
|
|
3
3
|
export default WithFlash;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
/* withFlash
|
|
1
|
+
/* withFlash.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
|
-
import "./withFlash
|
|
3
|
+
import "./withFlash.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
5
5
|
import React from 'react';
|
|
6
6
|
const pulseBackground = null;
|
|
@@ -11,7 +11,7 @@ const compiledStyles = {
|
|
|
11
11
|
};
|
|
12
12
|
// Ignored via go/ees005
|
|
13
13
|
// eslint-disable-next-line @repo/internal/react/no-class-components
|
|
14
|
-
export class
|
|
14
|
+
export class WithFlash extends React.Component {
|
|
15
15
|
constructor(...args) {
|
|
16
16
|
super(...args);
|
|
17
17
|
_defineProperty(this, "toggle", false);
|