@aranova/tracking-react 0.5.1 → 0.6.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 +114 -0
- package/dist/index.d.mts +47 -43
- package/dist/index.d.ts +47 -43
- package/dist/index.js +26 -16
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +26 -16
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -2
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
+
import * as src from 'src';
|
|
3
4
|
import { z } from 'zod';
|
|
4
5
|
|
|
5
6
|
declare function ConsentBanner(): react_jsx_runtime.JSX.Element | null;
|
|
@@ -109,7 +110,7 @@ declare const ctaClickMetadataSchema: z.ZodObject<{
|
|
|
109
110
|
cta_name: z.ZodString;
|
|
110
111
|
page: z.ZodObject<{
|
|
111
112
|
path: z.ZodString;
|
|
112
|
-
}, "
|
|
113
|
+
}, "strict", z.ZodTypeAny, {
|
|
113
114
|
path: string;
|
|
114
115
|
}, {
|
|
115
116
|
path: string;
|
|
@@ -177,7 +178,7 @@ declare const formStartMetadataSchema: z.ZodObject<{
|
|
|
177
178
|
form: z.ZodObject<{
|
|
178
179
|
id: z.ZodString;
|
|
179
180
|
action: z.ZodNullable<z.ZodString>;
|
|
180
|
-
}, "
|
|
181
|
+
}, "strict", z.ZodTypeAny, {
|
|
181
182
|
id: string;
|
|
182
183
|
action: string | null;
|
|
183
184
|
}, {
|
|
@@ -186,7 +187,7 @@ declare const formStartMetadataSchema: z.ZodObject<{
|
|
|
186
187
|
}>;
|
|
187
188
|
page: z.ZodObject<{
|
|
188
189
|
path: z.ZodString;
|
|
189
|
-
}, "
|
|
190
|
+
}, "strict", z.ZodTypeAny, {
|
|
190
191
|
path: string;
|
|
191
192
|
}, {
|
|
192
193
|
path: string;
|
|
@@ -218,6 +219,9 @@ declare const formStartConfigSchema: z.ZodObject<{
|
|
|
218
219
|
}>;
|
|
219
220
|
type FormStartConfig = z.infer<typeof formStartConfigSchema>;
|
|
220
221
|
|
|
222
|
+
type JsonValue = string | number | boolean | null | JsonValue[] | {
|
|
223
|
+
[key: string]: JsonValue;
|
|
224
|
+
};
|
|
221
225
|
declare const formSubmitMetadataSchema: z.ZodObject<{
|
|
222
226
|
form: z.ZodObject<{
|
|
223
227
|
id: z.ZodString;
|
|
@@ -226,40 +230,40 @@ declare const formSubmitMetadataSchema: z.ZodObject<{
|
|
|
226
230
|
name: z.ZodString;
|
|
227
231
|
type: z.ZodString;
|
|
228
232
|
label: z.ZodNullable<z.ZodString>;
|
|
229
|
-
|
|
230
|
-
}, "
|
|
233
|
+
value: z.ZodType<JsonValue, z.ZodTypeDef, JsonValue>;
|
|
234
|
+
}, "strict", z.ZodTypeAny, {
|
|
231
235
|
label: string | null;
|
|
236
|
+
value: JsonValue;
|
|
232
237
|
type: string;
|
|
233
238
|
name: string;
|
|
234
|
-
has_value: boolean;
|
|
235
239
|
}, {
|
|
236
240
|
label: string | null;
|
|
241
|
+
value: JsonValue;
|
|
237
242
|
type: string;
|
|
238
243
|
name: string;
|
|
239
|
-
has_value: boolean;
|
|
240
244
|
}>, "many">>;
|
|
241
|
-
}, "
|
|
245
|
+
}, "strict", z.ZodTypeAny, {
|
|
242
246
|
id: string;
|
|
243
247
|
action: string | null;
|
|
244
248
|
fields?: {
|
|
245
249
|
label: string | null;
|
|
250
|
+
value: JsonValue;
|
|
246
251
|
type: string;
|
|
247
252
|
name: string;
|
|
248
|
-
has_value: boolean;
|
|
249
253
|
}[] | undefined;
|
|
250
254
|
}, {
|
|
251
255
|
id: string;
|
|
252
256
|
action: string | null;
|
|
253
257
|
fields?: {
|
|
254
258
|
label: string | null;
|
|
259
|
+
value: JsonValue;
|
|
255
260
|
type: string;
|
|
256
261
|
name: string;
|
|
257
|
-
has_value: boolean;
|
|
258
262
|
}[] | undefined;
|
|
259
263
|
}>;
|
|
260
264
|
page: z.ZodObject<{
|
|
261
265
|
path: z.ZodString;
|
|
262
|
-
}, "
|
|
266
|
+
}, "strict", z.ZodTypeAny, {
|
|
263
267
|
path: string;
|
|
264
268
|
}, {
|
|
265
269
|
path: string;
|
|
@@ -270,9 +274,9 @@ declare const formSubmitMetadataSchema: z.ZodObject<{
|
|
|
270
274
|
action: string | null;
|
|
271
275
|
fields?: {
|
|
272
276
|
label: string | null;
|
|
277
|
+
value: JsonValue;
|
|
273
278
|
type: string;
|
|
274
279
|
name: string;
|
|
275
|
-
has_value: boolean;
|
|
276
280
|
}[] | undefined;
|
|
277
281
|
};
|
|
278
282
|
page: {
|
|
@@ -284,9 +288,9 @@ declare const formSubmitMetadataSchema: z.ZodObject<{
|
|
|
284
288
|
action: string | null;
|
|
285
289
|
fields?: {
|
|
286
290
|
label: string | null;
|
|
291
|
+
value: JsonValue;
|
|
287
292
|
type: string;
|
|
288
293
|
name: string;
|
|
289
|
-
has_value: boolean;
|
|
290
294
|
}[] | undefined;
|
|
291
295
|
};
|
|
292
296
|
page: {
|
|
@@ -301,7 +305,7 @@ declare const multiPageSessionMetadataSchema: z.ZodObject<{
|
|
|
301
305
|
page_count: z.ZodNumber;
|
|
302
306
|
page: z.ZodObject<{
|
|
303
307
|
path: z.ZodString;
|
|
304
|
-
}, "
|
|
308
|
+
}, "strict", z.ZodTypeAny, {
|
|
305
309
|
path: string;
|
|
306
310
|
}, {
|
|
307
311
|
path: string;
|
|
@@ -333,7 +337,7 @@ declare const pageViewMetadataSchema: z.ZodObject<{
|
|
|
333
337
|
path: z.ZodString;
|
|
334
338
|
search: z.ZodString;
|
|
335
339
|
hash: z.ZodString;
|
|
336
|
-
}, "
|
|
340
|
+
}, "strict", z.ZodTypeAny, {
|
|
337
341
|
search: string;
|
|
338
342
|
title: string | null;
|
|
339
343
|
path: string;
|
|
@@ -348,7 +352,7 @@ declare const pageViewMetadataSchema: z.ZodObject<{
|
|
|
348
352
|
viewport: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
349
353
|
w: z.ZodNumber;
|
|
350
354
|
h: z.ZodNumber;
|
|
351
|
-
}, "
|
|
355
|
+
}, "strict", z.ZodTypeAny, {
|
|
352
356
|
w: number;
|
|
353
357
|
h: number;
|
|
354
358
|
}, {
|
|
@@ -388,7 +392,7 @@ declare const phoneClickMetadataSchema: z.ZodObject<{
|
|
|
388
392
|
phone_number: z.ZodString;
|
|
389
393
|
page: z.ZodObject<{
|
|
390
394
|
path: z.ZodString;
|
|
391
|
-
}, "
|
|
395
|
+
}, "strict", z.ZodTypeAny, {
|
|
392
396
|
path: string;
|
|
393
397
|
}, {
|
|
394
398
|
path: string;
|
|
@@ -415,7 +419,7 @@ declare const scrollDepthMetadataSchema: z.ZodObject<{
|
|
|
415
419
|
depth_percent: z.ZodNumber;
|
|
416
420
|
page: z.ZodObject<{
|
|
417
421
|
path: z.ZodString;
|
|
418
|
-
}, "
|
|
422
|
+
}, "strict", z.ZodTypeAny, {
|
|
419
423
|
path: string;
|
|
420
424
|
}, {
|
|
421
425
|
path: string;
|
|
@@ -447,7 +451,7 @@ declare const specificPageVisitMetadataSchema: z.ZodObject<{
|
|
|
447
451
|
page_name: z.ZodEnum<["contact_page", "about_page", "services_page", "booking_page", "location_page", "pricing_page", "faq_page", "testimonials_page"]>;
|
|
448
452
|
page: z.ZodObject<{
|
|
449
453
|
path: z.ZodString;
|
|
450
|
-
}, "
|
|
454
|
+
}, "strict", z.ZodTypeAny, {
|
|
451
455
|
path: string;
|
|
452
456
|
}, {
|
|
453
457
|
path: string;
|
|
@@ -468,7 +472,7 @@ declare const specificPageVisitConfigSchema: z.ZodObject<{
|
|
|
468
472
|
pages: z.ZodArray<z.ZodObject<{
|
|
469
473
|
name: z.ZodEnum<["contact_page", "about_page", "services_page", "booking_page", "location_page", "pricing_page", "faq_page", "testimonials_page"]>;
|
|
470
474
|
pathPattern: z.ZodType<RegExp, z.ZodTypeDef, RegExp>;
|
|
471
|
-
}, "
|
|
475
|
+
}, "strict", z.ZodTypeAny, {
|
|
472
476
|
name: "contact_page" | "about_page" | "services_page" | "booking_page" | "location_page" | "pricing_page" | "faq_page" | "testimonials_page";
|
|
473
477
|
pathPattern: RegExp;
|
|
474
478
|
}, {
|
|
@@ -492,7 +496,7 @@ declare const timeOnSiteMetadataSchema: z.ZodObject<{
|
|
|
492
496
|
duration_ms: z.ZodNumber;
|
|
493
497
|
page: z.ZodObject<{
|
|
494
498
|
path: z.ZodString;
|
|
495
|
-
}, "
|
|
499
|
+
}, "strict", z.ZodTypeAny, {
|
|
496
500
|
path: string;
|
|
497
501
|
}, {
|
|
498
502
|
path: string;
|
|
@@ -527,7 +531,7 @@ declare const EVENT_REGISTRY: {
|
|
|
527
531
|
path: z.ZodString;
|
|
528
532
|
search: z.ZodString;
|
|
529
533
|
hash: z.ZodString;
|
|
530
|
-
}, "
|
|
534
|
+
}, "strict", z.ZodTypeAny, {
|
|
531
535
|
search: string;
|
|
532
536
|
title: string | null;
|
|
533
537
|
path: string;
|
|
@@ -542,7 +546,7 @@ declare const EVENT_REGISTRY: {
|
|
|
542
546
|
viewport: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
543
547
|
w: z.ZodNumber;
|
|
544
548
|
h: z.ZodNumber;
|
|
545
|
-
}, "
|
|
549
|
+
}, "strict", z.ZodTypeAny, {
|
|
546
550
|
w: number;
|
|
547
551
|
h: number;
|
|
548
552
|
}, {
|
|
@@ -582,7 +586,7 @@ declare const EVENT_REGISTRY: {
|
|
|
582
586
|
duration_ms: z.ZodNumber;
|
|
583
587
|
page: z.ZodObject<{
|
|
584
588
|
path: z.ZodString;
|
|
585
|
-
}, "
|
|
589
|
+
}, "strict", z.ZodTypeAny, {
|
|
586
590
|
path: string;
|
|
587
591
|
}, {
|
|
588
592
|
path: string;
|
|
@@ -612,7 +616,7 @@ declare const EVENT_REGISTRY: {
|
|
|
612
616
|
page_name: z.ZodEnum<["contact_page", "about_page", "services_page", "booking_page", "location_page", "pricing_page", "faq_page", "testimonials_page"]>;
|
|
613
617
|
page: z.ZodObject<{
|
|
614
618
|
path: z.ZodString;
|
|
615
|
-
}, "
|
|
619
|
+
}, "strict", z.ZodTypeAny, {
|
|
616
620
|
path: string;
|
|
617
621
|
}, {
|
|
618
622
|
path: string;
|
|
@@ -632,7 +636,7 @@ declare const EVENT_REGISTRY: {
|
|
|
632
636
|
pages: z.ZodArray<z.ZodObject<{
|
|
633
637
|
name: z.ZodEnum<["contact_page", "about_page", "services_page", "booking_page", "location_page", "pricing_page", "faq_page", "testimonials_page"]>;
|
|
634
638
|
pathPattern: z.ZodType<RegExp, z.ZodTypeDef, RegExp>;
|
|
635
|
-
}, "
|
|
639
|
+
}, "strict", z.ZodTypeAny, {
|
|
636
640
|
name: "contact_page" | "about_page" | "services_page" | "booking_page" | "location_page" | "pricing_page" | "faq_page" | "testimonials_page";
|
|
637
641
|
pathPattern: RegExp;
|
|
638
642
|
}, {
|
|
@@ -657,7 +661,7 @@ declare const EVENT_REGISTRY: {
|
|
|
657
661
|
depth_percent: z.ZodNumber;
|
|
658
662
|
page: z.ZodObject<{
|
|
659
663
|
path: z.ZodString;
|
|
660
|
-
}, "
|
|
664
|
+
}, "strict", z.ZodTypeAny, {
|
|
661
665
|
path: string;
|
|
662
666
|
}, {
|
|
663
667
|
path: string;
|
|
@@ -687,7 +691,7 @@ declare const EVENT_REGISTRY: {
|
|
|
687
691
|
page_count: z.ZodNumber;
|
|
688
692
|
page: z.ZodObject<{
|
|
689
693
|
path: z.ZodString;
|
|
690
|
-
}, "
|
|
694
|
+
}, "strict", z.ZodTypeAny, {
|
|
691
695
|
path: string;
|
|
692
696
|
}, {
|
|
693
697
|
path: string;
|
|
@@ -717,7 +721,7 @@ declare const EVENT_REGISTRY: {
|
|
|
717
721
|
form: z.ZodObject<{
|
|
718
722
|
id: z.ZodString;
|
|
719
723
|
action: z.ZodNullable<z.ZodString>;
|
|
720
|
-
}, "
|
|
724
|
+
}, "strict", z.ZodTypeAny, {
|
|
721
725
|
id: string;
|
|
722
726
|
action: string | null;
|
|
723
727
|
}, {
|
|
@@ -726,7 +730,7 @@ declare const EVENT_REGISTRY: {
|
|
|
726
730
|
}>;
|
|
727
731
|
page: z.ZodObject<{
|
|
728
732
|
path: z.ZodString;
|
|
729
|
-
}, "
|
|
733
|
+
}, "strict", z.ZodTypeAny, {
|
|
730
734
|
path: string;
|
|
731
735
|
}, {
|
|
732
736
|
path: string;
|
|
@@ -804,40 +808,40 @@ declare const EVENT_REGISTRY: {
|
|
|
804
808
|
name: z.ZodString;
|
|
805
809
|
type: z.ZodString;
|
|
806
810
|
label: z.ZodNullable<z.ZodString>;
|
|
807
|
-
|
|
808
|
-
}, "
|
|
811
|
+
value: z.ZodType<src.JsonValue, z.ZodTypeDef, src.JsonValue>;
|
|
812
|
+
}, "strict", z.ZodTypeAny, {
|
|
809
813
|
label: string | null;
|
|
814
|
+
value: src.JsonValue;
|
|
810
815
|
type: string;
|
|
811
816
|
name: string;
|
|
812
|
-
has_value: boolean;
|
|
813
817
|
}, {
|
|
814
818
|
label: string | null;
|
|
819
|
+
value: src.JsonValue;
|
|
815
820
|
type: string;
|
|
816
821
|
name: string;
|
|
817
|
-
has_value: boolean;
|
|
818
822
|
}>, "many">>;
|
|
819
|
-
}, "
|
|
823
|
+
}, "strict", z.ZodTypeAny, {
|
|
820
824
|
id: string;
|
|
821
825
|
action: string | null;
|
|
822
826
|
fields?: {
|
|
823
827
|
label: string | null;
|
|
828
|
+
value: src.JsonValue;
|
|
824
829
|
type: string;
|
|
825
830
|
name: string;
|
|
826
|
-
has_value: boolean;
|
|
827
831
|
}[] | undefined;
|
|
828
832
|
}, {
|
|
829
833
|
id: string;
|
|
830
834
|
action: string | null;
|
|
831
835
|
fields?: {
|
|
832
836
|
label: string | null;
|
|
837
|
+
value: src.JsonValue;
|
|
833
838
|
type: string;
|
|
834
839
|
name: string;
|
|
835
|
-
has_value: boolean;
|
|
836
840
|
}[] | undefined;
|
|
837
841
|
}>;
|
|
838
842
|
page: z.ZodObject<{
|
|
839
843
|
path: z.ZodString;
|
|
840
|
-
}, "
|
|
844
|
+
}, "strict", z.ZodTypeAny, {
|
|
841
845
|
path: string;
|
|
842
846
|
}, {
|
|
843
847
|
path: string;
|
|
@@ -848,9 +852,9 @@ declare const EVENT_REGISTRY: {
|
|
|
848
852
|
action: string | null;
|
|
849
853
|
fields?: {
|
|
850
854
|
label: string | null;
|
|
855
|
+
value: src.JsonValue;
|
|
851
856
|
type: string;
|
|
852
857
|
name: string;
|
|
853
|
-
has_value: boolean;
|
|
854
858
|
}[] | undefined;
|
|
855
859
|
};
|
|
856
860
|
page: {
|
|
@@ -862,9 +866,9 @@ declare const EVENT_REGISTRY: {
|
|
|
862
866
|
action: string | null;
|
|
863
867
|
fields?: {
|
|
864
868
|
label: string | null;
|
|
869
|
+
value: src.JsonValue;
|
|
865
870
|
type: string;
|
|
866
871
|
name: string;
|
|
867
|
-
has_value: boolean;
|
|
868
872
|
}[] | undefined;
|
|
869
873
|
};
|
|
870
874
|
page: {
|
|
@@ -879,7 +883,7 @@ declare const EVENT_REGISTRY: {
|
|
|
879
883
|
phone_number: z.ZodString;
|
|
880
884
|
page: z.ZodObject<{
|
|
881
885
|
path: z.ZodString;
|
|
882
|
-
}, "
|
|
886
|
+
}, "strict", z.ZodTypeAny, {
|
|
883
887
|
path: string;
|
|
884
888
|
}, {
|
|
885
889
|
path: string;
|
|
@@ -906,7 +910,7 @@ declare const EVENT_REGISTRY: {
|
|
|
906
910
|
cta_name: z.ZodString;
|
|
907
911
|
page: z.ZodObject<{
|
|
908
912
|
path: z.ZodString;
|
|
909
|
-
}, "
|
|
913
|
+
}, "strict", z.ZodTypeAny, {
|
|
910
914
|
path: string;
|
|
911
915
|
}, {
|
|
912
916
|
path: string;
|
|
@@ -1048,4 +1052,4 @@ interface CreateTrackingResult<TRegistry extends TriggerRegistryConfig> {
|
|
|
1048
1052
|
}
|
|
1049
1053
|
declare function createTracking<TRegistry extends TriggerRegistryConfig>(options: CreateTrackingOptions<TRegistry>): CreateTrackingResult<TRegistry>;
|
|
1050
1054
|
|
|
1051
|
-
export { type AutomaticEventName, ConsentBanner, type ConsentState, type CreateTrackingOptions, type CreateTrackingResult, type CtaClickConfig, type CtaClickMetadata, type EventConfig, type EventMetadata, type EventName, type FormStartConfig, type FormStartMetadata, type FormSubmitConfig, type FormSubmitMetadata, GoogleAdsTracking, type GoogleAdsTrackingProps, type ManualEventName, type MultiPageSessionConfig, type MultiPageSessionMetadata, type PageViewConfig, type PageViewMetadata, type PhoneClickConfig, type PhoneClickMetadata, type RegisteredAutomaticEvents, type RegisteredManualEvents, type ScrollDepthConfig, type ScrollDepthMetadata, type SpecificPageName, type SpecificPageVisitConfig, type SpecificPageVisitMetadata, TRACKING_PARAM_KEYS, type TimeOnSiteConfig, type TimeOnSiteMetadata, type TrackingClient, type TrackingClientContext, type TrackingEventCreatePayload, type TrackingInitConfig, type TrackingInstallSurface, type TrackingParams, type TrackingProviderProps, type TrackingSessionUpsertPayload, type TriggerRegistryConfig, type TypedTrackEventOptions, type TypedTrackingClient, captureTrackingParamsFromLocation, createTracking, createTrackingClientContext, createTrackingEventCreatePayload, createTrackingSessionUpsertPayload, getConsentState, setConsentState, useConsentState, useGclid, useTrackingParams };
|
|
1055
|
+
export { type AutomaticEventName, ConsentBanner, type ConsentState, type CreateTrackingOptions, type CreateTrackingResult, type CtaClickConfig, type CtaClickMetadata, type EventConfig, type EventMetadata, type EventName, type FormStartConfig, type FormStartMetadata, type FormSubmitConfig, type FormSubmitMetadata, GoogleAdsTracking, type GoogleAdsTrackingProps, type JsonValue, type ManualEventName, type MultiPageSessionConfig, type MultiPageSessionMetadata, type PageViewConfig, type PageViewMetadata, type PhoneClickConfig, type PhoneClickMetadata, type RegisteredAutomaticEvents, type RegisteredManualEvents, type ScrollDepthConfig, type ScrollDepthMetadata, type SpecificPageName, type SpecificPageVisitConfig, type SpecificPageVisitMetadata, TRACKING_PARAM_KEYS, type TimeOnSiteConfig, type TimeOnSiteMetadata, type TrackingClient, type TrackingClientContext, type TrackingEventCreatePayload, type TrackingInitConfig, type TrackingInstallSurface, type TrackingParams, type TrackingProviderProps, type TrackingSessionUpsertPayload, type TriggerRegistryConfig, type TypedTrackEventOptions, type TypedTrackingClient, captureTrackingParamsFromLocation, createTracking, createTrackingClientContext, createTrackingEventCreatePayload, createTrackingSessionUpsertPayload, getConsentState, setConsentState, useConsentState, useGclid, useTrackingParams };
|
package/dist/index.js
CHANGED
|
@@ -295,7 +295,7 @@ var pageViewMetadataSchema = import_zod.z.object({
|
|
|
295
295
|
path: import_zod.z.string(),
|
|
296
296
|
search: import_zod.z.string(),
|
|
297
297
|
hash: import_zod.z.string()
|
|
298
|
-
}),
|
|
298
|
+
}).strict(),
|
|
299
299
|
referrer: import_zod.z.string().nullable(),
|
|
300
300
|
// `.nullable().optional()` — absent (undefined) OR explicit null OR a
|
|
301
301
|
// real viewport object. Mirrors Pydantic's `_Viewport | None = None`
|
|
@@ -303,7 +303,7 @@ var pageViewMetadataSchema = import_zod.z.object({
|
|
|
303
303
|
viewport: import_zod.z.object({
|
|
304
304
|
w: import_zod.z.number(),
|
|
305
305
|
h: import_zod.z.number()
|
|
306
|
-
}).nullable().optional()
|
|
306
|
+
}).strict().nullable().optional()
|
|
307
307
|
}).strict();
|
|
308
308
|
var pageViewConfigSchema = import_zod.z.object({}).strict();
|
|
309
309
|
|
|
@@ -686,7 +686,7 @@ var ctaClickMetadataSchema = import_zod2.z.object({
|
|
|
686
686
|
cta_name: import_zod2.z.string(),
|
|
687
687
|
page: import_zod2.z.object({
|
|
688
688
|
path: import_zod2.z.string()
|
|
689
|
-
}),
|
|
689
|
+
}).strict(),
|
|
690
690
|
section: import_zod2.z.string().nullable().optional(),
|
|
691
691
|
destination_url: import_zod2.z.string().nullable().optional()
|
|
692
692
|
}).strict();
|
|
@@ -713,10 +713,10 @@ var formStartMetadataSchema = import_zod4.z.object({
|
|
|
713
713
|
form: import_zod4.z.object({
|
|
714
714
|
id: import_zod4.z.string(),
|
|
715
715
|
action: import_zod4.z.string().nullable()
|
|
716
|
-
}),
|
|
716
|
+
}).strict(),
|
|
717
717
|
page: import_zod4.z.object({
|
|
718
718
|
path: import_zod4.z.string()
|
|
719
|
-
})
|
|
719
|
+
}).strict()
|
|
720
720
|
}).strict();
|
|
721
721
|
var formStartConfigSchema = import_zod4.z.object({
|
|
722
722
|
selector: import_zod4.z.string().optional()
|
|
@@ -724,6 +724,16 @@ var formStartConfigSchema = import_zod4.z.object({
|
|
|
724
724
|
|
|
725
725
|
// ../tracking-core/src/events/form-submit.ts
|
|
726
726
|
var import_zod5 = require("zod");
|
|
727
|
+
var jsonValueSchema = import_zod5.z.lazy(
|
|
728
|
+
() => import_zod5.z.union([
|
|
729
|
+
import_zod5.z.string(),
|
|
730
|
+
import_zod5.z.number().finite(),
|
|
731
|
+
import_zod5.z.boolean(),
|
|
732
|
+
import_zod5.z.null(),
|
|
733
|
+
import_zod5.z.array(jsonValueSchema),
|
|
734
|
+
import_zod5.z.record(jsonValueSchema)
|
|
735
|
+
])
|
|
736
|
+
);
|
|
727
737
|
var formSubmitMetadataSchema = import_zod5.z.object({
|
|
728
738
|
form: import_zod5.z.object({
|
|
729
739
|
id: import_zod5.z.string(),
|
|
@@ -733,13 +743,13 @@ var formSubmitMetadataSchema = import_zod5.z.object({
|
|
|
733
743
|
name: import_zod5.z.string(),
|
|
734
744
|
type: import_zod5.z.string(),
|
|
735
745
|
label: import_zod5.z.string().nullable(),
|
|
736
|
-
|
|
737
|
-
})
|
|
746
|
+
value: jsonValueSchema
|
|
747
|
+
}).strict()
|
|
738
748
|
).optional()
|
|
739
|
-
}),
|
|
749
|
+
}).strict(),
|
|
740
750
|
page: import_zod5.z.object({
|
|
741
751
|
path: import_zod5.z.string()
|
|
742
|
-
})
|
|
752
|
+
}).strict()
|
|
743
753
|
}).strict();
|
|
744
754
|
var formSubmitConfigSchema = import_zod5.z.object({}).strict();
|
|
745
755
|
|
|
@@ -749,7 +759,7 @@ var multiPageSessionMetadataSchema = import_zod6.z.object({
|
|
|
749
759
|
page_count: import_zod6.z.number().int().min(2),
|
|
750
760
|
page: import_zod6.z.object({
|
|
751
761
|
path: import_zod6.z.string()
|
|
752
|
-
})
|
|
762
|
+
}).strict()
|
|
753
763
|
}).strict();
|
|
754
764
|
var multiPageSessionConfigSchema = import_zod6.z.object({
|
|
755
765
|
pageThreshold: import_zod6.z.number().int().min(2)
|
|
@@ -761,7 +771,7 @@ var phoneClickMetadataSchema = import_zod7.z.object({
|
|
|
761
771
|
phone_number: import_zod7.z.string(),
|
|
762
772
|
page: import_zod7.z.object({
|
|
763
773
|
path: import_zod7.z.string()
|
|
764
|
-
}),
|
|
774
|
+
}).strict(),
|
|
765
775
|
section: import_zod7.z.string().nullable().optional()
|
|
766
776
|
}).strict();
|
|
767
777
|
var phoneClickConfigSchema = import_zod7.z.object({}).strict();
|
|
@@ -772,7 +782,7 @@ var scrollDepthMetadataSchema = import_zod8.z.object({
|
|
|
772
782
|
depth_percent: import_zod8.z.number().int().min(1).max(100),
|
|
773
783
|
page: import_zod8.z.object({
|
|
774
784
|
path: import_zod8.z.string()
|
|
775
|
-
})
|
|
785
|
+
}).strict()
|
|
776
786
|
}).strict();
|
|
777
787
|
var scrollDepthConfigSchema = import_zod8.z.object({
|
|
778
788
|
thresholds: import_zod8.z.array(import_zod8.z.number().int().min(1).max(100)).min(1)
|
|
@@ -795,7 +805,7 @@ var specificPageVisitMetadataSchema = import_zod9.z.object({
|
|
|
795
805
|
page_name: specificPageNameSchema,
|
|
796
806
|
page: import_zod9.z.object({
|
|
797
807
|
path: import_zod9.z.string()
|
|
798
|
-
})
|
|
808
|
+
}).strict()
|
|
799
809
|
}).strict();
|
|
800
810
|
var specificPageVisitConfigSchema = import_zod9.z.object({
|
|
801
811
|
pages: import_zod9.z.array(
|
|
@@ -804,7 +814,7 @@ var specificPageVisitConfigSchema = import_zod9.z.object({
|
|
|
804
814
|
pathPattern: import_zod9.z.custom((value) => value instanceof RegExp, {
|
|
805
815
|
message: "pathPattern must be a RegExp"
|
|
806
816
|
})
|
|
807
|
-
})
|
|
817
|
+
}).strict()
|
|
808
818
|
).min(1)
|
|
809
819
|
}).strict();
|
|
810
820
|
|
|
@@ -814,7 +824,7 @@ var timeOnSiteMetadataSchema = import_zod10.z.object({
|
|
|
814
824
|
duration_ms: import_zod10.z.number().int().nonnegative(),
|
|
815
825
|
page: import_zod10.z.object({
|
|
816
826
|
path: import_zod10.z.string()
|
|
817
|
-
})
|
|
827
|
+
}).strict()
|
|
818
828
|
}).strict();
|
|
819
829
|
var timeOnSiteConfigSchema = import_zod10.z.object({
|
|
820
830
|
thresholdSeconds: import_zod10.z.number().int().positive()
|
|
@@ -1326,7 +1336,7 @@ function useConsentState() {
|
|
|
1326
1336
|
var import_react4 = require("react");
|
|
1327
1337
|
|
|
1328
1338
|
// package.json
|
|
1329
|
-
var version = "0.
|
|
1339
|
+
var version = "0.6.0";
|
|
1330
1340
|
|
|
1331
1341
|
// src/factory.tsx
|
|
1332
1342
|
var import_jsx_runtime2 = require("react/jsx-runtime");
|