UNPKG

@ng-bootstrap/ng-bootstrap

Version:
1 lines 57.8 kB
{"version":3,"file":"ng-bootstrap-ng-bootstrap-modal.mjs","sources":["../../../src/modal/modal-config.ts","../../../src/modal/modal-backdrop.ts","../../../src/modal/modal-ref.ts","../../../src/modal/modal-dismiss-reasons.ts","../../../src/modal/modal-window.ts","../../../src/modal/modal-stack.ts","../../../src/modal/modal.ts","../../../src/modal/modal.module.ts","../../../src/modal/ng-bootstrap-ng-bootstrap-modal.ts"],"sourcesContent":["import { inject, Injectable, Injector } from '@angular/core';\nimport { NgbConfig } from '@ng-bootstrap/ng-bootstrap/config';\n\n/**\n * Options available when opening new modal windows with `NgbModal.open()` method.\n */\nexport interface NgbModalOptions {\n\t/**\n\t * If `true`, modal opening and closing will be animated.\n\t *\n\t * @since 8.0.0\n\t */\n\tanimation?: boolean;\n\n\t/**\n\t * `aria-labelledby` attribute value to set on the modal window.\n\t *\n\t * @since 2.2.0\n\t */\n\tariaLabelledBy?: string;\n\n\t/**\n\t * `aria-describedby` attribute value to set on the modal window.\n\t *\n\t * @since 6.1.0\n\t */\n\tariaDescribedBy?: string;\n\n\t/**\n\t * If `true`, the backdrop element will be created for a given modal.\n\t *\n\t * Alternatively, specify `'static'` for a backdrop which doesn't close the modal on click.\n\t *\n\t * Default value is `true`.\n\t */\n\tbackdrop?: boolean | 'static';\n\n\t/**\n\t * Callback right before the modal will be dismissed.\n\t *\n\t * If this function returns:\n\t * * `false`\n\t * * a promise resolved with `false`\n\t * * a promise that is rejected\n\t *\n\t * then the modal won't be dismissed.\n\t */\n\tbeforeDismiss?: () => boolean | Promise<boolean>;\n\n\t/**\n\t * If `true`, the modal will be centered vertically.\n\t *\n\t * Default value is `false`.\n\t *\n\t * @since 1.1.0\n\t */\n\tcentered?: boolean;\n\n\t/**\n\t * A selector specifying the element all new modal windows should be appended to.\n\t * Since v5.3.0 it is also possible to pass the reference to an `HTMLElement`.\n\t *\n\t * If not specified, will be `body`.\n\t */\n\tcontainer?: string | HTMLElement;\n\n\t/**\n\t * If `true` modal will always be displayed in fullscreen mode.\n\t *\n\t * For values like `'md'` it means that modal will be displayed in fullscreen mode\n\t * only if the viewport width is below `'md'`. For custom strings (ex. when passing `'mysize'`)\n\t * it will add a `'modal-fullscreen-mysize-down'` class.\n\t *\n\t * If not specified will be `false`.\n\t *\n\t * @since 12.1.0\n\t */\n\tfullscreen?: 'sm' | 'md' | 'lg' | 'xl' | 'xxl' | boolean | string;\n\n\t/**\n\t * The `Injector` to use for modal content.\n\t */\n\tinjector?: Injector;\n\n\t/**\n\t * If `true`, the modal will be closed when `Escape` key is pressed\n\t *\n\t * Default value is `true`.\n\t */\n\tkeyboard?: boolean;\n\n\t/**\n\t * `role` attribute value to set on the modal window.\n\t *\n\t * Default value is `dialog`.\n\t *\n\t * @since 18.0.0\n\t */\n\trole?: 'alertdialog' | 'dialog';\n\n\t/**\n\t * Scrollable modal content (false by default).\n\t *\n\t * @since 5.0.0\n\t */\n\tscrollable?: boolean;\n\n\t/**\n\t * Size of a new modal window.\n\t */\n\tsize?: 'sm' | 'lg' | 'xl' | string;\n\n\t/**\n\t * A custom class to append to the modal window.\n\t */\n\twindowClass?: string;\n\n\t/**\n\t * A custom class to append to the modal dialog.\n\t *\n\t * @since 9.1.0\n\t */\n\tmodalDialogClass?: string;\n\n\t/**\n\t * A custom class to append to the modal backdrop.\n\t *\n\t * @since 1.1.0\n\t */\n\tbackdropClass?: string;\n}\n\n/**\n * Options that can be changed on an opened modal with `NgbModalRef.update()` and `NgbActiveModal.update()` methods.\n *\n * @since 14.2.0\n */\nexport type NgbModalUpdatableOptions = Pick<\n\tNgbModalOptions,\n\t| 'ariaLabelledBy'\n\t| 'ariaDescribedBy'\n\t| 'centered'\n\t| 'fullscreen'\n\t| 'backdropClass'\n\t| 'size'\n\t| 'windowClass'\n\t| 'modalDialogClass'\n>;\n\n/**\n * A configuration service for the [`NgbModal`](#/components/modal/api#NgbModal) service.\n *\n * You can inject this service, typically in your root component, and customize the values of its properties in\n * order to provide default values for all modals used in the application.\n *\n * @since 3.1.0\n */\n@Injectable({ providedIn: 'root' })\nexport class NgbModalConfig implements Required<NgbModalOptions> {\n\tprivate _ngbConfig = inject(NgbConfig);\n\tprivate _animation: boolean;\n\n\tariaLabelledBy: string;\n\tariaDescribedBy: string;\n\tbackdrop: boolean | 'static' = true;\n\tbeforeDismiss: () => boolean | Promise<boolean>;\n\tcentered: boolean;\n\tcontainer: string | HTMLElement;\n\tfullscreen: 'sm' | 'md' | 'lg' | 'xl' | 'xxl' | boolean | string = false;\n\tinjector: Injector;\n\tkeyboard = true;\n\trole: 'alertdialog' | 'dialog' = 'dialog';\n\tscrollable: boolean;\n\tsize: 'sm' | 'lg' | 'xl' | string;\n\twindowClass: string;\n\tmodalDialogClass: string;\n\tbackdropClass: string;\n\n\tget animation(): boolean {\n\t\treturn this._animation ?? this._ngbConfig.animation;\n\t}\n\tset animation(animation: boolean) {\n\t\tthis._animation = animation;\n\t}\n}\n","import {\n\tafterNextRender,\n\tChangeDetectorRef,\n\tComponent,\n\tElementRef,\n\tinject,\n\tInjector,\n\tInput,\n\tNgZone,\n\tOnInit,\n\tViewEncapsulation,\n} from '@angular/core';\n\nimport { Observable } from 'rxjs';\n\nimport { ngbRunTransition, isDefined, reflow } from './_ngb-ngbootstrap-utilities.mjs';\nimport { NgbModalUpdatableOptions } from './modal-config';\n\nconst BACKDROP_ATTRIBUTES: string[] = ['animation', 'backdropClass'];\n\n@Component({\n\tselector: 'ngb-modal-backdrop',\n\tencapsulation: ViewEncapsulation.None,\n\ttemplate: '',\n\thost: {\n\t\t'[class]': '\"modal-backdrop\" + (backdropClass ? \" \" + backdropClass : \"\")',\n\t\t'[class.show]': '!animation',\n\t\t'[class.fade]': 'animation',\n\t\tstyle: 'z-index: 1055',\n\t},\n})\nexport class NgbModalBackdrop implements OnInit {\n\tprivate _nativeElement = inject(ElementRef).nativeElement as HTMLElement;\n\tprivate _zone = inject(NgZone);\n\tprivate _injector = inject(Injector);\n\tprivate _cdRef = inject(ChangeDetectorRef);\n\n\t@Input() animation: boolean;\n\t@Input() backdropClass: string;\n\n\tngOnInit() {\n\t\tafterNextRender(\n\t\t\t{\n\t\t\t\tmixedReadWrite: () =>\n\t\t\t\t\tngbRunTransition(\n\t\t\t\t\t\tthis._zone,\n\t\t\t\t\t\tthis._nativeElement,\n\t\t\t\t\t\t(element: HTMLElement, animation: boolean) => {\n\t\t\t\t\t\t\tif (animation) {\n\t\t\t\t\t\t\t\treflow(element);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telement.classList.add('show');\n\t\t\t\t\t\t},\n\t\t\t\t\t\t{ animation: this.animation, runningTransition: 'continue' },\n\t\t\t\t\t),\n\t\t\t},\n\t\t\t{ injector: this._injector },\n\t\t);\n\t}\n\n\thide(): Observable<void> {\n\t\treturn ngbRunTransition(this._zone, this._nativeElement, ({ classList }) => classList.remove('show'), {\n\t\t\tanimation: this.animation,\n\t\t\trunningTransition: 'stop',\n\t\t});\n\t}\n\n\tupdateOptions(options: NgbModalUpdatableOptions) {\n\t\tBACKDROP_ATTRIBUTES.forEach((optionName: string) => {\n\t\t\tif (isDefined(options[optionName])) {\n\t\t\t\tthis[optionName] = options[optionName];\n\t\t\t}\n\t\t});\n\t\tthis._cdRef.markForCheck();\n\t}\n}\n","import { ComponentRef } from '@angular/core';\n\nimport { Observable, of, Subject, zip } from 'rxjs';\nimport { takeUntil } from 'rxjs/operators';\n\nimport { NgbModalBackdrop } from './modal-backdrop';\nimport { NgbModalWindow } from './modal-window';\nimport { NgbModalUpdatableOptions } from './modal-config';\n\nimport { isPromise, ContentRef } from './_ngb-ngbootstrap-utilities.mjs';\n\n/**\n * A reference to the currently opened (active) modal.\n *\n * Instances of this class can be injected into your component passed as modal content.\n * So you can `.update()`, `.close()` or `.dismiss()` the modal window from your component.\n */\nexport class NgbActiveModal {\n\t/**\n\t * Updates options of an opened modal.\n\t *\n\t * @since 14.2.0\n\t */\n\tupdate(options: NgbModalUpdatableOptions): void {}\n\t/**\n\t * Closes the modal with an optional `result` value.\n\t *\n\t * The `NgbModalRef.result` promise will be resolved with the provided value.\n\t */\n\tclose(result?: any): void {}\n\n\t/**\n\t * Dismisses the modal with an optional `reason` value.\n\t *\n\t * The `NgbModalRef.result` promise will be rejected with the provided value.\n\t */\n\tdismiss(reason?: any): void {}\n}\n\n/**\n * A reference to the newly opened modal returned by the `NgbModal.open()` method.\n */\nexport class NgbModalRef {\n\tprivate _closed = new Subject<any>();\n\tprivate _dismissed = new Subject<any>();\n\tprivate _hidden = new Subject<void>();\n\tprivate _resolve: (result?: any) => void;\n\tprivate _reject: (reason?: any) => void;\n\n\t/**\n\t * Updates options of an opened modal.\n\t *\n\t * @since 14.2.0\n\t */\n\tupdate(options: NgbModalUpdatableOptions): void {\n\t\tthis._windowCmptRef.instance.updateOptions(options);\n\t\tif (this._backdropCmptRef && this._backdropCmptRef.instance) {\n\t\t\tthis._backdropCmptRef.instance.updateOptions(options);\n\t\t}\n\t}\n\n\t/**\n\t * The instance of a component used for the modal content.\n\t *\n\t * When a `TemplateRef` is used as the content or when the modal is closed, will return `undefined`.\n\t */\n\tget componentInstance(): any {\n\t\tif (this._contentRef && this._contentRef.componentRef) {\n\t\t\treturn this._contentRef.componentRef.instance;\n\t\t}\n\t}\n\n\t/**\n\t * The promise that is resolved when the modal is closed and rejected when the modal is dismissed.\n\t */\n\tresult: Promise<any>;\n\n\t/**\n\t * The observable that emits when the modal is closed via the `.close()` method.\n\t *\n\t * It will emit the result passed to the `.close()` method.\n\t *\n\t * @since 8.0.0\n\t */\n\tget closed(): Observable<any> {\n\t\treturn this._closed.asObservable().pipe(takeUntil(this._hidden));\n\t}\n\n\t/**\n\t * The observable that emits when the modal is dismissed via the `.dismiss()` method.\n\t *\n\t * It will emit the reason passed to the `.dismissed()` method by the user, or one of the internal\n\t * reasons like backdrop click or ESC key press.\n\t *\n\t * @since 8.0.0\n\t */\n\tget dismissed(): Observable<any> {\n\t\treturn this._dismissed.asObservable().pipe(takeUntil(this._hidden));\n\t}\n\n\t/**\n\t * The observable that emits when both modal window and backdrop are closed and animations were finished.\n\t * At this point modal and backdrop elements will be removed from the DOM tree.\n\t *\n\t * This observable will be completed after emitting.\n\t *\n\t * @since 8.0.0\n\t */\n\tget hidden(): Observable<void> {\n\t\treturn this._hidden.asObservable();\n\t}\n\n\t/**\n\t * The observable that emits when modal is fully visible and animation was finished.\n\t * Modal DOM element is always available synchronously after calling 'modal.open()' service.\n\t *\n\t * This observable will be completed after emitting.\n\t * It will not emit, if modal is closed before open animation is finished.\n\t *\n\t * @since 8.0.0\n\t */\n\tget shown(): Observable<void> {\n\t\treturn this._windowCmptRef.instance.shown.asObservable();\n\t}\n\n\tconstructor(\n\t\tprivate _windowCmptRef: ComponentRef<NgbModalWindow>,\n\t\tprivate _contentRef: ContentRef,\n\t\tprivate _backdropCmptRef?: ComponentRef<NgbModalBackdrop>,\n\t\tprivate _beforeDismiss?: () => boolean | Promise<boolean>,\n\t) {\n\t\t_windowCmptRef.instance.dismissEvent.subscribe((reason: any) => {\n\t\t\tthis.dismiss(reason);\n\t\t});\n\n\t\tthis.result = new Promise((resolve, reject) => {\n\t\t\tthis._resolve = resolve;\n\t\t\tthis._reject = reject;\n\t\t});\n\t\tthis.result.then(null, () => {});\n\t}\n\n\t/**\n\t * Closes the modal with an optional `result` value.\n\t *\n\t * The `NgbMobalRef.result` promise will be resolved with the provided value.\n\t */\n\tclose(result?: any): void {\n\t\tif (this._windowCmptRef) {\n\t\t\tthis._closed.next(result);\n\t\t\tthis._resolve(result);\n\t\t\tthis._removeModalElements();\n\t\t}\n\t}\n\n\tprivate _dismiss(reason?: any) {\n\t\tthis._dismissed.next(reason);\n\t\tthis._reject(reason);\n\t\tthis._removeModalElements();\n\t}\n\n\t/**\n\t * Dismisses the modal with an optional `reason` value.\n\t *\n\t * The `NgbModalRef.result` promise will be rejected with the provided value.\n\t */\n\tdismiss(reason?: any): void {\n\t\tif (this._windowCmptRef) {\n\t\t\tif (!this._beforeDismiss) {\n\t\t\t\tthis._dismiss(reason);\n\t\t\t} else {\n\t\t\t\tconst dismiss = this._beforeDismiss();\n\t\t\t\tif (isPromise(dismiss)) {\n\t\t\t\t\tdismiss.then(\n\t\t\t\t\t\t(result) => {\n\t\t\t\t\t\t\tif (result !== false) {\n\t\t\t\t\t\t\t\tthis._dismiss(reason);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t},\n\t\t\t\t\t\t() => {},\n\t\t\t\t\t);\n\t\t\t\t} else if (dismiss !== false) {\n\t\t\t\t\tthis._dismiss(reason);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate _removeModalElements() {\n\t\tconst windowTransition$ = this._windowCmptRef.instance.hide();\n\t\tconst backdropTransition$ = this._backdropCmptRef ? this._backdropCmptRef.instance.hide() : of(undefined);\n\n\t\t// hiding window\n\t\twindowTransition$.subscribe(() => {\n\t\t\tconst { nativeElement } = this._windowCmptRef.location;\n\t\t\tnativeElement.parentNode.removeChild(nativeElement);\n\t\t\tthis._windowCmptRef.destroy();\n\t\t\tthis._contentRef?.viewRef?.destroy();\n\n\t\t\tthis._windowCmptRef = <any>null;\n\t\t\tthis._contentRef = <any>null;\n\t\t});\n\n\t\t// hiding backdrop\n\t\tbackdropTransition$.subscribe(() => {\n\t\t\tif (this._backdropCmptRef) {\n\t\t\t\tconst { nativeElement } = this._backdropCmptRef.location;\n\t\t\t\tnativeElement.parentNode.removeChild(nativeElement);\n\t\t\t\tthis._backdropCmptRef.destroy();\n\t\t\t\tthis._backdropCmptRef = <any>null;\n\t\t\t}\n\t\t});\n\n\t\t// all done\n\t\tzip(windowTransition$, backdropTransition$).subscribe(() => {\n\t\t\tthis._hidden.next();\n\t\t\tthis._hidden.complete();\n\t\t});\n\t}\n}\n","export enum ModalDismissReasons {\n\tBACKDROP_CLICK,\n\tESC,\n}\n","import {\n\tafterNextRender,\n\tChangeDetectorRef,\n\tComponent,\n\tElementRef,\n\tEventEmitter,\n\tinject,\n\tInjector,\n\tInput,\n\tNgZone,\n\tOnDestroy,\n\tOnInit,\n\tOutput,\n\tViewChild,\n\tViewEncapsulation,\n\tDOCUMENT,\n} from '@angular/core';\n\nimport { fromEvent, Observable, Subject, zip } from 'rxjs';\nimport { filter, switchMap, take, takeUntil, tap } from 'rxjs/operators';\n\nimport { ModalDismissReasons } from './modal-dismiss-reasons';\nimport {\n\tisDefined,\n\tisString,\n\tgetFocusableBoundaryElements,\n\tngbRunTransition,\n\tNgbTransitionOptions,\n\treflow,\n} from './_ngb-ngbootstrap-utilities.mjs';\nimport { NgbModalUpdatableOptions } from './modal-config';\n\nconst WINDOW_ATTRIBUTES: string[] = [\n\t'animation',\n\t'ariaLabelledBy',\n\t'ariaDescribedBy',\n\t'backdrop',\n\t'centered',\n\t'fullscreen',\n\t'keyboard',\n\t'role',\n\t'scrollable',\n\t'size',\n\t'windowClass',\n\t'modalDialogClass',\n] as const;\n\n@Component({\n\tselector: 'ngb-modal-window',\n\thost: {\n\t\t'[class]': '\"modal d-block\" + (windowClass ? \" \" + windowClass : \"\")',\n\t\t'[class.fade]': 'animation',\n\t\ttabindex: '-1',\n\t\t'[attr.aria-modal]': 'true',\n\t\t'[attr.aria-labelledby]': 'ariaLabelledBy',\n\t\t'[attr.aria-describedby]': 'ariaDescribedBy',\n\t\t'[attr.role]': 'role',\n\t},\n\ttemplate: `\n\t\t<div\n\t\t\t#dialog\n\t\t\t[class]=\"\n\t\t\t\t'modal-dialog' +\n\t\t\t\t(size ? ' modal-' + size : '') +\n\t\t\t\t(centered ? ' modal-dialog-centered' : '') +\n\t\t\t\tfullscreenClass +\n\t\t\t\t(scrollable ? ' modal-dialog-scrollable' : '') +\n\t\t\t\t(modalDialogClass ? ' ' + modalDialogClass : '')\n\t\t\t\"\n\t\t\trole=\"document\"\n\t\t>\n\t\t\t<div class=\"modal-content\"><ng-content /></div>\n\t\t</div>\n\t`,\n\tencapsulation: ViewEncapsulation.None,\n\tstyleUrl: './modal.scss',\n})\nexport class NgbModalWindow implements OnInit, OnDestroy {\n\tprivate _document = inject(DOCUMENT);\n\tprivate _elRef = inject(ElementRef<HTMLElement>);\n\tprivate _zone = inject(NgZone);\n\tprivate _injector = inject(Injector);\n\tprivate _cdRef = inject(ChangeDetectorRef);\n\n\tprivate _closed$ = new Subject<void>();\n\tprivate _elWithFocus: Element | null = null; // element that is focused prior to modal opening\n\n\t@ViewChild('dialog', { static: true }) private _dialogEl: ElementRef<HTMLElement>;\n\n\t@Input() animation: boolean;\n\t@Input() ariaLabelledBy: string;\n\t@Input() ariaDescribedBy: string;\n\t@Input() backdrop: boolean | string = true;\n\t@Input() centered: string;\n\t@Input() fullscreen: string | boolean;\n\t@Input() keyboard = true;\n\t@Input() role: string = 'dialog';\n\t@Input() scrollable: string;\n\t@Input() size: string;\n\t@Input() windowClass: string;\n\t@Input() modalDialogClass: string;\n\n\t@Output('dismiss') dismissEvent = new EventEmitter();\n\n\tshown = new Subject<void>();\n\thidden = new Subject<void>();\n\n\tget fullscreenClass(): string {\n\t\treturn this.fullscreen === true\n\t\t\t? ' modal-fullscreen'\n\t\t\t: isString(this.fullscreen)\n\t\t\t ? ` modal-fullscreen-${this.fullscreen}-down`\n\t\t\t : '';\n\t}\n\n\tdismiss(reason): void {\n\t\tthis.dismissEvent.emit(reason);\n\t}\n\n\tngOnInit() {\n\t\tthis._elWithFocus = this._document.activeElement;\n\t\tafterNextRender({ mixedReadWrite: () => this._show() }, { injector: this._injector });\n\t}\n\n\tngOnDestroy() {\n\t\tthis._disableEventHandling();\n\t}\n\n\thide(): Observable<any> {\n\t\tconst { nativeElement } = this._elRef;\n\t\tconst context: NgbTransitionOptions<any> = { animation: this.animation, runningTransition: 'stop' };\n\n\t\tconst windowTransition$ = ngbRunTransition(\n\t\t\tthis._zone,\n\t\t\tnativeElement,\n\t\t\t() => nativeElement.classList.remove('show'),\n\t\t\tcontext,\n\t\t);\n\t\tconst dialogTransition$ = ngbRunTransition(this._zone, this._dialogEl.nativeElement, () => {}, context);\n\n\t\tconst transitions$ = zip(windowTransition$, dialogTransition$);\n\t\ttransitions$.subscribe(() => {\n\t\t\tthis.hidden.next();\n\t\t\tthis.hidden.complete();\n\t\t});\n\n\t\tthis._disableEventHandling();\n\t\tthis._restoreFocus();\n\n\t\treturn transitions$;\n\t}\n\n\tupdateOptions(options: NgbModalUpdatableOptions): void {\n\t\tWINDOW_ATTRIBUTES.forEach((optionName: string) => {\n\t\t\tif (isDefined(options[optionName])) {\n\t\t\t\tthis[optionName] = options[optionName];\n\t\t\t}\n\t\t});\n\t\tthis._cdRef.markForCheck();\n\t}\n\n\tprivate _show() {\n\t\tconst context: NgbTransitionOptions<any> = { animation: this.animation, runningTransition: 'continue' };\n\n\t\tconst windowTransition$ = ngbRunTransition(\n\t\t\tthis._zone,\n\t\t\tthis._elRef.nativeElement,\n\t\t\t(element: HTMLElement, animation: boolean) => {\n\t\t\t\tif (animation) {\n\t\t\t\t\treflow(element);\n\t\t\t\t}\n\t\t\t\telement.classList.add('show');\n\t\t\t},\n\t\t\tcontext,\n\t\t);\n\t\tconst dialogTransition$ = ngbRunTransition(this._zone, this._dialogEl.nativeElement, () => {}, context);\n\n\t\tzip(windowTransition$, dialogTransition$).subscribe(() => {\n\t\t\tthis.shown.next();\n\t\t\tthis.shown.complete();\n\t\t});\n\n\t\tthis._enableEventHandling();\n\t\tthis._setFocus();\n\t}\n\n\tprivate _enableEventHandling() {\n\t\tconst { nativeElement } = this._elRef;\n\t\tthis._zone.runOutsideAngular(() => {\n\t\t\tfromEvent<KeyboardEvent>(nativeElement, 'keydown')\n\t\t\t\t.pipe(\n\t\t\t\t\ttakeUntil(this._closed$),\n\t\t\t\t\tfilter((e) => e.key === 'Escape'),\n\t\t\t\t)\n\t\t\t\t.subscribe((event) => {\n\t\t\t\t\tif (this.keyboard) {\n\t\t\t\t\t\trequestAnimationFrame(() => {\n\t\t\t\t\t\t\tif (!event.defaultPrevented) {\n\t\t\t\t\t\t\t\tthis._zone.run(() => this.dismiss(ModalDismissReasons.ESC));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t} else if (this.backdrop === 'static') {\n\t\t\t\t\t\tthis._bumpBackdrop();\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t// We're listening to 'mousedown' and 'mouseup' to prevent modal from closing when pressing the mouse\n\t\t\t// inside the modal dialog and releasing it outside\n\t\t\tlet preventClose = false;\n\t\t\tfromEvent<MouseEvent>(this._dialogEl.nativeElement, 'mousedown')\n\t\t\t\t.pipe(\n\t\t\t\t\ttakeUntil(this._closed$),\n\t\t\t\t\ttap(() => (preventClose = false)),\n\t\t\t\t\tswitchMap(() => fromEvent<MouseEvent>(nativeElement, 'mouseup').pipe(takeUntil(this._closed$), take(1))),\n\t\t\t\t\tfilter(({ target }) => nativeElement === target),\n\t\t\t\t)\n\t\t\t\t.subscribe(() => {\n\t\t\t\t\tpreventClose = true;\n\t\t\t\t});\n\n\t\t\t// We're listening to 'click' to dismiss modal on modal window click, except when:\n\t\t\t// 1. clicking on modal dialog itself\n\t\t\t// 2. closing was prevented by mousedown/up handlers\n\t\t\t// 3. clicking on scrollbar when the viewport is too small and modal doesn't fit (click is not triggered at all)\n\t\t\tfromEvent<MouseEvent>(nativeElement, 'click')\n\t\t\t\t.pipe(takeUntil(this._closed$))\n\t\t\t\t.subscribe(({ target }) => {\n\t\t\t\t\tif (nativeElement === target) {\n\t\t\t\t\t\tif (this.backdrop === 'static') {\n\t\t\t\t\t\t\tthis._bumpBackdrop();\n\t\t\t\t\t\t} else if (this.backdrop === true && !preventClose) {\n\t\t\t\t\t\t\tthis._zone.run(() => this.dismiss(ModalDismissReasons.BACKDROP_CLICK));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tpreventClose = false;\n\t\t\t\t});\n\t\t});\n\t}\n\n\tprivate _disableEventHandling() {\n\t\tthis._closed$.next();\n\t}\n\n\tprivate _setFocus() {\n\t\tconst { nativeElement } = this._elRef;\n\t\tif (!nativeElement.contains(document.activeElement)) {\n\t\t\tconst autoFocusable = nativeElement.querySelector(`[ngbAutofocus]`) as HTMLElement;\n\t\t\tconst firstFocusable = getFocusableBoundaryElements(nativeElement)[0];\n\n\t\t\tconst elementToFocus = autoFocusable || firstFocusable || nativeElement;\n\t\t\telementToFocus.focus();\n\t\t}\n\t}\n\n\tprivate _restoreFocus() {\n\t\tconst body = this._document.body;\n\t\tconst elWithFocus = this._elWithFocus;\n\n\t\tlet elementToFocus;\n\t\tif (elWithFocus && elWithFocus['focus'] && body.contains(elWithFocus)) {\n\t\t\telementToFocus = elWithFocus;\n\t\t} else {\n\t\t\telementToFocus = body;\n\t\t}\n\t\tthis._zone.runOutsideAngular(() => {\n\t\t\tsetTimeout(() => elementToFocus.focus());\n\t\t\tthis._elWithFocus = null;\n\t\t});\n\t}\n\n\tprivate _bumpBackdrop() {\n\t\tif (this.backdrop === 'static') {\n\t\t\tngbRunTransition(\n\t\t\t\tthis._zone,\n\t\t\t\tthis._elRef.nativeElement,\n\t\t\t\t({ classList }) => {\n\t\t\t\t\tclassList.add('modal-static');\n\t\t\t\t\treturn () => classList.remove('modal-static');\n\t\t\t\t},\n\t\t\t\t{ animation: this.animation, runningTransition: 'continue' },\n\t\t\t);\n\t\t}\n\t}\n}\n","import {\n\tApplicationRef,\n\tComponentRef,\n\tcreateComponent,\n\tEnvironmentInjector,\n\tEventEmitter,\n\tinject,\n\tInjectable,\n\tInjector,\n\tNgZone,\n\tTemplateRef,\n\tType,\n\tDOCUMENT,\n} from '@angular/core';\nimport { Subject } from 'rxjs';\n\nimport { isDefined, isString, ngbFocusTrap, ContentRef, ScrollBar } from './_ngb-ngbootstrap-utilities.mjs';\nimport { NgbModalBackdrop } from './modal-backdrop';\nimport { NgbModalOptions, NgbModalUpdatableOptions } from './modal-config';\nimport { NgbActiveModal, NgbModalRef } from './modal-ref';\nimport { NgbModalWindow } from './modal-window';\nimport { take } from 'rxjs/operators';\n\n@Injectable({ providedIn: 'root' })\nexport class NgbModalStack {\n\tprivate _applicationRef = inject(ApplicationRef);\n\tprivate _injector = inject(Injector);\n\tprivate _environmentInjector = inject(EnvironmentInjector);\n\tprivate _document = inject(DOCUMENT);\n\tprivate _scrollBar = inject(ScrollBar);\n\n\tprivate _activeWindowCmptHasChanged = new Subject<void>();\n\tprivate _ariaHiddenValues: Map<Element, string | null> = new Map();\n\tprivate _scrollBarRestoreFn: null | (() => void) = null;\n\tprivate _modalRefs: NgbModalRef[] = [];\n\tprivate _windowCmpts: ComponentRef<NgbModalWindow>[] = [];\n\tprivate _activeInstances: EventEmitter<NgbModalRef[]> = new EventEmitter();\n\n\tconstructor() {\n\t\tconst ngZone = inject(NgZone);\n\n\t\t// Trap focus on active WindowCmpt\n\t\tthis._activeWindowCmptHasChanged.subscribe(() => {\n\t\t\tif (this._windowCmpts.length) {\n\t\t\t\tconst activeWindowCmpt = this._windowCmpts[this._windowCmpts.length - 1];\n\t\t\t\tngbFocusTrap(ngZone, activeWindowCmpt.location.nativeElement, this._activeWindowCmptHasChanged);\n\t\t\t\tthis._revertAriaHidden();\n\t\t\t\tthis._setAriaHidden(activeWindowCmpt.location.nativeElement);\n\t\t\t}\n\t\t});\n\t}\n\n\tprivate _restoreScrollBar() {\n\t\tconst scrollBarRestoreFn = this._scrollBarRestoreFn;\n\t\tif (scrollBarRestoreFn) {\n\t\t\tthis._scrollBarRestoreFn = null;\n\t\t\tscrollBarRestoreFn();\n\t\t}\n\t}\n\n\tprivate _hideScrollBar() {\n\t\tif (!this._scrollBarRestoreFn) {\n\t\t\tthis._scrollBarRestoreFn = this._scrollBar.hide();\n\t\t}\n\t}\n\n\topen(contentInjector: Injector, content: any, options: NgbModalOptions): NgbModalRef {\n\t\tconst containerEl =\n\t\t\toptions.container instanceof HTMLElement\n\t\t\t\t? options.container\n\t\t\t\t: isDefined(options.container)\n\t\t\t\t ? this._document.querySelector(options.container!)\n\t\t\t\t : this._document.body;\n\n\t\tif (!containerEl) {\n\t\t\tthrow new Error(`The specified modal container \"${options.container || 'body'}\" was not found in the DOM.`);\n\t\t}\n\n\t\tthis._hideScrollBar();\n\n\t\tconst activeModal = new NgbActiveModal();\n\n\t\tcontentInjector = options.injector || contentInjector;\n\t\tconst environmentInjector = contentInjector.get(EnvironmentInjector, null) || this._environmentInjector;\n\t\tconst contentRef = this._getContentRef(contentInjector, environmentInjector, content, activeModal, options);\n\n\t\tlet backdropCmptRef: ComponentRef<NgbModalBackdrop> | undefined =\n\t\t\toptions.backdrop !== false ? this._attachBackdrop(containerEl) : undefined;\n\t\tlet windowCmptRef: ComponentRef<NgbModalWindow> = this._attachWindowComponent(containerEl, contentRef.nodes);\n\t\tlet ngbModalRef: NgbModalRef = new NgbModalRef(windowCmptRef, contentRef, backdropCmptRef, options.beforeDismiss);\n\n\t\tthis._registerModalRef(ngbModalRef);\n\t\tthis._registerWindowCmpt(windowCmptRef);\n\n\t\t// We have to cleanup DOM after the last modal when BOTH 'hidden' was emitted and 'result' promise was resolved:\n\t\t// - with animations OFF, 'hidden' emits synchronously, then 'result' is resolved asynchronously\n\t\t// - with animations ON, 'result' is resolved asynchronously, then 'hidden' emits asynchronously\n\t\tngbModalRef.hidden.pipe(take(1)).subscribe(() =>\n\t\t\tPromise.resolve(true).then(() => {\n\t\t\t\tif (!this._modalRefs.length) {\n\t\t\t\t\tthis._document.body.classList.remove('modal-open');\n\t\t\t\t\tthis._restoreScrollBar();\n\t\t\t\t\tthis._revertAriaHidden();\n\t\t\t\t}\n\t\t\t}),\n\t\t);\n\n\t\tactiveModal.close = (result: any) => {\n\t\t\tngbModalRef.close(result);\n\t\t};\n\t\tactiveModal.dismiss = (reason: any) => {\n\t\t\tngbModalRef.dismiss(reason);\n\t\t};\n\n\t\tactiveModal.update = (options: NgbModalUpdatableOptions) => {\n\t\t\tngbModalRef.update(options);\n\t\t};\n\n\t\tngbModalRef.update(options);\n\t\tif (this._modalRefs.length === 1) {\n\t\t\tthis._document.body.classList.add('modal-open');\n\t\t}\n\n\t\tif (backdropCmptRef && backdropCmptRef.instance) {\n\t\t\tbackdropCmptRef.changeDetectorRef.detectChanges();\n\t\t}\n\t\twindowCmptRef.changeDetectorRef.detectChanges();\n\t\treturn ngbModalRef;\n\t}\n\n\tget activeInstances() {\n\t\treturn this._activeInstances;\n\t}\n\n\tdismissAll(reason?: any) {\n\t\tthis._modalRefs.forEach((ngbModalRef) => ngbModalRef.dismiss(reason));\n\t}\n\n\thasOpenModals(): boolean {\n\t\treturn this._modalRefs.length > 0;\n\t}\n\n\tprivate _attachBackdrop(containerEl: Element): ComponentRef<NgbModalBackdrop> {\n\t\tlet backdropCmptRef = createComponent(NgbModalBackdrop, {\n\t\t\tenvironmentInjector: this._applicationRef.injector,\n\t\t\telementInjector: this._injector,\n\t\t});\n\t\tthis._applicationRef.attachView(backdropCmptRef.hostView);\n\t\tcontainerEl.appendChild(backdropCmptRef.location.nativeElement);\n\t\treturn backdropCmptRef;\n\t}\n\n\tprivate _attachWindowComponent(containerEl: Element, projectableNodes: Node[][]): ComponentRef<NgbModalWindow> {\n\t\tlet windowCmptRef = createComponent(NgbModalWindow, {\n\t\t\tenvironmentInjector: this._applicationRef.injector,\n\t\t\telementInjector: this._injector,\n\t\t\tprojectableNodes,\n\t\t});\n\t\tthis._applicationRef.attachView(windowCmptRef.hostView);\n\t\tcontainerEl.appendChild(windowCmptRef.location.nativeElement);\n\t\treturn windowCmptRef;\n\t}\n\n\tprivate _getContentRef(\n\t\tcontentInjector: Injector,\n\t\tenvironmentInjector: EnvironmentInjector,\n\t\tcontent: Type<any> | TemplateRef<any> | string,\n\t\tactiveModal: NgbActiveModal,\n\t\toptions: NgbModalOptions,\n\t): ContentRef {\n\t\tif (!content) {\n\t\t\treturn new ContentRef([]);\n\t\t} else if (content instanceof TemplateRef) {\n\t\t\treturn this._createFromTemplateRef(content, activeModal);\n\t\t} else if (isString(content)) {\n\t\t\treturn this._createFromString(content);\n\t\t} else {\n\t\t\treturn this._createFromComponent(contentInjector, environmentInjector, content, activeModal, options);\n\t\t}\n\t}\n\n\tprivate _createFromTemplateRef(templateRef: TemplateRef<any>, activeModal: NgbActiveModal): ContentRef {\n\t\tconst context = {\n\t\t\t$implicit: activeModal,\n\t\t\tclose(result) {\n\t\t\t\tactiveModal.close(result);\n\t\t\t},\n\t\t\tdismiss(reason) {\n\t\t\t\tactiveModal.dismiss(reason);\n\t\t\t},\n\t\t};\n\t\tconst viewRef = templateRef.createEmbeddedView(context);\n\t\tthis._applicationRef.attachView(viewRef);\n\t\treturn new ContentRef([viewRef.rootNodes], viewRef);\n\t}\n\n\tprivate _createFromString(content: string): ContentRef {\n\t\tconst component = this._document.createTextNode(`${content}`);\n\t\treturn new ContentRef([[component]]);\n\t}\n\n\tprivate _createFromComponent(\n\t\tcontentInjector: Injector,\n\t\tenvironmentInjector: EnvironmentInjector,\n\t\tcomponentType: Type<any>,\n\t\tcontext: NgbActiveModal,\n\t\toptions: NgbModalOptions,\n\t): ContentRef {\n\t\tconst elementInjector = Injector.create({\n\t\t\tproviders: [{ provide: NgbActiveModal, useValue: context }],\n\t\t\tparent: contentInjector,\n\t\t});\n\t\tconst componentRef = createComponent(componentType, {\n\t\t\tenvironmentInjector,\n\t\t\telementInjector,\n\t\t});\n\t\tconst componentNativeEl = componentRef.location.nativeElement;\n\t\tif (options.scrollable) {\n\t\t\t(componentNativeEl as HTMLElement).classList.add('component-host-scrollable');\n\t\t}\n\t\tthis._applicationRef.attachView(componentRef.hostView);\n\t\t// FIXME: we should here get rid of the component nativeElement\n\t\t// and use `[Array.from(componentNativeEl.childNodes)]` instead and remove the above CSS class.\n\t\treturn new ContentRef([[componentNativeEl]], componentRef.hostView, componentRef);\n\t}\n\n\tprivate _setAriaHidden(element: Element) {\n\t\tconst parent = element.parentElement;\n\t\tif (parent && element !== this._document.body) {\n\t\t\tArray.from(parent.children).forEach((sibling) => {\n\t\t\t\tif (sibling !== element && sibling.nodeName !== 'SCRIPT') {\n\t\t\t\t\tthis._ariaHiddenValues.set(sibling, sibling.getAttribute('aria-hidden'));\n\t\t\t\t\tsibling.setAttribute('aria-hidden', 'true');\n\t\t\t\t}\n\t\t\t});\n\n\t\t\tthis._setAriaHidden(parent);\n\t\t}\n\t}\n\n\tprivate _revertAriaHidden() {\n\t\tthis._ariaHiddenValues.forEach((value, element) => {\n\t\t\tif (value) {\n\t\t\t\telement.setAttribute('aria-hidden', value);\n\t\t\t} else {\n\t\t\t\telement.removeAttribute('aria-hidden');\n\t\t\t}\n\t\t});\n\t\tthis._ariaHiddenValues.clear();\n\t}\n\n\tprivate _registerModalRef(ngbModalRef: NgbModalRef) {\n\t\tconst unregisterModalRef = () => {\n\t\t\tconst index = this._modalRefs.indexOf(ngbModalRef);\n\t\t\tif (index > -1) {\n\t\t\t\tthis._modalRefs.splice(index, 1);\n\t\t\t\tthis._activeInstances.emit(this._modalRefs);\n\t\t\t}\n\t\t};\n\t\tthis._modalRefs.push(ngbModalRef);\n\t\tthis._activeInstances.emit(this._modalRefs);\n\t\tngbModalRef.result.then(unregisterModalRef, unregisterModalRef);\n\t}\n\n\tprivate _registerWindowCmpt(ngbWindowCmpt: ComponentRef<NgbModalWindow>) {\n\t\tthis._windowCmpts.push(ngbWindowCmpt);\n\t\tthis._activeWindowCmptHasChanged.next();\n\n\t\tngbWindowCmpt.onDestroy(() => {\n\t\t\tconst index = this._windowCmpts.indexOf(ngbWindowCmpt);\n\t\t\tif (index > -1) {\n\t\t\t\tthis._windowCmpts.splice(index, 1);\n\t\t\t\tthis._activeWindowCmptHasChanged.next();\n\t\t\t}\n\t\t});\n\t}\n}\n","import { inject, Injectable, Injector } from '@angular/core';\n\nimport { NgbModalConfig, NgbModalOptions } from './modal-config';\nimport { NgbModalRef } from './modal-ref';\nimport { NgbModalStack } from './modal-stack';\n\n/**\n * A service for opening modal windows.\n *\n * Creating a modal is straightforward: create a component or a template and pass it as an argument to\n * the `.open()` method.\n */\n@Injectable({ providedIn: 'root' })\nexport class NgbModal {\n\tprivate _injector = inject(Injector);\n\tprivate _modalStack = inject(NgbModalStack);\n\tprivate _config = inject(NgbModalConfig);\n\n\t/**\n\t * Opens a new modal window with the specified content and supplied options.\n\t *\n\t * Content can be provided as a `TemplateRef` or a component type. If you pass a component type as content,\n\t * then instances of those components can be injected with an instance of the `NgbActiveModal` class. You can then\n\t * use `NgbActiveModal` methods to close / dismiss modals from \"inside\" of your component.\n\t *\n\t * Also see the [`NgbModalOptions`](#/components/modal/api#NgbModalOptions) for the list of supported options.\n\t */\n\topen(content: any, options: NgbModalOptions = {}): NgbModalRef {\n\t\tconst combinedOptions = { ...this._config, animation: this._config.animation, ...options };\n\t\treturn this._modalStack.open(this._injector, content, combinedOptions);\n\t}\n\n\t/**\n\t * Returns an observable that holds the active modal instances.\n\t */\n\tget activeInstances() {\n\t\treturn this._modalStack.activeInstances;\n\t}\n\n\t/**\n\t * Dismisses all currently displayed modal windows with the supplied reason.\n\t *\n\t * @since 3.1.0\n\t */\n\tdismissAll(reason?: any) {\n\t\tthis._modalStack.dismissAll(reason);\n\t}\n\n\t/**\n\t * Indicates if there are currently any open modal windows in the application.\n\t *\n\t * @since 3.3.0\n\t */\n\thasOpenModals(): boolean {\n\t\treturn this._modalStack.hasOpenModals();\n\t}\n}\n","import { NgModule } from '@angular/core';\n\nimport { NgbModal } from './modal';\n\nexport { NgbModal } from './modal';\nexport { NgbModalConfig, NgbModalOptions, NgbModalUpdatableOptions } from './modal-config';\nexport { NgbModalRef, NgbActiveModal } from './modal-ref';\nexport { ModalDismissReasons } from './modal-dismiss-reasons';\n\n@NgModule({ providers: [NgbModal] })\nexport class NgbModalModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;AAqJA;;;;;;;AAOG;MAEU,cAAc,CAAA;AAD3B,IAAA,WAAA,GAAA;AAES,QAAA,IAAA,CAAA,UAAU,GAAG,MAAM,CAAC,SAAS,CAAC;QAKtC,IAAA,CAAA,QAAQ,GAAuB,IAAI;QAInC,IAAA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