@kontexted/darwin-arm64 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.
Potentially problematic release.
This version of @kontexted/darwin-arm64 might be problematic. Click here for more details.
- package/bin/kontexted +0 -0
- package/bin/kontexted-migrate +0 -0
- package/migrations/postgresql/0000_mysterious_sharon_ventura.sql +219 -0
- package/migrations/postgresql/meta/0000_snapshot.json +1678 -0
- package/migrations/postgresql/meta/_journal.json +13 -0
- package/migrations/sqlite/0000_low_old_lace.sql +219 -0
- package/migrations/sqlite/meta/0000_snapshot.json +1587 -0
- package/migrations/sqlite/meta/_journal.json +13 -0
- package/package.json +22 -0
- package/public/assets/index-D7m-7Tv3.css +1 -0
- package/public/assets/index-zo0m3331.js +321 -0
- package/public/assets/index-zo0m3331.js.map +1 -0
- package/public/assets/react-vendor-Bz9DKma8.js +10 -0
- package/public/assets/react-vendor-Bz9DKma8.js.map +1 -0
- package/public/assets/state-vendor-BT1BogGT.js +18 -0
- package/public/assets/state-vendor-BT1BogGT.js.map +1 -0
- package/public/index.html +15 -0
- package/public/logo.png +0 -0
|
@@ -0,0 +1,219 @@
|
|
|
1
|
+
CREATE TABLE `account` (
|
|
2
|
+
`id` text PRIMARY KEY NOT NULL,
|
|
3
|
+
`userId` text NOT NULL,
|
|
4
|
+
`accountId` text NOT NULL,
|
|
5
|
+
`providerId` text NOT NULL,
|
|
6
|
+
`accessToken` text,
|
|
7
|
+
`refreshToken` text,
|
|
8
|
+
`idToken` text,
|
|
9
|
+
`accessTokenExpiresAt` integer,
|
|
10
|
+
`refreshTokenExpiresAt` integer,
|
|
11
|
+
`scope` text,
|
|
12
|
+
`password` text,
|
|
13
|
+
`createdAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
14
|
+
`updatedAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
15
|
+
FOREIGN KEY (`userId`) REFERENCES `user`(`id`) ON UPDATE no action ON DELETE cascade
|
|
16
|
+
);
|
|
17
|
+
--> statement-breakpoint
|
|
18
|
+
CREATE TABLE `jwks` (
|
|
19
|
+
`id` text PRIMARY KEY NOT NULL,
|
|
20
|
+
`publicKey` text NOT NULL,
|
|
21
|
+
`privateKey` text NOT NULL,
|
|
22
|
+
`createdAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
23
|
+
`expiresAt` integer
|
|
24
|
+
);
|
|
25
|
+
--> statement-breakpoint
|
|
26
|
+
CREATE TABLE `oauthAccessToken` (
|
|
27
|
+
`id` text PRIMARY KEY NOT NULL,
|
|
28
|
+
`token` text NOT NULL,
|
|
29
|
+
`clientId` text NOT NULL,
|
|
30
|
+
`sessionId` text,
|
|
31
|
+
`userId` text,
|
|
32
|
+
`referenceId` text,
|
|
33
|
+
`refreshId` text,
|
|
34
|
+
`expiresAt` integer,
|
|
35
|
+
`createdAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
36
|
+
`scopes` text NOT NULL,
|
|
37
|
+
FOREIGN KEY (`clientId`) REFERENCES `oauthApplication`(`clientId`) ON UPDATE no action ON DELETE cascade,
|
|
38
|
+
FOREIGN KEY (`sessionId`) REFERENCES `session`(`id`) ON UPDATE no action ON DELETE set null,
|
|
39
|
+
FOREIGN KEY (`userId`) REFERENCES `user`(`id`) ON UPDATE no action ON DELETE cascade,
|
|
40
|
+
FOREIGN KEY (`refreshId`) REFERENCES `oauthRefreshToken`(`id`) ON UPDATE no action ON DELETE set null
|
|
41
|
+
);
|
|
42
|
+
--> statement-breakpoint
|
|
43
|
+
CREATE UNIQUE INDEX `oauth_access_token_token_unique` ON `oauthAccessToken` (`token`);--> statement-breakpoint
|
|
44
|
+
CREATE INDEX `oauth_access_token_client_id_idx` ON `oauthAccessToken` (`clientId`);--> statement-breakpoint
|
|
45
|
+
CREATE INDEX `oauth_access_token_user_id_idx` ON `oauthAccessToken` (`userId`);--> statement-breakpoint
|
|
46
|
+
CREATE INDEX `oauth_access_token_session_id_idx` ON `oauthAccessToken` (`sessionId`);--> statement-breakpoint
|
|
47
|
+
CREATE TABLE `oauthApplication` (
|
|
48
|
+
`id` text PRIMARY KEY NOT NULL,
|
|
49
|
+
`clientId` text NOT NULL,
|
|
50
|
+
`clientSecret` text,
|
|
51
|
+
`disabled` integer DEFAULT false NOT NULL,
|
|
52
|
+
`skipConsent` integer,
|
|
53
|
+
`enableEndSession` integer,
|
|
54
|
+
`scopes` text,
|
|
55
|
+
`userId` text,
|
|
56
|
+
`createdAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
57
|
+
`updatedAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
58
|
+
`name` text NOT NULL,
|
|
59
|
+
`uri` text,
|
|
60
|
+
`icon` text,
|
|
61
|
+
`contacts` text,
|
|
62
|
+
`tos` text,
|
|
63
|
+
`policy` text,
|
|
64
|
+
`softwareId` text,
|
|
65
|
+
`softwareVersion` text,
|
|
66
|
+
`softwareStatement` text,
|
|
67
|
+
`redirectUris` text NOT NULL,
|
|
68
|
+
`postLogoutRedirectUris` text,
|
|
69
|
+
`tokenEndpointAuthMethod` text,
|
|
70
|
+
`grantTypes` text,
|
|
71
|
+
`responseTypes` text,
|
|
72
|
+
`public` integer,
|
|
73
|
+
`type` text,
|
|
74
|
+
`referenceId` text,
|
|
75
|
+
`metadata` text,
|
|
76
|
+
FOREIGN KEY (`userId`) REFERENCES `user`(`id`) ON UPDATE no action ON DELETE cascade
|
|
77
|
+
);
|
|
78
|
+
--> statement-breakpoint
|
|
79
|
+
CREATE UNIQUE INDEX `oauthApplication_clientId_unique` ON `oauthApplication` (`clientId`);--> statement-breakpoint
|
|
80
|
+
CREATE INDEX `oauth_application_user_id_idx` ON `oauthApplication` (`userId`);--> statement-breakpoint
|
|
81
|
+
CREATE TABLE `oauthConsent` (
|
|
82
|
+
`id` text PRIMARY KEY NOT NULL,
|
|
83
|
+
`clientId` text NOT NULL,
|
|
84
|
+
`userId` text,
|
|
85
|
+
`referenceId` text,
|
|
86
|
+
`scopes` text NOT NULL,
|
|
87
|
+
`createdAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
88
|
+
`updatedAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
89
|
+
FOREIGN KEY (`clientId`) REFERENCES `oauthApplication`(`clientId`) ON UPDATE no action ON DELETE cascade,
|
|
90
|
+
FOREIGN KEY (`userId`) REFERENCES `user`(`id`) ON UPDATE no action ON DELETE cascade
|
|
91
|
+
);
|
|
92
|
+
--> statement-breakpoint
|
|
93
|
+
CREATE INDEX `oauth_consent_client_id_idx` ON `oauthConsent` (`clientId`);--> statement-breakpoint
|
|
94
|
+
CREATE INDEX `oauth_consent_user_id_idx` ON `oauthConsent` (`userId`);--> statement-breakpoint
|
|
95
|
+
CREATE TABLE `oauthRefreshToken` (
|
|
96
|
+
`id` text PRIMARY KEY NOT NULL,
|
|
97
|
+
`token` text NOT NULL,
|
|
98
|
+
`clientId` text NOT NULL,
|
|
99
|
+
`sessionId` text,
|
|
100
|
+
`userId` text NOT NULL,
|
|
101
|
+
`referenceId` text,
|
|
102
|
+
`expiresAt` integer,
|
|
103
|
+
`createdAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
104
|
+
`revoked` integer,
|
|
105
|
+
`scopes` text NOT NULL,
|
|
106
|
+
FOREIGN KEY (`clientId`) REFERENCES `oauthApplication`(`clientId`) ON UPDATE no action ON DELETE cascade,
|
|
107
|
+
FOREIGN KEY (`sessionId`) REFERENCES `session`(`id`) ON UPDATE no action ON DELETE set null,
|
|
108
|
+
FOREIGN KEY (`userId`) REFERENCES `user`(`id`) ON UPDATE no action ON DELETE cascade
|
|
109
|
+
);
|
|
110
|
+
--> statement-breakpoint
|
|
111
|
+
CREATE UNIQUE INDEX `oauthRefreshToken_token_unique` ON `oauthRefreshToken` (`token`);--> statement-breakpoint
|
|
112
|
+
CREATE INDEX `oauth_refresh_token_client_id_idx` ON `oauthRefreshToken` (`clientId`);--> statement-breakpoint
|
|
113
|
+
CREATE INDEX `oauth_refresh_token_user_id_idx` ON `oauthRefreshToken` (`userId`);--> statement-breakpoint
|
|
114
|
+
CREATE INDEX `oauth_refresh_token_session_id_idx` ON `oauthRefreshToken` (`sessionId`);--> statement-breakpoint
|
|
115
|
+
CREATE TABLE `session` (
|
|
116
|
+
`id` text PRIMARY KEY NOT NULL,
|
|
117
|
+
`userId` text NOT NULL,
|
|
118
|
+
`token` text NOT NULL,
|
|
119
|
+
`expiresAt` integer NOT NULL,
|
|
120
|
+
`ipAddress` text,
|
|
121
|
+
`userAgent` text,
|
|
122
|
+
`createdAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
123
|
+
`updatedAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
124
|
+
FOREIGN KEY (`userId`) REFERENCES `user`(`id`) ON UPDATE no action ON DELETE cascade
|
|
125
|
+
);
|
|
126
|
+
--> statement-breakpoint
|
|
127
|
+
CREATE UNIQUE INDEX `session_token_unique` ON `session` (`token`);--> statement-breakpoint
|
|
128
|
+
CREATE TABLE `user` (
|
|
129
|
+
`id` text PRIMARY KEY NOT NULL,
|
|
130
|
+
`name` text,
|
|
131
|
+
`email` text NOT NULL,
|
|
132
|
+
`emailVerified` integer DEFAULT false NOT NULL,
|
|
133
|
+
`image` text,
|
|
134
|
+
`createdAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
135
|
+
`updatedAt` integer DEFAULT (unixepoch() * 1000) NOT NULL
|
|
136
|
+
);
|
|
137
|
+
--> statement-breakpoint
|
|
138
|
+
CREATE UNIQUE INDEX `user_email_unique` ON `user` (`email`);--> statement-breakpoint
|
|
139
|
+
CREATE TABLE `verification` (
|
|
140
|
+
`id` text PRIMARY KEY NOT NULL,
|
|
141
|
+
`identifier` text NOT NULL,
|
|
142
|
+
`value` text NOT NULL,
|
|
143
|
+
`expiresAt` integer NOT NULL,
|
|
144
|
+
`createdAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
145
|
+
`updatedAt` integer DEFAULT (unixepoch() * 1000) NOT NULL
|
|
146
|
+
);
|
|
147
|
+
--> statement-breakpoint
|
|
148
|
+
CREATE TABLE `workspaces` (
|
|
149
|
+
`id` integer PRIMARY KEY AUTOINCREMENT NOT NULL,
|
|
150
|
+
`slug` text NOT NULL,
|
|
151
|
+
`name` text NOT NULL,
|
|
152
|
+
`created_by_user_id` text NOT NULL,
|
|
153
|
+
`created_at` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
154
|
+
`updated_at` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
155
|
+
FOREIGN KEY (`created_by_user_id`) REFERENCES `user`(`id`) ON UPDATE no action ON DELETE no action
|
|
156
|
+
);
|
|
157
|
+
--> statement-breakpoint
|
|
158
|
+
CREATE UNIQUE INDEX `workspaces_slug_idx` ON `workspaces` (`slug`);--> statement-breakpoint
|
|
159
|
+
CREATE INDEX `workspaces_owner_idx` ON `workspaces` (`created_by_user_id`);--> statement-breakpoint
|
|
160
|
+
CREATE TABLE `folders` (
|
|
161
|
+
`id` integer PRIMARY KEY AUTOINCREMENT NOT NULL,
|
|
162
|
+
`public_id` text NOT NULL,
|
|
163
|
+
`workspace_id` integer NOT NULL,
|
|
164
|
+
`parent_id` integer,
|
|
165
|
+
`name` text NOT NULL,
|
|
166
|
+
`display_name` text NOT NULL,
|
|
167
|
+
`created_at` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
168
|
+
`updated_at` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
169
|
+
FOREIGN KEY (`workspace_id`) REFERENCES `workspaces`(`id`) ON UPDATE no action ON DELETE no action,
|
|
170
|
+
FOREIGN KEY (`parent_id`) REFERENCES `folders`(`id`) ON UPDATE no action ON DELETE no action
|
|
171
|
+
);
|
|
172
|
+
--> statement-breakpoint
|
|
173
|
+
CREATE UNIQUE INDEX `folders_public_id_unique` ON `folders` (`public_id`);--> statement-breakpoint
|
|
174
|
+
CREATE INDEX `folders_public_id_idx` ON `folders` (`public_id`);--> statement-breakpoint
|
|
175
|
+
CREATE INDEX `folders_workspace_parent_idx` ON `folders` (`workspace_id`,`parent_id`);--> statement-breakpoint
|
|
176
|
+
CREATE TABLE `notes` (
|
|
177
|
+
`id` integer PRIMARY KEY AUTOINCREMENT NOT NULL,
|
|
178
|
+
`public_id` text NOT NULL,
|
|
179
|
+
`workspace_id` integer NOT NULL,
|
|
180
|
+
`folder_id` integer,
|
|
181
|
+
`name` text NOT NULL,
|
|
182
|
+
`title` text NOT NULL,
|
|
183
|
+
`content` text NOT NULL,
|
|
184
|
+
`createdAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
185
|
+
`updatedAt` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
186
|
+
FOREIGN KEY (`workspace_id`) REFERENCES `workspaces`(`id`) ON UPDATE no action ON DELETE no action,
|
|
187
|
+
FOREIGN KEY (`folder_id`) REFERENCES `folders`(`id`) ON UPDATE no action ON DELETE no action
|
|
188
|
+
);
|
|
189
|
+
--> statement-breakpoint
|
|
190
|
+
CREATE UNIQUE INDEX `notes_public_id_unique` ON `notes` (`public_id`);--> statement-breakpoint
|
|
191
|
+
CREATE INDEX `notes_public_id_idx` ON `notes` (`public_id`);--> statement-breakpoint
|
|
192
|
+
CREATE INDEX `notes_workspace_folder_idx` ON `notes` (`workspace_id`,`folder_id`);--> statement-breakpoint
|
|
193
|
+
CREATE INDEX `notes_workspace_updated_idx` ON `notes` (`workspace_id`,`updatedAt`);--> statement-breakpoint
|
|
194
|
+
CREATE TABLE `revisions` (
|
|
195
|
+
`id` integer PRIMARY KEY AUTOINCREMENT NOT NULL,
|
|
196
|
+
`workspace_id` integer NOT NULL,
|
|
197
|
+
`note_id` integer NOT NULL,
|
|
198
|
+
`author_user_id` text NOT NULL,
|
|
199
|
+
`content` text NOT NULL,
|
|
200
|
+
`created_at` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
201
|
+
FOREIGN KEY (`workspace_id`) REFERENCES `workspaces`(`id`) ON UPDATE no action ON DELETE no action,
|
|
202
|
+
FOREIGN KEY (`note_id`) REFERENCES `notes`(`id`) ON UPDATE no action ON DELETE no action,
|
|
203
|
+
FOREIGN KEY (`author_user_id`) REFERENCES `user`(`id`) ON UPDATE no action ON DELETE no action
|
|
204
|
+
);
|
|
205
|
+
--> statement-breakpoint
|
|
206
|
+
CREATE INDEX `revisions_note_created_idx` ON `revisions` (`note_id`,`created_at`);--> statement-breakpoint
|
|
207
|
+
CREATE TABLE `note_line_blame` (
|
|
208
|
+
`note_id` integer NOT NULL,
|
|
209
|
+
`line_number` integer NOT NULL,
|
|
210
|
+
`author_user_id` text NOT NULL,
|
|
211
|
+
`revision_id` integer NOT NULL,
|
|
212
|
+
`touched_at` integer DEFAULT (unixepoch() * 1000) NOT NULL,
|
|
213
|
+
PRIMARY KEY(`note_id`, `line_number`),
|
|
214
|
+
FOREIGN KEY (`note_id`) REFERENCES `notes`(`id`) ON UPDATE no action ON DELETE no action,
|
|
215
|
+
FOREIGN KEY (`author_user_id`) REFERENCES `user`(`id`) ON UPDATE no action ON DELETE no action,
|
|
216
|
+
FOREIGN KEY (`revision_id`) REFERENCES `revisions`(`id`) ON UPDATE no action ON DELETE no action
|
|
217
|
+
);
|
|
218
|
+
--> statement-breakpoint
|
|
219
|
+
CREATE INDEX `note_line_blame_note_idx` ON `note_line_blame` (`note_id`);
|