@fireproof/core 0.19.0-dev-publish → 0.19.0-dev-global

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/{chunk-EVSZA26U.js → chunk-AZVWSRER.js} +2 -2
  2. package/{chunk-UCMXU3DH.js → chunk-NZNG6TQT.js} +103 -1
  3. package/chunk-NZNG6TQT.js.map +1 -0
  4. package/{chunk-5X6APJDY.js → chunk-ZHO4NMWL.js} +2 -2
  5. package/index.cjs +122 -92
  6. package/index.cjs.map +1 -1
  7. package/index.d.cts +21 -1
  8. package/index.d.ts +21 -1
  9. package/index.global.js +24688 -0
  10. package/index.global.js.map +1 -0
  11. package/index.js +41 -122
  12. package/index.js.map +1 -1
  13. package/metafile-cjs.json +1 -1
  14. package/metafile-esm.json +1 -1
  15. package/metafile-iife.json +1 -0
  16. package/package.json +1 -1
  17. package/{sqlite-data-store-RIH56645.js → sqlite-data-store-3ST7XOLX.js} +3 -3
  18. package/{sqlite-meta-store-6347MWOR.js → sqlite-meta-store-QOIMCSJ7.js} +3 -3
  19. package/{sqlite-wal-store-G5YGK77N.js → sqlite-wal-store-JFBQPOYT.js} +3 -3
  20. package/{store-file-D472VFCS.js → store-file-CSS5THFH.js} +2 -2
  21. package/{store-indexdb-FRX5PTKR.js → store-indexdb-DR4HELVP.js} +3 -3
  22. package/{store-sql-MDSU23Y7.js → store-sql-BG6SMGQJ.js} +5 -5
  23. package/tests/blockstore/loader.test.ts +265 -0
  24. package/tests/blockstore/store.test.ts +164 -0
  25. package/tests/blockstore/transaction.test.ts +121 -0
  26. package/tests/fireproof/config.test.ts +212 -0
  27. package/tests/fireproof/crdt.test.ts +434 -0
  28. package/tests/fireproof/database.test.ts +466 -0
  29. package/tests/fireproof/fireproof.test.ts +602 -0
  30. package/tests/fireproof/hello.test.ts +54 -0
  31. package/tests/fireproof/indexer.test.ts +389 -0
  32. package/tests/helpers.ts +81 -0
  33. package/tests/react/useFireproof.test.tsx +19 -0
  34. package/tests/www/gallery.html +132 -0
  35. package/tests/www/iife.html +42 -0
  36. package/tests/www/todo-aws.html +232 -0
  37. package/tests/www/todo-ipfs.html +213 -0
  38. package/tests/www/todo-local.html +214 -0
  39. package/tests/www/todo-netlify.html +227 -0
  40. package/tests/www/todo.html +236 -0
  41. package/chunk-UCMXU3DH.js.map +0 -1
  42. /package/{chunk-EVSZA26U.js.map → chunk-AZVWSRER.js.map} +0 -0
  43. /package/{chunk-5X6APJDY.js.map → chunk-ZHO4NMWL.js.map} +0 -0
  44. /package/{sqlite-data-store-RIH56645.js.map → sqlite-data-store-3ST7XOLX.js.map} +0 -0
  45. /package/{sqlite-meta-store-6347MWOR.js.map → sqlite-meta-store-QOIMCSJ7.js.map} +0 -0
  46. /package/{sqlite-wal-store-G5YGK77N.js.map → sqlite-wal-store-JFBQPOYT.js.map} +0 -0
  47. /package/{store-file-D472VFCS.js.map → store-file-CSS5THFH.js.map} +0 -0
  48. /package/{store-indexdb-FRX5PTKR.js.map → store-indexdb-DR4HELVP.js.map} +0 -0
  49. /package/{store-sql-MDSU23Y7.js.map → store-sql-BG6SMGQJ.js.map} +0 -0
package/index.d.cts CHANGED
@@ -966,6 +966,25 @@ declare namespace index$1 {
966
966
  export { type index$1_DBConnection as DBConnection, type index$1_DataRecord as DataRecord, type index$1_DataSQLStore as DataSQLStore, index$1_DefaultSQLTableNames as DefaultSQLTableNames, type index$1_MetaRecord as MetaRecord, type index$1_MetaRecordKey as MetaRecordKey, type index$1_MetaSQLStore as MetaSQLStore, type index$1_MetaType as MetaType, type index$1_SQLOpts as SQLOpts, type index$1_SQLStore as SQLStore, type index$1_SQLTableNames as SQLTableNames, type index$1_WalKey as WalKey, type index$1_WalRecord as WalRecord, type index$1_WalSQLStore as WalSQLStore, index$1_ensureSQLOpts as ensureSQLOpts };
967
967
  }
968
968
 
969
+ declare function toCryptoOpts(cryptoOpts?: Partial<CryptoOpts>): CryptoOpts;
970
+
971
+ declare const crypto$1_toCryptoOpts: typeof toCryptoOpts;
972
+ declare namespace crypto$1 {
973
+ export { crypto$1_toCryptoOpts as toCryptoOpts };
974
+ }
975
+
976
+ declare function encodeFile(blob: BlobLike): Promise<{
977
+ cid: AnyLink;
978
+ blocks: AnyBlock[];
979
+ }>;
980
+ declare function decodeFile(blocks: unknown, cid: AnyLink, meta: DocFileMeta): Promise<File>;
981
+
982
+ declare const files_decodeFile: typeof decodeFile;
983
+ declare const files_encodeFile: typeof encodeFile;
984
+ declare namespace files {
985
+ export { files_decodeFile as decodeFile, files_encodeFile as encodeFile };
986
+ }
987
+
969
988
  declare const FILESTORE_VERSION = "v0.19-file";
970
989
 
971
990
  declare const INDEXDB_VERSION = "v0.19-indexdb";
@@ -979,11 +998,12 @@ declare const index_SQLITE_VERSION: typeof SQLITE_VERSION;
979
998
  declare const index_SysContainer: typeof SysContainer;
980
999
  declare const index_dataDir: typeof dataDir;
981
1000
  declare const index_ensureIndexName: typeof ensureIndexName;
1001
+ declare const index_files: typeof files;
982
1002
  declare const index_getFileName: typeof getFileName;
983
1003
  declare const index_getPath: typeof getPath;
984
1004
  declare const index_join: typeof join;
985
1005
  declare namespace index {
986
- export { index_FILESTORE_VERSION as FILESTORE_VERSION, index_INDEXDB_VERSION as INDEXDB_VERSION, type index_NodeMap as NodeMap, index_SQLITE_VERSION as SQLITE_VERSION, index_SysContainer as SysContainer, index_dataDir as dataDir, index_ensureIndexName as ensureIndexName, index_getFileName as getFileName, index_getPath as getPath, index_join as join, index$1 as sql };
1006
+ export { index_FILESTORE_VERSION as FILESTORE_VERSION, index_INDEXDB_VERSION as INDEXDB_VERSION, type index_NodeMap as NodeMap, index_SQLITE_VERSION as SQLITE_VERSION, index_SysContainer as SysContainer, crypto$1 as crypto, index_dataDir as dataDir, index_ensureIndexName as ensureIndexName, index_files as files, index_getFileName as getFileName, index_getPath as getPath, index_join as join, index$1 as sql };
987
1007
  }
988
1008
 
989
1009
  declare const PACKAGE_VERSION: string;
package/index.d.ts CHANGED
@@ -966,6 +966,25 @@ declare namespace index$1 {
966
966
  export { type index$1_DBConnection as DBConnection, type index$1_DataRecord as DataRecord, type index$1_DataSQLStore as DataSQLStore, index$1_DefaultSQLTableNames as DefaultSQLTableNames, type index$1_MetaRecord as MetaRecord, type index$1_MetaRecordKey as MetaRecordKey, type index$1_MetaSQLStore as MetaSQLStore, type index$1_MetaType as MetaType, type index$1_SQLOpts as SQLOpts, type index$1_SQLStore as SQLStore, type index$1_SQLTableNames as SQLTableNames, type index$1_WalKey as WalKey, type index$1_WalRecord as WalRecord, type index$1_WalSQLStore as WalSQLStore, index$1_ensureSQLOpts as ensureSQLOpts };
967
967
  }
968
968
 
969
+ declare function toCryptoOpts(cryptoOpts?: Partial<CryptoOpts>): CryptoOpts;
970
+
971
+ declare const crypto$1_toCryptoOpts: typeof toCryptoOpts;
972
+ declare namespace crypto$1 {
973
+ export { crypto$1_toCryptoOpts as toCryptoOpts };
974
+ }
975
+
976
+ declare function encodeFile(blob: BlobLike): Promise<{
977
+ cid: AnyLink;
978
+ blocks: AnyBlock[];
979
+ }>;
980
+ declare function decodeFile(blocks: unknown, cid: AnyLink, meta: DocFileMeta): Promise<File>;
981
+
982
+ declare const files_decodeFile: typeof decodeFile;
983
+ declare const files_encodeFile: typeof encodeFile;
984
+ declare namespace files {
985
+ export { files_decodeFile as decodeFile, files_encodeFile as encodeFile };
986
+ }
987
+
969
988
  declare const FILESTORE_VERSION = "v0.19-file";
970
989
 
971
990
  declare const INDEXDB_VERSION = "v0.19-indexdb";
@@ -979,11 +998,12 @@ declare const index_SQLITE_VERSION: typeof SQLITE_VERSION;
979
998
  declare const index_SysContainer: typeof SysContainer;
980
999
  declare const index_dataDir: typeof dataDir;
981
1000
  declare const index_ensureIndexName: typeof ensureIndexName;
1001
+ declare const index_files: typeof files;
982
1002
  declare const index_getFileName: typeof getFileName;
983
1003
  declare const index_getPath: typeof getPath;
984
1004
  declare const index_join: typeof join;
985
1005
  declare namespace index {
986
- export { index_FILESTORE_VERSION as FILESTORE_VERSION, index_INDEXDB_VERSION as INDEXDB_VERSION, type index_NodeMap as NodeMap, index_SQLITE_VERSION as SQLITE_VERSION, index_SysContainer as SysContainer, index_dataDir as dataDir, index_ensureIndexName as ensureIndexName, index_getFileName as getFileName, index_getPath as getPath, index_join as join, index$1 as sql };
1006
+ export { index_FILESTORE_VERSION as FILESTORE_VERSION, index_INDEXDB_VERSION as INDEXDB_VERSION, type index_NodeMap as NodeMap, index_SQLITE_VERSION as SQLITE_VERSION, index_SysContainer as SysContainer, crypto$1 as crypto, index_dataDir as dataDir, index_ensureIndexName as ensureIndexName, index_files as files, index_getFileName as getFileName, index_getPath as getPath, index_join as join, index$1 as sql };
987
1007
  }
988
1008
 
989
1009
  declare const PACKAGE_VERSION: string;