@dimasbaguspm/versaur 0.0.10 → 0.0.11
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/{calendar-DwRERSxq.js → js/calendar-De5dCVnE.js} +149 -137
- package/dist/{enforce-subpath-import.js → js/enforce-subpath-import.js} +29 -13
- package/dist/{feedbacks → js/feedbacks}/index.js +1 -1
- package/dist/{form-layout-COQbtyW5.js → js/form-layout-BRqZZe8s.js} +55 -55
- package/dist/{forms → js/forms}/index.js +1 -1
- package/dist/{index.js → js/index.js} +7 -7
- package/dist/{layouts → js/layouts}/index.js +1 -1
- package/dist/{menu--hEHXVZf.js → js/menu-Du409VIG.js} +15 -15
- package/dist/js/navigation/index.js +5 -0
- package/dist/{overlays → js/overlays}/index.js +1 -1
- package/dist/{primitive → js/primitive}/index.js +2 -2
- package/dist/{skeleton-DwqjRsF-.js → js/skeleton-BNZyaRjo.js} +19 -19
- package/dist/{styles.css → js/styles.css} +62 -37
- package/dist/{switch-input-DRNFMsqC.js → js/switch-input-B-pwBWbi.js} +266 -262
- package/dist/{tabs-KyFmo5cA.js → js/tabs-BbOkYchB.js} +53 -53
- package/dist/{tile-BinjKW_i.js → js/tile-6SeBYc08.js} +162 -162
- package/dist/types/primitive/anchor/anchor.d.ts +7 -0
- package/dist/types/primitive/anchor/index.d.ts +2 -0
- package/dist/types/primitive/anchor/types.d.ts +19 -0
- package/dist/{primitive → types/primitive}/icon/types.d.ts +1 -1
- package/dist/{primitive → types/primitive}/text/types.d.ts +1 -1
- package/package.json +17 -17
- package/dist/navigation/index.js +0 -5
- /package/dist/{drawer-Cn7sreJG.js → js/drawer-Cn7sreJG.js} +0 -0
- /package/dist/{index-DOdDlCoL.js → js/index-DOdDlCoL.js} +0 -0
- /package/dist/{feedbacks → types/feedbacks}/index.d.ts +0 -0
- /package/dist/{feedbacks → types/feedbacks}/loading-indicator/index.d.ts +0 -0
- /package/dist/{feedbacks → types/feedbacks}/loading-indicator/loading-indicator.atoms.d.ts +0 -0
- /package/dist/{feedbacks → types/feedbacks}/loading-indicator/loading-indicator.d.ts +0 -0
- /package/dist/{feedbacks → types/feedbacks}/loading-indicator/types.d.ts +0 -0
- /package/dist/{feedbacks → types/feedbacks}/progress-indicator/index.d.ts +0 -0
- /package/dist/{feedbacks → types/feedbacks}/progress-indicator/progress-indicator.d.ts +0 -0
- /package/dist/{feedbacks → types/feedbacks}/progress-indicator/types.d.ts +0 -0
- /package/dist/{feedbacks → types/feedbacks}/skeleton/index.d.ts +0 -0
- /package/dist/{feedbacks → types/feedbacks}/skeleton/skeleton.d.ts +0 -0
- /package/dist/{feedbacks → types/feedbacks}/skeleton/types.d.ts +0 -0
- /package/dist/{forms → types/forms}/calculator-input/calculator-input.atoms.d.ts +0 -0
- /package/dist/{forms → types/forms}/calculator-input/calculator-input.d.ts +0 -0
- /package/dist/{forms → types/forms}/calculator-input/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/calculator-input/types.d.ts +0 -0
- /package/dist/{forms → types/forms}/checkbox-input/checkbox-input.atoms.d.ts +0 -0
- /package/dist/{forms → types/forms}/checkbox-input/checkbox-input.d.ts +0 -0
- /package/dist/{forms → types/forms}/checkbox-input/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/checkbox-input/types.d.ts +0 -0
- /package/dist/{forms → types/forms}/chip-input/chip-input.atoms.d.ts +0 -0
- /package/dist/{forms → types/forms}/chip-input/chip-input.d.ts +0 -0
- /package/dist/{forms → types/forms}/chip-input/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/chip-input/types.d.ts +0 -0
- /package/dist/{forms → types/forms}/date-single-picker-input/date-single-picker-input.atoms.d.ts +0 -0
- /package/dist/{forms → types/forms}/date-single-picker-input/date-single-picker-input.d.ts +0 -0
- /package/dist/{forms → types/forms}/date-single-picker-input/date-single-picker-input.docked.d.ts +0 -0
- /package/dist/{forms → types/forms}/date-single-picker-input/date-single-picker-input.modal.d.ts +0 -0
- /package/dist/{forms → types/forms}/date-single-picker-input/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/date-single-picker-input/types.d.ts +0 -0
- /package/dist/{forms → types/forms}/date-single-picker-input/use-date-single-picker.d.ts +0 -0
- /package/dist/{forms → types/forms}/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/radio-input/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/radio-input/radio-input.atoms.d.ts +0 -0
- /package/dist/{forms → types/forms}/radio-input/radio-input.d.ts +0 -0
- /package/dist/{forms → types/forms}/radio-input/types.d.ts +0 -0
- /package/dist/{forms → types/forms}/segment-multiple-input/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/segment-multiple-input/segment-multiple-input.atoms.d.ts +0 -0
- /package/dist/{forms → types/forms}/segment-multiple-input/segment-multiple-input.d.ts +0 -0
- /package/dist/{forms → types/forms}/segment-multiple-input/types.d.ts +0 -0
- /package/dist/{forms → types/forms}/segment-single-input/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/segment-single-input/segment-single-input.atoms.d.ts +0 -0
- /package/dist/{forms → types/forms}/segment-single-input/segment-single-input.d.ts +0 -0
- /package/dist/{forms → types/forms}/segment-single-input/types.d.ts +0 -0
- /package/dist/{forms → types/forms}/select-input/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/select-input/select-input.d.ts +0 -0
- /package/dist/{forms → types/forms}/select-input/types.d.ts +0 -0
- /package/dist/{forms → types/forms}/switch-input/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/switch-input/switch-input.atoms.d.ts +0 -0
- /package/dist/{forms → types/forms}/switch-input/switch-input.d.ts +0 -0
- /package/dist/{forms → types/forms}/switch-input/types.d.ts +0 -0
- /package/dist/{forms → types/forms}/text-input/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/text-input/text-input.d.ts +0 -0
- /package/dist/{forms → types/forms}/text-input/types.d.ts +0 -0
- /package/dist/{forms → types/forms}/textarea-input/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/textarea-input/textarea-input.d.ts +0 -0
- /package/dist/{forms → types/forms}/textarea-input/types.d.ts +0 -0
- /package/dist/{forms → types/forms}/time-picker-input/index.d.ts +0 -0
- /package/dist/{forms → types/forms}/time-picker-input/time-picker-input.atoms.d.ts +0 -0
- /package/dist/{forms → types/forms}/time-picker-input/time-picker-input.d.ts +0 -0
- /package/dist/{forms → types/forms}/time-picker-input/types.d.ts +0 -0
- /package/dist/{index.d.ts → types/index.d.ts} +0 -0
- /package/dist/{layouts → types/layouts}/app-bar/app-bar.atoms.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/app-bar/app-bar.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/app-bar/index.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/app-bar/types.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/bottom-bar/bottom-bar.atoms.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/bottom-bar/bottom-bar.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/bottom-bar/index.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/bottom-bar/types.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/form-layout/form-layout.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/form-layout/index.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/form-layout/types.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/index.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/page-layout/index.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/page-layout/page-layout.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/page-layout/types.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/top-bar/index.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/top-bar/top-bar.atoms.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/top-bar/top-bar.d.ts +0 -0
- /package/dist/{layouts → types/layouts}/top-bar/types.d.ts +0 -0
- /package/dist/{navigation → types/navigation}/breadcrumbs/breadcrumbs.atoms.d.ts +0 -0
- /package/dist/{navigation → types/navigation}/breadcrumbs/breadcrumbs.d.ts +0 -0
- /package/dist/{navigation → types/navigation}/breadcrumbs/index.d.ts +0 -0
- /package/dist/{navigation → types/navigation}/breadcrumbs/types.d.ts +0 -0
- /package/dist/{navigation → types/navigation}/index.d.ts +0 -0
- /package/dist/{navigation → types/navigation}/tabs/index.d.ts +0 -0
- /package/dist/{navigation → types/navigation}/tabs/tabs.atoms.d.ts +0 -0
- /package/dist/{navigation → types/navigation}/tabs/tabs.d.ts +0 -0
- /package/dist/{navigation → types/navigation}/tabs/types.d.ts +0 -0
- /package/dist/{navigation → types/navigation}/tabs/use-tab-indicator.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/drawer/drawer.atoms.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/drawer/drawer.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/drawer/index.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/drawer/types.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/index.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/menu/index.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/menu/menu.atoms.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/menu/menu.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/menu/types.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/menu/use-menu.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/modal/index.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/modal/modal.atoms.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/modal/modal.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/modal/types.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/modal/use-escape-close.d.ts +0 -0
- /package/dist/{overlays → types/overlays}/modal/use-focus-trap.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/alert/alert.atoms.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/alert/alert.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/alert/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/alert/types.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/avatar/avatar.atoms.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/avatar/avatar.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/avatar/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/avatar/types.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/badge/badge.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/badge/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/badge/types.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/brand/brand.atoms.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/brand/brand.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/brand/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/brand/types.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/button/button.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/button/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/button/types.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/button-float/button-float.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/button-float/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/button-float/types.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/button-float/use-floating-position.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/button-icon/button-icon.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/button-icon/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/button-icon/types.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/calculator/calculator.atoms.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/calculator/calculator.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/calculator/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/calculator/types.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/calculator/use-calculator.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/calendar/calendar.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/calendar/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/calendar/types.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/icon/icon.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/icon/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/snackbar/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/snackbar/snackbar.atoms.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/snackbar/snackbar.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/snackbar/types.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/table/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/table/table.atoms.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/table/table.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/table/types.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/text/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/text/text.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/tile/index.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/tile/tile.d.ts +0 -0
- /package/dist/{primitive → types/primitive}/tile/types.d.ts +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { c as cva, j as jsxRuntimeExports, a as cn } from "./index-DOdDlCoL.js";
|
|
2
2
|
import React__default, { useState, useRef, createContext, useContext, useEffect, useId, useCallback } from "react";
|
|
3
|
-
import { I as Icon, C as Calculator, B as Button, b as Calendar, T as Text } from "./calendar-
|
|
4
|
-
import { a as Modal, M as Menu } from "./menu
|
|
3
|
+
import { I as Icon, C as Calculator, B as Button, b as Calendar, T as Text } from "./calendar-De5dCVnE.js";
|
|
4
|
+
import { a as Modal, M as Menu } from "./menu-Du409VIG.js";
|
|
5
5
|
import { CalculatorIcon, Check, Clock } from "lucide-react";
|
|
6
6
|
const textInputVariants = cva(
|
|
7
7
|
"block w-full rounded-md border bg-white transition-colors focus:outline-none focus:ring-2 focus:ring-offset-2 disabled:opacity-50 disabled:pointer-events-none disabled:bg-gray-50",
|
|
@@ -9,16 +9,16 @@ const textInputVariants = cva(
|
|
|
9
9
|
variants: {
|
|
10
10
|
variant: {
|
|
11
11
|
// Core variants using Versaur color system
|
|
12
|
-
primary: "border-
|
|
13
|
-
secondary: "border-
|
|
14
|
-
tertiary: "border-
|
|
15
|
-
ghost: "border-
|
|
12
|
+
primary: "border-primary/30 text-foreground focus:border-primary focus:ring-primary/20",
|
|
13
|
+
secondary: "border-secondary/30 text-foreground focus:border-secondary focus:ring-secondary/20",
|
|
14
|
+
tertiary: "border-tertiary/30 text-foreground focus:border-tertiary focus:ring-tertiary/20",
|
|
15
|
+
ghost: "border-ghost/30 text-foreground focus:border-ghost focus:ring-ghost/20",
|
|
16
16
|
neutral: "border-gray-300 text-foreground focus:border-gray-400 focus:ring-gray-400/20",
|
|
17
17
|
// Outline variants
|
|
18
|
-
"primary-outline": "border-
|
|
19
|
-
"secondary-outline": "border-
|
|
20
|
-
"tertiary-outline": "border-
|
|
21
|
-
"ghost-outline": "border-
|
|
18
|
+
"primary-outline": "border-primary text-foreground focus:border-primary focus:ring-primary/20",
|
|
19
|
+
"secondary-outline": "border-secondary text-foreground focus:border-secondary focus:ring-secondary/20",
|
|
20
|
+
"tertiary-outline": "border-tertiary text-foreground focus:border-tertiary focus:ring-tertiary/20",
|
|
21
|
+
"ghost-outline": "border-ghost text-foreground focus:border-ghost focus:ring-ghost/20",
|
|
22
22
|
"neutral-outline": "border-gray-400 text-foreground focus:border-gray-500 focus:ring-gray-500/20",
|
|
23
23
|
// Semantic variants
|
|
24
24
|
success: "border-success/30 text-foreground focus:border-success focus:ring-success/20",
|
|
@@ -225,16 +225,16 @@ const DEFAULT_HEADER = "Enter Amount", CalculatorInput = ({
|
|
|
225
225
|
variants: {
|
|
226
226
|
variant: {
|
|
227
227
|
// Core variants using Versaur color system
|
|
228
|
-
primary: "border-
|
|
229
|
-
secondary: "border-
|
|
230
|
-
tertiary: "border-
|
|
231
|
-
ghost: "border-
|
|
228
|
+
primary: "border-primary/40 checked:bg-primary checked:border-primary focus:ring-primary/20",
|
|
229
|
+
secondary: "border-secondary/40 checked:bg-secondary checked:border-secondary focus:ring-secondary/20",
|
|
230
|
+
tertiary: "border-tertiary/40 checked:bg-tertiary checked:border-tertiary focus:ring-tertiary/20",
|
|
231
|
+
ghost: "border-ghost/40 checked:bg-ghost checked:border-ghost focus:ring-ghost/20",
|
|
232
232
|
neutral: "border-gray-300 checked:bg-gray-500 checked:border-gray-500 focus:ring-gray-400/20",
|
|
233
233
|
// Outline variants
|
|
234
|
-
"primary-outline": "border-
|
|
235
|
-
"secondary-outline": "border-
|
|
236
|
-
"tertiary-outline": "border-
|
|
237
|
-
"ghost-outline": "border-
|
|
234
|
+
"primary-outline": "border-primary checked:bg-white checked:border-primary focus:ring-primary/20",
|
|
235
|
+
"secondary-outline": "border-secondary checked:bg-white checked:border-secondary focus:ring-secondary/20",
|
|
236
|
+
"tertiary-outline": "border-tertiary checked:bg-white checked:border-tertiary focus:ring-tertiary/20",
|
|
237
|
+
"ghost-outline": "border-ghost checked:bg-white checked:border-ghost focus:ring-ghost/20",
|
|
238
238
|
"neutral-outline": "border-gray-400 checked:bg-white checked:border-gray-400 focus:ring-gray-500/20",
|
|
239
239
|
// Semantic variants
|
|
240
240
|
success: "border-success/40 checked:bg-success checked:border-success focus:ring-success/20",
|
|
@@ -377,71 +377,71 @@ const CheckboxInput = Object.assign(CheckboxInputRoot, {
|
|
|
377
377
|
throw new Error("useChipInputContext must be used within ChipInputContext");
|
|
378
378
|
return e;
|
|
379
379
|
}, chipOptionVariants = cva(
|
|
380
|
-
"inline-flex items-center px-2 py-1 text-xs bg-
|
|
380
|
+
"inline-flex items-center px-2 py-1 text-xs bg-white rounded-full font-regular font-sm transition-colors duration-200 cursor-pointer border border-border",
|
|
381
381
|
{
|
|
382
382
|
variants: {
|
|
383
383
|
variant: {
|
|
384
384
|
primary: [
|
|
385
|
-
"hover:bg-
|
|
386
|
-
"hover:border-
|
|
387
|
-
"focus:border-
|
|
388
|
-
"data-[selected=true]:bg-
|
|
389
|
-
"data-[selected=true]:border-
|
|
385
|
+
"hover:bg-primary-soft",
|
|
386
|
+
"hover:border-primary-light",
|
|
387
|
+
"focus:border-primary-light",
|
|
388
|
+
"data-[selected=true]:bg-primary-soft",
|
|
389
|
+
"data-[selected=true]:border-primary"
|
|
390
390
|
].join(" "),
|
|
391
391
|
secondary: [
|
|
392
|
-
"hover:bg-
|
|
393
|
-
"hover:border-
|
|
394
|
-
"focus:border-
|
|
395
|
-
"data-[selected=true]:bg-
|
|
396
|
-
"data-[selected=true]:border-
|
|
392
|
+
"hover:bg-secondary-soft",
|
|
393
|
+
"hover:border-secondary-light",
|
|
394
|
+
"focus:border-secondary-light",
|
|
395
|
+
"data-[selected=true]:bg-secondary-soft",
|
|
396
|
+
"data-[selected=true]:border-secondary"
|
|
397
397
|
].join(" "),
|
|
398
398
|
tertiary: [
|
|
399
|
-
"hover:bg-
|
|
400
|
-
"hover:border-
|
|
401
|
-
"focus:border-
|
|
402
|
-
"data-[selected=true]:bg-
|
|
403
|
-
"data-[selected=true]:border-
|
|
399
|
+
"hover:bg-tertiary-soft",
|
|
400
|
+
"hover:border-tertiary-light",
|
|
401
|
+
"focus:border-tertiary-light",
|
|
402
|
+
"data-[selected=true]:bg-tertiary-soft",
|
|
403
|
+
"data-[selected=true]:border-tertiary"
|
|
404
404
|
].join(" "),
|
|
405
405
|
ghost: [
|
|
406
|
-
"hover:bg-
|
|
407
|
-
"hover:border-
|
|
408
|
-
"focus:border-
|
|
409
|
-
"data-[selected=true]:bg-
|
|
410
|
-
"data-[selected=true]:border-
|
|
406
|
+
"hover:bg-ghost-soft",
|
|
407
|
+
"hover:border-ghost-light",
|
|
408
|
+
"focus:border-ghost-light",
|
|
409
|
+
"data-[selected=true]:bg-ghost-soft",
|
|
410
|
+
"data-[selected=true]:border-ghost"
|
|
411
411
|
].join(" "),
|
|
412
412
|
neutral: [
|
|
413
|
-
"hover:bg-gray
|
|
414
|
-
"hover:border-gray
|
|
415
|
-
"focus:border-gray
|
|
416
|
-
"data-[selected=true]:bg-gray
|
|
413
|
+
"hover:bg-gray-soft",
|
|
414
|
+
"hover:border-gray-light",
|
|
415
|
+
"focus:border-gray-light",
|
|
416
|
+
"data-[selected=true]:bg-gray-soft",
|
|
417
417
|
"data-[selected=true]:border-gray"
|
|
418
418
|
].join(" "),
|
|
419
419
|
success: [
|
|
420
|
-
"hover:bg-success
|
|
421
|
-
"hover:border-success
|
|
422
|
-
"focus:border-success
|
|
423
|
-
"data-[selected=true]:bg-success
|
|
420
|
+
"hover:bg-success-soft",
|
|
421
|
+
"hover:border-success-light",
|
|
422
|
+
"focus:border-success-light",
|
|
423
|
+
"data-[selected=true]:bg-success-soft",
|
|
424
424
|
"data-[selected=true]:border-success"
|
|
425
425
|
].join(" "),
|
|
426
426
|
info: [
|
|
427
|
-
"hover:bg-info
|
|
428
|
-
"hover:border-info
|
|
429
|
-
"focus:border-info
|
|
430
|
-
"data-[selected=true]:bg-info
|
|
427
|
+
"hover:bg-info-soft",
|
|
428
|
+
"hover:border-info-light",
|
|
429
|
+
"focus:border-info-light",
|
|
430
|
+
"data-[selected=true]:bg-info-soft",
|
|
431
431
|
"data-[selected=true]:border-info"
|
|
432
432
|
].join(" "),
|
|
433
433
|
warning: [
|
|
434
|
-
"hover:bg-warning
|
|
435
|
-
"hover:border-warning
|
|
436
|
-
"focus:border-warning
|
|
437
|
-
"data-[selected=true]:bg-warning
|
|
434
|
+
"hover:bg-warning-soft",
|
|
435
|
+
"hover:border-warning-light",
|
|
436
|
+
"focus:border-warning-light",
|
|
437
|
+
"data-[selected=true]:bg-warning-soft",
|
|
438
438
|
"data-[selected=true]:border-warning"
|
|
439
439
|
].join(" "),
|
|
440
440
|
danger: [
|
|
441
|
-
"hover:bg-danger
|
|
442
|
-
"hover:border-danger
|
|
443
|
-
"focus:border-danger
|
|
444
|
-
"data-[selected=true]:bg-danger
|
|
441
|
+
"hover:bg-danger-soft",
|
|
442
|
+
"hover:border-danger-light",
|
|
443
|
+
"focus:border-danger-light",
|
|
444
|
+
"data-[selected=true]:bg-danger-soft",
|
|
445
445
|
"data-[selected=true]:border-danger"
|
|
446
446
|
].join(" ")
|
|
447
447
|
},
|
|
@@ -456,13 +456,13 @@ const CheckboxInput = Object.assign(CheckboxInputRoot, {
|
|
|
456
456
|
}
|
|
457
457
|
}
|
|
458
458
|
), ChipOption = React__default.forwardRef(({ children: e, className: t, disabled: s, id: a, value: n, ...c }, l) => {
|
|
459
|
-
const o = useChipInputContext(), r = React__default.useId(), u = a || r, x = s || o.disabled, i = o.error ? "danger" : o.variant || "primary", d = o.value?.includes(n) ?? !1, g = (
|
|
459
|
+
const o = useChipInputContext(), r = React__default.useId(), u = a || r, x = s || o.disabled, i = o.error ? "danger" : o.variant || "primary", d = o.value?.includes(n) ?? !1, g = (m) => {
|
|
460
460
|
if (!x) {
|
|
461
|
-
const
|
|
462
|
-
let
|
|
463
|
-
d ?
|
|
461
|
+
const p = o.value || [];
|
|
462
|
+
let h;
|
|
463
|
+
d ? h = p.filter((b) => b !== n) : h = [...p, n], o.onChange?.(h);
|
|
464
464
|
}
|
|
465
|
-
c.onChange?.(
|
|
465
|
+
c.onChange?.(m);
|
|
466
466
|
};
|
|
467
467
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
468
468
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -507,7 +507,7 @@ const CheckboxInput = Object.assign(CheckboxInputRoot, {
|
|
|
507
507
|
Check,
|
|
508
508
|
{
|
|
509
509
|
size: 16,
|
|
510
|
-
className: i === "primary" ? "text-
|
|
510
|
+
className: i === "primary" ? "text-primary" : i === "secondary" ? "text-secondary" : i === "tertiary" ? "text-tertiary" : i === "ghost" ? "text-ghost" : i === "success" ? "text-success" : i === "info" ? "text-info" : i === "warning" ? "text-warning" : i === "danger" ? "text-danger" : "text-primary"
|
|
511
511
|
}
|
|
512
512
|
)
|
|
513
513
|
}
|
|
@@ -716,25 +716,25 @@ const DateSinglePickerInput = React__default.forwardRef(
|
|
|
716
716
|
"DateSinglePickerInput is a controlled component: value and onChange are required."
|
|
717
717
|
);
|
|
718
718
|
const {
|
|
719
|
-
open:
|
|
720
|
-
setOpen:
|
|
721
|
-
inputId:
|
|
722
|
-
buttonRef:
|
|
723
|
-
handleKeyDown:
|
|
719
|
+
open: m,
|
|
720
|
+
setOpen: p,
|
|
721
|
+
inputId: h,
|
|
722
|
+
buttonRef: b,
|
|
723
|
+
handleKeyDown: y,
|
|
724
724
|
handleMenuClose: j
|
|
725
|
-
} = useDateSinglePicker({ id: x }),
|
|
725
|
+
} = useDateSinglePicker({ id: x }), w = !!l, E = (R) => R ? R.toLocaleDateString(void 0, {
|
|
726
726
|
year: "numeric",
|
|
727
727
|
month: "short",
|
|
728
728
|
day: "numeric"
|
|
729
|
-
}) : typeof u == "string" ? u : "Select date", I = (R) => typeof d.formatDate == "function" ? d.formatDate(R) : E(R), k = () =>
|
|
730
|
-
t?.(R),
|
|
729
|
+
}) : typeof u == "string" ? u : "Select date", I = (R) => typeof d.formatDate == "function" ? d.formatDate(R) : E(R), k = () => p((R) => !R), f = y, C = (R) => {
|
|
730
|
+
t?.(R), b.current?.focus();
|
|
731
731
|
};
|
|
732
732
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "relative w-full", children: [
|
|
733
733
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "relative", children: [
|
|
734
734
|
s && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
735
735
|
"label",
|
|
736
736
|
{
|
|
737
|
-
htmlFor:
|
|
737
|
+
htmlFor: h,
|
|
738
738
|
className: "block text-sm font-medium text-foreground mb-2",
|
|
739
739
|
children: s
|
|
740
740
|
}
|
|
@@ -743,49 +743,49 @@ const DateSinglePickerInput = React__default.forwardRef(
|
|
|
743
743
|
DateSinglePickerTrigger,
|
|
744
744
|
{
|
|
745
745
|
ref: (R) => {
|
|
746
|
-
|
|
746
|
+
b.current = R, typeof g == "function" ? g(R) : g && (g.current = R);
|
|
747
747
|
},
|
|
748
|
-
id:
|
|
748
|
+
id: h,
|
|
749
749
|
"aria-haspopup": "dialog",
|
|
750
|
-
"aria-expanded":
|
|
751
|
-
"aria-controls":
|
|
752
|
-
"aria-invalid":
|
|
750
|
+
"aria-expanded": m,
|
|
751
|
+
"aria-controls": m ? `${h}-calendar` : void 0,
|
|
752
|
+
"aria-invalid": w,
|
|
753
753
|
"aria-disabled": r,
|
|
754
754
|
disabled: r,
|
|
755
755
|
leftContent: a,
|
|
756
756
|
rightContent: n,
|
|
757
|
-
hasError:
|
|
757
|
+
hasError: w,
|
|
758
758
|
variant: o,
|
|
759
759
|
value: e,
|
|
760
760
|
placeholder: typeof u == "string" ? u : "Select date",
|
|
761
761
|
formatDate: I,
|
|
762
762
|
onClick: k,
|
|
763
|
-
onKeyDown:
|
|
763
|
+
onKeyDown: f,
|
|
764
764
|
tabIndex: 0,
|
|
765
765
|
...d
|
|
766
766
|
}
|
|
767
767
|
),
|
|
768
|
-
|
|
768
|
+
w && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "mt-1 text-sm text-danger", role: "alert", children: l }),
|
|
769
769
|
c && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "mt-1 text-sm text-muted-foreground", children: c })
|
|
770
770
|
] }),
|
|
771
771
|
i === "docked" ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
772
772
|
DateSinglePickerDocked,
|
|
773
773
|
{
|
|
774
|
-
open:
|
|
774
|
+
open: m,
|
|
775
775
|
value: e,
|
|
776
776
|
onChange: C,
|
|
777
|
-
inputId:
|
|
777
|
+
inputId: h,
|
|
778
778
|
handleMenuClose: j
|
|
779
779
|
}
|
|
780
780
|
) : /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
781
781
|
DateSinglePickerModal,
|
|
782
782
|
{
|
|
783
|
-
open:
|
|
784
|
-
setOpen:
|
|
783
|
+
open: m,
|
|
784
|
+
setOpen: p,
|
|
785
785
|
value: e,
|
|
786
786
|
onChange: C,
|
|
787
787
|
label: typeof s == "string" ? s : void 0,
|
|
788
|
-
buttonRef:
|
|
788
|
+
buttonRef: b
|
|
789
789
|
}
|
|
790
790
|
)
|
|
791
791
|
] });
|
|
@@ -806,16 +806,16 @@ const DateSinglePickerInput = React__default.forwardRef(
|
|
|
806
806
|
variants: {
|
|
807
807
|
variant: {
|
|
808
808
|
// Core variants using Versaur color system
|
|
809
|
-
primary: "border-
|
|
810
|
-
secondary: "border-
|
|
811
|
-
tertiary: "border-
|
|
812
|
-
ghost: "border-
|
|
809
|
+
primary: "border-primary/40 checked:bg-primary checked:border-primary focus:ring-primary/20",
|
|
810
|
+
secondary: "border-secondary/40 checked:bg-secondary checked:border-secondary focus:ring-secondary/20",
|
|
811
|
+
tertiary: "border-tertiary/40 checked:bg-tertiary checked:border-tertiary focus:ring-tertiary/20",
|
|
812
|
+
ghost: "border-ghost/40 checked:bg-ghost checked:border-ghost focus:ring-ghost/20",
|
|
813
813
|
neutral: "border-gray-300 checked:bg-gray-500 checked:border-gray-500 focus:ring-gray-400/20",
|
|
814
814
|
// Outline variants
|
|
815
|
-
"primary-outline": "border-
|
|
816
|
-
"secondary-outline": "border-
|
|
817
|
-
"tertiary-outline": "border-
|
|
818
|
-
"ghost-outline": "border-
|
|
815
|
+
"primary-outline": "border-primary checked:bg-white checked:border-primary focus:ring-primary/20",
|
|
816
|
+
"secondary-outline": "border-secondary checked:bg-white checked:border-secondary focus:ring-secondary/20",
|
|
817
|
+
"tertiary-outline": "border-tertiary checked:bg-white checked:border-tertiary focus:ring-tertiary/20",
|
|
818
|
+
"ghost-outline": "border-ghost checked:bg-white checked:border-ghost focus:ring-ghost/20",
|
|
819
819
|
"neutral-outline": "border-gray-400 checked:bg-white checked:border-gray-400 focus:ring-gray-500/20",
|
|
820
820
|
// Semantic variants
|
|
821
821
|
success: "border-success/40 checked:bg-success checked:border-success focus:ring-success/20",
|
|
@@ -962,16 +962,16 @@ const DateSinglePickerInput = React__default.forwardRef(
|
|
|
962
962
|
variants: {
|
|
963
963
|
variant: {
|
|
964
964
|
// Core variants using Versaur color system
|
|
965
|
-
primary: "border-
|
|
966
|
-
secondary: "border-
|
|
967
|
-
tertiary: "border-
|
|
968
|
-
ghost: "border-
|
|
965
|
+
primary: "border-primary/20",
|
|
966
|
+
secondary: "border-secondary/20",
|
|
967
|
+
tertiary: "border-tertiary/20",
|
|
968
|
+
ghost: "border-ghost/20",
|
|
969
969
|
neutral: "border-gray-200",
|
|
970
970
|
// Outline variants
|
|
971
|
-
"primary-outline": "border-
|
|
972
|
-
"secondary-outline": "border-
|
|
973
|
-
"tertiary-outline": "border-
|
|
974
|
-
"ghost-outline": "border-
|
|
971
|
+
"primary-outline": "border-primary",
|
|
972
|
+
"secondary-outline": "border-secondary",
|
|
973
|
+
"tertiary-outline": "border-tertiary",
|
|
974
|
+
"ghost-outline": "border-ghost",
|
|
975
975
|
"neutral-outline": "border-gray-400",
|
|
976
976
|
// Semantic variants
|
|
977
977
|
success: "border-success/20",
|
|
@@ -1005,25 +1005,25 @@ const DateSinglePickerInput = React__default.forwardRef(
|
|
|
1005
1005
|
variants: {
|
|
1006
1006
|
variant: {
|
|
1007
1007
|
// Core variants using Versaur color system
|
|
1008
|
-
primary: "text-
|
|
1009
|
-
secondary: "text-
|
|
1010
|
-
tertiary: "text-
|
|
1011
|
-
ghost: "text-
|
|
1012
|
-
neutral: "text-
|
|
1008
|
+
primary: "text-ghost hover:text-primary focus:ring-primary/30",
|
|
1009
|
+
secondary: "text-ghost hover:text-secondary focus:ring-secondary/30",
|
|
1010
|
+
tertiary: "text-ghost hover:text-tertiary focus:ring-tertiary/30",
|
|
1011
|
+
ghost: "text-ghost hover:text-ghost focus:ring-ghost/30",
|
|
1012
|
+
neutral: "text-ghost hover:text-gray-700 focus:ring-gray-400/30",
|
|
1013
1013
|
// Outline variants
|
|
1014
|
-
"primary-outline": "text-
|
|
1015
|
-
"secondary-outline": "text-
|
|
1016
|
-
"tertiary-outline": "text-
|
|
1017
|
-
"ghost-outline": "text-
|
|
1014
|
+
"primary-outline": "text-primary hover:bg-primary/10 focus:ring-primary/30",
|
|
1015
|
+
"secondary-outline": "text-secondary hover:bg-secondary/10 focus:ring-secondary/30",
|
|
1016
|
+
"tertiary-outline": "text-tertiary hover:bg-tertiary/10 focus:ring-tertiary/30",
|
|
1017
|
+
"ghost-outline": "text-ghost hover:bg-ghost/10 focus:ring-ghost/30",
|
|
1018
1018
|
"neutral-outline": "text-gray-600 hover:bg-gray-100 focus:ring-gray-500/30",
|
|
1019
1019
|
// Semantic variants
|
|
1020
|
-
success: "text-
|
|
1020
|
+
success: "text-ghost hover:text-success focus:ring-success/30",
|
|
1021
1021
|
"success-outline": "text-success hover:bg-success/10 focus:ring-success/30",
|
|
1022
|
-
info: "text-
|
|
1022
|
+
info: "text-ghost hover:text-info focus:ring-info/30",
|
|
1023
1023
|
"info-outline": "text-info hover:bg-info/10 focus:ring-info/30",
|
|
1024
|
-
warning: "text-
|
|
1024
|
+
warning: "text-ghost hover:text-warning focus:ring-warning/30",
|
|
1025
1025
|
"warning-outline": "text-warning hover:bg-warning/10 focus:ring-warning/30",
|
|
1026
|
-
danger: "text-
|
|
1026
|
+
danger: "text-ghost hover:text-danger focus:ring-danger/30",
|
|
1027
1027
|
"danger-outline": "text-danger hover:bg-danger/10 focus:ring-danger/30"
|
|
1028
1028
|
},
|
|
1029
1029
|
size: {
|
|
@@ -1047,16 +1047,16 @@ const DateSinglePickerInput = React__default.forwardRef(
|
|
|
1047
1047
|
), getSegmentSelectedClasses$1 = (e) => {
|
|
1048
1048
|
const t = {
|
|
1049
1049
|
// Core variants - override hover text color changes
|
|
1050
|
-
primary: "bg-
|
|
1051
|
-
secondary: "bg-
|
|
1052
|
-
tertiary: "bg-
|
|
1053
|
-
ghost: "bg-
|
|
1050
|
+
primary: "bg-primary text-white shadow-sm hover:text-white",
|
|
1051
|
+
secondary: "bg-secondary text-white shadow-sm hover:text-white",
|
|
1052
|
+
tertiary: "bg-tertiary text-white shadow-sm hover:text-white",
|
|
1053
|
+
ghost: "bg-ghost text-white shadow-sm hover:text-white",
|
|
1054
1054
|
neutral: "bg-gray-500 text-white shadow-sm hover:text-white",
|
|
1055
1055
|
// Outline variants - override hover text color changes
|
|
1056
|
-
"primary-outline": "bg-
|
|
1057
|
-
"secondary-outline": "bg-
|
|
1058
|
-
"tertiary-outline": "bg-
|
|
1059
|
-
"ghost-outline": "bg-
|
|
1056
|
+
"primary-outline": "bg-primary text-white shadow-sm hover:text-white",
|
|
1057
|
+
"secondary-outline": "bg-secondary text-white shadow-sm hover:text-white",
|
|
1058
|
+
"tertiary-outline": "bg-tertiary text-white shadow-sm hover:text-white",
|
|
1059
|
+
"ghost-outline": "bg-ghost text-white shadow-sm hover:text-white",
|
|
1060
1060
|
"neutral-outline": "bg-gray-500 text-white shadow-sm hover:text-white",
|
|
1061
1061
|
// Semantic variants - override hover text color changes
|
|
1062
1062
|
success: "bg-success text-white shadow-sm hover:text-white",
|
|
@@ -1078,12 +1078,12 @@ const DateSinglePickerInput = React__default.forwardRef(
|
|
|
1078
1078
|
return e;
|
|
1079
1079
|
}, SegmentOption$1 = React__default.forwardRef(
|
|
1080
1080
|
({ children: e, className: t, disabled: s, id: a, value: n, position: c = "middle", ...l }, o) => {
|
|
1081
|
-
const r = useSegmentSingleInputContext(), u = React__default.useId(), x = a || u, i = s || r.disabled, d = r.error ? "danger" : r.variant || "primary", g = r.value === n,
|
|
1081
|
+
const r = useSegmentSingleInputContext(), u = React__default.useId(), x = a || u, i = s || r.disabled, d = r.error ? "danger" : r.variant || "primary", g = r.value === n, m = (p) => {
|
|
1082
1082
|
if (!i) {
|
|
1083
|
-
const
|
|
1084
|
-
r.onChange?.(
|
|
1083
|
+
const h = r.value === n ? null : n;
|
|
1084
|
+
r.onChange?.(h);
|
|
1085
1085
|
}
|
|
1086
|
-
l.onChange?.(
|
|
1086
|
+
l.onChange?.(p);
|
|
1087
1087
|
};
|
|
1088
1088
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
1089
1089
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -1096,7 +1096,7 @@ const DateSinglePickerInput = React__default.forwardRef(
|
|
|
1096
1096
|
value: n,
|
|
1097
1097
|
checked: g,
|
|
1098
1098
|
disabled: i,
|
|
1099
|
-
onChange:
|
|
1099
|
+
onChange: m,
|
|
1100
1100
|
className: "sr-only",
|
|
1101
1101
|
...l
|
|
1102
1102
|
}
|
|
@@ -1142,26 +1142,26 @@ const SegmentSingleInputRoot = React__default.forwardRef(
|
|
|
1142
1142
|
fullWidth: i = !1,
|
|
1143
1143
|
...d
|
|
1144
1144
|
}, g) => {
|
|
1145
|
-
const
|
|
1145
|
+
const m = !!n, p = {
|
|
1146
1146
|
variant: e,
|
|
1147
1147
|
size: t,
|
|
1148
1148
|
disabled: l,
|
|
1149
|
-
error:
|
|
1149
|
+
error: m,
|
|
1150
1150
|
name: o,
|
|
1151
1151
|
value: r,
|
|
1152
1152
|
onChange: u,
|
|
1153
1153
|
fullWidth: i
|
|
1154
|
-
},
|
|
1155
|
-
if (React__default.isValidElement(
|
|
1156
|
-
let
|
|
1157
|
-
return
|
|
1158
|
-
|
|
1159
|
-
{ position:
|
|
1154
|
+
}, h = React__default.Children.toArray(x), b = h.map((y, j) => {
|
|
1155
|
+
if (React__default.isValidElement(y)) {
|
|
1156
|
+
let w;
|
|
1157
|
+
return h.length === 1 ? w = "single" : j === 0 ? w = "first" : j === h.length - 1 ? w = "last" : w = "middle", React__default.cloneElement(
|
|
1158
|
+
y,
|
|
1159
|
+
{ position: w }
|
|
1160
1160
|
);
|
|
1161
1161
|
}
|
|
1162
|
-
return
|
|
1162
|
+
return y;
|
|
1163
1163
|
});
|
|
1164
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(SegmentSingleInputContext.Provider, { value:
|
|
1164
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(SegmentSingleInputContext.Provider, { value: p, children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
1165
1165
|
"div",
|
|
1166
1166
|
{
|
|
1167
1167
|
ref: g,
|
|
@@ -1174,17 +1174,17 @@ const SegmentSingleInputRoot = React__default.forwardRef(
|
|
|
1174
1174
|
{
|
|
1175
1175
|
className: cn(
|
|
1176
1176
|
segmentGroupVariants$1({
|
|
1177
|
-
variant:
|
|
1177
|
+
variant: m ? "danger" : e,
|
|
1178
1178
|
size: t,
|
|
1179
|
-
error:
|
|
1179
|
+
error: m
|
|
1180
1180
|
}),
|
|
1181
1181
|
i ? "flex w-full" : ""
|
|
1182
1182
|
),
|
|
1183
|
-
children:
|
|
1183
|
+
children: b
|
|
1184
1184
|
}
|
|
1185
1185
|
),
|
|
1186
|
-
|
|
1187
|
-
!
|
|
1186
|
+
m && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "mt-2 text-sm text-danger", role: "alert", children: n }),
|
|
1187
|
+
!m && a && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "mt-2 text-sm text-gray-600", children: a })
|
|
1188
1188
|
]
|
|
1189
1189
|
}
|
|
1190
1190
|
) });
|
|
@@ -1197,16 +1197,16 @@ const SegmentSingleInputRoot = React__default.forwardRef(
|
|
|
1197
1197
|
variants: {
|
|
1198
1198
|
variant: {
|
|
1199
1199
|
// Core variants using Versaur color system
|
|
1200
|
-
primary: "border-
|
|
1201
|
-
secondary: "border-
|
|
1202
|
-
tertiary: "border-
|
|
1203
|
-
ghost: "border-
|
|
1200
|
+
primary: "border-primary/20",
|
|
1201
|
+
secondary: "border-secondary/20",
|
|
1202
|
+
tertiary: "border-tertiary/20",
|
|
1203
|
+
ghost: "border-ghost/20",
|
|
1204
1204
|
neutral: "border-gray-200",
|
|
1205
1205
|
// Outline variants
|
|
1206
|
-
"primary-outline": "border-
|
|
1207
|
-
"secondary-outline": "border-
|
|
1208
|
-
"tertiary-outline": "border-
|
|
1209
|
-
"ghost-outline": "border-
|
|
1206
|
+
"primary-outline": "border-primary",
|
|
1207
|
+
"secondary-outline": "border-secondary",
|
|
1208
|
+
"tertiary-outline": "border-tertiary",
|
|
1209
|
+
"ghost-outline": "border-ghost",
|
|
1210
1210
|
"neutral-outline": "border-gray-400",
|
|
1211
1211
|
// Semantic variants
|
|
1212
1212
|
success: "border-success/20",
|
|
@@ -1240,25 +1240,25 @@ const SegmentSingleInputRoot = React__default.forwardRef(
|
|
|
1240
1240
|
variants: {
|
|
1241
1241
|
variant: {
|
|
1242
1242
|
// Core variants using Versaur color system
|
|
1243
|
-
primary: "text-
|
|
1244
|
-
secondary: "text-
|
|
1245
|
-
tertiary: "text-
|
|
1246
|
-
ghost: "text-
|
|
1247
|
-
neutral: "text-
|
|
1243
|
+
primary: "text-ghost hover:text-primary focus:ring-primary/30",
|
|
1244
|
+
secondary: "text-ghost hover:text-secondary focus:ring-secondary/30",
|
|
1245
|
+
tertiary: "text-ghost hover:text-tertiary focus:ring-tertiary/30",
|
|
1246
|
+
ghost: "text-ghost hover:text-ghost focus:ring-ghost/30",
|
|
1247
|
+
neutral: "text-ghost hover:text-gray-700 focus:ring-gray-400/30",
|
|
1248
1248
|
// Outline variants
|
|
1249
|
-
"primary-outline": "text-
|
|
1250
|
-
"secondary-outline": "text-
|
|
1251
|
-
"tertiary-outline": "text-
|
|
1252
|
-
"ghost-outline": "text-
|
|
1249
|
+
"primary-outline": "text-primary hover:bg-primary/10 focus:ring-primary/30",
|
|
1250
|
+
"secondary-outline": "text-secondary hover:bg-secondary/10 focus:ring-secondary/30",
|
|
1251
|
+
"tertiary-outline": "text-tertiary hover:bg-tertiary/10 focus:ring-tertiary/30",
|
|
1252
|
+
"ghost-outline": "text-ghost hover:bg-ghost/10 focus:ring-ghost/30",
|
|
1253
1253
|
"neutral-outline": "text-gray-600 hover:bg-gray-100 focus:ring-gray-500/30",
|
|
1254
1254
|
// Semantic variants
|
|
1255
|
-
success: "text-
|
|
1255
|
+
success: "text-ghost hover:text-success focus:ring-success/30",
|
|
1256
1256
|
"success-outline": "text-success hover:bg-success/10 focus:ring-success/30",
|
|
1257
|
-
info: "text-
|
|
1257
|
+
info: "text-ghost hover:text-info focus:ring-info/30",
|
|
1258
1258
|
"info-outline": "text-info hover:bg-info/10 focus:ring-info/30",
|
|
1259
|
-
warning: "text-
|
|
1259
|
+
warning: "text-ghost hover:text-warning focus:ring-warning/30",
|
|
1260
1260
|
"warning-outline": "text-warning hover:bg-warning/10 focus:ring-warning/30",
|
|
1261
|
-
danger: "text-
|
|
1261
|
+
danger: "text-ghost hover:text-danger focus:ring-danger/30",
|
|
1262
1262
|
"danger-outline": "text-danger hover:bg-danger/10 focus:ring-danger/30"
|
|
1263
1263
|
},
|
|
1264
1264
|
size: {
|
|
@@ -1282,16 +1282,16 @@ const SegmentSingleInputRoot = React__default.forwardRef(
|
|
|
1282
1282
|
), getSegmentSelectedClasses = (e) => {
|
|
1283
1283
|
const t = {
|
|
1284
1284
|
// Core variants - override hover text color changes
|
|
1285
|
-
primary: "bg-
|
|
1286
|
-
secondary: "bg-
|
|
1287
|
-
tertiary: "bg-
|
|
1288
|
-
ghost: "bg-
|
|
1285
|
+
primary: "bg-primary text-white shadow-sm hover:text-white",
|
|
1286
|
+
secondary: "bg-secondary text-white shadow-sm hover:text-white",
|
|
1287
|
+
tertiary: "bg-tertiary text-white shadow-sm hover:text-white",
|
|
1288
|
+
ghost: "bg-ghost text-white shadow-sm hover:text-white",
|
|
1289
1289
|
neutral: "bg-gray-500 text-white shadow-sm hover:text-white",
|
|
1290
1290
|
// Outline variants - override hover text color changes
|
|
1291
|
-
"primary-outline": "bg-
|
|
1292
|
-
"secondary-outline": "bg-
|
|
1293
|
-
"tertiary-outline": "bg-
|
|
1294
|
-
"ghost-outline": "bg-
|
|
1291
|
+
"primary-outline": "bg-primary text-white shadow-sm hover:text-white",
|
|
1292
|
+
"secondary-outline": "bg-secondary text-white shadow-sm hover:text-white",
|
|
1293
|
+
"tertiary-outline": "bg-tertiary text-white shadow-sm hover:text-white",
|
|
1294
|
+
"ghost-outline": "bg-ghost text-white shadow-sm hover:text-white",
|
|
1295
1295
|
"neutral-outline": "bg-gray-500 text-white shadow-sm hover:text-white",
|
|
1296
1296
|
// Semantic variants - override hover text color changes
|
|
1297
1297
|
success: "bg-success text-white shadow-sm hover:text-white",
|
|
@@ -1313,13 +1313,13 @@ const SegmentSingleInputRoot = React__default.forwardRef(
|
|
|
1313
1313
|
return e;
|
|
1314
1314
|
}, SegmentOption = React__default.forwardRef(
|
|
1315
1315
|
({ children: e, className: t, disabled: s, id: a, value: n, position: c = "middle", ...l }, o) => {
|
|
1316
|
-
const r = useSegmentMultipleInputContext(), u = React__default.useId(), x = a || u, i = s || r.disabled, d = r.error ? "danger" : r.variant || "primary", g = r.value?.includes(n) ?? !1,
|
|
1316
|
+
const r = useSegmentMultipleInputContext(), u = React__default.useId(), x = a || u, i = s || r.disabled, d = r.error ? "danger" : r.variant || "primary", g = r.value?.includes(n) ?? !1, m = (p) => {
|
|
1317
1317
|
if (!i) {
|
|
1318
|
-
const
|
|
1319
|
-
let
|
|
1320
|
-
g ?
|
|
1318
|
+
const h = r.value || [];
|
|
1319
|
+
let b;
|
|
1320
|
+
g ? b = h.filter((y) => y !== n) : b = [...h, n], r.onChange?.(b);
|
|
1321
1321
|
}
|
|
1322
|
-
l.onChange?.(
|
|
1322
|
+
l.onChange?.(p);
|
|
1323
1323
|
};
|
|
1324
1324
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
1325
1325
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -1332,7 +1332,7 @@ const SegmentSingleInputRoot = React__default.forwardRef(
|
|
|
1332
1332
|
value: n,
|
|
1333
1333
|
checked: g,
|
|
1334
1334
|
disabled: i,
|
|
1335
|
-
onChange:
|
|
1335
|
+
onChange: m,
|
|
1336
1336
|
className: "sr-only",
|
|
1337
1337
|
...l
|
|
1338
1338
|
}
|
|
@@ -1377,25 +1377,25 @@ const SegmentMultipleInputRoot = React__default.forwardRef(
|
|
|
1377
1377
|
fullWidth: i = !1,
|
|
1378
1378
|
...d
|
|
1379
1379
|
}, g) => {
|
|
1380
|
-
const
|
|
1380
|
+
const m = !!n, p = {
|
|
1381
1381
|
variant: e,
|
|
1382
1382
|
size: t,
|
|
1383
1383
|
disabled: l,
|
|
1384
|
-
error:
|
|
1384
|
+
error: m,
|
|
1385
1385
|
name: o,
|
|
1386
1386
|
value: r,
|
|
1387
1387
|
onChange: u
|
|
1388
|
-
},
|
|
1389
|
-
if (React__default.isValidElement(
|
|
1390
|
-
let
|
|
1391
|
-
return
|
|
1392
|
-
|
|
1393
|
-
{ position:
|
|
1388
|
+
}, h = React__default.Children.toArray(x), b = h.map((y, j) => {
|
|
1389
|
+
if (React__default.isValidElement(y)) {
|
|
1390
|
+
let w;
|
|
1391
|
+
return h.length === 1 ? w = "single" : j === 0 ? w = "first" : j === h.length - 1 ? w = "last" : w = "middle", React__default.cloneElement(
|
|
1392
|
+
y,
|
|
1393
|
+
{ position: w }
|
|
1394
1394
|
);
|
|
1395
1395
|
}
|
|
1396
|
-
return
|
|
1396
|
+
return y;
|
|
1397
1397
|
});
|
|
1398
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(SegmentMultipleInputContext.Provider, { value:
|
|
1398
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(SegmentMultipleInputContext.Provider, { value: p, children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
1399
1399
|
"div",
|
|
1400
1400
|
{
|
|
1401
1401
|
ref: g,
|
|
@@ -1411,17 +1411,17 @@ const SegmentMultipleInputRoot = React__default.forwardRef(
|
|
|
1411
1411
|
{
|
|
1412
1412
|
className: cn(
|
|
1413
1413
|
segmentGroupVariants({
|
|
1414
|
-
variant:
|
|
1414
|
+
variant: m ? "danger" : e,
|
|
1415
1415
|
size: t,
|
|
1416
|
-
error:
|
|
1416
|
+
error: m
|
|
1417
1417
|
}),
|
|
1418
1418
|
i && "flex w-full"
|
|
1419
1419
|
),
|
|
1420
|
-
children:
|
|
1420
|
+
children: b
|
|
1421
1421
|
}
|
|
1422
1422
|
),
|
|
1423
|
-
|
|
1424
|
-
!
|
|
1423
|
+
m && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "mt-2 text-sm text-danger", role: "alert", children: n }),
|
|
1424
|
+
!m && a && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "mt-2 text-sm text-gray-600", children: a })
|
|
1425
1425
|
]
|
|
1426
1426
|
}
|
|
1427
1427
|
) });
|
|
@@ -1434,16 +1434,16 @@ const SegmentMultipleInputRoot = React__default.forwardRef(
|
|
|
1434
1434
|
variants: {
|
|
1435
1435
|
variant: {
|
|
1436
1436
|
// Core variants using Versaur color system
|
|
1437
|
-
primary: "border-
|
|
1438
|
-
secondary: "border-
|
|
1439
|
-
tertiary: "border-
|
|
1440
|
-
ghost: "border-
|
|
1437
|
+
primary: "border-primary/30 text-foreground focus:border-primary focus:ring-primary/20",
|
|
1438
|
+
secondary: "border-secondary/30 text-foreground focus:border-secondary focus:ring-secondary/20",
|
|
1439
|
+
tertiary: "border-tertiary/30 text-foreground focus:border-tertiary focus:ring-tertiary/20",
|
|
1440
|
+
ghost: "border-ghost/30 text-foreground focus:border-ghost focus:ring-ghost/20",
|
|
1441
1441
|
neutral: "border-gray-300 text-foreground focus:border-gray-400 focus:ring-gray-400/20",
|
|
1442
1442
|
// Outline variants
|
|
1443
|
-
"primary-outline": "border-
|
|
1444
|
-
"secondary-outline": "border-
|
|
1445
|
-
"tertiary-outline": "border-
|
|
1446
|
-
"ghost-outline": "border-
|
|
1443
|
+
"primary-outline": "border-primary text-foreground focus:border-primary focus:ring-primary/20",
|
|
1444
|
+
"secondary-outline": "border-secondary text-foreground focus:border-secondary focus:ring-secondary/20",
|
|
1445
|
+
"tertiary-outline": "border-tertiary text-foreground focus:border-tertiary focus:ring-tertiary/20",
|
|
1446
|
+
"ghost-outline": "border-ghost text-foreground focus:border-ghost focus:ring-ghost/20",
|
|
1447
1447
|
"neutral-outline": "border-gray-400 text-foreground focus:border-gray-500 focus:ring-gray-500/20",
|
|
1448
1448
|
// Semantic variants
|
|
1449
1449
|
success: "border-success/30 text-foreground focus:border-success focus:ring-success/20",
|
|
@@ -1536,16 +1536,16 @@ const textAreaInputVariants = cva(
|
|
|
1536
1536
|
variants: {
|
|
1537
1537
|
variant: {
|
|
1538
1538
|
// Core variants using Versaur color system
|
|
1539
|
-
primary: "border-
|
|
1540
|
-
secondary: "border-
|
|
1541
|
-
tertiary: "border-
|
|
1542
|
-
ghost: "border-
|
|
1539
|
+
primary: "border-primary/30 text-foreground focus:border-primary focus:ring-primary/20",
|
|
1540
|
+
secondary: "border-secondary/30 text-foreground focus:border-secondary focus:ring-secondary/20",
|
|
1541
|
+
tertiary: "border-tertiary/30 text-foreground focus:border-tertiary focus:ring-tertiary/20",
|
|
1542
|
+
ghost: "border-ghost/30 text-foreground focus:border-ghost focus:ring-ghost/20",
|
|
1543
1543
|
neutral: "border-gray-300 text-foreground focus:border-gray-400 focus:ring-gray-400/20",
|
|
1544
1544
|
// Outline variants
|
|
1545
|
-
"primary-outline": "border-
|
|
1546
|
-
"secondary-outline": "border-
|
|
1547
|
-
"tertiary-outline": "border-
|
|
1548
|
-
"ghost-outline": "border-
|
|
1545
|
+
"primary-outline": "border-primary text-foreground focus:border-primary focus:ring-primary/20",
|
|
1546
|
+
"secondary-outline": "border-secondary text-foreground focus:border-secondary focus:ring-secondary/20",
|
|
1547
|
+
"tertiary-outline": "border-tertiary text-foreground focus:border-tertiary focus:ring-tertiary/20",
|
|
1548
|
+
"ghost-outline": "border-ghost text-foreground focus:border-ghost focus:ring-ghost/20",
|
|
1549
1549
|
"neutral-outline": "border-gray-400 text-foreground focus:border-gray-500 focus:ring-gray-500/20",
|
|
1550
1550
|
// Semantic variants
|
|
1551
1551
|
success: "border-success/30 text-foreground focus:border-success focus:ring-success/20",
|
|
@@ -1583,10 +1583,10 @@ const textAreaInputVariants = cva(
|
|
|
1583
1583
|
rows: i,
|
|
1584
1584
|
...d
|
|
1585
1585
|
}, g) => {
|
|
1586
|
-
const
|
|
1586
|
+
const m = React__default.useId(), p = l || m, h = !!a, b = i || o, y = u === "content" ? void 0 : r, j = {
|
|
1587
1587
|
...u === "content" && { fieldSizing: "content" },
|
|
1588
|
-
...
|
|
1589
|
-
maxHeight: `${
|
|
1588
|
+
...y && {
|
|
1589
|
+
maxHeight: `${y * 1.5}rem`
|
|
1590
1590
|
// Approximate line height
|
|
1591
1591
|
},
|
|
1592
1592
|
...x
|
|
@@ -1595,7 +1595,7 @@ const textAreaInputVariants = cva(
|
|
|
1595
1595
|
t && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
1596
1596
|
"label",
|
|
1597
1597
|
{
|
|
1598
|
-
htmlFor:
|
|
1598
|
+
htmlFor: p,
|
|
1599
1599
|
className: "block text-sm font-medium text-foreground mb-2",
|
|
1600
1600
|
children: t
|
|
1601
1601
|
}
|
|
@@ -1604,15 +1604,15 @@ const textAreaInputVariants = cva(
|
|
|
1604
1604
|
"textarea",
|
|
1605
1605
|
{
|
|
1606
1606
|
ref: g,
|
|
1607
|
-
id:
|
|
1608
|
-
rows:
|
|
1609
|
-
"aria-invalid":
|
|
1607
|
+
id: p,
|
|
1608
|
+
rows: b,
|
|
1609
|
+
"aria-invalid": h,
|
|
1610
1610
|
"aria-disabled": c,
|
|
1611
1611
|
disabled: c,
|
|
1612
1612
|
style: j,
|
|
1613
1613
|
className: cn(
|
|
1614
1614
|
textAreaInputVariants({
|
|
1615
|
-
variant:
|
|
1615
|
+
variant: h ? "danger" : e,
|
|
1616
1616
|
fieldSizing: u
|
|
1617
1617
|
}),
|
|
1618
1618
|
"px-3 py-2"
|
|
@@ -1620,8 +1620,8 @@ const textAreaInputVariants = cva(
|
|
|
1620
1620
|
...d
|
|
1621
1621
|
}
|
|
1622
1622
|
) }),
|
|
1623
|
-
|
|
1624
|
-
!
|
|
1623
|
+
h && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "mt-1 text-sm text-danger", role: "alert", children: a }),
|
|
1624
|
+
!h && s && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "mt-1 text-sm text-gray-600", children: s })
|
|
1625
1625
|
] });
|
|
1626
1626
|
}
|
|
1627
1627
|
);
|
|
@@ -1698,27 +1698,27 @@ const timeSegmentButtonVariants = cva(
|
|
|
1698
1698
|
"aria-describedby": u
|
|
1699
1699
|
}) => {
|
|
1700
1700
|
const [x, i] = useState(!1), d = (k) => {
|
|
1701
|
-
const
|
|
1702
|
-
return
|
|
1703
|
-
hour:
|
|
1704
|
-
minute:
|
|
1705
|
-
period:
|
|
1701
|
+
const f = k.match(/^(\d{1,2}):(\d{2})\s?(AM|PM)$/i);
|
|
1702
|
+
return f ? {
|
|
1703
|
+
hour: f[1],
|
|
1704
|
+
minute: f[2],
|
|
1705
|
+
period: f[3].toUpperCase()
|
|
1706
1706
|
} : { hour: "", minute: "", period: "AM" };
|
|
1707
|
-
}, [{ hour: g, minute:
|
|
1708
|
-
n || (
|
|
1709
|
-
}, w = (k) => {
|
|
1710
|
-
let h = k.replace(/[^\d]/g, "");
|
|
1711
|
-
h.length > 2 && (h = h.slice(0, 2)), Number(h) > 12 && (h = "12"), m((C) => ({ ...C, hour: h }));
|
|
1712
|
-
}, j = (k) => {
|
|
1713
|
-
let h = k.replace(/[^\d]/g, "");
|
|
1714
|
-
h.length > 2 && (h = h.slice(0, 2)), Number(h) > 59 && (h = "59"), m((C) => ({ ...C, minute: h }));
|
|
1707
|
+
}, [{ hour: g, minute: m, period: p }, h] = useState(() => d(e)), b = () => {
|
|
1708
|
+
n || (h(d(e)), i(!0));
|
|
1715
1709
|
}, y = (k) => {
|
|
1716
|
-
|
|
1710
|
+
let f = k.replace(/[^\d]/g, "");
|
|
1711
|
+
f.length > 2 && (f = f.slice(0, 2)), Number(f) > 12 && (f = "12"), h((C) => ({ ...C, hour: f }));
|
|
1712
|
+
}, j = (k) => {
|
|
1713
|
+
let f = k.replace(/[^\d]/g, "");
|
|
1714
|
+
f.length > 2 && (f = f.slice(0, 2)), Number(f) > 59 && (f = "59"), h((C) => ({ ...C, minute: f }));
|
|
1715
|
+
}, w = (k) => {
|
|
1716
|
+
h((f) => ({ ...f, period: k }));
|
|
1717
1717
|
}, E = () => {
|
|
1718
|
-
|
|
1718
|
+
h(d(e)), i(!1);
|
|
1719
1719
|
}, I = () => {
|
|
1720
|
-
const k = g.padStart(2, "0") || "12",
|
|
1721
|
-
t(`${k}:${
|
|
1720
|
+
const k = g.padStart(2, "0") || "12", f = m.padStart(2, "0") || "00";
|
|
1721
|
+
t(`${k}:${f} ${p}`), i(!1);
|
|
1722
1722
|
};
|
|
1723
1723
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
1724
1724
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -1726,7 +1726,7 @@ const timeSegmentButtonVariants = cva(
|
|
|
1726
1726
|
{
|
|
1727
1727
|
label: s,
|
|
1728
1728
|
value: e,
|
|
1729
|
-
onClick:
|
|
1729
|
+
onClick: b,
|
|
1730
1730
|
readOnly: !0,
|
|
1731
1731
|
disabled: n,
|
|
1732
1732
|
error: c,
|
|
@@ -1755,7 +1755,7 @@ const timeSegmentButtonVariants = cva(
|
|
|
1755
1755
|
TimeField,
|
|
1756
1756
|
{
|
|
1757
1757
|
value: g,
|
|
1758
|
-
onChange:
|
|
1758
|
+
onChange: y,
|
|
1759
1759
|
label: "Hour",
|
|
1760
1760
|
"aria-label": "Hour",
|
|
1761
1761
|
disabled: n
|
|
@@ -1765,7 +1765,7 @@ const timeSegmentButtonVariants = cva(
|
|
|
1765
1765
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
1766
1766
|
TimeField,
|
|
1767
1767
|
{
|
|
1768
|
-
value:
|
|
1768
|
+
value: m,
|
|
1769
1769
|
onChange: j,
|
|
1770
1770
|
label: "Minute",
|
|
1771
1771
|
"aria-label": "Minute",
|
|
@@ -1775,8 +1775,8 @@ const timeSegmentButtonVariants = cva(
|
|
|
1775
1775
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
1776
1776
|
AmPmSegment,
|
|
1777
1777
|
{
|
|
1778
|
-
value:
|
|
1779
|
-
onChange:
|
|
1778
|
+
value: p === "AM" ? "AM" : "PM",
|
|
1779
|
+
onChange: w,
|
|
1780
1780
|
disabled: n
|
|
1781
1781
|
}
|
|
1782
1782
|
)
|
|
@@ -1790,7 +1790,7 @@ const timeSegmentButtonVariants = cva(
|
|
|
1790
1790
|
)
|
|
1791
1791
|
] });
|
|
1792
1792
|
}, switchVariants = cva(
|
|
1793
|
-
"relative inline-flex items-center transition-colors duration-200",
|
|
1793
|
+
"relative inline-flex items-center transition-colors duration-200 border border-transparent",
|
|
1794
1794
|
{
|
|
1795
1795
|
variants: {
|
|
1796
1796
|
color: {
|
|
@@ -1825,20 +1825,24 @@ const timeSegmentButtonVariants = cva(
|
|
|
1825
1825
|
checked: !1
|
|
1826
1826
|
},
|
|
1827
1827
|
compoundVariants: [
|
|
1828
|
-
{
|
|
1828
|
+
{
|
|
1829
|
+
checked: !0,
|
|
1830
|
+
color: "primary",
|
|
1831
|
+
class: "bg-primary"
|
|
1832
|
+
},
|
|
1829
1833
|
{
|
|
1830
1834
|
checked: !0,
|
|
1831
1835
|
color: "secondary",
|
|
1832
|
-
class: "bg-
|
|
1836
|
+
class: "bg-secondary"
|
|
1833
1837
|
},
|
|
1834
|
-
{ checked: !0, color: "tertiary", class: "bg-
|
|
1835
|
-
{ checked: !0, color: "ghost", class: "bg-
|
|
1836
|
-
{ checked: !0, color: "neutral", class: "bg-
|
|
1837
|
-
{ checked: !0, color: "success", class: "bg-
|
|
1838
|
-
{ checked: !0, color: "info", class: "bg-
|
|
1839
|
-
{ checked: !0, color: "warning", class: "bg-
|
|
1840
|
-
{ checked: !0, color: "danger", class: "bg-
|
|
1841
|
-
{ checked: !1, class: "bg-white border
|
|
1838
|
+
{ checked: !0, color: "tertiary", class: "bg-tertiary" },
|
|
1839
|
+
{ checked: !0, color: "ghost", class: "bg-ghost" },
|
|
1840
|
+
{ checked: !0, color: "neutral", class: "bg-neutral" },
|
|
1841
|
+
{ checked: !0, color: "success", class: "bg-success" },
|
|
1842
|
+
{ checked: !0, color: "info", class: "bg-info" },
|
|
1843
|
+
{ checked: !0, color: "warning", class: "bg-warning" },
|
|
1844
|
+
{ checked: !0, color: "danger", class: "bg-danger" },
|
|
1845
|
+
{ checked: !1, class: "bg-white border-border" }
|
|
1842
1846
|
]
|
|
1843
1847
|
}
|
|
1844
1848
|
), thumbVariants = cva(
|
|
@@ -1852,7 +1856,7 @@ const timeSegmentButtonVariants = cva(
|
|
|
1852
1856
|
},
|
|
1853
1857
|
checked: {
|
|
1854
1858
|
true: "translate-x-full bg-white left-1.5",
|
|
1855
|
-
false: "bg-
|
|
1859
|
+
false: "bg-neutral left-0.5"
|
|
1856
1860
|
}
|
|
1857
1861
|
},
|
|
1858
1862
|
defaultVariants: {
|
|
@@ -1902,10 +1906,10 @@ const timeSegmentButtonVariants = cva(
|
|
|
1902
1906
|
ariaLabel: x,
|
|
1903
1907
|
...i
|
|
1904
1908
|
}, d) => {
|
|
1905
|
-
const [g,
|
|
1909
|
+
const [g, m] = useState(
|
|
1906
1910
|
t ?? !1
|
|
1907
|
-
),
|
|
1908
|
-
|
|
1911
|
+
), p = useId(), h = u || p, b = typeof e == "boolean", y = b ? e : g, j = (w) => {
|
|
1912
|
+
b || m(w.target.checked), s?.(w.target.checked);
|
|
1909
1913
|
};
|
|
1910
1914
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
1911
1915
|
"div",
|
|
@@ -1920,7 +1924,7 @@ const timeSegmentButtonVariants = cva(
|
|
|
1920
1924
|
SwitchLabel,
|
|
1921
1925
|
{
|
|
1922
1926
|
label: c,
|
|
1923
|
-
htmlFor:
|
|
1927
|
+
htmlFor: h,
|
|
1924
1928
|
placement: l,
|
|
1925
1929
|
disabled: o
|
|
1926
1930
|
}
|
|
@@ -1938,9 +1942,9 @@ const timeSegmentButtonVariants = cva(
|
|
|
1938
1942
|
{
|
|
1939
1943
|
ref: d,
|
|
1940
1944
|
type: "checkbox",
|
|
1941
|
-
id:
|
|
1945
|
+
id: h,
|
|
1942
1946
|
"aria-label": x || c,
|
|
1943
|
-
checked:
|
|
1947
|
+
checked: y,
|
|
1944
1948
|
disabled: o,
|
|
1945
1949
|
onChange: j,
|
|
1946
1950
|
className: "absolute inset-0 w-full h-full opacity-0 cursor-pointer z-10",
|
|
@@ -1953,10 +1957,10 @@ const timeSegmentButtonVariants = cva(
|
|
|
1953
1957
|
color: a,
|
|
1954
1958
|
size: n,
|
|
1955
1959
|
disabled: o,
|
|
1956
|
-
checked:
|
|
1960
|
+
checked: y
|
|
1957
1961
|
}
|
|
1958
1962
|
),
|
|
1959
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(SwitchThumb, { size: n, checked:
|
|
1963
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(SwitchThumb, { size: n, checked: y })
|
|
1960
1964
|
]
|
|
1961
1965
|
}
|
|
1962
1966
|
)
|