@payfit/unity-components
Version:
116 lines (115 loc) • 2.86 kB
TypeScript
import { CalendarDate } from '@internationalized/date';
import { ReactElement } from 'react';
import { DateFieldProps } from 'react-aria-components/DateField';
export declare const dateSegment: import('tailwind-variants').TVReturnType<{
isPlaceholder: {
true: string[];
false: "uy:text-content-form-enabled";
};
isLiteral: {
true: "uy:text-content-neutral-lowest-enabled";
false: "";
};
}, undefined, string[], {
isPlaceholder: {
true: string[];
false: "uy:text-content-form-enabled";
};
isLiteral: {
true: "uy:text-content-neutral-lowest-enabled";
false: "";
};
}, undefined, import('tailwind-variants').TVReturnTypeLike<{
isPlaceholder: {
true: string[];
false: "uy:text-content-form-enabled";
};
isLiteral: {
true: "uy:text-content-neutral-lowest-enabled";
false: "";
};
}, undefined>>;
export declare const dateInput: import('tailwind-variants').TVReturnType<{
isInvalid: {
true: {
base: string;
state: string;
};
};
isReadOnly: {
true: {
base: string;
};
};
isDisabled: {
true: {
base: string;
};
};
}, {
base: string;
input: string;
state: string;
}, undefined, {
isInvalid: {
true: {
base: string;
state: string;
};
};
isReadOnly: {
true: {
base: string;
};
};
isDisabled: {
true: {
base: string;
};
};
}, {
base: string;
input: string;
state: string;
}, import('tailwind-variants').TVReturnTypeLike<{
isInvalid: {
true: {
base: string;
state: string;
};
};
isReadOnly: {
true: {
base: string;
};
};
isDisabled: {
true: {
base: string;
};
};
}, {
base: string;
input: string;
state: string;
}>>;
export interface DateInputProps extends DateFieldProps<CalendarDate> {
/** Element to display after the input field */
suffix?: ReactElement;
/** Whether the field is required */
isRequired?: boolean;
/** Whether the field is in an invalid state */
isInvalid?: boolean;
/** Whether the field is in a loading state */
isLoading?: boolean;
/** Whether the field is disabled */
isDisabled?: boolean;
/** Whether the field is read-only */
isReadOnly?: boolean;
/** Clear button click handler */
onClearButtonPress?: () => void;
}
export declare function DateInput({ isLoading, isInvalid, isReadOnly, isDisabled, onClearButtonPress, }: DateInputProps): import("react/jsx-runtime").JSX.Element;
export declare namespace DateInput {
var displayName: string;
}