@kopexa/extension-table 17.0.45 → 17.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunk-2NBDRVYL.mjs +428 -0
- package/dist/chunk-3SWV7BGP.mjs +638 -0
- package/dist/chunk-4QSZXHZO.mjs +276 -0
- package/dist/chunk-5B5XIL2G.mjs +457 -0
- package/dist/chunk-62B2LU2Q.mjs +603 -0
- package/dist/chunk-6FHFDGJO.mjs +251 -0
- package/dist/chunk-CD62W5C3.mjs +165 -0
- package/dist/chunk-CN73TYHV.mjs +190 -0
- package/dist/chunk-CPDSPBS6.mjs +276 -0
- package/dist/chunk-E7W2KRZG.mjs +49 -0
- package/dist/chunk-G6GHC2WO.mjs +276 -0
- package/dist/chunk-GBTQVIN5.mjs +174 -0
- package/dist/chunk-GDEXPEW5.mjs +52 -0
- package/dist/chunk-GQLZBIWF.mjs +198 -0
- package/dist/chunk-IRJ6RAVQ.mjs +116 -0
- package/dist/chunk-J4VOSZCZ.mjs +59 -0
- package/dist/chunk-KIYFW7MP.mjs +122 -0
- package/dist/chunk-KTRZVXJC.mjs +306 -0
- package/dist/chunk-LUA32VH4.mjs +35 -0
- package/dist/{chunk-SNJF4UW6.mjs → chunk-MB52MZQ4.mjs} +7 -8
- package/dist/chunk-PTX5UYV6.mjs +10 -0
- package/dist/chunk-TEGO6KUS.mjs +96 -0
- package/dist/chunk-VIBVRWS4.mjs +197 -0
- package/dist/chunk-VQV757EG.mjs +113 -0
- package/dist/chunk-XRNQXADK.mjs +149 -0
- package/dist/chunk-ZVPJDJBO.mjs +134 -0
- package/dist/{kit.d.mts → extensions/kit.d.mts} +1 -3
- package/dist/{kit.d.ts → extensions/kit.d.ts} +1 -3
- package/dist/extensions/kit.js +1041 -0
- package/dist/extensions/kit.mjs +15 -0
- package/dist/extensions/table-cell.d.mts +6 -0
- package/dist/extensions/table-cell.d.ts +6 -0
- package/dist/extensions/table-cell.js +70 -0
- package/dist/{table/icons.mjs → extensions/table-cell.mjs} +3 -3
- package/dist/extensions/table-handle-plugin.d.mts +46 -0
- package/dist/extensions/table-handle-plugin.d.ts +46 -0
- package/dist/extensions/table-handle-plugin.js +1100 -0
- package/dist/extensions/table-handle-plugin.mjs +18 -0
- package/dist/extensions/table-handle.d.mts +19 -0
- package/dist/extensions/table-handle.d.ts +19 -0
- package/dist/extensions/table-handle.js +865 -0
- package/dist/extensions/table-handle.mjs +11 -0
- package/dist/{table → extensions}/table.d.mts +2 -2
- package/dist/{table → extensions}/table.d.ts +2 -2
- package/dist/extensions/table.js +138 -0
- package/dist/extensions/table.mjs +9 -0
- package/dist/hooks/use-resize-overlay.d.mts +5 -0
- package/dist/hooks/use-resize-overlay.d.ts +5 -0
- package/dist/hooks/use-resize-overlay.js +83 -0
- package/dist/hooks/use-resize-overlay.mjs +9 -0
- package/dist/hooks/use-table-add-row-column.d.mts +57 -0
- package/dist/hooks/use-table-add-row-column.d.ts +57 -0
- package/dist/hooks/use-table-add-row-column.js +551 -0
- package/dist/hooks/use-table-add-row-column.mjs +11 -0
- package/dist/hooks/use-table-align-cell.d.mts +148 -0
- package/dist/hooks/use-table-align-cell.d.ts +148 -0
- package/dist/hooks/use-table-align-cell.js +655 -0
- package/dist/hooks/use-table-align-cell.mjs +13 -0
- package/dist/hooks/use-table-clear-row-column-content.d.mts +103 -0
- package/dist/hooks/use-table-clear-row-column-content.d.ts +103 -0
- package/dist/hooks/use-table-clear-row-column-content.js +681 -0
- package/dist/hooks/use-table-clear-row-column-content.mjs +11 -0
- package/dist/hooks/use-table-delete-row-column.d.mts +87 -0
- package/dist/hooks/use-table-delete-row-column.d.ts +87 -0
- package/dist/hooks/use-table-delete-row-column.js +459 -0
- package/dist/hooks/use-table-delete-row-column.mjs +11 -0
- package/dist/hooks/use-table-duplicate-row-column.d.mts +49 -0
- package/dist/hooks/use-table-duplicate-row-column.d.ts +49 -0
- package/dist/hooks/use-table-duplicate-row-column.js +758 -0
- package/dist/hooks/use-table-duplicate-row-column.mjs +11 -0
- package/dist/hooks/use-table-handle-positioning.d.mts +42 -0
- package/dist/hooks/use-table-handle-positioning.d.ts +42 -0
- package/dist/hooks/use-table-handle-positioning.js +190 -0
- package/dist/hooks/use-table-handle-positioning.mjs +10 -0
- package/dist/hooks/use-table-handle-state.d.mts +28 -0
- package/dist/hooks/use-table-handle-state.d.ts +28 -0
- package/dist/hooks/use-table-handle-state.js +76 -0
- package/dist/hooks/use-table-handle-state.mjs +9 -0
- package/dist/hooks/use-table-header-row-column.d.mts +58 -0
- package/dist/hooks/use-table-header-row-column.d.ts +58 -0
- package/dist/hooks/use-table-header-row-column.js +603 -0
- package/dist/hooks/use-table-header-row-column.mjs +13 -0
- package/dist/hooks/use-table-merge-split-cell.d.mts +123 -0
- package/dist/hooks/use-table-merge-split-cell.d.ts +123 -0
- package/dist/hooks/use-table-merge-split-cell.js +331 -0
- package/dist/hooks/use-table-merge-split-cell.mjs +12 -0
- package/dist/hooks/use-table-move-row-column.d.mts +101 -0
- package/dist/hooks/use-table-move-row-column.d.ts +101 -0
- package/dist/hooks/use-table-move-row-column.js +621 -0
- package/dist/hooks/use-table-move-row-column.mjs +13 -0
- package/dist/hooks/use-table-sort-row-column.d.mts +118 -0
- package/dist/hooks/use-table-sort-row-column.d.ts +118 -0
- package/dist/hooks/use-table-sort-row-column.js +623 -0
- package/dist/hooks/use-table-sort-row-column.mjs +13 -0
- package/dist/index.d.mts +18 -5
- package/dist/index.d.ts +18 -5
- package/dist/index.js +4939 -910
- package/dist/index.mjs +43 -18
- package/dist/lib/constants.d.mts +4 -0
- package/dist/lib/constants.d.ts +4 -0
- package/dist/{table-row.js → lib/constants.js} +10 -10
- package/dist/lib/constants.mjs +10 -0
- package/dist/lib/create-image.d.mts +12 -0
- package/dist/lib/create-image.d.ts +12 -0
- package/dist/lib/create-image.js +221 -0
- package/dist/lib/create-image.mjs +8 -0
- package/dist/lib/table-utils.d.mts +263 -0
- package/dist/lib/table-utils.d.ts +263 -0
- package/dist/lib/table-utils.js +488 -0
- package/dist/lib/table-utils.mjs +40 -0
- package/dist/messages.d.mts +174 -0
- package/dist/messages.d.ts +174 -0
- package/dist/messages.js +213 -0
- package/dist/{table-row.mjs → messages.mjs} +3 -3
- package/dist/ui/table-alignment-menu.d.mts +25 -0
- package/dist/ui/table-alignment-menu.d.ts +25 -0
- package/dist/ui/table-alignment-menu.js +758 -0
- package/dist/ui/table-alignment-menu.mjs +14 -0
- package/dist/ui/table-cell-handle-menu.d.mts +12 -0
- package/dist/ui/table-cell-handle-menu.d.ts +12 -0
- package/dist/ui/table-cell-handle-menu.js +1317 -0
- package/dist/ui/table-cell-handle-menu.mjs +17 -0
- package/dist/ui/table-handle-menu.d.mts +23 -0
- package/dist/ui/table-handle-menu.d.ts +23 -0
- package/dist/ui/table-handle-menu.js +2598 -0
- package/dist/ui/table-handle-menu.mjs +21 -0
- package/dist/ui/table-handle.d.mts +48 -0
- package/dist/ui/table-handle.d.ts +48 -0
- package/dist/ui/table-handle.js +3126 -0
- package/dist/ui/table-handle.mjs +22 -0
- package/dist/ui/table-selection-overlay.d.mts +14 -0
- package/dist/ui/table-selection-overlay.d.ts +14 -0
- package/dist/ui/table-selection-overlay.js +553 -0
- package/dist/ui/table-selection-overlay.mjs +11 -0
- package/package.json +16 -12
- package/dist/chunk-6NY5XWR7.mjs +0 -11
- package/dist/chunk-74O2ORPO.mjs +0 -81
- package/dist/chunk-7NEAULTF.mjs +0 -58
- package/dist/chunk-ARSGMUXM.mjs +0 -116
- package/dist/chunk-BAQU2YT5.mjs +0 -41
- package/dist/chunk-DF6ZMJLL.mjs +0 -40
- package/dist/chunk-FKOIW52J.mjs +0 -11
- package/dist/chunk-GMNNSVR3.mjs +0 -540
- package/dist/chunk-IMRHHVEF.mjs +0 -113
- package/dist/chunk-NTWXQSW6.mjs +0 -13
- package/dist/chunk-OPDSKEZR.mjs +0 -93
- package/dist/chunk-YSUOVRY4.mjs +0 -1
- package/dist/kit.js +0 -1024
- package/dist/kit.mjs +0 -19
- package/dist/table/icons.d.mts +0 -13
- package/dist/table/icons.d.ts +0 -13
- package/dist/table/icons.js +0 -81
- package/dist/table/index.d.mts +0 -3
- package/dist/table/index.d.ts +0 -3
- package/dist/table/index.js +0 -809
- package/dist/table/index.mjs +0 -15
- package/dist/table/table-controls.d.mts +0 -15
- package/dist/table/table-controls.d.ts +0 -15
- package/dist/table/table-controls.js +0 -131
- package/dist/table/table-controls.mjs +0 -8
- package/dist/table/table-view.d.mts +0 -43
- package/dist/table/table-view.d.ts +0 -43
- package/dist/table/table-view.js +0 -610
- package/dist/table/table-view.mjs +0 -12
- package/dist/table/table.js +0 -807
- package/dist/table/table.mjs +0 -14
- package/dist/table/utilities/col-style.d.mts +0 -3
- package/dist/table/utilities/col-style.d.ts +0 -3
- package/dist/table/utilities/col-style.js +0 -36
- package/dist/table/utilities/col-style.mjs +0 -8
- package/dist/table/utilities/delete-table-when-all-cells-selected.d.mts +0 -5
- package/dist/table/utilities/delete-table-when-all-cells-selected.d.ts +0 -5
- package/dist/table/utilities/delete-table-when-all-cells-selected.js +0 -66
- package/dist/table/utilities/delete-table-when-all-cells-selected.mjs +0 -40
- package/dist/table/utilities/get-table-node-types.d.mts +0 -7
- package/dist/table/utilities/get-table-node-types.d.ts +0 -7
- package/dist/table/utilities/get-table-node-types.js +0 -44
- package/dist/table/utilities/get-table-node-types.mjs +0 -21
- package/dist/table/utilities/insert-line-above-table-action.d.mts +0 -5
- package/dist/table/utilities/insert-line-above-table-action.d.ts +0 -5
- package/dist/table/utilities/insert-line-above-table-action.js +0 -64
- package/dist/table/utilities/insert-line-above-table-action.mjs +0 -8
- package/dist/table/utilities/insert-line-below-table-action.d.mts +0 -5
- package/dist/table/utilities/insert-line-below-table-action.d.ts +0 -5
- package/dist/table/utilities/insert-line-below-table-action.js +0 -63
- package/dist/table/utilities/insert-line-below-table-action.mjs +0 -8
- package/dist/table/utilities/is-cell-selection.d.mts +0 -5
- package/dist/table/utilities/is-cell-selection.d.ts +0 -5
- package/dist/table/utilities/is-cell-selection.js +0 -34
- package/dist/table/utilities/is-cell-selection.mjs +0 -8
- package/dist/table-cell.d.mts +0 -8
- package/dist/table-cell.d.ts +0 -8
- package/dist/table-cell.js +0 -139
- package/dist/table-cell.mjs +0 -8
- package/dist/table-header.d.mts +0 -6
- package/dist/table-header.d.ts +0 -6
- package/dist/table-header.js +0 -104
- package/dist/table-header.mjs +0 -8
- package/dist/table-row.d.mts +0 -6
- package/dist/table-row.d.ts +0 -6
|
@@ -0,0 +1,488 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
"use strict";
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __export = (target, all) => {
|
|
8
|
+
for (var name in all)
|
|
9
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
10
|
+
};
|
|
11
|
+
var __copyProps = (to, from, except, desc) => {
|
|
12
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
13
|
+
for (let key of __getOwnPropNames(from))
|
|
14
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
15
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
16
|
+
}
|
|
17
|
+
return to;
|
|
18
|
+
};
|
|
19
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
20
|
+
|
|
21
|
+
// src/lib/table-utils.ts
|
|
22
|
+
var table_utils_exports = {};
|
|
23
|
+
__export(table_utils_exports, {
|
|
24
|
+
cellsOverlapRectangle: () => cellsOverlapRectangle,
|
|
25
|
+
domCellAround: () => domCellAround,
|
|
26
|
+
getCellIndicesFromDOM: () => getCellIndicesFromDOM,
|
|
27
|
+
getColumnCells: () => getColumnCells,
|
|
28
|
+
getIndexCoordinates: () => getIndexCoordinates,
|
|
29
|
+
getRowCells: () => getRowCells,
|
|
30
|
+
getRowOrColumnCells: () => getRowOrColumnCells,
|
|
31
|
+
getTable: () => getTable,
|
|
32
|
+
getTableFromDOM: () => getTableFromDOM,
|
|
33
|
+
getTableSelectionType: () => getTableSelectionType,
|
|
34
|
+
isCellEmpty: () => isCellEmpty,
|
|
35
|
+
isCellMerged: () => isCellMerged,
|
|
36
|
+
isTableNode: () => isTableNode,
|
|
37
|
+
rectEq: () => rectEq,
|
|
38
|
+
selectCellsByCoords: () => selectCellsByCoords,
|
|
39
|
+
setCellAttr: () => setCellAttr,
|
|
40
|
+
updateSelectionAfterAction: () => updateSelectionAfterAction
|
|
41
|
+
});
|
|
42
|
+
module.exports = __toCommonJS(table_utils_exports);
|
|
43
|
+
var import_shared_utils = require("@kopexa/shared-utils");
|
|
44
|
+
var import_tables = require("@tiptap/pm/tables");
|
|
45
|
+
var EMPTY_CELLS_RESULT = { cells: [], mergedCells: [] };
|
|
46
|
+
function domCellAround(target) {
|
|
47
|
+
let current = target;
|
|
48
|
+
while (current && current.tagName !== "TD" && current.tagName !== "TH" && !current.classList.contains("tableWrapper")) {
|
|
49
|
+
if (current.classList.contains("ProseMirror")) return void 0;
|
|
50
|
+
current = (0, import_shared_utils.isHTMLElement)(current.parentNode) ? current.parentNode : null;
|
|
51
|
+
}
|
|
52
|
+
if (!current) return void 0;
|
|
53
|
+
if (current.tagName === "TD" || current.tagName === "TH") {
|
|
54
|
+
return {
|
|
55
|
+
type: "cell",
|
|
56
|
+
domNode: current,
|
|
57
|
+
tbodyNode: (0, import_shared_utils.safeClosest)(current, "tbody")
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
return {
|
|
61
|
+
type: "wrapper",
|
|
62
|
+
domNode: current,
|
|
63
|
+
tbodyNode: current.querySelector("tbody")
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
function getCellIndicesFromDOM(cell, tableNode, editor) {
|
|
67
|
+
if (!tableNode) return null;
|
|
68
|
+
try {
|
|
69
|
+
const cellPos = editor.view.posAtDOM(cell, 0);
|
|
70
|
+
const $cellPos = editor.view.state.doc.resolve(cellPos);
|
|
71
|
+
for (let d = $cellPos.depth; d > 0; d--) {
|
|
72
|
+
const node = $cellPos.node(d);
|
|
73
|
+
if (node.type.name === "tableCell" || node.type.name === "tableHeader") {
|
|
74
|
+
const tableMap = import_tables.TableMap.get(tableNode);
|
|
75
|
+
const cellNodePos = $cellPos.before(d);
|
|
76
|
+
const tableStart = $cellPos.start(d - 2);
|
|
77
|
+
const cellOffset = cellNodePos - tableStart;
|
|
78
|
+
const cellIndex = tableMap.map.indexOf(cellOffset);
|
|
79
|
+
return {
|
|
80
|
+
rowIndex: Math.floor(cellIndex / tableMap.width),
|
|
81
|
+
colIndex: cellIndex % tableMap.width
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
} catch (error) {
|
|
86
|
+
console.warn("Could not get cell position:", error);
|
|
87
|
+
}
|
|
88
|
+
return null;
|
|
89
|
+
}
|
|
90
|
+
function collectCells(editor, orientation, index, tablePos) {
|
|
91
|
+
if (!editor) return EMPTY_CELLS_RESULT;
|
|
92
|
+
const { state } = editor;
|
|
93
|
+
const table = getTable(editor, tablePos);
|
|
94
|
+
if (!table) return EMPTY_CELLS_RESULT;
|
|
95
|
+
const tableStart = table.start;
|
|
96
|
+
const tableNode = table.node;
|
|
97
|
+
const map = table.map;
|
|
98
|
+
const resolvedIndex = resolveOrientationIndex(
|
|
99
|
+
state,
|
|
100
|
+
table,
|
|
101
|
+
orientation,
|
|
102
|
+
index
|
|
103
|
+
);
|
|
104
|
+
if (resolvedIndex === null) return EMPTY_CELLS_RESULT;
|
|
105
|
+
const maxIndex = orientation === "row" ? map.height : map.width;
|
|
106
|
+
if (resolvedIndex < 0 || resolvedIndex >= maxIndex) {
|
|
107
|
+
return EMPTY_CELLS_RESULT;
|
|
108
|
+
}
|
|
109
|
+
const cells = [];
|
|
110
|
+
const mergedCells = [];
|
|
111
|
+
const seenMerged = /* @__PURE__ */ new Set();
|
|
112
|
+
const iterationCount = orientation === "row" ? map.width : map.height;
|
|
113
|
+
for (let i = 0; i < iterationCount; i++) {
|
|
114
|
+
const row = orientation === "row" ? resolvedIndex : i;
|
|
115
|
+
const col = orientation === "row" ? i : resolvedIndex;
|
|
116
|
+
const cellIndex = row * map.width + col;
|
|
117
|
+
const mapCell = map.map[cellIndex];
|
|
118
|
+
if (mapCell === void 0) continue;
|
|
119
|
+
const cellPos = tableStart + mapCell;
|
|
120
|
+
const cellNode = tableNode.nodeAt(mapCell);
|
|
121
|
+
if (!cellNode) continue;
|
|
122
|
+
const cell = createCellInfo(row, col, cellPos, cellNode);
|
|
123
|
+
if (isCellMerged(cellNode)) {
|
|
124
|
+
if (!seenMerged.has(cellPos)) {
|
|
125
|
+
mergedCells.push(cell);
|
|
126
|
+
seenMerged.add(cellPos);
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
cells.push(cell);
|
|
130
|
+
}
|
|
131
|
+
return { cells, mergedCells };
|
|
132
|
+
}
|
|
133
|
+
function isCellMerged(node) {
|
|
134
|
+
var _a, _b;
|
|
135
|
+
if (!node) return false;
|
|
136
|
+
const colspan = (_a = node.attrs.colspan) != null ? _a : 1;
|
|
137
|
+
const rowspan = (_b = node.attrs.rowspan) != null ? _b : 1;
|
|
138
|
+
return colspan > 1 || rowspan > 1;
|
|
139
|
+
}
|
|
140
|
+
function getColumnCells(editor, columnIndex, tablePos) {
|
|
141
|
+
return collectCells(editor, "column", columnIndex, tablePos);
|
|
142
|
+
}
|
|
143
|
+
function getTable(editor, tablePos) {
|
|
144
|
+
if (!editor) return null;
|
|
145
|
+
let table = null;
|
|
146
|
+
if (typeof tablePos === "number") {
|
|
147
|
+
const tableNode = editor.state.doc.nodeAt(tablePos);
|
|
148
|
+
if ((tableNode == null ? void 0 : tableNode.type.name) === "table") {
|
|
149
|
+
table = {
|
|
150
|
+
node: tableNode,
|
|
151
|
+
pos: tablePos,
|
|
152
|
+
start: tablePos + 1,
|
|
153
|
+
depth: editor.state.doc.resolve(tablePos).depth
|
|
154
|
+
};
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
if (!table) {
|
|
158
|
+
const { state } = editor;
|
|
159
|
+
const $from = state.doc.resolve(state.selection.from);
|
|
160
|
+
table = (0, import_tables.findTable)($from);
|
|
161
|
+
}
|
|
162
|
+
if (!table) return null;
|
|
163
|
+
const tableMap = import_tables.TableMap.get(table.node);
|
|
164
|
+
if (!tableMap) return null;
|
|
165
|
+
return { ...table, map: tableMap };
|
|
166
|
+
}
|
|
167
|
+
function createCellInfo(row, column, cellPos, cellNode) {
|
|
168
|
+
return {
|
|
169
|
+
row,
|
|
170
|
+
column,
|
|
171
|
+
pos: cellPos,
|
|
172
|
+
node: cellNode,
|
|
173
|
+
start: cellPos + 1,
|
|
174
|
+
depth: cellNode ? cellNode.content.size : 0
|
|
175
|
+
};
|
|
176
|
+
}
|
|
177
|
+
function resolveOrientationIndex(state, table, orientation, providedIndex) {
|
|
178
|
+
var _a;
|
|
179
|
+
if (typeof providedIndex === "number") {
|
|
180
|
+
return providedIndex;
|
|
181
|
+
}
|
|
182
|
+
if (state.selection instanceof import_tables.CellSelection) {
|
|
183
|
+
const rect2 = (0, import_tables.selectedRect)(state);
|
|
184
|
+
return orientation === "row" ? rect2.top : rect2.left;
|
|
185
|
+
}
|
|
186
|
+
const $cell = (_a = (0, import_tables.cellAround)(state.selection.$anchor)) != null ? _a : (0, import_tables.selectionCell)(state);
|
|
187
|
+
if (!$cell) return null;
|
|
188
|
+
const rel = $cell.pos - table.start;
|
|
189
|
+
const rect = table.map.findCell(rel);
|
|
190
|
+
return orientation === "row" ? rect.top : rect.left;
|
|
191
|
+
}
|
|
192
|
+
function getIndexCoordinates({
|
|
193
|
+
editor,
|
|
194
|
+
index,
|
|
195
|
+
orientation,
|
|
196
|
+
tablePos
|
|
197
|
+
}) {
|
|
198
|
+
if (!editor) return null;
|
|
199
|
+
const table = getTable(editor, tablePos);
|
|
200
|
+
if (!table) return null;
|
|
201
|
+
const { map } = table;
|
|
202
|
+
const { width, height } = map;
|
|
203
|
+
if (index < 0) return null;
|
|
204
|
+
if (orientation === "row" && index >= height) return null;
|
|
205
|
+
if (orientation === "column" && index >= width) return null;
|
|
206
|
+
return orientation === "row" ? Array.from({ length: map.width }, (_, col) => ({ row: index, col })) : Array.from({ length: map.height }, (_, row) => ({ row, col: index }));
|
|
207
|
+
}
|
|
208
|
+
function getRowCells(editor, rowIndex, tablePos) {
|
|
209
|
+
return collectCells(editor, "row", rowIndex, tablePos);
|
|
210
|
+
}
|
|
211
|
+
function getTableFromDOM(tableElement, editor) {
|
|
212
|
+
try {
|
|
213
|
+
const pos = editor.view.posAtDOM(tableElement, 0);
|
|
214
|
+
const $pos = editor.view.state.doc.resolve(pos);
|
|
215
|
+
for (let d = $pos.depth; d >= 0; d--) {
|
|
216
|
+
const node = $pos.node(d);
|
|
217
|
+
if (isTableNode(node)) {
|
|
218
|
+
return { node, pos: d === 0 ? 0 : $pos.before(d) };
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
} catch (error) {
|
|
222
|
+
console.warn("Could not get table from DOM:", error);
|
|
223
|
+
}
|
|
224
|
+
return null;
|
|
225
|
+
}
|
|
226
|
+
function isTableNode(node) {
|
|
227
|
+
return !!node && (node.type.name === "table" || node.type.spec.tableRole === "table");
|
|
228
|
+
}
|
|
229
|
+
function selectCellsByCoords(editor, tablePos, coords, options = { mode: "state" }) {
|
|
230
|
+
if (!editor) return;
|
|
231
|
+
const table = getTable(editor, tablePos);
|
|
232
|
+
if (!table) return;
|
|
233
|
+
const { state } = editor;
|
|
234
|
+
const tableMap = table.map;
|
|
235
|
+
const cleanedCoords = coords.map((coord) => ({
|
|
236
|
+
row: (0, import_shared_utils.clamp)(coord.row, 0, tableMap.height - 1),
|
|
237
|
+
col: (0, import_shared_utils.clamp)(coord.col, 0, tableMap.width - 1)
|
|
238
|
+
})).filter((coord) => isWithinBounds(coord.row, coord.col, tableMap));
|
|
239
|
+
if (cleanedCoords.length === 0) {
|
|
240
|
+
return;
|
|
241
|
+
}
|
|
242
|
+
const allRows = cleanedCoords.map((coord) => coord.row);
|
|
243
|
+
const topRow = Math.min(...allRows);
|
|
244
|
+
const bottomRow = Math.max(...allRows);
|
|
245
|
+
const allCols = cleanedCoords.map((coord) => coord.col);
|
|
246
|
+
const leftCol = Math.min(...allCols);
|
|
247
|
+
const rightCol = Math.max(...allCols);
|
|
248
|
+
const getCellPositionFromMap = (row, col) => {
|
|
249
|
+
const cellOffset = tableMap.map[row * tableMap.width + col];
|
|
250
|
+
if (cellOffset === void 0) return null;
|
|
251
|
+
return tablePos + 1 + cellOffset;
|
|
252
|
+
};
|
|
253
|
+
const anchorPosition = getCellPositionFromMap(topRow, leftCol);
|
|
254
|
+
if (anchorPosition === null) return;
|
|
255
|
+
let headPosition = getCellPositionFromMap(bottomRow, rightCol);
|
|
256
|
+
if (headPosition === null) return;
|
|
257
|
+
if (headPosition === anchorPosition) {
|
|
258
|
+
let foundDifferentCell = false;
|
|
259
|
+
for (let row = bottomRow; row >= topRow && !foundDifferentCell; row--) {
|
|
260
|
+
for (let col = rightCol; col >= leftCol && !foundDifferentCell; col--) {
|
|
261
|
+
const candidatePosition = getCellPositionFromMap(row, col);
|
|
262
|
+
if (candidatePosition !== null && candidatePosition !== anchorPosition) {
|
|
263
|
+
headPosition = candidatePosition;
|
|
264
|
+
foundDifferentCell = true;
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
try {
|
|
270
|
+
const anchorRef = state.doc.resolve(anchorPosition);
|
|
271
|
+
const headRef = state.doc.resolve(headPosition);
|
|
272
|
+
const cellSelection = new import_tables.CellSelection(anchorRef, headRef);
|
|
273
|
+
const transaction = state.tr.setSelection(cellSelection);
|
|
274
|
+
return applySelectionWithMode(state, transaction, options);
|
|
275
|
+
} catch (error) {
|
|
276
|
+
console.error("Failed to create cell selection:", error);
|
|
277
|
+
return;
|
|
278
|
+
}
|
|
279
|
+
}
|
|
280
|
+
function isWithinBounds(row, col, map) {
|
|
281
|
+
return row >= 0 && row < map.height && col >= 0 && col < map.width;
|
|
282
|
+
}
|
|
283
|
+
function applySelectionWithMode(state, transaction, options) {
|
|
284
|
+
var _a;
|
|
285
|
+
const mode = (_a = options.mode) != null ? _a : "state";
|
|
286
|
+
switch (mode) {
|
|
287
|
+
case "dispatch": {
|
|
288
|
+
const dispatchOptions = options;
|
|
289
|
+
if (typeof dispatchOptions.dispatch === "function") {
|
|
290
|
+
dispatchOptions.dispatch(transaction);
|
|
291
|
+
}
|
|
292
|
+
return;
|
|
293
|
+
}
|
|
294
|
+
case "transaction":
|
|
295
|
+
return transaction;
|
|
296
|
+
default:
|
|
297
|
+
return state.apply(transaction);
|
|
298
|
+
}
|
|
299
|
+
}
|
|
300
|
+
function getTableSelectionType(editor, index, orientation, tablePos) {
|
|
301
|
+
if (typeof index === "number" && orientation) {
|
|
302
|
+
return { orientation, index };
|
|
303
|
+
}
|
|
304
|
+
if (!editor) return null;
|
|
305
|
+
const { state } = editor;
|
|
306
|
+
const table = getTable(editor, tablePos);
|
|
307
|
+
if (!table) return null;
|
|
308
|
+
if (state.selection instanceof import_tables.CellSelection) {
|
|
309
|
+
const rect = (0, import_tables.selectedRect)(state);
|
|
310
|
+
const map = import_tables.TableMap.get(table.node);
|
|
311
|
+
const width = rect.right - rect.left;
|
|
312
|
+
const height = rect.bottom - rect.top;
|
|
313
|
+
if (height === 1 && width === map.width) {
|
|
314
|
+
return { orientation: "row", index: rect.top };
|
|
315
|
+
}
|
|
316
|
+
if (width === 1 && height === map.height) {
|
|
317
|
+
return { orientation: "column", index: rect.left };
|
|
318
|
+
}
|
|
319
|
+
return null;
|
|
320
|
+
}
|
|
321
|
+
return null;
|
|
322
|
+
}
|
|
323
|
+
function getRowOrColumnCells(editor, index, orientation, tablePos) {
|
|
324
|
+
const emptyResult = {
|
|
325
|
+
cells: [],
|
|
326
|
+
mergedCells: [],
|
|
327
|
+
index: void 0,
|
|
328
|
+
orientation: void 0,
|
|
329
|
+
tablePos: void 0
|
|
330
|
+
};
|
|
331
|
+
if (!editor) {
|
|
332
|
+
return emptyResult;
|
|
333
|
+
}
|
|
334
|
+
if (typeof index !== "number" && !(editor.state.selection instanceof import_tables.CellSelection)) {
|
|
335
|
+
return emptyResult;
|
|
336
|
+
}
|
|
337
|
+
let finalIndex = index;
|
|
338
|
+
let finalOrientation = orientation;
|
|
339
|
+
if (typeof finalIndex !== "number" || !finalOrientation || !["row", "column"].includes(finalOrientation)) {
|
|
340
|
+
const selectionType = getTableSelectionType(editor);
|
|
341
|
+
if (!selectionType) return emptyResult;
|
|
342
|
+
finalIndex = selectionType.index;
|
|
343
|
+
finalOrientation = selectionType.orientation;
|
|
344
|
+
}
|
|
345
|
+
const result = collectCells(editor, finalOrientation, finalIndex, tablePos);
|
|
346
|
+
return { ...result, index: finalIndex, orientation: finalOrientation };
|
|
347
|
+
}
|
|
348
|
+
function updateSelectionAfterAction(editor, orientation, newIndex, tablePos) {
|
|
349
|
+
try {
|
|
350
|
+
const table = getTable(editor, tablePos);
|
|
351
|
+
if (!table) return;
|
|
352
|
+
const { state } = editor;
|
|
353
|
+
const { map } = table;
|
|
354
|
+
if (orientation === "row") {
|
|
355
|
+
if (newIndex >= 0 && newIndex < map.height) {
|
|
356
|
+
const startCol = 0;
|
|
357
|
+
const endCol = map.width - 1;
|
|
358
|
+
const startCellPos = table.start + map.positionAt(newIndex, startCol, table.node);
|
|
359
|
+
const endCellPos = table.start + map.positionAt(newIndex, endCol, table.node);
|
|
360
|
+
const $start = state.doc.resolve(startCellPos);
|
|
361
|
+
const $end = state.doc.resolve(endCellPos);
|
|
362
|
+
const newSelection = import_tables.CellSelection.create(
|
|
363
|
+
state.doc,
|
|
364
|
+
$start.pos,
|
|
365
|
+
$end.pos
|
|
366
|
+
);
|
|
367
|
+
const tr = state.tr.setSelection(newSelection);
|
|
368
|
+
editor.view.dispatch(tr);
|
|
369
|
+
}
|
|
370
|
+
} else if (orientation === "column") {
|
|
371
|
+
if (newIndex >= 0 && newIndex < map.width) {
|
|
372
|
+
const startRow = 0;
|
|
373
|
+
const endRow = map.height - 1;
|
|
374
|
+
const startCellPos = table.start + map.positionAt(startRow, newIndex, table.node);
|
|
375
|
+
const endCellPos = table.start + map.positionAt(endRow, newIndex, table.node);
|
|
376
|
+
const $start = state.doc.resolve(startCellPos);
|
|
377
|
+
const $end = state.doc.resolve(endCellPos);
|
|
378
|
+
const newSelection = import_tables.CellSelection.create(
|
|
379
|
+
state.doc,
|
|
380
|
+
$start.pos,
|
|
381
|
+
$end.pos
|
|
382
|
+
);
|
|
383
|
+
const tr = state.tr.setSelection(newSelection);
|
|
384
|
+
editor.view.dispatch(tr);
|
|
385
|
+
}
|
|
386
|
+
}
|
|
387
|
+
} catch (error) {
|
|
388
|
+
console.warn("Failed to update selection after move:", error);
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
function isCellEmpty(cellNode) {
|
|
392
|
+
if (cellNode.childCount === 0) return true;
|
|
393
|
+
let isEmpty = true;
|
|
394
|
+
cellNode.descendants((n) => {
|
|
395
|
+
var _a;
|
|
396
|
+
if (n.isText && ((_a = n.text) == null ? void 0 : _a.trim())) {
|
|
397
|
+
isEmpty = false;
|
|
398
|
+
return false;
|
|
399
|
+
}
|
|
400
|
+
if (n.isLeaf && !n.isText) {
|
|
401
|
+
isEmpty = false;
|
|
402
|
+
return false;
|
|
403
|
+
}
|
|
404
|
+
return true;
|
|
405
|
+
});
|
|
406
|
+
return isEmpty;
|
|
407
|
+
}
|
|
408
|
+
function setCellAttr(nameOrAttrs, value) {
|
|
409
|
+
return (state, dispatch) => {
|
|
410
|
+
var _a;
|
|
411
|
+
if (!(0, import_tables.isInTable)(state)) return false;
|
|
412
|
+
const $cell = (0, import_tables.selectionCell)(state);
|
|
413
|
+
const attrs = typeof nameOrAttrs === "string" ? { [nameOrAttrs]: value } : nameOrAttrs;
|
|
414
|
+
if (dispatch) {
|
|
415
|
+
const tr = state.tr;
|
|
416
|
+
if (state.selection instanceof import_tables.CellSelection) {
|
|
417
|
+
state.selection.forEachCell((node, pos) => {
|
|
418
|
+
const needsUpdate = Object.entries(attrs).some(
|
|
419
|
+
([name, val]) => node.attrs[name] !== val
|
|
420
|
+
);
|
|
421
|
+
if (needsUpdate) {
|
|
422
|
+
tr.setNodeMarkup(pos, null, {
|
|
423
|
+
...node.attrs,
|
|
424
|
+
...attrs
|
|
425
|
+
});
|
|
426
|
+
}
|
|
427
|
+
});
|
|
428
|
+
} else {
|
|
429
|
+
const needsUpdate = Object.entries(attrs).some(
|
|
430
|
+
([name, val]) => {
|
|
431
|
+
var _a2;
|
|
432
|
+
return ((_a2 = $cell.nodeAfter) == null ? void 0 : _a2.attrs[name]) !== val;
|
|
433
|
+
}
|
|
434
|
+
);
|
|
435
|
+
if (needsUpdate) {
|
|
436
|
+
tr.setNodeMarkup($cell.pos, null, {
|
|
437
|
+
...(_a = $cell.nodeAfter) == null ? void 0 : _a.attrs,
|
|
438
|
+
...attrs
|
|
439
|
+
});
|
|
440
|
+
}
|
|
441
|
+
}
|
|
442
|
+
dispatch(tr);
|
|
443
|
+
}
|
|
444
|
+
return true;
|
|
445
|
+
};
|
|
446
|
+
}
|
|
447
|
+
function cellsOverlapRectangle({ width, height, map }, rect) {
|
|
448
|
+
let indexTop = rect.top * width + rect.left, indexLeft = indexTop;
|
|
449
|
+
let indexBottom = (rect.bottom - 1) * width + rect.left, indexRight = indexTop + (rect.right - rect.left - 1);
|
|
450
|
+
for (let i = rect.top; i < rect.bottom; i++) {
|
|
451
|
+
if (rect.left > 0 && map[indexLeft] === map[indexLeft - 1] || rect.right < width && map[indexRight] === map[indexRight + 1])
|
|
452
|
+
return true;
|
|
453
|
+
indexLeft += width;
|
|
454
|
+
indexRight += width;
|
|
455
|
+
}
|
|
456
|
+
for (let i = rect.left; i < rect.right; i++) {
|
|
457
|
+
if (rect.top > 0 && map[indexTop] === map[indexTop - width] || rect.bottom < height && map[indexBottom] === map[indexBottom + width])
|
|
458
|
+
return true;
|
|
459
|
+
indexTop++;
|
|
460
|
+
indexBottom++;
|
|
461
|
+
}
|
|
462
|
+
return false;
|
|
463
|
+
}
|
|
464
|
+
function rectEq(a, b) {
|
|
465
|
+
if (!a && !b) return true;
|
|
466
|
+
if (!a || !b) return false;
|
|
467
|
+
return a.left === b.left && a.top === b.top && a.width === b.width && a.height === b.height;
|
|
468
|
+
}
|
|
469
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
470
|
+
0 && (module.exports = {
|
|
471
|
+
cellsOverlapRectangle,
|
|
472
|
+
domCellAround,
|
|
473
|
+
getCellIndicesFromDOM,
|
|
474
|
+
getColumnCells,
|
|
475
|
+
getIndexCoordinates,
|
|
476
|
+
getRowCells,
|
|
477
|
+
getRowOrColumnCells,
|
|
478
|
+
getTable,
|
|
479
|
+
getTableFromDOM,
|
|
480
|
+
getTableSelectionType,
|
|
481
|
+
isCellEmpty,
|
|
482
|
+
isCellMerged,
|
|
483
|
+
isTableNode,
|
|
484
|
+
rectEq,
|
|
485
|
+
selectCellsByCoords,
|
|
486
|
+
setCellAttr,
|
|
487
|
+
updateSelectionAfterAction
|
|
488
|
+
});
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import {
|
|
3
|
+
cellsOverlapRectangle,
|
|
4
|
+
domCellAround,
|
|
5
|
+
getCellIndicesFromDOM,
|
|
6
|
+
getColumnCells,
|
|
7
|
+
getIndexCoordinates,
|
|
8
|
+
getRowCells,
|
|
9
|
+
getRowOrColumnCells,
|
|
10
|
+
getTable,
|
|
11
|
+
getTableFromDOM,
|
|
12
|
+
getTableSelectionType,
|
|
13
|
+
isCellEmpty,
|
|
14
|
+
isCellMerged,
|
|
15
|
+
isTableNode,
|
|
16
|
+
rectEq,
|
|
17
|
+
selectCellsByCoords,
|
|
18
|
+
setCellAttr,
|
|
19
|
+
updateSelectionAfterAction
|
|
20
|
+
} from "../chunk-5B5XIL2G.mjs";
|
|
21
|
+
import "../chunk-WKV76XOR.mjs";
|
|
22
|
+
export {
|
|
23
|
+
cellsOverlapRectangle,
|
|
24
|
+
domCellAround,
|
|
25
|
+
getCellIndicesFromDOM,
|
|
26
|
+
getColumnCells,
|
|
27
|
+
getIndexCoordinates,
|
|
28
|
+
getRowCells,
|
|
29
|
+
getRowOrColumnCells,
|
|
30
|
+
getTable,
|
|
31
|
+
getTableFromDOM,
|
|
32
|
+
getTableSelectionType,
|
|
33
|
+
isCellEmpty,
|
|
34
|
+
isCellMerged,
|
|
35
|
+
isTableNode,
|
|
36
|
+
rectEq,
|
|
37
|
+
selectCellsByCoords,
|
|
38
|
+
setCellAttr,
|
|
39
|
+
updateSelectionAfterAction
|
|
40
|
+
};
|
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
declare const messages: {
|
|
2
|
+
row_actions: {
|
|
3
|
+
id: string;
|
|
4
|
+
defaultMessage: string;
|
|
5
|
+
description: string;
|
|
6
|
+
};
|
|
7
|
+
column_actions: {
|
|
8
|
+
id: string;
|
|
9
|
+
defaultMessage: string;
|
|
10
|
+
description: string;
|
|
11
|
+
};
|
|
12
|
+
cell_options: {
|
|
13
|
+
id: string;
|
|
14
|
+
defaultMessage: string;
|
|
15
|
+
description: string;
|
|
16
|
+
};
|
|
17
|
+
alignment: {
|
|
18
|
+
id: string;
|
|
19
|
+
defaultMessage: string;
|
|
20
|
+
description: string;
|
|
21
|
+
};
|
|
22
|
+
align_left: {
|
|
23
|
+
id: string;
|
|
24
|
+
defaultMessage: string;
|
|
25
|
+
description: string;
|
|
26
|
+
};
|
|
27
|
+
align_center: {
|
|
28
|
+
id: string;
|
|
29
|
+
defaultMessage: string;
|
|
30
|
+
description: string;
|
|
31
|
+
};
|
|
32
|
+
align_right: {
|
|
33
|
+
id: string;
|
|
34
|
+
defaultMessage: string;
|
|
35
|
+
description: string;
|
|
36
|
+
};
|
|
37
|
+
justify: {
|
|
38
|
+
id: string;
|
|
39
|
+
defaultMessage: string;
|
|
40
|
+
description: string;
|
|
41
|
+
};
|
|
42
|
+
align_top: {
|
|
43
|
+
id: string;
|
|
44
|
+
defaultMessage: string;
|
|
45
|
+
description: string;
|
|
46
|
+
};
|
|
47
|
+
align_middle: {
|
|
48
|
+
id: string;
|
|
49
|
+
defaultMessage: string;
|
|
50
|
+
description: string;
|
|
51
|
+
};
|
|
52
|
+
align_bottom: {
|
|
53
|
+
id: string;
|
|
54
|
+
defaultMessage: string;
|
|
55
|
+
description: string;
|
|
56
|
+
};
|
|
57
|
+
insert_row_above: {
|
|
58
|
+
id: string;
|
|
59
|
+
defaultMessage: string;
|
|
60
|
+
description: string;
|
|
61
|
+
};
|
|
62
|
+
insert_row_below: {
|
|
63
|
+
id: string;
|
|
64
|
+
defaultMessage: string;
|
|
65
|
+
description: string;
|
|
66
|
+
};
|
|
67
|
+
insert_column_left: {
|
|
68
|
+
id: string;
|
|
69
|
+
defaultMessage: string;
|
|
70
|
+
description: string;
|
|
71
|
+
};
|
|
72
|
+
insert_column_right: {
|
|
73
|
+
id: string;
|
|
74
|
+
defaultMessage: string;
|
|
75
|
+
description: string;
|
|
76
|
+
};
|
|
77
|
+
delete_row: {
|
|
78
|
+
id: string;
|
|
79
|
+
defaultMessage: string;
|
|
80
|
+
description: string;
|
|
81
|
+
};
|
|
82
|
+
delete_column: {
|
|
83
|
+
id: string;
|
|
84
|
+
defaultMessage: string;
|
|
85
|
+
description: string;
|
|
86
|
+
};
|
|
87
|
+
move_row_up: {
|
|
88
|
+
id: string;
|
|
89
|
+
defaultMessage: string;
|
|
90
|
+
description: string;
|
|
91
|
+
};
|
|
92
|
+
move_row_down: {
|
|
93
|
+
id: string;
|
|
94
|
+
defaultMessage: string;
|
|
95
|
+
description: string;
|
|
96
|
+
};
|
|
97
|
+
move_column_left: {
|
|
98
|
+
id: string;
|
|
99
|
+
defaultMessage: string;
|
|
100
|
+
description: string;
|
|
101
|
+
};
|
|
102
|
+
move_column_right: {
|
|
103
|
+
id: string;
|
|
104
|
+
defaultMessage: string;
|
|
105
|
+
description: string;
|
|
106
|
+
};
|
|
107
|
+
sort_row_asc: {
|
|
108
|
+
id: string;
|
|
109
|
+
defaultMessage: string;
|
|
110
|
+
description: string;
|
|
111
|
+
};
|
|
112
|
+
sort_row_desc: {
|
|
113
|
+
id: string;
|
|
114
|
+
defaultMessage: string;
|
|
115
|
+
description: string;
|
|
116
|
+
};
|
|
117
|
+
sort_column_asc: {
|
|
118
|
+
id: string;
|
|
119
|
+
defaultMessage: string;
|
|
120
|
+
description: string;
|
|
121
|
+
};
|
|
122
|
+
sort_column_desc: {
|
|
123
|
+
id: string;
|
|
124
|
+
defaultMessage: string;
|
|
125
|
+
description: string;
|
|
126
|
+
};
|
|
127
|
+
duplicate_row: {
|
|
128
|
+
id: string;
|
|
129
|
+
defaultMessage: string;
|
|
130
|
+
description: string;
|
|
131
|
+
};
|
|
132
|
+
duplicate_column: {
|
|
133
|
+
id: string;
|
|
134
|
+
defaultMessage: string;
|
|
135
|
+
description: string;
|
|
136
|
+
};
|
|
137
|
+
header_row: {
|
|
138
|
+
id: string;
|
|
139
|
+
defaultMessage: string;
|
|
140
|
+
description: string;
|
|
141
|
+
};
|
|
142
|
+
header_column: {
|
|
143
|
+
id: string;
|
|
144
|
+
defaultMessage: string;
|
|
145
|
+
description: string;
|
|
146
|
+
};
|
|
147
|
+
merge_cells: {
|
|
148
|
+
id: string;
|
|
149
|
+
defaultMessage: string;
|
|
150
|
+
description: string;
|
|
151
|
+
};
|
|
152
|
+
split_cell: {
|
|
153
|
+
id: string;
|
|
154
|
+
defaultMessage: string;
|
|
155
|
+
description: string;
|
|
156
|
+
};
|
|
157
|
+
clear_row_contents: {
|
|
158
|
+
id: string;
|
|
159
|
+
defaultMessage: string;
|
|
160
|
+
description: string;
|
|
161
|
+
};
|
|
162
|
+
clear_column_contents: {
|
|
163
|
+
id: string;
|
|
164
|
+
defaultMessage: string;
|
|
165
|
+
description: string;
|
|
166
|
+
};
|
|
167
|
+
clear_contents: {
|
|
168
|
+
id: string;
|
|
169
|
+
defaultMessage: string;
|
|
170
|
+
description: string;
|
|
171
|
+
};
|
|
172
|
+
};
|
|
173
|
+
|
|
174
|
+
export { messages };
|