@oxcide-ui/schema 0.0.3

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.
@@ -0,0 +1,58 @@
1
+
2
+ > @oxcide-ui/schema@0.0.3 build /home/runner/work/oxcide-ui/oxcide-ui/packages/schema
3
+ > pnpm type-sync && tsup src/index.ts --format esm,cjs --dts --clean
4
+
5
+
6
+ > @oxcide-ui/schema@0.0.3 type-sync /home/runner/work/oxcide-ui/oxcide-ui/packages/schema
7
+ > tsx scripts/sync-types.ts && pnpm lint:fix
8
+
9
+ 
10
+ 🚀 Starting type synchronization (Direct Mode)...
11
+ 
12
+ ⏳ Syncing badge.ts...
13
+ ✅ Successfully synced badge.ts
14
+ ⏳ Syncing box.ts...
15
+ ✅ Successfully synced box.ts
16
+ ⏳ Syncing button.ts...
17
+ ✅ Successfully synced button.ts
18
+ ⏳ Syncing checkbox.ts...
19
+ ✅ Successfully synced checkbox.ts
20
+ ⏳ Syncing dialog.ts...
21
+ ✅ Successfully synced dialog.ts
22
+ ⏳ Syncing icon.ts...
23
+ ✅ Successfully synced icon.ts
24
+ ⏳ Syncing input.ts...
25
+ ✅ Successfully synced input.ts
26
+ ⏳ Syncing radiobutton.ts...
27
+ ✅ Successfully synced radiobutton.ts
28
+ ⏳ Syncing stack.ts...
29
+ ✅ Successfully synced stack.ts
30
+ ⏳ Syncing switch.ts...
31
+ ✅ Successfully synced switch.ts
32
+ ⏳ Syncing tag.ts...
33
+ ✅ Successfully synced tag.ts
34
+ ⏳ Syncing toast.ts...
35
+ ✅ Successfully synced toast.ts
36
+ 
37
+ ✨ Type synchronization complete! Updated 12 files.
38
+ 
39
+
40
+ > @oxcide-ui/schema@0.0.3 lint:fix /home/runner/work/oxcide-ui/oxcide-ui/packages/schema
41
+ > biome check --write .
42
+
43
+ Checked 17 files in 68ms. Fixed 12 files.
44
+ CLI Building entry: src/index.ts
45
+ CLI Using tsconfig: tsconfig.json
46
+ CLI tsup v8.5.1
47
+ CLI Target: esnext
48
+ CLI Cleaning output folder
49
+ ESM Build start
50
+ CJS Build start
51
+ ESM dist/index.js 12.34 KB
52
+ ESM ⚡️ Build success in 67ms
53
+ CJS dist/index.cjs 16.32 KB
54
+ CJS ⚡️ Build success in 68ms
55
+ DTS Build start
56
+ DTS ⚡️ Build success in 2954ms
57
+ DTS dist/index.d.ts 208.74 KB
58
+ DTS dist/index.d.cts 208.74 KB
package/CHANGELOG.md ADDED
@@ -0,0 +1,15 @@
1
+ # @oxcide-ui/schema
2
+
3
+ ## 0.0.3
4
+
5
+ ### Patch Changes
6
+
7
+ - @oxcide-ui/icons@0.0.3
8
+
9
+ ## 0.0.2
10
+
11
+ ### Patch Changes
12
+
13
+ - 04c4ff6: feat: initial public release setup with automated CI/CD pipeline.
14
+ - Updated dependencies [04c4ff6]
15
+ - @oxcide-ui/icons@0.0.2
package/dist/index.cjs ADDED
@@ -0,0 +1,436 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+
20
+ // src/index.ts
21
+ var index_exports = {};
22
+ __export(index_exports, {
23
+ badgePropsSchema: () => badgePropsSchema,
24
+ boxPropsSchema: () => boxPropsSchema,
25
+ buttonPropsSchema: () => buttonPropsSchema,
26
+ checkboxPropsSchema: () => checkboxPropsSchema,
27
+ dialogPropsSchema: () => dialogPropsSchema,
28
+ getBadgeDefaults: () => getBadgeDefaults,
29
+ getBoxDefaults: () => getBoxDefaults,
30
+ getButtonDefaults: () => getButtonDefaults,
31
+ getCheckboxDefaults: () => getCheckboxDefaults,
32
+ getDialogDefaults: () => getDialogDefaults,
33
+ getIconDefaults: () => getIconDefaults,
34
+ getInputDefaults: () => getInputDefaults,
35
+ getRadioButtonDefaults: () => getRadioButtonDefaults,
36
+ getStackDefaults: () => getStackDefaults,
37
+ getSwitchDefaults: () => getSwitchDefaults,
38
+ getTagDefaults: () => getTagDefaults,
39
+ getToastDefaults: () => getToastDefaults,
40
+ iconPropsSchema: () => iconPropsSchema,
41
+ inputPropsSchema: () => inputPropsSchema,
42
+ radioButtonPropsSchema: () => radioButtonPropsSchema,
43
+ registryIndexSchema: () => registryIndexSchema,
44
+ registryItemFileSchema: () => registryItemFileSchema,
45
+ registryItemSchema: () => registryItemSchema,
46
+ stackPropsSchema: () => stackPropsSchema,
47
+ switchPropsSchema: () => switchPropsSchema,
48
+ tagPropsSchema: () => tagPropsSchema,
49
+ toastMessageSchema: () => toastMessageSchema,
50
+ toastPropsSchema: () => toastPropsSchema,
51
+ toastSeveritySchema: () => toastSeveritySchema
52
+ });
53
+ module.exports = __toCommonJS(index_exports);
54
+
55
+ // src/components/badge.ts
56
+ var import_zod = require("zod");
57
+ var badgePropsSchema = import_zod.z.object({
58
+ /** Severity / semantic color */
59
+ severity: import_zod.z.enum(["primary", "secondary", "success", "info", "warning", "danger", "help", "contrast"]).default("primary"),
60
+ /** Size */
61
+ size: import_zod.z.enum(["xs", "sm", "md", "lg", "xl"]).default("md"),
62
+ /** Value to display */
63
+ value: import_zod.z.union([import_zod.z.string(), import_zod.z.number()]).optional()
64
+ });
65
+ function getBadgeDefaults(props = {}) {
66
+ return badgePropsSchema.parse(props);
67
+ }
68
+
69
+ // src/components/box.ts
70
+ var import_zod2 = require("zod");
71
+ var boxPropsSchema = import_zod2.z.object({
72
+ as: import_zod2.z.string().default("div")
73
+ });
74
+ function getBoxDefaults(props = {}) {
75
+ return boxPropsSchema.parse(props);
76
+ }
77
+
78
+ // src/components/button.ts
79
+ var import_zod3 = require("zod");
80
+ var buttonPropsSchema = import_zod3.z.object({
81
+ /** Visual variant */
82
+ variant: import_zod3.z.enum(["solid", "outline", "ghost", "link"]).default("solid"),
83
+ /** Size */
84
+ size: import_zod3.z.enum(["xs", "sm", "md", "lg", "xl"]).default("md"),
85
+ /** Severity / semantic color */
86
+ severity: import_zod3.z.enum(["primary", "secondary", "success", "info", "warning", "danger", "help", "contrast"]).default("primary"),
87
+ /** Disabled state */
88
+ disabled: import_zod3.z.boolean().default(false),
89
+ /** Loading state */
90
+ loading: import_zod3.z.boolean().default(false),
91
+ /** Icon name from the library */
92
+ icon: import_zod3.z.string().optional(),
93
+ /** Icon position relative to label */
94
+ iconPos: import_zod3.z.enum(["left", "right"]).default("left"),
95
+ /** Loading icon name */
96
+ loadingIcon: import_zod3.z.string().optional().default("spinner"),
97
+ /** Button label text */
98
+ label: import_zod3.z.string().optional(),
99
+ /** Render as rounded pill */
100
+ rounded: import_zod3.z.boolean().default(false),
101
+ /** Render as text-only (no background/border) */
102
+ text: import_zod3.z.boolean().default(false),
103
+ /** Render as raised with shadow */
104
+ raised: import_zod3.z.boolean().default(false)
105
+ });
106
+ function getButtonDefaults(props = {}) {
107
+ return buttonPropsSchema.parse(props);
108
+ }
109
+
110
+ // src/components/checkbox.ts
111
+ var import_zod4 = require("zod");
112
+ var checkboxPropsSchema = import_zod4.z.object({
113
+ /** V-model value */
114
+ modelValue: import_zod4.z.any().optional(),
115
+ /** Value for array-based checkboxes */
116
+ value: import_zod4.z.any().optional(),
117
+ /** Value when checked */
118
+ onValue: import_zod4.z.any().default(true),
119
+ /** Value when unchecked */
120
+ offValue: import_zod4.z.any().default(false),
121
+ /** Treat modelValue as boolean regardless of value or switch to boolean mode */
122
+ binary: import_zod4.z.boolean().default(false),
123
+ /** Disabled state */
124
+ disabled: import_zod4.z.boolean().default(false),
125
+ /** Invalid / Error state */
126
+ invalid: import_zod4.z.boolean().default(false),
127
+ /** Readonly state */
128
+ readonly: import_zod4.z.boolean().default(false),
129
+ /** Label text (next to checkbox) */
130
+ label: import_zod4.z.string().optional(),
131
+ /** Position of the label */
132
+ labelPosition: import_zod4.z.enum(["left", "right"]).default("right"),
133
+ /** Custom icon when checked */
134
+ icon: import_zod4.z.string().optional(),
135
+ /** Indeterminate state */
136
+ indeterminate: import_zod4.z.boolean().default(false),
137
+ /** Size */
138
+ size: import_zod4.z.enum(["sm", "md", "lg"]).default("md"),
139
+ /** Severity */
140
+ severity: import_zod4.z.enum(["primary", "secondary", "success", "info", "warning", "danger", "help", "contrast"]).default("primary"),
141
+ /** Native name attribute */
142
+ name: import_zod4.z.string().optional(),
143
+ /** Native id attribute */
144
+ id: import_zod4.z.string().optional()
145
+ });
146
+ function getCheckboxDefaults(props = {}) {
147
+ return checkboxPropsSchema.parse(props);
148
+ }
149
+
150
+ // src/components/dialog.ts
151
+ var import_zod5 = require("zod");
152
+ var dialogPropsSchema = import_zod5.z.object({
153
+ /** Modal visibility */
154
+ visible: import_zod5.z.boolean().default(false),
155
+ /** Header text */
156
+ header: import_zod5.z.string().optional(),
157
+ /** Footer text */
158
+ footer: import_zod5.z.string().optional(),
159
+ /** Whether the dialog can be closed */
160
+ closable: import_zod5.z.boolean().default(true),
161
+ /** Custom icon for the close button */
162
+ closeIcon: import_zod5.z.string().default("times"),
163
+ /** Whether clicking the mask closes the dialog */
164
+ dismissableMask: import_zod5.z.boolean().default(false),
165
+ /** Whether to close on Escape key */
166
+ closeOnEscape: import_zod5.z.boolean().default(true),
167
+ /** Teleport target selector or element */
168
+ appendTo: import_zod5.z.any().default("#teleports"),
169
+ /** Style class for the mask */
170
+ maskClass: import_zod5.z.string().optional(),
171
+ /** Modal state */
172
+ modal: import_zod5.z.boolean().default(true),
173
+ /** Whether to show the header */
174
+ showHeader: import_zod5.z.boolean().default(true),
175
+ /** Custom style object */
176
+ style: import_zod5.z.any().optional(),
177
+ /** Custom class name */
178
+ class: import_zod5.z.any().optional(),
179
+ /** Dialog position */
180
+ position: import_zod5.z.enum(["center", "top", "bottom", "left", "right", "top-left", "top-right", "bottom-left", "bottom-right"]).default("center"),
181
+ /** Native id attribute */
182
+ id: import_zod5.z.string().optional()
183
+ });
184
+ function getDialogDefaults(props = {}) {
185
+ return dialogPropsSchema.parse(props);
186
+ }
187
+
188
+ // src/components/icon.ts
189
+ var import_zod6 = require("zod");
190
+ var iconPropsSchema = import_zod6.z.object({
191
+ /** Icon name from the library */
192
+ name: import_zod6.z.string().default(""),
193
+ /** Icon size (CSS value) */
194
+ size: import_zod6.z.union([import_zod6.z.string(), import_zod6.z.number()]).optional().default("1em"),
195
+ /** Icon color (CSS value) */
196
+ color: import_zod6.z.string().optional(),
197
+ /** Whether the icon should spin */
198
+ spin: import_zod6.z.boolean().optional().default(false)
199
+ });
200
+ function getIconDefaults(props = {}) {
201
+ return iconPropsSchema.parse(props);
202
+ }
203
+
204
+ // src/components/input.ts
205
+ var import_zod7 = require("zod");
206
+ var inputPropsSchema = import_zod7.z.object({
207
+ /** Input value */
208
+ modelValue: import_zod7.z.string().optional(),
209
+ /** Size */
210
+ size: import_zod7.z.enum(["sm", "md", "lg"]).default("md"),
211
+ /** Disabled state */
212
+ disabled: import_zod7.z.boolean().default(false),
213
+ /** Readonly state */
214
+ readonly: import_zod7.z.boolean().default(false),
215
+ /** Invalid / Error state */
216
+ invalid: import_zod7.z.boolean().default(false),
217
+ /** Width 100% */
218
+ fluid: import_zod7.z.boolean().default(false),
219
+ /** Icon to display on the left */
220
+ iconLeft: import_zod7.z.string().optional(),
221
+ /** Icon to display on the right */
222
+ iconRight: import_zod7.z.string().optional(),
223
+ /** Whether the input is clearable */
224
+ clearable: import_zod7.z.boolean().default(false),
225
+ /** Placeholder text */
226
+ placeholder: import_zod7.z.string().optional(),
227
+ /** Native type attribute */
228
+ type: import_zod7.z.string().default("text"),
229
+ /** Native name attribute */
230
+ name: import_zod7.z.string().optional(),
231
+ /** Native id attribute */
232
+ id: import_zod7.z.string().optional()
233
+ });
234
+ function getInputDefaults(props = {}) {
235
+ return inputPropsSchema.parse(props);
236
+ }
237
+
238
+ // src/components/radiobutton.ts
239
+ var import_zod8 = require("zod");
240
+ var radioButtonPropsSchema = import_zod8.z.object({
241
+ /** V-model selected value */
242
+ modelValue: import_zod8.z.any().optional(),
243
+ /** Value representing this specific radio button */
244
+ value: import_zod8.z.any().optional(),
245
+ /** Disabled state */
246
+ disabled: import_zod8.z.boolean().default(false),
247
+ /** Invalid / Error state */
248
+ invalid: import_zod8.z.boolean().default(false),
249
+ /** Readonly state */
250
+ readonly: import_zod8.z.boolean().default(false),
251
+ /** Size */
252
+ size: import_zod8.z.enum(["sm", "md", "lg"]).default("md"),
253
+ /** Severity */
254
+ severity: import_zod8.z.enum(["primary", "secondary", "success", "info", "warning", "danger", "help", "contrast"]).default("primary"),
255
+ /** Variant */
256
+ variant: import_zod8.z.enum(["filled", "outlined"]).default("filled"),
257
+ /** Label for accessibility and grouping */
258
+ label: import_zod8.z.string().optional(),
259
+ /** Position of the label */
260
+ labelPosition: import_zod8.z.enum(["left", "right"]).default("right"),
261
+ /** Group name for radios */
262
+ name: import_zod8.z.string().optional(),
263
+ /** Native id attribute */
264
+ id: import_zod8.z.string().optional()
265
+ });
266
+ function getRadioButtonDefaults(props = {}) {
267
+ return radioButtonPropsSchema.parse(props);
268
+ }
269
+
270
+ // src/components/stack.ts
271
+ var import_zod9 = require("zod");
272
+ var stackPropsSchema = import_zod9.z.object({
273
+ as: import_zod9.z.string().default("div"),
274
+ direction: import_zod9.z.enum(["row", "column", "row-reverse", "column-reverse"]).default("column"),
275
+ gap: import_zod9.z.enum(["none", "xs", "sm", "md", "lg", "xl", "2xl"]).default("md"),
276
+ align: import_zod9.z.enum(["start", "center", "end", "stretch", "baseline"]).default("stretch"),
277
+ justify: import_zod9.z.enum(["start", "center", "end", "between", "around", "evenly"]).default("start"),
278
+ wrap: import_zod9.z.enum(["nowrap", "wrap", "wrap-reverse"]).default("nowrap"),
279
+ fluid: import_zod9.z.boolean().default(false)
280
+ });
281
+ function getStackDefaults(props = {}) {
282
+ return stackPropsSchema.parse(props);
283
+ }
284
+
285
+ // src/components/switch.ts
286
+ var import_zod10 = require("zod");
287
+ var switchPropsSchema = import_zod10.z.object({
288
+ /** V-model value */
289
+ modelValue: import_zod10.z.any().optional(),
290
+ /** Value for 'on' state */
291
+ onValue: import_zod10.z.any().default(true),
292
+ /** Value for 'off' state */
293
+ offValue: import_zod10.z.any().default(false),
294
+ /** Disabled state */
295
+ disabled: import_zod10.z.boolean().default(false),
296
+ /** Invalid / Error state */
297
+ invalid: import_zod10.z.boolean().default(false),
298
+ /** Readonly state */
299
+ readonly: import_zod10.z.boolean().default(false),
300
+ /** Label (next to the switch) */
301
+ label: import_zod10.z.string().optional(),
302
+ /** Position of the label */
303
+ labelPosition: import_zod10.z.enum(["left", "right"]).default("right"),
304
+ /** Icon to display when switch is on */
305
+ trueIcon: import_zod10.z.string().optional(),
306
+ /** Icon to display when switch is off */
307
+ falseIcon: import_zod10.z.string().optional(),
308
+ /** Size of the switch */
309
+ size: import_zod10.z.enum(["sm", "md", "lg"]).default("md"),
310
+ /** Native id attribute */
311
+ id: import_zod10.z.string().optional()
312
+ });
313
+ function getSwitchDefaults(props = {}) {
314
+ return switchPropsSchema.parse(props);
315
+ }
316
+
317
+ // src/components/tag.ts
318
+ var import_zod11 = require("zod");
319
+ var tagPropsSchema = import_zod11.z.object({
320
+ /** Tag label / content */
321
+ value: import_zod11.z.string().optional(),
322
+ /** Severity / semantic color */
323
+ severity: import_zod11.z.enum(["primary", "secondary", "success", "info", "warning", "danger", "help", "contrast"]).default("primary"),
324
+ /** Rounded / pill shape */
325
+ rounded: import_zod11.z.boolean().default(false),
326
+ /** Icon name from the library */
327
+ icon: import_zod11.z.string().optional(),
328
+ /** Show close icon */
329
+ closable: import_zod11.z.boolean().default(false)
330
+ });
331
+ function getTagDefaults(props = {}) {
332
+ return tagPropsSchema.parse(props);
333
+ }
334
+
335
+ // src/components/toast.ts
336
+ var import_zod12 = require("zod");
337
+ var toastSeveritySchema = import_zod12.z.enum([
338
+ "success",
339
+ "info",
340
+ "warning",
341
+ "danger",
342
+ "secondary",
343
+ "help",
344
+ "contrast",
345
+ "primary"
346
+ ]);
347
+ var toastMessageSchema = import_zod12.z.object({
348
+ id: import_zod12.z.string().optional(),
349
+ severity: toastSeveritySchema.default("info"),
350
+ summary: import_zod12.z.string().optional(),
351
+ detail: import_zod12.z.string().optional(),
352
+ life: import_zod12.z.number().optional().default(3e3),
353
+ sticky: import_zod12.z.boolean().optional().default(false),
354
+ closable: import_zod12.z.boolean().optional().default(true),
355
+ icon: import_zod12.z.string().optional(),
356
+ group: import_zod12.z.string().optional()
357
+ });
358
+ var toastPropsSchema = import_zod12.z.object({
359
+ position: import_zod12.z.enum(["top-left", "top-center", "top-right", "bottom-left", "bottom-center", "bottom-right", "center"]).default("top-right"),
360
+ group: import_zod12.z.string().optional(),
361
+ baseZIndex: import_zod12.z.number().optional().default(0),
362
+ autoZIndex: import_zod12.z.boolean().optional().default(true),
363
+ /** Teleport target selector or element */
364
+ appendTo: import_zod12.z.any().default("#teleports")
365
+ });
366
+ function getToastDefaults(props = {}) {
367
+ return toastPropsSchema.parse(props);
368
+ }
369
+
370
+ // src/registry.ts
371
+ var import_zod13 = require("zod");
372
+ var registryItemFileSchema = import_zod13.z.object({
373
+ /** Relative file path */
374
+ path: import_zod13.z.string(),
375
+ /** File content as string */
376
+ content: import_zod13.z.string(),
377
+ /** File type hint */
378
+ type: import_zod13.z.enum(["component", "style", "schema", "composable", "util"]).optional()
379
+ });
380
+ var registryItemSchema = import_zod13.z.object({
381
+ /** Component name (kebab-case) */
382
+ name: import_zod13.z.string(),
383
+ /** Component type */
384
+ type: import_zod13.z.enum(["component", "primitive", "composable", "util"]).default("component"),
385
+ /** Human-readable description */
386
+ description: import_zod13.z.string().optional(),
387
+ /** Source files */
388
+ files: import_zod13.z.array(registryItemFileSchema),
389
+ /** npm dependencies required by this component */
390
+ dependencies: import_zod13.z.array(import_zod13.z.string()).default([]),
391
+ /** Other registry components this one depends on */
392
+ registryDependencies: import_zod13.z.array(import_zod13.z.string()).default([]),
393
+ /** CSS file paths (if separately bundled) */
394
+ cssFiles: import_zod13.z.array(import_zod13.z.string()).default([])
395
+ });
396
+ var registryIndexSchema = import_zod13.z.array(
397
+ import_zod13.z.object({
398
+ name: import_zod13.z.string(),
399
+ type: import_zod13.z.string(),
400
+ description: import_zod13.z.string().optional(),
401
+ dependencies: import_zod13.z.array(import_zod13.z.string()).default([]),
402
+ registryDependencies: import_zod13.z.array(import_zod13.z.string()).default([])
403
+ })
404
+ );
405
+ // Annotate the CommonJS export names for ESM import in node:
406
+ 0 && (module.exports = {
407
+ badgePropsSchema,
408
+ boxPropsSchema,
409
+ buttonPropsSchema,
410
+ checkboxPropsSchema,
411
+ dialogPropsSchema,
412
+ getBadgeDefaults,
413
+ getBoxDefaults,
414
+ getButtonDefaults,
415
+ getCheckboxDefaults,
416
+ getDialogDefaults,
417
+ getIconDefaults,
418
+ getInputDefaults,
419
+ getRadioButtonDefaults,
420
+ getStackDefaults,
421
+ getSwitchDefaults,
422
+ getTagDefaults,
423
+ getToastDefaults,
424
+ iconPropsSchema,
425
+ inputPropsSchema,
426
+ radioButtonPropsSchema,
427
+ registryIndexSchema,
428
+ registryItemFileSchema,
429
+ registryItemSchema,
430
+ stackPropsSchema,
431
+ switchPropsSchema,
432
+ tagPropsSchema,
433
+ toastMessageSchema,
434
+ toastPropsSchema,
435
+ toastSeveritySchema
436
+ });