simple-table-core 4.2.0 → 4.2.2
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/cjs/index.js +1 -1
- package/dist/core/dom/DOMManager.d.ts +2 -0
- package/dist/core/initialization/TableInitializer.d.ts +1 -0
- package/dist/core/rendering/TableRenderer.d.ts +2 -0
- package/dist/core/vanilla/VanillaLiveHost.d.ts +5 -2
- package/dist/index.es.js +1 -1
- package/dist/types/ColumnEditorConfig.d.ts +4 -2
- package/dist/utils/headerCell/resizing.d.ts +2 -0
- package/dist/utils/headerCell/styling.d.ts +2 -0
- package/dist/utils/resizeUtils/autoExpandResize.d.ts +3 -3
- package/package.json +1 -1
|
@@ -25,6 +25,8 @@ export interface ColumnEditorConfig {
|
|
|
25
25
|
searchEnabled?: boolean;
|
|
26
26
|
/** Placeholder text for the search input (default: "Search columns...") */
|
|
27
27
|
searchPlaceholder?: string;
|
|
28
|
+
/** Label for the reset-columns button (default: "Reset columns") */
|
|
29
|
+
resetText?: string;
|
|
28
30
|
/** Custom search function to override default search behavior. Receives header and searchTerm, returns true if header matches. */
|
|
29
31
|
searchFunction?: ColumnEditorSearchFunction;
|
|
30
32
|
/**
|
|
@@ -38,5 +40,5 @@ export interface ColumnEditorConfig {
|
|
|
38
40
|
customRenderer?: ColumnEditorCustomRenderer;
|
|
39
41
|
}
|
|
40
42
|
export declare const DEFAULT_COLUMN_EDITOR_CONFIG: Required<Omit<ColumnEditorConfig, "searchFunction" | "rowRenderer" | "customRenderer">>;
|
|
41
|
-
/** Column editor config with defaults applied
|
|
42
|
-
export type MergedColumnEditorConfig = Required<Pick<ColumnEditorConfig, "text" | "showToggle" | "searchEnabled" | "searchPlaceholder" | "allowColumnPinning">> & Pick<ColumnEditorConfig, "searchFunction" | "rowRenderer" | "customRenderer">;
|
|
43
|
+
/** Column editor config with defaults applied */
|
|
44
|
+
export type MergedColumnEditorConfig = Required<Pick<ColumnEditorConfig, "text" | "showToggle" | "searchEnabled" | "searchPlaceholder" | "resetText" | "allowColumnPinning">> & Pick<ColumnEditorConfig, "searchFunction" | "rowRenderer" | "customRenderer">;
|
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
import ColumnDef from "../../types/ColumnDef";
|
|
2
2
|
import { HeaderRenderContext } from "./types";
|
|
3
3
|
export declare const createResizeHandle: (header: ColumnDef, context: HeaderRenderContext) => HTMLElement | null;
|
|
4
|
+
/** Add or remove the resize handle to match `columnResizing`. */
|
|
5
|
+
export declare const syncResizeHandle: (cellElement: HTMLElement, header: ColumnDef, context: HeaderRenderContext) => void;
|
|
@@ -4,5 +4,7 @@ export declare const createHeaderCellElement: (cell: AbsoluteCell, context: Head
|
|
|
4
4
|
export declare const getLastHeaderIndex: (absoluteCells: AbsoluteCell[]) => number;
|
|
5
5
|
/** Replace sort/filter/collapse icons on an existing header cell, preserving label/drag handlers. */
|
|
6
6
|
export declare const refreshHeaderCellIcons: (cellElement: HTMLElement, header: AbsoluteCell["header"], context: HeaderRenderContext, colIndex: number) => void;
|
|
7
|
+
/** Set or clear the label's draggable attribute from `columnReordering`. */
|
|
8
|
+
export declare const syncHeaderDragAttribute: (cellElement: HTMLElement, header: AbsoluteCell["header"], context: HeaderRenderContext) => void;
|
|
7
9
|
/** Keep a reused header cell in sync with the current column definition. */
|
|
8
10
|
export declare const syncHeaderCellLabel: (cellElement: HTMLElement, header: AbsoluteCell["header"], context: HeaderRenderContext, colIndex: number) => void;
|
|
@@ -7,9 +7,9 @@ import type { Pinned } from "../../types/Pinned";
|
|
|
7
7
|
* natural width — declared, content-measured, or user-set). Once all
|
|
8
8
|
* neighbors are at their floor, the main section keeps growing past the
|
|
9
9
|
* container width and overflows into horizontal scroll instead of blocking
|
|
10
|
-
* the drag.
|
|
11
|
-
*
|
|
12
|
-
*
|
|
10
|
+
* the drag. A pinned column that still has leftover delta grows the pinned
|
|
11
|
+
* strip itself (policy-capped), not only when it is the column next to the
|
|
12
|
+
* main grid.
|
|
13
13
|
*/
|
|
14
14
|
export declare const handleResizeWithAutoExpand: ({ childrenToResize, collapsedHeaders, containerWidth, delta, headers, initialWidthsMap, isParentResize, resizedHeader, reverse, rootPinned, sectionHeaders, sectionWidth, sectionViewportWidth, shrinkFloors, startWidth, }: {
|
|
15
15
|
childrenToResize?: ColumnDef[];
|