fix(component): input style (#2285)

This commit is contained in:
Himself65
2023-05-10 04:01:29 +08:00
committed by GitHub
parent b978bb171a
commit a84ca43ce2
+2 -1
View File
@@ -37,6 +37,7 @@ export const Input = forwardRef<HTMLInputElement, inputProps>(function Input(
width, width,
onChange, onChange,
noBorder = false, noBorder = false,
className,
...otherProps ...otherProps
}: inputProps, }: inputProps,
ref: ForwardedRef<HTMLInputElement> ref: ForwardedRef<HTMLInputElement>
@@ -51,7 +52,7 @@ export const Input = forwardRef<HTMLInputElement, inputProps>(function Input(
return ( return (
<input <input
className={clsx(inputStyle, otherProps.className)} className={clsx(inputStyle, className)}
style={assignInlineVars({ style={assignInlineVars({
[widthVar]: width ? `${width}px` : '100%', [widthVar]: width ? `${width}px` : '100%',
[heightVar]: height ? `${height}px` : 'unset', [heightVar]: height ? `${height}px` : 'unset',