@atlaskit/editor-core 216.1.1 → 216.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/dist/cjs/ui/EditorContentContainer/EditorContentContainer.js +5 -1
- package/dist/cjs/ui/EditorContentContainer/styles/blockTypeStyles.js +57 -20
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/ui/EditorContentContainer/EditorContentContainer.js +7 -3
- package/dist/es2019/ui/EditorContentContainer/styles/blockTypeStyles.js +60 -18
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/ui/EditorContentContainer/EditorContentContainer.js +7 -3
- package/dist/esm/ui/EditorContentContainer/styles/blockTypeStyles.js +55 -19
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/ui/EditorContentContainer/styles/blockTypeStyles.d.ts +2 -0
- package/dist/types-ts4.5/ui/EditorContentContainer/styles/blockTypeStyles.d.ts +2 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @atlaskit/editor-core
|
|
2
2
|
|
|
3
|
+
## 216.1.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`fabf67c3ca239`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/fabf67c3ca239) -
|
|
8
|
+
EDITOR-4191 Use node selection for all nodes selected via drag handle
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
|
|
3
11
|
## 216.1.1
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -200,7 +200,11 @@ var EditorContentContainer = /*#__PURE__*/_react.default.forwardRef(function (pr
|
|
|
200
200
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
201
201
|
_blockTypeStyles.blocktypeStyles, (0, _expValEquals.expValEquals)('platform_editor_block_menu', 'isEnabled', true) &&
|
|
202
202
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
203
|
-
_blockTypeStyles.blockquoteSelectedNodeStyles, (0,
|
|
203
|
+
_blockTypeStyles.blockquoteSelectedNodeStyles, (0, _expValEquals.expValEquals)('platform_editor_block_menu', 'isEnabled', true) &&
|
|
204
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
205
|
+
_blockTypeStyles.listSelectedNodeStyles, (0, _expValEquals.expValEquals)('platform_editor_block_menu', 'isEnabled', true) &&
|
|
206
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
207
|
+
_blockTypeStyles.textSelectedNodeStyles, (0, _expVal.expVal)('platform_editor_blockquote_zero_padding', 'isEnabled', false) ?
|
|
204
208
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
205
209
|
_blockTypeStyles.blockquoteZeroPadding : null,
|
|
206
210
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
3
4
|
Object.defineProperty(exports, "__esModule", {
|
|
4
5
|
value: true
|
|
5
6
|
});
|
|
6
|
-
exports.blocktypeStyles_without_fg_platform_editor_typography_ugc = exports.blocktypeStyles_fg_platform_editor_typography_ugc = exports.blocktypeStyles_fg_platform_editor_nested_dnd_styles_changes = exports.blocktypeStyles = exports.blockquoteZeroPadding = exports.blockquoteSelectedNodeStyles = exports.blockquoteDangerStyles = void 0;
|
|
7
|
+
exports.textSelectedNodeStyles = exports.listSelectedNodeStyles = exports.blocktypeStyles_without_fg_platform_editor_typography_ugc = exports.blocktypeStyles_fg_platform_editor_typography_ugc = exports.blocktypeStyles_fg_platform_editor_nested_dnd_styles_changes = exports.blocktypeStyles = exports.blockquoteZeroPadding = exports.blockquoteSelectedNodeStyles = exports.blockquoteDangerStyles = void 0;
|
|
8
|
+
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
7
9
|
var _react = require("@emotion/react");
|
|
8
10
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
9
11
|
|
|
@@ -128,24 +130,18 @@ var blockquoteDangerStyles = exports.blockquoteDangerStyles = (0, _react.css)({
|
|
|
128
130
|
|
|
129
131
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
130
132
|
var blockquoteSelectedNodeStyles = exports.blockquoteSelectedNodeStyles = (0, _react.css)({
|
|
131
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
132
|
-
'.ProseMirror': {
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
},
|
|
144
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
145
|
-
'&::-moz-selection, *::-moz-selection': {
|
|
146
|
-
backgroundColor: 'transparent'
|
|
147
|
-
}
|
|
148
|
-
}
|
|
133
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
134
|
+
'.ProseMirror blockquote.ak-editor-selected-node': {
|
|
135
|
+
background: "var(--ds-background-accent-blue-subtler, #CFE1FD)",
|
|
136
|
+
borderLeftColor: "var(--ds-border-selected, #1868DB)",
|
|
137
|
+
WebkitUserSelect: 'text',
|
|
138
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
139
|
+
'&::selection, *::selection': {
|
|
140
|
+
backgroundColor: 'transparent'
|
|
141
|
+
},
|
|
142
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
143
|
+
'&::-moz-selection, *::-moz-selection': {
|
|
144
|
+
backgroundColor: 'transparent'
|
|
149
145
|
}
|
|
150
146
|
}
|
|
151
147
|
});
|
|
@@ -337,4 +333,45 @@ var blocktypeStyles_fg_platform_editor_nested_dnd_styles_changes = exports.block
|
|
|
337
333
|
'.ak-editor-content-area .ak-editor-content-area .ProseMirror blockquote': {
|
|
338
334
|
paddingLeft: "var(--ds-space-200, 16px)"
|
|
339
335
|
}
|
|
340
|
-
});
|
|
336
|
+
});
|
|
337
|
+
|
|
338
|
+
// This class applies when the node is selected directly or is included in the selected range
|
|
339
|
+
var isSelectedNode = '.ak-editor-selected-node';
|
|
340
|
+
var isOuterMostSelectedNode = "".concat(isSelectedNode, ":not(").concat(isSelectedNode, " *)");
|
|
341
|
+
|
|
342
|
+
// This class applies when there is a node selection on this node directly
|
|
343
|
+
var isOnlySelectedNode = '.ProseMirror-selectednode';
|
|
344
|
+
var isOuterMostOnlySelectedNode = "".concat(isOnlySelectedNode, ":not(").concat(isOnlySelectedNode, " *)");
|
|
345
|
+
var isList = ':is(ul, ol, div[data-node-type="actionList"])';
|
|
346
|
+
var isOuterMostList = "".concat(isList, ":not(").concat(isList, " *)");
|
|
347
|
+
|
|
348
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
349
|
+
var listSelectedNodeStyles = exports.listSelectedNodeStyles = (0, _react.css)((0, _defineProperty2.default)({}, ".ProseMirror ".concat(isOuterMostList).concat(isOuterMostSelectedNode), {
|
|
350
|
+
background: "var(--ds-background-accent-blue-subtler, #CFE1FD)",
|
|
351
|
+
WebkitUserSelect: 'text',
|
|
352
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
353
|
+
'&::selection, *::selection': {
|
|
354
|
+
backgroundColor: 'transparent'
|
|
355
|
+
},
|
|
356
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
357
|
+
'&::-moz-selection, *::-moz-selection': {
|
|
358
|
+
backgroundColor: 'transparent'
|
|
359
|
+
}
|
|
360
|
+
}));
|
|
361
|
+
var isText = ":is(p, h1, h2, h3, h4, h5, h6)";
|
|
362
|
+
var isRootText = "".concat(isText, ":not(").concat(isList, " ").concat(isText, ")");
|
|
363
|
+
|
|
364
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
365
|
+
var textSelectedNodeStyles = exports.textSelectedNodeStyles = (0, _react.css)((0, _defineProperty2.default)({}, ".ProseMirror ".concat(isRootText).concat(isOuterMostOnlySelectedNode), {
|
|
366
|
+
background: "var(--ds-background-accent-blue-subtler, #CFE1FD)",
|
|
367
|
+
WebkitUserSelect: 'text',
|
|
368
|
+
boxShadow: "0 -4px 0 ".concat("var(--ds-background-accent-blue-subtler, #CFE1FD)", ", 0 4px 0 ", "var(--ds-background-accent-blue-subtler, #CFE1FD)"),
|
|
369
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
370
|
+
'&::selection, *::selection': {
|
|
371
|
+
backgroundColor: 'transparent'
|
|
372
|
+
},
|
|
373
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
374
|
+
'&::-moz-selection, *::-moz-selection': {
|
|
375
|
+
backgroundColor: 'transparent'
|
|
376
|
+
}
|
|
377
|
+
}));
|
|
@@ -22,7 +22,7 @@ import { annotationStyles } from './styles/annotationStyles';
|
|
|
22
22
|
import { backgroundColorStyles, textHighlightPaddingStyles } from './styles/backgroundColorStyles';
|
|
23
23
|
import { baseStyles, baseStylesMaxContainerWidthFixes, editorLargeGutterPuddingBaseStyles, editorLargeGutterPuddingBaseStylesEditorControls, editorLargeGutterPuddingReducedBaseStyles } from './styles/baseStyles';
|
|
24
24
|
import { blockMarksStyles } from './styles/blockMarksStyles';
|
|
25
|
-
import { blockquoteSelectedNodeStyles,
|
|
25
|
+
import { blockquoteDangerStyles, blockquoteSelectedNodeStyles, blockquoteZeroPadding, blocktypeStyles, blocktypeStyles_fg_platform_editor_nested_dnd_styles_changes, blocktypeStyles_fg_platform_editor_typography_ugc, blocktypeStyles_without_fg_platform_editor_typography_ugc, listSelectedNodeStyles, textSelectedNodeStyles } from './styles/blockTypeStyles';
|
|
26
26
|
import { codeBidiWarningStyles } from './styles/codeBidiWarningStyles';
|
|
27
27
|
import { codeBgColorStyles, codeBlockStyles, codeBlockStylesWithEmUnits, firstCodeBlockWithNoMargin, firstCodeBlockWithNoMarginOld } from './styles/codeBlockStyles';
|
|
28
28
|
import { codeMarkStyles } from './styles/codeMarkStyles';
|
|
@@ -59,7 +59,7 @@ import { shadowStyles } from './styles/shadowStyles';
|
|
|
59
59
|
import { editorControlsSmartCardStyles, linkingVisualRefreshV1Styles, showDiffDeletedNodeStyles, smartCardDiffStyles, smartCardStyles, smartCardStylesWithSearchMatch, smartCardStylesWithSearchMatchAndBlockMenuDangerStyles, smartCardStylesWithSearchMatchAndPreviewPanelResponsiveness, smartLinksInLivePagesStyles } from './styles/smartCardStyles';
|
|
60
60
|
import { statusDangerStyles, statusStyles, statusStylesMixin_fg_platform_component_visual_refresh, statusStylesMixin_fg_platform_component_visual_refresh_with_search_match, statusStylesMixin_without_fg_platform_component_visual_refresh, statusStylesMixin_without_fg_platform_component_visual_refresh_with_search_match } from './styles/statusStyles';
|
|
61
61
|
import { syncBlockStyles } from './styles/syncBlockStyles';
|
|
62
|
-
import { tableCommentEditorStyles, tableContainerOverflowY, tableContainerStyles,
|
|
62
|
+
import { tableCommentEditorStyles, tableContainerOverflowY, tableContainerStyles, tableEmptyRowStyles, tableLayoutFixes } from './styles/tableStyles';
|
|
63
63
|
import { decisionDangerStyles, decisionIconWithVisualRefresh, decisionStyles, getDenseTasksAndDecisionsStyles, taskItemStyles, taskItemStylesWithBlockTaskItem, tasksAndDecisionsStyles } from './styles/tasksAndDecisionsStyles';
|
|
64
64
|
import { telepointerColorAndCommonStyle, telepointerStyle } from './styles/telepointerStyles';
|
|
65
65
|
import { textColorStyles } from './styles/textColorStyles';
|
|
@@ -196,7 +196,11 @@ const EditorContentContainer = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
|
196
196
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
197
197
|
blocktypeStyles, expValEquals('platform_editor_block_menu', 'isEnabled', true) &&
|
|
198
198
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
199
|
-
blockquoteSelectedNodeStyles,
|
|
199
|
+
blockquoteSelectedNodeStyles, expValEquals('platform_editor_block_menu', 'isEnabled', true) &&
|
|
200
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
201
|
+
listSelectedNodeStyles, expValEquals('platform_editor_block_menu', 'isEnabled', true) &&
|
|
202
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
203
|
+
textSelectedNodeStyles, expVal('platform_editor_blockquote_zero_padding', 'isEnabled', false) ?
|
|
200
204
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
201
205
|
blockquoteZeroPadding : null,
|
|
202
206
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
@@ -121,24 +121,18 @@ export const blockquoteDangerStyles = css({
|
|
|
121
121
|
|
|
122
122
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
123
123
|
export const blockquoteSelectedNodeStyles = css({
|
|
124
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
125
|
-
'.ProseMirror': {
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
},
|
|
137
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
138
|
-
'&::-moz-selection, *::-moz-selection': {
|
|
139
|
-
backgroundColor: 'transparent'
|
|
140
|
-
}
|
|
141
|
-
}
|
|
124
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
125
|
+
'.ProseMirror blockquote.ak-editor-selected-node': {
|
|
126
|
+
background: "var(--ds-background-accent-blue-subtler, #CFE1FD)",
|
|
127
|
+
borderLeftColor: "var(--ds-border-selected, #1868DB)",
|
|
128
|
+
WebkitUserSelect: 'text',
|
|
129
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
130
|
+
'&::selection, *::selection': {
|
|
131
|
+
backgroundColor: 'transparent'
|
|
132
|
+
},
|
|
133
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
134
|
+
'&::-moz-selection, *::-moz-selection': {
|
|
135
|
+
backgroundColor: 'transparent'
|
|
142
136
|
}
|
|
143
137
|
}
|
|
144
138
|
});
|
|
@@ -330,4 +324,52 @@ export const blocktypeStyles_fg_platform_editor_nested_dnd_styles_changes = css(
|
|
|
330
324
|
'.ak-editor-content-area .ak-editor-content-area .ProseMirror blockquote': {
|
|
331
325
|
paddingLeft: "var(--ds-space-200, 16px)"
|
|
332
326
|
}
|
|
327
|
+
});
|
|
328
|
+
|
|
329
|
+
// This class applies when the node is selected directly or is included in the selected range
|
|
330
|
+
const isSelectedNode = '.ak-editor-selected-node';
|
|
331
|
+
const isOuterMostSelectedNode = `${isSelectedNode}:not(${isSelectedNode} *)`;
|
|
332
|
+
|
|
333
|
+
// This class applies when there is a node selection on this node directly
|
|
334
|
+
const isOnlySelectedNode = '.ProseMirror-selectednode';
|
|
335
|
+
const isOuterMostOnlySelectedNode = `${isOnlySelectedNode}:not(${isOnlySelectedNode} *)`;
|
|
336
|
+
const isList = ':is(ul, ol, div[data-node-type="actionList"])';
|
|
337
|
+
const isOuterMostList = `${isList}:not(${isList} *)`;
|
|
338
|
+
|
|
339
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
340
|
+
export const listSelectedNodeStyles = css({
|
|
341
|
+
// only apply selected styles to the outermost list to avoid nested selection styles for lists within lists
|
|
342
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-values
|
|
343
|
+
[`.ProseMirror ${isOuterMostList}${isOuterMostSelectedNode}`]: {
|
|
344
|
+
background: "var(--ds-background-accent-blue-subtler, #CFE1FD)",
|
|
345
|
+
WebkitUserSelect: 'text',
|
|
346
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
347
|
+
'&::selection, *::selection': {
|
|
348
|
+
backgroundColor: 'transparent'
|
|
349
|
+
},
|
|
350
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
351
|
+
'&::-moz-selection, *::-moz-selection': {
|
|
352
|
+
backgroundColor: 'transparent'
|
|
353
|
+
}
|
|
354
|
+
}
|
|
355
|
+
});
|
|
356
|
+
const isText = `:is(p, h1, h2, h3, h4, h5, h6)`;
|
|
357
|
+
const isRootText = `${isText}:not(${isList} ${isText})`;
|
|
358
|
+
|
|
359
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
360
|
+
export const textSelectedNodeStyles = css({
|
|
361
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-values
|
|
362
|
+
[`.ProseMirror ${isRootText}${isOuterMostOnlySelectedNode}`]: {
|
|
363
|
+
background: "var(--ds-background-accent-blue-subtler, #CFE1FD)",
|
|
364
|
+
WebkitUserSelect: 'text',
|
|
365
|
+
boxShadow: `0 -4px 0 ${"var(--ds-background-accent-blue-subtler, #CFE1FD)"}, 0 4px 0 ${"var(--ds-background-accent-blue-subtler, #CFE1FD)"}`,
|
|
366
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
367
|
+
'&::selection, *::selection': {
|
|
368
|
+
backgroundColor: 'transparent'
|
|
369
|
+
},
|
|
370
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
371
|
+
'&::-moz-selection, *::-moz-selection': {
|
|
372
|
+
backgroundColor: 'transparent'
|
|
373
|
+
}
|
|
374
|
+
}
|
|
333
375
|
});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export const name = "@atlaskit/editor-core";
|
|
2
|
-
export const version = "
|
|
2
|
+
export const version = "216.1.1";
|
|
@@ -23,7 +23,7 @@ import { annotationStyles } from './styles/annotationStyles';
|
|
|
23
23
|
import { backgroundColorStyles, textHighlightPaddingStyles } from './styles/backgroundColorStyles';
|
|
24
24
|
import { baseStyles, baseStylesMaxContainerWidthFixes, editorLargeGutterPuddingBaseStyles, editorLargeGutterPuddingBaseStylesEditorControls, editorLargeGutterPuddingReducedBaseStyles } from './styles/baseStyles';
|
|
25
25
|
import { blockMarksStyles } from './styles/blockMarksStyles';
|
|
26
|
-
import { blockquoteSelectedNodeStyles,
|
|
26
|
+
import { blockquoteDangerStyles, blockquoteSelectedNodeStyles, blockquoteZeroPadding, blocktypeStyles, blocktypeStyles_fg_platform_editor_nested_dnd_styles_changes, blocktypeStyles_fg_platform_editor_typography_ugc, blocktypeStyles_without_fg_platform_editor_typography_ugc, listSelectedNodeStyles, textSelectedNodeStyles } from './styles/blockTypeStyles';
|
|
27
27
|
import { codeBidiWarningStyles } from './styles/codeBidiWarningStyles';
|
|
28
28
|
import { codeBgColorStyles, codeBlockStyles, codeBlockStylesWithEmUnits, firstCodeBlockWithNoMargin, firstCodeBlockWithNoMarginOld } from './styles/codeBlockStyles';
|
|
29
29
|
import { codeMarkStyles } from './styles/codeMarkStyles';
|
|
@@ -60,7 +60,7 @@ import { shadowStyles } from './styles/shadowStyles';
|
|
|
60
60
|
import { editorControlsSmartCardStyles, linkingVisualRefreshV1Styles, showDiffDeletedNodeStyles, smartCardDiffStyles, smartCardStyles, smartCardStylesWithSearchMatch, smartCardStylesWithSearchMatchAndBlockMenuDangerStyles, smartCardStylesWithSearchMatchAndPreviewPanelResponsiveness, smartLinksInLivePagesStyles } from './styles/smartCardStyles';
|
|
61
61
|
import { statusDangerStyles, statusStyles, statusStylesMixin_fg_platform_component_visual_refresh, statusStylesMixin_fg_platform_component_visual_refresh_with_search_match, statusStylesMixin_without_fg_platform_component_visual_refresh, statusStylesMixin_without_fg_platform_component_visual_refresh_with_search_match } from './styles/statusStyles';
|
|
62
62
|
import { syncBlockStyles } from './styles/syncBlockStyles';
|
|
63
|
-
import { tableCommentEditorStyles, tableContainerOverflowY, tableContainerStyles,
|
|
63
|
+
import { tableCommentEditorStyles, tableContainerOverflowY, tableContainerStyles, tableEmptyRowStyles, tableLayoutFixes } from './styles/tableStyles';
|
|
64
64
|
import { decisionDangerStyles, decisionIconWithVisualRefresh, decisionStyles, getDenseTasksAndDecisionsStyles, taskItemStyles, taskItemStylesWithBlockTaskItem, tasksAndDecisionsStyles } from './styles/tasksAndDecisionsStyles';
|
|
65
65
|
import { telepointerColorAndCommonStyle, telepointerStyle } from './styles/telepointerStyles';
|
|
66
66
|
import { textColorStyles } from './styles/textColorStyles';
|
|
@@ -192,7 +192,11 @@ var EditorContentContainer = /*#__PURE__*/React.forwardRef(function (props, ref)
|
|
|
192
192
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
193
193
|
blocktypeStyles, expValEquals('platform_editor_block_menu', 'isEnabled', true) &&
|
|
194
194
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
195
|
-
blockquoteSelectedNodeStyles,
|
|
195
|
+
blockquoteSelectedNodeStyles, expValEquals('platform_editor_block_menu', 'isEnabled', true) &&
|
|
196
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
197
|
+
listSelectedNodeStyles, expValEquals('platform_editor_block_menu', 'isEnabled', true) &&
|
|
198
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
199
|
+
textSelectedNodeStyles, expVal('platform_editor_blockquote_zero_padding', 'isEnabled', false) ?
|
|
196
200
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
197
201
|
blockquoteZeroPadding : null,
|
|
198
202
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
1
2
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
2
3
|
import { css } from '@emotion/react';
|
|
3
4
|
// This style is needed to avoid Confluence's batch.css overrides that expand blockquote with extra padding after SSR.
|
|
@@ -121,24 +122,18 @@ export var blockquoteDangerStyles = css({
|
|
|
121
122
|
|
|
122
123
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
123
124
|
export var blockquoteSelectedNodeStyles = css({
|
|
124
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
125
|
-
'.ProseMirror': {
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
},
|
|
137
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
138
|
-
'&::-moz-selection, *::-moz-selection': {
|
|
139
|
-
backgroundColor: 'transparent'
|
|
140
|
-
}
|
|
141
|
-
}
|
|
125
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
126
|
+
'.ProseMirror blockquote.ak-editor-selected-node': {
|
|
127
|
+
background: "var(--ds-background-accent-blue-subtler, #CFE1FD)",
|
|
128
|
+
borderLeftColor: "var(--ds-border-selected, #1868DB)",
|
|
129
|
+
WebkitUserSelect: 'text',
|
|
130
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
131
|
+
'&::selection, *::selection': {
|
|
132
|
+
backgroundColor: 'transparent'
|
|
133
|
+
},
|
|
134
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
135
|
+
'&::-moz-selection, *::-moz-selection': {
|
|
136
|
+
backgroundColor: 'transparent'
|
|
142
137
|
}
|
|
143
138
|
}
|
|
144
139
|
});
|
|
@@ -330,4 +325,45 @@ export var blocktypeStyles_fg_platform_editor_nested_dnd_styles_changes = css({
|
|
|
330
325
|
'.ak-editor-content-area .ak-editor-content-area .ProseMirror blockquote': {
|
|
331
326
|
paddingLeft: "var(--ds-space-200, 16px)"
|
|
332
327
|
}
|
|
333
|
-
});
|
|
328
|
+
});
|
|
329
|
+
|
|
330
|
+
// This class applies when the node is selected directly or is included in the selected range
|
|
331
|
+
var isSelectedNode = '.ak-editor-selected-node';
|
|
332
|
+
var isOuterMostSelectedNode = "".concat(isSelectedNode, ":not(").concat(isSelectedNode, " *)");
|
|
333
|
+
|
|
334
|
+
// This class applies when there is a node selection on this node directly
|
|
335
|
+
var isOnlySelectedNode = '.ProseMirror-selectednode';
|
|
336
|
+
var isOuterMostOnlySelectedNode = "".concat(isOnlySelectedNode, ":not(").concat(isOnlySelectedNode, " *)");
|
|
337
|
+
var isList = ':is(ul, ol, div[data-node-type="actionList"])';
|
|
338
|
+
var isOuterMostList = "".concat(isList, ":not(").concat(isList, " *)");
|
|
339
|
+
|
|
340
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
341
|
+
export var listSelectedNodeStyles = css(_defineProperty({}, ".ProseMirror ".concat(isOuterMostList).concat(isOuterMostSelectedNode), {
|
|
342
|
+
background: "var(--ds-background-accent-blue-subtler, #CFE1FD)",
|
|
343
|
+
WebkitUserSelect: 'text',
|
|
344
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
345
|
+
'&::selection, *::selection': {
|
|
346
|
+
backgroundColor: 'transparent'
|
|
347
|
+
},
|
|
348
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
349
|
+
'&::-moz-selection, *::-moz-selection': {
|
|
350
|
+
backgroundColor: 'transparent'
|
|
351
|
+
}
|
|
352
|
+
}));
|
|
353
|
+
var isText = ":is(p, h1, h2, h3, h4, h5, h6)";
|
|
354
|
+
var isRootText = "".concat(isText, ":not(").concat(isList, " ").concat(isText, ")");
|
|
355
|
+
|
|
356
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
357
|
+
export var textSelectedNodeStyles = css(_defineProperty({}, ".ProseMirror ".concat(isRootText).concat(isOuterMostOnlySelectedNode), {
|
|
358
|
+
background: "var(--ds-background-accent-blue-subtler, #CFE1FD)",
|
|
359
|
+
WebkitUserSelect: 'text',
|
|
360
|
+
boxShadow: "0 -4px 0 ".concat("var(--ds-background-accent-blue-subtler, #CFE1FD)", ", 0 4px 0 ", "var(--ds-background-accent-blue-subtler, #CFE1FD)"),
|
|
361
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
362
|
+
'&::selection, *::selection': {
|
|
363
|
+
backgroundColor: 'transparent'
|
|
364
|
+
},
|
|
365
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors, @atlaskit/ui-styling-standard/no-nested-selectors
|
|
366
|
+
'&::-moz-selection, *::-moz-selection': {
|
|
367
|
+
backgroundColor: 'transparent'
|
|
368
|
+
}
|
|
369
|
+
}));
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export var name = "@atlaskit/editor-core";
|
|
2
|
-
export var version = "
|
|
2
|
+
export var version = "216.1.1";
|
|
@@ -6,3 +6,5 @@ export declare const blockquoteSelectedNodeStyles: SerializedStyles;
|
|
|
6
6
|
export declare const blocktypeStyles_fg_platform_editor_typography_ugc: SerializedStyles;
|
|
7
7
|
export declare const blocktypeStyles_without_fg_platform_editor_typography_ugc: SerializedStyles;
|
|
8
8
|
export declare const blocktypeStyles_fg_platform_editor_nested_dnd_styles_changes: SerializedStyles;
|
|
9
|
+
export declare const listSelectedNodeStyles: SerializedStyles;
|
|
10
|
+
export declare const textSelectedNodeStyles: SerializedStyles;
|
|
@@ -6,3 +6,5 @@ export declare const blockquoteSelectedNodeStyles: SerializedStyles;
|
|
|
6
6
|
export declare const blocktypeStyles_fg_platform_editor_typography_ugc: SerializedStyles;
|
|
7
7
|
export declare const blocktypeStyles_without_fg_platform_editor_typography_ugc: SerializedStyles;
|
|
8
8
|
export declare const blocktypeStyles_fg_platform_editor_nested_dnd_styles_changes: SerializedStyles;
|
|
9
|
+
export declare const listSelectedNodeStyles: SerializedStyles;
|
|
10
|
+
export declare const textSelectedNodeStyles: SerializedStyles;
|