@festo-ui/angular 5.0.0-dev.147 → 5.0.0-dev.148
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/esm2020/lib/modals/prompt/prompt.component.mjs +11 -5
- package/fesm2015/festo-ui-angular.mjs +11 -4
- package/fesm2015/festo-ui-angular.mjs.map +1 -1
- package/fesm2020/festo-ui-angular.mjs +10 -4
- package/fesm2020/festo-ui-angular.mjs.map +1 -1
- package/lib/modals/prompt/prompt.component.d.ts +2 -0
- package/package.json +1 -1
|
@@ -2981,6 +2981,9 @@ class FngPromptComponent {
|
|
|
2981
2981
|
if (event.key === 'Esc' || event.key === 'Escape') {
|
|
2982
2982
|
this.onClose();
|
|
2983
2983
|
}
|
|
2984
|
+
if (event.key === 'Enter') {
|
|
2985
|
+
this.onOk();
|
|
2986
|
+
}
|
|
2984
2987
|
}
|
|
2985
2988
|
ngOnInit() {
|
|
2986
2989
|
const text = this.data.value || '';
|
|
@@ -3002,8 +3005,8 @@ class FngPromptComponent {
|
|
|
3002
3005
|
this.handleErrors();
|
|
3003
3006
|
}
|
|
3004
3007
|
ngAfterViewInit() {
|
|
3005
|
-
if (this.
|
|
3006
|
-
this.
|
|
3008
|
+
if (this.inputField) {
|
|
3009
|
+
(this.inputField.inputElement?.nativeElement).focus();
|
|
3007
3010
|
}
|
|
3008
3011
|
}
|
|
3009
3012
|
ngOnDestroy() {
|
|
@@ -3035,10 +3038,10 @@ class FngPromptComponent {
|
|
|
3035
3038
|
}
|
|
3036
3039
|
}
|
|
3037
3040
|
FngPromptComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.1", ngImport: i0, type: FngPromptComponent, deps: [{ token: i3.FormBuilder }], target: i0.ɵɵFactoryTarget.Component });
|
|
3038
|
-
FngPromptComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.1.1", type: FngPromptComponent, isStandalone: true, selector: "fng-prompt", inputs: { data: "data" }, outputs: { close: "close", cancel: "cancel", ok: "ok" }, host: { listeners: { "window:keyup": "onKeyUp($event)" } }, viewQueries: [{ propertyName: "closeBtn", first: true, predicate: ["closeBtn"], descendants: true }], ngImport: i0, template: "<div class=\"fwe-modal\">\n <div class=\"fwe-modal-close\">\n <button type=\"button\" aria-label=\"Close\" #closeBtn class=\"fwe-btn fwe-btn-link fwe-dark\" (click)=\"onClose()\">\n <i aria-hidden=\"true\" class=\"fwe-icon fwe-icon-close-small\"></i>\n <span class=\"fwe-sr-only\">Close</span>\n </button>\n </div>\n <div class=\"fwe-modal-header\">\n <h2 *ngIf=\"data.subtitle\" class=\"fwe-modal-h2\">{{ data.subtitle }}</h2>\n <h1 class=\"fwe-modal-h1\">{{ data.title }}</h1>\n </div>\n <form [formGroup]=\"form\" class=\"fwe-modal-body\">\n <fng-text-input\n type=\"text\"\n [label]=\"data.label\"\n formControlName=\"text\"\n [error]=\"error\"\n [hint]=\"data.hint\"\n [placeholder]=\"data.placeholder\"\n >\n </fng-text-input>\n </form>\n <div class=\"fwe-modal-footer\" *ngIf=\"data.cancel || data.ok\">\n <div class=\"fwe-modal-buttons\">\n <button *ngIf=\"data.cancel\" type=\"button\" aria-label=\"Cancel\" class=\"fwe-btn fwe-btn-lg\" (click)=\"onCancel()\">\n {{ data.cancel }}\n </button>\n <button *ngIf=\"data.ok\" type=\"button\" aria-label=\"Ok\" class=\"fwe-btn fwe-btn-hero fwe-btn-lg\" (click)=\"onOk()\">\n {{ data.ok }}\n </button>\n </div>\n </div>\n</div>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: FngTextInputComponent, selector: "fng-text-input", inputs: ["label", "type", "readonly", "step", "min", "max", "tabindex", "placeholder", "name", "disabled", "value", "required", "error", "hint"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
3041
|
+
FngPromptComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.1.1", type: FngPromptComponent, isStandalone: true, selector: "fng-prompt", inputs: { data: "data" }, outputs: { close: "close", cancel: "cancel", ok: "ok" }, host: { listeners: { "window:keyup": "onKeyUp($event)" } }, viewQueries: [{ propertyName: "closeBtn", first: true, predicate: ["closeBtn"], descendants: true }, { propertyName: "inputField", first: true, predicate: ["inputField"], descendants: true }], ngImport: i0, template: "<div class=\"fwe-modal\">\n <div class=\"fwe-modal-close\">\n <button type=\"button\" aria-label=\"Close\" #closeBtn class=\"fwe-btn fwe-btn-link fwe-dark\" (click)=\"onClose()\">\n <i aria-hidden=\"true\" class=\"fwe-icon fwe-icon-close-small\"></i>\n <span class=\"fwe-sr-only\">Close</span>\n </button>\n </div>\n <div class=\"fwe-modal-header\">\n <h2 *ngIf=\"data.subtitle\" class=\"fwe-modal-h2\">{{ data.subtitle }}</h2>\n <h1 class=\"fwe-modal-h1\">{{ data.title }}</h1>\n </div>\n <form [formGroup]=\"form\" class=\"fwe-modal-body\">\n <fng-text-input\n #inputField\n type=\"text\"\n [label]=\"data.label\"\n formControlName=\"text\"\n [error]=\"error\"\n [hint]=\"data.hint\"\n [placeholder]=\"data.placeholder\"\n >\n </fng-text-input>\n </form>\n <div class=\"fwe-modal-footer\" *ngIf=\"data.cancel || data.ok\">\n <div class=\"fwe-modal-buttons\">\n <button *ngIf=\"data.cancel\" type=\"button\" aria-label=\"Cancel\" class=\"fwe-btn fwe-btn-lg\" (click)=\"onCancel()\">\n {{ data.cancel }}\n </button>\n <button *ngIf=\"data.ok\" type=\"button\" aria-label=\"Ok\" class=\"fwe-btn fwe-btn-hero fwe-btn-lg\" (click)=\"onOk()\">\n {{ data.ok }}\n </button>\n </div>\n </div>\n</div>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: FngTextInputComponent, selector: "fng-text-input", inputs: ["label", "type", "readonly", "step", "min", "max", "tabindex", "placeholder", "name", "disabled", "value", "required", "error", "hint"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
3039
3042
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.1", ngImport: i0, type: FngPromptComponent, decorators: [{
|
|
3040
3043
|
type: Component,
|
|
3041
|
-
args: [{ standalone: true, imports: [ReactiveFormsModule, FormsModule, CommonModule, FngTextInputComponent], selector: 'fng-prompt', encapsulation: ViewEncapsulation.None, template: "<div class=\"fwe-modal\">\n <div class=\"fwe-modal-close\">\n <button type=\"button\" aria-label=\"Close\" #closeBtn class=\"fwe-btn fwe-btn-link fwe-dark\" (click)=\"onClose()\">\n <i aria-hidden=\"true\" class=\"fwe-icon fwe-icon-close-small\"></i>\n <span class=\"fwe-sr-only\">Close</span>\n </button>\n </div>\n <div class=\"fwe-modal-header\">\n <h2 *ngIf=\"data.subtitle\" class=\"fwe-modal-h2\">{{ data.subtitle }}</h2>\n <h1 class=\"fwe-modal-h1\">{{ data.title }}</h1>\n </div>\n <form [formGroup]=\"form\" class=\"fwe-modal-body\">\n <fng-text-input\n type=\"text\"\n [label]=\"data.label\"\n formControlName=\"text\"\n [error]=\"error\"\n [hint]=\"data.hint\"\n [placeholder]=\"data.placeholder\"\n >\n </fng-text-input>\n </form>\n <div class=\"fwe-modal-footer\" *ngIf=\"data.cancel || data.ok\">\n <div class=\"fwe-modal-buttons\">\n <button *ngIf=\"data.cancel\" type=\"button\" aria-label=\"Cancel\" class=\"fwe-btn fwe-btn-lg\" (click)=\"onCancel()\">\n {{ data.cancel }}\n </button>\n <button *ngIf=\"data.ok\" type=\"button\" aria-label=\"Ok\" class=\"fwe-btn fwe-btn-hero fwe-btn-lg\" (click)=\"onOk()\">\n {{ data.ok }}\n </button>\n </div>\n </div>\n</div>\n" }]
|
|
3044
|
+
args: [{ standalone: true, imports: [ReactiveFormsModule, FormsModule, CommonModule, FngTextInputComponent], selector: 'fng-prompt', encapsulation: ViewEncapsulation.None, template: "<div class=\"fwe-modal\">\n <div class=\"fwe-modal-close\">\n <button type=\"button\" aria-label=\"Close\" #closeBtn class=\"fwe-btn fwe-btn-link fwe-dark\" (click)=\"onClose()\">\n <i aria-hidden=\"true\" class=\"fwe-icon fwe-icon-close-small\"></i>\n <span class=\"fwe-sr-only\">Close</span>\n </button>\n </div>\n <div class=\"fwe-modal-header\">\n <h2 *ngIf=\"data.subtitle\" class=\"fwe-modal-h2\">{{ data.subtitle }}</h2>\n <h1 class=\"fwe-modal-h1\">{{ data.title }}</h1>\n </div>\n <form [formGroup]=\"form\" class=\"fwe-modal-body\">\n <fng-text-input\n #inputField\n type=\"text\"\n [label]=\"data.label\"\n formControlName=\"text\"\n [error]=\"error\"\n [hint]=\"data.hint\"\n [placeholder]=\"data.placeholder\"\n >\n </fng-text-input>\n </form>\n <div class=\"fwe-modal-footer\" *ngIf=\"data.cancel || data.ok\">\n <div class=\"fwe-modal-buttons\">\n <button *ngIf=\"data.cancel\" type=\"button\" aria-label=\"Cancel\" class=\"fwe-btn fwe-btn-lg\" (click)=\"onCancel()\">\n {{ data.cancel }}\n </button>\n <button *ngIf=\"data.ok\" type=\"button\" aria-label=\"Ok\" class=\"fwe-btn fwe-btn-hero fwe-btn-lg\" (click)=\"onOk()\">\n {{ data.ok }}\n </button>\n </div>\n </div>\n</div>\n" }]
|
|
3042
3045
|
}], ctorParameters: function () { return [{ type: i3.FormBuilder }]; }, propDecorators: { data: [{
|
|
3043
3046
|
type: Input
|
|
3044
3047
|
}], close: [{
|
|
@@ -3050,6 +3053,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.1", ngImpor
|
|
|
3050
3053
|
}], closeBtn: [{
|
|
3051
3054
|
type: ViewChild,
|
|
3052
3055
|
args: ['closeBtn']
|
|
3056
|
+
}], inputField: [{
|
|
3057
|
+
type: ViewChild,
|
|
3058
|
+
args: ['inputField']
|
|
3053
3059
|
}], onKeyUp: [{
|
|
3054
3060
|
type: HostListener,
|
|
3055
3061
|
args: ['window:keyup', ['$event']]
|