@atlaskit/editor-common 74.29.0 → 74.29.2
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 +12 -0
- package/dist/cjs/card/MediaAndEmbedsToolbar/index.js +8 -8
- package/dist/cjs/core-utils/inside.js +2 -2
- package/dist/cjs/guideline/defaultGuideline.js +57 -0
- package/dist/cjs/guideline/dynamicGuideline.js +4 -4
- package/dist/cjs/guideline/index.js +13 -0
- package/dist/cjs/guideline/utils.js +12 -2
- package/dist/cjs/insert/index.js +30 -30
- package/dist/cjs/monitoring/error.js +1 -1
- package/dist/cjs/node-width/index.js +3 -3
- package/dist/cjs/safe-plugin/index.js +2 -2
- package/dist/cjs/selection/gap-cursor/selection.js +7 -7
- package/dist/cjs/transforms/expand.js +5 -5
- package/dist/cjs/transforms/extension.js +2 -2
- package/dist/cjs/transforms/layout.js +5 -5
- package/dist/cjs/ui/DropList/index.js +1 -1
- package/dist/cjs/ui/UnsupportedInline/index.js +1 -1
- package/dist/cjs/utils/document.js +3 -3
- package/dist/cjs/utils/editor-core-utils.js +8 -8
- package/dist/cjs/utils/is-text-input.js +2 -2
- package/dist/cjs/utils/nodes.js +2 -2
- package/dist/cjs/utils/rich-media-utils.js +2 -2
- package/dist/cjs/utils/slice.js +6 -6
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/card/MediaAndEmbedsToolbar/index.js +2 -2
- package/dist/es2019/card/utils.js +0 -1
- package/dist/es2019/core-utils/inside.js +1 -1
- package/dist/es2019/guideline/defaultGuideline.js +45 -0
- package/dist/es2019/guideline/dynamicGuideline.js +2 -2
- package/dist/es2019/guideline/index.js +2 -1
- package/dist/es2019/guideline/utils.js +8 -1
- package/dist/es2019/insert/index.js +4 -4
- package/dist/es2019/monitoring/error.js +1 -1
- package/dist/es2019/node-width/index.js +1 -1
- package/dist/es2019/safe-plugin/index.js +1 -1
- package/dist/es2019/selection/gap-cursor/selection.js +2 -2
- package/dist/es2019/transforms/expand.js +2 -2
- package/dist/es2019/transforms/extension.js +1 -1
- package/dist/es2019/transforms/layout.js +1 -1
- package/dist/es2019/ui/DropList/index.js +1 -1
- package/dist/es2019/ui/UnsupportedInline/index.js +1 -1
- package/dist/es2019/utils/document.js +1 -1
- package/dist/es2019/utils/editor-core-utils.js +3 -3
- package/dist/es2019/utils/is-text-input.js +1 -1
- package/dist/es2019/utils/nodes.js +1 -1
- package/dist/es2019/utils/rich-media-utils.js +1 -1
- package/dist/es2019/utils/slice.js +1 -1
- package/dist/es2019/version.json +1 -1
- package/dist/esm/card/MediaAndEmbedsToolbar/index.js +2 -2
- package/dist/esm/card/utils.js +0 -1
- package/dist/esm/core-utils/inside.js +1 -1
- package/dist/esm/guideline/defaultGuideline.js +49 -0
- package/dist/esm/guideline/dynamicGuideline.js +2 -2
- package/dist/esm/guideline/index.js +2 -1
- package/dist/esm/guideline/utils.js +9 -0
- package/dist/esm/insert/index.js +4 -4
- package/dist/esm/monitoring/error.js +1 -1
- package/dist/esm/node-width/index.js +1 -1
- package/dist/esm/safe-plugin/index.js +1 -1
- package/dist/esm/selection/gap-cursor/selection.js +2 -2
- package/dist/esm/transforms/expand.js +2 -2
- package/dist/esm/transforms/extension.js +1 -1
- package/dist/esm/transforms/layout.js +1 -1
- package/dist/esm/ui/DropList/index.js +1 -1
- package/dist/esm/ui/UnsupportedInline/index.js +1 -1
- package/dist/esm/utils/document.js +1 -1
- package/dist/esm/utils/editor-core-utils.js +3 -3
- package/dist/esm/utils/is-text-input.js +1 -1
- package/dist/esm/utils/nodes.js +1 -1
- package/dist/esm/utils/rich-media-utils.js +1 -1
- package/dist/esm/utils/slice.js +1 -1
- package/dist/esm/version.json +1 -1
- package/dist/types/analytics/api.d.ts +1 -1
- package/dist/types/analytics/types/events.d.ts +1 -1
- package/dist/types/analytics/utils.d.ts +1 -1
- package/dist/types/card/MediaAndEmbedsToolbar/index.d.ts +2 -2
- package/dist/types/card/types.d.ts +2 -2
- package/dist/types/card/utils.d.ts +2 -2
- package/dist/types/collab/index.d.ts +2 -2
- package/dist/types/core-utils/inside.d.ts +1 -1
- package/dist/types/editor-analytics/withAnalytics.d.ts +1 -1
- package/dist/types/event-dispatcher/index.d.ts +1 -1
- package/dist/types/guideline/defaultGuideline.d.ts +2 -0
- package/dist/types/guideline/dynamicGuideline.d.ts +1 -1
- package/dist/types/guideline/index.d.ts +2 -1
- package/dist/types/guideline/types.d.ts +1 -1
- package/dist/types/guideline/utils.d.ts +5 -0
- package/dist/types/insert/index.d.ts +2 -2
- package/dist/types/link/LinkPicker/EditorLinkPicker/index.d.ts +1 -1
- package/dist/types/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.d.ts +1 -1
- package/dist/types/link/LinkPicker/HyperlinkAddToolbar/index.d.ts +1 -1
- package/dist/types/link/types.d.ts +1 -1
- package/dist/types/node-width/index.d.ts +2 -2
- package/dist/types/preset/plugin-injection-api.d.ts +1 -1
- package/dist/types/provider-factory/macro-provider.d.ts +1 -1
- package/dist/types/provider-factory/quick-insert-provider.d.ts +2 -2
- package/dist/types/react-node-view/getInlineNodeViewProducer.d.ts +2 -2
- package/dist/types/react-node-view/index.d.ts +2 -2
- package/dist/types/react-node-view/types.d.ts +1 -1
- package/dist/types/safe-plugin/index.d.ts +1 -1
- package/dist/types/selection/gap-cursor/selection.d.ts +3 -3
- package/dist/types/selection/gap-cursor/utils/is-ignored.d.ts +1 -1
- package/dist/types/selection/gap-cursor/utils/is-valid-target-node.d.ts +1 -1
- package/dist/types/selection/types.d.ts +2 -2
- package/dist/types/selection/utils.d.ts +2 -2
- package/dist/types/selection-based-node-view/SelectionBasedNodeView.d.ts +2 -2
- package/dist/types/transforms/expand.d.ts +2 -2
- package/dist/types/transforms/extension.d.ts +1 -1
- package/dist/types/transforms/layout.d.ts +1 -1
- package/dist/types/types/annotation/index.d.ts +1 -1
- package/dist/types/types/command.d.ts +2 -2
- package/dist/types/types/context-panel.d.ts +1 -1
- package/dist/types/types/copy-button.d.ts +2 -2
- package/dist/types/types/editor-actions.d.ts +2 -2
- package/dist/types/types/editor-plugin.d.ts +1 -1
- package/dist/types/types/floating-toolbar.d.ts +3 -3
- package/dist/types/types/index.d.ts +1 -1
- package/dist/types/types/next-editor-plugin.d.ts +1 -1
- package/dist/types/types/plugin-factory.d.ts +1 -1
- package/dist/types/types/prosemirror-config.d.ts +2 -2
- package/dist/types/types/resizable-media-single.d.ts +1 -1
- package/dist/types/types/type-ahead.d.ts +2 -2
- package/dist/types/types/ui-components.d.ts +1 -1
- package/dist/types/ufo/experience-store.d.ts +1 -1
- package/dist/types/ui/MediaSingle/grid.d.ts +1 -1
- package/dist/types/ui/ResizerLegacy/types.d.ts +1 -1
- package/dist/types/ui/UnsupportedBlock/index.d.ts +1 -1
- package/dist/types/ui/UnsupportedInline/index.d.ts +1 -1
- package/dist/types/ui/unsupported-content-helper.d.ts +1 -1
- package/dist/types/ui-react/ReactEditorViewContext.d.ts +1 -1
- package/dist/types/utils/annotation/index.d.ts +1 -1
- package/dist/types/utils/compareNodes.d.ts +1 -1
- package/dist/types/utils/document.d.ts +2 -2
- package/dist/types/utils/editor-core-utils.d.ts +4 -4
- package/dist/types/utils/get-performance-options.d.ts +1 -1
- package/dist/types/utils/hyperlink.d.ts +2 -2
- package/dist/types/utils/is-text-input.d.ts +1 -1
- package/dist/types/utils/list.d.ts +1 -1
- package/dist/types/utils/macro.d.ts +1 -1
- package/dist/types/utils/nodes.d.ts +2 -2
- package/dist/types/utils/plugin-state-factory.d.ts +1 -1
- package/dist/types/utils/referentiality.d.ts +2 -2
- package/dist/types/utils/rich-media-utils.d.ts +1 -1
- package/dist/types/utils/slice.d.ts +1 -1
- package/dist/types/utils/table.d.ts +1 -1
- package/dist/types/utils/track-unsupported-content.d.ts +1 -1
- package/dist/types/utils/validate-using-spec.d.ts +1 -1
- package/dist/types/utils/validator.d.ts +1 -1
- package/dist/types/with-plugin-state/index.d.ts +2 -2
- package/dist/types/with-plugin-state/types.d.ts +1 -1
- package/dist/types-ts4.5/analytics/api.d.ts +1 -1
- package/dist/types-ts4.5/analytics/types/events.d.ts +1 -1
- package/dist/types-ts4.5/analytics/utils.d.ts +1 -1
- package/dist/types-ts4.5/card/MediaAndEmbedsToolbar/index.d.ts +2 -2
- package/dist/types-ts4.5/card/types.d.ts +2 -2
- package/dist/types-ts4.5/card/utils.d.ts +2 -2
- package/dist/types-ts4.5/collab/index.d.ts +2 -2
- package/dist/types-ts4.5/core-utils/inside.d.ts +1 -1
- package/dist/types-ts4.5/editor-analytics/withAnalytics.d.ts +1 -1
- package/dist/types-ts4.5/event-dispatcher/index.d.ts +1 -1
- package/dist/types-ts4.5/guideline/defaultGuideline.d.ts +2 -0
- package/dist/types-ts4.5/guideline/dynamicGuideline.d.ts +1 -1
- package/dist/types-ts4.5/guideline/index.d.ts +2 -1
- package/dist/types-ts4.5/guideline/types.d.ts +1 -1
- package/dist/types-ts4.5/guideline/utils.d.ts +5 -0
- package/dist/types-ts4.5/insert/index.d.ts +2 -2
- package/dist/types-ts4.5/link/LinkPicker/EditorLinkPicker/index.d.ts +1 -1
- package/dist/types-ts4.5/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.d.ts +1 -1
- package/dist/types-ts4.5/link/LinkPicker/HyperlinkAddToolbar/index.d.ts +1 -1
- package/dist/types-ts4.5/link/types.d.ts +1 -1
- package/dist/types-ts4.5/node-width/index.d.ts +2 -2
- package/dist/types-ts4.5/preset/plugin-injection-api.d.ts +1 -1
- package/dist/types-ts4.5/provider-factory/macro-provider.d.ts +1 -1
- package/dist/types-ts4.5/provider-factory/quick-insert-provider.d.ts +2 -2
- package/dist/types-ts4.5/react-node-view/getInlineNodeViewProducer.d.ts +2 -2
- package/dist/types-ts4.5/react-node-view/index.d.ts +2 -2
- package/dist/types-ts4.5/react-node-view/types.d.ts +1 -1
- package/dist/types-ts4.5/safe-plugin/index.d.ts +1 -1
- package/dist/types-ts4.5/selection/gap-cursor/selection.d.ts +3 -3
- package/dist/types-ts4.5/selection/gap-cursor/utils/is-ignored.d.ts +1 -1
- package/dist/types-ts4.5/selection/gap-cursor/utils/is-valid-target-node.d.ts +1 -1
- package/dist/types-ts4.5/selection/types.d.ts +2 -2
- package/dist/types-ts4.5/selection/utils.d.ts +2 -2
- package/dist/types-ts4.5/selection-based-node-view/SelectionBasedNodeView.d.ts +2 -2
- package/dist/types-ts4.5/transforms/expand.d.ts +2 -2
- package/dist/types-ts4.5/transforms/extension.d.ts +1 -1
- package/dist/types-ts4.5/transforms/layout.d.ts +1 -1
- package/dist/types-ts4.5/types/annotation/index.d.ts +1 -1
- package/dist/types-ts4.5/types/command.d.ts +2 -2
- package/dist/types-ts4.5/types/context-panel.d.ts +1 -1
- package/dist/types-ts4.5/types/copy-button.d.ts +2 -2
- package/dist/types-ts4.5/types/editor-actions.d.ts +2 -2
- package/dist/types-ts4.5/types/editor-plugin.d.ts +1 -1
- package/dist/types-ts4.5/types/floating-toolbar.d.ts +3 -3
- package/dist/types-ts4.5/types/index.d.ts +1 -1
- package/dist/types-ts4.5/types/next-editor-plugin.d.ts +1 -1
- package/dist/types-ts4.5/types/plugin-factory.d.ts +1 -1
- package/dist/types-ts4.5/types/prosemirror-config.d.ts +2 -2
- package/dist/types-ts4.5/types/resizable-media-single.d.ts +1 -1
- package/dist/types-ts4.5/types/type-ahead.d.ts +2 -2
- package/dist/types-ts4.5/types/ui-components.d.ts +1 -1
- package/dist/types-ts4.5/ufo/experience-store.d.ts +1 -1
- package/dist/types-ts4.5/ui/MediaSingle/grid.d.ts +1 -1
- package/dist/types-ts4.5/ui/ResizerLegacy/types.d.ts +1 -1
- package/dist/types-ts4.5/ui/UnsupportedBlock/index.d.ts +1 -1
- package/dist/types-ts4.5/ui/UnsupportedInline/index.d.ts +1 -1
- package/dist/types-ts4.5/ui/unsupported-content-helper.d.ts +1 -1
- package/dist/types-ts4.5/ui-react/ReactEditorViewContext.d.ts +1 -1
- package/dist/types-ts4.5/utils/annotation/index.d.ts +1 -1
- package/dist/types-ts4.5/utils/compareNodes.d.ts +1 -1
- package/dist/types-ts4.5/utils/document.d.ts +2 -2
- package/dist/types-ts4.5/utils/editor-core-utils.d.ts +4 -4
- package/dist/types-ts4.5/utils/get-performance-options.d.ts +1 -1
- package/dist/types-ts4.5/utils/hyperlink.d.ts +2 -2
- package/dist/types-ts4.5/utils/is-text-input.d.ts +1 -1
- package/dist/types-ts4.5/utils/list.d.ts +1 -1
- package/dist/types-ts4.5/utils/macro.d.ts +1 -1
- package/dist/types-ts4.5/utils/nodes.d.ts +2 -2
- package/dist/types-ts4.5/utils/plugin-state-factory.d.ts +1 -1
- package/dist/types-ts4.5/utils/referentiality.d.ts +2 -2
- package/dist/types-ts4.5/utils/rich-media-utils.d.ts +1 -1
- package/dist/types-ts4.5/utils/slice.d.ts +1 -1
- package/dist/types-ts4.5/utils/table.d.ts +1 -1
- package/dist/types-ts4.5/utils/track-unsupported-content.d.ts +1 -1
- package/dist/types-ts4.5/utils/validate-using-spec.d.ts +1 -1
- package/dist/types-ts4.5/utils/validator.d.ts +1 -1
- package/dist/types-ts4.5/with-plugin-state/index.d.ts +2 -2
- package/dist/types-ts4.5/with-plugin-state/types.d.ts +1 -1
- package/package.json +4 -8
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { findParentNodeOfTypeClosestToPos } from 'prosemirror
|
|
1
|
+
import { findParentNodeOfTypeClosestToPos } from '@atlaskit/editor-prosemirror/utils';
|
|
2
2
|
import { akEditorDefaultLayoutWidth, akEditorFullWidthLayoutWidth, akEditorWideLayoutWidth, akLayoutGutterOffset, gridMediumMaxWidth } from '@atlaskit/editor-shared-styles';
|
|
3
3
|
// eslint-disable-next-line @atlaskit/design-system/no-deprecated-imports
|
|
4
4
|
import { gridSize } from '@atlaskit/theme/constants';
|
|
@@ -5,7 +5,7 @@ import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstruct
|
|
|
5
5
|
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
6
6
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
7
7
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
8
|
-
import { Plugin } from 'prosemirror
|
|
8
|
+
import { Plugin } from '@atlaskit/editor-prosemirror/state';
|
|
9
9
|
export var SafePlugin = /*#__PURE__*/function (_Plugin) {
|
|
10
10
|
_inherits(SafePlugin, _Plugin);
|
|
11
11
|
var _super = _createSuper(SafePlugin);
|
|
@@ -7,8 +7,8 @@ import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
|
7
7
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
8
8
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
9
9
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
10
|
-
import { Slice } from 'prosemirror
|
|
11
|
-
import { Selection } from 'prosemirror
|
|
10
|
+
import { Slice } from '@atlaskit/editor-prosemirror/model';
|
|
11
|
+
import { Selection } from '@atlaskit/editor-prosemirror/state';
|
|
12
12
|
import { isValidTargetNode } from './utils/is-valid-target-node';
|
|
13
13
|
export var Side = /*#__PURE__*/function (Side) {
|
|
14
14
|
Side["LEFT"] = "left";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Fragment, Slice } from 'prosemirror
|
|
2
|
-
import { findParentNodeOfType, findSelectedNodeOfType } from 'prosemirror
|
|
1
|
+
import { Fragment, Slice } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
import { findParentNodeOfType, findSelectedNodeOfType } from '@atlaskit/editor-prosemirror/utils';
|
|
3
3
|
import { mapChildren } from '../utils/slice';
|
|
4
4
|
export var findExpand = function findExpand(state, selection) {
|
|
5
5
|
var _state$schema$nodes = state.schema.nodes,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Fragment, Slice } from 'prosemirror
|
|
1
|
+
import { Fragment, Slice } from '@atlaskit/editor-prosemirror/model';
|
|
2
2
|
import { flatmap, mapFragment } from '../utils/slice';
|
|
3
3
|
var isLayoutNode = function isLayoutNode(node) {
|
|
4
4
|
return node.type === node.type.schema.nodes.layoutSection || node.type === node.type.schema.nodes.layoutColumn;
|
|
@@ -18,7 +18,7 @@ import { themed } from '@atlaskit/theme/components';
|
|
|
18
18
|
import { borderRadius } from '@atlaskit/theme/constants';
|
|
19
19
|
import Layer from '../Layer';
|
|
20
20
|
var packageName = "@atlaskit/editor-common";
|
|
21
|
-
var packageVersion = "74.29.
|
|
21
|
+
var packageVersion = "74.29.2";
|
|
22
22
|
var halfFocusRing = 1;
|
|
23
23
|
var dropOffset = '0, 8';
|
|
24
24
|
var DropList = /*#__PURE__*/function (_Component) {
|
|
@@ -13,7 +13,7 @@ import { ACTION_SUBJECT_ID } from '../../analytics';
|
|
|
13
13
|
import { unsupportedContentMessages } from '../../messages/unsupportedContent';
|
|
14
14
|
import { trackUnsupportedContentTooltipDisplayedFor } from '../../utils/track-unsupported-content';
|
|
15
15
|
import { getUnsupportedContent } from '../unsupported-content-helper';
|
|
16
|
-
var inlineNodeStyle = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n align-items: center;\n background: ", ";\n border: 1px dashed ", ";\n border-radius: ", "px;\n box-sizing: border-box;\n cursor: default;\n display: inline-flex;\n font-size: ", ";\n margin: 0
|
|
16
|
+
var inlineNodeStyle = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n align-items: center;\n background: ", ";\n border: 1px dashed ", ";\n border-radius: ", "px;\n box-sizing: border-box;\n cursor: default;\n display: inline-flex;\n font-size: ", ";\n margin: 0 ", ";\n min-height: 24px;\n padding: 0 10px;\n vertical-align: middle;\n white-space: nowrap;\n"])), "var(--ds-background-disabled, ".concat(N30, ")"), "var(--ds-border-disabled, ".concat(N50, ")"), borderRadius(), relativeFontSizeToBase16(fontSize()), "var(--ds-space-025, 2px)");
|
|
17
17
|
var UnsupportedInlineNode = function UnsupportedInlineNode(_ref) {
|
|
18
18
|
var node = _ref.node,
|
|
19
19
|
intl = _ref.intl,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Node } from 'prosemirror-model';
|
|
2
1
|
import { transformDedupeMarks, transformIndentationMarks, transformInvalidMediaContent, transformMediaLinkMarks, transformNodesMissingContent, transformTextLinkCodeMarks } from '@atlaskit/adf-utils/transforms';
|
|
2
|
+
import { Node } from '@atlaskit/editor-prosemirror/model';
|
|
3
3
|
import { ACTION, ACTION_SUBJECT, EVENT_TYPE } from '../analytics';
|
|
4
4
|
import { isEmptyParagraph } from './editor-core-utils';
|
|
5
5
|
import { sanitizeNodeForPrivacy } from './filter/privacy-filter';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { NodeSelection, TextSelection } from 'prosemirror
|
|
2
|
-
import { ReplaceAroundStep, ReplaceStep } from 'prosemirror
|
|
3
|
-
import { hasParentNodeOfType } from 'prosemirror
|
|
1
|
+
import { NodeSelection, TextSelection } from '@atlaskit/editor-prosemirror/state';
|
|
2
|
+
import { ReplaceAroundStep, ReplaceStep } from '@atlaskit/editor-prosemirror/transform';
|
|
3
|
+
import { hasParentNodeOfType } from '@atlaskit/editor-prosemirror/utils';
|
|
4
4
|
import { closest } from './dom';
|
|
5
5
|
|
|
6
6
|
/**
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
2
2
|
// TODO: remove from editor-core utils, re-export from editor-common
|
|
3
3
|
|
|
4
|
-
import { ReplaceStep } from 'prosemirror
|
|
4
|
+
import { ReplaceStep } from '@atlaskit/editor-prosemirror/transform';
|
|
5
5
|
export var isTextInput = function isTextInput(tr) {
|
|
6
6
|
var _tr$steps = _slicedToArray(tr.steps, 1),
|
|
7
7
|
step = _tr$steps[0];
|
package/dist/esm/utils/nodes.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { findParentNodeOfType } from 'prosemirror
|
|
1
|
+
import { findParentNodeOfType } from '@atlaskit/editor-prosemirror/utils';
|
|
2
2
|
/**
|
|
3
3
|
* Finds all top level nodes affected by the transaction
|
|
4
4
|
* Uses from/to positions in transaction's steps to work out which nodes will
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
2
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
3
3
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
4
|
-
import { findParentNodeOfTypeClosestToPos } from 'prosemirror
|
|
4
|
+
import { findParentNodeOfTypeClosestToPos } from '@atlaskit/editor-prosemirror/utils';
|
|
5
5
|
import { akEditorBreakoutPadding } from '@atlaskit/editor-shared-styles';
|
|
6
6
|
import { shouldAddDefaultWrappedWidth } from '../ui/MediaSingle';
|
|
7
7
|
import { calcPxFromColumns, wrappedLayouts } from '../ui/MediaSingle/grid';
|
package/dist/esm/utils/slice.js
CHANGED
package/dist/esm/version.json
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Transaction } from 'prosemirror
|
|
1
|
+
import type { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
2
2
|
import type { AnalyticsEventPayload } from './types';
|
|
3
3
|
export type EditorAnalyticsAPI = {
|
|
4
4
|
attachAnalyticsEvent: (payload: AnalyticsEventPayload, channel?: string) => (tr: Transaction) => boolean;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import type { EditorState, PluginKey } from 'prosemirror-state';
|
|
3
2
|
import { CreateUIAnalyticsEvent } from '@atlaskit/analytics-next';
|
|
3
|
+
import type { EditorState, PluginKey } from '@atlaskit/editor-prosemirror/state';
|
|
4
4
|
import type { NewCollabSyncUpErrorAttributes } from '../../collab';
|
|
5
5
|
import type { UnsupportedContentPayload, UnsupportedContentTooltipPayload, UserBrowserExtensionResults } from '../../utils';
|
|
6
6
|
import type { AvatarEventPayload } from './avatar';
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { ReadonlyTransaction, Transaction } from 'prosemirror
|
|
1
|
+
import type { ReadonlyTransaction, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
2
2
|
import type { AnalyticsEventPayloadWithChannel } from './types';
|
|
3
3
|
export declare function getAnalyticsEventsFromTransaction(tr: Transaction | ReadonlyTransaction): AnalyticsEventPayloadWithChannel[];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { NodeType } from 'prosemirror-model';
|
|
2
|
-
import { EditorState } from 'prosemirror-state';
|
|
3
1
|
import { IntlShape } from 'react-intl-next';
|
|
2
|
+
import { NodeType } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import { EditorState } from '@atlaskit/editor-prosemirror/state';
|
|
4
4
|
import { EditorAnalyticsAPI } from '../../analytics';
|
|
5
5
|
import type { Command, EditorContainerWidth, FloatingToolbarItem, NextEditorPlugin, PluginDependenciesAPI } from '../../types';
|
|
6
6
|
type WidthPluginType = NextEditorPlugin<'width', {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { Node } from 'prosemirror-model';
|
|
2
|
-
import type { EditorState, Transaction } from 'prosemirror-state';
|
|
3
1
|
import { UIAnalyticsEvent } from '@atlaskit/analytics-next';
|
|
2
|
+
import type { Node } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import type { EditorState, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
4
4
|
import { ACTION, EditorAnalyticsAPI, INPUT_METHOD } from '../analytics';
|
|
5
5
|
import type { CardAppearance } from '../provider-factory';
|
|
6
6
|
import type { Command } from '../types';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { EditorState, ReadonlyTransaction, Selection, Transaction } from 'prosemirror-state';
|
|
2
|
-
import type { EditorView } from 'prosemirror-view';
|
|
3
1
|
import { LinkStepMetadata } from '@atlaskit/adf-schema/steps';
|
|
2
|
+
import type { EditorState, ReadonlyTransaction, Selection, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
3
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
4
4
|
/**
|
|
5
5
|
* Records metadata about the user action and input method relating to a transaction
|
|
6
6
|
* as a custom LinkStepMetadata prosemirror step so that it is preserved in
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { EditorState, Transaction } from 'prosemirror-state';
|
|
2
|
-
import type { Step } from 'prosemirror-transform';
|
|
3
1
|
import type { JSONDocNode } from '@atlaskit/editor-json-transformer';
|
|
2
|
+
import type { EditorState, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
3
|
+
import type { Step } from '@atlaskit/editor-prosemirror/transform';
|
|
4
4
|
export type NewCollabSyncUpErrorAttributes = {
|
|
5
5
|
lengthOfUnconfirmedSteps?: number;
|
|
6
6
|
tries: number;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { EditorState } from 'prosemirror
|
|
1
|
+
import type { EditorState } from '@atlaskit/editor-prosemirror/state';
|
|
2
2
|
export declare const insideTable: (state: EditorState) => Boolean;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export { generateDynamicGuidelines } from './dynamicGuideline';
|
|
2
2
|
export { createFixedGuidelinesFromLengths, createGuidesFromLengths, } from './fixedGuideline';
|
|
3
|
+
export { generateDefaultGuidelines } from './defaultGuideline';
|
|
3
4
|
export { getGuidelinesWithHighlights } from './updateGuideline';
|
|
4
5
|
export { MEDIA_DYNAMIC_GUIDELINE_PREFIX } from './constants';
|
|
5
6
|
export type { WidthTypes, Position, GuidelineConfig, GuidelinePluginState, GuidelinePluginOptions, DisplayGuideline, DisplayGrid, VerticalPosition, HorizontalPosition, } from './types';
|
|
6
|
-
export { isVerticalPosition } from './utils';
|
|
7
|
+
export { isVerticalPosition, getContainerWidthOrFullEditorWidth, } from './utils';
|
|
@@ -1,3 +1,8 @@
|
|
|
1
1
|
import { Position, VerticalPosition } from './types';
|
|
2
2
|
export declare const isNumber: (x: unknown) => x is number;
|
|
3
3
|
export declare const isVerticalPosition: (pos: Position) => pos is VerticalPosition;
|
|
4
|
+
/**
|
|
5
|
+
* Calculates container or full editor width taking in account editor full width layout
|
|
6
|
+
* width and editor gutter padding.
|
|
7
|
+
*/
|
|
8
|
+
export declare const getContainerWidthOrFullEditorWidth: (containerWidth: number) => number;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Fragment, Node, NodeType } from 'prosemirror
|
|
2
|
-
import { EditorState, Transaction } from 'prosemirror
|
|
1
|
+
import { Fragment, Node, NodeType } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
import { EditorState, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
3
3
|
export type InsertableContent = Node | Fragment;
|
|
4
4
|
export declare enum LookDirection {
|
|
5
5
|
Before = "before",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { EditorView } from 'prosemirror
|
|
2
|
+
import { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
3
3
|
import { LinkPickerProps } from '@atlaskit/link-picker';
|
|
4
4
|
import type { Command, EditorAppearance } from '../../../types';
|
|
5
5
|
/**
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
2
|
import React, { PureComponent } from 'react';
|
|
3
3
|
import { jsx } from '@emotion/react';
|
|
4
|
-
import { EditorView } from 'prosemirror-view';
|
|
5
4
|
import { WrappedComponentProps } from 'react-intl-next';
|
|
6
5
|
import { ActivityProvider } from '@atlaskit/activity-provider';
|
|
7
6
|
import { WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
|
|
7
|
+
import { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
8
8
|
import type { HyperlinkState } from '../../../link';
|
|
9
9
|
import type { SearchProvider } from '../../../provider-factory';
|
|
10
10
|
import type { Command, LinkInputType } from '../../../types';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { EditorView } from 'prosemirror-view';
|
|
3
2
|
import { UIAnalyticsEvent } from '@atlaskit/analytics-next';
|
|
3
|
+
import { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
4
4
|
import type { HyperlinkState } from '../../../link';
|
|
5
5
|
import { ProviderFactory } from '../../../provider-factory';
|
|
6
6
|
import type { Command, FeatureFlags, LinkInputType, LinkPickerOptions } from '../../../types';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Node as PMNode } from 'prosemirror
|
|
2
|
-
import { EditorState } from 'prosemirror
|
|
1
|
+
import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
import { EditorState } from '@atlaskit/editor-prosemirror/state';
|
|
3
3
|
import type { EditorContainerWidth } from '../types/editor-container-width';
|
|
4
4
|
export declare const layoutToWidth: {
|
|
5
5
|
default: number;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { EditorState } from 'prosemirror
|
|
1
|
+
import type { EditorState } from '@atlaskit/editor-prosemirror/state';
|
|
2
2
|
import type { DefaultEditorPlugin, NextEditorPlugin, PluginDependenciesAPI, PluginInjectionAPI } from '../types/next-editor-plugin';
|
|
3
3
|
type NextEditorPluginInitializedType = ReturnType<NextEditorPlugin<any>>;
|
|
4
4
|
type SharedStateAPIProps = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Node as PmNode } from 'prosemirror-model';
|
|
2
1
|
import { ExtensionLayout } from '@atlaskit/adf-schema';
|
|
2
|
+
import { Node as PmNode } from '@atlaskit/editor-prosemirror/model';
|
|
3
3
|
export type ExtensionType = 'extension' | 'bodiedExtension' | 'inlineExtension';
|
|
4
4
|
export interface MacroAttributes {
|
|
5
5
|
type: ExtensionType;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { Node } from 'prosemirror
|
|
2
|
-
import type { EditorState, Transaction } from 'prosemirror
|
|
1
|
+
import type { Node } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
import type { EditorState, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
3
3
|
import type { TypeAheadItem } from '../types/type-ahead';
|
|
4
4
|
export type QuickInsertActionInsert = (node?: Node | Record<string, any> | string, opts?: {
|
|
5
5
|
selectInlineNode?: boolean;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { Node as PMNode } from 'prosemirror
|
|
4
|
-
import { Decoration, EditorView, NodeView } from 'prosemirror
|
|
3
|
+
import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
4
|
+
import { Decoration, EditorView, NodeView } from '@atlaskit/editor-prosemirror/view';
|
|
5
5
|
import type { PMPluginFactoryParams } from '../types';
|
|
6
6
|
export type InlineNodeViewComponentProps = {
|
|
7
7
|
view: EditorView;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { Node as PMNode } from 'prosemirror
|
|
3
|
-
import { Decoration, DecorationSource, EditorView, NodeView } from 'prosemirror
|
|
2
|
+
import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import { Decoration, DecorationSource, EditorView, NodeView } from '@atlaskit/editor-prosemirror/view';
|
|
4
4
|
import { EventDispatcher } from '../event-dispatcher';
|
|
5
5
|
import type { PortalProviderAPI } from '../ui/PortalProvider';
|
|
6
6
|
import { ForwardRef, getPosHandler, ReactComponentProps, shouldUpdate } from './types';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Node as PMNode, ResolvedPos, Slice } from 'prosemirror
|
|
2
|
-
import { Selection } from 'prosemirror
|
|
3
|
-
import { Mapping } from 'prosemirror
|
|
1
|
+
import { Node as PMNode, ResolvedPos, Slice } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
import { Selection } from '@atlaskit/editor-prosemirror/state';
|
|
3
|
+
import { Mapping } from '@atlaskit/editor-prosemirror/transform';
|
|
4
4
|
export declare enum Side {
|
|
5
5
|
LEFT = "left",
|
|
6
6
|
RIGHT = "right"
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Node as PMNode } from 'prosemirror
|
|
1
|
+
import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
2
2
|
export declare const isIgnored: (node?: PMNode | null) => boolean;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Node as PMNode } from 'prosemirror
|
|
1
|
+
import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
2
2
|
export declare const isValidTargetNode: (node?: PMNode | null) => boolean;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { EditorState, Selection, Transaction } from 'prosemirror
|
|
2
|
-
import type { DecorationSet } from 'prosemirror
|
|
1
|
+
import type { EditorState, Selection, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
2
|
+
import type { DecorationSet } from '@atlaskit/editor-prosemirror/view';
|
|
3
3
|
export declare enum RelativeSelectionPos {
|
|
4
4
|
Before = "Before",
|
|
5
5
|
Start = "Start",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ResolvedPos } from 'prosemirror
|
|
2
|
-
import { ContentNodeWithPos } from 'prosemirror
|
|
1
|
+
import { ResolvedPos } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
import { ContentNodeWithPos } from '@atlaskit/editor-prosemirror/utils';
|
|
3
3
|
export declare const isSelectionAtStartOfNode: ($pos: ResolvedPos, parentNode?: ContentNodeWithPos) => boolean;
|
|
4
4
|
export declare const isSelectionAtEndOfNode: ($pos: ResolvedPos, parentNode?: ContentNodeWithPos) => boolean;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { Node as PMNode } from 'prosemirror
|
|
3
|
-
import { EditorView } from 'prosemirror
|
|
2
|
+
import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
4
4
|
import { EventDispatcher } from '../event-dispatcher';
|
|
5
5
|
import ReactNodeView, { getPosHandler, ReactComponentProps, shouldUpdate } from '../react-node-view';
|
|
6
6
|
import { PortalProviderAPI } from '../ui/PortalProvider';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Schema, Slice } from 'prosemirror
|
|
2
|
-
import type { EditorState, Selection } from 'prosemirror
|
|
1
|
+
import { Schema, Slice } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
import type { EditorState, Selection } from '@atlaskit/editor-prosemirror/state';
|
|
3
3
|
export declare const findExpand: (state: EditorState, selection?: Selection | null) => import("prosemirror-utils").ContentNodeWithPos | undefined;
|
|
4
4
|
export declare const transformSliceToRemoveOpenExpand: (slice: Slice, schema: Schema) => Slice;
|
|
5
5
|
export declare const transformSliceNestedExpandToExpand: (slice: Slice, schema: Schema) => Slice;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Schema, Slice } from 'prosemirror
|
|
1
|
+
import { Schema, Slice } from '@atlaskit/editor-prosemirror/model';
|
|
2
2
|
/**
|
|
3
3
|
* Lift content out of "open" top-level bodiedExtensions.
|
|
4
4
|
* Will not work if bodiedExtensions are nested, or when bodiedExtensions are not in the top level
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Fragment, Node, Schema, Slice } from 'prosemirror
|
|
1
|
+
import { Fragment, Node, Schema, Slice } from '@atlaskit/editor-prosemirror/model';
|
|
2
2
|
export declare function unwrapContentFromLayout(maybeLayoutSection: Node): Node | Node[];
|
|
3
3
|
export declare function removeLayoutFromFirstChild(node: Node, i: number): Node | Node[];
|
|
4
4
|
export declare function removeLayoutFromLastChild(node: Node, i: number, fragment: Fragment): Node | Node[];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import type { Step } from 'prosemirror-transform';
|
|
3
2
|
import { AnnotationId, AnnotationTypes } from '@atlaskit/adf-schema';
|
|
4
3
|
import type { JSONDocNode } from '@atlaskit/editor-json-transformer';
|
|
4
|
+
import type { Step } from '@atlaskit/editor-prosemirror/transform';
|
|
5
5
|
import { AnnotationState, AnnotationUpdateEmitter, AnnotationUpdateEvent, AnnotationUpdateEventPayloads, OnAnnotationClickPayload } from './emitter';
|
|
6
6
|
export type { AnnotationState };
|
|
7
7
|
export type AnnotationByMatches = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { EditorState, Transaction } from 'prosemirror
|
|
2
|
-
import type { EditorView } from 'prosemirror
|
|
1
|
+
import type { EditorState, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
2
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
3
3
|
export type CommandDispatch = (tr: Transaction) => void;
|
|
4
4
|
export type Command = (state: EditorState, dispatch?: CommandDispatch, view?: EditorView) => boolean;
|
|
5
5
|
export type HigherOrderCommand = (command: Command) => Command;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { MarkType, NodeType } from 'prosemirror-model';
|
|
2
|
-
import type { EditorState } from 'prosemirror-state';
|
|
3
1
|
import type { IntlShape } from 'react-intl-next';
|
|
2
|
+
import type { MarkType, NodeType } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import type { EditorState } from '@atlaskit/editor-prosemirror/state';
|
|
4
4
|
import { Command } from './command';
|
|
5
5
|
export type MarkOptions = {
|
|
6
6
|
state: EditorState;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { Node } from 'prosemirror-model';
|
|
2
|
-
import type { EditorView } from 'prosemirror-view';
|
|
3
1
|
import type { JSONDocNode } from '@atlaskit/editor-json-transformer';
|
|
2
|
+
import type { Node } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
4
4
|
import type { ResolvedEditorState } from '../collab';
|
|
5
5
|
import type { EventDispatcher } from '../event-dispatcher';
|
|
6
6
|
export type ContextUpdateHandler = (editorView: EditorView, eventDispatcher: EventDispatcher) => void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { EditorState, Transaction } from 'prosemirror
|
|
1
|
+
import type { EditorState, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
2
2
|
import type { ContextPanelHandler } from './context-panel';
|
|
3
3
|
import type { FloatingToolbarHandler } from './floating-toolbar';
|
|
4
4
|
import type { PMPlugin } from './plugin-factory';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import type React from 'react';
|
|
2
|
-
import { Node, NodeType } from 'prosemirror-model';
|
|
3
|
-
import type { EditorState } from 'prosemirror-state';
|
|
4
|
-
import { EditorView } from 'prosemirror-view';
|
|
5
2
|
import { IntlShape } from 'react-intl-next';
|
|
3
|
+
import { Node, NodeType } from '@atlaskit/editor-prosemirror/model';
|
|
4
|
+
import type { EditorState } from '@atlaskit/editor-prosemirror/state';
|
|
5
|
+
import { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
6
6
|
import type { EmojiId } from '@atlaskit/emoji/types';
|
|
7
7
|
import type { DispatchAnalyticsEvent } from '../analytics/types/dispatch-analytics-event';
|
|
8
8
|
import type { ProviderFactory } from '../provider-factory';
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* `Presets` - if the generics get too unwieldy, we may redesign how presets
|
|
5
5
|
* are put together - but for now `Builder` & `Preset` aim to beinterchangeable.
|
|
6
6
|
*/
|
|
7
|
-
import type { EditorState } from 'prosemirror
|
|
7
|
+
import type { EditorState } from '@atlaskit/editor-prosemirror/state';
|
|
8
8
|
import type { EditorPlugin } from './editor-plugin';
|
|
9
9
|
type IsAny<T> = 0 extends 1 & T ? true : false;
|
|
10
10
|
type PickSharedStatePropertyName<Metadata extends NextEditorPluginMetadata> = IsAny<Metadata> extends true ? never : ExtractSharedStateFromMetadata<Metadata> extends never ? never : 'getSharedState';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { Schema } from 'prosemirror-model';
|
|
2
1
|
import type { IntlShape } from 'react-intl-next';
|
|
2
|
+
import type { Schema } from '@atlaskit/editor-prosemirror/model';
|
|
3
3
|
import type { DispatchAnalyticsEvent } from '../analytics/types/dispatch-analytics-event';
|
|
4
4
|
import type { Dispatch, EventDispatcher } from '../event-dispatcher';
|
|
5
5
|
import type { ProviderFactory } from '../provider-factory';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { MarkSpec, NodeSpec } from 'prosemirror
|
|
2
|
-
import type { NodeView } from 'prosemirror
|
|
1
|
+
import type { MarkSpec, NodeSpec } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
import type { NodeView } from '@atlaskit/editor-prosemirror/view';
|
|
3
3
|
export interface NodeConfig {
|
|
4
4
|
name: string;
|
|
5
5
|
node: NodeSpec;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ReactElement } from 'react';
|
|
2
|
-
import { Fragment, Node as PMNode } from 'prosemirror
|
|
3
|
-
import type { EditorState, Transaction } from 'prosemirror
|
|
2
|
+
import { Fragment, Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import type { EditorState, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
4
4
|
import type { TypeAheadPayload } from '../analytics/types/type-ahead';
|
|
5
5
|
import type { SelectItemMode, TypeAheadAvailableNodes } from '../type-ahead';
|
|
6
6
|
type TypeAheadForceSelectProps = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type React from 'react';
|
|
2
|
-
import type { EditorView } from 'prosemirror
|
|
2
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
3
3
|
import type { DispatchAnalyticsEvent } from '../analytics/types/dispatch-analytics-event';
|
|
4
4
|
import type { EventDispatcher } from '../event-dispatcher';
|
|
5
5
|
import type { ProviderFactory } from '../provider-factory';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EditorView } from 'prosemirror
|
|
1
|
+
import { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
2
2
|
import { UFOExperience } from '@atlaskit/ufo';
|
|
3
3
|
import type { CustomData, ExperienceConfig } from '@atlaskit/ufo/types';
|
|
4
4
|
export declare const experienceConfig: ExperienceConfig;
|