@agorapulse/ui-components 20.3.30-beta.1 → 20.3.32
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/agorapulse-ui-components-20.3.32.tgz +0 -0
- package/confirm-modal/index.d.ts +4 -3
- package/fesm2022/agorapulse-ui-components-confirm-modal.mjs.map +1 -1
- package/fesm2022/agorapulse-ui-components-datepicker.mjs +4 -0
- package/fesm2022/agorapulse-ui-components-datepicker.mjs.map +1 -1
- package/fesm2022/agorapulse-ui-components-modal.mjs +2 -5
- package/fesm2022/agorapulse-ui-components-modal.mjs.map +1 -1
- package/fesm2022/agorapulse-ui-components-nav-selector.mjs +9 -0
- package/fesm2022/agorapulse-ui-components-nav-selector.mjs.map +1 -1
- package/fesm2022/agorapulse-ui-components-split-button.mjs +3 -3
- package/fesm2022/agorapulse-ui-components-split-button.mjs.map +1 -1
- package/fesm2022/agorapulse-ui-components-toggle.mjs +2 -2
- package/fesm2022/agorapulse-ui-components-toggle.mjs.map +1 -1
- package/modal/index.d.ts +3 -12
- package/package.json +1 -1
- package/split-button/index.d.ts +2 -2
- package/agorapulse-ui-components-20.3.30-beta.1.tgz +0 -0
|
Binary file
|
package/confirm-modal/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ModalConfig } from '@agorapulse/ui-components/modal';
|
|
2
|
+
import { ComponentType } from '@angular/cdk/portal';
|
|
2
3
|
import { MatDialogRef, MatDialog } from '@angular/material/dialog';
|
|
3
4
|
import * as i0 from '@angular/core';
|
|
4
5
|
|
|
@@ -12,17 +13,17 @@ interface ConfirmModalTexts {
|
|
|
12
13
|
}
|
|
13
14
|
|
|
14
15
|
declare class ConfirmModalComponent {
|
|
15
|
-
dialogRef: MatDialogRef<
|
|
16
|
+
dialogRef: MatDialogRef<ComponentType<any>>;
|
|
16
17
|
contentText: string;
|
|
17
18
|
footerCancelButtonId: string;
|
|
18
19
|
footerCancelButtonLabel: string;
|
|
19
20
|
footerConfirmButtonId: string;
|
|
20
21
|
footerConfirmButtonLabel: string;
|
|
21
22
|
headerTitle: string;
|
|
22
|
-
constructor(dialogRef: MatDialogRef<
|
|
23
|
+
constructor(dialogRef: MatDialogRef<ComponentType<any>>);
|
|
23
24
|
onCancel(): void;
|
|
24
25
|
onConfirm(): void;
|
|
25
|
-
static open(dialog: MatDialog, confirmModalTexts: ConfirmModalTexts, modalConfig?: ModalConfig | null): MatDialogRef<ConfirmModalComponent,
|
|
26
|
+
static open(dialog: MatDialog, confirmModalTexts: ConfirmModalTexts, modalConfig?: ModalConfig | null): MatDialogRef<ConfirmModalComponent, any>;
|
|
26
27
|
static ɵfac: i0.ɵɵFactoryDeclaration<ConfirmModalComponent, never>;
|
|
27
28
|
static ɵcmp: i0.ɵɵComponentDeclaration<ConfirmModalComponent, "ap-confirm-modal", never, { "contentText": { "alias": "contentText"; "required": false; }; "footerCancelButtonId": { "alias": "footerCancelButtonId"; "required": false; }; "footerCancelButtonLabel": { "alias": "footerCancelButtonLabel"; "required": false; }; "footerConfirmButtonId": { "alias": "footerConfirmButtonId"; "required": false; }; "footerConfirmButtonLabel": { "alias": "footerConfirmButtonLabel"; "required": false; }; "headerTitle": { "alias": "headerTitle"; "required": false; }; }, {}, never, never, true, never>;
|
|
28
29
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agorapulse-ui-components-confirm-modal.mjs","sources":["../../../libs/ui-components/confirm-modal/src/confirm-modal.component.ts","../../../libs/ui-components/confirm-modal/src/confirm-modal.component.html","../../../libs/ui-components/confirm-modal/src/agorapulse-ui-components-confirm-modal.ts"],"sourcesContent":["import { ButtonComponent } from '@agorapulse/ui-components/button';\nimport { ModalComponent, ModalConfig } from '@agorapulse/ui-components/modal';\nimport { ChangeDetectionStrategy, Component, Input } from '@angular/core';\nimport { MatDialog, MatDialogRef } from '@angular/material/dialog';\nimport { ConfirmModalTexts } from './confirm-modal-texts.model';\n\n@Component({\n changeDetection: ChangeDetectionStrategy.OnPush,\n selector: 'ap-confirm-modal',\n templateUrl: 'confirm-modal.component.html',\n styleUrls: ['./confirm-modal.component.scss'],\n imports: [ButtonComponent, ModalComponent],\n})\nexport class ConfirmModalComponent {\n @Input() contentText: string = '';\n @Input() footerCancelButtonId: string = 'cancel';\n @Input() footerCancelButtonLabel: string = '';\n @Input() footerConfirmButtonId: string = 'confirm';\n @Input() footerConfirmButtonLabel: string = '';\n @Input() headerTitle: string = '';\n\n constructor(public dialogRef: MatDialogRef<
|
|
1
|
+
{"version":3,"file":"agorapulse-ui-components-confirm-modal.mjs","sources":["../../../libs/ui-components/confirm-modal/src/confirm-modal.component.ts","../../../libs/ui-components/confirm-modal/src/confirm-modal.component.html","../../../libs/ui-components/confirm-modal/src/agorapulse-ui-components-confirm-modal.ts"],"sourcesContent":["import { ButtonComponent } from '@agorapulse/ui-components/button';\nimport { ModalComponent, ModalConfig } from '@agorapulse/ui-components/modal';\nimport { ComponentType } from '@angular/cdk/portal';\nimport { ChangeDetectionStrategy, Component, Input } from '@angular/core';\nimport { MatDialog, MatDialogRef } from '@angular/material/dialog';\nimport { ConfirmModalTexts } from './confirm-modal-texts.model';\n\n@Component({\n changeDetection: ChangeDetectionStrategy.OnPush,\n selector: 'ap-confirm-modal',\n templateUrl: 'confirm-modal.component.html',\n styleUrls: ['./confirm-modal.component.scss'],\n imports: [ButtonComponent, ModalComponent],\n})\nexport class ConfirmModalComponent {\n @Input() contentText: string = '';\n @Input() footerCancelButtonId: string = 'cancel';\n @Input() footerCancelButtonLabel: string = '';\n @Input() footerConfirmButtonId: string = 'confirm';\n @Input() footerConfirmButtonLabel: string = '';\n @Input() headerTitle: string = '';\n\n constructor(public dialogRef: MatDialogRef<ComponentType<any>>) {\n dialogRef.disableClose = true;\n }\n\n onCancel() {\n this.dialogRef.close(false);\n }\n\n onConfirm() {\n this.dialogRef.close(true);\n }\n\n static open(dialog: MatDialog, confirmModalTexts: ConfirmModalTexts, modalConfig: ModalConfig | null = null) {\n if (!modalConfig) {\n modalConfig = {};\n }\n if (!modalConfig.matDialogConfig) {\n modalConfig.matDialogConfig = {\n width: '550px',\n };\n }\n const confirmModal = ModalComponent.openWithComponent(dialog, modalConfig, ConfirmModalComponent);\n confirmModal.componentInstance.contentText = confirmModalTexts.contentText;\n confirmModal.componentInstance.footerConfirmButtonId = confirmModalTexts.footerConfirmButtonId;\n confirmModal.componentInstance.footerConfirmButtonLabel = confirmModalTexts.footerConfirmButtonLabel;\n confirmModal.componentInstance.footerCancelButtonId = confirmModalTexts.footerCancelButtonId;\n confirmModal.componentInstance.footerCancelButtonLabel = confirmModalTexts.footerCancelButtonLabel;\n confirmModal.componentInstance.headerTitle = confirmModalTexts.headerTitle;\n return confirmModal;\n }\n}\n","<ng-template #headerTemplate>\n <h2>{{ headerTitle }}</h2>\n</ng-template>\n\n<ng-template #mainTemplate>\n <p>{{ contentText }}</p>\n</ng-template>\n\n<ng-template #footerTemplate>\n <div class=\"buttons\">\n <ap-button\n name=\"confirm-modal-cancel-button\"\n [config]=\"{\n style: 'ghost',\n color: 'grey'\n }\"\n [id]=\"footerCancelButtonId\"\n (click)=\"onCancel()\">\n <span>\n {{ footerCancelButtonLabel }}\n </span>\n </ap-button>\n <ap-button\n name=\"confirm-modal-confirm-button\"\n cdkFocusInitial\n [config]=\"{\n style: 'primary',\n color: 'orange'\n }\"\n [id]=\"footerConfirmButtonId\"\n (click)=\"onConfirm()\">\n <span>\n {{ footerConfirmButtonLabel }}\n </span>\n </ap-button>\n </div>\n</ng-template>\n\n<ap-modal\n [closable]=\"true\"\n [headerTemplate]=\"headerTemplate\"\n [mainTemplate]=\"mainTemplate\"\n [footerTemplate]=\"footerTemplate\" />\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;MAca,qBAAqB,CAAA;AAQX,IAAA,SAAA;IAPV,WAAW,GAAW,EAAE;IACxB,oBAAoB,GAAW,QAAQ;IACvC,uBAAuB,GAAW,EAA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/B;gBACQ,qBAAqB,EAAA,CAAA;sBAA7B;gBACQ,wBAAwB,EAAA,CAAA;sBAAhC;gBACQ,WAAW,EAAA,CAAA;sBAAnB;;;AEpBL;;AAEG;;;;"}
|
|
@@ -126,6 +126,10 @@ class DatepickerComponent {
|
|
|
126
126
|
ngAfterViewInit() {
|
|
127
127
|
if (this.datepickerRef) {
|
|
128
128
|
setTimeout(() => {
|
|
129
|
+
if (this.mode === DatepickerMode.Range && this.selectedPeriod?.startDate) {
|
|
130
|
+
this.datepickerRef.setStartDate(this.selectedPeriod.startDate);
|
|
131
|
+
this.datepickerRef.setEndDate(this.selectedPeriod.endDate ?? this.selectedPeriod.startDate);
|
|
132
|
+
}
|
|
129
133
|
this.datepickerRef.updateCalendars();
|
|
130
134
|
this.setCalendarCurrentPage();
|
|
131
135
|
}, 100);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agorapulse-ui-components-datepicker.mjs","sources":["../../../libs/ui-components/datepicker/src/datepicker.component.ts","../../../libs/ui-components/datepicker/src/datepicker.component.html","../../../libs/ui-components/datepicker/src/agorapulse-ui-components-datepicker.ts"],"sourcesContent":["import { SymbolComponent, SymbolRegistry, apArrowLeft, apArrowRight } from '@agorapulse/ui-symbol';\n\nimport { DaterangepickerComponent, NgxDaterangepickerMd } from '@agorapulse/ngx-daterangepicker-material';\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n EventEmitter,\n Input,\n OnChanges,\n OnInit,\n Output,\n SimpleChanges,\n ViewChild,\n input,\n} from '@angular/core';\nimport dayjs from 'dayjs';\nimport 'dayjs/locale/de';\nimport 'dayjs/locale/en';\nimport 'dayjs/locale/es';\nimport 'dayjs/locale/fr';\nimport 'dayjs/locale/pt';\nimport localeData from 'dayjs/plugin/localeData';\n\nexport enum DatepickerMode {\n Single = 'Single',\n Multiple = 'Multiple',\n Range = 'Range',\n}\n\nexport interface Period {\n startDate?: dayjs.Dayjs;\n endDate?: dayjs.Dayjs;\n}\n\nexport interface StartDate {\n startDate: dayjs.Dayjs;\n}\n\nexport interface I18nDatePicker {\n ranges: {\n yesterday: string;\n lastWeek: string;\n last30Days: string;\n lastMonth: string;\n thisMonth: string;\n [other: string]: string;\n };\n}\n\nenum SideEnum {\n left = 'left',\n right = 'right',\n}\n\nexport type RangesConfigPresetType = { [periodText: string]: [dayjs.Dayjs, dayjs.Dayjs] };\nexport const RangesConfigPreset = {\n yesterday: [dayjs().subtract(1, 'days'), dayjs().subtract(1, 'days')],\n lastWeek: [dayjs().subtract(7, 'days'), dayjs().subtract(1, 'days')],\n last30Days: [dayjs().subtract(30, 'days'), dayjs().subtract(1, 'days')],\n lastMonth: [dayjs().subtract(1, 'month').startOf('month'), dayjs().subtract(1, 'month').endOf('month')],\n thisMonth: [dayjs().startOf('month'), dayjs().endOf('month')],\n\n lastWeekFromToday: [dayjs().subtract(6, 'days'), dayjs()],\n lastMonthFromToday: [dayjs().subtract(1, 'month').add(1, 'days'), dayjs()],\n last3MonthsFromToday: [dayjs().subtract(3, 'month').add(1, 'days'), dayjs()],\n last6MonthsFromToday: [dayjs().subtract(6, 'month').add(1, 'days'), dayjs()],\n lastYearFromToday: [dayjs().subtract(1, 'year').add(1, 'days'), dayjs()],\n} satisfies RangesConfigPresetType;\n\n// TODO fix css for range mode (more lateral padding)\n@Component({\n changeDetection: ChangeDetectionStrategy.OnPush,\n selector: 'ap-datepicker',\n templateUrl: './datepicker.component.html',\n imports: [SymbolComponent, NgxDaterangepickerMd],\n styleUrls: ['./datepicker.component.scss'],\n})\nexport class DatepickerComponent implements OnInit, OnChanges, AfterViewInit {\n @ViewChild('datepickerRef') datepickerRef!: DaterangepickerComponent;\n\n @Input() firstDayOfWeek = 'monday';\n @Input() i18n: I18nDatePicker = {\n ranges: {\n yesterday: 'Yesterday',\n lastWeek: 'Last Week',\n last30Days: 'Last 30 days',\n lastMonth: 'Previous month',\n thisMonth: 'This month',\n },\n };\n @Input() locale = 'en';\n @Input() set maxDate(maxDate: dayjs.Dayjs | undefined) {\n if (maxDate) {\n this.maxDateStr = maxDate.toISOString();\n } else {\n this.maxDateStr = '';\n }\n }\n @Input() set minDate(minDate: dayjs.Dayjs | undefined) {\n if (minDate) {\n this.minDateStr = minDate.toISOString();\n } else {\n this.minDateStr = '';\n }\n }\n @Input({\n required: true,\n })\n mode!: DatepickerMode;\n @Input() selectedDate: dayjs.Dayjs | undefined = undefined;\n @Input() selectedDates: dayjs.Dayjs[] = [];\n @Input() selectedPeriod: Period = { startDate: undefined, endDate: undefined };\n @Input() showRanges = false;\n showCustomRangeLabel = input<boolean>(false);\n\n @Output() dateSelected = new EventEmitter<any>();\n @Output() periodSelected = new EventEmitter<Period>();\n\n DatepickerMode = DatepickerMode;\n doubleCalendarWidth = 528; // 231px calendar table * 2 = 462 (+ 16px x-padding * 4 = 64)\n localeConfig!: {\n customRangeLabel: string;\n daysOfWeek: string[];\n monthNames: string[];\n firstDay: number;\n };\n rangesConfig = input<RangesConfigPresetType | null>(null);\n ranges: RangesConfigPresetType = {};\n rangePickerWidth = 150;\n width = 0;\n pageSet = false;\n maxDateStr: string = '';\n minDateStr: string = '';\n constructor(\n public changeDetectorRef: ChangeDetectorRef,\n public symbolRegistry: SymbolRegistry\n ) {\n this.symbolRegistry.registerSymbols([apArrowLeft, apArrowRight]);\n }\n\n ngOnInit() {\n dayjs.extend(localeData);\n const rangesConfig = this.rangesConfig();\n if (rangesConfig) {\n this.ranges = rangesConfig;\n } else {\n // if config not defined - init default ranges\n this.initRanges();\n }\n this.initDatePickerLocale();\n }\n\n ngOnChanges(changes: SimpleChanges) {\n this.setWidth();\n if (this.datepickerRef) {\n setTimeout(() => {\n this.datepickerRef.updateCalendars();\n this.changeDetectorRef.detectChanges();\n }, 100);\n }\n if (changes.selectedPeriod?.currentValue && this.datepickerRef) {\n if (this.selectedPeriod.startDate === null && this.selectedPeriod.endDate === null) {\n this.datepickerRef.clear();\n } else {\n this.datepickerRef.setStartDate(this.selectedPeriod?.startDate ?? dayjs(undefined));\n this.datepickerRef.setEndDate(this.selectedPeriod.endDate ?? dayjs(undefined));\n }\n }\n if (changes.mode?.currentValue === DatepickerMode.Single && this.datepickerRef) {\n this.setCalendarCurrentPage();\n }\n }\n ngAfterViewInit(): void {\n if (this.datepickerRef) {\n setTimeout(() => {\n this.datepickerRef.updateCalendars();\n this.setCalendarCurrentPage();\n }, 100);\n }\n }\n\n initDatePickerLocale() {\n if (this.locale) {\n dayjs.locale(this.locale);\n }\n let firstDayOfWeekIndex: number;\n if (this.firstDayOfWeek === 'sunday') {\n firstDayOfWeekIndex = 0;\n } else if (this.firstDayOfWeek === 'monday') {\n firstDayOfWeekIndex = 1;\n } else {\n firstDayOfWeekIndex = dayjs.localeData().firstDayOfWeek();\n }\n this.localeConfig = {\n customRangeLabel: 'Custom',\n daysOfWeek: dayjs.weekdaysMin(),\n monthNames: dayjs.months(),\n firstDay: firstDayOfWeekIndex,\n };\n }\n\n private initRanges(): void {\n this.ranges[this.i18n.ranges.yesterday] = RangesConfigPreset.yesterday;\n this.ranges[this.i18n.ranges.lastWeek] = RangesConfigPreset.lastWeek;\n this.ranges[this.i18n.ranges.last30Days] = RangesConfigPreset.last30Days;\n this.ranges[this.i18n.ranges.lastMonth] = RangesConfigPreset.lastMonth;\n this.ranges[this.i18n.ranges.thisMonth] = RangesConfigPreset.thisMonth;\n }\n\n isCustomDate = (date: any) => {\n const classes: string[] = [];\n if (this.mode === DatepickerMode.Multiple) {\n classes.push(this.isSelected(date) ? 'active' : 'force-inactive');\n } else if (this.mode === DatepickerMode.Single) {\n classes.push(this.selectedDate && this.selectedDate.isSame(date, 'day') ? 'active' : 'force-inactive');\n } else if (this.mode === DatepickerMode.Range) {\n classes.push('range-picker-mode');\n // Workaround to fix the auto-active today date when no date is selected\n if (dayjs().isSame(date, 'day') && !this.selectedPeriod?.startDate && !this.selectedPeriod?.endDate) {\n classes.push('force-inactive');\n }\n }\n return classes;\n };\n\n private isSelected(date: any) {\n return this.selectedDates && this.selectedDates.some(selectedDate => selectedDate.isSame(date, 'day'));\n }\n\n onStartDateChanged(event: StartDate) {\n const date = event.startDate.toDate();\n const dateLocalTime = new Date(date.getTime());\n const dayJsDate = dayjs(dateLocalTime);\n if (this.mode !== DatepickerMode.Range) {\n this.selectedDate = dayJsDate;\n this.datepickerRef.setEndDate(dayJsDate);\n if (this.pageSet) {\n this.pageSet = false;\n } else {\n this.dateSelected.emit(dayJsDate.clone());\n if (this.mode === DatepickerMode.Multiple) {\n this.selectedDates.push(dayJsDate);\n }\n }\n if (this.datepickerRef) {\n this.datepickerRef.updateCalendars();\n }\n }\n }\n\n onDatesUpdated(event: Period) {\n if (this.mode === DatepickerMode.Range) {\n const startDate = event.startDate?.toDate();\n const startDateLocalTime = startDate ? new Date(startDate.getTime()) : new Date();\n const endDate = event.endDate?.toDate();\n const endDateLocalTime = endDate ? new Date(endDate.getTime()) : new Date();\n this.periodSelected.emit({\n startDate: dayjs(startDateLocalTime).startOf('day'),\n endDate: dayjs(endDateLocalTime).endOf('day'),\n });\n }\n if (this.datepickerRef) {\n this.datepickerRef.updateCalendars();\n }\n }\n\n onNextMonth() {\n this.datepickerRef.leftCalendar.month = this.datepickerRef.leftCalendar.month.add(1, 'months').clone();\n this.datepickerRef.rightCalendar.month = this.datepickerRef.rightCalendar.month.add(1, 'months').clone();\n this.datepickerRef.clickNext(SideEnum.left);\n this.datepickerRef.clickNext(SideEnum.right);\n }\n\n onPreviousMonth() {\n this.datepickerRef.leftCalendar.month = this.datepickerRef.leftCalendar.month.subtract(1, 'months').clone();\n this.datepickerRef.rightCalendar.month = this.datepickerRef.rightCalendar.month.subtract(1, 'months').clone();\n this.datepickerRef.clickPrev(SideEnum.left);\n this.datepickerRef.clickPrev(SideEnum.right);\n }\n\n /**\n * Ugly hack used here to open the calendar on the right day if they are selected dates\n * * https://github.com/fetrarij/ngx-daterangepicker-material/issues/139\n */\n setCalendarCurrentPage(): void {\n const selectedFirstDate = this.selectedDates.length > 0 ? this.selectedDates[0] : this.selectedDate;\n if (selectedFirstDate && selectedFirstDate.isValid() && this.mode !== DatepickerMode.Range) {\n const endDate = selectedFirstDate.clone();\n endDate.add(1, 'month');\n this.pageSet = true;\n this.datepickerRef.setStartDate(selectedFirstDate);\n this.datepickerRef.setEndDate(endDate);\n this.datepickerRef.updateView();\n }\n this.changeDetectorRef.detectChanges();\n }\n\n setWidth() {\n this.width =\n this.showRanges && this.mode === DatepickerMode.Range\n ? this.doubleCalendarWidth + this.rangePickerWidth\n : this.doubleCalendarWidth;\n }\n}\n","<div\n class=\"custom-calendar\"\n [style.width]=\"width + 'px'\">\n <div class=\"custom-header\">\n @if (datepickerRef.leftCalendar.month) {\n <div class=\"month-header\">\n <div\n class=\"month-arrow-button\"\n (click)=\"onPreviousMonth()\">\n <ap-symbol\n symbolId=\"arrow-left\"\n [color]=\"'#858FA1'\"\n [size]=\"14\" />\n </div>\n <div class=\"month-label\">\n {{ datepickerRef.leftCalendar.month.locale(locale).format('MMMM YYYY') }}\n </div>\n </div>\n }\n @if (datepickerRef.rightCalendar.month) {\n <div class=\"month-header\">\n <div class=\"month-label\">\n {{ datepickerRef.rightCalendar.month.locale(locale).format('MMMM YYYY') }}\n </div>\n <div\n class=\"month-arrow-button\"\n (click)=\"onNextMonth()\">\n <ap-symbol\n symbolId=\"arrow-right\"\n [color]=\"'#858FA1'\"\n [size]=\"14\" />\n </div>\n </div>\n }\n @if (showRanges && mode === DatepickerMode.Range) {\n <div class=\"header-filler\"></div>\n }\n </div>\n <ngx-daterangepicker-material\n #datepickerRef\n [class.hide-ranges]=\"!showRanges\"\n [alwaysShowCalendars]=\"true\"\n [autoApply]=\"true\"\n [customRangeDirection]=\"true\"\n [isCustomDate]=\"$any(isCustomDate)\"\n [locale]=\"localeConfig\"\n [maxDate]=\"maxDateStr\"\n [minDate]=\"minDateStr\"\n [ranges]=\"showRanges && mode === DatepickerMode.Range ? ranges : $any(null)\"\n [showCustomRangeLabel]=\"showCustomRangeLabel()\"\n (datesUpdated)=\"onDatesUpdated($event)\"\n (startDateChanged)=\"onStartDateChanged($event)\" />\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;IAyBY;AAAZ,CAAA,UAAY,cAAc,EAAA;AACtB,IAAA,cAAA,CAAA,QAAA,CAAA,GAAA,QAAiB;AACjB,IAAA,cAAA,CAAA,UAAA,CAAA,GAAA,UAAqB;AACrB,IAAA,cAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACnB,CAAC,EAJW,cAAc,KAAd,cAAc,GAAA,EAAA,CAAA,CAAA;AA0B1B,IAAK,QAGJ;AAHD,CAAA,UAAK,QAAQ,EAAA;AACT,IAAA,QAAA,CAAA,MAAA,CAAA,GAAA,MAAa;AACb,IAAA,QAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACnB,CAAC,EAHI,QAAQ,KAAR,QAAQ,GAAA,EAAA,CAAA,CAAA;AAMN,MAAM,kBAAkB,GAAG;IAC9B,SAAS,EAAE,CAAC,KAAK,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,MAAM,CAAC,EAAE,KAAK,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;IACrE,QAAQ,EAAE,CAAC,KAAK,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,MAAM,CAAC,EAAE,KAAK,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;IACpE,UAAU,EAAE,CAAC,KAAK,EAAE,CAAC,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC,EAAE,KAAK,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;AACvE,IAAA,SAAS,EAAE,CAAC,KAAK,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,EAAE,KAAK,EAAE,CAAC,QAAQ,CAAC,CA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AAc,EAAA,CAAA;sBAAvB;;;AEtHL;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"agorapulse-ui-components-datepicker.mjs","sources":["../../../libs/ui-components/datepicker/src/datepicker.component.ts","../../../libs/ui-components/datepicker/src/datepicker.component.html","../../../libs/ui-components/datepicker/src/agorapulse-ui-components-datepicker.ts"],"sourcesContent":["import { SymbolComponent, SymbolRegistry, apArrowLeft, apArrowRight } from '@agorapulse/ui-symbol';\n\nimport { DaterangepickerComponent, NgxDaterangepickerMd } from '@agorapulse/ngx-daterangepicker-material';\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n EventEmitter,\n Input,\n OnChanges,\n OnInit,\n Output,\n SimpleChanges,\n ViewChild,\n input,\n} from '@angular/core';\nimport dayjs from 'dayjs';\nimport 'dayjs/locale/de';\nimport 'dayjs/locale/en';\nimport 'dayjs/locale/es';\nimport 'dayjs/locale/fr';\nimport 'dayjs/locale/pt';\nimport localeData from 'dayjs/plugin/localeData';\n\nexport enum DatepickerMode {\n Single = 'Single',\n Multiple = 'Multiple',\n Range = 'Range',\n}\n\nexport interface Period {\n startDate?: dayjs.Dayjs;\n endDate?: dayjs.Dayjs;\n}\n\nexport interface StartDate {\n startDate: dayjs.Dayjs;\n}\n\nexport interface I18nDatePicker {\n ranges: {\n yesterday: string;\n lastWeek: string;\n last30Days: string;\n lastMonth: string;\n thisMonth: string;\n [other: string]: string;\n };\n}\n\nenum SideEnum {\n left = 'left',\n right = 'right',\n}\n\nexport type RangesConfigPresetType = { [periodText: string]: [dayjs.Dayjs, dayjs.Dayjs] };\nexport const RangesConfigPreset = {\n yesterday: [dayjs().subtract(1, 'days'), dayjs().subtract(1, 'days')],\n lastWeek: [dayjs().subtract(7, 'days'), dayjs().subtract(1, 'days')],\n last30Days: [dayjs().subtract(30, 'days'), dayjs().subtract(1, 'days')],\n lastMonth: [dayjs().subtract(1, 'month').startOf('month'), dayjs().subtract(1, 'month').endOf('month')],\n thisMonth: [dayjs().startOf('month'), dayjs().endOf('month')],\n\n lastWeekFromToday: [dayjs().subtract(6, 'days'), dayjs()],\n lastMonthFromToday: [dayjs().subtract(1, 'month').add(1, 'days'), dayjs()],\n last3MonthsFromToday: [dayjs().subtract(3, 'month').add(1, 'days'), dayjs()],\n last6MonthsFromToday: [dayjs().subtract(6, 'month').add(1, 'days'), dayjs()],\n lastYearFromToday: [dayjs().subtract(1, 'year').add(1, 'days'), dayjs()],\n} satisfies RangesConfigPresetType;\n\n// TODO fix css for range mode (more lateral padding)\n@Component({\n changeDetection: ChangeDetectionStrategy.OnPush,\n selector: 'ap-datepicker',\n templateUrl: './datepicker.component.html',\n imports: [SymbolComponent, NgxDaterangepickerMd],\n styleUrls: ['./datepicker.component.scss'],\n})\nexport class DatepickerComponent implements OnInit, OnChanges, AfterViewInit {\n @ViewChild('datepickerRef') datepickerRef!: DaterangepickerComponent;\n\n @Input() firstDayOfWeek = 'monday';\n @Input() i18n: I18nDatePicker = {\n ranges: {\n yesterday: 'Yesterday',\n lastWeek: 'Last Week',\n last30Days: 'Last 30 days',\n lastMonth: 'Previous month',\n thisMonth: 'This month',\n },\n };\n @Input() locale = 'en';\n @Input() set maxDate(maxDate: dayjs.Dayjs | undefined) {\n if (maxDate) {\n this.maxDateStr = maxDate.toISOString();\n } else {\n this.maxDateStr = '';\n }\n }\n @Input() set minDate(minDate: dayjs.Dayjs | undefined) {\n if (minDate) {\n this.minDateStr = minDate.toISOString();\n } else {\n this.minDateStr = '';\n }\n }\n @Input({\n required: true,\n })\n mode!: DatepickerMode;\n @Input() selectedDate: dayjs.Dayjs | undefined = undefined;\n @Input() selectedDates: dayjs.Dayjs[] = [];\n @Input() selectedPeriod: Period = { startDate: undefined, endDate: undefined };\n @Input() showRanges = false;\n showCustomRangeLabel = input<boolean>(false);\n\n @Output() dateSelected = new EventEmitter<any>();\n @Output() periodSelected = new EventEmitter<Period>();\n\n DatepickerMode = DatepickerMode;\n doubleCalendarWidth = 528; // 231px calendar table * 2 = 462 (+ 16px x-padding * 4 = 64)\n localeConfig!: {\n customRangeLabel: string;\n daysOfWeek: string[];\n monthNames: string[];\n firstDay: number;\n };\n rangesConfig = input<RangesConfigPresetType | null>(null);\n ranges: RangesConfigPresetType = {};\n rangePickerWidth = 150;\n width = 0;\n pageSet = false;\n maxDateStr: string = '';\n minDateStr: string = '';\n constructor(\n public changeDetectorRef: ChangeDetectorRef,\n public symbolRegistry: SymbolRegistry\n ) {\n this.symbolRegistry.registerSymbols([apArrowLeft, apArrowRight]);\n }\n\n ngOnInit() {\n dayjs.extend(localeData);\n const rangesConfig = this.rangesConfig();\n if (rangesConfig) {\n this.ranges = rangesConfig;\n } else {\n // if config not defined - init default ranges\n this.initRanges();\n }\n this.initDatePickerLocale();\n }\n\n ngOnChanges(changes: SimpleChanges) {\n this.setWidth();\n if (this.datepickerRef) {\n setTimeout(() => {\n this.datepickerRef.updateCalendars();\n this.changeDetectorRef.detectChanges();\n }, 100);\n }\n if (changes.selectedPeriod?.currentValue && this.datepickerRef) {\n if (this.selectedPeriod.startDate === null && this.selectedPeriod.endDate === null) {\n this.datepickerRef.clear();\n } else {\n this.datepickerRef.setStartDate(this.selectedPeriod?.startDate ?? dayjs(undefined));\n this.datepickerRef.setEndDate(this.selectedPeriod.endDate ?? dayjs(undefined));\n }\n }\n if (changes.mode?.currentValue === DatepickerMode.Single && this.datepickerRef) {\n this.setCalendarCurrentPage();\n }\n }\n ngAfterViewInit(): void {\n if (this.datepickerRef) {\n setTimeout(() => {\n if (this.mode === DatepickerMode.Range && this.selectedPeriod?.startDate) {\n this.datepickerRef.setStartDate(this.selectedPeriod.startDate);\n this.datepickerRef.setEndDate(this.selectedPeriod.endDate ?? this.selectedPeriod.startDate);\n }\n this.datepickerRef.updateCalendars();\n this.setCalendarCurrentPage();\n }, 100);\n }\n }\n\n initDatePickerLocale() {\n if (this.locale) {\n dayjs.locale(this.locale);\n }\n let firstDayOfWeekIndex: number;\n if (this.firstDayOfWeek === 'sunday') {\n firstDayOfWeekIndex = 0;\n } else if (this.firstDayOfWeek === 'monday') {\n firstDayOfWeekIndex = 1;\n } else {\n firstDayOfWeekIndex = dayjs.localeData().firstDayOfWeek();\n }\n this.localeConfig = {\n customRangeLabel: 'Custom',\n daysOfWeek: dayjs.weekdaysMin(),\n monthNames: dayjs.months(),\n firstDay: firstDayOfWeekIndex,\n };\n }\n\n private initRanges(): void {\n this.ranges[this.i18n.ranges.yesterday] = RangesConfigPreset.yesterday;\n this.ranges[this.i18n.ranges.lastWeek] = RangesConfigPreset.lastWeek;\n this.ranges[this.i18n.ranges.last30Days] = RangesConfigPreset.last30Days;\n this.ranges[this.i18n.ranges.lastMonth] = RangesConfigPreset.lastMonth;\n this.ranges[this.i18n.ranges.thisMonth] = RangesConfigPreset.thisMonth;\n }\n\n isCustomDate = (date: any) => {\n const classes: string[] = [];\n if (this.mode === DatepickerMode.Multiple) {\n classes.push(this.isSelected(date) ? 'active' : 'force-inactive');\n } else if (this.mode === DatepickerMode.Single) {\n classes.push(this.selectedDate && this.selectedDate.isSame(date, 'day') ? 'active' : 'force-inactive');\n } else if (this.mode === DatepickerMode.Range) {\n classes.push('range-picker-mode');\n // Workaround to fix the auto-active today date when no date is selected\n if (dayjs().isSame(date, 'day') && !this.selectedPeriod?.startDate && !this.selectedPeriod?.endDate) {\n classes.push('force-inactive');\n }\n }\n return classes;\n };\n\n private isSelected(date: any) {\n return this.selectedDates && this.selectedDates.some(selectedDate => selectedDate.isSame(date, 'day'));\n }\n\n onStartDateChanged(event: StartDate) {\n const date = event.startDate.toDate();\n const dateLocalTime = new Date(date.getTime());\n const dayJsDate = dayjs(dateLocalTime);\n if (this.mode !== DatepickerMode.Range) {\n this.selectedDate = dayJsDate;\n this.datepickerRef.setEndDate(dayJsDate);\n if (this.pageSet) {\n this.pageSet = false;\n } else {\n this.dateSelected.emit(dayJsDate.clone());\n if (this.mode === DatepickerMode.Multiple) {\n this.selectedDates.push(dayJsDate);\n }\n }\n if (this.datepickerRef) {\n this.datepickerRef.updateCalendars();\n }\n }\n }\n\n onDatesUpdated(event: Period) {\n if (this.mode === DatepickerMode.Range) {\n const startDate = event.startDate?.toDate();\n const startDateLocalTime = startDate ? new Date(startDate.getTime()) : new Date();\n const endDate = event.endDate?.toDate();\n const endDateLocalTime = endDate ? new Date(endDate.getTime()) : new Date();\n this.periodSelected.emit({\n startDate: dayjs(startDateLocalTime).startOf('day'),\n endDate: dayjs(endDateLocalTime).endOf('day'),\n });\n }\n if (this.datepickerRef) {\n this.datepickerRef.updateCalendars();\n }\n }\n\n onNextMonth() {\n this.datepickerRef.leftCalendar.month = this.datepickerRef.leftCalendar.month.add(1, 'months').clone();\n this.datepickerRef.rightCalendar.month = this.datepickerRef.rightCalendar.month.add(1, 'months').clone();\n this.datepickerRef.clickNext(SideEnum.left);\n this.datepickerRef.clickNext(SideEnum.right);\n }\n\n onPreviousMonth() {\n this.datepickerRef.leftCalendar.month = this.datepickerRef.leftCalendar.month.subtract(1, 'months').clone();\n this.datepickerRef.rightCalendar.month = this.datepickerRef.rightCalendar.month.subtract(1, 'months').clone();\n this.datepickerRef.clickPrev(SideEnum.left);\n this.datepickerRef.clickPrev(SideEnum.right);\n }\n\n /**\n * Ugly hack used here to open the calendar on the right day if they are selected dates\n * * https://github.com/fetrarij/ngx-daterangepicker-material/issues/139\n */\n setCalendarCurrentPage(): void {\n const selectedFirstDate = this.selectedDates.length > 0 ? this.selectedDates[0] : this.selectedDate;\n if (selectedFirstDate && selectedFirstDate.isValid() && this.mode !== DatepickerMode.Range) {\n const endDate = selectedFirstDate.clone();\n endDate.add(1, 'month');\n this.pageSet = true;\n this.datepickerRef.setStartDate(selectedFirstDate);\n this.datepickerRef.setEndDate(endDate);\n this.datepickerRef.updateView();\n }\n this.changeDetectorRef.detectChanges();\n }\n\n setWidth() {\n this.width =\n this.showRanges && this.mode === DatepickerMode.Range\n ? this.doubleCalendarWidth + this.rangePickerWidth\n : this.doubleCalendarWidth;\n }\n}\n","<div\n class=\"custom-calendar\"\n [style.width]=\"width + 'px'\">\n <div class=\"custom-header\">\n @if (datepickerRef.leftCalendar.month) {\n <div class=\"month-header\">\n <div\n class=\"month-arrow-button\"\n (click)=\"onPreviousMonth()\">\n <ap-symbol\n symbolId=\"arrow-left\"\n [color]=\"'#858FA1'\"\n [size]=\"14\" />\n </div>\n <div class=\"month-label\">\n {{ datepickerRef.leftCalendar.month.locale(locale).format('MMMM YYYY') }}\n </div>\n </div>\n }\n @if (datepickerRef.rightCalendar.month) {\n <div class=\"month-header\">\n <div class=\"month-label\">\n {{ datepickerRef.rightCalendar.month.locale(locale).format('MMMM YYYY') }}\n </div>\n <div\n class=\"month-arrow-button\"\n (click)=\"onNextMonth()\">\n <ap-symbol\n symbolId=\"arrow-right\"\n [color]=\"'#858FA1'\"\n [size]=\"14\" />\n </div>\n </div>\n }\n @if (showRanges && mode === DatepickerMode.Range) {\n <div class=\"header-filler\"></div>\n }\n </div>\n <ngx-daterangepicker-material\n #datepickerRef\n [class.hide-ranges]=\"!showRanges\"\n [alwaysShowCalendars]=\"true\"\n [autoApply]=\"true\"\n [customRangeDirection]=\"true\"\n [isCustomDate]=\"$any(isCustomDate)\"\n [locale]=\"localeConfig\"\n [maxDate]=\"maxDateStr\"\n [minDate]=\"minDateStr\"\n [ranges]=\"showRanges && mode === DatepickerMode.Range ? ranges : $any(null)\"\n [showCustomRangeLabel]=\"showCustomRangeLabel()\"\n (datesUpdated)=\"onDatesUpdated($event)\"\n (startDateChanged)=\"onStartDateChanged($event)\" />\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;IAyBY;AAAZ,CAAA,UAAY,cAAc,EAAA;AACtB,IAAA,cAAA,CAAA,QAAA,CAAA,GAAA,QAAiB;AACjB,IAAA,cAAA,CAAA,UAAA,CAAA,GAAA,UAAqB;AACrB,IAAA,cAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACnB,CAAC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AEG;;;;"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
+
import { ButtonComponent } from '@agorapulse/ui-components/button';
|
|
1
2
|
import { IconButtonComponent } from '@agorapulse/ui-components/icon-button';
|
|
2
3
|
import * as i2 from '@agorapulse/ui-symbol';
|
|
3
4
|
import { apClose, SymbolComponent } from '@agorapulse/ui-symbol';
|
|
4
5
|
import { NgStyle, NgClass, NgTemplateOutlet } from '@angular/common';
|
|
5
6
|
import * as i0 from '@angular/core';
|
|
6
7
|
import { Input, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
7
|
-
import { firstValueFrom } from 'rxjs';
|
|
8
8
|
import * as i1 from '@angular/material/dialog';
|
|
9
9
|
|
|
10
10
|
class ModalComponent {
|
|
@@ -59,9 +59,6 @@ class ModalComponent {
|
|
|
59
59
|
}
|
|
60
60
|
return dialogRef;
|
|
61
61
|
}
|
|
62
|
-
static async openAndWaitWithComponent(matDialog, config, componentType) {
|
|
63
|
-
return firstValueFrom(ModalComponent.openWithComponent(matDialog, config, componentType).afterClosed());
|
|
64
|
-
}
|
|
65
62
|
/**
|
|
66
63
|
* Use it to open a modal containing the provided templates, with the right configuration.
|
|
67
64
|
*/
|
|
@@ -84,7 +81,7 @@ class ModalComponent {
|
|
|
84
81
|
}
|
|
85
82
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: ModalComponent, decorators: [{
|
|
86
83
|
type: Component,
|
|
87
|
-
args: [{ changeDetection: ChangeDetectionStrategy.OnPush, selector: 'ap-modal', imports: [SymbolComponent, NgStyle, NgClass, NgTemplateOutlet, IconButtonComponent], template: "@if (sidePaneTemplate) {\n <div\n [ngStyle]=\"sidePaneStyle\"\n [ngClass]=\"{ pane: defaultLayout }\">\n <ng-template [ngTemplateOutlet]=\"sidePaneTemplate\" />\n </div>\n}\n\n<div\n class=\"modal-wrapper\"\n [ngStyle]=\"containerStyle\"\n [class.default-layout]=\"defaultLayout\">\n @if (closable) {\n <ap-icon-button\n class=\"close-button\"\n ariaLabel=\"Close button\"\n name=\"close-button\"\n color=\"none\"\n type=\"flat\"\n (onClick)=\"close()\">\n <ap-symbol symbolId=\"close\" />\n </ap-icon-button>\n }\n @if (headerTemplate && headerVisible) {\n <div\n [ngStyle]=\"headerStyle\"\n [ngClass]=\"{ header: defaultLayout }\"\n [class.border-bottom]=\"headerBottomBorderEnabled\">\n <ng-template [ngTemplateOutlet]=\"headerTemplate\" />\n </div>\n }\n @if (mainTemplate) {\n <div\n [ngStyle]=\"contentStyle\"\n [class.content]=\"defaultLayout\">\n <ng-template [ngTemplateOutlet]=\"mainTemplate\" />\n </div>\n }\n @if (footerTemplate && footerVisible) {\n <div\n [ngStyle]=\"footerStyle\"\n [ngClass]=\"{ footer: defaultLayout }\">\n <ng-template [ngTemplateOutlet]=\"footerTemplate\" />\n </div>\n }\n</div>\n", styles: ["[color=facebook]{color:#0866ff}[bgcolor=facebook],[hcolor=facebook]:hover{background-color:#0866ff}[border=facebook]{border:1px solid #0866ff}[color=google]{color:#4e85e8}[bgcolor=google],[hcolor=google]:hover{background-color:#4e85e8}[border=google]{border:1px solid #4e85e8}[color=instagram]{color:#e1306c}[bgcolor=instagram],[hcolor=instagram]:hover{background-color:#e1306c}[border=instagram]{border:1px solid #e1306c}[color=instagrammagenta]{color:#c13584}[bgcolor=instagrammagenta],[hcolor=instagrammagenta]:hover{background-color:#c13584}[border=instagrammagenta]{border:1px solid #c13584}[color=instagramblue]{color:#5851db}[bgcolor=instagramblue],[hcolor=instagramblue]:hover{background-color:#5851db}[border=instagramblue]{border:1px solid #5851db}[color=instagrampurple]{color:#833ab4}[bgcolor=instagrampurple],[hcolor=instagrampurple]:hover{background-color:#833ab4}[border=instagrampurple]{border:1px solid #833ab4}[color=instagramorange]{color:#f56040}[bgcolor=instagramorange],[hcolor=instagramorange]:hover{background-color:#f56040}[border=instagramorange]{border:1px solid #f56040}[color=instagramyellow]{color:#ffdc80}[bgcolor=instagramyellow],[hcolor=instagramyellow]:hover{background-color:#ffdc80}[border=instagramyellow]{border:1px solid #ffdc80}[color=linkedin]{color:#2c67bc}[bgcolor=linkedin],[hcolor=linkedin]:hover{background-color:#2c67bc}[border=linkedin]{border:1px solid #2c67bc}[color=twitter]{color:#55acee}[bgcolor=twitter],[hcolor=twitter]:hover{background-color:#55acee}[border=twitter]{border:1px solid #55acee}[color=youtube]{color:red}[bgcolor=youtube],[hcolor=youtube]:hover{background-color:red}[border=youtube]{border:1px solid #ff0000}[color=reddit]{color:#ff4500}[bgcolor=reddit],[hcolor=reddit]:hover{background-color:#ff4500}[border=reddit]{border:1px solid #ff4500}[color=blood-orange]{color:#ff4d00}[bgcolor=blood-orange],[hcolor=blood-orange]:hover{background-color:#ff4d00}[border=blood-orange]{border:1px solid #ff4d00}[color=pinkish-orange]{color:#ff7b49}[bgcolor=pinkish-orange],[hcolor=pinkish-orange]:hover{background-color:#ff7b49}[border=pinkish-orange]{border:1px solid #ff7b49}[color=charcoal-grey]{color:#2a2f34}[bgcolor=charcoal-grey],[hcolor=charcoal-grey]:hover{background-color:#2a2f34}[border=charcoal-grey]{border:1px solid #2a2f34}[color=azure]{color:#00aeef}[bgcolor=azure],[hcolor=azure]:hover{background-color:#00aeef}[border=azure]{border:1px solid #00aeef}[color=light-azure]{color:#eaf5fd}[bgcolor=light-azure],[hcolor=light-azure]:hover{background-color:#eaf5fd}[border=light-azure]{border:1px solid #eaf5fd}[color=blue-grey]{color:#8d98a9}[bgcolor=blue-grey],[hcolor=blue-grey]:hover{background-color:#8d98a9}[border=blue-grey]{border:1px solid #8d98a9}[color=silver]{color:#ced0da}[bgcolor=silver],[hcolor=silver]:hover{background-color:#ced0da}[border=silver]{border:1px solid #ced0da}[color=pale-grey]{color:#dfe3e9}[bgcolor=pale-grey],[hcolor=pale-grey]:hover{background-color:#dfe3e9}[border=pale-grey]{border:1px solid #dfe3e9}[color=grey-white]{color:#f5f7f8}[bgcolor=grey-white],[hcolor=grey-white]:hover{background-color:#f5f7f8}[border=grey-white]{border:1px solid #f5f7f8}[color=cool-grey]{color:#b4bbc6}[bgcolor=cool-grey],[hcolor=cool-grey]:hover{background-color:#b4bbc6}[border=cool-grey]{border:1px solid #b4bbc6}[color=black]{color:#344563}[bgcolor=black],[hcolor=black]:hover{background-color:#344563}[border=black]{border:1px solid #344563}[color=grey-blue]{color:#68768c}[bgcolor=grey-blue],[hcolor=grey-blue]:hover{background-color:#68768c}[border=grey-blue]{border:1px solid #68768c}[color=strawberry]{color:#f4282d}[bgcolor=strawberry],[hcolor=strawberry]:hover{background-color:#f4282d}[border=strawberry]{border:1px solid #f4282d}[color=light-strawberry]{color:#f8eded}[bgcolor=light-strawberry],[hcolor=light-strawberry]:hover{background-color:#f8eded}[border=light-strawberry]{border:1px solid #f8eded}[color=white]{color:#fff}[bgcolor=white],[hcolor=white]:hover{background-color:#fff}[border=white]{border:1px solid #ffffff}[color=cool-green]{color:#33c15d}[bgcolor=cool-green],[hcolor=cool-green]:hover{background-color:#33c15d}[border=cool-green]{border:1px solid #33c15d}[color=light-green]{color:#ebfaef}[bgcolor=light-green],[hcolor=light-green]:hover{background-color:#ebfaef}[border=light-green]{border:1px solid #ebfaef}[color=transparent]{color:transparent}[bgcolor=transparent],[hcolor=transparent]:hover{background-color:transparent}[border=transparent]{border:1px solid transparent}[color=c0]{color:#a566a5}[bgcolor=c0],[hcolor=c0]:hover{background-color:#a566a5}[border=c0]{border:1px solid #a566a5}[color=c1]{color:#c7ab82}[bgcolor=c1],[hcolor=c1]:hover{background-color:#c7ab82}[border=c1]{border:1px solid #c7ab82}[color=c2]{color:#f2713c}[bgcolor=c2],[hcolor=c2]:hover{background-color:#f2713c}[border=c2]{border:1px solid #f2713c}[color=c3]{color:#ffd006}[bgcolor=c3],[hcolor=c3]:hover{background-color:#ffd006}[border=c3]{border:1px solid #ffd006}[color=c4]{color:#94c5aa}[bgcolor=c4],[hcolor=c4]:hover{background-color:#94c5aa}[border=c4]{border:1px solid #94c5aa}[color=c5]{color:#2a9d8f}[bgcolor=c5],[hcolor=c5]:hover{background-color:#2a9d8f}[border=c5]{border:1px solid #2a9d8f}[color=c6]{color:#78acd8}[bgcolor=c6],[hcolor=c6]:hover{background-color:#78acd8}[border=c6]{border:1px solid #78acd8}[color=c7]{color:#525a9e}[bgcolor=c7],[hcolor=c7]:hover{background-color:#525a9e}[border=c7]{border:1px solid #525a9e}[color=c8]{color:#6a2459}[bgcolor=c8],[hcolor=c8]:hover{background-color:#6a2459}[border=c8]{border:1px solid #6a2459}[color=c9]{color:#74729e}[bgcolor=c9],[hcolor=c9]:hover{background-color:#74729e}[border=c9]{border:1px solid #74729e}:host{display:flex;flex-direction:row;max-height:90vh}.modal-wrapper{position:relative;width:100%;display:flex;flex-direction:column}.modal-wrapper.default-layout{padding-top:24px;padding-bottom:16px}.modal-wrapper .close-button{margin:-12px;position:absolute;right:24px;top:24px}.modal-wrapper .close-button ap-symbol{height:12px;width:12px}.modal-wrapper .header ::ng-deep h2{margin-top:0}.modal-wrapper .header{padding:0 24px 16px}.modal-wrapper .header.border-bottom{border-bottom:1px solid #eaecef;margin-bottom:16px}.modal-wrapper .content{color:#5d6a82;font-size:16px;padding:0 24px;flex:1;overflow-y:auto;overflow-x:hidden}.modal-wrapper .footer{align-items:center;box-shadow:0 1px #eaecef inset;display:flex;justify-content:flex-end;margin-top:24px;padding:16px 24px 0}.pane{padding:24px}::ng-deep .modal-container{max-width:100vw!important;margin:24px 24px 64px}::ng-deep .modal-container .mat-mdc-dialog-container .mdc-dialog__surface{border-radius:10px;box-shadow:0 25px 50px #0000000a;max-width:100vw;padding:0}::ng-deep .cdk-overlay-dark-backdrop{background:#344563b3}\n"] }]
|
|
84
|
+
args: [{ changeDetection: ChangeDetectionStrategy.OnPush, selector: 'ap-modal', imports: [SymbolComponent, NgStyle, NgClass, ButtonComponent, NgTemplateOutlet, IconButtonComponent], template: "@if (sidePaneTemplate) {\n <div\n [ngStyle]=\"sidePaneStyle\"\n [ngClass]=\"{ pane: defaultLayout }\">\n <ng-template [ngTemplateOutlet]=\"sidePaneTemplate\" />\n </div>\n}\n\n<div\n class=\"modal-wrapper\"\n [ngStyle]=\"containerStyle\"\n [class.default-layout]=\"defaultLayout\">\n @if (closable) {\n <ap-icon-button\n class=\"close-button\"\n ariaLabel=\"Close button\"\n name=\"close-button\"\n color=\"none\"\n type=\"flat\"\n (onClick)=\"close()\">\n <ap-symbol symbolId=\"close\" />\n </ap-icon-button>\n }\n @if (headerTemplate && headerVisible) {\n <div\n [ngStyle]=\"headerStyle\"\n [ngClass]=\"{ header: defaultLayout }\"\n [class.border-bottom]=\"headerBottomBorderEnabled\">\n <ng-template [ngTemplateOutlet]=\"headerTemplate\" />\n </div>\n }\n @if (mainTemplate) {\n <div\n [ngStyle]=\"contentStyle\"\n [class.content]=\"defaultLayout\">\n <ng-template [ngTemplateOutlet]=\"mainTemplate\" />\n </div>\n }\n @if (footerTemplate && footerVisible) {\n <div\n [ngStyle]=\"footerStyle\"\n [ngClass]=\"{ footer: defaultLayout }\">\n <ng-template [ngTemplateOutlet]=\"footerTemplate\" />\n </div>\n }\n</div>\n", styles: ["[color=facebook]{color:#0866ff}[bgcolor=facebook],[hcolor=facebook]:hover{background-color:#0866ff}[border=facebook]{border:1px solid #0866ff}[color=google]{color:#4e85e8}[bgcolor=google],[hcolor=google]:hover{background-color:#4e85e8}[border=google]{border:1px solid #4e85e8}[color=instagram]{color:#e1306c}[bgcolor=instagram],[hcolor=instagram]:hover{background-color:#e1306c}[border=instagram]{border:1px solid #e1306c}[color=instagrammagenta]{color:#c13584}[bgcolor=instagrammagenta],[hcolor=instagrammagenta]:hover{background-color:#c13584}[border=instagrammagenta]{border:1px solid #c13584}[color=instagramblue]{color:#5851db}[bgcolor=instagramblue],[hcolor=instagramblue]:hover{background-color:#5851db}[border=instagramblue]{border:1px solid #5851db}[color=instagrampurple]{color:#833ab4}[bgcolor=instagrampurple],[hcolor=instagrampurple]:hover{background-color:#833ab4}[border=instagrampurple]{border:1px solid #833ab4}[color=instagramorange]{color:#f56040}[bgcolor=instagramorange],[hcolor=instagramorange]:hover{background-color:#f56040}[border=instagramorange]{border:1px solid #f56040}[color=instagramyellow]{color:#ffdc80}[bgcolor=instagramyellow],[hcolor=instagramyellow]:hover{background-color:#ffdc80}[border=instagramyellow]{border:1px solid #ffdc80}[color=linkedin]{color:#2c67bc}[bgcolor=linkedin],[hcolor=linkedin]:hover{background-color:#2c67bc}[border=linkedin]{border:1px solid #2c67bc}[color=twitter]{color:#55acee}[bgcolor=twitter],[hcolor=twitter]:hover{background-color:#55acee}[border=twitter]{border:1px solid #55acee}[color=youtube]{color:red}[bgcolor=youtube],[hcolor=youtube]:hover{background-color:red}[border=youtube]{border:1px solid #ff0000}[color=reddit]{color:#ff4500}[bgcolor=reddit],[hcolor=reddit]:hover{background-color:#ff4500}[border=reddit]{border:1px solid #ff4500}[color=blood-orange]{color:#ff4d00}[bgcolor=blood-orange],[hcolor=blood-orange]:hover{background-color:#ff4d00}[border=blood-orange]{border:1px solid #ff4d00}[color=pinkish-orange]{color:#ff7b49}[bgcolor=pinkish-orange],[hcolor=pinkish-orange]:hover{background-color:#ff7b49}[border=pinkish-orange]{border:1px solid #ff7b49}[color=charcoal-grey]{color:#2a2f34}[bgcolor=charcoal-grey],[hcolor=charcoal-grey]:hover{background-color:#2a2f34}[border=charcoal-grey]{border:1px solid #2a2f34}[color=azure]{color:#00aeef}[bgcolor=azure],[hcolor=azure]:hover{background-color:#00aeef}[border=azure]{border:1px solid #00aeef}[color=light-azure]{color:#eaf5fd}[bgcolor=light-azure],[hcolor=light-azure]:hover{background-color:#eaf5fd}[border=light-azure]{border:1px solid #eaf5fd}[color=blue-grey]{color:#8d98a9}[bgcolor=blue-grey],[hcolor=blue-grey]:hover{background-color:#8d98a9}[border=blue-grey]{border:1px solid #8d98a9}[color=silver]{color:#ced0da}[bgcolor=silver],[hcolor=silver]:hover{background-color:#ced0da}[border=silver]{border:1px solid #ced0da}[color=pale-grey]{color:#dfe3e9}[bgcolor=pale-grey],[hcolor=pale-grey]:hover{background-color:#dfe3e9}[border=pale-grey]{border:1px solid #dfe3e9}[color=grey-white]{color:#f5f7f8}[bgcolor=grey-white],[hcolor=grey-white]:hover{background-color:#f5f7f8}[border=grey-white]{border:1px solid #f5f7f8}[color=cool-grey]{color:#b4bbc6}[bgcolor=cool-grey],[hcolor=cool-grey]:hover{background-color:#b4bbc6}[border=cool-grey]{border:1px solid #b4bbc6}[color=black]{color:#344563}[bgcolor=black],[hcolor=black]:hover{background-color:#344563}[border=black]{border:1px solid #344563}[color=grey-blue]{color:#68768c}[bgcolor=grey-blue],[hcolor=grey-blue]:hover{background-color:#68768c}[border=grey-blue]{border:1px solid #68768c}[color=strawberry]{color:#f4282d}[bgcolor=strawberry],[hcolor=strawberry]:hover{background-color:#f4282d}[border=strawberry]{border:1px solid #f4282d}[color=light-strawberry]{color:#f8eded}[bgcolor=light-strawberry],[hcolor=light-strawberry]:hover{background-color:#f8eded}[border=light-strawberry]{border:1px solid #f8eded}[color=white]{color:#fff}[bgcolor=white],[hcolor=white]:hover{background-color:#fff}[border=white]{border:1px solid #ffffff}[color=cool-green]{color:#33c15d}[bgcolor=cool-green],[hcolor=cool-green]:hover{background-color:#33c15d}[border=cool-green]{border:1px solid #33c15d}[color=light-green]{color:#ebfaef}[bgcolor=light-green],[hcolor=light-green]:hover{background-color:#ebfaef}[border=light-green]{border:1px solid #ebfaef}[color=transparent]{color:transparent}[bgcolor=transparent],[hcolor=transparent]:hover{background-color:transparent}[border=transparent]{border:1px solid transparent}[color=c0]{color:#a566a5}[bgcolor=c0],[hcolor=c0]:hover{background-color:#a566a5}[border=c0]{border:1px solid #a566a5}[color=c1]{color:#c7ab82}[bgcolor=c1],[hcolor=c1]:hover{background-color:#c7ab82}[border=c1]{border:1px solid #c7ab82}[color=c2]{color:#f2713c}[bgcolor=c2],[hcolor=c2]:hover{background-color:#f2713c}[border=c2]{border:1px solid #f2713c}[color=c3]{color:#ffd006}[bgcolor=c3],[hcolor=c3]:hover{background-color:#ffd006}[border=c3]{border:1px solid #ffd006}[color=c4]{color:#94c5aa}[bgcolor=c4],[hcolor=c4]:hover{background-color:#94c5aa}[border=c4]{border:1px solid #94c5aa}[color=c5]{color:#2a9d8f}[bgcolor=c5],[hcolor=c5]:hover{background-color:#2a9d8f}[border=c5]{border:1px solid #2a9d8f}[color=c6]{color:#78acd8}[bgcolor=c6],[hcolor=c6]:hover{background-color:#78acd8}[border=c6]{border:1px solid #78acd8}[color=c7]{color:#525a9e}[bgcolor=c7],[hcolor=c7]:hover{background-color:#525a9e}[border=c7]{border:1px solid #525a9e}[color=c8]{color:#6a2459}[bgcolor=c8],[hcolor=c8]:hover{background-color:#6a2459}[border=c8]{border:1px solid #6a2459}[color=c9]{color:#74729e}[bgcolor=c9],[hcolor=c9]:hover{background-color:#74729e}[border=c9]{border:1px solid #74729e}:host{display:flex;flex-direction:row;max-height:90vh}.modal-wrapper{position:relative;width:100%;display:flex;flex-direction:column}.modal-wrapper.default-layout{padding-top:24px;padding-bottom:16px}.modal-wrapper .close-button{margin:-12px;position:absolute;right:24px;top:24px}.modal-wrapper .close-button ap-symbol{height:12px;width:12px}.modal-wrapper .header ::ng-deep h2{margin-top:0}.modal-wrapper .header{padding:0 24px 16px}.modal-wrapper .header.border-bottom{border-bottom:1px solid #eaecef;margin-bottom:16px}.modal-wrapper .content{color:#5d6a82;font-size:16px;padding:0 24px;flex:1;overflow-y:auto;overflow-x:hidden}.modal-wrapper .footer{align-items:center;box-shadow:0 1px #eaecef inset;display:flex;justify-content:flex-end;margin-top:24px;padding:16px 24px 0}.pane{padding:24px}::ng-deep .modal-container{max-width:100vw!important;margin:24px 24px 64px}::ng-deep .modal-container .mat-mdc-dialog-container .mdc-dialog__surface{border-radius:10px;box-shadow:0 25px 50px #0000000a;max-width:100vw;padding:0}::ng-deep .cdk-overlay-dark-backdrop{background:#344563b3}\n"] }]
|
|
88
85
|
}], ctorParameters: () => [{ type: i1.MatDialogRef }, { type: i2.SymbolRegistry }], propDecorators: { closable: [{
|
|
89
86
|
type: Input
|
|
90
87
|
}], headerBottomBorderEnabled: [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agorapulse-ui-components-modal.mjs","sources":["../../../libs/ui-components/modal/src/modal.component.ts","../../../libs/ui-components/modal/src/modal.component.html","../../../libs/ui-components/modal/src/agorapulse-ui-components-modal.ts"],"sourcesContent":["import { IconButtonComponent } from '@agorapulse/ui-components/icon-button';\nimport { apClose, SymbolComponent, SymbolRegistry } from '@agorapulse/ui-symbol';\nimport { ComponentType } from '@angular/cdk/portal';\nimport { NgClass, NgStyle, NgTemplateOutlet } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, Input, TemplateRef } from '@angular/core';\nimport { MatDialog, MatDialogConfig, MatDialogRef } from '@angular/material/dialog';\nimport { firstValueFrom } from 'rxjs';\n\nexport interface ModalConfig<T = unknown> extends ModalConfigBase<T> {\n closable?: boolean;\n headerBottomBorderEnabled?: boolean;\n}\n\nexport interface ModalConfigBase<T> {\n backdropCloseEnable?: boolean;\n matDialogConfig?: MatDialogConfig<T>;\n}\n\ninterface HasDialogRef<T, R> {\n dialogRef: MatDialogRef<T, R>;\n}\ninterface HasModalData<D> {\n modalData: D;\n}\n\ntype ExtractDialogRef<C> = C extends HasDialogRef<infer T, infer R> ? MatDialogRef<T, R> : MatDialogRef<C>;\ntype ExtractModalData<C> = C extends HasModalData<infer D> ? D : unknown;\n\n@Component({\n changeDetection: ChangeDetectionStrategy.OnPush,\n selector: 'ap-modal',\n templateUrl: 'modal.component.html',\n imports: [SymbolComponent, NgStyle, NgClass, NgTemplateOutlet, IconButtonComponent],\n styleUrls: ['modal.component.scss'],\n})\nexport class ModalComponent {\n static readonly PANEL_CLASS = 'modal-container';\n\n constructor(\n public dialogRef: MatDialogRef<ModalComponent, void>,\n public symbolRegistry: SymbolRegistry\n ) {\n dialogRef.disableClose = true;\n this.symbolRegistry.registerSymbols([apClose]);\n }\n\n @Input() closable = false;\n @Input() headerBottomBorderEnabled = false;\n @Input() footerTemplate: TemplateRef<any> | undefined = undefined;\n @Input() footerVisible = true;\n @Input() headerTemplate: TemplateRef<any> | undefined = undefined;\n @Input() headerVisible = true;\n @Input({\n required: true,\n })\n mainTemplate!: TemplateRef<any>;\n @Input() sidePaneTemplate: TemplateRef<any> | undefined = undefined;\n @Input() sidePaneStyle: { [arg: string]: string } | undefined = {};\n @Input() containerStyle: { [arg: string]: string } | undefined = {};\n @Input() headerStyle: { [arg: string]: string } | undefined = {};\n @Input() contentStyle: { [arg: string]: string } | undefined = {};\n @Input() footerStyle: { [arg: string]: string } | undefined = {};\n @Input() defaultLayout = true;\n\n /**\n * Use it to open a modal containing the {@link componentType} component, with the right configuration.\n */\n static openWithComponent<C>(\n matDialog: MatDialog,\n config: ModalConfigBase<ExtractModalData<C>> | undefined,\n componentType: ComponentType<C>\n ): ExtractDialogRef<C> {\n let matDialogConfig: MatDialogConfig<unknown> | undefined;\n if (config) {\n matDialogConfig = config.matDialogConfig;\n if (matDialogConfig && config.matDialogConfig) {\n matDialogConfig.panelClass = Array.isArray(config.matDialogConfig.panelClass)\n ? [...config.matDialogConfig.panelClass, ModalComponent.PANEL_CLASS] // in case where the panelClass is an array\n : [config.matDialogConfig.panelClass ?? '', ModalComponent.PANEL_CLASS]; // in the other case, it's a String\n } else {\n matDialogConfig = { panelClass: ModalComponent.PANEL_CLASS };\n }\n } else {\n matDialogConfig = {\n panelClass: ModalComponent.PANEL_CLASS,\n };\n }\n matDialogConfig.autoFocus = false; // Prevent first button to be focused\n\n const dialogRef = matDialog.open(componentType, matDialogConfig);\n if (config?.backdropCloseEnable === true) {\n dialogRef.disableClose = false;\n }\n return dialogRef as ExtractDialogRef<C>;\n }\n\n static async openAndWaitWithComponent<C>(\n matDialog: MatDialog,\n config: ModalConfigBase<ExtractModalData<C>> | undefined,\n componentType: ComponentType<C>\n ): Promise<C extends HasDialogRef<unknown, infer R> ? R : unknown> {\n return firstValueFrom(ModalComponent.openWithComponent(matDialog, config, componentType).afterClosed());\n }\n\n /**\n * Use it to open a modal containing the provided templates, with the right configuration.\n */\n static openWithTemplates<T>(\n matDialog: MatDialog,\n headerTemplate: TemplateRef<any> | undefined,\n mainTemplate: TemplateRef<any>,\n footerTemplate?: TemplateRef<any> | undefined,\n config?: ModalConfig<T>,\n sidePaneTemplate?: TemplateRef<any> | undefined\n ): MatDialogRef<ModalComponent> {\n const dialogRef = ModalComponent.openWithComponent(matDialog, config, ModalComponent);\n dialogRef.componentInstance.closable = config && config.closable ? config.closable : false;\n dialogRef.componentInstance.headerBottomBorderEnabled =\n config && config.headerBottomBorderEnabled ? config.headerBottomBorderEnabled : false;\n dialogRef.componentInstance.headerTemplate = headerTemplate;\n dialogRef.componentInstance.mainTemplate = mainTemplate;\n dialogRef.componentInstance.footerTemplate = footerTemplate;\n dialogRef.componentInstance.sidePaneTemplate = sidePaneTemplate;\n return dialogRef;\n }\n\n close(): void {\n this.dialogRef.close();\n }\n}\n","@if (sidePaneTemplate) {\n <div\n [ngStyle]=\"sidePaneStyle\"\n [ngClass]=\"{ pane: defaultLayout }\">\n <ng-template [ngTemplateOutlet]=\"sidePaneTemplate\" />\n </div>\n}\n\n<div\n class=\"modal-wrapper\"\n [ngStyle]=\"containerStyle\"\n [class.default-layout]=\"defaultLayout\">\n @if (closable) {\n <ap-icon-button\n class=\"close-button\"\n ariaLabel=\"Close button\"\n name=\"close-button\"\n color=\"none\"\n type=\"flat\"\n (onClick)=\"close()\">\n <ap-symbol symbolId=\"close\" />\n </ap-icon-button>\n }\n @if (headerTemplate && headerVisible) {\n <div\n [ngStyle]=\"headerStyle\"\n [ngClass]=\"{ header: defaultLayout }\"\n [class.border-bottom]=\"headerBottomBorderEnabled\">\n <ng-template [ngTemplateOutlet]=\"headerTemplate\" />\n </div>\n }\n @if (mainTemplate) {\n <div\n [ngStyle]=\"contentStyle\"\n [class.content]=\"defaultLayout\">\n <ng-template [ngTemplateOutlet]=\"mainTemplate\" />\n </div>\n }\n @if (footerTemplate && footerVisible) {\n <div\n [ngStyle]=\"footerStyle\"\n [ngClass]=\"{ footer: defaultLayout }\">\n <ng-template [ngTemplateOutlet]=\"footerTemplate\" />\n </div>\n }\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;MAmCa,cAAc,CAAA;AAIZ,IAAA,SAAA;AACA,IAAA,cAAA;AAJX,IAAA,OAAgB,WAAW,GAAG,iBAAiB;IAE/C,WAAA,CACW,SAA6C,EAC7C,cAA8B,EAAA;QAD9B,IAAA,CAAA,SAAS,GAAT,SAAS;QACT,IAAA,CAAA,cAAc,GAAd,cAAc;AAErB,QAAA,SAAS,CAAC,YAAY,GAAG,IAAI;QAC7B,IAAI,CAAC,cAAc,CAAC,eAAe,CAAC,CAAC,OAAO,CAAC,CAAC;IAClD;IAES,QAAQ,GAAG,KAAK;IAChB,yBAAyB,GAAG,KAAK;IACjC,cAAc,GAAiC,SAAS;IACxD,aAAa,GAAG,IAAI;IACpB,cAAc,GAAiC,SAAS;IACxD,aAAa,GAAG,IAAI;AAI7B,IAAA,YAAY;IACH,gBAAgB,GAAiC,SAAS;IAC1D,aAAa,GAA0C,EAAE;IACzD,cAAc,GAA0C,EAAE;IAC1D,WAAW,GAA0C,EAAE;IACvD,YAAY,GAA0C,EAAE;IACxD,WAAW,GAA0C,EAAE;IACvD,aAAa,GAAG,IAAI;AAE7B;;AAEG;AACH,IAAA,OAAO,iBAAiB,CACpB,SAAoB,EACpB,MAAwD,EACxD,aAA+B,EAAA;AAE/B,QAAA,IAAI,eAAqD;QACzD,IAAI,MAAM,EAAE;AACR,YAAA,eAAe,GAAG,MAAM,CAAC,eAAe;AACxC,YAAA,IAAI,eAAe,IAAI,MAAM,CAAC,eAAe,EAAE;AAC3C,gBAAA,eAAe,CAAC,UAAU,GAAG,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,eAAe,CAAC,UAAU;AACxE,sBA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;sBAArB;gBACQ,cAAc,EAAA,CAAA;sBAAtB;gBACQ,aAAa,EAAA,CAAA;sBAArB;gBAID,YAAY,EAAA,CAAA;sBAHX,KAAK;AAAC,gBAAA,IAAA,EAAA,CAAA;AACH,wBAAA,QAAQ,EAAE,IAAI;AACjB,qBAAA;gBAEQ,gBAAgB,EAAA,CAAA;sBAAxB;gBACQ,aAAa,EAAA,CAAA;sBAArB;gBACQ,cAAc,EAAA,CAAA;sBAAtB;gBACQ,WAAW,EAAA,CAAA;sBAAnB;gBACQ,YAAY,EAAA,CAAA;sBAApB;gBACQ,WAAW,EAAA,CAAA;sBAAnB;gBACQ,aAAa,EAAA,CAAA;sBAArB;;;AE9DL;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"agorapulse-ui-components-modal.mjs","sources":["../../../libs/ui-components/modal/src/modal.component.ts","../../../libs/ui-components/modal/src/modal.component.html","../../../libs/ui-components/modal/src/agorapulse-ui-components-modal.ts"],"sourcesContent":["import { ButtonComponent } from '@agorapulse/ui-components/button';\nimport { IconButtonComponent } from '@agorapulse/ui-components/icon-button';\nimport { apClose, SymbolComponent, SymbolRegistry } from '@agorapulse/ui-symbol';\nimport { ComponentType } from '@angular/cdk/portal';\nimport { NgClass, NgStyle, NgTemplateOutlet } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, Input, TemplateRef } from '@angular/core';\nimport { MatDialog, MatDialogConfig, MatDialogRef } from '@angular/material/dialog';\n\nexport interface ModalConfig<T = unknown> extends ModalConfigBase<T> {\n closable?: boolean;\n headerBottomBorderEnabled?: boolean;\n}\n\nexport interface ModalConfigBase<T> {\n backdropCloseEnable?: boolean;\n matDialogConfig?: MatDialogConfig<T>;\n}\n\n@Component({\n changeDetection: ChangeDetectionStrategy.OnPush,\n selector: 'ap-modal',\n templateUrl: 'modal.component.html',\n imports: [SymbolComponent, NgStyle, NgClass, ButtonComponent, NgTemplateOutlet, IconButtonComponent],\n styleUrls: ['modal.component.scss'],\n})\nexport class ModalComponent {\n static readonly PANEL_CLASS = 'modal-container';\n\n constructor(\n public dialogRef: MatDialogRef<ComponentType<any>>,\n public symbolRegistry: SymbolRegistry\n ) {\n dialogRef.disableClose = true;\n this.symbolRegistry.registerSymbols([apClose]);\n }\n\n @Input() closable = false;\n @Input() headerBottomBorderEnabled = false;\n @Input() footerTemplate: TemplateRef<any> | undefined = undefined;\n @Input() footerVisible = true;\n @Input() headerTemplate: TemplateRef<any> | undefined = undefined;\n @Input() headerVisible = true;\n @Input({\n required: true,\n })\n mainTemplate!: TemplateRef<any>;\n @Input() sidePaneTemplate: TemplateRef<any> | undefined = undefined;\n @Input() sidePaneStyle: { [arg: string]: string } | undefined = {};\n @Input() containerStyle: { [arg: string]: string } | undefined = {};\n @Input() headerStyle: { [arg: string]: string } | undefined = {};\n @Input() contentStyle: { [arg: string]: string } | undefined = {};\n @Input() footerStyle: { [arg: string]: string } | undefined = {};\n @Input() defaultLayout = true;\n\n /**\n * Use it to open a modal containing the {@link componentType} component, with the right configuration.\n */\n static openWithComponent<T, Y>(\n matDialog: MatDialog,\n config: ModalConfigBase<Y> | undefined,\n componentType: ComponentType<T>\n ): MatDialogRef<T> {\n let matDialogConfig: MatDialogConfig<Y> | undefined;\n if (config) {\n matDialogConfig = config.matDialogConfig;\n if (matDialogConfig && config.matDialogConfig) {\n matDialogConfig.panelClass = Array.isArray(config.matDialogConfig.panelClass)\n ? [...config.matDialogConfig.panelClass, ModalComponent.PANEL_CLASS] // in case where the panelClass is an array\n : [config.matDialogConfig.panelClass ?? '', ModalComponent.PANEL_CLASS]; // in the other case, it's a String\n } else {\n matDialogConfig = { panelClass: ModalComponent.PANEL_CLASS };\n }\n } else {\n matDialogConfig = {\n panelClass: ModalComponent.PANEL_CLASS,\n };\n }\n matDialogConfig.autoFocus = false; // Prevent first button to be focused\n\n const dialogRef = matDialog.open(componentType, matDialogConfig);\n if (config?.backdropCloseEnable === true) {\n dialogRef.disableClose = false;\n }\n return dialogRef;\n }\n\n /**\n * Use it to open a modal containing the provided templates, with the right configuration.\n */\n static openWithTemplates<T>(\n matDialog: MatDialog,\n headerTemplate: TemplateRef<any> | undefined,\n mainTemplate: TemplateRef<any>,\n footerTemplate?: TemplateRef<any> | undefined,\n config?: ModalConfig<T>,\n sidePaneTemplate?: TemplateRef<any> | undefined\n ): MatDialogRef<ModalComponent> {\n const dialogRef = ModalComponent.openWithComponent(matDialog, config, ModalComponent);\n dialogRef.componentInstance.closable = config && config.closable ? config.closable : false;\n dialogRef.componentInstance.headerBottomBorderEnabled =\n config && config.headerBottomBorderEnabled ? config.headerBottomBorderEnabled : false;\n dialogRef.componentInstance.headerTemplate = headerTemplate;\n dialogRef.componentInstance.mainTemplate = mainTemplate;\n dialogRef.componentInstance.footerTemplate = footerTemplate;\n dialogRef.componentInstance.sidePaneTemplate = sidePaneTemplate;\n return dialogRef;\n }\n\n close(): void {\n this.dialogRef.close();\n }\n}\n","@if (sidePaneTemplate) {\n <div\n [ngStyle]=\"sidePaneStyle\"\n [ngClass]=\"{ pane: defaultLayout }\">\n <ng-template [ngTemplateOutlet]=\"sidePaneTemplate\" />\n </div>\n}\n\n<div\n class=\"modal-wrapper\"\n [ngStyle]=\"containerStyle\"\n [class.default-layout]=\"defaultLayout\">\n @if (closable) {\n <ap-icon-button\n class=\"close-button\"\n ariaLabel=\"Close button\"\n name=\"close-button\"\n color=\"none\"\n type=\"flat\"\n (onClick)=\"close()\">\n <ap-symbol symbolId=\"close\" />\n </ap-icon-button>\n }\n @if (headerTemplate && headerVisible) {\n <div\n [ngStyle]=\"headerStyle\"\n [ngClass]=\"{ header: defaultLayout }\"\n [class.border-bottom]=\"headerBottomBorderEnabled\">\n <ng-template [ngTemplateOutlet]=\"headerTemplate\" />\n </div>\n }\n @if (mainTemplate) {\n <div\n [ngStyle]=\"contentStyle\"\n [class.content]=\"defaultLayout\">\n <ng-template [ngTemplateOutlet]=\"mainTemplate\" />\n </div>\n }\n @if (footerTemplate && footerVisible) {\n <div\n [ngStyle]=\"footerStyle\"\n [ngClass]=\"{ footer: defaultLayout }\">\n <ng-template [ngTemplateOutlet]=\"footerTemplate\" />\n </div>\n }\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;MAyBa,cAAc,CAAA;AAIZ,IAAA,SAAA;AACA,IAAA,cAAA;AAJX,IAAA,OAAgB,WAAW,GAAG,iBAAiB;IAE/C,WAAA,CACW,SAA2C,EAC3C,cAA8B,EAAA;QAD9B,IAAA,CAAA,SAAS,GAAT,SAAS;QACT,IAAA,CAAA,cAAc,GAAd,cAAc;AAErB,QAAA,SAAS,CAAC,YAAY,GAAG,IAAI;QAC7B,IAAI,CAAC,cAAc,CAAC,eAAe,CAAC,CAAC,OAAO,CAAC,CAAC;IAClD;IAES,QAAQ,GAAG,KAAK;IAChB,yBAAyB,GAAG,KAAK;IACjC,cAAc,GAAiC,SAAS;IACxD,aAAa,GAAG,IAAI;IACpB,cAAc,GAAiC,SAAS;IACxD,aAAa,GAAG,IAAI;AAI7B,IAAA,YAAY;IACH,gBAAgB,GAAiC,SAAS;IAC1D,aAAa,GAA0C,EAAE;IACzD,cAAc,GAA0C,EAAE;IAC1D,WAAW,GAA0C,EAAE;IACvD,YAAY,GAA0C,EAAE;IACxD,WAAW,GAA0C,EAAE;IACvD,aAAa,GAAG,IAAI;AAE7B;;AAEG;AACH,IAAA,OAAO,iBAAiB,CACpB,SAAoB,EACpB,MAAsC,EACtC,aAA+B,EAAA;AAE/B,QAAA,IAAI,eAA+C;QACnD,IAAI,MAAM,EAAE;AACR,YAAA,eAAe,GAAG,MAAM,CAAC,eAAe;AACxC,YAAA,IAAI,eAAe,IAAI,MAAM,CAAC,eAAe,EAAE;AAC3C,gBAAA,eAAe,CAAC,UAAU,GAAG,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,eAAe,CAAC,UAAU;AACxE,sBAAE,CAAC,GAAG,MAAM,CAAC,eAAe,CAAC,UAAU,EAAE,cAAc,CA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Q,aAAa,EAAA,CAAA;sBAArB;gBACQ,cAAc,EAAA,CAAA;sBAAtB;gBACQ,WAAW,EAAA,CAAA;sBAAnB;gBACQ,YAAY,EAAA,CAAA;sBAApB;gBACQ,WAAW,EAAA,CAAA;sBAAnB;gBACQ,aAAa,EAAA,CAAA;sBAArB;;;AEpDL;;AAEG;;;;"}
|
|
@@ -3041,7 +3041,16 @@ class NavSelectorComponent {
|
|
|
3041
3041
|
this.navSelectorState.initEntries(newEntries, selectedUids, limit);
|
|
3042
3042
|
}
|
|
3043
3043
|
else {
|
|
3044
|
+
// Save scroll position before updating
|
|
3045
|
+
const scrollContainer = this.el.nativeElement.querySelector('.nav-selector__content');
|
|
3046
|
+
const scrollTop = scrollContainer?.scrollTop ?? 0;
|
|
3044
3047
|
this.navSelectorState.updateEntries(newEntries, selectedUids, limit);
|
|
3048
|
+
// Restore scroll position after Angular updates the DOM
|
|
3049
|
+
setTimeout(() => {
|
|
3050
|
+
if (scrollContainer) {
|
|
3051
|
+
scrollContainer.scrollTop = scrollTop;
|
|
3052
|
+
}
|
|
3053
|
+
});
|
|
3045
3054
|
}
|
|
3046
3055
|
});
|
|
3047
3056
|
});
|