@atlaskit/editor-plugin-table 3.0.0 → 3.0.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/package.json +2 -2
- package/src/__tests__/unit/analytics.ts +1 -1
- package/src/__tests__/unit/collab.ts +1 -1
- package/src/__tests__/unit/commands/go-to-next-cell.ts +1 -1
- package/src/__tests__/unit/commands/insert.ts +4 -2
- package/src/__tests__/unit/commands/misc.ts +1 -1
- package/src/__tests__/unit/commands.ts +1 -1
- package/src/__tests__/unit/copy-paste.ts +1 -1
- package/src/__tests__/unit/event-handlers/index.ts +1 -1
- package/src/__tests__/unit/event-handlers.ts +1 -1
- package/src/__tests__/unit/fix-tables.ts +1 -1
- package/src/__tests__/unit/get-toolbar-config.ts +1 -1
- package/src/__tests__/unit/handlers.ts +1 -1
- package/src/__tests__/unit/hover-selection.ts +1 -1
- package/src/__tests__/unit/index-with-fake-timers.ts +2 -2
- package/src/__tests__/unit/index.ts +4 -2
- package/src/__tests__/unit/layout.ts +1 -1
- package/src/__tests__/unit/nodeviews/TableComponent.tsx +1 -2
- package/src/__tests__/unit/nodeviews/TableContainer.tsx +70 -1
- package/src/__tests__/unit/nodeviews/cell.ts +1 -1
- package/src/__tests__/unit/nodeviews/table.ts +1 -1
- package/src/__tests__/unit/pm-plugins/decorations/column-resizing.ts +1 -1
- package/src/__tests__/unit/pm-plugins/decorations/plugin.ts +1 -1
- package/src/__tests__/unit/pm-plugins/main.ts +1 -1
- package/src/__tests__/unit/pm-plugins/safari-delete-composition-text-issue-workaround.ts +1 -1
- package/src/__tests__/unit/pm-plugins/sticky-headers/tableRow.tsx +1 -1
- package/src/__tests__/unit/pm-plugins/table-local-id.ts +5 -2
- package/src/__tests__/unit/pm-plugins/table-resizing/event-handlers.ts +1 -1
- package/src/__tests__/unit/pm-plugins/table-width.ts +1 -1
- package/src/__tests__/unit/sort-column.ts +1 -1
- package/src/__tests__/unit/transforms/delete-columns.ts +1 -1
- package/src/__tests__/unit/transforms/delete-rows.ts +1 -1
- package/src/__tests__/unit/transforms/merging.ts +1 -1
- package/src/__tests__/unit/ui/CornerControls.tsx +1 -1
- package/src/__tests__/unit/ui/FloatingContextualButton.tsx +1 -1
- package/src/__tests__/unit/ui/FloatingDeleteButton.tsx +1 -1
- package/src/__tests__/unit/ui/FloatingInsertButton.tsx +1 -1
- package/src/__tests__/unit/ui/RowControls.tsx +1 -1
- package/src/__tests__/unit/ui/TableFloatingControls.tsx +1 -1
- package/src/__tests__/unit/undo-redo.ts +1 -1
- package/src/__tests__/unit/utils/collapse.ts +1 -1
- package/src/__tests__/unit/utils/nodes.ts +1 -1
- package/src/__tests__/unit/utils/row-controls.ts +1 -1
- package/src/__tests__/unit/utils.ts +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-table
|
|
2
2
|
|
|
3
|
+
## 3.0.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`37c62369dae`](https://bitbucket.org/atlassian/atlassian-frontend/commits/37c62369dae) - NO-ISSUE Import doc builder types from editor-common
|
|
8
|
+
|
|
9
|
+
## 3.0.1
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- Updated dependencies
|
|
14
|
+
|
|
3
15
|
## 3.0.0
|
|
4
16
|
|
|
5
17
|
### Major Changes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-table",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.2",
|
|
4
4
|
"description": "Table plugin for the @atlaskit/editor",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
30
|
"@atlaskit/adf-schema": "^29.1.0",
|
|
31
|
-
"@atlaskit/editor-common": "^
|
|
31
|
+
"@atlaskit/editor-common": "^75.0.0",
|
|
32
32
|
"@atlaskit/editor-palette": "1.5.1",
|
|
33
33
|
"@atlaskit/editor-plugin-analytics": "^0.2.0",
|
|
34
34
|
"@atlaskit/editor-plugin-content-insertion": "^0.1.0",
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
2
2
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
3
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
3
4
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
4
5
|
import type { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
5
6
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -12,7 +13,6 @@ import {
|
|
|
12
13
|
createProsemirrorEditorFactory,
|
|
13
14
|
Preset,
|
|
14
15
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
15
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
16
16
|
import {
|
|
17
17
|
doc,
|
|
18
18
|
p,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -10,7 +11,6 @@ import {
|
|
|
10
11
|
createProsemirrorEditorFactory,
|
|
11
12
|
Preset,
|
|
12
13
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
13
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
14
14
|
import {
|
|
15
15
|
doc,
|
|
16
16
|
p,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
2
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
2
3
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
3
4
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
4
5
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -11,7 +12,6 @@ import {
|
|
|
11
12
|
createProsemirrorEditorFactory,
|
|
12
13
|
Preset,
|
|
13
14
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
14
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
15
15
|
import {
|
|
16
16
|
doc,
|
|
17
17
|
p,
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type {
|
|
2
|
+
DocBuilder,
|
|
3
|
+
GetEditorContainerWidth,
|
|
4
|
+
} from '@atlaskit/editor-common/types';
|
|
2
5
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
3
6
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
4
7
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -11,7 +14,6 @@ import {
|
|
|
11
14
|
createProsemirrorEditorFactory,
|
|
12
15
|
Preset,
|
|
13
16
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
14
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
15
17
|
import {
|
|
16
18
|
doc,
|
|
17
19
|
p,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -12,7 +13,6 @@ import {
|
|
|
12
13
|
createProsemirrorEditorFactory,
|
|
13
14
|
Preset,
|
|
14
15
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
15
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
16
16
|
import {
|
|
17
17
|
doc,
|
|
18
18
|
p,
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { uuid } from '@atlaskit/adf-schema';
|
|
2
2
|
import { defaultSchema } from '@atlaskit/adf-schema/schema-default';
|
|
3
3
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
4
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
4
5
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
5
6
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
6
7
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -20,7 +21,6 @@ import {
|
|
|
20
21
|
createProsemirrorEditorFactory,
|
|
21
22
|
Preset,
|
|
22
23
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
23
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
24
24
|
import {
|
|
25
25
|
doc,
|
|
26
26
|
p,
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { uuid } from '@atlaskit/adf-schema';
|
|
4
4
|
import { transformSliceToRemoveOpenExpand } from '@atlaskit/editor-common/transforms';
|
|
5
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
5
6
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
6
7
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
7
8
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -32,7 +33,6 @@ import {
|
|
|
32
33
|
Preset,
|
|
33
34
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
34
35
|
import dispatchPasteEvent from '@atlaskit/editor-test-helpers/dispatch-paste-event';
|
|
35
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
36
36
|
import {
|
|
37
37
|
br,
|
|
38
38
|
code_block,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -10,7 +11,6 @@ import {
|
|
|
10
11
|
createProsemirrorEditorFactory,
|
|
11
12
|
Preset,
|
|
12
13
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
13
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
14
14
|
import {
|
|
15
15
|
doc,
|
|
16
16
|
table,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -12,7 +13,6 @@ import {
|
|
|
12
13
|
createProsemirrorEditorFactory,
|
|
13
14
|
Preset,
|
|
14
15
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
15
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
16
16
|
import {
|
|
17
17
|
doc,
|
|
18
18
|
p,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -9,7 +10,6 @@ import {
|
|
|
9
10
|
createProsemirrorEditorFactory,
|
|
10
11
|
Preset,
|
|
11
12
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
12
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
13
13
|
import {
|
|
14
14
|
doc,
|
|
15
15
|
p,
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
2
2
|
import type {
|
|
3
|
+
DocBuilder,
|
|
3
4
|
FloatingToolbarButton,
|
|
4
5
|
FloatingToolbarItem,
|
|
5
6
|
GetEditorFeatureFlags,
|
|
@@ -17,7 +18,6 @@ import {
|
|
|
17
18
|
createProsemirrorEditorFactory,
|
|
18
19
|
Preset,
|
|
19
20
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
20
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
21
21
|
import {
|
|
22
22
|
doc,
|
|
23
23
|
p,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -11,7 +12,6 @@ import {
|
|
|
11
12
|
createProsemirrorEditorFactory,
|
|
12
13
|
Preset,
|
|
13
14
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
14
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
15
15
|
import {
|
|
16
16
|
doc,
|
|
17
17
|
table,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -16,7 +17,6 @@ import {
|
|
|
16
17
|
createProsemirrorEditorFactory,
|
|
17
18
|
Preset,
|
|
18
19
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
19
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
20
20
|
import {
|
|
21
21
|
doc,
|
|
22
22
|
p,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// TODO: ensure this works as I have removed sinon here
|
|
2
2
|
import { defaultSchema } from '@atlaskit/adf-schema/schema-default';
|
|
3
3
|
import type { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
|
|
4
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
4
5
|
import { createEditorFactory } from '@atlaskit/editor-test-helpers/create-editor';
|
|
5
6
|
import {
|
|
6
7
|
doc,
|
|
7
|
-
DocBuilder,
|
|
8
8
|
p,
|
|
9
9
|
table,
|
|
10
10
|
tdCursor,
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
|
|
15
15
|
import TableView from '../../plugins/table/nodeviews/table';
|
|
16
16
|
import { pluginKey } from '../../plugins/table/pm-plugins/plugin-key';
|
|
17
|
-
import { PluginConfig, TablePluginState } from '../../plugins/table/types';
|
|
17
|
+
import type { PluginConfig, TablePluginState } from '../../plugins/table/types';
|
|
18
18
|
|
|
19
19
|
// TODO: this doesn't work
|
|
20
20
|
describe.skip('TableView', () => {
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import { uuid } from '@atlaskit/adf-schema';
|
|
2
|
-
import type {
|
|
2
|
+
import type {
|
|
3
|
+
DocBuilder,
|
|
4
|
+
GetEditorContainerWidth,
|
|
5
|
+
} from '@atlaskit/editor-common/types';
|
|
3
6
|
import { setNodeSelection } from '@atlaskit/editor-common/utils';
|
|
4
7
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
5
8
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
@@ -22,7 +25,6 @@ import {
|
|
|
22
25
|
createProsemirrorEditorFactory,
|
|
23
26
|
Preset,
|
|
24
27
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
25
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
26
28
|
import {
|
|
27
29
|
doc,
|
|
28
30
|
media,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { TableLayout } from '@atlaskit/adf-schema';
|
|
2
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
2
3
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
3
4
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
4
5
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -13,7 +14,6 @@ import {
|
|
|
13
14
|
createProsemirrorEditorFactory,
|
|
14
15
|
Preset,
|
|
15
16
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
16
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
17
17
|
import {
|
|
18
18
|
doc,
|
|
19
19
|
table,
|
|
@@ -4,7 +4,7 @@ import { render } from '@testing-library/react';
|
|
|
4
4
|
import { replaceRaf } from 'raf-stub';
|
|
5
5
|
|
|
6
6
|
import type { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
|
|
7
|
-
import type { Command } from '@atlaskit/editor-common/types';
|
|
7
|
+
import type { Command, DocBuilder } from '@atlaskit/editor-common/types';
|
|
8
8
|
import { TextSelection } from '@atlaskit/editor-prosemirror/state';
|
|
9
9
|
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
10
10
|
import { selectTableClosestToPos } from '@atlaskit/editor-tables/src/utils/select-nodes';
|
|
@@ -14,7 +14,6 @@ import {
|
|
|
14
14
|
selectTable,
|
|
15
15
|
} from '@atlaskit/editor-tables/utils';
|
|
16
16
|
import { createEditorFactory } from '@atlaskit/editor-test-helpers/create-editor';
|
|
17
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
18
17
|
import {
|
|
19
18
|
doc,
|
|
20
19
|
p,
|
|
@@ -8,10 +8,10 @@ import {
|
|
|
8
8
|
EVENT_TYPE,
|
|
9
9
|
TABLE_ACTION,
|
|
10
10
|
} from '@atlaskit/editor-common/analytics';
|
|
11
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
11
12
|
import { akEditorWideLayoutWidth } from '@atlaskit/editor-shared-styles';
|
|
12
13
|
import { findTable } from '@atlaskit/editor-tables/utils';
|
|
13
14
|
import { createEditorFactory } from '@atlaskit/editor-test-helpers/create-editor';
|
|
14
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
15
15
|
import {
|
|
16
16
|
doc,
|
|
17
17
|
p,
|
|
@@ -338,4 +338,73 @@ describe('table -> nodeviews -> TableContainer.tsx', () => {
|
|
|
338
338
|
expect(selectionActionMock).toHaveBeenNthCalledWith(2, true);
|
|
339
339
|
});
|
|
340
340
|
});
|
|
341
|
+
|
|
342
|
+
describe('deletion', () => {
|
|
343
|
+
const selectionActionMock = jest.fn().mockReturnValue(() => {});
|
|
344
|
+
const actualGuidelineMock = jest.fn();
|
|
345
|
+
const guidelineActionMock = jest.fn().mockReturnValue(actualGuidelineMock);
|
|
346
|
+
const buildContainer = (attrs: TableAttributes) => {
|
|
347
|
+
const { table, editorView } = createNode(attrs);
|
|
348
|
+
|
|
349
|
+
const { container, unmount } = render(
|
|
350
|
+
<ResizableTableContainer
|
|
351
|
+
containerWidth={1800}
|
|
352
|
+
lineLength={720}
|
|
353
|
+
node={table}
|
|
354
|
+
className={''}
|
|
355
|
+
editorView={editorView}
|
|
356
|
+
getPos={() => 0}
|
|
357
|
+
tableRef={
|
|
358
|
+
{
|
|
359
|
+
querySelector: () => null,
|
|
360
|
+
insertBefore: () => {},
|
|
361
|
+
style: {},
|
|
362
|
+
} as any
|
|
363
|
+
}
|
|
364
|
+
pluginInjectionApi={
|
|
365
|
+
{
|
|
366
|
+
selection: {
|
|
367
|
+
commands: { displayGapCursor: selectionActionMock },
|
|
368
|
+
},
|
|
369
|
+
guideline: {
|
|
370
|
+
actions: { displayGuideline: guidelineActionMock },
|
|
371
|
+
},
|
|
372
|
+
// mock core so the selection command will execute
|
|
373
|
+
core: { actions: { execute: jest.fn() } },
|
|
374
|
+
} as any
|
|
375
|
+
}
|
|
376
|
+
/>,
|
|
377
|
+
);
|
|
378
|
+
|
|
379
|
+
return { container, unmount, selectionActionMock, actualGuidelineMock };
|
|
380
|
+
};
|
|
381
|
+
|
|
382
|
+
afterEach(() => {
|
|
383
|
+
selectionActionMock.mockClear();
|
|
384
|
+
actualGuidelineMock.mockClear();
|
|
385
|
+
guidelineActionMock.mockClear();
|
|
386
|
+
});
|
|
387
|
+
|
|
388
|
+
// this is testing logic inside TableResizer, targeting the clean up in the useEffect
|
|
389
|
+
it('should call selection plugin action to display gapcursor when removed', () => {
|
|
390
|
+
const { container, unmount, selectionActionMock } = buildContainer({});
|
|
391
|
+
|
|
392
|
+
fireEvent.mouseDown(container.querySelector('.resizer-handle.right')!);
|
|
393
|
+
fireEvent.mouseMove(container.querySelector('.resizer-handle.right')!);
|
|
394
|
+
|
|
395
|
+
unmount();
|
|
396
|
+
expect(selectionActionMock).toHaveBeenCalledWith(true);
|
|
397
|
+
});
|
|
398
|
+
|
|
399
|
+
// this is testing logic inside TableResizer, targeting the clean up in the useEffect
|
|
400
|
+
it('should call guideline plugin action to remove guidelines when removed', () => {
|
|
401
|
+
const { container, unmount, actualGuidelineMock } = buildContainer({});
|
|
402
|
+
|
|
403
|
+
fireEvent.mouseDown(container.querySelector('.resizer-handle.right')!);
|
|
404
|
+
fireEvent.mouseMove(container.querySelector('.resizer-handle.right')!);
|
|
405
|
+
|
|
406
|
+
unmount();
|
|
407
|
+
expect(actualGuidelineMock).toHaveBeenCalledWith({ guidelines: [] });
|
|
408
|
+
});
|
|
409
|
+
});
|
|
341
410
|
});
|
|
@@ -3,6 +3,7 @@ import {
|
|
|
3
3
|
tableBackgroundColorNames,
|
|
4
4
|
uuid,
|
|
5
5
|
} from '@atlaskit/adf-schema';
|
|
6
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
6
7
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
7
8
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
8
9
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -18,7 +19,6 @@ import {
|
|
|
18
19
|
createProsemirrorEditorFactory,
|
|
19
20
|
Preset,
|
|
20
21
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
21
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
22
22
|
import {
|
|
23
23
|
doc,
|
|
24
24
|
p,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { TableAttributes } from '@atlaskit/adf-schema';
|
|
2
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
2
3
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
3
4
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
4
5
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -12,7 +13,6 @@ import {
|
|
|
12
13
|
createProsemirrorEditorFactory,
|
|
13
14
|
Preset,
|
|
14
15
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
15
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
16
16
|
import {
|
|
17
17
|
doc,
|
|
18
18
|
p,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -14,7 +15,6 @@ import {
|
|
|
14
15
|
createProsemirrorEditorFactory,
|
|
15
16
|
Preset,
|
|
16
17
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
17
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
18
18
|
import {
|
|
19
19
|
doc,
|
|
20
20
|
p,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -12,7 +13,6 @@ import {
|
|
|
12
13
|
createProsemirrorEditorFactory,
|
|
13
14
|
Preset,
|
|
14
15
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
15
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
16
16
|
import {
|
|
17
17
|
doc,
|
|
18
18
|
table,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -13,7 +14,6 @@ import {
|
|
|
13
14
|
createProsemirrorEditorFactory,
|
|
14
15
|
Preset,
|
|
15
16
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
16
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
17
17
|
import {
|
|
18
18
|
doc,
|
|
19
19
|
p,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -9,7 +10,6 @@ import {
|
|
|
9
10
|
createProsemirrorEditorFactory,
|
|
10
11
|
Preset,
|
|
11
12
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
12
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
13
13
|
import {
|
|
14
14
|
doc,
|
|
15
15
|
p,
|
|
@@ -5,6 +5,7 @@ import type { Stub } from 'raf-stub';
|
|
|
5
5
|
import createStub from 'raf-stub';
|
|
6
6
|
|
|
7
7
|
import type { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
|
|
8
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
8
9
|
import { findOverflowScrollParent } from '@atlaskit/editor-common/ui';
|
|
9
10
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
10
11
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
@@ -19,7 +20,6 @@ import {
|
|
|
19
20
|
createProsemirrorEditorFactory,
|
|
20
21
|
Preset,
|
|
21
22
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
22
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
23
23
|
import {
|
|
24
24
|
doc,
|
|
25
25
|
table,
|
|
@@ -3,6 +3,7 @@ import { replaceRaf } from 'raf-stub';
|
|
|
3
3
|
|
|
4
4
|
import { uuid } from '@atlaskit/adf-schema';
|
|
5
5
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
6
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
6
7
|
import {
|
|
7
8
|
NodeSelection,
|
|
8
9
|
TextSelection,
|
|
@@ -14,7 +15,6 @@ import { createEditorFactory } from '@atlaskit/editor-test-helpers/create-editor
|
|
|
14
15
|
import dispatchPasteEvent from '@atlaskit/editor-test-helpers/dispatch-paste-event';
|
|
15
16
|
import {
|
|
16
17
|
doc,
|
|
17
|
-
DocBuilder,
|
|
18
18
|
expand,
|
|
19
19
|
layoutColumn,
|
|
20
20
|
layoutSection,
|
|
@@ -28,7 +28,10 @@ import { insertText } from '@atlaskit/editor-test-helpers/transactions';
|
|
|
28
28
|
|
|
29
29
|
import { handleCut } from '../../../plugins/table/event-handlers';
|
|
30
30
|
import { pluginKey as tablePluginKey } from '../../../plugins/table/pm-plugins/plugin-key';
|
|
31
|
-
import {
|
|
31
|
+
import type {
|
|
32
|
+
PluginConfig,
|
|
33
|
+
TablePluginState,
|
|
34
|
+
} from '../../../plugins/table/types';
|
|
32
35
|
|
|
33
36
|
replaceRaf();
|
|
34
37
|
const requestAnimationFrame = window.requestAnimationFrame as any;
|
|
@@ -3,6 +3,7 @@ import {
|
|
|
3
3
|
EVENT_TYPE,
|
|
4
4
|
TABLE_ACTION,
|
|
5
5
|
} from '@atlaskit/editor-common/analytics';
|
|
6
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
6
7
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
7
8
|
import type { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
8
9
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -22,7 +23,6 @@ import {
|
|
|
22
23
|
createProsemirrorEditorFactory,
|
|
23
24
|
Preset,
|
|
24
25
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
25
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
26
26
|
import {
|
|
27
27
|
doc,
|
|
28
28
|
p,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -10,7 +11,6 @@ import {
|
|
|
10
11
|
createProsemirrorEditorFactory,
|
|
11
12
|
Preset,
|
|
12
13
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
13
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
14
14
|
import {
|
|
15
15
|
doc,
|
|
16
16
|
p,
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { uuid } from '@atlaskit/adf-schema';
|
|
2
2
|
import { TableSortOrder as SortOrder } from '@atlaskit/adf-schema/steps';
|
|
3
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
3
4
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
4
5
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
5
6
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -12,7 +13,6 @@ import {
|
|
|
12
13
|
createProsemirrorEditorFactory,
|
|
13
14
|
Preset,
|
|
14
15
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
15
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
16
16
|
import {
|
|
17
17
|
doc,
|
|
18
18
|
p,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { uuid } from '@atlaskit/adf-schema';
|
|
2
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
2
3
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
3
4
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
4
5
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -13,7 +14,6 @@ import {
|
|
|
13
14
|
createProsemirrorEditorFactory,
|
|
14
15
|
Preset,
|
|
15
16
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
16
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
17
17
|
import {
|
|
18
18
|
doc,
|
|
19
19
|
p,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { uuid } from '@atlaskit/adf-schema';
|
|
2
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
2
3
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
3
4
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
4
5
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -13,7 +14,6 @@ import {
|
|
|
13
14
|
createProsemirrorEditorFactory,
|
|
14
15
|
Preset,
|
|
15
16
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
16
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
17
17
|
import {
|
|
18
18
|
doc,
|
|
19
19
|
p,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { uuid } from '@atlaskit/adf-schema';
|
|
2
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
2
3
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
3
4
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
4
5
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -11,7 +12,6 @@ import {
|
|
|
11
12
|
createProsemirrorEditorFactory,
|
|
12
13
|
Preset,
|
|
13
14
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
14
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
15
15
|
import {
|
|
16
16
|
doc,
|
|
17
17
|
p,
|
|
@@ -3,6 +3,7 @@ import React from 'react';
|
|
|
3
3
|
import { fireEvent, render, screen } from '@testing-library/react';
|
|
4
4
|
import { IntlProvider } from 'react-intl-next';
|
|
5
5
|
|
|
6
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
6
7
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
7
8
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
8
9
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -15,7 +16,6 @@ import {
|
|
|
15
16
|
createProsemirrorEditorFactory,
|
|
16
17
|
Preset,
|
|
17
18
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
18
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
19
19
|
import {
|
|
20
20
|
doc,
|
|
21
21
|
table,
|
|
@@ -4,6 +4,7 @@ import { render, screen } from '@testing-library/react';
|
|
|
4
4
|
import { IntlProvider } from 'react-intl-next';
|
|
5
5
|
|
|
6
6
|
import type { UIAnalyticsEvent } from '@atlaskit/analytics-next';
|
|
7
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
7
8
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
8
9
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
9
10
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -18,7 +19,6 @@ import {
|
|
|
18
19
|
createProsemirrorEditorFactory,
|
|
19
20
|
Preset,
|
|
20
21
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
21
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
22
22
|
import {
|
|
23
23
|
doc,
|
|
24
24
|
table,
|
|
@@ -3,10 +3,10 @@ import React from 'react';
|
|
|
3
3
|
import { fireEvent, render, screen } from '@testing-library/react';
|
|
4
4
|
import { IntlProvider } from 'react-intl-next';
|
|
5
5
|
|
|
6
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
6
7
|
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
7
8
|
import { getCellsInColumn, selectTable } from '@atlaskit/editor-tables/utils';
|
|
8
9
|
import { createEditorFactory } from '@atlaskit/editor-test-helpers/create-editor';
|
|
9
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
10
10
|
import {
|
|
11
11
|
doc,
|
|
12
12
|
table,
|
|
@@ -10,11 +10,11 @@ import {
|
|
|
10
10
|
CONTENT_COMPONENT,
|
|
11
11
|
EVENT_TYPE,
|
|
12
12
|
} from '@atlaskit/editor-common/analytics';
|
|
13
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
13
14
|
import { findParentNodeOfTypeClosestToPos } from '@atlaskit/editor-prosemirror/utils';
|
|
14
15
|
import * as prosemirrorUtils from '@atlaskit/editor-prosemirror/utils';
|
|
15
16
|
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
16
17
|
import { createEditorFactory } from '@atlaskit/editor-test-helpers/create-editor';
|
|
17
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
18
18
|
import {
|
|
19
19
|
doc,
|
|
20
20
|
table,
|
|
@@ -3,6 +3,7 @@ import React from 'react';
|
|
|
3
3
|
import { fireEvent, render, screen } from '@testing-library/react';
|
|
4
4
|
import { IntlProvider } from 'react-intl-next';
|
|
5
5
|
|
|
6
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
6
7
|
import { setTextSelection } from '@atlaskit/editor-common/utils';
|
|
7
8
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
8
9
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
@@ -16,7 +17,6 @@ import {
|
|
|
16
17
|
createProsemirrorEditorFactory,
|
|
17
18
|
Preset,
|
|
18
19
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
19
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
20
20
|
import {
|
|
21
21
|
doc,
|
|
22
22
|
p,
|
|
@@ -3,6 +3,7 @@ import React from 'react';
|
|
|
3
3
|
import { render, screen } from '@testing-library/react';
|
|
4
4
|
import { IntlProvider } from 'react-intl-next';
|
|
5
5
|
|
|
6
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
6
7
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
7
8
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
8
9
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -15,7 +16,6 @@ import {
|
|
|
15
16
|
createProsemirrorEditorFactory,
|
|
16
17
|
Preset,
|
|
17
18
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
18
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
19
19
|
import {
|
|
20
20
|
doc,
|
|
21
21
|
p,
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import clone from 'lodash/clone';
|
|
2
2
|
|
|
3
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
3
4
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
4
5
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
5
6
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -13,7 +14,6 @@ import {
|
|
|
13
14
|
createProsemirrorEditorFactory,
|
|
14
15
|
Preset,
|
|
15
16
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
16
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
17
17
|
import {
|
|
18
18
|
doc,
|
|
19
19
|
p,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -9,7 +10,6 @@ import {
|
|
|
9
10
|
createProsemirrorEditorFactory,
|
|
10
11
|
Preset,
|
|
11
12
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
12
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
13
13
|
import {
|
|
14
14
|
doc,
|
|
15
15
|
table,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -10,7 +11,6 @@ import {
|
|
|
10
11
|
createProsemirrorEditorFactory,
|
|
11
12
|
Preset,
|
|
12
13
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
13
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
14
14
|
import {
|
|
15
15
|
doc,
|
|
16
16
|
p,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { uuid } from '@atlaskit/adf-schema';
|
|
2
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
2
3
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
3
4
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
4
5
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -12,7 +13,6 @@ import {
|
|
|
12
13
|
createProsemirrorEditorFactory,
|
|
13
14
|
Preset,
|
|
14
15
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
15
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
16
16
|
import {
|
|
17
17
|
doc,
|
|
18
18
|
p,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DocBuilder } from '@atlaskit/editor-common/types';
|
|
1
2
|
import selectionPlugin from '@atlaskit/editor-core/src/plugins/selection';
|
|
2
3
|
import { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
4
|
import { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
@@ -10,7 +11,6 @@ import {
|
|
|
10
11
|
createProsemirrorEditorFactory,
|
|
11
12
|
Preset,
|
|
12
13
|
} from '@atlaskit/editor-test-helpers/create-prosemirror-editor';
|
|
13
|
-
import type { DocBuilder } from '@atlaskit/editor-test-helpers/doc-builder';
|
|
14
14
|
import {
|
|
15
15
|
doc,
|
|
16
16
|
p,
|