@fireproof/vendor 2.0.2 → 3.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 (73) hide show
  1. package/package.json +6 -60
  2. package/src/p-limit/index.d.ts +81 -0
  3. package/src/p-limit/index.js +104 -0
  4. package/src/p-limit/license +9 -0
  5. package/src/p-limit/readme.md +129 -0
  6. package/src/@web3-storage/pail/LICENSE.md +0 -232
  7. package/src/@web3-storage/pail/README.md +0 -84
  8. package/src/@web3-storage/pail/cli.js +0 -218
  9. package/src/@web3-storage/pail/dist/src/api.d.ts +0 -61
  10. package/src/@web3-storage/pail/dist/src/api.d.ts.map +0 -1
  11. package/src/@web3-storage/pail/dist/src/api.js +0 -1
  12. package/src/@web3-storage/pail/dist/src/batch/api.d.ts +0 -31
  13. package/src/@web3-storage/pail/dist/src/batch/api.d.ts.map +0 -1
  14. package/src/@web3-storage/pail/dist/src/batch/api.js +0 -1
  15. package/src/@web3-storage/pail/dist/src/batch/index.d.ts +0 -23
  16. package/src/@web3-storage/pail/dist/src/batch/index.d.ts.map +0 -1
  17. package/src/@web3-storage/pail/dist/src/batch/index.js +0 -241
  18. package/src/@web3-storage/pail/dist/src/batch/shard.d.ts +0 -3
  19. package/src/@web3-storage/pail/dist/src/batch/shard.d.ts.map +0 -1
  20. package/src/@web3-storage/pail/dist/src/batch/shard.js +0 -12
  21. package/src/@web3-storage/pail/dist/src/block.d.ts +0 -35
  22. package/src/@web3-storage/pail/dist/src/block.d.ts.map +0 -1
  23. package/src/@web3-storage/pail/dist/src/block.js +0 -66
  24. package/src/@web3-storage/pail/dist/src/clock/api.d.ts +0 -10
  25. package/src/@web3-storage/pail/dist/src/clock/api.d.ts.map +0 -1
  26. package/src/@web3-storage/pail/dist/src/clock/api.js +0 -1
  27. package/src/@web3-storage/pail/dist/src/clock/index.d.ts +0 -48
  28. package/src/@web3-storage/pail/dist/src/clock/index.d.ts.map +0 -1
  29. package/src/@web3-storage/pail/dist/src/clock/index.js +0 -178
  30. package/src/@web3-storage/pail/dist/src/crdt/api.d.ts +0 -26
  31. package/src/@web3-storage/pail/dist/src/crdt/api.d.ts.map +0 -1
  32. package/src/@web3-storage/pail/dist/src/crdt/api.js +0 -1
  33. package/src/@web3-storage/pail/dist/src/crdt/batch/api.d.ts +0 -11
  34. package/src/@web3-storage/pail/dist/src/crdt/batch/api.d.ts.map +0 -1
  35. package/src/@web3-storage/pail/dist/src/crdt/batch/api.js +0 -1
  36. package/src/@web3-storage/pail/dist/src/crdt/batch/index.d.ts +0 -5
  37. package/src/@web3-storage/pail/dist/src/crdt/batch/index.d.ts.map +0 -1
  38. package/src/@web3-storage/pail/dist/src/crdt/batch/index.js +0 -140
  39. package/src/@web3-storage/pail/dist/src/crdt/index.d.ts +0 -9
  40. package/src/@web3-storage/pail/dist/src/crdt/index.d.ts.map +0 -1
  41. package/src/@web3-storage/pail/dist/src/crdt/index.js +0 -344
  42. package/src/@web3-storage/pail/dist/src/diff.d.ts +0 -13
  43. package/src/@web3-storage/pail/dist/src/diff.d.ts.map +0 -1
  44. package/src/@web3-storage/pail/dist/src/diff.js +0 -151
  45. package/src/@web3-storage/pail/dist/src/index.d.ts +0 -10
  46. package/src/@web3-storage/pail/dist/src/index.d.ts.map +0 -1
  47. package/src/@web3-storage/pail/dist/src/index.js +0 -356
  48. package/src/@web3-storage/pail/dist/src/merge.d.ts +0 -5
  49. package/src/@web3-storage/pail/dist/src/merge.d.ts.map +0 -1
  50. package/src/@web3-storage/pail/dist/src/merge.js +0 -42
  51. package/src/@web3-storage/pail/dist/src/shard.d.ts +0 -43
  52. package/src/@web3-storage/pail/dist/src/shard.d.ts.map +0 -1
  53. package/src/@web3-storage/pail/dist/src/shard.js +0 -166
  54. package/src/@web3-storage/pail/dist/tsconfig.tsbuildinfo +0 -1
  55. package/src/@web3-storage/pail/src/api.ts +0 -92
  56. package/src/@web3-storage/pail/src/batch/api.js +0 -1
  57. package/src/@web3-storage/pail/src/batch/api.ts +0 -59
  58. package/src/@web3-storage/pail/src/batch/index.js +0 -258
  59. package/src/@web3-storage/pail/src/batch/shard.js +0 -13
  60. package/src/@web3-storage/pail/src/block.js +0 -75
  61. package/src/@web3-storage/pail/src/clock/api.js +0 -1
  62. package/src/@web3-storage/pail/src/clock/api.ts +0 -12
  63. package/src/@web3-storage/pail/src/clock/index.js +0 -182
  64. package/src/@web3-storage/pail/src/crdt/api.js +0 -1
  65. package/src/@web3-storage/pail/src/crdt/api.ts +0 -33
  66. package/src/@web3-storage/pail/src/crdt/batch/api.js +0 -1
  67. package/src/@web3-storage/pail/src/crdt/batch/api.ts +0 -30
  68. package/src/@web3-storage/pail/src/crdt/batch/index.js +0 -155
  69. package/src/@web3-storage/pail/src/crdt/index.js +0 -354
  70. package/src/@web3-storage/pail/src/diff.js +0 -151
  71. package/src/@web3-storage/pail/src/index.js +0 -406
  72. package/src/@web3-storage/pail/src/merge.js +0 -43
  73. package/src/@web3-storage/pail/src/shard.js +0 -180
@@ -1 +0,0 @@
1
- {"fileNames":["../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es5.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2015.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2016.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2017.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2018.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2019.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2020.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2021.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2022.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.dom.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.dom.iterable.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.dom.asynciterable.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.webworker.importscripts.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.scripthost.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2015.core.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2015.collection.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2015.generator.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2015.iterable.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2015.promise.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2015.proxy.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2015.reflect.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2015.symbol.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2016.array.include.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2016.intl.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2017.arraybuffer.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2017.date.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2017.object.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2017.string.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2017.intl.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2018.intl.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2018.promise.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2018.regexp.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2019.array.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2019.object.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2019.string.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2019.symbol.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2019.intl.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2020.bigint.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2020.date.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2020.promise.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2020.string.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2020.intl.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2020.number.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2021.promise.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2021.string.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2021.weakref.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2021.intl.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2022.array.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2022.error.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2022.intl.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2022.object.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2022.string.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2022.regexp.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.decorators.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.decorators.legacy.d.ts","../node_modules/.pnpm/typescript@5.8.2/node_modules/typescript/lib/lib.es2022.full.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/bytes.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/bases/interface.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/block/interface.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/hashes/interface.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/link/interface.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/cid.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/hashes/digest.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/hashes/hasher.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/varint.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/codecs/interface.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/interface.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/index.d.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/hashes/sha2.d.ts","../node_modules/.pnpm/cborg@4.0.7/node_modules/cborg/types/lib/token.d.ts","../node_modules/.pnpm/cborg@4.0.7/node_modules/cborg/types/lib/bl.d.ts","../node_modules/.pnpm/cborg@4.0.7/node_modules/cborg/types/interface.d.ts","../node_modules/.pnpm/cborg@4.0.7/node_modules/cborg/types/lib/decode.d.ts","../node_modules/.pnpm/cborg@4.0.7/node_modules/cborg/types/lib/encode.d.ts","../node_modules/.pnpm/cborg@4.0.7/node_modules/cborg/types/cborg.d.ts","../node_modules/.pnpm/@ipld+dag-cbor@9.2.2/node_modules/@ipld/dag-cbor/dist/src/index.d.ts","../src/api.ts","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/link.d.ts","../src/block.js","../node_modules/.pnpm/multiformats@13.3.2/node_modules/multiformats/dist/src/block.d.ts","../src/shard.js","../src/diff.js","../src/index.js","../src/merge.js","../src/batch/api.ts","../src/batch/shard.js","../src/batch/index.js","../src/clock/api.ts","../src/clock/index.js","../src/crdt/api.ts","../src/crdt/index.js","../src/crdt/batch/api.ts","../src/crdt/batch/index.js","../node_modules/.pnpm/@vitest+pretty-format@3.0.9/node_modules/@vitest/pretty-format/dist/index.d.ts","../node_modules/.pnpm/@vitest+utils@3.0.9/node_modules/@vitest/utils/dist/types.d.ts","../node_modules/.pnpm/@vitest+utils@3.0.9/node_modules/@vitest/utils/dist/helpers.d.ts","../node_modules/.pnpm/tinyrainbow@2.0.0/node_modules/tinyrainbow/dist/index-8b61d5bc.d.ts","../node_modules/.pnpm/tinyrainbow@2.0.0/node_modules/tinyrainbow/dist/node.d.ts","../node_modules/.pnpm/@vitest+utils@3.0.9/node_modules/@vitest/utils/dist/index.d.ts","../node_modules/.pnpm/@vitest+runner@3.0.9/node_modules/@vitest/runner/dist/tasks.d-D4e98wjH.d.ts","../node_modules/.pnpm/@vitest+utils@3.0.9/node_modules/@vitest/utils/dist/types.d-Cr0z4Cnu.d.ts","../node_modules/.pnpm/@vitest+utils@3.0.9/node_modules/@vitest/utils/dist/diff.d.ts","../node_modules/.pnpm/@vitest+utils@3.0.9/node_modules/@vitest/utils/diff.d.ts","../node_modules/.pnpm/@vitest+runner@3.0.9/node_modules/@vitest/runner/dist/types.d.ts","../node_modules/.pnpm/@vitest+utils@3.0.9/node_modules/@vitest/utils/dist/error.d.ts","../node_modules/.pnpm/@vitest+utils@3.0.9/node_modules/@vitest/utils/error.d.ts","../node_modules/.pnpm/@vitest+runner@3.0.9/node_modules/@vitest/runner/dist/index.d.ts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/dist/chunks/environment.d.C8UItCbf.d.ts","../node_modules/.pnpm/@types+estree@1.0.6/node_modules/@types/estree/index.d.ts","../node_modules/.pnpm/rollup@4.36.0/node_modules/rollup/dist/rollup.d.ts","../node_modules/.pnpm/vite@6.2.2/node_modules/vite/types/hmrPayload.d.ts","../node_modules/.pnpm/vite@6.2.2/node_modules/vite/types/customEvent.d.ts","../node_modules/.pnpm/vite@6.2.2/node_modules/vite/types/hot.d.ts","../node_modules/.pnpm/vite@6.2.2/node_modules/vite/dist/node/moduleRunnerTransport.d-CXw_Ws6P.d.ts","../node_modules/.pnpm/vite@6.2.2/node_modules/vite/dist/node/module-runner.d.ts","../node_modules/.pnpm/esbuild@0.25.1/node_modules/esbuild/lib/main.d.ts","../node_modules/.pnpm/source-map-js@1.2.1/node_modules/source-map-js/source-map.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/previous-map.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/input.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/css-syntax-error.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/declaration.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/root.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/warning.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/lazy-result.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/no-work-result.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/processor.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/result.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/document.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/rule.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/node.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/comment.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/container.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/at-rule.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/list.d.ts","../node_modules/.pnpm/postcss@8.5.3/node_modules/postcss/lib/postcss.d.ts","../node_modules/.pnpm/vite@6.2.2/node_modules/vite/types/internal/lightningcssOptions.d.ts","../node_modules/.pnpm/vite@6.2.2/node_modules/vite/types/internal/cssPreprocessorOptions.d.ts","../node_modules/.pnpm/vite@6.2.2/node_modules/vite/types/importGlob.d.ts","../node_modules/.pnpm/vite@6.2.2/node_modules/vite/types/metadata.d.ts","../node_modules/.pnpm/vite@6.2.2/node_modules/vite/dist/node/index.d.ts","../node_modules/.pnpm/@vitest+utils@3.0.9/node_modules/@vitest/utils/dist/source-map.d.ts","../node_modules/.pnpm/@vitest+snapshot@3.0.9/node_modules/@vitest/snapshot/dist/environment.d-DHdQ1Csl.d.ts","../node_modules/.pnpm/@vitest+snapshot@3.0.9/node_modules/@vitest/snapshot/dist/rawSnapshot.d-lFsMJFUd.d.ts","../node_modules/.pnpm/@vitest+snapshot@3.0.9/node_modules/@vitest/snapshot/dist/index.d.ts","../node_modules/.pnpm/@vitest+snapshot@3.0.9/node_modules/@vitest/snapshot/dist/environment.d.ts","../node_modules/.pnpm/@vitest+snapshot@3.0.9/node_modules/@vitest/snapshot/environment.d.ts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/dist/chunks/config.d.DevWltVl.d.ts","../node_modules/.pnpm/vite-node@3.0.9/node_modules/vite-node/dist/trace-mapping.d-DLVdEqOp.d.ts","../node_modules/.pnpm/vite-node@3.0.9/node_modules/vite-node/dist/index.d-CvjHzhRV.d.ts","../node_modules/.pnpm/vite-node@3.0.9/node_modules/vite-node/dist/index.d.ts","../node_modules/.pnpm/@vitest+runner@3.0.9/node_modules/@vitest/runner/dist/utils.d.ts","../node_modules/.pnpm/@vitest+runner@3.0.9/node_modules/@vitest/runner/utils.d.ts","../node_modules/.pnpm/tinybench@2.9.0/node_modules/tinybench/dist/index.d.cts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/dist/chunks/benchmark.d.BwvBVTda.d.ts","../node_modules/.pnpm/vite-node@3.0.9/node_modules/vite-node/dist/client.d.ts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/dist/chunks/coverage.d.S9RMNXIe.d.ts","../node_modules/.pnpm/@vitest+snapshot@3.0.9/node_modules/@vitest/snapshot/dist/manager.d.ts","../node_modules/.pnpm/@vitest+snapshot@3.0.9/node_modules/@vitest/snapshot/manager.d.ts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/dist/chunks/reporters.d.CqBhtcTq.d.ts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/dist/chunks/worker.d.C58isfFm.d.ts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/dist/chunks/worker.d.CSFlSYJg.d.ts","../node_modules/.pnpm/@vitest+expect@3.0.9/node_modules/@vitest/expect/dist/chai.d.cts","../node_modules/.pnpm/@vitest+spy@3.0.9/node_modules/@vitest/spy/dist/index.d.ts","../node_modules/.pnpm/@vitest+expect@3.0.9/node_modules/@vitest/expect/dist/index.d.ts","../node_modules/.pnpm/@vitest+expect@3.0.9/node_modules/@vitest/expect/index.d.ts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/dist/chunks/global.d.Cg2sEPIm.d.ts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/dist/chunks/vite.d.BUZTGxQ3.d.ts","../node_modules/.pnpm/@vitest+mocker@3.0.9_vite@6.2.2/node_modules/@vitest/mocker/dist/types.d-kZ7T8ECy.d.ts","../node_modules/.pnpm/@vitest+mocker@3.0.9_vite@6.2.2/node_modules/@vitest/mocker/dist/index.d.ts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/dist/chunks/mocker.d.BE_2ls6u.d.ts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/dist/chunks/suite.d.FvehnV49.d.ts","../node_modules/.pnpm/expect-type@1.2.0/node_modules/expect-type/dist/utils.d.ts","../node_modules/.pnpm/expect-type@1.2.0/node_modules/expect-type/dist/overloads.d.ts","../node_modules/.pnpm/expect-type@1.2.0/node_modules/expect-type/dist/branding.d.ts","../node_modules/.pnpm/expect-type@1.2.0/node_modules/expect-type/dist/messages.d.ts","../node_modules/.pnpm/expect-type@1.2.0/node_modules/expect-type/dist/index.d.ts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/dist/index.d.ts","../node_modules/.pnpm/vitest@3.0.9/node_modules/vitest/globals.d.ts"],"fileIdsList":[[69,73,79,82],[105,106,110,170],[171],[175],[106,107,110,111,113],[106],[106,107,110],[106,107],[158],[149],[101,149,150],[101,149],[152],[164],[109],[101,108],[102],[101,102,103,105],[101],[112],[77,79,80,81],[77,78],[77,79],[79],[179,180],[179,180,181,182],[179,181],[179],[74,75],[68,69],[68],[66],[67],[67,70],[71],[64,69,70,71,72,74],[65,66,67,68,73],[65,66,67],[139],[137,139],[128,136,137,138,140],[126],[129,134,139,142],[125,142],[129,130,133,134,135,142],[129,130,131,133,134,142],[126,127,128,129,130,134,135,136,138,139,140,142],[124,126,127,128,129,130,131,133,134,135,136,137,138,139,140,141],[124,142],[129,131,132,134,135,142],[133,142],[134,135,139,142],[127,137],[116,117],[104],[155,156],[155],[117,118,119,121,122,123,142,143,144,145,146,147],[118,119,120,121],[118],[119],[117,147],[114,159,160,173],[101,110,114,151,153,173],[162],[101,114,115,151,161,172,173],[176],[101,106,110,114,115,147,148,151,154,157,161,163,165,169,173,174],[114,159,160,161,173],[147,166],[114,115,151,154,157,173],[167],[101,106,110,114,115,147,148,151,153,154,157,159,160,161,162,163,165,166,167,168,169,170,172,173,174,176,177,178,183],[184],[66,68,75,76,83],[84],[88,92,93],[88,92],[75,84,85],[75,84],[75,76,83,87,95],[84,95],[92,97],[86,88,94,96,98,99],[86,88,90,94,96,97],[84,88],[84,89,90],[76,83,84,85,87]],"fileInfos":[{"version":"69684132aeb9b5642cbcd9e22dff7818ff0ee1aa831728af0ecf97d3364d5546","affectsGlobalScope":true,"impliedFormat":1},{"version":"45b7ab580deca34ae9729e97c13cfd999df04416a79116c3bfb483804f85ded4","impliedFormat":1},{"version":"3facaf05f0c5fc569c5649dd359892c98a85557e3e0c847964caeb67076f4d75","impliedFormat":1},{"version":"e44bb8bbac7f10ecc786703fe0a6a4b952189f908707980ba8f3c8975a760962","impliedFormat":1},{"version":"5e1c4c362065a6b95ff952c0eab010f04dcd2c3494e813b493ecfd4fcb9fc0d8","impliedFormat":1},{"version":"68d73b4a11549f9c0b7d352d10e91e5dca8faa3322bfb77b661839c42b1ddec7","impliedFormat":1},{"version":"5efce4fc3c29ea84e8928f97adec086e3dc876365e0982cc8479a07954a3efd4","impliedFormat":1},{"version":"feecb1be483ed332fad555aff858affd90a48ab19ba7272ee084704eb7167569","impliedFormat":1},{"version":"ee7bad0c15b58988daa84371e0b89d313b762ab83cb5b31b8a2d1162e8eb41c2","impliedFormat":1},{"version":"092c2bfe125ce69dbb1223c85d68d4d2397d7d8411867b5cc03cec902c233763","affectsGlobalScope":true,"impliedFormat":1},{"version":"07f073f19d67f74d732b1adea08e1dc66b1b58d77cb5b43931dee3d798a2fd53","affectsGlobalScope":true,"impliedFormat":1},{"version":"d7a3c8b952931daebdfc7a2897c53c0a1c73624593fa070e46bd537e64dcd20a","affectsGlobalScope":true,"impliedFormat":1},{"version":"80e18897e5884b6723488d4f5652167e7bb5024f946743134ecc4aa4ee731f89","affectsGlobalScope":true,"impliedFormat":1},{"version":"cd034f499c6cdca722b60c04b5b1b78e058487a7085a8e0d6fb50809947ee573","affectsGlobalScope":true,"impliedFormat":1},{"version":"c57796738e7f83dbc4b8e65132f11a377649c00dd3eee333f672b8f0a6bea671","affectsGlobalScope":true,"impliedFormat":1},{"version":"dc2df20b1bcdc8c2d34af4926e2c3ab15ffe1160a63e58b7e09833f616efff44","affectsGlobalScope":true,"impliedFormat":1},{"version":"515d0b7b9bea2e31ea4ec968e9edd2c39d3eebf4a2d5cbd04e88639819ae3b71","affectsGlobalScope":true,"impliedFormat":1},{"version":"0559b1f683ac7505ae451f9a96ce4c3c92bdc71411651ca6ddb0e88baaaad6a3","affectsGlobalScope":true,"impliedFormat":1},{"version":"0dc1e7ceda9b8b9b455c3a2d67b0412feab00bd2f66656cd8850e8831b08b537","affectsGlobalScope":true,"impliedFormat":1},{"version":"ce691fb9e5c64efb9547083e4a34091bcbe5bdb41027e310ebba8f7d96a98671","affectsGlobalScope":true,"impliedFormat":1},{"version":"8d697a2a929a5fcb38b7a65594020fcef05ec1630804a33748829c5ff53640d0","affectsGlobalScope":true,"impliedFormat":1},{"version":"4ff2a353abf8a80ee399af572debb8faab2d33ad38c4b4474cff7f26e7653b8d","affectsGlobalScope":true,"impliedFormat":1},{"version":"936e80ad36a2ee83fc3caf008e7c4c5afe45b3cf3d5c24408f039c1d47bdc1df","affectsGlobalScope":true,"impliedFormat":1},{"version":"d15bea3d62cbbdb9797079416b8ac375ae99162a7fba5de2c6c505446486ac0a","affectsGlobalScope":true,"impliedFormat":1},{"version":"68d18b664c9d32a7336a70235958b8997ebc1c3b8505f4f1ae2b7e7753b87618","affectsGlobalScope":true,"impliedFormat":1},{"version":"eb3d66c8327153d8fa7dd03f9c58d351107fe824c79e9b56b462935176cdf12a","affectsGlobalScope":true,"impliedFormat":1},{"version":"38f0219c9e23c915ef9790ab1d680440d95419ad264816fa15009a8851e79119","affectsGlobalScope":true,"impliedFormat":1},{"version":"69ab18c3b76cd9b1be3d188eaf8bba06112ebbe2f47f6c322b5105a6fbc45a2e","affectsGlobalScope":true,"impliedFormat":1},{"version":"fef8cfad2e2dc5f5b3d97a6f4f2e92848eb1b88e897bb7318cef0e2820bceaab","affectsGlobalScope":true,"impliedFormat":1},{"version":"2f11ff796926e0832f9ae148008138ad583bd181899ab7dd768a2666700b1893","affectsGlobalScope":true,"impliedFormat":1},{"version":"4de680d5bb41c17f7f68e0419412ca23c98d5749dcaaea1896172f06435891fc","affectsGlobalScope":true,"impliedFormat":1},{"version":"954296b30da6d508a104a3a0b5d96b76495c709785c1d11610908e63481ee667","affectsGlobalScope":true,"impliedFormat":1},{"version":"ac9538681b19688c8eae65811b329d3744af679e0bdfa5d842d0e32524c73e1c","affectsGlobalScope":true,"impliedFormat":1},{"version":"0a969edff4bd52585473d24995c5ef223f6652d6ef46193309b3921d65dd4376","affectsGlobalScope":true,"impliedFormat":1},{"version":"9e9fbd7030c440b33d021da145d3232984c8bb7916f277e8ffd3dc2e3eae2bdb","affectsGlobalScope":true,"impliedFormat":1},{"version":"811ec78f7fefcabbda4bfa93b3eb67d9ae166ef95f9bff989d964061cbf81a0c","affectsGlobalScope":true,"impliedFormat":1},{"version":"717937616a17072082152a2ef351cb51f98802fb4b2fdabd32399843875974ca","affectsGlobalScope":true,"impliedFormat":1},{"version":"d7e7d9b7b50e5f22c915b525acc5a49a7a6584cf8f62d0569e557c5cfc4b2ac2","affectsGlobalScope":true,"impliedFormat":1},{"version":"71c37f4c9543f31dfced6c7840e068c5a5aacb7b89111a4364b1d5276b852557","affectsGlobalScope":true,"impliedFormat":1},{"version":"576711e016cf4f1804676043e6a0a5414252560eb57de9faceee34d79798c850","affectsGlobalScope":true,"impliedFormat":1},{"version":"89c1b1281ba7b8a96efc676b11b264de7a8374c5ea1e6617f11880a13fc56dc6","affectsGlobalScope":true,"impliedFormat":1},{"version":"74f7fa2d027d5b33eb0471c8e82a6c87216223181ec31247c357a3e8e2fddc5b","affectsGlobalScope":true,"impliedFormat":1},{"version":"d6d7ae4d1f1f3772e2a3cde568ed08991a8ae34a080ff1151af28b7f798e22ca","affectsGlobalScope":true,"impliedFormat":1},{"version":"063600664504610fe3e99b717a1223f8b1900087fab0b4cad1496a114744f8df","affectsGlobalScope":true,"impliedFormat":1},{"version":"934019d7e3c81950f9a8426d093458b65d5aff2c7c1511233c0fd5b941e608ab","affectsGlobalScope":true,"impliedFormat":1},{"version":"52ada8e0b6e0482b728070b7639ee42e83a9b1c22d205992756fe020fd9f4a47","affectsGlobalScope":true,"impliedFormat":1},{"version":"3bdefe1bfd4d6dee0e26f928f93ccc128f1b64d5d501ff4a8cf3c6371200e5e6","affectsGlobalScope":true,"impliedFormat":1},{"version":"59fb2c069260b4ba00b5643b907ef5d5341b167e7d1dbf58dfd895658bda2867","affectsGlobalScope":true,"impliedFormat":1},{"version":"639e512c0dfc3fad96a84caad71b8834d66329a1f28dc95e3946c9b58176c73a","affectsGlobalScope":true,"impliedFormat":1},{"version":"368af93f74c9c932edd84c58883e736c9e3d53cec1fe24c0b0ff451f529ceab1","affectsGlobalScope":true,"impliedFormat":1},{"version":"af3dd424cf267428f30ccfc376f47a2c0114546b55c44d8c0f1d57d841e28d74","affectsGlobalScope":true,"impliedFormat":1},{"version":"995c005ab91a498455ea8dfb63aa9f83fa2ea793c3d8aa344be4a1678d06d399","affectsGlobalScope":true,"impliedFormat":1},{"version":"959d36cddf5e7d572a65045b876f2956c973a586da58e5d26cde519184fd9b8a","affectsGlobalScope":true,"impliedFormat":1},{"version":"965f36eae237dd74e6cca203a43e9ca801ce38824ead814728a2807b1910117d","affectsGlobalScope":true,"impliedFormat":1},{"version":"3925a6c820dcb1a06506c90b1577db1fdbf7705d65b62b99dce4be75c637e26b","affectsGlobalScope":true,"impliedFormat":1},{"version":"0a3d63ef2b853447ec4f749d3f368ce642264246e02911fcb1590d8c161b8005","affectsGlobalScope":true,"impliedFormat":1},{"version":"b5ce7a470bc3628408429040c4e3a53a27755022a32fd05e2cb694e7015386c7","affectsGlobalScope":true,"impliedFormat":1},{"version":"8444af78980e3b20b49324f4a16ba35024fef3ee069a0eb67616ea6ca821c47a","affectsGlobalScope":true,"impliedFormat":1},{"version":"3287d9d085fbd618c3971944b65b4be57859f5415f495b33a6adc994edd2f004","affectsGlobalScope":true,"impliedFormat":1},{"version":"b4b67b1a91182421f5df999988c690f14d813b9850b40acd06ed44691f6727ad","affectsGlobalScope":true,"impliedFormat":1},{"version":"8e7f8264d0fb4c5339605a15daadb037bf238c10b654bb3eee14208f860a32ea","affectsGlobalScope":true,"impliedFormat":1},{"version":"782dec38049b92d4e85c1585fbea5474a219c6984a35b004963b00beb1aab538","affectsGlobalScope":true,"impliedFormat":1},{"version":"3cbad9a1ba4453443026ed38e4b8be018abb26565fa7c944376463ad9df07c41","impliedFormat":1},{"version":"929fc31f7523aaa1d19735b77e637af06e58d76007648ec088ecfbec1521cbfe","impliedFormat":99},{"version":"4a3605bef1a5ef29fd5a1696dd95b0b4e2259e2d07a4d88fac79f3a9765c44a2","impliedFormat":99},{"version":"370079895f1acdd4bb5194a403c85bf60cfbb2654bced9430a6c7210e7246be8","impliedFormat":99},{"version":"90240231e730deed31569f6c686766a538e4a024bbc33ea1738fe924f477ba61","impliedFormat":99},{"version":"552223520e823223ee13c5764e9b69b1819c985818a8bcda435d8d1dbd909bee","impliedFormat":99},{"version":"49b7c3ddd683c09aa437dd92681699387441f522524b14d2331ce494a9bf2f27","impliedFormat":99},{"version":"3d0e04c8ca3f41da5f3d689500d9c4aeb54a1c59764d66d58f0e579b9af720e5","impliedFormat":99},{"version":"a6eb23f2a83113ce0ab7203bfda2be0888720f8d694a20abaef83b9f62832061","impliedFormat":99},{"version":"363dca5004ac5a3d9c2bba12812b97a64461911762f0b8f9320a8856ec53bcad","impliedFormat":99},{"version":"1447d46bff9e7c5c77da14515a7456ea5e919ce6e28f5e6746edf99818e4be47","impliedFormat":99},{"version":"557b8c7481296f4b7ed362320f3bbb40bb87404edf880c81224f365a8d1e17f3","impliedFormat":99},{"version":"283ed3d075bf7d3e8793f63b2a52f475ed84d95b7b6351c5d5bcc6c49d4b845b","impliedFormat":99},{"version":"130e4655e30a6d7a8004566642e24bf3016b5e5a2e5dcd72c0a61b663f7df711","impliedFormat":99},{"version":"0e84a640a449bd767be2ebebf4acf7cac1b1f92e72941b30d370ca0c8f1a30b3","impliedFormat":99},{"version":"a32c2dd5736b27da05ddf1034df28c75e8db3ef26effe60df4bd608f5c7a03d8","impliedFormat":99},{"version":"f65fb2149519d5e7cdf1245e0d5e5c6369855d9f14cfd1da9a678750da3f3fe6","impliedFormat":99},{"version":"15f502c247a60ad85c2a87635e7b0a71701a7f6d75fecba0f541e2b28d66f6fd","impliedFormat":99},{"version":"730fedb3e76078f11d9a8a595c3f337dadfb1c687810999b02394e853b668c5a","impliedFormat":99},{"version":"babe35042b7448cb38bbc24c357a358c5e1e71d2692a818f21a8550340e41329","impliedFormat":99},{"version":"f559fb70d8e4823601376e26e0ade0d4e1c50a5f8c349affbd3590c8d3666866","impliedFormat":99},{"version":"520e2311096e70379ad8aa19ca6bf5ea8b723da29607567e42820e12ca84f37f","signature":"3674bfc72b196cbf10af41d760eb1825ea904c2688666bdaa542fa84236a2aad"},{"version":"a1e5af4d821aeeee056db8fa6ce613f957af652cdab1c1b8058803684bdb23df","impliedFormat":99},{"version":"3c60343b48438de7de857209f3272804f325705e05945d0b5c6b77d8c0b91271","signature":"f5f7ad262c1abeec98a9a74f6cac8c2544c883e2e5f294d5a6283883f9c295d6"},{"version":"36a2b2bca10a1e53acaaae2f85c2737447ab9d66ebb05aee53f9f7de251e3c93","impliedFormat":99},{"version":"da90eb2d7d795885d978a33a0d37fc875f4749c30ddf1b6ef4642d767b572828","signature":"a64e40b9fd4087b7ae2763416bc02ffdbbccb15f3e76151538e0a7b650bb697f"},{"version":"4efb0e55bdb87c1fc5ede5dceba6bbd330daee81c9acf55110f1d68fbea8e34c","signature":"b1088088614739978364c6ab4de3d58e26aef7fd6113f81b96d82a6224c86b3a"},{"version":"10d638b1e0877b6af4f6ac5d6d5a4749ca96bc4dab30b9632b9435c669b34fd0","signature":"cd633aec7dbec63e37281aafc3e12ac4f3c1c0337d173015e8ac81ed143a529f"},{"version":"229faf86cd68a721d11b73a0b398ee241a57172cb3eef98351fa6adc4ed96aec","signature":"6bfa5af024804ea22f15370d2feb92958199fd3827bc97bf0487d29fb488925f"},{"version":"ecdb20ce70028bfb135f2c6475d6500c92148473be5347e1c3c527413176d65d","signature":"0b43e07b80bc9186dad45a6fe6ca756ea04ba9514b28f1a178910a0c7d8712ad"},{"version":"d913e4e7f031f401daed294c2308e81384c22c81cc6e7510f4f513bbb4717c67","signature":"a544cca6c47cb8b6d575bb76e95bed5098d90b61d41c5b5c3c727533477306a4"},{"version":"340c655e4885b071b70ec4dbc2a4ca517e473017c96467ca96679b767007b545","signature":"c8427ac345e001d4a1c9b3ed1ad0c0db4b900406a2224f7e7a7b0e57c6d2a38a"},{"version":"634e303df54ddd9c2e20bce6784a7fef1ea06183d75161fbf57e3324d4d6f07e","signature":"de94446f7a45df1aa8cfbe6aba6041f18551e6cee0067f29ecbe8615baf45360"},{"version":"31e758d6640ef652be142972a0002fed5ff026c20a61c51266ac73463c34e4fb","signature":"b21031da01aa8da51e7e76069e790766fe129a9d3f0d2b1513d861f0c9756a7e"},{"version":"857a4ca072a3a8d8e9be87699f3e9e2cf35989c2541551256724ace7c2ea1979","signature":"ac8e46be3c88e8f148a521f4719e07e1be9078cf37ec1f12b519d6bc569d5f14"},{"version":"8bcfa3cca1e71f4ed6e02e022c76853939a4588400bf396a828e33d1407dbccb","signature":"863e1c8c2d1d22df115e62c4c56c49b918e4c25fda25b7c5ad5b1f24776d25e2"},{"version":"0e0efe474d811ce52d4f8a73b2ab588aab64c3b7ff9180d36cb59c43034a44d6","signature":"39eaa64d9ce59d3a874d8f8d738db4428f23f1983b0aa99e0fefdcaf6ec5f9ae"},{"version":"aa856deef38ee724cda58a8d4ee451125f95c35af9fafcb0050169a519a17032","signature":"c69bc379f337d1e362506c4b44d64004801262c7b4c6ee280a131c86eb1ced15"},{"version":"c3d8e1342e4503eecd78e50ec4a4ddc87392afaf41a93ca640d3c88fe035ae56","impliedFormat":99},{"version":"07c0547e91d0c35c3d1bff1d2b7ffac3334b315e9eb5744a8440940e819ab13a","impliedFormat":99},{"version":"694f091f9b015e559c767b031e2c3c578916194a5335dfcf3bdba5f9e38afb66","impliedFormat":99},{"version":"f9b028d3c3891dd817e24d53102132b8f696269309605e6ed4f0db2c113bbd82","impliedFormat":99},{"version":"fb7c8d90e52e2884509166f96f3d591020c7b7977ab473b746954b0c8d100960","impliedFormat":99},{"version":"09acfcc65d81722128cf25e70c88e376513076b674829a3f2fd0d713643aea66","impliedFormat":99},{"version":"56fda0faf35a36ad0526c83cf6cb68d0ad1fc0be7b978e8b09505e0e59a2f84a","impliedFormat":99},{"version":"136cb8389f9750475777893903fabed422a7ddb88de72ff101b4d8c05371795c","impliedFormat":99},{"version":"bc7157768e6b7962ba9987f1c2038d31523b61b3956117b8195cdf817cc7247f","impliedFormat":99},{"version":"05c7aef6a4e496b93c2e682cced8903c0dfe6340d04f3fe616176e2782193435","impliedFormat":99},{"version":"2158408f62d0d2e4eec1d71087427ccf1d1402671d85b6d8d94fb83749c51220","impliedFormat":99},{"version":"a2d825985fa2f549e66d2d43aca3b91187855171ccf27bdfb308a5e023294747","impliedFormat":99},{"version":"500a67e158e4025f27570ab6a99831680852bb45a44d4c3647ab7567feb1fb4c","impliedFormat":99},{"version":"37b979b237e4e861576ff06f453f87806125b4fc4930005f11107a46075806c9","impliedFormat":99},{"version":"142a572c0496b5aff2904d3734adfff2d1e901ef08a75472e50f0c52f9a510ea","impliedFormat":99},{"version":"785b9d575b49124ce01b46f5b9402157c7611e6532effa562ac6aebec0074dfc","impliedFormat":1},{"version":"b5ba01279af8f99bdab82c198a16ac0a4926a98b794ddc019090a9678ebad1be","affectsGlobalScope":true,"impliedFormat":1},{"version":"02b1133807234b1a7d9bf9b1419ee19444dd8c26b101bc268aa8181591241f1f","impliedFormat":1},{"version":"6222e987b58abfe92597e1273ad7233626285bc2d78409d4a7b113d81a83496b","impliedFormat":1},{"version":"cbe726263ae9a7bf32352380f7e8ab66ee25b3457137e316929269c19e18a2be","impliedFormat":1},{"version":"0a25f947e7937ee5e01a21eb10d49de3b467eba752d3b42ea442e9e773f254ef","impliedFormat":99},{"version":"f11151a83668f94c1e763e39d89c0022ceb74618f1bfcf67596044acbe306094","impliedFormat":99},{"version":"b8caba62c0d2ef625f31cbb4fde09d851251af2551086ccf068611b0a69efd81","affectsGlobalScope":true,"impliedFormat":1},{"version":"402e5c534fb2b85fa771170595db3ac0dd532112c8fa44fc23f233bc6967488b","impliedFormat":1},{"version":"8885cf05f3e2abf117590bbb951dcf6359e3e5ac462af1c901cfd24c6a6472e2","impliedFormat":1},{"version":"33f3718dababfc26dfd9832c150149ea4e934f255130f8c118a59ae69e5ed441","impliedFormat":1},{"version":"e61df3640a38d535fd4bc9f4a53aef17c296b58dc4b6394fd576b808dd2fe5e6","impliedFormat":1},{"version":"459920181700cec8cbdf2a5faca127f3f17fd8dd9d9e577ed3f5f3af5d12a2e4","impliedFormat":1},{"version":"4719c209b9c00b579553859407a7e5dcfaa1c472994bd62aa5dd3cc0757eb077","impliedFormat":1},{"version":"7ec359bbc29b69d4063fe7dad0baaf35f1856f914db16b3f4f6e3e1bca4099fa","impliedFormat":1},{"version":"70790a7f0040993ca66ab8a07a059a0f8256e7bb57d968ae945f696cbff4ac7a","impliedFormat":1},{"version":"d1b9a81e99a0050ca7f2d98d7eedc6cda768f0eb9fa90b602e7107433e64c04c","impliedFormat":1},{"version":"a022503e75d6953d0e82c2c564508a5c7f8556fad5d7f971372d2d40479e4034","impliedFormat":1},{"version":"b215c4f0096f108020f666ffcc1f072c81e9f2f95464e894a5d5f34c5ea2a8b1","impliedFormat":1},{"version":"644491cde678bd462bb922c1d0cfab8f17d626b195ccb7f008612dc31f445d2d","impliedFormat":1},{"version":"dfe54dab1fa4961a6bcfba68c4ca955f8b5bbeb5f2ab3c915aa7adaa2eabc03a","impliedFormat":1},{"version":"1bb61aa2f08ab4506d41dbe16c5f3f5010f014bbf46fa3d715c0cbe3b00f4e1c","impliedFormat":1},{"version":"47865c5e695a382a916b1eedda1b6523145426e48a2eae4647e96b3b5e52024f","impliedFormat":1},{"version":"e42820cd611b15910c204cd133f692dcd602532b39317d4f2a19389b27e6f03d","impliedFormat":1},{"version":"331b8f71bfae1df25d564f5ea9ee65a0d847c4a94baa45925b6f38c55c7039bf","impliedFormat":1},{"version":"2a771d907aebf9391ac1f50e4ad37952943515eeea0dcc7e78aa08f508294668","impliedFormat":1},{"version":"0146fd6262c3fd3da51cb0254bb6b9a4e42931eb2f56329edd4c199cb9aaf804","impliedFormat":1},{"version":"4ec16d7a4e366c06a4573d299e15fe6207fc080f41beac5da06f4af33ea9761e","impliedFormat":1},{"version":"7870becb94cbc11d2d01b77c4422589adcba4d8e59f726246d40cd0d129784d8","affectsGlobalScope":true,"impliedFormat":1},{"version":"7f698624bbbb060ece7c0e51b7236520ebada74b747d7523c7df376453ed6fea","impliedFormat":1},{"version":"8f07f2b6514744ac96e51d7cb8518c0f4de319471237ea10cf688b8d0e9d0225","impliedFormat":1},{"version":"08971f8379717d46a8a990ce9a7eed3af3e47e22c3d45c3a046054b7a2fffe7a","impliedFormat":99},{"version":"727d1e78ee77d6db6b071fde82d7d1eb92484c99c4d49d86c30dd15b0b0a3c94","impliedFormat":99},{"version":"324ac98294dab54fbd580c7d0e707d94506d7b2c3d5efe981a8495f02cf9ad96","impliedFormat":99},{"version":"9ec72eb493ff209b470467e24264116b6a8616484bca438091433a545dfba17e","impliedFormat":99},{"version":"dd1e40affaae1edc4beefe3d9832e86a683dcfc66fdf8c93c851a47298b04276","impliedFormat":99},{"version":"49747416f08b3ba50500a215e7a55d75268b84e31e896a40313c8053e8dec908","impliedFormat":99},{"version":"f2d1a59a658165341b0e2b7879aa2e19ea6a709146b2d3f70ee8a07159d3d08e","impliedFormat":99},{"version":"bf85a259612faa1f444bcef0045aae0ff766561b0a2fb2797f2b65714b9d9fec","impliedFormat":99},{"version":"e6233e1c976265e85aa8ad76c3881febe6264cb06ae3136f0257e1eab4a6cc5a","impliedFormat":99},{"version":"73bffad73eb0e632fb83726d67f50a5e3c3ed6d50e7ff1416225c885d2272305","impliedFormat":99},{"version":"3c65174d4d399d0a9247b94abfb308f23074f907e44507096cd583375d538fc0","impliedFormat":99},{"version":"ea3c33b10a8026011e79b31ef982b4a0df9641ffa40f6b9bc81dcac96a7cd860","impliedFormat":99},{"version":"e666e31d323fef5642f87db0da48a83e58f0aaf9e3823e87eabd8ec7e0441a36","impliedFormat":99},{"version":"69bf2422313487956e4dacf049f30cb91b34968912058d244cb19e4baa24da97","impliedFormat":1},{"version":"971a2c327ff166c770c5fb35699575ba2d13bba1f6d2757309c9be4b30036c8e","impliedFormat":99},{"version":"fb0d12ac2d83c807ffdca1e4e1e5806220fcaaf54b4459b52e535399155caf0e","impliedFormat":99},{"version":"7bd51996fb7717941cbe094b05adc0d80b9503b350a77b789bbb0fc786f28053","impliedFormat":99},{"version":"b62006bbc815fe8190c7aee262aad6bff993e3f9ade70d7057dfceab6de79d2f","impliedFormat":99},{"version":"b7e28e06011460436d5c2ec2996846ac0c451e135357fc5a7269e5665a32fbd7","impliedFormat":99},{"version":"21e562cde44f5aed7baee7ee3541d4274f9a561b9589b2622537a9ef57b5768f","impliedFormat":99},{"version":"79a6eba90bfe3c1f721838d7e61b394d6d81c7b6d8d754df0b46509a3d147693","impliedFormat":99},{"version":"83194635ad31a639e339e90f46401d5e69810f93f7b06589bb26b1ae6f2bc211","impliedFormat":99},{"version":"3c1291fa957007538097ce38f7f0d65bf4c6ba6c2fad80ab806b71264fd296f4","affectsGlobalScope":true,"impliedFormat":1},{"version":"f11e0e40bd4f6bedb1cc15115dbef210137185cfe79c2b18ea2d8fe5059ed66c","impliedFormat":99},{"version":"79664f59ba31fe4cdb59c78824c9ce2a84e7686a52dcdecc62005096cc248458","affectsGlobalScope":true,"impliedFormat":99},{"version":"fe2d63fcfdde197391b6b70daf7be8c02a60afa90754a5f4a04bdc367f62793d","impliedFormat":99},{"version":"3b352d29931971dbaae2202a81257e13e739a77c547746a4e28ca2cd3c1aacd9","affectsGlobalScope":true,"impliedFormat":99},{"version":"4baf9111d939d3b5d10519e4e22d2589d15d008391ce2866f2d4295ae5419a6c","impliedFormat":99},{"version":"849ab6fd9f93c9ca914b60085a2a5e2df1f0e137739f4a7e23d2eaa530396d50","impliedFormat":99},{"version":"5825e828f2d57d0cf90a36f0caa4c8e457faeff96c5af59a2336aea8e9ea305d","impliedFormat":99},{"version":"5a88655bf852c8cc007d6bc874ab61d1d63fba97063020458177173c454e9b4a","impliedFormat":99},{"version":"7e4dfae2da12ec71ffd9f55f4641a6e05610ce0d6784838659490e259e4eb13c","impliedFormat":99},{"version":"c30a41267fc04c6518b17e55dcb2b810f267af4314b0b6d7df1c33a76ce1b330","impliedFormat":1},{"version":"72422d0bac4076912385d0c10911b82e4694fc106e2d70added091f88f0824ba","impliedFormat":1},{"version":"da251b82c25bee1d93f9fd80c5a61d945da4f708ca21285541d7aff83ecb8200","impliedFormat":1},{"version":"4c8ca51077f382498f47074cf304d654aba5d362416d4f809dfdd5d4f6b3aaca","impliedFormat":1},{"version":"c6bddf16578495abc8b5546850b047f30c4b5a2a2b7fecefc0e11a44a6e91399","impliedFormat":1},{"version":"d8c23711d682db1527eab3df7e9ee19a8ac4e2beeb1cbb79342a8e839e16b181","impliedFormat":99},{"version":"381d27c35f5a5bf6c09dd238ec26fef30a03d12ea84589c621ebc208d7dc8378","affectsGlobalScope":true,"impliedFormat":99}],"root":[84,86,[88,100]],"options":{"allowJs":true,"checkJs":true,"composite":true,"declarationMap":true,"esModuleInterop":true,"module":7,"outDir":"./","skipLibCheck":true,"strict":true,"target":9},"referencedMap":[[83,1],[171,2],[172,3],[176,4],[114,5],[107,6],[111,7],[158,8],[159,9],[152,10],[151,11],[164,11],[150,12],[153,13],[165,14],[110,15],[109,16],[112,16],[103,17],[106,18],[148,17],[108,19],[113,20],[82,21],[79,22],[80,23],[81,24],[181,25],[183,26],[182,27],[180,28],[87,29],[66,30],[69,31],[73,32],[70,33],[71,34],[76,35],[75,36],[74,37],[85,30],[68,38],[140,39],[138,40],[139,41],[127,42],[128,40],[135,43],[126,44],[131,45],[132,46],[137,47],[142,48],[125,49],[133,50],[134,51],[129,52],[136,39],[130,53],[117,54],[105,55],[162,56],[156,57],[157,56],[147,58],[122,59],[121,60],[119,60],[120,61],[146,62],[161,63],[154,64],[163,65],[173,66],[177,67],[166,68],[178,69],[174,70],[167,71],[168,72],[184,73],[185,74],[84,75],[92,76],[94,77],[93,78],[86,79],[95,80],[96,81],[97,82],[99,83],[100,84],[98,85],[89,86],[90,86],[91,87],[88,88]],"latestChangedDtsFile":"./src/crdt/batch/index.d.ts","version":"5.8.2"}
@@ -1,92 +0,0 @@
1
- import type { Version } from 'multiformats'
2
- import type { Link, UnknownLink } from 'multiformats/link/interface'
3
- import type { Block, BlockView } from 'multiformats/block/interface'
4
- import { sha256 } from 'multiformats/hashes/sha2'
5
- import * as dagCBOR from '@ipld/dag-cbor'
6
-
7
- export { Link, UnknownLink, BlockView, Block, Version }
8
-
9
- export type ShardEntryValueValue = UnknownLink
10
-
11
- export type ShardEntryLinkValue = [ShardLink]
12
-
13
- export type ShardEntryLinkAndValueValue = [ShardLink, UnknownLink]
14
-
15
- export type ShardValueEntry = [key: string, value: ShardEntryValueValue]
16
-
17
- export type ShardLinkEntry = [key: string, value: ShardEntryLinkValue | ShardEntryLinkAndValueValue]
18
-
19
- /** Single key/value entry within a shard. */
20
- export type ShardEntry = [key: string, value: ShardEntryValueValue | ShardEntryLinkValue | ShardEntryLinkAndValueValue]
21
-
22
- export interface Shard extends ShardConfig {
23
- entries: ShardEntry[]
24
- }
25
-
26
- export type ShardLink = Link<Shard, typeof dagCBOR.code, typeof sha256.code, 1>
27
-
28
- export interface ShardBlockView extends BlockView<Shard, typeof dagCBOR.code, typeof sha256.code, 1> {}
29
-
30
- export interface ShardDiff {
31
- additions: ShardBlockView[]
32
- removals: ShardBlockView[]
33
- }
34
-
35
- export interface BlockFetcher {
36
- get<T = unknown, C extends number = number, A extends number = number, V extends Version = 1> (link: Link<T, C, A, V>):
37
- Promise<Block<T, C, A, V> | undefined>
38
- }
39
-
40
- export interface ShardConfig {
41
- /** Shard compatibility version. */
42
- version: number
43
- /**
44
- * Characters allowed in keys, referring to a known character set.
45
- * e.g. "ascii" refers to the printable ASCII characters in the code range 32-126.
46
- */
47
- keyChars: string
48
- /** Max key size in bytes - default 4096 bytes. */
49
- maxKeySize: number
50
- /** The key prefix from the root to this shard. */
51
- prefix: string
52
- }
53
-
54
- export type ShardOptions = Partial<ShardConfig>
55
-
56
- export interface KeyPrefixOption {
57
- /** Filter results to entries with keys prefixed with this string. */
58
- prefix: string
59
- }
60
-
61
- export type KeyRangeOption =
62
- | KeyLowerBoundRangeOption
63
- | KeyUpperBoundRangeOption
64
- | (KeyLowerBoundRangeOption & KeyUpperBoundRangeOption)
65
-
66
- export type KeyLowerBoundRangeOption =
67
- | KeyLowerBoundRangeExclusiveOption
68
- | KeyLowerBoundRangeInclusiveOption
69
-
70
- export interface KeyLowerBoundRangeExclusiveOption {
71
- gt: string
72
- }
73
-
74
- export interface KeyLowerBoundRangeInclusiveOption {
75
- gte: string
76
- }
77
-
78
- export type KeyUpperBoundRangeOption =
79
- | KeyUpperBoundRangeExclusiveOption
80
- | KeyUpperBoundRangeInclusiveOption
81
-
82
- export interface KeyUpperBoundRangeExclusiveOption {
83
- lt: string
84
- }
85
-
86
- export interface KeyUpperBoundRangeInclusiveOption {
87
- lte: string
88
- }
89
-
90
- export type EntriesOptions =
91
- | KeyPrefixOption
92
- | KeyRangeOption
@@ -1 +0,0 @@
1
- export {}
@@ -1,59 +0,0 @@
1
- import {
2
- UnknownLink,
3
- ShardLink,
4
- ShardDiff,
5
- ShardEntry,
6
- ShardEntryValueValue,
7
- ShardEntryLinkValue,
8
- ShardEntryLinkAndValueValue,
9
- ShardConfig,
10
- ShardOptions,
11
- ShardBlockView,
12
- BlockFetcher
13
- } from '../api.js'
14
-
15
- export {
16
- UnknownLink,
17
- ShardLink,
18
- ShardDiff,
19
- ShardEntry,
20
- ShardEntryValueValue,
21
- ShardEntryLinkValue,
22
- ShardEntryLinkAndValueValue,
23
- ShardConfig,
24
- ShardOptions,
25
- ShardBlockView,
26
- BlockFetcher
27
- }
28
-
29
- export interface BatcherShard extends ShardConfig {
30
- base?: ShardBlockView
31
- entries: BatcherShardEntry[]
32
- }
33
-
34
- export interface BatcherShardInit extends ShardOptions {
35
- base?: ShardBlockView
36
- entries?: BatcherShardEntry[]
37
- }
38
-
39
- export type BatcherShardEntry = [
40
- key: string,
41
- value: ShardEntryValueValue | ShardEntryLinkValue | ShardEntryLinkAndValueValue | ShardEntryShardValue | ShardEntryShardAndValueValue
42
- ]
43
-
44
- export type ShardEntryShardValue = [BatcherShard]
45
-
46
- export type ShardEntryShardAndValueValue = [BatcherShard, UnknownLink]
47
-
48
- export interface Batcher {
49
- /**
50
- * Put a value (a CID) for the given key. If the key exists it's value is
51
- * overwritten.
52
- */
53
- put (key: string, value: UnknownLink): Promise<void>
54
- /**
55
- * Encode all altered shards in the batch and return the new root CID and
56
- * difference blocks.
57
- */
58
- commit (): Promise<{ root: ShardLink } & ShardDiff>
59
- }
@@ -1,258 +0,0 @@
1
- // eslint-disable-next-line no-unused-vars
2
- import * as API from './api.js'
3
- import { ShardFetcher, isPrintableASCII } from '../shard.js'
4
- import * as Shard from '../shard.js'
5
- import * as BatcherShard from './shard.js'
6
-
7
- /** @implements {API.Batcher} */
8
- class Batcher {
9
- #committed = false
10
-
11
- /**
12
- * @param {object} init
13
- * @param {API.BlockFetcher} init.blocks Block storage.
14
- * @param {API.BatcherShardEntry[]} init.entries The entries in this shard.
15
- * @param {string} init.prefix Key prefix.
16
- * @param {number} init.version Shard compatibility version.
17
- * @param {string} init.keyChars Characters allowed in keys, referring to a known character set.
18
- * @param {number} init.maxKeySize Max key size in bytes.
19
- * @param {API.ShardBlockView} init.base Original shard this batcher is based on.
20
- */
21
- constructor ({ blocks, entries, prefix, version, keyChars, maxKeySize, base }) {
22
- this.blocks = blocks
23
- this.prefix = prefix
24
- this.entries = [...entries]
25
- this.base = base
26
- this.version = version
27
- this.keyChars = keyChars
28
- this.maxKeySize = maxKeySize
29
- }
30
-
31
- /**
32
- * @param {string} key The key of the value to put.
33
- * @param {API.UnknownLink} value The value to put.
34
- * @returns {Promise<void>}
35
- */
36
- async put (key, value) {
37
- if (this.#committed) throw new BatchCommittedError()
38
- return put(this.blocks, this, key, value)
39
- }
40
-
41
- async commit () {
42
- if (this.#committed) throw new BatchCommittedError()
43
- this.#committed = true
44
- return commit(this)
45
- }
46
-
47
- /**
48
- * @param {object} init
49
- * @param {API.BlockFetcher} init.blocks Block storage.
50
- * @param {API.ShardLink} init.link CID of the shard block.
51
- */
52
- static async create ({ blocks, link }) {
53
- const shards = new ShardFetcher(blocks)
54
- const base = await shards.get(link)
55
- return new Batcher({ blocks, base, ...base.value })
56
- }
57
- }
58
-
59
- /**
60
- * @param {API.BlockFetcher} blocks
61
- * @param {API.BatcherShard} shard
62
- * @param {string} key The key of the value to put.
63
- * @param {API.UnknownLink} value The value to put.
64
- * @returns {Promise<void>}
65
- */
66
- export const put = async (blocks, shard, key, value) => {
67
- if (shard.keyChars !== Shard.KeyCharsASCII) {
68
- throw new Error(`unsupported key character set: ${shard.keyChars}`)
69
- }
70
- if (!isPrintableASCII(key)) {
71
- throw new Error('key contains non-ASCII characters')
72
- }
73
- // ensure utf8 encoded key is smaller than max
74
- if (new TextEncoder().encode(key).length > shard.maxKeySize) {
75
- throw new Error(`UTF-8 encoded key exceeds max size of ${shard.maxKeySize} bytes`)
76
- }
77
-
78
- const shards = new ShardFetcher(blocks)
79
- const dest = await traverse(shards, shard, key)
80
- if (dest.shard !== shard) {
81
- shard = dest.shard
82
- key = dest.key
83
- }
84
-
85
- /** @type {API.BatcherShardEntry} */
86
- let entry = [dest.key, value]
87
- let targetEntries = [...dest.shard.entries]
88
-
89
- for (const [i, e] of targetEntries.entries()) {
90
- const [k, v] = e
91
-
92
- // is this just a replace?
93
- if (k === dest.key) break
94
-
95
- // do we need to shard this entry?
96
- const shortest = k.length < dest.key.length ? k : dest.key
97
- const other = shortest === k ? dest.key : k
98
- let common = ''
99
- for (const char of shortest) {
100
- const next = common + char
101
- if (!other.startsWith(next)) break
102
- common = next
103
- }
104
- if (common.length) {
105
- /** @type {API.ShardEntry[]} */
106
- let entries = []
107
-
108
- // if the existing entry key or new key is equal to the common prefix,
109
- // then the existing value / new value needs to persist in the parent
110
- // shard. Otherwise they persist in this new shard.
111
- if (common !== dest.key) {
112
- entries = Shard.putEntry(entries, [dest.key.slice(common.length), value])
113
- }
114
- if (common !== k) {
115
- entries = Shard.putEntry(entries, asShardEntry([k.slice(common.length), v]))
116
- }
117
-
118
- let child = BatcherShard.create({
119
- ...Shard.configure(dest.shard),
120
- prefix: dest.shard.prefix + common,
121
- entries
122
- })
123
-
124
- // need to spread as access by index does not consider utf-16 surrogates
125
- const commonChars = [...common]
126
-
127
- // create parent shards for each character of the common prefix
128
- for (let i = commonChars.length - 1; i > 0; i--) {
129
- /** @type {API.ShardEntryShardValue | API.ShardEntryShardAndValueValue} */
130
- let parentValue
131
- // if the first iteration and the existing entry key is equal to the
132
- // common prefix, then existing value needs to persist in this parent
133
- if (i === commonChars.length - 1 && common === k) {
134
- if (Array.isArray(v)) throw new Error('found a shard link when expecting a value')
135
- parentValue = [child, v]
136
- } else if (i === commonChars.length - 1 && common === dest.key) {
137
- parentValue = [child, value]
138
- } else {
139
- parentValue = [child]
140
- }
141
- const parent = BatcherShard.create({
142
- ...Shard.configure(dest.shard),
143
- prefix: dest.shard.prefix + commonChars.slice(0, i).join(''),
144
- entries: [[commonChars[i], parentValue]]
145
- })
146
- child = parent
147
- }
148
-
149
- // remove the sharded entry
150
- targetEntries.splice(i, 1)
151
-
152
- // create the entry that will be added to target
153
- if (commonChars.length === 1 && common === k) {
154
- if (Array.isArray(v)) throw new Error('found a shard link when expecting a value')
155
- entry = [commonChars[0], [child, v]]
156
- } else if (commonChars.length === 1 && common === dest.key) {
157
- entry = [commonChars[0], [child, value]]
158
- } else {
159
- entry = [commonChars[0], [child]]
160
- }
161
- break
162
- }
163
- }
164
-
165
- shard.entries = Shard.putEntry(asShardEntries(targetEntries), asShardEntry(entry))
166
- }
167
-
168
- /**
169
- * Traverse from the passed shard through to the correct shard for the passed
170
- * key.
171
- *
172
- * @param {ShardFetcher} shards
173
- * @param {API.BatcherShard} shard
174
- * @param {string} key
175
- * @returns {Promise<{ shard: API.BatcherShard, key: string }>}
176
- */
177
- export const traverse = async (shards, shard, key) => {
178
- for (let i = 0; i < shard.entries.length; i++) {
179
- const [k, v] = shard.entries[i]
180
- if (key <= k) break
181
- if (key.startsWith(k) && Array.isArray(v)) {
182
- if (Shard.isShardLink(v[0])) {
183
- const blk = await shards.get(v[0])
184
- const batcher = BatcherShard.create({ base: blk, ...blk.value })
185
- shard.entries[i] = [k, v[1] == null ? [batcher] : [batcher, v[1]]]
186
- return traverse(shards, batcher, key.slice(k.length))
187
- }
188
- return traverse(shards, v[0], key.slice(k.length))
189
- }
190
- }
191
- return { shard, key }
192
- }
193
-
194
- /**
195
- * Encode all altered shards in the batch and return the new root CID and
196
- * difference blocks.
197
- *
198
- * @param {API.BatcherShard} shard
199
- */
200
- export const commit = async shard => {
201
- /** @type {API.ShardBlockView[]} */
202
- const additions = []
203
- /** @type {API.ShardBlockView[]} */
204
- const removals = []
205
-
206
- /** @type {API.ShardEntry[]} */
207
- const entries = []
208
- for (const entry of shard.entries) {
209
- if (Array.isArray(entry[1]) && !Shard.isShardLink(entry[1][0])) {
210
- const result = await commit(entry[1][0])
211
- entries.push([
212
- entry[0],
213
- entry[1][1] == null ? [result.root] : [result.root, entry[1][1]]
214
- ])
215
- additions.push(...result.additions)
216
- removals.push(...result.removals)
217
- } else {
218
- entries.push(asShardEntry(entry))
219
- }
220
- }
221
-
222
- const block = await Shard.encodeBlock(Shard.withEntries(entries, shard))
223
- additions.push(block)
224
-
225
- if (shard.base && shard.base.cid.toString() === block.cid.toString()) {
226
- return { root: block.cid, additions: [], removals: [] }
227
- }
228
-
229
- if (shard.base) removals.push(shard.base)
230
-
231
- return { root: block.cid, additions, removals }
232
- }
233
-
234
- /** @param {API.BatcherShardEntry[]} entries */
235
- const asShardEntries = entries => /** @type {API.ShardEntry[]} */ (entries)
236
-
237
- /** @param {API.BatcherShardEntry} entry */
238
- const asShardEntry = entry => /** @type {API.ShardEntry} */ (entry)
239
-
240
- /**
241
- * @param {API.BlockFetcher} blocks Bucket block storage.
242
- * @param {API.ShardLink} root CID of the root shard block.
243
- * @returns {Promise<API.Batcher>}
244
- */
245
- export const create = (blocks, root) => Batcher.create({ blocks, link: root })
246
-
247
- export class BatchCommittedError extends Error {
248
- /**
249
- * @param {string} [message]
250
- * @param {ErrorOptions} [options]
251
- */
252
- constructor (message, options) {
253
- super(message ?? 'batch already committed', options)
254
- this.code = BatchCommittedError.code
255
- }
256
-
257
- static code = 'ERR_BATCH_COMMITTED'
258
- }
@@ -1,13 +0,0 @@
1
- // eslint-disable-next-line no-unused-vars
2
- import * as API from './api.js'
3
- import { configure } from '../shard.js'
4
-
5
- /**
6
- * @param {API.BatcherShardInit} [init]
7
- * @returns {API.BatcherShard}
8
- */
9
- export const create = init => ({
10
- base: init?.base,
11
- entries: [...(init?.entries ?? [])],
12
- ...configure(init)
13
- })
@@ -1,75 +0,0 @@
1
- // eslint-disable-next-line no-unused-vars
2
- import * as API from './api.js'
3
- import { parse } from 'multiformats/link'
4
-
5
- /** @implements {API.BlockFetcher} */
6
- export class MemoryBlockstore {
7
- /** @type {Map<string, Uint8Array>} */
8
- #blocks = new Map()
9
-
10
- /**
11
- * @param {Array<import('multiformats').Block>} [blocks]
12
- */
13
- constructor (blocks) {
14
- if (blocks) {
15
- this.#blocks = new Map(blocks.map(b => [b.cid.toString(), b.bytes]))
16
- }
17
- }
18
-
19
- /** @type {API.BlockFetcher['get']} */
20
- async get (cid) {
21
- const bytes = this.#blocks.get(cid.toString())
22
- if (!bytes) return
23
- return { cid, bytes }
24
- }
25
-
26
- /**
27
- * @param {API.UnknownLink} cid
28
- * @param {Uint8Array} bytes
29
- */
30
- async put (cid, bytes) {
31
- this.#blocks.set(cid.toString(), bytes)
32
- }
33
-
34
- /**
35
- * @param {API.UnknownLink} cid
36
- * @param {Uint8Array} bytes
37
- */
38
- putSync (cid, bytes) {
39
- this.#blocks.set(cid.toString(), bytes)
40
- }
41
-
42
- /** @param {API.UnknownLink} cid */
43
- async delete (cid) {
44
- this.#blocks.delete(cid.toString())
45
- }
46
-
47
- /** @param {API.UnknownLink} cid */
48
- deleteSync (cid) {
49
- this.#blocks.delete(cid.toString())
50
- }
51
-
52
- * entries () {
53
- for (const [str, bytes] of this.#blocks) {
54
- yield { cid: parse(str), bytes }
55
- }
56
- }
57
- }
58
-
59
- export class MultiBlockFetcher {
60
- /** @type {API.BlockFetcher[]} */
61
- #fetchers
62
-
63
- /** @param {API.BlockFetcher[]} fetchers */
64
- constructor (...fetchers) {
65
- this.#fetchers = fetchers
66
- }
67
-
68
- /** @type {API.BlockFetcher['get']} */
69
- async get (link) {
70
- for (const f of this.#fetchers) {
71
- const v = await f.get(link)
72
- if (v) return v
73
- }
74
- }
75
- }
@@ -1 +0,0 @@
1
- export {}
@@ -1,12 +0,0 @@
1
- import { Link, BlockView } from 'multiformats'
2
-
3
- export { BlockFetcher } from '../api.js'
4
-
5
- export type EventLink<T> = Link<EventView<T>>
6
-
7
- export interface EventView<T> {
8
- parents: EventLink<T>[]
9
- data: T
10
- }
11
-
12
- export interface EventBlockView<T> extends BlockView<EventView<T>> {}