arthub-table 0.2.48 → 0.2.49-next.1
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/arthub-table.common.js +1 -1
- package/dist/arthub-table.common.js.map +1 -1
- package/dist/arthub-table.umd.js +1 -1
- package/dist/arthub-table.umd.js.map +1 -1
- package/dist/arthub-table.umd.min.js +1 -1
- package/dist/arthub-table.umd.min.js.map +1 -1
- package/dist/types/core/NestedGrid.d.ts +17 -0
- package/dist/types/core/viewers/TextViewerWithSwitcher.d.ts +0 -12
- package/dist/types/testing/TestHooks.d.ts +0 -6
- package/package.json +1 -1
|
@@ -209,6 +209,23 @@ declare class NestedGrid {
|
|
|
209
209
|
parentColKey: string;
|
|
210
210
|
};
|
|
211
211
|
} | null;
|
|
212
|
+
/**
|
|
213
|
+
* 处理 hover tooltip 事件,返回 tooltip 信息
|
|
214
|
+
* 用于外层 NestedGridViewer.getTooltip 事件穿透,代理调用内层 cell 的 viewer.getTooltip
|
|
215
|
+
*
|
|
216
|
+
* @param mouseX 鼠标相对于嵌套表格左上角的 X 坐标
|
|
217
|
+
* @param mouseY 鼠标相对于嵌套表格左上角的 Y 坐标
|
|
218
|
+
* @returns tooltip 信息(相对于嵌套表格左上角的 bounds),未命中或内层 viewer 无 getTooltip 时返回 null
|
|
219
|
+
*/
|
|
220
|
+
getTooltipAtPosition(mouseX: number, mouseY: number): {
|
|
221
|
+
text: string;
|
|
222
|
+
bounds: {
|
|
223
|
+
x: number;
|
|
224
|
+
y: number;
|
|
225
|
+
width: number;
|
|
226
|
+
height: number;
|
|
227
|
+
};
|
|
228
|
+
} | null;
|
|
212
229
|
/**
|
|
213
230
|
* Handle double-click inside nested grid.
|
|
214
231
|
* Delegates to viewer.onDblClick (e.g. FileViewer opens file detail on dblclick).
|
|
@@ -23,18 +23,6 @@ declare class TextViewerWithSwitcher implements CellViewer<TextViewerWithSwitche
|
|
|
23
23
|
private _sm;
|
|
24
24
|
private arrowColoredCanvas;
|
|
25
25
|
private arrowColoredColor;
|
|
26
|
-
/**
|
|
27
|
-
* 每个 cell 文本绘制几何缓存(用于 getTooltip 中判定文本溢出 → 新通路 onCellOverflowHover)。
|
|
28
|
-
* - Key: `${rowIndex}-${colIndex}`
|
|
29
|
-
* - Value: { textStartX, y, availableWidth, height, fontSize }
|
|
30
|
-
* - textStartX / y 是 drawText 调用时的绝对画布坐标(与 cell.x / cell.y 不同)
|
|
31
|
-
* - availableWidth 是 drawText 入参,等于 cell 内文字区域的可用宽度
|
|
32
|
-
*
|
|
33
|
-
* 写入:draw() 调用 drawText 之后写入
|
|
34
|
-
* 读取:getTooltip 命中文本区域时按需用 ctx.measureText 临时判定是否溢出
|
|
35
|
-
* 清理策略:依赖 draw 每次重绘自动覆盖同 key,不主动清理。
|
|
36
|
-
*/
|
|
37
|
-
private _textGeometryCache;
|
|
38
26
|
constructor();
|
|
39
27
|
/**
|
|
40
28
|
* Preload SVG icons
|
|
@@ -213,12 +213,6 @@ export interface TestHooksAPI {
|
|
|
213
213
|
* @returns Row data object or null if not found
|
|
214
214
|
*/
|
|
215
215
|
getRowData: (rowId: string | number) => Record<string, any> | null;
|
|
216
|
-
/**
|
|
217
|
-
* 返回当前 body.data 的浅拷贝(视觉顺序),每项含 id / nodeId / name。
|
|
218
|
-
* 用于 e2e 在视觉顺序下批量获取主任务 rowId(pipeline-count-display 等场景)。
|
|
219
|
-
* 不存在 body.data 时回退到 _fullData。
|
|
220
|
-
*/
|
|
221
|
-
getDataRows: () => Array<Record<string, any>>;
|
|
222
216
|
/**
|
|
223
217
|
* 获取组头行搜索命中高亮状态。
|
|
224
218
|
*
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "arthub-table",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.49-next.1",
|
|
4
4
|
"description": "High-performance canvas-based table/grid component for Vue 3 with TypeScript support, featuring virtual scrolling, cell viewers, grouped rows, and nested grids.",
|
|
5
5
|
"main": "dist/arthub-table.common.js",
|
|
6
6
|
"module": "dist/arthub-table.umd.min.js",
|