@atlaskit/editor-core 203.11.3 → 203.11.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,25 @@
1
1
  # @atlaskit/editor-core
2
2
 
3
+ ## 203.11.5
4
+
5
+ ### Patch Changes
6
+
7
+ - [#103674](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/103674)
8
+ [`5cd5e35c2e27c`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/5cd5e35c2e27c) -
9
+ Cleanup flag that gated change to PluginSlot using a React18 compatible component
10
+
11
+ ## 203.11.4
12
+
13
+ ### Patch Changes
14
+
15
+ - [#103354](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/103354)
16
+ [`129cb98043b09`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/129cb98043b09) -
17
+ TypeError coming from handleEditorFocus has been increasing significantly. We've added a null
18
+ check to stop this TypeError.
19
+ - [#102744](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/102744)
20
+ [`289c0169e410a`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/289c0169e410a) -
21
+ ED-26243 Cleaned up platform_editor_drag_and_drop_target_v2 FG
22
+
3
23
  ## 203.11.3
4
24
 
5
25
  ### 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
  };
@@ -4,159 +4,23 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
4
4
  Object.defineProperty(exports, "__esModule", {
5
5
  value: true
6
6
  });
7
- exports.default = PluginSlotDefault;
8
- var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
9
- var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
10
- var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
11
- var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
12
- var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
13
- var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
7
+ exports.default = void 0;
14
8
  var _react = _interopRequireDefault(require("react"));
15
9
  var _react2 = require("@emotion/react");
16
10
  var _isEqual = _interopRequireDefault(require("lodash/isEqual"));
17
11
  var _analytics = require("@atlaskit/editor-common/analytics");
18
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
19
- var _whichTransitionEvent = require("../../utils/whichTransitionEvent");
20
12
  var _ErrorBoundary = require("../ErrorBoundary");
21
13
  var _mountPluginHooks = require("./mount-plugin-hooks");
22
- function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); }
23
- function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /**
14
+ /**
24
15
  * @jsxRuntime classic
25
16
  * @jsx jsx
26
- */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
17
+ */
18
+
19
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
20
+
27
21
  var pluginsComponentsWrapper = (0, _react2.css)({
28
22
  display: 'flex'
29
23
  });
30
- // Ignored via go/ees005
31
- // eslint-disable-next-line @repo/internal/react/no-class-components
32
- var PluginSlotLegacy = /*#__PURE__*/function (_React$Component) {
33
- function PluginSlotLegacy() {
34
- var _this;
35
- (0, _classCallCheck2.default)(this, PluginSlotLegacy);
36
- for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
37
- args[_key] = arguments[_key];
38
- }
39
- _this = _callSuper(this, PluginSlotLegacy, [].concat(args));
40
- (0, _defineProperty2.default)(_this, "transitionEvent", (0, _whichTransitionEvent.whichTransitionEvent)());
41
- (0, _defineProperty2.default)(_this, "forceComponentUpdate", function (event) {
42
- // Only trigger an update if the transition is on a property containing `width`
43
- // This will cater for media and the content area itself currently.
44
- if (event.propertyName.includes('width')) {
45
- _this.forceUpdate();
46
- }
47
- });
48
- (0, _defineProperty2.default)(_this, "removeModeChangeListener", function (contentArea) {
49
- if (contentArea && _this.transitionEvent) {
50
- // Ignored via go/ees005
51
- // eslint-disable-next-line @repo/internal/dom-events/no-unsafe-event-listeners
52
- contentArea.removeEventListener(_this.transitionEvent, _this.forceComponentUpdate);
53
- }
54
- });
55
- (0, _defineProperty2.default)(_this, "addModeChangeListener", function (contentArea) {
56
- if (contentArea && _this.transitionEvent) {
57
- /**
58
- * Update the plugin components once the transition
59
- * to full width / default mode completes
60
- */
61
- // Ignored via go/ees005
62
- // eslint-disable-next-line @repo/internal/dom-events/no-unsafe-event-listeners
63
- contentArea.addEventListener(_this.transitionEvent, _this.forceComponentUpdate);
64
- }
65
- });
66
- return _this;
67
- }
68
- (0, _inherits2.default)(PluginSlotLegacy, _React$Component);
69
- return (0, _createClass2.default)(PluginSlotLegacy, [{
70
- key: "shouldComponentUpdate",
71
- value: function shouldComponentUpdate(nextProps) {
72
- var _this$props = this.props,
73
- editorView = _this$props.editorView,
74
- editorActions = _this$props.editorActions,
75
- items = _this$props.items,
76
- providerFactory = _this$props.providerFactory,
77
- eventDispatcher = _this$props.eventDispatcher,
78
- popupsMountPoint = _this$props.popupsMountPoint,
79
- popupsBoundariesElement = _this$props.popupsBoundariesElement,
80
- popupsScrollableElement = _this$props.popupsScrollableElement,
81
- containerElement = _this$props.containerElement,
82
- disabled = _this$props.disabled,
83
- wrapperElement = _this$props.wrapperElement;
84
- return !(nextProps.editorView === editorView && nextProps.editorActions === editorActions && nextProps.items === items && nextProps.providerFactory === providerFactory && nextProps.eventDispatcher === eventDispatcher && nextProps.popupsMountPoint === popupsMountPoint && nextProps.popupsBoundariesElement === popupsBoundariesElement && nextProps.popupsScrollableElement === popupsScrollableElement && nextProps.containerElement === containerElement && nextProps.disabled === disabled && nextProps.wrapperElement === wrapperElement);
85
- }
86
- }, {
87
- key: "componentDidMount",
88
- value: function componentDidMount() {
89
- this.addModeChangeListener(this.props.contentArea);
90
- }
91
- }, {
92
- key: "UNSAFE_componentWillReceiveProps",
93
- value: function UNSAFE_componentWillReceiveProps(nextProps) {
94
- if (this.props.contentArea !== nextProps.contentArea) {
95
- this.removeModeChangeListener(this.props.contentArea);
96
- this.addModeChangeListener(nextProps.contentArea);
97
- }
98
- }
99
- }, {
100
- key: "componentWillUnmount",
101
- value: function componentWillUnmount() {
102
- this.removeModeChangeListener(this.props.contentArea);
103
- }
104
- }, {
105
- key: "render",
106
- value: function render() {
107
- var _this$props2 = this.props,
108
- items = _this$props2.items,
109
- editorView = _this$props2.editorView,
110
- editorActions = _this$props2.editorActions,
111
- eventDispatcher = _this$props2.eventDispatcher,
112
- providerFactory = _this$props2.providerFactory,
113
- appearance = _this$props2.appearance,
114
- popupsMountPoint = _this$props2.popupsMountPoint,
115
- popupsBoundariesElement = _this$props2.popupsBoundariesElement,
116
- popupsScrollableElement = _this$props2.popupsScrollableElement,
117
- containerElement = _this$props2.containerElement,
118
- disabled = _this$props2.disabled,
119
- dispatchAnalyticsEvent = _this$props2.dispatchAnalyticsEvent,
120
- wrapperElement = _this$props2.wrapperElement,
121
- pluginHooks = _this$props2.pluginHooks;
122
- if (!items && !pluginHooks || !editorView) {
123
- return null;
124
- }
125
- return (0, _react2.jsx)(_ErrorBoundary.ErrorBoundary, {
126
- component: _analytics.ACTION_SUBJECT.PLUGIN_SLOT,
127
- fallbackComponent: null
128
- }, (0, _react2.jsx)(_mountPluginHooks.MountPluginHooks, {
129
- editorView: editorView,
130
- pluginHooks: pluginHooks,
131
- containerElement: containerElement
132
- }), (0, _react2.jsx)("div", {
133
- css: pluginsComponentsWrapper
134
- }, items === null || items === void 0 ? void 0 : items.map(function (component, key) {
135
- var props = {
136
- key: key
137
- };
138
- var element = component({
139
- editorView: editorView,
140
- editorActions: editorActions,
141
- eventDispatcher: eventDispatcher,
142
- providerFactory: providerFactory,
143
- dispatchAnalyticsEvent: dispatchAnalyticsEvent,
144
- // Ignored via go/ees005
145
- // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
146
- appearance: appearance,
147
- popupsMountPoint: popupsMountPoint,
148
- popupsBoundariesElement: popupsBoundariesElement,
149
- popupsScrollableElement: popupsScrollableElement,
150
- containerElement: containerElement,
151
- disabled: disabled,
152
- wrapperElement: wrapperElement
153
- });
154
- return element && /*#__PURE__*/_react.default.cloneElement(element, props);
155
- })));
156
- }
157
- }]);
158
- }(_react.default.Component);
159
- (0, _defineProperty2.default)(PluginSlotLegacy, "displayName", 'PluginSlot');
160
24
  var PluginSlot = function PluginSlot(_ref) {
161
25
  var items = _ref.items,
162
26
  editorView = _ref.editorView,
@@ -207,57 +71,6 @@ var PluginSlot = function PluginSlot(_ref) {
207
71
  return element && /*#__PURE__*/_react.default.cloneElement(element, props);
208
72
  })));
209
73
  };
210
- var PluginSlotNew = /*#__PURE__*/_react.default.memo(PluginSlot, _isEqual.default);
211
- PluginSlotNew.displayName = 'PluginSlot';
212
- function PluginSlotDefault(_ref2) {
213
- var items = _ref2.items,
214
- editorView = _ref2.editorView,
215
- editorActions = _ref2.editorActions,
216
- eventDispatcher = _ref2.eventDispatcher,
217
- providerFactory = _ref2.providerFactory,
218
- appearance = _ref2.appearance,
219
- popupsMountPoint = _ref2.popupsMountPoint,
220
- popupsBoundariesElement = _ref2.popupsBoundariesElement,
221
- popupsScrollableElement = _ref2.popupsScrollableElement,
222
- containerElement = _ref2.containerElement,
223
- disabled = _ref2.disabled,
224
- dispatchAnalyticsEvent = _ref2.dispatchAnalyticsEvent,
225
- wrapperElement = _ref2.wrapperElement,
226
- pluginHooks = _ref2.pluginHooks,
227
- contentArea = _ref2.contentArea;
228
- if ((0, _platformFeatureFlags.fg)('platform_editor_react_18_plugin_slot')) {
229
- return (0, _react2.jsx)(PluginSlotNew, {
230
- items: items,
231
- editorView: editorView,
232
- editorActions: editorActions,
233
- eventDispatcher: eventDispatcher,
234
- providerFactory: providerFactory,
235
- appearance: appearance,
236
- popupsMountPoint: popupsMountPoint,
237
- popupsBoundariesElement: popupsBoundariesElement,
238
- popupsScrollableElement: popupsScrollableElement,
239
- containerElement: containerElement,
240
- disabled: disabled,
241
- dispatchAnalyticsEvent: dispatchAnalyticsEvent,
242
- wrapperElement: wrapperElement,
243
- pluginHooks: pluginHooks
244
- });
245
- }
246
- return (0, _react2.jsx)(PluginSlotLegacy, {
247
- contentArea: contentArea,
248
- items: items,
249
- editorView: editorView,
250
- editorActions: editorActions,
251
- eventDispatcher: eventDispatcher,
252
- providerFactory: providerFactory,
253
- appearance: appearance,
254
- popupsMountPoint: popupsMountPoint,
255
- popupsBoundariesElement: popupsBoundariesElement,
256
- popupsScrollableElement: popupsScrollableElement,
257
- containerElement: containerElement,
258
- disabled: disabled,
259
- dispatchAnalyticsEvent: dispatchAnalyticsEvent,
260
- wrapperElement: wrapperElement,
261
- pluginHooks: pluginHooks
262
- });
263
- }
74
+ var PluginSlotComponent = /*#__PURE__*/_react.default.memo(PluginSlot, _isEqual.default);
75
+ PluginSlotComponent.displayName = 'PluginSlot';
76
+ var _default = exports.default = PluginSlotComponent;
@@ -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.5";
@@ -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,4 +1,3 @@
1
- import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
1
  /**
3
2
  * @jsxRuntime classic
4
3
  * @jsx jsx
@@ -9,127 +8,11 @@ import React from 'react';
9
8
  import { css, jsx } from '@emotion/react';
10
9
  import isEqual from 'lodash/isEqual';
11
10
  import { ACTION_SUBJECT } from '@atlaskit/editor-common/analytics';
12
- import { fg } from '@atlaskit/platform-feature-flags';
13
- import { whichTransitionEvent } from '../../utils/whichTransitionEvent';
14
11
  import { ErrorBoundary } from '../ErrorBoundary';
15
12
  import { MountPluginHooks } from './mount-plugin-hooks';
16
13
  const pluginsComponentsWrapper = css({
17
14
  display: 'flex'
18
15
  });
19
- // Ignored via go/ees005
20
- // eslint-disable-next-line @repo/internal/react/no-class-components
21
- class PluginSlotLegacy extends React.Component {
22
- constructor(...args) {
23
- super(...args);
24
- _defineProperty(this, "transitionEvent", whichTransitionEvent());
25
- _defineProperty(this, "forceComponentUpdate", event => {
26
- // Only trigger an update if the transition is on a property containing `width`
27
- // This will cater for media and the content area itself currently.
28
- if (event.propertyName.includes('width')) {
29
- this.forceUpdate();
30
- }
31
- });
32
- _defineProperty(this, "removeModeChangeListener", contentArea => {
33
- if (contentArea && this.transitionEvent) {
34
- // Ignored via go/ees005
35
- // eslint-disable-next-line @repo/internal/dom-events/no-unsafe-event-listeners
36
- contentArea.removeEventListener(this.transitionEvent, this.forceComponentUpdate);
37
- }
38
- });
39
- _defineProperty(this, "addModeChangeListener", contentArea => {
40
- if (contentArea && this.transitionEvent) {
41
- /**
42
- * Update the plugin components once the transition
43
- * to full width / default mode completes
44
- */
45
- // Ignored via go/ees005
46
- // eslint-disable-next-line @repo/internal/dom-events/no-unsafe-event-listeners
47
- contentArea.addEventListener(this.transitionEvent, this.forceComponentUpdate);
48
- }
49
- });
50
- }
51
- shouldComponentUpdate(nextProps) {
52
- const {
53
- editorView,
54
- editorActions,
55
- items,
56
- providerFactory,
57
- eventDispatcher,
58
- popupsMountPoint,
59
- popupsBoundariesElement,
60
- popupsScrollableElement,
61
- containerElement,
62
- disabled,
63
- wrapperElement
64
- } = this.props;
65
- return !(nextProps.editorView === editorView && nextProps.editorActions === editorActions && nextProps.items === items && nextProps.providerFactory === providerFactory && nextProps.eventDispatcher === eventDispatcher && nextProps.popupsMountPoint === popupsMountPoint && nextProps.popupsBoundariesElement === popupsBoundariesElement && nextProps.popupsScrollableElement === popupsScrollableElement && nextProps.containerElement === containerElement && nextProps.disabled === disabled && nextProps.wrapperElement === wrapperElement);
66
- }
67
- componentDidMount() {
68
- this.addModeChangeListener(this.props.contentArea);
69
- }
70
- UNSAFE_componentWillReceiveProps(nextProps) {
71
- if (this.props.contentArea !== nextProps.contentArea) {
72
- this.removeModeChangeListener(this.props.contentArea);
73
- this.addModeChangeListener(nextProps.contentArea);
74
- }
75
- }
76
- componentWillUnmount() {
77
- this.removeModeChangeListener(this.props.contentArea);
78
- }
79
- render() {
80
- const {
81
- items,
82
- editorView,
83
- editorActions,
84
- eventDispatcher,
85
- providerFactory,
86
- appearance,
87
- popupsMountPoint,
88
- popupsBoundariesElement,
89
- popupsScrollableElement,
90
- containerElement,
91
- disabled,
92
- dispatchAnalyticsEvent,
93
- wrapperElement,
94
- pluginHooks
95
- } = this.props;
96
- if (!items && !pluginHooks || !editorView) {
97
- return null;
98
- }
99
- return jsx(ErrorBoundary, {
100
- component: ACTION_SUBJECT.PLUGIN_SLOT,
101
- fallbackComponent: null
102
- }, jsx(MountPluginHooks, {
103
- editorView: editorView,
104
- pluginHooks: pluginHooks,
105
- containerElement: containerElement
106
- }), jsx("div", {
107
- css: pluginsComponentsWrapper
108
- }, items === null || items === void 0 ? void 0 : items.map((component, key) => {
109
- const props = {
110
- key
111
- };
112
- const element = component({
113
- editorView: editorView,
114
- editorActions: editorActions,
115
- eventDispatcher: eventDispatcher,
116
- providerFactory,
117
- dispatchAnalyticsEvent,
118
- // Ignored via go/ees005
119
- // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
120
- appearance: appearance,
121
- popupsMountPoint,
122
- popupsBoundariesElement,
123
- popupsScrollableElement,
124
- containerElement,
125
- disabled,
126
- wrapperElement
127
- });
128
- return element && /*#__PURE__*/React.cloneElement(element, props);
129
- })));
130
- }
131
- }
132
- _defineProperty(PluginSlotLegacy, "displayName", 'PluginSlot');
133
16
  const PluginSlot = ({
134
17
  items,
135
18
  editorView,
@@ -181,58 +64,6 @@ const PluginSlot = ({
181
64
  return element && /*#__PURE__*/React.cloneElement(element, props);
182
65
  })));
183
66
  };
184
- const PluginSlotNew = /*#__PURE__*/React.memo(PluginSlot, isEqual);
185
- PluginSlotNew.displayName = 'PluginSlot';
186
- export default function PluginSlotDefault({
187
- items,
188
- editorView,
189
- editorActions,
190
- eventDispatcher,
191
- providerFactory,
192
- appearance,
193
- popupsMountPoint,
194
- popupsBoundariesElement,
195
- popupsScrollableElement,
196
- containerElement,
197
- disabled,
198
- dispatchAnalyticsEvent,
199
- wrapperElement,
200
- pluginHooks,
201
- contentArea
202
- }) {
203
- if (fg('platform_editor_react_18_plugin_slot')) {
204
- return jsx(PluginSlotNew, {
205
- items: items,
206
- editorView: editorView,
207
- editorActions: editorActions,
208
- eventDispatcher: eventDispatcher,
209
- providerFactory: providerFactory,
210
- appearance: appearance,
211
- popupsMountPoint: popupsMountPoint,
212
- popupsBoundariesElement: popupsBoundariesElement,
213
- popupsScrollableElement: popupsScrollableElement,
214
- containerElement: containerElement,
215
- disabled: disabled,
216
- dispatchAnalyticsEvent: dispatchAnalyticsEvent,
217
- wrapperElement: wrapperElement,
218
- pluginHooks: pluginHooks
219
- });
220
- }
221
- return jsx(PluginSlotLegacy, {
222
- contentArea: contentArea,
223
- items: items,
224
- editorView: editorView,
225
- editorActions: editorActions,
226
- eventDispatcher: eventDispatcher,
227
- providerFactory: providerFactory,
228
- appearance: appearance,
229
- popupsMountPoint: popupsMountPoint,
230
- popupsBoundariesElement: popupsBoundariesElement,
231
- popupsScrollableElement: popupsScrollableElement,
232
- containerElement: containerElement,
233
- disabled: disabled,
234
- dispatchAnalyticsEvent: dispatchAnalyticsEvent,
235
- wrapperElement: wrapperElement,
236
- pluginHooks: pluginHooks
237
- });
238
- }
67
+ const PluginSlotComponent = /*#__PURE__*/React.memo(PluginSlot, isEqual);
68
+ PluginSlotComponent.displayName = 'PluginSlot';
69
+ export default PluginSlotComponent;
@@ -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.5";
@@ -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,11 +1,3 @@
1
- import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
2
- import _createClass from "@babel/runtime/helpers/createClass";
3
- import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
4
- import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
5
- import _inherits from "@babel/runtime/helpers/inherits";
6
- import _defineProperty from "@babel/runtime/helpers/defineProperty";
7
- function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
8
- function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
9
1
  /**
10
2
  * @jsxRuntime classic
11
3
  * @jsx jsx
@@ -16,143 +8,11 @@ import React from 'react';
16
8
  import { css, jsx } from '@emotion/react';
17
9
  import isEqual from 'lodash/isEqual';
18
10
  import { ACTION_SUBJECT } from '@atlaskit/editor-common/analytics';
19
- import { fg } from '@atlaskit/platform-feature-flags';
20
- import { whichTransitionEvent } from '../../utils/whichTransitionEvent';
21
11
  import { ErrorBoundary } from '../ErrorBoundary';
22
12
  import { MountPluginHooks } from './mount-plugin-hooks';
23
13
  var pluginsComponentsWrapper = css({
24
14
  display: 'flex'
25
15
  });
26
- // Ignored via go/ees005
27
- // eslint-disable-next-line @repo/internal/react/no-class-components
28
- var PluginSlotLegacy = /*#__PURE__*/function (_React$Component) {
29
- function PluginSlotLegacy() {
30
- var _this;
31
- _classCallCheck(this, PluginSlotLegacy);
32
- for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
33
- args[_key] = arguments[_key];
34
- }
35
- _this = _callSuper(this, PluginSlotLegacy, [].concat(args));
36
- _defineProperty(_this, "transitionEvent", whichTransitionEvent());
37
- _defineProperty(_this, "forceComponentUpdate", function (event) {
38
- // Only trigger an update if the transition is on a property containing `width`
39
- // This will cater for media and the content area itself currently.
40
- if (event.propertyName.includes('width')) {
41
- _this.forceUpdate();
42
- }
43
- });
44
- _defineProperty(_this, "removeModeChangeListener", function (contentArea) {
45
- if (contentArea && _this.transitionEvent) {
46
- // Ignored via go/ees005
47
- // eslint-disable-next-line @repo/internal/dom-events/no-unsafe-event-listeners
48
- contentArea.removeEventListener(_this.transitionEvent, _this.forceComponentUpdate);
49
- }
50
- });
51
- _defineProperty(_this, "addModeChangeListener", function (contentArea) {
52
- if (contentArea && _this.transitionEvent) {
53
- /**
54
- * Update the plugin components once the transition
55
- * to full width / default mode completes
56
- */
57
- // Ignored via go/ees005
58
- // eslint-disable-next-line @repo/internal/dom-events/no-unsafe-event-listeners
59
- contentArea.addEventListener(_this.transitionEvent, _this.forceComponentUpdate);
60
- }
61
- });
62
- return _this;
63
- }
64
- _inherits(PluginSlotLegacy, _React$Component);
65
- return _createClass(PluginSlotLegacy, [{
66
- key: "shouldComponentUpdate",
67
- value: function shouldComponentUpdate(nextProps) {
68
- var _this$props = this.props,
69
- editorView = _this$props.editorView,
70
- editorActions = _this$props.editorActions,
71
- items = _this$props.items,
72
- providerFactory = _this$props.providerFactory,
73
- eventDispatcher = _this$props.eventDispatcher,
74
- popupsMountPoint = _this$props.popupsMountPoint,
75
- popupsBoundariesElement = _this$props.popupsBoundariesElement,
76
- popupsScrollableElement = _this$props.popupsScrollableElement,
77
- containerElement = _this$props.containerElement,
78
- disabled = _this$props.disabled,
79
- wrapperElement = _this$props.wrapperElement;
80
- return !(nextProps.editorView === editorView && nextProps.editorActions === editorActions && nextProps.items === items && nextProps.providerFactory === providerFactory && nextProps.eventDispatcher === eventDispatcher && nextProps.popupsMountPoint === popupsMountPoint && nextProps.popupsBoundariesElement === popupsBoundariesElement && nextProps.popupsScrollableElement === popupsScrollableElement && nextProps.containerElement === containerElement && nextProps.disabled === disabled && nextProps.wrapperElement === wrapperElement);
81
- }
82
- }, {
83
- key: "componentDidMount",
84
- value: function componentDidMount() {
85
- this.addModeChangeListener(this.props.contentArea);
86
- }
87
- }, {
88
- key: "UNSAFE_componentWillReceiveProps",
89
- value: function UNSAFE_componentWillReceiveProps(nextProps) {
90
- if (this.props.contentArea !== nextProps.contentArea) {
91
- this.removeModeChangeListener(this.props.contentArea);
92
- this.addModeChangeListener(nextProps.contentArea);
93
- }
94
- }
95
- }, {
96
- key: "componentWillUnmount",
97
- value: function componentWillUnmount() {
98
- this.removeModeChangeListener(this.props.contentArea);
99
- }
100
- }, {
101
- key: "render",
102
- value: function render() {
103
- var _this$props2 = this.props,
104
- items = _this$props2.items,
105
- editorView = _this$props2.editorView,
106
- editorActions = _this$props2.editorActions,
107
- eventDispatcher = _this$props2.eventDispatcher,
108
- providerFactory = _this$props2.providerFactory,
109
- appearance = _this$props2.appearance,
110
- popupsMountPoint = _this$props2.popupsMountPoint,
111
- popupsBoundariesElement = _this$props2.popupsBoundariesElement,
112
- popupsScrollableElement = _this$props2.popupsScrollableElement,
113
- containerElement = _this$props2.containerElement,
114
- disabled = _this$props2.disabled,
115
- dispatchAnalyticsEvent = _this$props2.dispatchAnalyticsEvent,
116
- wrapperElement = _this$props2.wrapperElement,
117
- pluginHooks = _this$props2.pluginHooks;
118
- if (!items && !pluginHooks || !editorView) {
119
- return null;
120
- }
121
- return jsx(ErrorBoundary, {
122
- component: ACTION_SUBJECT.PLUGIN_SLOT,
123
- fallbackComponent: null
124
- }, jsx(MountPluginHooks, {
125
- editorView: editorView,
126
- pluginHooks: pluginHooks,
127
- containerElement: containerElement
128
- }), jsx("div", {
129
- css: pluginsComponentsWrapper
130
- }, items === null || items === void 0 ? void 0 : items.map(function (component, key) {
131
- var props = {
132
- key: key
133
- };
134
- var element = component({
135
- editorView: editorView,
136
- editorActions: editorActions,
137
- eventDispatcher: eventDispatcher,
138
- providerFactory: providerFactory,
139
- dispatchAnalyticsEvent: dispatchAnalyticsEvent,
140
- // Ignored via go/ees005
141
- // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
142
- appearance: appearance,
143
- popupsMountPoint: popupsMountPoint,
144
- popupsBoundariesElement: popupsBoundariesElement,
145
- popupsScrollableElement: popupsScrollableElement,
146
- containerElement: containerElement,
147
- disabled: disabled,
148
- wrapperElement: wrapperElement
149
- });
150
- return element && /*#__PURE__*/React.cloneElement(element, props);
151
- })));
152
- }
153
- }]);
154
- }(React.Component);
155
- _defineProperty(PluginSlotLegacy, "displayName", 'PluginSlot');
156
16
  var PluginSlot = function PluginSlot(_ref) {
157
17
  var items = _ref.items,
158
18
  editorView = _ref.editorView,
@@ -203,57 +63,6 @@ var PluginSlot = function PluginSlot(_ref) {
203
63
  return element && /*#__PURE__*/React.cloneElement(element, props);
204
64
  })));
205
65
  };
206
- var PluginSlotNew = /*#__PURE__*/React.memo(PluginSlot, isEqual);
207
- PluginSlotNew.displayName = 'PluginSlot';
208
- export default function PluginSlotDefault(_ref2) {
209
- var items = _ref2.items,
210
- editorView = _ref2.editorView,
211
- editorActions = _ref2.editorActions,
212
- eventDispatcher = _ref2.eventDispatcher,
213
- providerFactory = _ref2.providerFactory,
214
- appearance = _ref2.appearance,
215
- popupsMountPoint = _ref2.popupsMountPoint,
216
- popupsBoundariesElement = _ref2.popupsBoundariesElement,
217
- popupsScrollableElement = _ref2.popupsScrollableElement,
218
- containerElement = _ref2.containerElement,
219
- disabled = _ref2.disabled,
220
- dispatchAnalyticsEvent = _ref2.dispatchAnalyticsEvent,
221
- wrapperElement = _ref2.wrapperElement,
222
- pluginHooks = _ref2.pluginHooks,
223
- contentArea = _ref2.contentArea;
224
- if (fg('platform_editor_react_18_plugin_slot')) {
225
- return jsx(PluginSlotNew, {
226
- items: items,
227
- editorView: editorView,
228
- editorActions: editorActions,
229
- eventDispatcher: eventDispatcher,
230
- providerFactory: providerFactory,
231
- appearance: appearance,
232
- popupsMountPoint: popupsMountPoint,
233
- popupsBoundariesElement: popupsBoundariesElement,
234
- popupsScrollableElement: popupsScrollableElement,
235
- containerElement: containerElement,
236
- disabled: disabled,
237
- dispatchAnalyticsEvent: dispatchAnalyticsEvent,
238
- wrapperElement: wrapperElement,
239
- pluginHooks: pluginHooks
240
- });
241
- }
242
- return jsx(PluginSlotLegacy, {
243
- contentArea: contentArea,
244
- items: items,
245
- editorView: editorView,
246
- editorActions: editorActions,
247
- eventDispatcher: eventDispatcher,
248
- providerFactory: providerFactory,
249
- appearance: appearance,
250
- popupsMountPoint: popupsMountPoint,
251
- popupsBoundariesElement: popupsBoundariesElement,
252
- popupsScrollableElement: popupsScrollableElement,
253
- containerElement: containerElement,
254
- disabled: disabled,
255
- dispatchAnalyticsEvent: dispatchAnalyticsEvent,
256
- wrapperElement: wrapperElement,
257
- pluginHooks: pluginHooks
258
- });
259
- }
66
+ var PluginSlotComponent = /*#__PURE__*/React.memo(PluginSlot, isEqual);
67
+ PluginSlotComponent.displayName = 'PluginSlot';
68
+ export default PluginSlotComponent;
@@ -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.5";
@@ -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,3 +1,8 @@
1
+ /**
2
+ * @jsxRuntime classic
3
+ * @jsx jsx
4
+ */
5
+ import React from 'react';
1
6
  import { jsx } from '@emotion/react';
2
7
  import type { DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
3
8
  import type { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
@@ -22,4 +27,5 @@ export interface Props {
22
27
  contentArea?: HTMLElement;
23
28
  wrapperElement: HTMLElement | null;
24
29
  }
25
- export default function PluginSlotDefault({ items, editorView, editorActions, eventDispatcher, providerFactory, appearance, popupsMountPoint, popupsBoundariesElement, popupsScrollableElement, containerElement, disabled, dispatchAnalyticsEvent, wrapperElement, pluginHooks, contentArea, }: Props): jsx.JSX.Element;
30
+ declare const PluginSlotComponent: React.MemoExoticComponent<({ items, editorView, editorActions, eventDispatcher, providerFactory, appearance, popupsMountPoint, popupsBoundariesElement, popupsScrollableElement, containerElement, disabled, dispatchAnalyticsEvent, wrapperElement, pluginHooks, }: Props) => jsx.JSX.Element | null>;
31
+ export default PluginSlotComponent;
@@ -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,3 +1,8 @@
1
+ /**
2
+ * @jsxRuntime classic
3
+ * @jsx jsx
4
+ */
5
+ import React from 'react';
1
6
  import { jsx } from '@emotion/react';
2
7
  import type { DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
3
8
  import type { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
@@ -22,4 +27,5 @@ export interface Props {
22
27
  contentArea?: HTMLElement;
23
28
  wrapperElement: HTMLElement | null;
24
29
  }
25
- export default function PluginSlotDefault({ items, editorView, editorActions, eventDispatcher, providerFactory, appearance, popupsMountPoint, popupsBoundariesElement, popupsScrollableElement, containerElement, disabled, dispatchAnalyticsEvent, wrapperElement, pluginHooks, contentArea, }: Props): jsx.JSX.Element;
30
+ declare const PluginSlotComponent: React.MemoExoticComponent<({ items, editorView, editorActions, eventDispatcher, providerFactory, appearance, popupsMountPoint, popupsBoundariesElement, popupsScrollableElement, containerElement, disabled, dispatchAnalyticsEvent, wrapperElement, pluginHooks, }: Props) => jsx.JSX.Element | null>;
31
+ export default PluginSlotComponent;
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.5",
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",
@@ -52,11 +52,11 @@
52
52
  "@atlaskit/emoji": "^67.12.0",
53
53
  "@atlaskit/icon": "^23.4.0",
54
54
  "@atlaskit/media-card": "^78.18.0",
55
- "@atlaskit/mention": "^23.8.0",
55
+ "@atlaskit/mention": "^23.9.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.37.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",
@@ -84,7 +84,7 @@
84
84
  "@atlaskit/adf-utils": "^19.17.0",
85
85
  "@atlaskit/analytics-listeners": "^8.13.0",
86
86
  "@atlaskit/collab-provider": "10.4.0",
87
- "@atlaskit/editor-plugin-annotation": "1.26.11",
87
+ "@atlaskit/editor-plugin-annotation": "1.26.12",
88
88
  "@atlaskit/editor-plugin-card": "^4.5.0",
89
89
  "@atlaskit/editor-plugin-list": "^3.9.0",
90
90
  "@atlaskit/editor-plugin-paste": "^2.0.0",
@@ -96,7 +96,7 @@
96
96
  "@atlaskit/modal-dialog": "^12.19.0",
97
97
  "@atlaskit/primitives": "^13.3.0",
98
98
  "@atlaskit/renderer": "^112.8.0",
99
- "@atlaskit/smart-card": "^34.2.0",
99
+ "@atlaskit/smart-card": "^34.4.0",
100
100
  "@atlaskit/synchrony-test-helpers": "^3.0.0",
101
101
  "@atlaskit/toggle": "^14.0.0",
102
102
  "@atlaskit/util-data-test": "^17.13.0",
@@ -185,9 +185,6 @@
185
185
  "type": "boolean",
186
186
  "referenceOnly": true
187
187
  },
188
- "platform_editor_react_18_plugin_slot": {
189
- "type": "boolean"
190
- },
191
188
  "platform_editor_disable_instrumented_plugin": {
192
189
  "type": "boolean"
193
190
  },
@@ -225,6 +222,10 @@
225
222
  "type": "boolean",
226
223
  "referenceOnly": true
227
224
  },
225
+ "platform_editor_annotation_react_18_mem_leak": {
226
+ "type": "boolean",
227
+ "referenceOnly": true
228
+ },
228
229
  "platform_editor_ssr_fix_block_controls": {
229
230
  "type": "boolean"
230
231
  },
@@ -250,10 +251,6 @@
250
251
  "type:": "boolean",
251
252
  "referenceOnly": true
252
253
  },
253
- "platform_editor_drag_and_drop_target_v2": {
254
- "type": "boolean",
255
- "referenceOnly": true
256
- },
257
254
  "platform_editor_element_dnd_nested_fix_patch_5": {
258
255
  "type": "boolean",
259
256
  "referenceOnly": true
@@ -290,14 +287,6 @@
290
287
  "platform_editor_add_extension_api_to_quick_insert": {
291
288
  "type": "boolean"
292
289
  },
293
- "platform_editor_ed-25557_lnv_add_ssr_placeholder": {
294
- "type": "boolean",
295
- "referenceOnly": true
296
- },
297
- "platform_editor_replace_finddomnode_in_common": {
298
- "type": "boolean",
299
- "referenceOnly": true
300
- },
301
290
  "platform-component-visual-refresh": {
302
291
  "type": "boolean",
303
292
  "referenceOnly": true
@@ -400,6 +389,14 @@
400
389
  },
401
390
  "platform_editor_ease_of_use_metrics": {
402
391
  "type": "boolean"
392
+ },
393
+ "platform_editor_nested_tables_renderer_colgroup": {
394
+ "type": "boolean",
395
+ "referenceOnly": true
396
+ },
397
+ "platform_editor_table_use_shared_state_hook_fg": {
398
+ "type": "boolean",
399
+ "referenceOnly": true
403
400
  }
404
401
  },
405
402
  "stricter": {
@@ -1,29 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.whichTransitionEvent = whichTransitionEvent;
7
- /*
8
- * From Modernizr
9
- * Returns the kind of transitionevent available for the element
10
- */
11
- function whichTransitionEvent() {
12
- var el = document.createElement('fakeelement');
13
- var transitions = {
14
- transition: 'transitionend',
15
- MozTransition: 'transitionend',
16
- OTransition: 'oTransitionEnd',
17
- WebkitTransition: 'webkitTransitionEnd'
18
- };
19
- for (var t in transitions) {
20
- if (el.style[t] !== undefined) {
21
- // Use a generic as the return type because TypeScript doesnt know
22
- // about cross browser features, so we cast here to align to the
23
- // standard Event spec and propagate the type properly to the callbacks
24
- // of `addEventListener` and `removeEventListener`.
25
- return transitions[t];
26
- }
27
- }
28
- return;
29
- }
@@ -1,23 +0,0 @@
1
- /*
2
- * From Modernizr
3
- * Returns the kind of transitionevent available for the element
4
- */
5
- export function whichTransitionEvent() {
6
- const el = document.createElement('fakeelement');
7
- const transitions = {
8
- transition: 'transitionend',
9
- MozTransition: 'transitionend',
10
- OTransition: 'oTransitionEnd',
11
- WebkitTransition: 'webkitTransitionEnd'
12
- };
13
- for (const t in transitions) {
14
- if (el.style[t] !== undefined) {
15
- // Use a generic as the return type because TypeScript doesnt know
16
- // about cross browser features, so we cast here to align to the
17
- // standard Event spec and propagate the type properly to the callbacks
18
- // of `addEventListener` and `removeEventListener`.
19
- return transitions[t];
20
- }
21
- }
22
- return;
23
- }
@@ -1,23 +0,0 @@
1
- /*
2
- * From Modernizr
3
- * Returns the kind of transitionevent available for the element
4
- */
5
- export function whichTransitionEvent() {
6
- var el = document.createElement('fakeelement');
7
- var transitions = {
8
- transition: 'transitionend',
9
- MozTransition: 'transitionend',
10
- OTransition: 'oTransitionEnd',
11
- WebkitTransition: 'webkitTransitionEnd'
12
- };
13
- for (var t in transitions) {
14
- if (el.style[t] !== undefined) {
15
- // Use a generic as the return type because TypeScript doesnt know
16
- // about cross browser features, so we cast here to align to the
17
- // standard Event spec and propagate the type properly to the callbacks
18
- // of `addEventListener` and `removeEventListener`.
19
- return transitions[t];
20
- }
21
- }
22
- return;
23
- }
@@ -1 +0,0 @@
1
- export declare function whichTransitionEvent<TransitionEventName extends string>(): TransitionEventName | undefined;
@@ -1 +0,0 @@
1
- export declare function whichTransitionEvent<TransitionEventName extends string>(): TransitionEventName | undefined;