@atlaskit/editor-plugin-expand 17.1.4 → 17.1.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,11 @@
1
1
  # @atlaskit/editor-plugin-expand
2
2
 
3
+ ## 17.1.5
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
3
9
  ## 17.1.4
4
10
 
5
11
  ### Patch Changes
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.updateExpandTitle = exports.toggleExpandWithMatch = exports.toggleExpandExpanded = exports.setSelectionInsideExpand = exports.setExpandRef = exports.insertExpandWithInputMethod = exports.insertExpand = exports.focusTitle = exports.focusIcon = exports.deleteExpandAtPos = exports.deleteExpand = exports.createExpandNode = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
9
- var _steps = require("@atlaskit/adf-schema/steps");
9
+ var _setAttrs = require("@atlaskit/adf-schema/steps/set-attrs");
10
10
  var _analytics = require("@atlaskit/editor-common/analytics");
11
11
  var _selection2 = require("@atlaskit/editor-common/selection");
12
12
  var _styles = require("@atlaskit/editor-common/styles");
@@ -80,7 +80,7 @@ var updateExpandTitle = exports.updateExpandTitle = function updateExpandTitle(_
80
80
  if (node && node.type === nodeType && dispatch) {
81
81
  var tr = state.tr;
82
82
  if (__livePage) {
83
- tr.step(new _steps.SetAttrsStep(pos, _objectSpread(_objectSpread({}, node.attrs), {}, {
83
+ tr.step(new _setAttrs.SetAttrsStep(pos, _objectSpread(_objectSpread({}, node.attrs), {}, {
84
84
  title: title
85
85
  })));
86
86
  } else {
@@ -104,7 +104,7 @@ var toggleExpandExpanded = exports.toggleExpandExpanded = function toggleExpandE
104
104
  var tr = state.tr;
105
105
  var isExpandedNext = !node.attrs.__expanded;
106
106
  if (__livePage) {
107
- tr.step(new _steps.SetAttrsStep(pos, _objectSpread(_objectSpread({}, node.attrs), {}, {
107
+ tr.step(new _setAttrs.SetAttrsStep(pos, _objectSpread(_objectSpread({}, node.attrs), {}, {
108
108
  __expanded: isExpandedNext
109
109
  })));
110
110
  } else {
@@ -7,7 +7,8 @@ Object.defineProperty(exports, "__esModule", {
7
7
  exports.expandPlugin = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
9
9
  var _react = _interopRequireDefault(require("react"));
10
- var _adfSchema = require("@atlaskit/adf-schema");
10
+ var _expand = require("@atlaskit/adf-schema/expand");
11
+ var _nestedExpand = require("@atlaskit/adf-schema/nested-expand");
11
12
  var _analytics = require("@atlaskit/editor-common/analytics");
12
13
  var _blockMenu = require("@atlaskit/editor-common/block-menu");
13
14
  var _messages = require("@atlaskit/editor-common/messages");
@@ -62,10 +63,10 @@ var expandPlugin = exports.expandPlugin = function expandPlugin(_ref) {
62
63
  nodes: function nodes() {
63
64
  return [{
64
65
  name: 'expand',
65
- node: _adfSchema.expandWithNestedExpand
66
+ node: _expand.expandWithNestedExpand
66
67
  }, {
67
68
  name: 'nestedExpand',
68
- node: _adfSchema.nestedExpand
69
+ node: _nestedExpand.nestedExpand
69
70
  }];
70
71
  },
71
72
  actions: {
@@ -7,7 +7,7 @@ Object.defineProperty(exports, "__esModule", {
7
7
  exports.wrapSelectionAndSetExpandedState = exports.updateExpandTitle = exports.toggleExpandWithMatch = exports.toggleExpandExpanded = exports.setSelectionInsideExpand = exports.insertExpandWithInputMethod = exports.insertExpand = exports.focusTitle = exports.focusIcon = exports.deleteExpandAtPos = exports.deleteExpand = exports.createExpandNode = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
9
9
  var _v = _interopRequireDefault(require("uuid/v4"));
10
- var _steps = require("@atlaskit/adf-schema/steps");
10
+ var _setAttrs = require("@atlaskit/adf-schema/steps/set-attrs");
11
11
  var _analytics = require("@atlaskit/editor-common/analytics");
12
12
  var _expand = require("@atlaskit/editor-common/expand");
13
13
  var _selection = require("@atlaskit/editor-common/selection");
@@ -214,7 +214,7 @@ var updateExpandTitle = exports.updateExpandTitle = function updateExpandTitle(_
214
214
  var node = state.doc.nodeAt(pos);
215
215
  if (node && node.type === nodeType && dispatch) {
216
216
  var tr = state.tr;
217
- tr.step(new _steps.SetAttrsStep(pos, _objectSpread(_objectSpread({}, node.attrs), {}, {
217
+ tr.step(new _setAttrs.SetAttrsStep(pos, _objectSpread(_objectSpread({}, node.attrs), {}, {
218
218
  title: title
219
219
  })));
220
220
  dispatch(tr);
@@ -7,7 +7,8 @@ Object.defineProperty(exports, "__esModule", {
7
7
  exports.expandPlugin = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
9
9
  var _react = _interopRequireDefault(require("react"));
10
- var _adfSchema = require("@atlaskit/adf-schema");
10
+ var _expand = require("@atlaskit/adf-schema/expand");
11
+ var _nestedExpand = require("@atlaskit/adf-schema/nested-expand");
11
12
  var _analytics = require("@atlaskit/editor-common/analytics");
12
13
  var _blockMenu = require("@atlaskit/editor-common/block-menu");
13
14
  var _messages = require("@atlaskit/editor-common/messages");
@@ -62,10 +63,10 @@ var expandPlugin = exports.expandPlugin = function expandPlugin(_ref) {
62
63
  nodes: function nodes() {
63
64
  return [{
64
65
  name: 'expand',
65
- node: (0, _fg.fg)('platform_editor_adf_with_localid') ? _adfSchema.expandWithNestedExpandLocalId : _adfSchema.expandWithNestedExpand
66
+ node: (0, _fg.fg)('platform_editor_adf_with_localid') ? _expand.expandWithNestedExpandLocalId : _expand.expandWithNestedExpand
66
67
  }, {
67
68
  name: 'nestedExpand',
68
- node: (0, _fg.fg)('platform_editor_adf_with_localid') ? _adfSchema.nestedExpandWithLocalId : _adfSchema.nestedExpand
69
+ node: (0, _fg.fg)('platform_editor_adf_with_localid') ? _nestedExpand.nestedExpandWithLocalId : _nestedExpand.nestedExpand
69
70
  }];
70
71
  },
71
72
  actions: {
@@ -1,4 +1,4 @@
1
- import { SetAttrsStep } from '@atlaskit/adf-schema/steps';
1
+ import { SetAttrsStep } from '@atlaskit/adf-schema/steps/set-attrs';
2
2
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD, MODE, PLATFORMS } from '@atlaskit/editor-common/analytics';
3
3
  import { GapCursorSelection, Side } from '@atlaskit/editor-common/selection';
4
4
  import { expandClassNames } from '@atlaskit/editor-common/styles';
@@ -1,5 +1,6 @@
1
1
  import React from 'react';
2
- import { expandWithNestedExpand, nestedExpand } from '@atlaskit/adf-schema';
2
+ import { expandWithNestedExpand } from '@atlaskit/adf-schema/expand';
3
+ import { nestedExpand } from '@atlaskit/adf-schema/nested-expand';
3
4
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
4
5
  import { TRANSFORM_STRUCTURE_EXPAND_MENU_ITEM, TRANSFORM_STRUCTURE_MENU_SECTION, TRANSFORM_STRUCTURE_MENU_SECTION_RANK } from '@atlaskit/editor-common/block-menu';
5
6
  import { toolbarInsertBlockMessages as messages } from '@atlaskit/editor-common/messages';
@@ -1,6 +1,6 @@
1
1
  // eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
2
2
  import uuid from 'uuid/v4';
3
- import { SetAttrsStep } from '@atlaskit/adf-schema/steps';
3
+ import { SetAttrsStep } from '@atlaskit/adf-schema/steps/set-attrs';
4
4
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD, MODE, PLATFORMS } from '@atlaskit/editor-common/analytics';
5
5
  import { expandedState } from '@atlaskit/editor-common/expand';
6
6
  import { GapCursorSelection, Side } from '@atlaskit/editor-common/selection';
@@ -1,5 +1,6 @@
1
1
  import React from 'react';
2
- import { expandWithNestedExpand, expandWithNestedExpandLocalId, nestedExpand, nestedExpandWithLocalId } from '@atlaskit/adf-schema';
2
+ import { expandWithNestedExpand, expandWithNestedExpandLocalId } from '@atlaskit/adf-schema/expand';
3
+ import { nestedExpand, nestedExpandWithLocalId } from '@atlaskit/adf-schema/nested-expand';
3
4
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
4
5
  import { TRANSFORM_STRUCTURE_EXPAND_MENU_ITEM, TRANSFORM_STRUCTURE_MENU_SECTION, TRANSFORM_STRUCTURE_MENU_SECTION_RANK } from '@atlaskit/editor-common/block-menu';
5
6
  import { toolbarInsertBlockMessages as messages } from '@atlaskit/editor-common/messages';
@@ -1,7 +1,7 @@
1
1
  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
- import { SetAttrsStep } from '@atlaskit/adf-schema/steps';
4
+ import { SetAttrsStep } from '@atlaskit/adf-schema/steps/set-attrs';
5
5
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD, MODE, PLATFORMS } from '@atlaskit/editor-common/analytics';
6
6
  import { GapCursorSelection, Side } from '@atlaskit/editor-common/selection';
7
7
  import { expandClassNames } from '@atlaskit/editor-common/styles';
@@ -2,7 +2,8 @@ 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 React from 'react';
5
- import { expandWithNestedExpand, nestedExpand } from '@atlaskit/adf-schema';
5
+ import { expandWithNestedExpand } from '@atlaskit/adf-schema/expand';
6
+ import { nestedExpand } from '@atlaskit/adf-schema/nested-expand';
6
7
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
7
8
  import { TRANSFORM_STRUCTURE_EXPAND_MENU_ITEM, TRANSFORM_STRUCTURE_MENU_SECTION, TRANSFORM_STRUCTURE_MENU_SECTION_RANK } from '@atlaskit/editor-common/block-menu';
8
9
  import { toolbarInsertBlockMessages as messages } from '@atlaskit/editor-common/messages';
@@ -3,7 +3,7 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
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
  // eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
5
5
  import uuid from 'uuid/v4';
6
- import { SetAttrsStep } from '@atlaskit/adf-schema/steps';
6
+ import { SetAttrsStep } from '@atlaskit/adf-schema/steps/set-attrs';
7
7
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD, MODE, PLATFORMS } from '@atlaskit/editor-common/analytics';
8
8
  import { expandedState } from '@atlaskit/editor-common/expand';
9
9
  import { GapCursorSelection, Side } from '@atlaskit/editor-common/selection';
@@ -2,7 +2,8 @@ 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 React from 'react';
5
- import { expandWithNestedExpand, expandWithNestedExpandLocalId, nestedExpand, nestedExpandWithLocalId } from '@atlaskit/adf-schema';
5
+ import { expandWithNestedExpand, expandWithNestedExpandLocalId } from '@atlaskit/adf-schema/expand';
6
+ import { nestedExpand, nestedExpandWithLocalId } from '@atlaskit/adf-schema/nested-expand';
6
7
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
7
8
  import { TRANSFORM_STRUCTURE_EXPAND_MENU_ITEM, TRANSFORM_STRUCTURE_MENU_SECTION, TRANSFORM_STRUCTURE_MENU_SECTION_RANK } from '@atlaskit/editor-common/block-menu';
8
9
  import { toolbarInsertBlockMessages as messages } from '@atlaskit/editor-common/messages';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-expand",
3
- "version": "17.1.4",
3
+ "version": "17.1.5",
4
4
  "description": "Expand plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -25,7 +25,7 @@
25
25
  "@atlaskit/button": "^25.3.0",
26
26
  "@atlaskit/editor-plugin-analytics": "^16.1.0",
27
27
  "@atlaskit/editor-plugin-block-controls": "^17.3.0",
28
- "@atlaskit/editor-plugin-block-menu": "^15.0.0",
28
+ "@atlaskit/editor-plugin-block-menu": "^15.1.0",
29
29
  "@atlaskit/editor-plugin-decorations": "^16.1.0",
30
30
  "@atlaskit/editor-plugin-editor-disabled": "^16.1.0",
31
31
  "@atlaskit/editor-plugin-editor-viewmode": "^18.0.0",
@@ -43,7 +43,7 @@
43
43
  "@atlaskit/platform-feature-experiments": "^0.3.0",
44
44
  "@atlaskit/platform-feature-flags": "^2.2.0",
45
45
  "@atlaskit/prosemirror-history": "^1.2.0",
46
- "@atlaskit/tmp-editor-statsig": "^172.0.0",
46
+ "@atlaskit/tmp-editor-statsig": "^173.0.0",
47
47
  "@atlaskit/tokens": "^16.11.0",
48
48
  "@atlaskit/tooltip": "^24.3.0",
49
49
  "@babel/runtime": "^7.0.0",