@habit.analytics/habit-claims-journey-components 2.3.1 → 2.3.3

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.
@@ -4,9 +4,19 @@ interface WidgetRendererProps {
4
4
  value: unknown;
5
5
  onChange: (value: unknown) => void;
6
6
  onValidationChange?: (hasError: boolean) => void;
7
- onFileSelect?: (file: File) => Promise<string | UploadResult | void> | void;
7
+ /**
8
+ * File upload callback. If provided, `questionKey` must also be provided.
9
+ * The callback receives `(file, questionKey)` from the host app.
10
+ * This prop is memoized internally so `UploadWidget` doesn't re-render
11
+ * when the host passes a new reference.
12
+ */
13
+ onFileSelect?: (file: File, questionKey: string) => Promise<string | UploadResult | void> | void;
14
+ /**
15
+ * The question key associated with `onFileSelect`. Required when `onFileSelect` is provided.
16
+ */
17
+ questionKey?: string;
8
18
  googleMapsApiKey?: string;
9
19
  hideLabel?: boolean;
10
20
  }
11
- export declare function WidgetRenderer({ nodeData, value, onChange, onValidationChange, onFileSelect, googleMapsApiKey, hideLabel }: WidgetRendererProps): import("react/jsx-runtime").JSX.Element;
21
+ export declare function WidgetRenderer({ nodeData, value, onChange, onValidationChange, onFileSelect, questionKey, googleMapsApiKey, hideLabel }: WidgetRendererProps): import("react/jsx-runtime").JSX.Element;
12
22
  export {};