@anfenn/dync 1.1.0 → 1.1.3

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/dist/index.d.cts CHANGED
@@ -1,7 +1,7 @@
1
- import { D as DyncOptions, S as SyncStatus, a as SyncApi, T as TableMap } from './types-DhCTdAep.cjs';
2
- export { A as AfterRemoteAddCallback, e as BatchFirstLoadResult, c as BatchPushPayload, d as BatchPushResult, B as BatchSync, f as ConflictResolutionStrategy, C as CrudSyncApi, F as FirstLoadProgress, g as FirstLoadProgressCallback, h as MissingRemoteRecordDuringUpdateCallback, M as MissingRemoteRecordStrategy, i as MutationEvent, b as SyncAction, j as SyncOptions, k as SyncState, l as SyncedRecord } from './types-DhCTdAep.cjs';
3
- import { T as TableSchemaDefinition, D as DexieQueryContext, S as SQLiteQueryContext, M as MemoryQueryContext, a as StorageTable } from './dexie-3VOQSn1s.cjs';
4
- export { b as MemoryAdapter, c as SQLiteAdapter, d as StorageAdapter } from './dexie-3VOQSn1s.cjs';
1
+ import { D as DyncOptions, S as SyncStatus, a as SyncApi, T as TableMap } from './types-Di82FTAL.cjs';
2
+ export { A as AfterRemoteAddCallback, e as BatchFirstLoadResult, c as BatchPushPayload, d as BatchPushResult, B as BatchSync, f as ConflictResolutionStrategy, C as CrudSyncApi, F as FirstLoadProgress, g as FirstLoadProgressCallback, h as MissingRemoteRecordDuringUpdateCallback, M as MissingRemoteRecordStrategy, i as MutationEvent, b as SyncAction, j as SyncOptions, k as SyncState, l as SyncedRecord } from './types-Di82FTAL.cjs';
3
+ import { T as TableSchemaDefinition, D as DexieQueryContext, S as SQLiteQueryContext, M as MemoryQueryContext, a as StorageTable } from './dexie-BRWUYM02.cjs';
4
+ export { b as MemoryAdapter, c as SQLiteAdapter, d as StorageAdapter } from './dexie-BRWUYM02.cjs';
5
5
  import { c as SQLiteVersionMigration } from './types-6-NyRQ0D.cjs';
6
6
  export { S as SQLiteDatabaseDriver, b as SQLiteQueryResult, a as SQLiteRunResult } from './types-6-NyRQ0D.cjs';
7
7
  import 'dexie';
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
- import { D as DyncOptions, S as SyncStatus, a as SyncApi, T as TableMap } from './types-BIJhsSOf.js';
2
- export { A as AfterRemoteAddCallback, e as BatchFirstLoadResult, c as BatchPushPayload, d as BatchPushResult, B as BatchSync, f as ConflictResolutionStrategy, C as CrudSyncApi, F as FirstLoadProgress, g as FirstLoadProgressCallback, h as MissingRemoteRecordDuringUpdateCallback, M as MissingRemoteRecordStrategy, i as MutationEvent, b as SyncAction, j as SyncOptions, k as SyncState, l as SyncedRecord } from './types-BIJhsSOf.js';
3
- import { T as TableSchemaDefinition, D as DexieQueryContext, S as SQLiteQueryContext, M as MemoryQueryContext, a as StorageTable } from './dexie-D85rTx4g.js';
4
- export { b as MemoryAdapter, c as SQLiteAdapter, d as StorageAdapter } from './dexie-D85rTx4g.js';
1
+ import { D as DyncOptions, S as SyncStatus, a as SyncApi, T as TableMap } from './types-DhlgTu1o.js';
2
+ export { A as AfterRemoteAddCallback, e as BatchFirstLoadResult, c as BatchPushPayload, d as BatchPushResult, B as BatchSync, f as ConflictResolutionStrategy, C as CrudSyncApi, F as FirstLoadProgress, g as FirstLoadProgressCallback, h as MissingRemoteRecordDuringUpdateCallback, M as MissingRemoteRecordStrategy, i as MutationEvent, b as SyncAction, j as SyncOptions, k as SyncState, l as SyncedRecord } from './types-DhlgTu1o.js';
3
+ import { T as TableSchemaDefinition, D as DexieQueryContext, S as SQLiteQueryContext, M as MemoryQueryContext, a as StorageTable } from './dexie-B3Ihrrxi.js';
4
+ export { b as MemoryAdapter, c as SQLiteAdapter, d as StorageAdapter } from './dexie-B3Ihrrxi.js';
5
5
  import { c as SQLiteVersionMigration } from './types-6-NyRQ0D.js';
6
6
  export { S as SQLiteDatabaseDriver, b as SQLiteQueryResult, a as SQLiteRunResult } from './types-6-NyRQ0D.js';
7
7
  import 'dexie';
package/dist/index.js CHANGED
@@ -2526,22 +2526,9 @@ var normalizeComparableValue = (value) => {
2526
2526
 
2527
2527
  // src/storage/sqlite/SQLiteQueryContext.ts
2528
2528
  var SQLiteQueryContext = class {
2529
- constructor(driver, adapter) {
2530
- this.driver = driver;
2529
+ constructor(adapter) {
2531
2530
  this.adapter = adapter;
2532
2531
  }
2533
- table(name) {
2534
- return this.adapter.table(name);
2535
- }
2536
- transaction(mode, tableNames, callback) {
2537
- return this.adapter.transaction(mode, tableNames, callback);
2538
- }
2539
- async execute(statement) {
2540
- return this.driver.execute(statement);
2541
- }
2542
- async run(statement, values) {
2543
- return this.driver.run(statement, values);
2544
- }
2545
2532
  async queryRows(statement, values) {
2546
2533
  return this.adapter.queryRows(statement, values);
2547
2534
  }
@@ -2710,8 +2697,7 @@ var SQLiteAdapter2 = class {
2710
2697
  }
2711
2698
  async query(arg1, arg2) {
2712
2699
  if (typeof arg1 === "function") {
2713
- const driver2 = await this.getDriver();
2714
- return arg1(new SQLiteQueryContext(driver2, this));
2700
+ return arg1(new SQLiteQueryContext(this));
2715
2701
  }
2716
2702
  const statement = arg1;
2717
2703
  const values = arg2;