@mindly/ui-components 8.5.0 → 8.5.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,11 +1,15 @@
1
- import { SupportedLocales } from '../types';
2
- type CalendarListProps = {
3
- locale?: SupportedLocales;
4
- lastDate: Date;
5
- };
6
- type CalendarListItem = {
7
- value: Date;
1
+ type SelectionItem<T extends string | number> = {
8
2
  label: string;
3
+ value: T;
4
+ };
5
+ type CalendarSelections = {
6
+ day: SelectionItem<number>[];
7
+ month: SelectionItem<string>[];
8
+ year: SelectionItem<number>[];
9
+ };
10
+ type CalendarListProps = {
11
+ locale?: string;
12
+ lastDate?: Date;
9
13
  };
10
- export declare function useCalendarListData({ locale, lastDate, }: CalendarListProps): CalendarListItem[];
14
+ export declare function useCalendarListData({ locale, lastDate, }: CalendarListProps): CalendarSelections;
11
15
  export {};
@@ -10,7 +10,12 @@ type DatesResultType = {
10
10
  isFutureMonth: boolean;
11
11
  };
12
12
  export declare function getDatePosition(calendarDate: Date): DatesResultType;
13
- export declare function getSelectedFormattedDate(date: Date, locale?: string): string;
13
+ type CalendarDefaults = {
14
+ day: string;
15
+ month: string;
16
+ year: string;
17
+ };
18
+ export declare function getSelectedFormattedDate(selectedDate: Date | null | undefined, locale?: string): CalendarDefaults;
14
19
  type FormattedDateProps = {
15
20
  date: Date;
16
21
  locale?: SupportedLocales;
@@ -7,9 +7,10 @@ type Props = {
7
7
  height?: number;
8
8
  selections: Record<string, SelectionType[]>;
9
9
  defaults?: Record<string, string>;
10
- onChange(value: Record<string, SelectionType>): void;
10
+ onChange(value: Record<string, string>): void;
11
11
  className?: string;
12
12
  compareBy?: 'value' | 'label';
13
+ presentation?: 'date' | 'month' | 'month-year';
13
14
  };
14
- declare const DrumListPicker: ({ height, selections, defaults, onChange, className, compareBy, }: Props) => import("react/jsx-runtime").JSX.Element;
15
+ declare const DrumListPicker: ({ height, selections, defaults, onChange, className, compareBy, presentation, }: Props) => import("react/jsx-runtime").JSX.Element;
15
16
  export default DrumListPicker;
@@ -16,4 +16,6 @@ export type SpecialistCardWithScheduleWidgetProps = {
16
16
  onScheduleSlotChange?: (slot: ScheduleSlot | null) => void;
17
17
  onScheduleShowAll?: () => void;
18
18
  };
19
+ shouldAnimateNotice?: boolean;
20
+ isNoticeReady?: boolean;
19
21
  };