/**
 * Minified by jsDelivr using Terser v5.39.0.
 * Original file: /npm/idb-lite@0.1.0/dist/index-cjs.js
 *
 * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
 */
module.exports={set:set,get:get,closeAll:closeAll,keys:keys,del:del,clear:clear,Store:Store};var dbs={};function exec(e,n,t,r,o){var c=n?n.name:"keyval",l=n?n.dbName:"keyval-store",u=encodeURI(l)+"|"+encodeURI(c);return dbs[u]||(dbs[u]=new Promise((function(e,n){var t=indexedDB.open(l);t.onerror=n,t.onupgradeneeded=function(){t.result.createObjectStore(c)},t.onsuccess=function(){e(t.result)}}))),dbs[u].then((function(n){return new Promise((function(l,u){var s=n.transaction(c,e);s.onabort=s.onerror=u,s.oncomplete=function(){l(o&&d.result)};var a=s.objectStore(c),d=a[t].apply(a,r)}))}))}function set(e,n,t){return exec("readwrite",t,"put",[n,e])}function get(e,n){return exec("readonly",n,"get",[e],!0)}function keys(e){return exec("readonly",e,"getAllKeys",null,!0)}function del(e,n){return exec("readwrite",n,"delete",[e])}function clear(e){return exec("readwrite",e,"clear")}function Store(e,n){this.dbName=e,this.name=n}function closeAll(){return Promise.all(Object.keys(dbs).map((function(e){var n=dbs[e];return delete dbs[e],n.then((function(e){return e.close()}))})))}
//# sourceMappingURL=/sm/444b9c196bb46173c7b8cfcacba9a83b74851a06adbb1594642e110e97cf1f58.map