@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.
Files changed (229) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/cjs/card/MediaAndEmbedsToolbar/index.js +8 -8
  3. package/dist/cjs/core-utils/inside.js +2 -2
  4. package/dist/cjs/guideline/defaultGuideline.js +57 -0
  5. package/dist/cjs/guideline/dynamicGuideline.js +4 -4
  6. package/dist/cjs/guideline/index.js +13 -0
  7. package/dist/cjs/guideline/utils.js +12 -2
  8. package/dist/cjs/insert/index.js +30 -30
  9. package/dist/cjs/monitoring/error.js +1 -1
  10. package/dist/cjs/node-width/index.js +3 -3
  11. package/dist/cjs/safe-plugin/index.js +2 -2
  12. package/dist/cjs/selection/gap-cursor/selection.js +7 -7
  13. package/dist/cjs/transforms/expand.js +5 -5
  14. package/dist/cjs/transforms/extension.js +2 -2
  15. package/dist/cjs/transforms/layout.js +5 -5
  16. package/dist/cjs/ui/DropList/index.js +1 -1
  17. package/dist/cjs/ui/UnsupportedInline/index.js +1 -1
  18. package/dist/cjs/utils/document.js +3 -3
  19. package/dist/cjs/utils/editor-core-utils.js +8 -8
  20. package/dist/cjs/utils/is-text-input.js +2 -2
  21. package/dist/cjs/utils/nodes.js +2 -2
  22. package/dist/cjs/utils/rich-media-utils.js +2 -2
  23. package/dist/cjs/utils/slice.js +6 -6
  24. package/dist/cjs/version.json +1 -1
  25. package/dist/es2019/card/MediaAndEmbedsToolbar/index.js +2 -2
  26. package/dist/es2019/card/utils.js +0 -1
  27. package/dist/es2019/core-utils/inside.js +1 -1
  28. package/dist/es2019/guideline/defaultGuideline.js +45 -0
  29. package/dist/es2019/guideline/dynamicGuideline.js +2 -2
  30. package/dist/es2019/guideline/index.js +2 -1
  31. package/dist/es2019/guideline/utils.js +8 -1
  32. package/dist/es2019/insert/index.js +4 -4
  33. package/dist/es2019/monitoring/error.js +1 -1
  34. package/dist/es2019/node-width/index.js +1 -1
  35. package/dist/es2019/safe-plugin/index.js +1 -1
  36. package/dist/es2019/selection/gap-cursor/selection.js +2 -2
  37. package/dist/es2019/transforms/expand.js +2 -2
  38. package/dist/es2019/transforms/extension.js +1 -1
  39. package/dist/es2019/transforms/layout.js +1 -1
  40. package/dist/es2019/ui/DropList/index.js +1 -1
  41. package/dist/es2019/ui/UnsupportedInline/index.js +1 -1
  42. package/dist/es2019/utils/document.js +1 -1
  43. package/dist/es2019/utils/editor-core-utils.js +3 -3
  44. package/dist/es2019/utils/is-text-input.js +1 -1
  45. package/dist/es2019/utils/nodes.js +1 -1
  46. package/dist/es2019/utils/rich-media-utils.js +1 -1
  47. package/dist/es2019/utils/slice.js +1 -1
  48. package/dist/es2019/version.json +1 -1
  49. package/dist/esm/card/MediaAndEmbedsToolbar/index.js +2 -2
  50. package/dist/esm/card/utils.js +0 -1
  51. package/dist/esm/core-utils/inside.js +1 -1
  52. package/dist/esm/guideline/defaultGuideline.js +49 -0
  53. package/dist/esm/guideline/dynamicGuideline.js +2 -2
  54. package/dist/esm/guideline/index.js +2 -1
  55. package/dist/esm/guideline/utils.js +9 -0
  56. package/dist/esm/insert/index.js +4 -4
  57. package/dist/esm/monitoring/error.js +1 -1
  58. package/dist/esm/node-width/index.js +1 -1
  59. package/dist/esm/safe-plugin/index.js +1 -1
  60. package/dist/esm/selection/gap-cursor/selection.js +2 -2
  61. package/dist/esm/transforms/expand.js +2 -2
  62. package/dist/esm/transforms/extension.js +1 -1
  63. package/dist/esm/transforms/layout.js +1 -1
  64. package/dist/esm/ui/DropList/index.js +1 -1
  65. package/dist/esm/ui/UnsupportedInline/index.js +1 -1
  66. package/dist/esm/utils/document.js +1 -1
  67. package/dist/esm/utils/editor-core-utils.js +3 -3
  68. package/dist/esm/utils/is-text-input.js +1 -1
  69. package/dist/esm/utils/nodes.js +1 -1
  70. package/dist/esm/utils/rich-media-utils.js +1 -1
  71. package/dist/esm/utils/slice.js +1 -1
  72. package/dist/esm/version.json +1 -1
  73. package/dist/types/analytics/api.d.ts +1 -1
  74. package/dist/types/analytics/types/events.d.ts +1 -1
  75. package/dist/types/analytics/utils.d.ts +1 -1
  76. package/dist/types/card/MediaAndEmbedsToolbar/index.d.ts +2 -2
  77. package/dist/types/card/types.d.ts +2 -2
  78. package/dist/types/card/utils.d.ts +2 -2
  79. package/dist/types/collab/index.d.ts +2 -2
  80. package/dist/types/core-utils/inside.d.ts +1 -1
  81. package/dist/types/editor-analytics/withAnalytics.d.ts +1 -1
  82. package/dist/types/event-dispatcher/index.d.ts +1 -1
  83. package/dist/types/guideline/defaultGuideline.d.ts +2 -0
  84. package/dist/types/guideline/dynamicGuideline.d.ts +1 -1
  85. package/dist/types/guideline/index.d.ts +2 -1
  86. package/dist/types/guideline/types.d.ts +1 -1
  87. package/dist/types/guideline/utils.d.ts +5 -0
  88. package/dist/types/insert/index.d.ts +2 -2
  89. package/dist/types/link/LinkPicker/EditorLinkPicker/index.d.ts +1 -1
  90. package/dist/types/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.d.ts +1 -1
  91. package/dist/types/link/LinkPicker/HyperlinkAddToolbar/index.d.ts +1 -1
  92. package/dist/types/link/types.d.ts +1 -1
  93. package/dist/types/node-width/index.d.ts +2 -2
  94. package/dist/types/preset/plugin-injection-api.d.ts +1 -1
  95. package/dist/types/provider-factory/macro-provider.d.ts +1 -1
  96. package/dist/types/provider-factory/quick-insert-provider.d.ts +2 -2
  97. package/dist/types/react-node-view/getInlineNodeViewProducer.d.ts +2 -2
  98. package/dist/types/react-node-view/index.d.ts +2 -2
  99. package/dist/types/react-node-view/types.d.ts +1 -1
  100. package/dist/types/safe-plugin/index.d.ts +1 -1
  101. package/dist/types/selection/gap-cursor/selection.d.ts +3 -3
  102. package/dist/types/selection/gap-cursor/utils/is-ignored.d.ts +1 -1
  103. package/dist/types/selection/gap-cursor/utils/is-valid-target-node.d.ts +1 -1
  104. package/dist/types/selection/types.d.ts +2 -2
  105. package/dist/types/selection/utils.d.ts +2 -2
  106. package/dist/types/selection-based-node-view/SelectionBasedNodeView.d.ts +2 -2
  107. package/dist/types/transforms/expand.d.ts +2 -2
  108. package/dist/types/transforms/extension.d.ts +1 -1
  109. package/dist/types/transforms/layout.d.ts +1 -1
  110. package/dist/types/types/annotation/index.d.ts +1 -1
  111. package/dist/types/types/command.d.ts +2 -2
  112. package/dist/types/types/context-panel.d.ts +1 -1
  113. package/dist/types/types/copy-button.d.ts +2 -2
  114. package/dist/types/types/editor-actions.d.ts +2 -2
  115. package/dist/types/types/editor-plugin.d.ts +1 -1
  116. package/dist/types/types/floating-toolbar.d.ts +3 -3
  117. package/dist/types/types/index.d.ts +1 -1
  118. package/dist/types/types/next-editor-plugin.d.ts +1 -1
  119. package/dist/types/types/plugin-factory.d.ts +1 -1
  120. package/dist/types/types/prosemirror-config.d.ts +2 -2
  121. package/dist/types/types/resizable-media-single.d.ts +1 -1
  122. package/dist/types/types/type-ahead.d.ts +2 -2
  123. package/dist/types/types/ui-components.d.ts +1 -1
  124. package/dist/types/ufo/experience-store.d.ts +1 -1
  125. package/dist/types/ui/MediaSingle/grid.d.ts +1 -1
  126. package/dist/types/ui/ResizerLegacy/types.d.ts +1 -1
  127. package/dist/types/ui/UnsupportedBlock/index.d.ts +1 -1
  128. package/dist/types/ui/UnsupportedInline/index.d.ts +1 -1
  129. package/dist/types/ui/unsupported-content-helper.d.ts +1 -1
  130. package/dist/types/ui-react/ReactEditorViewContext.d.ts +1 -1
  131. package/dist/types/utils/annotation/index.d.ts +1 -1
  132. package/dist/types/utils/compareNodes.d.ts +1 -1
  133. package/dist/types/utils/document.d.ts +2 -2
  134. package/dist/types/utils/editor-core-utils.d.ts +4 -4
  135. package/dist/types/utils/get-performance-options.d.ts +1 -1
  136. package/dist/types/utils/hyperlink.d.ts +2 -2
  137. package/dist/types/utils/is-text-input.d.ts +1 -1
  138. package/dist/types/utils/list.d.ts +1 -1
  139. package/dist/types/utils/macro.d.ts +1 -1
  140. package/dist/types/utils/nodes.d.ts +2 -2
  141. package/dist/types/utils/plugin-state-factory.d.ts +1 -1
  142. package/dist/types/utils/referentiality.d.ts +2 -2
  143. package/dist/types/utils/rich-media-utils.d.ts +1 -1
  144. package/dist/types/utils/slice.d.ts +1 -1
  145. package/dist/types/utils/table.d.ts +1 -1
  146. package/dist/types/utils/track-unsupported-content.d.ts +1 -1
  147. package/dist/types/utils/validate-using-spec.d.ts +1 -1
  148. package/dist/types/utils/validator.d.ts +1 -1
  149. package/dist/types/with-plugin-state/index.d.ts +2 -2
  150. package/dist/types/with-plugin-state/types.d.ts +1 -1
  151. package/dist/types-ts4.5/analytics/api.d.ts +1 -1
  152. package/dist/types-ts4.5/analytics/types/events.d.ts +1 -1
  153. package/dist/types-ts4.5/analytics/utils.d.ts +1 -1
  154. package/dist/types-ts4.5/card/MediaAndEmbedsToolbar/index.d.ts +2 -2
  155. package/dist/types-ts4.5/card/types.d.ts +2 -2
  156. package/dist/types-ts4.5/card/utils.d.ts +2 -2
  157. package/dist/types-ts4.5/collab/index.d.ts +2 -2
  158. package/dist/types-ts4.5/core-utils/inside.d.ts +1 -1
  159. package/dist/types-ts4.5/editor-analytics/withAnalytics.d.ts +1 -1
  160. package/dist/types-ts4.5/event-dispatcher/index.d.ts +1 -1
  161. package/dist/types-ts4.5/guideline/defaultGuideline.d.ts +2 -0
  162. package/dist/types-ts4.5/guideline/dynamicGuideline.d.ts +1 -1
  163. package/dist/types-ts4.5/guideline/index.d.ts +2 -1
  164. package/dist/types-ts4.5/guideline/types.d.ts +1 -1
  165. package/dist/types-ts4.5/guideline/utils.d.ts +5 -0
  166. package/dist/types-ts4.5/insert/index.d.ts +2 -2
  167. package/dist/types-ts4.5/link/LinkPicker/EditorLinkPicker/index.d.ts +1 -1
  168. package/dist/types-ts4.5/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.d.ts +1 -1
  169. package/dist/types-ts4.5/link/LinkPicker/HyperlinkAddToolbar/index.d.ts +1 -1
  170. package/dist/types-ts4.5/link/types.d.ts +1 -1
  171. package/dist/types-ts4.5/node-width/index.d.ts +2 -2
  172. package/dist/types-ts4.5/preset/plugin-injection-api.d.ts +1 -1
  173. package/dist/types-ts4.5/provider-factory/macro-provider.d.ts +1 -1
  174. package/dist/types-ts4.5/provider-factory/quick-insert-provider.d.ts +2 -2
  175. package/dist/types-ts4.5/react-node-view/getInlineNodeViewProducer.d.ts +2 -2
  176. package/dist/types-ts4.5/react-node-view/index.d.ts +2 -2
  177. package/dist/types-ts4.5/react-node-view/types.d.ts +1 -1
  178. package/dist/types-ts4.5/safe-plugin/index.d.ts +1 -1
  179. package/dist/types-ts4.5/selection/gap-cursor/selection.d.ts +3 -3
  180. package/dist/types-ts4.5/selection/gap-cursor/utils/is-ignored.d.ts +1 -1
  181. package/dist/types-ts4.5/selection/gap-cursor/utils/is-valid-target-node.d.ts +1 -1
  182. package/dist/types-ts4.5/selection/types.d.ts +2 -2
  183. package/dist/types-ts4.5/selection/utils.d.ts +2 -2
  184. package/dist/types-ts4.5/selection-based-node-view/SelectionBasedNodeView.d.ts +2 -2
  185. package/dist/types-ts4.5/transforms/expand.d.ts +2 -2
  186. package/dist/types-ts4.5/transforms/extension.d.ts +1 -1
  187. package/dist/types-ts4.5/transforms/layout.d.ts +1 -1
  188. package/dist/types-ts4.5/types/annotation/index.d.ts +1 -1
  189. package/dist/types-ts4.5/types/command.d.ts +2 -2
  190. package/dist/types-ts4.5/types/context-panel.d.ts +1 -1
  191. package/dist/types-ts4.5/types/copy-button.d.ts +2 -2
  192. package/dist/types-ts4.5/types/editor-actions.d.ts +2 -2
  193. package/dist/types-ts4.5/types/editor-plugin.d.ts +1 -1
  194. package/dist/types-ts4.5/types/floating-toolbar.d.ts +3 -3
  195. package/dist/types-ts4.5/types/index.d.ts +1 -1
  196. package/dist/types-ts4.5/types/next-editor-plugin.d.ts +1 -1
  197. package/dist/types-ts4.5/types/plugin-factory.d.ts +1 -1
  198. package/dist/types-ts4.5/types/prosemirror-config.d.ts +2 -2
  199. package/dist/types-ts4.5/types/resizable-media-single.d.ts +1 -1
  200. package/dist/types-ts4.5/types/type-ahead.d.ts +2 -2
  201. package/dist/types-ts4.5/types/ui-components.d.ts +1 -1
  202. package/dist/types-ts4.5/ufo/experience-store.d.ts +1 -1
  203. package/dist/types-ts4.5/ui/MediaSingle/grid.d.ts +1 -1
  204. package/dist/types-ts4.5/ui/ResizerLegacy/types.d.ts +1 -1
  205. package/dist/types-ts4.5/ui/UnsupportedBlock/index.d.ts +1 -1
  206. package/dist/types-ts4.5/ui/UnsupportedInline/index.d.ts +1 -1
  207. package/dist/types-ts4.5/ui/unsupported-content-helper.d.ts +1 -1
  208. package/dist/types-ts4.5/ui-react/ReactEditorViewContext.d.ts +1 -1
  209. package/dist/types-ts4.5/utils/annotation/index.d.ts +1 -1
  210. package/dist/types-ts4.5/utils/compareNodes.d.ts +1 -1
  211. package/dist/types-ts4.5/utils/document.d.ts +2 -2
  212. package/dist/types-ts4.5/utils/editor-core-utils.d.ts +4 -4
  213. package/dist/types-ts4.5/utils/get-performance-options.d.ts +1 -1
  214. package/dist/types-ts4.5/utils/hyperlink.d.ts +2 -2
  215. package/dist/types-ts4.5/utils/is-text-input.d.ts +1 -1
  216. package/dist/types-ts4.5/utils/list.d.ts +1 -1
  217. package/dist/types-ts4.5/utils/macro.d.ts +1 -1
  218. package/dist/types-ts4.5/utils/nodes.d.ts +2 -2
  219. package/dist/types-ts4.5/utils/plugin-state-factory.d.ts +1 -1
  220. package/dist/types-ts4.5/utils/referentiality.d.ts +2 -2
  221. package/dist/types-ts4.5/utils/rich-media-utils.d.ts +1 -1
  222. package/dist/types-ts4.5/utils/slice.d.ts +1 -1
  223. package/dist/types-ts4.5/utils/table.d.ts +1 -1
  224. package/dist/types-ts4.5/utils/track-unsupported-content.d.ts +1 -1
  225. package/dist/types-ts4.5/utils/validate-using-spec.d.ts +1 -1
  226. package/dist/types-ts4.5/utils/validator.d.ts +1 -1
  227. package/dist/types-ts4.5/with-plugin-state/index.d.ts +2 -2
  228. package/dist/types-ts4.5/with-plugin-state/types.d.ts +1 -1
  229. package/package.json +4 -8
@@ -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';
@@ -1,4 +1,4 @@
1
- import { Node } from 'prosemirror-model';
1
+ import { Node } from '@atlaskit/editor-prosemirror/model';
2
2
  export interface Transformer<T> {
3
3
  encode(node: Node): T;
4
4
  parse(content: T): Node;
@@ -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-state';
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-model';
2
- import type { NodeView } from 'prosemirror-view';
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,4 +1,4 @@
1
- import { ResolvedPos } from 'prosemirror-model';
1
+ import { ResolvedPos } from '@atlaskit/editor-prosemirror/model';
2
2
  export interface SnapPointsProps {
3
3
  $pos?: ResolvedPos | null;
4
4
  akEditorWideLayoutWidth: number;
@@ -1,6 +1,6 @@
1
1
  import type { ReactElement } from 'react';
2
- import { Fragment, Node as PMNode } from 'prosemirror-model';
3
- import type { EditorState, Transaction } from 'prosemirror-state';
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-view';
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-view';
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;
@@ -1,5 +1,5 @@
1
- import type { EditorState } from 'prosemirror-state';
2
1
  import { RichMediaLayout as MediaSingleLayout } from '@atlaskit/adf-schema';
2
+ import type { EditorState } from '@atlaskit/editor-prosemirror/state';
3
3
  import { EditorContainerWidth } from '../../types';
4
4
  export declare const layoutSupportsWidth: (layout: MediaSingleLayout) => boolean;
5
5
  export declare function calcPxFromColumns(columns: number, lineLength: number, gridSize: number): number;
@@ -1,5 +1,5 @@
1
- import { EditorView } from 'prosemirror-view';
2
1
  import { RichMediaLayout } from '@atlaskit/adf-schema';
2
+ import { EditorView } from '@atlaskit/editor-prosemirror/view';
3
3
  import { MediaClientConfig } from '@atlaskit/media-core';
4
4
  import type { DispatchAnalyticsEvent } from '../../analytics';
5
5
  import type { getPosHandler } from '../../react-node-view';
@@ -1,7 +1,7 @@
1
1
  /** @jsx jsx */
2
2
  import React from 'react';
3
- import { Node as PMNode } from 'prosemirror-model';
4
3
  import { WrappedComponentProps } from 'react-intl-next';
4
+ import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
5
5
  import { UnsupportedContentTooltipPayload } from '../../utils';
6
6
  export interface Props {
7
7
  node?: PMNode;
@@ -1,7 +1,7 @@
1
1
  /** @jsx jsx */
2
2
  import React from 'react';
3
- import { Node as PMNode } from 'prosemirror-model';
4
3
  import { WrappedComponentProps } from 'react-intl-next';
4
+ import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
5
5
  import { UnsupportedContentTooltipPayload } from '../../utils';
6
6
  export interface Props {
7
7
  node?: PMNode;
@@ -1,3 +1,3 @@
1
- import { Node as PMNode } from 'prosemirror-model';
2
1
  import { IntlShape } from 'react-intl-next';
2
+ import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
3
3
  export declare function getUnsupportedContent(message: any, prefix: string, node?: PMNode, intl?: IntlShape): any;
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { EditorView } from 'prosemirror-view';
2
+ import { EditorView } from '@atlaskit/editor-prosemirror/view';
3
3
  type ReactEditorViewContextProps = {
4
4
  editorView?: EditorView;
5
5
  editorRef?: React.RefObject<HTMLDivElement>;
@@ -1,4 +1,4 @@
1
- import { Node as PMNode, Schema } from 'prosemirror-model';
1
+ import { Node as PMNode, Schema } from '@atlaskit/editor-prosemirror/model';
2
2
  type Range = {
3
3
  from: number;
4
4
  to: number;
@@ -1,5 +1,5 @@
1
- import { Node as PMNode } from 'prosemirror-model';
2
1
  import { CardAttributes } from '@atlaskit/adf-schema';
2
+ import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
3
3
  import { SortOrder } from '../types';
4
4
  export declare enum ContentType {
5
5
  NUMBER = 0,
@@ -1,5 +1,5 @@
1
- import { Node, ResolvedPos, Schema } from 'prosemirror-model';
2
- import type { EditorState, ReadonlyTransaction, Transaction } from 'prosemirror-state';
1
+ import { Node, ResolvedPos, Schema } from '@atlaskit/editor-prosemirror/model';
2
+ import type { EditorState, ReadonlyTransaction, Transaction } from '@atlaskit/editor-prosemirror/state';
3
3
  import { DispatchAnalyticsEvent } from '../analytics';
4
4
  import type { ProviderFactory } from '../provider-factory';
5
5
  import type { ReplaceRawValue, Transformer } from '../types';
@@ -1,7 +1,7 @@
1
- import { Node, NodeType, Slice } from 'prosemirror-model';
2
- import { EditorState, Selection, TextSelection } from 'prosemirror-state';
3
- import { Step } from 'prosemirror-transform';
4
- import { EditorView } from 'prosemirror-view';
1
+ import { Node, NodeType, Slice } from '@atlaskit/editor-prosemirror/model';
2
+ import { EditorState, Selection, TextSelection } from '@atlaskit/editor-prosemirror/state';
3
+ import { Step } from '@atlaskit/editor-prosemirror/transform';
4
+ import { EditorView } from '@atlaskit/editor-prosemirror/view';
5
5
  /**
6
6
  * Checks if node is an empty paragraph.
7
7
  */
@@ -1,4 +1,4 @@
1
- import type { EditorView } from 'prosemirror-view';
1
+ import type { EditorView } from '@atlaskit/editor-prosemirror/view';
2
2
  import { AnalyticsEventPayload } from '../analytics';
3
3
  export declare function getPerformanceOptions(view: EditorView): {
4
4
  trackingEnabled: boolean;
@@ -1,5 +1,5 @@
1
- import { Schema, Slice } from 'prosemirror-model';
2
- import { EditorState } from 'prosemirror-state';
1
+ import { Schema, Slice } from '@atlaskit/editor-prosemirror/model';
2
+ import { EditorState } from '@atlaskit/editor-prosemirror/state';
3
3
  import { AnalyticsEventPayload, InputMethodInsertLink } from '../analytics/types';
4
4
  export declare const FILEPATH_REGEXP: RegExp;
5
5
  export declare const DONTLINKIFY_REGEXP: RegExp;
@@ -1,2 +1,2 @@
1
- import type { ReadonlyTransaction, Transaction } from 'prosemirror-state';
1
+ import type { ReadonlyTransaction, Transaction } from '@atlaskit/editor-prosemirror/state';
2
2
  export declare const isTextInput: (tr: Transaction | ReadonlyTransaction) => boolean;
@@ -1,4 +1,4 @@
1
- import { Node } from 'prosemirror-model';
1
+ import { Node } from '@atlaskit/editor-prosemirror/model';
2
2
  export declare const DEFAULT_ORDER = 1;
3
3
  export declare const resolveOrder: (order: number | undefined | string) => number | undefined;
4
4
  export declare const getOrderFromOrderedListNode: (orderedListNode: Node) => number;
@@ -1,4 +1,4 @@
1
- import { Node as PmNode } from 'prosemirror-model';
1
+ import { Node as PmNode } from '@atlaskit/editor-prosemirror/model';
2
2
  export interface Params {
3
3
  node: PmNode;
4
4
  type: 'image' | 'icon';
@@ -1,5 +1,5 @@
1
- import type { Fragment, MarkType, NodeType, Mark as PMMark, Node as PMNode, ResolvedPos, Schema } from 'prosemirror-model';
2
- import type { EditorState, Transaction } from 'prosemirror-state';
1
+ import type { Fragment, MarkType, NodeType, Mark as PMMark, Node as PMNode, ResolvedPos, Schema } from '@atlaskit/editor-prosemirror/model';
2
+ import type { EditorState, Transaction } from '@atlaskit/editor-prosemirror/state';
3
3
  import type { CardAppearance } from '@atlaskit/smart-card';
4
4
  /**
5
5
  * Finds all top level nodes affected by the transaction
@@ -1,4 +1,4 @@
1
- import type { EditorState, PluginKey, ReadonlyTransaction, SafeStateField, Transaction } from 'prosemirror-state';
1
+ import type { EditorState, PluginKey, ReadonlyTransaction, SafeStateField, Transaction } from '@atlaskit/editor-prosemirror/state';
2
2
  import { Dispatch } from '../event-dispatcher';
3
3
  import { Command } from '../types';
4
4
  export type Reducer<PluginState, Action> = (state: PluginState, action: Action) => PluginState;
@@ -1,8 +1,8 @@
1
1
  /// <reference path="../../../../../../typings/prosemirror.d.ts" />
2
2
  /// <reference path="../../../../../../typings/prosemirror-state.d.ts" />
3
- import { Node as PMNode } from 'prosemirror-model';
4
- import type { EditorState } from 'prosemirror-state';
5
3
  import type { FragmentAttributes } from '@atlaskit/adf-schema/schema';
4
+ import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
5
+ import type { EditorState } from '@atlaskit/editor-prosemirror/state';
6
6
  import { ConfirmDialogChildInfo } from '../types';
7
7
  type LocalId = FragmentAttributes['localId'];
8
8
  type NodeAndTargetLinkages = {
@@ -1,5 +1,5 @@
1
- import { EditorView } from 'prosemirror-view';
2
1
  import { RichMediaAttributes, RichMediaLayout } from '@atlaskit/adf-schema';
2
+ import { EditorView } from '@atlaskit/editor-prosemirror/view';
3
3
  import { SnapPointsProps } from '../types';
4
4
  export declare const nonWrappedLayouts: RichMediaLayout[];
5
5
  export declare const floatingLayouts: string[];
@@ -1,4 +1,4 @@
1
- import { Fragment, Node, Slice } from 'prosemirror-model';
1
+ import { Fragment, Node, Slice } from '@atlaskit/editor-prosemirror/model';
2
2
  /**
3
3
  * A helper to get the underlying array of a fragment.
4
4
  */
@@ -1,4 +1,4 @@
1
- import type { Node as PmNode } from 'prosemirror-model';
1
+ import type { Node as PmNode } from '@atlaskit/editor-prosemirror/model';
2
2
  export declare function calcTableColumnWidths(node: PmNode): number[];
3
3
  export declare function hasMergedCell(tableNode: PmNode): boolean;
4
4
  export declare function convertProsemirrorTableNodeToArrayOfRows(tableNode: PmNode): Array<Array<PmNode | null>>;
@@ -1,4 +1,4 @@
1
- import type { Node as PMNode, Schema } from 'prosemirror-model';
1
+ import type { Node as PMNode, Schema } from '@atlaskit/editor-prosemirror/model';
2
2
  import { ACTION_SUBJECT_ID } from '../analytics';
3
3
  import type { UnsupportedContentPayload, UnsupportedContentTooltipPayload } from './analytics';
4
4
  type DispatchAnalyticsEvent = (payload: UnsupportedContentPayload) => void;
@@ -1,6 +1,6 @@
1
- import type { Schema } from 'prosemirror-model';
2
1
  import type { ADFEntity } from '@atlaskit/adf-utils/types';
3
2
  import type { ErrorCallbackOptions, Validate, ValidationError } from '@atlaskit/adf-utils/validatorTypes';
3
+ import type { Schema } from '@atlaskit/editor-prosemirror/model';
4
4
  export declare const UNSUPPORTED_NODE_ATTRIBUTE = "unsupportedNodeAttribute";
5
5
  import type { UnsupportedContentPayload } from './analytics';
6
6
  export type DispatchAnalyticsEvent = (event: UnsupportedContentPayload) => void;
@@ -1,4 +1,4 @@
1
- import type { Mark as PMMark, Schema } from 'prosemirror-model';
1
+ import type { Mark as PMMark, Schema } from '@atlaskit/editor-prosemirror/model';
2
2
  export declare const ADFStages: {
3
3
  readonly FINAL: "final";
4
4
  readonly STAGE_0: "stage0";
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import PropTypes from 'prop-types';
3
- import type { PluginKey } from 'prosemirror-state';
4
- import { EditorView } from 'prosemirror-view';
3
+ import type { PluginKey } from '@atlaskit/editor-prosemirror/state';
4
+ import { EditorView } from '@atlaskit/editor-prosemirror/view';
5
5
  import { EventDispatcher } from '../event-dispatcher';
6
6
  import type { NamedPluginKeys, NamedPluginStates } from './types';
7
7
  export type PerformanceOptions = {
@@ -1,4 +1,4 @@
1
- import type { PluginKey } from 'prosemirror-state';
1
+ import type { PluginKey } from '@atlaskit/editor-prosemirror/state';
2
2
  export type NamedPluginKeys = Readonly<{
3
3
  [stateName: string]: PluginKey;
4
4
  }>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-common",
3
- "version": "74.29.0",
3
+ "version": "74.29.2",
4
4
  "description": "A package that contains common classes and components for editor and renderer",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -78,7 +78,7 @@
78
78
  },
79
79
  "dependencies": {
80
80
  "@atlaskit/activity-provider": "^2.4.0",
81
- "@atlaskit/adf-schema": "^26.3.0",
81
+ "@atlaskit/adf-schema": "^26.4.0",
82
82
  "@atlaskit/adf-utils": "^19.0.0",
83
83
  "@atlaskit/analytics-listeners": "^8.7.0",
84
84
  "@atlaskit/analytics-namespaced-context": "^6.7.0",
@@ -88,6 +88,7 @@
88
88
  "@atlaskit/code": "^14.6.0",
89
89
  "@atlaskit/codemod-utils": "^4.2.0",
90
90
  "@atlaskit/editor-palette": "1.5.1",
91
+ "@atlaskit/editor-prosemirror": "1.0.2",
91
92
  "@atlaskit/editor-shared-styles": "^2.5.0",
92
93
  "@atlaskit/emoji": "^67.4.0",
93
94
  "@atlaskit/icon": "^21.12.0",
@@ -124,11 +125,6 @@
124
125
  "memoize-one": "^6.0.0",
125
126
  "popper.js": "^1.14.1",
126
127
  "prop-types": "^15.5.10",
127
- "prosemirror-model": "1.16.0",
128
- "prosemirror-state": "1.3.4",
129
- "prosemirror-transform": "1.3.2",
130
- "prosemirror-utils": "^1.0.0-0",
131
- "prosemirror-view": "1.23.7",
132
128
  "raf-schd": "^4.0.3",
133
129
  "re-resizable": "6.0.0",
134
130
  "react-loadable": "^5.1.0",
@@ -145,7 +141,7 @@
145
141
  "@atlaskit/editor-test-helpers": "^18.10.0",
146
142
  "@atlaskit/media-core": "^34.1.0",
147
143
  "@atlaskit/media-test-helpers": "^33.0.0",
148
- "@atlaskit/smart-card": "^26.12.0",
144
+ "@atlaskit/smart-card": "^26.13.0",
149
145
  "@atlaskit/util-data-test": "^17.8.0",
150
146
  "@atlaskit/visual-regression": "*",
151
147
  "@atlassian/atlassian-frontend-prettier-config-1.0.1": "npm:@atlassian/atlassian-frontend-prettier-config@1.0.1",