iureiure 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (1410) hide show
  1. package/.editorconfig +21 -0
  2. package/.env.example +8 -0
  3. package/.eslintignore +19 -0
  4. package/.eslintrc.json +155 -0
  5. package/.github/ISSUE_TEMPLATE/bug_report.md +50 -0
  6. package/.github/ISSUE_TEMPLATE/feature_request.md +19 -0
  7. package/.github/dependabot.yml +6 -0
  8. package/.github/pull_request_template.md +23 -0
  9. package/.github/workflows/build-and-quality-checks-v3.yml +51 -0
  10. package/.github/workflows/check_pr_title.yml +17 -0
  11. package/.github/workflows/codeql-analysis.yml +70 -0
  12. package/.github/workflows/create-hotfix-branch-v3.yml +21 -0
  13. package/.github/workflows/deploy-beta-v3.yml +82 -0
  14. package/.github/workflows/deploy-dev-v3.yml +71 -0
  15. package/.github/workflows/deploy-npm-v3.yml +169 -0
  16. package/.github/workflows/deploy-prod-v3.yml +194 -0
  17. package/.github/workflows/deploy-sanity-suite.yml +80 -0
  18. package/.github/workflows/deploy-staging-v3.yml +99 -0
  19. package/.github/workflows/draft-new-release-v3.yml +103 -0
  20. package/.github/workflows/housekeeping.yaml +40 -0
  21. package/.github/workflows/publish-new-release-v3.yml +136 -0
  22. package/.github/workflows/rollback-v3.yml +190 -0
  23. package/.github/workflows/test-v3.yml +60 -0
  24. package/.husky/commit-msg +1 -0
  25. package/.husky/pre-commit +1 -0
  26. package/.jscpd.json +17 -0
  27. package/.nvmrc +1 -0
  28. package/.nxignore +3 -0
  29. package/.prettierignore +18 -0
  30. package/.prettierrc +13 -0
  31. package/.versionrc +8 -0
  32. package/CODEOWNERS +2 -0
  33. package/__mocks__/BraveBrowser.js +9 -0
  34. package/assets/integrations/AdobeAnalytics/adobe-analytics-js-heartbeat.js +193 -0
  35. package/assets/integrations/AdobeAnalytics/adobe-analytics-js.js +116 -0
  36. package/assets/rs-logo-full-light.jpg +0 -0
  37. package/babel.config.json +14 -0
  38. package/commitlint.config.js +27 -0
  39. package/examples/angular/sample-app/.editorconfig +16 -0
  40. package/examples/angular/sample-app/README.md +27 -0
  41. package/examples/angular/sample-app/angular.json +83 -0
  42. package/examples/angular/sample-app/package-lock.json +12552 -0
  43. package/examples/angular/sample-app/package.json +39 -0
  44. package/examples/angular/sample-app/src/app/app-routing.module.ts +10 -0
  45. package/examples/angular/sample-app/src/app/app.component.css +0 -0
  46. package/examples/angular/sample-app/src/app/app.component.html +508 -0
  47. package/examples/angular/sample-app/src/app/app.component.spec.ts +33 -0
  48. package/examples/angular/sample-app/src/app/app.component.ts +104 -0
  49. package/examples/angular/sample-app/src/app/app.module.ts +12 -0
  50. package/examples/angular/sample-app/src/assets/.gitkeep +0 -0
  51. package/examples/angular/sample-app/src/favicon.ico +0 -0
  52. package/examples/angular/sample-app/src/index.html +45 -0
  53. package/examples/angular/sample-app/src/main.ts +7 -0
  54. package/examples/angular/sample-app/src/styles.css +1 -0
  55. package/examples/angular/sample-app/tsconfig.app.json +10 -0
  56. package/examples/angular/sample-app/tsconfig.json +30 -0
  57. package/examples/angular/sample-app/tsconfig.spec.json +9 -0
  58. package/examples/chrome-extension/USAGE.md +140 -0
  59. package/examples/chrome-extension/background-script/LICENSE +21 -0
  60. package/examples/chrome-extension/background-script/README.md +105 -0
  61. package/examples/chrome-extension/background-script/foreground.js +7 -0
  62. package/examples/chrome-extension/background-script/logo/logo-128.png +0 -0
  63. package/examples/chrome-extension/background-script/logo/logo-16.png +0 -0
  64. package/examples/chrome-extension/background-script/logo/logo-48.png +0 -0
  65. package/examples/chrome-extension/background-script/logo/logo.svg +138 -0
  66. package/examples/chrome-extension/background-script/manifest.json +36 -0
  67. package/examples/chrome-extension/background-script/popup/popup.css +11 -0
  68. package/examples/chrome-extension/background-script/popup/popup.html +11 -0
  69. package/examples/chrome-extension/background-script/rudderAnalytics.js +5133 -0
  70. package/examples/chrome-extension/background-script/service-worker.js +28 -0
  71. package/examples/chrome-extension/background-script/settings/settings.css +8 -0
  72. package/examples/chrome-extension/background-script/settings/settings.html +12 -0
  73. package/examples/chrome-extension/background-script-websockets/LICENSE +21 -0
  74. package/examples/chrome-extension/background-script-websockets/README.md +101 -0
  75. package/examples/chrome-extension/background-script-websockets/foreground.js +7 -0
  76. package/examples/chrome-extension/background-script-websockets/logo/logo-128.png +0 -0
  77. package/examples/chrome-extension/background-script-websockets/logo/logo-16.png +0 -0
  78. package/examples/chrome-extension/background-script-websockets/logo/logo-48.png +0 -0
  79. package/examples/chrome-extension/background-script-websockets/logo/logo.svg +138 -0
  80. package/examples/chrome-extension/background-script-websockets/manifest.json +37 -0
  81. package/examples/chrome-extension/background-script-websockets/popup/popup.css +11 -0
  82. package/examples/chrome-extension/background-script-websockets/popup/popup.html +11 -0
  83. package/examples/chrome-extension/background-script-websockets/rudderAnalytics.js +5133 -0
  84. package/examples/chrome-extension/background-script-websockets/service-worker.js +60 -0
  85. package/examples/chrome-extension/background-script-websockets/settings/settings.css +8 -0
  86. package/examples/chrome-extension/background-script-websockets/settings/settings.html +12 -0
  87. package/examples/chrome-extension/content-script-v1.1/LICENSE +21 -0
  88. package/examples/chrome-extension/content-script-v1.1/README.md +105 -0
  89. package/examples/chrome-extension/content-script-v1.1/foreground.js +65 -0
  90. package/examples/chrome-extension/content-script-v1.1/logo/logo-128.png +0 -0
  91. package/examples/chrome-extension/content-script-v1.1/logo/logo-16.png +0 -0
  92. package/examples/chrome-extension/content-script-v1.1/logo/logo-48.png +0 -0
  93. package/examples/chrome-extension/content-script-v1.1/logo/logo.svg +138 -0
  94. package/examples/chrome-extension/content-script-v1.1/manifest.json +35 -0
  95. package/examples/chrome-extension/content-script-v1.1/popup/popup.css +11 -0
  96. package/examples/chrome-extension/content-script-v1.1/popup/popup.html +11 -0
  97. package/examples/chrome-extension/content-script-v1.1/service-worker-utils.js +17 -0
  98. package/examples/chrome-extension/content-script-v1.1/service-worker.js +12 -0
  99. package/examples/chrome-extension/content-script-v1.1/settings/settings.css +8 -0
  100. package/examples/chrome-extension/content-script-v1.1/settings/settings.html +12 -0
  101. package/examples/chrome-extension/content-script-v3/LICENSE +21 -0
  102. package/examples/chrome-extension/content-script-v3/README.md +105 -0
  103. package/examples/chrome-extension/content-script-v3/foreground.js +3875 -0
  104. package/examples/chrome-extension/content-script-v3/logo/logo-128.png +0 -0
  105. package/examples/chrome-extension/content-script-v3/logo/logo-16.png +0 -0
  106. package/examples/chrome-extension/content-script-v3/logo/logo-48.png +0 -0
  107. package/examples/chrome-extension/content-script-v3/logo/logo.svg +138 -0
  108. package/examples/chrome-extension/content-script-v3/manifest.json +35 -0
  109. package/examples/chrome-extension/content-script-v3/popup/popup.css +11 -0
  110. package/examples/chrome-extension/content-script-v3/popup/popup.html +11 -0
  111. package/examples/chrome-extension/content-script-v3/service-worker-utils.js +17 -0
  112. package/examples/chrome-extension/content-script-v3/service-worker.js +12 -0
  113. package/examples/chrome-extension/content-script-v3/settings/settings.css +8 -0
  114. package/examples/chrome-extension/content-script-v3/settings/settings.html +12 -0
  115. package/examples/chrome-extension/websocket-server/server.mjs +19 -0
  116. package/examples/gatsby/sample-gatsby-plugin-usage/README.md +49 -0
  117. package/examples/gatsby/sample-gatsby-plugin-usage/gatsby-config.ts +27 -0
  118. package/examples/gatsby/sample-gatsby-plugin-usage/package-lock.json +16070 -0
  119. package/examples/gatsby/sample-gatsby-plugin-usage/package.json +31 -0
  120. package/examples/gatsby/sample-gatsby-plugin-usage/src/images/icon.png +0 -0
  121. package/examples/gatsby/sample-gatsby-plugin-usage/src/pages/404.tsx +49 -0
  122. package/examples/gatsby/sample-gatsby-plugin-usage/src/pages/index.tsx +193 -0
  123. package/examples/gatsby/sample-gatsby-plugin-usage/tsconfig.json +105 -0
  124. package/examples/gatsby/sample-gatsby-site/README.md +49 -0
  125. package/examples/gatsby/sample-gatsby-site/gatsby-config.ts +15 -0
  126. package/examples/gatsby/sample-gatsby-site/package-lock.json +15916 -0
  127. package/examples/gatsby/sample-gatsby-site/package.json +37 -0
  128. package/examples/gatsby/sample-gatsby-site/src/images/icon.png +0 -0
  129. package/examples/gatsby/sample-gatsby-site/src/pages/404.tsx +49 -0
  130. package/examples/gatsby/sample-gatsby-site/src/pages/index.tsx +209 -0
  131. package/examples/gatsby/sample-gatsby-site/tsconfig.json +105 -0
  132. package/examples/html/autotrack-test.html +94 -0
  133. package/examples/html/ecomm_test.html +358 -0
  134. package/examples/html/script-test.html +968 -0
  135. package/examples/html/segment.html +177 -0
  136. package/examples/html/test_poster.jpg +0 -0
  137. package/examples/nextjs/hooks/sample-app/.eslintrc.json +3 -0
  138. package/examples/nextjs/hooks/sample-app/README.md +36 -0
  139. package/examples/nextjs/hooks/sample-app/next.config.js +4 -0
  140. package/examples/nextjs/hooks/sample-app/package-lock.json +4766 -0
  141. package/examples/nextjs/hooks/sample-app/package.json +28 -0
  142. package/examples/nextjs/hooks/sample-app/postcss.config.js +6 -0
  143. package/examples/nextjs/hooks/sample-app/public/next.svg +1 -0
  144. package/examples/nextjs/hooks/sample-app/public/vercel.svg +1 -0
  145. package/examples/nextjs/hooks/sample-app/src/app/favicon.ico +0 -0
  146. package/examples/nextjs/hooks/sample-app/src/app/globals.css +27 -0
  147. package/examples/nextjs/hooks/sample-app/src/app/layout.tsx +55 -0
  148. package/examples/nextjs/hooks/sample-app/src/app/page.tsx +137 -0
  149. package/examples/nextjs/hooks/sample-app/src/app/useRudderAnalytics.ts +29 -0
  150. package/examples/nextjs/hooks/sample-app/tailwind.config.ts +19 -0
  151. package/examples/nextjs/hooks/sample-app/tsconfig.json +27 -0
  152. package/examples/nextjs/js/sample-app/.eslintrc.json +3 -0
  153. package/examples/nextjs/js/sample-app/README.md +36 -0
  154. package/examples/nextjs/js/sample-app/jsconfig.json +7 -0
  155. package/examples/nextjs/js/sample-app/next.config.js +4 -0
  156. package/examples/nextjs/js/sample-app/package-lock.json +4710 -0
  157. package/examples/nextjs/js/sample-app/package.json +24 -0
  158. package/examples/nextjs/js/sample-app/postcss.config.js +6 -0
  159. package/examples/nextjs/js/sample-app/public/next.svg +1 -0
  160. package/examples/nextjs/js/sample-app/public/vercel.svg +1 -0
  161. package/examples/nextjs/js/sample-app/src/app/favicon.ico +0 -0
  162. package/examples/nextjs/js/sample-app/src/app/globals.css +27 -0
  163. package/examples/nextjs/js/sample-app/src/app/layout.js +54 -0
  164. package/examples/nextjs/js/sample-app/src/app/page.js +146 -0
  165. package/examples/nextjs/js/sample-app/tailwind.config.js +17 -0
  166. package/examples/nextjs/page-router/sample-app/.eslintrc.json +3 -0
  167. package/examples/nextjs/page-router/sample-app/README.md +40 -0
  168. package/examples/nextjs/page-router/sample-app/next.config.js +6 -0
  169. package/examples/nextjs/page-router/sample-app/package-lock.json +4270 -0
  170. package/examples/nextjs/page-router/sample-app/package.json +28 -0
  171. package/examples/nextjs/page-router/sample-app/postcss.config.js +6 -0
  172. package/examples/nextjs/page-router/sample-app/public/favicon.ico +0 -0
  173. package/examples/nextjs/page-router/sample-app/public/next.svg +1 -0
  174. package/examples/nextjs/page-router/sample-app/public/vercel.svg +1 -0
  175. package/examples/nextjs/page-router/sample-app/src/pages/_app.tsx +35 -0
  176. package/examples/nextjs/page-router/sample-app/src/pages/_document.tsx +49 -0
  177. package/examples/nextjs/page-router/sample-app/src/pages/api/hello.ts +10 -0
  178. package/examples/nextjs/page-router/sample-app/src/pages/index.tsx +138 -0
  179. package/examples/nextjs/page-router/sample-app/src/pages/page2.tsx +18 -0
  180. package/examples/nextjs/page-router/sample-app/src/styles/globals.css +27 -0
  181. package/examples/nextjs/page-router/sample-app/src/useRudderAnalytics.ts +29 -0
  182. package/examples/nextjs/page-router/sample-app/tailwind.config.ts +19 -0
  183. package/examples/nextjs/page-router/sample-app/tsconfig.json +22 -0
  184. package/examples/nextjs/ts/sample-app/.eslintrc.json +3 -0
  185. package/examples/nextjs/ts/sample-app/README.md +36 -0
  186. package/examples/nextjs/ts/sample-app/next.config.js +4 -0
  187. package/examples/nextjs/ts/sample-app/package-lock.json +4766 -0
  188. package/examples/nextjs/ts/sample-app/package.json +28 -0
  189. package/examples/nextjs/ts/sample-app/postcss.config.js +6 -0
  190. package/examples/nextjs/ts/sample-app/public/next.svg +1 -0
  191. package/examples/nextjs/ts/sample-app/public/vercel.svg +1 -0
  192. package/examples/nextjs/ts/sample-app/src/app/favicon.ico +0 -0
  193. package/examples/nextjs/ts/sample-app/src/app/globals.css +27 -0
  194. package/examples/nextjs/ts/sample-app/src/app/layout.tsx +55 -0
  195. package/examples/nextjs/ts/sample-app/src/app/page.tsx +147 -0
  196. package/examples/nextjs/ts/sample-app/tailwind.config.ts +19 -0
  197. package/examples/nextjs/ts/sample-app/tsconfig.json +27 -0
  198. package/examples/reactjs/hooks/sample-app/README.md +46 -0
  199. package/examples/reactjs/hooks/sample-app/package-lock.json +16203 -0
  200. package/examples/reactjs/hooks/sample-app/package.json +47 -0
  201. package/examples/reactjs/hooks/sample-app/public/favicon.ico +0 -0
  202. package/examples/reactjs/hooks/sample-app/public/index.html +75 -0
  203. package/examples/reactjs/hooks/sample-app/public/logo192.png +0 -0
  204. package/examples/reactjs/hooks/sample-app/public/logo512.png +0 -0
  205. package/examples/reactjs/hooks/sample-app/public/manifest.json +25 -0
  206. package/examples/reactjs/hooks/sample-app/public/robots.txt +3 -0
  207. package/examples/reactjs/hooks/sample-app/src/App.css +38 -0
  208. package/examples/reactjs/hooks/sample-app/src/App.test.tsx +9 -0
  209. package/examples/reactjs/hooks/sample-app/src/App.tsx +95 -0
  210. package/examples/reactjs/hooks/sample-app/src/index.css +32 -0
  211. package/examples/reactjs/hooks/sample-app/src/index.tsx +19 -0
  212. package/examples/reactjs/hooks/sample-app/src/logo.svg +1 -0
  213. package/examples/reactjs/hooks/sample-app/src/react-app-env.d.ts +1 -0
  214. package/examples/reactjs/hooks/sample-app/src/reportWebVitals.ts +15 -0
  215. package/examples/reactjs/hooks/sample-app/src/setupTests.ts +5 -0
  216. package/examples/reactjs/hooks/sample-app/src/useRudderAnalytics.ts +23 -0
  217. package/examples/reactjs/hooks/sample-app/tsconfig.json +20 -0
  218. package/examples/reactjs/js/sample-app/README.md +70 -0
  219. package/examples/reactjs/js/sample-app/package-lock.json +17665 -0
  220. package/examples/reactjs/js/sample-app/package.json +42 -0
  221. package/examples/reactjs/js/sample-app/public/favicon.ico +0 -0
  222. package/examples/reactjs/js/sample-app/public/index.html +75 -0
  223. package/examples/reactjs/js/sample-app/public/logo192.png +0 -0
  224. package/examples/reactjs/js/sample-app/public/logo512.png +0 -0
  225. package/examples/reactjs/js/sample-app/public/manifest.json +25 -0
  226. package/examples/reactjs/js/sample-app/public/robots.txt +3 -0
  227. package/examples/reactjs/js/sample-app/src/App.css +38 -0
  228. package/examples/reactjs/js/sample-app/src/App.js +101 -0
  229. package/examples/reactjs/js/sample-app/src/App.test.js +8 -0
  230. package/examples/reactjs/js/sample-app/src/index.css +34 -0
  231. package/examples/reactjs/js/sample-app/src/index.js +17 -0
  232. package/examples/reactjs/js/sample-app/src/logo.svg +1 -0
  233. package/examples/reactjs/js/sample-app/src/reportWebVitals.js +13 -0
  234. package/examples/reactjs/js/sample-app/src/setupTests.js +5 -0
  235. package/examples/reactjs/ts/sample-app/README.md +46 -0
  236. package/examples/reactjs/ts/sample-app/package-lock.json +17653 -0
  237. package/examples/reactjs/ts/sample-app/package.json +47 -0
  238. package/examples/reactjs/ts/sample-app/public/favicon.ico +0 -0
  239. package/examples/reactjs/ts/sample-app/public/index.html +75 -0
  240. package/examples/reactjs/ts/sample-app/public/logo192.png +0 -0
  241. package/examples/reactjs/ts/sample-app/public/logo512.png +0 -0
  242. package/examples/reactjs/ts/sample-app/public/manifest.json +25 -0
  243. package/examples/reactjs/ts/sample-app/public/robots.txt +3 -0
  244. package/examples/reactjs/ts/sample-app/src/App.css +38 -0
  245. package/examples/reactjs/ts/sample-app/src/App.test.tsx +9 -0
  246. package/examples/reactjs/ts/sample-app/src/App.tsx +101 -0
  247. package/examples/reactjs/ts/sample-app/src/index.css +34 -0
  248. package/examples/reactjs/ts/sample-app/src/index.tsx +19 -0
  249. package/examples/reactjs/ts/sample-app/src/logo.svg +1 -0
  250. package/examples/reactjs/ts/sample-app/src/react-app-env.d.ts +1 -0
  251. package/examples/reactjs/ts/sample-app/src/reportWebVitals.ts +15 -0
  252. package/examples/reactjs/ts/sample-app/src/setupTests.ts +5 -0
  253. package/examples/reactjs/ts/sample-app/tsconfig.json +20 -0
  254. package/examples/reactjs/vite/sample-app/.eslintrc.cjs +18 -0
  255. package/examples/reactjs/vite/sample-app/README.md +27 -0
  256. package/examples/reactjs/vite/sample-app/index.html +45 -0
  257. package/examples/reactjs/vite/sample-app/package-lock.json +3427 -0
  258. package/examples/reactjs/vite/sample-app/package.json +29 -0
  259. package/examples/reactjs/vite/sample-app/public/vite.svg +1 -0
  260. package/examples/reactjs/vite/sample-app/src/App.css +42 -0
  261. package/examples/reactjs/vite/sample-app/src/App.tsx +105 -0
  262. package/examples/reactjs/vite/sample-app/src/assets/react.svg +1 -0
  263. package/examples/reactjs/vite/sample-app/src/index.css +70 -0
  264. package/examples/reactjs/vite/sample-app/src/main.tsx +10 -0
  265. package/examples/reactjs/vite/sample-app/src/vite-env.d.ts +1 -0
  266. package/examples/reactjs/vite/sample-app/tsconfig.json +25 -0
  267. package/examples/reactjs/vite/sample-app/tsconfig.node.json +10 -0
  268. package/examples/reactjs/vite/sample-app/vite.config.ts +7 -0
  269. package/examples/serverless/USAGE.md +85 -0
  270. package/examples/serverless/cloudflare-worker/.editorconfig +13 -0
  271. package/examples/serverless/cloudflare-worker/.prettierrc +6 -0
  272. package/examples/serverless/cloudflare-worker/package-lock.json +2646 -0
  273. package/examples/serverless/cloudflare-worker/package.json +18 -0
  274. package/examples/serverless/cloudflare-worker/src/worker.js +54 -0
  275. package/examples/serverless/cloudflare-worker/wrangler.toml +52 -0
  276. package/examples/serverless/vercel-edge/.eslintrc.json +3 -0
  277. package/examples/serverless/vercel-edge/README.md +34 -0
  278. package/examples/serverless/vercel-edge/app/api/edge-function-example/route.ts +32 -0
  279. package/examples/serverless/vercel-edge/app/favicon.ico +0 -0
  280. package/examples/serverless/vercel-edge/app/globals.css +27 -0
  281. package/examples/serverless/vercel-edge/app/layout.tsx +22 -0
  282. package/examples/serverless/vercel-edge/app/page.tsx +113 -0
  283. package/examples/serverless/vercel-edge/next.config.js +4 -0
  284. package/examples/serverless/vercel-edge/package-lock.json +5351 -0
  285. package/examples/serverless/vercel-edge/package.json +26 -0
  286. package/examples/serverless/vercel-edge/postcss.config.js +6 -0
  287. package/examples/serverless/vercel-edge/public/next.svg +1 -0
  288. package/examples/serverless/vercel-edge/public/vercel.svg +1 -0
  289. package/examples/serverless/vercel-edge/tailwind.config.ts +19 -0
  290. package/examples/serverless/vercel-edge/tsconfig.json +27 -0
  291. package/examples/symfony/USAGE.md +57 -0
  292. package/examples/symfony/sample/.env.test +6 -0
  293. package/examples/symfony/sample/assets/app.js +15 -0
  294. package/examples/symfony/sample/assets/styles/app.css +3 -0
  295. package/examples/symfony/sample/compose.override.yaml +14 -0
  296. package/examples/symfony/sample/compose.yaml +21 -0
  297. package/examples/symfony/sample/composer.json +104 -0
  298. package/examples/symfony/sample/composer.lock +9921 -0
  299. package/examples/symfony/sample/config/bundles.php +15 -0
  300. package/examples/symfony/sample/config/packages/cache.yaml +19 -0
  301. package/examples/symfony/sample/config/packages/debug.yaml +5 -0
  302. package/examples/symfony/sample/config/packages/doctrine.yaml +43 -0
  303. package/examples/symfony/sample/config/packages/doctrine_migrations.yaml +6 -0
  304. package/examples/symfony/sample/config/packages/framework.yaml +24 -0
  305. package/examples/symfony/sample/config/packages/mailer.yaml +3 -0
  306. package/examples/symfony/sample/config/packages/messenger.yaml +24 -0
  307. package/examples/symfony/sample/config/packages/monolog.yaml +61 -0
  308. package/examples/symfony/sample/config/packages/notifier.yaml +12 -0
  309. package/examples/symfony/sample/config/packages/routing.yaml +12 -0
  310. package/examples/symfony/sample/config/packages/security.yaml +40 -0
  311. package/examples/symfony/sample/config/packages/translation.yaml +13 -0
  312. package/examples/symfony/sample/config/packages/twig.yaml +6 -0
  313. package/examples/symfony/sample/config/packages/validator.yaml +13 -0
  314. package/examples/symfony/sample/config/packages/web_profiler.yaml +15 -0
  315. package/examples/symfony/sample/config/packages/webpack_encore.yaml +45 -0
  316. package/examples/symfony/sample/config/preload.php +5 -0
  317. package/examples/symfony/sample/config/routes/framework.yaml +4 -0
  318. package/examples/symfony/sample/config/routes/web_profiler.yaml +8 -0
  319. package/examples/symfony/sample/config/routes.yaml +7 -0
  320. package/examples/symfony/sample/config/services.yaml +24 -0
  321. package/examples/symfony/sample/package-lock.json +8082 -0
  322. package/examples/symfony/sample/package.json +23 -0
  323. package/examples/symfony/sample/phpunit.xml.dist +38 -0
  324. package/examples/symfony/sample/public/index.php +9 -0
  325. package/examples/symfony/sample/src/Controller/LuckyController.php +18 -0
  326. package/examples/symfony/sample/src/Kernel.php +11 -0
  327. package/examples/symfony/sample/symfony.lock +277 -0
  328. package/examples/symfony/sample/templates/base.html.twig +19 -0
  329. package/examples/symfony/sample/templates/lucky/number.html.twig +20 -0
  330. package/examples/symfony/sample/tests/bootstrap.php +11 -0
  331. package/examples/symfony/sample/webpack.config.js +72 -0
  332. package/examples/v1/index.html +229 -0
  333. package/examples/v1.1/index.html +229 -0
  334. package/examples/v2-beacon/index.html +229 -0
  335. package/examples/v3/index.html +266 -0
  336. package/examples/v3-beacon/index.html +270 -0
  337. package/examples/v3-legacy/index.html +266 -0
  338. package/examples/v3-legacy-minimum-plugins/index.html +270 -0
  339. package/examples/v3-minimum-plugins/index.html +270 -0
  340. package/jest/jest.global-setup.js +3 -0
  341. package/jest/jest.polyfills.js +18 -0
  342. package/jest/jest.setup-dom.js +54 -0
  343. package/jest/jsdom-extended.js +26 -0
  344. package/jest.config.ts +5 -0
  345. package/jest.preset.js +83 -0
  346. package/migrations.json +34 -0
  347. package/nx.json +69 -0
  348. package/package.json +170 -0
  349. package/packages/analytics-js/.env.example +9 -0
  350. package/packages/analytics-js/.jscpd.json +17 -0
  351. package/packages/analytics-js/.size-limit.js +31 -0
  352. package/packages/analytics-js/CHANGELOG.md +283 -0
  353. package/packages/analytics-js/CHANGELOG_LATEST.md +2 -0
  354. package/packages/analytics-js/LICENSE +21 -0
  355. package/packages/analytics-js/README.md +100 -0
  356. package/packages/analytics-js/__fixtures__/fixtures.ts +765 -0
  357. package/packages/analytics-js/__fixtures__/msw.handlers.ts +82 -0
  358. package/packages/analytics-js/__fixtures__/msw.server.ts +6 -0
  359. package/packages/analytics-js/__mocks__/remotePlugins/BeaconQueue.ts +9 -0
  360. package/packages/analytics-js/__mocks__/remotePlugins/Bugsnag.ts +10 -0
  361. package/packages/analytics-js/__mocks__/remotePlugins/CustomConsentManager.ts +10 -0
  362. package/packages/analytics-js/__mocks__/remotePlugins/DeviceModeDestinations.ts +9 -0
  363. package/packages/analytics-js/__mocks__/remotePlugins/DeviceModeTransformation.ts +9 -0
  364. package/packages/analytics-js/__mocks__/remotePlugins/ErrorReporting.ts +10 -0
  365. package/packages/analytics-js/__mocks__/remotePlugins/ExternalAnonymousId.ts +10 -0
  366. package/packages/analytics-js/__mocks__/remotePlugins/GoogleLinker.ts +8 -0
  367. package/packages/analytics-js/__mocks__/remotePlugins/KetchConsentManager.ts +10 -0
  368. package/packages/analytics-js/__mocks__/remotePlugins/NativeDestinationQueue.ts +10 -0
  369. package/packages/analytics-js/__mocks__/remotePlugins/OneTrustConsentManager.ts +10 -0
  370. package/packages/analytics-js/__mocks__/remotePlugins/StorageEncryption.ts +9 -0
  371. package/packages/analytics-js/__mocks__/remotePlugins/StorageEncryptionLegacy.ts +9 -0
  372. package/packages/analytics-js/__mocks__/remotePlugins/StorageMigrator.ts +8 -0
  373. package/packages/analytics-js/__mocks__/remotePlugins/XhrQueue.ts +9 -0
  374. package/packages/analytics-js/__tests__/app/RudderAnalytics.test.ts +286 -0
  375. package/packages/analytics-js/__tests__/components/capabilitiesManager/detection/adBlockers.test.ts +78 -0
  376. package/packages/analytics-js/__tests__/components/capabilitiesManager/detection/browser.test.ts +24 -0
  377. package/packages/analytics-js/__tests__/components/capabilitiesManager/detection/clientHint.test.ts +87 -0
  378. package/packages/analytics-js/__tests__/components/capabilitiesManager/detection/dom.test.ts +13 -0
  379. package/packages/analytics-js/__tests__/components/capabilitiesManager/detection/screen.test.ts +13 -0
  380. package/packages/analytics-js/__tests__/components/capabilitiesManager/detection/storage.test.ts +27 -0
  381. package/packages/analytics-js/__tests__/components/configManager/ConfigManager.test.ts +222 -0
  382. package/packages/analytics-js/__tests__/components/configManager/cdnPaths.test.ts +70 -0
  383. package/packages/analytics-js/__tests__/components/configManager/commonUtil.test.ts +531 -0
  384. package/packages/analytics-js/__tests__/components/configManager/dataPlaneResolver.test.ts +163 -0
  385. package/packages/analytics-js/__tests__/components/configManager/validate.test.ts +31 -0
  386. package/packages/analytics-js/__tests__/components/core/Analytics.test.ts +628 -0
  387. package/packages/analytics-js/__tests__/components/eventManager/EventManager.test.ts +78 -0
  388. package/packages/analytics-js/__tests__/components/eventManager/RudderEventFactory.test.ts +514 -0
  389. package/packages/analytics-js/__tests__/components/eventManager/utilities.test.ts +1043 -0
  390. package/packages/analytics-js/__tests__/components/eventRepository/EventRepository.test.ts +324 -0
  391. package/packages/analytics-js/__tests__/components/pluginsManager/.gitkeep +0 -0
  392. package/packages/analytics-js/__tests__/components/preloadBuffer/index.test.ts +130 -0
  393. package/packages/analytics-js/__tests__/components/userSessionManager/UserSessionManager.test.ts +1386 -0
  394. package/packages/analytics-js/__tests__/components/userSessionManager/utils.test.ts +103 -0
  395. package/packages/analytics-js/__tests__/components/utilities/consent.test.ts +192 -0
  396. package/packages/analytics-js/__tests__/components/utilities/destinations.test.ts +201 -0
  397. package/packages/analytics-js/__tests__/components/utilities/event.test.ts +8 -0
  398. package/packages/analytics-js/__tests__/components/utilities/globals.test.ts +42 -0
  399. package/packages/analytics-js/__tests__/components/utilities/page.test.ts +235 -0
  400. package/packages/analytics-js/__tests__/components/utilities/sort.test.ts +17 -0
  401. package/packages/analytics-js/__tests__/components/utilities/statsCollection.test.ts +84 -0
  402. package/packages/analytics-js/__tests__/components/utilities/url.test.ts +51 -0
  403. package/packages/analytics-js/__tests__/services/ErrorHandler/ErrorHandler.test.ts +272 -0
  404. package/packages/analytics-js/__tests__/services/ErrorHandler/processError.test.ts +33 -0
  405. package/packages/analytics-js/__tests__/services/HttpClient/HttpClient.test.ts +255 -0
  406. package/packages/analytics-js/__tests__/services/Logger/Logger.test.ts +204 -0
  407. package/packages/analytics-js/__tests__/services/PluginEngine/PluginEngine.test.ts +206 -0
  408. package/packages/analytics-js/__tests__/services/StoreManager/Store.test.ts +152 -0
  409. package/packages/analytics-js/__tests__/services/StoreManager/StoreManager.test.ts +272 -0
  410. package/packages/analytics-js/__tests__/services/StoreManager/component-cookie/index.test.ts +65 -0
  411. package/packages/analytics-js/__tests__/services/StoreManager/storages/CookieStorage.test.ts +42 -0
  412. package/packages/analytics-js/__tests__/services/StoreManager/storages/InMemoryStorage.test.ts +26 -0
  413. package/packages/analytics-js/__tests__/services/StoreManager/storages/LocalStorage.test.ts +26 -0
  414. package/packages/analytics-js/__tests__/services/StoreManager/storages/sessionStorage.test.ts +26 -0
  415. package/packages/analytics-js/__tests__/services/StoreManager/top-domain/index.test.ts +60 -0
  416. package/packages/analytics-js/babel.config.json +15 -0
  417. package/packages/analytics-js/jest.config.mjs +14 -0
  418. package/packages/analytics-js/package.json +114 -0
  419. package/packages/analytics-js/project.json +138 -0
  420. package/packages/analytics-js/public/index-legacy-only.html +308 -0
  421. package/packages/analytics-js/public/index.html +324 -0
  422. package/packages/analytics-js/public/list_integration_sdks.html +408 -0
  423. package/packages/analytics-js/rollup.config.mjs +387 -0
  424. package/packages/analytics-js/src/app/IRudderStackGlobals.ts +21 -0
  425. package/packages/analytics-js/src/app/RudderAnalytics.ts +296 -0
  426. package/packages/analytics-js/src/browser.ts +55 -0
  427. package/packages/analytics-js/src/components/capabilitiesManager/CapabilitiesManager.ts +199 -0
  428. package/packages/analytics-js/src/components/capabilitiesManager/detection/adBlockers.ts +38 -0
  429. package/packages/analytics-js/src/components/capabilitiesManager/detection/browser.ts +24 -0
  430. package/packages/analytics-js/src/components/capabilitiesManager/detection/clientHint.ts +31 -0
  431. package/packages/analytics-js/src/components/capabilitiesManager/detection/dom.ts +54 -0
  432. package/packages/analytics-js/src/components/capabilitiesManager/detection/index.ts +6 -0
  433. package/packages/analytics-js/src/components/capabilitiesManager/detection/screen.ts +23 -0
  434. package/packages/analytics-js/src/components/capabilitiesManager/detection/storage.ts +77 -0
  435. package/packages/analytics-js/src/components/capabilitiesManager/index.ts +1 -0
  436. package/packages/analytics-js/src/components/capabilitiesManager/polyfill/index.ts +14 -0
  437. package/packages/analytics-js/src/components/capabilitiesManager/types.ts +14 -0
  438. package/packages/analytics-js/src/components/configManager/ConfigManager.ts +218 -0
  439. package/packages/analytics-js/src/components/configManager/constants.ts +21 -0
  440. package/packages/analytics-js/src/components/configManager/index.ts +1 -0
  441. package/packages/analytics-js/src/components/configManager/types.ts +90 -0
  442. package/packages/analytics-js/src/components/configManager/util/cdnPaths.ts +80 -0
  443. package/packages/analytics-js/src/components/configManager/util/commonUtil.ts +262 -0
  444. package/packages/analytics-js/src/components/configManager/util/dataPlaneResolver.ts +79 -0
  445. package/packages/analytics-js/src/components/configManager/util/validate.ts +46 -0
  446. package/packages/analytics-js/src/components/core/Analytics.ts +824 -0
  447. package/packages/analytics-js/src/components/core/IAnalytics.ts +218 -0
  448. package/packages/analytics-js/src/components/core/utilities.ts +12 -0
  449. package/packages/analytics-js/src/components/eventManager/EventManager.ts +80 -0
  450. package/packages/analytics-js/src/components/eventManager/RudderEventFactory.ts +171 -0
  451. package/packages/analytics-js/src/components/eventManager/constants.ts +29 -0
  452. package/packages/analytics-js/src/components/eventManager/index.ts +1 -0
  453. package/packages/analytics-js/src/components/eventManager/types.ts +7 -0
  454. package/packages/analytics-js/src/components/eventManager/utilities.ts +341 -0
  455. package/packages/analytics-js/src/components/eventRepository/EventRepository.ts +225 -0
  456. package/packages/analytics-js/src/components/eventRepository/constants.ts +9 -0
  457. package/packages/analytics-js/src/components/eventRepository/index.ts +1 -0
  458. package/packages/analytics-js/src/components/eventRepository/types.ts +10 -0
  459. package/packages/analytics-js/src/components/eventRepository/utils.ts +53 -0
  460. package/packages/analytics-js/src/components/pluginsManager/PluginsManager.ts +332 -0
  461. package/packages/analytics-js/src/components/pluginsManager/bundledBuildPluginImports.ts +39 -0
  462. package/packages/analytics-js/src/components/pluginsManager/defaultPluginsList.ts +24 -0
  463. package/packages/analytics-js/src/components/pluginsManager/federatedModulesBuildPluginImports.ts +68 -0
  464. package/packages/analytics-js/src/components/pluginsManager/index.ts +1 -0
  465. package/packages/analytics-js/src/components/pluginsManager/pluginNames.ts +29 -0
  466. package/packages/analytics-js/src/components/pluginsManager/pluginsInventory.ts +47 -0
  467. package/packages/analytics-js/src/components/pluginsManager/types.ts +4 -0
  468. package/packages/analytics-js/src/components/preloadBuffer/index.ts +187 -0
  469. package/packages/analytics-js/src/components/preloadBuffer/types.ts +5 -0
  470. package/packages/analytics-js/src/components/userSessionManager/UserSessionManager.ts +642 -0
  471. package/packages/analytics-js/src/components/userSessionManager/constants.ts +25 -0
  472. package/packages/analytics-js/src/components/userSessionManager/index.ts +1 -0
  473. package/packages/analytics-js/src/components/userSessionManager/types.ts +29 -0
  474. package/packages/analytics-js/src/components/userSessionManager/utils.ts +109 -0
  475. package/packages/analytics-js/src/components/utilities/consent.ts +163 -0
  476. package/packages/analytics-js/src/components/utilities/destinations.ts +31 -0
  477. package/packages/analytics-js/src/components/utilities/event.ts +3 -0
  478. package/packages/analytics-js/src/components/utilities/globals.ts +54 -0
  479. package/packages/analytics-js/src/components/utilities/loadOptions.ts +176 -0
  480. package/packages/analytics-js/src/components/utilities/number.ts +23 -0
  481. package/packages/analytics-js/src/components/utilities/page.ts +103 -0
  482. package/packages/analytics-js/src/components/utilities/sort.ts +15 -0
  483. package/packages/analytics-js/src/components/utilities/statsCollection.ts +16 -0
  484. package/packages/analytics-js/src/components/utilities/url.ts +90 -0
  485. package/packages/analytics-js/src/constants/app.ts +24 -0
  486. package/packages/analytics-js/src/constants/encryption.ts +6 -0
  487. package/packages/analytics-js/src/constants/errors.ts +4 -0
  488. package/packages/analytics-js/src/constants/logMessages.ts +282 -0
  489. package/packages/analytics-js/src/constants/queryParams.ts +13 -0
  490. package/packages/analytics-js/src/constants/storage.ts +40 -0
  491. package/packages/analytics-js/src/constants/timeouts.ts +15 -0
  492. package/packages/analytics-js/src/constants/urls.ts +21 -0
  493. package/packages/analytics-js/src/index.ts +40 -0
  494. package/packages/analytics-js/src/services/ErrorHandler/ErrorHandler.ts +204 -0
  495. package/packages/analytics-js/src/services/ErrorHandler/constant.ts +3 -0
  496. package/packages/analytics-js/src/services/ErrorHandler/index.ts +1 -0
  497. package/packages/analytics-js/src/services/ErrorHandler/processError.ts +61 -0
  498. package/packages/analytics-js/src/services/HttpClient/HttpClient.ts +112 -0
  499. package/packages/analytics-js/src/services/HttpClient/index.ts +7 -0
  500. package/packages/analytics-js/src/services/HttpClient/xhr/xhrRequestHandler.ts +140 -0
  501. package/packages/analytics-js/src/services/HttpClient/xhr/xhrResponseHandler.ts +25 -0
  502. package/packages/analytics-js/src/services/Logger/Logger.ts +123 -0
  503. package/packages/analytics-js/src/services/Logger/index.ts +1 -0
  504. package/packages/analytics-js/src/services/Logger/types.ts +6 -0
  505. package/packages/analytics-js/src/services/PluginEngine/PluginEngine.ts +200 -0
  506. package/packages/analytics-js/src/services/PluginEngine/README.md +152 -0
  507. package/packages/analytics-js/src/services/PluginEngine/index.ts +1 -0
  508. package/packages/analytics-js/src/services/StoreManager/Store.ts +218 -0
  509. package/packages/analytics-js/src/services/StoreManager/StoreManager.ts +231 -0
  510. package/packages/analytics-js/src/services/StoreManager/component-cookie/README.md +23 -0
  511. package/packages/analytics-js/src/services/StoreManager/component-cookie/index.ts +138 -0
  512. package/packages/analytics-js/src/services/StoreManager/index.ts +2 -0
  513. package/packages/analytics-js/src/services/StoreManager/storages/CookieStorage.ts +80 -0
  514. package/packages/analytics-js/src/services/StoreManager/storages/InMemoryStorage.ts +66 -0
  515. package/packages/analytics-js/src/services/StoreManager/storages/LocalStorage.ts +68 -0
  516. package/packages/analytics-js/src/services/StoreManager/storages/defaultOptions.ts +39 -0
  517. package/packages/analytics-js/src/services/StoreManager/storages/index.ts +18 -0
  518. package/packages/analytics-js/src/services/StoreManager/storages/sessionStorage.ts +64 -0
  519. package/packages/analytics-js/src/services/StoreManager/storages/storageEngine.ts +91 -0
  520. package/packages/analytics-js/src/services/StoreManager/top-domain/README.md +21 -0
  521. package/packages/analytics-js/src/services/StoreManager/top-domain/index.ts +83 -0
  522. package/packages/analytics-js/src/services/StoreManager/types.ts +32 -0
  523. package/packages/analytics-js/src/services/StoreManager/utils.ts +33 -0
  524. package/packages/analytics-js/src/state/index.ts +53 -0
  525. package/packages/analytics-js/src/state/slices/capabilities.ts +19 -0
  526. package/packages/analytics-js/src/state/slices/consents.ts +16 -0
  527. package/packages/analytics-js/src/state/slices/context.ts +36 -0
  528. package/packages/analytics-js/src/state/slices/eventBuffer.ts +9 -0
  529. package/packages/analytics-js/src/state/slices/lifecycle.ts +19 -0
  530. package/packages/analytics-js/src/state/slices/loadOptions.ts +44 -0
  531. package/packages/analytics-js/src/state/slices/metrics.ts +12 -0
  532. package/packages/analytics-js/src/state/slices/nativeDestinations.ts +15 -0
  533. package/packages/analytics-js/src/state/slices/plugins.ts +13 -0
  534. package/packages/analytics-js/src/state/slices/reporting.ts +11 -0
  535. package/packages/analytics-js/src/state/slices/session.ts +24 -0
  536. package/packages/analytics-js/src/state/slices/source.ts +6 -0
  537. package/packages/analytics-js/src/state/slices/storage.ts +13 -0
  538. package/packages/analytics-js/src/types/index.ts +1 -0
  539. package/packages/analytics-js/src/types/remote-plugins.d.ts +15 -0
  540. package/packages/analytics-js/src/types/rudderanalytics.d.ts +16 -0
  541. package/packages/analytics-js/tsconfig.json +14 -0
  542. package/packages/analytics-js/tsconfig.spec.json +26 -0
  543. package/packages/analytics-js-common/.jscpd.json +17 -0
  544. package/packages/analytics-js-common/.size-limit.js +11 -0
  545. package/packages/analytics-js-common/CHANGELOG.md +180 -0
  546. package/packages/analytics-js-common/CHANGELOG_LATEST.md +7 -0
  547. package/packages/analytics-js-common/LICENSE +21 -0
  548. package/packages/analytics-js-common/README.md +42 -0
  549. package/packages/analytics-js-common/__fixtures__/fixtures.ts +161 -0
  550. package/packages/analytics-js-common/__fixtures__/msw.handlers.ts +82 -0
  551. package/packages/analytics-js-common/__fixtures__/msw.server.ts +6 -0
  552. package/packages/analytics-js-common/__mocks__/.gitkeep +0 -0
  553. package/packages/analytics-js-common/__tests__/services/BufferQueue/BufferQueue.test.ts +55 -0
  554. package/packages/analytics-js-common/__tests__/services/ExternalSrcLoader/ExternalSrcLoader.test.ts +170 -0
  555. package/packages/analytics-js-common/__tests__/utilities/checks.test.ts +95 -0
  556. package/packages/analytics-js-common/__tests__/utilities/destinations.test.ts +44 -0
  557. package/packages/analytics-js-common/__tests__/utilities/detect.test.ts +22 -0
  558. package/packages/analytics-js-common/__tests__/utilities/eventMethodOverloads.test.ts +260 -0
  559. package/packages/analytics-js-common/__tests__/utilities/json.test.ts +155 -0
  560. package/packages/analytics-js-common/__tests__/utilities/object.test.ts +287 -0
  561. package/packages/analytics-js-common/__tests__/utilities/string.test.ts +104 -0
  562. package/packages/analytics-js-common/__tests__/utilities/timezone.test.ts +9 -0
  563. package/packages/analytics-js-common/__tests__/utilities/uuid.test.ts +35 -0
  564. package/packages/analytics-js-common/__tests__/v1.1/utils/ObjectUtils.test.js +113 -0
  565. package/packages/analytics-js-common/__tests__/v1.1/utils/errorHandler.test.js +60 -0
  566. package/packages/analytics-js-common/babel.config.json +14 -0
  567. package/packages/analytics-js-common/jest.config.mjs +14 -0
  568. package/packages/analytics-js-common/package.json +92 -0
  569. package/packages/analytics-js-common/project.json +107 -0
  570. package/packages/analytics-js-common/src/constants/QueueStatuses.ts +10 -0
  571. package/packages/analytics-js-common/src/constants/consent.ts +6 -0
  572. package/packages/analytics-js-common/src/constants/destDisplayNamesToFileNamesMap.ts +243 -0
  573. package/packages/analytics-js-common/src/constants/destinationNames.ts +312 -0
  574. package/packages/analytics-js-common/src/constants/htmlAttributes.ts +3 -0
  575. package/packages/analytics-js-common/src/constants/index.ts +11 -0
  576. package/packages/analytics-js-common/src/constants/integrations/ActiveCampaign/constants.js +18 -0
  577. package/packages/analytics-js-common/src/constants/integrations/AdobeAnalytics/constants.ts +18 -0
  578. package/packages/analytics-js-common/src/constants/integrations/Adroll/constants.ts +14 -0
  579. package/packages/analytics-js-common/src/constants/integrations/Amplitude/constants.ts +13 -0
  580. package/packages/analytics-js-common/src/constants/integrations/Appcues/constants.ts +13 -0
  581. package/packages/analytics-js-common/src/constants/integrations/Axeptio/constants.ts +12 -0
  582. package/packages/analytics-js-common/src/constants/integrations/BingAds/constants.ts +16 -0
  583. package/packages/analytics-js-common/src/constants/integrations/Braze/constants.ts +22 -0
  584. package/packages/analytics-js-common/src/constants/integrations/Bugsnag/constants.ts +12 -0
  585. package/packages/analytics-js-common/src/constants/integrations/Chartbeat/constants.ts +14 -0
  586. package/packages/analytics-js-common/src/constants/integrations/Clevertap/constants.ts +12 -0
  587. package/packages/analytics-js-common/src/constants/integrations/CommandBar/constants.ts +21 -0
  588. package/packages/analytics-js-common/src/constants/integrations/CommonIntegrationsConstant/constants.ts +194 -0
  589. package/packages/analytics-js-common/src/constants/integrations/Comscore/constants.ts +15 -0
  590. package/packages/analytics-js-common/src/constants/integrations/ConvertFlow/constants.ts +19 -0
  591. package/packages/analytics-js-common/src/constants/integrations/Criteo/constants.ts +22 -0
  592. package/packages/analytics-js-common/src/constants/integrations/CustomerIO/constants.ts +14 -0
  593. package/packages/analytics-js-common/src/constants/integrations/DCMFloodlight/constants.ts +19 -0
  594. package/packages/analytics-js-common/src/constants/integrations/Drip/constants.ts +12 -0
  595. package/packages/analytics-js-common/src/constants/integrations/Engage/constants.ts +27 -0
  596. package/packages/analytics-js-common/src/constants/integrations/FacebookPixel/constants.ts +89 -0
  597. package/packages/analytics-js-common/src/constants/integrations/Fullstory/constants.ts +17 -0
  598. package/packages/analytics-js-common/src/constants/integrations/GA/constants.ts +14 -0
  599. package/packages/analytics-js-common/src/constants/integrations/GA360/constants.ts +18 -0
  600. package/packages/analytics-js-common/src/constants/integrations/GA4/constants.ts +19 -0
  601. package/packages/analytics-js-common/src/constants/integrations/GoogleAds/constants.ts +15 -0
  602. package/packages/analytics-js-common/src/constants/integrations/GoogleOptimize/constants.ts +17 -0
  603. package/packages/analytics-js-common/src/constants/integrations/GoogleTagManager/constants.ts +14 -0
  604. package/packages/analytics-js-common/src/constants/integrations/Heap/constants.ts +13 -0
  605. package/packages/analytics-js-common/src/constants/integrations/Hotjar/constants.ts +14 -0
  606. package/packages/analytics-js-common/src/constants/integrations/HubSpot/constants.ts +15 -0
  607. package/packages/analytics-js-common/src/constants/integrations/INTERCOM/constants.ts +12 -0
  608. package/packages/analytics-js-common/src/constants/integrations/Iterable/constants.ts +12 -0
  609. package/packages/analytics-js-common/src/constants/integrations/June/constants.ts +12 -0
  610. package/packages/analytics-js-common/src/constants/integrations/Keen/constants.ts +14 -0
  611. package/packages/analytics-js-common/src/constants/integrations/Kissmetrics/constants.ts +12 -0
  612. package/packages/analytics-js-common/src/constants/integrations/Klaviyo/constants.ts +12 -0
  613. package/packages/analytics-js-common/src/constants/integrations/LaunchDarkly/constants.ts +15 -0
  614. package/packages/analytics-js-common/src/constants/integrations/Lemnisk/constants.ts +17 -0
  615. package/packages/analytics-js-common/src/constants/integrations/LinkedInInsightTag/constants.ts +20 -0
  616. package/packages/analytics-js-common/src/constants/integrations/LiveChat/constants.ts +16 -0
  617. package/packages/analytics-js-common/src/constants/integrations/Lotame/constants.ts +12 -0
  618. package/packages/analytics-js-common/src/constants/integrations/Lytics/constants.ts +12 -0
  619. package/packages/analytics-js-common/src/constants/integrations/Matomo/constants.ts +12 -0
  620. package/packages/analytics-js-common/src/constants/integrations/MicrosoftClarity/constants.ts +18 -0
  621. package/packages/analytics-js-common/src/constants/integrations/Mixpanel/constants.ts +15 -0
  622. package/packages/analytics-js-common/src/constants/integrations/MoEngage/constants.ts +16 -0
  623. package/packages/analytics-js-common/src/constants/integrations/Mouseflow/constants.ts +18 -0
  624. package/packages/analytics-js-common/src/constants/integrations/Ninetailed/constants.ts +13 -0
  625. package/packages/analytics-js-common/src/constants/integrations/Olark/constants.ts +12 -0
  626. package/packages/analytics-js-common/src/constants/integrations/Optimizely/constants.ts +12 -0
  627. package/packages/analytics-js-common/src/constants/integrations/Pendo/constants.ts +12 -0
  628. package/packages/analytics-js-common/src/constants/integrations/PinterestTag/constants.ts +23 -0
  629. package/packages/analytics-js-common/src/constants/integrations/Podsights/constants.ts +24 -0
  630. package/packages/analytics-js-common/src/constants/integrations/PostAffiliatePro/constants.ts +17 -0
  631. package/packages/analytics-js-common/src/constants/integrations/Posthog/constants.ts +16 -0
  632. package/packages/analytics-js-common/src/constants/integrations/ProfitWell/constants.ts +16 -0
  633. package/packages/analytics-js-common/src/constants/integrations/Qualaroo/constants.ts +12 -0
  634. package/packages/analytics-js-common/src/constants/integrations/Qualtrics/constants.ts +12 -0
  635. package/packages/analytics-js-common/src/constants/integrations/QuantumMetric/constants.ts +17 -0
  636. package/packages/analytics-js-common/src/constants/integrations/QuoraPixel/constants.ts +19 -0
  637. package/packages/analytics-js-common/src/constants/integrations/RedditPixel/constants.ts +17 -0
  638. package/packages/analytics-js-common/src/constants/integrations/Refiner/constants.ts +12 -0
  639. package/packages/analytics-js-common/src/constants/integrations/Rockerbox/constants.ts +16 -0
  640. package/packages/analytics-js-common/src/constants/integrations/RollBar/constants.ts +17 -0
  641. package/packages/analytics-js-common/src/constants/integrations/Satismeter/constants.ts +12 -0
  642. package/packages/analytics-js-common/src/constants/integrations/Sendinblue/constants.ts +37 -0
  643. package/packages/analytics-js-common/src/constants/integrations/Sentry/constants.ts +12 -0
  644. package/packages/analytics-js-common/src/constants/integrations/Shynet/constants.ts +18 -0
  645. package/packages/analytics-js-common/src/constants/integrations/SnapEngage/constants.ts +16 -0
  646. package/packages/analytics-js-common/src/constants/integrations/SnapPixel/constants.ts +17 -0
  647. package/packages/analytics-js-common/src/constants/integrations/SpotifyPixel/constants.ts +20 -0
  648. package/packages/analytics-js-common/src/constants/integrations/Sprig/constants.ts +12 -0
  649. package/packages/analytics-js-common/src/constants/integrations/TVSquared/constants.ts +18 -0
  650. package/packages/analytics-js-common/src/constants/integrations/TiktokAds/constants.ts +97 -0
  651. package/packages/analytics-js-common/src/constants/integrations/VWO/constants.ts +17 -0
  652. package/packages/analytics-js-common/src/constants/integrations/Vero/constants.ts +12 -0
  653. package/packages/analytics-js-common/src/constants/integrations/Woopra/constants.ts +12 -0
  654. package/packages/analytics-js-common/src/constants/integrations/YandexMetrica/constants.ts +14 -0
  655. package/packages/analytics-js-common/src/constants/integrationsConfig.ts +5 -0
  656. package/packages/analytics-js-common/src/constants/logMessages.ts +24 -0
  657. package/packages/analytics-js-common/src/constants/loggerContexts.ts +33 -0
  658. package/packages/analytics-js-common/src/constants/storages.ts +9 -0
  659. package/packages/analytics-js-common/src/constants/timeouts.ts +3 -0
  660. package/packages/analytics-js-common/src/constants/urls.ts +4 -0
  661. package/packages/analytics-js-common/src/index.ts +4 -0
  662. package/packages/analytics-js-common/src/services/BufferQueue/BufferQueue.ts +37 -0
  663. package/packages/analytics-js-common/src/services/ExternalSrcLoader/ExternalSrcLoader.ts +63 -0
  664. package/packages/analytics-js-common/src/services/ExternalSrcLoader/index.ts +1 -0
  665. package/packages/analytics-js-common/src/services/ExternalSrcLoader/jsFileLoader.ts +124 -0
  666. package/packages/analytics-js-common/src/services/ExternalSrcLoader/types.ts +26 -0
  667. package/packages/analytics-js-common/src/types/ApiObject.ts +14 -0
  668. package/packages/analytics-js-common/src/types/ApplicationLifecycle.ts +12 -0
  669. package/packages/analytics-js-common/src/types/ApplicationState.ts +172 -0
  670. package/packages/analytics-js-common/src/types/Consent.ts +47 -0
  671. package/packages/analytics-js-common/src/types/DataResidency.ts +9 -0
  672. package/packages/analytics-js-common/src/types/Destination.ts +85 -0
  673. package/packages/analytics-js-common/src/types/ErrorHandler.ts +39 -0
  674. package/packages/analytics-js-common/src/types/Event.ts +54 -0
  675. package/packages/analytics-js-common/src/types/EventApi.ts +45 -0
  676. package/packages/analytics-js-common/src/types/EventContext.ts +26 -0
  677. package/packages/analytics-js-common/src/types/HttpClient.ts +63 -0
  678. package/packages/analytics-js-common/src/types/IRudderAnalytics.ts +204 -0
  679. package/packages/analytics-js-common/src/types/Integration.ts +18 -0
  680. package/packages/analytics-js-common/src/types/LoadOptions.ts +159 -0
  681. package/packages/analytics-js-common/src/types/Logger.ts +19 -0
  682. package/packages/analytics-js-common/src/types/Nullable.ts +1 -0
  683. package/packages/analytics-js-common/src/types/PluginEngine.ts +41 -0
  684. package/packages/analytics-js-common/src/types/PluginsManager.ts +29 -0
  685. package/packages/analytics-js-common/src/types/Session.ts +8 -0
  686. package/packages/analytics-js-common/src/types/Source.ts +21 -0
  687. package/packages/analytics-js-common/src/types/Storage.ts +49 -0
  688. package/packages/analytics-js-common/src/types/Store.ts +82 -0
  689. package/packages/analytics-js-common/src/types/UserSessionStorage.ts +10 -0
  690. package/packages/analytics-js-common/src/types/traits.ts +91 -0
  691. package/packages/analytics-js-common/src/utilities/checks.ts +77 -0
  692. package/packages/analytics-js-common/src/utilities/crypto.ts +6 -0
  693. package/packages/analytics-js-common/src/utilities/destinations.ts +31 -0
  694. package/packages/analytics-js-common/src/utilities/detect.ts +8 -0
  695. package/packages/analytics-js-common/src/utilities/errors.ts +20 -0
  696. package/packages/analytics-js-common/src/utilities/eventMethodOverloads.ts +407 -0
  697. package/packages/analytics-js-common/src/utilities/http.ts +13 -0
  698. package/packages/analytics-js-common/src/utilities/index.ts +14 -0
  699. package/packages/analytics-js-common/src/utilities/json.ts +69 -0
  700. package/packages/analytics-js-common/src/utilities/object.ts +119 -0
  701. package/packages/analytics-js-common/src/utilities/string.ts +64 -0
  702. package/packages/analytics-js-common/src/utilities/timestamp.ts +10 -0
  703. package/packages/analytics-js-common/src/utilities/timezone.ts +11 -0
  704. package/packages/analytics-js-common/src/utilities/url.ts +3 -0
  705. package/packages/analytics-js-common/src/utilities/uuId.ts +13 -0
  706. package/packages/analytics-js-common/src/v1.1/utils/ObjectUtils.js +54 -0
  707. package/packages/analytics-js-common/src/v1.1/utils/ScriptLoader.js +51 -0
  708. package/packages/analytics-js-common/src/v1.1/utils/client_server_name.js +82 -0
  709. package/packages/analytics-js-common/src/v1.1/utils/config_to_integration_names.js +83 -0
  710. package/packages/analytics-js-common/src/v1.1/utils/constants.js +15 -0
  711. package/packages/analytics-js-common/src/v1.1/utils/errorHandler.js +88 -0
  712. package/packages/analytics-js-common/src/v1.1/utils/index.ts +10 -0
  713. package/packages/analytics-js-common/src/v1.1/utils/integration_cname.js +164 -0
  714. package/packages/analytics-js-common/src/v1.1/utils/logUtil.js +51 -0
  715. package/packages/analytics-js-common/src/v1.1/utils/notifyError.js +16 -0
  716. package/packages/analytics-js-common/src/v1.1/utils/storage/cookie.js +98 -0
  717. package/packages/analytics-js-common/src/v1.1/utils/storage/index.js +5 -0
  718. package/packages/analytics-js-common/src/v1.1/utils/storage/storage.js +384 -0
  719. package/packages/analytics-js-common/src/v1.1/utils/storage/store.js +79 -0
  720. package/packages/analytics-js-common/src/v1.1/utils/storage/v3DecryptionUtils.js +19 -0
  721. package/packages/analytics-js-common/tsconfig.json +14 -0
  722. package/packages/analytics-js-common/tsconfig.spec.json +23 -0
  723. package/packages/analytics-js-common/types/rudderanalytics.d.ts +16 -0
  724. package/packages/analytics-js-integrations/.jscpd.json +17 -0
  725. package/packages/analytics-js-integrations/.size-limit.js +11 -0
  726. package/packages/analytics-js-integrations/CHANGELOG.md +241 -0
  727. package/packages/analytics-js-integrations/CHANGELOG_LATEST.md +12 -0
  728. package/packages/analytics-js-integrations/LICENSE +21 -0
  729. package/packages/analytics-js-integrations/README.md +35 -0
  730. package/packages/analytics-js-integrations/__fixtures__/.gitkeep +0 -0
  731. package/packages/analytics-js-integrations/__mocks__/.gitkeep +0 -0
  732. package/packages/analytics-js-integrations/__tests__/common/common.test.js +49 -0
  733. package/packages/analytics-js-integrations/__tests__/integrations/Amplitude/browser.test.js +926 -0
  734. package/packages/analytics-js-integrations/__tests__/integrations/Amplitude/util.test.js +190 -0
  735. package/packages/analytics-js-integrations/__tests__/integrations/Appcues/appcues.test.js +163 -0
  736. package/packages/analytics-js-integrations/__tests__/integrations/BingAds/__fixtures__/data.js +17 -0
  737. package/packages/analytics-js-integrations/__tests__/integrations/BingAds/browser.test.js +166 -0
  738. package/packages/analytics-js-integrations/__tests__/integrations/BingAds/utils.test.js +138 -0
  739. package/packages/analytics-js-integrations/__tests__/integrations/Braze/browser.test.js +1077 -0
  740. package/packages/analytics-js-integrations/__tests__/integrations/Clevertap/browser.test.js +43 -0
  741. package/packages/analytics-js-integrations/__tests__/integrations/CommandBar/browser.test.js +115 -0
  742. package/packages/analytics-js-integrations/__tests__/integrations/FacebookPixel/browser.test.js +410 -0
  743. package/packages/analytics-js-integrations/__tests__/integrations/FacebookPixel/utils.test.js +775 -0
  744. package/packages/analytics-js-integrations/__tests__/integrations/Fullstory/browser.test.js +173 -0
  745. package/packages/analytics-js-integrations/__tests__/integrations/GA/browser.test.js +179 -0
  746. package/packages/analytics-js-integrations/__tests__/integrations/GA4/__mocks__/data.js +1563 -0
  747. package/packages/analytics-js-integrations/__tests__/integrations/GA4/browser.test.js +212 -0
  748. package/packages/analytics-js-integrations/__tests__/integrations/GA4/utils.test.js +380 -0
  749. package/packages/analytics-js-integrations/__tests__/integrations/GoogleAds/__fixtures__/data.js +256 -0
  750. package/packages/analytics-js-integrations/__tests__/integrations/GoogleAds/browser.test.js +372 -0
  751. package/packages/analytics-js-integrations/__tests__/integrations/GoogleAds/utils.test.js +121 -0
  752. package/packages/analytics-js-integrations/__tests__/integrations/Hotjar/browser.test.js +108 -0
  753. package/packages/analytics-js-integrations/__tests__/integrations/Intercom/browser.test.js +135 -0
  754. package/packages/analytics-js-integrations/__tests__/integrations/Intercom/util.test.js +69 -0
  755. package/packages/analytics-js-integrations/__tests__/integrations/LaunchDarkly/__fixtures__/data.js +61 -0
  756. package/packages/analytics-js-integrations/__tests__/integrations/LaunchDarkly/browser.test.js +151 -0
  757. package/packages/analytics-js-integrations/__tests__/integrations/LaunchDarkly/utils.test.js +36 -0
  758. package/packages/analytics-js-integrations/__tests__/integrations/Lemnisk/browser.test.js +172 -0
  759. package/packages/analytics-js-integrations/__tests__/integrations/Matomo/browser.test.js +208 -0
  760. package/packages/analytics-js-integrations/__tests__/integrations/Mixpanel/browser.test.js +117 -0
  761. package/packages/analytics-js-integrations/__tests__/integrations/Mixpanel/util.test.js +504 -0
  762. package/packages/analytics-js-integrations/__tests__/integrations/Ninetailed/browser.test.js +148 -0
  763. package/packages/analytics-js-integrations/__tests__/integrations/PinterestTag/__fixtures__/data.js +24 -0
  764. package/packages/analytics-js-integrations/__tests__/integrations/PinterestTag/utils.test.js +19 -0
  765. package/packages/analytics-js-integrations/__tests__/integrations/Podsights/utils.test.js +394 -0
  766. package/packages/analytics-js-integrations/__tests__/integrations/Posthog/browser.test.js +420 -0
  767. package/packages/analytics-js-integrations/__tests__/integrations/Posthog/utils.test.js +111 -0
  768. package/packages/analytics-js-integrations/__tests__/integrations/SpotifyPixel/browser.test.js +630 -0
  769. package/packages/analytics-js-integrations/__tests__/integrations/Sprig/browser.test.js +85 -0
  770. package/packages/analytics-js-integrations/__tests__/integrations/TikTokAds/browser.test.js +421 -0
  771. package/packages/analytics-js-integrations/__tests__/integrations/VWO/browser.test.js +143 -0
  772. package/packages/analytics-js-integrations/__tests__/integrations/VWO/utils.test.js +36 -0
  773. package/packages/analytics-js-integrations/__tests__/utils/camelcase.test.js +29 -0
  774. package/packages/analytics-js-integrations/__tests__/utils/commonUtils.test.js +347 -0
  775. package/packages/analytics-js-integrations/__tests__/utils/utils.test.js +337 -0
  776. package/packages/analytics-js-integrations/babel.config.json +14 -0
  777. package/packages/analytics-js-integrations/jest.config.mjs +21 -0
  778. package/packages/analytics-js-integrations/package.json +143 -0
  779. package/packages/analytics-js-integrations/project.json +106 -0
  780. package/packages/analytics-js-integrations/public/list_integration_sdks.html +408 -0
  781. package/packages/analytics-js-integrations/rollup.config.mjs +151 -0
  782. package/packages/analytics-js-integrations/scripts/integrationBuildScript.js +79 -0
  783. package/packages/analytics-js-integrations/src/integrations/ActiveCampaign/browser.js +53 -0
  784. package/packages/analytics-js-integrations/src/integrations/ActiveCampaign/index.js +1 -0
  785. package/packages/analytics-js-integrations/src/integrations/ActiveCampaign/nativeSdkLoader.js +24 -0
  786. package/packages/analytics-js-integrations/src/integrations/AdobeAnalytics/browser.js +279 -0
  787. package/packages/analytics-js-integrations/src/integrations/AdobeAnalytics/eCommHandle.js +56 -0
  788. package/packages/analytics-js-integrations/src/integrations/AdobeAnalytics/heartbeatHandle.js +268 -0
  789. package/packages/analytics-js-integrations/src/integrations/AdobeAnalytics/index.js +1 -0
  790. package/packages/analytics-js-integrations/src/integrations/AdobeAnalytics/util.js +681 -0
  791. package/packages/analytics-js-integrations/src/integrations/Adroll/browser.js +123 -0
  792. package/packages/analytics-js-integrations/src/integrations/Adroll/index.js +1 -0
  793. package/packages/analytics-js-integrations/src/integrations/Adroll/util.js +48 -0
  794. package/packages/analytics-js-integrations/src/integrations/Amplitude/browser.js +374 -0
  795. package/packages/analytics-js-integrations/src/integrations/Amplitude/index.js +1 -0
  796. package/packages/analytics-js-integrations/src/integrations/Amplitude/nativeSdkLoader.js +114 -0
  797. package/packages/analytics-js-integrations/src/integrations/Amplitude/test/test_amplitude.html +157 -0
  798. package/packages/analytics-js-integrations/src/integrations/Amplitude/utils.js +67 -0
  799. package/packages/analytics-js-integrations/src/integrations/Appcues/browser.js +89 -0
  800. package/packages/analytics-js-integrations/src/integrations/Appcues/index.js +1 -0
  801. package/packages/analytics-js-integrations/src/integrations/Axeptio/browser.js +61 -0
  802. package/packages/analytics-js-integrations/src/integrations/Axeptio/index.js +1 -0
  803. package/packages/analytics-js-integrations/src/integrations/Axeptio/nativeSdkLoader.js +14 -0
  804. package/packages/analytics-js-integrations/src/integrations/Axeptio/utils.js +16 -0
  805. package/packages/analytics-js-integrations/src/integrations/BingAds/browser.js +81 -0
  806. package/packages/analytics-js-integrations/src/integrations/BingAds/index.js +1 -0
  807. package/packages/analytics-js-integrations/src/integrations/BingAds/nativeSdkLoader.js +30 -0
  808. package/packages/analytics-js-integrations/src/integrations/BingAds/utils.js +100 -0
  809. package/packages/analytics-js-integrations/src/integrations/Braze/browser.js +297 -0
  810. package/packages/analytics-js-integrations/src/integrations/Braze/index.js +1 -0
  811. package/packages/analytics-js-integrations/src/integrations/Braze/nativeSdkLoader.js +35 -0
  812. package/packages/analytics-js-integrations/src/integrations/Braze/utils.js +51 -0
  813. package/packages/analytics-js-integrations/src/integrations/Bugsnag/browser.js +62 -0
  814. package/packages/analytics-js-integrations/src/integrations/Bugsnag/index.js +1 -0
  815. package/packages/analytics-js-integrations/src/integrations/Chartbeat/browser.js +143 -0
  816. package/packages/analytics-js-integrations/src/integrations/Chartbeat/index.js +1 -0
  817. package/packages/analytics-js-integrations/src/integrations/Chartbeat/nativeSdkLoader.js +7 -0
  818. package/packages/analytics-js-integrations/src/integrations/Clevertap/browser.js +202 -0
  819. package/packages/analytics-js-integrations/src/integrations/Clevertap/index.js +1 -0
  820. package/packages/analytics-js-integrations/src/integrations/Clevertap/utils.js +17 -0
  821. package/packages/analytics-js-integrations/src/integrations/CommandBar/browser.js +78 -0
  822. package/packages/analytics-js-integrations/src/integrations/CommandBar/index.js +1 -0
  823. package/packages/analytics-js-integrations/src/integrations/CommandBar/nativeSdkLoader.js +85 -0
  824. package/packages/analytics-js-integrations/src/integrations/Comscore/browser.js +126 -0
  825. package/packages/analytics-js-integrations/src/integrations/Comscore/index.js +1 -0
  826. package/packages/analytics-js-integrations/src/integrations/Comscore/nativeSdkLoader.js +10 -0
  827. package/packages/analytics-js-integrations/src/integrations/ConvertFlow/browser.js +60 -0
  828. package/packages/analytics-js-integrations/src/integrations/ConvertFlow/index.js +1 -0
  829. package/packages/analytics-js-integrations/src/integrations/ConvertFlow/utils.js +107 -0
  830. package/packages/analytics-js-integrations/src/integrations/Criteo/browser.js +144 -0
  831. package/packages/analytics-js-integrations/src/integrations/Criteo/index.js +1 -0
  832. package/packages/analytics-js-integrations/src/integrations/Criteo/utils.js +346 -0
  833. package/packages/analytics-js-integrations/src/integrations/CustomerIO/browser.js +85 -0
  834. package/packages/analytics-js-integrations/src/integrations/CustomerIO/index.js +1 -0
  835. package/packages/analytics-js-integrations/src/integrations/CustomerIO/nativeSdkLoader.js +33 -0
  836. package/packages/analytics-js-integrations/src/integrations/DCMFloodlight/browser.js +228 -0
  837. package/packages/analytics-js-integrations/src/integrations/DCMFloodlight/index.js +1 -0
  838. package/packages/analytics-js-integrations/src/integrations/DCMFloodlight/utils.js +353 -0
  839. package/packages/analytics-js-integrations/src/integrations/Drip/browser.js +165 -0
  840. package/packages/analytics-js-integrations/src/integrations/Drip/index.js +1 -0
  841. package/packages/analytics-js-integrations/src/integrations/Drip/nativeSdkLoader.js +10 -0
  842. package/packages/analytics-js-integrations/src/integrations/Drip/utils.js +29 -0
  843. package/packages/analytics-js-integrations/src/integrations/Engage/browser.js +119 -0
  844. package/packages/analytics-js-integrations/src/integrations/Engage/index.js +1 -0
  845. package/packages/analytics-js-integrations/src/integrations/Engage/nativeSdkLoader.js +25 -0
  846. package/packages/analytics-js-integrations/src/integrations/Engage/utils.js +69 -0
  847. package/packages/analytics-js-integrations/src/integrations/FacebookPixel/browser.js +326 -0
  848. package/packages/analytics-js-integrations/src/integrations/FacebookPixel/index.js +1 -0
  849. package/packages/analytics-js-integrations/src/integrations/FacebookPixel/utils.js +332 -0
  850. package/packages/analytics-js-integrations/src/integrations/Fullstory/browser.js +175 -0
  851. package/packages/analytics-js-integrations/src/integrations/Fullstory/index.js +1 -0
  852. package/packages/analytics-js-integrations/src/integrations/Fullstory/nativeSdkLoader.js +69 -0
  853. package/packages/analytics-js-integrations/src/integrations/Fullstory/utils.js +17 -0
  854. package/packages/analytics-js-integrations/src/integrations/GA/browser.js +817 -0
  855. package/packages/analytics-js-integrations/src/integrations/GA/index.js +1 -0
  856. package/packages/analytics-js-integrations/src/integrations/GA360/browser.js +58 -0
  857. package/packages/analytics-js-integrations/src/integrations/GA360/index.js +1 -0
  858. package/packages/analytics-js-integrations/src/integrations/GA4/browser.js +264 -0
  859. package/packages/analytics-js-integrations/src/integrations/GA4/config.js +296 -0
  860. package/packages/analytics-js-integrations/src/integrations/GA4/index.js +1 -0
  861. package/packages/analytics-js-integrations/src/integrations/GA4/utils.js +374 -0
  862. package/packages/analytics-js-integrations/src/integrations/GoogleAds/browser.js +219 -0
  863. package/packages/analytics-js-integrations/src/integrations/GoogleAds/browser.test.js +16 -0
  864. package/packages/analytics-js-integrations/src/integrations/GoogleAds/index.js +1 -0
  865. package/packages/analytics-js-integrations/src/integrations/GoogleAds/nativeSdkLoader.js +28 -0
  866. package/packages/analytics-js-integrations/src/integrations/GoogleAds/utils.js +135 -0
  867. package/packages/analytics-js-integrations/src/integrations/GoogleOptimize/browser.js +81 -0
  868. package/packages/analytics-js-integrations/src/integrations/GoogleOptimize/index.js +1 -0
  869. package/packages/analytics-js-integrations/src/integrations/GoogleTagManager/browser.js +96 -0
  870. package/packages/analytics-js-integrations/src/integrations/GoogleTagManager/index.js +1 -0
  871. package/packages/analytics-js-integrations/src/integrations/GoogleTagManager/nativeSdkLoader.js +21 -0
  872. package/packages/analytics-js-integrations/src/integrations/Heap/browser.js +64 -0
  873. package/packages/analytics-js-integrations/src/integrations/Heap/index.js +1 -0
  874. package/packages/analytics-js-integrations/src/integrations/Heap/nativeSdkLoader.js +40 -0
  875. package/packages/analytics-js-integrations/src/integrations/Heap/util.js +23 -0
  876. package/packages/analytics-js-integrations/src/integrations/Hotjar/browser.js +79 -0
  877. package/packages/analytics-js-integrations/src/integrations/Hotjar/index.js +1 -0
  878. package/packages/analytics-js-integrations/src/integrations/Hotjar/nativeSdkLoader.js +21 -0
  879. package/packages/analytics-js-integrations/src/integrations/HubSpot/browser.js +91 -0
  880. package/packages/analytics-js-integrations/src/integrations/HubSpot/index.js +1 -0
  881. package/packages/analytics-js-integrations/src/integrations/INTERCOM/browser.js +112 -0
  882. package/packages/analytics-js-integrations/src/integrations/INTERCOM/index.js +1 -0
  883. package/packages/analytics-js-integrations/src/integrations/INTERCOM/nativeSdkLoader.js +46 -0
  884. package/packages/analytics-js-integrations/src/integrations/INTERCOM/utils.js +68 -0
  885. package/packages/analytics-js-integrations/src/integrations/Iterable/browser.js +179 -0
  886. package/packages/analytics-js-integrations/src/integrations/Iterable/index.js +1 -0
  887. package/packages/analytics-js-integrations/src/integrations/Iterable/utils.js +127 -0
  888. package/packages/analytics-js-integrations/src/integrations/June/browser.js +96 -0
  889. package/packages/analytics-js-integrations/src/integrations/June/index.js +1 -0
  890. package/packages/analytics-js-integrations/src/integrations/Keen/browser.js +150 -0
  891. package/packages/analytics-js-integrations/src/integrations/Keen/index.js +1 -0
  892. package/packages/analytics-js-integrations/src/integrations/Kissmetrics/browser.js +245 -0
  893. package/packages/analytics-js-integrations/src/integrations/Kissmetrics/index.js +1 -0
  894. package/packages/analytics-js-integrations/src/integrations/Kissmetrics/nativeSdkLoader.js +23 -0
  895. package/packages/analytics-js-integrations/src/integrations/Klaviyo/browser.js +197 -0
  896. package/packages/analytics-js-integrations/src/integrations/Klaviyo/index.js +1 -0
  897. package/packages/analytics-js-integrations/src/integrations/Klaviyo/util.js +91 -0
  898. package/packages/analytics-js-integrations/src/integrations/LaunchDarkly/browser.js +75 -0
  899. package/packages/analytics-js-integrations/src/integrations/LaunchDarkly/index.js +1 -0
  900. package/packages/analytics-js-integrations/src/integrations/LaunchDarkly/utils.js +40 -0
  901. package/packages/analytics-js-integrations/src/integrations/Lemnisk/browser.js +81 -0
  902. package/packages/analytics-js-integrations/src/integrations/Lemnisk/index.js +1 -0
  903. package/packages/analytics-js-integrations/src/integrations/Lemnisk/nativeSdkLoader.js +34 -0
  904. package/packages/analytics-js-integrations/src/integrations/LinkedInInsightTag/browser.js +79 -0
  905. package/packages/analytics-js-integrations/src/integrations/LinkedInInsightTag/index.js +1 -0
  906. package/packages/analytics-js-integrations/src/integrations/LiveChat/browser.js +81 -0
  907. package/packages/analytics-js-integrations/src/integrations/LiveChat/index.js +1 -0
  908. package/packages/analytics-js-integrations/src/integrations/LiveChat/nativeSdkLoader.js +40 -0
  909. package/packages/analytics-js-integrations/src/integrations/LiveChat/util.js +71 -0
  910. package/packages/analytics-js-integrations/src/integrations/Lotame/LotameStorage.js +21 -0
  911. package/packages/analytics-js-integrations/src/integrations/Lotame/browser.js +152 -0
  912. package/packages/analytics-js-integrations/src/integrations/Lotame/index.js +1 -0
  913. package/packages/analytics-js-integrations/src/integrations/Lytics/browser.js +103 -0
  914. package/packages/analytics-js-integrations/src/integrations/Lytics/index.js +1 -0
  915. package/packages/analytics-js-integrations/src/integrations/Lytics/nativeSdkLoader.js +77 -0
  916. package/packages/analytics-js-integrations/src/integrations/Lytics/test/script-test-lytics.html +250 -0
  917. package/packages/analytics-js-integrations/src/integrations/Matomo/browser.js +184 -0
  918. package/packages/analytics-js-integrations/src/integrations/Matomo/index.js +1 -0
  919. package/packages/analytics-js-integrations/src/integrations/Matomo/nativeSdkLoader.js +20 -0
  920. package/packages/analytics-js-integrations/src/integrations/Matomo/util.js +433 -0
  921. package/packages/analytics-js-integrations/src/integrations/MicrosoftClarity/browser.js +69 -0
  922. package/packages/analytics-js-integrations/src/integrations/MicrosoftClarity/index.js +1 -0
  923. package/packages/analytics-js-integrations/src/integrations/MicrosoftClarity/nativeSdkLoader.js +22 -0
  924. package/packages/analytics-js-integrations/src/integrations/Mixpanel/browser.js +353 -0
  925. package/packages/analytics-js-integrations/src/integrations/Mixpanel/index.js +1 -0
  926. package/packages/analytics-js-integrations/src/integrations/Mixpanel/nativeSdkLoader.js +71 -0
  927. package/packages/analytics-js-integrations/src/integrations/Mixpanel/util.js +288 -0
  928. package/packages/analytics-js-integrations/src/integrations/MoEngage/browser.js +131 -0
  929. package/packages/analytics-js-integrations/src/integrations/MoEngage/index.js +1 -0
  930. package/packages/analytics-js-integrations/src/integrations/MoEngage/nativeSdkLoader.js +65 -0
  931. package/packages/analytics-js-integrations/src/integrations/MoEngage/test/script-test-moengage.html +216 -0
  932. package/packages/analytics-js-integrations/src/integrations/Mouseflow/browser.js +97 -0
  933. package/packages/analytics-js-integrations/src/integrations/Mouseflow/index.js +1 -0
  934. package/packages/analytics-js-integrations/src/integrations/Mouseflow/utils.js +41 -0
  935. package/packages/analytics-js-integrations/src/integrations/Ninetailed/browser.js +65 -0
  936. package/packages/analytics-js-integrations/src/integrations/Ninetailed/index.js +1 -0
  937. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/README.md +70 -0
  938. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/package-lock.json +17843 -0
  939. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/package.json +43 -0
  940. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/public/favicon.ico +0 -0
  941. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/public/index.html +75 -0
  942. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/public/logo192.png +0 -0
  943. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/public/logo512.png +0 -0
  944. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/public/manifest.json +25 -0
  945. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/public/robots.txt +3 -0
  946. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/src/App.css +38 -0
  947. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/src/App.js +108 -0
  948. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/src/index.css +34 -0
  949. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/src/index.js +17 -0
  950. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/src/logo.svg +1 -0
  951. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/src/reportWebVitals.js +13 -0
  952. package/packages/analytics-js-integrations/src/integrations/Ninetailed/sample-app/src/setupTests.js +5 -0
  953. package/packages/analytics-js-integrations/src/integrations/Olark/browser.js +92 -0
  954. package/packages/analytics-js-integrations/src/integrations/Olark/index.js +1 -0
  955. package/packages/analytics-js-integrations/src/integrations/Olark/nativeSdkLoader.js +31 -0
  956. package/packages/analytics-js-integrations/src/integrations/Olark/utils.js +51 -0
  957. package/packages/analytics-js-integrations/src/integrations/Optimizely/browser.js +244 -0
  958. package/packages/analytics-js-integrations/src/integrations/Optimizely/index.js +1 -0
  959. package/packages/analytics-js-integrations/src/integrations/Optimizely/utils.js +23 -0
  960. package/packages/analytics-js-integrations/src/integrations/Pendo/browser.js +123 -0
  961. package/packages/analytics-js-integrations/src/integrations/Pendo/index.js +1 -0
  962. package/packages/analytics-js-integrations/src/integrations/Pendo/nativeSdkLoader.js +32 -0
  963. package/packages/analytics-js-integrations/src/integrations/PinterestTag/browser.js +240 -0
  964. package/packages/analytics-js-integrations/src/integrations/PinterestTag/index.js +1 -0
  965. package/packages/analytics-js-integrations/src/integrations/PinterestTag/nativeSdkLoader.js +19 -0
  966. package/packages/analytics-js-integrations/src/integrations/PinterestTag/propertyMappingConfig.js +57 -0
  967. package/packages/analytics-js-integrations/src/integrations/PinterestTag/test/input.js +180 -0
  968. package/packages/analytics-js-integrations/src/integrations/PinterestTag/test/output.js +129 -0
  969. package/packages/analytics-js-integrations/src/integrations/PinterestTag/utils.js +50 -0
  970. package/packages/analytics-js-integrations/src/integrations/Podsights/browser.js +179 -0
  971. package/packages/analytics-js-integrations/src/integrations/Podsights/index.js +1 -0
  972. package/packages/analytics-js-integrations/src/integrations/Podsights/utils.js +64 -0
  973. package/packages/analytics-js-integrations/src/integrations/PostAffiliatePro/browser.js +132 -0
  974. package/packages/analytics-js-integrations/src/integrations/PostAffiliatePro/index.js +1 -0
  975. package/packages/analytics-js-integrations/src/integrations/PostAffiliatePro/utils.js +40 -0
  976. package/packages/analytics-js-integrations/src/integrations/Posthog/browser.js +147 -0
  977. package/packages/analytics-js-integrations/src/integrations/Posthog/index.js +1 -0
  978. package/packages/analytics-js-integrations/src/integrations/Posthog/nativeSdkLoader.js +48 -0
  979. package/packages/analytics-js-integrations/src/integrations/Posthog/test/test_posthog.html +77 -0
  980. package/packages/analytics-js-integrations/src/integrations/Posthog/utils.js +52 -0
  981. package/packages/analytics-js-integrations/src/integrations/ProfitWell/browser.js +71 -0
  982. package/packages/analytics-js-integrations/src/integrations/ProfitWell/index.js +1 -0
  983. package/packages/analytics-js-integrations/src/integrations/ProfitWell/nativeSdkLoader.js +25 -0
  984. package/packages/analytics-js-integrations/src/integrations/Qualaroo/browser.js +116 -0
  985. package/packages/analytics-js-integrations/src/integrations/Qualaroo/index.js +1 -0
  986. package/packages/analytics-js-integrations/src/integrations/Qualaroo/utils.js +83 -0
  987. package/packages/analytics-js-integrations/src/integrations/Qualtrics/browser.js +92 -0
  988. package/packages/analytics-js-integrations/src/integrations/Qualtrics/index.js +1 -0
  989. package/packages/analytics-js-integrations/src/integrations/Qualtrics/nativeSdkLoader.js +79 -0
  990. package/packages/analytics-js-integrations/src/integrations/QuantumMetric/browser.js +54 -0
  991. package/packages/analytics-js-integrations/src/integrations/QuantumMetric/index.js +1 -0
  992. package/packages/analytics-js-integrations/src/integrations/QuoraPixel/browser.js +77 -0
  993. package/packages/analytics-js-integrations/src/integrations/QuoraPixel/index.js +1 -0
  994. package/packages/analytics-js-integrations/src/integrations/QuoraPixel/nativeSdkLoader.js +21 -0
  995. package/packages/analytics-js-integrations/src/integrations/RedditPixel/browser.js +103 -0
  996. package/packages/analytics-js-integrations/src/integrations/RedditPixel/index.js +1 -0
  997. package/packages/analytics-js-integrations/src/integrations/RedditPixel/nativeSdkLoader.js +21 -0
  998. package/packages/analytics-js-integrations/src/integrations/Refiner/browser.js +117 -0
  999. package/packages/analytics-js-integrations/src/integrations/Refiner/index.js +1 -0
  1000. package/packages/analytics-js-integrations/src/integrations/Refiner/nativeSdkLoader.js +20 -0
  1001. package/packages/analytics-js-integrations/src/integrations/Refiner/utils.js +44 -0
  1002. package/packages/analytics-js-integrations/src/integrations/Rockerbox/browser.js +90 -0
  1003. package/packages/analytics-js-integrations/src/integrations/Rockerbox/index.js +1 -0
  1004. package/packages/analytics-js-integrations/src/integrations/Rockerbox/nativeSdkLoader.js +32 -0
  1005. package/packages/analytics-js-integrations/src/integrations/RollBar/browser.js +93 -0
  1006. package/packages/analytics-js-integrations/src/integrations/RollBar/index.js +1 -0
  1007. package/packages/analytics-js-integrations/src/integrations/RollBar/nativeSdkLoader.js +383 -0
  1008. package/packages/analytics-js-integrations/src/integrations/Satismeter/browser.js +92 -0
  1009. package/packages/analytics-js-integrations/src/integrations/Satismeter/index.js +1 -0
  1010. package/packages/analytics-js-integrations/src/integrations/Satismeter/nativeSdkLoader.js +23 -0
  1011. package/packages/analytics-js-integrations/src/integrations/Satismeter/util.js +54 -0
  1012. package/packages/analytics-js-integrations/src/integrations/Sendinblue/browser.js +111 -0
  1013. package/packages/analytics-js-integrations/src/integrations/Sendinblue/index.js +1 -0
  1014. package/packages/analytics-js-integrations/src/integrations/Sendinblue/nativeSdkLoader.js +36 -0
  1015. package/packages/analytics-js-integrations/src/integrations/Sendinblue/utils.js +129 -0
  1016. package/packages/analytics-js-integrations/src/integrations/Sentry/browser.js +120 -0
  1017. package/packages/analytics-js-integrations/src/integrations/Sentry/index.js +1 -0
  1018. package/packages/analytics-js-integrations/src/integrations/Sentry/utils.js +84 -0
  1019. package/packages/analytics-js-integrations/src/integrations/Shynet/browser.js +99 -0
  1020. package/packages/analytics-js-integrations/src/integrations/Shynet/index.js +1 -0
  1021. package/packages/analytics-js-integrations/src/integrations/SnapEngage/browser.js +74 -0
  1022. package/packages/analytics-js-integrations/src/integrations/SnapEngage/index.js +1 -0
  1023. package/packages/analytics-js-integrations/src/integrations/SnapEngage/nativeSdkLoader.js +24 -0
  1024. package/packages/analytics-js-integrations/src/integrations/SnapEngage/util.js +63 -0
  1025. package/packages/analytics-js-integrations/src/integrations/SnapPixel/browser.js +226 -0
  1026. package/packages/analytics-js-integrations/src/integrations/SnapPixel/index.js +1 -0
  1027. package/packages/analytics-js-integrations/src/integrations/SnapPixel/nativeSdkLoader.js +20 -0
  1028. package/packages/analytics-js-integrations/src/integrations/SnapPixel/util.js +214 -0
  1029. package/packages/analytics-js-integrations/src/integrations/SpotifyPixel/browser.js +180 -0
  1030. package/packages/analytics-js-integrations/src/integrations/SpotifyPixel/index.js +1 -0
  1031. package/packages/analytics-js-integrations/src/integrations/Sprig/browser.js +89 -0
  1032. package/packages/analytics-js-integrations/src/integrations/Sprig/index.js +1 -0
  1033. package/packages/analytics-js-integrations/src/integrations/Sprig/nativeSdkLoader.js +19 -0
  1034. package/packages/analytics-js-integrations/src/integrations/TVSquared/browser.js +99 -0
  1035. package/packages/analytics-js-integrations/src/integrations/TVSquared/index.js +1 -0
  1036. package/packages/analytics-js-integrations/src/integrations/TVSquared/utils.js +41 -0
  1037. package/packages/analytics-js-integrations/src/integrations/TiktokAds/browser.js +111 -0
  1038. package/packages/analytics-js-integrations/src/integrations/TiktokAds/index.js +1 -0
  1039. package/packages/analytics-js-integrations/src/integrations/TiktokAds/nativeSdkLoader.js +52 -0
  1040. package/packages/analytics-js-integrations/src/integrations/TiktokAds/util.js +70 -0
  1041. package/packages/analytics-js-integrations/src/integrations/VWO/browser.js +155 -0
  1042. package/packages/analytics-js-integrations/src/integrations/VWO/index.js +1 -0
  1043. package/packages/analytics-js-integrations/src/integrations/VWO/nativeSdkLoader.js +64 -0
  1044. package/packages/analytics-js-integrations/src/integrations/VWO/utils.js +42 -0
  1045. package/packages/analytics-js-integrations/src/integrations/Vero/browser.js +166 -0
  1046. package/packages/analytics-js-integrations/src/integrations/Vero/index.js +1 -0
  1047. package/packages/analytics-js-integrations/src/integrations/Vero/utils.js +17 -0
  1048. package/packages/analytics-js-integrations/src/integrations/Woopra/browser.js +82 -0
  1049. package/packages/analytics-js-integrations/src/integrations/Woopra/index.js +1 -0
  1050. package/packages/analytics-js-integrations/src/integrations/Woopra/nativeSdkLoader.js +43 -0
  1051. package/packages/analytics-js-integrations/src/integrations/YandexMetrica/browser.js +139 -0
  1052. package/packages/analytics-js-integrations/src/integrations/YandexMetrica/index.js +1 -0
  1053. package/packages/analytics-js-integrations/src/integrations/YandexMetrica/nativeSdkLoader.js +35 -0
  1054. package/packages/analytics-js-integrations/src/integrations/YandexMetrica/utils.js +140 -0
  1055. package/packages/analytics-js-integrations/src/integrations/index.js +163 -0
  1056. package/packages/analytics-js-integrations/src/utils/camelcase.js +48 -0
  1057. package/packages/analytics-js-integrations/src/utils/commonUtils.js +214 -0
  1058. package/packages/analytics-js-integrations/src/utils/constants.js +4 -0
  1059. package/packages/analytics-js-integrations/src/utils/logger.js +106 -0
  1060. package/packages/analytics-js-integrations/src/utils/utils.js +585 -0
  1061. package/packages/analytics-js-integrations/tsconfig.json +8 -0
  1062. package/packages/analytics-js-integrations/tsconfig.spec.json +26 -0
  1063. package/packages/analytics-js-plugins/.jscpd.json +17 -0
  1064. package/packages/analytics-js-plugins/.size-limit.js +16 -0
  1065. package/packages/analytics-js-plugins/CHANGELOG.md +212 -0
  1066. package/packages/analytics-js-plugins/CHANGELOG_LATEST.md +7 -0
  1067. package/packages/analytics-js-plugins/LICENSE +21 -0
  1068. package/packages/analytics-js-plugins/README.md +57 -0
  1069. package/packages/analytics-js-plugins/__fixtures__/.gitkeep +0 -0
  1070. package/packages/analytics-js-plugins/__fixtures__/fixtures.ts +174 -0
  1071. package/packages/analytics-js-plugins/__fixtures__/msw.handlers.js +45 -0
  1072. package/packages/analytics-js-plugins/__fixtures__/msw.server.js +6 -0
  1073. package/packages/analytics-js-plugins/__mocks__/.gitkeep +0 -0
  1074. package/packages/analytics-js-plugins/__tests__/beaconQueue/.gitkeep +0 -0
  1075. package/packages/analytics-js-plugins/__tests__/bugsnag/index.test.ts +116 -0
  1076. package/packages/analytics-js-plugins/__tests__/bugsnag/utils.test.ts +555 -0
  1077. package/packages/analytics-js-plugins/__tests__/customConsentManager/index.test.ts +264 -0
  1078. package/packages/analytics-js-plugins/__tests__/deviceModeDestinations/utils.test.ts +260 -0
  1079. package/packages/analytics-js-plugins/__tests__/deviceModeTransformation/.gitkeep +0 -0
  1080. package/packages/analytics-js-plugins/__tests__/deviceModeTransformation/index.test.ts +287 -0
  1081. package/packages/analytics-js-plugins/__tests__/deviceModeTransformation/utilities.test.ts +22 -0
  1082. package/packages/analytics-js-plugins/__tests__/errorReporting/index.test.ts +102 -0
  1083. package/packages/analytics-js-plugins/__tests__/externalAnonymousId/.gitkeep +0 -0
  1084. package/packages/analytics-js-plugins/__tests__/googleLinker/.gitkeep +0 -0
  1085. package/packages/analytics-js-plugins/__tests__/ketchConsentManager/index.test.ts +498 -0
  1086. package/packages/analytics-js-plugins/__tests__/ketchConsentManager/utils.test.ts +189 -0
  1087. package/packages/analytics-js-plugins/__tests__/nativeDestinationQueue/utilities.test.ts +98 -0
  1088. package/packages/analytics-js-plugins/__tests__/oneTrustConsentManager/index.test.ts +395 -0
  1089. package/packages/analytics-js-plugins/__tests__/storageEncryption/index.test.ts +37 -0
  1090. package/packages/analytics-js-plugins/__tests__/storageEncryptionLegacy/index.test.ts +41 -0
  1091. package/packages/analytics-js-plugins/__tests__/storageMigrator/.gitkeep +0 -0
  1092. package/packages/analytics-js-plugins/__tests__/storageMigrator/index.test.ts +144 -0
  1093. package/packages/analytics-js-plugins/__tests__/utilities/destination.test.ts +133 -0
  1094. package/packages/analytics-js-plugins/__tests__/utilities/queue.test.ts +327 -0
  1095. package/packages/analytics-js-plugins/__tests__/utilities/retryQueue/RetryQueue.test.ts +1077 -0
  1096. package/packages/analytics-js-plugins/__tests__/utilities/retryQueue/Schedule.test.ts +78 -0
  1097. package/packages/analytics-js-plugins/__tests__/xhrQueue/index.test.ts +320 -0
  1098. package/packages/analytics-js-plugins/__tests__/xhrQueue/utilities.test.ts +388 -0
  1099. package/packages/analytics-js-plugins/babel.config.json +14 -0
  1100. package/packages/analytics-js-plugins/jest.config.mjs +14 -0
  1101. package/packages/analytics-js-plugins/package.json +106 -0
  1102. package/packages/analytics-js-plugins/project.json +131 -0
  1103. package/packages/analytics-js-plugins/public/.gitkeep +0 -0
  1104. package/packages/analytics-js-plugins/rollup.config.mjs +245 -0
  1105. package/packages/analytics-js-plugins/src/beaconQueue/constants.ts +27 -0
  1106. package/packages/analytics-js-plugins/src/beaconQueue/index.ts +146 -0
  1107. package/packages/analytics-js-plugins/src/beaconQueue/logMessages.ts +24 -0
  1108. package/packages/analytics-js-plugins/src/beaconQueue/types.ts +12 -0
  1109. package/packages/analytics-js-plugins/src/beaconQueue/utilities.ts +68 -0
  1110. package/packages/analytics-js-plugins/src/bugsnag/constants.ts +52 -0
  1111. package/packages/analytics-js-plugins/src/bugsnag/index.ts +65 -0
  1112. package/packages/analytics-js-plugins/src/bugsnag/logMessages.ts +19 -0
  1113. package/packages/analytics-js-plugins/src/bugsnag/utils.ts +214 -0
  1114. package/packages/analytics-js-plugins/src/customConsentManager/constants.ts +3 -0
  1115. package/packages/analytics-js-plugins/src/customConsentManager/index.ts +86 -0
  1116. package/packages/analytics-js-plugins/src/customConsentManager/logMessages.ts +3 -0
  1117. package/packages/analytics-js-plugins/src/deviceModeDestinations/constants.ts +6 -0
  1118. package/packages/analytics-js-plugins/src/deviceModeDestinations/index.ts +138 -0
  1119. package/packages/analytics-js-plugins/src/deviceModeDestinations/logMessages.ts +24 -0
  1120. package/packages/analytics-js-plugins/src/deviceModeDestinations/types.ts +28 -0
  1121. package/packages/analytics-js-plugins/src/deviceModeDestinations/utils.ts +249 -0
  1122. package/packages/analytics-js-plugins/src/deviceModeTransformation/constants.ts +12 -0
  1123. package/packages/analytics-js-plugins/src/deviceModeTransformation/index.ts +111 -0
  1124. package/packages/analytics-js-plugins/src/deviceModeTransformation/logMessages.ts +28 -0
  1125. package/packages/analytics-js-plugins/src/deviceModeTransformation/types.ts +38 -0
  1126. package/packages/analytics-js-plugins/src/deviceModeTransformation/utilities.ts +155 -0
  1127. package/packages/analytics-js-plugins/src/errorReporting/index.ts +62 -0
  1128. package/packages/analytics-js-plugins/src/errorReporting/logMessages.ts +3 -0
  1129. package/packages/analytics-js-plugins/src/externalAnonymousId/constants.ts +5 -0
  1130. package/packages/analytics-js-plugins/src/externalAnonymousId/index.ts +47 -0
  1131. package/packages/analytics-js-plugins/src/externalAnonymousId/util.ts +25 -0
  1132. package/packages/analytics-js-plugins/src/googleLinker/base64Decoder.ts +33 -0
  1133. package/packages/analytics-js-plugins/src/googleLinker/constants.ts +1 -0
  1134. package/packages/analytics-js-plugins/src/googleLinker/crc32.ts +44 -0
  1135. package/packages/analytics-js-plugins/src/googleLinker/index.ts +30 -0
  1136. package/packages/analytics-js-plugins/src/googleLinker/userLib.ts +16 -0
  1137. package/packages/analytics-js-plugins/src/googleLinker/utils.ts +156 -0
  1138. package/packages/analytics-js-plugins/src/index.ts +15 -0
  1139. package/packages/analytics-js-plugins/src/ketchConsentManager/constants.ts +4 -0
  1140. package/packages/analytics-js-plugins/src/ketchConsentManager/index.ts +120 -0
  1141. package/packages/analytics-js-plugins/src/ketchConsentManager/logMessages.ts +15 -0
  1142. package/packages/analytics-js-plugins/src/ketchConsentManager/types.ts +11 -0
  1143. package/packages/analytics-js-plugins/src/ketchConsentManager/utils.ts +95 -0
  1144. package/packages/analytics-js-plugins/src/nativeDestinationQueue/constants.ts +9 -0
  1145. package/packages/analytics-js-plugins/src/nativeDestinationQueue/index.ts +159 -0
  1146. package/packages/analytics-js-plugins/src/nativeDestinationQueue/logMessages.ts +14 -0
  1147. package/packages/analytics-js-plugins/src/nativeDestinationQueue/utilities.ts +81 -0
  1148. package/packages/analytics-js-plugins/src/oneTrustConsentManager/constants.ts +3 -0
  1149. package/packages/analytics-js-plugins/src/oneTrustConsentManager/index.ts +131 -0
  1150. package/packages/analytics-js-plugins/src/oneTrustConsentManager/logMessages.ts +8 -0
  1151. package/packages/analytics-js-plugins/src/oneTrustConsentManager/types.ts +4 -0
  1152. package/packages/analytics-js-plugins/src/shared-chunks/common.ts +13 -0
  1153. package/packages/analytics-js-plugins/src/shared-chunks/deviceModeDestinations.ts +3 -0
  1154. package/packages/analytics-js-plugins/src/storageEncryption/constants.ts +1 -0
  1155. package/packages/analytics-js-plugins/src/storageEncryption/encryptionUtils.ts +14 -0
  1156. package/packages/analytics-js-plugins/src/storageEncryption/index.ts +26 -0
  1157. package/packages/analytics-js-plugins/src/storageEncryptionLegacy/constants.ts +2 -0
  1158. package/packages/analytics-js-plugins/src/storageEncryptionLegacy/index.ts +26 -0
  1159. package/packages/analytics-js-plugins/src/storageEncryptionLegacy/legacyEncryptionUtils.ts +18 -0
  1160. package/packages/analytics-js-plugins/src/storageMigrator/constants.ts +3 -0
  1161. package/packages/analytics-js-plugins/src/storageMigrator/index.ts +59 -0
  1162. package/packages/analytics-js-plugins/src/storageMigrator/logMessages.ts +4 -0
  1163. package/packages/analytics-js-plugins/src/types/plugins.ts +69 -0
  1164. package/packages/analytics-js-plugins/src/utilities/constants.ts +3 -0
  1165. package/packages/analytics-js-plugins/src/utilities/destination.ts +40 -0
  1166. package/packages/analytics-js-plugins/src/utilities/eventsDelivery.ts +85 -0
  1167. package/packages/analytics-js-plugins/src/utilities/retryQueue/README.md +135 -0
  1168. package/packages/analytics-js-plugins/src/utilities/retryQueue/RetryQueue.ts +736 -0
  1169. package/packages/analytics-js-plugins/src/utilities/retryQueue/Schedule.ts +101 -0
  1170. package/packages/analytics-js-plugins/src/utilities/retryQueue/constants.ts +32 -0
  1171. package/packages/analytics-js-plugins/src/utilities/retryQueue/logMessages.ts +9 -0
  1172. package/packages/analytics-js-plugins/src/utilities/retryQueue/types.ts +21 -0
  1173. package/packages/analytics-js-plugins/src/xhrQueue/constants.ts +23 -0
  1174. package/packages/analytics-js-plugins/src/xhrQueue/index.ts +158 -0
  1175. package/packages/analytics-js-plugins/src/xhrQueue/logMessages.ts +6 -0
  1176. package/packages/analytics-js-plugins/src/xhrQueue/types.ts +16 -0
  1177. package/packages/analytics-js-plugins/src/xhrQueue/utilities.ts +103 -0
  1178. package/packages/analytics-js-plugins/tsconfig.json +14 -0
  1179. package/packages/analytics-js-plugins/tsconfig.spec.json +24 -0
  1180. package/packages/analytics-js-service-worker/.env.example +8 -0
  1181. package/packages/analytics-js-service-worker/.jscpd.json +17 -0
  1182. package/packages/analytics-js-service-worker/.size-limit.js +11 -0
  1183. package/packages/analytics-js-service-worker/CHANGELOG.md +91 -0
  1184. package/packages/analytics-js-service-worker/CHANGELOG_LATEST.md +7 -0
  1185. package/packages/analytics-js-service-worker/LICENSE +21 -0
  1186. package/packages/analytics-js-service-worker/README.md +74 -0
  1187. package/packages/analytics-js-service-worker/__fixtures__/fixtures.ts +79 -0
  1188. package/packages/analytics-js-service-worker/__fixtures__/msw.server.ts +13 -0
  1189. package/packages/analytics-js-service-worker/__mocks__/.gitkeep +0 -0
  1190. package/packages/analytics-js-service-worker/__tests__/Analytics.test.ts +120 -0
  1191. package/packages/analytics-js-service-worker/__tests__/loosely-validate-event/index.test.ts +140 -0
  1192. package/packages/analytics-js-service-worker/babel.config.json +15 -0
  1193. package/packages/analytics-js-service-worker/jest.config.mjs +14 -0
  1194. package/packages/analytics-js-service-worker/package.json +103 -0
  1195. package/packages/analytics-js-service-worker/project.json +104 -0
  1196. package/packages/analytics-js-service-worker/public/.gitkeep +0 -0
  1197. package/packages/analytics-js-service-worker/rollup.config.mjs +140 -0
  1198. package/packages/analytics-js-service-worker/src/Analytics.ts +564 -0
  1199. package/packages/analytics-js-service-worker/src/IAnalytics.ts +141 -0
  1200. package/packages/analytics-js-service-worker/src/index.ts +9 -0
  1201. package/packages/analytics-js-service-worker/src/loosely-validate-event/index.ts +136 -0
  1202. package/packages/analytics-js-service-worker/src/types.ts +67 -0
  1203. package/packages/analytics-js-service-worker/tsconfig.json +8 -0
  1204. package/packages/analytics-js-service-worker/tsconfig.spec.json +22 -0
  1205. package/packages/analytics-v1.1/.env.example +8 -0
  1206. package/packages/analytics-v1.1/.jscpd.json +17 -0
  1207. package/packages/analytics-v1.1/.size-limit.js +16 -0
  1208. package/packages/analytics-v1.1/.versionrc +12 -0
  1209. package/packages/analytics-v1.1/CHANGELOG.md +3859 -0
  1210. package/packages/analytics-v1.1/CHANGELOG_LATEST.md +5 -0
  1211. package/packages/analytics-v1.1/LICENSE +21 -0
  1212. package/packages/analytics-v1.1/README.md +321 -0
  1213. package/packages/analytics-v1.1/__fixtures__/fixtures.js +130 -0
  1214. package/packages/analytics-v1.1/__fixtures__/msw.handlers.js +51 -0
  1215. package/packages/analytics-v1.1/__fixtures__/msw.server.js +6 -0
  1216. package/packages/analytics-v1.1/__mocks__/.gitkeep +0 -0
  1217. package/packages/analytics-v1.1/__tests__/data-residency.test.js +236 -0
  1218. package/packages/analytics-v1.1/__tests__/features/core/metrics/errorReporting/ErrorReportingService.test.js +80 -0
  1219. package/packages/analytics-v1.1/__tests__/ketchConsent.test.js +49 -0
  1220. package/packages/analytics-v1.1/__tests__/oneTrustCookieConsent.test.js +89 -0
  1221. package/packages/analytics-v1.1/__tests__/script.test.js +167 -0
  1222. package/packages/analytics-v1.1/__tests__/transformationHandler.test.js +179 -0
  1223. package/packages/analytics-v1.1/__tests__/utils/IntegrationsData.test.js +105 -0
  1224. package/packages/analytics-v1.1/__tests__/utils/cdnPaths.test.js +63 -0
  1225. package/packages/analytics-v1.1/__tests__/utils/clientHint.test.js +87 -0
  1226. package/packages/analytics-v1.1/__tests__/utils/eventProcessorUtils.test.js +264 -0
  1227. package/packages/analytics-v1.1/__tests__/utils/navigator.test.js +38 -0
  1228. package/packages/analytics-v1.1/__tests__/utils/preProcessQueue.test.js +78 -0
  1229. package/packages/analytics-v1.1/__tests__/utils/screenDetails.test.js +19 -0
  1230. package/packages/analytics-v1.1/__tests__/utils/utils.test.js +69 -0
  1231. package/packages/analytics-v1.1/babel.config.json +14 -0
  1232. package/packages/analytics-v1.1/jest.config.mjs +14 -0
  1233. package/packages/analytics-v1.1/package.json +115 -0
  1234. package/packages/analytics-v1.1/project.json +119 -0
  1235. package/packages/analytics-v1.1/public/index.html +137 -0
  1236. package/packages/analytics-v1.1/rollup-configs/rollup.sdk.browser.mjs +32 -0
  1237. package/packages/analytics-v1.1/rollup-configs/rollup.sdk.npm.mjs +53 -0
  1238. package/packages/analytics-v1.1/rollup-configs/rollup.utilities.mjs +160 -0
  1239. package/packages/analytics-v1.1/src/core/analytics.js +1669 -0
  1240. package/packages/analytics-v1.1/src/features/core/cookieConsent/CookieConsentFactory.js +32 -0
  1241. package/packages/analytics-v1.1/src/features/core/cookieConsent/OneTrust/browser.js +102 -0
  1242. package/packages/analytics-v1.1/src/features/core/cookieConsent/OneTrust/index.js +1 -0
  1243. package/packages/analytics-v1.1/src/features/core/cookieConsent/ketch/browser.js +114 -0
  1244. package/packages/analytics-v1.1/src/features/core/cookieConsent/ketch/index.js +1 -0
  1245. package/packages/analytics-v1.1/src/features/core/deviceModeTransformation/transformationHandler.js +196 -0
  1246. package/packages/analytics-v1.1/src/features/core/deviceModeTransformation/util.js +23 -0
  1247. package/packages/analytics-v1.1/src/features/core/metrics/errorReporting/ErrorReportingService.js +116 -0
  1248. package/packages/analytics-v1.1/src/features/core/metrics/errorReporting/providers/Bugsnag.js +247 -0
  1249. package/packages/analytics-v1.1/src/features/core/session/index.js +207 -0
  1250. package/packages/analytics-v1.1/src/utils/EventRepository.js +79 -0
  1251. package/packages/analytics-v1.1/src/utils/IntegrationsData.js +56 -0
  1252. package/packages/analytics-v1.1/src/utils/JSFileLoader.js +66 -0
  1253. package/packages/analytics-v1.1/src/utils/PreProcessQueue.js +66 -0
  1254. package/packages/analytics-v1.1/src/utils/RudderApp.js +9 -0
  1255. package/packages/analytics-v1.1/src/utils/RudderContext.js +23 -0
  1256. package/packages/analytics-v1.1/src/utils/RudderElement.js +33 -0
  1257. package/packages/analytics-v1.1/src/utils/RudderElementBuilder.js +29 -0
  1258. package/packages/analytics-v1.1/src/utils/RudderInfo.js +41 -0
  1259. package/packages/analytics-v1.1/src/utils/RudderMessage.js +28 -0
  1260. package/packages/analytics-v1.1/src/utils/beaconQueue.js +140 -0
  1261. package/packages/analytics-v1.1/src/utils/cdnPaths.js +43 -0
  1262. package/packages/analytics-v1.1/src/utils/clientHint.js +28 -0
  1263. package/packages/analytics-v1.1/src/utils/constants.js +70 -0
  1264. package/packages/analytics-v1.1/src/utils/eventProcessorUtils.js +53 -0
  1265. package/packages/analytics-v1.1/src/utils/linker/base64decoder.js +29 -0
  1266. package/packages/analytics-v1.1/src/utils/linker/crc32.js +42 -0
  1267. package/packages/analytics-v1.1/src/utils/linker/index.js +134 -0
  1268. package/packages/analytics-v1.1/src/utils/linker/userLib.js +20 -0
  1269. package/packages/analytics-v1.1/src/utils/navigator.js +32 -0
  1270. package/packages/analytics-v1.1/src/utils/pageProperties.js +74 -0
  1271. package/packages/analytics-v1.1/src/utils/screenDetails.js +23 -0
  1272. package/packages/analytics-v1.1/src/utils/utils.js +423 -0
  1273. package/packages/analytics-v1.1/src/utils/xhrModule.js +117 -0
  1274. package/packages/analytics-v1.1/tsconfig.json +8 -0
  1275. package/packages/analytics-v1.1/tsconfig.spec.json +26 -0
  1276. package/packages/analytics-v1.1/types/index.d.ts +472 -0
  1277. package/packages/analytics-v1.1/types/service-worker/index.d.ts +220 -0
  1278. package/packages/loading-scripts/.env.example +11 -0
  1279. package/packages/loading-scripts/.jscpd.json +17 -0
  1280. package/packages/loading-scripts/CHANGELOG.md +130 -0
  1281. package/packages/loading-scripts/CHANGELOG_LATEST.md +2 -0
  1282. package/packages/loading-scripts/LICENSE +21 -0
  1283. package/packages/loading-scripts/README.md +26 -0
  1284. package/packages/loading-scripts/__fixtures__/.gitkeep +0 -0
  1285. package/packages/loading-scripts/__mocks__/.gitkeep +0 -0
  1286. package/packages/loading-scripts/__tests__/.gitkeep +0 -0
  1287. package/packages/loading-scripts/babel.config.json +14 -0
  1288. package/packages/loading-scripts/jest.config.mjs +14 -0
  1289. package/packages/loading-scripts/package.json +62 -0
  1290. package/packages/loading-scripts/project.json +101 -0
  1291. package/packages/loading-scripts/public/index.html +180 -0
  1292. package/packages/loading-scripts/rollup.config.mjs +112 -0
  1293. package/packages/loading-scripts/src/index.ts +106 -0
  1294. package/packages/loading-scripts/src/types/rudderanalytics.d.ts +16 -0
  1295. package/packages/loading-scripts/tsconfig.json +15 -0
  1296. package/packages/loading-scripts/tsconfig.spec.json +22 -0
  1297. package/packages/sanity-suite/.env.example +39 -0
  1298. package/packages/sanity-suite/.jscpd.json +17 -0
  1299. package/packages/sanity-suite/CHANGELOG.md +154 -0
  1300. package/packages/sanity-suite/LICENSE +21 -0
  1301. package/packages/sanity-suite/README.md +37 -0
  1302. package/packages/sanity-suite/__fixtures__/alias1.json +141 -0
  1303. package/packages/sanity-suite/__fixtures__/alias2.json +101 -0
  1304. package/packages/sanity-suite/__fixtures__/alias3.json +101 -0
  1305. package/packages/sanity-suite/__fixtures__/alias4.json +101 -0
  1306. package/packages/sanity-suite/__fixtures__/alias5.json +107 -0
  1307. package/packages/sanity-suite/__fixtures__/alias6.json +141 -0
  1308. package/packages/sanity-suite/__fixtures__/eventFiltering1.json +69 -0
  1309. package/packages/sanity-suite/__fixtures__/eventFiltering2.json +69 -0
  1310. package/packages/sanity-suite/__fixtures__/eventFiltering3.json +69 -0
  1311. package/packages/sanity-suite/__fixtures__/group1.json +124 -0
  1312. package/packages/sanity-suite/__fixtures__/group2.json +90 -0
  1313. package/packages/sanity-suite/__fixtures__/group3.json +90 -0
  1314. package/packages/sanity-suite/__fixtures__/group4.json +105 -0
  1315. package/packages/sanity-suite/__fixtures__/group5.json +71 -0
  1316. package/packages/sanity-suite/__fixtures__/group6.json +70 -0
  1317. package/packages/sanity-suite/__fixtures__/identify1.json +140 -0
  1318. package/packages/sanity-suite/__fixtures__/identify2.json +106 -0
  1319. package/packages/sanity-suite/__fixtures__/identify3.json +103 -0
  1320. package/packages/sanity-suite/__fixtures__/identify4.json +69 -0
  1321. package/packages/sanity-suite/__fixtures__/identify5.json +106 -0
  1322. package/packages/sanity-suite/__fixtures__/identify6.json +107 -0
  1323. package/packages/sanity-suite/__fixtures__/identify7.json +106 -0
  1324. package/packages/sanity-suite/__fixtures__/identify8.json +107 -0
  1325. package/packages/sanity-suite/__fixtures__/page1.json +123 -0
  1326. package/packages/sanity-suite/__fixtures__/page2.json +90 -0
  1327. package/packages/sanity-suite/__fixtures__/page3.json +90 -0
  1328. package/packages/sanity-suite/__fixtures__/page4.json +116 -0
  1329. package/packages/sanity-suite/__fixtures__/page5.json +83 -0
  1330. package/packages/sanity-suite/__fixtures__/page6.json +81 -0
  1331. package/packages/sanity-suite/__fixtures__/page7.json +81 -0
  1332. package/packages/sanity-suite/__fixtures__/page8.json +79 -0
  1333. package/packages/sanity-suite/__fixtures__/sourceConfig1.json +1536 -0
  1334. package/packages/sanity-suite/__fixtures__/sourceConfigDMT1.json +665 -0
  1335. package/packages/sanity-suite/__fixtures__/sourceConfigDev1.json +892 -0
  1336. package/packages/sanity-suite/__fixtures__/track1.json +154 -0
  1337. package/packages/sanity-suite/__fixtures__/track2.json +122 -0
  1338. package/packages/sanity-suite/__fixtures__/track3.json +122 -0
  1339. package/packages/sanity-suite/__fixtures__/track4.json +138 -0
  1340. package/packages/sanity-suite/__fixtures__/track5.json +106 -0
  1341. package/packages/sanity-suite/__fixtures__/track6.json +85 -0
  1342. package/packages/sanity-suite/__fixtures__/track7.json +85 -0
  1343. package/packages/sanity-suite/babel.config.json +14 -0
  1344. package/packages/sanity-suite/jest.config.mjs +14 -0
  1345. package/packages/sanity-suite/package.json +83 -0
  1346. package/packages/sanity-suite/project.json +55 -0
  1347. package/packages/sanity-suite/public/v1.1/index-cdn.html +135 -0
  1348. package/packages/sanity-suite/public/v1.1/index-local.html +141 -0
  1349. package/packages/sanity-suite/public/v1.1/index-npm.html +107 -0
  1350. package/packages/sanity-suite/public/v1.1/integrations/index-cdn.html +172 -0
  1351. package/packages/sanity-suite/public/v1.1/integrations/index-local.html +171 -0
  1352. package/packages/sanity-suite/public/v1.1/integrations/index-npm.html +140 -0
  1353. package/packages/sanity-suite/public/v1.1/manualLoadCall/index-cdn.html +172 -0
  1354. package/packages/sanity-suite/public/v1.1/manualLoadCall/index-local.html +171 -0
  1355. package/packages/sanity-suite/public/v1.1/manualLoadCall/index-npm.html +140 -0
  1356. package/packages/sanity-suite/public/v3/index-cdn.html +165 -0
  1357. package/packages/sanity-suite/public/v3/index-local.html +169 -0
  1358. package/packages/sanity-suite/public/v3/index-npm.html +99 -0
  1359. package/packages/sanity-suite/public/v3/integrations/index-cdn.html +196 -0
  1360. package/packages/sanity-suite/public/v3/integrations/index-local.html +198 -0
  1361. package/packages/sanity-suite/public/v3/integrations/index-npm.html +138 -0
  1362. package/packages/sanity-suite/public/v3/manualLoadCall/index-cdn.html +196 -0
  1363. package/packages/sanity-suite/public/v3/manualLoadCall/index-local.html +198 -0
  1364. package/packages/sanity-suite/public/v3/manualLoadCall/index-npm.html +138 -0
  1365. package/packages/sanity-suite/rollup.config.mjs +247 -0
  1366. package/packages/sanity-suite/serve.json +4 -0
  1367. package/packages/sanity-suite/src/ignoredProperties/ignoredProperties.js +183 -0
  1368. package/packages/sanity-suite/src/ignoredProperties/sourceConfigIgnoredProperties.js +144 -0
  1369. package/packages/sanity-suite/src/index-npm-v1.1.ts +53 -0
  1370. package/packages/sanity-suite/src/index-npm.ts +57 -0
  1371. package/packages/sanity-suite/src/index.ts +6 -0
  1372. package/packages/sanity-suite/src/testBook/ResultAssertions.js +77 -0
  1373. package/packages/sanity-suite/src/testBook/TestBook.js +360 -0
  1374. package/packages/sanity-suite/src/testBook/index.js +13 -0
  1375. package/packages/sanity-suite/src/testBookSuites/alias.js +289 -0
  1376. package/packages/sanity-suite/src/testBookSuites/eventFiltering.js +77 -0
  1377. package/packages/sanity-suite/src/testBookSuites/group.js +241 -0
  1378. package/packages/sanity-suite/src/testBookSuites/identify.js +455 -0
  1379. package/packages/sanity-suite/src/testBookSuites/index.js +40 -0
  1380. package/packages/sanity-suite/src/testBookSuites/page.js +259 -0
  1381. package/packages/sanity-suite/src/testBookSuites/sourceConfig.js +89 -0
  1382. package/packages/sanity-suite/src/testBookSuites/sourceConfigDev.js +20 -0
  1383. package/packages/sanity-suite/src/testBookSuites/track.js +448 -0
  1384. package/packages/sanity-suite/src/types/global.d.ts +2 -0
  1385. package/packages/sanity-suite/src/types/rudderanalytics.d.ts +16 -0
  1386. package/packages/sanity-suite/tsconfig.json +14 -0
  1387. package/packages/sanity-suite/tsconfig.spec.json +22 -0
  1388. package/patches/@originjs+vite-plugin-federation+1.3.5.patch +170 -0
  1389. package/patches/@segment+localstorage-retry+1.3.0.patch +123 -0
  1390. package/patches/@segment+top-domain+3.0.1.patch +34 -0
  1391. package/patches/@vespaiach+axios-fetch-adapter+0.3.1.patch +43 -0
  1392. package/patches/crypto-es+2.1.0.patch +103 -0
  1393. package/patches/nx+18.0.5.patch +83 -0
  1394. package/patches/rollup-plugin-generate-html-template+1.7.0.patch +46 -0
  1395. package/scripts/commitizen.js +26 -0
  1396. package/scripts/fix-reports-path-in-github-runner.sh +16 -0
  1397. package/scripts/generate-last-release-changelog.sh +32 -0
  1398. package/scripts/sync-tags-in-nx-projects.sh +24 -0
  1399. package/sonar-project.properties +37 -0
  1400. package/tsconfig.build.json +12 -0
  1401. package/tsconfig.json +49 -0
  1402. package/tsconfig.paths.json +27 -0
  1403. package/types/clipboardJs.d.ts +1 -0
  1404. package/types/component-querystring.d.ts +1 -0
  1405. package/types/component-type.d.ts +1 -0
  1406. package/types/global.d.ts +18 -0
  1407. package/types/join-component.d.ts +1 -0
  1408. package/types/localstorage-retry.d.ts +1 -0
  1409. package/types/loosely-validate-event.d.ts +1 -0
  1410. package/types/user-agent-data-types.d.ts +3 -0
@@ -0,0 +1,60 @@
1
+ // This is the service worker script, which executes in its own context
2
+ // when the extension is installed or refreshed (or when you access its console).
3
+ // It would correspond to the background script in chrome extensions v2.
4
+
5
+ console.log("This prints to the console of the service worker (background script)")
6
+
7
+ // Importing and using functionality from external files is also possible.
8
+ import { Analytics } from "./rudderAnalytics.js";
9
+
10
+ console.log(Analytics);
11
+
12
+ let socket = new WebSocket("ws://localhost:8080");
13
+ socket.onopen = function(e) {
14
+ console.log("[open] Connection established");
15
+ console.log("Sending to server");
16
+ };
17
+
18
+ socket.onmessage = function(event) {
19
+ console.log(`[message] Data received from server: ${event.data}`);
20
+ };
21
+
22
+ socket.onclose = function(event) {
23
+ if (event.wasClean) {
24
+ console.log(`[close] Connection closed cleanly, code=${event.code} reason=${event.reason}`);
25
+ } else {
26
+ // e.g. server process killed or network down
27
+ // event.code is usually 1006 in this case
28
+ console.log('[close] Connection died');
29
+ }
30
+ };
31
+
32
+ socket.onerror = function(error) {
33
+ console.log(`[error]`);
34
+ };
35
+
36
+ const rudderClient = new Analytics(
37
+ "<writeKey>",
38
+ "<dataPlaneURL>/v1/batch",
39
+ {
40
+ logLevel: 'silly',
41
+ flashAt: 1,
42
+ flushOverride: function(message) {
43
+ socket.send(JSON.stringify(message))
44
+ }
45
+ }
46
+ );
47
+
48
+ chrome.tabs.onUpdated.addListener((tabId, tab) => {
49
+ if (tab.url) {
50
+ rudderClient.track({
51
+ userId: "123456",
52
+ event: "Event Name",
53
+ properties: {
54
+ data: {
55
+ url: tab.url
56
+ },
57
+ }
58
+ });
59
+ }
60
+ });
@@ -0,0 +1,8 @@
1
+ body {
2
+ background-color: #222;
3
+ color: #eee;
4
+ }
5
+
6
+ .special-text {
7
+ color: red;
8
+ }
@@ -0,0 +1,12 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
6
+ <link rel="stylesheet" href="settings.css">
7
+ <title>Rudderstack SDK: Chrome Extension Background Script Sample: Settings</title>
8
+ </head>
9
+ <body>
10
+ This is the <span class="special-text">settings</span> page for the addon.
11
+ </body>
12
+ </html>
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2021 RudderStack
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,105 @@
1
+ <div align="center">
2
+ <img src="https://raw.githubusercontent.com/SimGus/chrome-addon-v3-starter/master/logo/logo-128.png"/>
3
+ <h1>Chrome Extension v3 Starter</h1>
4
+ <h3>A minimal template of a Chrome v3 addon</h3>
5
+ </div>
6
+
7
+ This repository contains a minimal Chrome/Chromium extension that uses the newest version of the manifest (v3).
8
+
9
+ You can use it as a basis to develop an extension.
10
+ It can also give you more insights about how to turn a v2 extension to v3.
11
+
12
+ In other words, this is a **working, installable v3 extension** example meant for you to **jumpstart** the development of your own extension.
13
+
14
+ ## Installation
15
+
16
+ - **Fork** this repo, then **clone your forked repo locally**. If you don't have a github account, you can simply download a zip of the repo and unzip it on your computer.
17
+ - **Open [the extensions page](chrome://extensions)** in your browser: `chrome://extensions`. This link works on any chromium-based browser.
18
+ - If you did not do it already, **toggle the "developer mode"**. This is usually a toggle button at the top right of the extensions page.
19
+ - Click the button **_load unpacked extension_**.
20
+ - In the window that pops up, **select the folder that contains this minimal extension**, then **click _ok_**.
21
+ - **Done!** A new extension called _Chrome Addon v3 Starter_ should have appeared in the list.
22
+
23
+ ## Q&A
24
+
25
+ > Does this work only on Chrome or on **other web browsers** as well?
26
+
27
+ At the moment, this works on every chromium-based web browser that supports v3 extensions.
28
+ Therefore, you should be able to install this extension on any of the following browsers (as long as they are up-to-date):
29
+
30
+ - _Free and open-source browsers_:
31
+ - Chromium
32
+ - Brave
33
+ - _Proprietary browsers_:
34
+ - Chrome
35
+ - Edge
36
+ - Vivaldi
37
+ - Opera
38
+
39
+ > So it doesn't work on **Firefox** or **Safari**?
40
+
41
+ No, Firefox uses a different extension format. That being said, it is usually not too hard to port extensions from Chrome to Firefox.
42
+ Read [their porting documentation](https://extensionworkshop.com/documentation/develop/porting-a-google-chrome-extension/) for more information.
43
+
44
+ Safari uses yet another extension format and porting is usually harder.
45
+ You can find more information [here](https://bartsolutions.github.io/2020/11/20/safari-extension/).
46
+
47
+ > Does this work on **Chrome for Android/iOS**?
48
+
49
+ Chrome for mobile doesn't currently support extensions.
50
+
51
+ > I don't need a **popup tool** for my extension! Can I remove it?
52
+
53
+ Yes, simply delete the `popup` folder and remove the `default_popup` property from the manifest.
54
+
55
+ > I changed some code in the extension, but my **changes aren't taken into account**!
56
+
57
+ For most of the changes you make, you will need to reload your extension for the changes to be applied.
58
+ To do that, go to the chrome://extensions page and click the reload button of your extension.
59
+ Note that most of the changes you will make to the settings page or the popup don't require reloading the extension.
60
+
61
+ > Can I follow a **tutorial about a v2 extension** with this?
62
+
63
+ Most of what you will find in those tutorials still holds with v3.
64
+
65
+ However, a few things (notably best practices) have changed.
66
+ You should read the [official migration page (v2 to v3)](https://developer.chrome.com/docs/extensions/mv3/intro/mv3-migration/) before following such a tutorial.
67
+
68
+ > When I make an erroneous change in my service worker, the extension doesn't load! How can I **debug a service worker**?
69
+
70
+ Using the debugger if your service worker is not loaded is not possible.
71
+
72
+ However, if you want to test some piece of code before putting it in your service worker, you can:
73
+
74
+ - load your extension with a working version of the service worker.
75
+ - click on "service worker" on the page _chrome://extensions_. This will open the console attached to the service worker.
76
+ - paste your code in the console and see if any error is logged.
77
+
78
+ Note that in this console, you have access to anything your service worker has access to, including its variables, functions and chrome APIs.
79
+
80
+ > How do I **uninstall** this extension from my browser?
81
+
82
+ - Go to the [extensions page](chrome://extensions): chrome://extensions.
83
+ There should be a card with the name of this extension as title.
84
+ If you don't see such a card, it means the extension is not installed.
85
+ - Simply click the _Delete_ button at the bottom of the card. Click _ok_ if a popup asks you for confirmation. The extension is now uninstalled.
86
+
87
+ > I want to **push my changes to my own repo**, how do I do this?
88
+
89
+ - If you forked this repo and cloned your own fork locally, git will push to your fork on your account automatically (i.e. use the command `git push` or `git push origin <your-branch>`).
90
+
91
+ - If you downloaded a zip or simply cloned this repo locally, do the following:
92
+ - Create a github account if you don't already have one and install git on your machine.
93
+ - Create a new (empty) repo on your github and copy its url.
94
+ - Open a terminal in the folder where the extension is cloned.
95
+ - Run the command `git init`, then `git commit -am "Initial commit"`
96
+ - Run the command `git remote add origin <url-of-your-repo>`
97
+ - Run `git push -u origin master`. The extension code is now on your repo, on brnach _master_.
98
+ - If you want, you can make the _master_ branch the default one and delete the _main_ branch in the settings of your repo.
99
+
100
+ ## External resources
101
+
102
+ - [Official feature summary for manifest v3](https://developer.chrome.com/docs/extensions/mv3/intro/mv3-overview/)
103
+ - [Migrating from v2 to v3](https://developer.chrome.com/docs/extensions/mv3/intro/mv3-migration/) + [very useful checklist once you think you are done](https://developer.chrome.com/docs/extensions/mv3/mv3-migration-checklist/)
104
+ - [Excellent write-ups of a migration](https://github.com/kentbrew/learning-manifest-v3)
105
+ - [Another example of a v3 extension (older code)](https://gist.github.com/dotproto/3a328d6b187621b445499ba503599dc0)
@@ -0,0 +1,65 @@
1
+ // This script gets injected into any opened page
2
+ // whose URL matches the pattern defined in the manifest
3
+ // (see "content_script" key).
4
+ // Several foreground scripts can be declared
5
+ // and injected into the same or different pages.
6
+ (() => {
7
+ //======================== npm package code ==========================================
8
+ function e(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function t(t){for(var n=1;n<arguments.length;n++){var r=null!=arguments[n]?arguments[n]:{};n%2?e(Object(r),!0).forEach((function(e){s(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):e(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,f(r.key),r)}}function o(e,t,n){return t&&i(e.prototype,t),n&&i(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function s(e,t,n){return(t=f(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(){return a=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},a.apply(this,arguments)}function u(e){return function(e){if(Array.isArray(e))return l(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||c(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function c(e,t){if(e){if("string"==typeof e)return l(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?l(e,t):void 0}}function l(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function f(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:String(t)}"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;function h(e){if(e.__esModule)return e;var t=e.default;if("function"==typeof t){var n=function e(){if(this instanceof e){var n=[null];n.push.apply(n,arguments);var r=Function.bind.apply(t,n);return new r}return t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach((function(t){var r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,r.get?r:{enumerable:!0,get:function(){return e[t]}})})),n}var d={},p={get exports(){return d},set exports(e){d=e}};!function(e){function t(e){if(e)return function(e){for(var n in t.prototype)e[n]=t.prototype[n];return e}(e)}p.exports=t,t.prototype.on=t.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},t.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},t.prototype.off=t.prototype.removeListener=t.prototype.removeAllListeners=t.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var i=0;i<r.length;i++)if((n=r[i])===t||n.fn===t){r.splice(i,1);break}return 0===r.length&&delete this._callbacks["$"+e],this},t.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){r=0;for(var i=(n=n.slice(0)).length;r<i;++r)n[r].apply(this,t)}return this},t.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},t.prototype.hasListeners=function(e){return!!this.listeners(e).length}}();var g,y=d,v={},m={get exports(){return v},set exports(e){v=e}};g=v,(g=m.exports=function(e){return e.trim?e.trim():g.right(g.left(e))}).left=function(e){return e.trimLeft?e.trimLeft():e.replace(/^\s\s*/,"")},g.right=function(e){if(e.trimRight)return e.trimRight();for(var t=/\s/,n=e.length;t.test(e.charAt(--n)););return e.slice(0,n+1)};var A=v,I=/(\w+)\[(\d+)\]/,E=function(e){try{return decodeURIComponent(e.replace(/\+/g," "))}catch(t){return e}},b=function(e){if("string"!=typeof e)return{};if(""==(e=A(e)))return{};"?"==e.charAt(0)&&(e=e.slice(1));for(var t={},n=e.split("&"),r=0;r<n.length;r++){var i,o=n[r].split("="),s=E(o[0]);(i=I.exec(s))?(t[i[1]]=t[i[1]]||[],t[i[1]][i[2]]=E(o[1])):t[o[0]]=null==o[1]?"":E(o[1])}return t};function O(e){return null!=e&&"object"==typeof e&&!0===e["@@functional/placeholder"]}function S(e){return function t(n){return 0===arguments.length||O(n)?t:e.apply(this,arguments)}}function k(e){return function t(n,r){switch(arguments.length){case 0:return t;case 1:return O(n)?t:S((function(t){return e(n,t)}));default:return O(n)&&O(r)?t:O(n)?S((function(t){return e(t,r)})):O(r)?S((function(t){return e(n,t)})):e(n,r)}}}function C(e){return function t(n,r,i){switch(arguments.length){case 0:return t;case 1:return O(n)?t:k((function(t,r){return e(n,t,r)}));case 2:return O(n)&&O(r)?t:O(n)?k((function(t,n){return e(t,r,n)})):O(r)?k((function(t,r){return e(n,t,r)})):S((function(t){return e(n,r,t)}));default:return O(n)&&O(r)&&O(i)?t:O(n)&&O(r)?k((function(t,n){return e(t,n,i)})):O(n)&&O(i)?k((function(t,n){return e(t,r,n)})):O(r)&&O(i)?k((function(t,r){return e(n,t,r)})):O(n)?S((function(t){return e(t,r,i)})):O(r)?S((function(t){return e(n,t,i)})):O(i)?S((function(t){return e(n,r,t)})):e(n,r,i)}}}function w(e,t){return Object.prototype.hasOwnProperty.call(t,e)}var _=S((function(e){return null===e?"Null":void 0===e?"Undefined":Object.prototype.toString.call(e).slice(8,-1)}));function T(e,t,n,r){var i=function(i){for(var o=t.length,s=0;s<o;){if(e===t[s])return n[s];s+=1}for(var a in t[s]=e,n[s]=i,e)e.hasOwnProperty(a)&&(i[a]=r?T(e[a],t,n,!0):e[a]);return i};switch(_(e)){case"Object":return i(Object.create(Object.getPrototypeOf(e)));case"Array":return i([]);case"Date":return new Date(e.valueOf());case"RegExp":return function(e){return new RegExp(e.source,(e.global?"g":"")+(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.sticky?"y":"")+(e.unicode?"u":""))}(e);case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"Uint32Array":case"Float32Array":case"Float64Array":case"BigInt64Array":case"BigUint64Array":return e.slice();default:return e}}var R=S((function(e){return null!=e&&"function"==typeof e.clone?e.clone():T(e,[],[],!0)}));function P(e){return"[object Object]"===Object.prototype.toString.call(e)}var L=C((function(e,t,n){var r,i={};for(r in t)w(r,t)&&(i[r]=w(r,n)?e(r,t[r],n[r]):t[r]);for(r in n)w(r,n)&&!w(r,i)&&(i[r]=n[r]);return i})),x=C((function e(t,n,r){return L((function(n,r,i){return P(r)&&P(i)?e(t,r,i):t(n,r,i)}),n,r)})),M=C((function(e,t,n){return x((function(t,n,r){return e(n,r)}),t,n)})),D={};!function(e){function t(e){switch(e){case"http:":return 80;case"https:":return 443;default:return location.port}}e.parse=function(e){var n=document.createElement("a");return n.href=e,{href:n.href,host:n.host||location.host,port:"0"===n.port||""===n.port?t(n.protocol):n.port,hash:n.hash,hostname:n.hostname||location.hostname,pathname:"/"!=n.pathname.charAt(0)?"/"+n.pathname:n.pathname,protocol:n.protocol&&":"!=n.protocol?n.protocol:location.protocol,search:n.search,query:n.search.slice(1)}},e.isAbsolute=function(e){return 0==e.indexOf("//")||!!~e.indexOf("://")},e.isRelative=function(t){return!e.isAbsolute(t)},e.isCrossDomain=function(t){t=e.parse(t);var n=e.parse(window.location.href);return t.hostname!==n.hostname||t.port!==n.port||t.protocol!==n.protocol}}(D);const N=function(e){return null!=e&&"object"==typeof e&&!1===Array.isArray(e)};var B=function(e,t,n){if(N(n)||(n={default:n}),!U(e))return void 0!==n.default?n.default:e;"number"==typeof t&&(t=String(t));const r=Array.isArray(t),i="string"==typeof t,o=n.separator||".",s=n.joinChar||("string"==typeof o?o:".");if(!i&&!r)return e;if(i&&t in e)return F(t,e,n)?e[t]:n.default;let a=r?t:function(e,t,n){if("function"==typeof n.split)return n.split(e);return e.split(t)}(t,o,n),u=a.length,c=0;do{let t=a[c];for("number"==typeof t&&(t=String(t));t&&"\\"===t.slice(-1);)t=G([t.slice(0,-1),a[++c]||""],s,n);if(t in e){if(!F(t,e,n))return n.default;e=e[t]}else{let r=!1,i=c+1;for(;i<u;)if(t=G([t,a[i++]],s,n),r=t in e){if(!F(t,e,n))return n.default;e=e[t],c=i-1;break}if(!r)return n.default}}while(++c<u&&U(e));return c===u?e:n.default};function G(e,t,n){return"function"==typeof n.join?n.join(e):e[0]+t+e[1]}function F(e,t,n){return"function"!=typeof n.isValid||n.isValid(e,t)}function U(e){return N(e)||Array.isArray(e)||"function"==typeof e}for(var j,H=256,K=[];H--;)K[H]=(H+256).toString(16).substring(1);var z,Q,V,q,W,Y,J,X,$,Z,ee,te,ne,re,ie,oe,se,ae,ue,ce,le,fe,he,de,pe,ge,ye,ve,me,Ae,Ie,Ee,be,Oe,Se,ke,Ce,we,_e,Te,Re,Pe,Le,xe,Me,De,Ne,Be,Ge,Fe,Ue,je,He,Ke,ze,Qe,Ve,qe,We,Ye,Je,Xe,$e,Ze,et,tt,nt,rt,it,ot,st,at,ut=4,ct=function(e){switch(e.toUpperCase()){case"INFO":ut=1;break;case"DEBUG":ut=2;break;case"WARN":ut=3;break;default:ut=4}},lt=function(){var e;ut<=1&&(e=console).info.apply(e,arguments)},ft=function(){var e;ut<=2&&(e=console).log.apply(e,arguments)},ht=function(){var e;ut<=3&&(e=console).warn.apply(e,arguments)},dt=function(){var e;ut<=4&&(e=console).error.apply(e,arguments)},pt="ADOBE_ANALYTICS",gt=(z={"Adobe Analytics":pt,ADOBEANALYTICS:pt,"ADOBE ANALYTICS":pt},s(z,pt,pt),s(z,"AdobeAnalytics",pt),s(z,"adobeanalytics",pt),s(z,"adobe analytics",pt),s(z,"Adobe analytics",pt),s(z,"adobe Analytics",pt),z),yt=(Q={},s(Q,"AM","AM"),s(Q,"AMPLITUDE","AM"),s(Q,"Amplitude","AM"),s(Q,"am","AM"),Q),vt=(V={},s(V,"APPCUES","APPCUES"),s(V,"Appcues","APPCUES"),s(V,"App Cues","APPCUES"),s(V,"appcues","APPCUES"),V),mt=(q={},s(q,"BINGADS","BINGADS"),s(q,"BingAds","BINGADS"),s(q,"bingads","BINGADS"),s(q,"Bing Ads","BINGADS"),s(q,"Bing ads","BINGADS"),s(q,"bing Ads","BINGADS"),s(q,"bing ads","BINGADS"),q),At=(W={},s(W,"BRAZE","BRAZE"),s(W,"Braze","BRAZE"),s(W,"braze","BRAZE"),W),It=(Y={},s(Y,"BUGSNAG","BUGSNAG"),s(Y,"bugsnag","BUGSNAG"),s(Y,"Bugsnag","BUGSNAG"),Y),Et="CHARTBEAT",bt=(J={},s(J,Et,Et),s(J,"Chartbeat",Et),s(J,"chartbeat",Et),s(J,"Chart Beat",Et),s(J,"chart beat",Et),J),Ot="CLEVERTAP",St=(X={},s(X,Ot,Ot),s(X,"Clevertap",Ot),s(X,"clevertap",Ot),X),kt="COMSCORE",Ct=($={},s($,kt,kt),s($,"Comscore",kt),s($,"Com Score",kt),s($,"com Score",kt),s($,"com score",kt),s($,"Com score",kt),$),wt=(Z={},s(Z,"CRITEO","CRITEO"),s(Z,"Criteo","CRITEO"),s(Z,"criteo","CRITEO"),Z),_t="CUSTOMERIO",Tt=(ee={},s(ee,_t,_t),s(ee,"Customerio",_t),s(ee,"Customer.io",_t),s(ee,"CUSTOMER.IO",_t),s(ee,"customer.io",_t),ee),Rt=(te={},s(te,"DRIP","DRIP"),s(te,"Drip","DRIP"),s(te,"drip","DRIP"),te),Pt="FACEBOOK_PIXEL",Lt=(s(ne={},Pt,Pt),s(ne,"FB Pixel",Pt),s(ne,"Facebook Pixel",Pt),s(ne,"facebook pixel",Pt),s(ne,"fbpixel",Pt),s(ne,"FBPIXEL",Pt),s(ne,"FB_PIXEL",Pt),ne),xt="FULLSTORY",Mt=(s(re={},xt,xt),s(re,"Fullstory",xt),s(re,"FullStory",xt),s(re,"full Story",xt),s(re,"Full Story",xt),s(re,"Full story",xt),s(re,"full story",xt),s(re,"fullstory",xt),re),Dt=(s(ie={},"GA","GA"),s(ie,"Google Analytics","GA"),s(ie,"GoogleAnalytics","GA"),s(ie,"GOOGLE ANALYTICS","GA"),s(ie,"google analytics","GA"),ie),Nt=(s(oe={},"GA4","GA4"),s(oe,"Google Analytics 4","GA4"),s(oe,"Google analytics 4","GA4"),s(oe,"google analytics 4","GA4"),s(oe,"Google Analytics4","GA4"),s(oe,"Google analytics4","GA4"),s(oe,"google analytics4","GA4"),s(oe,"GoogleAnalytics4","GA4"),oe),Bt="GOOGLEADS",Gt=(s(se={},Bt,Bt),s(se,"Google Ads",Bt),s(se,"GoogleAds",Bt),s(se,"GOOGLE ADS",Bt),s(se,"google ads",Bt),s(se,"googleads",Bt),se),Ft="GOOGLE_OPTIMIZE",Ut=(s(ae={},Ft,Ft),s(ae,"Google Optimize",Ft),s(ae,"GoogleOptimize",Ft),s(ae,"Googleoptimize",Ft),s(ae,"GOOGLEOPTIMIZE",Ft),s(ae,"google optimize",Ft),s(ae,"Google optimize",Ft),s(ae,"GOOGLE OPTIMIZE",Ft),ae),jt=(s(ue={},"GTM","GTM"),s(ue,"Google Tag Manager","GTM"),s(ue,"google tag manager","GTM"),s(ue,"googletag manager","GTM"),s(ue,"googletagmanager","GTM"),ue),Ht=(s(ce={},"HEAP","HEAP"),s(ce,"Heap","HEAP"),s(ce,"heap","HEAP"),s(ce,"Heap.io","HEAP"),ce),Kt=(s(le={},"HOTJAR","HOTJAR"),s(le,"Hotjar","HOTJAR"),s(le,"hotjar","HOTJAR"),s(le,"Hot Jar","HOTJAR"),s(le,"hot jar","HOTJAR"),le),zt=(s(fe={},"HS","HS"),s(fe,"Hubspot","HS"),s(fe,"HUBSPOT","HS"),s(fe,"hub spot","HS"),s(fe,"Hub Spot","HS"),s(fe,"Hub spot","HS"),fe),Qt=(s(he={},"INTERCOM","INTERCOM"),s(he,"Intercom","INTERCOM"),s(he,"intercom","INTERCOM"),he),Vt=(s(de={},"KEEN","KEEN"),s(de,"Keen","KEEN"),s(de,"Keen.io","KEEN"),s(de,"keen","KEEN"),s(de,"keen.io","KEEN"),de),qt="KISSMETRICS",Wt=(s(pe={},qt,qt),s(pe,"Kissmetrics",qt),s(pe,"kissmetrics",qt),pe),Yt=(s(ge={},"KLAVIYO","KLAVIYO"),s(ge,"Klaviyo","KLAVIYO"),s(ge,"klaviyo","KLAVIYO"),ge),Jt="LAUNCHDARKLY",Xt=(s(ye={},Jt,Jt),s(ye,"LaunchDarkly",Jt),s(ye,"Launch_Darkly",Jt),s(ye,"Launch Darkly",Jt),s(ye,"launchDarkly",Jt),s(ye,"launch darkly",Jt),ye),$t="LINKEDIN_INSIGHT_TAG",Zt=(s(ve={},$t,$t),s(ve,"LinkedIn Insight Tag",$t),s(ve,"LinkedIn insight tag",$t),s(ve,"linkedIn insight tag",$t),s(ve,"Linkedin_insight_tag",$t),s(ve,"LinkedinInsighttag",$t),s(ve,"LinkedinInsightTag",$t),s(ve,"LinkedInInsightTag",$t),s(ve,"Linkedininsighttag",$t),s(ve,"LINKEDININSIGHTTAG",$t),s(ve,"linkedininsighttag",$t),ve),en=(s(me={},"LOTAME","LOTAME"),s(me,"Lotame","LOTAME"),s(me,"lotame","LOTAME"),me),tn=(s(Ae={},"LYTICS","LYTICS"),s(Ae,"Lytics","LYTICS"),s(Ae,"lytics","LYTICS"),Ae),nn=(s(Ie={},"MP","MP"),s(Ie,"MIXPANEL","MP"),s(Ie,"Mixpanel","MP"),s(Ie,"MIX PANEL","MP"),s(Ie,"Mix panel","MP"),s(Ie,"Mix Panel","MP"),Ie),rn="MOENGAGE",on=(s(Ee={},rn,rn),s(Ee,"MoEngage",rn),s(Ee,"moengage",rn),s(Ee,"Moengage",rn),s(Ee,"Mo Engage",rn),s(Ee,"mo engage",rn),s(Ee,"Mo engage",rn),Ee),sn="OPTIMIZELY",an=(s(be={},sn,sn),s(be,"Optimizely",sn),s(be,"optimizely",sn),be),un=(s(Oe={},"PENDO","PENDO"),s(Oe,"Pendo","PENDO"),s(Oe,"pendo","PENDO"),Oe),cn="PINTEREST_TAG",ln=(s(Se={},cn,cn),s(Se,"PinterestTag",cn),s(Se,"Pinterest_Tag",cn),s(Se,"PINTERESTTAG",cn),s(Se,"pinterest",cn),s(Se,"PinterestAds",cn),s(Se,"Pinterest_Ads",cn),s(Se,"Pinterest",cn),s(Se,"Pinterest Tag",cn),s(Se,"Pinterest tag",cn),s(Se,"PINTEREST TAG",cn),s(Se,"pinterest tag",cn),s(Se,"Pinterest Ads",cn),s(Se,"Pinterest ads",cn),Se),fn="POST_AFFILIATE_PRO",hn=(s(ke={},fn,fn),s(ke,"PostAffiliatePro",fn),s(ke,"Post_affiliate_pro",fn),s(ke,"Post Affiliate Pro",fn),s(ke,"Post affiliate pro",fn),s(ke,"post affiliate pro",fn),s(ke,"postaffiliatepro",fn),s(ke,"POSTAFFILIATEPRO",fn),ke),dn="POSTHOG",pn=(s(Ce={},dn,dn),s(Ce,"PostHog",dn),s(Ce,"Posthog",dn),s(Ce,"posthog",dn),s(Ce,"Post Hog",dn),s(Ce,"Post hog",dn),s(Ce,"post hog",dn),Ce),gn="PROFITWELL",yn=(s(we={},gn,gn),s(we,"ProfitWell",gn),s(we,"profitwell",gn),s(we,"Profitwell",gn),s(we,"Profit Well",gn),s(we,"profit well",gn),s(we,"Profit well",gn),we),vn="QUALTRICS",mn=(s(_e={},vn,vn),s(_e,"Qualtrics",vn),s(_e,"qualtrics",vn),_e),An="QUANTUMMETRIC",In=(s(Te={},An,An),s(Te,"Quantum Metric",An),s(Te,"quantum Metric",An),s(Te,"quantum metric",An),s(Te,"QuantumMetric",An),s(Te,"quantumMetric",An),s(Te,"quantummetric",An),s(Te,"Quantum_Metric",An),Te),En="REDDIT_PIXEL",bn=(s(Re={},En,En),s(Re,"Reddit_Pixel",En),s(Re,"RedditPixel",En),s(Re,"REDDITPIXEL",En),s(Re,"redditpixel",En),s(Re,"Reddit Pixel",En),s(Re,"REDDIT PIXEL",En),s(Re,"reddit pixel",En),Re),On=(s(Pe={},"SENTRY","SENTRY"),s(Pe,"sentry","SENTRY"),s(Pe,"Sentry","SENTRY"),Pe),Sn="SNAP_PIXEL",kn=(s(Le={},Sn,Sn),s(Le,"Snap_Pixel",Sn),s(Le,"SnapPixel",Sn),s(Le,"SNAPPIXEL",Sn),s(Le,"snappixel",Sn),s(Le,"Snap Pixel",Sn),s(Le,"SNAP PIXEL",Sn),s(Le,"snap pixel",Sn),Le),Cn="TVSQUARED",wn=(s(xe={},Cn,Cn),s(xe,"TVSquared",Cn),s(xe,"tvsquared",Cn),s(xe,"tvSquared",Cn),s(xe,"TvSquared",Cn),s(xe,"Tvsquared",Cn),s(xe,"TV Squared",Cn),s(xe,"tv squared",Cn),s(xe,"tv Squared",Cn),xe),_n=(s(Me={},"VWO","VWO"),s(Me,"VisualWebsiteOptimizer","VWO"),s(Me,"Visualwebsiteoptimizer","VWO"),s(Me,"visualwebsiteoptimizer","VWO"),s(Me,"vwo","VWO"),s(Me,"Visual Website Optimizer","VWO"),s(Me,"Visual website optimizer","VWO"),s(Me,"visual website optimizer","VWO"),Me),Tn=(s(De={},"GA360","GA360"),s(De,"Google Analytics 360","GA360"),s(De,"Google analytics 360","GA360"),s(De,"google analytics 360","GA360"),s(De,"Google Analytics360","GA360"),s(De,"Google analytics360","GA360"),s(De,"google analytics360","GA360"),s(De,"GoogleAnalytics360","GA360"),s(De,"GA 360","GA360"),De),Rn=(s(Ne={},"ADROLL","ADROLL"),s(Ne,"Adroll","ADROLL"),s(Ne,"Ad roll","ADROLL"),s(Ne,"ad roll","ADROLL"),s(Ne,"adroll","ADROLL"),Ne),Pn="DCM_FLOODLIGHT",Ln=(s(Be={},Pn,Pn),s(Be,"DCM Floodlight",Pn),s(Be,"dcm floodlight",Pn),s(Be,"Dcm Floodlight",Pn),s(Be,"DCMFloodlight",Pn),s(Be,"dcmfloodlight",Pn),s(Be,"DcmFloodlight",Pn),s(Be,"dcm_floodlight",Pn),s(Be,"DCM_Floodlight",Pn),Be),xn=(s(Ge={},"MATOMO","MATOMO"),s(Ge,"Matomo","MATOMO"),s(Ge,"matomo","MATOMO"),Ge),Mn=(s(Fe={},"VERO","VERO"),s(Fe,"Vero","VERO"),s(Fe,"vero","VERO"),Fe),Dn="MOUSEFLOW",Nn=(s(Ue={},Dn,Dn),s(Ue,"Mouseflow",Dn),s(Ue,"mouseflow",Dn),s(Ue,"mouseFlow",Dn),s(Ue,"MouseFlow",Dn),s(Ue,"Mouse flow",Dn),s(Ue,"mouse flow",Dn),s(Ue,"mouse Flow",Dn),s(Ue,"Mouse Flow",Dn),Ue),Bn="ROCKERBOX",Gn=(s(je={},Bn,Bn),s(je,"Rockerbox",Bn),s(je,"rockerbox",Bn),s(je,"RockerBox",Bn),s(je,"Rocker box",Bn),s(je,"rocker box",Bn),s(je,"Rocker Box",Bn),je),Fn="CONVERTFLOW",Un=(s(He={},Fn,Fn),s(He,"Convertflow",Fn),s(He,"convertflow",Fn),s(He,"convertFlow",Fn),s(He,"ConvertFlow",Fn),s(He,"Convert flow",Fn),s(He,"convert flow",Fn),s(He,"convert Flow",Fn),s(He,"Convert Flow",Fn),s(He,"CONVERT FLOW",Fn),He),jn="SNAPENGAGE",Hn=(s(Ke={},jn,jn),s(Ke,"SnapEngage",jn),s(Ke,"Snap_Engage",jn),s(Ke,"snapengage",jn),s(Ke,"SNAP ENGAGE",jn),s(Ke,"Snap Engage",jn),s(Ke,"snap engage",jn),Ke),Kn="LIVECHAT",zn=(s(ze={},Kn,Kn),s(ze,"LiveChat",Kn),s(ze,"Live_Chat",Kn),s(ze,"livechat",Kn),s(ze,"LIVE CHAT",Kn),s(ze,"Live Chat",Kn),s(ze,"live chat",Kn),ze),Qn="SHYNET",Vn=(s(Qe={},Qn,Qn),s(Qe,"shynet",Qn),s(Qe,"ShyNet",Qn),s(Qe,"shyNet",Qn),s(Qe,"Shynet",Qn),s(Qe,"shy net",Qn),s(Qe,"Shy Net",Qn),s(Qe,"shy Net",Qn),s(Qe,"Shy net",Qn),Qe),qn=(s(Ve={},"WOOPRA","WOOPRA"),s(Ve,"Woopra","WOOPRA"),s(Ve,"woopra","WOOPRA"),Ve),Wn="ROLLBAR",Yn=(s(qe={},Wn,Wn),s(qe,"RollBar",Wn),s(qe,"Roll_Bar",Wn),s(qe,"rollbar",Wn),s(qe,"Rollbar",Wn),s(qe,"ROLL BAR",Wn),s(qe,"Roll Bar",Wn),s(qe,"roll bar",Wn),qe),Jn="QUORA_PIXEL",Xn=(s(We={},Jn,Jn),s(We,"Quora Pixel",Jn),s(We,"Quora pixel",Jn),s(We,"QUORA PIXEL",Jn),s(We,"QuoraPixel",Jn),s(We,"Quorapixel",Jn),s(We,"QUORAPIXEL",Jn),s(We,"Quora_Pixel",Jn),s(We,"quora_pixel",Jn),s(We,"Quora",Jn),We),$n=(s(Ye={},"JUNE","JUNE"),s(Ye,"June","JUNE"),s(Ye,"june","JUNE"),Ye),Zn=(s(Je={},"ENGAGE","ENGAGE"),s(Je,"Engage","ENGAGE"),s(Je,"engage","ENGAGE"),Je),er=(s(Xe={},"ITERABLE","ITERABLE"),s(Xe,"Iterable","ITERABLE"),s(Xe,"iterable","ITERABLE"),Xe),tr="YANDEX_METRICA",nr=(s($e={},tr,tr),s($e,"Yandexmetrica",tr),s($e,"yandexmetrica",tr),s($e,"yandexMetrica",tr),s($e,"YandexMetrica",tr),$e),rr=(s(Ze={},"REFINER","REFINER"),s(Ze,"Refiner","REFINER"),s(Ze,"refiner","REFINER"),Ze),ir=(s(et={},"QUALAROO","QUALAROO"),s(et,"Qualaroo","QUALAROO"),s(et,"qualaroo","QUALAROO"),et),or="PODSIGHTS",sr=(s(tt={},or,or),s(tt,"Podsights",or),s(tt,"PodSights",or),s(tt,"pod Sights",or),s(tt,"Pod Sights",or),s(tt,"pod sights",or),s(tt,"POD SIGHTS",or),s(tt,"Pod sights",or),tt),ar=(s(nt={},"AXEPTIO","AXEPTIO"),s(nt,"Axeptio","AXEPTIO"),s(nt,"axeptio","AXEPTIO"),nt),ur="SATISMETER",cr=(s(rt={},ur,ur),s(rt,"Satismeter",ur),s(rt,"SatisMeter",ur),s(rt,"SATISMETER",ur),rt),lr="MICROSOFT_CLARITY",fr=(s(it={},lr,lr),s(it,"Microsoft Clarity",lr),s(it,"Microsoft clarity",lr),s(it,"microsoft clarity",lr),s(it,"Microsoft_clarity",lr),s(it,"MicrosoftClarity",lr),s(it,"MICROSOFTCLARITY",lr),s(it,"microsoftclarity",lr),s(it,"microsoftClarity",lr),it),hr="SENDINBLUE",dr=(s(ot={},hr,hr),s(ot,"Sendinblue",hr),s(ot,"sendinblue",hr),s(ot,"SendinBlue",hr),ot),pr=(s(st={},"OLARK","OLARK"),s(st,"Olark","OLARK"),s(st,"olark","OLARK"),st),gr=t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t(t({All:"All"},gt),yt),vt),mt),At),It),bt),St),Ct),wt),Tt),Rt),Lt),Mt),Dt),Nt),Tn),Gt),Ut),jt),Ht),Kt),zt),Qt),Vt),Wt),Yt),Xt),Zt),en),tn),nn),on),an),un),ln),hn),pn),yn),mn),In),bn),On),kn),wn),_n),Rn),Ln),xn),Mn),Nn),Un),Hn),zn),Vn),qn),Yn),Xn),$n),Zn),er),Gn),nr),rr),ir),sr),ar),cr),fr),dr),pr),yr={All:"All",GA:"Google Analytics",GOOGLEADS:"Google Ads",BRAZE:"Braze",CHARTBEAT:"Chartbeat",COMSCORE:"Comscore",CUSTOMERIO:"Customer IO",DCM_Floodlight:"DCM Floodlight",FACEBOOK_PIXEL:"Facebook Pixel",GTM:"Google Tag Manager",HOTJAR:"Hotjar",HS:"HubSpot",INTERCOM:"Intercom",KEEN:"Keen",KISSMETRICS:"Kiss Metrics",LOTAME:"Lotame",VWO:"VWO",OPTIMIZELY:"Optimizely Web",FULLSTORY:"Fullstory",TVSQUARED:"TVSquared",GA4:"Google Analytics 4",MOENGAGE:"MoEngage",AM:"Amplitude",PENDO:"Pendo",LYTICS:"Lytics",APPCUES:"Appcues",POSTHOG:"PostHog",PROFITWELL:"ProfitWell",KLAVIYO:"Klaviyo",CLEVERTAP:"CleverTap",BINGADS:"Bing Ads",PINTEREST_TAG:"Pinterest Tag",SNAP_PIXEL:"Snap Pixel",LINKEDIN_INSIGHT_TAG:"Linkedin Insight Tag",REDDIT_PIXEL:"Reddit Pixel",DRIP:"Drip",HEAP:"Heap.io",CRITEO:"Criteo",MP:"Mixpanel",QUALTRICS:"Qualtrics",SENTRY:"Sentry",GOOGLE_OPTIMIZE:"Google Optimize",POST_AFFILIATE_PRO:"Post Affiliate Pro",LAUNCHDARKLY:"LaunchDarkly",GA360:"Google Analytics 360",ADROLL:"Adroll",VERO:"Vero",MATOMO:"Matomo",MOUSEFLOW:"Mouseflow",ROCKERBOX:"Rockerbox",CONVERTFLOW:"ConvertFlow",SNAPENGAGE:"SnapEngage",LIVECHAT:"LiveChat",SHYNET:"Shynet",WOOPRA:"Woopra",ROLLBAR:"RollBar",QUORA_PIXEL:"Quora Pixel",JUNE:"June",ENGAGE:"Engage",ITERABLE:"Iterable",YANDEX_METRICA:"Yandex.Metrica",REFINER:"Refiner",QUALAROO:"Qualaroo",PODSIGHTS:"Podsights",AXEPTIO:"Axeptio",SATISMETER:"Satismeter",MICROSOFT_CLARITY:"Microsoft Clarity",SENDINBLUE:"Sendinblue",OLARK:"Olark"},vr=["anonymous_id","id","sent_at","received_at","timestamp","original_timestamp","event_text","event"],mr="https://api.rudderlabs.com/sourceConfig/?p=npm&v=2.22.3",Ar="".concat("https://cdn.rudderlabs.com","/").concat("v1.1","/").concat("js-integrations"),Ir=["bugsnag"],Er=["Lax","None","Strict"],br={},Or={},Sr={get exports(){return Or},set exports(e){Or=e}};function kr(){return at||(at=1,Sr.exports=(e=e||function(e,t){var n=Object.create||function(){function e(){}return function(t){var n;return e.prototype=t,n=new e,e.prototype=null,n}}(),r={},i=r.lib={},o=i.Base={extend:function(e){var t=n(this);return e&&t.mixIn(e),t.hasOwnProperty("init")&&this.init!==t.init||(t.init=function(){t.$super.init.apply(this,arguments)}),t.init.prototype=t,t.$super=this,t},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}},s=i.WordArray=o.extend({init:function(e,n){e=this.words=e||[],this.sigBytes=n!=t?n:4*e.length},toString:function(e){return(e||u).stringify(this)},concat:function(e){var t=this.words,n=e.words,r=this.sigBytes,i=e.sigBytes;if(this.clamp(),r%4)for(var o=0;o<i;o++){var s=n[o>>>2]>>>24-o%4*8&255;t[r+o>>>2]|=s<<24-(r+o)%4*8}else for(o=0;o<i;o+=4)t[r+o>>>2]=n[o>>>2];return this.sigBytes+=i,this},clamp:function(){var t=this.words,n=this.sigBytes;t[n>>>2]&=4294967295<<32-n%4*8,t.length=e.ceil(n/4)},clone:function(){var e=o.clone.call(this);return e.words=this.words.slice(0),e},random:function(t){for(var n,r=[],i=function(t){var n=987654321,r=4294967295;return function(){var i=((n=36969*(65535&n)+(n>>16)&r)<<16)+(t=18e3*(65535&t)+(t>>16)&r)&r;return i/=4294967296,(i+=.5)*(e.random()>.5?1:-1)}},o=0;o<t;o+=4){var a=i(4294967296*(n||e.random()));n=987654071*a(),r.push(4294967296*a()|0)}return new s.init(r,t)}}),a=r.enc={},u=a.Hex={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],i=0;i<n;i++){var o=t[i>>>2]>>>24-i%4*8&255;r.push((o>>>4).toString(16)),r.push((15&o).toString(16))}return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r<t;r+=2)n[r>>>3]|=parseInt(e.substr(r,2),16)<<24-r%8*4;return new s.init(n,t/2)}},c=a.Latin1={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],i=0;i<n;i++){var o=t[i>>>2]>>>24-i%4*8&255;r.push(String.fromCharCode(o))}return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r<t;r++)n[r>>>2]|=(255&e.charCodeAt(r))<<24-r%4*8;return new s.init(n,t)}},l=a.Utf8={stringify:function(e){try{return decodeURIComponent(escape(c.stringify(e)))}catch(e){throw new Error("Malformed UTF-8 data")}},parse:function(e){return c.parse(unescape(encodeURIComponent(e)))}},f=i.BufferedBlockAlgorithm=o.extend({reset:function(){this._data=new s.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=l.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var n=this._data,r=n.words,i=n.sigBytes,o=this.blockSize,a=i/(4*o),u=(a=t?e.ceil(a):e.max((0|a)-this._minBufferSize,0))*o,c=e.min(4*u,i);if(u){for(var l=0;l<u;l+=o)this._doProcessBlock(r,l);var f=r.splice(0,u);n.sigBytes-=c}return new s.init(f,c)},clone:function(){var e=o.clone.call(this);return e._data=this._data.clone(),e},_minBufferSize:0});i.Hasher=f.extend({cfg:o.extend(),init:function(e){this.cfg=this.cfg.extend(e),this.reset()},reset:function(){f.reset.call(this),this._doReset()},update:function(e){return this._append(e),this._process(),this},finalize:function(e){return e&&this._append(e),this._doFinalize()},blockSize:16,_createHelper:function(e){return function(t,n){return new e.init(n).finalize(t)}},_createHmacHelper:function(e){return function(t,n){return new h.HMAC.init(e,n).finalize(t)}}});var h=r.algo={};return r}(Math),e)),Or;var e}var Cr,wr={},_r={get exports(){return wr},set exports(e){wr=e}};function Tr(){return Cr||(Cr=1,_r.exports=(e=kr(),function(){var t=e,n=t.lib.WordArray;function r(e,t,r){for(var i=[],o=0,s=0;s<t;s++)if(s%4){var a=r[e.charCodeAt(s-1)]<<s%4*2,u=r[e.charCodeAt(s)]>>>6-s%4*2;i[o>>>2]|=(a|u)<<24-o%4*8,o++}return n.create(i,o)}t.enc.Base64={stringify:function(e){var t=e.words,n=e.sigBytes,r=this._map;e.clamp();for(var i=[],o=0;o<n;o+=3)for(var s=(t[o>>>2]>>>24-o%4*8&255)<<16|(t[o+1>>>2]>>>24-(o+1)%4*8&255)<<8|t[o+2>>>2]>>>24-(o+2)%4*8&255,a=0;a<4&&o+.75*a<n;a++)i.push(r.charAt(s>>>6*(3-a)&63));var u=r.charAt(64);if(u)for(;i.length%4;)i.push(u);return i.join("")},parse:function(e){var t=e.length,n=this._map,i=this._reverseMap;if(!i){i=this._reverseMap=[];for(var o=0;o<n.length;o++)i[n.charCodeAt(o)]=o}var s=n.charAt(64);if(s){var a=e.indexOf(s);-1!==a&&(t=a)}return r(e,t,i)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="}}(),e.enc.Base64)),wr;var e}var Rr,Pr={},Lr={get exports(){return Pr},set exports(e){Pr=e}};function xr(){return Rr||(Rr=1,Lr.exports=(e=kr(),function(t){var n=e,r=n.lib,i=r.WordArray,o=r.Hasher,s=n.algo,a=[];!function(){for(var e=0;e<64;e++)a[e]=4294967296*t.abs(t.sin(e+1))|0}();var u=s.MD5=o.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(e,t){for(var n=0;n<16;n++){var r=t+n,i=e[r];e[r]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var o=this._hash.words,s=e[t+0],u=e[t+1],d=e[t+2],p=e[t+3],g=e[t+4],y=e[t+5],v=e[t+6],m=e[t+7],A=e[t+8],I=e[t+9],E=e[t+10],b=e[t+11],O=e[t+12],S=e[t+13],k=e[t+14],C=e[t+15],w=o[0],_=o[1],T=o[2],R=o[3];w=c(w,_,T,R,s,7,a[0]),R=c(R,w,_,T,u,12,a[1]),T=c(T,R,w,_,d,17,a[2]),_=c(_,T,R,w,p,22,a[3]),w=c(w,_,T,R,g,7,a[4]),R=c(R,w,_,T,y,12,a[5]),T=c(T,R,w,_,v,17,a[6]),_=c(_,T,R,w,m,22,a[7]),w=c(w,_,T,R,A,7,a[8]),R=c(R,w,_,T,I,12,a[9]),T=c(T,R,w,_,E,17,a[10]),_=c(_,T,R,w,b,22,a[11]),w=c(w,_,T,R,O,7,a[12]),R=c(R,w,_,T,S,12,a[13]),T=c(T,R,w,_,k,17,a[14]),w=l(w,_=c(_,T,R,w,C,22,a[15]),T,R,u,5,a[16]),R=l(R,w,_,T,v,9,a[17]),T=l(T,R,w,_,b,14,a[18]),_=l(_,T,R,w,s,20,a[19]),w=l(w,_,T,R,y,5,a[20]),R=l(R,w,_,T,E,9,a[21]),T=l(T,R,w,_,C,14,a[22]),_=l(_,T,R,w,g,20,a[23]),w=l(w,_,T,R,I,5,a[24]),R=l(R,w,_,T,k,9,a[25]),T=l(T,R,w,_,p,14,a[26]),_=l(_,T,R,w,A,20,a[27]),w=l(w,_,T,R,S,5,a[28]),R=l(R,w,_,T,d,9,a[29]),T=l(T,R,w,_,m,14,a[30]),w=f(w,_=l(_,T,R,w,O,20,a[31]),T,R,y,4,a[32]),R=f(R,w,_,T,A,11,a[33]),T=f(T,R,w,_,b,16,a[34]),_=f(_,T,R,w,k,23,a[35]),w=f(w,_,T,R,u,4,a[36]),R=f(R,w,_,T,g,11,a[37]),T=f(T,R,w,_,m,16,a[38]),_=f(_,T,R,w,E,23,a[39]),w=f(w,_,T,R,S,4,a[40]),R=f(R,w,_,T,s,11,a[41]),T=f(T,R,w,_,p,16,a[42]),_=f(_,T,R,w,v,23,a[43]),w=f(w,_,T,R,I,4,a[44]),R=f(R,w,_,T,O,11,a[45]),T=f(T,R,w,_,C,16,a[46]),w=h(w,_=f(_,T,R,w,d,23,a[47]),T,R,s,6,a[48]),R=h(R,w,_,T,m,10,a[49]),T=h(T,R,w,_,k,15,a[50]),_=h(_,T,R,w,y,21,a[51]),w=h(w,_,T,R,O,6,a[52]),R=h(R,w,_,T,p,10,a[53]),T=h(T,R,w,_,E,15,a[54]),_=h(_,T,R,w,u,21,a[55]),w=h(w,_,T,R,A,6,a[56]),R=h(R,w,_,T,C,10,a[57]),T=h(T,R,w,_,v,15,a[58]),_=h(_,T,R,w,S,21,a[59]),w=h(w,_,T,R,g,6,a[60]),R=h(R,w,_,T,b,10,a[61]),T=h(T,R,w,_,d,15,a[62]),_=h(_,T,R,w,I,21,a[63]),o[0]=o[0]+w|0,o[1]=o[1]+_|0,o[2]=o[2]+T|0,o[3]=o[3]+R|0},_doFinalize:function(){var e=this._data,n=e.words,r=8*this._nDataBytes,i=8*e.sigBytes;n[i>>>5]|=128<<24-i%32;var o=t.floor(r/4294967296),s=r;n[15+(i+64>>>9<<4)]=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),n[14+(i+64>>>9<<4)]=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8),e.sigBytes=4*(n.length+1),this._process();for(var a=this._hash,u=a.words,c=0;c<4;c++){var l=u[c];u[c]=16711935&(l<<8|l>>>24)|4278255360&(l<<24|l>>>8)}return a},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});function c(e,t,n,r,i,o,s){var a=e+(t&n|~t&r)+i+s;return(a<<o|a>>>32-o)+t}function l(e,t,n,r,i,o,s){var a=e+(t&r|n&~r)+i+s;return(a<<o|a>>>32-o)+t}function f(e,t,n,r,i,o,s){var a=e+(t^n^r)+i+s;return(a<<o|a>>>32-o)+t}function h(e,t,n,r,i,o,s){var a=e+(n^(t|~r))+i+s;return(a<<o|a>>>32-o)+t}n.MD5=o._createHelper(u),n.HmacMD5=o._createHmacHelper(u)}(Math),e.MD5)),Pr;var e}var Mr,Dr={},Nr={get exports(){return Dr},set exports(e){Dr=e}},Br={},Gr={get exports(){return Br},set exports(e){Br=e}};function Fr(){return Mr||(Mr=1,Gr.exports=(a=kr(),t=(e=a).lib,n=t.WordArray,r=t.Hasher,i=e.algo,o=[],s=i.SHA1=r.extend({_doReset:function(){this._hash=new n.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(e,t){for(var n=this._hash.words,r=n[0],i=n[1],s=n[2],a=n[3],u=n[4],c=0;c<80;c++){if(c<16)o[c]=0|e[t+c];else{var l=o[c-3]^o[c-8]^o[c-14]^o[c-16];o[c]=l<<1|l>>>31}var f=(r<<5|r>>>27)+u+o[c];f+=c<20?1518500249+(i&s|~i&a):c<40?1859775393+(i^s^a):c<60?(i&s|i&a|s&a)-1894007588:(i^s^a)-899497514,u=a,a=s,s=i<<30|i>>>2,i=r,r=f}n[0]=n[0]+r|0,n[1]=n[1]+i|0,n[2]=n[2]+s|0,n[3]=n[3]+a|0,n[4]=n[4]+u|0},_doFinalize:function(){var e=this._data,t=e.words,n=8*this._nDataBytes,r=8*e.sigBytes;return t[r>>>5]|=128<<24-r%32,t[14+(r+64>>>9<<4)]=Math.floor(n/4294967296),t[15+(r+64>>>9<<4)]=n,e.sigBytes=4*t.length,this._process(),this._hash},clone:function(){var e=r.clone.call(this);return e._hash=this._hash.clone(),e}}),e.SHA1=r._createHelper(s),e.HmacSHA1=r._createHmacHelper(s),a.SHA1)),Br;var e,t,n,r,i,o,s,a}var Ur,jr,Hr={},Kr={get exports(){return Hr},set exports(e){Hr=e}};function zr(){return jr||(jr=1,Nr.exports=function(e){return n=(t=e).lib,r=n.Base,i=n.WordArray,o=t.algo,s=o.MD5,a=o.EvpKDF=r.extend({cfg:r.extend({keySize:4,hasher:s,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){for(var n=this.cfg,r=n.hasher.create(),o=i.create(),s=o.words,a=n.keySize,u=n.iterations;s.length<a;){c&&r.update(c);var c=r.update(e).finalize(t);r.reset();for(var l=1;l<u;l++)c=r.finalize(c),r.reset();o.concat(c)}return o.sigBytes=4*a,o}}),t.EvpKDF=function(e,t,n){return a.create(n).compute(e,t)},e.EvpKDF;var t,n,r,i,o,s,a}(kr(),Fr(),Ur||(Ur=1,Kr.exports=(e=kr(),void function(){var t=e,n=t.lib.Base,r=t.enc.Utf8;t.algo.HMAC=n.extend({init:function(e,t){e=this._hasher=new e.init,"string"==typeof t&&(t=r.parse(t));var n=e.blockSize,i=4*n;t.sigBytes>i&&(t=e.finalize(t)),t.clamp();for(var o=this._oKey=t.clone(),s=this._iKey=t.clone(),a=o.words,u=s.words,c=0;c<n;c++)a[c]^=1549556828,u[c]^=909522486;o.sigBytes=s.sigBytes=i,this.reset()},reset:function(){var e=this._hasher;e.reset(),e.update(this._iKey)},update:function(e){return this._hasher.update(e),this},finalize:function(e){var t=this._hasher,n=t.finalize(e);return t.reset(),t.finalize(this._oKey.clone().concat(n))}})}())))),Dr;var e}var Qr,Vr,qr={},Wr={get exports(){return qr},set exports(e){qr=e}};({get exports(){return br},set exports(e){br=e}}).exports=function(e){return function(){var t=e,n=t.lib.BlockCipher,r=t.algo,i=[],o=[],s=[],a=[],u=[],c=[],l=[],f=[],h=[],d=[];!function(){for(var e=[],t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;var n=0,r=0;for(t=0;t<256;t++){var p=r^r<<1^r<<2^r<<3^r<<4;p=p>>>8^255&p^99,i[n]=p,o[p]=n;var g=e[n],y=e[g],v=e[y],m=257*e[p]^16843008*p;s[n]=m<<24|m>>>8,a[n]=m<<16|m>>>16,u[n]=m<<8|m>>>24,c[n]=m,m=16843009*v^65537*y^257*g^16843008*n,l[p]=m<<24|m>>>8,f[p]=m<<16|m>>>16,h[p]=m<<8|m>>>24,d[p]=m,n?(n=g^e[e[e[v^g]]],r^=e[e[r]]):n=r=1}}();var p=[0,1,2,4,8,16,32,64,128,27,54],g=r.AES=n.extend({_doReset:function(){if(!this._nRounds||this._keyPriorReset!==this._key){for(var e=this._keyPriorReset=this._key,t=e.words,n=e.sigBytes/4,r=4*((this._nRounds=n+6)+1),o=this._keySchedule=[],s=0;s<r;s++)if(s<n)o[s]=t[s];else{var a=o[s-1];s%n?n>6&&s%n==4&&(a=i[a>>>24]<<24|i[a>>>16&255]<<16|i[a>>>8&255]<<8|i[255&a]):(a=i[(a=a<<8|a>>>24)>>>24]<<24|i[a>>>16&255]<<16|i[a>>>8&255]<<8|i[255&a],a^=p[s/n|0]<<24),o[s]=o[s-n]^a}for(var u=this._invKeySchedule=[],c=0;c<r;c++)s=r-c,a=c%4?o[s]:o[s-4],u[c]=c<4||s<=4?a:l[i[a>>>24]]^f[i[a>>>16&255]]^h[i[a>>>8&255]]^d[i[255&a]]}},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._keySchedule,s,a,u,c,i)},decryptBlock:function(e,t){var n=e[t+1];e[t+1]=e[t+3],e[t+3]=n,this._doCryptBlock(e,t,this._invKeySchedule,l,f,h,d,o),n=e[t+1],e[t+1]=e[t+3],e[t+3]=n},_doCryptBlock:function(e,t,n,r,i,o,s,a){for(var u=this._nRounds,c=e[t]^n[0],l=e[t+1]^n[1],f=e[t+2]^n[2],h=e[t+3]^n[3],d=4,p=1;p<u;p++){var g=r[c>>>24]^i[l>>>16&255]^o[f>>>8&255]^s[255&h]^n[d++],y=r[l>>>24]^i[f>>>16&255]^o[h>>>8&255]^s[255&c]^n[d++],v=r[f>>>24]^i[h>>>16&255]^o[c>>>8&255]^s[255&l]^n[d++],m=r[h>>>24]^i[c>>>16&255]^o[l>>>8&255]^s[255&f]^n[d++];c=g,l=y,f=v,h=m}g=(a[c>>>24]<<24|a[l>>>16&255]<<16|a[f>>>8&255]<<8|a[255&h])^n[d++],y=(a[l>>>24]<<24|a[f>>>16&255]<<16|a[h>>>8&255]<<8|a[255&c])^n[d++],v=(a[f>>>24]<<24|a[h>>>16&255]<<16|a[c>>>8&255]<<8|a[255&l])^n[d++],m=(a[h>>>24]<<24|a[c>>>16&255]<<16|a[l>>>8&255]<<8|a[255&f])^n[d++],e[t]=g,e[t+1]=y,e[t+2]=v,e[t+3]=m},keySize:8});t.AES=n._createHelper(g)}(),e.AES}(kr(),Tr(),xr(),zr(),Qr||(Qr=1,Wr.exports=(Vr=kr(),zr(),void(Vr.lib.Cipher||function(e){var t=Vr,n=t.lib,r=n.Base,i=n.WordArray,o=n.BufferedBlockAlgorithm,s=t.enc;s.Utf8;var a=s.Base64,u=t.algo.EvpKDF,c=n.Cipher=o.extend({cfg:r.extend(),createEncryptor:function(e,t){return this.create(this._ENC_XFORM_MODE,e,t)},createDecryptor:function(e,t){return this.create(this._DEC_XFORM_MODE,e,t)},init:function(e,t,n){this.cfg=this.cfg.extend(n),this._xformMode=e,this._key=t,this.reset()},reset:function(){o.reset.call(this),this._doReset()},process:function(e){return this._append(e),this._process()},finalize:function(e){return e&&this._append(e),this._doFinalize()},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function e(e){return"string"==typeof e?m:y}return function(t){return{encrypt:function(n,r,i){return e(r).encrypt(t,n,r,i)},decrypt:function(n,r,i){return e(r).decrypt(t,n,r,i)}}}}()});n.StreamCipher=c.extend({_doFinalize:function(){return this._process(!0)},blockSize:1});var l=t.mode={},f=n.BlockCipherMode=r.extend({createEncryptor:function(e,t){return this.Encryptor.create(e,t)},createDecryptor:function(e,t){return this.Decryptor.create(e,t)},init:function(e,t){this._cipher=e,this._iv=t}}),h=l.CBC=function(){var t=f.extend();function n(t,n,r){var i=this._iv;if(i){var o=i;this._iv=e}else o=this._prevBlock;for(var s=0;s<r;s++)t[n+s]^=o[s]}return t.Encryptor=t.extend({processBlock:function(e,t){var r=this._cipher,i=r.blockSize;n.call(this,e,t,i),r.encryptBlock(e,t),this._prevBlock=e.slice(t,t+i)}}),t.Decryptor=t.extend({processBlock:function(e,t){var r=this._cipher,i=r.blockSize,o=e.slice(t,t+i);r.decryptBlock(e,t),n.call(this,e,t,i),this._prevBlock=o}}),t}(),d=(t.pad={}).Pkcs7={pad:function(e,t){for(var n=4*t,r=n-e.sigBytes%n,o=r<<24|r<<16|r<<8|r,s=[],a=0;a<r;a+=4)s.push(o);var u=i.create(s,r);e.concat(u)},unpad:function(e){var t=255&e.words[e.sigBytes-1>>>2];e.sigBytes-=t}};n.BlockCipher=c.extend({cfg:c.cfg.extend({mode:h,padding:d}),reset:function(){c.reset.call(this);var e=this.cfg,t=e.iv,n=e.mode;if(this._xformMode==this._ENC_XFORM_MODE)var r=n.createEncryptor;else r=n.createDecryptor,this._minBufferSize=1;this._mode&&this._mode.__creator==r?this._mode.init(this,t&&t.words):(this._mode=r.call(n,this,t&&t.words),this._mode.__creator=r)},_doProcessBlock:function(e,t){this._mode.processBlock(e,t)},_doFinalize:function(){var e=this.cfg.padding;if(this._xformMode==this._ENC_XFORM_MODE){e.pad(this._data,this.blockSize);var t=this._process(!0)}else t=this._process(!0),e.unpad(t);return t},blockSize:4});var p=n.CipherParams=r.extend({init:function(e){this.mixIn(e)},toString:function(e){return(e||this.formatter).stringify(this)}}),g=(t.format={}).OpenSSL={stringify:function(e){var t=e.ciphertext,n=e.salt;if(n)var r=i.create([1398893684,1701076831]).concat(n).concat(t);else r=t;return r.toString(a)},parse:function(e){var t=a.parse(e),n=t.words;if(1398893684==n[0]&&1701076831==n[1]){var r=i.create(n.slice(2,4));n.splice(0,4),t.sigBytes-=16}return p.create({ciphertext:t,salt:r})}},y=n.SerializableCipher=r.extend({cfg:r.extend({format:g}),encrypt:function(e,t,n,r){r=this.cfg.extend(r);var i=e.createEncryptor(n,r),o=i.finalize(t),s=i.cfg;return p.create({ciphertext:o,key:n,iv:s.iv,algorithm:e,mode:s.mode,padding:s.padding,blockSize:e.blockSize,formatter:r.format})},decrypt:function(e,t,n,r){return r=this.cfg.extend(r),t=this._parse(t,r.format),e.createDecryptor(n,r).finalize(t.ciphertext)},_parse:function(e,t){return"string"==typeof e?t.parse(e,this):e}}),v=(t.kdf={}).OpenSSL={execute:function(e,t,n,r){r||(r=i.random(8));var o=u.create({keySize:t+n}).compute(e,r),s=i.create(o.words.slice(t),4*n);return o.sigBytes=4*t,p.create({key:o,iv:s,salt:r})}},m=n.PasswordBasedCipher=y.extend({cfg:y.cfg.extend({kdf:v}),encrypt:function(e,t,n,r){var i=(r=this.cfg.extend(r)).kdf.execute(n,e.keySize,e.ivSize);r.iv=i.iv;var o=y.encrypt.call(this,e,t,i.key,r);return o.mixIn(i),o},decrypt:function(e,t,n,r){r=this.cfg.extend(r),t=this._parse(t,r.format);var i=r.kdf.execute(n,e.keySize,e.ivSize,t.salt);return r.iv=i.iv,y.decrypt.call(this,e,t,i.key,r)}})}()))));var Yr=br,Jr={};({get exports(){return Jr},set exports(e){Jr=e}}).exports=function(e){return e.enc.Utf8}(kr());var Xr,$r,Zr=Jr,ei={};function ti(){if($r)return Xr;$r=1;var e=1e3,t=60*e,n=60*t,r=24*n,i=7*r,o=365.25*r;function s(e,t,n,r){var i=t>=1.5*n;return Math.round(e/n)+" "+r+(i?"s":"")}return Xr=function(a,u){u=u||{};var c=typeof a;if("string"===c&&a.length>0)return function(s){if((s=String(s)).length>100)return;var a=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(s);if(!a)return;var u=parseFloat(a[1]);switch((a[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return u*o;case"weeks":case"week":case"w":return u*i;case"days":case"day":case"d":return u*r;case"hours":case"hour":case"hrs":case"hr":case"h":return u*n;case"minutes":case"minute":case"mins":case"min":case"m":return u*t;case"seconds":case"second":case"secs":case"sec":case"s":return u*e;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return u;default:return}}(a);if("number"===c&&isFinite(a))return u.long?function(i){var o=Math.abs(i);if(o>=r)return s(i,o,r,"day");if(o>=n)return s(i,o,n,"hour");if(o>=t)return s(i,o,t,"minute");if(o>=e)return s(i,o,e,"second");return i+" ms"}(a):function(i){var o=Math.abs(i);if(o>=r)return Math.round(i/r)+"d";if(o>=n)return Math.round(i/n)+"h";if(o>=t)return Math.round(i/t)+"m";if(o>=e)return Math.round(i/e)+"s";return i+"ms"}(a);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(a))},Xr}var ni=function(e){function t(e){let r,i,o,s=null;function a(...e){if(!a.enabled)return;const n=a,i=Number(new Date),o=i-(r||i);n.diff=o,n.prev=r,n.curr=i,r=i,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let s=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((r,i)=>{if("%%"===r)return"%";s++;const o=t.formatters[i];if("function"==typeof o){const t=e[s];r=o.call(n,t),e.splice(s,1),s--}return r})),t.formatArgs.call(n,e);(n.log||t.log).apply(n,e)}return a.namespace=e,a.useColors=t.useColors(),a.color=t.selectColor(e),a.extend=n,a.destroy=t.destroy,Object.defineProperty(a,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==s?s:(i!==t.namespaces&&(i=t.namespaces,o=t.enabled(e)),o),set:e=>{s=e}}),"function"==typeof t.init&&t.init(a),a}function n(e,n){const r=t(this.namespace+(void 0===n?":":n)+e);return r.log=this.log,r}function r(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return t.debug=t,t.default=t,t.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},t.disable=function(){const e=[...t.names.map(r),...t.skips.map(r).map((e=>"-"+e))].join(",");return t.enable(""),e},t.enable=function(e){let n;t.save(e),t.namespaces=e,t.names=[],t.skips=[];const r=("string"==typeof e?e:"").split(/[\s,]+/),i=r.length;for(n=0;n<i;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.slice(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){if("*"===e[e.length-1])return!0;let n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=ti(),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach((n=>{t[n]=e[n]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let n=0;for(let t=0;t<e.length;t++)n=(n<<5)-n+e.charCodeAt(t),n|=0;return t.colors[Math.abs(n)%t.colors.length]},t.enable(t.load()),t};!function(e,t){t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(r++,"%c"===e&&(i=r))})),t.splice(i,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=ni(t);const{formatters:n}=e.exports;n.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}({get exports(){return ei},set exports(e){ei=e}},ei);var ri=ei("cookie"),ii=function(e,t,n){switch(arguments.length){case 3:case 2:return oi(e,t,n);case 1:return ai(e);default:return si()}};function oi(e,t,n){n=n||{};var r=ui(e)+"="+ui(t);null==t&&(n.maxage=-1),n.maxage&&(n.expires=new Date(+new Date+n.maxage)),n.path&&(r+="; path="+n.path),n.domain&&(r+="; domain="+n.domain),n.expires&&(r+="; expires="+n.expires.toUTCString()),n.samesite&&(r+="; samesite="+n.samesite),n.secure&&(r+="; secure"),document.cookie=r}function si(){var e;try{e=document.cookie}catch(e){return"undefined"!=typeof console&&"function"==typeof console.error&&console.error(e.stack||e),{}}return function(e){var t,n={},r=e.split(/ *; */);if(""==r[0])return n;for(var i=0;i<r.length;++i)n[ci((t=r[i].split("="))[0])]=ci(t[1]);return n}(e)}function ai(e){return si()[e]}function ui(e){try{return encodeURIComponent(e)}catch(t){ri("error `encode(%o)` - %o",e,t)}}function ci(e){try{return decodeURIComponent(e)}catch(t){ri("error `decode(%o)` - %o",e,t)}}var li={},fi={get exports(){return li},set exports(e){li=e}},hi=Math.max,di=function(e,t){var n=t?t.length:0;if(!n)return[];for(var r=hi(Number(e)||0,0),i=hi(n-r,0),o=new Array(i),s=0;s<i;s+=1)o[s]=t[s+r];return o},pi=Math.max,gi=function(e){if(null==e||!e.length)return[];for(var t=new Array(pi(e.length-2,0)),n=1;n<e.length;n+=1)t[n-1]=e[n];return t},yi=di,vi=gi,mi=Object.prototype.hasOwnProperty,Ai=Object.prototype.toString,Ii=function(e){return Boolean(e)&&"object"==typeof e},Ei=function(e){return Boolean(e)&&"[object Object]"===Ai.call(e)},bi=function(e,t,n,r){return mi.call(t,r)&&void 0===e[r]&&(e[r]=n),t},Oi=function(e,t,n,r){return mi.call(t,r)&&(Ei(e[r])&&Ei(n)?e[r]=ki(e[r],n):void 0===e[r]&&(e[r]=n)),t},Si=function(e,t){if(!Ii(t))return t;e=e||bi;for(var n=yi(2,arguments),r=0;r<n.length;r+=1)for(var i in n[r])e(t,n[r],n[r][i],i);return t},ki=function(e){return Si.apply(null,[Oi,e].concat(vi(arguments)))};fi.exports=function(e){return Si.apply(null,[null,e].concat(vi(arguments)))},li.deep=ki;var Ci={},wi={get exports(){return Ci},set exports(e){Ci=e}},_i=ei("cookie"),Ti=function(e,t,n){switch(arguments.length){case 3:case 2:return Ri(e,t,n);case 1:return Li(e);default:return Pi()}};function Ri(e,t,n){n=n||{};var r=xi(e)+"="+xi(t);null==t&&(n.maxage=-1),n.maxage&&(n.expires=new Date(+new Date+n.maxage)),n.path&&(r+="; path="+n.path),n.domain&&(r+="; domain="+n.domain),n.expires&&(r+="; expires="+n.expires.toUTCString()),n.secure&&(r+="; secure"),document.cookie=r}function Pi(){var e;try{e=document.cookie}catch(e){return"undefined"!=typeof console&&"function"==typeof console.error&&console.error(e.stack||e),{}}return function(e){var t,n={},r=e.split(/ *; */);if(""==r[0])return n;for(var i=0;i<r.length;++i)n[Mi((t=r[i].split("="))[0])]=Mi(t[1]);return n}(e)}function Li(e){return Pi()[e]}function xi(e){try{return encodeURIComponent(e)}catch(t){_i("error `encode(%o)` - %o",e,t)}}function Mi(e){try{return decodeURIComponent(e)}catch(t){_i("error `decode(%o)` - %o",e,t)}}!function(e,t){var n=D.parse,r=Ti;function i(e){for(var n=t.cookie,r=t.levels(e),i=0;i<r.length;++i){var o="__tld__",s=r[i],a={domain:"."+s};if(n(o,1,a),n(o))return n(o,null,a),s}return""}i.levels=function(e){var t=n(e).hostname.split("."),r=t[t.length-1],i=[];if(4===t.length&&r===parseInt(r,10))return i;if(t.length<=1)return i;for(var o=t.length-2;o>=0;--o)i.push(t.slice(o).join("."));return i},i.cookie=r,t=e.exports=i}(wi,Ci);var Di=Ci,Ni=new(function(){function e(t){r(this,e),this.cOpts={},this.options(t),this.isSupportAvailable=this.checkSupportAvailability()}return o(e,[{key:"options",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(0===arguments.length)return this.cOpts;var t=".".concat(Di(window.location.href));return"."===t&&(t=null),this.cOpts=li(e,{maxage:31536e6,path:"/",domain:t,samesite:"Lax"}),this.cOpts}},{key:"set",value:function(e,t){try{return ii(e,t,R(this.cOpts)),!0}catch(e){return dt(e),!1}}},{key:"get",value:function(e){return ii(e)}},{key:"remove",value:function(e){try{return ii(e,null,R(this.cOpts)),!0}catch(e){return!1}}},{key:"checkSupportAvailability",value:function(){var e="test_rudder_cookie";return this.set(e,!0),!!this.get(e)&&(this.remove(e),!0)}}]),e}())({}),Bi={};({get exports(){return Bi},set exports(e){Bi=e}}).exports=function(){var e=window.localStorage;function t(e){return e=JSON.stringify(e),!!/^\{[\s\S]*\}$/.test(e)}function n(e){return void 0===e||"function"==typeof e?e+"":JSON.stringify(e)}function r(e){if("string"==typeof e)try{return JSON.parse(e)}catch(t){return e}}function i(e){return"[object Function]"==={}.toString.call(e)}function o(e){return"[object Array]"===Object.prototype.toString.call(e)}function s(e){var t="_Is_Incognit",n="yes";try{e.setItem(t,n)}catch(t){if("QuotaExceededError"===t.name){var r=function(){};e.__proto__={setItem:r,getItem:r,removeItem:r,clear:r}}}finally{e.getItem(t)===n&&e.removeItem(t)}return e}function a(){if(!(this instanceof a))return new a}e=s(e),a.prototype={set:function(r,i){if(r&&!t(r))e.setItem(r,n(i));else if(t(r))for(var o in r)this.set(o,r[o]);return this},get:function(t){if(!t){var n={};return this.forEach((function(e,t){return n[e]=t})),n}if("?"===t.charAt(0))return this.has(t.substr(1));var i=arguments;if(i.length>1){for(var o={},s=0,a=i.length;s<a;s++){var u=r(e.getItem(i[s]));this.has(i[s])&&(o[i[s]]=u)}return o}return r(e.getItem(t))},clear:function(){return e.clear(),this},remove:function(t){var n=this.get(t);return e.removeItem(t),n},has:function(e){return{}.hasOwnProperty.call(this.get(),e)},keys:function(){var e=[];return this.forEach((function(t){e.push(t)})),e},forEach:function(t){for(var n=0,r=e.length;n<r;n++){var i=e.key(n);t(i,this.get(i))}return this},search:function(e){for(var t=this.keys(),n={},r=0,i=t.length;r<i;r++)t[r].indexOf(e)>-1&&(n[t[r]]=this.get(t[r]));return n}};var u=null;function c(e,n){var r=arguments,s=null;if(u||(u=a()),0===r.length)return u.get();if(1===r.length){if("string"==typeof e)return u.get(e);if(t(e))return u.set(e)}if(2===r.length&&"string"==typeof e){if(!n)return u.remove(e);if(n&&"string"==typeof n)return u.set(e,n);n&&i(n)&&(s=null,s=n(e,u.get(e)),c.set(e,s))}if(2===r.length&&o(e)&&i(n))for(var l=0,f=e.length;l<f;l++)s=n(e[l],u.get(e[l])),c.set(e[l],s);return c}for(var l in a.prototype)c[l]=a.prototype[l];return c}();var Gi=Bi,Fi=new(function(){function e(t){r(this,e),this.sOpts={},this.enabled=this.checkSupportAvailability(),this.options(t)}return o(e,[{key:"options",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return 0===arguments.length||(li(e,{enabled:!0}),this.enabled=e.enabled&&this.enabled,this.sOpts=e),this.sOpts}},{key:"set",value:function(e,t){return Gi.set(e,t)}},{key:"get",value:function(e){return Gi.get(e)}},{key:"remove",value:function(e){return Gi.remove(e)}},{key:"checkSupportAvailability",value:function(){var e="test_rudder_ls";return this.set(e,!0),!!this.get(e)&&(this.remove(e),!0)}}]),e}())({}),Ui="rl_user_id",ji="rl_trait",Hi="rl_anonymous_id",Ki="rl_group_id",zi="rl_group_trait",Qi="rl_page_init_referrer",Vi="rl_page_init_referring_domain",qi="rl_session",Wi="RudderEncrypt:",Yi="Rudder",Ji={segment:"ajs_anonymous_id"};function Xi(e){try{return e?JSON.parse(e):null}catch(t){return dt(t),e||null}}function $i(e){return e.replace(/^\s+|\s+$/gm,"")}function Zi(e){return!e||"string"==typeof e&&""===$i(e)?e:e.substring(0,Wi.length)===Wi?Yr.decrypt(e.substring(Wi.length),Yi).toString(Zr):e}var eo=function(){function e(){r(this,e),Ni.isSupportAvailable?this.storage=Ni:(Fi.enabled&&(this.storage=Fi),this.storage||dt("No storage is available :: initializing the SDK without storage"))}return o(e,[{key:"options",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.storage.options(e)}},{key:"setItem",value:function(e,t){this.storage.set(e,function(e){return""===$i(e)?e:"".concat(Wi).concat(Yr.encrypt(e,Yi).toString())}(function(e){return JSON.stringify(e)}(t)))}},{key:"setStringItem",value:function(e,t){"string"==typeof t?this.setItem(e,t):dt("[Storage] ".concat(e," should be string"))}},{key:"setUserId",value:function(e){this.setStringItem(Ui,e)}},{key:"setUserTraits",value:function(e){this.setItem(ji,e)}},{key:"setGroupId",value:function(e){this.setStringItem(Ki,e)}},{key:"setGroupTraits",value:function(e){this.setItem(zi,e)}},{key:"setAnonymousId",value:function(e){this.setStringItem(Hi,e)}},{key:"setInitialReferrer",value:function(e){this.setItem(Qi,e)}},{key:"setInitialReferringDomain",value:function(e){this.setItem(Vi,e)}},{key:"setSessionInfo",value:function(e){this.setItem(qi,e)}},{key:"getItem",value:function(e){return Xi(Zi(this.storage.get(e)))}},{key:"getUserId",value:function(){return this.getItem(Ui)}},{key:"getUserTraits",value:function(){return this.getItem(ji)}},{key:"getGroupId",value:function(){return this.getItem(Ki)}},{key:"getGroupTraits",value:function(){return this.getItem(zi)}},{key:"fetchExternalAnonymousId",value:function(e){var t,n=e.toLowerCase();return Object.keys(Ji).includes(n)&&"segment"===n?(Fi.enabled&&(t=Fi.get(Ji[n])),!t&&Ni.isSupportAvailable&&(t=Ni.get(Ji[n])),t):t}},{key:"getAnonymousId",value:function(e){var t=Xi(Zi(this.storage.get(Hi)));if(t)return t;var n=B(e,"autoCapture.source");if(!0===B(e,"autoCapture.enabled")&&"string"==typeof n){var r=this.fetchExternalAnonymousId(n);if(r)return r}return t}},{key:"getInitialReferrer",value:function(){return this.getItem(Qi)}},{key:"getInitialReferringDomain",value:function(){return this.getItem(Vi)}},{key:"getSessionInfo",value:function(){return this.getItem(qi)}},{key:"removeItem",value:function(e){return this.storage.remove(e)}},{key:"removeSessionInfo",value:function(){this.removeItem(qi)}},{key:"clear",value:function(e){this.storage.remove(Ui),this.storage.remove(ji),this.storage.remove(Ki),this.storage.remove(zi),e&&this.storage.remove(Hi)}}]),e}(),to=new eo,no=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=document.getElementById(e);if(!r){var i=document.createElement("script");i.src=t,i.async=void 0===n.async||n.async,i.type="text/javascript",i.id=e,!0!==n.skipDatasetAttributes&&(i.setAttribute("data-loader","RS_JS_SDK"),void 0!==n.isNonNativeSDK&&i.setAttribute("data-isNonNativeSDK",n.isNonNativeSDK));var o=document.getElementsByTagName("head");if(0!==o.length)o[0].insertBefore(i,o[0].firstChild);else{var s=document.getElementsByTagName("script")[0];s.parentNode.insertBefore(i,s)}}};function ro(e){window.rsBugsnagClient&&window.rsBugsnagClient.leaveBreadcrumb(e)}function io(e){window.rsBugsnagClient&&window.rsBugsnagClient.notify(e)}function oo(e,t,n){var r;try{r=function(e,t,n){var r;try{r="string"==typeof e?e:e instanceof Error||e.message?e.message:JSON.stringify(e)}catch(e){r=""}if(e instanceof Event){if(e.target&&"script"!==e.target.localName)return"";if(e.target.dataset&&("RS_JS_SDK"!==e.target.dataset.loader||"true"!==e.target.dataset.isNonNativeSDK))return"";if(r="error in script loading:: src:: ".concat(e.target.src," id:: ").concat(e.target.id),"ad-block"===e.target.id)return n.page("RudderJS-Initiated","ad-block page request",{path:"/ad-blocked",title:r},n.sendAdblockPageOptions),""}return"[handleError]::".concat(t||"",' "').concat(r,'"')}(e,t,n)}catch(t){dt("[handleError] Exception:: ",t),dt("[handleError] Original error:: ",JSON.stringify(e)),io(t)}if(r){dt(r);var i=e;e instanceof Error||(i=new Error(r)),io(i)}}function so(e,t){if(null!=t)return t}function ao(e){return e&&e.endsWith("/")?e.replace(/\/+$/,""):e}function uo(){return function(){var e,t=0,n="";if(!j||H+16>256){for(j=Array(t=256);t--;)j[t]=256*Math.random()|0;t=H=0}for(;t<16;t++)e=j[H+t],n+=6==t?K[15&e|64]:8==t?K[63&e|128]:K[e],1&t&&t>1&&t<11&&(n+="-");return H++,n}()}function co(){return(new Date).toISOString()}function lo(){var e=po(),t=e?D.parse(e).pathname:window.location.pathname,n=window.location.search,r=document.title,i=function(e){var t=po(),n=t?t.indexOf("?")>-1?t:t+e:window.location.href,r=n.indexOf("#");return r>-1?n.slice(0,r):n}(n),o=window.location.href,s=fo();return{path:t,referrer:s,referring_domain:ho(s),search:n,title:r,url:i,tab_url:o,initial_referrer:to.getInitialReferrer(),initial_referring_domain:to.getInitialReferringDomain()}}function fo(){return document.referrer||"$direct"}function ho(e){var t=e.split("/");return t.length>=3?t[2]:""}function po(){for(var e,t=document.getElementsByTagName("link"),n=0;e=t[n];n++)if("canonical"===e.getAttribute("rel"))return e.getAttribute("href")}function go(e,t){Object.keys(e).forEach((function(n){e.hasOwnProperty(n)&&(t[n]&&(e[t[n]]=e[n]),"All"!=n&&null!=t[n]&&t[n]!=n&&delete e[n])}))}function yo(e){go(e,gr)}function vo(e,t){var r=[];if(!t||0===t.length)return r;var i=!0;void 0!==e.All&&(i=e.All);var o=[];return"string"==typeof t[0]?t.forEach((function(e){o.push({intgName:e,intObj:e})})):"object"===n(t[0])&&t.forEach((function(e){o.push({intgName:e.name,intObj:e})})),o.forEach((function(t){var n=t.intgName,o=t.intObj;if(i){var s=!0;null!=e[n]&&0==e[n]&&(s=!1),s&&r.push(o)}else null!=e[n]&&1==e[n]&&r.push(o)})),r}for(var mo,Ao=function(){for(var e,t=document.getElementsByTagName("script"),n=!1,r=0;r<t.length;r+=1){var i=ao(t[r].getAttribute("src"));if(i){var o=i.match(/^.*rudder-analytics(-staging)?(\.min)?\.js$/);if(o){e=i,n=void 0!==o[1];break}}}return{sdkURL:e,isStaging:n}},Io=function(e){return"string"==typeof e||null==e?e:JSON.stringify(e)},Eo=o((function e(){r(this,e),this.name="RudderLabs JavaScript SDK",this.namespace="com.rudderlabs.javascript",this.version="2.22.3"})),bo=o((function e(){r(this,e),this.name="RudderLabs JavaScript SDK",this.version="2.22.3"})),Oo=o((function e(){r(this,e),this.name="",this.version=""})),So=o((function e(){r(this,e),this.density=0,this.width=0,this.height=0,this.innerWidth=0,this.innerHeight=0})),ko=o((function e(){var t;r(this,e),this.app=new Eo,this.traits=null,this.library=new bo,this.userAgent=function(){if("undefined"==typeof navigator)return null;var e=navigator.userAgent,t=navigator.brave;if(t&&Object.getPrototypeOf(t).isBrave){var n=e.match(/(chrome)\/([\w.]+)/i);n&&(e="".concat(e," Brave/").concat(n[2]))}return e}(),this.device=null,this.network=null,this.os=new Oo,this.locale="undefined"==typeof navigator?null:navigator.language||navigator.browserLanguage,this.screen=(t=new So,"undefined"==typeof window||(t.width=window.screen.width,t.height=window.screen.height,t.density=window.devicePixelRatio,t.innerWidth=window.innerWidth,t.innerHeight=window.innerHeight),t)})),Co=function(){function e(){r(this,e),this.channel="web",this.context=new ko,this.type=null,this.messageId=uo(),this.originalTimestamp=(new Date).toISOString(),this.anonymousId=null,this.userId=null,this.event=null,this.properties={},this.integrations={},this.integrations.All=!0}return o(e,[{key:"getProperty",value:function(e){return this.properties[e]}},{key:"addProperty",value:function(e,t){this.properties[e]=t}}]),e}(),wo=function(){function e(){r(this,e),this.message=new Co}return o(e,[{key:"setType",value:function(e){this.message.type=e}},{key:"setProperty",value:function(e){this.message.properties=e}},{key:"setUserProperty",value:function(e){this.message.user_properties=e}},{key:"setUserId",value:function(e){this.message.userId=e}},{key:"setEventName",value:function(e){this.message.event=e}},{key:"getElementContent",value:function(){return this.message}}]),e}(),_o=function(){function e(){r(this,e),this.rudderProperty=null,this.rudderUserProperty=null,this.event=null,this.userId=null,this.type=null}return o(e,[{key:"setType",value:function(e){return this.type=e,this}},{key:"build",value:function(){var e=new wo;return e.setUserId(this.userId),e.setType(this.type),e.setEventName(this.event),e.setProperty(this.rudderProperty),e.setUserProperty(this.rudderUserProperty),e}}]),e}(),To={},Ro=256,Po=[];Ro--;)Po[Ro]=(Ro+256).toString(16).substring(1);To.v4=function(){var e,t=0,n="";if(!mo||Ro+16>256){for(mo=Array(t=256);t--;)mo[t]=256*Math.random()|0;t=Ro=0}for(;t<16;t++)e=mo[Ro+t],n+=6==t?Po[15&e|64]:8==t?Po[63&e|128]:Po[e],1&t&&t>1&&t<11&&(n+="-");return Ro++,n};var Lo,xo={},Mo=Object.prototype.hasOwnProperty,Do=String.prototype.charAt,No=Object.prototype.toString,Bo=function(e,t){return Do.call(e,t)},Go=function(e,t){return Mo.call(e,t)},Fo=function(e,t){t=t||Go;for(var n=[],r=0,i=e.length;r<i;r+=1)t(e,r)&&n.push(String(r));return n},Uo=function(e){return null==e?[]:(t=e,"[object String]"===No.call(t)?Fo(e,Bo):function(e){return null!=e&&"function"!=typeof e&&"number"==typeof e.length}(e)?Fo(e,Go):function(e,t){t=t||Go;var n=[];for(var r in e)t(e,r)&&n.push(String(r));return n}(e));var t},jo=new Uint8Array(16);function Ho(){if(!Lo&&!(Lo="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Lo(jo)}var Ko=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;function zo(e){return"string"==typeof e&&Ko.test(e)}for(var Qo,Vo,qo=[],Wo=0;Wo<256;++Wo)qo.push((Wo+256).toString(16).substr(1));function Yo(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=(qo[e[t+0]]+qo[e[t+1]]+qo[e[t+2]]+qo[e[t+3]]+"-"+qo[e[t+4]]+qo[e[t+5]]+"-"+qo[e[t+6]]+qo[e[t+7]]+"-"+qo[e[t+8]]+qo[e[t+9]]+"-"+qo[e[t+10]]+qo[e[t+11]]+qo[e[t+12]]+qo[e[t+13]]+qo[e[t+14]]+qo[e[t+15]]).toLowerCase();if(!zo(n))throw TypeError("Stringified UUID is invalid");return n}var Jo=0,Xo=0;function $o(e){if(!zo(e))throw TypeError("Invalid UUID");var t,n=new Uint8Array(16);return n[0]=(t=parseInt(e.slice(0,8),16))>>>24,n[1]=t>>>16&255,n[2]=t>>>8&255,n[3]=255&t,n[4]=(t=parseInt(e.slice(9,13),16))>>>8,n[5]=255&t,n[6]=(t=parseInt(e.slice(14,18),16))>>>8,n[7]=255&t,n[8]=(t=parseInt(e.slice(19,23),16))>>>8,n[9]=255&t,n[10]=(t=parseInt(e.slice(24,36),16))/1099511627776&255,n[11]=t/4294967296&255,n[12]=t>>>24&255,n[13]=t>>>16&255,n[14]=t>>>8&255,n[15]=255&t,n}function Zo(e,t,n){function r(e,r,i,o){if("string"==typeof e&&(e=function(e){e=unescape(encodeURIComponent(e));for(var t=[],n=0;n<e.length;++n)t.push(e.charCodeAt(n));return t}(e)),"string"==typeof r&&(r=$o(r)),16!==r.length)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");var s=new Uint8Array(16+e.length);if(s.set(r),s.set(e,r.length),(s=n(s))[6]=15&s[6]|t,s[8]=63&s[8]|128,i){o=o||0;for(var a=0;a<16;++a)i[o+a]=s[a];return i}return Yo(s)}try{r.name=e}catch(e){}return r.DNS="6ba7b810-9dad-11d1-80b4-00c04fd430c8",r.URL="6ba7b811-9dad-11d1-80b4-00c04fd430c8",r}function es(e){return 14+(e+64>>>9<<4)+1}function ts(e,t){var n=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(n>>16)<<16|65535&n}function ns(e,t,n,r,i,o){return ts((s=ts(ts(t,e),ts(r,o)))<<(a=i)|s>>>32-a,n);var s,a}function rs(e,t,n,r,i,o,s){return ns(t&n|~t&r,e,t,i,o,s)}function is(e,t,n,r,i,o,s){return ns(t&r|n&~r,e,t,i,o,s)}function os(e,t,n,r,i,o,s){return ns(t^n^r,e,t,i,o,s)}function ss(e,t,n,r,i,o,s){return ns(n^(t|~r),e,t,i,o,s)}var as=Zo("v3",48,(function(e){if("string"==typeof e){var t=unescape(encodeURIComponent(e));e=new Uint8Array(t.length);for(var n=0;n<t.length;++n)e[n]=t.charCodeAt(n)}return function(e){for(var t=[],n=32*e.length,r="0123456789abcdef",i=0;i<n;i+=8){var o=e[i>>5]>>>i%32&255,s=parseInt(r.charAt(o>>>4&15)+r.charAt(15&o),16);t.push(s)}return t}(function(e,t){e[t>>5]|=128<<t%32,e[es(t)-1]=t;for(var n=1732584193,r=-271733879,i=-1732584194,o=271733878,s=0;s<e.length;s+=16){var a=n,u=r,c=i,l=o;n=rs(n,r,i,o,e[s],7,-680876936),o=rs(o,n,r,i,e[s+1],12,-389564586),i=rs(i,o,n,r,e[s+2],17,606105819),r=rs(r,i,o,n,e[s+3],22,-1044525330),n=rs(n,r,i,o,e[s+4],7,-176418897),o=rs(o,n,r,i,e[s+5],12,1200080426),i=rs(i,o,n,r,e[s+6],17,-1473231341),r=rs(r,i,o,n,e[s+7],22,-45705983),n=rs(n,r,i,o,e[s+8],7,1770035416),o=rs(o,n,r,i,e[s+9],12,-1958414417),i=rs(i,o,n,r,e[s+10],17,-42063),r=rs(r,i,o,n,e[s+11],22,-1990404162),n=rs(n,r,i,o,e[s+12],7,1804603682),o=rs(o,n,r,i,e[s+13],12,-40341101),i=rs(i,o,n,r,e[s+14],17,-1502002290),n=is(n,r=rs(r,i,o,n,e[s+15],22,1236535329),i,o,e[s+1],5,-165796510),o=is(o,n,r,i,e[s+6],9,-1069501632),i=is(i,o,n,r,e[s+11],14,643717713),r=is(r,i,o,n,e[s],20,-373897302),n=is(n,r,i,o,e[s+5],5,-701558691),o=is(o,n,r,i,e[s+10],9,38016083),i=is(i,o,n,r,e[s+15],14,-660478335),r=is(r,i,o,n,e[s+4],20,-405537848),n=is(n,r,i,o,e[s+9],5,568446438),o=is(o,n,r,i,e[s+14],9,-1019803690),i=is(i,o,n,r,e[s+3],14,-187363961),r=is(r,i,o,n,e[s+8],20,1163531501),n=is(n,r,i,o,e[s+13],5,-1444681467),o=is(o,n,r,i,e[s+2],9,-51403784),i=is(i,o,n,r,e[s+7],14,1735328473),n=os(n,r=is(r,i,o,n,e[s+12],20,-1926607734),i,o,e[s+5],4,-378558),o=os(o,n,r,i,e[s+8],11,-2022574463),i=os(i,o,n,r,e[s+11],16,1839030562),r=os(r,i,o,n,e[s+14],23,-35309556),n=os(n,r,i,o,e[s+1],4,-1530992060),o=os(o,n,r,i,e[s+4],11,1272893353),i=os(i,o,n,r,e[s+7],16,-155497632),r=os(r,i,o,n,e[s+10],23,-1094730640),n=os(n,r,i,o,e[s+13],4,681279174),o=os(o,n,r,i,e[s],11,-358537222),i=os(i,o,n,r,e[s+3],16,-722521979),r=os(r,i,o,n,e[s+6],23,76029189),n=os(n,r,i,o,e[s+9],4,-640364487),o=os(o,n,r,i,e[s+12],11,-421815835),i=os(i,o,n,r,e[s+15],16,530742520),n=ss(n,r=os(r,i,o,n,e[s+2],23,-995338651),i,o,e[s],6,-198630844),o=ss(o,n,r,i,e[s+7],10,1126891415),i=ss(i,o,n,r,e[s+14],15,-1416354905),r=ss(r,i,o,n,e[s+5],21,-57434055),n=ss(n,r,i,o,e[s+12],6,1700485571),o=ss(o,n,r,i,e[s+3],10,-1894986606),i=ss(i,o,n,r,e[s+10],15,-1051523),r=ss(r,i,o,n,e[s+1],21,-2054922799),n=ss(n,r,i,o,e[s+8],6,1873313359),o=ss(o,n,r,i,e[s+15],10,-30611744),i=ss(i,o,n,r,e[s+6],15,-1560198380),r=ss(r,i,o,n,e[s+13],21,1309151649),n=ss(n,r,i,o,e[s+4],6,-145523070),o=ss(o,n,r,i,e[s+11],10,-1120210379),i=ss(i,o,n,r,e[s+2],15,718787259),r=ss(r,i,o,n,e[s+9],21,-343485551),n=ts(n,a),r=ts(r,u),i=ts(i,c),o=ts(o,l)}return[n,r,i,o]}(function(e){if(0===e.length)return[];for(var t=8*e.length,n=new Uint32Array(es(t)),r=0;r<t;r+=8)n[r>>5]|=(255&e[r/8])<<r%32;return n}(e),8*e.length))})),us=as;function cs(e,t,n,r){switch(e){case 0:return t&n^~t&r;case 1:case 3:return t^n^r;case 2:return t&n^t&r^n&r}}function ls(e,t){return e<<t|e>>>32-t}var fs=Zo("v5",80,(function(e){var t=[1518500249,1859775393,2400959708,3395469782],n=[1732584193,4023233417,2562383102,271733878,3285377520];if("string"==typeof e){var r=unescape(encodeURIComponent(e));e=[];for(var i=0;i<r.length;++i)e.push(r.charCodeAt(i))}else Array.isArray(e)||(e=Array.prototype.slice.call(e));e.push(128);for(var o=e.length/4+2,s=Math.ceil(o/16),a=new Array(s),u=0;u<s;++u){for(var c=new Uint32Array(16),l=0;l<16;++l)c[l]=e[64*u+4*l]<<24|e[64*u+4*l+1]<<16|e[64*u+4*l+2]<<8|e[64*u+4*l+3];a[u]=c}a[s-1][14]=8*(e.length-1)/Math.pow(2,32),a[s-1][14]=Math.floor(a[s-1][14]),a[s-1][15]=8*(e.length-1)&4294967295;for(var f=0;f<s;++f){for(var h=new Uint32Array(80),d=0;d<16;++d)h[d]=a[f][d];for(var p=16;p<80;++p)h[p]=ls(h[p-3]^h[p-8]^h[p-14]^h[p-16],1);for(var g=n[0],y=n[1],v=n[2],m=n[3],A=n[4],I=0;I<80;++I){var E=Math.floor(I/20),b=ls(g,5)+cs(E,y,v,m)+A+t[E]+h[I]>>>0;A=m,m=v,v=ls(y,30)>>>0,y=g,g=b}n[0]=n[0]+g>>>0,n[1]=n[1]+y>>>0,n[2]=n[2]+v>>>0,n[3]=n[3]+m>>>0,n[4]=n[4]+A>>>0}return[n[0]>>24&255,n[0]>>16&255,n[0]>>8&255,255&n[0],n[1]>>24&255,n[1]>>16&255,n[1]>>8&255,255&n[1],n[2]>>24&255,n[2]>>16&255,n[2]>>8&255,255&n[2],n[3]>>24&255,n[3]>>16&255,n[3]>>8&255,255&n[3],n[4]>>24&255,n[4]>>16&255,n[4]>>8&255,255&n[4]]})),hs=fs;var ds=Object.freeze({__proto__:null,v1:function(e,t,n){var r=t&&n||0,i=t||new Array(16),o=(e=e||{}).node||Qo,s=void 0!==e.clockseq?e.clockseq:Vo;if(null==o||null==s){var a=e.random||(e.rng||Ho)();null==o&&(o=Qo=[1|a[0],a[1],a[2],a[3],a[4],a[5]]),null==s&&(s=Vo=16383&(a[6]<<8|a[7]))}var u=void 0!==e.msecs?e.msecs:Date.now(),c=void 0!==e.nsecs?e.nsecs:Xo+1,l=u-Jo+(c-Xo)/1e4;if(l<0&&void 0===e.clockseq&&(s=s+1&16383),(l<0||u>Jo)&&void 0===e.nsecs&&(c=0),c>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");Jo=u,Xo=c,Vo=s;var f=(1e4*(268435455&(u+=122192928e5))+c)%4294967296;i[r++]=f>>>24&255,i[r++]=f>>>16&255,i[r++]=f>>>8&255,i[r++]=255&f;var h=u/4294967296*1e4&268435455;i[r++]=h>>>8&255,i[r++]=255&h,i[r++]=h>>>24&15|16,i[r++]=h>>>16&255,i[r++]=s>>>8|128,i[r++]=255&s;for(var d=0;d<6;++d)i[r+d]=o[d];return t||Yo(i)},v3:us,v4:function(e,t,n){var r=(e=e||{}).random||(e.rng||Ho)();if(r[6]=15&r[6]|64,r[8]=63&r[8]|128,t){n=n||0;for(var i=0;i<16;++i)t[n+i]=r[i];return t}return Yo(r)},v5:hs,NIL:"00000000-0000-0000-0000-000000000000",version:function(e){if(!zo(e))throw TypeError("Invalid UUID");return parseInt(e.substr(14,1),16)},validate:zo,stringify:Yo,parse:$o}),ps=Uo,gs=h(ds).v4,ys={_data:{},length:0,setItem:function(e,t){return this._data[e]=t,this.length=ps(this._data).length,t},getItem:function(e){return e in this._data?this._data[e]:null},removeItem:function(e){return e in this._data&&delete this._data[e],this.length=ps(this._data).length,null},clear:function(){this._data={},this.length=0},key:function(e){return ps(this._data)[e]}};xo.defaultEngine=function(){try{if(!window.localStorage)return!1;var e=gs();window.localStorage.setItem(e,"test_value");var t=window.localStorage.getItem(e);return window.localStorage.removeItem(e),"test_value"===t}catch(e){return!1}}()?window.localStorage:ys,xo.inMemoryEngine=ys;var vs=Uo,ms=Object.prototype.toString,As="function"==typeof Array.isArray?Array.isArray:function(e){return"[object Array]"===ms.call(e)},Is=function(e){return null!=e&&(As(e)||"function"!==e&&function(e){var t=typeof e;return"number"===t||"object"===t&&"[object Number]"===ms.call(e)}(e.length))},Es=function(e,t){for(var n=0;n<t.length&&!1!==e(t[n],n,t);n+=1);},bs=function(e,t){for(var n=vs(t),r=0;r<n.length&&!1!==e(t[n[r]],n[r],t);r+=1);},Os=function(e,t){return(Is(t)?Es:bs).call(this,e,t)},Ss=xo.defaultEngine,ks=xo.inMemoryEngine,Cs=Os,ws=Uo,_s=JSON;function Ts(e,t,n,r){this.id=t,this.name=e,this.keys=n||{},this.engine=r||Ss,this.originalEngine=this.engine}Ts.prototype.set=function(e,t){var n=this._createValidKey(e);if(n)try{this.engine.setItem(n,_s.stringify(t))}catch(n){(function(e){var t=!1;if(e.code)switch(e.code){case 22:t=!0;break;case 1014:"NS_ERROR_DOM_QUOTA_REACHED"===e.name&&(t=!0)}else-2147024882===e.number&&(t=!0);return t})(n)&&(this._swapEngine(),this.set(e,t))}},Ts.prototype.get=function(e){try{var t=this.engine.getItem(this._createValidKey(e));return null===t?null:_s.parse(t)}catch(e){return null}},Ts.prototype.getOriginalEngine=function(){return this.originalEngine},Ts.prototype.remove=function(e){this.engine.removeItem(this._createValidKey(e))},Ts.prototype._createValidKey=function(e){var t,n=this.name,r=this.id;return ws(this.keys).length?(Cs((function(i){i===e&&(t=[n,r,e].join("."))}),this.keys),t):[n,r,e].join(".")},Ts.prototype._swapEngine=function(){var e=this;Cs((function(t){var n=e.get(t);ks.setItem([e.name,e.id,t].join("."),n),e.remove(t)}),this.keys),this.engine=ks};var Rs=Ts;var Ps=Os,Ls={setTimeout:function(e,t){return window.setTimeout(e,t)},clearTimeout:function(e){return window.clearTimeout(e)},Date:window.Date},xs=Ls,Ms={ASAP:1,RESCHEDULE:2,ABANDON:3};function Ds(){this.tasks={},this.nextId=1}Ds.prototype.now=function(){return+new xs.Date},Ds.prototype.run=function(e,t,n){var r=this.nextId++;return this.tasks[r]=xs.setTimeout(this._handle(r,e,t,n||Ms.ASAP),t),r},Ds.prototype.cancel=function(e){this.tasks[e]&&(xs.clearTimeout(this.tasks[e]),delete this.tasks[e])},Ds.prototype.cancelAll=function(){Ps(xs.clearTimeout,this.tasks),this.tasks={}},Ds.prototype._handle=function(e,t,n,r){var i=this,o=i.now();return function(){if(delete i.tasks[e],!(r>=Ms.RESCHEDULE&&o+2*n<i.now()))return t();r===Ms.RESCHEDULE&&i.run(t,n,r)}},Ds.setClock=function(e){xs=e},Ds.resetClock=function(){xs=Ls},Ds.Modes=Ms;var Ns=Ds,Bs=To.v4,Gs=Rs,Fs=Os,Us=Ns,js=ei("localstorage-retry");function Hs(e,t){return function(){return e.apply(t,arguments)}}function Ks(e,t,n){"function"==typeof t&&(n=t),this.name=e,this.id=Bs(),this.fn=n,this.maxItems=t.maxItems||1/0,this.maxAttempts=t.maxAttempts||1/0,this.backoff={MIN_RETRY_DELAY:t.minRetryDelay||1e3,MAX_RETRY_DELAY:t.maxRetryDelay||3e4,FACTOR:t.backoffFactor||2,JITTER:t.backoffJitter||0},this.timeouts={ACK_TIMER:1e3,RECLAIM_TIMER:3e3,RECLAIM_TIMEOUT:1e4,RECLAIM_WAIT:500},this.keys={IN_PROGRESS:"inProgress",QUEUE:"queue",RECLAIM_START:"reclaimStart",RECLAIM_END:"reclaimEnd",ACK:"ack"},this._schedule=new Us,this._processId=0,this._store=new Gs(this.name,this.id,this.keys),this._store.set(this.keys.IN_PROGRESS,{}),this._store.set(this.keys.QUEUE,[]),this._ack=Hs(this._ack,this),this._checkReclaim=Hs(this._checkReclaim,this),this._processHead=Hs(this._processHead,this),this._running=!1}d(Ks.prototype),Ks.prototype.start=function(){this._running&&this.stop(),this._running=!0,this._ack(),this._checkReclaim(),this._processHead()},Ks.prototype.stop=function(){this._schedule.cancelAll(),this._running=!1},Ks.prototype.shouldRetry=function(e,t){return!(t>this.maxAttempts)},Ks.prototype.getDelay=function(e){var t=this.backoff.MIN_RETRY_DELAY*Math.pow(this.backoff.FACTOR,e);if(this.backoff.JITTER){var n=Math.random(),r=Math.floor(n*this.backoff.JITTER*t);Math.floor(10*n)<5?t-=r:t+=r}return Number(Math.min(t,this.backoff.MAX_RETRY_DELAY).toPrecision(1))},Ks.prototype.addItem=function(e){this._enqueue({item:e,attemptNumber:0,time:this._schedule.now(),id:Bs()})},Ks.prototype.requeue=function(e,t,n,r){this.shouldRetry(e,t,n)?this._enqueue({item:e,attemptNumber:t,time:this._schedule.now()+this.getDelay(t),id:r||Bs()}):this.emit("discard",e,t)},Ks.prototype._enqueue=function(e){var t=this._store.get(this.keys.QUEUE)||[];(t=t.slice(-(this.maxItems-1))).push(e),t=t.sort((function(e,t){return e.time-t.time})),this._store.set(this.keys.QUEUE,t),this._running&&this._processHead()},Ks.prototype._processHead=function(){var e=this,t=this._store;this._schedule.cancel(this._processId);var n=t.get(this.keys.QUEUE)||[],r=t.get(this.keys.IN_PROGRESS)||{},i=this._schedule.now(),o=[];function s(n,r){o.push({item:n.item,done:function(i,o){var s=t.get(e.keys.IN_PROGRESS)||{};delete s[r],t.set(e.keys.IN_PROGRESS,s),e.emit("processed",i,o,n.item),i&&e.requeue(n.item,n.attemptNumber+1,i,n.id)}})}for(var a=Object.keys(r).length;n.length&&n[0].time<=i&&a++<e.maxItems;){var u=n.shift(),c=Bs();r[c]={item:u.item,attemptNumber:u.attemptNumber,time:e._schedule.now()},s(u,c)}t.set(this.keys.QUEUE,n),t.set(this.keys.IN_PROGRESS,r),Fs((function(t){try{e.fn(t.item,t.done)}catch(e){js("Process function threw error: "+e)}}),o),n=t.get(this.keys.QUEUE)||[],this._schedule.cancel(this._processId),n.length>0&&(this._processId=this._schedule.run(this._processHead,n[0].time-i,Us.Modes.ASAP))},Ks.prototype._ack=function(){this._store.set(this.keys.ACK,this._schedule.now()),this._store.set(this.keys.RECLAIM_START,null),this._store.set(this.keys.RECLAIM_END,null),this._schedule.run(this._ack,this.timeouts.ACK_TIMER,Us.Modes.ASAP)},Ks.prototype._checkReclaim=function(){var e=this;Fs((function(t){t.id!==e.id&&(e._schedule.now()-t.get(e.keys.ACK)<e.timeouts.RECLAIM_TIMEOUT||function(t){t.set(e.keys.RECLAIM_START,e.id),t.set(e.keys.ACK,e._schedule.now()),e._schedule.run((function(){t.get(e.keys.RECLAIM_START)===e.id&&(t.set(e.keys.RECLAIM_END,e.id),e._schedule.run((function(){t.get(e.keys.RECLAIM_END)===e.id&&t.get(e.keys.RECLAIM_START)===e.id&&e._reclaim(t.id)}),e.timeouts.RECLAIM_WAIT,Us.Modes.ABANDON))}),e.timeouts.RECLAIM_WAIT,Us.Modes.ABANDON)}(t))}),function(t){for(var n=[],r=e._store.getOriginalEngine(),i=0;i<r.length;i++){var o=r.key(i).split(".");3===o.length&&(o[0]===t&&"ack"===o[2]&&n.push(new Gs(t,o[1],e.keys)))}return n}(this.name)),this._schedule.run(this._checkReclaim,this.timeouts.RECLAIM_TIMER,Us.Modes.RESCHEDULE)},Ks.prototype._reclaim=function(e){var t=this,n=new Gs(this.name,e,this.keys),r={queue:this._store.get(this.keys.QUEUE)||[]},i={inProgress:n.get(this.keys.IN_PROGRESS)||{},queue:n.get(this.keys.QUEUE)||[]},o=[],s=function(e,n){Fs((function(e){var i=e.id||Bs();o.indexOf(i)>=0?t.emit("duplication",e.item,e.attemptNumber):(r.queue.push({item:e.item,attemptNumber:e.attemptNumber+n,time:t._schedule.now(),id:i}),o.push(i))}),e)};s(i.queue,0),s(i.inProgress,1),r.queue=r.queue.sort((function(e,t){return e.time-t.time})),this._store.set(this.keys.QUEUE,r.queue),n.remove(this.keys.IN_PROGRESS),n.remove(this.keys.QUEUE),n.remove(this.keys.RECLAIM_START),n.remove(this.keys.RECLAIM_END),n.remove(this.keys.ACK),this._processHead()};var zs=Ks,Qs={maxRetryDelay:36e4,minRetryDelay:1e3,backoffFactor:2,maxAttempts:10,maxItems:100},Vs=function(){function e(){r(this,e),this.url="",this.writeKey=""}return o(e,[{key:"init",value:function(e,t,n){this.url=t,this.writeKey=e,n&&a(Qs,n),this.payloadQueue=new zs("rudder",Qs,function(e,t){e.message.sentAt=co(),this.processQueueElement(e.url,e.headers,e.message,1e4,(function(e,n){if(e)return t(e);t(null,n)}))}.bind(this)),this.payloadQueue.start()}},{key:"processQueueElement",value:function(e,t,n,r,i){try{var o=new XMLHttpRequest;for(var s in o.open("POST",e,!0),t)o.setRequestHeader(s,t[s]);o.timeout=r,o.ontimeout=i,o.onerror=i,o.onreadystatechange=function(){4===o.readyState&&(429===o.status||o.status>=500&&o.status<600?(oo(new Error("request failed with status: ".concat(o.status).concat(o.statusText," for url: ").concat(e))),i(new Error("request failed with status: ".concat(o.status).concat(o.statusText," for url: ").concat(e)))):i(null,o.status))},o.send(JSON.stringify(n,so))}catch(e){i(e)}}},{key:"enqueue",value:function(e,t){var n={"Content-Type":"application/json",Authorization:"Basic ".concat(btoa("".concat(this.writeKey,":"))),AnonymousId:btoa(e.anonymousId)};this.payloadQueue.addItem({url:"".concat(this.url,"/v1/").concat(t),headers:n,message:e})}}]),e}(),qs="queue",Ws=64e3,Ys=function(){function e(){r(this,e),this.storage=Fi,this.maxItems=10,this.flushQueueTimeOut=void 0,this.timeOutActive=!1,this.flushQueueTimeOutInterval=6e5,this.url="",this.writekey="",this.queueName="".concat(qs,".").concat(Date.now()),this.send=navigator.sendBeacon&&navigator.sendBeacon.bind(navigator)}return o(e,[{key:"sendQueueDataForBeacon",value:function(){this.sendDataFromQueueAndDestroyQueue()}},{key:"init",value:function(e,t,n){this.url=t,this.writekey=e,n.maxItems&&(this.maxItems=n.maxItems),n.flushQueueInterval&&(this.flushQueueTimeOutInterval=n.flushQueueInterval);var r=this.sendQueueDataForBeacon.bind(this);window.addEventListener("unload",r)}},{key:"getQueue",value:function(){return this.storage.get(this.queueName)}},{key:"setQueue",value:function(e){this.storage.set(this.queueName,e)}},{key:"enqueue",value:function(e){var t=this.getQueue()||[];(t=t.slice(-(this.maxItems-1))).push(e);var n=t.slice(0),r={batch:n};JSON.stringify(r,so).length>Ws&&(n=t.slice(0,t.length-1),this.flushQueue(n),(t=this.getQueue()).push(e)),this.setQueue(t),this.setTimer(),t.length===this.maxItems&&this.flushQueue(n)}},{key:"sendDataFromQueueAndDestroyQueue",value:function(){this.sendDataFromQueue(),this.storage.remove(this.queueName)}},{key:"sendDataFromQueue",value:function(){var e=this.getQueue();if(e&&e.length>0){var t=e.slice(0,e.length);this.flushQueue(t)}}},{key:"flushQueue",value:function(e){e.forEach((function(e){e.sentAt=(new Date).toISOString()}));var t={batch:e},n=JSON.stringify(t,so),r=new Blob([n],{type:"text/plain"});try{this.send("".concat(this.url,"?writeKey=").concat(this.writekey),r)||oo(new Error("Unable to queue data to browser's beacon queue"))}catch(e){oo(e)}this.setQueue([]),this.clearTimer()}},{key:"setTimer",value:function(){this.timeOutActive||(this.flushQueueTimeOut=setTimeout(this.sendDataFromQueue.bind(this),this.flushQueueTimeOutInterval),this.timeOutActive=!0)}},{key:"clearTimer",value:function(){this.timeOutActive&&(clearTimeout(this.flushQueueTimeOut),this.timeOutActive=!1)}}]),e}(),Js=function(){function e(){r(this,e),this.queue=void 0}return o(e,[{key:"initialize",value:function(e,t,r){var i={},o=ao(t);r&&r.useBeacon&&navigator.sendBeacon?(r&&r.beaconQueueOptions&&null!=r.beaconQueueOptions&&"object"===n(r.beaconQueueOptions)&&(i=r.beaconQueueOptions),o="".concat(o,"/beacon/v1/batch"),this.queue=new Ys):(r&&r.useBeacon&&lt("[EventRepository] sendBeacon feature not available in this browser :: fallback to XHR"),r&&r.queueOptions&&null!=r.queueOptions&&"object"===n(r.queueOptions)&&(i=r.queueOptions),this.queue=new Vs),this.queue.init(e,o,i)}},{key:"enqueue",value:function(e,t){var n=e.getElementContent();n.originalTimestamp=n.originalTimestamp||co(),n.sentAt=co(),JSON.stringify(n,so).length>32e3&&dt("[EventRepository] enqueue:: message length greater 32 Kb ",n),this.queue.enqueue(n,t)}}]),e}(),Xs=new Js,$s=function(){return navigator&&navigator.language},Zs=function(){return navigator&&navigator.userAgent};function ea(e){return decodeURIComponent(atob(e).split("").map((function(e){return"%".concat("00".concat(e.charCodeAt(0).toString(16)).slice(-2))})).join(""))}function ta(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return ea(e=e.endsWith("..")?e.substr(0,e.length-2):e)}var na=/^[a-zA-Z0-9\-_.]+$/;function ra(e,t,n,r){var i=function(e,t){return[e,(new Date).getTimezoneOffset(),t].join("*")}(n,r),o=t||0,s=function(e){for(var t=function(){for(var e,t=[],n=0;n<256;n++){e=n;for(var r=0;r<8;r++)e=1&e?3988292384^e>>>1:e>>>1;t[n]=e}return t}(),n=-1,r=0;r<e.length;r++)n=n>>>8^t[255&(n^e.charCodeAt(r))];return(-1^n)>>>0}([i,Math.floor(Date.now()/6e4)-o,e].join("*"));return s.toString(36)}function ia(e){var t=function(e){var t=e.split("*"),n=t.length%2==0;return t.length<4||!n||1!==Number(t.shift())?null:{checksum:t.shift(),serializedIds:t.join("*")}}(e);if(!t)return null;var n=t.checksum,r=t.serializedIds;return function(e,t){for(var n=Zs(),r=$s(),i=0;i<=1;i+=1)if(ra(e,i,n,r)===t)return!0;return!1}(r,n)?function(e){for(var t={},n=e.split("*"),r=0;r<n.length;r+=2){var i=n[r];if(na.test(i)){var o=ta(n[r+1]);t[i]=o}}return t}(r):null}var oa={HS:"HubSpot",GA:"GA",HOTJAR:"Hotjar",GOOGLEADS:"GoogleAds",VWO:"VWO",GTM:"GoogleTagManager",BRAZE:"Braze",INTERCOM:"INTERCOM",KEEN:"Keen",KISSMETRICS:"Kissmetrics",CUSTOMERIO:"CustomerIO",CHARTBEAT:"Chartbeat",COMSCORE:"Comscore",FACEBOOK_PIXEL:"FacebookPixel",LOTAME:"Lotame",OPTIMIZELY:"Optimizely",BUGSNAG:"Bugsnag",FULLSTORY:"Fullstory",TVSQUARED:"TVSquared",GA4:"GA4",MOENGAGE:"MoEngage",AM:"Amplitude",PENDO:"Pendo",LYTICS:"Lytics",APPCUES:"Appcues",POSTHOG:"Posthog",KLAVIYO:"Klaviyo",CLEVERTAP:"Clevertap",BINGADS:"BingAds",PINTEREST_TAG:"PinterestTag",ADOBE_ANALYTICS:"AdobeAnalytics",LINKEDIN_INSIGHT_TAG:"LinkedInInsightTag",REDDIT_PIXEL:"RedditPixel",DRIP:"Drip",HEAP:"Heap",CRITEO:"Criteo",MP:"Mixpanel",QUALTRICS:"Qualtrics",PROFITWELL:"ProfitWell",SENTRY:"Sentry",QUANTUMMETRIC:"QuantumMetric",SNAP_PIXEL:"SnapPixel",POST_AFFILIATE_PRO:"PostAffiliatePro",GOOGLE_OPTIMIZE:"GoogleOptimize",LAUNCHDARKLY:"LaunchDarkly",GA360:"GA360",ADROLL:"Adroll",DCM_FLOODLIGHT:"DCMFloodlight",MATOMO:"Matomo",VERO:"Vero",MOUSEFLOW:"Mouseflow",ROCKERBOX:"Rockerbox",CONVERTFLOW:"ConvertFlow",SNAPENGAGE:"SnapEngage",LIVECHAT:"LiveChat",SHYNET:"Shynet",WOOPRA:"Woopra",ROLLBAR:"RollBar",QUORA_PIXEL:"QuoraPixel",JUNE:"June",ENGAGE:"Engage",ITERABLE:"Iterable",YANDEX_METRICA:"YandexMetrica",REFINER:"Refiner",QUALAROO:"Qualaroo",PODSIGHTS:"Podsights",AXEPTIO:"Axeptio",SATISMETER:"Satismeter",MICROSOFT_CLARITY:"MicrosoftClarity",SENDINBLUE:"Sendinblue",OLARK:"Olark"},sa=function(){function e(){var t=this;if(r(this,e),!window.OneTrust||!window.OnetrustActiveGroups)throw new Error("OneTrust resources are not accessible. Thus all the destinations will be loaded");this.userSetConsentGroupIds=window.OnetrustActiveGroups.split(",").filter((function(e){return e}));var n=window.OneTrust.GetDomainData().Groups;this.userSetConsentGroupNames=[],n.forEach((function(e){var n=e.CustomGroupId,r=e.GroupName;t.userSetConsentGroupIds.includes(n)&&t.userSetConsentGroupNames.push(r.toUpperCase().trim())})),this.userSetConsentGroupIds=this.userSetConsentGroupIds.map((function(e){return e.toUpperCase()}))}return o(e,[{key:"isEnabled",value:function(e){var t=this;try{var n=e.oneTrustCookieCategories;if(!n)return!0;var r=n.map((function(e){return e.oneTrustCookieCategory})).filter((function(e){return e}));return r.every((function(e){return t.userSetConsentGroupIds.includes(e.toUpperCase().trim())||t.userSetConsentGroupNames.includes(e.toUpperCase().trim())}))}catch(e){return dt("Error during onetrust cookie consent management ".concat(e)),!0}}}]),e}(),aa=function(){function e(){r(this,e)}return o(e,null,[{key:"initialize",value:function(e){var t;return null!=e&&null!==(t=e.oneTrust)&&void 0!==t&&t.enabled?new sa:null}}]),e}(),ua={SDK:{name:"JS",installType:"npm"}},ca="{{RS_BUGSNAG_API_KEY}}",la=["rudder-analytics.min.js"].concat(u(Object.keys(oa).map((function(e){return"".concat(oa[e],".min.js")}))));function fa(e){if(void 0!==window.Bugsnag){if(null===ca.match(/{{.+}}/)){var t=window.location.hostname;window.rsBugsnagClient=window.Bugsnag.start({apiKey:ca,appVersion:"2.22.3",metadata:ua,onError:function(t){try{var n=B(t,"errors.0.stacktrace.0.file");if(!n||"string"!=typeof n)return!1;var r=n.substring(n.lastIndexOf("/")+1);if(!la.includes(r))return!1;t.addMetadata("source",{sourceId:e});var i=t.errors[0].errorMessage;return t.context=i,i.includes("error in script loading")&&(t.context="Script load failures"),t.severity="error",!0}catch(e){return!1}},autoTrackSessions:!1,collectUserIp:!1,enabledBreadcrumbTypes:["error","log","user"],maxEvents:100,releaseStage:t&&["localhost","127.0.0.1","[::1]"].includes(t)?"development":"production"})}}}var ha=new(function(){function e(){r(this,e),this.storage=to,this.timeout=18e5,this.sessionInfo=this.storage.getSessionInfo()||{autoTrack:!0}}return o(e,[{key:"initialize",value:function(e){try{var t;if(this.sessionInfo.autoTrack=!(!1===(null==e||null===(t=e.sessions)||void 0===t?void 0:t.autoTrack)||this.sessionInfo.manualTrack),null!=e&&e.sessions&&!isNaN(e.sessions.timeout)){var n=e.sessions.timeout;0===n&&(ht("[Session]:: Provided timeout value 0 will disable the auto session tracking feature."),this.sessionInfo.autoTrack=!1),n>0&&n<1e4&&ht('[Session]:: It is not advised to set "timeout" less than 10 seconds'),this.timeout=n}this.sessionInfo.autoTrack?this.startAutoTracking():!1!==this.sessionInfo.autoTrack||this.sessionInfo.manualTrack||this.end()}catch(e){oo(e)}}},{key:"isValidSession",value:function(e){return e<=this.sessionInfo.expiresAt}},{key:"generateSessionId",value:function(){return Date.now()}},{key:"startAutoTracking",value:function(){var e=Date.now();this.isValidSession(e)||(this.sessionInfo={},this.sessionInfo.id=e,this.sessionInfo.expiresAt=e+this.timeout,this.sessionInfo.sessionStart=!0,this.sessionInfo.autoTrack=!0),this.storage.setSessionInfo(this.sessionInfo)}},{key:"validateSessionId",value:function(e){if("number"==typeof e&&e%1==0){var t;if(!(((t=e)?t.toString().length:0)<10))return e;dt('[Session]:: "sessionId" should at least be "'.concat(10,'" digits long'))}else dt('[Session]:: "sessionId" should only be a positive integer')}},{key:"start",value:function(e){var t=e?this.validateSessionId(e):this.generateSessionId();this.sessionInfo={id:t||this.generateSessionId(),sessionStart:!0,manualTrack:!0},this.storage.setSessionInfo(this.sessionInfo)}},{key:"getSessionId",value:function(){return this.sessionInfo.autoTrack&&this.isValidSession(Date.now())||this.sessionInfo.manualTrack?this.sessionInfo.id:null}},{key:"end",value:function(){this.sessionInfo={},this.storage.removeSessionInfo()}},{key:"getSessionInfo",value:function(){var e={};if(this.sessionInfo.autoTrack||this.sessionInfo.manualTrack){if(this.sessionInfo.autoTrack){var t=Date.now();this.isValidSession(t)?this.sessionInfo.expiresAt=t+this.timeout:this.startAutoTracking()}this.sessionInfo.sessionStart&&(e.sessionStart=!0,this.sessionInfo.sessionStart=!1),e.sessionId=this.sessionInfo.id,this.storage.setSessionInfo(this.sessionInfo)}return e}},{key:"reset",value:function(){var e=this.sessionInfo,t=e.manualTrack;e.autoTrack?(this.sessionInfo={},this.startAutoTracking()):t&&this.start()}}]),e}()),da=function(e,t){if(!Array.isArray(e)||!Array.isArray(t))return R(t);var n=R(e);return t.forEach((function(e,t){n[t]=pa(n[t],e)})),n},pa=function(e,t){return M(da,e,t)},ga=["integrations","anonymousId","originalTimestamp"],ya=function(){function e(){r(this,e),this.initialized=!1,this.clientIntegrations=[],this.loadOnlyIntegrations={},this.clientIntegrationObjects=void 0,this.successfullyLoadedIntegration=[],this.failedToBeLoadedIntegration=[],this.toBeProcessedArray=[],this.toBeProcessedByIntegrationArray=[],this.storage=to,this.eventRepository=Xs,this.sendAdblockPage=!1,this.sendAdblockPageOptions={},this.clientSuppliedCallbacks={},this.readyCallbacks=[],this.methodToCallbackMapping={syncPixel:"syncPixelCallback"},this.loaded=!1,this.loadIntegration=!0,this.integrationsData={},this.dynamicallyLoadedIntegrations={},this.destSDKBaseURL=Ar,this.cookieConsentOptions={},this.logLevel=void 0,this.clientIntegrationsReady=!1,this.uSession=ha,this.version="2.22.3",this.lockIntegrationsVersion=!1}return o(e,[{key:"initializeUser",value:function(e){this.userId=this.storage.getUserId()||"",this.storage.setUserId(this.userId),this.userTraits=this.storage.getUserTraits()||{},this.storage.setUserTraits(this.userTraits),this.groupId=this.storage.getGroupId()||"",this.storage.setGroupId(this.groupId),this.groupTraits=this.storage.getGroupTraits()||{},this.storage.setGroupTraits(this.groupTraits),this.anonymousId=this.getAnonymousId(e),this.storage.setAnonymousId(this.anonymousId)}},{key:"setInitialPageProperties",value:function(){if(null==this.storage.getInitialReferrer()&&null==this.storage.getInitialReferringDomain()){var e=fo();this.storage.setInitialReferrer(e),this.storage.setInitialReferringDomain(ho(e))}}},{key:"allModulesInitialized",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return new Promise((function(n){e.clientIntegrations.every((function(t){return null!=e.dynamicallyLoadedIntegrations["".concat(oa[t.name]).concat("_RS")]}))||t>=2e4?n(e):e.pause(1e3).then((function(){return e.allModulesInitialized(t+1e3).then(n)}))}))}},{key:"executeReadyCallback",value:function(){this.readyCallbacks.forEach((function(e){return e()}))}},{key:"integrationSDKLoaded",value:function(e,t){try{return window.hasOwnProperty(e)&&window[e][t]&&void 0!==window[e][t].prototype.constructor}catch(e){return oo(e),!1}}},{key:"processResponse",value:function(e,t){var r,i=this;try{var o=t;try{if("string"==typeof t&&(o=JSON.parse(t)),!o||"object"!==n(o)||Array.isArray(o))throw new Error("Invalid source configuration")}catch(e){return void oo(e)}if(!0===B(o.source.config,"statsCollection.errorReports.enabled")){var s=B(o.source.config,"statsCollection.errorReports.provider")||"bugsnag";Ir.includes(s)||dt("Invalid error reporting provider value"),"bugsnag"===s&&(r="bugsnag",window.hasOwnProperty(r)||no(r,"https://d2wy8f7a9ursnm.cloudfront.net/v7/bugsnag.min.js",{isNonNativeSDK:"true"}),function(e){if(!window.hasOwnProperty("rsBugsnagClient"))if(void 0!==window.Bugsnag)fa(e);else{var t=setInterval((function(){void 0!==window.Bugsnag&&(clearInterval(t),fa(e))}),100);setTimeout((function(){clearInterval(t)}),1e4)}}(o.source.id))}if(o.source.destinations.forEach((function(e){e.enabled&&this.clientIntegrations.push({name:e.destinationDefinition.name,config:e.config})}),this),this.clientIntegrations=vo(this.loadOnlyIntegrations,this.clientIntegrations),Object.keys(this.cookieConsentOptions).length>0)try{var a=aa.initialize(this.cookieConsentOptions);this.clientIntegrations=this.clientIntegrations.filter((function(e){return!a||a&&a.isEnabled(e.config)}))}catch(e){oo(e)}var u="";Ao().isStaging&&(u="-staging"),ro("Starting device-mode initialization"),this.clientIntegrations.forEach((function(e){var t=oa[e.name],n="".concat(t).concat("_RS"),r="".concat(i.destSDKBaseURL,"/").concat(t).concat(u,".min.js");window.hasOwnProperty(n)||no(n,r,{isNonNativeSDK:!0});var o=i,s=setInterval((function(){if(o.integrationSDKLoaded(n,t)){var r,i=window[n];clearInterval(s);try{ro("[Analytics] processResponse :: trying to initialize integration name:: ".concat(n)),(r=new i[t](e.config,o)).init(),o.isInitialized(r).then((function(){o.dynamicallyLoadedIntegrations[n]=i[t]}))}catch(e){oo(e,"[Analytics] 'integration.init()' failed :: ".concat(n," :: ").concat(e.message)),o.failedToBeLoadedIntegration.push(r)}}}),100);setTimeout((function(){clearInterval(s)}),1e4)}));var c=this;this.allModulesInitialized().then((function(){if(!c.clientIntegrations||0===c.clientIntegrations.length)return i.clientIntegrationsReady=!0,i.executeReadyCallback(),void(i.toBeProcessedByIntegrationArray=[]);c.replayEvents(c)}))}catch(e){oo(e)}}},{key:"replayEvents",value:function(e){var t,n,r;ro("Started replaying buffered events"),e.clientIntegrationObjects=[],e.clientIntegrationObjects=e.successfullyLoadedIntegration,e.clientIntegrationObjects.every((function(e){return!e.isReady||e.isReady()}))&&(this.integrationsData=(t=this.integrationsData,n=e.clientIntegrationObjects,r=R(t),n.forEach((function(e){if(e.getDataForIntegrationsObject)try{r=pa(r,e.getDataForIntegrationsObject())}catch(e){ft("[Analytics: prepareDataForIntegrationsObj]",e)}})),r),e.clientIntegrationsReady=!0,e.executeReadyCallback()),e.toBeProcessedByIntegrationArray.forEach((function(t){var n=t[0];t.shift(),Object.keys(t[0].message.integrations).length>0&&yo(t[0].message.integrations);var r,i=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=c(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){a=!0,o=e},f:function(){try{s||null==n.return||n.return()}finally{if(a)throw o}}}}(vo(t[0].message.integrations,e.clientIntegrationObjects));try{for(i.s();!(r=i.n()).done;){var o=r.value;try{if((!o.isFailed||!o.isFailed())&&o[n])if(!e.IsEventBlackListed(t[0].message.event,o.name)){var s=R(t);o[n].apply(o,u(s))}}catch(e){oo(e)}}}catch(e){i.e(e)}finally{i.f()}})),e.toBeProcessedByIntegrationArray=[]}},{key:"pause",value:function(e){return new Promise((function(t){setTimeout(t,e)}))}},{key:"isInitialized",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return new Promise((function(r){e.isLoaded()?(t.successfullyLoadedIntegration.push(e),r(t)):n>=1e4?(t.failedToBeLoadedIntegration.push(e),r(t)):t.pause(1e3).then((function(){return t.isInitialized(e,n+1e3).then(r)}))}))}},{key:"page",value:function(e,t,r,i,o){if(ro("Page event"),this.loaded){"function"==typeof i&&(o=i,i=null),"function"==typeof r&&(o=r,i=r=null),"function"==typeof t&&(o=t,i=r=t=null),"function"==typeof e&&(o=e,i=r=t=e=null),"object"===n(e)&&null!=e&&null!=e&&(i=t,r=e,t=e=null),"object"===n(t)&&null!=t&&null!=t&&(i=r,r=t,t=null),"string"==typeof e&&"string"!=typeof t&&(t=e,e=null),this.sendAdblockPage&&"RudderJS-Initiated"!=e&&this.sendSampleRequest();var s=(new _o).setType("page").build();r||(r={}),t&&(s.message.name=r.name=t),e&&(s.message.category=r.category=e),s.message.properties=this.getPageProperties(r),this.processAndSendDataToDestinations("page",s,i,o)}}},{key:"track",value:function(e,t,n,r){if(ro("Track event"),this.loaded){"function"==typeof n&&(r=n,n=null),"function"==typeof t&&(r=t,n=null,t=null);var i=(new _o).setType("track").build();e&&i.setEventName(e),i.setProperty(t||{}),this.processAndSendDataToDestinations("track",i,n,r)}}},{key:"identify",value:function(e,t,r,i){if(ro("Identify event"),this.loaded){if("function"==typeof r&&(i=r,r=null),"function"==typeof t&&(i=t,r=null,t=null),"object"===n(e)&&(r=t,t=e,e=this.userId),e&&this.userId&&e!==this.userId&&this.reset(),this.userId=Io(e),this.storage.setUserId(this.userId),t){for(var o in t)this.userTraits[o]=t[o];this.storage.setUserTraits(this.userTraits)}var s=(new _o).setType("identify").build();this.processAndSendDataToDestinations("identify",s,r,i)}}},{key:"alias",value:function(e,t,r,i){if(ro("Alias event"),this.loaded){"function"==typeof r&&(i=r,r=null),"function"==typeof t&&(i=t,r=null,t=null),"function"==typeof e&&(i=e,r=null,t=null,e=null),"object"===n(t)&&(r=t,t=null),"object"===n(e)&&(r=e,t=null,e=null);var o=(new _o).setType("alias").build();o.message.previousId=Io(t)||(this.userId?this.userId:this.getAnonymousId()),o.message.userId=Io(e),this.processAndSendDataToDestinations("alias",o,r,i)}}},{key:"group",value:function(e,t,r,i){if(ro("Group event"),this.loaded&&0!==arguments.length){"function"==typeof r&&(i=r,r=null),"function"==typeof t&&(i=t,r=null,t=null),"object"===n(e)&&(r=t,t=e,e=this.groupId),"function"==typeof e&&(i=e,r=null,t=null,e=this.groupId),this.groupId=Io(e),this.storage.setGroupId(this.groupId);var o=(new _o).setType("group").build();if(t)for(var s in t)this.groupTraits[s]=t[s];else this.groupTraits={};this.storage.setGroupTraits(this.groupTraits),this.processAndSendDataToDestinations("group",o,r,i)}}},{key:"IsEventBlackListed",value:function(e,t){if(!e||"string"!=typeof e)return!1;var n=gr[t],r=this.clientIntegrations.find((function(e){return e.name===n})).config,i=r.blacklistedEvents,o=r.whitelistedEvents,s=r.eventFilteringOption;if(!s)return!1;var a=e.trim().toUpperCase();switch(s){case"disable":default:return!1;case"blacklistedEvents":return!!Array.isArray(i)&&i.some((function(e){return e.eventName.trim().toUpperCase()===a}));case"whitelistedEvents":return!Array.isArray(o)||!o.some((function(e){return e.eventName.trim().toUpperCase()===a}))}}},{key:"processAndSendDataToDestinations",value:function(e,n,r,i){var o=this;try{this.anonymousId||this.setAnonymousId(),ro("Started sending data to destinations"),n.message.context.traits=t({},this.userTraits),n.message.anonymousId=this.anonymousId,n.message.userId=n.message.userId?n.message.userId:this.userId,"group"==e&&(this.groupId&&(n.message.groupId=this.groupId),this.groupTraits&&(n.message.traits=t({},this.groupTraits)));try{var s=this.uSession.getSessionInfo(),a=s.sessionId,u=s.sessionStart;n.message.context.sessionId=a,u&&(n.message.context.sessionStart=!0)}catch(e){oo(e)}this.processOptionsParam(n,r),function(e,t){var n=e.properties,r=e.traits;n&&Object.keys(n).forEach((function(e){vr.indexOf(e.toLowerCase())>=0&&dt("Warning! : Reserved keyword used in properties--\x3e ".concat(e," with ").concat(t," call"))})),r&&Object.keys(r).forEach((function(e){vr.indexOf(e.toLowerCase())>=0&&dt("Warning! : Reserved keyword used in traits--\x3e ".concat(e," with ").concat(t," call"))}));var i=e.context.traits;i&&Object.keys(i).forEach((function(e){vr.indexOf(e.toLowerCase())>=0&&dt("Warning! : Reserved keyword used in traits --\x3e ".concat(e," with ").concat(t," call"))}))}(n.message,e);var c=n.message.integrations||{All:!0};if(yo(c),n.message.integrations=c,this.clientIntegrationObjects)vo(c,this.clientIntegrationObjects).forEach((function(t){try{if((!t.isFailed||!t.isFailed())&&t[e])if(!o.IsEventBlackListed(n.message.event,t.name)){var r=R(n);t[e](r)}}catch(e){oo(e,"[sendToNative]:: [Destination: ".concat(t.name,"]:: "))}}));else this.toBeProcessedByIntegrationArray.push([e,n]);go(n.message.integrations,yr),n.message.integrations=function(e,t){var n=R(e),r=Object.keys(t).filter((function(e){return!(!0===t[e]&&n[e])})).reduce((function(e,n){return e[n]=t[n],e}),{});return pa(n,r)}(this.integrationsData,c),this.eventRepository.enqueue(n,e),i&&i(n)}catch(e){oo(e)}}},{key:"utm",value:function(e){var t;"?"===e.charAt(0)&&(e=e.substring(1)),e=e.replace(/\?/g,"&");var n=b(e),r={};for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&"utm_"===i.substr(0,4)&&("campaign"===(t=i.substr(4))&&(t="name"),r[t]=n[i]);return r}},{key:"addCampaignInfo",value:function(e){var t=e.message.context;if(t&&"object"===n(t)){var r=lo().search;e.message.context.campaign=this.utm(r)}}},{key:"processOptionsParam",value:function(e,r){var i=e.message,o=i.type,a=i.properties;this.addCampaignInfo(e),e.message.context.page=this.getContextPageProperties("page"===o?a:void 0),function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};"object"===n(t)&&null!==t&&Object.keys(t).forEach((function(n){ga.includes(n)&&(e[n]=t[n])}))}(e.message,r),e.message.context=function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=e.context;return"object"!==n(r)||null===r||Object.keys(r).forEach((function(e){ga.includes(e)||("context"!==e?i=pa(i,s({},e,r[e])):"object"===n(r[e])&&null!==r[e]?i=pa(i,t({},r[e])):dt("[Analytics: processOptionsParam] context passed in options ".concat(e," is not object.")))})),i}(e.message,r)}},{key:"getPageProperties",value:function(e,t){var n=lo(),r=t&&t.page||{};for(var i in n)void 0===e[i]&&(e[i]=r[i]||n[i]);return e}},{key:"getContextPageProperties",value:function(e){var t=lo(),n={};for(var r in t)n[r]=e&&e[r]?e[r]:t[r];return n}},{key:"reset",value:function(e){ro("reset API :: flag: ".concat(e)),this.loaded&&(e&&(this.anonymousId=""),this.userId="",this.userTraits={},this.groupId="",this.groupTraits={},this.uSession.reset(),this.storage.clear(e))}},{key:"getAnonymousId",value:function(e){return this.anonymousId=this.storage.getAnonymousId(e),this.anonymousId||this.setAnonymousId(),this.anonymousId}},{key:"getUserId",value:function(){return this.userId}},{key:"getSessionId",value:function(){return this.uSession.getSessionId()}},{key:"getUserTraits",value:function(){return this.userTraits}},{key:"getGroupId",value:function(){return this.groupId}},{key:"getGroupTraits",value:function(){return this.groupTraits}},{key:"setAnonymousId",value:function(e,t){var n=t?ia(t):null,r=n?n.rs_amp_id:null;this.anonymousId=e||r||uo(),this.storage.setAnonymousId(this.anonymousId)}},{key:"isValidWriteKey",value:function(e){return e&&"string"==typeof e&&e.trim().length>0}},{key:"isValidServerUrl",value:function(e){return e&&"string"==typeof e&&e.trim().length>0}},{key:"isDatasetAvailable",value:function(){var e=document.createElement("div");return e.setAttribute("data-a-b","c"),!!e.dataset&&"c"===e.dataset.aB}},{key:"loadAfterPolyfill",value:function(e,r,i){var o=this;if(i&&i.logLevel&&(this.logLevel=i.logLevel,ct(i.logLevel)),!this.storage||0===Object.keys(this.storage).length)throw Error("Cannot proceed as no storage is available");if(i&&i.cookieConsentManager&&(this.cookieConsentOptions=R(i.cookieConsentManager)),!this.isValidWriteKey(e)||!this.isValidServerUrl(r))throw Error("Unable to load the SDK due to invalid writeKey or serverUrl");var s={};if(i&&i.setCookieDomain&&(s=t(t({},s),{},{domain:i.setCookieDomain})),i&&"boolean"==typeof i.secureCookie&&(s=t(t({},s),{},{secure:i.secureCookie})),i&&Er.includes(i.sameSiteCookie)&&(s=t(t({},s),{},{samesite:i.sameSiteCookie})),this.storage.options(s),i&&i.integrations&&(a(this.loadOnlyIntegrations,i.integrations),yo(this.loadOnlyIntegrations)),i&&i.sendAdblockPage&&(this.sendAdblockPage=!0),i&&i.sendAdblockPageOptions&&"object"===n(i.sendAdblockPageOptions)&&(this.sendAdblockPageOptions=i.sendAdblockPageOptions),this.uSession.initialize(i),i&&i.clientSuppliedCallbacks){var u={};Object.keys(this.methodToCallbackMapping).forEach((function(e){o.methodToCallbackMapping.hasOwnProperty(e)&&i.clientSuppliedCallbacks[o.methodToCallbackMapping[e]]&&(u[e]=i.clientSuppliedCallbacks[o.methodToCallbackMapping[e]])})),a(this.clientSuppliedCallbacks,u),this.registerCallbacks(!0)}if(i&&null!=i.loadIntegration&&(this.loadIntegration=!!i.loadIntegration),i&&void 0!==i.lockIntegrationsVersion&&(this.lockIntegrationsVersion=!0===i.lockIntegrationsVersion),this.eventRepository.initialize(e,r,i),this.initializeUser(i?i.anonymousIdOptions:void 0),this.setInitialPageProperties(),this.loaded=!0,this.destSDKBaseURL=function(e,t,n){var r="";if(n){if(!(r=ao(n))){var i="CDN base URL for integrations is not valid";throw oo({message:"[Analytics] load:: ".concat(i)}),Error("Failed to load Rudder SDK: ".concat(i))}return r}var o=Ao().sdkURL;return r=o?o.split("/").slice(0,-1).concat("js-integrations").join("/"):Ar,t&&(r=r.replace("v1.1",e)),r}(this.version,this.lockIntegrationsVersion,i&&i.destSDKBaseURL),i&&i.getSourceConfig)if("function"!=typeof i.getSourceConfig)oo(new Error('option "getSourceConfig" must be a function'));else{var c=i.getSourceConfig();c instanceof Promise?c.then((function(e){return o.processResponse(200,e)})).catch(oo):this.processResponse(200,c),ma(this)}else{var l=function(e){return mr.concat(mr.includes("?")?"&":"?").concat(e?"writeKey=".concat(e):"")}(e);i&&i.configUrl&&(l=function(e,t){var n=e;-1===n.indexOf("sourceConfig")&&(n="".concat(ao(n),"/sourceConfig/")),n="/"===n.slice(-1)?n:"".concat(n,"/");var r=t.split("?")[1],i=n.split("?");return i.length>1&&i[1]!==r?"".concat(i[0],"?").concat(r):"".concat(n,"?").concat(r)}(i.configUrl,l));try{!function(e,t,n,r){var i=r.bind(e),o=new XMLHttpRequest;o.open("GET",t,!0),o.setRequestHeader("Authorization","Basic ".concat(btoa("".concat(n,":")))),o.onload=function(){var e=o.status;200==e?i(200,o.responseText):(oo(new Error("request failed with status: ".concat(o.status," for url: ").concat(t))),i(e))},o.send()}(this,l,e,this.processResponse)}catch(e){oo(e)}ma(this)}}},{key:"load",value:function(e,t,n){if(!this.loaded)if(String.prototype.endsWith&&String.prototype.startsWith&&String.prototype.includes&&Array.prototype.find&&Array.prototype.includes&&Promise&&Object.entries&&Object.values&&String.prototype.replaceAll&&this.isDatasetAvailable())this.loadAfterPolyfill(e,t,n);else{var r="polyfill";no(r,"https://polyfill.io/v3/polyfill.min.js?features=Array.prototype.find%2CArray.prototype.includes%2CPromise%2CString.prototype.endsWith%2CString.prototype.includes%2CString.prototype.startsWith%2CObject.entries%2CObject.values%2CElement.prototype.dataset%2CString.prototype.replaceAll",{skipDatasetAttributes:!0});var i=this,o=setInterval((function(){(window.hasOwnProperty(r)||null!==document.getElementById(r))&&(clearInterval(o),i.loadAfterPolyfill(e,t,n))}),100);setTimeout((function(){clearInterval(o)}),1e4)}}},{key:"ready",value:function(e){this.loaded&&("function"!=typeof e?dt("ready callback is not a function"):this.clientIntegrationsReady?e():this.readyCallbacks.push(e))}},{key:"initializeCallbacks",value:function(){var e=this;Object.keys(this.methodToCallbackMapping).forEach((function(t){e.methodToCallbackMapping.hasOwnProperty(t)&&e.on(t,(function(){}))}))}},{key:"registerCallbacks",value:function(e){var t=this;e||Object.keys(this.methodToCallbackMapping).forEach((function(e){t.methodToCallbackMapping.hasOwnProperty(e)&&window.rudderanalytics&&"function"==typeof window.rudderanalytics[t.methodToCallbackMapping[e]]&&(t.clientSuppliedCallbacks[e]=window.rudderanalytics[t.methodToCallbackMapping[e]])})),Object.keys(this.clientSuppliedCallbacks).forEach((function(e){t.clientSuppliedCallbacks.hasOwnProperty(e)&&t.on(e,t.clientSuppliedCallbacks[e])}))}},{key:"sendSampleRequest",value:function(){no("ad-block","//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js")}},{key:"startSession",value:function(e){this.uSession.start(e)}},{key:"endSession",value:function(){this.uSession.end()}}]),e}(),va=new ya;function ma(e){if(e.toBeProcessedArray.length>0)for(;e.toBeProcessedArray.length>0;){var t=u(e.toBeProcessedArray[0]);e.toBeProcessedArray.shift();var n=t[0];t.shift(),e[n].apply(e,u(t))}}y(va),window.addEventListener("error",(function(e){oo(e,void 0,va)}),!0),va.initializeCallbacks(),va.registerCallbacks(!1);var Aa,Ia=window.rudderanalytics,Ea=Array.isArray(Ia);if(Ea)for(var ba=0;ba<Ia.length;){if(Ia[ba]&&"load"===Ia[ba][0]){Aa=Ia[ba],Ia.splice(ba,1);break}ba+=1}!function(e){var t="ajs_trait_",n="ajs_prop_";function r(e,t){var n={};return Object.keys(e).forEach((function(r){r.startsWith(t)&&(n[r.substr(t.length)]=e[r])})),n}var i=b(e);i.ajs_aid&&va.toBeProcessedArray.push(["setAnonymousId",i.ajs_aid]),i.ajs_uid&&va.toBeProcessedArray.push(["identify",i.ajs_uid,r(i,t)]),i.ajs_event&&va.toBeProcessedArray.push(["track",i.ajs_event,r(i,n)])}(window.location.search),Ea&&Ia.forEach((function(e){return va.toBeProcessedArray.push(e)})),Aa&&Aa.length>0&&(Aa.shift(),va.load.apply(va,u(Aa)));var Oa=va.ready.bind(va),Sa=va.identify.bind(va),ka=va.page.bind(va),Ca=va.track.bind(va),wa=va.alias.bind(va),_a=va.group.bind(va),Ta=va.reset.bind(va),Ra=va.load.bind(va),Pa=va.initialized=!0,La=va.getUserId.bind(va),xa=va.getSessionId.bind(va),Ma=va.getUserTraits.bind(va),Da=va.getAnonymousId.bind(va),Na=va.setAnonymousId.bind(va),Ba=va.getGroupId.bind(va),Ga=va.getGroupTraits.bind(va),Fa=va.startSession.bind(va),Ua=va.endSession.bind(va);export{wa as alias,Ua as endSession,Da as getAnonymousId,Ba as getGroupId,Ga as getGroupTraits,xa as getSessionId,La as getUserId,Ma as getUserTraits,_a as group,Sa as identify,Pa as initialized,Ra as load,ka as page,Oa as ready,Ta as reset,Na as setAnonymousId,Fa as startSession,Ca as track};
9
+
10
+ //=====================================================================================
11
+
12
+ console.log("This prints to the console of the page (injected only if the page url matched)");
13
+
14
+ const initialiseRudderstack = () => {
15
+ rudderanalytics.ready(() => {
16
+ console.log("we are all set!!!");
17
+ });
18
+
19
+ rudderanalytics.load("<writeKey>", "<dataPlaneURL>");
20
+ }
21
+
22
+
23
+ const testEvents = () => {
24
+ rudderanalytics.page();
25
+
26
+ rudderanalytics.identify(
27
+ "moumita123",
28
+ {email: "name@domain.com"},
29
+ {
30
+ page: {
31
+ path: "",
32
+ referrer: "",
33
+ search: "",
34
+ title: "",
35
+ url: "",
36
+ },
37
+ },
38
+ () => {
39
+ console.log("in identify call");
40
+ }
41
+ );
42
+
43
+ rudderanalytics.track(
44
+ "test track event GA3",
45
+ {
46
+ revenue: 30,
47
+ currency: "USD",
48
+ user_actual_id: 12345,
49
+ },
50
+ () => {
51
+ console.log("in track call");
52
+ }
53
+ );
54
+ };
55
+
56
+ chrome.runtime.onMessage.addListener((obj, sender, response) => {
57
+ const { type, value} = obj;
58
+
59
+ if (type === "track") {
60
+ testEvents(value);
61
+ }
62
+ });
63
+
64
+ initialiseRudderstack();
65
+ })();