@vite-hub/realtime 0.0.4 → 0.1.0

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.
@@ -1,42 +0,0 @@
1
- import { WorkspaceSnapshot } from "@vite-hub/workspace";
2
-
3
- //#region src/types.d.ts
4
- interface RealtimeDefinition {
5
- auth?: boolean;
6
- document: {
7
- workspace: string;
8
- };
9
- history?: {
10
- checkpoint: true | {
11
- message?: string;
12
- };
13
- };
14
- }
15
- interface RealtimeCheckpoint {
16
- content: string;
17
- snapshot: WorkspaceSnapshot;
18
- }
19
- interface RealtimeModuleOptions {
20
- authority?: "auto" | "cloudflare" | "memory";
21
- projectRoot?: string;
22
- }
23
- interface RealtimePerson {
24
- clientId: number;
25
- color: string;
26
- id: string;
27
- image?: string;
28
- name: string;
29
- }
30
- type RealtimeWorkspaceChange = {
31
- operation: "create" | "delete" | "update";
32
- path: string;
33
- } | {
34
- operation: "move";
35
- from: string;
36
- to: string;
37
- };
38
- type RealtimeRegistry = Record<string, () => Promise<{
39
- default: RealtimeDefinition;
40
- }>>;
41
- //#endregion
42
- export { RealtimeRegistry as a, RealtimePerson as i, RealtimeDefinition as n, RealtimeWorkspaceChange as o, RealtimeModuleOptions as r, RealtimeCheckpoint as t };