react-semaphor 0.1.559 → 0.1.561

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 (168) hide show
  1. package/dist/analytics-protocol/index.js +389 -378
  2. package/dist/assistant-context/index.js +1 -1
  3. package/dist/assistant-protocol/index.js +5 -5
  4. package/dist/brand-studio/index.js +9 -9
  5. package/dist/briefings/index.js +5 -5
  6. package/dist/chunks/analytics-base-schemas-CB3oFAXk.js +658 -0
  7. package/dist/chunks/{assistant-chat-B_4bVE6I.js → assistant-chat-DiVHY3Hw.js} +209 -211
  8. package/dist/chunks/bookmark-impact-CR09dpkn.js +75 -0
  9. package/dist/chunks/bookmark-state-BusLpkb7.js +743 -0
  10. package/dist/chunks/{braces-Rdxa3H-s.js → braces-u8VorWJc.js} +1 -1
  11. package/dist/chunks/{comparison-window-caption-CKzQ5LcF.js → comparison-window-caption-DDsIWJYT.js} +201 -201
  12. package/dist/chunks/{context-DVy4HOU0.js → context-TUjw9eqr.js} +1 -1
  13. package/dist/chunks/{custom-visual-inputs-zVa9wX_o.js → custom-visual-inputs-DfolidZ9.js} +1 -1
  14. package/dist/chunks/{dashboard-BziwOVpZ.js → dashboard-BRdZBPqr.js} +1 -1
  15. package/dist/chunks/{dashboard-briefing-launcher-CbeNR-YI.js → dashboard-briefing-launcher-CgvTLndW.js} +1163 -1178
  16. package/dist/chunks/{dashboard-controls-RD6UJs1r.js → dashboard-controls-B4vfSzTF.js} +877 -941
  17. package/dist/chunks/{dashboard-json-DGpv17vL.js → dashboard-json-Y3MF59g7.js} +5 -5
  18. package/dist/chunks/document-dashboard-inputs-CvBbFTUA.js +1718 -0
  19. package/dist/chunks/{edit-dashboard-visual-AQ2pQkFp.js → edit-dashboard-visual-DwjZcxj-.js} +9080 -9354
  20. package/dist/chunks/filter-reach-copy-bijwf_-b.js +3596 -0
  21. package/dist/chunks/{filter-value-text-B4l-xqJT.js → filter-value-text-DFnhwuEW.js} +3 -3
  22. package/dist/chunks/global-date-filter-utils-BXgCpvQM.js +15142 -0
  23. package/dist/chunks/{index-B1Xr7W24.js → index-ClwbY3BL.js} +648 -674
  24. package/dist/chunks/{layout-grid-Bbz3zKif.js → layout-grid-CtvCBfOm.js} +1 -1
  25. package/dist/chunks/{list-filter-3sbH0Uy1.js → list-filter-BklYgciR.js} +1 -1
  26. package/dist/chunks/{matrix-analytical-definition-CEe3PGEo.js → matrix-analytical-definition-pU51-JmY.js} +4 -4
  27. package/dist/chunks/{matrix-card-BRNGb1C4.js → matrix-card-CUorIB7Q.js} +3 -3
  28. package/dist/chunks/{matrix-member-presentation-CEegvTqg.js → matrix-member-presentation-Df5UgCGN.js} +1 -1
  29. package/dist/chunks/{matrix-operation-contract-COxrfQTS.js → matrix-operation-contract-BSiGEXVC.js} +221 -214
  30. package/dist/chunks/{metric-comparison-DQx-uX__.js → metric-comparison-95aC0uEO.js} +6 -6
  31. package/dist/chunks/{model-change-CJEj3ZD6.js → model-change-B5wQhg5G.js} +1 -1
  32. package/dist/chunks/{palette-DMJtp3Vn.js → palette-DTnMhipt.js} +1 -1
  33. package/dist/chunks/pivot-result-contract-expectations-Bo-86vwS.js +56 -0
  34. package/dist/chunks/{pivot-result-identity-CAj8SiRL.js → pivot-result-identity-olvXJoB9.js} +1 -1
  35. package/dist/chunks/{report-preferences-dialog-0sc8B1lh.js → report-preferences-dialog-C2YUIwKG.js} +55 -55
  36. package/dist/chunks/{report-runtime-context-bYoExeWr.js → report-runtime-context-DoIUr3MP.js} +2 -2
  37. package/dist/chunks/resolve-dashboard-input-context-q_iiNXE1.js +6503 -0
  38. package/dist/chunks/{save-DSb1jTtG.js → save-DH4RyrnG.js} +1 -1
  39. package/dist/chunks/{saved-dashboard-context-BQWM3ldX.js → saved-dashboard-context-8jqfI7hI.js} +59 -59
  40. package/dist/chunks/{selection-reducer-DSzMWb4x.js → selection-reducer-CV7K4FI6.js} +1 -1
  41. package/dist/chunks/{semaphor-ready-indicator-Bz14Oma5.js → semaphor-ready-indicator-E2XWyibu.js} +40105 -41658
  42. package/dist/chunks/{shelf-drop-preview-context-DBHAkgch.js → shelf-drop-preview-context-C29EUzDp.js} +570 -570
  43. package/dist/chunks/{source-entity-resolution-BOrmNCEM.js → source-entity-resolution-BXI3nQ5Z.js} +1 -1
  44. package/dist/chunks/{switch-Dq8XPFpT.js → switch-balDSHc7.js} +3 -3
  45. package/dist/chunks/{table-export-sheet-C_RvEUyO.js → table-export-sheet-CK8tvh4d.js} +1 -1
  46. package/dist/chunks/temporal-input-presentation-B77JsAzU.js +5002 -0
  47. package/dist/chunks/{token-types-LCYMJ3pa.js → token-types-DhYH5YKb.js} +1 -1
  48. package/dist/chunks/{upload-Dr_WAxHQ.js → upload-Ufj8vjyn.js} +1 -1
  49. package/dist/chunks/{use-create-flow-overlay-state-BK3YFkfc.js → use-create-flow-overlay-state-9WsnzEO5.js} +6 -6
  50. package/dist/chunks/{validators-C87JPd-_.js → validators-BtaCFIEB.js} +1206 -1579
  51. package/dist/chunks/{zoned-wall-clock-E35Frf9v.js → zoned-wall-clock-CGLVI40Q.js} +1 -1
  52. package/dist/dashboard/index.js +2 -2
  53. package/dist/dashboard-authoring/index.js +2713 -1459
  54. package/dist/data-app-sdk/index.js +20 -20
  55. package/dist/data-app-sdk-adapters/index.js +3 -3
  56. package/dist/data-app-sdk-validation/index.js +10 -10
  57. package/dist/format-utils/index.js +262 -256
  58. package/dist/index.js +214 -215
  59. package/dist/report-runtime-context/index.js +2 -2
  60. package/dist/style.css +1 -1
  61. package/dist/surfboard/index.js +2 -2
  62. package/dist/types/components/dashboard/summary-number-formatter.d.ts +6 -0
  63. package/dist/types/components/editor/editor-aside/utils.d.ts +1 -1
  64. package/dist/types/components/visual/data-table/types/data-table.d.ts +5 -20
  65. package/dist/types/index.js +50 -51
  66. package/dist/types/lib/formatters/canonical-format-adapter.d.ts +2 -29
  67. package/dist/types/lib/formatters/kpi-number-formatter.d.ts +41 -0
  68. package/dist/types/lib/formatters/raw-temporal-presentation.d.ts +0 -2
  69. package/dist/types/lib/formatters/table-column-settings.d.ts +47 -0
  70. package/dist/types/lib/matrix-table/matrix-card-adapter.d.ts +10 -188
  71. package/dist/types/lib/matrix-table/matrix-delivery-policy.d.ts +1 -1
  72. package/dist/types/lib/matrix-table/matrix-delivery.d.ts +16 -372
  73. package/dist/types/lib/stores/dashboard-store.d.ts +0 -1
  74. package/dist/types/lib/stores/editor-store.d.ts +48 -10
  75. package/dist/types/lib/stores/table-actions.d.ts +9 -5
  76. package/dist/types/lib/table-formatting/index.d.ts +0 -2
  77. package/dist/types/lib/table-formatting/table-conditional-formatting-range-source.d.ts +3 -2
  78. package/dist/types/lib/table-formatting/table-conditional-formatting-range.d.ts +3 -2
  79. package/dist/types/lib/table-formatting/table-formatting-normalize.d.ts +1 -2
  80. package/dist/types/lib/table-formatting/table-formatting-render-model.d.ts +9 -0
  81. package/dist/types/lib/table-formatting/table-formatting-types.d.ts +5 -95
  82. package/dist/types/lib/table-formatting/table-presentation-fields.d.ts +35 -0
  83. package/dist/types/lib/types/common-types.d.ts +40 -47
  84. package/dist/types/lib/types/explorer-types.d.ts +11 -43
  85. package/dist/types/lib/utils/card-config-utils.d.ts +8 -0
  86. package/dist/types/lib/utils/card-definition.d.ts +9 -187
  87. package/dist/types/shared/analytics-protocol/analytics-base-schemas.d.ts +169 -513
  88. package/dist/types/shared/analytics-protocol/contracts.d.ts +32 -9
  89. package/dist/types/shared/analytics-protocol/execution-input-schemas.d.ts +108 -980
  90. package/dist/types/shared/analytics-protocol/field-validation.d.ts +1 -0
  91. package/dist/types/shared/analytics-protocol/matrix-definition-contract.d.ts +281 -4624
  92. package/dist/types/shared/analytics-protocol/matrix-operation-contract.d.ts +20 -20
  93. package/dist/types/shared/analytics-protocol/matrix-operation-request.d.ts +18 -18
  94. package/dist/types/shared/analytics-protocol/matrix-path-contract.d.ts +40 -40
  95. package/dist/types/shared/analytics-protocol/matrix-window-contract.d.ts +3 -203
  96. package/dist/types/shared/analytics-protocol/measure-aggregation-profile.d.ts +12 -0
  97. package/dist/types/shared/analytics-protocol/scalar-value.d.ts +8 -8
  98. package/dist/types/shared/assistant-context/saved-dashboard-context.d.ts +8 -0
  99. package/dist/types/shared/assistant-protocol/context.d.ts +69 -69
  100. package/dist/types/shared/dashboard-authoring/canonical-result-keys.d.ts +13 -0
  101. package/dist/types/shared/dashboard-authoring/card-export-request.d.ts +4 -1
  102. package/dist/types/shared/dashboard-authoring/card-formats/sql-date-pattern.d.ts +10 -0
  103. package/dist/types/shared/dashboard-authoring/card-formats/upgrade-card-formats.d.ts +57 -0
  104. package/dist/types/shared/dashboard-authoring/card-settings/apply-card-settings.d.ts +11 -0
  105. package/dist/types/shared/dashboard-authoring/card-settings/card-display-write.d.ts +52 -0
  106. package/dist/types/shared/dashboard-authoring/card-settings/card-kinds.d.ts +14 -0
  107. package/dist/types/shared/dashboard-authoring/card-settings/carry-column-settings.d.ts +3 -0
  108. package/dist/types/shared/dashboard-authoring/card-settings/column-format-write.d.ts +8 -0
  109. package/dist/types/shared/dashboard-authoring/card-settings/column-names.d.ts +51 -0
  110. package/dist/types/shared/dashboard-authoring/card-settings/column-sources.d.ts +14 -0
  111. package/dist/types/shared/dashboard-authoring/card-settings/confirm-class.d.ts +9 -0
  112. package/dist/types/shared/dashboard-authoring/card-settings/highlight-inputs.d.ts +19 -0
  113. package/dist/types/shared/dashboard-authoring/card-settings/index.d.ts +15 -0
  114. package/dist/types/shared/dashboard-authoring/card-settings/inputs.d.ts +102 -0
  115. package/dist/types/shared/dashboard-authoring/card-settings/read-card-settings.d.ts +10 -0
  116. package/dist/types/shared/dashboard-authoring/card-settings/resolve-card-highlights.d.ts +14 -0
  117. package/dist/types/shared/dashboard-authoring/card-settings/resolve-card-settings.d.ts +59 -0
  118. package/dist/types/shared/dashboard-authoring/card-settings/resolved.d.ts +40 -0
  119. package/dist/types/shared/dashboard-authoring/card-settings/views.d.ts +28 -0
  120. package/dist/types/shared/dashboard-authoring/changes/card-query-part.d.ts +6 -0
  121. package/dist/types/shared/dashboard-authoring/changes/card-types.d.ts +32 -0
  122. package/dist/types/shared/dashboard-authoring/changes/dashboard-change.d.ts +555 -38
  123. package/dist/types/shared/dashboard-authoring/changes/diagnostics.d.ts +27 -8
  124. package/dist/types/shared/dashboard-authoring/changes/resolve-dashboard-changes.d.ts +25 -1
  125. package/dist/types/shared/dashboard-authoring/conditional-formatting/editable.d.ts +14 -0
  126. package/dist/types/shared/dashboard-authoring/conditional-formatting/evaluate.d.ts +16 -0
  127. package/dist/types/shared/dashboard-authoring/conditional-formatting/index.d.ts +9 -0
  128. package/dist/types/shared/dashboard-authoring/conditional-formatting/kpi.d.ts +7 -0
  129. package/dist/types/shared/dashboard-authoring/conditional-formatting/resolve-card-column-ref.d.ts +17 -0
  130. package/dist/types/shared/dashboard-authoring/conditional-formatting/retain.d.ts +14 -0
  131. package/dist/types/shared/dashboard-authoring/conditional-formatting/schema.d.ts +4499 -0
  132. package/dist/types/shared/dashboard-authoring/conditional-formatting/store.d.ts +12 -0
  133. package/dist/types/shared/dashboard-authoring/conditional-formatting/types.d.ts +151 -0
  134. package/dist/types/shared/dashboard-authoring/conditional-formatting/upgrade.d.ts +35 -0
  135. package/dist/types/shared/dashboard-authoring/control-execution-contract.d.ts +62 -62
  136. package/dist/types/shared/dashboard-authoring/index.d.ts +8 -0
  137. package/dist/types/shared/dashboard-authoring/kpi-figure.d.ts +123 -0
  138. package/dist/types/shared/dashboard-authoring/matrix-authoring.d.ts +4 -5
  139. package/dist/types/shared/dashboard-authoring/matrix-delivery.d.ts +24 -736
  140. package/dist/types/shared/dashboard-authoring/operations/operation-types.d.ts +21 -1
  141. package/dist/types/shared/dashboard-authoring/outline/outline-dashboard.d.ts +10 -4
  142. package/dist/types/shared/dashboard-authoring/retired-presentation-fields.d.ts +31 -0
  143. package/dist/types/shared/dashboard-authoring/upgrade-card-presentation.d.ts +14 -0
  144. package/dist/types/shared/dashboard-viewer/bookmark-impact.d.ts +33 -0
  145. package/dist/types/shared/format-utils/formatters/matrix-formatter.d.ts +13 -2
  146. package/dist/types/shared/format-utils/formatters/number-formatter.d.ts +16 -0
  147. package/dist/types/shared/format-utils/index.d.ts +2 -0
  148. package/dist/types/shared/format-utils/matrix-export-presentation.d.ts +10 -366
  149. package/dist/types/shared/format-utils/raw-temporal.d.ts +31 -1
  150. package/dist/types/shared/format-utils/resolve-column-format.d.ts +43 -0
  151. package/dist/types/shared/format-utils/retired-format-adapters.d.ts +68 -0
  152. package/dist/types/shared/format-utils/semantic-format.d.ts +5 -1
  153. package/dist/types/shared/format-utils/stored-value-format.d.ts +16 -0
  154. package/dist/types/shared/format-utils/types/format-types.d.ts +10 -12
  155. package/package.json +2 -2
  156. package/dist/chunks/analytics-base-schemas-BUFUoO6G.js +0 -472
  157. package/dist/chunks/bookmark-state-ssqrs5oP.js +0 -111
  158. package/dist/chunks/document-dashboard-inputs-ChVkcBuu.js +0 -3010
  159. package/dist/chunks/editor-draft-sync-BN5qYHPF.js +0 -15
  160. package/dist/chunks/filter-reach-copy-B5Y7FHzg.js +0 -3411
  161. package/dist/chunks/global-date-filter-utils-DBzEOX9M.js +0 -12222
  162. package/dist/chunks/pivot-result-contract-expectations-DOYhqeZb.js +0 -1926
  163. package/dist/chunks/raw-temporal-presentation-BmT7z6NH.js +0 -584
  164. package/dist/chunks/resolve-dashboard-input-context-B_C_VAJH.js +0 -5520
  165. package/dist/chunks/table-settings-DXj_zXwS.js +0 -637
  166. package/dist/chunks/temporal-input-presentation-AhLSkGPf.js +0 -2939
  167. package/dist/types/lib/table-formatting/table-conditional-formatting-evaluator.d.ts +0 -9
  168. package/dist/types/lib/table-formatting/table-formatting-validation.d.ts +0 -12
@@ -1,4 +1,5 @@
1
1
  import { EmbeddedFilterDashboardInput, TDashboard, TFrame } from '../../../lib/types/common-types.js';
2
+ import { ResolvedCardSettings } from '../card-settings/resolved.js';
2
3
  import { FilterSettingsChange, FilterValueEffect } from '../../../lib/dashboard-inputs/filter-settings.js';
3
4
  import { DashboardFilterBoundCardApplication } from '../dashboard-filter-mapping-types.js';
4
5
  import { Field } from '../../../lib/types/explorer-types.js';
@@ -40,6 +41,11 @@ export type CardUpdate =
40
41
  | {
41
42
  kind: 'relabel';
42
43
  labels: StatedLabel[];
44
+ }
45
+ /** How the card's columns read and show, resolved by the card settings owner (card appearance CA-D10, SPEC 3.6). */
46
+ | {
47
+ kind: 'settings';
48
+ settings: ResolvedCardSettings;
43
49
  };
44
50
  /** Everything the editor's "Done", Save & Apply and Apply Local commit persists, as one operation (DE-D13). */
45
51
  export type FrameCommit = {
@@ -105,6 +111,12 @@ export type DashboardOperation = ({
105
111
  op: 'filter.exclude';
106
112
  filterId: string;
107
113
  cardId: string;
114
+ }
115
+ /** The dashboard's own title and description (card appearance); a null description removes it. */
116
+ | {
117
+ op: 'dashboard.update';
118
+ title?: string;
119
+ description?: string | null;
108
120
  }) & {
109
121
  /** Set by the resolver: the public change this operation came from. Descriptions group by it. */
110
122
  changeIndex?: number;
@@ -168,7 +180,9 @@ export type OperationFailureCode = 'sheet_not_found'
168
180
  /** A conversion asked for more ids than the operation carries. */
169
181
  | 'ids_exhausted'
170
182
  /** A retype across the Matrix boundary without a catalog. */
171
- | 'catalog_loading';
183
+ | 'catalog_loading'
184
+ /** A card settings operation names a column the card no longer has (card appearance SPEC 4.3): a defect, since apply runs after the staleness check. */
185
+ | 'setting_target_missing';
172
186
  export type DashboardOperationResult = {
173
187
  ok: true;
174
188
  dashboard: TDashboard;
@@ -176,6 +190,12 @@ export type DashboardOperationResult = {
176
190
  /** One plain sentence per public change (or per operation without a changeIndex). */
177
191
  descriptions: OperationDescription[];
178
192
  runtimeEffects: DashboardRuntimeEffect[];
193
+ /**
194
+ * An edit made a card that showed a library visual the dashboard's own:
195
+ * never applied without a yes (card appearance P2-36). From each
196
+ * operation's outcome; its sentence says so too, but is never read for it.
197
+ */
198
+ detaches: boolean;
179
199
  } | {
180
200
  ok: false;
181
201
  failedAt: {
@@ -1,6 +1,8 @@
1
1
  import { DashboardRelationshipReachResolver } from '../../../lib/query-context/dashboard-filter-mapping-resolution.js';
2
2
  import { TDashboard } from '../../../lib/types/common-types.js';
3
3
  import { FrameWidth } from '../../layouts/index.js';
4
+ import { CardTypeProperties } from '../changes/card-types.js';
5
+ import { CardSettingsView } from '../card-settings/views.js';
4
6
  import { NotEditableReason, OutlineCardSource } from '../changes/read-card-query.js';
5
7
  import { CardQuery, MatrixColumns } from '../changes/dashboard-change.js';
6
8
  import { OutlineFilter } from './outline-filters.js';
@@ -34,10 +36,10 @@ export type OutlineViewer = {
34
36
  */
35
37
  relationshipReach?: DashboardRelationshipReachResolver;
36
38
  };
37
- export type OutlineCard = {
39
+ export type OutlineCard = ({
38
40
  cardId: string;
39
41
  title: string;
40
- /** The public type name (DE-D43). */
42
+ /** The public type name (DE-D43): one of the eight, a variant as properties beside it (card appearance CA-D6). */
41
43
  type: string;
42
44
  source: OutlineCardSource;
43
45
  /** Shows a library visual; changing it makes it local (DE-D50). */
@@ -46,7 +48,9 @@ export type OutlineCard = {
46
48
  /** Absent only when the outline is truncated. */
47
49
  query?: CardQuery;
48
50
  matrix?: MatrixColumns;
49
- } | {
51
+ } & CardTypeProperties &
52
+ /** How the card reads and shows, in the shape a change takes; absent when the outline is truncated (card appearance SPEC 3.2). */
53
+ Partial<CardSettingsView>) | ({
50
54
  cardId: string;
51
55
  title: string;
52
56
  type: string;
@@ -58,7 +62,7 @@ export type OutlineCard = {
58
62
  message: string;
59
63
  detail?: string;
60
64
  };
61
- };
65
+ } & CardTypeProperties);
62
66
  export type OutlineSheet = {
63
67
  sheetId: string;
64
68
  title: string;
@@ -83,6 +87,8 @@ export type OutlineLayoutRow = {
83
87
  export type DashboardOutline = {
84
88
  dashboardId: string;
85
89
  title: string;
90
+ /** The dashboard's description, when it has one: what `dashboard.update` sets. */
91
+ description?: string;
86
92
  updatedAt: string;
87
93
  access: {
88
94
  canEdit: boolean;
@@ -0,0 +1,31 @@
1
+ import { TCard } from '../../lib/types/common-types.js';
2
+ export type RetiredPresentationField = {
3
+ /** Where the field is, e.g. `sheets[id=s1].frames[id=f1].cards[id=c1].preferences.formatNumber`. */
4
+ path: string;
5
+ /** The retired field's name, e.g. `formatNumber`. */
6
+ field: string;
7
+ /** What to write instead. */
8
+ replacement: string;
9
+ };
10
+ /**
11
+ * Whether a stored record holds a key, whatever its value (`null`, `{}` and
12
+ * `[]` included): what the save check refuses, and so what the upgrades must
13
+ * clear (column formats ledger P5-18).
14
+ */
15
+ export declare function hasStoredKey(record: unknown, key: string): boolean;
16
+ /** Every retired presentation field on one card; `at` is the card's path. */
17
+ export declare function findRetiredCardPresentationFields(card: TCard, at: string): RetiredPresentationField[];
18
+ /** Every retired presentation field in a dashboard template or a library visual frame. */
19
+ export declare function findRetiredPresentationFields(template: unknown): RetiredPresentationField[];
20
+ export type PresentationStoreIssue = {
21
+ code: 'retired_presentation_field' | 'invalid_conditional_formatting';
22
+ path: string;
23
+ message: string;
24
+ };
25
+ /**
26
+ * What the save check refuses in a dashboard template or a library visual
27
+ * frame (column formats CF-D8, conditional formatting store CR-D9): every
28
+ * retired presentation field, and a rule store whose shape is wrong or whose
29
+ * rules name a column the card doesn't have. Empty when the template saves.
30
+ */
31
+ export declare function checkPresentationStores(template: unknown): PresentationStoreIssue[];
@@ -0,0 +1,14 @@
1
+ import { TCard } from '../../lib/types/common-types.js';
2
+ import { UpgradeCardFormatsOptions, UpgradeCardFormatsResult } from './card-formats/upgrade-card-formats.js';
3
+ import { UpgradeConditionalFormattingResult } from './conditional-formatting/upgrade.js';
4
+ export type UpgradeCardPresentationOptions = UpgradeCardFormatsOptions & {
5
+ /** One part only; omitted, both. */
6
+ only?: 'formats' | 'rules';
7
+ };
8
+ export type UpgradeCardPresentationResult = {
9
+ /** The input card itself when nothing changed. */
10
+ card: TCard;
11
+ formats?: UpgradeCardFormatsResult;
12
+ rules?: UpgradeConditionalFormattingResult;
13
+ };
14
+ export declare function upgradeCardPresentation(card: TCard, options?: UpgradeCardPresentationOptions): UpgradeCardPresentationResult;
@@ -0,0 +1,33 @@
1
+ import { TDashboard } from '../../lib/types/common-types.js';
2
+ import { BookmarkUsage } from './viewer-contract.js';
3
+ export type BookmarkImpactItem = {
4
+ readonly target: 'input' | 'sheet' | 'table' | 'column';
5
+ readonly id: string;
6
+ /** For a column: its table. */
7
+ readonly cardId?: string;
8
+ /** From the saved dashboard, where the removed part still has its name. */
9
+ readonly label: string;
10
+ readonly bookmarks: number;
11
+ /** Viewers with remembered settings that name it (tables and columns). */
12
+ readonly remembered: number;
13
+ };
14
+ /**
15
+ * What an edit removes that saved bookmarks or remembered settings use: parts
16
+ * of the saved dashboard that the draft no longer has, with how many use each.
17
+ * Removed parts don't break anything (opening reports a note, PLAN B24); this
18
+ * tells the author before they save. "No longer has" is decided by the same
19
+ * checks a bookmark is reconciled with when it opens. Builder table columns
20
+ * only: a SQL or Python table's columns are known only from a result. Pure.
21
+ */
22
+ export declare function describeBookmarkImpact(input: {
23
+ readonly saved: TDashboard;
24
+ readonly draft: TDashboard;
25
+ readonly usage: BookmarkUsage;
26
+ }): readonly BookmarkImpactItem[];
27
+ /** How the editor names an affected part and what uses it: ("Revenue", "2 bookmarks, 1 remembered layout"). */
28
+ export declare function describeBookmarkImpactItem(item: BookmarkImpactItem): {
29
+ name: string;
30
+ uses: string;
31
+ };
32
+ /** One sentence for a proposal: what it removes that viewers saved, in the editor's words (card appearance CA-D17). */
33
+ export declare function bookmarkImpactSentence(item: BookmarkImpactItem): string;
@@ -1,6 +1,6 @@
1
1
  import { MatrixPath, MatrixPresentation, MatrixWindow, SemaphorScalarValue, SemaphorValueFormat } from '../../analytics-protocol/index.js';
2
2
  import { ReportRuntimeContext } from '../../report-runtime-context/index.js';
3
- import { MeasureCanonicalFormat } from '../types/index.js';
3
+ import { MeasureCanonicalFormat, RawTemporalFormat } from '../types/index.js';
4
4
  /** Null hierarchy members stay identifiable even when null cells render blank. */
5
5
  export declare function matrixMemberLabel(path: MatrixPath, levels?: ReadonlyMap<string, (value: SemaphorScalarValue) => string>): string;
6
6
  /**
@@ -29,7 +29,18 @@ export declare function matrixLevelLabels(input: {
29
29
  visible: boolean;
30
30
  total: boolean;
31
31
  }>;
32
- /** Shared viewer/export adapter. Arithmetic, precision and temporal rules stay shared. */
32
+ /**
33
+ * Shared viewer/export adapter: a Matrix measure's or level's format, its
34
+ * override, else its catalog (model) format, in the one precedence
35
+ * (`pickColumnFormat`). Arithmetic, precision and temporal rules stay shared.
36
+ */
37
+ /**
38
+ * A Matrix raw date level's authored format: what its cells draw of a stored
39
+ * date format (a pattern or preset, and the time zones). Relative time, a
40
+ * prefix and a suffix aren't drawn; card settings read that from here
41
+ * (card appearance CA-D24).
42
+ */
43
+ export declare function matrixRawDateFormat(stored: SemaphorValueFormat | undefined): RawTemporalFormat | undefined;
33
44
  export declare function resolveMatrixValueFormat(override: SemaphorValueFormat | undefined, semantic: SemaphorValueFormat | undefined): import('../semantic-format.js').AdaptedCanonicalFormatSpec | undefined;
34
45
  /** One card's prepared formats: every Matrix surface (screen, Layout CSV, Flat CSV, PDF) formats through it. */
35
46
  export type MatrixFormatting = ReturnType<typeof prepareMatrixFormatting>;
@@ -20,6 +20,22 @@ export declare function formatPercent(value: NumericValue | null | undefined, op
20
20
  * Format a number in scientific notation
21
21
  */
22
22
  export declare function formatScientific(value: NumericValue | null | undefined, options?: NumberFormatOptions): string;
23
+ /**
24
+ * What `signDisplay` (column formats CF-D16) does to a value: `never` drops
25
+ * its sign, `always` and `exceptZero` put a plus before a positive one;
26
+ * absent means `auto`. The one sign rule for every number formatter.
27
+ */
28
+ export declare function applySignDisplay(value: NumericValue, signDisplay: NumericCanonicalFormat['signDisplay']): {
29
+ value: NumericValue;
30
+ plus: boolean;
31
+ };
32
+ /**
33
+ * The format a change between two values shows with (a comparison's
34
+ * difference, a KPI's delta): its measure's, without the measure's
35
+ * `signDisplay`, which describes the values, not a change. The surface that
36
+ * shows the change puts its direction on it, once (column formats ledger P5-46).
37
+ */
38
+ export declare function changeFormat<T extends object | undefined>(format: T): T;
23
39
  export declare function formatNumericCanonical(value: number | ExactNumericValue | null | undefined, format: NumericCanonicalFormat): string;
24
40
  /**
25
41
  * Formats a table measure value with its resolved format: numeric styles go
@@ -25,6 +25,7 @@ export type * from './table-structure.js';
25
25
  export * from './pdf-export-policy.js';
26
26
  export * from './pdf-delivery.js';
27
27
  export * from './numeric-presentation.js';
28
+ export { pickColumnFormat, resolveColumnFormat, withLiveModelFormats, type ColumnFormatSource, type FormatSurface, type ModelFormats, type ResolvedColumnFormat, } from './resolve-column-format.js';
28
29
  export * from './presentation-execution.js';
29
30
  export * from './temporal-bucket-format-policy.js';
30
31
  export * from './temporal-bucket.js';
@@ -38,6 +39,7 @@ export { describeFilterValueInFullDetail, type FullDetailFilterValue, } from './
38
39
  export { describeConditionInFullDetail, type FilterClauseText } from './filter-detail.js';
39
40
  export { formatCanonicalComparisonRange } from '../../lib/utils/comparison-window-caption.js';
40
41
  export { PDF_GROUP_CONTINUATION_CLASS } from './grouped-table-presentation.js';
42
+ export { toStoredValueFormat } from './stored-value-format.js';
41
43
  export { SEMAPHOR_GENERATED_COUNT_METRIC_ID } from '../analytics-protocol/contracts.js';
42
44
  export { resolveMetricResultAlias } from '../analytics-protocol/metric-comparison.js';
43
45
  export * from './pivot-header-presentation.js';