@pol-studios/db 1.0.58 → 1.0.59
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/DataLayerContext-V5FotiSk.d.ts +563 -0
- package/dist/auth/context.js +2 -2
- package/dist/auth/hooks.js +3 -3
- package/dist/auth/index.js +3 -3
- package/dist/{chunk-YRIPM2AN.js → chunk-4PZ744G2.js} +207 -6
- package/dist/chunk-4PZ744G2.js.map +1 -0
- package/dist/{chunk-6SDH7M7J.js → chunk-ARALLEDJ.js} +2 -2
- package/dist/{chunk-Z456IHCB.js → chunk-F4HW4NT5.js} +1 -1
- package/dist/chunk-F4HW4NT5.js.map +1 -0
- package/dist/{chunk-OK2C54B6.js → chunk-K46TGKB2.js} +323 -379
- package/dist/chunk-K46TGKB2.js.map +1 -0
- package/dist/{chunk-GWYTROSD.js → chunk-L4DFVMTS.js} +335 -4
- package/dist/chunk-L4DFVMTS.js.map +1 -0
- package/dist/{chunk-MEBT5YHA.js → chunk-SNPZMRBC.js} +2 -2
- package/dist/{chunk-LG3OHLGB.js → chunk-VADZSRHY.js} +16 -337
- package/dist/chunk-VADZSRHY.js.map +1 -0
- package/dist/{chunk-4EO55YV2.js → chunk-VSY6766U.js} +4 -4
- package/dist/{chunk-VYFAMTHI.js → chunk-WY6MNB6K.js} +2 -2
- package/dist/core/index.d.ts +1 -1
- package/dist/{executor-D15yjeMo.d.ts → executor-Bu1OlqCl.d.ts} +43 -3
- package/dist/hooks/index.d.ts +3 -3
- package/dist/hooks/index.js +2 -2
- package/dist/{index-CFUuTzXO.d.ts → index-vwVJ0BWj.d.ts} +1 -9
- package/dist/index.d.ts +5 -5
- package/dist/index.js +20 -12
- package/dist/index.native.d.ts +77 -76
- package/dist/index.native.js +20 -12
- package/dist/index.web.d.ts +21 -44
- package/dist/index.web.js +215 -149
- package/dist/index.web.js.map +1 -1
- package/dist/powersync-bridge/index.d.ts +1 -1
- package/dist/query/index.d.ts +1 -1
- package/dist/query/index.js +1 -1
- package/dist/types/index.d.ts +3 -3
- package/dist/types/index.js +1 -1
- package/dist/{useDbCount-Ckb-FhZk.d.ts → useDbCount-dCkdaBpP.d.ts} +41 -83
- package/dist/{useResolveFeedback-CuUkdHoR.d.ts → useResolveFeedback-thFi-4h8.d.ts} +429 -5
- package/dist/with-auth/index.js +5 -5
- package/package.json +1 -1
- package/dist/DataLayerContext-BYZtDD0g.d.ts +0 -946
- package/dist/chunk-GWYTROSD.js.map +0 -1
- package/dist/chunk-LG3OHLGB.js.map +0 -1
- package/dist/chunk-OK2C54B6.js.map +0 -1
- package/dist/chunk-YRIPM2AN.js.map +0 -1
- package/dist/chunk-Z456IHCB.js.map +0 -1
- /package/dist/{chunk-6SDH7M7J.js.map → chunk-ARALLEDJ.js.map} +0 -0
- /package/dist/{chunk-MEBT5YHA.js.map → chunk-SNPZMRBC.js.map} +0 -0
- /package/dist/{chunk-4EO55YV2.js.map → chunk-VSY6766U.js.map} +0 -0
- /package/dist/{chunk-VYFAMTHI.js.map → chunk-WY6MNB6K.js.map} +0 -0
package/dist/index.native.js
CHANGED
|
@@ -13,26 +13,26 @@ import {
|
|
|
13
13
|
useHasConflicts,
|
|
14
14
|
usePendingConflicts,
|
|
15
15
|
useSupabaseUpload
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-K46TGKB2.js";
|
|
17
17
|
import {
|
|
18
18
|
ADAPTER_STRATEGIES,
|
|
19
|
-
AdapterAutoDetector,
|
|
20
19
|
AdapterRegistry,
|
|
21
20
|
BUCKETS,
|
|
22
|
-
BackendStatus,
|
|
23
21
|
StorageQueueContext,
|
|
24
22
|
StorageQueueProvider,
|
|
25
23
|
SupabaseAdapter,
|
|
26
24
|
SyncTrackingAdapter,
|
|
27
25
|
convertFilterToRealtimeQuery,
|
|
28
|
-
createAdapterAutoDetector,
|
|
29
26
|
createAdapterRegistry,
|
|
30
27
|
createInCondition,
|
|
31
28
|
createSupabaseAdapter,
|
|
32
29
|
executeAdvanceQuery,
|
|
30
|
+
generatePowerSyncAlias,
|
|
33
31
|
getErrorBody,
|
|
32
|
+
getPowerSyncAlias,
|
|
34
33
|
getStorageUrl,
|
|
35
34
|
newTimeActivity,
|
|
35
|
+
stripSchemaPrefix,
|
|
36
36
|
useAI,
|
|
37
37
|
useApplyFeedback,
|
|
38
38
|
useAutosave,
|
|
@@ -65,7 +65,7 @@ import {
|
|
|
65
65
|
useUpsertChangelog,
|
|
66
66
|
useUpsertChangelogEntry,
|
|
67
67
|
useUpsertChangelogMedia
|
|
68
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-VADZSRHY.js";
|
|
69
69
|
import {
|
|
70
70
|
LiveChangeContext,
|
|
71
71
|
LiveChangeContextProvider,
|
|
@@ -76,7 +76,7 @@ import {
|
|
|
76
76
|
useUserMetadataState,
|
|
77
77
|
useUserMetadataValue,
|
|
78
78
|
userMetadataContext
|
|
79
|
-
} from "./chunk-
|
|
79
|
+
} from "./chunk-VSY6766U.js";
|
|
80
80
|
import {
|
|
81
81
|
PostgrestFilter,
|
|
82
82
|
binarySearch,
|
|
@@ -116,12 +116,12 @@ import {
|
|
|
116
116
|
useOnlineStatus,
|
|
117
117
|
useSyncControl,
|
|
118
118
|
useSyncStatus
|
|
119
|
-
} from "./chunk-
|
|
119
|
+
} from "./chunk-WY6MNB6K.js";
|
|
120
120
|
import {
|
|
121
121
|
Constants,
|
|
122
122
|
createCombinedStatus,
|
|
123
123
|
useDbAdvanceFilterQuery
|
|
124
|
-
} from "./chunk-
|
|
124
|
+
} from "./chunk-F4HW4NT5.js";
|
|
125
125
|
import {
|
|
126
126
|
Accessory,
|
|
127
127
|
Address,
|
|
@@ -310,25 +310,29 @@ import {
|
|
|
310
310
|
UserMetadata
|
|
311
311
|
} from "./chunk-SM73S2DY.js";
|
|
312
312
|
import "./chunk-NSIAAYW3.js";
|
|
313
|
-
import "./chunk-
|
|
313
|
+
import "./chunk-SNPZMRBC.js";
|
|
314
314
|
import {
|
|
315
315
|
DEFAULT_QUERY_TIMEOUT,
|
|
316
316
|
TIMEOUT_ERROR_MESSAGE,
|
|
317
317
|
isTimeoutError
|
|
318
|
-
} from "./chunk-
|
|
318
|
+
} from "./chunk-ARALLEDJ.js";
|
|
319
319
|
import {
|
|
320
|
+
AdapterAutoDetector,
|
|
321
|
+
BackendStatus,
|
|
320
322
|
DataLayerContext,
|
|
321
323
|
DataLayerCoreContext,
|
|
324
|
+
DataLayerNestingContext,
|
|
322
325
|
DataLayerStatusContext,
|
|
326
|
+
createAdapterAutoDetector,
|
|
323
327
|
useDataLayer,
|
|
324
328
|
useDataLayerCore,
|
|
325
329
|
useDataLayerOptional,
|
|
326
330
|
useDataLayerStatus,
|
|
327
331
|
useDbQuery,
|
|
328
332
|
useDbQueryById
|
|
329
|
-
} from "./chunk-
|
|
333
|
+
} from "./chunk-L4DFVMTS.js";
|
|
330
334
|
import "./chunk-RT4O5H2E.js";
|
|
331
|
-
import "./chunk-
|
|
335
|
+
import "./chunk-4PZ744G2.js";
|
|
332
336
|
import {
|
|
333
337
|
getSupabaseUrl,
|
|
334
338
|
setSupabaseUrl
|
|
@@ -409,6 +413,7 @@ export {
|
|
|
409
413
|
DataExchangeImport,
|
|
410
414
|
DataLayerContext,
|
|
411
415
|
DataLayerCoreContext,
|
|
416
|
+
DataLayerNestingContext,
|
|
412
417
|
DataLayerProvider,
|
|
413
418
|
DataLayerStatusContext,
|
|
414
419
|
Datasheet,
|
|
@@ -599,8 +604,10 @@ export {
|
|
|
599
604
|
findFilters,
|
|
600
605
|
findIndexOrdered,
|
|
601
606
|
findLastIndex,
|
|
607
|
+
generatePowerSyncAlias,
|
|
602
608
|
get,
|
|
603
609
|
getErrorBody,
|
|
610
|
+
getPowerSyncAlias,
|
|
604
611
|
getStorageUrl,
|
|
605
612
|
getSupabaseUrl,
|
|
606
613
|
getTable,
|
|
@@ -631,6 +638,7 @@ export {
|
|
|
631
638
|
setFilterValue,
|
|
632
639
|
setSupabaseUrl,
|
|
633
640
|
sortSearchParams,
|
|
641
|
+
stripSchemaPrefix,
|
|
634
642
|
typedSupabase,
|
|
635
643
|
useAI,
|
|
636
644
|
useAdvanceQuery,
|
package/dist/index.web.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
export { C as CompositeTypes, c as Constants, D as Database, E as Enums, J as Json, T as Tables, a as TablesInsert, b as TablesUpdate } from './database.types-ChFCG-4M.js';
|
|
2
2
|
export { a as FilterConfig, F as FilterConfigOption, G as Group, P as PropertyType, S as SortConfig, T as TableInfo, V as ValueForPropertyType, W as WhereFilter } from './FilterConfig-Bt2Ek74z.js';
|
|
3
|
-
import { u as useDbAdvanceFilterQuery, Q as QueryState } from './index-
|
|
4
|
-
export { r as BackendSelectionResult, B as BooleanOperator, k as ClarificationSuggestion, C as CombinedProviderStatus, j as ComputedSortConfig, n as DataLayerWithPowerSyncProps, D as DbChangeLog, E as EnhancedSyncControl, a as EnhancedSyncStatus, d as FilterConditionType, m as FilterContextType, g as FilterInput, h as FilterState, H as HasPowerSyncConfig, O as OrderColumn, P as PowerSyncEnabledConfig, b as PowerSyncEnabledContextValue, q as PowerSyncTables, U as UseDataLayerWithPowerSync, p as UseSyncControlWithPowerSync, o as UseSyncStatusWithPowerSync, V as ValueOrArrayForPropertyType, c as createCombinedStatus, s as normalizeFilter } from './index-
|
|
5
|
-
export {
|
|
3
|
+
import { u as useDbAdvanceFilterQuery, Q as QueryState } from './index-vwVJ0BWj.js';
|
|
4
|
+
export { r as BackendSelectionResult, B as BooleanOperator, k as ClarificationSuggestion, C as CombinedProviderStatus, j as ComputedSortConfig, n as DataLayerWithPowerSyncProps, D as DbChangeLog, E as EnhancedSyncControl, a as EnhancedSyncStatus, d as FilterConditionType, m as FilterContextType, g as FilterInput, h as FilterState, H as HasPowerSyncConfig, O as OrderColumn, P as PowerSyncEnabledConfig, b as PowerSyncEnabledContextValue, q as PowerSyncTables, U as UseDataLayerWithPowerSync, p as UseSyncControlWithPowerSync, o as UseSyncStatusWithPowerSync, V as ValueOrArrayForPropertyType, c as createCombinedStatus, s as normalizeFilter } from './index-vwVJ0BWj.js';
|
|
5
|
+
export { G as AIOptions, H as AIResponse, v as AdapterRegistry, Z as AlertProps, A as AttachmentQueueProvider, P as BUCKETS, Q as BucketName, O as CustomPageQueryResult, V as DEFAULT_QUERY_TIMEOUT, ag as FeedbackListItem, ah as FeedbackListParams, _ as LiveChangeContext, $ as LiveChangeContextProvider, J as ServerAvailabilityState, k as StorageQueueContext, m as StorageQueueContextValue, S as StorageQueueProvider, j as StorageQueueProviderProps, aj as SubmitFeedbackParams, B as SupabaseAdapter, T as TIMEOUT_ERROR_MESSAGE, M as UpdateOptions, U as UseAutosaveOptions, d as UseAutosaveResult, am as UseDbPartialQueryResult, X as UseDbRealtimeQueryResult, q as UseMutationSuccessOptions, h as UseStorageSourceOptions, i as UseStorageSourceResult, Y as convertFilterToRealtimeQuery, w as createAdapterRegistry, R as createInCondition, C as createSupabaseAdapter, N as executeAdvanceQuery, F as getErrorBody, g as getStorageUrl, p as getSupabaseUrl, W as isTimeoutError, n as newTimeActivity, s as setSupabaseUrl, I as useAI, ak as useApplyFeedback, c as useAutosave, b as useAutosaveState, ab as useChangelogById, ac as useChangelogBySlug, ad as useChangelogEntries, ae as useChangelogMedia, a9 as useChangelogs, an as useDbPartialQuery, o as useDbRealtimeQuery, a1 as useDeleteChangelog, a4 as useDeleteChangelogEntry, a7 as useDeleteChangelogMedia, af as useFeedbackList, a as useLatestOperationLog, u as useLiveChangeTracking, a5 as useMultiDeleteChangelogEntries, a3 as useMultiUpsertChangelogEntries, r as useMutationSuccess, t as useMutationSuccessRN, aa as usePublishedChangelogs, o as useRealtimeQuery, al as useResolveFeedback, L as useSearchQuery, K as useServerAvailability, l as useStorageQueueContext, f as useStorageSource, ai as useSubmitFeedback, e as useToastError, a8 as useUploadChangelogMedia, a0 as useUpsertChangelog, a2 as useUpsertChangelogEntry, a6 as useUpsertChangelogMedia } from './useResolveFeedback-thFi-4h8.js';
|
|
6
6
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
7
7
|
import { UseInfiniteQueryOptions, InfiniteData, UseQueryOptions, QueryClient } from '@tanstack/react-query';
|
|
8
8
|
import { D as Database } from './useSupabase-DSZNeXnF.js';
|
|
@@ -14,15 +14,14 @@ export { F as Fetch, i as GenericFunction, g as GenericNonUpdatableView, f as Ge
|
|
|
14
14
|
import { PostgrestSingleResponse, RealtimePostgresChangesPayload, SupabaseClient } from '@supabase/supabase-js';
|
|
15
15
|
import { useInsertMutation, useUpdateMutation } from '@supabase-cache-helpers/postgrest-react-query';
|
|
16
16
|
export { U as UseDbQuerySingleReturn, u as useDbQuery } from './useDbQuery-C-TL8jY1.js';
|
|
17
|
-
export { C as ClarificationQuestion, D as DatabaseTypes, F as Filter, x as FilterGroup, y as FilterOperator, z as Pagination, P as PublicTableNames, Q as QueryState, R as ResolveRowType, S as SchemaNames, m as SchemaTableNames, A as Sort, T as TableIdentifier, U as UseAdvanceQueryOptions, n as UseAdvanceQueryResult, o as UseDbCountOptions, p as UseDbCountResult, K as UseDbDeleteOptions, L as UseDbDeleteResult, q as UseDbInfiniteQueryOptions, r as UseDbInfiniteQueryResult, B as UseDbInsertOptions, E as UseDbInsertResult, v as UseDbQueryByIdOptions, w as UseDbQueryByIdResult, s as UseDbQueryOptions, t as UseDbQueryResult, G as UseDbUpdateOptions, H as UseDbUpdateResult, I as UseDbUpsertOptions, J as UseDbUpsertResult, u as useAdvanceQuery, a as useDataLayer, c as useDataLayerOptional, e as useDbCount, e as useDbCountV3, f as useDbDeleteV3, g as useDbInfiniteQueryV3, h as useDbInsertV3, j as useDbQueryById, i as useDbQueryV3, k as useDbUpdateV3, l as useDbUpsert, l as useDbUpsertV3, l as useUpsert } from './useDbCount-
|
|
17
|
+
export { C as ClarificationQuestion, D as DatabaseTypes, F as Filter, x as FilterGroup, y as FilterOperator, z as Pagination, P as PublicTableNames, Q as QueryState, R as ResolveRowType, S as SchemaNames, m as SchemaTableNames, A as Sort, T as TableIdentifier, U as UseAdvanceQueryOptions, n as UseAdvanceQueryResult, o as UseDbCountOptions, p as UseDbCountResult, K as UseDbDeleteOptions, L as UseDbDeleteResult, q as UseDbInfiniteQueryOptions, r as UseDbInfiniteQueryResult, B as UseDbInsertOptions, E as UseDbInsertResult, v as UseDbQueryByIdOptions, w as UseDbQueryByIdResult, s as UseDbQueryOptions, t as UseDbQueryResult, G as UseDbUpdateOptions, H as UseDbUpdateResult, I as UseDbUpsertOptions, J as UseDbUpsertResult, u as useAdvanceQuery, a as useDataLayer, c as useDataLayerOptional, e as useDbCount, e as useDbCountV3, f as useDbDeleteV3, g as useDbInfiniteQueryV3, h as useDbInsertV3, j as useDbQueryById, i as useDbQueryV3, k as useDbUpdateV3, l as useDbUpsert, l as useDbUpsertV3, l as useUpsert } from './useDbCount-dCkdaBpP.js';
|
|
18
18
|
import { DataLayerConfig } from './core/index.js';
|
|
19
19
|
export { AdapterRegistry as AdapterRegistryInterface, AutoStrategy, BuiltQuery, CachedStrategy, ColumnInfo, ColumnType, ConnectionConfig, DataAdapter, DataLayerHooks, DatabaseSchema, DeleteMutationResult, ExplicitFkSpec, ExtractInsert, ExtractRow, ExtractUpdate, HybridStrategy, MutationHookResult, MutationResult, OrderBy, ParsedSelect, PowerSyncStrategy, QueryOptions, QueryResult, QuerySingleResult, RelationshipInfo, RelationshipType, ResolvedRelationship, ScopeDefinition, SelectColumn, SelectRelation, SupabaseStrategy, SyncControl, SyncSchedule, SyncScope, SyncStatus, TableNames, TableSchema, TableStrategy, UseDbMutationHook, UseDbQueryByIdHook, UseDbQueryHook, WhereClause, WhereOperators } from './core/index.js';
|
|
20
20
|
export { u as useBatchDelete, a as useBatchUpsert } from './useBatchUpsert-DAkiCNo3.js';
|
|
21
21
|
export { E as ExtractedExplicitFk, e as extractColumnNames, d as extractExplicitFkRelations, f as extractExplicitFkTables, a as extractRelationNames, g as getRelationSelect, b as hasExplicitFk, h as hasRelation, p as parseSelect, c as selectHasExplicitFkSyntax, s as stringifySelect, t as tokenizeTopLevel } from './select-parser-BAV7fOaM.js';
|
|
22
|
-
export { P as PowerSyncDatabase, Q as QueryExecutor, e as RelationJoinData, R as RelationshipResolver, b as ResultJoiner, S as SQLBuilder, f as createQueryExecutor, c as createRelationshipResolver, d as createResultJoiner, a as createSQLBuilder } from './executor-
|
|
22
|
+
export { P as PowerSyncDatabase, Q as QueryExecutor, e as RelationJoinData, R as RelationshipResolver, b as ResultJoiner, S as SQLBuilder, T as TableAliasResolver, f as createQueryExecutor, c as createRelationshipResolver, d as createResultJoiner, a as createSQLBuilder } from './executor-Bu1OlqCl.js';
|
|
23
23
|
export { UsePartialAdvancedQueryResult, UsePartialQueryResult, UseQuerySingleReturn, useAdvancedFilterQuery, useAdvancedQuery, useInfiniteQuery, usePartialAdvancedQuery, usePartialQuery, useQuery } from './query/index.js';
|
|
24
|
-
|
|
25
|
-
export { f as ADAPTER_STRATEGIES, i as AdapterAutoDetector, c as AdapterCapabilities, a as AdapterConfig, d as AdapterDependencies, b as AdapterFactory, A as AdapterQueryResult, g as AdapterRegistry, e as AdapterStrategyType, k as AutoDetectionResult, l as AutoDetectorOptions, m as BackendChangeListener, B as BackendStatus, C as CapableDataAdapter, D as DataLayerContext, u as DataLayerStatus, T as TableDataAdapter, j as createAdapterAutoDetector, h as createAdapterRegistry } from './DataLayerContext-BYZtDD0g.js';
|
|
24
|
+
export { f as ADAPTER_STRATEGIES, g as AdapterAutoDetector, c as AdapterCapabilities, a as AdapterConfig, d as AdapterDependencies, b as AdapterFactory, A as AdapterQueryResult, e as AdapterStrategyType, i as AutoDetectionResult, j as AutoDetectorOptions, k as BackendChangeListener, B as BackendStatus, C as CapableDataAdapter, D as DataLayerContext, o as DataLayerContextValue, l as DataLayerCoreContext, p as DataLayerCoreContextValue, n as DataLayerNestingContext, r as DataLayerStatus, m as DataLayerStatusContext, q as DataLayerStatusContextValue, s as SimpleAdapterRegistry, T as TableDataAdapter, h as createAdapterAutoDetector } from './DataLayerContext-V5FotiSk.js';
|
|
26
25
|
import { ReactNode, JSX } from 'react';
|
|
27
26
|
export { B as BatchAnalysisProgress, E as ExtractedReceipt, P as PendingExpense, a as useReceiptAI, u as useSupabaseFunction } from './useReceiptAI-6HkRpRml.js';
|
|
28
27
|
export { e as UserMetadataContextProvider, c as UserMetadataContextType, a as UserMetadataInsert, U as UserMetadataRow, b as UserMetadataUpdate, u as useLiveChangesIndicator, h as useSetUserMetadata, f as useUserMetadata, i as useUserMetadataState, g as useUserMetadataValue, d as userMetadataContext } from './UserMetadataContext-pQb3A8_Q.js';
|
|
@@ -352,42 +351,9 @@ declare function useDbUpdate<TableName extends string & keyof PublicSchema["Tabl
|
|
|
352
351
|
}): _tanstack_react_query.UseMutationResult<RowResult, Error, ResultUpdate, unknown>;
|
|
353
352
|
|
|
354
353
|
/**
|
|
355
|
-
* V3 Data Layer Provider - Web/Browser Version
|
|
354
|
+
* V3 Data Layer Provider - Web/Browser Version - SIMPLIFIED
|
|
356
355
|
*
|
|
357
|
-
*
|
|
358
|
-
* This is a browser-safe version that excludes PowerSync dependencies.
|
|
359
|
-
*
|
|
360
|
-
* For React Native apps that need PowerSync, use the default DataLayerProvider instead.
|
|
361
|
-
*/
|
|
362
|
-
|
|
363
|
-
/**
|
|
364
|
-
* Props for DataLayerProvider (Web version)
|
|
365
|
-
*/
|
|
366
|
-
interface DataLayerProviderProps {
|
|
367
|
-
/** Data layer configuration */
|
|
368
|
-
config: DataLayerConfig;
|
|
369
|
-
/** Children to render */
|
|
370
|
-
children: ReactNode;
|
|
371
|
-
/** Supabase client (required) */
|
|
372
|
-
supabaseClient: SupabaseClient;
|
|
373
|
-
/** React Query client (required) */
|
|
374
|
-
queryClient: QueryClient;
|
|
375
|
-
/** Callback when initialization completes */
|
|
376
|
-
onInitialized?: (context: DataLayerContextValue) => void;
|
|
377
|
-
/** Callback when error occurs */
|
|
378
|
-
onError?: (error: Error) => void;
|
|
379
|
-
}
|
|
380
|
-
/**
|
|
381
|
-
* Provider component for the V3 data layer (Web/Browser version).
|
|
382
|
-
*
|
|
383
|
-
* This provider:
|
|
384
|
-
* - Creates and manages the AdapterRegistry
|
|
385
|
-
* - Initializes the AdapterAutoDetector for backend selection
|
|
386
|
-
* - Sets up Supabase adapter (PowerSync not supported in web builds)
|
|
387
|
-
* - Tracks online/offline status
|
|
388
|
-
* - Provides context for all V3 hooks
|
|
389
|
-
*
|
|
390
|
-
* Note: This is the browser-safe version that does NOT support PowerSync.
|
|
356
|
+
* Browser-safe version that excludes PowerSync dependencies.
|
|
391
357
|
* For React Native apps that need PowerSync, use the default DataLayerProvider.
|
|
392
358
|
*
|
|
393
359
|
* @example
|
|
@@ -407,6 +373,17 @@ interface DataLayerProviderProps {
|
|
|
407
373
|
* }
|
|
408
374
|
* ```
|
|
409
375
|
*/
|
|
410
|
-
declare function DataLayerProvider({ config, children, supabaseClient, queryClient, onInitialized, onError, }: DataLayerProviderProps): JSX.Element;
|
|
411
376
|
|
|
412
|
-
|
|
377
|
+
interface DataLayerProviderProps {
|
|
378
|
+
/** Data layer configuration */
|
|
379
|
+
config: DataLayerConfig;
|
|
380
|
+
/** Children to render */
|
|
381
|
+
children: ReactNode;
|
|
382
|
+
/** Supabase client (required) */
|
|
383
|
+
supabaseClient: SupabaseClient;
|
|
384
|
+
/** React Query client (required) */
|
|
385
|
+
queryClient: QueryClient;
|
|
386
|
+
}
|
|
387
|
+
declare function DataLayerProvider({ config, children, supabaseClient, queryClient, }: DataLayerProviderProps): JSX.Element;
|
|
388
|
+
|
|
389
|
+
export { DataLayerConfig, DataLayerProvider, type DataLayerProviderProps, GenericSchema, GenericTable, GenericView, GetResult, type UseDbPartialAdvanceQueryResult, useDbAdvanceFilterQuery, useDbAdvanceFilterQuery as useDbAdvanceQuery, useDbDelete, useDbInfiniteQuery, useDbInsert, useDbMultiDelete, useDbMultiUpsert, useDbPartialAdvanceQuery, useDbRealtime, useDbUpdate, useDbDelete as useDelete, useDbInsert as useInsert, useDbRealtime as useRealtime, useDbUpdate as useUpdate };
|