react-semaphor 0.1.252 → 0.1.253

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 (29) hide show
  1. package/dist/chunks/{dashboard-controls-RKNlZLUy.js → dashboard-controls-BgaOqhnw.js} +1 -1
  2. package/dist/chunks/{dashboard-controls-tzai5JMp.js → dashboard-controls-CHH9Ea4j.js} +36 -36
  3. package/dist/chunks/{dashboard-json-B5wllXw0.js → dashboard-json-Blynp1N2.js} +1 -1
  4. package/dist/chunks/{dashboard-json-ihTGgefO.js → dashboard-json-CJ6i6izi.js} +1 -1
  5. package/dist/chunks/{dashboard-summary-settings-dialog-5tiQcv5v.js → dashboard-summary-settings-dialog-BtpW7fJ0.js} +1 -1
  6. package/dist/chunks/{dashboard-summary-settings-dialog-aTE5vsbO.js → dashboard-summary-settings-dialog-CHhYvPUB.js} +1 -1
  7. package/dist/chunks/{edit-dashboard-visual-DWk1Nj1P.js → edit-dashboard-visual-C22E6KJj.js} +2 -2
  8. package/dist/chunks/{edit-dashboard-visual-BIQd7lCz.js → edit-dashboard-visual-CZvBuYhN.js} +1 -1
  9. package/dist/chunks/{editor-action-buttons-CmELP3na.js → editor-action-buttons-1cbHJIqv.js} +1 -1
  10. package/dist/chunks/{editor-action-buttons-B7ESBjzC.js → editor-action-buttons-DNSIXb3y.js} +2 -2
  11. package/dist/chunks/index-9_GiUNMO.js +1109 -0
  12. package/dist/chunks/{index-BDN1Q9RG.js → index-DsMIsFii.js} +32323 -32077
  13. package/dist/chunks/{notification-bell-CYrG1hcX.js → notification-bell-DXQ2fu8Y.js} +36 -36
  14. package/dist/chunks/{notification-bell-TG-yGjyj.js → notification-bell-DxOIm0IK.js} +1 -1
  15. package/dist/chunks/{resource-management-panel-jsX9tgNz.js → resource-management-panel-D427FGhi.js} +1 -1
  16. package/dist/chunks/{resource-management-panel-CnDTYkf7.js → resource-management-panel-DkW4oYpN.js} +26 -26
  17. package/dist/chunks/{use-visual-utils-H6Nd2HfE.js → use-visual-utils-BqG8Hwpl.js} +1 -1
  18. package/dist/chunks/{use-visual-utils-BNXkYg0F.js → use-visual-utils-CW_sw621.js} +1 -1
  19. package/dist/dashboard/index.cjs +1 -1
  20. package/dist/dashboard/index.js +1 -1
  21. package/dist/index.cjs +1 -1
  22. package/dist/index.js +413 -252
  23. package/dist/style.css +1 -1
  24. package/dist/surfboard/index.cjs +1 -1
  25. package/dist/surfboard/index.js +2 -2
  26. package/dist/types/main.d.ts +249 -48
  27. package/dist/types/types.d.ts +92 -20
  28. package/package.json +1 -1
  29. package/dist/chunks/index-DvjTd3ue.js +0 -1109
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../chunks/index-DvjTd3ue.js"),a=require("../types/index.cjs"),e=require("../chunks/dashboard-summary-settings-dialog-5tiQcv5v.js");exports.Surfboard=r.DashboardPlus;exports.EMPTY_SELECTION=a.EMPTY_SELECTION;exports.CalendarPreferencesDialog=e.CalendarPreferencesDialog;exports.DashboardSummarySettingsDialog=e.DashboardSummarySettingsDialog;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../chunks/index-9_GiUNMO.js"),a=require("../types/index.cjs"),e=require("../chunks/dashboard-summary-settings-dialog-BtpW7fJ0.js");exports.Surfboard=r.DashboardPlus;exports.EMPTY_SELECTION=a.EMPTY_SELECTION;exports.CalendarPreferencesDialog=e.CalendarPreferencesDialog;exports.DashboardSummarySettingsDialog=e.DashboardSummarySettingsDialog;
@@ -1,6 +1,6 @@
1
- import { a as o } from "../chunks/index-BDN1Q9RG.js";
1
+ import { a as o } from "../chunks/index-DsMIsFii.js";
2
2
  import { EMPTY_SELECTION as s } from "../types/index.js";
3
- import { C as m, D as t } from "../chunks/dashboard-summary-settings-dialog-aTE5vsbO.js";
3
+ import { C as m, D as t } from "../chunks/dashboard-summary-settings-dialog-CHhYvPUB.js";
4
4
  export {
5
5
  m as CalendarPreferencesDialog,
6
6
  t as DashboardSummarySettingsDialog,
@@ -1,3 +1,4 @@
1
+ import { ActionDispatch } from 'react';
1
2
  import { Chart as Chart_2 } from 'chart.js';
2
3
  import { ChartConfiguration } from 'chart.js';
3
4
  import { ClassProp } from 'class-variance-authority/types';
@@ -331,12 +332,7 @@ export declare interface Alert {
331
332
  sourceHealth?: 'OK' | 'SOURCE_MISSING' | 'SOURCE_ERROR' | 'STALE';
332
333
  alertState?: AlertState | null;
333
334
  jobConfig: AlertJobConfig;
334
- deliveryConfig: {
335
- recipients: AlertRecipient[];
336
- channels: AlertDeliveryChannel[];
337
- subject?: string;
338
- message?: string;
339
- };
335
+ deliveryConfig: DeliveryConfig;
340
336
  createdAt: string;
341
337
  updatedAt: string;
342
338
  }
@@ -357,8 +353,6 @@ export declare interface AlertBacktestResult {
357
353
 
358
354
  export declare type AlertConditionOperator = 'gt' | 'gte' | 'lt' | 'lte' | 'eq' | 'neq' | 'pct_change_gt' | 'pct_change_lt';
359
355
 
360
- export declare type AlertContextAuthoringMode = 'basic' | 'conversational' | 'manual';
361
-
362
356
  export declare interface AlertContextInterpretResponse {
363
357
  workflowDef: Record<string, unknown>;
364
358
  contextSources: ContextSource[];
@@ -367,28 +361,41 @@ export declare interface AlertContextInterpretResponse {
367
361
 
368
362
  export declare type AlertContextSourceKind = 'trend_window' | 'peer_comparison' | 'related_metric' | 'breakdown' | 'custom_query';
369
363
 
370
- export declare function AlertCreationDialog({ open, onOpenChange, prefilledSource, prefilledSeries, onCreated, contextBuilderEnabled, }: AlertCreationDialogProps): JSX.Element;
371
-
372
- declare type AlertCreationDialogProps = {
373
- open: boolean;
374
- onOpenChange: (open: boolean) => void;
375
- prefilledSource?: AlertSource;
376
- prefilledSeries?: BacktestPoint[];
377
- onCreated?: (alertId: string) => void;
378
- contextBuilderEnabled?: boolean;
379
- };
380
-
381
364
  export declare interface AlertDeliverablePreview {
382
365
  mode: 'standard_fallback' | 'custom';
383
366
  html: string;
384
367
  warnings?: string[];
385
368
  }
386
369
 
387
- export declare type AlertDeliveryChannel = 'EMAIL' | 'WEBHOOK' | 'SLACK' | 'IN_APP';
370
+ export declare type AlertDeliveryChannel = 'EMAIL' | 'WEBHOOK' | 'SLACK' | 'IN_APP' | 'TELEGRAM';
388
371
 
389
- declare type AlertDraft = Partial<CreateAlertRequest> & {
390
- contextSources?: ContextSource[];
391
- presentationPrompt?: string;
372
+ export declare function AlertDetailPageEmbedded({ alertId, onBack }: AlertDetailPageEmbeddedProps): JSX.Element;
373
+
374
+ declare type AlertDetailPageEmbeddedProps = {
375
+ alertId: string;
376
+ onBack?: () => void;
377
+ };
378
+
379
+ declare type AlertDraft = {
380
+ name?: string;
381
+ description?: string | null;
382
+ scheduleExpr?: string;
383
+ timezone?: string;
384
+ workflowDef?: Record<string, unknown> | null;
385
+ jobConfig?: Partial<AlertJobConfig>;
386
+ deliveryConfig?: Partial<DeliveryConfig>;
387
+ };
388
+
389
+ export declare type AlertExecutionFilterContext = {
390
+ active_filters: TFilterValue[];
391
+ };
392
+
393
+ export declare type AlertExecutionQueryConfig = {
394
+ cardType: TChartType;
395
+ cardMode: CardMode;
396
+ cardConfig: CardConfig;
397
+ cardDataSource: DataSource;
398
+ connectionId?: string;
392
399
  };
393
400
 
394
401
  declare type AlertFilters = {
@@ -434,16 +441,19 @@ export declare type AlertJobConfig = {
434
441
  severity: AlertSeverity;
435
442
  consecutiveCount?: number;
436
443
  notifyPolicy: 'on_state_change';
437
- contextAuthoringMode?: AlertContextAuthoringMode;
438
444
  contextSources?: ContextSource[];
439
445
  presentationPrompt?: string;
446
+ sensitivityPreset?: SensitivityPreset | null;
440
447
  };
441
448
 
442
- export declare function AlertManagementPage({ scope, prefilledSource, }: AlertManagementPageProps): JSX.Element;
449
+ export declare function AlertManagementPage({ scope, prefilledSource, allowCreateSignalWatch, onOpenAlertDetail, onCreateSignalWatch, }: AlertManagementPageProps): JSX.Element;
443
450
 
444
451
  declare type AlertManagementPageProps = {
445
452
  scope?: AlertManagementScope;
446
453
  prefilledSource?: AlertSource;
454
+ allowCreateSignalWatch?: boolean;
455
+ onOpenAlertDetail?: (alert: Alert) => void;
456
+ onCreateSignalWatch?: () => void;
447
457
  };
448
458
 
449
459
  declare type AlertManagementScope = {
@@ -499,18 +509,19 @@ export declare type AlertSeverity = 'LOW' | 'MEDIUM' | 'HIGH' | 'CRITICAL';
499
509
 
500
510
  export declare type AlertSource = {
501
511
  type: 'saved_metric';
502
- metricId: string;
512
+ visualId: string;
503
513
  title?: string;
514
+ format?: CanonicalFormatSpec;
504
515
  } | {
505
516
  type: 'dashboard_metric';
506
517
  dashboardId: string;
507
518
  visualId: string;
508
519
  cardId: string;
509
520
  title?: string;
521
+ format?: CanonicalFormatSpec;
510
522
  executionSnapshot: {
511
- queryConfig: Record<string, unknown>;
512
- filterContext: Record<string, unknown>;
513
- formattingContext: Record<string, unknown>;
523
+ queryConfig: AlertExecutionQueryConfig;
524
+ filterContext: AlertExecutionFilterContext;
514
525
  connectionId: string;
515
526
  calendarContext?: {
516
527
  tz: string;
@@ -559,6 +570,14 @@ declare type AlertStoreState = {
559
570
  draft: AlertDraft;
560
571
  };
561
572
 
573
+ export declare function AlertWizardDialog({ open, onOpenChange, cardSnapshot, }: AlertWizardDialogProps): JSX.Element;
574
+
575
+ declare interface AlertWizardDialogProps {
576
+ open: boolean;
577
+ onOpenChange: (open: boolean) => void;
578
+ cardSnapshot: CardSnapshot | null;
579
+ }
580
+
562
581
  export declare type AssistantId = 'dashboard-assistant' | 'editor-assistant';
563
582
 
564
583
  export declare type AuthToken = {
@@ -607,11 +626,6 @@ export declare type AxisConfig = {
607
626
 
608
627
  export declare function backtestAlert(apiServiceUrl: string, token: string, id: string | undefined, payload?: Record<string, unknown>): Promise<AlertBacktestResult>;
609
628
 
610
- declare type BacktestPoint = {
611
- at: string;
612
- value: number;
613
- };
614
-
615
629
  export declare interface BaseColumn {
616
630
  id: string;
617
631
  name: string;
@@ -765,6 +779,8 @@ declare interface CalendarPreferencesDialogProps {
765
779
  */
766
780
  export declare function cancelExport(apiServiceUrl: string, token: string, exportId: string): Promise<void>;
767
781
 
782
+ export declare type CanonicalFormatSpec = NumericCanonicalFormat | DateCanonicalFormat | StringCanonicalFormat;
783
+
768
784
  export declare function CardAlertIndicator({ cardId }: CardAlertIndicatorProps): JSX.Element | null;
769
785
 
770
786
  declare type CardAlertIndicatorProps = {
@@ -840,6 +856,18 @@ export declare interface CardInteractionConfig {
840
856
 
841
857
  export declare type CardMode = 'explorer' | 'dev';
842
858
 
859
+ export declare interface CardSnapshot {
860
+ dashboardId: string;
861
+ visualId: string;
862
+ cardId: string;
863
+ title?: string;
864
+ currentValue?: number | null;
865
+ format?: AlertSource['format'];
866
+ executionSnapshot?: Extract<AlertSource, {
867
+ type: 'dashboard_metric';
868
+ }>['executionSnapshot'];
869
+ }
870
+
843
871
  export declare function CardSummary({ card, mode }: CardSummaryProps): JSX.Element | null;
844
872
 
845
873
  declare type CardSummaryProps = {
@@ -867,6 +895,34 @@ declare type CardWithFooter = BaseCustomCard & {
867
895
  }>;
868
896
  };
869
897
 
898
+ export declare type ChannelFormatConfig = {
899
+ formatProfile: FormatProfile;
900
+ subjectOverride?: string;
901
+ titleOverride?: string;
902
+ summaryOverride?: string;
903
+ actionBlockVisible?: boolean;
904
+ webhookConfig?: {
905
+ url: string;
906
+ method: string;
907
+ headers: Record<string, string>;
908
+ secretEncrypted?: string;
909
+ };
910
+ };
911
+
912
+ declare type ChannelFormatConfig_2 = {
913
+ formatProfile: FormatProfile_2;
914
+ subjectOverride?: string;
915
+ titleOverride?: string;
916
+ summaryOverride?: string;
917
+ actionBlockVisible?: boolean;
918
+ webhookConfig?: {
919
+ url: string;
920
+ method: string;
921
+ headers: Record<string, string>;
922
+ secretEncrypted?: string;
923
+ };
924
+ };
925
+
870
926
  export declare interface ClickedMetricValue {
871
927
  field: Field;
872
928
  value: number;
@@ -1068,16 +1124,17 @@ export declare interface CreateAlertRequest {
1068
1124
  description?: string;
1069
1125
  scheduleExpr: string;
1070
1126
  timezone?: string;
1071
- source: AlertSource;
1072
- operator: AlertConditionOperator;
1073
- threshold: number;
1127
+ source?: AlertSource;
1128
+ operator?: AlertConditionOperator;
1129
+ threshold?: number;
1074
1130
  severity?: AlertSeverity;
1075
1131
  consecutiveCount?: number;
1076
- recipients: AlertRecipient[];
1132
+ recipients?: AlertRecipient[];
1077
1133
  channels?: AlertDeliveryChannel[];
1078
- contextAuthoringMode?: AlertContextAuthoringMode;
1079
1134
  contextSources?: ContextSource[];
1080
1135
  presentationPrompt?: string;
1136
+ jobConfig?: AlertJobConfig;
1137
+ deliveryConfig?: DeliveryConfig;
1081
1138
  workflowDef?: Record<string, unknown>;
1082
1139
  }
1083
1140
 
@@ -1325,6 +1382,17 @@ export declare type DataType = 'string' | 'number' | 'date' | 'datetime' | 'bool
1325
1382
 
1326
1383
  export declare const DATE_FORMAT_VALUES: readonly ["MM-DD-YYYY", "YYYY-MM-DD", "MM/DD/YYYY", "DD/MM/YYYY", "MMMM DD, YYYY", "MMM DD, YYYY", "DD MMM YYYY", "YYYY-MM-DD HH:mm", "YYYY-MM-DD HH:mm:ss", "YYYY-MM-DD HH:mm Z", "YYYY-MM-DD HH:mm:ss Z", "Week of MMM DD, YYYY", "Week of MMMM DD, YYYY", "YYYY-WW", "MMM YYYY", "MMMM YYYY", "YYYY-MM", "MM/YYYY", "YYYY MMM", "Q1 YYYY", "YYYY Q1", "1st Quarter YYYY", "YYYY-Q1", "Quarter 1, YYYY", "YYYY", "YY", "custom"];
1327
1384
 
1385
+ declare type DateCanonicalFormat = {
1386
+ type: 'date';
1387
+ locale?: string;
1388
+ pattern?: string;
1389
+ relative?: boolean;
1390
+ timezone?: string;
1391
+ sourceTimezone?: string;
1392
+ prefix?: string;
1393
+ suffix?: string;
1394
+ };
1395
+
1328
1396
  declare type DateComparisonOperation = '=' | '!=' | '>' | '>=' | '<' | '<=' | 'between' | 'not between' | 'is null' | 'is not null';
1329
1397
 
1330
1398
  export declare type DateFormatOption = {
@@ -1360,6 +1428,16 @@ export declare function deleteAlert(apiServiceUrl: string, token: string, id: st
1360
1428
  success: boolean;
1361
1429
  }>;
1362
1430
 
1431
+ declare type DeliveryChannel = 'EMAIL' | 'WEBHOOK' | 'SLACK' | 'IN_APP' | 'TELEGRAM';
1432
+
1433
+ export declare type DeliveryConfig = {
1434
+ recipients: AlertRecipient[];
1435
+ channels: AlertDeliveryChannel[];
1436
+ subject?: string;
1437
+ message?: string;
1438
+ channelConfigs?: Record<string, ChannelFormatConfig>;
1439
+ };
1440
+
1363
1441
  /**
1364
1442
  * Field configuration for detail table columns.
1365
1443
  * Unlike GroupByField, DetailField does not support aggregation or granularity.
@@ -1433,6 +1511,24 @@ export declare interface DomainCalculatedMetric {
1433
1511
 
1434
1512
  export declare function downloadPdf(apiServiceUrl: string, authToken: AuthToken | undefined, password?: string, sheetSelection?: 'current' | 'all', expandedState?: Record<string, boolean>): Promise<void>;
1435
1513
 
1514
+ declare type DraftDeliveryConfig = {
1515
+ channels: DeliveryChannel[];
1516
+ channelConfigs?: Record<string, ChannelFormatConfig_2>;
1517
+ recipients?: Array<{
1518
+ type: string;
1519
+ [key: string]: unknown;
1520
+ }>;
1521
+ };
1522
+
1523
+ declare type DraftJobConfig = {
1524
+ source?: AlertSource;
1525
+ operator?: AlertConditionOperator;
1526
+ threshold?: number;
1527
+ severity?: AlertSeverity;
1528
+ consecutiveCount?: number;
1529
+ sensitivityPreset?: SensitivityPreset_2 | null;
1530
+ };
1531
+
1436
1532
  declare interface DrillActions {
1437
1533
  updateDrillHierarchies: (h: DrillHierarchy[]) => void;
1438
1534
  addDrillHierarchy: (h: DrillHierarchy) => void;
@@ -1673,6 +1769,15 @@ export declare interface DrillUpInteraction {
1673
1769
  label?: string;
1674
1770
  }
1675
1771
 
1772
+ declare type DriverCandidate = {
1773
+ id: string;
1774
+ label: string;
1775
+ sourceKind: 'same_dashboard' | 'same_connection' | 'same_project';
1776
+ provenance: string;
1777
+ metricType: string;
1778
+ referenceId: string;
1779
+ };
1780
+
1676
1781
  export declare type DropdownItem = {
1677
1782
  id: string;
1678
1783
  name: string;
@@ -2153,6 +2258,10 @@ export declare function fmt(str: string): string;
2153
2258
  */
2154
2259
  export declare function formatFileSize(bytes?: number): string;
2155
2260
 
2261
+ export declare type FormatProfile = 'concise' | 'balanced' | 'detailed';
2262
+
2263
+ declare type FormatProfile_2 = 'concise' | 'balanced' | 'detailed';
2264
+
2156
2265
  export declare type FormatSpec = {
2157
2266
  type: 'number' | 'currency' | 'percent' | 'percentage' | 'scientific';
2158
2267
  locale?: string;
@@ -2446,11 +2555,6 @@ export declare interface InteractionTrigger {
2446
2555
  field: Field;
2447
2556
  }
2448
2557
 
2449
- export declare function interpretAlertContext(apiServiceUrl: string, token: string, payload: {
2450
- intent: string;
2451
- ruleId?: string;
2452
- }): Promise<AlertContextInterpretResponse>;
2453
-
2454
2558
  export declare function invalidateToken(apiServiceUrl: string): Promise<any>;
2455
2559
 
2456
2560
  export declare function isBooleanDataType(dataType: string): boolean;
@@ -2694,6 +2798,21 @@ export declare type NumberOptions = {
2694
2798
  colorRanges?: ColorRange[];
2695
2799
  };
2696
2800
 
2801
+ declare type NumericCanonicalFormat = {
2802
+ type: 'number' | 'currency' | 'percent' | 'scientific';
2803
+ locale?: string;
2804
+ minimumFractionDigits?: number;
2805
+ maximumFractionDigits?: number;
2806
+ useGrouping?: boolean;
2807
+ prefix?: string;
2808
+ suffix?: string;
2809
+ negativeStyle?: 'minus' | 'parentheses';
2810
+ compact?: boolean;
2811
+ scale?: number;
2812
+ currency?: string;
2813
+ percentValueMode?: 'fraction' | 'whole';
2814
+ };
2815
+
2697
2816
  export declare type OldFilterValue = string | number | null | (string | number)[] | RangeValue;
2698
2817
 
2699
2818
  declare type Operation = '=' | '>' | '<' | '>=' | '<=' | '!=' | 'in' | 'not in' | 'like' | 'not like' | 'between' | 'not between' | 'is null' | 'is not null';
@@ -2981,6 +3100,10 @@ declare function SemaphorQueryClient({ children, }: {
2981
3100
  export { SemaphorQueryClient as SemaphorDataProvider }
2982
3101
  export { SemaphorQueryClient }
2983
3102
 
3103
+ export declare type SensitivityPreset = 'low_noise' | 'standard' | 'early_warning';
3104
+
3105
+ declare type SensitivityPreset_2 = 'low_noise' | 'standard' | 'early_warning';
3106
+
2984
3107
  /**
2985
3108
  * Stable serializer for dashboard dirty checks.
2986
3109
  * This consolidates normalization + serialization into one call site, so
@@ -3027,6 +3150,12 @@ export declare type SqlGen = {
3027
3150
 
3028
3151
  declare type StateSerializer<T> = (value: T) => string;
3029
3152
 
3153
+ declare type StringCanonicalFormat = {
3154
+ type: 'string';
3155
+ prefix?: string;
3156
+ suffix?: string;
3157
+ };
3158
+
3030
3159
  declare type StringOptions = {
3031
3160
  maxLength?: number;
3032
3161
  };
@@ -3508,7 +3637,7 @@ export declare type TChartOptions = {
3508
3637
  treemapColorMode?: 'branch' | 'category';
3509
3638
  };
3510
3639
 
3511
- declare type TChartType = 'bar' | 'horizontalBar' | 'line' | 'area' | 'stackedArea' | 'combo' | 'pie' | 'doughnut' | 'radar' | 'polarArea' | 'bubble' | 'scatter' | 'stackedBar' | 'stackedLine' | 'table' | 'pivotTable' | 'aggregateTable' | 'detailTable' | 'tableBuilder' | 'kpi' | 'pyramid' | 'tornado' | 'range' | 'text' | 'map' | 'funnel' | 'bullet' | 'heatmap' | 'treemap' | 'custom';
3640
+ export declare type TChartType = 'bar' | 'horizontalBar' | 'line' | 'area' | 'stackedArea' | 'combo' | 'pie' | 'doughnut' | 'radar' | 'polarArea' | 'bubble' | 'scatter' | 'stackedBar' | 'stackedLine' | 'table' | 'pivotTable' | 'aggregateTable' | 'detailTable' | 'tableBuilder' | 'kpi' | 'pyramid' | 'tornado' | 'range' | 'text' | 'map' | 'funnel' | 'bullet' | 'heatmap' | 'treemap' | 'custom';
3512
3641
 
3513
3642
  export declare type TColumnSetting<T extends DisplayDataType> = {
3514
3643
  columnIdx: number;
@@ -4193,9 +4322,12 @@ export declare interface UpdateAlertRequest {
4193
4322
  consecutiveCount?: number;
4194
4323
  recipients?: AlertRecipient[];
4195
4324
  channels?: AlertDeliveryChannel[];
4196
- contextAuthoringMode?: AlertContextAuthoringMode;
4197
4325
  contextSources?: ContextSource[];
4198
4326
  presentationPrompt?: string;
4327
+ sensitivityPreset?: SensitivityPreset | null;
4328
+ channelConfigs?: Record<string, ChannelFormatConfig>;
4329
+ jobConfig?: AlertJobConfig;
4330
+ deliveryConfig?: DeliveryConfig;
4199
4331
  workflowDef?: Record<string, unknown> | null;
4200
4332
  }
4201
4333
 
@@ -4255,8 +4387,6 @@ export declare const useAlertActions: () => AlertStoreActions;
4255
4387
 
4256
4388
  export declare function useAlertBacktest(alertId?: string): UseMutationResult<AlertBacktestResult, Error, Record<string, unknown> | undefined, unknown>;
4257
4389
 
4258
- export declare function useAlertContextBuilder(ruleId?: string): UseMutationResult<AlertContextInterpretResponse, Error, string, unknown>;
4259
-
4260
4390
  export declare function useAlertDeliveries(alertId: string | undefined, runId: string | undefined): UseQueryResult< {
4261
4391
  attempts: Array<Record<string, unknown>>;
4262
4392
  }, Error>;
@@ -4669,6 +4799,19 @@ setState(nextStateOrUpdater: AlertStore | Partial<AlertStore> | ((state: Writabl
4669
4799
  setState(nextStateOrUpdater: AlertStore | ((state: WritableDraft<AlertStore>) => void), shouldReplace: true): void;
4670
4800
  }>;
4671
4801
 
4802
+ export declare function useAlertWizard({ cardSnapshot }: {
4803
+ cardSnapshot: CardSnapshot | null;
4804
+ }): {
4805
+ state: WizardState;
4806
+ dispatch: ActionDispatch<[action: WizardAction]>;
4807
+ nextStep: () => void;
4808
+ prevStep: () => void;
4809
+ toggleDriver: (id: string) => void;
4810
+ updateJobConfig: (config: Partial<DraftJobConfig>) => void;
4811
+ updateDeliveryConfig: (config: Partial<DraftDeliveryConfig>) => void;
4812
+ setSensitivity: (preset: SensitivityPreset_2) => void;
4813
+ };
4814
+
4672
4815
  export declare function useCard(cardId: string): {
4673
4816
  data: any;
4674
4817
  card: TCard;
@@ -5087,4 +5230,62 @@ export declare interface WindowTransform {
5087
5230
  };
5088
5231
  }
5089
5232
 
5233
+ declare type WizardAction = {
5234
+ type: 'START_PREFILL';
5235
+ } | {
5236
+ type: 'RESET_PREFILL';
5237
+ } | {
5238
+ type: 'SET_PREFILL';
5239
+ payload: WizardPrefillResponse;
5240
+ } | {
5241
+ type: 'SET_PREFILL_ERROR';
5242
+ error: string;
5243
+ } | {
5244
+ type: 'NEXT_STEP';
5245
+ } | {
5246
+ type: 'PREV_STEP';
5247
+ } | {
5248
+ type: 'SET_SENSITIVITY';
5249
+ payload: SensitivityPreset_2;
5250
+ } | {
5251
+ type: 'TOGGLE_DRIVER';
5252
+ driverId: string;
5253
+ } | {
5254
+ type: 'UPDATE_JOB_CONFIG';
5255
+ payload: Partial<DraftJobConfig>;
5256
+ } | {
5257
+ type: 'UPDATE_DELIVERY_CONFIG';
5258
+ payload: Partial<DraftDeliveryConfig>;
5259
+ };
5260
+
5261
+ declare type WizardPrefillResponse = {
5262
+ source: AlertSource;
5263
+ metricLabel: string;
5264
+ currentValue: number | null;
5265
+ snapshotAge: {
5266
+ capturedAt: string;
5267
+ ageMinutes: number;
5268
+ isStale: boolean;
5269
+ };
5270
+ suggestedName: string;
5271
+ connectionName: string | null;
5272
+ dashboardName: string | null;
5273
+ calendarContext: {
5274
+ tz: string;
5275
+ weekStart: number;
5276
+ } | null;
5277
+ driverCandidates: DriverCandidate[];
5278
+ snapshotWarning?: 'missing' | 'invalid' | 'stale';
5279
+ };
5280
+
5281
+ declare type WizardState = {
5282
+ step: 1 | 2 | 3;
5283
+ prefillData: WizardPrefillResponse | null;
5284
+ prefillLoading: boolean;
5285
+ prefillError: string | null;
5286
+ draftJobConfig: DraftJobConfig;
5287
+ draftDeliveryConfig: DraftDeliveryConfig;
5288
+ selectedDrivers: string[];
5289
+ };
5290
+
5090
5291
  export { }