@atlaskit/editor-core 207.0.4 → 207.0.6
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/core-editor.js +9 -2
- package/dist/cjs/ui/Appearance/Chromeless.js +1 -1
- package/dist/cjs/ui/Appearance/Comment/Comment.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/FullPageContentArea.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/StyledComponents.js +2 -1
- package/dist/cjs/ui/ContentStyles/layout.js +2 -1
- package/dist/cjs/ui/{EditorContentContainer.js → EditorContentContainer/EditorContentContainer.js} +10 -10
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/composable-editor/core-editor.js +9 -2
- package/dist/es2019/ui/Appearance/Chromeless.js +1 -1
- package/dist/es2019/ui/Appearance/Comment/Comment.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/FullPageContentArea.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/StyledComponents.js +2 -1
- package/dist/es2019/ui/ContentStyles/layout.js +2 -1
- package/dist/es2019/ui/{EditorContentContainer.js → EditorContentContainer/EditorContentContainer.js} +61 -14
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/composable-editor/core-editor.js +9 -2
- package/dist/esm/ui/Appearance/Chromeless.js +1 -1
- package/dist/esm/ui/Appearance/Comment/Comment.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/FullPageContentArea.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/StyledComponents.js +2 -1
- package/dist/esm/ui/ContentStyles/layout.js +2 -1
- package/dist/esm/ui/{EditorContentContainer.js → EditorContentContainer/EditorContentContainer.js} +10 -10
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/composable-editor/core-editor.d.ts +5 -0
- package/dist/types/create-editor/create-universal-preset.d.ts +12 -1
- package/dist/types/presets/universal.d.ts +12 -1
- package/dist/types/presets/useUniversalPreset.d.ts +12 -1
- package/dist/types-ts4.5/composable-editor/core-editor.d.ts +5 -0
- package/dist/types-ts4.5/create-editor/create-universal-preset.d.ts +13 -1
- package/dist/types-ts4.5/presets/universal.d.ts +13 -1
- package/dist/types-ts4.5/presets/useUniversalPreset.d.ts +13 -1
- package/package.json +7 -13
- package/dist/cjs/composable-editor/core-performance-metrics.js +0 -109
- package/dist/es2019/composable-editor/core-performance-metrics.js +0 -92
- package/dist/esm/composable-editor/core-performance-metrics.js +0 -101
- package/dist/types/composable-editor/core-performance-metrics.d.ts +0 -4
- package/dist/types-ts4.5/composable-editor/core-performance-metrics.d.ts +0 -4
- /package/dist/types/ui/{EditorContentContainer.d.ts → EditorContentContainer/EditorContentContainer.d.ts} +0 -0
- /package/dist/types-ts4.5/ui/{EditorContentContainer.d.ts → EditorContentContainer/EditorContentContainer.d.ts} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @atlaskit/editor-core
|
|
2
2
|
|
|
3
|
+
## 207.0.6
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#155774](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/155774)
|
|
8
|
+
[`763f7a1fe5157`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/763f7a1fe5157) -
|
|
9
|
+
[ED-27991] Clean up: platform_editor_fe--ufo-bridge
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
12
|
+
## 207.0.5
|
|
13
|
+
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- [#156533](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/156533)
|
|
17
|
+
[`4d7cbea3fea55`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/4d7cbea3fea55) -
|
|
18
|
+
[ux] ED-28033: Fixed layout not in the centre of resize container
|
|
19
|
+
- Updated dependencies
|
|
20
|
+
|
|
3
21
|
## 207.0.4
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
|
@@ -24,7 +24,6 @@ var _EditorContext = require("../ui/EditorContext");
|
|
|
24
24
|
var _featureFlagsFromProps = require("../utils/feature-flags-from-props");
|
|
25
25
|
var _measureEnum = _interopRequireDefault(require("../utils/performance/measure-enum"));
|
|
26
26
|
var _versionWrapper = require("../version-wrapper");
|
|
27
|
-
var _corePerformanceMetrics = require("./core-performance-metrics");
|
|
28
27
|
var _editorInpMetrics = require("./editor-inp-metrics");
|
|
29
28
|
var _editorInternal = require("./editor-internal");
|
|
30
29
|
var _useMeasureEditorMountTime = _interopRequireDefault(require("./hooks/useMeasureEditorMountTime"));
|
|
@@ -40,6 +39,8 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
40
39
|
// eslint-disable-next-line import/no-named-as-default
|
|
41
40
|
/**
|
|
42
41
|
* Editor wrapper that deals with the lifecycle logic of the editor
|
|
42
|
+
* @param passedProps
|
|
43
|
+
* @example
|
|
43
44
|
*/
|
|
44
45
|
function Editor(passedProps) {
|
|
45
46
|
var propsRef = (0, _react.useRef)(passedProps);
|
|
@@ -94,7 +95,7 @@ function Editor(passedProps) {
|
|
|
94
95
|
}
|
|
95
96
|
}, [onSaveFromProps]);
|
|
96
97
|
var isFullPageApperance = Boolean(props.appearance && ['full-page', 'full-width'].includes(props.appearance));
|
|
97
|
-
return (0, _react2.jsx)(_react.Fragment, null, isFullPageApperance && (0, _platformFeatureFlags.fg)('platform_editor_fe--
|
|
98
|
+
return (0, _react2.jsx)(_react.Fragment, null, isFullPageApperance && (0, _platformFeatureFlags.fg)('platform_editor_fe--inp-metrics') ? (0, _react2.jsx)(_editorInpMetrics.EditorINPMetrics, null) : null, (0, _react2.jsx)(_editorInternal.EditorInternal, {
|
|
98
99
|
props: props,
|
|
99
100
|
handleAnalyticsEvent: handleAnalyticsEvent,
|
|
100
101
|
createAnalyticsEvent: createAnalyticsEvent,
|
|
@@ -114,6 +115,12 @@ var useMemoEditorFeatureFlags = function useMemoEditorFeatureFlags(featureFlags)
|
|
|
114
115
|
}
|
|
115
116
|
return ffRef.current;
|
|
116
117
|
};
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
*
|
|
121
|
+
* @param props
|
|
122
|
+
* @example
|
|
123
|
+
*/
|
|
117
124
|
function CoreEditor(props) {
|
|
118
125
|
var editorSessionId = (0, _react.useRef)((0, _v.default)());
|
|
119
126
|
var data = (0, _react.useMemo)(function () {
|
|
@@ -19,7 +19,7 @@ var _scrollbar = require("@atlaskit/editor-shared-styles/scrollbar");
|
|
|
19
19
|
var _platformFeatureFlagsReact = require("@atlaskit/platform-feature-flags-react");
|
|
20
20
|
var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
|
|
21
21
|
var _ContentStyles = require("../ContentStyles");
|
|
22
|
-
var _EditorContentContainer = _interopRequireDefault(require("../EditorContentContainer"));
|
|
22
|
+
var _EditorContentContainer = _interopRequireDefault(require("../EditorContentContainer/EditorContentContainer"));
|
|
23
23
|
var _PluginSlot = _interopRequireDefault(require("../PluginSlot"));
|
|
24
24
|
var _WithFlash = _interopRequireDefault(require("../WithFlash"));
|
|
25
25
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
@@ -25,7 +25,7 @@ var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
|
|
|
25
25
|
var _ClickAreaBlock = _interopRequireDefault(require("../../Addon/ClickAreaBlock"));
|
|
26
26
|
var _contentComponentWrapper = require("../../Addon/ClickAreaBlock/contentComponentWrapper");
|
|
27
27
|
var _ContentStyles = require("../../ContentStyles");
|
|
28
|
-
var _EditorContentContainer = _interopRequireDefault(require("../../EditorContentContainer"));
|
|
28
|
+
var _EditorContentContainer = _interopRequireDefault(require("../../EditorContentContainer/EditorContentContainer"));
|
|
29
29
|
var _PluginSlot = _interopRequireDefault(require("../../PluginSlot"));
|
|
30
30
|
var _ToolbarWithSizeDetector = require("../../Toolbar/ToolbarWithSizeDetector");
|
|
31
31
|
var _WithFlash = _interopRequireDefault(require("../../WithFlash"));
|
|
@@ -20,7 +20,7 @@ var _ClickAreaBlock = _interopRequireDefault(require("../../Addon/ClickAreaBlock
|
|
|
20
20
|
var _contentComponentWrapper = require("../../Addon/ClickAreaBlock/contentComponentWrapper");
|
|
21
21
|
var _ContentStyles = require("../../ContentStyles");
|
|
22
22
|
var _ContextPanel = require("../../ContextPanel");
|
|
23
|
-
var _EditorContentContainer = _interopRequireDefault(require("../../EditorContentContainer"));
|
|
23
|
+
var _EditorContentContainer = _interopRequireDefault(require("../../EditorContentContainer/EditorContentContainer"));
|
|
24
24
|
var _PluginSlot = _interopRequireDefault(require("../../PluginSlot"));
|
|
25
25
|
var _StyledComponents = require("./StyledComponents");
|
|
26
26
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
@@ -21,6 +21,7 @@ var SWOOP_ANIMATION = "0.5s ".concat(_editorSharedStyles.akEditorSwoopCubicBezie
|
|
|
21
21
|
var getTotalPadding = function getTotalPadding() {
|
|
22
22
|
return (0, _editorSharedStyles.akEditorGutterPaddingDynamic)() * 2;
|
|
23
23
|
};
|
|
24
|
+
var akNestedDndGutterOffset = 8;
|
|
24
25
|
|
|
25
26
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
26
27
|
var fullPageEditorWrapper = exports.fullPageEditorWrapper = (0, _react.css)({
|
|
@@ -126,7 +127,7 @@ var editorContentAreaContainerStyle = function editorContentAreaContainerStyle()
|
|
|
126
127
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
|
|
127
128
|
'[data-layout-section]': {
|
|
128
129
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
|
|
129
|
-
maxWidth: "calc(100% + ".concat(_editorSharedStyles.akLayoutGutterOffset * 2, "px)")
|
|
130
|
+
maxWidth: "calc(100% + ".concat((_editorSharedStyles.akLayoutGutterOffset + ((0, _platformFeatureFlags.fg)('platform_editor_nested_dnd_styles_changes') ? akNestedDndGutterOffset : 0)) * 2, "px)")
|
|
130
131
|
}
|
|
131
132
|
}
|
|
132
133
|
});
|
|
@@ -21,6 +21,7 @@ var _templateObject, _templateObject2, _templateObject3, _templateObject4, _temp
|
|
|
21
21
|
* If you are making updates to this file, please updates in new location as well.
|
|
22
22
|
*/
|
|
23
23
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
24
|
+
var akNestedDndGutterOffset = 8;
|
|
24
25
|
var firstNodeWithNotMarginTop = function firstNodeWithNotMarginTop() {
|
|
25
26
|
return (0, _platformFeatureFlags.fg)('platform_editor_nested_dnd_styles_changes') ? // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression
|
|
26
27
|
(0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\t\t\t\t> :nth-child(1 of :not(style, .ProseMirror-gapcursor, .ProseMirror-widget, span)) {\n\t\t\t\t\tmargin-top: 0;\n\t\t\t\t}\n\t\t\t"]))) : // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression
|
|
@@ -76,5 +77,5 @@ var layoutResponsiveStyles = function layoutResponsiveStyles(viewMode) {
|
|
|
76
77
|
|
|
77
78
|
// eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation
|
|
78
79
|
var layoutStyles = exports.layoutStyles = function layoutStyles(viewMode) {
|
|
79
|
-
return (0, _react.css)(_templateObject13 || (_templateObject13 = (0, _taggedTemplateLiteral2.default)(["\n\t.ProseMirror {\n\t\t", "\n\t\t[data-layout-section] {\n\t\t\t/* Ignored via go/ees007\n\t\t\tTODO: Migrate away from gridSize\n\t\t\tRecommendation: Replace directly with 7px */\n\t\t\tmargin: ", " -", "px 0;\n\t\t\ttransition: border-color 0.3s ", ";\n\t\t\tcursor: ", ";\n\n\t\t\t/* Inner cursor located 26px from left */\n\t\t\t[data-layout-column] {\n\t\t\t\tflex: 1;\n\t\t\t\tposition: relative;\n\n\t\t\t\tmin-width: 0;\n\t\t\t\t/* disable 4 borders when in view mode and advanced layouts is on */\n\t\t\t\tborder: ", "px\n\t\t\t\t\tsolid ", ";\n\t\t\t\tborder-radius: 4px;\n\t\t\t\tpadding: ", "px\n\t\t\t\t\t", "px;\n\t\t\t\tbox-sizing: border-box;\n\n\t\t\t\t> div {\n\t\t\t\t\t", "\n\n\t\t\t\t\t> .embedCardView-content-wrap:first-of-type .rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t> .mediaSingleView-content-wrap:first-of-type .rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t> .ProseMirror-gapcursor.-right:first-child\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item,\n\t\t\t\t\t> style:first-child\n\t\t\t\t\t\t+ .ProseMirror-gapcursor.-right\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item,\n\t\t\t\t\t> .ProseMirror-gapcursor.-right:first-of-type\n\t\t\t\t\t\t+ .embedCardView-content-wrap\n\t\t\t\t\t\t.rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t> .ProseMirror-gapcursor:first-child\n\t\t\t\t\t\t+ span\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item,\n\t\t\t\t\t> style:first-child\n\t\t\t\t\t\t+ .ProseMirror-gapcursor\n\t\t\t\t\t\t+ span\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t/* Prevent first DecisionWrapper's margin-top: 8px from shifting decisions down\n and shrinking layout's node selectable area (leniency margin) */\n\t\t\t\t\t> [data-node-type='decisionList'] {\n\t\t\t\t\t\tli:first-of-type [data-decision-wrapper] {\n\t\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t/* Make the 'content' fill the entire height of the layout column to allow click\n handler of layout section nodeview to target only data-layout-column */\n\t\t\t\t[data-layout-content] {\n\t\t\t\t\theight: 100%;\n\t\t\t\t\tcursor: text;\n\t\t\t\t\t.mediaGroupView-content-wrap {\n\t\t\t\t\t\tclear: both;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t", "\n\t\t}\n\n\t\t/* styles to support borders for layout */\n\t\t[data-layout-section],\n\t\t.layoutSectionView-content-wrap {\n\t\t\t", "\n\t\t}\n\t}\n\n\t", "\n\n\t/* hide separator when element is dragging on top of a layout column */\n\t[data-blocks-drop-target-container] ~ [data-layout-column] > [data-layout-content]::before {\n\t\tdisplay: none;\n\t}\n\n\t.fabric-editor--full-width-mode .ProseMirror {\n\t\t[data-layout-section] {\n\t\t\t.", " {\n\t\t\t\tmargin: 0 ", "px;\n\t\t\t}\n\t\t}\n\t}\n\n\t", "\n"])), layoutSectionStyles(), "var(--ds-space-100, 8px)", _editorSharedStyles.akLayoutGutterOffset + ((0, _platformFeatureFlags.fg)('platform_editor_nested_dnd_styles_changes') ?
|
|
80
|
+
return (0, _react.css)(_templateObject13 || (_templateObject13 = (0, _taggedTemplateLiteral2.default)(["\n\t.ProseMirror {\n\t\t", "\n\t\t[data-layout-section] {\n\t\t\t/* Ignored via go/ees007\n\t\t\tTODO: Migrate away from gridSize\n\t\t\tRecommendation: Replace directly with 7px */\n\t\t\tmargin: ", " -", "px 0;\n\t\t\ttransition: border-color 0.3s ", ";\n\t\t\tcursor: ", ";\n\n\t\t\t/* Inner cursor located 26px from left */\n\t\t\t[data-layout-column] {\n\t\t\t\tflex: 1;\n\t\t\t\tposition: relative;\n\n\t\t\t\tmin-width: 0;\n\t\t\t\t/* disable 4 borders when in view mode and advanced layouts is on */\n\t\t\t\tborder: ", "px\n\t\t\t\t\tsolid ", ";\n\t\t\t\tborder-radius: 4px;\n\t\t\t\tpadding: ", "px\n\t\t\t\t\t", "px;\n\t\t\t\tbox-sizing: border-box;\n\n\t\t\t\t> div {\n\t\t\t\t\t", "\n\n\t\t\t\t\t> .embedCardView-content-wrap:first-of-type .rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t> .mediaSingleView-content-wrap:first-of-type .rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t> .ProseMirror-gapcursor.-right:first-child\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item,\n\t\t\t\t\t> style:first-child\n\t\t\t\t\t\t+ .ProseMirror-gapcursor.-right\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item,\n\t\t\t\t\t> .ProseMirror-gapcursor.-right:first-of-type\n\t\t\t\t\t\t+ .embedCardView-content-wrap\n\t\t\t\t\t\t.rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t> .ProseMirror-gapcursor:first-child\n\t\t\t\t\t\t+ span\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item,\n\t\t\t\t\t> style:first-child\n\t\t\t\t\t\t+ .ProseMirror-gapcursor\n\t\t\t\t\t\t+ span\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t/* Prevent first DecisionWrapper's margin-top: 8px from shifting decisions down\n and shrinking layout's node selectable area (leniency margin) */\n\t\t\t\t\t> [data-node-type='decisionList'] {\n\t\t\t\t\t\tli:first-of-type [data-decision-wrapper] {\n\t\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t/* Make the 'content' fill the entire height of the layout column to allow click\n handler of layout section nodeview to target only data-layout-column */\n\t\t\t\t[data-layout-content] {\n\t\t\t\t\theight: 100%;\n\t\t\t\t\tcursor: text;\n\t\t\t\t\t.mediaGroupView-content-wrap {\n\t\t\t\t\t\tclear: both;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t", "\n\t\t}\n\n\t\t/* styles to support borders for layout */\n\t\t[data-layout-section],\n\t\t.layoutSectionView-content-wrap {\n\t\t\t", "\n\t\t}\n\t}\n\n\t", "\n\n\t/* hide separator when element is dragging on top of a layout column */\n\t[data-blocks-drop-target-container] ~ [data-layout-column] > [data-layout-content]::before {\n\t\tdisplay: none;\n\t}\n\n\t.fabric-editor--full-width-mode .ProseMirror {\n\t\t[data-layout-section] {\n\t\t\t.", " {\n\t\t\t\tmargin: 0 ", "px;\n\t\t\t}\n\t\t}\n\t}\n\n\t", "\n"])), layoutSectionStyles(), "var(--ds-space-100, 8px)", _editorSharedStyles.akLayoutGutterOffset + ((0, _platformFeatureFlags.fg)('platform_editor_nested_dnd_styles_changes') ? akNestedDndGutterOffset : 0), _editorSharedStyles.akEditorSwoopCubicBezier, viewMode === 'view' ? 'default' : 'pointer', viewMode === 'view' || (0, _experiments.editorExperiment)('advanced_layouts', true) ? 0 : _editorSharedStyles.akEditorSelectedBorderSize, "var(--ds-border, #091E4224)", _styles.LAYOUT_COLUMN_PADDING, _styles.LAYOUT_COLUMN_PADDING + ((0, _platformFeatureFlags.fg)('platform_editor_nested_dnd_styles_changes') ? 8 : 0), firstNodeWithNotMarginTop(), layoutColumnStyles(), (0, _experiments.editorExperiment)('advanced_layouts', true) ? layoutWithSeparatorBorderStyles(viewMode) : layoutBorderStyles(viewMode), (0, _experiments.editorExperiment)('advanced_layouts', true) && layoutResponsiveStyles(viewMode), _types.TableCssClassName.TABLE_CONTAINER, _consts.tableMarginFullWidthMode, (0, _experiments.editorExperiment)('advanced_layouts', false) && (0, _platformFeatureFlags.fg)('platform_editor_nested_dnd_styles_changes') && ".ak-editor-content-area.appearance-full-page .ProseMirror [data-layout-section] {\n\t\t\t\tmargin: ".concat("var(--ds-space-100, 8px)", " -", _editorSharedStyles.akLayoutGutterOffset + 8, "px 0;\n\t\t\t\t}"));
|
|
80
81
|
};
|
package/dist/cjs/ui/{EditorContentContainer.js → EditorContentContainer/EditorContentContainer.js}
RENAMED
|
@@ -28,15 +28,15 @@ var _scrollbar = require("@atlaskit/editor-shared-styles/scrollbar");
|
|
|
28
28
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
29
29
|
var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
|
|
30
30
|
var _tokens = require("@atlaskit/tokens");
|
|
31
|
-
var _getInlineNodeViewProducer = require("
|
|
32
|
-
var _codeBlock = require("
|
|
33
|
-
var _date = require("
|
|
34
|
-
var _expand = require("
|
|
35
|
-
var _extension = require("
|
|
36
|
-
var _media = require("
|
|
37
|
-
var _panel2 = require("
|
|
38
|
-
var _status = require("
|
|
39
|
-
var _tasksAndDecisions = require("
|
|
31
|
+
var _getInlineNodeViewProducer = require("../../nodeviews/getInlineNodeViewProducer.styles");
|
|
32
|
+
var _codeBlock = require("../ContentStyles/code-block");
|
|
33
|
+
var _date = require("../ContentStyles/date");
|
|
34
|
+
var _expand = require("../ContentStyles/expand");
|
|
35
|
+
var _extension = require("../ContentStyles/extension");
|
|
36
|
+
var _media = require("../ContentStyles/media");
|
|
37
|
+
var _panel2 = require("../ContentStyles/panel");
|
|
38
|
+
var _status = require("../ContentStyles/status");
|
|
39
|
+
var _tasksAndDecisions = require("../ContentStyles/tasks-and-decisions");
|
|
40
40
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14, _templateObject15, _templateObject16, _templateObject17, _templateObject18, _templateObject19, _templateObject20, _templateObject21, _templateObject22, _templateObject23, _templateObject24, _templateObject25, _templateObject26, _templateObject27, _templateObject28, _templateObject29, _templateObject30, _templateObject31, _templateObject32, _templateObject33, _templateObject34, _templateObject35, _templateObject36;
|
|
41
41
|
/* eslint-disable @atlaskit/design-system/consistent-css-prop-usage */
|
|
42
42
|
/* eslint-disable react-hooks/rules-of-hooks */
|
|
@@ -351,7 +351,7 @@ var akEditorBreakpointForSmallDevice = "1266px";
|
|
|
351
351
|
|
|
352
352
|
// jest warning: JSDOM version (22) doesn't support the new @container CSS rule
|
|
353
353
|
var contentStyles = function contentStyles() {
|
|
354
|
-
return (0, _react2.css)(_templateObject32 || (_templateObject32 = (0, _taggedTemplateLiteral2.default)(["\n\t--ak-editor--default-gutter-padding: ", "px;\n\t/* 52 is from akEditorGutterPaddingDynamic via editor-shared-styles */\n\t--ak-editor--large-gutter-padding: ", "px;\n\t--ak-editor--default-layout-width: ", "px;\n\t--ak-editor--full-width-layout-width: ", "px;\n\t/* calculate editor line length, 100cqw is the editor container width */\n\t--ak-editor--line-length: min(\n\t\tcalc(100cqw - var(--ak-editor--large-gutter-padding) * 2),\n\t\tvar(--ak-editor--default-layout-width)\n\t);\n\t--ak-editor--breakout-wide-layout-width: ", "px;\n\t--ak-editor--breakout-full-page-guttering-padding: calc(\n\t\tvar(--ak-editor--large-gutter-padding) * 2 + var(--ak-editor--default-gutter-padding)\n\t);\n\n\t.fabric-editor--full-width-mode {\n\t\t--ak-editor--line-length: min(\n\t\t\tcalc(100cqw - var(--ak-editor--large-gutter-padding) * 2),\n\t\t\tvar(--ak-editor--full-width-layout-width)\n\t\t);\n\t}\n\n\t.ProseMirror {\n\t\t--ak-editor-max-container-width: calc(100cqw - var(--ak-editor--large-gutter-padding));\n\t}\n\n\t/* We can't allow nodes that are inside other nodes to bleed from the parent container */\n\t.ProseMirror > div[data-prosemirror-node-block] [data-prosemirror-node-block] {\n\t\t--ak-editor-max-container-width: 100%;\n\t}\n\n\t/* container editor-area is defined in platform/packages/editor/editor-core/src/ui/Appearance/FullPage/StyledComponents.ts */\n\t@container editor-area (width >= ", ") {\n\t\t.ProseMirror {\n\t\t\t--ak-editor--breakout-wide-layout-width: ", "px;\n\t\t}\n\t}\n\n\t.ProseMirror {\n\t\toutline: none;\n\t\tfont-size: var(--ak-editor-base-font-size);\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t}\n\n\t", "\n\n\t.ProseMirror-hideselection *::selection {\n\t\tbackground: transparent;\n\t}\n\n\t.ProseMirror-hideselection *::-moz-selection {\n\t\tbackground: transparent;\n\t}\n\n\t/**\n\t * This prosemirror css style: https://github.com/ProseMirror/prosemirror-view/blob/f37ebb29befdbde3cd194fe13fe17b78e743d2f2/style/prosemirror.css#L24\n\t *\n\t * 1. Merge and Release platform_editor_hide_cursor_when_pm_hideselection\n\t * 2. Cleanup duplicated style from platform_editor_advanced_code_blocks\n\t * https://product-fabric.atlassian.net/browse/ED-26331\n\t */\n\t", "\n\n\t/* This prosemirror css style: https://github.com/ProseMirror/prosemirror-view/blob/f37ebb29befdbde3cd194fe13fe17b78e743d2f2/style/prosemirror.css#L24 */\n\t", "\n\n\t.ProseMirror-selectednode {\n\t\toutline: none;\n\t}\n\n\t.ProseMirror-selectednode:empty {\n\t\toutline: 2px solid ", ";\n\t}\n\n\t.ProseMirror.ProseMirror-focused:has(.ProseMirror-mark-boundary-cursor) {\n\t\tcaret-color: transparent;\n\t}\n\t.ProseMirror:not(.ProseMirror-focused) .ProseMirror-mark-boundary-cursor {\n\t\tdisplay: none;\n\t}\n\n\t", "\n\t", "\n\t", "\n\t", "\n\n ", "\n\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", ";\n\
|
|
354
|
+
return (0, _react2.css)(_templateObject32 || (_templateObject32 = (0, _taggedTemplateLiteral2.default)(["\n\t--ak-editor--default-gutter-padding: ", "px;\n\t/* 52 is from akEditorGutterPaddingDynamic via editor-shared-styles */\n\t--ak-editor--large-gutter-padding: ", "px;\n\t--ak-editor--default-layout-width: ", "px;\n\t--ak-editor--full-width-layout-width: ", "px;\n\t/* calculate editor line length, 100cqw is the editor container width */\n\t--ak-editor--line-length: min(\n\t\tcalc(100cqw - var(--ak-editor--large-gutter-padding) * 2),\n\t\tvar(--ak-editor--default-layout-width)\n\t);\n\t--ak-editor--breakout-wide-layout-width: ", "px;\n\t--ak-editor--breakout-full-page-guttering-padding: calc(\n\t\tvar(--ak-editor--large-gutter-padding) * 2 + var(--ak-editor--default-gutter-padding)\n\t);\n\n\t.fabric-editor--full-width-mode {\n\t\t--ak-editor--line-length: min(\n\t\t\tcalc(100cqw - var(--ak-editor--large-gutter-padding) * 2),\n\t\t\tvar(--ak-editor--full-width-layout-width)\n\t\t);\n\t}\n\n\t.ProseMirror {\n\t\t--ak-editor-max-container-width: calc(100cqw - var(--ak-editor--large-gutter-padding));\n\t}\n\n\t/* We can't allow nodes that are inside other nodes to bleed from the parent container */\n\t.ProseMirror > div[data-prosemirror-node-block] [data-prosemirror-node-block] {\n\t\t--ak-editor-max-container-width: 100%;\n\t}\n\n\t/* container editor-area is defined in platform/packages/editor/editor-core/src/ui/Appearance/FullPage/StyledComponents.ts */\n\t@container editor-area (width >= ", ") {\n\t\t.ProseMirror {\n\t\t\t--ak-editor--breakout-wide-layout-width: ", "px;\n\t\t}\n\t}\n\n\t.ProseMirror {\n\t\toutline: none;\n\t\tfont-size: var(--ak-editor-base-font-size);\n\n\t\t", ";\n\n\t\t", ";\n\n\t\t", ";\n\n\t\t", ";\n\n\t\t", ";\n\n\t\t", ";\n\t}\n\n\t", "\n\n\t.ProseMirror-hideselection *::selection {\n\t\tbackground: transparent;\n\t}\n\n\t.ProseMirror-hideselection *::-moz-selection {\n\t\tbackground: transparent;\n\t}\n\n\t/**\n\t * This prosemirror css style: https://github.com/ProseMirror/prosemirror-view/blob/f37ebb29befdbde3cd194fe13fe17b78e743d2f2/style/prosemirror.css#L24\n\t *\n\t * 1. Merge and Release platform_editor_hide_cursor_when_pm_hideselection\n\t * 2. Cleanup duplicated style from platform_editor_advanced_code_blocks\n\t * https://product-fabric.atlassian.net/browse/ED-26331\n\t */\n\t", "\n\n\t/* This prosemirror css style: https://github.com/ProseMirror/prosemirror-view/blob/f37ebb29befdbde3cd194fe13fe17b78e743d2f2/style/prosemirror.css#L24 */\n\t", "\n\n\t.ProseMirror-selectednode {\n\t\toutline: none;\n\t}\n\n\t.ProseMirror-selectednode:empty {\n\t\toutline: 2px solid ", ";\n\t}\n\n\t.ProseMirror.ProseMirror-focused:has(.ProseMirror-mark-boundary-cursor) {\n\t\tcaret-color: transparent;\n\t}\n\t.ProseMirror:not(.ProseMirror-focused) .ProseMirror-mark-boundary-cursor {\n\t\tdisplay: none;\n\t}\n\n\t", "\n\n\t", "\n\n\t", "\n\n\t", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n ", ";\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n // Switch between the two icons based on the visual refresh feature gate\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n\t", "\n\n ", "\n\n ", "\n\n ", "\n\n ", "\n\n .panelView-content-wrap {\n\t\tbox-sizing: border-box;\n\t}\n\n\t.mediaGroupView-content-wrap ul {\n\t\tpadding: 0;\n\t}\n\n\t/** Needed to override any cleared floats, e.g. image wrapping */\n\n\tdiv.fabric-editor-block-mark[class^='fabric-editor-align'] {\n\t\tclear: none !important;\n\t}\n\n\t.fabric-editor-align-end {\n\t\ttext-align: right;\n\t}\n\n\t.fabric-editor-align-start {\n\t\ttext-align: left;\n\t}\n\n\t.fabric-editor-align-center {\n\t\ttext-align: center;\n\t}\n\n\t// For FullPage only when inside a table\n\t// Related code all lives inside: packages/editor/editor-core/src/ui/Appearance/FullPage/StyledComponents.ts\n\t// In the \"editorContentAreaContainerStyle\" function\n\t.fabric-editor--full-width-mode {\n\t\t.pm-table-container {\n\t\t\t.code-block,\n\t\t\t.extension-container,\n\t\t\t.multiBodiedExtension--container {\n\t\t\t\tmax-width: 100%;\n\t\t\t}\n\t\t}\n\t}\n\n\t.pm-table-header-content-wrap :not(.fabric-editor-alignment),\n\t.pm-table-header-content-wrap :not(p, .fabric-editor-block-mark) + div.fabric-editor-block-mark,\n\t.pm-table-cell-content-wrap :not(p, .fabric-editor-block-mark) + div.fabric-editor-block-mark {\n\t\tp:first-of-type {\n\t\t\tmargin-top: 0;\n\t\t}\n\t}\n\t.pm-table-cell-content-wrap .mediaGroupView-content-wrap {\n\t\tclear: both;\n\t}\n\n\t.hyperlink-floating-toolbar,\n\t.", " {\n\t\tpadding: 0;\n\t}\n\n\t/* Legacy Link icon in the Atlaskit package\n\t is bigger than the others, new ADS icon does not have this issue\n */\n\t", "\n"])), _editorSharedStyles.akEditorGutterPadding, (0, _editorSharedStyles.akEditorGutterPaddingDynamic)(), _editorSharedStyles.akEditorDefaultLayoutWidth, _editorSharedStyles.akEditorFullWidthLayoutWidth, _editorSharedStyles.akEditorCalculatedWideLayoutWidthSmallViewport, akEditorBreakpointForSmallDevice, _editorSharedStyles.akEditorCalculatedWideLayoutWidth, _styles.whitespaceSharedStyles, (0, _styles.paragraphSharedStyles)(), _styles.listsSharedStyles, _styles.indentationSharedStyles, _styles.shadowSharedStyle, _getInlineNodeViewProducer.InlineNodeViewSharedStyles, (0, _platformFeatureFlags.fg)('editor_request_to_edit_task') ? null : (0, _react2.css)(_templateObject33 || (_templateObject33 = (0, _taggedTemplateLiteral2.default)(["\n\t\t\t\t.ProseMirror[contenteditable='false'] .taskItemView-content-wrap {\n\t\t\t\t\tpointer-events: none;\n\t\t\t\t\topacity: 0.7;\n\t\t\t\t}\n\t\t\t"]))), (0, _platformFeatureFlags.fg)('platform_editor_hide_cursor_when_pm_hideselection') ? (0, _react2.css)(_templateObject34 || (_templateObject34 = (0, _taggedTemplateLiteral2.default)(["\n\t\t\t\t.ProseMirror-hideselection {\n\t\t\t\t\tcaret-color: transparent;\n\t\t\t\t}\n\t\t\t"]))) : null, (0, _experiments.editorExperiment)('platform_editor_advanced_code_blocks', true) ? (0, _react2.css)(_templateObject35 || (_templateObject35 = (0, _taggedTemplateLiteral2.default)(["\n\t\t\t\t.ProseMirror-hideselection {\n\t\t\t\t\tcaret-color: transparent;\n\t\t\t\t}\n\t\t\t"]))) : null, "var(--ds-border-focused, #8cf)", _styles5.placeholderTextStyles, placeholderStyles, (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1') ? placeholderOverflowStyles : null, (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1') && (0, _platformFeatureFlags.fg)('platform_editor_quick_insert_placeholder') ? placeholderWrapStyles : null, (0, _codeBlock.codeBlockStyles)(), (0, _styles2.blocktypeStyles)(), (0, _styles.codeMarkSharedStyles)(), _styles.textColorStyles, (0, _styles.backgroundColorStyles)(), listsStyles, ruleStyles(), (0, _media.mediaStyles)(), (0, _platformFeatureFlags.fg)('confluence_team_presence_scroll_to_pointer') ? _collab.telepointerStyle : _collab.telepointerStyleWithInitialOnly, _selection.gapCursorStyles, (0, _panel2.panelStyles)(), mentionsStyles, (0, _experiments.editorExperiment)('platform_editor_vanilla_dom', true, {
|
|
355
355
|
exposure: false
|
|
356
356
|
}) && vanillaMentionsStyles, (0, _experiments.editorExperiment)('platform_editor_vanilla_dom', true, {
|
|
357
357
|
exposure: false
|
|
@@ -21,7 +21,6 @@ import { useEditorContext } from '../ui/EditorContext';
|
|
|
21
21
|
import { createFeatureFlagsFromProps } from '../utils/feature-flags-from-props';
|
|
22
22
|
import measurements from '../utils/performance/measure-enum';
|
|
23
23
|
import { name, version } from '../version-wrapper';
|
|
24
|
-
import { EditorUFOBridge, EditorPerformanceMetrics } from './core-performance-metrics';
|
|
25
24
|
import { EditorINPMetrics } from './editor-inp-metrics';
|
|
26
25
|
import { EditorInternal } from './editor-internal';
|
|
27
26
|
import useMeasureEditorMountTime from './hooks/useMeasureEditorMountTime';
|
|
@@ -33,6 +32,8 @@ import sendDurationAnalytics from './utils/sendDurationAnalytics';
|
|
|
33
32
|
|
|
34
33
|
/**
|
|
35
34
|
* Editor wrapper that deals with the lifecycle logic of the editor
|
|
35
|
+
* @param passedProps
|
|
36
|
+
* @example
|
|
36
37
|
*/
|
|
37
38
|
function Editor(passedProps) {
|
|
38
39
|
const propsRef = useRef(passedProps);
|
|
@@ -92,7 +93,7 @@ function Editor(passedProps) {
|
|
|
92
93
|
}
|
|
93
94
|
}, [onSaveFromProps]);
|
|
94
95
|
const isFullPageApperance = Boolean(props.appearance && ['full-page', 'full-width'].includes(props.appearance));
|
|
95
|
-
return jsx(Fragment, null, isFullPageApperance && fg('platform_editor_fe--
|
|
96
|
+
return jsx(Fragment, null, isFullPageApperance && fg('platform_editor_fe--inp-metrics') ? jsx(EditorINPMetrics, null) : null, jsx(EditorInternal, {
|
|
96
97
|
props: props,
|
|
97
98
|
handleAnalyticsEvent: handleAnalyticsEvent,
|
|
98
99
|
createAnalyticsEvent: createAnalyticsEvent,
|
|
@@ -112,6 +113,12 @@ const useMemoEditorFeatureFlags = featureFlags => {
|
|
|
112
113
|
}
|
|
113
114
|
return ffRef.current;
|
|
114
115
|
};
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
*
|
|
119
|
+
* @param props
|
|
120
|
+
* @example
|
|
121
|
+
*/
|
|
115
122
|
export function CoreEditor(props) {
|
|
116
123
|
const editorSessionId = useRef(uuid());
|
|
117
124
|
const data = useMemo(() => {
|
|
@@ -12,7 +12,7 @@ import { scrollbarStyles } from '@atlaskit/editor-shared-styles/scrollbar';
|
|
|
12
12
|
import { componentWithCondition } from '@atlaskit/platform-feature-flags-react';
|
|
13
13
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
14
14
|
import { createEditorContentStyle } from '../ContentStyles';
|
|
15
|
-
import EditorContentContainer from '../EditorContentContainer';
|
|
15
|
+
import EditorContentContainer from '../EditorContentContainer/EditorContentContainer';
|
|
16
16
|
import PluginSlot from '../PluginSlot';
|
|
17
17
|
import WithFlash from '../WithFlash';
|
|
18
18
|
const chromelessEditorStyles = css({
|
|
@@ -24,7 +24,7 @@ import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
|
24
24
|
import ClickAreaBlock from '../../Addon/ClickAreaBlock';
|
|
25
25
|
import { contentComponentClickWrapper } from '../../Addon/ClickAreaBlock/contentComponentWrapper';
|
|
26
26
|
import { createEditorContentStyle } from '../../ContentStyles';
|
|
27
|
-
import EditorContentContainer from '../../EditorContentContainer';
|
|
27
|
+
import EditorContentContainer from '../../EditorContentContainer/EditorContentContainer';
|
|
28
28
|
import PluginSlot from '../../PluginSlot';
|
|
29
29
|
import { ToolbarWithSizeDetector as Toolbar } from '../../Toolbar/ToolbarWithSizeDetector';
|
|
30
30
|
import WithFlash from '../../WithFlash';
|
|
@@ -20,7 +20,7 @@ import ClickAreaBlock from '../../Addon/ClickAreaBlock';
|
|
|
20
20
|
import { contentComponentClickWrapper } from '../../Addon/ClickAreaBlock/contentComponentWrapper';
|
|
21
21
|
import { createEditorContentStyle } from '../../ContentStyles';
|
|
22
22
|
import { ContextPanel } from '../../ContextPanel';
|
|
23
|
-
import EditorContentContainer from '../../EditorContentContainer';
|
|
23
|
+
import EditorContentContainer from '../../EditorContentContainer/EditorContentContainer';
|
|
24
24
|
import PluginSlot from '../../PluginSlot';
|
|
25
25
|
import { contentArea, contentAreaHeightNoToolbar, contentAreaWrapper, editorContentAreaStyle, editorContentGutterStyle, sidebarArea } from './StyledComponents';
|
|
26
26
|
export const CONTENT_AREA_TEST_ID = 'ak-editor-fp-content-area';
|
|
@@ -9,6 +9,7 @@ import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
|
9
9
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
10
10
|
const SWOOP_ANIMATION = `0.5s ${akEditorSwoopCubicBezier}`;
|
|
11
11
|
const getTotalPadding = () => akEditorGutterPaddingDynamic() * 2;
|
|
12
|
+
const akNestedDndGutterOffset = 8;
|
|
12
13
|
|
|
13
14
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
14
15
|
export const fullPageEditorWrapper = css({
|
|
@@ -113,7 +114,7 @@ const editorContentAreaContainerStyle = () => css({
|
|
|
113
114
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
|
|
114
115
|
'[data-layout-section]': {
|
|
115
116
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
|
|
116
|
-
maxWidth: `calc(100% + ${akLayoutGutterOffset * 2}px)`
|
|
117
|
+
maxWidth: `calc(100% + ${(akLayoutGutterOffset + (fg('platform_editor_nested_dnd_styles_changes') ? akNestedDndGutterOffset : 0)) * 2}px)`
|
|
117
118
|
}
|
|
118
119
|
}
|
|
119
120
|
});
|
|
@@ -13,6 +13,7 @@ import { tableMarginFullWidthMode } from '@atlaskit/editor-plugins/table/ui/cons
|
|
|
13
13
|
import { akEditorDeleteBackground, akEditorDeleteBorder, akEditorSelectedBorderSize, akEditorSelectedNodeClassName, akEditorSwoopCubicBezier, akLayoutGutterOffset, getSelectionStyles, gridMediumMaxWidth, SelectionStyle } from '@atlaskit/editor-shared-styles';
|
|
14
14
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
15
15
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
16
|
+
const akNestedDndGutterOffset = 8;
|
|
16
17
|
const firstNodeWithNotMarginTop = () => fg('platform_editor_nested_dnd_styles_changes') ?
|
|
17
18
|
// eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression
|
|
18
19
|
css`
|
|
@@ -282,7 +283,7 @@ export const layoutStyles = viewMode => css`
|
|
|
282
283
|
/* Ignored via go/ees007
|
|
283
284
|
TODO: Migrate away from gridSize
|
|
284
285
|
Recommendation: Replace directly with 7px */
|
|
285
|
-
margin: ${"var(--ds-space-100, 8px)"} -${akLayoutGutterOffset + (fg('platform_editor_nested_dnd_styles_changes') ?
|
|
286
|
+
margin: ${"var(--ds-space-100, 8px)"} -${akLayoutGutterOffset + (fg('platform_editor_nested_dnd_styles_changes') ? akNestedDndGutterOffset : 0)}px 0;
|
|
286
287
|
transition: border-color 0.3s ${akEditorSwoopCubicBezier};
|
|
287
288
|
cursor: ${viewMode === 'view' ? 'default' : 'pointer'};
|
|
288
289
|
|
|
@@ -28,15 +28,15 @@ import { scrollbarStyles } from '@atlaskit/editor-shared-styles/scrollbar';
|
|
|
28
28
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
29
29
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
30
30
|
import { useThemeObserver } from '@atlaskit/tokens';
|
|
31
|
-
import { InlineNodeViewSharedStyles } from '
|
|
32
|
-
import { codeBlockStyles } from '
|
|
33
|
-
import { dateStyles, dateVanillaStyles } from '
|
|
34
|
-
import { expandStyles } from '
|
|
35
|
-
import { extensionStyles } from '
|
|
36
|
-
import { mediaStyles } from '
|
|
37
|
-
import { panelStyles } from '
|
|
38
|
-
import { statusStyles, vanillaStatusStyles } from '
|
|
39
|
-
import { taskDecisionStyles, vanillaTaskDecisionIconWithoutVisualRefresh as vanillaDecisionIconWithoutVisualRefresh, vanillaTaskDecisionIconWithVisualRefresh as vanillaDecisionIconWithVisualRefresh, vanillaTaskDecisionStyles as vanillaDecisionStyles, vanillaTaskItemStyles } from '
|
|
31
|
+
import { InlineNodeViewSharedStyles } from '../../nodeviews/getInlineNodeViewProducer.styles';
|
|
32
|
+
import { codeBlockStyles } from '../ContentStyles/code-block';
|
|
33
|
+
import { dateStyles, dateVanillaStyles } from '../ContentStyles/date';
|
|
34
|
+
import { expandStyles } from '../ContentStyles/expand';
|
|
35
|
+
import { extensionStyles } from '../ContentStyles/extension';
|
|
36
|
+
import { mediaStyles } from '../ContentStyles/media';
|
|
37
|
+
import { panelStyles } from '../ContentStyles/panel';
|
|
38
|
+
import { statusStyles, vanillaStatusStyles } from '../ContentStyles/status';
|
|
39
|
+
import { taskDecisionStyles, vanillaTaskDecisionIconWithoutVisualRefresh as vanillaDecisionIconWithoutVisualRefresh, vanillaTaskDecisionIconWithVisualRefresh as vanillaDecisionIconWithVisualRefresh, vanillaTaskDecisionStyles as vanillaDecisionStyles, vanillaTaskItemStyles } from '../ContentStyles/tasks-and-decisions';
|
|
40
40
|
|
|
41
41
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
42
42
|
export const linkStyles = css`
|
|
@@ -1068,11 +1068,17 @@ const contentStyles = () => css`
|
|
|
1068
1068
|
.ProseMirror {
|
|
1069
1069
|
outline: none;
|
|
1070
1070
|
font-size: var(--ak-editor-base-font-size);
|
|
1071
|
+
|
|
1071
1072
|
${whitespaceSharedStyles};
|
|
1073
|
+
|
|
1072
1074
|
${paragraphSharedStyles()};
|
|
1075
|
+
|
|
1073
1076
|
${listsSharedStyles};
|
|
1077
|
+
|
|
1074
1078
|
${indentationSharedStyles};
|
|
1079
|
+
|
|
1075
1080
|
${shadowSharedStyle};
|
|
1081
|
+
|
|
1076
1082
|
${InlineNodeViewSharedStyles};
|
|
1077
1083
|
}
|
|
1078
1084
|
|
|
@@ -1127,66 +1133,107 @@ const contentStyles = () => css`
|
|
|
1127
1133
|
}
|
|
1128
1134
|
|
|
1129
1135
|
${placeholderTextStyles}
|
|
1136
|
+
|
|
1130
1137
|
${placeholderStyles}
|
|
1138
|
+
|
|
1131
1139
|
${editorExperiment('platform_editor_controls', 'variant1') ? placeholderOverflowStyles : null}
|
|
1140
|
+
|
|
1132
1141
|
${editorExperiment('platform_editor_controls', 'variant1') && fg('platform_editor_quick_insert_placeholder') ? placeholderWrapStyles : null}
|
|
1133
1142
|
|
|
1134
1143
|
${codeBlockStyles()}
|
|
1135
1144
|
|
|
1136
1145
|
${blocktypeStyles()}
|
|
1146
|
+
|
|
1137
1147
|
${codeMarkSharedStyles()}
|
|
1148
|
+
|
|
1138
1149
|
${textColorStyles}
|
|
1150
|
+
|
|
1139
1151
|
${backgroundColorStyles()}
|
|
1152
|
+
|
|
1140
1153
|
${listsStyles}
|
|
1154
|
+
|
|
1141
1155
|
${ruleStyles()}
|
|
1156
|
+
|
|
1142
1157
|
${mediaStyles()}
|
|
1158
|
+
|
|
1143
1159
|
${fg('confluence_team_presence_scroll_to_pointer') ? telepointerStyle : telepointerStyleWithInitialOnly}
|
|
1144
1160
|
${gapCursorStyles};
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1161
|
+
|
|
1162
|
+
${panelStyles()}
|
|
1163
|
+
|
|
1164
|
+
${mentionsStyles}
|
|
1165
|
+
|
|
1166
|
+
${editorExperiment('platform_editor_vanilla_dom', true, {
|
|
1148
1167
|
exposure: false
|
|
1149
1168
|
}) && vanillaMentionsStyles}
|
|
1150
|
-
|
|
1169
|
+
|
|
1170
|
+
${editorExperiment('platform_editor_vanilla_dom', true, {
|
|
1151
1171
|
exposure: false
|
|
1152
1172
|
}) && vanillaSelectionStyles}
|
|
1153
|
-
|
|
1173
|
+
|
|
1174
|
+
${editorExperiment('platform_editor_vanilla_dom', true, {
|
|
1154
1175
|
exposure: false
|
|
1155
1176
|
}) ? emojiStyles : reactEmojiStyles}
|
|
1177
|
+
|
|
1156
1178
|
${emojiStyles}
|
|
1179
|
+
|
|
1157
1180
|
${tasksAndDecisionsStyles}
|
|
1181
|
+
|
|
1158
1182
|
${gridStyles}
|
|
1183
|
+
|
|
1159
1184
|
${linkStyles}
|
|
1185
|
+
|
|
1160
1186
|
${blockMarksSharedStyles}
|
|
1187
|
+
|
|
1161
1188
|
${dateSharedStyle}
|
|
1189
|
+
|
|
1162
1190
|
${extensionStyles}
|
|
1191
|
+
|
|
1163
1192
|
${expandStyles()}
|
|
1193
|
+
|
|
1164
1194
|
${findReplaceStyles}
|
|
1195
|
+
|
|
1165
1196
|
${textHighlightStyle}
|
|
1197
|
+
|
|
1166
1198
|
${taskDecisionStyles}
|
|
1199
|
+
|
|
1167
1200
|
${editorExperiment('platform_editor_vanilla_dom', true, {
|
|
1168
1201
|
exposure: false
|
|
1169
1202
|
}) && vanillaTaskItemStyles}
|
|
1203
|
+
|
|
1170
1204
|
${editorExperiment('platform_editor_vanilla_dom', true, {
|
|
1171
1205
|
exposure: false
|
|
1172
1206
|
}) && vanillaDecisionStyles}
|
|
1207
|
+
|
|
1173
1208
|
// Switch between the two icons based on the visual refresh feature gate
|
|
1174
1209
|
${editorExperiment('platform_editor_vanilla_dom', true, {
|
|
1175
1210
|
exposure: false
|
|
1176
1211
|
}) && fg('platform-visual-refresh-icons') && vanillaDecisionIconWithVisualRefresh}
|
|
1212
|
+
|
|
1177
1213
|
${editorExperiment('platform_editor_vanilla_dom', true, {
|
|
1178
1214
|
exposure: false
|
|
1179
1215
|
}) && !fg('platform-visual-refresh-icons') && vanillaDecisionIconWithoutVisualRefresh}
|
|
1216
|
+
|
|
1180
1217
|
${statusStyles}
|
|
1218
|
+
|
|
1181
1219
|
${editorExperiment('platform_editor_vanilla_dom', true) ? vanillaStatusStyles() : null}
|
|
1220
|
+
|
|
1182
1221
|
${annotationSharedStyles()}
|
|
1222
|
+
|
|
1183
1223
|
${smartCardStyles()}
|
|
1224
|
+
|
|
1184
1225
|
${fg('platform-linking-visual-refresh-v1') ? getSmartCardSharedStyles() : smartCardSharedStyles}
|
|
1226
|
+
|
|
1185
1227
|
${editorExperiment('platform_editor_vanilla_dom', true) ? dateVanillaStyles : null}
|
|
1228
|
+
|
|
1186
1229
|
${dateStyles}
|
|
1230
|
+
|
|
1187
1231
|
${embedCardStyles()}
|
|
1232
|
+
|
|
1188
1233
|
${unsupportedStyles}
|
|
1234
|
+
|
|
1189
1235
|
${resizerStyles}
|
|
1236
|
+
|
|
1190
1237
|
${fixBlockControlStylesSSR()}
|
|
1191
1238
|
|
|
1192
1239
|
.panelView-content-wrap {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export const name = "@atlaskit/editor-core";
|
|
2
|
-
export const version = "207.0.
|
|
2
|
+
export const version = "207.0.6";
|
|
@@ -24,7 +24,6 @@ import { useEditorContext } from '../ui/EditorContext';
|
|
|
24
24
|
import { createFeatureFlagsFromProps } from '../utils/feature-flags-from-props';
|
|
25
25
|
import measurements from '../utils/performance/measure-enum';
|
|
26
26
|
import { name, version } from '../version-wrapper';
|
|
27
|
-
import { EditorUFOBridge, EditorPerformanceMetrics } from './core-performance-metrics';
|
|
28
27
|
import { EditorINPMetrics } from './editor-inp-metrics';
|
|
29
28
|
import { EditorInternal } from './editor-internal';
|
|
30
29
|
import useMeasureEditorMountTime from './hooks/useMeasureEditorMountTime';
|
|
@@ -36,6 +35,8 @@ import sendDurationAnalytics from './utils/sendDurationAnalytics';
|
|
|
36
35
|
|
|
37
36
|
/**
|
|
38
37
|
* Editor wrapper that deals with the lifecycle logic of the editor
|
|
38
|
+
* @param passedProps
|
|
39
|
+
* @example
|
|
39
40
|
*/
|
|
40
41
|
function Editor(passedProps) {
|
|
41
42
|
var propsRef = useRef(passedProps);
|
|
@@ -90,7 +91,7 @@ function Editor(passedProps) {
|
|
|
90
91
|
}
|
|
91
92
|
}, [onSaveFromProps]);
|
|
92
93
|
var isFullPageApperance = Boolean(props.appearance && ['full-page', 'full-width'].includes(props.appearance));
|
|
93
|
-
return jsx(Fragment, null, isFullPageApperance && fg('platform_editor_fe--
|
|
94
|
+
return jsx(Fragment, null, isFullPageApperance && fg('platform_editor_fe--inp-metrics') ? jsx(EditorINPMetrics, null) : null, jsx(EditorInternal, {
|
|
94
95
|
props: props,
|
|
95
96
|
handleAnalyticsEvent: handleAnalyticsEvent,
|
|
96
97
|
createAnalyticsEvent: createAnalyticsEvent,
|
|
@@ -110,6 +111,12 @@ var useMemoEditorFeatureFlags = function useMemoEditorFeatureFlags(featureFlags)
|
|
|
110
111
|
}
|
|
111
112
|
return ffRef.current;
|
|
112
113
|
};
|
|
114
|
+
|
|
115
|
+
/**
|
|
116
|
+
*
|
|
117
|
+
* @param props
|
|
118
|
+
* @example
|
|
119
|
+
*/
|
|
113
120
|
export function CoreEditor(props) {
|
|
114
121
|
var editorSessionId = useRef(uuid());
|
|
115
122
|
var data = useMemo(function () {
|
|
@@ -19,7 +19,7 @@ import { scrollbarStyles } from '@atlaskit/editor-shared-styles/scrollbar';
|
|
|
19
19
|
import { componentWithCondition } from '@atlaskit/platform-feature-flags-react';
|
|
20
20
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
21
21
|
import { createEditorContentStyle } from '../ContentStyles';
|
|
22
|
-
import EditorContentContainer from '../EditorContentContainer';
|
|
22
|
+
import EditorContentContainer from '../EditorContentContainer/EditorContentContainer';
|
|
23
23
|
import PluginSlot from '../PluginSlot';
|
|
24
24
|
import WithFlash from '../WithFlash';
|
|
25
25
|
var chromelessEditorStyles = css({
|
|
@@ -25,7 +25,7 @@ import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
|
25
25
|
import ClickAreaBlock from '../../Addon/ClickAreaBlock';
|
|
26
26
|
import { contentComponentClickWrapper } from '../../Addon/ClickAreaBlock/contentComponentWrapper';
|
|
27
27
|
import { createEditorContentStyle } from '../../ContentStyles';
|
|
28
|
-
import EditorContentContainer from '../../EditorContentContainer';
|
|
28
|
+
import EditorContentContainer from '../../EditorContentContainer/EditorContentContainer';
|
|
29
29
|
import PluginSlot from '../../PluginSlot';
|
|
30
30
|
import { ToolbarWithSizeDetector as Toolbar } from '../../Toolbar/ToolbarWithSizeDetector';
|
|
31
31
|
import WithFlash from '../../WithFlash';
|
|
@@ -21,7 +21,7 @@ import ClickAreaBlock from '../../Addon/ClickAreaBlock';
|
|
|
21
21
|
import { contentComponentClickWrapper } from '../../Addon/ClickAreaBlock/contentComponentWrapper';
|
|
22
22
|
import { createEditorContentStyle } from '../../ContentStyles';
|
|
23
23
|
import { ContextPanel } from '../../ContextPanel';
|
|
24
|
-
import EditorContentContainer from '../../EditorContentContainer';
|
|
24
|
+
import EditorContentContainer from '../../EditorContentContainer/EditorContentContainer';
|
|
25
25
|
import PluginSlot from '../../PluginSlot';
|
|
26
26
|
import { contentArea, contentAreaHeightNoToolbar, contentAreaWrapper, editorContentAreaStyle, editorContentGutterStyle, sidebarArea } from './StyledComponents';
|
|
27
27
|
export var CONTENT_AREA_TEST_ID = 'ak-editor-fp-content-area';
|
|
@@ -13,6 +13,7 @@ var SWOOP_ANIMATION = "0.5s ".concat(akEditorSwoopCubicBezier);
|
|
|
13
13
|
var getTotalPadding = function getTotalPadding() {
|
|
14
14
|
return akEditorGutterPaddingDynamic() * 2;
|
|
15
15
|
};
|
|
16
|
+
var akNestedDndGutterOffset = 8;
|
|
16
17
|
|
|
17
18
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
18
19
|
export var fullPageEditorWrapper = css({
|
|
@@ -118,7 +119,7 @@ var editorContentAreaContainerStyle = function editorContentAreaContainerStyle()
|
|
|
118
119
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
|
|
119
120
|
'[data-layout-section]': {
|
|
120
121
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
|
|
121
|
-
maxWidth: "calc(100% + ".concat(akLayoutGutterOffset * 2, "px)")
|
|
122
|
+
maxWidth: "calc(100% + ".concat((akLayoutGutterOffset + (fg('platform_editor_nested_dnd_styles_changes') ? akNestedDndGutterOffset : 0)) * 2, "px)")
|
|
122
123
|
}
|
|
123
124
|
}
|
|
124
125
|
});
|
|
@@ -15,6 +15,7 @@ import { tableMarginFullWidthMode } from '@atlaskit/editor-plugins/table/ui/cons
|
|
|
15
15
|
import { akEditorDeleteBackground, akEditorDeleteBorder, akEditorSelectedBorderSize, akEditorSelectedNodeClassName, akEditorSwoopCubicBezier, akLayoutGutterOffset, getSelectionStyles, gridMediumMaxWidth, SelectionStyle } from '@atlaskit/editor-shared-styles';
|
|
16
16
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
17
17
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
18
|
+
var akNestedDndGutterOffset = 8;
|
|
18
19
|
var firstNodeWithNotMarginTop = function firstNodeWithNotMarginTop() {
|
|
19
20
|
return fg('platform_editor_nested_dnd_styles_changes') ? // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression
|
|
20
21
|
css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n\t\t\t\t> :nth-child(1 of :not(style, .ProseMirror-gapcursor, .ProseMirror-widget, span)) {\n\t\t\t\t\tmargin-top: 0;\n\t\t\t\t}\n\t\t\t"]))) : // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression
|
|
@@ -70,5 +71,5 @@ var layoutResponsiveStyles = function layoutResponsiveStyles(viewMode) {
|
|
|
70
71
|
|
|
71
72
|
// eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation
|
|
72
73
|
export var layoutStyles = function layoutStyles(viewMode) {
|
|
73
|
-
return css(_templateObject13 || (_templateObject13 = _taggedTemplateLiteral(["\n\t.ProseMirror {\n\t\t", "\n\t\t[data-layout-section] {\n\t\t\t/* Ignored via go/ees007\n\t\t\tTODO: Migrate away from gridSize\n\t\t\tRecommendation: Replace directly with 7px */\n\t\t\tmargin: ", " -", "px 0;\n\t\t\ttransition: border-color 0.3s ", ";\n\t\t\tcursor: ", ";\n\n\t\t\t/* Inner cursor located 26px from left */\n\t\t\t[data-layout-column] {\n\t\t\t\tflex: 1;\n\t\t\t\tposition: relative;\n\n\t\t\t\tmin-width: 0;\n\t\t\t\t/* disable 4 borders when in view mode and advanced layouts is on */\n\t\t\t\tborder: ", "px\n\t\t\t\t\tsolid ", ";\n\t\t\t\tborder-radius: 4px;\n\t\t\t\tpadding: ", "px\n\t\t\t\t\t", "px;\n\t\t\t\tbox-sizing: border-box;\n\n\t\t\t\t> div {\n\t\t\t\t\t", "\n\n\t\t\t\t\t> .embedCardView-content-wrap:first-of-type .rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t> .mediaSingleView-content-wrap:first-of-type .rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t> .ProseMirror-gapcursor.-right:first-child\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item,\n\t\t\t\t\t> style:first-child\n\t\t\t\t\t\t+ .ProseMirror-gapcursor.-right\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item,\n\t\t\t\t\t> .ProseMirror-gapcursor.-right:first-of-type\n\t\t\t\t\t\t+ .embedCardView-content-wrap\n\t\t\t\t\t\t.rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t> .ProseMirror-gapcursor:first-child\n\t\t\t\t\t\t+ span\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item,\n\t\t\t\t\t> style:first-child\n\t\t\t\t\t\t+ .ProseMirror-gapcursor\n\t\t\t\t\t\t+ span\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t/* Prevent first DecisionWrapper's margin-top: 8px from shifting decisions down\n and shrinking layout's node selectable area (leniency margin) */\n\t\t\t\t\t> [data-node-type='decisionList'] {\n\t\t\t\t\t\tli:first-of-type [data-decision-wrapper] {\n\t\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t/* Make the 'content' fill the entire height of the layout column to allow click\n handler of layout section nodeview to target only data-layout-column */\n\t\t\t\t[data-layout-content] {\n\t\t\t\t\theight: 100%;\n\t\t\t\t\tcursor: text;\n\t\t\t\t\t.mediaGroupView-content-wrap {\n\t\t\t\t\t\tclear: both;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t", "\n\t\t}\n\n\t\t/* styles to support borders for layout */\n\t\t[data-layout-section],\n\t\t.layoutSectionView-content-wrap {\n\t\t\t", "\n\t\t}\n\t}\n\n\t", "\n\n\t/* hide separator when element is dragging on top of a layout column */\n\t[data-blocks-drop-target-container] ~ [data-layout-column] > [data-layout-content]::before {\n\t\tdisplay: none;\n\t}\n\n\t.fabric-editor--full-width-mode .ProseMirror {\n\t\t[data-layout-section] {\n\t\t\t.", " {\n\t\t\t\tmargin: 0 ", "px;\n\t\t\t}\n\t\t}\n\t}\n\n\t", "\n"])), layoutSectionStyles(), "var(--ds-space-100, 8px)", akLayoutGutterOffset + (fg('platform_editor_nested_dnd_styles_changes') ?
|
|
74
|
+
return css(_templateObject13 || (_templateObject13 = _taggedTemplateLiteral(["\n\t.ProseMirror {\n\t\t", "\n\t\t[data-layout-section] {\n\t\t\t/* Ignored via go/ees007\n\t\t\tTODO: Migrate away from gridSize\n\t\t\tRecommendation: Replace directly with 7px */\n\t\t\tmargin: ", " -", "px 0;\n\t\t\ttransition: border-color 0.3s ", ";\n\t\t\tcursor: ", ";\n\n\t\t\t/* Inner cursor located 26px from left */\n\t\t\t[data-layout-column] {\n\t\t\t\tflex: 1;\n\t\t\t\tposition: relative;\n\n\t\t\t\tmin-width: 0;\n\t\t\t\t/* disable 4 borders when in view mode and advanced layouts is on */\n\t\t\t\tborder: ", "px\n\t\t\t\t\tsolid ", ";\n\t\t\t\tborder-radius: 4px;\n\t\t\t\tpadding: ", "px\n\t\t\t\t\t", "px;\n\t\t\t\tbox-sizing: border-box;\n\n\t\t\t\t> div {\n\t\t\t\t\t", "\n\n\t\t\t\t\t> .embedCardView-content-wrap:first-of-type .rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t> .mediaSingleView-content-wrap:first-of-type .rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t> .ProseMirror-gapcursor.-right:first-child\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item,\n\t\t\t\t\t> style:first-child\n\t\t\t\t\t\t+ .ProseMirror-gapcursor.-right\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item,\n\t\t\t\t\t> .ProseMirror-gapcursor.-right:first-of-type\n\t\t\t\t\t\t+ .embedCardView-content-wrap\n\t\t\t\t\t\t.rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t> .ProseMirror-gapcursor:first-child\n\t\t\t\t\t\t+ span\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item,\n\t\t\t\t\t> style:first-child\n\t\t\t\t\t\t+ .ProseMirror-gapcursor\n\t\t\t\t\t\t+ span\n\t\t\t\t\t\t+ .mediaSingleView-content-wrap\n\t\t\t\t\t\t.rich-media-item {\n\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t/* Prevent first DecisionWrapper's margin-top: 8px from shifting decisions down\n and shrinking layout's node selectable area (leniency margin) */\n\t\t\t\t\t> [data-node-type='decisionList'] {\n\t\t\t\t\t\tli:first-of-type [data-decision-wrapper] {\n\t\t\t\t\t\t\tmargin-top: 0;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t/* Make the 'content' fill the entire height of the layout column to allow click\n handler of layout section nodeview to target only data-layout-column */\n\t\t\t\t[data-layout-content] {\n\t\t\t\t\theight: 100%;\n\t\t\t\t\tcursor: text;\n\t\t\t\t\t.mediaGroupView-content-wrap {\n\t\t\t\t\t\tclear: both;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t", "\n\t\t}\n\n\t\t/* styles to support borders for layout */\n\t\t[data-layout-section],\n\t\t.layoutSectionView-content-wrap {\n\t\t\t", "\n\t\t}\n\t}\n\n\t", "\n\n\t/* hide separator when element is dragging on top of a layout column */\n\t[data-blocks-drop-target-container] ~ [data-layout-column] > [data-layout-content]::before {\n\t\tdisplay: none;\n\t}\n\n\t.fabric-editor--full-width-mode .ProseMirror {\n\t\t[data-layout-section] {\n\t\t\t.", " {\n\t\t\t\tmargin: 0 ", "px;\n\t\t\t}\n\t\t}\n\t}\n\n\t", "\n"])), layoutSectionStyles(), "var(--ds-space-100, 8px)", akLayoutGutterOffset + (fg('platform_editor_nested_dnd_styles_changes') ? akNestedDndGutterOffset : 0), akEditorSwoopCubicBezier, viewMode === 'view' ? 'default' : 'pointer', viewMode === 'view' || editorExperiment('advanced_layouts', true) ? 0 : akEditorSelectedBorderSize, "var(--ds-border, #091E4224)", LAYOUT_COLUMN_PADDING, LAYOUT_COLUMN_PADDING + (fg('platform_editor_nested_dnd_styles_changes') ? 8 : 0), firstNodeWithNotMarginTop(), layoutColumnStyles(), editorExperiment('advanced_layouts', true) ? layoutWithSeparatorBorderStyles(viewMode) : layoutBorderStyles(viewMode), editorExperiment('advanced_layouts', true) && layoutResponsiveStyles(viewMode), TableCssClassName.TABLE_CONTAINER, tableMarginFullWidthMode, editorExperiment('advanced_layouts', false) && fg('platform_editor_nested_dnd_styles_changes') && ".ak-editor-content-area.appearance-full-page .ProseMirror [data-layout-section] {\n\t\t\t\tmargin: ".concat("var(--ds-space-100, 8px)", " -", akLayoutGutterOffset + 8, "px 0;\n\t\t\t\t}"));
|
|
74
75
|
};
|