@uniformdev/context 20.25.2-alpha.3 → 20.26.1-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.esm.js CHANGED
@@ -2257,7 +2257,6 @@ var ScriptType = /* @__PURE__ */ ((ScriptType2) => {
2257
2257
  var EdgeNodeTagName = "nesitag";
2258
2258
 
2259
2259
  // src/insights/index.ts
2260
- import { v4 } from "uuid";
2261
2260
  var getBasePayload = () => {
2262
2261
  const timeZone = Intl.DateTimeFormat().resolvedOptions().timeZone;
2263
2262
  const locale = navigator.languages && navigator.languages.length ? navigator.languages[0] : navigator.userLanguage || navigator.language || navigator.browserLanguage || "en";
@@ -2596,8 +2595,11 @@ var enableUniformInsights = (options) => {
2596
2595
  };
2597
2596
  };
2598
2597
  var generalRandomId = () => {
2599
- const id = v4();
2600
- return id.replaceAll("-", "").toLowerCase();
2598
+ if (typeof crypto !== "undefined" && typeof crypto.randomUUID === "function") {
2599
+ const id = crypto.randomUUID();
2600
+ return id.replaceAll("-", "").toLowerCase();
2601
+ }
2602
+ return Math.random().toString(32).substring(2);
2601
2603
  };
2602
2604
 
2603
2605
  // src/logging/enableConsoleLogDrain.ts
package/dist/index.js CHANGED
@@ -2350,7 +2350,6 @@ var ScriptType = /* @__PURE__ */ ((ScriptType2) => {
2350
2350
  var EdgeNodeTagName = "nesitag";
2351
2351
 
2352
2352
  // src/insights/index.ts
2353
- var import_uuid = require("uuid");
2354
2353
  var getBasePayload = () => {
2355
2354
  const timeZone = Intl.DateTimeFormat().resolvedOptions().timeZone;
2356
2355
  const locale = navigator.languages && navigator.languages.length ? navigator.languages[0] : navigator.userLanguage || navigator.language || navigator.browserLanguage || "en";
@@ -2689,8 +2688,11 @@ var enableUniformInsights = (options) => {
2689
2688
  };
2690
2689
  };
2691
2690
  var generalRandomId = () => {
2692
- const id = (0, import_uuid.v4)();
2693
- return id.replaceAll("-", "").toLowerCase();
2691
+ if (typeof crypto !== "undefined" && typeof crypto.randomUUID === "function") {
2692
+ const id = crypto.randomUUID();
2693
+ return id.replaceAll("-", "").toLowerCase();
2694
+ }
2695
+ return Math.random().toString(32).substring(2);
2694
2696
  };
2695
2697
 
2696
2698
  // src/logging/enableConsoleLogDrain.ts
package/dist/index.mjs CHANGED
@@ -2257,7 +2257,6 @@ var ScriptType = /* @__PURE__ */ ((ScriptType2) => {
2257
2257
  var EdgeNodeTagName = "nesitag";
2258
2258
 
2259
2259
  // src/insights/index.ts
2260
- import { v4 } from "uuid";
2261
2260
  var getBasePayload = () => {
2262
2261
  const timeZone = Intl.DateTimeFormat().resolvedOptions().timeZone;
2263
2262
  const locale = navigator.languages && navigator.languages.length ? navigator.languages[0] : navigator.userLanguage || navigator.language || navigator.browserLanguage || "en";
@@ -2596,8 +2595,11 @@ var enableUniformInsights = (options) => {
2596
2595
  };
2597
2596
  };
2598
2597
  var generalRandomId = () => {
2599
- const id = v4();
2600
- return id.replaceAll("-", "").toLowerCase();
2598
+ if (typeof crypto !== "undefined" && typeof crypto.randomUUID === "function") {
2599
+ const id = crypto.randomUUID();
2600
+ return id.replaceAll("-", "").toLowerCase();
2601
+ }
2602
+ return Math.random().toString(32).substring(2);
2601
2603
  };
2602
2604
 
2603
2605
  // src/logging/enableConsoleLogDrain.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uniformdev/context",
3
- "version": "20.25.2-alpha.3+fac462fd6d",
3
+ "version": "20.26.1-alpha.0+ff834f63d0",
4
4
  "description": "Uniform Context core package",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "main": "./dist/index.js",
@@ -59,8 +59,7 @@
59
59
  "js-cookie": "3.0.5",
60
60
  "mitt": "^3.0.1",
61
61
  "p-limit": "^3.1.0",
62
- "rfdc": "^1.4.1",
63
- "uuid": "9.0.1"
62
+ "rfdc": "^1.4.1"
64
63
  },
65
64
  "files": [
66
65
  "/dist"
@@ -68,5 +67,5 @@
68
67
  "publishConfig": {
69
68
  "access": "public"
70
69
  },
71
- "gitHead": "fac462fd6dd8d6d51a6d37d5ed321ed058e23d00"
70
+ "gitHead": "ff834f63d07f7f709e42f69705b93ae20f6b7ddf"
72
71
  }