@dereekb/dbx-web 9.24.19 → 9.24.21
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.
- package/calendar/esm2020/lib/calendar.store.mjs +2 -2
- package/calendar/fesm2015/dereekb-dbx-web-calendar.mjs +1 -1
- package/calendar/fesm2015/dereekb-dbx-web-calendar.mjs.map +1 -1
- package/calendar/fesm2020/dereekb-dbx-web-calendar.mjs +1 -1
- package/calendar/fesm2020/dereekb-dbx-web-calendar.mjs.map +1 -1
- package/calendar/package.json +2 -2
- package/esm2020/calendar/lib/calendar.store.mjs +2 -2
- package/esm2020/mapbox/lib/index.mjs +2 -1
- package/esm2020/mapbox/lib/mapbox.layout.component.mjs +13 -9
- package/esm2020/mapbox/lib/mapbox.layout.resize.sync.directive.mjs +38 -0
- package/esm2020/mapbox/lib/mapbox.module.mjs +5 -1
- package/esm2020/mapbox/lib/mapbox.store.mjs +61 -26
- package/fesm2015/dereekb-dbx-web-calendar.mjs +1 -1
- package/fesm2015/dereekb-dbx-web-calendar.mjs.map +1 -1
- package/fesm2015/dereekb-dbx-web-mapbox.mjs +109 -34
- package/fesm2015/dereekb-dbx-web-mapbox.mjs.map +1 -1
- package/fesm2020/dereekb-dbx-web-calendar.mjs +1 -1
- package/fesm2020/dereekb-dbx-web-calendar.mjs.map +1 -1
- package/fesm2020/dereekb-dbx-web-mapbox.mjs +107 -34
- package/fesm2020/dereekb-dbx-web-mapbox.mjs.map +1 -1
- package/mapbox/esm2020/lib/index.mjs +2 -1
- package/mapbox/esm2020/lib/mapbox.layout.component.mjs +13 -9
- package/mapbox/esm2020/lib/mapbox.layout.resize.sync.directive.mjs +38 -0
- package/mapbox/esm2020/lib/mapbox.module.mjs +5 -1
- package/mapbox/esm2020/lib/mapbox.store.mjs +61 -26
- package/mapbox/fesm2015/dereekb-dbx-web-mapbox.mjs +109 -34
- package/mapbox/fesm2015/dereekb-dbx-web-mapbox.mjs.map +1 -1
- package/mapbox/fesm2020/dereekb-dbx-web-mapbox.mjs +107 -34
- package/mapbox/fesm2020/dereekb-dbx-web-mapbox.mjs.map +1 -1
- package/mapbox/lib/index.d.ts +1 -0
- package/mapbox/lib/mapbox.layout.component.d.ts +3 -1
- package/mapbox/lib/mapbox.layout.resize.sync.directive.d.ts +15 -0
- package/mapbox/lib/mapbox.module.d.ts +18 -17
- package/mapbox/lib/mapbox.store.d.ts +31 -13
- package/mapbox/package.json +3 -3
- package/package.json +3 -3
- package/table/package.json +3 -3
|
@@ -103,7 +103,7 @@ class DbxCalendarStore extends ComponentStore {
|
|
|
103
103
|
}))));
|
|
104
104
|
});
|
|
105
105
|
// MARK: Accessors
|
|
106
|
-
this.showTodayButton$ = this.state$.pipe(map((x) => x.showTodayButton), distinctUntilChanged(), shareReplay());
|
|
106
|
+
this.showTodayButton$ = this.state$.pipe(map((x) => x.showTodayButton), distinctUntilChanged(), shareReplay(1));
|
|
107
107
|
this.date$ = this.state$.pipe(map((x) => x.date));
|
|
108
108
|
this.dateTappedTwice$ = this.state$.pipe(map((x) => x.dateTappedTwice));
|
|
109
109
|
this.events$ = this.state$.pipe(map((x) => x.events));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dereekb-dbx-web-calendar.mjs","sources":["../../../../packages/dbx-web/calendar/src/lib/calendar.store.ts","../../../../packages/dbx-web/calendar/src/lib/calendar.ts","../../../../packages/dbx-web/calendar/src/lib/calendar.base.component.ts","../../../../packages/dbx-web/calendar/src/lib/calendar.base.component.html","../../../../packages/dbx-web/calendar/src/lib/calendar.component.ts","../../../../packages/dbx-web/calendar/src/lib/calendar.component.html","../../../../packages/dbx-web/calendar/src/lib/calendar.module.ts","../../../../packages/dbx-web/calendar/src/dereekb-dbx-web-calendar.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\nimport { clampDateToDateRange, DateRange, isDateInDateRange, isFullDateRange, isSameDateDay, isSameDateRange } from '@dereekb/date';\nimport { invertDecision, Maybe, reduceBooleansWithAndFn } from '@dereekb/util';\nimport { ComponentStore } from '@ngrx/component-store';\nimport { CalendarEvent } from 'angular-calendar';\nimport { differenceInDays, addDays, endOfDay, endOfMonth, endOfWeek, isSameDay, startOfDay, startOfMonth, startOfWeek, isBefore, isAfter } from 'date-fns';\nimport { Observable, distinctUntilChanged, first, map, shareReplay, switchMap, tap, combineLatest } from 'rxjs';\n\nexport enum CalendarDisplayType {\n MONTH = 'month',\n WEEK = 'week',\n DAY = 'day'\n}\n\nexport interface CalendarViewDateRange {\n type: CalendarDisplayType;\n start: Date;\n end: Date;\n distance: number;\n /**\n * Whether or not the min navigation date is currently visible. This implies that we're at the minimum date.\n */\n isMinDateVisible: boolean;\n /**\n * Whether or not the maximum navigation date is visible. This implies that we're at the maximum date.\n */\n isMaxDateVisible: boolean;\n}\n\nexport interface CalendarState<T = any> {\n /**\n * Calendar display mode\n */\n readonly type: CalendarDisplayType;\n /**\n * Whether or not to show the today button. Defaults to true.\n */\n readonly showTodayButton?: boolean;\n /**\n * Date that is selected.\n */\n readonly date: Date;\n /**\n * Whether or not the day was tapped/set twice.\n */\n readonly dateTappedTwice: boolean;\n /**\n * Set of calendar events.\n */\n readonly events: CalendarEvent<T>[];\n /**\n * Optional navigation range limitation that limits which dates can be navigated to.\n */\n readonly navigationRangeLimit?: Maybe<Partial<DateRange>>;\n /**\n * Whether or not to display the page buttons when applicable. Can only be displayed when a navigationRangeLimit is set.\n */\n readonly showPageButtons?: boolean;\n}\n\nexport function visibleDateRangeForCalendarState(calendarState: CalendarState): CalendarViewDateRange {\n const { navigationRangeLimit, type, date } = calendarState;\n let start: Date;\n let end: Date;\n let distance: number;\n\n switch (type) {\n case CalendarDisplayType.MONTH:\n start = startOfDay(startOfWeek(startOfMonth(date), { weekStartsOn: 0 }));\n end = endOfWeek(endOfMonth(date));\n distance = differenceInDays(end, start) + 1;\n break;\n case CalendarDisplayType.WEEK:\n start = startOfWeek(date);\n end = endOfWeek(start);\n distance = 7; // 7 days in a week.\n break;\n case CalendarDisplayType.DAY:\n start = startOfDay(date);\n end = endOfDay(date);\n distance = 1;\n break;\n }\n\n const isMinDateVisible: boolean = navigationRangeLimit?.start != null ? !isAfter(start, navigationRangeLimit.start) : false;\n const isMaxDateVisible: boolean = navigationRangeLimit?.end != null ? !isBefore(end, navigationRangeLimit.end) : false;\n\n // TODO: Consider changing min/max date visible logical utility to be fully within the current month or not,\n // not just visible, since it can change to a locked out calendar and doesn't feel as UI friendly.\n\n return {\n type,\n start,\n end,\n distance,\n isMinDateVisible,\n isMaxDateVisible\n };\n}\n\nconst distinctUntilDateOrTypeOrEventsChanged = distinctUntilChanged<CalendarState>((a, b) => a?.date === b?.date && a?.type === b?.type && a?.events === b?.events);\n\n@Injectable()\nexport class DbxCalendarStore<T = any> extends ComponentStore<CalendarState<T>> {\n constructor() {\n super({\n type: CalendarDisplayType.MONTH,\n showTodayButton: true,\n date: new Date(),\n dateTappedTwice: false,\n events: []\n });\n }\n\n // MARK: Effects\n readonly tapFirstPage = this.effect((input: Observable<void>) => {\n return input.pipe(\n switchMap(() =>\n this.minNavigationDate$.pipe(\n first(),\n tap((x) => {\n if (x) {\n this.tapDay(x);\n }\n })\n )\n )\n );\n });\n\n readonly tapNext = this.effect((input: Observable<void>) => {\n return input.pipe(\n switchMap(() =>\n this.visibleDateRange$.pipe(\n first(),\n tap(({ end, isMaxDateVisible }) => {\n if (!isMaxDateVisible) {\n this.tapDay(addDays(end, 1));\n }\n })\n )\n )\n );\n });\n\n readonly tapPrevious = this.effect((input: Observable<void>) => {\n return input.pipe(\n switchMap(() =>\n this.visibleDateRange$.pipe(\n first(),\n tap(({ start, isMinDateVisible }) => {\n if (!isMinDateVisible) {\n this.tapDay(addDays(start, -1));\n }\n })\n )\n )\n );\n });\n\n readonly tapLastPage = this.effect((input: Observable<void>) => {\n return input.pipe(\n switchMap(() =>\n this.maxNavigationDate$.pipe(\n first(),\n tap((x) => {\n if (x) {\n this.tapDay(x);\n }\n })\n )\n )\n );\n });\n\n // MARK: Accessors\n\n readonly showTodayButton$ = this.state$.pipe(\n map((x) => x.showTodayButton),\n distinctUntilChanged(),\n shareReplay()\n );\n\n readonly date$ = this.state$.pipe(map((x) => x.date));\n readonly dateTappedTwice$ = this.state$.pipe(map((x) => x.dateTappedTwice));\n\n readonly events$ = this.state$.pipe(map((x) => x.events));\n\n // TODO: Filter to be events that will only be displayed based on the current calendar.\n readonly visibleEvents$ = this.state$.pipe(\n map((x) => x.events),\n shareReplay(1)\n );\n\n readonly eventsForDateState$ = this.state$.pipe(\n distinctUntilDateOrTypeOrEventsChanged,\n map((state) => ({\n date: state.date,\n events: state.events.filter((x) => isSameDay(x.start, state.date) || (x.end && isBefore(x.start, state.date) && isAfter(x.end, state.date))),\n dateTappedTwice: state.dateTappedTwice\n })),\n shareReplay(1)\n );\n\n readonly eventsForDate$ = this.eventsForDateState$.pipe(map((state) => state.events));\n\n readonly visibleDateRange$: Observable<CalendarViewDateRange> = this.state$.pipe(\n // If the date or type changes, check again.\n distinctUntilChanged((a, b) => a?.date === b?.date && a?.type === b?.type),\n map(visibleDateRangeForCalendarState),\n distinctUntilChanged((a, b) => {\n if (a.type === b.type) {\n return isSameDay(a.start, b.start);\n } else {\n return false; // Type changed, date range changed.\n }\n }),\n shareReplay(1)\n );\n\n readonly isLookingAtToday$ = this.visibleDateRange$.pipe(\n map((x) => isDateInDateRange(new Date(), x)),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly isLookingAtMinimumDate$ = this.visibleDateRange$.pipe(\n map((x) => x.isMinDateVisible),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly isLookingAtMaximumDate$ = this.visibleDateRange$.pipe(\n map((x) => x.isMaxDateVisible),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly hasMultiplePages$ = combineLatest([this.isLookingAtMinimumDate$, this.isLookingAtMaximumDate$]).pipe(map(invertDecision(reduceBooleansWithAndFn(true))), distinctUntilChanged(), shareReplay(1));\n\n readonly displayType$ = this.state$.pipe(\n map((x) => x.type),\n distinctUntilChanged((a, b) => a === b),\n shareReplay(1)\n );\n\n readonly navigationRangeLimit$ = this.state$.pipe(\n map((x) => x.navigationRangeLimit),\n distinctUntilChanged(isSameDateRange),\n shareReplay(1)\n );\n\n readonly minNavigationDate$: Observable<Maybe<Date>> = this.navigationRangeLimit$.pipe(\n map((x) => x?.start),\n distinctUntilChanged(isSameDateDay),\n shareReplay(1)\n );\n\n readonly maxNavigationDate$: Observable<Maybe<Date>> = this.navigationRangeLimit$.pipe(\n map((x) => x?.end),\n distinctUntilChanged(isSameDateDay),\n shareReplay(1)\n );\n\n readonly isTodayInNavigationRangeLimit$ = this.navigationRangeLimit$.pipe(\n map((x) => isDateInDateRange(new Date(), x ?? {})),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly canJumpToToday$ = combineLatest([this.isLookingAtToday$, this.isTodayInNavigationRangeLimit$]).pipe(\n map(([isLookingAtToday, isTodayInNavigationRangeLimit]) => !isLookingAtToday && isTodayInNavigationRangeLimit),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly canShowPageButtons$ = this.state$.pipe(\n map((x) => x.showPageButtons && x.navigationRangeLimit && isFullDateRange(x.navigationRangeLimit)),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly showPageButtons$ = combineLatest([this.canShowPageButtons$, this.isLookingAtMinimumDate$, this.isLookingAtMaximumDate$]).pipe(\n map(([canShowPageButtons, isLookingAtMinimumDate, isLookingAtMaximumDate]) => {\n return canShowPageButtons && !(isLookingAtMinimumDate && isLookingAtMaximumDate);\n }),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n // MARK: State Changes\n /**\n * Tap a day.\n *\n * - If the same day is presented, dateTappedTwice is flipped.\n */\n readonly tapDay = this.updater((state, date: Date) => updateCalendarStateWithTappedDate(state, date));\n\n /**\n * Set all events on the calendar.\n */\n readonly setEvents = this.updater((state, events: CalendarEvent<T>[]) => ({ ...state, events }));\n\n /**\n * Set all events on the calendar.\n */\n readonly setDisplayType = this.updater((state, type: CalendarDisplayType) => ({ ...state, type }));\n\n /**\n * Sets the navigation limit.\n */\n readonly setNavigationRangeLimit = this.updater((state, navigationRangeLimit: Maybe<Partial<DateRange>>) => updateCalendarStateWithNavigationRangeLimit(state, navigationRangeLimit));\n\n readonly setShowTodayButton = this.updater((state, showTodayButton: Maybe<boolean>) => ({ ...state, showTodayButton: showTodayButton != null ? showTodayButton : true }));\n readonly setShowPageButtons = this.updater((state, showPageButtons: Maybe<boolean>) => ({ ...state, showPageButtons: showPageButtons != null ? showPageButtons : false }));\n}\n\nexport function updateCalendarStateWithTappedDate(state: CalendarState, date: Date) {\n // only update the date if it is different\n if (!isSameDateDay(state.date, date)) {\n // Only update the date if it is within the date range\n if (!state.navigationRangeLimit || isDateInDateRange(date, state.navigationRangeLimit)) {\n state = { ...state, date, dateTappedTwice: isSameDay(date, state.date) ? !state.dateTappedTwice : false };\n }\n }\n\n return state;\n}\n\nexport function updateCalendarStateWithNavigationRangeLimit(state: CalendarState, navigationRangeLimit: Maybe<Partial<DateRange>>) {\n const { date } = state;\n\n // cap the date if it doesn't fall within the range.\n if (navigationRangeLimit && !isDateInDateRange(date, navigationRangeLimit)) {\n const clampedDate = clampDateToDateRange(date, navigationRangeLimit);\n return { ...state, date: clampedDate, navigationRangeLimit };\n } else {\n return { ...state, navigationRangeLimit };\n }\n}\n","import { formatToTimeAndDurationString, sortDateRangeStartAscendingCompareFunction } from '@dereekb/date';\nimport { CalendarEvent } from 'angular-calendar';\n\nexport interface DbxCalendarEvent<T> {\n event: CalendarEvent<T>;\n action?: string;\n}\n\nfunction timeSubtitleForEvent(event: CalendarEvent): string {\n let subtitle;\n\n if (event.allDay) {\n subtitle = `(All Day)`;\n } else {\n subtitle = formatToTimeAndDurationString(event.start, event.end ?? new Date());\n }\n\n return subtitle;\n}\n\nexport function prepareAndSortCalendarEvents(events: CalendarEvent[]): CalendarEvent[] {\n return events\n .map((event: CalendarEvent) => {\n const subtitle = timeSubtitleForEvent(event);\n let title;\n\n if (event.allDay) {\n title = event.title + ' ' + subtitle;\n } else {\n title = `${event.title} - ${subtitle}`;\n }\n\n return {\n ...event,\n title\n };\n })\n .sort(sortDateRangeStartAscendingCompareFunction);\n}\n","import { Component } from '@angular/core';\nimport { isSameMonth } from 'date-fns';\nimport { DbxCalendarStore } from './calendar.store';\nimport { map, withLatestFrom } from 'rxjs';\nimport { MatButtonToggleChange } from '@angular/material/button-toggle';\n\n@Component({\n selector: 'dbx-calendar-base',\n templateUrl: './calendar.base.component.html'\n})\nexport class DbxCalendarBaseComponent<T> {\n readonly viewDate$ = this.calendarStore.date$;\n\n readonly showTodayButton$ = this.calendarStore.showTodayButton$;\n readonly canJumpToToday$ = this.calendarStore.canJumpToToday$;\n\n readonly isLookingAtMinimumDate$ = this.calendarStore.isLookingAtMinimumDate$;\n readonly isLookingAtMaximumDate$ = this.calendarStore.isLookingAtMaximumDate$;\n readonly hasMultiplePages$ = this.calendarStore.hasMultiplePages$;\n\n readonly showPageButtons$ = this.calendarStore.showPageButtons$;\n\n readonly activeDayIsOpen$ = this.calendarStore.eventsForDateState$.pipe(\n withLatestFrom(this.calendarStore.date$),\n map(([x, date]) => {\n if (x.events.length && isSameMonth(x.date, date)) {\n return !x.dateTappedTwice;\n }\n\n return false;\n })\n );\n\n readonly displayType$ = this.calendarStore.displayType$;\n\n constructor(public readonly calendarStore: DbxCalendarStore<T>) {}\n\n todayClicked(): void {\n this.calendarStore.tapDay(new Date());\n }\n\n firstPageButtonClicked(): void {\n this.calendarStore.tapFirstPage();\n }\n\n nextButtonClicked(): void {\n this.calendarStore.tapNext();\n }\n\n previousButtonClicked(): void {\n this.calendarStore.tapPrevious();\n }\n\n lastPageButtonClicked(): void {\n this.calendarStore.tapLastPage();\n }\n\n typeToggleChanged(event: MatButtonToggleChange): void {\n this.calendarStore.setDisplayType(event.value);\n }\n}\n","<div class=\"dbx-calendar\">\n <h3 class=\"dbx-calendar-title\">{{ (viewDate$ | async)! | calendarDate: (displayType$ | async) + 'ViewTitle':'en' }}</h3>\n <div class=\"dbx-calendar-header\">\n <div class=\"dbx-calendar-controls\" fxLayout=\"row\" fxLayout.xs=\"column\" ngClass.xs=\"dbx-calendar-controls-compact\">\n <span class=\"dbx-calendar-controls-left\" fxFlex=\"nogrow\">\n <button *ngIf=\"showTodayButton$ | async\" mat-stroked-button [disabled]=\"!(canJumpToToday$ | async)\" (click)=\"todayClicked()\">Today</button>\n <dbx-button-spacer></dbx-button-spacer>\n <div class=\"d-iblock\" *ngIf=\"hasMultiplePages$ | async\">\n <button *ngIf=\"showPageButtons$ | async\" mat-icon-button [disabled]=\"isLookingAtMinimumDate$ | async\" aria-label=\"first page button\" (click)=\"firstPageButtonClicked()\">\n <mat-icon>first_page</mat-icon>\n </button>\n <button mat-icon-button [disabled]=\"isLookingAtMinimumDate$ | async\" [attr.aria-label]=\"'Previous ' + (displayType$ | async) + ' button'\" (click)=\"previousButtonClicked()\">\n <mat-icon>navigate_before</mat-icon>\n </button>\n <button mat-icon-button [disabled]=\"isLookingAtMaximumDate$ | async\" [attr.aria-label]=\"'Next' + (displayType$ | async)! + ' button'\" (click)=\"nextButtonClicked()\">\n <mat-icon>navigate_next</mat-icon>\n </button>\n <button *ngIf=\"showPageButtons$ | async\" mat-icon-button [disabled]=\"isLookingAtMaximumDate$ | async\" aria-label=\"last page button\" (click)=\"lastPageButtonClicked()\">\n <mat-icon>last_page</mat-icon>\n </button>\n </div>\n </span>\n <span class=\"spacer\"></span>\n <span class=\"dbx-calendar-controls-right\" fxFlex=\"nogrow\">\n <ng-content select=\"[controls]\"></ng-content>\n </span>\n </div>\n </div>\n <ng-content></ng-content>\n</div>\n","import { Component, EventEmitter, Output, OnDestroy } from '@angular/core';\nimport { isSameMonth } from 'date-fns';\nimport { CalendarEvent } from 'angular-calendar';\nimport { DbxCalendarStore } from './calendar.store';\nimport { distinctUntilChanged, map, shareReplay, withLatestFrom } from 'rxjs';\nimport { MatButtonToggleChange } from '@angular/material/button-toggle';\nimport { DbxCalendarEvent, prepareAndSortCalendarEvents } from './calendar';\n\n@Component({\n selector: 'dbx-calendar',\n templateUrl: './calendar.component.html'\n})\nexport class DbxCalendarComponent<T> implements OnDestroy {\n @Output()\n clickEvent = new EventEmitter<DbxCalendarEvent<T>>();\n\n readonly viewDate$ = this.calendarStore.date$;\n\n readonly events$ = this.calendarStore.visibleEvents$.pipe(map(prepareAndSortCalendarEvents), shareReplay(1));\n\n readonly activeDayIsOpen$ = this.calendarStore.eventsForDateState$.pipe(\n withLatestFrom(this.calendarStore.date$),\n map(([x, date]) => {\n if (x.events.length && isSameMonth(x.date, date)) {\n return !x.dateTappedTwice;\n }\n\n return false;\n }),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly displayType$ = this.calendarStore.displayType$;\n\n constructor(readonly calendarStore: DbxCalendarStore<T>) {}\n\n ngOnDestroy(): void {\n this.clickEvent.complete();\n }\n\n todayClicked(): void {\n this.dayClicked({ date: new Date() });\n }\n\n nextButtonClicked(): void {\n this.calendarStore.tapNext();\n }\n\n previousButtonClicked(): void {\n this.calendarStore.tapPrevious();\n }\n\n dayClicked({ date }: { date: Date }): void {\n this.calendarStore.tapDay(date);\n }\n\n eventClicked(action: string, event: CalendarEvent<T>): void {\n this.clickEvent.emit({ action, event });\n }\n\n typeToggleChanged(event: MatButtonToggleChange): void {\n this.calendarStore.setDisplayType(event.value);\n }\n}\n","<dbx-calendar-base>\n <ng-container controls>\n <mat-button-toggle-group name=\"calendarDisplayStyle\" [value]=\"(displayType$ | async)!\" (change)=\"typeToggleChanged($event)\" aria-label=\"Display Style\">\n <mat-button-toggle value=\"month\">Month</mat-button-toggle>\n <mat-button-toggle value=\"week\">Week</mat-button-toggle>\n <mat-button-toggle value=\"day\">Day</mat-button-toggle>\n </mat-button-toggle-group>\n </ng-container>\n <div class=\"dbx-calendar-content\" [ngClass]=\"'dbx-calendar-content-' + (displayType$ | async)!\" [ngSwitch]=\"displayType$ | async\">\n <mwl-calendar-month-view *ngSwitchCase=\"'month'\" [viewDate]=\"(viewDate$ | async)!\" [events]=\"(events$ | async)!\" [activeDayIsOpen]=\"(activeDayIsOpen$ | async)!\" (dayClicked)=\"dayClicked($event.day)\" (eventClicked)=\"eventClicked('Clicked', $event.event)\"></mwl-calendar-month-view>\n <mwl-calendar-week-view *ngSwitchCase=\"'week'\" [viewDate]=\"(viewDate$ | async)!\" [events]=\"(events$ | async)!\" (eventClicked)=\"eventClicked('Clicked', $event.event)\"></mwl-calendar-week-view>\n <mwl-calendar-day-view *ngSwitchCase=\"'day'\" [viewDate]=\"(viewDate$ | async)!\" [events]=\"(events$ | async)!\" (eventClicked)=\"eventClicked('Clicked', $event.event)\"></mwl-calendar-day-view>\n </div>\n</dbx-calendar-base>\n","import { NgModule } from '@angular/core';\nimport { DbxCalendarComponent } from './calendar.component';\nimport { CalendarDayModule, CalendarModule, CalendarWeekModule, DateAdapter } from 'angular-calendar';\nimport { CommonModule } from '@angular/common';\nimport { DbxButtonModule, DbxPopoverInteractionModule } from '@dereekb/dbx-web';\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatButtonToggleModule } from '@angular/material/button-toggle';\nimport { adapterFactory as dateAdapterFactory } from 'angular-calendar/date-adapters/date-fns';\nimport { MatButtonModule } from '@angular/material/button';\nimport { FlexLayoutModule } from '@angular/flex-layout';\nimport { DbxCalendarBaseComponent } from './calendar.base.component';\n\nconst declarations = [\n //\n DbxCalendarBaseComponent,\n DbxCalendarComponent\n];\n\n@NgModule({\n imports: [\n //\n CommonModule,\n MatIconModule,\n MatButtonModule,\n MatButtonToggleModule,\n DbxButtonModule,\n DbxPopoverInteractionModule,\n CalendarModule,\n CalendarDayModule,\n FlexLayoutModule,\n CalendarWeekModule\n ],\n declarations,\n exports: declarations\n})\nexport class DbxCalendarModule {}\n\n/**\n * Provides default configuration for the DbxCalendarModule\n */\n@NgModule({\n imports: [CalendarModule.forRoot({ provide: DateAdapter, useFactory: dateAdapterFactory })],\n exports: [DbxCalendarModule]\n})\nexport class DbxCalendarRootModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1.DbxCalendarStore","i8","i3","i4","i5","i6.DbxCalendarBaseComponent","dateAdapterFactory"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;IAQY,oBAIX;AAJD,CAAA,UAAY,mBAAmB,EAAA;AAC7B,IAAA,mBAAA,CAAA,OAAA,CAAA,GAAA,OAAe,CAAA;AACf,IAAA,mBAAA,CAAA,MAAA,CAAA,GAAA,MAAa,CAAA;AACb,IAAA,mBAAA,CAAA,KAAA,CAAA,GAAA,KAAW,CAAA;AACb,CAAC,EAJW,mBAAmB,KAAnB,mBAAmB,GAI9B,EAAA,CAAA,CAAA,CAAA;AAgDK,SAAU,gCAAgC,CAAC,aAA4B,EAAA;IAC3E,MAAM,EAAE,oBAAoB,EAAE,IAAI,EAAE,IAAI,EAAE,GAAG,aAAa,CAAC;AAC3D,IAAA,IAAI,KAAW,CAAC;AAChB,IAAA,IAAI,GAAS,CAAC;AACd,IAAA,IAAI,QAAgB,CAAC;AAErB,IAAA,QAAQ,IAAI;QACV,KAAK,mBAAmB,CAAC,KAAK;AAC5B,YAAA,KAAK,GAAG,UAAU,CAAC,WAAW,CAAC,YAAY,CAAC,IAAI,CAAC,EAAE,EAAE,YAAY,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;YACzE,GAAG,GAAG,SAAS,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC;YAClC,QAAQ,GAAG,gBAAgB,CAAC,GAAG,EAAE,KAAK,CAAC,GAAG,CAAC,CAAC;YAC5C,MAAM;QACR,KAAK,mBAAmB,CAAC,IAAI;AAC3B,YAAA,KAAK,GAAG,WAAW,CAAC,IAAI,CAAC,CAAC;AAC1B,YAAA,GAAG,GAAG,SAAS,CAAC,KAAK,CAAC,CAAC;AACvB,YAAA,QAAQ,GAAG,CAAC,CAAC;YACb,MAAM;QACR,KAAK,mBAAmB,CAAC,GAA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AAqB,4CATrB,iBAAiB,CAAA,EAAA,CAAA,CAAA;AASjB,qBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,qBAAqB,YAHtB,cAAc,CAAC,OAAO,CAAC,EAAE,OAAO,EAAE,WAAW,EAAE,UAAU,EAAEC,cAAkB,EAAE,CAAC,EAN/E,iBAAiB,CAAA,EAAA,CAAA,CAAA;4FASjB,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBAJjC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,cAAc,CAAC,OAAO,CAAC,EAAE,OAAO,EAAE,WAAW,EAAE,UAAU,EAAEA,cAAkB,EAAE,CAAC,CAAC;oBAC3F,OAAO,EAAE,CAAC,iBAAiB,CAAC;AAC7B,iBAAA,CAAA;;;AC3CD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"dereekb-dbx-web-calendar.mjs","sources":["../../../../packages/dbx-web/calendar/src/lib/calendar.store.ts","../../../../packages/dbx-web/calendar/src/lib/calendar.ts","../../../../packages/dbx-web/calendar/src/lib/calendar.base.component.ts","../../../../packages/dbx-web/calendar/src/lib/calendar.base.component.html","../../../../packages/dbx-web/calendar/src/lib/calendar.component.ts","../../../../packages/dbx-web/calendar/src/lib/calendar.component.html","../../../../packages/dbx-web/calendar/src/lib/calendar.module.ts","../../../../packages/dbx-web/calendar/src/dereekb-dbx-web-calendar.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\nimport { clampDateToDateRange, DateRange, isDateInDateRange, isFullDateRange, isSameDateDay, isSameDateRange } from '@dereekb/date';\nimport { invertDecision, Maybe, reduceBooleansWithAndFn } from '@dereekb/util';\nimport { ComponentStore } from '@ngrx/component-store';\nimport { CalendarEvent } from 'angular-calendar';\nimport { differenceInDays, addDays, endOfDay, endOfMonth, endOfWeek, isSameDay, startOfDay, startOfMonth, startOfWeek, isBefore, isAfter } from 'date-fns';\nimport { Observable, distinctUntilChanged, first, map, shareReplay, switchMap, tap, combineLatest } from 'rxjs';\n\nexport enum CalendarDisplayType {\n MONTH = 'month',\n WEEK = 'week',\n DAY = 'day'\n}\n\nexport interface CalendarViewDateRange {\n type: CalendarDisplayType;\n start: Date;\n end: Date;\n distance: number;\n /**\n * Whether or not the min navigation date is currently visible. This implies that we're at the minimum date.\n */\n isMinDateVisible: boolean;\n /**\n * Whether or not the maximum navigation date is visible. This implies that we're at the maximum date.\n */\n isMaxDateVisible: boolean;\n}\n\nexport interface CalendarState<T = any> {\n /**\n * Calendar display mode\n */\n readonly type: CalendarDisplayType;\n /**\n * Whether or not to show the today button. Defaults to true.\n */\n readonly showTodayButton?: boolean;\n /**\n * Date that is selected.\n */\n readonly date: Date;\n /**\n * Whether or not the day was tapped/set twice.\n */\n readonly dateTappedTwice: boolean;\n /**\n * Set of calendar events.\n */\n readonly events: CalendarEvent<T>[];\n /**\n * Optional navigation range limitation that limits which dates can be navigated to.\n */\n readonly navigationRangeLimit?: Maybe<Partial<DateRange>>;\n /**\n * Whether or not to display the page buttons when applicable. Can only be displayed when a navigationRangeLimit is set.\n */\n readonly showPageButtons?: boolean;\n}\n\nexport function visibleDateRangeForCalendarState(calendarState: CalendarState): CalendarViewDateRange {\n const { navigationRangeLimit, type, date } = calendarState;\n let start: Date;\n let end: Date;\n let distance: number;\n\n switch (type) {\n case CalendarDisplayType.MONTH:\n start = startOfDay(startOfWeek(startOfMonth(date), { weekStartsOn: 0 }));\n end = endOfWeek(endOfMonth(date));\n distance = differenceInDays(end, start) + 1;\n break;\n case CalendarDisplayType.WEEK:\n start = startOfWeek(date);\n end = endOfWeek(start);\n distance = 7; // 7 days in a week.\n break;\n case CalendarDisplayType.DAY:\n start = startOfDay(date);\n end = endOfDay(date);\n distance = 1;\n break;\n }\n\n const isMinDateVisible: boolean = navigationRangeLimit?.start != null ? !isAfter(start, navigationRangeLimit.start) : false;\n const isMaxDateVisible: boolean = navigationRangeLimit?.end != null ? !isBefore(end, navigationRangeLimit.end) : false;\n\n // TODO: Consider changing min/max date visible logical utility to be fully within the current month or not,\n // not just visible, since it can change to a locked out calendar and doesn't feel as UI friendly.\n\n return {\n type,\n start,\n end,\n distance,\n isMinDateVisible,\n isMaxDateVisible\n };\n}\n\nconst distinctUntilDateOrTypeOrEventsChanged = distinctUntilChanged<CalendarState>((a, b) => a?.date === b?.date && a?.type === b?.type && a?.events === b?.events);\n\n@Injectable()\nexport class DbxCalendarStore<T = any> extends ComponentStore<CalendarState<T>> {\n constructor() {\n super({\n type: CalendarDisplayType.MONTH,\n showTodayButton: true,\n date: new Date(),\n dateTappedTwice: false,\n events: []\n });\n }\n\n // MARK: Effects\n readonly tapFirstPage = this.effect((input: Observable<void>) => {\n return input.pipe(\n switchMap(() =>\n this.minNavigationDate$.pipe(\n first(),\n tap((x) => {\n if (x) {\n this.tapDay(x);\n }\n })\n )\n )\n );\n });\n\n readonly tapNext = this.effect((input: Observable<void>) => {\n return input.pipe(\n switchMap(() =>\n this.visibleDateRange$.pipe(\n first(),\n tap(({ end, isMaxDateVisible }) => {\n if (!isMaxDateVisible) {\n this.tapDay(addDays(end, 1));\n }\n })\n )\n )\n );\n });\n\n readonly tapPrevious = this.effect((input: Observable<void>) => {\n return input.pipe(\n switchMap(() =>\n this.visibleDateRange$.pipe(\n first(),\n tap(({ start, isMinDateVisible }) => {\n if (!isMinDateVisible) {\n this.tapDay(addDays(start, -1));\n }\n })\n )\n )\n );\n });\n\n readonly tapLastPage = this.effect((input: Observable<void>) => {\n return input.pipe(\n switchMap(() =>\n this.maxNavigationDate$.pipe(\n first(),\n tap((x) => {\n if (x) {\n this.tapDay(x);\n }\n })\n )\n )\n );\n });\n\n // MARK: Accessors\n\n readonly showTodayButton$ = this.state$.pipe(\n map((x) => x.showTodayButton),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly date$ = this.state$.pipe(map((x) => x.date));\n readonly dateTappedTwice$ = this.state$.pipe(map((x) => x.dateTappedTwice));\n\n readonly events$ = this.state$.pipe(map((x) => x.events));\n\n // TODO: Filter to be events that will only be displayed based on the current calendar.\n readonly visibleEvents$ = this.state$.pipe(\n map((x) => x.events),\n shareReplay(1)\n );\n\n readonly eventsForDateState$ = this.state$.pipe(\n distinctUntilDateOrTypeOrEventsChanged,\n map((state) => ({\n date: state.date,\n events: state.events.filter((x) => isSameDay(x.start, state.date) || (x.end && isBefore(x.start, state.date) && isAfter(x.end, state.date))),\n dateTappedTwice: state.dateTappedTwice\n })),\n shareReplay(1)\n );\n\n readonly eventsForDate$ = this.eventsForDateState$.pipe(map((state) => state.events));\n\n readonly visibleDateRange$: Observable<CalendarViewDateRange> = this.state$.pipe(\n // If the date or type changes, check again.\n distinctUntilChanged((a, b) => a?.date === b?.date && a?.type === b?.type),\n map(visibleDateRangeForCalendarState),\n distinctUntilChanged((a, b) => {\n if (a.type === b.type) {\n return isSameDay(a.start, b.start);\n } else {\n return false; // Type changed, date range changed.\n }\n }),\n shareReplay(1)\n );\n\n readonly isLookingAtToday$ = this.visibleDateRange$.pipe(\n map((x) => isDateInDateRange(new Date(), x)),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly isLookingAtMinimumDate$ = this.visibleDateRange$.pipe(\n map((x) => x.isMinDateVisible),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly isLookingAtMaximumDate$ = this.visibleDateRange$.pipe(\n map((x) => x.isMaxDateVisible),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly hasMultiplePages$ = combineLatest([this.isLookingAtMinimumDate$, this.isLookingAtMaximumDate$]).pipe(map(invertDecision(reduceBooleansWithAndFn(true))), distinctUntilChanged(), shareReplay(1));\n\n readonly displayType$ = this.state$.pipe(\n map((x) => x.type),\n distinctUntilChanged((a, b) => a === b),\n shareReplay(1)\n );\n\n readonly navigationRangeLimit$ = this.state$.pipe(\n map((x) => x.navigationRangeLimit),\n distinctUntilChanged(isSameDateRange),\n shareReplay(1)\n );\n\n readonly minNavigationDate$: Observable<Maybe<Date>> = this.navigationRangeLimit$.pipe(\n map((x) => x?.start),\n distinctUntilChanged(isSameDateDay),\n shareReplay(1)\n );\n\n readonly maxNavigationDate$: Observable<Maybe<Date>> = this.navigationRangeLimit$.pipe(\n map((x) => x?.end),\n distinctUntilChanged(isSameDateDay),\n shareReplay(1)\n );\n\n readonly isTodayInNavigationRangeLimit$ = this.navigationRangeLimit$.pipe(\n map((x) => isDateInDateRange(new Date(), x ?? {})),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly canJumpToToday$ = combineLatest([this.isLookingAtToday$, this.isTodayInNavigationRangeLimit$]).pipe(\n map(([isLookingAtToday, isTodayInNavigationRangeLimit]) => !isLookingAtToday && isTodayInNavigationRangeLimit),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly canShowPageButtons$ = this.state$.pipe(\n map((x) => x.showPageButtons && x.navigationRangeLimit && isFullDateRange(x.navigationRangeLimit)),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly showPageButtons$ = combineLatest([this.canShowPageButtons$, this.isLookingAtMinimumDate$, this.isLookingAtMaximumDate$]).pipe(\n map(([canShowPageButtons, isLookingAtMinimumDate, isLookingAtMaximumDate]) => {\n return canShowPageButtons && !(isLookingAtMinimumDate && isLookingAtMaximumDate);\n }),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n // MARK: State Changes\n /**\n * Tap a day.\n *\n * - If the same day is presented, dateTappedTwice is flipped.\n */\n readonly tapDay = this.updater((state, date: Date) => updateCalendarStateWithTappedDate(state, date));\n\n /**\n * Set all events on the calendar.\n */\n readonly setEvents = this.updater((state, events: CalendarEvent<T>[]) => ({ ...state, events }));\n\n /**\n * Set all events on the calendar.\n */\n readonly setDisplayType = this.updater((state, type: CalendarDisplayType) => ({ ...state, type }));\n\n /**\n * Sets the navigation limit.\n */\n readonly setNavigationRangeLimit = this.updater((state, navigationRangeLimit: Maybe<Partial<DateRange>>) => updateCalendarStateWithNavigationRangeLimit(state, navigationRangeLimit));\n\n readonly setShowTodayButton = this.updater((state, showTodayButton: Maybe<boolean>) => ({ ...state, showTodayButton: showTodayButton != null ? showTodayButton : true }));\n readonly setShowPageButtons = this.updater((state, showPageButtons: Maybe<boolean>) => ({ ...state, showPageButtons: showPageButtons != null ? showPageButtons : false }));\n}\n\nexport function updateCalendarStateWithTappedDate(state: CalendarState, date: Date) {\n // only update the date if it is different\n if (!isSameDateDay(state.date, date)) {\n // Only update the date if it is within the date range\n if (!state.navigationRangeLimit || isDateInDateRange(date, state.navigationRangeLimit)) {\n state = { ...state, date, dateTappedTwice: isSameDay(date, state.date) ? !state.dateTappedTwice : false };\n }\n }\n\n return state;\n}\n\nexport function updateCalendarStateWithNavigationRangeLimit(state: CalendarState, navigationRangeLimit: Maybe<Partial<DateRange>>) {\n const { date } = state;\n\n // cap the date if it doesn't fall within the range.\n if (navigationRangeLimit && !isDateInDateRange(date, navigationRangeLimit)) {\n const clampedDate = clampDateToDateRange(date, navigationRangeLimit);\n return { ...state, date: clampedDate, navigationRangeLimit };\n } else {\n return { ...state, navigationRangeLimit };\n }\n}\n","import { formatToTimeAndDurationString, sortDateRangeStartAscendingCompareFunction } from '@dereekb/date';\nimport { CalendarEvent } from 'angular-calendar';\n\nexport interface DbxCalendarEvent<T> {\n event: CalendarEvent<T>;\n action?: string;\n}\n\nfunction timeSubtitleForEvent(event: CalendarEvent): string {\n let subtitle;\n\n if (event.allDay) {\n subtitle = `(All Day)`;\n } else {\n subtitle = formatToTimeAndDurationString(event.start, event.end ?? new Date());\n }\n\n return subtitle;\n}\n\nexport function prepareAndSortCalendarEvents(events: CalendarEvent[]): CalendarEvent[] {\n return events\n .map((event: CalendarEvent) => {\n const subtitle = timeSubtitleForEvent(event);\n let title;\n\n if (event.allDay) {\n title = event.title + ' ' + subtitle;\n } else {\n title = `${event.title} - ${subtitle}`;\n }\n\n return {\n ...event,\n title\n };\n })\n .sort(sortDateRangeStartAscendingCompareFunction);\n}\n","import { Component } from '@angular/core';\nimport { isSameMonth } from 'date-fns';\nimport { DbxCalendarStore } from './calendar.store';\nimport { map, withLatestFrom } from 'rxjs';\nimport { MatButtonToggleChange } from '@angular/material/button-toggle';\n\n@Component({\n selector: 'dbx-calendar-base',\n templateUrl: './calendar.base.component.html'\n})\nexport class DbxCalendarBaseComponent<T> {\n readonly viewDate$ = this.calendarStore.date$;\n\n readonly showTodayButton$ = this.calendarStore.showTodayButton$;\n readonly canJumpToToday$ = this.calendarStore.canJumpToToday$;\n\n readonly isLookingAtMinimumDate$ = this.calendarStore.isLookingAtMinimumDate$;\n readonly isLookingAtMaximumDate$ = this.calendarStore.isLookingAtMaximumDate$;\n readonly hasMultiplePages$ = this.calendarStore.hasMultiplePages$;\n\n readonly showPageButtons$ = this.calendarStore.showPageButtons$;\n\n readonly activeDayIsOpen$ = this.calendarStore.eventsForDateState$.pipe(\n withLatestFrom(this.calendarStore.date$),\n map(([x, date]) => {\n if (x.events.length && isSameMonth(x.date, date)) {\n return !x.dateTappedTwice;\n }\n\n return false;\n })\n );\n\n readonly displayType$ = this.calendarStore.displayType$;\n\n constructor(public readonly calendarStore: DbxCalendarStore<T>) {}\n\n todayClicked(): void {\n this.calendarStore.tapDay(new Date());\n }\n\n firstPageButtonClicked(): void {\n this.calendarStore.tapFirstPage();\n }\n\n nextButtonClicked(): void {\n this.calendarStore.tapNext();\n }\n\n previousButtonClicked(): void {\n this.calendarStore.tapPrevious();\n }\n\n lastPageButtonClicked(): void {\n this.calendarStore.tapLastPage();\n }\n\n typeToggleChanged(event: MatButtonToggleChange): void {\n this.calendarStore.setDisplayType(event.value);\n }\n}\n","<div class=\"dbx-calendar\">\n <h3 class=\"dbx-calendar-title\">{{ (viewDate$ | async)! | calendarDate: (displayType$ | async) + 'ViewTitle':'en' }}</h3>\n <div class=\"dbx-calendar-header\">\n <div class=\"dbx-calendar-controls\" fxLayout=\"row\" fxLayout.xs=\"column\" ngClass.xs=\"dbx-calendar-controls-compact\">\n <span class=\"dbx-calendar-controls-left\" fxFlex=\"nogrow\">\n <button *ngIf=\"showTodayButton$ | async\" mat-stroked-button [disabled]=\"!(canJumpToToday$ | async)\" (click)=\"todayClicked()\">Today</button>\n <dbx-button-spacer></dbx-button-spacer>\n <div class=\"d-iblock\" *ngIf=\"hasMultiplePages$ | async\">\n <button *ngIf=\"showPageButtons$ | async\" mat-icon-button [disabled]=\"isLookingAtMinimumDate$ | async\" aria-label=\"first page button\" (click)=\"firstPageButtonClicked()\">\n <mat-icon>first_page</mat-icon>\n </button>\n <button mat-icon-button [disabled]=\"isLookingAtMinimumDate$ | async\" [attr.aria-label]=\"'Previous ' + (displayType$ | async) + ' button'\" (click)=\"previousButtonClicked()\">\n <mat-icon>navigate_before</mat-icon>\n </button>\n <button mat-icon-button [disabled]=\"isLookingAtMaximumDate$ | async\" [attr.aria-label]=\"'Next' + (displayType$ | async)! + ' button'\" (click)=\"nextButtonClicked()\">\n <mat-icon>navigate_next</mat-icon>\n </button>\n <button *ngIf=\"showPageButtons$ | async\" mat-icon-button [disabled]=\"isLookingAtMaximumDate$ | async\" aria-label=\"last page button\" (click)=\"lastPageButtonClicked()\">\n <mat-icon>last_page</mat-icon>\n </button>\n </div>\n </span>\n <span class=\"spacer\"></span>\n <span class=\"dbx-calendar-controls-right\" fxFlex=\"nogrow\">\n <ng-content select=\"[controls]\"></ng-content>\n </span>\n </div>\n </div>\n <ng-content></ng-content>\n</div>\n","import { Component, EventEmitter, Output, OnDestroy } from '@angular/core';\nimport { isSameMonth } from 'date-fns';\nimport { CalendarEvent } from 'angular-calendar';\nimport { DbxCalendarStore } from './calendar.store';\nimport { distinctUntilChanged, map, shareReplay, withLatestFrom } from 'rxjs';\nimport { MatButtonToggleChange } from '@angular/material/button-toggle';\nimport { DbxCalendarEvent, prepareAndSortCalendarEvents } from './calendar';\n\n@Component({\n selector: 'dbx-calendar',\n templateUrl: './calendar.component.html'\n})\nexport class DbxCalendarComponent<T> implements OnDestroy {\n @Output()\n clickEvent = new EventEmitter<DbxCalendarEvent<T>>();\n\n readonly viewDate$ = this.calendarStore.date$;\n\n readonly events$ = this.calendarStore.visibleEvents$.pipe(map(prepareAndSortCalendarEvents), shareReplay(1));\n\n readonly activeDayIsOpen$ = this.calendarStore.eventsForDateState$.pipe(\n withLatestFrom(this.calendarStore.date$),\n map(([x, date]) => {\n if (x.events.length && isSameMonth(x.date, date)) {\n return !x.dateTappedTwice;\n }\n\n return false;\n }),\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n readonly displayType$ = this.calendarStore.displayType$;\n\n constructor(readonly calendarStore: DbxCalendarStore<T>) {}\n\n ngOnDestroy(): void {\n this.clickEvent.complete();\n }\n\n todayClicked(): void {\n this.dayClicked({ date: new Date() });\n }\n\n nextButtonClicked(): void {\n this.calendarStore.tapNext();\n }\n\n previousButtonClicked(): void {\n this.calendarStore.tapPrevious();\n }\n\n dayClicked({ date }: { date: Date }): void {\n this.calendarStore.tapDay(date);\n }\n\n eventClicked(action: string, event: CalendarEvent<T>): void {\n this.clickEvent.emit({ action, event });\n }\n\n typeToggleChanged(event: MatButtonToggleChange): void {\n this.calendarStore.setDisplayType(event.value);\n }\n}\n","<dbx-calendar-base>\n <ng-container controls>\n <mat-button-toggle-group name=\"calendarDisplayStyle\" [value]=\"(displayType$ | async)!\" (change)=\"typeToggleChanged($event)\" aria-label=\"Display Style\">\n <mat-button-toggle value=\"month\">Month</mat-button-toggle>\n <mat-button-toggle value=\"week\">Week</mat-button-toggle>\n <mat-button-toggle value=\"day\">Day</mat-button-toggle>\n </mat-button-toggle-group>\n </ng-container>\n <div class=\"dbx-calendar-content\" [ngClass]=\"'dbx-calendar-content-' + (displayType$ | async)!\" [ngSwitch]=\"displayType$ | async\">\n <mwl-calendar-month-view *ngSwitchCase=\"'month'\" [viewDate]=\"(viewDate$ | async)!\" [events]=\"(events$ | async)!\" [activeDayIsOpen]=\"(activeDayIsOpen$ | async)!\" (dayClicked)=\"dayClicked($event.day)\" (eventClicked)=\"eventClicked('Clicked', $event.event)\"></mwl-calendar-month-view>\n <mwl-calendar-week-view *ngSwitchCase=\"'week'\" [viewDate]=\"(viewDate$ | async)!\" [events]=\"(events$ | async)!\" (eventClicked)=\"eventClicked('Clicked', $event.event)\"></mwl-calendar-week-view>\n <mwl-calendar-day-view *ngSwitchCase=\"'day'\" [viewDate]=\"(viewDate$ | async)!\" [events]=\"(events$ | async)!\" (eventClicked)=\"eventClicked('Clicked', $event.event)\"></mwl-calendar-day-view>\n </div>\n</dbx-calendar-base>\n","import { NgModule } from '@angular/core';\nimport { DbxCalendarComponent } from './calendar.component';\nimport { CalendarDayModule, CalendarModule, CalendarWeekModule, DateAdapter } from 'angular-calendar';\nimport { CommonModule } from '@angular/common';\nimport { DbxButtonModule, DbxPopoverInteractionModule } from '@dereekb/dbx-web';\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatButtonToggleModule } from '@angular/material/button-toggle';\nimport { adapterFactory as dateAdapterFactory } from 'angular-calendar/date-adapters/date-fns';\nimport { MatButtonModule } from '@angular/material/button';\nimport { FlexLayoutModule } from '@angular/flex-layout';\nimport { DbxCalendarBaseComponent } from './calendar.base.component';\n\nconst declarations = [\n //\n DbxCalendarBaseComponent,\n DbxCalendarComponent\n];\n\n@NgModule({\n imports: [\n //\n CommonModule,\n MatIconModule,\n MatButtonModule,\n MatButtonToggleModule,\n DbxButtonModule,\n DbxPopoverInteractionModule,\n CalendarModule,\n CalendarDayModule,\n FlexLayoutModule,\n CalendarWeekModule\n ],\n declarations,\n exports: declarations\n})\nexport class DbxCalendarModule {}\n\n/**\n * Provides default configuration for the DbxCalendarModule\n */\n@NgModule({\n imports: [CalendarModule.forRoot({ provide: DateAdapter, useFactory: dateAdapterFactory })],\n exports: [DbxCalendarModule]\n})\nexport class DbxCalendarRootModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1.DbxCalendarStore","i8","i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AA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,qBAAqB,YAHtB,cAAc,CAAC,OAAO,CAAC,EAAE,OAAO,EAAE,WAAW,EAAE,UAAU,EAAEC,cAAkB,EAAE,CAAC,EAN/E,iBAAiB,CAAA,EAAA,CAAA,CAAA;4FASjB,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBAJjC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,cAAc,CAAC,OAAO,CAAC,EAAE,OAAO,EAAE,WAAW,EAAE,UAAU,EAAEA,cAAkB,EAAE,CAAC,CAAC;oBAC3F,OAAO,EAAE,CAAC,iBAAiB,CAAC;AAC7B,iBAAA,CAAA;;;AC3CD;;AAEG;;;;"}
|
|
@@ -4,7 +4,7 @@ import * as i2 from '@dereekb/dbx-core';
|
|
|
4
4
|
import { safeMarkForCheck, safeDetectChanges, AbstractSubscriptionDirective, DbxInjectionComponentModule } from '@dereekb/dbx-core';
|
|
5
5
|
import { asObservable, cleanup, filterMaybe, onTrueToFalse, SubscriptionObject, distinctUntilMapHasDifferentKeys } from '@dereekb/rxjs';
|
|
6
6
|
import { distinctUntilChanged, switchMap, map, combineLatestWith, shareReplay, NEVER, defaultIfEmpty, tap, EMPTY, of, combineLatest, filter, first, startWith, interval, Subject, merge, throttleTime, BehaviorSubject } from 'rxjs';
|
|
7
|
-
import { LAT_LONG_10M_PRECISION, latLngPointFunction, roundNumberToStepFunction, latLngBoundFunction, latLngBoundFromInput, filterUndefinedValues, isSameLatLngPoint, isDefaultLatLngPoint, swMostLatLngPoint, neMostLatLngPoint, isSameLatLngBound, diffLatLngBoundPoints, latLngBoundWrapsMap, isWithinLatLngBoundFunction, overlapsLatLngBoundFunction,
|
|
7
|
+
import { LAT_LONG_10M_PRECISION, latLngPointFunction, roundNumberToStepFunction, latLngBoundFunction, latLngBoundFromInput, filterUndefinedValues, isSameLatLngPoint, isSameVector, isDefaultLatLngPoint, swMostLatLngPoint, neMostLatLngPoint, isSameLatLngBound, diffLatLngBoundPoints, latLngBoundWrapsMap, isWithinLatLngBoundFunction, overlapsLatLngBoundFunction, latLngBoundCenterPoint, addLatLngPoints, vectorMinimumSizeResizeFunction, latLngPoint, DestroyFunctionObject, getValueFromGetter } from '@dereekb/util';
|
|
8
8
|
import { ComponentStore } from '@ngrx/component-store';
|
|
9
9
|
import * as MapboxGl from 'mapbox-gl';
|
|
10
10
|
import { bounds } from '@mapbox/geo-viewport';
|
|
@@ -159,7 +159,8 @@ class DbxMapboxMapStore extends ComponentStore {
|
|
|
159
159
|
moveState: 'init',
|
|
160
160
|
zoomState: 'init',
|
|
161
161
|
rotateState: 'init',
|
|
162
|
-
retainContent: true
|
|
162
|
+
retainContent: true,
|
|
163
|
+
useVirtualBound: true
|
|
163
164
|
});
|
|
164
165
|
this.dbxMapboxService = dbxMapboxService;
|
|
165
166
|
this.safeLatLngPoint = latLngPointFunction({ wrap: true });
|
|
@@ -425,16 +426,48 @@ class DbxMapboxMapStore extends ComponentStore {
|
|
|
425
426
|
}
|
|
426
427
|
}), shareReplay(1));
|
|
427
428
|
this.whenInitialized$ = this.isInitialized$.pipe(filter((x) => true), shareReplay(1));
|
|
428
|
-
this.isRendering$ = this.whenInitialized$.pipe(switchMap(() => this.lifecycleState$.pipe(map((x) => x === 'render'), distinctUntilChanged(), shareReplay())));
|
|
429
|
-
this.isMoving$ = this.whenInitialized$.pipe(switchMap(() => this.moveState$.pipe(map((x) => x === 'moving'), distinctUntilChanged(), shareReplay())));
|
|
430
|
-
this.isZooming$ = this.whenInitialized$.pipe(switchMap(() => this.zoomState$.pipe(map((x) => x === 'zooming'), distinctUntilChanged(), shareReplay())));
|
|
431
|
-
this.isRotating$ = this.whenInitialized$.pipe(switchMap(() => this.rotateState$.pipe(map((x) => x === 'rotating'), distinctUntilChanged(), shareReplay())));
|
|
429
|
+
this.isRendering$ = this.whenInitialized$.pipe(switchMap(() => this.lifecycleState$.pipe(map((x) => x === 'render'), distinctUntilChanged(), shareReplay(1))));
|
|
430
|
+
this.isMoving$ = this.whenInitialized$.pipe(switchMap(() => this.moveState$.pipe(map((x) => x === 'moving'), distinctUntilChanged(), shareReplay(1))));
|
|
431
|
+
this.isZooming$ = this.whenInitialized$.pipe(switchMap(() => this.zoomState$.pipe(map((x) => x === 'zooming'), distinctUntilChanged(), shareReplay(1))));
|
|
432
|
+
this.isRotating$ = this.whenInitialized$.pipe(switchMap(() => this.rotateState$.pipe(map((x) => x === 'rotating'), distinctUntilChanged(), shareReplay(1))));
|
|
432
433
|
this._movingTimer = this.movingTimer();
|
|
433
434
|
this._renderingTimer = this.lifecycleRenderTimer();
|
|
434
435
|
this.centerNow$ = this.whenInitialized$.pipe(switchMap(() => this.mapInstance$.pipe(switchMap((x) => this._movingTimer.pipe(map(() => this.latLngPoint(x.getCenter())))), shareReplay(1))), shareReplay(1));
|
|
435
436
|
this.center$ = this.whenInitialized$.pipe(switchMap(() => {
|
|
436
437
|
return this.isMoving$.pipe(onTrueToFalse(), startWith(undefined), switchMap(() => this.centerNow$.pipe(first())), distinctUntilChanged(isSameLatLngPoint), shareReplay(1));
|
|
437
438
|
}), shareReplay(1));
|
|
439
|
+
this.minimumVirtualViewportSize$ = this.state$.pipe(map((x) => x.minimumVirtualViewportSize), distinctUntilChanged(isSameVector), shareReplay(1));
|
|
440
|
+
this.currentMapCanvasSize$ = this.state$.pipe(map((x) => x.mapCanvasSize), distinctUntilChanged(isSameVector), shareReplay(1));
|
|
441
|
+
/**
|
|
442
|
+
* The map canvas size with consideration to the virtual viewport size.
|
|
443
|
+
*/
|
|
444
|
+
this.mapCanvasSize$ = this.currentMapCanvasSize$.pipe(filterMaybe());
|
|
445
|
+
/**
|
|
446
|
+
* The map canvas size with consideration to the virtual viewport size.
|
|
447
|
+
*/
|
|
448
|
+
this.virtualMapCanvasSize$ = this.minimumVirtualViewportSize$.pipe(switchMap((minimumVirtualViewportSize) => {
|
|
449
|
+
if (minimumVirtualViewportSize) {
|
|
450
|
+
return this.minimumMapCanvasSize(minimumVirtualViewportSize);
|
|
451
|
+
}
|
|
452
|
+
else {
|
|
453
|
+
return this.mapCanvasSize$;
|
|
454
|
+
}
|
|
455
|
+
}), distinctUntilChanged(isSameVector), shareReplay(1));
|
|
456
|
+
this.rawViewportBoundFunction$ = this.mapCanvasSize$.pipe(map((mapCanvasSize) => mapboxViewportBoundFunction({ mapCanvasSize })), shareReplay(1));
|
|
457
|
+
this.viewportBoundFunction$ = this.minimumVirtualViewportSize$.pipe(switchMap((minimumVirtualViewportSize) => {
|
|
458
|
+
if (minimumVirtualViewportSize) {
|
|
459
|
+
return this.viewportBoundFunctionWithMinimumSize(minimumVirtualViewportSize);
|
|
460
|
+
}
|
|
461
|
+
else {
|
|
462
|
+
return this.rawViewportBoundFunction$;
|
|
463
|
+
}
|
|
464
|
+
}), shareReplay(1));
|
|
465
|
+
this.virtualBound$ = this.viewportBoundFunction$.pipe(switchMap((fn) => {
|
|
466
|
+
return combineLatest([this.center$, this.zoom$]).pipe(map(([center, zoom]) => fn({
|
|
467
|
+
center,
|
|
468
|
+
zoom
|
|
469
|
+
})));
|
|
470
|
+
}), shareReplay(1));
|
|
438
471
|
this.margin$ = this.state$.pipe(map((x) => x.margin), distinctUntilChanged((a, b) => a != null && b != null && a.fullWidth === b.fullWidth && a.leftMargin === b.leftMargin && a.rightMargin === b.rightMargin), shareReplay(1));
|
|
439
472
|
this.reverseMargin$ = this.margin$.pipe(map((x) => {
|
|
440
473
|
if (x) {
|
|
@@ -454,7 +487,7 @@ class DbxMapboxMapStore extends ComponentStore {
|
|
|
454
487
|
}
|
|
455
488
|
}));
|
|
456
489
|
}), shareReplay(1));
|
|
457
|
-
this.
|
|
490
|
+
this.rawBoundNow$ = this.whenInitialized$.pipe(switchMap(() => this.mapInstance$.pipe(switchMap((x) => this._renderingTimer.pipe(map(() => {
|
|
458
491
|
const bound = x.getBounds();
|
|
459
492
|
const boundSw = bound.getSouthWest();
|
|
460
493
|
const boundNe = bound.getNorthEast();
|
|
@@ -462,13 +495,22 @@ class DbxMapboxMapStore extends ComponentStore {
|
|
|
462
495
|
const ne = isDefaultLatLngPoint(boundNe) ? neMostLatLngPoint() : { lat: boundNe.lat, lng: boundNe.lng };
|
|
463
496
|
return this.latLngBound(sw, ne);
|
|
464
497
|
}))), shareReplay(1))));
|
|
465
|
-
this.
|
|
466
|
-
return this.isRendering$.pipe(onTrueToFalse(), startWith(undefined), switchMap((x) => this.
|
|
498
|
+
this.rawBound$ = this.whenInitialized$.pipe(switchMap(() => {
|
|
499
|
+
return this.isRendering$.pipe(onTrueToFalse(), startWith(undefined), switchMap((x) => this.rawBoundNow$.pipe(first())), distinctUntilChanged(isSameLatLngBound), shareReplay(1));
|
|
467
500
|
}));
|
|
501
|
+
this.useVirtualBound$ = this.state$.pipe(map((x) => x.useVirtualBound), distinctUntilChanged(), shareReplay(1));
|
|
502
|
+
this.bound$ = this.useVirtualBound$.pipe(switchMap((useVirtualBound) => {
|
|
503
|
+
if (useVirtualBound) {
|
|
504
|
+
return this.virtualBound$;
|
|
505
|
+
}
|
|
506
|
+
else {
|
|
507
|
+
return this.bound$;
|
|
508
|
+
}
|
|
509
|
+
}), shareReplay(1));
|
|
468
510
|
this.boundSizing$ = this.bound$.pipe(map((x) => diffLatLngBoundPoints(x)), shareReplay(1));
|
|
469
511
|
this.boundWrapsAroundWorld$ = this.bound$.pipe(map((x) => latLngBoundWrapsMap(x)), distinctUntilChanged(), shareReplay(1));
|
|
470
512
|
this.isWithinBoundFunction$ = this.bound$.pipe(map((x) => isWithinLatLngBoundFunction(x)), shareReplay(1));
|
|
471
|
-
this.overlapsBoundFunction$ = this.
|
|
513
|
+
this.overlapsBoundFunction$ = this.virtualBound$.pipe(map((x) => overlapsLatLngBoundFunction(x)), shareReplay(1));
|
|
472
514
|
this.zoomNow$ = this.whenInitialized$.pipe(switchMap(() => this.mapInstance$.pipe(switchMap((x) => this._renderingTimer.pipe(map(() => x.getZoom()))), shareReplay(1))));
|
|
473
515
|
this.zoom$ = this.whenInitialized$.pipe(switchMap(() => {
|
|
474
516
|
return this.isZooming$.pipe(onTrueToFalse(), startWith(undefined), switchMap(() => this.zoomNow$.pipe(first())), distinctUntilChanged(), shareReplay(1));
|
|
@@ -483,25 +525,14 @@ class DbxMapboxMapStore extends ComponentStore {
|
|
|
483
525
|
}));
|
|
484
526
|
this.content$ = this.state$.pipe(map((x) => x.content), distinctUntilChanged(), shareReplay(1));
|
|
485
527
|
this.hasContent$ = this.content$.pipe(map(Boolean));
|
|
486
|
-
this.currentMapCanvasSize$ = this.state$.pipe(map((x) => x.mapCanvasSize), distinctUntilChanged((a, b) => a != null && b != null && vectorsAreEqual(a, b)), shareReplay(1));
|
|
487
|
-
this.mapCanvasSize$ = this.currentMapCanvasSize$.pipe(filterMaybe());
|
|
488
|
-
this.minimumVirtualViewportSize$ = this.state$.pipe(map((x) => x.minimumVirtualViewportSize), distinctUntilChanged(isSameVector), shareReplay(1));
|
|
489
|
-
this.rawViewportBoundFunction$ = this.mapCanvasSize$.pipe(map((x) => mapboxViewportBoundFunction({ mapCanvasSize: x })), shareReplay(1));
|
|
490
|
-
this.viewportBoundFunction$ = this.minimumVirtualViewportSize$.pipe(switchMap((minimumSize) => {
|
|
491
|
-
if (minimumSize) {
|
|
492
|
-
return this.viewportBoundFunctionWithMinimumSize(minimumSize);
|
|
493
|
-
}
|
|
494
|
-
else {
|
|
495
|
-
return this.rawViewportBoundFunction$;
|
|
496
|
-
}
|
|
497
|
-
}), shareReplay(1));
|
|
498
528
|
this.clickEvent$ = this.state$.pipe(map((x) => x.clickEvent), distinctUntilChanged(), shareReplay(1));
|
|
499
529
|
this.doubleClickEvent$ = this.state$.pipe(map((x) => x.doubleClickEvent), distinctUntilChanged(), shareReplay(1));
|
|
500
530
|
this.rightClickEvent$ = this.state$.pipe(map((x) => x.rightClickEvent), distinctUntilChanged(), shareReplay(1));
|
|
501
531
|
// MARK: State Changes
|
|
502
532
|
this.setMargin = this.updater((state, margin) => ({ ...state, margin: margin && (margin.rightMargin !== 0 || margin.leftMargin !== 0) ? margin : undefined }));
|
|
503
533
|
this.setMinimumVirtualViewportSize = this.updater((state, minimumVirtualViewportSize) => ({ ...state, minimumVirtualViewportSize }));
|
|
504
|
-
this.
|
|
534
|
+
this.setUseVirtualBound = this.updater((state, useVirtualBound) => ({ ...state, useVirtualBound }));
|
|
535
|
+
this._setMapService = this.updater((state, mapService) => ({ mapService, moveState: 'init', lifecycleState: 'init', zoomState: 'init', rotateState: 'init', retainContent: state.retainContent, content: state.retainContent ? state.content : undefined, useVirtualBound: state.useVirtualBound }));
|
|
505
536
|
this._setLifecycleState = this.updater((state, lifecycleState) => ({ ...state, lifecycleState }));
|
|
506
537
|
this._setMoveState = this.updater((state, moveState) => ({ ...state, moveState }));
|
|
507
538
|
this._setZoomState = this.updater((state, zoomState) => ({ ...state, zoomState }));
|
|
@@ -526,7 +557,7 @@ class DbxMapboxMapStore extends ComponentStore {
|
|
|
526
557
|
else {
|
|
527
558
|
return of(0);
|
|
528
559
|
}
|
|
529
|
-
}), shareReplay());
|
|
560
|
+
}), shareReplay(1));
|
|
530
561
|
}
|
|
531
562
|
lifecycleRenderTimer(period = this.timerRefreshPeriod) {
|
|
532
563
|
return this.lifecycleState$.pipe(switchMap((x) => {
|
|
@@ -536,7 +567,7 @@ class DbxMapboxMapStore extends ComponentStore {
|
|
|
536
567
|
else {
|
|
537
568
|
return of(0);
|
|
538
569
|
}
|
|
539
|
-
}), shareReplay());
|
|
570
|
+
}), shareReplay(1));
|
|
540
571
|
}
|
|
541
572
|
atNextIdle() {
|
|
542
573
|
return this.moveState$.pipe(map((x) => x === 'idle'), first());
|
|
@@ -578,6 +609,10 @@ class DbxMapboxMapStore extends ComponentStore {
|
|
|
578
609
|
boundDecisionObs: this.overlapsBoundFunction$
|
|
579
610
|
});
|
|
580
611
|
}
|
|
612
|
+
minimumMapCanvasSize(minVector) {
|
|
613
|
+
const resizeFn = vectorMinimumSizeResizeFunction(minVector);
|
|
614
|
+
return this.mapCanvasSize$.pipe(map((x) => resizeFn(x)), distinctUntilChanged(isSameVector), shareReplay(1));
|
|
615
|
+
}
|
|
581
616
|
/**
|
|
582
617
|
* Creates a MapboxViewportBoundFunction observable that returns the minimum viewport size.
|
|
583
618
|
*
|
|
@@ -816,6 +851,7 @@ class DbxMapboxLayoutComponent extends SubscriptionObject {
|
|
|
816
851
|
this._openToggle = new BehaviorSubject(true);
|
|
817
852
|
this._color = new BehaviorSubject(undefined);
|
|
818
853
|
this._toggleSub = new SubscriptionObject();
|
|
854
|
+
this.resized$ = this._resized.asObservable();
|
|
819
855
|
this.side$ = this._side.pipe(distinctUntilChanged(), shareReplay(1));
|
|
820
856
|
this.mode$ = this._mode.pipe(distinctUntilChanged(), shareReplay(1));
|
|
821
857
|
this.hasContent$ = combineLatest([this._forceHasContent, this.dbxMapboxMapStore.hasContent$]).pipe(map(([hasContent, forceHasContent]) => hasContent || forceHasContent), distinctUntilChanged(), shareReplay(1));
|
|
@@ -853,12 +889,12 @@ class DbxMapboxLayoutComponent extends SubscriptionObject {
|
|
|
853
889
|
let obs;
|
|
854
890
|
if (mode === 'push') {
|
|
855
891
|
obs = combineLatest([this.opened$.pipe(distinctUntilChanged()), this._updateMargins]).pipe(tap(([opened]) => {
|
|
856
|
-
let { right } = this.
|
|
857
|
-
this.
|
|
892
|
+
let { right } = this.drawerContainer._contentMargins;
|
|
893
|
+
this.drawerContainer.updateContentMargins();
|
|
858
894
|
setTimeout(() => {
|
|
859
895
|
const flip = opened ? 1 : -1;
|
|
860
896
|
if (opened) {
|
|
861
|
-
right = this.
|
|
897
|
+
right = this.drawerContainer._contentMargins.right;
|
|
862
898
|
}
|
|
863
899
|
right = (right || 0) * flip;
|
|
864
900
|
const element = this.content.nativeElement;
|
|
@@ -881,7 +917,7 @@ class DbxMapboxLayoutComponent extends SubscriptionObject {
|
|
|
881
917
|
}
|
|
882
918
|
else {
|
|
883
919
|
obs = combineLatest([this.opened$.pipe(distinctUntilChanged()), this._updateMargins]).pipe(switchMap((_) => this.dbxMapboxMapStore.mapInstance$), tap((x) => {
|
|
884
|
-
this.
|
|
920
|
+
this.drawerContainer.updateContentMargins();
|
|
885
921
|
x.triggerRepaint();
|
|
886
922
|
}));
|
|
887
923
|
}
|
|
@@ -928,15 +964,18 @@ class DbxMapboxLayoutComponent extends SubscriptionObject {
|
|
|
928
964
|
this._color.next(color);
|
|
929
965
|
}
|
|
930
966
|
onResized(event) {
|
|
931
|
-
this._resized.next();
|
|
967
|
+
this._resized.next(event);
|
|
932
968
|
}
|
|
933
969
|
}
|
|
934
970
|
DbxMapboxLayoutComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: DbxMapboxLayoutComponent, deps: [{ token: DbxMapboxMapStore }], target: i0.ɵɵFactoryTarget.Component });
|
|
935
|
-
DbxMapboxLayoutComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: DbxMapboxLayoutComponent, selector: "dbx-mapbox-layout", inputs: { side: "side", mode: "mode", opened: "opened", hasContent: "hasContent", drawerColor: "drawerColor" }, viewQueries: [{ propertyName: "
|
|
971
|
+
DbxMapboxLayoutComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: DbxMapboxLayoutComponent, selector: "dbx-mapbox-layout", inputs: { side: "side", mode: "mode", opened: "opened", hasContent: "hasContent", drawerColor: "drawerColor" }, viewQueries: [{ propertyName: "containerElement", first: true, predicate: MatDrawerContainer, descendants: true, read: ElementRef }, { propertyName: "drawerContainer", first: true, predicate: MatDrawerContainer, descendants: true }, { propertyName: "content", first: true, predicate: ["content"], descendants: true, read: ElementRef, static: true }], usesInheritance: true, ngImport: i0, template: "<mat-drawer-container #containerElement class=\"dbx-mapbox-layout-container\" [ngClass]=\"(drawerClasses$ | async) || ''\" [hasBackdrop]=\"false\">\n <mat-drawer class=\"dbx-mapbox-layout-drawer\" #drawer [opened]=\"opened$ | async\" [mode]=\"(mode$ | async) || 'side'\" [position]=\"(position$ | async) || 'end'\">\n <div class=\"dbx-mapbox-layout-drawer-content\" [ngClass]=\"(drawerButtonClasses$ | async) || ''\">\n <ng-content select=\"[drawer]\"></ng-content>\n <dbx-mapbox-layout-drawer></dbx-mapbox-layout-drawer>\n </div>\n </mat-drawer>\n <mat-drawer-content #content class=\"dbx-mapbox-layout-content\" (resized)=\"onResized($event)\">\n <button mat-icon-button (click)=\"toggleDrawer()\" class=\"dbx-mapbox-layout-drawer-button\" [ngClass]=\"(drawerButtonClasses$ | async) || ''\">\n <mat-icon>{{ buttonIcon$ | async }}</mat-icon>\n </button>\n <ng-content></ng-content>\n </mat-drawer-content>\n</mat-drawer-container>\n", styles: [".dbx-mapbox-layout-container{height:100%;max-width:100%}.dbx-mapbox-layout-container .mat-drawer-container{height:100%}.dbx-mapbox-layout-container .dbx-mapbox-layout-drawer{max-width:calc(100% - var(--dbx-mapbox-min-width-var, 60px))}.dbx-mapbox-layout-container .dbx-mapbox-layout-drawer-content{height:100%;width:100%;overflow:hidden}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{position:absolute;z-index:2;top:40%;border:none;display:flex;overflow:hidden}.left-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{left:0;border-radius:0 20px 20px 0}.right-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{right:0;border-radius:20px 0 0 20px}.has-drawer-content .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:35px}.has-drawer-content.open-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:35px}.no-drawer-content .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:0px}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button mat-icon{padding-left:8px}\n"], dependencies: [{ kind: "directive", type: i2$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: i3.MatDrawer, selector: "mat-drawer", inputs: ["position", "mode", "disableClose", "autoFocus", "opened"], outputs: ["openedChange", "opened", "openedStart", "closed", "closedStart", "positionChanged"], exportAs: ["matDrawer"] }, { kind: "component", type: i3.MatDrawerContainer, selector: "mat-drawer-container", inputs: ["autosize", "hasBackdrop"], outputs: ["backdropClick"], exportAs: ["matDrawerContainer"] }, { kind: "component", type: i3.MatDrawerContent, selector: "mat-drawer-content" }, { kind: "component", type: i4.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i5.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i6.ResizedDirective, selector: "[resized]", outputs: ["resized"] }, { kind: "component", type: DbxMapboxLayoutDrawerComponent, selector: "dbx-mapbox-layout-drawer" }, { kind: "pipe", type: i2$1.AsyncPipe, name: "async" }] });
|
|
936
972
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: DbxMapboxLayoutComponent, decorators: [{
|
|
937
973
|
type: Component,
|
|
938
|
-
args: [{ selector: 'dbx-mapbox-layout', template: "<mat-drawer-container class=\"dbx-mapbox-layout-container\" [ngClass]=\"(drawerClasses$ | async) || ''\" [hasBackdrop]=\"false\">\n <mat-drawer class=\"dbx-mapbox-layout-drawer\" #drawer [opened]=\"opened$ | async\" [mode]=\"(mode$ | async) || 'side'\" [position]=\"(position$ | async) || 'end'\">\n <div class=\"dbx-mapbox-layout-drawer-content\" [ngClass]=\"(drawerButtonClasses$ | async) || ''\">\n <ng-content select=\"[drawer]\"></ng-content>\n <dbx-mapbox-layout-drawer></dbx-mapbox-layout-drawer>\n </div>\n </mat-drawer>\n <mat-drawer-content #content class=\"dbx-mapbox-layout-content\" (resized)=\"onResized($event)\">\n <button mat-icon-button (click)=\"toggleDrawer()\" class=\"dbx-mapbox-layout-drawer-button\" [ngClass]=\"(drawerButtonClasses$ | async) || ''\">\n <mat-icon>{{ buttonIcon$ | async }}</mat-icon>\n </button>\n <ng-content></ng-content>\n </mat-drawer-content>\n</mat-drawer-container>\n", styles: [".dbx-mapbox-layout-container{height:100%;max-width:100%}.dbx-mapbox-layout-container .mat-drawer-container{height:100%}.dbx-mapbox-layout-container .dbx-mapbox-layout-drawer{max-width:calc(100% - var(--dbx-mapbox-min-width-var, 60px))}.dbx-mapbox-layout-container .dbx-mapbox-layout-drawer-content{height:100%;width:100%;overflow:hidden}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{position:absolute;z-index:2;top:40%;border:none;display:flex;overflow:hidden}.left-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{left:0;border-radius:0 20px 20px 0}.right-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{right:0;border-radius:20px 0 0 20px}.has-drawer-content .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:35px}.has-drawer-content.open-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:35px}.no-drawer-content .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:0px}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button mat-icon{padding-left:8px}\n"] }]
|
|
939
|
-
}], ctorParameters: function () { return [{ type: DbxMapboxMapStore }]; }, propDecorators: {
|
|
974
|
+
args: [{ selector: 'dbx-mapbox-layout', template: "<mat-drawer-container #containerElement class=\"dbx-mapbox-layout-container\" [ngClass]=\"(drawerClasses$ | async) || ''\" [hasBackdrop]=\"false\">\n <mat-drawer class=\"dbx-mapbox-layout-drawer\" #drawer [opened]=\"opened$ | async\" [mode]=\"(mode$ | async) || 'side'\" [position]=\"(position$ | async) || 'end'\">\n <div class=\"dbx-mapbox-layout-drawer-content\" [ngClass]=\"(drawerButtonClasses$ | async) || ''\">\n <ng-content select=\"[drawer]\"></ng-content>\n <dbx-mapbox-layout-drawer></dbx-mapbox-layout-drawer>\n </div>\n </mat-drawer>\n <mat-drawer-content #content class=\"dbx-mapbox-layout-content\" (resized)=\"onResized($event)\">\n <button mat-icon-button (click)=\"toggleDrawer()\" class=\"dbx-mapbox-layout-drawer-button\" [ngClass]=\"(drawerButtonClasses$ | async) || ''\">\n <mat-icon>{{ buttonIcon$ | async }}</mat-icon>\n </button>\n <ng-content></ng-content>\n </mat-drawer-content>\n</mat-drawer-container>\n", styles: [".dbx-mapbox-layout-container{height:100%;max-width:100%}.dbx-mapbox-layout-container .mat-drawer-container{height:100%}.dbx-mapbox-layout-container .dbx-mapbox-layout-drawer{max-width:calc(100% - var(--dbx-mapbox-min-width-var, 60px))}.dbx-mapbox-layout-container .dbx-mapbox-layout-drawer-content{height:100%;width:100%;overflow:hidden}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{position:absolute;z-index:2;top:40%;border:none;display:flex;overflow:hidden}.left-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{left:0;border-radius:0 20px 20px 0}.right-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{right:0;border-radius:20px 0 0 20px}.has-drawer-content .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:35px}.has-drawer-content.open-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:35px}.no-drawer-content .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:0px}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button mat-icon{padding-left:8px}\n"] }]
|
|
975
|
+
}], ctorParameters: function () { return [{ type: DbxMapboxMapStore }]; }, propDecorators: { containerElement: [{
|
|
976
|
+
type: ViewChild,
|
|
977
|
+
args: [MatDrawerContainer, { read: ElementRef }]
|
|
978
|
+
}], drawerContainer: [{
|
|
940
979
|
type: ViewChild,
|
|
941
980
|
args: [MatDrawerContainer]
|
|
942
981
|
}], content: [{
|
|
@@ -1274,8 +1313,40 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
|
|
|
1274
1313
|
type: Input
|
|
1275
1314
|
}] } });
|
|
1276
1315
|
|
|
1316
|
+
/**
|
|
1317
|
+
* Directive that synchronizes a map's virtual size with the size of the element.
|
|
1318
|
+
*/
|
|
1319
|
+
class DbxMapboxLayoutVirtualResizeSyncComponent extends SubscriptionObject {
|
|
1320
|
+
constructor(dbxMapboxLayoutComponent) {
|
|
1321
|
+
super();
|
|
1322
|
+
this.dbxMapboxLayoutComponent = dbxMapboxLayoutComponent;
|
|
1323
|
+
this.resizedVector$ = this.dbxMapboxLayoutComponent.resized$.pipe(map(() => {
|
|
1324
|
+
const element = this.dbxMapboxLayoutComponent.containerElement.nativeElement;
|
|
1325
|
+
const { clientWidth, clientHeight } = element;
|
|
1326
|
+
return {
|
|
1327
|
+
x: clientWidth,
|
|
1328
|
+
y: clientHeight
|
|
1329
|
+
};
|
|
1330
|
+
}), distinctUntilChanged(isSameVector), shareReplay(1));
|
|
1331
|
+
}
|
|
1332
|
+
ngOnInit() {
|
|
1333
|
+
this.dbxMapboxLayoutComponent.dbxMapboxMapStore.setMinimumVirtualViewportSize(this.resizedVector$);
|
|
1334
|
+
}
|
|
1335
|
+
}
|
|
1336
|
+
DbxMapboxLayoutVirtualResizeSyncComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: DbxMapboxLayoutVirtualResizeSyncComponent, deps: [{ token: DbxMapboxLayoutComponent, host: true }], target: i0.ɵɵFactoryTarget.Directive });
|
|
1337
|
+
DbxMapboxLayoutVirtualResizeSyncComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.12", type: DbxMapboxLayoutVirtualResizeSyncComponent, selector: "[dbxMapboxLayoutVirtualResizeSync]", usesInheritance: true, ngImport: i0 });
|
|
1338
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: DbxMapboxLayoutVirtualResizeSyncComponent, decorators: [{
|
|
1339
|
+
type: Directive,
|
|
1340
|
+
args: [{
|
|
1341
|
+
selector: '[dbxMapboxLayoutVirtualResizeSync]'
|
|
1342
|
+
}]
|
|
1343
|
+
}], ctorParameters: function () { return [{ type: DbxMapboxLayoutComponent, decorators: [{
|
|
1344
|
+
type: Host
|
|
1345
|
+
}] }]; } });
|
|
1346
|
+
|
|
1277
1347
|
const declarations = [
|
|
1278
1348
|
//
|
|
1349
|
+
DbxMapboxLayoutVirtualResizeSyncComponent,
|
|
1279
1350
|
DbxMapboxMapDirective,
|
|
1280
1351
|
DbxMapboxLayoutComponent,
|
|
1281
1352
|
DbxMapboxLayoutDrawerComponent,
|
|
@@ -1301,6 +1372,7 @@ class DbxMapboxModule {
|
|
|
1301
1372
|
DbxMapboxModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: DbxMapboxModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1302
1373
|
DbxMapboxModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: DbxMapboxModule, declarations: [
|
|
1303
1374
|
//
|
|
1375
|
+
DbxMapboxLayoutVirtualResizeSyncComponent,
|
|
1304
1376
|
DbxMapboxMapDirective,
|
|
1305
1377
|
DbxMapboxLayoutComponent,
|
|
1306
1378
|
DbxMapboxLayoutDrawerComponent,
|
|
@@ -1319,6 +1391,7 @@ DbxMapboxModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version
|
|
|
1319
1391
|
DbxRouterAnchorModule,
|
|
1320
1392
|
NgxMapboxGLModule], exports: [
|
|
1321
1393
|
//
|
|
1394
|
+
DbxMapboxLayoutVirtualResizeSyncComponent,
|
|
1322
1395
|
DbxMapboxMapDirective,
|
|
1323
1396
|
DbxMapboxLayoutComponent,
|
|
1324
1397
|
DbxMapboxLayoutDrawerComponent,
|
|
@@ -1393,5 +1466,5 @@ function mapboxZoomLevel(input) {
|
|
|
1393
1466
|
* Generated bundle index. Do not edit.
|
|
1394
1467
|
*/
|
|
1395
1468
|
|
|
1396
|
-
export { DEFAULT_MAPBOX_CENTER, DEFAULT_MAPBOX_MAP_STORE_TIMER_REFRESH_PERIOD, DEFAULT_MAPBOX_STYLE, DEFAULT_MAPBOX_ZOOM, DbxMapboxChangeDetectorRefService, DbxMapboxChangeService, DbxMapboxConfig, DbxMapboxInjectionComponent, DbxMapboxInjectionStore, DbxMapboxInjectionStoreInjectionBlockDirective, DbxMapboxInjectionStoreProviderBlock, DbxMapboxLayoutComponent, DbxMapboxLayoutDrawerComponent, DbxMapboxMapDirective, DbxMapboxMapStore, DbxMapboxMapStoreInjectionBlockDirective, DbxMapboxMapStoreProviderBlock, DbxMapboxMarkerComponent, DbxMapboxMarkersComponent, DbxMapboxMenuComponent, DbxMapboxModule, DbxMapboxService, KNOWN_MAPBOX_STYLES, MAPBOX_MAX_ZOOM_LEVEL, MAPBOX_MIN_ZOOM_LEVEL, dbxMapboxColoredDotStyle, filterByMapboxViewportBound, mapboxViewportBoundFunction, mapboxZoomLevel, provideMapboxInjectionStoreIfParentIsUnavailable, provideMapboxStoreIfParentIsUnavailable, updateDbxMapboxMapInjectionStoreStateWithInjectionConfig, updateDbxMapboxMapInjectionStoreStateWithRemovedKey };
|
|
1469
|
+
export { DEFAULT_MAPBOX_CENTER, DEFAULT_MAPBOX_MAP_STORE_TIMER_REFRESH_PERIOD, DEFAULT_MAPBOX_STYLE, DEFAULT_MAPBOX_ZOOM, DbxMapboxChangeDetectorRefService, DbxMapboxChangeService, DbxMapboxConfig, DbxMapboxInjectionComponent, DbxMapboxInjectionStore, DbxMapboxInjectionStoreInjectionBlockDirective, DbxMapboxInjectionStoreProviderBlock, DbxMapboxLayoutComponent, DbxMapboxLayoutDrawerComponent, DbxMapboxLayoutVirtualResizeSyncComponent, DbxMapboxMapDirective, DbxMapboxMapStore, DbxMapboxMapStoreInjectionBlockDirective, DbxMapboxMapStoreProviderBlock, DbxMapboxMarkerComponent, DbxMapboxMarkersComponent, DbxMapboxMenuComponent, DbxMapboxModule, DbxMapboxService, KNOWN_MAPBOX_STYLES, MAPBOX_MAX_ZOOM_LEVEL, MAPBOX_MIN_ZOOM_LEVEL, dbxMapboxColoredDotStyle, filterByMapboxViewportBound, mapboxViewportBoundFunction, mapboxZoomLevel, provideMapboxInjectionStoreIfParentIsUnavailable, provideMapboxStoreIfParentIsUnavailable, updateDbxMapboxMapInjectionStoreStateWithInjectionConfig, updateDbxMapboxMapInjectionStoreStateWithRemovedKey };
|
|
1397
1470
|
//# sourceMappingURL=dereekb-dbx-web-mapbox.mjs.map
|