@atlaskit/editor-plugin-breakout 26.0.5 → 26.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/dist/cjs/pm-plugins/get-guidelines.js +14 -12
  3. package/dist/cjs/pm-plugins/pragmatic-resizer.js +11 -11
  4. package/dist/cjs/pm-plugins/resizing-mark-view.js +3 -3
  5. package/dist/cjs/pm-plugins/resizing-plugin.js +5 -4
  6. package/dist/cjs/pm-plugins/utils/analytics.js +7 -7
  7. package/dist/cjs/ui/GuidelineLabel.js +5 -5
  8. package/dist/es2019/pm-plugins/get-guidelines.js +4 -2
  9. package/dist/es2019/pm-plugins/pragmatic-resizer.js +1 -1
  10. package/dist/es2019/pm-plugins/resizing-mark-view.js +1 -1
  11. package/dist/es2019/pm-plugins/resizing-plugin.js +3 -2
  12. package/dist/es2019/pm-plugins/utils/analytics.js +1 -1
  13. package/dist/es2019/ui/GuidelineLabel.js +3 -3
  14. package/dist/esm/pm-plugins/get-guidelines.js +4 -2
  15. package/dist/esm/pm-plugins/pragmatic-resizer.js +1 -1
  16. package/dist/esm/pm-plugins/resizing-mark-view.js +1 -1
  17. package/dist/esm/pm-plugins/resizing-plugin.js +3 -2
  18. package/dist/esm/pm-plugins/utils/analytics.js +1 -1
  19. package/dist/esm/ui/GuidelineLabel.js +3 -3
  20. package/dist/types/breakoutPluginType.d.ts +10 -9
  21. package/dist/types/editor-commands/set-breakout-width.d.ts +2 -1
  22. package/dist/types/pm-plugins/get-guidelines.d.ts +2 -2
  23. package/dist/types/pm-plugins/handle-key-down.d.ts +1 -1
  24. package/dist/types/pm-plugins/pragmatic-resizer.d.ts +2 -2
  25. package/dist/types/pm-plugins/resize-width.d.ts +1 -1
  26. package/dist/types/pm-plugins/resizer-callbacks.d.ts +2 -3
  27. package/dist/types/pm-plugins/resizing-mark-view.d.ts +2 -2
  28. package/dist/types/pm-plugins/resizing-plugin.d.ts +2 -2
  29. package/dist/types/pm-plugins/utils/analytics.d.ts +1 -1
  30. package/dist/types/ui/GuidelineLabel.d.ts +1 -1
  31. package/package.json +2 -2
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @atlaskit/editor-plugin-breakout
2
2
 
3
+ ## 26.0.6
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
3
9
  ## 26.0.5
4
10
 
5
11
  ### Patch Changes
@@ -6,14 +6,16 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.getGuidelines = exports.GUIDELINE_KEYS = void 0;
8
8
  var _memoizeOne = _interopRequireDefault(require("memoize-one"));
9
- var _styles = require("@atlaskit/editor-common/styles");
10
- var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
9
+ var _layout = require("@atlaskit/editor-common/styles/layout");
10
+ var _resizer = require("@atlaskit/editor-common/styles/resizer");
11
+ var _sharedStyles = require("@atlaskit/editor-common/ui-expand/sharedStyles");
12
+ var _constants = require("@atlaskit/editor-shared-styles/constants");
11
13
  var _editorExperiment = require("@atlaskit/tmp-editor-statsig/editor-experiment");
12
14
  var WIDTHS = {
13
- MIN: _editorSharedStyles.akEditorDefaultLayoutWidth,
14
- WIDE: _editorSharedStyles.akEditorCalculatedWideLayoutWidth,
15
- FULL: _editorSharedStyles.akEditorFullWidthLayoutWidth,
16
- MAX: _editorSharedStyles.akEditorMaxLayoutWidth
15
+ MIN: _constants.akEditorDefaultLayoutWidth,
16
+ WIDE: _constants.akEditorCalculatedWideLayoutWidth,
17
+ FULL: _constants.akEditorFullWidthLayoutWidth,
18
+ MAX: _constants.akEditorMaxLayoutWidth
17
19
  };
18
20
  var GUIDELINE_KEYS = exports.GUIDELINE_KEYS = {
19
21
  lineLengthLeft: 'grid_left',
@@ -41,10 +43,10 @@ var getGuidelines = exports.getGuidelines = (0, _memoizeOne.default)(function (i
41
43
  if (nodeType) {
42
44
  switch (nodeType.name) {
43
45
  case 'expand':
44
- innerPaddingOffset = _styles.EXPAND_CONTAINER_PADDING + _styles.resizerHandleThumbWidth + AK_NESTED_DND_GUTTER_OFFSET;
46
+ innerPaddingOffset = _sharedStyles.EXPAND_CONTAINER_PADDING + _resizer.resizerHandleThumbWidth + AK_NESTED_DND_GUTTER_OFFSET;
45
47
  break;
46
48
  case 'layoutSection':
47
- innerPaddingOffset = _styles.LAYOUT_COLUMN_PADDING + AK_NESTED_DND_GUTTER_OFFSET;
49
+ innerPaddingOffset = _layout.LAYOUT_COLUMN_PADDING + AK_NESTED_DND_GUTTER_OFFSET;
48
50
  break;
49
51
  case 'bodiedSyncBlock':
50
52
  case 'syncBlock':
@@ -61,11 +63,11 @@ var getGuidelines = exports.getGuidelines = (0, _memoizeOne.default)(function (i
61
63
  }
62
64
  var _ref = getEditorWidth() || {},
63
65
  width = _ref.width;
64
- var padding = width && width <= _editorSharedStyles.akEditorFullPageNarrowBreakout && (0, _editorExperiment.editorExperiment)('platform_editor_preview_panel_responsiveness', true, {
66
+ var padding = width && width <= _constants.akEditorFullPageNarrowBreakout && (0, _editorExperiment.editorExperiment)('platform_editor_preview_panel_responsiveness', true, {
65
67
  exposure: true
66
- }) ? _editorSharedStyles.akEditorGutterPaddingReduced : (0, _editorSharedStyles.akEditorGutterPaddingDynamic)();
67
- var fullWidth = width ? Math.min(WIDTHS.FULL, width - 2 * padding - _editorSharedStyles.akEditorGutterPadding) : undefined;
68
- var maxWidth = width ? Math.min(WIDTHS.MAX, width - 2 * padding - _editorSharedStyles.akEditorGutterPadding) : undefined;
68
+ }) ? _constants.akEditorGutterPaddingReduced : (0, _constants.akEditorGutterPaddingDynamic)();
69
+ var fullWidth = width ? Math.min(WIDTHS.FULL, width - 2 * padding - _constants.akEditorGutterPadding) : undefined;
70
+ var maxWidth = width ? Math.min(WIDTHS.MAX, width - 2 * padding - _constants.akEditorGutterPadding) : undefined;
69
71
  guidelines.push({
70
72
  key: GUIDELINE_KEYS.lineLengthLeft,
71
73
  position: {
@@ -10,7 +10,7 @@ var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers
10
10
  var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
11
11
  var _react = _interopRequireWildcard(require("react"));
12
12
  var _bindEventListener = require("bind-event-listener");
13
- var _messages = require("@atlaskit/editor-common/messages");
13
+ var _breakout = require("@atlaskit/editor-common/messages/breakout");
14
14
  var _vanillaTooltip = require("@atlaskit/editor-common/vanilla-tooltip");
15
15
  var _isExperimentEnabled = require("@atlaskit/platform-feature-experiments/is-experiment-enabled");
16
16
  var _elementAdapter = require("@atlaskit/pragmatic-drag-and-drop/adapter/element-adapter");
@@ -40,16 +40,16 @@ var getNodeName = function getNodeName(nodeName) {
40
40
  */
41
41
  var tooltipAnchorTopVar = '--pm-breakout-resize-tooltip-anchor-top';
42
42
  var resizeHandleMessage = exports.resizeHandleMessage = {
43
- expand: _messages.breakoutMessages.resizeExpand,
44
- codeBlock: _messages.breakoutMessages.resizeCodeBlock,
45
- layout: _messages.breakoutMessages.resizeLayout,
46
- rule: _messages.breakoutMessages.resizeRule,
47
- panel: _messages.breakoutMessages.resizePanel,
48
- panel_c1: _messages.breakoutMessages.resizePanel,
49
- node: _messages.breakoutMessages.resizeElement,
50
- extension: _messages.breakoutMessages.resizeExtension,
51
- bodiedExtension: _messages.breakoutMessages.resizeExtension,
52
- multiBodiedExtension: _messages.breakoutMessages.resizeExtension
43
+ expand: _breakout.messages.resizeExpand,
44
+ codeBlock: _breakout.messages.resizeCodeBlock,
45
+ layout: _breakout.messages.resizeLayout,
46
+ rule: _breakout.messages.resizeRule,
47
+ panel: _breakout.messages.resizePanel,
48
+ panel_c1: _breakout.messages.resizePanel,
49
+ node: _breakout.messages.resizeElement,
50
+ extension: _breakout.messages.resizeExtension,
51
+ bodiedExtension: _breakout.messages.resizeExtension,
52
+ multiBodiedExtension: _breakout.messages.resizeExtension
53
53
  };
54
54
  /**
55
55
  * Remove during `platform_editor_use_vanilla_components` cleanup — replaced by
@@ -8,7 +8,7 @@ exports.ResizingMarkView = exports.LOCAL_RESIZE_PROPERTY = void 0;
8
8
  var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
9
9
  var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
10
10
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
11
- var _styles = require("@atlaskit/editor-common/styles");
11
+ var _breakout = require("@atlaskit/editor-common/styles/breakout");
12
12
  var _isExperimentEnabled = require("@atlaskit/platform-feature-experiments/is-experiment-enabled");
13
13
  var _fg = require("@atlaskit/platform-feature-flags/fg");
14
14
  var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
@@ -55,9 +55,9 @@ var ResizingMarkView = exports.ResizingMarkView = /*#__PURE__*/function () {
55
55
  (0, _defineProperty2.default)(this, "isResizingInitialised", false);
56
56
  var dom = document.createElement('div');
57
57
  var contentDOM = document.createElement('div');
58
- contentDOM.className = _styles.BreakoutCssClassName.BREAKOUT_MARK_DOM;
58
+ contentDOM.className = _breakout.BreakoutCssClassName.BREAKOUT_MARK_DOM;
59
59
  contentDOM.setAttribute('data-testid', 'ak-editor-breakout-mark-dom');
60
- dom.className = _styles.BreakoutCssClassName.BREAKOUT_MARK;
60
+ dom.className = _breakout.BreakoutCssClassName.BREAKOUT_MARK;
61
61
  dom.setAttribute('data-layout', mark.attrs.mode);
62
62
  dom.setAttribute('data-testid', 'ak-editor-breakout-mark');
63
63
  var isRemoveLeftResizeHandleEnabled = (0, _isExperimentEnabled.isExperimentEnabled)('platform_editor_remove_left_resize_handle');
@@ -9,8 +9,9 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
9
9
  var _safePlugin = require("@atlaskit/editor-common/safe-plugin");
10
10
  var _utils = require("@atlaskit/editor-common/utils");
11
11
  var _document = require("@atlaskit/editor-common/utils/document");
12
+ var _editorCoreUtils = require("@atlaskit/editor-common/utils/editor-core-utils");
12
13
  var _state = require("@atlaskit/editor-prosemirror/state");
13
- var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
14
+ var _constants = require("@atlaskit/editor-shared-styles/constants");
14
15
  var _isExperimentEnabled = require("@atlaskit/platform-feature-experiments/is-experiment-enabled");
15
16
  var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
16
17
  var _handleKeyDown = require("./handle-key-down");
@@ -38,7 +39,7 @@ var addBreakoutToResizableNode = function addBreakoutToResizableNode(_ref) {
38
39
  });
39
40
  var isExpand = node.type === expand;
40
41
  if (!breakoutMark) {
41
- var width = isMaxWidthEnabled ? _editorSharedStyles.akEditorMaxWidthLayoutWidth : isFullWidthEnabled ? _editorSharedStyles.akEditorFullWidthLayoutWidth : _editorSharedStyles.akEditorDefaultLayoutWidth;
42
+ var width = isMaxWidthEnabled ? _constants.akEditorMaxWidthLayoutWidth : isFullWidthEnabled ? _constants.akEditorFullWidthLayoutWidth : _constants.akEditorDefaultLayoutWidth;
42
43
  if ((0, _isExperimentEnabled.isExperimentEnabled)('platform_editor_lovability_resize_extensions')) {
43
44
  var marks = breakout.create({
44
45
  width: width
@@ -62,7 +63,7 @@ var addBreakoutToResizableNode = function addBreakoutToResizableNode(_ref) {
62
63
  var mode = breakoutMark.attrs.mode;
63
64
 
64
65
  // if breakout is present on node, but page appearance is 'full width' force width to full width to maintain backwards compatibility
65
- var _width = isMaxWidthEnabled ? _editorSharedStyles.akEditorMaxWidthLayoutWidth : isFullWidthEnabled || mode === 'full-width' ? _editorSharedStyles.akEditorFullWidthLayoutWidth : _editorSharedStyles.akEditorCalculatedWideLayoutWidth;
66
+ var _width = isMaxWidthEnabled ? _constants.akEditorMaxWidthLayoutWidth : isFullWidthEnabled || mode === 'full-width' ? _constants.akEditorFullWidthLayoutWidth : _constants.akEditorCalculatedWideLayoutWidth;
66
67
  if ((0, _isExperimentEnabled.isExperimentEnabled)('platform_editor_lovability_resize_extensions')) {
67
68
  var _marks = breakout.create({
68
69
  width: _width
@@ -236,7 +237,7 @@ var createResizingPlugin = exports.createResizingPlugin = function createResizin
236
237
  } else {
237
238
  transactions.forEach(function (tr) {
238
239
  var isAddingResizableNodes = tr.steps.some(function (step) {
239
- return (0, _utils.stepAddsOneOf)(step, breakoutResizableNodes);
240
+ return (0, _editorCoreUtils.stepAddsOneOf)(step, breakoutResizableNodes);
240
241
  });
241
242
  if (isAddingResizableNodes) {
242
243
  var changedNodes = (0, _document.getChangedNodes)(tr);
@@ -4,13 +4,13 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.generateResizedEventPayload = exports.generateResizeFrameRatePayloads = void 0;
7
- var _analytics = require("@atlaskit/editor-common/analytics");
7
+ var _enums = require("@atlaskit/editor-common/analytics/types/enums");
8
8
  var generateResizeFrameRatePayloads = exports.generateResizeFrameRatePayloads = function generateResizeFrameRatePayloads(props) {
9
9
  return props.frameRateSamples.map(function (frameRateSample, index) {
10
10
  return {
11
- action: _analytics.ACTION.RESIZED_PERF_SAMPLING,
12
- actionSubject: _analytics.ACTION_SUBJECT.ELEMENT,
13
- eventType: _analytics.EVENT_TYPE.OPERATIONAL,
11
+ action: _enums.ACTION.RESIZED_PERF_SAMPLING,
12
+ actionSubject: _enums.ACTION_SUBJECT.ELEMENT,
13
+ eventType: _enums.EVENT_TYPE.OPERATIONAL,
14
14
  attributes: {
15
15
  nodeType: props.originalNode.type.name,
16
16
  frameRate: frameRateSample,
@@ -26,9 +26,9 @@ var generateResizedEventPayload = exports.generateResizedEventPayload = function
26
26
  prevWidth = _ref.prevWidth,
27
27
  newWidth = _ref.newWidth;
28
28
  return {
29
- action: _analytics.ACTION.RESIZED,
30
- actionSubject: _analytics.ACTION_SUBJECT.ELEMENT,
31
- eventType: _analytics.EVENT_TYPE.TRACK,
29
+ action: _enums.ACTION.RESIZED,
30
+ actionSubject: _enums.ACTION_SUBJECT.ELEMENT,
31
+ eventType: _enums.EVENT_TYPE.TRACK,
32
32
  attributes: {
33
33
  nodeType: node.type.name,
34
34
  prevWidth: prevWidth,
@@ -6,9 +6,9 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.GuidelineLabel = void 0;
8
8
  var _react = _interopRequireDefault(require("react"));
9
- var _resizer = require("@atlaskit/editor-common/resizer");
10
- var _ui = require("@atlaskit/editor-common/ui");
11
- var _useSharedPluginStateSelector = require("@atlaskit/editor-common/use-shared-plugin-state-selector");
9
+ var _Popup = _interopRequireDefault(require("@atlaskit/editor-common/Popup"));
10
+ var _ResizerBreakoutModeLabel = require("@atlaskit/editor-common/resizer/ResizerBreakoutModeLabel");
11
+ var _useSharedPluginStateSelector = require("@atlaskit/editor-common/useSharedPluginStateSelector");
12
12
  var _utils = require("@atlaskit/editor-prosemirror/utils");
13
13
  var GUIDELINE_KEY_TO_LAYOUT = {
14
14
  wide_left: 'wide',
@@ -30,7 +30,7 @@ var GuidelineLabel = exports.GuidelineLabel = function GuidelineLabel(_ref) {
30
30
  return null;
31
31
  }
32
32
  var element = (0, _utils.findDomRefAtPos)(breakoutNode.pos, editorView.domAtPos.bind(editorView));
33
- return /*#__PURE__*/_react.default.createElement(_ui.Popup, {
33
+ return /*#__PURE__*/_react.default.createElement(_Popup.default, {
34
34
  target: element && element instanceof HTMLElement ? element : undefined
35
35
  // eslint-disable-next-line @atlassian/perf-linting/no-unstable-inline-props -- Ignored via go/ees017 (to be fixed)
36
36
  ,
@@ -42,7 +42,7 @@ var GuidelineLabel = exports.GuidelineLabel = function GuidelineLabel(_ref) {
42
42
  scrollableElement: scrollableElement,
43
43
  stick: true,
44
44
  forcePlacement: true
45
- }, /*#__PURE__*/_react.default.createElement(_resizer.ResizerBreakoutModeLabel, {
45
+ }, /*#__PURE__*/_react.default.createElement(_ResizerBreakoutModeLabel.ResizerBreakoutModeLabel, {
46
46
  layout: GUIDELINE_KEY_TO_LAYOUT[activeGuidelineKey]
47
47
  }));
48
48
  };
@@ -1,6 +1,8 @@
1
1
  import memoizeOne from 'memoize-one';
2
- import { EXPAND_CONTAINER_PADDING, LAYOUT_COLUMN_PADDING, resizerHandleThumbWidth } from '@atlaskit/editor-common/styles';
3
- import { akEditorGutterPaddingDynamic, akEditorGutterPadding, akEditorGutterPaddingReduced, akEditorFullPageNarrowBreakout, akEditorCalculatedWideLayoutWidth, akEditorFullWidthLayoutWidth, akEditorDefaultLayoutWidth, akEditorMaxLayoutWidth } from '@atlaskit/editor-shared-styles';
2
+ import { LAYOUT_COLUMN_PADDING } from '@atlaskit/editor-common/styles/layout';
3
+ import { resizerHandleThumbWidth } from '@atlaskit/editor-common/styles/resizer';
4
+ import { EXPAND_CONTAINER_PADDING } from '@atlaskit/editor-common/ui-expand/sharedStyles';
5
+ import { akEditorGutterPaddingDynamic, akEditorGutterPadding, akEditorGutterPaddingReduced, akEditorFullPageNarrowBreakout, akEditorCalculatedWideLayoutWidth, akEditorFullWidthLayoutWidth, akEditorDefaultLayoutWidth, akEditorMaxLayoutWidth } from '@atlaskit/editor-shared-styles/constants';
4
6
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
5
7
  const WIDTHS = {
6
8
  MIN: akEditorDefaultLayoutWidth,
@@ -1,6 +1,6 @@
1
1
  import React, { useLayoutEffect, useState } from 'react';
2
2
  import { bind } from 'bind-event-listener';
3
- import { breakoutMessages as messages } from '@atlaskit/editor-common/messages';
3
+ import { messages } from '@atlaskit/editor-common/messages/breakout';
4
4
  import { VANILLA_TOOLTIP_DEFAULT_CLASS, VanillaTooltip } from '@atlaskit/editor-common/vanilla-tooltip';
5
5
  import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
6
6
  import { draggable } from '@atlaskit/pragmatic-drag-and-drop/adapter/element-adapter';
@@ -1,5 +1,5 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
- import { BreakoutCssClassName } from '@atlaskit/editor-common/styles';
2
+ import { BreakoutCssClassName } from '@atlaskit/editor-common/styles/breakout';
3
3
  import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
4
4
  import { fg } from '@atlaskit/platform-feature-flags/fg';
5
5
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
@@ -1,8 +1,9 @@
1
1
  import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
2
- import { getBreakoutResizableNodeTypes, getBreakoutResizableNodeTypesNew, stepAddsOneOf } from '@atlaskit/editor-common/utils';
2
+ import { getBreakoutResizableNodeTypes, getBreakoutResizableNodeTypesNew } from '@atlaskit/editor-common/utils';
3
3
  import { getChangedNodes, isReplaceDocOperation } from '@atlaskit/editor-common/utils/document';
4
+ import { stepAddsOneOf } from '@atlaskit/editor-common/utils/editor-core-utils';
4
5
  import { PluginKey } from '@atlaskit/editor-prosemirror/state';
5
- import { akEditorDefaultLayoutWidth, akEditorFullWidthLayoutWidth, akEditorMaxWidthLayoutWidth, akEditorCalculatedWideLayoutWidth } from '@atlaskit/editor-shared-styles';
6
+ import { akEditorDefaultLayoutWidth, akEditorFullWidthLayoutWidth, akEditorMaxWidthLayoutWidth, akEditorCalculatedWideLayoutWidth } from '@atlaskit/editor-shared-styles/constants';
6
7
  import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
7
8
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
8
9
  import { handleKeyDown } from './handle-key-down';
@@ -1,4 +1,4 @@
1
- import { ACTION, ACTION_SUBJECT, EVENT_TYPE } from '@atlaskit/editor-common/analytics';
1
+ import { ACTION, ACTION_SUBJECT, EVENT_TYPE } from '@atlaskit/editor-common/analytics/types/enums';
2
2
  export const generateResizeFrameRatePayloads = props => {
3
3
  return props.frameRateSamples.map((frameRateSample, index) => ({
4
4
  action: ACTION.RESIZED_PERF_SAMPLING,
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
- import { ResizerBreakoutModeLabel } from '@atlaskit/editor-common/resizer';
3
- import { Popup } from '@atlaskit/editor-common/ui';
4
- import { useSharedPluginStateSelector } from '@atlaskit/editor-common/use-shared-plugin-state-selector';
2
+ import Popup from '@atlaskit/editor-common/Popup';
3
+ import { ResizerBreakoutModeLabel } from '@atlaskit/editor-common/resizer/ResizerBreakoutModeLabel';
4
+ import { useSharedPluginStateSelector } from '@atlaskit/editor-common/useSharedPluginStateSelector';
5
5
  import { findDomRefAtPos } from '@atlaskit/editor-prosemirror/utils';
6
6
  const GUIDELINE_KEY_TO_LAYOUT = {
7
7
  wide_left: 'wide',
@@ -1,6 +1,8 @@
1
1
  import memoizeOne from 'memoize-one';
2
- import { EXPAND_CONTAINER_PADDING, LAYOUT_COLUMN_PADDING, resizerHandleThumbWidth } from '@atlaskit/editor-common/styles';
3
- import { akEditorGutterPaddingDynamic, akEditorGutterPadding, akEditorGutterPaddingReduced, akEditorFullPageNarrowBreakout, akEditorCalculatedWideLayoutWidth, akEditorFullWidthLayoutWidth, akEditorDefaultLayoutWidth, akEditorMaxLayoutWidth } from '@atlaskit/editor-shared-styles';
2
+ import { LAYOUT_COLUMN_PADDING } from '@atlaskit/editor-common/styles/layout';
3
+ import { resizerHandleThumbWidth } from '@atlaskit/editor-common/styles/resizer';
4
+ import { EXPAND_CONTAINER_PADDING } from '@atlaskit/editor-common/ui-expand/sharedStyles';
5
+ import { akEditorGutterPaddingDynamic, akEditorGutterPadding, akEditorGutterPaddingReduced, akEditorFullPageNarrowBreakout, akEditorCalculatedWideLayoutWidth, akEditorFullWidthLayoutWidth, akEditorDefaultLayoutWidth, akEditorMaxLayoutWidth } from '@atlaskit/editor-shared-styles/constants';
4
6
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
5
7
  var WIDTHS = {
6
8
  MIN: akEditorDefaultLayoutWidth,
@@ -2,7 +2,7 @@ import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
2
2
  import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
3
3
  import React, { useLayoutEffect, useState } from 'react';
4
4
  import { bind } from 'bind-event-listener';
5
- import { breakoutMessages as messages } from '@atlaskit/editor-common/messages';
5
+ import { messages } from '@atlaskit/editor-common/messages/breakout';
6
6
  import { VANILLA_TOOLTIP_DEFAULT_CLASS, VanillaTooltip } from '@atlaskit/editor-common/vanilla-tooltip';
7
7
  import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
8
8
  import { draggable } from '@atlaskit/pragmatic-drag-and-drop/adapter/element-adapter';
@@ -3,7 +3,7 @@ import _createClass from "@babel/runtime/helpers/createClass";
3
3
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
4
4
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
5
5
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
6
- import { BreakoutCssClassName } from '@atlaskit/editor-common/styles';
6
+ import { BreakoutCssClassName } from '@atlaskit/editor-common/styles/breakout';
7
7
  import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
8
8
  import { fg } from '@atlaskit/platform-feature-flags/fg';
9
9
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
@@ -2,10 +2,11 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
3
3
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
4
4
  import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
5
- import { getBreakoutResizableNodeTypes, getBreakoutResizableNodeTypesNew, stepAddsOneOf } from '@atlaskit/editor-common/utils';
5
+ import { getBreakoutResizableNodeTypes, getBreakoutResizableNodeTypesNew } from '@atlaskit/editor-common/utils';
6
6
  import { getChangedNodes, isReplaceDocOperation } from '@atlaskit/editor-common/utils/document';
7
+ import { stepAddsOneOf } from '@atlaskit/editor-common/utils/editor-core-utils';
7
8
  import { PluginKey } from '@atlaskit/editor-prosemirror/state';
8
- import { akEditorDefaultLayoutWidth, akEditorFullWidthLayoutWidth, akEditorMaxWidthLayoutWidth, akEditorCalculatedWideLayoutWidth } from '@atlaskit/editor-shared-styles';
9
+ import { akEditorDefaultLayoutWidth, akEditorFullWidthLayoutWidth, akEditorMaxWidthLayoutWidth, akEditorCalculatedWideLayoutWidth } from '@atlaskit/editor-shared-styles/constants';
9
10
  import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
10
11
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
11
12
  import { handleKeyDown } from './handle-key-down';
@@ -1,4 +1,4 @@
1
- import { ACTION, ACTION_SUBJECT, EVENT_TYPE } from '@atlaskit/editor-common/analytics';
1
+ import { ACTION, ACTION_SUBJECT, EVENT_TYPE } from '@atlaskit/editor-common/analytics/types/enums';
2
2
  export var generateResizeFrameRatePayloads = function generateResizeFrameRatePayloads(props) {
3
3
  return props.frameRateSamples.map(function (frameRateSample, index) {
4
4
  return {
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
- import { ResizerBreakoutModeLabel } from '@atlaskit/editor-common/resizer';
3
- import { Popup } from '@atlaskit/editor-common/ui';
4
- import { useSharedPluginStateSelector } from '@atlaskit/editor-common/use-shared-plugin-state-selector';
2
+ import Popup from '@atlaskit/editor-common/Popup';
3
+ import { ResizerBreakoutModeLabel } from '@atlaskit/editor-common/resizer/ResizerBreakoutModeLabel';
4
+ import { useSharedPluginStateSelector } from '@atlaskit/editor-common/useSharedPluginStateSelector';
5
5
  import { findDomRefAtPos } from '@atlaskit/editor-prosemirror/utils';
6
6
  var GUIDELINE_KEY_TO_LAYOUT = {
7
7
  wide_left: 'wide',
@@ -1,12 +1,13 @@
1
- import type { EditorAppearance, NextEditorPlugin, OptionalPlugin } from '@atlaskit/editor-common/types';
2
- import type { AnalyticsPlugin } from '@atlaskit/editor-plugin-analytics';
3
- import type { BlockControlsPlugin } from '@atlaskit/editor-plugin-block-controls';
4
- import type { EditorDisabledPlugin } from '@atlaskit/editor-plugin-editor-disabled';
5
- import type { EditorViewModePlugin } from '@atlaskit/editor-plugin-editor-viewmode';
6
- import type { GuidelinePlugin } from '@atlaskit/editor-plugin-guideline';
7
- import type { InteractionPlugin } from '@atlaskit/editor-plugin-interaction';
8
- import type { UserIntentPlugin } from '@atlaskit/editor-plugin-user-intent';
9
- import type { WidthPlugin } from '@atlaskit/editor-plugin-width';
1
+ import type { EditorAppearance } from '@atlaskit/editor-common/types/editor-appearance';
2
+ import type { NextEditorPlugin, OptionalPlugin } from '@atlaskit/editor-common/types/next-editor-plugin';
3
+ import type { AnalyticsPlugin } from '@atlaskit/editor-plugin-analytics/analyticsPluginType';
4
+ import type { BlockControlsPlugin } from '@atlaskit/editor-plugin-block-controls/blockControlsPluginType';
5
+ import type { EditorDisabledPlugin } from '@atlaskit/editor-plugin-editor-disabled/editorDisabledPluginType';
6
+ import type { EditorViewModePlugin } from '@atlaskit/editor-plugin-editor-viewmode/editorViewmodePluginType';
7
+ import type { GuidelinePlugin } from '@atlaskit/editor-plugin-guideline/guidelinePluginType';
8
+ import type { InteractionPlugin } from '@atlaskit/editor-plugin-interaction/interaction-plugin-type';
9
+ import type { UserIntentPlugin } from '@atlaskit/editor-plugin-user-intent/user-intent-plugin-type';
10
+ import type { WidthPlugin } from '@atlaskit/editor-plugin-width/width-plugin-type';
10
11
  import type { ContentNodeWithPos } from '@atlaskit/editor-prosemirror/utils';
11
12
  import type { ActiveGuidelineKey } from './pm-plugins/resizing-plugin';
12
13
  export interface BreakoutPluginState {
@@ -1,2 +1,3 @@
1
- import type { BreakoutMode, Command } from '@atlaskit/editor-common/types';
1
+ import type { BreakoutMode } from '@atlaskit/editor-common/types/breakout';
2
+ import type { Command } from '@atlaskit/editor-common/types/command';
2
3
  export declare function setBreakoutWidth(width: number, mode: BreakoutMode, pos: number, isLivePage?: boolean): Command;
@@ -1,6 +1,6 @@
1
1
  import type { MemoizedFn } from 'memoize-one';
2
- import type { GuidelineConfig } from '@atlaskit/editor-common/guideline';
3
- import type { EditorContainerWidth } from '@atlaskit/editor-common/types';
2
+ import type { GuidelineConfig } from '@atlaskit/editor-common/guideline/types';
3
+ import type { EditorContainerWidth } from '@atlaskit/editor-common/types/editor-container-width';
4
4
  import type { NodeType } from '@atlaskit/editor-prosemirror/model';
5
5
  export declare const GUIDELINE_KEYS: {
6
6
  readonly lineLengthLeft: 'grid_left';
@@ -1,4 +1,4 @@
1
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
1
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types/next-editor-plugin';
2
2
  import type { EditorView } from '@atlaskit/editor-prosemirror/view';
3
3
  import type { BreakoutPlugin } from '../breakoutPluginType';
4
4
  export declare const handleKeyDown: (api: ExtractInjectionAPI<BreakoutPlugin> | undefined) => (view: EditorView, event: KeyboardEvent) => boolean;
@@ -1,6 +1,6 @@
1
1
  import type { IntlShape, MessageDescriptor } from 'react-intl';
2
- import type { PortalProviderAPI } from '@atlaskit/editor-common/portal';
3
- import type { BaseEventPayload, ElementDragType } from '@atlaskit/pragmatic-drag-and-drop/types';
2
+ import type { PortalProviderAPI } from '@atlaskit/editor-common/common';
3
+ import type { BaseEventPayload, ElementDragType } from '@atlaskit/pragmatic-drag-and-drop/internal-types';
4
4
  export declare const resizeHandleMessage: Record<string, MessageDescriptor>;
5
5
  export declare const createPragmaticResizer: ({ target, onDragStart, onDrag, onDrop, intl, nodeViewPortalProviderAPI, }: {
6
6
  intl: IntlShape;
@@ -1,4 +1,4 @@
1
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
1
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types/next-editor-plugin';
2
2
  import type { BreakoutPlugin } from '../breakoutPluginType';
3
3
  declare const WIDTHS: {
4
4
  FULL: number;
@@ -1,8 +1,7 @@
1
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
1
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types/next-editor-plugin';
2
2
  import type { Mark } from '@atlaskit/editor-prosemirror/model';
3
3
  import type { EditorView } from '@atlaskit/editor-prosemirror/view';
4
- import type { ElementDragPayload } from '@atlaskit/pragmatic-drag-and-drop/element/adapter';
5
- import type { BaseEventPayload, DragLocationHistory, ElementDragType } from '@atlaskit/pragmatic-drag-and-drop/types';
4
+ import type { BaseEventPayload, DragLocationHistory, ElementDragPayload, ElementDragType } from '@atlaskit/pragmatic-drag-and-drop/internal-types';
6
5
  import type { BreakoutPlugin } from '../breakoutPluginType';
7
6
  export declare function getProposedWidth({ initialWidth, location, api, source, }: {
8
7
  api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
@@ -1,6 +1,6 @@
1
1
  import type { IntlShape } from 'react-intl';
2
- import type { PortalProviderAPI } from '@atlaskit/editor-common/portal';
3
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
2
+ import type { PortalProviderAPI } from '@atlaskit/editor-common/common';
3
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types/next-editor-plugin';
4
4
  import type { Mark } from '@atlaskit/editor-prosemirror/model';
5
5
  import type { EditorView, NodeView } from '@atlaskit/editor-prosemirror/view';
6
6
  import type { BreakoutPlugin } from '../breakoutPluginType';
@@ -1,7 +1,7 @@
1
1
  import type { IntlShape } from 'react-intl';
2
- import type { PortalProviderAPI } from '@atlaskit/editor-common/portal';
2
+ import type { PortalProviderAPI } from '@atlaskit/editor-common/common';
3
3
  import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
4
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
4
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types/next-editor-plugin';
5
5
  import { PluginKey } from '@atlaskit/editor-prosemirror/state';
6
6
  import type { BreakoutPlugin, BreakoutPluginOptions, BreakoutPluginState } from '../breakoutPluginType';
7
7
  import type { GUIDELINE_KEYS } from './get-guidelines';
@@ -1,4 +1,4 @@
1
- import type { BreakoutEventPayload } from '@atlaskit/editor-common/analytics';
1
+ import type { BreakoutEventPayload } from '@atlaskit/editor-common/analytics/types/breakout-events';
2
2
  import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
3
3
  export declare const generateResizeFrameRatePayloads: (props: {
4
4
  docSize: number;
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
2
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types/next-editor-plugin';
3
3
  import type { EditorView } from '@atlaskit/editor-prosemirror/view';
4
4
  import type { BreakoutPlugin } from '../breakoutPluginType';
5
5
  type GuidelineLabelProps = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-breakout",
3
- "version": "26.0.5",
3
+ "version": "26.0.6",
4
4
  "description": "Breakout plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -36,7 +36,7 @@
36
36
  "@atlaskit/platform-feature-flags": "^2.2.0",
37
37
  "@atlaskit/pragmatic-drag-and-drop": "^4.0.0",
38
38
  "@atlaskit/theme": "^28.2.0",
39
- "@atlaskit/tmp-editor-statsig": "^231.0.0",
39
+ "@atlaskit/tmp-editor-statsig": "^232.0.0",
40
40
  "@atlaskit/tokens": "^20.4.0",
41
41
  "@atlaskit/tooltip": "^24.4.0",
42
42
  "@babel/runtime": "^7.0.0",