pivotkit-react 0.1.0 → 0.3.0

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.
Files changed (61) hide show
  1. package/CHANGELOG.md +306 -1
  2. package/README.md +48 -298
  3. package/dist/chunks/{chunk-ILHFIV2P.js → chunk-32Z33U6S.js} +58 -78
  4. package/dist/chunks/chunk-7CC4JHDY.js +363 -0
  5. package/dist/chunks/chunk-APB4NW4O.js +434 -0
  6. package/dist/chunks/chunk-EM23V5GH.js +183 -0
  7. package/dist/chunks/{chunk-KKJO36W5.js → chunk-IOPAM4JD.js} +412 -365
  8. package/dist/chunks/chunk-RWYHJRQO.js +99 -0
  9. package/dist/chunks/unused-texts-K3VFH65P.js +10 -0
  10. package/dist/chunks/unused-texts-de-OW4TGIVX.js +6 -0
  11. package/dist/echarts.js +96 -11
  12. package/dist/index.js +654 -560
  13. package/dist/labels.js +13 -4
  14. package/dist/menu-texts-de.js +6 -0
  15. package/dist/menus.js +2905 -550
  16. package/dist/styles.css +738 -216
  17. package/package.json +2 -2
  18. package/types/chart-layout.d.ts +111 -0
  19. package/types/chart-types.d.ts +0 -91
  20. package/types/chip-menus.d.ts +20 -4
  21. package/types/dnd.d.ts +8 -4
  22. package/types/drill-panel.d.ts +5 -22
  23. package/types/drill-table.d.ts +71 -0
  24. package/types/drill.d.ts +0 -36
  25. package/types/filter-level.d.ts +16 -0
  26. package/types/filter.d.ts +31 -0
  27. package/types/help.d.ts +14 -0
  28. package/types/icons.d.ts +4 -0
  29. package/types/labels.d.ts +114 -101
  30. package/types/lazy-menus.d.ts +18 -6
  31. package/types/levels.d.ts +105 -0
  32. package/types/menu-fields.d.ts +80 -0
  33. package/types/menu-labels-de.d.ts +2 -0
  34. package/types/menu-labels.d.ts +270 -13
  35. package/types/menu-ops.d.ts +286 -0
  36. package/types/menu-texts.d.ts +2 -0
  37. package/types/menu-topics.d.ts +293 -0
  38. package/types/menus.d.ts +2 -2
  39. package/types/names.d.ts +160 -20
  40. package/types/overflow.d.ts +4 -1
  41. package/types/place.d.ts +44 -0
  42. package/types/popover.d.ts +10 -6
  43. package/types/section.d.ts +8 -28
  44. package/types/share-actions.d.ts +99 -0
  45. package/types/share.d.ts +0 -9
  46. package/types/table.d.ts +9 -3
  47. package/types/templates.d.ts +7 -1
  48. package/types/tips.d.ts +1 -34
  49. package/types/toolbar-panels.d.ts +20 -10
  50. package/types/unused-load.d.ts +23 -0
  51. package/types/unused-texts-de.d.ts +2 -0
  52. package/types/unused-texts.d.ts +136 -0
  53. package/types/unused.d.ts +22 -0
  54. package/types/use-view-history.d.ts +8 -4
  55. package/types/view-history.d.ts +23 -6
  56. package/types/view-ops.d.ts +80 -119
  57. package/types/view-save.d.ts +76 -0
  58. package/types/view-store.d.ts +13 -6
  59. package/types/zones.d.ts +5 -4
  60. package/dist/chunks/chunk-C32TYSHG.js +0 -441
  61. package/dist/chunks/chunk-XYP47DJ3.js +0 -123
@@ -1,6 +1,8 @@
1
1
  export type Zone = "rows" | "cols" | "values" | "filters";
2
2
  /** @typedef {"rows" | "cols" | "values" | "filters"} Zone */
3
3
  export declare const ZONES: readonly Zone[];
4
+ export declare const clone: (view: any) => any;
5
+ export declare const same: (a: any, b: any) => boolean;
4
6
  /** The fields shown in the Filters zone: filtered fields that are on no axis, once each. */
5
7
  export declare function filterZoneFields(view: any): any[];
6
8
  /** The axis a field is on, or null. */
@@ -95,30 +97,6 @@ export declare function fieldAt(view: any, zone: any, index: any): any;
95
97
  export declare function moveField(view: any, from: Zone, fromIndex: number, to: Zone, toIndex: number | undefined, options?: AddOptions): any;
96
98
  /** Moves an entry within a zone. */
97
99
  export declare function reorder(view: any, zone: any, from: any, to: any): any;
98
- /**
99
- * Changes properties of the value at `index` (agg, format, label, showAs, conditional). A new
100
- * aggregator drops the "show values as" calculation (a running total does not fit an average) and
101
- * picks the format: one the patch names; else the user's own format (one that is not the host's
102
- * default) while the result keeps its unit (average to median: still years); else the host's format
103
- * for the field (fieldDefaults) when its aggregator has that unit; else none, the automatic one.
104
- * @param {any} view
105
- * @param {number} index
106
- * @param {{ agg?: string, format?: string | null, label?: string | null, showAs?: object | null, conditional?: object | null }} patch
107
- * @param {{ defaults?: { agg?: string, format?: string } }} [options] `defaults`: the host's
108
- * settings for the value's field
109
- */
110
- export declare function updateValue(view: any, index: number, patch: {
111
- agg?: string;
112
- format?: string | null;
113
- label?: string | null;
114
- showAs?: object | null;
115
- conditional?: object | null;
116
- }, options?: {
117
- defaults?: {
118
- agg?: string;
119
- format?: string;
120
- };
121
- }): any;
122
100
  /**
123
101
  * The smallest and the largest number of a number column, for the range form; null without numbers.
124
102
  * @param {import("pivotkit-core").Encoded} encoded
@@ -130,18 +108,17 @@ export declare function numberRange(encoded: import("pivotkit-core").Encoded, fi
130
108
  max: number;
131
109
  } | null;
132
110
  /**
133
- * Why ranges of `size` from `start` cannot hold the numbers of `range`, or null when they can. A start
134
- * so far from the values that a range's bounds can no longer be told apart in a double (1e17 for
135
- * magnitudes of 2 to 9 in ranges of 0.5) would put every row into "(blank)": "far".
136
- * @param {number} size
137
- * @param {number} start
138
- * @param {{ min: number, max: number } | null} range
139
- * @returns {"far" | null}
111
+ * The first and the last date of a date column (wall-clock ms, as the column holds them), or null
112
+ * for another type or a column without dates: the data's span, which a relative range is measured
113
+ * against ("2026 has no data") and the anchor "latest" counts back from.
114
+ * @param {import("pivotkit-core").Encoded} encoded
115
+ * @param {string} field a date column (a grouping's source, see sourceOf)
116
+ * @returns {{ min: number, max: number } | null}
140
117
  */
141
- export declare function binProblem(size: number, start: number, range: {
118
+ export declare function dateSpan(encoded: import("pivotkit-core").Encoded, field: string): {
142
119
  min: number;
143
120
  max: number;
144
- } | null): "far" | null;
121
+ } | null;
145
122
  /**
146
123
  * The derived field a grouping makes of a field on an axis: replaces it in place. `unit` null removes
147
124
  * the grouping (back to the source field). Returns the view and the new field's name.
@@ -179,46 +156,87 @@ export declare function setSort(view: any, field: any, sort: any): any;
179
156
  export declare function withHostOrders(view: any, orderOf: (field: string) => unknown[] | undefined): any;
180
157
  /** The sort entry of a field, or null. */
181
158
  export declare function sortOf(view: any, field: any): any;
182
- /** Filters of one type of a field. */
183
- export declare function filtersOf(view: any, field: any, types: any): any;
184
159
  /**
185
- * The item filter of a field from the selected values: everything selected removes it; otherwise the
186
- * values not selected are excluded, so values that appear in newer data are shown, as in Excel.
160
+ * The entry setSort writes for a sort the user chose: A to Z is the default without an entry, except
161
+ * for a field with the host's order, which keeps it as an entry, or the host's order would come back
162
+ * (withHostOrders).
163
+ * @param {{ by: string, order: string }} spec
164
+ * @param {boolean} [hostOrdered] the field has the host's order (fieldDefaults.order)
165
+ */
166
+ export declare function sortEntry(spec: {
167
+ by: string;
168
+ order: string;
169
+ }, hostOrdered?: boolean): {
170
+ by: string;
171
+ order: string;
172
+ } | null;
173
+ /**
174
+ * What a click on a header of the table sorts: a row field's name sorts that field by label; a value's
175
+ * name sorts the innermost row field by that value. Only a value's header that stands for the whole
176
+ * row does (its column path is empty: the one value header over all columns, the values without
177
+ * column fields, the grand total column), and only a value that gives a number (numericResult). Null
178
+ * for every other header.
187
179
  * @param {any} view
188
- * @param {string} field
189
- * @param {Array<unknown>} selected values (null is blank)
190
- * @param {Array<unknown>} all every value of the field
180
+ * @param {{ kind: string, field?: string, valueIndex?: number, colPath?: any[] }} cell a header cell of the grid
181
+ * @param {(field: string) => string | undefined} typeOf the column type of a field
182
+ * @returns {{ field: string, ref?: { field: string | null, agg: string } } | null}
191
183
  */
192
- export declare function setItemFilter(view: any, field: string, selected: Array<unknown>, all: Array<unknown>): any;
193
- /** The values an item filter lets through, from the field's values; all of them without a filter. */
194
- export declare function selectedItems(view: any, field: any, all: any): any;
195
- /** The label condition of a field ({ op, value }) or null to remove it. */
196
- export declare function setLabelFilter(view: any, field: any, condition: any): any;
184
+ export declare function headerSortTarget(view: any, cell: {
185
+ kind: string;
186
+ field?: string;
187
+ valueIndex?: number;
188
+ colPath?: any[];
189
+ }, typeOf: (field: string) => string | undefined): {
190
+ field: string;
191
+ ref?: {
192
+ field: string | null;
193
+ agg: string;
194
+ };
195
+ } | null;
197
196
  /**
198
- * Top or bottom N items of a field by a value ({ count, bottom, by }), or null to remove it. `previous`
199
- * is the top filter being edited (the view's own entry); without it the field's top filters are
200
- * replaced. Another top filter of the field (a view may hold two) stays.
197
+ * The sort a header shows (aria-sort): "ascending", "descending", "other" (a custom order), or null
198
+ * when the rows are not in its order; `chosen` when a sort entry of the view puts them in it (the
199
+ * default A to Z of a field without an entry is not chosen).
200
+ * @param {any} view
201
+ * @param {{ field: string, ref?: { field: string | null, agg: string } }} target headerSortTarget's
202
+ * @returns {{ order: "ascending" | "descending" | "other" | null, chosen: boolean }}
201
203
  */
202
- export declare function setTopFilter(view: any, field: any, top: any, previous: any): any;
204
+ export declare function headerSortState(view: any, target: {
205
+ field: string;
206
+ ref?: {
207
+ field: string | null;
208
+ agg: string;
209
+ };
210
+ }): {
211
+ order: "ascending" | "descending" | "other" | null;
212
+ chosen: boolean;
213
+ };
203
214
  /**
204
- * A value condition on a field ({ by, op, value, value2 }, pivotkit-core's `value` filter: "Sum of
205
- * Revenue greater than 1000"), or null to remove it. `previous` is the condition being edited (the
206
- * view's own entry): only that one is replaced or removed; without it every value condition of the
207
- * field is. The field keeps its other filters.
215
+ * The field's sort entry after a click on a header (setSort's argument): a value's header goes from
216
+ * largest first to smallest first to no sort by it (the field's default order); a row field's name
217
+ * from A to Z to Z to A and back, and to A to Z from a sort by a value or a custom order.
208
218
  * @param {any} view
209
- * @param {string} field
210
- * @param {{ by: { field: string | null, agg: string }, op: string, value: number, value2?: number } | null} condition
211
- * @param {object} [previous]
219
+ * @param {{ field: string, ref?: { field: string | null, agg: string } }} target headerSortTarget's
220
+ * @param {boolean} [hostOrdered] the field has the host's order (fieldDefaults.order)
212
221
  */
213
- export declare function setValueFilter(view: any, field: string, condition: {
214
- by: {
222
+ export declare function nextHeaderSort(view: any, target: {
223
+ field: string;
224
+ ref?: {
215
225
  field: string | null;
216
226
  agg: string;
217
227
  };
218
- op: string;
219
- value: number;
220
- value2?: number;
221
- } | null, previous?: object): any;
228
+ }, hostOrdered?: boolean): {
229
+ by: string;
230
+ order: string;
231
+ } | {
232
+ by: string;
233
+ order: string;
234
+ value: any;
235
+ } | null;
236
+ /** Filters of one type of a field. */
237
+ export declare function filtersOf(view: any, field: any, types: any): any;
238
+ /** The values an item filter lets through, from the field's values; all of them without a filter. */
239
+ export declare function selectedItems(view: any, field: any, all: any): any;
222
240
  /**
223
241
  * True when a value gives a number for each cell, so it can be shown as a share, formatted, highlighted,
224
242
  * sorted by and filtered by: not a list of distinct values, not the first or last entry of a text,
@@ -229,44 +247,8 @@ export declare function setValueFilter(view: any, field: string, condition: {
229
247
  export declare function numericResult(spec: {
230
248
  agg: string;
231
249
  }, type: string): boolean;
232
- /**
233
- * The measures to choose from with `ref` among them: a sort, a top N or a condition may go by a
234
- * measure the view no longer shows (its value was removed); it stays a choice, so applying the form
235
- * again keeps it.
236
- * @param {Array<{ field: string | null, agg: string }>} choices
237
- * @param {{ field: string | null, agg: string } | null | undefined} ref
238
- */
239
- export declare function withMeasure(choices: Array<{
240
- field: string | null;
241
- agg: string;
242
- }>, ref: {
243
- field: string | null;
244
- agg: string;
245
- } | null | undefined): {
246
- field: string | null;
247
- agg: string;
248
- }[];
249
250
  /** True when two value references ({ field, agg }) name the same measure. */
250
251
  export declare function sameRef(a: any, b: any): boolean;
251
- /**
252
- * The measures a field on an axis can be sorted, ranked and filtered by: each value of the view that
253
- * gives a number, once per field and aggregator, in the view's order; the row count without one. The
254
- * first one is the default, as pivotkit-core's.
255
- * @param {any} view
256
- * @param {(field: string) => string | undefined} typeOf the column type of a field
257
- * @returns {Array<{ field: string | null, agg: string }>}
258
- */
259
- export declare function measureChoices(view: any, typeOf: (field: string) => string | undefined): Array<{
260
- field: string | null;
261
- agg: string;
262
- }>;
263
- /**
264
- * Removes what the filter of a field keeps out: its item list, its text condition and a value
265
- * condition; Top N has its own control and stays. A field in the Filters zone stays there, unfiltered.
266
- */
267
- export declare function removeFilters(view: any, field: any): any;
268
- /** True when a field has an item, text or value filter that removes something (Top N is not counted). */
269
- export declare function hasFilter(view: any, field: any): any;
270
252
  /** True when a field has a filter that removes something. */
271
253
  export declare function isFiltered(view: any, field: any): any;
272
254
  /** Collapses or expands one group of an axis. */
@@ -296,17 +278,6 @@ export declare function rowFolding(view: any, outer: Array<Array<unknown>>): {
296
278
  * @param {Array<Array<unknown>> | null} paths the paths to collapse; null expands everything
297
279
  */
298
280
  export declare function setCollapsed(view: any, axis: "rows" | "cols", paths: Array<Array<unknown>> | null): any;
299
- /** The four totals of Options, in their order. */
300
- export declare const TOTALS: readonly string[];
301
- /**
302
- * Why a total of Options would change nothing in this view, or null when it changes something: a
303
- * grand total row needs a field in Rows (without one the only row is the total), a grand total column
304
- * one in Columns, subtotals two or more fields on their axis. The key names the text (labels).
305
- * @param {any} view
306
- * @param {string} key one of TOTALS
307
- * @returns {string | null}
308
- */
309
- export declare function totalNoEffect(view: any, key: string): string | null;
310
281
  /** Turns one of the totals on or off. */
311
282
  export declare function setTotal(view: any, key: any, on: any): any;
312
283
  /** Table or chart. */
@@ -332,13 +303,3 @@ export declare function setChartDisplay(view: any, patch: {
332
303
  export declare function swapAxes(view: any): any;
333
304
  /** True when nothing is placed: the UI shows its first steps. */
334
305
  export declare function isEmptyView(view: any): boolean;
335
- /**
336
- * The condition on a field's labels its type offers: "text" for text, "number" for a number (on the
337
- * label as shown), none for a date (or a grouping of one) and a yes/no field, whose items the list
338
- * above chooses.
339
- * @param {import("pivotkit-core").Encoded} encoded
340
- * @param {any} view
341
- * @param {string} field
342
- * @returns {"text" | "number" | null}
343
- */
344
- export declare function conditionKind(encoded: import("pivotkit-core").Encoded, view: any, field: string): "text" | "number" | null;
@@ -0,0 +1,76 @@
1
+ export type LoadedView = {
2
+ name: string;
3
+ scope: "user" | "shared" | null;
4
+ store: boolean;
5
+ storeSource?: string | null;
6
+ };
7
+ export type SaveRights = {
8
+ host: boolean;
9
+ store: boolean;
10
+ publish: boolean;
11
+ sourceId?: string;
12
+ };
13
+ export type SaveWrite = {
14
+ kind: "store";
15
+ at?: number;
16
+ storeSource: string | null;
17
+ } | {
18
+ kind: "host";
19
+ } | {
20
+ kind: "publish";
21
+ };
22
+ export type SaveTarget = SaveWrite | {
23
+ kind: null;
24
+ why: "saveSharedLocked" | "saveNotInViews" | "exportNeedsField";
25
+ };
26
+ export type Entry = {
27
+ name: string;
28
+ scope: string;
29
+ at?: number;
30
+ sourceId?: string;
31
+ };
32
+ /**
33
+ * @typedef {{ name: string, scope: "user" | "shared" | null, store: boolean, storeSource?: string | null }} LoadedView
34
+ * the view loaded: its name, its group (null: a file or a link), whether the browser store keeps it
35
+ * and, there, the data it names
36
+ * @typedef {{ host: boolean, store: boolean, publish: boolean, sourceId?: string }} SaveRights
37
+ * onSaveTemplate is set, the browser store is on, the user may publish (canPublish with
38
+ * onPublishTemplate); the data shown
39
+ * @typedef {{ kind: "store", at?: number, storeSource: string | null } | { kind: "host" } | { kind: "publish" }} SaveWrite
40
+ * where a save goes; `at`: the browser store's view it writes over (none: a view added)
41
+ * @typedef {SaveWrite | { kind: null, why: "saveSharedLocked" | "saveNotInViews" | "exportNeedsField" }} SaveTarget
42
+ * `why`: the label that says why Save is off
43
+ * @typedef {{ name: string, scope: string, at?: number, sourceId?: string }} Entry an entry of the Views menu
44
+ */
45
+ /** Whether Save as can write anywhere. @param {SaveRights} can */
46
+ export declare const canSaveAs: (can: SaveRights) => boolean;
47
+ /**
48
+ * Whether an entry of the Views menu is the view loaded: its name, its group, and for the browser
49
+ * store the data it names.
50
+ * @param {Entry} t
51
+ * @param {LoadedView | null | undefined} loaded
52
+ */
53
+ export declare const isLoadedEntry: (t: Entry, loaded: LoadedView | null | undefined) => boolean;
54
+ /**
55
+ * Where Save writes the loaded view, or why it is off; null when there is no Save to offer (nothing
56
+ * loaded, or no way to save at all).
57
+ * @param {LoadedView | null} loaded
58
+ * @param {ReadonlyArray<Entry>} entries the Views menu's entries
59
+ * @param {SaveRights} can
60
+ * @param {boolean} [empty] the report has no field placed
61
+ * @returns {SaveTarget | null}
62
+ */
63
+ export declare function saveTarget(loaded: LoadedView | null, entries: ReadonlyArray<Entry>, can: SaveRights, empty?: boolean): SaveTarget | null;
64
+ /**
65
+ * Where Save as writes a view named `name`, and the user's view it would replace (null: none, so
66
+ * nothing to ask): the host's own view of that name when the host takes the saves, else the browser
67
+ * store's for this data (or saved without named data).
68
+ * @template {Entry} T
69
+ * @param {string} name
70
+ * @param {ReadonlyArray<T>} entries
71
+ * @param {SaveRights} can
72
+ * @returns {SaveWrite & { replaces: T | null }}
73
+ */
74
+ export declare function saveAsTarget<T extends Entry>(name: string, entries: ReadonlyArray<T>, can: SaveRights): SaveWrite & {
75
+ replaces: T | null;
76
+ };
@@ -8,21 +8,26 @@ export declare const VIEW_STORE_LIMITS: Readonly<{
8
8
  * named data.
9
9
  * @param {string | null} raw
10
10
  * @param {string | undefined} sourceId
11
- * @returns {Array<{ name: string, view: Record<string, unknown>, at: number }>}
11
+ * `sourceId` of an entry: the data it names (none for a view saved without), which tells two views
12
+ * of the same name apart (one for no named data, one for this data).
13
+ * @returns {Array<{ name: string, view: Record<string, unknown>, at: number, sourceId?: string }>}
12
14
  */
13
15
  export declare function storedViews(raw: string | null, sourceId: string | undefined): Array<{
14
16
  name: string;
15
17
  view: Record<string, unknown>;
16
18
  at: number;
19
+ sourceId?: string;
17
20
  }>;
18
21
  /**
19
22
  * The browser store's text after a change: `name` saved for `sourceId` (replacing a view of the same
20
- * name for the same data), or the view at `remove` taken out. A delete checks that the view there is
21
- * still the one named `removeName` (another tab may have changed the store since the menu was drawn)
22
- * and throws "changed" when it is not, so the wrong view is never deleted. The caps apply to a save
23
+ * name for the same data), the view at `replace` written over in its place (Save, and Save as onto a
24
+ * name that exists: its data and its place in the list stay), or the view at `remove` taken out. A
25
+ * delete and a replace check that the view there is still the one named `removeName` or `name`
26
+ * (another tab may have changed the store since the menu was drawn) and throw "changed" when it is
27
+ * not, so the wrong view is never deleted or overwritten. The caps apply to a save
23
28
  * only: a store over them (older caps, changed by hand) can always shrink.
24
29
  * @param {string | null} raw
25
- * @param {{ name?: string, view?: object, sourceId?: string, remove?: number, removeName?: string }} change
30
+ * @param {{ name?: string, view?: object, sourceId?: string, remove?: number, removeName?: string, replace?: number }} change
26
31
  * @param {(kind: "count" | "text" | "changed", max: number) => string} message the Error's message
27
32
  * @returns {string | null} null when nothing is left
28
33
  */
@@ -32,13 +37,14 @@ export declare function changedViews(raw: string | null, change: {
32
37
  sourceId?: string;
33
38
  remove?: number;
34
39
  removeName?: string;
40
+ replace?: number;
35
41
  }, message: (kind: "count" | "text" | "changed", max: number) => string): string | null;
36
42
  /**
37
43
  * Saves or deletes a view in the browser store (see changedViews). Throws an Error with the reason in
38
44
  * the labels' words when the store would hold too much, changed since the menu was drawn, or the
39
45
  * browser refused to keep it.
40
46
  * @param {string | null} raw the store's text now
41
- * @param {{ name?: string, view?: object, sourceId?: string, remove?: number, removeName?: string }} change
47
+ * @param {{ name?: string, view?: object, sourceId?: string, remove?: number, removeName?: string, replace?: number }} change
42
48
  * @param {any} labels with the menus' texts
43
49
  * @param {string} locale for the numbers
44
50
  * @param {(text: string | null) => boolean} keep writes the text (storage.js: writeItem), false when the browser refused
@@ -49,4 +55,5 @@ export declare function storeViews(raw: string | null, change: {
49
55
  sourceId?: string;
50
56
  remove?: number;
51
57
  removeName?: string;
58
+ replace?: number;
52
59
  }, labels: any, locale: string, keep: (text: string | null) => boolean): void;
package/types/zones.d.ts CHANGED
@@ -14,21 +14,22 @@ export declare function zoneEntries(view: any, types: any, labels: any): {
14
14
  };
15
15
  /**
16
16
  * @param {{ view: any, types: Map<string, string>, labels: import("./labels.js").UiLabels,
17
- * commit: (view: object, note?: any) => void, openFilter: (field: string, anchor: HTMLElement) => void,
17
+ * commit: (view: object, note?: any) => void, earlier?: () => any[],
18
18
  * encoded: import("pivotkit-core").Encoded, locale: string, onSwap: () => void,
19
19
  * id: string, folded: boolean, onShow: () => void, defaultsOf?: (field: string) => import("./index.js").FieldDefaults | undefined,
20
20
  * infoOf?: (field: string) => import("./field-info.js").FieldInfo | undefined, explain?: boolean, showInfo?: boolean }} props
21
21
  * `explain`: an "i" next to each zone's title that says what the zone does; `showInfo` false: no "i"
22
22
  * of a field description on the chips (Options → Help)
23
23
  * `folded`: the compact layout's one line; `defaultsOf`: the host's settings for a source field (fieldDefaults);
24
- * `infoOf`: the host's description of a field (its source field's for a grouping)
24
+ * `infoOf`: the host's description of a field (its source field's for a grouping); `earlier`: the
25
+ * history's views before this one (a value's own colours for its Highlight)
25
26
  */
26
- export declare function Zones({ view, types, labels, commit, openFilter, encoded, locale, onSwap, id, folded, onShow, defaultsOf, infoOf, explain, showInfo }: {
27
+ export declare function Zones({ view, types, labels, commit, earlier, encoded, locale, onSwap, id, folded, onShow, defaultsOf, infoOf, explain, showInfo }: {
27
28
  view: any;
28
29
  types: Map<string, string>;
29
30
  labels: import("./labels.js").UiLabels;
30
31
  commit: (view: object, note?: any) => void;
31
- openFilter: (field: string, anchor: HTMLElement) => void;
32
+ earlier?: () => any[];
32
33
  encoded: import("pivotkit-core").Encoded;
33
34
  locale: string;
34
35
  onSwap: () => void;