From 8eff962cab608341a6f2fedc640a0e32d96f26e2 Mon Sep 17 00:00:00 2001 From: altaf-creator Date: Sun, 9 Nov 2025 11:15:19 +0800 Subject: pain --- .../node_modules/idb/build/wrap-idb-value.d.ts | 34 ++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 frontend-old/node_modules/idb/build/wrap-idb-value.d.ts (limited to 'frontend-old/node_modules/idb/build/wrap-idb-value.d.ts') diff --git a/frontend-old/node_modules/idb/build/wrap-idb-value.d.ts b/frontend-old/node_modules/idb/build/wrap-idb-value.d.ts new file mode 100644 index 0000000..a8d8cd4 --- /dev/null +++ b/frontend-old/node_modules/idb/build/wrap-idb-value.d.ts @@ -0,0 +1,34 @@ +import { IDBPCursor, IDBPCursorWithValue, IDBPDatabase, IDBPIndex, IDBPObjectStore, IDBPTransaction } from './entry.js'; +export declare const reverseTransformCache: WeakMap; +export declare function replaceTraps(callback: (currentTraps: ProxyHandler) => ProxyHandler): void; +/** + * Enhance an IDB object with helpers. + * + * @param value The thing to enhance. + */ +export declare function wrap(value: IDBDatabase): IDBPDatabase; +export declare function wrap(value: IDBIndex): IDBPIndex; +export declare function wrap(value: IDBObjectStore): IDBPObjectStore; +export declare function wrap(value: IDBTransaction): IDBPTransaction; +export declare function wrap(value: IDBOpenDBRequest): Promise; +export declare function wrap(value: IDBRequest): Promise; +/** + * Revert an enhanced IDB object to a plain old miserable IDB one. + * + * Will also revert a promise back to an IDBRequest. + * + * @param value The enhanced object to revert. + */ +interface Unwrap { + (value: IDBPCursorWithValue): IDBCursorWithValue; + (value: IDBPCursor): IDBCursor; + (value: IDBPDatabase): IDBDatabase; + (value: IDBPIndex): IDBIndex; + (value: IDBPObjectStore): IDBObjectStore; + (value: IDBPTransaction): IDBTransaction; + (value: Promise>): IDBOpenDBRequest; + (value: Promise): IDBOpenDBRequest; + (value: Promise): IDBRequest; +} +export declare const unwrap: Unwrap; +export {}; -- cgit v1.2.3