@restio/ui 0.2.1-20260917153719 → 0.2.1-20261007123729

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/index.d.ts CHANGED
@@ -314,12 +314,8 @@ declare const OverlayPanelHeader: React__default.FC<OverlayPanelHeaderProps>;
314
314
  /** OverlayPanelPosition defines the possible positions for the OverlayPanel. */
315
315
  type OverlayPanelPosition = "center" | "left" | "right" | "top" | "bottom";
316
316
  /**
317
- * OverlayPanelVariant defines the visual and behavioral variant for the OverlayPanel.
318
- * - "modal": Center modal with backdrop, traps focus, blocks interaction.
319
- * - "dialog": Center dialog, lighter backdrop, may allow outside click to close.
320
- * - "sidepanel": Left/right slide-in panel, typically with backdrop.
321
- * - "drawer": Mobile-friendly drawer, usually slides from bottom or side.
322
- * - "popover": Light overlay, anchored to element, minimal/no backdrop.
317
+ * Visual and behavioral variant: "modal", "dialog", "sidepanel", "drawer", or
318
+ * "popover" (light, anchored, minimal backdrop).
323
319
  */
324
320
  type OverlayPanelVariant = "modal" | "dialog" | "sidepanel" | "drawer" | "popover";
325
321
  /** Props for the OverlayPanel component.*/
@@ -668,8 +664,7 @@ declare const DatePicker: React__default.FC<DatePickerProps>;
668
664
 
669
665
  /**
670
666
  * Date range picker supporting day, month, quarter, and year modes.
671
- * Shows two calendars side-by-side for range selection.
672
- * Clicking once sets the start date; clicking again sets the end date.
667
+ * Two calendars select the range: the first click sets the start, the second the end.
673
668
  */
674
669
  declare const DateRangePicker: React__default.FC<DateRangePickerProps>;
675
670
 
@@ -847,29 +842,8 @@ interface ShortcutProviderProps {
847
842
  readonly children: React__default.ReactNode;
848
843
  }
849
844
  /**
850
- * ShortcutProvider manages global keyboard shortcuts and displays visual feedback tooltips.
851
- *
852
- * Features:
853
- * - Global and component-scoped shortcuts
854
- * - Visual feedback with tooltips appearing near cursor
855
- * - Hold-to-execute shortcuts with progress indicators (3s default)
856
- * - Automatic cleanup of component-scoped shortcuts
857
- * - Key release detection for cancelling hold shortcuts
858
- *
859
- * How it works:
860
- * 1. Maintains a map of registered shortcuts with their configurations
861
- * 2. Tracks active components for scoping validation
862
- * 3. Listens for keyboard events and matches against registered shortcuts
863
- * 4. Shows tooltip with shortcut keys and function name near cursor
864
- * 5. Executes actions only after full hold duration (for hold shortcuts)
865
- * 6. Cancels hold shortcuts when any key is released
866
- *
867
- * Component Scoping:
868
- * - Global shortcuts (no componentId) always available
869
- * - Component shortcuts only trigger when their component is registered as active
870
- * - Components auto-register/unregister through useShortcut hook focus/hover handlers
871
- *
872
- * @param children - Child components that will have access to shortcut context
845
+ * Manages global and per-component keyboard shortcuts and shows the cursor-anchored
846
+ * feedback tooltip, including progress for hold-to-execute shortcuts (3s default).
873
847
  */
874
848
  declare const ShortcutProvider: React__default.FC<ShortcutProviderProps>;
875
849
 
@@ -889,9 +863,7 @@ interface ShortcutConfig {
889
863
  */
890
864
  interface UseShortcutOptions {
891
865
  /**
892
- * Scope of the shortcuts:
893
- * - 'component': Shortcuts only work when this component is focused or hovered
894
- * - 'global': Shortcuts work globally across the application
866
+ * Scope of the shortcuts: 'global' works app-wide, 'component' only when focused or hovered.
895
867
  */
896
868
  scope?: 'global' | 'component';
897
869
  /** Whether shortcuts are enabled */
@@ -931,9 +903,8 @@ interface UseDynamicVirtualListOptions {
931
903
  /** Fallback height used for items that have not been measured yet */
932
904
  estimatedItemHeight?: number;
933
905
  /**
934
- * Extra items rendered above and below the visible viewport.
935
- * A larger value makes scrolling smoother at the cost of slightly more DOM nodes.
936
- * Defaults to 10.
906
+ * Extra items rendered above and below the viewport. Higher values scroll more
907
+ * smoothly at the cost of more DOM nodes. Defaults to 10.
937
908
  */
938
909
  overscan?: number;
939
910
  }
@@ -963,14 +934,10 @@ interface UseDynamicVirtualListResult {
963
934
  scrollTop: number;
964
935
  }
965
936
  /**
966
- * A dynamic-height virtual list hook inspired by TanStack Virtual.
967
- *
968
- * Unlike fixed-height virtualizers, this hook uses a ResizeObserver to measure
969
- * each rendered item's actual height and falls back to `estimatedItemHeight` for
970
- * items that have not yet been rendered. This allows rows with variable content
971
- * (wrapped text, expandable cells, group headers) to scroll correctly.
937
+ * Dynamic-height virtual list hook: measures every rendered item with a ResizeObserver
938
+ * and falls back to `estimatedItemHeight`, so variable-height rows scroll correctly.
972
939
  *
973
- * Usage:
940
+ * @example
974
941
  * ```tsx
975
942
  * const { virtualItems, totalSize, containerRef, onScroll, measureElement } =
976
943
  * useDynamicVirtualList({ count: rows.length, estimatedItemHeight: 40, overscan: 10 });
@@ -991,9 +958,6 @@ interface UseDynamicVirtualListResult {
991
958
  * </div>
992
959
  * );
993
960
  * ```
994
- *
995
- * For table usage, pair with padding `<tr>` spacers at the top and bottom of
996
- * `<tbody>` and attach `measureElement` to each `<tr>` via a ref callback.
997
961
  */
998
962
  declare function useDynamicVirtualList({ count, estimatedItemHeight, overscan, }: UseDynamicVirtualListOptions): UseDynamicVirtualListResult;
999
963
 
@@ -1062,9 +1026,8 @@ type LayoutProps = {
1062
1026
  };
1063
1027
 
1064
1028
  /**
1065
- * Maps each CellType to the component-specific props that can be passed
1066
- * via `uiVariant` in a rule. TypeScript enforces that you only pass props
1067
- * the underlying component actually understands.
1029
+ * Maps each CellType to the component props accepted by `uiVariant`, so TypeScript
1030
+ * only allows props the underlying component understands.
1068
1031
  */
1069
1032
  type CellUIVariantMap = {
1070
1033
  [K in CellType]: K extends "IMAGE" ? Partial<Omit<IconProps, "src">> : K extends "TAG" ? Partial<{
@@ -1094,10 +1057,8 @@ type LookupCellType<TData, TColumns extends readonly DataStructureColumn<TData>[
1094
1057
  /** Comparison operators for AST-like UI rules */
1095
1058
  type UIRuleOperator = "==" | "!=" | ">" | ">=" | "<" | "<=" | "includes" | "startsWith" | "endsWith" | "isEmpty" | "isNotEmpty";
1096
1059
  /**
1097
- * A single declarative styling rule evaluated against a row.
1098
- * Rules are compiled once into fast evaluators — no runtime functions.
1099
- *
1100
- * When `field` and `op` are omitted, the rule always matches (static styling).
1060
+ * A declarative styling rule evaluated against a row, compiled once into a fast
1061
+ * evaluator. Omitting `field` and `op` makes it a static rule that always matches.
1101
1062
  *
1102
1063
  * @example conditional
1103
1064
  * { field: "price", op: ">", value: 100, uiVariant: { color: "var(--rst-color-success)", fontWeight: "bold" } }
@@ -1182,17 +1143,13 @@ interface DataStructureColumn<TData, TValue = TData[keyof TData]> {
1182
1143
  /** Helper text shown below the field (e.g. "Opzionale", "Usa +/− per il segno"). */
1183
1144
  helperText?: string;
1184
1145
  /**
1185
- * Generic column-level configuration for the target component.
1186
- * Mirrors the uiConfig pattern: carries the props of the component
1187
- * referenced by `cellType` (e.g. ChartProps for CHART, TableGridProps for TABLE_GRID).
1188
- * `data` and `columns` are excluded — they come from the cell value and schema.
1146
+ * Column-level config for the component named by `cellType` (e.g. ChartProps for
1147
+ * CHART). `data` and `columns` are excluded — they come from the cell value and schema.
1189
1148
  */
1190
1149
  columnConfig?: Record<string, unknown>;
1191
1150
  /**
1192
- * Called when an interactive cell (e.g. BUTTON, IMAGE click) fires an action.
1193
- * The cell handler decides when to invoke it; the first argument is the
1194
- * action id (for BUTTON = `option.value`). Works in any data-component
1195
- * that renders Cell in display mode (CardList, TableGrid, …).
1151
+ * Called when an interactive cell (e.g. BUTTON) fires an action; the first argument
1152
+ * is the action id (for BUTTON, `option.value`).
1196
1153
  */
1197
1154
  onCellClick?: (actionId: string, rowData: TData, column: DataStructureColumn<TData, TValue>) => void;
1198
1155
  }
@@ -1239,10 +1196,8 @@ declare namespace Card {
1239
1196
  }
1240
1197
 
1241
1198
  /**
1242
- * Per-series row of the composed-series matrix.
1243
- * `column` references a Y-axis data column by id/accessor;
1244
- * `type` decides which cartesian primitive (line/bar/area/scatter) renders;
1245
- * `color` is optional — falls back to the chart palette when omitted.
1199
+ * Per-series row of the composed matrix: `column` names the Y-axis data column,
1200
+ * `type` the cartesian primitive, `color` an optional override for the palette.
1246
1201
  */
1247
1202
  interface ChartSeriesConfig<TData = Record<string, unknown>> {
1248
1203
  column: keyof TData | string;
@@ -1250,11 +1205,8 @@ interface ChartSeriesConfig<TData = Record<string, unknown>> {
1250
1205
  color?: string;
1251
1206
  }
1252
1207
  /**
1253
- * Configuration for Sankey charts.
1254
- * stageColumns: ordered list of columns that define the flow stages (min 2).
1255
- * - Null/undefined/empty values in a row are skipped, creating a direct link
1256
- * between the nearest non-empty columns on both sides.
1257
- * valueColumn: numeric column used as the flow weight.
1208
+ * Sankey chart config. `stageColumns` lists the ordered flow stages (min 2); empty
1209
+ * values are skipped, linking the nearest non-empty stages on either side.
1258
1210
  *
1259
1211
  * @example 2-level (source → target)
1260
1212
  * { stageColumns: ["from", "to"], valueColumn: "amount" }
@@ -1267,11 +1219,8 @@ interface SankeyConfig<TData> {
1267
1219
  valueColumn: keyof TData;
1268
1220
  }
1269
1221
  /**
1270
- * Configuration for Geo charts.
1271
- * geoJson: GeoJSON FeatureCollection with MultiPolygon geometry.
1272
- * regionColumn: column in TData that maps to the "name" property in geoJson features.
1273
- * valueColumn: numeric column used for the choropleth color scale.
1274
- * colorRange: [minColor, maxColor] — two CSS color strings for the gradient.
1222
+ * Geo (choropleth) chart config: GeoJSON features matched to `regionColumn`,
1223
+ * with `valueColumn` driving the colour scale and `colorRange` as its endpoints.
1275
1224
  */
1276
1225
  interface GeoConfig<TData> {
1277
1226
  geoJson: {
@@ -1307,11 +1256,8 @@ interface ChartSpecificProps<TData> {
1307
1256
  /** Custom colors for chart series */
1308
1257
  colors?: string[];
1309
1258
  /**
1310
- * Per-series matrix used when type === "composed" (Cartesian-only mixes:
1311
- * line + bar + area + scatter). For the single-type cartesian types
1312
- * (line/bar/area/scatter), the matrix is derived from yAxisColumns and
1313
- * every entry adopts `type` — so the prop form only needs to manage one
1314
- * matrix for all cartesian charts. Ignored for pie/sankey/sparkline/geo.
1259
+ * Per-series matrix for "composed" cartesian charts (line + bar + area + scatter).
1260
+ * Single-type cartesian charts derive it from `yAxisColumns`; ignored for pie/sankey/sparkline/geo.
1315
1261
  */
1316
1262
  series?: ChartSeriesConfig<TData>[];
1317
1263
  /** Show/hide chart elements */
@@ -1413,20 +1359,13 @@ interface ChatMessage {
1413
1359
 
1414
1360
  type GanttView = "year" | "month" | "week" | "day";
1415
1361
  /**
1416
- * Relation types:
1417
- * - FS (Finish-to-Start): arrow from end of predecessor to start of successor
1418
- * - SS (Start-to-Start): arrow from start of predecessor to start of successor
1419
- * - FF (Finish-to-Finish): arrow from end of predecessor to end of successor
1420
- * - SF (Start-to-Finish): arrow from start of predecessor to end of successor
1362
+ * Dependency relation types: FS (finish→start), SS (start→start), FF (finish→finish)
1363
+ * and SF (start→finish).
1421
1364
  */
1422
1365
  type GanttRelationType = "FS" | "SS" | "FF" | "SF";
1423
1366
  /**
1424
- * A single dependency descriptor.
1425
- * The `dependencyColumnId` field on each row can resolve to:
1426
- * - `string` — single dependency ID (defaults to "FS")
1427
- * - `string[]` — multiple dependency IDs (all default to "FS")
1428
- * - `GanttDependency` — single dependency with explicit type
1429
- * - `GanttDependency[]` — multiple dependencies with explicit types
1367
+ * A single dependency descriptor. A row's `dependencyColumnId` may resolve to a string,
1368
+ * string[], `GanttDependency`, or `GanttDependency[]` (strings default to "FS").
1430
1369
  */
1431
1370
  interface GanttDependency {
1432
1371
  id: string;
@@ -1490,10 +1429,8 @@ interface PivotValueField {
1490
1429
  label?: string;
1491
1430
  }
1492
1431
  /**
1493
- * Configuration for pivot mode.
1494
- * rowFields: column IDs whose values form the row groups.
1495
- * columnFields: column IDs whose unique values become dynamic columns.
1496
- * valueFields: numeric fields to aggregate at each row × column intersection.
1432
+ * Pivot config: `rowFields` form the row groups, `columnFields` become dynamic columns,
1433
+ * and `valueFields` are aggregated at each intersection.
1497
1434
  */
1498
1435
  interface PivotConfig {
1499
1436
  rowFields: string[];
@@ -1581,15 +1518,8 @@ interface OperatorOption {
1581
1518
  }
1582
1519
 
1583
1520
  /**
1584
- * Row model switch and feature-by-model registry.
1585
- *
1586
- * Single source of truth binding each grid feature to the row models that
1587
- * support it. The registry makes explicit what runs where:
1588
- * - "client" — feature executes in the browser on the full dataset
1589
- * - "server" — feature executes on the server
1590
- * - "server-only" — server-mandatory when rowModel="server"; client otherwise
1591
- * - "dual" — runs in both, where is user-decidable
1592
- * - "blocked-on-server" — cannot work server-side (UI disabled + dev warning)
1521
+ * Row model switch and feature-by-model registry: single source of truth binding each grid
1522
+ * feature to the models that support it (client, server, server-only, dual, blocked-on-server).
1593
1523
  */
1594
1524
  /** All row models the grid supports. */
1595
1525
  declare const TableRowModel: {
@@ -1708,9 +1638,8 @@ interface TableGridSpecificProps<TData> {
1708
1638
  /** Height of each row in pixels (required for virtualization) */
1709
1639
  virtualizedRowHeight?: number;
1710
1640
  /**
1711
- * Height of the scrollable container in pixels. Required when virtualization
1712
- * is enabled; optional otherwise — without it the container grows with its
1713
- * content (fill mode in a flex parent).
1641
+ * Scrollable container height in pixels. Required with virtualization; otherwise the
1642
+ * container grows with its content (fill mode in a flex parent).
1714
1643
  */
1715
1644
  containerHeight?: number;
1716
1645
  /** When true, cells keep a fixed single-line height; overflowing content is clipped. */
@@ -1730,9 +1659,8 @@ interface TableGridSpecificProps<TData> {
1730
1659
  /** Enable the formula builder — shows the formula icon in the right toolbar */
1731
1660
  enableFormulaBuilder?: boolean;
1732
1661
  /**
1733
- * Controls how column widths are calculated.
1734
- * - `"auto"` (default): columns share the available width; `size` is ignored.
1735
- * - `"fixed"`: each column uses its `size` value; the table scrolls horizontally when the total exceeds the container.
1662
+ * How column widths are calculated: "auto" shares the available width (ignoring `size`),
1663
+ * "fixed" uses each column's `size` and scrolls horizontally when the total overflows.
1736
1664
  */
1737
1665
  columnSizing?: "auto" | "fixed";
1738
1666
  /** Show loading skeleton state while data is being fetched */
@@ -1752,21 +1680,18 @@ interface TableGridSpecificProps<TData> {
1752
1680
  /** Pre-configured action buttons shown in the AI chat panel for one-click commands */
1753
1681
  aiQuickActions?: AIQuickAction[];
1754
1682
  /**
1755
- * Called whenever a new formula column is created (via the builder or AI).
1756
- * Use this to persist the column definition on your server so it can be
1757
- * re-supplied via the `columns` prop on the next load.
1683
+ * Called when a new formula column is created (builder or AI). Persist the definition
1684
+ * on your server so it can be re-supplied via `columns` on the next load.
1758
1685
  */
1759
1686
  onFormulaColumnAdd?: (col: ColumnDef<TData>) => void;
1760
1687
  /**
1761
- * Forwarded to the inner scroll container (`rst-table-container`).
1762
- * Allows an external component to react to scroll events from the table body.
1763
- * Works for both virtualized and non-virtualized modes.
1688
+ * Forwarded to the inner scroll container (`rst-table-container`), so an external
1689
+ * component can react to scroll events. Works in both row models.
1764
1690
  */
1765
1691
  onScroll?: UIEventHandler<HTMLDivElement>;
1766
1692
  /**
1767
- * Ref forwarded to the inner scroll container (`rst-table-container`).
1768
- * Allows an external component to programmatically read or set `scrollTop`.
1769
- * Works for both virtualized and non-virtualized modes.
1693
+ * Ref to the inner scroll container (`rst-table-container`), so an external component
1694
+ * can read or set `scrollTop`. Works in both row models.
1770
1695
  */
1771
1696
  scrollContainerRef?: Ref<HTMLDivElement>;
1772
1697
  }
@@ -1786,10 +1711,8 @@ type TableGridProps<TData> = DataStructureComponent<TData> & TableGridSpecificPr
1786
1711
  /** Global row-model switch — decides where each data-pipeline feature runs. Default "client". See `TableRowModel`. */
1787
1712
  rowModel?: TableRowModel;
1788
1713
  /**
1789
- * Pagination — a theme fully orthogonal to the row model: client pages slice
1790
- * the in-memory data, server pages ask the datasource for the page window
1791
- * (request.range = [pageStart, pageEnd)). Only honored when virtualization
1792
- * is disabled (mutually exclusive). Defaults to off.
1714
+ * Pagination — orthogonal to the row model: client pages slice in-memory data, server
1715
+ * pages fetch a window. Honored only when virtualization is off. Defaults to off.
1793
1716
  */
1794
1717
  pagination?: TableGridPagination;
1795
1718
  } & TableGridServerModelProps<TData>;
@@ -1958,12 +1881,8 @@ interface FormColumnDelta<TData> {
1958
1881
  column: FormColumn<TData>;
1959
1882
  }
1960
1883
  /**
1961
- * Server response to a field change.
1962
- * Only the changed pieces are returned — the form merges them with existing state.
1963
- *
1964
- * - `data`: partial data to merge (e.g. reset dependent fields to null)
1965
- * - `columns`: delta operations on columns (add new dependent fields, update options, remove fields)
1966
- * - `layout`: optional new layout. If omitted, the form recalculates from current columns.
1884
+ * Server response to a field change. Only the changed pieces are returned; the form
1885
+ * merges `data` (partial rows), `columns` (add/update/remove deltas) and optional `layout`.
1967
1886
  */
1968
1887
  interface FormChangeResponse<TData> {
1969
1888
  /** Partial data delta — merged with current formData */
@@ -1989,18 +1908,9 @@ interface FormSpecificProps<TData> {
1989
1908
  /** Custom action buttons rendered in the form footer.*/
1990
1909
  actions?: ButtonProps[];
1991
1910
  /**
1992
- * Server-driven callback invoked on every field change.
1993
- *
1994
- * The server receives the current form state and the changed field,
1995
- * and returns a **partial delta** — only the pieces that changed.
1996
- * The form merges the delta into its state and re-renders only
1997
- * the affected fields.
1911
+ * Server-driven callback invoked on every field change: it receives the form state
1912
+ * and the changed field, and returns the partial delta to merge. Unresolved fields show skeletons.
1998
1913
  *
1999
- * Fields not yet resolved (loading) show a skeleton placeholder.
2000
- *
2001
- * @param formData - Current complete form data
2002
- * @param changedField - The accessorKey of the field that changed
2003
- * @param newValue - The new value of the changed field
2004
1914
  * @returns A partial delta with data, column operations, and optional layout
2005
1915
  */
2006
1916
  onFormChange?: (formData: TData, changedField: keyof TData, newValue: TData[keyof TData]) => Promise<FormChangeResponse<TData>>;
@@ -2201,11 +2111,8 @@ type KPIProps<TData> = Omit<DataStructureComponent<TData>, "data"> & KPISpecific
2201
2111
  declare function KPI<TData>({ data, columns, layout, slotMap, className, uiConfig, onClick }: KPIProps<TData>): React$1.JSX.Element;
2202
2112
 
2203
2113
  /**
2204
- * Shared finance layouts, usable by any component that accepts a
2205
- * `ResponsiveLayout` (Card, KPI, CardList).
2206
- *
2207
- * Field IDs are intentionally generic so they work with any dataset that
2208
- * follows the KPI shape: `label`, `value`, `delta`, `trend`, `icon`.
2114
+ * Shared finance layouts for any component taking a `ResponsiveLayout` (Card, KPI,
2115
+ * CardList). Field IDs are generic: `label`, `value`, `delta`, `trend`, `icon`.
2209
2116
  */
2210
2117
  /**
2211
2118
  * Compact KPI layout: label on top, big value in the middle, delta/trend
@@ -2228,14 +2135,8 @@ interface CardLayoutPreset {
2228
2135
  layout: ResponsiveLayout;
2229
2136
  }
2230
2137
  /**
2231
- * Card layout: icon on the left, name + type next to it, actions right-aligned.
2232
- *
2138
+ * Card layout: icon left, name + type beside it, actions right-aligned.
2233
2139
  * Field IDs: `icon`, `name`, `type`, `actions`.
2234
- *
2235
- * ┌──────────────────────────────────────┐
2236
- * │ icon name actions │
2237
- * │ type │
2238
- * └──────────────────────────────────────┘
2239
2140
  */
2240
2141
  declare const cardLayoutWithIcon: ResponsiveLayout;
2241
2142
  /** Maps a preset id to its `ResponsiveLayout`. Falls back to `undefined`. */
@@ -2249,12 +2150,8 @@ declare const cardLayoutPresetOptions: {
2249
2150
  }[];
2250
2151
 
2251
2152
  /**
2252
- * A registered KPI layout preset.
2253
- *
2254
- * `id` is the value stored in the widget config (and resolved back to a
2255
- * `ResponsiveLayout` at render time by the Switcher). `label` / `description`
2256
- * drive the selector UI; `layout` is the actual tree rendered in the preview
2257
- * and passed to the `KPI` component.
2153
+ * A registered KPI layout preset: `id` is stored in the widget config and resolved
2154
+ * back to a `ResponsiveLayout`; `label` / `description` drive the selector UI.
2258
2155
  */
2259
2156
  interface KpiLayoutPreset {
2260
2157
  id: string;
@@ -2292,14 +2189,8 @@ type ComponentSpecificPropsMap<TData> = {
2292
2189
  "kpi": KPISpecificProps<TData>;
2293
2190
  };
2294
2191
  /**
2295
- * Props for the Switcher component.
2296
- * Accepts the shared DataStructureComponent props plus an optional initial component.
2297
- *
2298
- * Two modes:
2299
- * - **Uncontrolled**: provide `initialComponent` / `initialComponentProps`. Switcher manages its own state.
2300
- * - **Controlled**: provide `activeComponent` / `componentProps`. The parent manages state,
2301
- * and the Switcher reflects changes immediately. Use this when an external configurator
2302
- * (e.g. DashboardBuilder) drives the configuration.
2192
+ * Props for the Switcher, which wraps a data-component and manages its specific props.
2193
+ * Uncontrolled: `initialComponent` / `initialComponentProps`; controlled: `activeComponent` / `componentProps`.
2303
2194
  */
2304
2195
  interface SwitcherProps<TData> extends DataStructureComponent<TData> {
2305
2196
  /** Initial active component. Defaults to "table-grid". (Uncontrolled mode) */
@@ -2319,22 +2210,14 @@ interface SwitcherProps<TData> extends DataStructureComponent<TData> {
2319
2210
  }
2320
2211
 
2321
2212
  /**
2322
- * Switcher — wraps a data-component
2323
- * Shared props (data, columns, uiConfig, getSubRows) are passed to every component.
2324
- * Specific props are managed per-component via the config overlay.
2325
- *
2326
- * Two modes:
2327
- * - **Uncontrolled**: provide `initialComponent` / `initialComponentProps`
2328
- * - **Controlled**: provide `activeComponent` / `componentProps` (external configurator drives state)
2213
+ * Wraps a data-component: shared props (data, columns, uiConfig, getSubRows) go to every
2214
+ * component, specific props are managed via the config overlay. Uncontrolled or controlled.
2329
2215
  */
2330
2216
  declare const Switcher: <TData extends object>({ data, columns, getSubRows, uiConfig, initialComponent, initialComponentProps, activeComponent: controlledComponent, componentProps: controlledProps, showConfigurator, onComponentChange, onComponentPropsChange, }: SwitcherProps<TData>) => React__default.JSX.Element;
2331
2217
 
2332
2218
  /**
2333
- * Where a prop field is configurable.
2334
- * - `"all"`: visible in both Switcher and Dashboard configurator
2335
- * - `"switcher"`: visible only in the Switcher panel
2336
- * - `"dashboard"`: visible only in the Dashboard configurator
2337
- * - `"none"`: not configurable via UI (callbacks, complex objects, etc.)
2219
+ * Where a prop field is configurable: "all" (both), "switcher", "dashboard",
2220
+ * or "none" (not configurable via UI).
2338
2221
  */
2339
2222
  type PropFieldScope = "all" | "switcher" | "dashboard" | "none";
2340
2223
  /**
@@ -2377,11 +2260,8 @@ interface PropFieldDescriptor {
2377
2260
  type PropSchemaRegistry = Record<string, PropFieldDescriptor[]>;
2378
2261
 
2379
2262
  /**
2380
- * Props for the shared DataComponentConfigurator.
2381
- *
2382
- * This component is used in two contexts:
2383
- * 1. **Switcher** — shows the component selector + prop form (scope: "switcher")
2384
- * 2. **Dashboard widget configurator** — shows only the prop form (scope: "dashboard")
2263
+ * Props for the shared DataComponentConfigurator, used by the Switcher (selector +
2264
+ * form, scope "switcher") and the Dashboard widget configurator (form only).
2385
2265
  */
2386
2266
  interface DataComponentConfiguratorProps {
2387
2267
  /** Schema for the active component's configurable fields. */
@@ -2410,15 +2290,8 @@ interface DataComponentConfiguratorProps {
2410
2290
  }
2411
2291
 
2412
2292
  /**
2413
- * Shared configurator for data-components.
2414
- *
2415
- * Renders:
2416
- * - An optional **component selector** (when `componentMetaList` is provided)
2417
- * - A **dynamic prop form** filtered by the given scope
2418
- *
2419
- * Used by:
2420
- * - **Switcher** — full configurator with component selector + all props
2421
- * - **Dashboard widget configurator** — prop form only (scope: "dashboard")
2293
+ * Shared configurator for data-components: an optional component selector
2294
+ * (`componentMetaList`) plus a dynamic prop form filtered by `scope`.
2422
2295
  */
2423
2296
  declare const DataComponentConfigurator: {
2424
2297
  ({ schema, values, onChange, columns, scope, componentId, onComponentChange, componentMetaList, }: DataComponentConfiguratorProps): React__default.JSX.Element;
@@ -2514,9 +2387,8 @@ interface StepperProps extends React.HTMLAttributes<HTMLElement> {
2514
2387
  }
2515
2388
 
2516
2389
  /**
2517
- * Horizontal stepper that renders ordered steps with idle/active/done states.
2518
- * Steps before `current` are automatically marked as done. Each step renders
2519
- * as a `Tag` whose state changes with the step status.
2390
+ * Horizontal stepper rendering ordered steps with idle/active/done states, each as a
2391
+ * `Tag`. Steps before `current` are marked done automatically.
2520
2392
  */
2521
2393
  declare const Stepper: React__default.FC<StepperProps>;
2522
2394
 
@@ -2603,10 +2475,8 @@ declare const BlankSlate: React__default.FC<BlankSlateProps> & {
2603
2475
  };
2604
2476
 
2605
2477
  /**
2606
- * Derives `FilterFieldProp[]` from column definitions.
2607
- *
2608
- * Columns without a resolvable ID or header are skipped.
2609
- * SELECT / BUTTON_GROUP columns populate `availableOptions` from `col.options`.
2478
+ * Derives `FilterFieldProp[]` from column definitions, skipping columns without a
2479
+ * resolvable ID or header and populating options from SELECT / BUTTON_GROUP columns.
2610
2480
  */
2611
2481
  declare function fieldOptionsFromColumns<TData>(columns: DataStructureColumn<TData>[]): FilterFieldProp[];
2612
2482
  /** Returns the available operator options for a given column type. */
@@ -2650,12 +2520,8 @@ declare function removeFieldFilters(root: FilterGroup, fieldId: string): FilterG
2650
2520
  declare function countTopLevelFiltersMap(filters: Record<string, FilterGroup | null> | null): number;
2651
2521
 
2652
2522
  /**
2653
- * Filters `data` rows using the provided `FilterGroup` AST.
2654
- *
2655
- * - Returns the original `data` array reference unchanged when `filter` is
2656
- * `null` or contains no active conditions (avoids unnecessary re-renders).
2657
- * - Works with any `DataStructureComponent`-compatible column definition,
2658
- * resolving values via `accessorFn` or `accessorKey`.
2523
+ * Filters `data` with a `FilterGroup` AST, returning the same array reference when
2524
+ * the filter is null or empty. Values resolve via `accessorFn` or `accessorKey`.
2659
2525
  *
2660
2526
  * @example
2661
2527
  * const visible = applyFilter(data, filterGroup, columns);
@@ -2683,17 +2549,8 @@ interface FilterConditionEditorProps {
2683
2549
  readonly onGuidedComplete?: () => void;
2684
2550
  }
2685
2551
  /**
2686
- * Shared row-level filter condition editor: field → operator → value.
2687
- *
2688
- * Reused by both `FilterBuilder` (panel rows inside groups) and `FilterField`
2689
- * (inline chips in edit-in-place mode). This is the single place where field /
2690
- * operator / value input switching logic lives.
2691
- *
2692
- * Each piece (field, operator, value, delete) can be individually locked via
2693
- * `condition.readOnly` or the `readOnly` prop.
2694
- *
2695
- * When `guided` is `true`, the editor walks the user through the three steps,
2696
- * auto-opening the dropdown / focusing the input of the current step.
2552
+ * Shared row-level filter editor (field → operator → value), used by both `FilterBuilder`
2553
+ * and `FilterField`. Each piece can be locked, and `guided` walks the user through the steps.
2697
2554
  */
2698
2555
  declare const FilterConditionEditor: React.FC<FilterConditionEditorProps>;
2699
2556
 
@@ -2713,21 +2570,13 @@ interface FilterFieldProps {
2713
2570
  declare const FilterField: React.FC<FilterFieldProps>;
2714
2571
 
2715
2572
  /**
2716
- * Props for the Dashboard orchestrator component.
2717
- *
2718
- * Dashboard provides global filters to all child DashboardWidget instances
2719
- * and arranges them using the responsive Layout system.
2720
- *
2721
- * Global filters are organised per data source: each entry in `filters` is
2722
- * keyed by the data source id (e.g. "transactions", "budgets") and contains
2723
- * the filter tree specific to that source. Widgets pick the entry matching
2724
- * their own data source via context.
2573
+ * Props for the Dashboard orchestrator, which feeds global filters (keyed by data
2574
+ * source id) to every child DashboardWidget and lays them out with the Layout system.
2725
2575
  */
2726
2576
  interface DashboardProps {
2727
2577
  /**
2728
- * Global filter trees keyed by data source id.
2729
- * Each widget receives the entry whose key matches its data source,
2730
- * then merges it with its own per-section filters.
2578
+ * Global filter trees keyed by data source id. Each widget merges the entry matching
2579
+ * its own data source with its per-section filters.
2731
2580
  */
2732
2581
  filters: Record<string, FilterGroup | null> | null;
2733
2582
  /** Called when a data-source filter tree changes (key + new tree) */
@@ -2735,9 +2584,8 @@ interface DashboardProps {
2735
2584
  /** Responsive layout configuration (mobile / tablet / desktop breakpoints) */
2736
2585
  layout: ResponsiveLayout;
2737
2586
  /**
2738
- * Field definitions for the FilterBuilder, keyed by data source id.
2739
- * Each entry is shown as a separate tab/section inside the global filter
2740
- * overlay. Required when `enableFilter` is true.
2587
+ * FilterBuilder fields keyed by data source id, each shown as its own tab in the global
2588
+ * filter overlay. Required when `enableFilter` is true.
2741
2589
  */
2742
2590
  fieldOptions?: Record<string, FilterFieldProp[]>;
2743
2591
  /** Show a filter button that opens the FilterBuilder overlay */
@@ -2758,23 +2606,14 @@ interface DashboardContextValue {
2758
2606
  }
2759
2607
 
2760
2608
  /**
2761
- * Dashboard is the top-level orchestrator for a page of data widgets.
2762
- *
2763
- * It provides global filters to all child DashboardWidget instances via
2764
- * context, keyed by data source id, and arranges widgets using the
2765
- * responsive Layout system.
2766
- *
2767
- * When `enableFilter` is set, a filter button opens the FilterBuilder
2768
- * overlay where the user picks a data source and edits its filter tree.
2769
- * The button shows the total number of active top-level filters across
2770
- * all data sources.
2609
+ * Top-level orchestrator for a page of data widgets: shares global filters with every
2610
+ * child DashboardWidget (keyed by data source id) and arranges them with the Layout system.
2771
2611
  */
2772
2612
  declare const Dashboard: React__default.FC<DashboardProps>;
2773
2613
 
2774
2614
  /**
2775
- * Hook to consume the DashboardContext.
2776
- * Returns the current filters and onFilterChange callback.
2777
- * Returns null when used outside a Dashboard.
2615
+ * Reads the DashboardContext, returning the current filters and `onFilterChange`,
2616
+ * or null outside a Dashboard.
2778
2617
  */
2779
2618
  declare function useDashboard(): DashboardContextValue | null;
2780
2619
 
@@ -2786,14 +2625,8 @@ interface DashboardWidgetRenderPayload<TData> {
2786
2625
  data: TData[];
2787
2626
  }
2788
2627
  /**
2789
- * Props for the DashboardWidget component.
2790
- *
2791
- * Three modes are supported, depending on which props you provide:
2792
- *
2793
- * - **Passthrough mode**: provide only `data`. The data is used as-is —
2794
- * the server already prepared it. Zero frontend processing.
2795
- * - **Legacy mode**: provide `data` + `columns`. Global dashboard filters
2796
- * are applied client-side via `applyFilter()`.
2628
+ * Props for DashboardWidget. Passthrough mode takes only `data` and uses it as-is;
2629
+ * legacy mode takes `data` + `columns` and applies global filters client-side.
2797
2630
  */
2798
2631
  interface DashboardWidgetProps<TData> {
2799
2632
  /** Unique identifier for this widget (used as Layout block key) */
@@ -2801,9 +2634,8 @@ interface DashboardWidgetProps<TData> {
2801
2634
  /** Widget title displayed in the Section header */
2802
2635
  title: string;
2803
2636
  /**
2804
- * Data source identifier used to pick this widget's entry from the
2805
- * dashboard's per-source global filter map. Required to receive
2806
- * global filters (otherwise only the per-section filter applies).
2637
+ * Data source id that picks this widget's entry from the dashboard's per-source
2638
+ * filter map. Required to receive global filters.
2807
2639
  */
2808
2640
  dataSourceId?: string;
2809
2641
  /** Optional subtitle displayed below the title */
@@ -2811,10 +2643,8 @@ interface DashboardWidgetProps<TData> {
2811
2643
  /** Optional icon name (bundled SVG) shown before the title in the Section header */
2812
2644
  icon?: string;
2813
2645
  /**
2814
- * Data for this widget.
2815
- *
2816
- * - **Passthrough**: provide `data` alone → used as-is (server-ready).
2817
- * - **Legacy**: provide `data` + `columns` → global filters applied.
2646
+ * Data for this widget: alone it is used as-is (passthrough); with `columns`,
2647
+ * global filters are applied client-side.
2818
2648
  */
2819
2649
  data?: TData[];
2820
2650
  /**
@@ -2847,14 +2677,8 @@ interface DashboardWidgetProps<TData> {
2847
2677
  }
2848
2678
 
2849
2679
  /**
2850
- * DashboardWidget is a self-contained widget that:
2851
- * 1. Receives its own data (raw, pre-filtered, or engine-backed)
2852
- * 2. Renders a Section with a toolbar of actions (export, screenshot, expand)
2853
- * 3. Passes data to the render prop
2854
- *
2855
- * Three modes:
2856
- * - **Passthrough**: provide only `data` → used as-is (server-ready, zero processing)
2857
- * - **Legacy**: provide `data` + `columns` → global filters applied via `applyFilter()`
2680
+ * Self-contained widget that takes its own data (raw, pre-filtered, or engine-backed),
2681
+ * renders a Section with an action toolbar, and passes the data to the render prop.
2858
2682
  */
2859
2683
  declare const DashboardWidget: {
2860
2684
  <TData extends object>({ title, subtitle, icon, data, columns, children, enableExport, enableScreenshot, enableExpand, enableFilter, fieldOptions, filters, onFilterChange, ignoreGlobalFilters, dataSourceId, className, }: DashboardWidgetProps<TData>): React__default.JSX.Element;