@mgdis/mg-components 5.19.3 → 5.20.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/{components.utils-69435877.js → components.utils-cd908d4e.js} +102 -99
- package/dist/cjs/components.utils-cd908d4e.js.map +1 -0
- package/dist/cjs/{index-60dd0c56.js → index-8532b5e9.js} +185 -87
- package/dist/cjs/index-8532b5e9.js.map +1 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/mg-action-more_34.cjs.entry.js +5115 -5110
- package/dist/cjs/mg-action-more_34.cjs.entry.js.map +1 -1
- package/dist/cjs/mg-components.cjs.js +3 -3
- package/dist/cjs/mg-components.cjs.js.map +1 -1
- package/dist/cjs/mg-item-more.cjs.entry.js +224 -224
- package/dist/cjs/mg-item-more.cjs.entry.js.map +1 -1
- package/dist/collection/assets/icons/index.js +192 -190
- package/dist/collection/assets/icons/index.js.map +1 -0
- package/dist/collection/collection-manifest.json +6 -6
- package/dist/collection/components/atoms/mg-badge/mg-badge.js +161 -161
- package/dist/collection/components/atoms/mg-badge/mg-badge.js.map +1 -1
- package/dist/collection/components/atoms/mg-button/mg-button.js +362 -362
- package/dist/collection/components/atoms/mg-button/mg-button.js.map +1 -1
- package/dist/collection/components/atoms/mg-card/mg-card.js +126 -126
- package/dist/collection/components/atoms/mg-card/mg-card.js.map +1 -1
- package/dist/collection/components/atoms/mg-character-left/mg-character-left.js +101 -101
- package/dist/collection/components/atoms/mg-character-left/mg-character-left.js.map +1 -1
- package/dist/collection/components/atoms/mg-divider/mg-divider.js +47 -47
- package/dist/collection/components/atoms/mg-divider/mg-divider.js.map +1 -1
- package/dist/collection/components/atoms/mg-icon/mg-icon.js +231 -231
- package/dist/collection/components/atoms/mg-icon/mg-icon.js.map +1 -1
- package/dist/collection/components/atoms/mg-input-title/mg-input-title.js +132 -132
- package/dist/collection/components/atoms/mg-input-title/mg-input-title.js.map +1 -1
- package/dist/collection/components/atoms/mg-tag/mg-tag.js +158 -158
- package/dist/collection/components/atoms/mg-tag/mg-tag.js.map +1 -1
- package/dist/collection/components/atoms/mg-tooltip/mg-tooltip-content/mg-tooltip-content.js +46 -46
- package/dist/collection/components/atoms/mg-tooltip/mg-tooltip-content/mg-tooltip-content.js.map +1 -1
- package/dist/collection/components/atoms/mg-tooltip/mg-tooltip.conf.js +3 -3
- package/dist/collection/components/atoms/mg-tooltip/mg-tooltip.conf.js.map +1 -1
- package/dist/collection/components/atoms/mg-tooltip/mg-tooltip.js +398 -398
- package/dist/collection/components/atoms/mg-tooltip/mg-tooltip.js.map +1 -1
- package/dist/collection/components/molecules/inputs/MgInput.conf.js +2 -2
- package/dist/collection/components/molecules/inputs/MgInput.conf.js.map +1 -1
- package/dist/collection/components/molecules/inputs/MgInput.js +84 -84
- package/dist/collection/components/molecules/inputs/MgInput.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/MgInputCheckboxList.js +8 -8
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/MgInputCheckboxList.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox-paginated/mg-input-checkbox-paginated.js +266 -266
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox-paginated/mg-input-checkbox-paginated.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.conf.js +4 -4
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.conf.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.js +788 -791
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.conf.js +4 -4
- package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.conf.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.js +588 -578
- package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.conf.js +4 -4
- package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.conf.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.js +778 -773
- package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-password/mg-input-password.js +536 -526
- package/dist/collection/components/molecules/inputs/mg-input-password/mg-input-password.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.js +565 -555
- package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.js +700 -695
- package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-text/mg-input-text.js +770 -760
- package/dist/collection/components/molecules/inputs/mg-input-text/mg-input-text.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-textarea/mg-input-textarea.js +705 -695
- package/dist/collection/components/molecules/inputs/mg-input-textarea/mg-input-textarea.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.js +527 -522
- package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.js.map +1 -1
- package/dist/collection/components/molecules/menu/mg-menu/mg-menu.conf.js +2 -2
- package/dist/collection/components/molecules/menu/mg-menu/mg-menu.conf.js.map +1 -1
- package/dist/collection/components/molecules/menu/mg-menu/mg-menu.js +263 -263
- package/dist/collection/components/molecules/menu/mg-menu/mg-menu.js.map +1 -1
- package/dist/collection/components/molecules/menu/mg-menu-item/mg-menu-item.conf.js +6 -6
- package/dist/collection/components/molecules/menu/mg-menu-item/mg-menu-item.conf.js.map +1 -1
- package/dist/collection/components/molecules/menu/mg-menu-item/mg-menu-item.js +423 -423
- package/dist/collection/components/molecules/menu/mg-menu-item/mg-menu-item.js.map +1 -1
- package/dist/collection/components/molecules/mg-action-more/mg-action-more.js +214 -214
- package/dist/collection/components/molecules/mg-action-more/mg-action-more.js.map +1 -1
- package/dist/collection/components/molecules/mg-details/mg-details.js +155 -150
- package/dist/collection/components/molecules/mg-details/mg-details.js.map +1 -1
- package/dist/collection/components/molecules/mg-form/mg-form.js +332 -327
- package/dist/collection/components/molecules/mg-form/mg-form.js.map +1 -1
- package/dist/collection/components/molecules/mg-illustrated-message/mg-illustrated-message.js +85 -85
- package/dist/collection/components/molecules/mg-illustrated-message/mg-illustrated-message.js.map +1 -1
- package/dist/collection/components/molecules/mg-item-more/mg-item-more.js +189 -189
- package/dist/collection/components/molecules/mg-item-more/mg-item-more.js.map +1 -1
- package/dist/collection/components/molecules/mg-message/mg-message.js +325 -304
- package/dist/collection/components/molecules/mg-message/mg-message.js.map +1 -1
- package/dist/collection/components/molecules/mg-modal/mg-modal.js +317 -317
- package/dist/collection/components/molecules/mg-modal/mg-modal.js.map +1 -1
- package/dist/collection/components/molecules/mg-pagination/mg-pagination.conf.js +2 -2
- package/dist/collection/components/molecules/mg-pagination/mg-pagination.conf.js.map +1 -1
- package/dist/collection/components/molecules/mg-pagination/mg-pagination.js +216 -216
- package/dist/collection/components/molecules/mg-pagination/mg-pagination.js.map +1 -1
- package/dist/collection/components/molecules/mg-panel/mg-panel.js +409 -399
- package/dist/collection/components/molecules/mg-panel/mg-panel.js.map +1 -1
- package/dist/collection/components/molecules/mg-popover/mg-popover-content/mg-popover-content.js +91 -91
- package/dist/collection/components/molecules/mg-popover/mg-popover-content/mg-popover-content.js.map +1 -1
- package/dist/collection/components/molecules/mg-popover/mg-popover.js +336 -329
- package/dist/collection/components/molecules/mg-popover/mg-popover.js.map +1 -1
- package/dist/collection/components/molecules/mg-skip-links/mg-skip-links.js +94 -94
- package/dist/collection/components/molecules/mg-skip-links/mg-skip-links.js.map +1 -1
- package/dist/collection/components/molecules/mg-tabs/mg-tabs.conf.js +4 -4
- package/dist/collection/components/molecules/mg-tabs/mg-tabs.conf.js.map +1 -1
- package/dist/collection/components/molecules/mg-tabs/mg-tabs.js +348 -343
- package/dist/collection/components/molecules/mg-tabs/mg-tabs.js.map +1 -1
- package/dist/collection/locales/fr/messages.json +4 -4
- package/dist/collection/locales/index.spec.js +20 -20
- package/dist/collection/locales/index.spec.js.map +1 -1
- package/dist/collection/utils/behaviors.utils.js +127 -127
- package/dist/collection/utils/behaviors.utils.js.map +1 -1
- package/dist/collection/utils/behaviors.utils.spec.js +42 -42
- package/dist/collection/utils/behaviors.utils.spec.js.map +1 -1
- package/dist/collection/utils/components.utils.js +77 -75
- package/dist/collection/utils/components.utils.js.map +1 -1
- package/dist/collection/utils/components.utils.spec.js +150 -140
- package/dist/collection/utils/components.utils.spec.js.map +1 -1
- package/dist/collection/utils/e2e.test.utils.js +21 -21
- package/dist/collection/utils/e2e.test.utils.js.map +1 -1
- package/dist/collection/utils/locale.utils.js +17 -17
- package/dist/collection/utils/locale.utils.js.map +1 -1
- package/dist/collection/utils/locale.utils.spec.js +45 -45
- package/dist/collection/utils/locale.utils.spec.js.map +1 -1
- package/dist/collection/utils/playwright.e2e.test.utils.js +41 -41
- package/dist/collection/utils/playwright.e2e.test.utils.js.map +1 -1
- package/dist/collection/utils/playwright.fixture.js +24 -0
- package/dist/collection/utils/playwright.fixture.js.map +1 -0
- package/dist/collection/utils/unit.test.utils.js +50 -50
- package/dist/collection/utils/unit.test.utils.js.map +1 -1
- package/dist/components/MgInput.js +98 -98
- package/dist/components/MgInput.js.map +1 -1
- package/dist/components/components.utils.js +78 -76
- package/dist/components/components.utils.js.map +1 -1
- package/dist/components/index2.js +21 -21
- package/dist/components/index2.js.map +1 -1
- package/dist/components/mg-action-more.d.ts +2 -2
- package/dist/components/mg-action-more.js +173 -173
- package/dist/components/mg-action-more.js.map +1 -1
- package/dist/components/mg-badge.d.ts +2 -2
- package/dist/components/mg-badge2.js +83 -83
- package/dist/components/mg-badge2.js.map +1 -1
- package/dist/components/mg-button.d.ts +2 -2
- package/dist/components/mg-button2.js +182 -182
- package/dist/components/mg-button2.js.map +1 -1
- package/dist/components/mg-card.d.ts +2 -2
- package/dist/components/mg-card2.js +77 -77
- package/dist/components/mg-card2.js.map +1 -1
- package/dist/components/mg-character-left.d.ts +2 -2
- package/dist/components/mg-character-left2.js +50 -50
- package/dist/components/mg-character-left2.js.map +1 -1
- package/dist/components/mg-details.d.ts +2 -2
- package/dist/components/mg-details.js +69 -69
- package/dist/components/mg-details.js.map +1 -1
- package/dist/components/mg-divider.d.ts +2 -2
- package/dist/components/mg-divider.js +30 -30
- package/dist/components/mg-divider.js.map +1 -1
- package/dist/components/mg-form.d.ts +2 -2
- package/dist/components/mg-form.js +171 -171
- package/dist/components/mg-form.js.map +1 -1
- package/dist/components/mg-icon.d.ts +2 -2
- package/dist/components/mg-icon2.js +318 -316
- package/dist/components/mg-icon2.js.map +1 -1
- package/dist/components/mg-illustrated-message.d.ts +2 -2
- package/dist/components/mg-illustrated-message.js +51 -51
- package/dist/components/mg-illustrated-message.js.map +1 -1
- package/dist/components/mg-input-checkbox-paginated.d.ts +2 -2
- package/dist/components/mg-input-checkbox-paginated2.js +170 -170
- package/dist/components/mg-input-checkbox-paginated2.js.map +1 -1
- package/dist/components/mg-input-checkbox.d.ts +2 -2
- package/dist/components/mg-input-checkbox.js +477 -480
- package/dist/components/mg-input-checkbox.js.map +1 -1
- package/dist/components/mg-input-date.d.ts +2 -2
- package/dist/components/mg-input-date.js +265 -265
- package/dist/components/mg-input-date.js.map +1 -1
- package/dist/components/mg-input-numeric.d.ts +2 -2
- package/dist/components/mg-input-numeric.js +353 -353
- package/dist/components/mg-input-numeric.js.map +1 -1
- package/dist/components/mg-input-password.d.ts +2 -2
- package/dist/components/mg-input-password.js +204 -204
- package/dist/components/mg-input-password.js.map +1 -1
- package/dist/components/mg-input-radio.d.ts +2 -2
- package/dist/components/mg-input-radio.js +234 -234
- package/dist/components/mg-input-radio.js.map +1 -1
- package/dist/components/mg-input-select.d.ts +2 -2
- package/dist/components/mg-input-select2.js +315 -315
- package/dist/components/mg-input-select2.js.map +1 -1
- package/dist/components/mg-input-text.d.ts +2 -2
- package/dist/components/mg-input-text2.js +305 -305
- package/dist/components/mg-input-text2.js.map +1 -1
- package/dist/components/mg-input-textarea.d.ts +2 -2
- package/dist/components/mg-input-textarea.js +276 -276
- package/dist/components/mg-input-textarea.js.map +1 -1
- package/dist/components/mg-input-title.d.ts +2 -2
- package/dist/components/mg-input-title2.js +60 -60
- package/dist/components/mg-input-title2.js.map +1 -1
- package/dist/components/mg-input-toggle.d.ts +2 -2
- package/dist/components/mg-input-toggle.js +251 -251
- package/dist/components/mg-input-toggle.js.map +1 -1
- package/dist/components/mg-item-more.d.ts +2 -2
- package/dist/components/mg-item-more.js +285 -285
- package/dist/components/mg-item-more.js.map +1 -1
- package/dist/components/mg-menu-item.d.ts +2 -2
- package/dist/components/mg-menu-item2.js +344 -344
- package/dist/components/mg-menu-item2.js.map +1 -1
- package/dist/components/mg-menu.conf.js +2 -2
- package/dist/components/mg-menu.conf.js.map +1 -1
- package/dist/components/mg-menu.d.ts +2 -2
- package/dist/components/mg-menu2.js +176 -176
- package/dist/components/mg-menu2.js.map +1 -1
- package/dist/components/mg-message.d.ts +2 -2
- package/dist/components/mg-message.js +197 -192
- package/dist/components/mg-message.js.map +1 -1
- package/dist/components/mg-modal.d.ts +2 -2
- package/dist/components/mg-modal.js +198 -198
- package/dist/components/mg-modal.js.map +1 -1
- package/dist/components/mg-pagination.d.ts +2 -2
- package/dist/components/mg-pagination2.js +133 -133
- package/dist/components/mg-pagination2.js.map +1 -1
- package/dist/components/mg-panel.d.ts +2 -2
- package/dist/components/mg-panel.js +238 -238
- package/dist/components/mg-panel.js.map +1 -1
- package/dist/components/mg-popover-content.d.ts +2 -2
- package/dist/components/mg-popover-content2.js +69 -69
- package/dist/components/mg-popover-content2.js.map +1 -1
- package/dist/components/mg-popover.d.ts +2 -2
- package/dist/components/mg-popover2.js +224 -222
- package/dist/components/mg-popover2.js.map +1 -1
- package/dist/components/mg-skip-links.d.ts +2 -2
- package/dist/components/mg-skip-links.js +57 -57
- package/dist/components/mg-skip-links.js.map +1 -1
- package/dist/components/mg-tabs.d.ts +2 -2
- package/dist/components/mg-tabs.js +243 -243
- package/dist/components/mg-tabs.js.map +1 -1
- package/dist/components/mg-tag.d.ts +2 -2
- package/dist/components/mg-tag.js +97 -97
- package/dist/components/mg-tag.js.map +1 -1
- package/dist/components/mg-tooltip-content.d.ts +2 -2
- package/dist/components/mg-tooltip-content2.js +30 -30
- package/dist/components/mg-tooltip-content2.js.map +1 -1
- package/dist/components/mg-tooltip.d.ts +2 -2
- package/dist/components/mg-tooltip2.js +316 -316
- package/dist/components/mg-tooltip2.js.map +1 -1
- package/dist/esm/{components.utils-6cf27db1.js → components.utils-0d67c31c.js} +102 -100
- package/dist/esm/components.utils-0d67c31c.js.map +1 -0
- package/dist/esm/{index-0f833068.js → index-f34a3a2c.js} +185 -87
- package/dist/esm/index-f34a3a2c.js.map +1 -0
- package/dist/esm/loader.js +3 -3
- package/dist/esm/mg-action-more_34.entry.js +5115 -5110
- package/dist/esm/mg-action-more_34.entry.js.map +1 -1
- package/dist/esm/mg-components.js +4 -4
- package/dist/esm/mg-components.js.map +1 -1
- package/dist/esm/mg-item-more.entry.js +224 -224
- package/dist/esm/mg-item-more.entry.js.map +1 -1
- package/dist/mg-components/locales/fr/messages.json +4 -4
- package/dist/mg-components/mg-components.esm.js +1 -1
- package/dist/mg-components/mg-components.esm.js.map +1 -1
- package/dist/mg-components/p-629454f7.entry.js +2 -0
- package/dist/mg-components/p-629454f7.entry.js.map +1 -0
- package/dist/mg-components/p-7444ff40.js +3 -0
- package/dist/mg-components/p-7444ff40.js.map +1 -0
- package/dist/mg-components/p-af42d17b.js +2 -0
- package/dist/mg-components/p-af42d17b.js.map +1 -0
- package/dist/mg-components/{p-91feda5a.entry.js → p-e0fb0f3c.entry.js} +2 -2
- package/dist/types/assets/icons/index.d.ts +193 -0
- package/dist/types/components/atoms/mg-badge/mg-badge.d.ts +41 -41
- package/dist/types/components/atoms/mg-button/mg-button.d.ts +100 -100
- package/dist/types/components/atoms/mg-card/mg-card.d.ts +39 -39
- package/dist/types/components/atoms/mg-character-left/mg-character-left.d.ts +37 -37
- package/dist/types/components/atoms/mg-divider/mg-divider.d.ts +12 -12
- package/dist/types/components/atoms/mg-icon/mg-icon.d.ts +56 -56
- package/dist/types/components/atoms/mg-input-title/mg-input-title.d.ts +34 -34
- package/dist/types/components/atoms/mg-tag/mg-tag.d.ts +51 -51
- package/dist/types/components/atoms/mg-tooltip/mg-tooltip-content/mg-tooltip-content.d.ts +12 -12
- package/dist/types/components/atoms/mg-tooltip/mg-tooltip.conf.d.ts +3 -3
- package/dist/types/components/atoms/mg-tooltip/mg-tooltip.d.ts +113 -113
- package/dist/types/components/molecules/inputs/MgInput.conf.d.ts +5 -5
- package/dist/types/components/molecules/inputs/MgInput.d.ts +16 -16
- package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox-paginated/mg-input-checkbox-paginated.d.ts +100 -100
- package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.conf.d.ts +26 -26
- package/dist/types/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.d.ts +262 -262
- package/dist/types/components/molecules/inputs/mg-input-date/mg-input-date.conf.d.ts +4 -4
- package/dist/types/components/molecules/inputs/mg-input-date/mg-input-date.d.ts +150 -150
- package/dist/types/components/molecules/inputs/mg-input-numeric/mg-input-numeric.conf.d.ts +4 -4
- package/dist/types/components/molecules/inputs/mg-input-numeric/mg-input-numeric.d.ts +223 -223
- package/dist/types/components/molecules/inputs/mg-input-password/mg-input-password.d.ts +142 -142
- package/dist/types/components/molecules/inputs/mg-input-radio/mg-input-radio.conf.d.ts +3 -3
- package/dist/types/components/molecules/inputs/mg-input-radio/mg-input-radio.d.ts +152 -152
- package/dist/types/components/molecules/inputs/mg-input-select/mg-input-select.conf.d.ts +6 -6
- package/dist/types/components/molecules/inputs/mg-input-select/mg-input-select.d.ts +193 -193
- package/dist/types/components/molecules/inputs/mg-input-text/mg-input-text.d.ts +195 -195
- package/dist/types/components/molecules/inputs/mg-input-textarea/mg-input-textarea.d.ts +181 -181
- package/dist/types/components/molecules/inputs/mg-input-toggle/mg-input-toggle.conf.d.ts +2 -2
- package/dist/types/components/molecules/inputs/mg-input-toggle/mg-input-toggle.d.ts +141 -141
- package/dist/types/components/molecules/menu/mg-menu/mg-menu.conf.d.ts +2 -2
- package/dist/types/components/molecules/menu/mg-menu/mg-menu.d.ts +97 -97
- package/dist/types/components/molecules/menu/mg-menu-item/mg-menu-item.conf.d.ts +6 -6
- package/dist/types/components/molecules/menu/mg-menu-item/mg-menu-item.d.ts +179 -179
- package/dist/types/components/molecules/mg-action-more/mg-action-more.conf.d.ts +12 -12
- package/dist/types/components/molecules/mg-action-more/mg-action-more.d.ts +72 -72
- package/dist/types/components/molecules/mg-details/mg-details.d.ts +45 -45
- package/dist/types/components/molecules/mg-form/mg-form.d.ts +103 -103
- package/dist/types/components/molecules/mg-illustrated-message/mg-illustrated-message.d.ts +27 -27
- package/dist/types/components/molecules/mg-item-more/mg-item-more.conf.d.ts +5 -5
- package/dist/types/components/molecules/mg-item-more/mg-item-more.d.ts +61 -61
- package/dist/types/components/molecules/mg-message/mg-message.d.ts +100 -93
- package/dist/types/components/molecules/mg-modal/mg-modal.d.ts +107 -107
- package/dist/types/components/molecules/mg-pagination/mg-pagination.conf.d.ts +2 -2
- package/dist/types/components/molecules/mg-pagination/mg-pagination.d.ts +74 -74
- package/dist/types/components/molecules/mg-panel/mg-panel.d.ts +149 -149
- package/dist/types/components/molecules/mg-popover/mg-popover-content/mg-popover-content.d.ts +43 -43
- package/dist/types/components/molecules/mg-popover/mg-popover.d.ts +88 -88
- package/dist/types/components/molecules/mg-skip-links/mg-skip-links.conf.d.ts +2 -2
- package/dist/types/components/molecules/mg-skip-links/mg-skip-links.d.ts +40 -40
- package/dist/types/components/molecules/mg-tabs/mg-tabs.conf.d.ts +10 -10
- package/dist/types/components/molecules/mg-tabs/mg-tabs.d.ts +118 -118
- package/dist/types/components.d.ts +294 -30
- package/dist/types/locales/index.d.ts +172 -172
- package/dist/types/stencil-public-runtime.d.ts +29 -0
- package/dist/types/utils/behaviors.utils.d.ts +65 -65
- package/dist/types/utils/components.utils.d.ts +32 -26
- package/dist/types/utils/locale.utils.d.ts +2 -2
- package/dist/types/utils/playwright.fixture.d.ts +3 -0
- package/dist/types/utils/unit.test.utils.d.ts +5 -5
- package/package.json +18 -32
- package/dist/cjs/components.utils-69435877.js.map +0 -1
- package/dist/cjs/index-60dd0c56.js.map +0 -1
- package/dist/collection/components/atoms/mg-badge/test/mg-badge.e2e.playwright.js +0 -33
- package/dist/collection/components/atoms/mg-badge/test/mg-badge.e2e.playwright.js.map +0 -1
- package/dist/collection/components/atoms/mg-badge/test/mg-badge.spec.js +0 -70
- package/dist/collection/components/atoms/mg-badge/test/mg-badge.spec.js.map +0 -1
- package/dist/collection/components/atoms/mg-button/test/mg-button.e2e.js +0 -91
- package/dist/collection/components/atoms/mg-button/test/mg-button.e2e.js.map +0 -1
- package/dist/collection/components/atoms/mg-button/test/mg-button.spec.js +0 -192
- package/dist/collection/components/atoms/mg-button/test/mg-button.spec.js.map +0 -1
- package/dist/collection/components/atoms/mg-card/test/mg-card.e2e.js +0 -36
- package/dist/collection/components/atoms/mg-card/test/mg-card.e2e.js.map +0 -1
- package/dist/collection/components/atoms/mg-card/test/mg-card.spec.js +0 -43
- package/dist/collection/components/atoms/mg-card/test/mg-card.spec.js.map +0 -1
- package/dist/collection/components/atoms/mg-character-left/test/mg-character-left.e2e.js +0 -15
- package/dist/collection/components/atoms/mg-character-left/test/mg-character-left.e2e.js.map +0 -1
- package/dist/collection/components/atoms/mg-character-left/test/mg-character-left.spec.js +0 -42
- package/dist/collection/components/atoms/mg-character-left/test/mg-character-left.spec.js.map +0 -1
- package/dist/collection/components/atoms/mg-divider/test/mg-divider.e2e.js +0 -11
- package/dist/collection/components/atoms/mg-divider/test/mg-divider.e2e.js.map +0 -1
- package/dist/collection/components/atoms/mg-divider/test/mg-divider.spec.js +0 -14
- package/dist/collection/components/atoms/mg-divider/test/mg-divider.spec.js.map +0 -1
- package/dist/collection/components/atoms/mg-icon/test/mg-icon.e2e.js +0 -55
- package/dist/collection/components/atoms/mg-icon/test/mg-icon.e2e.js.map +0 -1
- package/dist/collection/components/atoms/mg-icon/test/mg-icon.spec.js +0 -84
- package/dist/collection/components/atoms/mg-icon/test/mg-icon.spec.js.map +0 -1
- package/dist/collection/components/atoms/mg-input-title/test/mg-input-title.e2e.playwright.js +0 -12
- package/dist/collection/components/atoms/mg-input-title/test/mg-input-title.e2e.playwright.js.map +0 -1
- package/dist/collection/components/atoms/mg-input-title/test/mg-input-title.spec.js +0 -23
- package/dist/collection/components/atoms/mg-input-title/test/mg-input-title.spec.js.map +0 -1
- package/dist/collection/components/atoms/mg-tag/test/mg-tag.e2e.playwright.js +0 -23
- package/dist/collection/components/atoms/mg-tag/test/mg-tag.e2e.playwright.js.map +0 -1
- package/dist/collection/components/atoms/mg-tag/test/mg-tag.spec.js +0 -71
- package/dist/collection/components/atoms/mg-tag/test/mg-tag.spec.js.map +0 -1
- package/dist/collection/components/atoms/mg-tooltip/test/mg-tooltip.e2e.js +0 -138
- package/dist/collection/components/atoms/mg-tooltip/test/mg-tooltip.e2e.js.map +0 -1
- package/dist/collection/components/atoms/mg-tooltip/test/mg-tooltip.spec.js +0 -272
- package/dist/collection/components/atoms/mg-tooltip/test/mg-tooltip.spec.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/test/mg-input-checkbox.e2e.playwright.js +0 -237
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/test/mg-input-checkbox.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/test/mg-input-checkbox.spec.js +0 -634
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/test/mg-input-checkbox.spec.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-date/test/mg-input-date.e2e.js +0 -123
- package/dist/collection/components/molecules/inputs/mg-input-date/test/mg-input-date.e2e.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-date/test/mg-input-date.spec.js +0 -383
- package/dist/collection/components/molecules/inputs/mg-input-date/test/mg-input-date.spec.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-numeric/test/mg-input-numeric.e2e.js +0 -212
- package/dist/collection/components/molecules/inputs/mg-input-numeric/test/mg-input-numeric.e2e.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-numeric/test/mg-input-numeric.spec.js +0 -460
- package/dist/collection/components/molecules/inputs/mg-input-numeric/test/mg-input-numeric.spec.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-password/test/mg-input-password.e2e.js +0 -115
- package/dist/collection/components/molecules/inputs/mg-input-password/test/mg-input-password.e2e.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-password/test/mg-input-password.spec.js +0 -293
- package/dist/collection/components/molecules/inputs/mg-input-password/test/mg-input-password.spec.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-radio/test/mg-input-radio.e2e.js +0 -154
- package/dist/collection/components/molecules/inputs/mg-input-radio/test/mg-input-radio.e2e.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-radio/test/mg-input-radio.spec.js +0 -359
- package/dist/collection/components/molecules/inputs/mg-input-radio/test/mg-input-radio.spec.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-select/test/mg-input-select.e2e.js +0 -194
- package/dist/collection/components/molecules/inputs/mg-input-select/test/mg-input-select.e2e.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-select/test/mg-input-select.spec.js +0 -403
- package/dist/collection/components/molecules/inputs/mg-input-select/test/mg-input-select.spec.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-text/test/mg-input-text.e2e.playwright.js +0 -147
- package/dist/collection/components/molecules/inputs/mg-input-text/test/mg-input-text.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-text/test/mg-input-text.spec.js +0 -355
- package/dist/collection/components/molecules/inputs/mg-input-text/test/mg-input-text.spec.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-textarea/test/mg-input-textarea.e2e.js +0 -129
- package/dist/collection/components/molecules/inputs/mg-input-textarea/test/mg-input-textarea.e2e.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-textarea/test/mg-input-textarea.spec.js +0 -320
- package/dist/collection/components/molecules/inputs/mg-input-textarea/test/mg-input-textarea.spec.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-toggle/test/mg-input-toggle.e2e.playwright.js +0 -108
- package/dist/collection/components/molecules/inputs/mg-input-toggle/test/mg-input-toggle.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/inputs/mg-input-toggle/test/mg-input-toggle.spec.js +0 -247
- package/dist/collection/components/molecules/inputs/mg-input-toggle/test/mg-input-toggle.spec.js.map +0 -1
- package/dist/collection/components/molecules/menu/mg-menu/test/mg-menu.e2e.playwright.js +0 -239
- package/dist/collection/components/molecules/menu/mg-menu/test/mg-menu.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/menu/mg-menu/test/mg-menu.spec.js +0 -175
- package/dist/collection/components/molecules/menu/mg-menu/test/mg-menu.spec.js.map +0 -1
- package/dist/collection/components/molecules/menu/mg-menu-item/test/mg-menu-item.e2e.playwright.js +0 -100
- package/dist/collection/components/molecules/menu/mg-menu-item/test/mg-menu-item.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/menu/mg-menu-item/test/mg-menu-item.spec.js +0 -295
- package/dist/collection/components/molecules/menu/mg-menu-item/test/mg-menu-item.spec.js.map +0 -1
- package/dist/collection/components/molecules/mg-action-more/test/mg-action-more.e2e.playwright.js +0 -136
- package/dist/collection/components/molecules/mg-action-more/test/mg-action-more.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/mg-action-more/test/mg-action-more.spec.js +0 -195
- package/dist/collection/components/molecules/mg-action-more/test/mg-action-more.spec.js.map +0 -1
- package/dist/collection/components/molecules/mg-details/test/mg-details.e2e.playwright.js +0 -30
- package/dist/collection/components/molecules/mg-details/test/mg-details.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/mg-details/test/mg-details.spec.js +0 -42
- package/dist/collection/components/molecules/mg-details/test/mg-details.spec.js.map +0 -1
- package/dist/collection/components/molecules/mg-form/test/mg-form.e2e.js +0 -169
- package/dist/collection/components/molecules/mg-form/test/mg-form.e2e.js.map +0 -1
- package/dist/collection/components/molecules/mg-form/test/mg-form.spec.js +0 -292
- package/dist/collection/components/molecules/mg-form/test/mg-form.spec.js.map +0 -1
- package/dist/collection/components/molecules/mg-illustrated-message/test/mg-illustrated-message.e2e.js +0 -39
- package/dist/collection/components/molecules/mg-illustrated-message/test/mg-illustrated-message.e2e.js.map +0 -1
- package/dist/collection/components/molecules/mg-illustrated-message/test/mg-illustrated-message.spec.js +0 -36
- package/dist/collection/components/molecules/mg-illustrated-message/test/mg-illustrated-message.spec.js.map +0 -1
- package/dist/collection/components/molecules/mg-item-more/test/mg-item-more.e2e.playwright.js +0 -85
- package/dist/collection/components/molecules/mg-item-more/test/mg-item-more.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/mg-item-more/test/mg-item-more.spec.js +0 -106
- package/dist/collection/components/molecules/mg-item-more/test/mg-item-more.spec.js.map +0 -1
- package/dist/collection/components/molecules/mg-message/test/mg-message.e2e.js +0 -64
- package/dist/collection/components/molecules/mg-message/test/mg-message.e2e.js.map +0 -1
- package/dist/collection/components/molecules/mg-message/test/mg-message.spec.js +0 -109
- package/dist/collection/components/molecules/mg-message/test/mg-message.spec.js.map +0 -1
- package/dist/collection/components/molecules/mg-modal/test/mg-modal.e2e.playwright.js +0 -62
- package/dist/collection/components/molecules/mg-modal/test/mg-modal.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/mg-modal/test/mg-modal.e2e.template.js +0 -40
- package/dist/collection/components/molecules/mg-modal/test/mg-modal.e2e.template.js.map +0 -1
- package/dist/collection/components/molecules/mg-modal/test/mg-modal.firefox.e2e.playwright.js +0 -26
- package/dist/collection/components/molecules/mg-modal/test/mg-modal.firefox.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/mg-modal/test/mg-modal.spec.js +0 -122
- package/dist/collection/components/molecules/mg-modal/test/mg-modal.spec.js.map +0 -1
- package/dist/collection/components/molecules/mg-pagination/test/mg-pagination.e2e.playwright.js +0 -57
- package/dist/collection/components/molecules/mg-pagination/test/mg-pagination.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/mg-pagination/test/mg-pagination.spec.js +0 -121
- package/dist/collection/components/molecules/mg-pagination/test/mg-pagination.spec.js.map +0 -1
- package/dist/collection/components/molecules/mg-panel/test/mg-panel.e2e.playwright.js +0 -106
- package/dist/collection/components/molecules/mg-panel/test/mg-panel.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/mg-panel/test/mg-panel.spec.js +0 -213
- package/dist/collection/components/molecules/mg-panel/test/mg-panel.spec.js.map +0 -1
- package/dist/collection/components/molecules/mg-popover/test/mg-popover.e2e.playwright.js +0 -140
- package/dist/collection/components/molecules/mg-popover/test/mg-popover.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/mg-popover/test/mg-popover.spec.js +0 -142
- package/dist/collection/components/molecules/mg-popover/test/mg-popover.spec.js.map +0 -1
- package/dist/collection/components/molecules/mg-skip-links/test/mg-skip-links.e2e.js +0 -55
- package/dist/collection/components/molecules/mg-skip-links/test/mg-skip-links.e2e.js.map +0 -1
- package/dist/collection/components/molecules/mg-skip-links/test/mg-skip-links.spec.js +0 -55
- package/dist/collection/components/molecules/mg-skip-links/test/mg-skip-links.spec.js.map +0 -1
- package/dist/collection/components/molecules/mg-tabs/test/mg-tabs.e2e.playwright.js +0 -76
- package/dist/collection/components/molecules/mg-tabs/test/mg-tabs.e2e.playwright.js.map +0 -1
- package/dist/collection/components/molecules/mg-tabs/test/mg-tabs.spec.js +0 -332
- package/dist/collection/components/molecules/mg-tabs/test/mg-tabs.spec.js.map +0 -1
- package/dist/collection/utils/stencil.e2e.test.utils.js +0 -33
- package/dist/collection/utils/stencil.e2e.test.utils.js.map +0 -1
- package/dist/esm/components.utils-6cf27db1.js.map +0 -1
- package/dist/esm/index-0f833068.js.map +0 -1
- package/dist/mg-components/p-10ed4425.entry.js +0 -2
- package/dist/mg-components/p-10ed4425.entry.js.map +0 -1
- package/dist/mg-components/p-36a51c5e.js +0 -2
- package/dist/mg-components/p-36a51c5e.js.map +0 -1
- package/dist/mg-components/p-9b12021b.js +0 -3
- package/dist/mg-components/p-9b12021b.js.map +0 -1
- package/dist/types/components/atoms/mg-badge/test/mg-badge.e2e.playwright.d.ts +0 -1
- package/dist/types/components/atoms/mg-input-title/test/mg-input-title.e2e.playwright.d.ts +0 -1
- package/dist/types/components/atoms/mg-tag/test/mg-tag.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/inputs/mg-input-checkbox/test/mg-input-checkbox.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/inputs/mg-input-text/test/mg-input-text.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/inputs/mg-input-toggle/test/mg-input-toggle.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/menu/mg-menu/test/mg-menu.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/menu/mg-menu-item/test/mg-menu-item.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/mg-action-more/test/mg-action-more.e2e.playwright.d.ts +0 -2
- package/dist/types/components/molecules/mg-details/test/mg-details.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/mg-item-more/test/mg-item-more.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/mg-modal/test/mg-modal.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/mg-modal/test/mg-modal.e2e.template.d.ts +0 -12
- package/dist/types/components/molecules/mg-modal/test/mg-modal.firefox.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/mg-pagination/test/mg-pagination.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/mg-panel/test/mg-panel.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/mg-popover/test/mg-popover.e2e.playwright.d.ts +0 -1
- package/dist/types/components/molecules/mg-tabs/test/mg-tabs.e2e.playwright.d.ts +0 -1
- package/dist/types/utils/stencil.e2e.test.utils.d.ts +0 -14
- /package/dist/mg-components/{p-91feda5a.entry.js.map → p-e0fb0f3c.entry.js.map} +0 -0
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
const e={required:"This field is required.",date:{badInput:'The date format must be <span aria-hidden="true">mm/dd/yyyy</span><span class="mg-u-visually-hidden">m m / d d / y y y y</span> and the date must be greater than {min}',min:"The date cannot be earlier than {min}",max:"The date cannot be later than {max}",minMax:"The date must be between {min} and {max}"},numeric:{min:"The value cannot be less than {min}",max:"The value cannot be greater than {max}",minMax:"The value must be between {min} et {max}"}};const t="{counter} characters left.";const s={select:{placeholder:"Select a value"},checkbox:{selectedValues:"{nb} selected values",selectedValue:"{nb} selected value",editButton:"Edit",selectButton:"Select values",showButton:"Show",label:"Enter a value",result:"result",results:"results",searchResults:"Search result(s) list.",noResult:"No result.",sections:{selected:{title:"Selected",titlePlurial:"Selected",action:"Unselect all"},notSelected:{title:"Not selected",titlePlurial:"Not selected",action:"Select all"}}}};const n={required:'Fields with a <strong class="mg-u-is-asterisk">*</strong> are required',requiredSingle:'Field with a <strong class="mg-u-is-asterisk">*</strong> is required',allRequired:"All fields are required",allRequiredSingle:"The field is required"};const a={closeButton:"Close message"};const i={closeButton:"Close modal"};const r={label:"Pagination",page:"page",pages:"pages",nextPage:"Next page",previousPage:"Previous page",selectPage:"Select the page to display."};const l={editLabel:"Edit section title."};const o={navLabel:"Quick access"};const c={confirm:"Confirm",cancel:"Cancel",close:"Close",next:"next",previous:"previous"};const u={moreLabel:"Additional menu",badgeLabel:"Include notification(s)"};const d={label:"Actions"};const m={errors:e,nbCharLeft:t,input:s,form:n,message:a,modal:i,pagination:r,panel:l,skipLinks:o,general:c,plusMenu:u,actionMore:d};const p={required:"Ce champ est obligatoire.",date:{badInput:'Le format de la date doit être du type <span aria-hidden="true">jj/mm/aaaa</span><span class="mg-u-visually-hidden">j j / m m / a a a a</span> et la date supérieure au {min}',min:"La date ne peut pas être antérieure au {min}",max:"La date ne peut pas être postérieure au {max}",minMax:"La date doit être comprise entre le {min} et le {max}"},numeric:{min:"La valeur ne peut pas être inférieure à {min}",max:"La valeur ne peut pas être supérieure à {max}",minMax:"La valeur doit être comprise entre {min} et {max}"}};const g="{counter} caractères disponibles.";const h={select:{placeholder:"Sélectionnez une valeur"},checkbox:{selectedValues:"{nb} valeurs selectionnées",selectedValue:"{nb} valeur selectionnée",editButton:"Modifier",selectButton:"Sélectionner des valeurs",showButton:"Voir",label:"Saisissez une valeur",result:"résultat",results:"résultats",searchResults:"List de résultat(s) de la recherche.",noResult:"Aucun résultat.",sections:{selected:{title:"Sélectionné",titlePlurial:"Sélectionnés",action:"Tout désélectionner"},notSelected:{title:"Non sélectionné",titlePlurial:"Non sélectionnés",action:"Tout sélectionner"}}}};const b={required:'Les champs marqués d\'un <strong class="mg-u-is-asterisk">*</strong> sont obligatoires',requiredSingle:'Le champ marqué d\'un <strong class="mg-u-is-asterisk">*</strong> est obligatoire',allRequired:"Tous les champs sont obligatoires",allRequiredSingle:"Le champ est obligatoire"};const f={closeButton:"Fermer le message"};const v={closeButton:"Fermer la modale"};const x={label:"Pagination",page:"page",pages:"pages",nextPage:"Page suivante",previousPage:"Page précédente",selectPage:"Sélectionner la page à afficher."};const y={editLabel:"Modifier le titre de la section."};const L={navLabel:"Accès rapide"};const S={confirm:"Valider",cancel:"Annuler",close:"Fermer",next:"suivant",previous:"précédent"};const q={moreLabel:"Menu complémentaire",badgeLabel:"Notification(s) incluse(s)"};const P={label:"Actions"};const w={errors:p,nbCharLeft:g,input:h,form:b,message:f,modal:v,pagination:x,panel:y,skipLinks:L,general:S,plusMenu:q,actionMore:P};const k=(e,t,s)=>new Intl.NumberFormat(t,{style:"currency",currency:s}).format(e);const T=(e,t)=>new Intl.NumberFormat(t).format(e);const A=/^\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\d|3[01])$/;const M=(e,t)=>{if(typeof e!=="string"||e===""||!A.test(e)){return""}return new Intl.DateTimeFormat(t).format(new Date(e))};const B=(e,t,s)=>{const n=e.closest("[lang]");const a=Intl.NumberFormat.supportedLocalesOf(n===null||n===void 0?void 0:n.lang);const i=a.length>0?a[0]:navigator.language||s;const r=i.split("-").shift();return{locale:i,messages:t[r]||t[s]}};const C="en";const N={en:m,fr:w};const R=e=>B(e,N,C);var I;(function(e){e["VERTICAL"]="vertical";e["HORIZONTAL"]="horizontal"})(I||(I={}));const F=["regular","medium","large"];const V=(e="",t=10)=>{const s=new Uint8Array(t);crypto.getRandomValues(s);const n=Array.from(s).map((e=>e.toString(16).padStart(2,"0"))).join("").slice(0,t);return e!==""?`${e}-${n}`:n};class j{constructor(e=[]){this.add=e=>{if(!this.has(e)){this.classes.push(e)}};this.delete=e=>{const t=this.classes.indexOf(e);if(t>-1){this.classes.splice(t,1)}};this.has=e=>this.classes.includes(e);this.join=()=>this.classes.join(" ");this.classes=e}}const D=e=>Array.isArray(e)&&e.every((e=>typeof e==="string"));const z=(e,t)=>t.includes(e===null||e===void 0?void 0:e.tagName.toLowerCase());const E='a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]), [identifier]';const $=e=>{const t=U(e);const s=Q(e);return[e,...t,...s]};const U=(e,t=[])=>{if(e.self!==e.top){try{const s=e.parent;t.push(s);return U(s,t)}catch(e){console.error("Different hosts between iframes:",e);return t}}return t};const Q=(e,t=[])=>{if(e.frames.length>0){for(const s of Array.from(e.frames)){t.push(s);Q(s,t)}}return t};const G=e=>typeof e==="string"&&e.trim()!=="";const H=e=>typeof e==="string"&&e.toLocaleLowerCase().normalize("NFD").replaceAll(/[\u0300-\u036f]/g,"");const J=async e=>e();export{j as C,I as D,G as a,z as b,V as c,H as d,A as e,k as f,T as g,D as h,R as i,E as j,$ as k,M as l,J as n,F as s};
|
|
2
|
+
//# sourceMappingURL=p-af42d17b.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["localeCurrency","number","locale","currency","Intl","NumberFormat","style","format","localeNumber","dateRegExp","localeDate","date","test","DateTimeFormat","Date","getLocaleMessages","element","messages","defaultLocale","closestLangAttribute","closest","closestLang","supportedLocalesOf","lang","length","navigator","language","localeSubtag","split","shift","en","fr","initLocales","Direction","sizes","createID","prefix","randomBytes","Uint8Array","crypto","getRandomValues","hexString","Array","from","map","byte","toString","padStart","join","slice","ClassList","constructor","classlist","this","add","className","has","classes","push","delete","index","indexOf","splice","includes","allItemsAreString","items","isArray","every","item","isTagName","tagNames","tagName","toLowerCase","focusableElements","getWindows","localWindow","parentWindows","getParentWindows","childWindows","getChildWindows","windows","self","top","parentWindow","parent","err","console","error","frames","childWindow","isValidString","value","trim","cleanString","text","toLocaleLowerCase","normalize","replaceAll","nextTick","async","callback"],"sources":["src/utils/locale.utils.ts","src/locales/index.ts","src/components/molecules/menu/mg-menu/mg-menu.conf.ts","src/utils/components.utils.ts"],"sourcesContent":["/**\n * Format number to the locale currency\n * @param number - number to format\n * @param locale - locale to apply\n * @param currency - currency to apply\n * @returns formatted currency\n */\nexport const localeCurrency = (number: number, locale: string, currency: string): string => {\n return new Intl.NumberFormat(locale, { style: 'currency', currency }).format(number);\n};\n\n/**\n * Format number to locale\n * @param number - number to format\n * @param locale - locale to apply\n * @returns formatted number\n */\nexport const localeNumber = (number: number, locale: string): string => {\n return new Intl.NumberFormat(locale).format(number);\n};\n\n/**\n * Date RegExp\n */\nexport const dateRegExp = /^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\\d|3[01])$/;\n\n/**\n * Locale date format\n * @param date - date to format\n * @param locale - locale to apply\n * @returns formatted date\n */\nexport const localeDate = (date: string, locale: string): string => {\n if (typeof date !== 'string' || date === '' || !dateRegExp.test(date)) {\n return '';\n }\n return new Intl.DateTimeFormat(locale).format(new Date(date));\n};\n\n/**\n * Get locale and messages\n * We load the defined locale but for now we only support the first subtag for messages\n * @param element - element we need to get the language\n * @param messages - messages to use\n * @param defaultLocale - default messages locale\n * @returns messages object\n */\nexport const getLocaleMessages = (element: HTMLElement, messages: unknown, defaultLocale: string): { locale: string; messages: Record<string, unknown> } => {\n // Get local\n const closestLangAttribute: HTMLElement = element.closest('[lang]');\n const closestLang: string[] = Intl.NumberFormat.supportedLocalesOf(closestLangAttribute?.lang);\n const locale = closestLang.length > 0 ? closestLang[0] : navigator.language || defaultLocale;\n // Only keep first subtag\n const localeSubtag = locale.split('-').shift();\n // Return\n return {\n locale,\n messages: messages[localeSubtag] || messages[defaultLocale],\n };\n};\n","import en from './en/messages.json';\nimport fr from './fr/messages.json';\nimport { getLocaleMessages } from '../utils/locale.utils';\n\nconst defaultLocale = 'en';\nconst messages = { en, fr };\n\n/**\n * Get Intl object\n * @param element - element we need to get the language\n * @returns messages object\n */\nexport const initLocales = (element: HTMLElement): { locale: string; messages: Record<string, unknown> } => getLocaleMessages(element, messages, defaultLocale);\n","import { MgItemMore } from '../../mg-item-more/mg-item-more';\n\n/**\n * Menu direction type\n */\nexport enum Direction {\n VERTICAL = 'vertical',\n HORIZONTAL = 'horizontal',\n}\n\n/**\n * ItemMore prop type\n */\nexport type ItemMoreType = Pick<MgItemMore, 'icon' | 'slotlabel' | 'size'>;\n\n/**\n * List of all possibles sizes\n */\nexport const sizes = ['regular', 'medium', 'large'] as const;\n\n/**\n * item Size from sizes\n */\nexport type MenuSizeType = (typeof sizes)[number];\n","/**\n * Create random ID\n * @param prefix - add prefix to created ID\n * @param length - ID length\n * @returns ID\n */\nexport const createID = (prefix = '', length = 10): string => {\n const randomBytes = new Uint8Array(length);\n\n crypto.getRandomValues(randomBytes);\n\n const hexString = Array.from(randomBytes)\n .map(byte => byte.toString(16).padStart(2, '0'))\n .join('')\n .slice(0, length);\n\n return prefix !== '' ? `${prefix}-${hexString}` : hexString;\n};\n\n/**\n * Class to manage component classlist\n * Set() are not working when imported in project\n */\nexport class ClassList {\n /**\n * Available classes\n */\n classes: string[];\n\n constructor(classlist: string[] = []) {\n this.classes = classlist;\n }\n\n /**\n * Add class\n * @param className - class name to add\n */\n add = (className: string): void => {\n if (!this.has(className)) {\n this.classes.push(className);\n }\n };\n\n /**\n * Delete class\n * @param className - class name to delete\n */\n delete = (className: string): void => {\n const index = this.classes.indexOf(className);\n if (index > -1) {\n this.classes.splice(index, 1);\n }\n };\n\n /**\n * Check if class exist in list\n * @param className - class name to check\n * @returns class name is in the list\n */\n has = (className: string): boolean => {\n return this.classes.includes(className);\n };\n\n /**\n * Join classes seperated by spaces\n * @returns joined values\n */\n join = (): string => {\n return this.classes.join(' ');\n };\n}\n\n/**\n * Check if all items are string\n * @param items - items to check\n * @returns all items are string\n */\nexport const allItemsAreString = (items: unknown): items is string[] => Array.isArray(items) && items.every(item => typeof item === 'string');\n\n/**\n * Check if element is a heading\n * @param element - slotted element\n * @param tagNames - allowed tag names list\n * @returns element is a heading\n */\nexport const isTagName = (element: Element, tagNames: string[]): boolean => {\n return tagNames.includes(element?.tagName.toLowerCase());\n};\n\n/**\n * Focusable elements query selector\n */\nexport const focusableElements = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]), [identifier]';\n\n/**\n * Get windows\n * @param localWindow - the window we are lookink for other windows\n * @returns The list of windows found\n */\nexport const getWindows = (localWindow: Window): Window[] => {\n const parentWindows = getParentWindows(localWindow);\n const childWindows = getChildWindows(localWindow);\n return [localWindow, ...parentWindows, ...childWindows];\n};\n\n/**\n * Get parent windows\n * @param localWindow - the window we are lookink for parents\n * @param windows - The list of allready found windows\n * @returns The list of windows found\n */\nexport const getParentWindows = (localWindow: Window, windows: Window[] = []): Window[] => {\n // Check if is in iframe\n if (localWindow.self !== localWindow.top) {\n // Check if we have permission to access parent\n try {\n const parentWindow: Window = localWindow.parent;\n windows.push(parentWindow);\n return getParentWindows(parentWindow, windows);\n } catch (err) {\n console.error('Different hosts between iframes:', err);\n return windows;\n }\n }\n return windows;\n};\n\n/**\n * Get child windows\n * @param localWindow - the window we are lookink for children\n * @param windows - The list of allready found windows\n * @returns The list of windows found\n */\nconst getChildWindows = (localWindow: Window, windows: Window[] = []): Window[] => {\n if (localWindow.frames.length > 0) {\n for (const childWindow of Array.from(localWindow.frames)) {\n windows.push(childWindow);\n getChildWindows(childWindow, windows);\n }\n }\n return windows;\n};\n\n/**\n * Validate string\n * @param value - value to check\n * @returns if string is valid\n */\nexport const isValidString = (value: unknown): boolean => typeof value === 'string' && value.trim() !== '';\n\n/**\n * Clean string caraters\n * @param text - text to cliean\n * @returns cleanded string\n */\nexport const cleanString = (text: string): string =>\n typeof text === 'string' &&\n text\n .toLocaleLowerCase()\n .normalize('NFD')\n .replaceAll(/[\\u0300-\\u036f]/g, '');\n\n/**\n * Use to process code next tick in the event loop\n * @param callback - code to excute on next tick\n * @returns differed code excution\n */\nexport const nextTick = async (callback: () => void): Promise<void> => callback();\n"],"mappings":"g/HAOaA,EAAiB,CAACC,EAAgBC,EAAgBC,IACtD,IAAIC,KAAKC,aAAaH,EAAQ,CAAEI,MAAO,WAAYH,aAAYI,OAAON,G,MASlEO,EAAe,CAACP,EAAgBC,IACpC,IAAIE,KAAKC,aAAaH,GAAQK,OAAON,G,MAMjCQ,EAAa,gD,MAQbC,EAAa,CAACC,EAAcT,KACvC,UAAWS,IAAS,UAAYA,IAAS,KAAOF,EAAWG,KAAKD,GAAO,CACrE,MAAO,E,CAET,OAAO,IAAIP,KAAKS,eAAeX,GAAQK,OAAO,IAAIO,KAAKH,GAAM,EAWxD,MAAMI,EAAoB,CAACC,EAAsBC,EAAmBC,KAEzE,MAAMC,EAAoCH,EAAQI,QAAQ,UAC1D,MAAMC,EAAwBjB,KAAKC,aAAaiB,mBAAmBH,IAAoB,MAApBA,SAAoB,SAApBA,EAAsBI,MACzF,MAAMrB,EAASmB,EAAYG,OAAS,EAAIH,EAAY,GAAKI,UAAUC,UAAYR,EAE/E,MAAMS,EAAezB,EAAO0B,MAAM,KAAKC,QAEvC,MAAO,CACL3B,SACAe,SAAUA,EAASU,IAAiBV,EAASC,GAC9C,ECtDH,MAAMA,EAAgB,KACtB,MAAMD,EAAW,CAAEa,KAAIC,M,MAOVC,EAAehB,GAAgFD,EAAkBC,EAASC,EAAUC,G,ICPrIe,GAAZ,SAAYA,GACVA,EAAA,uBACAA,EAAA,0BACD,EAHD,CAAYA,MAAS,K,MAaRC,EAAQ,CAAC,UAAW,SAAU,S,MCZ9BC,EAAW,CAACC,EAAS,GAAIZ,EAAS,MAC7C,MAAMa,EAAc,IAAIC,WAAWd,GAEnCe,OAAOC,gBAAgBH,GAEvB,MAAMI,EAAYC,MAAMC,KAAKN,GAC1BO,KAAIC,GAAQA,EAAKC,SAAS,IAAIC,SAAS,EAAG,OAC1CC,KAAK,IACLC,MAAM,EAAGzB,GAEZ,OAAOY,IAAW,GAAK,GAAGA,KAAUK,IAAcA,CAAS,E,MAOhDS,EAMX,WAAAC,CAAYC,EAAsB,IAQlCC,KAAAC,IAAOC,IACL,IAAKF,KAAKG,IAAID,GAAY,CACxBF,KAAKI,QAAQC,KAAKH,E,GAQtBF,KAAAM,OAAUJ,IACR,MAAMK,EAAQP,KAAKI,QAAQI,QAAQN,GACnC,GAAIK,GAAS,EAAG,CACdP,KAAKI,QAAQK,OAAOF,EAAO,E,GAS/BP,KAAAG,IAAOD,GACEF,KAAKI,QAAQM,SAASR,GAO/BF,KAAAL,KAAO,IACEK,KAAKI,QAAQT,KAAK,KAtCzBK,KAAKI,QAAUL,C,QA+CNY,EAAqBC,GAAsCvB,MAAMwB,QAAQD,IAAUA,EAAME,OAAMC,UAAeA,IAAS,W,MAQvHC,EAAY,CAACrD,EAAkBsD,IACnCA,EAASP,SAAS/C,IAAO,MAAPA,SAAO,SAAPA,EAASuD,QAAQC,e,MAM/BC,EAAoB,mG,MAOpBC,EAAcC,IACzB,MAAMC,EAAgBC,EAAiBF,GACvC,MAAMG,EAAeC,EAAgBJ,GACrC,MAAO,CAACA,KAAgBC,KAAkBE,EAAa,EASlD,MAAMD,EAAmB,CAACF,EAAqBK,EAAoB,MAExE,GAAIL,EAAYM,OAASN,EAAYO,IAAK,CAExC,IACE,MAAMC,EAAuBR,EAAYS,OACzCJ,EAAQtB,KAAKyB,GACb,OAAON,EAAiBM,EAAcH,E,CACtC,MAAOK,GACPC,QAAQC,MAAM,mCAAoCF,GAClD,OAAOL,C,EAGX,OAAOA,CAAO,EAShB,MAAMD,EAAkB,CAACJ,EAAqBK,EAAoB,MAChE,GAAIL,EAAYa,OAAOhE,OAAS,EAAG,CACjC,IAAK,MAAMiE,KAAe/C,MAAMC,KAAKgC,EAAYa,QAAS,CACxDR,EAAQtB,KAAK+B,GACbV,EAAgBU,EAAaT,E,EAGjC,OAAOA,CAAO,E,MAQHU,EAAiBC,UAAmCA,IAAU,UAAYA,EAAMC,SAAW,G,MAO3FC,EAAeC,UACnBA,IAAS,UAChBA,EACGC,oBACAC,UAAU,OACVC,WAAW,mBAAoB,I,MAOvBC,EAAWC,MAAOC,GAAwCA,W"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{r as t,h as i,H as e,g as s}from"./p-
|
|
2
|
-
//# sourceMappingURL=p-
|
|
1
|
+
import{r as t,h as i,H as e,g as s}from"./p-7444ff40.js";import{a as o,i as n,D as h}from"./p-af42d17b.js";const r=t=>t.nodeName==="MG-ITEM-MORE";var a;(function(t){t["BASE_INDEX"]="data-overflow-base-index";t["PROXY_INDEX"]="data-overflow-proxy-index"})(a||(a={}));class l{constructor(t,i){this.element=t;this.render=i;this.disconnect=()=>{this._resizeObserver.disconnect()};this.run=t=>{if(this._moreElement===undefined){this._moreElement=this.render();this._baseChildren=this.getInteractiveItems(this.element);if(r(this._moreElement)){this._proxyChildren=this.getInteractiveItems(this._moreElement.shadowRoot.querySelector("mg-menu"))}this._baseChildren.forEach(((t,i)=>{t.setAttribute(a.BASE_INDEX,`${i}`);this._proxyChildren[i].setAttribute(a.PROXY_INDEX,`${i}`)}))}if(t!==undefined)this.updateDisplayedItems(t)};this.getInteractiveItems=t=>{var i;return(((i=t.children)===null||i===void 0?void 0:i.length)>0?Array.from(t.children):[]).filter((t=>["MG-MENU-ITEM","MG-BUTTON"].includes(t.nodeName)))};this.updateDisplayedItems=t=>{this.restoreItems();const i={accWidth:0,previousItem:null};[...this._baseChildren,this._moreElement].forEach((e=>{i.accWidth+=e.offsetWidth;const s=i.previousItem!==null;const o=s&&i.previousItem.getAttribute("hidden")!==null;this.toggleItem(e,o&&!this.isMoreElement(e)||this.isOverflowElement(i.accWidth,e,t)||this.isMoreElement(e)&&!o);i.previousItem=e}))};this.isOverflowElement=(t,i,e)=>{if(i.previousElementSibling===null||this.isMoreElement(i))return false;else if(!this.isMoreElement(i.nextElementSibling))return t+this._moreElement.offsetWidth>e;else return t>e};this.isMoreElement=t=>t.nodeName==="MG-ITEM-MORE";this.toggleItem=(t,i)=>{const e=Number(t.getAttribute(a.BASE_INDEX));if(this.isMoreElement(t))this.toggleElement(this._moreElement,i);else if(e>=0){this.toggleElement(t,i);this.toggleElement(this._proxyChildren[e],!i)}};this.toggleElement=(t,i)=>{if(i)t.setAttribute("hidden","");else t.removeAttribute("hidden")};this.restoreItems=()=>{[...this._baseChildren,this._moreElement].forEach((t=>t.removeAttribute("hidden")))};if(this._resizeObserver===undefined){this._resizeObserver=new ResizeObserver((t=>{t.forEach((t=>{this.run(t.contentRect.width)}))}));this._resizeObserver.observe(this.element)}this.run()}}const m=".mg-u-visually-hidden{position:absolute !important;overflow:hidden !important;width:.1rem !important;height:.1rem !important;padding:0 !important;border:0 !important;margin:-0.1rem !important;clip:rect(0.1rem, 0.1rem, 0.1rem, 0.1rem) !important;clip-path:inset(50%) !important;white-space:nowrap !important}*:focus:not(:focus-visible){outline:none}@media (prefers-reduced-motion){*{animation:none !important;transition:none !important}}:host:not([hidden]){display:flex}";const d=class{constructor(i){t(this,i);this.name="mg-item-more";this.renderMgMenuItemOverflowElement=()=>{const t=this.element.shadowRoot.querySelector("mg-menu-item");this.menuItems.forEach((i=>{t.querySelector("mg-menu").appendChild(i.cloneNode(true))}));const i=Array.from(this.parentMenu.querySelectorAll("mg-menu-item:not([data-overflow-more])"));Array.from(t.querySelectorAll("mg-menu-item:not([data-overflow-more])")).forEach(((t,e)=>{t.addEventListener("click",(()=>{const t=i[e].shadowRoot.querySelector("a, button");if(t instanceof HTMLButtonElement||t instanceof HTMLAnchorElement)t.click()}));if(o(t.id))t.id=`${t.id}-proxy`;i[e].addEventListener("status-change",(i=>{t.setAttribute("status",i.detail)}))}));return this.element};this.icon={icon:"ellipsis-vertical"};this.slotlabel={display:false};this.size=undefined;this.parentMenu=undefined}validateIcon(t){if(typeof t!=="object"||typeof t==="object"&&typeof t.icon!=="string")throw new Error(`<${this.name}> prop "icon" must match MgItemMore['icon'] type.`)}validateSlotLabel(t){if(typeof t!=="object"||typeof t==="object"&&typeof t.display!=="boolean")throw new Error(`<${this.name}> prop "slotlabel" must match MgItemMore['slotlabel'] type.`);else if(typeof t.label!=="string")this.slotlabel.label=this.messages.moreLabel}validateSize(t){if(t&&typeof t!=="string")throw new Error(`<${this.name}> prop "size" must match MgItemMore['size'] type.`)}disconnectedCallback(){this.overflowBehavior.disconnect()}componentWillLoad(){this.messages=n(this.element).messages.plusMenu;this.parentMenu=this.element.closest("mg-menu");this.menuItems=Array.from(this.parentMenu.children).filter((t=>t.nodeName==="MG-MENU-ITEM"));this.validateIcon(this.icon);this.validateSlotLabel(this.slotlabel);this.validateSize(this.size)}componentDidLoad(){this.overflowBehavior=new l(this.parentMenu,this.renderMgMenuItemOverflowElement)}render(){return i(e,{role:"listitem"},i("mg-menu-item",{"data-overflow-more":true,"data-size":this.parentMenu.size},i("mg-icon",{icon:this.icon.icon,slot:"image"}),i("span",{class:{"mg-u-visually-hidden":!this.slotlabel.display},slot:"label"},this.slotlabel.label),i("mg-menu",{direction:h.VERTICAL,label:this.messages.moreLabel,size:this.size})))}get element(){return s(this)}static get watchers(){return{icon:["validateIcon"],slotlabel:["validateSlotLabel"],size:["validateSize"]}}};d.style=m;export{d as mg_item_more};
|
|
2
|
+
//# sourceMappingURL=p-e0fb0f3c.entry.js.map
|
|
@@ -0,0 +1,193 @@
|
|
|
1
|
+
export declare const icons: {
|
|
2
|
+
'address-card': string;
|
|
3
|
+
'align-center': string;
|
|
4
|
+
'align-justify': string;
|
|
5
|
+
'align-left': string;
|
|
6
|
+
'align-right': string;
|
|
7
|
+
api: string;
|
|
8
|
+
archive: string;
|
|
9
|
+
'archive-outline': string;
|
|
10
|
+
'arrow-clock': string;
|
|
11
|
+
'arrow-down': string;
|
|
12
|
+
'arrow-down-a-z': string;
|
|
13
|
+
'arrow-down-right': string;
|
|
14
|
+
'arrow-left': string;
|
|
15
|
+
'arrow-right': string;
|
|
16
|
+
'arrow-rotate': string;
|
|
17
|
+
'arrow-rotate-backward': string;
|
|
18
|
+
'arrow-up': string;
|
|
19
|
+
'arrow-up-right': string;
|
|
20
|
+
'arrow-up-right-square': string;
|
|
21
|
+
'arrow-up-z-a': string;
|
|
22
|
+
'arrows-compare': string;
|
|
23
|
+
'arrows-right-down': string;
|
|
24
|
+
'arrows-right-left': string;
|
|
25
|
+
'arrows-rotate': string;
|
|
26
|
+
'arrows-rotate-backward': string;
|
|
27
|
+
ban: string;
|
|
28
|
+
bell: string;
|
|
29
|
+
'bell-outline': string;
|
|
30
|
+
book: string;
|
|
31
|
+
'book-outline': string;
|
|
32
|
+
briefcase: string;
|
|
33
|
+
'briefcase-outline': string;
|
|
34
|
+
'building-outline': string;
|
|
35
|
+
calculator: string;
|
|
36
|
+
calendar: string;
|
|
37
|
+
'calendar-euro': string;
|
|
38
|
+
'calendar-euro-outline': string;
|
|
39
|
+
'calendar-outline': string;
|
|
40
|
+
check: string;
|
|
41
|
+
'check-circle': string;
|
|
42
|
+
'check-circle-outline': string;
|
|
43
|
+
'chevron-down': string;
|
|
44
|
+
'chevron-down-circle': string;
|
|
45
|
+
'chevron-left': string;
|
|
46
|
+
'chevron-left-circle': string;
|
|
47
|
+
'chevron-right': string;
|
|
48
|
+
'chevron-right-circle': string;
|
|
49
|
+
'chevron-up': string;
|
|
50
|
+
'chevron-up-circle': string;
|
|
51
|
+
circle: string;
|
|
52
|
+
clock: string;
|
|
53
|
+
'clock-outline': string;
|
|
54
|
+
'code-square-outline': string;
|
|
55
|
+
cog: string;
|
|
56
|
+
'cog-outline': string;
|
|
57
|
+
comment: string;
|
|
58
|
+
'comment-outline': string;
|
|
59
|
+
'comment-sms': string;
|
|
60
|
+
conversation: string;
|
|
61
|
+
'conversation-outline': string;
|
|
62
|
+
copy: string;
|
|
63
|
+
'credit-card': string;
|
|
64
|
+
cross: string;
|
|
65
|
+
'cross-circle': string;
|
|
66
|
+
'cross-circle-outline': string;
|
|
67
|
+
dashboard: string;
|
|
68
|
+
'dashboard-outline': string;
|
|
69
|
+
download: string;
|
|
70
|
+
earth: string;
|
|
71
|
+
'earth-outline': string;
|
|
72
|
+
ellipsis: string;
|
|
73
|
+
'ellipsis-vertical': string;
|
|
74
|
+
euro: string;
|
|
75
|
+
'euro-circle': string;
|
|
76
|
+
'exclamation-circle': string;
|
|
77
|
+
'exclamation-circle-outline': string;
|
|
78
|
+
'exclamation-stamp': string;
|
|
79
|
+
'exclamation-triangle': string;
|
|
80
|
+
'exclamation-triangle-outline': string;
|
|
81
|
+
eye: string;
|
|
82
|
+
'eye-slash': string;
|
|
83
|
+
fax: string;
|
|
84
|
+
'fax-outline': string;
|
|
85
|
+
file: string;
|
|
86
|
+
'file-cog': string;
|
|
87
|
+
'file-download': string;
|
|
88
|
+
'file-excel': string;
|
|
89
|
+
'file-excel-outline': string;
|
|
90
|
+
'file-outline': string;
|
|
91
|
+
'file-pdf': string;
|
|
92
|
+
'file-pdf-outline': string;
|
|
93
|
+
'file-text': string;
|
|
94
|
+
'file-text-outline': string;
|
|
95
|
+
'file-upload': string;
|
|
96
|
+
'file-word': string;
|
|
97
|
+
'file-word-outline': string;
|
|
98
|
+
filter: string;
|
|
99
|
+
'floppy-disk': string;
|
|
100
|
+
folder: string;
|
|
101
|
+
'folder-check': string;
|
|
102
|
+
'folder-check-outline': string;
|
|
103
|
+
'folder-lines': string;
|
|
104
|
+
'folder-lines-outline': string;
|
|
105
|
+
'folder-link': string;
|
|
106
|
+
'folder-link-outline': string;
|
|
107
|
+
'folder-outline': string;
|
|
108
|
+
'folder-star': string;
|
|
109
|
+
folders: string;
|
|
110
|
+
'folders-outline': string;
|
|
111
|
+
gavel: string;
|
|
112
|
+
'gavel-outline': string;
|
|
113
|
+
'graduation-cap': string;
|
|
114
|
+
'hand-up': string;
|
|
115
|
+
history: string;
|
|
116
|
+
home: string;
|
|
117
|
+
'home-outline': string;
|
|
118
|
+
'info-circle': string;
|
|
119
|
+
'info-circle-outline': string;
|
|
120
|
+
'interrogation-circle': string;
|
|
121
|
+
'interrogation-circle-outline': string;
|
|
122
|
+
key: string;
|
|
123
|
+
laptop: string;
|
|
124
|
+
'life-ring': string;
|
|
125
|
+
'lines-rectangle': string;
|
|
126
|
+
link: string;
|
|
127
|
+
list: string;
|
|
128
|
+
loader: string;
|
|
129
|
+
location: string;
|
|
130
|
+
'location-outline': string;
|
|
131
|
+
lock: string;
|
|
132
|
+
'log-in': string;
|
|
133
|
+
'log-out': string;
|
|
134
|
+
'magnifying-glass': string;
|
|
135
|
+
mail: string;
|
|
136
|
+
'mail-outline': string;
|
|
137
|
+
'messages-square': string;
|
|
138
|
+
'messages-square-outline': string;
|
|
139
|
+
mobile: string;
|
|
140
|
+
'mobile-outline': string;
|
|
141
|
+
notes: string;
|
|
142
|
+
'notes-outline': string;
|
|
143
|
+
'paper-plane': string;
|
|
144
|
+
'paper-plane-slash': string;
|
|
145
|
+
paperclip: string;
|
|
146
|
+
pen: string;
|
|
147
|
+
'pen-circle': string;
|
|
148
|
+
'pen-fancy': string;
|
|
149
|
+
'pen-fancy-files-outline': string;
|
|
150
|
+
'pen-fancy-outline': string;
|
|
151
|
+
'pen-outline': string;
|
|
152
|
+
phone: string;
|
|
153
|
+
'phone-outline': string;
|
|
154
|
+
picture: string;
|
|
155
|
+
'play-circle': string;
|
|
156
|
+
plus: string;
|
|
157
|
+
'plus-circle': string;
|
|
158
|
+
'question-circle': string;
|
|
159
|
+
share: string;
|
|
160
|
+
shuffle: string;
|
|
161
|
+
sitemap: string;
|
|
162
|
+
sliders: string;
|
|
163
|
+
'sliders-outline': string;
|
|
164
|
+
squares: string;
|
|
165
|
+
star: string;
|
|
166
|
+
'star-outline': string;
|
|
167
|
+
table: string;
|
|
168
|
+
tag: string;
|
|
169
|
+
tags: string;
|
|
170
|
+
'thumb-up': string;
|
|
171
|
+
'thumb-up-outline': string;
|
|
172
|
+
thumbtack: string;
|
|
173
|
+
'thumbtack-outline': string;
|
|
174
|
+
trash: string;
|
|
175
|
+
'trash-outline': string;
|
|
176
|
+
'universal-access': string;
|
|
177
|
+
unlink: string;
|
|
178
|
+
unlock: string;
|
|
179
|
+
upload: string;
|
|
180
|
+
user: string;
|
|
181
|
+
'user-circle': string;
|
|
182
|
+
'user-group': string;
|
|
183
|
+
'user-lock': string;
|
|
184
|
+
'user-outline': string;
|
|
185
|
+
'user-pen-fancy-outline': string;
|
|
186
|
+
'user-plus': string;
|
|
187
|
+
'user-question-outline': string;
|
|
188
|
+
'user-shield-outline': string;
|
|
189
|
+
users: string;
|
|
190
|
+
'users-outline': string;
|
|
191
|
+
wallet: string;
|
|
192
|
+
'wallet-outline': string;
|
|
193
|
+
};
|
|
@@ -1,45 +1,45 @@
|
|
|
1
1
|
import { BadgeVariantType } from './mg-badge.conf';
|
|
2
2
|
import { ClassList } from '../../../utils/components.utils';
|
|
3
3
|
export declare class MgBadge {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
4
|
+
/************
|
|
5
|
+
* Internal *
|
|
6
|
+
************/
|
|
7
|
+
private readonly classOutline;
|
|
8
|
+
/**************
|
|
9
|
+
* Decorators *
|
|
10
|
+
**************/
|
|
11
|
+
/**
|
|
12
|
+
* Badge value
|
|
13
|
+
*/
|
|
14
|
+
value: string | number;
|
|
15
|
+
validateValue(newValue: MgBadge['value']): void;
|
|
16
|
+
/**
|
|
17
|
+
* Badge label. Include short description.
|
|
18
|
+
* Required for accessibility
|
|
19
|
+
*/
|
|
20
|
+
label: string;
|
|
21
|
+
validateLabel(newValue: MgBadge['label']): void;
|
|
22
|
+
/**
|
|
23
|
+
* Define button variant
|
|
24
|
+
*/
|
|
25
|
+
variant?: BadgeVariantType;
|
|
26
|
+
validateVariant(newValue: MgBadge['variant'], oldValue?: MgBadge['variant']): void;
|
|
27
|
+
/**
|
|
28
|
+
* Define if button is using outline style
|
|
29
|
+
*/
|
|
30
|
+
outline: boolean;
|
|
31
|
+
validateOutline(newValue: MgBadge['outline']): void;
|
|
32
|
+
/**
|
|
33
|
+
* Component classes
|
|
34
|
+
*/
|
|
35
|
+
classCollection: ClassList;
|
|
36
|
+
/**
|
|
37
|
+
* Check if props are well configured on init
|
|
38
|
+
*/
|
|
39
|
+
componentWillLoad(): void;
|
|
40
|
+
/**
|
|
41
|
+
* Render
|
|
42
|
+
* @returns HTML Element
|
|
43
|
+
*/
|
|
44
|
+
render(): HTMLElement;
|
|
45
45
|
}
|
|
@@ -2,104 +2,104 @@ import { EventEmitter } from '../../../stencil-public-runtime';
|
|
|
2
2
|
import { VariantType, ButtonType } from './mg-button.conf';
|
|
3
3
|
import { ClassList } from '../../../utils/components.utils';
|
|
4
4
|
export declare class MgButton {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
5
|
+
/************
|
|
6
|
+
* Internal *
|
|
7
|
+
************/
|
|
8
|
+
private onClickElementFn;
|
|
9
|
+
private readonly classDisabled;
|
|
10
|
+
private readonly classLoading;
|
|
11
|
+
private readonly classFullWidth;
|
|
12
|
+
/**************
|
|
13
|
+
* Decorators *
|
|
14
|
+
**************/
|
|
15
|
+
/**
|
|
16
|
+
* Get component DOM element
|
|
17
|
+
*/
|
|
18
|
+
element: HTMLMgButtonElement;
|
|
19
|
+
/**
|
|
20
|
+
* Define button variant
|
|
21
|
+
*/
|
|
22
|
+
variant: VariantType;
|
|
23
|
+
validateVariant(newValue: VariantType, oldValue?: VariantType): void;
|
|
24
|
+
/**
|
|
25
|
+
* Identifier is used for the element ID (id is a reserved prop in Stencil.js)
|
|
26
|
+
*/
|
|
27
|
+
identifier: string;
|
|
28
|
+
/**
|
|
29
|
+
* aria-label
|
|
30
|
+
* In case button text is not explicit enough
|
|
31
|
+
*/
|
|
32
|
+
label: string;
|
|
33
|
+
/**
|
|
34
|
+
* Define button type
|
|
35
|
+
*/
|
|
36
|
+
type: ButtonType;
|
|
37
|
+
/**
|
|
38
|
+
* Set button to full-width
|
|
39
|
+
*/
|
|
40
|
+
fullWidth: boolean;
|
|
41
|
+
validateFullWidth(newValue: MgButton['fullWidth']): void;
|
|
42
|
+
/**
|
|
43
|
+
* Define form id to attach button with.
|
|
44
|
+
* If this attribute is not set, the <button> is associated with its ancestor <form> element.
|
|
45
|
+
*/
|
|
46
|
+
form: string;
|
|
47
|
+
/**
|
|
48
|
+
* Disable button
|
|
49
|
+
*/
|
|
50
|
+
disabled: boolean;
|
|
51
|
+
disabledHandler(isDisabled: MgButton['disabled']): void;
|
|
52
|
+
/**
|
|
53
|
+
* Define if button is round.
|
|
54
|
+
* Used for icon button.
|
|
55
|
+
*/
|
|
56
|
+
isIcon: boolean;
|
|
57
|
+
/**
|
|
58
|
+
* Option to set input disable on click, in order to prevent multi-click.
|
|
59
|
+
* Parent component have to remove the attribute 'disabled' when the process ends.
|
|
60
|
+
*/
|
|
61
|
+
disableOnClick: boolean;
|
|
62
|
+
/**
|
|
63
|
+
* Define if button is loading, default to false.
|
|
64
|
+
* Trigger when button is clicked or key-up ['enter', 'space], then value change to true.
|
|
65
|
+
* It's required to reset to false when action/promise in parent is done to stop the loading state
|
|
66
|
+
*/
|
|
67
|
+
loading: boolean;
|
|
68
|
+
loadingHandler(newValue: MgButton['loading']): void;
|
|
69
|
+
/**
|
|
70
|
+
* Component classes
|
|
71
|
+
*/
|
|
72
|
+
classCollection: ClassList;
|
|
73
|
+
/**
|
|
74
|
+
* Emmited event when disabled change
|
|
75
|
+
*/
|
|
76
|
+
disabledChange: EventEmitter<HTMLMgButtonElement['disabled']>;
|
|
77
|
+
/**
|
|
78
|
+
* Trigger actions onClick event
|
|
79
|
+
* @param event - click event
|
|
80
|
+
*/
|
|
81
|
+
private handleClick;
|
|
82
|
+
/**
|
|
83
|
+
* Handle onKeydown event
|
|
84
|
+
* @param event - keyboard event
|
|
85
|
+
*/
|
|
86
|
+
private handleKeydown;
|
|
87
|
+
/**
|
|
88
|
+
* Handle onKeyup event
|
|
89
|
+
* @param event - keyboard event
|
|
90
|
+
*/
|
|
91
|
+
private handleKeyup;
|
|
92
|
+
/**
|
|
93
|
+
* Check if props are well configured on init
|
|
94
|
+
*/
|
|
95
|
+
componentWillLoad(): void;
|
|
96
|
+
/**
|
|
97
|
+
* Add listners
|
|
98
|
+
*/
|
|
99
|
+
componentDidLoad(): void;
|
|
100
|
+
/**
|
|
101
|
+
* Render component
|
|
102
|
+
* @returns html element
|
|
103
|
+
*/
|
|
104
|
+
render(): HTMLElement;
|
|
105
105
|
}
|
|
@@ -1,43 +1,43 @@
|
|
|
1
1
|
import { ClassList } from '../../../utils/components.utils';
|
|
2
2
|
import { type VariantStyleType, type VariantType } from './mg-card.conf';
|
|
3
3
|
export declare class MgCard {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
4
|
+
/*************
|
|
5
|
+
* Private *
|
|
6
|
+
*************/
|
|
7
|
+
private readonly name;
|
|
8
|
+
private readonly classBase;
|
|
9
|
+
/*************
|
|
10
|
+
* Decorators *
|
|
11
|
+
*************/
|
|
12
|
+
/**
|
|
13
|
+
* Define variant prop
|
|
14
|
+
*/
|
|
15
|
+
variant: undefined | VariantType;
|
|
16
|
+
validateVariant(newValue: MgCard['variant'], oldValue?: MgCard['variant']): void;
|
|
17
|
+
/**
|
|
18
|
+
* Define variantStyle prop
|
|
19
|
+
*/
|
|
20
|
+
variantStyle: undefined | VariantStyleType;
|
|
21
|
+
validateVariantStyle(newValue: MgCard['variantStyle'], oldValue?: MgCard['variantStyle']): void;
|
|
22
|
+
/**
|
|
23
|
+
* Component classes
|
|
24
|
+
*/
|
|
25
|
+
classCollection: ClassList;
|
|
26
|
+
/**
|
|
27
|
+
* Methode to set default varianStyle props
|
|
28
|
+
* needeed has stencil doesn't know that props is mutated when updated in prop watcher
|
|
29
|
+
*/
|
|
30
|
+
private setDefaultVariantStyle;
|
|
31
|
+
/*************
|
|
32
|
+
* Lifecycle *
|
|
33
|
+
*************/
|
|
34
|
+
/**
|
|
35
|
+
* Check if props are well configured on init
|
|
36
|
+
*/
|
|
37
|
+
componentWillLoad(): void;
|
|
38
|
+
/**
|
|
39
|
+
* Render
|
|
40
|
+
* @returns HTML Element
|
|
41
|
+
*/
|
|
42
|
+
render(): HTMLElement;
|
|
43
43
|
}
|