type fixes
This commit is contained in:
@ -1,63 +1,65 @@
|
||||
// DB Types
|
||||
|
||||
export type User = {
|
||||
id: string
|
||||
name: string
|
||||
email: string
|
||||
generations: number
|
||||
sandbox: Sandbox[]
|
||||
usersToSandboxes: UsersToSandboxes[]
|
||||
}
|
||||
id: string;
|
||||
name: string;
|
||||
email: string;
|
||||
generations: number;
|
||||
sandbox: Sandbox[];
|
||||
usersToSandboxes: UsersToSandboxes[];
|
||||
};
|
||||
|
||||
export type Sandbox = {
|
||||
id: string
|
||||
name: string
|
||||
type: "react" | "node"
|
||||
visibility: "public" | "private"
|
||||
userId: string
|
||||
usersToSandboxes: UsersToSandboxes[]
|
||||
}
|
||||
id: string;
|
||||
name: string;
|
||||
type: "react" | "node";
|
||||
visibility: "public" | "private";
|
||||
createdAt: Date;
|
||||
userId: string;
|
||||
usersToSandboxes: UsersToSandboxes[];
|
||||
};
|
||||
|
||||
export type UsersToSandboxes = {
|
||||
userId: string
|
||||
sandboxId: string
|
||||
}
|
||||
userId: string;
|
||||
sandboxId: string;
|
||||
sharedOn: Date;
|
||||
};
|
||||
|
||||
export type R2Files = {
|
||||
objects: R2FileData[]
|
||||
truncated: boolean
|
||||
delimitedPrefixes: any[]
|
||||
}
|
||||
objects: R2FileData[];
|
||||
truncated: boolean;
|
||||
delimitedPrefixes: any[];
|
||||
};
|
||||
|
||||
export type R2FileData = {
|
||||
storageClass: string
|
||||
uploaded: string
|
||||
checksums: any
|
||||
httpEtag: string
|
||||
etag: string
|
||||
size: number
|
||||
version: string
|
||||
key: string
|
||||
}
|
||||
storageClass: string;
|
||||
uploaded: string;
|
||||
checksums: any;
|
||||
httpEtag: string;
|
||||
etag: string;
|
||||
size: number;
|
||||
version: string;
|
||||
key: string;
|
||||
};
|
||||
|
||||
export type TFolder = {
|
||||
id: string
|
||||
type: "folder"
|
||||
name: string
|
||||
children: (TFile | TFolder)[]
|
||||
}
|
||||
id: string;
|
||||
type: "folder";
|
||||
name: string;
|
||||
children: (TFile | TFolder)[];
|
||||
};
|
||||
|
||||
export type TFile = {
|
||||
id: string
|
||||
type: "file"
|
||||
name: string
|
||||
}
|
||||
id: string;
|
||||
type: "file";
|
||||
name: string;
|
||||
};
|
||||
|
||||
export type TTab = TFile & {
|
||||
saved: boolean
|
||||
}
|
||||
saved: boolean;
|
||||
};
|
||||
|
||||
export type TFileData = {
|
||||
id: string
|
||||
data: string
|
||||
}
|
||||
id: string;
|
||||
data: string;
|
||||
};
|
||||
|
Reference in New Issue
Block a user