react-semaphor 0.1.427 → 0.1.429
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/analytics-protocol/index.cjs +1 -1
- package/dist/analytics-protocol/index.js +72 -71
- package/dist/brand-studio/index.cjs +1 -1
- package/dist/brand-studio/index.js +5 -4
- package/dist/briefings/index.cjs +1 -1
- package/dist/briefings/index.js +1031 -622
- package/dist/chunks/analyze-result-contract-BswhsmWT.js +1 -0
- package/dist/chunks/{analyze-result-contract-DnfF8kBb.js → analyze-result-contract-CfOBEwaC.js} +681 -759
- package/dist/chunks/{code-editor-CojfM3qp.js → code-editor-C65eEYyU.js} +2980 -2960
- package/dist/chunks/code-editor-DOh3aYEh.js +138 -0
- package/dist/chunks/{comparison-document-migration-b6c3xiWh.js → comparison-document-migration-DbU_BTxR.js} +1 -1
- package/dist/chunks/{comparison-document-migration-BJH1idOd.js → comparison-document-migration-Dj6xZMCb.js} +2 -2
- package/dist/chunks/csv-utils-Co0WxHke.js +4 -0
- package/dist/chunks/csv-utils-suxSkJGj.js +376 -0
- package/dist/chunks/dashboard-CQfAvRYI.js +1401 -0
- package/dist/chunks/{dashboard-DSxho2LN.js → dashboard-agBXhvKo.js} +45651 -42951
- package/dist/chunks/{dashboard-briefing-launcher-CguxcHIl.js → dashboard-briefing-launcher-CkH_pthg.js} +1 -1
- package/dist/chunks/{dashboard-briefing-launcher-BFIw5BOf.js → dashboard-briefing-launcher-gBNNKqoH.js} +100 -99
- package/dist/chunks/{dashboard-controls-Cl0LagTr.js → dashboard-controls-CAZnIGfT.js} +2 -2
- package/dist/chunks/{dashboard-controls-jD-HpCNK.js → dashboard-controls-CoIxUTvH.js} +207 -202
- package/dist/chunks/{dashboard-json-BovTt0uu.js → dashboard-json-BMcPjL8-.js} +18 -17
- package/dist/chunks/dashboard-json-D4hFrMkX.js +1 -0
- package/dist/chunks/{edit-dashboard-visual-dlm8F_Qu.js → edit-dashboard-visual-Bc8qNfSr.js} +8721 -8481
- package/dist/chunks/edit-dashboard-visual-onhUUXlw.js +182 -0
- package/dist/chunks/{metric-comparison-CWweq9RG.js → metric-comparison-CPoDx56y.js} +1 -1
- package/dist/chunks/{metric-comparison-BKgkMy9r.js → metric-comparison-DVy3fll_.js} +1 -1
- package/dist/chunks/numeric-presentation-CGTcqocU.js +517 -0
- package/dist/chunks/numeric-presentation-Dlb-Dk4c.js +1 -0
- package/dist/chunks/report-preferences-dialog-CPptr_V9.js +690 -0
- package/dist/chunks/report-preferences-dialog-DV_5aHrS.js +1 -0
- package/dist/chunks/source-identity-5OPV4gvg.js +92 -0
- package/dist/chunks/source-identity-Cbo2LOHQ.js +1 -0
- package/dist/chunks/{update-policy-CY2k-pJP.js → update-policy-De2NswtM.js} +1 -1
- package/dist/chunks/{update-policy-BgONreNd.js → update-policy-DnF_74zC.js} +1 -1
- package/dist/chunks/{use-create-flow-overlay-state-kbl6avDY.js → use-create-flow-overlay-state-Bs6gqgjo.js} +1 -1
- package/dist/chunks/{use-create-flow-overlay-state-BU0ROMSm.js → use-create-flow-overlay-state-CgQbCrni.js} +97 -96
- package/dist/chunks/validators-B2vUAqTf.js +1 -0
- package/dist/chunks/{validators-Cz-XuORM.js → validators-Bce_J7Vd.js} +19 -13
- package/dist/dashboard/index.cjs +1 -1
- package/dist/dashboard/index.js +1 -1
- package/dist/dashboard-authoring/index.cjs +3 -3
- package/dist/dashboard-authoring/index.js +20 -19
- package/dist/data-app-builder/index.cjs +1 -1
- package/dist/data-app-builder/index.js +50 -50
- package/dist/data-app-codegen/index.cjs +1 -1
- package/dist/data-app-codegen/index.js +2 -2
- package/dist/data-app-codegen-node/index.cjs +1 -1
- package/dist/data-app-codegen-node/index.js +3 -3
- package/dist/data-app-sdk/index.cjs +2 -2
- package/dist/data-app-sdk/index.js +27 -26
- package/dist/data-app-sdk-adapters/index.cjs +1 -1
- package/dist/data-app-sdk-adapters/index.js +25 -24
- package/dist/data-app-sdk-validation/index.cjs +1 -1
- package/dist/data-app-sdk-validation/index.js +57 -55
- package/dist/format-utils/index.cjs +2 -5
- package/dist/format-utils/index.js +136 -161
- package/dist/index.cjs +1 -1
- package/dist/index.js +158 -155
- package/dist/report-runtime-context/index.cjs +1 -0
- package/dist/report-runtime-context/index.js +394 -0
- package/dist/style.css +1 -1
- package/dist/surfboard/index.cjs +1 -1
- package/dist/surfboard/index.js +7 -6
- package/dist/types/analytics-protocol.d.ts +0 -4
- package/dist/types/briefings.d.ts +216 -19
- package/dist/types/dashboard-assistant.d.ts +0 -2
- package/dist/types/dashboard-authoring.d.ts +34 -9
- package/dist/types/dashboard.d.ts +93 -9
- package/dist/types/data-app-builder.d.ts +0 -1
- package/dist/types/data-app-codegen-node.d.ts +6 -28
- package/dist/types/data-app-codegen.d.ts +6 -28
- package/dist/types/data-app-sdk-adapters.d.ts +6 -28
- package/dist/types/data-app-sdk-validation.d.ts +6 -29
- package/dist/types/data-app-sdk.d.ts +6 -31
- package/dist/types/format-utils.d.ts +128 -4
- package/dist/types/index.cjs +1 -1
- package/dist/types/index.js +10 -13
- package/dist/types/main.d.ts +249 -89
- package/dist/types/report-runtime-context.d.ts +99 -0
- package/dist/types/shared.d.ts +34 -9
- package/dist/types/surfboard.d.ts +119 -16
- package/dist/types/types.d.ts +156 -73
- package/dist/types/value-format-preferences.d.ts +126 -0
- package/dist/value-format-preferences/index.cjs +1 -0
- package/dist/value-format-preferences/index.js +635 -0
- package/package.json +11 -1
- package/dist/chunks/analyze-result-contract-ege_u6Nl.js +0 -1
- package/dist/chunks/calendar-preferences-dialog-DE4tk3t3.js +0 -457
- package/dist/chunks/calendar-preferences-dialog-DuGX1NPV.js +0 -1
- package/dist/chunks/code-editor-BoowcKU0.js +0 -138
- package/dist/chunks/dashboard-json-7mpQsizF.js +0 -1
- package/dist/chunks/dashboard-ogxedhSY.js +0 -1402
- package/dist/chunks/date-formatter-BTTYdAik.js +0 -1
- package/dist/chunks/date-formatter-D-89jTjG.js +0 -514
- package/dist/chunks/edit-dashboard-visual-B7wLrHeF.js +0 -182
- package/dist/chunks/validators-B4VMLX3_.js +0 -1
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
export declare type CalendarContext = {
|
|
2
|
+
tz: string;
|
|
3
|
+
weekStart: WeekStart;
|
|
4
|
+
anchor: 'now' | {
|
|
5
|
+
iso: string;
|
|
6
|
+
};
|
|
7
|
+
fiscalCalendar?: MonthAlignedFiscalCalendar;
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
export declare type CalendarPreferences = {
|
|
11
|
+
tz?: string;
|
|
12
|
+
weekStart?: WeekStart;
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
export declare type CalendarPreferencesResponse = {
|
|
16
|
+
stored: CalendarPreferences | null;
|
|
17
|
+
inherited: ResolvedCalendarPreferences;
|
|
18
|
+
inheritedSources: ResolvedCalendarPreferenceSources;
|
|
19
|
+
resolved: ResolvedCalendarPreferences;
|
|
20
|
+
sources: ResolvedCalendarPreferenceSources;
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
export declare const DEFAULT_CALENDAR_CONTEXT: CalendarContext;
|
|
24
|
+
|
|
25
|
+
declare type LocaleStyle = 'short' | 'medium' | 'long';
|
|
26
|
+
|
|
27
|
+
export declare type MonthAlignedFiscalCalendar = {
|
|
28
|
+
kind: 'month_aligned';
|
|
29
|
+
yearStartMonth: number;
|
|
30
|
+
};
|
|
31
|
+
|
|
32
|
+
export declare function parseCalendarContext(input: unknown): ReportRuntimeContextParseResult<CalendarContext>;
|
|
33
|
+
|
|
34
|
+
export declare function parseCalendarPreferencesResponse(input: unknown): ReportRuntimeContextParseResult<CalendarPreferencesResponse>;
|
|
35
|
+
|
|
36
|
+
export declare function parseReportRuntimeContext(input: unknown): ReportRuntimeContextParseResult<ReportRuntimeContext>;
|
|
37
|
+
|
|
38
|
+
declare const REPORT_PREFERENCE_SOURCES: readonly ["viewer_user", "viewer_tenant_user", "session_initial", "viewer_tenant", "viewer_organization", "system_default"];
|
|
39
|
+
|
|
40
|
+
declare type ReportPreferenceSource = (typeof REPORT_PREFERENCE_SOURCES)[number];
|
|
41
|
+
|
|
42
|
+
export declare type ReportPreferenceSources = {
|
|
43
|
+
calendar: ResolvedCalendarPreferenceSources;
|
|
44
|
+
valueFormat: ResolvedValueFormatPreferenceSources;
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
export declare type ReportRuntimeContext = {
|
|
48
|
+
calendar: CalendarContext;
|
|
49
|
+
valueFormat: ResolvedValueFormatPreferences;
|
|
50
|
+
preferenceSources: ReportPreferenceSources;
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
export declare type ReportRuntimeContextParseResult<T> = {
|
|
54
|
+
ok: true;
|
|
55
|
+
value: T;
|
|
56
|
+
} | {
|
|
57
|
+
ok: false;
|
|
58
|
+
issues: ReportRuntimeContextValidationIssue[];
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
export declare type ReportRuntimeContextValidationIssue = {
|
|
62
|
+
path: string;
|
|
63
|
+
code: 'invalid_type' | 'unknown_property' | 'invalid_timezone' | 'invalid_week_start' | 'invalid_anchor' | 'invalid_fiscal_calendar' | 'invalid_value_format' | 'invalid_preference_source';
|
|
64
|
+
message: string;
|
|
65
|
+
};
|
|
66
|
+
|
|
67
|
+
export declare type ResolvedCalendarPreferences = {
|
|
68
|
+
tz: string;
|
|
69
|
+
weekStart: WeekStart;
|
|
70
|
+
};
|
|
71
|
+
|
|
72
|
+
export declare type ResolvedCalendarPreferenceSources = {
|
|
73
|
+
tz: ReportPreferenceSource;
|
|
74
|
+
weekStart: ReportPreferenceSource;
|
|
75
|
+
};
|
|
76
|
+
|
|
77
|
+
declare type ResolvedValueFormatPreferences = {
|
|
78
|
+
locale: string;
|
|
79
|
+
dateStyle: LocaleStyle;
|
|
80
|
+
dateTime: {
|
|
81
|
+
dateStyle: LocaleStyle;
|
|
82
|
+
timeStyle: LocaleStyle;
|
|
83
|
+
};
|
|
84
|
+
defaultCurrency: string;
|
|
85
|
+
};
|
|
86
|
+
|
|
87
|
+
declare type ResolvedValueFormatPreferenceSources = {
|
|
88
|
+
locale: ReportPreferenceSource;
|
|
89
|
+
dateStyle: ReportPreferenceSource;
|
|
90
|
+
dateTime: {
|
|
91
|
+
dateStyle: ReportPreferenceSource;
|
|
92
|
+
timeStyle: ReportPreferenceSource;
|
|
93
|
+
};
|
|
94
|
+
defaultCurrency: ReportPreferenceSource;
|
|
95
|
+
};
|
|
96
|
+
|
|
97
|
+
export declare type WeekStart = 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
98
|
+
|
|
99
|
+
export { }
|
package/dist/types/shared.d.ts
CHANGED
|
@@ -295,12 +295,17 @@ declare interface ColumnSettings {
|
|
|
295
295
|
totalsLabel?: string;
|
|
296
296
|
numberFormat: {
|
|
297
297
|
style: 'decimal' | 'currency' | 'percent' | 'scientific';
|
|
298
|
-
currency
|
|
299
|
-
locale
|
|
300
|
-
minimumFractionDigits
|
|
301
|
-
maximumFractionDigits
|
|
298
|
+
currency?: string;
|
|
299
|
+
locale?: string;
|
|
300
|
+
minimumFractionDigits?: number;
|
|
301
|
+
maximumFractionDigits?: number;
|
|
302
302
|
useGrouping?: boolean;
|
|
303
303
|
percentValueMode?: 'fraction' | 'whole';
|
|
304
|
+
scale?: number;
|
|
305
|
+
compact?: boolean;
|
|
306
|
+
negativeStyle?: 'minus' | 'parentheses';
|
|
307
|
+
prefix?: string;
|
|
308
|
+
suffix?: string;
|
|
304
309
|
showDataBar: boolean;
|
|
305
310
|
dataBarColor: string;
|
|
306
311
|
dataBarMinValue?: number;
|
|
@@ -326,8 +331,6 @@ declare interface ColumnSettings {
|
|
|
326
331
|
colorRanges: ColorRange_2[];
|
|
327
332
|
}
|
|
328
333
|
|
|
329
|
-
declare type ColumnSettingsMap = Record<string, ColumnSettings>;
|
|
330
|
-
|
|
331
334
|
declare type ColumnTextWrap = 'default' | 'truncate' | 'wrap' | 'nowrap' | 'preserve';
|
|
332
335
|
|
|
333
336
|
declare type ColumnType = 'string' | 'number' | 'date';
|
|
@@ -465,7 +468,7 @@ declare type ControlBinding = {
|
|
|
465
468
|
controlId: string;
|
|
466
469
|
target: 'config_grain';
|
|
467
470
|
mapping: Record<string, string>;
|
|
468
|
-
};
|
|
471
|
+
} | CurrencyPresentationBinding;
|
|
469
472
|
|
|
470
473
|
declare type ControlDashboardInput = DashboardInputBase & {
|
|
471
474
|
kind: 'control';
|
|
@@ -520,6 +523,23 @@ declare type ControlSource = {
|
|
|
520
523
|
|
|
521
524
|
declare type ControlType = 'enum' | 'multi_enum' | 'text' | 'number' | 'boolean' | 'date' | 'field_selector' | 'metric_selector' | 'aggregation_selector' | 'grain_selector';
|
|
522
525
|
|
|
526
|
+
declare type CurrencyPresentationBinding = {
|
|
527
|
+
controlId: string;
|
|
528
|
+
target: 'presentation_currency';
|
|
529
|
+
presentationTarget: CurrencyPresentationTarget;
|
|
530
|
+
};
|
|
531
|
+
|
|
532
|
+
declare type CurrencyPresentationTarget = {
|
|
533
|
+
kind: 'metric';
|
|
534
|
+
metricId: string;
|
|
535
|
+
} | {
|
|
536
|
+
kind: 'column';
|
|
537
|
+
columnKey: string;
|
|
538
|
+
} | {
|
|
539
|
+
kind: 'matrix_measure';
|
|
540
|
+
measureId: string;
|
|
541
|
+
};
|
|
542
|
+
|
|
523
543
|
declare type CustomCard = CardWithContent | CardWithFooter;
|
|
524
544
|
|
|
525
545
|
declare type DashboardAIContext = AIContext & {
|
|
@@ -1603,6 +1623,12 @@ declare interface PaginationConfig {
|
|
|
1603
1623
|
pageSize: number;
|
|
1604
1624
|
}
|
|
1605
1625
|
|
|
1626
|
+
declare type PersistedColumnSettings = Omit<Partial<ColumnSettings>, 'numberFormat'> & {
|
|
1627
|
+
numberFormat?: Partial<ColumnSettings['numberFormat']>;
|
|
1628
|
+
};
|
|
1629
|
+
|
|
1630
|
+
declare type PersistedColumnSettingsMap = Record<string, PersistedColumnSettings>;
|
|
1631
|
+
|
|
1606
1632
|
declare type PersistedInteraction = Interaction & {
|
|
1607
1633
|
id?: string;
|
|
1608
1634
|
};
|
|
@@ -1933,7 +1959,6 @@ declare type SemaphorTimeGrain = 'hour' | 'day' | 'week' | 'month' | 'quarter' |
|
|
|
1933
1959
|
|
|
1934
1960
|
declare type SemaphorValueFormat = {
|
|
1935
1961
|
type: 'number' | 'currency' | 'percent' | 'percentage' | 'scientific';
|
|
1936
|
-
locale?: string;
|
|
1937
1962
|
minimumFractionDigits?: number;
|
|
1938
1963
|
maximumFractionDigits?: number;
|
|
1939
1964
|
useGrouping?: boolean;
|
|
@@ -2082,7 +2107,7 @@ declare type TableHeaderStyle = 'plain' | 'filled' | 'accent';
|
|
|
2082
2107
|
declare type TablePart = 'body' | 'header' | 'footer' | 'subtotal' | 'grandTotal';
|
|
2083
2108
|
|
|
2084
2109
|
declare type TablePreferences = {
|
|
2085
|
-
columnSettingsMap?:
|
|
2110
|
+
columnSettingsMap?: PersistedColumnSettingsMap;
|
|
2086
2111
|
baseFormatting?: TableBaseFormatting;
|
|
2087
2112
|
conditionalFormatting?: TableConditionalFormatting;
|
|
2088
2113
|
selectColumnVisible?: boolean;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { ColumnSizingState } from '@tanstack/react-table';
|
|
2
|
-
import { default as default_2 } from 'react';
|
|
3
2
|
import { FontSpec } from 'chart.js';
|
|
4
3
|
import { JSX } from 'react';
|
|
5
4
|
|
|
@@ -204,12 +203,14 @@ declare interface CalculatedFieldFormula {
|
|
|
204
203
|
*/
|
|
205
204
|
declare type CalculatedFieldOperation = 'sum' | 'difference' | 'product' | 'ratio' | 'change' | 'percentage' | 'scale' | 'custom';
|
|
206
205
|
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
}
|
|
206
|
+
declare type CalendarContext = {
|
|
207
|
+
tz: string;
|
|
208
|
+
weekStart: WeekStart;
|
|
209
|
+
anchor: 'now' | {
|
|
210
|
+
iso: string;
|
|
211
|
+
};
|
|
212
|
+
fiscalCalendar?: MonthAlignedFiscalCalendar;
|
|
213
|
+
};
|
|
213
214
|
|
|
214
215
|
declare interface CardConfig {
|
|
215
216
|
/**
|
|
@@ -395,12 +396,17 @@ declare interface ColumnSettings {
|
|
|
395
396
|
totalsLabel?: string;
|
|
396
397
|
numberFormat: {
|
|
397
398
|
style: 'decimal' | 'currency' | 'percent' | 'scientific';
|
|
398
|
-
currency
|
|
399
|
-
locale
|
|
400
|
-
minimumFractionDigits
|
|
401
|
-
maximumFractionDigits
|
|
399
|
+
currency?: string;
|
|
400
|
+
locale?: string;
|
|
401
|
+
minimumFractionDigits?: number;
|
|
402
|
+
maximumFractionDigits?: number;
|
|
402
403
|
useGrouping?: boolean;
|
|
403
404
|
percentValueMode?: 'fraction' | 'whole';
|
|
405
|
+
scale?: number;
|
|
406
|
+
compact?: boolean;
|
|
407
|
+
negativeStyle?: 'minus' | 'parentheses';
|
|
408
|
+
prefix?: string;
|
|
409
|
+
suffix?: string;
|
|
404
410
|
showDataBar: boolean;
|
|
405
411
|
dataBarColor: string;
|
|
406
412
|
dataBarMinValue?: number;
|
|
@@ -426,8 +432,6 @@ declare interface ColumnSettings {
|
|
|
426
432
|
colorRanges: ColorRange_2[];
|
|
427
433
|
}
|
|
428
434
|
|
|
429
|
-
declare type ColumnSettingsMap = Record<string, ColumnSettings>;
|
|
430
|
-
|
|
431
435
|
declare type ColumnTextWrap = 'default' | 'truncate' | 'wrap' | 'nowrap' | 'preserve';
|
|
432
436
|
|
|
433
437
|
declare type ColumnType = 'string' | 'number' | 'date';
|
|
@@ -573,7 +577,7 @@ export declare type ControlBinding = {
|
|
|
573
577
|
controlId: string;
|
|
574
578
|
target: 'config_grain';
|
|
575
579
|
mapping: Record<string, string>;
|
|
576
|
-
};
|
|
580
|
+
} | CurrencyPresentationBinding;
|
|
577
581
|
|
|
578
582
|
export declare type ControlDashboardInput = DashboardInputBase & {
|
|
579
583
|
kind: 'control';
|
|
@@ -628,6 +632,23 @@ export declare type ControlSource = {
|
|
|
628
632
|
|
|
629
633
|
export declare type ControlType = 'enum' | 'multi_enum' | 'text' | 'number' | 'boolean' | 'date' | 'field_selector' | 'metric_selector' | 'aggregation_selector' | 'grain_selector';
|
|
630
634
|
|
|
635
|
+
export declare type CurrencyPresentationBinding = {
|
|
636
|
+
controlId: string;
|
|
637
|
+
target: 'presentation_currency';
|
|
638
|
+
presentationTarget: CurrencyPresentationTarget;
|
|
639
|
+
};
|
|
640
|
+
|
|
641
|
+
export declare type CurrencyPresentationTarget = {
|
|
642
|
+
kind: 'metric';
|
|
643
|
+
metricId: string;
|
|
644
|
+
} | {
|
|
645
|
+
kind: 'column';
|
|
646
|
+
columnKey: string;
|
|
647
|
+
} | {
|
|
648
|
+
kind: 'matrix_measure';
|
|
649
|
+
measureId: string;
|
|
650
|
+
};
|
|
651
|
+
|
|
631
652
|
export declare type CustomCard = CardWithContent | CardWithFooter;
|
|
632
653
|
|
|
633
654
|
declare type DashboardAIContext = AIContext & {
|
|
@@ -965,6 +986,16 @@ declare type Dialect = 'mysql' | 'postgres' | 'bigquery' | 'redshift' | 'snowfla
|
|
|
965
986
|
|
|
966
987
|
export declare type DisplayDataType = 'string' | 'date' | 'number' | 'html' | 'none';
|
|
967
988
|
|
|
989
|
+
export declare function DisplayFormatPreferencesFields({ value, inherited, inheritedSources, onChange, disabled, }: DisplayFormatPreferencesFieldsProps): JSX.Element;
|
|
990
|
+
|
|
991
|
+
export declare type DisplayFormatPreferencesFieldsProps = {
|
|
992
|
+
value: ValueFormatPreferences;
|
|
993
|
+
inherited: ResolvedValueFormatPreferences;
|
|
994
|
+
inheritedSources: Pick<ResolvedValueFormatPreferenceSources, 'locale' | 'defaultCurrency'>;
|
|
995
|
+
onChange: (value: ValueFormatPreferences) => void;
|
|
996
|
+
disabled?: boolean;
|
|
997
|
+
};
|
|
998
|
+
|
|
968
999
|
export declare type DocumentChartSection = {
|
|
969
1000
|
id: string;
|
|
970
1001
|
type: 'chart';
|
|
@@ -1572,6 +1603,7 @@ declare type FormatSpec = {
|
|
|
1572
1603
|
|
|
1573
1604
|
export declare type GetDashboardResponse = {
|
|
1574
1605
|
dashboard: TDashboard;
|
|
1606
|
+
initialReportContext: ReportRuntimeContext;
|
|
1575
1607
|
lenses: TLens[];
|
|
1576
1608
|
filterValues?: TFilterValue[] | null;
|
|
1577
1609
|
inputValues?: LensInputValuesSnapshot | null;
|
|
@@ -1753,6 +1785,8 @@ export declare type LoadingProps = {
|
|
|
1753
1785
|
message?: string;
|
|
1754
1786
|
};
|
|
1755
1787
|
|
|
1788
|
+
declare type LocaleStyle = 'short' | 'medium' | 'long';
|
|
1789
|
+
|
|
1756
1790
|
declare type LogicalOperator = 'AND' | 'OR';
|
|
1757
1791
|
|
|
1758
1792
|
/**
|
|
@@ -1847,6 +1881,11 @@ declare interface MetricField extends Field {
|
|
|
1847
1881
|
semanticComparisonPolarity?: MetricComparisonPolarity;
|
|
1848
1882
|
}
|
|
1849
1883
|
|
|
1884
|
+
declare type MonthAlignedFiscalCalendar = {
|
|
1885
|
+
kind: 'month_aligned';
|
|
1886
|
+
yearStartMonth: number;
|
|
1887
|
+
};
|
|
1888
|
+
|
|
1850
1889
|
declare type NoneOptions = {};
|
|
1851
1890
|
|
|
1852
1891
|
export declare type NumberAxisFormat = {
|
|
@@ -1898,6 +1937,12 @@ declare type Params = {
|
|
|
1898
1937
|
[key: string]: string | number | string[] | number[];
|
|
1899
1938
|
};
|
|
1900
1939
|
|
|
1940
|
+
declare type PersistedColumnSettings = Omit<Partial<ColumnSettings>, 'numberFormat'> & {
|
|
1941
|
+
numberFormat?: Partial<ColumnSettings['numberFormat']>;
|
|
1942
|
+
};
|
|
1943
|
+
|
|
1944
|
+
declare type PersistedColumnSettingsMap = Record<string, PersistedColumnSettings>;
|
|
1945
|
+
|
|
1901
1946
|
declare type PersistedInteraction = Interaction & {
|
|
1902
1947
|
id?: string;
|
|
1903
1948
|
};
|
|
@@ -1965,6 +2010,33 @@ declare type RelativeDateFilter = {
|
|
|
1965
2010
|
to: number;
|
|
1966
2011
|
};
|
|
1967
2012
|
|
|
2013
|
+
declare const REPORT_PREFERENCE_SOURCES: readonly ["viewer_user", "viewer_tenant_user", "session_initial", "viewer_tenant", "viewer_organization", "system_default"];
|
|
2014
|
+
|
|
2015
|
+
export declare function ReportPreferencesDialog({ open, onOpenChange, }: ReportPreferencesDialogProps): JSX.Element;
|
|
2016
|
+
|
|
2017
|
+
declare type ReportPreferencesDialogProps = {
|
|
2018
|
+
open: boolean;
|
|
2019
|
+
onOpenChange: (open: boolean) => void;
|
|
2020
|
+
};
|
|
2021
|
+
|
|
2022
|
+
declare type ReportPreferenceSource = (typeof REPORT_PREFERENCE_SOURCES)[number];
|
|
2023
|
+
|
|
2024
|
+
declare type ReportPreferenceSources = {
|
|
2025
|
+
calendar: ResolvedCalendarPreferenceSources;
|
|
2026
|
+
valueFormat: ResolvedValueFormatPreferenceSources;
|
|
2027
|
+
};
|
|
2028
|
+
|
|
2029
|
+
declare type ReportRuntimeContext = {
|
|
2030
|
+
calendar: CalendarContext;
|
|
2031
|
+
valueFormat: ResolvedValueFormatPreferences;
|
|
2032
|
+
preferenceSources: ReportPreferenceSources;
|
|
2033
|
+
};
|
|
2034
|
+
|
|
2035
|
+
declare type ResolvedCalendarPreferenceSources = {
|
|
2036
|
+
tz: ReportPreferenceSource;
|
|
2037
|
+
weekStart: ReportPreferenceSource;
|
|
2038
|
+
};
|
|
2039
|
+
|
|
1968
2040
|
export declare type ResolvedDashboardDateComparisonInput = {
|
|
1969
2041
|
inputId: string;
|
|
1970
2042
|
filterId: string;
|
|
@@ -2040,6 +2112,26 @@ declare type ResolvedPrimaryDateField = {
|
|
|
2040
2112
|
supportedGranularities?: TimeGranularity[];
|
|
2041
2113
|
} | null;
|
|
2042
2114
|
|
|
2115
|
+
declare type ResolvedValueFormatPreferences = {
|
|
2116
|
+
locale: string;
|
|
2117
|
+
dateStyle: LocaleStyle;
|
|
2118
|
+
dateTime: {
|
|
2119
|
+
dateStyle: LocaleStyle;
|
|
2120
|
+
timeStyle: LocaleStyle;
|
|
2121
|
+
};
|
|
2122
|
+
defaultCurrency: string;
|
|
2123
|
+
};
|
|
2124
|
+
|
|
2125
|
+
declare type ResolvedValueFormatPreferenceSources = {
|
|
2126
|
+
locale: ReportPreferenceSource;
|
|
2127
|
+
dateStyle: ReportPreferenceSource;
|
|
2128
|
+
dateTime: {
|
|
2129
|
+
dateStyle: ReportPreferenceSource;
|
|
2130
|
+
timeStyle: ReportPreferenceSource;
|
|
2131
|
+
};
|
|
2132
|
+
defaultCurrency: ReportPreferenceSource;
|
|
2133
|
+
};
|
|
2134
|
+
|
|
2043
2135
|
declare type SelectedEntities = SelectedEntity[];
|
|
2044
2136
|
|
|
2045
2137
|
declare type SelectedEntity = DatabaseEntityReference | DataModelEntityReference | DatasetEntityReference | FileEntityReference;
|
|
@@ -2326,7 +2418,6 @@ declare type SemaphorTimeGrain = 'hour' | 'day' | 'week' | 'month' | 'quarter' |
|
|
|
2326
2418
|
|
|
2327
2419
|
declare type SemaphorValueFormat = {
|
|
2328
2420
|
type: 'number' | 'currency' | 'percent' | 'percentage' | 'scientific';
|
|
2329
|
-
locale?: string;
|
|
2330
2421
|
minimumFractionDigits?: number;
|
|
2331
2422
|
maximumFractionDigits?: number;
|
|
2332
2423
|
useGrouping?: boolean;
|
|
@@ -2524,7 +2615,7 @@ declare type TableHeaderStyle = 'plain' | 'filled' | 'accent';
|
|
|
2524
2615
|
declare type TablePart = 'body' | 'header' | 'footer' | 'subtotal' | 'grandTotal';
|
|
2525
2616
|
|
|
2526
2617
|
declare type TablePreferences = {
|
|
2527
|
-
columnSettingsMap?:
|
|
2618
|
+
columnSettingsMap?: PersistedColumnSettingsMap;
|
|
2528
2619
|
baseFormatting?: TableBaseFormatting;
|
|
2529
2620
|
conditionalFormatting?: TableConditionalFormatting;
|
|
2530
2621
|
selectColumnVisible?: boolean;
|
|
@@ -3421,6 +3512,16 @@ export declare interface UserPreference {
|
|
|
3421
3512
|
updatedAt: string;
|
|
3422
3513
|
}
|
|
3423
3514
|
|
|
3515
|
+
declare type ValueFormatPreferences = {
|
|
3516
|
+
locale?: string;
|
|
3517
|
+
dateStyle?: LocaleStyle;
|
|
3518
|
+
dateTime?: {
|
|
3519
|
+
dateStyle?: LocaleStyle;
|
|
3520
|
+
timeStyle?: LocaleStyle;
|
|
3521
|
+
};
|
|
3522
|
+
defaultCurrency?: string;
|
|
3523
|
+
};
|
|
3524
|
+
|
|
3424
3525
|
declare type ViewerPeriodComparisonSpec = Extract<MetricComparisonSpec, {
|
|
3425
3526
|
kind: 'previous_period' | 'previous_year';
|
|
3426
3527
|
}>;
|
|
@@ -3461,6 +3562,8 @@ export declare type VisualDisplayPreferences = {
|
|
|
3461
3562
|
};
|
|
3462
3563
|
};
|
|
3463
3564
|
|
|
3565
|
+
declare type WeekStart = 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
3566
|
+
|
|
3464
3567
|
declare type WindowFunction = 'running_total' | 'moving_average' | 'previous_period_delta' | 'percent_of_total';
|
|
3465
3568
|
|
|
3466
3569
|
declare interface WindowTransform {
|