@skyux/modals 10.0.0-alpha.2 → 10.0.0-alpha.4
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/documentation.json +1432 -1062
- package/esm2022/index.mjs +1 -1
- package/esm2022/lib/modules/confirm/confirm-instance.mjs +8 -6
- package/esm2022/lib/modules/confirm/confirm-service-interface.mjs +2 -0
- package/esm2022/lib/modules/confirm/confirm.component.mjs +61 -37
- package/esm2022/lib/modules/confirm/confirm.module.mjs +4 -4
- package/esm2022/lib/modules/confirm/confirm.service.mjs +10 -16
- package/esm2022/lib/modules/modal/modal-adapter.service.mjs +3 -3
- package/esm2022/lib/modules/modal/modal-component-adapter.service.mjs +3 -3
- package/esm2022/lib/modules/modal/modal-configuration.mjs +3 -3
- package/esm2022/lib/modules/modal/modal-content.component.mjs +3 -3
- package/esm2022/lib/modules/modal/modal-errors.service.mjs +3 -3
- package/esm2022/lib/modules/modal/modal-footer.component.mjs +3 -3
- package/esm2022/lib/modules/modal/modal-header.component.mjs +3 -3
- package/esm2022/lib/modules/modal/modal-host-context.mjs +3 -3
- package/esm2022/lib/modules/modal/modal-host.component.mjs +3 -3
- package/esm2022/lib/modules/modal/modal-host.service.mjs +3 -3
- package/esm2022/lib/modules/modal/modal-is-dirty.directive.mjs +3 -3
- package/esm2022/lib/modules/modal/modal-scroll-shadow.directive.mjs +3 -3
- package/esm2022/lib/modules/modal/modal.component.mjs +6 -6
- package/esm2022/lib/modules/modal/modal.module.mjs +4 -4
- package/esm2022/lib/modules/modal/modal.service.mjs +6 -6
- package/esm2022/lib/modules/shared/sky-modals-resources.module.mjs +4 -4
- package/esm2022/testing/confirm/confirm-testing.controller.mjs +7 -0
- package/esm2022/testing/confirm/confirm-testing.module.mjs +18 -0
- package/esm2022/testing/confirm/confirm-testing.service.mjs +57 -0
- package/esm2022/testing/confirm/provide-confirm-testing.mjs +20 -0
- package/esm2022/testing/public-api.mjs +3 -1
- package/fesm2022/skyux-modals-testing.mjs +98 -2
- package/fesm2022/skyux-modals-testing.mjs.map +1 -1
- package/fesm2022/skyux-modals.mjs +268 -249
- package/fesm2022/skyux-modals.mjs.map +1 -1
- package/index.d.ts +1 -0
- package/lib/modules/confirm/confirm-instance.d.ts +4 -3
- package/lib/modules/confirm/confirm-service-interface.d.ts +8 -0
- package/lib/modules/confirm/confirm.component.d.ts +11 -13
- package/lib/modules/confirm/confirm.service.d.ts +2 -1
- package/package.json +9 -9
- package/testing/confirm/confirm-testing.controller.d.ts +28 -0
- package/testing/confirm/confirm-testing.module.d.ts +9 -0
- package/testing/confirm/confirm-testing.service.d.ts +14 -0
- package/testing/confirm/provide-confirm-testing.d.ts +5 -0
- package/testing/public-api.d.ts +2 -0
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { ReplaySubject,
|
|
1
|
+
import { ReplaySubject, Subject, BehaviorSubject } from 'rxjs';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
3
|
import { NgModule, InjectionToken, Component, ViewEncapsulation, Injectable, EventEmitter, inject, ElementRef, NgZone, Directive, Output, HostListener, ChangeDetectorRef, HostBinding, Input, ViewChild, Inject, EnvironmentInjector, ViewContainerRef } from '@angular/core';
|
|
4
4
|
import * as i1$1 from '@angular/common';
|
|
5
5
|
import { CommonModule } from '@angular/common';
|
|
6
6
|
import * as i1 from '@skyux/core';
|
|
7
|
-
import { SkyMutationObserverService, SkyCoreAdapterService, SkyDockService, SkyLiveAnnouncerService, SkyResizeObserverMediaQueryService, SkyAppWindowRef, SkyDockLocation, SkyIdModule, SkyDynamicComponentService, SkyMediaQueryService, SKY_STACKING_CONTEXT, SkyTrimModule } from '@skyux/core';
|
|
8
|
-
import * as
|
|
7
|
+
import { SkyMutationObserverService, SkyCoreAdapterService, SkyDockService, SkyLiveAnnouncerService, SkyResizeObserverMediaQueryService, SkyAppWindowRef, SkyDockLocation, SkyIdModule, SkyIdService, SkyDynamicComponentService, SkyMediaQueryService, SKY_STACKING_CONTEXT, SkyTrimModule } from '@skyux/core';
|
|
8
|
+
import * as i4 from '@skyux/i18n';
|
|
9
|
+
import { SkyLibResourcesService, getLibStringForLocale, SkyI18nModule, SKY_LIB_RESOURCES_PROVIDERS } from '@skyux/i18n';
|
|
10
|
+
import * as i3 from '@skyux/theme';
|
|
9
11
|
import { SkyThemeService, SkyTheme, SkyThemeModule } from '@skyux/theme';
|
|
10
|
-
import { takeUntil,
|
|
12
|
+
import { takeUntil, takeWhile } from 'rxjs/operators';
|
|
11
13
|
import * as i2 from '@skyux/indicators';
|
|
12
14
|
import { SkyIconModule, SkyStatusIndicatorModule } from '@skyux/indicators';
|
|
13
|
-
import * as i2$1 from '@skyux/i18n';
|
|
14
|
-
import { SkyLibResourcesService, getLibStringForLocale, SkyI18nModule, SKY_LIB_RESOURCES_PROVIDERS } from '@skyux/i18n';
|
|
15
15
|
import { Router, NavigationStart, RouterModule } from '@angular/router';
|
|
16
16
|
|
|
17
17
|
class SkyConfirmInstance {
|
|
@@ -21,15 +21,17 @@ class SkyConfirmInstance {
|
|
|
21
21
|
* users select. It returns the `'cancel'` action when users press the <kbd>Escape</kbd> key.
|
|
22
22
|
*/
|
|
23
23
|
get closed() {
|
|
24
|
-
return this.#
|
|
24
|
+
return this.#closedObs;
|
|
25
25
|
}
|
|
26
26
|
#closed = new ReplaySubject();
|
|
27
|
+
#closedObs = this.#closed.asObservable();
|
|
27
28
|
/**
|
|
28
|
-
*
|
|
29
|
-
* @
|
|
29
|
+
* Closes the confirm instance.
|
|
30
|
+
* @param args Specifies an object to emit to subscribers of the `closed` event
|
|
31
|
+
* of the confirm instance.
|
|
30
32
|
*/
|
|
31
|
-
|
|
32
|
-
this.#closed.next(
|
|
33
|
+
close(args) {
|
|
34
|
+
this.#closed.next(args);
|
|
33
35
|
this.#closed.complete();
|
|
34
36
|
}
|
|
35
37
|
}
|
|
@@ -62,11 +64,11 @@ var SkyConfirmType;
|
|
|
62
64
|
* @deprecated The `SkyConfirmModule` is no longer needed and can be removed from your application.
|
|
63
65
|
*/
|
|
64
66
|
class SkyConfirmModule {
|
|
65
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
66
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.
|
|
67
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.
|
|
67
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyConfirmModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
68
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.2.4", ngImport: i0, type: SkyConfirmModule }); }
|
|
69
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyConfirmModule }); }
|
|
68
70
|
}
|
|
69
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
71
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyConfirmModule, decorators: [{
|
|
70
72
|
type: NgModule,
|
|
71
73
|
args: [{}]
|
|
72
74
|
}] });
|
|
@@ -80,14 +82,151 @@ const SKY_CONFIRM_CONFIG = new InjectionToken('SkyConfirmConfig');
|
|
|
80
82
|
* Specifies content to display in the modal's body.
|
|
81
83
|
*/
|
|
82
84
|
class SkyModalContentComponent {
|
|
83
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
84
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
85
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
86
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.2.4", type: SkyModalContentComponent, isStandalone: true, selector: "sky-modal-content", ngImport: i0, template: "<ng-content />\n", styles: ["sky-modal-content{display:block;min-height:100%}.sky-theme-modern sky-modal-content{padding:10px 30px 30px}\n"], encapsulation: i0.ViewEncapsulation.None }); }
|
|
85
87
|
}
|
|
86
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
88
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalContentComponent, decorators: [{
|
|
87
89
|
type: Component,
|
|
88
90
|
args: [{ standalone: true, selector: 'sky-modal-content', encapsulation: ViewEncapsulation.None, template: "<ng-content />\n", styles: ["sky-modal-content{display:block;min-height:100%}.sky-theme-modern sky-modal-content{padding:10px 30px 30px}\n"] }]
|
|
89
91
|
}] });
|
|
90
92
|
|
|
93
|
+
/**
|
|
94
|
+
* Properties about the modal close action and a method to close the modal.
|
|
95
|
+
*/
|
|
96
|
+
class SkyModalBeforeCloseHandler {
|
|
97
|
+
constructor(closeModal, closeArgs) {
|
|
98
|
+
this.closeArgs = closeArgs;
|
|
99
|
+
this.closeModal = closeModal;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
/**
|
|
104
|
+
* Contains an object with the data passed from users when
|
|
105
|
+
* a modal is closed and the reason that the modal was closed.
|
|
106
|
+
*/
|
|
107
|
+
class SkyModalCloseArgs {
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
class SkyModalInstance {
|
|
111
|
+
/**
|
|
112
|
+
* An event that the modal instance emits when it is about to close.
|
|
113
|
+
* It emits a `SkyModalBeforeCloseHandler` object with a `closeModal` method
|
|
114
|
+
* that closes the modal. If a subscription exists for this event,
|
|
115
|
+
* the modal does not close until the subscriber calls the `closeModal` method.
|
|
116
|
+
*/
|
|
117
|
+
get beforeClose() {
|
|
118
|
+
return this.#_beforeClose;
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* An event that the modal instance emits when it closes.
|
|
122
|
+
* It emits a `SkyModalCloseArgs` object with a `data` property that includes
|
|
123
|
+
* data passed from users on close or save and a `reason` property that indicates
|
|
124
|
+
* whether the modal was saved or closed without saving.
|
|
125
|
+
* The `reason` property accepts any string value.
|
|
126
|
+
* Common examples include `"cancel"`, `"close"`, and `"save"`.
|
|
127
|
+
*/
|
|
128
|
+
get closed() {
|
|
129
|
+
return this.#_closed;
|
|
130
|
+
}
|
|
131
|
+
/**
|
|
132
|
+
* An event that the modal instance emits when users click
|
|
133
|
+
* the <i class="fa fa-question-circle" aria-hidden="true"></i> button.
|
|
134
|
+
* If a `helpKey` parameter was specified, the `helpOpened` event broadcasts the `helpKey`.
|
|
135
|
+
*/
|
|
136
|
+
get helpOpened() {
|
|
137
|
+
return this.#_helpOpened;
|
|
138
|
+
}
|
|
139
|
+
/**
|
|
140
|
+
* Sets the component adapter for the instance. This is used internally for actions such as scrolling the content.
|
|
141
|
+
* @internal
|
|
142
|
+
*/
|
|
143
|
+
set adapter(value) {
|
|
144
|
+
this.#adapter = value;
|
|
145
|
+
}
|
|
146
|
+
/**
|
|
147
|
+
* Sets the component ref for the instance. This is used to extract the component instance for the public API and the element ref for internal use.
|
|
148
|
+
* @internal
|
|
149
|
+
*/
|
|
150
|
+
set componentRef(value) {
|
|
151
|
+
this.componentInstance = value.instance;
|
|
152
|
+
this.#elementRef = value.location;
|
|
153
|
+
}
|
|
154
|
+
#_beforeClose = new Subject();
|
|
155
|
+
#_closed = new Subject();
|
|
156
|
+
#_helpOpened = new Subject();
|
|
157
|
+
#adapter;
|
|
158
|
+
#elementRef;
|
|
159
|
+
/**
|
|
160
|
+
* Closes the modal instance.
|
|
161
|
+
* @param result Specifies an object to emit to subscribers of the `closed` event of the
|
|
162
|
+
* modal instance. The `SkyModalInstance` provider can be injected into a component's constructor
|
|
163
|
+
* so that this `close` function can be called from a button in the `sky-modal-footer`.
|
|
164
|
+
* @param reason Specifies the reason for the modal closing, with the default reason of `"close"`.
|
|
165
|
+
* @param ignoreBeforeClose Indicates whether to ignore the modal instance's `beforeClose` event.
|
|
166
|
+
*/
|
|
167
|
+
close(result, reason, ignoreBeforeClose) {
|
|
168
|
+
if (reason === undefined) {
|
|
169
|
+
reason = 'close';
|
|
170
|
+
}
|
|
171
|
+
this.#closeModal(reason, result, ignoreBeforeClose);
|
|
172
|
+
}
|
|
173
|
+
/**
|
|
174
|
+
* Closes the modal instance with `reason="cancel"`.
|
|
175
|
+
* @param result Specifies an object to emit to subscribers of the `closed` event of the modal
|
|
176
|
+
* instance. The `SkyModalInstance` provider can be injected into a component's constructor so
|
|
177
|
+
* that this cancel function can be called from a button in the `sky-modal-footer`.
|
|
178
|
+
*/
|
|
179
|
+
cancel(result) {
|
|
180
|
+
this.#closeModal('cancel', result);
|
|
181
|
+
}
|
|
182
|
+
/**
|
|
183
|
+
* Closes the modal instance with `reason="save"`.
|
|
184
|
+
* @param result Specifies an object to emit to subscribers of the `closed` event of the modal
|
|
185
|
+
* instance. The `SkyModalInstance` provider can be injected into a component's constructor so
|
|
186
|
+
* that this `save` function can be called from a button in `the sky-modal-footer`.
|
|
187
|
+
*/
|
|
188
|
+
save(result) {
|
|
189
|
+
this.#closeModal('save', result);
|
|
190
|
+
}
|
|
191
|
+
/**
|
|
192
|
+
* Scrolls the modal content area to the top of its scrollable area.
|
|
193
|
+
*/
|
|
194
|
+
scrollContentToTop() {
|
|
195
|
+
if (this.#adapter && this.#elementRef) {
|
|
196
|
+
this.#adapter.scrollContentToTop(this.#elementRef);
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
/**
|
|
200
|
+
* Triggers the `helpOpened` event that broadcasts a `helpKey` parameter to open
|
|
201
|
+
* when users click the <i class="fa fa-question-circle" aria-hidden="true"></i> button.
|
|
202
|
+
* @param helpKey Specifies a string to emit to subscribers of
|
|
203
|
+
* the modal instance's `helpOpened` event. Consumers can inject the `SkyModalInstance` provider
|
|
204
|
+
* into a component's constructor to call the `openHelp` function in the modal template.
|
|
205
|
+
*/
|
|
206
|
+
openHelp(helpKey) {
|
|
207
|
+
this.#_helpOpened.next(helpKey);
|
|
208
|
+
}
|
|
209
|
+
#closeModal(type, result, ignoreBeforeClose = false) {
|
|
210
|
+
const args = new SkyModalCloseArgs();
|
|
211
|
+
args.reason = type;
|
|
212
|
+
args.data = result;
|
|
213
|
+
if (this.#_beforeClose.observers.length === 0 || ignoreBeforeClose) {
|
|
214
|
+
this.#notifyClosed(args);
|
|
215
|
+
}
|
|
216
|
+
else {
|
|
217
|
+
this.#_beforeClose.next(new SkyModalBeforeCloseHandler(() => {
|
|
218
|
+
this.#notifyClosed(args);
|
|
219
|
+
}, args));
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
#notifyClosed(args) {
|
|
223
|
+
this.#_closed.next(args);
|
|
224
|
+
this.#_closed.complete();
|
|
225
|
+
this.#_beforeClose.complete();
|
|
226
|
+
this.#_helpOpened.complete();
|
|
227
|
+
}
|
|
228
|
+
}
|
|
229
|
+
|
|
91
230
|
/* istanbul ignore file */
|
|
92
231
|
/**
|
|
93
232
|
* NOTICE: DO NOT MODIFY THIS FILE!
|
|
@@ -124,9 +263,9 @@ class SkyModalsResourcesProvider {
|
|
|
124
263
|
* Import into any component library module that needs to use resource strings.
|
|
125
264
|
*/
|
|
126
265
|
class SkyModalsResourcesModule {
|
|
127
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
128
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.
|
|
129
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.
|
|
266
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalsResourcesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
267
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.2.4", ngImport: i0, type: SkyModalsResourcesModule, exports: [SkyI18nModule] }); }
|
|
268
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalsResourcesModule, providers: [
|
|
130
269
|
{
|
|
131
270
|
provide: SKY_LIB_RESOURCES_PROVIDERS,
|
|
132
271
|
useClass: SkyModalsResourcesProvider,
|
|
@@ -134,7 +273,7 @@ class SkyModalsResourcesModule {
|
|
|
134
273
|
},
|
|
135
274
|
], imports: [SkyI18nModule] }); }
|
|
136
275
|
}
|
|
137
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
276
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalsResourcesModule, decorators: [{
|
|
138
277
|
type: NgModule,
|
|
139
278
|
args: [{
|
|
140
279
|
exports: [SkyI18nModule],
|
|
@@ -239,10 +378,10 @@ class SkyModalComponentAdapterService {
|
|
|
239
378
|
fullPageModalEl.style.height = fullPageModalHeight;
|
|
240
379
|
fullPageModalEl.style.maxHeight = fullPageModalHeight;
|
|
241
380
|
}
|
|
242
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
243
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
381
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalComponentAdapterService, deps: [{ token: i1.SkyCoreAdapterService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
382
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalComponentAdapterService }); }
|
|
244
383
|
}
|
|
245
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
384
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalComponentAdapterService, decorators: [{
|
|
246
385
|
type: Injectable
|
|
247
386
|
}], ctorParameters: () => [{ type: i1.SkyCoreAdapterService }] });
|
|
248
387
|
|
|
@@ -253,10 +392,10 @@ class SkyModalConfiguration {
|
|
|
253
392
|
constructor() {
|
|
254
393
|
this.size = 'medium';
|
|
255
394
|
}
|
|
256
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
257
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
395
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalConfiguration, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
396
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalConfiguration }); }
|
|
258
397
|
}
|
|
259
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
398
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalConfiguration, decorators: [{
|
|
260
399
|
type: Injectable
|
|
261
400
|
}], ctorParameters: () => [] });
|
|
262
401
|
|
|
@@ -271,10 +410,10 @@ class SkyModalErrorsService {
|
|
|
271
410
|
updateErrors(value) {
|
|
272
411
|
this.#formErrors.next(value);
|
|
273
412
|
}
|
|
274
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
275
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
413
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalErrorsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
414
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalErrorsService }); }
|
|
276
415
|
}
|
|
277
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
416
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalErrorsService, decorators: [{
|
|
278
417
|
type: Injectable
|
|
279
418
|
}], ctorParameters: () => [] });
|
|
280
419
|
|
|
@@ -327,10 +466,10 @@ class SkyModalHostService {
|
|
|
327
466
|
return currentMaxZIndex + 10;
|
|
328
467
|
}
|
|
329
468
|
}
|
|
330
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
331
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
469
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalHostService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
470
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalHostService, providedIn: 'root' }); }
|
|
332
471
|
}
|
|
333
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
472
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalHostService, decorators: [{
|
|
334
473
|
type: Injectable,
|
|
335
474
|
args: [{
|
|
336
475
|
providedIn: 'root',
|
|
@@ -439,10 +578,10 @@ class SkyModalScrollShadowDirective {
|
|
|
439
578
|
this.#currentShadow = shadow;
|
|
440
579
|
}
|
|
441
580
|
}
|
|
442
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
443
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.
|
|
581
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalScrollShadowDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
582
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.2.4", type: SkyModalScrollShadowDirective, isStandalone: true, selector: "[skyModalScrollShadow]", outputs: { skyModalScrollShadow: "skyModalScrollShadow" }, host: { listeners: { "window:resize": "windowResize()", "scroll": "scroll()" } }, ngImport: i0 }); }
|
|
444
583
|
}
|
|
445
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
584
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalScrollShadowDirective, decorators: [{
|
|
446
585
|
type: Directive,
|
|
447
586
|
args: [{
|
|
448
587
|
standalone: true,
|
|
@@ -648,14 +787,14 @@ class SkyModalComponent {
|
|
|
648
787
|
viewkeeperEnabled() {
|
|
649
788
|
return this.#componentAdapter.modalContentHasDirectChildViewkeeper(this.#elRef);
|
|
650
789
|
}
|
|
651
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
652
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
790
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
791
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.2.4", type: SkyModalComponent, isStandalone: true, selector: "sky-modal", inputs: { formErrors: "formErrors", ariaRole: "ariaRole", tiledBody: "tiledBody", ariaDescribedBy: "ariaDescribedBy", ariaLabelledBy: "ariaLabelledBy" }, host: { listeners: { "document:keyup": "onDocumentKeyUp($event)", "document:keydown": "onDocumentKeyDown($event)" }, properties: { "class": "this.wrapperClass" } }, providers: [
|
|
653
792
|
SkyModalComponentAdapterService,
|
|
654
793
|
SkyModalErrorsService,
|
|
655
794
|
SkyDockService,
|
|
656
|
-
], viewQueries: [{ propertyName: "modalContentWrapperElement", first: true, predicate: ["modalContentWrapper"], descendants: true, read: ElementRef }], ngImport: i0, template: "<div\n class=\"sky-modal-dialog\"\n aria-modal=\"true\"\n [attr.aria-describedby]=\"ariaDescribedBy || modalContentId.id\"\n [attr.aria-labelledby]=\"ariaLabelledBy || headerId.id\"\n [attr.aria-owns]=\"ariaOwns\"\n [attr.role]=\"ariaRoleOrDefault\"\n (window:resize)=\"windowResize()\"\n>\n <div\n class=\"sky-modal sky-shadow sky-box sky-elevation-16 sky-modal-{{ size }}\"\n tabindex=\"-1\"\n [ngClass]=\"{\n 'sky-modal-tiled': tiledBody,\n 'sky-modal-viewkeeper': viewkeeperEnabled()\n }\"\n [ngStyle]=\"{\n zIndex: modalZIndex\n }\"\n >\n <div\n class=\"sky-modal-header\"\n [hidden]=\"!headerContent || !headerContent.children || headerContent.children.length < 1\"\n [ngStyle]=\"{\n 'box-shadow': scrollShadow?.topShadow\n }\"\n >\n <div\n class=\"sky-modal-header-content\"\n skyId\n [ngClass]=\"{\n 'sky-font-heading-2': size === 'full-page'\n }\"\n #headerContent\n #headerId=\"skyId\"\n >\n <ng-content select=\"sky-modal-header\" />\n </div>\n <div class=\"sky-modal-header-buttons\">\n <button\n *ngIf=\"helpKey\"\n class=\"sky-btn sky-modal-btn-help\"\n name=\"help-button\"\n type=\"button\"\n [attr.aria-label]=\"'skyux_modal_open_help' | skyLibResources\"\n (click)=\"helpButtonClick()\"\n >\n <sky-icon icon=\"question-circle\" />\n </button>\n\n <button\n type=\"button\"\n class=\"sky-btn sky-modal-btn-close\"\n [attr.aria-label]=\"'skyux_modal_close' | skyLibResources\"\n (click)=\"closeButtonClick()\"\n >\n <sky-icon icon=\"close\" />\n </button>\n </div>\n </div>\n <div\n class=\"sky-modal-content sky-padding-even-large\"\n role=\"region\"\n tabindex=\"0\"\n skyId\n [attr.aria-labelledby]=\"headerId.id\"\n (skyModalScrollShadow)=\"scrollShadowChange($event)\"\n #modalContentId=\"skyId\"\n #modalContentWrapper\n >\n <ng-content select=\"sky-modal-content\" />\n </div>\n <div\n class=\"sky-modal-footer\"\n [ngStyle]=\"{\n 'box-shadow': scrollShadow?.bottomShadow\n }\"\n >\n <ng-content select=\"sky-modal-footer\" />\n </div>\n </div>\n</div>\n", styles: [".sky-modal{border-top:1px solid #cdcfd2;border-bottom:1px solid #cdcfd2;border-left:1px solid #cdcfd2;border-right:1px solid #cdcfd2;position:fixed;width:auto;left:0;right:0;top:20px;margin:10px;display:flex;flex-direction:column;overflow:hidden}.sky-modal:focus{outline:none}@media (min-width: 768px){.sky-modal:not(.sky-modal-large){margin:0 auto}.sky-modal-small{width:300px}.sky-modal-small .sky-modal-content,.sky-modal-small .sky-modal-header,.sky-modal-small .sky-modal-footer{max-width:300px}.sky-modal-medium{width:600px}.sky-modal-medium .sky-modal-content,.sky-modal-medium .sky-modal-header,.sky-modal-medium .sky-modal-footer{max-width:600px}}@media (min-width: 920px){.sky-modal-large{margin:0 auto;width:900px}.sky-modal-large .sky-modal-content,.sky-modal-large .sky-modal-header,.sky-modal-large .sky-modal-footer{max-width:900px}}.sky-modal-content{background-color:#fff;--sky-background-color-page-default: #fff}.sky-modal-content:focus{outline-style:dotted;outline-width:thin;outline-offset:-1px}.sky-modal-tiled .sky-modal-content{background-color:#eeeeef;--sky-background-color-page-default: $sky-background-color-neutral-light}.sky-modal-tiled .sky-modal-content ::ng-deep .sky-tile-title{font-family:BLKB Sans,Helvetica Neue,Arial,sans-serif;color:var(--sky-text-color-deemphasized);font-weight:300;font-size:19px}.sky-modal-header{padding:9px 3px 9px 15px;background-color:#fff;display:flex;align-items:baseline;border-bottom:1px solid #e2e3e4}.sky-modal-header-buttons{flex-shrink:.0001}.sky-modal-header-buttons .sky-btn{border:none;color:#cdcfd2;cursor:pointer}.sky-modal-header-buttons .sky-btn:hover{color:#979ba2;transition:color .15s}.sky-modal-header-content{flex-grow:1}.sky-modal-header{flex-shrink:0;z-index:2}.sky-modal-content{overflow-y:auto}.sky-modal-footer{flex-shrink:0;z-index:2}.sky-modal-full-page{width:100%;top:0;margin:0}.sky-modal-full-page .sky-modal-header-buttons sky-icon[icon=close]{font-size:20px}.sky-modal-full-page .sky-modal-content{flex-grow:1}
|
|
795
|
+
], viewQueries: [{ propertyName: "modalContentWrapperElement", first: true, predicate: ["modalContentWrapper"], descendants: true, read: ElementRef }], ngImport: i0, template: "<div\n class=\"sky-modal-dialog\"\n aria-modal=\"true\"\n [attr.aria-describedby]=\"ariaDescribedBy || modalContentId.id\"\n [attr.aria-labelledby]=\"ariaLabelledBy || headerId.id\"\n [attr.aria-owns]=\"ariaOwns\"\n [attr.role]=\"ariaRoleOrDefault\"\n (window:resize)=\"windowResize()\"\n>\n <div\n class=\"sky-modal sky-shadow sky-box sky-elevation-16 sky-modal-{{ size }}\"\n tabindex=\"-1\"\n [ngClass]=\"{\n 'sky-modal-tiled': tiledBody,\n 'sky-modal-viewkeeper': viewkeeperEnabled()\n }\"\n [ngStyle]=\"{\n zIndex: modalZIndex\n }\"\n >\n <div\n class=\"sky-modal-header\"\n [hidden]=\"!headerContent || !headerContent.children || headerContent.children.length < 1\"\n [ngStyle]=\"{\n 'box-shadow': scrollShadow?.topShadow\n }\"\n >\n <div\n class=\"sky-modal-header-content\"\n skyId\n [ngClass]=\"{\n 'sky-font-heading-2': size === 'full-page'\n }\"\n #headerContent\n #headerId=\"skyId\"\n >\n <ng-content select=\"sky-modal-header\" />\n </div>\n <div class=\"sky-modal-header-buttons\">\n <button\n *ngIf=\"helpKey\"\n class=\"sky-btn sky-modal-btn-help\"\n name=\"help-button\"\n type=\"button\"\n [attr.aria-label]=\"'skyux_modal_open_help' | skyLibResources\"\n (click)=\"helpButtonClick()\"\n >\n <sky-icon icon=\"question-circle\" />\n </button>\n\n <button\n type=\"button\"\n class=\"sky-btn sky-modal-btn-close\"\n [attr.aria-label]=\"'skyux_modal_close' | skyLibResources\"\n (click)=\"closeButtonClick()\"\n >\n <sky-icon icon=\"close\" />\n </button>\n </div>\n </div>\n <div\n class=\"sky-modal-content sky-padding-even-large\"\n role=\"region\"\n tabindex=\"0\"\n skyId\n [attr.aria-labelledby]=\"headerId.id\"\n (skyModalScrollShadow)=\"scrollShadowChange($event)\"\n #modalContentId=\"skyId\"\n #modalContentWrapper\n >\n <ng-content select=\"sky-modal-content\" />\n </div>\n <div\n class=\"sky-modal-footer\"\n [ngStyle]=\"{\n 'box-shadow': scrollShadow?.bottomShadow\n }\"\n >\n <ng-content select=\"sky-modal-footer\" />\n </div>\n </div>\n</div>\n", styles: [".sky-modal{border-top:1px solid #cdcfd2;border-bottom:1px solid #cdcfd2;border-left:1px solid #cdcfd2;border-right:1px solid #cdcfd2;position:fixed;width:auto;left:0;right:0;top:20px;margin:10px;display:flex;flex-direction:column;overflow:hidden}.sky-modal:focus{outline:none}@media (min-width: 768px){.sky-modal:not(.sky-modal-large){margin:0 auto}.sky-modal-small{width:300px}.sky-modal-small .sky-modal-content,.sky-modal-small .sky-modal-header,.sky-modal-small .sky-modal-footer{max-width:300px}.sky-modal-medium{width:600px}.sky-modal-medium .sky-modal-content,.sky-modal-medium .sky-modal-header,.sky-modal-medium .sky-modal-footer{max-width:600px}}@media (min-width: 920px){.sky-modal-large{margin:0 auto;width:900px}.sky-modal-large .sky-modal-content,.sky-modal-large .sky-modal-header,.sky-modal-large .sky-modal-footer{max-width:900px}}.sky-modal-content{background-color:#fff;--sky-background-color-page-default: #fff}.sky-modal-content:focus{outline-style:dotted;outline-width:thin;outline-offset:-1px}.sky-modal-tiled .sky-modal-content{background-color:#eeeeef;--sky-background-color-page-default: $sky-background-color-neutral-light}.sky-modal-tiled .sky-modal-content ::ng-deep .sky-tile-title{font-family:BLKB Sans,Helvetica Neue,Arial,sans-serif;color:var(--sky-text-color-deemphasized);font-weight:300;font-size:19px}.sky-modal-header{padding:9px 3px 9px 15px;background-color:#fff;display:flex;align-items:baseline;border-bottom:1px solid #e2e3e4}.sky-modal-header-buttons{flex-shrink:.0001}.sky-modal-header-buttons .sky-btn{border:none;color:#cdcfd2;cursor:pointer}.sky-modal-header-buttons .sky-btn:hover{color:#979ba2;transition:color .15s}.sky-modal-header-content{flex-grow:1}.sky-modal-header{flex-shrink:0;z-index:2}.sky-modal-content{overflow-y:auto}.sky-modal-footer{flex-shrink:0;z-index:2}.sky-modal-full-page{width:100%;top:0;margin:0}.sky-modal-full-page .sky-modal-header-buttons sky-icon[icon=close]{font-size:20px}.sky-modal-full-page .sky-modal-content{flex-grow:1}.sky-modal-content>::ng-deep sky-dock{bottom:-15px;margin-left:-15px;margin-bottom:-15px;padding-top:15px;width:calc(100% + 30px)}:host-context(.sky-theme-modern) .sky-modal-header{border:none;padding:20px 30px}:host-context(.sky-theme-modern) .sky-modal-btn-help,:host-context(.sky-theme-modern) .sky-modal-btn-close{display:none}:host-context(.sky-theme-modern) .sky-modal-content{padding:0}:host-context(.sky-theme-modern) .sky-modal-full-page{width:calc(100% - 60px);margin:30px}:host-context(.sky-theme-modern) .sky-modal-content>::ng-deep sky-dock{bottom:0;margin-left:initial;margin-bottom:initial;padding-top:initial;width:100%}:host-context(.sky-theme-modern) .sky-modal-viewkeeper .sky-modal-header{box-shadow:none!important}:host-context(.sky-theme-modern) .sky-modal-viewkeeper .sky-modal-content ::ng-deep sky-modal-content>.sky-viewkeeper-fixed{box-shadow:0 4px 8px -4px #0000004d}:host-context(.sky-theme-modern) .sky-modal-viewkeeper .sky-modal-content ::ng-deep sky-modal-content>.sky-viewkeeper-fixed>sky-toolbar .sky-toolbar-container{background-color:#fff;--sky-background-color-page-default: #fff;padding-left:30px;padding-right:30px}.sky-theme-modern .sky-modal-header{border:none;padding:20px 30px}.sky-theme-modern .sky-modal-btn-help,.sky-theme-modern .sky-modal-btn-close{display:none}.sky-theme-modern .sky-modal-content{padding:0}.sky-theme-modern .sky-modal-full-page{width:calc(100% - 60px);margin:30px}.sky-theme-modern .sky-modal-content>::ng-deep sky-dock{bottom:0;margin-left:initial;margin-bottom:initial;padding-top:initial;width:100%}.sky-theme-modern .sky-modal-viewkeeper .sky-modal-header{box-shadow:none!important}.sky-theme-modern .sky-modal-viewkeeper .sky-modal-content ::ng-deep sky-modal-content>.sky-viewkeeper-fixed{box-shadow:0 4px 8px -4px #0000004d}.sky-theme-modern .sky-modal-viewkeeper .sky-modal-content ::ng-deep sky-modal-content>.sky-viewkeeper-fixed>sky-toolbar .sky-toolbar-container{background-color:#fff;--sky-background-color-page-default: #fff;padding-left:30px;padding-right:30px}:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-modal{border-color:#121212}:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-modal-header{color:#fbfcfe}:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-modal-header,:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-modal-content{background-color:transparent;--sky-background-color-page-default: $sky-theme-modern-mode-dark-background-color-page-default}.sky-theme-modern.sky-theme-mode-dark .sky-modal{border-color:#121212}.sky-theme-modern.sky-theme-mode-dark .sky-modal-header{color:#fbfcfe}.sky-theme-modern.sky-theme-mode-dark .sky-modal-header,.sky-theme-modern.sky-theme-mode-dark .sky-modal-content{background-color:transparent;--sky-background-color-page-default: $sky-theme-modern-mode-dark-background-color-page-default}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "ngmodule", type: SkyIconModule }, { kind: "component", type: i2.λ4, selector: "sky-icon", inputs: ["icon", "iconType", "size", "fixedWidth", "variant"] }, { kind: "ngmodule", type: SkyIdModule }, { kind: "directive", type: i1.λ2, selector: "[skyId]", exportAs: ["skyId"] }, { kind: "directive", type: SkyModalScrollShadowDirective, selector: "[skyModalScrollShadow]", outputs: ["skyModalScrollShadow"] }, { kind: "ngmodule", type: SkyModalsResourcesModule }, { kind: "pipe", type: i4.SkyLibResourcesPipe, name: "skyLibResources" }] }); }
|
|
657
796
|
}
|
|
658
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
797
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalComponent, decorators: [{
|
|
659
798
|
type: Component,
|
|
660
799
|
args: [{ standalone: true, selector: 'sky-modal', providers: [
|
|
661
800
|
SkyModalComponentAdapterService,
|
|
@@ -667,7 +806,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.1", ngImpor
|
|
|
667
806
|
SkyIdModule,
|
|
668
807
|
SkyModalScrollShadowDirective,
|
|
669
808
|
SkyModalsResourcesModule,
|
|
670
|
-
], template: "<div\n class=\"sky-modal-dialog\"\n aria-modal=\"true\"\n [attr.aria-describedby]=\"ariaDescribedBy || modalContentId.id\"\n [attr.aria-labelledby]=\"ariaLabelledBy || headerId.id\"\n [attr.aria-owns]=\"ariaOwns\"\n [attr.role]=\"ariaRoleOrDefault\"\n (window:resize)=\"windowResize()\"\n>\n <div\n class=\"sky-modal sky-shadow sky-box sky-elevation-16 sky-modal-{{ size }}\"\n tabindex=\"-1\"\n [ngClass]=\"{\n 'sky-modal-tiled': tiledBody,\n 'sky-modal-viewkeeper': viewkeeperEnabled()\n }\"\n [ngStyle]=\"{\n zIndex: modalZIndex\n }\"\n >\n <div\n class=\"sky-modal-header\"\n [hidden]=\"!headerContent || !headerContent.children || headerContent.children.length < 1\"\n [ngStyle]=\"{\n 'box-shadow': scrollShadow?.topShadow\n }\"\n >\n <div\n class=\"sky-modal-header-content\"\n skyId\n [ngClass]=\"{\n 'sky-font-heading-2': size === 'full-page'\n }\"\n #headerContent\n #headerId=\"skyId\"\n >\n <ng-content select=\"sky-modal-header\" />\n </div>\n <div class=\"sky-modal-header-buttons\">\n <button\n *ngIf=\"helpKey\"\n class=\"sky-btn sky-modal-btn-help\"\n name=\"help-button\"\n type=\"button\"\n [attr.aria-label]=\"'skyux_modal_open_help' | skyLibResources\"\n (click)=\"helpButtonClick()\"\n >\n <sky-icon icon=\"question-circle\" />\n </button>\n\n <button\n type=\"button\"\n class=\"sky-btn sky-modal-btn-close\"\n [attr.aria-label]=\"'skyux_modal_close' | skyLibResources\"\n (click)=\"closeButtonClick()\"\n >\n <sky-icon icon=\"close\" />\n </button>\n </div>\n </div>\n <div\n class=\"sky-modal-content sky-padding-even-large\"\n role=\"region\"\n tabindex=\"0\"\n skyId\n [attr.aria-labelledby]=\"headerId.id\"\n (skyModalScrollShadow)=\"scrollShadowChange($event)\"\n #modalContentId=\"skyId\"\n #modalContentWrapper\n >\n <ng-content select=\"sky-modal-content\" />\n </div>\n <div\n class=\"sky-modal-footer\"\n [ngStyle]=\"{\n 'box-shadow': scrollShadow?.bottomShadow\n }\"\n >\n <ng-content select=\"sky-modal-footer\" />\n </div>\n </div>\n</div>\n", styles: [".sky-modal{border-top:1px solid #cdcfd2;border-bottom:1px solid #cdcfd2;border-left:1px solid #cdcfd2;border-right:1px solid #cdcfd2;position:fixed;width:auto;left:0;right:0;top:20px;margin:10px;display:flex;flex-direction:column;overflow:hidden}.sky-modal:focus{outline:none}@media (min-width: 768px){.sky-modal:not(.sky-modal-large){margin:0 auto}.sky-modal-small{width:300px}.sky-modal-small .sky-modal-content,.sky-modal-small .sky-modal-header,.sky-modal-small .sky-modal-footer{max-width:300px}.sky-modal-medium{width:600px}.sky-modal-medium .sky-modal-content,.sky-modal-medium .sky-modal-header,.sky-modal-medium .sky-modal-footer{max-width:600px}}@media (min-width: 920px){.sky-modal-large{margin:0 auto;width:900px}.sky-modal-large .sky-modal-content,.sky-modal-large .sky-modal-header,.sky-modal-large .sky-modal-footer{max-width:900px}}.sky-modal-content{background-color:#fff;--sky-background-color-page-default: #fff}.sky-modal-content:focus{outline-style:dotted;outline-width:thin;outline-offset:-1px}.sky-modal-tiled .sky-modal-content{background-color:#eeeeef;--sky-background-color-page-default: $sky-background-color-neutral-light}.sky-modal-tiled .sky-modal-content ::ng-deep .sky-tile-title{font-family:BLKB Sans,Helvetica Neue,Arial,sans-serif;color:var(--sky-text-color-deemphasized);font-weight:300;font-size:19px}.sky-modal-header{padding:9px 3px 9px 15px;background-color:#fff;display:flex;align-items:baseline;border-bottom:1px solid #e2e3e4}.sky-modal-header-buttons{flex-shrink:.0001}.sky-modal-header-buttons .sky-btn{border:none;color:#cdcfd2;cursor:pointer}.sky-modal-header-buttons .sky-btn:hover{color:#979ba2;transition:color .15s}.sky-modal-header-content{flex-grow:1}.sky-modal-header{flex-shrink:0;z-index:2}.sky-modal-content{overflow-y:auto}.sky-modal-footer{flex-shrink:0;z-index:2}.sky-modal-full-page{width:100%;top:0;margin:0}.sky-modal-full-page .sky-modal-header-buttons sky-icon[icon=close]{font-size:20px}.sky-modal-full-page .sky-modal-content{flex-grow:1}
|
|
809
|
+
], template: "<div\n class=\"sky-modal-dialog\"\n aria-modal=\"true\"\n [attr.aria-describedby]=\"ariaDescribedBy || modalContentId.id\"\n [attr.aria-labelledby]=\"ariaLabelledBy || headerId.id\"\n [attr.aria-owns]=\"ariaOwns\"\n [attr.role]=\"ariaRoleOrDefault\"\n (window:resize)=\"windowResize()\"\n>\n <div\n class=\"sky-modal sky-shadow sky-box sky-elevation-16 sky-modal-{{ size }}\"\n tabindex=\"-1\"\n [ngClass]=\"{\n 'sky-modal-tiled': tiledBody,\n 'sky-modal-viewkeeper': viewkeeperEnabled()\n }\"\n [ngStyle]=\"{\n zIndex: modalZIndex\n }\"\n >\n <div\n class=\"sky-modal-header\"\n [hidden]=\"!headerContent || !headerContent.children || headerContent.children.length < 1\"\n [ngStyle]=\"{\n 'box-shadow': scrollShadow?.topShadow\n }\"\n >\n <div\n class=\"sky-modal-header-content\"\n skyId\n [ngClass]=\"{\n 'sky-font-heading-2': size === 'full-page'\n }\"\n #headerContent\n #headerId=\"skyId\"\n >\n <ng-content select=\"sky-modal-header\" />\n </div>\n <div class=\"sky-modal-header-buttons\">\n <button\n *ngIf=\"helpKey\"\n class=\"sky-btn sky-modal-btn-help\"\n name=\"help-button\"\n type=\"button\"\n [attr.aria-label]=\"'skyux_modal_open_help' | skyLibResources\"\n (click)=\"helpButtonClick()\"\n >\n <sky-icon icon=\"question-circle\" />\n </button>\n\n <button\n type=\"button\"\n class=\"sky-btn sky-modal-btn-close\"\n [attr.aria-label]=\"'skyux_modal_close' | skyLibResources\"\n (click)=\"closeButtonClick()\"\n >\n <sky-icon icon=\"close\" />\n </button>\n </div>\n </div>\n <div\n class=\"sky-modal-content sky-padding-even-large\"\n role=\"region\"\n tabindex=\"0\"\n skyId\n [attr.aria-labelledby]=\"headerId.id\"\n (skyModalScrollShadow)=\"scrollShadowChange($event)\"\n #modalContentId=\"skyId\"\n #modalContentWrapper\n >\n <ng-content select=\"sky-modal-content\" />\n </div>\n <div\n class=\"sky-modal-footer\"\n [ngStyle]=\"{\n 'box-shadow': scrollShadow?.bottomShadow\n }\"\n >\n <ng-content select=\"sky-modal-footer\" />\n </div>\n </div>\n</div>\n", styles: [".sky-modal{border-top:1px solid #cdcfd2;border-bottom:1px solid #cdcfd2;border-left:1px solid #cdcfd2;border-right:1px solid #cdcfd2;position:fixed;width:auto;left:0;right:0;top:20px;margin:10px;display:flex;flex-direction:column;overflow:hidden}.sky-modal:focus{outline:none}@media (min-width: 768px){.sky-modal:not(.sky-modal-large){margin:0 auto}.sky-modal-small{width:300px}.sky-modal-small .sky-modal-content,.sky-modal-small .sky-modal-header,.sky-modal-small .sky-modal-footer{max-width:300px}.sky-modal-medium{width:600px}.sky-modal-medium .sky-modal-content,.sky-modal-medium .sky-modal-header,.sky-modal-medium .sky-modal-footer{max-width:600px}}@media (min-width: 920px){.sky-modal-large{margin:0 auto;width:900px}.sky-modal-large .sky-modal-content,.sky-modal-large .sky-modal-header,.sky-modal-large .sky-modal-footer{max-width:900px}}.sky-modal-content{background-color:#fff;--sky-background-color-page-default: #fff}.sky-modal-content:focus{outline-style:dotted;outline-width:thin;outline-offset:-1px}.sky-modal-tiled .sky-modal-content{background-color:#eeeeef;--sky-background-color-page-default: $sky-background-color-neutral-light}.sky-modal-tiled .sky-modal-content ::ng-deep .sky-tile-title{font-family:BLKB Sans,Helvetica Neue,Arial,sans-serif;color:var(--sky-text-color-deemphasized);font-weight:300;font-size:19px}.sky-modal-header{padding:9px 3px 9px 15px;background-color:#fff;display:flex;align-items:baseline;border-bottom:1px solid #e2e3e4}.sky-modal-header-buttons{flex-shrink:.0001}.sky-modal-header-buttons .sky-btn{border:none;color:#cdcfd2;cursor:pointer}.sky-modal-header-buttons .sky-btn:hover{color:#979ba2;transition:color .15s}.sky-modal-header-content{flex-grow:1}.sky-modal-header{flex-shrink:0;z-index:2}.sky-modal-content{overflow-y:auto}.sky-modal-footer{flex-shrink:0;z-index:2}.sky-modal-full-page{width:100%;top:0;margin:0}.sky-modal-full-page .sky-modal-header-buttons sky-icon[icon=close]{font-size:20px}.sky-modal-full-page .sky-modal-content{flex-grow:1}.sky-modal-content>::ng-deep sky-dock{bottom:-15px;margin-left:-15px;margin-bottom:-15px;padding-top:15px;width:calc(100% + 30px)}:host-context(.sky-theme-modern) .sky-modal-header{border:none;padding:20px 30px}:host-context(.sky-theme-modern) .sky-modal-btn-help,:host-context(.sky-theme-modern) .sky-modal-btn-close{display:none}:host-context(.sky-theme-modern) .sky-modal-content{padding:0}:host-context(.sky-theme-modern) .sky-modal-full-page{width:calc(100% - 60px);margin:30px}:host-context(.sky-theme-modern) .sky-modal-content>::ng-deep sky-dock{bottom:0;margin-left:initial;margin-bottom:initial;padding-top:initial;width:100%}:host-context(.sky-theme-modern) .sky-modal-viewkeeper .sky-modal-header{box-shadow:none!important}:host-context(.sky-theme-modern) .sky-modal-viewkeeper .sky-modal-content ::ng-deep sky-modal-content>.sky-viewkeeper-fixed{box-shadow:0 4px 8px -4px #0000004d}:host-context(.sky-theme-modern) .sky-modal-viewkeeper .sky-modal-content ::ng-deep sky-modal-content>.sky-viewkeeper-fixed>sky-toolbar .sky-toolbar-container{background-color:#fff;--sky-background-color-page-default: #fff;padding-left:30px;padding-right:30px}.sky-theme-modern .sky-modal-header{border:none;padding:20px 30px}.sky-theme-modern .sky-modal-btn-help,.sky-theme-modern .sky-modal-btn-close{display:none}.sky-theme-modern .sky-modal-content{padding:0}.sky-theme-modern .sky-modal-full-page{width:calc(100% - 60px);margin:30px}.sky-theme-modern .sky-modal-content>::ng-deep sky-dock{bottom:0;margin-left:initial;margin-bottom:initial;padding-top:initial;width:100%}.sky-theme-modern .sky-modal-viewkeeper .sky-modal-header{box-shadow:none!important}.sky-theme-modern .sky-modal-viewkeeper .sky-modal-content ::ng-deep sky-modal-content>.sky-viewkeeper-fixed{box-shadow:0 4px 8px -4px #0000004d}.sky-theme-modern .sky-modal-viewkeeper .sky-modal-content ::ng-deep sky-modal-content>.sky-viewkeeper-fixed>sky-toolbar .sky-toolbar-container{background-color:#fff;--sky-background-color-page-default: #fff;padding-left:30px;padding-right:30px}:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-modal{border-color:#121212}:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-modal-header{color:#fbfcfe}:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-modal-header,:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-modal-content{background-color:transparent;--sky-background-color-page-default: $sky-theme-modern-mode-dark-background-color-page-default}.sky-theme-modern.sky-theme-mode-dark .sky-modal{border-color:#121212}.sky-theme-modern.sky-theme-mode-dark .sky-modal-header{color:#fbfcfe}.sky-theme-modern.sky-theme-mode-dark .sky-modal-header,.sky-theme-modern.sky-theme-mode-dark .sky-modal-content{background-color:transparent;--sky-background-color-page-default: $sky-theme-modern-mode-dark-background-color-page-default}\n"] }]
|
|
671
810
|
}], ctorParameters: () => [], propDecorators: { wrapperClass: [{
|
|
672
811
|
type: HostBinding,
|
|
673
812
|
args: ['class']
|
|
@@ -692,187 +831,76 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.1", ngImpor
|
|
|
692
831
|
args: ['document:keydown', ['$event']]
|
|
693
832
|
}] } });
|
|
694
833
|
|
|
695
|
-
/**
|
|
696
|
-
* Properties about the modal close action and a method to close the modal.
|
|
697
|
-
*/
|
|
698
|
-
class SkyModalBeforeCloseHandler {
|
|
699
|
-
constructor(closeModal, closeArgs) {
|
|
700
|
-
this.closeArgs = closeArgs;
|
|
701
|
-
this.closeModal = closeModal;
|
|
702
|
-
}
|
|
703
|
-
}
|
|
704
|
-
|
|
705
|
-
/**
|
|
706
|
-
* Contains an object with the data passed from users when
|
|
707
|
-
* a modal is closed and the reason that the modal was closed.
|
|
708
|
-
*/
|
|
709
|
-
class SkyModalCloseArgs {
|
|
710
|
-
}
|
|
711
|
-
|
|
712
|
-
class SkyModalInstance {
|
|
713
|
-
/**
|
|
714
|
-
* An event that the modal instance emits when it is about to close.
|
|
715
|
-
* It emits a `SkyModalBeforeCloseHandler` object with a `closeModal` method
|
|
716
|
-
* that closes the modal. If a subscription exists for this event,
|
|
717
|
-
* the modal does not close until the subscriber calls the `closeModal` method.
|
|
718
|
-
*/
|
|
719
|
-
get beforeClose() {
|
|
720
|
-
return this.#_beforeClose;
|
|
721
|
-
}
|
|
722
|
-
/**
|
|
723
|
-
* An event that the modal instance emits when it closes.
|
|
724
|
-
* It emits a `SkyModalCloseArgs` object with a `data` property that includes
|
|
725
|
-
* data passed from users on close or save and a `reason` property that indicates
|
|
726
|
-
* whether the modal was saved or closed without saving.
|
|
727
|
-
* The `reason` property accepts any string value.
|
|
728
|
-
* Common examples include `"cancel"`, `"close"`, and `"save"`.
|
|
729
|
-
*/
|
|
730
|
-
get closed() {
|
|
731
|
-
return this.#_closed;
|
|
732
|
-
}
|
|
733
|
-
/**
|
|
734
|
-
* An event that the modal instance emits when users click
|
|
735
|
-
* the <i class="fa fa-question-circle" aria-hidden="true"></i> button.
|
|
736
|
-
* If a `helpKey` parameter was specified, the `helpOpened` event broadcasts the `helpKey`.
|
|
737
|
-
*/
|
|
738
|
-
get helpOpened() {
|
|
739
|
-
return this.#_helpOpened;
|
|
740
|
-
}
|
|
741
|
-
/**
|
|
742
|
-
* Sets the component adapter for the instance. This is used internally for actions such as scrolling the content.
|
|
743
|
-
* @internal
|
|
744
|
-
*/
|
|
745
|
-
set adapter(value) {
|
|
746
|
-
this.#adapter = value;
|
|
747
|
-
}
|
|
748
|
-
/**
|
|
749
|
-
* Sets the component ref for the instance. This is used to extract the component instance for the public API and the element ref for internal use.
|
|
750
|
-
* @internal
|
|
751
|
-
*/
|
|
752
|
-
set componentRef(value) {
|
|
753
|
-
this.componentInstance = value.instance;
|
|
754
|
-
this.#elementRef = value.location;
|
|
755
|
-
}
|
|
756
|
-
#_beforeClose = new Subject();
|
|
757
|
-
#_closed = new Subject();
|
|
758
|
-
#_helpOpened = new Subject();
|
|
759
|
-
#adapter;
|
|
760
|
-
#elementRef;
|
|
761
|
-
/**
|
|
762
|
-
* Closes the modal instance.
|
|
763
|
-
* @param result Specifies an object to emit to subscribers of the `closed` event of the
|
|
764
|
-
* modal instance. The `SkyModalInstance` provider can be injected into a component's constructor
|
|
765
|
-
* so that this `close` function can be called from a button in the `sky-modal-footer`.
|
|
766
|
-
* @param reason Specifies the reason for the modal closing, with the default reason of `"close"`.
|
|
767
|
-
* @param ignoreBeforeClose Indicates whether to ignore the modal instance's `beforeClose` event.
|
|
768
|
-
*/
|
|
769
|
-
close(result, reason, ignoreBeforeClose) {
|
|
770
|
-
if (reason === undefined) {
|
|
771
|
-
reason = 'close';
|
|
772
|
-
}
|
|
773
|
-
this.#closeModal(reason, result, ignoreBeforeClose);
|
|
774
|
-
}
|
|
775
|
-
/**
|
|
776
|
-
* Closes the modal instance with `reason="cancel"`.
|
|
777
|
-
* @param result Specifies an object to emit to subscribers of the `closed` event of the modal
|
|
778
|
-
* instance. The `SkyModalInstance` provider can be injected into a component's constructor so
|
|
779
|
-
* that this cancel function can be called from a button in the `sky-modal-footer`.
|
|
780
|
-
*/
|
|
781
|
-
cancel(result) {
|
|
782
|
-
this.#closeModal('cancel', result);
|
|
783
|
-
}
|
|
784
|
-
/**
|
|
785
|
-
* Closes the modal instance with `reason="save"`.
|
|
786
|
-
* @param result Specifies an object to emit to subscribers of the `closed` event of the modal
|
|
787
|
-
* instance. The `SkyModalInstance` provider can be injected into a component's constructor so
|
|
788
|
-
* that this `save` function can be called from a button in `the sky-modal-footer`.
|
|
789
|
-
*/
|
|
790
|
-
save(result) {
|
|
791
|
-
this.#closeModal('save', result);
|
|
792
|
-
}
|
|
793
|
-
/**
|
|
794
|
-
* Scrolls the modal content area to the top of its scrollable area.
|
|
795
|
-
*/
|
|
796
|
-
scrollContentToTop() {
|
|
797
|
-
if (this.#adapter && this.#elementRef) {
|
|
798
|
-
this.#adapter.scrollContentToTop(this.#elementRef);
|
|
799
|
-
}
|
|
800
|
-
}
|
|
801
|
-
/**
|
|
802
|
-
* Triggers the `helpOpened` event that broadcasts a `helpKey` parameter to open
|
|
803
|
-
* when users click the <i class="fa fa-question-circle" aria-hidden="true"></i> button.
|
|
804
|
-
* @param helpKey Specifies a string to emit to subscribers of
|
|
805
|
-
* the modal instance's `helpOpened` event. Consumers can inject the `SkyModalInstance` provider
|
|
806
|
-
* into a component's constructor to call the `openHelp` function in the modal template.
|
|
807
|
-
*/
|
|
808
|
-
openHelp(helpKey) {
|
|
809
|
-
this.#_helpOpened.next(helpKey);
|
|
810
|
-
}
|
|
811
|
-
#closeModal(type, result, ignoreBeforeClose = false) {
|
|
812
|
-
const args = new SkyModalCloseArgs();
|
|
813
|
-
args.reason = type;
|
|
814
|
-
args.data = result;
|
|
815
|
-
if (this.#_beforeClose.observers.length === 0 || ignoreBeforeClose) {
|
|
816
|
-
this.#notifyClosed(args);
|
|
817
|
-
}
|
|
818
|
-
else {
|
|
819
|
-
this.#_beforeClose.next(new SkyModalBeforeCloseHandler(() => {
|
|
820
|
-
this.#notifyClosed(args);
|
|
821
|
-
}, args));
|
|
822
|
-
}
|
|
823
|
-
}
|
|
824
|
-
#notifyClosed(args) {
|
|
825
|
-
this.#_closed.next(args);
|
|
826
|
-
this.#_closed.complete();
|
|
827
|
-
this.#_beforeClose.complete();
|
|
828
|
-
this.#_helpOpened.complete();
|
|
829
|
-
}
|
|
830
|
-
}
|
|
831
|
-
|
|
832
834
|
class SkyConfirmComponent {
|
|
835
|
+
#ngUnsubscribe;
|
|
833
836
|
#config;
|
|
834
|
-
#
|
|
835
|
-
#
|
|
836
|
-
|
|
837
|
-
|
|
837
|
+
#modalInstance;
|
|
838
|
+
#confirmInstance;
|
|
839
|
+
#resourcesSvc;
|
|
840
|
+
#idSvc;
|
|
841
|
+
constructor() {
|
|
838
842
|
this.isOkType = false;
|
|
839
|
-
this
|
|
840
|
-
this.#
|
|
841
|
-
this.#
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
843
|
+
this.preserveWhiteSpace = false;
|
|
844
|
+
this.#ngUnsubscribe = new Subject();
|
|
845
|
+
this.#config = inject(SKY_CONFIRM_CONFIG);
|
|
846
|
+
this.#modalInstance = inject(SkyModalInstance);
|
|
847
|
+
this.#confirmInstance = inject(SkyConfirmInstance);
|
|
848
|
+
this.#resourcesSvc = inject(SkyLibResourcesService);
|
|
849
|
+
this.#idSvc = inject(SkyIdService);
|
|
850
|
+
if (this.#config.type === SkyConfirmType.Custom &&
|
|
851
|
+
this.#config.buttons &&
|
|
852
|
+
this.#config.buttons.length > 0) {
|
|
853
|
+
this.buttons = this.#getCustomButtons(this.#config.buttons);
|
|
846
854
|
}
|
|
847
855
|
else {
|
|
848
856
|
this.#getPresetButtons()
|
|
849
|
-
.pipe(
|
|
857
|
+
.pipe(takeUntil(this.#ngUnsubscribe))
|
|
850
858
|
.subscribe((buttons) => {
|
|
851
859
|
this.buttons = buttons;
|
|
852
860
|
});
|
|
853
861
|
}
|
|
854
|
-
this.message = config.message;
|
|
855
|
-
this.body = config.body;
|
|
856
|
-
// Using the service here instead of the directive due to the confirm
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
this.
|
|
862
|
+
this.message = this.#config.message;
|
|
863
|
+
this.body = this.#config.body;
|
|
864
|
+
// Using the service here instead of the directive due to the confirm
|
|
865
|
+
// component's "body" container being conditional and thus a template
|
|
866
|
+
// variable being unavailable at an outer scope
|
|
867
|
+
this.bodyId = this.#idSvc.generateId();
|
|
868
|
+
this.preserveWhiteSpace = !!this.#config.preserveWhiteSpace;
|
|
869
|
+
this.isOkType = this.#config.type === SkyConfirmType.OK;
|
|
870
|
+
// Closes the modal when requested by the confirm instance.
|
|
871
|
+
this.#confirmInstance.closed.subscribe((args) => {
|
|
872
|
+
this.#modalInstance.close(args);
|
|
873
|
+
});
|
|
874
|
+
this.#modalInstance.closed.subscribe((args) => {
|
|
875
|
+
// Close the confirm when the "escape" key is pressed (passes 'undefined')
|
|
876
|
+
// since this behavior is handled by the underlying modal component.
|
|
877
|
+
if (args.data === undefined) {
|
|
878
|
+
this.#confirmInstance.close({
|
|
879
|
+
action: 'cancel',
|
|
880
|
+
});
|
|
881
|
+
}
|
|
882
|
+
});
|
|
883
|
+
}
|
|
884
|
+
ngOnDestroy() {
|
|
885
|
+
this.#ngUnsubscribe.next();
|
|
886
|
+
this.#ngUnsubscribe.complete();
|
|
860
887
|
}
|
|
861
888
|
close(button) {
|
|
862
889
|
const result = {
|
|
863
890
|
action: button.action,
|
|
864
891
|
};
|
|
865
|
-
this.#
|
|
892
|
+
this.#confirmInstance.close(result);
|
|
866
893
|
}
|
|
867
894
|
#getPresetButtons() {
|
|
868
895
|
const emitter = new ReplaySubject(1);
|
|
869
|
-
this.#
|
|
896
|
+
this.#resourcesSvc
|
|
870
897
|
.getStrings({
|
|
871
898
|
cancel: 'skyux_confirm_dialog_default_cancel_text',
|
|
872
899
|
no: 'skyux_confirm_dialog_default_no_text',
|
|
873
900
|
ok: 'skyux_confirm_dialog_default_ok_text',
|
|
874
901
|
yes: 'skyux_confirm_dialog_default_yes_text',
|
|
875
902
|
})
|
|
903
|
+
.pipe(takeUntil(this.#ngUnsubscribe))
|
|
876
904
|
.subscribe((values) => {
|
|
877
905
|
const confirmButtons = [];
|
|
878
906
|
switch (this.#config.type) {
|
|
@@ -917,10 +945,10 @@ class SkyConfirmComponent {
|
|
|
917
945
|
autofocus: config.autofocus || false,
|
|
918
946
|
}));
|
|
919
947
|
}
|
|
920
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
921
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
948
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyConfirmComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
949
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.2.4", type: SkyConfirmComponent, isStandalone: true, selector: "sky-confirm", ngImport: i0, template: "<div class=\"sky-confirm\" [ngClass]=\"{ 'sky-confirm-type-ok': isOkType }\">\n <sky-modal\n ariaRole=\"alertdialog\"\n [ariaLabelledBy]=\"confirmMessage.id\"\n [ariaDescribedBy]=\"body ? bodyId : undefined\"\n >\n <sky-modal-content class=\"sky-confirm-content\">\n <!--\n The following \"magic comment\" keeps Prettier from adding line breaks\n inside the div and causing leading and trailing whitespace when\n `preserveWhiteSpace` is `true`.\n https://prettier.io/blog/2018/11/07/1.15.0.html#whitespace-sensitive-formatting\n -->\n <!-- display: inline -->\n <div\n class=\"sky-confirm-message\"\n [ngClass]=\"{\n 'sky-confirm-preserve-white-space': preserveWhiteSpace\n }\"\n [skyThemeClass]=\"{\n 'sky-font-display-4': 'default',\n 'sky-font-heading-1 sky-font-display-3': 'modern'\n }\"\n skyId\n #confirmMessage=\"skyId\"\n >{{ message }}</div\n >\n\n <!--\n The following \"magic comment\" keeps Prettier from adding line breaks\n inside the div and causing leading and trailing whitespace when\n `preserveWhiteSpace` is `true`.\n https://prettier.io/blog/2018/11/07/1.15.0.html#whitespace-sensitive-formatting\n -->\n <!-- display: inline -->\n <div\n *ngIf=\"body\"\n class=\"sky-confirm-body\"\n [id]=\"bodyId\"\n [ngClass]=\"{\n 'sky-confirm-preserve-white-space': preserveWhiteSpace\n }\"\n >{{ body }}</div\n >\n\n <div class=\"sky-confirm-buttons\">\n <button\n *ngFor=\"let button of buttons\"\n type=\"button\"\n class=\"sky-btn\"\n [ngClass]=\"'sky-btn-' + button.styleType\"\n [skyThemeClass]=\"{\n 'sky-margin-inline-sm': 'modern',\n 'sky-margin-inline-compact': 'default'\n }\"\n (click)=\"close(button)\"\n [attr.autofocus]=\"button.autofocus ? 'autofocus' : null\"\n >\n {{ button.text }}\n </button>\n </div>\n </sky-modal-content>\n </sky-modal>\n</div>\n", styles: [".sky-confirm{--sky-confirm-body-margin-top: var(--sky-margin-stacked-sm);--sky-confirm-buttons-margin-top: var(--sky-margin-stacked-xl);--sky-confirm-content-padding: 0;--sky-confirm-message-padding-bottom: 0}:host-context(.sky-theme-modern) .sky-confirm{--sky-confirm-body-margin-top: 0;--sky-confirm-buttons-margin-top: var(--sky-margin-stacked-lg);--sky-confirm-content-padding: var(--sky-margin-stacked-lg) var(--sky-margin-inline-xl);--sky-confirm-message-padding-bottom: var(--sky-margin-stacked-lg)}.sky-theme-modern .sky-confirm{--sky-confirm-body-margin-top: 0;--sky-confirm-buttons-margin-top: var(--sky-margin-stacked-lg);--sky-confirm-content-padding: var(--sky-margin-stacked-lg) var(--sky-margin-inline-xl);--sky-confirm-message-padding-bottom: var(--sky-margin-stacked-lg)}.sky-confirm-content{padding:var(--sky-confirm-content-padding)}.sky-confirm-message{margin-top:var(--sky-margin-stacked-xs);padding-bottom:var(--sky-confirm-message-padding-bottom)}.sky-confirm-body{margin-top:var(--sky-confirm-body-margin-top)}.sky-confirm-buttons{margin-top:var(--sky-confirm-buttons-margin-top)}.sky-confirm-preserve-white-space{white-space:pre-wrap}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: SkyIdModule }, { kind: "directive", type: i1.λ2, selector: "[skyId]", exportAs: ["skyId"] }, { kind: "component", type: SkyModalComponent, selector: "sky-modal", inputs: ["formErrors", "ariaRole", "tiledBody", "ariaDescribedBy", "ariaLabelledBy"] }, { kind: "component", type: SkyModalContentComponent, selector: "sky-modal-content" }, { kind: "ngmodule", type: SkyModalsResourcesModule }, { kind: "ngmodule", type: SkyThemeModule }, { kind: "directive", type: i3.λ2, selector: "[skyThemeClass]", inputs: ["class", "skyThemeClass"] }] }); }
|
|
922
950
|
}
|
|
923
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
951
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyConfirmComponent, decorators: [{
|
|
924
952
|
type: Component,
|
|
925
953
|
args: [{ standalone: true, selector: 'sky-confirm', imports: [
|
|
926
954
|
CommonModule,
|
|
@@ -930,10 +958,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.1", ngImpor
|
|
|
930
958
|
SkyModalsResourcesModule,
|
|
931
959
|
SkyThemeModule,
|
|
932
960
|
], template: "<div class=\"sky-confirm\" [ngClass]=\"{ 'sky-confirm-type-ok': isOkType }\">\n <sky-modal\n ariaRole=\"alertdialog\"\n [ariaLabelledBy]=\"confirmMessage.id\"\n [ariaDescribedBy]=\"body ? bodyId : undefined\"\n >\n <sky-modal-content class=\"sky-confirm-content\">\n <!--\n The following \"magic comment\" keeps Prettier from adding line breaks\n inside the div and causing leading and trailing whitespace when\n `preserveWhiteSpace` is `true`.\n https://prettier.io/blog/2018/11/07/1.15.0.html#whitespace-sensitive-formatting\n -->\n <!-- display: inline -->\n <div\n class=\"sky-confirm-message\"\n [ngClass]=\"{\n 'sky-confirm-preserve-white-space': preserveWhiteSpace\n }\"\n [skyThemeClass]=\"{\n 'sky-font-display-4': 'default',\n 'sky-font-heading-1 sky-font-display-3': 'modern'\n }\"\n skyId\n #confirmMessage=\"skyId\"\n >{{ message }}</div\n >\n\n <!--\n The following \"magic comment\" keeps Prettier from adding line breaks\n inside the div and causing leading and trailing whitespace when\n `preserveWhiteSpace` is `true`.\n https://prettier.io/blog/2018/11/07/1.15.0.html#whitespace-sensitive-formatting\n -->\n <!-- display: inline -->\n <div\n *ngIf=\"body\"\n class=\"sky-confirm-body\"\n [id]=\"bodyId\"\n [ngClass]=\"{\n 'sky-confirm-preserve-white-space': preserveWhiteSpace\n }\"\n >{{ body }}</div\n >\n\n <div class=\"sky-confirm-buttons\">\n <button\n *ngFor=\"let button of buttons\"\n type=\"button\"\n class=\"sky-btn\"\n [ngClass]=\"'sky-btn-' + button.styleType\"\n [skyThemeClass]=\"{\n 'sky-margin-inline-sm': 'modern',\n 'sky-margin-inline-compact': 'default'\n }\"\n (click)=\"close(button)\"\n [attr.autofocus]=\"button.autofocus ? 'autofocus' : null\"\n >\n {{ button.text }}\n </button>\n </div>\n </sky-modal-content>\n </sky-modal>\n</div>\n", styles: [".sky-confirm{--sky-confirm-body-margin-top: var(--sky-margin-stacked-sm);--sky-confirm-buttons-margin-top: var(--sky-margin-stacked-xl);--sky-confirm-content-padding: 0;--sky-confirm-message-padding-bottom: 0}:host-context(.sky-theme-modern) .sky-confirm{--sky-confirm-body-margin-top: 0;--sky-confirm-buttons-margin-top: var(--sky-margin-stacked-lg);--sky-confirm-content-padding: var(--sky-margin-stacked-lg) var(--sky-margin-inline-xl);--sky-confirm-message-padding-bottom: var(--sky-margin-stacked-lg)}.sky-theme-modern .sky-confirm{--sky-confirm-body-margin-top: 0;--sky-confirm-buttons-margin-top: var(--sky-margin-stacked-lg);--sky-confirm-content-padding: var(--sky-margin-stacked-lg) var(--sky-margin-inline-xl);--sky-confirm-message-padding-bottom: var(--sky-margin-stacked-lg)}.sky-confirm-content{padding:var(--sky-confirm-content-padding)}.sky-confirm-message{margin-top:var(--sky-margin-stacked-xs);padding-bottom:var(--sky-confirm-message-padding-bottom)}.sky-confirm-body{margin-top:var(--sky-confirm-body-margin-top)}.sky-confirm-buttons{margin-top:var(--sky-confirm-buttons-margin-top)}.sky-confirm-preserve-white-space{white-space:pre-wrap}\n"] }]
|
|
933
|
-
}], ctorParameters: () => [
|
|
934
|
-
type: Inject,
|
|
935
|
-
args: [SKY_CONFIRM_CONFIG]
|
|
936
|
-
}] }, { type: SkyModalInstance }, { type: i2$1.SkyLibResourcesService }, { type: i1.SkyIdService }] });
|
|
961
|
+
}], ctorParameters: () => [] });
|
|
937
962
|
|
|
938
963
|
/**
|
|
939
964
|
* Provided by the modal service to give the modal host
|
|
@@ -944,10 +969,10 @@ class SkyModalHostContext {
|
|
|
944
969
|
constructor(args) {
|
|
945
970
|
this.args = args;
|
|
946
971
|
}
|
|
947
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
948
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
972
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalHostContext, deps: [{ token: 'SkyModalHostContextArgs' }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
973
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalHostContext }); }
|
|
949
974
|
}
|
|
950
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
975
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalHostContext, decorators: [{
|
|
951
976
|
type: Injectable
|
|
952
977
|
}], ctorParameters: () => [{ type: undefined, decorators: [{
|
|
953
978
|
type: Inject,
|
|
@@ -1042,10 +1067,10 @@ class SkyModalAdapterService {
|
|
|
1042
1067
|
topModal.nativeElement.previousElementSibling.removeAttribute('aria-hidden');
|
|
1043
1068
|
}
|
|
1044
1069
|
}
|
|
1045
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
1046
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
1070
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalAdapterService, deps: [{ token: i1.SkyAppWindowRef }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1071
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalAdapterService }); }
|
|
1047
1072
|
}
|
|
1048
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
1073
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalAdapterService, decorators: [{
|
|
1049
1074
|
type: Injectable
|
|
1050
1075
|
}], ctorParameters: () => [{ type: i1.SkyAppWindowRef }] });
|
|
1051
1076
|
|
|
@@ -1173,10 +1198,10 @@ class SkyModalHostComponent {
|
|
|
1173
1198
|
instance.close();
|
|
1174
1199
|
}
|
|
1175
1200
|
}
|
|
1176
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
1177
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
1201
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalHostComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1202
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.2.4", type: SkyModalHostComponent, isStandalone: true, selector: "sky-modal-host", viewQueries: [{ propertyName: "target", first: true, predicate: ["target"], descendants: true, read: ViewContainerRef, static: true }], ngImport: i0, template: "<div\n class=\"sky-modal-host-backdrop\"\n [hidden]=\"!modalOpen\"\n [ngStyle]=\"{\n zIndex: backdropZIndex\n }\"\n></div>\n<div #target></div>\n", styles: [".sky-modal-host-backdrop{background-color:#00000080;position:fixed;inset:0}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "ngmodule", type: RouterModule }, { kind: "ngmodule", type: SkyModalsResourcesModule }], viewProviders: [SkyModalAdapterService] }); }
|
|
1178
1203
|
}
|
|
1179
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
1204
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalHostComponent, decorators: [{
|
|
1180
1205
|
type: Component,
|
|
1181
1206
|
args: [{ standalone: true, selector: 'sky-modal-host', viewProviders: [SkyModalAdapterService], imports: [CommonModule, RouterModule, SkyModalsResourcesModule], template: "<div\n class=\"sky-modal-host-backdrop\"\n [hidden]=\"!modalOpen\"\n [ngStyle]=\"{\n zIndex: backdropZIndex\n }\"\n></div>\n<div #target></div>\n", styles: [".sky-modal-host-backdrop{background-color:#00000080;position:fixed;inset:0}\n"] }]
|
|
1182
1207
|
}], propDecorators: { target: [{
|
|
@@ -1267,10 +1292,10 @@ class SkyModalService {
|
|
|
1267
1292
|
});
|
|
1268
1293
|
return componentRef;
|
|
1269
1294
|
}
|
|
1270
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
1271
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
1295
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalService, deps: [{ token: i1.SkyDynamicComponentService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1296
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalService, providedIn: 'root' }); }
|
|
1272
1297
|
}
|
|
1273
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
1298
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalService, decorators: [{
|
|
1274
1299
|
type: Injectable,
|
|
1275
1300
|
args: [{
|
|
1276
1301
|
providedIn: 'root',
|
|
@@ -1286,10 +1311,10 @@ class SkyModalLegacyService extends SkyModalService {
|
|
|
1286
1311
|
constructor(dynamicComponentSvc) {
|
|
1287
1312
|
super(dynamicComponentSvc);
|
|
1288
1313
|
}
|
|
1289
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
1290
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
1314
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalLegacyService, deps: [{ token: i1.SkyDynamicComponentLegacyService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1315
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalLegacyService, providedIn: 'any' }); }
|
|
1291
1316
|
}
|
|
1292
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
1317
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalLegacyService, decorators: [{
|
|
1293
1318
|
type: Injectable,
|
|
1294
1319
|
args: [{
|
|
1295
1320
|
// Must be 'any' so that the modal component is created in the context of its module's injector.
|
|
@@ -1312,31 +1337,25 @@ class SkyConfirmService {
|
|
|
1312
1337
|
* @param config Specifies configuration options for the dialog.
|
|
1313
1338
|
*/
|
|
1314
1339
|
open(config) {
|
|
1315
|
-
const
|
|
1340
|
+
const confirmInstance = new SkyConfirmInstance();
|
|
1341
|
+
this.#modalService.open(SkyConfirmComponent, {
|
|
1316
1342
|
providers: [
|
|
1317
1343
|
{
|
|
1318
1344
|
provide: SKY_CONFIRM_CONFIG,
|
|
1319
1345
|
useValue: config,
|
|
1320
1346
|
},
|
|
1347
|
+
{
|
|
1348
|
+
provide: SkyConfirmInstance,
|
|
1349
|
+
useValue: confirmInstance,
|
|
1350
|
+
},
|
|
1321
1351
|
],
|
|
1322
1352
|
});
|
|
1323
|
-
const confirmInstance = new SkyConfirmInstance();
|
|
1324
|
-
modalInstance.closed.subscribe((args) => {
|
|
1325
|
-
let result = args.data;
|
|
1326
|
-
// The modal was closed using the ESC key.
|
|
1327
|
-
if (result === undefined) {
|
|
1328
|
-
result = {
|
|
1329
|
-
action: 'cancel',
|
|
1330
|
-
};
|
|
1331
|
-
}
|
|
1332
|
-
confirmInstance.notifyClosed(result);
|
|
1333
|
-
});
|
|
1334
1353
|
return confirmInstance;
|
|
1335
1354
|
}
|
|
1336
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
1337
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
1355
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyConfirmService, deps: [{ token: SkyModalService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1356
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyConfirmService, providedIn: 'root' }); }
|
|
1338
1357
|
}
|
|
1339
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
1358
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyConfirmService, decorators: [{
|
|
1340
1359
|
type: Injectable,
|
|
1341
1360
|
args: [{
|
|
1342
1361
|
providedIn: 'root',
|
|
@@ -1350,10 +1369,10 @@ class SkyModalFooterComponent {
|
|
|
1350
1369
|
constructor() {
|
|
1351
1370
|
this.errorsSvc = inject(SkyModalErrorsService);
|
|
1352
1371
|
}
|
|
1353
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
1354
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
1372
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalFooterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1373
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.2.4", type: SkyModalFooterComponent, isStandalone: true, selector: "sky-modal-footer", ngImport: i0, template: "<div class=\"sky-modal-footer-container sky-padding-even-large\">\n <div aria-live=\"polite\">\n <div\n *ngIf=\"errorsSvc.formErrors | async as formErrors\"\n class=\"sky-modal-footer-errors sky-margin-stacked-lg\"\n >\n <sky-status-indicator\n *ngFor=\"let formError of formErrors\"\n [ngClass]=\"{\n 'sky-margin-stacked-lg':\n formErrors.indexOf(formError) < formErrors.length - 1,\n 'footer-error': true\n }\"\n descriptionType=\"error\"\n indicatorType=\"danger\"\n >\n {{ formError.message }}\n </sky-status-indicator>\n </div>\n </div>\n <ng-content />\n</div>\n", styles: [".sky-modal-footer-container{background-color:#fff;border-top:1px solid #e2e3e4}.sky-modal-footer-container .sky-btn-link:first-child{margin-left:-12px}.sky-modal-footer-container .sky-btn+.sky-btn{margin-left:10px}.sky-modal-footer-container .sky-btn+.sky-btn-link{margin-left:-2px}.sky-modal-footer-container .sky-modal-footer-errors{max-height:100px;overflow-y:auto}.sky-modal-footer-container .sky-modal-footer-errors .footer-error{display:block}.sky-theme-modern .sky-modal-footer-container{border-top:none;padding:20px 30px}.sky-theme-modern .sky-modal-footer-container .sky-btn-link:first-child{margin-left:0}.sky-theme-modern .sky-modal-footer-container .sky-btn+.sky-btn-link{margin-left:var(--sky-compat-modal-footer-adjacent-btn-btn-link-margin, 10px)}.sky-theme-modern-dark .sky-modal-footer-container{background-color:transparent}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "ngmodule", type: SkyStatusIndicatorModule }, { kind: "component", type: i2.λ10, selector: "sky-status-indicator", inputs: ["indicatorType", "descriptionType", "customDescription"] }], encapsulation: i0.ViewEncapsulation.None }); }
|
|
1355
1374
|
}
|
|
1356
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
1375
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalFooterComponent, decorators: [{
|
|
1357
1376
|
type: Component,
|
|
1358
1377
|
args: [{ standalone: true, selector: 'sky-modal-footer', encapsulation: ViewEncapsulation.None, imports: [CommonModule, SkyStatusIndicatorModule], template: "<div class=\"sky-modal-footer-container sky-padding-even-large\">\n <div aria-live=\"polite\">\n <div\n *ngIf=\"errorsSvc.formErrors | async as formErrors\"\n class=\"sky-modal-footer-errors sky-margin-stacked-lg\"\n >\n <sky-status-indicator\n *ngFor=\"let formError of formErrors\"\n [ngClass]=\"{\n 'sky-margin-stacked-lg':\n formErrors.indexOf(formError) < formErrors.length - 1,\n 'footer-error': true\n }\"\n descriptionType=\"error\"\n indicatorType=\"danger\"\n >\n {{ formError.message }}\n </sky-status-indicator>\n </div>\n </div>\n <ng-content />\n</div>\n", styles: [".sky-modal-footer-container{background-color:#fff;border-top:1px solid #e2e3e4}.sky-modal-footer-container .sky-btn-link:first-child{margin-left:-12px}.sky-modal-footer-container .sky-btn+.sky-btn{margin-left:10px}.sky-modal-footer-container .sky-btn+.sky-btn-link{margin-left:-2px}.sky-modal-footer-container .sky-modal-footer-errors{max-height:100px;overflow-y:auto}.sky-modal-footer-container .sky-modal-footer-errors .footer-error{display:block}.sky-theme-modern .sky-modal-footer-container{border-top:none;padding:20px 30px}.sky-theme-modern .sky-modal-footer-container .sky-btn-link:first-child{margin-left:0}.sky-theme-modern .sky-modal-footer-container .sky-btn+.sky-btn-link{margin-left:var(--sky-compat-modal-footer-adjacent-btn-btn-link-margin, 10px)}.sky-theme-modern-dark .sky-modal-footer-container{background-color:transparent}\n"] }]
|
|
1359
1378
|
}] });
|
|
@@ -1362,10 +1381,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.1", ngImpor
|
|
|
1362
1381
|
* Specifies a header for the modal.
|
|
1363
1382
|
*/
|
|
1364
1383
|
class SkyModalHeaderComponent {
|
|
1365
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
1366
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
1384
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1385
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.2.4", type: SkyModalHeaderComponent, isStandalone: true, selector: "sky-modal-header", ngImport: i0, template: "<h2\n class=\"sky-font-emphasized\"\n [skyThemeClass]=\"{\n 'sky-font-heading-4': 'default',\n 'sky-font-display-3': 'modern'\n }\"\n skyTrim\n>\n <ng-content />\n</h2>\n<span class=\"sky-control-help-container\" skyTrim\n ><ng-content select=\".sky-control-help\"></ng-content\n></span>\n", styles: ["h2{margin:0;line-height:1.2;display:inline}:host-context(.sky-theme-modern.sky-theme-mode-dark) h2{color:#fbfcfe}.sky-theme-modern.sky-theme-mode-dark h2{color:#fbfcfe}\n"], dependencies: [{ kind: "ngmodule", type: SkyThemeModule }, { kind: "directive", type: i3.λ2, selector: "[skyThemeClass]", inputs: ["class", "skyThemeClass"] }, { kind: "ngmodule", type: SkyTrimModule }, { kind: "directive", type: i1.λ4, selector: "[skyTrim]" }] }); }
|
|
1367
1386
|
}
|
|
1368
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
1387
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalHeaderComponent, decorators: [{
|
|
1369
1388
|
type: Component,
|
|
1370
1389
|
args: [{ standalone: true, selector: 'sky-modal-header', imports: [SkyThemeModule, SkyTrimModule], template: "<h2\n class=\"sky-font-emphasized\"\n [skyThemeClass]=\"{\n 'sky-font-heading-4': 'default',\n 'sky-font-display-3': 'modern'\n }\"\n skyTrim\n>\n <ng-content />\n</h2>\n<span class=\"sky-control-help-container\" skyTrim\n ><ng-content select=\".sky-control-help\"></ng-content\n></span>\n", styles: ["h2{margin:0;line-height:1.2;display:inline}:host-context(.sky-theme-modern.sky-theme-mode-dark) h2{color:#fbfcfe}.sky-theme-modern.sky-theme-mode-dark h2{color:#fbfcfe}\n"] }]
|
|
1371
1390
|
}] });
|
|
@@ -1438,10 +1457,10 @@ class SkyModalIsDirtyDirective {
|
|
|
1438
1457
|
handler.closeModal();
|
|
1439
1458
|
}
|
|
1440
1459
|
}
|
|
1441
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
1442
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.
|
|
1460
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalIsDirtyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
1461
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.2.4", type: SkyModalIsDirtyDirective, isStandalone: true, selector: "sky-modal[isDirty]", inputs: { isDirty: "isDirty" }, host: { properties: { "attr.data-sky-modal-is-dirty": "this.isDirty" } }, ngImport: i0 }); }
|
|
1443
1462
|
}
|
|
1444
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
1463
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalIsDirtyDirective, decorators: [{
|
|
1445
1464
|
type: Directive,
|
|
1446
1465
|
args: [{
|
|
1447
1466
|
standalone: true,
|
|
@@ -1458,8 +1477,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.1", ngImpor
|
|
|
1458
1477
|
}] } });
|
|
1459
1478
|
|
|
1460
1479
|
class SkyModalModule {
|
|
1461
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
1462
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.
|
|
1480
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
1481
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.2.4", ngImport: i0, type: SkyModalModule, imports: [SkyModalComponent,
|
|
1463
1482
|
SkyModalContentComponent,
|
|
1464
1483
|
SkyModalFooterComponent,
|
|
1465
1484
|
SkyModalHeaderComponent,
|
|
@@ -1468,11 +1487,11 @@ class SkyModalModule {
|
|
|
1468
1487
|
SkyModalFooterComponent,
|
|
1469
1488
|
SkyModalHeaderComponent,
|
|
1470
1489
|
SkyModalIsDirtyDirective] }); }
|
|
1471
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.
|
|
1490
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalModule, imports: [SkyModalComponent,
|
|
1472
1491
|
SkyModalFooterComponent,
|
|
1473
1492
|
SkyModalHeaderComponent] }); }
|
|
1474
1493
|
}
|
|
1475
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
1494
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: SkyModalModule, decorators: [{
|
|
1476
1495
|
type: NgModule,
|
|
1477
1496
|
args: [{
|
|
1478
1497
|
imports: [
|