angulartics2 10.1.0 → 12.1.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.
Files changed (385) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +7 -8
  3. package/angular-router.d.ts +3 -0
  4. package/angulartics2-core.d.ts +3 -0
  5. package/angulartics2.d.ts +1 -0
  6. package/angulartics2.module.d.ts +5 -0
  7. package/angulartics2On.d.ts +6 -0
  8. package/esm2020/angular-router.mjs +33 -0
  9. package/esm2020/angulartics2-config.mjs +19 -0
  10. package/esm2020/angulartics2-core.mjs +93 -0
  11. package/esm2020/angulartics2-interfaces.mjs +2 -0
  12. package/esm2020/angulartics2-token.mjs +3 -0
  13. package/esm2020/angulartics2.mjs +5 -0
  14. package/{esm2015/angulartics2.module.js → esm2020/angulartics2.module.mjs} +12 -7
  15. package/esm2020/angulartics2On.mjs +66 -0
  16. package/esm2020/providers/adobeanalytics/adobeanalytics.mjs +98 -0
  17. package/esm2020/providers/amplitude/amplitude.mjs +68 -0
  18. package/esm2020/providers/appinsights/appinsights.mjs +118 -0
  19. package/esm2020/providers/baidu/baidu.mjs +81 -0
  20. package/{clicky/esm2015/clicky.interfaces.js → esm2020/providers/clicky/clicky.interfaces.mjs} +1 -0
  21. package/esm2020/providers/clicky/clicky.mjs +64 -0
  22. package/esm2020/providers/facebook/facebook.mjs +45 -0
  23. package/esm2020/providers/ga/ga.mjs +219 -0
  24. package/{ga-enhanced-ecom/esm2015/ga-enhanced-ecom-options.js → esm2020/providers/ga-enhanced-ecom/ga-enhanced-ecom-options.mjs} +1 -0
  25. package/esm2020/providers/ga-enhanced-ecom/ga-enhanced-ecom.mjs +32 -0
  26. package/esm2020/providers/gosquared/gosquared.mjs +55 -0
  27. package/{gst/esm2015/gst-interfaces.js → esm2020/providers/gst/gst-interfaces.mjs} +1 -0
  28. package/esm2020/providers/gst/gst.mjs +197 -0
  29. package/esm2020/providers/gtm/gtm.mjs +114 -0
  30. package/esm2020/providers/hubspot/hubspot.mjs +40 -0
  31. package/esm2020/providers/ibm-digital-analytics/ibm-digital-analytics.mjs +125 -0
  32. package/esm2020/providers/intercom/intercom.mjs +60 -0
  33. package/esm2020/providers/kissmetrics/kissmetrics.mjs +40 -0
  34. package/esm2020/providers/launch/launch.mjs +59 -0
  35. package/esm2020/providers/matomo/matomo.mjs +303 -0
  36. package/esm2020/providers/mixpanel/mixpanel.mjs +109 -0
  37. package/esm2020/providers/pyze/pyze.mjs +65 -0
  38. package/esm2020/providers/segment/segment.mjs +100 -0
  39. package/esm2020/providers/splunk/splunk.mjs +46 -0
  40. package/esm2020/providers/woopra/woopra.mjs +61 -0
  41. package/esm2020/public_api.mjs +32 -0
  42. package/esm2020/routerless.mjs +10 -0
  43. package/esm2020/routerless.module.mjs +28 -0
  44. package/fesm2015/angulartics2.mjs +2248 -0
  45. package/fesm2015/angulartics2.mjs.map +1 -0
  46. package/fesm2020/angulartics2.mjs +2294 -0
  47. package/fesm2020/angulartics2.mjs.map +1 -0
  48. package/package.json +26 -13
  49. package/{adobeanalytics → providers/adobeanalytics}/README.md +1 -1
  50. package/{adobeanalytics → providers/adobeanalytics}/adobeanalytics.d.ts +4 -1
  51. package/{amplitude → providers/amplitude}/README.md +1 -1
  52. package/{amplitude → providers/amplitude}/amplitude.d.ts +4 -1
  53. package/{appinsights → providers/appinsights}/README.md +1 -1
  54. package/{appinsights → providers/appinsights}/appinsights.d.ts +5 -1
  55. package/{baidu → providers/baidu}/README.md +1 -1
  56. package/{baidu → providers/baidu}/baidu.d.ts +4 -1
  57. package/{clicky → providers/clicky}/README.md +1 -1
  58. package/{clicky → providers/clicky}/clicky.d.ts +4 -1
  59. package/{clicky → providers/clicky}/clicky.interfaces.d.ts +0 -0
  60. package/{facebook → providers/facebook}/README.md +1 -1
  61. package/{facebook → providers/facebook}/facebook.d.ts +4 -1
  62. package/{ga → providers/ga}/README.md +1 -1
  63. package/{ga → providers/ga}/ga.d.ts +6 -1
  64. package/{ga-enhanced-ecom → providers/ga-enhanced-ecom}/README.md +1 -1
  65. package/{ga-enhanced-ecom → providers/ga-enhanced-ecom}/ga-enhanced-ecom-options.d.ts +0 -0
  66. package/{ga-enhanced-ecom → providers/ga-enhanced-ecom}/ga-enhanced-ecom.d.ts +3 -0
  67. package/{gosquared → providers/gosquared}/README.md +1 -1
  68. package/{gosquared → providers/gosquared}/gosquared.d.ts +4 -1
  69. package/{gst → providers/gst}/README.md +2 -2
  70. package/{gst → providers/gst}/gst-interfaces.d.ts +0 -0
  71. package/{gst → providers/gst}/gst.d.ts +5 -1
  72. package/{gtm → providers/gtm}/README.md +2 -2
  73. package/{gtm → providers/gtm}/gtm.d.ts +5 -1
  74. package/{hubspot → providers/hubspot}/README.md +1 -1
  75. package/{hubspot → providers/hubspot}/hubspot.d.ts +4 -1
  76. package/{ibm-digital-analytics → providers/ibm-digital-analytics}/README.md +2 -2
  77. package/{ibm-digital-analytics → providers/ibm-digital-analytics}/ibm-digital-analytics.d.ts +4 -1
  78. package/{intercom → providers/intercom}/README.md +1 -1
  79. package/{intercom → providers/intercom}/intercom.d.ts +4 -1
  80. package/{kissmetrics → providers/kissmetrics}/README.md +1 -1
  81. package/{kissmetrics → providers/kissmetrics}/kissmetrics.d.ts +4 -1
  82. package/{launch → providers/launch}/README.md +3 -3
  83. package/{launch → providers/launch}/launch.d.ts +4 -1
  84. package/{matomo → providers/matomo}/README.md +3 -3
  85. package/{matomo → providers/matomo}/matomo.d.ts +9 -6
  86. package/{mixpanel → providers/mixpanel}/README.md +2 -2
  87. package/{mixpanel → providers/mixpanel}/mixpanel.d.ts +4 -1
  88. package/{pyze → providers/pyze}/README.md +1 -1
  89. package/providers/pyze/pyze.d.ts +13 -0
  90. package/{segment → providers/segment}/README.md +3 -3
  91. package/{segment → providers/segment}/segment.d.ts +4 -1
  92. package/{splunk → providers/splunk}/README.md +2 -2
  93. package/providers/splunk/splunk.d.ts +11 -0
  94. package/{woopra → providers/woopra}/README.md +1 -1
  95. package/{woopra → providers/woopra}/woopra.d.ts +4 -1
  96. package/public_api.d.ts +23 -0
  97. package/routerless.module.d.ts +10 -0
  98. package/adobeanalytics/angulartics2-adobeanalytics.d.ts +0 -4
  99. package/adobeanalytics/angulartics2-adobeanalytics.metadata.json +0 -1
  100. package/adobeanalytics/bundles/angulartics2-adobeanalytics.umd.js +0 -116
  101. package/adobeanalytics/bundles/angulartics2-adobeanalytics.umd.js.map +0 -1
  102. package/adobeanalytics/bundles/angulartics2-adobeanalytics.umd.min.js +0 -2
  103. package/adobeanalytics/bundles/angulartics2-adobeanalytics.umd.min.js.map +0 -1
  104. package/adobeanalytics/esm2015/adobeanalytics.js +0 -103
  105. package/adobeanalytics/esm2015/angulartics2-adobeanalytics.js +0 -5
  106. package/adobeanalytics/fesm2015/angulartics2-adobeanalytics.js +0 -107
  107. package/adobeanalytics/fesm2015/angulartics2-adobeanalytics.js.map +0 -1
  108. package/adobeanalytics/package.json +0 -20
  109. package/amplitude/angulartics2-amplitude.d.ts +0 -4
  110. package/amplitude/angulartics2-amplitude.metadata.json +0 -1
  111. package/amplitude/bundles/angulartics2-amplitude.umd.js +0 -88
  112. package/amplitude/bundles/angulartics2-amplitude.umd.js.map +0 -1
  113. package/amplitude/bundles/angulartics2-amplitude.umd.min.js +0 -2
  114. package/amplitude/bundles/angulartics2-amplitude.umd.min.js.map +0 -1
  115. package/amplitude/esm2015/amplitude.js +0 -73
  116. package/amplitude/esm2015/angulartics2-amplitude.js +0 -5
  117. package/amplitude/fesm2015/angulartics2-amplitude.js +0 -78
  118. package/amplitude/fesm2015/angulartics2-amplitude.js.map +0 -1
  119. package/amplitude/package.json +0 -20
  120. package/angulartics2.metadata.json +0 -1
  121. package/appinsights/angulartics2-appinsights.d.ts +0 -4
  122. package/appinsights/angulartics2-appinsights.metadata.json +0 -1
  123. package/appinsights/bundles/angulartics2-appinsights.umd.js +0 -134
  124. package/appinsights/bundles/angulartics2-appinsights.umd.js.map +0 -1
  125. package/appinsights/bundles/angulartics2-appinsights.umd.min.js +0 -2
  126. package/appinsights/bundles/angulartics2-appinsights.umd.min.js.map +0 -1
  127. package/appinsights/esm2015/angulartics2-appinsights.js +0 -5
  128. package/appinsights/esm2015/appinsights.js +0 -122
  129. package/appinsights/fesm2015/angulartics2-appinsights.js +0 -125
  130. package/appinsights/fesm2015/angulartics2-appinsights.js.map +0 -1
  131. package/appinsights/package.json +0 -20
  132. package/baidu/angulartics2-baidu.d.ts +0 -4
  133. package/baidu/angulartics2-baidu.metadata.json +0 -1
  134. package/baidu/bundles/angulartics2-baidu.umd.js +0 -98
  135. package/baidu/bundles/angulartics2-baidu.umd.js.map +0 -1
  136. package/baidu/bundles/angulartics2-baidu.umd.min.js +0 -2
  137. package/baidu/bundles/angulartics2-baidu.umd.min.js.map +0 -1
  138. package/baidu/esm2015/angulartics2-baidu.js +0 -5
  139. package/baidu/esm2015/baidu.js +0 -83
  140. package/baidu/fesm2015/angulartics2-baidu.js +0 -88
  141. package/baidu/fesm2015/angulartics2-baidu.js.map +0 -1
  142. package/baidu/package.json +0 -20
  143. package/bundles/angulartics2.umd.js +0 -564
  144. package/bundles/angulartics2.umd.js.map +0 -1
  145. package/bundles/angulartics2.umd.min.js +0 -16
  146. package/bundles/angulartics2.umd.min.js.map +0 -1
  147. package/clicky/angulartics2-clicky.d.ts +0 -4
  148. package/clicky/angulartics2-clicky.metadata.json +0 -1
  149. package/clicky/bundles/angulartics2-clicky.umd.js +0 -80
  150. package/clicky/bundles/angulartics2-clicky.umd.js.map +0 -1
  151. package/clicky/bundles/angulartics2-clicky.umd.min.js +0 -2
  152. package/clicky/bundles/angulartics2-clicky.umd.min.js.map +0 -1
  153. package/clicky/esm2015/angulartics2-clicky.js +0 -5
  154. package/clicky/esm2015/clicky.js +0 -68
  155. package/clicky/fesm2015/angulartics2-clicky.js +0 -72
  156. package/clicky/fesm2015/angulartics2-clicky.js.map +0 -1
  157. package/clicky/package.json +0 -20
  158. package/esm2015/angular-router.js +0 -36
  159. package/esm2015/angulartics2-config.js +0 -19
  160. package/esm2015/angulartics2-core.js +0 -89
  161. package/esm2015/angulartics2-interfaces.js +0 -1
  162. package/esm2015/angulartics2-token.js +0 -3
  163. package/esm2015/angulartics2.js +0 -5
  164. package/esm2015/angulartics2On.js +0 -55
  165. package/esm2015/public_api.js +0 -9
  166. package/esm2015/routerless.js +0 -10
  167. package/facebook/angulartics2-facebook.d.ts +0 -4
  168. package/facebook/angulartics2-facebook.metadata.json +0 -1
  169. package/facebook/bundles/angulartics2-facebook.umd.js +0 -62
  170. package/facebook/bundles/angulartics2-facebook.umd.js.map +0 -1
  171. package/facebook/bundles/angulartics2-facebook.umd.min.js +0 -2
  172. package/facebook/bundles/angulartics2-facebook.umd.min.js.map +0 -1
  173. package/facebook/esm2015/angulartics2-facebook.js +0 -5
  174. package/facebook/esm2015/facebook.js +0 -47
  175. package/facebook/fesm2015/angulartics2-facebook.js +0 -52
  176. package/facebook/fesm2015/angulartics2-facebook.js.map +0 -1
  177. package/facebook/package.json +0 -20
  178. package/fesm2015/angulartics2.js +0 -223
  179. package/fesm2015/angulartics2.js.map +0 -1
  180. package/ga/angulartics2-ga.d.ts +0 -4
  181. package/ga/angulartics2-ga.metadata.json +0 -1
  182. package/ga/bundles/angulartics2-ga.umd.js +0 -600
  183. package/ga/bundles/angulartics2-ga.umd.js.map +0 -1
  184. package/ga/bundles/angulartics2-ga.umd.min.js +0 -16
  185. package/ga/bundles/angulartics2-ga.umd.min.js.map +0 -1
  186. package/ga/esm2015/angulartics2-ga.js +0 -5
  187. package/ga/esm2015/ga.js +0 -207
  188. package/ga/fesm2015/angulartics2-ga.js +0 -212
  189. package/ga/fesm2015/angulartics2-ga.js.map +0 -1
  190. package/ga/package.json +0 -20
  191. package/ga-enhanced-ecom/angulartics2-ga-enhanced-ecom.d.ts +0 -4
  192. package/ga-enhanced-ecom/angulartics2-ga-enhanced-ecom.metadata.json +0 -1
  193. package/ga-enhanced-ecom/bundles/angulartics2-ga-enhanced-ecom.umd.js +0 -47
  194. package/ga-enhanced-ecom/bundles/angulartics2-ga-enhanced-ecom.umd.js.map +0 -1
  195. package/ga-enhanced-ecom/bundles/angulartics2-ga-enhanced-ecom.umd.min.js +0 -2
  196. package/ga-enhanced-ecom/bundles/angulartics2-ga-enhanced-ecom.umd.min.js.map +0 -1
  197. package/ga-enhanced-ecom/esm2015/angulartics2-ga-enhanced-ecom.js +0 -5
  198. package/ga-enhanced-ecom/esm2015/ga-enhanced-ecom.js +0 -30
  199. package/ga-enhanced-ecom/fesm2015/angulartics2-ga-enhanced-ecom.js +0 -36
  200. package/ga-enhanced-ecom/fesm2015/angulartics2-ga-enhanced-ecom.js.map +0 -1
  201. package/ga-enhanced-ecom/package.json +0 -20
  202. package/gosquared/angulartics2-gosquared.d.ts +0 -4
  203. package/gosquared/angulartics2-gosquared.metadata.json +0 -1
  204. package/gosquared/bundles/angulartics2-gosquared.umd.js +0 -72
  205. package/gosquared/bundles/angulartics2-gosquared.umd.js.map +0 -1
  206. package/gosquared/bundles/angulartics2-gosquared.umd.min.js +0 -2
  207. package/gosquared/bundles/angulartics2-gosquared.umd.min.js.map +0 -1
  208. package/gosquared/esm2015/angulartics2-gosquared.js +0 -5
  209. package/gosquared/esm2015/gosquared.js +0 -57
  210. package/gosquared/fesm2015/angulartics2-gosquared.js +0 -62
  211. package/gosquared/fesm2015/angulartics2-gosquared.js.map +0 -1
  212. package/gosquared/package.json +0 -20
  213. package/gst/angulartics2-gst.d.ts +0 -4
  214. package/gst/angulartics2-gst.metadata.json +0 -1
  215. package/gst/bundles/angulartics2-gst.umd.js +0 -514
  216. package/gst/bundles/angulartics2-gst.umd.js.map +0 -1
  217. package/gst/bundles/angulartics2-gst.umd.min.js +0 -16
  218. package/gst/bundles/angulartics2-gst.umd.min.js.map +0 -1
  219. package/gst/esm2015/angulartics2-gst.js +0 -5
  220. package/gst/esm2015/gst.js +0 -182
  221. package/gst/fesm2015/angulartics2-gst.js +0 -187
  222. package/gst/fesm2015/angulartics2-gst.js.map +0 -1
  223. package/gst/package.json +0 -20
  224. package/gtm/angulartics2-gtm.d.ts +0 -4
  225. package/gtm/angulartics2-gtm.metadata.json +0 -1
  226. package/gtm/bundles/angulartics2-gtm.umd.js +0 -125
  227. package/gtm/bundles/angulartics2-gtm.umd.js.map +0 -1
  228. package/gtm/bundles/angulartics2-gtm.umd.min.js +0 -2
  229. package/gtm/bundles/angulartics2-gtm.umd.min.js.map +0 -1
  230. package/gtm/esm2015/angulartics2-gtm.js +0 -5
  231. package/gtm/esm2015/gtm.js +0 -108
  232. package/gtm/fesm2015/angulartics2-gtm.js +0 -113
  233. package/gtm/fesm2015/angulartics2-gtm.js.map +0 -1
  234. package/gtm/package.json +0 -20
  235. package/hubspot/angulartics2-hubspot.d.ts +0 -4
  236. package/hubspot/angulartics2-hubspot.metadata.json +0 -1
  237. package/hubspot/bundles/angulartics2-hubspot.umd.js +0 -58
  238. package/hubspot/bundles/angulartics2-hubspot.umd.js.map +0 -1
  239. package/hubspot/bundles/angulartics2-hubspot.umd.min.js +0 -2
  240. package/hubspot/bundles/angulartics2-hubspot.umd.min.js.map +0 -1
  241. package/hubspot/esm2015/angulartics2-hubspot.js +0 -5
  242. package/hubspot/esm2015/hubspot.js +0 -43
  243. package/hubspot/fesm2015/angulartics2-hubspot.js +0 -48
  244. package/hubspot/fesm2015/angulartics2-hubspot.js.map +0 -1
  245. package/hubspot/package.json +0 -20
  246. package/ibm-digital-analytics/angulartics2-ibm-digital-analytics.d.ts +0 -4
  247. package/ibm-digital-analytics/angulartics2-ibm-digital-analytics.metadata.json +0 -1
  248. package/ibm-digital-analytics/bundles/angulartics2-ibm-digital-analytics.umd.js +0 -142
  249. package/ibm-digital-analytics/bundles/angulartics2-ibm-digital-analytics.umd.js.map +0 -1
  250. package/ibm-digital-analytics/bundles/angulartics2-ibm-digital-analytics.umd.min.js +0 -2
  251. package/ibm-digital-analytics/bundles/angulartics2-ibm-digital-analytics.umd.min.js.map +0 -1
  252. package/ibm-digital-analytics/esm2015/angulartics2-ibm-digital-analytics.js +0 -5
  253. package/ibm-digital-analytics/esm2015/ibm-digital-analytics.js +0 -127
  254. package/ibm-digital-analytics/fesm2015/angulartics2-ibm-digital-analytics.js +0 -132
  255. package/ibm-digital-analytics/fesm2015/angulartics2-ibm-digital-analytics.js.map +0 -1
  256. package/ibm-digital-analytics/package.json +0 -20
  257. package/intercom/angulartics2-intercom.d.ts +0 -4
  258. package/intercom/angulartics2-intercom.metadata.json +0 -1
  259. package/intercom/bundles/angulartics2-intercom.umd.js +0 -79
  260. package/intercom/bundles/angulartics2-intercom.umd.js.map +0 -1
  261. package/intercom/bundles/angulartics2-intercom.umd.min.js +0 -2
  262. package/intercom/bundles/angulartics2-intercom.umd.min.js.map +0 -1
  263. package/intercom/esm2015/angulartics2-intercom.js +0 -5
  264. package/intercom/esm2015/intercom.js +0 -64
  265. package/intercom/fesm2015/angulartics2-intercom.js +0 -69
  266. package/intercom/fesm2015/angulartics2-intercom.js.map +0 -1
  267. package/intercom/package.json +0 -20
  268. package/kissmetrics/angulartics2-kissmetrics.d.ts +0 -4
  269. package/kissmetrics/angulartics2-kissmetrics.metadata.json +0 -1
  270. package/kissmetrics/bundles/angulartics2-kissmetrics.umd.js +0 -59
  271. package/kissmetrics/bundles/angulartics2-kissmetrics.umd.js.map +0 -1
  272. package/kissmetrics/bundles/angulartics2-kissmetrics.umd.min.js +0 -2
  273. package/kissmetrics/bundles/angulartics2-kissmetrics.umd.min.js.map +0 -1
  274. package/kissmetrics/esm2015/angulartics2-kissmetrics.js +0 -5
  275. package/kissmetrics/esm2015/kissmetrics.js +0 -44
  276. package/kissmetrics/fesm2015/angulartics2-kissmetrics.js +0 -49
  277. package/kissmetrics/fesm2015/angulartics2-kissmetrics.js.map +0 -1
  278. package/kissmetrics/package.json +0 -23
  279. package/launch/angulartics2-launch.d.ts +0 -4
  280. package/launch/angulartics2-launch.metadata.json +0 -1
  281. package/launch/bundles/angulartics2-launch.umd.js +0 -78
  282. package/launch/bundles/angulartics2-launch.umd.js.map +0 -1
  283. package/launch/bundles/angulartics2-launch.umd.min.js +0 -2
  284. package/launch/bundles/angulartics2-launch.umd.min.js.map +0 -1
  285. package/launch/esm2015/angulartics2-launch.js +0 -5
  286. package/launch/esm2015/launch.js +0 -63
  287. package/launch/fesm2015/angulartics2-launch.js +0 -68
  288. package/launch/fesm2015/angulartics2-launch.js.map +0 -1
  289. package/launch/package.json +0 -20
  290. package/matomo/angulartics2-matomo.d.ts +0 -4
  291. package/matomo/angulartics2-matomo.metadata.json +0 -1
  292. package/matomo/bundles/angulartics2-matomo.umd.js +0 -309
  293. package/matomo/bundles/angulartics2-matomo.umd.js.map +0 -1
  294. package/matomo/bundles/angulartics2-matomo.umd.min.js +0 -2
  295. package/matomo/bundles/angulartics2-matomo.umd.min.js.map +0 -1
  296. package/matomo/esm2015/angulartics2-matomo.js +0 -5
  297. package/matomo/esm2015/matomo.js +0 -294
  298. package/matomo/fesm2015/angulartics2-matomo.js +0 -299
  299. package/matomo/fesm2015/angulartics2-matomo.js.map +0 -1
  300. package/matomo/package.json +0 -20
  301. package/mixpanel/angulartics2-mixpanel.d.ts +0 -4
  302. package/mixpanel/angulartics2-mixpanel.metadata.json +0 -1
  303. package/mixpanel/bundles/angulartics2-mixpanel.umd.js +0 -132
  304. package/mixpanel/bundles/angulartics2-mixpanel.umd.js.map +0 -1
  305. package/mixpanel/bundles/angulartics2-mixpanel.umd.min.js +0 -2
  306. package/mixpanel/bundles/angulartics2-mixpanel.umd.min.js.map +0 -1
  307. package/mixpanel/esm2015/angulartics2-mixpanel.js +0 -5
  308. package/mixpanel/esm2015/mixpanel.js +0 -117
  309. package/mixpanel/fesm2015/angulartics2-mixpanel.js +0 -122
  310. package/mixpanel/fesm2015/angulartics2-mixpanel.js.map +0 -1
  311. package/mixpanel/package.json +0 -20
  312. package/pyze/angulartics2-pyze.d.ts +0 -4
  313. package/pyze/angulartics2-pyze.metadata.json +0 -1
  314. package/pyze/bundles/angulartics2-pyze.umd.js +0 -82
  315. package/pyze/bundles/angulartics2-pyze.umd.js.map +0 -1
  316. package/pyze/bundles/angulartics2-pyze.umd.min.js +0 -2
  317. package/pyze/bundles/angulartics2-pyze.umd.min.js.map +0 -1
  318. package/pyze/esm2015/angulartics2-pyze.js +0 -5
  319. package/pyze/esm2015/pyze.js +0 -67
  320. package/pyze/fesm2015/angulartics2-pyze.js +0 -72
  321. package/pyze/fesm2015/angulartics2-pyze.js.map +0 -1
  322. package/pyze/package.json +0 -20
  323. package/pyze/pyze.d.ts +0 -10
  324. package/routerlessmodule/angulartics2-routerlessmodule.d.ts +0 -4
  325. package/routerlessmodule/angulartics2-routerlessmodule.metadata.json +0 -1
  326. package/routerlessmodule/bundles/angulartics2-routerlessmodule.umd.js +0 -38
  327. package/routerlessmodule/bundles/angulartics2-routerlessmodule.umd.js.map +0 -1
  328. package/routerlessmodule/bundles/angulartics2-routerlessmodule.umd.min.js +0 -2
  329. package/routerlessmodule/bundles/angulartics2-routerlessmodule.umd.min.js.map +0 -1
  330. package/routerlessmodule/esm2015/angulartics2-routerlessmodule.js +0 -5
  331. package/routerlessmodule/esm2015/routerless.module.js +0 -20
  332. package/routerlessmodule/fesm2015/angulartics2-routerlessmodule.js +0 -27
  333. package/routerlessmodule/fesm2015/angulartics2-routerlessmodule.js.map +0 -1
  334. package/routerlessmodule/package.json +0 -20
  335. package/routerlessmodule/routerless.module.d.ts +0 -5
  336. package/segment/angulartics2-segment.d.ts +0 -4
  337. package/segment/angulartics2-segment.metadata.json +0 -1
  338. package/segment/bundles/angulartics2-segment.umd.js +0 -120
  339. package/segment/bundles/angulartics2-segment.umd.js.map +0 -1
  340. package/segment/bundles/angulartics2-segment.umd.min.js +0 -2
  341. package/segment/bundles/angulartics2-segment.umd.min.js.map +0 -1
  342. package/segment/esm2015/angulartics2-segment.js +0 -5
  343. package/segment/esm2015/segment.js +0 -105
  344. package/segment/fesm2015/angulartics2-segment.js +0 -110
  345. package/segment/fesm2015/angulartics2-segment.js.map +0 -1
  346. package/segment/package.json +0 -20
  347. package/splunk/angulartics2-splunk.d.ts +0 -4
  348. package/splunk/angulartics2-splunk.metadata.json +0 -1
  349. package/splunk/bundles/angulartics2-splunk.umd.js +0 -62
  350. package/splunk/bundles/angulartics2-splunk.umd.js.map +0 -1
  351. package/splunk/bundles/angulartics2-splunk.umd.min.js +0 -2
  352. package/splunk/bundles/angulartics2-splunk.umd.min.js.map +0 -1
  353. package/splunk/esm2015/angulartics2-splunk.js +0 -5
  354. package/splunk/esm2015/splunk.js +0 -48
  355. package/splunk/fesm2015/angulartics2-splunk.js +0 -53
  356. package/splunk/fesm2015/angulartics2-splunk.js.map +0 -1
  357. package/splunk/package.json +0 -20
  358. package/splunk/splunk.d.ts +0 -8
  359. package/uiroutermodule/angulartics2-uiroutermodule.d.ts +0 -4
  360. package/uiroutermodule/angulartics2-uiroutermodule.metadata.json +0 -1
  361. package/uiroutermodule/bundles/angulartics2-uiroutermodule.umd.js +0 -76
  362. package/uiroutermodule/bundles/angulartics2-uiroutermodule.umd.js.map +0 -1
  363. package/uiroutermodule/bundles/angulartics2-uiroutermodule.umd.min.js +0 -2
  364. package/uiroutermodule/bundles/angulartics2-uiroutermodule.umd.min.js.map +0 -1
  365. package/uiroutermodule/esm2015/angulartics2-uiroutermodule.js +0 -5
  366. package/uiroutermodule/esm2015/public_api.js +0 -3
  367. package/uiroutermodule/esm2015/uirouter.js +0 -40
  368. package/uiroutermodule/esm2015/uirouter.module.js +0 -21
  369. package/uiroutermodule/fesm2015/angulartics2-uiroutermodule.js +0 -64
  370. package/uiroutermodule/fesm2015/angulartics2-uiroutermodule.js.map +0 -1
  371. package/uiroutermodule/package.json +0 -20
  372. package/uiroutermodule/public_api.d.ts +0 -2
  373. package/uiroutermodule/uirouter.d.ts +0 -17
  374. package/uiroutermodule/uirouter.module.d.ts +0 -5
  375. package/woopra/angulartics2-woopra.d.ts +0 -4
  376. package/woopra/angulartics2-woopra.metadata.json +0 -1
  377. package/woopra/bundles/angulartics2-woopra.umd.js +0 -79
  378. package/woopra/bundles/angulartics2-woopra.umd.js.map +0 -1
  379. package/woopra/bundles/angulartics2-woopra.umd.min.js +0 -2
  380. package/woopra/bundles/angulartics2-woopra.umd.min.js.map +0 -1
  381. package/woopra/esm2015/angulartics2-woopra.js +0 -5
  382. package/woopra/esm2015/woopra.js +0 -64
  383. package/woopra/fesm2015/angulartics2-woopra.js +0 -69
  384. package/woopra/fesm2015/angulartics2-woopra.js.map +0 -1
  385. package/woopra/package.json +0 -20
@@ -1,600 +0,0 @@
1
- (function (global, factory) {
2
- typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('angulartics2')) :
3
- typeof define === 'function' && define.amd ? define('angulartics2/ga', ['exports', '@angular/core', 'angulartics2'], factory) :
4
- (global = global || self, factory((global.angulartics2 = global.angulartics2 || {}, global.angulartics2.ga = {}), global.ng.core, global.angulartics2));
5
- }(this, (function (exports, i0, i1) { 'use strict';
6
-
7
- /*! *****************************************************************************
8
- Copyright (c) Microsoft Corporation.
9
-
10
- Permission to use, copy, modify, and/or distribute this software for any
11
- purpose with or without fee is hereby granted.
12
-
13
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
14
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
15
- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
16
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
17
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
18
- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
19
- PERFORMANCE OF THIS SOFTWARE.
20
- ***************************************************************************** */
21
- /* global Reflect, Promise */
22
- var extendStatics = function (d, b) {
23
- extendStatics = Object.setPrototypeOf ||
24
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
25
- function (d, b) { for (var p in b)
26
- if (b.hasOwnProperty(p))
27
- d[p] = b[p]; };
28
- return extendStatics(d, b);
29
- };
30
- function __extends(d, b) {
31
- extendStatics(d, b);
32
- function __() { this.constructor = d; }
33
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
34
- }
35
- var __assign = function () {
36
- __assign = Object.assign || function __assign(t) {
37
- for (var s, i = 1, n = arguments.length; i < n; i++) {
38
- s = arguments[i];
39
- for (var p in s)
40
- if (Object.prototype.hasOwnProperty.call(s, p))
41
- t[p] = s[p];
42
- }
43
- return t;
44
- };
45
- return __assign.apply(this, arguments);
46
- };
47
- function __rest(s, e) {
48
- var t = {};
49
- for (var p in s)
50
- if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
51
- t[p] = s[p];
52
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
53
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
54
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
55
- t[p[i]] = s[p[i]];
56
- }
57
- return t;
58
- }
59
- function __decorate(decorators, target, key, desc) {
60
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
61
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
62
- r = Reflect.decorate(decorators, target, key, desc);
63
- else
64
- for (var i = decorators.length - 1; i >= 0; i--)
65
- if (d = decorators[i])
66
- r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
67
- return c > 3 && r && Object.defineProperty(target, key, r), r;
68
- }
69
- function __param(paramIndex, decorator) {
70
- return function (target, key) { decorator(target, key, paramIndex); };
71
- }
72
- function __metadata(metadataKey, metadataValue) {
73
- if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
74
- return Reflect.metadata(metadataKey, metadataValue);
75
- }
76
- function __awaiter(thisArg, _arguments, P, generator) {
77
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
78
- return new (P || (P = Promise))(function (resolve, reject) {
79
- function fulfilled(value) { try {
80
- step(generator.next(value));
81
- }
82
- catch (e) {
83
- reject(e);
84
- } }
85
- function rejected(value) { try {
86
- step(generator["throw"](value));
87
- }
88
- catch (e) {
89
- reject(e);
90
- } }
91
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
92
- step((generator = generator.apply(thisArg, _arguments || [])).next());
93
- });
94
- }
95
- function __generator(thisArg, body) {
96
- var _ = { label: 0, sent: function () { if (t[0] & 1)
97
- throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
98
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function () { return this; }), g;
99
- function verb(n) { return function (v) { return step([n, v]); }; }
100
- function step(op) {
101
- if (f)
102
- throw new TypeError("Generator is already executing.");
103
- while (_)
104
- try {
105
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done)
106
- return t;
107
- if (y = 0, t)
108
- op = [op[0] & 2, t.value];
109
- switch (op[0]) {
110
- case 0:
111
- case 1:
112
- t = op;
113
- break;
114
- case 4:
115
- _.label++;
116
- return { value: op[1], done: false };
117
- case 5:
118
- _.label++;
119
- y = op[1];
120
- op = [0];
121
- continue;
122
- case 7:
123
- op = _.ops.pop();
124
- _.trys.pop();
125
- continue;
126
- default:
127
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
128
- _ = 0;
129
- continue;
130
- }
131
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) {
132
- _.label = op[1];
133
- break;
134
- }
135
- if (op[0] === 6 && _.label < t[1]) {
136
- _.label = t[1];
137
- t = op;
138
- break;
139
- }
140
- if (t && _.label < t[2]) {
141
- _.label = t[2];
142
- _.ops.push(op);
143
- break;
144
- }
145
- if (t[2])
146
- _.ops.pop();
147
- _.trys.pop();
148
- continue;
149
- }
150
- op = body.call(thisArg, _);
151
- }
152
- catch (e) {
153
- op = [6, e];
154
- y = 0;
155
- }
156
- finally {
157
- f = t = 0;
158
- }
159
- if (op[0] & 5)
160
- throw op[1];
161
- return { value: op[0] ? op[1] : void 0, done: true };
162
- }
163
- }
164
- var __createBinding = Object.create ? (function (o, m, k, k2) {
165
- if (k2 === undefined)
166
- k2 = k;
167
- Object.defineProperty(o, k2, { enumerable: true, get: function () { return m[k]; } });
168
- }) : (function (o, m, k, k2) {
169
- if (k2 === undefined)
170
- k2 = k;
171
- o[k2] = m[k];
172
- });
173
- function __exportStar(m, exports) {
174
- for (var p in m)
175
- if (p !== "default" && !exports.hasOwnProperty(p))
176
- __createBinding(exports, m, p);
177
- }
178
- function __values(o) {
179
- var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
180
- if (m)
181
- return m.call(o);
182
- if (o && typeof o.length === "number")
183
- return {
184
- next: function () {
185
- if (o && i >= o.length)
186
- o = void 0;
187
- return { value: o && o[i++], done: !o };
188
- }
189
- };
190
- throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
191
- }
192
- function __read(o, n) {
193
- var m = typeof Symbol === "function" && o[Symbol.iterator];
194
- if (!m)
195
- return o;
196
- var i = m.call(o), r, ar = [], e;
197
- try {
198
- while ((n === void 0 || n-- > 0) && !(r = i.next()).done)
199
- ar.push(r.value);
200
- }
201
- catch (error) {
202
- e = { error: error };
203
- }
204
- finally {
205
- try {
206
- if (r && !r.done && (m = i["return"]))
207
- m.call(i);
208
- }
209
- finally {
210
- if (e)
211
- throw e.error;
212
- }
213
- }
214
- return ar;
215
- }
216
- function __spread() {
217
- for (var ar = [], i = 0; i < arguments.length; i++)
218
- ar = ar.concat(__read(arguments[i]));
219
- return ar;
220
- }
221
- function __spreadArrays() {
222
- for (var s = 0, i = 0, il = arguments.length; i < il; i++)
223
- s += arguments[i].length;
224
- for (var r = Array(s), k = 0, i = 0; i < il; i++)
225
- for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
226
- r[k] = a[j];
227
- return r;
228
- }
229
- ;
230
- function __await(v) {
231
- return this instanceof __await ? (this.v = v, this) : new __await(v);
232
- }
233
- function __asyncGenerator(thisArg, _arguments, generator) {
234
- if (!Symbol.asyncIterator)
235
- throw new TypeError("Symbol.asyncIterator is not defined.");
236
- var g = generator.apply(thisArg, _arguments || []), i, q = [];
237
- return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
238
- function verb(n) { if (g[n])
239
- i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
240
- function resume(n, v) { try {
241
- step(g[n](v));
242
- }
243
- catch (e) {
244
- settle(q[0][3], e);
245
- } }
246
- function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
247
- function fulfill(value) { resume("next", value); }
248
- function reject(value) { resume("throw", value); }
249
- function settle(f, v) { if (f(v), q.shift(), q.length)
250
- resume(q[0][0], q[0][1]); }
251
- }
252
- function __asyncDelegator(o) {
253
- var i, p;
254
- return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i;
255
- function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; }
256
- }
257
- function __asyncValues(o) {
258
- if (!Symbol.asyncIterator)
259
- throw new TypeError("Symbol.asyncIterator is not defined.");
260
- var m = o[Symbol.asyncIterator], i;
261
- return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
262
- function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
263
- function settle(resolve, reject, d, v) { Promise.resolve(v).then(function (v) { resolve({ value: v, done: d }); }, reject); }
264
- }
265
- function __makeTemplateObject(cooked, raw) {
266
- if (Object.defineProperty) {
267
- Object.defineProperty(cooked, "raw", { value: raw });
268
- }
269
- else {
270
- cooked.raw = raw;
271
- }
272
- return cooked;
273
- }
274
- ;
275
- var __setModuleDefault = Object.create ? (function (o, v) {
276
- Object.defineProperty(o, "default", { enumerable: true, value: v });
277
- }) : function (o, v) {
278
- o["default"] = v;
279
- };
280
- function __importStar(mod) {
281
- if (mod && mod.__esModule)
282
- return mod;
283
- var result = {};
284
- if (mod != null)
285
- for (var k in mod)
286
- if (Object.hasOwnProperty.call(mod, k))
287
- __createBinding(result, mod, k);
288
- __setModuleDefault(result, mod);
289
- return result;
290
- }
291
- function __importDefault(mod) {
292
- return (mod && mod.__esModule) ? mod : { default: mod };
293
- }
294
- function __classPrivateFieldGet(receiver, privateMap) {
295
- if (!privateMap.has(receiver)) {
296
- throw new TypeError("attempted to get private field on non-instance");
297
- }
298
- return privateMap.get(receiver);
299
- }
300
- function __classPrivateFieldSet(receiver, privateMap, value) {
301
- if (!privateMap.has(receiver)) {
302
- throw new TypeError("attempted to set private field on non-instance");
303
- }
304
- privateMap.set(receiver, value);
305
- return value;
306
- }
307
-
308
- var GoogleAnalyticsDefaults = /** @class */ (function () {
309
- function GoogleAnalyticsDefaults() {
310
- this.additionalAccountNames = [];
311
- this.userId = null;
312
- this.transport = '';
313
- this.anonymizeIp = false;
314
- }
315
- return GoogleAnalyticsDefaults;
316
- }());
317
- var Angulartics2GoogleAnalytics = /** @class */ (function () {
318
- function Angulartics2GoogleAnalytics(angulartics2) {
319
- var _this = this;
320
- this.angulartics2 = angulartics2;
321
- this.dimensionsAndMetrics = [];
322
- var defaults = new GoogleAnalyticsDefaults();
323
- // Set the default settings for this module
324
- this.angulartics2.settings.ga = Object.assign(Object.assign({}, defaults), this.angulartics2.settings.ga);
325
- this.settings = this.angulartics2.settings.ga;
326
- this.angulartics2.setUsername.subscribe(function (x) { return _this.setUsername(x); });
327
- this.angulartics2.setUserProperties.subscribe(function (x) { return _this.setUserProperties(x); });
328
- }
329
- Angulartics2GoogleAnalytics.prototype.startTracking = function () {
330
- var _this = this;
331
- this.angulartics2.pageTrack
332
- .pipe(this.angulartics2.filterDeveloperMode())
333
- .subscribe(function (x) { return _this.pageTrack(x.path); });
334
- this.angulartics2.eventTrack
335
- .pipe(this.angulartics2.filterDeveloperMode())
336
- .subscribe(function (x) { return _this.eventTrack(x.action, x.properties); });
337
- this.angulartics2.exceptionTrack
338
- .pipe(this.angulartics2.filterDeveloperMode())
339
- .subscribe(function (x) { return _this.exceptionTrack(x); });
340
- this.angulartics2.userTimings
341
- .pipe(this.angulartics2.filterDeveloperMode())
342
- .subscribe(function (x) { return _this.userTimings(x); });
343
- };
344
- Angulartics2GoogleAnalytics.prototype.pageTrack = function (path) {
345
- var e_1, _a, e_2, _b, e_3, _c, e_4, _d;
346
- if (typeof _gaq !== 'undefined' && _gaq) {
347
- _gaq.push(['_trackPageview', path]);
348
- try {
349
- for (var _e = __values(this.angulartics2.settings.ga.additionalAccountNames), _f = _e.next(); !_f.done; _f = _e.next()) {
350
- var accountName = _f.value;
351
- _gaq.push([accountName + '._trackPageview', path]);
352
- }
353
- }
354
- catch (e_1_1) { e_1 = { error: e_1_1 }; }
355
- finally {
356
- try {
357
- if (_f && !_f.done && (_a = _e.return)) _a.call(_e);
358
- }
359
- finally { if (e_1) throw e_1.error; }
360
- }
361
- }
362
- if (typeof ga !== 'undefined' && ga) {
363
- if (this.angulartics2.settings.ga.userId) {
364
- ga('set', '&uid', this.angulartics2.settings.ga.userId);
365
- try {
366
- for (var _g = __values(this.angulartics2.settings.ga.additionalAccountNames), _h = _g.next(); !_h.done; _h = _g.next()) {
367
- var accountName = _h.value;
368
- ga(accountName + '.set', '&uid', this.angulartics2.settings.ga.userId);
369
- }
370
- }
371
- catch (e_2_1) { e_2 = { error: e_2_1 }; }
372
- finally {
373
- try {
374
- if (_h && !_h.done && (_b = _g.return)) _b.call(_g);
375
- }
376
- finally { if (e_2) throw e_2.error; }
377
- }
378
- }
379
- if (this.angulartics2.settings.ga.anonymizeIp) {
380
- ga('set', 'anonymizeIp', true);
381
- try {
382
- for (var _j = __values(this.angulartics2.settings.ga.additionalAccountNames), _k = _j.next(); !_k.done; _k = _j.next()) {
383
- var accountName = _k.value;
384
- ga(accountName + '.set', 'anonymizeIp', true);
385
- }
386
- }
387
- catch (e_3_1) { e_3 = { error: e_3_1 }; }
388
- finally {
389
- try {
390
- if (_k && !_k.done && (_c = _j.return)) _c.call(_j);
391
- }
392
- finally { if (e_3) throw e_3.error; }
393
- }
394
- }
395
- ga('send', 'pageview', path);
396
- try {
397
- for (var _l = __values(this.angulartics2.settings.ga.additionalAccountNames), _m = _l.next(); !_m.done; _m = _l.next()) {
398
- var accountName = _m.value;
399
- ga(accountName + '.send', 'pageview', path);
400
- }
401
- }
402
- catch (e_4_1) { e_4 = { error: e_4_1 }; }
403
- finally {
404
- try {
405
- if (_m && !_m.done && (_d = _l.return)) _d.call(_l);
406
- }
407
- finally { if (e_4) throw e_4.error; }
408
- }
409
- }
410
- };
411
- /**
412
- * Track Event in GA
413
- *
414
- * @param action Associated with the event
415
- * @param properties Comprised of:
416
- * - category (string) and optional
417
- * - label (string)
418
- * - value (integer)
419
- * - noninteraction (boolean)
420
- *
421
- * @link https://developers.google.com/analytics/devguides/collection/gajs/eventTrackerGuide#SettingUpEventTracking
422
- * @link https://developers.google.com/analytics/devguides/collection/analyticsjs/events
423
- */
424
- Angulartics2GoogleAnalytics.prototype.eventTrack = function (action, properties) {
425
- var e_5, _a;
426
- // Google Analytics requires an Event Category
427
- if (!properties || !properties.category) {
428
- properties = properties || {};
429
- properties.category = 'Event';
430
- }
431
- // GA requires that eventValue be an integer, see:
432
- // https://developers.google.com/analytics/devguides/collection/analyticsjs/field-reference#eventValue
433
- // https://github.com/luisfarzati/angulartics/issues/81
434
- if (properties.value) {
435
- var parsed = parseInt(properties.value, 10);
436
- properties.value = isNaN(parsed) ? 0 : parsed;
437
- }
438
- if (typeof ga !== 'undefined') {
439
- var eventOptions = Object.assign({ eventCategory: properties.category, eventAction: action, eventLabel: properties.label, eventValue: properties.value, nonInteraction: properties.noninteraction, page: properties.page || location.hash.substring(1) || location.pathname, userId: this.angulartics2.settings.ga.userId, hitCallback: properties.hitCallback }, this.angulartics2.settings.ga.transport && { transport: this.angulartics2.settings.ga.transport });
440
- // add custom dimensions and metrics
441
- this.setDimensionsAndMetrics(properties);
442
- ga('send', 'event', eventOptions);
443
- try {
444
- for (var _b = __values(this.angulartics2.settings.ga.additionalAccountNames), _c = _b.next(); !_c.done; _c = _b.next()) {
445
- var accountName = _c.value;
446
- ga(accountName + '.send', 'event', eventOptions);
447
- }
448
- }
449
- catch (e_5_1) { e_5 = { error: e_5_1 }; }
450
- finally {
451
- try {
452
- if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
453
- }
454
- finally { if (e_5) throw e_5.error; }
455
- }
456
- }
457
- else if (typeof _gaq !== 'undefined') {
458
- _gaq.push([
459
- '_trackEvent',
460
- properties.category,
461
- action,
462
- properties.label,
463
- properties.value,
464
- properties.noninteraction,
465
- ]);
466
- }
467
- };
468
- /**
469
- * Exception Track Event in GA
470
- *
471
- * @param properties Comprised of the optional fields:
472
- * - fatal (string)
473
- * - description (string)
474
- *
475
- * @https://developers.google.com/analytics/devguides/collection/analyticsjs/exceptions
476
- *
477
- * @link https://developers.google.com/analytics/devguides/collection/analyticsjs/events
478
- */
479
- Angulartics2GoogleAnalytics.prototype.exceptionTrack = function (properties) {
480
- var e_6, _a;
481
- if (properties.fatal === undefined) {
482
- console.log('No "fatal" provided, sending with fatal=true');
483
- properties.fatal = true;
484
- }
485
- properties.exDescription = properties.description;
486
- var eventOptions = {
487
- exFatal: properties.fatal,
488
- exDescription: properties.description,
489
- };
490
- ga('send', 'exception', eventOptions);
491
- try {
492
- for (var _b = __values(this.angulartics2.settings.ga.additionalAccountNames), _c = _b.next(); !_c.done; _c = _b.next()) {
493
- var accountName = _c.value;
494
- ga(accountName + '.send', 'exception', eventOptions);
495
- }
496
- }
497
- catch (e_6_1) { e_6 = { error: e_6_1 }; }
498
- finally {
499
- try {
500
- if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
501
- }
502
- finally { if (e_6) throw e_6.error; }
503
- }
504
- };
505
- /**
506
- * User Timings Event in GA
507
- *
508
- * @param properties Comprised of the mandatory fields:
509
- * - timingCategory (string)
510
- * - timingVar (string)
511
- * - timingValue (number)
512
- * Properties can also have the optional fields:
513
- * - timingLabel (string)
514
- *
515
- * @link https://developers.google.com/analytics/devguides/collection/analyticsjs/user-timings
516
- */
517
- Angulartics2GoogleAnalytics.prototype.userTimings = function (properties) {
518
- var e_7, _a;
519
- if (!properties ||
520
- !properties.timingCategory ||
521
- !properties.timingVar ||
522
- !properties.timingValue) {
523
- console.error('Properties timingCategory, timingVar, and timingValue are required to be set.');
524
- return;
525
- }
526
- if (typeof ga !== 'undefined') {
527
- ga('send', 'timing', properties);
528
- try {
529
- for (var _b = __values(this.angulartics2.settings.ga.additionalAccountNames), _c = _b.next(); !_c.done; _c = _b.next()) {
530
- var accountName = _c.value;
531
- ga(accountName + '.send', 'timing', properties);
532
- }
533
- }
534
- catch (e_7_1) { e_7 = { error: e_7_1 }; }
535
- finally {
536
- try {
537
- if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
538
- }
539
- finally { if (e_7) throw e_7.error; }
540
- }
541
- }
542
- };
543
- Angulartics2GoogleAnalytics.prototype.setUsername = function (userId) {
544
- this.angulartics2.settings.ga.userId = userId;
545
- if (typeof ga === 'undefined') {
546
- return;
547
- }
548
- ga('set', 'userId', userId);
549
- };
550
- Angulartics2GoogleAnalytics.prototype.setUserProperties = function (properties) {
551
- this.setDimensionsAndMetrics(properties);
552
- };
553
- Angulartics2GoogleAnalytics.prototype.setDimensionsAndMetrics = function (properties) {
554
- var _this = this;
555
- if (typeof ga === 'undefined') {
556
- return;
557
- }
558
- // clean previously used dimensions and metrics that will not be overriden
559
- this.dimensionsAndMetrics.forEach(function (elem) {
560
- if (!properties.hasOwnProperty(elem)) {
561
- ga('set', elem, undefined);
562
- _this.angulartics2.settings.ga.additionalAccountNames.forEach(function (accountName) {
563
- ga(accountName + ".set", elem, undefined);
564
- });
565
- }
566
- });
567
- this.dimensionsAndMetrics = [];
568
- // add custom dimensions and metrics
569
- Object.keys(properties).forEach(function (key) {
570
- if (key.lastIndexOf('dimension', 0) === 0 ||
571
- key.lastIndexOf('metric', 0) === 0) {
572
- ga('set', key, properties[key]);
573
- _this.angulartics2.settings.ga.additionalAccountNames.forEach(function (accountName) {
574
- ga(accountName + ".set", key, properties[key]);
575
- });
576
- _this.dimensionsAndMetrics.push(key);
577
- }
578
- });
579
- };
580
- return Angulartics2GoogleAnalytics;
581
- }());
582
- Angulartics2GoogleAnalytics.ɵprov = i0.ɵɵdefineInjectable({ factory: function Angulartics2GoogleAnalytics_Factory() { return new Angulartics2GoogleAnalytics(i0.ɵɵinject(i1.Angulartics2)); }, token: Angulartics2GoogleAnalytics, providedIn: "root" });
583
- Angulartics2GoogleAnalytics.decorators = [
584
- { type: i0.Injectable, args: [{ providedIn: 'root' },] }
585
- ];
586
- Angulartics2GoogleAnalytics.ctorParameters = function () { return [
587
- { type: i1.Angulartics2 }
588
- ]; };
589
-
590
- /**
591
- * Generated bundle index. Do not edit.
592
- */
593
-
594
- exports.Angulartics2GoogleAnalytics = Angulartics2GoogleAnalytics;
595
- exports.GoogleAnalyticsDefaults = GoogleAnalyticsDefaults;
596
-
597
- Object.defineProperty(exports, '__esModule', { value: true });
598
-
599
- })));
600
- //# sourceMappingURL=angulartics2-ga.umd.js.map