@fkn/lib 0.9.48 → 0.9.49

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/{storage-C6F9SnDM.js → account-storage-C31d68BN.js} +2 -2
  2. package/{storage-DmRIhg1P.cjs → account-storage-C6hcXjG0.cjs} +1 -1
  3. package/{storage-B_mXNAdB.d.ts → account-storage-DHl6bXdb.d.ts} +2 -2
  4. package/{api-Cpi-qz1j.d.ts → api-wnOQJEK6.d.ts} +34 -42
  5. package/api.d.ts +2 -2
  6. package/cloud/dns.d.ts +1 -1
  7. package/cloud/fetch.d.ts +1 -1
  8. package/cloud/fs/promises.d.ts +1 -1
  9. package/cloud/fs.cjs +1 -1
  10. package/cloud/fs.d.ts +3 -3
  11. package/cloud/fs.js +12 -12
  12. package/cloud/net.d.ts +1 -1
  13. package/{cloud-DK3DtdsU.d.ts → cloud-CWHjH89l.d.ts} +3 -3
  14. package/cloud.d.ts +4 -4
  15. package/{contract-XlEPwc7b.d.ts → contract-DGuGXxKd.d.ts} +119 -82
  16. package/contract.cjs +1 -1
  17. package/contract.d.ts +2 -2
  18. package/contract.js +69 -3
  19. package/dgram.d.ts +2 -2
  20. package/dns.d.ts +1 -1
  21. package/fs/promises.cjs +1 -1
  22. package/fs/promises.d.ts +1 -1
  23. package/fs/promises.js +1 -1
  24. package/{fs-lKZe5xIo.d.ts → fs-BZv2djbS.d.ts} +2 -2
  25. package/{fs-BY0Csn2V.js → fs-ClnOPmRF.js} +39 -39
  26. package/fs-zERmcLRS.cjs +1 -0
  27. package/fs.cjs +1 -1
  28. package/fs.d.ts +3 -3
  29. package/fs.js +2 -2
  30. package/http.d.ts +1 -1
  31. package/{index-D9x6A-Gx.d.ts → index-DawD_N1P.d.ts} +2 -2
  32. package/index.cjs +1 -1
  33. package/index.d.ts +5 -6
  34. package/index.js +39 -40
  35. package/{messages-d7pvCXPn.d.ts → messages-AdPfdoLV.d.ts} +1 -1
  36. package/messages.d.ts +1 -1
  37. package/{net-C2Yz0job.d.ts → net-C2sulnNU.d.ts} +2 -2
  38. package/net.d.ts +1 -1
  39. package/package.json +5 -5
  40. package/packages.d.ts +1 -1
  41. package/{proxy-BZ-YFeXe.d.ts → proxy-MVuD49E2.d.ts} +2 -2
  42. package/rooms.d.ts +1 -1
  43. package/storage.cjs +1 -0
  44. package/storage.d.ts +69 -0
  45. package/storage.js +137 -0
  46. package/fs-DnF1cQuE.cjs +0 -1
  47. package/links.cjs +0 -1
  48. package/links.d.ts +0 -65
  49. package/links.js +0 -187
package/contract.cjs CHANGED
@@ -1 +1 @@
1
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});var e=`fkn-attach-frame`,t=`fkn-attach-window`,n=`sdbx-control`,r=`sdbx-attach-error`,i=`fkn-frame-message`,a=`sdbx-frame-message`,o={hello:`fkn-attach-window`,refused:`fkn-attach-window-refused`,gone:`fkn-attach-window-gone`,detach:`fkn-attach-window-detach`},s={request:`sdbx-jar-request`,port:`sdbx-jar-port`,mode:`sdbx-jar-mode`},c=[`bad-attach`,`no-storage`,`bad-jar`,`no-parent`,`no-jar-host`,`no-token`,`no-indexeddb`,`failed`],l={hello:`fkn-jar-hello`,ready:`fkn-jar-ready`,port:`fkn-jar-port`,who:`fkn-jar-who`,host:`fkn-jar-host`},u=2e4,d=3e4,f=6e4,p={default:6048e5,min:6e4,max:31536e6},m={min:6e4,max:31536e6};exports.ATTACH_FRAME_KEY=e,exports.ATTACH_WINDOW_KEY=t,exports.ATTACH_WINDOW_MESSAGE=o,exports.FRAME_MESSAGE=i,exports.JAR_ANCHOR_MESSAGE=l,exports.LINK_EXPIRES_MS=m,exports.ROOM_TEMPORARY_MS=p,exports.SHELL_ATTACH_ERROR=r,exports.SHELL_CONTROL_KEY=n,exports.SHELL_FRAME_MESSAGE=a,exports.SHELL_JAR_MESSAGE=s,exports.SHELL_JAR_UNREACHABLE=c,exports.WINDOW_HANDSHAKE_TIMEOUT_MS=f,exports.WINDOW_HELLO_TIMEOUT_MS=u,exports.WINDOW_JAR_MODE_TIMEOUT_MS=d;
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});var e=`fkn-attach-frame`,t=`fkn-attach-window`,n=`sdbx-control`,r=`sdbx-attach-error`,i=`fkn-frame-message`,a=`sdbx-frame-message`,o={hello:`fkn-attach-window`,refused:`fkn-attach-window-refused`,gone:`fkn-attach-window-gone`,detach:`fkn-attach-window-detach`},s={request:`sdbx-jar-request`,port:`sdbx-jar-port`,mode:`sdbx-jar-mode`},c=[`bad-attach`,`no-storage`,`bad-jar`,`no-parent`,`no-jar-host`,`no-token`,`no-indexeddb`,`failed`],l={hello:`fkn-jar-hello`,ready:`fkn-jar-ready`,port:`fkn-jar-port`,who:`fkn-jar-who`,host:`fkn-jar-host`},u=2e4,d=3e4,f=6e4,p={default:6048e5,min:6e4,max:31536e6},m={notAFile:{code:`invalid`,message:`storage: the data is not a Blob or a ReadableStream`},badSize:{code:`invalid`,message:`storage: a stream needs the size it will deliver, a whole number of bytes`},shortStream:{code:`invalid`,message:`storage: the stream did not deliver the size it declared`},tooLarge:{code:`invalid`,message:`storage: the file is too large to store`},badKey:{code:`invalid`,message:`storage: the key is not 32 bytes base64url`},badUrl:{code:`invalid`,message:`storage: the url does not name a stored object`},badLimit:{code:`invalid`,message:`storage: the limit is out of range`},badCursor:{code:`invalid`,message:`storage: the cursor is not one list answered`},notFound:{code:`not-found`,message:`storage: no object at this url`},integrity:{code:`integrity`,message:`storage: the object does not match its key`},needsAccount:{code:`denied`,message:`storage: storing needs an account`},notCreator:{code:`denied`,message:`storage: only the app that stored the object can delete it`},quota:{code:`quota`,message:`storage: storage quota exceeded`},tooMany:{code:`too-many`,message:`storage: too many stored objects`},tooManyThisHour:{code:`too-many`,message:`storage: too many objects stored this hour, try again later`},accountChanged:{code:`account-changed`,message:`storage: the signed-in account changed`},unavailable:{code:`unavailable`,message:`storage: storage is unavailable`}};exports.ATTACH_FRAME_KEY=e,exports.ATTACH_WINDOW_KEY=t,exports.ATTACH_WINDOW_MESSAGE=o,exports.FRAME_MESSAGE=i,exports.JAR_ANCHOR_MESSAGE=l,exports.ROOM_TEMPORARY_MS=p,exports.SHELL_ATTACH_ERROR=r,exports.SHELL_CONTROL_KEY=n,exports.SHELL_FRAME_MESSAGE=a,exports.SHELL_JAR_MESSAGE=s,exports.SHELL_JAR_UNREACHABLE=c,exports.STORAGE_REFUSALS=m,exports.WINDOW_HANDSHAKE_TIMEOUT_MS=f,exports.WINDOW_HELLO_TIMEOUT_MS=u,exports.WINDOW_JAR_MODE_TIMEOUT_MS=d;
package/contract.d.ts CHANGED
@@ -1,4 +1,4 @@
1
1
  import { d as CookieMatchWire, u as ClearCookiesWire } from "./index-DlBWSKwV.js";
2
- import { $ as ROOM_TEMPORARY_MS, A as Link, At as SurfaceRect, B as MountDescriptor, Bt as WINDOW_JAR_MODE_TIMEOUT_MS, C as FrameMessageRelay, Ct as SetOverlayHost, D as IpFamily, Dt as ShellJarUnreachable, E as InstalledPackage, Et as ShellGotoOptions, F as LinksErrorCode, Ft as UdpDatagram, G as PackagesErrorCode, H as OverlayState, Ht as WriteData, I as LinksFail, It as UdpSocketOptions, J as Placement, K as PackagesFail, L as ListedLink, Lt as UdpSocketResult, M as LinkCreateWire, Mt as TcpSocketListenerResult, N as LinkHandle, Nt as TcpSocketOptions, O as JAR_ANCHOR_MESSAGE, Ot as StorageEntry, P as LinkProgress, Pt as TcpSocketResult, Q as Quota, R as MiddleControl, Rt as WINDOW_HANDSHAKE_TIMEOUT_MS, S as FrameFetchScope, St as SHELL_JAR_UNREACHABLE, T as InstallOptions, Tt as ShellFrameMessage, U as PackageQuery, Ut as JarSeed, V as OverlayRect, Vt as WindowMiddleControl, W as PackageResult, Wt as JarSeedCookie, X as ProxyFetchInit, Y as ProxyFetch, Z as ProxyFetchInput, _ as DnsLookup, _t as RoomsFail, a as AccountChange, at as RoomDefaults, b as FrameConsentAnswer, bt as SHELL_FRAME_MESSAGE, c as AdoptRequest, ct as RoomHandle, d as ConflictRequest, dt as RoomMember, et as Radii, f as ConflictSide, ft as RoomMessage, g as DisplayLevel, gt as RoomsErrorCode, h as DisplayCause, ht as RoomPermissions, i as Account, it as RoomCreateOptions, j as LinkCreateOptions, jt as TcpSocketListenerOptions, k as LINK_EXPIRES_MS, kt as StorageQuota, l as AdoptState, lt as RoomJoinOptions, m as ConnectOptions, mt as RoomPermission, n as ATTACH_WINDOW_KEY, nt as RoomBacklog, o as AccountPinOptions, ot as RoomEnd, p as ConnectAvailability, pt as RoomOpenOptions, q as PickOptions, r as ATTACH_WINDOW_MESSAGE, rt as RoomClaimOptions, s as AddressLookupResult, st as RoomEvent, t as ATTACH_FRAME_KEY, tt as Resolvers, u as ConflictChoice, ut as RoomMailbox, v as EncryptionState, vt as SHELL_ATTACH_ERROR, w as HiddenSurface, wt as ShellControl, x as FrameConsentRequest, xt as SHELL_JAR_MESSAGE, y as FRAME_MESSAGE, yt as SHELL_CONTROL_KEY, z as MiddleGotoOptions, zt as WINDOW_HELLO_TIMEOUT_MS } from "./contract-XlEPwc7b.js";
2
+ import { $ as RoomHandle, A as MiddleGotoOptions, At as SurfaceRect, B as ProxyFetch, Bt as WINDOW_JAR_MODE_TIMEOUT_MS, C as FrameMessageRelay, Ct as StorageProgress, D as IpFamily, Dt as StoredHandle, E as InstalledPackage, Et as StorageQuota, F as PackageResult, Ft as UdpDatagram, G as Radii, H as ProxyFetchInput, Ht as WriteData, I as PackagesErrorCode, It as UdpSocketOptions, J as RoomClaimOptions, K as Resolvers, L as PackagesFail, Lt as UdpSocketResult, M as OverlayRect, Mt as TcpSocketListenerResult, N as OverlayState, Nt as TcpSocketOptions, O as JAR_ANCHOR_MESSAGE, Ot as StoredObject, P as PackageQuery, Pt as TcpSocketResult, Q as RoomEvent, R as PickOptions, Rt as WINDOW_HANDSHAKE_TIMEOUT_MS, S as FrameFetchScope, St as StorageFail, T as InstallOptions, Tt as StoragePutWire, U as Quota, Ut as JarSeed, V as ProxyFetchInit, Vt as WindowMiddleControl, W as ROOM_TEMPORARY_MS, Wt as JarSeedCookie, X as RoomDefaults, Y as RoomCreateOptions, Z as RoomEnd, _ as DnsLookup, _t as ShellFrameMessage, a as AccountChange, at as RoomPermission, b as FrameConsentAnswer, bt as StorageEntry, c as AdoptRequest, ct as RoomsFail, d as ConflictRequest, dt as SHELL_FRAME_MESSAGE, et as RoomJoinOptions, f as ConflictSide, ft as SHELL_JAR_MESSAGE, g as DisplayLevel, gt as ShellControl, h as DisplayCause, ht as SetOverlayHost, i as Account, it as RoomOpenOptions, j as MountDescriptor, jt as TcpSocketListenerOptions, k as MiddleControl, kt as StoredPage, l as AdoptState, lt as SHELL_ATTACH_ERROR, m as ConnectOptions, mt as STORAGE_REFUSALS, n as ATTACH_WINDOW_KEY, nt as RoomMember, o as AccountPinOptions, ot as RoomPermissions, p as ConnectAvailability, pt as SHELL_JAR_UNREACHABLE, q as RoomBacklog, r as ATTACH_WINDOW_MESSAGE, rt as RoomMessage, s as AddressLookupResult, st as RoomsErrorCode, t as ATTACH_FRAME_KEY, tt as RoomMailbox, u as ConflictChoice, ut as SHELL_CONTROL_KEY, v as EncryptionState, vt as ShellGotoOptions, w as HiddenSurface, wt as StoragePutOptions, x as FrameConsentRequest, xt as StorageErrorCode, y as FRAME_MESSAGE, yt as ShellJarUnreachable, z as Placement, zt as WINDOW_HELLO_TIMEOUT_MS } from "./contract-DGuGXxKd.js";
3
3
  import { o as TcpSocketOption, x as UdpSocketOption } from "./wire-Fk5pJaoy.js";
4
- export { ATTACH_FRAME_KEY, ATTACH_WINDOW_KEY, ATTACH_WINDOW_MESSAGE, Account, AccountChange, AccountPinOptions, AddressLookupResult, AdoptRequest, AdoptState, type ClearCookiesWire, ConflictChoice, ConflictRequest, ConflictSide, ConnectAvailability, ConnectOptions, type CookieMatchWire, DisplayCause, DisplayLevel, DnsLookup, EncryptionState, FRAME_MESSAGE, FrameConsentAnswer, FrameConsentRequest, FrameFetchScope, FrameMessageRelay, HiddenSurface, InstallOptions, InstalledPackage, IpFamily, JAR_ANCHOR_MESSAGE, type JarSeed, type JarSeedCookie, LINK_EXPIRES_MS, Link, LinkCreateOptions, LinkCreateWire, LinkHandle, LinkProgress, LinksErrorCode, LinksFail, ListedLink, MiddleControl, MiddleGotoOptions, MountDescriptor, OverlayRect, OverlayState, PackageQuery, PackageResult, PackagesErrorCode, PackagesFail, PickOptions, Placement, ProxyFetch, ProxyFetchInit, ProxyFetchInput, Quota, ROOM_TEMPORARY_MS, Radii, Resolvers, RoomBacklog, RoomClaimOptions, RoomCreateOptions, RoomDefaults, RoomEnd, RoomEvent, RoomHandle, RoomJoinOptions, RoomMailbox, RoomMember, RoomMessage, RoomOpenOptions, RoomPermission, RoomPermissions, RoomsErrorCode, RoomsFail, SHELL_ATTACH_ERROR, SHELL_CONTROL_KEY, SHELL_FRAME_MESSAGE, SHELL_JAR_MESSAGE, SHELL_JAR_UNREACHABLE, SetOverlayHost, ShellControl, ShellFrameMessage, ShellGotoOptions, ShellJarUnreachable, StorageEntry, StorageQuota, SurfaceRect, TcpSocketListenerOptions, TcpSocketListenerResult, type TcpSocketOption, TcpSocketOptions, TcpSocketResult, UdpDatagram, type UdpSocketOption, UdpSocketOptions, UdpSocketResult, WINDOW_HANDSHAKE_TIMEOUT_MS, WINDOW_HELLO_TIMEOUT_MS, WINDOW_JAR_MODE_TIMEOUT_MS, WindowMiddleControl, WriteData };
4
+ export { ATTACH_FRAME_KEY, ATTACH_WINDOW_KEY, ATTACH_WINDOW_MESSAGE, Account, AccountChange, AccountPinOptions, AddressLookupResult, AdoptRequest, AdoptState, type ClearCookiesWire, ConflictChoice, ConflictRequest, ConflictSide, ConnectAvailability, ConnectOptions, type CookieMatchWire, DisplayCause, DisplayLevel, DnsLookup, EncryptionState, FRAME_MESSAGE, FrameConsentAnswer, FrameConsentRequest, FrameFetchScope, FrameMessageRelay, HiddenSurface, InstallOptions, InstalledPackage, IpFamily, JAR_ANCHOR_MESSAGE, type JarSeed, type JarSeedCookie, MiddleControl, MiddleGotoOptions, MountDescriptor, OverlayRect, OverlayState, PackageQuery, PackageResult, PackagesErrorCode, PackagesFail, PickOptions, Placement, ProxyFetch, ProxyFetchInit, ProxyFetchInput, Quota, ROOM_TEMPORARY_MS, Radii, Resolvers, RoomBacklog, RoomClaimOptions, RoomCreateOptions, RoomDefaults, RoomEnd, RoomEvent, RoomHandle, RoomJoinOptions, RoomMailbox, RoomMember, RoomMessage, RoomOpenOptions, RoomPermission, RoomPermissions, RoomsErrorCode, RoomsFail, SHELL_ATTACH_ERROR, SHELL_CONTROL_KEY, SHELL_FRAME_MESSAGE, SHELL_JAR_MESSAGE, SHELL_JAR_UNREACHABLE, STORAGE_REFUSALS, SetOverlayHost, ShellControl, ShellFrameMessage, ShellGotoOptions, ShellJarUnreachable, StorageEntry, StorageErrorCode, StorageFail, StorageProgress, StoragePutOptions, StoragePutWire, StorageQuota, StoredHandle, StoredObject, StoredPage, SurfaceRect, TcpSocketListenerOptions, TcpSocketListenerResult, type TcpSocketOption, TcpSocketOptions, TcpSocketResult, UdpDatagram, type UdpSocketOption, UdpSocketOptions, UdpSocketResult, WINDOW_HANDSHAKE_TIMEOUT_MS, WINDOW_HELLO_TIMEOUT_MS, WINDOW_JAR_MODE_TIMEOUT_MS, WindowMiddleControl, WriteData };
package/contract.js CHANGED
@@ -28,8 +28,74 @@ var e = "fkn-attach-frame", t = "fkn-attach-window", n = "sdbx-control", r = "sd
28
28
  min: 6e4,
29
29
  max: 31536e6
30
30
  }, m = {
31
- min: 6e4,
32
- max: 31536e6
31
+ notAFile: {
32
+ code: "invalid",
33
+ message: "storage: the data is not a Blob or a ReadableStream"
34
+ },
35
+ badSize: {
36
+ code: "invalid",
37
+ message: "storage: a stream needs the size it will deliver, a whole number of bytes"
38
+ },
39
+ shortStream: {
40
+ code: "invalid",
41
+ message: "storage: the stream did not deliver the size it declared"
42
+ },
43
+ tooLarge: {
44
+ code: "invalid",
45
+ message: "storage: the file is too large to store"
46
+ },
47
+ badKey: {
48
+ code: "invalid",
49
+ message: "storage: the key is not 32 bytes base64url"
50
+ },
51
+ badUrl: {
52
+ code: "invalid",
53
+ message: "storage: the url does not name a stored object"
54
+ },
55
+ badLimit: {
56
+ code: "invalid",
57
+ message: "storage: the limit is out of range"
58
+ },
59
+ badCursor: {
60
+ code: "invalid",
61
+ message: "storage: the cursor is not one list answered"
62
+ },
63
+ notFound: {
64
+ code: "not-found",
65
+ message: "storage: no object at this url"
66
+ },
67
+ integrity: {
68
+ code: "integrity",
69
+ message: "storage: the object does not match its key"
70
+ },
71
+ needsAccount: {
72
+ code: "denied",
73
+ message: "storage: storing needs an account"
74
+ },
75
+ notCreator: {
76
+ code: "denied",
77
+ message: "storage: only the app that stored the object can delete it"
78
+ },
79
+ quota: {
80
+ code: "quota",
81
+ message: "storage: storage quota exceeded"
82
+ },
83
+ tooMany: {
84
+ code: "too-many",
85
+ message: "storage: too many stored objects"
86
+ },
87
+ tooManyThisHour: {
88
+ code: "too-many",
89
+ message: "storage: too many objects stored this hour, try again later"
90
+ },
91
+ accountChanged: {
92
+ code: "account-changed",
93
+ message: "storage: the signed-in account changed"
94
+ },
95
+ unavailable: {
96
+ code: "unavailable",
97
+ message: "storage: storage is unavailable"
98
+ }
33
99
  };
34
100
  //#endregion
35
- export { e as ATTACH_FRAME_KEY, t as ATTACH_WINDOW_KEY, o as ATTACH_WINDOW_MESSAGE, i as FRAME_MESSAGE, l as JAR_ANCHOR_MESSAGE, m as LINK_EXPIRES_MS, p as ROOM_TEMPORARY_MS, r as SHELL_ATTACH_ERROR, n as SHELL_CONTROL_KEY, a as SHELL_FRAME_MESSAGE, s as SHELL_JAR_MESSAGE, c as SHELL_JAR_UNREACHABLE, f as WINDOW_HANDSHAKE_TIMEOUT_MS, u as WINDOW_HELLO_TIMEOUT_MS, d as WINDOW_JAR_MODE_TIMEOUT_MS };
101
+ export { e as ATTACH_FRAME_KEY, t as ATTACH_WINDOW_KEY, o as ATTACH_WINDOW_MESSAGE, i as FRAME_MESSAGE, l as JAR_ANCHOR_MESSAGE, p as ROOM_TEMPORARY_MS, r as SHELL_ATTACH_ERROR, n as SHELL_CONTROL_KEY, a as SHELL_FRAME_MESSAGE, s as SHELL_JAR_MESSAGE, c as SHELL_JAR_UNREACHABLE, m as STORAGE_REFUSALS, f as WINDOW_HANDSHAKE_TIMEOUT_MS, u as WINDOW_HELLO_TIMEOUT_MS, d as WINDOW_JAR_MODE_TIMEOUT_MS };
package/dgram.d.ts CHANGED
@@ -1,6 +1,6 @@
1
- import { Lt as UdpSocketResult, tt as Resolvers } from "./contract-XlEPwc7b.js";
1
+ import { K as Resolvers, Lt as UdpSocketResult } from "./contract-DGuGXxKd.js";
2
2
  import { x as UdpSocketOption } from "./wire-Fk5pJaoy.js";
3
- import "./api-Cpi-qz1j.js";
3
+ import "./api-wnOQJEK6.js";
4
4
  import { Buffer } from "buffer";
5
5
  import { AddressInfo } from "net";
6
6
  import { EventEmitter } from "events";
package/dns.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { s as AddressLookupResult } from "./contract-XlEPwc7b.js";
1
+ import { s as AddressLookupResult } from "./contract-DGuGXxKd.js";
2
2
  declare namespace dns_d_exports {
3
3
  export { AddressLookupResult, lookup };
4
4
  }
package/fs/promises.cjs CHANGED
@@ -1 +1 @@
1
- Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../fs-DnF1cQuE.cjs");var{readFile:t,writeFile:n,appendFile:r,unlink:i,rename:a,readdir:o,mkdir:s,rm:c,rmdir:l,stat:u,lstat:d,access:f}=e.v,p=e.v;exports.access=f,exports.appendFile=r,exports.default=p,exports.lstat=d,exports.mkdir=s,exports.readFile=t,exports.readdir=o,exports.rename=a,exports.rm=c,exports.rmdir=l,exports.stat=u,exports.unlink=i,exports.writeFile=n;
1
+ Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("../fs-zERmcLRS.cjs");var{readFile:t,writeFile:n,appendFile:r,unlink:i,rename:a,readdir:o,mkdir:s,rm:c,rmdir:l,stat:u,lstat:d,access:f}=e.v,p=e.v;exports.access=f,exports.appendFile=r,exports.default=p,exports.lstat=d,exports.mkdir=s,exports.readFile=t,exports.readdir=o,exports.rename=a,exports.rm=c,exports.rmdir=l,exports.stat=u,exports.unlink=i,exports.writeFile=n;
package/fs/promises.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { a as WriteData, i as Stats, n as MakeOptions, o as WriteOptions, r as ReadOptions } from "../index-BQgZVQl7.js";
2
- import { v as promises } from "../index-D9x6A-Gx.js";
2
+ import { v as promises } from "../index-DawD_N1P.js";
3
3
  //#region src/fs/promises.d.ts
4
4
  export declare const readFile: (path: import("node:fs").PathLike, options?: ReadOptions) => Promise<Buffer | string>, writeFile: (path: import("node:fs").PathLike, data: WriteData, options?: WriteOptions) => Promise<void>, appendFile: (path: import("node:fs").PathLike, data: WriteData, options?: WriteOptions) => Promise<void>, unlink: (path: import("node:fs").PathLike) => Promise<void>, rename: (from: import("node:fs").PathLike, to: import("node:fs").PathLike) => Promise<void>, readdir: (path: import("node:fs").PathLike) => Promise<string[]>, mkdir: (path: import("node:fs").PathLike, options?: MakeOptions) => Promise<void>, rm: (path: import("node:fs").PathLike, options?: {
5
5
  recursive?: boolean;
package/fs/promises.js CHANGED
@@ -1,4 +1,4 @@
1
- import { v as e } from "../fs-BY0Csn2V.js";
1
+ import { v as e } from "../fs-ClnOPmRF.js";
2
2
  //#region src/fs/promises.ts
3
3
  var { readFile: t, writeFile: n, appendFile: r, unlink: i, rename: a, readdir: o, mkdir: s, rm: c, rmdir: l, stat: u, lstat: d, access: f } = e, p = e;
4
4
  //#endregion
@@ -1,6 +1,6 @@
1
1
  import { a as WriteData, i as Stats, n as MakeOptions, o as WriteOptions, r as ReadOptions, t as Callback } from "./index-BQgZVQl7.js";
2
- import { _ as unlock, a as StorageAccountChangedError, c as StorageNotFoundError, f as encryption, g as storage_d_exports, h as quota, i as SealedRead, l as StorageQuota, m as isNotFound, n as EncryptionStatus, o as StorageAccountPinUnsupportedError, p as isAccountChanged, r as FileEntry, s as StorageLockedError, t as CloudAvailability, u as availability } from "./storage-B_mXNAdB.js";
3
- import { c as STORAGE_ACCOUNT_CHANGED, l as STORAGE_ACCOUNT_PIN_UNSUPPORTED, u as STORAGE_NOT_FOUND } from "./messages-d7pvCXPn.js";
2
+ import { _ as unlock, a as StorageAccountChangedError, c as StorageNotFoundError, d as availability, g as quota, h as isNotFound, i as SealedRead, l as StorageQuota, m as isAccountChanged, n as EncryptionStatus, o as StorageAccountPinUnsupportedError, p as encryption, r as FileEntry, s as StorageLockedError, t as CloudAvailability, u as account_storage_d_exports } from "./account-storage-DHl6bXdb.js";
3
+ import { c as STORAGE_ACCOUNT_CHANGED, l as STORAGE_ACCOUNT_PIN_UNSUPPORTED, u as STORAGE_NOT_FOUND } from "./messages-AdPfdoLV.js";
4
4
  declare namespace fs_d_exports {
5
5
  export { CloudAvailability, EncryptionStatus, FileEntry, STORAGE_ACCOUNT_CHANGED, STORAGE_ACCOUNT_PIN_UNSUPPORTED, STORAGE_NOT_FOUND, SealedRead, Stats, StorageAccountChangedError, StorageAccountPinUnsupportedError, StorageLockedError, StorageNotFoundError, StorageQuota, availability, available, encryption, isAccountChanged, isNotFound, list, mkdir, promises, quota, readFile, readFileSealed, readdir, rename, rm, stat, unlink, unlock, writeFile };
6
6
  }
@@ -3,7 +3,7 @@ import { o as t, u as n } from "./api-ySazPAwN.js";
3
3
  import { i as r } from "./busy-DsMWrSzc.js";
4
4
  import { t as i } from "./node-fs-DY2fO5zd.js";
5
5
  import { STORAGE_ACCOUNT_CHANGED as a, STORAGE_ACCOUNT_PIN_UNSUPPORTED as o } from "./messages.js";
6
- import { _ as s, a as c, b as l, c as u, d as ee, f as d, g as te, h as f, l as ne, n as re, o as p, p as ie, t as ae } from "./storage-C6F9SnDM.js";
6
+ import { _ as s, b as c, f as l, g as u, l as d, m as ee, n as te, o as ne, p as f, s as p, t as re, u as ie, v as ae } from "./account-storage-C31d68BN.js";
7
7
  import { onChange as oe } from "./account.js";
8
8
  import { a as se, i as m, n as h, o as g, t as ce } from "./opfs-D0goLAQW.js";
9
9
  //#region src/fs/hybrid.ts
@@ -22,10 +22,10 @@ var le = /* @__PURE__ */ e({
22
22
  remove: () => Fe,
23
23
  replicating: () => Ee,
24
24
  writeFile: () => Pe
25
- }), ue = p, de, _ = async () => await (de ??= ce().catch(() => !1)) ? !0 : (de = void 0, !1), v = () => c().catch(() => "unknown"), y = async () => await v() === "connected", fe = async () => await _() || await y(), pe = "fkn:fs:pending", me = "fkn:fs:pending-delete", he = "fkn:fs:adopt-declined", b = !0, ge = /* @__PURE__ */ new Map(), _e = null, ve = (e, t) => {
25
+ }), ue = p, de, _ = async () => await (de ??= ce().catch(() => !1)) ? !0 : (de = void 0, !1), v = () => ne().catch(() => "unknown"), y = async () => await v() === "connected", fe = async () => await _() || await y(), pe = "fkn:fs:pending", me = "fkn:fs:pending-delete", he = "fkn:fs:adopt-declined", b = !0, ge = /* @__PURE__ */ new Map(), _e = null, ve = (e, t) => {
26
26
  if (e === null) return !1;
27
27
  if ("generation" in e && "generation" in t) return e.generation === t.generation;
28
- let n = (e) => "pin" in e ? e.pin : ee(e), r = n(e);
28
+ let n = (e) => "pin" in e ? e.pin : l(e), r = n(e);
29
29
  return r !== void 0 && r === n(t);
30
30
  }, x = (e, t) => ve(_e, t) ? ge.get(e) ?? null : null, S = (e) => e === "write" ? pe : me, C = (e) => {
31
31
  try {
@@ -64,7 +64,7 @@ var le = /* @__PURE__ */ e({
64
64
  } catch {
65
65
  return {};
66
66
  }
67
- }, T = /* @__PURE__ */ new Map(), be = (e) => "pin" in e ? e.pin : ee(e) ?? null, xe = (e, t, n, r) => {
67
+ }, T = /* @__PURE__ */ new Map(), be = (e) => "pin" in e ? e.pin : l(e) ?? null, xe = (e, t, n, r) => {
68
68
  let i = C(e), a = i[t], o = be(r);
69
69
  a && o !== null && a.pin === o || (i[t] = {
70
70
  base: a ? a.base : n,
@@ -101,13 +101,13 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
101
101
  }, je = async (e) => {
102
102
  let t = e?.pin ?? p();
103
103
  q();
104
- let n = await v(), r = n === "connected", [i, a] = await Promise.all([_().then((e) => e ? h() : []).catch(() => []), r ? d({ pin: t }).then((e) => ({
104
+ let n = await v(), r = n === "connected", [i, a] = await Promise.all([_().then((e) => e ? h() : []).catch(() => []), r ? f({ pin: t }).then((e) => ({
105
105
  ok: !0,
106
106
  entries: e
107
107
  }), (e) => ({
108
108
  ok: !1,
109
109
  entries: [],
110
- changed: u(e) ? e : void 0
110
+ changed: d(e) ? e : void 0
111
111
  })) : Promise.resolve({
112
112
  ok: n === "disconnected",
113
113
  entries: []
@@ -134,7 +134,7 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
134
134
  } catch (e) {
135
135
  if (e?.name !== "NotFoundError") throw e;
136
136
  }
137
- let r = await f(e, { pin: n });
137
+ let r = await u(e, { pin: n });
138
138
  return await _() && g(e, r).catch(() => {}), r;
139
139
  }, Ne = async (e, t) => {
140
140
  let n = t?.pin ?? p();
@@ -147,7 +147,7 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
147
147
  } catch (e) {
148
148
  if (e?.name !== "NotFoundError") throw e;
149
149
  }
150
- return te(e, { pin: n });
150
+ return s(e, { pin: n });
151
151
  }, Pe = async (e, t, n) => {
152
152
  let r = n?.pin ?? p(), i = n?.contentType, a = i ? { contentType: i } : void 0, o = t instanceof Blob ? t : new Blob([t], a ? { type: a.contentType } : void 0);
153
153
  if (await _()) {
@@ -158,16 +158,16 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
158
158
  E(e, t, r), I();
159
159
  return;
160
160
  }
161
- l(e, o, {
161
+ c(e, o, {
162
162
  ...a,
163
163
  pin: r
164
164
  }).then(() => D(e)).catch((n) => {
165
- E(e, t, r), u(n) || I(), console.warn("fs: cloud replicate failed, queued for adopt()", n);
165
+ E(e, t, r), d(n) || I(), console.warn("fs: cloud replicate failed, queued for adopt()", n);
166
166
  });
167
167
  return;
168
168
  }
169
169
  let s = await v();
170
- if (s === "connected") return l(e, o, {
170
+ if (s === "connected") return c(e, o, {
171
171
  ...a,
172
172
  pin: r
173
173
  });
@@ -178,12 +178,12 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
178
178
  let r = [];
179
179
  await _() && r.push(se(e).catch(() => {}));
180
180
  let i = await v();
181
- if (i === "connected" ? r.push(s(e, { pin: n }).then(() => O(e)).catch((t) => {
182
- Ce(e, n), u(t) || I(), console.warn("fs: cloud delete failed, queued for retry", t);
181
+ if (i === "connected" ? r.push(ae(e, { pin: n }).then(() => O(e)).catch((t) => {
182
+ Ce(e, n), d(t) || I(), console.warn("fs: cloud delete failed, queued for retry", t);
183
183
  })) : i === "unknown" && r.length && x(e, n) !== null && (Ce(e, n), I()), !r.length) throw Error(i === "unknown" ? "fs: cloud unreachable" : "fs: no storage backend available");
184
184
  D(e), await Promise.all(r);
185
185
  }, Ie = async (e) => {
186
- let t = p(), n = await f(e, { pin: t });
186
+ let t = p(), n = await u(e, { pin: t });
187
187
  return await _() && await g(e, n), n;
188
188
  }, R = null, Le = (e) => (R = e, () => {
189
189
  R === e && (R = null);
@@ -216,9 +216,9 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
216
216
  for (let [e, t] of [...T]) {
217
217
  let n = e.startsWith("write:") ? "write" : "delete", r = e.slice(n.length + 1), i;
218
218
  try {
219
- i = await ie(t);
219
+ i = await ee(t);
220
220
  } catch (t) {
221
- u(t) && T.delete(e);
221
+ d(t) && T.delete(e);
222
222
  continue;
223
223
  }
224
224
  if (T.get(e) !== t) continue;
@@ -230,8 +230,8 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
230
230
  }, w(n, a));
231
231
  }
232
232
  }, He = async (e, t, n, r, i, a) => {
233
- let o = new Map(t.map((e) => [e.path, e])), c = (e) => {
234
- if (u(e)) throw new z();
233
+ let o = new Map(t.map((e) => [e.path, e])), s = (e) => {
234
+ if (d(e)) throw new z();
235
235
  };
236
236
  for (let [t, a] of e.deletes) {
237
237
  let e = o.get(t);
@@ -248,25 +248,25 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
248
248
  continue;
249
249
  }
250
250
  try {
251
- await s(t, n), O(t), i.deleted.push(t);
251
+ await ae(t, n), O(t), i.deleted.push(t);
252
252
  } catch (e) {
253
- c(e), i.failed.push({
253
+ s(e), i.failed.push({
254
254
  path: t,
255
255
  error: B(e)
256
256
  });
257
257
  }
258
258
  }
259
259
  for (let t of r) {
260
- let r = o.get(t.path), s = e.writes.has(t.path);
261
- if (!s) {
260
+ let r = o.get(t.path), l = e.writes.has(t.path);
261
+ if (!l) {
262
262
  if (!a(t)) continue;
263
263
  if (r) {
264
264
  i.kept.push(t.path);
265
265
  continue;
266
266
  }
267
267
  }
268
- let u = e.writes.get(t.path) ?? null;
269
- if (s && r && r.updatedAt !== u) {
268
+ let d = e.writes.get(t.path) ?? null;
269
+ if (l && r && r.updatedAt !== d) {
270
270
  let e = null, a = null, o = await ze({
271
271
  path: t.path,
272
272
  local: {
@@ -278,7 +278,7 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
278
278
  updatedAt: r.updatedAt
279
279
  },
280
280
  readLocal: () => e ??= m(t.path),
281
- readCloud: () => a ??= f(t.path, n)
281
+ readCloud: () => a ??= u(t.path, n)
282
282
  });
283
283
  if (o == null) {
284
284
  i.unresolved.push(t.path);
@@ -286,7 +286,7 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
286
286
  }
287
287
  try {
288
288
  let r = e !== null && o === await e, s = a !== null && o === await a;
289
- s || await l(t.path, o, t.contentType ? {
289
+ s || await c(t.path, o, t.contentType ? {
290
290
  contentType: t.contentType,
291
291
  ...n
292
292
  } : n), r || await g(t.path, o), D(t.path), i.resolved.push({
@@ -294,7 +294,7 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
294
294
  choice: r ? "local" : s ? "cloud" : "merged"
295
295
  });
296
296
  } catch (e) {
297
- if (c(e), e?.code === "FKN_E2E_LOCKED") throw e;
297
+ if (s(e), e?.code === "FKN_E2E_LOCKED") throw e;
298
298
  i.failed.push({
299
299
  path: t.path,
300
300
  error: B(e)
@@ -304,12 +304,12 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
304
304
  }
305
305
  try {
306
306
  let e = await m(t.path);
307
- await l(t.path, e, t.contentType ? {
307
+ await c(t.path, e, t.contentType ? {
308
308
  contentType: t.contentType,
309
309
  ...n
310
310
  } : n), D(t.path), i.uploaded.push(t.path);
311
311
  } catch (e) {
312
- if (s || E(t.path, r?.updatedAt ?? null, n.pin), c(e), e?.code === "FKN_E2E_LOCKED") throw e;
312
+ if (l || E(t.path, r?.updatedAt ?? null, n.pin), s(e), e?.code === "FKN_E2E_LOCKED") throw e;
313
313
  i.failed.push({
314
314
  path: t.path,
315
315
  error: B(e)
@@ -334,13 +334,13 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
334
334
  if (e === null || De(e)) continue;
335
335
  let i = { pin: { pin: e } }, o;
336
336
  try {
337
- o = await d(i);
337
+ o = await f(i);
338
338
  } catch (n) {
339
- if (u(n)) {
339
+ if (d(n)) {
340
340
  k.set(e, t.generation);
341
341
  continue;
342
342
  }
343
- if (ne(n)) {
343
+ if (ie(n)) {
344
344
  We(e);
345
345
  continue;
346
346
  }
@@ -354,7 +354,7 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
354
354
  }
355
355
  }
356
356
  if (e) {
357
- let e = { pin: t }, r = await d(e), i = C("write"), o = Be().get(null) ?? {
357
+ let e = { pin: t }, r = await f(e), i = C("write"), o = Be().get(null) ?? {
358
358
  writes: /* @__PURE__ */ new Map(),
359
359
  deletes: /* @__PURE__ */ new Map()
360
360
  }, s = /* @__PURE__ */ new Set([
@@ -366,7 +366,7 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
366
366
  try {
367
367
  await He(o, r, e, a, n, c);
368
368
  } catch (e) {
369
- throw e instanceof z ? new ae() : e;
369
+ throw e instanceof z ? new re() : e;
370
370
  }
371
371
  }
372
372
  return n;
@@ -397,7 +397,7 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
397
397
  paths: [],
398
398
  bytes: 0
399
399
  };
400
- let [t, n] = await Promise.all([h(), d({ pin: e })]), r = H(t, n);
400
+ let [t, n] = await Promise.all([h(), f({ pin: e })]), r = H(t, n);
401
401
  return {
402
402
  paths: r.map((e) => e.path),
403
403
  bytes: r.reduce((e, t) => e + t.size, 0)
@@ -415,7 +415,7 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
415
415
  if (!await y()) return;
416
416
  let r = e ?? (await _() ? {
417
417
  local: await h(),
418
- remote: await d({ pin: n })
418
+ remote: await f({ pin: n })
419
419
  } : null);
420
420
  if (!r) return;
421
421
  let i = Ke(), a = H(r.local, r.remote).filter((e) => !i.has(e.path));
@@ -461,8 +461,8 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
461
461
  }, Qe = /* @__PURE__ */ e({
462
462
  STORAGE_ACCOUNT_CHANGED: () => a,
463
463
  STORAGE_ACCOUNT_PIN_UNSUPPORTED: () => o,
464
- StorageAccountChangedError: () => ae,
465
- StorageAccountPinUnsupportedError: () => re,
464
+ StorageAccountChangedError: () => re,
465
+ StorageAccountPinUnsupportedError: () => te,
466
466
  adopt: () => X,
467
467
  adoptable: () => Z,
468
468
  appendFile: () => ht,
@@ -472,7 +472,7 @@ var M = () => ["write", "delete"].some((e) => Object.entries(C(e)).some(([t, n])
472
472
  exists: () => St,
473
473
  existsSync: () => it,
474
474
  flush: () => Tt,
475
- isAccountChanged: () => u,
475
+ isAccountChanged: () => d,
476
476
  lstatSync: () => ot,
477
477
  mkdir: () => vt,
478
478
  mkdirSync: () => ct,
@@ -0,0 +1 @@
1
+ const e=require("./rolldown-runtime-BIInC43l.cjs"),t=require("./api-DMnVye0K.cjs"),n=require("./busy-BXbVH595.cjs"),r=require("./node-fs-vsWuoMGa.cjs"),i=require("./messages.cjs"),a=require("./account-storage-C6hcXjG0.cjs"),o=require("./account.cjs"),s=require("./opfs-CXMESVLc.cjs");var c=e.t({adopt:()=>L,adoptable:()=>z,available:()=>ee,captureAccount:()=>l,list:()=>ye,onConflict:()=>Ce,pending:()=>fe,pendingDeletes:()=>pe,pull:()=>N,readFile:()=>be,readFileSealed:()=>M,remove:()=>Se,replicating:()=>me,writeFile:()=>xe}),l=a.s,u,d=async()=>await(u??=s.t().catch(()=>!1))?!0:(u=void 0,!1),f=()=>a.o().catch(()=>`unknown`),p=async()=>await f()===`connected`,ee=async()=>await d()||await p(),te=`fkn:fs:pending`,ne=`fkn:fs:pending-delete`,re=`fkn:fs:adopt-declined`,m=!0,ie=new Map,ae=null,oe=(e,t)=>{if(e===null)return!1;if(`generation`in e&&`generation`in t)return e.generation===t.generation;let n=e=>`pin`in e?e.pin:a.f(e),r=n(e);return r!==void 0&&r===n(t)},h=(e,t)=>oe(ae,t)?ie.get(e)??null:null,g=e=>e===`write`?te:ne,_=e=>{try{let t=localStorage.getItem(g(e));if(!t)return{};let n=JSON.parse(t);if(Array.isArray(n))return Object.fromEntries(n.filter(e=>typeof e==`string`).map(e=>[e,{base:null,pin:null}]));if(!n||typeof n!=`object`)return{};let r={};for(let[e,t]of Object.entries(n))if(t===null||typeof t==`string`)r[e]={base:t,pin:null};else if(typeof t==`object`){let{base:n,pin:i}=t;r[e]={base:typeof n==`string`?n:null,pin:typeof i==`string`&&i?i:null}}return r}catch{return{}}},v=(e,t)=>{try{Object.keys(t).length?localStorage.setItem(g(e),JSON.stringify(t)):localStorage.removeItem(g(e))}catch{}},se=()=>{try{let e=JSON.parse(localStorage.getItem(re)??`{}`);return e&&typeof e==`object`&&!Array.isArray(e)?e:{}}catch{return{}}},y=new Map,ce=e=>`pin`in e?e.pin:a.f(e)??null,le=(e,t,n,r)=>{let i=_(e),a=i[t],o=ce(r);a&&o!==null&&a.pin===o||(i[t]={base:a?a.base:n,pin:o},v(e,i),o===null&&`generation`in r?y.set(`${e}:${t}`,r):y.delete(`${e}:${t}`))},ue=(e,t)=>{y.delete(`${e}:${t}`);let n=_(e);t in n&&(delete n[t],v(e,n),E()||(O=D))},b=(e,t,n)=>le(`write`,e,t,n),x=e=>ue(`write`,e),de=(e,t)=>le(`delete`,e,h(e,t),t),S=e=>ue(`delete`,e),fe=()=>Object.keys(_(`write`)),pe=()=>Object.keys(_(`delete`)),me=()=>m,C=new Map,he=e=>C.get(e)===a.s().generation,ge=(e,t,n)=>n.pin===null&&!y.has(`${e}:${t}`),w=null,T=!1;n.i(`storage replication`,()=>w!==null||B!==null);var E=()=>[`write`,`delete`].some(e=>Object.entries(_(e)).some(([t,n])=>n.pin===null?!ge(e,t,n):!he(n.pin))),D=6e4,_e=6e5,O=D,k=null,A=()=>{!k&&typeof window<`u`&&E()&&(k=setTimeout(()=>{k=null,j()},O),O=Math.min(O*2,_e))},j=()=>{if(w){T=!0;return}E()&&(w=ke(!1,a.s()).then(e=>{if(!E()){O=D;return}e.failed.length&&A()}).catch(()=>{A()}).finally(()=>{w=null,ve()}))},ve=()=>{T&&(T=!1,j())},ye=async e=>{let t=e?.pin??a.s();U();let n=await f(),r=n===`connected`,[i,o]=await Promise.all([d().then(e=>e?s.n():[]).catch(()=>[]),r?a.p({pin:t}).then(e=>({ok:!0,entries:e}),e=>({ok:!1,entries:[],changed:a.l(e)?e:void 0})):Promise.resolve({ok:n===`disconnected`,entries:[]})]);if(n!==`unknown`&&(m=o.ok),o.ok&&n!==`unknown`&&(ie=new Map(o.entries.map(e=>[e.path,e.updatedAt])),ae=t),o.changed)throw o.changed;let c=new Map,l=e=>{let t=Date.parse(e.updatedAt??``);return Number.isFinite(t)?t:0},u=e=>{let t=c.get(e.path);(!t||l(e)>=l(t))&&c.set(e.path,e)};for(let e of i)u(e);for(let e of o.entries)u(e);return o.ok&&r&&(Ie(i,o.entries).catch(()=>{}),E()?j():H({local:i,remote:o.entries,from:t}).catch(()=>{})),[...c.values()]},be=async(e,t)=>{let n=t?.pin??a.s();if(await d())try{return await s.i(e)}catch(e){if(e?.name!==`NotFoundError`)throw e}let r=await a.g(e,{pin:n});return await d()&&s.o(e,r).catch(()=>{}),r},M=async(e,t)=>{let n=t?.pin??a.s();if(await d())try{let t=await s.i(e);return{data:new Uint8Array(await t.arrayBuffer()),sealedAt:null}}catch(e){if(e?.name!==`NotFoundError`)throw e}return a._(e,{pin:n})},xe=async(e,t,n)=>{let r=n?.pin??a.s(),i=n?.contentType,o=i?{contentType:i}:void 0,c=t instanceof Blob?t:new Blob([t],o?{type:o.contentType}:void 0);if(await d()){await s.o(e,c,o),U();let t=h(e,r),n=await f();if(n===`disconnected`)return;if(n===`unknown`||!m){b(e,t,r),A();return}a.b(e,c,{...o,pin:r}).then(()=>x(e)).catch(n=>{b(e,t,r),a.l(n)||A(),console.warn(`fs: cloud replicate failed, queued for adopt()`,n)});return}let l=await f();if(l===`connected`)return a.b(e,c,{...o,pin:r});throw Error(l===`unknown`?`fs: cloud unreachable`:`fs: no storage backend available`)},Se=async(e,t)=>{let n=t?.pin??a.s();U();let r=[];await d()&&r.push(s.a(e).catch(()=>{}));let i=await f();if(i===`connected`?r.push(a.v(e,{pin:n}).then(()=>S(e)).catch(t=>{de(e,n),a.l(t)||A(),console.warn(`fs: cloud delete failed, queued for retry`,t)})):i===`unknown`&&r.length&&h(e,n)!==null&&(de(e,n),A()),!r.length)throw Error(i===`unknown`?`fs: cloud unreachable`:`fs: no storage backend available`);x(e),await Promise.all(r)},N=async e=>{let t=a.s(),n=await a.g(e,{pin:t});return await d()&&await s.o(e,n),n},P=null,Ce=e=>(P=e,()=>{P===e&&(P=null)}),we=async e=>{let n=await(await t.o).cloud.fs.promptConflict({path:e.path,local:e.local,cloud:e.cloud}).catch(()=>null);return n===`local`?e.readLocal():n===`cloud`?e.readCloud():null},Te=async e=>{if(P)try{return await P(e)}catch{return null}return we(e)},F=class extends Error{},I=e=>e instanceof Error?e.message:String(e),Ee=()=>{let e=new Map,t=t=>{let n=e.get(t);return n||e.set(t,n={writes:new Map,deletes:new Map}),n};for(let[e,n]of Object.entries(_(`write`)))t(n.pin).writes.set(e,n.base);for(let[e,n]of Object.entries(_(`delete`)))t(n.pin).deletes.set(e,n.base);return e},De=async()=>{for(let[e,t]of[...y]){let n=e.startsWith(`write:`)?`write`:`delete`,r=e.slice(n.length+1),i;try{i=await a.m(t)}catch(t){a.l(t)&&y.delete(e);continue}if(y.get(e)!==t)continue;y.delete(e);let o=_(n),s=o[r];s&&s.pin===null&&(o[r]={base:s.base,pin:i},v(n,o))}},Oe=async(e,t,n,r,i,o)=>{let c=new Map(t.map(e=>[e.path,e])),l=e=>{if(a.l(e))throw new F};for(let[t,o]of e.deletes){let e=c.get(t);if(!e){S(t);continue}if(r.some(e=>e.path===t)){S(t);continue}if(e.updatedAt!==o){S(t);continue}try{await a.v(t,n),S(t),i.deleted.push(t)}catch(e){l(e),i.failed.push({path:t,error:I(e)})}}for(let t of r){let r=c.get(t.path),u=e.writes.has(t.path);if(!u){if(!o(t))continue;if(r){i.kept.push(t.path);continue}}let d=e.writes.get(t.path)??null;if(u&&r&&r.updatedAt!==d){let e=null,o=null,c=await Te({path:t.path,local:{size:t.size,updatedAt:t.updatedAt},cloud:{size:r.size,updatedAt:r.updatedAt},readLocal:()=>e??=s.i(t.path),readCloud:()=>o??=a.g(t.path,n)});if(c==null){i.unresolved.push(t.path);continue}try{let r=e!==null&&c===await e,l=o!==null&&c===await o;l||await a.b(t.path,c,t.contentType?{contentType:t.contentType,...n}:n),r||await s.o(t.path,c),x(t.path),i.resolved.push({path:t.path,choice:r?`local`:l?`cloud`:`merged`})}catch(e){if(l(e),e?.code===`FKN_E2E_LOCKED`)throw e;i.failed.push({path:t.path,error:I(e)})}continue}try{let e=await s.i(t.path);await a.b(t.path,e,t.contentType?{contentType:t.contentType,...n}:n),x(t.path),i.uploaded.push(t.path)}catch(e){if(u||b(t.path,r?.updatedAt??null,n.pin),l(e),e?.code===`FKN_E2E_LOCKED`)throw e;i.failed.push({path:t.path,error:I(e)})}}},ke=async(e,t)=>{let n={uploaded:[],kept:[],resolved:[],unresolved:[],deleted:[],failed:[]},r=await f();if(r===`unknown`)throw Error(`fs: cloud unreachable`);if(r!==`connected`)throw Error(`fs: this needs a signed-in account`);let i=await d(),o=i?await s.n():[];if(i)for(let e of Object.keys(_(`write`)))o.some(t=>t.path===e)||x(e);await De();for(let[e,r]of Ee()){if(e===null||he(e))continue;let i={pin:{pin:e}},s;try{s=await a.p(i)}catch(n){if(a.l(n)){C.set(e,t.generation);continue}if(a.u(n)){Ae(e);continue}throw n}try{await Oe(r,s,i,o,n,()=>!1)}catch(n){if(!(n instanceof F))throw n;C.set(e,t.generation)}}if(e){let e={pin:t},r=await a.p(e),i=_(`write`),s=Ee().get(null)??{writes:new Map,deletes:new Map},c=new Set([...n.uploaded,...n.resolved.map(({path:e})=>e),...n.unresolved,...n.failed.map(({path:e})=>e)]),l=e=>!(e.path in i)&&!c.has(e.path);try{await Oe(s,r,e,o,n,l)}catch(e){throw e instanceof F?new a.t:e}}return n},Ae=e=>{for(let t of[`write`,`delete`]){let n=_(t),r=!1;for(let t of Object.values(n))t.pin===e&&(t.pin=null,r=!0);r&&v(t,n)}},je=async e=>{for(;w;)await w;let t=ke(!0,e);w=t.then(()=>{},()=>{});try{return await t}finally{w=null,ve()}},L=()=>je(a.s()),R=(e,t)=>{let n=new Set(t.map(e=>e.path)),r=_(`write`);return e.filter(e=>{let t=r[e.path];return t?ge(`write`,e.path,t):!n.has(e.path)})},z=async()=>{let e=a.s();if(!await p()||!await d())return{paths:[],bytes:0};let[t,n]=await Promise.all([s.n(),a.p({pin:e})]),r=R(t,n);return{paths:r.map(e=>e.path),bytes:r.reduce((e,t)=>e+t.size,0)}},Me=()=>new Set(Object.keys(se())),Ne=e=>{let t=se();for(let n of e)t[n]=null;try{localStorage.setItem(re,JSON.stringify(t))}catch{}},B=null,V=!1,H=e=>{if(B)return V=!0,B;let n=e?.from??a.s();return B=(async()=>{if(!await p())return;let r=e??(await d()?{local:await s.n(),remote:await a.p({pin:n})}:null);if(!r)return;let i=Me(),o=R(r.local,r.remote).filter(e=>!i.has(e.path));if(!o.length)return;let c=await t.o,l=o.reduce((e,t)=>e+t.size,0);if(!await c.cloud.fs.promptAdopt({files:o.length,bytes:l}).catch(()=>!1)){Ne(o.map(e=>e.path));return}`generation`in n&&await je(n)})().catch(()=>{}).finally(()=>{B=null,V&&(V=!1,H())}),B},Pe=null,Fe=!1,Ie=async(e,n)=>{let r=R(e,n),i=await t.o,a=async()=>{await L().catch(()=>{});let e=await z().catch(()=>({paths:[],bytes:0}));await i.cloud.fs.setAdoptSource({files:e.paths.length,bytes:e.bytes},a).catch(()=>{})},o={files:r.length,bytes:r.reduce((e,t)=>e+t.size,0)};Pe=()=>{i.cloud.fs.setAdoptSource(o,a).catch(()=>{})},Fe||(Fe=!0,t.u((e,t)=>{t>1&&Pe?.()})),await i.cloud.fs.setAdoptSource(o,a)},Le=!1,U=()=>{Le||typeof window>`u`||(Le=!0,window.addEventListener(`online`,()=>{j()}),o.onChange(()=>{H().catch(()=>{}),j()}).catch(()=>{}))},Re=e.t({STORAGE_ACCOUNT_CHANGED:()=>i.STORAGE_ACCOUNT_CHANGED,STORAGE_ACCOUNT_PIN_UNSUPPORTED:()=>i.STORAGE_ACCOUNT_PIN_UNSUPPORTED,StorageAccountChangedError:()=>a.t,StorageAccountPinUnsupportedError:()=>a.n,adopt:()=>q,adoptable:()=>J,appendFile:()=>tt,appendFileSync:()=>Ue,available:()=>Be,default:()=>$,exists:()=>ct,existsSync:()=>We,flush:()=>W,isAccountChanged:()=>a.l,lstatSync:()=>Ke,mkdir:()=>it,mkdirSync:()=>Je,mount:()=>ut,onConflict:()=>Q,pending:()=>Y,pendingDeletes:()=>X,promises:()=>lt,pull:()=>G,readFile:()=>$e,readFileSealed:()=>K,readFileSync:()=>Ve,readdir:()=>rt,readdirSync:()=>qe,remount:()=>dt,rename:()=>st,renameSync:()=>Qe,replicating:()=>Z,rm:()=>at,rmSync:()=>Ye,rmdirSync:()=>Xe,stat:()=>nt,statSync:()=>Ge,unlink:()=>ot,unlinkSync:()=>Ze,writeFile:()=>et,writeFileSync:()=>He}),ze=r.t(c,{memfs:!0}),{available:Be,readFileSync:Ve,writeFileSync:He,appendFileSync:Ue,existsSync:We,statSync:Ge,lstatSync:Ke,readdirSync:qe,mkdirSync:Je,rmSync:Ye,rmdirSync:Xe,unlinkSync:Ze,renameSync:Qe,readFile:$e,writeFile:et,appendFile:tt,stat:nt,readdir:rt,mkdir:it,rm:at,unlink:ot,rename:st,exists:ct,promises:lt,mount:ut,flush:W,remount:dt}=ze,G=N,K=M,q=L,J=z,Y=fe,X=pe,Z=me,Q=Ce,$={...ze,pull:G,readFileSealed:K,adopt:q,adoptable:J,pending:Y,pendingDeletes:X,replicating:Z,onConflict:Q};Object.defineProperty(exports,"A",{enumerable:!0,get:function(){return Ye}}),Object.defineProperty(exports,"C",{enumerable:!0,get:function(){return rt}}),Object.defineProperty(exports,"D",{enumerable:!0,get:function(){return Qe}}),Object.defineProperty(exports,"E",{enumerable:!0,get:function(){return st}}),Object.defineProperty(exports,"F",{enumerable:!0,get:function(){return Ze}}),Object.defineProperty(exports,"I",{enumerable:!0,get:function(){return et}}),Object.defineProperty(exports,"L",{enumerable:!0,get:function(){return He}}),Object.defineProperty(exports,"M",{enumerable:!0,get:function(){return nt}}),Object.defineProperty(exports,"N",{enumerable:!0,get:function(){return Ge}}),Object.defineProperty(exports,"O",{enumerable:!0,get:function(){return Z}}),Object.defineProperty(exports,"P",{enumerable:!0,get:function(){return ot}}),Object.defineProperty(exports,"S",{enumerable:!0,get:function(){return Ve}}),Object.defineProperty(exports,"T",{enumerable:!0,get:function(){return dt}}),Object.defineProperty(exports,"_",{enumerable:!0,get:function(){return X}}),Object.defineProperty(exports,"a",{enumerable:!0,get:function(){return Be}}),Object.defineProperty(exports,"b",{enumerable:!0,get:function(){return $e}}),Object.defineProperty(exports,"c",{enumerable:!0,get:function(){return W}}),Object.defineProperty(exports,"d",{enumerable:!0,get:function(){return Ke}}),Object.defineProperty(exports,"f",{enumerable:!0,get:function(){return it}}),Object.defineProperty(exports,"g",{enumerable:!0,get:function(){return Y}}),Object.defineProperty(exports,"h",{enumerable:!0,get:function(){return Q}}),Object.defineProperty(exports,"i",{enumerable:!0,get:function(){return Ue}}),Object.defineProperty(exports,"j",{enumerable:!0,get:function(){return Xe}}),Object.defineProperty(exports,"k",{enumerable:!0,get:function(){return at}}),Object.defineProperty(exports,"l",{enumerable:!0,get:function(){return $}}),Object.defineProperty(exports,"m",{enumerable:!0,get:function(){return ut}}),Object.defineProperty(exports,"n",{enumerable:!0,get:function(){return J}}),Object.defineProperty(exports,"o",{enumerable:!0,get:function(){return ct}}),Object.defineProperty(exports,"p",{enumerable:!0,get:function(){return Je}}),Object.defineProperty(exports,"r",{enumerable:!0,get:function(){return tt}}),Object.defineProperty(exports,"s",{enumerable:!0,get:function(){return We}}),Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return q}}),Object.defineProperty(exports,"u",{enumerable:!0,get:function(){return Re}}),Object.defineProperty(exports,"v",{enumerable:!0,get:function(){return lt}}),Object.defineProperty(exports,"w",{enumerable:!0,get:function(){return qe}}),Object.defineProperty(exports,"x",{enumerable:!0,get:function(){return K}}),Object.defineProperty(exports,"y",{enumerable:!0,get:function(){return G}});
package/fs.cjs CHANGED
@@ -1 +1 @@
1
- Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("./messages.cjs"),t=require("./storage-DmRIhg1P.cjs"),n=require("./fs-DnF1cQuE.cjs");exports.STORAGE_ACCOUNT_CHANGED=e.STORAGE_ACCOUNT_CHANGED,exports.STORAGE_ACCOUNT_PIN_UNSUPPORTED=e.STORAGE_ACCOUNT_PIN_UNSUPPORTED,exports.StorageAccountChangedError=t.t,exports.StorageAccountPinUnsupportedError=t.n,exports.adopt=n.t,exports.adoptable=n.n,exports.appendFile=n.r,exports.appendFileSync=n.i,exports.available=n.a,exports.default=n.l,exports.exists=n.o,exports.existsSync=n.s,exports.flush=n.c,exports.isAccountChanged=t.c,exports.lstatSync=n.d,exports.mkdir=n.f,exports.mkdirSync=n.p,exports.mount=n.m,exports.onConflict=n.h,exports.pending=n.g,exports.pendingDeletes=n._,exports.promises=n.v,exports.pull=n.y,exports.readFile=n.b,exports.readFileSealed=n.x,exports.readFileSync=n.S,exports.readdir=n.C,exports.readdirSync=n.w,exports.remount=n.T,exports.rename=n.E,exports.renameSync=n.D,exports.replicating=n.O,exports.rm=n.k,exports.rmSync=n.A,exports.rmdirSync=n.j,exports.stat=n.M,exports.statSync=n.N,exports.unlink=n.P,exports.unlinkSync=n.F,exports.writeFile=n.I,exports.writeFileSync=n.L;
1
+ Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("./messages.cjs"),t=require("./account-storage-C6hcXjG0.cjs"),n=require("./fs-zERmcLRS.cjs");exports.STORAGE_ACCOUNT_CHANGED=e.STORAGE_ACCOUNT_CHANGED,exports.STORAGE_ACCOUNT_PIN_UNSUPPORTED=e.STORAGE_ACCOUNT_PIN_UNSUPPORTED,exports.StorageAccountChangedError=t.t,exports.StorageAccountPinUnsupportedError=t.n,exports.adopt=n.t,exports.adoptable=n.n,exports.appendFile=n.r,exports.appendFileSync=n.i,exports.available=n.a,exports.default=n.l,exports.exists=n.o,exports.existsSync=n.s,exports.flush=n.c,exports.isAccountChanged=t.l,exports.lstatSync=n.d,exports.mkdir=n.f,exports.mkdirSync=n.p,exports.mount=n.m,exports.onConflict=n.h,exports.pending=n.g,exports.pendingDeletes=n._,exports.promises=n.v,exports.pull=n.y,exports.readFile=n.b,exports.readFileSealed=n.x,exports.readFileSync=n.S,exports.readdir=n.C,exports.readdirSync=n.w,exports.remount=n.T,exports.rename=n.E,exports.renameSync=n.D,exports.replicating=n.O,exports.rm=n.k,exports.rmSync=n.A,exports.rmdirSync=n.j,exports.stat=n.M,exports.statSync=n.N,exports.unlink=n.P,exports.unlinkSync=n.F,exports.writeFile=n.I,exports.writeFileSync=n.L;
package/fs.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { i as Stats } from "./index-BQgZVQl7.js";
2
- import { a as StorageAccountChangedError, i as SealedRead, o as StorageAccountPinUnsupportedError, p as isAccountChanged } from "./storage-B_mXNAdB.js";
3
- import { c as STORAGE_ACCOUNT_CHANGED, l as STORAGE_ACCOUNT_PIN_UNSUPPORTED } from "./messages-d7pvCXPn.js";
4
- import { A as rmSync, B as ConflictResolver, C as readdir, D as renameSync, E as rename, F as unlinkSync, H as FileConflict, I as writeFile, L as writeFileSync, M as stat, N as statSync, O as replicating, P as unlink, R as AdoptSummary, S as readFileSync, T as remount, V as ConflictSide, _ as pendingDeletes, a as appendFileSync, b as readFile, c as existsSync, d as lstatSync, f as mkdir, g as pending, h as onConflict, i as appendFile, j as rmdirSync, k as rm, l as flush, m as mount, n as adopt, o as available, p as mkdirSync, r as adoptable, s as exists, t as _default, v as promises, w as readdirSync, x as readFileSealed, y as pull, z as ConflictResolution } from "./index-D9x6A-Gx.js";
2
+ import { a as StorageAccountChangedError, i as SealedRead, m as isAccountChanged, o as StorageAccountPinUnsupportedError } from "./account-storage-DHl6bXdb.js";
3
+ import { c as STORAGE_ACCOUNT_CHANGED, l as STORAGE_ACCOUNT_PIN_UNSUPPORTED } from "./messages-AdPfdoLV.js";
4
+ import { A as rmSync, B as ConflictResolver, C as readdir, D as renameSync, E as rename, F as unlinkSync, H as FileConflict, I as writeFile, L as writeFileSync, M as stat, N as statSync, O as replicating, P as unlink, R as AdoptSummary, S as readFileSync, T as remount, V as ConflictSide, _ as pendingDeletes, a as appendFileSync, b as readFile, c as existsSync, d as lstatSync, f as mkdir, g as pending, h as onConflict, i as appendFile, j as rmdirSync, k as rm, l as flush, m as mount, n as adopt, o as available, p as mkdirSync, r as adoptable, s as exists, t as _default, v as promises, w as readdirSync, x as readFileSealed, y as pull, z as ConflictResolution } from "./index-DawD_N1P.js";
5
5
  export { type AdoptSummary, type ConflictResolution, type ConflictResolver, type ConflictSide, type FileConflict, STORAGE_ACCOUNT_CHANGED, STORAGE_ACCOUNT_PIN_UNSUPPORTED, type SealedRead, type Stats, StorageAccountChangedError, StorageAccountPinUnsupportedError, adopt, adoptable, appendFile, appendFileSync, available, _default as default, exists, existsSync, flush, isAccountChanged, lstatSync, mkdir, mkdirSync, mount, onConflict, pending, pendingDeletes, promises, pull, readFile, readFileSealed, readFileSync, readdir, readdirSync, remount, rename, renameSync, replicating, rm, rmSync, rmdirSync, stat, statSync, unlink, unlinkSync, writeFile, writeFileSync };
package/fs.js CHANGED
@@ -1,4 +1,4 @@
1
1
  import { STORAGE_ACCOUNT_CHANGED as e, STORAGE_ACCOUNT_PIN_UNSUPPORTED as t } from "./messages.js";
2
- import { c as n, n as r, t as i } from "./storage-C6F9SnDM.js";
3
- import { A as a, C as o, D as s, E as c, F as l, I as u, L as d, M as f, N as p, O as m, P as h, S as g, T as _, _ as v, a as y, b, c as x, d as S, f as C, g as w, h as T, i as E, j as D, k as O, l as k, m as A, n as j, o as M, p as N, r as P, s as F, t as I, v as L, w as R, x as z, y as B } from "./fs-BY0Csn2V.js";
2
+ import { l as n, n as r, t as i } from "./account-storage-C31d68BN.js";
3
+ import { A as a, C as o, D as s, E as c, F as l, I as u, L as d, M as f, N as p, O as m, P as h, S as g, T as _, _ as v, a as y, b, c as x, d as S, f as C, g as w, h as T, i as E, j as D, k as O, l as k, m as A, n as j, o as M, p as N, r as P, s as F, t as I, v as L, w as R, x as z, y as B } from "./fs-ClnOPmRF.js";
4
4
  export { e as STORAGE_ACCOUNT_CHANGED, t as STORAGE_ACCOUNT_PIN_UNSUPPORTED, i as StorageAccountChangedError, r as StorageAccountPinUnsupportedError, I as adopt, j as adoptable, P as appendFile, E as appendFileSync, y as available, k as default, M as exists, F as existsSync, x as flush, n as isAccountChanged, S as lstatSync, C as mkdir, N as mkdirSync, A as mount, T as onConflict, w as pending, v as pendingDeletes, L as promises, B as pull, b as readFile, z as readFileSealed, g as readFileSync, o as readdir, R as readdirSync, _ as remount, c as rename, s as renameSync, m as replicating, O as rm, a as rmSync, D as rmdirSync, f as stat, p as statSync, h as unlink, l as unlinkSync, u as writeFile, d as writeFileSync };
package/http.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { n as Socket, t as Server$1 } from "./net-C2Yz0job.js";
1
+ import { n as Socket, t as Server$1 } from "./net-C2sulnNU.js";
2
2
  import { Buffer } from "buffer";
3
3
  import { Stream } from "stream";
4
4
  import { IncomingHttpHeaders, OutgoingHttpHeaders, RequestOptions } from "http";
@@ -1,6 +1,6 @@
1
1
  import { a as WriteData, i as Stats, n as MakeOptions, o as WriteOptions, r as ReadOptions, t as Callback } from "./index-BQgZVQl7.js";
2
- import { a as StorageAccountChangedError, b as PinOptions, d as captureAccount$1, g as storage_d_exports, i as SealedRead, o as StorageAccountPinUnsupportedError, p as isAccountChanged, v as FileEntry, x as WriteData$1, y as FileSystem } from "./storage-B_mXNAdB.js";
3
- import { c as STORAGE_ACCOUNT_CHANGED, l as STORAGE_ACCOUNT_PIN_UNSUPPORTED } from "./messages-d7pvCXPn.js";
2
+ import { a as StorageAccountChangedError, b as PinOptions, f as captureAccount$1, i as SealedRead, m as isAccountChanged, o as StorageAccountPinUnsupportedError, u as account_storage_d_exports, v as FileEntry, x as WriteData$1, y as FileSystem } from "./account-storage-DHl6bXdb.js";
3
+ import { c as STORAGE_ACCOUNT_CHANGED, l as STORAGE_ACCOUNT_PIN_UNSUPPORTED } from "./messages-AdPfdoLV.js";
4
4
  declare namespace hybrid_d_exports {
5
5
  export { AdoptSummary, ConflictResolution, ConflictResolver, ConflictSide, FileConflict, FileEntry, FileSystem, WriteData$1 as WriteData, adopt$1 as adopt, adoptable$1 as adoptable, available$1 as available, captureAccount, list, onConflict$1 as onConflict, pending$1 as pending, pendingDeletes$1 as pendingDeletes, pull$1 as pull, readFile$1 as readFile, readFileSealed$1 as readFileSealed, remove, replicating$1 as replicating, writeFile$1 as writeFile };
6
6
  }
package/index.cjs CHANGED
@@ -1 +1 @@
1
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./rolldown-runtime-BIInC43l.cjs"),t=require("./lib-5z-jA7ND.cjs"),n=require("./extension-uAlpUogG.cjs"),r=require("./api-DMnVye0K.cjs"),i=require("./busy-BXbVH595.cjs"),a=require("./contract.cjs"),o=require("./cloud-BmwojOb5.cjs"),s=require("./dns.cjs"),c=require("./net.cjs"),l=require("./dgram.cjs"),u=require("./http.cjs"),d=require("./desktop.cjs"),f=require("./account.cjs"),p=require("./fs-DnF1cQuE.cjs"),m=require("./opfs.cjs"),h=require("./packages.cjs"),g=require("./rooms.cjs"),_=require("./links.cjs"),v=require("./connect-button-BpXDs7tw.cjs");let y=require("osra");var b=1e4,x=150,S=()=>new Promise(e=>{if(t.et())return e(!0);let n,r=setTimeout(()=>i(t.et()),b),i=t=>{clearTimeout(n),clearTimeout(r),o.disconnect(),document.removeEventListener(`readystatechange`,s),e(t)},a=()=>{clearTimeout(n),n=setTimeout(()=>i(t.et()),x)},o=new MutationObserver(()=>{t.et()&&i(!0)}),s=()=>{document.readyState===`complete`&&!t.et()&&a()};o.observe(document.documentElement,{attributes:!0,attributeFilter:[`data-fkn-extension`]}),document.addEventListener(`readystatechange`,s),document.readyState===`complete`&&a()}),C=(async e=>{let{kind:n,cookies:r}=t.o(e);if(n===`window`){let n=e;return r===`native`?t.a(n):o.i(n)}let i=e;return r===`native`?w(i):o.i(i)}),w=async e=>(o.a(e),await S(),t.a(e)),T=`https://fkn.app`,E=async(e,t)=>{if(typeof window>`u`)throw Error(`FKN @fkn/lib: relayWorker must be called from the main thread`);let n=await r.f;if(!n)throw Error(`FKN @fkn/lib: relayWorker found no FKN transport in this realm`);r.d(),i.r(`relayed worker`,t?.unregisterSignal);let a=n.emit instanceof MessagePort?{}:{originA:t?.originA??T,originB:t?.originB??`*`};(0,y.relay)(n,e,{key:`fkn-api`,...a,unregisterSignal:t?.unregisterSignal})},D=async()=>typeof window>`u`?!1:(await r.o).connect.prompt(location.origin).catch(()=>!1),O=async()=>typeof window>`u`?null:(await r.o).relay.prompt().catch(()=>null),k=new Set,A=e=>(k.add(e),()=>{k.delete(e)}),j=()=>{if(k.size===0)return!1;for(let e of[...k])try{e()}catch{}return!0},M=(e,t)=>{if(typeof e?.onUpdateTaken==`function`)return Promise.resolve(e.onUpdateTaken(t))},N=e.t({applyUpdate:()=>K,busyReasons:()=>G,onUpdate:()=>B,onUpdateTaken:()=>V,updateReady:()=>P}),P=async()=>typeof window>`u`?!1:r.o.then(e=>e.shell?.updateReady()).then(e=>e===!0).catch(()=>!1),F=new Set,I=!1,L=()=>{I=!0;for(let e of[...F])try{e()}catch{}},R=0,z=()=>{let e=r.c();e&&F.size!==0&&R!==e.epoch&&(R=e.epoch,I=!1,Promise.resolve(e.remote.shell?.onUpdate(L)).catch(()=>{R===e.epoch&&(R=0)}))};typeof window<`u`&&r.u(z);var B=async e=>{if(typeof window>`u`)return()=>{};if(F.add(e),I)try{e()}catch{}return z(),()=>{F.delete(e)}},V=e=>typeof window>`u`?()=>{}:A(e),H=0,U=!1,W=()=>{if(!j()&&!U){U=!0;try{location.reload()}catch{}}};typeof window<`u`&&r.u(()=>{let e=r.c();if(!e||H===e.epoch)return;H=e.epoch;let t=M(e.remote.shell,W);if(!t){H=0;return}t.catch(()=>{H===e.epoch&&(H=0)})});var G=()=>i.n(),K=async()=>typeof window>`u`?!1:r.o.then(e=>e.shell?.applyUpdate()).then(e=>e===!0).catch(()=>!1);exports.ATTACH_FRAME_EVENT_KEY=t.i,exports.BACKGROUND_STOPPED=n.a,exports.CATEGORIES=t.w,exports.EXTENSION_ABI=t.it,exports.ExtensionOperationUnsupportedError=t.at,exports.ExtensionOutdatedError=t.ot,exports.FORGEABLE_HEADERS=t.Y,exports.FrameWindowBlockedError=t.g,exports.FrameWindowRefusedError=t._,exports.LINK_EXPIRES_MS=a.LINK_EXPIRES_MS,exports.LOCATOR_DENIED=t.k,exports.LOCATOR_ERROR=t.P,exports.LOCATOR_INVALID=t.I,exports.LOCATOR_UNSUPPORTED=t.E,exports.PERMISSION_DENIED=t.t,exports.REQUIRED_EXTENSION_ABI=t.st,exports.TimeoutError=t.T,Object.defineProperty(exports,"account",{enumerable:!0,get:function(){return f.t}}),exports.assertAttachableFrameUrl=t.x,exports.assertFetchableUrl=t.H,exports.assertForgeableHeaders=t.X,exports.assertLockdownApplicable=t.S,exports.assertOneCookieIdentity=t.Z,exports.attachFrame=C,exports.attachFramePermission=t.v,exports.box=t.ut,Object.defineProperty(exports,"cloud",{enumerable:!0,get:function(){return o.n}}),exports.connect=D,exports.connectButtonUrl=v.t,exports.cookies=t.B,exports.createFrame=t.y,exports.createVideoElementHandle=t.dt,Object.defineProperty(exports,"desktop",{enumerable:!0,get:function(){return d.t}}),Object.defineProperty(exports,"dgram",{enumerable:!0,get:function(){return l.t}}),Object.defineProperty(exports,"dns",{enumerable:!0,get:function(){return s.t}}),Object.defineProperty(exports,"extension",{enumerable:!0,get:function(){return n.t}}),exports.fetch=n.n,exports.fetchCredentialedPermission=t.W,exports.fetchLocalPermission=t.G,exports.fetchPermission=t.K,Object.defineProperty(exports,"fs",{enumerable:!0,get:function(){return p.u}}),exports.gotoPermission=t.b,exports.handleRevivableModules=t.lt,exports.hasForgedCookie=t.Q,Object.defineProperty(exports,"http",{enumerable:!0,get:function(){return u.t}}),exports.isBackgroundStopped=n.o,exports.isBlockedFetchUrl=t.q,exports.isBlockedFrameUrl=t.C,exports.isExtensionExposed=t.et,exports.isLocalNetworkUrl=t.J,exports.isLocatorDenied=t.F,exports.isLocatorInvalid=t.j,exports.isLocatorUnsupported=t.D,exports.isPermissionDenied=t.n,exports.isTerminalError=t.N,exports.isType=t.ft,Object.defineProperty(exports,"links",{enumerable:!0,get:function(){return _.t}}),exports.modifyRequestHeadersPermission=t.L,Object.defineProperty(exports,"net",{enumerable:!0,get:function(){return c.t}}),Object.defineProperty(exports,"opfs",{enumerable:!0,get:function(){return m.t}}),Object.defineProperty(exports,"packages",{enumerable:!0,get:function(){return h.t}}),exports.permissions=t.r,exports.promptInstall=n.i,exports.promptRelay=O,exports.readCookiePermission=t.V,exports.readExtensionHandshake=t.tt,exports.relayWorker=E,exports.removeRequestHeaderRule=t.R,exports.revive=t.pt,Object.defineProperty(exports,"rooms",{enumerable:!0,get:function(){return g.t}}),exports.setMissingExtensionHandler=t.nt,exports.setRequestHeaderRule=t.z,Object.defineProperty(exports,"shell",{enumerable:!0,get:function(){return N}}),exports.supportsOperation=t.ct,exports.type=t.mt,exports.waitForExtensionExposure=t.rt;
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./rolldown-runtime-BIInC43l.cjs"),t=require("./lib-5z-jA7ND.cjs"),n=require("./extension-uAlpUogG.cjs"),r=require("./api-DMnVye0K.cjs"),i=require("./busy-BXbVH595.cjs"),a=require("./cloud-BmwojOb5.cjs"),o=require("./dns.cjs"),s=require("./net.cjs"),c=require("./dgram.cjs"),l=require("./http.cjs"),u=require("./desktop.cjs"),d=require("./account.cjs"),f=require("./fs-zERmcLRS.cjs"),p=require("./opfs.cjs"),m=require("./packages.cjs"),h=require("./rooms.cjs"),g=require("./storage.cjs"),_=require("./connect-button-BpXDs7tw.cjs");let v=require("osra");var y=1e4,b=150,x=()=>new Promise(e=>{if(t.et())return e(!0);let n,r=setTimeout(()=>i(t.et()),y),i=t=>{clearTimeout(n),clearTimeout(r),o.disconnect(),document.removeEventListener(`readystatechange`,s),e(t)},a=()=>{clearTimeout(n),n=setTimeout(()=>i(t.et()),b)},o=new MutationObserver(()=>{t.et()&&i(!0)}),s=()=>{document.readyState===`complete`&&!t.et()&&a()};o.observe(document.documentElement,{attributes:!0,attributeFilter:[`data-fkn-extension`]}),document.addEventListener(`readystatechange`,s),document.readyState===`complete`&&a()}),S=(async e=>{let{kind:n,cookies:r}=t.o(e);if(n===`window`){let n=e;return r===`native`?t.a(n):a.i(n)}let i=e;return r===`native`?C(i):a.i(i)}),C=async e=>(a.a(e),await x(),t.a(e)),w=`https://fkn.app`,T=async(e,t)=>{if(typeof window>`u`)throw Error(`FKN @fkn/lib: relayWorker must be called from the main thread`);let n=await r.f;if(!n)throw Error(`FKN @fkn/lib: relayWorker found no FKN transport in this realm`);r.d(),i.r(`relayed worker`,t?.unregisterSignal);let a=n.emit instanceof MessagePort?{}:{originA:t?.originA??w,originB:t?.originB??`*`};(0,v.relay)(n,e,{key:`fkn-api`,...a,unregisterSignal:t?.unregisterSignal})},E=async()=>typeof window>`u`?!1:(await r.o).connect.prompt(location.origin).catch(()=>!1),D=async()=>typeof window>`u`?null:(await r.o).relay.prompt().catch(()=>null),O=new Set,k=e=>(O.add(e),()=>{O.delete(e)}),A=()=>{if(O.size===0)return!1;for(let e of[...O])try{e()}catch{}return!0},j=(e,t)=>{if(typeof e?.onUpdateTaken==`function`)return Promise.resolve(e.onUpdateTaken(t))},M=e.t({applyUpdate:()=>G,busyReasons:()=>W,onUpdate:()=>z,onUpdateTaken:()=>B,updateReady:()=>N}),N=async()=>typeof window>`u`?!1:r.o.then(e=>e.shell?.updateReady()).then(e=>e===!0).catch(()=>!1),P=new Set,F=!1,I=()=>{F=!0;for(let e of[...P])try{e()}catch{}},L=0,R=()=>{let e=r.c();e&&P.size!==0&&L!==e.epoch&&(L=e.epoch,F=!1,Promise.resolve(e.remote.shell?.onUpdate(I)).catch(()=>{L===e.epoch&&(L=0)}))};typeof window<`u`&&r.u(R);var z=async e=>{if(typeof window>`u`)return()=>{};if(P.add(e),F)try{e()}catch{}return R(),()=>{P.delete(e)}},B=e=>typeof window>`u`?()=>{}:k(e),V=0,H=!1,U=()=>{if(!A()&&!H){H=!0;try{location.reload()}catch{}}};typeof window<`u`&&r.u(()=>{let e=r.c();if(!e||V===e.epoch)return;V=e.epoch;let t=j(e.remote.shell,U);if(!t){V=0;return}t.catch(()=>{V===e.epoch&&(V=0)})});var W=()=>i.n(),G=async()=>typeof window>`u`?!1:r.o.then(e=>e.shell?.applyUpdate()).then(e=>e===!0).catch(()=>!1);exports.ATTACH_FRAME_EVENT_KEY=t.i,exports.BACKGROUND_STOPPED=n.a,exports.CATEGORIES=t.w,exports.EXTENSION_ABI=t.it,exports.ExtensionOperationUnsupportedError=t.at,exports.ExtensionOutdatedError=t.ot,exports.FORGEABLE_HEADERS=t.Y,exports.FrameWindowBlockedError=t.g,exports.FrameWindowRefusedError=t._,exports.LOCATOR_DENIED=t.k,exports.LOCATOR_ERROR=t.P,exports.LOCATOR_INVALID=t.I,exports.LOCATOR_UNSUPPORTED=t.E,exports.PERMISSION_DENIED=t.t,exports.REQUIRED_EXTENSION_ABI=t.st,exports.TimeoutError=t.T,Object.defineProperty(exports,"account",{enumerable:!0,get:function(){return d.t}}),exports.assertAttachableFrameUrl=t.x,exports.assertFetchableUrl=t.H,exports.assertForgeableHeaders=t.X,exports.assertLockdownApplicable=t.S,exports.assertOneCookieIdentity=t.Z,exports.attachFrame=S,exports.attachFramePermission=t.v,exports.box=t.ut,Object.defineProperty(exports,"cloud",{enumerable:!0,get:function(){return a.n}}),exports.connect=E,exports.connectButtonUrl=_.t,exports.cookies=t.B,exports.createFrame=t.y,exports.createVideoElementHandle=t.dt,Object.defineProperty(exports,"desktop",{enumerable:!0,get:function(){return u.t}}),Object.defineProperty(exports,"dgram",{enumerable:!0,get:function(){return c.t}}),Object.defineProperty(exports,"dns",{enumerable:!0,get:function(){return o.t}}),Object.defineProperty(exports,"extension",{enumerable:!0,get:function(){return n.t}}),exports.fetch=n.n,exports.fetchCredentialedPermission=t.W,exports.fetchLocalPermission=t.G,exports.fetchPermission=t.K,Object.defineProperty(exports,"fs",{enumerable:!0,get:function(){return f.u}}),exports.gotoPermission=t.b,exports.handleRevivableModules=t.lt,exports.hasForgedCookie=t.Q,Object.defineProperty(exports,"http",{enumerable:!0,get:function(){return l.t}}),exports.isBackgroundStopped=n.o,exports.isBlockedFetchUrl=t.q,exports.isBlockedFrameUrl=t.C,exports.isExtensionExposed=t.et,exports.isLocalNetworkUrl=t.J,exports.isLocatorDenied=t.F,exports.isLocatorInvalid=t.j,exports.isLocatorUnsupported=t.D,exports.isPermissionDenied=t.n,exports.isTerminalError=t.N,exports.isType=t.ft,exports.modifyRequestHeadersPermission=t.L,Object.defineProperty(exports,"net",{enumerable:!0,get:function(){return s.t}}),Object.defineProperty(exports,"opfs",{enumerable:!0,get:function(){return p.t}}),Object.defineProperty(exports,"packages",{enumerable:!0,get:function(){return m.t}}),exports.permissions=t.r,exports.promptInstall=n.i,exports.promptRelay=D,exports.readCookiePermission=t.V,exports.readExtensionHandshake=t.tt,exports.relayWorker=T,exports.removeRequestHeaderRule=t.R,exports.revive=t.pt,Object.defineProperty(exports,"rooms",{enumerable:!0,get:function(){return h.t}}),exports.setMissingExtensionHandler=t.nt,exports.setRequestHeaderRule=t.z,Object.defineProperty(exports,"shell",{enumerable:!0,get:function(){return M}}),Object.defineProperty(exports,"storage",{enumerable:!0,get:function(){return g.t}}),exports.supportsOperation=t.ct,exports.type=t.mt,exports.waitForExtensionExposure=t.rt;
package/index.d.ts CHANGED
@@ -1,18 +1,17 @@
1
1
  import { t as account_d_exports } from "./account.js";
2
2
  import { $ as GateTools, A as attachFramePermission, B as CategoryMeta, C as FrameWindowRefusal, D as StorageState, E as Locator, F as LegacyPermissionRequest, G as VideoElementState, H as handleRevivableModules, I as PermissionGrant, J as isType, K as box, L as PermissionRequest, M as gotoPermission, N as CategoryGrant, O as StorageStateCookie, P as CategoryRequest, Q as Gate, R as permissions, S as FrameWindowOptions, T as GotoOptions, U as BoxedVideoElement, V as PermissionCategory, W as RemoteVideoElement, X as type, Y as revive, Z as Executor, _ as FrameEventMap, a as AttachCookies, b as FramePostMessageOptions, c as BlankPage, d as CookieMatchWire, et as OperationRequest, f as Frame, g as FrameEventListener, h as FrameDocumentEvent, i as AddScriptTagOptions, j as createFrame, k as WindowFrame, l as ClearCookiesOptions, m as FrameBackendEvent, o as AttachFrameOptions, p as FrameBackend, q as createVideoElementHandle, r as AttachFrameFunction, s as AttachWindowOptions, t as ATTACH_FRAME_EVENT_KEY, tt as SelectorPart, u as ClearCookiesWire, v as FrameLocator, w as FrameWindowRefusedError, x as FrameWindowBlockedError, y as FrameMessageEvent, z as CATEGORIES } from "./index-DlBWSKwV.js";
3
3
  import { $ as isLocatorInvalid, A as CookieDetails, B as fetchPermission, C as assertLockdownApplicable, D as modifyRequestHeadersPermission, E as RequestHeaderRule, F as ProxyFetchRequest, G as assertOneCookieIdentity, H as isLocalNetworkUrl, I as assertFetchableUrl, J as LOCATOR_ERROR, K as hasForgedCookie, M as cookies, N as readCookiePermission, O as removeRequestHeaderRule, P as FetchInit, Q as isLocatorDenied, R as fetchCredentialedPermission, S as assertAttachableFrameUrl, T as HeaderOperation, U as FORGEABLE_HEADERS, V as isBlockedFetchUrl, W as assertForgeableHeaders, X as LOCATOR_UNSUPPORTED, Y as LOCATOR_INVALID, Z as TimeoutError, _ as BackgroundStoppedError, b as PermissionDeniedError, c as setMissingExtensionHandler, d as ExtensionHandshake, et as isLocatorUnsupported, f as ExtensionOperationUnsupportedError, g as BACKGROUND_STOPPED, h as supportsOperation, i as promptInstall, j as SiteCookie, k as setRequestHeaderRule, l as waitForExtensionExposure, m as REQUIRED_EXTENSION_ABI, n as fetch, o as isExtensionExposed, p as ExtensionOutdatedError, q as LOCATOR_DENIED, s as readExtensionHandshake, t as extension_d_exports, tt as isTerminalError, u as EXTENSION_ABI, v as isBackgroundStopped, w as isBlockedFrameUrl, x as isPermissionDenied, y as PERMISSION_DENIED, z as fetchLocalPermission } from "./extension-C4Don9vi.js";
4
- import { k as LINK_EXPIRES_MS } from "./contract-XlEPwc7b.js";
5
- import { n as cloud_d_exports } from "./cloud-DK3DtdsU.js";
4
+ import { n as cloud_d_exports } from "./cloud-CWHjH89l.js";
6
5
  import { t as dns_d_exports } from "./dns.js";
7
- import { s as net_d_exports } from "./net-C2Yz0job.js";
6
+ import { s as net_d_exports } from "./net-C2sulnNU.js";
8
7
  import { t as dgram_d_exports } from "./dgram.js";
9
8
  import { t as http_d_exports } from "./http.js";
10
9
  import { t as desktop_d_exports } from "./desktop.js";
11
- import { u as index_d_exports } from "./index-D9x6A-Gx.js";
10
+ import { u as index_d_exports } from "./index-DawD_N1P.js";
12
11
  import { t as index_d_exports$1 } from "./opfs.js";
13
12
  import { t as packages_d_exports } from "./packages.js";
14
13
  import { t as rooms_d_exports } from "./rooms.js";
15
- import { t as links_d_exports } from "./links.js";
14
+ import { t as storage_d_exports } from "./storage.js";
16
15
  import { t as connectButtonUrl } from "./connect-button-Cp0NS95-.js";
17
16
  //#region src/frame.d.ts
18
17
  /**
@@ -129,4 +128,4 @@ declare const busyReasons: () => string[];
129
128
  */
130
129
  declare const applyUpdate: () => Promise<boolean>;
131
130
  //#endregion
132
- export { ATTACH_FRAME_EVENT_KEY, AddScriptTagOptions, AttachCookies, AttachFrameOptions, AttachWindowOptions, BACKGROUND_STOPPED, type BackgroundStoppedError, BlankPage, BoxedVideoElement, CATEGORIES, CategoryGrant, type CategoryMeta, CategoryRequest, ClearCookiesOptions, ClearCookiesWire, CookieDetails, CookieMatchWire, EXTENSION_ABI, type Executor, type ExtensionHandshake, ExtensionOperationUnsupportedError, ExtensionOutdatedError, FORGEABLE_HEADERS, FetchInit, Frame, FrameBackend, FrameBackendEvent, FrameDocumentEvent, FrameEventListener, FrameEventMap, FrameLocator, FrameMessageEvent, FramePostMessageOptions, FrameWindowBlockedError, FrameWindowOptions, FrameWindowRefusal, FrameWindowRefusedError, type Gate, type GateTools, GotoOptions, HeaderOperation, LINK_EXPIRES_MS, LOCATOR_DENIED, LOCATOR_ERROR, LOCATOR_INVALID, LOCATOR_UNSUPPORTED, LegacyPermissionRequest, Locator, type OperationRequest, PERMISSION_DENIED, type PermissionCategory, type PermissionDeniedError, PermissionGrant, PermissionRequest, ProxyFetchRequest, REQUIRED_EXTENSION_ABI, RemoteVideoElement, RequestHeaderRule, type SelectorPart, SiteCookie, StorageState, StorageStateCookie, TimeoutError, VideoElementState, WindowFrame, account_d_exports as account, assertAttachableFrameUrl, assertFetchableUrl, assertForgeableHeaders, assertLockdownApplicable, assertOneCookieIdentity, attachFramePermission, box, cloud_d_exports as cloud, connectButtonUrl, cookies, createFrame, createVideoElementHandle, desktop_d_exports as desktop, dgram_d_exports as dgram, dns_d_exports as dns, extension_d_exports as extension, fetch, fetchCredentialedPermission, fetchLocalPermission, fetchPermission, index_d_exports as fs, gotoPermission, handleRevivableModules, hasForgedCookie, http_d_exports as http, isBackgroundStopped, isBlockedFetchUrl, isBlockedFrameUrl, isExtensionExposed, isLocalNetworkUrl, isLocatorDenied, isLocatorInvalid, isLocatorUnsupported, isPermissionDenied, isTerminalError, isType, links_d_exports as links, modifyRequestHeadersPermission, net_d_exports as net, index_d_exports$1 as opfs, packages_d_exports as packages, permissions, promptInstall, readCookiePermission, readExtensionHandshake, removeRequestHeaderRule, revive, rooms_d_exports as rooms, setMissingExtensionHandler, setRequestHeaderRule, shell_d_exports as shell, supportsOperation, type, waitForExtensionExposure };
131
+ export { ATTACH_FRAME_EVENT_KEY, AddScriptTagOptions, AttachCookies, AttachFrameOptions, AttachWindowOptions, BACKGROUND_STOPPED, type BackgroundStoppedError, BlankPage, BoxedVideoElement, CATEGORIES, CategoryGrant, type CategoryMeta, CategoryRequest, ClearCookiesOptions, ClearCookiesWire, CookieDetails, CookieMatchWire, EXTENSION_ABI, type Executor, type ExtensionHandshake, ExtensionOperationUnsupportedError, ExtensionOutdatedError, FORGEABLE_HEADERS, FetchInit, Frame, FrameBackend, FrameBackendEvent, FrameDocumentEvent, FrameEventListener, FrameEventMap, FrameLocator, FrameMessageEvent, FramePostMessageOptions, FrameWindowBlockedError, FrameWindowOptions, FrameWindowRefusal, FrameWindowRefusedError, type Gate, type GateTools, GotoOptions, HeaderOperation, LOCATOR_DENIED, LOCATOR_ERROR, LOCATOR_INVALID, LOCATOR_UNSUPPORTED, LegacyPermissionRequest, Locator, type OperationRequest, PERMISSION_DENIED, type PermissionCategory, type PermissionDeniedError, PermissionGrant, PermissionRequest, ProxyFetchRequest, REQUIRED_EXTENSION_ABI, RemoteVideoElement, RequestHeaderRule, type SelectorPart, SiteCookie, StorageState, StorageStateCookie, TimeoutError, VideoElementState, WindowFrame, account_d_exports as account, assertAttachableFrameUrl, assertFetchableUrl, assertForgeableHeaders, assertLockdownApplicable, assertOneCookieIdentity, attachFramePermission, box, cloud_d_exports as cloud, connectButtonUrl, cookies, createFrame, createVideoElementHandle, desktop_d_exports as desktop, dgram_d_exports as dgram, dns_d_exports as dns, extension_d_exports as extension, fetch, fetchCredentialedPermission, fetchLocalPermission, fetchPermission, index_d_exports as fs, gotoPermission, handleRevivableModules, hasForgedCookie, http_d_exports as http, isBackgroundStopped, isBlockedFetchUrl, isBlockedFrameUrl, isExtensionExposed, isLocalNetworkUrl, isLocatorDenied, isLocatorInvalid, isLocatorUnsupported, isPermissionDenied, isTerminalError, isType, modifyRequestHeadersPermission, net_d_exports as net, index_d_exports$1 as opfs, packages_d_exports as packages, permissions, promptInstall, readCookiePermission, readExtensionHandshake, removeRequestHeaderRule, revive, rooms_d_exports as rooms, setMissingExtensionHandler, setRequestHeaderRule, shell_d_exports as shell, storage_d_exports as storage, supportsOperation, type, waitForExtensionExposure };