@rdlabo/ionic-angular-kit 21.5.25 → 21.5.26
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/package.json
CHANGED
|
@@ -365,6 +365,8 @@ interface OfflineCommandBase<T> extends OfflineScope {
|
|
|
365
365
|
retryAt: number | null;
|
|
366
366
|
createdAt: number;
|
|
367
367
|
lastErrorCode: string | null;
|
|
368
|
+
/** True when transport started but the client cannot prove whether the server committed. */
|
|
369
|
+
serverCommitUnknown?: boolean;
|
|
368
370
|
}
|
|
369
371
|
/** Durable before/after image used to reconcile product-owned derived rows. */
|
|
370
372
|
interface OfflineOptimisticReplicaCompanion {
|
|
@@ -416,6 +418,10 @@ interface OfflineReplicaTransaction {
|
|
|
416
418
|
putCommands?: readonly OfflineCommand[];
|
|
417
419
|
removeCommandIds?: readonly string[];
|
|
418
420
|
putCursors?: readonly OfflineReplicaCursor[];
|
|
421
|
+
/** Scopes whose acknowledged server changes still require an authoritative pull. */
|
|
422
|
+
putReconciliationScopes?: readonly OfflineScope[];
|
|
423
|
+
/** Scopes whose authoritative post-acknowledgement pull completed successfully. */
|
|
424
|
+
removeReconciliationScopes?: readonly OfflineScope[];
|
|
419
425
|
}
|
|
420
426
|
/** Durable local replica and outbox persistence contract. */
|
|
421
427
|
interface OfflineRepository {
|
|
@@ -431,6 +437,7 @@ interface OfflineRepository {
|
|
|
431
437
|
getReplicaRowByRemoteId<TValues = unknown>(scope: OfflineScope, sourceKey: string, remoteId: OfflineGeneratedRemoteId): Promise<OfflineReplicaRow<TValues> | null>;
|
|
432
438
|
getReplicaRowByRemoteIdentity<TValues = unknown>(scope: OfflineScope, sourceKey: string, identity: OfflineReplicaRemoteIdentity): Promise<OfflineReplicaRow<TValues> | null>;
|
|
433
439
|
getReplicaCursor(scope: OfflineScope): Promise<OfflineReplicaCursor | null>;
|
|
440
|
+
getReconciliationScopes?(userId: OfflinePrincipalId): Promise<OfflineScope[]>;
|
|
434
441
|
getCommands(scope: OfflineScope): Promise<OfflineCommand[]>;
|
|
435
442
|
getCommandsForUser?(userId: OfflinePrincipalId): Promise<OfflineCommand[]>;
|
|
436
443
|
putCommand(command: OfflineCommand): Promise<void>;
|
|
@@ -458,6 +465,7 @@ declare class IonicOfflineRepository implements OfflineRepository {
|
|
|
458
465
|
getReplicaRowByRemoteId<TValues = unknown>(scope: OfflineScope, sourceKey: string, remoteId: OfflineGeneratedRemoteId): Promise<OfflineReplicaRow<TValues> | null>;
|
|
459
466
|
getReplicaRowByRemoteIdentity<TValues = unknown>(scope: OfflineScope, sourceKey: string, identity: OfflineReplicaRemoteIdentity): Promise<OfflineReplicaRow<TValues> | null>;
|
|
460
467
|
getReplicaCursor(scope: OfflineScope): Promise<OfflineReplicaCursor | null>;
|
|
468
|
+
getReconciliationScopes(userId: OfflinePrincipalId): Promise<OfflineScope[]>;
|
|
461
469
|
getCommands(scope: OfflineScope): Promise<OfflineCommand[]>;
|
|
462
470
|
getCommandsForUser(userId: OfflinePrincipalId): Promise<OfflineCommand[]>;
|
|
463
471
|
putCommand(command: OfflineCommand): Promise<void>;
|
|
@@ -1018,6 +1026,7 @@ declare class SqliteOfflineRepository implements OfflineRepository {
|
|
|
1018
1026
|
getReplicaRowByRemoteId<TValues = unknown>(scope: OfflineScope, sourceKey: string, remoteId: OfflineGeneratedRemoteId): Promise<OfflineReplicaRow<TValues> | null>;
|
|
1019
1027
|
getReplicaRowByRemoteIdentity<TValues = unknown>(scope: OfflineScope, sourceKey: string, identity: OfflineReplicaRemoteIdentity): Promise<OfflineReplicaRow<TValues> | null>;
|
|
1020
1028
|
getReplicaCursor(scope: OfflineScope): Promise<OfflineReplicaCursor | null>;
|
|
1029
|
+
getReconciliationScopes(userId: OfflinePrincipalId): Promise<OfflineScope[]>;
|
|
1021
1030
|
getCommands(scope: OfflineScope): Promise<OfflineCommand[]>;
|
|
1022
1031
|
getCommandsForUser(userId: OfflinePrincipalId): Promise<OfflineCommand[]>;
|
|
1023
1032
|
putCommand(command: OfflineCommand): Promise<void>;
|
|
@@ -1107,6 +1116,11 @@ declare class OfflineOutboxCapacityError extends Error {
|
|
|
1107
1116
|
readonly currentBytes: number;
|
|
1108
1117
|
constructor(reason: 'command_count' | 'serialized_bytes', currentCommands: number, currentBytes: number);
|
|
1109
1118
|
}
|
|
1119
|
+
/** Raised when a discard could race a request whose server commit is unknown. */
|
|
1120
|
+
declare class OfflineCommandInFlightError extends Error {
|
|
1121
|
+
readonly commandIds: readonly string[];
|
|
1122
|
+
constructor(commandIds: readonly string[]);
|
|
1123
|
+
}
|
|
1110
1124
|
/** Maintains the optimistic local replica and synchronizes its durable outbox. */
|
|
1111
1125
|
declare class OfflineSyncService {
|
|
1112
1126
|
#private;
|
|
@@ -1169,5 +1183,5 @@ declare class OfflineRequestFallbackService {
|
|
|
1169
1183
|
static ɵprov: i0.ɵɵInjectableDeclaration<OfflineRequestFallbackService>;
|
|
1170
1184
|
}
|
|
1171
1185
|
|
|
1172
|
-
export { COMMUNITY_SQLITE, DEFAULT_OFFLINE_COMMAND_HOOKS, IonicOfflineRepository, OFFLINE_BYPASS, OFFLINE_COMMAND_EXECUTOR, OFFLINE_COMMAND_HOOKS, OFFLINE_KIT_OPTIONS, OFFLINE_MUTATION_REQUEST_POLICIES, OFFLINE_REPLICA_PULLER, OFFLINE_REPOSITORY, OFFLINE_REQUEST_POLICIES, OFFLINE_RESPONSE_HEADER, OFFLINE_SCHEMA_VERSION, OFFLINE_SYNC_CONTEXT, OfflineCoordinatorService, OfflineMutationPolicyConflictError, OfflineMutationProtocolError, OfflineMutationRequestPolicyRegistry, OfflineNetworkService, OfflineOutboxCapacityError, OfflinePayloadValidationError, OfflineReplicaMutationCoordinator, OfflineReplicaPullService, OfflineRequestFallbackService, OfflineRequestPolicyRegistry, OfflineSessionService, OfflineSyncService, SqliteOfflineRepository, assertOfflineLocalId, assertOfflineReplicaGeneratedRemoteId, assertOfflineReplicaNaturalKeyBaseline, booleanColumn, canonicalOfflineCommandIdentity, canonicalOfflinePrincipalId, canonicalOfflineRemoteIdentity, canonicalOfflineReplicaIdentity, commandIdentityFromReplicaIdentity, commandIdentityMatchesReplicaRow, createCommunitySqliteDriver, createOfflineAuthBridge, createRandomOfflineEncryptionKey, datetime, decodeOfflineReplicaValues, defineOfflineReplicaSchema, defineReplicaEntity, encodeOfflineReplicaValues, generatedId, ignored, integer, isOfflineFallbackError, json, localOnly, naturalKey, normalizeOfflineNaturalKey, normalizeOfflineReplicaPullPage, nullable, offlineCommandLookupIdentity, offlineCommandTargetFromReplicaRow, offlineGeneratedReplicaIdentity, offlineInterceptor, offlineNaturalKeyFromValues, offlineNaturalReplicaIdentity, offlineReplicaRemoteIdentity, offlineSessionManifestAllows, parseOfflineCommandIdentity, parseOfflineMutationEnvelope, parseOfflinePrincipalId, projectOfflineReplicaValues, provideOffline, provideOfflineMutationRequestPolicy, provideOfflineRequestPolicy, real, replicaAddressFromIdentity, requirePositiveOfflineInteger, selectOfflineRepository, serializeOfflineCommandIdentity, sha256OfflineReplicaSchema, text };
|
|
1186
|
+
export { COMMUNITY_SQLITE, DEFAULT_OFFLINE_COMMAND_HOOKS, IonicOfflineRepository, OFFLINE_BYPASS, OFFLINE_COMMAND_EXECUTOR, OFFLINE_COMMAND_HOOKS, OFFLINE_KIT_OPTIONS, OFFLINE_MUTATION_REQUEST_POLICIES, OFFLINE_REPLICA_PULLER, OFFLINE_REPOSITORY, OFFLINE_REQUEST_POLICIES, OFFLINE_RESPONSE_HEADER, OFFLINE_SCHEMA_VERSION, OFFLINE_SYNC_CONTEXT, OfflineCommandInFlightError, OfflineCoordinatorService, OfflineMutationPolicyConflictError, OfflineMutationProtocolError, OfflineMutationRequestPolicyRegistry, OfflineNetworkService, OfflineOutboxCapacityError, OfflinePayloadValidationError, OfflineReplicaMutationCoordinator, OfflineReplicaPullService, OfflineRequestFallbackService, OfflineRequestPolicyRegistry, OfflineSessionService, OfflineSyncService, SqliteOfflineRepository, assertOfflineLocalId, assertOfflineReplicaGeneratedRemoteId, assertOfflineReplicaNaturalKeyBaseline, booleanColumn, canonicalOfflineCommandIdentity, canonicalOfflinePrincipalId, canonicalOfflineRemoteIdentity, canonicalOfflineReplicaIdentity, commandIdentityFromReplicaIdentity, commandIdentityMatchesReplicaRow, createCommunitySqliteDriver, createOfflineAuthBridge, createRandomOfflineEncryptionKey, datetime, decodeOfflineReplicaValues, defineOfflineReplicaSchema, defineReplicaEntity, encodeOfflineReplicaValues, generatedId, ignored, integer, isOfflineFallbackError, json, localOnly, naturalKey, normalizeOfflineNaturalKey, normalizeOfflineReplicaPullPage, nullable, offlineCommandLookupIdentity, offlineCommandTargetFromReplicaRow, offlineGeneratedReplicaIdentity, offlineInterceptor, offlineNaturalKeyFromValues, offlineNaturalReplicaIdentity, offlineReplicaRemoteIdentity, offlineSessionManifestAllows, parseOfflineCommandIdentity, parseOfflineMutationEnvelope, parseOfflinePrincipalId, projectOfflineReplicaValues, provideOffline, provideOfflineMutationRequestPolicy, provideOfflineRequestPolicy, real, replicaAddressFromIdentity, requirePositiveOfflineInteger, selectOfflineRepository, serializeOfflineCommandIdentity, sha256OfflineReplicaSchema, text };
|
|
1173
1187
|
export type { CommunitySqliteConnection, CommunitySqliteDatabase, CommunitySqliteDriver, CreateOfflineAuthBridgeOptions, EnqueueOfflineCommand, EnqueueOfflineCommandIdentity, EnqueueOfflineGeneratedIdentity, EnqueueOfflineNaturalIdentity, OfflineAuthBridgeConfig, OfflineAuthExchangeContext, OfflineAuthExchangePhase, OfflineAuthResumeContext, OfflineCommand, OfflineCommandExecutor, OfflineCommandHooks, OfflineCommandIdentity, OfflineCommandResult, OfflineCommandState, OfflineCommandTarget, OfflineGeneratedRemoteId, OfflineKitOptions, OfflineLogoutAction, OfflineMutationEnvelope, OfflineMutationEnvelopeIdPolicy, OfflineMutationEnvelopeOptions, OfflineMutationEnvelopeValuesPolicy, OfflineMutationRequestPlan, OfflineMutationRequestPolicy, OfflineNaturalKey, OfflineNaturalKeyValue, OfflineNetworkState, OfflineOptimisticReplicaCompanion, OfflineOutboxLimits, OfflinePrincipalId, OfflineReadRequestPlan, OfflineReadResponseSource, OfflineRemoteIdentity, OfflineReplicaAddress, OfflineReplicaChange, OfflineReplicaChangeBase, OfflineReplicaColumnDef, OfflineReplicaCursor, OfflineReplicaEntityDefinition, OfflineReplicaEntitySchema, OfflineReplicaEntityScope, OfflineReplicaFieldDescriptor, OfflineReplicaFieldPolicy, OfflineReplicaIdentity, OfflineReplicaIdentityDescriptor, OfflineReplicaIgnoredDef, OfflineReplicaLocalOnlyDef, OfflineReplicaMigration, OfflineReplicaMutation, OfflineReplicaNaturalKeyDef, OfflineReplicaPullPage, OfflineReplicaPullRequest, OfflineReplicaPuller, OfflineReplicaRemoteIdDef, OfflineReplicaRemoteIdRelease, OfflineReplicaRemoteIdentity, OfflineReplicaRow, OfflineReplicaRowKey, OfflineReplicaSchemaBundle, OfflineReplicaSchemaDefinition, OfflineReplicaSqliteAffinity, OfflineReplicaStorageKind, OfflineReplicaSyncState, OfflineReplicaTransaction, OfflineReplicaVisibility, OfflineReplicaWebMigrationCallback, OfflineReplicaWebMigrationResult, OfflineReplicaWebMigrationRow, OfflineReplicaWireChange, OfflineReplicaWireIdentity, OfflineReplicaWirePullPage, OfflineRepository, OfflineRequestPlan, OfflineRequestPolicy, OfflineResponseSource, OfflineResumeRemoteSessionOptions, OfflineScope, OfflineSessionManifest, OfflineSessionTransitionLease, OfflineSyncContext, OfflineSyncSession, OfflineSyncState, PreparedOfflineCommand, ProvideOfflineOptions, ProvideReadCacheOfflineOptions, ProvideSynchronizedOfflineOptions };
|