import { TextField as Kobalte } from "@kobalte/core/text-field" import { Show, splitProps } from "solid-js" import type { ComponentProps } from "solid-js" export interface InputProps extends ComponentProps, Partial< Pick< ComponentProps, | "name" | "defaultValue" | "value" | "onChange" | "onKeyDown" | "validationState" | "required" | "disabled" | "readOnly" > > { label?: string hideLabel?: boolean hidden?: boolean description?: string error?: string variant?: "normal" | "ghost" } export function Input(props: InputProps) { const [local, others] = splitProps(props, [ "name", "defaultValue", "value", "onChange", "onKeyDown", "validationState", "required", "disabled", "readOnly", "class", "label", "hidden", "hideLabel", "description", "error", "variant", ]) return ( {local.label} {local.description} {local.error} ) }