@skyux/modals 6.18.0 → 6.19.0
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
CHANGED
|
@@ -2456,12 +2456,18 @@
|
|
|
2456
2456
|
"isOptional": true
|
|
2457
2457
|
},
|
|
2458
2458
|
"comment": {
|
|
2459
|
-
"shortText": "Indicates whether to place focus on this button by default."
|
|
2459
|
+
"shortText": "Indicates whether to place focus on this button by default.",
|
|
2460
|
+
"tags": [
|
|
2461
|
+
{
|
|
2462
|
+
"tag": "deprecated",
|
|
2463
|
+
"text": "The confirm component automatically focuses the first interactive\nelement of the dialog.\n"
|
|
2464
|
+
}
|
|
2465
|
+
]
|
|
2460
2466
|
},
|
|
2461
2467
|
"sources": [
|
|
2462
2468
|
{
|
|
2463
2469
|
"fileName": "projects/modals/src/modules/confirm/confirm-button-config.ts",
|
|
2464
|
-
"line":
|
|
2470
|
+
"line": 23,
|
|
2465
2471
|
"character": 2
|
|
2466
2472
|
}
|
|
2467
2473
|
],
|
|
@@ -3008,12 +3014,12 @@
|
|
|
3008
3014
|
{
|
|
3009
3015
|
"fileName": "confirm-demo.component.html",
|
|
3010
3016
|
"filePath": "/projects/modals/documentation/code-examples/confirm/confirm-demo.component.html",
|
|
3011
|
-
"rawContents": "<button\n aria-haspopup=\"dialog\"\n class=\"sky-btn sky-btn-default sky-margin-inline-
|
|
3017
|
+
"rawContents": "<button\n aria-haspopup=\"dialog\"\n class=\"sky-btn sky-btn-default sky-margin-inline-default\"\n type=\"button\"\n (click)=\"openOKConfirm()\"\n>\n OK confirm\n</button>\n\n<button\n aria-haspopup=\"dialog\"\n class=\"sky-btn sky-btn-default sky-margin-inline-default\"\n type=\"button\"\n (click)=\"openTwoActionConfirm()\"\n>\n Confirm with two actions\n</button>\n\n<button\n aria-haspopup=\"dialog\"\n class=\"sky-btn sky-btn-default sky-margin-inline-default\"\n type=\"button\"\n (click)=\"openThreeActionConfirm()\"\n>\n Confirm with three actions\n</button>\n\n<button\n aria-haspopup=\"dialog\"\n class=\"sky-btn sky-btn-default sky-margin-inline-default\"\n type=\"button\"\n (click)=\"openDeleteConfirm()\"\n>\n Confirm with delete button\n</button>\n\n<p *ngIf=\"selectedAction && selectedText\">\n You selected the \"{{ selectedText }}\" button, which has an action of \"{{\n selectedAction\n }}.\"\n</p>\n<p *ngIf=\"selectedAction && !selectedText\">\n You selected the \"{{ selectedAction }}\" action.\n</p>\n"
|
|
3012
3018
|
},
|
|
3013
3019
|
{
|
|
3014
3020
|
"fileName": "confirm-demo.component.ts",
|
|
3015
3021
|
"filePath": "/projects/modals/documentation/code-examples/confirm/confirm-demo.component.ts",
|
|
3016
|
-
"rawContents": "import { Component } from '@angular/core';\nimport {\n SkyConfirmButtonConfig,\n SkyConfirmInstance,\n SkyConfirmService,\n SkyConfirmType,\n} from '@skyux/modals';\n\n@Component({\n selector: 'app-confirm-demo',\n templateUrl: './confirm-demo.component.html',\n})\nexport class ConfirmDemoComponent {\n public selectedAction: string | undefined;\n\n public selectedText: string | undefined;\n\n #confirmSvc: SkyConfirmService;\n\n constructor(confirmSvc: SkyConfirmService) {\n this.#confirmSvc = confirmSvc;\n }\n\n public openOKConfirm(): void {\n const dialog: SkyConfirmInstance = this.#confirmSvc.open({\n message:\n '
|
|
3022
|
+
"rawContents": "import { Component } from '@angular/core';\nimport {\n SkyConfirmButtonConfig,\n SkyConfirmInstance,\n SkyConfirmService,\n SkyConfirmType,\n} from '@skyux/modals';\n\n@Component({\n selector: 'app-confirm-demo',\n templateUrl: './confirm-demo.component.html',\n})\nexport class ConfirmDemoComponent {\n public selectedAction: string | undefined;\n\n public selectedText: string | undefined;\n\n #confirmSvc: SkyConfirmService;\n\n constructor(confirmSvc: SkyConfirmService) {\n this.#confirmSvc = confirmSvc;\n }\n\n public openOKConfirm(): void {\n const dialog: SkyConfirmInstance = this.#confirmSvc.open({\n message:\n 'Cannot delete invoice because it has vendor, credit memo, or purchase order activity.',\n type: SkyConfirmType.OK,\n });\n\n dialog.closed.subscribe((result) => {\n this.selectedText = undefined;\n this.selectedAction = result.action;\n });\n }\n\n public openTwoActionConfirm() {\n const buttons: SkyConfirmButtonConfig[] = [\n { text: 'Finalize', action: 'save', styleType: 'primary' },\n { text: 'Cancel', action: 'cancel', styleType: 'link' },\n ];\n\n const dialog: SkyConfirmInstance = this.#confirmSvc.open({\n message: 'Finalize report cards?',\n body: 'Grades cannot be changed once the report cards are finalized.',\n type: SkyConfirmType.Custom,\n buttons,\n });\n\n dialog.closed.subscribe((result) => {\n this.selectedAction = result.action;\n\n for (const button of buttons) {\n if (button.action === result.action) {\n this.selectedText = button.text;\n break;\n }\n }\n });\n }\n\n public openThreeActionConfirm() {\n const buttons: SkyConfirmButtonConfig[] = [\n { text: 'Save', action: 'save', styleType: 'primary' },\n { text: 'Delete', action: 'delete' },\n { text: 'Keep working', action: 'cancel', styleType: 'link' },\n ];\n\n const dialog: SkyConfirmInstance = this.#confirmSvc.open({\n message: 'Save your changes before leaving?',\n type: SkyConfirmType.Custom,\n buttons,\n });\n\n dialog.closed.subscribe((result) => {\n this.selectedAction = result.action;\n\n for (const button of buttons) {\n if (button.action === result.action) {\n this.selectedText = button.text;\n break;\n }\n }\n });\n }\n\n public openDeleteConfirm() {\n const buttons: SkyConfirmButtonConfig[] = [\n { text: 'Delete', action: 'delete', styleType: 'danger' },\n { text: 'Cancel', action: 'cancel', styleType: 'link' },\n ];\n\n const dialog: SkyConfirmInstance = this.#confirmSvc.open({\n message: 'Delete this account?',\n body: 'Deleting this account may affect processes that are currently running.',\n type: SkyConfirmType.Custom,\n buttons,\n });\n\n dialog.closed.subscribe((result) => {\n this.selectedAction = result.action;\n\n for (const button of buttons) {\n if (button.action === result.action) {\n this.selectedText = button.text;\n break;\n }\n }\n });\n }\n}\n"
|
|
3017
3023
|
},
|
|
3018
3024
|
{
|
|
3019
3025
|
"fileName": "confirm-demo.module.ts",
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export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RoYXRcbiAgICogY2xvc2VzIHRoZSBkaWFsb2cuXG4gICAqL1xuICBzdHlsZVR5cGU/OiAncHJpbWFyeScgfCAnZGVmYXVsdCcgfCAnbGluaycgfCBzdHJpbmc7XG4gIC8qKlxuICAgKiBJbmRpY2F0ZXMgd2hldGhlciB0byBwbGFjZSBmb2N1cyBvbiB0aGlzIGJ1dHRvbiBieSBkZWZhdWx0LlxuICAgKiBAZGVwcmVjYXRlZCBUaGUgY29uZmlybSBjb21wb25lbnQgYXV0b21hdGljYWxseSBmb2N1c2VzIHRoZSBmaXJzdCBpbnRlcmFjdGl2ZVxuICAgKiBlbGVtZW50IG9mIHRoZSBkaWFsb2cuXG4gICAqL1xuICBhdXRvZm9jdXM/OiBib29sZWFuO1xufVxuIl19
|
|
@@ -17,6 +17,8 @@ export interface SkyConfirmButtonConfig {
|
|
|
17
17
|
styleType?: 'primary' | 'default' | 'link' | string;
|
|
18
18
|
/**
|
|
19
19
|
* Indicates whether to place focus on this button by default.
|
|
20
|
+
* @deprecated The confirm component automatically focuses the first interactive
|
|
21
|
+
* element of the dialog.
|
|
20
22
|
*/
|
|
21
23
|
autofocus?: boolean;
|
|
22
24
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@skyux/modals",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.19.0",
|
|
4
4
|
"author": "Blackbaud, Inc.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"blackbaud",
|
|
@@ -43,10 +43,10 @@
|
|
|
43
43
|
"@angular/common": "^13.3.2",
|
|
44
44
|
"@angular/core": "^13.3.2",
|
|
45
45
|
"@angular/router": "^13.3.2",
|
|
46
|
-
"@skyux/core": "6.
|
|
47
|
-
"@skyux/i18n": "6.
|
|
48
|
-
"@skyux/indicators": "6.
|
|
49
|
-
"@skyux/theme": "6.
|
|
46
|
+
"@skyux/core": "6.19.0",
|
|
47
|
+
"@skyux/i18n": "6.19.0",
|
|
48
|
+
"@skyux/indicators": "6.19.0",
|
|
49
|
+
"@skyux/theme": "6.19.0"
|
|
50
50
|
},
|
|
51
51
|
"dependencies": {
|
|
52
52
|
"tslib": "^2.3.1"
|