@atlaskit/editor-core 203.11.3 → 203.11.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 CHANGED
@@ -1,5 +1,17 @@
1
1
  # @atlaskit/editor-core
2
2
 
3
+ ## 203.11.4
4
+
5
+ ### Patch Changes
6
+
7
+ - [#103354](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/103354)
8
+ [`129cb98043b09`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/129cb98043b09) -
9
+ TypeError coming from handleEditorFocus has been increasing significantly. We've added a null
10
+ check to stop this TypeError.
11
+ - [#102744](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/102744)
12
+ [`289c0169e410a`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/289c0169e410a) -
13
+ ED-26243 Cleaned up platform_editor_drag_and_drop_target_v2 FG
14
+
3
15
  ## 203.11.3
4
16
 
5
17
  ### Patch Changes
@@ -6,39 +6,41 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.handleEditorFocus = handleEditorFocus;
7
7
  var _state = require("@atlaskit/editor-prosemirror/state");
8
8
  function handleEditorFocus(view) {
9
- if (view.hasFocus()) {
9
+ if (view !== null && view !== void 0 && view.hasFocus()) {
10
10
  return;
11
11
  }
12
12
  return window.setTimeout(function () {
13
- if (view.hasFocus()) {
13
+ if (view !== null && view !== void 0 && view.hasFocus()) {
14
14
  return;
15
15
  }
16
16
  if (!window.getSelection) {
17
- view.focus();
17
+ view === null || view === void 0 || view.focus();
18
18
  return;
19
19
  }
20
20
  var domSelection = window.getSelection();
21
21
  if (!domSelection || domSelection.rangeCount === 0) {
22
- view.focus();
22
+ view === null || view === void 0 || view.focus();
23
23
  return;
24
24
  }
25
25
  var range = domSelection.getRangeAt(0);
26
26
  // if selection is outside editor focus and exit
27
- if (range.startContainer.contains(view.dom)) {
27
+ if (view && range.startContainer.contains(view.dom)) {
28
28
  view.focus();
29
29
  return;
30
30
  }
31
31
  // set cursor/selection and focus
32
- var anchor = view.posAtDOM(range.startContainer, range.startOffset);
33
- var head = view.posAtDOM(range.endContainer, range.endOffset);
32
+ var anchor = view === null || view === void 0 ? void 0 : view.posAtDOM(range.startContainer, range.startOffset);
33
+ var head = view === null || view === void 0 ? void 0 : view.posAtDOM(range.endContainer, range.endOffset);
34
34
  // if anchor or head < 0 focus and exit
35
- if (anchor < 0 || head < 0) {
36
- view.focus();
35
+ if (anchor && anchor < 0 || head && head < 0) {
36
+ view === null || view === void 0 || view.focus();
37
37
  return;
38
38
  }
39
- var selection = _state.TextSelection.create(view.state.doc, anchor, head);
40
- var tr = view.state.tr.setSelection(selection);
41
- view.dispatch(tr);
42
- view.focus();
39
+ if (view && anchor) {
40
+ var selection = _state.TextSelection.create(view.state.doc, anchor, head);
41
+ var tr = view.state.tr.setSelection(selection);
42
+ view.dispatch(tr);
43
+ view.focus();
44
+ }
43
45
  }, 0);
44
46
  }
@@ -69,5 +69,5 @@ var layoutResponsiveStyles = function layoutResponsiveStyles(viewMode) {
69
69
 
70
70
  // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation
71
71
  var layoutStyles = exports.layoutStyles = function layoutStyles(viewMode) {
72
- return (0, _react.css)(_templateObject14 || (_templateObject14 = (0, _taggedTemplateLiteral2.default)(["\n\t.ProseMirror {\n\t\t", "\n\t\t[data-layout-section] {\n\t\t\t// TODO: Migrate away from gridSize\n\t\t\t// Recommendation: 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\t", "\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, _experiments.editorExperiment)('nested-dnd', true) && (0, _platformFeatureFlags.fg)('platform_editor_advanced_layouts_post_fix_patch_2') ? 8 : 0), _editorSharedStyles.akEditorSwoopCubicBezier, viewMode === 'view' ? 'default' : 'pointer', (0, _platformFeatureFlags.fg)('platform_editor_drag_and_drop_target_v2') ? 'position: relative;' : '', viewMode === 'view' || (0, _experiments.editorExperiment)('advanced_layouts', true) ? 0 : _editorSharedStyles.akEditorSelectedBorderSize, "var(--ds-border, #091E4224)", _styles.LAYOUT_COLUMN_PADDING, _styles.LAYOUT_COLUMN_PADDING + ((0, _experiments.editorExperiment)('nested-dnd', true) ? 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)('nested-dnd', true) && (0, _experiments.editorExperiment)('advanced_layouts', false) && ".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}"));
72
+ return (0, _react.css)(_templateObject14 || (_templateObject14 = (0, _taggedTemplateLiteral2.default)(["\n\t.ProseMirror {\n\t\t", "\n\t\t[data-layout-section] {\n\t\t\t// TODO: Migrate away from gridSize\n\t\t\t// Recommendation: 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, _experiments.editorExperiment)('nested-dnd', true) && (0, _platformFeatureFlags.fg)('platform_editor_advanced_layouts_post_fix_patch_2') ? 8 : 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, _experiments.editorExperiment)('nested-dnd', true) ? 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)('nested-dnd', true) && (0, _experiments.editorExperiment)('advanced_layouts', false) && ".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}"));
73
73
  };
@@ -5,4 +5,4 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.version = exports.name = void 0;
7
7
  var name = exports.name = "@atlaskit/editor-core";
8
- var version = exports.version = "203.11.3";
8
+ var version = exports.version = "203.11.4";
@@ -1,38 +1,40 @@
1
1
  import { TextSelection } from '@atlaskit/editor-prosemirror/state';
2
2
  export function handleEditorFocus(view) {
3
- if (view.hasFocus()) {
3
+ if (view !== null && view !== void 0 && view.hasFocus()) {
4
4
  return;
5
5
  }
6
6
  return window.setTimeout(() => {
7
- if (view.hasFocus()) {
7
+ if (view !== null && view !== void 0 && view.hasFocus()) {
8
8
  return;
9
9
  }
10
10
  if (!window.getSelection) {
11
- view.focus();
11
+ view === null || view === void 0 ? void 0 : view.focus();
12
12
  return;
13
13
  }
14
14
  const domSelection = window.getSelection();
15
15
  if (!domSelection || domSelection.rangeCount === 0) {
16
- view.focus();
16
+ view === null || view === void 0 ? void 0 : view.focus();
17
17
  return;
18
18
  }
19
19
  const range = domSelection.getRangeAt(0);
20
20
  // if selection is outside editor focus and exit
21
- if (range.startContainer.contains(view.dom)) {
21
+ if (view && range.startContainer.contains(view.dom)) {
22
22
  view.focus();
23
23
  return;
24
24
  }
25
25
  // set cursor/selection and focus
26
- const anchor = view.posAtDOM(range.startContainer, range.startOffset);
27
- const head = view.posAtDOM(range.endContainer, range.endOffset);
26
+ const anchor = view === null || view === void 0 ? void 0 : view.posAtDOM(range.startContainer, range.startOffset);
27
+ const head = view === null || view === void 0 ? void 0 : view.posAtDOM(range.endContainer, range.endOffset);
28
28
  // if anchor or head < 0 focus and exit
29
- if (anchor < 0 || head < 0) {
30
- view.focus();
29
+ if (anchor && anchor < 0 || head && head < 0) {
30
+ view === null || view === void 0 ? void 0 : view.focus();
31
31
  return;
32
32
  }
33
- const selection = TextSelection.create(view.state.doc, anchor, head);
34
- const tr = view.state.tr.setSelection(selection);
35
- view.dispatch(tr);
36
- view.focus();
33
+ if (view && anchor) {
34
+ const selection = TextSelection.create(view.state.doc, anchor, head);
35
+ const tr = view.state.tr.setSelection(selection);
36
+ view.dispatch(tr);
37
+ view.focus();
38
+ }
37
39
  }, 0);
38
40
  }
@@ -314,7 +314,7 @@ export const layoutStyles = viewMode => css`
314
314
  /* Inner cursor located 26px from left */
315
315
  [data-layout-column] {
316
316
  flex: 1;
317
- ${fg('platform_editor_drag_and_drop_target_v2') ? 'position: relative;' : ''}
317
+ position: relative;
318
318
 
319
319
  min-width: 0;
320
320
  /* disable 4 borders when in view mode and advanced layouts is on */
@@ -1,2 +1,2 @@
1
1
  export const name = "@atlaskit/editor-core";
2
- export const version = "203.11.3";
2
+ export const version = "203.11.4";
@@ -1,38 +1,40 @@
1
1
  import { TextSelection } from '@atlaskit/editor-prosemirror/state';
2
2
  export function handleEditorFocus(view) {
3
- if (view.hasFocus()) {
3
+ if (view !== null && view !== void 0 && view.hasFocus()) {
4
4
  return;
5
5
  }
6
6
  return window.setTimeout(function () {
7
- if (view.hasFocus()) {
7
+ if (view !== null && view !== void 0 && view.hasFocus()) {
8
8
  return;
9
9
  }
10
10
  if (!window.getSelection) {
11
- view.focus();
11
+ view === null || view === void 0 || view.focus();
12
12
  return;
13
13
  }
14
14
  var domSelection = window.getSelection();
15
15
  if (!domSelection || domSelection.rangeCount === 0) {
16
- view.focus();
16
+ view === null || view === void 0 || view.focus();
17
17
  return;
18
18
  }
19
19
  var range = domSelection.getRangeAt(0);
20
20
  // if selection is outside editor focus and exit
21
- if (range.startContainer.contains(view.dom)) {
21
+ if (view && range.startContainer.contains(view.dom)) {
22
22
  view.focus();
23
23
  return;
24
24
  }
25
25
  // set cursor/selection and focus
26
- var anchor = view.posAtDOM(range.startContainer, range.startOffset);
27
- var head = view.posAtDOM(range.endContainer, range.endOffset);
26
+ var anchor = view === null || view === void 0 ? void 0 : view.posAtDOM(range.startContainer, range.startOffset);
27
+ var head = view === null || view === void 0 ? void 0 : view.posAtDOM(range.endContainer, range.endOffset);
28
28
  // if anchor or head < 0 focus and exit
29
- if (anchor < 0 || head < 0) {
30
- view.focus();
29
+ if (anchor && anchor < 0 || head && head < 0) {
30
+ view === null || view === void 0 || view.focus();
31
31
  return;
32
32
  }
33
- var selection = TextSelection.create(view.state.doc, anchor, head);
34
- var tr = view.state.tr.setSelection(selection);
35
- view.dispatch(tr);
36
- view.focus();
33
+ if (view && anchor) {
34
+ var selection = TextSelection.create(view.state.doc, anchor, head);
35
+ var tr = view.state.tr.setSelection(selection);
36
+ view.dispatch(tr);
37
+ view.focus();
38
+ }
37
39
  }, 0);
38
40
  }
@@ -63,5 +63,5 @@ var layoutResponsiveStyles = function layoutResponsiveStyles(viewMode) {
63
63
 
64
64
  // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation
65
65
  export var layoutStyles = function layoutStyles(viewMode) {
66
- return css(_templateObject14 || (_templateObject14 = _taggedTemplateLiteral(["\n\t.ProseMirror {\n\t\t", "\n\t\t[data-layout-section] {\n\t\t\t// TODO: Migrate away from gridSize\n\t\t\t// Recommendation: 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\t", "\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 + (editorExperiment('nested-dnd', true) && fg('platform_editor_advanced_layouts_post_fix_patch_2') ? 8 : 0), akEditorSwoopCubicBezier, viewMode === 'view' ? 'default' : 'pointer', fg('platform_editor_drag_and_drop_target_v2') ? 'position: relative;' : '', viewMode === 'view' || editorExperiment('advanced_layouts', true) ? 0 : akEditorSelectedBorderSize, "var(--ds-border, #091E4224)", LAYOUT_COLUMN_PADDING, LAYOUT_COLUMN_PADDING + (editorExperiment('nested-dnd', true) ? 8 : 0), firstNodeWithNotMarginTop(), layoutColumnStyles(), editorExperiment('advanced_layouts', true) ? layoutWithSeparatorBorderStyles(viewMode) : layoutBorderStyles(viewMode), editorExperiment('advanced_layouts', true) && layoutResponsiveStyles(viewMode), TableCssClassName.TABLE_CONTAINER, tableMarginFullWidthMode, editorExperiment('nested-dnd', true) && editorExperiment('advanced_layouts', false) && ".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}"));
66
+ return css(_templateObject14 || (_templateObject14 = _taggedTemplateLiteral(["\n\t.ProseMirror {\n\t\t", "\n\t\t[data-layout-section] {\n\t\t\t// TODO: Migrate away from gridSize\n\t\t\t// Recommendation: 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 + (editorExperiment('nested-dnd', true) && fg('platform_editor_advanced_layouts_post_fix_patch_2') ? 8 : 0), akEditorSwoopCubicBezier, viewMode === 'view' ? 'default' : 'pointer', viewMode === 'view' || editorExperiment('advanced_layouts', true) ? 0 : akEditorSelectedBorderSize, "var(--ds-border, #091E4224)", LAYOUT_COLUMN_PADDING, LAYOUT_COLUMN_PADDING + (editorExperiment('nested-dnd', true) ? 8 : 0), firstNodeWithNotMarginTop(), layoutColumnStyles(), editorExperiment('advanced_layouts', true) ? layoutWithSeparatorBorderStyles(viewMode) : layoutBorderStyles(viewMode), editorExperiment('advanced_layouts', true) && layoutResponsiveStyles(viewMode), TableCssClassName.TABLE_CONTAINER, tableMarginFullWidthMode, editorExperiment('nested-dnd', true) && editorExperiment('advanced_layouts', false) && ".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}"));
67
67
  };
@@ -1,2 +1,2 @@
1
1
  export var name = "@atlaskit/editor-core";
2
- export var version = "203.11.3";
2
+ export var version = "203.11.4";
@@ -1,2 +1,2 @@
1
1
  import { type EditorView } from '@atlaskit/editor-prosemirror/view';
2
- export declare function handleEditorFocus(view: EditorView): number | undefined;
2
+ export declare function handleEditorFocus(view: EditorView | null): number | undefined;
@@ -1,2 +1,2 @@
1
1
  import { type EditorView } from '@atlaskit/editor-prosemirror/view';
2
- export declare function handleEditorFocus(view: EditorView): number | undefined;
2
+ export declare function handleEditorFocus(view: EditorView | null): number | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-core",
3
- "version": "203.11.3",
3
+ "version": "203.11.4",
4
4
  "description": "A package contains Atlassian editor core functionality",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -43,7 +43,7 @@
43
43
  "@atlaskit/analytics-next": "^10.2.0",
44
44
  "@atlaskit/analytics-next-stable-react-context": "1.0.1",
45
45
  "@atlaskit/button": "^20.3.0",
46
- "@atlaskit/editor-common": "^99.2.0",
46
+ "@atlaskit/editor-common": "^99.3.0",
47
47
  "@atlaskit/editor-json-transformer": "^8.21.0",
48
48
  "@atlaskit/editor-plugin-quick-insert": "1.8.3",
49
49
  "@atlaskit/editor-plugins": "^6.4.0",
@@ -55,8 +55,8 @@
55
55
  "@atlaskit/mention": "^23.8.0",
56
56
  "@atlaskit/platform-feature-flags": "^0.3.0",
57
57
  "@atlaskit/task-decision": "^17.11.0",
58
- "@atlaskit/tmp-editor-statsig": "^2.35.0",
59
- "@atlaskit/tokens": "^3.0.0",
58
+ "@atlaskit/tmp-editor-statsig": "^2.36.0",
59
+ "@atlaskit/tokens": "^3.1.0",
60
60
  "@atlaskit/tooltip": "^19.0.0",
61
61
  "@atlaskit/width-detector": "^4.3.0",
62
62
  "@babel/runtime": "^7.0.0",
@@ -250,10 +250,6 @@
250
250
  "type:": "boolean",
251
251
  "referenceOnly": true
252
252
  },
253
- "platform_editor_drag_and_drop_target_v2": {
254
- "type": "boolean",
255
- "referenceOnly": true
256
- },
257
253
  "platform_editor_element_dnd_nested_fix_patch_5": {
258
254
  "type": "boolean",
259
255
  "referenceOnly": true
@@ -400,6 +396,14 @@
400
396
  },
401
397
  "platform_editor_ease_of_use_metrics": {
402
398
  "type": "boolean"
399
+ },
400
+ "platform_editor_nested_tables_renderer_colgroup": {
401
+ "type": "boolean",
402
+ "referenceOnly": true
403
+ },
404
+ "platform_editor_table_use_shared_state_hook_fg": {
405
+ "type": "boolean",
406
+ "referenceOnly": true
403
407
  }
404
408
  },
405
409
  "stricter": {