@navette-js/tables 1.0.0-beta.1 → 1.0.0-beta.3
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/README.md +2 -2
- package/lib/index.d.ts +149 -148
- package/lib/index.js +167 -166
- package/lib/query-builder.d.ts +53 -53
- package/lib/query-builder.js +89 -95
- package/package.json +7 -8
- package/views/column-manager.ejs +2 -2
- package/views/index.ejs +14 -15
package/lib/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { DataAdapter, ListQuery, Page as RecordPage, SortDirection } from '@navette-js/database';
|
|
2
2
|
import { Attributes, type ColorManager } from '@navette-js/support';
|
|
3
3
|
export * from './query-builder.ts';
|
|
4
|
-
/**
|
|
4
|
+
/** Render hook slots of a table. */
|
|
5
5
|
export declare const TablesRenderHook: {
|
|
6
6
|
readonly CONTENT_AFTER: "tables::content.after";
|
|
7
7
|
readonly CONTENT_BEFORE: "tables::content.before";
|
|
@@ -23,18 +23,18 @@ export declare const TablesRenderHook: {
|
|
|
23
23
|
readonly TOOLBAR_START: "tables::toolbar.start";
|
|
24
24
|
readonly FILTER_INDICATORS: "tables::filter.indicators";
|
|
25
25
|
readonly HEADER_CELL: "tables::header.cell";
|
|
26
|
-
/**
|
|
26
|
+
/** Legacy aliases of the column manager trigger slots. */
|
|
27
27
|
readonly TOOLBAR_TOGGLE_COLUMN_TRIGGER_AFTER: "tables::toolbar.toggle-column-trigger.after";
|
|
28
28
|
readonly TOOLBAR_TOGGLE_COLUMN_TRIGGER_BEFORE: "tables::toolbar.toggle-column-trigger.before";
|
|
29
29
|
};
|
|
30
|
-
/**
|
|
30
|
+
/** Methods and properties that trigger the table's loading state (`wire:target`). */
|
|
31
31
|
export declare const LOADING_TARGETS = "activeTab,applyTableFilters,gotoPage,nextPage,previousPage,removeTableFilter,removeTableFilters,reorderTable,resetTableColumnSearch,resetTableFiltersForm,resetTableSearch,setPage,sortTable,tableColumnSearches,tableFilters,tableGrouping,tableRecordsPerPage,tableSearch,tableSort,toggleTableReordering";
|
|
32
32
|
type StateResolver<R> = (ctx: {
|
|
33
33
|
record: R;
|
|
34
34
|
}) => unknown | Promise<unknown>;
|
|
35
|
-
/** Base
|
|
35
|
+
/** Base class of table columns. */
|
|
36
36
|
export declare abstract class Column<R = any> {
|
|
37
|
-
/**
|
|
37
|
+
/** Default setup for every instance created afterwards by `make()`, e.g. `TextColumn.configureUsing((column) => column.sortable())`. */
|
|
38
38
|
static configureUsing<T>(this: abstract new (...args: any[]) => T, configure: (instance: T) => void): void;
|
|
39
39
|
readonly name: string;
|
|
40
40
|
protected _label: string | null;
|
|
@@ -48,30 +48,30 @@ export declare abstract class Column<R = any> {
|
|
|
48
48
|
protected _sortColumn: string | null;
|
|
49
49
|
protected _searchColumn: string | null;
|
|
50
50
|
protected _url: ((record: R) => string | null) | null;
|
|
51
|
-
/**
|
|
51
|
+
/** Label of the column group this column belongs to (set by ColumnGroup). */
|
|
52
52
|
_group: string | null;
|
|
53
53
|
constructor(name: string);
|
|
54
54
|
label(label: string): this;
|
|
55
|
-
/** `column
|
|
55
|
+
/** `column`: column (or query alias) to sort by when it differs from the name, e.g. for a relationship. */
|
|
56
56
|
sortable(condition?: boolean | {
|
|
57
57
|
column: string;
|
|
58
58
|
inverted?: boolean;
|
|
59
59
|
}): this;
|
|
60
60
|
getSortColumn(): string;
|
|
61
61
|
private _sortInverted;
|
|
62
|
-
/**
|
|
62
|
+
/** `inverted`: the sort column runs opposite to the displayed value (e.g. an age sorted by birth date). */
|
|
63
63
|
isSortInverted(): boolean;
|
|
64
|
-
/**
|
|
64
|
+
/** Link on the cell; takes precedence over the row action. */
|
|
65
65
|
url(resolver: (record: R) => string | null): this;
|
|
66
66
|
getUrl(record: R): string | null;
|
|
67
|
-
/** `isGlobal: false`
|
|
67
|
+
/** `isGlobal: false` excludes the column from the global search; `isIndividual` adds a search field for this column. */
|
|
68
68
|
getSearchColumn(): string;
|
|
69
69
|
searchable(options?: boolean | {
|
|
70
70
|
isIndividual?: boolean;
|
|
71
71
|
isGlobal?: boolean;
|
|
72
72
|
column?: string;
|
|
73
73
|
}): this;
|
|
74
|
-
/**
|
|
74
|
+
/** Lets the user hide the column from the column manager. */
|
|
75
75
|
toggleable(condition?: boolean, options?: {
|
|
76
76
|
isToggledHiddenByDefault?: boolean;
|
|
77
77
|
}): this;
|
|
@@ -87,10 +87,10 @@ export declare abstract class Column<R = any> {
|
|
|
87
87
|
isToggleable(): boolean;
|
|
88
88
|
isToggledHiddenByDefault(): boolean;
|
|
89
89
|
getAlignment(): string | null;
|
|
90
|
-
/**
|
|
90
|
+
/** Suffix of the `fi-ta-header-cell-…` / `fi-ta-cell-…` classes: underscores become dashes, dots are kept. */
|
|
91
91
|
getCssName(): string;
|
|
92
92
|
getState(record: R): Promise<unknown>;
|
|
93
|
-
/**
|
|
93
|
+
/** True for editable cells: they are not wrapped in a link or button to the record. */
|
|
94
94
|
isClickDisabled(): boolean;
|
|
95
95
|
abstract toHtml(record: R, recordKey?: string | number): Promise<string>;
|
|
96
96
|
}
|
|
@@ -109,41 +109,41 @@ export declare class TextColumn<R = any> extends Column<R> {
|
|
|
109
109
|
private _limit;
|
|
110
110
|
private _tooltip;
|
|
111
111
|
static make<R = any>(name: string): TextColumn<R>;
|
|
112
|
-
/**
|
|
112
|
+
/** Displays the value in a badge. */
|
|
113
113
|
badge(condition?: boolean): this;
|
|
114
114
|
color(color: string | ((record: R) => string)): this;
|
|
115
115
|
icon(resolver: (record: R) => string | null): this;
|
|
116
|
-
/**
|
|
116
|
+
/** Text displayed instead of the raw value (e.g. an enum label). */
|
|
117
117
|
formatStateUsing(formatter: (ctx: {
|
|
118
118
|
state: unknown;
|
|
119
119
|
record: R;
|
|
120
120
|
}) => string): this;
|
|
121
|
-
/**
|
|
121
|
+
/** Short date, e.g. "Nov 9, 2026". */
|
|
122
122
|
date(condition?: boolean): this;
|
|
123
123
|
private _dateTime;
|
|
124
|
-
/** Date
|
|
124
|
+
/** Date and time, e.g. "Nov 9, 2026 14:30:00". */
|
|
125
125
|
dateTime(condition?: boolean): this;
|
|
126
|
-
/**
|
|
126
|
+
/** Number formatted with thousands separators. */
|
|
127
127
|
private _decimals;
|
|
128
|
-
/** `numeric(1)
|
|
128
|
+
/** `numeric(1)`: fixed number of decimals. */
|
|
129
129
|
numeric(condition?: boolean | number): this;
|
|
130
|
-
/**
|
|
130
|
+
/** Summary row below the table. */
|
|
131
131
|
summarize(summarizer: Summarizer | Summarizer[]): this;
|
|
132
132
|
getSummarizers(): Summarizer[];
|
|
133
133
|
weight(weight: string): this;
|
|
134
|
-
/**
|
|
134
|
+
/** Truncates the displayed text to `length` characters, followed by "...". */
|
|
135
135
|
limit(length: number | null): this;
|
|
136
|
-
/**
|
|
136
|
+
/** Tooltip on hover; `null` for none. */
|
|
137
137
|
tooltip(tooltip: ((record: R) => string | null) | string | null): this;
|
|
138
138
|
copyable(condition?: boolean): this;
|
|
139
|
-
/**
|
|
139
|
+
/** Amount formatted in the given currency, e.g. `money('usd')`. */
|
|
140
140
|
money(currency?: string | ((record: R) => string)): this;
|
|
141
|
-
/**
|
|
141
|
+
/** Text displayed when the value is empty. */
|
|
142
142
|
placeholder(text: string | null): this;
|
|
143
|
-
/**
|
|
143
|
+
/** Cell content: a short markup for plain text, a full markup as soon as an option (badge, icon, color…) is set. */
|
|
144
144
|
toHtml(record: R): Promise<string>;
|
|
145
145
|
}
|
|
146
|
-
/**
|
|
146
|
+
/** Values a summarizer works from: aggregates over the query (all records) or over the displayed page. */
|
|
147
147
|
export type SummaryValues = {
|
|
148
148
|
count: number;
|
|
149
149
|
sum: Record<string, number>;
|
|
@@ -156,7 +156,7 @@ export type SummaryItem = {
|
|
|
156
156
|
label: string | null;
|
|
157
157
|
value: string;
|
|
158
158
|
};
|
|
159
|
-
/**
|
|
159
|
+
/** Column summary below the table: sum, average, count or range. */
|
|
160
160
|
export declare abstract class Summarizer {
|
|
161
161
|
abstract readonly kind: 'sum' | 'avg' | 'count' | 'range';
|
|
162
162
|
protected _label: string | null;
|
|
@@ -167,37 +167,37 @@ export declare abstract class Summarizer {
|
|
|
167
167
|
format(value: number): string;
|
|
168
168
|
abstract summarize(column: string, values: SummaryValues): SummaryItem | null;
|
|
169
169
|
}
|
|
170
|
-
/**
|
|
170
|
+
/** Column total. */
|
|
171
171
|
export declare class Sum extends Summarizer {
|
|
172
172
|
readonly kind = "sum";
|
|
173
173
|
static make(): Sum;
|
|
174
174
|
getLabel(): string;
|
|
175
175
|
summarize(column: string, values: SummaryValues): SummaryItem;
|
|
176
176
|
}
|
|
177
|
-
/**
|
|
177
|
+
/** Column average. */
|
|
178
178
|
export declare class Average extends Summarizer {
|
|
179
179
|
readonly kind = "avg";
|
|
180
180
|
static make(): Average;
|
|
181
181
|
getLabel(): string;
|
|
182
182
|
summarize(column: string, values: SummaryValues): SummaryItem;
|
|
183
183
|
}
|
|
184
|
-
/**
|
|
184
|
+
/** Record count. */
|
|
185
185
|
export declare class Count extends Summarizer {
|
|
186
186
|
readonly kind = "count";
|
|
187
187
|
static make(): Count;
|
|
188
188
|
getLabel(): string;
|
|
189
189
|
summarize(_column: string, values: SummaryValues): SummaryItem;
|
|
190
190
|
}
|
|
191
|
-
/**
|
|
191
|
+
/** Smallest and largest value of a column. */
|
|
192
192
|
export declare class Range extends Summarizer {
|
|
193
193
|
readonly kind = "range";
|
|
194
194
|
private _minimalDateTime;
|
|
195
195
|
static make(): Range;
|
|
196
|
-
/** Dates
|
|
196
|
+
/** Dates: day only when the bounds fall on different days, day and time otherwise; a single value when both are equal. */
|
|
197
197
|
minimalDateTimeDifference(condition?: boolean): this;
|
|
198
198
|
summarize(column: string, values: SummaryValues): SummaryItem | null;
|
|
199
199
|
}
|
|
200
|
-
/**
|
|
200
|
+
/** Row grouping: rows are sorted by the column and each group gets a header row. */
|
|
201
201
|
export declare class Group<R = any> {
|
|
202
202
|
private id;
|
|
203
203
|
private _label;
|
|
@@ -210,17 +210,17 @@ export declare class Group<R = any> {
|
|
|
210
210
|
constructor(id: string);
|
|
211
211
|
static make<R = any>(id: string): Group<R>;
|
|
212
212
|
label(label: string | null): this;
|
|
213
|
-
/**
|
|
213
|
+
/** Query column holding the group value, when it differs from the id (relationship). */
|
|
214
214
|
column(column: string | null): this;
|
|
215
|
-
/**
|
|
215
|
+
/** Group title computed from the record (e.g. an enum label). */
|
|
216
216
|
getTitleUsing(resolver: ((record: R) => string | null) | null): this;
|
|
217
217
|
getDescriptionUsing(resolver: ((record: R) => string | null) | null): this;
|
|
218
|
-
/**
|
|
218
|
+
/** Aliases using the `get…FromRecordUsing` naming. */
|
|
219
219
|
getTitleFromRecordUsing(resolver: ((record: R) => string | null) | null): this;
|
|
220
220
|
getDescriptionFromRecordUsing(resolver: ((record: R) => string | null) | null): this;
|
|
221
|
-
/**
|
|
221
|
+
/** Groups collapse when their header is clicked. */
|
|
222
222
|
collapsible(condition?: boolean): this;
|
|
223
|
-
/**
|
|
223
|
+
/** The column is a date: rows from the same day form one group. */
|
|
224
224
|
date(condition?: boolean): this;
|
|
225
225
|
titlePrefixedWithLabel(condition?: boolean): this;
|
|
226
226
|
getId(): string;
|
|
@@ -229,43 +229,43 @@ export declare class Group<R = any> {
|
|
|
229
229
|
isCollapsible(): boolean;
|
|
230
230
|
isDate(): boolean;
|
|
231
231
|
isTitlePrefixedWithLabel(): boolean;
|
|
232
|
-
/**
|
|
232
|
+
/** Group value of a record, as text; `null` when empty. */
|
|
233
233
|
getStringKey(record: R): string | null;
|
|
234
234
|
getTitle(record: R): string | null;
|
|
235
235
|
getDescription(record: R): string | null;
|
|
236
|
-
/**
|
|
236
|
+
/** Restricts a query to the records of the group with the given key. */
|
|
237
237
|
scope(query: any, key: string | null): void;
|
|
238
238
|
}
|
|
239
239
|
/**
|
|
240
|
-
*
|
|
241
|
-
*
|
|
240
|
+
* Column layout: as soon as a table has one, records are rendered as cards (`fi-ta-content`) instead of table rows,
|
|
241
|
+
* and sorting goes through a "Sort by" select.
|
|
242
242
|
*/
|
|
243
243
|
export declare abstract class ColumnLayout<R = any> {
|
|
244
244
|
protected _children: (Column<R> | ColumnLayout<R>)[];
|
|
245
245
|
constructor(children: (Column<R> | ColumnLayout<R>)[]);
|
|
246
246
|
getChildren(): (Column<R> | ColumnLayout<R>)[];
|
|
247
|
-
/**
|
|
247
|
+
/** Leaf columns, in order: the ones the table sorts, searches and toggles. */
|
|
248
248
|
getColumns(): Column<R>[];
|
|
249
249
|
abstract getClasses(): string[];
|
|
250
250
|
}
|
|
251
|
-
/**
|
|
251
|
+
/** Columns side by side, from a given breakpoint. */
|
|
252
252
|
export declare class Split<R = any> extends ColumnLayout<R> {
|
|
253
253
|
private _from;
|
|
254
254
|
static make<R = any>(children: (Column<R> | ColumnLayout<R>)[]): Split<R>;
|
|
255
255
|
from(breakpoint: 'sm' | 'md' | 'lg' | 'xl' | '2xl' | null): this;
|
|
256
256
|
getClasses(): string[];
|
|
257
257
|
}
|
|
258
|
-
/**
|
|
258
|
+
/** Columns stacked vertically. */
|
|
259
259
|
export declare class Stack<R = any> extends ColumnLayout<R> {
|
|
260
260
|
private _space;
|
|
261
261
|
private _alignment;
|
|
262
262
|
static make<R = any>(children: (Column<R> | ColumnLayout<R>)[]): Stack<R>;
|
|
263
|
-
/**
|
|
263
|
+
/** Gap between columns: 1 (small), 2 (medium) or 3 (large). */
|
|
264
264
|
space(space?: 1 | 2 | 3 | null): this;
|
|
265
265
|
alignment(alignment: 'start' | 'center' | 'end'): this;
|
|
266
266
|
getClasses(): string[];
|
|
267
267
|
}
|
|
268
|
-
/**
|
|
268
|
+
/** Column group: a shared label above the column headers. */
|
|
269
269
|
export declare class ColumnGroup<R = any> {
|
|
270
270
|
private label;
|
|
271
271
|
private _columns;
|
|
@@ -274,31 +274,31 @@ export declare class ColumnGroup<R = any> {
|
|
|
274
274
|
columns(columns: Column<R>[]): this;
|
|
275
275
|
getColumns(): Column<R>[];
|
|
276
276
|
}
|
|
277
|
-
/**
|
|
277
|
+
/** Color swatch column. */
|
|
278
278
|
export declare class ColorColumn<R = any> extends Column<R> {
|
|
279
279
|
static make<R = any>(name: string): ColorColumn<R>;
|
|
280
280
|
toHtml(record: R): Promise<string>;
|
|
281
281
|
}
|
|
282
|
-
/** Image
|
|
282
|
+
/** Image column: the state is the image URL. Only local or http(s) URLs are rendered. */
|
|
283
283
|
export declare class ImageColumn<R = any> extends Column<R> {
|
|
284
284
|
private _alt;
|
|
285
285
|
private _height;
|
|
286
286
|
private _circular;
|
|
287
287
|
static make<R = any>(name: string): ImageColumn<R>;
|
|
288
288
|
alt(resolver: (record: R) => string | null): this;
|
|
289
|
-
/**
|
|
289
|
+
/** CSS height of the image (`2.5rem` by default). */
|
|
290
290
|
imageHeight(height: string): this;
|
|
291
291
|
circular(condition?: boolean): this;
|
|
292
292
|
toHtml(record: R): Promise<string>;
|
|
293
293
|
}
|
|
294
|
-
/**
|
|
294
|
+
/** Icon depending on the value; `boolean()` shows a green check or a red cross. */
|
|
295
295
|
export declare class IconColumn<R = any> extends Column<R> {
|
|
296
296
|
private _boolean;
|
|
297
297
|
static make<R = any>(name: string): IconColumn<R>;
|
|
298
298
|
boolean(condition?: boolean): this;
|
|
299
299
|
toHtml(record: R): Promise<string>;
|
|
300
300
|
}
|
|
301
|
-
/**
|
|
301
|
+
/** Application-defined validation rule of an editable column: synchronous check and message (`:attribute` already replaced). */
|
|
302
302
|
export type ColumnValidationRule = {
|
|
303
303
|
name: string;
|
|
304
304
|
passes: (value: unknown) => boolean;
|
|
@@ -309,10 +309,10 @@ type StateHook<R> = (ctx: {
|
|
|
309
309
|
record: R;
|
|
310
310
|
}) => unknown | Promise<unknown>;
|
|
311
311
|
/**
|
|
312
|
-
* Base
|
|
313
|
-
*
|
|
314
|
-
*
|
|
315
|
-
*
|
|
312
|
+
* Base class of in-cell editable columns. The browser calls `updateTableColumnState(column, key, value)` on the host component:
|
|
313
|
+
* the column must be declared, visible and enabled for this record, and the value must pass the rules; only then do
|
|
314
|
+
* `beforeStateUpdated`, the write and `afterStateUpdated` run. The write does not check model permissions: use `disabled()`
|
|
315
|
+
* to restrict editing.
|
|
316
316
|
*/
|
|
317
317
|
export declare abstract class EditableColumn<R = any> extends Column<R> {
|
|
318
318
|
protected _disabled: ((record: R) => boolean | Promise<boolean>) | boolean;
|
|
@@ -325,50 +325,49 @@ export declare abstract class EditableColumn<R = any> extends Column<R> {
|
|
|
325
325
|
protected _tooltip: ((record: R) => string | null) | string | null;
|
|
326
326
|
disabled(condition?: ((record: R) => boolean | Promise<boolean>) | boolean): this;
|
|
327
327
|
isDisabledFor(record: R): Promise<boolean>;
|
|
328
|
-
/**
|
|
328
|
+
/** An editable cell is neither a link nor a button to the record. */
|
|
329
329
|
isClickDisabled(): boolean;
|
|
330
330
|
isEditable(): boolean;
|
|
331
|
-
/**
|
|
331
|
+
/** Rules applied to the received value: strings (`required`, `max:255`, `in:a,b`…) or `{ name, passes, message }` objects. */
|
|
332
332
|
rules(rules: (string | ColumnValidationRule)[]): this;
|
|
333
333
|
getRules(): (string | ColumnValidationRule)[];
|
|
334
|
-
/**
|
|
334
|
+
/** Same as adding `required` to the rules. */
|
|
335
335
|
required(condition?: boolean): this;
|
|
336
336
|
isRequired(): boolean;
|
|
337
|
-
/**
|
|
337
|
+
/** Column name used in messages (defaults to the label with a lowercase first letter). */
|
|
338
338
|
validationAttribute(label: string | null): this;
|
|
339
|
-
/**
|
|
339
|
+
/** Custom messages by rule name, e.g. `{ max: 'Too long.' }`. */
|
|
340
340
|
validationMessages(messages: Record<string, string>): this;
|
|
341
341
|
getValidationAttribute(): string;
|
|
342
|
-
/**
|
|
342
|
+
/** Rules specific to the column type (e.g. select options). */
|
|
343
343
|
protected getImplicitRules(): ColumnValidationRule[];
|
|
344
344
|
/**
|
|
345
|
-
*
|
|
346
|
-
*
|
|
345
|
+
* Error message, or `null` if the value is valid. An empty value is only checked by `required`, and several errors
|
|
346
|
+
* produce the first message followed by "(and N more errors)".
|
|
347
347
|
*/
|
|
348
348
|
validate(input: unknown): string | null;
|
|
349
|
-
/**
|
|
349
|
+
/** Custom write, replacing the update of the record's column. Its return value is sent back to the browser. */
|
|
350
350
|
updateStateUsing(callback: StateHook<R> | null): this;
|
|
351
351
|
beforeStateUpdated(callback: StateHook<R> | null): this;
|
|
352
352
|
afterStateUpdated(callback: StateHook<R> | null): this;
|
|
353
|
-
/**
|
|
353
|
+
/** Tooltip on the control, shown while no error is displayed. */
|
|
354
354
|
tooltip(tooltip: ((record: R) => string | null) | string | null): this;
|
|
355
355
|
getUpdateStateMessages(): Record<'saving' | 'saved' | 'failure', string>;
|
|
356
|
-
/**
|
|
356
|
+
/** Value written from a validated value: blank values become `null`. */
|
|
357
357
|
castState(input: unknown): unknown;
|
|
358
358
|
/**
|
|
359
|
-
*
|
|
360
|
-
*
|
|
359
|
+
* Saves an already validated value. Only the column's declared name is written: a relationship column (`author.name`)
|
|
360
|
+
* can only be edited with `updateStateUsing()`.
|
|
361
361
|
*/
|
|
362
362
|
updateState(record: R, input: unknown, adapter: Pick<DataAdapter<R>, 'getKey' | 'update'>): Promise<unknown>;
|
|
363
|
-
/**
|
|
363
|
+
/** `x-tooltip` expression of editable controls: the column tooltip, replaced by the validation error when there is one. */
|
|
364
364
|
protected tooltipExpression(record: R): string;
|
|
365
|
-
/**
|
|
365
|
+
/** Shared opening markup of editable cells: lazily loaded Alpine component, server state and record key. */
|
|
366
366
|
protected editableAttributes(component: string, asset: string, recordKey: string | number, state: unknown): Attributes;
|
|
367
367
|
protected static readonly STATUS_HTML = "<p x-cloak x-show=\"error\" x-bind:id=\"$id('table-column-error')\" x-ref=\"error\" x-text=\"error\" class=\"fi-sr-only\"></p><p role=\"status\" aria-live=\"polite\" aria-atomic=\"true\" x-text=\"status\" class=\"fi-sr-only\"></p>";
|
|
368
368
|
}
|
|
369
369
|
/**
|
|
370
|
-
*
|
|
371
|
-
* options déclarées.
|
|
370
|
+
* In-cell editable select (native select only). The received value must be one of the declared options.
|
|
372
371
|
*/
|
|
373
372
|
export declare class SelectColumn<R = any> extends EditableColumn<R> {
|
|
374
373
|
private _options;
|
|
@@ -380,7 +379,7 @@ export declare class SelectColumn<R = any> extends EditableColumn<R> {
|
|
|
380
379
|
protected getImplicitRules(): ColumnValidationRule[];
|
|
381
380
|
toHtml(record: R, recordKey?: string | number): Promise<string>;
|
|
382
381
|
}
|
|
383
|
-
/**
|
|
382
|
+
/** In-cell editable toggle. The received value must be a boolean (`boolean` rule by default). */
|
|
384
383
|
export declare class ToggleColumn<R = any> extends EditableColumn<R> {
|
|
385
384
|
private _onColor;
|
|
386
385
|
private _offColor;
|
|
@@ -388,23 +387,23 @@ export declare class ToggleColumn<R = any> extends EditableColumn<R> {
|
|
|
388
387
|
private _offIcon;
|
|
389
388
|
constructor(name: string);
|
|
390
389
|
static make<R = any>(name: string): ToggleColumn<R>;
|
|
391
|
-
/**
|
|
390
|
+
/** Toggle color when on (`primary` by default) and off (`gray`). */
|
|
392
391
|
onColor(color: string | null): this;
|
|
393
392
|
offColor(color: string | null): this;
|
|
394
|
-
/**
|
|
393
|
+
/** Icons shown inside the toggle's thumb. */
|
|
395
394
|
onIcon(icon: string | null): this;
|
|
396
395
|
offIcon(icon: string | null): this;
|
|
397
396
|
castState(input: unknown): unknown;
|
|
398
397
|
toHtml(record: R, recordKey?: string | number): Promise<string>;
|
|
399
398
|
}
|
|
400
|
-
/**
|
|
399
|
+
/** In-cell editable checkbox. The received value must be a boolean (`boolean` rule by default). */
|
|
401
400
|
export declare class CheckboxColumn<R = any> extends EditableColumn<R> {
|
|
402
401
|
constructor(name: string);
|
|
403
402
|
static make<R = any>(name: string): CheckboxColumn<R>;
|
|
404
403
|
castState(input: unknown): unknown;
|
|
405
404
|
toHtml(record: R, recordKey?: string | number): Promise<string>;
|
|
406
405
|
}
|
|
407
|
-
/**
|
|
406
|
+
/** In-cell editable text input. Only a string or a number is accepted from the browser. */
|
|
408
407
|
export declare class TextInputColumn<R = any> extends EditableColumn<R> {
|
|
409
408
|
private _type;
|
|
410
409
|
private _mask;
|
|
@@ -420,9 +419,9 @@ export declare class TextInputColumn<R = any> extends EditableColumn<R> {
|
|
|
420
419
|
private _prefixInline;
|
|
421
420
|
private _suffixInline;
|
|
422
421
|
static make<R = any>(name: string): TextInputColumn<R>;
|
|
423
|
-
/**
|
|
422
|
+
/** HTML input type (`text` by default; `number`, `email`, `color`…). */
|
|
424
423
|
type(type: string | null): this;
|
|
425
|
-
/**
|
|
424
|
+
/** Alpine input mask (`x-mask`); the input then becomes a text input. */
|
|
426
425
|
mask(mask: string | null): this;
|
|
427
426
|
inputMode(mode: string | null): this;
|
|
428
427
|
step(step: number | string | null): this;
|
|
@@ -439,8 +438,8 @@ export declare class TextInputColumn<R = any> extends EditableColumn<R> {
|
|
|
439
438
|
toHtml(record: R, recordKey?: string | number): Promise<string>;
|
|
440
439
|
}
|
|
441
440
|
/**
|
|
442
|
-
*
|
|
443
|
-
*
|
|
441
|
+
* Custom-rendered column: `view()` takes a function returning the cell HTML, or the name of an EJS view rendered with
|
|
442
|
+
* `{ state, record, column }`. This HTML is the application's own: data inside it must be escaped there (`e()`).
|
|
444
443
|
*/
|
|
445
444
|
export declare class ViewColumn<R = any> extends Column<R> {
|
|
446
445
|
private _view;
|
|
@@ -453,59 +452,59 @@ export declare class ViewColumn<R = any> extends Column<R> {
|
|
|
453
452
|
}) => string | Promise<string>) | string, data?: Record<string, unknown>): this;
|
|
454
453
|
toHtml(record: R): Promise<string>;
|
|
455
454
|
}
|
|
456
|
-
/** @deprecated
|
|
455
|
+
/** @deprecated Use `TextColumn.make(name).badge()`. */
|
|
457
456
|
export declare class BadgeColumn<R = any> extends TextColumn<R> {
|
|
458
457
|
constructor(name: string);
|
|
459
458
|
static make<R = any>(name: string): BadgeColumn<R>;
|
|
460
459
|
}
|
|
461
|
-
/** @deprecated
|
|
460
|
+
/** @deprecated Use `IconColumn.make(name).boolean()`. */
|
|
462
461
|
export declare class BooleanColumn<R = any> extends IconColumn<R> {
|
|
463
462
|
constructor(name: string);
|
|
464
463
|
static make<R = any>(name: string): BooleanColumn<R>;
|
|
465
464
|
}
|
|
466
465
|
/**
|
|
467
|
-
*
|
|
468
|
-
*
|
|
469
|
-
*
|
|
466
|
+
* Writes an editable cell value received from the browser. Everything is checked again: the column must be declared, editable
|
|
467
|
+
* and visible, the record within the adapter's scope and not disabled for this column, `authorize` (the host's edit permission)
|
|
468
|
+
* must accept it, and the value must pass the column's rules.
|
|
470
469
|
*/
|
|
471
470
|
export declare function updateTableColumnState<R>(table: Table<R>, host: TableHost, adapter: DataAdapter<R>, columnName: unknown, recordKey: unknown, input: unknown, options?: {
|
|
472
471
|
authorize?: (record: R) => boolean | Promise<boolean>;
|
|
473
472
|
}): Promise<unknown>;
|
|
474
|
-
/**
|
|
473
|
+
/** Filter state: the values of its form. */
|
|
475
474
|
export type FilterState = Record<string, unknown>;
|
|
476
|
-
/**
|
|
475
|
+
/** Active filter indicator: its label, and the filter field cleared when it is removed. */
|
|
477
476
|
export type FilterIndicator = {
|
|
478
477
|
label: string;
|
|
479
478
|
field: string;
|
|
480
479
|
};
|
|
481
|
-
/**
|
|
480
|
+
/** Filters layout: toolbar dropdown (default), or collapsible panel above the content. */
|
|
482
481
|
export type FiltersLayout = 'dropdown' | 'above-content-collapsible';
|
|
483
482
|
export interface TableFilter {
|
|
484
483
|
readonly name: string;
|
|
485
484
|
getLabel(): string;
|
|
486
|
-
/**
|
|
485
|
+
/** Initial state (empty form). */
|
|
487
486
|
getDefaultState(): FilterState;
|
|
488
|
-
/** Options
|
|
487
|
+
/** Options of the `value` field as [value, label] pairs, and the empty option's label. */
|
|
489
488
|
getFormDefinition(): {
|
|
490
489
|
placeholder: string;
|
|
491
490
|
options: [string, string][];
|
|
492
491
|
};
|
|
493
492
|
isActive(state: FilterState): boolean;
|
|
494
|
-
/**
|
|
493
|
+
/** Applies the filter to the list query. Only reads known values. */
|
|
495
494
|
apply(query: Omit<ListQuery, 'page' | 'perPage'>, state: FilterState): void;
|
|
496
|
-
/**
|
|
495
|
+
/** Form components of the filter, replacing the select described by `getFormDefinition()`. */
|
|
497
496
|
getFormComponents?(): unknown[];
|
|
498
497
|
getColumnSpan?(): Record<string, number | string>;
|
|
499
|
-
/**
|
|
498
|
+
/** Applied state derived from the form state (received from the browser): keeps only what the filter knows. */
|
|
500
499
|
sanitizeState?(state: unknown): FilterState;
|
|
501
500
|
getIndicators?(state: FilterState): FilterIndicator[];
|
|
502
|
-
/**
|
|
501
|
+
/** Select options loaded on demand (relationship), replacing those of `getFormDefinition()`. */
|
|
503
502
|
getFormOptions?(): Promise<[string, string][]>;
|
|
504
503
|
removeIndicator?(state: FilterState, field: string): FilterState;
|
|
505
|
-
/**
|
|
504
|
+
/** Data loaded from the database before indicators are computed (e.g. related record labels). */
|
|
506
505
|
loadIndicatorData?(state: FilterState, host: TableHost): Promise<void>;
|
|
507
506
|
}
|
|
508
|
-
/**
|
|
507
|
+
/** "Trashed" filter for soft-deletable models. */
|
|
509
508
|
export declare class TrashedFilter implements TableFilter {
|
|
510
509
|
readonly name = "trashed";
|
|
511
510
|
static make(): TrashedFilter;
|
|
@@ -518,7 +517,7 @@ export declare class TrashedFilter implements TableFilter {
|
|
|
518
517
|
isActive(state: FilterState): boolean;
|
|
519
518
|
apply(query: Omit<ListQuery, 'page' | 'perPage'>, state: FilterState): void;
|
|
520
519
|
}
|
|
521
|
-
/**
|
|
520
|
+
/** Filters on a column value picked from a list (single select). */
|
|
522
521
|
export declare class SelectFilter implements TableFilter {
|
|
523
522
|
readonly name: string;
|
|
524
523
|
private _label;
|
|
@@ -527,9 +526,9 @@ export declare class SelectFilter implements TableFilter {
|
|
|
527
526
|
constructor(name: string);
|
|
528
527
|
static make(name: string): SelectFilter;
|
|
529
528
|
label(label: string): this;
|
|
530
|
-
/**
|
|
529
|
+
/** Filtered column when it differs from the filter name (e.g. a relationship's foreign key). */
|
|
531
530
|
column(column: string): this;
|
|
532
|
-
/**
|
|
531
|
+
/** Fixed options, or an async function (e.g. records of a relationship). */
|
|
533
532
|
options(options: [string, string][] | Record<string, string> | (() => Promise<[string, string][]>)): this;
|
|
534
533
|
getLabel(): string;
|
|
535
534
|
getDefaultState(): FilterState;
|
|
@@ -538,12 +537,12 @@ export declare class SelectFilter implements TableFilter {
|
|
|
538
537
|
options: [string, string][];
|
|
539
538
|
};
|
|
540
539
|
getFormOptions(): Promise<[string, string][]>;
|
|
541
|
-
/**
|
|
540
|
+
/** Options are evaluated on every render, so the select gets a key derived from them (forces a re-render when they change). */
|
|
542
541
|
readonly hasDynamicOptions = true;
|
|
543
542
|
isActive(state: FilterState): boolean;
|
|
544
543
|
apply(query: Omit<ListQuery, 'page' | 'perPage'>, state: FilterState): void;
|
|
545
544
|
}
|
|
546
|
-
/**
|
|
545
|
+
/** Three-state filter on a boolean column: all, yes, no. */
|
|
547
546
|
export declare class TernaryFilter implements TableFilter {
|
|
548
547
|
readonly name: string;
|
|
549
548
|
private _label;
|
|
@@ -559,7 +558,7 @@ export declare class TernaryFilter implements TableFilter {
|
|
|
559
558
|
isActive(state: FilterState): boolean;
|
|
560
559
|
apply(query: Omit<ListQuery, 'page' | 'perPage'>, state: FilterState): void;
|
|
561
560
|
}
|
|
562
|
-
/**
|
|
561
|
+
/** Custom form filter (`schema()`): the query and indicators are written by the application. */
|
|
563
562
|
export declare class Filter implements TableFilter {
|
|
564
563
|
readonly name: string;
|
|
565
564
|
private _label;
|
|
@@ -569,11 +568,11 @@ export declare class Filter implements TableFilter {
|
|
|
569
568
|
constructor(name: string);
|
|
570
569
|
static make(name: string): Filter;
|
|
571
570
|
label(label: string): this;
|
|
572
|
-
/**
|
|
571
|
+
/** Filter fields; their names are the only state keys accepted from the browser. */
|
|
573
572
|
schema(components: unknown[]): this;
|
|
574
|
-
/**
|
|
573
|
+
/** Query condition built from the sanitized form state. */
|
|
575
574
|
query(modifier: (query: any, data: FilterState) => void): this;
|
|
576
|
-
/**
|
|
575
|
+
/** Indicators of applied values as `{ field: label }`; removing one clears its field. */
|
|
577
576
|
indicateUsing(resolver: (data: FilterState) => Record<string, string>): this;
|
|
578
577
|
private fields;
|
|
579
578
|
getLabel(): string;
|
|
@@ -621,55 +620,55 @@ export declare class Table<R = any> {
|
|
|
621
620
|
private _groupingDirectionSettingHidden;
|
|
622
621
|
private _groupingSettingsInDropdownOnDesktop;
|
|
623
622
|
private _collapsedGroupsByDefault;
|
|
624
|
-
/**
|
|
623
|
+
/** Groupings offered in the toolbar (a column id is shorthand for `Group.make(id)`). */
|
|
625
624
|
groups(groups: (Group<R> | string)[]): this;
|
|
626
625
|
getGroups(): Group<R>[];
|
|
627
626
|
getGroup(id: string | null | undefined): Group<R> | null;
|
|
628
627
|
/**
|
|
629
|
-
*
|
|
630
|
-
*
|
|
628
|
+
* Default grouping. If it is one of `groups()`, it is only preselected when the table opens (`initializeTableGrouping`)
|
|
629
|
+
* and the user can remove it; otherwise it always applies, without a selector.
|
|
631
630
|
*/
|
|
632
631
|
defaultGroup(group: Group<R> | string | null, direction?: SortDirection): this;
|
|
633
632
|
getDefaultGroup(): Group<R> | null;
|
|
634
633
|
getDefaultGroupDirection(): SortDirection;
|
|
635
634
|
isDefaultGroupSelectable(): boolean;
|
|
636
|
-
/**
|
|
635
|
+
/** Shows only group headers and summaries, without rows or pagination. */
|
|
637
636
|
groupsOnly(condition?: boolean): this;
|
|
638
637
|
isGroupsOnly(): boolean;
|
|
639
|
-
/**
|
|
638
|
+
/** Hides the toolbar grouping selector. */
|
|
640
639
|
groupingSettingsHidden(condition?: boolean): this;
|
|
641
640
|
areGroupingSettingsHidden(): boolean;
|
|
642
|
-
/**
|
|
641
|
+
/** Hides the grouping direction (ascending / descending) choice. */
|
|
643
642
|
groupingDirectionSettingHidden(condition?: boolean): this;
|
|
644
643
|
isGroupingDirectionSettingHidden(): boolean;
|
|
645
|
-
/**
|
|
644
|
+
/** Puts the grouping selector in a dropdown on desktop too. */
|
|
646
645
|
groupingSettingsInDropdownOnDesktop(condition?: boolean): this;
|
|
647
|
-
/** @deprecated
|
|
646
|
+
/** @deprecated Use `groupingSettingsInDropdownOnDesktop()`. */
|
|
648
647
|
groupsInDropdownOnDesktop(condition?: boolean): this;
|
|
649
648
|
areGroupingSettingsInDropdownOnDesktop(): boolean;
|
|
650
|
-
/**
|
|
649
|
+
/** Collapsible groups start collapsed. */
|
|
651
650
|
collapsedGroupsByDefault(condition?: boolean): this;
|
|
652
651
|
areGroupsCollapsedByDefault(): boolean;
|
|
653
652
|
private _columnsLayout;
|
|
654
653
|
columns(columns: (Column<R> | ColumnGroup<R> | ColumnLayout<R>)[]): this;
|
|
655
|
-
/**
|
|
654
|
+
/** Column layout, or `null` for a regular table. */
|
|
656
655
|
getColumnsLayout(): (Column<R> | ColumnLayout<R>)[] | null;
|
|
657
|
-
/** Action
|
|
656
|
+
/** Action mounted when a row is clicked (e.g. `'edit'`), instead of a URL. */
|
|
658
657
|
recordAction(name: string | null): this;
|
|
659
658
|
getRecordAction(): string | null;
|
|
660
|
-
/**
|
|
659
|
+
/** Heading shown in the table header. */
|
|
661
660
|
heading(heading: string | null): this;
|
|
662
661
|
getHeading(): string | null;
|
|
663
|
-
/** Actions
|
|
662
|
+
/** Actions shown in the table header. */
|
|
664
663
|
headerActions(actions: any[]): this;
|
|
665
664
|
getHeaderActions(): any[];
|
|
666
|
-
/**
|
|
665
|
+
/** Bulk actions ("Bulk actions" menu); if never called, the host provides its default ones. */
|
|
667
666
|
groupedBulkActions(actions: any[]): this;
|
|
668
667
|
getBulkActions(): any[] | null;
|
|
669
|
-
/**
|
|
668
|
+
/** Row actions: `Action`s or an `ActionGroup` (dropdown). */
|
|
670
669
|
recordActions(actions: any[]): this;
|
|
671
670
|
getRecordActions(): any[];
|
|
672
|
-
/**
|
|
671
|
+
/** CSS classes added to a row depending on its record. */
|
|
673
672
|
recordClasses(resolver: (record: R) => string | null): this;
|
|
674
673
|
getRecordClasses(record: R): string | null;
|
|
675
674
|
filters(filters: TableFilter[], options?: {
|
|
@@ -677,21 +676,21 @@ export declare class Table<R = any> {
|
|
|
677
676
|
}): this;
|
|
678
677
|
filtersLayout(layout: FiltersLayout): this;
|
|
679
678
|
getFiltersLayout(): FiltersLayout;
|
|
680
|
-
/**
|
|
679
|
+
/** No-op kept for API compatibility: filters always wait for the "Apply" button. */
|
|
681
680
|
deferFilters(): this;
|
|
682
681
|
defaultSort(column: string, direction?: SortDirection): this;
|
|
683
682
|
recordUrl(resolver: (record: R) => string | null): this;
|
|
684
683
|
private _reorderColumn;
|
|
685
|
-
/**
|
|
684
|
+
/** Lets users reorder rows by hand; `column` stores the position. */
|
|
686
685
|
reorderable(column: string | null): this;
|
|
687
686
|
getReorderColumn(): string | null;
|
|
688
687
|
paginationPageOptions(options: number[]): this;
|
|
689
688
|
private _defaultPageOption;
|
|
690
|
-
/**
|
|
689
|
+
/** Rows per page when the table opens. */
|
|
691
690
|
defaultPaginationPageOption(option: number | null): this;
|
|
692
691
|
getDefaultPageOption(): number;
|
|
693
692
|
private _paginationMode;
|
|
694
|
-
/** `'simple'
|
|
693
|
+
/** `'simple'`: previous / next buttons only, without page numbers or total. */
|
|
695
694
|
paginationMode(mode: 'default' | 'simple'): this;
|
|
696
695
|
getPaginationMode(): 'default' | 'simple';
|
|
697
696
|
stackedOnMobile(condition?: boolean): this;
|
|
@@ -708,11 +707,11 @@ export declare class Table<R = any> {
|
|
|
708
707
|
isStackedOnMobile(): boolean;
|
|
709
708
|
getPluralModelLabel(): string;
|
|
710
709
|
hasToggleableColumns(): boolean;
|
|
711
|
-
/**
|
|
710
|
+
/** Default column manager state. */
|
|
712
711
|
getDefaultColumnState(): ColumnState[];
|
|
713
712
|
getDefaultFilterState(): Record<string, FilterState>;
|
|
714
713
|
}
|
|
715
|
-
/**
|
|
714
|
+
/** Table state held by the host component. */
|
|
716
715
|
export interface TableHost {
|
|
717
716
|
readonly id: string;
|
|
718
717
|
tableSearch: string;
|
|
@@ -722,37 +721,39 @@ export interface TableHost {
|
|
|
722
721
|
paginators: Record<string, number>;
|
|
723
722
|
tableFilters?: Record<string, FilterState>;
|
|
724
723
|
tableColumns?: ColumnState[];
|
|
725
|
-
/**
|
|
724
|
+
/** Current grouping: `id` or `id:direction`. */
|
|
726
725
|
tableGrouping?: string | null;
|
|
727
|
-
/**
|
|
726
|
+
/** Reordering mode: all rows, in position order, with drag handles. */
|
|
728
727
|
isTableReordering?: boolean;
|
|
729
728
|
}
|
|
730
|
-
/**
|
|
729
|
+
/** Visible columns: those left checked in the column manager. Browser state can only hide columns declared toggleable. */
|
|
731
730
|
export declare function getVisibleColumns<R>(table: Table<R>, host: TableHost): Column<R>[];
|
|
732
|
-
/**
|
|
731
|
+
/** Sanitizes column state from the browser: only `isToggled` of toggleable columns is kept. */
|
|
733
732
|
export declare function sanitizeColumnState<R>(table: Table<R>, state: unknown): ColumnState[];
|
|
734
|
-
/**
|
|
735
|
-
*
|
|
733
|
+
/**
|
|
734
|
+
* List query (search, column searches, filters, sort) for the host's state, without pagination.
|
|
735
|
+
* Only what the table declares is accepted, whatever state the browser sends.
|
|
736
|
+
*/
|
|
736
737
|
export declare function getTableQuery<R>(table: Table<R>, host: TableHost): Omit<ListQuery, 'page' | 'perPage'>;
|
|
737
|
-
/**
|
|
738
|
+
/** Current grouping: only a group declared by the table is accepted, whatever state the browser sends. */
|
|
738
739
|
export declare function getTableGrouping<R>(table: Table<R>, host: TableHost): {
|
|
739
740
|
group: Group<R>;
|
|
740
741
|
direction: SortDirection;
|
|
741
742
|
} | null;
|
|
742
|
-
/**
|
|
743
|
+
/** When the table opens (host mount): preselects the default grouping when the user can change it. */
|
|
743
744
|
export declare function initializeTableGrouping<R>(table: Table<R>, host: TableHost): void;
|
|
744
745
|
export declare function countActiveFilters<R>(table: Table<R>, host: TableHost): number;
|
|
745
|
-
/**
|
|
746
|
+
/** Indicators of the applied filters (only filters that declare some have them). */
|
|
746
747
|
export declare function getFilterIndicators<R>(table: Table<R>, host: TableHost): {
|
|
747
748
|
filter: string;
|
|
748
749
|
field: string;
|
|
749
750
|
label: string;
|
|
750
751
|
}[];
|
|
751
|
-
/**
|
|
752
|
+
/** Cycles a column's sort: none → asc → desc → none. */
|
|
752
753
|
export declare function sortTable(host: TableHost, column?: string | null, direction?: string | null): void;
|
|
753
|
-
/**
|
|
754
|
+
/** Loads the page of records matching the host's state. */
|
|
754
755
|
export declare function getTableRecords<R>(table: Table<R>, host: TableHost, adapter: DataAdapter<R>): Promise<RecordPage<R>>;
|
|
755
|
-
/**
|
|
756
|
+
/** Pagination elements: the first and last pages and a window around the current page, with `...` gaps. */
|
|
756
757
|
export declare function paginationElements(current: number, last: number, onEachSide?: number): (number | '...')[];
|
|
757
758
|
export declare const useColorManager: (manager: ColorManager) => void;
|
|
758
759
|
export type RenderTableOptions<R> = {
|
|
@@ -767,20 +768,20 @@ export type RenderTableOptions<R> = {
|
|
|
767
768
|
icon: string;
|
|
768
769
|
key: string;
|
|
769
770
|
}[]>;
|
|
770
|
-
/** `false
|
|
771
|
+
/** `false`: reordering is not offered (user not authorized). */
|
|
771
772
|
canReorder?: boolean;
|
|
772
|
-
/** HTML
|
|
773
|
+
/** HTML placed in `.fi-ta`, after the table container (action modals). */
|
|
773
774
|
after?: string;
|
|
774
|
-
/**
|
|
775
|
+
/** Already rendered HTML of the table header actions. */
|
|
775
776
|
headerActions?: string[];
|
|
776
|
-
/** HTML
|
|
777
|
+
/** Already rendered HTML of the row actions (ActionGroup…), replacing the `rowActions` links. */
|
|
777
778
|
rowActionsHtml?: (record: R) => Promise<string>;
|
|
778
779
|
bulkActions?: string[];
|
|
779
|
-
/** HTML
|
|
780
|
+
/** HTML of the filters form (`tableFiltersForm` schema), if there are filters. */
|
|
780
781
|
filtersForm?: string | null;
|
|
781
782
|
};
|
|
782
|
-
/**
|
|
783
|
+
/** Maximum number of rows shown (and reorderable) in reordering mode. */
|
|
783
784
|
export declare const REORDER_LIMIT = 1000;
|
|
784
|
-
/**
|
|
785
|
+
/** Maximum records read for a `groupsOnly` table (which is not paginated). */
|
|
785
786
|
export declare const GROUPS_ONLY_LIMIT = 1000;
|
|
786
787
|
export declare function renderTable<R>(table: Table<R>, host: TableHost, adapter: DataAdapter<R>, options?: RenderTableOptions<R>): Promise<string>;
|