@uplink-protocol/calendar-controller
Version:
Flexible calendar and time picker API supporting both calendar, date-picker, and time-picker integrations for any JavaScript framework or library
58 lines (57 loc) • 2.06 kB
TypeScript
import { ILocalizationService, IDateFormattingService } from "../interfaces";
import { CalendarStateManager } from "./state-manager";
import { BindingsCoordinator } from "./bindings-coordinator";
import { CalendarControllerBindings } from "../types";
import { CalendarGetters } from "../types/getters.type";
/**
* LocalizationCoordinator
* Handles all localization and locale-related operations
*/
export declare class LocalizationCoordinator {
private stateManager;
private bindingsCoordinator;
private localizationService;
private dateFormattingService;
private hasCustomFormatOptions;
constructor(stateManager: CalendarStateManager, bindingsCoordinator: BindingsCoordinator, localizationService: ILocalizationService, dateFormattingService: IDateFormattingService);
/**
* Set the locale for the calendar
*/
setLocale(locale: string, bindings: CalendarControllerBindings, getters: CalendarGetters, applyDefaults?: boolean): void;
/**
* Get current locale
*/
getLocale(): string;
/**
* Set date format
*/
setDateFormat(format: string | null, bindings: CalendarControllerBindings, getters: CalendarGetters): void;
/**
* Get date format
*/
getDateFormat(): string | null;
/**
* Set date format options
*/
setDateFormatOptions(options: Intl.DateTimeFormatOptions | null, bindings: CalendarControllerBindings, getters: CalendarGetters): void;
/**
* Get date format options
*/
getDateFormatOptions(): Intl.DateTimeFormatOptions | null;
/**
* Set first day of week
*/
setFirstDayOfWeek(day: number, bindings: CalendarControllerBindings, getters: CalendarGetters): void;
/**
* Get first day of week
*/
getFirstDayOfWeek(): number;
/**
* Set hide other month days option
*/
setHideOtherMonthDays(hide: boolean, bindings: CalendarControllerBindings, getters: CalendarGetters): void;
/**
* Get hide other month days option
*/
getHideOtherMonthDays(): boolean;
}