effect-browser 0.3.0-beta.22 → 0.3.0-beta.23

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.
@@ -13,7 +13,8 @@ import { d as parts$1, l as validated, t as Current$2, u as description } from "
13
13
  import { request } from "./Matching.mjs";
14
14
  import { Change, Changes } from "./Change.mjs";
15
15
  import { Window } from "./Window.mjs";
16
- import { Cache, Cause, Clock, Context, Crypto, Data, DateTime, Deferred, Duration, Effect, Exit, Fiber, FiberSet, MutableRef, Option, Queue, Ref, Result, Schedule, Schema, Scope, Semaphore, Stream, SynchronizedRef } from "effect";
16
+ import { Cache, Cause, Clock, Context, Data, DateTime, Deferred, Duration, Effect, Exit, Fiber, FiberSet, MutableRef, Option, Queue, Ref, Result, Schedule, Schema, Scope, Semaphore, Stream, SynchronizedRef } from "effect";
17
+ import { SecureRandom } from "effect/crypto";
17
18
  import { Base64 } from "effect/encoding";
18
19
  //#region src/internal/input/gate.ts
19
20
  /**
@@ -473,11 +474,11 @@ const listen = Effect.fnUntraced(function* (playwright, page, publish, now, answ
473
474
  });
474
475
  //#endregion
475
476
  //#region src/internal/page/identity.ts
476
- /** Connection identity uses the supplied Crypto service, or the host's Web Crypto on Node/Bun. */
477
+ /** Connection identity uses the supplied SecureRandom service, or the host's Web Crypto on Node/Bun. */
477
478
  const failed = () => undispatched("make", new Failed({ detail: "Could not name connection" }));
478
479
  const make$24 = Effect.gen(function* () {
479
- const supplied = yield* Effect.serviceOption(Crypto.Crypto);
480
- return yield* Option.isSome(supplied) ? supplied.value.randomUUIDv4().pipe(Effect.mapError(failed)) : Effect.try({
480
+ const supplied = yield* Effect.serviceOption(SecureRandom.SecureRandom);
481
+ return yield* Option.isSome(supplied) ? supplied.value.uuidV4() : Effect.try({
481
482
  try: () => globalThis.crypto.randomUUID(),
482
483
  catch: failed
483
484
  });
@@ -4072,4 +4073,4 @@ const make = Effect.fn("Browser.make")(function* (context, info, options = {}) {
4072
4073
  //#endregion
4073
4074
  export { make$1 as a, make as i, Browser_exports as n, fold as o, Suspension as r, make$27 as s, Browser as t };
4074
4075
 
4075
- //# sourceMappingURL=Browser-Cq2K1FEA.mjs.map
4076
+ //# sourceMappingURL=Browser-BKPAbyys.mjs.map