import { DateRange } from '@dereekb/date';
import { Maybe } from '@dereekb/util';
import { ComponentStore } from '@ngrx/component-store';
import { CalendarEvent } from 'angular-calendar';
import { Observable } from 'rxjs';
import * as i0 from "@angular/core";
export declare enum CalendarDisplayType {
    MONTH = "month",
    WEEK = "week",
    DAY = "day"
}
export interface CalendarViewDateRange {
    readonly type: CalendarDisplayType;
    readonly start: Date;
    readonly end: Date;
    readonly distance: number;
    /**
     * Whether or not the min navigation date is currently visible. This implies that we're at the minimum date.
     */
    readonly isMinDateVisible: boolean;
    /**
     * Whether or not the maximum navigation date is visible. This implies that we're at the maximum date.
     */
    readonly isMaxDateVisible: boolean;
}
export declare function isCalendarViewDateRangeEqual(a: CalendarViewDateRange, b: CalendarViewDateRange): boolean;
export interface CalendarState<T = any> {
    /**
     * Calendar display mode
     */
    readonly type: CalendarDisplayType;
    /**
     * Whether or not to show the today button. Defaults to true.
     */
    readonly showTodayButton?: boolean;
    /**
     * Date that is selected.
     */
    readonly date: Date;
    /**
     * Whether or not the day was tapped/set twice.
     */
    readonly dateTappedTwice: boolean;
    /**
     * Set of calendar events.
     */
    readonly events: CalendarEvent<T>[];
    /**
     * Optional navigation range limitation that limits which dates can be navigated to.
     */
    readonly navigationRangeLimit?: Maybe<Partial<DateRange>>;
    /**
     * Whether or not to display the page buttons when applicable. Can only be displayed when a navigationRangeLimit is set.
     */
    readonly showPageButtons?: boolean;
}
export declare function visibleDateRangeForCalendarState(calendarState: CalendarState): CalendarViewDateRange;
export declare class DbxCalendarStore<T = any> extends ComponentStore<CalendarState<T>> {
    constructor();
    readonly tapFirstPage: (observableOrValue?: void | Observable<void> | undefined) => import("rxjs").Subscription;
    readonly tapNext: (observableOrValue?: void | Observable<void> | undefined) => import("rxjs").Subscription;
    readonly tapPrevious: (observableOrValue?: void | Observable<void> | undefined) => import("rxjs").Subscription;
    readonly tapLastPage: (observableOrValue?: void | Observable<void> | undefined) => import("rxjs").Subscription;
    readonly showTodayButton$: Observable<boolean | undefined>;
    readonly date$: Observable<Date>;
    readonly dateTappedTwice$: Observable<boolean>;
    readonly events$: Observable<CalendarEvent<T>[]>;
    /**
     * Returns the events that match the tapped date range state.
     */
    readonly eventsForDateState$: Observable<{
        date: Date;
        events: CalendarEvent<any>[];
        dateTappedTwice: boolean;
    }>;
    readonly eventsForDate$: Observable<CalendarEvent<any>[]>;
    readonly visibleDateRange$: Observable<CalendarViewDateRange>;
    readonly visibleEvents$: Observable<CalendarEvent<T>[]>;
    readonly isLookingAtToday$: Observable<boolean>;
    readonly isLookingAtMinimumDate$: Observable<boolean>;
    readonly isLookingAtMaximumDate$: Observable<boolean>;
    readonly hasMultiplePages$: Observable<boolean>;
    readonly displayType$: Observable<CalendarDisplayType>;
    readonly navigationRangeLimit$: Observable<Maybe<Partial<DateRange>>>;
    readonly minNavigationDate$: Observable<Maybe<Date>>;
    readonly maxNavigationDate$: Observable<Maybe<Date>>;
    readonly isTodayInNavigationRangeLimit$: Observable<boolean>;
    readonly canJumpToToday$: Observable<boolean>;
    readonly canShowPageButtons$: Observable<boolean | import("@dereekb/util").MaybeNot>;
    readonly showPageButtons$: Observable<boolean | import("@dereekb/util").MaybeNot>;
    /**
     * Tap a day.
     *
     * - If the same day is presented, dateTappedTwice is flipped.
     */
    readonly tapDay: (observableOrValue: Date | Observable<Date>) => import("rxjs").Subscription;
    /**
     * Set all events on the calendar.
     */
    readonly setEvents: (observableOrValue: CalendarEvent<T>[] | Observable<CalendarEvent<T>[]>) => import("rxjs").Subscription;
    /**
     * Set all events on the calendar.
     */
    readonly setDisplayType: (observableOrValue: CalendarDisplayType | Observable<CalendarDisplayType>) => import("rxjs").Subscription;
    /**
     * Sets the navigation limit.
     */
    readonly setNavigationRangeLimit: (() => void) | ((observableOrValue: Maybe<Partial<DateRange>> | Observable<Maybe<Partial<DateRange>>>) => import("rxjs").Subscription);
    readonly setShowTodayButton: (() => void) | ((observableOrValue: Maybe<boolean> | Observable<Maybe<boolean>>) => import("rxjs").Subscription);
    readonly setShowPageButtons: (() => void) | ((observableOrValue: Maybe<boolean> | Observable<Maybe<boolean>>) => import("rxjs").Subscription);
    static ɵfac: i0.ɵɵFactoryDeclaration<DbxCalendarStore<any>, never>;
    static ɵprov: i0.ɵɵInjectableDeclaration<DbxCalendarStore<any>>;
}
export declare function updateCalendarStateWithTappedDate(state: CalendarState, date: Date): CalendarState<any>;
export declare function updateCalendarStateWithNavigationRangeLimit(state: CalendarState, navigationRangeLimit: Maybe<Partial<DateRange>>): {
    navigationRangeLimit: Maybe<Partial<DateRange>>;
    type: CalendarDisplayType;
    showTodayButton?: boolean;
    date: Date;
    dateTappedTwice: boolean;
    events: CalendarEvent<any>[];
    showPageButtons?: boolean;
};
