@mgdis/mg-components 3.1.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/LICENSE +29 -0
- package/dist/cjs/css-shim-a22512c4.js +6 -0
- package/dist/cjs/index-85a4a0b6.js +1674 -0
- package/dist/cjs/index.cjs.js +2 -0
- package/dist/cjs/loader.cjs.js +35 -0
- package/dist/cjs/mg-badge_20.cjs.entry.js +4661 -0
- package/dist/cjs/mg-components.cjs.js +23 -0
- package/dist/cjs/shadow-css-8940f82d.js +390 -0
- package/dist/collection/collection-manifest.json +31 -0
- package/dist/collection/components/atoms/mg-badge/mg-badge.conf.js +4 -0
- package/dist/collection/components/atoms/mg-badge/mg-badge.css +99 -0
- package/dist/collection/components/atoms/mg-badge/mg-badge.js +148 -0
- package/dist/collection/components/atoms/mg-badge/mg-badge.stories.js +27 -0
- package/dist/collection/components/atoms/mg-button/mg-button.conf.js +4 -0
- package/dist/collection/components/atoms/mg-button/mg-button.css +134 -0
- package/dist/collection/components/atoms/mg-button/mg-button.js +236 -0
- package/dist/collection/components/atoms/mg-button/mg-button.stories.js +38 -0
- package/dist/collection/components/atoms/mg-character-left/mg-character-left.css +3 -0
- package/dist/collection/components/atoms/mg-character-left/mg-character-left.js +133 -0
- package/dist/collection/components/atoms/mg-character-left/mg-character-left.stories.js +15 -0
- package/dist/collection/components/atoms/mg-icon/mg-icon.conf.js +54 -0
- package/dist/collection/components/atoms/mg-icon/mg-icon.css +57 -0
- package/dist/collection/components/atoms/mg-icon/mg-icon.js +155 -0
- package/dist/collection/components/atoms/mg-icon/mg-icon.stories.js +34 -0
- package/dist/collection/components/atoms/mg-input-title/mg-input-title.css +12 -0
- package/dist/collection/components/atoms/mg-input-title/mg-input-title.js +95 -0
- package/dist/collection/components/atoms/mg-input-title/mg-input-title.stories.js +21 -0
- package/dist/collection/components/atoms/mg-tag/mg-tag.conf.js +4 -0
- package/dist/collection/components/atoms/mg-tag/mg-tag.css +73 -0
- package/dist/collection/components/atoms/mg-tag/mg-tag.js +94 -0
- package/dist/collection/components/atoms/mg-tag/mg-tag.stories.js +25 -0
- package/dist/collection/components/atoms/mg-tooltip/mg-tooltip.css +44 -0
- package/dist/collection/components/atoms/mg-tooltip/mg-tooltip.js +225 -0
- package/dist/collection/components/atoms/mg-tooltip/mg-tooltip.stories.js +26 -0
- package/dist/collection/components/molecules/inputs/MgInput.conf.js +7 -0
- package/dist/collection/components/molecules/inputs/MgInput.js +130 -0
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.conf.js +1 -0
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.css +156 -0
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.js +444 -0
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.stories.js +57 -0
- package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.conf.js +7 -0
- package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.css +171 -0
- package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.js +467 -0
- package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.stories.js +46 -0
- package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.conf.js +11 -0
- package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.css +199 -0
- package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.js +633 -0
- package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.stories.js +68 -0
- package/dist/collection/components/molecules/inputs/mg-input-password/mg-input-password.css +195 -0
- package/dist/collection/components/molecules/inputs/mg-input-password/mg-input-password.js +401 -0
- package/dist/collection/components/molecules/inputs/mg-input-password/mg-input-password.stories.js +43 -0
- package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.conf.js +1 -0
- package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.css +156 -0
- package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.js +443 -0
- package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.stories.js +65 -0
- package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.conf.js +1 -0
- package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.css +201 -0
- package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.js +532 -0
- package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.stories.js +70 -0
- package/dist/collection/components/molecules/inputs/mg-input-text/mg-input-text.css +222 -0
- package/dist/collection/components/molecules/inputs/mg-input-text/mg-input-text.js +589 -0
- package/dist/collection/components/molecules/inputs/mg-input-text/mg-input-text.stories.js +115 -0
- package/dist/collection/components/molecules/inputs/mg-input-textarea/mg-input-textarea.css +217 -0
- package/dist/collection/components/molecules/inputs/mg-input-textarea/mg-input-textarea.js +553 -0
- package/dist/collection/components/molecules/inputs/mg-input-textarea/mg-input-textarea.stories.js +52 -0
- package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.conf.js +1 -0
- package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.css +213 -0
- package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.js +457 -0
- package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.stories.js +73 -0
- package/dist/collection/components/molecules/mg-message/mg-message.conf.js +4 -0
- package/dist/collection/components/molecules/mg-message/mg-message.css +94 -0
- package/dist/collection/components/molecules/mg-message/mg-message.js +285 -0
- package/dist/collection/components/molecules/mg-message/mg-message.stories.js +43 -0
- package/dist/collection/components/molecules/mg-pagination/mg-pagination.conf.js +5 -0
- package/dist/collection/components/molecules/mg-pagination/mg-pagination.css +39 -0
- package/dist/collection/components/molecules/mg-pagination/mg-pagination.js +218 -0
- package/dist/collection/components/molecules/mg-pagination/mg-pagination.stories.js +23 -0
- package/dist/collection/components/molecules/mg-popover/mg-popover.css +59 -0
- package/dist/collection/components/molecules/mg-popover/mg-popover.js +249 -0
- package/dist/collection/components/molecules/mg-popover/mg-popover.stories.js +36 -0
- package/dist/collection/components/molecules/mg-tabs/mg-tabs.conf.js +1 -0
- package/dist/collection/components/molecules/mg-tabs/mg-tabs.css +30 -0
- package/dist/collection/components/molecules/mg-tabs/mg-tabs.js +212 -0
- package/dist/collection/components/molecules/mg-tabs/mg-tabs.stories.js +40 -0
- package/dist/collection/fonts/OpenSans-Regular.ttf +0 -0
- package/dist/collection/fonts/OpenSans-SemiBold.ttf +0 -0
- package/dist/collection/fonts/Poppins-Bold.ttf +0 -0
- package/dist/collection/index.js +1 -0
- package/dist/collection/locales/index.js +4 -0
- package/dist/collection/stories/buttons.stories.js +43 -0
- package/dist/collection/stories/grids.stories.js +50 -0
- package/dist/collection/stories/icons.stories.js +20 -0
- package/dist/collection/stories/messages.stories.js +44 -0
- package/dist/collection/stories/tags.stories.js +13 -0
- package/dist/collection/stories/typography.stories.js +28 -0
- package/dist/collection/utils/components.utils.js +67 -0
- package/dist/collection/utils/locale.utils.js +32 -0
- package/dist/collection/utils/test.utils.js +26 -0
- package/dist/collection/variables.css +177 -0
- package/dist/collection/variables.scss +177 -0
- package/dist/components/MgInput.js +140 -0
- package/dist/components/components.utils.js +69 -0
- package/dist/components/index.d.ts +26 -0
- package/dist/components/index.js +1 -0
- package/dist/components/index2.js +54 -0
- package/dist/components/locale.utils.js +35 -0
- package/dist/components/mg-badge.d.ts +11 -0
- package/dist/components/mg-badge.js +6 -0
- package/dist/components/mg-badge2.js +82 -0
- package/dist/components/mg-button.d.ts +11 -0
- package/dist/components/mg-button.js +6 -0
- package/dist/components/mg-button2.js +148 -0
- package/dist/components/mg-character-left.d.ts +11 -0
- package/dist/components/mg-character-left.js +6 -0
- package/dist/components/mg-character-left2.js +77 -0
- package/dist/components/mg-icon.d.ts +11 -0
- package/dist/components/mg-icon.js +6 -0
- package/dist/components/mg-icon2.js +147 -0
- package/dist/components/mg-input-checkbox.d.ts +11 -0
- package/dist/components/mg-input-checkbox.js +222 -0
- package/dist/components/mg-input-date.d.ts +11 -0
- package/dist/components/mg-input-date.js +245 -0
- package/dist/components/mg-input-numeric.d.ts +11 -0
- package/dist/components/mg-input-numeric.js +324 -0
- package/dist/components/mg-input-password.d.ts +11 -0
- package/dist/components/mg-input-password.js +171 -0
- package/dist/components/mg-input-radio.d.ts +11 -0
- package/dist/components/mg-input-radio.js +211 -0
- package/dist/components/mg-input-select.d.ts +11 -0
- package/dist/components/mg-input-select.js +6 -0
- package/dist/components/mg-input-select2.js +243 -0
- package/dist/components/mg-input-text.d.ts +11 -0
- package/dist/components/mg-input-text.js +242 -0
- package/dist/components/mg-input-textarea.d.ts +11 -0
- package/dist/components/mg-input-textarea.js +224 -0
- package/dist/components/mg-input-title.d.ts +11 -0
- package/dist/components/mg-input-title.js +6 -0
- package/dist/components/mg-input-title2.js +55 -0
- package/dist/components/mg-input-toggle.d.ts +11 -0
- package/dist/components/mg-input-toggle.js +247 -0
- package/dist/components/mg-message.d.ts +11 -0
- package/dist/components/mg-message.js +183 -0
- package/dist/components/mg-pagination.d.ts +11 -0
- package/dist/components/mg-pagination.js +175 -0
- package/dist/components/mg-popover.d.ts +11 -0
- package/dist/components/mg-popover.js +183 -0
- package/dist/components/mg-tabs.d.ts +11 -0
- package/dist/components/mg-tabs.js +160 -0
- package/dist/components/mg-tag.d.ts +11 -0
- package/dist/components/mg-tag.js +76 -0
- package/dist/components/mg-tooltip.d.ts +11 -0
- package/dist/components/mg-tooltip.js +6 -0
- package/dist/components/mg-tooltip2.js +150 -0
- package/dist/components/popper.js +1784 -0
- package/dist/esm/css-shim-7c240feb.js +4 -0
- package/dist/esm/index-e3e84606.js +1643 -0
- package/dist/esm/index.js +1 -0
- package/dist/esm/loader.js +31 -0
- package/dist/esm/mg-badge_20.entry.js +4638 -0
- package/dist/esm/mg-components.js +21 -0
- package/dist/esm/polyfills/core-js.js +11 -0
- package/dist/esm/polyfills/css-shim.js +1 -0
- package/dist/esm/polyfills/dom.js +79 -0
- package/dist/esm/polyfills/es5-html-element.js +1 -0
- package/dist/esm/polyfills/index.js +34 -0
- package/dist/esm/polyfills/system.js +6 -0
- package/dist/esm/shadow-css-5d2d01ce.js +388 -0
- package/dist/esm-es5/css-shim-7c240feb.js +1 -0
- package/dist/esm-es5/index-e3e84606.js +1 -0
- package/dist/esm-es5/index.js +0 -0
- package/dist/esm-es5/loader.js +1 -0
- package/dist/esm-es5/mg-badge_20.entry.js +2 -0
- package/dist/esm-es5/mg-components.js +1 -0
- package/dist/esm-es5/shadow-css-5d2d01ce.js +12 -0
- package/dist/index.cjs.js +1 -0
- package/dist/index.js +1 -0
- package/dist/mg-components/fonts/OpenSans-Regular.ttf +0 -0
- package/dist/mg-components/fonts/OpenSans-SemiBold.ttf +0 -0
- package/dist/mg-components/fonts/Poppins-Bold.ttf +0 -0
- package/dist/mg-components/index.esm.js +0 -0
- package/dist/mg-components/mg-components.css +1 -0
- package/dist/mg-components/mg-components.esm.js +1 -0
- package/dist/mg-components/mg-components.js +132 -0
- package/dist/mg-components/p-1cd24462.system.js +1 -0
- package/dist/mg-components/p-2e2f6b27.system.entry.js +2 -0
- package/dist/mg-components/p-366a224e.js +1 -0
- package/dist/mg-components/p-422c429b.system.js +1 -0
- package/dist/mg-components/p-50ea2036.system.js +1 -0
- package/dist/mg-components/p-62fa3797.js +1 -0
- package/dist/mg-components/p-71d57b8b.system.js +13 -0
- package/dist/mg-components/p-9a215712.system.js +1 -0
- package/dist/mg-components/p-cbf0464b.entry.js +1 -0
- package/dist/mg-components/p-f6455ab3.js +12 -0
- package/dist/mg-components/variables.css +177 -0
- package/dist/mg-components/variables.scss +177 -0
- package/dist/types/components/atoms/mg-badge/mg-badge.conf.d.ts +8 -0
- package/dist/types/components/atoms/mg-badge/mg-badge.d.ts +36 -0
- package/dist/types/components/atoms/mg-badge/mg-badge.stories.d.ts +19 -0
- package/dist/types/components/atoms/mg-button/mg-button.conf.d.ts +4 -0
- package/dist/types/components/atoms/mg-button/mg-button.d.ts +67 -0
- package/dist/types/components/atoms/mg-button/mg-button.stories.d.ts +16 -0
- package/dist/types/components/atoms/mg-character-left/mg-character-left.d.ts +39 -0
- package/dist/types/components/atoms/mg-character-left/mg-character-left.stories.d.ts +7 -0
- package/dist/types/components/atoms/mg-icon/mg-icon.conf.d.ts +12 -0
- package/dist/types/components/atoms/mg-icon/mg-icon.d.ts +36 -0
- package/dist/types/components/atoms/mg-icon/mg-icon.stories.d.ts +26 -0
- package/dist/types/components/atoms/mg-input-title/mg-input-title.d.ts +24 -0
- package/dist/types/components/atoms/mg-input-title/mg-input-title.stories.d.ts +6 -0
- package/dist/types/components/atoms/mg-tag/mg-tag.conf.d.ts +4 -0
- package/dist/types/components/atoms/mg-tag/mg-tag.d.ts +25 -0
- package/dist/types/components/atoms/mg-tag/mg-tag.stories.d.ts +14 -0
- package/dist/types/components/atoms/mg-tooltip/mg-tooltip.d.ts +56 -0
- package/dist/types/components/atoms/mg-tooltip/mg-tooltip.stories.d.ts +11 -0
- package/dist/types/components/molecules/inputs/MgInput.conf.d.ts +10 -0
- package/dist/types/components/molecules/inputs/MgInput.d.ts +35 -0
- package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.conf.d.ts +19 -0
- package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.d.ts +120 -0
- package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.stories.d.ts +6 -0
- package/dist/types/components/molecules/inputs/mg-input-date/mg-input-date.conf.d.ts +6 -0
- package/dist/types/components/molecules/inputs/mg-input-date/mg-input-date.d.ts +128 -0
- package/dist/types/components/molecules/inputs/mg-input-date/mg-input-date.stories.d.ts +7 -0
- package/dist/types/components/molecules/inputs/mg-input-numeric/mg-input-numeric.conf.d.ts +10 -0
- package/dist/types/components/molecules/inputs/mg-input-numeric/mg-input-numeric.d.ts +173 -0
- package/dist/types/components/molecules/inputs/mg-input-numeric/mg-input-numeric.stories.d.ts +21 -0
- package/dist/types/components/molecules/inputs/mg-input-password/mg-input-password.d.ts +111 -0
- package/dist/types/components/molecules/inputs/mg-input-password/mg-input-password.stories.d.ts +9 -0
- package/dist/types/components/molecules/inputs/mg-input-radio/mg-input-radio.conf.d.ts +9 -0
- package/dist/types/components/molecules/inputs/mg-input-radio/mg-input-radio.d.ts +121 -0
- package/dist/types/components/molecules/inputs/mg-input-radio/mg-input-radio.stories.d.ts +15 -0
- package/dist/types/components/molecules/inputs/mg-input-select/mg-input-select.conf.d.ts +18 -0
- package/dist/types/components/molecules/inputs/mg-input-select/mg-input-select.d.ts +133 -0
- package/dist/types/components/molecules/inputs/mg-input-select/mg-input-select.stories.d.ts +14 -0
- package/dist/types/components/molecules/inputs/mg-input-text/mg-input-text.d.ts +160 -0
- package/dist/types/components/molecules/inputs/mg-input-text/mg-input-text.stories.d.ts +26 -0
- package/dist/types/components/molecules/inputs/mg-input-textarea/mg-input-textarea.d.ts +150 -0
- package/dist/types/components/molecules/inputs/mg-input-textarea/mg-input-textarea.stories.d.ts +6 -0
- package/dist/types/components/molecules/inputs/mg-input-toggle/mg-input-toggle.conf.d.ts +8 -0
- package/dist/types/components/molecules/inputs/mg-input-toggle/mg-input-toggle.d.ts +117 -0
- package/dist/types/components/molecules/inputs/mg-input-toggle/mg-input-toggle.stories.d.ts +7 -0
- package/dist/types/components/molecules/mg-message/mg-message.conf.d.ts +4 -0
- package/dist/types/components/molecules/mg-message/mg-message.d.ts +76 -0
- package/dist/types/components/molecules/mg-message/mg-message.stories.d.ts +16 -0
- package/dist/types/components/molecules/mg-pagination/mg-pagination.conf.d.ts +4 -0
- package/dist/types/components/molecules/mg-pagination/mg-pagination.d.ts +53 -0
- package/dist/types/components/molecules/mg-pagination/mg-pagination.stories.d.ts +6 -0
- package/dist/types/components/molecules/mg-popover/mg-popover.d.ts +62 -0
- package/dist/types/components/molecules/mg-popover/mg-popover.stories.d.ts +12 -0
- package/dist/types/components/molecules/mg-tabs/mg-tabs.conf.d.ts +10 -0
- package/dist/types/components/molecules/mg-tabs/mg-tabs.d.ts +63 -0
- package/dist/types/components/molecules/mg-tabs/mg-tabs.stories.d.ts +7 -0
- package/dist/types/components.d.ts +1987 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/locales/index.d.ts +44 -0
- package/dist/types/stencil-public-runtime.d.ts +1565 -0
- package/dist/types/stories/buttons.stories.d.ts +13 -0
- package/dist/types/stories/grids.stories.d.ts +5 -0
- package/dist/types/stories/icons.stories.d.ts +13 -0
- package/dist/types/stories/messages.stories.d.ts +13 -0
- package/dist/types/stories/tags.stories.d.ts +5 -0
- package/dist/types/stories/typography.stories.d.ts +5 -0
- package/dist/types/utils/components.utils.d.ts +43 -0
- package/dist/types/utils/locale.utils.d.ts +22 -0
- package/dist/types/utils/test.utils.d.ts +5 -0
- package/loader/cdn.js +3 -0
- package/loader/index.cjs.js +3 -0
- package/loader/index.d.ts +12 -0
- package/loader/index.es2017.js +3 -0
- package/loader/index.js +4 -0
- package/loader/package.json +10 -0
- package/package.json +86 -0
- package/readme.md +159 -0
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
import { EventEmitter } from '../../../../stencil-public-runtime';
|
|
3
|
+
import { ClassList } from '../../../../utils/components.utils';
|
|
4
|
+
import { CheckboxItem, CheckboxValue } from './mg-input-checkbox.conf';
|
|
5
|
+
export declare class MgInputCheckbox {
|
|
6
|
+
/************
|
|
7
|
+
* Internal *
|
|
8
|
+
************/
|
|
9
|
+
private classError;
|
|
10
|
+
private inputs;
|
|
11
|
+
/**************
|
|
12
|
+
* Decorators *
|
|
13
|
+
**************/
|
|
14
|
+
/**
|
|
15
|
+
* Component value
|
|
16
|
+
* If item.value is `null`, checkbox will be indeterminate by default
|
|
17
|
+
* Required
|
|
18
|
+
*/
|
|
19
|
+
value: CheckboxValue[];
|
|
20
|
+
validateValue(newValue: any): void;
|
|
21
|
+
/**
|
|
22
|
+
* Identifier is used for the element ID (id is a reserved prop in Stencil.js)
|
|
23
|
+
* If not set, it will be created.
|
|
24
|
+
*/
|
|
25
|
+
identifier?: string;
|
|
26
|
+
/**
|
|
27
|
+
* Input name
|
|
28
|
+
* If not set the value equals the identifier
|
|
29
|
+
*/
|
|
30
|
+
name?: string;
|
|
31
|
+
/**
|
|
32
|
+
* Input label
|
|
33
|
+
* Required
|
|
34
|
+
*/
|
|
35
|
+
label: string;
|
|
36
|
+
/**
|
|
37
|
+
* Define if label is displayed on top
|
|
38
|
+
*/
|
|
39
|
+
labelOnTop: boolean;
|
|
40
|
+
/**
|
|
41
|
+
* Define if label is visible
|
|
42
|
+
*/
|
|
43
|
+
labelHide: boolean;
|
|
44
|
+
/**
|
|
45
|
+
* Define if inputs are display verticaly
|
|
46
|
+
*/
|
|
47
|
+
inputVerticalList: boolean;
|
|
48
|
+
/**
|
|
49
|
+
* Define if input is required
|
|
50
|
+
*/
|
|
51
|
+
required: boolean;
|
|
52
|
+
/**
|
|
53
|
+
* Define if input is readonly
|
|
54
|
+
*/
|
|
55
|
+
readonly: boolean;
|
|
56
|
+
handleReadOnly(): void;
|
|
57
|
+
/**
|
|
58
|
+
* Define if input is disabled
|
|
59
|
+
*/
|
|
60
|
+
disabled: boolean;
|
|
61
|
+
/**
|
|
62
|
+
* Add a tooltip message next to the input
|
|
63
|
+
*/
|
|
64
|
+
tooltip: string;
|
|
65
|
+
/**
|
|
66
|
+
* Add a help text under the input, usually expected data format and example
|
|
67
|
+
*/
|
|
68
|
+
helpText: string;
|
|
69
|
+
/**
|
|
70
|
+
* Force valid component
|
|
71
|
+
*/
|
|
72
|
+
valid: boolean;
|
|
73
|
+
/**
|
|
74
|
+
* Force invalid component
|
|
75
|
+
*/
|
|
76
|
+
invalid: boolean;
|
|
77
|
+
/**
|
|
78
|
+
* Component classes
|
|
79
|
+
*/
|
|
80
|
+
classList: ClassList;
|
|
81
|
+
/**
|
|
82
|
+
* Error message to display
|
|
83
|
+
*/
|
|
84
|
+
errorMessage: string;
|
|
85
|
+
/**
|
|
86
|
+
* Formated value for display
|
|
87
|
+
*/
|
|
88
|
+
checkboxItems: CheckboxItem[];
|
|
89
|
+
/**
|
|
90
|
+
* Emitted event when value change
|
|
91
|
+
*/
|
|
92
|
+
valueChange: EventEmitter<CheckboxValue[]>;
|
|
93
|
+
/**
|
|
94
|
+
* Handle input event
|
|
95
|
+
* @param event
|
|
96
|
+
*/
|
|
97
|
+
private handleInput;
|
|
98
|
+
/**
|
|
99
|
+
* Handle blur event
|
|
100
|
+
*/
|
|
101
|
+
private handleBlur;
|
|
102
|
+
/**
|
|
103
|
+
* Check if input is valid
|
|
104
|
+
*/
|
|
105
|
+
private checkValidity;
|
|
106
|
+
/**
|
|
107
|
+
* Check input errors
|
|
108
|
+
*/
|
|
109
|
+
private checkError;
|
|
110
|
+
/**
|
|
111
|
+
* get invalid element
|
|
112
|
+
* @returns element: HTMLInputElement
|
|
113
|
+
*/
|
|
114
|
+
private getInvalidElement;
|
|
115
|
+
/*************
|
|
116
|
+
* Lifecycle *
|
|
117
|
+
*************/
|
|
118
|
+
componentWillLoad(): NodeJS.Timeout;
|
|
119
|
+
render(): any;
|
|
120
|
+
}
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
import { EventEmitter } from '../../../../stencil-public-runtime';
|
|
3
|
+
import { ClassList } from '../../../../utils/components.utils';
|
|
4
|
+
export declare class MgInputDate {
|
|
5
|
+
/************
|
|
6
|
+
* Internal *
|
|
7
|
+
************/
|
|
8
|
+
private classError;
|
|
9
|
+
private input;
|
|
10
|
+
/**************
|
|
11
|
+
* Decorators *
|
|
12
|
+
**************/
|
|
13
|
+
/**
|
|
14
|
+
* Component value
|
|
15
|
+
*/
|
|
16
|
+
value: string;
|
|
17
|
+
validateValue(newValue: any): void;
|
|
18
|
+
/**
|
|
19
|
+
* Identifier is used for the element ID (id is a reserved prop in Stencil.js)
|
|
20
|
+
* If not set, it will be created.
|
|
21
|
+
*/
|
|
22
|
+
identifier?: string;
|
|
23
|
+
/**
|
|
24
|
+
* Input name
|
|
25
|
+
* If not set the value equals the identifier
|
|
26
|
+
*/
|
|
27
|
+
name?: string;
|
|
28
|
+
/**
|
|
29
|
+
* Input label
|
|
30
|
+
* Required
|
|
31
|
+
*/
|
|
32
|
+
label: string;
|
|
33
|
+
/**
|
|
34
|
+
* Define if label is displayed on top
|
|
35
|
+
*/
|
|
36
|
+
labelOnTop: boolean;
|
|
37
|
+
/**
|
|
38
|
+
* Define if label is visible
|
|
39
|
+
*/
|
|
40
|
+
labelHide: boolean;
|
|
41
|
+
/**
|
|
42
|
+
* Define if input is required
|
|
43
|
+
*/
|
|
44
|
+
required: boolean;
|
|
45
|
+
/**
|
|
46
|
+
* Define if input is readonly
|
|
47
|
+
*/
|
|
48
|
+
readonly: boolean;
|
|
49
|
+
/**
|
|
50
|
+
* Define if input is disabled
|
|
51
|
+
*/
|
|
52
|
+
disabled: boolean;
|
|
53
|
+
/**
|
|
54
|
+
* Add a tooltip message next to the input
|
|
55
|
+
*/
|
|
56
|
+
tooltip: string;
|
|
57
|
+
/**
|
|
58
|
+
* Add a help text under the input, usually expected data format and example
|
|
59
|
+
*/
|
|
60
|
+
helpText: string;
|
|
61
|
+
/**
|
|
62
|
+
* Define input pattern to validate
|
|
63
|
+
*/
|
|
64
|
+
valid: boolean;
|
|
65
|
+
/**
|
|
66
|
+
* Define input pattern error message
|
|
67
|
+
*/
|
|
68
|
+
invalid: boolean;
|
|
69
|
+
/**
|
|
70
|
+
* Define input minimum date
|
|
71
|
+
* format: yyyy-mm-dd
|
|
72
|
+
*/
|
|
73
|
+
min: string;
|
|
74
|
+
validateMin(newValue: any): void;
|
|
75
|
+
/**
|
|
76
|
+
* Define input maximum date
|
|
77
|
+
* format: yyyy-mm-dd
|
|
78
|
+
*/
|
|
79
|
+
max: string;
|
|
80
|
+
validateMax(newValue: any): void;
|
|
81
|
+
/**
|
|
82
|
+
* Component classes
|
|
83
|
+
*/
|
|
84
|
+
classList: ClassList;
|
|
85
|
+
/**
|
|
86
|
+
* Error message to display
|
|
87
|
+
*/
|
|
88
|
+
errorMessage: string;
|
|
89
|
+
/**
|
|
90
|
+
* Emmited event when value change
|
|
91
|
+
*/
|
|
92
|
+
valueChange: EventEmitter<string>;
|
|
93
|
+
/**
|
|
94
|
+
* Handle input event
|
|
95
|
+
*/
|
|
96
|
+
private handleInput;
|
|
97
|
+
/**
|
|
98
|
+
* Handle blur event
|
|
99
|
+
*/
|
|
100
|
+
private handleBlur;
|
|
101
|
+
/**
|
|
102
|
+
* Date format validation
|
|
103
|
+
* @param date
|
|
104
|
+
*/
|
|
105
|
+
private validateDateFormat;
|
|
106
|
+
/**
|
|
107
|
+
* Check if input is valid
|
|
108
|
+
*/
|
|
109
|
+
private checkValidity;
|
|
110
|
+
/**
|
|
111
|
+
* get input error code
|
|
112
|
+
* @returns {null | InputError}
|
|
113
|
+
*/
|
|
114
|
+
private getInputError;
|
|
115
|
+
/**
|
|
116
|
+
* Set error message
|
|
117
|
+
*/
|
|
118
|
+
private setErrorMessage;
|
|
119
|
+
/**
|
|
120
|
+
* Check input errors
|
|
121
|
+
*/
|
|
122
|
+
private checkError;
|
|
123
|
+
/*************
|
|
124
|
+
* Lifecycle *
|
|
125
|
+
*************/
|
|
126
|
+
componentWillLoad(): NodeJS.Timeout;
|
|
127
|
+
render(): any;
|
|
128
|
+
}
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
import { EventEmitter } from '../../../../stencil-public-runtime';
|
|
3
|
+
import { Width } from '../MgInput.conf';
|
|
4
|
+
import { ClassList } from '../../../../utils/components.utils';
|
|
5
|
+
export declare class MgInputNumeric {
|
|
6
|
+
/************
|
|
7
|
+
* Internal *
|
|
8
|
+
************/
|
|
9
|
+
private storedValue;
|
|
10
|
+
private numericValue;
|
|
11
|
+
private readonlyValue;
|
|
12
|
+
private classError;
|
|
13
|
+
private input;
|
|
14
|
+
/**************
|
|
15
|
+
* Decorators *
|
|
16
|
+
**************/
|
|
17
|
+
element: HTMLMgInputNumericElement;
|
|
18
|
+
/**
|
|
19
|
+
* Component value
|
|
20
|
+
*/
|
|
21
|
+
value: string;
|
|
22
|
+
validateValue(newValue: string): void;
|
|
23
|
+
/**
|
|
24
|
+
* Identifier is used for the element ID (id is a reserved prop in Stencil.js)
|
|
25
|
+
* If not set, it will be created.
|
|
26
|
+
*/
|
|
27
|
+
identifier?: string;
|
|
28
|
+
/**
|
|
29
|
+
* Input name
|
|
30
|
+
* If not set the value equals the identifier
|
|
31
|
+
*/
|
|
32
|
+
name?: string;
|
|
33
|
+
/**
|
|
34
|
+
* Input label
|
|
35
|
+
* Required
|
|
36
|
+
*/
|
|
37
|
+
label: string;
|
|
38
|
+
/**
|
|
39
|
+
* Define if label is displayed on top
|
|
40
|
+
*/
|
|
41
|
+
labelOnTop: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* Define if label is visible
|
|
44
|
+
*/
|
|
45
|
+
labelHide: boolean;
|
|
46
|
+
/**
|
|
47
|
+
* Input placeholder.
|
|
48
|
+
* It should be a word or short phrase that demonstrates the expected type of data, not a replacement for labels or help text.
|
|
49
|
+
*/
|
|
50
|
+
placeholder: string;
|
|
51
|
+
/**
|
|
52
|
+
* Define if input is required
|
|
53
|
+
*/
|
|
54
|
+
required: boolean;
|
|
55
|
+
/**
|
|
56
|
+
* Define if input is readonly
|
|
57
|
+
*/
|
|
58
|
+
readonly: boolean;
|
|
59
|
+
/**
|
|
60
|
+
* Define if input is disabled
|
|
61
|
+
*/
|
|
62
|
+
disabled: boolean;
|
|
63
|
+
/**
|
|
64
|
+
* Define input width
|
|
65
|
+
*/
|
|
66
|
+
width: Width;
|
|
67
|
+
/**
|
|
68
|
+
* Add a tooltip message next to the input
|
|
69
|
+
*/
|
|
70
|
+
tooltip: string;
|
|
71
|
+
/**
|
|
72
|
+
* Add a help text under the input, usually expected data format and example
|
|
73
|
+
*/
|
|
74
|
+
helpText: string;
|
|
75
|
+
/**
|
|
76
|
+
* Define numeric type
|
|
77
|
+
*/
|
|
78
|
+
type: string;
|
|
79
|
+
validateType(newValue: string): void;
|
|
80
|
+
/**
|
|
81
|
+
* Maximum value
|
|
82
|
+
*/
|
|
83
|
+
max: number;
|
|
84
|
+
/**
|
|
85
|
+
* Minimum value
|
|
86
|
+
*/
|
|
87
|
+
min: number;
|
|
88
|
+
/**
|
|
89
|
+
* Override integer length
|
|
90
|
+
* integer is the number before the decimal point
|
|
91
|
+
*/
|
|
92
|
+
integerLength: number;
|
|
93
|
+
validateIntegerLength(newValue: number): void;
|
|
94
|
+
/**
|
|
95
|
+
* Override decimal length
|
|
96
|
+
* decimal is the number after the decimal point
|
|
97
|
+
*/
|
|
98
|
+
decimalLength: number;
|
|
99
|
+
validateDecimalLength(newValue: number): void;
|
|
100
|
+
/**
|
|
101
|
+
* Define input pattern to validate
|
|
102
|
+
*/
|
|
103
|
+
valid: boolean;
|
|
104
|
+
/**
|
|
105
|
+
* Define input pattern error message
|
|
106
|
+
*/
|
|
107
|
+
invalid: boolean;
|
|
108
|
+
/**
|
|
109
|
+
* Component classes
|
|
110
|
+
*/
|
|
111
|
+
classList: ClassList;
|
|
112
|
+
/**
|
|
113
|
+
* Error message to display
|
|
114
|
+
*/
|
|
115
|
+
errorMessage: string;
|
|
116
|
+
/**
|
|
117
|
+
* Displayed value in input
|
|
118
|
+
* Change on focus/blur
|
|
119
|
+
*/
|
|
120
|
+
displayValue: string;
|
|
121
|
+
/**
|
|
122
|
+
* Emmited event when value change
|
|
123
|
+
*/
|
|
124
|
+
valueChange: EventEmitter<number>;
|
|
125
|
+
/**
|
|
126
|
+
* Handle input event
|
|
127
|
+
*/
|
|
128
|
+
private handleInput;
|
|
129
|
+
/**
|
|
130
|
+
* Handle focus event
|
|
131
|
+
*/
|
|
132
|
+
private handleFocus;
|
|
133
|
+
/**
|
|
134
|
+
* Handle blur event
|
|
135
|
+
*/
|
|
136
|
+
private handleBlur;
|
|
137
|
+
/**
|
|
138
|
+
* Check if input is valid
|
|
139
|
+
*/
|
|
140
|
+
private checkValidity;
|
|
141
|
+
/**
|
|
142
|
+
* Set error message
|
|
143
|
+
*/
|
|
144
|
+
private setErrorMessage;
|
|
145
|
+
/**
|
|
146
|
+
* Check input errors
|
|
147
|
+
*/
|
|
148
|
+
private checkError;
|
|
149
|
+
/**
|
|
150
|
+
* get input error code
|
|
151
|
+
* @returns {null | InputError}
|
|
152
|
+
*/
|
|
153
|
+
private getInputError;
|
|
154
|
+
/**
|
|
155
|
+
* Format value based on type
|
|
156
|
+
* @param value {number}
|
|
157
|
+
* @returns {string} formated local value
|
|
158
|
+
*/
|
|
159
|
+
private formatValue;
|
|
160
|
+
/**
|
|
161
|
+
* Validate append slot
|
|
162
|
+
*/
|
|
163
|
+
private validateAppendSlot;
|
|
164
|
+
/*************
|
|
165
|
+
* Lifecycle *
|
|
166
|
+
*************/
|
|
167
|
+
componentWillLoad(): NodeJS.Timeout;
|
|
168
|
+
componentDidLoad(): void;
|
|
169
|
+
/**
|
|
170
|
+
* Check if component props are well configured on init
|
|
171
|
+
*/
|
|
172
|
+
render(): any;
|
|
173
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
component: string;
|
|
3
|
+
title: string;
|
|
4
|
+
argTypes: {
|
|
5
|
+
type: {
|
|
6
|
+
options: string[];
|
|
7
|
+
control: {
|
|
8
|
+
type: string;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
export default _default;
|
|
14
|
+
/**
|
|
15
|
+
* Global use
|
|
16
|
+
*/
|
|
17
|
+
export declare const MgInputNumeric: any;
|
|
18
|
+
/**
|
|
19
|
+
* Global use
|
|
20
|
+
*/
|
|
21
|
+
export declare const AppendSlot: any;
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
import { EventEmitter } from '../../../../stencil-public-runtime';
|
|
3
|
+
import { Width } from '../MgInput.conf';
|
|
4
|
+
import { ClassList } from '../../../../utils/components.utils';
|
|
5
|
+
export declare class MgInputPassword {
|
|
6
|
+
/************
|
|
7
|
+
* Internal *
|
|
8
|
+
************/
|
|
9
|
+
private classError;
|
|
10
|
+
private input;
|
|
11
|
+
/**************
|
|
12
|
+
* Decorators *
|
|
13
|
+
**************/
|
|
14
|
+
/**
|
|
15
|
+
* Component value
|
|
16
|
+
*/
|
|
17
|
+
value: string;
|
|
18
|
+
/**
|
|
19
|
+
* Identifier is used for the element ID (id is a reserved prop in Stencil.js)
|
|
20
|
+
* If not set, it will be created.
|
|
21
|
+
*/
|
|
22
|
+
identifier?: string;
|
|
23
|
+
/**
|
|
24
|
+
* Input name
|
|
25
|
+
* If not set the value equals the identifier
|
|
26
|
+
*/
|
|
27
|
+
name?: string;
|
|
28
|
+
/**
|
|
29
|
+
* Input label
|
|
30
|
+
* Required
|
|
31
|
+
*/
|
|
32
|
+
label: string;
|
|
33
|
+
/**
|
|
34
|
+
* Define if label is displayed on top
|
|
35
|
+
*/
|
|
36
|
+
labelOnTop: boolean;
|
|
37
|
+
/**
|
|
38
|
+
* Define if label is visible
|
|
39
|
+
*/
|
|
40
|
+
labelHide: boolean;
|
|
41
|
+
/**
|
|
42
|
+
* Input placeholder.
|
|
43
|
+
* It should be a word or short phrase that demonstrates the expected type of data, not a replacement for labels or help text.
|
|
44
|
+
*/
|
|
45
|
+
placeholder: string;
|
|
46
|
+
/**
|
|
47
|
+
* Define if input is required
|
|
48
|
+
*/
|
|
49
|
+
required: boolean;
|
|
50
|
+
/**
|
|
51
|
+
* Define if input is readonly
|
|
52
|
+
*/
|
|
53
|
+
readonly: boolean;
|
|
54
|
+
/**
|
|
55
|
+
* Define if input is disabled
|
|
56
|
+
*/
|
|
57
|
+
disabled: boolean;
|
|
58
|
+
/**
|
|
59
|
+
* Define input width
|
|
60
|
+
*/
|
|
61
|
+
width: Width;
|
|
62
|
+
/**
|
|
63
|
+
* Add a tooltip message next to the input
|
|
64
|
+
*/
|
|
65
|
+
tooltip: string;
|
|
66
|
+
/**
|
|
67
|
+
* Add a help text under the input, usually expected data format and example
|
|
68
|
+
*/
|
|
69
|
+
helpText: string;
|
|
70
|
+
/**
|
|
71
|
+
* Define input pattern to validate
|
|
72
|
+
*/
|
|
73
|
+
valid: boolean;
|
|
74
|
+
/**
|
|
75
|
+
* Define input pattern error message
|
|
76
|
+
*/
|
|
77
|
+
invalid: boolean;
|
|
78
|
+
/**
|
|
79
|
+
* Component classes
|
|
80
|
+
*/
|
|
81
|
+
classList: ClassList;
|
|
82
|
+
/**
|
|
83
|
+
* Error message to display
|
|
84
|
+
*/
|
|
85
|
+
errorMessage: string;
|
|
86
|
+
/**
|
|
87
|
+
* Emmited event when value change
|
|
88
|
+
*/
|
|
89
|
+
valueChange: EventEmitter<string>;
|
|
90
|
+
/**
|
|
91
|
+
* Handle input event
|
|
92
|
+
*/
|
|
93
|
+
private handleInput;
|
|
94
|
+
/**
|
|
95
|
+
* Handle blur event
|
|
96
|
+
*/
|
|
97
|
+
private handleBlur;
|
|
98
|
+
/**
|
|
99
|
+
* Check if input is valid
|
|
100
|
+
*/
|
|
101
|
+
private checkValidity;
|
|
102
|
+
/**
|
|
103
|
+
* Check input errors
|
|
104
|
+
*/
|
|
105
|
+
private checkError;
|
|
106
|
+
/*************
|
|
107
|
+
* Lifecycle *
|
|
108
|
+
*************/
|
|
109
|
+
componentWillLoad(): NodeJS.Timeout;
|
|
110
|
+
render(): any;
|
|
111
|
+
}
|