source: trip-planner-front/node_modules/.cache/babel-webpack/3a101c91fb0b4bba55d1f1f3003dd8bb.json@ 571e0df

Last change on this file since 571e0df was e29cc2e, checked in by Ema <ema_spirova@…>, 3 years ago

primeNG components

  • Property mode set to 100644
File size: 64.1 KB
Line 
1{"ast":null,"code":"import * as i0 from '@angular/core';\nimport { Directive, Component, ChangeDetectionStrategy, ViewEncapsulation, ViewChild, NgModule, Injectable } from '@angular/core';\nimport { animation, style, animate, trigger, transition, useAnimation } from '@angular/animations';\nimport * as i4 from '@angular/common';\nimport { CommonModule } from '@angular/common';\nimport { DomHandler } from 'primeng/dom';\nimport { ZIndexUtils } from 'primeng/utils';\nimport { Subject } from 'rxjs';\nimport * as i3 from 'primeng/api';\nconst _c0 = [\"mask\"];\n\nfunction DynamicDialogComponent_div_2_div_1_button_4_Template(rf, ctx) {\n if (rf & 1) {\n const _r7 = i0.ɵɵgetCurrentView();\n\n i0.ɵɵelementStart(0, \"button\", 12);\n i0.ɵɵlistener(\"click\", function DynamicDialogComponent_div_2_div_1_button_4_Template_button_click_0_listener() {\n i0.ɵɵrestoreView(_r7);\n const ctx_r6 = i0.ɵɵnextContext(3);\n return ctx_r6.hide();\n })(\"keydown.enter\", function DynamicDialogComponent_div_2_div_1_button_4_Template_button_keydown_enter_0_listener() {\n i0.ɵɵrestoreView(_r7);\n const ctx_r8 = i0.ɵɵnextContext(3);\n return ctx_r8.hide();\n });\n i0.ɵɵelement(1, \"span\", 13);\n i0.ɵɵelementEnd();\n }\n\n if (rf & 2) {\n i0.ɵɵproperty(\"ngClass\", \"p-dialog-header-icon p-dialog-header-maximize p-link\");\n }\n}\n\nfunction DynamicDialogComponent_div_2_div_1_Template(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵelementStart(0, \"div\", 8);\n i0.ɵɵelementStart(1, \"span\", 9);\n i0.ɵɵtext(2);\n i0.ɵɵelementEnd();\n i0.ɵɵelementStart(3, \"div\", 10);\n i0.ɵɵtemplate(4, DynamicDialogComponent_div_2_div_1_button_4_Template, 2, 1, \"button\", 11);\n i0.ɵɵelementEnd();\n i0.ɵɵelementEnd();\n }\n\n if (rf & 2) {\n const ctx_r2 = i0.ɵɵnextContext(2);\n i0.ɵɵadvance(2);\n i0.ɵɵtextInterpolate(ctx_r2.config.header);\n i0.ɵɵadvance(2);\n i0.ɵɵproperty(\"ngIf\", ctx_r2.config.closable !== false);\n }\n}\n\nfunction DynamicDialogComponent_div_2_ng_template_3_Template(rf, ctx) {}\n\nfunction DynamicDialogComponent_div_2_div_4_Template(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵelementStart(0, \"div\", 14);\n i0.ɵɵtext(1);\n i0.ɵɵelementEnd();\n }\n\n if (rf & 2) {\n const ctx_r4 = i0.ɵɵnextContext(2);\n i0.ɵɵadvance(1);\n i0.ɵɵtextInterpolate1(\" \", ctx_r4.config.footer, \" \");\n }\n}\n\nconst _c1 = function (a1) {\n return {\n \"p-dialog p-dynamic-dialog p-component\": true,\n \"p-dialog-rtl\": a1\n };\n};\n\nconst _c2 = function (a0, a1) {\n return {\n transform: a0,\n transition: a1\n };\n};\n\nconst _c3 = function (a1) {\n return {\n value: \"visible\",\n params: a1\n };\n};\n\nfunction DynamicDialogComponent_div_2_Template(rf, ctx) {\n if (rf & 1) {\n const _r10 = i0.ɵɵgetCurrentView();\n\n i0.ɵɵelementStart(0, \"div\", 3);\n i0.ɵɵlistener(\"@animation.start\", function DynamicDialogComponent_div_2_Template_div_animation_animation_start_0_listener($event) {\n i0.ɵɵrestoreView(_r10);\n const ctx_r9 = i0.ɵɵnextContext();\n return ctx_r9.onAnimationStart($event);\n })(\"@animation.done\", function DynamicDialogComponent_div_2_Template_div_animation_animation_done_0_listener($event) {\n i0.ɵɵrestoreView(_r10);\n const ctx_r11 = i0.ɵɵnextContext();\n return ctx_r11.onAnimationEnd($event);\n });\n i0.ɵɵtemplate(1, DynamicDialogComponent_div_2_div_1_Template, 5, 2, \"div\", 4);\n i0.ɵɵelementStart(2, \"div\", 5);\n i0.ɵɵtemplate(3, DynamicDialogComponent_div_2_ng_template_3_Template, 0, 0, \"ng-template\", 6);\n i0.ɵɵelementEnd();\n i0.ɵɵtemplate(4, DynamicDialogComponent_div_2_div_4_Template, 2, 1, \"div\", 7);\n i0.ɵɵelementEnd();\n }\n\n if (rf & 2) {\n const ctx_r1 = i0.ɵɵnextContext();\n i0.ɵɵclassMap(ctx_r1.config.styleClass);\n i0.ɵɵstyleProp(\"width\", ctx_r1.config.width)(\"height\", ctx_r1.config.height);\n i0.ɵɵproperty(\"ngClass\", i0.ɵɵpureFunction1(12, _c1, ctx_r1.config.rtl))(\"ngStyle\", ctx_r1.config.style)(\"@animation\", i0.ɵɵpureFunction1(17, _c3, i0.ɵɵpureFunction2(14, _c2, ctx_r1.transformOptions, ctx_r1.config.transitionOptions || \"150ms cubic-bezier(0, 0, 0.2, 1)\")));\n i0.ɵɵadvance(1);\n i0.ɵɵproperty(\"ngIf\", ctx_r1.config.showHeader === false ? false : true);\n i0.ɵɵadvance(1);\n i0.ɵɵproperty(\"ngStyle\", ctx_r1.config.contentStyle);\n i0.ɵɵadvance(2);\n i0.ɵɵproperty(\"ngIf\", ctx_r1.config.footer);\n }\n}\n\nconst _c4 = function (a1) {\n return {\n \"p-dialog-mask\": true,\n \"p-component-overlay-enter p-dialog-mask-scrollblocker\": a1\n };\n};\n\nclass DynamicDialogContent {\n constructor(viewContainerRef) {\n this.viewContainerRef = viewContainerRef;\n }\n\n}\n\nDynamicDialogContent.ɵfac = function DynamicDialogContent_Factory(t) {\n return new (t || DynamicDialogContent)(i0.ɵɵdirectiveInject(i0.ViewContainerRef));\n};\n\nDynamicDialogContent.ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: DynamicDialogContent,\n selectors: [[\"\", \"pDynamicDialogContent\", \"\"]],\n hostAttrs: [1, \"p-element\"]\n});\n\n(function () {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DynamicDialogContent, [{\n type: Directive,\n args: [{\n selector: '[pDynamicDialogContent]',\n host: {\n 'class': 'p-element'\n }\n }]\n }], function () {\n return [{\n type: i0.ViewContainerRef\n }];\n }, null);\n})();\n\nclass DynamicDialogConfig {}\n\nclass DynamicDialogRef {\n constructor() {\n this._onClose = new Subject();\n this.onClose = this._onClose.asObservable();\n this._onDestroy = new Subject();\n this.onDestroy = this._onDestroy.asObservable();\n }\n\n close(result) {\n this._onClose.next(result);\n }\n\n destroy() {\n this._onDestroy.next(null);\n }\n\n}\n\nconst showAnimation = animation([style({\n transform: '{{transform}}',\n opacity: 0\n}), animate('{{transition}}', style({\n transform: 'none',\n opacity: 1\n}))]);\nconst hideAnimation = animation([animate('{{transition}}', style({\n transform: '{{transform}}',\n opacity: 0\n}))]);\n\nclass DynamicDialogComponent {\n constructor(componentFactoryResolver, cd, renderer, config, dialogRef, zone, primeNGConfig) {\n this.componentFactoryResolver = componentFactoryResolver;\n this.cd = cd;\n this.renderer = renderer;\n this.config = config;\n this.dialogRef = dialogRef;\n this.zone = zone;\n this.primeNGConfig = primeNGConfig;\n this.visible = true;\n this.transformOptions = \"scale(0.7)\";\n }\n\n ngAfterViewInit() {\n this.loadChildComponent(this.childComponentType);\n this.cd.detectChanges();\n }\n\n loadChildComponent(componentType) {\n let componentFactory = this.componentFactoryResolver.resolveComponentFactory(componentType);\n let viewContainerRef = this.insertionPoint.viewContainerRef;\n viewContainerRef.clear();\n this.componentRef = viewContainerRef.createComponent(componentFactory);\n }\n\n moveOnTop() {\n if (this.config.autoZIndex !== false) {\n ZIndexUtils.set('modal', this.container, (this.config.baseZIndex || 0) + this.primeNGConfig.zIndex.modal);\n this.wrapper.style.zIndex = String(parseInt(this.container.style.zIndex, 10) - 1);\n }\n }\n\n onAnimationStart(event) {\n switch (event.toState) {\n case 'visible':\n this.container = event.element;\n this.wrapper = this.container.parentElement;\n this.moveOnTop();\n this.bindGlobalListeners();\n\n if (this.config.modal !== false) {\n this.enableModality();\n }\n\n this.focus();\n break;\n\n case 'void':\n if (this.config.modal !== false) {\n DomHandler.addClass(this.wrapper, 'p-component-overlay-leave');\n }\n\n break;\n }\n }\n\n onAnimationEnd(event) {\n if (event.toState === 'void') {\n this.onContainerDestroy();\n this.dialogRef.destroy();\n }\n }\n\n onContainerDestroy() {\n this.unbindGlobalListeners();\n\n if (this.container && this.config.autoZIndex !== false) {\n ZIndexUtils.clear(this.container);\n }\n\n if (this.config.modal !== false) {\n this.disableModality();\n }\n\n this.container = null;\n }\n\n close() {\n this.visible = false;\n this.cd.markForCheck();\n }\n\n hide() {\n if (this.dialogRef) {\n this.dialogRef.close();\n }\n }\n\n enableModality() {\n if (this.config.closable !== false && this.config.dismissableMask) {\n this.maskClickListener = this.renderer.listen(this.wrapper, 'mousedown', event => {\n if (this.wrapper && this.wrapper.isSameNode(event.target)) {\n this.hide();\n }\n });\n }\n\n if (this.config.modal !== false) {\n DomHandler.addClass(document.body, 'p-overflow-hidden');\n }\n }\n\n disableModality() {\n if (this.wrapper) {\n if (this.config.dismissableMask) {\n this.unbindMaskClickListener();\n }\n\n if (this.config.modal !== false) {\n DomHandler.removeClass(document.body, 'p-overflow-hidden');\n }\n\n if (!this.cd.destroyed) {\n this.cd.detectChanges();\n }\n }\n }\n\n onKeydown(event) {\n if (event.which === 9) {\n event.preventDefault();\n let focusableElements = DomHandler.getFocusableElements(this.container);\n\n if (focusableElements && focusableElements.length > 0) {\n if (!focusableElements[0].ownerDocument.activeElement) {\n focusableElements[0].focus();\n } else {\n let focusedIndex = focusableElements.indexOf(focusableElements[0].ownerDocument.activeElement);\n\n if (event.shiftKey) {\n if (focusedIndex == -1 || focusedIndex === 0) focusableElements[focusableElements.length - 1].focus();else focusableElements[focusedIndex - 1].focus();\n } else {\n if (focusedIndex == -1 || focusedIndex === focusableElements.length - 1) focusableElements[0].focus();else focusableElements[focusedIndex + 1].focus();\n }\n }\n }\n }\n }\n\n focus() {\n let focusable = DomHandler.findSingle(this.container, '[autofocus]');\n\n if (focusable) {\n this.zone.runOutsideAngular(() => {\n setTimeout(() => focusable.focus(), 5);\n });\n }\n }\n\n bindGlobalListeners() {\n this.bindDocumentKeydownListener();\n\n if (this.config.closeOnEscape !== false && this.config.closable !== false) {\n this.bindDocumentEscapeListener();\n }\n }\n\n unbindGlobalListeners() {\n this.unbindDocumentKeydownListener();\n this.unbindDocumentEscapeListener();\n }\n\n bindDocumentKeydownListener() {\n this.zone.runOutsideAngular(() => {\n this.documentKeydownListener = this.onKeydown.bind(this);\n window.document.addEventListener('keydown', this.documentKeydownListener);\n });\n }\n\n unbindDocumentKeydownListener() {\n if (this.documentKeydownListener) {\n window.document.removeEventListener('keydown', this.documentKeydownListener);\n this.documentKeydownListener = null;\n }\n }\n\n bindDocumentEscapeListener() {\n const documentTarget = this.maskViewChild ? this.maskViewChild.nativeElement.ownerDocument : 'document';\n this.documentEscapeListener = this.renderer.listen(documentTarget, 'keydown', event => {\n if (event.which == 27) {\n if (parseInt(this.container.style.zIndex) == ZIndexUtils.getCurrent()) {\n this.hide();\n }\n }\n });\n }\n\n unbindDocumentEscapeListener() {\n if (this.documentEscapeListener) {\n this.documentEscapeListener();\n this.documentEscapeListener = null;\n }\n }\n\n unbindMaskClickListener() {\n if (this.maskClickListener) {\n this.maskClickListener();\n this.maskClickListener = null;\n }\n }\n\n ngOnDestroy() {\n this.onContainerDestroy();\n\n if (this.componentRef) {\n this.componentRef.destroy();\n }\n }\n\n}\n\nDynamicDialogComponent.ɵfac = function DynamicDialogComponent_Factory(t) {\n return new (t || DynamicDialogComponent)(i0.ɵɵdirectiveInject(i0.ComponentFactoryResolver), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef), i0.ɵɵdirectiveInject(i0.Renderer2), i0.ɵɵdirectiveInject(DynamicDialogConfig), i0.ɵɵdirectiveInject(DynamicDialogRef), i0.ɵɵdirectiveInject(i0.NgZone), i0.ɵɵdirectiveInject(i3.PrimeNGConfig));\n};\n\nDynamicDialogComponent.ɵcmp = /* @__PURE__ */i0.ɵɵdefineComponent({\n type: DynamicDialogComponent,\n selectors: [[\"p-dynamicDialog\"]],\n viewQuery: function DynamicDialogComponent_Query(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵviewQuery(DynamicDialogContent, 5);\n i0.ɵɵviewQuery(_c0, 5);\n }\n\n if (rf & 2) {\n let _t;\n\n i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.insertionPoint = _t.first);\n i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.maskViewChild = _t.first);\n }\n },\n hostAttrs: [1, \"p-element\"],\n decls: 3,\n vars: 4,\n consts: [[3, \"ngClass\"], [\"mask\", \"\"], [\"role\", \"dialog\", 3, \"ngClass\", \"ngStyle\", \"class\", \"width\", \"height\", 4, \"ngIf\"], [\"role\", \"dialog\", 3, \"ngClass\", \"ngStyle\"], [\"class\", \"p-dialog-header\", 4, \"ngIf\"], [1, \"p-dialog-content\", 3, \"ngStyle\"], [\"pDynamicDialogContent\", \"\"], [\"class\", \"p-dialog-footer\", 4, \"ngIf\"], [1, \"p-dialog-header\"], [1, \"p-dialog-title\"], [1, \"p-dialog-header-icons\"], [\"type\", \"button\", 3, \"ngClass\", \"click\", \"keydown.enter\", 4, \"ngIf\"], [\"type\", \"button\", 3, \"ngClass\", \"click\", \"keydown.enter\"], [1, \"p-dialog-header-close-icon\", \"pi\", \"pi-times\"], [1, \"p-dialog-footer\"]],\n template: function DynamicDialogComponent_Template(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵelementStart(0, \"div\", 0, 1);\n i0.ɵɵtemplate(2, DynamicDialogComponent_div_2_Template, 5, 19, \"div\", 2);\n i0.ɵɵelementEnd();\n }\n\n if (rf & 2) {\n i0.ɵɵproperty(\"ngClass\", i0.ɵɵpureFunction1(2, _c4, ctx.config.modal !== false));\n i0.ɵɵadvance(2);\n i0.ɵɵproperty(\"ngIf\", ctx.visible);\n }\n },\n directives: function () {\n return [i4.NgClass, i4.NgIf, i4.NgStyle, DynamicDialogContent];\n },\n styles: [\".p-dialog-mask{position:fixed;top:0;left:0;width:100%;height:100%;display:flex;justify-content:center;align-items:center;pointer-events:none}.p-dialog-mask.p-component-overlay{pointer-events:auto}.p-dialog{display:flex;flex-direction:column;pointer-events:auto;max-height:90%;transform:scale(1);position:relative}.p-dialog-content{overflow-y:auto;flex-grow:1}.p-dialog-header{display:flex;align-items:center;justify-content:space-between;flex-shrink:0}.p-dialog-footer{flex-shrink:0}.p-dialog .p-dialog-header-icons{display:flex;align-items:center}.p-dialog .p-dialog-header-icon{display:flex;align-items:center;justify-content:center;overflow:hidden;position:relative}.p-fluid .p-dialog-footer .p-button{width:auto}.p-dialog-top .p-dialog,.p-dialog-bottom .p-dialog,.p-dialog-left .p-dialog,.p-dialog-right .p-dialog,.p-dialog-top-left .p-dialog,.p-dialog-top-right .p-dialog,.p-dialog-bottom-left .p-dialog,.p-dialog-bottom-right .p-dialog{margin:.75rem;transform:translate(0)}.p-dialog-maximized{transition:none;transform:none;width:100vw!important;height:100vh!important;top:0px!important;left:0px!important;max-height:100%;height:100%}.p-dialog-maximized .p-dialog-content{flex-grow:1}.p-dialog-left{justify-content:flex-start}.p-dialog-right{justify-content:flex-end}.p-dialog-top{align-items:flex-start}.p-dialog-top-left{justify-content:flex-start;align-items:flex-start}.p-dialog-top-right{justify-content:flex-end;align-items:flex-start}.p-dialog-bottom{align-items:flex-end}.p-dialog-bottom-left{justify-content:flex-start;align-items:flex-end}.p-dialog-bottom-right{justify-content:flex-end;align-items:flex-end}.p-dialog .p-resizable-handle{position:absolute;font-size:.1px;display:block;cursor:se-resize;width:12px;height:12px;right:1px;bottom:1px}.p-confirm-dialog .p-dialog-content{display:flex;align-items:center}\\n\"],\n encapsulation: 2,\n data: {\n animation: [trigger('animation', [transition('void => visible', [useAnimation(showAnimation)]), transition('visible => void', [useAnimation(hideAnimation)])])]\n }\n});\n\n(function () {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DynamicDialogComponent, [{\n type: Component,\n args: [{\n selector: 'p-dynamicDialog',\n template: `\n <div #mask [ngClass]=\"{'p-dialog-mask':true, 'p-component-overlay-enter p-dialog-mask-scrollblocker': config.modal !== false}\">\n <div [ngClass]=\"{'p-dialog p-dynamic-dialog p-component':true, 'p-dialog-rtl': config.rtl}\" [ngStyle]=\"config.style\" [class]=\"config.styleClass\"\n [@animation]=\"{value: 'visible', params: {transform: transformOptions, transition: config.transitionOptions || '150ms cubic-bezier(0, 0, 0.2, 1)'}}\"\n (@animation.start)=\"onAnimationStart($event)\" (@animation.done)=\"onAnimationEnd($event)\" role=\"dialog\" *ngIf=\"visible\"\n [style.width]=\"config.width\" [style.height]=\"config.height\">\n <div class=\"p-dialog-header\" *ngIf=\"config.showHeader === false ? false: true\">\n <span class=\"p-dialog-title\">{{config.header}}</span>\n <div class=\"p-dialog-header-icons\">\n <button [ngClass]=\"'p-dialog-header-icon p-dialog-header-maximize p-link'\" type=\"button\" (click)=\"hide()\" (keydown.enter)=\"hide()\" *ngIf=\"config.closable !== false\">\n <span class=\"p-dialog-header-close-icon pi pi-times\"></span>\n </button>\n </div>\n </div>\n <div class=\"p-dialog-content\" [ngStyle]=\"config.contentStyle\">\n <ng-template pDynamicDialogContent></ng-template>\n </div>\n <div class=\"p-dialog-footer\" *ngIf=\"config.footer\">\n {{config.footer}}\n </div>\n </div>\n </div>\n\t`,\n animations: [trigger('animation', [transition('void => visible', [useAnimation(showAnimation)]), transition('visible => void', [useAnimation(hideAnimation)])])],\n changeDetection: ChangeDetectionStrategy.Default,\n encapsulation: ViewEncapsulation.None,\n host: {\n 'class': 'p-element'\n },\n styles: [\".p-dialog-mask{position:fixed;top:0;left:0;width:100%;height:100%;display:flex;justify-content:center;align-items:center;pointer-events:none}.p-dialog-mask.p-component-overlay{pointer-events:auto}.p-dialog{display:flex;flex-direction:column;pointer-events:auto;max-height:90%;transform:scale(1);position:relative}.p-dialog-content{overflow-y:auto;flex-grow:1}.p-dialog-header{display:flex;align-items:center;justify-content:space-between;flex-shrink:0}.p-dialog-footer{flex-shrink:0}.p-dialog .p-dialog-header-icons{display:flex;align-items:center}.p-dialog .p-dialog-header-icon{display:flex;align-items:center;justify-content:center;overflow:hidden;position:relative}.p-fluid .p-dialog-footer .p-button{width:auto}.p-dialog-top .p-dialog,.p-dialog-bottom .p-dialog,.p-dialog-left .p-dialog,.p-dialog-right .p-dialog,.p-dialog-top-left .p-dialog,.p-dialog-top-right .p-dialog,.p-dialog-bottom-left .p-dialog,.p-dialog-bottom-right .p-dialog{margin:.75rem;transform:translate(0)}.p-dialog-maximized{transition:none;transform:none;width:100vw!important;height:100vh!important;top:0px!important;left:0px!important;max-height:100%;height:100%}.p-dialog-maximized .p-dialog-content{flex-grow:1}.p-dialog-left{justify-content:flex-start}.p-dialog-right{justify-content:flex-end}.p-dialog-top{align-items:flex-start}.p-dialog-top-left{justify-content:flex-start;align-items:flex-start}.p-dialog-top-right{justify-content:flex-end;align-items:flex-start}.p-dialog-bottom{align-items:flex-end}.p-dialog-bottom-left{justify-content:flex-start;align-items:flex-end}.p-dialog-bottom-right{justify-content:flex-end;align-items:flex-end}.p-dialog .p-resizable-handle{position:absolute;font-size:.1px;display:block;cursor:se-resize;width:12px;height:12px;right:1px;bottom:1px}.p-confirm-dialog .p-dialog-content{display:flex;align-items:center}\\n\"]\n }]\n }], function () {\n return [{\n type: i0.ComponentFactoryResolver\n }, {\n type: i0.ChangeDetectorRef\n }, {\n type: i0.Renderer2\n }, {\n type: DynamicDialogConfig\n }, {\n type: DynamicDialogRef\n }, {\n type: i0.NgZone\n }, {\n type: i3.PrimeNGConfig\n }];\n }, {\n insertionPoint: [{\n type: ViewChild,\n args: [DynamicDialogContent]\n }],\n maskViewChild: [{\n type: ViewChild,\n args: ['mask']\n }]\n });\n})();\n\nclass DynamicDialogModule {}\n\nDynamicDialogModule.ɵfac = function DynamicDialogModule_Factory(t) {\n return new (t || DynamicDialogModule)();\n};\n\nDynamicDialogModule.ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: DynamicDialogModule\n});\nDynamicDialogModule.ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({\n imports: [[CommonModule]]\n});\n\n(function () {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DynamicDialogModule, [{\n type: NgModule,\n args: [{\n imports: [CommonModule],\n declarations: [DynamicDialogComponent, DynamicDialogContent],\n entryComponents: [DynamicDialogComponent]\n }]\n }], null, null);\n})();\n\nclass DynamicDialogInjector {\n constructor(_parentInjector, _additionalTokens) {\n this._parentInjector = _parentInjector;\n this._additionalTokens = _additionalTokens;\n }\n\n get(token, notFoundValue, flags) {\n const value = this._additionalTokens.get(token);\n\n if (value) return value;\n return this._parentInjector.get(token, notFoundValue);\n }\n\n}\n\nclass DialogService {\n constructor(componentFactoryResolver, appRef, injector) {\n this.componentFactoryResolver = componentFactoryResolver;\n this.appRef = appRef;\n this.injector = injector;\n this.dialogComponentRefMap = new Map();\n }\n\n open(componentType, config) {\n const dialogRef = this.appendDialogComponentToBody(config);\n this.dialogComponentRefMap.get(dialogRef).instance.childComponentType = componentType;\n return dialogRef;\n }\n\n appendDialogComponentToBody(config) {\n const map = new WeakMap();\n map.set(DynamicDialogConfig, config);\n const dialogRef = new DynamicDialogRef();\n map.set(DynamicDialogRef, dialogRef);\n const sub = dialogRef.onClose.subscribe(() => {\n this.dialogComponentRefMap.get(dialogRef).instance.close();\n });\n const destroySub = dialogRef.onDestroy.subscribe(() => {\n this.removeDialogComponentFromBody(dialogRef);\n destroySub.unsubscribe();\n sub.unsubscribe();\n });\n const componentFactory = this.componentFactoryResolver.resolveComponentFactory(DynamicDialogComponent);\n const componentRef = componentFactory.create(new DynamicDialogInjector(this.injector, map));\n this.appRef.attachView(componentRef.hostView);\n const domElem = componentRef.hostView.rootNodes[0];\n document.body.appendChild(domElem);\n this.dialogComponentRefMap.set(dialogRef, componentRef);\n return dialogRef;\n }\n\n removeDialogComponentFromBody(dialogRef) {\n if (!dialogRef || !this.dialogComponentRefMap.has(dialogRef)) {\n return;\n }\n\n const dialogComponentRef = this.dialogComponentRefMap.get(dialogRef);\n this.appRef.detachView(dialogComponentRef.hostView);\n dialogComponentRef.destroy();\n this.dialogComponentRefMap.delete(dialogRef);\n }\n\n}\n\nDialogService.ɵfac = function DialogService_Factory(t) {\n return new (t || DialogService)(i0.ɵɵinject(i0.ComponentFactoryResolver), i0.ɵɵinject(i0.ApplicationRef), i0.ɵɵinject(i0.Injector));\n};\n\nDialogService.ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: DialogService,\n factory: DialogService.ɵfac\n});\n\n(function () {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DialogService, [{\n type: Injectable\n }], function () {\n return [{\n type: i0.ComponentFactoryResolver\n }, {\n type: i0.ApplicationRef\n }, {\n type: i0.Injector\n }];\n }, null);\n})();\n/**\n * Generated bundle index. Do not edit.\n */\n\n\nexport { DialogService, DynamicDialogComponent, DynamicDialogConfig, DynamicDialogInjector, DynamicDialogModule, DynamicDialogRef };","map":{"version":3,"sources":["C:/Users/DELL/Desktop/bachelor-thesis/trip-planner-front/node_modules/primeng/fesm2020/primeng-dynamicdialog.mjs"],"names":["i0","Directive","Component","ChangeDetectionStrategy","ViewEncapsulation","ViewChild","NgModule","Injectable","animation","style","animate","trigger","transition","useAnimation","i4","CommonModule","DomHandler","ZIndexUtils","Subject","i3","DynamicDialogContent","constructor","viewContainerRef","ɵfac","ViewContainerRef","ɵdir","type","args","selector","host","DynamicDialogConfig","DynamicDialogRef","_onClose","onClose","asObservable","_onDestroy","onDestroy","close","result","next","destroy","showAnimation","transform","opacity","hideAnimation","DynamicDialogComponent","componentFactoryResolver","cd","renderer","config","dialogRef","zone","primeNGConfig","visible","transformOptions","ngAfterViewInit","loadChildComponent","childComponentType","detectChanges","componentType","componentFactory","resolveComponentFactory","insertionPoint","clear","componentRef","createComponent","moveOnTop","autoZIndex","set","container","baseZIndex","zIndex","modal","wrapper","String","parseInt","onAnimationStart","event","toState","element","parentElement","bindGlobalListeners","enableModality","focus","addClass","onAnimationEnd","onContainerDestroy","unbindGlobalListeners","disableModality","markForCheck","hide","closable","dismissableMask","maskClickListener","listen","isSameNode","target","document","body","unbindMaskClickListener","removeClass","destroyed","onKeydown","which","preventDefault","focusableElements","getFocusableElements","length","ownerDocument","activeElement","focusedIndex","indexOf","shiftKey","focusable","findSingle","runOutsideAngular","setTimeout","bindDocumentKeydownListener","closeOnEscape","bindDocumentEscapeListener","unbindDocumentKeydownListener","unbindDocumentEscapeListener","documentKeydownListener","bind","window","addEventListener","removeEventListener","documentTarget","maskViewChild","nativeElement","documentEscapeListener","getCurrent","ngOnDestroy","ComponentFactoryResolver","ChangeDetectorRef","Renderer2","NgZone","PrimeNGConfig","ɵcmp","NgClass","NgIf","NgStyle","template","animations","changeDetection","Default","encapsulation","None","styles","DynamicDialogModule","ɵmod","ɵinj","imports","declarations","entryComponents","DynamicDialogInjector","_parentInjector","_additionalTokens","get","token","notFoundValue","flags","value","DialogService","appRef","injector","dialogComponentRefMap","Map","open","appendDialogComponentToBody","instance","map","WeakMap","sub","subscribe","destroySub","removeDialogComponentFromBody","unsubscribe","create","attachView","hostView","domElem","rootNodes","appendChild","has","dialogComponentRef","detachView","delete","ApplicationRef","Injector","ɵprov"],"mappings":"AAAA,OAAO,KAAKA,EAAZ,MAAoB,eAApB;AACA,SAASC,SAAT,EAAoBC,SAApB,EAA+BC,uBAA/B,EAAwDC,iBAAxD,EAA2EC,SAA3E,EAAsFC,QAAtF,EAAgGC,UAAhG,QAAkH,eAAlH;AACA,SAASC,SAAT,EAAoBC,KAApB,EAA2BC,OAA3B,EAAoCC,OAApC,EAA6CC,UAA7C,EAAyDC,YAAzD,QAA6E,qBAA7E;AACA,OAAO,KAAKC,EAAZ,MAAoB,iBAApB;AACA,SAASC,YAAT,QAA6B,iBAA7B;AACA,SAASC,UAAT,QAA2B,aAA3B;AACA,SAASC,WAAT,QAA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AA8GA,aAA9G;AAAA;;AACA;AAAA,qDA/WuGnK,EA+WvG,mBAA2FmK,aAA3F,EAAsH,CAAC;AAC3GzI,IAAAA,IAAI,EAAEnB;AADqG,GAAD,CAAtH,EAE4B,YAAY;AAAE,WAAO,CAAC;AAAEmB,MAAAA,IAAI,EAAE1B,EAAE,CAACqI;AAAX,KAAD,EAAwC;AAAE3G,MAAAA,IAAI,EAAE1B,EAAE,CAAC4L;AAAX,KAAxC,EAAqE;AAAElK,MAAAA,IAAI,EAAE1B,EAAE,CAAC6L;AAAX,KAArE,CAAP;AAAqG,GAF/I;AAAA;AAIA;AACA;AACA;;;AAEA,SAAS1B,aAAT,EAAwBtH,sBAAxB,EAAgDf,mBAAhD,EAAqE6H,qBAArE,EAA4FN,mBAA5F,EAAiHtH,gBAAjH","sourcesContent":["import * as i0 from '@angular/core';\nimport { Directive, Component, ChangeDetectionStrategy, ViewEncapsulation, ViewChild, NgModule, Injectable } from '@angular/core';\nimport { animation, style, animate, trigger, transition, useAnimation } from '@angular/animations';\nimport * as i4 from '@angular/common';\nimport { CommonModule } from '@angular/common';\nimport { DomHandler } from 'primeng/dom';\nimport { ZIndexUtils } from 'primeng/utils';\nimport { Subject } from 'rxjs';\nimport * as i3 from 'primeng/api';\n\nclass DynamicDialogContent {\n constructor(viewContainerRef) {\n this.viewContainerRef = viewContainerRef;\n }\n}\nDynamicDialogContent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"13.0.0\", ngImport: i0, type: DynamicDialogContent, deps: [{ token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive });\nDynamicDialogContent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: \"12.0.0\", version: \"13.0.0\", type: DynamicDialogContent, selector: \"[pDynamicDialogContent]\", host: { classAttribute: \"p-element\" }, ngImport: i0 });\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"13.0.0\", ngImport: i0, type: DynamicDialogContent, decorators: [{\n type: Directive,\n args: [{\n selector: '[pDynamicDialogContent]',\n host: {\n 'class': 'p-element'\n }\n }]\n }], ctorParameters: function () { return [{ type: i0.ViewContainerRef }]; } });\n\nclass DynamicDialogConfig {\n}\n\nclass DynamicDialogRef {\n constructor() {\n this._onClose = new Subject();\n this.onClose = this._onClose.asObservable();\n this._onDestroy = new Subject();\n this.onDestroy = this._onDestroy.asObservable();\n }\n close(result) {\n this._onClose.next(result);\n }\n destroy() {\n this._onDestroy.next(null);\n }\n}\n\nconst showAnimation = animation([\n style({ transform: '{{transform}}', opacity: 0 }),\n animate('{{transition}}', style({ transform: 'none', opacity: 1 }))\n]);\nconst hideAnimation = animation([\n animate('{{transition}}', style({ transform: '{{transform}}', opacity: 0 }))\n]);\nclass DynamicDialogComponent {\n constructor(componentFactoryResolver, cd, renderer, config, dialogRef, zone, primeNGConfig) {\n this.componentFactoryResolver = componentFactoryResolver;\n this.cd = cd;\n this.renderer = renderer;\n this.config = config;\n this.dialogRef = dialogRef;\n this.zone = zone;\n this.primeNGConfig = primeNGConfig;\n this.visible = true;\n this.transformOptions = \"scale(0.7)\";\n }\n ngAfterViewInit() {\n this.loadChildComponent(this.childComponentType);\n this.cd.detectChanges();\n }\n loadChildComponent(componentType) {\n let componentFactory = this.componentFactoryResolver.resolveComponentFactory(componentType);\n let viewContainerRef = this.insertionPoint.viewContainerRef;\n viewContainerRef.clear();\n this.componentRef = viewContainerRef.createComponent(componentFactory);\n }\n moveOnTop() {\n if (this.config.autoZIndex !== false) {\n ZIndexUtils.set('modal', this.container, (this.config.baseZIndex || 0) + this.primeNGConfig.zIndex.modal);\n this.wrapper.style.zIndex = String(parseInt(this.container.style.zIndex, 10) - 1);\n }\n }\n onAnimationStart(event) {\n switch (event.toState) {\n case 'visible':\n this.container = event.element;\n this.wrapper = this.container.parentElement;\n this.moveOnTop();\n this.bindGlobalListeners();\n if (this.config.modal !== false) {\n this.enableModality();\n }\n this.focus();\n break;\n case 'void':\n if (this.config.modal !== false) {\n DomHandler.addClass(this.wrapper, 'p-component-overlay-leave');\n }\n break;\n }\n }\n onAnimationEnd(event) {\n if (event.toState === 'void') {\n this.onContainerDestroy();\n this.dialogRef.destroy();\n }\n }\n onContainerDestroy() {\n this.unbindGlobalListeners();\n if (this.container && this.config.autoZIndex !== false) {\n ZIndexUtils.clear(this.container);\n }\n if (this.config.modal !== false) {\n this.disableModality();\n }\n this.container = null;\n }\n close() {\n this.visible = false;\n this.cd.markForCheck();\n }\n hide() {\n if (this.dialogRef) {\n this.dialogRef.close();\n }\n }\n enableModality() {\n if (this.config.closable !== false && this.config.dismissableMask) {\n this.maskClickListener = this.renderer.listen(this.wrapper, 'mousedown', (event) => {\n if (this.wrapper && this.wrapper.isSameNode(event.target)) {\n this.hide();\n }\n });\n }\n if (this.config.modal !== false) {\n DomHandler.addClass(document.body, 'p-overflow-hidden');\n }\n }\n disableModality() {\n if (this.wrapper) {\n if (this.config.dismissableMask) {\n this.unbindMaskClickListener();\n }\n if (this.config.modal !== false) {\n DomHandler.removeClass(document.body, 'p-overflow-hidden');\n }\n if (!this.cd.destroyed) {\n this.cd.detectChanges();\n }\n }\n }\n onKeydown(event) {\n if (event.which === 9) {\n event.preventDefault();\n let focusableElements = DomHandler.getFocusableElements(this.container);\n if (focusableElements && focusableElements.length > 0) {\n if (!focusableElements[0].ownerDocument.activeElement) {\n focusableElements[0].focus();\n }\n else {\n let focusedIndex = focusableElements.indexOf(focusableElements[0].ownerDocument.activeElement);\n if (event.shiftKey) {\n if (focusedIndex == -1 || focusedIndex === 0)\n focusableElements[focusableElements.length - 1].focus();\n else\n focusableElements[focusedIndex - 1].focus();\n }\n else {\n if (focusedIndex == -1 || focusedIndex === (focusableElements.length - 1))\n focusableElements[0].focus();\n else\n focusableElements[focusedIndex + 1].focus();\n }\n }\n }\n }\n }\n focus() {\n let focusable = DomHandler.findSingle(this.container, '[autofocus]');\n if (focusable) {\n this.zone.runOutsideAngular(() => {\n setTimeout(() => focusable.focus(), 5);\n });\n }\n }\n bindGlobalListeners() {\n this.bindDocumentKeydownListener();\n if (this.config.closeOnEscape !== false && this.config.closable !== false) {\n this.bindDocumentEscapeListener();\n }\n }\n unbindGlobalListeners() {\n this.unbindDocumentKeydownListener();\n this.unbindDocumentEscapeListener();\n }\n bindDocumentKeydownListener() {\n this.zone.runOutsideAngular(() => {\n this.documentKeydownListener = this.onKeydown.bind(this);\n window.document.addEventListener('keydown', this.documentKeydownListener);\n });\n }\n unbindDocumentKeydownListener() {\n if (this.documentKeydownListener) {\n window.document.removeEventListener('keydown', this.documentKeydownListener);\n this.documentKeydownListener = null;\n }\n }\n bindDocumentEscapeListener() {\n const documentTarget = this.maskViewChild ? this.maskViewChild.nativeElement.ownerDocument : 'document';\n this.documentEscapeListener = this.renderer.listen(documentTarget, 'keydown', (event) => {\n if (event.which == 27) {\n if (parseInt(this.container.style.zIndex) == ZIndexUtils.getCurrent()) {\n this.hide();\n }\n }\n });\n }\n unbindDocumentEscapeListener() {\n if (this.documentEscapeListener) {\n this.documentEscapeListener();\n this.documentEscapeListener = null;\n }\n }\n unbindMaskClickListener() {\n if (this.maskClickListener) {\n this.maskClickListener();\n this.maskClickListener = null;\n }\n }\n ngOnDestroy() {\n this.onContainerDestroy();\n if (this.componentRef) {\n this.componentRef.destroy();\n }\n }\n}\nDynamicDialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"13.0.0\", ngImport: i0, type: DynamicDialogComponent, deps: [{ token: i0.ComponentFactoryResolver }, { token: i0.ChangeDetectorRef }, { token: i0.Renderer2 }, { token: DynamicDialogConfig }, { token: DynamicDialogRef }, { token: i0.NgZone }, { token: i3.PrimeNGConfig }], target: i0.ɵɵFactoryTarget.Component });\nDynamicDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: \"12.0.0\", version: \"13.0.0\", type: DynamicDialogComponent, selector: \"p-dynamicDialog\", host: { classAttribute: \"p-element\" }, viewQueries: [{ propertyName: \"insertionPoint\", first: true, predicate: DynamicDialogContent, descendants: true }, { propertyName: \"maskViewChild\", first: true, predicate: [\"mask\"], descendants: true }], ngImport: i0, template: `\n <div #mask [ngClass]=\"{'p-dialog-mask':true, 'p-component-overlay-enter p-dialog-mask-scrollblocker': config.modal !== false}\">\n <div [ngClass]=\"{'p-dialog p-dynamic-dialog p-component':true, 'p-dialog-rtl': config.rtl}\" [ngStyle]=\"config.style\" [class]=\"config.styleClass\"\n [@animation]=\"{value: 'visible', params: {transform: transformOptions, transition: config.transitionOptions || '150ms cubic-bezier(0, 0, 0.2, 1)'}}\"\n (@animation.start)=\"onAnimationStart($event)\" (@animation.done)=\"onAnimationEnd($event)\" role=\"dialog\" *ngIf=\"visible\"\n [style.width]=\"config.width\" [style.height]=\"config.height\">\n <div class=\"p-dialog-header\" *ngIf=\"config.showHeader === false ? false: true\">\n <span class=\"p-dialog-title\">{{config.header}}</span>\n <div class=\"p-dialog-header-icons\">\n <button [ngClass]=\"'p-dialog-header-icon p-dialog-header-maximize p-link'\" type=\"button\" (click)=\"hide()\" (keydown.enter)=\"hide()\" *ngIf=\"config.closable !== false\">\n <span class=\"p-dialog-header-close-icon pi pi-times\"></span>\n </button>\n </div>\n </div>\n <div class=\"p-dialog-content\" [ngStyle]=\"config.contentStyle\">\n <ng-template pDynamicDialogContent></ng-template>\n </div>\n <div class=\"p-dialog-footer\" *ngIf=\"config.footer\">\n {{config.footer}}\n </div>\n </div>\n </div>\n\t`, isInline: true, styles: [\".p-dialog-mask{position:fixed;top:0;left:0;width:100%;height:100%;display:flex;justify-content:center;align-items:center;pointer-events:none}.p-dialog-mask.p-component-overlay{pointer-events:auto}.p-dialog{display:flex;flex-direction:column;pointer-events:auto;max-height:90%;transform:scale(1);position:relative}.p-dialog-content{overflow-y:auto;flex-grow:1}.p-dialog-header{display:flex;align-items:center;justify-content:space-between;flex-shrink:0}.p-dialog-footer{flex-shrink:0}.p-dialog .p-dialog-header-icons{display:flex;align-items:center}.p-dialog .p-dialog-header-icon{display:flex;align-items:center;justify-content:center;overflow:hidden;position:relative}.p-fluid .p-dialog-footer .p-button{width:auto}.p-dialog-top .p-dialog,.p-dialog-bottom .p-dialog,.p-dialog-left .p-dialog,.p-dialog-right .p-dialog,.p-dialog-top-left .p-dialog,.p-dialog-top-right .p-dialog,.p-dialog-bottom-left .p-dialog,.p-dialog-bottom-right .p-dialog{margin:.75rem;transform:translate(0)}.p-dialog-maximized{transition:none;transform:none;width:100vw!important;height:100vh!important;top:0px!important;left:0px!important;max-height:100%;height:100%}.p-dialog-maximized .p-dialog-content{flex-grow:1}.p-dialog-left{justify-content:flex-start}.p-dialog-right{justify-content:flex-end}.p-dialog-top{align-items:flex-start}.p-dialog-top-left{justify-content:flex-start;align-items:flex-start}.p-dialog-top-right{justify-content:flex-end;align-items:flex-start}.p-dialog-bottom{align-items:flex-end}.p-dialog-bottom-left{justify-content:flex-start;align-items:flex-end}.p-dialog-bottom-right{justify-content:flex-end;align-items:flex-end}.p-dialog .p-resizable-handle{position:absolute;font-size:.1px;display:block;cursor:se-resize;width:12px;height:12px;right:1px;bottom:1px}.p-confirm-dialog .p-dialog-content{display:flex;align-items:center}\\n\"], directives: [{ type: i0.forwardRef(function () { return i4.NgClass; }), selector: \"[ngClass]\", inputs: [\"class\", \"ngClass\"] }, { type: i0.forwardRef(function () { return i4.NgIf; }), selector: \"[ngIf]\", inputs: [\"ngIf\", \"ngIfThen\", \"ngIfElse\"] }, { type: i0.forwardRef(function () { return i4.NgStyle; }), selector: \"[ngStyle]\", inputs: [\"ngStyle\"] }, { type: i0.forwardRef(function () { return DynamicDialogContent; }), selector: \"[pDynamicDialogContent]\" }], animations: [\n trigger('animation', [\n transition('void => visible', [\n useAnimation(showAnimation)\n ]),\n transition('visible => void', [\n useAnimation(hideAnimation)\n ])\n ])\n ], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None });\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"13.0.0\", ngImport: i0, type: DynamicDialogComponent, decorators: [{\n type: Component,\n args: [{ selector: 'p-dynamicDialog', template: `\n <div #mask [ngClass]=\"{'p-dialog-mask':true, 'p-component-overlay-enter p-dialog-mask-scrollblocker': config.modal !== false}\">\n <div [ngClass]=\"{'p-dialog p-dynamic-dialog p-component':true, 'p-dialog-rtl': config.rtl}\" [ngStyle]=\"config.style\" [class]=\"config.styleClass\"\n [@animation]=\"{value: 'visible', params: {transform: transformOptions, transition: config.transitionOptions || '150ms cubic-bezier(0, 0, 0.2, 1)'}}\"\n (@animation.start)=\"onAnimationStart($event)\" (@animation.done)=\"onAnimationEnd($event)\" role=\"dialog\" *ngIf=\"visible\"\n [style.width]=\"config.width\" [style.height]=\"config.height\">\n <div class=\"p-dialog-header\" *ngIf=\"config.showHeader === false ? false: true\">\n <span class=\"p-dialog-title\">{{config.header}}</span>\n <div class=\"p-dialog-header-icons\">\n <button [ngClass]=\"'p-dialog-header-icon p-dialog-header-maximize p-link'\" type=\"button\" (click)=\"hide()\" (keydown.enter)=\"hide()\" *ngIf=\"config.closable !== false\">\n <span class=\"p-dialog-header-close-icon pi pi-times\"></span>\n </button>\n </div>\n </div>\n <div class=\"p-dialog-content\" [ngStyle]=\"config.contentStyle\">\n <ng-template pDynamicDialogContent></ng-template>\n </div>\n <div class=\"p-dialog-footer\" *ngIf=\"config.footer\">\n {{config.footer}}\n </div>\n </div>\n </div>\n\t`, animations: [\n trigger('animation', [\n transition('void => visible', [\n useAnimation(showAnimation)\n ]),\n transition('visible => void', [\n useAnimation(hideAnimation)\n ])\n ])\n ], changeDetection: ChangeDetectionStrategy.Default, encapsulation: ViewEncapsulation.None, host: {\n 'class': 'p-element'\n }, styles: [\".p-dialog-mask{position:fixed;top:0;left:0;width:100%;height:100%;display:flex;justify-content:center;align-items:center;pointer-events:none}.p-dialog-mask.p-component-overlay{pointer-events:auto}.p-dialog{display:flex;flex-direction:column;pointer-events:auto;max-height:90%;transform:scale(1);position:relative}.p-dialog-content{overflow-y:auto;flex-grow:1}.p-dialog-header{display:flex;align-items:center;justify-content:space-between;flex-shrink:0}.p-dialog-footer{flex-shrink:0}.p-dialog .p-dialog-header-icons{display:flex;align-items:center}.p-dialog .p-dialog-header-icon{display:flex;align-items:center;justify-content:center;overflow:hidden;position:relative}.p-fluid .p-dialog-footer .p-button{width:auto}.p-dialog-top .p-dialog,.p-dialog-bottom .p-dialog,.p-dialog-left .p-dialog,.p-dialog-right .p-dialog,.p-dialog-top-left .p-dialog,.p-dialog-top-right .p-dialog,.p-dialog-bottom-left .p-dialog,.p-dialog-bottom-right .p-dialog{margin:.75rem;transform:translate(0)}.p-dialog-maximized{transition:none;transform:none;width:100vw!important;height:100vh!important;top:0px!important;left:0px!important;max-height:100%;height:100%}.p-dialog-maximized .p-dialog-content{flex-grow:1}.p-dialog-left{justify-content:flex-start}.p-dialog-right{justify-content:flex-end}.p-dialog-top{align-items:flex-start}.p-dialog-top-left{justify-content:flex-start;align-items:flex-start}.p-dialog-top-right{justify-content:flex-end;align-items:flex-start}.p-dialog-bottom{align-items:flex-end}.p-dialog-bottom-left{justify-content:flex-start;align-items:flex-end}.p-dialog-bottom-right{justify-content:flex-end;align-items:flex-end}.p-dialog .p-resizable-handle{position:absolute;font-size:.1px;display:block;cursor:se-resize;width:12px;height:12px;right:1px;bottom:1px}.p-confirm-dialog .p-dialog-content{display:flex;align-items:center}\\n\"] }]\n }], ctorParameters: function () { return [{ type: i0.ComponentFactoryResolver }, { type: i0.ChangeDetectorRef }, { type: i0.Renderer2 }, { type: DynamicDialogConfig }, { type: DynamicDialogRef }, { type: i0.NgZone }, { type: i3.PrimeNGConfig }]; }, propDecorators: { insertionPoint: [{\n type: ViewChild,\n args: [DynamicDialogContent]\n }], maskViewChild: [{\n type: ViewChild,\n args: ['mask']\n }] } });\nclass DynamicDialogModule {\n}\nDynamicDialogModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"13.0.0\", ngImport: i0, type: DynamicDialogModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });\nDynamicDialogModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: \"12.0.0\", version: \"13.0.0\", ngImport: i0, type: DynamicDialogModule, declarations: [DynamicDialogComponent, DynamicDialogContent], imports: [CommonModule] });\nDynamicDialogModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: \"12.0.0\", version: \"13.0.0\", ngImport: i0, type: DynamicDialogModule, imports: [[CommonModule]] });\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"13.0.0\", ngImport: i0, type: DynamicDialogModule, decorators: [{\n type: NgModule,\n args: [{\n imports: [CommonModule],\n declarations: [DynamicDialogComponent, DynamicDialogContent],\n entryComponents: [DynamicDialogComponent]\n }]\n }] });\n\nclass DynamicDialogInjector {\n constructor(_parentInjector, _additionalTokens) {\n this._parentInjector = _parentInjector;\n this._additionalTokens = _additionalTokens;\n }\n get(token, notFoundValue, flags) {\n const value = this._additionalTokens.get(token);\n if (value)\n return value;\n return this._parentInjector.get(token, notFoundValue);\n }\n}\n\nclass DialogService {\n constructor(componentFactoryResolver, appRef, injector) {\n this.componentFactoryResolver = componentFactoryResolver;\n this.appRef = appRef;\n this.injector = injector;\n this.dialogComponentRefMap = new Map();\n }\n open(componentType, config) {\n const dialogRef = this.appendDialogComponentToBody(config);\n this.dialogComponentRefMap.get(dialogRef).instance.childComponentType = componentType;\n return dialogRef;\n }\n appendDialogComponentToBody(config) {\n const map = new WeakMap();\n map.set(DynamicDialogConfig, config);\n const dialogRef = new DynamicDialogRef();\n map.set(DynamicDialogRef, dialogRef);\n const sub = dialogRef.onClose.subscribe(() => {\n this.dialogComponentRefMap.get(dialogRef).instance.close();\n });\n const destroySub = dialogRef.onDestroy.subscribe(() => {\n this.removeDialogComponentFromBody(dialogRef);\n destroySub.unsubscribe();\n sub.unsubscribe();\n });\n const componentFactory = this.componentFactoryResolver.resolveComponentFactory(DynamicDialogComponent);\n const componentRef = componentFactory.create(new DynamicDialogInjector(this.injector, map));\n this.appRef.attachView(componentRef.hostView);\n const domElem = componentRef.hostView.rootNodes[0];\n document.body.appendChild(domElem);\n this.dialogComponentRefMap.set(dialogRef, componentRef);\n return dialogRef;\n }\n removeDialogComponentFromBody(dialogRef) {\n if (!dialogRef || !this.dialogComponentRefMap.has(dialogRef)) {\n return;\n }\n const dialogComponentRef = this.dialogComponentRefMap.get(dialogRef);\n this.appRef.detachView(dialogComponentRef.hostView);\n dialogComponentRef.destroy();\n this.dialogComponentRefMap.delete(dialogRef);\n }\n}\nDialogService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"13.0.0\", ngImport: i0, type: DialogService, deps: [{ token: i0.ComponentFactoryResolver }, { token: i0.ApplicationRef }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Injectable });\nDialogService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: \"12.0.0\", version: \"13.0.0\", ngImport: i0, type: DialogService });\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"13.0.0\", ngImport: i0, type: DialogService, decorators: [{\n type: Injectable\n }], ctorParameters: function () { return [{ type: i0.ComponentFactoryResolver }, { type: i0.ApplicationRef }, { type: i0.Injector }]; } });\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { DialogService, DynamicDialogComponent, DynamicDialogConfig, DynamicDialogInjector, DynamicDialogModule, DynamicDialogRef };\n"]},"metadata":{},"sourceType":"module"}
Note: See TracBrowser for help on using the repository browser.