@atlaskit/editor-core 193.30.0 → 193.30.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/afm-cc/tsconfig.json +0 -3
- package/afm-jira/tsconfig.json +0 -3
- package/dist/cjs/actions/index.js +1 -2
- package/dist/cjs/create-editor/ReactEditorView.js +3 -4
- package/dist/cjs/ui/Addon/index.js +0 -7
- package/dist/cjs/ui/Appearance/Chromeless.js +2 -2
- package/dist/cjs/ui/Appearance/FullPage/StyledComponents.js +2 -2
- package/dist/cjs/ui/ContextPanel/index.js +2 -2
- package/dist/cjs/ui/ToolbarFeedback/index.js +4 -4
- package/dist/cjs/ui/ToolbarHelp/index.js +2 -2
- package/dist/cjs/utils/document.js +0 -6
- package/dist/cjs/utils/index.js +0 -157
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/actions/index.js +1 -2
- package/dist/es2019/create-editor/ReactEditorView.js +1 -2
- package/dist/es2019/ui/Addon/index.js +0 -1
- package/dist/es2019/ui/Appearance/Chromeless.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/StyledComponents.js +1 -1
- package/dist/es2019/ui/ContextPanel/index.js +1 -1
- package/dist/es2019/ui/ToolbarFeedback/index.js +2 -2
- package/dist/es2019/ui/ToolbarHelp/index.js +1 -1
- package/dist/es2019/utils/document.js +0 -1
- package/dist/es2019/utils/index.js +1 -73
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/actions/index.js +1 -2
- package/dist/esm/create-editor/ReactEditorView.js +1 -2
- package/dist/esm/ui/Addon/index.js +0 -1
- package/dist/esm/ui/Appearance/Chromeless.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/StyledComponents.js +1 -1
- package/dist/esm/ui/ContextPanel/index.js +1 -1
- package/dist/esm/ui/ToolbarFeedback/index.js +2 -2
- package/dist/esm/ui/ToolbarHelp/index.js +1 -1
- package/dist/esm/utils/document.js +0 -1
- package/dist/esm/utils/index.js +1 -75
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/actions/index.d.ts +1 -1
- package/dist/types/ui/Addon/index.d.ts +0 -1
- package/dist/types/ui/Appearance/FullPage/StyledComponents.d.ts +1 -1
- package/dist/types/ui/ContentStyles/index.d.ts +2 -2
- package/dist/types/utils/document.d.ts +0 -1
- package/dist/types/utils/index.d.ts +0 -22
- package/dist/types-ts4.5/actions/index.d.ts +1 -1
- package/dist/types-ts4.5/ui/Addon/index.d.ts +0 -1
- package/dist/types-ts4.5/ui/Appearance/FullPage/StyledComponents.d.ts +1 -1
- package/dist/types-ts4.5/ui/ContentStyles/index.d.ts +2 -2
- package/dist/types-ts4.5/utils/document.d.ts +0 -1
- package/dist/types-ts4.5/utils/index.d.ts +0 -22
- package/package.json +14 -10
- package/dist/cjs/keymaps/index.js +0 -594
- package/dist/cjs/ui/Addon/DropdownItem/index.js +0 -24
- package/dist/cjs/ui/Addon/DropdownItem/styles.js +0 -27
- package/dist/cjs/ui/ToolbarButton/index.js +0 -14
- package/dist/cjs/ui/WithPluginState/index.js +0 -8
- package/dist/cjs/ui/styles.js +0 -19
- package/dist/cjs/ui/with-outer-listeners.js +0 -8
- package/dist/cjs/utils/nodes.js +0 -36
- package/dist/es2019/keymaps/index.js +0 -1
- package/dist/es2019/ui/Addon/DropdownItem/index.js +0 -13
- package/dist/es2019/ui/Addon/DropdownItem/styles.js +0 -20
- package/dist/es2019/ui/ToolbarButton/index.js +0 -3
- package/dist/es2019/ui/WithPluginState/index.js +0 -2
- package/dist/es2019/ui/styles.js +0 -2
- package/dist/es2019/ui/with-outer-listeners.js +0 -2
- package/dist/es2019/utils/nodes.js +0 -1
- package/dist/esm/keymaps/index.js +0 -1
- package/dist/esm/ui/Addon/DropdownItem/index.js +0 -17
- package/dist/esm/ui/Addon/DropdownItem/styles.js +0 -20
- package/dist/esm/ui/ToolbarButton/index.js +0 -3
- package/dist/esm/ui/WithPluginState/index.js +0 -2
- package/dist/esm/ui/styles.js +0 -2
- package/dist/esm/ui/with-outer-listeners.js +0 -2
- package/dist/esm/utils/nodes.js +0 -1
- package/dist/types/keymaps/index.d.ts +0 -2
- package/dist/types/ui/Addon/DropdownItem/index.d.ts +0 -5
- package/dist/types/ui/Addon/DropdownItem/styles.d.ts +0 -1
- package/dist/types/ui/ToolbarButton/index.d.ts +0 -4
- package/dist/types/ui/WithPluginState/index.d.ts +0 -4
- package/dist/types/ui/styles.d.ts +0 -2
- package/dist/types/ui/with-outer-listeners.d.ts +0 -2
- package/dist/types/utils/nodes.d.ts +0 -1
- package/dist/types-ts4.5/keymaps/index.d.ts +0 -2
- package/dist/types-ts4.5/ui/Addon/DropdownItem/index.d.ts +0 -5
- package/dist/types-ts4.5/ui/Addon/DropdownItem/styles.d.ts +0 -1
- package/dist/types-ts4.5/ui/ToolbarButton/index.d.ts +0 -4
- package/dist/types-ts4.5/ui/WithPluginState/index.d.ts +0 -4
- package/dist/types-ts4.5/ui/styles.d.ts +0 -2
- package/dist/types-ts4.5/ui/with-outer-listeners.d.ts +0 -2
- package/dist/types-ts4.5/utils/nodes.d.ts +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @atlaskit/editor-core
|
|
2
2
|
|
|
3
|
+
## 193.30.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 193.30.1
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#115969](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/115969)
|
|
14
|
+
[`761dca055a7af`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/761dca055a7af) -
|
|
15
|
+
Cleanup unused code in editor-core.
|
|
16
|
+
|
|
3
17
|
## 193.30.0
|
|
4
18
|
|
|
5
19
|
### Minor Changes
|
package/afm-cc/tsconfig.json
CHANGED
package/afm-jira/tsconfig.json
CHANGED
|
@@ -15,7 +15,6 @@ var _model = require("@atlaskit/editor-prosemirror/model");
|
|
|
15
15
|
var _state = require("@atlaskit/editor-prosemirror/state");
|
|
16
16
|
var _utils2 = require("@atlaskit/editor-prosemirror/utils");
|
|
17
17
|
var _eventDispatcher = require("../event-dispatcher");
|
|
18
|
-
var _utils3 = require("../utils");
|
|
19
18
|
var _action = require("../utils/action");
|
|
20
19
|
var _deprecationWarnings = _interopRequireDefault(require("../utils/deprecation-warnings"));
|
|
21
20
|
var _document = require("../utils/document");
|
|
@@ -255,7 +254,7 @@ var EditorActions = exports.default = /*#__PURE__*/function () {
|
|
|
255
254
|
return (0, _action.getEditorValueWithMedia)(editorView);
|
|
256
255
|
case 5:
|
|
257
256
|
doc = _context3.sent;
|
|
258
|
-
json = (0,
|
|
257
|
+
json = (0, _utils.toJSON)(doc);
|
|
259
258
|
if (this.contentEncode) {
|
|
260
259
|
_context3.next = 9;
|
|
261
260
|
break;
|
|
@@ -29,7 +29,6 @@ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
|
29
29
|
var _eventDispatcher = require("../event-dispatcher");
|
|
30
30
|
var _document = require("../utils/document");
|
|
31
31
|
var _isFullPage = require("../utils/is-full-page");
|
|
32
|
-
var _nodes = require("../utils/nodes");
|
|
33
32
|
var _RenderTracking = require("../utils/performance/components/RenderTracking");
|
|
34
33
|
var _measureEnum = _interopRequireDefault(require("../utils/performance/measure-enum"));
|
|
35
34
|
var _pluginPerformanceObserver = require("../utils/performance/plugin-performance-observer");
|
|
@@ -301,8 +300,8 @@ var ReactEditorView = exports.ReactEditorView = /*#__PURE__*/function (_React$Co
|
|
|
301
300
|
var _this$experienceStore;
|
|
302
301
|
(_this$experienceStore = _this.experienceStore) === null || _this$experienceStore === void 0 || _this$experienceStore.start(_ufo.EditorExperience.interaction);
|
|
303
302
|
}
|
|
304
|
-
var nodes = (0,
|
|
305
|
-
var changedNodesValid = (0,
|
|
303
|
+
var nodes = (0, _utils.findChangedNodesFromTransaction)(unsafeTransaction);
|
|
304
|
+
var changedNodesValid = (0, _utils.validateNodes)(nodes);
|
|
306
305
|
var transaction = new Proxy(unsafeTransaction, (0, _saferTransactions.freezeUnsafeTransactionProperties)({
|
|
307
306
|
dispatchAnalyticsEvent: _this.dispatchAnalyticsEvent,
|
|
308
307
|
pluginKey: 'unknown-reacteditorview'
|
|
@@ -376,7 +375,7 @@ var ReactEditorView = exports.ReactEditorView = /*#__PURE__*/function (_React$Co
|
|
|
376
375
|
} else {
|
|
377
376
|
var _this$experienceStore8;
|
|
378
377
|
var invalidNodes = nodes.filter(function (node) {
|
|
379
|
-
return !(0,
|
|
378
|
+
return !(0, _utils.validNode)(node);
|
|
380
379
|
}).map(function (node) {
|
|
381
380
|
return (0, _coreUtils.getDocStructure)(node, {
|
|
382
381
|
compact: true
|
|
@@ -4,12 +4,6 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
|
-
Object.defineProperty(exports, "Addon", {
|
|
8
|
-
enumerable: true,
|
|
9
|
-
get: function get() {
|
|
10
|
-
return _DropdownItem.default;
|
|
11
|
-
}
|
|
12
|
-
});
|
|
13
7
|
Object.defineProperty(exports, "ClickAreaBlock", {
|
|
14
8
|
enumerable: true,
|
|
15
9
|
get: function get() {
|
|
@@ -34,7 +28,6 @@ Object.defineProperty(exports, "Dropdown", {
|
|
|
34
28
|
return _Dropdown.default;
|
|
35
29
|
}
|
|
36
30
|
});
|
|
37
|
-
var _DropdownItem = _interopRequireDefault(require("./DropdownItem"));
|
|
38
31
|
var _Dropdown = _interopRequireDefault(require("./Dropdown"));
|
|
39
32
|
var _ClickAreaInline = _interopRequireDefault(require("./ClickAreaInline"));
|
|
40
33
|
var _ClickAreaBlock = _interopRequireDefault(require("./ClickAreaBlock"));
|
|
@@ -16,10 +16,10 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
|
|
|
16
16
|
var _react = _interopRequireWildcard(require("react"));
|
|
17
17
|
var _react2 = require("@emotion/react");
|
|
18
18
|
var _hooks = require("@atlaskit/editor-common/hooks");
|
|
19
|
+
var _scrollbar = require("@atlaskit/editor-shared-styles/scrollbar");
|
|
19
20
|
var _context = require("../../presets/context");
|
|
20
21
|
var _ContentStyles = require("../ContentStyles");
|
|
21
22
|
var _PluginSlot = _interopRequireDefault(require("../PluginSlot"));
|
|
22
|
-
var _styles = require("../styles");
|
|
23
23
|
var _WithFlash = _interopRequireDefault(require("../WithFlash"));
|
|
24
24
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
25
25
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
@@ -32,7 +32,7 @@ var chromelessEditorStyles = (0, _react2.css)({
|
|
|
32
32
|
overflowY: 'auto'
|
|
33
33
|
},
|
|
34
34
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
35
|
-
|
|
35
|
+
_scrollbar.scrollbarStyles, {
|
|
36
36
|
maxWidth: 'inherit',
|
|
37
37
|
boxSizing: 'border-box',
|
|
38
38
|
wordWrap: 'break-word',
|
|
@@ -11,9 +11,9 @@ var _adfSchema = require("@atlaskit/adf-schema");
|
|
|
11
11
|
var _commonStyles = require("@atlaskit/editor-plugins/table/ui/common-styles");
|
|
12
12
|
var _consts = require("@atlaskit/editor-plugins/table/ui/consts");
|
|
13
13
|
var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
|
|
14
|
+
var _scrollbar = require("@atlaskit/editor-shared-styles/scrollbar");
|
|
14
15
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
15
16
|
var _ContentStyles = require("../../ContentStyles");
|
|
16
|
-
var _styles = require("../../styles");
|
|
17
17
|
var _ProseMirror; // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
18
18
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
19
19
|
var SWOOP_ANIMATION = "0.5s ".concat(_editorSharedStyles.akEditorSwoopCubicBezier);
|
|
@@ -39,7 +39,7 @@ var scrollStyles = (0, _react.css)({
|
|
|
39
39
|
scrollBehavior: 'smooth'
|
|
40
40
|
},
|
|
41
41
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
42
|
-
|
|
42
|
+
_scrollbar.scrollbarStyles);
|
|
43
43
|
|
|
44
44
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles, @atlaskit/design-system/no-exported-css -- Ignored via go/DSP-18766
|
|
45
45
|
var ScrollContainer = exports.ScrollContainer = (0, _ContentStyles.createEditorContentStyle)(scrollStyles);
|
|
@@ -21,12 +21,12 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
21
21
|
var _react2 = require("@emotion/react");
|
|
22
22
|
var _Transition = _interopRequireDefault(require("react-transition-group/Transition"));
|
|
23
23
|
var _ui = require("@atlaskit/editor-common/ui");
|
|
24
|
+
var _withPluginState = require("@atlaskit/editor-common/with-plugin-state");
|
|
24
25
|
var _utils = require("@atlaskit/editor-prosemirror/utils");
|
|
25
26
|
var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
|
|
26
27
|
var _colors = require("@atlaskit/theme/colors");
|
|
27
28
|
var _document = require("../../utils/document");
|
|
28
29
|
var _WithEditorActions = _interopRequireDefault(require("../WithEditorActions"));
|
|
29
|
-
var _WithPluginState = _interopRequireDefault(require("../WithPluginState"));
|
|
30
30
|
var _excluded = ["actions"];
|
|
31
31
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
32
32
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
@@ -244,7 +244,7 @@ function ContextPanelWithActions(_ref2) {
|
|
|
244
244
|
return (
|
|
245
245
|
// @ts-ignore - 'WithPluginState' cannot be used as a JSX component.
|
|
246
246
|
// This error was introduced after upgrading to TypeScript 5
|
|
247
|
-
(0, _react2.jsx)(
|
|
247
|
+
(0, _react2.jsx)(_withPluginState.WithPluginState, {
|
|
248
248
|
eventDispatcher: eventDispatcher,
|
|
249
249
|
plugins: {
|
|
250
250
|
contextPanel: contextPanelPluginKey,
|
|
@@ -23,19 +23,19 @@ var _button = _interopRequireDefault(require("@atlaskit/button"));
|
|
|
23
23
|
var _buttonGroup = _interopRequireDefault(require("@atlaskit/button/button-group"));
|
|
24
24
|
var _analytics = require("@atlaskit/editor-common/analytics");
|
|
25
25
|
var _ui = require("@atlaskit/editor-common/ui");
|
|
26
|
+
var _uiMenu = require("@atlaskit/editor-common/ui-menu");
|
|
27
|
+
var _uiReact = require("@atlaskit/editor-common/ui-react");
|
|
26
28
|
var _utils = require("@atlaskit/editor-common/utils");
|
|
27
29
|
var _spinner = _interopRequireDefault(require("@atlaskit/spinner"));
|
|
28
30
|
var _eventDispatcher = require("../../event-dispatcher");
|
|
29
31
|
var _context2 = require("../../presets/context");
|
|
30
32
|
var _deprecationWarnings = _interopRequireDefault(require("../../utils/deprecation-warnings"));
|
|
31
|
-
var _ToolbarButton = _interopRequireDefault(require("../ToolbarButton"));
|
|
32
|
-
var _withOuterListeners = _interopRequireDefault(require("../with-outer-listeners"));
|
|
33
33
|
var _styles = require("./styles");
|
|
34
34
|
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; }
|
|
35
35
|
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) { (0, _defineProperty2.default)(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; }
|
|
36
36
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
37
37
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /** @jsx jsx */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
38
|
-
var PopupWithOutsideListeners = (0,
|
|
38
|
+
var PopupWithOutsideListeners = (0, _uiReact.withReactEditorViewOuterListeners)(_ui.Popup);
|
|
39
39
|
var POPUP_HEIGHT = 388;
|
|
40
40
|
var POPUP_WIDTH = 280;
|
|
41
41
|
var EDITOR_IMAGE_URL = 'https://confluence.atlassian.com/download/attachments/945114421/editorillustration@2x.png?api=v2';
|
|
@@ -167,7 +167,7 @@ var ToolbarFeedbackInternal = /*#__PURE__*/function (_PureComponent) {
|
|
|
167
167
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
|
|
168
168
|
(0, _react2.jsx)("div", {
|
|
169
169
|
css: _styles.wrapper
|
|
170
|
-
}, (0, _react2.jsx)(
|
|
170
|
+
}, (0, _react2.jsx)(_uiMenu.ToolbarButton, {
|
|
171
171
|
ref: this.handleRef,
|
|
172
172
|
iconBefore: iconBefore,
|
|
173
173
|
onClick: this.collectFeedback,
|
|
@@ -7,8 +7,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.default = void 0;
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
var _reactIntlNext = require("react-intl-next");
|
|
10
|
+
var _uiMenu = require("@atlaskit/editor-common/ui-menu");
|
|
10
11
|
var _question = _interopRequireDefault(require("@atlaskit/icon/glyph/question"));
|
|
11
|
-
var _ToolbarButton = _interopRequireDefault(require("../ToolbarButton"));
|
|
12
12
|
var _WithHelpTrigger = _interopRequireDefault(require("../WithHelpTrigger"));
|
|
13
13
|
var _messages = require("./messages");
|
|
14
14
|
var TooltipHelpTrigger = function TooltipHelpTrigger(_ref) {
|
|
@@ -24,7 +24,7 @@ var TooltipHelpTrigger = function TooltipHelpTrigger(_ref) {
|
|
|
24
24
|
}
|
|
25
25
|
return /*#__PURE__*/_react.default.createElement(_WithHelpTrigger.default, {
|
|
26
26
|
render: function render(showHelp) {
|
|
27
|
-
return /*#__PURE__*/_react.default.createElement(
|
|
27
|
+
return /*#__PURE__*/_react.default.createElement(_uiMenu.ToolbarButton, {
|
|
28
28
|
onClick: showHelp,
|
|
29
29
|
title: displayTitle,
|
|
30
30
|
titlePosition: titlePosition,
|
|
@@ -6,12 +6,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.getChildBreakoutModes = getChildBreakoutModes;
|
|
8
8
|
exports.getNodesCount = getNodesCount;
|
|
9
|
-
Object.defineProperty(exports, "isInEmptyLine", {
|
|
10
|
-
enumerable: true,
|
|
11
|
-
get: function get() {
|
|
12
|
-
return _utils.isInEmptyLine;
|
|
13
|
-
}
|
|
14
|
-
});
|
|
15
9
|
exports.processRawFragmentValue = processRawFragmentValue;
|
|
16
10
|
var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
|
|
17
11
|
var _utils = require("@atlaskit/editor-common/utils");
|
package/dist/cjs/utils/index.js
CHANGED
|
@@ -4,167 +4,21 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
|
-
Object.defineProperty(exports, "SetAttrsStep", {
|
|
8
|
-
enumerable: true,
|
|
9
|
-
get: function get() {
|
|
10
|
-
return _steps.SetAttrsStep;
|
|
11
|
-
}
|
|
12
|
-
});
|
|
13
|
-
Object.defineProperty(exports, "checkNodeDown", {
|
|
14
|
-
enumerable: true,
|
|
15
|
-
get: function get() {
|
|
16
|
-
return _utils.checkNodeDown;
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
7
|
Object.defineProperty(exports, "getNodesCount", {
|
|
20
8
|
enumerable: true,
|
|
21
9
|
get: function get() {
|
|
22
10
|
return _document.getNodesCount;
|
|
23
11
|
}
|
|
24
12
|
});
|
|
25
|
-
exports.hasOpenEnd = void 0;
|
|
26
|
-
Object.defineProperty(exports, "insideTable", {
|
|
27
|
-
enumerable: true,
|
|
28
|
-
get: function get() {
|
|
29
|
-
return _coreUtils.insideTable;
|
|
30
|
-
}
|
|
31
|
-
});
|
|
32
|
-
Object.defineProperty(exports, "insideTableCell", {
|
|
33
|
-
enumerable: true,
|
|
34
|
-
get: function get() {
|
|
35
|
-
return _utils.insideTableCell;
|
|
36
|
-
}
|
|
37
|
-
});
|
|
38
|
-
Object.defineProperty(exports, "isElementInTableCell", {
|
|
39
|
-
enumerable: true,
|
|
40
|
-
get: function get() {
|
|
41
|
-
return _utils.isElementInTableCell;
|
|
42
|
-
}
|
|
43
|
-
});
|
|
44
|
-
Object.defineProperty(exports, "isEmptyNode", {
|
|
45
|
-
enumerable: true,
|
|
46
|
-
get: function get() {
|
|
47
|
-
return _utils.isEmptyNode;
|
|
48
|
-
}
|
|
49
|
-
});
|
|
50
|
-
Object.defineProperty(exports, "isInListItem", {
|
|
51
|
-
enumerable: true,
|
|
52
|
-
get: function get() {
|
|
53
|
-
return _utils.isInListItem;
|
|
54
|
-
}
|
|
55
|
-
});
|
|
56
|
-
Object.defineProperty(exports, "isLastItemMediaGroup", {
|
|
57
|
-
enumerable: true,
|
|
58
|
-
get: function get() {
|
|
59
|
-
return _utils.isLastItemMediaGroup;
|
|
60
|
-
}
|
|
61
|
-
});
|
|
62
|
-
exports.isMarkTypeAllowedInCurrentSelection = isMarkTypeAllowedInCurrentSelection;
|
|
63
|
-
Object.defineProperty(exports, "isSelectionInsideLastNodeInDocument", {
|
|
64
|
-
enumerable: true,
|
|
65
|
-
get: function get() {
|
|
66
|
-
return _utils.isSelectionInsideLastNodeInDocument;
|
|
67
|
-
}
|
|
68
|
-
});
|
|
69
|
-
exports.isTemporary = void 0;
|
|
70
|
-
Object.defineProperty(exports, "isTextSelection", {
|
|
71
|
-
enumerable: true,
|
|
72
|
-
get: function get() {
|
|
73
|
-
return _utils.isTextSelection;
|
|
74
|
-
}
|
|
75
|
-
});
|
|
76
13
|
Object.defineProperty(exports, "measurements", {
|
|
77
14
|
enumerable: true,
|
|
78
15
|
get: function get() {
|
|
79
16
|
return _measureEnum.default;
|
|
80
17
|
}
|
|
81
18
|
});
|
|
82
|
-
Object.defineProperty(exports, "nodeToJSON", {
|
|
83
|
-
enumerable: true,
|
|
84
|
-
get: function get() {
|
|
85
|
-
return _utils.nodeToJSON;
|
|
86
|
-
}
|
|
87
|
-
});
|
|
88
|
-
Object.defineProperty(exports, "nonNullable", {
|
|
89
|
-
enumerable: true,
|
|
90
|
-
get: function get() {
|
|
91
|
-
return _utils.nonNullable;
|
|
92
|
-
}
|
|
93
|
-
});
|
|
94
|
-
exports.stringRepeat = stringRepeat;
|
|
95
|
-
exports.sum = sum;
|
|
96
|
-
Object.defineProperty(exports, "toJSON", {
|
|
97
|
-
enumerable: true,
|
|
98
|
-
get: function get() {
|
|
99
|
-
return _utils.toJSON;
|
|
100
|
-
}
|
|
101
|
-
});
|
|
102
19
|
exports.whichTransitionEvent = whichTransitionEvent;
|
|
103
|
-
var _commands = require("@atlaskit/editor-prosemirror/commands");
|
|
104
|
-
var _utils = require("@atlaskit/editor-common/utils");
|
|
105
|
-
var _coreUtils = require("@atlaskit/editor-common/core-utils");
|
|
106
20
|
var _document = require("./document");
|
|
107
21
|
var _measureEnum = _interopRequireDefault(require("./performance/measure-enum"));
|
|
108
|
-
var _steps = require("@atlaskit/adf-schema/steps");
|
|
109
|
-
function isMarkTypeCompatibleWithMark(markType, mark) {
|
|
110
|
-
return !mark.type.excludes(markType) && !markType.excludes(mark.type);
|
|
111
|
-
}
|
|
112
|
-
function isMarkTypeAllowedInNode(markType, state) {
|
|
113
|
-
return (0, _commands.toggleMark)(markType)(state);
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
/**
|
|
117
|
-
* Check if a mark is allowed at the current selection / cursor based on a given state.
|
|
118
|
-
* This method looks at both the currently active marks on the transaction, as well as
|
|
119
|
-
* the node and marks at the current selection to determine if the given mark type is
|
|
120
|
-
* allowed.
|
|
121
|
-
*/
|
|
122
|
-
function isMarkTypeAllowedInCurrentSelection(markType, state) {
|
|
123
|
-
if (!isMarkTypeAllowedInNode(markType, state)) {
|
|
124
|
-
return false;
|
|
125
|
-
}
|
|
126
|
-
var _ref = state.selection,
|
|
127
|
-
empty = _ref.empty,
|
|
128
|
-
$cursor = _ref.$cursor,
|
|
129
|
-
ranges = _ref.ranges;
|
|
130
|
-
if (empty && !$cursor) {
|
|
131
|
-
return false;
|
|
132
|
-
}
|
|
133
|
-
var isCompatibleMarkType = function isCompatibleMarkType(mark) {
|
|
134
|
-
return isMarkTypeCompatibleWithMark(markType, mark);
|
|
135
|
-
};
|
|
136
|
-
|
|
137
|
-
// Handle any new marks in the current transaction
|
|
138
|
-
if (state.tr.storedMarks && !state.tr.storedMarks.every(isCompatibleMarkType)) {
|
|
139
|
-
return false;
|
|
140
|
-
}
|
|
141
|
-
if ($cursor) {
|
|
142
|
-
return $cursor.marks().every(isCompatibleMarkType);
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
// Check every node in a selection - ensuring that it is compatible with the current mark type
|
|
146
|
-
return ranges.every(function (_ref2) {
|
|
147
|
-
var $from = _ref2.$from,
|
|
148
|
-
$to = _ref2.$to;
|
|
149
|
-
var allowedInActiveMarks = $from.depth === 0 ? state.doc.marks.every(isCompatibleMarkType) : true;
|
|
150
|
-
state.doc.nodesBetween($from.pos, $to.pos, function (node) {
|
|
151
|
-
allowedInActiveMarks = allowedInActiveMarks && node.marks.every(isCompatibleMarkType);
|
|
152
|
-
});
|
|
153
|
-
return allowedInActiveMarks;
|
|
154
|
-
});
|
|
155
|
-
}
|
|
156
|
-
|
|
157
|
-
/**
|
|
158
|
-
* Repeating string for multiple times
|
|
159
|
-
*/
|
|
160
|
-
function stringRepeat(text, length) {
|
|
161
|
-
var result = '';
|
|
162
|
-
for (var x = 0; x < length; x++) {
|
|
163
|
-
result += text;
|
|
164
|
-
}
|
|
165
|
-
return result;
|
|
166
|
-
}
|
|
167
|
-
|
|
168
22
|
/*
|
|
169
23
|
* From Modernizr
|
|
170
24
|
* Returns the kind of transitionevent available for the element
|
|
@@ -187,15 +41,4 @@ function whichTransitionEvent() {
|
|
|
187
41
|
}
|
|
188
42
|
}
|
|
189
43
|
return;
|
|
190
|
-
}
|
|
191
|
-
var isTemporary = exports.isTemporary = function isTemporary(id) {
|
|
192
|
-
return id.indexOf('temporary:') === 0;
|
|
193
|
-
};
|
|
194
|
-
var hasOpenEnd = exports.hasOpenEnd = function hasOpenEnd(slice) {
|
|
195
|
-
return slice.openStart > 0 || slice.openEnd > 0;
|
|
196
|
-
};
|
|
197
|
-
function sum(arr, f) {
|
|
198
|
-
return arr.reduce(function (val, x) {
|
|
199
|
-
return val + f(x);
|
|
200
|
-
}, 0);
|
|
201
44
|
}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
|
-
import { analyticsEventKey, findNodePosByLocalIds, isEmptyDocument, processRawValue } from '@atlaskit/editor-common/utils';
|
|
2
|
+
import { analyticsEventKey, findNodePosByLocalIds, isEmptyDocument, processRawValue, toJSON } from '@atlaskit/editor-common/utils';
|
|
3
3
|
import { Node } from '@atlaskit/editor-prosemirror/model';
|
|
4
4
|
import { NodeSelection, TextSelection } from '@atlaskit/editor-prosemirror/state';
|
|
5
5
|
import { findParentNode, safeInsert } from '@atlaskit/editor-prosemirror/utils';
|
|
6
6
|
import { createDispatch } from '../event-dispatcher';
|
|
7
|
-
import { toJSON } from '../utils';
|
|
8
7
|
import { __temporaryFixForConfigPanel, getEditorValueWithMedia } from '../utils/action';
|
|
9
8
|
import deprecationWarnings from '../utils/deprecation-warnings';
|
|
10
9
|
import { processRawFragmentValue } from '../utils/document';
|
|
@@ -8,14 +8,13 @@ import { getEnabledFeatureFlagKeys } from '@atlaskit/editor-common/normalize-fea
|
|
|
8
8
|
import { EditorPluginInjectionAPI } from '@atlaskit/editor-common/preset';
|
|
9
9
|
import { EditorExperience, ExperienceStore, RELIABILITY_INTERVAL } from '@atlaskit/editor-common/ufo';
|
|
10
10
|
import { EDIT_AREA_ID } from '@atlaskit/editor-common/ui';
|
|
11
|
-
import { analyticsEventKey, browser, countNodes, getAnalyticsEventSeverity, getResponseEndTime, measureRender, processRawValue, shouldForceTracking, startMeasure, stopMeasure } from '@atlaskit/editor-common/utils';
|
|
11
|
+
import { analyticsEventKey, browser, countNodes, findChangedNodesFromTransaction, getAnalyticsEventSeverity, getResponseEndTime, measureRender, processRawValue, shouldForceTracking, startMeasure, stopMeasure, validateNodes, validNode } from '@atlaskit/editor-common/utils';
|
|
12
12
|
import { EditorState, Selection, TextSelection } from '@atlaskit/editor-prosemirror/state';
|
|
13
13
|
import { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
14
14
|
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
15
15
|
import { createDispatch, EventDispatcher } from '../event-dispatcher';
|
|
16
16
|
import { getNodesCount } from '../utils/document';
|
|
17
17
|
import { isFullPage } from '../utils/is-full-page';
|
|
18
|
-
import { findChangedNodesFromTransaction, validateNodes, validNode } from '../utils/nodes';
|
|
19
18
|
import { RenderTracking } from '../utils/performance/components/RenderTracking';
|
|
20
19
|
import measurements from '../utils/performance/measure-enum';
|
|
21
20
|
import { PluginPerformanceObserver } from '../utils/performance/plugin-performance-observer';
|
|
@@ -5,10 +5,10 @@ import React, { Fragment } from 'react';
|
|
|
5
5
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
6
6
|
import { css, jsx } from '@emotion/react';
|
|
7
7
|
import { useSharedPluginState } from '@atlaskit/editor-common/hooks';
|
|
8
|
+
import { scrollbarStyles } from '@atlaskit/editor-shared-styles/scrollbar';
|
|
8
9
|
import { usePresetContext } from '../../presets/context';
|
|
9
10
|
import { createEditorContentStyle } from '../ContentStyles';
|
|
10
11
|
import PluginSlot from '../PluginSlot';
|
|
11
|
-
import { scrollbarStyles } from '../styles';
|
|
12
12
|
import WithFlash from '../WithFlash';
|
|
13
13
|
const chromelessEditorStyles = css({
|
|
14
14
|
lineHeight: '20px',
|
|
@@ -4,9 +4,9 @@ import { decisionListSelector, taskListSelector } from '@atlaskit/adf-schema';
|
|
|
4
4
|
import { tableFullPageEditorStyles } from '@atlaskit/editor-plugins/table/ui/common-styles';
|
|
5
5
|
import { tableMarginFullWidthMode } from '@atlaskit/editor-plugins/table/ui/consts';
|
|
6
6
|
import { akEditorContextPanelWidth, akEditorFullWidthLayoutWidth, akEditorGutterPaddingDynamic, akEditorSwoopCubicBezier, akLayoutGutterOffset, FULL_PAGE_EDITOR_TOOLBAR_HEIGHT } from '@atlaskit/editor-shared-styles';
|
|
7
|
+
import { scrollbarStyles } from '@atlaskit/editor-shared-styles/scrollbar';
|
|
7
8
|
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
8
9
|
import { createEditorContentStyle } from '../../ContentStyles';
|
|
9
|
-
import { scrollbarStyles } from '../../styles';
|
|
10
10
|
|
|
11
11
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
12
12
|
const SWOOP_ANIMATION = `0.5s ${akEditorSwoopCubicBezier}`;
|
|
@@ -7,12 +7,12 @@ import React, { useContext } from 'react';
|
|
|
7
7
|
import { css, jsx } from '@emotion/react';
|
|
8
8
|
import Transition from 'react-transition-group/Transition';
|
|
9
9
|
import { ContextPanelConsumer, WidthContext } from '@atlaskit/editor-common/ui';
|
|
10
|
+
import { WithPluginState } from '@atlaskit/editor-common/with-plugin-state';
|
|
10
11
|
import { findChildrenByType } from '@atlaskit/editor-prosemirror/utils';
|
|
11
12
|
import { akEditorBreakoutPadding, akEditorContextPanelWidth, akEditorDefaultLayoutWidth, akEditorSwoopCubicBezier, akEditorWideLayoutWidth, FULL_PAGE_EDITOR_TOOLBAR_HEIGHT } from '@atlaskit/editor-shared-styles';
|
|
12
13
|
import { N30 } from '@atlaskit/theme/colors';
|
|
13
14
|
import { getChildBreakoutModes } from '../../utils/document';
|
|
14
15
|
import WithEditorActions from '../WithEditorActions';
|
|
15
|
-
import WithPluginState from '../WithPluginState';
|
|
16
16
|
const ANIM_SPEED_MS = 500;
|
|
17
17
|
const EDITOR_WIDTH = akEditorDefaultLayoutWidth + akEditorBreakoutPadding;
|
|
18
18
|
const WIDE_EDITOR_WIDTH = akEditorWideLayoutWidth + akEditorBreakoutPadding;
|
|
@@ -11,13 +11,13 @@ import Button from '@atlaskit/button';
|
|
|
11
11
|
import ButtonGroup from '@atlaskit/button/button-group';
|
|
12
12
|
import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE } from '@atlaskit/editor-common/analytics';
|
|
13
13
|
import { Popup } from '@atlaskit/editor-common/ui';
|
|
14
|
+
import { ToolbarButton } from '@atlaskit/editor-common/ui-menu';
|
|
15
|
+
import { withReactEditorViewOuterListeners as withOuterListeners } from '@atlaskit/editor-common/ui-react';
|
|
14
16
|
import { analyticsEventKey } from '@atlaskit/editor-common/utils';
|
|
15
17
|
import Spinner from '@atlaskit/spinner';
|
|
16
18
|
import { createDispatch } from '../../event-dispatcher';
|
|
17
19
|
import { usePresetContext } from '../../presets/context';
|
|
18
20
|
import deprecationWarnings from '../../utils/deprecation-warnings';
|
|
19
|
-
import ToolbarButton from '../ToolbarButton';
|
|
20
|
-
import withOuterListeners from '../with-outer-listeners';
|
|
21
21
|
import { buttonContent, confirmationHeader, confirmationImg, confirmationPopup, confirmationText, wrapper } from './styles';
|
|
22
22
|
const PopupWithOutsideListeners = withOuterListeners(Popup);
|
|
23
23
|
const POPUP_HEIGHT = 388;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { injectIntl } from 'react-intl-next';
|
|
3
|
+
import { ToolbarButton } from '@atlaskit/editor-common/ui-menu';
|
|
3
4
|
import QuestionIcon from '@atlaskit/icon/glyph/question';
|
|
4
|
-
import ToolbarButton from '../ToolbarButton';
|
|
5
5
|
import WithHelpTrigger from '../WithHelpTrigger';
|
|
6
6
|
import { messages } from './messages';
|
|
7
7
|
const TooltipHelpTrigger = ({
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { processRawValue } from '@atlaskit/editor-common/utils';
|
|
2
2
|
import { Fragment } from '@atlaskit/editor-prosemirror/model';
|
|
3
3
|
import { getBreakoutMode } from './node-width';
|
|
4
|
-
export { isInEmptyLine } from '@atlaskit/editor-common/utils';
|
|
5
4
|
export function processRawFragmentValue(schema, value, providerFactory, sanitizePrivateContent, contentTransformer, dispatchAnalyticsEvent) {
|
|
6
5
|
if (!value) {
|
|
7
6
|
return;
|
|
@@ -1,66 +1,5 @@
|
|
|
1
|
-
import { toggleMark } from '@atlaskit/editor-prosemirror/commands';
|
|
2
|
-
export { isEmptyNode, isSelectionInsideLastNodeInDocument, checkNodeDown, insideTableCell, isInListItem, toJSON, nodeToJSON } from '@atlaskit/editor-common/utils';
|
|
3
|
-
export { insideTable } from '@atlaskit/editor-common/core-utils';
|
|
4
1
|
export { getNodesCount } from './document';
|
|
5
2
|
export { default as measurements } from './performance/measure-enum';
|
|
6
|
-
function isMarkTypeCompatibleWithMark(markType, mark) {
|
|
7
|
-
return !mark.type.excludes(markType) && !markType.excludes(mark.type);
|
|
8
|
-
}
|
|
9
|
-
function isMarkTypeAllowedInNode(markType, state) {
|
|
10
|
-
return toggleMark(markType)(state);
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
/**
|
|
14
|
-
* Check if a mark is allowed at the current selection / cursor based on a given state.
|
|
15
|
-
* This method looks at both the currently active marks on the transaction, as well as
|
|
16
|
-
* the node and marks at the current selection to determine if the given mark type is
|
|
17
|
-
* allowed.
|
|
18
|
-
*/
|
|
19
|
-
export function isMarkTypeAllowedInCurrentSelection(markType, state) {
|
|
20
|
-
if (!isMarkTypeAllowedInNode(markType, state)) {
|
|
21
|
-
return false;
|
|
22
|
-
}
|
|
23
|
-
const {
|
|
24
|
-
empty,
|
|
25
|
-
$cursor,
|
|
26
|
-
ranges
|
|
27
|
-
} = state.selection;
|
|
28
|
-
if (empty && !$cursor) {
|
|
29
|
-
return false;
|
|
30
|
-
}
|
|
31
|
-
let isCompatibleMarkType = mark => isMarkTypeCompatibleWithMark(markType, mark);
|
|
32
|
-
|
|
33
|
-
// Handle any new marks in the current transaction
|
|
34
|
-
if (state.tr.storedMarks && !state.tr.storedMarks.every(isCompatibleMarkType)) {
|
|
35
|
-
return false;
|
|
36
|
-
}
|
|
37
|
-
if ($cursor) {
|
|
38
|
-
return $cursor.marks().every(isCompatibleMarkType);
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
// Check every node in a selection - ensuring that it is compatible with the current mark type
|
|
42
|
-
return ranges.every(({
|
|
43
|
-
$from,
|
|
44
|
-
$to
|
|
45
|
-
}) => {
|
|
46
|
-
let allowedInActiveMarks = $from.depth === 0 ? state.doc.marks.every(isCompatibleMarkType) : true;
|
|
47
|
-
state.doc.nodesBetween($from.pos, $to.pos, node => {
|
|
48
|
-
allowedInActiveMarks = allowedInActiveMarks && node.marks.every(isCompatibleMarkType);
|
|
49
|
-
});
|
|
50
|
-
return allowedInActiveMarks;
|
|
51
|
-
});
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
/**
|
|
55
|
-
* Repeating string for multiple times
|
|
56
|
-
*/
|
|
57
|
-
export function stringRepeat(text, length) {
|
|
58
|
-
let result = '';
|
|
59
|
-
for (let x = 0; x < length; x++) {
|
|
60
|
-
result += text;
|
|
61
|
-
}
|
|
62
|
-
return result;
|
|
63
|
-
}
|
|
64
3
|
|
|
65
4
|
/*
|
|
66
5
|
* From Modernizr
|
|
@@ -84,15 +23,4 @@ export function whichTransitionEvent() {
|
|
|
84
23
|
}
|
|
85
24
|
}
|
|
86
25
|
return;
|
|
87
|
-
}
|
|
88
|
-
export const isTemporary = id => {
|
|
89
|
-
return id.indexOf('temporary:') === 0;
|
|
90
|
-
};
|
|
91
|
-
export const hasOpenEnd = slice => {
|
|
92
|
-
return slice.openStart > 0 || slice.openEnd > 0;
|
|
93
|
-
};
|
|
94
|
-
export { isTextSelection, isElementInTableCell, isLastItemMediaGroup, nonNullable } from '@atlaskit/editor-common/utils';
|
|
95
|
-
export function sum(arr, f) {
|
|
96
|
-
return arr.reduce((val, x) => val + f(x), 0);
|
|
97
|
-
}
|
|
98
|
-
export { SetAttrsStep } from '@atlaskit/adf-schema/steps';
|
|
26
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export const name = "@atlaskit/editor-core";
|
|
2
|
-
export const version = "193.30.
|
|
2
|
+
export const version = "193.30.4";
|