4
4
5
5
``` ts
6
6
7
- import { Analytics } from ' @firebase/analytics-types-exp' ;
8
- import { AnalyticsCallOptions } from ' @firebase/analytics-types-exp' ;
9
- import { ControlParams } from ' @firebase/analytics-types-exp' ;
10
- import { CustomParams } from ' @firebase/analytics-types-exp' ;
11
- import { EventNameString } from ' @firebase/analytics-types-exp' ;
12
- import { EventParams } from ' @firebase/analytics-types-exp' ;
13
7
import { FirebaseApp } from ' @firebase/app-exp' ;
14
- import { Item } from ' @firebase/analytics-types-exp' ;
15
- import { Promotion } from ' @firebase/analytics-types-exp' ;
16
- import { SettingsOptions } from ' @firebase/analytics-types-exp' ;
17
8
18
- export { Analytics }
9
+ // @public (undocumented)
10
+ export interface Analytics {
11
+ app: FirebaseApp ;
12
+ }
19
13
20
- export { ControlParams }
14
+ // @public
15
+ export interface AnalyticsCallOptions {
16
+ global: boolean ;
17
+ }
18
+
19
+ // @public
20
+ export interface ControlParams {
21
+ // (undocumented)
22
+ event_callback? : () => void ;
23
+ // (undocumented)
24
+ event_timeout? : number ;
25
+ // (undocumented)
26
+ groups? : string | string [];
27
+ // (undocumented)
28
+ send_to? : string | string [];
29
+ }
30
+
31
+ // @public (undocumented)
32
+ export type Currency = string | number ;
21
33
22
34
// @public
23
35
export type CustomEventName <T > = T extends EventNameString ? never : T ;
24
36
25
- export { CustomParams }
37
+ // @public
38
+ export interface CustomParams {
39
+ // (undocumented)
40
+ [key : string ]: any ;
41
+ }
42
+
43
+ // @public
44
+ export type EventNameString = ' add_payment_info' | ' add_shipping_info' | ' add_to_cart' | ' add_to_wishlist' | ' begin_checkout' | ' checkout_progress' | ' exception' | ' generate_lead' | ' login' | ' page_view' | ' purchase' | ' refund' | ' remove_from_cart' | ' screen_view' | ' search' | ' select_content' | ' select_item' | ' select_promotion' | ' set_checkout_option' | ' share' | ' sign_up' | ' timing_complete' | ' view_cart' | ' view_item' | ' view_item_list' | ' view_promotion' | ' view_search_results' ;
26
45
27
- export { EventParams }
46
+ // @public
47
+ export interface EventParams {
48
+ // (undocumented)
49
+ affiliation? : string ;
50
+ // (undocumented)
51
+ checkout_option? : string ;
52
+ // (undocumented)
53
+ checkout_step? : number ;
54
+ // (undocumented)
55
+ content_id? : string ;
56
+ // (undocumented)
57
+ content_type? : string ;
58
+ // (undocumented)
59
+ coupon? : string ;
60
+ // (undocumented)
61
+ currency? : string ;
62
+ // (undocumented)
63
+ description? : string ;
64
+ // (undocumented)
65
+ event_category? : string ;
66
+ // (undocumented)
67
+ event_label? : string ;
68
+ // (undocumented)
69
+ fatal? : boolean ;
70
+ // (undocumented)
71
+ item_list_id? : string ;
72
+ // (undocumented)
73
+ item_list_name? : string ;
74
+ // (undocumented)
75
+ items? : Item [];
76
+ // (undocumented)
77
+ method? : string ;
78
+ // (undocumented)
79
+ number? : string ;
80
+ // (undocumented)
81
+ page_location? : string ;
82
+ // (undocumented)
83
+ page_path? : string ;
84
+ // (undocumented)
85
+ page_title? : string ;
86
+ // (undocumented)
87
+ payment_type? : string ;
88
+ // (undocumented)
89
+ promotion_id? : string ;
90
+ // (undocumented)
91
+ promotion_name? : string ;
92
+ // (undocumented)
93
+ promotions? : Promotion [];
94
+ // (undocumented)
95
+ screen_name? : string ;
96
+ // (undocumented)
97
+ search_term? : string ;
98
+ // (undocumented)
99
+ shipping? : Currency ;
100
+ // (undocumented)
101
+ shipping_tier? : string ;
102
+ // (undocumented)
103
+ tax? : Currency ;
104
+ // (undocumented)
105
+ transaction_id? : string ;
106
+ // (undocumented)
107
+ value? : number ;
108
+ }
28
109
29
110
// @public
30
111
export function getAnalytics(app : FirebaseApp ): Analytics ;
31
112
32
113
// @public
33
114
export function isSupported(): Promise <boolean >;
34
115
35
- export { Item }
116
+ // @public (undocumented)
117
+ export interface Item {
118
+ // (undocumented)
119
+ affiliation? : string ;
120
+ // @deprecated (undocumented)
121
+ brand? : string ;
122
+ // @deprecated (undocumented)
123
+ category? : string ;
124
+ // (undocumented)
125
+ coupon? : string ;
126
+ // (undocumented)
127
+ creative_name? : string ;
128
+ // (undocumented)
129
+ creative_slot? : string ;
130
+ // (undocumented)
131
+ discount? : Currency ;
132
+ // @deprecated (undocumented)
133
+ id? : string ;
134
+ // (undocumented)
135
+ index? : number ;
136
+ // (undocumented)
137
+ item_brand? : string ;
138
+ // (undocumented)
139
+ item_category? : string ;
140
+ // (undocumented)
141
+ item_category2? : string ;
142
+ // (undocumented)
143
+ item_category3? : string ;
144
+ // (undocumented)
145
+ item_category4? : string ;
146
+ // (undocumented)
147
+ item_category5? : string ;
148
+ // (undocumented)
149
+ item_id? : string ;
150
+ // (undocumented)
151
+ item_list_id? : string ;
152
+ // (undocumented)
153
+ item_list_name? : string ;
154
+ // (undocumented)
155
+ item_name? : string ;
156
+ // (undocumented)
157
+ item_variant? : string ;
158
+ // (undocumented)
159
+ location_id? : string ;
160
+ // @deprecated (undocumented)
161
+ name? : string ;
162
+ // (undocumented)
163
+ price? : Currency ;
164
+ // (undocumented)
165
+ promotion_id? : string ;
166
+ // (undocumented)
167
+ promotion_name? : string ;
168
+ // (undocumented)
169
+ quantity? : number ;
170
+ }
36
171
37
172
// @public
38
173
export function logEvent(analyticsInstance : Analytics , eventName : ' add_payment_info' , eventParams ? : {
@@ -216,7 +351,17 @@ export function logEvent<T extends string>(analyticsInstance: Analytics, eventNa
216
351
[key : string ]: any ;
217
352
}, options ? : AnalyticsCallOptions ): void ;
218
353
219
- export { Promotion }
354
+ // @public @deprecated (undocumented)
355
+ export interface Promotion {
356
+ // (undocumented)
357
+ creative_name? : string ;
358
+ // (undocumented)
359
+ creative_slot? : string ;
360
+ // (undocumented)
361
+ id? : string ;
362
+ // (undocumented)
363
+ name? : string ;
364
+ }
220
365
221
366
// @public
222
367
export function setAnalyticsCollectionEnabled(analyticsInstance : Analytics , enabled : boolean ): void ;
@@ -227,7 +372,11 @@ export function setCurrentScreen(analyticsInstance: Analytics, screenName: strin
227
372
// @public
228
373
export function settings(options : SettingsOptions ): void ;
229
374
230
- export { SettingsOptions }
375
+ // @public
376
+ export interface SettingsOptions {
377
+ dataLayerName? : string ;
378
+ gtagName? : string ;
379
+ }
231
380
232
381
// @public
233
382
export function setUserId(analyticsInstance : Analytics , id : string , options ? : AnalyticsCallOptions ): void ;
0 commit comments