@skyux/modals 6.0.0-beta.1 → 6.0.0-beta.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 +374 -631
- package/esm2020/index.mjs +2 -2
- package/esm2020/lib/modules/confirm/confirm-button-action.mjs +1 -1
- package/esm2020/lib/modules/confirm/confirm-button-config.mjs +1 -1
- package/esm2020/lib/modules/confirm/confirm-button.mjs +1 -1
- package/esm2020/lib/modules/confirm/confirm-closed-event-args.mjs +1 -1
- package/esm2020/lib/modules/confirm/confirm-config.mjs +1 -1
- package/esm2020/lib/modules/confirm/confirm-instance.mjs +3 -3
- package/esm2020/lib/modules/confirm/confirm-modal-context.mjs +4 -2
- package/esm2020/lib/modules/confirm/confirm-type.mjs +3 -4
- package/esm2020/lib/modules/confirm/confirm.component.mjs +3 -3
- package/esm2020/lib/modules/confirm/confirm.module.mjs +4 -4
- package/esm2020/lib/modules/confirm/confirm.service.mjs +7 -8
- package/esm2020/lib/modules/modal/modal-adapter.service.mjs +3 -3
- package/esm2020/lib/modules/modal/modal-before-close-handler.mjs +4 -1
- package/esm2020/lib/modules/modal/modal-close-args.mjs +5 -1
- package/esm2020/lib/modules/modal/modal-component-adapter.service.mjs +3 -3
- package/esm2020/lib/modules/modal/modal-configuration.mjs +3 -3
- package/esm2020/lib/modules/modal/modal-content.component.mjs +3 -3
- package/esm2020/lib/modules/modal/modal-footer.component.mjs +3 -3
- package/esm2020/lib/modules/modal/modal-header.component.mjs +3 -3
- package/esm2020/lib/modules/modal/modal-host.component.mjs +3 -3
- package/esm2020/lib/modules/modal/modal-host.service.mjs +3 -3
- package/esm2020/lib/modules/modal/modal-instance.mjs +5 -10
- package/esm2020/lib/modules/modal/modal-scroll-shadow.directive.mjs +3 -3
- package/esm2020/lib/modules/modal/modal.component.mjs +38 -10
- package/esm2020/lib/modules/modal/modal.interface.mjs +1 -1
- package/esm2020/lib/modules/modal/modal.module.mjs +4 -4
- package/esm2020/lib/modules/modal/modal.service.mjs +6 -8
- package/esm2020/lib/modules/shared/sky-modals-resources.module.mjs +4 -4
- package/fesm2015/skyux-modals.mjs +113 -83
- package/fesm2015/skyux-modals.mjs.map +1 -1
- package/fesm2020/skyux-modals.mjs +113 -83
- package/fesm2020/skyux-modals.mjs.map +1 -1
- package/index.d.ts +0 -1
- package/lib/modules/confirm/confirm-button-action.d.ts +3 -0
- package/lib/modules/confirm/confirm-button-config.d.ts +6 -7
- package/lib/modules/confirm/confirm-button.d.ts +4 -0
- package/lib/modules/confirm/confirm-closed-event-args.d.ts +1 -1
- package/lib/modules/confirm/confirm-config.d.ts +3 -5
- package/lib/modules/confirm/confirm-instance.d.ts +2 -2
- package/lib/modules/confirm/confirm-modal-context.d.ts +3 -0
- package/lib/modules/confirm/confirm-type.d.ts +2 -3
- package/lib/modules/confirm/confirm.service.d.ts +3 -4
- package/lib/modules/modal/modal-before-close-handler.d.ts +3 -0
- package/lib/modules/modal/modal-close-args.d.ts +11 -0
- package/lib/modules/modal/modal-instance.d.ts +4 -7
- package/lib/modules/modal/modal.component.d.ts +8 -7
- package/lib/modules/modal/modal.interface.d.ts +1 -1
- package/lib/modules/modal/modal.service.d.ts +2 -3
- package/package.json +24 -21
|
@@ -1,4 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Contains an object with the data passed from users when
|
|
3
|
+
* a modal is closed and the reason that the modal was closed.
|
|
4
|
+
*/
|
|
1
5
|
export declare class SkyModalCloseArgs {
|
|
6
|
+
/**
|
|
7
|
+
* Indicates the reason the modal was closed.
|
|
8
|
+
* Options include `"close"`, `"save"`, and `"cancel"`.
|
|
9
|
+
*/
|
|
2
10
|
reason: string;
|
|
11
|
+
/**
|
|
12
|
+
* The data passed from users when the modal is closed.
|
|
13
|
+
*/
|
|
3
14
|
data: any;
|
|
4
15
|
}
|
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
import { Observable } from 'rxjs';
|
|
2
2
|
import { SkyModalBeforeCloseHandler } from './modal-before-close-handler';
|
|
3
3
|
import { SkyModalCloseArgs } from './modal-close-args';
|
|
4
|
-
/**
|
|
5
|
-
* Allows you to close the modal and return data from the launched modal.
|
|
6
|
-
*/
|
|
7
4
|
export declare class SkyModalInstance {
|
|
8
5
|
/**
|
|
9
6
|
* An event that the modal instance emits when it is about to close.
|
|
@@ -18,7 +15,7 @@ export declare class SkyModalInstance {
|
|
|
18
15
|
* data passed from users on close or save and a `reason` property that indicates
|
|
19
16
|
* whether the modal was saved or closed without saving.
|
|
20
17
|
* The `reason` property accepts any string value.
|
|
21
|
-
* Common examples include `cancel`, `close`, and `save`.
|
|
18
|
+
* Common examples include `"cancel"`, `"close"`, and `"save"`.
|
|
22
19
|
*/
|
|
23
20
|
get closed(): Observable<SkyModalCloseArgs>;
|
|
24
21
|
/**
|
|
@@ -39,19 +36,19 @@ export declare class SkyModalInstance {
|
|
|
39
36
|
* @param result Specifies an object to emit to subscribers of the `closed` event of the
|
|
40
37
|
* modal instance. The `SkyModalInstance` provider can be injected into a component's constructor
|
|
41
38
|
* so that this `close` function can be called from a button in the `sky-modal-footer`.
|
|
42
|
-
* @param reason Specifies the reason for the modal closing, with the default reason of `close`.
|
|
39
|
+
* @param reason Specifies the reason for the modal closing, with the default reason of `"close"`.
|
|
43
40
|
* @param ignoreBeforeClose Indicates whether to ignore the modal instance's `beforeClose` event.
|
|
44
41
|
*/
|
|
45
42
|
close(result?: any, reason?: string, ignoreBeforeClose?: boolean): void;
|
|
46
43
|
/**
|
|
47
|
-
* Closes the modal instance with `reason=cancel`.
|
|
44
|
+
* Closes the modal instance with `reason="cancel"`.
|
|
48
45
|
* @param result Specifies an object to emit to subscribers of the `closed` event of the modal
|
|
49
46
|
* instance. The `SkyModalInstance` provider can be injected into a component's constructor so
|
|
50
47
|
* that this cancel function can be called from a button in the `sky-modal-footer`.
|
|
51
48
|
*/
|
|
52
49
|
cancel(result?: any): void;
|
|
53
50
|
/**
|
|
54
|
-
* Closes the modal instance with `reason=save`.
|
|
51
|
+
* Closes the modal instance with `reason="save"`.
|
|
55
52
|
* @param result Specifies an object to emit to subscribers of the `closed` event of the modal
|
|
56
53
|
* instance. The `SkyModalInstance` provider can be injected into a component's constructor so
|
|
57
54
|
* that this `save` function can be called from a button in `the sky-modal-footer`.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { AfterViewInit, ElementRef } from '@angular/core';
|
|
2
|
-
import { SkyAppWindowRef, SkyCoreAdapterService, SkyDockService } from '@skyux/core';
|
|
1
|
+
import { AfterViewInit, ElementRef, OnDestroy } from '@angular/core';
|
|
2
|
+
import { SkyAppWindowRef, SkyCoreAdapterService, SkyDockService, SkyResizeObserverMediaQueryService } from '@skyux/core';
|
|
3
3
|
import { SkyModalComponentAdapterService } from './modal-component-adapter.service';
|
|
4
4
|
import { SkyModalConfiguration } from './modal-configuration';
|
|
5
5
|
import { SkyModalHostService } from './modal-host.service';
|
|
@@ -8,10 +8,9 @@ import * as i0 from "@angular/core";
|
|
|
8
8
|
/**
|
|
9
9
|
* Provides a common look-and-feel for modal content with options to display
|
|
10
10
|
* a common modal header, specify body content, and display a common modal footer
|
|
11
|
-
* and buttons.
|
|
12
|
-
* [write unit tests for modals](https://developer.blackbaud.com/skyux/learn/get-started/advanced/unit-test-modals).
|
|
11
|
+
* and buttons.
|
|
13
12
|
*/
|
|
14
|
-
export declare class SkyModalComponent implements AfterViewInit {
|
|
13
|
+
export declare class SkyModalComponent implements AfterViewInit, OnDestroy {
|
|
15
14
|
private hostService;
|
|
16
15
|
private config;
|
|
17
16
|
private elRef;
|
|
@@ -19,6 +18,7 @@ export declare class SkyModalComponent implements AfterViewInit {
|
|
|
19
18
|
private componentAdapter;
|
|
20
19
|
private coreAdapter;
|
|
21
20
|
private dockService;
|
|
21
|
+
private mediaQueryService?;
|
|
22
22
|
get wrapperClass(): string;
|
|
23
23
|
/**
|
|
24
24
|
* @internal
|
|
@@ -43,15 +43,16 @@ export declare class SkyModalComponent implements AfterViewInit {
|
|
|
43
43
|
modalHeaderId: string;
|
|
44
44
|
scrollShadow: SkyModalScrollShadowEventArgs;
|
|
45
45
|
private modalContentWrapperElement;
|
|
46
|
-
constructor(hostService: SkyModalHostService, config: SkyModalConfiguration, elRef: ElementRef, windowRef: SkyAppWindowRef, componentAdapter: SkyModalComponentAdapterService, coreAdapter: SkyCoreAdapterService, dockService: SkyDockService);
|
|
46
|
+
constructor(hostService: SkyModalHostService, config: SkyModalConfiguration, elRef: ElementRef, windowRef: SkyAppWindowRef, componentAdapter: SkyModalComponentAdapterService, coreAdapter: SkyCoreAdapterService, dockService: SkyDockService, mediaQueryService?: SkyResizeObserverMediaQueryService);
|
|
47
47
|
onDocumentKeyUp(event: KeyboardEvent): void;
|
|
48
48
|
onDocumentKeyDown(event: KeyboardEvent): void;
|
|
49
49
|
ngAfterViewInit(): void;
|
|
50
|
+
ngOnDestroy(): void;
|
|
50
51
|
helpButtonClick(): void;
|
|
51
52
|
closeButtonClick(): void;
|
|
52
53
|
windowResize(): void;
|
|
53
54
|
scrollShadowChange(args: SkyModalScrollShadowEventArgs): void;
|
|
54
55
|
private isSizeEqual;
|
|
55
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<SkyModalComponent, [null, null, null, null, null, null, { host: true; }]>;
|
|
56
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SkyModalComponent, [null, null, null, null, null, null, { host: true; }, { optional: true; host: true; }]>;
|
|
56
57
|
static ɵcmp: i0.ɵɵComponentDeclaration<SkyModalComponent, "sky-modal", never, { "ariaRole": "ariaRole"; "tiledBody": "tiledBody"; }, {}, never, ["sky-modal-header", "sky-modal-content", "sky-modal-footer"]>;
|
|
57
58
|
}
|
|
@@ -52,7 +52,7 @@ export interface SkyModalConfigurationInterface {
|
|
|
52
52
|
*/
|
|
53
53
|
tiledBody?: boolean;
|
|
54
54
|
/**
|
|
55
|
-
* Specifies a `helpKey` string. This property
|
|
55
|
+
* Specifies a `helpKey` string. This property displays
|
|
56
56
|
* the <i class="fa fa-question-circle" aria-hidden="true"></i> button in the modal header.
|
|
57
57
|
* When users click this button, the `helpOpened` event broadcasts the `helpKey` parameter.
|
|
58
58
|
* Blackbaud developers can use the Help Widget, which is for internal Blackbaud use only, to
|
|
@@ -3,8 +3,7 @@ import { SkyModalInstance } from './modal-instance';
|
|
|
3
3
|
import { SkyModalConfigurationInterface } from './modal.interface';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
/**
|
|
6
|
-
* A service that
|
|
7
|
-
* [write unit tests for modals](https://developer.blackbaud.com/skyux/learn/get-started/advanced/unit-test-modals).
|
|
6
|
+
* A service that launches modals.
|
|
8
7
|
* @dynamic
|
|
9
8
|
*/
|
|
10
9
|
export declare class SkyModalService {
|
|
@@ -19,7 +18,7 @@ export declare class SkyModalService {
|
|
|
19
18
|
/**
|
|
20
19
|
* Opens a modal using the specified component.
|
|
21
20
|
* @param component Determines the component to render.
|
|
22
|
-
* @param {SkyModalConfigurationInterface} config
|
|
21
|
+
* @param {SkyModalConfigurationInterface} config Specifies configuration options for the modal.
|
|
23
22
|
*/
|
|
24
23
|
open(component: any, config?: SkyModalConfigurationInterface | any[]): SkyModalInstance;
|
|
25
24
|
private getConfigFromParameter;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@skyux/modals",
|
|
3
|
-
"version": "6.0.0-beta.
|
|
3
|
+
"version": "6.0.0-beta.4",
|
|
4
4
|
"author": "Blackbaud, Inc.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"blackbaud",
|
|
@@ -15,25 +15,6 @@
|
|
|
15
15
|
"url": "https://github.com/blackbaud/skyux/issues"
|
|
16
16
|
},
|
|
17
17
|
"homepage": "https://github.com/blackbaud/skyux#readme",
|
|
18
|
-
"peerDependencies": {
|
|
19
|
-
"@angular/animations": "^13.2.7",
|
|
20
|
-
"@angular/common": "^13.2.7",
|
|
21
|
-
"@angular/core": "^13.2.7",
|
|
22
|
-
"@angular/router": "^13.2.7",
|
|
23
|
-
"@skyux/core": "6.0.0-beta.1",
|
|
24
|
-
"@skyux/i18n": "6.0.0-beta.1",
|
|
25
|
-
"@skyux/indicators": "6.0.0-beta.1",
|
|
26
|
-
"@skyux/theme": "6.0.0-beta.1"
|
|
27
|
-
},
|
|
28
|
-
"dependencies": {
|
|
29
|
-
"tslib": "^2.3.1"
|
|
30
|
-
},
|
|
31
|
-
"module": "fesm2015/skyux-modals.mjs",
|
|
32
|
-
"es2020": "fesm2020/skyux-modals.mjs",
|
|
33
|
-
"esm2020": "esm2020/skyux-modals.mjs",
|
|
34
|
-
"fesm2020": "fesm2020/skyux-modals.mjs",
|
|
35
|
-
"fesm2015": "fesm2015/skyux-modals.mjs",
|
|
36
|
-
"typings": "skyux-modals.d.ts",
|
|
37
18
|
"exports": {
|
|
38
19
|
"./package.json": {
|
|
39
20
|
"default": "./package.json"
|
|
@@ -53,7 +34,29 @@
|
|
|
53
34
|
"es2015": "./fesm2015/skyux-modals-testing.mjs",
|
|
54
35
|
"node": "./fesm2015/skyux-modals-testing.mjs",
|
|
55
36
|
"default": "./fesm2020/skyux-modals-testing.mjs"
|
|
37
|
+
},
|
|
38
|
+
"./documentation.json": {
|
|
39
|
+
"default": "./documentation.json"
|
|
56
40
|
}
|
|
57
41
|
},
|
|
42
|
+
"peerDependencies": {
|
|
43
|
+
"@angular/animations": "^13.3.2",
|
|
44
|
+
"@angular/common": "^13.3.2",
|
|
45
|
+
"@angular/core": "^13.3.2",
|
|
46
|
+
"@angular/router": "^13.3.2",
|
|
47
|
+
"@skyux/core": "6.0.0-beta.4",
|
|
48
|
+
"@skyux/i18n": "6.0.0-beta.4",
|
|
49
|
+
"@skyux/indicators": "6.0.0-beta.4",
|
|
50
|
+
"@skyux/theme": "6.0.0-beta.4"
|
|
51
|
+
},
|
|
52
|
+
"dependencies": {
|
|
53
|
+
"tslib": "^2.3.1"
|
|
54
|
+
},
|
|
55
|
+
"module": "fesm2015/skyux-modals.mjs",
|
|
56
|
+
"es2020": "fesm2020/skyux-modals.mjs",
|
|
57
|
+
"esm2020": "esm2020/skyux-modals.mjs",
|
|
58
|
+
"fesm2020": "fesm2020/skyux-modals.mjs",
|
|
59
|
+
"fesm2015": "fesm2015/skyux-modals.mjs",
|
|
60
|
+
"typings": "skyux-modals.d.ts",
|
|
58
61
|
"sideEffects": false
|
|
59
|
-
}
|
|
62
|
+
}
|