@minion-stack/shared 0.8.0 → 0.8.1

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.
@@ -1,2 +1,2 @@
1
- export declare function uuid(): string;
1
+ export declare const uuid: () => string;
2
2
  //# sourceMappingURL=uuid.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"uuid.d.ts","sourceRoot":"","sources":["../../src/utils/uuid.ts"],"names":[],"mappings":"AAAA,wBAAgB,IAAI,IAAI,MAAM,CAM7B"}
1
+ {"version":3,"file":"uuid.d.ts","sourceRoot":"","sources":["../../src/utils/uuid.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,IAAI,QAAO,MAA6B,CAAC"}
@@ -1,9 +1,4 @@
1
- export function uuid() {
2
- if (typeof crypto !== 'undefined' && crypto.randomUUID)
3
- return crypto.randomUUID();
4
- return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {
5
- const r = (Math.random() * 16) | 0;
6
- return (c === 'x' ? r : (r & 0x3) | 0x8).toString(16);
7
- });
8
- }
1
+ // ponytail: crypto.randomUUID is native in Node 15.7+ and all browser secure
2
+ // contexts (https + localhost). No fallback needed.
3
+ export const uuid = () => crypto.randomUUID();
9
4
  //# sourceMappingURL=uuid.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"uuid.js","sourceRoot":"","sources":["../../src/utils/uuid.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,IAAI;IAClB,IAAI,OAAO,MAAM,KAAK,WAAW,IAAI,MAAM,CAAC,UAAU;QAAE,OAAO,MAAM,CAAC,UAAU,EAAE,CAAC;IACnF,OAAO,sCAAsC,CAAC,OAAO,CAAC,OAAO,EAAE,CAAC,CAAC,EAAE,EAAE;QACnE,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,MAAM,EAAE,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC;QACnC,OAAO,CAAC,CAAC,KAAK,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,GAAG,GAAG,CAAC,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;IACxD,CAAC,CAAC,CAAC;AACL,CAAC"}
1
+ {"version":3,"file":"uuid.js","sourceRoot":"","sources":["../../src/utils/uuid.ts"],"names":[],"mappings":"AAAA,6EAA6E;AAC7E,oDAAoD;AACpD,MAAM,CAAC,MAAM,IAAI,GAAG,GAAW,EAAE,CAAC,MAAM,CAAC,UAAU,EAAE,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@minion-stack/shared",
3
- "version": "0.8.0",
3
+ "version": "0.8.1",
4
4
  "description": "Shared gateway protocol types and utilities for the Minion platform.",
5
5
  "license": "MIT",
6
6
  "repository": {