@mgdis/mg-components 5.9.1 → 5.10.1
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/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/mg-action-more_31.cjs.entry.js +345 -648
- package/dist/cjs/mg-components.cjs.js +1 -1
- package/dist/cjs/mg-item-more.cjs.entry.js +19 -43
- package/dist/cjs/{mg-menu.conf-9afe6571.js → mg-menu.conf-196151fe.js} +16 -21
- package/dist/collection/components/atoms/mg-badge/mg-badge.js +9 -12
- package/dist/collection/components/atoms/mg-button/mg-button.js +18 -27
- package/dist/collection/components/atoms/mg-card/mg-card.js +22 -15
- package/dist/collection/components/atoms/mg-character-left/mg-character-left.js +1 -4
- package/dist/collection/components/atoms/mg-divider/mg-divider.js +1 -2
- package/dist/collection/components/atoms/mg-icon/mg-icon.js +26 -23
- package/dist/collection/components/atoms/mg-input-title/mg-input-title.js +1 -4
- package/dist/collection/components/atoms/mg-tag/mg-tag.js +11 -16
- package/dist/collection/components/atoms/mg-tooltip/mg-tooltip.js +12 -34
- package/dist/collection/components/molecules/inputs/MgInput.conf.js +4 -1
- package/dist/collection/components/molecules/inputs/MgInput.js +26 -24
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.js +10 -20
- package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.js +7 -17
- package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.js +14 -34
- package/dist/collection/components/molecules/inputs/mg-input-password/mg-input-password.js +6 -13
- package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.js +10 -27
- package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.js +21 -45
- package/dist/collection/components/molecules/inputs/mg-input-text/mg-input-text.js +17 -43
- package/dist/collection/components/molecules/inputs/mg-input-textarea/mg-input-textarea.js +14 -22
- package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.js +17 -28
- package/dist/collection/components/molecules/menu/mg-menu/mg-menu.js +11 -29
- package/dist/collection/components/molecules/menu/mg-menu-item/mg-menu-item.js +20 -47
- package/dist/collection/components/molecules/mg-action-more/mg-action-more.js +11 -23
- package/dist/collection/components/molecules/mg-details/mg-details.js +1 -6
- package/dist/collection/components/molecules/mg-form/mg-form.js +8 -27
- package/dist/collection/components/molecules/mg-illustrated-message/mg-illustrated-message.js +1 -4
- package/dist/collection/components/molecules/mg-item-more/mg-item-more.js +4 -12
- package/dist/collection/components/molecules/mg-message/mg-message.js +12 -20
- package/dist/collection/components/molecules/mg-modal/mg-modal.js +8 -17
- package/dist/collection/components/molecules/mg-pagination/mg-pagination.js +11 -19
- package/dist/collection/components/molecules/mg-panel/mg-panel.js +11 -30
- package/dist/collection/components/molecules/mg-popover/mg-popover.js +8 -21
- package/dist/collection/components/molecules/mg-skip-links/mg-skip-links.js +3 -8
- package/dist/collection/components/molecules/mg-tabs/mg-tabs.js +20 -36
- package/dist/collection/locales/index.js +2 -3
- package/dist/collection/utils/behaviors.utils.js +16 -32
- package/dist/collection/utils/components.utils.js +22 -33
- package/dist/collection/utils/locale.utils.js +14 -18
- package/dist/collection/utils/unit.test.utils.js +7 -15
- package/dist/components/MgInput.js +30 -24
- package/dist/components/components.utils.js +22 -33
- package/dist/components/index2.js +16 -21
- package/dist/components/mg-action-more.js +9 -21
- package/dist/components/mg-badge2.js +9 -12
- package/dist/components/mg-button2.js +18 -27
- package/dist/components/mg-card2.js +20 -13
- package/dist/components/mg-character-left2.js +1 -4
- package/dist/components/mg-details.js +1 -6
- package/dist/components/mg-divider.js +1 -2
- package/dist/components/mg-form.js +7 -23
- package/dist/components/mg-icon2.js +26 -23
- package/dist/components/mg-illustrated-message.js +1 -4
- package/dist/components/mg-input-checkbox.js +9 -16
- package/dist/components/mg-input-date.js +6 -13
- package/dist/components/mg-input-numeric.js +13 -30
- package/dist/components/mg-input-password.js +5 -9
- package/dist/components/mg-input-radio.js +9 -23
- package/dist/components/mg-input-select2.js +20 -41
- package/dist/components/mg-input-text2.js +15 -35
- package/dist/components/mg-input-textarea.js +13 -18
- package/dist/components/mg-input-title2.js +1 -4
- package/dist/components/mg-input-toggle.js +16 -24
- package/dist/components/mg-item-more.js +18 -42
- package/dist/components/mg-menu-item2.js +17 -44
- package/dist/components/mg-menu2.js +9 -27
- package/dist/components/mg-message.js +12 -20
- package/dist/components/mg-modal.js +8 -17
- package/dist/components/mg-pagination.js +11 -19
- package/dist/components/mg-panel.js +11 -30
- package/dist/components/mg-popover2.js +8 -21
- package/dist/components/mg-skip-links.js +3 -8
- package/dist/components/mg-tabs.js +20 -36
- package/dist/components/mg-tag.js +11 -16
- package/dist/components/mg-tooltip2.js +12 -34
- package/dist/esm/loader.js +1 -1
- package/dist/esm/mg-action-more_31.entry.js +345 -648
- package/dist/esm/mg-components.js +1 -1
- package/dist/esm/mg-item-more.entry.js +19 -43
- package/dist/esm/{mg-menu.conf-881fbd82.js → mg-menu.conf-9ca023ee.js} +16 -21
- package/dist/mg-components/mg-components.esm.js +1 -1
- package/dist/mg-components/{p-67ce7cb8.entry.js → p-97aaca3e.entry.js} +1 -1
- package/dist/mg-components/p-d891e707.entry.js +1 -0
- package/dist/types/components/atoms/mg-badge/mg-badge.d.ts +2 -5
- package/dist/types/components/atoms/mg-button/mg-button.d.ts +5 -14
- package/dist/types/components/atoms/mg-card/mg-card.d.ts +11 -8
- package/dist/types/components/atoms/mg-character-left/mg-character-left.d.ts +1 -4
- package/dist/types/components/atoms/mg-divider/mg-divider.d.ts +1 -2
- package/dist/types/components/atoms/mg-icon/mg-icon.d.ts +8 -7
- package/dist/types/components/atoms/mg-input-title/mg-input-title.d.ts +1 -4
- package/dist/types/components/atoms/mg-tag/mg-tag.d.ts +3 -8
- package/dist/types/components/atoms/mg-tooltip/mg-tooltip.d.ts +11 -33
- package/dist/types/components/molecules/inputs/MgInput.conf.d.ts +2 -1
- package/dist/types/components/molecules/inputs/MgInput.d.ts +5 -6
- package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.d.ts +5 -11
- package/dist/types/components/molecules/inputs/mg-input-date/mg-input-date.d.ts +4 -11
- package/dist/types/components/molecules/inputs/mg-input-numeric/mg-input-numeric.d.ts +7 -26
- package/dist/types/components/molecules/inputs/mg-input-password/mg-input-password.d.ts +3 -7
- package/dist/types/components/molecules/inputs/mg-input-radio/mg-input-radio.d.ts +5 -18
- package/dist/types/components/molecules/inputs/mg-input-select/mg-input-select.conf.d.ts +2 -2
- package/dist/types/components/molecules/inputs/mg-input-select/mg-input-select.d.ts +9 -22
- package/dist/types/components/molecules/inputs/mg-input-text/mg-input-text.d.ts +3 -23
- package/dist/types/components/molecules/inputs/mg-input-textarea/mg-input-textarea.d.ts +4 -9
- package/dist/types/components/molecules/inputs/mg-input-toggle/mg-input-toggle.d.ts +2 -11
- package/dist/types/components/molecules/menu/mg-menu/mg-menu.d.ts +10 -29
- package/dist/types/components/molecules/menu/mg-menu-item/mg-menu-item.d.ts +21 -49
- package/dist/types/components/molecules/mg-action-more/mg-action-more.d.ts +3 -15
- package/dist/types/components/molecules/mg-details/mg-details.d.ts +1 -6
- package/dist/types/components/molecules/mg-form/mg-form.d.ts +3 -19
- package/dist/types/components/molecules/mg-illustrated-message/mg-illustrated-message.d.ts +1 -4
- package/dist/types/components/molecules/mg-item-more/mg-item-more.d.ts +2 -12
- package/dist/types/components/molecules/mg-message/mg-message.d.ts +4 -12
- package/dist/types/components/molecules/mg-modal/mg-modal.d.ts +3 -12
- package/dist/types/components/molecules/mg-pagination/mg-pagination.d.ts +5 -14
- package/dist/types/components/molecules/mg-panel/mg-panel.d.ts +4 -23
- package/dist/types/components/molecules/mg-popover/mg-popover.d.ts +3 -16
- package/dist/types/components/molecules/mg-skip-links/mg-skip-links.d.ts +2 -7
- package/dist/types/components/molecules/mg-tabs/mg-tabs.d.ts +15 -30
- package/dist/types/components.d.ts +22 -34
- package/dist/types/locales/index.d.ts +2 -3
- package/dist/types/utils/behaviors.utils.d.ts +14 -29
- package/dist/types/utils/components.utils.d.ts +19 -29
- package/dist/types/utils/locale.utils.d.ts +14 -18
- package/dist/types/utils/unit.test.utils.d.ts +11 -24
- package/package.json +11 -12
- package/dist/mg-components/p-9a93b7af.entry.js +0 -1
- /package/dist/mg-components/{p-367f92d2.js → p-0d3146d9.js} +0 -0
|
@@ -32,17 +32,14 @@ export declare class MgBadge {
|
|
|
32
32
|
/**
|
|
33
33
|
* Component classes
|
|
34
34
|
*/
|
|
35
|
-
|
|
35
|
+
classCollection: ClassList;
|
|
36
36
|
/**
|
|
37
37
|
* Check if props are well configured on init
|
|
38
|
-
*
|
|
39
|
-
* @returns {void}
|
|
40
38
|
*/
|
|
41
39
|
componentWillLoad(): void;
|
|
42
40
|
/**
|
|
43
41
|
* Render
|
|
44
|
-
*
|
|
45
|
-
* @returns {HTMLElement} HTML Element
|
|
42
|
+
* @returns HTML Element
|
|
46
43
|
*/
|
|
47
44
|
render(): HTMLElement;
|
|
48
45
|
}
|
|
@@ -69,42 +69,33 @@ export declare class MgButton {
|
|
|
69
69
|
/**
|
|
70
70
|
* Component classes
|
|
71
71
|
*/
|
|
72
|
-
|
|
72
|
+
classCollection: ClassList;
|
|
73
73
|
/**
|
|
74
74
|
* Emmited event when disabled change
|
|
75
75
|
*/
|
|
76
76
|
disabledChange: EventEmitter<MgButton['disabled']>;
|
|
77
77
|
/**
|
|
78
78
|
* Trigger actions onClick event
|
|
79
|
-
*
|
|
80
|
-
* @param {MouseEvent} event click event
|
|
81
|
-
* @returns {void}
|
|
79
|
+
* @param event - click event
|
|
82
80
|
*/
|
|
83
81
|
private handleClick;
|
|
84
82
|
/**
|
|
85
83
|
* Handle onKeydown event
|
|
86
|
-
*
|
|
87
|
-
* @param {KeyboardEvent} event keyboard event
|
|
88
|
-
* @returns {void}
|
|
84
|
+
* @param event - keyboard event
|
|
89
85
|
*/
|
|
90
86
|
private handleKeydown;
|
|
91
87
|
/**
|
|
92
88
|
* Handle onKeyup event
|
|
93
|
-
*
|
|
94
|
-
* @param {KeyboardEvent} event keyboard event
|
|
95
|
-
* @returns {void}
|
|
89
|
+
* @param event - keyboard event
|
|
96
90
|
*/
|
|
97
91
|
private handleKeyup;
|
|
98
92
|
/**
|
|
99
93
|
* Check if props are well configured on init
|
|
100
|
-
*
|
|
101
|
-
* @returns {void}
|
|
102
94
|
*/
|
|
103
95
|
componentWillLoad(): void;
|
|
104
96
|
/**
|
|
105
97
|
* Render component
|
|
106
|
-
*
|
|
107
|
-
* @returns {HTMLElement} html element
|
|
98
|
+
* @returns html element
|
|
108
99
|
*/
|
|
109
100
|
render(): HTMLElement;
|
|
110
101
|
}
|
|
@@ -7,34 +7,37 @@ export declare class MgCard {
|
|
|
7
7
|
private readonly name;
|
|
8
8
|
private readonly baseClass;
|
|
9
9
|
/*************
|
|
10
|
-
*
|
|
10
|
+
* Decorators *
|
|
11
11
|
*************/
|
|
12
12
|
/**
|
|
13
13
|
* Define variant prop
|
|
14
|
-
* Default: undefined
|
|
15
14
|
*/
|
|
16
15
|
variant: undefined | VariantType;
|
|
17
16
|
validateVariant(newValue: MgCard['variant'], oldValue?: MgCard['variant']): void;
|
|
18
17
|
/**
|
|
19
18
|
* Define variantStyle prop
|
|
20
|
-
* Default: undefined
|
|
21
19
|
*/
|
|
22
20
|
variantStyle: undefined | VariantStyleType;
|
|
23
21
|
validateVariantStyle(newValue: MgCard['variantStyle'], oldValue?: MgCard['variantStyle']): void;
|
|
24
22
|
/**
|
|
25
23
|
* Component classes
|
|
26
24
|
*/
|
|
27
|
-
|
|
25
|
+
classCollection: ClassList;
|
|
26
|
+
/**
|
|
27
|
+
* Methode to set default varianStyle props
|
|
28
|
+
* needeed has stencil doesn't know that props is mutated when updated in prop watcher
|
|
29
|
+
*/
|
|
30
|
+
private setDefaultVariantStyle;
|
|
31
|
+
/*************
|
|
32
|
+
* Lifecycle *
|
|
33
|
+
*************/
|
|
28
34
|
/**
|
|
29
35
|
* Check if props are well configured on init
|
|
30
|
-
*
|
|
31
|
-
* @returns {void}
|
|
32
36
|
*/
|
|
33
37
|
componentWillLoad(): void;
|
|
34
38
|
/**
|
|
35
39
|
* Render
|
|
36
|
-
*
|
|
37
|
-
* @returns {HTMLElement} HTML Element
|
|
40
|
+
* @returns HTML Element
|
|
38
41
|
*/
|
|
39
42
|
render(): HTMLElement;
|
|
40
43
|
}
|
|
@@ -29,14 +29,11 @@ export declare class MgCharacterLeft {
|
|
|
29
29
|
*************/
|
|
30
30
|
/**
|
|
31
31
|
* Check if props are well configured on init
|
|
32
|
-
*
|
|
33
|
-
* @returns {void}
|
|
34
32
|
*/
|
|
35
33
|
componentWillLoad(): void;
|
|
36
34
|
/**
|
|
37
35
|
* Render component
|
|
38
|
-
*
|
|
39
|
-
* @returns {HTMLElement} HTML Element
|
|
36
|
+
* @returns HTML Element
|
|
40
37
|
*/
|
|
41
38
|
render(): HTMLElement;
|
|
42
39
|
}
|
|
@@ -33,23 +33,24 @@ export declare class MgIcon {
|
|
|
33
33
|
/**
|
|
34
34
|
* Component classes
|
|
35
35
|
*/
|
|
36
|
-
|
|
36
|
+
classCollection: ClassList;
|
|
37
37
|
/**
|
|
38
38
|
* getIcon
|
|
39
|
-
*
|
|
40
|
-
* @returns {HTMLElement} icon html
|
|
39
|
+
* @returns icon html
|
|
41
40
|
*/
|
|
42
41
|
private getIcon;
|
|
42
|
+
/**
|
|
43
|
+
* Method to set default varianStyle props
|
|
44
|
+
* needeed has stencil doesn't know that props is mutated when updated in prop watcher
|
|
45
|
+
*/
|
|
46
|
+
private setDefaultVariantStyle;
|
|
43
47
|
/**
|
|
44
48
|
* Check if props are well configured on init
|
|
45
|
-
*
|
|
46
|
-
* @returns {void}
|
|
47
49
|
*/
|
|
48
50
|
componentWillLoad(): void;
|
|
49
51
|
/**
|
|
50
52
|
* Render component
|
|
51
|
-
*
|
|
52
|
-
* @returns {HTMLElement} HTML Element
|
|
53
|
+
* @returns HTML Element
|
|
53
54
|
*/
|
|
54
55
|
render(): HTMLElement;
|
|
55
56
|
}
|
|
@@ -22,14 +22,11 @@ export declare class MgInputTitle {
|
|
|
22
22
|
*************/
|
|
23
23
|
/**
|
|
24
24
|
* Init tag name
|
|
25
|
-
*
|
|
26
|
-
* @returns {void}
|
|
27
25
|
*/
|
|
28
26
|
componentWillLoad(): void;
|
|
29
27
|
/**
|
|
30
28
|
* Render
|
|
31
|
-
*
|
|
32
|
-
* @returns {HTMLElement} HTML Element
|
|
29
|
+
* @returns HTML element
|
|
33
30
|
*/
|
|
34
31
|
render(): HTMLElement;
|
|
35
32
|
}
|
|
@@ -31,15 +31,13 @@ export declare class MgTag {
|
|
|
31
31
|
/**
|
|
32
32
|
* Component classes
|
|
33
33
|
*/
|
|
34
|
-
|
|
34
|
+
classCollection: ClassList;
|
|
35
35
|
/*************
|
|
36
36
|
* Methods *
|
|
37
37
|
*************/
|
|
38
38
|
/**
|
|
39
39
|
* Validate the given textContent
|
|
40
|
-
*
|
|
41
|
-
* @param {string} textContent html element textContent property
|
|
42
|
-
* @returns {void}
|
|
40
|
+
* @param textContent - html element textContent property
|
|
43
41
|
*/
|
|
44
42
|
private validateTextContent;
|
|
45
43
|
/*************
|
|
@@ -47,14 +45,11 @@ export declare class MgTag {
|
|
|
47
45
|
*************/
|
|
48
46
|
/**
|
|
49
47
|
* Check if props are well configured on init
|
|
50
|
-
*
|
|
51
|
-
* @returns {void}
|
|
52
48
|
*/
|
|
53
49
|
componentWillLoad(): void;
|
|
54
50
|
/**
|
|
55
51
|
* Render
|
|
56
|
-
*
|
|
57
|
-
* @returns {HTMLElement} HTML Element
|
|
52
|
+
* @returns HTML Element
|
|
58
53
|
*/
|
|
59
54
|
render(): HTMLElement;
|
|
60
55
|
}
|
|
@@ -40,65 +40,48 @@ export declare class MgTooltip {
|
|
|
40
40
|
disabled: boolean;
|
|
41
41
|
/**
|
|
42
42
|
* Show tooltip
|
|
43
|
-
*
|
|
44
|
-
* @returns {void}
|
|
45
43
|
*/
|
|
46
44
|
private show;
|
|
47
45
|
/**
|
|
48
46
|
* Hide tooltip
|
|
49
|
-
*
|
|
50
|
-
* @returns {void}
|
|
51
47
|
*/
|
|
52
48
|
private hide;
|
|
53
49
|
/**
|
|
54
50
|
* Check if clicked outside of component and hidde tooltip
|
|
55
|
-
*
|
|
56
|
-
* @param {MouseEvent} event mouse event
|
|
57
|
-
* @returns {void}
|
|
51
|
+
* @param event - mouse event
|
|
58
52
|
*/
|
|
59
53
|
private clickOutside;
|
|
60
54
|
/**
|
|
61
55
|
* Check if 'Escape' key is pressed of component and hidde tooltip
|
|
62
|
-
*
|
|
63
|
-
* @param {KeyboardEvent} event keyboard event
|
|
64
|
-
* @returns {void}
|
|
56
|
+
* @param event - keyboard event
|
|
65
57
|
*/
|
|
66
58
|
private pressEscape;
|
|
67
59
|
/**
|
|
68
60
|
* Method to set display prop
|
|
69
|
-
*
|
|
70
|
-
* @param
|
|
71
|
-
* @param {boolean} condition additionnal condition to apply display prop newValue
|
|
72
|
-
* @returns {void}
|
|
61
|
+
* @param newValue - display prop new value
|
|
62
|
+
* @param condition - additionnal condition to apply display prop newValue
|
|
73
63
|
*/
|
|
74
64
|
private setDisplay;
|
|
75
65
|
/**
|
|
76
66
|
* Action for tooltip element and tooltiped element mouse listener
|
|
77
|
-
*
|
|
78
|
-
* @param
|
|
79
|
-
* @param
|
|
80
|
-
* @param {Guard} conditionalGuard guard condition
|
|
81
|
-
* @returns {void}
|
|
67
|
+
* @param elementGuard - tooltip element guard
|
|
68
|
+
* @param isMouseenter - mouseenter validation
|
|
69
|
+
* @param conditionalGuard - guard condition
|
|
82
70
|
*/
|
|
83
71
|
private tooltipMouseListenerAction;
|
|
84
72
|
/**
|
|
85
73
|
* Method to reset guard value
|
|
86
|
-
*
|
|
87
|
-
* @returns {void}
|
|
88
74
|
*/
|
|
89
75
|
private resetGuard;
|
|
90
76
|
/**
|
|
91
77
|
* Update slot content when it is a mg-button
|
|
92
|
-
*
|
|
93
|
-
* @param {HTMLMgButtonElement} mgButton slotted mg-button
|
|
94
|
-
* @returns {void}
|
|
78
|
+
* @param mgButton - slotted mg-button
|
|
95
79
|
*/
|
|
96
80
|
private setMgButtonWrapper;
|
|
97
81
|
/**
|
|
98
82
|
* Init tooltip
|
|
99
|
-
*
|
|
100
|
-
* @param
|
|
101
|
-
* @param {HTMLElement} interactiveElement interactive element
|
|
83
|
+
* @param slotElement - slotted element
|
|
84
|
+
* @param interactiveElement - interactive element
|
|
102
85
|
*/
|
|
103
86
|
private initTooltip;
|
|
104
87
|
/*************
|
|
@@ -106,22 +89,17 @@ export declare class MgTooltip {
|
|
|
106
89
|
*************/
|
|
107
90
|
/**
|
|
108
91
|
* set variables
|
|
109
|
-
*
|
|
110
|
-
* @returns {void}
|
|
111
92
|
*/
|
|
112
93
|
componentWillLoad(): void;
|
|
113
94
|
/**
|
|
114
95
|
* Get slotted element
|
|
115
96
|
* Check if it already contain an interactive element, if not we need to add a tabIndex attribute
|
|
116
97
|
* We need to attach the focused element to the tooltip (aria-describedby)
|
|
117
|
-
*
|
|
118
|
-
* @returns {void}
|
|
119
98
|
*/
|
|
120
99
|
componentDidLoad(): void;
|
|
121
100
|
/**
|
|
122
101
|
* Render
|
|
123
|
-
*
|
|
124
|
-
* @returns {HTMLElement} HTML Element
|
|
102
|
+
* @returns HTML Element
|
|
125
103
|
*/
|
|
126
104
|
render(): HTMLElement;
|
|
127
105
|
}
|
|
@@ -6,7 +6,7 @@ import { ClassList } from '../../../utils/components.utils';
|
|
|
6
6
|
*/
|
|
7
7
|
interface MgInputProps {
|
|
8
8
|
identifier: string;
|
|
9
|
-
|
|
9
|
+
classCollection: ClassList;
|
|
10
10
|
label: string;
|
|
11
11
|
labelOnTop: boolean;
|
|
12
12
|
labelHide: boolean;
|
|
@@ -24,11 +24,10 @@ interface MgInputProps {
|
|
|
24
24
|
}
|
|
25
25
|
/**
|
|
26
26
|
* Get input template
|
|
27
|
-
*
|
|
28
|
-
* @param
|
|
29
|
-
* @param
|
|
30
|
-
* @
|
|
31
|
-
* @returns {VNode[]} input template
|
|
27
|
+
* @param props - MgInput Interface Props
|
|
28
|
+
* @param children - Represent scoped elements
|
|
29
|
+
* @param utils - Stencil.js utils
|
|
30
|
+
* @returns input template
|
|
32
31
|
*/
|
|
33
32
|
export declare const MgInput: FunctionalComponent<MgInputProps>;
|
|
34
33
|
export {};
|
|
@@ -79,7 +79,7 @@ export declare class MgInputCheckbox {
|
|
|
79
79
|
/**
|
|
80
80
|
* Component classes
|
|
81
81
|
*/
|
|
82
|
-
|
|
82
|
+
classCollection: ClassList;
|
|
83
83
|
/**
|
|
84
84
|
* Error message to display
|
|
85
85
|
*/
|
|
@@ -98,14 +98,11 @@ export declare class MgInputCheckbox {
|
|
|
98
98
|
inputValid: EventEmitter<MgInputCheckbox['valid']>;
|
|
99
99
|
/**
|
|
100
100
|
* Public method to display errors
|
|
101
|
-
*
|
|
102
|
-
* @returns {Promise<void>}
|
|
103
101
|
*/
|
|
104
102
|
displayError(): Promise<void>;
|
|
105
103
|
/**
|
|
106
104
|
* Handle input event
|
|
107
|
-
*
|
|
108
|
-
* @param {InputEvent} event input event
|
|
105
|
+
* @param event - input event
|
|
109
106
|
*/
|
|
110
107
|
private handleInput;
|
|
111
108
|
/**
|
|
@@ -114,8 +111,7 @@ export declare class MgInputCheckbox {
|
|
|
114
111
|
private handleBlur;
|
|
115
112
|
/**
|
|
116
113
|
* get invalid element
|
|
117
|
-
*
|
|
118
|
-
* @returns {HTMLInputElement} element
|
|
114
|
+
* @returns element
|
|
119
115
|
*/
|
|
120
116
|
private getInvalidElement;
|
|
121
117
|
/**
|
|
@@ -131,14 +127,12 @@ export declare class MgInputCheckbox {
|
|
|
131
127
|
*************/
|
|
132
128
|
/**
|
|
133
129
|
* Check if component props are well configured on init
|
|
134
|
-
*
|
|
135
|
-
* @returns {ReturnType<typeof setTimeout>} timeout
|
|
130
|
+
* @returns timeout
|
|
136
131
|
*/
|
|
137
132
|
componentWillLoad(): ReturnType<typeof setTimeout>;
|
|
138
133
|
/**
|
|
139
134
|
* Render
|
|
140
|
-
*
|
|
141
|
-
* @returns {HTMLElement} HTML Element
|
|
135
|
+
* @returns HTML Element
|
|
142
136
|
*/
|
|
143
137
|
render(): HTMLElement;
|
|
144
138
|
}
|
|
@@ -84,7 +84,7 @@ export declare class MgInputDate {
|
|
|
84
84
|
/**
|
|
85
85
|
* Component classes
|
|
86
86
|
*/
|
|
87
|
-
|
|
87
|
+
classCollection: ClassList;
|
|
88
88
|
/**
|
|
89
89
|
* Error message to display
|
|
90
90
|
*/
|
|
@@ -99,8 +99,6 @@ export declare class MgInputDate {
|
|
|
99
99
|
inputValid: EventEmitter<boolean>;
|
|
100
100
|
/**
|
|
101
101
|
* Public method to display errors
|
|
102
|
-
*
|
|
103
|
-
* @returns {Promise<void>}
|
|
104
102
|
*/
|
|
105
103
|
displayError(): Promise<void>;
|
|
106
104
|
/**
|
|
@@ -117,14 +115,11 @@ export declare class MgInputDate {
|
|
|
117
115
|
private checkValidity;
|
|
118
116
|
/**
|
|
119
117
|
* get input error code
|
|
120
|
-
*
|
|
121
|
-
* @returns {null | InputError} error code
|
|
118
|
+
* @returns error code
|
|
122
119
|
*/
|
|
123
120
|
private getInputError;
|
|
124
121
|
/**
|
|
125
122
|
* Check input errors
|
|
126
|
-
*
|
|
127
|
-
* @returns {void}
|
|
128
123
|
*/
|
|
129
124
|
private setErrorMessage;
|
|
130
125
|
/*************
|
|
@@ -132,14 +127,12 @@ export declare class MgInputDate {
|
|
|
132
127
|
*************/
|
|
133
128
|
/**
|
|
134
129
|
* Check if component props are well configured on init
|
|
135
|
-
*
|
|
136
|
-
* @returns {ReturnType<typeof setTimeout>} timeout
|
|
130
|
+
* @returns timeout
|
|
137
131
|
*/
|
|
138
132
|
componentWillLoad(): ReturnType<typeof setTimeout>;
|
|
139
133
|
/**
|
|
140
134
|
* Render
|
|
141
|
-
*
|
|
142
|
-
* @returns {HTMLElement} HTML Element
|
|
135
|
+
* @returns HTML Element
|
|
143
136
|
*/
|
|
144
137
|
render(): HTMLElement;
|
|
145
138
|
}
|
|
@@ -115,7 +115,7 @@ export declare class MgInputNumeric {
|
|
|
115
115
|
/**
|
|
116
116
|
* Component classes
|
|
117
117
|
*/
|
|
118
|
-
|
|
118
|
+
classCollection: ClassList;
|
|
119
119
|
/**
|
|
120
120
|
* Error message to display
|
|
121
121
|
*/
|
|
@@ -134,64 +134,47 @@ export declare class MgInputNumeric {
|
|
|
134
134
|
inputValid: EventEmitter<boolean>;
|
|
135
135
|
/**
|
|
136
136
|
* Public method to display errors
|
|
137
|
-
*
|
|
138
|
-
* @returns {Promise<void>}
|
|
139
137
|
*/
|
|
140
138
|
displayError(): Promise<void>;
|
|
141
139
|
/**
|
|
142
140
|
* Displayed value in input
|
|
143
141
|
* Change on focus/blur
|
|
144
|
-
*
|
|
145
|
-
* @returns {MgInputNumeric['value'] | MgInputNumeric['readonlyValue']} display value
|
|
142
|
+
* @returns display value
|
|
146
143
|
*/
|
|
147
144
|
private displayValue;
|
|
148
145
|
/**
|
|
149
146
|
* Handle input event
|
|
150
|
-
*
|
|
151
|
-
* @returns {void}
|
|
152
147
|
*/
|
|
153
148
|
private handleInput;
|
|
154
149
|
/**
|
|
155
150
|
* Handle focus event
|
|
156
|
-
*
|
|
157
|
-
* @returns {void}
|
|
158
151
|
*/
|
|
159
152
|
private handleFocus;
|
|
160
153
|
/**
|
|
161
154
|
* Handle blur event
|
|
162
|
-
*
|
|
163
|
-
* @returns {void}
|
|
164
155
|
*/
|
|
165
156
|
private handleBlur;
|
|
166
157
|
/**
|
|
167
158
|
* Check if input is valid
|
|
168
|
-
*
|
|
169
|
-
* @returns {void}
|
|
170
159
|
*/
|
|
171
160
|
private checkValidity;
|
|
172
161
|
/**
|
|
173
162
|
* Set input error message
|
|
174
|
-
*
|
|
175
|
-
* @returns {void}
|
|
176
163
|
*/
|
|
177
164
|
private setErrorMessage;
|
|
178
165
|
/**
|
|
179
166
|
* Get input error code
|
|
180
|
-
*
|
|
181
|
-
* @returns {null | InputError} error code
|
|
167
|
+
* @returns error code
|
|
182
168
|
*/
|
|
183
169
|
private getInputError;
|
|
184
170
|
/**
|
|
185
171
|
* Format value based on type
|
|
186
|
-
*
|
|
187
|
-
* @
|
|
188
|
-
* @returns {string} formated local value
|
|
172
|
+
* @param value - value to format
|
|
173
|
+
* @returns formated local value
|
|
189
174
|
*/
|
|
190
175
|
private formatValue;
|
|
191
176
|
/**
|
|
192
177
|
* Validate append slot
|
|
193
|
-
*
|
|
194
|
-
* @returns {void}
|
|
195
178
|
*/
|
|
196
179
|
private validateAppendSlot;
|
|
197
180
|
/*************
|
|
@@ -199,14 +182,12 @@ export declare class MgInputNumeric {
|
|
|
199
182
|
*************/
|
|
200
183
|
/**
|
|
201
184
|
* Check if component props are well configured on init
|
|
202
|
-
*
|
|
203
|
-
* @returns {ReturnType<typeof setTimeout>} timeout
|
|
185
|
+
* @returns timeout
|
|
204
186
|
*/
|
|
205
187
|
componentWillLoad(): ReturnType<typeof setTimeout>;
|
|
206
188
|
/**
|
|
207
189
|
* Render
|
|
208
|
-
*
|
|
209
|
-
* @returns {HTMLElement} HTML Element
|
|
190
|
+
* @returns HTML Element
|
|
210
191
|
*/
|
|
211
192
|
render(): HTMLElement;
|
|
212
193
|
}
|
|
@@ -82,7 +82,7 @@ export declare class MgInputPassword {
|
|
|
82
82
|
/**
|
|
83
83
|
* Component classes
|
|
84
84
|
*/
|
|
85
|
-
|
|
85
|
+
classCollection: ClassList;
|
|
86
86
|
/**
|
|
87
87
|
* Error message to display
|
|
88
88
|
*/
|
|
@@ -97,8 +97,6 @@ export declare class MgInputPassword {
|
|
|
97
97
|
inputValid: EventEmitter<boolean>;
|
|
98
98
|
/**
|
|
99
99
|
* Public method to display errors
|
|
100
|
-
*
|
|
101
|
-
* @returns {Promise<void>}
|
|
102
100
|
*/
|
|
103
101
|
displayError(): Promise<void>;
|
|
104
102
|
/**
|
|
@@ -122,14 +120,12 @@ export declare class MgInputPassword {
|
|
|
122
120
|
*************/
|
|
123
121
|
/**
|
|
124
122
|
* Check if component props are well configured on init
|
|
125
|
-
*
|
|
126
|
-
* @returns {ReturnType<typeof setTimeout>} timeout
|
|
123
|
+
* @returns timeout
|
|
127
124
|
*/
|
|
128
125
|
componentWillLoad(): ReturnType<typeof setTimeout>;
|
|
129
126
|
/**
|
|
130
127
|
* Render
|
|
131
|
-
*
|
|
132
|
-
* @returns {HTMLElement} HTML Element
|
|
128
|
+
* @returns HTML Element
|
|
133
129
|
*/
|
|
134
130
|
render(): HTMLElement;
|
|
135
131
|
}
|
|
@@ -83,7 +83,7 @@ export declare class MgInputRadio {
|
|
|
83
83
|
/**
|
|
84
84
|
* Component classes
|
|
85
85
|
*/
|
|
86
|
-
|
|
86
|
+
classCollection: ClassList;
|
|
87
87
|
/**
|
|
88
88
|
* Error message to display
|
|
89
89
|
*/
|
|
@@ -102,39 +102,28 @@ export declare class MgInputRadio {
|
|
|
102
102
|
inputValid: EventEmitter<boolean>;
|
|
103
103
|
/**
|
|
104
104
|
* Public method to display errors
|
|
105
|
-
*
|
|
106
|
-
* @returns {Promise<void>}
|
|
107
105
|
*/
|
|
108
106
|
displayError(): Promise<void>;
|
|
109
107
|
/**
|
|
110
108
|
* Handle input event
|
|
111
|
-
*
|
|
112
|
-
* @param {event} event input event
|
|
113
|
-
* @returns {void}
|
|
109
|
+
* @param event - input event
|
|
114
110
|
*/
|
|
115
111
|
private handleInput;
|
|
116
112
|
/**
|
|
117
113
|
* Handle blur event
|
|
118
|
-
*
|
|
119
|
-
* @returns {void}
|
|
120
114
|
*/
|
|
121
115
|
private handleBlur;
|
|
122
116
|
/**
|
|
123
117
|
* Check if input is valid
|
|
124
|
-
*
|
|
125
|
-
* @returns {void}
|
|
126
118
|
*/
|
|
127
119
|
private checkValidity;
|
|
128
120
|
/**
|
|
129
121
|
* Set input error message
|
|
130
|
-
*
|
|
131
|
-
* @returns {void}
|
|
132
122
|
*/
|
|
133
123
|
private setErrorMessage;
|
|
134
124
|
/**
|
|
135
125
|
* get invalid element
|
|
136
|
-
*
|
|
137
|
-
* @returns {HTMLInputElement} element
|
|
126
|
+
* @returns element
|
|
138
127
|
*/
|
|
139
128
|
private getInvalidElement;
|
|
140
129
|
/*************
|
|
@@ -142,14 +131,12 @@ export declare class MgInputRadio {
|
|
|
142
131
|
*************/
|
|
143
132
|
/**
|
|
144
133
|
* Check if component props are well configured on init
|
|
145
|
-
*
|
|
146
|
-
* @returns {ReturnType<typeof setTimeout>} timeout
|
|
134
|
+
* @returns timeout
|
|
147
135
|
*/
|
|
148
136
|
componentWillLoad(): ReturnType<typeof setTimeout>;
|
|
149
137
|
/**
|
|
150
138
|
* Render
|
|
151
|
-
*
|
|
152
|
-
* @returns {HTMLElement} HTML Element
|
|
139
|
+
* @returns HTML Element
|
|
153
140
|
*/
|
|
154
141
|
render(): HTMLElement;
|
|
155
142
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* type SelectOption
|
|
3
|
-
* use to match select
|
|
3
|
+
* use to match select \> option attributes
|
|
4
4
|
*/
|
|
5
5
|
export type SelectOption = {
|
|
6
6
|
title: string;
|
|
@@ -10,7 +10,7 @@ export type SelectOption = {
|
|
|
10
10
|
};
|
|
11
11
|
/**
|
|
12
12
|
* type OptGroup
|
|
13
|
-
* use to match select
|
|
13
|
+
* use to match select \> optgroup attributes
|
|
14
14
|
*/
|
|
15
15
|
export type OptGroup = {
|
|
16
16
|
group: string;
|