This commit is contained in:
Elio Bischof
2023-06-05 13:02:36 +02:00
parent c71046dc66
commit 4ca1d60f0f
38 changed files with 10214 additions and 226 deletions

View File

@@ -8,6 +8,7 @@ import React, {
InputHTMLAttributes,
ReactNode,
} from "react";
import { v4 as uuidv4 } from 'uuid'
export type TextInputProps = DetailedHTMLProps<
InputHTMLAttributes<HTMLInputElement>,
@@ -54,12 +55,12 @@ export const TextInput = forwardRef<HTMLInputElement, TextInputProps>(
},
ref
) => {
const id = uuidv4()
return (
<label className="flex flex-col text-12px text-input-light-label dark:text-input-dark-label">
<span
className={`leading-3 mb-1 ${
error ? "text-warn-light-500 dark:text-warn-dark-500" : ""
}`}
className={`leading-3 mb-1 ${error ? "text-warn-light-500 dark:text-warn-dark-500" : ""
}`}
>
{label} {required && "*"}
</span>