magick-ui 0.2.1 → 0.2.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.
- package/dist/index.cjs +1967 -258
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +2026 -312
- package/dist/index.js.map +1 -1
- package/dist/schema.cjs +1957 -76
- package/dist/schema.cjs.map +1 -1
- package/dist/schema.d.cts +5144 -8
- package/dist/schema.d.ts +5144 -8
- package/dist/schema.js +1869 -75
- package/dist/schema.js.map +1 -1
- package/dist/ui/index.cjs +337 -248
- package/dist/ui/index.cjs.map +1 -1
- package/dist/ui/index.d.cts +28 -3
- package/dist/ui/index.d.ts +28 -3
- package/dist/ui/index.js +337 -243
- package/dist/ui/index.js.map +1 -1
- package/package.json +3 -2
- package/schema/component-schema.json +672 -0
package/dist/index.js
CHANGED
|
@@ -85,6 +85,88 @@ var component_schema_default = {
|
|
|
85
85
|
},
|
|
86
86
|
$schema: "http://json-schema.org/draft-07/schema#"
|
|
87
87
|
},
|
|
88
|
+
"tool-button": {
|
|
89
|
+
$ref: "#/definitions/tool-button",
|
|
90
|
+
definitions: {
|
|
91
|
+
"tool-button": {
|
|
92
|
+
type: "object",
|
|
93
|
+
properties: {
|
|
94
|
+
type: {
|
|
95
|
+
type: "string",
|
|
96
|
+
const: "tool-button"
|
|
97
|
+
},
|
|
98
|
+
props: {
|
|
99
|
+
type: "object",
|
|
100
|
+
properties: {
|
|
101
|
+
variant: {
|
|
102
|
+
type: "string",
|
|
103
|
+
enum: [
|
|
104
|
+
"primary",
|
|
105
|
+
"outline",
|
|
106
|
+
"destructive"
|
|
107
|
+
],
|
|
108
|
+
description: "Button style. Defaults to 'primary'"
|
|
109
|
+
},
|
|
110
|
+
size: {
|
|
111
|
+
type: "string",
|
|
112
|
+
enum: [
|
|
113
|
+
"md",
|
|
114
|
+
"lg"
|
|
115
|
+
],
|
|
116
|
+
description: "Button size. Defaults to 'md'"
|
|
117
|
+
},
|
|
118
|
+
state: {
|
|
119
|
+
type: "string",
|
|
120
|
+
enum: [
|
|
121
|
+
"loading",
|
|
122
|
+
"default"
|
|
123
|
+
],
|
|
124
|
+
description: "Button state. Defaults to 'default'"
|
|
125
|
+
},
|
|
126
|
+
onlyIcon: {
|
|
127
|
+
type: "boolean",
|
|
128
|
+
description: "Icon-only mode with square padding"
|
|
129
|
+
},
|
|
130
|
+
disabled: {
|
|
131
|
+
type: "boolean"
|
|
132
|
+
}
|
|
133
|
+
},
|
|
134
|
+
additionalProperties: false
|
|
135
|
+
},
|
|
136
|
+
children: {
|
|
137
|
+
type: "array",
|
|
138
|
+
items: {
|
|
139
|
+
type: "object",
|
|
140
|
+
properties: {
|
|
141
|
+
type: {
|
|
142
|
+
type: "string"
|
|
143
|
+
},
|
|
144
|
+
props: {
|
|
145
|
+
type: "object",
|
|
146
|
+
additionalProperties: {}
|
|
147
|
+
},
|
|
148
|
+
children: {
|
|
149
|
+
type: "array",
|
|
150
|
+
items: {}
|
|
151
|
+
}
|
|
152
|
+
},
|
|
153
|
+
required: [
|
|
154
|
+
"type"
|
|
155
|
+
],
|
|
156
|
+
additionalProperties: false
|
|
157
|
+
},
|
|
158
|
+
description: "Button content"
|
|
159
|
+
}
|
|
160
|
+
},
|
|
161
|
+
required: [
|
|
162
|
+
"type"
|
|
163
|
+
],
|
|
164
|
+
additionalProperties: false,
|
|
165
|
+
description: "A toolbar action button with loading state"
|
|
166
|
+
}
|
|
167
|
+
},
|
|
168
|
+
$schema: "http://json-schema.org/draft-07/schema#"
|
|
169
|
+
},
|
|
88
170
|
card: {
|
|
89
171
|
$ref: "#/definitions/card",
|
|
90
172
|
definitions: {
|
|
@@ -387,6 +469,55 @@ var component_schema_default = {
|
|
|
387
469
|
},
|
|
388
470
|
$schema: "http://json-schema.org/draft-07/schema#"
|
|
389
471
|
},
|
|
472
|
+
"card-action": {
|
|
473
|
+
$ref: "#/definitions/card-action",
|
|
474
|
+
definitions: {
|
|
475
|
+
"card-action": {
|
|
476
|
+
type: "object",
|
|
477
|
+
properties: {
|
|
478
|
+
type: {
|
|
479
|
+
type: "string",
|
|
480
|
+
const: "card-action"
|
|
481
|
+
},
|
|
482
|
+
props: {
|
|
483
|
+
type: "object",
|
|
484
|
+
properties: {},
|
|
485
|
+
additionalProperties: false
|
|
486
|
+
},
|
|
487
|
+
children: {
|
|
488
|
+
type: "array",
|
|
489
|
+
items: {
|
|
490
|
+
type: "object",
|
|
491
|
+
properties: {
|
|
492
|
+
type: {
|
|
493
|
+
type: "string"
|
|
494
|
+
},
|
|
495
|
+
props: {
|
|
496
|
+
type: "object",
|
|
497
|
+
additionalProperties: {}
|
|
498
|
+
},
|
|
499
|
+
children: {
|
|
500
|
+
type: "array",
|
|
501
|
+
items: {}
|
|
502
|
+
}
|
|
503
|
+
},
|
|
504
|
+
required: [
|
|
505
|
+
"type"
|
|
506
|
+
],
|
|
507
|
+
additionalProperties: false
|
|
508
|
+
},
|
|
509
|
+
description: "Action elements (buttons, links) placed at the top-right of a card header"
|
|
510
|
+
}
|
|
511
|
+
},
|
|
512
|
+
required: [
|
|
513
|
+
"type"
|
|
514
|
+
],
|
|
515
|
+
additionalProperties: false,
|
|
516
|
+
description: "An action area positioned at the top-right of a card"
|
|
517
|
+
}
|
|
518
|
+
},
|
|
519
|
+
$schema: "http://json-schema.org/draft-07/schema#"
|
|
520
|
+
},
|
|
390
521
|
form: {
|
|
391
522
|
$ref: "#/definitions/form",
|
|
392
523
|
definitions: {
|
|
@@ -2936,7 +3067,609 @@ var component_schema_default = {
|
|
|
2936
3067
|
}
|
|
2937
3068
|
},
|
|
2938
3069
|
required: [
|
|
2939
|
-
"items"
|
|
3070
|
+
"items"
|
|
3071
|
+
],
|
|
3072
|
+
additionalProperties: false
|
|
3073
|
+
}
|
|
3074
|
+
},
|
|
3075
|
+
required: [
|
|
3076
|
+
"type",
|
|
3077
|
+
"props"
|
|
3078
|
+
],
|
|
3079
|
+
additionalProperties: false,
|
|
3080
|
+
description: "A breadcrumb navigation trail"
|
|
3081
|
+
}
|
|
3082
|
+
},
|
|
3083
|
+
$schema: "http://json-schema.org/draft-07/schema#"
|
|
3084
|
+
},
|
|
3085
|
+
tooltip: {
|
|
3086
|
+
$ref: "#/definitions/tooltip",
|
|
3087
|
+
definitions: {
|
|
3088
|
+
tooltip: {
|
|
3089
|
+
type: "object",
|
|
3090
|
+
properties: {
|
|
3091
|
+
type: {
|
|
3092
|
+
type: "string",
|
|
3093
|
+
const: "tooltip"
|
|
3094
|
+
},
|
|
3095
|
+
props: {
|
|
3096
|
+
type: "object",
|
|
3097
|
+
properties: {
|
|
3098
|
+
content: {
|
|
3099
|
+
type: "string",
|
|
3100
|
+
description: "Tooltip text"
|
|
3101
|
+
},
|
|
3102
|
+
position: {
|
|
3103
|
+
type: "string",
|
|
3104
|
+
enum: [
|
|
3105
|
+
"top",
|
|
3106
|
+
"top-center",
|
|
3107
|
+
"top-left",
|
|
3108
|
+
"top-right",
|
|
3109
|
+
"bottom",
|
|
3110
|
+
"bottom-left",
|
|
3111
|
+
"bottom-center",
|
|
3112
|
+
"bottom-right",
|
|
3113
|
+
"left",
|
|
3114
|
+
"right"
|
|
3115
|
+
],
|
|
3116
|
+
description: "Tooltip placement"
|
|
3117
|
+
},
|
|
3118
|
+
withArrow: {
|
|
3119
|
+
type: "boolean",
|
|
3120
|
+
description: "Show an arrow pointer"
|
|
3121
|
+
}
|
|
3122
|
+
},
|
|
3123
|
+
required: [
|
|
3124
|
+
"content"
|
|
3125
|
+
],
|
|
3126
|
+
additionalProperties: false
|
|
3127
|
+
},
|
|
3128
|
+
children: {
|
|
3129
|
+
type: "array",
|
|
3130
|
+
items: {
|
|
3131
|
+
type: "object",
|
|
3132
|
+
properties: {
|
|
3133
|
+
type: {
|
|
3134
|
+
type: "string"
|
|
3135
|
+
},
|
|
3136
|
+
props: {
|
|
3137
|
+
type: "object",
|
|
3138
|
+
additionalProperties: {}
|
|
3139
|
+
},
|
|
3140
|
+
children: {
|
|
3141
|
+
type: "array",
|
|
3142
|
+
items: {}
|
|
3143
|
+
}
|
|
3144
|
+
},
|
|
3145
|
+
required: [
|
|
3146
|
+
"type"
|
|
3147
|
+
],
|
|
3148
|
+
additionalProperties: false
|
|
3149
|
+
},
|
|
3150
|
+
description: "The trigger element the tooltip wraps"
|
|
3151
|
+
}
|
|
3152
|
+
},
|
|
3153
|
+
required: [
|
|
3154
|
+
"type",
|
|
3155
|
+
"props"
|
|
3156
|
+
],
|
|
3157
|
+
additionalProperties: false,
|
|
3158
|
+
description: "A tooltip that appears on hover over its child element"
|
|
3159
|
+
}
|
|
3160
|
+
},
|
|
3161
|
+
$schema: "http://json-schema.org/draft-07/schema#"
|
|
3162
|
+
},
|
|
3163
|
+
table: {
|
|
3164
|
+
$ref: "#/definitions/table",
|
|
3165
|
+
definitions: {
|
|
3166
|
+
table: {
|
|
3167
|
+
type: "object",
|
|
3168
|
+
properties: {
|
|
3169
|
+
type: {
|
|
3170
|
+
type: "string",
|
|
3171
|
+
const: "table"
|
|
3172
|
+
},
|
|
3173
|
+
props: {
|
|
3174
|
+
type: "object",
|
|
3175
|
+
properties: {
|
|
3176
|
+
columns: {
|
|
3177
|
+
type: "array",
|
|
3178
|
+
items: {
|
|
3179
|
+
type: "object",
|
|
3180
|
+
properties: {
|
|
3181
|
+
accessorKey: {
|
|
3182
|
+
type: "string",
|
|
3183
|
+
description: "Key in the row data object"
|
|
3184
|
+
},
|
|
3185
|
+
header: {
|
|
3186
|
+
type: "string",
|
|
3187
|
+
description: "Column header text"
|
|
3188
|
+
}
|
|
3189
|
+
},
|
|
3190
|
+
required: [
|
|
3191
|
+
"accessorKey",
|
|
3192
|
+
"header"
|
|
3193
|
+
],
|
|
3194
|
+
additionalProperties: false
|
|
3195
|
+
},
|
|
3196
|
+
description: "Column definitions"
|
|
3197
|
+
},
|
|
3198
|
+
tableData: {
|
|
3199
|
+
type: "array",
|
|
3200
|
+
items: {
|
|
3201
|
+
type: "object",
|
|
3202
|
+
additionalProperties: {}
|
|
3203
|
+
},
|
|
3204
|
+
description: "Array of row data objects"
|
|
3205
|
+
}
|
|
3206
|
+
},
|
|
3207
|
+
required: [
|
|
3208
|
+
"columns",
|
|
3209
|
+
"tableData"
|
|
3210
|
+
],
|
|
3211
|
+
additionalProperties: false
|
|
3212
|
+
}
|
|
3213
|
+
},
|
|
3214
|
+
required: [
|
|
3215
|
+
"type",
|
|
3216
|
+
"props"
|
|
3217
|
+
],
|
|
3218
|
+
additionalProperties: false,
|
|
3219
|
+
description: "A data table with columns and rows"
|
|
3220
|
+
}
|
|
3221
|
+
},
|
|
3222
|
+
$schema: "http://json-schema.org/draft-07/schema#"
|
|
3223
|
+
},
|
|
3224
|
+
"google-map": {
|
|
3225
|
+
$ref: "#/definitions/google-map",
|
|
3226
|
+
definitions: {
|
|
3227
|
+
"google-map": {
|
|
3228
|
+
type: "object",
|
|
3229
|
+
properties: {
|
|
3230
|
+
type: {
|
|
3231
|
+
type: "string",
|
|
3232
|
+
const: "google-map"
|
|
3233
|
+
},
|
|
3234
|
+
props: {
|
|
3235
|
+
type: "object",
|
|
3236
|
+
properties: {
|
|
3237
|
+
center: {
|
|
3238
|
+
type: "object",
|
|
3239
|
+
properties: {
|
|
3240
|
+
lat: {
|
|
3241
|
+
type: "number",
|
|
3242
|
+
description: "Center latitude"
|
|
3243
|
+
},
|
|
3244
|
+
lng: {
|
|
3245
|
+
type: "number",
|
|
3246
|
+
description: "Center longitude"
|
|
3247
|
+
}
|
|
3248
|
+
},
|
|
3249
|
+
required: [
|
|
3250
|
+
"lat",
|
|
3251
|
+
"lng"
|
|
3252
|
+
],
|
|
3253
|
+
additionalProperties: false,
|
|
3254
|
+
description: "Map center coordinates"
|
|
3255
|
+
},
|
|
3256
|
+
zoom: {
|
|
3257
|
+
type: "number",
|
|
3258
|
+
description: "Zoom level (1-20). Defaults to 12"
|
|
3259
|
+
},
|
|
3260
|
+
markers: {
|
|
3261
|
+
type: "array",
|
|
3262
|
+
items: {
|
|
3263
|
+
type: "object",
|
|
3264
|
+
properties: {
|
|
3265
|
+
lat: {
|
|
3266
|
+
type: "number",
|
|
3267
|
+
description: "Latitude"
|
|
3268
|
+
},
|
|
3269
|
+
lng: {
|
|
3270
|
+
type: "number",
|
|
3271
|
+
description: "Longitude"
|
|
3272
|
+
},
|
|
3273
|
+
title: {
|
|
3274
|
+
type: "string",
|
|
3275
|
+
description: "Marker title shown in info window"
|
|
3276
|
+
},
|
|
3277
|
+
description: {
|
|
3278
|
+
type: "string",
|
|
3279
|
+
description: "Marker description shown in info window"
|
|
3280
|
+
},
|
|
3281
|
+
color: {
|
|
3282
|
+
type: "string",
|
|
3283
|
+
description: "Marker pin color (hex or CSS color)"
|
|
3284
|
+
}
|
|
3285
|
+
},
|
|
3286
|
+
required: [
|
|
3287
|
+
"lat",
|
|
3288
|
+
"lng"
|
|
3289
|
+
],
|
|
3290
|
+
additionalProperties: false
|
|
3291
|
+
},
|
|
3292
|
+
description: "Array of map markers with lat/lng and optional info"
|
|
3293
|
+
},
|
|
3294
|
+
height: {
|
|
3295
|
+
type: "string",
|
|
3296
|
+
description: "Map height CSS value. Defaults to '400px'"
|
|
3297
|
+
},
|
|
3298
|
+
width: {
|
|
3299
|
+
type: "string",
|
|
3300
|
+
description: "Map width CSS value. Defaults to '100%'"
|
|
3301
|
+
},
|
|
3302
|
+
gestureHandling: {
|
|
3303
|
+
type: "string",
|
|
3304
|
+
enum: [
|
|
3305
|
+
"cooperative",
|
|
3306
|
+
"greedy",
|
|
3307
|
+
"none",
|
|
3308
|
+
"auto"
|
|
3309
|
+
],
|
|
3310
|
+
description: "How the map handles touch/scroll gestures. Defaults to 'cooperative'"
|
|
3311
|
+
},
|
|
3312
|
+
disableDefaultUI: {
|
|
3313
|
+
type: "boolean",
|
|
3314
|
+
description: "Hide default map controls"
|
|
3315
|
+
}
|
|
3316
|
+
},
|
|
3317
|
+
additionalProperties: false
|
|
3318
|
+
}
|
|
3319
|
+
},
|
|
3320
|
+
required: [
|
|
3321
|
+
"type",
|
|
3322
|
+
"props"
|
|
3323
|
+
],
|
|
3324
|
+
additionalProperties: false,
|
|
3325
|
+
description: "An interactive Google Map with optional markers and info windows"
|
|
3326
|
+
}
|
|
3327
|
+
},
|
|
3328
|
+
$schema: "http://json-schema.org/draft-07/schema#"
|
|
3329
|
+
},
|
|
3330
|
+
calendar: {
|
|
3331
|
+
$ref: "#/definitions/calendar",
|
|
3332
|
+
definitions: {
|
|
3333
|
+
calendar: {
|
|
3334
|
+
type: "object",
|
|
3335
|
+
properties: {
|
|
3336
|
+
type: {
|
|
3337
|
+
type: "string",
|
|
3338
|
+
const: "calendar"
|
|
3339
|
+
},
|
|
3340
|
+
props: {
|
|
3341
|
+
type: "object",
|
|
3342
|
+
properties: {
|
|
3343
|
+
showOutsideDays: {
|
|
3344
|
+
type: "boolean",
|
|
3345
|
+
description: "Show days from adjacent months. Defaults to true"
|
|
3346
|
+
},
|
|
3347
|
+
captionLayout: {
|
|
3348
|
+
type: "string",
|
|
3349
|
+
enum: [
|
|
3350
|
+
"label",
|
|
3351
|
+
"dropdown",
|
|
3352
|
+
"dropdown-months",
|
|
3353
|
+
"dropdown-years"
|
|
3354
|
+
],
|
|
3355
|
+
description: "Caption display mode. Defaults to 'label'"
|
|
3356
|
+
},
|
|
3357
|
+
buttonVariant: {
|
|
3358
|
+
type: "string",
|
|
3359
|
+
enum: [
|
|
3360
|
+
"primary",
|
|
3361
|
+
"secondary",
|
|
3362
|
+
"outline",
|
|
3363
|
+
"destructive",
|
|
3364
|
+
"ghost",
|
|
3365
|
+
"soft"
|
|
3366
|
+
],
|
|
3367
|
+
description: "Navigation button style. Defaults to 'ghost'"
|
|
3368
|
+
},
|
|
3369
|
+
mode: {
|
|
3370
|
+
type: "string",
|
|
3371
|
+
enum: [
|
|
3372
|
+
"single",
|
|
3373
|
+
"multiple",
|
|
3374
|
+
"range"
|
|
3375
|
+
],
|
|
3376
|
+
description: "Selection mode"
|
|
3377
|
+
},
|
|
3378
|
+
numberOfMonths: {
|
|
3379
|
+
type: "number",
|
|
3380
|
+
description: "Number of months to display"
|
|
3381
|
+
},
|
|
3382
|
+
disabled: {
|
|
3383
|
+
type: "boolean"
|
|
3384
|
+
}
|
|
3385
|
+
},
|
|
3386
|
+
additionalProperties: false
|
|
3387
|
+
}
|
|
3388
|
+
},
|
|
3389
|
+
required: [
|
|
3390
|
+
"type"
|
|
3391
|
+
],
|
|
3392
|
+
additionalProperties: false,
|
|
3393
|
+
description: "A date calendar for picking dates or date ranges"
|
|
3394
|
+
}
|
|
3395
|
+
},
|
|
3396
|
+
$schema: "http://json-schema.org/draft-07/schema#"
|
|
3397
|
+
},
|
|
3398
|
+
"file-input": {
|
|
3399
|
+
$ref: "#/definitions/file-input",
|
|
3400
|
+
definitions: {
|
|
3401
|
+
"file-input": {
|
|
3402
|
+
type: "object",
|
|
3403
|
+
properties: {
|
|
3404
|
+
type: {
|
|
3405
|
+
type: "string",
|
|
3406
|
+
const: "file-input"
|
|
3407
|
+
},
|
|
3408
|
+
props: {
|
|
3409
|
+
type: "object",
|
|
3410
|
+
properties: {
|
|
3411
|
+
label: {
|
|
3412
|
+
type: "string",
|
|
3413
|
+
description: "Label text above the input"
|
|
3414
|
+
},
|
|
3415
|
+
helperText: {
|
|
3416
|
+
type: "string",
|
|
3417
|
+
description: "Helper text below the input"
|
|
3418
|
+
},
|
|
3419
|
+
error: {
|
|
3420
|
+
type: "boolean",
|
|
3421
|
+
description: "Show error styling. Defaults to false"
|
|
3422
|
+
},
|
|
3423
|
+
accept: {
|
|
3424
|
+
type: "string",
|
|
3425
|
+
description: "Accepted file types, e.g. 'image/*,.pdf'"
|
|
3426
|
+
},
|
|
3427
|
+
multiple: {
|
|
3428
|
+
type: "boolean",
|
|
3429
|
+
description: "Allow multiple files. Defaults to false"
|
|
3430
|
+
},
|
|
3431
|
+
disabled: {
|
|
3432
|
+
type: "boolean"
|
|
3433
|
+
}
|
|
3434
|
+
},
|
|
3435
|
+
additionalProperties: false
|
|
3436
|
+
}
|
|
3437
|
+
},
|
|
3438
|
+
required: [
|
|
3439
|
+
"type"
|
|
3440
|
+
],
|
|
3441
|
+
additionalProperties: false,
|
|
3442
|
+
description: "A file input with choose-file button and upload progress"
|
|
3443
|
+
}
|
|
3444
|
+
},
|
|
3445
|
+
$schema: "http://json-schema.org/draft-07/schema#"
|
|
3446
|
+
},
|
|
3447
|
+
"tool-toggle": {
|
|
3448
|
+
$ref: "#/definitions/tool-toggle",
|
|
3449
|
+
definitions: {
|
|
3450
|
+
"tool-toggle": {
|
|
3451
|
+
type: "object",
|
|
3452
|
+
properties: {
|
|
3453
|
+
type: {
|
|
3454
|
+
type: "string",
|
|
3455
|
+
const: "tool-toggle"
|
|
3456
|
+
},
|
|
3457
|
+
props: {
|
|
3458
|
+
type: "object",
|
|
3459
|
+
properties: {
|
|
3460
|
+
icon: {
|
|
3461
|
+
type: "string",
|
|
3462
|
+
description: "Icon name (resolved by the renderer)"
|
|
3463
|
+
},
|
|
3464
|
+
dropdown: {
|
|
3465
|
+
type: "boolean",
|
|
3466
|
+
description: "Show dropdown chevron"
|
|
3467
|
+
}
|
|
3468
|
+
},
|
|
3469
|
+
additionalProperties: false
|
|
3470
|
+
}
|
|
3471
|
+
},
|
|
3472
|
+
required: [
|
|
3473
|
+
"type"
|
|
3474
|
+
],
|
|
3475
|
+
additionalProperties: false,
|
|
3476
|
+
description: "A round toggle button used in toolbars, optionally with a dropdown"
|
|
3477
|
+
}
|
|
3478
|
+
},
|
|
3479
|
+
$schema: "http://json-schema.org/draft-07/schema#"
|
|
3480
|
+
},
|
|
3481
|
+
"toggle-dropdown-button": {
|
|
3482
|
+
$ref: "#/definitions/toggle-dropdown-button",
|
|
3483
|
+
definitions: {
|
|
3484
|
+
"toggle-dropdown-button": {
|
|
3485
|
+
type: "object",
|
|
3486
|
+
properties: {
|
|
3487
|
+
type: {
|
|
3488
|
+
type: "string",
|
|
3489
|
+
const: "toggle-dropdown-button"
|
|
3490
|
+
},
|
|
3491
|
+
props: {
|
|
3492
|
+
type: "object",
|
|
3493
|
+
properties: {
|
|
3494
|
+
type: {
|
|
3495
|
+
type: "string",
|
|
3496
|
+
enum: [
|
|
3497
|
+
"text",
|
|
3498
|
+
"icon"
|
|
3499
|
+
],
|
|
3500
|
+
description: "Button content type"
|
|
3501
|
+
},
|
|
3502
|
+
selected: {
|
|
3503
|
+
type: "boolean",
|
|
3504
|
+
description: "Whether the button is selected"
|
|
3505
|
+
},
|
|
3506
|
+
variant: {
|
|
3507
|
+
type: "string",
|
|
3508
|
+
enum: [
|
|
3509
|
+
"primary",
|
|
3510
|
+
"secondary",
|
|
3511
|
+
"destructive"
|
|
3512
|
+
],
|
|
3513
|
+
description: "Button color variant"
|
|
3514
|
+
}
|
|
3515
|
+
},
|
|
3516
|
+
required: [
|
|
3517
|
+
"type",
|
|
3518
|
+
"selected",
|
|
3519
|
+
"variant"
|
|
3520
|
+
],
|
|
3521
|
+
additionalProperties: false
|
|
3522
|
+
}
|
|
3523
|
+
},
|
|
3524
|
+
required: [
|
|
3525
|
+
"type",
|
|
3526
|
+
"props"
|
|
3527
|
+
],
|
|
3528
|
+
additionalProperties: false,
|
|
3529
|
+
description: "A split toggle button with an attached dropdown trigger"
|
|
3530
|
+
}
|
|
3531
|
+
},
|
|
3532
|
+
$schema: "http://json-schema.org/draft-07/schema#"
|
|
3533
|
+
},
|
|
3534
|
+
"icon-container": {
|
|
3535
|
+
$ref: "#/definitions/icon-container",
|
|
3536
|
+
definitions: {
|
|
3537
|
+
"icon-container": {
|
|
3538
|
+
type: "object",
|
|
3539
|
+
properties: {
|
|
3540
|
+
type: {
|
|
3541
|
+
type: "string",
|
|
3542
|
+
const: "icon-container"
|
|
3543
|
+
},
|
|
3544
|
+
props: {
|
|
3545
|
+
type: "object",
|
|
3546
|
+
properties: {
|
|
3547
|
+
icon: {
|
|
3548
|
+
type: "string",
|
|
3549
|
+
description: "Icon name (resolved by the renderer)"
|
|
3550
|
+
},
|
|
3551
|
+
size: {
|
|
3552
|
+
type: "string",
|
|
3553
|
+
enum: [
|
|
3554
|
+
"xs",
|
|
3555
|
+
"sm",
|
|
3556
|
+
"md",
|
|
3557
|
+
"lg",
|
|
3558
|
+
"xl",
|
|
3559
|
+
"2xl",
|
|
3560
|
+
"3xl",
|
|
3561
|
+
"4xl",
|
|
3562
|
+
"5xl",
|
|
3563
|
+
"6xl",
|
|
3564
|
+
"auto"
|
|
3565
|
+
],
|
|
3566
|
+
description: "Icon size. Defaults to 'sm'"
|
|
3567
|
+
},
|
|
3568
|
+
colorInFill: {
|
|
3569
|
+
type: "boolean",
|
|
3570
|
+
description: "Apply fill colors to SVG paths. Defaults to true"
|
|
3571
|
+
},
|
|
3572
|
+
disableTheme: {
|
|
3573
|
+
type: "boolean",
|
|
3574
|
+
description: "Disable theme-aware coloring. Defaults to false"
|
|
3575
|
+
}
|
|
3576
|
+
},
|
|
3577
|
+
additionalProperties: false
|
|
3578
|
+
},
|
|
3579
|
+
children: {
|
|
3580
|
+
type: "array",
|
|
3581
|
+
items: {
|
|
3582
|
+
type: "object",
|
|
3583
|
+
properties: {
|
|
3584
|
+
type: {
|
|
3585
|
+
type: "string"
|
|
3586
|
+
},
|
|
3587
|
+
props: {
|
|
3588
|
+
type: "object",
|
|
3589
|
+
additionalProperties: {}
|
|
3590
|
+
},
|
|
3591
|
+
children: {
|
|
3592
|
+
type: "array",
|
|
3593
|
+
items: {}
|
|
3594
|
+
}
|
|
3595
|
+
},
|
|
3596
|
+
required: [
|
|
3597
|
+
"type"
|
|
3598
|
+
],
|
|
3599
|
+
additionalProperties: false
|
|
3600
|
+
},
|
|
3601
|
+
description: "Icon element"
|
|
3602
|
+
}
|
|
3603
|
+
},
|
|
3604
|
+
required: [
|
|
3605
|
+
"type"
|
|
3606
|
+
],
|
|
3607
|
+
additionalProperties: false,
|
|
3608
|
+
description: "A sized container for static icons with theme-aware coloring"
|
|
3609
|
+
}
|
|
3610
|
+
},
|
|
3611
|
+
$schema: "http://json-schema.org/draft-07/schema#"
|
|
3612
|
+
},
|
|
3613
|
+
"icon-profile": {
|
|
3614
|
+
$ref: "#/definitions/icon-profile",
|
|
3615
|
+
definitions: {
|
|
3616
|
+
"icon-profile": {
|
|
3617
|
+
type: "object",
|
|
3618
|
+
properties: {
|
|
3619
|
+
type: {
|
|
3620
|
+
type: "string",
|
|
3621
|
+
const: "icon-profile"
|
|
3622
|
+
},
|
|
3623
|
+
props: {
|
|
3624
|
+
type: "object",
|
|
3625
|
+
properties: {
|
|
3626
|
+
icon: {
|
|
3627
|
+
type: "string",
|
|
3628
|
+
description: "Icon name (resolved by the renderer)"
|
|
3629
|
+
},
|
|
3630
|
+
color: {
|
|
3631
|
+
type: "string",
|
|
3632
|
+
enum: [
|
|
3633
|
+
"red",
|
|
3634
|
+
"orange",
|
|
3635
|
+
"amber",
|
|
3636
|
+
"yellow",
|
|
3637
|
+
"lime",
|
|
3638
|
+
"green",
|
|
3639
|
+
"emerald",
|
|
3640
|
+
"teal",
|
|
3641
|
+
"cyan",
|
|
3642
|
+
"sky",
|
|
3643
|
+
"blue",
|
|
3644
|
+
"indigo",
|
|
3645
|
+
"violet",
|
|
3646
|
+
"purple",
|
|
3647
|
+
"fuchsia",
|
|
3648
|
+
"pink",
|
|
3649
|
+
"rose",
|
|
3650
|
+
"slate"
|
|
3651
|
+
],
|
|
3652
|
+
description: "Background glow and icon color. Defaults to 'red'"
|
|
3653
|
+
},
|
|
3654
|
+
size: {
|
|
3655
|
+
type: "string",
|
|
3656
|
+
enum: [
|
|
3657
|
+
"26",
|
|
3658
|
+
"32",
|
|
3659
|
+
"40",
|
|
3660
|
+
"48",
|
|
3661
|
+
"56",
|
|
3662
|
+
"64"
|
|
3663
|
+
],
|
|
3664
|
+
description: "Size in pixels. Defaults to '64'"
|
|
3665
|
+
},
|
|
3666
|
+
externalIcon: {
|
|
3667
|
+
type: "boolean",
|
|
3668
|
+
description: "Whether the icon is external"
|
|
3669
|
+
}
|
|
3670
|
+
},
|
|
3671
|
+
required: [
|
|
3672
|
+
"icon"
|
|
2940
3673
|
],
|
|
2941
3674
|
additionalProperties: false
|
|
2942
3675
|
}
|
|
@@ -2946,20 +3679,20 @@ var component_schema_default = {
|
|
|
2946
3679
|
"props"
|
|
2947
3680
|
],
|
|
2948
3681
|
additionalProperties: false,
|
|
2949
|
-
description: "
|
|
3682
|
+
description: "An icon with a colored radial glow background"
|
|
2950
3683
|
}
|
|
2951
3684
|
},
|
|
2952
3685
|
$schema: "http://json-schema.org/draft-07/schema#"
|
|
2953
3686
|
},
|
|
2954
|
-
tooltip: {
|
|
2955
|
-
$ref: "#/definitions/tooltip",
|
|
3687
|
+
"button-with-tooltip": {
|
|
3688
|
+
$ref: "#/definitions/button-with-tooltip",
|
|
2956
3689
|
definitions: {
|
|
2957
|
-
tooltip: {
|
|
3690
|
+
"button-with-tooltip": {
|
|
2958
3691
|
type: "object",
|
|
2959
3692
|
properties: {
|
|
2960
3693
|
type: {
|
|
2961
3694
|
type: "string",
|
|
2962
|
-
const: "tooltip"
|
|
3695
|
+
const: "button-with-tooltip"
|
|
2963
3696
|
},
|
|
2964
3697
|
props: {
|
|
2965
3698
|
type: "object",
|
|
@@ -3016,68 +3749,7 @@ var component_schema_default = {
|
|
|
3016
3749
|
],
|
|
3017
3750
|
additionalProperties: false
|
|
3018
3751
|
},
|
|
3019
|
-
description: "The
|
|
3020
|
-
}
|
|
3021
|
-
},
|
|
3022
|
-
required: [
|
|
3023
|
-
"type",
|
|
3024
|
-
"props"
|
|
3025
|
-
],
|
|
3026
|
-
additionalProperties: false,
|
|
3027
|
-
description: "A tooltip that appears on hover over its child element"
|
|
3028
|
-
}
|
|
3029
|
-
},
|
|
3030
|
-
$schema: "http://json-schema.org/draft-07/schema#"
|
|
3031
|
-
},
|
|
3032
|
-
table: {
|
|
3033
|
-
$ref: "#/definitions/table",
|
|
3034
|
-
definitions: {
|
|
3035
|
-
table: {
|
|
3036
|
-
type: "object",
|
|
3037
|
-
properties: {
|
|
3038
|
-
type: {
|
|
3039
|
-
type: "string",
|
|
3040
|
-
const: "table"
|
|
3041
|
-
},
|
|
3042
|
-
props: {
|
|
3043
|
-
type: "object",
|
|
3044
|
-
properties: {
|
|
3045
|
-
columns: {
|
|
3046
|
-
type: "array",
|
|
3047
|
-
items: {
|
|
3048
|
-
type: "object",
|
|
3049
|
-
properties: {
|
|
3050
|
-
accessorKey: {
|
|
3051
|
-
type: "string",
|
|
3052
|
-
description: "Key in the row data object"
|
|
3053
|
-
},
|
|
3054
|
-
header: {
|
|
3055
|
-
type: "string",
|
|
3056
|
-
description: "Column header text"
|
|
3057
|
-
}
|
|
3058
|
-
},
|
|
3059
|
-
required: [
|
|
3060
|
-
"accessorKey",
|
|
3061
|
-
"header"
|
|
3062
|
-
],
|
|
3063
|
-
additionalProperties: false
|
|
3064
|
-
},
|
|
3065
|
-
description: "Column definitions"
|
|
3066
|
-
},
|
|
3067
|
-
tableData: {
|
|
3068
|
-
type: "array",
|
|
3069
|
-
items: {
|
|
3070
|
-
type: "object",
|
|
3071
|
-
additionalProperties: {}
|
|
3072
|
-
},
|
|
3073
|
-
description: "Array of row data objects"
|
|
3074
|
-
}
|
|
3075
|
-
},
|
|
3076
|
-
required: [
|
|
3077
|
-
"columns",
|
|
3078
|
-
"tableData"
|
|
3079
|
-
],
|
|
3080
|
-
additionalProperties: false
|
|
3752
|
+
description: "The button element to wrap with a tooltip"
|
|
3081
3753
|
}
|
|
3082
3754
|
},
|
|
3083
3755
|
required: [
|
|
@@ -3085,7 +3757,7 @@ var component_schema_default = {
|
|
|
3085
3757
|
"props"
|
|
3086
3758
|
],
|
|
3087
3759
|
additionalProperties: false,
|
|
3088
|
-
description: "A
|
|
3760
|
+
description: "A button wrapped with a tooltip that appears on hover"
|
|
3089
3761
|
}
|
|
3090
3762
|
},
|
|
3091
3763
|
$schema: "http://json-schema.org/draft-07/schema#"
|
|
@@ -4161,6 +4833,954 @@ var component_schema_default = {
|
|
|
4161
4833
|
}
|
|
4162
4834
|
};
|
|
4163
4835
|
|
|
4836
|
+
// src/types.ts
|
|
4837
|
+
import { z } from "zod";
|
|
4838
|
+
var uiNodeSchema = z.lazy(
|
|
4839
|
+
() => z.object({
|
|
4840
|
+
type: z.string(),
|
|
4841
|
+
props: z.record(z.unknown()).optional(),
|
|
4842
|
+
children: z.array(uiNodeSchema).optional()
|
|
4843
|
+
})
|
|
4844
|
+
);
|
|
4845
|
+
|
|
4846
|
+
// src/ui/Button/schema.ts
|
|
4847
|
+
import { z as z2 } from "zod";
|
|
4848
|
+
var buttonSchema = z2.object({
|
|
4849
|
+
type: z2.literal("button"),
|
|
4850
|
+
props: z2.object({
|
|
4851
|
+
label: z2.string().optional().describe("Button text"),
|
|
4852
|
+
variant: z2.enum(["primary", "secondary", "outline", "destructive", "ghost", "soft"]).optional().describe("Button style. Defaults to 'primary'"),
|
|
4853
|
+
size: z2.enum(["sm", "md", "lg"]).optional().describe("Button size. Defaults to 'md'"),
|
|
4854
|
+
url: z2.string().optional().describe("URL to open when clicked"),
|
|
4855
|
+
disabled: z2.boolean().optional().describe("Whether the button is disabled")
|
|
4856
|
+
}).optional(),
|
|
4857
|
+
children: z2.array(uiNodeSchema).optional()
|
|
4858
|
+
}).describe("An action button");
|
|
4859
|
+
var toolButtonSchema = z2.object({
|
|
4860
|
+
type: z2.literal("tool-button"),
|
|
4861
|
+
props: z2.object({
|
|
4862
|
+
variant: z2.enum(["primary", "outline", "destructive"]).optional().describe("Button style. Defaults to 'primary'"),
|
|
4863
|
+
size: z2.enum(["md", "lg"]).optional().describe("Button size. Defaults to 'md'"),
|
|
4864
|
+
state: z2.enum(["loading", "default"]).optional().describe("Button state. Defaults to 'default'"),
|
|
4865
|
+
onlyIcon: z2.boolean().optional().describe("Icon-only mode with square padding"),
|
|
4866
|
+
disabled: z2.boolean().optional()
|
|
4867
|
+
}).optional(),
|
|
4868
|
+
children: z2.array(uiNodeSchema).optional().describe("Button content")
|
|
4869
|
+
}).describe("A toolbar action button with loading state");
|
|
4870
|
+
|
|
4871
|
+
// src/ui/Card/schema.ts
|
|
4872
|
+
import { z as z3 } from "zod";
|
|
4873
|
+
var cardSchema = z3.object({
|
|
4874
|
+
type: z3.literal("card"),
|
|
4875
|
+
props: z3.object({}).optional(),
|
|
4876
|
+
children: z3.array(uiNodeSchema).optional().describe("Compose with card-header, card-content, card-footer")
|
|
4877
|
+
}).describe("Container card");
|
|
4878
|
+
var cardHeaderSchema = z3.object({
|
|
4879
|
+
type: z3.literal("card-header"),
|
|
4880
|
+
props: z3.object({}).optional(),
|
|
4881
|
+
children: z3.array(uiNodeSchema).optional().describe("Place card-title and card-description inside")
|
|
4882
|
+
}).describe("Header section of a card");
|
|
4883
|
+
var cardTitleSchema = z3.object({
|
|
4884
|
+
type: z3.literal("card-title"),
|
|
4885
|
+
props: z3.object({
|
|
4886
|
+
children: z3.string().optional().describe("Title text")
|
|
4887
|
+
}).optional(),
|
|
4888
|
+
children: z3.array(uiNodeSchema).optional()
|
|
4889
|
+
}).describe("Title inside a card-header");
|
|
4890
|
+
var cardDescriptionSchema = z3.object({
|
|
4891
|
+
type: z3.literal("card-description"),
|
|
4892
|
+
props: z3.object({
|
|
4893
|
+
children: z3.string().optional().describe("Description text")
|
|
4894
|
+
}).optional(),
|
|
4895
|
+
children: z3.array(uiNodeSchema).optional()
|
|
4896
|
+
}).describe("Description text inside a card-header");
|
|
4897
|
+
var cardContentSchema = z3.object({
|
|
4898
|
+
type: z3.literal("card-content"),
|
|
4899
|
+
props: z3.object({}).optional(),
|
|
4900
|
+
children: z3.array(uiNodeSchema).optional().describe("Main content area")
|
|
4901
|
+
}).describe("Main content area of a card");
|
|
4902
|
+
var cardFooterSchema = z3.object({
|
|
4903
|
+
type: z3.literal("card-footer"),
|
|
4904
|
+
props: z3.object({}).optional(),
|
|
4905
|
+
children: z3.array(uiNodeSchema).optional().describe("Footer area, typically for actions")
|
|
4906
|
+
}).describe("Footer section of a card");
|
|
4907
|
+
var cardActionSchema = z3.object({
|
|
4908
|
+
type: z3.literal("card-action"),
|
|
4909
|
+
props: z3.object({}).optional(),
|
|
4910
|
+
children: z3.array(uiNodeSchema).optional().describe("Action elements (buttons, links) placed at the top-right of a card header")
|
|
4911
|
+
}).describe("An action area positioned at the top-right of a card");
|
|
4912
|
+
|
|
4913
|
+
// src/ui/form/schema.ts
|
|
4914
|
+
import { z as z4 } from "zod";
|
|
4915
|
+
var formSchema = z4.object({
|
|
4916
|
+
type: z4.literal("form"),
|
|
4917
|
+
props: z4.object({
|
|
4918
|
+
id: z4.string().describe("Unique form ID")
|
|
4919
|
+
}),
|
|
4920
|
+
children: z4.array(uiNodeSchema).optional().describe("Form field components")
|
|
4921
|
+
}).describe("A form container. Wrap form fields inside.");
|
|
4922
|
+
|
|
4923
|
+
// src/ui/Input/schema.ts
|
|
4924
|
+
import { z as z5 } from "zod";
|
|
4925
|
+
var inputFieldSchema = z5.object({
|
|
4926
|
+
type: z5.literal("input-field"),
|
|
4927
|
+
props: z5.object({
|
|
4928
|
+
name: z5.string().describe("Field name (maps to form data key)"),
|
|
4929
|
+
label: z5.string().optional().describe("Label text above the input"),
|
|
4930
|
+
placeholder: z5.string().optional().describe("Placeholder text"),
|
|
4931
|
+
type: z5.enum(["text", "email", "number", "url", "search", "tel"]).optional().describe("Input type. Defaults to 'text'"),
|
|
4932
|
+
required: z5.boolean().optional().describe("Whether the field is required"),
|
|
4933
|
+
disabled: z5.boolean().optional()
|
|
4934
|
+
})
|
|
4935
|
+
}).describe("A text input field inside a form");
|
|
4936
|
+
|
|
4937
|
+
// src/ui/PasswordInput/schema.ts
|
|
4938
|
+
import { z as z6 } from "zod";
|
|
4939
|
+
var passwordFieldSchema = z6.object({
|
|
4940
|
+
type: z6.literal("password-field"),
|
|
4941
|
+
props: z6.object({
|
|
4942
|
+
name: z6.string().describe("Field name"),
|
|
4943
|
+
label: z6.string().optional().describe("Label text"),
|
|
4944
|
+
placeholder: z6.string().optional()
|
|
4945
|
+
})
|
|
4946
|
+
}).describe("A password input field with show/hide toggle");
|
|
4947
|
+
|
|
4948
|
+
// src/ui/TextAreaInput/schema.ts
|
|
4949
|
+
import { z as z7 } from "zod";
|
|
4950
|
+
var textareaFieldSchema = z7.object({
|
|
4951
|
+
type: z7.literal("textarea-field"),
|
|
4952
|
+
props: z7.object({
|
|
4953
|
+
name: z7.string().describe("Field name"),
|
|
4954
|
+
label: z7.string().optional().describe("Label text"),
|
|
4955
|
+
placeholder: z7.string().optional(),
|
|
4956
|
+
rows: z7.number().optional().describe("Number of visible rows")
|
|
4957
|
+
})
|
|
4958
|
+
}).describe("A multi-line text input field");
|
|
4959
|
+
|
|
4960
|
+
// src/ui/SelectInput/schema.ts
|
|
4961
|
+
import { z as z8 } from "zod";
|
|
4962
|
+
var selectFieldSchema = z8.object({
|
|
4963
|
+
type: z8.literal("select-field"),
|
|
4964
|
+
props: z8.object({
|
|
4965
|
+
name: z8.string().describe("Field name"),
|
|
4966
|
+
label: z8.string().optional().describe("Label text"),
|
|
4967
|
+
placeholder: z8.string().optional(),
|
|
4968
|
+
options: z8.array(z8.object({
|
|
4969
|
+
label: z8.string().describe("Display text"),
|
|
4970
|
+
value: z8.string().describe("Option value")
|
|
4971
|
+
})).describe("Array of selectable options"),
|
|
4972
|
+
required: z8.boolean().optional()
|
|
4973
|
+
})
|
|
4974
|
+
}).describe("A dropdown select field");
|
|
4975
|
+
|
|
4976
|
+
// src/ui/Checkbox/schema.ts
|
|
4977
|
+
import { z as z9 } from "zod";
|
|
4978
|
+
var checkboxFieldSchema = z9.object({
|
|
4979
|
+
type: z9.literal("checkbox-field"),
|
|
4980
|
+
props: z9.object({
|
|
4981
|
+
name: z9.string().describe("Field name"),
|
|
4982
|
+
label: z9.string().optional().describe("Checkbox label text")
|
|
4983
|
+
})
|
|
4984
|
+
}).describe("A checkbox field");
|
|
4985
|
+
|
|
4986
|
+
// src/ui/Radio/schema.ts
|
|
4987
|
+
import { z as z10 } from "zod";
|
|
4988
|
+
var radioFieldSchema = z10.object({
|
|
4989
|
+
type: z10.literal("radio-field"),
|
|
4990
|
+
props: z10.object({
|
|
4991
|
+
name: z10.string().describe("Field name"),
|
|
4992
|
+
label: z10.string().optional().describe("Group label"),
|
|
4993
|
+
options: z10.array(z10.object({
|
|
4994
|
+
label: z10.string().describe("Option label"),
|
|
4995
|
+
value: z10.string().describe("Option value")
|
|
4996
|
+
})).describe("Array of radio options")
|
|
4997
|
+
})
|
|
4998
|
+
}).describe("A radio button group field");
|
|
4999
|
+
|
|
5000
|
+
// src/ui/Switch/schema.ts
|
|
5001
|
+
import { z as z11 } from "zod";
|
|
5002
|
+
var switchFieldSchema = z11.object({
|
|
5003
|
+
type: z11.literal("switch-field"),
|
|
5004
|
+
props: z11.object({
|
|
5005
|
+
name: z11.string().describe("Field name"),
|
|
5006
|
+
label: z11.string().optional().describe("Switch label")
|
|
5007
|
+
})
|
|
5008
|
+
}).describe("A toggle switch field");
|
|
5009
|
+
|
|
5010
|
+
// src/ui/DatePickerInput/schema.ts
|
|
5011
|
+
import { z as z12 } from "zod";
|
|
5012
|
+
var dateFieldSchema = z12.object({
|
|
5013
|
+
type: z12.literal("date-field"),
|
|
5014
|
+
props: z12.object({
|
|
5015
|
+
name: z12.string().describe("Field name"),
|
|
5016
|
+
label: z12.string().optional().describe("Label text"),
|
|
5017
|
+
placeholder: z12.string().optional(),
|
|
5018
|
+
disablePast: z12.boolean().optional().describe("Disable past dates"),
|
|
5019
|
+
required: z12.boolean().optional()
|
|
5020
|
+
})
|
|
5021
|
+
}).describe("A date picker field");
|
|
5022
|
+
|
|
5023
|
+
// src/ui/TimePicker/schema.ts
|
|
5024
|
+
import { z as z13 } from "zod";
|
|
5025
|
+
var timeFieldSchema = z13.object({
|
|
5026
|
+
type: z13.literal("time-field"),
|
|
5027
|
+
props: z13.object({
|
|
5028
|
+
name: z13.string().describe("Field name"),
|
|
5029
|
+
label: z13.string().optional().describe("Label text")
|
|
5030
|
+
})
|
|
5031
|
+
}).describe("A time picker field");
|
|
5032
|
+
|
|
5033
|
+
// src/ui/Combobox/schema.ts
|
|
5034
|
+
import { z as z14 } from "zod";
|
|
5035
|
+
var comboboxFieldSchema = z14.object({
|
|
5036
|
+
type: z14.literal("combobox-field"),
|
|
5037
|
+
props: z14.object({
|
|
5038
|
+
name: z14.string().describe("Field name"),
|
|
5039
|
+
label: z14.string().optional().describe("Label text"),
|
|
5040
|
+
placeholder: z14.string().optional(),
|
|
5041
|
+
options: z14.array(z14.object({
|
|
5042
|
+
label: z14.string().describe("Display text"),
|
|
5043
|
+
value: z14.string().describe("Option value")
|
|
5044
|
+
})).describe("Array of searchable options")
|
|
5045
|
+
})
|
|
5046
|
+
}).describe("A searchable combobox/autocomplete field");
|
|
5047
|
+
|
|
5048
|
+
// src/ui/MultiSelect/schema.ts
|
|
5049
|
+
import { z as z15 } from "zod";
|
|
5050
|
+
var multiSelectFieldSchema = z15.object({
|
|
5051
|
+
type: z15.literal("multi-select-field"),
|
|
5052
|
+
props: z15.object({
|
|
5053
|
+
name: z15.string().describe("Field name"),
|
|
5054
|
+
label: z15.string().optional().describe("Label text"),
|
|
5055
|
+
placeholder: z15.string().optional(),
|
|
5056
|
+
options: z15.array(z15.object({
|
|
5057
|
+
label: z15.string().describe("Display text"),
|
|
5058
|
+
value: z15.string().describe("Option value")
|
|
5059
|
+
})).describe("Array of options for multi-selection")
|
|
5060
|
+
})
|
|
5061
|
+
}).describe("A multi-select dropdown field");
|
|
5062
|
+
|
|
5063
|
+
// src/ui/OTPInput/schema.ts
|
|
5064
|
+
import { z as z16 } from "zod";
|
|
5065
|
+
var otpFieldSchema = z16.object({
|
|
5066
|
+
type: z16.literal("otp-field"),
|
|
5067
|
+
props: z16.object({
|
|
5068
|
+
name: z16.string().describe("Field name"),
|
|
5069
|
+
maxLength: z16.number().optional().describe("Number of OTP digits. Defaults to 6")
|
|
5070
|
+
})
|
|
5071
|
+
}).describe("An OTP (one-time password) input field");
|
|
5072
|
+
|
|
5073
|
+
// src/ui/FileUpload/schema.ts
|
|
5074
|
+
import { z as z17 } from "zod";
|
|
5075
|
+
var fileUploadFieldSchema = z17.object({
|
|
5076
|
+
type: z17.literal("file-upload-field"),
|
|
5077
|
+
props: z17.object({
|
|
5078
|
+
name: z17.string().describe("Field name"),
|
|
5079
|
+
label: z17.string().optional().describe("Label text"),
|
|
5080
|
+
isMultiple: z17.boolean().optional().describe("Allow multiple files"),
|
|
5081
|
+
maxFiles: z17.number().optional().describe("Maximum number of files")
|
|
5082
|
+
})
|
|
5083
|
+
}).describe("A file upload field with drag-and-drop");
|
|
5084
|
+
|
|
5085
|
+
// src/ui/Text/schema.ts
|
|
5086
|
+
import { z as z18 } from "zod";
|
|
5087
|
+
var textSchema = z18.object({
|
|
5088
|
+
type: z18.literal("text"),
|
|
5089
|
+
props: z18.object({
|
|
5090
|
+
children: z18.string().optional().describe("Text content")
|
|
5091
|
+
}).optional(),
|
|
5092
|
+
children: z18.array(uiNodeSchema).optional()
|
|
5093
|
+
}).describe("A paragraph of text");
|
|
5094
|
+
|
|
5095
|
+
// src/ui/Title/schema.ts
|
|
5096
|
+
import { z as z19 } from "zod";
|
|
5097
|
+
var titleSchema = z19.object({
|
|
5098
|
+
type: z19.literal("title"),
|
|
5099
|
+
props: z19.object({
|
|
5100
|
+
children: z19.string().optional().describe("Heading text")
|
|
5101
|
+
}).optional(),
|
|
5102
|
+
children: z19.array(uiNodeSchema).optional()
|
|
5103
|
+
}).describe("A heading / title element");
|
|
5104
|
+
|
|
5105
|
+
// src/ui/Label/schema.ts
|
|
5106
|
+
import { z as z20 } from "zod";
|
|
5107
|
+
var labelSchema = z20.object({
|
|
5108
|
+
type: z20.literal("label"),
|
|
5109
|
+
props: z20.object({
|
|
5110
|
+
children: z20.string().optional().describe("Label text"),
|
|
5111
|
+
htmlFor: z20.string().optional().describe("ID of the form element this label is for")
|
|
5112
|
+
}).optional(),
|
|
5113
|
+
children: z20.array(uiNodeSchema).optional()
|
|
5114
|
+
}).describe("A form label element");
|
|
5115
|
+
|
|
5116
|
+
// src/ui/Badge/schema.ts
|
|
5117
|
+
import { z as z21 } from "zod";
|
|
5118
|
+
var badgeSchema = z21.object({
|
|
5119
|
+
type: z21.literal("badge"),
|
|
5120
|
+
props: z21.object({
|
|
5121
|
+
children: z21.string().optional().describe("Badge text"),
|
|
5122
|
+
type: z21.enum([
|
|
5123
|
+
"primary-hard",
|
|
5124
|
+
"primary-soft",
|
|
5125
|
+
"destructive-hard",
|
|
5126
|
+
"destructive-soft",
|
|
5127
|
+
"secondary-hard",
|
|
5128
|
+
"secondary-soft"
|
|
5129
|
+
]).optional().describe("Badge style. Defaults to 'primary-hard'"),
|
|
5130
|
+
size: z21.enum(["sm", "md"]).optional().describe("Badge size. Defaults to 'sm'"),
|
|
5131
|
+
rounded: z21.boolean().optional().describe("Fully rounded pill shape")
|
|
5132
|
+
}).optional(),
|
|
5133
|
+
children: z21.array(uiNodeSchema).optional()
|
|
5134
|
+
}).describe("A small status badge / label");
|
|
5135
|
+
|
|
5136
|
+
// src/ui/Tag/schema.ts
|
|
5137
|
+
import { z as z22 } from "zod";
|
|
5138
|
+
var tagSchema = z22.object({
|
|
5139
|
+
type: z22.literal("tag"),
|
|
5140
|
+
props: z22.object({
|
|
5141
|
+
label: z22.string().describe("Tag text"),
|
|
5142
|
+
variant: z22.enum(["primary", "secondary", "destructive"]).optional().describe("Tag color variant. Defaults to 'primary'")
|
|
5143
|
+
})
|
|
5144
|
+
}).describe("A colored tag / pill");
|
|
5145
|
+
|
|
5146
|
+
// src/ui/Chip/schema.ts
|
|
5147
|
+
import { z as z23 } from "zod";
|
|
5148
|
+
var chipSchema = z23.object({
|
|
5149
|
+
type: z23.literal("chip"),
|
|
5150
|
+
props: z23.object({
|
|
5151
|
+
label: z23.string().describe("Chip text"),
|
|
5152
|
+
type: z23.enum(["rounded", "rectangle"]).optional().describe("Chip shape. Defaults to 'rounded'"),
|
|
5153
|
+
color: z23.enum([
|
|
5154
|
+
"slate",
|
|
5155
|
+
"red",
|
|
5156
|
+
"orange",
|
|
5157
|
+
"amber",
|
|
5158
|
+
"yellow",
|
|
5159
|
+
"lime",
|
|
5160
|
+
"green",
|
|
5161
|
+
"emerald",
|
|
5162
|
+
"teal",
|
|
5163
|
+
"cyan",
|
|
5164
|
+
"sky",
|
|
5165
|
+
"blue",
|
|
5166
|
+
"indigo",
|
|
5167
|
+
"violet",
|
|
5168
|
+
"purple",
|
|
5169
|
+
"fuchsia",
|
|
5170
|
+
"pink",
|
|
5171
|
+
"rose"
|
|
5172
|
+
]).optional().describe("Chip color. Defaults to 'slate'"),
|
|
5173
|
+
dot: z23.boolean().optional().describe("Show a colored dot indicator"),
|
|
5174
|
+
avatar: z23.string().optional().describe("Avatar image URL shown inside the chip")
|
|
5175
|
+
})
|
|
5176
|
+
}).describe("A compact chip element with optional color dot or avatar");
|
|
5177
|
+
|
|
5178
|
+
// src/ui/Alert/schema.ts
|
|
5179
|
+
import { z as z24 } from "zod";
|
|
5180
|
+
var alertSchema = z24.object({
|
|
5181
|
+
type: z24.literal("alert"),
|
|
5182
|
+
props: z24.object({
|
|
5183
|
+
variant: z24.enum(["default", "secondary", "destructive"]).optional().describe("Alert style. Defaults to 'default'"),
|
|
5184
|
+
title: z24.string().optional().describe("Alert heading"),
|
|
5185
|
+
description: z24.string().optional().describe("Alert body text")
|
|
5186
|
+
}).optional(),
|
|
5187
|
+
children: z24.array(uiNodeSchema).optional()
|
|
5188
|
+
}).describe("An alert / notice banner");
|
|
5189
|
+
|
|
5190
|
+
// src/ui/Skeleton/schema.ts
|
|
5191
|
+
import { z as z25 } from "zod";
|
|
5192
|
+
var skeletonSchema = z25.object({
|
|
5193
|
+
type: z25.literal("skeleton"),
|
|
5194
|
+
props: z25.object({
|
|
5195
|
+
className: z25.string().optional().describe("Tailwind classes to control width/height, e.g. 'h-4 w-[250px]'")
|
|
5196
|
+
}).optional()
|
|
5197
|
+
}).describe("A loading placeholder skeleton");
|
|
5198
|
+
|
|
5199
|
+
// src/ui/ProgressIndicator/schema.ts
|
|
5200
|
+
import { z as z26 } from "zod";
|
|
5201
|
+
var progressIndicatorSchema = z26.object({
|
|
5202
|
+
type: z26.literal("progress-indicator"),
|
|
5203
|
+
props: z26.object({
|
|
5204
|
+
value: z26.number().describe("Current progress value"),
|
|
5205
|
+
max: z26.number().optional().describe("Maximum value. Defaults to 100"),
|
|
5206
|
+
showPercentage: z26.boolean().optional().describe("Show percentage text. Defaults to true"),
|
|
5207
|
+
variant: z26.enum(["bar", "circle"]).optional().describe("Display style. Defaults to 'bar'")
|
|
5208
|
+
})
|
|
5209
|
+
}).describe("A progress bar or circular progress indicator");
|
|
5210
|
+
|
|
5211
|
+
// src/ui/Avatar/schema.ts
|
|
5212
|
+
import { z as z27 } from "zod";
|
|
5213
|
+
var avatarSchema = z27.object({
|
|
5214
|
+
type: z27.literal("avatar"),
|
|
5215
|
+
props: z27.object({
|
|
5216
|
+
variant: z27.enum(["image", "text", "placeholder"]).describe("Avatar display mode"),
|
|
5217
|
+
fallback: z27.string().describe("Fallback text (initials) when image is unavailable"),
|
|
5218
|
+
imgsrc: z27.string().optional().describe("Image URL (required when variant is 'image')"),
|
|
5219
|
+
size: z27.enum(["xs", "sm", "md", "lg", "xl", "2xl", "3xl", "4xl", "5xl"]).optional().describe("Avatar size. Defaults to 'md'"),
|
|
5220
|
+
status: z27.enum(["active", "inactive"]).optional().describe("Online status indicator")
|
|
5221
|
+
})
|
|
5222
|
+
}).describe("A user avatar displaying an image, initials, or placeholder");
|
|
5223
|
+
|
|
5224
|
+
// src/ui/AvatarListItem/schema.ts
|
|
5225
|
+
import { z as z28 } from "zod";
|
|
5226
|
+
var avatarListItemSchema = z28.object({
|
|
5227
|
+
type: z28.literal("avatar-list-item"),
|
|
5228
|
+
props: z28.object({
|
|
5229
|
+
avatar: z28.string().describe("Avatar image URL"),
|
|
5230
|
+
name: z28.string().describe("Display name"),
|
|
5231
|
+
email: z28.string().describe("Email address"),
|
|
5232
|
+
isMe: z28.boolean().optional().describe("Highlight as current user")
|
|
5233
|
+
})
|
|
5234
|
+
}).describe("An avatar with name and email, typically used in lists");
|
|
5235
|
+
|
|
5236
|
+
// src/ui/Media/schema.ts
|
|
5237
|
+
import { z as z29 } from "zod";
|
|
5238
|
+
var mediaSchema = z29.object({
|
|
5239
|
+
type: z29.literal("media"),
|
|
5240
|
+
props: z29.object({
|
|
5241
|
+
src: z29.string().describe("Media source URL"),
|
|
5242
|
+
alt: z29.string().optional().describe("Alt text for images"),
|
|
5243
|
+
type: z29.enum(["image", "video"]).optional().describe("Media type. Defaults to 'image'"),
|
|
5244
|
+
aspectRatio: z29.enum(["1:1", "16:9", "9:16", "4:3", "3:4"]).optional().describe("Fixed aspect ratio"),
|
|
5245
|
+
objectFit: z29.enum(["cover", "contain", "fill", "scale-down", "none"]).optional().describe("How the media fills its container. Defaults to 'cover'"),
|
|
5246
|
+
rounded: z29.enum(["none", "sm", "md", "lg", "xl", "2xl", "full"]).optional().describe("Border radius"),
|
|
5247
|
+
loading: z29.enum(["lazy", "eager"]).optional().describe("Loading strategy. Defaults to 'lazy'")
|
|
5248
|
+
})
|
|
5249
|
+
}).describe("An image or video media element");
|
|
5250
|
+
|
|
5251
|
+
// src/ui/Grid/schema.ts
|
|
5252
|
+
import { z as z30 } from "zod";
|
|
5253
|
+
var gridSchema = z30.object({
|
|
5254
|
+
type: z30.literal("grid"),
|
|
5255
|
+
props: z30.object({
|
|
5256
|
+
className: z30.string().optional().describe("Tailwind grid classes, e.g. 'grid-cols-2 gap-4'")
|
|
5257
|
+
}).optional(),
|
|
5258
|
+
children: z30.array(uiNodeSchema).optional().describe("Grid items")
|
|
5259
|
+
}).describe("A CSS grid layout container");
|
|
5260
|
+
|
|
5261
|
+
// src/ui/Accordion/schema.ts
|
|
5262
|
+
import { z as z31 } from "zod";
|
|
5263
|
+
var accordionSchema = z31.object({
|
|
5264
|
+
type: z31.literal("accordion"),
|
|
5265
|
+
props: z31.object({
|
|
5266
|
+
type: z31.enum(["single", "multiple"]).optional().describe("Allow one or multiple items open. Defaults to 'single'"),
|
|
5267
|
+
collapsible: z31.boolean().optional().describe("Allow collapsing all items"),
|
|
5268
|
+
defaultValue: z31.union([z31.string(), z31.array(z31.string())]).optional().describe("Initially open item value(s)")
|
|
5269
|
+
}).optional(),
|
|
5270
|
+
children: z31.array(uiNodeSchema).optional().describe("Compose with accordion-item children")
|
|
5271
|
+
}).describe("A collapsible accordion container");
|
|
5272
|
+
var accordionItemSchema = z31.object({
|
|
5273
|
+
type: z31.literal("accordion-item"),
|
|
5274
|
+
props: z31.object({
|
|
5275
|
+
value: z31.string().describe("Unique item identifier")
|
|
5276
|
+
}),
|
|
5277
|
+
children: z31.array(uiNodeSchema).optional().describe("Place accordion-trigger and accordion-content inside")
|
|
5278
|
+
}).describe("A single accordion section");
|
|
5279
|
+
var accordionTriggerSchema = z31.object({
|
|
5280
|
+
type: z31.literal("accordion-trigger"),
|
|
5281
|
+
props: z31.object({
|
|
5282
|
+
children: z31.string().optional().describe("Trigger label text")
|
|
5283
|
+
}).optional(),
|
|
5284
|
+
children: z31.array(uiNodeSchema).optional()
|
|
5285
|
+
}).describe("Clickable header that toggles an accordion-item");
|
|
5286
|
+
var accordionContentSchema = z31.object({
|
|
5287
|
+
type: z31.literal("accordion-content"),
|
|
5288
|
+
props: z31.object({}).optional(),
|
|
5289
|
+
children: z31.array(uiNodeSchema).optional().describe("Content revealed when the item is open")
|
|
5290
|
+
}).describe("Collapsible content area of an accordion-item");
|
|
5291
|
+
|
|
5292
|
+
// src/ui/Tabs/schema.ts
|
|
5293
|
+
import { z as z32 } from "zod";
|
|
5294
|
+
var tabsSchema = z32.object({
|
|
5295
|
+
type: z32.literal("tabs"),
|
|
5296
|
+
props: z32.object({
|
|
5297
|
+
defaultActiveTab: z32.string().describe("Value of the initially active tab"),
|
|
5298
|
+
tabs: z32.array(
|
|
5299
|
+
z32.object({
|
|
5300
|
+
value: z32.string().describe("Unique tab identifier"),
|
|
5301
|
+
label: z32.string().describe("Tab label text"),
|
|
5302
|
+
count: z32.number().optional().describe("Badge count on the tab"),
|
|
5303
|
+
notification: z32.boolean().optional().describe("Show notification dot")
|
|
5304
|
+
})
|
|
5305
|
+
).describe("Tab definitions"),
|
|
5306
|
+
tabSmall: z32.boolean().optional().describe("Use compact tab styling"),
|
|
5307
|
+
showContent: z32.boolean().optional().describe("Show tab content panels. Defaults to true")
|
|
5308
|
+
}),
|
|
5309
|
+
children: z32.array(uiNodeSchema).optional().describe("Tab content panels (one per tab, in order)")
|
|
5310
|
+
}).describe("A tabbed interface with switchable content panels");
|
|
5311
|
+
|
|
5312
|
+
// src/ui/WrapperCard/schema.ts
|
|
5313
|
+
import { z as z33 } from "zod";
|
|
5314
|
+
var wrapperCardSchema = z33.object({
|
|
5315
|
+
type: z33.literal("wrapper-card"),
|
|
5316
|
+
props: z33.object({}).optional(),
|
|
5317
|
+
children: z33.array(uiNodeSchema).optional().describe("Card body content")
|
|
5318
|
+
}).describe("A simple card wrapper with default padding and border");
|
|
5319
|
+
|
|
5320
|
+
// src/ui/GradientContainer/schema.ts
|
|
5321
|
+
import { z as z34 } from "zod";
|
|
5322
|
+
var gradientContainerSchema = z34.object({
|
|
5323
|
+
type: z34.literal("gradient-container"),
|
|
5324
|
+
props: z34.object({}).optional(),
|
|
5325
|
+
children: z34.array(uiNodeSchema).optional().describe("Content inside the gradient container")
|
|
5326
|
+
}).describe("A container with a gradient background");
|
|
5327
|
+
|
|
5328
|
+
// src/ui/Carousel/schema.ts
|
|
5329
|
+
import { z as z35 } from "zod";
|
|
5330
|
+
var carouselSchema = z35.object({
|
|
5331
|
+
type: z35.literal("carousel"),
|
|
5332
|
+
props: z35.object({
|
|
5333
|
+
orientation: z35.enum(["horizontal", "vertical"]).optional().describe("Scroll direction. Defaults to 'horizontal'")
|
|
5334
|
+
}).optional(),
|
|
5335
|
+
children: z35.array(uiNodeSchema).optional().describe("Place a carousel-content inside")
|
|
5336
|
+
}).describe("A scrollable carousel container");
|
|
5337
|
+
var carouselContentSchema = z35.object({
|
|
5338
|
+
type: z35.literal("carousel-content"),
|
|
5339
|
+
props: z35.object({}).optional(),
|
|
5340
|
+
children: z35.array(uiNodeSchema).optional().describe("Compose with carousel-item children")
|
|
5341
|
+
}).describe("Content track of a carousel");
|
|
5342
|
+
var carouselItemSchema = z35.object({
|
|
5343
|
+
type: z35.literal("carousel-item"),
|
|
5344
|
+
props: z35.object({}).optional(),
|
|
5345
|
+
children: z35.array(uiNodeSchema).optional().describe("Content for this slide")
|
|
5346
|
+
}).describe("A single slide inside a carousel");
|
|
5347
|
+
|
|
5348
|
+
// src/ui/Toggle/schema.ts
|
|
5349
|
+
import { z as z36 } from "zod";
|
|
5350
|
+
var toggleSchema = z36.object({
|
|
5351
|
+
type: z36.literal("toggle"),
|
|
5352
|
+
props: z36.object({
|
|
5353
|
+
active: z36.boolean().optional().describe("Whether the toggle is pressed"),
|
|
5354
|
+
shape: z36.enum(["rectangle", "rounded"]).optional().describe("Toggle shape. Defaults to 'rectangle'"),
|
|
5355
|
+
style: z36.enum(["ghost", "outline", "soft"]).optional().describe("Visual style. Defaults to 'soft'"),
|
|
5356
|
+
size: z36.enum(["sm", "md", "lg"]).optional().describe("Toggle size. Defaults to 'sm'"),
|
|
5357
|
+
disabled: z36.boolean().optional()
|
|
5358
|
+
}).optional(),
|
|
5359
|
+
children: z36.array(uiNodeSchema).optional().describe("Toggle label / content")
|
|
5360
|
+
}).describe("A pressable toggle button");
|
|
5361
|
+
|
|
5362
|
+
// src/ui/Slider/schema.ts
|
|
5363
|
+
import { z as z37 } from "zod";
|
|
5364
|
+
var sliderSchema = z37.object({
|
|
5365
|
+
type: z37.literal("slider"),
|
|
5366
|
+
props: z37.object({
|
|
5367
|
+
defaultValue: z37.union([z37.number(), z37.array(z37.number())]).optional().describe("Initial value or range [min, max]"),
|
|
5368
|
+
min: z37.number().optional().describe("Minimum value. Defaults to 0"),
|
|
5369
|
+
max: z37.number().optional().describe("Maximum value. Defaults to 100"),
|
|
5370
|
+
step: z37.number().optional().describe("Step increment"),
|
|
5371
|
+
disabled: z37.boolean().optional()
|
|
5372
|
+
}).optional()
|
|
5373
|
+
}).describe("A range slider input");
|
|
5374
|
+
|
|
5375
|
+
// src/ui/SearchInput/schema.ts
|
|
5376
|
+
import { z as z38 } from "zod";
|
|
5377
|
+
var searchInputSchema = z38.object({
|
|
5378
|
+
type: z38.literal("search-input"),
|
|
5379
|
+
props: z38.object({
|
|
5380
|
+
searchKey: z38.string().describe("URL query param key for the search value"),
|
|
5381
|
+
placeholder: z38.string().optional().describe("Placeholder text. Defaults to 'Search by...'"),
|
|
5382
|
+
debounceDelay: z38.number().optional().describe("Debounce delay in ms. Defaults to 500"),
|
|
5383
|
+
variant: z38.enum(["ghost", "outline"]).optional().describe("Input style variant"),
|
|
5384
|
+
disabled: z38.boolean().optional()
|
|
5385
|
+
})
|
|
5386
|
+
}).describe("A search input with debounced query param binding");
|
|
5387
|
+
|
|
5388
|
+
// src/ui/IconButton/schema.ts
|
|
5389
|
+
import { z as z39 } from "zod";
|
|
5390
|
+
var iconButtonSchema = z39.object({
|
|
5391
|
+
type: z39.literal("icon-button"),
|
|
5392
|
+
props: z39.object({
|
|
5393
|
+
icon: z39.string().describe("Icon name (resolved by the renderer)"),
|
|
5394
|
+
variant: z39.enum([
|
|
5395
|
+
"primary",
|
|
5396
|
+
"secondary",
|
|
5397
|
+
"destructive",
|
|
5398
|
+
"outline",
|
|
5399
|
+
"ghost",
|
|
5400
|
+
"soft",
|
|
5401
|
+
"ai-filled",
|
|
5402
|
+
"ai-outline",
|
|
5403
|
+
"glass"
|
|
5404
|
+
]).optional().describe("Button style. Defaults to 'primary'"),
|
|
5405
|
+
size: z39.enum(["xs", "sm", "md", "lg"]).optional().describe("Button size. Defaults to 'sm'"),
|
|
5406
|
+
active: z39.boolean().optional().describe("Active / pressed state"),
|
|
5407
|
+
rounded: z39.boolean().optional().describe("Fully round button"),
|
|
5408
|
+
disabled: z39.boolean().optional()
|
|
5409
|
+
})
|
|
5410
|
+
}).describe("An icon-only action button");
|
|
5411
|
+
|
|
5412
|
+
// src/ui/LinkButton/schema.ts
|
|
5413
|
+
import { z as z40 } from "zod";
|
|
5414
|
+
var linkButtonSchema = z40.object({
|
|
5415
|
+
type: z40.literal("link-button"),
|
|
5416
|
+
props: z40.object({
|
|
5417
|
+
href: z40.string().describe("Link URL"),
|
|
5418
|
+
children: z40.string().optional().describe("Link text")
|
|
5419
|
+
}),
|
|
5420
|
+
children: z40.array(uiNodeSchema).optional()
|
|
5421
|
+
}).describe("A button styled as a navigation link");
|
|
5422
|
+
|
|
5423
|
+
// src/ui/ButtonLink/schema.ts
|
|
5424
|
+
import { z as z41 } from "zod";
|
|
5425
|
+
var buttonLinkSchema = z41.object({
|
|
5426
|
+
type: z41.literal("button-link"),
|
|
5427
|
+
props: z41.object({
|
|
5428
|
+
children: z41.string().optional().describe("Link text"),
|
|
5429
|
+
variant: z41.enum(["link", "text-link", "error"]).optional().describe("Link style. Defaults to 'link'"),
|
|
5430
|
+
href: z41.string().optional().describe("Link URL"),
|
|
5431
|
+
disabled: z41.boolean().optional()
|
|
5432
|
+
}).optional(),
|
|
5433
|
+
children: z41.array(uiNodeSchema).optional()
|
|
5434
|
+
}).describe("An inline text link styled as a button");
|
|
5435
|
+
|
|
5436
|
+
// src/ui/SelectHover/schema.ts
|
|
5437
|
+
import { z as z42 } from "zod";
|
|
5438
|
+
var selectHoverSchema = z42.object({
|
|
5439
|
+
type: z42.literal("select-hover"),
|
|
5440
|
+
props: z42.object({
|
|
5441
|
+
options: z42.array(
|
|
5442
|
+
z42.object({
|
|
5443
|
+
label: z42.string().describe("Display text"),
|
|
5444
|
+
value: z42.string().describe("Option value")
|
|
5445
|
+
})
|
|
5446
|
+
).describe("Array of selectable options"),
|
|
5447
|
+
placeholder: z42.string().optional().describe("Placeholder text. Defaults to 'Select an option'"),
|
|
5448
|
+
value: z42.string().optional().describe("Currently selected value")
|
|
5449
|
+
})
|
|
5450
|
+
}).describe("A hover-activated select dropdown");
|
|
5451
|
+
|
|
5452
|
+
// src/ui/Breadcrumb/schema.ts
|
|
5453
|
+
import { z as z43 } from "zod";
|
|
5454
|
+
var breadcrumbSchema = z43.object({
|
|
5455
|
+
type: z43.literal("breadcrumb"),
|
|
5456
|
+
props: z43.object({
|
|
5457
|
+
items: z43.array(
|
|
5458
|
+
z43.object({
|
|
5459
|
+
label: z43.string().describe("Breadcrumb text"),
|
|
5460
|
+
href: z43.string().optional().describe("Navigation URL"),
|
|
5461
|
+
disabled: z43.boolean().optional()
|
|
5462
|
+
})
|
|
5463
|
+
).describe("Ordered list of breadcrumb segments")
|
|
5464
|
+
})
|
|
5465
|
+
}).describe("A breadcrumb navigation trail");
|
|
5466
|
+
|
|
5467
|
+
// src/ui/Tooltip/schema.ts
|
|
5468
|
+
import { z as z44 } from "zod";
|
|
5469
|
+
var tooltipSchema = z44.object({
|
|
5470
|
+
type: z44.literal("tooltip"),
|
|
5471
|
+
props: z44.object({
|
|
5472
|
+
content: z44.string().describe("Tooltip text"),
|
|
5473
|
+
position: z44.enum([
|
|
5474
|
+
"top",
|
|
5475
|
+
"top-center",
|
|
5476
|
+
"top-left",
|
|
5477
|
+
"top-right",
|
|
5478
|
+
"bottom",
|
|
5479
|
+
"bottom-left",
|
|
5480
|
+
"bottom-center",
|
|
5481
|
+
"bottom-right",
|
|
5482
|
+
"left",
|
|
5483
|
+
"right"
|
|
5484
|
+
]).optional().describe("Tooltip placement"),
|
|
5485
|
+
withArrow: z44.boolean().optional().describe("Show an arrow pointer")
|
|
5486
|
+
}),
|
|
5487
|
+
children: z44.array(uiNodeSchema).optional().describe("The trigger element the tooltip wraps")
|
|
5488
|
+
}).describe("A tooltip that appears on hover over its child element");
|
|
5489
|
+
|
|
5490
|
+
// src/ui/Table/schema.ts
|
|
5491
|
+
import { z as z45 } from "zod";
|
|
5492
|
+
var tableSchema = z45.object({
|
|
5493
|
+
type: z45.literal("table"),
|
|
5494
|
+
props: z45.object({
|
|
5495
|
+
columns: z45.array(
|
|
5496
|
+
z45.object({
|
|
5497
|
+
accessorKey: z45.string().describe("Key in the row data object"),
|
|
5498
|
+
header: z45.string().describe("Column header text")
|
|
5499
|
+
})
|
|
5500
|
+
).describe("Column definitions"),
|
|
5501
|
+
tableData: z45.array(z45.record(z45.unknown())).describe("Array of row data objects")
|
|
5502
|
+
})
|
|
5503
|
+
}).describe("A data table with columns and rows");
|
|
5504
|
+
|
|
5505
|
+
// src/ui/Map/schema.ts
|
|
5506
|
+
import { z as z46 } from "zod";
|
|
5507
|
+
var mapMarkerSchema = z46.object({
|
|
5508
|
+
lat: z46.number().describe("Latitude"),
|
|
5509
|
+
lng: z46.number().describe("Longitude"),
|
|
5510
|
+
title: z46.string().optional().describe("Marker title shown in info window"),
|
|
5511
|
+
description: z46.string().optional().describe("Marker description shown in info window"),
|
|
5512
|
+
color: z46.string().optional().describe("Marker pin color (hex or CSS color)")
|
|
5513
|
+
});
|
|
5514
|
+
var googleMapSchema = z46.object({
|
|
5515
|
+
type: z46.literal("google-map"),
|
|
5516
|
+
props: z46.object({
|
|
5517
|
+
center: z46.object({
|
|
5518
|
+
lat: z46.number().describe("Center latitude"),
|
|
5519
|
+
lng: z46.number().describe("Center longitude")
|
|
5520
|
+
}).optional().describe("Map center coordinates"),
|
|
5521
|
+
zoom: z46.number().optional().describe("Zoom level (1-20). Defaults to 12"),
|
|
5522
|
+
markers: z46.array(mapMarkerSchema).optional().describe("Array of map markers with lat/lng and optional info"),
|
|
5523
|
+
height: z46.string().optional().describe("Map height CSS value. Defaults to '400px'"),
|
|
5524
|
+
width: z46.string().optional().describe("Map width CSS value. Defaults to '100%'"),
|
|
5525
|
+
gestureHandling: z46.enum(["cooperative", "greedy", "none", "auto"]).optional().describe("How the map handles touch/scroll gestures. Defaults to 'cooperative'"),
|
|
5526
|
+
disableDefaultUI: z46.boolean().optional().describe("Hide default map controls")
|
|
5527
|
+
})
|
|
5528
|
+
}).describe("An interactive Google Map with optional markers and info windows");
|
|
5529
|
+
|
|
5530
|
+
// src/ui/Calendar/schema.ts
|
|
5531
|
+
import { z as z47 } from "zod";
|
|
5532
|
+
var calendarSchema = z47.object({
|
|
5533
|
+
type: z47.literal("calendar"),
|
|
5534
|
+
props: z47.object({
|
|
5535
|
+
showOutsideDays: z47.boolean().optional().describe("Show days from adjacent months. Defaults to true"),
|
|
5536
|
+
captionLayout: z47.enum(["label", "dropdown", "dropdown-months", "dropdown-years"]).optional().describe("Caption display mode. Defaults to 'label'"),
|
|
5537
|
+
buttonVariant: z47.enum(["primary", "secondary", "outline", "destructive", "ghost", "soft"]).optional().describe("Navigation button style. Defaults to 'ghost'"),
|
|
5538
|
+
mode: z47.enum(["single", "multiple", "range"]).optional().describe("Selection mode"),
|
|
5539
|
+
numberOfMonths: z47.number().optional().describe("Number of months to display"),
|
|
5540
|
+
disabled: z47.boolean().optional()
|
|
5541
|
+
}).optional()
|
|
5542
|
+
}).describe("A date calendar for picking dates or date ranges");
|
|
5543
|
+
|
|
5544
|
+
// src/ui/FileInput/schema.ts
|
|
5545
|
+
import { z as z48 } from "zod";
|
|
5546
|
+
var fileInputSchema = z48.object({
|
|
5547
|
+
type: z48.literal("file-input"),
|
|
5548
|
+
props: z48.object({
|
|
5549
|
+
label: z48.string().optional().describe("Label text above the input"),
|
|
5550
|
+
helperText: z48.string().optional().describe("Helper text below the input"),
|
|
5551
|
+
error: z48.boolean().optional().describe("Show error styling. Defaults to false"),
|
|
5552
|
+
accept: z48.string().optional().describe("Accepted file types, e.g. 'image/*,.pdf'"),
|
|
5553
|
+
multiple: z48.boolean().optional().describe("Allow multiple files. Defaults to false"),
|
|
5554
|
+
disabled: z48.boolean().optional()
|
|
5555
|
+
}).optional()
|
|
5556
|
+
}).describe("A file input with choose-file button and upload progress");
|
|
5557
|
+
|
|
5558
|
+
// src/ui/ToolToggle/schema.ts
|
|
5559
|
+
import { z as z49 } from "zod";
|
|
5560
|
+
var toolToggleSchema = z49.object({
|
|
5561
|
+
type: z49.literal("tool-toggle"),
|
|
5562
|
+
props: z49.object({
|
|
5563
|
+
icon: z49.string().optional().describe("Icon name (resolved by the renderer)"),
|
|
5564
|
+
dropdown: z49.boolean().optional().describe("Show dropdown chevron")
|
|
5565
|
+
}).optional()
|
|
5566
|
+
}).describe("A round toggle button used in toolbars, optionally with a dropdown");
|
|
5567
|
+
|
|
5568
|
+
// src/ui/ToggleDropdownButton/schema.ts
|
|
5569
|
+
import { z as z50 } from "zod";
|
|
5570
|
+
var toggleDropdownButtonSchema = z50.object({
|
|
5571
|
+
type: z50.literal("toggle-dropdown-button"),
|
|
5572
|
+
props: z50.object({
|
|
5573
|
+
type: z50.enum(["text", "icon"]).describe("Button content type"),
|
|
5574
|
+
selected: z50.boolean().describe("Whether the button is selected"),
|
|
5575
|
+
variant: z50.enum(["primary", "secondary", "destructive"]).describe("Button color variant")
|
|
5576
|
+
})
|
|
5577
|
+
}).describe("A split toggle button with an attached dropdown trigger");
|
|
5578
|
+
|
|
5579
|
+
// src/ui/IconContainer/schema.ts
|
|
5580
|
+
import { z as z51 } from "zod";
|
|
5581
|
+
var iconContainerSchema = z51.object({
|
|
5582
|
+
type: z51.literal("icon-container"),
|
|
5583
|
+
props: z51.object({
|
|
5584
|
+
icon: z51.string().optional().describe("Icon name (resolved by the renderer)"),
|
|
5585
|
+
size: z51.enum(["xs", "sm", "md", "lg", "xl", "2xl", "3xl", "4xl", "5xl", "6xl", "auto"]).optional().describe("Icon size. Defaults to 'sm'"),
|
|
5586
|
+
colorInFill: z51.boolean().optional().describe("Apply fill colors to SVG paths. Defaults to true"),
|
|
5587
|
+
disableTheme: z51.boolean().optional().describe("Disable theme-aware coloring. Defaults to false")
|
|
5588
|
+
}).optional(),
|
|
5589
|
+
children: z51.array(uiNodeSchema).optional().describe("Icon element")
|
|
5590
|
+
}).describe("A sized container for static icons with theme-aware coloring");
|
|
5591
|
+
|
|
5592
|
+
// src/ui/IconProfile/schema.ts
|
|
5593
|
+
import { z as z52 } from "zod";
|
|
5594
|
+
var iconProfileSchema = z52.object({
|
|
5595
|
+
type: z52.literal("icon-profile"),
|
|
5596
|
+
props: z52.object({
|
|
5597
|
+
icon: z52.string().describe("Icon name (resolved by the renderer)"),
|
|
5598
|
+
color: z52.enum([
|
|
5599
|
+
"red",
|
|
5600
|
+
"orange",
|
|
5601
|
+
"amber",
|
|
5602
|
+
"yellow",
|
|
5603
|
+
"lime",
|
|
5604
|
+
"green",
|
|
5605
|
+
"emerald",
|
|
5606
|
+
"teal",
|
|
5607
|
+
"cyan",
|
|
5608
|
+
"sky",
|
|
5609
|
+
"blue",
|
|
5610
|
+
"indigo",
|
|
5611
|
+
"violet",
|
|
5612
|
+
"purple",
|
|
5613
|
+
"fuchsia",
|
|
5614
|
+
"pink",
|
|
5615
|
+
"rose",
|
|
5616
|
+
"slate"
|
|
5617
|
+
]).optional().describe("Background glow and icon color. Defaults to 'red'"),
|
|
5618
|
+
size: z52.enum(["26", "32", "40", "48", "56", "64"]).optional().describe("Size in pixels. Defaults to '64'"),
|
|
5619
|
+
externalIcon: z52.boolean().optional().describe("Whether the icon is external")
|
|
5620
|
+
})
|
|
5621
|
+
}).describe("An icon with a colored radial glow background");
|
|
5622
|
+
|
|
5623
|
+
// src/ui/ButtonWithTooltip/schema.ts
|
|
5624
|
+
import { z as z53 } from "zod";
|
|
5625
|
+
var buttonWithTooltipSchema = z53.object({
|
|
5626
|
+
type: z53.literal("button-with-tooltip"),
|
|
5627
|
+
props: z53.object({
|
|
5628
|
+
content: z53.string().describe("Tooltip text"),
|
|
5629
|
+
position: z53.enum([
|
|
5630
|
+
"top",
|
|
5631
|
+
"top-center",
|
|
5632
|
+
"top-left",
|
|
5633
|
+
"top-right",
|
|
5634
|
+
"bottom",
|
|
5635
|
+
"bottom-left",
|
|
5636
|
+
"bottom-center",
|
|
5637
|
+
"bottom-right",
|
|
5638
|
+
"left",
|
|
5639
|
+
"right"
|
|
5640
|
+
]).optional().describe("Tooltip placement"),
|
|
5641
|
+
withArrow: z53.boolean().optional().describe("Show an arrow pointer")
|
|
5642
|
+
}),
|
|
5643
|
+
children: z53.array(uiNodeSchema).optional().describe("The button element to wrap with a tooltip")
|
|
5644
|
+
}).describe("A button wrapped with a tooltip that appears on hover");
|
|
5645
|
+
|
|
5646
|
+
// src/ui/Sheet/schema.ts
|
|
5647
|
+
import { z as z54 } from "zod";
|
|
5648
|
+
var sheetSchema = z54.object({
|
|
5649
|
+
type: z54.literal("sheet"),
|
|
5650
|
+
props: z54.object({}).optional(),
|
|
5651
|
+
children: z54.array(uiNodeSchema).optional().describe("Compose with sheet-trigger and sheet-content")
|
|
5652
|
+
}).describe("A slide-out panel overlay");
|
|
5653
|
+
var sheetTriggerSchema = z54.object({
|
|
5654
|
+
type: z54.literal("sheet-trigger"),
|
|
5655
|
+
props: z54.object({}).optional(),
|
|
5656
|
+
children: z54.array(uiNodeSchema).optional().describe("The element that opens the sheet")
|
|
5657
|
+
}).describe("Trigger element that opens a sheet");
|
|
5658
|
+
var sheetContentSchema = z54.object({
|
|
5659
|
+
type: z54.literal("sheet-content"),
|
|
5660
|
+
props: z54.object({
|
|
5661
|
+
side: z54.enum(["top", "right", "bottom", "left"]).optional().describe("Slide-in direction. Defaults to 'right'"),
|
|
5662
|
+
showCloseButton: z54.boolean().optional().describe("Show close button. Defaults to true")
|
|
5663
|
+
}).optional(),
|
|
5664
|
+
children: z54.array(uiNodeSchema).optional().describe("Sheet body content")
|
|
5665
|
+
}).describe("Content panel of a sheet");
|
|
5666
|
+
var sheetHeaderSchema = z54.object({
|
|
5667
|
+
type: z54.literal("sheet-header"),
|
|
5668
|
+
props: z54.object({}).optional(),
|
|
5669
|
+
children: z54.array(uiNodeSchema).optional()
|
|
5670
|
+
}).describe("Header section of a sheet");
|
|
5671
|
+
var sheetFooterSchema = z54.object({
|
|
5672
|
+
type: z54.literal("sheet-footer"),
|
|
5673
|
+
props: z54.object({}).optional(),
|
|
5674
|
+
children: z54.array(uiNodeSchema).optional()
|
|
5675
|
+
}).describe("Footer section of a sheet");
|
|
5676
|
+
var sheetTitleSchema = z54.object({
|
|
5677
|
+
type: z54.literal("sheet-title"),
|
|
5678
|
+
props: z54.object({
|
|
5679
|
+
children: z54.string().optional().describe("Title text")
|
|
5680
|
+
}).optional(),
|
|
5681
|
+
children: z54.array(uiNodeSchema).optional()
|
|
5682
|
+
}).describe("Title inside a sheet-header");
|
|
5683
|
+
var sheetDescriptionSchema = z54.object({
|
|
5684
|
+
type: z54.literal("sheet-description"),
|
|
5685
|
+
props: z54.object({
|
|
5686
|
+
children: z54.string().optional().describe("Description text")
|
|
5687
|
+
}).optional(),
|
|
5688
|
+
children: z54.array(uiNodeSchema).optional()
|
|
5689
|
+
}).describe("Description text inside a sheet-header");
|
|
5690
|
+
|
|
5691
|
+
// src/ui/Dropdown/schema.ts
|
|
5692
|
+
import { z as z55 } from "zod";
|
|
5693
|
+
var dropdownMenuSchema = z55.object({
|
|
5694
|
+
type: z55.literal("dropdown-menu"),
|
|
5695
|
+
props: z55.object({}).optional(),
|
|
5696
|
+
children: z55.array(uiNodeSchema).optional().describe("Compose with dropdown-menu-trigger and dropdown-menu-content")
|
|
5697
|
+
}).describe("A dropdown menu container");
|
|
5698
|
+
var dropdownMenuTriggerSchema = z55.object({
|
|
5699
|
+
type: z55.literal("dropdown-menu-trigger"),
|
|
5700
|
+
props: z55.object({}).optional(),
|
|
5701
|
+
children: z55.array(uiNodeSchema).optional().describe("The element that opens the dropdown")
|
|
5702
|
+
}).describe("Trigger element that opens a dropdown menu");
|
|
5703
|
+
var dropdownMenuContentSchema = z55.object({
|
|
5704
|
+
type: z55.literal("dropdown-menu-content"),
|
|
5705
|
+
props: z55.object({
|
|
5706
|
+
side: z55.enum(["top", "right", "bottom", "left"]).optional(),
|
|
5707
|
+
align: z55.enum(["start", "center", "end"]).optional()
|
|
5708
|
+
}).optional(),
|
|
5709
|
+
children: z55.array(uiNodeSchema).optional().describe("Menu items")
|
|
5710
|
+
}).describe("Content panel of a dropdown menu");
|
|
5711
|
+
var dropdownMenuItemSchema = z55.object({
|
|
5712
|
+
type: z55.literal("dropdown-menu-item"),
|
|
5713
|
+
props: z55.object({
|
|
5714
|
+
children: z55.string().optional().describe("Menu item text"),
|
|
5715
|
+
variant: z55.enum(["default", "destructive"]).optional().describe("Item style. Defaults to 'default'"),
|
|
5716
|
+
disabled: z55.boolean().optional()
|
|
5717
|
+
}).optional(),
|
|
5718
|
+
children: z55.array(uiNodeSchema).optional()
|
|
5719
|
+
}).describe("A single item inside a dropdown menu");
|
|
5720
|
+
var dropdownMenuSeparatorSchema = z55.object({
|
|
5721
|
+
type: z55.literal("dropdown-menu-separator"),
|
|
5722
|
+
props: z55.object({}).optional()
|
|
5723
|
+
}).describe("A visual separator between dropdown menu items");
|
|
5724
|
+
var dropdownMenuLabelSchema = z55.object({
|
|
5725
|
+
type: z55.literal("dropdown-menu-label"),
|
|
5726
|
+
props: z55.object({
|
|
5727
|
+
children: z55.string().optional().describe("Label text")
|
|
5728
|
+
}).optional(),
|
|
5729
|
+
children: z55.array(uiNodeSchema).optional()
|
|
5730
|
+
}).describe("A non-interactive label inside a dropdown menu");
|
|
5731
|
+
|
|
5732
|
+
// src/ui/Popover/schema.ts
|
|
5733
|
+
import { z as z56 } from "zod";
|
|
5734
|
+
var popoverSchema = z56.object({
|
|
5735
|
+
type: z56.literal("popover"),
|
|
5736
|
+
props: z56.object({}).optional(),
|
|
5737
|
+
children: z56.array(uiNodeSchema).optional().describe("Compose with popover-trigger and popover-content")
|
|
5738
|
+
}).describe("A popover overlay container");
|
|
5739
|
+
var popoverTriggerSchema = z56.object({
|
|
5740
|
+
type: z56.literal("popover-trigger"),
|
|
5741
|
+
props: z56.object({}).optional(),
|
|
5742
|
+
children: z56.array(uiNodeSchema).optional().describe("The element that opens the popover")
|
|
5743
|
+
}).describe("Trigger element that opens a popover");
|
|
5744
|
+
var popoverContentSchema = z56.object({
|
|
5745
|
+
type: z56.literal("popover-content"),
|
|
5746
|
+
props: z56.object({
|
|
5747
|
+
align: z56.enum(["start", "center", "end"]).optional().describe("Alignment relative to trigger. Defaults to 'center'"),
|
|
5748
|
+
sideOffset: z56.number().optional().describe("Offset from trigger in px. Defaults to 4")
|
|
5749
|
+
}).optional(),
|
|
5750
|
+
children: z56.array(uiNodeSchema).optional().describe("Popover body content")
|
|
5751
|
+
}).describe("Content panel of a popover");
|
|
5752
|
+
|
|
5753
|
+
// src/ui/ContextMenu/schema.ts
|
|
5754
|
+
import { z as z57 } from "zod";
|
|
5755
|
+
var contextMenuSchema = z57.object({
|
|
5756
|
+
type: z57.literal("context-menu"),
|
|
5757
|
+
props: z57.object({}).optional(),
|
|
5758
|
+
children: z57.array(uiNodeSchema).optional().describe("Compose with context-menu-trigger and context-menu-content")
|
|
5759
|
+
}).describe("A right-click context menu container");
|
|
5760
|
+
var contextMenuTriggerSchema = z57.object({
|
|
5761
|
+
type: z57.literal("context-menu-trigger"),
|
|
5762
|
+
props: z57.object({}).optional(),
|
|
5763
|
+
children: z57.array(uiNodeSchema).optional().describe("The element that triggers the context menu on right-click")
|
|
5764
|
+
}).describe("Trigger area for a context menu");
|
|
5765
|
+
var contextMenuContentSchema = z57.object({
|
|
5766
|
+
type: z57.literal("context-menu-content"),
|
|
5767
|
+
props: z57.object({}).optional(),
|
|
5768
|
+
children: z57.array(uiNodeSchema).optional().describe("Menu items")
|
|
5769
|
+
}).describe("Content panel of a context menu");
|
|
5770
|
+
var contextMenuItemSchema = z57.object({
|
|
5771
|
+
type: z57.literal("context-menu-item"),
|
|
5772
|
+
props: z57.object({
|
|
5773
|
+
children: z57.string().optional().describe("Menu item text"),
|
|
5774
|
+
variant: z57.enum(["default", "destructive"]).optional().describe("Item style. Defaults to 'default'"),
|
|
5775
|
+
disabled: z57.boolean().optional()
|
|
5776
|
+
}).optional(),
|
|
5777
|
+
children: z57.array(uiNodeSchema).optional()
|
|
5778
|
+
}).describe("A single item inside a context menu");
|
|
5779
|
+
var contextMenuSeparatorSchema = z57.object({
|
|
5780
|
+
type: z57.literal("context-menu-separator"),
|
|
5781
|
+
props: z57.object({}).optional()
|
|
5782
|
+
}).describe("A visual separator between context menu items");
|
|
5783
|
+
|
|
4164
5784
|
// src/schema.ts
|
|
4165
5785
|
var componentSchema = component_schema_default;
|
|
4166
5786
|
function getComponentSchemas() {
|
|
@@ -7794,11 +9414,104 @@ function LinkButton({
|
|
|
7794
9414
|
);
|
|
7795
9415
|
}
|
|
7796
9416
|
|
|
9417
|
+
// src/ui/Map/index.tsx
|
|
9418
|
+
import {
|
|
9419
|
+
APIProvider,
|
|
9420
|
+
Map as GoogleMap,
|
|
9421
|
+
AdvancedMarker,
|
|
9422
|
+
InfoWindow,
|
|
9423
|
+
Pin
|
|
9424
|
+
} from "@vis.gl/react-google-maps";
|
|
9425
|
+
import { useState as useState6, useCallback as useCallback3 } from "react";
|
|
9426
|
+
import { jsx as jsx34, jsxs as jsxs25 } from "react/jsx-runtime";
|
|
9427
|
+
function MarkerWithInfo({
|
|
9428
|
+
marker,
|
|
9429
|
+
index,
|
|
9430
|
+
onMarkerClick
|
|
9431
|
+
}) {
|
|
9432
|
+
const [open, setOpen] = useState6(false);
|
|
9433
|
+
const handleClick = useCallback3(() => {
|
|
9434
|
+
setOpen((prev) => !prev);
|
|
9435
|
+
onMarkerClick?.(marker, index);
|
|
9436
|
+
}, [marker, index, onMarkerClick]);
|
|
9437
|
+
return /* @__PURE__ */ jsxs25(
|
|
9438
|
+
AdvancedMarker,
|
|
9439
|
+
{
|
|
9440
|
+
position: { lat: marker.lat, lng: marker.lng },
|
|
9441
|
+
title: marker.title,
|
|
9442
|
+
onClick: handleClick,
|
|
9443
|
+
children: [
|
|
9444
|
+
marker.color && /* @__PURE__ */ jsx34(
|
|
9445
|
+
Pin,
|
|
9446
|
+
{
|
|
9447
|
+
background: marker.color,
|
|
9448
|
+
borderColor: marker.color,
|
|
9449
|
+
glyphColor: "#fff"
|
|
9450
|
+
}
|
|
9451
|
+
),
|
|
9452
|
+
open && (marker.title || marker.description) && /* @__PURE__ */ jsx34(
|
|
9453
|
+
InfoWindow,
|
|
9454
|
+
{
|
|
9455
|
+
position: { lat: marker.lat, lng: marker.lng },
|
|
9456
|
+
onCloseClick: () => setOpen(false),
|
|
9457
|
+
children: /* @__PURE__ */ jsxs25("div", { className: "max-w-xs", children: [
|
|
9458
|
+
marker.title && /* @__PURE__ */ jsx34("h3", { className: "text-body-sm font-semibold", children: marker.title }),
|
|
9459
|
+
marker.description && /* @__PURE__ */ jsx34("p", { className: "text-body-sm text-element-inverse-gray mt-1", children: marker.description })
|
|
9460
|
+
] })
|
|
9461
|
+
}
|
|
9462
|
+
)
|
|
9463
|
+
]
|
|
9464
|
+
}
|
|
9465
|
+
);
|
|
9466
|
+
}
|
|
9467
|
+
var DEFAULT_CENTER = { lat: 16.8661, lng: 96.1951 };
|
|
9468
|
+
function GoogleMapView({
|
|
9469
|
+
apiKey,
|
|
9470
|
+
center = DEFAULT_CENTER,
|
|
9471
|
+
zoom = 12,
|
|
9472
|
+
markers = [],
|
|
9473
|
+
mapId,
|
|
9474
|
+
height = "400px",
|
|
9475
|
+
width = "100%",
|
|
9476
|
+
className,
|
|
9477
|
+
gestureHandling = "cooperative",
|
|
9478
|
+
disableDefaultUI = false,
|
|
9479
|
+
onMarkerClick
|
|
9480
|
+
}) {
|
|
9481
|
+
return /* @__PURE__ */ jsx34(APIProvider, { apiKey, children: /* @__PURE__ */ jsx34(
|
|
9482
|
+
"div",
|
|
9483
|
+
{
|
|
9484
|
+
className: cn("overflow-hidden rounded-unit-corner-radius-xl", className),
|
|
9485
|
+
style: { height, width },
|
|
9486
|
+
children: /* @__PURE__ */ jsx34(
|
|
9487
|
+
GoogleMap,
|
|
9488
|
+
{
|
|
9489
|
+
defaultCenter: center,
|
|
9490
|
+
defaultZoom: zoom,
|
|
9491
|
+
mapId,
|
|
9492
|
+
gestureHandling,
|
|
9493
|
+
disableDefaultUI,
|
|
9494
|
+
style: { width: "100%", height: "100%" },
|
|
9495
|
+
children: markers.map((marker, i) => /* @__PURE__ */ jsx34(
|
|
9496
|
+
MarkerWithInfo,
|
|
9497
|
+
{
|
|
9498
|
+
marker,
|
|
9499
|
+
index: i,
|
|
9500
|
+
onMarkerClick
|
|
9501
|
+
},
|
|
9502
|
+
`${marker.lat}-${marker.lng}-${i}`
|
|
9503
|
+
))
|
|
9504
|
+
}
|
|
9505
|
+
)
|
|
9506
|
+
}
|
|
9507
|
+
) });
|
|
9508
|
+
}
|
|
9509
|
+
|
|
7797
9510
|
// src/ui/Media/index.tsx
|
|
7798
9511
|
import { cva as cva10 } from "class-variance-authority";
|
|
7799
9512
|
import { Pause, Play } from "lucide-react";
|
|
7800
9513
|
import * as React10 from "react";
|
|
7801
|
-
import { Fragment as Fragment5, jsx as
|
|
9514
|
+
import { Fragment as Fragment5, jsx as jsx35, jsxs as jsxs26 } from "react/jsx-runtime";
|
|
7802
9515
|
var mediaVariants = cva10(
|
|
7803
9516
|
"relative overflow-hidden bg-gray-100 dark:bg-gray-800",
|
|
7804
9517
|
{
|
|
@@ -7896,7 +9609,7 @@ var Media = React10.forwardRef(
|
|
|
7896
9609
|
const handleImageError = () => {
|
|
7897
9610
|
setImageError(true);
|
|
7898
9611
|
};
|
|
7899
|
-
return /* @__PURE__ */
|
|
9612
|
+
return /* @__PURE__ */ jsx35(
|
|
7900
9613
|
"div",
|
|
7901
9614
|
{
|
|
7902
9615
|
ref,
|
|
@@ -7904,8 +9617,8 @@ var Media = React10.forwardRef(
|
|
|
7904
9617
|
onMouseEnter: () => setIsHovered(true),
|
|
7905
9618
|
onMouseLeave: () => setIsHovered(false),
|
|
7906
9619
|
...props,
|
|
7907
|
-
children: type === "image" ? /* @__PURE__ */
|
|
7908
|
-
/* @__PURE__ */
|
|
9620
|
+
children: type === "image" ? /* @__PURE__ */ jsxs26(Fragment5, { children: [
|
|
9621
|
+
/* @__PURE__ */ jsx35(
|
|
7909
9622
|
"img",
|
|
7910
9623
|
{
|
|
7911
9624
|
src,
|
|
@@ -7923,13 +9636,13 @@ var Media = React10.forwardRef(
|
|
|
7923
9636
|
style: { objectFit }
|
|
7924
9637
|
}
|
|
7925
9638
|
),
|
|
7926
|
-
!imageLoaded && !imageError && /* @__PURE__ */
|
|
7927
|
-
imageError && /* @__PURE__ */
|
|
7928
|
-
/* @__PURE__ */
|
|
7929
|
-
/* @__PURE__ */
|
|
9639
|
+
!imageLoaded && !imageError && /* @__PURE__ */ jsx35("div", { className: "absolute inset-0 flex items-center justify-center bg-gray-200 dark:bg-gray-700", children: /* @__PURE__ */ jsx35("div", { className: "h-8 w-8 animate-spin rounded-full border-2 border-gray-300 border-t-gray-600" }) }),
|
|
9640
|
+
imageError && /* @__PURE__ */ jsx35("div", { className: "absolute inset-0 flex items-center justify-center bg-gray-200 dark:bg-gray-700", children: /* @__PURE__ */ jsxs26("div", { className: "text-center text-gray-500", children: [
|
|
9641
|
+
/* @__PURE__ */ jsx35("div", { className: "text-2xl", children: "\u{1F4F7}" }),
|
|
9642
|
+
/* @__PURE__ */ jsx35("div", { className: "text-sm", children: "Failed to load" })
|
|
7930
9643
|
] }) })
|
|
7931
|
-
] }) : /* @__PURE__ */
|
|
7932
|
-
/* @__PURE__ */
|
|
9644
|
+
] }) : /* @__PURE__ */ jsxs26(Fragment5, { children: [
|
|
9645
|
+
/* @__PURE__ */ jsx35(
|
|
7933
9646
|
"video",
|
|
7934
9647
|
{
|
|
7935
9648
|
ref: videoRef,
|
|
@@ -7942,7 +9655,7 @@ var Media = React10.forwardRef(
|
|
|
7942
9655
|
preload: "metadata"
|
|
7943
9656
|
}
|
|
7944
9657
|
),
|
|
7945
|
-
showPlayButton && /* @__PURE__ */
|
|
9658
|
+
showPlayButton && /* @__PURE__ */ jsx35(
|
|
7946
9659
|
"div",
|
|
7947
9660
|
{
|
|
7948
9661
|
className: cn(
|
|
@@ -7952,10 +9665,10 @@ var Media = React10.forwardRef(
|
|
|
7952
9665
|
"opacity-0": !isHovered && !videoPlaying
|
|
7953
9666
|
}
|
|
7954
9667
|
),
|
|
7955
|
-
children: /* @__PURE__ */
|
|
9668
|
+
children: /* @__PURE__ */ jsx35(
|
|
7956
9669
|
IconButton,
|
|
7957
9670
|
{
|
|
7958
|
-
icon: videoPlaying ? /* @__PURE__ */
|
|
9671
|
+
icon: videoPlaying ? /* @__PURE__ */ jsx35(Pause, { className: "text-gray-900" }) : /* @__PURE__ */ jsx35(Play, { className: "ml-1 text-gray-900" }),
|
|
7959
9672
|
onClick: videoPlaying ? handlePause : handlePlay,
|
|
7960
9673
|
varient: "outline",
|
|
7961
9674
|
size: "md",
|
|
@@ -7976,7 +9689,7 @@ Media.displayName = "Media";
|
|
|
7976
9689
|
// src/ui/MultiSelect/index.tsx
|
|
7977
9690
|
import { ChevronDown as ChevronDown2, CircleXIcon, X as X3 } from "lucide-react";
|
|
7978
9691
|
import * as React11 from "react";
|
|
7979
|
-
import { jsx as
|
|
9692
|
+
import { jsx as jsx36, jsxs as jsxs27 } from "react/jsx-runtime";
|
|
7980
9693
|
function MultiSelect({
|
|
7981
9694
|
options,
|
|
7982
9695
|
selected,
|
|
@@ -8049,8 +9762,8 @@ function MultiSelect({
|
|
|
8049
9762
|
e.preventDefault();
|
|
8050
9763
|
inputRef.current?.focus();
|
|
8051
9764
|
};
|
|
8052
|
-
return /* @__PURE__ */
|
|
8053
|
-
/* @__PURE__ */
|
|
9765
|
+
return /* @__PURE__ */ jsxs27(Popover, { open, onOpenChange: setOpen, children: [
|
|
9766
|
+
/* @__PURE__ */ jsx36(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsxs27(
|
|
8054
9767
|
"div",
|
|
8055
9768
|
{
|
|
8056
9769
|
ref: containerRef,
|
|
@@ -8062,10 +9775,10 @@ function MultiSelect({
|
|
|
8062
9775
|
),
|
|
8063
9776
|
onClick: handleContainerClick,
|
|
8064
9777
|
children: [
|
|
8065
|
-
/* @__PURE__ */
|
|
9778
|
+
/* @__PURE__ */ jsxs27("div", { className: "flex flex-1 flex-wrap items-center gap-1", children: [
|
|
8066
9779
|
selected.map((value) => {
|
|
8067
9780
|
const option = options.find((opt) => opt.value === value);
|
|
8068
|
-
return /* @__PURE__ */
|
|
9781
|
+
return /* @__PURE__ */ jsx36(
|
|
8069
9782
|
Chip,
|
|
8070
9783
|
{
|
|
8071
9784
|
label: option?.label || value,
|
|
@@ -8076,12 +9789,12 @@ function MultiSelect({
|
|
|
8076
9789
|
className: cn(
|
|
8077
9790
|
disabled && "pointer-events-none cursor-not-allowed"
|
|
8078
9791
|
),
|
|
8079
|
-
children: /* @__PURE__ */
|
|
9792
|
+
children: /* @__PURE__ */ jsx36(X3, { className: "hover:text-destructive ml-1.5 h-3 w-3 cursor-pointer" })
|
|
8080
9793
|
},
|
|
8081
9794
|
value
|
|
8082
9795
|
);
|
|
8083
9796
|
}),
|
|
8084
|
-
/* @__PURE__ */
|
|
9797
|
+
/* @__PURE__ */ jsx36(
|
|
8085
9798
|
"input",
|
|
8086
9799
|
{
|
|
8087
9800
|
ref: inputRef,
|
|
@@ -8095,25 +9808,25 @@ function MultiSelect({
|
|
|
8095
9808
|
}
|
|
8096
9809
|
)
|
|
8097
9810
|
] }),
|
|
8098
|
-
selected.length > 0 && /* @__PURE__ */
|
|
9811
|
+
selected.length > 0 && /* @__PURE__ */ jsx36(
|
|
8099
9812
|
CircleXIcon,
|
|
8100
9813
|
{
|
|
8101
9814
|
className: "text-icon-default size-4.5 shrink-0",
|
|
8102
9815
|
onClick: () => onChange([])
|
|
8103
9816
|
}
|
|
8104
9817
|
),
|
|
8105
|
-
!createConfig?.enabled && /* @__PURE__ */
|
|
9818
|
+
!createConfig?.enabled && /* @__PURE__ */ jsx36(ChevronDown2, { className: "text-icon-default size-4.5 shrink-0" })
|
|
8106
9819
|
]
|
|
8107
9820
|
}
|
|
8108
9821
|
) }),
|
|
8109
|
-
/* @__PURE__ */
|
|
9822
|
+
/* @__PURE__ */ jsx36(
|
|
8110
9823
|
PopoverContent,
|
|
8111
9824
|
{
|
|
8112
9825
|
className: "shadow-box w-[var(--radix-popover-trigger-width)] border-none bg-white p-2",
|
|
8113
9826
|
align: "start",
|
|
8114
|
-
children: /* @__PURE__ */
|
|
8115
|
-
createConfig?.enabled && /* @__PURE__ */
|
|
8116
|
-
filteredOptions.map((option) => /* @__PURE__ */
|
|
9827
|
+
children: /* @__PURE__ */ jsx36("div", { className: "p-0", children: /* @__PURE__ */ jsx36("div", { className: "max-h-[300px] overflow-y-auto", children: filteredOptions.length === 0 && !canCreate ? /* @__PURE__ */ jsx36("div", { className: "py-6 text-center text-gray-500", children: inputValue ? "No results found." : "Start typing to search..." }) : /* @__PURE__ */ jsxs27("div", { className: "flex flex-col gap-1.5 px-1.5 pt-1.5 pb-0.5", children: [
|
|
9828
|
+
createConfig?.enabled && /* @__PURE__ */ jsx36("p", { className: "text-text-default pb-0.5 font-semibold", children: "Select or create one" }),
|
|
9829
|
+
filteredOptions.map((option) => /* @__PURE__ */ jsx36(
|
|
8117
9830
|
Chip,
|
|
8118
9831
|
{
|
|
8119
9832
|
label: option.label,
|
|
@@ -8122,14 +9835,14 @@ function MultiSelect({
|
|
|
8122
9835
|
},
|
|
8123
9836
|
option.value
|
|
8124
9837
|
)),
|
|
8125
|
-
canCreate && /* @__PURE__ */
|
|
9838
|
+
canCreate && /* @__PURE__ */ jsxs27(
|
|
8126
9839
|
"div",
|
|
8127
9840
|
{
|
|
8128
9841
|
onClick: async () => await handleCreate(),
|
|
8129
9842
|
className: "flex items-center justify-between",
|
|
8130
9843
|
children: [
|
|
8131
|
-
/* @__PURE__ */
|
|
8132
|
-
/* @__PURE__ */
|
|
9844
|
+
/* @__PURE__ */ jsx36(Chip, { label: inputValue.trim(), className: "rounded-md" }),
|
|
9845
|
+
/* @__PURE__ */ jsx36(
|
|
8133
9846
|
Button,
|
|
8134
9847
|
{
|
|
8135
9848
|
variant: "ghost",
|
|
@@ -8153,7 +9866,7 @@ import {
|
|
|
8153
9866
|
OTPInputContext as BaseOTPInputContext
|
|
8154
9867
|
} from "input-otp";
|
|
8155
9868
|
import * as React12 from "react";
|
|
8156
|
-
import { jsx as
|
|
9869
|
+
import { jsx as jsx37, jsxs as jsxs28 } from "react/jsx-runtime";
|
|
8157
9870
|
function OTPInput({
|
|
8158
9871
|
type = 4,
|
|
8159
9872
|
separate = false,
|
|
@@ -8161,8 +9874,8 @@ function OTPInput({
|
|
|
8161
9874
|
className,
|
|
8162
9875
|
...props
|
|
8163
9876
|
}) {
|
|
8164
|
-
return /* @__PURE__ */
|
|
8165
|
-
/* @__PURE__ */
|
|
9877
|
+
return /* @__PURE__ */ jsx37("div", { className: cn(className), children: /* @__PURE__ */ jsxs28(InputOTP, { disabled, className: "w-full", ...props, children: [
|
|
9878
|
+
/* @__PURE__ */ jsx37(InputOTPGroup, { className: "w-full", children: [...new Array(type / 2)].map((_, index) => /* @__PURE__ */ jsx37(
|
|
8166
9879
|
InputOTPSlot,
|
|
8167
9880
|
{
|
|
8168
9881
|
className: "w-full",
|
|
@@ -8171,8 +9884,8 @@ function OTPInput({
|
|
|
8171
9884
|
},
|
|
8172
9885
|
index
|
|
8173
9886
|
)) }),
|
|
8174
|
-
separate && /* @__PURE__ */
|
|
8175
|
-
/* @__PURE__ */
|
|
9887
|
+
separate && /* @__PURE__ */ jsx37(InputOTPSeparator, {}),
|
|
9888
|
+
/* @__PURE__ */ jsx37(InputOTPGroup, { className: "w-full", children: [...new Array(type / 2)].map((_, index) => /* @__PURE__ */ jsx37(
|
|
8176
9889
|
InputOTPSlot,
|
|
8177
9890
|
{
|
|
8178
9891
|
className: "w-full",
|
|
@@ -8188,7 +9901,7 @@ function InputOTP({
|
|
|
8188
9901
|
containerClassName,
|
|
8189
9902
|
...props
|
|
8190
9903
|
}) {
|
|
8191
|
-
return /* @__PURE__ */
|
|
9904
|
+
return /* @__PURE__ */ jsx37(
|
|
8192
9905
|
BaseOTPInput,
|
|
8193
9906
|
{
|
|
8194
9907
|
"data-slot": "input-otp",
|
|
@@ -8199,7 +9912,7 @@ function InputOTP({
|
|
|
8199
9912
|
);
|
|
8200
9913
|
}
|
|
8201
9914
|
function InputOTPGroup({ className, ...props }) {
|
|
8202
|
-
return /* @__PURE__ */
|
|
9915
|
+
return /* @__PURE__ */ jsx37(
|
|
8203
9916
|
"div",
|
|
8204
9917
|
{
|
|
8205
9918
|
"data-slot": "input-otp-group",
|
|
@@ -8217,7 +9930,7 @@ function InputOTPSlot({
|
|
|
8217
9930
|
}) {
|
|
8218
9931
|
const inputOTPContext = React12.useContext(BaseOTPInputContext);
|
|
8219
9932
|
const { char, hasFakeCaret, isActive } = inputOTPContext?.slots[index] ?? {};
|
|
8220
|
-
return /* @__PURE__ */
|
|
9933
|
+
return /* @__PURE__ */ jsxs28(
|
|
8221
9934
|
"div",
|
|
8222
9935
|
{
|
|
8223
9936
|
"data-slot": "input-otp-slot",
|
|
@@ -8232,26 +9945,26 @@ function InputOTPSlot({
|
|
|
8232
9945
|
),
|
|
8233
9946
|
...props,
|
|
8234
9947
|
children: [
|
|
8235
|
-
/* @__PURE__ */
|
|
8236
|
-
hasFakeCaret && /* @__PURE__ */
|
|
9948
|
+
/* @__PURE__ */ jsx37("span", { className: "text-h6", children: char || placeholder }),
|
|
9949
|
+
hasFakeCaret && /* @__PURE__ */ jsx37("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ jsx37("div", { className: "animate-caret-blink bg-foreground h-4 w-px duration-1000" }) })
|
|
8237
9950
|
]
|
|
8238
9951
|
}
|
|
8239
9952
|
);
|
|
8240
9953
|
}
|
|
8241
9954
|
function InputOTPSeparator({ ...props }) {
|
|
8242
|
-
return /* @__PURE__ */
|
|
9955
|
+
return /* @__PURE__ */ jsx37("div", { "data-slot": "input-otp-separator", role: "separator", ...props, children: /* @__PURE__ */ jsx37("div", { className: "bg-border-primary-normal h-0.5 w-2" }) });
|
|
8243
9956
|
}
|
|
8244
9957
|
|
|
8245
9958
|
// src/ui/PasswordInput/index.tsx
|
|
8246
9959
|
import * as React13 from "react";
|
|
8247
9960
|
import { Eye, EyeOff } from "lucide-react";
|
|
8248
|
-
import { jsx as
|
|
9961
|
+
import { jsx as jsx38, jsxs as jsxs29 } from "react/jsx-runtime";
|
|
8249
9962
|
var PasswordInput = React13.memo(
|
|
8250
9963
|
({ type, label, className, ...props }) => {
|
|
8251
9964
|
const [showPassword, setShowPassword] = React13.useState(false);
|
|
8252
9965
|
const error = props["aria-invalid"] || false;
|
|
8253
9966
|
const inputRef = React13.useRef(null);
|
|
8254
|
-
return /* @__PURE__ */
|
|
9967
|
+
return /* @__PURE__ */ jsxs29(
|
|
8255
9968
|
"div",
|
|
8256
9969
|
{
|
|
8257
9970
|
className: cn(
|
|
@@ -8271,7 +9984,7 @@ var PasswordInput = React13.memo(
|
|
|
8271
9984
|
}
|
|
8272
9985
|
),
|
|
8273
9986
|
children: [
|
|
8274
|
-
/* @__PURE__ */
|
|
9987
|
+
/* @__PURE__ */ jsx38(
|
|
8275
9988
|
"input",
|
|
8276
9989
|
{
|
|
8277
9990
|
ref: inputRef,
|
|
@@ -8295,7 +10008,7 @@ var PasswordInput = React13.memo(
|
|
|
8295
10008
|
}
|
|
8296
10009
|
}
|
|
8297
10010
|
),
|
|
8298
|
-
/* @__PURE__ */
|
|
10011
|
+
/* @__PURE__ */ jsx38(
|
|
8299
10012
|
"button",
|
|
8300
10013
|
{
|
|
8301
10014
|
tabIndex: -1,
|
|
@@ -8304,7 +10017,7 @@ var PasswordInput = React13.memo(
|
|
|
8304
10017
|
onClick: () => setShowPassword(!showPassword),
|
|
8305
10018
|
"aria-label": showPassword ? "Hide password" : "Show password",
|
|
8306
10019
|
className: "hover:bg-primary-bg-soft absolute right-2 flex h-5 w-5 cursor-pointer items-center justify-center rounded-sm bg-white",
|
|
8307
|
-
children: showPassword ? /* @__PURE__ */
|
|
10020
|
+
children: showPassword ? /* @__PURE__ */ jsx38(Eye, { size: 16, className: "text-element-inverse-default-alt" }) : /* @__PURE__ */ jsx38(EyeOff, { size: 16, className: "text-element-inverse-default-alt" })
|
|
8308
10021
|
}
|
|
8309
10022
|
)
|
|
8310
10023
|
]
|
|
@@ -8316,16 +10029,16 @@ var PasswordInput = React13.memo(
|
|
|
8316
10029
|
// src/ui/Radio/index.tsx
|
|
8317
10030
|
import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
|
|
8318
10031
|
import { CircleIcon as CircleIcon2 } from "lucide-react";
|
|
8319
|
-
import { jsx as
|
|
10032
|
+
import { jsx as jsx39, jsxs as jsxs30 } from "react/jsx-runtime";
|
|
8320
10033
|
function Radio({ onSelect, options, ...props }) {
|
|
8321
|
-
return /* @__PURE__ */
|
|
8322
|
-
return /* @__PURE__ */
|
|
10034
|
+
return /* @__PURE__ */ jsx39(BaseRadioGroup, { ...props, children: options.map((option) => {
|
|
10035
|
+
return /* @__PURE__ */ jsxs30(
|
|
8323
10036
|
Label2,
|
|
8324
10037
|
{
|
|
8325
10038
|
htmlFor: option.value,
|
|
8326
10039
|
className: "hover:bg-surface-bg flex cursor-pointer items-center gap-x-2 rounded-lg p-1.5",
|
|
8327
10040
|
children: [
|
|
8328
|
-
/* @__PURE__ */
|
|
10041
|
+
/* @__PURE__ */ jsx39(
|
|
8329
10042
|
BaseRadioGroupItem,
|
|
8330
10043
|
{
|
|
8331
10044
|
onClick: () => {
|
|
@@ -8346,7 +10059,7 @@ function BaseRadioGroup({
|
|
|
8346
10059
|
className,
|
|
8347
10060
|
...props
|
|
8348
10061
|
}) {
|
|
8349
|
-
return /* @__PURE__ */
|
|
10062
|
+
return /* @__PURE__ */ jsx39(
|
|
8350
10063
|
RadioGroupPrimitive.Root,
|
|
8351
10064
|
{
|
|
8352
10065
|
"data-slot": "radio-group",
|
|
@@ -8359,7 +10072,7 @@ function BaseRadioGroupItem({
|
|
|
8359
10072
|
className,
|
|
8360
10073
|
...props
|
|
8361
10074
|
}) {
|
|
8362
|
-
return /* @__PURE__ */
|
|
10075
|
+
return /* @__PURE__ */ jsx39(
|
|
8363
10076
|
RadioGroupPrimitive.Item,
|
|
8364
10077
|
{
|
|
8365
10078
|
"data-slot": "radio-group-item",
|
|
@@ -8368,12 +10081,12 @@ function BaseRadioGroupItem({
|
|
|
8368
10081
|
className
|
|
8369
10082
|
),
|
|
8370
10083
|
...props,
|
|
8371
|
-
children: /* @__PURE__ */
|
|
10084
|
+
children: /* @__PURE__ */ jsx39(
|
|
8372
10085
|
RadioGroupPrimitive.Indicator,
|
|
8373
10086
|
{
|
|
8374
10087
|
"data-slot": "radio-group-indicator",
|
|
8375
10088
|
className: "relative flex items-center justify-center",
|
|
8376
|
-
children: /* @__PURE__ */
|
|
10089
|
+
children: /* @__PURE__ */ jsx39(CircleIcon2, { className: "fill-check-box-and-radio-checked-enabled group-data-[state=checked]:hover:fill-check-box-and-radio-checked-hovered absolute top-1/2 left-1/2 size-[16px] -translate-x-1/2 -translate-y-1/2 stroke-none" })
|
|
8377
10090
|
}
|
|
8378
10091
|
)
|
|
8379
10092
|
}
|
|
@@ -8384,8 +10097,8 @@ function BaseRadioGroupItem({
|
|
|
8384
10097
|
import { debounce } from "lodash";
|
|
8385
10098
|
import { SearchIcon as SearchIcon2 } from "lucide-react";
|
|
8386
10099
|
import { useQueryState } from "nuqs";
|
|
8387
|
-
import { useCallback as
|
|
8388
|
-
import { jsx as
|
|
10100
|
+
import { useCallback as useCallback4, useEffect as useEffect6, useState as useState10 } from "react";
|
|
10101
|
+
import { jsx as jsx40 } from "react/jsx-runtime";
|
|
8389
10102
|
function SearchInput({
|
|
8390
10103
|
searchKey,
|
|
8391
10104
|
placeholder = "Search by...",
|
|
@@ -8397,8 +10110,8 @@ function SearchInput({
|
|
|
8397
10110
|
const [search, setSearch] = useQueryState(searchKey, {
|
|
8398
10111
|
defaultValue: ""
|
|
8399
10112
|
});
|
|
8400
|
-
const [inputValue, setInputValue] =
|
|
8401
|
-
const debouncedSetValue =
|
|
10113
|
+
const [inputValue, setInputValue] = useState10(search ?? "");
|
|
10114
|
+
const debouncedSetValue = useCallback4(
|
|
8402
10115
|
debounce((value) => {
|
|
8403
10116
|
if (addToParam) {
|
|
8404
10117
|
setSearch(value);
|
|
@@ -8414,7 +10127,7 @@ function SearchInput({
|
|
|
8414
10127
|
debouncedSetValue.cancel();
|
|
8415
10128
|
};
|
|
8416
10129
|
}, [inputValue, debouncedSetValue]);
|
|
8417
|
-
return /* @__PURE__ */
|
|
10130
|
+
return /* @__PURE__ */ jsx40("div", { className: cn("relative", className), children: /* @__PURE__ */ jsx40(
|
|
8418
10131
|
Input,
|
|
8419
10132
|
{
|
|
8420
10133
|
onChange: (e) => {
|
|
@@ -8423,7 +10136,7 @@ function SearchInput({
|
|
|
8423
10136
|
},
|
|
8424
10137
|
placeholder,
|
|
8425
10138
|
prefixNode: {
|
|
8426
|
-
node: /* @__PURE__ */
|
|
10139
|
+
node: /* @__PURE__ */ jsx40(SearchIcon2, { className: "text-element-inverse-default" }),
|
|
8427
10140
|
withBorder: false
|
|
8428
10141
|
},
|
|
8429
10142
|
value: inputValue,
|
|
@@ -8436,7 +10149,7 @@ function SearchInput({
|
|
|
8436
10149
|
// src/ui/SelectHover/index.tsx
|
|
8437
10150
|
import { Check as Check2 } from "lucide-react";
|
|
8438
10151
|
import * as React14 from "react";
|
|
8439
|
-
import { jsx as
|
|
10152
|
+
import { jsx as jsx41, jsxs as jsxs31 } from "react/jsx-runtime";
|
|
8440
10153
|
function SelectHover({
|
|
8441
10154
|
options,
|
|
8442
10155
|
placeholder = "Select an option",
|
|
@@ -8463,15 +10176,15 @@ function SelectHover({
|
|
|
8463
10176
|
setIsOpen(false);
|
|
8464
10177
|
}, 300);
|
|
8465
10178
|
};
|
|
8466
|
-
return /* @__PURE__ */
|
|
8467
|
-
/* @__PURE__ */
|
|
8468
|
-
/* @__PURE__ */
|
|
10179
|
+
return /* @__PURE__ */ jsx41(Popover, { open: isOpen, onOpenChange: setIsOpen, children: /* @__PURE__ */ jsxs31("div", { onMouseEnter: handleMouseEnter, onMouseLeave: handleMouseLeave, children: [
|
|
10180
|
+
/* @__PURE__ */ jsx41(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx41(Button, { role: "combobox", "aria-expanded": isOpen, className, children: /* @__PURE__ */ jsx41("span", { className: "truncate", children: selectedOption ? selectedOption.label : placeholder }) }) }),
|
|
10181
|
+
/* @__PURE__ */ jsx41(
|
|
8469
10182
|
PopoverContent,
|
|
8470
10183
|
{
|
|
8471
10184
|
className: "bg-surface-bg-container w-full rounded-3xl border-none p-2 shadow-md",
|
|
8472
10185
|
onMouseEnter: handleMouseEnter,
|
|
8473
10186
|
onMouseLeave: handleMouseLeave,
|
|
8474
|
-
children: /* @__PURE__ */
|
|
10187
|
+
children: /* @__PURE__ */ jsx41("div", { className: "flex max-h-[300px] flex-col items-start gap-[2px] overflow-auto", children: options.map((option) => /* @__PURE__ */ jsxs31(
|
|
8475
10188
|
"button",
|
|
8476
10189
|
{
|
|
8477
10190
|
className: cn(
|
|
@@ -8480,8 +10193,8 @@ function SelectHover({
|
|
|
8480
10193
|
),
|
|
8481
10194
|
onClick: () => handleSelect(option.value),
|
|
8482
10195
|
children: [
|
|
8483
|
-
/* @__PURE__ */
|
|
8484
|
-
value === option.value && /* @__PURE__ */
|
|
10196
|
+
/* @__PURE__ */ jsx41("span", { className: "flex-1", children: option.label }),
|
|
10197
|
+
value === option.value && /* @__PURE__ */ jsx41(Check2, { className: "text-icon-secondary ml-2 h-4 w-4" })
|
|
8485
10198
|
]
|
|
8486
10199
|
},
|
|
8487
10200
|
option.value
|
|
@@ -8494,7 +10207,7 @@ function SelectHover({
|
|
|
8494
10207
|
// src/ui/SelectInput/index.tsx
|
|
8495
10208
|
import * as SelectPrimitive from "@radix-ui/react-select";
|
|
8496
10209
|
import { CheckIcon as CheckIcon4, ChevronDownIcon as ChevronDownIcon3, ChevronUpIcon } from "lucide-react";
|
|
8497
|
-
import { jsx as
|
|
10210
|
+
import { jsx as jsx42, jsxs as jsxs32 } from "react/jsx-runtime";
|
|
8498
10211
|
function SelectInput({
|
|
8499
10212
|
defaultValue,
|
|
8500
10213
|
options,
|
|
@@ -8507,8 +10220,8 @@ function SelectInput({
|
|
|
8507
10220
|
itemProps,
|
|
8508
10221
|
...props
|
|
8509
10222
|
}) {
|
|
8510
|
-
return /* @__PURE__ */
|
|
8511
|
-
/* @__PURE__ */
|
|
10223
|
+
return /* @__PURE__ */ jsxs32(BaseSelect, { onValueChange: onChange, defaultValue, ...props, children: [
|
|
10224
|
+
/* @__PURE__ */ jsx42(
|
|
8512
10225
|
BaseSelectTrigger,
|
|
8513
10226
|
{
|
|
8514
10227
|
withArrow,
|
|
@@ -8516,7 +10229,7 @@ function SelectInput({
|
|
|
8516
10229
|
"aria-invalid": props["aria-invalid"],
|
|
8517
10230
|
className: cn("w-full cursor-pointer", className),
|
|
8518
10231
|
variant,
|
|
8519
|
-
children: /* @__PURE__ */
|
|
10232
|
+
children: /* @__PURE__ */ jsx42(
|
|
8520
10233
|
BaseSelectValue,
|
|
8521
10234
|
{
|
|
8522
10235
|
className: "flex-1",
|
|
@@ -8525,7 +10238,7 @@ function SelectInput({
|
|
|
8525
10238
|
)
|
|
8526
10239
|
}
|
|
8527
10240
|
),
|
|
8528
|
-
/* @__PURE__ */
|
|
10241
|
+
/* @__PURE__ */ jsx42(
|
|
8529
10242
|
BaseSelectContent,
|
|
8530
10243
|
{
|
|
8531
10244
|
...contentProps,
|
|
@@ -8533,7 +10246,7 @@ function SelectInput({
|
|
|
8533
10246
|
"border-stroke-inverse-slate-02 border",
|
|
8534
10247
|
contentProps?.className
|
|
8535
10248
|
),
|
|
8536
|
-
children: options.map((option) => /* @__PURE__ */
|
|
10249
|
+
children: options.map((option) => /* @__PURE__ */ jsxs32(
|
|
8537
10250
|
BaseSelectItem,
|
|
8538
10251
|
{
|
|
8539
10252
|
value: option.value,
|
|
@@ -8553,12 +10266,12 @@ function SelectInput({
|
|
|
8553
10266
|
function BaseSelect({
|
|
8554
10267
|
...props
|
|
8555
10268
|
}) {
|
|
8556
|
-
return /* @__PURE__ */
|
|
10269
|
+
return /* @__PURE__ */ jsx42(SelectPrimitive.Root, { "data-slot": "select", ...props });
|
|
8557
10270
|
}
|
|
8558
10271
|
function BaseSelectValue({
|
|
8559
10272
|
...props
|
|
8560
10273
|
}) {
|
|
8561
|
-
return /* @__PURE__ */
|
|
10274
|
+
return /* @__PURE__ */ jsx42(SelectPrimitive.Value, { "data-slot": "select-value", ...props });
|
|
8562
10275
|
}
|
|
8563
10276
|
function BaseSelectTrigger({
|
|
8564
10277
|
className,
|
|
@@ -8568,7 +10281,7 @@ function BaseSelectTrigger({
|
|
|
8568
10281
|
children,
|
|
8569
10282
|
...props
|
|
8570
10283
|
}) {
|
|
8571
|
-
return /* @__PURE__ */
|
|
10284
|
+
return /* @__PURE__ */ jsxs32(
|
|
8572
10285
|
SelectPrimitive.Trigger,
|
|
8573
10286
|
{
|
|
8574
10287
|
"data-slot": "select-trigger",
|
|
@@ -8589,7 +10302,7 @@ function BaseSelectTrigger({
|
|
|
8589
10302
|
...props,
|
|
8590
10303
|
children: [
|
|
8591
10304
|
children,
|
|
8592
|
-
withArrow && /* @__PURE__ */
|
|
10305
|
+
withArrow && /* @__PURE__ */ jsx42(SelectPrimitive.Icon, { asChild: true, children: /* @__PURE__ */ jsx42(ChevronDownIcon3, { className: "text-icon-default size-4" }) })
|
|
8593
10306
|
]
|
|
8594
10307
|
}
|
|
8595
10308
|
);
|
|
@@ -8600,7 +10313,7 @@ function BaseSelectContent({
|
|
|
8600
10313
|
position = "popper",
|
|
8601
10314
|
...props
|
|
8602
10315
|
}) {
|
|
8603
|
-
return /* @__PURE__ */
|
|
10316
|
+
return /* @__PURE__ */ jsx42(SelectPrimitive.Portal, { children: /* @__PURE__ */ jsxs32(
|
|
8604
10317
|
SelectPrimitive.Content,
|
|
8605
10318
|
{
|
|
8606
10319
|
"data-slot": "select-content",
|
|
@@ -8612,8 +10325,8 @@ function BaseSelectContent({
|
|
|
8612
10325
|
position,
|
|
8613
10326
|
...props,
|
|
8614
10327
|
children: [
|
|
8615
|
-
/* @__PURE__ */
|
|
8616
|
-
/* @__PURE__ */
|
|
10328
|
+
/* @__PURE__ */ jsx42(BaseSelectScrollUpButton, {}),
|
|
10329
|
+
/* @__PURE__ */ jsx42(
|
|
8617
10330
|
SelectPrimitive.Viewport,
|
|
8618
10331
|
{
|
|
8619
10332
|
className: cn(
|
|
@@ -8623,7 +10336,7 @@ function BaseSelectContent({
|
|
|
8623
10336
|
children
|
|
8624
10337
|
}
|
|
8625
10338
|
),
|
|
8626
|
-
/* @__PURE__ */
|
|
10339
|
+
/* @__PURE__ */ jsx42(BaseSelectScrollDownButton, {})
|
|
8627
10340
|
]
|
|
8628
10341
|
}
|
|
8629
10342
|
) });
|
|
@@ -8633,7 +10346,7 @@ function BaseSelectItem({
|
|
|
8633
10346
|
children,
|
|
8634
10347
|
...props
|
|
8635
10348
|
}) {
|
|
8636
|
-
return /* @__PURE__ */
|
|
10349
|
+
return /* @__PURE__ */ jsxs32(
|
|
8637
10350
|
SelectPrimitive.Item,
|
|
8638
10351
|
{
|
|
8639
10352
|
"data-slot": "select-item",
|
|
@@ -8643,8 +10356,8 @@ function BaseSelectItem({
|
|
|
8643
10356
|
),
|
|
8644
10357
|
...props,
|
|
8645
10358
|
children: [
|
|
8646
|
-
/* @__PURE__ */
|
|
8647
|
-
/* @__PURE__ */
|
|
10359
|
+
/* @__PURE__ */ jsx42("span", { className: "absolute right-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ jsx42(SelectPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx42(CheckIcon4, { className: "text-icon-secondary size-4" }) }) }),
|
|
10360
|
+
/* @__PURE__ */ jsx42(SelectPrimitive.ItemText, { children })
|
|
8648
10361
|
]
|
|
8649
10362
|
}
|
|
8650
10363
|
);
|
|
@@ -8653,7 +10366,7 @@ function BaseSelectScrollUpButton({
|
|
|
8653
10366
|
className,
|
|
8654
10367
|
...props
|
|
8655
10368
|
}) {
|
|
8656
|
-
return /* @__PURE__ */
|
|
10369
|
+
return /* @__PURE__ */ jsx42(
|
|
8657
10370
|
SelectPrimitive.ScrollUpButton,
|
|
8658
10371
|
{
|
|
8659
10372
|
"data-slot": "select-scroll-up-button",
|
|
@@ -8662,7 +10375,7 @@ function BaseSelectScrollUpButton({
|
|
|
8662
10375
|
className
|
|
8663
10376
|
),
|
|
8664
10377
|
...props,
|
|
8665
|
-
children: /* @__PURE__ */
|
|
10378
|
+
children: /* @__PURE__ */ jsx42(ChevronUpIcon, { className: "size-4" })
|
|
8666
10379
|
}
|
|
8667
10380
|
);
|
|
8668
10381
|
}
|
|
@@ -8670,7 +10383,7 @@ function BaseSelectScrollDownButton({
|
|
|
8670
10383
|
className,
|
|
8671
10384
|
...props
|
|
8672
10385
|
}) {
|
|
8673
|
-
return /* @__PURE__ */
|
|
10386
|
+
return /* @__PURE__ */ jsx42(
|
|
8674
10387
|
SelectPrimitive.ScrollDownButton,
|
|
8675
10388
|
{
|
|
8676
10389
|
"data-slot": "select-scroll-down-button",
|
|
@@ -8679,7 +10392,7 @@ function BaseSelectScrollDownButton({
|
|
|
8679
10392
|
className
|
|
8680
10393
|
),
|
|
8681
10394
|
...props,
|
|
8682
|
-
children: /* @__PURE__ */
|
|
10395
|
+
children: /* @__PURE__ */ jsx42(ChevronDownIcon3, { className: "size-4" })
|
|
8683
10396
|
}
|
|
8684
10397
|
);
|
|
8685
10398
|
}
|
|
@@ -8687,15 +10400,15 @@ function BaseSelectScrollDownButton({
|
|
|
8687
10400
|
// src/ui/Sheet/index.tsx
|
|
8688
10401
|
import * as SheetPrimitive from "@radix-ui/react-dialog";
|
|
8689
10402
|
import { XIcon as XIcon3 } from "lucide-react";
|
|
8690
|
-
import { jsx as
|
|
10403
|
+
import { jsx as jsx43, jsxs as jsxs33 } from "react/jsx-runtime";
|
|
8691
10404
|
function Sheet({ ...props }) {
|
|
8692
|
-
return /* @__PURE__ */
|
|
10405
|
+
return /* @__PURE__ */ jsx43(SheetPrimitive.Root, { "data-slot": "sheet", ...props });
|
|
8693
10406
|
}
|
|
8694
10407
|
|
|
8695
10408
|
// src/ui/Skeleton/index.tsx
|
|
8696
|
-
import { jsx as
|
|
10409
|
+
import { jsx as jsx44 } from "react/jsx-runtime";
|
|
8697
10410
|
function Skeleton({ className, ...props }) {
|
|
8698
|
-
return /* @__PURE__ */
|
|
10411
|
+
return /* @__PURE__ */ jsx44(
|
|
8699
10412
|
"div",
|
|
8700
10413
|
{
|
|
8701
10414
|
"data-slot": "skeleton",
|
|
@@ -8711,7 +10424,7 @@ function Skeleton({ className, ...props }) {
|
|
|
8711
10424
|
// src/ui/Slider/index.tsx
|
|
8712
10425
|
import * as SliderPrimitive from "@radix-ui/react-slider";
|
|
8713
10426
|
import * as React15 from "react";
|
|
8714
|
-
import { jsx as
|
|
10427
|
+
import { jsx as jsx45, jsxs as jsxs34 } from "react/jsx-runtime";
|
|
8715
10428
|
function Slider({
|
|
8716
10429
|
className,
|
|
8717
10430
|
defaultValue,
|
|
@@ -8724,7 +10437,7 @@ function Slider({
|
|
|
8724
10437
|
() => Array.isArray(value) ? value : Array.isArray(defaultValue) ? defaultValue : [min, max],
|
|
8725
10438
|
[value, defaultValue, min, max]
|
|
8726
10439
|
);
|
|
8727
|
-
return /* @__PURE__ */
|
|
10440
|
+
return /* @__PURE__ */ jsxs34(
|
|
8728
10441
|
SliderPrimitive.Root,
|
|
8729
10442
|
{
|
|
8730
10443
|
"data-slot": "slider",
|
|
@@ -8738,14 +10451,14 @@ function Slider({
|
|
|
8738
10451
|
),
|
|
8739
10452
|
...props,
|
|
8740
10453
|
children: [
|
|
8741
|
-
/* @__PURE__ */
|
|
10454
|
+
/* @__PURE__ */ jsx45(
|
|
8742
10455
|
SliderPrimitive.Track,
|
|
8743
10456
|
{
|
|
8744
10457
|
"data-slot": "slider-track",
|
|
8745
10458
|
className: cn(
|
|
8746
10459
|
"bg-audioProgress-bg relative grow overflow-hidden rounded-full data-[orientation=horizontal]:h-1.5 data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-1.5"
|
|
8747
10460
|
),
|
|
8748
|
-
children: /* @__PURE__ */
|
|
10461
|
+
children: /* @__PURE__ */ jsx45(
|
|
8749
10462
|
SliderPrimitive.Range,
|
|
8750
10463
|
{
|
|
8751
10464
|
"data-slot": "slider-range",
|
|
@@ -8756,7 +10469,7 @@ function Slider({
|
|
|
8756
10469
|
)
|
|
8757
10470
|
}
|
|
8758
10471
|
),
|
|
8759
|
-
Array.from({ length: _values.length }, (_, index) => /* @__PURE__ */
|
|
10472
|
+
Array.from({ length: _values.length }, (_, index) => /* @__PURE__ */ jsx45(
|
|
8760
10473
|
SliderPrimitive.Thumb,
|
|
8761
10474
|
{
|
|
8762
10475
|
"data-slot": "slider-thumb",
|
|
@@ -8772,10 +10485,10 @@ function Slider({
|
|
|
8772
10485
|
// src/ui/Sooner/index.tsx
|
|
8773
10486
|
import { useTheme } from "next-themes";
|
|
8774
10487
|
import { Toaster as Sonner } from "sonner";
|
|
8775
|
-
import { jsx as
|
|
10488
|
+
import { jsx as jsx46 } from "react/jsx-runtime";
|
|
8776
10489
|
var Toaster = ({ ...props }) => {
|
|
8777
10490
|
const { theme = "system" } = useTheme();
|
|
8778
|
-
return /* @__PURE__ */
|
|
10491
|
+
return /* @__PURE__ */ jsx46(
|
|
8779
10492
|
Sonner,
|
|
8780
10493
|
{
|
|
8781
10494
|
theme,
|
|
@@ -8792,14 +10505,14 @@ var Toaster = ({ ...props }) => {
|
|
|
8792
10505
|
|
|
8793
10506
|
// src/ui/Switch/index.tsx
|
|
8794
10507
|
import * as SwitchPrimitive from "@radix-ui/react-switch";
|
|
8795
|
-
import { jsx as
|
|
10508
|
+
import { jsx as jsx47, jsxs as jsxs35 } from "react/jsx-runtime";
|
|
8796
10509
|
function Switch({
|
|
8797
10510
|
className,
|
|
8798
10511
|
label,
|
|
8799
10512
|
...props
|
|
8800
10513
|
}) {
|
|
8801
|
-
return /* @__PURE__ */
|
|
8802
|
-
/* @__PURE__ */
|
|
10514
|
+
return /* @__PURE__ */ jsxs35("div", { className: "flex items-center space-x-2", children: [
|
|
10515
|
+
/* @__PURE__ */ jsx47(
|
|
8803
10516
|
SwitchPrimitive.Root,
|
|
8804
10517
|
{
|
|
8805
10518
|
"data-slot": "switch",
|
|
@@ -8809,7 +10522,7 @@ function Switch({
|
|
|
8809
10522
|
className
|
|
8810
10523
|
),
|
|
8811
10524
|
...props,
|
|
8812
|
-
children: /* @__PURE__ */
|
|
10525
|
+
children: /* @__PURE__ */ jsx47(
|
|
8813
10526
|
SwitchPrimitive.Thumb,
|
|
8814
10527
|
{
|
|
8815
10528
|
"data-slot": "switch-thumb",
|
|
@@ -8820,7 +10533,7 @@ function Switch({
|
|
|
8820
10533
|
)
|
|
8821
10534
|
}
|
|
8822
10535
|
),
|
|
8823
|
-
label && /* @__PURE__ */
|
|
10536
|
+
label && /* @__PURE__ */ jsx47(Label2, { htmlFor: props.id || label, children: label })
|
|
8824
10537
|
] });
|
|
8825
10538
|
}
|
|
8826
10539
|
|
|
@@ -8843,8 +10556,8 @@ import {
|
|
|
8843
10556
|
MagickoCopySuccess
|
|
8844
10557
|
} from "magick-icons";
|
|
8845
10558
|
import * as React16 from "react";
|
|
8846
|
-
import { useState as
|
|
8847
|
-
import { Fragment as Fragment6, jsx as
|
|
10559
|
+
import { useState as useState12 } from "react";
|
|
10560
|
+
import { Fragment as Fragment6, jsx as jsx48, jsxs as jsxs36 } from "react/jsx-runtime";
|
|
8848
10561
|
var Table = ({
|
|
8849
10562
|
columns,
|
|
8850
10563
|
tableData,
|
|
@@ -8852,7 +10565,7 @@ var Table = ({
|
|
|
8852
10565
|
emptyState = {
|
|
8853
10566
|
emptyAction: void 0,
|
|
8854
10567
|
label: "There is currently no data available to display in this table.",
|
|
8855
|
-
icon: /* @__PURE__ */
|
|
10568
|
+
icon: /* @__PURE__ */ jsx48(IconProfile, { icon: /* @__PURE__ */ jsx48(IconsaxBriefcaseBold, {}), color: "teal" })
|
|
8856
10569
|
},
|
|
8857
10570
|
onRowClick
|
|
8858
10571
|
}) => {
|
|
@@ -8864,41 +10577,41 @@ var Table = ({
|
|
|
8864
10577
|
getSortedRowModel: getSortedRowModel()
|
|
8865
10578
|
});
|
|
8866
10579
|
const rowCount = table.getRowModel().rows.length;
|
|
8867
|
-
return /* @__PURE__ */
|
|
8868
|
-
isLoading ? /* @__PURE__ */
|
|
10580
|
+
return /* @__PURE__ */ jsxs36("div", { className: "relative flex flex-col overflow-auto", children: [
|
|
10581
|
+
isLoading ? /* @__PURE__ */ jsx48(
|
|
8869
10582
|
"div",
|
|
8870
10583
|
{
|
|
8871
10584
|
className: cn(
|
|
8872
10585
|
rowCount === 0 ? "" : "bg-gray-100 dark:bg-gray-700",
|
|
8873
10586
|
"absolute top-10 left-0 w-full h-full min-h-[100px] opacity-70 z-10 flex items-center justify-center"
|
|
8874
10587
|
),
|
|
8875
|
-
children: /* @__PURE__ */
|
|
10588
|
+
children: /* @__PURE__ */ jsx48(Spinner, { className: "size-10 text-stroke-inverse-slate-04 " })
|
|
8876
10589
|
}
|
|
8877
10590
|
) : null,
|
|
8878
|
-
!isLoading && rowCount === 0 ? /* @__PURE__ */
|
|
10591
|
+
!isLoading && rowCount === 0 ? /* @__PURE__ */ jsx48("div", { className: "absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 z-2", children: /* @__PURE__ */ jsxs36("div", { className: "flex flex-col items-center gap-4", children: [
|
|
8879
10592
|
emptyState?.icon,
|
|
8880
|
-
/* @__PURE__ */
|
|
8881
|
-
emptyState?.emptyAction ? /* @__PURE__ */
|
|
10593
|
+
/* @__PURE__ */ jsx48(Text, { children: emptyState?.label }),
|
|
10594
|
+
emptyState?.emptyAction ? /* @__PURE__ */ jsx48(
|
|
8882
10595
|
Button,
|
|
8883
10596
|
{
|
|
8884
10597
|
variant: "outline",
|
|
8885
|
-
prefix: /* @__PURE__ */
|
|
10598
|
+
prefix: /* @__PURE__ */ jsx48(MagickoAdd, { className: "[&_path]:fill-element-inverse-default" }),
|
|
8886
10599
|
onClick: () => emptyState?.emptyAction?.(),
|
|
8887
10600
|
children: "Create new"
|
|
8888
10601
|
}
|
|
8889
10602
|
) : null
|
|
8890
10603
|
] }) }) : null,
|
|
8891
|
-
/* @__PURE__ */
|
|
10604
|
+
/* @__PURE__ */ jsx48("div", { className: "max-w-full flex-1 overflow-x-auto", children: /* @__PURE__ */ jsxs36(
|
|
8892
10605
|
"table",
|
|
8893
10606
|
{
|
|
8894
10607
|
className: "w-full caption-bottom text-sm",
|
|
8895
10608
|
style: { minWidth: "max-content" },
|
|
8896
10609
|
children: [
|
|
8897
|
-
/* @__PURE__ */
|
|
10610
|
+
/* @__PURE__ */ jsx48("thead", { className: "bg-fill-inverse-slate-03", children: table.getHeaderGroups().map((headerGroup) => /* @__PURE__ */ jsx48(
|
|
8898
10611
|
"tr",
|
|
8899
10612
|
{
|
|
8900
10613
|
className: "hover:bg-muted/50 border-stroke-inverse-slate-02 border-b transition-colors",
|
|
8901
|
-
children: headerGroup.headers.map((header) => /* @__PURE__ */
|
|
10614
|
+
children: headerGroup.headers.map((header) => /* @__PURE__ */ jsx48(
|
|
8902
10615
|
"th",
|
|
8903
10616
|
{
|
|
8904
10617
|
className: "text-muted-foreground h-12 px-4 text-left align-middle font-medium",
|
|
@@ -8912,14 +10625,14 @@ var Table = ({
|
|
|
8912
10625
|
},
|
|
8913
10626
|
headerGroup.id
|
|
8914
10627
|
)) }),
|
|
8915
|
-
/* @__PURE__ */
|
|
10628
|
+
/* @__PURE__ */ jsxs36("tbody", { className: "relative", children: [
|
|
8916
10629
|
table.getRowModel().rows.map((row) => {
|
|
8917
|
-
return /* @__PURE__ */
|
|
10630
|
+
return /* @__PURE__ */ jsx48(
|
|
8918
10631
|
"tr",
|
|
8919
10632
|
{
|
|
8920
10633
|
className: "hover:bg-muted/50 bg-table-table-cell-unselected group/row border-stroke-inverse-slate-02 cursor-pointer border-b transition-colors",
|
|
8921
10634
|
onClick: () => onRowClick?.(row.original),
|
|
8922
|
-
children: row.getVisibleCells().map((cell) => /* @__PURE__ */
|
|
10635
|
+
children: row.getVisibleCells().map((cell) => /* @__PURE__ */ jsx48("td", { className: "p-4", children: flexRender(
|
|
8923
10636
|
cell.column.columnDef.cell,
|
|
8924
10637
|
cell.getContext()
|
|
8925
10638
|
) }, cell.id))
|
|
@@ -8927,7 +10640,7 @@ var Table = ({
|
|
|
8927
10640
|
row.id
|
|
8928
10641
|
);
|
|
8929
10642
|
}),
|
|
8930
|
-
rowCount === 0 && Array.from({ length: 6 }).map((_, index) => /* @__PURE__ */
|
|
10643
|
+
rowCount === 0 && Array.from({ length: 6 }).map((_, index) => /* @__PURE__ */ jsx48("tr", { children: /* @__PURE__ */ jsx48("td", { colSpan: columns.length, className: "h-12 p-4", children: /* @__PURE__ */ jsx48("div", { className: "" }) }) }, index))
|
|
8931
10644
|
] })
|
|
8932
10645
|
]
|
|
8933
10646
|
}
|
|
@@ -8962,13 +10675,13 @@ var PrimaryCell = React16.forwardRef(
|
|
|
8962
10675
|
}, ref) => {
|
|
8963
10676
|
let content = children;
|
|
8964
10677
|
if (variant === "badge") {
|
|
8965
|
-
content = /* @__PURE__ */
|
|
10678
|
+
content = /* @__PURE__ */ jsxs36("div", { className: "flex items-center gap-2", children: [
|
|
8966
10679
|
children,
|
|
8967
|
-
badgeContent && /* @__PURE__ */
|
|
10680
|
+
badgeContent && /* @__PURE__ */ jsx48(Badge, { type: badgeType, size: badgeSize, children: badgeContent })
|
|
8968
10681
|
] });
|
|
8969
10682
|
} else if (variant === "progress") {
|
|
8970
|
-
content = /* @__PURE__ */
|
|
8971
|
-
progressValue !== 100 && /* @__PURE__ */
|
|
10683
|
+
content = /* @__PURE__ */ jsxs36(Fragment6, { children: [
|
|
10684
|
+
progressValue !== 100 && /* @__PURE__ */ jsx48(
|
|
8972
10685
|
ProgressIndicator,
|
|
8973
10686
|
{
|
|
8974
10687
|
variant: "circle",
|
|
@@ -8977,23 +10690,23 @@ var PrimaryCell = React16.forwardRef(
|
|
|
8977
10690
|
showPercentage: showProgressPercentage
|
|
8978
10691
|
}
|
|
8979
10692
|
),
|
|
8980
|
-
children && /* @__PURE__ */
|
|
10693
|
+
children && /* @__PURE__ */ jsx48("span", { className: "text-body-sm text-element-inverse-default", children })
|
|
8981
10694
|
] });
|
|
8982
10695
|
} else if (variant === "error") {
|
|
8983
|
-
content = /* @__PURE__ */
|
|
8984
|
-
/* @__PURE__ */
|
|
8985
|
-
errorMessage ? /* @__PURE__ */
|
|
10696
|
+
content = /* @__PURE__ */ jsxs36(Fragment6, { children: [
|
|
10697
|
+
/* @__PURE__ */ jsx48(AlertCircle, { className: "size-4 shrink-0" }),
|
|
10698
|
+
errorMessage ? /* @__PURE__ */ jsx48("span", { className: "text-body-sm", children: errorMessage }) : children
|
|
8986
10699
|
] });
|
|
8987
10700
|
}
|
|
8988
|
-
return /* @__PURE__ */
|
|
10701
|
+
return /* @__PURE__ */ jsxs36(
|
|
8989
10702
|
"div",
|
|
8990
10703
|
{
|
|
8991
10704
|
ref,
|
|
8992
10705
|
className: cn(primaryCellVariants({ variant })),
|
|
8993
10706
|
...props,
|
|
8994
10707
|
children: [
|
|
8995
|
-
/* @__PURE__ */
|
|
8996
|
-
hoverUI && /* @__PURE__ */
|
|
10708
|
+
/* @__PURE__ */ jsx48("div", { className: "flex min-w-0 flex-1 items-center gap-2", children: content }),
|
|
10709
|
+
hoverUI && /* @__PURE__ */ jsx48("div", { className: "ml-2 flex items-center gap-2 opacity-0 transition-opacity duration-200 group-hover/row:opacity-100", children: hoverUI })
|
|
8997
10710
|
]
|
|
8998
10711
|
}
|
|
8999
10712
|
);
|
|
@@ -9002,7 +10715,7 @@ var PrimaryCell = React16.forwardRef(
|
|
|
9002
10715
|
PrimaryCell.displayName = "PrimaryCell";
|
|
9003
10716
|
Table.PrimaryCell = PrimaryCell;
|
|
9004
10717
|
var TextCell = React16.forwardRef(({ text, copyable = true, className, ...props }, ref) => {
|
|
9005
|
-
const [isCopied, setIsCopied] =
|
|
10718
|
+
const [isCopied, setIsCopied] = useState12(false);
|
|
9006
10719
|
const [hoverRef, isHovering] = useHover();
|
|
9007
10720
|
const handleCopy = () => {
|
|
9008
10721
|
navigator.clipboard.writeText(text);
|
|
@@ -9015,11 +10728,11 @@ var TextCell = React16.forwardRef(({ text, copyable = true, className, ...props
|
|
|
9015
10728
|
}, 1200);
|
|
9016
10729
|
}
|
|
9017
10730
|
}, [isCopied]);
|
|
9018
|
-
return /* @__PURE__ */
|
|
9019
|
-
copyable && isHovering && /* @__PURE__ */
|
|
10731
|
+
return /* @__PURE__ */ jsx48("div", { className: cn("w-full h-full", className), ref, ...props, children: /* @__PURE__ */ jsxs36("div", { className: "relative", ref: hoverRef, children: [
|
|
10732
|
+
copyable && isHovering && /* @__PURE__ */ jsx48(
|
|
9020
10733
|
IconButton,
|
|
9021
10734
|
{
|
|
9022
|
-
icon: isCopied ? /* @__PURE__ */
|
|
10735
|
+
icon: isCopied ? /* @__PURE__ */ jsx48(
|
|
9023
10736
|
MagickoCopySuccess,
|
|
9024
10737
|
{
|
|
9025
10738
|
className: cn(
|
|
@@ -9027,16 +10740,16 @@ var TextCell = React16.forwardRef(({ text, copyable = true, className, ...props
|
|
|
9027
10740
|
"transition-all ease-in duration-200"
|
|
9028
10741
|
)
|
|
9029
10742
|
}
|
|
9030
|
-
) : /* @__PURE__ */
|
|
10743
|
+
) : /* @__PURE__ */ jsx48(MagickoCopy, { className: "size-4" }),
|
|
9031
10744
|
className: "absolute top-1/2 -right-3 -translate-y-1/2",
|
|
9032
10745
|
size: "sm",
|
|
9033
10746
|
varient: "soft",
|
|
9034
10747
|
onClick: handleCopy
|
|
9035
10748
|
}
|
|
9036
10749
|
),
|
|
9037
|
-
/* @__PURE__ */
|
|
9038
|
-
/* @__PURE__ */
|
|
9039
|
-
/* @__PURE__ */
|
|
10750
|
+
/* @__PURE__ */ jsxs36(Popover, { children: [
|
|
10751
|
+
/* @__PURE__ */ jsx48(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx48(Text, { className: "truncate line-clamp-1", children: text ?? "-" }) }),
|
|
10752
|
+
/* @__PURE__ */ jsx48(PopoverContent, { className: "", children: /* @__PURE__ */ jsx48(Text, { children: text ?? "-" }) })
|
|
9040
10753
|
] })
|
|
9041
10754
|
] }) });
|
|
9042
10755
|
});
|
|
@@ -9046,7 +10759,7 @@ var Table_default = Table;
|
|
|
9046
10759
|
|
|
9047
10760
|
// src/ui/Tabs/index.tsx
|
|
9048
10761
|
import * as TabsPrimitive from "@radix-ui/react-tabs";
|
|
9049
|
-
import { jsx as
|
|
10762
|
+
import { jsx as jsx49, jsxs as jsxs37 } from "react/jsx-runtime";
|
|
9050
10763
|
function Tabs({
|
|
9051
10764
|
defaultActiveTab,
|
|
9052
10765
|
tabSmall,
|
|
@@ -9055,8 +10768,8 @@ function Tabs({
|
|
|
9055
10768
|
showContent = true,
|
|
9056
10769
|
...props
|
|
9057
10770
|
}) {
|
|
9058
|
-
return /* @__PURE__ */
|
|
9059
|
-
/* @__PURE__ */
|
|
10771
|
+
return /* @__PURE__ */ jsxs37(BaseTabs, { defaultValue: defaultActiveTab, className, ...props, children: [
|
|
10772
|
+
/* @__PURE__ */ jsx49(BaseTabsList, { children: tabs.map((tab) => /* @__PURE__ */ jsxs37(
|
|
9060
10773
|
BaseTabsTrigger,
|
|
9061
10774
|
{
|
|
9062
10775
|
tabSmall,
|
|
@@ -9064,22 +10777,22 @@ function Tabs({
|
|
|
9064
10777
|
className: "relative flex cursor-pointer items-center justify-center gap-x-2",
|
|
9065
10778
|
onClick: typeof tab === "object" && "onClick" in tab ? tab.onClick : void 0,
|
|
9066
10779
|
children: [
|
|
9067
|
-
tab.icon && /* @__PURE__ */
|
|
10780
|
+
tab.icon && /* @__PURE__ */ jsx49("div", { children: tab.icon }),
|
|
9068
10781
|
tab.label,
|
|
9069
|
-
tab.notification && /* @__PURE__ */
|
|
9070
|
-
!!tab.count && /* @__PURE__ */
|
|
10782
|
+
tab.notification && /* @__PURE__ */ jsx49("div", { className: "bg-icon-destructive absolute top-1 right-1 size-1.5 rounded-full" }),
|
|
10783
|
+
!!tab.count && /* @__PURE__ */ jsx49(Badge, { type: "primary-soft", children: tab.count })
|
|
9071
10784
|
]
|
|
9072
10785
|
},
|
|
9073
10786
|
tab.value
|
|
9074
10787
|
)) }),
|
|
9075
|
-
showContent && "content" in tabs[0] && tabs.map((tab) => /* @__PURE__ */
|
|
10788
|
+
showContent && "content" in tabs[0] && tabs.map((tab) => /* @__PURE__ */ jsx49(BaseTabsContent, { value: tab.value, children: tab.content }, tab.value))
|
|
9076
10789
|
] });
|
|
9077
10790
|
}
|
|
9078
10791
|
function BaseTabs({
|
|
9079
10792
|
className,
|
|
9080
10793
|
...props
|
|
9081
10794
|
}) {
|
|
9082
|
-
return /* @__PURE__ */
|
|
10795
|
+
return /* @__PURE__ */ jsx49(
|
|
9083
10796
|
TabsPrimitive.Root,
|
|
9084
10797
|
{
|
|
9085
10798
|
"data-slot": "tabs",
|
|
@@ -9092,7 +10805,7 @@ function BaseTabsList({
|
|
|
9092
10805
|
className,
|
|
9093
10806
|
...props
|
|
9094
10807
|
}) {
|
|
9095
|
-
return /* @__PURE__ */
|
|
10808
|
+
return /* @__PURE__ */ jsx49(
|
|
9096
10809
|
TabsPrimitive.List,
|
|
9097
10810
|
{
|
|
9098
10811
|
"data-slot": "tabs-list",
|
|
@@ -9109,7 +10822,7 @@ function BaseTabsTrigger({
|
|
|
9109
10822
|
tabSmall,
|
|
9110
10823
|
...props
|
|
9111
10824
|
}) {
|
|
9112
|
-
return /* @__PURE__ */
|
|
10825
|
+
return /* @__PURE__ */ jsx49(
|
|
9113
10826
|
TabsPrimitive.Trigger,
|
|
9114
10827
|
{
|
|
9115
10828
|
"data-slot": "tabs-trigger",
|
|
@@ -9126,7 +10839,7 @@ function BaseTabsContent({
|
|
|
9126
10839
|
className,
|
|
9127
10840
|
...props
|
|
9128
10841
|
}) {
|
|
9129
|
-
return /* @__PURE__ */
|
|
10842
|
+
return /* @__PURE__ */ jsx49(
|
|
9130
10843
|
TabsPrimitive.Content,
|
|
9131
10844
|
{
|
|
9132
10845
|
"data-slot": "tabs-content",
|
|
@@ -9138,7 +10851,7 @@ function BaseTabsContent({
|
|
|
9138
10851
|
|
|
9139
10852
|
// src/ui/Tag/index.tsx
|
|
9140
10853
|
import { cva as cva12 } from "class-variance-authority";
|
|
9141
|
-
import { jsx as
|
|
10854
|
+
import { jsx as jsx50 } from "react/jsx-runtime";
|
|
9142
10855
|
var tagVariants = cva12("px-1 rounded-sm", {
|
|
9143
10856
|
variants: {
|
|
9144
10857
|
variant: {
|
|
@@ -9156,14 +10869,14 @@ function Tag({
|
|
|
9156
10869
|
variant,
|
|
9157
10870
|
className
|
|
9158
10871
|
}) {
|
|
9159
|
-
return /* @__PURE__ */
|
|
10872
|
+
return /* @__PURE__ */ jsx50("div", { "data-slot": "tag", className: cn(tagVariants({ variant }), className), children: /* @__PURE__ */ jsx50("span", { className: "text-caption font-semibold text-white", children: label }) });
|
|
9160
10873
|
}
|
|
9161
10874
|
|
|
9162
10875
|
// src/ui/TextAreaInput/index.tsx
|
|
9163
10876
|
import * as React17 from "react";
|
|
9164
|
-
import { jsx as
|
|
10877
|
+
import { jsx as jsx51 } from "react/jsx-runtime";
|
|
9165
10878
|
var TextareaInput = React17.forwardRef(({ className, label, ...props }, ref) => {
|
|
9166
|
-
return /* @__PURE__ */
|
|
10879
|
+
return /* @__PURE__ */ jsx51(
|
|
9167
10880
|
"textarea",
|
|
9168
10881
|
{
|
|
9169
10882
|
ref,
|
|
@@ -9183,8 +10896,8 @@ var TextAreaInput_default = TextareaInput;
|
|
|
9183
10896
|
|
|
9184
10897
|
// src/ui/TimePicker/index.tsx
|
|
9185
10898
|
import { Clock } from "lucide-react";
|
|
9186
|
-
import { useState as
|
|
9187
|
-
import { jsx as
|
|
10899
|
+
import { useState as useState13 } from "react";
|
|
10900
|
+
import { jsx as jsx52, jsxs as jsxs38 } from "react/jsx-runtime";
|
|
9188
10901
|
function TimePicker({
|
|
9189
10902
|
label,
|
|
9190
10903
|
onValueChange,
|
|
@@ -9193,7 +10906,7 @@ function TimePicker({
|
|
|
9193
10906
|
value,
|
|
9194
10907
|
...props
|
|
9195
10908
|
}) {
|
|
9196
|
-
const [isOpen, setIsOpen] =
|
|
10909
|
+
const [isOpen, setIsOpen] = useState13(false);
|
|
9197
10910
|
const currentValue = value || defaultValue || "";
|
|
9198
10911
|
const formatTimeForDisplay = (timeValue) => {
|
|
9199
10912
|
if (!timeValue) return "";
|
|
@@ -9205,10 +10918,10 @@ function TimePicker({
|
|
|
9205
10918
|
const handleChange = (value2) => {
|
|
9206
10919
|
onValueChange?.(value2);
|
|
9207
10920
|
};
|
|
9208
|
-
return /* @__PURE__ */
|
|
9209
|
-
label && /* @__PURE__ */
|
|
9210
|
-
/* @__PURE__ */
|
|
9211
|
-
/* @__PURE__ */
|
|
10921
|
+
return /* @__PURE__ */ jsxs38("div", { className: "flex flex-col gap-3", children: [
|
|
10922
|
+
label && /* @__PURE__ */ jsx52(Label2, { htmlFor: "time-picker", className: "px-1", children: "Time" }),
|
|
10923
|
+
/* @__PURE__ */ jsxs38(DropdownMenu, { open: isOpen, onOpenChange: setIsOpen, children: [
|
|
10924
|
+
/* @__PURE__ */ jsx52(DropdownMenuTrigger, { className: "!p-0", children: /* @__PURE__ */ jsx52(
|
|
9212
10925
|
Input,
|
|
9213
10926
|
{
|
|
9214
10927
|
...props,
|
|
@@ -9216,17 +10929,17 @@ function TimePicker({
|
|
|
9216
10929
|
value: currentValue ? formatTimeForDisplay(currentValue) : "",
|
|
9217
10930
|
onKeyDown: (e) => e.preventDefault(),
|
|
9218
10931
|
prefixNode: {
|
|
9219
|
-
node: /* @__PURE__ */
|
|
10932
|
+
node: /* @__PURE__ */ jsx52(Clock, { className: "pointer-events-none h-5 w-5 text-gray-700" }),
|
|
9220
10933
|
withBorder: false
|
|
9221
10934
|
}
|
|
9222
10935
|
}
|
|
9223
10936
|
) }),
|
|
9224
|
-
/* @__PURE__ */
|
|
10937
|
+
/* @__PURE__ */ jsx52(
|
|
9225
10938
|
DropdownMenuContent,
|
|
9226
10939
|
{
|
|
9227
10940
|
align: "start",
|
|
9228
10941
|
className: "max-h-60 min-w-41 overflow-y-auto",
|
|
9229
|
-
children: timeOptions?.map((item) => /* @__PURE__ */
|
|
10942
|
+
children: timeOptions?.map((item) => /* @__PURE__ */ jsx52(
|
|
9230
10943
|
DropdownMenuItem,
|
|
9231
10944
|
{
|
|
9232
10945
|
className: cn(
|
|
@@ -9247,11 +10960,11 @@ function TimePicker({
|
|
|
9247
10960
|
// src/ui/Title/index.tsx
|
|
9248
10961
|
import { Slot as Slot6 } from "@radix-ui/react-slot";
|
|
9249
10962
|
import * as React18 from "react";
|
|
9250
|
-
import { jsx as
|
|
10963
|
+
import { jsx as jsx53 } from "react/jsx-runtime";
|
|
9251
10964
|
var Title2 = React18.forwardRef(
|
|
9252
10965
|
({ className, asChild = false, ...props }, ref) => {
|
|
9253
10966
|
const Comp = asChild ? Slot6 : "h2";
|
|
9254
|
-
return /* @__PURE__ */
|
|
10967
|
+
return /* @__PURE__ */ jsx53(
|
|
9255
10968
|
Comp,
|
|
9256
10969
|
{
|
|
9257
10970
|
ref,
|
|
@@ -9270,7 +10983,7 @@ var Title_default = Title2;
|
|
|
9270
10983
|
// src/ui/Toggle/index.tsx
|
|
9271
10984
|
import * as TogglePrimitive from "@radix-ui/react-toggle";
|
|
9272
10985
|
import { cva as cva13 } from "class-variance-authority";
|
|
9273
|
-
import { jsx as
|
|
10986
|
+
import { jsx as jsx54 } from "react/jsx-runtime";
|
|
9274
10987
|
var toggleVariants = cva13(
|
|
9275
10988
|
"inline-flex items-center justify-center gap-2 text-sm font-medium disabled:pointer-events-none disabled:text-icon-inactive data-[state=on]:disabled:text-icon-inactive data-[state=on]:disabled:bg-toggle-bg-inactiveDefault data-[state=on]:bg-toggle-bg-activeDefault data-[state=on]:hover:bg-toggle-bg-activeHover data-[state=on]:text-icon-white hover:bg-toggle-bg-inactiveHover hover:text-icon-default [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 [&_svg]:shrink-0 focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none transition-[color,box-shadow] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive whitespace-nowrap cursor-pointer",
|
|
9276
10989
|
{
|
|
@@ -9305,7 +11018,7 @@ function Toggle({
|
|
|
9305
11018
|
size,
|
|
9306
11019
|
...props
|
|
9307
11020
|
}) {
|
|
9308
|
-
return /* @__PURE__ */
|
|
11021
|
+
return /* @__PURE__ */ jsx54(
|
|
9309
11022
|
TogglePrimitive.Root,
|
|
9310
11023
|
{
|
|
9311
11024
|
"data-slot": "toggle",
|
|
@@ -9322,7 +11035,7 @@ import { useRef as useRef10 } from "react";
|
|
|
9322
11035
|
// src/ui/ToggleDropdownButton/ToggleDropdownLeftButton.tsx
|
|
9323
11036
|
import { cva as cva14 } from "class-variance-authority";
|
|
9324
11037
|
import * as React19 from "react";
|
|
9325
|
-
import { jsx as
|
|
11038
|
+
import { jsx as jsx55 } from "react/jsx-runtime";
|
|
9326
11039
|
var toggleDropdownLeftButtonVariants = cva14(
|
|
9327
11040
|
"flex items-center justify-center cursor-pointer transition-all",
|
|
9328
11041
|
{
|
|
@@ -9418,7 +11131,7 @@ function ToggleDropdownLeftButton({
|
|
|
9418
11131
|
}) {
|
|
9419
11132
|
const iconClass = selected ? "text-element-static-white fill-element-static-white" : "text-element-inverse-default fill-element-inverse-default";
|
|
9420
11133
|
const isIcon = React19.isValidElement(children);
|
|
9421
|
-
return type === "text" ? /* @__PURE__ */
|
|
11134
|
+
return type === "text" ? /* @__PURE__ */ jsx55(
|
|
9422
11135
|
"button",
|
|
9423
11136
|
{
|
|
9424
11137
|
type: "button",
|
|
@@ -9427,7 +11140,7 @@ function ToggleDropdownLeftButton({
|
|
|
9427
11140
|
className
|
|
9428
11141
|
),
|
|
9429
11142
|
...props,
|
|
9430
|
-
children: isIcon ? /* @__PURE__ */
|
|
11143
|
+
children: isIcon ? /* @__PURE__ */ jsx55(
|
|
9431
11144
|
IconContainer,
|
|
9432
11145
|
{
|
|
9433
11146
|
colorInFill: false,
|
|
@@ -9440,7 +11153,7 @@ function ToggleDropdownLeftButton({
|
|
|
9440
11153
|
}
|
|
9441
11154
|
) : children
|
|
9442
11155
|
}
|
|
9443
|
-
) : /* @__PURE__ */
|
|
11156
|
+
) : /* @__PURE__ */ jsx55(
|
|
9444
11157
|
"button",
|
|
9445
11158
|
{
|
|
9446
11159
|
type: "button",
|
|
@@ -9449,7 +11162,7 @@ function ToggleDropdownLeftButton({
|
|
|
9449
11162
|
className
|
|
9450
11163
|
),
|
|
9451
11164
|
...props,
|
|
9452
|
-
children: /* @__PURE__ */
|
|
11165
|
+
children: /* @__PURE__ */ jsx55(
|
|
9453
11166
|
IconContainer,
|
|
9454
11167
|
{
|
|
9455
11168
|
colorInFill: false,
|
|
@@ -9468,7 +11181,7 @@ function ToggleDropdownLeftButton({
|
|
|
9468
11181
|
// src/ui/ToggleDropdownButton/ToggleDropdownRightButton.tsx
|
|
9469
11182
|
import { cva as cva15 } from "class-variance-authority";
|
|
9470
11183
|
import * as React20 from "react";
|
|
9471
|
-
import { jsx as
|
|
11184
|
+
import { jsx as jsx56 } from "react/jsx-runtime";
|
|
9472
11185
|
var toggleDropdownRightButtonVariants = cva15(
|
|
9473
11186
|
"flex items-center justify-center group cursor-pointer transition-all",
|
|
9474
11187
|
{
|
|
@@ -9564,7 +11277,7 @@ function ToggleDropdownRightButton({
|
|
|
9564
11277
|
}) {
|
|
9565
11278
|
const iconClass = selected ? "text-element-static-white fill-element-static-white" : "text-element-inverse-default fill-element-inverse-default";
|
|
9566
11279
|
const isIcon = React20.isValidElement(children);
|
|
9567
|
-
return type === "text" ? /* @__PURE__ */
|
|
11280
|
+
return type === "text" ? /* @__PURE__ */ jsx56(
|
|
9568
11281
|
"button",
|
|
9569
11282
|
{
|
|
9570
11283
|
type: "button",
|
|
@@ -9573,7 +11286,7 @@ function ToggleDropdownRightButton({
|
|
|
9573
11286
|
className
|
|
9574
11287
|
),
|
|
9575
11288
|
...props,
|
|
9576
|
-
children: isIcon ? /* @__PURE__ */
|
|
11289
|
+
children: isIcon ? /* @__PURE__ */ jsx56(
|
|
9577
11290
|
IconContainer,
|
|
9578
11291
|
{
|
|
9579
11292
|
colorInFill: false,
|
|
@@ -9586,7 +11299,7 @@ function ToggleDropdownRightButton({
|
|
|
9586
11299
|
}
|
|
9587
11300
|
) : children
|
|
9588
11301
|
}
|
|
9589
|
-
) : /* @__PURE__ */
|
|
11302
|
+
) : /* @__PURE__ */ jsx56(
|
|
9590
11303
|
"button",
|
|
9591
11304
|
{
|
|
9592
11305
|
type: "button",
|
|
@@ -9595,7 +11308,7 @@ function ToggleDropdownRightButton({
|
|
|
9595
11308
|
className
|
|
9596
11309
|
),
|
|
9597
11310
|
...props,
|
|
9598
|
-
children: /* @__PURE__ */
|
|
11311
|
+
children: /* @__PURE__ */ jsx56(
|
|
9599
11312
|
IconContainer,
|
|
9600
11313
|
{
|
|
9601
11314
|
colorInFill: false,
|
|
@@ -9612,10 +11325,10 @@ function ToggleDropdownRightButton({
|
|
|
9612
11325
|
}
|
|
9613
11326
|
|
|
9614
11327
|
// src/ui/ToggleDropdownButton/useToggleDropdown.ts
|
|
9615
|
-
import { useState as
|
|
11328
|
+
import { useState as useState14, useCallback as useCallback5 } from "react";
|
|
9616
11329
|
|
|
9617
11330
|
// src/ui/ToggleDropdownButton/index.tsx
|
|
9618
|
-
import { jsx as
|
|
11331
|
+
import { jsx as jsx57, jsxs as jsxs39 } from "react/jsx-runtime";
|
|
9619
11332
|
var ToggleDropdownButton = ({
|
|
9620
11333
|
type,
|
|
9621
11334
|
selected,
|
|
@@ -9633,8 +11346,8 @@ var ToggleDropdownButton = ({
|
|
|
9633
11346
|
const handleLeftButtonClick = () => {
|
|
9634
11347
|
onLeftButtonClick?.();
|
|
9635
11348
|
};
|
|
9636
|
-
return /* @__PURE__ */
|
|
9637
|
-
/* @__PURE__ */
|
|
11349
|
+
return /* @__PURE__ */ jsxs39("div", { className: "gap-x-unit-1px flex items-center", children: [
|
|
11350
|
+
/* @__PURE__ */ jsx57(
|
|
9638
11351
|
ToggleDropdownLeftButton,
|
|
9639
11352
|
{
|
|
9640
11353
|
selected,
|
|
@@ -9645,8 +11358,8 @@ var ToggleDropdownButton = ({
|
|
|
9645
11358
|
children: leftButtonChildren
|
|
9646
11359
|
}
|
|
9647
11360
|
),
|
|
9648
|
-
/* @__PURE__ */
|
|
9649
|
-
/* @__PURE__ */
|
|
11361
|
+
/* @__PURE__ */ jsxs39("div", { className: "relative", children: [
|
|
11362
|
+
/* @__PURE__ */ jsx57(
|
|
9650
11363
|
ToggleDropdownRightButton,
|
|
9651
11364
|
{
|
|
9652
11365
|
ref: rightButtonRef,
|
|
@@ -9666,8 +11379,8 @@ var ToggleDropdownButton_default = ToggleDropdownButton;
|
|
|
9666
11379
|
|
|
9667
11380
|
// src/ui/ToolToggle/index.tsx
|
|
9668
11381
|
import { ChevronDown as ChevronDown3 } from "lucide-react";
|
|
9669
|
-
import { useState as
|
|
9670
|
-
import { jsx as
|
|
11382
|
+
import { useState as useState15 } from "react";
|
|
11383
|
+
import { jsx as jsx58, jsxs as jsxs40 } from "react/jsx-runtime";
|
|
9671
11384
|
var ToolToggle = ({
|
|
9672
11385
|
dropdown,
|
|
9673
11386
|
dropdownContent,
|
|
@@ -9675,41 +11388,41 @@ var ToolToggle = ({
|
|
|
9675
11388
|
className,
|
|
9676
11389
|
onClick
|
|
9677
11390
|
}) => {
|
|
9678
|
-
const [active, setActive] =
|
|
11391
|
+
const [active, setActive] = useState15(false);
|
|
9679
11392
|
const handleClick = () => {
|
|
9680
11393
|
setActive(!active);
|
|
9681
11394
|
onClick?.(active);
|
|
9682
11395
|
};
|
|
9683
|
-
return /* @__PURE__ */
|
|
9684
|
-
/* @__PURE__ */
|
|
11396
|
+
return /* @__PURE__ */ jsx58("div", { className: cn(dropdown ? "min-w-20" : "min-w-[52px]", className), children: /* @__PURE__ */ jsxs40(DropdownMenu, { children: [
|
|
11397
|
+
/* @__PURE__ */ jsx58(
|
|
9685
11398
|
DropdownMenuTrigger,
|
|
9686
11399
|
{
|
|
9687
11400
|
className: cn(
|
|
9688
11401
|
"border-border-primary-light !bg-toggle-bg-inactiveDefault hover:!bg-toggle-bg-inactiveHover flex h-full w-full items-center justify-center gap-x-2 !rounded-full border p-4 transition-all",
|
|
9689
11402
|
active && "!bg-toggle-bg-activeDefault hover:!bg-toggle-bg-activeHover"
|
|
9690
11403
|
),
|
|
9691
|
-
children: /* @__PURE__ */
|
|
11404
|
+
children: /* @__PURE__ */ jsxs40(
|
|
9692
11405
|
"div",
|
|
9693
11406
|
{
|
|
9694
11407
|
className: "flex items-center justify-center gap-x-2",
|
|
9695
11408
|
onClick: handleClick,
|
|
9696
11409
|
children: [
|
|
9697
11410
|
icon,
|
|
9698
|
-
dropdown && /* @__PURE__ */
|
|
11411
|
+
dropdown && /* @__PURE__ */ jsx58(ChevronDown3, { className: "text-icon-default size-5" })
|
|
9699
11412
|
]
|
|
9700
11413
|
}
|
|
9701
11414
|
)
|
|
9702
11415
|
}
|
|
9703
11416
|
),
|
|
9704
|
-
dropdown && /* @__PURE__ */
|
|
11417
|
+
dropdown && /* @__PURE__ */ jsx58(DropdownMenuContent, { align: "start", className: "min-w-41", children: dropdownContent })
|
|
9705
11418
|
] }) });
|
|
9706
11419
|
};
|
|
9707
11420
|
|
|
9708
11421
|
// src/ui/WrapperCard/index.tsx
|
|
9709
|
-
import { jsx as
|
|
11422
|
+
import { jsx as jsx59 } from "react/jsx-runtime";
|
|
9710
11423
|
var WrapperCard = (props) => {
|
|
9711
11424
|
const { children, className } = props;
|
|
9712
|
-
return /* @__PURE__ */
|
|
11425
|
+
return /* @__PURE__ */ jsx59(
|
|
9713
11426
|
"div",
|
|
9714
11427
|
{
|
|
9715
11428
|
className: cn(
|
|
@@ -9730,7 +11443,7 @@ import {
|
|
|
9730
11443
|
useFormContext,
|
|
9731
11444
|
useFormState
|
|
9732
11445
|
} from "react-hook-form";
|
|
9733
|
-
import { jsx as
|
|
11446
|
+
import { jsx as jsx60 } from "react/jsx-runtime";
|
|
9734
11447
|
var BaseForm = FormProvider;
|
|
9735
11448
|
var FormFieldContext = React21.createContext(
|
|
9736
11449
|
{}
|
|
@@ -9738,7 +11451,7 @@ var FormFieldContext = React21.createContext(
|
|
|
9738
11451
|
var BaseFormField = ({
|
|
9739
11452
|
...props
|
|
9740
11453
|
}) => {
|
|
9741
|
-
return /* @__PURE__ */
|
|
11454
|
+
return /* @__PURE__ */ jsx60(FormFieldContext.Provider, { value: { name: props.name }, children: /* @__PURE__ */ jsx60(Controller, { ...props }) });
|
|
9742
11455
|
};
|
|
9743
11456
|
var useFormField = () => {
|
|
9744
11457
|
const fieldContext = React21.useContext(FormFieldContext);
|
|
@@ -9764,7 +11477,7 @@ var FormItemContext = React21.createContext(
|
|
|
9764
11477
|
);
|
|
9765
11478
|
function BaseFormItem({ className, ...props }) {
|
|
9766
11479
|
const id = React21.useId();
|
|
9767
|
-
return /* @__PURE__ */
|
|
11480
|
+
return /* @__PURE__ */ jsx60(FormItemContext.Provider, { value: { id }, children: /* @__PURE__ */ jsx60(
|
|
9768
11481
|
"div",
|
|
9769
11482
|
{
|
|
9770
11483
|
"data-slot": "form-item",
|
|
@@ -9778,7 +11491,7 @@ function BaseFormLabel({
|
|
|
9778
11491
|
...props
|
|
9779
11492
|
}) {
|
|
9780
11493
|
const { error, formItemId } = useFormField();
|
|
9781
|
-
return /* @__PURE__ */
|
|
11494
|
+
return /* @__PURE__ */ jsx60(
|
|
9782
11495
|
Label2,
|
|
9783
11496
|
{
|
|
9784
11497
|
"data-slot": "form-label",
|
|
@@ -9794,7 +11507,7 @@ function BaseFormLabel({
|
|
|
9794
11507
|
}
|
|
9795
11508
|
function BaseFormControl({ ...props }) {
|
|
9796
11509
|
const { error, formItemId, formDescriptionId, formMessageId } = useFormField();
|
|
9797
|
-
return /* @__PURE__ */
|
|
11510
|
+
return /* @__PURE__ */ jsx60(
|
|
9798
11511
|
Slot7,
|
|
9799
11512
|
{
|
|
9800
11513
|
"data-slot": "form-control",
|
|
@@ -9810,7 +11523,7 @@ function BaseFormDescription({
|
|
|
9810
11523
|
...props
|
|
9811
11524
|
}) {
|
|
9812
11525
|
const { formDescriptionId } = useFormField();
|
|
9813
|
-
return /* @__PURE__ */
|
|
11526
|
+
return /* @__PURE__ */ jsx60(
|
|
9814
11527
|
"p",
|
|
9815
11528
|
{
|
|
9816
11529
|
"data-slot": "form-description",
|
|
@@ -9826,7 +11539,7 @@ function BaseFormMessage({ className, ...props }) {
|
|
|
9826
11539
|
if (!body) {
|
|
9827
11540
|
return null;
|
|
9828
11541
|
}
|
|
9829
|
-
return /* @__PURE__ */
|
|
11542
|
+
return /* @__PURE__ */ jsx60(
|
|
9830
11543
|
"p",
|
|
9831
11544
|
{
|
|
9832
11545
|
"data-slot": "form-message",
|
|
@@ -9840,7 +11553,7 @@ function BaseFormMessage({ className, ...props }) {
|
|
|
9840
11553
|
|
|
9841
11554
|
// src/ui/form/FormField.tsx
|
|
9842
11555
|
import * as React22 from "react";
|
|
9843
|
-
import { jsx as
|
|
11556
|
+
import { jsx as jsx61, jsxs as jsxs41 } from "react/jsx-runtime";
|
|
9844
11557
|
var FormField = ({
|
|
9845
11558
|
control,
|
|
9846
11559
|
field,
|
|
@@ -9848,18 +11561,18 @@ var FormField = ({
|
|
|
9848
11561
|
onBlur,
|
|
9849
11562
|
className
|
|
9850
11563
|
}) => {
|
|
9851
|
-
return /* @__PURE__ */
|
|
11564
|
+
return /* @__PURE__ */ jsx61(
|
|
9852
11565
|
BaseFormField,
|
|
9853
11566
|
{
|
|
9854
11567
|
control,
|
|
9855
11568
|
name: field.name,
|
|
9856
|
-
render: ({ field: formField }) => /* @__PURE__ */
|
|
9857
|
-
field.label && /* @__PURE__ */
|
|
11569
|
+
render: ({ field: formField }) => /* @__PURE__ */ jsxs41(BaseFormItem, { className: cn("w-full", className), children: [
|
|
11570
|
+
field.label && /* @__PURE__ */ jsxs41(BaseFormLabel, { className: "gap-1", children: [
|
|
9858
11571
|
field.label,
|
|
9859
|
-
field.required && /* @__PURE__ */
|
|
9860
|
-
field.optional && /* @__PURE__ */
|
|
11572
|
+
field.required && /* @__PURE__ */ jsx61("span", { className: "text-element-inverse-red", children: "*" }),
|
|
11573
|
+
field.optional && /* @__PURE__ */ jsx61("span", { className: "text-title-sm!", children: "(Optional)" })
|
|
9861
11574
|
] }),
|
|
9862
|
-
/* @__PURE__ */
|
|
11575
|
+
/* @__PURE__ */ jsx61(BaseFormControl, { children: React22.isValidElement(field.render) ? React22.cloneElement(
|
|
9863
11576
|
field.render,
|
|
9864
11577
|
{
|
|
9865
11578
|
...formField,
|
|
@@ -9869,7 +11582,7 @@ var FormField = ({
|
|
|
9869
11582
|
}
|
|
9870
11583
|
}
|
|
9871
11584
|
) : field.render }),
|
|
9872
|
-
isShowError && /* @__PURE__ */
|
|
11585
|
+
isShowError && /* @__PURE__ */ jsx61(BaseFormMessage, {})
|
|
9873
11586
|
] })
|
|
9874
11587
|
},
|
|
9875
11588
|
field.name
|
|
@@ -9882,7 +11595,7 @@ import {
|
|
|
9882
11595
|
Controller as Controller2,
|
|
9883
11596
|
useFormContext as useFormContext2
|
|
9884
11597
|
} from "react-hook-form";
|
|
9885
|
-
import { jsx as
|
|
11598
|
+
import { jsx as jsx62, jsxs as jsxs42 } from "react/jsx-runtime";
|
|
9886
11599
|
var FormMethodsContext = createContext4(
|
|
9887
11600
|
null
|
|
9888
11601
|
);
|
|
@@ -9893,11 +11606,11 @@ function Form({
|
|
|
9893
11606
|
className,
|
|
9894
11607
|
children
|
|
9895
11608
|
}) {
|
|
9896
|
-
return /* @__PURE__ */
|
|
11609
|
+
return /* @__PURE__ */ jsx62(
|
|
9897
11610
|
FormMethodsContext.Provider,
|
|
9898
11611
|
{
|
|
9899
11612
|
value: formMethods,
|
|
9900
|
-
children: /* @__PURE__ */
|
|
11613
|
+
children: /* @__PURE__ */ jsx62(BaseForm, { ...formMethods, children: /* @__PURE__ */ jsx62(
|
|
9901
11614
|
"form",
|
|
9902
11615
|
{
|
|
9903
11616
|
id,
|
|
@@ -9918,7 +11631,7 @@ Form.InputField = function InputField({
|
|
|
9918
11631
|
...props
|
|
9919
11632
|
}) {
|
|
9920
11633
|
const { control } = useFormContext2();
|
|
9921
|
-
return /* @__PURE__ */
|
|
11634
|
+
return /* @__PURE__ */ jsx62(
|
|
9922
11635
|
FormField,
|
|
9923
11636
|
{
|
|
9924
11637
|
className: "w-full",
|
|
@@ -9929,7 +11642,7 @@ Form.InputField = function InputField({
|
|
|
9929
11642
|
name,
|
|
9930
11643
|
label,
|
|
9931
11644
|
required,
|
|
9932
|
-
render: /* @__PURE__ */
|
|
11645
|
+
render: /* @__PURE__ */ jsx62(Input, { ...props, inputClassName: props.inputClassName })
|
|
9933
11646
|
}
|
|
9934
11647
|
}
|
|
9935
11648
|
);
|
|
@@ -9940,7 +11653,7 @@ Form.PasswordField = function PasswordField({
|
|
|
9940
11653
|
...props
|
|
9941
11654
|
}) {
|
|
9942
11655
|
const { control } = useFormContext2();
|
|
9943
|
-
return /* @__PURE__ */
|
|
11656
|
+
return /* @__PURE__ */ jsx62(
|
|
9944
11657
|
FormField,
|
|
9945
11658
|
{
|
|
9946
11659
|
className: "w-full",
|
|
@@ -9948,7 +11661,7 @@ Form.PasswordField = function PasswordField({
|
|
|
9948
11661
|
field: {
|
|
9949
11662
|
name,
|
|
9950
11663
|
label,
|
|
9951
|
-
render: /* @__PURE__ */
|
|
11664
|
+
render: /* @__PURE__ */ jsx62(PasswordInput, { ...props })
|
|
9952
11665
|
}
|
|
9953
11666
|
}
|
|
9954
11667
|
);
|
|
@@ -9960,7 +11673,7 @@ Form.SelectInputField = function SelectInputField({
|
|
|
9960
11673
|
...props
|
|
9961
11674
|
}) {
|
|
9962
11675
|
const { control } = useFormContext2();
|
|
9963
|
-
return /* @__PURE__ */
|
|
11676
|
+
return /* @__PURE__ */ jsx62(
|
|
9964
11677
|
FormField,
|
|
9965
11678
|
{
|
|
9966
11679
|
control,
|
|
@@ -9968,7 +11681,7 @@ Form.SelectInputField = function SelectInputField({
|
|
|
9968
11681
|
name,
|
|
9969
11682
|
required,
|
|
9970
11683
|
label,
|
|
9971
|
-
render: /* @__PURE__ */
|
|
11684
|
+
render: /* @__PURE__ */ jsx62(SelectInput, { ...props })
|
|
9972
11685
|
}
|
|
9973
11686
|
}
|
|
9974
11687
|
);
|
|
@@ -9980,14 +11693,14 @@ Form.MultiSelectField = function MultiSelectField({
|
|
|
9980
11693
|
}) {
|
|
9981
11694
|
const { control, watch, setValue } = useFormContext2();
|
|
9982
11695
|
const selectedValues = watch(name) || [];
|
|
9983
|
-
return /* @__PURE__ */
|
|
11696
|
+
return /* @__PURE__ */ jsx62(
|
|
9984
11697
|
FormField,
|
|
9985
11698
|
{
|
|
9986
11699
|
control,
|
|
9987
11700
|
field: {
|
|
9988
11701
|
name,
|
|
9989
11702
|
label,
|
|
9990
|
-
render: /* @__PURE__ */
|
|
11703
|
+
render: /* @__PURE__ */ jsx62(
|
|
9991
11704
|
MultiSelect,
|
|
9992
11705
|
{
|
|
9993
11706
|
...props,
|
|
@@ -10006,7 +11719,7 @@ Form.TextareaField = function TextareaField({
|
|
|
10006
11719
|
...props
|
|
10007
11720
|
}) {
|
|
10008
11721
|
const { control } = useFormContext2();
|
|
10009
|
-
return /* @__PURE__ */
|
|
11722
|
+
return /* @__PURE__ */ jsx62(
|
|
10010
11723
|
FormField,
|
|
10011
11724
|
{
|
|
10012
11725
|
control,
|
|
@@ -10014,7 +11727,7 @@ Form.TextareaField = function TextareaField({
|
|
|
10014
11727
|
name,
|
|
10015
11728
|
label,
|
|
10016
11729
|
optional,
|
|
10017
|
-
render: /* @__PURE__ */
|
|
11730
|
+
render: /* @__PURE__ */ jsx62(TextAreaInput_default, { ...props })
|
|
10018
11731
|
}
|
|
10019
11732
|
}
|
|
10020
11733
|
);
|
|
@@ -10032,14 +11745,14 @@ Form.FileUploadField = function FileUploadFieldComponent({
|
|
|
10032
11745
|
const { control, formState } = useFormContext2();
|
|
10033
11746
|
const fieldError = formState.errors[name];
|
|
10034
11747
|
const hasValidationError = !!fieldError;
|
|
10035
|
-
return /* @__PURE__ */
|
|
11748
|
+
return /* @__PURE__ */ jsx62(
|
|
10036
11749
|
Controller2,
|
|
10037
11750
|
{
|
|
10038
11751
|
control,
|
|
10039
11752
|
name,
|
|
10040
|
-
render: ({ field: formField }) => /* @__PURE__ */
|
|
10041
|
-
label && /* @__PURE__ */
|
|
10042
|
-
/* @__PURE__ */
|
|
11753
|
+
render: ({ field: formField }) => /* @__PURE__ */ jsxs42("div", { className: "space-y-1", children: [
|
|
11754
|
+
label && /* @__PURE__ */ jsx62("label", { htmlFor: name, className: "font-medium", children: label }),
|
|
11755
|
+
/* @__PURE__ */ jsx62(
|
|
10043
11756
|
FileUploadField,
|
|
10044
11757
|
{
|
|
10045
11758
|
field: { name, isMultiple, maxFiles, children },
|
|
@@ -10070,7 +11783,7 @@ Form.DateInputField = function DateInputField({
|
|
|
10070
11783
|
}) {
|
|
10071
11784
|
const { control, watch, setValue } = useFormContext2();
|
|
10072
11785
|
const value = watch(name);
|
|
10073
|
-
return /* @__PURE__ */
|
|
11786
|
+
return /* @__PURE__ */ jsx62(
|
|
10074
11787
|
FormField,
|
|
10075
11788
|
{
|
|
10076
11789
|
control,
|
|
@@ -10078,7 +11791,7 @@ Form.DateInputField = function DateInputField({
|
|
|
10078
11791
|
name,
|
|
10079
11792
|
label,
|
|
10080
11793
|
required,
|
|
10081
|
-
render: /* @__PURE__ */
|
|
11794
|
+
render: /* @__PURE__ */ jsx62(
|
|
10082
11795
|
DatePickerInput,
|
|
10083
11796
|
{
|
|
10084
11797
|
...props,
|
|
@@ -10097,14 +11810,14 @@ Form.TimeInputField = function TimeInputField({
|
|
|
10097
11810
|
...props
|
|
10098
11811
|
}) {
|
|
10099
11812
|
const { control, setValue } = useFormContext2();
|
|
10100
|
-
return /* @__PURE__ */
|
|
11813
|
+
return /* @__PURE__ */ jsx62(
|
|
10101
11814
|
FormField,
|
|
10102
11815
|
{
|
|
10103
11816
|
control,
|
|
10104
11817
|
field: {
|
|
10105
11818
|
name,
|
|
10106
11819
|
label,
|
|
10107
|
-
render: /* @__PURE__ */
|
|
11820
|
+
render: /* @__PURE__ */ jsx62(
|
|
10108
11821
|
TimePicker,
|
|
10109
11822
|
{
|
|
10110
11823
|
onValueChange: (value) => {
|
|
@@ -10123,13 +11836,13 @@ Form.CheckboxField = function CheckboxField({
|
|
|
10123
11836
|
...props
|
|
10124
11837
|
}) {
|
|
10125
11838
|
const { control } = useFormContext2();
|
|
10126
|
-
return /* @__PURE__ */
|
|
11839
|
+
return /* @__PURE__ */ jsx62(
|
|
10127
11840
|
FormField,
|
|
10128
11841
|
{
|
|
10129
11842
|
control,
|
|
10130
11843
|
field: {
|
|
10131
11844
|
name,
|
|
10132
|
-
render: /* @__PURE__ */
|
|
11845
|
+
render: /* @__PURE__ */ jsx62(Checkbox, { value: name, label, ...props })
|
|
10133
11846
|
}
|
|
10134
11847
|
}
|
|
10135
11848
|
);
|
|
@@ -10139,12 +11852,12 @@ Form.OTPInputField = function OTPInputField({
|
|
|
10139
11852
|
...props
|
|
10140
11853
|
}) {
|
|
10141
11854
|
const { control } = useFormContext2();
|
|
10142
|
-
return /* @__PURE__ */
|
|
11855
|
+
return /* @__PURE__ */ jsx62(
|
|
10143
11856
|
FormField,
|
|
10144
11857
|
{
|
|
10145
11858
|
className: "w-full",
|
|
10146
11859
|
control,
|
|
10147
|
-
field: { name, render: /* @__PURE__ */
|
|
11860
|
+
field: { name, render: /* @__PURE__ */ jsx62(OTPInput, { ...props }) }
|
|
10148
11861
|
}
|
|
10149
11862
|
);
|
|
10150
11863
|
};
|
|
@@ -10155,14 +11868,14 @@ Form.RadioField = function RadioField({
|
|
|
10155
11868
|
}) {
|
|
10156
11869
|
const { control } = useFormContext2();
|
|
10157
11870
|
const { setValue } = useFormContext2();
|
|
10158
|
-
return /* @__PURE__ */
|
|
11871
|
+
return /* @__PURE__ */ jsx62(
|
|
10159
11872
|
FormField,
|
|
10160
11873
|
{
|
|
10161
11874
|
control,
|
|
10162
11875
|
field: {
|
|
10163
11876
|
name,
|
|
10164
11877
|
label,
|
|
10165
|
-
render: /* @__PURE__ */
|
|
11878
|
+
render: /* @__PURE__ */ jsx62(
|
|
10166
11879
|
Radio,
|
|
10167
11880
|
{
|
|
10168
11881
|
...props,
|
|
@@ -10179,13 +11892,13 @@ Form.ComboboxField = function ComboboxField({
|
|
|
10179
11892
|
}) {
|
|
10180
11893
|
const { control, setValue, watch } = useFormContext2();
|
|
10181
11894
|
const value = watch(name);
|
|
10182
|
-
return /* @__PURE__ */
|
|
11895
|
+
return /* @__PURE__ */ jsx62(
|
|
10183
11896
|
FormField,
|
|
10184
11897
|
{
|
|
10185
11898
|
control,
|
|
10186
11899
|
field: {
|
|
10187
11900
|
name,
|
|
10188
|
-
render: /* @__PURE__ */
|
|
11901
|
+
render: /* @__PURE__ */ jsx62(
|
|
10189
11902
|
Combobox,
|
|
10190
11903
|
{
|
|
10191
11904
|
...props,
|
|
@@ -10207,7 +11920,7 @@ Form.SwitchField = function SwitchField({
|
|
|
10207
11920
|
}) {
|
|
10208
11921
|
const { control, setValue, watch } = useFormContext2();
|
|
10209
11922
|
const value = watch(name);
|
|
10210
|
-
return /* @__PURE__ */
|
|
11923
|
+
return /* @__PURE__ */ jsx62(
|
|
10211
11924
|
FormField,
|
|
10212
11925
|
{
|
|
10213
11926
|
control,
|
|
@@ -10215,9 +11928,9 @@ Form.SwitchField = function SwitchField({
|
|
|
10215
11928
|
field: {
|
|
10216
11929
|
name,
|
|
10217
11930
|
label,
|
|
10218
|
-
render: /* @__PURE__ */
|
|
10219
|
-
prefix && /* @__PURE__ */
|
|
10220
|
-
/* @__PURE__ */
|
|
11931
|
+
render: /* @__PURE__ */ jsxs42("div", { className: "flex items-center", children: [
|
|
11932
|
+
prefix && /* @__PURE__ */ jsx62("span", { className: "mr-2", children: prefix }),
|
|
11933
|
+
/* @__PURE__ */ jsx62(
|
|
10221
11934
|
Switch,
|
|
10222
11935
|
{
|
|
10223
11936
|
...props,
|
|
@@ -10225,7 +11938,7 @@ Form.SwitchField = function SwitchField({
|
|
|
10225
11938
|
onCheckedChange: (checked) => setValue(name, checked)
|
|
10226
11939
|
}
|
|
10227
11940
|
),
|
|
10228
|
-
suffix && /* @__PURE__ */
|
|
11941
|
+
suffix && /* @__PURE__ */ jsx62("span", { className: "ml-2", children: suffix })
|
|
10229
11942
|
] })
|
|
10230
11943
|
}
|
|
10231
11944
|
}
|
|
@@ -11238,6 +12951,7 @@ export {
|
|
|
11238
12951
|
FileUploadField,
|
|
11239
12952
|
Form,
|
|
11240
12953
|
FormField,
|
|
12954
|
+
GoogleMapView,
|
|
11241
12955
|
GradientContainer,
|
|
11242
12956
|
Grid,
|
|
11243
12957
|
IconButton,
|