@xapp/form-widget 1.77.0 → 1.79.0

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/README.md CHANGED
@@ -1,3 +1,72 @@
1
1
  ## Form Widget
2
2
 
3
- An scheduling widget that supports multi-step form (displays)
3
+ A scheduling widget that supports multi-step forms and displays.
4
+
5
+ ## Features
6
+
7
+ - Multi-step form flows with dynamic display logic
8
+ - Integration with Stentor conversational AI platform
9
+ - Automatic tracking parameter pass-through for analytics
10
+ - Material-UI components with theming support
11
+ - Audio/voice input capabilities
12
+ - Address autocomplete and service area validation
13
+ - Session management and response caching
14
+
15
+ ## Tracking & Analytics
16
+
17
+ The form widget automatically captures and passes marketing attribution parameters to all API requests for analytics filtering.
18
+
19
+ ### Supported Tracking Parameters
20
+
21
+ #### Standard UTM Parameters
22
+ - `utm_source` - Traffic source (e.g., "google", "facebook", "newsletter")
23
+ - `utm_medium` - Marketing medium (e.g., "cpc", "email", "social")
24
+ - `utm_campaign` - Campaign name (e.g., "spring_sale", "product_launch")
25
+ - `utm_term` - Paid keywords (for paid search campaigns)
26
+ - `utm_content` - Ad content identifier (for A/B testing)
27
+
28
+ #### Platform Click IDs
29
+ - `gclid` - Google Click ID (Google Ads auto-tagging)
30
+ - `fbclid` - Facebook Click ID
31
+ - `msclkid` - Microsoft Click ID (Bing Ads)
32
+
33
+ #### Custom Parameters
34
+ - `track_*` - Any parameter with "track_" prefix
35
+
36
+ ### Implementation
37
+
38
+ Tracking parameters are automatically:
39
+ 1. **Extracted** from the page URL when the widget loads
40
+ 2. **Stored** in localStorage with 30-day expiration
41
+ 3. **Included** in all Stentor API requests via the `attributes` field
42
+ 4. **Available** for filtering in OpenSearch analytics
43
+
44
+ ### API Integration
45
+
46
+ All tracking parameters are included in the request attributes sent to the Stentor API:
47
+
48
+ ```javascript
49
+ // Example API request with tracking data
50
+ {
51
+ "sessionId": "stentor-form-session-123",
52
+ "userId": "user-456",
53
+ "attributes": {
54
+ "utm_source": "google",
55
+ "utm_medium": "cpc",
56
+ "utm_campaign": "spring_sale",
57
+ "gclid": "abc123def456",
58
+ "track_landing_page": "homepage"
59
+ },
60
+ // ... other request data
61
+ }
62
+ ```
63
+
64
+ ### Configuration
65
+
66
+ Tracking is enabled by default. The system handles:
67
+ - Parameter extraction and validation
68
+ - Automatic cleanup of expired data
69
+ - Cross-session persistence
70
+ - Error handling for malformed data
71
+
72
+ No additional configuration is required - the widget will automatically capture and pass through any UTM parameters, click IDs, or custom tracking parameters present in the page URL.
@@ -8,6 +8,8 @@ export declare const DefaultBlank: VFC;
8
8
  export declare const Styled: VFC;
9
9
  export declare const AutoOpened: VFC;
10
10
  export declare const WithIframe: FC;
11
+ export declare const WithCustomFont: FC;
12
+ export declare const WithCustomFontAndOverride: FC;
11
13
  export declare function buildDefaultTheme(_opts: {
12
14
  fontFamily?: string;
13
15
  }): FormWidgetTheme;
@@ -2,5 +2,6 @@ import { Meta } from "@storybook/react";
2
2
  declare const _default: Meta;
3
3
  export default _default;
4
4
  export declare const Default: any;
5
+ export declare const DefaultWithConsent: any;
5
6
  export declare const WithFormServiceOptions: any;
6
7
  export declare const WithFormServiceOptionsZipCodeServiceArea: any;
@@ -3,6 +3,7 @@ declare const _default: Meta;
3
3
  export default _default;
4
4
  export declare const Default: any;
5
5
  export declare const Radio: any;
6
+ export declare const RadioWithTitle: any;
6
7
  export declare const WithTitle: any;
7
8
  export declare const WithURL: any;
8
9
  export declare const WithMixedItems: any;
@@ -0,0 +1,9 @@
1
+ import { Meta } from "@storybook/react";
2
+ declare const _default: Meta;
3
+ export default _default;
4
+ export declare const Default: any;
5
+ export declare const WithTitle: any;
6
+ export declare const WithError: any;
7
+ export declare const ManyOptions: any;
8
+ export declare const WithLongLabels: any;
9
+ export declare const RequiredMembership: any;
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  export { Form, FormContainer, FormProps, FormWidget, FormWidgetProps, FormDisplay, WidgetStylesheet, } from "./components";
2
2
  export { FormWidgetConfig, StentorApiConfig } from "./config";
3
- export { FormWidgetCardTheme, FormWidgetCheckboxTheme, FormWidgetChipsTheme, FormWidgetDateTheme, FormWidgetDropdownTheme, FormWidgetTextTheme, } from "@xapp/stentor-form-widget-channel";
3
+ export { FormWidgetCardTheme, FormWidgetCheckboxTheme, FormWidgetChipsTheme, FormWidgetDateTheme, FormWidgetDropdownTheme, FormWidgetFontTheme, FormWidgetTextTheme, } from "@xapp/stentor-form-widget-channel";
4
4
  export { SearchIcon, SpinnerIcon, LeftAngleIcon, RightAngleIcon } from "./components/icons";
5
5
  export { parseWidgetEnv } from "./utils/parseWidgetEnv";
6
6
  export * from "./components/FormDisplay/model";