local-lite 0.0.3 → 0.0.4
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/README.md +421 -362
- package/dist/adapters/local/better-sqlite3.d.ts +2 -0
- package/dist/adapters/local/better-sqlite3.js +46 -25
- package/dist/adapters/local/expo-sqlite.d.ts +5 -1
- package/dist/adapters/local/expo-sqlite.js +40 -7
- package/dist/adapters/local/index.d.ts +1 -0
- package/dist/adapters/local/node-sqlite.d.ts +2 -0
- package/dist/adapters/local/node-sqlite.js +45 -22
- package/dist/adapters/local/op-sqlite.d.ts +1 -0
- package/dist/adapters/local/op-sqlite.js +6 -0
- package/dist/adapters/local/sql-js.d.ts +1 -0
- package/dist/adapters/local/sql-js.js +5 -0
- package/dist/adapters/network/index.js +33 -0
- package/dist/adapters/remote/convex.d.ts +2 -2
- package/dist/adapters/remote/convex.js +8 -12
- package/dist/adapters/remote/demo.d.ts +1 -1
- package/dist/adapters/remote/demo.js +3 -0
- package/dist/adapters/remote/firestore.d.ts +3 -2
- package/dist/adapters/remote/firestore.js +69 -46
- package/dist/adapters/remote/index.d.ts +6 -4
- package/dist/adapters/remote/supabase.d.ts +34 -6
- package/dist/adapters/remote/supabase.js +340 -79
- package/dist/config/index.js +7 -10
- package/dist/config/resolve-local.js +12 -1
- package/dist/config/resolve-remote.js +33 -28
- package/dist/config/types.d.ts +30 -5
- package/dist/core/client.d.ts +86 -3
- package/dist/core/client.js +423 -41
- package/dist/core/index.d.ts +14 -0
- package/dist/core/index.js +29 -0
- package/dist/core/outbox-store.d.ts +8 -4
- package/dist/core/outbox-store.js +84 -65
- package/dist/core/query.d.ts +8 -0
- package/dist/core/query.js +37 -0
- package/dist/core/schema-manager.d.ts +9 -0
- package/dist/core/schema-manager.js +68 -0
- package/dist/core/sync-worker.d.ts +38 -1
- package/dist/core/sync-worker.js +351 -104
- package/dist/core/table-manager.js +26 -29
- package/dist/core/types.d.ts +8 -0
- package/dist/react/BenchmarkModal.d.ts +32 -0
- package/dist/react/BenchmarkModal.js +777 -0
- package/dist/react/SyncInspector.d.ts +31 -0
- package/dist/react/SyncInspector.js +655 -0
- package/dist/react/index.d.ts +51 -19
- package/dist/react/index.js +265 -105
- package/dist/react/runner.d.ts +7 -0
- package/dist/react/runner.js +42 -0
- package/dist/react/status.d.ts +24 -0
- package/dist/react/status.js +123 -0
- package/dist/react/theme.d.ts +18 -0
- package/dist/react/theme.js +46 -0
- package/dist/utils/logger.d.ts +4 -0
- package/dist/utils/logger.js +20 -0
- package/package.json +138 -133
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { LocalFirstClient } from '../core/client.js';
|
|
3
|
+
import { type SyncThemeColors } from './theme.js';
|
|
4
|
+
export interface SyncInspectorProps {
|
|
5
|
+
client: LocalFirstClient | null | undefined;
|
|
6
|
+
position?: 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left' | 'top' | 'bottom' | 'inline';
|
|
7
|
+
variant?: 'pill' | 'compact' | 'icon' | 'minimal';
|
|
8
|
+
initialOpen?: boolean;
|
|
9
|
+
fullWidth?: boolean;
|
|
10
|
+
enableBenchmark?: boolean;
|
|
11
|
+
onOpenBenchmark?: () => void;
|
|
12
|
+
style?: any;
|
|
13
|
+
theme?: 'auto' | 'dark' | 'light' | Partial<SyncThemeColors>;
|
|
14
|
+
alwaysVisible?: boolean;
|
|
15
|
+
renderTrigger?: (props: {
|
|
16
|
+
isOpen: boolean;
|
|
17
|
+
open: () => void;
|
|
18
|
+
status: any;
|
|
19
|
+
metrics: any;
|
|
20
|
+
statusColor: string;
|
|
21
|
+
statusLabel: string;
|
|
22
|
+
}) => React.ReactNode;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Universal Developer Inspector Component for local-lite.
|
|
26
|
+
* Respects device safe areas and active theme (dark/light/custom).
|
|
27
|
+
* Displays real-time outbox telemetry, connection status, metrics, and triggers manual push, pull, reset, and benchmarks.
|
|
28
|
+
*/
|
|
29
|
+
export declare function SyncInspector({ client, position, variant, initialOpen, enableBenchmark, onOpenBenchmark, style, theme, alwaysVisible, renderTrigger, }: SyncInspectorProps): React.JSX.Element | null;
|
|
30
|
+
export declare const SyncIndicator: typeof SyncInspector;
|
|
31
|
+
export type SyncIndicatorProps = SyncInspectorProps;
|