@awsui/components-react
Version:
On July 19th, 2022, we launched [Cloudscape Design System](https://cloudscape.design). Cloudscape is an evolution of AWS-UI. It consists of user interface guidelines, front-end components, design resources, and development tools for building intuitive, en
17 lines • 786 B
TypeScript
import { CalendarProps } from '../calendar/interfaces';
import { MaskArgs } from '../internal/components/masked-input/utils/mask-format';
export interface GenerateMaskArgsProps extends Pick<CalendarProps, 'granularity'> {
isIso?: boolean;
}
export declare const generateMaskArgs: ({
granularity,
isIso
}?: GenerateMaskArgsProps) => MaskArgs;
/**
* Normalizes a partial ISO date string by trimming incomplete segments.
*
* @param dateString - The date string to normalize (e.g., "2012-", "2012-0", "2012-01-3").
* @param granularity - The level of detail required ('month' or 'day').
* @returns a properly formatted date string or empty string, if invalid.
*/
export declare function normalizeIsoDateString(dateString: string, granularity: CalendarProps.Granularity): string;