@pythia-software/query-table-core 0.9.6 β†’ 0.9.8

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
@@ -1,3 +1,43 @@
1
+ /** Portable presentation only. Arrays are ordered sets; their order is retained. */
2
+ interface JsonInspectionState {
3
+ version: 1;
4
+ open: boolean;
5
+ search: string;
6
+ searchMode: "filter" | "find";
7
+ raw: boolean;
8
+ collapsedPaths: string[];
9
+ expandedBuckets: string[];
10
+ visibleEntryLimit: number;
11
+ selectedMatch?: JsonMatchIdentity;
12
+ /** Explicit expansion choices made while searching, in interaction order. */
13
+ searchOverrides: {
14
+ path: string;
15
+ expanded: boolean;
16
+ }[];
17
+ }
18
+ interface JsonMatchIdentity {
19
+ path: string;
20
+ part: "key" | "value" | "path";
21
+ start: number;
22
+ }
23
+ interface JsonInspectionScope {
24
+ dataset: string;
25
+ rowId: RowId;
26
+ field: string;
27
+ }
28
+ interface ScopedJsonInspectionState extends JsonInspectionScope {
29
+ state: JsonInspectionState;
30
+ }
31
+ declare const MAX_JSON_INSPECTIONS = 200;
32
+ declare const MAX_JSON_PATHS = 5000;
33
+ /** Bracket JSONPath, as emitted by the inspector. No dot splitting or evaluation. */
34
+ declare function isJsonPath(path: unknown): path is string;
35
+ declare function isJsonBucketId(path: unknown): path is string;
36
+ declare function jsonInspectionScopeKey(scope: JsonInspectionScope): string;
37
+ declare function parseJsonInspectionState(input: unknown): JsonInspectionState;
38
+ /** Reject the entire envelope on an invalid/duplicate scope, never restore a different record. */
39
+ declare function parseJsonInspections(input: unknown): ScopedJsonInspectionState[];
40
+
1
41
  /** Presentation hints only: field types still determine query/filter semantics. */
2
42
  interface JsonCellDisplay {
3
43
  kind: "json";
@@ -130,6 +170,10 @@ interface SelectConfig {
130
170
  default?: boolean;
131
171
  /** Default column width (px); a per-column override rides in QueryState.select. */
132
172
  width?: number;
173
+ /** Narrowest usable width (px) when fitting columns to the screen, such as
174
+ * the room a host renderer's buttons need. Measured native controls are
175
+ * always kept whole; this adds room they cannot measure. */
176
+ minWidth?: number;
133
177
  align?: Align;
134
178
  }
135
179
  interface AggregateConfig {
@@ -268,19 +312,44 @@ declare function formulaRuntime(ast: FormulaNode, inputs: Record<string, Formula
268
312
  type MetricValue = number | string | boolean | null;
269
313
  type MetricKey = MetricValue;
270
314
  type MetricScope = "allMatching" | "shownRows";
315
+ /** Calendar intervals: each bucket is one interval on the timeline, keyed by
316
+ * its start as an ISO instant. */
317
+ type MetricCalendarInterval = "hour" | "day" | "week" | "month" | "year";
318
+ /** Cyclic intervals: each bucket is one slot of a repeating cycle, keyed by a
319
+ * number. `hourOfDay` is the local hour, 0–23; `dayOfWeek` the ISO weekday,
320
+ * 1 (Monday) to 7 (Sunday). */
321
+ type MetricCycleInterval = "hourOfDay" | "dayOfWeek";
322
+ /** Summarise each cyclic slot over its occurrences: every whole day or hour
323
+ * the slot covers inside the query's time bounds. */
324
+ interface MetricDateOccurrence {
325
+ /** One occurrence: "day" (dayOfWeek only) or "hour". */
326
+ interval: "hour" | "day";
327
+ /** Count occurrences without rows: 0 for direct COUNT, COUNT_DISTINCT and
328
+ * SUM metrics, no value for other expressions. false leaves them out. */
329
+ includeEmpty: boolean;
330
+ }
271
331
  /** Calendar grouping, currently executed over complete local populations. */
272
332
  interface MetricDateGrouping {
273
333
  field: string;
274
- interval: "hour" | "day" | "week" | "month" | "year";
334
+ interval: MetricCalendarInterval | MetricCycleInterval;
275
335
  /** IANA timezone identifier; omitted settings retain UTC behavior. */
276
336
  timeZone?: string;
337
+ /** Add a bucket for every interval of the range, or for every slot of a
338
+ * cyclic interval. */
277
339
  includeEmpty: boolean;
340
+ /** The calendar range empty intervals fill; for a cyclic interval, the range
341
+ * whose empty occurrences count. */
278
342
  range: "query" | "observed" | "custom";
279
343
  start?: string;
280
344
  end?: string;
281
345
  /** "exclude" leaves out intervals the query's bounds cut, and intervals that
282
- * have not ended by the evaluation time; omitted includes them. */
346
+ * have not ended by the evaluation time; omitted includes them. A cyclic
347
+ * interval's intervals are its hours or days. */
283
348
  partialIntervals?: "include" | "exclude";
349
+ /** Cyclic intervals only: each slot's value is the mean of its
350
+ * per-occurrence values, and a box distribution summarises them. Only whole
351
+ * occurrences count. Computed from a calendar metric by planMetricSeries. */
352
+ occurrence?: MetricDateOccurrence;
284
353
  }
285
354
  /** A trailing window over a calendar metric's intervals. */
286
355
  interface MetricWindow {
@@ -298,6 +367,19 @@ interface MetricWindow {
298
367
  /** Divide each bucket by the total of all groups ("total") or of its first
299
368
  * grouping key ("group0"), such as one calendar interval. */
300
369
  type MetricShare = "total" | "group0";
370
+ /** A per-group minimum measured over something other than rows: the distinct
371
+ * non-null values of one field (like COUNT_DISTINCT), or the sum of one
372
+ * numeric field (like SUM; nulls add nothing). Exactly one of `distinct` and
373
+ * `sum` is set. A group whose measure is an error is kept. */
374
+ type MetricMinCountOf = {
375
+ min: number;
376
+ distinct: string;
377
+ sum?: never;
378
+ } | {
379
+ min: number;
380
+ sum: string;
381
+ distinct?: never;
382
+ };
301
383
  interface MetricValueFormat {
302
384
  kind: "number" | "percent" | "duration" | "date" | "time" | "datetime";
303
385
  decimals?: number;
@@ -396,6 +478,8 @@ interface MetricDiagnostic extends FormulaDiagnostic {
396
478
  }
397
479
  /** Host must enforce snapshot against the row response; this token alone does not pin data. */
398
480
  interface MetricQuery {
481
+ /** The table's host-owned state when `hostQuery` is configured. */
482
+ hostState?: HostQueryState;
399
483
  snapshot?: string;
400
484
  profile?: string;
401
485
  expectedRevisions?: Record<string, string>;
@@ -418,6 +502,8 @@ interface MetricCapabilities {
418
502
  filters?: boolean;
419
503
  /** Executes AggregationClause.minCount and reports hiddenGroups. */
420
504
  minCount?: boolean;
505
+ /** Also executes an object minCount: distinct values or a sum per group. */
506
+ minCountMeasures?: boolean;
421
507
  maxGroups?: number;
422
508
  profile?: string;
423
509
  }
@@ -457,6 +543,8 @@ interface PropertyViewState {
457
543
  /** Property label column width as a percentage, shared with the saved view. */
458
544
  labelWidth?: number;
459
545
  }
546
+ /** Projection coverage used by rendering and semantic attention alike. */
547
+ declare function isPropertyFieldLoaded<Row>(field: FieldDef<Row>, loadedFields?: readonly string[]): boolean;
460
548
  declare const MAX_PROPERTIES = 200;
461
549
  declare function normalizePropertyFormat(input: unknown): PropertyFormat | undefined;
462
550
  /** Strict envelope/version checks prevent interpreting future saved views as empty. */
@@ -501,6 +589,33 @@ declare function readObjectReference<Row>(field: FieldDef<Row>, fields: FieldDef
501
589
  /** Only unambiguous, fully mapped constraints become links. Explicit metadata wins. */
502
590
  declare function discoverFieldRelationships<Row>(fields: FieldDef<Row>[], keys: ForeignKey[], types: ObjectTypeDefinition[]): FieldDef<Row>[];
503
591
 
592
+ /** Calendar intervals a grouping key can bucket a datetime field by. */
593
+ declare const GROUP_KEY_INTERVALS: readonly MetricCalendarInterval[];
594
+ /** A grouping key that buckets a datetime field by calendar interval: one
595
+ * group per interval, keyed by the interval's start as an ISO instant. The
596
+ * result column is named after the field. Intervals follow the metric
597
+ * calendar (`dateGrouping`), including daylight-saving changes; weeks start
598
+ * on Monday. */
599
+ interface CalendarGroupKey {
600
+ field: string;
601
+ interval: MetricCalendarInterval;
602
+ /** IANA timezone identifier; omitted means UTC. */
603
+ timeZone?: string;
604
+ }
605
+ /** A field name (group by its exact value) or a calendar key. */
606
+ type GroupKey = string | CalendarGroupKey;
607
+ declare function isCalendarGroupKey(key: GroupKey): key is CalendarGroupKey;
608
+ /** The source field a key reads; also the name of its result column. */
609
+ declare function groupKeyField(key: GroupKey): string;
610
+ /** Result column names, in key order. */
611
+ declare function groupKeyFields(keys: readonly GroupKey[]): string[];
612
+ /** The calendar key on `field`, if that key buckets by interval. */
613
+ declare function calendarGroupKey(keys: readonly GroupKey[], field: string): CalendarGroupKey | undefined;
614
+ /** `=` (or `is_null`) per key, in key order, or null when any key cannot be
615
+ * matched exactly (textarray, unknown or unfilterable fields, unparseable
616
+ * datetimes). A calendar key adds `>= start` and `< end` for its interval. */
617
+ declare function groupKeyTerms(keys: readonly GroupKey[], group: Record<string, unknown>, schema: FieldSchema): WhereClause[] | null;
618
+
504
619
  type QueryFacet = "filters" | "columns" | "order" | "grouping" | "metrics" | "limit";
505
620
  interface QueryPatch {
506
621
  /** Host identity for the patch; not interpreted. */
@@ -629,7 +744,10 @@ declare function isGroupLinkField(field: Pick<FieldDef, "render"> | undefined):
629
744
  interface GroupingView {
630
745
  version: 2;
631
746
  mode: "rows" | "groups";
747
+ /** Result key columns: the field each key reads, in key order. */
632
748
  keys: string[];
749
+ /** The keys as defined, including calendar intervals; absent means `keys`. */
750
+ groupKeys?: GroupKey[];
633
751
  summaries: SummaryColumn[];
634
752
  representative: RepresentativeRow | null;
635
753
  input: QueryState;
@@ -639,7 +757,10 @@ interface GroupingView {
639
757
  * HAVING in this mode; source.where is the pre-group WHERE. The source snapshot
640
758
  * also restores the record layout, paging, metrics and item details on exit. */
641
759
  interface GroupingDefinition {
642
- keys: string[];
760
+ /** Field names, or calendar keys (`{ field, interval, timeZone }`) that
761
+ * group a datetime field by interval. Each field appears once; its result
762
+ * column is named after the field. */
763
+ keys: GroupKey[];
643
764
  summaries: SummaryColumn[];
644
765
  representative: RepresentativeRow | null;
645
766
  diagnostics?: string[];
@@ -653,14 +774,14 @@ declare const MAX_SUMMARY_COLUMNS = 64;
653
774
  declare const MAX_RESULT_GROUPS = 10000;
654
775
  declare function withoutGrouping(query: QueryState): QueryState;
655
776
  /** Leave the grouping stage: the source snapshot restores the record WHERE,
656
- * layout, ordering, paging, metrics and item details. Ungrouped queries are
657
- * returned unchanged. */
777
+ * layout, ordering, paging, metrics and item details, and keeps the host
778
+ * state of the grouped query. Ungrouped queries are returned unchanged. */
658
779
  declare function exitGrouping(query: QueryState): QueryState;
659
780
  /** The grouping-key transition behind the grouping controls. Empty keys exit
660
781
  * the stage; an ungrouped query becomes the source of a new stage that shows
661
782
  * only its keys; a grouped query swaps keys, dropping result columns, HAVING
662
783
  * terms and sorts on removed keys and clearing group metrics. */
663
- declare function withGroupingKeys(query: QueryState, keys: string[]): QueryState;
784
+ declare function withGroupingKeys(query: QueryState, keys: GroupKey[]): QueryState;
664
785
  declare const OP_LABEL: Record<SummaryOp, string>;
665
786
  /** Bind aggregation helpers to this instance's source catalogue. */
666
787
  declare function createGroupingModel<InputRow>(inputSchema: FieldSchema<InputRow>): {
@@ -674,10 +795,10 @@ declare function createGroupingModel<InputRow>(inputSchema: FieldSchema<InputRow
674
795
  summaryExpression: (column: SummaryColumn) => string;
675
796
  summaryProblem: (column: SummaryColumn) => string | null;
676
797
  summaryLabel: (column: SummaryColumn) => string;
677
- linkProblem: (column: SummaryColumn, keys: string[], summaries: SummaryColumn[]) => string | null;
798
+ linkProblem: (column: SummaryColumn, keys: GroupKey[], summaries: SummaryColumn[]) => string | null;
678
799
  linkDiagnostics: (definition: Pick<GroupingDefinition, "keys" | "summaries">) => string[];
679
- resultSchema: (keys: string[], summaries: SummaryColumn[]) => FieldSchema<Row>;
680
- groupRows: (rows: InputRow[], schema: FieldSchema<InputRow>, keys: string[], summaries: SummaryColumn[], rule?: RepresentativeRow | null) => Row[];
800
+ resultSchema: (keys: GroupKey[], summaries: SummaryColumn[]) => FieldSchema<Row>;
801
+ groupRows: (rows: InputRow[], schema: FieldSchema<InputRow>, keys: GroupKey[], summaries: SummaryColumn[], rule?: RepresentativeRow | null) => Row[];
681
802
  filteredInput: (rows: InputRow[], query: QueryState, schema: FieldSchema<InputRow>, options?: QueryEvaluationOptions) => InputRow[];
682
803
  reconcileRepresentative: (query: QueryState, summaries: SummaryColumn[], schema: FieldSchema<Row>, remove: boolean) => QueryState;
683
804
  validate: (definition: GroupingDefinition) => void;
@@ -723,25 +844,59 @@ interface SetFilterMetadata {
723
844
  values: string[];
724
845
  }
725
846
  /** A disjunction of predicates β€” the inner OR of conjunctive normal form. Every
726
- * member is a plain literal; nesting is intentionally not allowed yet (CNF
727
- * only), but the object shape leaves room to grow. */
847
+ * member is a plain literal. See `OrOfAndsGroup` for an OR whose members may
848
+ * themselves be conjunctions. */
728
849
  interface OrGroup {
729
850
  any: WhereClause[];
730
851
  setFilter?: SetFilterMetadata;
731
852
  }
732
- /** One conjunct of the WHERE clause: either a single predicate or an OR group.
733
- * `QueryState.where` is the AND of these terms, so the whole WHERE is
734
- * conjunctive normal form β€” `(a) AND (b OR c) AND (d)`. A bare literal is
735
- * equivalent to a one-element OR group; normalization flattens singleton groups
736
- * back to a literal so equality/encoding stay canonical. */
737
- type WhereTerm = WhereClause | OrGroup;
738
- /** Narrow a term to an OR group. A literal always carries `field`; a group never
739
- * does and always carries an `any` array. */
853
+ /** One branch of an `OrOfAndsGroup` that ANDs several literals. Members are
854
+ * always plain literals: nesting stops at `any` β†’ `all` β†’ clause. */
855
+ interface WhereConjunction {
856
+ all: WhereClause[];
857
+ }
858
+ /** One alternative of an `OrOfAndsGroup`: a literal or a conjunction. */
859
+ type WhereBranch = WhereClause | WhereConjunction;
860
+ /** A disjunction of conjunctions β€” `(a AND b) OR (c AND d)` β€” written
861
+ * `{ any: [{ all: [a, b] }, { all: [c, d] }] }`. A branch may also be a bare
862
+ * literal. It selects the union of its branches' rows, such as a legend
863
+ * selection of several (provider, model) pairs, without the exponential
864
+ * AND-of-ORs rewrite. Normalization keeps the shape canonical: a one-literal
865
+ * conjunction becomes that literal, a group whose branches are all literals is
866
+ * an `OrGroup`, and a single conjunction becomes top-level literals. Every
867
+ * literal counts against `MAX_WHERE_CLAUSES`, which therefore also bounds the
868
+ * number of branches. Each literal keeps its own null-exclusive negation; the
869
+ * group itself is never negated. */
870
+ interface OrOfAndsGroup {
871
+ any: WhereBranch[];
872
+ setFilter?: SetFilterMetadata;
873
+ }
874
+ /** One conjunct of the WHERE clause: a single predicate, an OR group, or an OR
875
+ * of conjunctions. `QueryState.where` is the AND of these terms β€”
876
+ * `(a) AND (b OR c) AND ((d AND e) OR f)`. A bare literal is equivalent to a
877
+ * one-element OR group; normalization flattens singleton groups back to a
878
+ * literal so equality/encoding stay canonical. */
879
+ type WhereTerm = WhereClause | OrGroup | OrOfAndsGroup;
880
+ /** Narrow a branch to a conjunction. */
881
+ declare function isWhereConjunction(branch: WhereBranch): branch is WhereConjunction;
882
+ /** Narrow a term to a plain OR group (every member a literal). A literal
883
+ * always carries `field`; a group never does and always carries an `any`
884
+ * array. An `OrOfAndsGroup` is not an `OrGroup`. */
740
885
  declare function isOrGroup(term: WhereTerm): term is OrGroup;
741
- /** The predicate literals a term contributes, in order: the term itself for a
742
- * literal, or its members for a group. Handy for anything that must visit every
743
- * predicate regardless of grouping (field allowlisting, SELECT projection). */
886
+ /** Narrow a term to an OR group with at least one conjunction branch. */
887
+ declare function isOrOfAndsGroup(term: WhereTerm): term is OrOfAndsGroup;
888
+ /** Narrow a term to either kind of group (anything carrying `any`). */
889
+ declare function isWhereGroup(term: WhereTerm): term is OrGroup | OrOfAndsGroup;
890
+ /** The predicate literals a term references, in order: the term itself for a
891
+ * literal, a group's members, and the members of each conjunction branch.
892
+ * Handy for anything that must visit every predicate regardless of grouping
893
+ * (field allowlisting, SELECT projection, budgets); it does not preserve
894
+ * meaning β€” use `branchesOf` to evaluate a term. */
744
895
  declare function predicatesOf(term: WhereTerm): WhereClause[];
896
+ /** A term as a disjunction of conjunctions: it matches when every literal of
897
+ * some branch matches. A literal is `[[literal]]`, an OR group one
898
+ * single-literal branch per member. */
899
+ declare function branchesOf(term: WhereTerm): WhereClause[][];
745
900
  /** One ORDER BY term. Array order in `QueryState.orderBy` is the sort priority. */
746
901
  interface OrderByClause {
747
902
  field: string;
@@ -810,10 +965,12 @@ interface AggregationClause {
810
965
  * mode it refers to grouped-result fields. Shown-row metrics apply it inside
811
966
  * the shown page. */
812
967
  where?: WhereTerm[];
813
- /** Drop groups with fewer than this many rows (counted after `where`) before
814
- * sorting, `groupLimit` and Other. Requires at least one grouping field;
815
- * integer 1–1,000,000. Removed groups are reported as `hiddenGroups`. */
816
- minCount?: number;
968
+ /** Drop small groups before sorting, `groupLimit` and Other. A number counts
969
+ * rows (after `where`); `{ min, distinct: field }` counts a field's distinct
970
+ * non-null values and `{ min, sum: field }` sums a numeric field, ignoring
971
+ * nulls. Requires at least one grouping field; `min` is an integer
972
+ * 1–1,000,000. Removed groups are reported as `hiddenGroups`. */
973
+ minCount?: number | MetricMinCountOf;
817
974
  /** A trailing window or running value over the calendar intervals of
818
975
  * `dateGrouping`. Computed from ordinary metrics, so every engine supports it. */
819
976
  window?: MetricWindow;
@@ -841,8 +998,32 @@ interface ItemDetailsState {
841
998
  id: RowId;
842
999
  mode: "modal" | "expand";
843
1000
  };
844
- }
1001
+ /** Record-specific JSON presentation; independent of property instance/layout IDs. */
1002
+ jsonInspections?: ScopedJsonInspectionState[];
1003
+ }
1004
+ /**
1005
+ * Query state a host owns and registers with `useQueryTable({ hostQuery })`,
1006
+ * such as a keyword clause it runs itself. It travels with the table query
1007
+ * through saves, links, history and resets as one definition. `params` are
1008
+ * named lists of strings, like URL search parameters; the host's own
1009
+ * `normalize` interprets them. Version 0 marks a payload that could not be
1010
+ * read, and is always rejected on restore.
1011
+ */
1012
+ interface HostQueryState {
1013
+ version: number;
1014
+ params: Record<string, string[]>;
1015
+ }
1016
+ declare const MAX_HOST_QUERY_PARAMS = 64;
1017
+ declare const MAX_HOST_QUERY_VALUES = 64;
1018
+ declare const MAX_HOST_QUERY_VALUE_LENGTH = 4000;
1019
+ declare const MAX_HOST_QUERY_STATE_BYTES: number;
1020
+ /** Validates host state and returns its canonical form (parameters sorted by
1021
+ * name, values in order). Throws on a malformed or oversized payload. */
1022
+ declare function parseHostQueryState(input: unknown): HostQueryState;
845
1023
  interface QueryState {
1024
+ /** Host-owned state registered through `useQueryTable({ hostQuery })`.
1025
+ * Only the top-level query carries it; a grouping source never does. */
1026
+ hostState?: HostQueryState;
846
1027
  /** Optional row-producing stage. `grouping.source` is the original record
847
1028
  * query (its WHERE runs first). This query selects/filters/sorts the groups;
848
1029
  * its `where` therefore represents HAVING. Only one stage is supported. */
@@ -988,6 +1169,9 @@ interface ServerQuery {
988
1169
  orderBy: OrderByClause[];
989
1170
  limit: number;
990
1171
  offset: number;
1172
+ /** The table's host-owned state when `hostQuery` is configured; hosts run
1173
+ * their own clauses from it. Query Table does not interpret it. */
1174
+ hostState?: HostQueryState;
991
1175
  }
992
1176
  /** Project a QueryState into the server request, dropping client-only filters,
993
1177
  * client-only sorts, and remapping sort fields through `sort.field`. */
@@ -997,6 +1181,8 @@ declare function toServerQuery<Row>(q: QueryState, schema: FieldSchema<Row>): Se
997
1181
  * metrics describe every matching row, not the visible page. Mirrors the Go
998
1182
  * AggSpec list. */
999
1183
  interface AggregationRequest {
1184
+ /** The table's host-owned state when `hostQuery` is configured. */
1185
+ hostState?: HostQueryState;
1000
1186
  diagnostics?: MetricDiagnostic[];
1001
1187
  where: WhereTerm[];
1002
1188
  aggregations: AggregationClause[];
@@ -1022,6 +1208,9 @@ interface AggregationBucket {
1022
1208
  /** Calendar intervals combined into a windowed point (`AggregationClause.window`);
1023
1209
  * fewer than its periods where the window starts before the first interval. */
1024
1210
  intervals?: number;
1211
+ /** Occurrences summarised by a cyclic slot (`dateGrouping.occurrence`):
1212
+ * those with a value, the samples of its mean and box. */
1213
+ occurrences?: number;
1025
1214
  /** The metric: a number for count/sum/avg, or the column's value for min/max
1026
1215
  * (which may be a string for text/datetime). null when undefined (e.g. avg of
1027
1216
  * an all-null column). */
@@ -1219,12 +1408,46 @@ declare function reduceMetricValues(node: Extract<FormulaNode, {
1219
1408
  declare function evaluateMetricReductions(plan: MetricPlan, reductions: readonly FormulaResult[]): FormulaResult;
1220
1409
  declare function metricExpression(clause: AggregationClause): string;
1221
1410
  declare function hasRegex(plan: FormulaPlan): boolean;
1411
+ /** A box over a cyclic slot's per-occurrence values: its input is the
1412
+ * metric itself, evaluated once per occurrence. */
1413
+ declare function occurrenceDistribution(c: AggregationClause): boolean;
1222
1414
  declare function metricPlans(c: AggregationClause, schema: FieldSchema, resolve?: (name: string) => FormulaPlan | undefined): FormulaPlan[];
1223
1415
  declare function validateMetric(c: AggregationClause, schema: FieldSchema, resolve?: (name: string) => FormulaPlan | undefined): FormulaDiagnostic[];
1416
+ /** The threshold of `AggregationClause.minCount` in either form. */
1417
+ declare function metricMinCount(c: {
1418
+ minCount?: AggregationClause["minCount"] | undefined;
1419
+ }): number | undefined;
1420
+ /** What an object `minCount` measures: the aggregate whose value per group
1421
+ * must reach `min`. Undefined when `minCount` counts rows. */
1422
+ declare function metricMinCountMeasure(c: {
1423
+ minCount?: AggregationClause["minCount"] | undefined;
1424
+ }): {
1425
+ op: "count_distinct" | "sum";
1426
+ field: string;
1427
+ } | undefined;
1428
+ /** A minimum in words: "3 rows", "5 distinct Conversation values" or
1429
+ * "10 total Calls". `label` names a field (default: its name). */
1430
+ declare function metricMinCountText(c: {
1431
+ minCount?: AggregationClause["minCount"] | undefined;
1432
+ }, label?: (field: string) => string): string | undefined;
1433
+ /** The aggregate plan of an object `minCount`, such as SUM([calls]). */
1434
+ declare function metricMinCountPlan(c: {
1435
+ minCount?: AggregationClause["minCount"] | undefined;
1436
+ }, schema: FieldSchema, resolve?: (name: string) => FormulaPlan | undefined): MetricPlan | undefined;
1437
+ /** Whether a group survives `minCount`. Calendar fill-ins (no rows) always do.
1438
+ * Otherwise the row count, or for an object `minCount` the group's measure
1439
+ * (null counts as 0), must reach `min`. A measure that is an error keeps its
1440
+ * group, so the error stays visible. */
1441
+ declare function metricMinCountKeeps(min: number, count: number, measure?: {
1442
+ value: unknown;
1443
+ error?: string | undefined;
1444
+ }): boolean;
1224
1445
  /** Executor support for population controls, from either capability handshake. */
1225
1446
  interface MetricPopulationSupport {
1226
1447
  filters?: boolean | undefined;
1227
1448
  minCount?: boolean | undefined;
1449
+ /** A `minCount` object: distinct values or a sum of a field. */
1450
+ minCountMeasures?: boolean | undefined;
1228
1451
  }
1229
1452
  /** A clause the executor cannot run exactly gets its own error; it is never
1230
1453
  * sent with `where`/`minCount` silently dropped. */
@@ -1308,6 +1531,11 @@ interface QueryCapabilitiesV3 {
1308
1531
  version: 3;
1309
1532
  groupedRows: boolean;
1310
1533
  calendarGrouping: boolean;
1534
+ /** Executes the cyclic `hourOfDay` and `dayOfWeek` date intervals. */
1535
+ calendarCycles?: boolean;
1536
+ /** Executes calendar grouping keys (`{ field, interval, timeZone }`) in a
1537
+ * grouping stage. Requests using them are refused otherwise. */
1538
+ calendarGroupKeys?: boolean;
1311
1539
  computedSourceFilters: boolean;
1312
1540
  regex: boolean;
1313
1541
  regexSourceFilters?: boolean;
@@ -1316,12 +1544,16 @@ interface QueryCapabilitiesV3 {
1316
1544
  metricFilters?: boolean;
1317
1545
  /** Executes AggregationClause.minCount and reports hiddenGroups. */
1318
1546
  metricMinCount?: boolean;
1547
+ /** Also executes an object minCount: distinct values or a sum per group. */
1548
+ metricMinCountMeasures?: boolean;
1319
1549
  maxRows: number;
1320
1550
  maxGroups: number;
1321
1551
  maxPopulation: number;
1322
1552
  profile: string;
1323
1553
  }
1324
1554
  interface QueryRequestV3 {
1555
+ /** The table's host-owned state when `hostQuery` is configured. */
1556
+ hostState?: HostQueryState;
1325
1557
  version: 3;
1326
1558
  profile: string;
1327
1559
  now: number;
@@ -1380,6 +1612,8 @@ interface DistinctValuesQuery {
1380
1612
  search: string;
1381
1613
  /** Max suggestions to return (default chosen by the adapter, ~50). */
1382
1614
  limit?: number;
1615
+ /** The table's host-owned state when `hostQuery` is configured. */
1616
+ hostState?: HostQueryState;
1383
1617
  }
1384
1618
  interface DistinctValuesResult {
1385
1619
  values: string[];
@@ -1438,6 +1672,10 @@ interface SavedQuery {
1438
1672
  interface StorageAdapter {
1439
1673
  /** Optional authenticated server store. Ordinary URL sync never calls it. */
1440
1674
  snapshots?: QuerySnapshotStore;
1675
+ /** True when last-used and named queries keep `QueryState.hostState`
1676
+ * exactly. A table with `hostQuery` refuses to save through an adapter
1677
+ * without it rather than store a table-only query. */
1678
+ storesHostState?: boolean;
1441
1679
  loadLast(key: string): Promise<QueryState | null>;
1442
1680
  saveLast(key: string, query: QueryState): Promise<void>;
1443
1681
  listSaved(key: string): Promise<SavedQuery[]>;
@@ -1506,13 +1744,27 @@ declare function boxSummary(values: number[], whiskers?: "minmax" | "tukey"): {
1506
1744
  declare function histogramEdges(values: number[], bins: number): number[];
1507
1745
  declare function histogramCounts(values: number[], edges: number[]): number[];
1508
1746
 
1509
- declare const METRIC_DATE_INTERVALS: readonly ["hour", "day", "week", "month", "year"];
1747
+ declare const METRIC_DATE_INTERVALS: readonly ["hour", "day", "week", "month", "year", "hourOfDay", "dayOfWeek"];
1748
+ declare const METRIC_CYCLE_INTERVALS: readonly ["hourOfDay", "dayOfWeek"];
1749
+ /** Whether an interval is cyclic: keyed by slot number, not by date. */
1750
+ declare function isMetricCycle(interval: string | undefined): interval is MetricCycleInterval;
1751
+ /** Every slot of a cyclic interval, in order: 0–23 or 1–7 (ISO, Monday 1). */
1752
+ declare function metricCycleSlots(interval: MetricCycleInterval): number[];
1753
+ /** The calendar interval one occurrence of a slot spans: its hour or day.
1754
+ * Calendar intervals are their own unit. */
1755
+ declare function metricCalendarUnit(interval: MetricDateGrouping["interval"]): Exclude<MetricDateGrouping["interval"], MetricCycleInterval>;
1756
+ /** The slot an instant occupies in `timeZone`: its local wall-clock hour
1757
+ * (0–23), or its local ISO weekday (1 = Monday … 7 = Sunday). */
1758
+ declare function metricCycleSlot(time: number, interval: MetricCycleInterval, timeZone?: string): number;
1510
1759
  /** Strict calendar input; timestamps require an explicit offset. */
1511
1760
  declare function metricDateTime(value: MetricValue, timeZone?: string): number;
1512
- declare function metricDateFloor(time: number, interval: MetricDateGrouping["interval"], timeZone?: string): number;
1513
- declare function metricDateNext(time: number, interval: MetricDateGrouping["interval"], timeZone?: string): number;
1761
+ declare function metricDateFloor(time: number, cycleOrInterval: MetricDateGrouping["interval"], timeZone?: string): number;
1762
+ declare function metricDateNext(time: number, cycleOrInterval: MetricDateGrouping["interval"], timeZone?: string): number;
1514
1763
  /** A date-only Through value includes the whole local day, even for hourly groups. */
1515
1764
  declare function metricCustomEndTime(value: string, timeZone?: string): number;
1765
+ /** An IANA timezone identifier this runtime knows, such as America/Denver or
1766
+ * UTC. Fixed offsets ("+02:00") are refused: they do not follow DST. */
1767
+ declare function isGroupingTimeZone(value: unknown): value is string;
1516
1768
  declare function validateDateGrouping(config: MetricDateGrouping): void;
1517
1769
  /** Only conjunctive bounds prove a domain; OR alternatives are not bounds. */
1518
1770
  declare function metricDateRange(config: MetricDateGrouping, query: QueryState, observed: readonly number[], now: number, canonical: (field: string) => string): [number, number] | undefined;
@@ -1522,8 +1774,15 @@ declare const MAX_METRIC_WINDOW_PERIODS = 1000;
1522
1774
  declare function hasMetricSeries(c: AggregationClause): boolean;
1523
1775
  /** Throws when a clause's window or share cannot be computed exactly. */
1524
1776
  declare function validateMetricSeries(c: AggregationClause, plan: FormulaPlan): void;
1777
+ /** The conjunctive bounds on a date-grouped clause's field, from the query's
1778
+ * and the metric's own filters: [lower, upper), infinite where absent. */
1779
+ declare function metricDateBounds(c: AggregationClause, query: QueryState, schema: FieldSchema, now: number): {
1780
+ lower: number;
1781
+ upper: number;
1782
+ };
1525
1783
  /** The whole intervals inside the conjunctive bounds on the date field (the
1526
- * query's and the metric's own), ending by `now`: [start, end). */
1784
+ * query's and the metric's own), ending by `now`: [start, end). A cyclic
1785
+ * interval's intervals are its hours or days. */
1527
1786
  declare function wholeIntervalSpan(c: AggregationClause, query: QueryState, schema: FieldSchema, now: number): {
1528
1787
  start?: number;
1529
1788
  end: number;
@@ -1552,9 +1811,13 @@ interface MetricSeriesPlan {
1552
1811
  * of every group. With a window, both are windowed first.
1553
1812
  * - **Whole intervals.** `partialIntervals: "exclude"` narrows the metric to
1554
1813
  * the intervals the query bounds and `now` leave whole.
1814
+ * - **Occurrences.** A cyclic slot with `dateGrouping.occurrence` runs the
1815
+ * metric per whole occurrence (one calendar hour or day), then summarises
1816
+ * each slot: the mean of its occurrence values, or a box over them.
1555
1817
  *
1556
- * `sort`, `groupLimit` and `minCount` (counting a window's rows) apply to the
1557
- * combined buckets. Windowed and share results have no Other remainder. */
1818
+ * `sort`, `groupLimit` and `minCount` (counting a window's rows, or summing a
1819
+ * field over the window) apply to the combined buckets. Windowed and share
1820
+ * results have no Other remainder. */
1558
1821
  declare function planMetricSeries(query: QueryState, schema: FieldSchema, options?: MetricSeriesOptions): MetricSeriesPlan | undefined;
1559
1822
 
1560
1823
  interface SavedPropertyView {
@@ -1596,6 +1859,12 @@ declare function sourceDependencies<Row>(query: QueryState, schema: FieldSchema<
1596
1859
  * - A date-grouped key becomes `>= start` and `< next`, using the clause's
1597
1860
  * interval and timezone. A windowed point starts at its window's first
1598
1861
  * interval, or has no lower bound for a running value.
1862
+ * - An hour-of-day or day-of-week slot selects its occurrences inside the
1863
+ * date field's bounds (whole ones with `occurrence` or whole intervals):
1864
+ * `>= first`, `< last end` and, for each gap between occurrences, an OR
1865
+ * group `< gap start` or `>= gap end`. Without a lower and an upper bound on
1866
+ * the date field, or when the filter would exceed the query's predicate
1867
+ * budget (about 48 occurrences), the result is null.
1599
1868
  * - A histogram bin (`bucket.bin`) adds `>= min` and `< max` (`<= max` for
1600
1869
  * the final bin) on the distribution input, which must be a field reference.
1601
1870
  * Box cohorts are their group keys.
@@ -1613,7 +1882,8 @@ declare function inspectBucketQuery(query: QueryState, bucket: AggregationBucket
1613
1882
  *
1614
1883
  * Starts from the grouping source, as leaving the grouping stage does, so its
1615
1884
  * WHERE, columns, order and item details are kept. Each key adds `=` (or
1616
- * `is_null` for a null key) and the offset resets. */
1885
+ * `is_null` for a null key), a calendar key `>= start` and `< end` of its
1886
+ * interval, and the offset resets. */
1617
1887
  declare function groupSourceQuery(query: QueryState, group: GroupedRow, schema: FieldSchema): QueryState | null;
1618
1888
 
1619
1889
  /** Host routes for query-kind links, keyed by `LinkSpec.to.target`. Each
@@ -1640,4 +1910,37 @@ declare function groupLinkQuery(query: QueryState, value: GroupLinkValue): Query
1640
1910
  * routes and unresolvable values return `href: null` with a `problem`. */
1641
1911
  declare function resolveGroupLink(query: QueryState, value: GroupLinkValue, targets?: LinkTargets): ResolvedGroupLink;
1642
1912
 
1643
- export { AGG_OPS_BY_TYPE, AGG_OPS_NEEDING_FIELD, type AggOp, type AggregateConfig, type AggregationBucket, type AggregationClause, type AggregationRequest, type AggregationResult, type AggregationResultEntry, type Align, type ApplyPatchOptions, type ApplyResult, type BackendField, COMPUTED_PREFIX, type CellDisplay, type CellRenderer, type ColumnPreview, type ComputedCellError, type ComputedColumn, type ComputedColumnDraft, type ComputedColumnStore, type ComputedExecution, type ComputedFieldCapabilities, type DerivedField, type DistinctValuesQuery, type DistinctValuesResult, EMPTY_QUERY, FORMULA_FUNCTIONS, type FetchRowsResult, type FetchRowsResultV2, type FieldDef, type FieldOrigin, type FieldRelationship, type FieldSchema, type FieldSource, type FieldStats, type FieldType, type FilterConfig, type FilterOp, type FilterValues, type ForeignKey, type FormulaDiagnostic, FormulaError, type FormulaFunction, type FormulaNode, type FormulaPlan, type FormulaResult, type FormulaType, type FormulaValue, GROUP_ID_FIELD, GROUP_LINK_RENDER, type GroupLinkValue, type GroupedRow, type GroupingDefinition, type GroupingModel, type GroupingState, type GroupingView, ITEM_DETAILS_COLUMN, type ItemDetailMode, type ItemDetailsState, type ItemPageOptions, type ItemPropertyMode, type JsonCellDisplay, type LinkDestination, type LinkSpec, type LinkTargets, MAX_AGGREGATIONS, MAX_GROUP_BY_FIELDS, MAX_METRIC_WINDOW_PERIODS, MAX_ORDER_BY_TERMS, MAX_PROPERTIES, MAX_QUERY_LIMIT, MAX_QUERY_OFFSET, MAX_QUERY_STATE_BYTES, MAX_QUERY_TOKEN_LENGTH, MAX_RELATIVE_TIME_MS, MAX_REPRESENTATIVE_SORTS, MAX_RESULT_GROUPS, MAX_SELECT_COLUMNS, MAX_SUMMARY_COLUMNS, MAX_WHERE_CLAUSES, METRIC_DATE_INTERVALS, METRIC_FUNCTIONS, type MetricAxisScale, type MetricBoxSummary, type MetricCapabilities, type MetricDateGrouping, type MetricDiagnostic, type MetricDisplay, type MetricDistribution, type MetricDistributionResult, type MetricEvaluationOptions, type MetricHistogramBin, type MetricKey, type MetricLayout, type MetricPlan, type MetricPopulationSupport, type MetricQuery, type MetricReductionOptions, type MetricScope, type MetricSeriesOptions, type MetricSeriesPlan, type MetricShare, type MetricSort, type MetricValue, type MetricValueFormat, type MetricWindow, NULLARY_OPS, OPS_BY_TYPE, OP_LABEL, type ObjectReference, type ObjectTypeDefinition, type OpChoice, type OpPair, type OrGroup, type OrderByClause, type PreviewGroup, type PropertyFieldConfig, type PropertyFormat, type PropertySelection, type PropertyViewState, type PropertyViewStorage, type QueryCapabilitiesV3, QueryDecodeError, type QueryEvaluationOptions, type QueryFacet, type QueryLink, type QueryLinkOptions, type QueryLinkService, type QueryPatch, type QueryPatchMatch, type QueryRequestV3, type QueryResultV3, type QuerySnapshot, type QuerySnapshotCache, QuerySnapshotHttpError, type QuerySnapshotHttpErrorCode, type QuerySnapshotStore, type QueryState, type RegexInspection, type RelationshipAdapter, type RepresentativeOrder, type RepresentativeRow, type ResolvedGroupLink, type ResolvedObjectReference, type RowComputedValues, type RowId, type SavedPropertyView, type SavedQuery, type SelectColumn, type SelectConfig, type ServerQuery, type ServerQueryV2, type SetFilterMetadata, type SetFilterMode, type SetFilterTarget, type SortConfig, type SourceDependencies, type StorageAdapter, type SummaryColumn, type SummaryOp, type Transport, type WhereClause, type WhereTerm, aggOpAllowedForType, aggOpNeedsField, aggOpsForField, applyAggregations, applyPatch, applyQuery, boxSummary, coerceValue, compareMetricValues, compileFormula, compileMetric, computedFieldName, createGroupingModel, createPropertyView, createQueryLinkService, createSetFilter, decodeQuery, decodeQueryStrict, discoverFieldRelationships, encodeQuery, evaluateMetricReductions, evaluateMetrics, exitGrouping, filterValues, formulaRuntime, groupLinkQuery, groupPreview, groupSourceQuery, hasMetricSeries, hasRegex, histogramCounts, histogramEdges, httpComputedColumnStore, httpQuerySnapshotStore, indexFields, inspectBucketQuery, isComputedCellError, isComputedField, isFilterable, isGroupLinkField, isGroupLinkValue, isGroupable, isMeasurable, isNegativePredicate, isOrGroup, isPushdownFilter, isSelectable, isSortable, itemPageFields, jsonPropertyViewStorage, loadSchema, localPropertyViewStorage, localQuerySnapshotCache, localStorageAdapter, mapSetFilterValues, matchPatch, matchesClause, memoryComputedColumnStore, memoryPropertyViewStorage, memoryQuerySnapshotCache, memoryStorageAdapter, metricAggregatePlans, metricComputationKey, metricCustomEndTime, metricDateFloor, metricDateNext, metricDateRange, metricDateTime, metricDependencies, metricExpression, metricPlans, metricPopulationError, negateClause, normalizePropertyFormat, normalizePropertyView, normalizeQueryState, objectReferenceKey, opAllowedForType, opPairsForField, opsForField, parseRelativeDuration, percentile, planMetricSeries, predicatesOf, prepareGrouping, queriesEqual, readFieldValue, readObjectReference, readSetFilter, reduceMetricValues, removePatch, renderItemPageTemplate, resolveFieldName, resolveGroupLink, selectMetricShownRows, selectedFields, setFilterModes, setFilterTarget, sortMetricBuckets, sourceDependencies, sourceExecutionSchema, stripSetFilter, toAggregationQuery, toMetricQuery, toQueryRequestV3, toServerQuery, toServerQueryV2, validateComputedColumn, validateDateGrouping, validateItemPageTemplate, validateMetric, validateMetricSeries, validateQueryResultV3, validateQuerySnapshot, wholeIntervalSpan, withGroupingKeys, withoutGrouping, withoutLinkSummaries };
1913
+ /** Semantic identities only. A missing path never resolves to its parent. */
1914
+ interface AttentionTarget {
1915
+ dataset: string;
1916
+ rowId?: RowId;
1917
+ field?: string;
1918
+ path?: string;
1919
+ }
1920
+ type AttentionResult = {
1921
+ status: "revealed" | "unavailable" | "cancelled";
1922
+ target: AttentionTarget;
1923
+ };
1924
+ interface AttentionProvider {
1925
+ /** Await data/layout readiness; observe cancellation before changing presentation. */
1926
+ ready?: (signal: AbortSignal) => Promise<void>;
1927
+ /** Load/open the exact record or property, then return whether it exists. */
1928
+ materialize?: (target: AttentionTarget, signal: AbortSignal) => boolean | Promise<boolean>;
1929
+ /** Scroll/highlight the materialized target. Must never move keyboard focus. */
1930
+ reveal: (target: AttentionTarget, signal: AbortSignal) => boolean | Promise<boolean>;
1931
+ }
1932
+ interface AttentionRegistry {
1933
+ cancel(): void;
1934
+ register(target: AttentionTarget, provider: AttentionProvider): () => void;
1935
+ /** New navigation cancels the previous request; registrations alone never scroll. */
1936
+ resolve(target: AttentionTarget, options?: {
1937
+ signal?: AbortSignal;
1938
+ }): Promise<AttentionResult>;
1939
+ /** For materializers awaiting a React commit or a virtualized row. */
1940
+ whenRegistered(target: AttentionTarget, signal: AbortSignal, except?: AttentionProvider): Promise<AttentionProvider>;
1941
+ }
1942
+ declare function attentionTargetKey(target: AttentionTarget): string;
1943
+ /** Framework-independent registration and cancellation; adapters own materialization. */
1944
+ declare function createAttentionRegistry(): AttentionRegistry;
1945
+
1946
+ export { AGG_OPS_BY_TYPE, AGG_OPS_NEEDING_FIELD, type AggOp, type AggregateConfig, type AggregationBucket, type AggregationClause, type AggregationRequest, type AggregationResult, type AggregationResultEntry, type Align, type ApplyPatchOptions, type ApplyResult, type AttentionProvider, type AttentionRegistry, type AttentionResult, type AttentionTarget, type BackendField, COMPUTED_PREFIX, type CalendarGroupKey, type CellDisplay, type CellRenderer, type ColumnPreview, type ComputedCellError, type ComputedColumn, type ComputedColumnDraft, type ComputedColumnStore, type ComputedExecution, type ComputedFieldCapabilities, type DerivedField, type DistinctValuesQuery, type DistinctValuesResult, EMPTY_QUERY, FORMULA_FUNCTIONS, type FetchRowsResult, type FetchRowsResultV2, type FieldDef, type FieldOrigin, type FieldRelationship, type FieldSchema, type FieldSource, type FieldStats, type FieldType, type FilterConfig, type FilterOp, type FilterValues, type ForeignKey, type FormulaDiagnostic, FormulaError, type FormulaFunction, type FormulaNode, type FormulaPlan, type FormulaResult, type FormulaType, type FormulaValue, GROUP_ID_FIELD, GROUP_KEY_INTERVALS, GROUP_LINK_RENDER, type GroupKey, type GroupLinkValue, type GroupedRow, type GroupingDefinition, type GroupingModel, type GroupingState, type GroupingView, type HostQueryState, ITEM_DETAILS_COLUMN, type ItemDetailMode, type ItemDetailsState, type ItemPageOptions, type ItemPropertyMode, type JsonCellDisplay, type JsonInspectionScope, type JsonInspectionState, type JsonMatchIdentity, type LinkDestination, type LinkSpec, type LinkTargets, MAX_AGGREGATIONS, MAX_GROUP_BY_FIELDS, MAX_HOST_QUERY_PARAMS, MAX_HOST_QUERY_STATE_BYTES, MAX_HOST_QUERY_VALUES, MAX_HOST_QUERY_VALUE_LENGTH, MAX_JSON_INSPECTIONS, MAX_JSON_PATHS, MAX_METRIC_WINDOW_PERIODS, MAX_ORDER_BY_TERMS, MAX_PROPERTIES, MAX_QUERY_LIMIT, MAX_QUERY_OFFSET, MAX_QUERY_STATE_BYTES, MAX_QUERY_TOKEN_LENGTH, MAX_RELATIVE_TIME_MS, MAX_REPRESENTATIVE_SORTS, MAX_RESULT_GROUPS, MAX_SELECT_COLUMNS, MAX_SUMMARY_COLUMNS, MAX_WHERE_CLAUSES, METRIC_CYCLE_INTERVALS, METRIC_DATE_INTERVALS, METRIC_FUNCTIONS, type MetricAxisScale, type MetricBoxSummary, type MetricCalendarInterval, type MetricCapabilities, type MetricCycleInterval, type MetricDateGrouping, type MetricDateOccurrence, type MetricDiagnostic, type MetricDisplay, type MetricDistribution, type MetricDistributionResult, type MetricEvaluationOptions, type MetricHistogramBin, type MetricKey, type MetricLayout, type MetricMinCountOf, type MetricPlan, type MetricPopulationSupport, type MetricQuery, type MetricReductionOptions, type MetricScope, type MetricSeriesOptions, type MetricSeriesPlan, type MetricShare, type MetricSort, type MetricValue, type MetricValueFormat, type MetricWindow, NULLARY_OPS, OPS_BY_TYPE, OP_LABEL, type ObjectReference, type ObjectTypeDefinition, type OpChoice, type OpPair, type OrGroup, type OrOfAndsGroup, type OrderByClause, type PreviewGroup, type PropertyFieldConfig, type PropertyFormat, type PropertySelection, type PropertyViewState, type PropertyViewStorage, type QueryCapabilitiesV3, QueryDecodeError, type QueryEvaluationOptions, type QueryFacet, type QueryLink, type QueryLinkOptions, type QueryLinkService, type QueryPatch, type QueryPatchMatch, type QueryRequestV3, type QueryResultV3, type QuerySnapshot, type QuerySnapshotCache, QuerySnapshotHttpError, type QuerySnapshotHttpErrorCode, type QuerySnapshotStore, type QueryState, type RegexInspection, type RelationshipAdapter, type RepresentativeOrder, type RepresentativeRow, type ResolvedGroupLink, type ResolvedObjectReference, type RowComputedValues, type RowId, type SavedPropertyView, type SavedQuery, type ScopedJsonInspectionState, type SelectColumn, type SelectConfig, type ServerQuery, type ServerQueryV2, type SetFilterMetadata, type SetFilterMode, type SetFilterTarget, type SortConfig, type SourceDependencies, type StorageAdapter, type SummaryColumn, type SummaryOp, type Transport, type WhereBranch, type WhereClause, type WhereConjunction, type WhereTerm, aggOpAllowedForType, aggOpNeedsField, aggOpsForField, applyAggregations, applyPatch, applyQuery, attentionTargetKey, boxSummary, branchesOf, calendarGroupKey, coerceValue, compareMetricValues, compileFormula, compileMetric, computedFieldName, createAttentionRegistry, createGroupingModel, createPropertyView, createQueryLinkService, createSetFilter, decodeQuery, decodeQueryStrict, discoverFieldRelationships, encodeQuery, evaluateMetricReductions, evaluateMetrics, exitGrouping, filterValues, formulaRuntime, groupKeyField, groupKeyFields, groupKeyTerms, groupLinkQuery, groupPreview, groupSourceQuery, hasMetricSeries, hasRegex, histogramCounts, histogramEdges, httpComputedColumnStore, httpQuerySnapshotStore, indexFields, inspectBucketQuery, isCalendarGroupKey, isComputedCellError, isComputedField, isFilterable, isGroupLinkField, isGroupLinkValue, isGroupable, isGroupingTimeZone, isJsonBucketId, isJsonPath, isMeasurable, isMetricCycle, isNegativePredicate, isOrGroup, isOrOfAndsGroup, isPropertyFieldLoaded, isPushdownFilter, isSelectable, isSortable, isWhereConjunction, isWhereGroup, itemPageFields, jsonInspectionScopeKey, jsonPropertyViewStorage, loadSchema, localPropertyViewStorage, localQuerySnapshotCache, localStorageAdapter, mapSetFilterValues, matchPatch, matchesClause, memoryComputedColumnStore, memoryPropertyViewStorage, memoryQuerySnapshotCache, memoryStorageAdapter, metricAggregatePlans, metricCalendarUnit, metricComputationKey, metricCustomEndTime, metricCycleSlot, metricCycleSlots, metricDateBounds, metricDateFloor, metricDateNext, metricDateRange, metricDateTime, metricDependencies, metricExpression, metricMinCount, metricMinCountKeeps, metricMinCountMeasure, metricMinCountPlan, metricMinCountText, metricPlans, metricPopulationError, negateClause, normalizePropertyFormat, normalizePropertyView, normalizeQueryState, objectReferenceKey, occurrenceDistribution, opAllowedForType, opPairsForField, opsForField, parseHostQueryState, parseJsonInspectionState, parseJsonInspections, parseRelativeDuration, percentile, planMetricSeries, predicatesOf, prepareGrouping, queriesEqual, readFieldValue, readObjectReference, readSetFilter, reduceMetricValues, removePatch, renderItemPageTemplate, resolveFieldName, resolveGroupLink, selectMetricShownRows, selectedFields, setFilterModes, setFilterTarget, sortMetricBuckets, sourceDependencies, sourceExecutionSchema, stripSetFilter, toAggregationQuery, toMetricQuery, toQueryRequestV3, toServerQuery, toServerQueryV2, validateComputedColumn, validateDateGrouping, validateItemPageTemplate, validateMetric, validateMetricSeries, validateQueryResultV3, validateQuerySnapshot, wholeIntervalSpan, withGroupingKeys, withoutGrouping, withoutLinkSummaries };