Skip to content
This repository was archived by the owner on May 15, 2025. It is now read-only.

Commit 5bdd10c

Browse files
authored
fix: Adjust sizing btw select && inputs on xs, sm, md, lg, xl (#97)
1 parent 066af3e commit 5bdd10c

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

src/components/extenders/Select.tsx

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -55,36 +55,36 @@ export const selectStyles = tv({
5555
},
5656
size: {
5757
xs: {
58-
base: "text-xs",
59-
value: "px-sm*2 py-xs*2",
58+
base: "text-xs py-xs*2 rounded-xs",
59+
value: "px-xs",
6060
icon: "text-sm",
6161
item: "px-md text-xs",
6262
prefixLabel: "text-xs",
6363
},
6464
sm: {
65-
base: "text-sm",
66-
value: "px-md py-sm",
65+
base: "text-sm px-sm py-sm rounded-sm",
66+
value: "py-sm",
6767
icon: "text-base",
6868
item: "px-md text-sm",
6969
prefixLabel: "text-sm",
7070
},
7171
md: {
72-
base: "text-md",
72+
base: "text-md rounded-md",
7373
value: "px-md text-md py-md",
7474
icon: "text-lg",
7575
item: "px-md text-md",
7676
prefixLabel: "text-sm",
7777
},
7878
lg: {
79-
base: "text-lg",
80-
value: "px-xl/2 py-lg",
79+
base: "text-lg py-sm*2 rounded-lg",
80+
value: "px-lg py-sm",
8181
icon: "text-xl",
8282
item: "px-lg text-lg",
8383
prefixLabel: "text-base",
8484
},
8585
xl: {
86-
base: "text-xl",
87-
value: "px-sm*2 py-lg",
86+
base: "text-3xl py-md*2 rounded-xl",
87+
value: "px-lg py-xs",
8888
icon: "text-xl",
8989
item: "px-xl text-xl",
9090
prefixLabel: "text-lg",

src/components/primitives/Input.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ function Input({ look, size, state, inputClassName, className, ...props }: Input
9696
</label>
9797
)}
9898
</label>
99-
<Group>{error}</Group>
99+
{!!error && <Group>{error}</Group>}
100100
</Group>
101101
);
102102
return (
@@ -108,7 +108,7 @@ function Input({ look, size, state, inputClassName, className, ...props }: Input
108108
onChange={e => state?.[1]?.(e?.target?.value)}
109109
{...rest}
110110
/>
111-
<Group className="flex-col">{error}</Group>{" "}
111+
{!!error && <Group className="flex-col">{error}</Group>}
112112
</Group>
113113
);
114114
}

0 commit comments

Comments
 (0)