@atlaskit/editor-plugin-table 1.1.1 → 1.1.3
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 +18 -0
- package/dist/cjs/index.js +0 -2
- package/dist/cjs/plugins/table/commands/clear.js +4 -16
- package/dist/cjs/plugins/table/commands/collapse.js +0 -6
- package/dist/cjs/plugins/table/commands/go-to-next-cell.js +7 -18
- package/dist/cjs/plugins/table/commands/hover.js +7 -37
- package/dist/cjs/plugins/table/commands/index.js +0 -8
- package/dist/cjs/plugins/table/commands/insert.js +17 -56
- package/dist/cjs/plugins/table/commands/misc.js +36 -132
- package/dist/cjs/plugins/table/commands/referentiality.js +0 -4
- package/dist/cjs/plugins/table/commands/selection.js +21 -87
- package/dist/cjs/plugins/table/commands/sort.js +2 -23
- package/dist/cjs/plugins/table/commands/split-cell.js +3 -11
- package/dist/cjs/plugins/table/commands/toggle.js +8 -34
- package/dist/cjs/plugins/table/commands-with-analytics.js +50 -139
- package/dist/cjs/plugins/table/create-plugin-config.js +0 -6
- package/dist/cjs/plugins/table/event-handlers.js +58 -160
- package/dist/cjs/plugins/table/handlers.js +10 -39
- package/dist/cjs/plugins/table/index.js +47 -91
- package/dist/cjs/plugins/table/nodeviews/OverflowShadowsObserver.js +8 -41
- package/dist/cjs/plugins/table/nodeviews/TableComponent.js +95 -191
- package/dist/cjs/plugins/table/nodeviews/table.js +12 -70
- package/dist/cjs/plugins/table/nodeviews/tableCell.js +15 -39
- package/dist/cjs/plugins/table/nodeviews/update-overflow-shadows.js +3 -15
- package/dist/cjs/plugins/table/pm-plugins/decorations/plugin.js +0 -18
- package/dist/cjs/plugins/table/pm-plugins/decorations/utils/column-controls.js +8 -27
- package/dist/cjs/plugins/table/pm-plugins/decorations/utils/column-resizing.js +8 -20
- package/dist/cjs/plugins/table/pm-plugins/decorations/utils/compose-decorations.js +1 -3
- package/dist/cjs/plugins/table/pm-plugins/decorations/utils/index.js +0 -3
- package/dist/cjs/plugins/table/pm-plugins/keymap.js +2 -15
- package/dist/cjs/plugins/table/pm-plugins/main.js +20 -72
- package/dist/cjs/plugins/table/pm-plugins/plugin-factory.js +25 -42
- package/dist/cjs/plugins/table/pm-plugins/plugin-key.js +0 -2
- package/dist/cjs/plugins/table/pm-plugins/safari-delayed-dom-selection-syncing-workaround.js +8 -8
- package/dist/cjs/plugins/table/pm-plugins/safari-delete-composition-text-issue-workaround.js +4 -23
- package/dist/cjs/plugins/table/pm-plugins/sticky-headers/commands.js +0 -5
- package/dist/cjs/plugins/table/pm-plugins/sticky-headers/index.js +0 -5
- package/dist/cjs/plugins/table/pm-plugins/sticky-headers/nodeviews/dom.js +4 -13
- package/dist/cjs/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.js +56 -138
- package/dist/cjs/plugins/table/pm-plugins/sticky-headers/plugin-key.js +0 -2
- package/dist/cjs/plugins/table/pm-plugins/sticky-headers/plugin-state.js +15 -30
- package/dist/cjs/plugins/table/pm-plugins/sticky-headers/plugin.js +0 -6
- package/dist/cjs/plugins/table/pm-plugins/sticky-headers/util.js +0 -5
- package/dist/cjs/plugins/table/pm-plugins/table-local-id.js +13 -44
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/commands.js +18 -43
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/event-handlers.js +20 -52
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/index.js +0 -4
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/plugin-factory.js +0 -10
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/plugin-key.js +0 -2
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/plugin.js +5 -19
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/reducer.js +0 -10
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/colgroup.js +16 -15
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/column-state.js +8 -28
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/content-width.js +3 -23
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/dom.js +4 -46
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/index.js +0 -9
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/misc.js +51 -40
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/resize-column.js +1 -4
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/resize-logic.js +17 -73
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/resize-state.js +34 -82
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/scale-table.js +12 -36
- package/dist/cjs/plugins/table/pm-plugins/table-resizing/utils/unit-to-number.js +0 -2
- package/dist/cjs/plugins/table/pm-plugins/table-selection-keymap.js +0 -5
- package/dist/cjs/plugins/table/reducer.js +0 -24
- package/dist/cjs/plugins/table/toolbar.js +14 -94
- package/dist/cjs/plugins/table/transforms/column-width.js +58 -49
- package/dist/cjs/plugins/table/transforms/delete-columns.js +11 -76
- package/dist/cjs/plugins/table/transforms/delete-rows.js +4 -42
- package/dist/cjs/plugins/table/transforms/fix-tables.js +24 -61
- package/dist/cjs/plugins/table/transforms/index.js +0 -7
- package/dist/cjs/plugins/table/transforms/merge.js +14 -90
- package/dist/cjs/plugins/table/transforms/metadata.js +0 -5
- package/dist/cjs/plugins/table/transforms/replace-table.js +2 -13
- package/dist/cjs/plugins/table/transforms/split.js +18 -32
- package/dist/cjs/plugins/table/types.js +0 -11
- package/dist/cjs/plugins/table/ui/FloatingContextualButton/index.js +10 -51
- package/dist/cjs/plugins/table/ui/FloatingContextualButton/styles.js +0 -12
- package/dist/cjs/plugins/table/ui/FloatingContextualMenu/ContextualMenu.js +46 -145
- package/dist/cjs/plugins/table/ui/FloatingContextualMenu/index.js +12 -35
- package/dist/cjs/plugins/table/ui/FloatingContextualMenu/styles.js +0 -11
- package/dist/cjs/plugins/table/ui/FloatingDeleteButton/DeleteButton.js +5 -12
- package/dist/cjs/plugins/table/ui/FloatingDeleteButton/getPopUpOptions.js +3 -16
- package/dist/cjs/plugins/table/ui/FloatingDeleteButton/index.js +19 -89
- package/dist/cjs/plugins/table/ui/FloatingInsertButton/InsertButton.js +6 -31
- package/dist/cjs/plugins/table/ui/FloatingInsertButton/getPopupOptions.js +5 -22
- package/dist/cjs/plugins/table/ui/FloatingInsertButton/index.js +25 -80
- package/dist/cjs/plugins/table/ui/LayoutButton/index.js +16 -64
- package/dist/cjs/plugins/table/ui/TableFloatingControls/CornerControls/index.js +14 -47
- package/dist/cjs/plugins/table/ui/TableFloatingControls/NumberColumn/index.js +20 -48
- package/dist/cjs/plugins/table/ui/TableFloatingControls/RowControls/index.js +10 -43
- package/dist/cjs/plugins/table/ui/TableFloatingControls/index.js +33 -74
- package/dist/cjs/plugins/table/ui/common-styles.js +10 -22
- package/dist/cjs/plugins/table/ui/consts.js +3 -8
- package/dist/cjs/plugins/table/ui/messages.js +0 -3
- package/dist/cjs/plugins/table/ui/ui-styles.js +0 -32
- package/dist/cjs/plugins/table/utils/analytics.js +4 -19
- package/dist/cjs/plugins/table/utils/collapse.js +4 -21
- package/dist/cjs/plugins/table/utils/column-controls.js +25 -61
- package/dist/cjs/plugins/table/utils/decoration.js +46 -114
- package/dist/cjs/plugins/table/utils/dom.js +4 -51
- package/dist/cjs/plugins/table/utils/get-allow-add-column-custom-step.js +0 -2
- package/dist/cjs/plugins/table/utils/index.js +0 -10
- package/dist/cjs/plugins/table/utils/nodes.js +5 -48
- package/dist/cjs/plugins/table/utils/paste.js +22 -47
- package/dist/cjs/plugins/table/utils/row-controls.js +6 -67
- package/dist/cjs/plugins/table/utils/selection.js +3 -36
- package/dist/cjs/plugins/table/utils/table.js +0 -11
- package/dist/cjs/plugins/table/utils/update-plugin-state-decorations.js +0 -4
- package/dist/cjs/plugins/table-plugin.js +0 -3
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/plugins/table/commands/clear.js +3 -8
- package/dist/es2019/plugins/table/commands/collapse.js +0 -3
- package/dist/es2019/plugins/table/commands/go-to-next-cell.js +4 -7
- package/dist/es2019/plugins/table/commands/hover.js +7 -17
- package/dist/es2019/plugins/table/commands/insert.js +16 -36
- package/dist/es2019/plugins/table/commands/misc.js +37 -67
- package/dist/es2019/plugins/table/commands/selection.js +7 -62
- package/dist/es2019/plugins/table/commands/sort.js +0 -12
- package/dist/es2019/plugins/table/commands/split-cell.js +0 -4
- package/dist/es2019/plugins/table/commands/toggle.js +13 -15
- package/dist/es2019/plugins/table/commands-with-analytics.js +4 -14
- package/dist/es2019/plugins/table/event-handlers.js +14 -62
- package/dist/es2019/plugins/table/handlers.js +16 -26
- package/dist/es2019/plugins/table/index.js +12 -25
- package/dist/es2019/plugins/table/nodeviews/OverflowShadowsObserver.js +8 -40
- package/dist/es2019/plugins/table/nodeviews/TableComponent.js +40 -103
- package/dist/es2019/plugins/table/nodeviews/table.js +3 -33
- package/dist/es2019/plugins/table/nodeviews/tableCell.js +7 -16
- package/dist/es2019/plugins/table/nodeviews/update-overflow-shadows.js +3 -10
- package/dist/es2019/plugins/table/pm-plugins/decorations/plugin.js +0 -5
- package/dist/es2019/plugins/table/pm-plugins/decorations/utils/column-controls.js +4 -13
- package/dist/es2019/plugins/table/pm-plugins/decorations/utils/column-resizing.js +0 -3
- package/dist/es2019/plugins/table/pm-plugins/keymap.js +2 -3
- package/dist/es2019/plugins/table/pm-plugins/main.js +19 -43
- package/dist/es2019/plugins/table/pm-plugins/plugin-factory.js +2 -6
- package/dist/es2019/plugins/table/pm-plugins/safari-delayed-dom-selection-syncing-workaround.js +8 -3
- package/dist/es2019/plugins/table/pm-plugins/safari-delete-composition-text-issue-workaround.js +0 -12
- package/dist/es2019/plugins/table/pm-plugins/sticky-headers/nodeviews/dom.js +4 -9
- package/dist/es2019/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.js +55 -130
- package/dist/es2019/plugins/table/pm-plugins/sticky-headers/plugin-state.js +2 -9
- package/dist/es2019/plugins/table/pm-plugins/sticky-headers/util.js +0 -3
- package/dist/es2019/plugins/table/pm-plugins/table-local-id.js +20 -39
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/commands.js +14 -17
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/event-handlers.js +13 -27
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/plugin-factory.js +2 -4
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/plugin.js +2 -5
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/reducer.js +8 -8
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/colgroup.js +14 -3
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/column-state.js +8 -11
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/content-width.js +4 -21
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/dom.js +3 -22
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/misc.js +46 -21
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/resize-logic.js +31 -61
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/resize-state.js +54 -51
- package/dist/es2019/plugins/table/pm-plugins/table-resizing/utils/scale-table.js +9 -14
- package/dist/es2019/plugins/table/reducer.js +26 -30
- package/dist/es2019/plugins/table/toolbar.js +5 -48
- package/dist/es2019/plugins/table/transforms/column-width.js +60 -32
- package/dist/es2019/plugins/table/transforms/delete-columns.js +17 -58
- package/dist/es2019/plugins/table/transforms/delete-rows.js +8 -25
- package/dist/es2019/plugins/table/transforms/fix-tables.js +25 -42
- package/dist/es2019/plugins/table/transforms/merge.js +22 -70
- package/dist/es2019/plugins/table/transforms/metadata.js +3 -2
- package/dist/es2019/plugins/table/transforms/replace-table.js +0 -2
- package/dist/es2019/plugins/table/transforms/split.js +16 -19
- package/dist/es2019/plugins/table/types.js +2 -4
- package/dist/es2019/plugins/table/ui/FloatingContextualButton/index.js +2 -16
- package/dist/es2019/plugins/table/ui/FloatingContextualMenu/ContextualMenu.js +8 -54
- package/dist/es2019/plugins/table/ui/FloatingContextualMenu/index.js +4 -13
- package/dist/es2019/plugins/table/ui/FloatingDeleteButton/DeleteButton.js +0 -2
- package/dist/es2019/plugins/table/ui/FloatingDeleteButton/getPopUpOptions.js +2 -11
- package/dist/es2019/plugins/table/ui/FloatingDeleteButton/index.js +13 -49
- package/dist/es2019/plugins/table/ui/FloatingInsertButton/InsertButton.js +0 -8
- package/dist/es2019/plugins/table/ui/FloatingInsertButton/getPopupOptions.js +16 -24
- package/dist/es2019/plugins/table/ui/FloatingInsertButton/index.js +3 -31
- package/dist/es2019/plugins/table/ui/LayoutButton/index.js +2 -29
- package/dist/es2019/plugins/table/ui/TableFloatingControls/CornerControls/index.js +0 -12
- package/dist/es2019/plugins/table/ui/TableFloatingControls/NumberColumn/index.js +6 -12
- package/dist/es2019/plugins/table/ui/TableFloatingControls/RowControls/index.js +0 -9
- package/dist/es2019/plugins/table/ui/TableFloatingControls/index.js +4 -19
- package/dist/es2019/plugins/table/ui/common-styles.js +11 -7
- package/dist/es2019/plugins/table/ui/consts.js +4 -3
- package/dist/es2019/plugins/table/ui/ui-styles.js +0 -10
- package/dist/es2019/plugins/table/utils/analytics.js +0 -8
- package/dist/es2019/plugins/table/utils/collapse.js +3 -14
- package/dist/es2019/plugins/table/utils/column-controls.js +22 -37
- package/dist/es2019/plugins/table/utils/decoration.js +13 -51
- package/dist/es2019/plugins/table/utils/dom.js +3 -19
- package/dist/es2019/plugins/table/utils/nodes.js +2 -15
- package/dist/es2019/plugins/table/utils/paste.js +17 -22
- package/dist/es2019/plugins/table/utils/row-controls.js +12 -45
- package/dist/es2019/plugins/table/utils/selection.js +0 -21
- package/dist/es2019/plugins/table/utils/table.js +0 -2
- package/dist/es2019/version.json +1 -1
- package/dist/esm/plugins/table/commands/clear.js +3 -8
- package/dist/esm/plugins/table/commands/collapse.js +0 -3
- package/dist/esm/plugins/table/commands/go-to-next-cell.js +6 -9
- package/dist/esm/plugins/table/commands/hover.js +8 -18
- package/dist/esm/plugins/table/commands/insert.js +16 -36
- package/dist/esm/plugins/table/commands/misc.js +39 -78
- package/dist/esm/plugins/table/commands/selection.js +21 -78
- package/dist/esm/plugins/table/commands/sort.js +2 -14
- package/dist/esm/plugins/table/commands/split-cell.js +3 -8
- package/dist/esm/plugins/table/commands/toggle.js +11 -20
- package/dist/esm/plugins/table/commands-with-analytics.js +50 -85
- package/dist/esm/plugins/table/create-plugin-config.js +0 -3
- package/dist/esm/plugins/table/event-handlers.js +58 -123
- package/dist/esm/plugins/table/handlers.js +11 -29
- package/dist/esm/plugins/table/index.js +47 -60
- package/dist/esm/plugins/table/nodeviews/OverflowShadowsObserver.js +8 -44
- package/dist/esm/plugins/table/nodeviews/TableComponent.js +95 -184
- package/dist/esm/plugins/table/nodeviews/table.js +12 -52
- package/dist/esm/plugins/table/nodeviews/tableCell.js +15 -33
- package/dist/esm/plugins/table/nodeviews/update-overflow-shadows.js +3 -10
- package/dist/esm/plugins/table/pm-plugins/decorations/plugin.js +0 -5
- package/dist/esm/plugins/table/pm-plugins/decorations/utils/column-controls.js +8 -19
- package/dist/esm/plugins/table/pm-plugins/decorations/utils/column-resizing.js +8 -13
- package/dist/esm/plugins/table/pm-plugins/decorations/utils/compose-decorations.js +1 -1
- package/dist/esm/plugins/table/pm-plugins/keymap.js +2 -3
- package/dist/esm/plugins/table/pm-plugins/main.js +20 -47
- package/dist/esm/plugins/table/pm-plugins/plugin-factory.js +25 -37
- package/dist/esm/plugins/table/pm-plugins/safari-delayed-dom-selection-syncing-workaround.js +8 -3
- package/dist/esm/plugins/table/pm-plugins/safari-delete-composition-text-issue-workaround.js +3 -15
- package/dist/esm/plugins/table/pm-plugins/sticky-headers/nodeviews/dom.js +4 -9
- package/dist/esm/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.js +58 -147
- package/dist/esm/plugins/table/pm-plugins/sticky-headers/plugin-state.js +15 -27
- package/dist/esm/plugins/table/pm-plugins/sticky-headers/util.js +0 -3
- package/dist/esm/plugins/table/pm-plugins/table-local-id.js +14 -37
- package/dist/esm/plugins/table/pm-plugins/table-resizing/commands.js +18 -25
- package/dist/esm/plugins/table/pm-plugins/table-resizing/event-handlers.js +20 -36
- package/dist/esm/plugins/table/pm-plugins/table-resizing/plugin-factory.js +0 -6
- package/dist/esm/plugins/table/pm-plugins/table-resizing/plugin.js +5 -8
- package/dist/esm/plugins/table/pm-plugins/table-resizing/reducer.js +0 -7
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/colgroup.js +14 -3
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/column-state.js +8 -12
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/content-width.js +5 -22
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/dom.js +4 -23
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/misc.js +49 -26
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/resize-logic.js +17 -62
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/resize-state.js +34 -55
- package/dist/esm/plugins/table/pm-plugins/table-resizing/utils/scale-table.js +12 -24
- package/dist/esm/plugins/table/reducer.js +0 -20
- package/dist/esm/plugins/table/toolbar.js +13 -63
- package/dist/esm/plugins/table/transforms/column-width.js +58 -36
- package/dist/esm/plugins/table/transforms/delete-columns.js +11 -62
- package/dist/esm/plugins/table/transforms/delete-rows.js +4 -30
- package/dist/esm/plugins/table/transforms/fix-tables.js +24 -49
- package/dist/esm/plugins/table/transforms/merge.js +16 -75
- package/dist/esm/plugins/table/transforms/metadata.js +3 -2
- package/dist/esm/plugins/table/transforms/replace-table.js +2 -6
- package/dist/esm/plugins/table/transforms/split.js +18 -29
- package/dist/esm/plugins/table/types.js +0 -6
- package/dist/esm/plugins/table/ui/FloatingContextualButton/index.js +10 -31
- package/dist/esm/plugins/table/ui/FloatingContextualButton/styles.js +0 -2
- package/dist/esm/plugins/table/ui/FloatingContextualMenu/ContextualMenu.js +46 -126
- package/dist/esm/plugins/table/ui/FloatingContextualMenu/index.js +13 -24
- package/dist/esm/plugins/table/ui/FloatingContextualMenu/styles.js +0 -2
- package/dist/esm/plugins/table/ui/FloatingDeleteButton/DeleteButton.js +5 -7
- package/dist/esm/plugins/table/ui/FloatingDeleteButton/getPopUpOptions.js +3 -13
- package/dist/esm/plugins/table/ui/FloatingDeleteButton/index.js +19 -68
- package/dist/esm/plugins/table/ui/FloatingInsertButton/InsertButton.js +6 -14
- package/dist/esm/plugins/table/ui/FloatingInsertButton/getPopupOptions.js +5 -18
- package/dist/esm/plugins/table/ui/FloatingInsertButton/index.js +25 -57
- package/dist/esm/plugins/table/ui/LayoutButton/index.js +16 -47
- package/dist/esm/plugins/table/ui/TableFloatingControls/CornerControls/index.js +14 -35
- package/dist/esm/plugins/table/ui/TableFloatingControls/NumberColumn/index.js +20 -38
- package/dist/esm/plugins/table/ui/TableFloatingControls/RowControls/index.js +10 -29
- package/dist/esm/plugins/table/ui/TableFloatingControls/index.js +33 -62
- package/dist/esm/plugins/table/ui/common-styles.js +9 -10
- package/dist/esm/plugins/table/ui/consts.js +4 -3
- package/dist/esm/plugins/table/ui/ui-styles.js +0 -12
- package/dist/esm/plugins/table/utils/analytics.js +4 -13
- package/dist/esm/plugins/table/utils/collapse.js +4 -15
- package/dist/esm/plugins/table/utils/column-controls.js +25 -41
- package/dist/esm/plugins/table/utils/decoration.js +46 -88
- package/dist/esm/plugins/table/utils/dom.js +4 -20
- package/dist/esm/plugins/table/utils/nodes.js +5 -18
- package/dist/esm/plugins/table/utils/paste.js +24 -29
- package/dist/esm/plugins/table/utils/row-controls.js +6 -46
- package/dist/esm/plugins/table/utils/selection.js +3 -26
- package/dist/esm/plugins/table/utils/table.js +0 -2
- package/dist/esm/version.json +1 -1
- package/dist/types/plugins/table/pm-plugins/table-resizing/utils/colgroup.d.ts +7 -0
- package/dist/types/plugins/table/pm-plugins/table-resizing/utils/misc.d.ts +2 -1
- package/dist/types/plugins/table/ui/common-styles.d.ts +1 -0
- package/package.json +8 -6
- package/src/__tests__/integration/__fixtures__/empty-layout.ts +35 -0
- package/src/__tests__/integration/__fixtures__/nested-in-expand.ts +129 -0
- package/src/__tests__/integration/horizontal-scroll.ts +489 -0
- package/src/__tests__/unit/commands/insert.ts +3 -3
- package/src/__tests__/unit/keymap.ts +3 -1
- package/src/__tests__/unit/pm-plugins/table-resizing/colgroup.ts +38 -0
- package/src/__tests__/unit/pm-plugins/table-resizing/event-handlers.ts +5 -2
- package/src/__tests__/visual-regression/__image_snapshots__/cell-options-menu-ts-table-cell-options-menu-delete-column-menu-item-visual-hints-should-be-added-to-the-table-column-on-hover-1-snap.png +2 -2
- package/src/__tests__/visual-regression/__image_snapshots__/cell-options-menu-ts-table-cell-options-menu-delete-row-menu-item-visual-hints-should-be-added-to-the-table-row-on-hover-1-snap.png +2 -2
- package/src/__tests__/visual-regression/__image_snapshots__/sticky-header-ts-snapshot-test-table-sticky-header-should-align-with-table-cell-when-active-2-snap.png +2 -2
- package/src/__tests__/visual-regression/sticky-header.ts +2 -1
- package/src/plugins/table/nodeviews/TableComponent.tsx +16 -3
- package/src/plugins/table/pm-plugins/table-resizing/commands.ts +6 -2
- package/src/plugins/table/pm-plugins/table-resizing/event-handlers.ts +9 -1
- package/src/plugins/table/pm-plugins/table-resizing/utils/colgroup.ts +19 -1
- package/src/plugins/table/pm-plugins/table-resizing/utils/misc.ts +57 -5
- package/src/plugins/table/pm-plugins/table-resizing/utils/resize-logic.ts +2 -2
- package/src/plugins/table/transforms/column-width.ts +60 -6
- package/src/plugins/table/ui/common-styles.ts +5 -2
|
@@ -28,32 +28,27 @@ import FloatingInsertButton from './ui/FloatingInsertButton';
|
|
|
28
28
|
import LayoutButton from './ui/LayoutButton';
|
|
29
29
|
import { isLayoutSupported } from './utils';
|
|
30
30
|
import { ErrorBoundary } from '@atlaskit/editor-common/error-boundary';
|
|
31
|
-
|
|
32
31
|
var defaultGetEditorFeatureFlags = function defaultGetEditorFeatureFlags() {
|
|
33
32
|
return {};
|
|
34
33
|
};
|
|
35
|
-
|
|
36
34
|
var tablesPlugin = function tablesPlugin(options) {
|
|
37
35
|
var editorViewRef = {
|
|
38
36
|
current: null
|
|
39
37
|
};
|
|
40
|
-
|
|
41
38
|
var defaultGetEditorContainerWidth = function defaultGetEditorContainerWidth() {
|
|
42
39
|
if (!editorViewRef.current) {
|
|
43
40
|
var _document, _document$body;
|
|
44
|
-
|
|
45
41
|
return {
|
|
46
42
|
width: ((_document = document) === null || _document === void 0 ? void 0 : (_document$body = _document.body) === null || _document$body === void 0 ? void 0 : _document$body.offsetWidth) || 500
|
|
47
43
|
};
|
|
48
44
|
}
|
|
45
|
+
var state = editorViewRef.current.state;
|
|
49
46
|
|
|
50
|
-
|
|
47
|
+
// TODO: ED-15663
|
|
51
48
|
// Please, do not copy or use this kind of code below
|
|
52
49
|
// @ts-ignore
|
|
53
|
-
|
|
54
50
|
return state['widthPlugin$'];
|
|
55
51
|
};
|
|
56
|
-
|
|
57
52
|
return {
|
|
58
53
|
name: 'table',
|
|
59
54
|
nodes: function nodes() {
|
|
@@ -76,34 +71,29 @@ var tablesPlugin = function tablesPlugin(options) {
|
|
|
76
71
|
name: 'table',
|
|
77
72
|
plugin: function plugin(_ref) {
|
|
78
73
|
var dispatchAnalyticsEvent = _ref.dispatchAnalyticsEvent,
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
74
|
+
dispatch = _ref.dispatch,
|
|
75
|
+
portalProviderAPI = _ref.portalProviderAPI,
|
|
76
|
+
eventDispatcher = _ref.eventDispatcher;
|
|
83
77
|
var _ref2 = options || {},
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
78
|
+
fullWidthEnabled = _ref2.fullWidthEnabled,
|
|
79
|
+
wasFullWidthEnabled = _ref2.wasFullWidthEnabled,
|
|
80
|
+
breakoutEnabled = _ref2.breakoutEnabled,
|
|
81
|
+
tableOptions = _ref2.tableOptions,
|
|
82
|
+
editorAnalyticsAPI = _ref2.editorAnalyticsAPI,
|
|
83
|
+
getEditorFeatureFlags = _ref2.getEditorFeatureFlags;
|
|
91
84
|
return createPlugin(dispatchAnalyticsEvent, dispatch, portalProviderAPI, eventDispatcher, pluginConfig(tableOptions), defaultGetEditorContainerWidth, getEditorFeatureFlags || defaultGetEditorFeatureFlags, breakoutEnabled, fullWidthEnabled, wasFullWidthEnabled, editorAnalyticsAPI);
|
|
92
85
|
}
|
|
93
86
|
}, {
|
|
94
87
|
name: 'tablePMColResizing',
|
|
95
88
|
plugin: function plugin(_ref3) {
|
|
96
89
|
var dispatch = _ref3.dispatch;
|
|
97
|
-
|
|
98
90
|
var _ref4 = options || {},
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
91
|
+
fullWidthEnabled = _ref4.fullWidthEnabled,
|
|
92
|
+
tableOptions = _ref4.tableOptions,
|
|
93
|
+
editorAnalyticsAPI = _ref4.editorAnalyticsAPI,
|
|
94
|
+
getEditorFeatureFlags = _ref4.getEditorFeatureFlags;
|
|
104
95
|
var _pluginConfig = pluginConfig(tableOptions),
|
|
105
|
-
|
|
106
|
-
|
|
96
|
+
allowColumnResizing = _pluginConfig.allowColumnResizing;
|
|
107
97
|
return allowColumnResizing ? createFlexiResizingPlugin(dispatch, {
|
|
108
98
|
lastColumnResizable: !fullWidthEnabled
|
|
109
99
|
}, defaultGetEditorContainerWidth, getEditorFeatureFlags || defaultGetEditorFeatureFlags, editorAnalyticsAPI) : undefined;
|
|
@@ -113,7 +103,8 @@ var tablesPlugin = function tablesPlugin(options) {
|
|
|
113
103
|
plugin: function plugin() {
|
|
114
104
|
return createDecorationsPlugin();
|
|
115
105
|
}
|
|
116
|
-
},
|
|
106
|
+
},
|
|
107
|
+
// Needs to be lower priority than editor-tables.tableEditing
|
|
117
108
|
// plugin as it is currently swallowing backspace events inside tables
|
|
118
109
|
{
|
|
119
110
|
name: 'tableKeymap',
|
|
@@ -131,10 +122,9 @@ var tablesPlugin = function tablesPlugin(options) {
|
|
|
131
122
|
return tableEditing({
|
|
132
123
|
reportFixedTable: function reportFixedTable(_ref5) {
|
|
133
124
|
var _options$editorAnalyt;
|
|
134
|
-
|
|
135
125
|
var state = _ref5.state,
|
|
136
|
-
|
|
137
|
-
|
|
126
|
+
tr = _ref5.tr,
|
|
127
|
+
reason = _ref5.reason;
|
|
138
128
|
options === null || options === void 0 ? void 0 : (_options$editorAnalyt = options.editorAnalyticsAPI) === null || _options$editorAnalyt === void 0 ? void 0 : _options$editorAnalyt.attachAnalyticsEvent({
|
|
139
129
|
action: TABLE_ACTION.FIXED,
|
|
140
130
|
actionSubject: ACTION_SUBJECT.TABLE,
|
|
@@ -151,7 +141,7 @@ var tablesPlugin = function tablesPlugin(options) {
|
|
|
151
141
|
name: 'tableStickyHeaders',
|
|
152
142
|
plugin: function plugin(_ref6) {
|
|
153
143
|
var dispatch = _ref6.dispatch,
|
|
154
|
-
|
|
144
|
+
eventDispatcher = _ref6.eventDispatcher;
|
|
155
145
|
return options && options.tableOptions.stickyHeaders ? createStickyHeadersPlugin(dispatch, eventDispatcher, function () {
|
|
156
146
|
return [];
|
|
157
147
|
}, (options === null || options === void 0 ? void 0 : options.getEditorFeatureFlags) || defaultGetEditorFeatureFlags) : undefined;
|
|
@@ -176,12 +166,14 @@ var tablesPlugin = function tablesPlugin(options) {
|
|
|
176
166
|
}
|
|
177
167
|
});
|
|
178
168
|
}
|
|
179
|
-
}];
|
|
169
|
+
}];
|
|
170
|
+
|
|
171
|
+
// workaround for prosemirrors delayed dom selection syncing during pointer drag
|
|
180
172
|
// causing issues with table selections in Safari
|
|
181
173
|
// https://github.com/ProseMirror/prosemirror-view/commit/885258b80551ac87b81601d3ed25f552aeb22293
|
|
174
|
+
|
|
182
175
|
// NOTE: this workaround can be removed when next upgrading prosemirror as the issue will be fixed
|
|
183
176
|
// https://github.com/ProseMirror/prosemirror-view/pull/116
|
|
184
|
-
|
|
185
177
|
if (browser.safari) {
|
|
186
178
|
plugins.push({
|
|
187
179
|
name: 'tableSafariDelayedDomSelectionSyncingWorkaround',
|
|
@@ -189,10 +181,10 @@ var tablesPlugin = function tablesPlugin(options) {
|
|
|
189
181
|
return createTableSafariDelayedDomSelectionSyncingWorkaroundPlugin();
|
|
190
182
|
}
|
|
191
183
|
});
|
|
192
|
-
}
|
|
193
|
-
// https://github.com/ProseMirror/prosemirror/issues/934
|
|
194
|
-
|
|
184
|
+
}
|
|
195
185
|
|
|
186
|
+
// Workaround for table element breaking issue caused by composition event with an inputType of deleteCompositionText.
|
|
187
|
+
// https://github.com/ProseMirror/prosemirror/issues/934
|
|
196
188
|
if (browser.safari) {
|
|
197
189
|
plugins.push({
|
|
198
190
|
name: 'tableSafariDeleteCompositionTextIssueWorkaround',
|
|
@@ -201,15 +193,14 @@ var tablesPlugin = function tablesPlugin(options) {
|
|
|
201
193
|
}
|
|
202
194
|
});
|
|
203
195
|
}
|
|
204
|
-
|
|
205
196
|
return plugins;
|
|
206
197
|
},
|
|
207
198
|
contentComponent: function contentComponent(_ref8) {
|
|
208
199
|
var editorView = _ref8.editorView,
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
200
|
+
popupsMountPoint = _ref8.popupsMountPoint,
|
|
201
|
+
popupsBoundariesElement = _ref8.popupsBoundariesElement,
|
|
202
|
+
popupsScrollableElement = _ref8.popupsScrollableElement,
|
|
203
|
+
dispatchAnalyticsEvent = _ref8.dispatchAnalyticsEvent;
|
|
213
204
|
return /*#__PURE__*/React.createElement(ErrorBoundary, {
|
|
214
205
|
component: ACTION_SUBJECT.TABLES_PLUGIN,
|
|
215
206
|
dispatchAnalyticsEvent: dispatchAnalyticsEvent,
|
|
@@ -222,23 +213,23 @@ var tablesPlugin = function tablesPlugin(options) {
|
|
|
222
213
|
},
|
|
223
214
|
render: function render(_ref9) {
|
|
224
215
|
var resizingPluginState = _ref9.tableResizingPluginState,
|
|
225
|
-
|
|
226
|
-
|
|
216
|
+
stickyHeadersState = _ref9.stickyHeadersState,
|
|
217
|
+
tablePluginState = _ref9.tablePluginState;
|
|
227
218
|
var state = editorView.state;
|
|
228
219
|
var isDragging = resizingPluginState === null || resizingPluginState === void 0 ? void 0 : resizingPluginState.dragging;
|
|
229
220
|
var _ref10 = tablePluginState,
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
221
|
+
tableNode = _ref10.tableNode,
|
|
222
|
+
tablePos = _ref10.tablePos,
|
|
223
|
+
targetCellPosition = _ref10.targetCellPosition,
|
|
224
|
+
isContextualMenuOpen = _ref10.isContextualMenuOpen,
|
|
225
|
+
layout = _ref10.layout,
|
|
226
|
+
tableRef = _ref10.tableRef,
|
|
227
|
+
pluginConfig = _ref10.pluginConfig,
|
|
228
|
+
insertColumnButtonIndex = _ref10.insertColumnButtonIndex,
|
|
229
|
+
insertRowButtonIndex = _ref10.insertRowButtonIndex,
|
|
230
|
+
isHeaderColumnEnabled = _ref10.isHeaderColumnEnabled,
|
|
231
|
+
isHeaderRowEnabled = _ref10.isHeaderRowEnabled,
|
|
232
|
+
tableWrapperTarget = _ref10.tableWrapperTarget;
|
|
242
233
|
var allowControls = pluginConfig.allowControls;
|
|
243
234
|
var stickyHeader = stickyHeadersState ? findStickyHeaderForTable(stickyHeadersState, tablePos) : undefined;
|
|
244
235
|
return /*#__PURE__*/React.createElement(React.Fragment, null, targetCellPosition && tableRef && !isDragging && options && options.allowContextualMenu && /*#__PURE__*/React.createElement(FloatingContextualButton, {
|
|
@@ -305,13 +296,11 @@ var tablesPlugin = function tablesPlugin(options) {
|
|
|
305
296
|
// For now, we are using this on (insert-api/api.ts) but we may create a proper place for it
|
|
306
297
|
createNodeHandler: function createNodeHandler(_ref11) {
|
|
307
298
|
var nodeName = _ref11.nodeName,
|
|
308
|
-
|
|
309
|
-
|
|
299
|
+
schema = _ref11.schema;
|
|
310
300
|
// An EditorPlugin may manage more than one node.
|
|
311
301
|
if (nodeName !== 'table') {
|
|
312
302
|
return null;
|
|
313
303
|
}
|
|
314
|
-
|
|
315
304
|
var table = createTable({
|
|
316
305
|
schema: schema
|
|
317
306
|
});
|
|
@@ -331,7 +320,6 @@ var tablesPlugin = function tablesPlugin(options) {
|
|
|
331
320
|
},
|
|
332
321
|
action: function action(insert, state) {
|
|
333
322
|
var _options$editorAnalyt2;
|
|
334
|
-
|
|
335
323
|
var tr = insert(createTable({
|
|
336
324
|
schema: state.schema
|
|
337
325
|
}));
|
|
@@ -354,5 +342,4 @@ var tablesPlugin = function tablesPlugin(options) {
|
|
|
354
342
|
}
|
|
355
343
|
};
|
|
356
344
|
};
|
|
357
|
-
|
|
358
345
|
export default tablesPlugin;
|
|
@@ -8,53 +8,36 @@ export var OverflowShadowsObserver = /*#__PURE__*/function () {
|
|
|
8
8
|
// updateShadowState is a method to update shadow key
|
|
9
9
|
function OverflowShadowsObserver(updateShadowState, _table, wrapper) {
|
|
10
10
|
var _this = this;
|
|
11
|
-
|
|
12
11
|
_classCallCheck(this, OverflowShadowsObserver);
|
|
13
|
-
|
|
14
12
|
_defineProperty(this, "firstCell", null);
|
|
15
|
-
|
|
16
13
|
_defineProperty(this, "lastCell", null);
|
|
17
|
-
|
|
18
14
|
_defineProperty(this, "getFirstCell", function (isSticky, hasHeaderRow) {
|
|
19
15
|
var _this$table;
|
|
20
|
-
|
|
21
16
|
return (_this$table = _this.table) === null || _this$table === void 0 ? void 0 : _this$table.querySelector(isSticky || !hasHeaderRow ? 'table tbody tr td' : 'table tbody tr th');
|
|
22
17
|
});
|
|
23
|
-
|
|
24
18
|
_defineProperty(this, "getLastCell", function (isSticky, hasHeaderRow) {
|
|
25
19
|
var _this$table2;
|
|
26
|
-
|
|
27
20
|
return (_this$table2 = _this.table) === null || _this$table2 === void 0 ? void 0 : _this$table2.querySelector(isSticky || !hasHeaderRow ? 'table tbody tr td:last-child' : 'table tbody tr th:last-child');
|
|
28
21
|
});
|
|
29
|
-
|
|
30
22
|
_defineProperty(this, "isSticky", false);
|
|
31
|
-
|
|
32
23
|
_defineProperty(this, "stickyRowHeight", 0);
|
|
33
|
-
|
|
34
24
|
_defineProperty(this, "init", function () {
|
|
35
25
|
var table = _this.table;
|
|
36
|
-
|
|
37
26
|
if (!_this.wrapper || !table) {
|
|
38
27
|
return;
|
|
39
28
|
}
|
|
40
|
-
|
|
41
29
|
if (!_this.tableIntersectionObserver) {
|
|
42
30
|
var intersectonOnbserverCallback = function intersectonOnbserverCallback(entry) {
|
|
43
31
|
var _entry$rootBounds, _entry$rootBounds2;
|
|
44
|
-
|
|
45
32
|
if (!((_entry$rootBounds = entry.rootBounds) !== null && _entry$rootBounds !== void 0 && _entry$rootBounds.height) && !((_entry$rootBounds2 = entry.rootBounds) !== null && _entry$rootBounds2 !== void 0 && _entry$rootBounds2.width)) {
|
|
46
33
|
return;
|
|
47
34
|
}
|
|
48
|
-
|
|
49
35
|
if (entry.target !== _this.firstCell && entry.target !== _this.lastCell) {
|
|
50
36
|
return;
|
|
51
37
|
}
|
|
52
|
-
|
|
53
38
|
_this.updateStickyShadowsHeightIfChanged();
|
|
54
|
-
|
|
55
39
|
_this.checkIntersectionEvent(entry, _this.firstCell === entry.target ? ShadowEvent.SHOW_BEFORE_SHADOW : ShadowEvent.SHOW_AFTER_SHADOW);
|
|
56
40
|
};
|
|
57
|
-
|
|
58
41
|
_this.tableIntersectionObserver = new IntersectionObserver(function (entries, _) {
|
|
59
42
|
entries.forEach(function (entry) {
|
|
60
43
|
return intersectonOnbserverCallback(entry);
|
|
@@ -67,88 +50,71 @@ export var OverflowShadowsObserver = /*#__PURE__*/function () {
|
|
|
67
50
|
return;
|
|
68
51
|
}
|
|
69
52
|
});
|
|
70
|
-
|
|
71
53
|
_defineProperty(this, "checkIntersectionEvent", function (entry, shadowKey) {
|
|
72
|
-
if (
|
|
54
|
+
if (
|
|
55
|
+
// If it's in full view, don't show shadow.
|
|
73
56
|
entry.isIntersecting && entry.intersectionRatio === 1) {
|
|
74
57
|
_this.updateShadowState(shadowKey, false);
|
|
75
|
-
} else if (
|
|
58
|
+
} else if (
|
|
59
|
+
// If it's in partial view, show a shadow
|
|
76
60
|
entry.intersectionRatio < 1) {
|
|
77
61
|
_this.updateShadowState(shadowKey, true);
|
|
78
62
|
}
|
|
79
63
|
});
|
|
80
|
-
|
|
81
64
|
_defineProperty(this, "observeCells", function (isSticky, hasHeaderRow) {
|
|
82
65
|
var stickyChanged = !!isSticky !== _this.isSticky;
|
|
83
|
-
_this.isSticky = !!isSticky;
|
|
66
|
+
_this.isSticky = !!isSticky;
|
|
84
67
|
|
|
68
|
+
// update sticky shadows
|
|
85
69
|
_this.updateStickyShadowsHeightIfChanged();
|
|
86
|
-
|
|
87
70
|
if (!stickyChanged) {
|
|
88
71
|
var firstCell = _this.getFirstCell(isSticky, hasHeaderRow);
|
|
89
|
-
|
|
90
72
|
var lastCell = _this.getLastCell(isSticky, hasHeaderRow);
|
|
91
|
-
|
|
92
73
|
if (!firstCell || !lastCell || firstCell === _this.firstCell && lastCell === _this.lastCell) {
|
|
93
74
|
return;
|
|
94
75
|
}
|
|
95
76
|
}
|
|
96
|
-
|
|
97
77
|
_this.firstCell = _this.getFirstCell(isSticky, hasHeaderRow);
|
|
98
78
|
_this.lastCell = _this.getLastCell(isSticky, hasHeaderRow);
|
|
99
|
-
|
|
100
79
|
if (_this.tableIntersectionObserver && _this.firstCell && _this.lastCell) {
|
|
101
80
|
_this.tableIntersectionObserver.disconnect();
|
|
102
|
-
|
|
103
81
|
_this.tableIntersectionObserver.observe(_this.firstCell);
|
|
104
|
-
|
|
105
82
|
_this.tableIntersectionObserver.observe(_this.lastCell);
|
|
106
83
|
}
|
|
107
84
|
});
|
|
108
|
-
|
|
109
85
|
_defineProperty(this, "updateStickyShadows", function (stickyRowHeight) {
|
|
110
86
|
var _this$wrapper, _this$wrapper2, _this$wrapper2$parent, _this$wrapper3, _this$wrapper3$parent;
|
|
111
|
-
|
|
112
87
|
if (!_this.isSticky) {
|
|
113
88
|
return;
|
|
114
89
|
}
|
|
115
|
-
|
|
116
90
|
var stickyCell = _this.getStickyCell();
|
|
117
|
-
|
|
118
91
|
if (!stickyCell || !((_this$wrapper = _this.wrapper) !== null && _this$wrapper !== void 0 && _this$wrapper.parentElement)) {
|
|
119
92
|
return;
|
|
120
93
|
}
|
|
121
|
-
|
|
122
|
-
|
|
94
|
+
var heightStyleOrCompute = "".concat(stickyRowHeight || stickyCell.clientHeight + 1, "px");
|
|
95
|
+
// Use getElementsByClassName here for a live node list to capture
|
|
123
96
|
// sticky shadows
|
|
124
|
-
|
|
125
97
|
var liveRightShadows = (_this$wrapper2 = _this.wrapper) === null || _this$wrapper2 === void 0 ? void 0 : (_this$wrapper2$parent = _this$wrapper2.parentElement) === null || _this$wrapper2$parent === void 0 ? void 0 : _this$wrapper2$parent.getElementsByClassName("".concat(ClassName.TABLE_RIGHT_SHADOW));
|
|
126
98
|
var liveLeftShadows = (_this$wrapper3 = _this.wrapper) === null || _this$wrapper3 === void 0 ? void 0 : (_this$wrapper3$parent = _this$wrapper3.parentElement) === null || _this$wrapper3$parent === void 0 ? void 0 : _this$wrapper3$parent.getElementsByClassName("".concat(ClassName.TABLE_LEFT_SHADOW));
|
|
127
99
|
updateShadowListForStickyStyles(heightStyleOrCompute, liveLeftShadows);
|
|
128
100
|
updateShadowListForStickyStyles(heightStyleOrCompute, liveRightShadows);
|
|
129
101
|
});
|
|
130
|
-
|
|
131
102
|
this.updateShadowState = updateShadowState;
|
|
132
103
|
this.table = _table;
|
|
133
104
|
this.wrapper = wrapper;
|
|
134
105
|
this.init();
|
|
135
106
|
}
|
|
136
|
-
|
|
137
107
|
_createClass(OverflowShadowsObserver, [{
|
|
138
108
|
key: "updateStickyShadowsHeightIfChanged",
|
|
139
109
|
value: function updateStickyShadowsHeightIfChanged() {
|
|
140
110
|
if (!this.isSticky) {
|
|
141
111
|
return;
|
|
142
112
|
}
|
|
143
|
-
|
|
144
113
|
var stickyCell = this.getStickyCell();
|
|
145
|
-
|
|
146
114
|
if (!stickyCell) {
|
|
147
115
|
return;
|
|
148
116
|
}
|
|
149
|
-
|
|
150
117
|
var newStickyRowHeight = stickyCell.clientHeight + 1;
|
|
151
|
-
|
|
152
118
|
if (newStickyRowHeight === this.stickyRowHeight) {
|
|
153
119
|
this.stickyRowHeight = newStickyRowHeight;
|
|
154
120
|
this.updateStickyShadows(this.stickyRowHeight);
|
|
@@ -158,7 +124,6 @@ export var OverflowShadowsObserver = /*#__PURE__*/function () {
|
|
|
158
124
|
key: "getStickyCell",
|
|
159
125
|
value: function getStickyCell() {
|
|
160
126
|
var _this$wrapper4;
|
|
161
|
-
|
|
162
127
|
var stickyRow = (_this$wrapper4 = this.wrapper) === null || _this$wrapper4 === void 0 ? void 0 : _this$wrapper4.querySelector('tr.sticky');
|
|
163
128
|
var stickyCell = stickyRow && stickyRow.firstElementChild;
|
|
164
129
|
return stickyCell;
|
|
@@ -172,6 +137,5 @@ export var OverflowShadowsObserver = /*#__PURE__*/function () {
|
|
|
172
137
|
}
|
|
173
138
|
}
|
|
174
139
|
}]);
|
|
175
|
-
|
|
176
140
|
return OverflowShadowsObserver;
|
|
177
141
|
}();
|