File tree Expand file tree Collapse file tree 2 files changed +21
-20
lines changed Expand file tree Collapse file tree 2 files changed +21
-20
lines changed Original file line number Diff line number Diff line change @@ -79,3 +79,22 @@ export interface PixelEventProperties {
79
79
'VEF' | 'VND' |
80
80
'ZAR' ;
81
81
}
82
+
83
+ export type PixelEventName = 'AddPaymentInfo' |
84
+ 'AddToCart' |
85
+ 'AddToWishlist' |
86
+ 'CompleteRegistration' |
87
+ 'Contact' |
88
+ 'CustomizeProduct' |
89
+ 'Donate' |
90
+ 'FindLocation' |
91
+ 'InitiateCheckout' |
92
+ 'Lead' |
93
+ 'PageView' |
94
+ 'Purchase' |
95
+ 'Schedule' |
96
+ 'Search' |
97
+ 'StartTrial' |
98
+ 'SubmitApplication' |
99
+ 'Subscribe' |
100
+ 'ViewContent' ;
Original file line number Diff line number Diff line change 1
- import { PixelConfiguration , PixelEventProperties } from './pixel.models' ;
1
+ import { PixelEventName , PixelConfiguration , PixelEventProperties } from './pixel.models' ;
2
2
import { Inject , Injectable , Optional } from '@angular/core' ;
3
3
import { NavigationEnd , Router } from '@angular/router' ;
4
4
import { filter } from 'rxjs/operators' ;
@@ -51,25 +51,7 @@ export class PixelService {
51
51
* @param properties Optional properties of the event
52
52
*/
53
53
track (
54
- eventName :
55
- 'AddPaymentInfo' |
56
- 'AddToCart' |
57
- 'AddToWishlist' |
58
- 'CompleteRegistration' |
59
- 'Contact' |
60
- 'CustomizeProduct' |
61
- 'Donate' |
62
- 'FindLocation' |
63
- 'InitiateCheckout' |
64
- 'Lead' |
65
- 'PageView' |
66
- 'Purchase' |
67
- 'Schedule' |
68
- 'Search' |
69
- 'StartTrial' |
70
- 'SubmitApplication' |
71
- 'Subscribe' |
72
- 'ViewContent' ,
54
+ eventName : PixelEventName ,
73
55
properties ?: PixelEventProperties
74
56
) : void {
75
57
You can’t perform that action at this time.
0 commit comments