nolo-cli 0.143.0-alpha.1 → 0.145.0-alpha.1
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 +2 -0
- package/{_executeModel-QK43QR2R.js → _executeModel-M3FASQ2Z.js} +18 -17
- package/{agentDeleteCommand-SE4WUIRR.js → agentDeleteCommand-K7GCEEVS.js} +10 -9
- package/{agentEmailCommands-LW5JMYH2.js → agentEmailCommands-MNXRO36L.js} +24 -23
- package/{agentListCommands-LGZG2OQR.js → agentListCommands-KMZR6VVM.js} +12 -11
- package/{agentMachineCommands-BNOXYSPZ.js → agentMachineCommands-75TIBYDY.js} +10 -9
- package/{agentProviderCommands-AOG3OZJA.js → agentProviderCommands-TWB6E5WD.js} +1 -1
- package/{agentRecordCommands-W5ZXPHZV.js → agentRecordCommands-RDO5L3N4.js} +23 -22
- package/{agentRunCommand-VRLCL57M.js → agentRunCommand-FVJJPL27.js} +23 -22
- package/{agentRuntimeLocal-VOQ3UYZB.js → agentRuntimeLocal-DAK7RCER.js} +8 -7
- package/{agentSlice-4AK24F5F.js → agentSlice-6MRJR2BJ.js} +1 -1
- package/{appDeleteCommands-XWAIUHTN.js → appDeleteCommands-JMMXK3XT.js} +11 -10
- package/{appDeployCommands-CBJJCUMG.js → appDeployCommands-JFU6GALI.js} +11 -10
- package/{appDeployStatusCommands-LTTZTJQS.js → appDeployStatusCommands-AXTZ4GAN.js} +11 -10
- package/{appGetCommands-QHUB7MFF.js → appGetCommands-CR2W3DCM.js} +11 -10
- package/{appListCommands-HINIDJE7.js → appListCommands-2TV6P3EU.js} +11 -10
- package/{authCommand-LARLQ3GC.js → authCommand-UBJ4EWYZ.js} +6 -6
- package/{authCommands-GBIFZWD3.js → authCommands-H6WKKCRW.js} +1 -1
- package/{builtinSkillRegistry-AFPSTTAU.js → builtinSkillRegistry-ZMF6YGNO.js} +4 -3
- package/{chatQueueReduxAdapter-KIQ3FQ62.js → chatQueueReduxAdapter-CDOHVTSE.js} +2 -2
- package/{chromeCommands-NKU3OWKH.js → chromeCommands-2N6MEWRU.js} +94 -23
- package/{chromeOpsCommands-OQDJGD4Y.js → chromeOpsCommands-IXRLN57H.js} +4 -3
- package/{chunk-7MUSNQ6E.js → chunk-27ONFIEY.js} +20 -2
- package/{chunk-OZ6V53WV.js → chunk-2EE5UD3N.js} +1 -1
- package/{chunk-44QZPYLI.js → chunk-2SYTUTLI.js} +92 -20
- package/{chunk-DID5AVGT.js → chunk-2TKVOEQF.js} +11 -10
- package/chunk-5J3PYNUP.js +255 -0
- package/{chunk-OUOJE2P2.js → chunk-5XYFIDFU.js} +5 -5
- package/{chunk-WTUVMKSQ.js → chunk-62XHRZG4.js} +2 -2
- package/{chunk-WC6A2Q7S.js → chunk-6TPOEJMQ.js} +5 -2
- package/{chunk-RRMAZ2BI.js → chunk-7NANRWL4.js} +1 -1
- package/{chunk-44F6KKUE.js → chunk-7YAK46ML.js} +3 -3
- package/{chunk-NOGH7HCP.js → chunk-A6FNUMCF.js} +47 -6
- package/{chunk-OFYHCA6W.js → chunk-AATZZAZE.js} +1 -1
- package/{chunk-KUPDS66Q.js → chunk-ANX7Z7Z2.js} +8 -8
- package/{chunk-J5H6SUOW.js → chunk-B2XUQXQX.js} +2 -2
- package/{chunk-A5MB5RIT.js → chunk-CCOXTK3I.js} +1 -1
- package/chunk-GNMAFAIS.js +29 -0
- package/{chunk-GZQNKKDG.js → chunk-HKBFZONG.js} +1 -1
- package/{chunk-7LLWEG6F.js → chunk-I44MDY73.js} +3 -3
- package/{chunk-QDT5T7MK.js → chunk-I4OPU5TK.js} +1 -1
- package/{chunk-VPFEPRME.js → chunk-IVZJWTDI.js} +3 -0
- package/{chunk-CTGZO35O.js → chunk-JLQKV2ZJ.js} +2 -2
- package/{chunk-PQVOC2CZ.js → chunk-M2YBIBBS.js} +1 -1
- package/{chunk-ZOI6KA4N.js → chunk-M76SRQ3H.js} +34 -22
- package/{chunk-K25DK52L.js → chunk-OKSJZ4UU.js} +21 -223
- package/{chunk-U5QTKTZE.js → chunk-P6GMCCAT.js} +1 -1
- package/{chunk-L6RB42ZR.js → chunk-QFZM5BFI.js} +3 -3
- package/{chunk-GH4MH73K.js → chunk-RHDOQWXZ.js} +175 -17
- package/{chunk-M6NK74VP.js → chunk-S5XGT6GB.js} +1 -1
- package/{chunk-KUWT3C2P.js → chunk-T76D3OYX.js} +1 -1
- package/{chunk-MXRUAINC.js → chunk-UMB7CHAY.js} +3 -3
- package/{chunk-VVUSRF5D.js → chunk-VJ4FUWPC.js} +3 -3
- package/{chunk-T36EFAW7.js → chunk-VZVTPDPL.js} +3 -3
- package/{chunk-AAROOKLX.js → chunk-X2QRZXZH.js} +1 -1
- package/{chunk-WYYO2YOL.js → chunk-XNXNHAAP.js} +1 -1
- package/{chunk-O6OSWFZQ.js → chunk-XUWRURDF.js} +6 -0
- package/{chunk-DOBBRISY.js → chunk-Y6XHJ4JJ.js} +22 -10
- package/{chunk-W247GBSQ.js → chunk-YU2THNST.js} +1 -1
- package/{chunk-OY5IJI2N.js → chunk-YUNJN43V.js} +23 -3
- package/{commandRegistry-DETYXF5I.js → commandRegistry-ZF6YXQWV.js} +76 -65
- package/{contentThunks-6QBTPLWT.js → contentThunks-6Y6ATG3A.js} +3 -3
- package/{createAgentAutomationAction-TZVIJTZ7.js → createAgentAutomationAction-OQTLA2FC.js} +3 -3
- package/{createDialogAction-KTDAEA42.js → createDialogAction-IF5EZMBD.js} +6 -5
- package/{createPageAction-4RASVDAU.js → createPageAction-GU766R3L.js} +3 -3
- package/{dialogCommands-GY7LRERG.js → dialogCommands-QV7XAX2V.js} +11 -10
- package/{dialogSlice-J24APUGG.js → dialogSlice-CVHMDSVV.js} +2 -2
- package/{docCreateCommands-T7KII3WP.js → docCreateCommands-FSBANQTO.js} +10 -9
- package/{docDeleteCommands-SQ26EFE6.js → docDeleteCommands-4IR4YSGU.js} +11 -10
- package/{docReadCommands-I6NA2ZKV.js → docReadCommands-4EYPGUE3.js} +10 -9
- package/{docStore-SPOGE7K3.js → docStore-RQOWPNON.js} +1 -1
- package/{docUpdateCommands-IG43SZ6U.js → docUpdateCommands-RW2BYLSE.js} +10 -9
- package/{handleSendMessageAction-I2IN64DS.js → handleSendMessageAction-UDTPG5WK.js} +4 -3
- package/index.js +4 -4
- package/{machineCommands-U7VABJPW.js → machineCommands-WBQ4TCPD.js} +22 -21
- package/{machineWsRunDispatch-ZNU6LRNG.js → machineWsRunDispatch-7DNDXUOS.js} +22 -21
- package/node_modules/abstract-level/CHANGELOG.md +150 -0
- package/node_modules/abstract-level/LICENSE +21 -0
- package/node_modules/abstract-level/README.md +1957 -0
- package/node_modules/abstract-level/UPGRADING.md +669 -0
- package/node_modules/abstract-level/abstract-chained-batch.js +397 -0
- package/node_modules/abstract-level/abstract-iterator.js +404 -0
- package/node_modules/abstract-level/abstract-level.js +1127 -0
- package/node_modules/abstract-level/abstract-snapshot.js +84 -0
- package/node_modules/abstract-level/index.d.ts +52 -0
- package/node_modules/abstract-level/index.js +9 -0
- package/node_modules/abstract-level/lib/abstract-sublevel-iterator.js +141 -0
- package/node_modules/abstract-level/lib/abstract-sublevel.js +290 -0
- package/node_modules/abstract-level/lib/common.js +33 -0
- package/node_modules/abstract-level/lib/default-chained-batch.js +29 -0
- package/node_modules/abstract-level/lib/default-kv-iterator.js +74 -0
- package/node_modules/abstract-level/lib/deferred-iterator.js +110 -0
- package/node_modules/abstract-level/lib/deferred-queue.js +84 -0
- package/node_modules/abstract-level/lib/errors.js +21 -0
- package/node_modules/abstract-level/lib/event-monitor.js +30 -0
- package/node_modules/abstract-level/lib/hooks.js +78 -0
- package/node_modules/abstract-level/lib/prefixes.js +21 -0
- package/node_modules/abstract-level/lib/prewrite-batch.js +96 -0
- package/node_modules/abstract-level/lib/range-options.js +26 -0
- package/node_modules/abstract-level/package.json +66 -0
- package/node_modules/abstract-level/test/async-iterator-test.js +132 -0
- package/node_modules/abstract-level/test/batch-test.js +214 -0
- package/node_modules/abstract-level/test/chained-batch-test.js +315 -0
- package/node_modules/abstract-level/test/clear-range-test.js +262 -0
- package/node_modules/abstract-level/test/clear-test.js +110 -0
- package/node_modules/abstract-level/test/common.js +90 -0
- package/node_modules/abstract-level/test/deferred-open-test.js +209 -0
- package/node_modules/abstract-level/test/del-test.js +65 -0
- package/node_modules/abstract-level/test/encoding-buffer-test.js +336 -0
- package/node_modules/abstract-level/test/encoding-custom-test.js +92 -0
- package/node_modules/abstract-level/test/encoding-decode-error-test.js +85 -0
- package/node_modules/abstract-level/test/encoding-json-test.js +75 -0
- package/node_modules/abstract-level/test/encoding-test.js +130 -0
- package/node_modules/abstract-level/test/events/write.js +132 -0
- package/node_modules/abstract-level/test/factory-test.js +36 -0
- package/node_modules/abstract-level/test/get-many-test.js +157 -0
- package/node_modules/abstract-level/test/get-sync-test.js +61 -0
- package/node_modules/abstract-level/test/get-test.js +83 -0
- package/node_modules/abstract-level/test/has-many-test.js +144 -0
- package/node_modules/abstract-level/test/has-test.js +81 -0
- package/node_modules/abstract-level/test/hooks/newsub.js +57 -0
- package/node_modules/abstract-level/test/hooks/postopen.js +229 -0
- package/node_modules/abstract-level/test/hooks/prewrite.js +816 -0
- package/node_modules/abstract-level/test/hooks/shared.js +38 -0
- package/node_modules/abstract-level/test/index.js +86 -0
- package/node_modules/abstract-level/test/iterator-explicit-snapshot-test.js +393 -0
- package/node_modules/abstract-level/test/iterator-no-snapshot-test.js +49 -0
- package/node_modules/abstract-level/test/iterator-range-test.js +277 -0
- package/node_modules/abstract-level/test/iterator-seek-test.js +335 -0
- package/node_modules/abstract-level/test/iterator-snapshot-test.js +56 -0
- package/node_modules/abstract-level/test/iterator-test.js +621 -0
- package/node_modules/abstract-level/test/manifest-test.js +21 -0
- package/node_modules/abstract-level/test/open-create-if-missing-test.js +39 -0
- package/node_modules/abstract-level/test/open-error-if-exists-test.js +25 -0
- package/node_modules/abstract-level/test/open-test.js +263 -0
- package/node_modules/abstract-level/test/put-get-del-test.js +97 -0
- package/node_modules/abstract-level/test/put-test.js +70 -0
- package/node_modules/abstract-level/test/self/abstract-iterator-test.js +182 -0
- package/node_modules/abstract-level/test/self/async-iterator-test.js +242 -0
- package/node_modules/abstract-level/test/self/attach-resource-test.js +74 -0
- package/node_modules/abstract-level/test/self/defer-test.js +140 -0
- package/node_modules/abstract-level/test/self/deferred-iterator-test.js +314 -0
- package/node_modules/abstract-level/test/self/deferred-operations-test.js +86 -0
- package/node_modules/abstract-level/test/self/deferred-queue-test.js +93 -0
- package/node_modules/abstract-level/test/self/encoding-test.js +391 -0
- package/node_modules/abstract-level/test/self/errors-test.js +11 -0
- package/node_modules/abstract-level/test/self/iterator-test.js +1050 -0
- package/node_modules/abstract-level/test/self/sublevel-test.js +1039 -0
- package/node_modules/abstract-level/test/self.js +905 -0
- package/node_modules/abstract-level/test/sublevel-test.js +209 -0
- package/node_modules/abstract-level/test/traits/closed.js +42 -0
- package/node_modules/abstract-level/test/traits/index.js +4 -0
- package/node_modules/abstract-level/test/traits/open.js +62 -0
- package/node_modules/abstract-level/test/util.js +275 -0
- package/node_modules/abstract-level/types/abstract-chained-batch.d.ts +124 -0
- package/node_modules/abstract-level/types/abstract-iterator.d.ts +241 -0
- package/node_modules/abstract-level/types/abstract-level.d.ts +636 -0
- package/node_modules/abstract-level/types/abstract-snapshot.d.ts +30 -0
- package/node_modules/abstract-level/types/abstract-sublevel.d.ts +76 -0
- package/node_modules/abstract-level/types/interfaces.d.ts +43 -0
- package/node_modules/base64-js/LICENSE +21 -0
- package/node_modules/base64-js/README.md +34 -0
- package/node_modules/base64-js/base64js.min.js +1 -0
- package/node_modules/base64-js/index.d.ts +3 -0
- package/node_modules/base64-js/index.js +150 -0
- package/node_modules/base64-js/package.json +47 -0
- package/node_modules/browser-level/CHANGELOG.md +44 -0
- package/node_modules/browser-level/LICENSE +21 -0
- package/node_modules/browser-level/README.md +124 -0
- package/node_modules/browser-level/UPGRADING.md +143 -0
- package/node_modules/browser-level/index.d.ts +108 -0
- package/node_modules/browser-level/index.js +323 -0
- package/node_modules/browser-level/iterator.js +239 -0
- package/node_modules/browser-level/package.json +48 -0
- package/node_modules/browser-level/util/clear.js +38 -0
- package/node_modules/browser-level/util/deserialize.js +17 -0
- package/node_modules/browser-level/util/key-range.js +20 -0
- package/node_modules/buffer/AUTHORS.md +73 -0
- package/node_modules/buffer/LICENSE +21 -0
- package/node_modules/buffer/README.md +410 -0
- package/node_modules/buffer/index.d.ts +194 -0
- package/node_modules/buffer/index.js +2106 -0
- package/node_modules/buffer/package.json +93 -0
- package/node_modules/classic-level/CHANGELOG.md +115 -0
- package/node_modules/classic-level/LICENSE +21 -0
- package/node_modules/classic-level/README.md +274 -0
- package/node_modules/classic-level/UPGRADING.md +131 -0
- package/node_modules/classic-level/binding.cc +2652 -0
- package/node_modules/classic-level/binding.gyp +71 -0
- package/node_modules/classic-level/binding.js +1 -0
- package/node_modules/classic-level/chained-batch.js +35 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/LICENSE +27 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/Makefile +424 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/build_detect_platform +256 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/autocompact_test.cc +118 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/builder.cc +88 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/builder.h +34 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/c.cc +595 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/c_test.c +390 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/corruption_test.cc +374 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/db_bench.cc +1020 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/db_impl.cc +1568 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/db_impl.h +212 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/db_iter.cc +317 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/db_iter.h +28 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/db_test.cc +2158 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/dbformat.cc +140 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/dbformat.h +230 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/dbformat_test.cc +112 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/dumpfile.cc +225 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/fault_injection_test.cc +554 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/filename.cc +144 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/filename.h +85 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/filename_test.cc +123 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/leveldbutil.cc +64 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/log_format.h +35 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/log_reader.cc +284 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/log_reader.h +113 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/log_test.cc +591 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/log_writer.cc +112 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/log_writer.h +54 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/memtable.cc +145 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/memtable.h +89 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/recovery_test.cc +324 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/repair.cc +461 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/skiplist.h +384 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/skiplist_test.cc +378 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/snapshot.h +67 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/table_cache.cc +127 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/table_cache.h +61 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/version_edit.cc +266 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/version_edit.h +107 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/version_edit_test.cc +46 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/version_set.cc +1535 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/version_set.h +399 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/version_set_test.cc +179 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/write_batch.cc +147 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/write_batch_internal.h +50 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/write_batch_test.cc +120 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/helpers/memenv/memenv.cc +398 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/helpers/memenv/memenv.h +20 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/helpers/memenv/memenv_test.cc +241 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/c.h +290 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/cache.h +110 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/comparator.h +63 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/db.h +164 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/dumpfile.h +25 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/env.h +351 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/filter_policy.h +70 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/iterator.h +100 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/options.h +213 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/slice.h +109 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/status.h +112 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/table.h +85 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/table_builder.h +92 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/value_sink.h +26 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/write_batch.h +64 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/issues/issue178_test.cc +92 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/issues/issue200_test.cc +59 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/atomic_pointer.h +242 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/port.h +21 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/port_example.h +141 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/port_posix.cc +53 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/port_posix.h +156 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/port_posix_sse.cc +129 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/thread_annotations.h +60 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/win/stdint.h +24 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/block.cc +268 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/block.h +44 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/block_builder.cc +109 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/block_builder.h +57 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/filter_block.cc +111 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/filter_block.h +68 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/filter_block_test.cc +128 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/format.cc +144 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/format.h +108 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/iterator.cc +67 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/iterator_wrapper.h +66 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/merger.cc +197 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/merger.h +26 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/table.cc +285 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/table_builder.cc +270 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/table_test.cc +876 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/two_level_iterator.cc +182 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/two_level_iterator.h +34 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/arena.cc +68 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/arena.h +68 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/arena_test.cc +68 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/bloom.cc +95 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/bloom_test.cc +162 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/cache.cc +405 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/cache_test.cc +226 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/coding.cc +194 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/coding.h +104 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/coding_test.cc +196 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/comparator.cc +81 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/crc32c.cc +350 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/crc32c.h +45 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/crc32c_test.cc +72 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/env.cc +100 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/env_posix.cc +695 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/env_posix_test.cc +66 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/env_posix_test_helper.h +28 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/env_test.cc +106 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/filter_policy.cc +11 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/hash.cc +52 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/hash.h +19 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/hash_test.cc +54 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/histogram.cc +139 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/histogram.h +42 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/logging.cc +72 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/logging.h +43 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/mutexlock.h +41 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/options.cc +30 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/posix_logger.h +98 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/random.h +64 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/status.cc +75 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/testharness.cc +77 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/testharness.h +138 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/testutil.cc +51 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/testutil.h +63 -0
- package/node_modules/classic-level/deps/leveldb/leveldb.gyp +282 -0
- package/node_modules/classic-level/deps/leveldb/patches/001-value-sink.patch +164 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/atomic_pointer_win.h +48 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/env_win.cc +692 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/port_uv.cc +36 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/port_uv.h +157 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/port_uv.h.bak +153 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/stdint-msvc2008.h +247 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/uv_condvar.h +45 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/uv_condvar_posix.cc +139 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/win_logger.cc +79 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/win_logger.h +28 -0
- package/node_modules/classic-level/deps/snappy/freebsd/config.h +135 -0
- package/node_modules/classic-level/deps/snappy/freebsd/snappy-stubs-public.h +100 -0
- package/node_modules/classic-level/deps/snappy/linux/config.h +135 -0
- package/node_modules/classic-level/deps/snappy/linux/snappy-stubs-public.h +100 -0
- package/node_modules/classic-level/deps/snappy/mac/config.h +137 -0
- package/node_modules/classic-level/deps/snappy/mac/snappy-stubs-public.h +100 -0
- package/node_modules/classic-level/deps/snappy/openbsd/config.h +135 -0
- package/node_modules/classic-level/deps/snappy/openbsd/snappy-stubs-public.h +100 -0
- package/node_modules/classic-level/deps/snappy/snappy/COPYING +54 -0
- package/node_modules/classic-level/deps/snappy/snappy/cmake/SnappyConfig.cmake +1 -0
- package/node_modules/classic-level/deps/snappy/snappy/cmake/config.h.in +62 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-c.cc +90 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-c.h +138 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-internal.h +224 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-sinksource.cc +104 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-sinksource.h +182 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-stubs-internal.cc +42 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-stubs-internal.h +561 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-stubs-public.h.in +94 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-test.cc +612 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-test.h +573 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy.cc +1515 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy.h +203 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy_unittest.cc +1410 -0
- package/node_modules/classic-level/deps/snappy/snappy.gyp +119 -0
- package/node_modules/classic-level/deps/snappy/solaris/config.h +135 -0
- package/node_modules/classic-level/deps/snappy/solaris/snappy-stubs-public.h +100 -0
- package/node_modules/classic-level/deps/snappy/win32/config.h +29 -0
- package/node_modules/classic-level/deps/snappy/win32/snappy-stubs-public.h +100 -0
- package/node_modules/classic-level/index.d.ts +343 -0
- package/node_modules/classic-level/index.js +311 -0
- package/node_modules/classic-level/iterator.js +122 -0
- package/node_modules/classic-level/package.json +70 -0
- package/node_modules/classic-level/prebuilds/android-arm/classic-level.armv7.node +0 -0
- package/node_modules/classic-level/prebuilds/android-arm64/classic-level.armv8.node +0 -0
- package/node_modules/classic-level/prebuilds/darwin-x64+arm64/classic-level.node +0 -0
- package/node_modules/classic-level/prebuilds/linux-arm/classic-level.armv6.node +0 -0
- package/node_modules/classic-level/prebuilds/linux-arm/classic-level.armv7.node +0 -0
- package/node_modules/classic-level/prebuilds/linux-arm64/classic-level.armv8.node +0 -0
- package/node_modules/classic-level/prebuilds/linux-x64/classic-level.musl.node +0 -0
- package/node_modules/classic-level/prebuilds/linux-x64/classic-level.node +0 -0
- package/node_modules/classic-level/prebuilds/win32-ia32/classic-level.node +0 -0
- package/node_modules/classic-level/prebuilds/win32-x64/classic-level.node +0 -0
- package/node_modules/ieee754/LICENSE +11 -0
- package/node_modules/ieee754/README.md +51 -0
- package/node_modules/ieee754/index.d.ts +10 -0
- package/node_modules/ieee754/index.js +85 -0
- package/node_modules/ieee754/package.json +52 -0
- package/node_modules/is-buffer/LICENSE +21 -0
- package/node_modules/is-buffer/README.md +54 -0
- package/node_modules/is-buffer/index.d.ts +2 -0
- package/node_modules/is-buffer/index.js +11 -0
- package/node_modules/is-buffer/package.json +65 -0
- package/node_modules/level/CHANGELOG.md +532 -0
- package/node_modules/level/LICENSE +21 -0
- package/node_modules/level/README.md +107 -0
- package/node_modules/level/UPGRADING.md +413 -0
- package/node_modules/level/browser.js +1 -0
- package/node_modules/level/index.d.ts +75 -0
- package/node_modules/level/index.js +1 -0
- package/node_modules/level/package.json +62 -0
- package/node_modules/level-supports/CHANGELOG.md +140 -0
- package/node_modules/level-supports/LICENSE +21 -0
- package/node_modules/level-supports/README.md +276 -0
- package/node_modules/level-supports/index.d.ts +137 -0
- package/node_modules/level-supports/index.js +26 -0
- package/node_modules/level-supports/package.json +46 -0
- package/node_modules/level-supports/test/cloneable.js +26 -0
- package/node_modules/level-supports/test/index.js +24 -0
- package/node_modules/level-supports/test/self.js +86 -0
- package/node_modules/level-supports/test/shape.js +23 -0
- package/node_modules/level-transcoder/CHANGELOG.md +15 -0
- package/node_modules/level-transcoder/LICENSE +21 -0
- package/node_modules/level-transcoder/README.md +214 -0
- package/node_modules/level-transcoder/UPGRADING.md +13 -0
- package/node_modules/level-transcoder/index.d.ts +27 -0
- package/node_modules/level-transcoder/index.js +158 -0
- package/node_modules/level-transcoder/lib/encoding.d.ts +158 -0
- package/node_modules/level-transcoder/lib/encoding.js +105 -0
- package/node_modules/level-transcoder/lib/encodings.d.ts +9 -0
- package/node_modules/level-transcoder/lib/encodings.js +135 -0
- package/node_modules/level-transcoder/lib/formats.d.ts +13 -0
- package/node_modules/level-transcoder/lib/formats.js +111 -0
- package/node_modules/level-transcoder/lib/text-endec.d.ts +6 -0
- package/node_modules/level-transcoder/lib/text-endec.js +19 -0
- package/node_modules/level-transcoder/package.json +46 -0
- package/node_modules/maybe-combine-errors/LICENSE.md +21 -0
- package/node_modules/maybe-combine-errors/README.md +94 -0
- package/node_modules/maybe-combine-errors/index.js +60 -0
- package/node_modules/maybe-combine-errors/package.json +33 -0
- package/node_modules/module-error/CHANGELOG.md +23 -0
- package/node_modules/module-error/LICENSE +21 -0
- package/node_modules/module-error/README.md +89 -0
- package/node_modules/module-error/index.d.ts +18 -0
- package/node_modules/module-error/index.js +22 -0
- package/node_modules/module-error/package.json +36 -0
- package/node_modules/napi-macros/LICENSE +21 -0
- package/node_modules/napi-macros/README.md +277 -0
- package/node_modules/napi-macros/index.js +1 -0
- package/node_modules/napi-macros/napi-macros.h +255 -0
- package/node_modules/napi-macros/package.json +22 -0
- package/node_modules/node-gyp-build/LICENSE +21 -0
- package/node_modules/node-gyp-build/README.md +58 -0
- package/node_modules/node-gyp-build/SECURITY.md +5 -0
- package/node_modules/node-gyp-build/bin.js +84 -0
- package/node_modules/node-gyp-build/build-test.js +19 -0
- package/node_modules/node-gyp-build/index.js +6 -0
- package/node_modules/node-gyp-build/node-gyp-build.js +207 -0
- package/node_modules/node-gyp-build/optional.js +7 -0
- package/node_modules/node-gyp-build/package.json +43 -0
- package/package.json +6 -3
- package/{providerPresetApply-7XEHTODR.js → providerPresetApply-XTEXOH7X.js} +3 -3
- package/{providerRegistry-GNV4FFSA.js → providerRegistry-ADYDSLKR.js} +3 -3
- package/{readlineWorkspace-46KDFUHN.js → readlineWorkspace-LO6ZLFTO.js} +1381 -1317
- package/{runAgentClientLoop-CQWLWU4W.js → runAgentClientLoop-KAYGKVTK.js} +16 -15
- package/{runtimeDoctorCommands-3USD722U.js → runtimeDoctorCommands-ID23PNNZ.js} +28 -0
- package/{spaceCommands-TSBC5UWP.js → spaceCommands-FA6RCZ2Y.js} +10 -9
- package/{streamAgentChatTurn-XD5JEJXA.js → streamAgentChatTurn-DFNDU2UY.js} +17 -16
- package/{tools-5NAJJTFN.js → tools-6HKH75NT.js} +13 -12
- package/{tuiSummaryLlmCaller-7KLLDP22.js → tuiSummaryLlmCaller-CFFVXQWX.js} +2 -2
- package/{updateCommands-XYMGOKF4.js → updateCommands-4EHDLF5J.js} +1 -1
- package/{updateDialogTitleAction-IKZPJCRA.js → updateDialogTitleAction-FFSYTLBC.js} +3 -3
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import * as Transcoder from 'level-transcoder'
|
|
2
|
+
import { AbstractLevel } from './abstract-level'
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* @template TDatabase Type of parent database.
|
|
6
|
+
* @template TFormat The type used internally by the parent database to store data.
|
|
7
|
+
* @template KDefault The default type of keys if not overridden on operations.
|
|
8
|
+
* @template VDefault The default type of values if not overridden on operations.
|
|
9
|
+
*/
|
|
10
|
+
declare class AbstractSublevel<TDatabase, TFormat, KDefault, VDefault>
|
|
11
|
+
extends AbstractLevel<TFormat, KDefault, VDefault> {
|
|
12
|
+
/**
|
|
13
|
+
* Sublevel constructor.
|
|
14
|
+
*
|
|
15
|
+
* @param db Parent database.
|
|
16
|
+
* @param name Name of the sublevel, used to prefix keys.
|
|
17
|
+
*/
|
|
18
|
+
constructor (
|
|
19
|
+
db: TDatabase,
|
|
20
|
+
name: string,
|
|
21
|
+
options?: AbstractSublevelOptions<KDefault, VDefault> | undefined
|
|
22
|
+
)
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Prefix of the sublevel. A read-only string property.
|
|
26
|
+
*/
|
|
27
|
+
get prefix (): string
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* Get the path of the sublevel, which is its prefix without separators.
|
|
31
|
+
*
|
|
32
|
+
* @param local If true, exclude path of parent database. If false (the default) then
|
|
33
|
+
* recurse to form a fully-qualified path that travels from the root database to this
|
|
34
|
+
* sublevel.
|
|
35
|
+
*/
|
|
36
|
+
path (local?: boolean | undefined): string[]
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Parent database. A read-only property.
|
|
40
|
+
*/
|
|
41
|
+
get parent (): TDatabase
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* Root database. A read-only property.
|
|
45
|
+
*/
|
|
46
|
+
get db (): TDatabase extends AbstractSublevel<any, any, any, any>
|
|
47
|
+
? TDatabase['db']
|
|
48
|
+
: TDatabase extends AbstractLevel<any, any, any>
|
|
49
|
+
? TDatabase
|
|
50
|
+
: AbstractLevel<any, any, any>
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Options for the {@link AbstractLevel.sublevel} method.
|
|
55
|
+
*/
|
|
56
|
+
export interface AbstractSublevelOptions<K, V> {
|
|
57
|
+
/**
|
|
58
|
+
* Character for separating sublevel names from user keys and each other. Must sort
|
|
59
|
+
* before characters used in `name`. An error will be thrown if that's not the case.
|
|
60
|
+
*
|
|
61
|
+
* @defaultValue `'!'`
|
|
62
|
+
*/
|
|
63
|
+
separator?: string | undefined
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* Encoding to use for keys.
|
|
67
|
+
* @defaultValue `'utf8'`
|
|
68
|
+
*/
|
|
69
|
+
keyEncoding?: string | Transcoder.PartialEncoding<K> | undefined
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* Encoding to use for values.
|
|
73
|
+
* @defaultValue `'utf8'`
|
|
74
|
+
*/
|
|
75
|
+
valueEncoding?: string | Transcoder.PartialEncoding<V> | undefined
|
|
76
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
2
|
+
import { AbstractLevel } from './abstract-level'
|
|
3
|
+
import { AbstractSnapshot } from './abstract-snapshot'
|
|
4
|
+
|
|
5
|
+
export interface RangeOptions<K> {
|
|
6
|
+
gt?: K
|
|
7
|
+
gte?: K
|
|
8
|
+
lt?: K
|
|
9
|
+
lte?: K
|
|
10
|
+
reverse?: boolean | undefined
|
|
11
|
+
limit?: number | undefined
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Common options for read methods like {@link AbstractLevel.get} and
|
|
16
|
+
* {@link AbstractLevel.iterator}.
|
|
17
|
+
*/
|
|
18
|
+
export interface AbstractReadOptions {
|
|
19
|
+
/**
|
|
20
|
+
* Explicit snapshot to read from.
|
|
21
|
+
*/
|
|
22
|
+
snapshot?: AbstractSnapshot | undefined
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Represents a stateful resource that can be closed.
|
|
27
|
+
*/
|
|
28
|
+
export interface AbstractResource extends AsyncDisposable {
|
|
29
|
+
/**
|
|
30
|
+
* Close the resource.
|
|
31
|
+
*
|
|
32
|
+
* Note for implementors: if the resource is exposed to the user and can also be closed
|
|
33
|
+
* in an automated fashion - through `db.attachResource()` or other - then the
|
|
34
|
+
* `close()` method should be idempotent such that calling it twice will make no
|
|
35
|
+
* difference.
|
|
36
|
+
*/
|
|
37
|
+
close (): Promise<void>
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* Close the resource. Identical in functionality to {@link close}.
|
|
41
|
+
*/
|
|
42
|
+
[Symbol.asyncDispose] (): Promise<void>
|
|
43
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
The MIT License (MIT)
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2014 Jameson Little
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
|
13
|
+
all copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
21
|
+
THE SOFTWARE.
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
base64-js
|
|
2
|
+
=========
|
|
3
|
+
|
|
4
|
+
`base64-js` does basic base64 encoding/decoding in pure JS.
|
|
5
|
+
|
|
6
|
+
[](http://travis-ci.org/beatgammit/base64-js)
|
|
7
|
+
|
|
8
|
+
Many browsers already have base64 encoding/decoding functionality, but it is for text data, not all-purpose binary data.
|
|
9
|
+
|
|
10
|
+
Sometimes encoding/decoding binary data in the browser is useful, and that is what this module does.
|
|
11
|
+
|
|
12
|
+
## install
|
|
13
|
+
|
|
14
|
+
With [npm](https://npmjs.org) do:
|
|
15
|
+
|
|
16
|
+
`npm install base64-js` and `var base64js = require('base64-js')`
|
|
17
|
+
|
|
18
|
+
For use in web browsers do:
|
|
19
|
+
|
|
20
|
+
`<script src="base64js.min.js"></script>`
|
|
21
|
+
|
|
22
|
+
[Get supported base64-js with the Tidelift Subscription](https://tidelift.com/subscription/pkg/npm-base64-js?utm_source=npm-base64-js&utm_medium=referral&utm_campaign=readme)
|
|
23
|
+
|
|
24
|
+
## methods
|
|
25
|
+
|
|
26
|
+
`base64js` has three exposed functions, `byteLength`, `toByteArray` and `fromByteArray`, which both take a single argument.
|
|
27
|
+
|
|
28
|
+
* `byteLength` - Takes a base64 string and returns length of byte array
|
|
29
|
+
* `toByteArray` - Takes a base64 string and returns a byte array
|
|
30
|
+
* `fromByteArray` - Takes a byte array and returns a base64 string
|
|
31
|
+
|
|
32
|
+
## license
|
|
33
|
+
|
|
34
|
+
MIT
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(function(a){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=a();else if("function"==typeof define&&define.amd)define([],a);else{var b;b="undefined"==typeof window?"undefined"==typeof global?"undefined"==typeof self?this:self:global:window,b.base64js=a()}})(function(){return function(){function b(d,e,g){function a(j,i){if(!e[j]){if(!d[j]){var f="function"==typeof require&&require;if(!i&&f)return f(j,!0);if(h)return h(j,!0);var c=new Error("Cannot find module '"+j+"'");throw c.code="MODULE_NOT_FOUND",c}var k=e[j]={exports:{}};d[j][0].call(k.exports,function(b){var c=d[j][1][b];return a(c||b)},k,k.exports,b,d,e,g)}return e[j].exports}for(var h="function"==typeof require&&require,c=0;c<g.length;c++)a(g[c]);return a}return b}()({"/":[function(a,b,c){'use strict';function d(a){var b=a.length;if(0<b%4)throw new Error("Invalid string. Length must be a multiple of 4");var c=a.indexOf("=");-1===c&&(c=b);var d=c===b?0:4-c%4;return[c,d]}function e(a,b,c){return 3*(b+c)/4-c}function f(a){var b,c,f=d(a),g=f[0],h=f[1],j=new m(e(a,g,h)),k=0,n=0<h?g-4:g;for(c=0;c<n;c+=4)b=l[a.charCodeAt(c)]<<18|l[a.charCodeAt(c+1)]<<12|l[a.charCodeAt(c+2)]<<6|l[a.charCodeAt(c+3)],j[k++]=255&b>>16,j[k++]=255&b>>8,j[k++]=255&b;return 2===h&&(b=l[a.charCodeAt(c)]<<2|l[a.charCodeAt(c+1)]>>4,j[k++]=255&b),1===h&&(b=l[a.charCodeAt(c)]<<10|l[a.charCodeAt(c+1)]<<4|l[a.charCodeAt(c+2)]>>2,j[k++]=255&b>>8,j[k++]=255&b),j}function g(a){return k[63&a>>18]+k[63&a>>12]+k[63&a>>6]+k[63&a]}function h(a,b,c){for(var d,e=[],f=b;f<c;f+=3)d=(16711680&a[f]<<16)+(65280&a[f+1]<<8)+(255&a[f+2]),e.push(g(d));return e.join("")}function j(a){for(var b,c=a.length,d=c%3,e=[],f=16383,g=0,j=c-d;g<j;g+=f)e.push(h(a,g,g+f>j?j:g+f));return 1===d?(b=a[c-1],e.push(k[b>>2]+k[63&b<<4]+"==")):2===d&&(b=(a[c-2]<<8)+a[c-1],e.push(k[b>>10]+k[63&b>>4]+k[63&b<<2]+"=")),e.join("")}c.byteLength=function(a){var b=d(a),c=b[0],e=b[1];return 3*(c+e)/4-e},c.toByteArray=f,c.fromByteArray=j;for(var k=[],l=[],m="undefined"==typeof Uint8Array?Array:Uint8Array,n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",o=0,p=n.length;o<p;++o)k[o]=n[o],l[n.charCodeAt(o)]=o;l[45]=62,l[95]=63},{}]},{},[])("/")});
|
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
'use strict'
|
|
2
|
+
|
|
3
|
+
exports.byteLength = byteLength
|
|
4
|
+
exports.toByteArray = toByteArray
|
|
5
|
+
exports.fromByteArray = fromByteArray
|
|
6
|
+
|
|
7
|
+
var lookup = []
|
|
8
|
+
var revLookup = []
|
|
9
|
+
var Arr = typeof Uint8Array !== 'undefined' ? Uint8Array : Array
|
|
10
|
+
|
|
11
|
+
var code = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'
|
|
12
|
+
for (var i = 0, len = code.length; i < len; ++i) {
|
|
13
|
+
lookup[i] = code[i]
|
|
14
|
+
revLookup[code.charCodeAt(i)] = i
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
// Support decoding URL-safe base64 strings, as Node.js does.
|
|
18
|
+
// See: https://en.wikipedia.org/wiki/Base64#URL_applications
|
|
19
|
+
revLookup['-'.charCodeAt(0)] = 62
|
|
20
|
+
revLookup['_'.charCodeAt(0)] = 63
|
|
21
|
+
|
|
22
|
+
function getLens (b64) {
|
|
23
|
+
var len = b64.length
|
|
24
|
+
|
|
25
|
+
if (len % 4 > 0) {
|
|
26
|
+
throw new Error('Invalid string. Length must be a multiple of 4')
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
// Trim off extra bytes after placeholder bytes are found
|
|
30
|
+
// See: https://github.com/beatgammit/base64-js/issues/42
|
|
31
|
+
var validLen = b64.indexOf('=')
|
|
32
|
+
if (validLen === -1) validLen = len
|
|
33
|
+
|
|
34
|
+
var placeHoldersLen = validLen === len
|
|
35
|
+
? 0
|
|
36
|
+
: 4 - (validLen % 4)
|
|
37
|
+
|
|
38
|
+
return [validLen, placeHoldersLen]
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
// base64 is 4/3 + up to two characters of the original data
|
|
42
|
+
function byteLength (b64) {
|
|
43
|
+
var lens = getLens(b64)
|
|
44
|
+
var validLen = lens[0]
|
|
45
|
+
var placeHoldersLen = lens[1]
|
|
46
|
+
return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
function _byteLength (b64, validLen, placeHoldersLen) {
|
|
50
|
+
return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
function toByteArray (b64) {
|
|
54
|
+
var tmp
|
|
55
|
+
var lens = getLens(b64)
|
|
56
|
+
var validLen = lens[0]
|
|
57
|
+
var placeHoldersLen = lens[1]
|
|
58
|
+
|
|
59
|
+
var arr = new Arr(_byteLength(b64, validLen, placeHoldersLen))
|
|
60
|
+
|
|
61
|
+
var curByte = 0
|
|
62
|
+
|
|
63
|
+
// if there are placeholders, only get up to the last complete 4 chars
|
|
64
|
+
var len = placeHoldersLen > 0
|
|
65
|
+
? validLen - 4
|
|
66
|
+
: validLen
|
|
67
|
+
|
|
68
|
+
var i
|
|
69
|
+
for (i = 0; i < len; i += 4) {
|
|
70
|
+
tmp =
|
|
71
|
+
(revLookup[b64.charCodeAt(i)] << 18) |
|
|
72
|
+
(revLookup[b64.charCodeAt(i + 1)] << 12) |
|
|
73
|
+
(revLookup[b64.charCodeAt(i + 2)] << 6) |
|
|
74
|
+
revLookup[b64.charCodeAt(i + 3)]
|
|
75
|
+
arr[curByte++] = (tmp >> 16) & 0xFF
|
|
76
|
+
arr[curByte++] = (tmp >> 8) & 0xFF
|
|
77
|
+
arr[curByte++] = tmp & 0xFF
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
if (placeHoldersLen === 2) {
|
|
81
|
+
tmp =
|
|
82
|
+
(revLookup[b64.charCodeAt(i)] << 2) |
|
|
83
|
+
(revLookup[b64.charCodeAt(i + 1)] >> 4)
|
|
84
|
+
arr[curByte++] = tmp & 0xFF
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
if (placeHoldersLen === 1) {
|
|
88
|
+
tmp =
|
|
89
|
+
(revLookup[b64.charCodeAt(i)] << 10) |
|
|
90
|
+
(revLookup[b64.charCodeAt(i + 1)] << 4) |
|
|
91
|
+
(revLookup[b64.charCodeAt(i + 2)] >> 2)
|
|
92
|
+
arr[curByte++] = (tmp >> 8) & 0xFF
|
|
93
|
+
arr[curByte++] = tmp & 0xFF
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
return arr
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
function tripletToBase64 (num) {
|
|
100
|
+
return lookup[num >> 18 & 0x3F] +
|
|
101
|
+
lookup[num >> 12 & 0x3F] +
|
|
102
|
+
lookup[num >> 6 & 0x3F] +
|
|
103
|
+
lookup[num & 0x3F]
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
function encodeChunk (uint8, start, end) {
|
|
107
|
+
var tmp
|
|
108
|
+
var output = []
|
|
109
|
+
for (var i = start; i < end; i += 3) {
|
|
110
|
+
tmp =
|
|
111
|
+
((uint8[i] << 16) & 0xFF0000) +
|
|
112
|
+
((uint8[i + 1] << 8) & 0xFF00) +
|
|
113
|
+
(uint8[i + 2] & 0xFF)
|
|
114
|
+
output.push(tripletToBase64(tmp))
|
|
115
|
+
}
|
|
116
|
+
return output.join('')
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
function fromByteArray (uint8) {
|
|
120
|
+
var tmp
|
|
121
|
+
var len = uint8.length
|
|
122
|
+
var extraBytes = len % 3 // if we have 1 byte left, pad 2 bytes
|
|
123
|
+
var parts = []
|
|
124
|
+
var maxChunkLength = 16383 // must be multiple of 3
|
|
125
|
+
|
|
126
|
+
// go through the array every three bytes, we'll deal with trailing stuff later
|
|
127
|
+
for (var i = 0, len2 = len - extraBytes; i < len2; i += maxChunkLength) {
|
|
128
|
+
parts.push(encodeChunk(uint8, i, (i + maxChunkLength) > len2 ? len2 : (i + maxChunkLength)))
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
// pad the end with zeros, but make sure to not forget the extra bytes
|
|
132
|
+
if (extraBytes === 1) {
|
|
133
|
+
tmp = uint8[len - 1]
|
|
134
|
+
parts.push(
|
|
135
|
+
lookup[tmp >> 2] +
|
|
136
|
+
lookup[(tmp << 4) & 0x3F] +
|
|
137
|
+
'=='
|
|
138
|
+
)
|
|
139
|
+
} else if (extraBytes === 2) {
|
|
140
|
+
tmp = (uint8[len - 2] << 8) + uint8[len - 1]
|
|
141
|
+
parts.push(
|
|
142
|
+
lookup[tmp >> 10] +
|
|
143
|
+
lookup[(tmp >> 4) & 0x3F] +
|
|
144
|
+
lookup[(tmp << 2) & 0x3F] +
|
|
145
|
+
'='
|
|
146
|
+
)
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
return parts.join('')
|
|
150
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "base64-js",
|
|
3
|
+
"description": "Base64 encoding/decoding in pure JS",
|
|
4
|
+
"version": "1.5.1",
|
|
5
|
+
"author": "T. Jameson Little <t.jameson.little@gmail.com>",
|
|
6
|
+
"typings": "index.d.ts",
|
|
7
|
+
"bugs": {
|
|
8
|
+
"url": "https://github.com/beatgammit/base64-js/issues"
|
|
9
|
+
},
|
|
10
|
+
"devDependencies": {
|
|
11
|
+
"babel-minify": "^0.5.1",
|
|
12
|
+
"benchmark": "^2.1.4",
|
|
13
|
+
"browserify": "^16.3.0",
|
|
14
|
+
"standard": "*",
|
|
15
|
+
"tape": "4.x"
|
|
16
|
+
},
|
|
17
|
+
"homepage": "https://github.com/beatgammit/base64-js",
|
|
18
|
+
"keywords": [
|
|
19
|
+
"base64"
|
|
20
|
+
],
|
|
21
|
+
"license": "MIT",
|
|
22
|
+
"main": "index.js",
|
|
23
|
+
"repository": {
|
|
24
|
+
"type": "git",
|
|
25
|
+
"url": "git://github.com/beatgammit/base64-js.git"
|
|
26
|
+
},
|
|
27
|
+
"scripts": {
|
|
28
|
+
"build": "browserify -s base64js -r ./ | minify > base64js.min.js",
|
|
29
|
+
"lint": "standard",
|
|
30
|
+
"test": "npm run lint && npm run unit",
|
|
31
|
+
"unit": "tape test/*.js"
|
|
32
|
+
},
|
|
33
|
+
"funding": [
|
|
34
|
+
{
|
|
35
|
+
"type": "github",
|
|
36
|
+
"url": "https://github.com/sponsors/feross"
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"type": "patreon",
|
|
40
|
+
"url": "https://www.patreon.com/feross"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"type": "consulting",
|
|
44
|
+
"url": "https://feross.org/support"
|
|
45
|
+
}
|
|
46
|
+
]
|
|
47
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## [3.0.0] - 2025-04-20
|
|
4
|
+
|
|
5
|
+
_If you are upgrading: please see [`UPGRADING.md`](UPGRADING.md)._
|
|
6
|
+
|
|
7
|
+
### Changed
|
|
8
|
+
|
|
9
|
+
- **Breaking:** upgrade to `abstract-level` 3 ([#24](https://github.com/Level/browser-level/issues/24)) ([`26adf16`](https://github.com/Level/browser-level/commit/26adf16)) (Vincent Weevers)
|
|
10
|
+
|
|
11
|
+
### Added
|
|
12
|
+
|
|
13
|
+
- Implement `has()` and `hasMany()` ([#25](https://github.com/Level/browser-level/issues/25)) ([`40b1881`](https://github.com/Level/browser-level/commit/40b1881)) (Vincent Weevers)
|
|
14
|
+
|
|
15
|
+
## [2.0.0] - 2024-12-01
|
|
16
|
+
|
|
17
|
+
_If you are upgrading: please see [`UPGRADING.md`](UPGRADING.md)._
|
|
18
|
+
|
|
19
|
+
### Changed
|
|
20
|
+
|
|
21
|
+
- **Breaking:** upgrade to `abstract-level` 2 ([#16](https://github.com/Level/browser-level/issues/16)) ([`6296322`](https://github.com/Level/browser-level/commit/6296322)) (Vincent Weevers)
|
|
22
|
+
- Align location check with `classic-level` ([`9304795`](https://github.com/Level/browser-level/commit/9304795)) (Vincent Weevers)
|
|
23
|
+
|
|
24
|
+
### Removed
|
|
25
|
+
|
|
26
|
+
- Remove `levelup` compatibility check ([`0b98710`](https://github.com/Level/browser-level/commit/0b98710)) (Vincent Weevers)
|
|
27
|
+
|
|
28
|
+
## [1.0.1] - 2022-03-06
|
|
29
|
+
|
|
30
|
+
### Fixed
|
|
31
|
+
|
|
32
|
+
- Fix TypeScript type declarations ([`d5db420`](https://github.com/Level/browser-level/commit/d5db420)) (Vincent Weevers)
|
|
33
|
+
|
|
34
|
+
## [1.0.0] - 2022-03-05
|
|
35
|
+
|
|
36
|
+
_:seedling: Initial release. If you are upgrading from `level-js`, please see [UPGRADING.md](UPGRADING.md)._
|
|
37
|
+
|
|
38
|
+
[3.0.0]: https://github.com/Level/browser-level/releases/tag/v3.0.0
|
|
39
|
+
|
|
40
|
+
[2.0.0]: https://github.com/Level/browser-level/releases/tag/v2.0.0
|
|
41
|
+
|
|
42
|
+
[1.0.1]: https://github.com/Level/browser-level/releases/tag/v1.0.1
|
|
43
|
+
|
|
44
|
+
[1.0.0]: https://github.com/Level/browser-level/releases/tag/v1.0.0
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2012 Max Ogden and the contributors to browser-level.
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
# browser-level
|
|
2
|
+
|
|
3
|
+
**An [`abstract-level`][abstract-level] database for browsers, backed by [IndexedDB][indexeddb].** The successor to [`level-js`](https://github.com/Level/level-js). If you are upgrading, please see [UPGRADING.md](UPGRADING.md).
|
|
4
|
+
|
|
5
|
+
> :pushpin: Which module should I use? What is `abstract-level`? Head over to the [FAQ](https://github.com/Level/community#faq).
|
|
6
|
+
|
|
7
|
+
[![level badge][level-badge]][awesome]
|
|
8
|
+
[](https://www.npmjs.com/package/browser-level)
|
|
9
|
+
[](https://github.com/Level/browser-level/actions/workflows/test.yml)
|
|
10
|
+
[](https://codecov.io/gh/Level/browser-level)
|
|
11
|
+
[](https://standardjs.com)
|
|
12
|
+
[](https://common-changelog.org)
|
|
13
|
+
[](https://opencollective.com/level)
|
|
14
|
+
|
|
15
|
+
## Usage
|
|
16
|
+
|
|
17
|
+
```js
|
|
18
|
+
const { BrowserLevel } = require('browser-level')
|
|
19
|
+
|
|
20
|
+
// Create a database called 'example'
|
|
21
|
+
const db = new BrowserLevel('example', { valueEncoding: 'json' })
|
|
22
|
+
|
|
23
|
+
// Add an entry with key 'a' and value 1
|
|
24
|
+
await db.put('a', 1)
|
|
25
|
+
|
|
26
|
+
// Add multiple entries
|
|
27
|
+
await db.batch([{ type: 'put', key: 'b', value: 2 }])
|
|
28
|
+
|
|
29
|
+
// Get value of key 'a': 1
|
|
30
|
+
const value = await db.get('a')
|
|
31
|
+
|
|
32
|
+
// Iterate entries with keys that are greater than 'a'
|
|
33
|
+
for await (const [key, value] of db.iterator({ gt: 'a' })) {
|
|
34
|
+
console.log(value) // 2
|
|
35
|
+
}
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
## API
|
|
39
|
+
|
|
40
|
+
The API of `browser-level` follows that of [`abstract-level`](https://github.com/Level/abstract-level) with just two additional constructor options (see below) and one additional method (see below). As such, the majority of the API is documented in `abstract-level`. The `db.getSync()` method is not supported here and neither are the `createIfMissing` and `errorIfExists` options.
|
|
41
|
+
|
|
42
|
+
Like other implementations of `abstract-level`, `browser-level` has first-class support of binary keys and values, using either [Uint8Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array) or [Buffer](https://nodejs.org/api/buffer.html). In order to sort string and binary keys the same way as other databases, `browser-level` internally converts data to a Uint8Array before passing them to IndexedDB. If you have no need to work with `Buffer` keys or values, you can choose to omit the [`buffer`](https://github.com/feross/buffer) shim from a JavaScript bundle (through configuration of Webpack, Browserify or other bundlers).
|
|
43
|
+
|
|
44
|
+
Due to limitations of IndexedDB, `browser-level` does not offer snapshot guarantees. Such a guarantee would mean that an iterator does not see the data of simultaneous writes - it would be reading from a snapshot in time. In contrast, a `browser-level` iterator reads a few entries ahead and then opens a new IndexedDB transaction on the next read. A "few" means all entries for `iterator.all()`, `size` amount of entries for `iterator.nextv(size)` and a hardcoded 100 entries for `iterator.next()`. Individual calls to those methods have snapshot guarantees but repeated calls do not.
|
|
45
|
+
|
|
46
|
+
The result is that an iterator will include the data of simultaneous writes, if `db.put()`, `db.del()` or `db.batch()` are called in between creating the iterator and consuming the iterator, or in between calls to `iterator.next()` or `iterator.nextv()`. For example:
|
|
47
|
+
|
|
48
|
+
```js
|
|
49
|
+
const iterator = db.iterator()
|
|
50
|
+
await db.put('abc', '123')
|
|
51
|
+
|
|
52
|
+
for await (const [key, value] of iterator) {
|
|
53
|
+
// This might be 'abc'
|
|
54
|
+
console.log(key)
|
|
55
|
+
}
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
If snapshot guarantees are a must for your application then use `iterator.all()` and call it immediately after creating the iterator:
|
|
59
|
+
|
|
60
|
+
```js
|
|
61
|
+
const entries = await db.iterator({ limit: 50 }).all()
|
|
62
|
+
|
|
63
|
+
// Synchronously iterate the result
|
|
64
|
+
for (const [key, value] of entries) {
|
|
65
|
+
console.log(key)
|
|
66
|
+
}
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
### `db = new BrowserLevel(location[, options])`
|
|
70
|
+
|
|
71
|
+
Create a new database or open an existing one. The required `location` argument is the string name of the [`IDBDatabase`](https://developer.mozilla.org/en-US/docs/Web/API/IDBDatabase) to be opened, as well as the name of the object store within that database. The name of the `IDBDatabase` will be prefixed with `options.prefix`.
|
|
72
|
+
|
|
73
|
+
Besides `abstract-level` options, the optional `options` argument may contain:
|
|
74
|
+
|
|
75
|
+
- `prefix` (string, default: `'level-js-'`): Prefix for the `IDBDatabase` name. Can be set to an empty string. The default is compatible with `level-js`.
|
|
76
|
+
- `version` (string or number, default: `1`): The version to open the `IDBDatabase` with.
|
|
77
|
+
|
|
78
|
+
See [`IDBFactory#open()`](https://developer.mozilla.org/en-US/docs/Web/API/IDBFactory/open) for more details about database name and version.
|
|
79
|
+
|
|
80
|
+
### `BrowserLevel.destroy(location[, prefix])`
|
|
81
|
+
|
|
82
|
+
Delete the IndexedDB database at the given `location`. Returns a promise. If `prefix` is not given, it defaults to the same value as the `BrowserLevel` constructor does. This method is an additional method that is not part of the [`abstract-level`](https://github.com/Level/abstract-level) interface.
|
|
83
|
+
|
|
84
|
+
Before calling `destroy()`, close a database if it's using the same `location` and `prefix`:
|
|
85
|
+
|
|
86
|
+
```js
|
|
87
|
+
const db = new BrowserLevel('example')
|
|
88
|
+
await db.close()
|
|
89
|
+
await BrowserLevel.destroy('example')
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
## Install
|
|
93
|
+
|
|
94
|
+
With [npm](https://npmjs.org) do:
|
|
95
|
+
|
|
96
|
+
```bash
|
|
97
|
+
npm install browser-level
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
This module is best used with [`browserify`](http://browserify.org) or similar bundlers.
|
|
101
|
+
|
|
102
|
+
## Contributing
|
|
103
|
+
|
|
104
|
+
[`Level/browser-level`](https://github.com/Level/browser-level) is an **OPEN Open Source Project**. This means that:
|
|
105
|
+
|
|
106
|
+
> Individuals making significant and valuable contributions are given commit-access to the project to contribute as they see fit. This project is more like an open wiki than a standard guarded open source project.
|
|
107
|
+
|
|
108
|
+
See the [Contribution Guide](https://github.com/Level/community/blob/master/CONTRIBUTING.md) for more details.
|
|
109
|
+
|
|
110
|
+
## Donate
|
|
111
|
+
|
|
112
|
+
Support us with a monthly donation on [Open Collective](https://opencollective.com/level) and help us continue our work.
|
|
113
|
+
|
|
114
|
+
## License
|
|
115
|
+
|
|
116
|
+
[MIT](LICENSE)
|
|
117
|
+
|
|
118
|
+
[level-badge]: https://leveljs.org/img/badge.svg
|
|
119
|
+
|
|
120
|
+
[indexeddb]: https://developer.mozilla.org/en-US/docs/Web/API/IndexedDB_API
|
|
121
|
+
|
|
122
|
+
[awesome]: https://github.com/Level/awesome
|
|
123
|
+
|
|
124
|
+
[abstract-level]: https://github.com/Level/abstract-level
|