@atlaskit/editor-plugin-table 2.3.0 → 2.4.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/.eslintrc.js +6 -0
- package/CHANGELOG.md +12 -0
- package/dist/cjs/plugins/table/commands/go-to-next-cell.js +2 -2
- package/dist/cjs/plugins/table/commands/insert.js +3 -3
- package/dist/cjs/plugins/table/commands/misc.js +26 -26
- package/dist/cjs/plugins/table/commands/referentiality.js +1 -1
- package/dist/cjs/plugins/table/commands/selection.js +2 -2
- package/dist/cjs/plugins/table/commands/sort.js +8 -8
- package/dist/cjs/plugins/table/commands-with-analytics.js +3 -3
- package/dist/cjs/plugins/table/event-handlers.js +15 -15
- package/dist/cjs/plugins/table/handlers.js +6 -7
- package/dist/cjs/plugins/table/index.js +16 -16
- package/dist/cjs/plugins/table/nodeviews/TableComponent.js +44 -40
- package/dist/cjs/plugins/table/nodeviews/TableContainer.js +10 -8
- package/dist/cjs/plugins/table/nodeviews/TableResizer.js +2 -2
- package/dist/cjs/plugins/table/nodeviews/table.js +11 -9
- package/dist/cjs/plugins/table/nodeviews/tableCell.js +1 -1
- package/dist/cjs/plugins/table/pm-plugins/decorations/plugin.js +2 -2
- package/dist/cjs/plugins/table/pm-plugins/keymap.js +2 -2
- package/dist/cjs/plugins/table/pm-plugins/main.js +24 -21
- package/dist/cjs/plugins/table/pm-plugins/safari-delete-composition-text-issue-workaround.js +1 -1
- package/dist/cjs/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.js +2 -2
- package/dist/cjs/plugins/table/pm-plugins/table-local-id.js +1 -1
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/commands.js +1 -1
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/event-handlers.js +4 -4
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/colgroup.js +1 -1
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/column-state.js +1 -1
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/dom.js +1 -1
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/misc.js +2 -2
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/resize-state.js +1 -1
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/scale-table.js +2 -3
- package/dist/cjs/plugins/table/pm-plugins/table-width.js +3 -3
- package/dist/cjs/plugins/table/toolbar.js +26 -26
- package/dist/cjs/plugins/table/transforms/column-width.js +5 -5
- package/dist/cjs/plugins/table/transforms/delete-columns.js +1 -1
- package/dist/cjs/plugins/table/transforms/merge.js +1 -1
- package/dist/cjs/plugins/table/transforms/replace-table.js +2 -2
- package/dist/cjs/plugins/table/ui/FloatingContextualButton/FixedButton.js +2 -2
- package/dist/cjs/plugins/table/ui/FloatingContextualButton/index.js +3 -3
- package/dist/cjs/plugins/table/ui/FloatingContextualButton/styles.js +1 -1
- package/dist/cjs/plugins/table/ui/FloatingContextualMenu/ContextualMenu.js +11 -11
- package/dist/cjs/plugins/table/ui/FloatingContextualMenu/index.js +2 -2
- package/dist/cjs/plugins/table/ui/FloatingContextualMenu/styles.js +6 -3
- package/dist/cjs/plugins/table/ui/FloatingDeleteButton/index.js +10 -10
- package/dist/cjs/plugins/table/ui/FloatingInsertButton/InsertButton.js +3 -3
- package/dist/cjs/plugins/table/ui/FloatingInsertButton/index.js +9 -9
- package/dist/cjs/plugins/table/ui/LayoutButton/index.js +3 -3
- package/dist/cjs/plugins/table/ui/TableFloatingControls/CornerControls/index.js +1 -1
- package/dist/cjs/plugins/table/ui/common-styles.js +2 -2
- package/dist/cjs/plugins/table/ui/consts.js +2 -2
- package/dist/cjs/plugins/table/ui/ui-styles.js +2 -2
- package/dist/cjs/plugins/table/utils/column-controls.js +11 -11
- package/dist/cjs/plugins/table/utils/decoration.js +11 -11
- package/dist/cjs/plugins/table/utils/nodes.js +1 -1
- package/dist/cjs/plugins/table/utils/row-controls.js +9 -9
- package/dist/cjs/plugins/table/utils/selection.js +1 -1
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/plugins/table/commands/clear.js +3 -1
- package/dist/es2019/plugins/table/commands/go-to-next-cell.js +2 -2
- package/dist/es2019/plugins/table/commands/insert.js +4 -3
- package/dist/es2019/plugins/table/commands/misc.js +4 -4
- package/dist/es2019/plugins/table/commands/referentiality.js +1 -1
- package/dist/es2019/plugins/table/commands/selection.js +3 -3
- package/dist/es2019/plugins/table/commands/sort.js +3 -4
- package/dist/es2019/plugins/table/commands/toggle.js +1 -2
- package/dist/es2019/plugins/table/commands-with-analytics.js +4 -4
- package/dist/es2019/plugins/table/event-handlers.js +3 -5
- package/dist/es2019/plugins/table/handlers.js +5 -5
- package/dist/es2019/plugins/table/index.js +16 -16
- package/dist/es2019/plugins/table/nodeviews/OverflowShadowsObserver.js +1 -1
- package/dist/es2019/plugins/table/nodeviews/TableComponent.js +21 -18
- package/dist/es2019/plugins/table/nodeviews/TableContainer.js +10 -9
- package/dist/es2019/plugins/table/nodeviews/TableResizer.js +4 -4
- package/dist/es2019/plugins/table/nodeviews/table.js +11 -9
- package/dist/es2019/plugins/table/nodeviews/tableCell.js +2 -2
- package/dist/es2019/plugins/table/pm-plugins/decorations/plugin.js +2 -3
- package/dist/es2019/plugins/table/pm-plugins/keymap.js +4 -4
- package/dist/es2019/plugins/table/pm-plugins/main.js +13 -13
- package/dist/es2019/plugins/table/pm-plugins/safari-delete-composition-text-issue-workaround.js +1 -1
- package/dist/es2019/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.js +2 -2
- package/dist/es2019/plugins/table/pm-plugins/table-local-id.js +1 -1
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/commands.js +1 -1
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/event-handlers.js +4 -4
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/colgroup.js +1 -1
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/column-state.js +1 -1
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/dom.js +1 -1
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/misc.js +2 -3
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/resize-state.js +1 -1
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/scale-table.js +2 -3
- package/dist/es2019/plugins/table/pm-plugins/table-selection-keymap.js +1 -1
- package/dist/es2019/plugins/table/pm-plugins/table-width.js +3 -3
- package/dist/es2019/plugins/table/toolbar.js +16 -18
- package/dist/es2019/plugins/table/transforms/column-width.js +6 -7
- package/dist/es2019/plugins/table/transforms/delete-columns.js +1 -1
- package/dist/es2019/plugins/table/transforms/merge.js +2 -1
- package/dist/es2019/plugins/table/transforms/replace-table.js +2 -2
- package/dist/es2019/plugins/table/transforms/split.js +1 -0
- package/dist/es2019/plugins/table/ui/FloatingContextualButton/FixedButton.js +2 -2
- package/dist/es2019/plugins/table/ui/FloatingContextualButton/index.js +4 -4
- package/dist/es2019/plugins/table/ui/FloatingContextualButton/styles.js +1 -1
- package/dist/es2019/plugins/table/ui/FloatingContextualMenu/ContextualMenu.js +10 -10
- package/dist/es2019/plugins/table/ui/FloatingContextualMenu/index.js +2 -2
- package/dist/es2019/plugins/table/ui/FloatingContextualMenu/styles.js +7 -4
- package/dist/es2019/plugins/table/ui/FloatingDeleteButton/index.js +5 -5
- package/dist/es2019/plugins/table/ui/FloatingInsertButton/InsertButton.js +3 -3
- package/dist/es2019/plugins/table/ui/FloatingInsertButton/index.js +4 -5
- package/dist/es2019/plugins/table/ui/LayoutButton/index.js +3 -3
- package/dist/es2019/plugins/table/ui/TableFloatingControls/CornerControls/index.js +1 -1
- package/dist/es2019/plugins/table/ui/common-styles.js +5 -5
- package/dist/es2019/plugins/table/ui/consts.js +2 -2
- package/dist/es2019/plugins/table/ui/ui-styles.js +3 -3
- package/dist/es2019/plugins/table/utils/column-controls.js +3 -3
- package/dist/es2019/plugins/table/utils/decoration.js +2 -2
- package/dist/es2019/plugins/table/utils/guidelines.js +1 -1
- package/dist/es2019/plugins/table/utils/nodes.js +1 -1
- package/dist/es2019/plugins/table/utils/row-controls.js +3 -3
- package/dist/es2019/plugins/table/utils/selection.js +1 -1
- package/dist/es2019/version.json +1 -1
- package/dist/esm/plugins/table/commands/clear.js +3 -1
- package/dist/esm/plugins/table/commands/go-to-next-cell.js +2 -2
- package/dist/esm/plugins/table/commands/insert.js +4 -3
- package/dist/esm/plugins/table/commands/misc.js +4 -4
- package/dist/esm/plugins/table/commands/referentiality.js +1 -1
- package/dist/esm/plugins/table/commands/selection.js +3 -3
- package/dist/esm/plugins/table/commands/sort.js +3 -4
- package/dist/esm/plugins/table/commands/toggle.js +1 -2
- package/dist/esm/plugins/table/commands-with-analytics.js +4 -4
- package/dist/esm/plugins/table/event-handlers.js +3 -5
- package/dist/esm/plugins/table/handlers.js +5 -5
- package/dist/esm/plugins/table/index.js +16 -16
- package/dist/esm/plugins/table/nodeviews/OverflowShadowsObserver.js +1 -1
- package/dist/esm/plugins/table/nodeviews/TableComponent.js +39 -36
- package/dist/esm/plugins/table/nodeviews/TableContainer.js +10 -9
- package/dist/esm/plugins/table/nodeviews/TableResizer.js +4 -4
- package/dist/esm/plugins/table/nodeviews/table.js +11 -9
- package/dist/esm/plugins/table/nodeviews/tableCell.js +2 -2
- package/dist/esm/plugins/table/pm-plugins/decorations/plugin.js +2 -3
- package/dist/esm/plugins/table/pm-plugins/keymap.js +4 -4
- package/dist/esm/plugins/table/pm-plugins/main.js +13 -13
- package/dist/esm/plugins/table/pm-plugins/safari-delete-composition-text-issue-workaround.js +1 -1
- package/dist/esm/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.js +2 -2
- package/dist/esm/plugins/table/pm-plugins/table-local-id.js +1 -1
- package/dist/esm/plugins/table/pm-plugins/table-resizing/commands.js +1 -1
- package/dist/esm/plugins/table/pm-plugins/table-resizing/event-handlers.js +4 -4
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/colgroup.js +1 -1
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/column-state.js +1 -1
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/dom.js +1 -1
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/misc.js +2 -3
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/resize-state.js +1 -1
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/scale-table.js +2 -3
- package/dist/esm/plugins/table/pm-plugins/table-selection-keymap.js +1 -1
- package/dist/esm/plugins/table/pm-plugins/table-width.js +3 -3
- package/dist/esm/plugins/table/toolbar.js +16 -18
- package/dist/esm/plugins/table/transforms/column-width.js +6 -7
- package/dist/esm/plugins/table/transforms/delete-columns.js +1 -1
- package/dist/esm/plugins/table/transforms/merge.js +2 -1
- package/dist/esm/plugins/table/transforms/replace-table.js +2 -2
- package/dist/esm/plugins/table/transforms/split.js +1 -0
- package/dist/esm/plugins/table/ui/FloatingContextualButton/FixedButton.js +2 -2
- package/dist/esm/plugins/table/ui/FloatingContextualButton/index.js +4 -4
- package/dist/esm/plugins/table/ui/FloatingContextualButton/styles.js +1 -1
- package/dist/esm/plugins/table/ui/FloatingContextualMenu/ContextualMenu.js +10 -10
- package/dist/esm/plugins/table/ui/FloatingContextualMenu/index.js +2 -2
- package/dist/esm/plugins/table/ui/FloatingContextualMenu/styles.js +6 -3
- package/dist/esm/plugins/table/ui/FloatingDeleteButton/index.js +5 -5
- package/dist/esm/plugins/table/ui/FloatingInsertButton/InsertButton.js +3 -3
- package/dist/esm/plugins/table/ui/FloatingInsertButton/index.js +4 -5
- package/dist/esm/plugins/table/ui/LayoutButton/index.js +3 -3
- package/dist/esm/plugins/table/ui/TableFloatingControls/CornerControls/index.js +1 -1
- package/dist/esm/plugins/table/ui/common-styles.js +5 -5
- package/dist/esm/plugins/table/ui/consts.js +2 -2
- package/dist/esm/plugins/table/ui/ui-styles.js +3 -3
- package/dist/esm/plugins/table/utils/column-controls.js +3 -3
- package/dist/esm/plugins/table/utils/decoration.js +2 -2
- package/dist/esm/plugins/table/utils/guidelines.js +1 -1
- package/dist/esm/plugins/table/utils/nodes.js +1 -1
- package/dist/esm/plugins/table/utils/row-controls.js +3 -3
- package/dist/esm/plugins/table/utils/selection.js +1 -1
- package/dist/esm/version.json +1 -1
- package/dist/types/plugins/table/commands/go-to-next-cell.d.ts +2 -2
- package/dist/types/plugins/table/commands/insert.d.ts +1 -1
- package/dist/types/plugins/table/commands/selection.d.ts +1 -1
- package/dist/types/plugins/table/commands/sort.d.ts +1 -1
- package/dist/types/plugins/table/commands-with-analytics.d.ts +4 -5
- package/dist/types/plugins/table/event-handlers.d.ts +1 -1
- package/dist/types/plugins/table/handlers.d.ts +1 -1
- package/dist/types/plugins/table/index.d.ts +4 -4
- package/dist/types/plugins/table/nodeviews/TableComponent.d.ts +3 -4
- package/dist/types/plugins/table/nodeviews/TableContainer.d.ts +2 -2
- package/dist/types/plugins/table/nodeviews/TableResizer.d.ts +1 -1
- package/dist/types/plugins/table/nodeviews/table.d.ts +3 -4
- package/dist/types/plugins/table/nodeviews/tableCell.d.ts +1 -2
- package/dist/types/plugins/table/nodeviews/types.d.ts +2 -1
- package/dist/types/plugins/table/pm-plugins/decorations/plugin.d.ts +2 -2
- package/dist/types/plugins/table/pm-plugins/keymap.d.ts +1 -1
- package/dist/types/plugins/table/pm-plugins/main.d.ts +4 -6
- package/dist/types/plugins/table/pm-plugins/safari-delete-composition-text-issue-workaround.d.ts +1 -1
- package/dist/types/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.d.ts +1 -1
- package/dist/types/plugins/table/pm-plugins/sticky-headers/plugin.d.ts +1 -1
- package/dist/types/plugins/table/pm-plugins/table-local-id.d.ts +0 -12
- package/dist/types/plugins/table/pm-plugins/table-resizing/plugin.d.ts +3 -3
- package/dist/types/plugins/table/pm-plugins/table-resizing/utils/misc.d.ts +3 -4
- package/dist/types/plugins/table/pm-plugins/table-resizing/utils/resize-state.d.ts +3 -3
- package/dist/types/plugins/table/pm-plugins/table-resizing/utils/types.d.ts +1 -1
- package/dist/types/plugins/table/pm-plugins/table-width.d.ts +1 -1
- package/dist/types/plugins/table/toolbar.d.ts +4 -5
- package/dist/types/plugins/table/transforms/column-width.d.ts +1 -1
- package/dist/types/plugins/table/transforms/replace-table.d.ts +1 -1
- package/dist/types/plugins/table/types.d.ts +1 -1
- package/dist/types/plugins/table/ui/FloatingContextualButton/index.d.ts +2 -2
- package/dist/types/plugins/table/ui/FloatingContextualMenu/ContextualMenu.d.ts +2 -2
- package/dist/types/plugins/table/ui/FloatingContextualMenu/index.d.ts +1 -1
- package/dist/types/plugins/table/ui/FloatingDeleteButton/DeleteButton.d.ts +1 -2
- package/dist/types/plugins/table/ui/FloatingDeleteButton/index.d.ts +1 -1
- package/dist/types/plugins/table/ui/FloatingInsertButton/index.d.ts +1 -1
- package/dist/types/plugins/table/ui/LayoutButton/index.d.ts +1 -1
- package/dist/types/plugins/table/ui/TableFloatingControls/CornerControls/index.d.ts +1 -1
- package/dist/types/plugins/table/ui/TableFloatingControls/index.d.ts +1 -1
- package/dist/types/plugins/table/utils/analytics.d.ts +1 -1
- package/dist/types/plugins/table/utils/collapse.d.ts +2 -2
- package/dist/types/plugins/table/utils/decoration.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/commands/go-to-next-cell.d.ts +2 -2
- package/dist/types-ts4.5/plugins/table/commands/insert.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/commands/selection.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/commands/sort.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/commands-with-analytics.d.ts +4 -5
- package/dist/types-ts4.5/plugins/table/event-handlers.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/handlers.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/index.d.ts +4 -4
- package/dist/types-ts4.5/plugins/table/nodeviews/TableComponent.d.ts +3 -4
- package/dist/types-ts4.5/plugins/table/nodeviews/TableContainer.d.ts +2 -2
- package/dist/types-ts4.5/plugins/table/nodeviews/TableResizer.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/nodeviews/table.d.ts +3 -4
- package/dist/types-ts4.5/plugins/table/nodeviews/tableCell.d.ts +1 -2
- package/dist/types-ts4.5/plugins/table/nodeviews/types.d.ts +2 -1
- package/dist/types-ts4.5/plugins/table/pm-plugins/decorations/plugin.d.ts +2 -2
- package/dist/types-ts4.5/plugins/table/pm-plugins/keymap.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/pm-plugins/main.d.ts +4 -6
- package/dist/types-ts4.5/plugins/table/pm-plugins/safari-delete-composition-text-issue-workaround.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/pm-plugins/sticky-headers/plugin.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-local-id.d.ts +0 -12
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/plugin.d.ts +3 -3
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/misc.d.ts +3 -4
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/resize-state.d.ts +3 -3
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-resizing/utils/types.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/pm-plugins/table-width.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/toolbar.d.ts +4 -5
- package/dist/types-ts4.5/plugins/table/transforms/column-width.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/transforms/replace-table.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/types.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/ui/FloatingContextualButton/index.d.ts +2 -2
- package/dist/types-ts4.5/plugins/table/ui/FloatingContextualMenu/ContextualMenu.d.ts +2 -2
- package/dist/types-ts4.5/plugins/table/ui/FloatingContextualMenu/index.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/ui/FloatingDeleteButton/DeleteButton.d.ts +1 -2
- package/dist/types-ts4.5/plugins/table/ui/FloatingDeleteButton/index.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/ui/FloatingInsertButton/index.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/ui/LayoutButton/index.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/ui/TableFloatingControls/CornerControls/index.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/ui/TableFloatingControls/index.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/utils/analytics.d.ts +1 -1
- package/dist/types-ts4.5/plugins/table/utils/collapse.d.ts +2 -2
- package/dist/types-ts4.5/plugins/table/utils/decoration.d.ts +1 -1
- package/examples/99-testing.tsx +11 -10
- package/package.json +11 -3
- package/report.api.md +2 -0
- package/src/__tests__/integration/arrow-down-into-table.ts +3 -2
- package/src/__tests__/integration/auto-size.ts +8 -10
- package/src/__tests__/integration/cell-selection.ts +8 -7
- package/src/__tests__/integration/change-date-inside-table.ts +4 -5
- package/src/__tests__/integration/delete-columns.ts +6 -4
- package/src/__tests__/integration/delete-last-column-in-full-width.ts +4 -4
- package/src/__tests__/integration/delete-last-column-with-empty-action.ts +4 -4
- package/src/__tests__/integration/delete-last-row-with-empty-action.ts +4 -4
- package/src/__tests__/integration/delete-rows.ts +8 -6
- package/src/__tests__/integration/delete-table-when-selected.ts +10 -11
- package/src/__tests__/integration/deleting-empty-paragraph-under-table.ts +5 -4
- package/src/__tests__/integration/even-columns.ts +8 -8
- package/src/__tests__/integration/floating-toolbar.ts +3 -1
- package/src/__tests__/integration/horizontal-scroll-shadows.ts +7 -8
- package/src/__tests__/integration/horizontal-scroll.ts +8 -7
- package/src/__tests__/integration/insert-cell-header-with-strong-mark.ts +3 -4
- package/src/__tests__/integration/insert-row-inside-layout.ts +8 -6
- package/src/__tests__/integration/layout.ts +8 -11
- package/src/__tests__/integration/meta-arrowup-cursor-in-first-row.ts +3 -2
- package/src/__tests__/integration/resize-handler.ts +2 -2
- package/src/__tests__/integration/resize.ts +15 -15
- package/src/__tests__/integration/scale.ts +8 -8
- package/src/__tests__/integration/sticky-header.ts +3 -2
- package/src/__tests__/unit/analytics.ts +21 -21
- package/src/__tests__/unit/collab.ts +16 -16
- package/src/__tests__/unit/commands/go-to-next-cell.ts +14 -13
- package/src/__tests__/unit/commands/insert.ts +12 -12
- package/src/__tests__/unit/commands/misc.ts +18 -16
- package/src/__tests__/unit/commands/sort.ts +9 -8
- package/src/__tests__/unit/commands.ts +13 -14
- package/src/__tests__/unit/copy-paste.ts +31 -25
- package/src/__tests__/unit/event-handlers/index.ts +15 -13
- package/src/__tests__/unit/event-handlers.ts +18 -18
- package/src/__tests__/unit/fix-tables.ts +9 -9
- package/src/__tests__/unit/get-toolbar-config.ts +21 -21
- package/src/__tests__/unit/handlers.ts +13 -12
- package/src/__tests__/unit/hover-selection.ts +14 -13
- package/src/__tests__/unit/index-with-fake-timers.ts +6 -5
- package/src/__tests__/unit/index.ts +30 -31
- package/src/__tests__/unit/layout.ts +16 -16
- package/src/__tests__/unit/nodeviews/OverflowShadowsObserver.ts +4 -2
- package/src/__tests__/unit/nodeviews/TableComponent.tsx +21 -20
- package/src/__tests__/unit/nodeviews/TableContainer.tsx +38 -105
- package/src/__tests__/unit/nodeviews/cell.ts +17 -16
- package/src/__tests__/unit/nodeviews/table.ts +15 -13
- package/src/__tests__/unit/pm-plugins/decorations/column-controls.ts +1 -1
- package/src/__tests__/unit/pm-plugins/decorations/column-resizing.ts +7 -8
- package/src/__tests__/unit/pm-plugins/decorations/plugin.ts +45 -57
- package/src/__tests__/unit/pm-plugins/main.ts +15 -14
- package/src/__tests__/unit/pm-plugins/safari-delete-composition-text-issue-workaround.ts +7 -6
- package/src/__tests__/unit/pm-plugins/sticky-headers/tableRow.tsx +23 -21
- package/src/__tests__/unit/pm-plugins/table-local-id.ts +14 -15
- package/src/__tests__/unit/pm-plugins/table-resizing/colgroup.ts +3 -2
- package/src/__tests__/unit/pm-plugins/table-resizing/event-handlers.ts +22 -21
- package/src/__tests__/unit/sort-column.ts +16 -14
- package/src/__tests__/unit/toolbar.ts +22 -21
- package/src/__tests__/unit/transforms/delete-columns.ts +16 -14
- package/src/__tests__/unit/transforms/delete-rows.ts +16 -14
- package/src/__tests__/unit/transforms/merging.ts +15 -13
- package/src/__tests__/unit/ui/ContextualMenu.tsx +8 -6
- package/src/__tests__/unit/ui/CornerControls.tsx +11 -9
- package/src/__tests__/unit/ui/DeleteButton.tsx +3 -1
- package/src/__tests__/unit/ui/FixedButton.tsx +4 -1
- package/src/__tests__/unit/ui/FloatingContextualButton.tsx +14 -11
- package/src/__tests__/unit/ui/FloatingContextualMenu.tsx +8 -6
- package/src/__tests__/unit/ui/FloatingDeleteButton.tsx +12 -9
- package/src/__tests__/unit/ui/FloatingInsertButton.tsx +21 -19
- package/src/__tests__/unit/ui/RowControls.tsx +15 -12
- package/src/__tests__/unit/ui/TableFloatingControls.tsx +16 -15
- package/src/__tests__/unit/undo-redo.ts +17 -15
- package/src/__tests__/unit/utils/collapse.ts +7 -8
- package/src/__tests__/unit/utils/nodes.ts +12 -11
- package/src/__tests__/unit/utils/row-controls.ts +12 -12
- package/src/__tests__/unit/utils/table.ts +5 -4
- package/src/__tests__/unit/utils.ts +18 -16
- package/src/__tests__/visual-regression/cell-options-menu.ts +2 -2
- package/src/__tests__/visual-regression/index.ts +8 -7
- package/src/__tests__/visual-regression/sticky-header.ts +6 -5
- package/src/plugins/table/commands/clear.ts +3 -2
- package/src/plugins/table/commands/collapse.ts +1 -0
- package/src/plugins/table/commands/go-to-next-cell.ts +8 -7
- package/src/plugins/table/commands/insert.ts +8 -7
- package/src/plugins/table/commands/misc.ts +15 -18
- package/src/plugins/table/commands/referentiality.ts +3 -1
- package/src/plugins/table/commands/selection.ts +11 -10
- package/src/plugins/table/commands/sort.ts +9 -9
- package/src/plugins/table/commands/split-cell.ts +1 -1
- package/src/plugins/table/commands/toggle.ts +2 -3
- package/src/plugins/table/commands-with-analytics.ts +15 -15
- package/src/plugins/table/event-handlers.ts +19 -20
- package/src/plugins/table/handlers.ts +6 -7
- package/src/plugins/table/index.tsx +51 -51
- package/src/plugins/table/nodeviews/OverflowShadowsObserver.ts +2 -1
- package/src/plugins/table/nodeviews/TableComponent.tsx +23 -30
- package/src/plugins/table/nodeviews/TableContainer.tsx +16 -23
- package/src/plugins/table/nodeviews/TableResizer.tsx +8 -7
- package/src/plugins/table/nodeviews/table.tsx +25 -18
- package/src/plugins/table/nodeviews/tableCell.tsx +9 -7
- package/src/plugins/table/nodeviews/types.ts +4 -2
- package/src/plugins/table/nodeviews/update-overflow-shadows.ts +3 -1
- package/src/plugins/table/pm-plugins/decorations/plugin.ts +4 -3
- package/src/plugins/table/pm-plugins/decorations/utils/column-controls.ts +2 -1
- package/src/plugins/table/pm-plugins/keymap.ts +8 -8
- package/src/plugins/table/pm-plugins/main.ts +38 -33
- package/src/plugins/table/pm-plugins/plugin-factory.ts +2 -0
- package/src/plugins/table/pm-plugins/plugin-key.ts +1 -0
- package/src/plugins/table/pm-plugins/safari-delete-composition-text-issue-workaround.ts +2 -1
- package/src/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.ts +6 -7
- package/src/plugins/table/pm-plugins/sticky-headers/plugin-key.ts +1 -0
- package/src/plugins/table/pm-plugins/sticky-headers/plugin.ts +3 -4
- package/src/plugins/table/pm-plugins/table-local-id.ts +3 -4
- package/src/plugins/table/pm-plugins/table-resizing/commands.ts +3 -2
- package/src/plugins/table/pm-plugins/table-resizing/event-handlers.ts +13 -14
- package/src/plugins/table/pm-plugins/table-resizing/plugin-factory.ts +1 -0
- package/src/plugins/table/pm-plugins/table-resizing/plugin-key.ts +1 -0
- package/src/plugins/table/pm-plugins/table-resizing/plugin.ts +7 -6
- package/src/plugins/table/pm-plugins/table-resizing/utils/colgroup.ts +2 -1
- package/src/plugins/table/pm-plugins/table-resizing/utils/column-state.ts +1 -1
- package/src/plugins/table/pm-plugins/table-resizing/utils/dom.ts +3 -3
- package/src/plugins/table/pm-plugins/table-resizing/utils/misc.ts +8 -9
- package/src/plugins/table/pm-plugins/table-resizing/utils/resize-state.ts +8 -6
- package/src/plugins/table/pm-plugins/table-resizing/utils/scale-table.ts +4 -5
- package/src/plugins/table/pm-plugins/table-resizing/utils/types.ts +2 -1
- package/src/plugins/table/pm-plugins/table-selection-keymap.ts +4 -3
- package/src/plugins/table/pm-plugins/table-width.ts +5 -4
- package/src/plugins/table/toolbar.tsx +54 -57
- package/src/plugins/table/transforms/column-width.ts +13 -13
- package/src/plugins/table/transforms/delete-columns.ts +2 -2
- package/src/plugins/table/transforms/delete-rows.ts +2 -2
- package/src/plugins/table/transforms/merge.ts +3 -3
- package/src/plugins/table/transforms/replace-table.ts +6 -5
- package/src/plugins/table/transforms/split.ts +1 -1
- package/src/plugins/table/types.ts +3 -3
- package/src/plugins/table/ui/FloatingContextualButton/FixedButton.tsx +4 -2
- package/src/plugins/table/ui/FloatingContextualButton/index.tsx +12 -11
- package/src/plugins/table/ui/FloatingContextualButton/styles.ts +5 -3
- package/src/plugins/table/ui/FloatingContextualMenu/ContextualMenu.tsx +27 -28
- package/src/plugins/table/ui/FloatingContextualMenu/index.tsx +10 -11
- package/src/plugins/table/ui/FloatingContextualMenu/styles.ts +8 -4
- package/src/plugins/table/ui/FloatingDeleteButton/DeleteButton.tsx +5 -2
- package/src/plugins/table/ui/FloatingDeleteButton/index.tsx +9 -9
- package/src/plugins/table/ui/FloatingInsertButton/InsertButton.tsx +4 -5
- package/src/plugins/table/ui/FloatingInsertButton/index.tsx +16 -18
- package/src/plugins/table/ui/LayoutButton/index.tsx +6 -6
- package/src/plugins/table/ui/TableFloatingControls/CornerControls/index.tsx +3 -2
- package/src/plugins/table/ui/TableFloatingControls/NumberColumn/index.tsx +2 -1
- package/src/plugins/table/ui/TableFloatingControls/index.tsx +2 -3
- package/src/plugins/table/ui/common-styles.ts +33 -34
- package/src/plugins/table/ui/consts.ts +12 -13
- package/src/plugins/table/ui/ui-styles.ts +24 -22
- package/src/plugins/table/utils/analytics.ts +3 -2
- package/src/plugins/table/utils/collapse.ts +2 -2
- package/src/plugins/table/utils/column-controls.ts +5 -6
- package/src/plugins/table/utils/decoration.ts +6 -7
- package/src/plugins/table/utils/dom.ts +1 -0
- package/src/plugins/table/utils/guidelines.ts +2 -2
- package/src/plugins/table/utils/nodes.ts +2 -1
- package/src/plugins/table/utils/row-controls.ts +4 -3
- package/src/plugins/table/utils/selection.ts +2 -1
- package/src/plugins/table/utils/table.ts +2 -1
- package/tmp/api-report-tmp.d.ts +2 -0
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import type { Command } from '@atlaskit/editor-common/types';
|
|
1
|
+
import { TableSortOrder as SortOrder } from '@atlaskit/adf-schema/steps';
|
|
3
2
|
import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
4
3
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
4
|
+
import type { Command, GetEditorContainerWidth } from '@atlaskit/editor-common/types';
|
|
5
|
+
import { Rect } from '@atlaskit/editor-tables/table-map';
|
|
7
6
|
import { ResizeStateWithAnalytics } from './pm-plugins/table-resizing/utils';
|
|
8
|
-
import
|
|
7
|
+
import { InsertRowMethods, InsertRowOptions, RowInsertPosition } from './types';
|
|
9
8
|
export declare const emptyMultipleCellsWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined | null) => (inputMethod: INPUT_METHOD.CONTEXT_MENU | INPUT_METHOD.KEYBOARD | INPUT_METHOD.FLOATING_TB, targetCellPosition?: number) => Command;
|
|
10
9
|
export declare const mergeCellsWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | null | undefined) => (inputMethod: INPUT_METHOD.CONTEXT_MENU | INPUT_METHOD.FLOATING_TB) => Command;
|
|
11
10
|
export declare const splitCellWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined | null) => (inputMethod: INPUT_METHOD.CONTEXT_MENU | INPUT_METHOD.FLOATING_TB) => Command;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { EditorState, Transaction } from 'prosemirror-state';
|
|
2
2
|
import { EditorView } from 'prosemirror-view';
|
|
3
3
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
4
|
-
import { ElementContentRects } from './types';
|
|
5
4
|
import type { GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
5
|
+
import { ElementContentRects } from './types';
|
|
6
6
|
export declare const handleBlur: (view: EditorView, event: Event) => boolean;
|
|
7
7
|
export declare const handleFocus: (view: EditorView, event: Event) => boolean;
|
|
8
8
|
export declare const handleClick: (view: EditorView, event: Event) => boolean;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ReadonlyTransaction, Transaction } from 'prosemirror-state';
|
|
2
2
|
import { TablePluginState } from './types';
|
|
3
3
|
export declare const handleDocOrSelectionChanged: (tr: Transaction | ReadonlyTransaction, pluginState: TablePluginState) => TablePluginState;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import type { Command } from '@atlaskit/editor-common/types';
|
|
2
1
|
import { AnalyticsEventPayload } from '@atlaskit/editor-common/analytics';
|
|
3
2
|
import type { EditorSelectionAPI } from '@atlaskit/editor-common/selection';
|
|
4
|
-
import {
|
|
5
|
-
import type { GetEditorFeatureFlags, NextEditorPlugin } from '@atlaskit/editor-common/types';
|
|
3
|
+
import type { Command, GetEditorFeatureFlags, NextEditorPlugin } from '@atlaskit/editor-common/types';
|
|
6
4
|
import type { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
7
5
|
import type { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
8
|
-
import type { widthPlugin } from '@atlaskit/editor-plugin-width';
|
|
9
6
|
import type { guidelinePlugin } from '@atlaskit/editor-plugin-guideline';
|
|
7
|
+
import type { widthPlugin } from '@atlaskit/editor-plugin-width';
|
|
8
|
+
import { PluginConfig } from './types';
|
|
10
9
|
interface TablePluginOptions {
|
|
11
10
|
tableOptions: PluginConfig;
|
|
11
|
+
tableResizingEnabled?: boolean;
|
|
12
12
|
breakoutEnabled?: boolean;
|
|
13
13
|
allowContextualMenu?: boolean;
|
|
14
14
|
fullWidthEnabled?: boolean;
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Node as PmNode } from 'prosemirror-model';
|
|
3
3
|
import { EditorView } from 'prosemirror-view';
|
|
4
|
-
import type {
|
|
4
|
+
import type { TableColumnOrdering } from '@atlaskit/adf-schema/steps';
|
|
5
|
+
import type { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
|
|
6
|
+
import type { EditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
5
7
|
import { RowStickyState, StickyPluginState } from '../pm-plugins/sticky-headers';
|
|
6
|
-
import type { GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
7
8
|
import { PluginInjectionAPI, ShadowEvent } from '../types';
|
|
8
|
-
import type { TableColumnOrdering } from '@atlaskit/adf-schema/steps';
|
|
9
9
|
import type { TableOptions } from './types';
|
|
10
|
-
import type { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
|
|
11
10
|
export interface ComponentProps {
|
|
12
11
|
view: EditorView;
|
|
13
12
|
getNode: () => PmNode;
|
|
@@ -29,7 +29,7 @@ type TableContainerProps = {
|
|
|
29
29
|
node: PMNode;
|
|
30
30
|
className: string;
|
|
31
31
|
containerWidth: EditorContainerWidth;
|
|
32
|
-
|
|
32
|
+
isTableResizingEnabled: boolean | undefined;
|
|
33
33
|
isBreakoutEnabled: boolean | undefined;
|
|
34
34
|
editorView: EditorView;
|
|
35
35
|
getPos: () => number | undefined;
|
|
@@ -37,5 +37,5 @@ type TableContainerProps = {
|
|
|
37
37
|
isNested: boolean;
|
|
38
38
|
pluginInjectionApi?: PluginInjectionAPI;
|
|
39
39
|
};
|
|
40
|
-
export declare const TableContainer: ({ children, node, className, containerWidth: { lineLength, width: editorWidth },
|
|
40
|
+
export declare const TableContainer: ({ children, node, className, containerWidth: { lineLength, width: editorWidth }, isTableResizingEnabled, isBreakoutEnabled, editorView, getPos, tableRef, isNested, pluginInjectionApi, }: PropsWithChildren<TableContainerProps>) => JSX.Element;
|
|
41
41
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { PropsWithChildren } from 'react';
|
|
2
|
-
import { EditorView } from 'prosemirror-view';
|
|
3
2
|
import { Node as PMNode } from 'prosemirror-model';
|
|
3
|
+
import { EditorView } from 'prosemirror-view';
|
|
4
4
|
import type { GuidelineConfig } from '@atlaskit/editor-plugin-guideline';
|
|
5
5
|
interface TableResizerProps {
|
|
6
6
|
width: number;
|
|
@@ -2,12 +2,11 @@
|
|
|
2
2
|
import { Node as PmNode } from 'prosemirror-model';
|
|
3
3
|
import { EditorView, NodeView } from 'prosemirror-view';
|
|
4
4
|
import type { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
|
|
5
|
-
import type { getPosHandler, getPosHandlerNode } from '@atlaskit/editor-common/types';
|
|
6
|
-
import ReactNodeView from '@atlaskit/editor-common/react-node-view';
|
|
7
5
|
import type { PortalProviderAPI } from '@atlaskit/editor-common/portal-provider';
|
|
8
|
-
import
|
|
9
|
-
import {
|
|
6
|
+
import ReactNodeView from '@atlaskit/editor-common/react-node-view';
|
|
7
|
+
import type { GetEditorContainerWidth, GetEditorFeatureFlags, getPosHandler, getPosHandlerNode } from '@atlaskit/editor-common/types';
|
|
10
8
|
import { PluginInjectionAPI } from '../types';
|
|
9
|
+
import { Props, TableOptions } from './types';
|
|
11
10
|
type ForwardRef = (node: HTMLElement | null) => void;
|
|
12
11
|
export default class TableView extends ReactNodeView<Props> {
|
|
13
12
|
private table;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { Node } from 'prosemirror-model';
|
|
2
2
|
import { EditorView, NodeView } from 'prosemirror-view';
|
|
3
3
|
import { ProviderFactory } from '@atlaskit/editor-common/provider-factory';
|
|
4
|
-
import type { getPosHandler } from '@atlaskit/editor-common/types';
|
|
5
|
-
import type { GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
4
|
+
import type { GetEditorFeatureFlags, getPosHandler } from '@atlaskit/editor-common/types';
|
|
6
5
|
export default class TableCellNodeView implements NodeView {
|
|
7
6
|
node: Node;
|
|
8
7
|
dom: HTMLElement;
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import { Node as PmNode } from 'prosemirror-model';
|
|
2
2
|
import { EditorView } from 'prosemirror-view';
|
|
3
|
-
import type { GetEditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
4
3
|
import { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
|
|
5
4
|
import type { PortalProviderAPI } from '@atlaskit/editor-common/portal-provider';
|
|
5
|
+
import type { GetEditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
6
6
|
import type { PluginInjectionAPI } from '../types';
|
|
7
7
|
export type TableOptions = {
|
|
8
8
|
isBreakoutEnabled?: boolean;
|
|
9
9
|
isFullWidthModeEnabled?: boolean;
|
|
10
10
|
wasFullWidthModeEnabled?: boolean;
|
|
11
|
+
isTableResizingEnabled?: boolean;
|
|
11
12
|
};
|
|
12
13
|
export interface Props {
|
|
13
14
|
node: PmNode;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { EditorState, PluginKey, Transaction, ReadonlyTransaction } from 'prosemirror-state';
|
|
1
|
+
import { EditorState, PluginKey, ReadonlyTransaction, Transaction } from 'prosemirror-state';
|
|
3
2
|
import { DecorationSet } from 'prosemirror-view';
|
|
3
|
+
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
4
4
|
export declare const pluginKey: PluginKey<any>;
|
|
5
5
|
export declare const getDecorations: (state: EditorState) => DecorationSet;
|
|
6
6
|
export declare const handleDocOrSelectionChanged: (tr: Transaction | ReadonlyTransaction, decorationSet: DecorationSet, oldState: EditorState, newState: EditorState) => DecorationSet;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
import { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
1
2
|
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
2
3
|
import type { GetEditorContainerWidth } from '@atlaskit/editor-common/types';
|
|
3
|
-
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
4
4
|
export declare function keymapPlugin(getEditorContainerWidth: GetEditorContainerWidth, editorAnalyticsAPI: EditorAnalyticsAPI | undefined | null): SafePlugin;
|
|
5
5
|
export default keymapPlugin;
|
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { DispatchAnalyticsEvent, EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
2
2
|
import type { Dispatch, EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
|
|
3
3
|
import type { PortalProviderAPI } from '@atlaskit/editor-common/portal-provider';
|
|
4
|
-
import {
|
|
5
|
-
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
6
|
-
import type { DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
|
|
4
|
+
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
7
5
|
import type { GetEditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
8
|
-
import
|
|
9
|
-
export declare const createPlugin: (dispatchAnalyticsEvent: DispatchAnalyticsEvent, dispatch: Dispatch, portalProviderAPI: PortalProviderAPI, eventDispatcher: EventDispatcher, pluginConfig: PluginConfig, getEditorContainerWidth: GetEditorContainerWidth, getEditorFeatureFlags: GetEditorFeatureFlags, breakoutEnabled?: boolean, fullWidthModeEnabled?: boolean, previousFullWidthModeEnabled?: boolean, editorAnalyticsAPI?: EditorAnalyticsAPI, pluginInjectionApi?: PluginInjectionAPI) => SafePlugin<import("../types").TablePluginState>;
|
|
6
|
+
import { PluginConfig, PluginInjectionAPI } from '../types';
|
|
7
|
+
export declare const createPlugin: (dispatchAnalyticsEvent: DispatchAnalyticsEvent, dispatch: Dispatch, portalProviderAPI: PortalProviderAPI, eventDispatcher: EventDispatcher, pluginConfig: PluginConfig, getEditorContainerWidth: GetEditorContainerWidth, getEditorFeatureFlags: GetEditorFeatureFlags, breakoutEnabled?: boolean, fullWidthModeEnabled?: boolean, tableResizingEnabled?: boolean, previousFullWidthModeEnabled?: boolean, editorAnalyticsAPI?: EditorAnalyticsAPI, pluginInjectionApi?: PluginInjectionAPI) => SafePlugin<import("../types").TablePluginState>;
|
package/dist/types/plugins/table/pm-plugins/safari-delete-composition-text-issue-workaround.d.ts
CHANGED
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
* https://github.com/ProseMirror/prosemirror/issues/934
|
|
4
4
|
* We will remove this plugin when Webkit fix the problem itself.
|
|
5
5
|
*/
|
|
6
|
-
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
7
6
|
import { PluginKey } from 'prosemirror-state';
|
|
8
7
|
import { DecorationSet } from 'prosemirror-view';
|
|
8
|
+
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
9
9
|
interface SafariDeleteCompositionTextIssueWorkaroundPluginState {
|
|
10
10
|
renderSpan: boolean;
|
|
11
11
|
decorations: DecorationSet;
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
import { Node as PmNode } from 'prosemirror-model';
|
|
3
3
|
import { EditorView, NodeView } from 'prosemirror-view';
|
|
4
4
|
import { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
|
|
5
|
+
import type { GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
5
6
|
import { TablePluginState } from '../../../types';
|
|
6
7
|
import { TableDOMElements } from './dom';
|
|
7
|
-
import type { GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
8
8
|
/**
|
|
9
9
|
* Check if a given node is a header row with this definition:
|
|
10
10
|
* - all children are tableHeader cells
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
+
import { Dispatch, EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
|
|
1
2
|
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
2
3
|
import type { GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
3
|
-
import { EventDispatcher, Dispatch } from '@atlaskit/editor-common/event-dispatcher';
|
|
4
4
|
export declare const createPlugin: (dispatch: Dispatch, eventDispatcher: EventDispatcher, initialState: (() => never[]) | undefined, getEditorFeatureFlags: GetEditorFeatureFlags) => SafePlugin<import("./types").StickyPluginState>;
|
|
@@ -1,15 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* A plugin for ensuring tables always have unique local IDs, and to
|
|
3
|
-
* preserve/not regenerate them when they are being cut and paste around the
|
|
4
|
-
* document.
|
|
5
|
-
*
|
|
6
|
-
* More broadly, this plugin should be generalised so it can solve this ‘unique
|
|
7
|
-
* id’ problem across the codebase for any node, but for now this will live on
|
|
8
|
-
* its own solving only for tables.
|
|
9
|
-
*
|
|
10
|
-
* TODO: https://product-fabric.atlassian.net/browse/ED-12714
|
|
11
|
-
*
|
|
12
|
-
*/
|
|
13
1
|
import { Dispatch } from '@atlaskit/editor-common/event-dispatcher';
|
|
14
2
|
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
15
3
|
interface TableLocalIdPluginState {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
2
|
-
import { Dispatch } from '@atlaskit/editor-common/event-dispatcher';
|
|
3
|
-
import { ColumnResizingPluginState } from '../../types';
|
|
4
1
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
2
|
+
import { Dispatch } from '@atlaskit/editor-common/event-dispatcher';
|
|
3
|
+
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
5
4
|
import type { GetEditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
5
|
+
import { ColumnResizingPluginState } from '../../types';
|
|
6
6
|
export declare function createPlugin(dispatch: Dispatch<ColumnResizingPluginState>, { lastColumnResizable }: ColumnResizingPluginState, getEditorContainerWidth: GetEditorContainerWidth, getEditorFeatureFlags: GetEditorFeatureFlags, editorAnalyticsAPI?: EditorAnalyticsAPI): SafePlugin<ColumnResizingPluginState>;
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import { ResolvedPos } from 'prosemirror-model';
|
|
1
|
+
import { Node as PMNode, ResolvedPos } from 'prosemirror-model';
|
|
2
|
+
import { EditorState } from 'prosemirror-state';
|
|
2
3
|
import { EditorView } from 'prosemirror-view';
|
|
3
4
|
import { CellAttributes, TableLayout } from '@atlaskit/adf-schema';
|
|
4
|
-
import { TableOptions } from '../../../nodeviews/types';
|
|
5
|
-
import { Node as PMNode } from 'prosemirror-model';
|
|
6
|
-
import { EditorState } from 'prosemirror-state';
|
|
7
5
|
import type { GetEditorContainerWidth } from '@atlaskit/editor-common/types';
|
|
6
|
+
import { TableOptions } from '../../../nodeviews/types';
|
|
8
7
|
export declare function getLayoutSize(tableLayout: TableLayout, containerWidth: number | undefined, options: TableOptions): number;
|
|
9
8
|
export declare function getDefaultLayoutMaxWidth(containerWidth?: number): number;
|
|
10
9
|
export declare function pointsAtCell($pos: ResolvedPos): false | PMNode | null | undefined;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Node as PMNode } from 'prosemirror-model';
|
|
2
|
-
import { Rect } from '@atlaskit/editor-tables/table-map';
|
|
3
|
-
import { TableLayout } from '@atlaskit/adf-schema';
|
|
4
|
-
import { ResizeState, ResizeStateWithAnalytics } from './types';
|
|
5
2
|
import { EditorState } from 'prosemirror-state';
|
|
3
|
+
import { TableLayout } from '@atlaskit/adf-schema';
|
|
6
4
|
import type { GetEditorContainerWidth } from '@atlaskit/editor-common/types';
|
|
5
|
+
import { Rect } from '@atlaskit/editor-tables/table-map';
|
|
6
|
+
import { ResizeState, ResizeStateWithAnalytics } from './types';
|
|
7
7
|
export declare const getResizeState: ({ minWidth, maxSize, table, tableRef, start, domAtPos, }: {
|
|
8
8
|
minWidth: number;
|
|
9
9
|
maxSize: number;
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
* Has login to scan the document, add width value to table's width attribute when necessary
|
|
4
4
|
* Also holds resizing state to hide / show table controls
|
|
5
5
|
*/
|
|
6
|
-
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
7
6
|
import { PluginKey } from 'prosemirror-state';
|
|
8
7
|
import { Dispatch } from '@atlaskit/editor-common/event-dispatcher';
|
|
8
|
+
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
9
9
|
type TableWidthPluginState = {
|
|
10
10
|
resizing: boolean;
|
|
11
11
|
};
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import type { Command, FloatingToolbarDropdown, FloatingToolbarHandler, FloatingToolbarItem, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
2
|
-
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
3
|
-
import { ToolbarMenuConfig, ToolbarMenuState, ToolbarMenuContext, PluginConfig } from './types';
|
|
4
1
|
import { EditorState } from 'prosemirror-state';
|
|
5
|
-
import type { GetEditorContainerWidth } from '@atlaskit/editor-common/types';
|
|
6
|
-
import { Rect } from '@atlaskit/editor-tables/table-map';
|
|
7
2
|
import { EditorView } from 'prosemirror-view';
|
|
3
|
+
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
4
|
+
import type { Command, FloatingToolbarDropdown, FloatingToolbarHandler, FloatingToolbarItem, GetEditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
5
|
+
import { Rect } from '@atlaskit/editor-tables/table-map';
|
|
6
|
+
import { PluginConfig, ToolbarMenuConfig, ToolbarMenuContext, ToolbarMenuState } from './types';
|
|
8
7
|
export declare const messages: {
|
|
9
8
|
tableOptions: {
|
|
10
9
|
id: string;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Node as PMNode } from 'prosemirror-model';
|
|
2
2
|
import { Transaction } from 'prosemirror-state';
|
|
3
|
-
import { ResizeState } from '../pm-plugins/table-resizing/utils';
|
|
4
3
|
import { ContentNodeWithPos } from 'prosemirror-utils';
|
|
5
4
|
import { EditorView } from 'prosemirror-view';
|
|
6
5
|
import type { GetEditorContainerWidth } from '@atlaskit/editor-common/types';
|
|
6
|
+
import { ResizeState } from '../pm-plugins/table-resizing/utils';
|
|
7
7
|
export declare const updateColumnWidths: (resizeState: ResizeState, table: PMNode, start: number) => (tr: Transaction) => Transaction;
|
|
8
8
|
/**
|
|
9
9
|
* This function is called when user inserts/deletes a column in a table to;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Transaction, EditorState } from 'prosemirror-state';
|
|
2
1
|
import { Slice } from 'prosemirror-model';
|
|
2
|
+
import { EditorState, Transaction } from 'prosemirror-state';
|
|
3
3
|
import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
4
4
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
5
5
|
export declare const replaceSelectedTable: (state: EditorState, content: string | Slice, inputMethod: INPUT_METHOD.KEYBOARD | INPUT_METHOD.CLIPBOARD, editorAnalyticsAPI?: EditorAnalyticsAPI) => Transaction;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { Node as PmNode } from 'prosemirror-model';
|
|
2
2
|
import { Transaction } from 'prosemirror-state';
|
|
3
|
-
import { Rect } from '@atlaskit/editor-tables/table-map';
|
|
4
3
|
import { DecorationSet } from 'prosemirror-view';
|
|
5
4
|
import { IntlShape } from 'react-intl-next';
|
|
6
5
|
import { TableLayout } from '@atlaskit/adf-schema';
|
|
7
6
|
import { TableColumnOrdering } from '@atlaskit/adf-schema/steps';
|
|
8
7
|
import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
9
8
|
import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
|
9
|
+
import { Rect } from '@atlaskit/editor-tables/table-map';
|
|
10
10
|
import type tablePlugin from './index';
|
|
11
11
|
export declare const RESIZE_HANDLE_AREA_DECORATION_GAP = 30;
|
|
12
12
|
export type RowInsertPosition = 'TOP' | 'BOTTOM';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { jsx } from '@emotion/react';
|
|
2
|
+
import { Node as PMNode } from 'prosemirror-model';
|
|
2
3
|
import { EditorView } from 'prosemirror-view';
|
|
3
4
|
import { TableLayout } from '@atlaskit/adf-schema';
|
|
4
|
-
import { RowStickyState } from '../../pm-plugins/sticky-headers';
|
|
5
5
|
import { DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
|
|
6
|
-
import {
|
|
6
|
+
import { RowStickyState } from '../../pm-plugins/sticky-headers';
|
|
7
7
|
export interface Props {
|
|
8
8
|
editorView: EditorView;
|
|
9
9
|
tableWrapper?: HTMLElement;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
2
|
import { Component } from 'react';
|
|
3
3
|
import { jsx } from '@emotion/react';
|
|
4
|
-
import { Rect } from '@atlaskit/editor-tables/table-map';
|
|
5
4
|
import { EditorView } from 'prosemirror-view';
|
|
6
5
|
import { WrappedComponentProps } from 'react-intl-next';
|
|
7
|
-
import type { GetEditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
8
6
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
7
|
+
import type { GetEditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
8
|
+
import { Rect } from '@atlaskit/editor-tables/table-map';
|
|
9
9
|
export declare const messages: {
|
|
10
10
|
cellBackground: {
|
|
11
11
|
id: string;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
2
|
import { jsx } from '@emotion/react';
|
|
3
3
|
import { EditorView } from 'prosemirror-view';
|
|
4
|
-
import { PluginConfig } from '../../types';
|
|
5
4
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
6
5
|
import type { GetEditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
6
|
+
import { PluginConfig } from '../../types';
|
|
7
7
|
export interface Props {
|
|
8
8
|
editorView: EditorView;
|
|
9
9
|
isOpen: boolean;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React, { SyntheticEvent } from 'react';
|
|
2
|
-
import { WrappedComponentProps } from 'react-intl-next';
|
|
3
|
-
import { MessageDescriptor } from 'react-intl-next';
|
|
2
|
+
import { MessageDescriptor, WrappedComponentProps } from 'react-intl-next';
|
|
4
3
|
export interface ButtonProps {
|
|
5
4
|
removeLabel: MessageDescriptor;
|
|
6
5
|
style?: object;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Component } from 'react';
|
|
2
2
|
import { Selection } from 'prosemirror-state';
|
|
3
3
|
import { EditorView } from 'prosemirror-view';
|
|
4
|
+
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
4
5
|
import { RowStickyState } from '../../pm-plugins/sticky-headers';
|
|
5
6
|
import { CellSelectionType } from './types';
|
|
6
|
-
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
7
7
|
export interface Props {
|
|
8
8
|
editorView: EditorView;
|
|
9
9
|
selection: Selection;
|
|
@@ -2,8 +2,8 @@ import React from 'react';
|
|
|
2
2
|
import { Node as PmNode } from 'prosemirror-model';
|
|
3
3
|
import { EditorView } from 'prosemirror-view';
|
|
4
4
|
import { WrappedComponentProps } from 'react-intl-next';
|
|
5
|
-
import { DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
|
|
6
5
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
6
|
+
import { DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
|
|
7
7
|
import type { GetEditorContainerWidth } from '@atlaskit/editor-common/types';
|
|
8
8
|
export interface Props {
|
|
9
9
|
editorView: EditorView;
|
|
@@ -2,8 +2,8 @@ import React from 'react';
|
|
|
2
2
|
import { EditorView } from 'prosemirror-view';
|
|
3
3
|
import { WrappedComponentProps } from 'react-intl-next';
|
|
4
4
|
import { TableLayout } from '@atlaskit/adf-schema';
|
|
5
|
-
import { RowStickyState } from '../../pm-plugins/sticky-headers';
|
|
6
5
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
6
|
+
import { RowStickyState } from '../../pm-plugins/sticky-headers';
|
|
7
7
|
export interface Props {
|
|
8
8
|
editorView: EditorView;
|
|
9
9
|
targetRef?: HTMLElement;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { WrappedComponentProps } from 'react-intl-next';
|
|
3
2
|
import { EditorView } from 'prosemirror-view';
|
|
3
|
+
import type { WrappedComponentProps } from 'react-intl-next';
|
|
4
4
|
export interface Props {
|
|
5
5
|
editorView: EditorView;
|
|
6
6
|
tableRef?: HTMLTableElement;
|
|
@@ -2,8 +2,8 @@ import { Component } from 'react';
|
|
|
2
2
|
import { Selection } from 'prosemirror-state';
|
|
3
3
|
import { EditorView } from 'prosemirror-view';
|
|
4
4
|
import type { TableColumnOrdering } from '@atlaskit/adf-schema/steps';
|
|
5
|
-
import { RowStickyState } from '../../pm-plugins/sticky-headers';
|
|
6
5
|
import type { GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
6
|
+
import { RowStickyState } from '../../pm-plugins/sticky-headers';
|
|
7
7
|
export interface Props {
|
|
8
8
|
editorView: EditorView;
|
|
9
9
|
getEditorFeatureFlags: GetEditorFeatureFlags;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Selection } from 'prosemirror-state';
|
|
2
|
-
import { TableMap } from '@atlaskit/editor-tables/table-map';
|
|
3
2
|
import type { AnalyticsEventPayload, AnalyticsEventPayloadCallback, EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
4
3
|
import { HigherOrderCommand } from '@atlaskit/editor-common/types';
|
|
4
|
+
import { TableMap } from '@atlaskit/editor-tables/table-map';
|
|
5
5
|
export declare function getSelectedTableInfo(selection: Selection): {
|
|
6
6
|
table: import("prosemirror-utils").ContentNodeWithPos | undefined;
|
|
7
7
|
map: TableMap | undefined;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { NodeRange, NodeType } from 'prosemirror-model';
|
|
2
|
+
import { ReadonlyTransaction, Transaction } from 'prosemirror-state';
|
|
3
3
|
interface IsTableCollapsibleResult {
|
|
4
4
|
tableIsCollapsible: boolean;
|
|
5
5
|
range?: NodeRange;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Node as PmNode } from 'prosemirror-model';
|
|
2
|
-
import { Selection, Transaction
|
|
2
|
+
import { ReadonlyTransaction, Selection, Transaction } from 'prosemirror-state';
|
|
3
3
|
import { Decoration, DecorationSet } from 'prosemirror-view';
|
|
4
4
|
import { Cell, CellColumnPositioning, TableDecorations } from '../types';
|
|
5
5
|
export declare const findColumnControlSelectedDecoration: (decorationSet: DecorationSet) => Decoration[];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Direction } from '@atlaskit/editor-tables/types';
|
|
2
|
-
import { Command } from '@atlaskit/editor-common/types';
|
|
3
1
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
2
|
+
import { Command } from '@atlaskit/editor-common/types';
|
|
3
|
+
import { Direction } from '@atlaskit/editor-tables/types';
|
|
4
4
|
export declare const goToNextCell: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined | null) => (direction: Direction) => Command;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Transaction } from 'prosemirror-state';
|
|
2
|
-
import { Command } from '@atlaskit/editor-common/types';
|
|
3
2
|
import { EditorView } from 'prosemirror-view';
|
|
3
|
+
import { Command } from '@atlaskit/editor-common/types';
|
|
4
4
|
import type { GetEditorContainerWidth } from '@atlaskit/editor-common/types';
|
|
5
5
|
export declare function addColumnAt(getEditorContainerWidth: GetEditorContainerWidth): (column: number, allowAddColumnCustomStep: boolean | undefined, view: EditorView | undefined) => (tr: Transaction) => Transaction;
|
|
6
6
|
export declare const addColumnBefore: (getEditorContainerWidth: GetEditorContainerWidth) => Command;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { Command } from '@atlaskit/editor-common/types';
|
|
2
1
|
import { EditorSelectionAPI } from '@atlaskit/editor-common/selection';
|
|
2
|
+
import type { Command } from '@atlaskit/editor-common/types';
|
|
3
3
|
export declare enum TableSelectionDirection {
|
|
4
4
|
TopToBottom = "TopToBottom",
|
|
5
5
|
BottomToTop = "BottomToTop"
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { Command } from '@atlaskit/editor-common/types';
|
|
2
1
|
import { TableSortOrder as SortOrder } from '@atlaskit/adf-schema/steps';
|
|
2
|
+
import { Command } from '@atlaskit/editor-common/types';
|
|
3
3
|
export declare const sortByColumn: (columnIndex: number, order?: SortOrder) => Command;
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import type { Command } from '@atlaskit/editor-common/types';
|
|
1
|
+
import { TableSortOrder as SortOrder } from '@atlaskit/adf-schema/steps';
|
|
3
2
|
import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
4
3
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
4
|
+
import type { Command, GetEditorContainerWidth } from '@atlaskit/editor-common/types';
|
|
5
|
+
import { Rect } from '@atlaskit/editor-tables/table-map';
|
|
7
6
|
import { ResizeStateWithAnalytics } from './pm-plugins/table-resizing/utils';
|
|
8
|
-
import
|
|
7
|
+
import { InsertRowMethods, InsertRowOptions, RowInsertPosition } from './types';
|
|
9
8
|
export declare const emptyMultipleCellsWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined | null) => (inputMethod: INPUT_METHOD.CONTEXT_MENU | INPUT_METHOD.KEYBOARD | INPUT_METHOD.FLOATING_TB, targetCellPosition?: number) => Command;
|
|
10
9
|
export declare const mergeCellsWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | null | undefined) => (inputMethod: INPUT_METHOD.CONTEXT_MENU | INPUT_METHOD.FLOATING_TB) => Command;
|
|
11
10
|
export declare const splitCellWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined | null) => (inputMethod: INPUT_METHOD.CONTEXT_MENU | INPUT_METHOD.FLOATING_TB) => Command;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { EditorState, Transaction } from 'prosemirror-state';
|
|
2
2
|
import { EditorView } from 'prosemirror-view';
|
|
3
3
|
import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
|
|
4
|
-
import { ElementContentRects } from './types';
|
|
5
4
|
import type { GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
5
|
+
import { ElementContentRects } from './types';
|
|
6
6
|
export declare const handleBlur: (view: EditorView, event: Event) => boolean;
|
|
7
7
|
export declare const handleFocus: (view: EditorView, event: Event) => boolean;
|
|
8
8
|
export declare const handleClick: (view: EditorView, event: Event) => boolean;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ReadonlyTransaction, Transaction } from 'prosemirror-state';
|
|
2
2
|
import { TablePluginState } from './types';
|
|
3
3
|
export declare const handleDocOrSelectionChanged: (tr: Transaction | ReadonlyTransaction, pluginState: TablePluginState) => TablePluginState;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import type { Command } from '@atlaskit/editor-common/types';
|
|
2
1
|
import { AnalyticsEventPayload } from '@atlaskit/editor-common/analytics';
|
|
3
2
|
import type { EditorSelectionAPI } from '@atlaskit/editor-common/selection';
|
|
4
|
-
import {
|
|
5
|
-
import type { GetEditorFeatureFlags, NextEditorPlugin } from '@atlaskit/editor-common/types';
|
|
3
|
+
import type { Command, GetEditorFeatureFlags, NextEditorPlugin } from '@atlaskit/editor-common/types';
|
|
6
4
|
import type { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
7
5
|
import type { contentInsertionPlugin } from '@atlaskit/editor-plugin-content-insertion';
|
|
8
|
-
import type { widthPlugin } from '@atlaskit/editor-plugin-width';
|
|
9
6
|
import type { guidelinePlugin } from '@atlaskit/editor-plugin-guideline';
|
|
7
|
+
import type { widthPlugin } from '@atlaskit/editor-plugin-width';
|
|
8
|
+
import { PluginConfig } from './types';
|
|
10
9
|
interface TablePluginOptions {
|
|
11
10
|
tableOptions: PluginConfig;
|
|
11
|
+
tableResizingEnabled?: boolean;
|
|
12
12
|
breakoutEnabled?: boolean;
|
|
13
13
|
allowContextualMenu?: boolean;
|
|
14
14
|
fullWidthEnabled?: boolean;
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Node as PmNode } from 'prosemirror-model';
|
|
3
3
|
import { EditorView } from 'prosemirror-view';
|
|
4
|
-
import type {
|
|
4
|
+
import type { TableColumnOrdering } from '@atlaskit/adf-schema/steps';
|
|
5
|
+
import type { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
|
|
6
|
+
import type { EditorContainerWidth, GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
5
7
|
import { RowStickyState, StickyPluginState } from '../pm-plugins/sticky-headers';
|
|
6
|
-
import type { GetEditorFeatureFlags } from '@atlaskit/editor-common/types';
|
|
7
8
|
import { PluginInjectionAPI, ShadowEvent } from '../types';
|
|
8
|
-
import type { TableColumnOrdering } from '@atlaskit/adf-schema/steps';
|
|
9
9
|
import type { TableOptions } from './types';
|
|
10
|
-
import type { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
|
|
11
10
|
export interface ComponentProps {
|
|
12
11
|
view: EditorView;
|
|
13
12
|
getNode: () => PmNode;
|
|
@@ -29,7 +29,7 @@ type TableContainerProps = {
|
|
|
29
29
|
node: PMNode;
|
|
30
30
|
className: string;
|
|
31
31
|
containerWidth: EditorContainerWidth;
|
|
32
|
-
|
|
32
|
+
isTableResizingEnabled: boolean | undefined;
|
|
33
33
|
isBreakoutEnabled: boolean | undefined;
|
|
34
34
|
editorView: EditorView;
|
|
35
35
|
getPos: () => number | undefined;
|
|
@@ -37,5 +37,5 @@ type TableContainerProps = {
|
|
|
37
37
|
isNested: boolean;
|
|
38
38
|
pluginInjectionApi?: PluginInjectionAPI;
|
|
39
39
|
};
|
|
40
|
-
export declare const TableContainer: ({ children, node, className, containerWidth: { lineLength, width: editorWidth },
|
|
40
|
+
export declare const TableContainer: ({ children, node, className, containerWidth: { lineLength, width: editorWidth }, isTableResizingEnabled, isBreakoutEnabled, editorView, getPos, tableRef, isNested, pluginInjectionApi, }: PropsWithChildren<TableContainerProps>) => JSX.Element;
|
|
41
41
|
export {};
|