// react-hook-form import { Controller } from "react-hook-form"; // components import { FormComponentProps, Input } from "components/custom-attributes"; // ui import { CustomSelect, ToggleSwitch } from "components/ui"; // constants import { DATE_FORMATS, TIME_FORMATS } from "constants/custom-attributes"; export const DateTimeAttributeForm: React.FC = ({ control }) => (
( )} />
( {DATE_FORMATS.find((f) => f.value === value)?.label} } value={value} onChange={onChange} buttonClassName="bg-custom-background-100 !px-3 !py-2 !border-custom-border-200 !rounded" optionsClassName="w-full" input > {DATE_FORMATS.map((format) => ( {format.label} ))} )} /> (
Don{"'"}t show date
)} />
( {TIME_FORMATS.find((f) => f.value === value)?.label} } value={value} onChange={onChange} buttonClassName="bg-custom-background-100 !px-3 !py-2 !border-custom-border-200 !rounded" optionsClassName="w-full" input > {TIME_FORMATS.map((format) => ( {format.label} ))} )} /> (
Don{"'"}t show time
)} />
);