@mgdis/mg-components 6.14.0 → 6.15.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/dist/cjs/{index-DzBkSgSK.js → index-BGxkpQwi.js} +7 -1
- package/dist/cjs/{index-DUJwxnoi.js → index-CpENFzEo.js} +2 -2
- package/dist/cjs/{index-CwjAofQ1.js → index-iUZvsp-F.js} +55 -31
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/mg-action-more_37.cjs.entry.js +431 -208
- package/dist/cjs/mg-alert.cjs.entry.js +4 -4
- package/dist/cjs/mg-components.cjs.js +3 -3
- package/dist/cjs/mg-input-combobox.cjs.entry.js +145 -81
- package/dist/cjs/mg-input-rich-text-editor.cjs.entry.js +1248 -16004
- package/dist/cjs/{mg-input.conf-WTsvDfpC.js → mg-input.conf-CwjEAih3.js} +7 -0
- package/dist/cjs/mg-input.utils-D-ASK4ua.js +49 -0
- package/dist/cjs/mg-loader.cjs.entry.js +4 -4
- package/dist/cjs/mg-progress.cjs.entry.js +3 -3
- package/dist/collection/assets/icons/index.js +1 -1
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/atoms/mg-icon/mg-icon.js +1 -1
- package/dist/collection/components/molecules/inputs/mg-input/mg-input.conf.js +6 -0
- package/dist/collection/components/molecules/inputs/mg-input/mg-input.js +93 -22
- package/dist/collection/components/molecules/inputs/mg-input/mg-input.utils.js +21 -0
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/MgInputCheckboxList.js +2 -1
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox-paginated/mg-input-checkbox-paginated.js +49 -106
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.js +123 -48
- package/dist/collection/components/molecules/inputs/mg-input-combobox/mg-input-combobox.js +140 -56
- package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.js +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.js +6 -1
- package/dist/collection/components/molecules/inputs/mg-input-password/mg-input-password.js +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.js +63 -10
- package/dist/collection/components/molecules/inputs/mg-input-rich-text-editor/mg-input-rich-text-editor.js +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.js +54 -6
- package/dist/collection/components/molecules/inputs/mg-input-text/mg-input-text.js +2 -2
- package/dist/collection/components/molecules/inputs/mg-input-textarea/mg-input-textarea.js +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.js +142 -9
- package/dist/collection/components/molecules/internals/mg-item-more/mg-item-more.js +1 -1
- package/dist/collection/components/molecules/mg-action-more/mg-action-more.js +2 -2
- package/dist/collection/components/molecules/mg-alert/mg-alert.js +1 -1
- package/dist/collection/components/molecules/mg-details/mg-details.js +1 -1
- package/dist/collection/components/molecules/mg-form/mg-form.js +1 -1
- package/dist/collection/components/molecules/mg-illustrated-message/mg-illustrated-message.js +1 -1
- package/dist/collection/components/molecules/mg-loader/mg-loader.js +1 -1
- package/dist/collection/components/molecules/mg-message/mg-message.js +2 -2
- package/dist/collection/components/molecules/mg-modal/mg-modal.js +2 -2
- package/dist/collection/components/molecules/mg-panel/mg-panel.js +1 -1
- package/dist/collection/components/molecules/mg-popover/mg-popover-content/mg-popover-content.js +1 -1
- package/dist/collection/components/molecules/mg-popover/mg-popover.js +1 -1
- package/dist/collection/components/molecules/mg-progress/mg-progress.js +1 -1
- package/dist/collection/components/molecules/mg-skip-links/mg-skip-links.js +1 -1
- package/dist/collection/components/molecules/mg-table/mg-table.js +2 -2
- package/dist/collection/components/molecules/mg-tabs/mg-tabs.js +1 -1
- package/dist/collection/locales/en/messages.json +23 -14
- package/dist/collection/locales/fr/messages.json +24 -15
- package/dist/components/index2.js +3 -3
- package/dist/components/index3.js +55 -31
- package/dist/components/mg-action-more.js +2 -2
- package/dist/components/mg-alert.js +2 -2
- package/dist/components/mg-badge2.js +1 -1
- package/dist/components/mg-button2.js +1 -1
- package/dist/components/mg-card2.js +1 -1
- package/dist/components/mg-character-left2.js +1 -1
- package/dist/components/mg-details.js +1 -97
- package/dist/components/mg-details2.js +99 -0
- package/dist/components/mg-divider2.js +1 -1
- package/dist/components/mg-form.js +2 -2
- package/dist/components/mg-icon2.js +1 -1
- package/dist/components/mg-illustrated-message.js +2 -2
- package/dist/components/mg-input-checkbox-paginated2.js +43 -124
- package/dist/components/mg-input-checkbox.js +136 -62
- package/dist/components/mg-input-combobox.js +135 -63
- package/dist/components/mg-input-date.js +9 -3
- package/dist/components/mg-input-numeric.js +14 -3
- package/dist/components/mg-input-password.js +10 -4
- package/dist/components/mg-input-radio.js +54 -13
- package/dist/components/mg-input-rich-text-editor.js +1266 -16016
- package/dist/components/mg-input-select2.js +45 -9
- package/dist/components/mg-input-text2.js +10 -4
- package/dist/components/mg-input-textarea.js +10 -4
- package/dist/components/mg-input-title2.js +1 -1
- package/dist/components/mg-input-toggle.js +97 -12
- package/dist/components/mg-input.utils.js +24 -0
- package/dist/components/mg-input2.js +100 -23
- package/dist/components/mg-item-more2.js +2 -2
- package/dist/components/mg-loader2.js +2 -2
- package/dist/components/mg-menu-item2.js +1 -1
- package/dist/components/mg-message2.js +3 -3
- package/dist/components/mg-modal.js +3 -3
- package/dist/components/mg-pagination.js +233 -1
- package/dist/components/mg-panel.js +14 -8
- package/dist/components/mg-popover-content2.js +2 -2
- package/dist/components/mg-popover2.js +2 -2
- package/dist/components/mg-progress.js +2 -2
- package/dist/components/mg-skip-links.js +2 -2
- package/dist/components/mg-table.js +3 -3
- package/dist/components/mg-tabs.js +1 -311
- package/dist/components/mg-tabs2.js +313 -0
- package/dist/components/mg-tag.js +1 -1
- package/dist/components/mg-tooltip-content2.js +1 -1
- package/dist/components/mg-tooltip2.js +2 -2
- package/dist/esm/{index-Bv7NHR-W.js → index-CKB-AnCZ.js} +55 -31
- package/dist/esm/{index-Degtjvph.js → index-DhAOnZJn.js} +7 -1
- package/dist/esm/{index-Dr7GYvIz.js → index-WtiuOkLj.js} +2 -2
- package/dist/esm/loader.js +3 -3
- package/dist/esm/mg-action-more_37.entry.js +426 -203
- package/dist/esm/mg-alert.entry.js +4 -4
- package/dist/esm/mg-components.js +4 -4
- package/dist/esm/mg-input-combobox.entry.js +125 -61
- package/dist/esm/mg-input-rich-text-editor.entry.js +1249 -16005
- package/dist/esm/{mg-input.conf-CNgv8hc5.js → mg-input.conf-BAUTlb6r.js} +7 -1
- package/dist/esm/mg-input.utils-BYI03zSi.js +46 -0
- package/dist/esm/mg-loader.entry.js +4 -4
- package/dist/esm/mg-progress.entry.js +3 -3
- package/dist/mg-components/locales/en/messages.json +23 -14
- package/dist/mg-components/locales/fr/messages.json +24 -15
- package/dist/mg-components/mg-components.esm.js +1 -1
- package/dist/mg-components/p-31856cff.entry.js +1 -0
- package/dist/mg-components/{p-056ba467.entry.js → p-420daa1e.entry.js} +1 -1
- package/dist/mg-components/{p-d13a6fdc.entry.js → p-47e19783.entry.js} +1 -1
- package/dist/mg-components/p-67af6274.entry.js +1 -0
- package/dist/mg-components/p-698dfc6c.entry.js +1 -0
- package/dist/mg-components/p-BAUTlb6r.js +1 -0
- package/dist/mg-components/p-CKB-AnCZ.js +1 -0
- package/dist/mg-components/p-DhAOnZJn.js +2 -0
- package/dist/mg-components/p-PuX-pdL4.js +1 -0
- package/dist/mg-components/p-WtiuOkLj.js +1 -0
- package/dist/mg-components/p-a0fa44cf.entry.js +1 -0
- package/dist/types/assets/icons/index.d.ts +6 -0
- package/dist/types/components/molecules/inputs/mg-input/mg-input.conf.d.ts +13 -0
- package/dist/types/components/molecules/inputs/mg-input/mg-input.d.ts +15 -4
- package/dist/types/components/molecules/inputs/mg-input/mg-input.utils.d.ts +8 -0
- package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox-paginated/mg-input-checkbox-paginated.d.ts +17 -40
- package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.conf.d.ts +1 -2
- package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.d.ts +36 -9
- package/dist/types/components/molecules/inputs/mg-input-combobox/mg-input-combobox.d.ts +17 -3
- package/dist/types/components/molecules/inputs/mg-input-radio/mg-input-radio.d.ts +18 -0
- package/dist/types/components/molecules/inputs/mg-input-select/mg-input-select.d.ts +18 -0
- package/dist/types/components/molecules/inputs/mg-input-toggle/mg-input-toggle.d.ts +40 -4
- package/dist/types/components.d.ts +69 -40
- package/ide/intellij/web-types.json +148 -22
- package/ide/vscode/html-custom-data.json +143 -9
- package/package.json +15 -15
- package/dist/cjs/events.utils-D5SAtkpQ.js +0 -25
- package/dist/components/mg-pagination2.js +0 -229
- package/dist/esm/events.utils-yMGqY8YG.js +0 -23
- package/dist/mg-components/p-625c463c.entry.js +0 -1
- package/dist/mg-components/p-Bv7NHR-W.js +0 -1
- package/dist/mg-components/p-CNgv8hc5.js +0 -1
- package/dist/mg-components/p-Degtjvph.js +0 -2
- package/dist/mg-components/p-Dr7GYvIz.js +0 -1
- package/dist/mg-components/p-c522f3c1.entry.js +0 -1
- package/dist/mg-components/p-cac23bd7.entry.js +0 -1
- package/dist/mg-components/p-e75f5383.entry.js +0 -10
- package/dist/mg-components/p-yMGqY8YG.js +0 -1
|
@@ -14,8 +14,8 @@
|
|
|
14
14
|
"components/atoms/mg-tooltip/mg-tooltip.js",
|
|
15
15
|
"components/atoms/mg-tooltip/mg-tooltip-content/mg-tooltip-content.js",
|
|
16
16
|
"components/molecules/inputs/mg-input/mg-input.js",
|
|
17
|
-
"components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.js",
|
|
18
17
|
"components/molecules/inputs/mg-input-checkbox/mg-input-checkbox-paginated/mg-input-checkbox-paginated.js",
|
|
18
|
+
"components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.js",
|
|
19
19
|
"components/molecules/inputs/mg-input-combobox/mg-input-combobox.js",
|
|
20
20
|
"components/molecules/inputs/mg-input-date/mg-input-date.js",
|
|
21
21
|
"components/molecules/inputs/mg-input-numeric/mg-input-numeric.js",
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
],
|
|
46
46
|
"compiler": {
|
|
47
47
|
"name": "@stencil/core",
|
|
48
|
-
"version": "4.36.
|
|
48
|
+
"version": "4.36.2",
|
|
49
49
|
"typescriptVersion": "5.5.4"
|
|
50
50
|
},
|
|
51
51
|
"collections": [],
|
|
@@ -139,7 +139,7 @@ export class MgIcon {
|
|
|
139
139
|
"mutable": false,
|
|
140
140
|
"complexType": {
|
|
141
141
|
"original": "IconType",
|
|
142
|
-
"resolved": "\"filter\" | \"link\" | \"picture\" | \"table\" | \"circle\" | \"download\" | \"key\" | \"list\" | \"copy\" | \"history\" | \"location\" | \"loader\" | \"address-card\" | \"address-card-outline\" | \"align-center\" | \"align-justify\" | \"align-left\" | \"align-right\" | \"api\" | \"archive\" | \"archive-outline\" | \"arrow-clock\" | \"arrow-down\" | \"arrow-down-a-z\" | \"arrow-down-right\" | \"arrow-left\" | \"arrow-right\" | \"arrow-rotate\" | \"arrow-rotate-backward\" | \"arrow-up\" | \"arrow-up-right\" | \"arrow-up-right-square\" | \"arrow-up-z-a\" | \"arrows-compare\" | \"arrows-right-down\" | \"arrows-right-left\" | \"arrows-rotate\" | \"arrows-rotate-backward\" | \"arrows-up-down\" | \"ban\" | \"bell\" | \"bell-outline\" | \"book\" | \"book-outline\" | \"briefcase\" | \"briefcase-outline\" | \"building-outline\" | \"calculator\" | \"calculator-outline\" | \"calendar\" | \"calendar-euro\" | \"calendar-euro-outline\" | \"calendar-outline\" | \"check\" | \"check-circle\" | \"check-circle-outline\" | \"chevron-down\" | \"chevron-down-circle\" | \"chevron-left\" | \"chevron-left-circle\" | \"chevron-right\" | \"chevron-right-circle\" | \"chevron-up\" | \"chevron-up-circle\" | \"clock\" | \"clock-outline\" | \"code-square-outline\" | \"cog\" | \"cog-outline\" | \"comment\" | \"comment-outline\" | \"comment-sms\" | \"conversation\" | \"conversation-outline\" | \"copy-file\" | \"copy-file-outline\" | \"copy-outline\" | \"credit-card\" | \"cross\" | \"cross-circle\" | \"cross-circle-outline\" | \"dashboard\" | \"dashboard-outline\" | \"earth\" | \"earth-outline\" | \"ellipsis\" | \"ellipsis-vertical\" | \"euro\" | \"euro-circle\" | \"exclamation-circle\" | \"exclamation-circle-outline\" | \"exclamation-stamp\" | \"exclamation-triangle\" | \"exclamation-triangle-outline\" | \"eye\" | \"eye-outline\" | \"eye-slash\" | \"eye-slash-outline\" | \"fax\" | \"fax-outline\" | \"file\" | \"file-cog\" | \"file-download\" | \"file-excel\" | \"file-excel-outline\" | \"file-outline\" | \"file-pdf\" | \"file-pdf-outline\" | \"file-text\" | \"file-text-outline\" | \"file-upload\" | \"file-word\" | \"file-word-outline\" | \"filter-outline\" | \"floppy-disk\" | \"floppy-disk-checked\" | \"floppy-disk-checked-outline\" | \"floppy-disk-outline\" | \"folder\" | \"folder-check\" | \"folder-check-outline\" | \"folder-lines\" | \"folder-lines-outline\" | \"folder-link\" | \"folder-link-outline\" | \"folder-outline\" | \"folder-star\" | \"folders\" | \"folders-outline\" | \"gavel\" | \"gavel-outline\" | \"graduation-cap\" | \"graduation-cap-outline\" | \"hand-euro\" | \"hand-euro-outline\" | \"hand-up\" | \"home\" | \"home-outline\" | \"info-circle\" | \"info-circle-outline\" | \"interrogation-circle\" | \"interrogation-circle-outline\" | \"laptop\" | \"layers\" | \"life-ring\" | \"lines-rectangle\" | \"lines-rectangle-outline\" | \"location-outline\" | \"lock\" | \"lock-outline\" | \"log-in\" | \"log-out\" | \"magnifying-glass\" | \"mail\" | \"mail-outline\" | \"messages-square\" | \"messages-square-outline\" | \"mobile\" | \"mobile-outline\" | \"notes\" | \"notes-outline\" | \"paper-plane\" | \"paper-plane-outline\" | \"paper-plane-slash\" | \"paper-plane-slash-outline\" | \"paperclip\" | \"pen\" | \"pen-circle\" | \"pen-fancy\" | \"pen-fancy-files-outline\" | \"pen-fancy-outline\" | \"pen-outline\" | \"phone\" | \"phone-outline\" | \"picture-outline\" | \"play-circle\" | \"plus\" | \"plus-circle\" | \"share\" | \"share-outline\" | \"shuffle\" | \"sitemap\" | \"sliders\" | \"sliders-outline\" | \"squares\" | \"star\" | \"star-outline\" | \"tag\" | \"tag-outline\" | \"tags\" | \"tags-outline\" | \"thumb-down\" | \"thumb-down-outline\" | \"thumb-up\" | \"thumb-up-outline\" | \"thumbtack\" | \"thumbtack-outline\" | \"trash\" | \"trash-outline\" | \"universal-access\" | \"universal-access-outline\" | \"unlink\" | \"unlock\" | \"unlock-outline\" | \"upload\" | \"user\" | \"user-circle\" | \"user-group\" | \"user-group-outline\" | \"user-lock\" | \"user-outline\" | \"user-pen-fancy-outline\" | \"user-plus\" | \"user-question-outline\" | \"user-shield\" | \"user-shield-outline\" | \"users\" | \"users-outline\" | \"wallet\" | \"wallet-outline\"",
|
|
142
|
+
"resolved": "\"filter\" | \"link\" | \"picture\" | \"table\" | \"circle\" | \"download\" | \"key\" | \"list\" | \"copy\" | \"history\" | \"location\" | \"loader\" | \"address-card\" | \"address-card-outline\" | \"align-center\" | \"align-justify\" | \"align-left\" | \"align-right\" | \"api\" | \"archive\" | \"archive-outline\" | \"arrow-clock\" | \"arrow-down\" | \"arrow-down-a-z\" | \"arrow-down-right\" | \"arrow-left\" | \"arrow-right\" | \"arrow-rotate\" | \"arrow-rotate-backward\" | \"arrow-up\" | \"arrow-up-right\" | \"arrow-up-right-square\" | \"arrow-up-z-a\" | \"arrows-compare\" | \"arrows-right-down\" | \"arrows-right-left\" | \"arrows-rotate\" | \"arrows-rotate-backward\" | \"arrows-up-down\" | \"ban\" | \"bell\" | \"bell-outline\" | \"book\" | \"book-outline\" | \"briefcase\" | \"briefcase-outline\" | \"building-outline\" | \"calculator\" | \"calculator-outline\" | \"calendar\" | \"calendar-euro\" | \"calendar-euro-outline\" | \"calendar-outline\" | \"check\" | \"check-circle\" | \"check-circle-outline\" | \"chevron-down\" | \"chevron-down-circle\" | \"chevron-left\" | \"chevron-left-circle\" | \"chevron-right\" | \"chevron-right-circle\" | \"chevron-up\" | \"chevron-up-circle\" | \"clock\" | \"clock-outline\" | \"code-square-outline\" | \"cog\" | \"cog-outline\" | \"comment\" | \"comment-exclamation\" | \"comment-exclamation-outline\" | \"comment-outline\" | \"comment-question\" | \"comment-question-outline\" | \"comment-sms\" | \"conversation\" | \"conversation-outline\" | \"copy-file\" | \"copy-file-outline\" | \"copy-outline\" | \"credit-card\" | \"cross\" | \"cross-circle\" | \"cross-circle-outline\" | \"dashboard\" | \"dashboard-outline\" | \"earth\" | \"earth-outline\" | \"ellipsis\" | \"ellipsis-vertical\" | \"euro\" | \"euro-circle\" | \"exclamation-circle\" | \"exclamation-circle-outline\" | \"exclamation-stamp\" | \"exclamation-triangle\" | \"exclamation-triangle-outline\" | \"eye\" | \"eye-outline\" | \"eye-slash\" | \"eye-slash-outline\" | \"fax\" | \"fax-outline\" | \"file\" | \"file-cog\" | \"file-download\" | \"file-excel\" | \"file-excel-outline\" | \"file-outline\" | \"file-pdf\" | \"file-pdf-outline\" | \"file-text\" | \"file-text-outline\" | \"file-upload\" | \"file-word\" | \"file-word-outline\" | \"filter-outline\" | \"floppy-disk\" | \"floppy-disk-checked\" | \"floppy-disk-checked-outline\" | \"floppy-disk-outline\" | \"folder\" | \"folder-check\" | \"folder-check-outline\" | \"folder-lines\" | \"folder-lines-outline\" | \"folder-link\" | \"folder-link-outline\" | \"folder-outline\" | \"folder-star\" | \"folders\" | \"folders-outline\" | \"gavel\" | \"gavel-outline\" | \"graduation-cap\" | \"graduation-cap-outline\" | \"hand-euro\" | \"hand-euro-outline\" | \"hand-up\" | \"home\" | \"home-outline\" | \"info-circle\" | \"info-circle-outline\" | \"interrogation-circle\" | \"interrogation-circle-outline\" | \"laptop\" | \"layers\" | \"life-ring\" | \"lines-rectangle\" | \"lines-rectangle-outline\" | \"location-outline\" | \"lock\" | \"lock-outline\" | \"log-in\" | \"log-out\" | \"magnifying-glass\" | \"mail\" | \"mail-open\" | \"mail-open-outline\" | \"mail-outline\" | \"messages-square\" | \"messages-square-outline\" | \"mobile\" | \"mobile-outline\" | \"notes\" | \"notes-outline\" | \"paper-plane\" | \"paper-plane-outline\" | \"paper-plane-slash\" | \"paper-plane-slash-outline\" | \"paperclip\" | \"pen\" | \"pen-circle\" | \"pen-fancy\" | \"pen-fancy-files-outline\" | \"pen-fancy-outline\" | \"pen-outline\" | \"phone\" | \"phone-outline\" | \"picture-outline\" | \"play-circle\" | \"plus\" | \"plus-circle\" | \"share\" | \"share-outline\" | \"shuffle\" | \"sitemap\" | \"sliders\" | \"sliders-outline\" | \"squares\" | \"star\" | \"star-outline\" | \"tag\" | \"tag-outline\" | \"tags\" | \"tags-outline\" | \"thumb-down\" | \"thumb-down-outline\" | \"thumb-up\" | \"thumb-up-outline\" | \"thumbtack\" | \"thumbtack-outline\" | \"trash\" | \"trash-outline\" | \"universal-access\" | \"universal-access-outline\" | \"unlink\" | \"unlock\" | \"unlock-outline\" | \"upload\" | \"user\" | \"user-circle\" | \"user-group\" | \"user-group-outline\" | \"user-lock\" | \"user-outline\" | \"user-pen-fancy-outline\" | \"user-plus\" | \"user-question-outline\" | \"user-shield\" | \"user-shield-outline\" | \"users\" | \"users-outline\" | \"wallet\" | \"wallet-outline\"",
|
|
143
143
|
"references": {
|
|
144
144
|
"IconType": {
|
|
145
145
|
"location": "import",
|
|
@@ -10,3 +10,9 @@ export const classFieldset = 'mg-c-input--fieldset';
|
|
|
10
10
|
export const classDisabled = 'mg-c-input--disabled';
|
|
11
11
|
export const classReadonly = 'mg-c-input--readonly';
|
|
12
12
|
export const classVerticalList = 'mg-c-input--vertical-list';
|
|
13
|
+
/**
|
|
14
|
+
* Define cutom errors
|
|
15
|
+
*/
|
|
16
|
+
export const CustomError = {
|
|
17
|
+
NoValue: 'noValue',
|
|
18
|
+
};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { h, Host } from "@stencil/core";
|
|
2
|
-
import { isValideID, isValidString, toString } from "@mgdis/core-ui-helpers/dist/utils";
|
|
2
|
+
import { isObject, isValideID, isValidString, toString } from "@mgdis/core-ui-helpers/dist/utils";
|
|
3
3
|
import { tooltipPositions, classFieldset, classReadonly, classDisabled, classVerticalList } from "./mg-input.conf";
|
|
4
|
+
import { initLocales } from "../../../../locales";
|
|
5
|
+
const isValidErrorMessageType = (msg) => isObject(msg) && ['summary', 'details'].every(key => typeof msg[key] === 'string');
|
|
4
6
|
/**
|
|
5
7
|
* @slot - Input content
|
|
6
8
|
*/
|
|
@@ -8,6 +10,8 @@ export class MgInput {
|
|
|
8
10
|
constructor() {
|
|
9
11
|
this.slotLabel = 'label';
|
|
10
12
|
this.slotError = 'error';
|
|
13
|
+
this.slotSummary = 'summary';
|
|
14
|
+
this.slotDetails = 'details';
|
|
11
15
|
this.slotHelpText = 'help-text';
|
|
12
16
|
// style
|
|
13
17
|
this.classInput = 'mg-c-input';
|
|
@@ -49,6 +53,44 @@ export class MgInput {
|
|
|
49
53
|
* Element is disabled
|
|
50
54
|
*/
|
|
51
55
|
this.isVerticalList = false;
|
|
56
|
+
/**
|
|
57
|
+
* Render error message details element
|
|
58
|
+
*/
|
|
59
|
+
this.renderErrorDetailsMessage = (message) => {
|
|
60
|
+
var _a, _b;
|
|
61
|
+
// remove error slot if it is NOT a MG-DETAIL
|
|
62
|
+
if (((_a = this.errorMessageSlotElement) === null || _a === void 0 ? void 0 : _a.nodeName) !== 'MG-DETAILS') {
|
|
63
|
+
(_b = this.errorMessageSlotElement) === null || _b === void 0 ? void 0 : _b.remove();
|
|
64
|
+
}
|
|
65
|
+
// create OR update error summary
|
|
66
|
+
let summarySlotElement = this.element.querySelector(`[slot=${this.slotError}] [slot=${this.slotSummary}]`);
|
|
67
|
+
if (summarySlotElement === null) {
|
|
68
|
+
summarySlotElement = document.createElement('span');
|
|
69
|
+
summarySlotElement.setAttribute('slot', this.slotSummary);
|
|
70
|
+
}
|
|
71
|
+
summarySlotElement.innerHTML = message.summary;
|
|
72
|
+
// create OR update error details
|
|
73
|
+
let detailsSlotElement = this.element.querySelector(`[slot=${this.slotError}] [slot=${this.slotDetails}]`);
|
|
74
|
+
if (detailsSlotElement === null) {
|
|
75
|
+
detailsSlotElement = document.createElement('p');
|
|
76
|
+
detailsSlotElement.setAttribute('slot', this.slotDetails);
|
|
77
|
+
detailsSlotElement.classList.add('mg-c-input__error-details');
|
|
78
|
+
}
|
|
79
|
+
detailsSlotElement.innerHTML = message.details;
|
|
80
|
+
// create error mg-details
|
|
81
|
+
let mgDetails = this.element.querySelector(`mg-details[slot=${this.slotError}]`);
|
|
82
|
+
if (mgDetails === null) {
|
|
83
|
+
mgDetails = document.createElement('mg-details');
|
|
84
|
+
mgDetails.classList.add('mg-c-input__error');
|
|
85
|
+
mgDetails.toggleClosed = this.messages.details.toggleClosed;
|
|
86
|
+
mgDetails.toggleOpened = this.messages.details.toggleOpened;
|
|
87
|
+
mgDetails.hideSummary = true;
|
|
88
|
+
mgDetails.appendChild(summarySlotElement);
|
|
89
|
+
mgDetails.appendChild(detailsSlotElement);
|
|
90
|
+
this.element.appendChild(mgDetails);
|
|
91
|
+
}
|
|
92
|
+
this.errorMessageSlotElement = mgDetails;
|
|
93
|
+
};
|
|
52
94
|
/**
|
|
53
95
|
* Get tooltip node
|
|
54
96
|
* @returns mg-tooltip
|
|
@@ -86,16 +128,14 @@ export class MgInput {
|
|
|
86
128
|
}
|
|
87
129
|
}
|
|
88
130
|
watchErrorMessage(newValue) {
|
|
89
|
-
|
|
90
|
-
if (newValue !== undefined) {
|
|
131
|
+
if (isValidString(newValue) || isValidErrorMessageType(newValue)) {
|
|
91
132
|
this.element.classList.add(this.classHasError);
|
|
92
|
-
this.renderErrorMessage();
|
|
93
133
|
}
|
|
94
134
|
else {
|
|
95
135
|
this.element.classList.remove(this.classHasError);
|
|
96
|
-
(_a = this.errorMessageSlotElement) === null || _a === void 0 ? void 0 : _a.remove();
|
|
97
|
-
this.errorMessageSlotElement = undefined;
|
|
98
136
|
}
|
|
137
|
+
// update error message slot
|
|
138
|
+
this.renderErrorMessageSlot();
|
|
99
139
|
}
|
|
100
140
|
watchHelpText(newValue) {
|
|
101
141
|
var _a;
|
|
@@ -124,14 +164,12 @@ export class MgInput {
|
|
|
124
164
|
// Help text
|
|
125
165
|
if (this.helpText !== undefined) {
|
|
126
166
|
this.renderHelpText();
|
|
127
|
-
|
|
128
|
-
ariaDescribedbyIDs.add(this.helpTextId);
|
|
167
|
+
ariaDescribedbyIDs.add(this.helpTextId);
|
|
129
168
|
}
|
|
130
169
|
// Error Message
|
|
131
170
|
if (this.errorMessage !== undefined) {
|
|
132
|
-
this.
|
|
133
|
-
|
|
134
|
-
ariaDescribedbyIDs.add(this.helpTextErrorId);
|
|
171
|
+
this.renderErrorMessageSlot();
|
|
172
|
+
ariaDescribedbyIDs.add(this.helpTextErrorId);
|
|
135
173
|
}
|
|
136
174
|
this.element.querySelectorAll('input,select,textarea,[role="switch"]').forEach(element => {
|
|
137
175
|
if (ariaDescribedbyIDs.size > 0) {
|
|
@@ -197,17 +235,41 @@ export class MgInput {
|
|
|
197
235
|
this.element.appendChild(labelSlotElement);
|
|
198
236
|
}
|
|
199
237
|
/**
|
|
200
|
-
* Render error message
|
|
238
|
+
* Render error message element
|
|
201
239
|
*/
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
if
|
|
240
|
+
renderErrorStringMessage(message) {
|
|
241
|
+
var _a;
|
|
242
|
+
// remove error slot if it is a MG-DETAIL
|
|
243
|
+
if (((_a = this.errorMessageSlotElement) === null || _a === void 0 ? void 0 : _a.nodeName) === 'MG-DETAILS') {
|
|
244
|
+
this.errorMessageSlotElement.remove();
|
|
245
|
+
}
|
|
246
|
+
// create element if it does NOT exist
|
|
247
|
+
else if (this.errorMessageSlotElement === null) {
|
|
205
248
|
this.errorMessageSlotElement = document.createElement('div');
|
|
206
|
-
this.errorMessageSlotElement.setAttribute('slot', this.slotError);
|
|
207
249
|
this.element.appendChild(this.errorMessageSlotElement);
|
|
208
250
|
}
|
|
209
|
-
this.errorMessageSlotElement.
|
|
210
|
-
|
|
251
|
+
this.errorMessageSlotElement.innerHTML = message;
|
|
252
|
+
}
|
|
253
|
+
/**
|
|
254
|
+
* Render error message slot element
|
|
255
|
+
*/
|
|
256
|
+
renderErrorMessageSlot() {
|
|
257
|
+
var _a;
|
|
258
|
+
this.errorMessageSlotElement = this.element.querySelector(`[slot=${this.slotError}]`);
|
|
259
|
+
if (this.errorMessage !== undefined) {
|
|
260
|
+
if (typeof this.errorMessage === 'string') {
|
|
261
|
+
this.renderErrorStringMessage(this.errorMessage);
|
|
262
|
+
}
|
|
263
|
+
else {
|
|
264
|
+
this.renderErrorDetailsMessage(this.errorMessage);
|
|
265
|
+
}
|
|
266
|
+
this.errorMessageSlotElement.setAttribute('slot', this.slotError);
|
|
267
|
+
this.errorMessageSlotElement.setAttribute('id', this.helpTextErrorId);
|
|
268
|
+
}
|
|
269
|
+
else {
|
|
270
|
+
(_a = this.errorMessageSlotElement) === null || _a === void 0 ? void 0 : _a.remove();
|
|
271
|
+
this.errorMessageSlotElement = undefined;
|
|
272
|
+
}
|
|
211
273
|
}
|
|
212
274
|
/**
|
|
213
275
|
* Render help text message
|
|
@@ -229,6 +291,9 @@ export class MgInput {
|
|
|
229
291
|
* Check if component props are well configured on init
|
|
230
292
|
*/
|
|
231
293
|
componentWillLoad() {
|
|
294
|
+
// Get locales
|
|
295
|
+
this.messages = initLocales(this.element).messages;
|
|
296
|
+
// Validate
|
|
232
297
|
this.watchIdentifier(this.identifier);
|
|
233
298
|
this.watchLabel();
|
|
234
299
|
this.watchClass();
|
|
@@ -253,7 +318,7 @@ export class MgInput {
|
|
|
253
318
|
*/
|
|
254
319
|
render() {
|
|
255
320
|
const isGroup = this.isFieldset && !this.isReadonly;
|
|
256
|
-
return (h(Host, { key: '
|
|
321
|
+
return (h(Host, { key: '0641f834a725708ce254e82a86c3a75f1c183c0a', class: this.element.classList.toString(), role: isGroup ? 'group' : undefined, "aria-labelledby": isGroup ? `${this.identifier}-title` : undefined }, h("div", { key: '7d96f125694996407b8cecd9491366c39fd0d05f', class: { 'mg-c-input__title': true, 'mg-u-visually-hidden': this.labelHide } }, h("slot", { key: '43720fcecc55de1cae61607b2ae2c3b224e18dbd', name: this.slotLabel }), this.tooltip && (this.tooltipPosition === 'label' || this.labelOnTop) && !this.labelHide && this.renderTooltip()), h("div", { key: '1d9c6fc50758fd2b87d9a15b9983f6e944a9851e', class: "mg-c-input__input-container" }, h("div", { key: '983153a1e0d5777d11cc61af47a4231f093d7e9e', class: "mg-c-input__input" }, h("slot", { key: 'e3ae53d7484b193538c7c5ed68d02ddf3428eff4' }), this.tooltip && !this.labelOnTop && (this.tooltipPosition === 'input' || this.labelHide) && this.renderTooltip()), this.helptextMessageSlotElement && (h("div", { key: '2981238a76e52f4a9c5da6465934bb4edd653e96', class: "mg-c-input__help-text" }, h("slot", { key: 'feee3da8096260e11419b82cb2d281c8d73541d1', name: this.slotHelpText }))), !this.isDisabled && this.errorMessage && (h("div", { key: '1d5a709cfe3c9a1f7da68a260dd480f189ee5301', class: "mg-c-input__error", "aria-live": "assertive" }, h("slot", { key: '4f9f9545ffbdc7c53b77c5153daaf9b15b360fd7', name: this.slotError }))))));
|
|
257
322
|
}
|
|
258
323
|
static get is() { return "mg-input"; }
|
|
259
324
|
static get encapsulation() { return "shadow"; }
|
|
@@ -417,9 +482,15 @@ export class MgInput {
|
|
|
417
482
|
"attribute": "error-message",
|
|
418
483
|
"mutable": false,
|
|
419
484
|
"complexType": {
|
|
420
|
-
"original": "string",
|
|
421
|
-
"resolved": "string",
|
|
422
|
-
"references": {
|
|
485
|
+
"original": "string | ErrorMessageDetailsType",
|
|
486
|
+
"resolved": "string | { summary: string; details: string; }",
|
|
487
|
+
"references": {
|
|
488
|
+
"ErrorMessageDetailsType": {
|
|
489
|
+
"location": "import",
|
|
490
|
+
"path": "./mg-input.conf",
|
|
491
|
+
"id": "src/components/molecules/inputs/mg-input/mg-input.conf.ts::ErrorMessageDetailsType"
|
|
492
|
+
}
|
|
493
|
+
}
|
|
423
494
|
},
|
|
424
495
|
"required": false,
|
|
425
496
|
"optional": true,
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { isValidString } from "@mgdis/core-ui-helpers/dist/utils";
|
|
2
|
+
/**
|
|
3
|
+
* Define error message
|
|
4
|
+
* @param message - message to display
|
|
5
|
+
* @param details - message detail to display
|
|
6
|
+
* @returns formated MgInput["errorMessage"]
|
|
7
|
+
*/
|
|
8
|
+
export const defineErrorMessage = (message, details) => {
|
|
9
|
+
if (isValidString(message) && isValidString(details)) {
|
|
10
|
+
return {
|
|
11
|
+
summary: message,
|
|
12
|
+
details,
|
|
13
|
+
};
|
|
14
|
+
}
|
|
15
|
+
else if (isValidString(message)) {
|
|
16
|
+
return message;
|
|
17
|
+
}
|
|
18
|
+
else {
|
|
19
|
+
return undefined;
|
|
20
|
+
}
|
|
21
|
+
};
|
package/dist/collection/components/molecules/inputs/mg-input-checkbox/MgInputCheckboxList.js
CHANGED
|
@@ -4,7 +4,8 @@ import { h } from "@stencil/core";
|
|
|
4
4
|
* @param props - MgInputCheckboxList Interface Props
|
|
5
5
|
* @returns input template
|
|
6
6
|
*/
|
|
7
|
-
export const MgInputCheckboxList = (props) => (
|
|
7
|
+
export const MgInputCheckboxList = (props) => Array.isArray(props.checkboxes) &&
|
|
8
|
+
props.checkboxes.length > 0 && (h("ul", { class: "mg-c-input__input-group-container", role: "list", "aria-labelledby": props.labelledby, id: props.id }, props.checkboxes.map(input => {
|
|
8
9
|
var _a, _b;
|
|
9
10
|
return (h("li", { key: input._id, class: { 'mg-c-input__input-group': true, 'mg-c-input__input-group--disabled': props.disabled || input.disabled } }, h("input", { type: "checkbox", id: input._id, name: props.name, value: (_a = input.value) === null || _a === void 0 ? void 0 : _a.toString(), checked: Boolean(input.value), required: input.required, "aria-invalid": ((_b = props.invalid) === null || _b === void 0 ? void 0 : _b.toString()) || 'false', disabled: props.disabled || input.disabled, indeterminate: input.value === null, onInput: input._handleInput, onBlur: input._handleBlur, onKeyDown: input._handleKeydown }), h("label", { htmlFor: input._id }, input.title)));
|
|
10
11
|
})));
|
|
@@ -1,16 +1,13 @@
|
|
|
1
1
|
import { h, Host } from "@stencil/core";
|
|
2
|
-
import { SectionKind } from "../mg-input-checkbox.conf";
|
|
3
2
|
import { MgInputCheckboxList } from "../MgInputCheckboxList";
|
|
3
|
+
import { formatID } from "@mgdis/core-ui-helpers/dist/utils";
|
|
4
4
|
/**
|
|
5
5
|
* Internal component use to manage sections instances
|
|
6
6
|
* @internal
|
|
7
7
|
*/
|
|
8
8
|
export class MgInputCheckboxPaginated {
|
|
9
9
|
constructor() {
|
|
10
|
-
|
|
11
|
-
* Constantes *
|
|
12
|
-
*************/
|
|
13
|
-
this.offset = 10;
|
|
10
|
+
this.step = 10;
|
|
14
11
|
/*************
|
|
15
12
|
* Decorators *
|
|
16
13
|
*************/
|
|
@@ -23,76 +20,45 @@ export class MgInputCheckboxPaginated {
|
|
|
23
20
|
*/
|
|
24
21
|
this.disabled = false;
|
|
25
22
|
/**
|
|
26
|
-
*
|
|
27
|
-
*/
|
|
28
|
-
this.currentPage = 1;
|
|
29
|
-
/**
|
|
30
|
-
* Define checkboxes to paginate
|
|
31
|
-
*/
|
|
32
|
-
this.checkboxes = [];
|
|
33
|
-
/**
|
|
34
|
-
* Is checked items values expanded
|
|
23
|
+
* Page items limit to display
|
|
35
24
|
*/
|
|
36
|
-
this.
|
|
25
|
+
this.limit = this.step;
|
|
37
26
|
/***********
|
|
38
27
|
* Methods *
|
|
39
28
|
***********/
|
|
40
29
|
/**
|
|
41
|
-
*
|
|
30
|
+
* Component has next checkboxes to display
|
|
31
|
+
* @returns truthy if have next elements
|
|
42
32
|
*/
|
|
43
|
-
this.
|
|
44
|
-
this.
|
|
33
|
+
this.hasNext = () => {
|
|
34
|
+
return this.checkboxes.length > this.limit;
|
|
45
35
|
};
|
|
46
36
|
/**
|
|
47
|
-
*
|
|
37
|
+
* Set items from checkboxes and limit
|
|
48
38
|
*/
|
|
49
|
-
this.
|
|
50
|
-
this.
|
|
39
|
+
this.setItems = () => {
|
|
40
|
+
this.items = this.checkboxes.slice(0, this.limit);
|
|
51
41
|
};
|
|
52
42
|
/**
|
|
53
|
-
*
|
|
54
|
-
* @param from - array start index
|
|
55
|
-
* @param to - array end index
|
|
56
|
-
* @returns array's range
|
|
57
|
-
*/
|
|
58
|
-
this.getArrayRange = (array, from, to) => array.slice(from, to);
|
|
59
|
-
/**
|
|
60
|
-
* Method to get page count from items
|
|
61
|
-
* @param items - items to count
|
|
62
|
-
* @returns page count from items
|
|
63
|
-
*/
|
|
64
|
-
this.getPageCount = (items) => ((items === null || items === void 0 ? void 0 : items.length) > 0 ? Math.ceil(items.length / this.offset) : 0);
|
|
65
|
-
/**
|
|
66
|
-
* Handle mg-pagination current page change event
|
|
67
|
-
* @param event - pagination current page change event
|
|
43
|
+
* Handle load-more <mg-button> click event
|
|
68
44
|
*/
|
|
69
|
-
this.
|
|
70
|
-
this.
|
|
45
|
+
this.handleLoadMore = () => {
|
|
46
|
+
if (this.hasNext()) {
|
|
47
|
+
this.limit += this.step;
|
|
48
|
+
}
|
|
71
49
|
};
|
|
72
50
|
}
|
|
73
|
-
watchCheckboxes(
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
if (pageCountNewValue === 1 || (pageCountNewValue !== 0 && this.currentPage === 0)) {
|
|
79
|
-
this.currentPage = 1;
|
|
80
|
-
}
|
|
81
|
-
// when old items page numbers match the current page AND new items page number is lower than current page, we set the new last page
|
|
82
|
-
else if (pageCountOldValue === this.currentPage && pageCountNewValue < this.currentPage) {
|
|
83
|
-
this.currentPage--;
|
|
84
|
-
}
|
|
85
|
-
this.sectionKind = newValue[0].value ? SectionKind.SELECTED : SectionKind.NOT_SELECTED;
|
|
51
|
+
watchCheckboxes() {
|
|
52
|
+
this.setItems();
|
|
53
|
+
}
|
|
54
|
+
watchLimit() {
|
|
55
|
+
this.setItems();
|
|
86
56
|
}
|
|
87
57
|
/**
|
|
88
|
-
*
|
|
89
|
-
* @returns [from,to] index
|
|
58
|
+
* Method to reset limit
|
|
90
59
|
*/
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
const from = isFirstPage ? 0 : (this.currentPage - 1) * this.offset;
|
|
94
|
-
const to = isFirstPage ? this.offset : this.currentPage * this.offset;
|
|
95
|
-
return [from, to];
|
|
60
|
+
async resetLimit() {
|
|
61
|
+
this.limit = this.step;
|
|
96
62
|
}
|
|
97
63
|
/*************
|
|
98
64
|
* Lifecycle *
|
|
@@ -101,18 +67,16 @@ export class MgInputCheckboxPaginated {
|
|
|
101
67
|
* Validate props
|
|
102
68
|
*/
|
|
103
69
|
componentWillLoad() {
|
|
104
|
-
this.watchCheckboxes(
|
|
70
|
+
this.watchCheckboxes();
|
|
105
71
|
}
|
|
106
72
|
/**
|
|
107
73
|
* Render
|
|
108
74
|
* @returns HTML Element
|
|
109
75
|
*/
|
|
110
76
|
render() {
|
|
111
|
-
const
|
|
112
|
-
const
|
|
113
|
-
|
|
114
|
-
return (h(Host, { key: 'ee67aa1705efa2b88010748b6978e0c1dec6e4de', hidden: this.checkboxes.length < 1 }, h("div", { key: 'b713e2a0e21f57d3b238b72163f3d7a4781b7026', class: "mg-c-input__section-header" }, this.sectionKind === SectionKind.SELECTED ? (h("mg-button", { variant: "flat", onClick: this.handleToggleClick, "aria-controls": itemsContainerId, "aria-expanded": this.expanded.toString() }, h("mg-icon", { icon: this.expanded ? 'chevron-up' : 'chevron-down' }), h("span", { class: "mg-c-input__section-header-title" }, getText(this.checkboxes)))) : (h("p", { class: "mg-c-input__section-header-title mg-c-input__section-header-title--static" }, getText(this.checkboxes))), ((this.sectionKind === SectionKind.SELECTED && this.expanded && this.checkboxes.some(checkbox => checkbox.value === true && checkbox.disabled !== true)) ||
|
|
115
|
-
(this.sectionKind === SectionKind.NOT_SELECTED && this.checkboxes.some(checkbox => checkbox.value === false && checkbox.disabled !== true))) && (h("mg-tooltip", { key: '7e5cba3b03cdc7bab68650b9aed36c195ca4dfe6', class: "mg-c-input__section-header-tootlip", message: this.messages.tooltip }, h("mg-button", { key: '4980f26ade12cbfaa6ef6041fa84918900cb652a', variant: "link", onClick: this.massActionHandler }, this.messages.action))), this.expanded && this.getPageCount(this.checkboxes) > 1 && (h("mg-pagination", { key: "search-pagination", totalPages: this.getPageCount(this.checkboxes), currentPage: this.currentPage, "onCurrent-page-change": this.handleCurrentPageChange, hideNavigationLabels: true, hidePageCount: true, identifier: `input-checkbox-pagination-${this.sectionKind}` }))), h("div", { key: '950b07ea9c59e8bc21e236bf32e3bf0a9318a008', hidden: !this.expanded, id: itemsContainerId, class: "mg-c-input__section-content" }, h(MgInputCheckboxList, { key: '276f679e01756d6d60f043dc1c04807b5058750a', checkboxes: this.getArrayRange(this.checkboxes, from, to), displaySearchInput: true, messages: this.messages, id: `items-${this.sectionKind}`, disabled: this.disabled, name: this.name, invalid: this.invalid }))));
|
|
77
|
+
const listId = formatID(this.messages.label);
|
|
78
|
+
const tabId = 'tab-info';
|
|
79
|
+
return (h(Host, { key: '8e58037e78fcd7990bbd681053758b0ec4d0c4e0' }, h("slot", { key: 'c64e9c8f65a526b2289d3663fff64df02a282c96', name: "header-action" }), h("div", { key: 'c5953bb7e970384b231865d7fa4708fe2da4b407', class: "mg-c-input__tabs-content" }, h("p", { key: 'c0899cb7e7a6dea282f05aacf0fb05acd60a9d20', id: tabId, class: { 'mg-c-input__popover-info': true, 'mg-u-visually-hidden': this.items.length !== 0 }, "aria-live": this.items.length !== 0 ? 'polite' : undefined }, this.items.length === 0 ? this.messages.noValue : this.messages.values.replace('{count}', this.items.length.toString())), this.items.length > 0 && (h(MgInputCheckboxList, { key: '0bb1b4160d75b00d3fb5d9c08f3a560a16105e57', checkboxes: this.items, labelledby: tabId, id: listId, disabled: this.disabled, name: this.name, invalid: this.invalid })), this.hasNext() && (h("mg-button", { key: "load-more", variant: "flat", class: "mg-c-input__load-more", tabIndex: -1, "full-width": true, onClick: this.handleLoadMore, "aria-controls": listId }, h("mg-icon", { key: 'fd1560d7254f437f284925427130f69539b5fd3b', icon: "chevron-down" }), this.messages.showMore)))));
|
|
116
80
|
}
|
|
117
81
|
static get is() { return "mg-input-checkbox-paginated"; }
|
|
118
82
|
static get encapsulation() { return "scoped"; }
|
|
@@ -196,26 +160,6 @@ export class MgInputCheckboxPaginated {
|
|
|
196
160
|
"setter": false,
|
|
197
161
|
"reflect": false
|
|
198
162
|
},
|
|
199
|
-
"currentPage": {
|
|
200
|
-
"type": "number",
|
|
201
|
-
"attribute": "current-page",
|
|
202
|
-
"mutable": true,
|
|
203
|
-
"complexType": {
|
|
204
|
-
"original": "number",
|
|
205
|
-
"resolved": "number",
|
|
206
|
-
"references": {}
|
|
207
|
-
},
|
|
208
|
-
"required": false,
|
|
209
|
-
"optional": false,
|
|
210
|
-
"docs": {
|
|
211
|
-
"tags": [],
|
|
212
|
-
"text": "Current page"
|
|
213
|
-
},
|
|
214
|
-
"getter": false,
|
|
215
|
-
"setter": false,
|
|
216
|
-
"reflect": false,
|
|
217
|
-
"defaultValue": "1"
|
|
218
|
-
},
|
|
219
163
|
"checkboxes": {
|
|
220
164
|
"type": "unknown",
|
|
221
165
|
"attribute": "checkboxes",
|
|
@@ -238,8 +182,7 @@ export class MgInputCheckboxPaginated {
|
|
|
238
182
|
"text": "Define checkboxes to paginate"
|
|
239
183
|
},
|
|
240
184
|
"getter": false,
|
|
241
|
-
"setter": false
|
|
242
|
-
"defaultValue": "[]"
|
|
185
|
+
"setter": false
|
|
243
186
|
},
|
|
244
187
|
"messages": {
|
|
245
188
|
"type": "unknown",
|
|
@@ -268,37 +211,37 @@ export class MgInputCheckboxPaginated {
|
|
|
268
211
|
}
|
|
269
212
|
static get states() {
|
|
270
213
|
return {
|
|
271
|
-
"
|
|
214
|
+
"limit": {}
|
|
272
215
|
};
|
|
273
216
|
}
|
|
274
|
-
static get
|
|
275
|
-
return
|
|
276
|
-
|
|
277
|
-
"name": "mass-action",
|
|
278
|
-
"bubbles": true,
|
|
279
|
-
"cancelable": true,
|
|
280
|
-
"composed": true,
|
|
281
|
-
"docs": {
|
|
282
|
-
"tags": [],
|
|
283
|
-
"text": "Emit 'mass-action' event\nused to informe that select-all/unselect-all button listner is triggered"
|
|
284
|
-
},
|
|
217
|
+
static get methods() {
|
|
218
|
+
return {
|
|
219
|
+
"resetLimit": {
|
|
285
220
|
"complexType": {
|
|
286
|
-
"
|
|
287
|
-
"
|
|
221
|
+
"signature": "() => Promise<void>",
|
|
222
|
+
"parameters": [],
|
|
288
223
|
"references": {
|
|
289
|
-
"
|
|
290
|
-
"location": "
|
|
291
|
-
"
|
|
292
|
-
"id": "src/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.conf.ts::SectionKindType"
|
|
224
|
+
"Promise": {
|
|
225
|
+
"location": "global",
|
|
226
|
+
"id": "global::Promise"
|
|
293
227
|
}
|
|
294
|
-
}
|
|
228
|
+
},
|
|
229
|
+
"return": "Promise<void>"
|
|
230
|
+
},
|
|
231
|
+
"docs": {
|
|
232
|
+
"text": "Method to reset limit",
|
|
233
|
+
"tags": []
|
|
295
234
|
}
|
|
296
|
-
}
|
|
235
|
+
}
|
|
236
|
+
};
|
|
297
237
|
}
|
|
298
238
|
static get watchers() {
|
|
299
239
|
return [{
|
|
300
240
|
"propName": "checkboxes",
|
|
301
241
|
"methodName": "watchCheckboxes"
|
|
242
|
+
}, {
|
|
243
|
+
"propName": "limit",
|
|
244
|
+
"methodName": "watchLimit"
|
|
302
245
|
}];
|
|
303
246
|
}
|
|
304
247
|
}
|