fix(grid): preserve selection across column reordering
This commit is contained in:
1 parent
b406c0a52c
commit
d63a407931
4 files changed
+189
-18
No files matched your search
+12
@@ -0,0 +1,12 @@
|
||||
import { readFileSync } from "node:fs";
|
||||
import { describe, expect, it } from "vitest";
|
||||
|
||||
const dataGridSource = readFileSync(new URL("../DataGrid.vue", import.meta.url), "utf8");
|
||||
|
||||
describe("DataGrid synchronized column order selection", () => {
|
||||
it("reconciles the active selection when another grid changes the table order", () => {
|
||||
expect(dataGridSource).toContain("applyColumnOrderChange(() => onTableDataGridColumnOrderChanged(event));");
|
||||
expect(dataGridSource).toContain("window.addEventListener(TABLE_DATA_GRID_COLUMN_ORDER_CHANGED_EVENT, onSynchronizedTableDataGridColumnOrderChanged);");
|
||||
expect(dataGridSource).toContain("window.removeEventListener(TABLE_DATA_GRID_COLUMN_ORDER_CHANGED_EVENT, onSynchronizedTableDataGridColumnOrderChanged);");
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user