shadcn 4.6.0 → 4.8.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.
package/dist/mcp/index.js CHANGED
@@ -1 +1 @@
1
- export{b as server}from'../chunk-KJ7WG52C.js';import'../chunk-42UQOK2K.js';import'../chunk-HW2MEAJZ.js';import'../chunk-WLJDV6SE.js';import'../chunk-CHWMSXYA.js';
1
+ export{a as server}from'../chunk-ZUN7SVYE.js';import'../chunk-AIZFRNVF.js';import'../chunk-3ORLOMOE.js';import'../chunk-WLJDV6SE.js';import'../chunk-CHWMSXYA.js';
@@ -25,6 +25,325 @@ declare function searchRegistries(registries: string[], options?: {
25
25
  };
26
26
  }>;
27
27
 
28
+ type LoadRegistryOptions = {
29
+ cwd?: string;
30
+ registryFile?: string;
31
+ };
32
+ declare function loadRegistry(options?: LoadRegistryOptions): Promise<{
33
+ items: ({
34
+ files: ({
35
+ path: string;
36
+ type: "registry:page" | "registry:file";
37
+ target: string;
38
+ } | {
39
+ path: string;
40
+ type: "registry:lib" | "registry:block" | "registry:component" | "registry:ui" | "registry:hook" | "registry:theme" | "registry:style" | "registry:item" | "registry:base" | "registry:font" | "registry:example" | "registry:internal";
41
+ target?: string | undefined;
42
+ })[] | undefined;
43
+ type: "registry:base";
44
+ name: string;
45
+ tailwind?: {
46
+ config?: {
47
+ content?: string[] | undefined;
48
+ theme?: Record<string, any> | undefined;
49
+ plugins?: string[] | undefined;
50
+ } | undefined;
51
+ } | undefined;
52
+ docs?: string | undefined;
53
+ $schema?: string | undefined;
54
+ config?: {
55
+ tailwind?: {
56
+ config?: string | undefined;
57
+ css?: string | undefined;
58
+ baseColor?: string | undefined;
59
+ cssVariables?: boolean | undefined;
60
+ prefix?: string | undefined;
61
+ } | undefined;
62
+ $schema?: string | undefined;
63
+ style?: string | undefined;
64
+ rsc?: boolean | undefined;
65
+ tsx?: boolean | undefined;
66
+ iconLibrary?: string | undefined;
67
+ rtl?: boolean | undefined;
68
+ menuColor?: "default" | "inverted" | "default-translucent" | "inverted-translucent" | undefined;
69
+ menuAccent?: "subtle" | "bold" | undefined;
70
+ aliases?: {
71
+ components?: string | undefined;
72
+ ui?: string | undefined;
73
+ utils?: string | undefined;
74
+ lib?: string | undefined;
75
+ hooks?: string | undefined;
76
+ } | undefined;
77
+ registries?: Record<string, string | {
78
+ url: string;
79
+ params?: Record<string, string> | undefined;
80
+ headers?: Record<string, string> | undefined;
81
+ }> | undefined;
82
+ } | undefined;
83
+ css?: Record<string, any> | undefined;
84
+ extends?: string | undefined;
85
+ title?: string | undefined;
86
+ author?: string | undefined;
87
+ description?: string | undefined;
88
+ dependencies?: string[] | undefined;
89
+ devDependencies?: string[] | undefined;
90
+ registryDependencies?: string[] | undefined;
91
+ cssVars?: {
92
+ theme?: Record<string, string> | undefined;
93
+ light?: Record<string, string> | undefined;
94
+ dark?: Record<string, string> | undefined;
95
+ } | undefined;
96
+ envVars?: Record<string, string> | undefined;
97
+ meta?: Record<string, any> | undefined;
98
+ categories?: string[] | undefined;
99
+ } | {
100
+ files: ({
101
+ path: string;
102
+ type: "registry:page" | "registry:file";
103
+ target: string;
104
+ } | {
105
+ path: string;
106
+ type: "registry:lib" | "registry:block" | "registry:component" | "registry:ui" | "registry:hook" | "registry:theme" | "registry:style" | "registry:item" | "registry:base" | "registry:font" | "registry:example" | "registry:internal";
107
+ target?: string | undefined;
108
+ })[] | undefined;
109
+ type: "registry:font";
110
+ name: string;
111
+ font: {
112
+ family: string;
113
+ provider: "google";
114
+ import: string;
115
+ variable: string;
116
+ weight?: string[] | undefined;
117
+ subsets?: string[] | undefined;
118
+ selector?: string | undefined;
119
+ dependency?: string | undefined;
120
+ };
121
+ tailwind?: {
122
+ config?: {
123
+ content?: string[] | undefined;
124
+ theme?: Record<string, any> | undefined;
125
+ plugins?: string[] | undefined;
126
+ } | undefined;
127
+ } | undefined;
128
+ docs?: string | undefined;
129
+ $schema?: string | undefined;
130
+ css?: Record<string, any> | undefined;
131
+ extends?: string | undefined;
132
+ title?: string | undefined;
133
+ author?: string | undefined;
134
+ description?: string | undefined;
135
+ dependencies?: string[] | undefined;
136
+ devDependencies?: string[] | undefined;
137
+ registryDependencies?: string[] | undefined;
138
+ cssVars?: {
139
+ theme?: Record<string, string> | undefined;
140
+ light?: Record<string, string> | undefined;
141
+ dark?: Record<string, string> | undefined;
142
+ } | undefined;
143
+ envVars?: Record<string, string> | undefined;
144
+ meta?: Record<string, any> | undefined;
145
+ categories?: string[] | undefined;
146
+ } | {
147
+ files: ({
148
+ path: string;
149
+ type: "registry:page" | "registry:file";
150
+ target: string;
151
+ } | {
152
+ path: string;
153
+ type: "registry:lib" | "registry:block" | "registry:component" | "registry:ui" | "registry:hook" | "registry:theme" | "registry:style" | "registry:item" | "registry:base" | "registry:font" | "registry:example" | "registry:internal";
154
+ target?: string | undefined;
155
+ })[] | undefined;
156
+ type: "registry:lib" | "registry:block" | "registry:component" | "registry:ui" | "registry:hook" | "registry:page" | "registry:file" | "registry:theme" | "registry:style" | "registry:item" | "registry:example" | "registry:internal";
157
+ name: string;
158
+ tailwind?: {
159
+ config?: {
160
+ content?: string[] | undefined;
161
+ theme?: Record<string, any> | undefined;
162
+ plugins?: string[] | undefined;
163
+ } | undefined;
164
+ } | undefined;
165
+ docs?: string | undefined;
166
+ $schema?: string | undefined;
167
+ css?: Record<string, any> | undefined;
168
+ extends?: string | undefined;
169
+ title?: string | undefined;
170
+ author?: string | undefined;
171
+ description?: string | undefined;
172
+ dependencies?: string[] | undefined;
173
+ devDependencies?: string[] | undefined;
174
+ registryDependencies?: string[] | undefined;
175
+ cssVars?: {
176
+ theme?: Record<string, string> | undefined;
177
+ light?: Record<string, string> | undefined;
178
+ dark?: Record<string, string> | undefined;
179
+ } | undefined;
180
+ envVars?: Record<string, string> | undefined;
181
+ meta?: Record<string, any> | undefined;
182
+ categories?: string[] | undefined;
183
+ })[];
184
+ name: string;
185
+ homepage: string;
186
+ $schema?: string | undefined;
187
+ include?: string[] | undefined;
188
+ }>;
189
+ declare function loadRegistryItem(itemName: string, options?: LoadRegistryOptions): Promise<{
190
+ type: "registry:base";
191
+ name: string;
192
+ tailwind?: {
193
+ config?: {
194
+ content?: string[] | undefined;
195
+ theme?: Record<string, any> | undefined;
196
+ plugins?: string[] | undefined;
197
+ } | undefined;
198
+ } | undefined;
199
+ docs?: string | undefined;
200
+ $schema?: string | undefined;
201
+ config?: {
202
+ tailwind?: {
203
+ config?: string | undefined;
204
+ css?: string | undefined;
205
+ baseColor?: string | undefined;
206
+ cssVariables?: boolean | undefined;
207
+ prefix?: string | undefined;
208
+ } | undefined;
209
+ $schema?: string | undefined;
210
+ style?: string | undefined;
211
+ rsc?: boolean | undefined;
212
+ tsx?: boolean | undefined;
213
+ iconLibrary?: string | undefined;
214
+ rtl?: boolean | undefined;
215
+ menuColor?: "default" | "inverted" | "default-translucent" | "inverted-translucent" | undefined;
216
+ menuAccent?: "subtle" | "bold" | undefined;
217
+ aliases?: {
218
+ components?: string | undefined;
219
+ ui?: string | undefined;
220
+ utils?: string | undefined;
221
+ lib?: string | undefined;
222
+ hooks?: string | undefined;
223
+ } | undefined;
224
+ registries?: Record<string, string | {
225
+ url: string;
226
+ params?: Record<string, string> | undefined;
227
+ headers?: Record<string, string> | undefined;
228
+ }> | undefined;
229
+ } | undefined;
230
+ css?: Record<string, any> | undefined;
231
+ extends?: string | undefined;
232
+ title?: string | undefined;
233
+ author?: string | undefined;
234
+ description?: string | undefined;
235
+ dependencies?: string[] | undefined;
236
+ devDependencies?: string[] | undefined;
237
+ registryDependencies?: string[] | undefined;
238
+ files?: ({
239
+ path: string;
240
+ type: "registry:page" | "registry:file";
241
+ target: string;
242
+ content?: string | undefined;
243
+ } | {
244
+ path: string;
245
+ type: "registry:lib" | "registry:block" | "registry:component" | "registry:ui" | "registry:hook" | "registry:theme" | "registry:style" | "registry:item" | "registry:base" | "registry:font" | "registry:example" | "registry:internal";
246
+ content?: string | undefined;
247
+ target?: string | undefined;
248
+ })[] | undefined;
249
+ cssVars?: {
250
+ theme?: Record<string, string> | undefined;
251
+ light?: Record<string, string> | undefined;
252
+ dark?: Record<string, string> | undefined;
253
+ } | undefined;
254
+ envVars?: Record<string, string> | undefined;
255
+ meta?: Record<string, any> | undefined;
256
+ categories?: string[] | undefined;
257
+ } | {
258
+ type: "registry:font";
259
+ name: string;
260
+ font: {
261
+ family: string;
262
+ provider: "google";
263
+ import: string;
264
+ variable: string;
265
+ weight?: string[] | undefined;
266
+ subsets?: string[] | undefined;
267
+ selector?: string | undefined;
268
+ dependency?: string | undefined;
269
+ };
270
+ tailwind?: {
271
+ config?: {
272
+ content?: string[] | undefined;
273
+ theme?: Record<string, any> | undefined;
274
+ plugins?: string[] | undefined;
275
+ } | undefined;
276
+ } | undefined;
277
+ docs?: string | undefined;
278
+ $schema?: string | undefined;
279
+ css?: Record<string, any> | undefined;
280
+ extends?: string | undefined;
281
+ title?: string | undefined;
282
+ author?: string | undefined;
283
+ description?: string | undefined;
284
+ dependencies?: string[] | undefined;
285
+ devDependencies?: string[] | undefined;
286
+ registryDependencies?: string[] | undefined;
287
+ files?: ({
288
+ path: string;
289
+ type: "registry:page" | "registry:file";
290
+ target: string;
291
+ content?: string | undefined;
292
+ } | {
293
+ path: string;
294
+ type: "registry:lib" | "registry:block" | "registry:component" | "registry:ui" | "registry:hook" | "registry:theme" | "registry:style" | "registry:item" | "registry:base" | "registry:font" | "registry:example" | "registry:internal";
295
+ content?: string | undefined;
296
+ target?: string | undefined;
297
+ })[] | undefined;
298
+ cssVars?: {
299
+ theme?: Record<string, string> | undefined;
300
+ light?: Record<string, string> | undefined;
301
+ dark?: Record<string, string> | undefined;
302
+ } | undefined;
303
+ envVars?: Record<string, string> | undefined;
304
+ meta?: Record<string, any> | undefined;
305
+ categories?: string[] | undefined;
306
+ } | {
307
+ type: "registry:lib" | "registry:block" | "registry:component" | "registry:ui" | "registry:hook" | "registry:page" | "registry:file" | "registry:theme" | "registry:style" | "registry:item" | "registry:example" | "registry:internal";
308
+ name: string;
309
+ tailwind?: {
310
+ config?: {
311
+ content?: string[] | undefined;
312
+ theme?: Record<string, any> | undefined;
313
+ plugins?: string[] | undefined;
314
+ } | undefined;
315
+ } | undefined;
316
+ docs?: string | undefined;
317
+ $schema?: string | undefined;
318
+ css?: Record<string, any> | undefined;
319
+ extends?: string | undefined;
320
+ title?: string | undefined;
321
+ author?: string | undefined;
322
+ description?: string | undefined;
323
+ dependencies?: string[] | undefined;
324
+ devDependencies?: string[] | undefined;
325
+ registryDependencies?: string[] | undefined;
326
+ files?: ({
327
+ path: string;
328
+ type: "registry:page" | "registry:file";
329
+ target: string;
330
+ content?: string | undefined;
331
+ } | {
332
+ path: string;
333
+ type: "registry:lib" | "registry:block" | "registry:component" | "registry:ui" | "registry:hook" | "registry:theme" | "registry:style" | "registry:item" | "registry:base" | "registry:font" | "registry:example" | "registry:internal";
334
+ content?: string | undefined;
335
+ target?: string | undefined;
336
+ })[] | undefined;
337
+ cssVars?: {
338
+ theme?: Record<string, string> | undefined;
339
+ light?: Record<string, string> | undefined;
340
+ dark?: Record<string, string> | undefined;
341
+ } | undefined;
342
+ envVars?: Record<string, string> | undefined;
343
+ meta?: Record<string, any> | undefined;
344
+ categories?: string[] | undefined;
345
+ }>;
346
+
28
347
  declare const RegistryErrorCode: {
29
348
  readonly NETWORK_ERROR: "NETWORK_ERROR";
30
349
  readonly NOT_FOUND: "NOT_FOUND";
@@ -89,12 +408,32 @@ declare class RegistryNotConfiguredError extends RegistryError {
89
408
  }
90
409
  declare class RegistryLocalFileError extends RegistryError {
91
410
  readonly filePath: string;
92
- constructor(filePath: string, cause?: unknown);
411
+ constructor(filePath: string, cause?: unknown, options?: {
412
+ message?: string;
413
+ context?: Record<string, unknown>;
414
+ suggestion?: string;
415
+ });
93
416
  }
94
417
  declare class RegistryParseError extends RegistryError {
95
418
  readonly item: string;
96
419
  readonly parseError: unknown;
97
- constructor(item: string, parseError: unknown);
420
+ constructor(item: string, parseError: unknown, options?: {
421
+ subject?: string;
422
+ context?: Record<string, unknown>;
423
+ suggestion?: string;
424
+ });
425
+ }
426
+ declare class RegistryValidationError extends RegistryError {
427
+ constructor(message: string, options?: {
428
+ registryFile?: string;
429
+ cause?: unknown;
430
+ context?: Record<string, unknown>;
431
+ suggestion?: string;
432
+ });
433
+ }
434
+ declare class RegistryItemNotFoundError extends RegistryError {
435
+ readonly itemName: string;
436
+ constructor(itemName: string);
98
437
  }
99
438
  declare class RegistryMissingEnvironmentVariablesError extends RegistryError {
100
439
  readonly registryName: string;
@@ -110,4 +449,4 @@ declare class RegistriesIndexParseError extends RegistryError {
110
449
  constructor(parseError: unknown);
111
450
  }
112
451
 
113
- export { RegistriesIndexParseError, RegistryError, RegistryFetchError, RegistryForbiddenError, RegistryInvalidNamespaceError, RegistryLocalFileError, RegistryMissingEnvironmentVariablesError, RegistryNotConfiguredError, RegistryNotFoundError, RegistryParseError, RegistryUnauthorizedError, searchRegistries };
452
+ export { type LoadRegistryOptions, RegistriesIndexParseError, RegistryError, RegistryErrorCode, RegistryFetchError, RegistryForbiddenError, RegistryInvalidNamespaceError, RegistryItemNotFoundError, RegistryLocalFileError, RegistryMissingEnvironmentVariablesError, RegistryNotConfiguredError, RegistryNotFoundError, RegistryParseError, RegistryUnauthorizedError, RegistryValidationError, loadRegistry, loadRegistryItem, searchRegistries };
@@ -1 +1 @@
1
- export{p as RegistriesIndexParseError,f as RegistryError,j as RegistryFetchError,i as RegistryForbiddenError,o as RegistryInvalidNamespaceError,l as RegistryLocalFileError,n as RegistryMissingEnvironmentVariablesError,k as RegistryNotConfiguredError,g as RegistryNotFoundError,m as RegistryParseError,h as RegistryUnauthorizedError,ma as getRegistries,na as getRegistriesIndex,aa as getRegistry,ba as getRegistryItems,ca as resolveRegistryItems,va as searchRegistries}from'../chunk-42UQOK2K.js';import'../chunk-HW2MEAJZ.js';import'../chunk-WLJDV6SE.js';import'../chunk-CHWMSXYA.js';
1
+ export{v as RegistriesIndexParseError,j as RegistryError,i as RegistryErrorCode,n as RegistryFetchError,m as RegistryForbiddenError,u as RegistryInvalidNamespaceError,s as RegistryItemNotFoundError,p as RegistryLocalFileError,t as RegistryMissingEnvironmentVariablesError,o as RegistryNotConfiguredError,k as RegistryNotFoundError,q as RegistryParseError,l as RegistryUnauthorizedError,r as RegistryValidationError,ya as getRegistries,za as getRegistriesIndex,ma as getRegistry,na as getRegistryItems,Ga as loadRegistry,Ha as loadRegistryItem,oa as resolveRegistryItems,La as searchRegistries}from'../chunk-AIZFRNVF.js';import'../chunk-3ORLOMOE.js';import'../chunk-WLJDV6SE.js';import'../chunk-CHWMSXYA.js';