@atlaskit/editor-plugin-table 5.0.0 → 5.1.0
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 +6 -0
- package/dist/cjs/plugins/table/index.js +44 -35
- package/dist/cjs/plugins/table/pm-plugins/drag-and-drop/actions.js +12 -0
- package/dist/cjs/plugins/table/pm-plugins/drag-and-drop/commands.js +27 -0
- package/dist/cjs/plugins/table/pm-plugins/drag-and-drop/consts.js +11 -0
- package/dist/cjs/plugins/table/pm-plugins/drag-and-drop/index.js +32 -0
- package/dist/cjs/plugins/table/pm-plugins/drag-and-drop/plugin-factory.js +13 -0
- package/dist/cjs/plugins/table/pm-plugins/drag-and-drop/plugin-key.js +8 -0
- package/dist/cjs/plugins/table/pm-plugins/drag-and-drop/plugin.js +28 -0
- package/dist/cjs/plugins/table/pm-plugins/drag-and-drop/reducer.js +28 -0
- package/dist/cjs/plugins/table/pm-plugins/drag-and-drop/types.js +5 -0
- package/dist/es2019/plugins/table/index.js +9 -1
- package/dist/es2019/plugins/table/pm-plugins/drag-and-drop/actions.js +6 -0
- package/dist/es2019/plugins/table/pm-plugins/drag-and-drop/commands.js +14 -0
- package/dist/es2019/plugins/table/pm-plugins/drag-and-drop/consts.js +5 -0
- package/dist/es2019/plugins/table/pm-plugins/drag-and-drop/index.js +3 -0
- package/dist/es2019/plugins/table/pm-plugins/drag-and-drop/plugin-factory.js +8 -0
- package/dist/es2019/plugins/table/pm-plugins/drag-and-drop/plugin-key.js +2 -0
- package/dist/es2019/plugins/table/pm-plugins/drag-and-drop/plugin.js +22 -0
- package/dist/es2019/plugins/table/pm-plugins/drag-and-drop/reducer.js +20 -0
- package/dist/es2019/plugins/table/pm-plugins/drag-and-drop/types.js +1 -0
- package/dist/esm/plugins/table/index.js +44 -35
- package/dist/esm/plugins/table/pm-plugins/drag-and-drop/actions.js +6 -0
- package/dist/esm/plugins/table/pm-plugins/drag-and-drop/commands.js +22 -0
- package/dist/esm/plugins/table/pm-plugins/drag-and-drop/consts.js +5 -0
- package/dist/esm/plugins/table/pm-plugins/drag-and-drop/index.js +3 -0
- package/dist/esm/plugins/table/pm-plugins/drag-and-drop/plugin-factory.js +7 -0
- package/dist/esm/plugins/table/pm-plugins/drag-and-drop/plugin-key.js +2 -0
- package/dist/esm/plugins/table/pm-plugins/drag-and-drop/plugin.js +22 -0
- package/dist/esm/plugins/table/pm-plugins/drag-and-drop/reducer.js +21 -0
- package/dist/esm/plugins/table/pm-plugins/drag-and-drop/types.js +1 -0
- package/dist/types/plugins/table/pm-plugins/drag-and-drop/actions.d.ts +15 -0
- package/dist/types/plugins/table/pm-plugins/drag-and-drop/commands.d.ts +4 -0
- package/dist/types/plugins/table/pm-plugins/drag-and-drop/consts.d.ts +6 -0
- package/dist/types/plugins/table/pm-plugins/drag-and-drop/index.d.ts +4 -0
- package/dist/types/plugins/table/pm-plugins/drag-and-drop/plugin-factory.d.ts +2 -0
- package/dist/types/plugins/table/pm-plugins/drag-and-drop/plugin-key.d.ts +3 -0
- package/dist/types/plugins/table/pm-plugins/drag-and-drop/plugin.d.ts +3 -0
- package/dist/types/plugins/table/pm-plugins/drag-and-drop/reducer.d.ts +4 -0
- package/dist/types/plugins/table/pm-plugins/drag-and-drop/types.d.ts +5 -0
- package/dist/types-ts4.5/i18n/cs.d.ts +37 -0
- package/dist/types-ts4.5/i18n/da.d.ts +35 -0
- package/dist/types-ts4.5/i18n/de.d.ts +35 -0
- package/dist/types-ts4.5/i18n/en.d.ts +37 -0
- package/dist/types-ts4.5/i18n/en_GB.d.ts +37 -0
- package/dist/types-ts4.5/i18n/en_ZZ.d.ts +37 -0
- package/dist/types-ts4.5/i18n/es.d.ts +35 -0
- package/dist/types-ts4.5/i18n/fi.d.ts +35 -0
- package/dist/types-ts4.5/i18n/fr.d.ts +37 -0
- package/dist/types-ts4.5/i18n/hu.d.ts +37 -0
- package/dist/types-ts4.5/i18n/it.d.ts +37 -0
- package/dist/types-ts4.5/i18n/ja.d.ts +37 -0
- package/dist/types-ts4.5/i18n/ko.d.ts +35 -0
- package/dist/types-ts4.5/i18n/nb.d.ts +35 -0
- package/dist/types-ts4.5/i18n/nl.d.ts +37 -0
- package/dist/types-ts4.5/i18n/pl.d.ts +37 -0
- package/dist/types-ts4.5/i18n/pt_BR.d.ts +37 -0
- package/dist/types-ts4.5/i18n/ru.d.ts +37 -0
- package/dist/types-ts4.5/i18n/sv.d.ts +35 -0
- package/dist/types-ts4.5/i18n/th.d.ts +35 -0
- package/dist/types-ts4.5/i18n/tr.d.ts +37 -0
- package/dist/types-ts4.5/i18n/uk.d.ts +37 -0
- package/dist/types-ts4.5/i18n/vi.d.ts +35 -0
- package/dist/types-ts4.5/i18n/zh.d.ts +37 -0
- package/dist/types-ts4.5/i18n/zh_TW.d.ts +37 -0
- package/dist/types-ts4.5/index.d.ts +2 -0
- package/dist/types-ts4.5/plugins/table/commands/clear.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/commands/collapse.d.ts +2 -0
- package/dist/types-ts4.5/plugins/table/commands/delete.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/commands/go-to-next-cell.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/commands/hover.d.ts +8 -0
- package/dist/types-ts4.5/plugins/table/commands/index.d.ts +8 -0
- package/dist/types-ts4.5/plugins/table/commands/insert.d.ts +9 -0
- package/dist/types-ts4.5/plugins/table/commands/misc.d.ts +29 -0
- package/dist/types-ts4.5/plugins/table/commands/referentiality.d.ts +2 -0
- package/dist/types-ts4.5/plugins/table/commands/selection.d.ts +8 -0
- package/dist/types-ts4.5/plugins/table/commands/sort.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/commands/split-cell.d.ts +6 -0
- package/dist/types-ts4.5/plugins/table/commands/toggle.d.ts +12 -0
- package/dist/types-ts4.5/plugins/table/commands-with-analytics.d.ts +25 -0
- package/dist/types-ts4.5/plugins/table/create-plugin-config.d.ts +2 -0
- package/dist/types-ts4.5/plugins/table/event-handlers.d.ts +15 -0
- package/dist/types-ts4.5/plugins/table/handlers.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/index.d.ts +38 -0
- package/dist/types-ts4.5/plugins/table/nodeviews/OverflowShadowsObserver.d.ts +24 -0
- package/dist/types-ts4.5/plugins/table/nodeviews/TableComponent.d.ts +73 -0
- package/dist/types-ts4.5/plugins/table/nodeviews/TableContainer.d.ts +44 -0
- package/dist/types-ts4.5/plugins/table/nodeviews/TableResizer.d.ts +25 -0
- package/dist/types-ts4.5/plugins/table/nodeviews/TableStickyScrollbar.d.ts +24 -0
- package/dist/types-ts4.5/plugins/table/nodeviews/__mocks__/OverflowShadowsObserver.d.ts +9 -0
- package/dist/types-ts4.5/plugins/table/nodeviews/__mocks__/OverridableMock.d.ts +9 -0
- package/dist/types-ts4.5/plugins/table/nodeviews/table.d.ts +33 -0
- package/dist/types-ts4.5/plugins/table/nodeviews/tableCell.d.ts +17 -0
- package/dist/types-ts4.5/plugins/table/nodeviews/types.d.ts +26 -0
- package/dist/types-ts4.5/plugins/table/nodeviews/update-overflow-shadows.d.ts +1 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/decorations/plugin.d.ts +7 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/decorations/utils/column-controls.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/decorations/utils/column-resizing.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/decorations/utils/compose-decorations.d.ts +2 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/decorations/utils/index.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/decorations/utils/types.d.ts +6 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/default-table-selection.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/drag-and-drop/actions.d.ts +15 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/drag-and-drop/commands.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/drag-and-drop/consts.d.ts +6 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/drag-and-drop/index.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/drag-and-drop/plugin-factory.d.ts +2 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/drag-and-drop/plugin-key.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/drag-and-drop/plugin.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/drag-and-drop/reducer.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/drag-and-drop/types.d.ts +5 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/keymap.d.ts +5 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/main.d.ts +8 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/plugin-factory.d.ts +1 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/plugin-key.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/safari-delete-composition-text-issue-workaround.d.ts +15 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/sticky-headers/commands.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/sticky-headers/index.d.ts +6 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/sticky-headers/nodeviews/dom.d.ts +6 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.d.ts +73 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/sticky-headers/plugin-key.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/sticky-headers/plugin-state.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/sticky-headers/plugin.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/sticky-headers/types.d.ts +16 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/sticky-headers/util.d.ts +2 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-analytics.d.ts +23 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-local-id.d.ts +10 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/commands.d.ts +23 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/event-handlers.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/index.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/plugin-factory.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/plugin-key.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/plugin.d.ts +6 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/reducer.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/colgroup.d.ts +23 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/column-state.d.ts +14 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/consts.d.ts +2 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/content-width.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/dom.d.ts +12 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/index.d.ts +13 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/misc.d.ts +20 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/resize-column.d.ts +2 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/resize-logic.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/resize-state.d.ts +29 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/scale-table.d.ts +21 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/types.d.ts +22 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/unit-to-number.d.ts +1 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-selection-keymap.d.ts +5 -0
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-width.d.ts +17 -0
- package/dist/types-ts4.5/plugins/table/reducer.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/toolbar.d.ts +36 -0
- package/dist/types-ts4.5/plugins/table/transforms/column-width.d.ts +37 -0
- package/dist/types-ts4.5/plugins/table/transforms/delete-columns.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/transforms/delete-rows.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/transforms/fix-tables.d.ts +9 -0
- package/dist/types-ts4.5/plugins/table/transforms/index.d.ts +6 -0
- package/dist/types-ts4.5/plugins/table/transforms/merge.d.ts +5 -0
- package/dist/types-ts4.5/plugins/table/transforms/replace-table.d.ts +5 -0
- package/dist/types-ts4.5/plugins/table/transforms/split.d.ts +9 -0
- package/dist/types-ts4.5/plugins/table/types.d.ts +342 -0
- package/dist/types-ts4.5/plugins/table/ui/ColumnResizeWidget/index.d.ts +9 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingContextualButton/FixedButton.d.ts +23 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingContextualButton/index.d.ts +21 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingContextualButton/styles.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingContextualMenu/ContextualMenu.d.ts +87 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingContextualMenu/index.d.ts +23 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingContextualMenu/styles.d.ts +2 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingDeleteButton/DeleteButton.d.ts +13 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingDeleteButton/getPopUpOptions.d.ts +10 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingDeleteButton/index.d.ts +54 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingDeleteButton/types.d.ts +1 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingInsertButton/InsertButton.d.ts +13 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingInsertButton/getPopupOptions.d.ts +3 -0
- package/dist/types-ts4.5/plugins/table/ui/FloatingInsertButton/index.d.ts +35 -0
- package/dist/types-ts4.5/plugins/table/ui/LayoutButton/index.d.ts +21 -0
- package/dist/types-ts4.5/plugins/table/ui/TableFloatingControls/CornerControls/index.d.ts +16 -0
- package/dist/types-ts4.5/plugins/table/ui/TableFloatingControls/NumberColumn/index.d.ts +21 -0
- package/dist/types-ts4.5/plugins/table/ui/TableFloatingControls/RowControls/index.d.ts +17 -0
- package/dist/types-ts4.5/plugins/table/ui/TableFloatingControls/index.d.ts +39 -0
- package/dist/types-ts4.5/plugins/table/ui/common-styles.d.ts +9 -0
- package/dist/types-ts4.5/plugins/table/ui/consts.d.ts +50 -0
- package/dist/types-ts4.5/plugins/table/ui/messages.d.ts +63 -0
- package/dist/types-ts4.5/plugins/table/ui/ui-styles.d.ts +15 -0
- package/dist/types-ts4.5/plugins/table/utils/analytics.d.ts +45 -0
- package/dist/types-ts4.5/plugins/table/utils/collapse.d.ts +29 -0
- package/dist/types-ts4.5/plugins/table/utils/column-controls.d.ts +10 -0
- package/dist/types-ts4.5/plugins/table/utils/decoration.d.ts +19 -0
- package/dist/types-ts4.5/plugins/table/utils/dom.d.ts +20 -0
- package/dist/types-ts4.5/plugins/table/utils/get-allow-add-column-custom-step.d.ts +2 -0
- package/dist/types-ts4.5/plugins/table/utils/guidelines.d.ts +2 -0
- package/dist/types-ts4.5/plugins/table/utils/index.d.ts +11 -0
- package/dist/types-ts4.5/plugins/table/utils/nodes.d.ts +13 -0
- package/dist/types-ts4.5/plugins/table/utils/paste.d.ts +14 -0
- package/dist/types-ts4.5/plugins/table/utils/row-controls.d.ts +16 -0
- package/dist/types-ts4.5/plugins/table/utils/selection.d.ts +6 -0
- package/dist/types-ts4.5/plugins/table/utils/snapping.d.ts +10 -0
- package/dist/types-ts4.5/plugins/table/utils/table.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table/utils/update-plugin-state-decorations.d.ts +4 -0
- package/dist/types-ts4.5/plugins/table-plugin.d.ts +2 -0
- package/dist/types-ts4.5/types/i18n.d.ts +5 -0
- package/package.json +3 -3
- package/report.api.md +2 -17
- package/src/plugins/table/index.tsx +12 -0
- package/src/plugins/table/pm-plugins/drag-and-drop/actions.ts +29 -0
- package/src/plugins/table/pm-plugins/drag-and-drop/commands.ts +32 -0
- package/src/plugins/table/pm-plugins/drag-and-drop/consts.ts +8 -0
- package/src/plugins/table/pm-plugins/drag-and-drop/index.ts +5 -0
- package/src/plugins/table/pm-plugins/drag-and-drop/plugin-factory.ts +8 -0
- package/src/plugins/table/pm-plugins/drag-and-drop/plugin-key.ts +7 -0
- package/src/plugins/table/pm-plugins/drag-and-drop/plugin.ts +32 -0
- package/src/plugins/table/pm-plugins/drag-and-drop/reducer.ts +26 -0
- package/src/plugins/table/pm-plugins/drag-and-drop/types.ts +6 -0
- package/tmp/api-report-tmp.d.ts +100 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { Command } from '@atlaskit/editor-common/types';
|
|
2
|
+
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import type { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
4
|
+
import type { ContentNodeWithPos } from '@atlaskit/editor-prosemirror/utils';
|
|
5
|
+
import type { ResizeState } from './utils';
|
|
6
|
+
export declare const evenColumns: ({ resizeState, table, start, event, }: {
|
|
7
|
+
resizeState: ResizeState;
|
|
8
|
+
table: PMNode;
|
|
9
|
+
start: number;
|
|
10
|
+
event: MouseEvent;
|
|
11
|
+
}) => Command;
|
|
12
|
+
export declare const distributeColumnsWidths: (newResizeState: ResizeState, table: ContentNodeWithPos) => Command;
|
|
13
|
+
export declare const setResizeHandlePos: (resizeHandlePos: number | null) => Command;
|
|
14
|
+
export declare const stopResizing: (tr?: Transaction) => Command;
|
|
15
|
+
export declare const setDragging: (dragging: {
|
|
16
|
+
startX: number;
|
|
17
|
+
startWidth: number;
|
|
18
|
+
} | null, tr?: Transaction) => Command;
|
|
19
|
+
export declare const setLastClick: (lastClick: {
|
|
20
|
+
x: number;
|
|
21
|
+
y: number;
|
|
22
|
+
time: number;
|
|
23
|
+
} | null, transform?: ((tr: Transaction) => Transaction) | undefined) => Command;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
2
|
+
import type { GetEditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
3
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
4
|
+
export declare const handleMouseDown: (view: EditorView, event: MouseEvent, localResizeHandlePos: number, getEditorContainerWidth: GetEditorContainerWidth, getEditorFeatureFlags: GetEditorFeatureFlags, editorAnalyticsAPI?: EditorAnalyticsAPI) => boolean;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { ColumnResizingPluginState } from '../../types';
|
|
2
|
+
export declare const createCommand: <A = import("../../types").ColumnResizingPluginAction>(action: A | ((state: Readonly<import("prosemirror-state").EditorState>) => false | A), transform?: ((tr: import("prosemirror-state").Transaction, state: import("prosemirror-state").EditorState) => import("prosemirror-state").Transaction) | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
3
|
+
export declare const createPluginState: (dispatch: import("@atlaskit/editor-common/event-dispatcher").Dispatch<any>, initialState: ColumnResizingPluginState | ((state: import("prosemirror-state").EditorState) => ColumnResizingPluginState)) => import("prosemirror-state").SafeStateField<ColumnResizingPluginState>;
|
|
4
|
+
export declare const getPluginState: (state: import("prosemirror-state").EditorState) => ColumnResizingPluginState;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
2
|
+
import type { Dispatch } from '@atlaskit/editor-common/event-dispatcher';
|
|
3
|
+
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
4
|
+
import type { GetEditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
5
|
+
import type { ColumnResizingPluginState } from '../../types';
|
|
6
|
+
export declare function createPlugin(dispatch: Dispatch<ColumnResizingPluginState>, { lastColumnResizable }: ColumnResizingPluginState, getEditorContainerWidth: GetEditorContainerWidth, getEditorFeatureFlags: GetEditorFeatureFlags, editorAnalyticsAPI?: EditorAnalyticsAPI): SafePlugin<ColumnResizingPluginState>;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { Node as PmNode } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
type Col = Array<string | {
|
|
3
|
+
[name: string]: string;
|
|
4
|
+
}>;
|
|
5
|
+
/**
|
|
6
|
+
* This ensures the combined width of the columns (and tbody) of table is always smaller or equal
|
|
7
|
+
* than the table and table wrapper elements. This is necessary as there is no longer
|
|
8
|
+
* padding on the .pm-table-wrapper, so all elements need to be the same width to avoid
|
|
9
|
+
* overflow.
|
|
10
|
+
*/
|
|
11
|
+
export declare const getColWidthFix: (colwidth: number, tableColumnCount: number) => number;
|
|
12
|
+
export declare const generateColgroup: (table: PmNode) => Col[];
|
|
13
|
+
export declare const insertColgroupFromNode: (tableRef: HTMLTableElement, table: PmNode) => HTMLCollection;
|
|
14
|
+
export declare const hasTableBeenResized: (table: PmNode) => boolean;
|
|
15
|
+
/**
|
|
16
|
+
* Check if a table has all the column width set to tableCellMinWidth(48px) or null
|
|
17
|
+
*
|
|
18
|
+
* @param table
|
|
19
|
+
* @returns true if all column width is equal to tableCellMinWidth or null, false otherwise
|
|
20
|
+
*/
|
|
21
|
+
export declare const isMinCellWidthTable: (table: PmNode) => boolean;
|
|
22
|
+
export declare const getColgroupChildrenLength: (table: PmNode) => number;
|
|
23
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
export interface ColumnState {
|
|
3
|
+
index: number;
|
|
4
|
+
width: number;
|
|
5
|
+
minWidth: number;
|
|
6
|
+
}
|
|
7
|
+
export declare const getColumnStateFromDOM: (cells: HTMLElement[], index: number, minWidth: number) => ColumnState;
|
|
8
|
+
export declare const getFreeSpace: (state: ColumnState) => number;
|
|
9
|
+
export declare const getCellsRefsInColumn: (columnIndex: number, table: PMNode, tableStart: number, domAtPos: (pos: number) => {
|
|
10
|
+
node: Node;
|
|
11
|
+
offset: number;
|
|
12
|
+
}) => HTMLElement[];
|
|
13
|
+
export declare const calculateColumnWidth: (cells: HTMLElement[], calculateColumnWidthCb: (css: CSSStyleDeclaration, cellRef: HTMLElement, colSpan: number) => number) => number;
|
|
14
|
+
export declare const addContainerLeftRightPadding: (amount: number, css: CSSStyleDeclaration) => number;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { EditorState } from '@atlaskit/editor-prosemirror/state';
|
|
2
|
+
import { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
3
|
+
export declare const updateControls: () => (state: EditorState) => void;
|
|
4
|
+
export declare const isClickNear: (event: MouseEvent, click: {
|
|
5
|
+
x: number;
|
|
6
|
+
y: number;
|
|
7
|
+
}) => boolean;
|
|
8
|
+
export declare const getResizeCellPos: (view: EditorView, event: MouseEvent) => number | null;
|
|
9
|
+
export declare const updateStickyMargins: (table: HTMLElement) => void;
|
|
10
|
+
export declare const applyColWidthsToStickyRow: (colGroup: HTMLTableColElement | null, headerRow: HTMLTableRowElement) => void;
|
|
11
|
+
export declare const syncStickyRowToTable: (tableRef?: HTMLElement | null) => void;
|
|
12
|
+
export declare const applyTableWidthToStickyRow: (tableRef: HTMLElement, headerRow: HTMLTableRowElement) => void;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export { generateColgroup, insertColgroupFromNode, hasTableBeenResized, getColgroupChildrenLength, } from './colgroup';
|
|
2
|
+
export { contentWidth } from './content-width';
|
|
3
|
+
export { getColumnStateFromDOM, getFreeSpace, getCellsRefsInColumn, calculateColumnWidth, addContainerLeftRightPadding, } from './column-state';
|
|
4
|
+
export type { ColumnState } from './column-state';
|
|
5
|
+
export { growColumn, shrinkColumn, reduceSpace } from './resize-logic';
|
|
6
|
+
export { getResizeState, updateColgroup, getTotalWidth, evenAllColumnsWidths, bulkColumnsResize, areColumnsEven, adjustColumnsWidths, } from './resize-state';
|
|
7
|
+
export { getLayoutSize, getDefaultLayoutMaxWidth, pointsAtCell, currentColWidth, domCellAround, } from './misc';
|
|
8
|
+
export { updateControls, isClickNear, getResizeCellPos } from './dom';
|
|
9
|
+
export { scale, scaleWithParent, scaleTable, previewScaleTable, } from './scale-table';
|
|
10
|
+
export type { ScaleOptions } from './scale-table';
|
|
11
|
+
export type { ResizeState, ResizeStateWithAnalytics } from './types';
|
|
12
|
+
export { resizeColumn } from './resize-column';
|
|
13
|
+
export { COLUMN_MIN_WIDTH, TABLE_MAX_WIDTH } from './consts';
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { CellAttributes, TableLayout } from '@atlaskit/adf-schema';
|
|
2
|
+
import type { GetEditorContainerWidth } from '@atlaskit/editor-common/types';
|
|
3
|
+
import type { Node as PMNode, ResolvedPos } from '@atlaskit/editor-prosemirror/model';
|
|
4
|
+
import type { EditorState } from '@atlaskit/editor-prosemirror/state';
|
|
5
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
6
|
+
import type { TableOptions } from '../../../nodeviews/types';
|
|
7
|
+
export declare function getLayoutSize(tableLayout: TableLayout, containerWidth: number | undefined, options: TableOptions): number;
|
|
8
|
+
export declare function getDefaultLayoutMaxWidth(containerWidth?: number): number;
|
|
9
|
+
export declare function pointsAtCell($pos: ResolvedPos): false | PMNode | null;
|
|
10
|
+
export declare function currentColWidth(view: EditorView, cellPos: number, { colspan, colwidth }: CellAttributes): number;
|
|
11
|
+
export declare function domCellAround(target: HTMLElement | null): HTMLElement | null;
|
|
12
|
+
interface getTableMaxWidthProps {
|
|
13
|
+
table: PMNode;
|
|
14
|
+
tableStart: number;
|
|
15
|
+
state: EditorState;
|
|
16
|
+
layout: TableLayout;
|
|
17
|
+
getEditorContainerWidth: GetEditorContainerWidth;
|
|
18
|
+
}
|
|
19
|
+
export declare const getTableMaxWidth: ({ table, tableStart, state, layout, getEditorContainerWidth, }: getTableMaxWidthProps) => number;
|
|
20
|
+
export {};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { ResizeState } from './types';
|
|
2
|
+
export declare const growColumn: (state: ResizeState, colIndex: number, amount: number, selectedColumns?: number[]) => ResizeState;
|
|
3
|
+
export declare const shrinkColumn: (state: ResizeState, colIndex: number, amount: number, selectedColumns?: number[]) => ResizeState;
|
|
4
|
+
export declare function reduceSpace(state: ResizeState, amount: number, ignoreCols?: number[]): ResizeState;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import type { TableLayout } from '@atlaskit/adf-schema';
|
|
2
|
+
import type { GetEditorContainerWidth } from '@atlaskit/editor-common/types';
|
|
3
|
+
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
4
|
+
import type { EditorState } from '@atlaskit/editor-prosemirror/state';
|
|
5
|
+
import type { Rect } from '@atlaskit/editor-tables/table-map';
|
|
6
|
+
import type { ResizeState, ResizeStateWithAnalytics } from './types';
|
|
7
|
+
export declare const getResizeState: ({ minWidth, maxSize, table, tableRef, start, domAtPos, }: {
|
|
8
|
+
minWidth: number;
|
|
9
|
+
maxSize: number;
|
|
10
|
+
table: PMNode;
|
|
11
|
+
tableRef: HTMLTableElement;
|
|
12
|
+
start: number;
|
|
13
|
+
domAtPos: (pos: number) => {
|
|
14
|
+
node: Node;
|
|
15
|
+
offset: number;
|
|
16
|
+
};
|
|
17
|
+
}) => ResizeState;
|
|
18
|
+
export declare const updateColgroup: (state: ResizeState, tableRef: HTMLElement) => void;
|
|
19
|
+
export declare const getTotalWidth: ({ cols }: ResizeState) => number;
|
|
20
|
+
export declare const adjustColumnsWidths: (resizeState: ResizeState, maxSize: number) => ResizeState;
|
|
21
|
+
export declare const evenAllColumnsWidths: (resizeState: ResizeState) => ResizeState;
|
|
22
|
+
export declare const evenSelectedColumnsWidths: (resizeState: ResizeState, rect: Rect) => ResizeState;
|
|
23
|
+
export declare const bulkColumnsResize: (resizeState: ResizeState, columnsIndexes: number[], sourceColumnIndex: number) => ResizeState;
|
|
24
|
+
export declare const areColumnsEven: (resizeState: ResizeState) => boolean;
|
|
25
|
+
export declare const normaliseTableLayout: (input: string | undefined | null) => TableLayout;
|
|
26
|
+
export declare const getNewResizeStateFromSelectedColumns: (rect: Rect, state: EditorState, domAtPos: (pos: number) => {
|
|
27
|
+
node: Node;
|
|
28
|
+
offset: number;
|
|
29
|
+
}, getEditorContainerWidth: GetEditorContainerWidth) => ResizeStateWithAnalytics | undefined;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
import type { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
3
|
+
import type { DomAtPos } from '@atlaskit/editor-prosemirror/utils';
|
|
4
|
+
import type { ResizeState } from '../utils/types';
|
|
5
|
+
export interface ScaleOptions {
|
|
6
|
+
node: PMNode;
|
|
7
|
+
prevNode: PMNode;
|
|
8
|
+
start: number;
|
|
9
|
+
containerWidth?: number;
|
|
10
|
+
previousContainerWidth?: number;
|
|
11
|
+
parentWidth?: number;
|
|
12
|
+
layoutChanged?: boolean;
|
|
13
|
+
isBreakoutEnabled?: boolean;
|
|
14
|
+
isFullWidthModeEnabled?: boolean;
|
|
15
|
+
isTableResizingEnabled?: boolean;
|
|
16
|
+
}
|
|
17
|
+
export declare const scale: (tableRef: HTMLTableElement, options: ScaleOptions, domAtPos: DomAtPos) => ResizeState | undefined;
|
|
18
|
+
export declare const scaleWithParent: (tableRef: HTMLTableElement, parentWidth: number, table: PMNode, start: number, domAtPos: DomAtPos) => ResizeState;
|
|
19
|
+
export declare function scaleTableTo(state: ResizeState, maxSize: number): ResizeState;
|
|
20
|
+
export declare const previewScaleTable: (tableRef: HTMLTableElement | null | undefined, options: ScaleOptions, domAtPos: DomAtPos) => void;
|
|
21
|
+
export declare const scaleTable: (tableRef: HTMLTableElement | null | undefined, options: ScaleOptions, domAtPos: DomAtPos) => (tr: Transaction) => Transaction;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { ContentNodeWithPos } from '@atlaskit/editor-prosemirror/utils';
|
|
2
|
+
import { ColumnState } from './column-state';
|
|
3
|
+
export interface ResizeState {
|
|
4
|
+
cols: ColumnState[];
|
|
5
|
+
widths: number[];
|
|
6
|
+
maxSize: number;
|
|
7
|
+
overflow: boolean;
|
|
8
|
+
tableWidth: number;
|
|
9
|
+
}
|
|
10
|
+
export interface ResizeStateWithAnalytics {
|
|
11
|
+
resizeState: ResizeState;
|
|
12
|
+
table: ContentNodeWithPos;
|
|
13
|
+
changed: boolean;
|
|
14
|
+
attributes: {
|
|
15
|
+
position: number;
|
|
16
|
+
count: number;
|
|
17
|
+
totalRowCount: number;
|
|
18
|
+
totalColumnCount: number;
|
|
19
|
+
widthsBefore: number[];
|
|
20
|
+
widthsAfter: number[];
|
|
21
|
+
};
|
|
22
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const unitToNumber: (unit: string | null) => number;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
2
|
+
import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
|
3
|
+
import type tablePlugin from '../index';
|
|
4
|
+
export declare function tableSelectionKeymapPlugin(editorSelectionAPI: ExtractInjectionAPI<typeof tablePlugin>['selection'] | undefined): SafePlugin;
|
|
5
|
+
export default tableSelectionKeymapPlugin;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A plugin for handle table custom widths
|
|
3
|
+
* Has login to scan the document, add width value to table's width attribute when necessary
|
|
4
|
+
* Also holds resizing state to hide / show table controls
|
|
5
|
+
*/
|
|
6
|
+
import type { DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
|
|
7
|
+
import type { Dispatch } from '@atlaskit/editor-common/event-dispatcher';
|
|
8
|
+
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
9
|
+
import { PluginKey } from '@atlaskit/editor-prosemirror/state';
|
|
10
|
+
type TableWidthPluginState = {
|
|
11
|
+
resizing: boolean;
|
|
12
|
+
};
|
|
13
|
+
export declare const pluginKey: PluginKey<TableWidthPluginState>;
|
|
14
|
+
declare const createPlugin: (dispatch: Dispatch, dispatchAnalyticsEvent: DispatchAnalyticsEvent, fullWidthEnabled: boolean) => SafePlugin<{
|
|
15
|
+
resizing: boolean;
|
|
16
|
+
}>;
|
|
17
|
+
export { createPlugin };
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
2
|
+
import type { Command, FloatingToolbarDropdown, FloatingToolbarHandler, FloatingToolbarItem, GetEditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
3
|
+
import type { EditorState } from '@atlaskit/editor-prosemirror/state';
|
|
4
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
5
|
+
import type { Rect } from '@atlaskit/editor-tables/table-map';
|
|
6
|
+
import type { PluginConfig, ToolbarMenuConfig, ToolbarMenuContext, ToolbarMenuState } from './types';
|
|
7
|
+
export declare const messages: {
|
|
8
|
+
tableOptions: {
|
|
9
|
+
id: string;
|
|
10
|
+
defaultMessage: string;
|
|
11
|
+
description: string;
|
|
12
|
+
};
|
|
13
|
+
headerRow: {
|
|
14
|
+
id: string;
|
|
15
|
+
defaultMessage: string;
|
|
16
|
+
description: string;
|
|
17
|
+
};
|
|
18
|
+
headerColumn: {
|
|
19
|
+
id: string;
|
|
20
|
+
defaultMessage: string;
|
|
21
|
+
description: string;
|
|
22
|
+
};
|
|
23
|
+
numberedColumn: {
|
|
24
|
+
id: string;
|
|
25
|
+
defaultMessage: string;
|
|
26
|
+
description: string;
|
|
27
|
+
};
|
|
28
|
+
collapseTable: {
|
|
29
|
+
id: string;
|
|
30
|
+
defaultMessage: string;
|
|
31
|
+
description: string;
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
export declare const getToolbarMenuConfig: (config: ToolbarMenuConfig, state: ToolbarMenuState, { formatMessage }: ToolbarMenuContext, editorAnalyticsAPI: EditorAnalyticsAPI | undefined | null) => FloatingToolbarItem<Command>;
|
|
35
|
+
export declare const getToolbarCellOptionsConfig: (editorState: EditorState, editorView: EditorView | undefined | null, initialSelectionRect: Rect, { formatMessage }: ToolbarMenuContext, getEditorContainerWidth: GetEditorContainerWidth, editorAnalyticsAPI: EditorAnalyticsAPI | undefined | null) => FloatingToolbarDropdown<Command>;
|
|
36
|
+
export declare const getToolbarConfig: (getEditorContainerWidth: GetEditorContainerWidth, editorAnalyticsAPI: EditorAnalyticsAPI | undefined | null, getEditorFeatureFlags: GetEditorFeatureFlags, getEditorView: () => EditorView | null) => (config: PluginConfig) => FloatingToolbarHandler;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { GetEditorContainerWidth } from '@atlaskit/editor-common/types';
|
|
2
|
+
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import type { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
4
|
+
import type { ContentNodeWithPos } from '@atlaskit/editor-prosemirror/utils';
|
|
5
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
6
|
+
import type { ResizeState } from '../pm-plugins/table-resizing/utils';
|
|
7
|
+
/**
|
|
8
|
+
* Given a new ResizeState object, create a transaction that replaces and updates the table node based on new state.
|
|
9
|
+
* @param resizeState
|
|
10
|
+
* @param table
|
|
11
|
+
* @param start
|
|
12
|
+
* @returns
|
|
13
|
+
*/
|
|
14
|
+
export declare const updateColumnWidths: (resizeState: ResizeState, table: PMNode, start: number) => (tr: Transaction) => Transaction;
|
|
15
|
+
/**
|
|
16
|
+
* This function is called when user inserts/deletes a column in a table to;
|
|
17
|
+
* - rescale all columns (if the table did not overflow before the insertion)
|
|
18
|
+
* - and update column widths.
|
|
19
|
+
*
|
|
20
|
+
* This is done manually to avoid a multi-dispatch in TableComponent. See [ED-8288].
|
|
21
|
+
* @param table
|
|
22
|
+
* @param view
|
|
23
|
+
* @returns Updated transaction with rescaled columns for a given table
|
|
24
|
+
*/
|
|
25
|
+
export declare const rescaleColumnsNew: () => (table: ContentNodeWithPos, view: EditorView | undefined) => (tr: Transaction) => Transaction;
|
|
26
|
+
/**
|
|
27
|
+
* This function is called when user inserts/deletes a column in a table to;
|
|
28
|
+
* - rescale all columns (if the table did not overflow before the insertion)
|
|
29
|
+
* - and update column widths.
|
|
30
|
+
*
|
|
31
|
+
* This is done manually to avoid a multi-dispatch in TableComponent. See [ED-8288].
|
|
32
|
+
* @param table
|
|
33
|
+
* @param view
|
|
34
|
+
* @returns Updated transaction with rescaled columns for a given table
|
|
35
|
+
*/
|
|
36
|
+
export declare const rescaleColumnsOld: (getEditorContainerWidth: GetEditorContainerWidth) => (table: ContentNodeWithPos, view: EditorView | undefined) => (tr: Transaction) => Transaction;
|
|
37
|
+
export declare const rescaleColumns: (getEditorContainerWidth?: GetEditorContainerWidth) => (table: ContentNodeWithPos, view: EditorView | undefined) => (tr: Transaction) => Transaction;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
2
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
3
|
+
import type { Rect } from '@atlaskit/editor-tables/table-map';
|
|
4
|
+
export declare const deleteColumns: (rect: Rect, allowCustomStep: boolean, view?: EditorView) => (tr: Transaction) => Transaction;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
import { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
3
|
+
import { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
4
|
+
import { ReportInvalidNodeAttrs } from '../types';
|
|
5
|
+
export declare const removeExtraneousColumnWidths: (node: PMNode, basePos: number, tr: Transaction, reportInvalidTableCellSpanAttrs?: ReportInvalidNodeAttrs) => boolean;
|
|
6
|
+
export declare const fixTables: (tr: Transaction, reportInvalidTableCellSpanAttrs?: ReportInvalidNodeAttrs) => Transaction | undefined;
|
|
7
|
+
export declare const fixAutoSizedTable: (view: EditorView, tableNode: PMNode, tableRef: HTMLTableElement, tablePos: number, opts: {
|
|
8
|
+
containerWidth: number;
|
|
9
|
+
}) => Transaction;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { fixTables, fixAutoSizedTable } from './fix-tables';
|
|
2
|
+
export { mergeCells, canMergeCells, mergeEmptyColumns } from './merge';
|
|
3
|
+
export { deleteColumns } from './delete-columns';
|
|
4
|
+
export { deleteRows } from './delete-rows';
|
|
5
|
+
export { updateColumnWidths } from './column-width';
|
|
6
|
+
export { replaceSelectedTable } from './replace-table';
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
import { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
3
|
+
export declare function mergeCells(tr: Transaction): Transaction;
|
|
4
|
+
export declare function canMergeCells(tr: Transaction): boolean;
|
|
5
|
+
export declare function mergeEmptyColumns(table: PMNode): PMNode | null;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
2
|
+
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
3
|
+
import { Slice } from '@atlaskit/editor-prosemirror/model';
|
|
4
|
+
import { EditorState, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
5
|
+
export declare const replaceSelectedTable: (state: EditorState, content: string | Slice, inputMethod: INPUT_METHOD.KEYBOARD | INPUT_METHOD.CLIPBOARD, editorAnalyticsAPI?: EditorAnalyticsAPI) => Transaction;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
2
|
+
/**
|
|
3
|
+
* Helper to split all the cells in a range of columns
|
|
4
|
+
* @param tr
|
|
5
|
+
* @param tablePos
|
|
6
|
+
* @param columnStart - Start of the rect included (rect.left)
|
|
7
|
+
* @param columnEnd - End of the rect not included (rect.right)
|
|
8
|
+
*/
|
|
9
|
+
export declare function splitCellsInColumns(tr: Transaction, tablePos: number, columnStart: number, columnEnd: number): Transaction;
|