@fgv/ts-web-extras 5.0.2 → 5.1.0-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.
Files changed (208) hide show
  1. package/.rush/temp/81e0881271ff236956b2f52e8ca99da6574c6e1e.tar.log +223 -0
  2. package/.rush/temp/chunked-rush-logs/ts-web-extras.build.chunks.jsonl +35 -25
  3. package/.rush/temp/operation/build/all.log +35 -25
  4. package/.rush/temp/operation/build/log-chunks.jsonl +35 -25
  5. package/.rush/temp/operation/build/state.json +1 -1
  6. package/.rush/temp/shrinkwrap-deps.json +175 -163
  7. package/config/jest.config.json +4 -1
  8. package/config/typedoc.json +6 -0
  9. package/dist/index.js +2 -2
  10. package/dist/index.js.map +1 -1
  11. package/dist/packlets/crypto-utils/browserCryptoProvider.js +254 -0
  12. package/dist/packlets/crypto-utils/browserCryptoProvider.js.map +1 -0
  13. package/dist/packlets/crypto-utils/browserHashProvider.js.map +1 -0
  14. package/dist/packlets/{crypto → crypto-utils}/index.js +1 -0
  15. package/dist/packlets/crypto-utils/index.js.map +1 -0
  16. package/dist/packlets/file-api-types/index.js +27 -3
  17. package/dist/packlets/file-api-types/index.js.map +1 -1
  18. package/dist/packlets/file-tree/directoryHandleStore.js +124 -0
  19. package/dist/packlets/file-tree/directoryHandleStore.js.map +1 -0
  20. package/dist/packlets/file-tree/fileApiTreeAccessors.js +76 -0
  21. package/dist/packlets/file-tree/fileApiTreeAccessors.js.map +1 -1
  22. package/dist/packlets/file-tree/fileSystemAccessTreeAccessors.js +345 -0
  23. package/dist/packlets/file-tree/fileSystemAccessTreeAccessors.js.map +1 -0
  24. package/dist/packlets/file-tree/index.js +3 -0
  25. package/dist/packlets/file-tree/index.js.map +1 -1
  26. package/dist/packlets/file-tree/localStorageTreeAccessors.js +308 -0
  27. package/dist/packlets/file-tree/localStorageTreeAccessors.js.map +1 -0
  28. package/dist/test/mocks/idb-keyval.js +6 -0
  29. package/dist/test/mocks/idb-keyval.js.map +1 -0
  30. package/dist/test/unit/browserHashProvider.test.js +1 -1
  31. package/dist/test/unit/browserHashProvider.test.js.map +1 -1
  32. package/dist/test/unit/directoryHandleStore.test.js +190 -0
  33. package/dist/test/unit/directoryHandleStore.test.js.map +1 -0
  34. package/dist/test/unit/fileApiTypes.test.js +30 -0
  35. package/dist/test/unit/fileApiTypes.test.js.map +1 -1
  36. package/dist/test/unit/fileSystemAccessTreeAccessors.test.js +517 -0
  37. package/dist/test/unit/fileSystemAccessTreeAccessors.test.js.map +1 -0
  38. package/dist/test/unit/localStorageTreeAccessors.test.js +595 -0
  39. package/dist/test/unit/localStorageTreeAccessors.test.js.map +1 -0
  40. package/dist/test/utils/fileSystemAccessMocks.js +271 -0
  41. package/dist/test/utils/fileSystemAccessMocks.js.map +1 -0
  42. package/dist/ts-web-extras.d.ts +460 -1
  43. package/dist/tsdoc-metadata.json +1 -1
  44. package/docs/ts-web-extras.cryptoutils.browsercryptoprovider._constructor_.md +50 -0
  45. package/docs/ts-web-extras.cryptoutils.browsercryptoprovider.decrypt.md +104 -0
  46. package/docs/ts-web-extras.cryptoutils.browsercryptoprovider.derivekey.md +88 -0
  47. package/docs/ts-web-extras.cryptoutils.browsercryptoprovider.encrypt.md +72 -0
  48. package/docs/ts-web-extras.cryptoutils.browsercryptoprovider.frombase64.md +56 -0
  49. package/docs/ts-web-extras.cryptoutils.browsercryptoprovider.generatekey.md +19 -0
  50. package/docs/ts-web-extras.cryptoutils.browsercryptoprovider.generaterandombytes.md +56 -0
  51. package/docs/ts-web-extras.cryptoutils.browsercryptoprovider.md +169 -0
  52. package/docs/ts-web-extras.cryptoutils.browsercryptoprovider.tobase64.md +56 -0
  53. package/docs/{ts-web-extras.browserhashprovider.hashparts.md → ts-web-extras.cryptoutils.browserhashprovider.hashparts.md} +2 -2
  54. package/docs/{ts-web-extras.browserhashprovider.hashstring.md → ts-web-extras.cryptoutils.browserhashprovider.hashstring.md} +2 -2
  55. package/docs/{ts-web-extras.browserhashprovider.md → ts-web-extras.cryptoutils.browserhashprovider.md} +4 -4
  56. package/docs/ts-web-extras.cryptoutils.createbrowsercryptoprovider.md +19 -0
  57. package/docs/ts-web-extras.cryptoutils.md +71 -0
  58. package/docs/ts-web-extras.fileapitreeaccessors.createfromlocalstorage.md +74 -0
  59. package/docs/ts-web-extras.fileapitreeaccessors.createpersistent.md +76 -0
  60. package/docs/ts-web-extras.fileapitreeaccessors.md +32 -0
  61. package/docs/ts-web-extras.filesystemaccesstreeaccessors._constructor_.md +114 -0
  62. package/docs/ts-web-extras.filesystemaccesstreeaccessors.fileismutable.md +52 -0
  63. package/docs/ts-web-extras.filesystemaccesstreeaccessors.fromdirectoryhandle.md +72 -0
  64. package/docs/ts-web-extras.filesystemaccesstreeaccessors.getdirtypaths.md +17 -0
  65. package/docs/ts-web-extras.filesystemaccesstreeaccessors.isdirty.md +17 -0
  66. package/docs/ts-web-extras.filesystemaccesstreeaccessors.md +159 -0
  67. package/docs/ts-web-extras.filesystemaccesstreeaccessors.savefilecontents.md +66 -0
  68. package/docs/ts-web-extras.filesystemaccesstreeaccessors.synctodisk.md +17 -0
  69. package/docs/ts-web-extras.ifilesystemaccesstreeparams.autosync.md +13 -0
  70. package/docs/ts-web-extras.ifilesystemaccesstreeparams.md +78 -0
  71. package/docs/ts-web-extras.ifilesystemaccesstreeparams.requirewritepermission.md +13 -0
  72. package/docs/ts-web-extras.ilocalstoragetreeparams.autosync.md +13 -0
  73. package/docs/ts-web-extras.ilocalstoragetreeparams.md +97 -0
  74. package/docs/ts-web-extras.ilocalstoragetreeparams.pathtokeymap.md +13 -0
  75. package/docs/ts-web-extras.ilocalstoragetreeparams.storage.md +13 -0
  76. package/docs/ts-web-extras.localstoragetreeaccessors.fileismutable.md +56 -0
  77. package/docs/ts-web-extras.localstoragetreeaccessors.fromstorage.md +56 -0
  78. package/docs/ts-web-extras.localstoragetreeaccessors.getdirtypaths.md +19 -0
  79. package/docs/ts-web-extras.localstoragetreeaccessors.isdirty.md +19 -0
  80. package/docs/ts-web-extras.localstoragetreeaccessors.md +131 -0
  81. package/docs/ts-web-extras.localstoragetreeaccessors.savefilecontents.md +72 -0
  82. package/docs/ts-web-extras.localstoragetreeaccessors.synctodisk.md +19 -0
  83. package/docs/ts-web-extras.md +50 -4
  84. package/etc/ts-web-extras.api.md +91 -1
  85. package/lib/index.d.ts +2 -1
  86. package/lib/index.d.ts.map +1 -1
  87. package/lib/index.js +25 -2
  88. package/lib/index.js.map +1 -1
  89. package/lib/packlets/crypto-utils/browserCryptoProvider.d.ts +77 -0
  90. package/lib/packlets/crypto-utils/browserCryptoProvider.d.ts.map +1 -0
  91. package/lib/packlets/crypto-utils/browserCryptoProvider.js +259 -0
  92. package/lib/packlets/crypto-utils/browserCryptoProvider.js.map +1 -0
  93. package/lib/packlets/crypto-utils/browserHashProvider.d.ts.map +1 -0
  94. package/lib/packlets/crypto-utils/browserHashProvider.js.map +1 -0
  95. package/lib/packlets/{crypto → crypto-utils}/index.d.ts +1 -0
  96. package/lib/packlets/crypto-utils/index.d.ts.map +1 -0
  97. package/lib/packlets/{crypto → crypto-utils}/index.js +1 -0
  98. package/lib/packlets/crypto-utils/index.js.map +1 -0
  99. package/lib/packlets/file-api-types/index.d.ts.map +1 -1
  100. package/lib/packlets/file-api-types/index.js +27 -3
  101. package/lib/packlets/file-api-types/index.js.map +1 -1
  102. package/lib/packlets/file-tree/directoryHandleStore.d.ts +59 -0
  103. package/lib/packlets/file-tree/directoryHandleStore.d.ts.map +1 -0
  104. package/lib/packlets/file-tree/directoryHandleStore.js +128 -0
  105. package/lib/packlets/file-tree/directoryHandleStore.js.map +1 -0
  106. package/lib/packlets/file-tree/fileApiTreeAccessors.d.ts +57 -0
  107. package/lib/packlets/file-tree/fileApiTreeAccessors.d.ts.map +1 -1
  108. package/lib/packlets/file-tree/fileApiTreeAccessors.js +76 -0
  109. package/lib/packlets/file-tree/fileApiTreeAccessors.js.map +1 -1
  110. package/lib/packlets/file-tree/fileSystemAccessTreeAccessors.d.ts +136 -0
  111. package/lib/packlets/file-tree/fileSystemAccessTreeAccessors.d.ts.map +1 -0
  112. package/lib/packlets/file-tree/fileSystemAccessTreeAccessors.js +349 -0
  113. package/lib/packlets/file-tree/fileSystemAccessTreeAccessors.js.map +1 -0
  114. package/lib/packlets/file-tree/index.d.ts +3 -0
  115. package/lib/packlets/file-tree/index.d.ts.map +1 -1
  116. package/lib/packlets/file-tree/index.js +3 -0
  117. package/lib/packlets/file-tree/index.js.map +1 -1
  118. package/lib/packlets/file-tree/localStorageTreeAccessors.d.ts +129 -0
  119. package/lib/packlets/file-tree/localStorageTreeAccessors.d.ts.map +1 -0
  120. package/lib/packlets/file-tree/localStorageTreeAccessors.js +312 -0
  121. package/lib/packlets/file-tree/localStorageTreeAccessors.js.map +1 -0
  122. package/lib/test/mocks/idb-keyval.d.ts +6 -0
  123. package/lib/test/mocks/idb-keyval.d.ts.map +1 -0
  124. package/lib/test/mocks/idb-keyval.js +9 -0
  125. package/lib/test/mocks/idb-keyval.js.map +1 -0
  126. package/lib/test/unit/browserHashProvider.test.js +21 -21
  127. package/lib/test/unit/browserHashProvider.test.js.map +1 -1
  128. package/lib/test/unit/directoryHandleStore.test.d.ts +2 -0
  129. package/lib/test/unit/directoryHandleStore.test.d.ts.map +1 -0
  130. package/lib/test/unit/directoryHandleStore.test.js +192 -0
  131. package/lib/test/unit/directoryHandleStore.test.js.map +1 -0
  132. package/lib/test/unit/fileApiTypes.test.js +30 -0
  133. package/lib/test/unit/fileApiTypes.test.js.map +1 -1
  134. package/lib/test/unit/fileSystemAccessTreeAccessors.test.d.ts +2 -0
  135. package/lib/test/unit/fileSystemAccessTreeAccessors.test.d.ts.map +1 -0
  136. package/lib/test/unit/fileSystemAccessTreeAccessors.test.js +519 -0
  137. package/lib/test/unit/fileSystemAccessTreeAccessors.test.js.map +1 -0
  138. package/lib/test/unit/localStorageTreeAccessors.test.d.ts +2 -0
  139. package/lib/test/unit/localStorageTreeAccessors.test.d.ts.map +1 -0
  140. package/lib/test/unit/localStorageTreeAccessors.test.js +597 -0
  141. package/lib/test/unit/localStorageTreeAccessors.test.js.map +1 -0
  142. package/lib/test/utils/fileSystemAccessMocks.d.ts +53 -0
  143. package/lib/test/utils/fileSystemAccessMocks.d.ts.map +1 -0
  144. package/lib/test/utils/fileSystemAccessMocks.js +277 -0
  145. package/lib/test/utils/fileSystemAccessMocks.js.map +1 -0
  146. package/package.json +27 -20
  147. package/rush-logs/ts-web-extras.build.cache.log +3 -1
  148. package/rush-logs/ts-web-extras.build.log +35 -25
  149. package/src/index.ts +2 -2
  150. package/src/packlets/crypto-utils/browserCryptoProvider.ts +311 -0
  151. package/src/packlets/{crypto → crypto-utils}/index.ts +1 -0
  152. package/src/packlets/file-api-types/index.ts +24 -3
  153. package/src/packlets/file-tree/directoryHandleStore.ts +136 -0
  154. package/src/packlets/file-tree/fileApiTreeAccessors.ts +90 -0
  155. package/src/packlets/file-tree/fileSystemAccessTreeAccessors.ts +427 -0
  156. package/src/packlets/file-tree/index.ts +3 -0
  157. package/src/packlets/file-tree/localStorageTreeAccessors.ts +377 -0
  158. package/src/test/mocks/idb-keyval.ts +5 -0
  159. package/src/test/unit/browserHashProvider.test.ts +1 -1
  160. package/src/test/unit/directoryHandleStore.test.ts +251 -0
  161. package/src/test/unit/fileApiTypes.test.ts +36 -0
  162. package/src/test/unit/fileSystemAccessTreeAccessors.test.ts +732 -0
  163. package/src/test/unit/localStorageTreeAccessors.test.ts +746 -0
  164. package/src/test/utils/fileSystemAccessMocks.ts +353 -0
  165. package/temp/build/typescript/ts_8nwakTlr.json +1 -0
  166. package/temp/coverage/crypto-utils/browserCryptoProvider.ts.html +1018 -0
  167. package/temp/coverage/{crypto → crypto-utils}/browserHashProvider.ts.html +3 -3
  168. package/temp/coverage/{lcov-report/crypto → crypto-utils}/index.html +21 -6
  169. package/temp/coverage/file-tree/directoryHandleStore.ts.html +493 -0
  170. package/temp/coverage/file-tree/fileApiTreeAccessors.ts.html +276 -6
  171. package/temp/coverage/file-tree/fileSystemAccessTreeAccessors.ts.html +1366 -0
  172. package/temp/coverage/file-tree/index.html +55 -10
  173. package/temp/coverage/file-tree/localStorageTreeAccessors.ts.html +1216 -0
  174. package/temp/coverage/helpers/fileTreeHelpers.ts.html +1 -1
  175. package/temp/coverage/helpers/index.html +1 -1
  176. package/temp/coverage/index.html +15 -15
  177. package/temp/coverage/lcov-report/crypto-utils/browserCryptoProvider.ts.html +1018 -0
  178. package/temp/coverage/lcov-report/{crypto → crypto-utils}/browserHashProvider.ts.html +3 -3
  179. package/temp/coverage/{crypto → lcov-report/crypto-utils}/index.html +21 -6
  180. package/temp/coverage/lcov-report/file-tree/directoryHandleStore.ts.html +493 -0
  181. package/temp/coverage/lcov-report/file-tree/fileApiTreeAccessors.ts.html +276 -6
  182. package/temp/coverage/lcov-report/file-tree/fileSystemAccessTreeAccessors.ts.html +1366 -0
  183. package/temp/coverage/lcov-report/file-tree/index.html +55 -10
  184. package/temp/coverage/lcov-report/file-tree/localStorageTreeAccessors.ts.html +1216 -0
  185. package/temp/coverage/lcov-report/helpers/fileTreeHelpers.ts.html +1 -1
  186. package/temp/coverage/lcov-report/helpers/index.html +1 -1
  187. package/temp/coverage/lcov-report/index.html +15 -15
  188. package/temp/coverage/lcov-report/url-utils/index.html +1 -1
  189. package/temp/coverage/lcov-report/url-utils/urlParams.ts.html +1 -1
  190. package/temp/coverage/lcov.info +2128 -451
  191. package/temp/coverage/url-utils/index.html +1 -1
  192. package/temp/coverage/url-utils/urlParams.ts.html +1 -1
  193. package/temp/test/jest/haste-map-7492f1b44480e0cdd1f220078fb3afd8-c8dd6c3430605adeb2f1cadf4f75e791-8c9336785555d572065b28c111982ba4 +0 -0
  194. package/temp/test/jest/perf-cache-7492f1b44480e0cdd1f220078fb3afd8-da39a3ee5e6b4b0d3255bfef95601890 +1 -1
  195. package/temp/ts-web-extras.api.json +3236 -385
  196. package/temp/ts-web-extras.api.md +91 -1
  197. package/dist/packlets/crypto/browserHashProvider.js.map +0 -1
  198. package/dist/packlets/crypto/index.js.map +0 -1
  199. package/lib/packlets/crypto/browserHashProvider.d.ts.map +0 -1
  200. package/lib/packlets/crypto/browserHashProvider.js.map +0 -1
  201. package/lib/packlets/crypto/index.d.ts.map +0 -1
  202. package/lib/packlets/crypto/index.js.map +0 -1
  203. package/temp/build/typescript/ts_vnCx6LlY.json +0 -1
  204. /package/dist/packlets/{crypto → crypto-utils}/browserHashProvider.js +0 -0
  205. /package/lib/packlets/{crypto → crypto-utils}/browserHashProvider.d.ts +0 -0
  206. /package/lib/packlets/{crypto → crypto-utils}/browserHashProvider.js +0 -0
  207. /package/src/packlets/{crypto → crypto-utils}/browserHashProvider.ts +0 -0
  208. /package/temp/test/jest/jest-transform-cache-7492f1b44480e0cdd1f220078fb3afd8-79ef2876fae7ca75eedb2aa53dc48338/{0e/package_0eb6535f5987849d93ea51ef33a14cf6 → 8d/package_8dcbedef69e4299f0f51fcda8f4f1c8e} +0 -0
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "metadata": {
3
3
  "toolPackage": "@microsoft/api-extractor",
4
- "toolVersion": "7.54.0",
4
+ "toolVersion": "7.57.6",
5
5
  "schemaVersion": 1011,
6
6
  "oldestForwardsCompatibleVersion": 1001,
7
7
  "tsdocConfig": {
@@ -114,6 +114,22 @@
114
114
  "tagName": "@virtual",
115
115
  "syntaxKind": "modifier"
116
116
  },
117
+ {
118
+ "tagName": "@jsx",
119
+ "syntaxKind": "block"
120
+ },
121
+ {
122
+ "tagName": "@jsxRuntime",
123
+ "syntaxKind": "block"
124
+ },
125
+ {
126
+ "tagName": "@jsxFrag",
127
+ "syntaxKind": "block"
128
+ },
129
+ {
130
+ "tagName": "@jsxImportSource",
131
+ "syntaxKind": "block"
132
+ },
117
133
  {
118
134
  "tagName": "@betaDocumentation",
119
135
  "syntaxKind": "modifier"
@@ -172,38 +188,936 @@
172
188
  "name": "",
173
189
  "preserveMemberOrder": false,
174
190
  "members": [
191
+ {
192
+ "kind": "Namespace",
193
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils:namespace",
194
+ "docComment": "",
195
+ "excerptTokens": [],
196
+ "fileUrlPath": "src/index.ts",
197
+ "releaseTag": "None",
198
+ "name": "CryptoUtils",
199
+ "preserveMemberOrder": false,
200
+ "members": [
201
+ {
202
+ "kind": "Class",
203
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserCryptoProvider:class",
204
+ "docComment": "/**\n * Browser implementation of `ICryptoProvider` using the Web Crypto API. Uses AES-256-GCM for authenticated encryption.\n *\n * Note: This provider requires a browser environment with Web Crypto API support. In Node.js 15+, Web Crypto is available via globalThis.crypto or require('crypto').webcrypto.\n *\n * @public\n */\n",
205
+ "excerptTokens": [
206
+ {
207
+ "kind": "Content",
208
+ "text": "export declare class BrowserCryptoProvider implements "
209
+ },
210
+ {
211
+ "kind": "Reference",
212
+ "text": "ICryptoProvider",
213
+ "canonicalReference": "@fgv/ts-web-extras!~ICryptoProvider:type"
214
+ },
215
+ {
216
+ "kind": "Content",
217
+ "text": " "
218
+ }
219
+ ],
220
+ "fileUrlPath": "src/packlets/crypto-utils/browserCryptoProvider.ts",
221
+ "releaseTag": "Public",
222
+ "isAbstract": false,
223
+ "name": "BrowserCryptoProvider",
224
+ "preserveMemberOrder": false,
225
+ "members": [
226
+ {
227
+ "kind": "Constructor",
228
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserCryptoProvider:constructor(1)",
229
+ "docComment": "/**\n * Creates a new {@link CryptoUtils.BrowserCryptoProvider | BrowserCryptoProvider}.\n *\n * @param cryptoApi - Optional Crypto instance (defaults to globalThis.crypto)\n */\n",
230
+ "excerptTokens": [
231
+ {
232
+ "kind": "Content",
233
+ "text": "constructor(cryptoApi?: "
234
+ },
235
+ {
236
+ "kind": "Reference",
237
+ "text": "Crypto",
238
+ "canonicalReference": "!Crypto:interface"
239
+ },
240
+ {
241
+ "kind": "Content",
242
+ "text": ");"
243
+ }
244
+ ],
245
+ "releaseTag": "Public",
246
+ "isProtected": false,
247
+ "overloadIndex": 1,
248
+ "parameters": [
249
+ {
250
+ "parameterName": "cryptoApi",
251
+ "parameterTypeTokenRange": {
252
+ "startIndex": 1,
253
+ "endIndex": 2
254
+ },
255
+ "isOptional": true
256
+ }
257
+ ]
258
+ },
259
+ {
260
+ "kind": "Method",
261
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserCryptoProvider#decrypt:member(1)",
262
+ "docComment": "/**\n * Decrypts ciphertext using AES-256-GCM.\n *\n * @param encryptedData - Encrypted bytes\n *\n * @param key - 32-byte decryption key\n *\n * @param iv - Initialization vector (12 bytes)\n *\n * @param authTag - GCM authentication tag (16 bytes)\n *\n * @returns `Success` with decrypted UTF-8 string, or `Failure` with an error.\n */\n",
263
+ "excerptTokens": [
264
+ {
265
+ "kind": "Content",
266
+ "text": "decrypt(encryptedData: "
267
+ },
268
+ {
269
+ "kind": "Reference",
270
+ "text": "Uint8Array",
271
+ "canonicalReference": "!Uint8Array:interface"
272
+ },
273
+ {
274
+ "kind": "Content",
275
+ "text": ", key: "
276
+ },
277
+ {
278
+ "kind": "Reference",
279
+ "text": "Uint8Array",
280
+ "canonicalReference": "!Uint8Array:interface"
281
+ },
282
+ {
283
+ "kind": "Content",
284
+ "text": ", iv: "
285
+ },
286
+ {
287
+ "kind": "Reference",
288
+ "text": "Uint8Array",
289
+ "canonicalReference": "!Uint8Array:interface"
290
+ },
291
+ {
292
+ "kind": "Content",
293
+ "text": ", authTag: "
294
+ },
295
+ {
296
+ "kind": "Reference",
297
+ "text": "Uint8Array",
298
+ "canonicalReference": "!Uint8Array:interface"
299
+ },
300
+ {
301
+ "kind": "Content",
302
+ "text": "): "
303
+ },
304
+ {
305
+ "kind": "Reference",
306
+ "text": "Promise",
307
+ "canonicalReference": "!Promise:interface"
308
+ },
309
+ {
310
+ "kind": "Content",
311
+ "text": "<"
312
+ },
313
+ {
314
+ "kind": "Reference",
315
+ "text": "Result",
316
+ "canonicalReference": "@fgv/ts-utils!Result:type"
317
+ },
318
+ {
319
+ "kind": "Content",
320
+ "text": "<string>>"
321
+ },
322
+ {
323
+ "kind": "Content",
324
+ "text": ";"
325
+ }
326
+ ],
327
+ "isStatic": false,
328
+ "returnTypeTokenRange": {
329
+ "startIndex": 9,
330
+ "endIndex": 13
331
+ },
332
+ "releaseTag": "Public",
333
+ "isProtected": false,
334
+ "overloadIndex": 1,
335
+ "parameters": [
336
+ {
337
+ "parameterName": "encryptedData",
338
+ "parameterTypeTokenRange": {
339
+ "startIndex": 1,
340
+ "endIndex": 2
341
+ },
342
+ "isOptional": false
343
+ },
344
+ {
345
+ "parameterName": "key",
346
+ "parameterTypeTokenRange": {
347
+ "startIndex": 3,
348
+ "endIndex": 4
349
+ },
350
+ "isOptional": false
351
+ },
352
+ {
353
+ "parameterName": "iv",
354
+ "parameterTypeTokenRange": {
355
+ "startIndex": 5,
356
+ "endIndex": 6
357
+ },
358
+ "isOptional": false
359
+ },
360
+ {
361
+ "parameterName": "authTag",
362
+ "parameterTypeTokenRange": {
363
+ "startIndex": 7,
364
+ "endIndex": 8
365
+ },
366
+ "isOptional": false
367
+ }
368
+ ],
369
+ "isOptional": false,
370
+ "isAbstract": false,
371
+ "name": "decrypt"
372
+ },
373
+ {
374
+ "kind": "Method",
375
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserCryptoProvider#deriveKey:member(1)",
376
+ "docComment": "/**\n * Derives a key from a password using PBKDF2.\n *\n * @param password - Password string\n *\n * @param salt - Salt bytes (should be at least 16 bytes)\n *\n * @param iterations - Number of iterations (recommend 100000+)\n *\n * @returns Success with derived 32-byte key, or Failure with error\n */\n",
377
+ "excerptTokens": [
378
+ {
379
+ "kind": "Content",
380
+ "text": "deriveKey(password: "
381
+ },
382
+ {
383
+ "kind": "Content",
384
+ "text": "string"
385
+ },
386
+ {
387
+ "kind": "Content",
388
+ "text": ", salt: "
389
+ },
390
+ {
391
+ "kind": "Reference",
392
+ "text": "Uint8Array",
393
+ "canonicalReference": "!Uint8Array:interface"
394
+ },
395
+ {
396
+ "kind": "Content",
397
+ "text": ", iterations: "
398
+ },
399
+ {
400
+ "kind": "Content",
401
+ "text": "number"
402
+ },
403
+ {
404
+ "kind": "Content",
405
+ "text": "): "
406
+ },
407
+ {
408
+ "kind": "Reference",
409
+ "text": "Promise",
410
+ "canonicalReference": "!Promise:interface"
411
+ },
412
+ {
413
+ "kind": "Content",
414
+ "text": "<"
415
+ },
416
+ {
417
+ "kind": "Reference",
418
+ "text": "Result",
419
+ "canonicalReference": "@fgv/ts-utils!Result:type"
420
+ },
421
+ {
422
+ "kind": "Content",
423
+ "text": "<"
424
+ },
425
+ {
426
+ "kind": "Reference",
427
+ "text": "Uint8Array",
428
+ "canonicalReference": "!Uint8Array:interface"
429
+ },
430
+ {
431
+ "kind": "Content",
432
+ "text": ">>"
433
+ },
434
+ {
435
+ "kind": "Content",
436
+ "text": ";"
437
+ }
438
+ ],
439
+ "isStatic": false,
440
+ "returnTypeTokenRange": {
441
+ "startIndex": 7,
442
+ "endIndex": 13
443
+ },
444
+ "releaseTag": "Public",
445
+ "isProtected": false,
446
+ "overloadIndex": 1,
447
+ "parameters": [
448
+ {
449
+ "parameterName": "password",
450
+ "parameterTypeTokenRange": {
451
+ "startIndex": 1,
452
+ "endIndex": 2
453
+ },
454
+ "isOptional": false
455
+ },
456
+ {
457
+ "parameterName": "salt",
458
+ "parameterTypeTokenRange": {
459
+ "startIndex": 3,
460
+ "endIndex": 4
461
+ },
462
+ "isOptional": false
463
+ },
464
+ {
465
+ "parameterName": "iterations",
466
+ "parameterTypeTokenRange": {
467
+ "startIndex": 5,
468
+ "endIndex": 6
469
+ },
470
+ "isOptional": false
471
+ }
472
+ ],
473
+ "isOptional": false,
474
+ "isAbstract": false,
475
+ "name": "deriveKey"
476
+ },
477
+ {
478
+ "kind": "Method",
479
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserCryptoProvider#encrypt:member(1)",
480
+ "docComment": "/**\n * Encrypts plaintext using AES-256-GCM.\n *\n * @param plaintext - UTF-8 string to encrypt\n *\n * @param key - 32-byte encryption key\n *\n * @returns `Success` with encryption result, or `Failure` with an error.\n */\n",
481
+ "excerptTokens": [
482
+ {
483
+ "kind": "Content",
484
+ "text": "encrypt(plaintext: "
485
+ },
486
+ {
487
+ "kind": "Content",
488
+ "text": "string"
489
+ },
490
+ {
491
+ "kind": "Content",
492
+ "text": ", key: "
493
+ },
494
+ {
495
+ "kind": "Reference",
496
+ "text": "Uint8Array",
497
+ "canonicalReference": "!Uint8Array:interface"
498
+ },
499
+ {
500
+ "kind": "Content",
501
+ "text": "): "
502
+ },
503
+ {
504
+ "kind": "Reference",
505
+ "text": "Promise",
506
+ "canonicalReference": "!Promise:interface"
507
+ },
508
+ {
509
+ "kind": "Content",
510
+ "text": "<"
511
+ },
512
+ {
513
+ "kind": "Reference",
514
+ "text": "Result",
515
+ "canonicalReference": "@fgv/ts-utils!Result:type"
516
+ },
517
+ {
518
+ "kind": "Content",
519
+ "text": "<"
520
+ },
521
+ {
522
+ "kind": "Reference",
523
+ "text": "IEncryptionResult",
524
+ "canonicalReference": "@fgv/ts-web-extras!~IEncryptionResult:type"
525
+ },
526
+ {
527
+ "kind": "Content",
528
+ "text": ">>"
529
+ },
530
+ {
531
+ "kind": "Content",
532
+ "text": ";"
533
+ }
534
+ ],
535
+ "isStatic": false,
536
+ "returnTypeTokenRange": {
537
+ "startIndex": 5,
538
+ "endIndex": 11
539
+ },
540
+ "releaseTag": "Public",
541
+ "isProtected": false,
542
+ "overloadIndex": 1,
543
+ "parameters": [
544
+ {
545
+ "parameterName": "plaintext",
546
+ "parameterTypeTokenRange": {
547
+ "startIndex": 1,
548
+ "endIndex": 2
549
+ },
550
+ "isOptional": false
551
+ },
552
+ {
553
+ "parameterName": "key",
554
+ "parameterTypeTokenRange": {
555
+ "startIndex": 3,
556
+ "endIndex": 4
557
+ },
558
+ "isOptional": false
559
+ }
560
+ ],
561
+ "isOptional": false,
562
+ "isAbstract": false,
563
+ "name": "encrypt"
564
+ },
565
+ {
566
+ "kind": "Method",
567
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserCryptoProvider#fromBase64:member(1)",
568
+ "docComment": "/**\n * Decodes base64 string to binary data.\n *\n * @param base64 - Base64-encoded string\n *\n * @returns Success with decoded bytes, or Failure if invalid base64\n */\n",
569
+ "excerptTokens": [
570
+ {
571
+ "kind": "Content",
572
+ "text": "fromBase64(base64: "
573
+ },
574
+ {
575
+ "kind": "Content",
576
+ "text": "string"
577
+ },
578
+ {
579
+ "kind": "Content",
580
+ "text": "): "
581
+ },
582
+ {
583
+ "kind": "Reference",
584
+ "text": "Result",
585
+ "canonicalReference": "@fgv/ts-utils!Result:type"
586
+ },
587
+ {
588
+ "kind": "Content",
589
+ "text": "<"
590
+ },
591
+ {
592
+ "kind": "Reference",
593
+ "text": "Uint8Array",
594
+ "canonicalReference": "!Uint8Array:interface"
595
+ },
596
+ {
597
+ "kind": "Content",
598
+ "text": ">"
599
+ },
600
+ {
601
+ "kind": "Content",
602
+ "text": ";"
603
+ }
604
+ ],
605
+ "isStatic": false,
606
+ "returnTypeTokenRange": {
607
+ "startIndex": 3,
608
+ "endIndex": 7
609
+ },
610
+ "releaseTag": "Public",
611
+ "isProtected": false,
612
+ "overloadIndex": 1,
613
+ "parameters": [
614
+ {
615
+ "parameterName": "base64",
616
+ "parameterTypeTokenRange": {
617
+ "startIndex": 1,
618
+ "endIndex": 2
619
+ },
620
+ "isOptional": false
621
+ }
622
+ ],
623
+ "isOptional": false,
624
+ "isAbstract": false,
625
+ "name": "fromBase64"
626
+ },
627
+ {
628
+ "kind": "Method",
629
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserCryptoProvider#generateKey:member(1)",
630
+ "docComment": "/**\n * Generates a random 32-byte key suitable for AES-256.\n *\n * @returns Success with generated key, or Failure with error\n */\n",
631
+ "excerptTokens": [
632
+ {
633
+ "kind": "Content",
634
+ "text": "generateKey(): "
635
+ },
636
+ {
637
+ "kind": "Reference",
638
+ "text": "Promise",
639
+ "canonicalReference": "!Promise:interface"
640
+ },
641
+ {
642
+ "kind": "Content",
643
+ "text": "<"
644
+ },
645
+ {
646
+ "kind": "Reference",
647
+ "text": "Result",
648
+ "canonicalReference": "@fgv/ts-utils!Result:type"
649
+ },
650
+ {
651
+ "kind": "Content",
652
+ "text": "<"
653
+ },
654
+ {
655
+ "kind": "Reference",
656
+ "text": "Uint8Array",
657
+ "canonicalReference": "!Uint8Array:interface"
658
+ },
659
+ {
660
+ "kind": "Content",
661
+ "text": ">>"
662
+ },
663
+ {
664
+ "kind": "Content",
665
+ "text": ";"
666
+ }
667
+ ],
668
+ "isStatic": false,
669
+ "returnTypeTokenRange": {
670
+ "startIndex": 1,
671
+ "endIndex": 7
672
+ },
673
+ "releaseTag": "Public",
674
+ "isProtected": false,
675
+ "overloadIndex": 1,
676
+ "parameters": [],
677
+ "isOptional": false,
678
+ "isAbstract": false,
679
+ "name": "generateKey"
680
+ },
681
+ {
682
+ "kind": "Method",
683
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserCryptoProvider#generateRandomBytes:member(1)",
684
+ "docComment": "/**\n * Generates cryptographically secure random bytes.\n *\n * @param length - Number of bytes to generate\n *\n * @returns Success with random bytes, or Failure with error\n */\n",
685
+ "excerptTokens": [
686
+ {
687
+ "kind": "Content",
688
+ "text": "generateRandomBytes(length: "
689
+ },
690
+ {
691
+ "kind": "Content",
692
+ "text": "number"
693
+ },
694
+ {
695
+ "kind": "Content",
696
+ "text": "): "
697
+ },
698
+ {
699
+ "kind": "Reference",
700
+ "text": "Result",
701
+ "canonicalReference": "@fgv/ts-utils!Result:type"
702
+ },
703
+ {
704
+ "kind": "Content",
705
+ "text": "<"
706
+ },
707
+ {
708
+ "kind": "Reference",
709
+ "text": "Uint8Array",
710
+ "canonicalReference": "!Uint8Array:interface"
711
+ },
712
+ {
713
+ "kind": "Content",
714
+ "text": ">"
715
+ },
716
+ {
717
+ "kind": "Content",
718
+ "text": ";"
719
+ }
720
+ ],
721
+ "isStatic": false,
722
+ "returnTypeTokenRange": {
723
+ "startIndex": 3,
724
+ "endIndex": 7
725
+ },
726
+ "releaseTag": "Public",
727
+ "isProtected": false,
728
+ "overloadIndex": 1,
729
+ "parameters": [
730
+ {
731
+ "parameterName": "length",
732
+ "parameterTypeTokenRange": {
733
+ "startIndex": 1,
734
+ "endIndex": 2
735
+ },
736
+ "isOptional": false
737
+ }
738
+ ],
739
+ "isOptional": false,
740
+ "isAbstract": false,
741
+ "name": "generateRandomBytes"
742
+ },
743
+ {
744
+ "kind": "Method",
745
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserCryptoProvider#toBase64:member(1)",
746
+ "docComment": "/**\n * Encodes binary data to base64 string.\n *\n * @param data - Binary data to encode\n *\n * @returns Base64-encoded string\n */\n",
747
+ "excerptTokens": [
748
+ {
749
+ "kind": "Content",
750
+ "text": "toBase64(data: "
751
+ },
752
+ {
753
+ "kind": "Reference",
754
+ "text": "Uint8Array",
755
+ "canonicalReference": "!Uint8Array:interface"
756
+ },
757
+ {
758
+ "kind": "Content",
759
+ "text": "): "
760
+ },
761
+ {
762
+ "kind": "Content",
763
+ "text": "string"
764
+ },
765
+ {
766
+ "kind": "Content",
767
+ "text": ";"
768
+ }
769
+ ],
770
+ "isStatic": false,
771
+ "returnTypeTokenRange": {
772
+ "startIndex": 3,
773
+ "endIndex": 4
774
+ },
775
+ "releaseTag": "Public",
776
+ "isProtected": false,
777
+ "overloadIndex": 1,
778
+ "parameters": [
779
+ {
780
+ "parameterName": "data",
781
+ "parameterTypeTokenRange": {
782
+ "startIndex": 1,
783
+ "endIndex": 2
784
+ },
785
+ "isOptional": false
786
+ }
787
+ ],
788
+ "isOptional": false,
789
+ "isAbstract": false,
790
+ "name": "toBase64"
791
+ }
792
+ ],
793
+ "implementsTokenRanges": [
794
+ {
795
+ "startIndex": 1,
796
+ "endIndex": 2
797
+ }
798
+ ]
799
+ },
800
+ {
801
+ "kind": "Class",
802
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserHashProvider:class",
803
+ "docComment": "/**\n * Browser-compatible hash provider using the Web Crypto API. Supports common hash algorithms available in browsers.\n *\n * @public\n */\n",
804
+ "excerptTokens": [
805
+ {
806
+ "kind": "Content",
807
+ "text": "export declare class BrowserHashProvider "
808
+ }
809
+ ],
810
+ "fileUrlPath": "src/packlets/crypto-utils/browserHashProvider.ts",
811
+ "releaseTag": "Public",
812
+ "isAbstract": false,
813
+ "name": "BrowserHashProvider",
814
+ "preserveMemberOrder": false,
815
+ "members": [
816
+ {
817
+ "kind": "Method",
818
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserHashProvider.hashParts:member(1)",
819
+ "docComment": "/**\n * Hash multiple strings concatenated with a separator.\n *\n * @param parts - Array of strings to concatenate and hash\n *\n * @param algorithm - The hash algorithm to use\n *\n * @param separator - Separator to use between parts (default: '|')\n *\n * @returns Promise resolving to the hex-encoded hash\n */\n",
820
+ "excerptTokens": [
821
+ {
822
+ "kind": "Content",
823
+ "text": "static hashParts(parts: "
824
+ },
825
+ {
826
+ "kind": "Content",
827
+ "text": "string[]"
828
+ },
829
+ {
830
+ "kind": "Content",
831
+ "text": ", algorithm?: "
832
+ },
833
+ {
834
+ "kind": "Content",
835
+ "text": "string"
836
+ },
837
+ {
838
+ "kind": "Content",
839
+ "text": ", separator?: "
840
+ },
841
+ {
842
+ "kind": "Content",
843
+ "text": "string"
844
+ },
845
+ {
846
+ "kind": "Content",
847
+ "text": "): "
848
+ },
849
+ {
850
+ "kind": "Reference",
851
+ "text": "Promise",
852
+ "canonicalReference": "!Promise:interface"
853
+ },
854
+ {
855
+ "kind": "Content",
856
+ "text": "<"
857
+ },
858
+ {
859
+ "kind": "Reference",
860
+ "text": "Result",
861
+ "canonicalReference": "@fgv/ts-utils!Result:type"
862
+ },
863
+ {
864
+ "kind": "Content",
865
+ "text": "<string>>"
866
+ },
867
+ {
868
+ "kind": "Content",
869
+ "text": ";"
870
+ }
871
+ ],
872
+ "isStatic": true,
873
+ "returnTypeTokenRange": {
874
+ "startIndex": 7,
875
+ "endIndex": 11
876
+ },
877
+ "releaseTag": "Public",
878
+ "isProtected": false,
879
+ "overloadIndex": 1,
880
+ "parameters": [
881
+ {
882
+ "parameterName": "parts",
883
+ "parameterTypeTokenRange": {
884
+ "startIndex": 1,
885
+ "endIndex": 2
886
+ },
887
+ "isOptional": false
888
+ },
889
+ {
890
+ "parameterName": "algorithm",
891
+ "parameterTypeTokenRange": {
892
+ "startIndex": 3,
893
+ "endIndex": 4
894
+ },
895
+ "isOptional": true
896
+ },
897
+ {
898
+ "parameterName": "separator",
899
+ "parameterTypeTokenRange": {
900
+ "startIndex": 5,
901
+ "endIndex": 6
902
+ },
903
+ "isOptional": true
904
+ }
905
+ ],
906
+ "isOptional": false,
907
+ "isAbstract": false,
908
+ "name": "hashParts"
909
+ },
910
+ {
911
+ "kind": "Method",
912
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserHashProvider.hashString:member(1)",
913
+ "docComment": "/**\n * Hash a string using the specified algorithm.\n *\n * @param data - The string to hash\n *\n * @param algorithm - The hash algorithm to use\n *\n * @returns Promise resolving to the hex-encoded hash\n */\n",
914
+ "excerptTokens": [
915
+ {
916
+ "kind": "Content",
917
+ "text": "static hashString(data: "
918
+ },
919
+ {
920
+ "kind": "Content",
921
+ "text": "string"
922
+ },
923
+ {
924
+ "kind": "Content",
925
+ "text": ", algorithm?: "
926
+ },
927
+ {
928
+ "kind": "Content",
929
+ "text": "string"
930
+ },
931
+ {
932
+ "kind": "Content",
933
+ "text": "): "
934
+ },
935
+ {
936
+ "kind": "Reference",
937
+ "text": "Promise",
938
+ "canonicalReference": "!Promise:interface"
939
+ },
940
+ {
941
+ "kind": "Content",
942
+ "text": "<"
943
+ },
944
+ {
945
+ "kind": "Reference",
946
+ "text": "Result",
947
+ "canonicalReference": "@fgv/ts-utils!Result:type"
948
+ },
949
+ {
950
+ "kind": "Content",
951
+ "text": "<string>>"
952
+ },
953
+ {
954
+ "kind": "Content",
955
+ "text": ";"
956
+ }
957
+ ],
958
+ "isStatic": true,
959
+ "returnTypeTokenRange": {
960
+ "startIndex": 5,
961
+ "endIndex": 9
962
+ },
963
+ "releaseTag": "Public",
964
+ "isProtected": false,
965
+ "overloadIndex": 1,
966
+ "parameters": [
967
+ {
968
+ "parameterName": "data",
969
+ "parameterTypeTokenRange": {
970
+ "startIndex": 1,
971
+ "endIndex": 2
972
+ },
973
+ "isOptional": false
974
+ },
975
+ {
976
+ "parameterName": "algorithm",
977
+ "parameterTypeTokenRange": {
978
+ "startIndex": 3,
979
+ "endIndex": 4
980
+ },
981
+ "isOptional": true
982
+ }
983
+ ],
984
+ "isOptional": false,
985
+ "isAbstract": false,
986
+ "name": "hashString"
987
+ }
988
+ ],
989
+ "implementsTokenRanges": []
990
+ },
991
+ {
992
+ "kind": "Function",
993
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.createBrowserCryptoProvider:function(1)",
994
+ "docComment": "/**\n * Creates a {@link CryptoUtils.BrowserCryptoProvider | BrowserCryptoProvider} if Web Crypto API is available.\n *\n * @returns `Success` with provider, or `Failure` if not available\n *\n * @public\n */\n",
995
+ "excerptTokens": [
996
+ {
997
+ "kind": "Content",
998
+ "text": "export declare function createBrowserCryptoProvider(): "
999
+ },
1000
+ {
1001
+ "kind": "Reference",
1002
+ "text": "Result",
1003
+ "canonicalReference": "@fgv/ts-utils!Result:type"
1004
+ },
1005
+ {
1006
+ "kind": "Content",
1007
+ "text": "<"
1008
+ },
1009
+ {
1010
+ "kind": "Reference",
1011
+ "text": "BrowserCryptoProvider",
1012
+ "canonicalReference": "@fgv/ts-web-extras!CryptoUtils.BrowserCryptoProvider:class"
1013
+ },
1014
+ {
1015
+ "kind": "Content",
1016
+ "text": ">"
1017
+ },
1018
+ {
1019
+ "kind": "Content",
1020
+ "text": ";"
1021
+ }
1022
+ ],
1023
+ "fileUrlPath": "src/packlets/crypto-utils/browserCryptoProvider.ts",
1024
+ "returnTypeTokenRange": {
1025
+ "startIndex": 1,
1026
+ "endIndex": 5
1027
+ },
1028
+ "releaseTag": "Public",
1029
+ "overloadIndex": 1,
1030
+ "parameters": [],
1031
+ "name": "createBrowserCryptoProvider"
1032
+ }
1033
+ ]
1034
+ },
1035
+ {
1036
+ "kind": "Variable",
1037
+ "canonicalReference": "@fgv/ts-web-extras!DEFAULT_DIRECTORY_HANDLE_DB:var",
1038
+ "docComment": "/**\n * Default IndexedDB database name for directory handles.\n *\n * @public\n */\n",
1039
+ "excerptTokens": [
1040
+ {
1041
+ "kind": "Content",
1042
+ "text": "DEFAULT_DIRECTORY_HANDLE_DB = "
1043
+ },
1044
+ {
1045
+ "kind": "Content",
1046
+ "text": "\"chocolate-lab-storage\""
1047
+ }
1048
+ ],
1049
+ "fileUrlPath": "src/packlets/file-tree/directoryHandleStore.ts",
1050
+ "initializerTokenRange": {
1051
+ "startIndex": 1,
1052
+ "endIndex": 2
1053
+ },
1054
+ "isReadonly": true,
1055
+ "releaseTag": "Public",
1056
+ "name": "DEFAULT_DIRECTORY_HANDLE_DB",
1057
+ "variableTypeTokenRange": {
1058
+ "startIndex": 0,
1059
+ "endIndex": 0
1060
+ }
1061
+ },
1062
+ {
1063
+ "kind": "Variable",
1064
+ "canonicalReference": "@fgv/ts-web-extras!DEFAULT_DIRECTORY_HANDLE_STORE:var",
1065
+ "docComment": "/**\n * Default IndexedDB store name for directory handles.\n *\n * @public\n */\n",
1066
+ "excerptTokens": [
1067
+ {
1068
+ "kind": "Content",
1069
+ "text": "DEFAULT_DIRECTORY_HANDLE_STORE = "
1070
+ },
1071
+ {
1072
+ "kind": "Content",
1073
+ "text": "\"directory-handles\""
1074
+ }
1075
+ ],
1076
+ "fileUrlPath": "src/packlets/file-tree/directoryHandleStore.ts",
1077
+ "initializerTokenRange": {
1078
+ "startIndex": 1,
1079
+ "endIndex": 2
1080
+ },
1081
+ "isReadonly": true,
1082
+ "releaseTag": "Public",
1083
+ "name": "DEFAULT_DIRECTORY_HANDLE_STORE",
1084
+ "variableTypeTokenRange": {
1085
+ "startIndex": 0,
1086
+ "endIndex": 0
1087
+ }
1088
+ },
175
1089
  {
176
1090
  "kind": "Class",
177
- "canonicalReference": "@fgv/ts-web-extras!BrowserHashProvider:class",
178
- "docComment": "/**\n * Browser-compatible hash provider using the Web Crypto API. Supports common hash algorithms available in browsers.\n *\n * @public\n */\n",
1091
+ "canonicalReference": "@fgv/ts-web-extras!DirectoryHandleStore:class",
1092
+ "docComment": "/**\n * Manages persistence of {@link FileSystemDirectoryHandle} objects in IndexedDB. Keyed by a label (typically the directory name).\n *\n * @public\n */\n",
179
1093
  "excerptTokens": [
180
1094
  {
181
1095
  "kind": "Content",
182
- "text": "export declare class BrowserHashProvider "
1096
+ "text": "export declare class DirectoryHandleStore "
183
1097
  }
184
1098
  ],
185
- "fileUrlPath": "src/packlets/crypto/browserHashProvider.ts",
1099
+ "fileUrlPath": "src/packlets/file-tree/directoryHandleStore.ts",
186
1100
  "releaseTag": "Public",
187
1101
  "isAbstract": false,
188
- "name": "BrowserHashProvider",
1102
+ "name": "DirectoryHandleStore",
189
1103
  "preserveMemberOrder": false,
190
1104
  "members": [
191
1105
  {
192
- "kind": "Method",
193
- "canonicalReference": "@fgv/ts-web-extras!BrowserHashProvider.hashParts:member(1)",
194
- "docComment": "/**\n * Hash multiple strings concatenated with a separator.\n *\n * @param parts - Array of strings to concatenate and hash\n *\n * @param algorithm - The hash algorithm to use\n *\n * @param separator - Separator to use between parts (default: '|')\n *\n * @returns Promise resolving to the hex-encoded hash\n */\n",
1106
+ "kind": "Constructor",
1107
+ "canonicalReference": "@fgv/ts-web-extras!DirectoryHandleStore:constructor(1)",
1108
+ "docComment": "/**\n * Constructs a new instance of the `DirectoryHandleStore` class\n */\n",
195
1109
  "excerptTokens": [
196
1110
  {
197
1111
  "kind": "Content",
198
- "text": "static hashParts(parts: "
1112
+ "text": "constructor(dbName?: "
199
1113
  },
200
1114
  {
201
1115
  "kind": "Content",
202
- "text": "string[]"
1116
+ "text": "string"
203
1117
  },
204
1118
  {
205
1119
  "kind": "Content",
206
- "text": ", algorithm?: "
1120
+ "text": ", storeName?: "
207
1121
  },
208
1122
  {
209
1123
  "kind": "Content",
@@ -211,15 +1125,39 @@
211
1125
  },
212
1126
  {
213
1127
  "kind": "Content",
214
- "text": ", separator?: "
215
- },
1128
+ "text": ");"
1129
+ }
1130
+ ],
1131
+ "releaseTag": "Public",
1132
+ "isProtected": false,
1133
+ "overloadIndex": 1,
1134
+ "parameters": [
216
1135
  {
217
- "kind": "Content",
218
- "text": "string"
1136
+ "parameterName": "dbName",
1137
+ "parameterTypeTokenRange": {
1138
+ "startIndex": 1,
1139
+ "endIndex": 2
1140
+ },
1141
+ "isOptional": true
219
1142
  },
1143
+ {
1144
+ "parameterName": "storeName",
1145
+ "parameterTypeTokenRange": {
1146
+ "startIndex": 3,
1147
+ "endIndex": 4
1148
+ },
1149
+ "isOptional": true
1150
+ }
1151
+ ]
1152
+ },
1153
+ {
1154
+ "kind": "Method",
1155
+ "canonicalReference": "@fgv/ts-web-extras!DirectoryHandleStore#getAll:member(1)",
1156
+ "docComment": "/**\n * Returns all stored handles as label/handle pairs.\n *\n * @returns Success with array of entries, or Failure\n */\n",
1157
+ "excerptTokens": [
220
1158
  {
221
1159
  "kind": "Content",
222
- "text": "): "
1160
+ "text": "getAll(): "
223
1161
  },
224
1162
  {
225
1163
  "kind": "Reference",
@@ -237,67 +1175,97 @@
237
1175
  },
238
1176
  {
239
1177
  "kind": "Content",
240
- "text": "<string>>"
1178
+ "text": "<"
1179
+ },
1180
+ {
1181
+ "kind": "Reference",
1182
+ "text": "Array",
1183
+ "canonicalReference": "!Array:interface"
1184
+ },
1185
+ {
1186
+ "kind": "Content",
1187
+ "text": "<{\n label: string;\n handle: "
1188
+ },
1189
+ {
1190
+ "kind": "Reference",
1191
+ "text": "FileSystemDirectoryHandle",
1192
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemDirectoryHandle_2:interface"
1193
+ },
1194
+ {
1195
+ "kind": "Content",
1196
+ "text": ";\n }>>>"
241
1197
  },
242
1198
  {
243
1199
  "kind": "Content",
244
1200
  "text": ";"
245
1201
  }
246
1202
  ],
247
- "isStatic": true,
1203
+ "isStatic": false,
248
1204
  "returnTypeTokenRange": {
249
- "startIndex": 7,
250
- "endIndex": 11
1205
+ "startIndex": 1,
1206
+ "endIndex": 9
251
1207
  },
252
1208
  "releaseTag": "Public",
253
1209
  "isProtected": false,
254
1210
  "overloadIndex": 1,
255
- "parameters": [
1211
+ "parameters": [],
1212
+ "isOptional": false,
1213
+ "isAbstract": false,
1214
+ "name": "getAll"
1215
+ },
1216
+ {
1217
+ "kind": "Method",
1218
+ "canonicalReference": "@fgv/ts-web-extras!DirectoryHandleStore#getAllLabels:member(1)",
1219
+ "docComment": "/**\n * Returns all stored labels (keys).\n *\n * @returns Success with array of labels, or Failure\n */\n",
1220
+ "excerptTokens": [
256
1221
  {
257
- "parameterName": "parts",
258
- "parameterTypeTokenRange": {
259
- "startIndex": 1,
260
- "endIndex": 2
261
- },
262
- "isOptional": false
1222
+ "kind": "Content",
1223
+ "text": "getAllLabels(): "
263
1224
  },
264
1225
  {
265
- "parameterName": "algorithm",
266
- "parameterTypeTokenRange": {
267
- "startIndex": 3,
268
- "endIndex": 4
269
- },
270
- "isOptional": true
1226
+ "kind": "Reference",
1227
+ "text": "Promise",
1228
+ "canonicalReference": "!Promise:interface"
271
1229
  },
272
1230
  {
273
- "parameterName": "separator",
274
- "parameterTypeTokenRange": {
275
- "startIndex": 5,
276
- "endIndex": 6
277
- },
278
- "isOptional": true
1231
+ "kind": "Content",
1232
+ "text": "<"
1233
+ },
1234
+ {
1235
+ "kind": "Reference",
1236
+ "text": "Result",
1237
+ "canonicalReference": "@fgv/ts-utils!Result:type"
1238
+ },
1239
+ {
1240
+ "kind": "Content",
1241
+ "text": "<string[]>>"
1242
+ },
1243
+ {
1244
+ "kind": "Content",
1245
+ "text": ";"
279
1246
  }
280
1247
  ],
1248
+ "isStatic": false,
1249
+ "returnTypeTokenRange": {
1250
+ "startIndex": 1,
1251
+ "endIndex": 5
1252
+ },
1253
+ "releaseTag": "Public",
1254
+ "isProtected": false,
1255
+ "overloadIndex": 1,
1256
+ "parameters": [],
281
1257
  "isOptional": false,
282
1258
  "isAbstract": false,
283
- "name": "hashParts"
1259
+ "name": "getAllLabels"
284
1260
  },
285
1261
  {
286
1262
  "kind": "Method",
287
- "canonicalReference": "@fgv/ts-web-extras!BrowserHashProvider.hashString:member(1)",
288
- "docComment": "/**\n * Hash a string using the specified algorithm.\n *\n * @param data - The string to hash\n *\n * @param algorithm - The hash algorithm to use\n *\n * @returns Promise resolving to the hex-encoded hash\n */\n",
1263
+ "canonicalReference": "@fgv/ts-web-extras!DirectoryHandleStore#load:member(1)",
1264
+ "docComment": "/**\n * Retrieves a directory handle by label.\n *\n * @param label - Key to look up\n *\n * @returns Success with handle (or undefined if not found), or Failure on error\n */\n",
289
1265
  "excerptTokens": [
290
1266
  {
291
1267
  "kind": "Content",
292
- "text": "static hashString(data: "
293
- },
294
- {
295
- "kind": "Content",
296
- "text": "string"
297
- },
298
- {
299
- "kind": "Content",
300
- "text": ", algorithm?: "
1268
+ "text": "load(label: "
301
1269
  },
302
1270
  {
303
1271
  "kind": "Content",
@@ -323,16 +1291,25 @@
323
1291
  },
324
1292
  {
325
1293
  "kind": "Content",
326
- "text": "<string>>"
1294
+ "text": "<"
1295
+ },
1296
+ {
1297
+ "kind": "Reference",
1298
+ "text": "FileSystemDirectoryHandle",
1299
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemDirectoryHandle_2:interface"
1300
+ },
1301
+ {
1302
+ "kind": "Content",
1303
+ "text": " | undefined>>"
327
1304
  },
328
1305
  {
329
1306
  "kind": "Content",
330
1307
  "text": ";"
331
1308
  }
332
1309
  ],
333
- "isStatic": true,
1310
+ "isStatic": false,
334
1311
  "returnTypeTokenRange": {
335
- "startIndex": 5,
1312
+ "startIndex": 3,
336
1313
  "endIndex": 9
337
1314
  },
338
1315
  "releaseTag": "Public",
@@ -340,7 +1317,140 @@
340
1317
  "overloadIndex": 1,
341
1318
  "parameters": [
342
1319
  {
343
- "parameterName": "data",
1320
+ "parameterName": "label",
1321
+ "parameterTypeTokenRange": {
1322
+ "startIndex": 1,
1323
+ "endIndex": 2
1324
+ },
1325
+ "isOptional": false
1326
+ }
1327
+ ],
1328
+ "isOptional": false,
1329
+ "isAbstract": false,
1330
+ "name": "load"
1331
+ },
1332
+ {
1333
+ "kind": "Method",
1334
+ "canonicalReference": "@fgv/ts-web-extras!DirectoryHandleStore#remove:member(1)",
1335
+ "docComment": "/**\n * Removes a directory handle from IndexedDB.\n *\n * @param label - Key to remove\n *\n * @returns Success or Failure\n */\n",
1336
+ "excerptTokens": [
1337
+ {
1338
+ "kind": "Content",
1339
+ "text": "remove(label: "
1340
+ },
1341
+ {
1342
+ "kind": "Content",
1343
+ "text": "string"
1344
+ },
1345
+ {
1346
+ "kind": "Content",
1347
+ "text": "): "
1348
+ },
1349
+ {
1350
+ "kind": "Reference",
1351
+ "text": "Promise",
1352
+ "canonicalReference": "!Promise:interface"
1353
+ },
1354
+ {
1355
+ "kind": "Content",
1356
+ "text": "<"
1357
+ },
1358
+ {
1359
+ "kind": "Reference",
1360
+ "text": "Result",
1361
+ "canonicalReference": "@fgv/ts-utils!Result:type"
1362
+ },
1363
+ {
1364
+ "kind": "Content",
1365
+ "text": "<void>>"
1366
+ },
1367
+ {
1368
+ "kind": "Content",
1369
+ "text": ";"
1370
+ }
1371
+ ],
1372
+ "isStatic": false,
1373
+ "returnTypeTokenRange": {
1374
+ "startIndex": 3,
1375
+ "endIndex": 7
1376
+ },
1377
+ "releaseTag": "Public",
1378
+ "isProtected": false,
1379
+ "overloadIndex": 1,
1380
+ "parameters": [
1381
+ {
1382
+ "parameterName": "label",
1383
+ "parameterTypeTokenRange": {
1384
+ "startIndex": 1,
1385
+ "endIndex": 2
1386
+ },
1387
+ "isOptional": false
1388
+ }
1389
+ ],
1390
+ "isOptional": false,
1391
+ "isAbstract": false,
1392
+ "name": "remove"
1393
+ },
1394
+ {
1395
+ "kind": "Method",
1396
+ "canonicalReference": "@fgv/ts-web-extras!DirectoryHandleStore#save:member(1)",
1397
+ "docComment": "/**\n * Saves a directory handle to IndexedDB under the given label.\n *\n * @param label - Key to store the handle under (typically dirHandle.name)\n *\n * @param handle - The FileSystemDirectoryHandle to persist\n *\n * @returns Success or Failure\n */\n",
1398
+ "excerptTokens": [
1399
+ {
1400
+ "kind": "Content",
1401
+ "text": "save(label: "
1402
+ },
1403
+ {
1404
+ "kind": "Content",
1405
+ "text": "string"
1406
+ },
1407
+ {
1408
+ "kind": "Content",
1409
+ "text": ", handle: "
1410
+ },
1411
+ {
1412
+ "kind": "Reference",
1413
+ "text": "FileSystemDirectoryHandle",
1414
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemDirectoryHandle_2:interface"
1415
+ },
1416
+ {
1417
+ "kind": "Content",
1418
+ "text": "): "
1419
+ },
1420
+ {
1421
+ "kind": "Reference",
1422
+ "text": "Promise",
1423
+ "canonicalReference": "!Promise:interface"
1424
+ },
1425
+ {
1426
+ "kind": "Content",
1427
+ "text": "<"
1428
+ },
1429
+ {
1430
+ "kind": "Reference",
1431
+ "text": "Result",
1432
+ "canonicalReference": "@fgv/ts-utils!Result:type"
1433
+ },
1434
+ {
1435
+ "kind": "Content",
1436
+ "text": "<void>>"
1437
+ },
1438
+ {
1439
+ "kind": "Content",
1440
+ "text": ";"
1441
+ }
1442
+ ],
1443
+ "isStatic": false,
1444
+ "returnTypeTokenRange": {
1445
+ "startIndex": 5,
1446
+ "endIndex": 9
1447
+ },
1448
+ "releaseTag": "Public",
1449
+ "isProtected": false,
1450
+ "overloadIndex": 1,
1451
+ "parameters": [
1452
+ {
1453
+ "parameterName": "label",
344
1454
  "parameterTypeTokenRange": {
345
1455
  "startIndex": 1,
346
1456
  "endIndex": 2
@@ -348,17 +1458,17 @@
348
1458
  "isOptional": false
349
1459
  },
350
1460
  {
351
- "parameterName": "algorithm",
1461
+ "parameterName": "handle",
352
1462
  "parameterTypeTokenRange": {
353
1463
  "startIndex": 3,
354
1464
  "endIndex": 4
355
1465
  },
356
- "isOptional": true
1466
+ "isOptional": false
357
1467
  }
358
1468
  ],
359
1469
  "isOptional": false,
360
1470
  "isAbstract": false,
361
- "name": "hashString"
1471
+ "name": "save"
362
1472
  }
363
1473
  ],
364
1474
  "implementsTokenRanges": []
@@ -741,17 +1851,37 @@
741
1851
  },
742
1852
  {
743
1853
  "kind": "Method",
744
- "canonicalReference": "@fgv/ts-web-extras!FileApiTreeAccessors.extractFileMetadata:member(1)",
745
- "docComment": "/**\n * Extract file metadata from a File.\n *\n * @param fileList - The File to extract metadata from\n *\n * @returns The {@link IFileMetadata | file metadata}\n */\n",
1854
+ "canonicalReference": "@fgv/ts-web-extras!FileApiTreeAccessors.createFromLocalStorage:member(1)",
1855
+ "docComment": "/**\n * Create a persistent FileTree from browser localStorage. Changes to files can be synced back to localStorage.\n *\n * @remarks\n *\n * - Works in all browsers with localStorage support - Maps directory paths to localStorage keys - Each key stores multiple collections as JSON - Files are automatically discovered from storage\n *\n * @param params - Configuration including path-to-key mappings and optional autoSync\n *\n * @returns Result containing a FileTree with persistence capability\n *\n * @example\n * ```typescript\n * const tree = FileApiTreeAccessors.createFromLocalStorage({\n * pathToKeyMap: {\n * '/data/ingredients': 'myapp:ingredients:v1',\n * '/data/fillings': 'myapp:fillings:v1'\n * },\n * mutable: true,\n * autoSync: false\n * });\n * ```\n *\n * @public\n */\n",
746
1856
  "excerptTokens": [
747
1857
  {
748
1858
  "kind": "Content",
749
- "text": "static extractFileMetadata(file: "
1859
+ "text": "static createFromLocalStorage<TCT extends "
1860
+ },
1861
+ {
1862
+ "kind": "Content",
1863
+ "text": "string"
1864
+ },
1865
+ {
1866
+ "kind": "Content",
1867
+ "text": " = "
1868
+ },
1869
+ {
1870
+ "kind": "Content",
1871
+ "text": "string"
1872
+ },
1873
+ {
1874
+ "kind": "Content",
1875
+ "text": ">(params: "
750
1876
  },
751
1877
  {
752
1878
  "kind": "Reference",
753
- "text": "File",
754
- "canonicalReference": "!File:interface"
1879
+ "text": "ILocalStorageTreeParams",
1880
+ "canonicalReference": "@fgv/ts-web-extras!ILocalStorageTreeParams:interface"
1881
+ },
1882
+ {
1883
+ "kind": "Content",
1884
+ "text": "<TCT>"
755
1885
  },
756
1886
  {
757
1887
  "kind": "Content",
@@ -759,44 +1889,70 @@
759
1889
  },
760
1890
  {
761
1891
  "kind": "Reference",
762
- "text": "IFileMetadata",
763
- "canonicalReference": "@fgv/ts-web-extras!IFileMetadata:interface"
1892
+ "text": "Result",
1893
+ "canonicalReference": "@fgv/ts-utils!Result:type"
1894
+ },
1895
+ {
1896
+ "kind": "Content",
1897
+ "text": "<"
1898
+ },
1899
+ {
1900
+ "kind": "Reference",
1901
+ "text": "FileTree.FileTree",
1902
+ "canonicalReference": "@fgv/ts-json-base!FileTree_2:class"
1903
+ },
1904
+ {
1905
+ "kind": "Content",
1906
+ "text": "<TCT>>"
764
1907
  },
765
1908
  {
766
1909
  "kind": "Content",
767
1910
  "text": ";"
768
1911
  }
769
1912
  ],
1913
+ "typeParameters": [
1914
+ {
1915
+ "typeParameterName": "TCT",
1916
+ "constraintTokenRange": {
1917
+ "startIndex": 1,
1918
+ "endIndex": 2
1919
+ },
1920
+ "defaultTypeTokenRange": {
1921
+ "startIndex": 3,
1922
+ "endIndex": 4
1923
+ }
1924
+ }
1925
+ ],
770
1926
  "isStatic": true,
771
1927
  "returnTypeTokenRange": {
772
- "startIndex": 3,
773
- "endIndex": 4
1928
+ "startIndex": 8,
1929
+ "endIndex": 12
774
1930
  },
775
1931
  "releaseTag": "Public",
776
1932
  "isProtected": false,
777
1933
  "overloadIndex": 1,
778
1934
  "parameters": [
779
1935
  {
780
- "parameterName": "file",
1936
+ "parameterName": "params",
781
1937
  "parameterTypeTokenRange": {
782
- "startIndex": 1,
783
- "endIndex": 2
1938
+ "startIndex": 5,
1939
+ "endIndex": 7
784
1940
  },
785
1941
  "isOptional": false
786
1942
  }
787
1943
  ],
788
1944
  "isOptional": false,
789
1945
  "isAbstract": false,
790
- "name": "extractFileMetadata"
1946
+ "name": "createFromLocalStorage"
791
1947
  },
792
1948
  {
793
1949
  "kind": "Method",
794
- "canonicalReference": "@fgv/ts-web-extras!FileApiTreeAccessors.fromDirectoryUpload:member(1)",
795
- "docComment": "/**\n * Create FileTree from directory upload with webkitRelativePath.\n *\n * @param fileList - FileList from a directory upload (input with webkitdirectory)\n *\n * @param params - Optional `IFileTreeInitParams` for the file tree.\n *\n * @returns Promise resolving to a FileTree with all content pre-loaded\n */\n",
1950
+ "canonicalReference": "@fgv/ts-web-extras!FileApiTreeAccessors.createPersistent:member(1)",
1951
+ "docComment": "/**\n * Create a persistent FileTree from a File System Access API directory handle. Changes to files can be synced back to disk.\n *\n * @remarks\n *\n * - Only works in browsers supporting File System Access API (Chrome, Edge, Opera) - Requires 'readwrite' permission on the directory handle - Falls back to read-only mode if permissions unavailable (unless requireWritePermission is true)\n *\n * @param dirHandle - FileSystemDirectoryHandle to load files from\n *\n * @param params - Optional parameters including autoSync and permission settings\n *\n * @returns Promise resolving to a FileTree with persistence capability\n *\n * @public\n */\n",
796
1952
  "excerptTokens": [
797
1953
  {
798
1954
  "kind": "Content",
799
- "text": "static fromDirectoryUpload<TCT extends "
1955
+ "text": "static createPersistent<TCT extends "
800
1956
  },
801
1957
  {
802
1958
  "kind": "Content",
@@ -812,12 +1968,12 @@
812
1968
  },
813
1969
  {
814
1970
  "kind": "Content",
815
- "text": ">(fileList: "
1971
+ "text": ">(dirHandle: "
816
1972
  },
817
1973
  {
818
1974
  "kind": "Reference",
819
- "text": "FileList",
820
- "canonicalReference": "!FileList:interface"
1975
+ "text": "FileSystemDirectoryHandle",
1976
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemDirectoryHandle_2:interface"
821
1977
  },
822
1978
  {
823
1979
  "kind": "Content",
@@ -825,8 +1981,8 @@
825
1981
  },
826
1982
  {
827
1983
  "kind": "Reference",
828
- "text": "FileTree.IFileTreeInitParams",
829
- "canonicalReference": "@fgv/ts-json-base!IFileTreeInitParams:interface"
1984
+ "text": "IFileSystemAccessTreeParams",
1985
+ "canonicalReference": "@fgv/ts-web-extras!IFileSystemAccessTreeParams:interface"
830
1986
  },
831
1987
  {
832
1988
  "kind": "Content",
@@ -891,7 +2047,7 @@
891
2047
  "overloadIndex": 1,
892
2048
  "parameters": [
893
2049
  {
894
- "parameterName": "fileList",
2050
+ "parameterName": "dirHandle",
895
2051
  "parameterTypeTokenRange": {
896
2052
  "startIndex": 5,
897
2053
  "endIndex": 6
@@ -909,16 +2065,16 @@
909
2065
  ],
910
2066
  "isOptional": false,
911
2067
  "isAbstract": false,
912
- "name": "fromDirectoryUpload"
2068
+ "name": "createPersistent"
913
2069
  },
914
2070
  {
915
2071
  "kind": "Method",
916
- "canonicalReference": "@fgv/ts-web-extras!FileApiTreeAccessors.fromFileList:member(1)",
917
- "docComment": "/**\n * Create FileTree from FileList (e.g., from input[type=\"file\"]).\n *\n * @param fileList - FileList from a file input element\n *\n * @param params - Optional `IFileTreeInitParams` for the file tree.\n *\n * @returns Promise resolving to a FileTree with all content pre-loaded\n */\n",
2072
+ "canonicalReference": "@fgv/ts-web-extras!FileApiTreeAccessors.createPersistentFromFile:member(1)",
2073
+ "docComment": "/**\n * Create a persistent FileTree from a single File System Access API file handle. The tree contains exactly one file at `/<filename>`. Changes can be synced back to the original file via `syncToDisk()`.\n *\n * @param fileHandle - FileSystemFileHandle to load\n *\n * @param params - Optional parameters including autoSync and permission settings\n *\n * @returns Promise resolving to a FileTree with persistence capability\n *\n * @public\n */\n",
918
2074
  "excerptTokens": [
919
2075
  {
920
2076
  "kind": "Content",
921
- "text": "static fromFileList<TCT extends "
2077
+ "text": "static createPersistentFromFile<TCT extends "
922
2078
  },
923
2079
  {
924
2080
  "kind": "Content",
@@ -934,12 +2090,12 @@
934
2090
  },
935
2091
  {
936
2092
  "kind": "Content",
937
- "text": ">(fileList: "
2093
+ "text": ">(fileHandle: "
938
2094
  },
939
2095
  {
940
2096
  "kind": "Reference",
941
- "text": "FileList",
942
- "canonicalReference": "!FileList:interface"
2097
+ "text": "FileSystemFileHandle",
2098
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemFileHandle_2:interface"
943
2099
  },
944
2100
  {
945
2101
  "kind": "Content",
@@ -947,8 +2103,8 @@
947
2103
  },
948
2104
  {
949
2105
  "kind": "Reference",
950
- "text": "FileTree.IFileTreeInitParams",
951
- "canonicalReference": "@fgv/ts-json-base!IFileTreeInitParams:interface"
2106
+ "text": "IFileSystemAccessTreeParams",
2107
+ "canonicalReference": "@fgv/ts-web-extras!IFileSystemAccessTreeParams:interface"
952
2108
  },
953
2109
  {
954
2110
  "kind": "Content",
@@ -1013,7 +2169,7 @@
1013
2169
  "overloadIndex": 1,
1014
2170
  "parameters": [
1015
2171
  {
1016
- "parameterName": "fileList",
2172
+ "parameterName": "fileHandle",
1017
2173
  "parameterTypeTokenRange": {
1018
2174
  "startIndex": 5,
1019
2175
  "endIndex": 6
@@ -1031,29 +2187,21 @@
1031
2187
  ],
1032
2188
  "isOptional": false,
1033
2189
  "isAbstract": false,
1034
- "name": "fromFileList"
2190
+ "name": "createPersistentFromFile"
1035
2191
  },
1036
2192
  {
1037
2193
  "kind": "Method",
1038
- "canonicalReference": "@fgv/ts-web-extras!FileApiTreeAccessors.getOriginalFile:member(1)",
1039
- "docComment": "/**\n * Get the File object for a specific path from the original FileList. This is useful for accessing the original File API object for operations like getting file metadata, MIME type, etc.\n *\n * @param fileList - The original FileList\n *\n * @param targetPath - The path to find\n *\n * @returns Result containing the File object if found\n */\n",
2194
+ "canonicalReference": "@fgv/ts-web-extras!FileApiTreeAccessors.extractFileMetadata:member(1)",
2195
+ "docComment": "/**\n * Extract file metadata from a File.\n *\n * @param fileList - The File to extract metadata from\n *\n * @returns The {@link IFileMetadata | file metadata}\n */\n",
1040
2196
  "excerptTokens": [
1041
2197
  {
1042
2198
  "kind": "Content",
1043
- "text": "static getOriginalFile(fileList: "
2199
+ "text": "static extractFileMetadata(file: "
1044
2200
  },
1045
2201
  {
1046
2202
  "kind": "Reference",
1047
- "text": "FileList",
1048
- "canonicalReference": "!FileList:interface"
1049
- },
1050
- {
1051
- "kind": "Content",
1052
- "text": ", targetPath: "
1053
- },
1054
- {
1055
- "kind": "Content",
1056
- "text": "string"
2203
+ "text": "File",
2204
+ "canonicalReference": "!File:interface"
1057
2205
  },
1058
2206
  {
1059
2207
  "kind": "Content",
@@ -1061,21 +2209,8 @@
1061
2209
  },
1062
2210
  {
1063
2211
  "kind": "Reference",
1064
- "text": "Result",
1065
- "canonicalReference": "@fgv/ts-utils!Result:type"
1066
- },
1067
- {
1068
- "kind": "Content",
1069
- "text": "<"
1070
- },
1071
- {
1072
- "kind": "Reference",
1073
- "text": "File",
1074
- "canonicalReference": "!File:interface"
1075
- },
1076
- {
1077
- "kind": "Content",
1078
- "text": ">"
2212
+ "text": "IFileMetadata",
2213
+ "canonicalReference": "@fgv/ts-web-extras!IFileMetadata:interface"
1079
2214
  },
1080
2215
  {
1081
2216
  "kind": "Content",
@@ -1084,113 +2219,1114 @@
1084
2219
  ],
1085
2220
  "isStatic": true,
1086
2221
  "returnTypeTokenRange": {
1087
- "startIndex": 5,
1088
- "endIndex": 9
2222
+ "startIndex": 3,
2223
+ "endIndex": 4
1089
2224
  },
1090
2225
  "releaseTag": "Public",
1091
2226
  "isProtected": false,
1092
2227
  "overloadIndex": 1,
1093
2228
  "parameters": [
1094
2229
  {
1095
- "parameterName": "fileList",
2230
+ "parameterName": "file",
1096
2231
  "parameterTypeTokenRange": {
1097
2232
  "startIndex": 1,
1098
2233
  "endIndex": 2
1099
2234
  },
1100
2235
  "isOptional": false
1101
- },
1102
- {
1103
- "parameterName": "targetPath",
1104
- "parameterTypeTokenRange": {
1105
- "startIndex": 3,
1106
- "endIndex": 4
1107
- },
2236
+ }
2237
+ ],
2238
+ "isOptional": false,
2239
+ "isAbstract": false,
2240
+ "name": "extractFileMetadata"
2241
+ },
2242
+ {
2243
+ "kind": "Method",
2244
+ "canonicalReference": "@fgv/ts-web-extras!FileApiTreeAccessors.fromDirectoryUpload:member(1)",
2245
+ "docComment": "/**\n * Create FileTree from directory upload with webkitRelativePath.\n *\n * @param fileList - FileList from a directory upload (input with webkitdirectory)\n *\n * @param params - Optional `IFileTreeInitParams` for the file tree.\n *\n * @returns Promise resolving to a FileTree with all content pre-loaded\n */\n",
2246
+ "excerptTokens": [
2247
+ {
2248
+ "kind": "Content",
2249
+ "text": "static fromDirectoryUpload<TCT extends "
2250
+ },
2251
+ {
2252
+ "kind": "Content",
2253
+ "text": "string"
2254
+ },
2255
+ {
2256
+ "kind": "Content",
2257
+ "text": " = "
2258
+ },
2259
+ {
2260
+ "kind": "Content",
2261
+ "text": "string"
2262
+ },
2263
+ {
2264
+ "kind": "Content",
2265
+ "text": ">(fileList: "
2266
+ },
2267
+ {
2268
+ "kind": "Reference",
2269
+ "text": "FileList",
2270
+ "canonicalReference": "!FileList:interface"
2271
+ },
2272
+ {
2273
+ "kind": "Content",
2274
+ "text": ", params?: "
2275
+ },
2276
+ {
2277
+ "kind": "Reference",
2278
+ "text": "FileTree.IFileTreeInitParams",
2279
+ "canonicalReference": "@fgv/ts-json-base!IFileTreeInitParams:interface"
2280
+ },
2281
+ {
2282
+ "kind": "Content",
2283
+ "text": "<TCT>"
2284
+ },
2285
+ {
2286
+ "kind": "Content",
2287
+ "text": "): "
2288
+ },
2289
+ {
2290
+ "kind": "Reference",
2291
+ "text": "Promise",
2292
+ "canonicalReference": "!Promise:interface"
2293
+ },
2294
+ {
2295
+ "kind": "Content",
2296
+ "text": "<"
2297
+ },
2298
+ {
2299
+ "kind": "Reference",
2300
+ "text": "Result",
2301
+ "canonicalReference": "@fgv/ts-utils!Result:type"
2302
+ },
2303
+ {
2304
+ "kind": "Content",
2305
+ "text": "<"
2306
+ },
2307
+ {
2308
+ "kind": "Reference",
2309
+ "text": "FileTree.FileTree",
2310
+ "canonicalReference": "@fgv/ts-json-base!FileTree_2:class"
2311
+ },
2312
+ {
2313
+ "kind": "Content",
2314
+ "text": "<TCT>>>"
2315
+ },
2316
+ {
2317
+ "kind": "Content",
2318
+ "text": ";"
2319
+ }
2320
+ ],
2321
+ "typeParameters": [
2322
+ {
2323
+ "typeParameterName": "TCT",
2324
+ "constraintTokenRange": {
2325
+ "startIndex": 1,
2326
+ "endIndex": 2
2327
+ },
2328
+ "defaultTypeTokenRange": {
2329
+ "startIndex": 3,
2330
+ "endIndex": 4
2331
+ }
2332
+ }
2333
+ ],
2334
+ "isStatic": true,
2335
+ "returnTypeTokenRange": {
2336
+ "startIndex": 10,
2337
+ "endIndex": 16
2338
+ },
2339
+ "releaseTag": "Public",
2340
+ "isProtected": false,
2341
+ "overloadIndex": 1,
2342
+ "parameters": [
2343
+ {
2344
+ "parameterName": "fileList",
2345
+ "parameterTypeTokenRange": {
2346
+ "startIndex": 5,
2347
+ "endIndex": 6
2348
+ },
2349
+ "isOptional": false
2350
+ },
2351
+ {
2352
+ "parameterName": "params",
2353
+ "parameterTypeTokenRange": {
2354
+ "startIndex": 7,
2355
+ "endIndex": 9
2356
+ },
2357
+ "isOptional": true
2358
+ }
2359
+ ],
2360
+ "isOptional": false,
2361
+ "isAbstract": false,
2362
+ "name": "fromDirectoryUpload"
2363
+ },
2364
+ {
2365
+ "kind": "Method",
2366
+ "canonicalReference": "@fgv/ts-web-extras!FileApiTreeAccessors.fromFileList:member(1)",
2367
+ "docComment": "/**\n * Create FileTree from FileList (e.g., from input[type=\"file\"]).\n *\n * @param fileList - FileList from a file input element\n *\n * @param params - Optional `IFileTreeInitParams` for the file tree.\n *\n * @returns Promise resolving to a FileTree with all content pre-loaded\n */\n",
2368
+ "excerptTokens": [
2369
+ {
2370
+ "kind": "Content",
2371
+ "text": "static fromFileList<TCT extends "
2372
+ },
2373
+ {
2374
+ "kind": "Content",
2375
+ "text": "string"
2376
+ },
2377
+ {
2378
+ "kind": "Content",
2379
+ "text": " = "
2380
+ },
2381
+ {
2382
+ "kind": "Content",
2383
+ "text": "string"
2384
+ },
2385
+ {
2386
+ "kind": "Content",
2387
+ "text": ">(fileList: "
2388
+ },
2389
+ {
2390
+ "kind": "Reference",
2391
+ "text": "FileList",
2392
+ "canonicalReference": "!FileList:interface"
2393
+ },
2394
+ {
2395
+ "kind": "Content",
2396
+ "text": ", params?: "
2397
+ },
2398
+ {
2399
+ "kind": "Reference",
2400
+ "text": "FileTree.IFileTreeInitParams",
2401
+ "canonicalReference": "@fgv/ts-json-base!IFileTreeInitParams:interface"
2402
+ },
2403
+ {
2404
+ "kind": "Content",
2405
+ "text": "<TCT>"
2406
+ },
2407
+ {
2408
+ "kind": "Content",
2409
+ "text": "): "
2410
+ },
2411
+ {
2412
+ "kind": "Reference",
2413
+ "text": "Promise",
2414
+ "canonicalReference": "!Promise:interface"
2415
+ },
2416
+ {
2417
+ "kind": "Content",
2418
+ "text": "<"
2419
+ },
2420
+ {
2421
+ "kind": "Reference",
2422
+ "text": "Result",
2423
+ "canonicalReference": "@fgv/ts-utils!Result:type"
2424
+ },
2425
+ {
2426
+ "kind": "Content",
2427
+ "text": "<"
2428
+ },
2429
+ {
2430
+ "kind": "Reference",
2431
+ "text": "FileTree.FileTree",
2432
+ "canonicalReference": "@fgv/ts-json-base!FileTree_2:class"
2433
+ },
2434
+ {
2435
+ "kind": "Content",
2436
+ "text": "<TCT>>>"
2437
+ },
2438
+ {
2439
+ "kind": "Content",
2440
+ "text": ";"
2441
+ }
2442
+ ],
2443
+ "typeParameters": [
2444
+ {
2445
+ "typeParameterName": "TCT",
2446
+ "constraintTokenRange": {
2447
+ "startIndex": 1,
2448
+ "endIndex": 2
2449
+ },
2450
+ "defaultTypeTokenRange": {
2451
+ "startIndex": 3,
2452
+ "endIndex": 4
2453
+ }
2454
+ }
2455
+ ],
2456
+ "isStatic": true,
2457
+ "returnTypeTokenRange": {
2458
+ "startIndex": 10,
2459
+ "endIndex": 16
2460
+ },
2461
+ "releaseTag": "Public",
2462
+ "isProtected": false,
2463
+ "overloadIndex": 1,
2464
+ "parameters": [
2465
+ {
2466
+ "parameterName": "fileList",
2467
+ "parameterTypeTokenRange": {
2468
+ "startIndex": 5,
2469
+ "endIndex": 6
2470
+ },
2471
+ "isOptional": false
2472
+ },
2473
+ {
2474
+ "parameterName": "params",
2475
+ "parameterTypeTokenRange": {
2476
+ "startIndex": 7,
2477
+ "endIndex": 9
2478
+ },
2479
+ "isOptional": true
2480
+ }
2481
+ ],
2482
+ "isOptional": false,
2483
+ "isAbstract": false,
2484
+ "name": "fromFileList"
2485
+ },
2486
+ {
2487
+ "kind": "Method",
2488
+ "canonicalReference": "@fgv/ts-web-extras!FileApiTreeAccessors.getOriginalFile:member(1)",
2489
+ "docComment": "/**\n * Get the File object for a specific path from the original FileList. This is useful for accessing the original File API object for operations like getting file metadata, MIME type, etc.\n *\n * @param fileList - The original FileList\n *\n * @param targetPath - The path to find\n *\n * @returns Result containing the File object if found\n */\n",
2490
+ "excerptTokens": [
2491
+ {
2492
+ "kind": "Content",
2493
+ "text": "static getOriginalFile(fileList: "
2494
+ },
2495
+ {
2496
+ "kind": "Reference",
2497
+ "text": "FileList",
2498
+ "canonicalReference": "!FileList:interface"
2499
+ },
2500
+ {
2501
+ "kind": "Content",
2502
+ "text": ", targetPath: "
2503
+ },
2504
+ {
2505
+ "kind": "Content",
2506
+ "text": "string"
2507
+ },
2508
+ {
2509
+ "kind": "Content",
2510
+ "text": "): "
2511
+ },
2512
+ {
2513
+ "kind": "Reference",
2514
+ "text": "Result",
2515
+ "canonicalReference": "@fgv/ts-utils!Result:type"
2516
+ },
2517
+ {
2518
+ "kind": "Content",
2519
+ "text": "<"
2520
+ },
2521
+ {
2522
+ "kind": "Reference",
2523
+ "text": "File",
2524
+ "canonicalReference": "!File:interface"
2525
+ },
2526
+ {
2527
+ "kind": "Content",
2528
+ "text": ">"
2529
+ },
2530
+ {
2531
+ "kind": "Content",
2532
+ "text": ";"
2533
+ }
2534
+ ],
2535
+ "isStatic": true,
2536
+ "returnTypeTokenRange": {
2537
+ "startIndex": 5,
2538
+ "endIndex": 9
2539
+ },
2540
+ "releaseTag": "Public",
2541
+ "isProtected": false,
2542
+ "overloadIndex": 1,
2543
+ "parameters": [
2544
+ {
2545
+ "parameterName": "fileList",
2546
+ "parameterTypeTokenRange": {
2547
+ "startIndex": 1,
2548
+ "endIndex": 2
2549
+ },
2550
+ "isOptional": false
2551
+ },
2552
+ {
2553
+ "parameterName": "targetPath",
2554
+ "parameterTypeTokenRange": {
2555
+ "startIndex": 3,
2556
+ "endIndex": 4
2557
+ },
2558
+ "isOptional": false
2559
+ }
2560
+ ],
2561
+ "isOptional": false,
2562
+ "isAbstract": false,
2563
+ "name": "getOriginalFile"
2564
+ }
2565
+ ],
2566
+ "implementsTokenRanges": []
2567
+ },
2568
+ {
2569
+ "kind": "Interface",
2570
+ "canonicalReference": "@fgv/ts-web-extras!FilePickerAcceptType:interface",
2571
+ "docComment": "/**\n * File picker accept type\n *\n * @public\n */\n",
2572
+ "excerptTokens": [
2573
+ {
2574
+ "kind": "Content",
2575
+ "text": "export interface FilePickerAcceptType "
2576
+ }
2577
+ ],
2578
+ "fileUrlPath": "src/packlets/file-api-types/index.ts",
2579
+ "releaseTag": "Public",
2580
+ "name": "FilePickerAcceptType",
2581
+ "preserveMemberOrder": false,
2582
+ "members": [
2583
+ {
2584
+ "kind": "PropertySignature",
2585
+ "canonicalReference": "@fgv/ts-web-extras!FilePickerAcceptType#accept:member",
2586
+ "docComment": "",
2587
+ "excerptTokens": [
2588
+ {
2589
+ "kind": "Content",
2590
+ "text": "accept: "
2591
+ },
2592
+ {
2593
+ "kind": "Reference",
2594
+ "text": "Record",
2595
+ "canonicalReference": "!Record:type"
2596
+ },
2597
+ {
2598
+ "kind": "Content",
2599
+ "text": "<string, string | string[]>"
2600
+ },
2601
+ {
2602
+ "kind": "Content",
2603
+ "text": ";"
2604
+ }
2605
+ ],
2606
+ "isReadonly": false,
2607
+ "isOptional": false,
2608
+ "releaseTag": "Public",
2609
+ "name": "accept",
2610
+ "propertyTypeTokenRange": {
2611
+ "startIndex": 1,
2612
+ "endIndex": 3
2613
+ }
2614
+ },
2615
+ {
2616
+ "kind": "PropertySignature",
2617
+ "canonicalReference": "@fgv/ts-web-extras!FilePickerAcceptType#description:member",
2618
+ "docComment": "",
2619
+ "excerptTokens": [
2620
+ {
2621
+ "kind": "Content",
2622
+ "text": "description?: "
2623
+ },
2624
+ {
2625
+ "kind": "Content",
2626
+ "text": "string"
2627
+ },
2628
+ {
2629
+ "kind": "Content",
2630
+ "text": ";"
2631
+ }
2632
+ ],
2633
+ "isReadonly": false,
2634
+ "isOptional": true,
2635
+ "releaseTag": "Public",
2636
+ "name": "description",
2637
+ "propertyTypeTokenRange": {
2638
+ "startIndex": 1,
2639
+ "endIndex": 2
2640
+ }
2641
+ }
2642
+ ],
2643
+ "extendsTokenRanges": []
2644
+ },
2645
+ {
2646
+ "kind": "Class",
2647
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemAccessTreeAccessors:class",
2648
+ "docComment": "/**\n * Implementation of `FileTree.IPersistentFileTreeAccessors` that uses the File System Access API to provide persistent file editing in browsers.\n *\n * @public\n */\n",
2649
+ "excerptTokens": [
2650
+ {
2651
+ "kind": "Content",
2652
+ "text": "export declare class FileSystemAccessTreeAccessors<TCT extends "
2653
+ },
2654
+ {
2655
+ "kind": "Content",
2656
+ "text": "string"
2657
+ },
2658
+ {
2659
+ "kind": "Content",
2660
+ "text": " = "
2661
+ },
2662
+ {
2663
+ "kind": "Content",
2664
+ "text": "string"
2665
+ },
2666
+ {
2667
+ "kind": "Content",
2668
+ "text": "> extends "
2669
+ },
2670
+ {
2671
+ "kind": "Reference",
2672
+ "text": "FileTree.InMemoryTreeAccessors",
2673
+ "canonicalReference": "@fgv/ts-json-base!InMemoryTreeAccessors:class"
2674
+ },
2675
+ {
2676
+ "kind": "Content",
2677
+ "text": "<TCT>"
2678
+ },
2679
+ {
2680
+ "kind": "Content",
2681
+ "text": " implements "
2682
+ },
2683
+ {
2684
+ "kind": "Reference",
2685
+ "text": "FileTree.IPersistentFileTreeAccessors",
2686
+ "canonicalReference": "@fgv/ts-json-base!IPersistentFileTreeAccessors:interface"
2687
+ },
2688
+ {
2689
+ "kind": "Content",
2690
+ "text": "<TCT>"
2691
+ },
2692
+ {
2693
+ "kind": "Content",
2694
+ "text": " "
2695
+ }
2696
+ ],
2697
+ "fileUrlPath": "src/packlets/file-tree/fileSystemAccessTreeAccessors.ts",
2698
+ "releaseTag": "Public",
2699
+ "typeParameters": [
2700
+ {
2701
+ "typeParameterName": "TCT",
2702
+ "constraintTokenRange": {
2703
+ "startIndex": 1,
2704
+ "endIndex": 2
2705
+ },
2706
+ "defaultTypeTokenRange": {
2707
+ "startIndex": 3,
2708
+ "endIndex": 4
2709
+ }
2710
+ }
2711
+ ],
2712
+ "isAbstract": false,
2713
+ "name": "FileSystemAccessTreeAccessors",
2714
+ "preserveMemberOrder": false,
2715
+ "members": [
2716
+ {
2717
+ "kind": "Constructor",
2718
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemAccessTreeAccessors:constructor(1)",
2719
+ "docComment": "/**\n * Protected constructor for FileSystemAccessTreeAccessors.\n *\n * @param files - An array of in-memory files to include in the tree.\n *\n * @param rootDir - The root directory handle.\n *\n * @param handles - Map of file paths to their handles.\n *\n * @param params - Optional params for the tree.\n *\n * @param hasWritePermission - Whether write permission was granted.\n */\n",
2720
+ "excerptTokens": [
2721
+ {
2722
+ "kind": "Content",
2723
+ "text": "protected constructor(files: "
2724
+ },
2725
+ {
2726
+ "kind": "Reference",
2727
+ "text": "FileTree.IInMemoryFile",
2728
+ "canonicalReference": "@fgv/ts-json-base!IInMemoryFile:interface"
2729
+ },
2730
+ {
2731
+ "kind": "Content",
2732
+ "text": "<TCT>[]"
2733
+ },
2734
+ {
2735
+ "kind": "Content",
2736
+ "text": ", rootDir: "
2737
+ },
2738
+ {
2739
+ "kind": "Reference",
2740
+ "text": "FileSystemDirectoryHandle",
2741
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemDirectoryHandle_2:interface"
2742
+ },
2743
+ {
2744
+ "kind": "Content",
2745
+ "text": ", handles: "
2746
+ },
2747
+ {
2748
+ "kind": "Reference",
2749
+ "text": "Map",
2750
+ "canonicalReference": "!Map:interface"
2751
+ },
2752
+ {
2753
+ "kind": "Content",
2754
+ "text": "<string, "
2755
+ },
2756
+ {
2757
+ "kind": "Reference",
2758
+ "text": "FileSystemFileHandle",
2759
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemFileHandle_2:interface"
2760
+ },
2761
+ {
2762
+ "kind": "Content",
2763
+ "text": ">"
2764
+ },
2765
+ {
2766
+ "kind": "Content",
2767
+ "text": ", params: "
2768
+ },
2769
+ {
2770
+ "kind": "Reference",
2771
+ "text": "IFileSystemAccessTreeParams",
2772
+ "canonicalReference": "@fgv/ts-web-extras!IFileSystemAccessTreeParams:interface"
2773
+ },
2774
+ {
2775
+ "kind": "Content",
2776
+ "text": "<TCT> | undefined"
2777
+ },
2778
+ {
2779
+ "kind": "Content",
2780
+ "text": ", hasWritePermission: "
2781
+ },
2782
+ {
2783
+ "kind": "Content",
2784
+ "text": "boolean"
2785
+ },
2786
+ {
2787
+ "kind": "Content",
2788
+ "text": ");"
2789
+ }
2790
+ ],
2791
+ "releaseTag": "Public",
2792
+ "isProtected": true,
2793
+ "overloadIndex": 1,
2794
+ "parameters": [
2795
+ {
2796
+ "parameterName": "files",
2797
+ "parameterTypeTokenRange": {
2798
+ "startIndex": 1,
2799
+ "endIndex": 3
2800
+ },
2801
+ "isOptional": false
2802
+ },
2803
+ {
2804
+ "parameterName": "rootDir",
2805
+ "parameterTypeTokenRange": {
2806
+ "startIndex": 4,
2807
+ "endIndex": 5
2808
+ },
2809
+ "isOptional": false
2810
+ },
2811
+ {
2812
+ "parameterName": "handles",
2813
+ "parameterTypeTokenRange": {
2814
+ "startIndex": 6,
2815
+ "endIndex": 10
2816
+ },
2817
+ "isOptional": false
2818
+ },
2819
+ {
2820
+ "parameterName": "params",
2821
+ "parameterTypeTokenRange": {
2822
+ "startIndex": 11,
2823
+ "endIndex": 13
2824
+ },
2825
+ "isOptional": false
2826
+ },
2827
+ {
2828
+ "parameterName": "hasWritePermission",
2829
+ "parameterTypeTokenRange": {
2830
+ "startIndex": 14,
2831
+ "endIndex": 15
2832
+ },
2833
+ "isOptional": false
2834
+ }
2835
+ ]
2836
+ },
2837
+ {
2838
+ "kind": "Method",
2839
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemAccessTreeAccessors#fileIsMutable:member(1)",
2840
+ "docComment": "/**\n * Implements `FileTree.IMutableFileTreeAccessors.fileIsMutable`\n */\n",
2841
+ "excerptTokens": [
2842
+ {
2843
+ "kind": "Content",
2844
+ "text": "fileIsMutable(path: "
2845
+ },
2846
+ {
2847
+ "kind": "Content",
2848
+ "text": "string"
2849
+ },
2850
+ {
2851
+ "kind": "Content",
2852
+ "text": "): "
2853
+ },
2854
+ {
2855
+ "kind": "Reference",
2856
+ "text": "DetailedResult",
2857
+ "canonicalReference": "@fgv/ts-utils!DetailedResult:type"
2858
+ },
2859
+ {
2860
+ "kind": "Content",
2861
+ "text": "<boolean, "
2862
+ },
2863
+ {
2864
+ "kind": "Reference",
2865
+ "text": "FileTree.SaveDetail",
2866
+ "canonicalReference": "@fgv/ts-json-base!SaveDetail:type"
2867
+ },
2868
+ {
2869
+ "kind": "Content",
2870
+ "text": ">"
2871
+ },
2872
+ {
2873
+ "kind": "Content",
2874
+ "text": ";"
2875
+ }
2876
+ ],
2877
+ "isStatic": false,
2878
+ "returnTypeTokenRange": {
2879
+ "startIndex": 3,
2880
+ "endIndex": 7
2881
+ },
2882
+ "releaseTag": "Public",
2883
+ "isProtected": false,
2884
+ "overloadIndex": 1,
2885
+ "parameters": [
2886
+ {
2887
+ "parameterName": "path",
2888
+ "parameterTypeTokenRange": {
2889
+ "startIndex": 1,
2890
+ "endIndex": 2
2891
+ },
2892
+ "isOptional": false
2893
+ }
2894
+ ],
2895
+ "isOptional": false,
2896
+ "isAbstract": false,
2897
+ "name": "fileIsMutable"
2898
+ },
2899
+ {
2900
+ "kind": "Method",
2901
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemAccessTreeAccessors.fromDirectoryHandle:member(1)",
2902
+ "docComment": "/**\n * Creates a new FileSystemAccessTreeAccessors instance from a directory handle.\n *\n * @param dirHandle - The FileSystemDirectoryHandle to load files from.\n *\n * @param params - Optional parameters including autoSync and permission settings.\n *\n * @returns Promise resolving to a FileSystemAccessTreeAccessors instance.\n *\n * @public\n */\n",
2903
+ "excerptTokens": [
2904
+ {
2905
+ "kind": "Content",
2906
+ "text": "static fromDirectoryHandle<TCT extends "
2907
+ },
2908
+ {
2909
+ "kind": "Content",
2910
+ "text": "string"
2911
+ },
2912
+ {
2913
+ "kind": "Content",
2914
+ "text": " = "
2915
+ },
2916
+ {
2917
+ "kind": "Content",
2918
+ "text": "string"
2919
+ },
2920
+ {
2921
+ "kind": "Content",
2922
+ "text": ">(dirHandle: "
2923
+ },
2924
+ {
2925
+ "kind": "Reference",
2926
+ "text": "FileSystemDirectoryHandle",
2927
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemDirectoryHandle_2:interface"
2928
+ },
2929
+ {
2930
+ "kind": "Content",
2931
+ "text": ", params?: "
2932
+ },
2933
+ {
2934
+ "kind": "Reference",
2935
+ "text": "IFileSystemAccessTreeParams",
2936
+ "canonicalReference": "@fgv/ts-web-extras!IFileSystemAccessTreeParams:interface"
2937
+ },
2938
+ {
2939
+ "kind": "Content",
2940
+ "text": "<TCT>"
2941
+ },
2942
+ {
2943
+ "kind": "Content",
2944
+ "text": "): "
2945
+ },
2946
+ {
2947
+ "kind": "Reference",
2948
+ "text": "Promise",
2949
+ "canonicalReference": "!Promise:interface"
2950
+ },
2951
+ {
2952
+ "kind": "Content",
2953
+ "text": "<"
2954
+ },
2955
+ {
2956
+ "kind": "Reference",
2957
+ "text": "Result",
2958
+ "canonicalReference": "@fgv/ts-utils!Result:type"
2959
+ },
2960
+ {
2961
+ "kind": "Content",
2962
+ "text": "<"
2963
+ },
2964
+ {
2965
+ "kind": "Reference",
2966
+ "text": "FileSystemAccessTreeAccessors",
2967
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemAccessTreeAccessors:class"
2968
+ },
2969
+ {
2970
+ "kind": "Content",
2971
+ "text": "<TCT>>>"
2972
+ },
2973
+ {
2974
+ "kind": "Content",
2975
+ "text": ";"
2976
+ }
2977
+ ],
2978
+ "typeParameters": [
2979
+ {
2980
+ "typeParameterName": "TCT",
2981
+ "constraintTokenRange": {
2982
+ "startIndex": 1,
2983
+ "endIndex": 2
2984
+ },
2985
+ "defaultTypeTokenRange": {
2986
+ "startIndex": 3,
2987
+ "endIndex": 4
2988
+ }
2989
+ }
2990
+ ],
2991
+ "isStatic": true,
2992
+ "returnTypeTokenRange": {
2993
+ "startIndex": 10,
2994
+ "endIndex": 16
2995
+ },
2996
+ "releaseTag": "Public",
2997
+ "isProtected": false,
2998
+ "overloadIndex": 1,
2999
+ "parameters": [
3000
+ {
3001
+ "parameterName": "dirHandle",
3002
+ "parameterTypeTokenRange": {
3003
+ "startIndex": 5,
3004
+ "endIndex": 6
3005
+ },
3006
+ "isOptional": false
3007
+ },
3008
+ {
3009
+ "parameterName": "params",
3010
+ "parameterTypeTokenRange": {
3011
+ "startIndex": 7,
3012
+ "endIndex": 9
3013
+ },
3014
+ "isOptional": true
3015
+ }
3016
+ ],
3017
+ "isOptional": false,
3018
+ "isAbstract": false,
3019
+ "name": "fromDirectoryHandle"
3020
+ },
3021
+ {
3022
+ "kind": "Method",
3023
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemAccessTreeAccessors.fromFileHandle:member(1)",
3024
+ "docComment": "/**\n * Creates a new FileSystemAccessTreeAccessors instance from a single file handle.\n *\n * The resulting tree contains exactly one file at `/<filename>`. `syncToDisk()` writes changes back to the original file via the File System Access API. New file creation is not supported on this tree (no parent directory handle).\n *\n * @param fileHandle - The FileSystemFileHandle to load.\n *\n * @param params - Optional parameters including autoSync and permission settings.\n *\n * @returns Promise resolving to a FileSystemAccessTreeAccessors instance.\n *\n * @public\n */\n",
3025
+ "excerptTokens": [
3026
+ {
3027
+ "kind": "Content",
3028
+ "text": "static fromFileHandle<TCT extends "
3029
+ },
3030
+ {
3031
+ "kind": "Content",
3032
+ "text": "string"
3033
+ },
3034
+ {
3035
+ "kind": "Content",
3036
+ "text": " = "
3037
+ },
3038
+ {
3039
+ "kind": "Content",
3040
+ "text": "string"
3041
+ },
3042
+ {
3043
+ "kind": "Content",
3044
+ "text": ">(fileHandle: "
3045
+ },
3046
+ {
3047
+ "kind": "Reference",
3048
+ "text": "FileSystemFileHandle",
3049
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemFileHandle_2:interface"
3050
+ },
3051
+ {
3052
+ "kind": "Content",
3053
+ "text": ", params?: "
3054
+ },
3055
+ {
3056
+ "kind": "Reference",
3057
+ "text": "IFileSystemAccessTreeParams",
3058
+ "canonicalReference": "@fgv/ts-web-extras!IFileSystemAccessTreeParams:interface"
3059
+ },
3060
+ {
3061
+ "kind": "Content",
3062
+ "text": "<TCT>"
3063
+ },
3064
+ {
3065
+ "kind": "Content",
3066
+ "text": "): "
3067
+ },
3068
+ {
3069
+ "kind": "Reference",
3070
+ "text": "Promise",
3071
+ "canonicalReference": "!Promise:interface"
3072
+ },
3073
+ {
3074
+ "kind": "Content",
3075
+ "text": "<"
3076
+ },
3077
+ {
3078
+ "kind": "Reference",
3079
+ "text": "Result",
3080
+ "canonicalReference": "@fgv/ts-utils!Result:type"
3081
+ },
3082
+ {
3083
+ "kind": "Content",
3084
+ "text": "<"
3085
+ },
3086
+ {
3087
+ "kind": "Reference",
3088
+ "text": "FileSystemAccessTreeAccessors",
3089
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemAccessTreeAccessors:class"
3090
+ },
3091
+ {
3092
+ "kind": "Content",
3093
+ "text": "<TCT>>>"
3094
+ },
3095
+ {
3096
+ "kind": "Content",
3097
+ "text": ";"
3098
+ }
3099
+ ],
3100
+ "typeParameters": [
3101
+ {
3102
+ "typeParameterName": "TCT",
3103
+ "constraintTokenRange": {
3104
+ "startIndex": 1,
3105
+ "endIndex": 2
3106
+ },
3107
+ "defaultTypeTokenRange": {
3108
+ "startIndex": 3,
3109
+ "endIndex": 4
3110
+ }
3111
+ }
3112
+ ],
3113
+ "isStatic": true,
3114
+ "returnTypeTokenRange": {
3115
+ "startIndex": 10,
3116
+ "endIndex": 16
3117
+ },
3118
+ "releaseTag": "Public",
3119
+ "isProtected": false,
3120
+ "overloadIndex": 1,
3121
+ "parameters": [
3122
+ {
3123
+ "parameterName": "fileHandle",
3124
+ "parameterTypeTokenRange": {
3125
+ "startIndex": 5,
3126
+ "endIndex": 6
3127
+ },
1108
3128
  "isOptional": false
3129
+ },
3130
+ {
3131
+ "parameterName": "params",
3132
+ "parameterTypeTokenRange": {
3133
+ "startIndex": 7,
3134
+ "endIndex": 9
3135
+ },
3136
+ "isOptional": true
1109
3137
  }
1110
3138
  ],
1111
3139
  "isOptional": false,
1112
3140
  "isAbstract": false,
1113
- "name": "getOriginalFile"
1114
- }
1115
- ],
1116
- "implementsTokenRanges": []
1117
- },
1118
- {
1119
- "kind": "Interface",
1120
- "canonicalReference": "@fgv/ts-web-extras!FilePickerAcceptType:interface",
1121
- "docComment": "/**\n * File picker accept type\n *\n * @public\n */\n",
1122
- "excerptTokens": [
1123
- {
1124
- "kind": "Content",
1125
- "text": "export interface FilePickerAcceptType "
1126
- }
1127
- ],
1128
- "fileUrlPath": "src/packlets/file-api-types/index.ts",
1129
- "releaseTag": "Public",
1130
- "name": "FilePickerAcceptType",
1131
- "preserveMemberOrder": false,
1132
- "members": [
3141
+ "name": "fromFileHandle"
3142
+ },
1133
3143
  {
1134
- "kind": "PropertySignature",
1135
- "canonicalReference": "@fgv/ts-web-extras!FilePickerAcceptType#accept:member",
1136
- "docComment": "",
3144
+ "kind": "Method",
3145
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemAccessTreeAccessors#getDirtyPaths:member(1)",
3146
+ "docComment": "/**\n * Implements `FileTree.IPersistentFileTreeAccessors.getDirtyPaths`\n */\n",
1137
3147
  "excerptTokens": [
1138
3148
  {
1139
3149
  "kind": "Content",
1140
- "text": "accept: "
3150
+ "text": "getDirtyPaths(): "
1141
3151
  },
1142
3152
  {
1143
- "kind": "Reference",
1144
- "text": "Record",
1145
- "canonicalReference": "!Record:type"
3153
+ "kind": "Content",
3154
+ "text": "string[]"
1146
3155
  },
1147
3156
  {
1148
3157
  "kind": "Content",
1149
- "text": "<string, string | string[]>"
3158
+ "text": ";"
3159
+ }
3160
+ ],
3161
+ "isStatic": false,
3162
+ "returnTypeTokenRange": {
3163
+ "startIndex": 1,
3164
+ "endIndex": 2
3165
+ },
3166
+ "releaseTag": "Public",
3167
+ "isProtected": false,
3168
+ "overloadIndex": 1,
3169
+ "parameters": [],
3170
+ "isOptional": false,
3171
+ "isAbstract": false,
3172
+ "name": "getDirtyPaths"
3173
+ },
3174
+ {
3175
+ "kind": "Method",
3176
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemAccessTreeAccessors#isDirty:member(1)",
3177
+ "docComment": "/**\n * Implements `FileTree.IPersistentFileTreeAccessors.isDirty`\n */\n",
3178
+ "excerptTokens": [
3179
+ {
3180
+ "kind": "Content",
3181
+ "text": "isDirty(): "
3182
+ },
3183
+ {
3184
+ "kind": "Content",
3185
+ "text": "boolean"
1150
3186
  },
1151
3187
  {
1152
3188
  "kind": "Content",
1153
3189
  "text": ";"
1154
3190
  }
1155
3191
  ],
1156
- "isReadonly": false,
1157
- "isOptional": false,
1158
- "releaseTag": "Public",
1159
- "name": "accept",
1160
- "propertyTypeTokenRange": {
3192
+ "isStatic": false,
3193
+ "returnTypeTokenRange": {
1161
3194
  "startIndex": 1,
1162
- "endIndex": 3
1163
- }
3195
+ "endIndex": 2
3196
+ },
3197
+ "releaseTag": "Public",
3198
+ "isProtected": false,
3199
+ "overloadIndex": 1,
3200
+ "parameters": [],
3201
+ "isOptional": false,
3202
+ "isAbstract": false,
3203
+ "name": "isDirty"
1164
3204
  },
1165
3205
  {
1166
- "kind": "PropertySignature",
1167
- "canonicalReference": "@fgv/ts-web-extras!FilePickerAcceptType#description:member",
1168
- "docComment": "",
3206
+ "kind": "Method",
3207
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemAccessTreeAccessors#saveFileContents:member(1)",
3208
+ "docComment": "/**\n * Implements `FileTree.IMutableFileTreeAccessors.saveFileContents`\n */\n",
1169
3209
  "excerptTokens": [
1170
3210
  {
1171
3211
  "kind": "Content",
1172
- "text": "description?: "
3212
+ "text": "saveFileContents(path: "
3213
+ },
3214
+ {
3215
+ "kind": "Content",
3216
+ "text": "string"
3217
+ },
3218
+ {
3219
+ "kind": "Content",
3220
+ "text": ", contents: "
1173
3221
  },
1174
3222
  {
1175
3223
  "kind": "Content",
1176
3224
  "text": "string"
1177
3225
  },
3226
+ {
3227
+ "kind": "Content",
3228
+ "text": "): "
3229
+ },
3230
+ {
3231
+ "kind": "Reference",
3232
+ "text": "Result",
3233
+ "canonicalReference": "@fgv/ts-utils!Result:type"
3234
+ },
3235
+ {
3236
+ "kind": "Content",
3237
+ "text": "<string>"
3238
+ },
1178
3239
  {
1179
3240
  "kind": "Content",
1180
3241
  "text": ";"
1181
3242
  }
1182
3243
  ],
1183
- "isReadonly": false,
1184
- "isOptional": true,
3244
+ "isStatic": false,
3245
+ "returnTypeTokenRange": {
3246
+ "startIndex": 5,
3247
+ "endIndex": 7
3248
+ },
1185
3249
  "releaseTag": "Public",
1186
- "name": "description",
1187
- "propertyTypeTokenRange": {
3250
+ "isProtected": false,
3251
+ "overloadIndex": 1,
3252
+ "parameters": [
3253
+ {
3254
+ "parameterName": "path",
3255
+ "parameterTypeTokenRange": {
3256
+ "startIndex": 1,
3257
+ "endIndex": 2
3258
+ },
3259
+ "isOptional": false
3260
+ },
3261
+ {
3262
+ "parameterName": "contents",
3263
+ "parameterTypeTokenRange": {
3264
+ "startIndex": 3,
3265
+ "endIndex": 4
3266
+ },
3267
+ "isOptional": false
3268
+ }
3269
+ ],
3270
+ "isOptional": false,
3271
+ "isAbstract": false,
3272
+ "name": "saveFileContents"
3273
+ },
3274
+ {
3275
+ "kind": "Method",
3276
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemAccessTreeAccessors#syncToDisk:member(1)",
3277
+ "docComment": "/**\n * Implements `FileTree.IPersistentFileTreeAccessors.syncToDisk`\n */\n",
3278
+ "excerptTokens": [
3279
+ {
3280
+ "kind": "Content",
3281
+ "text": "syncToDisk(): "
3282
+ },
3283
+ {
3284
+ "kind": "Reference",
3285
+ "text": "Promise",
3286
+ "canonicalReference": "!Promise:interface"
3287
+ },
3288
+ {
3289
+ "kind": "Content",
3290
+ "text": "<"
3291
+ },
3292
+ {
3293
+ "kind": "Reference",
3294
+ "text": "Result",
3295
+ "canonicalReference": "@fgv/ts-utils!Result:type"
3296
+ },
3297
+ {
3298
+ "kind": "Content",
3299
+ "text": "<void>>"
3300
+ },
3301
+ {
3302
+ "kind": "Content",
3303
+ "text": ";"
3304
+ }
3305
+ ],
3306
+ "isStatic": false,
3307
+ "returnTypeTokenRange": {
1188
3308
  "startIndex": 1,
1189
- "endIndex": 2
1190
- }
3309
+ "endIndex": 5
3310
+ },
3311
+ "releaseTag": "Public",
3312
+ "isProtected": false,
3313
+ "overloadIndex": 1,
3314
+ "parameters": [],
3315
+ "isOptional": false,
3316
+ "isAbstract": false,
3317
+ "name": "syncToDisk"
1191
3318
  }
1192
3319
  ],
1193
- "extendsTokenRanges": []
3320
+ "extendsTokenRange": {
3321
+ "startIndex": 5,
3322
+ "endIndex": 7
3323
+ },
3324
+ "implementsTokenRanges": [
3325
+ {
3326
+ "startIndex": 8,
3327
+ "endIndex": 10
3328
+ }
3329
+ ]
1194
3330
  },
1195
3331
  {
1196
3332
  "kind": "Interface",
@@ -3297,6 +5433,152 @@
3297
5433
  ],
3298
5434
  "extendsTokenRanges": []
3299
5435
  },
5436
+ {
5437
+ "kind": "Interface",
5438
+ "canonicalReference": "@fgv/ts-web-extras!IFileSystemAccessTreeParams:interface",
5439
+ "docComment": "/**\n * Options for creating persistent file trees.\n *\n * @public\n */\n",
5440
+ "excerptTokens": [
5441
+ {
5442
+ "kind": "Content",
5443
+ "text": "export interface IFileSystemAccessTreeParams<TCT extends "
5444
+ },
5445
+ {
5446
+ "kind": "Content",
5447
+ "text": "string"
5448
+ },
5449
+ {
5450
+ "kind": "Content",
5451
+ "text": " = "
5452
+ },
5453
+ {
5454
+ "kind": "Content",
5455
+ "text": "string"
5456
+ },
5457
+ {
5458
+ "kind": "Content",
5459
+ "text": "> extends "
5460
+ },
5461
+ {
5462
+ "kind": "Reference",
5463
+ "text": "FileTree.IFileTreeInitParams",
5464
+ "canonicalReference": "@fgv/ts-json-base!IFileTreeInitParams:interface"
5465
+ },
5466
+ {
5467
+ "kind": "Content",
5468
+ "text": "<TCT>"
5469
+ },
5470
+ {
5471
+ "kind": "Content",
5472
+ "text": " "
5473
+ }
5474
+ ],
5475
+ "fileUrlPath": "src/packlets/file-tree/fileSystemAccessTreeAccessors.ts",
5476
+ "releaseTag": "Public",
5477
+ "typeParameters": [
5478
+ {
5479
+ "typeParameterName": "TCT",
5480
+ "constraintTokenRange": {
5481
+ "startIndex": 1,
5482
+ "endIndex": 2
5483
+ },
5484
+ "defaultTypeTokenRange": {
5485
+ "startIndex": 3,
5486
+ "endIndex": 4
5487
+ }
5488
+ }
5489
+ ],
5490
+ "name": "IFileSystemAccessTreeParams",
5491
+ "preserveMemberOrder": false,
5492
+ "members": [
5493
+ {
5494
+ "kind": "PropertySignature",
5495
+ "canonicalReference": "@fgv/ts-web-extras!IFileSystemAccessTreeParams#autoSync:member",
5496
+ "docComment": "/**\n * Automatically sync changes to disk immediately after each save. If false, changes are batched and written on explicit syncToDisk() call.\n *\n * @defaultValue false\n */\n",
5497
+ "excerptTokens": [
5498
+ {
5499
+ "kind": "Content",
5500
+ "text": "autoSync?: "
5501
+ },
5502
+ {
5503
+ "kind": "Content",
5504
+ "text": "boolean"
5505
+ },
5506
+ {
5507
+ "kind": "Content",
5508
+ "text": ";"
5509
+ }
5510
+ ],
5511
+ "isReadonly": false,
5512
+ "isOptional": true,
5513
+ "releaseTag": "Public",
5514
+ "name": "autoSync",
5515
+ "propertyTypeTokenRange": {
5516
+ "startIndex": 1,
5517
+ "endIndex": 2
5518
+ }
5519
+ },
5520
+ {
5521
+ "kind": "PropertySignature",
5522
+ "canonicalReference": "@fgv/ts-web-extras!IFileSystemAccessTreeParams#filePath:member",
5523
+ "docComment": "/**\n * Override the path at which the file is stored in the tree (for fromFileHandle). Must be an absolute path (e.g., '/data/confections/common.yaml'). If omitted, defaults to `/<filename>`.\n */\n",
5524
+ "excerptTokens": [
5525
+ {
5526
+ "kind": "Content",
5527
+ "text": "filePath?: "
5528
+ },
5529
+ {
5530
+ "kind": "Content",
5531
+ "text": "string"
5532
+ },
5533
+ {
5534
+ "kind": "Content",
5535
+ "text": ";"
5536
+ }
5537
+ ],
5538
+ "isReadonly": false,
5539
+ "isOptional": true,
5540
+ "releaseTag": "Public",
5541
+ "name": "filePath",
5542
+ "propertyTypeTokenRange": {
5543
+ "startIndex": 1,
5544
+ "endIndex": 2
5545
+ }
5546
+ },
5547
+ {
5548
+ "kind": "PropertySignature",
5549
+ "canonicalReference": "@fgv/ts-web-extras!IFileSystemAccessTreeParams#requireWritePermission:member",
5550
+ "docComment": "/**\n * Require write permission on the directory handle. If true, fails if write permission cannot be obtained. If false, falls back to read-only mode.\n *\n * @defaultValue true\n */\n",
5551
+ "excerptTokens": [
5552
+ {
5553
+ "kind": "Content",
5554
+ "text": "requireWritePermission?: "
5555
+ },
5556
+ {
5557
+ "kind": "Content",
5558
+ "text": "boolean"
5559
+ },
5560
+ {
5561
+ "kind": "Content",
5562
+ "text": ";"
5563
+ }
5564
+ ],
5565
+ "isReadonly": false,
5566
+ "isOptional": true,
5567
+ "releaseTag": "Public",
5568
+ "name": "requireWritePermission",
5569
+ "propertyTypeTokenRange": {
5570
+ "startIndex": 1,
5571
+ "endIndex": 2
5572
+ }
5573
+ }
5574
+ ],
5575
+ "extendsTokenRanges": [
5576
+ {
5577
+ "startIndex": 5,
5578
+ "endIndex": 7
5579
+ }
5580
+ ]
5581
+ },
3300
5582
  {
3301
5583
  "kind": "Interface",
3302
5584
  "canonicalReference": "@fgv/ts-web-extras!IFsAccessApis:interface",
@@ -3433,67 +5715,219 @@
3433
5715
  "name": "showOpenFilePicker"
3434
5716
  },
3435
5717
  {
3436
- "kind": "MethodSignature",
3437
- "canonicalReference": "@fgv/ts-web-extras!IFsAccessApis#showSaveFilePicker:member(1)",
3438
- "docComment": "",
5718
+ "kind": "MethodSignature",
5719
+ "canonicalReference": "@fgv/ts-web-extras!IFsAccessApis#showSaveFilePicker:member(1)",
5720
+ "docComment": "",
5721
+ "excerptTokens": [
5722
+ {
5723
+ "kind": "Content",
5724
+ "text": "showSaveFilePicker(options?: "
5725
+ },
5726
+ {
5727
+ "kind": "Reference",
5728
+ "text": "ShowSaveFilePickerOptions",
5729
+ "canonicalReference": "@fgv/ts-web-extras!ShowSaveFilePickerOptions:interface"
5730
+ },
5731
+ {
5732
+ "kind": "Content",
5733
+ "text": "): "
5734
+ },
5735
+ {
5736
+ "kind": "Reference",
5737
+ "text": "Promise",
5738
+ "canonicalReference": "!Promise:interface"
5739
+ },
5740
+ {
5741
+ "kind": "Content",
5742
+ "text": "<"
5743
+ },
5744
+ {
5745
+ "kind": "Reference",
5746
+ "text": "FileSystemFileHandle",
5747
+ "canonicalReference": "@fgv/ts-web-extras!FileSystemFileHandle_2:interface"
5748
+ },
5749
+ {
5750
+ "kind": "Content",
5751
+ "text": ">"
5752
+ },
5753
+ {
5754
+ "kind": "Content",
5755
+ "text": ";"
5756
+ }
5757
+ ],
5758
+ "isOptional": false,
5759
+ "returnTypeTokenRange": {
5760
+ "startIndex": 3,
5761
+ "endIndex": 7
5762
+ },
5763
+ "releaseTag": "Public",
5764
+ "overloadIndex": 1,
5765
+ "parameters": [
5766
+ {
5767
+ "parameterName": "options",
5768
+ "parameterTypeTokenRange": {
5769
+ "startIndex": 1,
5770
+ "endIndex": 2
5771
+ },
5772
+ "isOptional": true
5773
+ }
5774
+ ],
5775
+ "name": "showSaveFilePicker"
5776
+ }
5777
+ ],
5778
+ "extendsTokenRanges": []
5779
+ },
5780
+ {
5781
+ "kind": "Interface",
5782
+ "canonicalReference": "@fgv/ts-web-extras!ILocalStorageTreeParams:interface",
5783
+ "docComment": "/**\n * Configuration for LocalStorageTreeAccessors.\n *\n * @public\n */\n",
5784
+ "excerptTokens": [
5785
+ {
5786
+ "kind": "Content",
5787
+ "text": "export interface ILocalStorageTreeParams<TCT extends "
5788
+ },
5789
+ {
5790
+ "kind": "Content",
5791
+ "text": "string"
5792
+ },
5793
+ {
5794
+ "kind": "Content",
5795
+ "text": " = "
5796
+ },
5797
+ {
5798
+ "kind": "Content",
5799
+ "text": "string"
5800
+ },
5801
+ {
5802
+ "kind": "Content",
5803
+ "text": "> extends "
5804
+ },
5805
+ {
5806
+ "kind": "Reference",
5807
+ "text": "FileTree.IFileTreeInitParams",
5808
+ "canonicalReference": "@fgv/ts-json-base!IFileTreeInitParams:interface"
5809
+ },
5810
+ {
5811
+ "kind": "Content",
5812
+ "text": "<TCT>"
5813
+ },
5814
+ {
5815
+ "kind": "Content",
5816
+ "text": " "
5817
+ }
5818
+ ],
5819
+ "fileUrlPath": "src/packlets/file-tree/localStorageTreeAccessors.ts",
5820
+ "releaseTag": "Public",
5821
+ "typeParameters": [
5822
+ {
5823
+ "typeParameterName": "TCT",
5824
+ "constraintTokenRange": {
5825
+ "startIndex": 1,
5826
+ "endIndex": 2
5827
+ },
5828
+ "defaultTypeTokenRange": {
5829
+ "startIndex": 3,
5830
+ "endIndex": 4
5831
+ }
5832
+ }
5833
+ ],
5834
+ "name": "ILocalStorageTreeParams",
5835
+ "preserveMemberOrder": false,
5836
+ "members": [
5837
+ {
5838
+ "kind": "PropertySignature",
5839
+ "canonicalReference": "@fgv/ts-web-extras!ILocalStorageTreeParams#autoSync:member",
5840
+ "docComment": "/**\n * If true, automatically sync changes to localStorage on every modification. If false (default), changes are only synced when syncToDisk() is called.\n */\n",
5841
+ "excerptTokens": [
5842
+ {
5843
+ "kind": "Content",
5844
+ "text": "autoSync?: "
5845
+ },
5846
+ {
5847
+ "kind": "Content",
5848
+ "text": "boolean"
5849
+ },
5850
+ {
5851
+ "kind": "Content",
5852
+ "text": ";"
5853
+ }
5854
+ ],
5855
+ "isReadonly": false,
5856
+ "isOptional": true,
5857
+ "releaseTag": "Public",
5858
+ "name": "autoSync",
5859
+ "propertyTypeTokenRange": {
5860
+ "startIndex": 1,
5861
+ "endIndex": 2
5862
+ }
5863
+ },
5864
+ {
5865
+ "kind": "PropertySignature",
5866
+ "canonicalReference": "@fgv/ts-web-extras!ILocalStorageTreeParams#pathToKeyMap:member",
5867
+ "docComment": "/**\n * Map of directory path prefixes to localStorage keys. Files under each prefix are stored in the corresponding localStorage key. Example: \\{ '/data/ingredients': 'myapp:ingredients:v1' \\}\n */\n",
3439
5868
  "excerptTokens": [
3440
5869
  {
3441
5870
  "kind": "Content",
3442
- "text": "showSaveFilePicker(options?: "
5871
+ "text": "pathToKeyMap: "
3443
5872
  },
3444
5873
  {
3445
5874
  "kind": "Reference",
3446
- "text": "ShowSaveFilePickerOptions",
3447
- "canonicalReference": "@fgv/ts-web-extras!ShowSaveFilePickerOptions:interface"
5875
+ "text": "Record",
5876
+ "canonicalReference": "!Record:type"
3448
5877
  },
3449
5878
  {
3450
5879
  "kind": "Content",
3451
- "text": "): "
5880
+ "text": "<string, string>"
3452
5881
  },
3453
5882
  {
3454
- "kind": "Reference",
3455
- "text": "Promise",
3456
- "canonicalReference": "!Promise:interface"
3457
- },
5883
+ "kind": "Content",
5884
+ "text": ";"
5885
+ }
5886
+ ],
5887
+ "isReadonly": false,
5888
+ "isOptional": false,
5889
+ "releaseTag": "Public",
5890
+ "name": "pathToKeyMap",
5891
+ "propertyTypeTokenRange": {
5892
+ "startIndex": 1,
5893
+ "endIndex": 3
5894
+ }
5895
+ },
5896
+ {
5897
+ "kind": "PropertySignature",
5898
+ "canonicalReference": "@fgv/ts-web-extras!ILocalStorageTreeParams#storage:member",
5899
+ "docComment": "/**\n * Storage instance to use. Defaults to window.localStorage. Can be overridden for testing with mock storage.\n */\n",
5900
+ "excerptTokens": [
3458
5901
  {
3459
5902
  "kind": "Content",
3460
- "text": "<"
5903
+ "text": "storage?: "
3461
5904
  },
3462
5905
  {
3463
5906
  "kind": "Reference",
3464
- "text": "FileSystemFileHandle",
3465
- "canonicalReference": "@fgv/ts-web-extras!FileSystemFileHandle_2:interface"
3466
- },
3467
- {
3468
- "kind": "Content",
3469
- "text": ">"
5907
+ "text": "Storage",
5908
+ "canonicalReference": "!Storage:interface"
3470
5909
  },
3471
5910
  {
3472
5911
  "kind": "Content",
3473
5912
  "text": ";"
3474
5913
  }
3475
5914
  ],
3476
- "isOptional": false,
3477
- "returnTypeTokenRange": {
3478
- "startIndex": 3,
3479
- "endIndex": 7
3480
- },
5915
+ "isReadonly": false,
5916
+ "isOptional": true,
3481
5917
  "releaseTag": "Public",
3482
- "overloadIndex": 1,
3483
- "parameters": [
3484
- {
3485
- "parameterName": "options",
3486
- "parameterTypeTokenRange": {
3487
- "startIndex": 1,
3488
- "endIndex": 2
3489
- },
3490
- "isOptional": true
3491
- }
3492
- ],
3493
- "name": "showSaveFilePicker"
5918
+ "name": "storage",
5919
+ "propertyTypeTokenRange": {
5920
+ "startIndex": 1,
5921
+ "endIndex": 2
5922
+ }
3494
5923
  }
3495
5924
  ],
3496
- "extendsTokenRanges": []
5925
+ "extendsTokenRanges": [
5926
+ {
5927
+ "startIndex": 5,
5928
+ "endIndex": 7
5929
+ }
5930
+ ]
3497
5931
  },
3498
5932
  {
3499
5933
  "kind": "Function",
@@ -3625,56 +6059,272 @@
3625
6059
  "text": "): "
3626
6060
  },
3627
6061
  {
3628
- "kind": "Content",
3629
- "text": "boolean"
6062
+ "kind": "Content",
6063
+ "text": "boolean"
6064
+ },
6065
+ {
6066
+ "kind": "Content",
6067
+ "text": ";"
6068
+ }
6069
+ ],
6070
+ "fileUrlPath": "src/packlets/url-utils/urlParams.ts",
6071
+ "returnTypeTokenRange": {
6072
+ "startIndex": 3,
6073
+ "endIndex": 4
6074
+ },
6075
+ "releaseTag": "Public",
6076
+ "overloadIndex": 1,
6077
+ "parameters": [
6078
+ {
6079
+ "parameterName": "path",
6080
+ "parameterTypeTokenRange": {
6081
+ "startIndex": 1,
6082
+ "endIndex": 2
6083
+ },
6084
+ "isOptional": false
6085
+ }
6086
+ ],
6087
+ "name": "isFilePath"
6088
+ },
6089
+ {
6090
+ "kind": "Interface",
6091
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions:interface",
6092
+ "docComment": "/**\n * Configuration options that can be passed via URL parameters\n *\n * @public\n */\n",
6093
+ "excerptTokens": [
6094
+ {
6095
+ "kind": "Content",
6096
+ "text": "export interface IUrlConfigOptions "
6097
+ }
6098
+ ],
6099
+ "fileUrlPath": "src/packlets/url-utils/urlParams.ts",
6100
+ "releaseTag": "Public",
6101
+ "name": "IUrlConfigOptions",
6102
+ "preserveMemberOrder": false,
6103
+ "members": [
6104
+ {
6105
+ "kind": "PropertySignature",
6106
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#config:member",
6107
+ "docComment": "/**\n * Configuration name or path\n */\n",
6108
+ "excerptTokens": [
6109
+ {
6110
+ "kind": "Content",
6111
+ "text": "config?: "
6112
+ },
6113
+ {
6114
+ "kind": "Content",
6115
+ "text": "string"
6116
+ },
6117
+ {
6118
+ "kind": "Content",
6119
+ "text": ";"
6120
+ }
6121
+ ],
6122
+ "isReadonly": false,
6123
+ "isOptional": true,
6124
+ "releaseTag": "Public",
6125
+ "name": "config",
6126
+ "propertyTypeTokenRange": {
6127
+ "startIndex": 1,
6128
+ "endIndex": 2
6129
+ }
6130
+ },
6131
+ {
6132
+ "kind": "PropertySignature",
6133
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#configStartDir:member",
6134
+ "docComment": "/**\n * Starting directory for config file picker (derived from config path)\n */\n",
6135
+ "excerptTokens": [
6136
+ {
6137
+ "kind": "Content",
6138
+ "text": "configStartDir?: "
6139
+ },
6140
+ {
6141
+ "kind": "Content",
6142
+ "text": "string"
6143
+ },
6144
+ {
6145
+ "kind": "Content",
6146
+ "text": ";"
6147
+ }
6148
+ ],
6149
+ "isReadonly": false,
6150
+ "isOptional": true,
6151
+ "releaseTag": "Public",
6152
+ "name": "configStartDir",
6153
+ "propertyTypeTokenRange": {
6154
+ "startIndex": 1,
6155
+ "endIndex": 2
6156
+ }
6157
+ },
6158
+ {
6159
+ "kind": "PropertySignature",
6160
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#contextFilter:member",
6161
+ "docComment": "/**\n * Context filter token (pipe-separated)\n */\n",
6162
+ "excerptTokens": [
6163
+ {
6164
+ "kind": "Content",
6165
+ "text": "contextFilter?: "
6166
+ },
6167
+ {
6168
+ "kind": "Content",
6169
+ "text": "string"
6170
+ },
6171
+ {
6172
+ "kind": "Content",
6173
+ "text": ";"
6174
+ }
6175
+ ],
6176
+ "isReadonly": false,
6177
+ "isOptional": true,
6178
+ "releaseTag": "Public",
6179
+ "name": "contextFilter",
6180
+ "propertyTypeTokenRange": {
6181
+ "startIndex": 1,
6182
+ "endIndex": 2
6183
+ }
6184
+ },
6185
+ {
6186
+ "kind": "PropertySignature",
6187
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#input:member",
6188
+ "docComment": "/**\n * Input file path\n */\n",
6189
+ "excerptTokens": [
6190
+ {
6191
+ "kind": "Content",
6192
+ "text": "input?: "
6193
+ },
6194
+ {
6195
+ "kind": "Content",
6196
+ "text": "string"
6197
+ },
6198
+ {
6199
+ "kind": "Content",
6200
+ "text": ";"
6201
+ }
6202
+ ],
6203
+ "isReadonly": false,
6204
+ "isOptional": true,
6205
+ "releaseTag": "Public",
6206
+ "name": "input",
6207
+ "propertyTypeTokenRange": {
6208
+ "startIndex": 1,
6209
+ "endIndex": 2
6210
+ }
6211
+ },
6212
+ {
6213
+ "kind": "PropertySignature",
6214
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#inputStartDir:member",
6215
+ "docComment": "/**\n * Starting directory for input file picker (derived from input path)\n */\n",
6216
+ "excerptTokens": [
6217
+ {
6218
+ "kind": "Content",
6219
+ "text": "inputStartDir?: "
6220
+ },
6221
+ {
6222
+ "kind": "Content",
6223
+ "text": "string"
6224
+ },
6225
+ {
6226
+ "kind": "Content",
6227
+ "text": ";"
6228
+ }
6229
+ ],
6230
+ "isReadonly": false,
6231
+ "isOptional": true,
6232
+ "releaseTag": "Public",
6233
+ "name": "inputStartDir",
6234
+ "propertyTypeTokenRange": {
6235
+ "startIndex": 1,
6236
+ "endIndex": 2
6237
+ }
6238
+ },
6239
+ {
6240
+ "kind": "PropertySignature",
6241
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#interactive:member",
6242
+ "docComment": "/**\n * Whether to launch in interactive mode\n */\n",
6243
+ "excerptTokens": [
6244
+ {
6245
+ "kind": "Content",
6246
+ "text": "interactive?: "
6247
+ },
6248
+ {
6249
+ "kind": "Content",
6250
+ "text": "boolean"
6251
+ },
6252
+ {
6253
+ "kind": "Content",
6254
+ "text": ";"
6255
+ }
6256
+ ],
6257
+ "isReadonly": false,
6258
+ "isOptional": true,
6259
+ "releaseTag": "Public",
6260
+ "name": "interactive",
6261
+ "propertyTypeTokenRange": {
6262
+ "startIndex": 1,
6263
+ "endIndex": 2
6264
+ }
6265
+ },
6266
+ {
6267
+ "kind": "PropertySignature",
6268
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#loadZip:member",
6269
+ "docComment": "/**\n * Whether to use ZIP loading mode\n */\n",
6270
+ "excerptTokens": [
6271
+ {
6272
+ "kind": "Content",
6273
+ "text": "loadZip?: "
6274
+ },
6275
+ {
6276
+ "kind": "Content",
6277
+ "text": "boolean"
6278
+ },
6279
+ {
6280
+ "kind": "Content",
6281
+ "text": ";"
6282
+ }
6283
+ ],
6284
+ "isReadonly": false,
6285
+ "isOptional": true,
6286
+ "releaseTag": "Public",
6287
+ "name": "loadZip",
6288
+ "propertyTypeTokenRange": {
6289
+ "startIndex": 1,
6290
+ "endIndex": 2
6291
+ }
3630
6292
  },
3631
6293
  {
3632
- "kind": "Content",
3633
- "text": ";"
3634
- }
3635
- ],
3636
- "fileUrlPath": "src/packlets/url-utils/urlParams.ts",
3637
- "returnTypeTokenRange": {
3638
- "startIndex": 3,
3639
- "endIndex": 4
3640
- },
3641
- "releaseTag": "Public",
3642
- "overloadIndex": 1,
3643
- "parameters": [
3644
- {
3645
- "parameterName": "path",
3646
- "parameterTypeTokenRange": {
6294
+ "kind": "PropertySignature",
6295
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#maxDistance:member",
6296
+ "docComment": "/**\n * Maximum distance for language matching\n */\n",
6297
+ "excerptTokens": [
6298
+ {
6299
+ "kind": "Content",
6300
+ "text": "maxDistance?: "
6301
+ },
6302
+ {
6303
+ "kind": "Content",
6304
+ "text": "number"
6305
+ },
6306
+ {
6307
+ "kind": "Content",
6308
+ "text": ";"
6309
+ }
6310
+ ],
6311
+ "isReadonly": false,
6312
+ "isOptional": true,
6313
+ "releaseTag": "Public",
6314
+ "name": "maxDistance",
6315
+ "propertyTypeTokenRange": {
3647
6316
  "startIndex": 1,
3648
6317
  "endIndex": 2
3649
- },
3650
- "isOptional": false
3651
- }
3652
- ],
3653
- "name": "isFilePath"
3654
- },
3655
- {
3656
- "kind": "Interface",
3657
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions:interface",
3658
- "docComment": "/**\n * Configuration options that can be passed via URL parameters\n *\n * @public\n */\n",
3659
- "excerptTokens": [
3660
- {
3661
- "kind": "Content",
3662
- "text": "export interface IUrlConfigOptions "
3663
- }
3664
- ],
3665
- "fileUrlPath": "src/packlets/url-utils/urlParams.ts",
3666
- "releaseTag": "Public",
3667
- "name": "IUrlConfigOptions",
3668
- "preserveMemberOrder": false,
3669
- "members": [
6318
+ }
6319
+ },
3670
6320
  {
3671
6321
  "kind": "PropertySignature",
3672
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#config:member",
3673
- "docComment": "/**\n * Configuration name or path\n */\n",
6322
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#qualifierDefaults:member",
6323
+ "docComment": "/**\n * Qualifier defaults token (pipe-separated)\n */\n",
3674
6324
  "excerptTokens": [
3675
6325
  {
3676
6326
  "kind": "Content",
3677
- "text": "config?: "
6327
+ "text": "qualifierDefaults?: "
3678
6328
  },
3679
6329
  {
3680
6330
  "kind": "Content",
@@ -3688,7 +6338,7 @@
3688
6338
  "isReadonly": false,
3689
6339
  "isOptional": true,
3690
6340
  "releaseTag": "Public",
3691
- "name": "config",
6341
+ "name": "qualifierDefaults",
3692
6342
  "propertyTypeTokenRange": {
3693
6343
  "startIndex": 1,
3694
6344
  "endIndex": 2
@@ -3696,16 +6346,16 @@
3696
6346
  },
3697
6347
  {
3698
6348
  "kind": "PropertySignature",
3699
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#configStartDir:member",
3700
- "docComment": "/**\n * Starting directory for config file picker (derived from config path)\n */\n",
6349
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#reduceQualifiers:member",
6350
+ "docComment": "/**\n * Whether to reduce qualifiers\n */\n",
3701
6351
  "excerptTokens": [
3702
6352
  {
3703
6353
  "kind": "Content",
3704
- "text": "configStartDir?: "
6354
+ "text": "reduceQualifiers?: "
3705
6355
  },
3706
6356
  {
3707
6357
  "kind": "Content",
3708
- "text": "string"
6358
+ "text": "boolean"
3709
6359
  },
3710
6360
  {
3711
6361
  "kind": "Content",
@@ -3715,7 +6365,7 @@
3715
6365
  "isReadonly": false,
3716
6366
  "isOptional": true,
3717
6367
  "releaseTag": "Public",
3718
- "name": "configStartDir",
6368
+ "name": "reduceQualifiers",
3719
6369
  "propertyTypeTokenRange": {
3720
6370
  "startIndex": 1,
3721
6371
  "endIndex": 2
@@ -3723,12 +6373,12 @@
3723
6373
  },
3724
6374
  {
3725
6375
  "kind": "PropertySignature",
3726
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#contextFilter:member",
3727
- "docComment": "/**\n * Context filter token (pipe-separated)\n */\n",
6376
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#resourceTypes:member",
6377
+ "docComment": "/**\n * Resource types filter (comma-separated)\n */\n",
3728
6378
  "excerptTokens": [
3729
6379
  {
3730
6380
  "kind": "Content",
3731
- "text": "contextFilter?: "
6381
+ "text": "resourceTypes?: "
3732
6382
  },
3733
6383
  {
3734
6384
  "kind": "Content",
@@ -3742,7 +6392,7 @@
3742
6392
  "isReadonly": false,
3743
6393
  "isOptional": true,
3744
6394
  "releaseTag": "Public",
3745
- "name": "contextFilter",
6395
+ "name": "resourceTypes",
3746
6396
  "propertyTypeTokenRange": {
3747
6397
  "startIndex": 1,
3748
6398
  "endIndex": 2
@@ -3750,12 +6400,12 @@
3750
6400
  },
3751
6401
  {
3752
6402
  "kind": "PropertySignature",
3753
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#input:member",
3754
- "docComment": "/**\n * Input file path\n */\n",
6403
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#zipFile:member",
6404
+ "docComment": "/**\n * Name of ZIP file to load from Downloads (filename only)\n */\n",
3755
6405
  "excerptTokens": [
3756
6406
  {
3757
6407
  "kind": "Content",
3758
- "text": "input?: "
6408
+ "text": "zipFile?: "
3759
6409
  },
3760
6410
  {
3761
6411
  "kind": "Content",
@@ -3769,7 +6419,7 @@
3769
6419
  "isReadonly": false,
3770
6420
  "isOptional": true,
3771
6421
  "releaseTag": "Public",
3772
- "name": "input",
6422
+ "name": "zipFile",
3773
6423
  "propertyTypeTokenRange": {
3774
6424
  "startIndex": 1,
3775
6425
  "endIndex": 2
@@ -3777,12 +6427,12 @@
3777
6427
  },
3778
6428
  {
3779
6429
  "kind": "PropertySignature",
3780
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#inputStartDir:member",
3781
- "docComment": "/**\n * Starting directory for input file picker (derived from input path)\n */\n",
6430
+ "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#zipPath:member",
6431
+ "docComment": "/**\n * Path to ZIP file to load (for CLI-generated ZIPs)\n */\n",
3782
6432
  "excerptTokens": [
3783
6433
  {
3784
6434
  "kind": "Content",
3785
- "text": "inputStartDir?: "
6435
+ "text": "zipPath?: "
3786
6436
  },
3787
6437
  {
3788
6438
  "kind": "Content",
@@ -3796,128 +6446,283 @@
3796
6446
  "isReadonly": false,
3797
6447
  "isOptional": true,
3798
6448
  "releaseTag": "Public",
3799
- "name": "inputStartDir",
6449
+ "name": "zipPath",
3800
6450
  "propertyTypeTokenRange": {
3801
6451
  "startIndex": 1,
3802
6452
  "endIndex": 2
3803
6453
  }
6454
+ }
6455
+ ],
6456
+ "extendsTokenRanges": []
6457
+ },
6458
+ {
6459
+ "kind": "Class",
6460
+ "canonicalReference": "@fgv/ts-web-extras!LocalStorageTreeAccessors:class",
6461
+ "docComment": "/**\n * Browser localStorage-backed file tree accessors with persistence support.\n *\n * Maps filesystem-like directory paths to localStorage keys, where each key stores multiple collections as a JSON object. This provides a general-purpose implementation for browser-based file tree persistence without requiring File System Access API.\n *\n * Storage format per key: `{ \"collection-id\": \"<raw file content>\" }` File paths map as: `/data/ingredients/collection-id.yaml` → stored in key for `/data/ingredients`\n *\n * Legacy format (v1): `{ \"collection-id\": { ...parsedJsonObject } }` is auto-migrated on load.\n *\n * @remarks\n *\n * The constructor for this class is marked as internal. Third-party code should not call the constructor directly or create subclasses that extend the `LocalStorageTreeAccessors` class.\n *\n * @public\n */\n",
6462
+ "excerptTokens": [
6463
+ {
6464
+ "kind": "Content",
6465
+ "text": "export declare class LocalStorageTreeAccessors<TCT extends "
6466
+ },
6467
+ {
6468
+ "kind": "Content",
6469
+ "text": "string"
6470
+ },
6471
+ {
6472
+ "kind": "Content",
6473
+ "text": " = "
6474
+ },
6475
+ {
6476
+ "kind": "Content",
6477
+ "text": "string"
6478
+ },
6479
+ {
6480
+ "kind": "Content",
6481
+ "text": "> extends "
6482
+ },
6483
+ {
6484
+ "kind": "Reference",
6485
+ "text": "FileTree.InMemoryTreeAccessors",
6486
+ "canonicalReference": "@fgv/ts-json-base!InMemoryTreeAccessors:class"
6487
+ },
6488
+ {
6489
+ "kind": "Content",
6490
+ "text": "<TCT>"
6491
+ },
6492
+ {
6493
+ "kind": "Content",
6494
+ "text": " implements "
6495
+ },
6496
+ {
6497
+ "kind": "Reference",
6498
+ "text": "FileTree.IPersistentFileTreeAccessors",
6499
+ "canonicalReference": "@fgv/ts-json-base!IPersistentFileTreeAccessors:interface"
6500
+ },
6501
+ {
6502
+ "kind": "Content",
6503
+ "text": "<TCT>"
6504
+ },
6505
+ {
6506
+ "kind": "Content",
6507
+ "text": " "
6508
+ }
6509
+ ],
6510
+ "fileUrlPath": "src/packlets/file-tree/localStorageTreeAccessors.ts",
6511
+ "releaseTag": "Public",
6512
+ "typeParameters": [
6513
+ {
6514
+ "typeParameterName": "TCT",
6515
+ "constraintTokenRange": {
6516
+ "startIndex": 1,
6517
+ "endIndex": 2
6518
+ },
6519
+ "defaultTypeTokenRange": {
6520
+ "startIndex": 3,
6521
+ "endIndex": 4
6522
+ }
6523
+ }
6524
+ ],
6525
+ "isAbstract": false,
6526
+ "name": "LocalStorageTreeAccessors",
6527
+ "preserveMemberOrder": false,
6528
+ "members": [
6529
+ {
6530
+ "kind": "Method",
6531
+ "canonicalReference": "@fgv/ts-web-extras!LocalStorageTreeAccessors#fileIsMutable:member(1)",
6532
+ "docComment": "/**\n * Check if a file is mutable and return persistence detail.\n *\n * @param path - File path to check\n *\n * @returns DetailedResult with mutability status and 'persistent' detail if mutable\n *\n * @public\n */\n",
6533
+ "excerptTokens": [
6534
+ {
6535
+ "kind": "Content",
6536
+ "text": "fileIsMutable(path: "
6537
+ },
6538
+ {
6539
+ "kind": "Content",
6540
+ "text": "string"
6541
+ },
6542
+ {
6543
+ "kind": "Content",
6544
+ "text": "): "
6545
+ },
6546
+ {
6547
+ "kind": "Reference",
6548
+ "text": "DetailedResult",
6549
+ "canonicalReference": "@fgv/ts-utils!DetailedResult:type"
6550
+ },
6551
+ {
6552
+ "kind": "Content",
6553
+ "text": "<boolean, "
6554
+ },
6555
+ {
6556
+ "kind": "Reference",
6557
+ "text": "FileTree.SaveDetail",
6558
+ "canonicalReference": "@fgv/ts-json-base!SaveDetail:type"
6559
+ },
6560
+ {
6561
+ "kind": "Content",
6562
+ "text": ">"
6563
+ },
6564
+ {
6565
+ "kind": "Content",
6566
+ "text": ";"
6567
+ }
6568
+ ],
6569
+ "isStatic": false,
6570
+ "returnTypeTokenRange": {
6571
+ "startIndex": 3,
6572
+ "endIndex": 7
6573
+ },
6574
+ "releaseTag": "Public",
6575
+ "isProtected": false,
6576
+ "overloadIndex": 1,
6577
+ "parameters": [
6578
+ {
6579
+ "parameterName": "path",
6580
+ "parameterTypeTokenRange": {
6581
+ "startIndex": 1,
6582
+ "endIndex": 2
6583
+ },
6584
+ "isOptional": false
6585
+ }
6586
+ ],
6587
+ "isOptional": false,
6588
+ "isAbstract": false,
6589
+ "name": "fileIsMutable"
3804
6590
  },
3805
6591
  {
3806
- "kind": "PropertySignature",
3807
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#interactive:member",
3808
- "docComment": "/**\n * Whether to launch in interactive mode\n */\n",
6592
+ "kind": "Method",
6593
+ "canonicalReference": "@fgv/ts-web-extras!LocalStorageTreeAccessors.fromStorage:member(1)",
6594
+ "docComment": "/**\n * Create LocalStorageTreeAccessors from browser localStorage. Loads all collections from the configured storage keys.\n *\n * @param params - Configuration including path-to-key mappings\n *\n * @returns Result containing the accessors or an error\n *\n * @public\n */\n",
3809
6595
  "excerptTokens": [
3810
6596
  {
3811
6597
  "kind": "Content",
3812
- "text": "interactive?: "
6598
+ "text": "static fromStorage<TCT extends "
3813
6599
  },
3814
6600
  {
3815
6601
  "kind": "Content",
3816
- "text": "boolean"
6602
+ "text": "string"
3817
6603
  },
3818
6604
  {
3819
6605
  "kind": "Content",
3820
- "text": ";"
3821
- }
3822
- ],
3823
- "isReadonly": false,
3824
- "isOptional": true,
3825
- "releaseTag": "Public",
3826
- "name": "interactive",
3827
- "propertyTypeTokenRange": {
3828
- "startIndex": 1,
3829
- "endIndex": 2
3830
- }
3831
- },
3832
- {
3833
- "kind": "PropertySignature",
3834
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#loadZip:member",
3835
- "docComment": "/**\n * Whether to use ZIP loading mode\n */\n",
3836
- "excerptTokens": [
6606
+ "text": " = "
6607
+ },
3837
6608
  {
3838
6609
  "kind": "Content",
3839
- "text": "loadZip?: "
6610
+ "text": "string"
3840
6611
  },
3841
6612
  {
3842
6613
  "kind": "Content",
3843
- "text": "boolean"
6614
+ "text": ">(params: "
6615
+ },
6616
+ {
6617
+ "kind": "Reference",
6618
+ "text": "ILocalStorageTreeParams",
6619
+ "canonicalReference": "@fgv/ts-web-extras!ILocalStorageTreeParams:interface"
3844
6620
  },
3845
6621
  {
3846
6622
  "kind": "Content",
3847
- "text": ";"
3848
- }
3849
- ],
3850
- "isReadonly": false,
3851
- "isOptional": true,
3852
- "releaseTag": "Public",
3853
- "name": "loadZip",
3854
- "propertyTypeTokenRange": {
3855
- "startIndex": 1,
3856
- "endIndex": 2
3857
- }
3858
- },
3859
- {
3860
- "kind": "PropertySignature",
3861
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#maxDistance:member",
3862
- "docComment": "/**\n * Maximum distance for language matching\n */\n",
3863
- "excerptTokens": [
6623
+ "text": "<TCT>"
6624
+ },
3864
6625
  {
3865
6626
  "kind": "Content",
3866
- "text": "maxDistance?: "
6627
+ "text": "): "
6628
+ },
6629
+ {
6630
+ "kind": "Reference",
6631
+ "text": "Result",
6632
+ "canonicalReference": "@fgv/ts-utils!Result:type"
3867
6633
  },
3868
6634
  {
3869
6635
  "kind": "Content",
3870
- "text": "number"
6636
+ "text": "<"
6637
+ },
6638
+ {
6639
+ "kind": "Reference",
6640
+ "text": "LocalStorageTreeAccessors",
6641
+ "canonicalReference": "@fgv/ts-web-extras!LocalStorageTreeAccessors:class"
6642
+ },
6643
+ {
6644
+ "kind": "Content",
6645
+ "text": "<TCT>>"
3871
6646
  },
3872
6647
  {
3873
6648
  "kind": "Content",
3874
6649
  "text": ";"
3875
6650
  }
3876
6651
  ],
3877
- "isReadonly": false,
3878
- "isOptional": true,
6652
+ "typeParameters": [
6653
+ {
6654
+ "typeParameterName": "TCT",
6655
+ "constraintTokenRange": {
6656
+ "startIndex": 1,
6657
+ "endIndex": 2
6658
+ },
6659
+ "defaultTypeTokenRange": {
6660
+ "startIndex": 3,
6661
+ "endIndex": 4
6662
+ }
6663
+ }
6664
+ ],
6665
+ "isStatic": true,
6666
+ "returnTypeTokenRange": {
6667
+ "startIndex": 8,
6668
+ "endIndex": 12
6669
+ },
3879
6670
  "releaseTag": "Public",
3880
- "name": "maxDistance",
3881
- "propertyTypeTokenRange": {
3882
- "startIndex": 1,
3883
- "endIndex": 2
3884
- }
6671
+ "isProtected": false,
6672
+ "overloadIndex": 1,
6673
+ "parameters": [
6674
+ {
6675
+ "parameterName": "params",
6676
+ "parameterTypeTokenRange": {
6677
+ "startIndex": 5,
6678
+ "endIndex": 7
6679
+ },
6680
+ "isOptional": false
6681
+ }
6682
+ ],
6683
+ "isOptional": false,
6684
+ "isAbstract": false,
6685
+ "name": "fromStorage"
3885
6686
  },
3886
6687
  {
3887
- "kind": "PropertySignature",
3888
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#qualifierDefaults:member",
3889
- "docComment": "/**\n * Qualifier defaults token (pipe-separated)\n */\n",
6688
+ "kind": "Method",
6689
+ "canonicalReference": "@fgv/ts-web-extras!LocalStorageTreeAccessors#getDirtyPaths:member(1)",
6690
+ "docComment": "/**\n * Get list of file paths with unsaved changes.\n *\n * @returns Array of dirty file paths\n *\n * @public\n */\n",
3890
6691
  "excerptTokens": [
3891
6692
  {
3892
6693
  "kind": "Content",
3893
- "text": "qualifierDefaults?: "
6694
+ "text": "getDirtyPaths(): "
3894
6695
  },
3895
6696
  {
3896
6697
  "kind": "Content",
3897
- "text": "string"
6698
+ "text": "string[]"
3898
6699
  },
3899
6700
  {
3900
6701
  "kind": "Content",
3901
6702
  "text": ";"
3902
6703
  }
3903
6704
  ],
3904
- "isReadonly": false,
3905
- "isOptional": true,
3906
- "releaseTag": "Public",
3907
- "name": "qualifierDefaults",
3908
- "propertyTypeTokenRange": {
6705
+ "isStatic": false,
6706
+ "returnTypeTokenRange": {
3909
6707
  "startIndex": 1,
3910
6708
  "endIndex": 2
3911
- }
6709
+ },
6710
+ "releaseTag": "Public",
6711
+ "isProtected": false,
6712
+ "overloadIndex": 1,
6713
+ "parameters": [],
6714
+ "isOptional": false,
6715
+ "isAbstract": false,
6716
+ "name": "getDirtyPaths"
3912
6717
  },
3913
6718
  {
3914
- "kind": "PropertySignature",
3915
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#reduceQualifiers:member",
3916
- "docComment": "/**\n * Whether to reduce qualifiers\n */\n",
6719
+ "kind": "Method",
6720
+ "canonicalReference": "@fgv/ts-web-extras!LocalStorageTreeAccessors#isDirty:member(1)",
6721
+ "docComment": "/**\n * Check if there are unsaved changes.\n *\n * @returns True if there are dirty files\n *\n * @public\n */\n",
3917
6722
  "excerptTokens": [
3918
6723
  {
3919
6724
  "kind": "Content",
3920
- "text": "reduceQualifiers?: "
6725
+ "text": "isDirty(): "
3921
6726
  },
3922
6727
  {
3923
6728
  "kind": "Content",
@@ -3928,23 +6733,27 @@
3928
6733
  "text": ";"
3929
6734
  }
3930
6735
  ],
3931
- "isReadonly": false,
3932
- "isOptional": true,
3933
- "releaseTag": "Public",
3934
- "name": "reduceQualifiers",
3935
- "propertyTypeTokenRange": {
6736
+ "isStatic": false,
6737
+ "returnTypeTokenRange": {
3936
6738
  "startIndex": 1,
3937
6739
  "endIndex": 2
3938
- }
6740
+ },
6741
+ "releaseTag": "Public",
6742
+ "isProtected": false,
6743
+ "overloadIndex": 1,
6744
+ "parameters": [],
6745
+ "isOptional": false,
6746
+ "isAbstract": false,
6747
+ "name": "isDirty"
3939
6748
  },
3940
6749
  {
3941
- "kind": "PropertySignature",
3942
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#resourceTypes:member",
3943
- "docComment": "/**\n * Resource types filter (comma-separated)\n */\n",
6750
+ "kind": "Method",
6751
+ "canonicalReference": "@fgv/ts-web-extras!LocalStorageTreeAccessors#saveFileContents:member(1)",
6752
+ "docComment": "/**\n * Save file contents. Marks file as dirty and optionally auto-syncs.\n *\n * @param path - File path\n *\n * @param contents - New file contents\n *\n * @returns Result with the saved contents or error\n *\n * @public\n */\n",
3944
6753
  "excerptTokens": [
3945
6754
  {
3946
6755
  "kind": "Content",
3947
- "text": "resourceTypes?: "
6756
+ "text": "saveFileContents(path: "
3948
6757
  },
3949
6758
  {
3950
6759
  "kind": "Content",
@@ -3952,74 +6761,116 @@
3952
6761
  },
3953
6762
  {
3954
6763
  "kind": "Content",
3955
- "text": ";"
3956
- }
3957
- ],
3958
- "isReadonly": false,
3959
- "isOptional": true,
3960
- "releaseTag": "Public",
3961
- "name": "resourceTypes",
3962
- "propertyTypeTokenRange": {
3963
- "startIndex": 1,
3964
- "endIndex": 2
3965
- }
3966
- },
3967
- {
3968
- "kind": "PropertySignature",
3969
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#zipFile:member",
3970
- "docComment": "/**\n * Name of ZIP file to load from Downloads (filename only)\n */\n",
3971
- "excerptTokens": [
6764
+ "text": ", contents: "
6765
+ },
3972
6766
  {
3973
6767
  "kind": "Content",
3974
- "text": "zipFile?: "
6768
+ "text": "string"
3975
6769
  },
3976
6770
  {
3977
6771
  "kind": "Content",
3978
- "text": "string"
6772
+ "text": "): "
6773
+ },
6774
+ {
6775
+ "kind": "Reference",
6776
+ "text": "Result",
6777
+ "canonicalReference": "@fgv/ts-utils!Result:type"
6778
+ },
6779
+ {
6780
+ "kind": "Content",
6781
+ "text": "<string>"
3979
6782
  },
3980
6783
  {
3981
6784
  "kind": "Content",
3982
6785
  "text": ";"
3983
6786
  }
3984
6787
  ],
3985
- "isReadonly": false,
3986
- "isOptional": true,
6788
+ "isStatic": false,
6789
+ "returnTypeTokenRange": {
6790
+ "startIndex": 5,
6791
+ "endIndex": 7
6792
+ },
3987
6793
  "releaseTag": "Public",
3988
- "name": "zipFile",
3989
- "propertyTypeTokenRange": {
3990
- "startIndex": 1,
3991
- "endIndex": 2
3992
- }
6794
+ "isProtected": false,
6795
+ "overloadIndex": 1,
6796
+ "parameters": [
6797
+ {
6798
+ "parameterName": "path",
6799
+ "parameterTypeTokenRange": {
6800
+ "startIndex": 1,
6801
+ "endIndex": 2
6802
+ },
6803
+ "isOptional": false
6804
+ },
6805
+ {
6806
+ "parameterName": "contents",
6807
+ "parameterTypeTokenRange": {
6808
+ "startIndex": 3,
6809
+ "endIndex": 4
6810
+ },
6811
+ "isOptional": false
6812
+ }
6813
+ ],
6814
+ "isOptional": false,
6815
+ "isAbstract": false,
6816
+ "name": "saveFileContents"
3993
6817
  },
3994
6818
  {
3995
- "kind": "PropertySignature",
3996
- "canonicalReference": "@fgv/ts-web-extras!IUrlConfigOptions#zipPath:member",
3997
- "docComment": "/**\n * Path to ZIP file to load (for CLI-generated ZIPs)\n */\n",
6819
+ "kind": "Method",
6820
+ "canonicalReference": "@fgv/ts-web-extras!LocalStorageTreeAccessors#syncToDisk:member(1)",
6821
+ "docComment": "/**\n * Sync all dirty files to localStorage.\n *\n * @returns Result indicating success or failure\n *\n * @public\n */\n",
3998
6822
  "excerptTokens": [
3999
6823
  {
4000
6824
  "kind": "Content",
4001
- "text": "zipPath?: "
6825
+ "text": "syncToDisk(): "
6826
+ },
6827
+ {
6828
+ "kind": "Reference",
6829
+ "text": "Promise",
6830
+ "canonicalReference": "!Promise:interface"
4002
6831
  },
4003
6832
  {
4004
6833
  "kind": "Content",
4005
- "text": "string"
6834
+ "text": "<"
6835
+ },
6836
+ {
6837
+ "kind": "Reference",
6838
+ "text": "Result",
6839
+ "canonicalReference": "@fgv/ts-utils!Result:type"
6840
+ },
6841
+ {
6842
+ "kind": "Content",
6843
+ "text": "<void>>"
4006
6844
  },
4007
6845
  {
4008
6846
  "kind": "Content",
4009
6847
  "text": ";"
4010
6848
  }
4011
6849
  ],
4012
- "isReadonly": false,
4013
- "isOptional": true,
4014
- "releaseTag": "Public",
4015
- "name": "zipPath",
4016
- "propertyTypeTokenRange": {
6850
+ "isStatic": false,
6851
+ "returnTypeTokenRange": {
4017
6852
  "startIndex": 1,
4018
- "endIndex": 2
4019
- }
6853
+ "endIndex": 5
6854
+ },
6855
+ "releaseTag": "Public",
6856
+ "isProtected": false,
6857
+ "overloadIndex": 1,
6858
+ "parameters": [],
6859
+ "isOptional": false,
6860
+ "isAbstract": false,
6861
+ "name": "syncToDisk"
4020
6862
  }
4021
6863
  ],
4022
- "extendsTokenRanges": []
6864
+ "extendsTokenRange": {
6865
+ "startIndex": 5,
6866
+ "endIndex": 7
6867
+ },
6868
+ "implementsTokenRanges": [
6869
+ {
6870
+ "startIndex": 8,
6871
+ "endIndex": 10
6872
+ }
6873
+ ]
4023
6874
  },
4024
6875
  {
4025
6876
  "kind": "Function",