@fgv/ts-web-extras 5.1.0-4 → 5.1.0-40

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 (424) hide show
  1. package/dist/packlets/crypto-utils/browserCryptoProvider.js +330 -18
  2. package/dist/packlets/crypto-utils/browserCryptoProvider.js.map +1 -1
  3. package/dist/packlets/crypto-utils/idbPrivateKeyStorage.js +238 -0
  4. package/dist/packlets/crypto-utils/idbPrivateKeyStorage.js.map +1 -0
  5. package/dist/packlets/crypto-utils/index.js +13 -0
  6. package/dist/packlets/crypto-utils/index.js.map +1 -1
  7. package/dist/packlets/file-tree/directoryHandleStore.js.map +1 -1
  8. package/dist/packlets/file-tree/fileApiTreeAccessors.js +1 -1
  9. package/dist/packlets/file-tree/fileApiTreeAccessors.js.map +1 -1
  10. package/dist/packlets/file-tree/fileSystemAccessTreeAccessors.js +2 -2
  11. package/dist/packlets/file-tree/fileSystemAccessTreeAccessors.js.map +1 -1
  12. package/dist/packlets/file-tree/httpTreeAccessors.js +74 -44
  13. package/dist/packlets/file-tree/httpTreeAccessors.js.map +1 -1
  14. package/dist/packlets/file-tree/localStorageTreeAccessors.js.map +1 -1
  15. package/dist/packlets/helpers/fileTreeHelpers.js +1 -1
  16. package/dist/packlets/helpers/fileTreeHelpers.js.map +1 -1
  17. package/dist/ts-web-extras.d.ts +229 -10
  18. package/dist/tsdoc-metadata.json +1 -1
  19. package/eslint.config.js +32 -0
  20. package/lib/packlets/crypto-utils/browserCryptoProvider.d.ts +115 -6
  21. package/lib/packlets/crypto-utils/browserCryptoProvider.d.ts.map +1 -1
  22. package/lib/packlets/crypto-utils/browserCryptoProvider.js +329 -17
  23. package/lib/packlets/crypto-utils/browserCryptoProvider.js.map +1 -1
  24. package/lib/packlets/crypto-utils/idbPrivateKeyStorage.d.ts +87 -0
  25. package/lib/packlets/crypto-utils/idbPrivateKeyStorage.d.ts.map +1 -0
  26. package/lib/packlets/crypto-utils/idbPrivateKeyStorage.js +242 -0
  27. package/lib/packlets/crypto-utils/idbPrivateKeyStorage.js.map +1 -0
  28. package/lib/packlets/crypto-utils/index.d.ts +14 -0
  29. package/lib/packlets/crypto-utils/index.d.ts.map +1 -1
  30. package/lib/packlets/crypto-utils/index.js +14 -0
  31. package/lib/packlets/crypto-utils/index.js.map +1 -1
  32. package/lib/packlets/file-tree/directoryHandleStore.d.ts +2 -2
  33. package/lib/packlets/file-tree/directoryHandleStore.d.ts.map +1 -1
  34. package/lib/packlets/file-tree/directoryHandleStore.js.map +1 -1
  35. package/lib/packlets/file-tree/fileApiTreeAccessors.d.ts +2 -2
  36. package/lib/packlets/file-tree/fileApiTreeAccessors.d.ts.map +1 -1
  37. package/lib/packlets/file-tree/fileApiTreeAccessors.js +1 -1
  38. package/lib/packlets/file-tree/fileApiTreeAccessors.js.map +1 -1
  39. package/lib/packlets/file-tree/fileSystemAccessTreeAccessors.d.ts.map +1 -1
  40. package/lib/packlets/file-tree/fileSystemAccessTreeAccessors.js +2 -2
  41. package/lib/packlets/file-tree/fileSystemAccessTreeAccessors.js.map +1 -1
  42. package/lib/packlets/file-tree/httpTreeAccessors.d.ts +6 -0
  43. package/lib/packlets/file-tree/httpTreeAccessors.d.ts.map +1 -1
  44. package/lib/packlets/file-tree/httpTreeAccessors.js +74 -44
  45. package/lib/packlets/file-tree/httpTreeAccessors.js.map +1 -1
  46. package/lib/packlets/file-tree/localStorageTreeAccessors.js.map +1 -1
  47. package/lib/packlets/helpers/fileTreeHelpers.d.ts +1 -1
  48. package/lib/packlets/helpers/fileTreeHelpers.d.ts.map +1 -1
  49. package/lib/packlets/helpers/fileTreeHelpers.js +6 -6
  50. package/lib/packlets/helpers/fileTreeHelpers.js.map +1 -1
  51. package/package.json +15 -14
  52. package/.rush/temp/44b0369e8112f3c6f4248af466a3f35ad626d9d7.tar.log +0 -237
  53. package/.rush/temp/chunked-rush-logs/ts-web-extras.build.chunks.jsonl +0 -55
  54. package/.rush/temp/operation/build/all.log +0 -55
  55. package/.rush/temp/operation/build/log-chunks.jsonl +0 -55
  56. package/.rush/temp/operation/build/state.json +0 -3
  57. package/.rush/temp/shrinkwrap-deps.json +0 -692
  58. package/CHANGELOG.md +0 -23
  59. package/config/api-extractor.json +0 -343
  60. package/config/jest.config.json +0 -19
  61. package/config/rig.json +0 -16
  62. package/config/typedoc.json +0 -7
  63. package/dist/test/mocks/idb-keyval.js +0 -6
  64. package/dist/test/mocks/idb-keyval.js.map +0 -1
  65. package/dist/test/setupTests.js +0 -74
  66. package/dist/test/setupTests.js.map +0 -1
  67. package/dist/test/unit/browserHashProvider.test.js +0 -140
  68. package/dist/test/unit/browserHashProvider.test.js.map +0 -1
  69. package/dist/test/unit/directoryHandleStore.test.js +0 -190
  70. package/dist/test/unit/directoryHandleStore.test.js.map +0 -1
  71. package/dist/test/unit/fileApiTreeAccessors.test.js +0 -1188
  72. package/dist/test/unit/fileApiTreeAccessors.test.js.map +0 -1
  73. package/dist/test/unit/fileApiTypes.test.js +0 -472
  74. package/dist/test/unit/fileApiTypes.test.js.map +0 -1
  75. package/dist/test/unit/fileSystemAccessTreeAccessors.test.js +0 -622
  76. package/dist/test/unit/fileSystemAccessTreeAccessors.test.js.map +0 -1
  77. package/dist/test/unit/fileTreeHelpers.test.js +0 -590
  78. package/dist/test/unit/fileTreeHelpers.test.js.map +0 -1
  79. package/dist/test/unit/httpTreeAccessors.test.js +0 -1229
  80. package/dist/test/unit/httpTreeAccessors.test.js.map +0 -1
  81. package/dist/test/unit/localStorageTreeAccessors.test.js +0 -812
  82. package/dist/test/unit/localStorageTreeAccessors.test.js.map +0 -1
  83. package/dist/test/unit/urlParams.test.js +0 -393
  84. package/dist/test/unit/urlParams.test.js.map +0 -1
  85. package/dist/test/utils/fileSystemAccessMocks.js +0 -271
  86. package/dist/test/utils/fileSystemAccessMocks.js.map +0 -1
  87. package/dist/test/utils/testHelpers.js +0 -124
  88. package/dist/test/utils/testHelpers.js.map +0 -1
  89. package/docs/CryptoUtils/README.md +0 -60
  90. package/docs/CryptoUtils/classes/BrowserCryptoProvider.decrypt.md +0 -27
  91. package/docs/CryptoUtils/classes/BrowserCryptoProvider.deriveKey.md +0 -26
  92. package/docs/CryptoUtils/classes/BrowserCryptoProvider.encrypt.md +0 -25
  93. package/docs/CryptoUtils/classes/BrowserCryptoProvider.fromBase64.md +0 -24
  94. package/docs/CryptoUtils/classes/BrowserCryptoProvider.generateKey.md +0 -17
  95. package/docs/CryptoUtils/classes/BrowserCryptoProvider.generateRandomBytes.md +0 -24
  96. package/docs/CryptoUtils/classes/BrowserCryptoProvider.md +0 -151
  97. package/docs/CryptoUtils/classes/BrowserCryptoProvider.toBase64.md +0 -24
  98. package/docs/CryptoUtils/classes/BrowserHashProvider.hashParts.md +0 -26
  99. package/docs/CryptoUtils/classes/BrowserHashProvider.hashString.md +0 -25
  100. package/docs/CryptoUtils/classes/BrowserHashProvider.md +0 -81
  101. package/docs/CryptoUtils/functions/createBrowserCryptoProvider.md +0 -12
  102. package/docs/FileTreeHelpers/README.md +0 -85
  103. package/docs/FileTreeHelpers/functions/extractFileListMetadata.md +0 -11
  104. package/docs/FileTreeHelpers/functions/extractFileMetadata.md +0 -11
  105. package/docs/FileTreeHelpers/functions/fromDirectoryUpload.md +0 -12
  106. package/docs/FileTreeHelpers/functions/fromFileList.md +0 -12
  107. package/docs/FileTreeHelpers/functions/getOriginalFile.md +0 -11
  108. package/docs/FileTreeHelpers/variables/defaultFileApiTreeInitParams.md +0 -9
  109. package/docs/README.md +0 -524
  110. package/docs/classes/BrowserCryptoProvider.decrypt.md +0 -27
  111. package/docs/classes/BrowserCryptoProvider.deriveKey.md +0 -26
  112. package/docs/classes/BrowserCryptoProvider.encrypt.md +0 -25
  113. package/docs/classes/BrowserCryptoProvider.fromBase64.md +0 -24
  114. package/docs/classes/BrowserCryptoProvider.generateKey.md +0 -17
  115. package/docs/classes/BrowserCryptoProvider.generateRandomBytes.md +0 -24
  116. package/docs/classes/BrowserCryptoProvider.md +0 -151
  117. package/docs/classes/BrowserCryptoProvider.toBase64.md +0 -24
  118. package/docs/classes/BrowserHashProvider.hashParts.md +0 -26
  119. package/docs/classes/BrowserHashProvider.hashString.md +0 -25
  120. package/docs/classes/BrowserHashProvider.md +0 -81
  121. package/docs/classes/DirectoryHandleStore.getAll.md +0 -17
  122. package/docs/classes/DirectoryHandleStore.getAllLabels.md +0 -17
  123. package/docs/classes/DirectoryHandleStore.load.md +0 -24
  124. package/docs/classes/DirectoryHandleStore.md +0 -120
  125. package/docs/classes/DirectoryHandleStore.remove.md +0 -24
  126. package/docs/classes/DirectoryHandleStore.save.md +0 -25
  127. package/docs/classes/FileApiTreeAccessors.create.md +0 -25
  128. package/docs/classes/FileApiTreeAccessors.createFromHttp.md +0 -24
  129. package/docs/classes/FileApiTreeAccessors.createFromLocalStorage.md +0 -25
  130. package/docs/classes/FileApiTreeAccessors.createPersistent.md +0 -26
  131. package/docs/classes/FileApiTreeAccessors.createPersistentFromFile.md +0 -27
  132. package/docs/classes/FileApiTreeAccessors.extractFileMetadata.md +0 -24
  133. package/docs/classes/FileApiTreeAccessors.fromDirectoryUpload.md +0 -25
  134. package/docs/classes/FileApiTreeAccessors.fromFileList.md +0 -25
  135. package/docs/classes/FileApiTreeAccessors.getOriginalFile.md +0 -27
  136. package/docs/classes/FileApiTreeAccessors.md +0 -172
  137. package/docs/classes/FileSystemAccessTreeAccessors.deleteFile.md +0 -22
  138. package/docs/classes/FileSystemAccessTreeAccessors.fileIsMutable.md +0 -22
  139. package/docs/classes/FileSystemAccessTreeAccessors.fromDirectoryHandle.md +0 -25
  140. package/docs/classes/FileSystemAccessTreeAccessors.fromFileHandle.md +0 -29
  141. package/docs/classes/FileSystemAccessTreeAccessors.getDirtyPaths.md +0 -15
  142. package/docs/classes/FileSystemAccessTreeAccessors.isDirty.md +0 -15
  143. package/docs/classes/FileSystemAccessTreeAccessors.md +0 -275
  144. package/docs/classes/FileSystemAccessTreeAccessors.saveFileContents.md +0 -23
  145. package/docs/classes/FileSystemAccessTreeAccessors.syncToDisk.md +0 -15
  146. package/docs/classes/HttpTreeAccessors.deleteFile.md +0 -22
  147. package/docs/classes/HttpTreeAccessors.fileIsMutable.md +0 -24
  148. package/docs/classes/HttpTreeAccessors.fromHttp.md +0 -24
  149. package/docs/classes/HttpTreeAccessors.getDirtyPaths.md +0 -17
  150. package/docs/classes/HttpTreeAccessors.isDirty.md +0 -17
  151. package/docs/classes/HttpTreeAccessors.md +0 -261
  152. package/docs/classes/HttpTreeAccessors.saveFileContents.md +0 -25
  153. package/docs/classes/HttpTreeAccessors.syncToDisk.md +0 -22
  154. package/docs/classes/LocalStorageTreeAccessors.deleteFile.md +0 -24
  155. package/docs/classes/LocalStorageTreeAccessors.fileIsMutable.md +0 -24
  156. package/docs/classes/LocalStorageTreeAccessors.fromStorage.md +0 -25
  157. package/docs/classes/LocalStorageTreeAccessors.getDirtyPaths.md +0 -17
  158. package/docs/classes/LocalStorageTreeAccessors.isDirty.md +0 -17
  159. package/docs/classes/LocalStorageTreeAccessors.md +0 -270
  160. package/docs/classes/LocalStorageTreeAccessors.saveFileContents.md +0 -25
  161. package/docs/classes/LocalStorageTreeAccessors.syncToDisk.md +0 -17
  162. package/docs/functions/createBrowserCryptoProvider.md +0 -12
  163. package/docs/functions/exportAsJson.md +0 -12
  164. package/docs/functions/exportUsingFileSystemAPI.md +0 -11
  165. package/docs/functions/extractDirectoryPath.md +0 -13
  166. package/docs/functions/extractFileListMetadata.md +0 -11
  167. package/docs/functions/extractFileMetadata.md +0 -11
  168. package/docs/functions/fromDirectoryUpload.md +0 -12
  169. package/docs/functions/fromFileList.md +0 -12
  170. package/docs/functions/getOriginalFile.md +0 -11
  171. package/docs/functions/isDirectoryHandle.md +0 -11
  172. package/docs/functions/isFileHandle.md +0 -11
  173. package/docs/functions/isFilePath.md +0 -11
  174. package/docs/functions/parseContextFilter.md +0 -12
  175. package/docs/functions/parseQualifierDefaults.md +0 -12
  176. package/docs/functions/parseResourceTypes.md +0 -12
  177. package/docs/functions/parseUrlParameters.md +0 -11
  178. package/docs/functions/safeShowDirectoryPicker.md +0 -11
  179. package/docs/functions/safeShowOpenFilePicker.md +0 -11
  180. package/docs/functions/safeShowSaveFilePicker.md +0 -11
  181. package/docs/functions/supportsFileSystemAccess.md +0 -11
  182. package/docs/interfaces/FilePickerAcceptType.accept.md +0 -9
  183. package/docs/interfaces/FilePickerAcceptType.description.md +0 -9
  184. package/docs/interfaces/FilePickerAcceptType.md +0 -61
  185. package/docs/interfaces/FileSystemCreateWritableOptions.keepExistingData.md +0 -9
  186. package/docs/interfaces/FileSystemCreateWritableOptions.md +0 -44
  187. package/docs/interfaces/FileSystemDirectoryHandle._asyncIterator_.md +0 -13
  188. package/docs/interfaces/FileSystemDirectoryHandle.entries.md +0 -13
  189. package/docs/interfaces/FileSystemDirectoryHandle.getDirectoryHandle.md +0 -21
  190. package/docs/interfaces/FileSystemDirectoryHandle.getFileHandle.md +0 -21
  191. package/docs/interfaces/FileSystemDirectoryHandle.keys.md +0 -13
  192. package/docs/interfaces/FileSystemDirectoryHandle.kind.md +0 -9
  193. package/docs/interfaces/FileSystemDirectoryHandle.md +0 -224
  194. package/docs/interfaces/FileSystemDirectoryHandle.removeEntry.md +0 -21
  195. package/docs/interfaces/FileSystemDirectoryHandle.resolve.md +0 -20
  196. package/docs/interfaces/FileSystemDirectoryHandle.values.md +0 -13
  197. package/docs/interfaces/FileSystemFileHandle.createWritable.md +0 -20
  198. package/docs/interfaces/FileSystemFileHandle.getFile.md +0 -13
  199. package/docs/interfaces/FileSystemFileHandle.kind.md +0 -9
  200. package/docs/interfaces/FileSystemFileHandle.md +0 -146
  201. package/docs/interfaces/FileSystemGetDirectoryOptions.create.md +0 -9
  202. package/docs/interfaces/FileSystemGetDirectoryOptions.md +0 -44
  203. package/docs/interfaces/FileSystemGetFileOptions.create.md +0 -9
  204. package/docs/interfaces/FileSystemGetFileOptions.md +0 -44
  205. package/docs/interfaces/FileSystemHandle.isSameEntry.md +0 -20
  206. package/docs/interfaces/FileSystemHandle.kind.md +0 -9
  207. package/docs/interfaces/FileSystemHandle.md +0 -118
  208. package/docs/interfaces/FileSystemHandle.name.md +0 -9
  209. package/docs/interfaces/FileSystemHandle.queryPermission.md +0 -20
  210. package/docs/interfaces/FileSystemHandle.requestPermission.md +0 -20
  211. package/docs/interfaces/FileSystemHandlePermissionDescriptor.md +0 -44
  212. package/docs/interfaces/FileSystemHandlePermissionDescriptor.mode.md +0 -9
  213. package/docs/interfaces/FileSystemRemoveOptions.md +0 -44
  214. package/docs/interfaces/FileSystemRemoveOptions.recursive.md +0 -9
  215. package/docs/interfaces/FileSystemWritableFileStream.md +0 -142
  216. package/docs/interfaces/FileSystemWritableFileStream.seek.md +0 -20
  217. package/docs/interfaces/FileSystemWritableFileStream.truncate.md +0 -20
  218. package/docs/interfaces/FileSystemWritableFileStream.write.md +0 -20
  219. package/docs/interfaces/IDirectoryHandleTreeInitializer.dirHandles.md +0 -9
  220. package/docs/interfaces/IDirectoryHandleTreeInitializer.md +0 -78
  221. package/docs/interfaces/IDirectoryHandleTreeInitializer.nonRecursive.md +0 -9
  222. package/docs/interfaces/IDirectoryHandleTreeInitializer.prefix.md +0 -9
  223. package/docs/interfaces/IFileHandleTreeInitializer.fileHandles.md +0 -9
  224. package/docs/interfaces/IFileHandleTreeInitializer.md +0 -61
  225. package/docs/interfaces/IFileHandleTreeInitializer.prefix.md +0 -9
  226. package/docs/interfaces/IFileListTreeInitializer.fileList.md +0 -9
  227. package/docs/interfaces/IFileListTreeInitializer.md +0 -44
  228. package/docs/interfaces/IFileMetadata.lastModified.md +0 -9
  229. package/docs/interfaces/IFileMetadata.md +0 -112
  230. package/docs/interfaces/IFileMetadata.name.md +0 -9
  231. package/docs/interfaces/IFileMetadata.path.md +0 -9
  232. package/docs/interfaces/IFileMetadata.size.md +0 -9
  233. package/docs/interfaces/IFileMetadata.type.md +0 -9
  234. package/docs/interfaces/IFileSystemAccessTreeParams.autoSync.md +0 -12
  235. package/docs/interfaces/IFileSystemAccessTreeParams.filePath.md +0 -13
  236. package/docs/interfaces/IFileSystemAccessTreeParams.logger.md +0 -11
  237. package/docs/interfaces/IFileSystemAccessTreeParams.md +0 -148
  238. package/docs/interfaces/IFileSystemAccessTreeParams.requireWritePermission.md +0 -13
  239. package/docs/interfaces/IFsAccessApis.md +0 -62
  240. package/docs/interfaces/IFsAccessApis.showDirectoryPicker.md +0 -20
  241. package/docs/interfaces/IFsAccessApis.showOpenFilePicker.md +0 -20
  242. package/docs/interfaces/IFsAccessApis.showSaveFilePicker.md +0 -20
  243. package/docs/interfaces/IHttpTreeParams.autoSync.md +0 -9
  244. package/docs/interfaces/IHttpTreeParams.baseUrl.md +0 -9
  245. package/docs/interfaces/IHttpTreeParams.fetchImpl.md +0 -9
  246. package/docs/interfaces/IHttpTreeParams.logger.md +0 -9
  247. package/docs/interfaces/IHttpTreeParams.md +0 -182
  248. package/docs/interfaces/IHttpTreeParams.namespace.md +0 -9
  249. package/docs/interfaces/IHttpTreeParams.userId.md +0 -9
  250. package/docs/interfaces/ILocalStorageTreeParams.autoSync.md +0 -12
  251. package/docs/interfaces/ILocalStorageTreeParams.md +0 -131
  252. package/docs/interfaces/ILocalStorageTreeParams.pathToKeyMap.md +0 -13
  253. package/docs/interfaces/ILocalStorageTreeParams.storage.md +0 -12
  254. package/docs/interfaces/IUrlConfigOptions.config.md +0 -11
  255. package/docs/interfaces/IUrlConfigOptions.configStartDir.md +0 -11
  256. package/docs/interfaces/IUrlConfigOptions.contextFilter.md +0 -11
  257. package/docs/interfaces/IUrlConfigOptions.input.md +0 -11
  258. package/docs/interfaces/IUrlConfigOptions.inputStartDir.md +0 -11
  259. package/docs/interfaces/IUrlConfigOptions.interactive.md +0 -11
  260. package/docs/interfaces/IUrlConfigOptions.loadZip.md +0 -11
  261. package/docs/interfaces/IUrlConfigOptions.maxDistance.md +0 -11
  262. package/docs/interfaces/IUrlConfigOptions.md +0 -248
  263. package/docs/interfaces/IUrlConfigOptions.qualifierDefaults.md +0 -11
  264. package/docs/interfaces/IUrlConfigOptions.reduceQualifiers.md +0 -11
  265. package/docs/interfaces/IUrlConfigOptions.resourceTypes.md +0 -11
  266. package/docs/interfaces/IUrlConfigOptions.zipFile.md +0 -11
  267. package/docs/interfaces/IUrlConfigOptions.zipPath.md +0 -11
  268. package/docs/interfaces/ShowDirectoryPickerOptions.id.md +0 -9
  269. package/docs/interfaces/ShowDirectoryPickerOptions.md +0 -78
  270. package/docs/interfaces/ShowDirectoryPickerOptions.mode.md +0 -9
  271. package/docs/interfaces/ShowDirectoryPickerOptions.startIn.md +0 -9
  272. package/docs/interfaces/ShowOpenFilePickerOptions.excludeAcceptAllOption.md +0 -9
  273. package/docs/interfaces/ShowOpenFilePickerOptions.id.md +0 -9
  274. package/docs/interfaces/ShowOpenFilePickerOptions.md +0 -112
  275. package/docs/interfaces/ShowOpenFilePickerOptions.multiple.md +0 -9
  276. package/docs/interfaces/ShowOpenFilePickerOptions.startIn.md +0 -9
  277. package/docs/interfaces/ShowOpenFilePickerOptions.types.md +0 -9
  278. package/docs/interfaces/ShowSaveFilePickerOptions.excludeAcceptAllOption.md +0 -9
  279. package/docs/interfaces/ShowSaveFilePickerOptions.id.md +0 -9
  280. package/docs/interfaces/ShowSaveFilePickerOptions.md +0 -112
  281. package/docs/interfaces/ShowSaveFilePickerOptions.startIn.md +0 -9
  282. package/docs/interfaces/ShowSaveFilePickerOptions.suggestedName.md +0 -9
  283. package/docs/interfaces/ShowSaveFilePickerOptions.types.md +0 -9
  284. package/docs/type-aliases/TreeInitializer.md +0 -11
  285. package/docs/type-aliases/WellKnownDirectory.md +0 -11
  286. package/docs/type-aliases/WindowWithFsAccess.md +0 -11
  287. package/docs/variables/DEFAULT_DIRECTORY_HANDLE_DB.md +0 -9
  288. package/docs/variables/DEFAULT_DIRECTORY_HANDLE_STORE.md +0 -9
  289. package/docs/variables/defaultFileApiTreeInitParams.md +0 -9
  290. package/etc/ts-web-extras.api.md +0 -433
  291. package/lib/test/mocks/idb-keyval.d.ts +0 -6
  292. package/lib/test/mocks/idb-keyval.d.ts.map +0 -1
  293. package/lib/test/mocks/idb-keyval.js +0 -9
  294. package/lib/test/mocks/idb-keyval.js.map +0 -1
  295. package/lib/test/setupTests.d.ts +0 -2
  296. package/lib/test/setupTests.d.ts.map +0 -1
  297. package/lib/test/setupTests.js +0 -76
  298. package/lib/test/setupTests.js.map +0 -1
  299. package/lib/test/unit/browserHashProvider.test.d.ts +0 -2
  300. package/lib/test/unit/browserHashProvider.test.d.ts.map +0 -1
  301. package/lib/test/unit/browserHashProvider.test.js +0 -142
  302. package/lib/test/unit/browserHashProvider.test.js.map +0 -1
  303. package/lib/test/unit/directoryHandleStore.test.d.ts +0 -2
  304. package/lib/test/unit/directoryHandleStore.test.d.ts.map +0 -1
  305. package/lib/test/unit/directoryHandleStore.test.js +0 -192
  306. package/lib/test/unit/directoryHandleStore.test.js.map +0 -1
  307. package/lib/test/unit/fileApiTreeAccessors.test.d.ts +0 -2
  308. package/lib/test/unit/fileApiTreeAccessors.test.d.ts.map +0 -1
  309. package/lib/test/unit/fileApiTreeAccessors.test.js +0 -1190
  310. package/lib/test/unit/fileApiTreeAccessors.test.js.map +0 -1
  311. package/lib/test/unit/fileApiTypes.test.d.ts +0 -2
  312. package/lib/test/unit/fileApiTypes.test.d.ts.map +0 -1
  313. package/lib/test/unit/fileApiTypes.test.js +0 -474
  314. package/lib/test/unit/fileApiTypes.test.js.map +0 -1
  315. package/lib/test/unit/fileSystemAccessTreeAccessors.test.d.ts +0 -2
  316. package/lib/test/unit/fileSystemAccessTreeAccessors.test.d.ts.map +0 -1
  317. package/lib/test/unit/fileSystemAccessTreeAccessors.test.js +0 -624
  318. package/lib/test/unit/fileSystemAccessTreeAccessors.test.js.map +0 -1
  319. package/lib/test/unit/fileTreeHelpers.test.d.ts +0 -2
  320. package/lib/test/unit/fileTreeHelpers.test.d.ts.map +0 -1
  321. package/lib/test/unit/fileTreeHelpers.test.js +0 -592
  322. package/lib/test/unit/fileTreeHelpers.test.js.map +0 -1
  323. package/lib/test/unit/httpTreeAccessors.test.d.ts +0 -2
  324. package/lib/test/unit/httpTreeAccessors.test.d.ts.map +0 -1
  325. package/lib/test/unit/httpTreeAccessors.test.js +0 -1231
  326. package/lib/test/unit/httpTreeAccessors.test.js.map +0 -1
  327. package/lib/test/unit/localStorageTreeAccessors.test.d.ts +0 -2
  328. package/lib/test/unit/localStorageTreeAccessors.test.d.ts.map +0 -1
  329. package/lib/test/unit/localStorageTreeAccessors.test.js +0 -814
  330. package/lib/test/unit/localStorageTreeAccessors.test.js.map +0 -1
  331. package/lib/test/unit/urlParams.test.d.ts +0 -2
  332. package/lib/test/unit/urlParams.test.d.ts.map +0 -1
  333. package/lib/test/unit/urlParams.test.js +0 -395
  334. package/lib/test/unit/urlParams.test.js.map +0 -1
  335. package/lib/test/utils/fileSystemAccessMocks.d.ts +0 -53
  336. package/lib/test/utils/fileSystemAccessMocks.d.ts.map +0 -1
  337. package/lib/test/utils/fileSystemAccessMocks.js +0 -277
  338. package/lib/test/utils/fileSystemAccessMocks.js.map +0 -1
  339. package/lib/test/utils/testHelpers.d.ts +0 -51
  340. package/lib/test/utils/testHelpers.d.ts.map +0 -1
  341. package/lib/test/utils/testHelpers.js +0 -133
  342. package/lib/test/utils/testHelpers.js.map +0 -1
  343. package/rush-logs/ts-web-extras.build.cache.log +0 -3
  344. package/rush-logs/ts-web-extras.build.log +0 -55
  345. package/src/index.browser.ts +0 -24
  346. package/src/index.ts +0 -47
  347. package/src/packlets/crypto-utils/browserCryptoProvider.ts +0 -311
  348. package/src/packlets/crypto-utils/browserHashProvider.ts +0 -73
  349. package/src/packlets/crypto-utils/index.ts +0 -29
  350. package/src/packlets/file-api-types/index.ts +0 -366
  351. package/src/packlets/file-tree/directoryHandleStore.ts +0 -136
  352. package/src/packlets/file-tree/fileApiTreeAccessors.ts +0 -528
  353. package/src/packlets/file-tree/fileSystemAccessTreeAccessors.ts +0 -519
  354. package/src/packlets/file-tree/httpTreeAccessors.ts +0 -448
  355. package/src/packlets/file-tree/index.ts +0 -32
  356. package/src/packlets/file-tree/localStorageTreeAccessors.ts +0 -430
  357. package/src/packlets/helpers/fileTreeHelpers.ts +0 -107
  358. package/src/packlets/helpers/index.ts +0 -28
  359. package/src/packlets/url-utils/index.ts +0 -28
  360. package/src/packlets/url-utils/urlParams.ts +0 -245
  361. package/src/test/mocks/idb-keyval.ts +0 -5
  362. package/src/test/setupTests.ts +0 -87
  363. package/src/test/unit/browserHashProvider.test.ts +0 -155
  364. package/src/test/unit/browserHashProvider.test.ts.bak +0 -376
  365. package/src/test/unit/directoryHandleStore.test.ts +0 -251
  366. package/src/test/unit/fileApiTreeAccessors.test.ts +0 -1387
  367. package/src/test/unit/fileApiTypes.test.ts +0 -587
  368. package/src/test/unit/fileSystemAccessTreeAccessors.test.ts +0 -885
  369. package/src/test/unit/fileTreeHelpers.test.ts +0 -694
  370. package/src/test/unit/httpTreeAccessors.test.ts +0 -1571
  371. package/src/test/unit/localStorageTreeAccessors.test.ts +0 -1014
  372. package/src/test/unit/urlParams.test.ts +0 -464
  373. package/src/test/utils/fileSystemAccessMocks.ts +0 -353
  374. package/src/test/utils/testHelpers.ts +0 -155
  375. package/temp/build/typescript/ts_8nwakTlr.json +0 -1
  376. package/temp/coverage/base.css +0 -224
  377. package/temp/coverage/block-navigation.js +0 -87
  378. package/temp/coverage/crypto-utils/browserCryptoProvider.ts.html +0 -1018
  379. package/temp/coverage/crypto-utils/browserHashProvider.ts.html +0 -304
  380. package/temp/coverage/crypto-utils/index.html +0 -131
  381. package/temp/coverage/favicon.png +0 -0
  382. package/temp/coverage/file-tree/directoryHandleStore.ts.html +0 -493
  383. package/temp/coverage/file-tree/fileApiTreeAccessors.ts.html +0 -1669
  384. package/temp/coverage/file-tree/fileSystemAccessTreeAccessors.ts.html +0 -1642
  385. package/temp/coverage/file-tree/httpTreeAccessors.ts.html +0 -1429
  386. package/temp/coverage/file-tree/index.html +0 -176
  387. package/temp/coverage/file-tree/localStorageTreeAccessors.ts.html +0 -1375
  388. package/temp/coverage/helpers/fileTreeHelpers.ts.html +0 -406
  389. package/temp/coverage/helpers/index.html +0 -116
  390. package/temp/coverage/index.html +0 -161
  391. package/temp/coverage/lcov-report/base.css +0 -224
  392. package/temp/coverage/lcov-report/block-navigation.js +0 -87
  393. package/temp/coverage/lcov-report/crypto-utils/browserCryptoProvider.ts.html +0 -1018
  394. package/temp/coverage/lcov-report/crypto-utils/browserHashProvider.ts.html +0 -304
  395. package/temp/coverage/lcov-report/crypto-utils/index.html +0 -131
  396. package/temp/coverage/lcov-report/favicon.png +0 -0
  397. package/temp/coverage/lcov-report/file-tree/directoryHandleStore.ts.html +0 -493
  398. package/temp/coverage/lcov-report/file-tree/fileApiTreeAccessors.ts.html +0 -1669
  399. package/temp/coverage/lcov-report/file-tree/fileSystemAccessTreeAccessors.ts.html +0 -1642
  400. package/temp/coverage/lcov-report/file-tree/httpTreeAccessors.ts.html +0 -1429
  401. package/temp/coverage/lcov-report/file-tree/index.html +0 -176
  402. package/temp/coverage/lcov-report/file-tree/localStorageTreeAccessors.ts.html +0 -1375
  403. package/temp/coverage/lcov-report/helpers/fileTreeHelpers.ts.html +0 -406
  404. package/temp/coverage/lcov-report/helpers/index.html +0 -116
  405. package/temp/coverage/lcov-report/index.html +0 -161
  406. package/temp/coverage/lcov-report/prettify.css +0 -1
  407. package/temp/coverage/lcov-report/prettify.js +0 -2
  408. package/temp/coverage/lcov-report/sort-arrow-sprite.png +0 -0
  409. package/temp/coverage/lcov-report/sorter.js +0 -210
  410. package/temp/coverage/lcov-report/url-utils/index.html +0 -116
  411. package/temp/coverage/lcov-report/url-utils/urlParams.ts.html +0 -820
  412. package/temp/coverage/lcov.info +0 -3597
  413. package/temp/coverage/prettify.css +0 -1
  414. package/temp/coverage/prettify.js +0 -2
  415. package/temp/coverage/sort-arrow-sprite.png +0 -0
  416. package/temp/coverage/sorter.js +0 -210
  417. package/temp/coverage/url-utils/index.html +0 -116
  418. package/temp/coverage/url-utils/urlParams.ts.html +0 -820
  419. package/temp/test/jest/haste-map-7492f1b44480e0cdd1f220078fb3afd8-c8dd6c3430605adeb2f1cadf4f75e791-8c9336785555d572065b28c111982ba4 +0 -0
  420. package/temp/test/jest/jest-transform-cache-7492f1b44480e0cdd1f220078fb3afd8-79ef2876fae7ca75eedb2aa53dc48338/7c/package_7c16afc8299e635d80273763175c7a50 +0 -53
  421. package/temp/test/jest/perf-cache-7492f1b44480e0cdd1f220078fb3afd8-da39a3ee5e6b4b0d3255bfef95601890 +0 -1
  422. package/temp/ts-web-extras.api.json +0 -8850
  423. package/temp/ts-web-extras.api.md +0 -433
  424. package/tsconfig.json +0 -7
@@ -14,6 +14,7 @@ import { DetailedResult } from '@fgv/ts-utils';
14
14
  import { FileTree } from '@fgv/ts-json-base';
15
15
  import { Logging } from '@fgv/ts-utils';
16
16
  import { Result } from '@fgv/ts-utils';
17
+ import { Uuid } from '@fgv/ts-utils';
17
18
 
18
19
  /**
19
20
  * Browser implementation of `ICryptoProvider` using the Web Crypto API.
@@ -24,7 +25,7 @@ import { Result } from '@fgv/ts-utils';
24
25
  *
25
26
  * @public
26
27
  */
27
- declare class BrowserCryptoProvider implements ICryptoProvider {
28
+ declare class BrowserCryptoProvider implements CryptoUtils_2.ICryptoProvider {
28
29
  private readonly _crypto;
29
30
  /**
30
31
  * Creates a new {@link CryptoUtils.BrowserCryptoProvider | BrowserCryptoProvider}.
@@ -37,7 +38,7 @@ declare class BrowserCryptoProvider implements ICryptoProvider {
37
38
  * @param key - 32-byte encryption key
38
39
  * @returns `Success` with encryption result, or `Failure` with an error.
39
40
  */
40
- encrypt(plaintext: string, key: Uint8Array): Promise<Result<IEncryptionResult>>;
41
+ encrypt(plaintext: string, key: Uint8Array): Promise<Result<CryptoUtils_2.IEncryptionResult>>;
41
42
  /**
42
43
  * Decrypts ciphertext using AES-256-GCM.
43
44
  * @param encryptedData - Encrypted bytes
@@ -60,12 +61,25 @@ declare class BrowserCryptoProvider implements ICryptoProvider {
60
61
  * @returns Success with derived 32-byte key, or Failure with error
61
62
  */
62
63
  deriveKey(password: string, salt: Uint8Array, iterations: number): Promise<Result<Uint8Array>>;
64
+ /**
65
+ * Computes a SHA-256 hash of the given data.
66
+ * @param data - UTF-8 string to hash
67
+ * @returns `Success` with hex-encoded hash string, or `Failure` with an error.
68
+ */
69
+ sha256(data: string): Promise<Result<string>>;
63
70
  /**
64
71
  * Generates cryptographically secure random bytes.
65
72
  * @param length - Number of bytes to generate
66
73
  * @returns Success with random bytes, or Failure with error
67
74
  */
68
75
  generateRandomBytes(length: number): Result<Uint8Array>;
76
+ /**
77
+ * Generates a cryptographically random UUIDv4 using the injected
78
+ * `Crypto` instance.
79
+ * @returns `Success` with the generated UUID, or `Failure` if the underlying
80
+ * `Crypto` instance does not expose `randomUUID`.
81
+ */
82
+ generateUuid(): Result<Uuid>;
69
83
  /**
70
84
  * Encodes binary data to base64 string.
71
85
  * @param data - Binary data to encode
@@ -78,6 +92,105 @@ declare class BrowserCryptoProvider implements ICryptoProvider {
78
92
  * @returns Success with decoded bytes, or Failure if invalid base64
79
93
  */
80
94
  fromBase64(base64: string): Result<Uint8Array>;
95
+ /**
96
+ * Generates a new asymmetric keypair via Web Crypto.
97
+ * @param algorithm - The algorithm to use.
98
+ * @param extractable - Whether the resulting keys may be exported.
99
+ * @returns `Success` with the generated `CryptoKeyPair`, or `Failure` with an error.
100
+ */
101
+ generateKeyPair(algorithm: CryptoUtils_2.KeyPairAlgorithm, extractable: boolean): Promise<Result<CryptoKeyPair>>;
102
+ /**
103
+ * Exports a public `CryptoKey` as a JSON Web Key.
104
+ * @remarks
105
+ * Rejects non-public keys at runtime. WebCrypto's `exportKey('jwk', ...)`
106
+ * does not enforce public-vs-private; without this guard a caller that
107
+ * passed an extractable private key would receive its private fields
108
+ * (`d`, `p`, `q`, ...) as JWK, defeating the method's name.
109
+ * @param publicKey - Extractable public key to export.
110
+ * @returns `Success` with the JWK, or `Failure` if not a public key or if export fails.
111
+ */
112
+ exportPublicKeyJwk(publicKey: CryptoKey): Promise<Result<JsonWebKey>>;
113
+ /**
114
+ * Imports a public-key JWK as a `CryptoKey` for the requested algorithm.
115
+ * @param jwk - The JSON Web Key produced by a prior export.
116
+ * @param algorithm - The algorithm the key was generated for.
117
+ * @returns `Success` with the imported public `CryptoKey`, or `Failure` with an error.
118
+ */
119
+ importPublicKeyJwk(jwk: JsonWebKey, algorithm: CryptoUtils_2.KeyPairAlgorithm): Promise<Result<CryptoKey>>;
120
+ /**
121
+ * Exports a public `CryptoKey` as a DER-encoded SPKI blob.
122
+ * @param publicKey - The public `CryptoKey` to export.
123
+ * @returns `Success` with the raw SPKI bytes, or `Failure` with error context.
124
+ */
125
+ exportPublicKeySpki(publicKey: CryptoKey): Promise<Result<Uint8Array>>;
126
+ /**
127
+ * Imports a public key from a DER-encoded SPKI blob.
128
+ * @param spkiBytes - The raw SPKI bytes.
129
+ * @param algorithm - The algorithm the key was generated for.
130
+ * @returns `Success` with the imported public `CryptoKey`, or `Failure` with error context.
131
+ */
132
+ importPublicKeySpki(spkiBytes: Uint8Array, algorithm: CryptoUtils_2.KeyPairAlgorithm): Promise<Result<CryptoKey>>;
133
+ /**
134
+ * Signs `data` with `privateKey` using the algorithm inferred from the key.
135
+ * @param privateKey - A signing `CryptoKey` (`'ecdsa-p256'` or `'ed25519'`).
136
+ * @param data - The bytes to sign.
137
+ * @returns `Success` with the raw signature bytes, or `Failure` with error context.
138
+ */
139
+ sign(privateKey: CryptoKey, data: Uint8Array): Promise<Result<Uint8Array>>;
140
+ /**
141
+ * Verifies a signature produced by {@link BrowserCryptoProvider.sign}.
142
+ * @param publicKey - A verify `CryptoKey` (`'ecdsa-p256'` or `'ed25519'`).
143
+ * @param signature - The raw signature bytes.
144
+ * @param data - The original data that was signed.
145
+ * @returns `Success` with `true` if valid, `false` if not, or `Failure` with error context.
146
+ */
147
+ verify(publicKey: CryptoKey, signature: Uint8Array, data: Uint8Array): Promise<Result<boolean>>;
148
+ /**
149
+ * Compares two byte arrays in constant time.
150
+ *
151
+ * Accumulates XOR differences with bitwise-OR; no early-return is possible
152
+ * once the length check passes, making timing independent of the byte
153
+ * values. Returns `false` immediately on length mismatch (length is not
154
+ * secret in normal use).
155
+ * @param a - First byte array.
156
+ * @param b - Second byte array.
157
+ * @returns `true` if lengths match and all bytes are equal, `false` otherwise.
158
+ */
159
+ timingSafeEqual(a: Uint8Array, b: Uint8Array): boolean;
160
+ /**
161
+ * Computes an HMAC-SHA256 MAC for `data` using `key`.
162
+ * @param key - An HMAC `CryptoKey` with `'sign'` usage.
163
+ * @param data - The bytes to authenticate.
164
+ * @returns `Success` with the 32-byte MAC, or `Failure` with error context.
165
+ */
166
+ hmacSha256(key: CryptoKey, data: Uint8Array): Promise<Result<Uint8Array>>;
167
+ /**
168
+ * Verifies an HMAC-SHA256 MAC in constant time.
169
+ * @param key - An HMAC `CryptoKey` with `'sign'` usage.
170
+ * @param signature - The MAC bytes to verify.
171
+ * @param data - The original data that was authenticated.
172
+ * @returns `Success` with `true` if valid, `false` if not, or `Failure` with error context.
173
+ */
174
+ verifyHmacSha256(key: CryptoKey, signature: Uint8Array, data: Uint8Array): Promise<Result<boolean>>;
175
+ /**
176
+ * Wraps `plaintext` for the holder of `recipientPublicKey` using
177
+ * ECIES (ECDH P-256 + HKDF-SHA256 + AES-GCM-256). See
178
+ * {@link CryptoUtils.ICryptoProvider.wrapBytes | ICryptoProvider.wrapBytes}.
179
+ * @param plaintext - The bytes to wrap.
180
+ * @param recipientPublicKey - The recipient's ECDH P-256 public `CryptoKey`.
181
+ * @param options - HKDF salt and info; see {@link CryptoUtils.IWrapBytesOptions | IWrapBytesOptions}.
182
+ * @returns `Success` with the wrapped payload, or `Failure` with an error.
183
+ */
184
+ wrapBytes(plaintext: Uint8Array, recipientPublicKey: CryptoKey, options: CryptoUtils_2.IWrapBytesOptions): Promise<Result<CryptoUtils_2.IWrappedBytes>>;
185
+ /**
186
+ * Unwraps a payload produced by `wrapBytes` using the recipient's private
187
+ * key. See {@link CryptoUtils.ICryptoProvider.unwrapBytes | ICryptoProvider.unwrapBytes}.
188
+ * @param wrapped - The wrapped payload.
189
+ * @param recipientPrivateKey - The recipient's ECDH P-256 private `CryptoKey`.
190
+ * @param options - HKDF salt and info matching the wrap call.
191
+ * @returns `Success` with the original `plaintext`, or `Failure` with an error.
192
+ */
193
+ unwrapBytes(wrapped: CryptoUtils_2.IWrappedBytes, recipientPrivateKey: CryptoKey, options: CryptoUtils_2.IWrapBytesOptions): Promise<Result<Uint8Array>>;
81
194
  }
82
195
 
83
196
  /**
@@ -113,9 +226,13 @@ declare function createBrowserCryptoProvider(): Result<BrowserCryptoProvider>;
113
226
 
114
227
  declare namespace CryptoUtils {
115
228
  export {
229
+ HpkeProvider,
230
+ IHpkeSealResult,
116
231
  BrowserHashProvider,
117
232
  createBrowserCryptoProvider,
118
- BrowserCryptoProvider
233
+ BrowserCryptoProvider,
234
+ IIdbPrivateKeyStorageCreateParams,
235
+ IdbPrivateKeyStorage
119
236
  }
120
237
  }
121
238
  export { CryptoUtils }
@@ -124,13 +241,13 @@ export { CryptoUtils }
124
241
  * Default IndexedDB database name for directory handles.
125
242
  * @public
126
243
  */
127
- export declare const DEFAULT_DIRECTORY_HANDLE_DB = "chocolate-lab-storage";
244
+ export declare const DEFAULT_DIRECTORY_HANDLE_DB: string;
128
245
 
129
246
  /**
130
247
  * Default IndexedDB store name for directory handles.
131
248
  * @public
132
249
  */
133
- export declare const DEFAULT_DIRECTORY_HANDLE_STORE = "directory-handles";
250
+ export declare const DEFAULT_DIRECTORY_HANDLE_STORE: string;
134
251
 
135
252
  /**
136
253
  * Default initialization parameters for a `FileTree` using {@link FileApiTreeAccessors}.
@@ -229,7 +346,7 @@ declare function extractFileListMetadata(fileList: FileList): Array<IFileMetadat
229
346
  * Supports File API (FileList) and File System Access API handles.
230
347
  * @public
231
348
  */
232
- export declare class FileApiTreeAccessors<TCT extends string = string> {
349
+ export declare class FileApiTreeAccessors {
233
350
  /**
234
351
  * Create a persistent FileTree from a File System Access API directory handle.
235
352
  * Changes to files can be synced back to disk.
@@ -325,7 +442,7 @@ declare function extractFileListMetadata(fileList: FileList): Array<IFileMetadat
325
442
  static getOriginalFile(fileList: FileList, targetPath: string): Result<File>;
326
443
  /**
327
444
  * Extract file metadata from a File.
328
- * @param fileList - The File to extract metadata from
445
+ * @param file - The File to extract metadata from
329
446
  * @returns The {@link IFileMetadata | file metadata}
330
447
  */
331
448
  static extractFileMetadata(file: File): IFileMetadata;
@@ -651,6 +768,14 @@ declare function extractFileListMetadata(fileList: FileList): Array<IFileMetadat
651
768
  */
652
769
  declare function getOriginalFile(fileList: FileList, path: string): Result<File>;
653
770
 
771
+ /**
772
+ * HPKE base mode (RFC 9180) — `DHKEM(X25519, HKDF-SHA256) + HKDF-SHA256 + AES-256-GCM`.
773
+ * Re-exported from `@fgv/ts-extras` for browser consumers.
774
+ * @see {@link CryptoUtils.HpkeProvider}
775
+ * @public
776
+ */
777
+ declare const HpkeProvider: typeof CryptoUtils_2.HpkeProvider;
778
+
654
779
  /**
655
780
  * HTTP-backed file tree accessors that cache data in memory and persist via REST API.
656
781
  * @public
@@ -686,6 +811,12 @@ declare function extractFileListMetadata(fileList: FileList): Array<IFileMetadat
686
811
  */
687
812
  syncToDisk(): Promise<Result<void>>;
688
813
  private _doSync;
814
+ /**
815
+ * Restores snapshotted items back into the live dirty sets so they
816
+ * are retried on the next sync attempt. Items that were added to
817
+ * the live sets while the sync was in flight are preserved.
818
+ */
819
+ private _restoreUnsynced;
689
820
  /**
690
821
  * Checks if there are any dirty files that need synchronization.
691
822
  * @returns True if there are dirty files, false otherwise.
@@ -739,7 +870,70 @@ declare function extractFileListMetadata(fileList: FileList): Array<IFileMetadat
739
870
  private static _requestWithParams;
740
871
  }
741
872
 
742
- declare type ICryptoProvider = CryptoUtils_2.ICryptoProvider;
873
+ /**
874
+ * {@link CryptoUtils.KeyStore.IPrivateKeyStorage | IPrivateKeyStorage}
875
+ * implementation backed by IndexedDB. Stores `CryptoKey` objects directly via
876
+ * IndexedDB's structured-clone serialization — no JWK round-trip — so it works
877
+ * with non-extractable keys.
878
+ *
879
+ * `supportsNonExtractable` is `true`: because the `CryptoKey` is stored by
880
+ * reference (structured clone) rather than exported, the keystore may generate
881
+ * `extractable: false` keys for maximum security on browsers that support it.
882
+ *
883
+ * The database is opened lazily on first use and cached. Each operation runs in
884
+ * its own transaction, relying on IndexedDB's default serialization. Multi-tab
885
+ * concurrency is a known limitation: two tabs writing the same id can race; this
886
+ * implementation targets single-tab use.
887
+ *
888
+ * @public
889
+ */
890
+ declare class IdbPrivateKeyStorage implements CryptoUtils_2.KeyStore.IPrivateKeyStorage {
891
+ /**
892
+ * `true` — IndexedDB stores `CryptoKey` objects directly, so non-extractable
893
+ * keys are supported.
894
+ */
895
+ readonly supportsNonExtractable: true;
896
+ private readonly _factory;
897
+ private readonly _databaseName;
898
+ private readonly _storeName;
899
+ private _db;
900
+ private constructor();
901
+ /**
902
+ * Creates a new {@link CryptoUtils.IdbPrivateKeyStorage}.
903
+ * @param params - Optional {@link CryptoUtils.IIdbPrivateKeyStorageCreateParams}.
904
+ * @returns `Success` with the new instance, or `Failure` if no IndexedDB
905
+ * factory is available.
906
+ */
907
+ static create(params?: IIdbPrivateKeyStorageCreateParams): Result<IdbPrivateKeyStorage>;
908
+ /**
909
+ * Stores `key` under `id`.
910
+ * @param id - Storage handle to write under.
911
+ * @param key - The private `CryptoKey` to persist.
912
+ */
913
+ store(id: string, key: CryptoKey): Promise<Result<string>>;
914
+ /**
915
+ * Loads the private key stored under `id`.
916
+ * @param id - Storage handle to look up.
917
+ */
918
+ load(id: string): Promise<Result<CryptoKey>>;
919
+ /**
920
+ * Deletes the entry stored under `id`. Missing ids fail, mirroring the
921
+ * encrypted-file backend. The existence check and the delete run in separate
922
+ * transactions (single-tab assumption).
923
+ * @param id - Storage handle to remove.
924
+ */
925
+ delete(id: string): Promise<Result<string>>;
926
+ /**
927
+ * Lists every stored id.
928
+ */
929
+ list(): Promise<Result<readonly string[]>>;
930
+ private _getRaw;
931
+ private _openDb;
932
+ private _open;
933
+ private _withStore;
934
+ private _request;
935
+ private _awaitCompletion;
936
+ }
743
937
 
744
938
  /**
745
939
  * Tree initializer for File System Access API directory handles.
@@ -751,8 +945,6 @@ declare function extractFileListMetadata(fileList: FileList): Array<IFileMetadat
751
945
  readonly nonRecursive?: boolean;
752
946
  }
753
947
 
754
- declare type IEncryptionResult = CryptoUtils_2.IEncryptionResult;
755
-
756
948
  /**
757
949
  * Tree initializer for File System Access API file handles.
758
950
  * @public
@@ -820,6 +1012,12 @@ declare function extractFileListMetadata(fileList: FileList): Array<IFileMetadat
820
1012
  showSaveFilePicker(options?: ShowSaveFilePickerOptions): Promise<FileSystemFileHandle_2>;
821
1013
  }
822
1014
 
1015
+ /**
1016
+ * Output of `HpkeProvider.sealBase`. Re-exported from `@fgv/ts-extras`.
1017
+ * @public
1018
+ */
1019
+ declare type IHpkeSealResult = CryptoUtils_2.IHpkeSealResult;
1020
+
823
1021
  /**
824
1022
  * Configuration for creating HTTP-backed tree accessors.
825
1023
  * @public
@@ -833,6 +1031,27 @@ declare function extractFileListMetadata(fileList: FileList): Array<IFileMetadat
833
1031
  readonly logger?: Logging.LogReporter<unknown>;
834
1032
  }
835
1033
 
1034
+ /**
1035
+ * Parameters for {@link CryptoUtils.IdbPrivateKeyStorage.create}.
1036
+ * @public
1037
+ */
1038
+ declare interface IIdbPrivateKeyStorageCreateParams {
1039
+ /**
1040
+ * IndexedDB database name. Default: `'fgv-keystore-private-keys'`.
1041
+ */
1042
+ readonly databaseName?: string;
1043
+ /**
1044
+ * IndexedDB object-store name. Default: `'privateKeys'`.
1045
+ */
1046
+ readonly storeName?: string;
1047
+ /**
1048
+ * IndexedDB factory to use. Defaults to `globalThis.indexedDB`. Supplied
1049
+ * explicitly in tests (e.g. a `fake-indexeddb` factory) or to target a
1050
+ * non-default factory.
1051
+ */
1052
+ readonly indexedDB?: IDBFactory;
1053
+ }
1054
+
836
1055
  /**
837
1056
  * Configuration for LocalStorageTreeAccessors.
838
1057
  * @public
@@ -5,7 +5,7 @@
5
5
  "toolPackages": [
6
6
  {
7
7
  "packageName": "@microsoft/api-extractor",
8
- "packageVersion": "7.57.7"
8
+ "packageVersion": "7.58.9"
9
9
  }
10
10
  ]
11
11
  }
@@ -0,0 +1,32 @@
1
+ // ESLint 9 flat config
2
+ const nodeProfile = require('@rushstack/eslint-config/flat/profile/node');
3
+ const packletsPlugin = require('@rushstack/eslint-config/flat/mixins/packlets');
4
+ const tsdocPlugin = require('@rushstack/eslint-config/flat/mixins/tsdoc');
5
+
6
+ module.exports = [
7
+ ...nodeProfile,
8
+ packletsPlugin,
9
+ ...tsdocPlugin,
10
+ {
11
+ rules: {
12
+ '@rushstack/packlets/mechanics': 'warn'
13
+ }
14
+ },
15
+ {
16
+ // file-api-types/ deliberately mirrors the browser File System Access API.
17
+ // Interface names match the DOM verbatim (no `I` prefix) and some APIs return `null`.
18
+ files: ['src/packlets/file-api-types/**/*.ts'],
19
+ rules: {
20
+ '@typescript-eslint/naming-convention': 'off',
21
+ '@rushstack/no-new-null': 'off'
22
+ }
23
+ },
24
+ {
25
+ // MockStorage implements the browser Storage interface (localStorage), which
26
+ // declares `getItem(key)` and `key(index)` as returning `string | null`.
27
+ files: ['src/test/unit/localStorageTreeAccessors.test.ts'],
28
+ rules: {
29
+ '@rushstack/no-new-null': 'off'
30
+ }
31
+ }
32
+ ];
@@ -1,7 +1,5 @@
1
- import { Result } from '@fgv/ts-utils';
1
+ import { Result, Uuid } from '@fgv/ts-utils';
2
2
  import { CryptoUtils } from '@fgv/ts-extras';
3
- type ICryptoProvider = CryptoUtils.ICryptoProvider;
4
- type IEncryptionResult = CryptoUtils.IEncryptionResult;
5
3
  /**
6
4
  * Browser implementation of `ICryptoProvider` using the Web Crypto API.
7
5
  * Uses AES-256-GCM for authenticated encryption.
@@ -11,7 +9,7 @@ type IEncryptionResult = CryptoUtils.IEncryptionResult;
11
9
  *
12
10
  * @public
13
11
  */
14
- export declare class BrowserCryptoProvider implements ICryptoProvider {
12
+ export declare class BrowserCryptoProvider implements CryptoUtils.ICryptoProvider {
15
13
  private readonly _crypto;
16
14
  /**
17
15
  * Creates a new {@link CryptoUtils.BrowserCryptoProvider | BrowserCryptoProvider}.
@@ -24,7 +22,7 @@ export declare class BrowserCryptoProvider implements ICryptoProvider {
24
22
  * @param key - 32-byte encryption key
25
23
  * @returns `Success` with encryption result, or `Failure` with an error.
26
24
  */
27
- encrypt(plaintext: string, key: Uint8Array): Promise<Result<IEncryptionResult>>;
25
+ encrypt(plaintext: string, key: Uint8Array): Promise<Result<CryptoUtils.IEncryptionResult>>;
28
26
  /**
29
27
  * Decrypts ciphertext using AES-256-GCM.
30
28
  * @param encryptedData - Encrypted bytes
@@ -47,12 +45,25 @@ export declare class BrowserCryptoProvider implements ICryptoProvider {
47
45
  * @returns Success with derived 32-byte key, or Failure with error
48
46
  */
49
47
  deriveKey(password: string, salt: Uint8Array, iterations: number): Promise<Result<Uint8Array>>;
48
+ /**
49
+ * Computes a SHA-256 hash of the given data.
50
+ * @param data - UTF-8 string to hash
51
+ * @returns `Success` with hex-encoded hash string, or `Failure` with an error.
52
+ */
53
+ sha256(data: string): Promise<Result<string>>;
50
54
  /**
51
55
  * Generates cryptographically secure random bytes.
52
56
  * @param length - Number of bytes to generate
53
57
  * @returns Success with random bytes, or Failure with error
54
58
  */
55
59
  generateRandomBytes(length: number): Result<Uint8Array>;
60
+ /**
61
+ * Generates a cryptographically random UUIDv4 using the injected
62
+ * `Crypto` instance.
63
+ * @returns `Success` with the generated UUID, or `Failure` if the underlying
64
+ * `Crypto` instance does not expose `randomUUID`.
65
+ */
66
+ generateUuid(): Result<Uuid>;
56
67
  /**
57
68
  * Encodes binary data to base64 string.
58
69
  * @param data - Binary data to encode
@@ -65,6 +76,105 @@ export declare class BrowserCryptoProvider implements ICryptoProvider {
65
76
  * @returns Success with decoded bytes, or Failure if invalid base64
66
77
  */
67
78
  fromBase64(base64: string): Result<Uint8Array>;
79
+ /**
80
+ * Generates a new asymmetric keypair via Web Crypto.
81
+ * @param algorithm - The algorithm to use.
82
+ * @param extractable - Whether the resulting keys may be exported.
83
+ * @returns `Success` with the generated `CryptoKeyPair`, or `Failure` with an error.
84
+ */
85
+ generateKeyPair(algorithm: CryptoUtils.KeyPairAlgorithm, extractable: boolean): Promise<Result<CryptoKeyPair>>;
86
+ /**
87
+ * Exports a public `CryptoKey` as a JSON Web Key.
88
+ * @remarks
89
+ * Rejects non-public keys at runtime. WebCrypto's `exportKey('jwk', ...)`
90
+ * does not enforce public-vs-private; without this guard a caller that
91
+ * passed an extractable private key would receive its private fields
92
+ * (`d`, `p`, `q`, ...) as JWK, defeating the method's name.
93
+ * @param publicKey - Extractable public key to export.
94
+ * @returns `Success` with the JWK, or `Failure` if not a public key or if export fails.
95
+ */
96
+ exportPublicKeyJwk(publicKey: CryptoKey): Promise<Result<JsonWebKey>>;
97
+ /**
98
+ * Imports a public-key JWK as a `CryptoKey` for the requested algorithm.
99
+ * @param jwk - The JSON Web Key produced by a prior export.
100
+ * @param algorithm - The algorithm the key was generated for.
101
+ * @returns `Success` with the imported public `CryptoKey`, or `Failure` with an error.
102
+ */
103
+ importPublicKeyJwk(jwk: JsonWebKey, algorithm: CryptoUtils.KeyPairAlgorithm): Promise<Result<CryptoKey>>;
104
+ /**
105
+ * Exports a public `CryptoKey` as a DER-encoded SPKI blob.
106
+ * @param publicKey - The public `CryptoKey` to export.
107
+ * @returns `Success` with the raw SPKI bytes, or `Failure` with error context.
108
+ */
109
+ exportPublicKeySpki(publicKey: CryptoKey): Promise<Result<Uint8Array>>;
110
+ /**
111
+ * Imports a public key from a DER-encoded SPKI blob.
112
+ * @param spkiBytes - The raw SPKI bytes.
113
+ * @param algorithm - The algorithm the key was generated for.
114
+ * @returns `Success` with the imported public `CryptoKey`, or `Failure` with error context.
115
+ */
116
+ importPublicKeySpki(spkiBytes: Uint8Array, algorithm: CryptoUtils.KeyPairAlgorithm): Promise<Result<CryptoKey>>;
117
+ /**
118
+ * Signs `data` with `privateKey` using the algorithm inferred from the key.
119
+ * @param privateKey - A signing `CryptoKey` (`'ecdsa-p256'` or `'ed25519'`).
120
+ * @param data - The bytes to sign.
121
+ * @returns `Success` with the raw signature bytes, or `Failure` with error context.
122
+ */
123
+ sign(privateKey: CryptoKey, data: Uint8Array): Promise<Result<Uint8Array>>;
124
+ /**
125
+ * Verifies a signature produced by {@link BrowserCryptoProvider.sign}.
126
+ * @param publicKey - A verify `CryptoKey` (`'ecdsa-p256'` or `'ed25519'`).
127
+ * @param signature - The raw signature bytes.
128
+ * @param data - The original data that was signed.
129
+ * @returns `Success` with `true` if valid, `false` if not, or `Failure` with error context.
130
+ */
131
+ verify(publicKey: CryptoKey, signature: Uint8Array, data: Uint8Array): Promise<Result<boolean>>;
132
+ /**
133
+ * Compares two byte arrays in constant time.
134
+ *
135
+ * Accumulates XOR differences with bitwise-OR; no early-return is possible
136
+ * once the length check passes, making timing independent of the byte
137
+ * values. Returns `false` immediately on length mismatch (length is not
138
+ * secret in normal use).
139
+ * @param a - First byte array.
140
+ * @param b - Second byte array.
141
+ * @returns `true` if lengths match and all bytes are equal, `false` otherwise.
142
+ */
143
+ timingSafeEqual(a: Uint8Array, b: Uint8Array): boolean;
144
+ /**
145
+ * Computes an HMAC-SHA256 MAC for `data` using `key`.
146
+ * @param key - An HMAC `CryptoKey` with `'sign'` usage.
147
+ * @param data - The bytes to authenticate.
148
+ * @returns `Success` with the 32-byte MAC, or `Failure` with error context.
149
+ */
150
+ hmacSha256(key: CryptoKey, data: Uint8Array): Promise<Result<Uint8Array>>;
151
+ /**
152
+ * Verifies an HMAC-SHA256 MAC in constant time.
153
+ * @param key - An HMAC `CryptoKey` with `'sign'` usage.
154
+ * @param signature - The MAC bytes to verify.
155
+ * @param data - The original data that was authenticated.
156
+ * @returns `Success` with `true` if valid, `false` if not, or `Failure` with error context.
157
+ */
158
+ verifyHmacSha256(key: CryptoKey, signature: Uint8Array, data: Uint8Array): Promise<Result<boolean>>;
159
+ /**
160
+ * Wraps `plaintext` for the holder of `recipientPublicKey` using
161
+ * ECIES (ECDH P-256 + HKDF-SHA256 + AES-GCM-256). See
162
+ * {@link CryptoUtils.ICryptoProvider.wrapBytes | ICryptoProvider.wrapBytes}.
163
+ * @param plaintext - The bytes to wrap.
164
+ * @param recipientPublicKey - The recipient's ECDH P-256 public `CryptoKey`.
165
+ * @param options - HKDF salt and info; see {@link CryptoUtils.IWrapBytesOptions | IWrapBytesOptions}.
166
+ * @returns `Success` with the wrapped payload, or `Failure` with an error.
167
+ */
168
+ wrapBytes(plaintext: Uint8Array, recipientPublicKey: CryptoKey, options: CryptoUtils.IWrapBytesOptions): Promise<Result<CryptoUtils.IWrappedBytes>>;
169
+ /**
170
+ * Unwraps a payload produced by `wrapBytes` using the recipient's private
171
+ * key. See {@link CryptoUtils.ICryptoProvider.unwrapBytes | ICryptoProvider.unwrapBytes}.
172
+ * @param wrapped - The wrapped payload.
173
+ * @param recipientPrivateKey - The recipient's ECDH P-256 private `CryptoKey`.
174
+ * @param options - HKDF salt and info matching the wrap call.
175
+ * @returns `Success` with the original `plaintext`, or `Failure` with an error.
176
+ */
177
+ unwrapBytes(wrapped: CryptoUtils.IWrappedBytes, recipientPrivateKey: CryptoKey, options: CryptoUtils.IWrapBytesOptions): Promise<Result<Uint8Array>>;
68
178
  }
69
179
  /**
70
180
  * Creates a {@link CryptoUtils.BrowserCryptoProvider | BrowserCryptoProvider} if Web
@@ -73,5 +183,4 @@ export declare class BrowserCryptoProvider implements ICryptoProvider {
73
183
  * @public
74
184
  */
75
185
  export declare function createBrowserCryptoProvider(): Result<BrowserCryptoProvider>;
76
- export {};
77
186
  //# sourceMappingURL=browserCryptoProvider.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"browserCryptoProvider.d.ts","sourceRoot":"","sources":["../../../src/packlets/crypto-utils/browserCryptoProvider.ts"],"names":[],"mappings":"AAqBA,OAAO,EAA0B,MAAM,EAAW,MAAM,eAAe,CAAC;AACxE,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,KAAK,eAAe,GAAG,WAAW,CAAC,eAAe,CAAC;AACnD,KAAK,iBAAiB,GAAG,WAAW,CAAC,iBAAiB,CAAC;AAevD;;;;;;;;GAQG;AACH,qBAAa,qBAAsB,YAAW,eAAe;IAC3D,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAS;IAEjC;;;OAGG;gBACgB,SAAS,CAAC,EAAE,MAAM;IAYrC;;;;;OAKG;IACU,OAAO,CAAC,SAAS,EAAE,MAAM,EAAE,GAAG,EAAE,UAAU,GAAG,OAAO,CAAC,MAAM,CAAC,iBAAiB,CAAC,CAAC;IAmD5F;;;;;;;OAOG;IACU,OAAO,CAClB,aAAa,EAAE,UAAU,EACzB,GAAG,EAAE,UAAU,EACf,EAAE,EAAE,UAAU,EACd,OAAO,EAAE,UAAU,GAClB,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;IAgD1B;;;OAGG;IACU,WAAW,IAAI,OAAO,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC;IASvD;;;;;;OAMG;IACU,SAAS,CACpB,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,UAAU,EAChB,UAAU,EAAE,MAAM,GACjB,OAAO,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC;IAyC9B;;;;OAIG;IACI,mBAAmB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,UAAU,CAAC;IAY9D;;;;OAIG;IACI,QAAQ,CAAC,IAAI,EAAE,UAAU,GAAG,MAAM;IASzC;;;;OAIG;IACI,UAAU,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,UAAU,CAAC;CAYtD;AAED;;;;;GAKG;AACH,wBAAgB,2BAA2B,IAAI,MAAM,CAAC,qBAAqB,CAAC,CAE3E"}
1
+ {"version":3,"file":"browserCryptoProvider.d.ts","sourceRoot":"","sources":["../../../src/packlets/crypto-utils/browserCryptoProvider.ts"],"names":[],"mappings":"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"}