@clasing/ui 0.1.137 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +0,0 @@
1
- "use strict";const t=require("./jsx-runtime-BuHQgaKs.cjs"),p=require("./index-DoxiiusW.cjs"),$=require("@radix-ui/react-slot"),w=require("./index-C8P6Mn4U.cjs"),u=require("react"),r=require("./icon-component-D5YssRbR.cjs"),a=require("./tooltip-VxOmcZ36.cjs"),k="focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] relative flex items-center justify-center outline-1 transition-[color,box-shadow]",z=w.cva(k,{variants:{variant:{primary:["bg-primary-600 lg:hover:bg-primary-800 text-white outline-transparent disabled:bg-neutral-100 disabled:text-neutral-700 disabled:lg:hover:bg-neutral-100 disabled:lg:hover:text-neutral-700"],secondary:["bg-black text-white outline-transparent disabled:bg-neutral-100 disabled:text-neutral-700 lg:hover:bg-neutral-900 disabled:lg:hover:bg-neutral-100 disabled:lg:hover:text-neutral-700"],inverse:["lg:hover:bg-neutral-000 bg-white text-black outline-transparent disabled:bg-neutral-100 disabled:text-neutral-700 disabled:lg:hover:bg-neutral-100 disabled:lg:hover:text-neutral-700"],outline:["text-primary-600 outline-primary-600 lg:hover:bg-primary-050 bg-white disabled:bg-neutral-100 disabled:text-neutral-700 disabled:outline-transparent disabled:lg:hover:bg-neutral-100 disabled:lg:hover:text-neutral-700"],ghost:["bg-primary-050 text-primary-600 lg:hover:bg-primary-100 outline-transparent disabled:bg-neutral-100 disabled:text-neutral-700 disabled:lg:hover:bg-neutral-100 disabled:lg:hover:text-neutral-700"],destructive:["bg-error-light text-error-main outline-transparent disabled:bg-neutral-100 disabled:text-neutral-700 disabled:lg:hover:bg-neutral-100 disabled:lg:hover:text-neutral-700"],link:["text-primary-600 lg:hover:bg-primary-050 bg-transparent outline-transparent disabled:bg-neutral-100 disabled:text-neutral-700 disabled:lg:hover:bg-neutral-100 disabled:lg:hover:text-neutral-700"]},size:{xl:"h-12 gap-2 px-6 py-1 text-base",lg:"h-10 gap-2 px-5 py-1 text-sm",md:"h-8 gap-1.5 px-4 py-1 text-xs",sm:"h-7 gap-1 px-3 py-1 text-xs",xs:"h-6 gap-1 px-3 py-1 text-xs"},rounded:{default:"rounded-2xl",full:"rounded-full"},weight:{light:"font-light",regular:"font-regular",semibold:"font-semibold",bold:"font-bold"},iconPosition:{left:"",right:"",only:"aspect-square"}},compoundVariants:[{iconPosition:"only",variant:"primary",class:"outline-neutral-050 text-primary-600 lg:hover:bg-neutral-000 bg-white"},{iconPosition:"only",variant:"destructive",class:"bg-error-light text-error-main outline-transparent"},{iconPosition:"only",variant:"link",class:"text-primary-600 lg:hover:bg-primary-050 bg-transparent"},{iconPosition:"only",size:"xl",class:"h-12 w-12 p-1.5"},{iconPosition:"only",size:"lg",class:"h-10 w-10 p-1.5"},{iconPosition:"only",size:"md",class:"h-8 w-8 p-1.5"},{iconPosition:"only",size:"sm",class:"h-7 w-7 p-1.5"},{iconPosition:"only",size:"xs",class:"h-6 w-6 p-1.5"},{variant:"link",size:"xl",class:"h-auto gap-2 px-3 py-1 text-base"},{variant:"link",size:"lg",class:"h-auto gap-2 px-3 py-1 text-base"},{variant:"link",size:"md",class:"h-auto gap-1.5 px-3 py-1 text-sm"},{variant:"link",size:"sm",class:"h-auto gap-1 px-3 py-1 text-xs"},{variant:"link",size:"xs",class:"h-auto gap-1 px-3 py-1 text-xs"}],defaultVariants:{variant:"primary",size:"xl",weight:"semibold",rounded:"full",iconPosition:"left"}}),C=w.cva(`${k} cursor-default`,{variants:{variant:{primary:["bg-primary-800 text-white outline-transparent"],secondary:["bg-neutral-900 text-white outline-transparent"],inverse:["bg-neutral-000 text-black outline-transparent"],ghost:["bg-primary-100 text-primary-600 outline-transparent"],outline:["bg-primary-100 text-primary-600 outline-primary-600"],destructive:["bg-error-light text-error-main outline-transparent"],link:["bg-primary-050 text-primary-600"]},size:{xl:"h-12 gap-2 px-6 text-base",lg:"h-10 gap-2 px-5 text-sm",md:"h-8 gap-1.5 px-4 text-xs",sm:"h-7 gap-1 px-3 text-xs",xs:"h-6 gap-1 px-3 text-xs"},rounded:{default:"rounded-2xl",full:"rounded-full"},weight:{light:"font-light",regular:"font-regular",semibold:"font-semibold",bold:"font-bold"},iconPosition:{left:"",right:"",only:"aspect-square"}},compoundVariants:[{iconPosition:"only",variant:"primary",class:"bg-neutral-000 text-primary-600 outline-neutral-050"},{iconPosition:"only",variant:"destructive",class:"bg-error-light text-error-main outline-transparent"},{iconPosition:"only",variant:"link",class:"bg-primary-050 text-primary-600"},{iconPosition:"only",size:"xl",class:"h-12 w-12 p-3"},{iconPosition:"only",size:"lg",class:"h-10 w-10 p-2"},{iconPosition:"only",size:"md",class:"h-8 w-8 p-1"},{iconPosition:"only",size:"sm",class:"h-7 w-7 p-0.5"},{iconPosition:"only",size:"xs",class:"h-6 w-6 p-0.5"},{variant:"link",size:"xl",class:"h-auto gap-2 px-3 py-1 text-base"},{variant:"link",size:"lg",class:"h-auto gap-2 px-3 py-1 text-base"},{variant:"link",size:"md",class:"h-auto gap-1.5 px-3 py-1 text-sm"},{variant:"link",size:"sm",class:"h-auto gap-1 px-3 py-1 text-xs"},{variant:"link",size:"xs",class:"h-auto gap-1 px-3 py-1 text-xs"}],defaultVariants:{variant:"primary",size:"xl",weight:"semibold",rounded:"full",iconPosition:"left"}}),N=w.cva(k,{variants:{variant:{primary:["bg-primary-800 text-white outline-transparent"],secondary:["bg-neutral-900 text-white outline-transparent"],inverse:["bg-neutral-000 text-black outline-transparent"],ghost:["bg-primary-100 text-primary-600 outline-transparent"],outline:["bg-primary-100 text-primary-600 outline-primary-600"],destructive:["bg-error-light text-error-main outline-transparent"],link:["bg-primary-050 text-primary-600"]},size:{xl:"h-12 gap-2 px-6 text-base",lg:"h-10 gap-2 px-5 text-sm",md:"h-8 gap-1.5 px-4 text-xs",sm:"h-7 gap-1 px-3 text-xs",xs:"h-6 gap-1 px-3 text-xs"},rounded:{default:"rounded-2xl",full:"rounded-full"},weight:{light:"font-light",regular:"font-regular",semibold:"font-semibold",bold:"font-bold"},iconPosition:{left:"",right:"",only:"aspect-square"}},compoundVariants:[{iconPosition:"only",variant:"primary",class:"bg-neutral-000 text-primary-600 outline-neutral-050"},{iconPosition:"only",variant:"destructive",class:"bg-error-light text-error-main outline-transparent"},{iconPosition:"only",variant:"link",class:"bg-primary-050 text-primary-600"},{iconPosition:"only",size:"xl",class:"h-12 w-12 p-3"},{iconPosition:"only",size:"lg",class:"h-10 w-10 p-2"},{iconPosition:"only",size:"md",class:"h-8 w-8 p-1"},{iconPosition:"only",size:"sm",class:"h-7 w-7 p-0.5"},{iconPosition:"only",size:"xs",class:"h-6 w-6 p-0.5"},{variant:"link",size:"xl",class:"h-auto gap-2 px-3 py-1 text-base"},{variant:"link",size:"lg",class:"h-auto gap-2 px-3 py-1 text-base"},{variant:"link",size:"md",class:"h-auto gap-1.5 px-3 py-1 text-sm"},{variant:"link",size:"sm",class:"h-auto gap-1 px-3 py-1 text-xs"},{variant:"link",size:"xs",class:"h-auto gap-1 px-3 py-1 text-xs"}],defaultVariants:{variant:"primary",size:"xl",weight:"semibold",rounded:"full",iconPosition:"left"}}),I=u.forwardRef(({className:b,variant:h,size:i,weight:y,rounded:v,children:o,iconName:l,iconText:c,iconPosition:f="left",isLoading:s,isActive:q,disabled:E,tooltip:d,tooltipPlacement:R="top",asChild:j,...S},V)=>{const T=j?$.Slot:"button",n=u.useMemo(()=>!o&&l||f==="only"?"only":f,[o,l,f]),e=u.useMemo(()=>l?typeof l=="string"?{name:l}:l:null,[l]),x=n==="only"?{xl:"min-w-6 h-6",lg:"min-w-6 h-6",md:"min-w-5 h-5",sm:"min-w-4 h-4",xs:"min-w-3.5 h-3.5"}:{xl:"min-w-5 h-5",lg:"min-w-5 h-5",md:"min-w-4 h-4",sm:"min-w-4 h-4",xs:"min-w-3.5 h-3.5"},B=t.jsxRuntimeExports.jsx(t.jsxRuntimeExports.Fragment,{children:n==="only"?t.jsxRuntimeExports.jsx(t.jsxRuntimeExports.Fragment,{children:s?t.jsxRuntimeExports.jsx(r.IconComponent,{iconName:"IconLoader2",className:p.cn("animate-spin",x[i||"xl"])}):e&&t.jsxRuntimeExports.jsx(r.IconComponent,{iconName:e.name,stroke:e.stroke,iconText:c,size:24})}):t.jsxRuntimeExports.jsxs(t.jsxRuntimeExports.Fragment,{children:[t.jsxRuntimeExports.jsx("span",{className:`absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 ${s?"visible opacity-100":"invisible opacity-0"}`,children:t.jsxRuntimeExports.jsx(r.IconComponent,{iconName:"IconLoader2",className:p.cn("animate-spin",x[i||"xl"])})}),t.jsxRuntimeExports.jsxs("span",{className:p.cn("flex items-center justify-center gap-2",s?"invisible opacity-0":"visible opacity-100"),children:[e&&n==="left"&&t.jsxRuntimeExports.jsx(r.IconComponent,{iconName:e.name,iconText:c,stroke:e.stroke,className:x[i||"xl"]}),o,e&&n==="right"&&t.jsxRuntimeExports.jsx(r.IconComponent,{iconName:e.name,iconText:c,stroke:e.stroke,className:x[i||"xl"]})]})]})}),F=()=>{if(!j||!u.isValidElement(o)||!e&&n!=="only")return o;const m=o,A=m.props.children;if(n==="only")return u.cloneElement(m,{...m.props,children:s?t.jsxRuntimeExports.jsx(r.IconComponent,{iconName:"IconLoader2",className:p.cn("animate-spin",x[i||"xl"])}):e&&t.jsxRuntimeExports.jsx(r.IconComponent,{iconName:e.name,stroke:e.stroke,iconText:c,size:24})});const P=e&&t.jsxRuntimeExports.jsx(r.IconComponent,{iconName:e.name,iconText:c,stroke:e.stroke,className:x[i||"xl"]}),M=t.jsxRuntimeExports.jsxs(t.jsxRuntimeExports.Fragment,{children:[t.jsxRuntimeExports.jsx("span",{className:`absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 ${s?"visible opacity-100":"invisible opacity-0"}`,children:t.jsxRuntimeExports.jsx(r.IconComponent,{iconName:"IconLoader2",className:p.cn("animate-spin",x[i||"xl"])})}),t.jsxRuntimeExports.jsxs("span",{className:p.cn("flex items-center justify-center gap-2",s?"invisible opacity-0":"visible opacity-100"),children:[n==="left"&&P,A,n==="right"&&P]})]});return u.cloneElement(m,{...m.props,children:M})},g=t.jsxRuntimeExports.jsx(T,{ref:V,className:p.cn(s?C({variant:h,weight:y,size:i,rounded:v,iconPosition:n,className:b}):q?N({variant:h,weight:y,size:i,rounded:v,iconPosition:n,className:b}):z({variant:h,weight:y,size:i,rounded:v,iconPosition:n,className:b})),disabled:E||s,...S,children:j?F():B});return d&&(E||s)?t.jsxRuntimeExports.jsx(a.TooltipProvider,{children:t.jsxRuntimeExports.jsxs(a.Tooltip,{children:[t.jsxRuntimeExports.jsx(a.TooltipTrigger,{asChild:n==="only",children:n==="only"?t.jsxRuntimeExports.jsx("div",{className:"inline-block","aria-disabled":"true",children:g}):g}),t.jsxRuntimeExports.jsx(a.TooltipContent,{side:R,className:"text-muted-foreground",children:d})]})}):d?t.jsxRuntimeExports.jsx(a.TooltipProvider,{children:t.jsxRuntimeExports.jsxs(a.Tooltip,{children:[t.jsxRuntimeExports.jsx(a.TooltipTrigger,{asChild:n==="only",children:g}),t.jsxRuntimeExports.jsx(a.TooltipContent,{side:R,className:"text-muted-foreground",children:d})]})}):g});I.displayName="Button";exports.Button=I;exports.buttonActiveStyles=N;exports.buttonLoadingStyles=C;exports.buttonStyles=z;
@@ -1,174 +0,0 @@
1
- import { j as s } from "./jsx-runtime-DywqP_6a.js";
2
- import { L as j } from "./label-_kG7WBoJ.js";
3
- import { c as r } from "./index-CRiPKpXj.js";
4
- import { c as N } from "./index-BqtVL8d-.js";
5
- import * as y from "react";
6
- import { I as d } from "./icon-component-CxQsODCa.js";
7
- const I = N(
8
- "file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input flex w-full min-w-0 border bg-transparent transition-[color,box-shadow] outline-none file:inline-flex file:border-0 file:bg-transparent file:text-sm file:font-semibold disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50",
9
- {
10
- variants: {
11
- size: {
12
- sm: "text-label-md h-8 rounded-sm px-2 py-1",
13
- md: "text-label-lg h-12 rounded-md px-3 py-1",
14
- lg: "text-label-xl h-16 rounded-lg px-4 py-2"
15
- },
16
- rounded: {
17
- default: "",
18
- full: "rounded-full"
19
- },
20
- state: {
21
- default: "",
22
- error: "border-destructive ring-destructive/20 dark:ring-destructive/40",
23
- success: "border-success ring-success/20 dark:ring-success/40"
24
- }
25
- },
26
- defaultVariants: {
27
- size: "md",
28
- rounded: "default",
29
- state: "default"
30
- }
31
- }
32
- );
33
- function V({
34
- className: b,
35
- label: x,
36
- helperText: u,
37
- error: t,
38
- touched: i,
39
- iconName: f,
40
- iconPosition: n = "left",
41
- type: l = "text",
42
- size: g,
43
- rounded: v,
44
- state: z,
45
- containerClassName: p,
46
- ...e
47
- }) {
48
- const [o, w] = y.useState(!1), a = f ? ((m) => typeof m == "string" ? { name: m } : m)(f) : void 0, c = t && i ? "error" : i && !t && e.value ? "success" : "default", h = () => {
49
- w(!o);
50
- };
51
- return /* @__PURE__ */ s.jsxs("div", { className: r("flex flex-col gap-2", p), children: [
52
- x && /* @__PURE__ */ s.jsx(
53
- j,
54
- {
55
- htmlFor: e.id,
56
- className: r("mb-1", {
57
- "opacity-50": e.disabled
58
- }),
59
- children: x
60
- }
61
- ),
62
- /* @__PURE__ */ s.jsxs("div", { className: "relative w-full", children: [
63
- a && n === "left" && /* @__PURE__ */ s.jsx(
64
- "span",
65
- {
66
- className: r("absolute top-1/2 left-3 -translate-y-1/2", {
67
- "text-muted-foreground": c === "default",
68
- "text-destructive": c === "error",
69
- "text-success-main": c === "success",
70
- "text-muted-foreground opacity-50": e.disabled
71
- }),
72
- children: /* @__PURE__ */ s.jsx(
73
- d,
74
- {
75
- iconName: a.name,
76
- stroke: a.stroke,
77
- size: 20
78
- }
79
- )
80
- }
81
- ),
82
- /* @__PURE__ */ s.jsx(
83
- "input",
84
- {
85
- type: l === "password" ? o ? "text" : "password" : l,
86
- "data-slot": "input",
87
- "aria-describedby": e.id && u ? `${e.id}-helper-text` : void 0,
88
- "aria-invalid": !!(t && i),
89
- "aria-errormessage": e.id && t ? `${e.id}-error-text` : void 0,
90
- className: r(
91
- I({
92
- size: g,
93
- rounded: v,
94
- state: c,
95
- className: r(
96
- "focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]",
97
- a && n === "left" ? "pl-10" : "",
98
- a && n === "right" || l === "password" ? "pr-10" : "",
99
- l === "color" ? "h-[50px] p-0" : "",
100
- b
101
- )
102
- })
103
- ),
104
- ...e
105
- }
106
- ),
107
- l === "password" && /* @__PURE__ */ s.jsx(
108
- "button",
109
- {
110
- type: "button",
111
- tabIndex: -1,
112
- "aria-label": o ? "Hide password" : "Show password",
113
- className: "absolute top-1/2 right-3 -translate-y-1/2 rounded-md p-1 hover:bg-neutral-100/50 focus-visible:ring-[1.5px] focus-visible:ring-offset-1 focus-visible:outline-none",
114
- onClick: h,
115
- children: /* @__PURE__ */ s.jsx(
116
- d,
117
- {
118
- iconName: o ? "IconEyeOff" : "IconEye",
119
- size: 20
120
- }
121
- )
122
- }
123
- ),
124
- a && n === "right" && l !== "password" && /* @__PURE__ */ s.jsx("span", { className: "absolute top-1/2 right-3 -translate-y-1/2", children: /* @__PURE__ */ s.jsx(
125
- d,
126
- {
127
- iconName: a.name,
128
- stroke: a.stroke,
129
- size: 20
130
- }
131
- ) }),
132
- !a && t && i && l !== "password" && /* @__PURE__ */ s.jsx(
133
- d,
134
- {
135
- iconName: "IconAlertCircleFilled",
136
- size: 20,
137
- className: "text-destructive absolute top-1/2 right-3 -translate-y-1/2"
138
- }
139
- ),
140
- !a && i && !t && e.value && l !== "password" && /* @__PURE__ */ s.jsx(
141
- d,
142
- {
143
- iconName: "IconCircleCheckFilled",
144
- size: 20,
145
- className: "text-success-main absolute top-1/2 right-3 -translate-y-1/2"
146
- }
147
- )
148
- ] }),
149
- t && i ? /* @__PURE__ */ s.jsx(
150
- "span",
151
- {
152
- id: e.id && `${e.id}-error-text`,
153
- "aria-invalid": !0,
154
- className: "text-destructive text-label-md",
155
- children: t
156
- }
157
- ) : u ? /* @__PURE__ */ s.jsx(
158
- "span",
159
- {
160
- id: e.id && `${e.id}-helper-text`,
161
- className: r("text-label-md", {
162
- "text-muted-foreground": !t && !i,
163
- "text-destructive": t && i,
164
- "text-success-main": i && !t && e.value !== void 0,
165
- "text-muted-foreground opacity-50": e.disabled
166
- }),
167
- children: u
168
- }
169
- ) : null
170
- ] });
171
- }
172
- export {
173
- V as I
174
- };
@@ -1 +0,0 @@
1
- "use strict";const s=require("./jsx-runtime-BuHQgaKs.cjs"),h=require("./label-U5GnYvFO.cjs"),d=require("./index-DoxiiusW.cjs"),y=require("./index-C8P6Mn4U.cjs"),N=require("react"),c=require("./icon-component-D5YssRbR.cjs");function R(l){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(l){for(const a in l)if(a!=="default"){const t=Object.getOwnPropertyDescriptor(l,a);Object.defineProperty(o,a,t.get?t:{enumerable:!0,get:()=>l[a]})}}return o.default=l,Object.freeze(o)}const E=R(N),I=y.cva("file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input flex w-full min-w-0 border bg-transparent transition-[color,box-shadow] outline-none file:inline-flex file:border-0 file:bg-transparent file:text-sm file:font-semibold disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50",{variants:{size:{sm:"text-label-md h-8 rounded-sm px-2 py-1",md:"text-label-lg h-12 rounded-md px-3 py-1",lg:"text-label-xl h-16 rounded-lg px-4 py-2"},rounded:{default:"",full:"rounded-full"},state:{default:"",error:"border-destructive ring-destructive/20 dark:ring-destructive/40",success:"border-success ring-success/20 dark:ring-success/40"}},defaultVariants:{size:"md",rounded:"default",state:"default"}});function z({className:l,label:o,helperText:a,error:t,touched:i,iconName:b,iconPosition:u="left",type:r="text",size:p,rounded:g,state:k,containerClassName:j,...e}){const[x,v]=E.useState(!1),n=b?(f=>typeof f=="string"?{name:f}:f)(b):void 0,m=t&&i?"error":i&&!t&&e.value?"success":"default",w=()=>{v(!x)};return s.jsxRuntimeExports.jsxs("div",{className:d.cn("flex flex-col gap-2",j),children:[o&&s.jsxRuntimeExports.jsx(h.Label,{htmlFor:e.id,className:d.cn("mb-1",{"opacity-50":e.disabled}),children:o}),s.jsxRuntimeExports.jsxs("div",{className:"relative w-full",children:[n&&u==="left"&&s.jsxRuntimeExports.jsx("span",{className:d.cn("absolute top-1/2 left-3 -translate-y-1/2",{"text-muted-foreground":m==="default","text-destructive":m==="error","text-success-main":m==="success","text-muted-foreground opacity-50":e.disabled}),children:s.jsxRuntimeExports.jsx(c.IconComponent,{iconName:n.name,stroke:n.stroke,size:20})}),s.jsxRuntimeExports.jsx("input",{type:r==="password"?x?"text":"password":r,"data-slot":"input","aria-describedby":e.id&&a?`${e.id}-helper-text`:void 0,"aria-invalid":!!(t&&i),"aria-errormessage":e.id&&t?`${e.id}-error-text`:void 0,className:d.cn(I({size:p,rounded:g,state:m,className:d.cn("focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]",n&&u==="left"?"pl-10":"",n&&u==="right"||r==="password"?"pr-10":"",r==="color"?"h-[50px] p-0":"",l)})),...e}),r==="password"&&s.jsxRuntimeExports.jsx("button",{type:"button",tabIndex:-1,"aria-label":x?"Hide password":"Show password",className:"absolute top-1/2 right-3 -translate-y-1/2 rounded-md p-1 hover:bg-neutral-100/50 focus-visible:ring-[1.5px] focus-visible:ring-offset-1 focus-visible:outline-none",onClick:w,children:s.jsxRuntimeExports.jsx(c.IconComponent,{iconName:x?"IconEyeOff":"IconEye",size:20})}),n&&u==="right"&&r!=="password"&&s.jsxRuntimeExports.jsx("span",{className:"absolute top-1/2 right-3 -translate-y-1/2",children:s.jsxRuntimeExports.jsx(c.IconComponent,{iconName:n.name,stroke:n.stroke,size:20})}),!n&&t&&i&&r!=="password"&&s.jsxRuntimeExports.jsx(c.IconComponent,{iconName:"IconAlertCircleFilled",size:20,className:"text-destructive absolute top-1/2 right-3 -translate-y-1/2"}),!n&&i&&!t&&e.value&&r!=="password"&&s.jsxRuntimeExports.jsx(c.IconComponent,{iconName:"IconCircleCheckFilled",size:20,className:"text-success-main absolute top-1/2 right-3 -translate-y-1/2"})]}),t&&i?s.jsxRuntimeExports.jsx("span",{id:e.id&&`${e.id}-error-text`,"aria-invalid":!0,className:"text-destructive text-label-md",children:t}):a?s.jsxRuntimeExports.jsx("span",{id:e.id&&`${e.id}-helper-text`,className:d.cn("text-label-md",{"text-muted-foreground":!t&&!i,"text-destructive":t&&i,"text-success-main":i&&!t&&e.value!==void 0,"text-muted-foreground opacity-50":e.disabled}),children:a}):null]})}exports.Input=z;