tool-db 2.5.6 → 2.6.2
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.
- package/README.md +1 -2
- package/bundle.js +1 -1
- package/dist/adapters-base/networkAdapter.js +3 -2
- package/dist/adapters-base/networkAdapter.js.map +1 -1
- package/dist/adapters-base/storageAdapter.d.ts +15 -0
- package/dist/adapters-base/storageAdapter.js +68 -0
- package/dist/adapters-base/storageAdapter.js.map +1 -1
- package/dist/adapters-base/userAdapter.d.ts +2 -2
- package/dist/adapters-base/userAdapter.js +46 -2
- package/dist/adapters-base/userAdapter.js.map +1 -1
- package/dist/crdt/counterCrdt.js +2 -1
- package/dist/crdt/counterCrdt.js.map +1 -1
- package/dist/crdt/listCrdt.js +2 -2
- package/dist/crdt/listCrdt.js.map +1 -1
- package/dist/crdt/mapCrdt.js +6 -4
- package/dist/crdt/mapCrdt.js.map +1 -1
- package/dist/index.d.ts +5 -0
- package/dist/index.js +11 -1
- package/dist/index.js.map +1 -1
- package/dist/messageHandlers/handleCrdtPut.js +51 -40
- package/dist/messageHandlers/handleCrdtPut.js.map +1 -1
- package/dist/messageHandlers/handleFunction.js +1 -1
- package/dist/messageHandlers/handleFunction.js.map +1 -1
- package/dist/messageHandlers/handlePong.js +14 -10
- package/dist/messageHandlers/handlePong.js.map +1 -1
- package/dist/toolDbAnonSignIn.d.ts +1 -1
- package/dist/toolDbAnonSignIn.js +46 -1
- package/dist/toolDbAnonSignIn.js.map +1 -1
- package/dist/toolDbCrdtGet.js +1 -1
- package/dist/toolDbCrdtGet.js.map +1 -1
- package/dist/toolDbKeysSignIn.js +52 -8
- package/dist/toolDbKeysSignIn.js.map +1 -1
- package/dist/toolDbQueryKeys.js +7 -2
- package/dist/toolDbQueryKeys.js.map +1 -1
- package/dist/toolDbSignIn.js +52 -4
- package/dist/toolDbSignIn.js.map +1 -1
- package/dist/toolDbSignUp.js +1 -1
- package/dist/toolDbSignUp.js.map +1 -1
- package/dist/tooldb.js +46 -3
- package/dist/tooldb.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/dist/types/tooldb.d.ts +3 -2
- package/dist/utils/encoding/arrayBufferToString.js +2 -6
- package/dist/utils/encoding/arrayBufferToString.js.map +1 -1
- package/dist/utils/encoding/base64ToUint8.d.ts +1 -0
- package/dist/utils/encoding/base64ToUint8.js +17 -0
- package/dist/utils/encoding/base64ToUint8.js.map +1 -0
- package/dist/utils/encoding/fromBase64.d.ts +1 -0
- package/dist/utils/encoding/fromBase64.js +7 -0
- package/dist/utils/encoding/fromBase64.js.map +1 -0
- package/dist/utils/encoding/stringToArrayBuffer.js +2 -6
- package/dist/utils/encoding/stringToArrayBuffer.js.map +1 -1
- package/dist/utils/encoding/toBase64.d.ts +1 -0
- package/dist/utils/encoding/toBase64.js +7 -0
- package/dist/utils/encoding/toBase64.js.map +1 -0
- package/dist/utils/encoding/uint8ToBase64.d.ts +1 -0
- package/dist/utils/encoding/uint8ToBase64.js +15 -0
- package/dist/utils/encoding/uint8ToBase64.js.map +1 -0
- package/dist/utils/generateGroupKey.d.ts +5 -0
- package/dist/utils/generateGroupKey.js +16 -0
- package/dist/utils/generateGroupKey.js.map +1 -0
- package/dist/utils/proofOfWork.d.ts +8 -1
- package/dist/utils/proofOfWork.js +14 -0
- package/dist/utils/proofOfWork.js.map +1 -1
- package/dist/utils/verifyMessage.d.ts +1 -1
- package/dist/utils/verifyMessage.js +2 -2
- package/dist/utils/verifyMessage.js.map +1 -1
- package/lib/adapters-base/networkAdapter.ts +3 -2
- package/lib/adapters-base/storageAdapter.ts +22 -0
- package/lib/adapters-base/userAdapter.ts +2 -2
- package/lib/crdt/counterCrdt.ts +2 -1
- package/lib/crdt/listCrdt.ts +2 -2
- package/lib/crdt/mapCrdt.ts +6 -4
- package/lib/index.ts +6 -0
- package/lib/messageHandlers/handleCrdtPut.ts +68 -58
- package/lib/messageHandlers/handleFunction.ts +1 -1
- package/lib/messageHandlers/handlePong.ts +19 -12
- package/lib/toolDbAnonSignIn.ts +2 -2
- package/lib/toolDbCrdtGet.ts +1 -1
- package/lib/toolDbKeysSignIn.ts +4 -7
- package/lib/toolDbQueryKeys.ts +8 -2
- package/lib/toolDbSignIn.ts +8 -3
- package/lib/toolDbSignUp.ts +1 -1
- package/lib/tooldb.ts +2 -2
- package/lib/types/tooldb.ts +3 -2
- package/lib/utils/encoding/arrayBufferToString.ts +3 -7
- package/lib/utils/encoding/base64ToUint8.ts +13 -0
- package/lib/utils/encoding/fromBase64.ts +4 -0
- package/lib/utils/encoding/stringToArrayBuffer.ts +3 -7
- package/lib/utils/encoding/toBase64.ts +4 -0
- package/lib/utils/encoding/uint8ToBase64.ts +11 -0
- package/lib/utils/generateGroupKey.ts +11 -0
- package/lib/utils/proofOfWork.ts +16 -1
- package/lib/utils/verifyMessage.ts +3 -3
- package/package.json +2 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"program":{"fileNames":["../../../node_modules/typescript/lib/lib.es5.d.ts","../../../node_modules/typescript/lib/lib.es2015.d.ts","../../../node_modules/typescript/lib/lib.es2016.d.ts","../../../node_modules/typescript/lib/lib.es2017.d.ts","../../../node_modules/typescript/lib/lib.es2018.d.ts","../../../node_modules/typescript/lib/lib.es2019.d.ts","../../../node_modules/typescript/lib/lib.es2020.d.ts","../../../node_modules/typescript/lib/lib.es2021.d.ts","../../../node_modules/typescript/lib/lib.es2022.d.ts","../../../node_modules/typescript/lib/lib.esnext.d.ts","../../../node_modules/typescript/lib/lib.dom.d.ts","../../../node_modules/typescript/lib/lib.dom.iterable.d.ts","../../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../node_modules/typescript/lib/lib.es2019.array.d.ts","../../../node_modules/typescript/lib/lib.es2019.object.d.ts","../../../node_modules/typescript/lib/lib.es2019.string.d.ts","../../../node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../node_modules/typescript/lib/lib.es2020.date.d.ts","../../../node_modules/typescript/lib/lib.es2020.promise.d.ts","../../../node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../../node_modules/typescript/lib/lib.es2020.string.d.ts","../../../node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../../node_modules/typescript/lib/lib.es2020.intl.d.ts","../../../node_modules/typescript/lib/lib.es2020.number.d.ts","../../../node_modules/typescript/lib/lib.es2021.promise.d.ts","../../../node_modules/typescript/lib/lib.es2021.string.d.ts","../../../node_modules/typescript/lib/lib.es2021.weakref.d.ts","../../../node_modules/typescript/lib/lib.es2021.intl.d.ts","../../../node_modules/typescript/lib/lib.es2022.array.d.ts","../../../node_modules/typescript/lib/lib.es2022.error.d.ts","../../../node_modules/typescript/lib/lib.es2022.intl.d.ts","../../../node_modules/typescript/lib/lib.es2022.object.d.ts","../../../node_modules/typescript/lib/lib.es2022.string.d.ts","../../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../lib/utils/proofofwork.ts","../lib/utils/sha1.ts","../lib/utils/sha256.ts","../lib/utils/uniq.ts","../lib/utils/randomanimal.ts","../lib/utils/verifymessage.ts","../lib/utils/getpeersignature.ts","../lib/utils/verifypeer.ts","../lib/utils/textrandom.ts","../lib/utils/catchreturn.ts","../lib/utils/encoding/stringtoarraybuffer.ts","../lib/utils/encoding/arraybuffertostring.ts","../lib/utils/encoding/arraybuffertohex.ts","../lib/utils/encoding/hextoarraybuffer.ts","../lib/utils/encoding/hextostring.ts","../lib/utils/encoding/hextouint8.ts","../lib/adapters-base/networkadapter.ts","../lib/adapters-base/storageadapter.ts","../lib/adapters-base/useradapter.ts","../lib/types/tooldb.ts","../lib/types/message.ts","../lib/crdt/basecrdt.ts","../lib/crdt/countercrdt.ts","../lib/crdt/listcrdt.ts","../lib/crdt/mapcrdt.ts","../lib/messagehandlers/handlesubscribe.ts","../lib/messagehandlers/handlefunction.ts","../lib/messagehandlers/handlecrdtget.ts","../lib/tooldbverificationwrapper.ts","../lib/messagehandlers/handlecrdtput.ts","../lib/messagehandlers/handlequery.ts","../lib/messagehandlers/handleping.ts","../lib/messagehandlers/handlepong.ts","../lib/messagehandlers/handleget.ts","../lib/messagehandlers/handleput.ts","../lib/tooldbget.ts","../lib/tooldbput.ts","../lib/tooldbsignin.ts","../lib/tooldbsignup.ts","../lib/tooldbcrdtget.ts","../lib/tooldbcrdtput.ts","../lib/tooldbfunction.ts","../lib/tooldbanonsignin.ts","../lib/tooldbclientonmessage.ts","../lib/tooldbquerykeys.ts","../lib/tooldbkeyssignin.ts","../lib/tooldbsubscribe.ts","../lib/logger.ts","../lib/tooldb.ts","../lib/index.ts","../lib/server.ts","../lib/shared.ts","../lib/utils/gettimestamp.ts","../../../node_modules/@types/abstract-leveldown/index.d.ts","../../../node_modules/@types/babel__generator/index.d.ts","../../../node_modules/@types/babel__template/index.d.ts","../../../node_modules/@types/babel__traverse/index.d.ts","../../../node_modules/@types/babel__core/index.d.ts","../../../node_modules/@types/node/assert.d.ts","../../../node_modules/@types/node/assert/strict.d.ts","../../../node_modules/@types/node/worker_threads.d.ts","../../../node_modules/@types/node/globals.d.ts","../../../node_modules/@types/node/async_hooks.d.ts","../../../node_modules/@types/node/buffer.d.ts","../../../node_modules/@types/node/child_process.d.ts","../../../node_modules/@types/node/cluster.d.ts","../../../node_modules/@types/node/console.d.ts","../../../node_modules/@types/node/constants.d.ts","../../../node_modules/@types/node/crypto.d.ts","../../../node_modules/@types/node/dgram.d.ts","../../../node_modules/@types/node/diagnostics_channel.d.ts","../../../node_modules/@types/node/dns.d.ts","../../../node_modules/@types/node/dns/promises.d.ts","../../../node_modules/@types/node/domain.d.ts","../../../node_modules/@types/node/events.d.ts","../../../node_modules/@types/node/fs.d.ts","../../../node_modules/@types/node/fs/promises.d.ts","../../../node_modules/@types/node/http.d.ts","../../../node_modules/@types/node/http2.d.ts","../../../node_modules/@types/node/https.d.ts","../../../node_modules/@types/node/inspector.d.ts","../../../node_modules/@types/node/module.d.ts","../../../node_modules/@types/node/net.d.ts","../../../node_modules/@types/node/os.d.ts","../../../node_modules/@types/node/path.d.ts","../../../node_modules/@types/node/perf_hooks.d.ts","../../../node_modules/@types/node/process.d.ts","../../../node_modules/@types/node/punycode.d.ts","../../../node_modules/@types/node/querystring.d.ts","../../../node_modules/@types/node/readline.d.ts","../../../node_modules/@types/node/repl.d.ts","../../../node_modules/@types/node/stream.d.ts","../../../node_modules/@types/node/stream/promises.d.ts","../../../node_modules/@types/node/stream/consumers.d.ts","../../../node_modules/@types/node/stream/web.d.ts","../../../node_modules/@types/node/string_decoder.d.ts","../../../node_modules/@types/node/test.d.ts","../../../node_modules/@types/node/timers.d.ts","../../../node_modules/@types/node/timers/promises.d.ts","../../../node_modules/@types/node/tls.d.ts","../../../node_modules/@types/node/trace_events.d.ts","../../../node_modules/@types/node/tty.d.ts","../../../node_modules/@types/node/url.d.ts","../../../node_modules/@types/node/util.d.ts","../../../node_modules/@types/node/v8.d.ts","../../../node_modules/@types/node/vm.d.ts","../../../node_modules/@types/node/wasi.d.ts","../../../node_modules/@types/node/zlib.d.ts","../../../node_modules/@types/node/globals.global.d.ts","../../../node_modules/@types/node/index.d.ts","../../../node_modules/@types/bn.js/index.d.ts","../../../node_modules/@types/keyv/index.d.ts","../../../node_modules/@types/http-cache-semantics/index.d.ts","../../../node_modules/@types/responselike/index.d.ts","../../../node_modules/@types/cacheable-request/index.d.ts","../../../node_modules/@types/level-codec/index.d.ts","../../../node_modules/@types/encoding-down/index.d.ts","../../../node_modules/@types/graceful-fs/index.d.ts","../../../node_modules/@types/istanbul-lib-coverage/index.d.ts","../../../node_modules/@types/istanbul-lib-report/index.d.ts","../../../node_modules/@types/istanbul-reports/index.d.ts","../../../node_modules/@types/jest/index.d.ts","../../../node_modules/@types/parse5/lib/tree-adapters/default.d.ts","../../../node_modules/@types/parse5/index.d.ts","../../../node_modules/@types/tough-cookie/index.d.ts","../../../node_modules/@types/jsdom/base.d.ts","../../../node_modules/@types/jsdom/ts4.0/index.d.ts","../../../node_modules/@types/jsdom/index.d.ts","../../../node_modules/@types/json-buffer/index.d.ts","../../../node_modules/@types/json-schema/index.d.ts","../../../node_modules/@types/json5/index.d.ts","../../../node_modules/@types/level-errors/index.d.ts","../../../node_modules/@types/levelup/index.d.ts","../../../node_modules/@types/level/index.d.ts","../../../node_modules/@types/minimatch/index.d.ts","../../../node_modules/@types/minimist/index.d.ts","../../../node_modules/@types/normalize-package-data/index.d.ts","../../../node_modules/@types/parse-json/index.d.ts","../../../node_modules/@types/pbkdf2/index.d.ts","../../../node_modules/@types/prettier/index.d.ts","../../../node_modules/@types/secp256k1/index.d.ts","../../../node_modules/@types/simple-peer/index.d.ts","../../../node_modules/@types/stack-utils/index.d.ts","../../../node_modules/@types/ws/index.d.ts","../../../node_modules/@types/yargs-parser/index.d.ts","../../../node_modules/@types/yargs/index.d.ts"],"fileInfos":[{"version":"f5c28122bee592cfaf5c72ed7bcc47f453b79778ffa6e301f45d21a0970719d4","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06","e6b724280c694a9f588847f754198fb96c43d805f065c3a5b28bbc9594541c84","1fc5ab7a764205c68fa10d381b08417795fc73111d6dd16b5b1ed36badb743d9","746d62152361558ea6d6115cf0da4dd10ede041d14882ede3568bce5dc4b4f1f","3eb679a56cab01203a1ba7edeade937f6a2a4c718513b2cd930b579807fa9359","aea179452def8a6152f98f63b191b84e7cbd69b0e248c91e61fb2e52328abe8c",{"version":"3f149f903dd20dfeb7c80e228b659f0e436532de772469980dbd00702cc05cc1","affectsGlobalScope":true},{"version":"1272277fe7daa738e555eb6cc45ded42cc2d0f76c07294142283145d49e96186","affectsGlobalScope":true},{"version":"adb996790133eb33b33aadb9c09f15c2c575e71fb57a62de8bf74dbf59ec7dfb","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"c5c05907c02476e4bde6b7e76a79ffcd948aedd14b6a8f56e4674221b0417398","affectsGlobalScope":true},{"version":"0d5f52b3174bee6edb81260ebcd792692c32c81fd55499d69531496f3f2b25e7","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"181f1784c6c10b751631b24ce60c7f78b20665db4550b335be179217bacc0d5f","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"75ec0bdd727d887f1b79ed6619412ea72ba3c81d92d0787ccb64bab18d261f14","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"9d57b2b5d15838ed094aa9ff1299eecef40b190722eb619bac4616657a05f951","affectsGlobalScope":true},{"version":"6c51b5dd26a2c31dbf37f00cfc32b2aa6a92e19c995aefb5b97a3a64f1ac99de","affectsGlobalScope":true},{"version":"6e7997ef61de3132e4d4b2250e75343f487903ddf5370e7ce33cf1b9db9a63ed","affectsGlobalScope":true},{"version":"2ad234885a4240522efccd77de6c7d99eecf9b4de0914adb9a35c0c22433f993","affectsGlobalScope":true},{"version":"09aa50414b80c023553090e2f53827f007a301bc34b0495bfb2c3c08ab9ad1eb","affectsGlobalScope":true},{"version":"d7f680a43f8cd12a6b6122c07c54ba40952b0c8aa140dcfcf32eb9e6cb028596","affectsGlobalScope":true},{"version":"3787b83e297de7c315d55d4a7c546ae28e5f6c0a361b7a1dcec1f1f50a54ef11","affectsGlobalScope":true},{"version":"e7e8e1d368290e9295ef18ca23f405cf40d5456fa9f20db6373a61ca45f75f40","affectsGlobalScope":true},{"version":"faf0221ae0465363c842ce6aa8a0cbda5d9296940a8e26c86e04cc4081eea21e","affectsGlobalScope":true},{"version":"06393d13ea207a1bfe08ec8d7be562549c5e2da8983f2ee074e00002629d1871","affectsGlobalScope":true},{"version":"cd483c056da900716879771893a3c9772b66c3c88f8943b4205aec738a94b1d0","affectsGlobalScope":true},{"version":"b248e32ca52e8f5571390a4142558ae4f203ae2f94d5bac38a3084d529ef4e58","affectsGlobalScope":true},{"version":"6c55633c733c8378db65ac3da7a767c3cf2cf3057f0565a9124a16a3a2019e87","affectsGlobalScope":true},{"version":"fb4416144c1bf0323ccbc9afb0ab289c07312214e8820ad17d709498c865a3fe","affectsGlobalScope":true},{"version":"5b0ca94ec819d68d33da516306c15297acec88efeb0ae9e2b39f71dbd9685ef7","affectsGlobalScope":true},{"version":"ff667ee99e5a28c3dc5063a3cfd4d3436699e3fb035d4451037da7f567da542a","affectsGlobalScope":true},{"version":"34478567f8a80171f88f2f30808beb7da15eac0538ae91282dd33dce928d98ed","affectsGlobalScope":true},{"version":"6ea9ab679ea030cf46c16a711a316078e9e02619ebaf07a7fcd16964aba88f2d","affectsGlobalScope":true},{"version":"6bda95ea27a59a276e46043b7065b55bd4b316c25e70e29b572958fa77565d43","affectsGlobalScope":true},{"version":"aedb8de1abb2ff1095c153854a6df7deae4a5709c37297f9d6e9948b6806fa66","affectsGlobalScope":true},{"version":"11ffe3c281f375fff9ffdde8bbec7669b4dd671905509079f866f2354a788064","affectsGlobalScope":true},{"version":"c37f8a49593a0030eecb51bbfa270e709bec9d79a6cc3bb851ef348d4e6b26f8","affectsGlobalScope":true},"76802aef992406e96761f352df34f137bc9d1834cecda89d94add71321b1da82","67105610d6198f8dfa1cc7c6c0e1de451c70df7c61736107602f8a1f9483370c","a766cc79a5724f856887034255c3ea17ba214b2b1be890908f49db417aeb8a0e","99912cb4da93cdd681820f79a9c80da9f9fafdd8f81f44f68d28342f8157edcb","22c6a46e4401a07cc5d6cca4bc2193e64476659c8e34f3614c5a5abec6406a84","cc3de76adf5cdf6f3df7159330aab17316dfcdcf0af88f2cda3dc638c8af8d74","0580954d68944a77b5bb09ff6ceda1dcdf58b6f5b901695f2f4cf02565e89473","1060625553787e21e6284ddd370af46262c4875286d0f6cdf5b5929ba97812f6","283f369a2dd7fe798e325b9df42ef242007bdbba33d752a5f9c6104521fe2f6f","158a1d349a085f9a3d99394aeade67ae71586f54af15dc238d9cdf0fa5337b20","29aaa6eef63227d002657305d9da615df52fe039a751b895284246592f56816e","f71e0e4ae49e398c64e64211d35fabc8e4c2367dea26677859906507deefd39e","59d73c82ebf4c64cd6efa8824c3693af3c1f2cd9b67d6205618e5c7154ca6d0e","a9ec4d0390d7ea1c3cf1c8648051414c601ea139948ced0456dd3fdf17add6f9","754311e63297f081337819e7800f2e55cf2127596be34229f401cd2865ac78d6","83e1f37a05cde7be453abf9437880e1cfdf3711610e2bcaa47bc7dbf301293d7","e54ffdacf8dc269c1fc81cb0c6b7c1a99eec73374698b38180d2789ff3ccabb3","8e654a69e60f35c9ada0969caf037ee23bcb1593d9788c16f27924d8c5b4b28b","7bdab0655120d4b753680bb47012e85269afcd65b89cac895c6eb62970ec632e","bd8812013e4d2f98e3acc01a0caaa6391958ee406d524b1da72b78cc10ee94ee","ab8f08b2b464dc84793bcf26c35af53a5b63e74340f29de42c26debdc60bc235","4e93e9ba37a3b7ab4cccd3a728834eba2cd34d117dbfba16b1bc29e8badbf938","5098d566e4bfa716483882fac2eec7bb67c971086666cf4719e48634fd34f9b8","11304f15ac2808fbb88414707a86a965a915cd4b48e591f1e8ab7a631e9d753a","fbd1dec42c73c45a3559dc7ebfa0f572a9d1492e7bf2b8766efde82146be8eec","04652ba486d2ed25912eaa63d3dd8cc083b7a7d6513aec7164f59cf009a0a9c5","93d11a02a6695ecd2d0eaab9c13f9ab402fa57d0b9957d5cce0a90a4430b1812","31b6ef989794d75fe1cbc0677e23b71f9e754c1502ca15151ba1916364867540","9d46c47186ef56debd299e71ae32977627b194385bed3a69942d3bf59f245902","3f67678077aaa041e0db6d5a9b6b46a80b3b8384779aa371386599a68035c025","0a01ed0b79301a0a1d6dd3317987ee0641e86280c6b4c34fd38c17db4675a067","16ffc5e4e2c61135ae4eb6b8dc887051f6f99abb021529f1ad61a2269265eed5","6e35e29760bd5de8e5e2d803a40fd1430751d579e93c71765b7bdcef17af963f","ccbd6c967c62351926169685074428604262114119a0fadc442e2d506bff4017","1f3f2e6a58fa808a7c54db544ae9c5d9189b571d752ed6c54d2b4509ee795a5d","69127f3eda2ebefacf67d3776ffe466e16a46a88d7a32e7787b557216f04c161","b844562fdf25214a33ed49b56a357d4ca65d95f9a6eff4f5b7066191464ffcfd","4502eb8af6444ceea39e084e1bf73f9bed27f886c6ac063bca5d79901283c04f","3e36ea2cb8bab52f8edb58632b6e2a1c44f310c6df4363486181e68f85b31a32","8ec140db08abfe944fb235a120b35a6e8b6706025483173b3a0c01f058b196e7","89ba7d9da91e101f35d49f55519cf7991b1fc4fa3b024d91d082ce6a6df5f23d","dac8f905d06607c6f84d18b2d04cbd1cb9a00acdeec0e90dbfcbaa6281a4a151","8a3d1db48de10bcc4673ec9751b1a7a48ae6600805d8db4c8dde46a2152ed0a8","4cb7fd69a6617c9946c76d4f789805c265b0dd58633eef4ec43d192056e0f368","0a1e7b30cbdd0e1919843a297943ef7be529647cfba7eda61b2e9612ea447692","29958389ee17d125b90ca2dffedc44b04033f2016985f164168e06d078d72231","9439ffc2dde7dd0055f29d9b4ddc6d0eafd1d719a7dc0e0cf14b39cab8a4c1cb","0628d59d6d8084a8b1defb70075bd2a9a62819fd85eefdaf122e4eba1b830342","07e1e46117d0dc91ff944cc05fe33e4a10399c9f963b17775027fb9652080568","e20ea2b13ba5e4c6c77fa2a20558211bb69bb0c3226bf436801c4f08bd7fec83","ce5ffe95ce1c07016311eaf191ea439437f28f2f848d992f3ef86d02bc112849","fb019b9056dbc5be2abb88c61d1f24ca322ae615df1db5d52906f5b154500cfd","6d613a1d549a46d76c89d53f6d794d8009b569f971d9b27f7bd2389334bdf448","4d1a185f12e4ff59831b2ebf45bf0500d0831c2bb1635b9ae41aee7f3bfae918","cc957354aa3c94c9961ebf46282cfde1e81d107fc5785a61f62c67f1dd3ac2eb","93de1c6dab503f053efe8d304cb522bb3a89feab8c98f307a674a4fae04773e9","fc72135da24040641388fb5f2c2a7a99aa5b962c0fa125bd96fabeec63dd2e63","5426e62886b7be7806312d31a00e8f7dccd6fe63ba9bbefe99ee2eab29cc48a3","9122ed7070e054b73ebab37c2373a196def2d90e7d1a9a7fcd9d46b0e51fae78","a69c09dbea52352f479d3e7ac949fde3d17b195abe90b045d619f747b38d6d1a","089e1f8603cbc35ab977c8dcc662eb754b82fca32ed1dfb16bd682726c2d5432",{"version":"77f0b5c6a193a699c9f7d7fb0578e64e562d271afa740783665d2a827104a873","affectsGlobalScope":true},"21a167fec8f933752fb8157f06d28fab6817af3ad9b0bdb1908a10762391eab9",{"version":"3e4624c306340ad303cc536a07004e81336c3f088308a9e4a9f4c957a3cda2fd","affectsGlobalScope":true},"0c0cee62cb619aed81133b904f644515ba3064487002a7da83fd8aa07b1b4abd","5a94487653355b56018122d92392beb2e5f4a6c63ba5cef83bbe1c99775ef713",{"version":"d5135ad93b33adcce80b18f8065087934cdc1730d63db58562edcf017e1aad9b","affectsGlobalScope":true},"82408ed3e959ddc60d3e9904481b5a8dc16469928257af22a3f7d1a3bc7fd8c4","025fc13211ed47d2798269017af3ec869122a050d5431a6ad3c1997900e65c58","bb9c4ffa5e6290c6980b63c815cdd1625876dadb2efaf77edbe82984be93e55e","75ecef44f126e2ae018b4abbd85b6e8a2e2ba1638ebec56cc64274643ce3567b","f30bb836526d930a74593f7b0f5c1c46d10856415a8f69e5e2fc3db80371e362","14b5aa23c5d0ae1907bc696ac7b6915d88f7d85799cc0dc2dcf98fbce2c5a67c","5c439dafdc09abe4d6c260a96b822fa0ba5be7203c71a63ab1f1423cd9e838ea",{"version":"249a2b90439cdfd51709539fbfa4dfe0791cbae6efce1e9b327ba8f8cd703f49","affectsGlobalScope":true},"2f60ac046e587e917d739f1edc77540eb0ec34f83090dae4ebd5f96c1c9578d4","a9b6b0f7b1e30359283b131ba6d1c51ee2d3601a2f12e1623141e6a1a60c92a5","aeee0090b38de0dd47ca9a79ad5c2d156e3e09d92306719b0b45a3e96098e564","7bac475dcdd9f7e4e9da934d32c305bc889c4ce3c8ac0ef45a93a8d670fff607","09416dd69576b03a3f485adf329a02f043e4a481e060ef5b208194e488d31fd9","8acf99b1c8682276a63ea5bb68433782715892726b97e4604a415e4e56bce41c",{"version":"e8b18c6385ff784228a6f369694fcf1a6b475355ba89090a88de13587a9391d5","affectsGlobalScope":true},"3b145a2351f5cf16abf999c8d5f4481c74dffdc54ec1e9a89992e2622e1226c5","a907bf91df26df2400858ef75f749498fb5cf00062bf90a737ac3949cc07978d","d270fd4b565eda11a0a737c181892316b7a1ace06c7988d0246219c3df11db06","4275d5f964e7fc7afc18538e26b3748c207dd772998346d17f409749aa1f3a63",{"version":"59a638a504490fecaacf0020b9814b6abee37edb66047eb1ab9f7c2274bf1da0","affectsGlobalScope":true},"5153a2fd150e46ce57bb3f8db1318d33f6ad3261ed70ceeff92281c0608c74a3","d1a78a3c5708807e8de3e399f91df4797c62e44b02195eefc2209b2e713e54ee","8c4c1a64db28930732033c31418f817dcb9d09d706766707ae6d38f23faf0c53","25846d43937c672bab7e8195f3d881f93495df712ee901860effc109918938cc","12a70315c8281e46d65696086dd25827408e967b305a22276ae2779fe519e0fe","1b952304137851e45bc009785de89ada562d9376177c97e37702e39e60c2f1ff",{"version":"806ef4cac3b3d9fa4a48d849c8e084d7c72fcd7b16d76e06049a9ed742ff79c0","affectsGlobalScope":true},"44b8b584a338b190a59f4f6929d072431950c7bd92ec2694821c11bce180c8a5","23b89798789dffbd437c0c423f5d02d11f9736aea73d6abf16db4f812ff36eda","29d613c3964ea75b2b4e0d17098245c34529282e9cc72b7e4eeb2a7b12c27cb7",{"version":"970a90f76d4d219ad60819d61f5994514087ba94c985647a3474a5a3d12714ed","affectsGlobalScope":true},"664d8f2d59164f2e08c543981453893bc7e003e4dfd29651ce09db13e9457980","a381f079c4804442f179d742fdb2e495fe28d67a47cac673485f75ae2e77aeca","3c13ef48634e7b5012fcf7e8fce7496352c2d779a7201389ca96a2a81ee4314d","5d0a25ec910fa36595f85a67ac992d7a53dd4064a1ba6aea1c9f14ab73a023f2",{"version":"bfe39beb986d2a2e512c091cbe924f1c415bc65de54de0e2f6a0dc6f84c183d9","affectsGlobalScope":true},"2af17363f8a062e3a8cd1b26030af0058b3f86e783f4fc6aa9f57247f240ebaa","06d7c42d256f0ce6afe1b2b6cfbc97ab391f29dadb00dd0ae8e8f23f5bc916c3","dfe08140492cdc135fb7fd9c4a652c05207b61a436906079b87da1d3111314bf","e59a892d87e72733e2a9ca21611b9beb52977be2696c7ba4b216cbbb9a48f5aa","8a300fa9b698845a1f9c41ecbe2c5966634582a8e2020d51abcace9b55aa959e",{"version":"ab9b9a36e5284fd8d3bf2f7d5fcbc60052f25f27e4d20954782099282c60d23e","affectsGlobalScope":true},"82fc37849846a3a0264047621d5beb6ce2ddeb2f83bdee2c79523af3c3282d97","cdac7e46e615e1fdcca7c3a2aab2fbd19085443048733cf239a090f7a17efa27","fec943fdb3275eb6e006b35e04a8e2e99e9adf3f4b969ddf15315ac7575a93e4","cab425b5559edac18327eb2c3c0f47e7e9f71b667290b7689faafd28aac69eae","3cfb0cb51cc2c2e1b313d7c4df04dbf7e5bda0a133c6b309bf6af77cf614b971","f992cd6cc0bcbaa4e6c810468c90f2d8595f8c6c3cf050c806397d3de8585562","487efbdd4279fc5fc28c44d5ed9ee8fa657b3cd6ee28577ca98fc8222aade7a8","f00c5e026830a9e77de992cdb628b3562ee08ad907227c78cdbdff1af2b54ac2","3ebae8c00411116a66fca65b08228ea0cf0b72724701f9b854442100aab55aba","8b06ac3faeacb8484d84ddb44571d8f410697f98d7bfa86c0fda60373a9f5215","7eb06594824ada538b1d8b48c3925a83e7db792f47a081a62cf3e5c4e23cf0ee","f5638f7c2f12a9a1a57b5c41b3c1ea7db3876c003bab68e6a57afd6bcc169af0",{"version":"09cc898e69f966c1a00290af83dbbfd04224c8828bf8518645c0556fceec5f44","affectsGlobalScope":true},"fc37aca06f6b8b296c42412a2e75ab53d30cd1fa8a340a3bb328a723fd678377","5f2c582b9ef260cb9559a64221b38606378c1fabe17694592cdfe5975a6d7efa","cc256fd958b33576ed32c7338c64adb0d08fc0c2c6525010202fab83f32745da","fd20dfa2434a61a87e3fa9450f9de2ed2c365ea43b17b34ac6616d90d9681381","389303117a81e90897689e7adb4b53a062e68a6fe4067088fae9552907aa28c3",{"version":"d4c4fe14b23180acf25e4a68dc3bb9e5c38233dd3de12a4ab9569e636090ac9b","affectsGlobalScope":true},"75bdc1b420f0ffc6cc6fd0b6694d89f5072bf755b4e6c7e65a2fda797ca0bb8a","f3e604694b624fa3f83f6684185452992088f5efb2cf136b62474aa106d6f1b6","96d14f21b7652903852eef49379d04dbda28c16ed36468f8c9fa08f7c14c9538","49afdedca00d22b171678e3cf9c47b7e0c1846fd4905a01d68f0145eb90add94","79583acf7af1577301a0f1aa67113806c919b648db16e0a7a46effe6b955d2ad","dffb72d000fcff088719593c507e7c1868d5a8bf0e8e7cd5d4a517ccf7d168b0","8841e2aa774b89bd23302dede20663306dc1b9902431ac64b24be8b8d0e3f649","209e814e8e71aec74f69686a9506dd7610b97ab59dcee9446266446f72a76d05","6fa0008bf91a4cc9c8963bace4bba0bd6865cbfa29c3e3ccc461155660fb113a","2b8264b2fefd7367e0f20e2c04eed5d3038831fe00f5efbc110ff0131aab899b","a73a445c1e0a6d0f8b48e8eb22dc9d647896783a7f8991cbbc31c0d94bf1f5a2","f1d8b21cdf08726021c8cce0cd6159486236cf1d633eeabbc435b5b2e5869c2e","3dce33e7eb25594863b8e615f14a45ab98190d85953436750644212d8a18c066","33875993d74ec1de26cd3f0899f53b70e312dc36e9ee50f5024f85dbe1055f33","b0d10e46cfe3f6c476b69af02eaa38e4ccc7430221ce3109ae84bb9fb8282298","b4358a89fcd9c579f84a6c68e2ce44ca91b07e4db3f8f403c2b7a72c1a1e04b6","70e9a18da08294f75bf23e46c7d69e67634c0765d355887b9b41f0d959e1426e","105b9a2234dcb06ae922f2cd8297201136d416503ff7d16c72bfc8791e9895c1"],"options":{"declaration":true,"esModuleInterop":true,"jsx":1,"module":99,"outDir":"./","skipLibCheck":true,"sourceMap":true,"strict":true,"target":1},"fileIdsList":[[158,180,181,182],[109,110,111,158,180,181,182],[158,164,180,181,182],[129,132,157,158,164,166,167,168,180,181,182],[108,158,170,180,181,182],[130,158,164,180,181,182],[158,173,180,181,182],[158,174,180,181,182],[129,158,160,164,178,179,181,182],[158,180,181],[158,180,182],[129,158,164,180,181,182],[108,158,171,180,181,182,187],[108,129,158,164,180,181,182,186],[113,158,180,181,182],[117,158,180,181,182],[118,123,158,180,181,182],[119,129,130,137,146,157,158,180,181,182],[119,120,129,137,158,180,181,182],[121,158,180,181,182],[122,123,130,138,158,180,181,182],[123,146,154,158,180,181,182],[124,126,129,137,158,180,181,182],[125,158,180,181,182],[126,127,158,180,181,182],[128,129,158,180,181,182],[129,158,180,181,182],[129,130,131,146,157,158,180,181,182],[129,130,131,146,149,158,180,181,182],[115,158,180,181,182],[132,137,146,157,158,180,181,182],[129,130,132,133,137,146,154,157,158,180,181,182],[132,134,146,154,157,158,180,181,182],[113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,180,181,182],[129,135,158,180,181,182],[136,157,158,180,181,182],[126,129,137,146,158,180,181,182],[138,158,180,181,182],[139,158,180,181,182],[117,140,158,180,181,182],[115,141,156,158,180,181,182],[142,158,180,181,182],[143,158,180,181,182],[129,144,158,180,181,182],[144,145,158,160,180,181,182],[129,146,147,148,149,158,180,181,182],[146,148,158,180,181,182],[146,147,158,180,181,182],[149,158,180,181,182],[150,158,180,181,182],[129,152,153,158,180,181,182],[152,153,158,180,181,182],[123,137,146,154,158,180,181,182],[155,158,180,181,182],[137,156,158,180,181,182],[118,132,143,157,158,180,181,182],[123,158,180,181,182],[146,158,159,180,181,182],[158,160,180,181,182],[158,161,180,181,182],[115,118,123,129,131,140,146,157,158,160,180,181,182],[146,158,162,180,181,182],[158,177,180,181,182],[132,146,158,164,180,181,182],[146,158,164,180,181,182],[129,132,134,146,154,157,158,162,164,180,181,182],[158,180,181,182,199],[55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,84,85,86,87,88,89,103,158,180,181,182],[83,158,180,181,182],[80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,129,158,180,181,182],[132,134,158,180,181,182]],"referencedMap":[[108,1],[112,2],[109,1],[110,1],[111,1],[165,3],[169,4],[171,5],[172,6],[167,1],[173,1],[174,7],[175,8],[176,1],[180,9],[182,10],[181,11],[183,1],[184,1],[185,1],[166,12],[170,1],[186,1],[188,13],[187,14],[189,1],[190,1],[113,15],[114,15],[117,16],[118,17],[119,18],[120,19],[121,20],[122,21],[123,22],[124,23],[125,24],[126,25],[127,25],[128,26],[129,27],[130,28],[131,29],[116,30],[163,1],[132,31],[133,32],[134,33],[164,34],[135,35],[136,36],[137,37],[138,38],[139,39],[140,40],[141,41],[142,42],[143,43],[144,44],[145,45],[146,46],[148,47],[147,48],[149,49],[150,50],[151,1],[152,51],[153,52],[154,53],[155,54],[156,55],[157,56],[158,57],[159,58],[160,59],[161,60],[115,61],[162,62],[191,1],[192,1],[178,63],[177,1],[193,3],[194,1],[168,64],[195,3],[196,65],[197,1],[179,1],[198,66],[199,1],[200,67],[11,1],[12,1],[14,1],[13,1],[2,1],[15,1],[16,1],[17,1],[18,1],[19,1],[20,1],[21,1],[22,1],[3,1],[4,1],[26,1],[23,1],[24,1],[25,1],[27,1],[28,1],[29,1],[5,1],[30,1],[31,1],[32,1],[33,1],[6,1],[34,1],[35,1],[36,1],[37,1],[7,1],[38,1],[43,1],[44,1],[39,1],[40,1],[41,1],[42,1],[8,1],[48,1],[45,1],[46,1],[47,1],[49,1],[9,1],[50,1],[51,1],[52,1],[53,1],[1,1],[10,1],[54,1],[71,1],[72,1],[73,1],[76,1],[77,1],[78,1],[79,1],[104,68],[102,1],[82,1],[84,69],[81,1],[88,1],[86,1],[87,1],[89,69],[85,1],[80,1],[105,1],[106,1],[103,70],[97,1],[98,1],[94,1],[95,1],[96,1],[90,1],[100,1],[91,1],[99,1],[92,1],[93,1],[101,1],[83,1],[75,1],[74,71],[64,1],[67,1],[66,1],[68,1],[69,1],[70,1],[65,1],[61,1],[107,1],[55,1],[59,1],[56,57],[57,57],[63,1],[58,1],[60,1],[62,1]],"exportedModulesMap":[[108,1],[112,2],[109,1],[110,1],[111,1],[165,3],[169,4],[171,5],[172,6],[167,1],[173,1],[174,7],[175,8],[176,1],[180,9],[182,10],[181,11],[183,1],[184,1],[185,1],[166,12],[170,1],[186,1],[188,13],[187,14],[189,1],[190,1],[113,15],[114,15],[117,16],[118,17],[119,18],[120,19],[121,20],[122,21],[123,22],[124,23],[125,24],[126,25],[127,25],[128,26],[129,27],[130,28],[131,29],[116,30],[163,1],[132,31],[133,32],[134,33],[164,34],[135,35],[136,36],[137,37],[138,38],[139,39],[140,40],[141,41],[142,42],[143,43],[144,44],[145,45],[146,46],[148,47],[147,48],[149,49],[150,50],[151,1],[152,51],[153,52],[154,53],[155,54],[156,55],[157,56],[158,57],[159,58],[160,59],[161,60],[115,61],[162,62],[191,1],[192,1],[178,63],[177,1],[193,3],[194,1],[168,64],[195,3],[196,65],[197,1],[179,1],[198,66],[199,1],[200,67],[11,1],[12,1],[14,1],[13,1],[2,1],[15,1],[16,1],[17,1],[18,1],[19,1],[20,1],[21,1],[22,1],[3,1],[4,1],[26,1],[23,1],[24,1],[25,1],[27,1],[28,1],[29,1],[5,1],[30,1],[31,1],[32,1],[33,1],[6,1],[34,1],[35,1],[36,1],[37,1],[7,1],[38,1],[43,1],[44,1],[39,1],[40,1],[41,1],[42,1],[8,1],[48,1],[45,1],[46,1],[47,1],[49,1],[9,1],[50,1],[51,1],[52,1],[53,1],[1,1],[10,1],[54,1],[71,1],[72,1],[73,1],[76,1],[77,1],[78,1],[79,1],[104,68],[102,1],[82,1],[84,69],[81,1],[88,1],[86,1],[87,1],[89,69],[85,1],[80,1],[105,1],[106,1],[103,70],[97,1],[98,1],[94,1],[95,1],[96,1],[90,1],[100,1],[91,1],[99,1],[92,1],[93,1],[101,1],[83,1],[75,1],[74,71],[64,1],[67,1],[66,1],[68,1],[69,1],[70,1],[65,1],[61,1],[107,1],[55,1],[59,1],[56,57],[57,57],[63,1],[58,1],[60,1],[62,1]],"semanticDiagnosticsPerFile":[108,112,109,110,111,165,169,171,172,167,173,174,175,176,180,182,181,183,184,185,166,170,186,188,187,189,190,113,114,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,116,163,132,133,134,164,135,136,137,138,139,140,141,142,143,144,145,146,148,147,149,150,151,152,153,154,155,156,157,158,159,160,161,115,162,191,192,178,177,193,194,168,195,196,197,179,198,199,200,11,12,14,13,2,15,16,17,18,19,20,21,22,3,4,26,23,24,25,27,28,29,5,30,31,32,33,6,34,35,36,37,7,38,43,44,39,40,41,42,8,48,45,46,47,49,9,50,51,52,53,1,10,54,[71,[{"file":"../lib/adapters-base/networkadapter.ts","start":116,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/adapters-base/networkadapter.ts","start":658,"length":8,"messageText":"Parameter 'meAsPeer' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/adapters-base/networkadapter.ts","start":1212,"length":9,"messageText":"Parameter 'signature' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/adapters-base/networkadapter.ts","start":2092,"length":8,"messageText":"Parameter 'meAsPeer' implicitly has an 'any' type.","category":1,"code":7006}]],[72,[{"file":"../lib/adapters-base/storageadapter.ts","start":23,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],[73,[{"file":"../lib/adapters-base/useradapter.ts","start":41,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],76,[77,[{"file":"../lib/crdt/countercrdt.ts","start":36,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],[78,[{"file":"../lib/crdt/listcrdt.ts","start":36,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],[79,[{"file":"../lib/crdt/mapcrdt.ts","start":35,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],104,[102,[{"file":"../lib/logger.ts","start":29,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],[82,[{"file":"../lib/messagehandlers/handlecrdtget.ts","start":55,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/messagehandlers/handlecrdtget.ts","start":226,"length":4,"messageText":"Parameter 'data' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handlecrdtget.ts","start":658,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[84,[{"file":"../lib/messagehandlers/handlecrdtput.ts","start":220,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/messagehandlers/handlecrdtput.ts","start":1017,"length":7,"messageText":"Parameter 'oldData' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handlecrdtput.ts","start":2917,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handlecrdtput.ts","start":3702,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handlecrdtput.ts","start":3832,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handlecrdtput.ts","start":4061,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[81,[{"file":"../lib/messagehandlers/handlefunction.ts","start":63,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/messagehandlers/handlefunction.ts","start":383,"length":3,"messageText":"Parameter 'ret' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handlefunction.ts","start":703,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[88,[{"file":"../lib/messagehandlers/handleget.ts","start":47,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/messagehandlers/handleget.ts","start":210,"length":4,"messageText":"Parameter 'data' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handleget.ts","start":634,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[86,[{"file":"../lib/messagehandlers/handleping.ts","start":61,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/messagehandlers/handleping.ts","start":305,"length":8,"messageText":"Parameter 'verified' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handleping.ts","start":530,"length":1,"messageText":"Parameter 'p' implicitly has an 'any' type.","category":1,"code":7006}]],[87,[{"file":"../lib/messagehandlers/handlepong.ts","start":48,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/messagehandlers/handlepong.ts","start":280,"length":4,"messageText":"Parameter 'peer' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handlepong.ts","start":427,"length":1,"messageText":"Parameter 'p' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handlepong.ts","start":575,"length":8,"messageText":"Parameter 'verified' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handlepong.ts","start":824,"length":1,"messageText":"Parameter 'p' implicitly has an 'any' type.","category":1,"code":7006}]],[89,[{"file":"../lib/messagehandlers/handleput.ts","start":49,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/messagehandlers/handleput.ts","start":815,"length":7,"messageText":"Parameter 'oldData' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handleput.ts","start":1170,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handleput.ts","start":1585,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handleput.ts","start":1794,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[85,[{"file":"../lib/messagehandlers/handlequery.ts","start":54,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/messagehandlers/handlequery.ts","start":223,"length":4,"messageText":"Parameter 'keys' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handlequery.ts","start":420,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[80,[{"file":"../lib/messagehandlers/handlesubscribe.ts","start":53,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/messagehandlers/handlesubscribe.ts","start":354,"length":3,"messageText":"Parameter 'msg' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handlesubscribe.ts","start":835,"length":4,"messageText":"Parameter 'data' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/messagehandlers/handlesubscribe.ts","start":1150,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[105,[{"file":"../lib/server.ts","start":23,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],106,[103,[{"file":"../lib/tooldb.ts","start":247,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/tooldb.ts","start":8291,"length":3,"messageText":"Parameter 'val' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldb.ts","start":8403,"length":1,"messageText":"Parameter 'a' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldb.ts","start":8614,"length":2,"messageText":"Parameter '_e' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldb.ts","start":8684,"length":1,"messageText":"Parameter 'a' implicitly has an 'any' type.","category":1,"code":7006}]],[97,[{"file":"../lib/tooldbanonsignin.ts","start":23,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],[98,[{"file":"../lib/tooldbclientonmessage.ts","start":38,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],[94,[{"file":"../lib/tooldbcrdtget.ts","start":61,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/tooldbcrdtget.ts","start":1137,"length":4,"messageText":"Parameter 'data' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbcrdtget.ts","start":1424,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbcrdtget.ts","start":1500,"length":3,"messageText":"Parameter 'msg' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbcrdtget.ts","start":1762,"length":4,"messageText":"Parameter 'data' implicitly has an 'any' type.","category":1,"code":7006}]],[95,[{"file":"../lib/tooldbcrdtput.ts","start":112,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/tooldbcrdtput.ts","start":1358,"length":4,"messageText":"Binding element 'hash' implicitly has an 'any' type.","category":1,"code":7031},{"file":"../lib/tooldbcrdtput.ts","start":1364,"length":5,"messageText":"Binding element 'nonce' implicitly has an 'any' type.","category":1,"code":7031},{"file":"../lib/tooldbcrdtput.ts","start":1425,"length":9,"messageText":"Parameter 'signature' implicitly has an 'any' type.","category":1,"code":7006}]],[96,[{"file":"../lib/tooldbfunction.ts","start":109,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/tooldbfunction.ts","start":867,"length":3,"messageText":"Parameter 'msg' implicitly has an 'any' type.","category":1,"code":7006}]],[90,[{"file":"../lib/tooldbget.ts","start":35,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/tooldbget.ts","start":1054,"length":4,"messageText":"Parameter 'data' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbget.ts","start":1298,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbget.ts","start":1399,"length":3,"messageText":"Parameter 'msg' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbget.ts","start":1624,"length":4,"messageText":"Parameter 'data' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbget.ts","start":1955,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[100,[{"file":"../lib/tooldbkeyssignin.ts","start":37,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/tooldbkeyssignin.ts","start":313,"length":10,"messageText":"Parameter 'newAccount' implicitly has an 'any' type.","category":1,"code":7006}]],[91,[{"file":"../lib/tooldbput.ts","start":95,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/tooldbput.ts","start":1258,"length":4,"messageText":"Binding element 'hash' implicitly has an 'any' type.","category":1,"code":7031},{"file":"../lib/tooldbput.ts","start":1264,"length":5,"messageText":"Binding element 'nonce' implicitly has an 'any' type.","category":1,"code":7031},{"file":"../lib/tooldbput.ts","start":1325,"length":9,"messageText":"Parameter 'signature' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbput.ts","start":2245,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[99,[{"file":"../lib/tooldbquerykeys.ts","start":41,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/tooldbquerykeys.ts","start":947,"length":9,"messageText":"Parameter 'localKeys' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbquerykeys.ts","start":1128,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbquerykeys.ts","start":1350,"length":3,"messageText":"Parameter 'msg' implicitly has an 'any' type.","category":1,"code":7006}]],[92,[{"file":"../lib/tooldbsignin.ts","start":45,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/tooldbsignin.ts","start":306,"length":5,"messageText":"Parameter '_user' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbsignin.ts","start":516,"length":10,"messageText":"Parameter 'newAccount' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbsignin.ts","start":732,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbsignin.ts","start":844,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[93,[{"file":"../lib/tooldbsignup.ts","start":106,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/tooldbsignup.ts","start":398,"length":4,"messageText":"Parameter 'data' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbsignup.ts","start":560,"length":8,"messageText":"Parameter 'userData' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbsignup.ts","start":830,"length":4,"messageText":"Binding element 'hash' implicitly has an 'any' type.","category":1,"code":7031},{"file":"../lib/tooldbsignup.ts","start":836,"length":5,"messageText":"Binding element 'nonce' implicitly has an 'any' type.","category":1,"code":7031},{"file":"../lib/tooldbsignup.ts","start":896,"length":9,"messageText":"Parameter 'signature' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbsignup.ts","start":1758,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[101,[{"file":"../lib/tooldbsubscribe.ts","start":35,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/tooldbsubscribe.ts","start":1010,"length":4,"messageText":"Parameter 'data' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbsubscribe.ts","start":1220,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[83,[{"file":"../lib/tooldbverificationwrapper.ts","start":55,"length":3,"messageText":"Cannot find module '.'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/tooldbverificationwrapper.ts","start":348,"length":8,"messageText":"Parameter 'verified' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbverificationwrapper.ts","start":460,"length":8,"messageText":"Parameter 'listener' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbverificationwrapper.ts","start":764,"length":4,"messageText":"Parameter 'prev' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbverificationwrapper.ts","start":974,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006},{"file":"../lib/tooldbverificationwrapper.ts","start":1447,"length":1,"messageText":"Parameter 'e' implicitly has an 'any' type.","category":1,"code":7006}]],[75,[{"file":"../lib/types/message.ts","start":99,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],[74,[{"file":"../lib/types/tooldb.ts","start":214,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],64,67,66,68,69,[70,[{"file":"../lib/utils/encoding/hextouint8.ts","start":33,"length":7,"messageText":"Cannot find module '../..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],65,[61,[{"file":"../lib/utils/getpeersignature.ts","start":42,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],107,[55,[{"file":"../lib/utils/proofofwork.ts","start":23,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]],59,56,57,63,58,[60,[{"file":"../lib/utils/verifymessage.ts","start":63,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792},{"file":"../lib/utils/verifymessage.ts","start":1481,"length":4,"messageText":"Parameter 'data' implicitly has an 'any' type.","category":1,"code":7006}]],[62,[{"file":"../lib/utils/verifypeer.ts","start":37,"length":4,"messageText":"Cannot find module '..'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?","category":1,"code":2792}]]],"affectedFilesPendingEmit":[[108,1],[112,1],[109,1],[110,1],[111,1],[165,1],[169,1],[171,1],[172,1],[167,1],[173,1],[174,1],[175,1],[176,1],[180,1],[182,1],[181,1],[183,1],[184,1],[185,1],[166,1],[170,1],[186,1],[188,1],[187,1],[189,1],[190,1],[113,1],[114,1],[117,1],[118,1],[119,1],[120,1],[121,1],[122,1],[123,1],[124,1],[125,1],[126,1],[127,1],[128,1],[129,1],[130,1],[131,1],[116,1],[163,1],[132,1],[133,1],[134,1],[164,1],[135,1],[136,1],[137,1],[138,1],[139,1],[140,1],[141,1],[142,1],[143,1],[144,1],[145,1],[146,1],[148,1],[147,1],[149,1],[150,1],[151,1],[152,1],[153,1],[154,1],[155,1],[156,1],[157,1],[158,1],[159,1],[160,1],[161,1],[115,1],[162,1],[191,1],[192,1],[178,1],[177,1],[193,1],[194,1],[168,1],[195,1],[196,1],[197,1],[179,1],[198,1],[199,1],[200,1],[2,1],[3,1],[4,1],[5,1],[6,1],[7,1],[8,1],[9,1],[10,1],[71,1],[72,1],[73,1],[76,1],[77,1],[78,1],[79,1],[104,1],[102,1],[82,1],[84,1],[81,1],[88,1],[86,1],[87,1],[89,1],[85,1],[80,1],[105,1],[106,1],[103,1],[97,1],[98,1],[94,1],[95,1],[96,1],[90,1],[100,1],[91,1],[99,1],[92,1],[93,1],[101,1],[83,1],[75,1],[74,1],[64,1],[67,1],[66,1],[68,1],[69,1],[70,1],[65,1],[61,1],[107,1],[55,1],[59,1],[56,1],[57,1],[63,1],[58,1],[60,1],[62,1]]},"version":"4.7.4"}
|
package/dist/types/tooldb.d.ts
CHANGED
|
@@ -37,9 +37,10 @@ export interface ToolDbOptions {
|
|
|
37
37
|
*/
|
|
38
38
|
wait: number;
|
|
39
39
|
/**
|
|
40
|
-
*
|
|
40
|
+
* Proof of work difficulty (number of leading zeroes required).
|
|
41
|
+
* Set to null to bypass POW calculations entirely (useful for testing/CI).
|
|
41
42
|
*/
|
|
42
|
-
pow: number;
|
|
43
|
+
pow: number | null;
|
|
43
44
|
/**
|
|
44
45
|
* Whether we are a server or not
|
|
45
46
|
*/
|
|
@@ -1,12 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
function arrayBufferToString(arr) {
|
|
4
|
-
var
|
|
5
|
-
|
|
6
|
-
for (var i = 0; i < byteArray.byteLength; i += 1) {
|
|
7
|
-
byteString += String.fromCodePoint(byteArray[i]);
|
|
8
|
-
}
|
|
9
|
-
return byteString;
|
|
4
|
+
var decoder = new TextDecoder();
|
|
5
|
+
return decoder.decode(arr);
|
|
10
6
|
}
|
|
11
7
|
exports.default = arrayBufferToString;
|
|
12
8
|
//# sourceMappingURL=arrayBufferToString.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"arrayBufferToString.js","sourceRoot":"","sources":["../../../lib/utils/encoding/arrayBufferToString.ts"],"names":[],"mappings":";;AAAA,SAAwB,mBAAmB,CAAC,GAAgB;IAC1D,IAAM,
|
|
1
|
+
{"version":3,"file":"arrayBufferToString.js","sourceRoot":"","sources":["../../../lib/utils/encoding/arrayBufferToString.ts"],"names":[],"mappings":";;AAAA,SAAwB,mBAAmB,CAAC,GAAgB;IAC1D,IAAM,OAAO,GAAG,IAAI,WAAW,EAAE,CAAC;IAClC,OAAO,OAAO,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;AAC7B,CAAC;AAHD,sCAGC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function base64ToUint8(based: string): Uint8Array;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
var fromBase64_1 = __importDefault(require("./fromBase64"));
|
|
7
|
+
function base64ToUint8(based) {
|
|
8
|
+
var str = (0, fromBase64_1.default)(based);
|
|
9
|
+
var buf = new ArrayBuffer(str.length);
|
|
10
|
+
var bufView = new Uint8Array(buf);
|
|
11
|
+
for (var i = 0, strLen = str.length; i < strLen; i += 1) {
|
|
12
|
+
bufView[i] = str.charCodeAt(i);
|
|
13
|
+
}
|
|
14
|
+
return bufView;
|
|
15
|
+
}
|
|
16
|
+
exports.default = base64ToUint8;
|
|
17
|
+
//# sourceMappingURL=base64ToUint8.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"base64ToUint8.js","sourceRoot":"","sources":["../../../lib/utils/encoding/base64ToUint8.ts"],"names":[],"mappings":";;;;;AAAA,4DAAsC;AAEtC,SAAwB,aAAa,CAAC,KAAa;IACjD,IAAM,GAAG,GAAG,IAAA,oBAAU,EAAC,KAAK,CAAC,CAAC;IAE9B,IAAM,GAAG,GAAG,IAAI,WAAW,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACxC,IAAM,OAAO,GAAG,IAAI,UAAU,CAAC,GAAG,CAAC,CAAC;IACpC,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,MAAM,GAAG,GAAG,CAAC,MAAM,EAAE,CAAC,GAAG,MAAM,EAAE,CAAC,IAAI,CAAC,EAAE;QACvD,OAAO,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;KAChC;IACD,OAAO,OAAO,CAAC;AACjB,CAAC;AATD,gCASC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function fromBase64(str: string): string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fromBase64.js","sourceRoot":"","sources":["../../../lib/utils/encoding/fromBase64.ts"],"names":[],"mappings":";;AAAA,SAAwB,UAAU,CAAC,GAAW;IAC5C,OAAO,kBAAkB,CAAC,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;AACtD,CAAC;AAFD,6BAEC"}
|
|
@@ -1,12 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
function stringToArrayBuffer(str) {
|
|
4
|
-
var
|
|
5
|
-
|
|
6
|
-
for (var i = 0, strLen = str.length; i < strLen; i += 1) {
|
|
7
|
-
bufView[i] = str.charCodeAt(i);
|
|
8
|
-
}
|
|
9
|
-
return buf;
|
|
4
|
+
var encoder = new TextEncoder();
|
|
5
|
+
return encoder.encode(str).buffer;
|
|
10
6
|
}
|
|
11
7
|
exports.default = stringToArrayBuffer;
|
|
12
8
|
//# sourceMappingURL=stringToArrayBuffer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"stringToArrayBuffer.js","sourceRoot":"","sources":["../../../lib/utils/encoding/stringToArrayBuffer.ts"],"names":[],"mappings":";;AAAA,SAAwB,mBAAmB,CAAC,GAAW;IACrD,IAAM,
|
|
1
|
+
{"version":3,"file":"stringToArrayBuffer.js","sourceRoot":"","sources":["../../../lib/utils/encoding/stringToArrayBuffer.ts"],"names":[],"mappings":";;AAAA,SAAwB,mBAAmB,CAAC,GAAW;IACrD,IAAM,OAAO,GAAG,IAAI,WAAW,EAAE,CAAC;IAClC,OAAO,OAAO,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,MAAM,CAAC;AACpC,CAAC;AAHD,sCAGC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function toBase64(str: string): string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toBase64.js","sourceRoot":"","sources":["../../../lib/utils/encoding/toBase64.ts"],"names":[],"mappings":";;AAAA,SAAwB,QAAQ,CAAC,GAAW;IAC1C,OAAO,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,kBAAkB,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;AACxD,CAAC;AAFD,2BAEC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function uint8ToBase64(byteArray: Uint8Array): string;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
var toBase64_1 = __importDefault(require("./toBase64"));
|
|
7
|
+
function uint8ToBase64(byteArray) {
|
|
8
|
+
var byteString = "";
|
|
9
|
+
for (var i = 0; i < byteArray.byteLength; i += 1) {
|
|
10
|
+
byteString += String.fromCodePoint(byteArray[i]);
|
|
11
|
+
}
|
|
12
|
+
return (0, toBase64_1.default)(byteString);
|
|
13
|
+
}
|
|
14
|
+
exports.default = uint8ToBase64;
|
|
15
|
+
//# sourceMappingURL=uint8ToBase64.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"uint8ToBase64.js","sourceRoot":"","sources":["../../../lib/utils/encoding/uint8ToBase64.ts"],"names":[],"mappings":";;;;;AAAA,wDAAkC;AAElC,SAAwB,aAAa,CAAC,SAAqB;IACzD,IAAI,UAAU,GAAG,EAAE,CAAC;IACpB,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,SAAS,CAAC,UAAU,EAAE,CAAC,IAAI,CAAC,EAAE;QAChD,UAAU,IAAI,MAAM,CAAC,aAAa,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;KAClD;IAED,OAAO,IAAA,kBAAQ,EAAC,UAAU,CAAC,CAAC;AAC9B,CAAC;AAPD,gCAOC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
var arrayBufferToHex_1 = __importDefault(require("./encoding/arrayBufferToHex"));
|
|
7
|
+
/**
|
|
8
|
+
* Generate a random 256-bit symmetric key for group encryption.
|
|
9
|
+
* Returns the key as a hex string for easy storage and transmission.
|
|
10
|
+
*/
|
|
11
|
+
function generateGroupKey() {
|
|
12
|
+
var key = crypto.getRandomValues(new Uint8Array(32));
|
|
13
|
+
return (0, arrayBufferToHex_1.default)(key.buffer);
|
|
14
|
+
}
|
|
15
|
+
exports.default = generateGroupKey;
|
|
16
|
+
//# sourceMappingURL=generateGroupKey.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"generateGroupKey.js","sourceRoot":"","sources":["../../lib/utils/generateGroupKey.ts"],"names":[],"mappings":";;;;;AAAA,iFAA2D;AAE3D;;;GAGG;AACH,SAAwB,gBAAgB;IACtC,IAAM,GAAG,GAAG,MAAM,CAAC,eAAe,CAAC,IAAI,UAAU,CAAC,EAAE,CAAC,CAAC,CAAC;IACvD,OAAO,IAAA,0BAAgB,EAAC,GAAG,CAAC,MAAM,CAAC,CAAC;AACtC,CAAC;AAHD,mCAGC"}
|
|
@@ -1,4 +1,11 @@
|
|
|
1
|
-
|
|
1
|
+
/**
|
|
2
|
+
* Calculates proof of work by finding a nonce that produces a hash
|
|
3
|
+
* with the required number of leading zeroes.
|
|
4
|
+
* @param value The value to hash
|
|
5
|
+
* @param difficulty Number of leading zeroes required. Pass null to skip POW entirely.
|
|
6
|
+
* @returns Promise with nonce and hash
|
|
7
|
+
*/
|
|
8
|
+
export default function proofOfWork(value: string, difficulty: number | null): Promise<{
|
|
2
9
|
nonce: number;
|
|
3
10
|
hash: string;
|
|
4
11
|
}>;
|
|
@@ -1,8 +1,22 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
var __1 = require("..");
|
|
4
|
+
/**
|
|
5
|
+
* Calculates proof of work by finding a nonce that produces a hash
|
|
6
|
+
* with the required number of leading zeroes.
|
|
7
|
+
* @param value The value to hash
|
|
8
|
+
* @param difficulty Number of leading zeroes required. Pass null to skip POW entirely.
|
|
9
|
+
* @returns Promise with nonce and hash
|
|
10
|
+
*/
|
|
4
11
|
function proofOfWork(value, difficulty) {
|
|
5
12
|
return new Promise(function (resolve) {
|
|
13
|
+
// When difficulty is null, skip POW calculation entirely
|
|
14
|
+
// Just return hash with nonce 0 (useful for testing/CI)
|
|
15
|
+
if (difficulty === null || difficulty === 0) {
|
|
16
|
+
var hash_1 = (0, __1.sha256)("".concat(value, "0"));
|
|
17
|
+
resolve({ nonce: 0, hash: hash_1 });
|
|
18
|
+
return;
|
|
19
|
+
}
|
|
6
20
|
var nonce = 0;
|
|
7
21
|
var hash = (0, __1.sha256)("".concat(value).concat(nonce));
|
|
8
22
|
while (hash.substring(0, difficulty) !== Array(difficulty + 1).join("0")) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"proofOfWork.js","sourceRoot":"","sources":["../../lib/utils/proofOfWork.ts"],"names":[],"mappings":";;AAAA,wBAA4B;AAE5B,SAAwB,WAAW,CACjC,KAAa,EACb,
|
|
1
|
+
{"version":3,"file":"proofOfWork.js","sourceRoot":"","sources":["../../lib/utils/proofOfWork.ts"],"names":[],"mappings":";;AAAA,wBAA4B;AAE5B;;;;;;GAMG;AACH,SAAwB,WAAW,CACjC,KAAa,EACb,UAAyB;IAEzB,OAAO,IAAI,OAAO,CAAC,UAAC,OAAO;QACzB,yDAAyD;QACzD,wDAAwD;QACxD,IAAI,UAAU,KAAK,IAAI,IAAI,UAAU,KAAK,CAAC,EAAE;YAC3C,IAAM,MAAI,GAAG,IAAA,UAAM,EAAC,UAAG,KAAK,MAAG,CAAC,CAAC;YACjC,OAAO,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,IAAI,QAAA,EAAE,CAAC,CAAC;YAC5B,OAAO;SACR;QAED,IAAI,KAAK,GAAG,CAAC,CAAC;QACd,IAAI,IAAI,GAAG,IAAA,UAAM,EAAC,UAAG,KAAK,SAAG,KAAK,CAAE,CAAC,CAAC;QACtC,OAAO,IAAI,CAAC,SAAS,CAAC,CAAC,EAAE,UAAU,CAAC,KAAK,KAAK,CAAC,UAAU,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE;YACxE,KAAK,IAAI,CAAC,CAAC;YACX,IAAI,GAAG,IAAA,UAAM,EAAC,UAAG,KAAK,SAAG,KAAK,CAAE,CAAC,CAAC;SACnC;QACD,OAAO,CAAC,EAAE,KAAK,OAAA,EAAE,IAAI,MAAA,EAAE,CAAC,CAAC;IAC3B,CAAC,CAAC,CAAC;AACL,CAAC;AArBD,8BAqBC"}
|
|
@@ -5,4 +5,4 @@ import { ToolDb, VerifyResult, VerificationData } from "..";
|
|
|
5
5
|
* @param pow amount of proof of work required, number of leading zeroes (default is 0/no pow)
|
|
6
6
|
* @returns boolean or undefined if the message type does not match
|
|
7
7
|
*/
|
|
8
|
-
export default function verifyMessage<T>(this: ToolDb, msg: Partial<VerificationData<T>>, pow?: number): Promise<VerifyResult>;
|
|
8
|
+
export default function verifyMessage<T>(this: ToolDb, msg: Partial<VerificationData<T>>, pow?: number | null): Promise<VerifyResult>;
|
|
@@ -98,8 +98,8 @@ function verifyMessage(msg, pow) {
|
|
|
98
98
|
// Verify hash and nonce (adjust zeroes for difficulty of the network)
|
|
99
99
|
// While this POW does not enforce security per-se, it does make it harder
|
|
100
100
|
// for attackers to spam the network, and could be adjusted by peers.
|
|
101
|
-
//
|
|
102
|
-
if (pow > 0) {
|
|
101
|
+
// When pow is null, skip POW verification entirely (useful for testing/CI)
|
|
102
|
+
if (pow !== null && pow > 0) {
|
|
103
103
|
if (msg.h.slice(0, pow) !== new Array(pow).fill("0").join("")) {
|
|
104
104
|
// this.logger("No valid hash (no pow)");
|
|
105
105
|
return [2 /*return*/, __1.VerifyResult.NoProofOfWork];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"verifyMessage.js","sourceRoot":"","sources":["../../lib/utils/verifyMessage.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAAoE;AAEpE;;;;;GAKG;AACH,SAA8B,aAAa,CAEzC,GAAiC,EACjC,
|
|
1
|
+
{"version":3,"file":"verifyMessage.js","sourceRoot":"","sources":["../../lib/utils/verifyMessage.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAAoE;AAEpE;;;;;GAKG;AACH,SAA8B,aAAa,CAEzC,GAAiC,EACjC,GAAsB;IAAtB,oBAAA,EAAA,OAAsB;;;;;;oBAGhB,OAAO,GAAG,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;oBAEtC,IACE,GAAG,CAAC,CAAC,KAAK,SAAS;wBACnB,GAAG,CAAC,CAAC,KAAK,SAAS;wBACnB,GAAG,CAAC,CAAC,KAAK,SAAS;wBACnB,GAAG,CAAC,CAAC,KAAK,SAAS;wBACnB,GAAG,CAAC,CAAC,KAAK,SAAS;wBACnB,GAAG,CAAC,CAAC,KAAK,SAAS,EACnB;wBACA,sBAAO,gBAAY,CAAC,WAAW,EAAC;qBACjC;oBAED,yCAAyC;oBACzC,kEAAkE;oBAClE,IAAI,GAAG,CAAC,CAAC,GAAG,IAAI,IAAI,EAAE,CAAC,OAAO,EAAE,GAAG,KAAK,EAAE;wBACxC,6CAA6C;wBAC7C,sBAAO,gBAAY,CAAC,gBAAgB,EAAC;qBACtC;oBAGG,gBAAgB,GAAmB,KAAK,CAAC;oBAC7C,IAAI,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,IAAI,GAAG,EAAE;wBAC5B,gBAAgB,GAAG,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;qBACjD;yBAIG,CAAA,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,IAAI,IAAI,CAAA,EAAzB,wBAAyB;oBACrB,GAAG,GAAG,GAAG,CAAC,CAAC,CAAC;oBACL,qBAAM,IAAI,CAAC,KAAK;6BAC1B,GAAG,CAAC,GAAG,CAAC;6BACR,IAAI,CAAC,UAAC,IAAI;4BACT,IAAI;gCACF,IAAM,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;gCACjC,OAAO,OAAO,CAAC;6BAChB;4BAAC,OAAO,CAAC,EAAE;gCACV,OAAO,IAAI,CAAC;6BACb;wBACH,CAAC,CAAC;6BACD,KAAK,CAAC;4BACL,OAAO,IAAI,CAAC;wBACd,CAAC,CAAC,EAAA;;oBAZE,IAAI,GAAG,SAYT;oBACJ,IAAI,IAAI,IAAI,IAAI,CAAC,CAAC,KAAK,GAAG,CAAC,CAAC;wBAAE,sBAAO,gBAAY,CAAC,aAAa,EAAC;;;oBAGlE,IAAI,gBAAgB,IAAI,gBAAgB,KAAK,GAAG,CAAC,CAAC,EAAE;wBAClD,kDAAkD;wBAClD,sBAAO,gBAAY,CAAC,eAAe,EAAC;qBACrC;oBAED,sEAAsE;oBACtE,0EAA0E;oBAC1E,qEAAqE;oBACrE,2EAA2E;oBAC3E,IAAI,GAAG,KAAK,IAAI,IAAI,GAAG,GAAG,CAAC,EAAE;wBAC3B,IAAI,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,GAAG,CAAC,KAAK,IAAI,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE;4BAC7D,yCAAyC;4BACzC,sBAAO,gBAAY,CAAC,aAAa,EAAC;yBACnC;wBAED,IAAI,IAAA,UAAM,EAAC,UAAG,OAAO,SAAG,GAAG,CAAC,CAAC,SAAG,GAAG,CAAC,CAAC,SAAG,GAAG,CAAC,CAAC,CAAE,CAAC,KAAK,GAAG,CAAC,CAAC,EAAE;4BAC1D,+DAA+D;4BAC/D,sBAAO,gBAAY,CAAC,gBAAgB,EAAC;yBACtC;qBACF;yBAEgB,IAAI,CAAC,WAAW,EAAhB,wBAAgB;oBAC7B,qBAAM,IAAI,CAAC,WAAW,CAAC,eAAe,CAAC,GAAG,CAAC,EAAA;;oBAA3C,KAAA,SAA2C,CAAA;;;oBAC3C,KAAA,KAAK,CAAA;;;oBAFH,QAAQ,KAEL;oBACT,0EAA0E;oBAE1E,sBAAO,QAAQ,CAAC,CAAC,CAAC,gBAAY,CAAC,QAAQ,CAAC,CAAC,CAAC,gBAAY,CAAC,gBAAgB,EAAC;;;;CACzE;AA/ED,gCA+EC"}
|
|
@@ -20,13 +20,14 @@ export default class ToolDbNetworkAdapter {
|
|
|
20
20
|
constructor(db: ToolDb) {
|
|
21
21
|
this._tooldb = db;
|
|
22
22
|
|
|
23
|
-
|
|
23
|
+
// Wait for peerAccount to be initialized before adding ourselves to serverPeers
|
|
24
|
+
this.tooldb.once("init", () => {
|
|
24
25
|
if (this.tooldb.options.server) {
|
|
25
26
|
this.getMeAsPeer().then((meAsPeer) => {
|
|
26
27
|
this.tooldb.serverPeers.push(meAsPeer);
|
|
27
28
|
});
|
|
28
29
|
}
|
|
29
|
-
}
|
|
30
|
+
});
|
|
30
31
|
}
|
|
31
32
|
|
|
32
33
|
get clientToSend() {
|
|
@@ -5,6 +5,20 @@ export default class ToolDbStorageAdapter {
|
|
|
5
5
|
|
|
6
6
|
private _forceStorageName: string | undefined;
|
|
7
7
|
|
|
8
|
+
/**
|
|
9
|
+
* Promise that resolves when the storage adapter is ready for operations.
|
|
10
|
+
* Subclasses should set this in their constructor.
|
|
11
|
+
*/
|
|
12
|
+
protected _readyPromise: Promise<void> = Promise.resolve();
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Public getter for the ready promise.
|
|
16
|
+
* Await this before performing operations if you need to ensure the store is ready.
|
|
17
|
+
*/
|
|
18
|
+
get ready(): Promise<void> {
|
|
19
|
+
return this._readyPromise;
|
|
20
|
+
}
|
|
21
|
+
|
|
8
22
|
get tooldb() {
|
|
9
23
|
return this._tooldb;
|
|
10
24
|
}
|
|
@@ -21,6 +35,14 @@ export default class ToolDbStorageAdapter {
|
|
|
21
35
|
}
|
|
22
36
|
}
|
|
23
37
|
|
|
38
|
+
/**
|
|
39
|
+
* Wait for the storage adapter to be ready.
|
|
40
|
+
* Called internally by put/get/query operations.
|
|
41
|
+
*/
|
|
42
|
+
protected async waitForReady(): Promise<void> {
|
|
43
|
+
await this._readyPromise;
|
|
44
|
+
}
|
|
45
|
+
|
|
24
46
|
put(key: string, data: string): Promise<unknown> {
|
|
25
47
|
return Promise.resolve();
|
|
26
48
|
}
|
|
@@ -11,11 +11,11 @@ export default class ToolDbUserAdapter {
|
|
|
11
11
|
this._tooldb = db;
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
public anonUser() {
|
|
14
|
+
public async anonUser(): Promise<void> {
|
|
15
15
|
return;
|
|
16
16
|
}
|
|
17
17
|
|
|
18
|
-
public setUser(account: unknown | undefined, name: string): void {}
|
|
18
|
+
public async setUser(account: unknown | undefined, name: string): Promise<void> { }
|
|
19
19
|
|
|
20
20
|
public signData(data: string): Promise<string> {
|
|
21
21
|
return Promise.resolve("");
|
package/lib/crdt/counterCrdt.ts
CHANGED
|
@@ -49,7 +49,7 @@ export class CounterCrdt<T> extends BaseCrdt<number, CounterChanges, number> {
|
|
|
49
49
|
calculate() {
|
|
50
50
|
let temp: number = 0;
|
|
51
51
|
// Only update if we have new changes
|
|
52
|
-
if (
|
|
52
|
+
if (this._changes.length !== this._lastUpdateSize) {
|
|
53
53
|
this._changes.sort(this.changesSort).forEach((change) => {
|
|
54
54
|
if (change.t === "ADD") {
|
|
55
55
|
temp += change.v;
|
|
@@ -58,6 +58,7 @@ export class CounterCrdt<T> extends BaseCrdt<number, CounterChanges, number> {
|
|
|
58
58
|
}
|
|
59
59
|
});
|
|
60
60
|
|
|
61
|
+
this._lastUpdateSize = this._changes.length;
|
|
61
62
|
this._value = temp;
|
|
62
63
|
}
|
|
63
64
|
}
|
package/lib/crdt/listCrdt.ts
CHANGED
|
@@ -61,7 +61,7 @@ export class ListCrdt<T> extends BaseCrdt<T, ListChanges<T>, T[]> {
|
|
|
61
61
|
calculate() {
|
|
62
62
|
const temp: ListTempCursor<T>[] = [];
|
|
63
63
|
// Only update if we have new changes
|
|
64
|
-
if (
|
|
64
|
+
if (this._changes.length !== this._lastUpdateSize) {
|
|
65
65
|
this._changes.sort(this.changesSort).forEach((change) => {
|
|
66
66
|
if (change.t === "INS") {
|
|
67
67
|
let poisitionToInsert = 0;
|
|
@@ -85,7 +85,7 @@ export class ListCrdt<T> extends BaseCrdt<T, ListChanges<T>, T[]> {
|
|
|
85
85
|
temp[poisitionToInsert].tomb = true;
|
|
86
86
|
}
|
|
87
87
|
});
|
|
88
|
-
this._lastUpdateSize =
|
|
88
|
+
this._lastUpdateSize = this._changes.length;
|
|
89
89
|
|
|
90
90
|
this._tempValues = temp;
|
|
91
91
|
|
package/lib/crdt/mapCrdt.ts
CHANGED
|
@@ -56,7 +56,7 @@ export class MapCrdt<T> extends BaseCrdt<T, MapChanges<T>, Record<string, T>> {
|
|
|
56
56
|
calculate() {
|
|
57
57
|
const temp: Record<string, T> = {};
|
|
58
58
|
// Only update if we have new changes
|
|
59
|
-
if (
|
|
59
|
+
if (this._changes.length !== this._lastUpdateSize) {
|
|
60
60
|
this._changes.sort(this.changesSort).forEach((change) => {
|
|
61
61
|
// Here we apply the model properties
|
|
62
62
|
// Since this is a KV store we dont need much logic,
|
|
@@ -68,7 +68,7 @@ export class MapCrdt<T> extends BaseCrdt<T, MapChanges<T>, Record<string, T>> {
|
|
|
68
68
|
}
|
|
69
69
|
this._keyIndex[change.k] = change.i;
|
|
70
70
|
});
|
|
71
|
-
this._lastUpdateSize =
|
|
71
|
+
this._lastUpdateSize = this._changes.length;
|
|
72
72
|
this._value = temp;
|
|
73
73
|
}
|
|
74
74
|
}
|
|
@@ -80,9 +80,9 @@ export class MapCrdt<T> extends BaseCrdt<T, MapChanges<T>, Record<string, T>> {
|
|
|
80
80
|
|
|
81
81
|
public mergeChanges(newChanges: MapChanges<T>[]) {
|
|
82
82
|
newChanges.forEach((change) => {
|
|
83
|
-
// Filter by author and
|
|
83
|
+
// Filter by key, author, index, and type
|
|
84
84
|
const filtered = this._changes.filter(
|
|
85
|
-
(c) => c.i === change.i && c.a === change.a && c.t === change.t
|
|
85
|
+
(c) => c.k === change.k && c.i === change.i && c.a === change.a && c.t === change.t
|
|
86
86
|
);
|
|
87
87
|
// Only add if there are not matches
|
|
88
88
|
if (filtered.length === 0) {
|
|
@@ -105,6 +105,7 @@ export class MapCrdt<T> extends BaseCrdt<T, MapChanges<T>, Record<string, T>> {
|
|
|
105
105
|
v: value,
|
|
106
106
|
i: this._keyIndex[key],
|
|
107
107
|
});
|
|
108
|
+
this.calculate();
|
|
108
109
|
}
|
|
109
110
|
|
|
110
111
|
public DEL(key: string) {
|
|
@@ -115,5 +116,6 @@ export class MapCrdt<T> extends BaseCrdt<T, MapChanges<T>, Record<string, T>> {
|
|
|
115
116
|
a: this._author,
|
|
116
117
|
i: this._keyIndex[key],
|
|
117
118
|
});
|
|
119
|
+
this.calculate();
|
|
118
120
|
}
|
|
119
121
|
}
|
package/lib/index.ts
CHANGED
|
@@ -2,6 +2,7 @@ export { default as proofOfWork } from "./utils/proofOfWork";
|
|
|
2
2
|
export { default as sha1 } from "./utils/sha1";
|
|
3
3
|
export { default as sha256 } from "./utils/sha256";
|
|
4
4
|
export { default as uniq } from "./utils/uniq";
|
|
5
|
+
export { default as generateGroupKey } from "./utils/generateGroupKey";
|
|
5
6
|
|
|
6
7
|
export { default as randomAnimal } from "./utils/randomAnimal";
|
|
7
8
|
export { default as verifyMessage } from "./utils/verifyMessage";
|
|
@@ -19,6 +20,11 @@ export { default as hexToArrayBuffer } from "./utils/encoding/hexToArrayBuffer";
|
|
|
19
20
|
export { default as hexToString } from "./utils/encoding/hexToString";
|
|
20
21
|
export { default as hexToUint8 } from "./utils/encoding/hexToUint8";
|
|
21
22
|
|
|
23
|
+
export { default as toBase64 } from "./utils/encoding/toBase64";
|
|
24
|
+
export { default as fromBase64 } from "./utils/encoding/fromBase64";
|
|
25
|
+
export { default as uint8ToBase64 } from "./utils/encoding/uint8ToBase64";
|
|
26
|
+
export { default as base64ToUint8 } from "./utils/encoding/base64ToUint8";
|
|
27
|
+
|
|
22
28
|
export { default as ToolDbNetworkAdapter } from "./adapters-base/networkAdapter";
|
|
23
29
|
export { default as ToolDbStorageAdapter } from "./adapters-base/storageAdapter";
|
|
24
30
|
export { default as ToolDbUserAdapter } from "./adapters-base/userAdapter";
|