@frigade/react 1.32.76 → 1.32.78

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/lib/index.d.ts CHANGED
@@ -117,6 +117,9 @@ interface DefaultFrigadeFlowProps {
117
117
  style?: CSSProperties;
118
118
  className?: string;
119
119
  appearance?: Appearance;
120
+ /**
121
+ * Dynamic variables to use in flow-data.yml. See https://docs.frigade.com/flows/dynamic-variables
122
+ */
120
123
  customVariables?: {
121
124
  [key: string]: string | number | boolean;
122
125
  };
@@ -280,29 +283,32 @@ interface FrigadeConfig {
280
283
  }
281
284
  declare const FrigadeProvider: FC<FrigadeProviderProps>;
282
285
 
283
- type FrigadeChecklistType = 'inline' | 'modal';
284
- type FrigadeChecklistStyle = 'with-guide' | 'default' | 'condensed' | 'carousel';
285
286
  interface FrigadeChecklistProps extends HeroChecklistProps {
286
287
  flowId: string;
287
288
  title?: string;
288
289
  subtitle?: string;
289
- onCompleteStep?: (index: number, stepData: StepData) => void;
290
290
  style?: CSSProperties;
291
+ /** @ignore */
291
292
  initialSelectedStep?: number;
292
293
  className?: string;
293
- type?: FrigadeChecklistType;
294
- checklistStyle?: FrigadeChecklistStyle;
294
+ type?: 'inline' | 'modal';
295
+ checklistStyle?: 'with-guide' | 'default' | 'condensed' | 'carousel';
295
296
  visible?: boolean;
296
297
  setVisible?: (visible: boolean) => void;
297
298
  onDismiss?: () => void;
299
+ /**
300
+ * See https://docs.frigade.com/flows/dynamic-variables
301
+ */
298
302
  customVariables?: {
299
303
  [key: string]: string | number | boolean;
300
304
  };
301
305
  /**
302
- * Optional Props specifically for ChecklistWithGuide
303
- *
306
+ * Flow ID referencing the flow of a guide/link collection to attach to this Checklist
304
307
  */
305
308
  guideFlowId?: string;
309
+ /**
310
+ * Title for the guide (if attached)
311
+ */
306
312
  guideTitle?: string;
307
313
  autoExpandFirstIncompleteStep?: boolean;
308
314
  autoExpandNextStep?: boolean;
@@ -314,15 +320,18 @@ interface HeroChecklistProps extends Omit<DefaultFrigadeFlowProps, 'flowId'> {
314
320
  subtitle?: string;
315
321
  /**
316
322
  * @deprecated Use `appearance` instead
323
+ * @ignore
317
324
  */
318
325
  primaryColor?: string;
326
+ /** @ignore */
319
327
  steps?: StepData[];
320
- /**
321
- * @deprecated use onStepCompletion instead
322
- */
323
- onCompleteStep?: (index: number, stepData: StepData) => void;
328
+ /** @ignore */
324
329
  selectedStep?: number;
330
+ /** @ignore */
325
331
  setSelectedStep?: (index: number) => void;
332
+ /**
333
+ * Map from string to function with StepData returning React.ReactNode
334
+ */
326
335
  customStepTypes?: Record<string, (stepData: StepData, appearance: Appearance) => React__default.ReactNode>;
327
336
  }
328
337
 
@@ -442,28 +451,50 @@ interface ToolTipData extends StepData {
442
451
  titleStyle?: CSSProperties;
443
452
  buttonStyle?: CSSProperties;
444
453
  }
445
- interface ToolTipProps extends Omit<DefaultFrigadeFlowProps, 'flowId'> {
454
+
455
+ interface FrigadeTourProps extends Omit<DefaultFrigadeFlowProps, 'flowId'> {
456
+ /**
457
+ * @ignore
458
+ */
446
459
  steps?: ToolTipData[];
447
460
  onDismiss?: () => void;
448
461
  onComplete?: () => void;
449
462
  tooltipPosition?: ToolTipPosition;
463
+ /**
464
+ * Whether to show the highlight (the small circle/ping) or not. Defaults to true.
465
+ */
450
466
  showHighlight?: boolean;
467
+ /**
468
+ * Whether to show more than one tooltip at a time. Defaults to false.
469
+ */
451
470
  showTooltipsSimultaneously?: boolean;
471
+ /**
472
+ * @ignore
473
+ */
452
474
  buttonStyle?: CSSProperties;
475
+ /**
476
+ * Offset to apply to all tooltips.
477
+ */
453
478
  offset?: {
454
479
  x: number;
455
480
  y: number;
456
481
  };
457
482
  visible?: boolean;
483
+ /**
484
+ * @ignore
485
+ */
458
486
  containerStyle?: CSSProperties;
459
487
  customVariables?: {
460
488
  [key: string]: string | number | boolean;
461
489
  };
490
+ /**
491
+ * @ignore
492
+ */
462
493
  selectedStep?: number;
463
494
  customStepTypes?: Record<string, (stepData: StepData) => React__default.ReactNode>;
464
495
  appearance?: Appearance;
465
496
  /**
466
- * Shows a close button in the top right corner of the tooltip. This will end the flow.
497
+ * Shows a close button in the top right corner of the tooltip. Depending on dismissBehavior, it will either end the entire flow or just the current step.
467
498
  */
468
499
  dismissible?: boolean;
469
500
  primaryColor?: string;
@@ -477,14 +508,16 @@ interface ToolTipProps extends Omit<DefaultFrigadeFlowProps, 'flowId'> {
477
508
  */
478
509
  showStepCount?: boolean;
479
510
  /**
480
- * 'complete-flow' (default): Completes the entire flow/tour when a single tooltip is dismissed.
481
- * 'complete-step': Completes the current step when a tooltip is dismissed.
511
+ * `complete-flow` (default): Completes the entire flow/tour when a single tooltip is dismissed.
512
+ * `complete-step`: Completes the current step when a tooltip is dismissed.
482
513
  */
483
514
  dismissBehavior?: 'complete-flow' | 'complete-step';
515
+ /**
516
+ * @ignore
517
+ */
484
518
  showFrigadeBranding?: boolean;
485
519
  }
486
-
487
- declare const FrigadeTour: FC<ToolTipProps & {
520
+ declare const FrigadeTour: FC<FrigadeTourProps & {
488
521
  flowId: string;
489
522
  initialSelectedStep?: number;
490
523
  }>;