valtech-components 4.0.1032 → 4.0.1033
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/esm2022/lib/components/organisms/confirmation-dialog-v2/confirmation-dialog-v2.component.mjs +46 -5
- package/esm2022/lib/services/confirmation-dialog/confirmation-dialog.service.mjs +9 -1
- package/esm2022/lib/services/confirmation-dialog/types.mjs +1 -1
- package/esm2022/lib/version.mjs +2 -2
- package/fesm2022/valtech-components.mjs +54 -5
- package/fesm2022/valtech-components.mjs.map +1 -1
- package/lib/components/organisms/confirmation-dialog-v2/confirmation-dialog-v2.component.d.ts +9 -1
- package/lib/services/confirmation-dialog/confirmation-dialog.service.d.ts +6 -1
- package/lib/services/confirmation-dialog/types.d.ts +9 -0
- package/lib/version.d.ts +1 -1
- package/package.json +1 -1
package/lib/components/organisms/confirmation-dialog-v2/confirmation-dialog-v2.component.d.ts
CHANGED
|
@@ -27,12 +27,20 @@ export declare class ConfirmationDialogV2Component {
|
|
|
27
27
|
confirmText: string;
|
|
28
28
|
cancelText: string;
|
|
29
29
|
theme: 'core' | 'native';
|
|
30
|
+
input?: {
|
|
31
|
+
label?: string;
|
|
32
|
+
placeholder?: string;
|
|
33
|
+
value?: string;
|
|
34
|
+
maxlength?: number;
|
|
35
|
+
};
|
|
30
36
|
/** Inyectado por `ModalService.open`/`openSheet` — cierra desde dentro. */
|
|
31
37
|
_modalRef?: {
|
|
32
38
|
dismiss: (data?: unknown, role?: string) => void;
|
|
33
39
|
};
|
|
40
|
+
get inputValue(): string;
|
|
41
|
+
onInput(event: Event): void;
|
|
34
42
|
confirm(): void;
|
|
35
43
|
cancel(): void;
|
|
36
44
|
static ɵfac: i0.ɵɵFactoryDeclaration<ConfirmationDialogV2Component, never>;
|
|
37
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<ConfirmationDialogV2Component, "val-confirmation-dialog-v2", never, { "title": { "alias": "title"; "required": false; }; "message": { "alias": "message"; "required": false; }; "confirmText": { "alias": "confirmText"; "required": false; }; "cancelText": { "alias": "cancelText"; "required": false; }; "theme": { "alias": "theme"; "required": false; }; "_modalRef": { "alias": "_modalRef"; "required": false; }; }, {}, never, never, true, never>;
|
|
45
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ConfirmationDialogV2Component, "val-confirmation-dialog-v2", never, { "title": { "alias": "title"; "required": false; }; "message": { "alias": "message"; "required": false; }; "confirmText": { "alias": "confirmText"; "required": false; }; "cancelText": { "alias": "cancelText"; "required": false; }; "theme": { "alias": "theme"; "required": false; }; "input": { "alias": "input"; "required": false; }; "_modalRef": { "alias": "_modalRef"; "required": false; }; }, {}, never, never, true, never>;
|
|
38
46
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ConfirmationDialogMetadata, ConfirmationResult, ConfirmationButton } from './types';
|
|
1
|
+
import { ConfirmationDialogMetadata, ConfirmationPromptMetadata, ConfirmationResult, ConfirmationButton } from './types';
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
/**
|
|
4
4
|
* Service for displaying confirmation dialogs.
|
|
@@ -59,6 +59,11 @@ export declare class ConfirmationDialogService {
|
|
|
59
59
|
* @returns Promise resolving to true if confirmed, false otherwise
|
|
60
60
|
*/
|
|
61
61
|
confirmSimple(title: string, message: string): Promise<boolean>;
|
|
62
|
+
prompt(options: ConfirmationPromptMetadata): Promise<ConfirmationResult & {
|
|
63
|
+
data?: {
|
|
64
|
+
value: string;
|
|
65
|
+
};
|
|
66
|
+
}>;
|
|
62
67
|
/**
|
|
63
68
|
* Shows a destructive action confirmation with red confirm button.
|
|
64
69
|
* @param options - Configuration for the dialog
|
|
@@ -50,6 +50,15 @@ export interface ConfirmationDialogMetadata {
|
|
|
50
50
|
/** `core` (neutro, negro/blanco) o `native` (usa --ion-color-primary de la app). Default `core`. */
|
|
51
51
|
theme?: 'core' | 'native';
|
|
52
52
|
}
|
|
53
|
+
export interface ConfirmationPromptInput {
|
|
54
|
+
label?: string;
|
|
55
|
+
placeholder?: string;
|
|
56
|
+
value?: string;
|
|
57
|
+
maxlength?: number;
|
|
58
|
+
}
|
|
59
|
+
export interface ConfirmationPromptMetadata extends ConfirmationDialogMetadata {
|
|
60
|
+
input: ConfirmationPromptInput;
|
|
61
|
+
}
|
|
53
62
|
/**
|
|
54
63
|
* Result from confirmation dialog.
|
|
55
64
|
*/
|
package/lib/version.d.ts
CHANGED