react-semaphor 0.1.428 → 0.1.430
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-509sbC4_.js → dashboard-0Tpj3XFq.js} +49934 -47167
- package/dist/chunks/dashboard-CVDy3fbO.js +1402 -0
- package/dist/chunks/{dashboard-briefing-launcher-B-ZTWJwo.js → dashboard-briefing-launcher-DLQqwXMF.js} +1 -1
- package/dist/chunks/{dashboard-briefing-launcher-DIdYHNTq.js → dashboard-briefing-launcher-pkNPk_4j.js} +100 -99
- package/dist/chunks/{dashboard-controls-CbRzWo1N.js → dashboard-controls-CIN4biYx.js} +114 -113
- package/dist/chunks/{dashboard-controls-CWprw-Pb.js → dashboard-controls-DbW9Jt_P.js} +2 -2
- package/dist/chunks/dashboard-json-BDKT0Z-m.js +1 -0
- package/dist/chunks/{dashboard-json-jO4GQfZk.js → dashboard-json-DBfR770k.js} +18 -17
- package/dist/chunks/edit-dashboard-visual-BjAp_UpK.js +182 -0
- package/dist/chunks/{edit-dashboard-visual-KgQTjqWp.js → edit-dashboard-visual-qkvRHS8Q.js} +8721 -8481
- 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-Bx8uzG8K.js +690 -0
- package/dist/chunks/report-preferences-dialog-LCHeqh7t.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-BiMYdjZP.js → use-create-flow-overlay-state-C-CxrQ48.js} +1 -1
- package/dist/chunks/{use-create-flow-overlay-state-CGsLzp9A.js → use-create-flow-overlay-state-C-j8E5IZ.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-BF9bNAF_.js +0 -457
- package/dist/chunks/calendar-preferences-dialog-_L9eBQfj.js +0 -1
- package/dist/chunks/code-editor-BoowcKU0.js +0 -138
- package/dist/chunks/dashboard-CMDXBLnG.js +0 -1402
- package/dist/chunks/dashboard-json-BEZrxx_k.js +0 -1
- 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-D3uhqgm3.js +0 -182
- package/dist/chunks/validators-B4VMLX3_.js +0 -1
|
@@ -26,6 +26,15 @@ export declare function arrayToCSV(rows: (string | number | null | undefined)[][
|
|
|
26
26
|
*/
|
|
27
27
|
export declare function arrayToCSVRow(values: (string | number | null | undefined)[], delimiter?: string): string;
|
|
28
28
|
|
|
29
|
+
declare type CalendarContext = {
|
|
30
|
+
tz: string;
|
|
31
|
+
weekStart: WeekStart;
|
|
32
|
+
anchor: 'now' | {
|
|
33
|
+
iso: string;
|
|
34
|
+
};
|
|
35
|
+
fiscalCalendar?: MonthAlignedFiscalCalendar;
|
|
36
|
+
};
|
|
37
|
+
|
|
29
38
|
export declare type CanonicalDurationUnit = 'millisecond' | 'second' | 'minute' | 'hour' | 'day';
|
|
30
39
|
|
|
31
40
|
export declare type CanonicalFormatSpec = NumericCanonicalFormat | DateCanonicalFormat | DurationCanonicalFormat | StringCanonicalFormat;
|
|
@@ -51,10 +60,10 @@ export declare interface ColumnSettings {
|
|
|
51
60
|
width?: number;
|
|
52
61
|
numberFormat?: {
|
|
53
62
|
style: 'decimal' | 'currency' | 'percent' | 'scientific';
|
|
54
|
-
currency
|
|
55
|
-
locale
|
|
56
|
-
minimumFractionDigits
|
|
57
|
-
maximumFractionDigits
|
|
63
|
+
currency?: string;
|
|
64
|
+
locale?: string;
|
|
65
|
+
minimumFractionDigits?: number;
|
|
66
|
+
maximumFractionDigits?: number;
|
|
58
67
|
useGrouping?: boolean;
|
|
59
68
|
percentValueMode?: 'fraction' | 'whole';
|
|
60
69
|
showDataBar?: boolean;
|
|
@@ -265,8 +274,15 @@ export declare function formatNumberWithColumnSettings(value: number | null | un
|
|
|
265
274
|
maximumFractionDigits?: number;
|
|
266
275
|
useGrouping?: boolean;
|
|
267
276
|
percentValueMode?: 'fraction' | 'whole';
|
|
277
|
+
scale?: number;
|
|
278
|
+
compact?: boolean;
|
|
279
|
+
negativeStyle?: 'minus' | 'parentheses';
|
|
280
|
+
prefix?: string;
|
|
281
|
+
suffix?: string;
|
|
268
282
|
} | undefined, defaultLocale?: string): string;
|
|
269
283
|
|
|
284
|
+
export declare function formatNumericCanonical(value: number | null | undefined, format: NumericCanonicalFormat): string;
|
|
285
|
+
|
|
270
286
|
export declare interface FormatOptions {
|
|
271
287
|
decimalPlaces?: number;
|
|
272
288
|
useSuffix?: boolean;
|
|
@@ -367,6 +383,8 @@ export declare interface GroupByField {
|
|
|
367
383
|
label?: string;
|
|
368
384
|
}
|
|
369
385
|
|
|
386
|
+
declare type LocaleStyle = 'short' | 'medium' | 'long';
|
|
387
|
+
|
|
370
388
|
declare type MetricComparisonDirection = 'increase' | 'decrease' | 'no_change' | 'unknown';
|
|
371
389
|
|
|
372
390
|
export declare type MetricComparisonDisplayMode = 'difference' | 'percent_change' | 'both' | 'ratio';
|
|
@@ -384,6 +402,11 @@ declare type MetricComparisonEvaluation = {
|
|
|
384
402
|
|
|
385
403
|
declare type MetricComparisonSentiment = 'favorable' | 'unfavorable' | 'neutral';
|
|
386
404
|
|
|
405
|
+
declare type MonthAlignedFiscalCalendar = {
|
|
406
|
+
kind: 'month_aligned';
|
|
407
|
+
yearStartMonth: number;
|
|
408
|
+
};
|
|
409
|
+
|
|
387
410
|
export declare interface NumberFormatOptions {
|
|
388
411
|
style: 'decimal' | 'currency' | 'percent' | 'scientific';
|
|
389
412
|
locale?: string;
|
|
@@ -428,6 +451,43 @@ export declare type NumericCanonicalFormat = {
|
|
|
428
451
|
percentValueMode?: 'fraction' | 'whole';
|
|
429
452
|
};
|
|
430
453
|
|
|
454
|
+
export declare type NumericCanonicalFormatParseResult = {
|
|
455
|
+
ok: true;
|
|
456
|
+
value: NumericCanonicalFormat;
|
|
457
|
+
} | {
|
|
458
|
+
ok: false;
|
|
459
|
+
issues: Array<{
|
|
460
|
+
path: string;
|
|
461
|
+
message: string;
|
|
462
|
+
}>;
|
|
463
|
+
};
|
|
464
|
+
|
|
465
|
+
export declare type NumericPresentationExecutionSnapshot = {
|
|
466
|
+
reportContext: ReportRuntimeContext;
|
|
467
|
+
resolvedNumericFormats: NumericPresentationSnapshotEntry[];
|
|
468
|
+
};
|
|
469
|
+
|
|
470
|
+
export declare type NumericPresentationSnapshotEntry = {
|
|
471
|
+
scope: {
|
|
472
|
+
dashboardId: string;
|
|
473
|
+
cardId?: string;
|
|
474
|
+
attachmentIndex?: number;
|
|
475
|
+
};
|
|
476
|
+
target: NumericPresentationTarget;
|
|
477
|
+
format: NumericCanonicalFormat;
|
|
478
|
+
};
|
|
479
|
+
|
|
480
|
+
export declare type NumericPresentationTarget = {
|
|
481
|
+
kind: 'metric';
|
|
482
|
+
metricId: string;
|
|
483
|
+
} | {
|
|
484
|
+
kind: 'column';
|
|
485
|
+
columnKey: string;
|
|
486
|
+
} | {
|
|
487
|
+
kind: 'matrix_measure';
|
|
488
|
+
measureId: string;
|
|
489
|
+
};
|
|
490
|
+
|
|
431
491
|
/**
|
|
432
492
|
* Convert an array of objects to CSV string
|
|
433
493
|
*/
|
|
@@ -435,6 +495,14 @@ export declare function objectsToCSV(data: Record<string, unknown>[], options?:
|
|
|
435
495
|
columns?: string[];
|
|
436
496
|
}): string;
|
|
437
497
|
|
|
498
|
+
export declare function parseNumericCanonicalFormat(input: unknown): NumericCanonicalFormatParseResult;
|
|
499
|
+
|
|
500
|
+
export declare function parseNumericPresentationExecutionSnapshot(input: unknown): NumericPresentationExecutionSnapshot;
|
|
501
|
+
|
|
502
|
+
export declare function parseNumericPresentationSnapshotEntries(input: unknown): NumericPresentationSnapshotEntry[];
|
|
503
|
+
|
|
504
|
+
export declare function parseResolvedNumericCanonicalFormat(input: unknown): NumericCanonicalFormatParseResult;
|
|
505
|
+
|
|
438
506
|
/**
|
|
439
507
|
* Parse a date string with source timezone interpretation
|
|
440
508
|
*
|
|
@@ -483,6 +551,50 @@ export declare interface PivotRowData {
|
|
|
483
551
|
isGrandTotal?: boolean;
|
|
484
552
|
}
|
|
485
553
|
|
|
554
|
+
declare const REPORT_PREFERENCE_SOURCES: readonly ["viewer_user", "viewer_tenant_user", "session_initial", "viewer_tenant", "viewer_organization", "system_default"];
|
|
555
|
+
|
|
556
|
+
declare type ReportPreferenceSource = (typeof REPORT_PREFERENCE_SOURCES)[number];
|
|
557
|
+
|
|
558
|
+
declare type ReportPreferenceSources = {
|
|
559
|
+
calendar: ResolvedCalendarPreferenceSources;
|
|
560
|
+
valueFormat: ResolvedValueFormatPreferenceSources;
|
|
561
|
+
};
|
|
562
|
+
|
|
563
|
+
declare type ReportRuntimeContext = {
|
|
564
|
+
calendar: CalendarContext;
|
|
565
|
+
valueFormat: ResolvedValueFormatPreferences;
|
|
566
|
+
preferenceSources: ReportPreferenceSources;
|
|
567
|
+
};
|
|
568
|
+
|
|
569
|
+
export declare function resolveCurrencyFractionDigits(locale: string, currency: string): Pick<NumericCanonicalFormat, 'minimumFractionDigits' | 'maximumFractionDigits'>;
|
|
570
|
+
|
|
571
|
+
declare type ResolvedCalendarPreferenceSources = {
|
|
572
|
+
tz: ReportPreferenceSource;
|
|
573
|
+
weekStart: ReportPreferenceSource;
|
|
574
|
+
};
|
|
575
|
+
|
|
576
|
+
declare type ResolvedValueFormatPreferences = {
|
|
577
|
+
locale: string;
|
|
578
|
+
dateStyle: LocaleStyle;
|
|
579
|
+
dateTime: {
|
|
580
|
+
dateStyle: LocaleStyle;
|
|
581
|
+
timeStyle: LocaleStyle;
|
|
582
|
+
};
|
|
583
|
+
defaultCurrency: string;
|
|
584
|
+
};
|
|
585
|
+
|
|
586
|
+
declare type ResolvedValueFormatPreferenceSources = {
|
|
587
|
+
locale: ReportPreferenceSource;
|
|
588
|
+
dateStyle: ReportPreferenceSource;
|
|
589
|
+
dateTime: {
|
|
590
|
+
dateStyle: ReportPreferenceSource;
|
|
591
|
+
timeStyle: ReportPreferenceSource;
|
|
592
|
+
};
|
|
593
|
+
defaultCurrency: ReportPreferenceSource;
|
|
594
|
+
};
|
|
595
|
+
|
|
596
|
+
export declare function resolveNumericPresentation(authored: NumericCanonicalFormat, preferences: ResolvedValueFormatPreferences, boundCurrency?: string): NumericCanonicalFormat;
|
|
597
|
+
|
|
486
598
|
/**
|
|
487
599
|
* Date formatting utilities with timezone support
|
|
488
600
|
* IMPORTANT: No React imports allowed in this file
|
|
@@ -513,4 +625,16 @@ export declare type StringCanonicalFormat = {
|
|
|
513
625
|
suffix?: string;
|
|
514
626
|
};
|
|
515
627
|
|
|
628
|
+
export declare function validateCardExportNumericPresentationSnapshot(input: {
|
|
629
|
+
entries: NumericPresentationSnapshotEntry[];
|
|
630
|
+
expectedScope: {
|
|
631
|
+
dashboardId: string;
|
|
632
|
+
cardId: string;
|
|
633
|
+
};
|
|
634
|
+
visibleColumns?: string[];
|
|
635
|
+
useFormattedValues: boolean;
|
|
636
|
+
}): void;
|
|
637
|
+
|
|
638
|
+
declare type WeekStart = 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
639
|
+
|
|
516
640
|
export { }
|
package/dist/types/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../chunks/common-types-C73-Ud1-.js")
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../chunks/common-types-C73-Ud1-.js");require("../value-format-preferences/index.cjs");const E=require("../report-runtime-context/index.cjs"),a={mode:"all"};exports.CALCULATED_FIELD_ENTITY_MARKER=e.CALCULATED_FIELD_ENTITY_MARKER;exports.CONTROL_CARD_DEFAULT_VALUE=e.CONTROL_CARD_DEFAULT_VALUE;exports.DATE_FORMAT_VALUES=e.DATE_FORMAT_VALUES;exports.EMPTY_SELECTION=e.EMPTY_SELECTION;exports.PivotMarkerEnum=e.PivotMarkerEnum;exports.getFieldRuntimeColumnName=e.getFieldRuntimeColumnName;exports.hasCalculatedFieldMarker=e.hasCalculatedFieldMarker;exports.hasCalculatedFormulaInputs=e.hasCalculatedFormulaInputs;exports.isCalculatedDimension=e.isCalculatedDimension;exports.isCalculatedField=e.isCalculatedField;exports.isCalculatedMetric=e.isCalculatedMetric;exports.DEFAULT_CALENDAR_CONTEXT=E.DEFAULT_CALENDAR_CONTEXT;exports.DEFAULT_SEMANTIC_DOMAIN_ACCESS=a;
|
package/dist/types/index.js
CHANGED
|
@@ -1,19 +1,16 @@
|
|
|
1
|
-
import { a as
|
|
2
|
-
|
|
1
|
+
import { a as l, C, D as A, E as t, P as T, g as _, h as i, b as o, i as r, c as D, d as L } from "../chunks/common-types-ClkOI-3O.js";
|
|
2
|
+
import "../value-format-preferences/index.js";
|
|
3
|
+
import { DEFAULT_CALENDAR_CONTEXT as m } from "../report-runtime-context/index.js";
|
|
4
|
+
const e = {
|
|
3
5
|
mode: "all"
|
|
4
|
-
}, e = {
|
|
5
|
-
tz: "UTC",
|
|
6
|
-
weekStart: 1,
|
|
7
|
-
// Monday (ISO standard)
|
|
8
|
-
anchor: "now"
|
|
9
6
|
};
|
|
10
7
|
export {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
8
|
+
l as CALCULATED_FIELD_ENTITY_MARKER,
|
|
9
|
+
C as CONTROL_CARD_DEFAULT_VALUE,
|
|
10
|
+
A as DATE_FORMAT_VALUES,
|
|
11
|
+
m as DEFAULT_CALENDAR_CONTEXT,
|
|
12
|
+
e as DEFAULT_SEMANTIC_DOMAIN_ACCESS,
|
|
13
|
+
t as EMPTY_SELECTION,
|
|
17
14
|
T as PivotMarkerEnum,
|
|
18
15
|
_ as getFieldRuntimeColumnName,
|
|
19
16
|
i as hasCalculatedFieldMarker,
|