@gentleduck/registers 0.1.1
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/CHANGELOG.md +7 -0
- package/LICENSE +21 -0
- package/index.ts +16 -0
- package/package.json +35 -0
- package/registry-blocks/index.ts +3 -0
- package/registry-blocks/registry-auth.ts +55 -0
- package/registry-blocks/registry-charts.ts +577 -0
- package/registry-blocks/registry-dashboards.ts +13 -0
- package/registry-colors/index.ts +3 -0
- package/registry-colors/registry-base-colors.ts +1721 -0
- package/registry-colors/registry-colors.dto.ts +68 -0
- package/registry-colors/registry-colors.ts +1810 -0
- package/registry-colors/registry-themes.ts +1086 -0
- package/registry-examples/index.ts +1 -0
- package/registry-examples/registry-examples.ts +398 -0
- package/registry-schema/index.ts +1 -0
- package/registry-schema/registry-schema.ts +93 -0
- package/registry-ui/index.ts +1 -0
- package/registry-ui/registry-ui.ts +385 -0
- package/styles.ts +8 -0
- package/tsconfig.json +15 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './registry-examples'
|
|
@@ -0,0 +1,398 @@
|
|
|
1
|
+
import type { RegistryEntry } from '../registry-schema'
|
|
2
|
+
|
|
3
|
+
export const registry_examples: RegistryEntry[] = [
|
|
4
|
+
{
|
|
5
|
+
files: [],
|
|
6
|
+
name: 'accordion-examples',
|
|
7
|
+
registryDependencies: ['accordion'],
|
|
8
|
+
root_folder: 'accordion',
|
|
9
|
+
type: 'registry:example',
|
|
10
|
+
},
|
|
11
|
+
{
|
|
12
|
+
files: [],
|
|
13
|
+
name: 'alert-examples',
|
|
14
|
+
registryDependencies: ['alert'],
|
|
15
|
+
root_folder: 'alert',
|
|
16
|
+
type: 'registry:example',
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
files: [],
|
|
20
|
+
name: 'alert-dialog-examples',
|
|
21
|
+
registryDependencies: ['alert-dialog'],
|
|
22
|
+
root_folder: 'alert-dialog',
|
|
23
|
+
type: 'registry:example',
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
files: [],
|
|
27
|
+
name: 'avatar-examples',
|
|
28
|
+
registryDependencies: ['avatar'],
|
|
29
|
+
root_folder: 'avatar',
|
|
30
|
+
type: 'registry:example',
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
files: [],
|
|
34
|
+
name: 'badge-examples',
|
|
35
|
+
registryDependencies: ['badge'],
|
|
36
|
+
root_folder: 'badge',
|
|
37
|
+
type: 'registry:example',
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
files: [],
|
|
41
|
+
name: 'button-examples',
|
|
42
|
+
registryDependencies: ['button'],
|
|
43
|
+
root_folder: 'button',
|
|
44
|
+
type: 'registry:example',
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
files: [],
|
|
48
|
+
name: 'breadcrumb-examples',
|
|
49
|
+
registryDependencies: ['breadcrumb'],
|
|
50
|
+
root_folder: 'breadcrumb',
|
|
51
|
+
type: 'registry:example',
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
files: [],
|
|
55
|
+
name: 'dialog-examples',
|
|
56
|
+
registryDependencies: ['dialog'],
|
|
57
|
+
root_folder: 'dialog',
|
|
58
|
+
type: 'registry:example',
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
files: [],
|
|
62
|
+
name: 'command-examples',
|
|
63
|
+
registryDependencies: ['command'],
|
|
64
|
+
root_folder: 'command',
|
|
65
|
+
type: 'registry:example',
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
files: [],
|
|
69
|
+
name: 'card-examples',
|
|
70
|
+
registryDependencies: ['card'],
|
|
71
|
+
root_folder: 'card',
|
|
72
|
+
type: 'registry:example',
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
files: [],
|
|
76
|
+
name: 'calendar-examples',
|
|
77
|
+
registryDependencies: ['calendar'],
|
|
78
|
+
root_folder: 'calendar',
|
|
79
|
+
type: 'registry:example',
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
files: [],
|
|
83
|
+
name: 'drawer-examples',
|
|
84
|
+
registryDependencies: ['drawer'],
|
|
85
|
+
root_folder: 'drawer',
|
|
86
|
+
type: 'registry:example',
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
files: [],
|
|
90
|
+
name: 'hover-card-examples',
|
|
91
|
+
registryDependencies: ['hover-card'],
|
|
92
|
+
root_folder: 'hover-card',
|
|
93
|
+
type: 'registry:example',
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
files: [],
|
|
97
|
+
name: 'input-examples',
|
|
98
|
+
registryDependencies: ['input'],
|
|
99
|
+
root_folder: 'input',
|
|
100
|
+
type: 'registry:example',
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
files: [],
|
|
104
|
+
name: 'label-examples',
|
|
105
|
+
registryDependencies: ['label'],
|
|
106
|
+
root_folder: 'label',
|
|
107
|
+
type: 'registry:example',
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
files: [],
|
|
111
|
+
name: 'progress-examples',
|
|
112
|
+
registryDependencies: ['progress'],
|
|
113
|
+
root_folder: 'progress',
|
|
114
|
+
type: 'registry:example',
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
files: [],
|
|
118
|
+
name: 'radio-group-examples',
|
|
119
|
+
registryDependencies: ['radio-group'],
|
|
120
|
+
root_folder: 'radio-group',
|
|
121
|
+
type: 'registry:example',
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
files: [],
|
|
125
|
+
name: 'scroll-area-examples',
|
|
126
|
+
registryDependencies: ['scroll-area'],
|
|
127
|
+
root_folder: 'scroll-area',
|
|
128
|
+
type: 'registry:example',
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
files: [],
|
|
132
|
+
name: 'select-examples',
|
|
133
|
+
registryDependencies: ['select'],
|
|
134
|
+
root_folder: 'select',
|
|
135
|
+
type: 'registry:example',
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
files: [],
|
|
139
|
+
name: 'separator-examples',
|
|
140
|
+
registryDependencies: ['separator'],
|
|
141
|
+
root_folder: 'separator',
|
|
142
|
+
type: 'registry:example',
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
files: [],
|
|
146
|
+
name: 'sheet-examples',
|
|
147
|
+
registryDependencies: ['sheet'],
|
|
148
|
+
root_folder: 'sheet',
|
|
149
|
+
type: 'registry:example',
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
files: [],
|
|
153
|
+
name: 'skeleton-examples',
|
|
154
|
+
registryDependencies: ['skeleton'],
|
|
155
|
+
root_folder: 'skeleton',
|
|
156
|
+
type: 'registry:example',
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
files: [],
|
|
160
|
+
name: 'slider-examples',
|
|
161
|
+
registryDependencies: ['slider'],
|
|
162
|
+
root_folder: 'slider',
|
|
163
|
+
type: 'registry:example',
|
|
164
|
+
},
|
|
165
|
+
{
|
|
166
|
+
files: [],
|
|
167
|
+
name: 'switch-examples',
|
|
168
|
+
registryDependencies: ['switch'],
|
|
169
|
+
root_folder: 'switch',
|
|
170
|
+
type: 'registry:example',
|
|
171
|
+
},
|
|
172
|
+
{
|
|
173
|
+
files: [],
|
|
174
|
+
name: 'sonner-examples',
|
|
175
|
+
registryDependencies: ['sonner'],
|
|
176
|
+
root_folder: 'sonner',
|
|
177
|
+
type: 'registry:example',
|
|
178
|
+
},
|
|
179
|
+
{
|
|
180
|
+
files: [],
|
|
181
|
+
name: 'tabs-examples',
|
|
182
|
+
registryDependencies: ['tabs'],
|
|
183
|
+
root_folder: 'tabs',
|
|
184
|
+
type: 'registry:example',
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
files: [],
|
|
188
|
+
name: 'textarea-examples',
|
|
189
|
+
registryDependencies: ['textarea'],
|
|
190
|
+
root_folder: 'textarea',
|
|
191
|
+
type: 'registry:example',
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
files: [],
|
|
195
|
+
name: 'toggle-examples',
|
|
196
|
+
registryDependencies: ['toggle'],
|
|
197
|
+
root_folder: 'toggle',
|
|
198
|
+
type: 'registry:example',
|
|
199
|
+
},
|
|
200
|
+
{
|
|
201
|
+
files: [],
|
|
202
|
+
name: 'toggle-group-examples',
|
|
203
|
+
registryDependencies: ['toggle-group'],
|
|
204
|
+
root_folder: 'toggle-group',
|
|
205
|
+
type: 'registry:example',
|
|
206
|
+
},
|
|
207
|
+
{
|
|
208
|
+
files: [],
|
|
209
|
+
name: 'tooltip-examples',
|
|
210
|
+
registryDependencies: ['tooltip'],
|
|
211
|
+
root_folder: 'tooltip',
|
|
212
|
+
type: 'registry:example',
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
files: [],
|
|
216
|
+
name: 'aspect-ratio-examples',
|
|
217
|
+
registryDependencies: ['aspect-ratio'],
|
|
218
|
+
root_folder: 'aspect-ratio',
|
|
219
|
+
type: 'registry:example',
|
|
220
|
+
},
|
|
221
|
+
{
|
|
222
|
+
files: [],
|
|
223
|
+
name: 'typography-examples',
|
|
224
|
+
registryDependencies: [],
|
|
225
|
+
// registryDependencies: ['typography'],
|
|
226
|
+
root_folder: 'typography',
|
|
227
|
+
type: 'registry:example',
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
files: [],
|
|
231
|
+
name: 'table-examples',
|
|
232
|
+
registryDependencies: ['table'],
|
|
233
|
+
root_folder: 'table',
|
|
234
|
+
type: 'registry:example',
|
|
235
|
+
},
|
|
236
|
+
{
|
|
237
|
+
files: [],
|
|
238
|
+
name: 'resizable-examples',
|
|
239
|
+
registryDependencies: ['resizable'],
|
|
240
|
+
root_folder: 'resizable',
|
|
241
|
+
type: 'registry:example',
|
|
242
|
+
},
|
|
243
|
+
{
|
|
244
|
+
files: [],
|
|
245
|
+
name: 'pagination-examples',
|
|
246
|
+
registryDependencies: ['pagination'],
|
|
247
|
+
root_folder: 'pagination',
|
|
248
|
+
type: 'registry:example',
|
|
249
|
+
},
|
|
250
|
+
|
|
251
|
+
{
|
|
252
|
+
files: [],
|
|
253
|
+
name: 'checkbox-examples',
|
|
254
|
+
registryDependencies: [],
|
|
255
|
+
root_folder: 'checkbox',
|
|
256
|
+
type: 'registry:example',
|
|
257
|
+
},
|
|
258
|
+
{
|
|
259
|
+
files: [],
|
|
260
|
+
name: 'carousel-examples',
|
|
261
|
+
registryDependencies: ['carousel'],
|
|
262
|
+
root_folder: 'carousel',
|
|
263
|
+
type: 'registry:example',
|
|
264
|
+
},
|
|
265
|
+
{
|
|
266
|
+
files: [],
|
|
267
|
+
name: 'date-picker-examples',
|
|
268
|
+
registryDependencies: ['calendar', 'popover', 'button'],
|
|
269
|
+
root_folder: 'date-picker',
|
|
270
|
+
type: 'registry:example',
|
|
271
|
+
},
|
|
272
|
+
{
|
|
273
|
+
files: [],
|
|
274
|
+
name: 'popover-examples',
|
|
275
|
+
registryDependencies: ['popover'],
|
|
276
|
+
root_folder: 'popover',
|
|
277
|
+
type: 'registry:example',
|
|
278
|
+
},
|
|
279
|
+
{
|
|
280
|
+
files: [],
|
|
281
|
+
name: 'menubar-examples',
|
|
282
|
+
registryDependencies: ['menubar'],
|
|
283
|
+
root_folder: 'menubar',
|
|
284
|
+
type: 'registry:example',
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
files: [],
|
|
288
|
+
name: 'dropdown-menu-examples',
|
|
289
|
+
registryDependencies: ['dropdown-menu'],
|
|
290
|
+
root_folder: 'dropdown-menu',
|
|
291
|
+
type: 'registry:example',
|
|
292
|
+
},
|
|
293
|
+
{
|
|
294
|
+
files: [],
|
|
295
|
+
name: 'combobox-examples',
|
|
296
|
+
registryDependencies: ['popover', 'command'],
|
|
297
|
+
root_folder: 'combobox',
|
|
298
|
+
type: 'registry:example',
|
|
299
|
+
},
|
|
300
|
+
{
|
|
301
|
+
files: [],
|
|
302
|
+
name: 'collapsible-examples',
|
|
303
|
+
registryDependencies: ['collapsible'],
|
|
304
|
+
root_folder: 'collapsible',
|
|
305
|
+
type: 'registry:example',
|
|
306
|
+
},
|
|
307
|
+
{
|
|
308
|
+
files: [],
|
|
309
|
+
name: 'input-otp-examples',
|
|
310
|
+
registryDependencies: ['input-otp'],
|
|
311
|
+
root_folder: 'input-otp',
|
|
312
|
+
type: 'registry:example',
|
|
313
|
+
},
|
|
314
|
+
{
|
|
315
|
+
files: [],
|
|
316
|
+
name: 'chart-examples',
|
|
317
|
+
registryDependencies: ['chart'],
|
|
318
|
+
root_folder: 'chart',
|
|
319
|
+
type: 'registry:example',
|
|
320
|
+
},
|
|
321
|
+
{
|
|
322
|
+
files: [],
|
|
323
|
+
name: 'navigation-menu-examples',
|
|
324
|
+
registryDependencies: ['navigation-menu'],
|
|
325
|
+
root_folder: 'navigation-menu',
|
|
326
|
+
type: 'registry:example',
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
files: [],
|
|
330
|
+
name: 'context-menu-examples',
|
|
331
|
+
registryDependencies: ['context-menu'],
|
|
332
|
+
root_folder: 'context-menu',
|
|
333
|
+
type: 'registry:example',
|
|
334
|
+
},
|
|
335
|
+
{
|
|
336
|
+
files: [],
|
|
337
|
+
name: 'data-table-examples',
|
|
338
|
+
registryDependencies: ['data-table', 'table'],
|
|
339
|
+
root_folder: 'data-table',
|
|
340
|
+
type: 'registry:example',
|
|
341
|
+
},
|
|
342
|
+
{
|
|
343
|
+
files: [],
|
|
344
|
+
name: 'cva-examples',
|
|
345
|
+
registryDependencies: [],
|
|
346
|
+
root_folder: 'cva',
|
|
347
|
+
type: 'registry:example',
|
|
348
|
+
},
|
|
349
|
+
{
|
|
350
|
+
files: [],
|
|
351
|
+
name: 'button-group-examples',
|
|
352
|
+
registryDependencies: ['button-group'],
|
|
353
|
+
root_folder: 'button-group',
|
|
354
|
+
type: 'registry:example',
|
|
355
|
+
},
|
|
356
|
+
{
|
|
357
|
+
files: [],
|
|
358
|
+
name: 'kbd-examples',
|
|
359
|
+
registryDependencies: ['kbd'],
|
|
360
|
+
root_folder: 'kbd',
|
|
361
|
+
type: 'registry:example',
|
|
362
|
+
},
|
|
363
|
+
{
|
|
364
|
+
files: [],
|
|
365
|
+
name: 'empty-examples',
|
|
366
|
+
registryDependencies: ['empty'],
|
|
367
|
+
root_folder: 'empty',
|
|
368
|
+
type: 'registry:example',
|
|
369
|
+
},
|
|
370
|
+
{
|
|
371
|
+
files: [],
|
|
372
|
+
name: 'field-examples',
|
|
373
|
+
registryDependencies: ['field'],
|
|
374
|
+
root_folder: 'field',
|
|
375
|
+
type: 'registry:example',
|
|
376
|
+
},
|
|
377
|
+
{
|
|
378
|
+
files: [],
|
|
379
|
+
name: 'item-examples',
|
|
380
|
+
registryDependencies: ['item'],
|
|
381
|
+
root_folder: 'item',
|
|
382
|
+
type: 'registry:example',
|
|
383
|
+
},
|
|
384
|
+
{
|
|
385
|
+
files: [],
|
|
386
|
+
name: 'input-group-examples',
|
|
387
|
+
registryDependencies: ['input-group'],
|
|
388
|
+
root_folder: 'input-group',
|
|
389
|
+
type: 'registry:example',
|
|
390
|
+
},
|
|
391
|
+
{
|
|
392
|
+
files: [],
|
|
393
|
+
name: 'theme-toggle-examples',
|
|
394
|
+
registryDependencies: [''],
|
|
395
|
+
root_folder: 'theme-toggle',
|
|
396
|
+
type: 'registry:example',
|
|
397
|
+
},
|
|
398
|
+
]
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './registry-schema'
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import { z } from 'zod'
|
|
2
|
+
|
|
3
|
+
export const REGISTRY_ITEM_TYPES = [
|
|
4
|
+
'registry:ui',
|
|
5
|
+
'registry:lib',
|
|
6
|
+
'registry:hook',
|
|
7
|
+
'registry:block',
|
|
8
|
+
'registry:example',
|
|
9
|
+
'registry:page',
|
|
10
|
+
] as const
|
|
11
|
+
|
|
12
|
+
export const registry_item_type_schema = z.enum(REGISTRY_ITEM_TYPES)
|
|
13
|
+
|
|
14
|
+
export const registry_item_file_schema = z.object({
|
|
15
|
+
content: z.string().optional(),
|
|
16
|
+
path: z.string(),
|
|
17
|
+
target: z.string().optional(),
|
|
18
|
+
type: registry_item_type_schema,
|
|
19
|
+
})
|
|
20
|
+
|
|
21
|
+
export type RegistryItemFile = z.infer<typeof registry_item_file_schema>
|
|
22
|
+
|
|
23
|
+
export const registry_item_tailwind_schema = z.object({
|
|
24
|
+
config: z.object({
|
|
25
|
+
content: z.array(z.string()).optional(),
|
|
26
|
+
plugins: z.array(z.string()).optional(),
|
|
27
|
+
theme: z.record(z.string(), z.any()).optional(),
|
|
28
|
+
}),
|
|
29
|
+
})
|
|
30
|
+
|
|
31
|
+
export const registry_item_css_vars_schema = z.object({
|
|
32
|
+
dark: z.record(z.string(), z.string()).optional(),
|
|
33
|
+
light: z.record(z.string(), z.string()).optional(),
|
|
34
|
+
})
|
|
35
|
+
|
|
36
|
+
export const block_chunk_schema = z.object({
|
|
37
|
+
code: z.string().optional(),
|
|
38
|
+
component: z.any(),
|
|
39
|
+
container: z
|
|
40
|
+
.object({
|
|
41
|
+
className: z.string().nullish(),
|
|
42
|
+
})
|
|
43
|
+
.optional(),
|
|
44
|
+
description: z.string(),
|
|
45
|
+
file: z.string(),
|
|
46
|
+
name: z.string(),
|
|
47
|
+
})
|
|
48
|
+
|
|
49
|
+
export const registry_entry_schema = z.object({
|
|
50
|
+
// chunks: z.array(block_chunk_schema).optional(),
|
|
51
|
+
// docs: z.string().optional(),
|
|
52
|
+
categories: z.array(z.string()).optional(),
|
|
53
|
+
cssVars: registry_item_css_vars_schema.optional(),
|
|
54
|
+
dependencies: z.array(z.string()).optional(),
|
|
55
|
+
description: z.string().optional(),
|
|
56
|
+
devDependencies: z.array(z.string()).optional(),
|
|
57
|
+
files: z.array(registry_item_file_schema).optional(),
|
|
58
|
+
name: z.string(),
|
|
59
|
+
registryDependencies: z.array(z.string()).optional(),
|
|
60
|
+
root_folder: z.string(),
|
|
61
|
+
source: z.string().optional(),
|
|
62
|
+
tailwind: registry_item_tailwind_schema.optional(),
|
|
63
|
+
type: registry_item_type_schema,
|
|
64
|
+
})
|
|
65
|
+
|
|
66
|
+
export type RegistryEntry = z.infer<typeof registry_entry_schema>
|
|
67
|
+
|
|
68
|
+
export const registry_schema = z.object({
|
|
69
|
+
blocks: z.array(registry_entry_schema),
|
|
70
|
+
examples: z.array(registry_entry_schema),
|
|
71
|
+
uis: z.array(registry_entry_schema),
|
|
72
|
+
//
|
|
73
|
+
// pages: z.array(registry_entry_schema),
|
|
74
|
+
})
|
|
75
|
+
|
|
76
|
+
export type Registry = z.infer<typeof registry_schema>
|
|
77
|
+
|
|
78
|
+
// TEST: NOTE: STILL NOT USED IN REAL
|
|
79
|
+
export const block_schema = registry_entry_schema.extend({
|
|
80
|
+
code: z.string(),
|
|
81
|
+
component: z.any(),
|
|
82
|
+
container: z
|
|
83
|
+
.object({
|
|
84
|
+
className: z.string().nullish(),
|
|
85
|
+
height: z.string().nullish(),
|
|
86
|
+
})
|
|
87
|
+
.optional(),
|
|
88
|
+
highlightedCode: z.string(),
|
|
89
|
+
type: z.literal('registry:block'),
|
|
90
|
+
})
|
|
91
|
+
export type Block = z.infer<typeof block_schema>
|
|
92
|
+
|
|
93
|
+
export type BlockChunk = z.infer<typeof block_chunk_schema>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './registry-ui'
|