@fundamental-ngx/core 0.43.9 → 0.43.11
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/date-picker/date-picker.component.d.ts +2 -0
- package/datetime-picker/datetime-picker.component.d.ts +2 -0
- package/dialog/base/dialog-base.service.d.ts +4 -3
- package/dialog/dialog-container/dialog-container.component.d.ts +12 -11
- package/dialog/index.d.ts +11 -10
- package/dialog/utils/dialog-container.model.d.ts +4 -0
- package/esm2020/busy-indicator/busy-indicator.component.mjs +3 -3
- package/esm2020/date-picker/date-picker.component.mjs +8 -8
- package/esm2020/datetime-picker/datetime-picker.component.mjs +8 -7
- package/esm2020/dialog/base/dialog-base.service.mjs +8 -3
- package/esm2020/dialog/dialog-container/dialog-container.component.mjs +23 -23
- package/esm2020/dialog/index.mjs +12 -11
- package/esm2020/dialog/utils/dialog-container.model.mjs +2 -0
- package/esm2020/form/form-message/popover-form-message.service.mjs +2 -12
- package/esm2020/message-box/message-box-container/message-box-container.component.mjs +23 -24
- package/esm2020/multi-input/multi-input.component.mjs +76 -56
- package/esm2020/multi-input/multi-input.module.mjs +17 -14
- package/esm2020/multi-input/pair-selection.model.mjs +38 -0
- package/esm2020/popover/popover-body/popover-body.component.mjs +3 -3
- package/esm2020/popover/popover-service/popover.service.mjs +9 -2
- package/esm2020/time-picker/time-picker.component.mjs +19 -20
- package/esm2020/token/token.component.mjs +4 -3
- package/esm2020/token/tokenizer.component.mjs +32 -13
- package/fesm2015/fundamental-ngx-core-busy-indicator.mjs +2 -2
- package/fesm2015/fundamental-ngx-core-busy-indicator.mjs.map +1 -1
- package/fesm2015/fundamental-ngx-core-date-picker.mjs +6 -6
- package/fesm2015/fundamental-ngx-core-date-picker.mjs.map +1 -1
- package/fesm2015/fundamental-ngx-core-datetime-picker.mjs +6 -6
- package/fesm2015/fundamental-ngx-core-datetime-picker.mjs.map +1 -1
- package/fesm2015/fundamental-ngx-core-dialog.mjs +189 -184
- package/fesm2015/fundamental-ngx-core-dialog.mjs.map +1 -1
- package/fesm2015/fundamental-ngx-core-form.mjs +1 -10
- package/fesm2015/fundamental-ngx-core-form.mjs.map +1 -1
- package/fesm2015/fundamental-ngx-core-message-box.mjs +20 -20
- package/fesm2015/fundamental-ngx-core-message-box.mjs.map +1 -1
- package/fesm2015/fundamental-ngx-core-multi-input.mjs +158 -100
- package/fesm2015/fundamental-ngx-core-multi-input.mjs.map +1 -1
- package/fesm2015/fundamental-ngx-core-popover.mjs +10 -3
- package/fesm2015/fundamental-ngx-core-popover.mjs.map +1 -1
- package/fesm2015/fundamental-ngx-core-time-picker.mjs +14 -16
- package/fesm2015/fundamental-ngx-core-time-picker.mjs.map +1 -1
- package/fesm2015/fundamental-ngx-core-token.mjs +29 -9
- package/fesm2015/fundamental-ngx-core-token.mjs.map +1 -1
- package/fesm2020/fundamental-ngx-core-busy-indicator.mjs +2 -2
- package/fesm2020/fundamental-ngx-core-busy-indicator.mjs.map +1 -1
- package/fesm2020/fundamental-ngx-core-date-picker.mjs +6 -6
- package/fesm2020/fundamental-ngx-core-date-picker.mjs.map +1 -1
- package/fesm2020/fundamental-ngx-core-datetime-picker.mjs +6 -5
- package/fesm2020/fundamental-ngx-core-datetime-picker.mjs.map +1 -1
- package/fesm2020/fundamental-ngx-core-dialog.mjs +188 -183
- package/fesm2020/fundamental-ngx-core-dialog.mjs.map +1 -1
- package/fesm2020/fundamental-ngx-core-form.mjs +1 -10
- package/fesm2020/fundamental-ngx-core-form.mjs.map +1 -1
- package/fesm2020/fundamental-ngx-core-message-box.mjs +20 -20
- package/fesm2020/fundamental-ngx-core-message-box.mjs.map +1 -1
- package/fesm2020/fundamental-ngx-core-multi-input.mjs +158 -98
- package/fesm2020/fundamental-ngx-core-multi-input.mjs.map +1 -1
- package/fesm2020/fundamental-ngx-core-popover.mjs +10 -3
- package/fesm2020/fundamental-ngx-core-popover.mjs.map +1 -1
- package/fesm2020/fundamental-ngx-core-time-picker.mjs +15 -16
- package/fesm2020/fundamental-ngx-core-time-picker.mjs.map +1 -1
- package/fesm2020/fundamental-ngx-core-token.mjs +29 -9
- package/fesm2020/fundamental-ngx-core-token.mjs.map +1 -1
- package/form/form-message/popover-form-message.service.d.ts +3 -7
- package/fundamental-ngx-core-v0.43.11.tgz +0 -0
- package/message-box/message-box-container/message-box-container.component.d.ts +12 -13
- package/multi-input/multi-input.component.d.ts +30 -21
- package/multi-input/multi-input.module.d.ts +2 -1
- package/multi-input/pair-selection.model.d.ts +19 -0
- package/package.json +3 -3
- package/popover/popover-service/popover.service.d.ts +1 -1
- package/schematics/add-dependencies/index.js +4 -4
- package/time-picker/time-picker.component.d.ts +17 -15
- package/token/tokenizer.component.d.ts +10 -2
- package/fundamental-ngx-core-v0.43.9.tgz +0 -0
|
@@ -1,37 +1,40 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { InjectionToken, Injectable,
|
|
2
|
+
import { InjectionToken, Injectable, Component, Optional, Inject, Input, Directive, ContentChildren, ContentChild, inject, isDevMode, HostBinding, HostListener, ChangeDetectionStrategy, ViewEncapsulation, ViewChild, ComponentRef, EmbeddedViewRef, Type, TemplateRef, PLATFORM_ID, Injector, NgModule } from '@angular/core';
|
|
3
|
+
import { Subject, BehaviorSubject, Subscription, fromEvent, takeUntil } from 'rxjs';
|
|
4
|
+
import * as i3 from '@fundamental-ngx/core/scrollbar';
|
|
5
|
+
import { ScrollbarDirective, ScrollbarModule } from '@fundamental-ngx/core/scrollbar';
|
|
3
6
|
import * as i4 from '@angular/common';
|
|
4
7
|
import { isPlatformBrowser, CommonModule } from '@angular/common';
|
|
5
|
-
import * as i7 from '@angular/cdk/a11y';
|
|
6
|
-
import { A11yModule } from '@angular/cdk/a11y';
|
|
7
|
-
import * as i6 from '@angular/cdk/drag-drop';
|
|
8
|
-
import { DragDropModule } from '@angular/cdk/drag-drop';
|
|
9
|
-
import { ButtonModule } from '@fundamental-ngx/core/button';
|
|
10
|
-
import * as i1$1 from '@fundamental-ngx/core/icon';
|
|
11
|
-
import { IconModule } from '@fundamental-ngx/core/icon';
|
|
12
|
-
import * as i3$2 from '@fundamental-ngx/core/title';
|
|
13
|
-
import { TitleToken, TitleModule } from '@fundamental-ngx/core/title';
|
|
14
|
-
import * as i2 from '@fundamental-ngx/core/bar';
|
|
15
|
-
import { FD_BUTTON_BAR_COMPONENT, BarElementDirective, BarModule } from '@fundamental-ngx/core/bar';
|
|
16
8
|
import * as i5 from '@fundamental-ngx/core/busy-indicator';
|
|
17
9
|
import { BusyIndicatorModule } from '@fundamental-ngx/core/busy-indicator';
|
|
10
|
+
import * as i1 from '@fundamental-ngx/core/icon';
|
|
11
|
+
import { IconModule } from '@fundamental-ngx/core/icon';
|
|
12
|
+
import * as i2 from '@fundamental-ngx/core/bar';
|
|
13
|
+
import { BarElementDirective, FD_BUTTON_BAR_COMPONENT, BarModule } from '@fundamental-ngx/core/bar';
|
|
14
|
+
import { startWith, filter, debounceTime } from 'rxjs/operators';
|
|
18
15
|
import * as i4$1 from '@fundamental-ngx/cdk/utils';
|
|
19
16
|
import { TemplateDirective, KeyUtil, applyCssClass, DynamicComponentContainer, DestroyedService, RtlService, ResizeModule, TemplateModule, InitialFocusModule, DynamicComponentService } from '@fundamental-ngx/cdk/utils';
|
|
17
|
+
import * as i3$1 from '@fundamental-ngx/core/content-density';
|
|
18
|
+
import { contentDensityObserverProviders } from '@fundamental-ngx/core/content-density';
|
|
19
|
+
import * as i3$2 from '@fundamental-ngx/core/title';
|
|
20
|
+
import { TitleToken, TitleModule } from '@fundamental-ngx/core/title';
|
|
20
21
|
import { __decorate, __metadata } from 'tslib';
|
|
21
|
-
import * as
|
|
22
|
+
import * as i4$2 from '@angular/cdk/portal';
|
|
23
|
+
import { CdkPortalOutlet, ComponentPortal, PortalModule } from '@angular/cdk/portal';
|
|
24
|
+
import * as i1$1 from '@angular/router';
|
|
22
25
|
import { NavigationStart } from '@angular/router';
|
|
23
|
-
import * as i3 from '@fundamental-ngx/core/content-density';
|
|
24
|
-
import { contentDensityObserverProviders } from '@fundamental-ngx/core/content-density';
|
|
25
|
-
import { Subject, BehaviorSubject, Subscription, fromEvent, takeUntil } from 'rxjs';
|
|
26
|
-
import * as i3$1 from '@fundamental-ngx/core/scrollbar';
|
|
27
|
-
import { ScrollbarDirective, ScrollbarModule } from '@fundamental-ngx/core/scrollbar';
|
|
28
|
-
import { startWith, filter, debounceTime } from 'rxjs/operators';
|
|
29
26
|
import { ESCAPE } from '@angular/cdk/keycodes';
|
|
27
|
+
import * as i6 from '@angular/cdk/drag-drop';
|
|
28
|
+
import { DragDropModule } from '@angular/cdk/drag-drop';
|
|
29
|
+
import * as i7 from '@angular/cdk/a11y';
|
|
30
|
+
import { A11yModule } from '@angular/cdk/a11y';
|
|
30
31
|
import { trigger, state, style, transition, animate } from '@angular/animations';
|
|
31
|
-
import * as i4$2 from '@angular/cdk/portal';
|
|
32
|
-
import { CdkPortalOutlet, ComponentPortal, PortalModule } from '@angular/cdk/portal';
|
|
33
32
|
import * as i2$1 from '@angular/cdk/overlay';
|
|
34
33
|
import { OverlayConfig, OverlayModule, OverlayContainer } from '@angular/cdk/overlay';
|
|
34
|
+
import { ButtonModule } from '@fundamental-ngx/core/button';
|
|
35
|
+
|
|
36
|
+
const FD_DIALOG_BODY_COMPONENT = new InjectionToken('FdDialogBodyComponent');
|
|
37
|
+
const FD_DIALOG_FOCUS_TRAP_ERROR = new InjectionToken('FdDialogFocusTrapError');
|
|
35
38
|
|
|
36
39
|
/* eslint-disable @typescript-eslint/no-inferrable-types */
|
|
37
40
|
class DialogConfigBase {
|
|
@@ -79,82 +82,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
|
|
|
79
82
|
type: Injectable
|
|
80
83
|
}] });
|
|
81
84
|
|
|
82
|
-
class DialogHeaderBase {
|
|
83
|
-
/** @hidden */
|
|
84
|
-
set defaultTitleSize(title) {
|
|
85
|
-
if (title && !title.headerSize) {
|
|
86
|
-
title.headerSize = 5;
|
|
87
|
-
this._changeDetectorRef.detectChanges();
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
/** @hidden */
|
|
91
|
-
constructor(_changeDetectorRef) {
|
|
92
|
-
this._changeDetectorRef = _changeDetectorRef;
|
|
93
|
-
}
|
|
94
|
-
/** @hidden */
|
|
95
|
-
ngAfterContentInit() {
|
|
96
|
-
this._assignCustomTemplates();
|
|
97
|
-
}
|
|
98
|
-
/** @hidden Assign custom templates */
|
|
99
|
-
_assignCustomTemplates() {
|
|
100
|
-
this.customTemplates.forEach((template) => {
|
|
101
|
-
switch (template.getName()) {
|
|
102
|
-
case 'header':
|
|
103
|
-
this.headerTemplate = template.templateRef;
|
|
104
|
-
break;
|
|
105
|
-
case 'subheader':
|
|
106
|
-
this.subHeaderTemplate = template.templateRef;
|
|
107
|
-
break;
|
|
108
|
-
}
|
|
109
|
-
});
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
DialogHeaderBase.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogHeaderBase, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
113
|
-
DialogHeaderBase.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: DialogHeaderBase, queries: [{ propertyName: "defaultTitleSize", first: true, predicate: TitleToken, descendants: true }, { propertyName: "customTemplates", predicate: TemplateDirective }], ngImport: i0 });
|
|
114
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogHeaderBase, decorators: [{
|
|
115
|
-
type: Directive
|
|
116
|
-
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { defaultTitleSize: [{
|
|
117
|
-
type: ContentChild,
|
|
118
|
-
args: [TitleToken]
|
|
119
|
-
}], customTemplates: [{
|
|
120
|
-
type: ContentChildren,
|
|
121
|
-
args: [TemplateDirective]
|
|
122
|
-
}] } });
|
|
123
|
-
|
|
124
|
-
/**
|
|
125
|
-
* Applies fundamental layout and styling to the contents of a dialog header.
|
|
126
|
-
*
|
|
127
|
-
* ```html
|
|
128
|
-
* <fd-dialog-header>
|
|
129
|
-
* <h1 fd-title>Title</h1>
|
|
130
|
-
* <button fd-dialog-close-button></button>
|
|
131
|
-
* </fd-dialog-header>
|
|
132
|
-
* ```
|
|
133
|
-
*/
|
|
134
|
-
class DialogHeaderComponent extends DialogHeaderBase {
|
|
135
|
-
/** @hidden */
|
|
136
|
-
constructor(dialogConfig, changeDetectorRef) {
|
|
137
|
-
super(changeDetectorRef);
|
|
138
|
-
this.dialogConfig = dialogConfig;
|
|
139
|
-
this.dialogConfig = this.dialogConfig || {};
|
|
140
|
-
}
|
|
141
|
-
/** @hidden */
|
|
142
|
-
ngAfterContentInit() {
|
|
143
|
-
super.ngAfterContentInit();
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
DialogHeaderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogHeaderComponent, deps: [{ token: DialogConfig, optional: true }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
147
|
-
DialogHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DialogHeaderComponent, selector: "fd-dialog-header", usesInheritance: true, ngImport: i0, template: "<div\n fd-bar\n class=\"fd-dialog__header\"\n [fdCozy]=\"dialogConfig.mobile\"\n [barDesign]=\"subHeaderTemplate ? 'header-with-subheader' : 'header'\"\n>\n <ng-container *ngTemplateOutlet=\"headerTemplate ? headerTemplate : defaultTemplate\"></ng-container>\n\n <ng-template #defaultTemplate>\n <div fd-bar-left>\n <fd-bar-element [fullWidth]=\"true\">\n <ng-content select=\"[fd-title]\"></ng-content>\n </fd-bar-element>\n </div>\n <div fd-bar-right>\n <fd-bar-element>\n <ng-content select=\"[fd-dialog-close-button]\"></ng-content>\n </fd-bar-element>\n </div>\n </ng-template>\n</div>\n\n<div fd-bar *ngIf=\"subHeaderTemplate\" class=\"fd-dialog__subheader\" barDesign=\"subheader\" [fdCozy]=\"dialogConfig.mobile\">\n <ng-container *ngTemplateOutlet=\"subHeaderTemplate\"></ng-container>\n</div>\n", dependencies: [{ kind: "component", type: i2.BarComponent, selector: "[fd-bar]", inputs: ["class", "barDesign", "inPage", "inHomePage", "size"] }, { kind: "directive", type: i2.BarLeftDirective, selector: "[fd-bar-left]" }, { kind: "directive", type: i2.BarRightDirective, selector: "[fd-bar-right]" }, { kind: "directive", type: i2.BarElementDirective, selector: "fd-bar-element", inputs: ["fullWidth", "isTitle"] }, { kind: "directive", type: i3.ContentDensityDirective, selector: "[fdContentDensity]:not([fdCompact]):not([fdCondensed]):not([fdCozy]), [fdCompact]:not([fdContentDensity]):not([fdCondensed]):not([fdCozy]), [fdCondensed]:not([fdContentDensity]):not([fdCompact]):not([fdCozy]), [fdCozy]:not([fdContentDensity]):not([fdCompact]):not([fdCondensed])", inputs: ["fdContentDensity", "fdCompact", "fdCondensed", "fdCozy"], exportAs: ["fdContentDensity"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i4.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] });
|
|
148
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogHeaderComponent, decorators: [{
|
|
149
|
-
type: Component,
|
|
150
|
-
args: [{ selector: 'fd-dialog-header', template: "<div\n fd-bar\n class=\"fd-dialog__header\"\n [fdCozy]=\"dialogConfig.mobile\"\n [barDesign]=\"subHeaderTemplate ? 'header-with-subheader' : 'header'\"\n>\n <ng-container *ngTemplateOutlet=\"headerTemplate ? headerTemplate : defaultTemplate\"></ng-container>\n\n <ng-template #defaultTemplate>\n <div fd-bar-left>\n <fd-bar-element [fullWidth]=\"true\">\n <ng-content select=\"[fd-title]\"></ng-content>\n </fd-bar-element>\n </div>\n <div fd-bar-right>\n <fd-bar-element>\n <ng-content select=\"[fd-dialog-close-button]\"></ng-content>\n </fd-bar-element>\n </div>\n </ng-template>\n</div>\n\n<div fd-bar *ngIf=\"subHeaderTemplate\" class=\"fd-dialog__subheader\" barDesign=\"subheader\" [fdCozy]=\"dialogConfig.mobile\">\n <ng-container *ngTemplateOutlet=\"subHeaderTemplate\"></ng-container>\n</div>\n" }]
|
|
151
|
-
}], ctorParameters: function () { return [{ type: DialogConfig, decorators: [{
|
|
152
|
-
type: Optional
|
|
153
|
-
}] }, { type: i0.ChangeDetectorRef }]; } });
|
|
154
|
-
|
|
155
|
-
const FD_DIALOG_BODY_COMPONENT = new InjectionToken('FdDialogBodyComponent');
|
|
156
|
-
const FD_DIALOG_FOCUS_TRAP_ERROR = new InjectionToken('FdDialogFocusTrapError');
|
|
157
|
-
|
|
158
85
|
class DialogRefBase {
|
|
159
86
|
constructor() {
|
|
160
87
|
/** @hidden */
|
|
@@ -256,7 +183,7 @@ DialogBodyComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", ve
|
|
|
256
183
|
provide: FD_DIALOG_BODY_COMPONENT,
|
|
257
184
|
useExisting: DialogBodyComponent
|
|
258
185
|
}
|
|
259
|
-
], hostDirectives: [{ directive: i3
|
|
186
|
+
], hostDirectives: [{ directive: i3.ScrollbarDirective }], ngImport: i0, template: "<ng-content></ng-content>\n<div class=\"fd-dialog__loader\" *ngIf=\"dialogRef.onLoading | async\">\n <fd-busy-indicator [loading]=\"true\" size=\"l\"></fd-busy-indicator>\n</div>\n", dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i5.BusyIndicatorComponent, selector: "fd-busy-indicator", inputs: ["loading", "size", "block", "ariaLabel", "title", "label", "ariaLive"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }] });
|
|
260
187
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogBodyComponent, decorators: [{
|
|
261
188
|
type: Component,
|
|
262
189
|
args: [{ selector: 'fd-dialog-body', host: {
|
|
@@ -275,11 +202,62 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
|
|
|
275
202
|
type: Optional
|
|
276
203
|
}] }, { type: DialogRef, decorators: [{
|
|
277
204
|
type: Optional
|
|
278
|
-
}] }, { type: i3
|
|
205
|
+
}] }, { type: i3.ScrollbarDirective, decorators: [{
|
|
279
206
|
type: Inject,
|
|
280
207
|
args: [ScrollbarDirective]
|
|
281
208
|
}] }]; } });
|
|
282
209
|
|
|
210
|
+
/**
|
|
211
|
+
* Directive that applies fundamental dialog styling to a dialog close button.
|
|
212
|
+
*
|
|
213
|
+
* ```html
|
|
214
|
+
* <button fd-dialog-close-button></button>
|
|
215
|
+
* ```
|
|
216
|
+
*/
|
|
217
|
+
class DialogCloseButtonComponent {
|
|
218
|
+
constructor() {
|
|
219
|
+
/** Displays dialog close button in mobile mode */
|
|
220
|
+
this.mobile = false;
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
DialogCloseButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogCloseButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
224
|
+
DialogCloseButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DialogCloseButtonComponent, selector: "[fd-dialog-close-button]", inputs: { mobile: "mobile", title: "title" }, host: { properties: { "attr.aria-label": "\"close\"", "class.fd-button": "true", "class.is-compact": "!mobile", "class.fd-button--transparent": "true", "attr.title": "title" } }, ngImport: i0, template: `<fd-icon glyph="decline"></fd-icon><ng-content></ng-content>`, isInline: true, dependencies: [{ kind: "component", type: i1.IconComponent, selector: "fd-icon", inputs: ["glyph", "font", "class", "ariaLabel"] }] });
|
|
225
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogCloseButtonComponent, decorators: [{
|
|
226
|
+
type: Component,
|
|
227
|
+
args: [{
|
|
228
|
+
// eslint-disable-next-line @angular-eslint/component-selector
|
|
229
|
+
selector: '[fd-dialog-close-button]',
|
|
230
|
+
host: {
|
|
231
|
+
'[attr.aria-label]': '"close"',
|
|
232
|
+
'[class.fd-button]': 'true',
|
|
233
|
+
'[class.is-compact]': '!mobile',
|
|
234
|
+
'[class.fd-button--transparent]': 'true',
|
|
235
|
+
'[attr.title]': 'title'
|
|
236
|
+
},
|
|
237
|
+
template: `<fd-icon glyph="decline"></fd-icon><ng-content></ng-content>`
|
|
238
|
+
}]
|
|
239
|
+
}], propDecorators: { mobile: [{
|
|
240
|
+
type: Input
|
|
241
|
+
}], title: [{
|
|
242
|
+
type: Input
|
|
243
|
+
}] } });
|
|
244
|
+
|
|
245
|
+
/**
|
|
246
|
+
* @deprecated
|
|
247
|
+
* Consider using `fd-button-bar`
|
|
248
|
+
*/
|
|
249
|
+
class DialogFooterButtonComponent extends BarElementDirective {
|
|
250
|
+
}
|
|
251
|
+
DialogFooterButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogFooterButtonComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
252
|
+
DialogFooterButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DialogFooterButtonComponent, selector: "fd-dialog-footer-button", usesInheritance: true, ngImport: i0, template: '<ng-content></ng-content>', isInline: true });
|
|
253
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogFooterButtonComponent, decorators: [{
|
|
254
|
+
type: Component,
|
|
255
|
+
args: [{
|
|
256
|
+
selector: 'fd-dialog-footer-button',
|
|
257
|
+
template: '<ng-content></ng-content>'
|
|
258
|
+
}]
|
|
259
|
+
}] });
|
|
260
|
+
|
|
283
261
|
class DialogFooterBase {
|
|
284
262
|
/** @hidden */
|
|
285
263
|
ngAfterContentInit() {
|
|
@@ -345,7 +323,7 @@ class DialogFooterComponent extends DialogFooterBase {
|
|
|
345
323
|
}
|
|
346
324
|
}
|
|
347
325
|
DialogFooterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogFooterComponent, deps: [{ token: DialogConfig, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
348
|
-
DialogFooterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DialogFooterComponent, selector: "fd-dialog-footer", usesInheritance: true, ngImport: i0, template: "<footer fd-bar class=\"fd-dialog__footer\" barDesign=\"footer\" [fdCozy]=\"dialogConfig.mobile\">\n <ng-container *ngTemplateOutlet=\"footerTemplate ? footerTemplate : defaultTemplate\"></ng-container>\n\n <ng-template #defaultTemplate>\n <div fd-bar-right>\n <ng-content></ng-content>\n </div>\n </ng-template>\n</footer>\n", dependencies: [{ kind: "component", type: i2.BarComponent, selector: "[fd-bar]", inputs: ["class", "barDesign", "inPage", "inHomePage", "size"] }, { kind: "directive", type: i2.BarRightDirective, selector: "[fd-bar-right]" }, { kind: "directive", type: i3.ContentDensityDirective, selector: "[fdContentDensity]:not([fdCompact]):not([fdCondensed]):not([fdCozy]), [fdCompact]:not([fdContentDensity]):not([fdCondensed]):not([fdCozy]), [fdCondensed]:not([fdContentDensity]):not([fdCompact]):not([fdCozy]), [fdCozy]:not([fdContentDensity]):not([fdCompact]):not([fdCondensed])", inputs: ["fdContentDensity", "fdCompact", "fdCondensed", "fdCozy"], exportAs: ["fdContentDensity"] }, { kind: "directive", type: i4.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] });
|
|
326
|
+
DialogFooterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DialogFooterComponent, selector: "fd-dialog-footer", usesInheritance: true, ngImport: i0, template: "<footer fd-bar class=\"fd-dialog__footer\" barDesign=\"footer\" [fdCozy]=\"dialogConfig.mobile\">\n <ng-container *ngTemplateOutlet=\"footerTemplate ? footerTemplate : defaultTemplate\"></ng-container>\n\n <ng-template #defaultTemplate>\n <div fd-bar-right>\n <ng-content></ng-content>\n </div>\n </ng-template>\n</footer>\n", dependencies: [{ kind: "component", type: i2.BarComponent, selector: "[fd-bar]", inputs: ["class", "barDesign", "inPage", "inHomePage", "size"] }, { kind: "directive", type: i2.BarRightDirective, selector: "[fd-bar-right]" }, { kind: "directive", type: i3$1.ContentDensityDirective, selector: "[fdContentDensity]:not([fdCompact]):not([fdCondensed]):not([fdCozy]), [fdCompact]:not([fdContentDensity]):not([fdCondensed]):not([fdCozy]), [fdCondensed]:not([fdContentDensity]):not([fdCompact]):not([fdCozy]), [fdCozy]:not([fdContentDensity]):not([fdCompact]):not([fdCondensed])", inputs: ["fdContentDensity", "fdCompact", "fdCondensed", "fdCozy"], exportAs: ["fdContentDensity"] }, { kind: "directive", type: i4.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] });
|
|
349
327
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogFooterComponent, decorators: [{
|
|
350
328
|
type: Component,
|
|
351
329
|
args: [{ selector: 'fd-dialog-footer', template: "<footer fd-bar class=\"fd-dialog__footer\" barDesign=\"footer\" [fdCozy]=\"dialogConfig.mobile\">\n <ng-container *ngTemplateOutlet=\"footerTemplate ? footerTemplate : defaultTemplate\"></ng-container>\n\n <ng-template #defaultTemplate>\n <div fd-bar-right>\n <ng-content></ng-content>\n </div>\n </ng-template>\n</footer>\n" }]
|
|
@@ -353,6 +331,79 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
|
|
|
353
331
|
type: Optional
|
|
354
332
|
}] }]; } });
|
|
355
333
|
|
|
334
|
+
class DialogHeaderBase {
|
|
335
|
+
/** @hidden */
|
|
336
|
+
set defaultTitleSize(title) {
|
|
337
|
+
if (title && !title.headerSize) {
|
|
338
|
+
title.headerSize = 5;
|
|
339
|
+
this._changeDetectorRef.detectChanges();
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
/** @hidden */
|
|
343
|
+
constructor(_changeDetectorRef) {
|
|
344
|
+
this._changeDetectorRef = _changeDetectorRef;
|
|
345
|
+
}
|
|
346
|
+
/** @hidden */
|
|
347
|
+
ngAfterContentInit() {
|
|
348
|
+
this._assignCustomTemplates();
|
|
349
|
+
}
|
|
350
|
+
/** @hidden Assign custom templates */
|
|
351
|
+
_assignCustomTemplates() {
|
|
352
|
+
this.customTemplates.forEach((template) => {
|
|
353
|
+
switch (template.getName()) {
|
|
354
|
+
case 'header':
|
|
355
|
+
this.headerTemplate = template.templateRef;
|
|
356
|
+
break;
|
|
357
|
+
case 'subheader':
|
|
358
|
+
this.subHeaderTemplate = template.templateRef;
|
|
359
|
+
break;
|
|
360
|
+
}
|
|
361
|
+
});
|
|
362
|
+
}
|
|
363
|
+
}
|
|
364
|
+
DialogHeaderBase.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogHeaderBase, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
365
|
+
DialogHeaderBase.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: DialogHeaderBase, queries: [{ propertyName: "defaultTitleSize", first: true, predicate: TitleToken, descendants: true }, { propertyName: "customTemplates", predicate: TemplateDirective }], ngImport: i0 });
|
|
366
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogHeaderBase, decorators: [{
|
|
367
|
+
type: Directive
|
|
368
|
+
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { defaultTitleSize: [{
|
|
369
|
+
type: ContentChild,
|
|
370
|
+
args: [TitleToken]
|
|
371
|
+
}], customTemplates: [{
|
|
372
|
+
type: ContentChildren,
|
|
373
|
+
args: [TemplateDirective]
|
|
374
|
+
}] } });
|
|
375
|
+
|
|
376
|
+
/**
|
|
377
|
+
* Applies fundamental layout and styling to the contents of a dialog header.
|
|
378
|
+
*
|
|
379
|
+
* ```html
|
|
380
|
+
* <fd-dialog-header>
|
|
381
|
+
* <h1 fd-title>Title</h1>
|
|
382
|
+
* <button fd-dialog-close-button></button>
|
|
383
|
+
* </fd-dialog-header>
|
|
384
|
+
* ```
|
|
385
|
+
*/
|
|
386
|
+
class DialogHeaderComponent extends DialogHeaderBase {
|
|
387
|
+
/** @hidden */
|
|
388
|
+
constructor(dialogConfig, changeDetectorRef) {
|
|
389
|
+
super(changeDetectorRef);
|
|
390
|
+
this.dialogConfig = dialogConfig;
|
|
391
|
+
this.dialogConfig = this.dialogConfig || {};
|
|
392
|
+
}
|
|
393
|
+
/** @hidden */
|
|
394
|
+
ngAfterContentInit() {
|
|
395
|
+
super.ngAfterContentInit();
|
|
396
|
+
}
|
|
397
|
+
}
|
|
398
|
+
DialogHeaderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogHeaderComponent, deps: [{ token: DialogConfig, optional: true }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
399
|
+
DialogHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DialogHeaderComponent, selector: "fd-dialog-header", usesInheritance: true, ngImport: i0, template: "<div\n fd-bar\n class=\"fd-dialog__header\"\n [fdCozy]=\"dialogConfig.mobile\"\n [barDesign]=\"subHeaderTemplate ? 'header-with-subheader' : 'header'\"\n>\n <ng-container *ngTemplateOutlet=\"headerTemplate ? headerTemplate : defaultTemplate\"></ng-container>\n\n <ng-template #defaultTemplate>\n <div fd-bar-left>\n <fd-bar-element [fullWidth]=\"true\">\n <ng-content select=\"[fd-title]\"></ng-content>\n </fd-bar-element>\n </div>\n <div fd-bar-right>\n <fd-bar-element>\n <ng-content select=\"[fd-dialog-close-button]\"></ng-content>\n </fd-bar-element>\n </div>\n </ng-template>\n</div>\n\n<div fd-bar *ngIf=\"subHeaderTemplate\" class=\"fd-dialog__subheader\" barDesign=\"subheader\" [fdCozy]=\"dialogConfig.mobile\">\n <ng-container *ngTemplateOutlet=\"subHeaderTemplate\"></ng-container>\n</div>\n", dependencies: [{ kind: "component", type: i2.BarComponent, selector: "[fd-bar]", inputs: ["class", "barDesign", "inPage", "inHomePage", "size"] }, { kind: "directive", type: i2.BarLeftDirective, selector: "[fd-bar-left]" }, { kind: "directive", type: i2.BarRightDirective, selector: "[fd-bar-right]" }, { kind: "directive", type: i2.BarElementDirective, selector: "fd-bar-element", inputs: ["fullWidth", "isTitle"] }, { kind: "directive", type: i3$1.ContentDensityDirective, selector: "[fdContentDensity]:not([fdCompact]):not([fdCondensed]):not([fdCozy]), [fdCompact]:not([fdContentDensity]):not([fdCondensed]):not([fdCozy]), [fdCondensed]:not([fdContentDensity]):not([fdCompact]):not([fdCozy]), [fdCozy]:not([fdContentDensity]):not([fdCompact]):not([fdCondensed])", inputs: ["fdContentDensity", "fdCompact", "fdCondensed", "fdCozy"], exportAs: ["fdContentDensity"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i4.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] });
|
|
400
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogHeaderComponent, decorators: [{
|
|
401
|
+
type: Component,
|
|
402
|
+
args: [{ selector: 'fd-dialog-header', template: "<div\n fd-bar\n class=\"fd-dialog__header\"\n [fdCozy]=\"dialogConfig.mobile\"\n [barDesign]=\"subHeaderTemplate ? 'header-with-subheader' : 'header'\"\n>\n <ng-container *ngTemplateOutlet=\"headerTemplate ? headerTemplate : defaultTemplate\"></ng-container>\n\n <ng-template #defaultTemplate>\n <div fd-bar-left>\n <fd-bar-element [fullWidth]=\"true\">\n <ng-content select=\"[fd-title]\"></ng-content>\n </fd-bar-element>\n </div>\n <div fd-bar-right>\n <fd-bar-element>\n <ng-content select=\"[fd-dialog-close-button]\"></ng-content>\n </fd-bar-element>\n </div>\n </ng-template>\n</div>\n\n<div fd-bar *ngIf=\"subHeaderTemplate\" class=\"fd-dialog__subheader\" barDesign=\"subheader\" [fdCozy]=\"dialogConfig.mobile\">\n <ng-container *ngTemplateOutlet=\"subHeaderTemplate\"></ng-container>\n</div>\n" }]
|
|
403
|
+
}], ctorParameters: function () { return [{ type: DialogConfig, decorators: [{
|
|
404
|
+
type: Optional
|
|
405
|
+
}] }, { type: i0.ChangeDetectorRef }]; } });
|
|
406
|
+
|
|
356
407
|
/** @hidden Returns dialog size based on width
|
|
357
408
|
* @param width - dialog window width
|
|
358
409
|
**/
|
|
@@ -487,11 +538,11 @@ class DialogBase {
|
|
|
487
538
|
}
|
|
488
539
|
}
|
|
489
540
|
}
|
|
490
|
-
DialogBase.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogBase, deps: [{ token: i1.Router }, { token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: i4$1.RtlService }, { token: i4$1.FocusTrapService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
541
|
+
DialogBase.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogBase, deps: [{ token: i1$1.Router }, { token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: i4$1.RtlService }, { token: i4$1.FocusTrapService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
491
542
|
DialogBase.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: DialogBase, host: { listeners: { "keydown": "closeDialogEsc($event)", "mousedown": "closeDialog($event.target)" }, properties: { "attr.dir": "this._dir" } }, ngImport: i0 });
|
|
492
543
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogBase, decorators: [{
|
|
493
544
|
type: Directive
|
|
494
|
-
}], ctorParameters: function () { return [{ type: i1.Router }, { type: i0.ElementRef }, { type: i0.ChangeDetectorRef }, { type: i4$1.RtlService }, { type: i4$1.FocusTrapService }]; }, propDecorators: { _dir: [{
|
|
545
|
+
}], ctorParameters: function () { return [{ type: i1$1.Router }, { type: i0.ElementRef }, { type: i0.ChangeDetectorRef }, { type: i4$1.RtlService }, { type: i4$1.FocusTrapService }]; }, propDecorators: { _dir: [{
|
|
495
546
|
type: HostBinding,
|
|
496
547
|
args: ['attr.dir']
|
|
497
548
|
}], closeDialogEsc: [{
|
|
@@ -655,8 +706,8 @@ class DialogComponent extends DialogBase {
|
|
|
655
706
|
});
|
|
656
707
|
}
|
|
657
708
|
}
|
|
658
|
-
DialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogComponent, deps: [{ token: DialogConfig, optional: true }, { token: DialogRef, optional: true }, { token: i1.Router, optional: true }, { token: i4$1.RtlService, optional: true }, { token: i4$1.FocusTrapService }, { token: i0.ChangeDetectorRef }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
659
|
-
DialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DialogComponent, selector: "fd-dialog", inputs: { class: "class", embeddedDialogRef: ["dialogRef", "embeddedDialogRef"], embeddedDialogConfig: ["dialogConfig", "embeddedDialogConfig"] }, host: { attributes: { "tabindex": "-1" } }, providers: [contentDensityObserverProviders({ alwaysAddModifiers: true })], queries: [{ propertyName: "dialogHeaderConfig", first: true, predicate: DialogHeaderComponent, descendants: true }, { propertyName: "dialogBodyConfig", first: true, predicate: DialogBodyComponent, descendants: true }, { propertyName: "dialogFooterConfig", first: true, predicate: DialogFooterComponent, descendants: true }, { propertyName: "dialogTitle", first: true, predicate: DialogTitleDirective, descendants: true }], viewQueries: [{ propertyName: "dialogWindow", first: true, predicate: ["dialogWindow"], descendants: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<div\n #dialogWindow\n role=\"dialog\"\n tabindex=\"-1\"\n aria-modal=\"true\"\n fdkResize\n cdkTrapFocus\n cdkDrag\n cdkDragBoundary=\".fd-dialog\"\n fd-scrollbar\n [fdkResizeBoundary]=\"elementRef.nativeElement\"\n class=\"fd-dialog__content\"\n [class]=\"dialogConfig.dialogPanelClass\"\n [class.cdk-drag]=\"dialogConfig.draggable\"\n [class.fd-dialog__content--s]=\"dialogPaddingSize === 'sm'\"\n [class.fd-dialog__content--m]=\"dialogPaddingSize === 'md'\"\n [class.fd-dialog__content--l]=\"dialogPaddingSize === 'lg'\"\n [class.fd-dialog__content--xl]=\"dialogPaddingSize === 'xl'\"\n [class.fd-dialog__content--mobile]=\"dialogConfig.mobile || dialogConfig.fullScreen\"\n [class.fd-dialog__content--no-mobile-stretch]=\"dialogConfig.mobileOuterSpacing\"\n [class.fd-dialog__content--draggable-grab]=\"dialogConfig.draggable && !isDragged\"\n [class.fd-dialog__content--draggable-grabbing]=\"dialogConfig.draggable && isDragged\"\n [cdkDragDisabled]=\"!dialogConfig.draggable\"\n [fdkResizeDisabled]=\"!dialogConfig.resizable\"\n [attr.id]=\"dialogConfig.id\"\n [attr.aria-label]=\"dialogConfig.ariaLabel\"\n [attr.aria-labelledby]=\"dialogConfig.ariaLabelledBy\"\n [attr.aria-describedby]=\"dialogConfig.ariaDescribedBy\"\n [attr.aria-modal]=\"dialogConfig.ariaModal\"\n (cdkDragStarted)=\"isDragged = true\"\n (cdkDragEnded)=\"isDragged = false\"\n (onResizeEnd)=\"adjustResponsivePadding()\"\n>\n <span fdkResizeHandle *ngIf=\"dialogConfig.resizable\" class=\"fd-dialog__resize-handle\"></span>\n\n <div cdkDragHandle [cdkDragHandleDisabled]=\"!dialogConfig.draggable\">\n <ng-content select=\"fd-dialog-header\"></ng-content>\n </div>\n\n <ng-content select=\"fd-dialog-body\"></ng-content>\n\n <ng-content select=\"fd-dialog-footer\"></ng-content>\n</div>\n", styles: ["/*!\n * Fundamental Library Styles v0.28.3\n * Copyright (c) 2023 SAP SE or an SAP affiliate company.\n * Licensed under Apache License 2.0 (https://github.com/SAP/fundamental-styles/blob/main/LICENSE)\n */.fd-dialog{-webkit-box-align:center;-ms-flex-align:center;-webkit-box-pack:center;-ms-flex-pack:center;align-items:center;justify-content:center;position:fixed}.fd-dialog,.fd-dialog:before{height:100%;left:0;top:0;width:100%}.fd-dialog:before{background-color:var(--sapBlockLayer_Background);content:\"\";opacity:var(--fdDialog_Background_Opacity);position:absolute}.fd-dialog__content{-webkit-box-shadow:var(--sapContent_Shadow3);border-radius:var(--sapElement_BorderCornerRadius);box-shadow:var(--sapContent_Shadow3);display:flex;flex-direction:column;max-height:calc(100vh - 6%);max-width:calc(100vw - 10%);min-height:7.5rem;min-width:20rem;outline:none;overflow:hidden;position:absolute}.fd-dialog__body{-webkit-box-flex:1;-ms-flex-positive:1;background-color:var(--sapGroup_ContentBackground);flex-grow:1;overflow:auto}.fd-dialog__footer.fd-bar,.fd-dialog__header.fd-bar,.fd-dialog__subheader.fd-bar{flex-shrink:0;padding-left:1rem;padding-right:1rem}.fd-dialog__content--mobile{border-radius:0;height:100vh;max-height:100vh;max-width:100vw;width:100vw}/*!\n .fd-dialog+(--active)\n .fd-dialog__content+(--s, --m, --l, --xl, --draggable-grab, --draggable-grabbing, --mobile, --no-mobile-stretch)\n .fd-dialog__header\n .fd-dialog__title\n .fd-dialog__subheader\n .fd-dialog__body+(--no-vertical-padding, --no-horizontal-padding)\n .fd-dialog__loader\n .fd-dialog__footer\n .fd-dialog__decisive-button\n .fd-dialog__resize-handle\n*/.fd-dialog{-webkit-box-sizing:border-box;border:0;box-sizing:border-box;color:var(--sapTextColor);display:none;font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-weight:400;forced-color-adjust:none;line-height:var(--sapContent_LineHeight);margin:0;padding:0}.fd-dialog:after,.fd-dialog:before{box-sizing:inherit;font-size:inherit}.fd-dialog--active{display:flex}.fd-dialog__content{-webkit-box-sizing:border-box;border:0;box-sizing:border-box;color:var(--sapTextColor);font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-weight:400;forced-color-adjust:none;line-height:var(--sapContent_LineHeight);margin:0;padding:0}.fd-dialog__content:after,.fd-dialog__content:before{box-sizing:inherit;font-size:inherit}.fd-dialog__content--def .fd-dialog__body,.fd-dialog__content--def .fd-dialog__footer.fd-bar,.fd-dialog__content--def .fd-dialog__header.fd-bar,.fd-dialog__content--def .fd-dialog__subheader.fd-bar,.fd-dialog__content--s .fd-dialog__body,.fd-dialog__content--s .fd-dialog__footer.fd-bar,.fd-dialog__content--s .fd-dialog__header.fd-bar,.fd-dialog__content--s .fd-dialog__subheader.fd-bar{padding-left:1rem;padding-right:1rem}.fd-dialog__content--l .fd-dialog__body,.fd-dialog__content--l .fd-dialog__footer.fd-bar,.fd-dialog__content--l .fd-dialog__header.fd-bar,.fd-dialog__content--l .fd-dialog__subheader.fd-bar,.fd-dialog__content--m .fd-dialog__body,.fd-dialog__content--m .fd-dialog__footer.fd-bar,.fd-dialog__content--m .fd-dialog__header.fd-bar,.fd-dialog__content--m .fd-dialog__subheader.fd-bar{padding-left:2rem;padding-right:2rem}.fd-dialog__content--xl .fd-dialog__body,.fd-dialog__content--xl .fd-dialog__footer.fd-bar,.fd-dialog__content--xl .fd-dialog__header.fd-bar,.fd-dialog__content--xl .fd-dialog__subheader.fd-bar{padding-left:3rem;padding-right:3rem}.fd-dialog__content--mobile .fd-dialog__body,.fd-dialog__content--mobile .fd-dialog__footer,.fd-dialog__content--mobile .fd-dialog__header,.fd-dialog__content--mobile .fd-menu__item:first-child,.fd-dialog__content--mobile .fd-menu__item:first-child .fd-menu__link:after,.fd-dialog__content--mobile .fd-menu__item:last-child,.fd-dialog__content--mobile .fd-menu__item:last-child .fd-menu__link:after{border-radius:0}.fd-dialog__content--no-mobile-stretch{border-radius:var(--sapElement_BorderCornerRadius);max-height:calc(100vh - 6%);max-width:calc(100vw - 10%)}.fd-dialog__content--draggable-grab.is-hover .fd-dialog__header,.fd-dialog__content--draggable-grab:hover .fd-dialog__header{cursor:move;cursor:grab}.fd-dialog__content--draggable-grabbing.is-hover .fd-dialog__header,.fd-dialog__content--draggable-grabbing:hover .fd-dialog__header{cursor:move;cursor:grabbing}.fd-dialog__footer.fd-bar .fd-dialog__decisive-button,.fd-dialog__header.fd-bar .fd-dialog__decisive-button{justify-content:center;min-width:4rem}.fd-dialog__body{-webkit-box-sizing:border-box;border:0;border-radius:var(--sapElement_BorderCornerRadius);box-sizing:border-box;color:var(--sapTextColor);font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-weight:400;forced-color-adjust:none;line-height:var(--sapContent_LineHeight);margin:0;padding:1rem 0;position:relative}.fd-dialog__body:after,.fd-dialog__body:before{box-sizing:inherit;font-size:inherit}.fd-dialog__body--no-vertical-padding{padding-bottom:0;padding-top:0}.fd-dialog__body--no-horizontal-padding{padding-left:0;padding-right:0}.fd-dialog__body:not(:first-child){border-top-left-radius:0;border-top-right-radius:0}.fd-dialog__body:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.fd-dialog__loader{-webkit-box-sizing:border-box;border:0;box-sizing:border-box;color:var(--sapTextColor);font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-weight:400;forced-color-adjust:none;line-height:var(--sapContent_LineHeight);margin:1.5rem 0 .5rem;padding:0;text-align:center}.fd-dialog__loader:after,.fd-dialog__loader:before{box-sizing:inherit;font-size:inherit}.fd-dialog__resize-handle{-webkit-box-sizing:border-box;border:0;bottom:-.35rem;box-sizing:border-box;color:var(--sapTextColor);cursor:se-resize;font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-size:1rem;font-weight:400;forced-color-adjust:none;line-height:var(--sapContent_LineHeight);margin:0;overflow:hidden;padding:0;position:absolute;right:.05rem}.fd-dialog__resize-handle:after,.fd-dialog__resize-handle:before{box-sizing:inherit;font-size:inherit}.fd-dialog__resize-handle[dir=rtl],[dir=rtl] .fd-dialog__resize-handle{-webkit-transform:scaleX(-1);cursor:sw-resize;left:.05rem;right:auto;transform:scaleX(-1)}.fd-dialog__resize-handle:after{color:var(--sapButton_Lite_TextColor);content:\"\\e24f\";font-family:SAP-icons;text-align:center;text-decoration:inherit;text-rendering:optimizeLegibility;text-transform:none}.fd-dialog--no-backdrop:not(.fd-dialog--targeted){-webkit-transform:translate(-50%,-50%);left:50%;position:fixed;top:50%;transform:translate(-50%,-50%);z-index:1000}.fd-dialog{z-index:999}.fd-dialog__resize-handle{z-index:1001;bottom:0;overflow:hidden}.fd-dialog__resize-handle:after{margin-bottom:-.125rem;display:block}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i4$1.ResizeDirective, selector: "[fdkResize], [fdResize], [fd-resize]", inputs: ["fdkResizeBoundary", "fdkResizeDisabled", "fdkResizeHandleLocation", "fdkResizeResizeHandleRef"], outputs: ["onResizeStart", "onResizeEnd"] }, { kind: "directive", type: i4$1.ResizeHandleDirective, selector: "[fdkResizeHandle], [fdResizeHandle], [fd-resize-handle]" }, { kind: "directive", type: i6.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i6.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "directive", type: i7.CdkTrapFocus, selector: "[cdkTrapFocus]", inputs: ["cdkTrapFocus", "cdkTrapFocusAutoCapture"], exportAs: ["cdkTrapFocus"] }, { kind: "directive", type: i3$1.ScrollbarDirective, selector: "[fdScrollbar], [fd-scrollbar]", inputs: ["noHorizontalScroll", "noVerticalScroll", "alwaysVisible", "overrideTabindex"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
709
|
+
DialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogComponent, deps: [{ token: DialogConfig, optional: true }, { token: DialogRef, optional: true }, { token: i1$1.Router, optional: true }, { token: i4$1.RtlService, optional: true }, { token: i4$1.FocusTrapService }, { token: i0.ChangeDetectorRef }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
710
|
+
DialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DialogComponent, selector: "fd-dialog", inputs: { class: "class", embeddedDialogRef: ["dialogRef", "embeddedDialogRef"], embeddedDialogConfig: ["dialogConfig", "embeddedDialogConfig"] }, host: { attributes: { "tabindex": "-1" } }, providers: [contentDensityObserverProviders({ alwaysAddModifiers: true })], queries: [{ propertyName: "dialogHeaderConfig", first: true, predicate: DialogHeaderComponent, descendants: true }, { propertyName: "dialogBodyConfig", first: true, predicate: DialogBodyComponent, descendants: true }, { propertyName: "dialogFooterConfig", first: true, predicate: DialogFooterComponent, descendants: true }, { propertyName: "dialogTitle", first: true, predicate: DialogTitleDirective, descendants: true }], viewQueries: [{ propertyName: "dialogWindow", first: true, predicate: ["dialogWindow"], descendants: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<div\n #dialogWindow\n role=\"dialog\"\n tabindex=\"-1\"\n aria-modal=\"true\"\n fdkResize\n cdkTrapFocus\n cdkDrag\n cdkDragBoundary=\".fd-dialog\"\n fd-scrollbar\n [fdkResizeBoundary]=\"elementRef.nativeElement\"\n class=\"fd-dialog__content\"\n [class]=\"dialogConfig.dialogPanelClass\"\n [class.cdk-drag]=\"dialogConfig.draggable\"\n [class.fd-dialog__content--s]=\"dialogPaddingSize === 'sm'\"\n [class.fd-dialog__content--m]=\"dialogPaddingSize === 'md'\"\n [class.fd-dialog__content--l]=\"dialogPaddingSize === 'lg'\"\n [class.fd-dialog__content--xl]=\"dialogPaddingSize === 'xl'\"\n [class.fd-dialog__content--mobile]=\"dialogConfig.mobile || dialogConfig.fullScreen\"\n [class.fd-dialog__content--no-mobile-stretch]=\"dialogConfig.mobileOuterSpacing\"\n [class.fd-dialog__content--draggable-grab]=\"dialogConfig.draggable && !isDragged\"\n [class.fd-dialog__content--draggable-grabbing]=\"dialogConfig.draggable && isDragged\"\n [cdkDragDisabled]=\"!dialogConfig.draggable\"\n [fdkResizeDisabled]=\"!dialogConfig.resizable\"\n [attr.id]=\"dialogConfig.id\"\n [attr.aria-label]=\"dialogConfig.ariaLabel\"\n [attr.aria-labelledby]=\"dialogConfig.ariaLabelledBy\"\n [attr.aria-describedby]=\"dialogConfig.ariaDescribedBy\"\n [attr.aria-modal]=\"dialogConfig.ariaModal\"\n (cdkDragStarted)=\"isDragged = true\"\n (cdkDragEnded)=\"isDragged = false\"\n (onResizeEnd)=\"adjustResponsivePadding()\"\n>\n <span fdkResizeHandle *ngIf=\"dialogConfig.resizable\" class=\"fd-dialog__resize-handle\"></span>\n\n <div cdkDragHandle [cdkDragHandleDisabled]=\"!dialogConfig.draggable\">\n <ng-content select=\"fd-dialog-header\"></ng-content>\n </div>\n\n <ng-content select=\"fd-dialog-body\"></ng-content>\n\n <ng-content select=\"fd-dialog-footer\"></ng-content>\n</div>\n", styles: ["/*!\n * Fundamental Library Styles v0.28.3\n * Copyright (c) 2023 SAP SE or an SAP affiliate company.\n * Licensed under Apache License 2.0 (https://github.com/SAP/fundamental-styles/blob/main/LICENSE)\n */.fd-dialog{-webkit-box-align:center;-ms-flex-align:center;-webkit-box-pack:center;-ms-flex-pack:center;align-items:center;justify-content:center;position:fixed}.fd-dialog,.fd-dialog:before{height:100%;left:0;top:0;width:100%}.fd-dialog:before{background-color:var(--sapBlockLayer_Background);content:\"\";opacity:var(--fdDialog_Background_Opacity);position:absolute}.fd-dialog__content{-webkit-box-shadow:var(--sapContent_Shadow3);border-radius:var(--sapElement_BorderCornerRadius);box-shadow:var(--sapContent_Shadow3);display:flex;flex-direction:column;max-height:calc(100vh - 6%);max-width:calc(100vw - 10%);min-height:7.5rem;min-width:20rem;outline:none;overflow:hidden;position:absolute}.fd-dialog__body{-webkit-box-flex:1;-ms-flex-positive:1;background-color:var(--sapGroup_ContentBackground);flex-grow:1;overflow:auto}.fd-dialog__footer.fd-bar,.fd-dialog__header.fd-bar,.fd-dialog__subheader.fd-bar{flex-shrink:0;padding-left:1rem;padding-right:1rem}.fd-dialog__content--mobile{border-radius:0;height:100vh;max-height:100vh;max-width:100vw;width:100vw}/*!\n .fd-dialog+(--active)\n .fd-dialog__content+(--s, --m, --l, --xl, --draggable-grab, --draggable-grabbing, --mobile, --no-mobile-stretch)\n .fd-dialog__header\n .fd-dialog__title\n .fd-dialog__subheader\n .fd-dialog__body+(--no-vertical-padding, --no-horizontal-padding)\n .fd-dialog__loader\n .fd-dialog__footer\n .fd-dialog__decisive-button\n .fd-dialog__resize-handle\n*/.fd-dialog{-webkit-box-sizing:border-box;border:0;box-sizing:border-box;color:var(--sapTextColor);display:none;font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-weight:400;forced-color-adjust:none;line-height:var(--sapContent_LineHeight);margin:0;padding:0}.fd-dialog:after,.fd-dialog:before{box-sizing:inherit;font-size:inherit}.fd-dialog--active{display:flex}.fd-dialog__content{-webkit-box-sizing:border-box;border:0;box-sizing:border-box;color:var(--sapTextColor);font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-weight:400;forced-color-adjust:none;line-height:var(--sapContent_LineHeight);margin:0;padding:0}.fd-dialog__content:after,.fd-dialog__content:before{box-sizing:inherit;font-size:inherit}.fd-dialog__content--def .fd-dialog__body,.fd-dialog__content--def .fd-dialog__footer.fd-bar,.fd-dialog__content--def .fd-dialog__header.fd-bar,.fd-dialog__content--def .fd-dialog__subheader.fd-bar,.fd-dialog__content--s .fd-dialog__body,.fd-dialog__content--s .fd-dialog__footer.fd-bar,.fd-dialog__content--s .fd-dialog__header.fd-bar,.fd-dialog__content--s .fd-dialog__subheader.fd-bar{padding-left:1rem;padding-right:1rem}.fd-dialog__content--l .fd-dialog__body,.fd-dialog__content--l .fd-dialog__footer.fd-bar,.fd-dialog__content--l .fd-dialog__header.fd-bar,.fd-dialog__content--l .fd-dialog__subheader.fd-bar,.fd-dialog__content--m .fd-dialog__body,.fd-dialog__content--m .fd-dialog__footer.fd-bar,.fd-dialog__content--m .fd-dialog__header.fd-bar,.fd-dialog__content--m .fd-dialog__subheader.fd-bar{padding-left:2rem;padding-right:2rem}.fd-dialog__content--xl .fd-dialog__body,.fd-dialog__content--xl .fd-dialog__footer.fd-bar,.fd-dialog__content--xl .fd-dialog__header.fd-bar,.fd-dialog__content--xl .fd-dialog__subheader.fd-bar{padding-left:3rem;padding-right:3rem}.fd-dialog__content--mobile .fd-dialog__body,.fd-dialog__content--mobile .fd-dialog__footer,.fd-dialog__content--mobile .fd-dialog__header,.fd-dialog__content--mobile .fd-menu__item:first-child,.fd-dialog__content--mobile .fd-menu__item:first-child .fd-menu__link:after,.fd-dialog__content--mobile .fd-menu__item:last-child,.fd-dialog__content--mobile .fd-menu__item:last-child .fd-menu__link:after{border-radius:0}.fd-dialog__content--no-mobile-stretch{border-radius:var(--sapElement_BorderCornerRadius);max-height:calc(100vh - 6%);max-width:calc(100vw - 10%)}.fd-dialog__content--draggable-grab.is-hover .fd-dialog__header,.fd-dialog__content--draggable-grab:hover .fd-dialog__header{cursor:move;cursor:grab}.fd-dialog__content--draggable-grabbing.is-hover .fd-dialog__header,.fd-dialog__content--draggable-grabbing:hover .fd-dialog__header{cursor:move;cursor:grabbing}.fd-dialog__footer.fd-bar .fd-dialog__decisive-button,.fd-dialog__header.fd-bar .fd-dialog__decisive-button{justify-content:center;min-width:4rem}.fd-dialog__body{-webkit-box-sizing:border-box;border:0;border-radius:var(--sapElement_BorderCornerRadius);box-sizing:border-box;color:var(--sapTextColor);font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-weight:400;forced-color-adjust:none;line-height:var(--sapContent_LineHeight);margin:0;padding:1rem 0;position:relative}.fd-dialog__body:after,.fd-dialog__body:before{box-sizing:inherit;font-size:inherit}.fd-dialog__body--no-vertical-padding{padding-bottom:0;padding-top:0}.fd-dialog__body--no-horizontal-padding{padding-left:0;padding-right:0}.fd-dialog__body:not(:first-child){border-top-left-radius:0;border-top-right-radius:0}.fd-dialog__body:not(:last-child){border-bottom-left-radius:0;border-bottom-right-radius:0}.fd-dialog__loader{-webkit-box-sizing:border-box;border:0;box-sizing:border-box;color:var(--sapTextColor);font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-weight:400;forced-color-adjust:none;line-height:var(--sapContent_LineHeight);margin:1.5rem 0 .5rem;padding:0;text-align:center}.fd-dialog__loader:after,.fd-dialog__loader:before{box-sizing:inherit;font-size:inherit}.fd-dialog__resize-handle{-webkit-box-sizing:border-box;border:0;bottom:-.35rem;box-sizing:border-box;color:var(--sapTextColor);cursor:se-resize;font-family:var(--sapFontFamily);font-size:var(--sapFontSize);font-size:1rem;font-weight:400;forced-color-adjust:none;line-height:var(--sapContent_LineHeight);margin:0;overflow:hidden;padding:0;position:absolute;right:.05rem}.fd-dialog__resize-handle:after,.fd-dialog__resize-handle:before{box-sizing:inherit;font-size:inherit}.fd-dialog__resize-handle[dir=rtl],[dir=rtl] .fd-dialog__resize-handle{-webkit-transform:scaleX(-1);cursor:sw-resize;left:.05rem;right:auto;transform:scaleX(-1)}.fd-dialog__resize-handle:after{color:var(--sapButton_Lite_TextColor);content:\"\\e24f\";font-family:SAP-icons;text-align:center;text-decoration:inherit;text-rendering:optimizeLegibility;text-transform:none}.fd-dialog--no-backdrop:not(.fd-dialog--targeted){-webkit-transform:translate(-50%,-50%);left:50%;position:fixed;top:50%;transform:translate(-50%,-50%);z-index:1000}.fd-dialog{z-index:999}.fd-dialog__resize-handle{z-index:1001;bottom:0;overflow:hidden}.fd-dialog__resize-handle:after{margin-bottom:-.125rem;display:block}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i4$1.ResizeDirective, selector: "[fdkResize], [fdResize], [fd-resize]", inputs: ["fdkResizeBoundary", "fdkResizeDisabled", "fdkResizeHandleLocation", "fdkResizeResizeHandleRef"], outputs: ["onResizeStart", "onResizeEnd"] }, { kind: "directive", type: i4$1.ResizeHandleDirective, selector: "[fdkResizeHandle], [fdResizeHandle], [fd-resize-handle]" }, { kind: "directive", type: i6.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i6.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "directive", type: i7.CdkTrapFocus, selector: "[cdkTrapFocus]", inputs: ["cdkTrapFocus", "cdkTrapFocusAutoCapture"], exportAs: ["cdkTrapFocus"] }, { kind: "directive", type: i3.ScrollbarDirective, selector: "[fdScrollbar], [fd-scrollbar]", inputs: ["noHorizontalScroll", "noVerticalScroll", "alwaysVisible", "overrideTabindex"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
660
711
|
__decorate([
|
|
661
712
|
applyCssClass,
|
|
662
713
|
__metadata("design:type", Function),
|
|
@@ -672,7 +723,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
|
|
|
672
723
|
type: Optional
|
|
673
724
|
}] }, { type: DialogRef, decorators: [{
|
|
674
725
|
type: Optional
|
|
675
|
-
}] }, { type: i1.Router, decorators: [{
|
|
726
|
+
}] }, { type: i1$1.Router, decorators: [{
|
|
676
727
|
type: Optional
|
|
677
728
|
}] }, { type: i4$1.RtlService, decorators: [{
|
|
678
729
|
type: Optional
|
|
@@ -701,41 +752,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
|
|
|
701
752
|
args: [DialogTitleDirective]
|
|
702
753
|
}], buildComponentCssClass: [] } });
|
|
703
754
|
|
|
704
|
-
/**
|
|
705
|
-
* Directive that applies fundamental dialog styling to a dialog close button.
|
|
706
|
-
*
|
|
707
|
-
* ```html
|
|
708
|
-
* <button fd-dialog-close-button></button>
|
|
709
|
-
* ```
|
|
710
|
-
*/
|
|
711
|
-
class DialogCloseButtonComponent {
|
|
712
|
-
constructor() {
|
|
713
|
-
/** Displays dialog close button in mobile mode */
|
|
714
|
-
this.mobile = false;
|
|
715
|
-
}
|
|
716
|
-
}
|
|
717
|
-
DialogCloseButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogCloseButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
718
|
-
DialogCloseButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DialogCloseButtonComponent, selector: "[fd-dialog-close-button]", inputs: { mobile: "mobile", title: "title" }, host: { properties: { "attr.aria-label": "\"close\"", "class.fd-button": "true", "class.is-compact": "!mobile", "class.fd-button--transparent": "true", "attr.title": "title" } }, ngImport: i0, template: `<fd-icon glyph="decline"></fd-icon><ng-content></ng-content>`, isInline: true, dependencies: [{ kind: "component", type: i1$1.IconComponent, selector: "fd-icon", inputs: ["glyph", "font", "class", "ariaLabel"] }] });
|
|
719
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogCloseButtonComponent, decorators: [{
|
|
720
|
-
type: Component,
|
|
721
|
-
args: [{
|
|
722
|
-
// eslint-disable-next-line @angular-eslint/component-selector
|
|
723
|
-
selector: '[fd-dialog-close-button]',
|
|
724
|
-
host: {
|
|
725
|
-
'[attr.aria-label]': '"close"',
|
|
726
|
-
'[class.fd-button]': 'true',
|
|
727
|
-
'[class.is-compact]': '!mobile',
|
|
728
|
-
'[class.fd-button--transparent]': 'true',
|
|
729
|
-
'[attr.title]': 'title'
|
|
730
|
-
},
|
|
731
|
-
template: `<fd-icon glyph="decline"></fd-icon><ng-content></ng-content>`
|
|
732
|
-
}]
|
|
733
|
-
}], propDecorators: { mobile: [{
|
|
734
|
-
type: Input
|
|
735
|
-
}], title: [{
|
|
736
|
-
type: Input
|
|
737
|
-
}] } });
|
|
738
|
-
|
|
739
755
|
/** Dialog component used to create the dialog in object based approach */
|
|
740
756
|
class DialogDefaultComponent {
|
|
741
757
|
/** @hidden */
|
|
@@ -767,7 +783,7 @@ class DialogDefaultComponent {
|
|
|
767
783
|
}
|
|
768
784
|
}
|
|
769
785
|
DialogDefaultComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogDefaultComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
770
|
-
DialogDefaultComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DialogDefaultComponent, selector: "fd-dialog-default", ngImport: i0, template: "<fd-dialog>\n <fd-dialog-header>\n <h1 fd-title [id]=\"_defaultDialogContent?.titleId\">{{ _defaultDialogContent?.title }}</h1>\n <button\n fd-dialog-close-button\n *ngIf=\"_defaultDialogContent?.closeButtonCallback\"\n [title]=\"_defaultDialogContent?.closeButtonTitle || ''\"\n (click)=\"_closeButtonClicked()\"\n ></button>\n <ng-container *ngIf=\"_defaultDialogContent?.subHeader\">\n <ng-template fdkTemplate=\"subheader\">\n <ng-container *ngTemplateOutlet=\"_defaultDialogContent!.subHeader!\"></ng-container>\n </ng-template>\n </ng-container>\n </fd-dialog-header>\n\n <fd-dialog-body *ngIf=\"_defaultDialogContent?.content\">\n <ng-container *ngTemplateOutlet=\"_defaultDialogContent?.content!\"></ng-container>\n </fd-dialog-body>\n\n <fd-dialog-footer *ngIf=\"_showFooter()\">\n <fd-button-bar\n *ngIf=\"_defaultDialogContent?.approveButton\"\n fdType=\"emphasized\"\n fdkInitialFocus\n [label]=\"_defaultDialogContent?.approveButton || ''\"\n [fdCozy]=\"_defaultDialogConfiguration.mobile\"\n (click)=\"_approveButtonClicked()\"\n [ariaLabel]=\"_defaultDialogContent?.approveButtonAriaLabel\"\n [id]=\"_defaultDialogContent?.approveButtonId\"\n >\n </fd-button-bar>\n <fd-button-bar\n *ngIf=\"_defaultDialogContent?.cancelButton\"\n [label]=\"_defaultDialogContent?.cancelButton || ''\"\n [fdCozy]=\"_defaultDialogConfiguration.mobile\"\n (click)=\"_cancelButtonClicked()\"\n [ariaLabel]=\"_defaultDialogContent?.closeButtonAriaLabel\"\n [id]=\"_defaultDialogContent?.cancelButtonId\"\n >\n </fd-button-bar>\n </fd-dialog-footer>\n</fd-dialog>\n", dependencies: [{ kind: "component", type: i2.ButtonBarComponent, selector: "fd-button-bar", inputs: ["fullWidth", "fdType", "title", "ariaLabel", "ariaLabelledby", "id"] }, { kind: "directive", type: i3.ContentDensityDirective, selector: "[fdContentDensity]:not([fdCompact]):not([fdCondensed]):not([fdCozy]), [fdCompact]:not([fdContentDensity]):not([fdCondensed]):not([fdCozy]), [fdCondensed]:not([fdContentDensity]):not([fdCompact]):not([fdCozy]), [fdCozy]:not([fdContentDensity]):not([fdCompact]):not([fdCondensed])", inputs: ["fdContentDensity", "fdCompact", "fdCondensed", "fdCozy"], exportAs: ["fdContentDensity"] }, { kind: "component", type: i3$2.TitleComponent, selector: "h1[fd-title], h2[fd-title], h3[fd-title], h4[fd-title], h5[fd-title], h6[fd-title]", inputs: ["headerSize", "wrap"], exportAs: ["fd-title"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i4.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i4$1.TemplateDirective, selector: "[fdkTemplate], [fdTemplate]", inputs: ["fdkTemplate"] }, { kind: "directive", type: i4$1.InitialFocusDirective, selector: "[fdkInitialFocus], [fdInitialFocus], [fd-initial-focus]", inputs: ["fdkInitialFocus", "enabled", "focusLastElement"] }, { kind: "component", type: DialogComponent, selector: "fd-dialog", inputs: ["class", "dialogRef", "dialogConfig"] }, { kind: "component", type: DialogBodyComponent, selector: "fd-dialog-body" }, { kind: "component", type: DialogFooterComponent, selector: "fd-dialog-footer" }, { kind: "component", type: DialogHeaderComponent, selector: "fd-dialog-header" }, { kind: "component", type: DialogCloseButtonComponent, selector: "[fd-dialog-close-button]", inputs: ["mobile", "title"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
786
|
+
DialogDefaultComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DialogDefaultComponent, selector: "fd-dialog-default", ngImport: i0, template: "<fd-dialog>\n <fd-dialog-header>\n <h1 fd-title [id]=\"_defaultDialogContent?.titleId\">{{ _defaultDialogContent?.title }}</h1>\n <button\n fd-dialog-close-button\n *ngIf=\"_defaultDialogContent?.closeButtonCallback\"\n [title]=\"_defaultDialogContent?.closeButtonTitle || ''\"\n (click)=\"_closeButtonClicked()\"\n ></button>\n <ng-container *ngIf=\"_defaultDialogContent?.subHeader\">\n <ng-template fdkTemplate=\"subheader\">\n <ng-container *ngTemplateOutlet=\"_defaultDialogContent!.subHeader!\"></ng-container>\n </ng-template>\n </ng-container>\n </fd-dialog-header>\n\n <fd-dialog-body *ngIf=\"_defaultDialogContent?.content\">\n <ng-container *ngTemplateOutlet=\"_defaultDialogContent?.content!\"></ng-container>\n </fd-dialog-body>\n\n <fd-dialog-footer *ngIf=\"_showFooter()\">\n <fd-button-bar\n *ngIf=\"_defaultDialogContent?.approveButton\"\n fdType=\"emphasized\"\n fdkInitialFocus\n [label]=\"_defaultDialogContent?.approveButton || ''\"\n [fdCozy]=\"_defaultDialogConfiguration.mobile\"\n (click)=\"_approveButtonClicked()\"\n [ariaLabel]=\"_defaultDialogContent?.approveButtonAriaLabel\"\n [id]=\"_defaultDialogContent?.approveButtonId\"\n >\n </fd-button-bar>\n <fd-button-bar\n *ngIf=\"_defaultDialogContent?.cancelButton\"\n [label]=\"_defaultDialogContent?.cancelButton || ''\"\n [fdCozy]=\"_defaultDialogConfiguration.mobile\"\n (click)=\"_cancelButtonClicked()\"\n [ariaLabel]=\"_defaultDialogContent?.closeButtonAriaLabel\"\n [id]=\"_defaultDialogContent?.cancelButtonId\"\n >\n </fd-button-bar>\n </fd-dialog-footer>\n</fd-dialog>\n", dependencies: [{ kind: "component", type: i2.ButtonBarComponent, selector: "fd-button-bar", inputs: ["fullWidth", "fdType", "title", "ariaLabel", "ariaLabelledby", "id"] }, { kind: "directive", type: i3$1.ContentDensityDirective, selector: "[fdContentDensity]:not([fdCompact]):not([fdCondensed]):not([fdCozy]), [fdCompact]:not([fdContentDensity]):not([fdCondensed]):not([fdCozy]), [fdCondensed]:not([fdContentDensity]):not([fdCompact]):not([fdCozy]), [fdCozy]:not([fdContentDensity]):not([fdCompact]):not([fdCondensed])", inputs: ["fdContentDensity", "fdCompact", "fdCondensed", "fdCozy"], exportAs: ["fdContentDensity"] }, { kind: "component", type: i3$2.TitleComponent, selector: "h1[fd-title], h2[fd-title], h3[fd-title], h4[fd-title], h5[fd-title], h6[fd-title]", inputs: ["headerSize", "wrap"], exportAs: ["fd-title"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i4.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i4$1.TemplateDirective, selector: "[fdkTemplate], [fdTemplate]", inputs: ["fdkTemplate"] }, { kind: "directive", type: i4$1.InitialFocusDirective, selector: "[fdkInitialFocus], [fdInitialFocus], [fd-initial-focus]", inputs: ["fdkInitialFocus", "enabled", "focusLastElement"] }, { kind: "component", type: DialogComponent, selector: "fd-dialog", inputs: ["class", "dialogRef", "dialogConfig"] }, { kind: "component", type: DialogBodyComponent, selector: "fd-dialog-body" }, { kind: "component", type: DialogFooterComponent, selector: "fd-dialog-footer" }, { kind: "component", type: DialogHeaderComponent, selector: "fd-dialog-header" }, { kind: "component", type: DialogCloseButtonComponent, selector: "[fd-dialog-close-button]", inputs: ["mobile", "title"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
771
787
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogDefaultComponent, decorators: [{
|
|
772
788
|
type: Component,
|
|
773
789
|
args: [{ selector: 'fd-dialog-default', changeDetection: ChangeDetectionStrategy.OnPush, template: "<fd-dialog>\n <fd-dialog-header>\n <h1 fd-title [id]=\"_defaultDialogContent?.titleId\">{{ _defaultDialogContent?.title }}</h1>\n <button\n fd-dialog-close-button\n *ngIf=\"_defaultDialogContent?.closeButtonCallback\"\n [title]=\"_defaultDialogContent?.closeButtonTitle || ''\"\n (click)=\"_closeButtonClicked()\"\n ></button>\n <ng-container *ngIf=\"_defaultDialogContent?.subHeader\">\n <ng-template fdkTemplate=\"subheader\">\n <ng-container *ngTemplateOutlet=\"_defaultDialogContent!.subHeader!\"></ng-container>\n </ng-template>\n </ng-container>\n </fd-dialog-header>\n\n <fd-dialog-body *ngIf=\"_defaultDialogContent?.content\">\n <ng-container *ngTemplateOutlet=\"_defaultDialogContent?.content!\"></ng-container>\n </fd-dialog-body>\n\n <fd-dialog-footer *ngIf=\"_showFooter()\">\n <fd-button-bar\n *ngIf=\"_defaultDialogContent?.approveButton\"\n fdType=\"emphasized\"\n fdkInitialFocus\n [label]=\"_defaultDialogContent?.approveButton || ''\"\n [fdCozy]=\"_defaultDialogConfiguration.mobile\"\n (click)=\"_approveButtonClicked()\"\n [ariaLabel]=\"_defaultDialogContent?.approveButtonAriaLabel\"\n [id]=\"_defaultDialogContent?.approveButtonId\"\n >\n </fd-button-bar>\n <fd-button-bar\n *ngIf=\"_defaultDialogContent?.cancelButton\"\n [label]=\"_defaultDialogContent?.cancelButton || ''\"\n [fdCozy]=\"_defaultDialogConfiguration.mobile\"\n (click)=\"_cancelButtonClicked()\"\n [ariaLabel]=\"_defaultDialogContent?.closeButtonAriaLabel\"\n [id]=\"_defaultDialogContent?.cancelButtonId\"\n >\n </fd-button-bar>\n </fd-dialog-footer>\n</fd-dialog>\n" }]
|
|
@@ -800,10 +816,10 @@ class DialogContainerComponent extends DynamicComponentContainer {
|
|
|
800
816
|
this.buildComponentCssClass();
|
|
801
817
|
}
|
|
802
818
|
/** @hidden */
|
|
803
|
-
constructor(dialogConfig,
|
|
819
|
+
constructor(dialogConfig, ref, _destroy$, elementRef, changeDetectorRef, injector) {
|
|
804
820
|
super(elementRef, injector, changeDetectorRef);
|
|
805
821
|
this.dialogConfig = dialogConfig;
|
|
806
|
-
this.
|
|
822
|
+
this.ref = ref;
|
|
807
823
|
this._destroy$ = _destroy$;
|
|
808
824
|
/** The state of the Dialog animations. */
|
|
809
825
|
this._animationState = 'void';
|
|
@@ -811,6 +827,18 @@ class DialogContainerComponent extends DynamicComponentContainer {
|
|
|
811
827
|
this._class = '';
|
|
812
828
|
}
|
|
813
829
|
/** @hidden */
|
|
830
|
+
buildComponentCssClass() {
|
|
831
|
+
return [this.dialogConfig.containerClass ? this.dialogConfig.containerClass : '', this._class];
|
|
832
|
+
}
|
|
833
|
+
/** Handle end of animations, updating the state of the Message Toast. */
|
|
834
|
+
onAnimationEnd(event) {
|
|
835
|
+
const { toState } = event;
|
|
836
|
+
if (toState === 'hidden') {
|
|
837
|
+
this.ref._endClose$.next();
|
|
838
|
+
this.ref._endClose$.complete();
|
|
839
|
+
}
|
|
840
|
+
}
|
|
841
|
+
/** @hidden */
|
|
814
842
|
ngAfterViewInit() {
|
|
815
843
|
setTimeout(() => {
|
|
816
844
|
this._loadContent();
|
|
@@ -824,15 +852,11 @@ class DialogContainerComponent extends DynamicComponentContainer {
|
|
|
824
852
|
}
|
|
825
853
|
}
|
|
826
854
|
/** @hidden */
|
|
827
|
-
buildComponentCssClass() {
|
|
828
|
-
return [this.dialogConfig.containerClass ? this.dialogConfig.containerClass : '', this._class];
|
|
829
|
-
}
|
|
830
|
-
/** @hidden */
|
|
831
855
|
_attached(event) {
|
|
832
|
-
if (event instanceof
|
|
856
|
+
if (event instanceof ComponentRef) {
|
|
833
857
|
event.changeDetectorRef.markForCheck();
|
|
834
858
|
}
|
|
835
|
-
else if (event instanceof
|
|
859
|
+
else if (event instanceof EmbeddedViewRef) {
|
|
836
860
|
event.markForCheck();
|
|
837
861
|
}
|
|
838
862
|
}
|
|
@@ -852,7 +876,7 @@ class DialogContainerComponent extends DynamicComponentContainer {
|
|
|
852
876
|
}
|
|
853
877
|
/** @hidden Returns context for embedded template*/
|
|
854
878
|
_templateContext() {
|
|
855
|
-
return { $implicit: this.
|
|
879
|
+
return { $implicit: this.ref, dialogConfig: this.dialogConfig };
|
|
856
880
|
}
|
|
857
881
|
/** @hidden Load Dialog component from passed object */
|
|
858
882
|
_createFromDefaultDialog(config) {
|
|
@@ -861,14 +885,6 @@ class DialogContainerComponent extends DynamicComponentContainer {
|
|
|
861
885
|
instance._defaultDialogContent = config;
|
|
862
886
|
instance._defaultDialogConfiguration = this.dialogConfig;
|
|
863
887
|
}
|
|
864
|
-
/** Handle end of animations, updating the state of the Message Toast. */
|
|
865
|
-
onAnimationEnd(event) {
|
|
866
|
-
const { toState } = event;
|
|
867
|
-
if (toState === 'hidden') {
|
|
868
|
-
this._dialogRef._endClose$.next();
|
|
869
|
-
this._dialogRef._endClose$.complete();
|
|
870
|
-
}
|
|
871
|
-
}
|
|
872
888
|
/**
|
|
873
889
|
* @hidden
|
|
874
890
|
* We need to wait until animation plays, and then send signal to the service to destroy the component.
|
|
@@ -878,7 +894,7 @@ class DialogContainerComponent extends DynamicComponentContainer {
|
|
|
878
894
|
this._animationState = 'hidden';
|
|
879
895
|
this._cdr.detectChanges();
|
|
880
896
|
};
|
|
881
|
-
this.
|
|
897
|
+
this.ref.afterClosed.pipe(takeUntil(this._destroy$)).subscribe({
|
|
882
898
|
next: () => callback(),
|
|
883
899
|
error: () => callback()
|
|
884
900
|
});
|
|
@@ -908,6 +924,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
|
|
|
908
924
|
args: ['@state.done', ['$event']]
|
|
909
925
|
}] } });
|
|
910
926
|
|
|
927
|
+
/* eslint-disable @typescript-eslint/member-ordering */
|
|
911
928
|
/** Service used to dynamically generate a dialog. */
|
|
912
929
|
class DialogBaseService {
|
|
913
930
|
constructor() {
|
|
@@ -924,8 +941,12 @@ class DialogBaseService {
|
|
|
924
941
|
return this._dialogs && this._dialogs.length > 0;
|
|
925
942
|
}
|
|
926
943
|
/** Dismisses all currently open dialogs. */
|
|
927
|
-
dismissAll() {
|
|
928
|
-
this._dialogs.forEach((item) =>
|
|
944
|
+
dismissAll(reason) {
|
|
945
|
+
this._dialogs.forEach((item) => {
|
|
946
|
+
item.instance.ref.dismiss(reason);
|
|
947
|
+
item.destroy();
|
|
948
|
+
});
|
|
949
|
+
this._dialogs = [];
|
|
929
950
|
}
|
|
930
951
|
/** @hidden */
|
|
931
952
|
ngOnDestroy() {
|
|
@@ -1016,22 +1037,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
|
|
|
1016
1037
|
type: Optional
|
|
1017
1038
|
}] }, { type: i0.Injector }, { type: i2$1.Overlay }]; } });
|
|
1018
1039
|
|
|
1019
|
-
/**
|
|
1020
|
-
* @deprecated
|
|
1021
|
-
* Consider using `fd-button-bar`
|
|
1022
|
-
*/
|
|
1023
|
-
class DialogFooterButtonComponent extends BarElementDirective {
|
|
1024
|
-
}
|
|
1025
|
-
DialogFooterButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogFooterButtonComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1026
|
-
DialogFooterButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DialogFooterButtonComponent, selector: "fd-dialog-footer-button", usesInheritance: true, ngImport: i0, template: '<ng-content></ng-content>', isInline: true });
|
|
1027
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DialogFooterButtonComponent, decorators: [{
|
|
1028
|
-
type: Component,
|
|
1029
|
-
args: [{
|
|
1030
|
-
selector: 'fd-dialog-footer-button',
|
|
1031
|
-
template: '<ng-content></ng-content>'
|
|
1032
|
-
}]
|
|
1033
|
-
}] });
|
|
1034
|
-
|
|
1035
1040
|
/**
|
|
1036
1041
|
* @deprecated
|
|
1037
1042
|
* Consider using `fd-button-bar`
|
|
@@ -1137,18 +1142,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
|
|
|
1137
1142
|
}]
|
|
1138
1143
|
}] });
|
|
1139
1144
|
|
|
1140
|
-
/**
|
|
1141
|
-
* Represents the positioning of the dialog on the screen.
|
|
1142
|
-
*/
|
|
1143
|
-
class DialogPosition {
|
|
1144
|
-
}
|
|
1145
|
-
|
|
1146
1145
|
class DialogContentBase {
|
|
1147
1146
|
}
|
|
1148
1147
|
|
|
1149
1148
|
class DialogDefaultContent extends DialogContentBase {
|
|
1150
1149
|
}
|
|
1151
1150
|
|
|
1151
|
+
/**
|
|
1152
|
+
* Represents the positioning of the dialog on the screen.
|
|
1153
|
+
*/
|
|
1154
|
+
class DialogPosition {
|
|
1155
|
+
}
|
|
1156
|
+
|
|
1152
1157
|
class DialogOverlayContainer extends OverlayContainer {
|
|
1153
1158
|
/**
|
|
1154
1159
|
* This method returns the overlay container element. It will lazily
|