@atlaskit/editor-core 207.0.2 → 207.0.4
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/ui/Appearance/Chromeless.js +13 -2
- package/dist/cjs/ui/Appearance/Comment/Comment.js +3 -1
- package/dist/cjs/ui/Appearance/FullPage/FullPageContentArea.js +3 -1
- package/dist/cjs/ui/ContentStyles/ai-panels.js +6 -1
- package/dist/cjs/ui/ContentStyles/index.js +10 -3
- package/dist/cjs/ui/ContentStyles/layout.js +8 -1
- package/dist/cjs/ui/ContentStyles/status.js +2 -2
- package/dist/cjs/ui/EditorContentContainer.js +227 -30
- package/dist/cjs/utils/extensions.js +16 -26
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/ui/Appearance/Chromeless.js +11 -1
- package/dist/es2019/ui/Appearance/Comment/Comment.js +3 -1
- package/dist/es2019/ui/Appearance/FullPage/FullPageContentArea.js +3 -1
- package/dist/es2019/ui/ContentStyles/ai-panels.js +7 -0
- package/dist/es2019/ui/ContentStyles/index.js +12 -5
- package/dist/es2019/ui/ContentStyles/layout.js +7 -0
- package/dist/es2019/ui/ContentStyles/status.js +2 -2
- package/dist/es2019/ui/EditorContentContainer.js +759 -34
- package/dist/es2019/utils/extensions.js +16 -26
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/ui/Appearance/Chromeless.js +13 -2
- package/dist/esm/ui/Appearance/Comment/Comment.js +3 -1
- package/dist/esm/ui/Appearance/FullPage/FullPageContentArea.js +3 -1
- package/dist/esm/ui/ContentStyles/ai-panels.js +7 -0
- package/dist/esm/ui/ContentStyles/index.js +10 -3
- package/dist/esm/ui/ContentStyles/layout.js +7 -0
- package/dist/esm/ui/ContentStyles/status.js +2 -2
- package/dist/esm/ui/EditorContentContainer.js +231 -30
- package/dist/esm/utils/extensions.js +16 -26
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/ui/Appearance/Chromeless.d.ts +8 -0
- package/dist/types/ui/ContentStyles/ai-panels.d.ts +6 -0
- package/dist/types/ui/ContentStyles/layout.d.ts +6 -0
- package/dist/types/ui/EditorContentContainer.d.ts +0 -3
- package/dist/types-ts4.5/ui/Appearance/Chromeless.d.ts +8 -0
- package/dist/types-ts4.5/ui/ContentStyles/ai-panels.d.ts +6 -0
- package/dist/types-ts4.5/ui/ContentStyles/layout.d.ts +6 -0
- package/dist/types-ts4.5/ui/EditorContentContainer.d.ts +0 -3
- package/package.json +7 -7
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @atlaskit/editor-core
|
|
2
2
|
|
|
3
|
+
## 207.0.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#156947](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/156947)
|
|
8
|
+
[`177aaf68cb7af`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/177aaf68cb7af) -
|
|
9
|
+
Cleanup feature flag - adding extension api to quick insert
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
12
|
+
## 207.0.3
|
|
13
|
+
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- [#154083](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/154083)
|
|
17
|
+
[`4895d110ee4b8`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/4895d110ee4b8) -
|
|
18
|
+
refactor content styles in editor core to be more static
|
|
19
|
+
- Updated dependencies
|
|
20
|
+
|
|
3
21
|
## 207.0.2
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
|
@@ -56,9 +56,15 @@ _scrollbar.scrollbarStyles, {
|
|
|
56
56
|
var ContentArea = exports.ContentArea = (0, _ContentStyles.createEditorContentStyle)();
|
|
57
57
|
ContentArea.displayName = 'ContentArea';
|
|
58
58
|
var EditorContainer = (0, _platformFeatureFlagsReact.componentWithCondition)(function () {
|
|
59
|
-
return (0, _experiments.editorExperiment)('platform_editor_core_static_emotion', true
|
|
59
|
+
return (0, _experiments.editorExperiment)('platform_editor_core_static_emotion', true, {
|
|
60
|
+
exposure: true
|
|
61
|
+
});
|
|
60
62
|
}, _EditorContentContainer.default, ContentArea);
|
|
61
63
|
|
|
64
|
+
/**
|
|
65
|
+
* Render the editor in a chromeless appearance.
|
|
66
|
+
* Example use is the inline comment editor, which doesn't have editor toolbar
|
|
67
|
+
*/
|
|
62
68
|
// Ignored via go/ees005
|
|
63
69
|
// eslint-disable-next-line @repo/internal/react/no-class-components
|
|
64
70
|
var Editor = exports.default = /*#__PURE__*/function (_React$Component) {
|
|
@@ -141,7 +147,12 @@ var Editor = exports.default = /*#__PURE__*/function (_React$Component) {
|
|
|
141
147
|
(0, _inherits2.default)(Editor, _React$Component);
|
|
142
148
|
return (0, _createClass2.default)(Editor, [{
|
|
143
149
|
key: "render",
|
|
144
|
-
value:
|
|
150
|
+
value:
|
|
151
|
+
/**
|
|
152
|
+
*
|
|
153
|
+
* @example
|
|
154
|
+
*/
|
|
155
|
+
function render() {
|
|
145
156
|
return (0, _react2.jsx)(RenderWithPluginState, {
|
|
146
157
|
editorAPI: this.props.editorAPI,
|
|
147
158
|
renderChrome: this.renderChrome
|
|
@@ -90,7 +90,9 @@ var secondaryToolbarStyles = (0, _react2.css)({
|
|
|
90
90
|
});
|
|
91
91
|
var appearance = 'comment';
|
|
92
92
|
var EditorContainer = (0, _platformFeatureFlagsReact.componentWithCondition)(function () {
|
|
93
|
-
return (0, _experiments.editorExperiment)('platform_editor_core_static_emotion', true
|
|
93
|
+
return (0, _experiments.editorExperiment)('platform_editor_core_static_emotion', true, {
|
|
94
|
+
exposure: true
|
|
95
|
+
});
|
|
94
96
|
}, _EditorContentContainer.default, ContentArea);
|
|
95
97
|
var CommentEditorWithIntl = exports.CommentEditorWithIntl = function CommentEditorWithIntl(props) {
|
|
96
98
|
var editorAPI = props.editorAPI;
|
|
@@ -53,7 +53,9 @@ _scrollbar.scrollbarStyles);
|
|
|
53
53
|
var ScrollContainer = (0, _ContentStyles.createEditorContentStyle)(scrollStyles);
|
|
54
54
|
ScrollContainer.displayName = 'ScrollContainer';
|
|
55
55
|
var EditorContainer = (0, _platformFeatureFlagsReact.componentWithCondition)(function () {
|
|
56
|
-
return (0, _experiments.editorExperiment)('platform_editor_core_static_emotion', true
|
|
56
|
+
return (0, _experiments.editorExperiment)('platform_editor_core_static_emotion', true, {
|
|
57
|
+
exposure: true
|
|
58
|
+
});
|
|
57
59
|
}, _EditorContentContainer.default, ScrollContainer);
|
|
58
60
|
var Content = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
59
61
|
var _contentAreaRef$curre;
|
|
@@ -10,7 +10,12 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
|
|
|
10
10
|
var _react = require("@emotion/react");
|
|
11
11
|
var _templateObject;
|
|
12
12
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
13
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
13
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } /**
|
|
14
|
+
* TODO ED-26957 - remove legacy styles when static emotion refactor is complete
|
|
15
|
+
* We are moving this to new location under FF: platform_editor_core_static_emotion
|
|
16
|
+
* New location: packages/editor/editor-core/src/ui/EditorContentContainer.tsx
|
|
17
|
+
* If you are making updates to this file, please updates in new location as well.
|
|
18
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
14
19
|
var isFirefox = typeof navigator !== 'undefined' && navigator.userAgent.toLowerCase().indexOf('firefox') > -1;
|
|
15
20
|
var rotationAnimation = (0, _react.keyframes)({
|
|
16
21
|
'0%': _objectSpread({
|
|
@@ -158,7 +158,7 @@ var akEditorBreakpointForSmallDevice = "1266px";
|
|
|
158
158
|
var legacyContentStyles = function legacyContentStyles(props) {
|
|
159
159
|
return (0, _react2.css)(_templateObject10 || (_templateObject10 = (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: ", "px;\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 ", ";\n\t", "\n\t", "\n\t", "\n\t", "\n\t", "\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\t", "\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\tRelated code all lives inside: packages/editor/editor-core/src/ui/Appearance/FullPage/StyledComponents.ts\n\tIn 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 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, (0, _editorSharedStyles.editorFontSize)({
|
|
160
160
|
theme: props.theme
|
|
161
|
-
}), _styles.whitespaceSharedStyles, (0, _styles.paragraphSharedStyles)(props.typographyTheme), _styles.listsSharedStyles, _styles.indentationSharedStyles, _styles.shadowSharedStyle, _getInlineNodeViewProducer.InlineNodeViewSharedStyles, (0, _platformFeatureFlags.fg)('editor_request_to_edit_task') ? null : (0, _react2.css)(_templateObject11 || (_templateObject11 = (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
|
|
161
|
+
}), _styles.whitespaceSharedStyles, (0, _styles.paragraphSharedStyles)(props.typographyTheme), _styles.listsSharedStyles, _styles.indentationSharedStyles, _styles.shadowSharedStyle, _getInlineNodeViewProducer.InlineNodeViewSharedStyles, (0, _platformFeatureFlags.fg)('editor_request_to_edit_task') ? null : (0, _react2.css)(_templateObject11 || (_templateObject11 = (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)(_templateObject12 || (_templateObject12 = (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)(_templateObject13 || (_templateObject13 = (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)(props.typographyTheme), (0, _styles.codeMarkSharedStyles)(), _styles.textColorStyles, (0, _styles.backgroundColorStyles)(), listsStyles, ruleStyles(), (0, _media.mediaStyles)(), (0, _layout.layoutStyles)(props.viewMode), (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, {
|
|
162
162
|
exposure: false
|
|
163
163
|
}) && vanillaMentionsStyles, (0, _experiments.editorExperiment)('platform_editor_vanilla_dom', true, {
|
|
164
164
|
exposure: false
|
|
@@ -172,8 +172,15 @@ var legacyContentStyles = function legacyContentStyles(props) {
|
|
|
172
172
|
exposure: false
|
|
173
173
|
}) && (0, _platformFeatureFlags.fg)('platform-visual-refresh-icons') && _tasksAndDecisions.vanillaTaskDecisionIconWithVisualRefresh, (0, _experiments.editorExperiment)('platform_editor_vanilla_dom', true, {
|
|
174
174
|
exposure: false
|
|
175
|
-
}) && !(0, _platformFeatureFlags.fg)('platform-visual-refresh-icons') && _tasksAndDecisions.vanillaTaskDecisionIconWithoutVisualRefresh, _status.statusStyles, (0, _experiments.editorExperiment)('platform_editor_vanilla_dom', true) ? (0, _status.vanillaStatusStyles)() : null, (0, _styles.annotationSharedStyles)(), (0, _styles.smartCardStyles)(), (0, _platformFeatureFlags.fg)('platform-linking-visual-refresh-v1') ? (0, _styles.getSmartCardSharedStyles)() : _styles.smartCardSharedStyles, (0, _experiments.editorExperiment)('platform_editor_vanilla_dom', true) ? _date.dateVanillaStyles : null, _date.dateStyles, (0, _styles.embedCardStyles)(), _styles.unsupportedStyles, _styles.resizerStyles, (0, _aiPanels.aiPanelStyles)(props.colorMode), fixBlockControlStylesSSR(), _styles.MediaSharedClassNames.FLOATING_TOOLBAR_COMPONENT, !(0, _platformFeatureFlags.fg)('platform-visual-refresh-icons') ? (0, _react2.css)(_templateObject14 || (_templateObject14 = (0, _taggedTemplateLiteral2.default)(["\n\t\t\t\t.hyperlink-open-link {\n\t\t\t\t\tmin-width: 24px;\n\t\t\t\t\tsvg {\n\t\t\t\t\t\tmax-width: 18px;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t
|
|
175
|
+
}) && !(0, _platformFeatureFlags.fg)('platform-visual-refresh-icons') && _tasksAndDecisions.vanillaTaskDecisionIconWithoutVisualRefresh, _status.statusStyles, (0, _experiments.editorExperiment)('platform_editor_vanilla_dom', true) ? (0, _status.vanillaStatusStyles)() : null, (0, _styles.annotationSharedStyles)(), (0, _styles.smartCardStyles)(), (0, _platformFeatureFlags.fg)('platform-linking-visual-refresh-v1') ? (0, _styles.getSmartCardSharedStyles)() : _styles.smartCardSharedStyles, (0, _experiments.editorExperiment)('platform_editor_vanilla_dom', true) ? _date.dateVanillaStyles : null, _date.dateStyles, (0, _styles.embedCardStyles)(), _styles.unsupportedStyles, _styles.resizerStyles, (0, _aiPanels.aiPanelStyles)(props.colorMode), fixBlockControlStylesSSR(), _styles.MediaSharedClassNames.FLOATING_TOOLBAR_COMPONENT, !(0, _platformFeatureFlags.fg)('platform-visual-refresh-icons') ? (0, _react2.css)(_templateObject14 || (_templateObject14 = (0, _taggedTemplateLiteral2.default)(["\n\t\t\t\t.hyperlink-open-link {\n\t\t\t\t\tmin-width: 24px;\n\t\t\t\t\tsvg {\n\t\t\t\t\t\tmax-width: 18px;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t"]))) : null);
|
|
176
176
|
};
|
|
177
|
+
var listLayoutShiftFix = (0, _react2.css)({
|
|
178
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
179
|
+
'.ProseMirror ul, .ProseMirror ol': {
|
|
180
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
181
|
+
marginTop: '10px'
|
|
182
|
+
}
|
|
183
|
+
});
|
|
177
184
|
var createEditorContentStyle = exports.createEditorContentStyle = function createEditorContentStyle(styles) {
|
|
178
185
|
return /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
179
186
|
var className = props.className,
|
|
@@ -206,7 +213,7 @@ var createEditorContentStyle = exports.createEditorContentStyle = function creat
|
|
|
206
213
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
207
214
|
className: className,
|
|
208
215
|
ref: ref,
|
|
209
|
-
css: [memoizedStyle, styles],
|
|
216
|
+
css: [memoizedStyle, styles, (0, _platformFeatureFlags.fg)('platform_editor_ssr_fix_lists') && listLayoutShiftFix],
|
|
210
217
|
"data-testid": "editor-content-container"
|
|
211
218
|
}, children);
|
|
212
219
|
});
|
|
@@ -13,7 +13,14 @@ var _consts = require("@atlaskit/editor-plugins/table/ui/consts");
|
|
|
13
13
|
var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
|
|
14
14
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
15
15
|
var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
|
|
16
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13;
|
|
16
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13;
|
|
17
|
+
/**
|
|
18
|
+
* TODO ED-26957 - remove legacy styles when static emotion refactor is complete
|
|
19
|
+
* We are moving this to new location under FF: platform_editor_core_static_emotion
|
|
20
|
+
* New location: packages/editor/editor-core/src/ui/EditorContentContainer.tsx
|
|
21
|
+
* If you are making updates to this file, please updates in new location as well.
|
|
22
|
+
*/
|
|
23
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
17
24
|
var firstNodeWithNotMarginTop = function firstNodeWithNotMarginTop() {
|
|
18
25
|
return (0, _platformFeatureFlags.fg)('platform_editor_nested_dnd_styles_changes') ? // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression
|
|
19
26
|
(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
|
|
@@ -16,8 +16,8 @@ var getVisualRefreshStatusStyles = function getVisualRefreshStatusStyles() {
|
|
|
16
16
|
return (
|
|
17
17
|
// eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
|
|
18
18
|
(0, _platformFeatureFlags.fg)('platform-component-visual-refresh') ? // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression
|
|
19
|
-
(0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\t\t\t\t&.", " .", " > span {\n\t\t\t\t\tbox-shadow: ", ";\n\t\t\t\t}\n\t\t
|
|
20
|
-
(0, _react.css)(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n\t\t\t\t&.", " .", " > span {\n\t\t\t\t\t", "\n\t\t\t\t}\n\t\t
|
|
19
|
+
(0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\t\t\t\t&.", " .", " > span {\n\t\t\t\t\tbox-shadow: ", ";\n\t\t\t\t}\n\t\t\t"])), _editorSharedStyles.akEditorSelectedNodeClassName, _styles.StatusSharedCssClassName.STATUS_LOZENGE, _editorSharedStyles.akEditorSelectedBoldBoxShadow) : // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression
|
|
20
|
+
(0, _react.css)(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n\t\t\t\t&.", " .", " > span {\n\t\t\t\t\t", "\n\t\t\t\t}\n\t\t\t"])), _editorSharedStyles.akEditorSelectedNodeClassName, _styles.StatusSharedCssClassName.STATUS_LOZENGE, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]))
|
|
21
21
|
);
|
|
22
22
|
};
|
|
23
23
|
var getStatusColors = function getStatusColors() {
|