@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.
Files changed (271) hide show
  1. package/LICENSE +29 -0
  2. package/dist/cjs/css-shim-a22512c4.js +6 -0
  3. package/dist/cjs/index-85a4a0b6.js +1674 -0
  4. package/dist/cjs/index.cjs.js +2 -0
  5. package/dist/cjs/loader.cjs.js +35 -0
  6. package/dist/cjs/mg-badge_20.cjs.entry.js +4661 -0
  7. package/dist/cjs/mg-components.cjs.js +23 -0
  8. package/dist/cjs/shadow-css-8940f82d.js +390 -0
  9. package/dist/collection/collection-manifest.json +31 -0
  10. package/dist/collection/components/atoms/mg-badge/mg-badge.conf.js +4 -0
  11. package/dist/collection/components/atoms/mg-badge/mg-badge.css +99 -0
  12. package/dist/collection/components/atoms/mg-badge/mg-badge.js +148 -0
  13. package/dist/collection/components/atoms/mg-badge/mg-badge.stories.js +27 -0
  14. package/dist/collection/components/atoms/mg-button/mg-button.conf.js +4 -0
  15. package/dist/collection/components/atoms/mg-button/mg-button.css +134 -0
  16. package/dist/collection/components/atoms/mg-button/mg-button.js +236 -0
  17. package/dist/collection/components/atoms/mg-button/mg-button.stories.js +38 -0
  18. package/dist/collection/components/atoms/mg-character-left/mg-character-left.css +3 -0
  19. package/dist/collection/components/atoms/mg-character-left/mg-character-left.js +133 -0
  20. package/dist/collection/components/atoms/mg-character-left/mg-character-left.stories.js +15 -0
  21. package/dist/collection/components/atoms/mg-icon/mg-icon.conf.js +54 -0
  22. package/dist/collection/components/atoms/mg-icon/mg-icon.css +57 -0
  23. package/dist/collection/components/atoms/mg-icon/mg-icon.js +155 -0
  24. package/dist/collection/components/atoms/mg-icon/mg-icon.stories.js +34 -0
  25. package/dist/collection/components/atoms/mg-input-title/mg-input-title.css +12 -0
  26. package/dist/collection/components/atoms/mg-input-title/mg-input-title.js +95 -0
  27. package/dist/collection/components/atoms/mg-input-title/mg-input-title.stories.js +21 -0
  28. package/dist/collection/components/atoms/mg-tag/mg-tag.conf.js +4 -0
  29. package/dist/collection/components/atoms/mg-tag/mg-tag.css +73 -0
  30. package/dist/collection/components/atoms/mg-tag/mg-tag.js +94 -0
  31. package/dist/collection/components/atoms/mg-tag/mg-tag.stories.js +25 -0
  32. package/dist/collection/components/atoms/mg-tooltip/mg-tooltip.css +44 -0
  33. package/dist/collection/components/atoms/mg-tooltip/mg-tooltip.js +225 -0
  34. package/dist/collection/components/atoms/mg-tooltip/mg-tooltip.stories.js +26 -0
  35. package/dist/collection/components/molecules/inputs/MgInput.conf.js +7 -0
  36. package/dist/collection/components/molecules/inputs/MgInput.js +130 -0
  37. package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.conf.js +1 -0
  38. package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.css +156 -0
  39. package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.js +444 -0
  40. package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.stories.js +57 -0
  41. package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.conf.js +7 -0
  42. package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.css +171 -0
  43. package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.js +467 -0
  44. package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.stories.js +46 -0
  45. package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.conf.js +11 -0
  46. package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.css +199 -0
  47. package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.js +633 -0
  48. package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.stories.js +68 -0
  49. package/dist/collection/components/molecules/inputs/mg-input-password/mg-input-password.css +195 -0
  50. package/dist/collection/components/molecules/inputs/mg-input-password/mg-input-password.js +401 -0
  51. package/dist/collection/components/molecules/inputs/mg-input-password/mg-input-password.stories.js +43 -0
  52. package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.conf.js +1 -0
  53. package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.css +156 -0
  54. package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.js +443 -0
  55. package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.stories.js +65 -0
  56. package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.conf.js +1 -0
  57. package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.css +201 -0
  58. package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.js +532 -0
  59. package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.stories.js +70 -0
  60. package/dist/collection/components/molecules/inputs/mg-input-text/mg-input-text.css +222 -0
  61. package/dist/collection/components/molecules/inputs/mg-input-text/mg-input-text.js +589 -0
  62. package/dist/collection/components/molecules/inputs/mg-input-text/mg-input-text.stories.js +115 -0
  63. package/dist/collection/components/molecules/inputs/mg-input-textarea/mg-input-textarea.css +217 -0
  64. package/dist/collection/components/molecules/inputs/mg-input-textarea/mg-input-textarea.js +553 -0
  65. package/dist/collection/components/molecules/inputs/mg-input-textarea/mg-input-textarea.stories.js +52 -0
  66. package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.conf.js +1 -0
  67. package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.css +213 -0
  68. package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.js +457 -0
  69. package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.stories.js +73 -0
  70. package/dist/collection/components/molecules/mg-message/mg-message.conf.js +4 -0
  71. package/dist/collection/components/molecules/mg-message/mg-message.css +94 -0
  72. package/dist/collection/components/molecules/mg-message/mg-message.js +285 -0
  73. package/dist/collection/components/molecules/mg-message/mg-message.stories.js +43 -0
  74. package/dist/collection/components/molecules/mg-pagination/mg-pagination.conf.js +5 -0
  75. package/dist/collection/components/molecules/mg-pagination/mg-pagination.css +39 -0
  76. package/dist/collection/components/molecules/mg-pagination/mg-pagination.js +218 -0
  77. package/dist/collection/components/molecules/mg-pagination/mg-pagination.stories.js +23 -0
  78. package/dist/collection/components/molecules/mg-popover/mg-popover.css +59 -0
  79. package/dist/collection/components/molecules/mg-popover/mg-popover.js +249 -0
  80. package/dist/collection/components/molecules/mg-popover/mg-popover.stories.js +36 -0
  81. package/dist/collection/components/molecules/mg-tabs/mg-tabs.conf.js +1 -0
  82. package/dist/collection/components/molecules/mg-tabs/mg-tabs.css +30 -0
  83. package/dist/collection/components/molecules/mg-tabs/mg-tabs.js +212 -0
  84. package/dist/collection/components/molecules/mg-tabs/mg-tabs.stories.js +40 -0
  85. package/dist/collection/fonts/OpenSans-Regular.ttf +0 -0
  86. package/dist/collection/fonts/OpenSans-SemiBold.ttf +0 -0
  87. package/dist/collection/fonts/Poppins-Bold.ttf +0 -0
  88. package/dist/collection/index.js +1 -0
  89. package/dist/collection/locales/index.js +4 -0
  90. package/dist/collection/stories/buttons.stories.js +43 -0
  91. package/dist/collection/stories/grids.stories.js +50 -0
  92. package/dist/collection/stories/icons.stories.js +20 -0
  93. package/dist/collection/stories/messages.stories.js +44 -0
  94. package/dist/collection/stories/tags.stories.js +13 -0
  95. package/dist/collection/stories/typography.stories.js +28 -0
  96. package/dist/collection/utils/components.utils.js +67 -0
  97. package/dist/collection/utils/locale.utils.js +32 -0
  98. package/dist/collection/utils/test.utils.js +26 -0
  99. package/dist/collection/variables.css +177 -0
  100. package/dist/collection/variables.scss +177 -0
  101. package/dist/components/MgInput.js +140 -0
  102. package/dist/components/components.utils.js +69 -0
  103. package/dist/components/index.d.ts +26 -0
  104. package/dist/components/index.js +1 -0
  105. package/dist/components/index2.js +54 -0
  106. package/dist/components/locale.utils.js +35 -0
  107. package/dist/components/mg-badge.d.ts +11 -0
  108. package/dist/components/mg-badge.js +6 -0
  109. package/dist/components/mg-badge2.js +82 -0
  110. package/dist/components/mg-button.d.ts +11 -0
  111. package/dist/components/mg-button.js +6 -0
  112. package/dist/components/mg-button2.js +148 -0
  113. package/dist/components/mg-character-left.d.ts +11 -0
  114. package/dist/components/mg-character-left.js +6 -0
  115. package/dist/components/mg-character-left2.js +77 -0
  116. package/dist/components/mg-icon.d.ts +11 -0
  117. package/dist/components/mg-icon.js +6 -0
  118. package/dist/components/mg-icon2.js +147 -0
  119. package/dist/components/mg-input-checkbox.d.ts +11 -0
  120. package/dist/components/mg-input-checkbox.js +222 -0
  121. package/dist/components/mg-input-date.d.ts +11 -0
  122. package/dist/components/mg-input-date.js +245 -0
  123. package/dist/components/mg-input-numeric.d.ts +11 -0
  124. package/dist/components/mg-input-numeric.js +324 -0
  125. package/dist/components/mg-input-password.d.ts +11 -0
  126. package/dist/components/mg-input-password.js +171 -0
  127. package/dist/components/mg-input-radio.d.ts +11 -0
  128. package/dist/components/mg-input-radio.js +211 -0
  129. package/dist/components/mg-input-select.d.ts +11 -0
  130. package/dist/components/mg-input-select.js +6 -0
  131. package/dist/components/mg-input-select2.js +243 -0
  132. package/dist/components/mg-input-text.d.ts +11 -0
  133. package/dist/components/mg-input-text.js +242 -0
  134. package/dist/components/mg-input-textarea.d.ts +11 -0
  135. package/dist/components/mg-input-textarea.js +224 -0
  136. package/dist/components/mg-input-title.d.ts +11 -0
  137. package/dist/components/mg-input-title.js +6 -0
  138. package/dist/components/mg-input-title2.js +55 -0
  139. package/dist/components/mg-input-toggle.d.ts +11 -0
  140. package/dist/components/mg-input-toggle.js +247 -0
  141. package/dist/components/mg-message.d.ts +11 -0
  142. package/dist/components/mg-message.js +183 -0
  143. package/dist/components/mg-pagination.d.ts +11 -0
  144. package/dist/components/mg-pagination.js +175 -0
  145. package/dist/components/mg-popover.d.ts +11 -0
  146. package/dist/components/mg-popover.js +183 -0
  147. package/dist/components/mg-tabs.d.ts +11 -0
  148. package/dist/components/mg-tabs.js +160 -0
  149. package/dist/components/mg-tag.d.ts +11 -0
  150. package/dist/components/mg-tag.js +76 -0
  151. package/dist/components/mg-tooltip.d.ts +11 -0
  152. package/dist/components/mg-tooltip.js +6 -0
  153. package/dist/components/mg-tooltip2.js +150 -0
  154. package/dist/components/popper.js +1784 -0
  155. package/dist/esm/css-shim-7c240feb.js +4 -0
  156. package/dist/esm/index-e3e84606.js +1643 -0
  157. package/dist/esm/index.js +1 -0
  158. package/dist/esm/loader.js +31 -0
  159. package/dist/esm/mg-badge_20.entry.js +4638 -0
  160. package/dist/esm/mg-components.js +21 -0
  161. package/dist/esm/polyfills/core-js.js +11 -0
  162. package/dist/esm/polyfills/css-shim.js +1 -0
  163. package/dist/esm/polyfills/dom.js +79 -0
  164. package/dist/esm/polyfills/es5-html-element.js +1 -0
  165. package/dist/esm/polyfills/index.js +34 -0
  166. package/dist/esm/polyfills/system.js +6 -0
  167. package/dist/esm/shadow-css-5d2d01ce.js +388 -0
  168. package/dist/esm-es5/css-shim-7c240feb.js +1 -0
  169. package/dist/esm-es5/index-e3e84606.js +1 -0
  170. package/dist/esm-es5/index.js +0 -0
  171. package/dist/esm-es5/loader.js +1 -0
  172. package/dist/esm-es5/mg-badge_20.entry.js +2 -0
  173. package/dist/esm-es5/mg-components.js +1 -0
  174. package/dist/esm-es5/shadow-css-5d2d01ce.js +12 -0
  175. package/dist/index.cjs.js +1 -0
  176. package/dist/index.js +1 -0
  177. package/dist/mg-components/fonts/OpenSans-Regular.ttf +0 -0
  178. package/dist/mg-components/fonts/OpenSans-SemiBold.ttf +0 -0
  179. package/dist/mg-components/fonts/Poppins-Bold.ttf +0 -0
  180. package/dist/mg-components/index.esm.js +0 -0
  181. package/dist/mg-components/mg-components.css +1 -0
  182. package/dist/mg-components/mg-components.esm.js +1 -0
  183. package/dist/mg-components/mg-components.js +132 -0
  184. package/dist/mg-components/p-1cd24462.system.js +1 -0
  185. package/dist/mg-components/p-2e2f6b27.system.entry.js +2 -0
  186. package/dist/mg-components/p-366a224e.js +1 -0
  187. package/dist/mg-components/p-422c429b.system.js +1 -0
  188. package/dist/mg-components/p-50ea2036.system.js +1 -0
  189. package/dist/mg-components/p-62fa3797.js +1 -0
  190. package/dist/mg-components/p-71d57b8b.system.js +13 -0
  191. package/dist/mg-components/p-9a215712.system.js +1 -0
  192. package/dist/mg-components/p-cbf0464b.entry.js +1 -0
  193. package/dist/mg-components/p-f6455ab3.js +12 -0
  194. package/dist/mg-components/variables.css +177 -0
  195. package/dist/mg-components/variables.scss +177 -0
  196. package/dist/types/components/atoms/mg-badge/mg-badge.conf.d.ts +8 -0
  197. package/dist/types/components/atoms/mg-badge/mg-badge.d.ts +36 -0
  198. package/dist/types/components/atoms/mg-badge/mg-badge.stories.d.ts +19 -0
  199. package/dist/types/components/atoms/mg-button/mg-button.conf.d.ts +4 -0
  200. package/dist/types/components/atoms/mg-button/mg-button.d.ts +67 -0
  201. package/dist/types/components/atoms/mg-button/mg-button.stories.d.ts +16 -0
  202. package/dist/types/components/atoms/mg-character-left/mg-character-left.d.ts +39 -0
  203. package/dist/types/components/atoms/mg-character-left/mg-character-left.stories.d.ts +7 -0
  204. package/dist/types/components/atoms/mg-icon/mg-icon.conf.d.ts +12 -0
  205. package/dist/types/components/atoms/mg-icon/mg-icon.d.ts +36 -0
  206. package/dist/types/components/atoms/mg-icon/mg-icon.stories.d.ts +26 -0
  207. package/dist/types/components/atoms/mg-input-title/mg-input-title.d.ts +24 -0
  208. package/dist/types/components/atoms/mg-input-title/mg-input-title.stories.d.ts +6 -0
  209. package/dist/types/components/atoms/mg-tag/mg-tag.conf.d.ts +4 -0
  210. package/dist/types/components/atoms/mg-tag/mg-tag.d.ts +25 -0
  211. package/dist/types/components/atoms/mg-tag/mg-tag.stories.d.ts +14 -0
  212. package/dist/types/components/atoms/mg-tooltip/mg-tooltip.d.ts +56 -0
  213. package/dist/types/components/atoms/mg-tooltip/mg-tooltip.stories.d.ts +11 -0
  214. package/dist/types/components/molecules/inputs/MgInput.conf.d.ts +10 -0
  215. package/dist/types/components/molecules/inputs/MgInput.d.ts +35 -0
  216. package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.conf.d.ts +19 -0
  217. package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.d.ts +120 -0
  218. package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.stories.d.ts +6 -0
  219. package/dist/types/components/molecules/inputs/mg-input-date/mg-input-date.conf.d.ts +6 -0
  220. package/dist/types/components/molecules/inputs/mg-input-date/mg-input-date.d.ts +128 -0
  221. package/dist/types/components/molecules/inputs/mg-input-date/mg-input-date.stories.d.ts +7 -0
  222. package/dist/types/components/molecules/inputs/mg-input-numeric/mg-input-numeric.conf.d.ts +10 -0
  223. package/dist/types/components/molecules/inputs/mg-input-numeric/mg-input-numeric.d.ts +173 -0
  224. package/dist/types/components/molecules/inputs/mg-input-numeric/mg-input-numeric.stories.d.ts +21 -0
  225. package/dist/types/components/molecules/inputs/mg-input-password/mg-input-password.d.ts +111 -0
  226. package/dist/types/components/molecules/inputs/mg-input-password/mg-input-password.stories.d.ts +9 -0
  227. package/dist/types/components/molecules/inputs/mg-input-radio/mg-input-radio.conf.d.ts +9 -0
  228. package/dist/types/components/molecules/inputs/mg-input-radio/mg-input-radio.d.ts +121 -0
  229. package/dist/types/components/molecules/inputs/mg-input-radio/mg-input-radio.stories.d.ts +15 -0
  230. package/dist/types/components/molecules/inputs/mg-input-select/mg-input-select.conf.d.ts +18 -0
  231. package/dist/types/components/molecules/inputs/mg-input-select/mg-input-select.d.ts +133 -0
  232. package/dist/types/components/molecules/inputs/mg-input-select/mg-input-select.stories.d.ts +14 -0
  233. package/dist/types/components/molecules/inputs/mg-input-text/mg-input-text.d.ts +160 -0
  234. package/dist/types/components/molecules/inputs/mg-input-text/mg-input-text.stories.d.ts +26 -0
  235. package/dist/types/components/molecules/inputs/mg-input-textarea/mg-input-textarea.d.ts +150 -0
  236. package/dist/types/components/molecules/inputs/mg-input-textarea/mg-input-textarea.stories.d.ts +6 -0
  237. package/dist/types/components/molecules/inputs/mg-input-toggle/mg-input-toggle.conf.d.ts +8 -0
  238. package/dist/types/components/molecules/inputs/mg-input-toggle/mg-input-toggle.d.ts +117 -0
  239. package/dist/types/components/molecules/inputs/mg-input-toggle/mg-input-toggle.stories.d.ts +7 -0
  240. package/dist/types/components/molecules/mg-message/mg-message.conf.d.ts +4 -0
  241. package/dist/types/components/molecules/mg-message/mg-message.d.ts +76 -0
  242. package/dist/types/components/molecules/mg-message/mg-message.stories.d.ts +16 -0
  243. package/dist/types/components/molecules/mg-pagination/mg-pagination.conf.d.ts +4 -0
  244. package/dist/types/components/molecules/mg-pagination/mg-pagination.d.ts +53 -0
  245. package/dist/types/components/molecules/mg-pagination/mg-pagination.stories.d.ts +6 -0
  246. package/dist/types/components/molecules/mg-popover/mg-popover.d.ts +62 -0
  247. package/dist/types/components/molecules/mg-popover/mg-popover.stories.d.ts +12 -0
  248. package/dist/types/components/molecules/mg-tabs/mg-tabs.conf.d.ts +10 -0
  249. package/dist/types/components/molecules/mg-tabs/mg-tabs.d.ts +63 -0
  250. package/dist/types/components/molecules/mg-tabs/mg-tabs.stories.d.ts +7 -0
  251. package/dist/types/components.d.ts +1987 -0
  252. package/dist/types/index.d.ts +1 -0
  253. package/dist/types/locales/index.d.ts +44 -0
  254. package/dist/types/stencil-public-runtime.d.ts +1565 -0
  255. package/dist/types/stories/buttons.stories.d.ts +13 -0
  256. package/dist/types/stories/grids.stories.d.ts +5 -0
  257. package/dist/types/stories/icons.stories.d.ts +13 -0
  258. package/dist/types/stories/messages.stories.d.ts +13 -0
  259. package/dist/types/stories/tags.stories.d.ts +5 -0
  260. package/dist/types/stories/typography.stories.d.ts +5 -0
  261. package/dist/types/utils/components.utils.d.ts +43 -0
  262. package/dist/types/utils/locale.utils.d.ts +22 -0
  263. package/dist/types/utils/test.utils.d.ts +5 -0
  264. package/loader/cdn.js +3 -0
  265. package/loader/index.cjs.js +3 -0
  266. package/loader/index.d.ts +12 -0
  267. package/loader/index.es2017.js +3 -0
  268. package/loader/index.js +4 -0
  269. package/loader/package.json +10 -0
  270. package/package.json +86 -0
  271. 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,6 @@
1
+ declare const _default: {
2
+ component: string;
3
+ title: string;
4
+ };
5
+ export default _default;
6
+ export declare const MgInputCheckbox: any;
@@ -0,0 +1,6 @@
1
+ export declare enum InputError {
2
+ MIN = "min",
3
+ MAX = "max",
4
+ MINMAX = "minMax",
5
+ REQUIRED = "required"
6
+ }
@@ -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,7 @@
1
+ declare const _default: {
2
+ component: string;
3
+ title: string;
4
+ };
5
+ export default _default;
6
+ export declare const MgInputDate: any;
7
+ export declare const MgInputDateMinMax: any;
@@ -0,0 +1,10 @@
1
+ /**
2
+ * List of all possibles types
3
+ */
4
+ export declare const types: string[];
5
+ export declare enum InputError {
6
+ MIN = "min",
7
+ MAX = "max",
8
+ MINMAX = "minMax",
9
+ REQUIRED = "required"
10
+ }
@@ -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
+ }
@@ -0,0 +1,9 @@
1
+ declare const _default: {
2
+ component: string;
3
+ title: string;
4
+ };
5
+ export default _default;
6
+ /**
7
+ * Global use
8
+ */
9
+ export declare const MgInputPassword: any;
@@ -0,0 +1,9 @@
1
+ /**
2
+ * type RadioOption
3
+ * use to match radio attributes
4
+ */
5
+ export declare type RadioOption = {
6
+ title: string;
7
+ value: any;
8
+ disabled?: boolean;
9
+ };