@cnamts/synapse 1.0.15 → 1.0.17
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/{DateFilter-isr8mXVb.js → DateFilter-RHtdShO1.js} +12 -12
- package/dist/{NumberFilter-BOe7DqWX.js → NumberFilter-DXYz_b_w.js} +1 -1
- package/dist/{PeriodFilter-WTprpO40.js → PeriodFilter-CzphmrNu.js} +1 -1
- package/dist/{SelectFilter-CqlG5dmI.js → SelectFilter-a4fUV5Jp.js} +1 -1
- package/dist/{TextFilter-fVW5bsRw.js → TextFilter-CZ4LTKoq.js} +1 -1
- package/dist/components/Accordion/Accordion.d.ts +22 -7
- package/dist/components/Amelipro/AmeliproAutoCompleteField/AmeliproAutoCompleteField.d.ts +2836 -2845
- package/dist/components/Amelipro/AmeliproCallback/AmeliproCallback.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproCarousel/AmeliproCarousel.d.ts +7 -7
- package/dist/components/Amelipro/AmeliproCarousel/AmeliproCarouselItem/AmeliproCarouselItem.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproCheckbox/AmeliproCheckbox.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproCheckboxGroup/AmeliproCheckboxGroup.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproClickableTile/AmeliproClickableTile.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproCustomSelector/AmeliproCustomSelector.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproErrorTemplate/AmeliproErrorTemplate.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproFirstLogin/AmeliproFirstLogin.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproFooter/AmeliproFooter.d.ts +18 -18
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeader.d.ts +9 -9
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBar.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBrandSection/AmeliproHeaderBrandSection.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproIcon/AmeliproIcon.d.ts +3 -1
- package/dist/components/Amelipro/AmeliproIconBtn/AmeliproIconBtn.d.ts +5 -3
- package/dist/components/Amelipro/AmeliproIllustratedRadioGroup/AmeliproIllustratedRadioGroup.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproMenu/AmeliproMenu.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproMultipleFoldingCard/AmeliproMultipleFoldingCard.d.ts +1 -1
- package/dist/components/Amelipro/AmeliproPagination/AmeliproPaginationBtn/AmeliproPaginationBtn.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproPatientBanner/AmeliproPatientBanner.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproPatientLogged/AmeliproPatientLogged.d.ts +40 -8
- package/dist/components/Amelipro/AmeliproPatientLogged/types.d.ts +2 -1
- package/dist/components/Amelipro/AmeliproPostalAddressField/AmeliproPostalAddressCityRow/AmeliproPostalAddressCityRow.d.ts +1288 -1284
- package/dist/components/Amelipro/AmeliproPostalAddressField/AmeliproPostalAddressField.d.ts +1936 -1930
- package/dist/components/Amelipro/AmeliproRadioGroup/AmeliproRadioGroup.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproSelect/AmeliproSelect.d.ts +2838 -2865
- package/dist/components/Amelipro/AmeliproStateTile/AmeliproStateTile.d.ts +3 -3
- package/dist/components/Amelipro/AmeliproTabs/AmeliproTabBtn/AmeliproTabBtn.d.ts +1 -1
- package/dist/components/Amelipro/AmeliproTabs/AmeliproTabs.d.ts +2849 -2867
- package/dist/components/Amelipro/AmeliproTextArea/AmeliproTextArea.d.ts +397 -397
- package/dist/components/Amelipro/AmeliproTextField/AmeliproTextField.d.ts +653 -642
- package/dist/components/Amelipro/AmeliproTileBtn/AmeliproTileBtn.d.ts +233 -5
- package/dist/components/Amelipro/AmeliproTooltips/AmeliproTooltips.d.ts +6 -2
- package/dist/components/Amelipro/AmeliproTransmission/AmeliproTransmission.d.ts +9 -9
- package/dist/components/Amelipro/StructureMenu/StructureBtn/StructureBtn.d.ts +9 -0
- package/dist/components/Amelipro/StructureMenu/StructureItem/types.d.ts +1 -0
- package/dist/components/Amelipro/StructureMenu/StructureMenu.d.ts +9 -0
- package/dist/components/Amelipro/StructureMenu/StructureTabs/StructureTabs.d.ts +23 -2
- package/dist/components/Captcha/CaptchaHelpdesk.d.ts +6 -0
- package/dist/components/ChipList/locales.d.ts +1 -0
- package/dist/components/CookieBanner/CookieBanner.d.ts +117 -119
- package/dist/components/CookiesSelection/CookiesInformation/CookiesInformation.d.ts +484 -484
- package/dist/components/CookiesSelection/CookiesSelection.d.ts +104 -106
- package/dist/components/Customs/Selects/SelectBtnField/SelectBtnField.d.ts +14 -10
- package/dist/components/Customs/Selects/SySelect/SySelect.d.ts +118 -129
- package/dist/components/Customs/Selects/SySelect/composables/useSySelectKeyboard.d.ts +1 -3
- package/dist/components/Customs/SyCheckbox/SyCheckbox.d.ts +1 -1
- package/dist/components/Customs/SyForm/SyForm.d.ts +60 -53
- package/dist/components/Customs/SyRadioGroup/SyRadioGroup.d.ts +88 -0
- package/dist/components/Customs/SyRadioGroup/locales.d.ts +3 -0
- package/dist/components/Customs/SyTextField/SyTextField.d.ts +644 -642
- package/dist/components/DataList/DataList.d.ts +6 -1
- package/dist/components/DataListGroup/DataListGroup.d.ts +14 -2
- package/dist/components/DataListItem/DataListItem.d.ts +3 -0
- package/dist/components/DatePicker/CalendarMode/DatePicker.d.ts +2986 -3098
- package/dist/components/DatePicker/ComplexDatePicker/ComplexDatePicker.d.ts +1456 -1558
- package/dist/components/DatePicker/DateTextInput/DateTextInput.d.ts +653 -652
- package/dist/components/DatePicker/composables/index.d.ts +4 -1
- package/dist/components/DatePicker/composables/useAsteriskDisplay.d.ts +1 -1
- package/dist/components/DatePicker/composables/useCalendarKeyboardNavigation.d.ts +11 -0
- package/dist/components/DatePicker/composables/useDatePickerState.d.ts +25 -0
- package/dist/components/DatePicker/composables/useDateTextField.d.ts +61 -0
- package/dist/components/DatePicker/composables/useHolidayHighlighting.d.ts +15 -0
- package/dist/components/DatePicker/constants/messages.d.ts +0 -1
- package/dist/components/DialogBox/DialogBox.d.ts +177 -179
- package/dist/components/DialogBox/config.d.ts +4 -0
- package/dist/components/FilterSideBar/FilterSideBar.d.ts +170 -173
- package/dist/components/FilterSideBar/locales.d.ts +5 -0
- package/dist/components/FooterBar/FooterBar.d.ts +5 -5
- package/dist/components/HeaderBar/HeaderBar.d.ts +4 -2
- package/dist/components/HeaderBar/HeaderLogo/HeaderLogo.d.ts +1 -1
- package/dist/components/HeaderNavigationBar/HeaderNavigationBar.d.ts +15 -5
- package/dist/components/HeaderNavigationBar/HorizontalNavbar/HorizontalNavbar.d.ts +5 -1
- package/dist/components/HeaderToolbar/HeaderToolbar.d.ts +234 -258
- package/dist/components/LangBtn/LangBtn.d.ts +173 -179
- package/dist/components/LogoBrandSection/LogoBrandSection.d.ts +1 -1
- package/dist/components/LunarCalendar/LunarCalendar.d.ts +29 -0
- package/dist/components/LunarCalendar/useLunarCalendarRules.d.ts +5 -0
- package/dist/components/LunarCalendar/useLunarCalendarValidation.d.ts +13 -0
- package/dist/components/MaintenancePage/MaintenancePage.d.ts +8 -1
- package/dist/components/NirField/NirField.d.ts +1296 -1292
- package/dist/components/NotFoundPage/NotFoundPage.d.ts +9 -2
- package/dist/components/NotificationBar/Notification/Notification.d.ts +30 -0
- package/dist/components/NotificationBar/NotificationBar.d.ts +32 -20
- package/dist/components/PaginatedTable/PaginatedTable.d.ts +1 -1
- package/dist/components/PeriodField/PeriodField.d.ts +5855 -6079
- package/dist/components/PhoneField/PhoneField.d.ts +645 -643
- package/dist/components/SubHeader/SubHeader.d.ts +11 -8
- package/dist/components/SyAlert/SyAlert.d.ts +31 -31
- package/dist/components/SyTextArea/SyTextArea.d.ts +397 -395
- package/dist/components/SyTextArea/locales.d.ts +1 -0
- package/dist/components/Tables/SyServerTable/SyServerTable.d.ts +193 -227
- package/dist/components/Tables/SyTable/SyTable.d.ts +192 -226
- package/dist/components/Tables/common/SyTableFilter.d.ts +1 -1
- package/dist/components/Tables/common/SyTablePagination.d.ts +118 -129
- package/dist/components/Tables/common/TableHeader.d.ts +52 -2
- package/dist/components/Tables/common/filters/DateFilter.d.ts +1 -1
- package/dist/components/Tables/common/filters/NumberFilter.d.ts +1 -1
- package/dist/components/Tables/common/filters/PeriodFilter.d.ts +1 -1
- package/dist/components/Tables/common/filters/SelectFilter.d.ts +1 -1
- package/dist/components/Tables/common/filters/TextFilter.d.ts +1 -1
- package/dist/components/Tables/common/locales.d.ts +1 -0
- package/dist/components/Tables/common/organizeColumns/OrganizeColumns.d.ts +86 -90
- package/dist/components/Tables/common/tableFilterUtils.d.ts +2 -2
- package/dist/components/Tables/common/types.d.ts +3 -2
- package/dist/components/Tables/common/useTableCheckbox.d.ts +3 -2
- package/dist/components/Tables/common/useTableFilter.d.ts +1 -1
- package/dist/components/Tables/common/useTableItems.d.ts +6 -8
- package/dist/components/UploadWorkflow/UploadWorkflow.d.ts +18 -18
- package/dist/components/UserMenuBtn/UserMenuBtn.d.ts +2 -0
- package/dist/components/index.d.ts +2 -0
- package/dist/design-system-v3.js +101 -98
- package/dist/design-system-v3.umd.cjs +25 -33
- package/dist/directives/lockFocus.d.ts +1 -1
- package/dist/main-BXIMMzFS.js +35408 -0
- package/dist/style.css +1 -1
- package/dist/utils/formatNir/formatNir.d.ts +2 -0
- package/dist/utils/index.d.ts +1 -0
- package/dist/utils/insertAt.d.ts +1 -0
- package/dist/utils/rules/validateDateValue.d.ts +14 -0
- package/dist/vuetifyConfig.d.ts +6 -6
- package/package.json +14 -7
- package/src/assets/tokens.scss +2 -0
- package/src/components/Accordion/Accessibilite/AccessibilityGuide.mdx +70 -241
- package/src/components/Accordion/Accordion.mdx +6 -1
- package/src/components/Accordion/Accordion.stories.ts +88 -9
- package/src/components/Accordion/Accordion.vue +56 -24
- package/src/components/Accordion/tests/Accordion.a11y.spec.ts +46 -0
- package/src/components/Accordion/tests/__snapshots__/accordion.spec.ts.snap +26 -30
- package/src/components/Accordion/tests/accordion.spec.ts +27 -26
- package/src/components/Amelipro/AmeliproAccordion/AmeliproAccordionTemplate/__tests__/__snapshots__/AmeliproAccordionTemplate.spec.ts.snap +1 -18
- package/src/components/Amelipro/AmeliproAccordion/__tests__/AmeliproAccordion.spec.ts +178 -9
- package/src/components/Amelipro/AmeliproAccordion/__tests__/__snapshots__/AmeliproAccordion.spec.ts.snap +28 -121
- package/src/components/Amelipro/AmeliproAccordionFrieze/__tests__/__snapshots__/AmeliproAccordionFrieze.spec.ts.snap +15 -270
- package/src/components/Amelipro/AmeliproAccordionList/__tests__/__snapshots__/AmeliproAccordionList.spec.ts.snap +12 -194
- package/src/components/Amelipro/AmeliproAccordionResult/AmeliproAccordionResultTemplate/__tests__/__snapshots__/AmeliproAccordionResultTemplate.spec.ts.snap +1 -18
- package/src/components/Amelipro/AmeliproAccordionResult/__tests__/__snapshots__/AmeliproAccordionResult.spec.ts.snap +1 -18
- package/src/components/Amelipro/AmeliproAccordionResultList/__tests__/__snapshots__/AmeliproAccordionResultList.spec.ts.snap +12 -194
- package/src/components/Amelipro/AmeliproAutoCompleteField/AmeliproAutoCompleteField.stories.ts +9 -9
- package/src/components/Amelipro/AmeliproAutoCompleteField/AmeliproAutoCompleteField.vue +5 -4
- package/src/components/Amelipro/AmeliproAutoCompleteField/__tests__/AmeliproAutoCompleteField.spec.ts +6 -6
- package/src/components/Amelipro/AmeliproAutoCompleteField/__tests__/__snapshots__/AmeliproAutoCompleteField.spec.ts.snap +2 -0
- package/src/components/Amelipro/AmeliproBadge/__tests__/AmeliproBadge.spec.ts +135 -9
- package/src/components/Amelipro/AmeliproBadge/__tests__/__snapshots__/AmeliproBadge.spec.ts.snap +20 -5
- package/src/components/Amelipro/AmeliproBreadcrumb/__tests__/AmeliproBreadcrumb.spec.ts +195 -28
- package/src/components/Amelipro/AmeliproBreadcrumb/__tests__/__snapshots__/AmeliproBreadcrumb.spec.ts.snap +193 -124
- package/src/components/Amelipro/AmeliproCaptcha/AmeliproCaptcha.vue +1 -1
- package/src/components/Amelipro/AmeliproCaptcha/__tests__/AmeliproCaptcha.spec.ts +364 -12
- package/src/components/Amelipro/AmeliproCaptcha/__tests__/__snapshots__/AmeliproCaptcha.spec.ts.snap +30 -390
- package/src/components/Amelipro/AmeliproCarousel/__tests__/__snapshots__/AmeliproCarousel.spec.ts.snap +4 -36
- package/src/components/Amelipro/AmeliproCheckbox/AmeliproCheckbox.stories.ts +10 -10
- package/src/components/Amelipro/AmeliproCheckbox/AmeliproCheckbox.vue +7 -7
- package/src/components/Amelipro/AmeliproCheckbox/__tests__/AmeliproCheckbox.spec.ts +5 -5
- package/src/components/Amelipro/AmeliproCheckbox/__tests__/__snapshots__/AmeliproCheckbox.spec.ts.snap +1 -1
- package/src/components/Amelipro/AmeliproCheckboxGroup/AmeliproCheckboxGroup.stories.ts +7 -6
- package/src/components/Amelipro/AmeliproCheckboxGroup/AmeliproCheckboxGroup.vue +6 -6
- package/src/components/Amelipro/AmeliproCheckboxGroup/__tests__/AmeliproCheckboxGroup.spec.ts +6 -6
- package/src/components/Amelipro/AmeliproCheckboxGroup/__tests__/__snapshots__/AmeliproCheckboxGroup.spec.ts.snap +2 -2
- package/src/components/Amelipro/AmeliproClickableTile/tests/__snapshots__/AmeliproClickableTile.spec.ts.snap +2 -43
- package/src/components/Amelipro/AmeliproContentLayout/__tests__/AmeliproContentLayout.spec.ts +80 -9
- package/src/components/Amelipro/AmeliproContentLayout/__tests__/__snapshots__/AmeliproContentLayout.spec.ts.snap +25 -4
- package/src/components/Amelipro/AmeliproCopyBtn/__tests__/__snapshots__/AmeliproCopyBtn.spec.ts.snap +1 -13
- package/src/components/Amelipro/AmeliproCustomSelector/AmeliproCustomSelector.stories.ts +7 -6
- package/src/components/Amelipro/AmeliproCustomSelector/AmeliproCustomSelector.vue +5 -5
- package/src/components/Amelipro/AmeliproCustomSelector/__tests__/AmeliproCustomSelector.spec.ts +187 -39
- package/src/components/Amelipro/AmeliproCustomSelector/__tests__/__snapshots__/AmeliproCustomSelector.spec.ts.snap +147 -147
- package/src/components/Amelipro/AmeliproDentalChart/tests/__snapshots__/AmeliproDentalChart.spec.ts.snap +1 -1
- package/src/components/Amelipro/AmeliproDialog/__tests__/__snapshots__/AmeliproDialog.spec.ts.snap +0 -2
- package/src/components/Amelipro/AmeliproErrorTemplate/__tests__/AmeliproErrorTemplate.spec.ts +160 -20
- package/src/components/Amelipro/AmeliproErrorTemplate/__tests__/__snapshots__/AmeliproErrorTemplate.spec.ts.snap +34 -177
- package/src/components/Amelipro/AmeliproFilePreview/AmeliproFilePreview.vue +1 -0
- package/src/components/Amelipro/AmeliproFilePreview/__tests__/AmeliproFilePreview.spec.ts +248 -19
- package/src/components/Amelipro/AmeliproFilePreview/__tests__/__snapshots__/AmeliproFilePreview.spec.ts.snap +34 -203
- package/src/components/Amelipro/AmeliproFirstLogin/__tests__/__snapshots__/AmeliproFirstLogin.spec.ts.snap +6 -144
- package/src/components/Amelipro/AmeliproIcon/AmeliproIcon.vue +20 -2
- package/src/components/Amelipro/AmeliproIcon/__tests__/__snapshots__/AmeliproIcon.spec.ts.snap +1 -25
- package/src/components/Amelipro/AmeliproIllustratedRadioGroup/AmeliproIllustratedRadioGroup.stories.ts +5 -5
- package/src/components/Amelipro/AmeliproIllustratedRadioGroup/AmeliproIllustratedRadioGroup.vue +6 -6
- package/src/components/Amelipro/AmeliproIllustratedRadioGroup/__tests__/AmeliproIllustratedRadioGroup.spec.ts +22 -22
- package/src/components/Amelipro/AmeliproIllustratedRadioGroup/__tests__/__snapshots__/AmeliproIllustratedRadioGroup.spec.ts.snap +2 -2
- package/src/components/Amelipro/AmeliproMultipleFoldingCard/__tests__/AmeliproMultipleFoldingCard.spec.ts +304 -0
- package/src/components/Amelipro/AmeliproMultipleFoldingCard/__tests__/__snapshots__/AmeliproMultipleFoldingCard.spec.ts.snap +373 -0
- package/src/components/Amelipro/AmeliproPatientLogged/AmeliproPatientLogged.stories.ts +64 -34
- package/src/components/Amelipro/AmeliproPatientLogged/AmeliproPatientLogged.vue +75 -16
- package/src/components/Amelipro/AmeliproPatientLogged/__tests__/AmeliproPatientLogged.spec.ts +4 -2
- package/src/components/Amelipro/AmeliproPatientLogged/__tests__/__snapshots__/AmeliproPatientLogged.spec.ts.snap +63 -177
- package/src/components/Amelipro/AmeliproPatientLogged/types.d.ts +2 -1
- package/src/components/Amelipro/AmeliproPatientLogin/AmeliproPatientLogin.stories.ts +11 -5
- package/src/components/Amelipro/AmeliproPatientLogin/AmeliproPatientLoginForm/AmeliproPatientLoginForm.vue +9 -1
- package/src/components/Amelipro/AmeliproPostalAddressField/AmeliproPostalAddressCityRow/AmeliproPostalAddressCityRow.vue +162 -72
- package/src/components/Amelipro/AmeliproPostalAddressField/AmeliproPostalAddressCityRow/__tests__/AmeliproPostalAddressCityRow.spec.ts +2 -2
- package/src/components/Amelipro/AmeliproPostalAddressField/AmeliproPostalAddressCityRow/__tests__/__snapshots__/AmeliproPostalAddressCityRow.spec.ts.snap +6 -39
- package/src/components/Amelipro/AmeliproPostalAddressField/AmeliproPostalAddressField.stories.ts +3 -3
- package/src/components/Amelipro/AmeliproPostalAddressField/AmeliproPostalAddressField.vue +8 -8
- package/src/components/Amelipro/AmeliproPostalAddressField/{tests → __tests__}/AmeliproPostalAddressField.spec.ts +2 -2
- package/src/components/Amelipro/AmeliproPostalAddressField/{tests → __tests__}/__snapshots__/AmeliproPostalAddressField.spec.ts.snap +11 -52
- package/src/components/Amelipro/AmeliproRadioGroup/AmeliproRadioGroup.stories.ts +7 -7
- package/src/components/Amelipro/AmeliproRadioGroup/AmeliproRadioGroup.vue +8 -8
- package/src/components/Amelipro/AmeliproRadioGroup/__tests__/AmeliproRadioGroup.spec.ts +6 -6
- package/src/components/Amelipro/AmeliproRadioGroup/__tests__/__snapshots__/AmeliproRadioGroup.spec.ts.snap +2 -2
- package/src/components/Amelipro/AmeliproResultList/__tests__/__snapshots__/AmeliproResultList.spec.ts.snap +2 -14
- package/src/components/Amelipro/AmeliproSelect/AmeliproSelect.stories.ts +7 -7
- package/src/components/Amelipro/AmeliproSelect/AmeliproSelect.vue +41 -5
- package/src/components/Amelipro/AmeliproSelect/__tests__/AmeliproSelect.spec.ts +12 -12
- package/src/components/Amelipro/AmeliproSelect/__tests__/__snapshots__/AmeliproSelect.spec.ts.snap +2 -2
- package/src/components/Amelipro/AmeliproStepper/AmeliproStepper.vue +2 -2
- package/src/components/Amelipro/AmeliproStepper/__tests__/__snapshots__/AmeliproStepper.spec.ts.snap +2 -2
- package/src/components/Amelipro/AmeliproTable/AmeliproTable.vue +2 -2
- package/src/components/Amelipro/AmeliproTable/__tests__/AmeliproTable.spec.ts +463 -68
- package/src/components/Amelipro/AmeliproTable/__tests__/__snapshots__/AmeliproTable.spec.ts.snap +176 -511
- package/src/components/Amelipro/AmeliproTabs/AmeliproTabs.stories.ts +94 -0
- package/src/components/Amelipro/AmeliproTabs/AmeliproTabs.vue +6 -2
- package/src/components/Amelipro/AmeliproTabs/__tests__/AmeliproTabs.spec.ts +4 -0
- package/src/components/Amelipro/AmeliproTabs/__tests__/__snapshots__/AmeliproTabs.spec.ts.snap +4 -2
- package/src/components/Amelipro/AmeliproTextArea/AmeliproTextArea.stories.ts +6 -6
- package/src/components/Amelipro/AmeliproTextArea/AmeliproTextArea.vue +4 -4
- package/src/components/Amelipro/AmeliproTextArea/__tests__/AmeliproTextArea.spec.ts +3 -3
- package/src/components/Amelipro/AmeliproTextArea/__tests__/__snapshots__/AmeliproTextArea.spec.ts.snap +1 -2
- package/src/components/Amelipro/AmeliproTextField/AmeliproTextField.stories.ts +78 -10
- package/src/components/Amelipro/AmeliproTextField/AmeliproTextField.vue +114 -6
- package/src/components/Amelipro/AmeliproTextField/__tests__/AmeliproTextField.spec.ts +19 -7
- package/src/components/Amelipro/AmeliproTextField/__tests__/__snapshots__/AmeliproTextField.spec.ts.snap +2 -0
- package/src/components/Amelipro/AmeliproTileBtn/AmeliproTileBtn.stories.ts +44 -0
- package/src/components/Amelipro/AmeliproTileBtn/AmeliproTileBtn.vue +79 -1
- package/src/components/Amelipro/AmeliproTooltips/AmeliproTooltips.stories.ts +45 -0
- package/src/components/Amelipro/AmeliproTooltips/AmeliproTooltips.vue +6 -0
- package/src/components/Amelipro/AmeliproTooltips/__tests__/__snapshots__/AmeliproTooltips.spec.ts.snap +0 -2
- package/src/components/Amelipro/AmeliproUpload/AmeliproUpload.stories.ts +2 -2
- package/src/components/Amelipro/AmeliproUpload/AmeliproUpload.vue +21 -7
- package/src/components/Amelipro/AmeliproUpload/__tests__/AmeliproUpload.spec.ts +252 -44
- package/src/components/Amelipro/AmeliproUpload/__tests__/__snapshots__/AmeliproUpload.spec.ts.snap +166 -0
- package/src/components/Amelipro/ServiceMenu/ServiceBtn/__tests__/ServiceBtn.spec.ts +137 -0
- package/src/components/Amelipro/ServiceMenu/ServiceBtn/__tests__/__snapshots__/ServiceBtn.spec.ts.snap +56 -0
- package/src/components/Amelipro/ServiceMenu/ServiceList/__tests__/ServiceList.spec.ts +116 -0
- package/src/components/Amelipro/ServiceMenu/ServiceList/__tests__/__snapshots__/ServiceList.spec.ts.snap +58 -0
- package/src/components/Amelipro/ServiceMenu/ServiceMenuContent/__tests__/ServiceMenuContent.spec.ts +118 -0
- package/src/components/Amelipro/ServiceMenu/ServiceMenuContent/__tests__/__snapshots__/ServiceMenuContent.spec.ts.snap +151 -0
- package/src/components/Amelipro/ServiceMenu/__tests__/ServiceMenu.spec.ts +259 -0
- package/src/components/Amelipro/ServiceMenu/__tests__/__snapshots__/ServiceMenu.spec.ts.snap +102 -0
- package/src/components/Amelipro/StructureMenu/StructureBtn/StructureBtn.vue +13 -0
- package/src/components/Amelipro/StructureMenu/StructureBtn/__tests__/StructureBtn.spec.ts +96 -0
- package/src/components/Amelipro/StructureMenu/StructureBtn/__tests__/__snapshots__/StructureBtn.spec.ts.snap +63 -0
- package/src/components/Amelipro/StructureMenu/StructureItem/StructureItem.vue +14 -2
- package/src/components/Amelipro/StructureMenu/StructureItem/__tests__/StructureItem.spec.ts +133 -0
- package/src/components/Amelipro/StructureMenu/StructureItem/__tests__/__snapshots__/StructureItem.spec.ts.snap +159 -0
- package/src/components/Amelipro/StructureMenu/StructureItem/types.d.ts +1 -0
- package/src/components/Amelipro/StructureMenu/StructureList/__tests__/StructureList.spec.ts +190 -0
- package/src/components/Amelipro/StructureMenu/StructureList/__tests__/__snapshots__/StructureList.spec.ts.snap +109 -0
- package/src/components/Amelipro/StructureMenu/StructureMenu.stories.ts +93 -63
- package/src/components/Amelipro/StructureMenu/StructureMenu.vue +5 -0
- package/src/components/Amelipro/StructureMenu/StructureTabs/StructureTabs.vue +22 -1
- package/src/components/Amelipro/StructureMenu/StructureTabs/__tests__/StructureTabs.spec.ts +163 -0
- package/src/components/Amelipro/StructureMenu/StructureTabs/__tests__/__snapshots__/StructureTabs.spec.ts.snap +105 -0
- package/src/components/Amelipro/StructureMenu/__tests__/StructureMenu.spec.ts +171 -0
- package/src/components/Amelipro/StructureMenu/__tests__/__snapshots__/StructureMenu.spec.ts.snap +39 -0
- package/src/components/Amelipro/UserInformationSummary/__tests__/UserInformationSummary.spec.ts +140 -0
- package/src/components/Amelipro/UserInformationSummary/{tests → __tests__}/__snapshots__/UserInformationSummary.spec.ts.snap +17 -24
- package/src/components/Amelipro/UserMenu/UserMenu.stories.ts +3 -3
- package/src/components/Amelipro/UserMenu/UserMenu.vue +2 -2
- package/src/components/Amelipro/UserMenu/UserMenuDetails/__tests__/UserMenuDetails.spec.ts +150 -0
- package/src/components/Amelipro/UserMenu/UserMenuDetails/__tests__/__snapshots__/UserMenuDetails.spec.ts.snap +117 -0
- package/src/components/Amelipro/UserMenu/__tests__/UserMenu.spec.ts +141 -0
- package/src/components/Amelipro/UserMenu/__tests__/__snapshots__/UserMenu.spec.ts.snap +103 -0
- package/src/components/BackBtn/tests/BackBtn.a11y.spec.ts +20 -0
- package/src/components/BackToTopBtn/BackToTopBtn.stories.ts +9 -0
- package/src/components/BackToTopBtn/tests/BackToTopBtn.a11y.spec.ts +37 -0
- package/src/components/Captcha/Captcha.vue +9 -24
- package/src/components/Captcha/CaptchaHelpdesk.vue +42 -0
- package/src/components/Captcha/tests/Captcha.a11y.spec.ts +49 -0
- package/src/components/Captcha/tests/__snapshots__/Captcha.spec.ts.snap +256 -268
- package/src/components/ChipList/ChipList.stories.ts +15 -0
- package/src/components/ChipList/ChipList.vue +20 -17
- package/src/components/ChipList/locales.ts +1 -0
- package/src/components/ChipList/tests/ChipList.a11y.spec.ts +40 -0
- package/src/components/CollapsibleList/Accessibilite.mdx +67 -11
- package/src/components/CollapsibleList/tests/CollapsibleList.a11y.spec.ts +38 -0
- package/src/components/ContextualMenu/ContextualMenu.stories.ts +3 -0
- package/src/components/ContextualMenu/tests/ContextualMenu.a11y.spec.ts +30 -0
- package/src/components/CookieBanner/CookieBanner.stories.ts +15 -0
- package/src/components/CookieBanner/CookieBanner.vue +0 -1
- package/src/components/CookieBanner/tests/CookieBanner.a11y.spec.ts +29 -0
- package/src/components/CookiesSelection/CookiesInformation/tests/CookiesInformation.a11y.spec.ts +46 -0
- package/src/components/CookiesSelection/CookiesTable/tests/CookiesTable.a11y.spec.ts +37 -0
- package/src/components/CookiesSelection/tests/CookiesSelection.a11y.spec.ts +58 -0
- package/src/components/CopyBtn/CopyBtn.stories.ts +21 -0
- package/src/components/CopyBtn/tests/CopyBtn.a11y.spec.ts +40 -0
- package/src/components/CopyBtn/tests/__snapshots__/CopyBtn.spec.ts.snap +0 -1
- package/src/components/Customs/Selects/SelectBtnField/Accessibilite.stories.ts +4 -0
- package/src/components/Customs/Selects/SelectBtnField/SelectBtnField.stories.ts +154 -82
- package/src/components/Customs/Selects/SelectBtnField/SelectBtnField.vue +229 -125
- package/src/components/Customs/Selects/SelectBtnField/tests/SelectBtnField.spec.ts +12 -12
- package/src/components/Customs/Selects/SelectBtnField/tests/__snapshots__/SelectBtnField.spec.ts.snap +344 -826
- package/src/components/Customs/Selects/SyBtnSelect/SyBtnSelect.stories.ts +30 -0
- package/src/components/Customs/Selects/SyBtnSelect/SyBtnSelect.vue +1 -0
- package/src/components/Customs/Selects/SySelect/SySelect.stories.ts +27 -0
- package/src/components/Customs/Selects/SySelect/SySelect.vue +215 -169
- package/src/components/Customs/Selects/SySelect/composables/tests/useSySelectKeyboard.spec.ts +4 -2
- package/src/components/Customs/Selects/SySelect/composables/useSySelectKeyboard.ts +7 -9
- package/src/components/Customs/Selects/SySelect/tests/SySelect.a11y.spec.ts +40 -0
- package/src/components/Customs/SyCheckbox/SyCheckbox.stories.ts +7 -3
- package/src/components/Customs/SyCheckbox/SyCheckbox.vue +20 -2
- package/src/components/Customs/SyCheckbox/tests/SyCheckbox.a11y.spec.ts +26 -0
- package/src/components/Customs/SyForm/SyForm.a11y.spec.ts +33 -0
- package/src/components/Customs/SyForm/SyForm.mdx +47 -7
- package/src/components/Customs/SyForm/SyForm.stories.ts +38 -34
- package/src/components/Customs/SyForm/SyForm.vue +27 -6
- package/src/components/Customs/SyIcon/SyIcon.a11y.spec.ts +37 -0
- package/src/components/Customs/SyIcon/SyIcon.stories.ts +5 -0
- package/src/components/Customs/SyPagination/tests/SyPagination.a11y.spec.ts +27 -0
- package/src/components/Customs/SyRadioGroup/Accessibilite.mdx +263 -0
- package/src/components/Customs/SyRadioGroup/SyRadioGroup.mdx +37 -0
- package/src/components/Customs/SyRadioGroup/SyRadioGroup.stories.ts +665 -0
- package/src/components/Customs/SyRadioGroup/SyRadioGroup.vue +324 -0
- package/src/components/Customs/SyRadioGroup/locales.ts +3 -0
- package/src/components/Customs/SyRadioGroup/tests/SyRadioGroup.a11y.spec.ts +30 -0
- package/src/components/Customs/SyRadioGroup/tests/SyRadioGroup.spec.ts +135 -0
- package/src/components/Customs/SyTabs/SyTabs.stories.ts +33 -0
- package/src/components/Customs/SyTabs/SyTabs.vue +1 -1
- package/src/components/Customs/SyTabs/tests/SyTabs.a11y.spec.ts +51 -0
- package/src/components/Customs/SyTextField/SyTextField.stories.ts +3 -0
- package/src/components/Customs/SyTextField/SyTextField.vue +232 -199
- package/src/components/Customs/SyTextField/tests/SyTextField.a11y.spec.ts +27 -0
- package/src/components/Customs/SyTextField/tests/SyTextField.spec.ts +32 -2
- package/src/components/DataList/DataList.mdx +3 -1
- package/src/components/DataList/DataList.stories.ts +67 -17
- package/src/components/DataList/DataList.vue +13 -1
- package/src/components/DataList/tests/DataList.a11y.spec.ts +35 -0
- package/src/components/DataListGroup/DataListGroup.stories.ts +42 -12
- package/src/components/DataListGroup/DataListGroup.vue +14 -1
- package/src/components/DataListGroup/tests/DataListGroup.a11y.spec.ts +24 -0
- package/src/components/DataListItem/DataListItem.vue +10 -2
- package/src/components/DataListItem/tests/DataListItem.a11y.spec.ts +31 -0
- package/src/components/DataListItem/tests/DataListItem.spec.ts +1 -1
- package/src/components/DatePicker/CalendarMode/DatePicker.stories.ts +45 -0
- package/src/components/DatePicker/CalendarMode/DatePicker.vue +230 -205
- package/src/components/DatePicker/CalendarMode/tests/DatePicker.a11y.spec.ts +27 -0
- package/src/components/DatePicker/CalendarMode/tests/DatePicker.events.spec.ts +5 -0
- package/src/components/DatePicker/CalendarMode/tests/DatePicker.spec.ts +179 -179
- package/src/components/DatePicker/ComplexDatePicker/ComplexDatePicker.stories.ts +54 -0
- package/src/components/DatePicker/ComplexDatePicker/ComplexDatePicker.vue +337 -278
- package/src/components/DatePicker/ComplexDatePicker/tests/ComplexDatePicker.a11y.spec.ts +26 -0
- package/src/components/DatePicker/ComplexDatePicker/tests/ComplexDatePicker.spec.ts +234 -827
- package/src/components/DatePicker/DateTextInput/DateRange.stories.ts +12 -0
- package/src/components/DatePicker/DateTextInput/DateTextInput.vue +46 -81
- package/src/components/DatePicker/DateTextInput/tests/DateTextInput.a11y.spec.ts +27 -0
- package/src/components/DatePicker/DateTextInput/tests/DateTextInput.spec.ts +350 -0
- package/src/components/DatePicker/composables/index.ts +4 -1
- package/src/components/DatePicker/composables/tests/useCalendarKeyboardNavigation.spec.ts +270 -0
- package/src/components/DatePicker/composables/tests/useDatePickerViewMode.spec.ts +61 -3
- package/src/components/DatePicker/composables/tests/useDateRangeInput.spec.ts +198 -0
- package/src/components/DatePicker/composables/tests/useDisplayedDateString.spec.ts +36 -2
- package/src/components/DatePicker/composables/tests/useInputHandler.spec.ts +755 -0
- package/src/components/DatePicker/composables/tests/useKeyboardEvents.spec.ts +168 -0
- package/src/components/DatePicker/composables/tests/useMonthButtonCustomization.spec.ts +40 -34
- package/src/components/DatePicker/composables/useAsteriskDisplay.ts +1 -2
- package/src/components/DatePicker/composables/useCalendarKeyboardNavigation.ts +155 -0
- package/src/components/DatePicker/composables/useDatePickerState.ts +163 -0
- package/src/components/DatePicker/composables/useDateRangeInput.ts +4 -8
- package/src/components/DatePicker/composables/useDateTextField.ts +156 -0
- package/src/components/DatePicker/composables/useHolidayHighlighting.ts +64 -0
- package/src/components/DatePicker/composables/useInputHandler.ts +25 -19
- package/src/components/DatePicker/composables/useMonthButtonCustomization.ts +51 -26
- package/src/components/DatePicker/constants/messages.ts +0 -1
- package/src/components/DatePicker/docExamples/DatePickerBidirectionalValidation.vue +2 -2
- package/src/components/DatePicker/playground/ComplexDatePickerPlayground.vue +16 -8
- package/src/components/DiacriticPicker/tests/DiacriticPicker.a11y.spec.ts +46 -0
- package/src/components/DialogBox/DialogBox.stories.ts +5 -2
- package/src/components/DialogBox/DialogBox.vue +5 -0
- package/src/components/DialogBox/config.ts +5 -0
- package/src/components/DialogBox/tests/DialogBox.a11y.spec.ts +43 -0
- package/src/components/DownloadBtn/tests/DownloadBtn.a11y.spec.ts +26 -0
- package/src/components/ErrorPage/ErrorPage.stories.ts +60 -0
- package/src/components/ErrorPage/ErrorPage.vue +1 -1
- package/src/components/ErrorPage/tests/ErrorPage.a11y.spec.ts +29 -0
- package/src/components/ErrorPage/tests/ErrorPage.spec.ts +17 -0
- package/src/components/ExternalLinks/ExternalLinks.stories.ts +21 -0
- package/src/components/ExternalLinks/tests/ExternalLinks.a11y.spec.ts +39 -0
- package/src/components/ExternalLinks/tests/__snapshots__/ExternalLinks.spec.ts.snap +0 -1
- package/src/components/FileList/FileList.stories.ts +3 -0
- package/src/components/FileList/tests/FileList.a11y.spec.ts +41 -0
- package/src/components/FilePreview/FilePreview.stories.ts +3 -0
- package/src/components/FilePreview/tests/FilePreview.a11y.spec.ts +47 -0
- package/src/components/FileUpload/tests/FileUpload.a11y.spec.ts +25 -0
- package/src/components/FilterInline/FilterInline.stories.ts +15 -0
- package/src/components/FilterInline/FilterInline.vue +8 -4
- package/src/components/FilterInline/tests/FilterInline.a11y.spec.ts +36 -0
- package/src/components/FilterInline/tests/__snapshots__/FilterInline.spec.ts.snap +0 -3
- package/src/components/FilterSideBar/Accessibilite.stories.ts +4 -0
- package/src/components/FilterSideBar/FilterSideBar.stories.ts +33 -11
- package/src/components/FilterSideBar/FilterSideBar.vue +146 -83
- package/src/components/FilterSideBar/locales.ts +6 -0
- package/src/components/FilterSideBar/tests/FilterSideBar.a11y.spec.ts +59 -0
- package/src/components/FilterSideBar/tests/FilterSideBar.spec.ts +2 -2
- package/src/components/FooterBar/Accessibilite.mdx +67 -11
- package/src/components/FooterBar/FooterBar.vue +1 -1
- package/src/components/FooterBar/config.ts +2 -2
- package/src/components/FooterBar/tests/FooterBar.a11y.spec.ts +31 -0
- package/src/components/FooterBar/tests/FooterBarConfig.spec.ts +1 -1
- package/src/components/FooterBar/tests/__snapshots__/FooterBar.spec.ts.snap +1 -1
- package/src/components/FranceConnectBtn/tests/FranceConnectBtn.a11y.spec.ts +25 -0
- package/src/components/HeaderBar/HeaderBar.stories.ts +21 -0
- package/src/components/HeaderBar/HeaderBar.vue +47 -40
- package/src/components/HeaderBar/HeaderBurgerMenu/HeaderBurgerMenu.stories.ts +12 -0
- package/src/components/HeaderBar/HeaderBurgerMenu/HeaderSubMenu/HeaderSubMenu.stories.ts +3 -0
- package/src/components/HeaderBar/HeaderBurgerMenu/HeaderSubMenu/HeaderSubMenu.vue +4 -0
- package/src/components/HeaderBar/HeaderBurgerMenu/menu.scss +17 -7
- package/src/components/HeaderBar/consts.scss +0 -1
- package/src/components/HeaderBar/tests/HeaderBar.a11y.spec.ts +33 -0
- package/src/components/HeaderBar/tests/__snapshots__/HeaderBar.spec.ts.snap +58 -57
- package/src/components/HeaderLoading/tests/HeaderLoading.a11y.spec.ts +25 -0
- package/src/components/HeaderNavigationBar/HeaderNavigationBar.stories.ts +42 -0
- package/src/components/HeaderNavigationBar/HeaderNavigationBar.vue +4 -0
- package/src/components/HeaderNavigationBar/HorizontalNavbar/HorizontalNavbar.vue +6 -2
- package/src/components/HeaderNavigationBar/tests/HeaderNavigationBar.a11y.spec.ts +45 -0
- package/src/components/HeaderToolbar/HeaderToolbar.stories.ts +6 -0
- package/src/components/HeaderToolbar/HeaderToolbar.vue +0 -3
- package/src/components/HeaderToolbar/tests/HeaderToolbar.a11y.spec.ts +25 -0
- package/src/components/LangBtn/LangBtn.stories.ts +12 -0
- package/src/components/LangBtn/tests/LangBtn.a11y.spec.ts +25 -0
- package/src/components/Logo/tests/Logo.a11y.spec.ts +20 -0
- package/src/components/LogoBrandSection/tests/LogoBrandSection.a11y.spec.ts +38 -0
- package/src/components/LunarCalendar/LunarCalendar.mdx +33 -0
- package/src/components/LunarCalendar/LunarCalendar.stories.ts +232 -0
- package/src/components/LunarCalendar/LunarCalendar.vue +57 -0
- package/src/components/LunarCalendar/tests/LunarCalendar.a11y.spec.ts +31 -0
- package/src/components/LunarCalendar/tests/LunarCalendar.spec.ts +79 -0
- package/src/components/LunarCalendar/useLunarCalendarRules.ts +96 -0
- package/src/components/LunarCalendar/useLunarCalendarValidation.ts +47 -0
- package/src/components/MaintenancePage/MaintenancePage.stories.ts +46 -0
- package/src/components/MaintenancePage/MaintenancePage.vue +7 -5
- package/src/components/MaintenancePage/tests/MaintenancePage.a11y.spec.ts +21 -0
- package/src/components/NirField/NirField.stories.ts +6 -0
- package/src/components/NirField/tests/NirField.a11y.spec.ts +32 -0
- package/src/components/NotFoundPage/NotFoundPage.stories.ts +56 -0
- package/src/components/NotFoundPage/NotFoundPage.vue +7 -5
- package/src/components/NotFoundPage/tests/NotFoundPage.a11y.spec.ts +31 -0
- package/src/components/NotificationBar/Notification/Notification.vue +203 -0
- package/src/components/NotificationBar/NotificationBar.stories.ts +151 -140
- package/src/components/NotificationBar/NotificationBar.vue +148 -202
- package/src/components/NotificationBar/config.ts +1 -1
- package/src/components/NotificationBar/tests/NotificationBar.a11y.spec.ts +66 -0
- package/src/components/NotificationBar/tests/NotificationBar.spec.ts +173 -177
- package/src/components/NotificationBar/tests/__snapshots__/NotificationBar.spec.ts.snap +67 -29
- package/src/components/PageContainer/tests/PageContainer.a11y.spec.ts +27 -0
- package/src/components/PaginatedTable/PaginatedTable.stories.ts +21 -10
- package/src/components/PaginatedTable/PaginatedTable.vue +72 -36
- package/src/components/PaginatedTable/tests/PaginatedTable.a11y.spec.ts +43 -0
- package/src/components/PasswordField/PasswordField.stories.ts +39 -0
- package/src/components/PasswordField/tests/PasswordField.a11y.spec.ts +26 -0
- package/src/components/PeriodField/tests/PeriodField.a11y.spec.ts +31 -0
- package/src/components/PhoneField/PhoneField.stories.ts +51 -0
- package/src/components/PhoneField/PhoneField.vue +102 -83
- package/src/components/PhoneField/tests/PhoneField.a11y.spec.ts +34 -0
- package/src/components/RangeField/tests/RangeField.a11y.spec.ts +32 -0
- package/src/components/RatingPicker/RatingPicker.stories.ts +21 -0
- package/src/components/SearchListField/tests/SearchListField.spec.ts +7 -53
- package/src/components/SkipLink/Accessibilite.mdx +59 -13
- package/src/components/SkipLink/SkipLink.stories.ts +41 -8
- package/src/components/SubHeader/SubHeader.stories.ts +178 -92
- package/src/components/SubHeader/SubHeader.vue +84 -71
- package/src/components/SubHeader/config.ts +1 -1
- package/src/components/SyAlert/SyAlert.vue +6 -3
- package/src/components/SyTextArea/SyTextArea.stories.ts +40 -0
- package/src/components/SyTextArea/SyTextArea.vue +13 -0
- package/src/components/SyTextArea/locales.ts +1 -0
- package/src/components/SyTextArea/tests/SyTextArea.spec.ts +42 -0
- package/src/components/TableToolbar/TableToolbar.stories.ts +3 -0
- package/src/components/TableToolbar/tests/__snapshots__/TableToolbar.spec.ts.snap +24 -72
- package/src/components/Tables/SyServerTable/SyServerTable.stories.ts +591 -24
- package/src/components/Tables/SyServerTable/SyServerTable.vue +19 -13
- package/src/components/Tables/SyTable/FilterRules.stories.ts +12 -0
- package/src/components/Tables/SyTable/SyTable.stories.ts +460 -18
- package/src/components/Tables/SyTable/SyTable.vue +16 -11
- package/src/components/Tables/common/TableHeader.vue +16 -7
- package/src/components/Tables/common/filters/DateFilter.vue +1 -1
- package/src/components/Tables/common/locales.ts +1 -0
- package/src/components/Tables/common/tableFilterUtils.ts +3 -3
- package/src/components/Tables/common/types.ts +4 -2
- package/src/components/Tables/common/useTableCheckbox.ts +4 -3
- package/src/components/Tables/common/useTableFilter.ts +2 -2
- package/src/components/Tables/common/useTableItems.ts +4 -19
- package/src/components/UserMenuBtn/UserMenuBtn.stories.ts +31 -1
- package/src/components/UserMenuBtn/UserMenuBtn.vue +2 -1
- package/src/components/UserMenuBtn/tests/UserMenuBtn.a11y.spec.ts +31 -0
- package/src/components/index.ts +2 -0
- package/src/composables/validation/tests/useFormValidation.spec.ts +251 -0
- package/src/composables/validation/tests/useValidatable.spec.ts +90 -0
- package/src/directives/lockFocus.ts +12 -2
- package/src/stories/Accessibilite/Audit/Exemptions-derogations.mdx +241 -0
- package/src/stories/Accessibilite/KitDePreAudit/Introduction.mdx +17 -10
- package/src/stories/Accessibilite/KitDePreAudit/Outils/Introduction.mdx +16 -0
- package/src/stories/Accessibilite/KitDePreAudit/Preaudit.mdx +160 -106
- package/src/stories/Accessibilite/Vuetify/VuetifyItems.ts +2 -1
- package/src/stories/GuideDuDev/ClassesUtilitaires/DataUtilities.mdx +6 -6
- package/src/stories/GuideDuDev/ClassesUtilitaires/DomBrowserUtilities.mdx +52 -59
- package/src/stories/GuideDuDev/ClassesUtilitaires/FormattingUtilities.mdx +28 -8
- package/src/stories/GuideDuDev/ClassesUtilitaires/StorageUtilities.mdx +2 -2
- package/src/stories/GuideDuDev/ClassesUtilitaires/ValidationRules.mdx +3 -3
- package/src/stories/GuideDuDev/ClassesUtilitaires/ValidationUtilities.mdx +11 -11
- package/src/stories/GuideDuDev/ClassesUtilitaires/index.mdx +24 -14
- package/src/stories/GuideDuDev/MigrationDepuisBridge.mdx +1 -1
- package/src/stories/GuideDuDev/moduleDeNotification.mdx +1 -1
- package/src/stories/accessibility/AccessibilityGuideLayout.mdx +87 -0
- package/src/stories/styles/accessibility-guide.css +153 -0
- package/src/utils/formatNir/formatNir.ts +15 -0
- package/src/utils/index.ts +1 -0
- package/src/utils/insertAt.ts +11 -0
- package/src/utils/rules/isDateValid/IsDateValid.mdx +2 -2
- package/src/utils/rules/isDateValid/IsDateValid.stories.ts +6 -4
- package/src/utils/rules/isDateValid/index.ts +23 -8
- package/src/utils/rules/isDateValid/tests/isDateValid.spec.ts +9 -0
- package/src/utils/rules/isExactLength/IsExactLenght.mdx +1 -1
- package/src/utils/rules/isHolidayDay/IsHolidayDay.mdx +19 -7
- package/src/utils/rules/isHolidayDay/index.ts +6 -8
- package/src/utils/rules/isHolidayDay/tests/isHolidayDay.spec.ts +13 -1
- package/src/utils/rules/isNotAfterDate/IsNotAfterDate.mdx +2 -2
- package/src/utils/rules/isNotAfterDate/IsNotAfterDate.stories.ts +9 -2
- package/src/utils/rules/isNotAfterDate/index.ts +5 -12
- package/src/utils/rules/isNotAfterDate/tests/isNotAfterDate.spec.ts +20 -0
- package/src/utils/rules/isNotAfterToday/IsNotAfterToday.mdx +2 -2
- package/src/utils/rules/isNotAfterToday/IsNotAfterToday.stories.ts +8 -2
- package/src/utils/rules/isNotAfterToday/index.ts +6 -6
- package/src/utils/rules/isNotAfterToday/tests/isNotAfterToday.spec.ts +20 -0
- package/src/utils/rules/isNotBeforeDate/IsNotBeforeDate.mdx +2 -2
- package/src/utils/rules/isNotBeforeDate/index.ts +5 -12
- package/src/utils/rules/isNotBeforeDate/tests/IsNotBeforeDate.spec.ts +20 -0
- package/src/utils/rules/isNotBeforeToday/IsNotBeforeToday.mdx +2 -2
- package/src/utils/rules/isNotBeforeToday/IsNotBeforeToday.stories.ts +8 -2
- package/src/utils/rules/isNotBeforeToday/index.ts +6 -6
- package/src/utils/rules/isNotBeforeToday/tests/notBeforeToday.spec.ts +19 -0
- package/src/utils/rules/validateDateValue.ts +37 -0
- package/src/vuetifyConfig.ts +6 -2
- package/dist/components/Customs/Selects/SelectBtnField/config.d.ts +0 -11
- package/dist/components/DatePicker/composables/useIconState.d.ts +0 -17
- package/dist/components/DatePicker/tests/setup.d.ts +0 -75370
- package/dist/components/Tables/common/formatters.d.ts +0 -17
- package/dist/main-CbBVJ_le.js +0 -34377
- package/dist/stories/Accessibilite/Vuetify/VuetifyItems.d.ts +0 -70
- package/dist/stories/DesignTokens/StylesTypographiques.stories.new.d.ts +0 -8
- package/dist/stories/DesignTokens/TypographyDisplay.d.ts +0 -28
- package/dist/stories/DesignTokens/vue-shims.d.ts +0 -6
- package/src/components/Amelipro/AmeliproMultipleFoldingCard/tests/AmeliproMultipleFoldingCard.spec.ts +0 -40
- package/src/components/Amelipro/AmeliproMultipleFoldingCard/tests/__snapshots__/AmeliproMultipleFoldingCard.spec.ts.snap +0 -369
- package/src/components/Amelipro/ServiceMenu/ServiceBtn/tests/ServiceBtn.spec.ts +0 -21
- package/src/components/Amelipro/ServiceMenu/ServiceBtn/tests/__snapshots__/ServiceBtn.spec.ts.snap +0 -100
- package/src/components/Amelipro/ServiceMenu/ServiceList/tests/ServiceList.spec.ts +0 -25
- package/src/components/Amelipro/ServiceMenu/ServiceList/tests/__snapshots__/ServiceList.spec.ts.snap +0 -245
- package/src/components/Amelipro/ServiceMenu/ServiceMenuContent/tests/ServiceMenuContent.spec.ts +0 -45
- package/src/components/Amelipro/ServiceMenu/ServiceMenuContent/tests/__snapshots__/ServiceMenuContent.spec.ts.snap +0 -787
- package/src/components/Amelipro/ServiceMenu/tests/ServiceMenu.spec.ts +0 -46
- package/src/components/Amelipro/ServiceMenu/tests/__snapshots__/ServiceMenu.spec.ts.snap +0 -111
- package/src/components/Amelipro/StructureMenu/StructureBtn/tests/StructureBtn.spec.ts +0 -17
- package/src/components/Amelipro/StructureMenu/StructureBtn/tests/__snapshots__/StructureBtn.spec.ts.snap +0 -34
- package/src/components/Amelipro/StructureMenu/StructureItem/tests/StructureItem.spec.ts +0 -21
- package/src/components/Amelipro/StructureMenu/StructureItem/tests/__snapshots__/StructureItem.spec.ts.snap +0 -106
- package/src/components/Amelipro/StructureMenu/StructureList/tests/StructureList.spec.ts +0 -33
- package/src/components/Amelipro/StructureMenu/StructureList/tests/__snapshots__/StructureList.spec.ts.snap +0 -353
- package/src/components/Amelipro/StructureMenu/StructureTabs/tests/StructureTabs.spec.ts +0 -60
- package/src/components/Amelipro/StructureMenu/StructureTabs/tests/__snapshots__/StructureTabs.spec.ts.snap +0 -824
- package/src/components/Amelipro/StructureMenu/tests/StructureMenu.spec.ts +0 -69
- package/src/components/Amelipro/StructureMenu/tests/__snapshots__/StructureMenu.spec.ts.snap +0 -1383
- package/src/components/Amelipro/UserInformationSummary/tests/UserInformationSummary.spec.ts +0 -24
- package/src/components/Amelipro/UserMenu/UserMenuDetails/tests/UserMenuDetails.spec.ts +0 -33
- package/src/components/Amelipro/UserMenu/UserMenuDetails/tests/__snapshots__/UserMenuDetails.spec.ts.snap +0 -3
- package/src/components/Amelipro/UserMenu/tests/UserMenu.spec.ts +0 -34
- package/src/components/Amelipro/UserMenu/tests/__snapshots__/UserMenu.spec.ts.snap +0 -101
- package/src/components/Customs/Selects/SelectBtnField/config.ts +0 -11
- package/src/components/DatePicker/ComplexDatePicker/tests/ComplexDatePicker.events.spec.ts +0 -151
- package/src/components/DatePicker/DateTextInput/DateTextInput.events.spec.ts +0 -148
- package/src/components/DatePicker/DateTextInput/DateTextInput.range.spec.ts +0 -361
- package/src/components/DatePicker/DateTextInput/DateTextInput.spec.ts +0 -709
- package/src/components/DatePicker/composables/tests/useIconState.spec.ts +0 -130
- package/src/components/DatePicker/composables/useIconState.ts +0 -53
- package/src/components/DatePicker/tests/DatePicker.validation.spec.ts +0 -4111
- package/src/components/DatePicker/tests/archiTest.md +0 -33
- package/src/components/DatePicker/tests/navigation.regression.spec.ts +0 -74
- package/src/components/DatePicker/tests/navigation.simple.spec.ts +0 -137
- package/src/components/DatePicker/tests/setup.ts +0 -243
- package/src/components/Tables/common/formatters.ts +0 -72
- package/src/components/Usages/tests/Usages.spec.ts +0 -155
|
@@ -9,6 +9,7 @@ describe('CalendarMode.vue - Events', () => {
|
|
|
9
9
|
beforeEach(() => {
|
|
10
10
|
wrapper = mount(DatePicker, {
|
|
11
11
|
props: {
|
|
12
|
+
label: 'Date Field',
|
|
12
13
|
modelValue: '',
|
|
13
14
|
format: 'DD/MM/YYYY',
|
|
14
15
|
},
|
|
@@ -55,6 +56,7 @@ describe('CalendarMode.vue - Events', () => {
|
|
|
55
56
|
// Créer un composant avec disablePickerInteraction à true
|
|
56
57
|
const wrapperWithDisabledPicker = mount(DatePicker, {
|
|
57
58
|
props: {
|
|
59
|
+
label: 'Date Field',
|
|
58
60
|
modelValue: '',
|
|
59
61
|
format: 'DD/MM/YYYY',
|
|
60
62
|
disablePickerInteraction: true,
|
|
@@ -112,6 +114,7 @@ describe('CalendarMode.vue - Events', () => {
|
|
|
112
114
|
it('accepte différents formats de date', async () => {
|
|
113
115
|
const wrapperWithDashFormat = mount(DatePicker, {
|
|
114
116
|
props: {
|
|
117
|
+
label: 'Date Field',
|
|
115
118
|
modelValue: '',
|
|
116
119
|
format: 'YYYY-MM-DD',
|
|
117
120
|
},
|
|
@@ -133,6 +136,7 @@ describe('CalendarMode.vue - Events', () => {
|
|
|
133
136
|
it('accepte les plages de dates en entrée', async () => {
|
|
134
137
|
const wrapperWithRange = mount(DatePicker, {
|
|
135
138
|
props: {
|
|
139
|
+
label: 'Date Field',
|
|
136
140
|
modelValue: ['01/01/2023', '05/01/2023'],
|
|
137
141
|
format: 'DD/MM/YYYY',
|
|
138
142
|
displayRange: true,
|
|
@@ -156,6 +160,7 @@ describe('CalendarMode.vue - Events', () => {
|
|
|
156
160
|
|
|
157
161
|
const wrapperWithRules = mount(DatePicker, {
|
|
158
162
|
props: {
|
|
163
|
+
label: 'Date Field',
|
|
159
164
|
modelValue: '',
|
|
160
165
|
format: 'DD/MM/YYYY',
|
|
161
166
|
customRules: [customRule],
|
|
@@ -1,85 +1,68 @@
|
|
|
1
|
-
import { mount } from '@vue/test-utils'
|
|
2
|
-
import { describe, it, expect
|
|
1
|
+
import { mount, flushPromises } from '@vue/test-utils'
|
|
2
|
+
import { describe, it, expect } from 'vitest'
|
|
3
3
|
import { nextTick } from 'vue'
|
|
4
4
|
import DatePicker from '../DatePicker.vue'
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
let wrapper
|
|
6
|
+
type DatePickerInstance = InstanceType<typeof DatePicker>
|
|
8
7
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
modelValue: '',
|
|
13
|
-
required: true,
|
|
14
|
-
},
|
|
15
|
-
})
|
|
8
|
+
describe('DatePicker', () => {
|
|
9
|
+
const mountComponent = (props: Record<string, unknown> = {}) => mount(DatePicker, {
|
|
10
|
+
props: { label: 'Date Field', ...props },
|
|
16
11
|
})
|
|
17
12
|
|
|
18
|
-
it('
|
|
19
|
-
const wrapper =
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
expect(wrapper.emitted('update:modelValue')).toBeTruthy()
|
|
23
|
-
})
|
|
13
|
+
it('renders the calendar mode activator input by default', () => {
|
|
14
|
+
const wrapper = mountComponent({
|
|
15
|
+
required: true,
|
|
16
|
+
})
|
|
24
17
|
|
|
25
|
-
it('renders the component', () => {
|
|
26
|
-
const wrapper = mount(DatePicker)
|
|
27
18
|
expect(wrapper.exists()).toBe(true)
|
|
19
|
+
const input = wrapper.find('input')
|
|
20
|
+
expect(input.exists()).toBe(true)
|
|
28
21
|
})
|
|
29
22
|
|
|
30
|
-
it('emits
|
|
23
|
+
it('emits update:modelValue when a valid date is typed in single mode', async () => {
|
|
24
|
+
const wrapper = mountComponent({
|
|
25
|
+
format: 'DD/MM/YYYY',
|
|
26
|
+
})
|
|
27
|
+
|
|
31
28
|
const input = wrapper.find('input')
|
|
32
29
|
await input.setValue('01/01/2023')
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
})
|
|
30
|
+
await input.trigger('blur')
|
|
31
|
+
await flushPromises()
|
|
36
32
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
await nextTick()
|
|
41
|
-
// Simuler un clic pour s'assurer que le CalendarMode est complètement initialisé
|
|
42
|
-
const input = wrapper.find('input')
|
|
43
|
-
await input.trigger('click')
|
|
44
|
-
await nextTick()
|
|
45
|
-
// Attendre un peu pour que le DOM soit mis à jour
|
|
46
|
-
await new Promise(resolve => setTimeout(resolve, 100))
|
|
47
|
-
// Vérifier que le CalendarMode est visible
|
|
48
|
-
const datePickerEl = document.querySelector('.v-date-picker')
|
|
49
|
-
expect(datePickerEl).not.toBeNull()
|
|
50
|
-
// Vérifier qu'il y a des boutons de navigation
|
|
51
|
-
const navigationButtons = datePickerEl?.querySelectorAll('button') || []
|
|
52
|
-
expect(navigationButtons.length).toBeGreaterThan(0)
|
|
33
|
+
const emitted = wrapper.emitted('update:modelValue')
|
|
34
|
+
expect(emitted).toBeTruthy()
|
|
35
|
+
expect(emitted && emitted[0][0]).toBe('01/01/2023')
|
|
53
36
|
})
|
|
54
37
|
|
|
55
|
-
it('handles invalid date input gracefully', async () => {
|
|
38
|
+
it('handles invalid typed date input gracefully', async () => {
|
|
39
|
+
const wrapper = mountComponent({
|
|
40
|
+
format: 'DD/MM/YYYY',
|
|
41
|
+
})
|
|
42
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
43
|
+
|
|
56
44
|
const input = wrapper.find('input')
|
|
57
45
|
await input.setValue('invalid date')
|
|
58
|
-
|
|
46
|
+
await input.trigger('blur')
|
|
47
|
+
await flushPromises()
|
|
48
|
+
|
|
49
|
+
expect(vm.selectedDates).toBeNull()
|
|
59
50
|
expect(wrapper.emitted('update:modelValue')).toBeFalsy()
|
|
60
51
|
})
|
|
61
52
|
|
|
62
|
-
it('
|
|
63
|
-
const
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
const
|
|
67
|
-
|
|
68
|
-
// Démonte le composant
|
|
69
|
-
wrapper.unmount()
|
|
70
|
-
|
|
71
|
-
// Vérifie que removeEventListener a été appelé avec les bons arguments
|
|
72
|
-
expect(removeEventListenerSpy).toHaveBeenCalledWith('click', wrapper.vm.handleClickOutside)
|
|
73
|
-
|
|
74
|
-
// Nettoie le spy
|
|
75
|
-
removeEventListenerSpy.mockRestore()
|
|
76
|
-
})
|
|
53
|
+
it('initializeSelectedDates returns an array of dates for a valid range', () => {
|
|
54
|
+
const wrapper = mountComponent({
|
|
55
|
+
format: 'DD/MM/YYYY',
|
|
56
|
+
})
|
|
57
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
77
58
|
|
|
78
|
-
it('returns an array of all dates between two valid dates', () => {
|
|
79
59
|
const datesArray = ['01/01/2023', '05/01/2023']
|
|
80
|
-
const result =
|
|
60
|
+
const result = vm.initializeSelectedDates(datesArray, 'DD/MM/YYYY')
|
|
81
61
|
|
|
82
62
|
expect(Array.isArray(result)).toBe(true)
|
|
63
|
+
if (!Array.isArray(result)) {
|
|
64
|
+
throw new Error('Expected initializeSelectedDates to return an array of dates')
|
|
65
|
+
}
|
|
83
66
|
expect(result.length).toBe(2)
|
|
84
67
|
expect(result[0]).toBeInstanceOf(Date)
|
|
85
68
|
expect(result[1]).toBeInstanceOf(Date)
|
|
@@ -87,200 +70,217 @@ describe('CalendarMode.vue', () => {
|
|
|
87
70
|
expect(result[1].toISOString().split('T')[0]).toBe('2023-01-05')
|
|
88
71
|
})
|
|
89
72
|
|
|
90
|
-
it('
|
|
73
|
+
it('initializeSelectedDates returns an empty array for invalid range inputs', () => {
|
|
74
|
+
const wrapper = mountComponent({
|
|
75
|
+
format: 'DD/MM/YYYY',
|
|
76
|
+
})
|
|
77
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
78
|
+
|
|
91
79
|
const datesArray = ['invalid date', '05/01/2023']
|
|
92
|
-
const result =
|
|
80
|
+
const result = vm.initializeSelectedDates(datesArray, 'DD/MM/YYYY')
|
|
93
81
|
|
|
94
82
|
expect(result).toEqual([])
|
|
95
83
|
})
|
|
96
84
|
|
|
97
|
-
it('handles a single date correctly', () => {
|
|
85
|
+
it('initializeSelectedDates handles a single valid date correctly', () => {
|
|
86
|
+
const wrapper = mountComponent({
|
|
87
|
+
format: 'DD/MM/YYYY',
|
|
88
|
+
})
|
|
89
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
90
|
+
|
|
98
91
|
const singleDate = '01/01/2023'
|
|
99
|
-
const result =
|
|
92
|
+
const result = vm.initializeSelectedDates(singleDate, 'DD/MM/YYYY')
|
|
100
93
|
|
|
101
94
|
expect(result).toBeInstanceOf(Date)
|
|
95
|
+
if (!(result instanceof Date)) {
|
|
96
|
+
throw new Error('Expected initializeSelectedDates to return a Date for a single valid date')
|
|
97
|
+
}
|
|
102
98
|
expect(result.toISOString().split('T')[0]).toBe('2023-01-01')
|
|
103
99
|
})
|
|
104
100
|
|
|
105
|
-
it('returns an empty array
|
|
101
|
+
it('initializeSelectedDates returns an empty array when start date is after end date', () => {
|
|
102
|
+
const wrapper = mountComponent({
|
|
103
|
+
format: 'DD/MM/YYYY',
|
|
104
|
+
})
|
|
105
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
106
|
+
|
|
106
107
|
const datesArray = ['05/01/2023', '01/01/2023']
|
|
107
|
-
const result =
|
|
108
|
+
const result = vm.initializeSelectedDates(datesArray, 'DD/MM/YYYY')
|
|
108
109
|
|
|
109
110
|
expect(result).toEqual([])
|
|
110
111
|
})
|
|
111
112
|
|
|
112
|
-
it('
|
|
113
|
-
const wrapper =
|
|
114
|
-
|
|
115
|
-
required: true,
|
|
116
|
-
},
|
|
113
|
+
it('updateSelectedDates sets selectedDates to null when input is empty', () => {
|
|
114
|
+
const wrapper = mountComponent({
|
|
115
|
+
format: 'DD/MM/YYYY',
|
|
117
116
|
})
|
|
117
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
118
118
|
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
const result = wrapper.vm.validateOnSubmit()
|
|
123
|
-
|
|
124
|
-
expect(result).toBe(true)
|
|
125
|
-
expect(wrapper.vm.errorMessages).toEqual([])
|
|
119
|
+
vm.updateSelectedDates('')
|
|
120
|
+
expect(vm.selectedDates).toBeNull()
|
|
126
121
|
})
|
|
127
122
|
|
|
128
|
-
it('
|
|
129
|
-
const wrapper =
|
|
130
|
-
|
|
131
|
-
required: true,
|
|
132
|
-
},
|
|
123
|
+
it('updateSelectedDates parses a valid date string and updates selectedDates', () => {
|
|
124
|
+
const wrapper = mountComponent({
|
|
125
|
+
format: 'DD/MM/YYYY',
|
|
133
126
|
})
|
|
127
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
128
|
+
|
|
129
|
+
vm.updateSelectedDates('15/01/2023')
|
|
130
|
+
expect(vm.selectedDates).toBeInstanceOf(Date)
|
|
131
|
+
if (!(vm.selectedDates instanceof Date)) {
|
|
132
|
+
throw new Error('Expected selectedDates to be a Date after parsing a valid string')
|
|
133
|
+
}
|
|
134
|
+
expect(vm.selectedDates.toISOString().split('T')[0]).toBe('2023-01-15')
|
|
135
|
+
})
|
|
134
136
|
|
|
135
|
-
|
|
136
|
-
|
|
137
|
+
it('updateSelectedDates does not update selectedDates for an invalid date string', () => {
|
|
138
|
+
const wrapper = mountComponent({
|
|
139
|
+
format: 'DD/MM/YYYY',
|
|
140
|
+
})
|
|
141
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
137
142
|
|
|
138
|
-
|
|
143
|
+
vm.selectedDates = null
|
|
144
|
+
vm.updateSelectedDates('invalid-date')
|
|
139
145
|
|
|
140
|
-
expect(
|
|
141
|
-
expect(wrapper.vm.errorMessages).toContain('La date est requise.')
|
|
146
|
+
expect(vm.selectedDates).toBeNull()
|
|
142
147
|
})
|
|
143
148
|
|
|
144
|
-
it('
|
|
145
|
-
const
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
})
|
|
149
|
+
it('validateOnSubmit returns false and sets error messages when required and empty', async () => {
|
|
150
|
+
const wrapper = mountComponent({
|
|
151
|
+
required: true,
|
|
152
|
+
format: 'DD/MM/YYYY',
|
|
153
|
+
})
|
|
154
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
151
155
|
|
|
152
|
-
|
|
153
|
-
const
|
|
154
|
-
const result = wrapper.vm.initializeSelectedDates(modelValue, 'DD/MM/YYYY')
|
|
156
|
+
vm.selectedDates = null
|
|
157
|
+
const result = await vm.validateOnSubmit()
|
|
155
158
|
|
|
156
|
-
expect(result).
|
|
159
|
+
expect(result).toBe(false)
|
|
160
|
+
expect(vm.errorMessages.length).toBeGreaterThan(0)
|
|
157
161
|
})
|
|
158
162
|
|
|
159
|
-
it('
|
|
160
|
-
const
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
163
|
+
it('validateOnSubmit returns true and clears error messages when required and a date is selected', async () => {
|
|
164
|
+
const wrapper = mountComponent({
|
|
165
|
+
required: true,
|
|
166
|
+
format: 'DD/MM/YYYY',
|
|
167
|
+
})
|
|
168
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
165
169
|
|
|
166
|
-
|
|
167
|
-
|
|
170
|
+
vm.selectedDates = new Date('2023-01-01')
|
|
171
|
+
const result = await vm.validateOnSubmit()
|
|
168
172
|
|
|
169
|
-
expect(
|
|
173
|
+
expect(result).toBe(true)
|
|
174
|
+
expect(vm.errorMessages).toEqual([])
|
|
170
175
|
})
|
|
171
176
|
|
|
172
|
-
it('
|
|
173
|
-
const
|
|
174
|
-
|
|
177
|
+
it('does not produce validation errors when required and readonly with empty selection', async () => {
|
|
178
|
+
const wrapper = mountComponent({
|
|
179
|
+
required: true,
|
|
180
|
+
format: 'DD/MM/YYYY',
|
|
181
|
+
readonly: true,
|
|
182
|
+
})
|
|
183
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
175
184
|
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
})
|
|
185
|
+
vm.selectedDates = null
|
|
186
|
+
const result = await vm.validateOnSubmit()
|
|
179
187
|
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
wrapper.vm.updateSelectedDates(invalidInput)
|
|
183
|
-
expect(wrapper.vm.selectedDates).toBeNull()
|
|
188
|
+
expect(result).toBe(true)
|
|
189
|
+
expect(vm.errorMessages.length).toBe(0)
|
|
184
190
|
})
|
|
185
191
|
|
|
186
|
-
it('toggles date picker visibility
|
|
187
|
-
const wrapper =
|
|
192
|
+
it('toggles date picker visibility with openDatePicker', async () => {
|
|
193
|
+
const wrapper = mountComponent()
|
|
194
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
188
195
|
|
|
189
|
-
expect(
|
|
196
|
+
expect(vm.isDatePickerVisible).toBe(false)
|
|
190
197
|
|
|
191
|
-
|
|
198
|
+
vm.openDatePicker()
|
|
192
199
|
await nextTick()
|
|
193
|
-
expect(
|
|
200
|
+
expect(vm.isDatePickerVisible).toBe(true)
|
|
194
201
|
|
|
195
|
-
|
|
202
|
+
vm.isDatePickerVisible = false
|
|
196
203
|
await nextTick()
|
|
197
|
-
expect(
|
|
204
|
+
expect(vm.isDatePickerVisible).toBe(false)
|
|
198
205
|
})
|
|
199
206
|
|
|
200
|
-
it('
|
|
201
|
-
const wrapper =
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
},
|
|
207
|
+
it('respects disabled and readonly props when opening the calendar', async () => {
|
|
208
|
+
const wrapper = mountComponent({
|
|
209
|
+
format: 'DD/MM/YYYY',
|
|
210
|
+
disabled: true,
|
|
205
211
|
})
|
|
212
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
206
213
|
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
214
|
+
expect(vm.isDatePickerVisible).toBe(false)
|
|
215
|
+
vm.openDatePicker()
|
|
216
|
+
await nextTick()
|
|
217
|
+
expect(vm.isDatePickerVisible).toBe(false)
|
|
218
|
+
|
|
219
|
+
await wrapper.setProps({ disabled: false, readonly: true })
|
|
220
|
+
vm.openDatePicker()
|
|
221
|
+
await nextTick()
|
|
222
|
+
expect(vm.isDatePickerVisible).toBe(false)
|
|
210
223
|
})
|
|
211
224
|
|
|
212
|
-
it('initializes selected dates
|
|
225
|
+
it('initializes selected dates from a valid modelValue', async () => {
|
|
213
226
|
const today = new Date()
|
|
214
227
|
const formattedDate = `${today.getDate().toString().padStart(2, '0')}/${(today.getMonth() + 1).toString().padStart(2, '0')}/${today.getFullYear()}`
|
|
215
|
-
const wrapper =
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
format: 'DD/MM/YYYY',
|
|
219
|
-
},
|
|
228
|
+
const wrapper = mountComponent({
|
|
229
|
+
modelValue: formattedDate,
|
|
230
|
+
format: 'DD/MM/YYYY',
|
|
220
231
|
})
|
|
232
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
221
233
|
|
|
222
234
|
await nextTick()
|
|
223
|
-
expect(
|
|
235
|
+
expect(vm.selectedDates).not.toBeNull()
|
|
224
236
|
})
|
|
225
237
|
|
|
226
|
-
it('supports date ranges when displayRange is true',
|
|
227
|
-
const wrapper =
|
|
228
|
-
|
|
229
|
-
displayRange: true,
|
|
230
|
-
},
|
|
238
|
+
it('supports date ranges when displayRange is true', () => {
|
|
239
|
+
const wrapper = mountComponent({
|
|
240
|
+
displayRange: true,
|
|
231
241
|
})
|
|
242
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
232
243
|
|
|
233
|
-
expect(
|
|
244
|
+
expect(vm.selectedDates).toBeNull()
|
|
234
245
|
const rangeInput = wrapper.find('input')
|
|
235
246
|
expect(rangeInput.exists()).toBe(true)
|
|
236
247
|
})
|
|
237
248
|
|
|
238
|
-
it('properly displays error messages from validation', async () => {
|
|
239
|
-
const wrapper = mount(DatePicker, {
|
|
240
|
-
props: {
|
|
241
|
-
required: true,
|
|
242
|
-
},
|
|
243
|
-
})
|
|
244
|
-
|
|
245
|
-
await wrapper.vm.validateOnSubmit()
|
|
246
|
-
await nextTick()
|
|
247
|
-
|
|
248
|
-
expect(wrapper.vm.errorMessages.length).toBeGreaterThan(0)
|
|
249
|
-
const errorMessage = wrapper.find('.v-messages__message')
|
|
250
|
-
expect(errorMessage.exists()).toBe(true)
|
|
251
|
-
expect(errorMessage.text()).toContain('requise')
|
|
252
|
-
})
|
|
253
|
-
|
|
254
249
|
it('handles birth date mode properly', async () => {
|
|
255
|
-
const wrapper =
|
|
256
|
-
|
|
257
|
-
isBirthDate: true,
|
|
258
|
-
},
|
|
250
|
+
const wrapper = mountComponent({
|
|
251
|
+
isBirthDate: true,
|
|
259
252
|
})
|
|
253
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
260
254
|
|
|
261
255
|
expect(wrapper.props('isBirthDate')).toBe(true)
|
|
262
256
|
|
|
263
|
-
|
|
257
|
+
vm.openDatePicker()
|
|
264
258
|
await nextTick()
|
|
265
|
-
expect(
|
|
266
|
-
})
|
|
259
|
+
expect(vm.isDatePickerVisible).toBe(true)
|
|
260
|
+
}, 20000)
|
|
267
261
|
|
|
268
|
-
it('
|
|
269
|
-
const wrapper =
|
|
270
|
-
|
|
271
|
-
disabled: true,
|
|
272
|
-
},
|
|
262
|
+
it('emits closed when handleClickOutside is called while open', () => {
|
|
263
|
+
const wrapper = mountComponent({
|
|
264
|
+
format: 'DD/MM/YYYY',
|
|
273
265
|
})
|
|
266
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
274
267
|
|
|
275
|
-
|
|
276
|
-
|
|
268
|
+
const outsideElement = document.createElement('div')
|
|
269
|
+
vm.isDatePickerVisible = true
|
|
270
|
+
vm.handleClickOutside({ target: outsideElement } as unknown as MouseEvent)
|
|
271
|
+
|
|
272
|
+
const closedEvents = wrapper.emitted('closed')
|
|
273
|
+
expect(closedEvents).toBeTruthy()
|
|
274
|
+
})
|
|
277
275
|
|
|
278
|
-
|
|
276
|
+
it('handleSelectToday selects today and keeps the component usable', async () => {
|
|
277
|
+
const wrapper = mountComponent()
|
|
278
|
+
const vm = wrapper.vm as DatePickerInstance
|
|
279
279
|
|
|
280
|
-
await
|
|
281
|
-
|
|
282
|
-
await nextTick()
|
|
280
|
+
await vm.handleSelectToday()
|
|
281
|
+
await flushPromises()
|
|
283
282
|
|
|
284
|
-
expect(
|
|
283
|
+
expect(vm.selectedDates).not.toBeNull()
|
|
284
|
+
expect(wrapper.exists()).toBe(true)
|
|
285
285
|
})
|
|
286
286
|
})
|
|
@@ -335,6 +335,9 @@ type Story = StoryObj<typeof meta>
|
|
|
335
335
|
|
|
336
336
|
export const Default: Story = {
|
|
337
337
|
parameters: {
|
|
338
|
+
a11y: {
|
|
339
|
+
disable: true,
|
|
340
|
+
},
|
|
338
341
|
sourceCode: [
|
|
339
342
|
{
|
|
340
343
|
name: 'Template',
|
|
@@ -404,6 +407,9 @@ export const Default: Story = {
|
|
|
404
407
|
|
|
405
408
|
export const Required: Story = {
|
|
406
409
|
parameters: {
|
|
410
|
+
a11y: {
|
|
411
|
+
disable: true,
|
|
412
|
+
},
|
|
407
413
|
sourceCode: [
|
|
408
414
|
{
|
|
409
415
|
name: 'Template',
|
|
@@ -485,6 +491,9 @@ export const Required: Story = {
|
|
|
485
491
|
|
|
486
492
|
export const DateRange: Story = {
|
|
487
493
|
parameters: {
|
|
494
|
+
a11y: {
|
|
495
|
+
disable: true,
|
|
496
|
+
},
|
|
488
497
|
sourceCode: [
|
|
489
498
|
{
|
|
490
499
|
name: 'Template',
|
|
@@ -553,6 +562,9 @@ export const DateRange: Story = {
|
|
|
553
562
|
|
|
554
563
|
export const BirthDate: Story = {
|
|
555
564
|
parameters: {
|
|
565
|
+
a11y: {
|
|
566
|
+
disable: true,
|
|
567
|
+
},
|
|
556
568
|
sourceCode: [
|
|
557
569
|
{
|
|
558
570
|
name: 'Template',
|
|
@@ -615,6 +627,9 @@ export const BirthDate: Story = {
|
|
|
615
627
|
|
|
616
628
|
export const WithValidation: Story = {
|
|
617
629
|
parameters: {
|
|
630
|
+
a11y: {
|
|
631
|
+
disable: true,
|
|
632
|
+
},
|
|
618
633
|
sourceCode: [
|
|
619
634
|
{
|
|
620
635
|
name: 'Template',
|
|
@@ -700,6 +715,9 @@ export const WithValidation: Story = {
|
|
|
700
715
|
|
|
701
716
|
export const DifferentFormats: Story = {
|
|
702
717
|
parameters: {
|
|
718
|
+
a11y: {
|
|
719
|
+
disable: true,
|
|
720
|
+
},
|
|
703
721
|
sourceCode: [
|
|
704
722
|
{
|
|
705
723
|
name: 'Template',
|
|
@@ -785,6 +803,9 @@ export const DifferentFormats: Story = {
|
|
|
785
803
|
|
|
786
804
|
export const WithDateFormatReturn: Story = {
|
|
787
805
|
parameters: {
|
|
806
|
+
a11y: {
|
|
807
|
+
disable: true,
|
|
808
|
+
},
|
|
788
809
|
sourceCode: [
|
|
789
810
|
{
|
|
790
811
|
name: 'Template',
|
|
@@ -843,6 +864,9 @@ export const WithDateFormatReturn: Story = {
|
|
|
843
864
|
|
|
844
865
|
export const DisablePickerInteraction: Story = {
|
|
845
866
|
parameters: {
|
|
867
|
+
a11y: {
|
|
868
|
+
disable: true,
|
|
869
|
+
},
|
|
846
870
|
sourceCode: [
|
|
847
871
|
{
|
|
848
872
|
name: 'Template',
|
|
@@ -900,6 +924,9 @@ export const DisablePickerInteraction: Story = {
|
|
|
900
924
|
|
|
901
925
|
export const AutoFormattingInput: Story = {
|
|
902
926
|
parameters: {
|
|
927
|
+
a11y: {
|
|
928
|
+
disable: true,
|
|
929
|
+
},
|
|
903
930
|
sourceCode: [
|
|
904
931
|
{
|
|
905
932
|
name: 'Template',
|
|
@@ -953,6 +980,9 @@ export const AutoFormattingInput: Story = {
|
|
|
953
980
|
|
|
954
981
|
export const CustomDateFormat: Story = {
|
|
955
982
|
parameters: {
|
|
983
|
+
a11y: {
|
|
984
|
+
disable: true,
|
|
985
|
+
},
|
|
956
986
|
sourceCode: [
|
|
957
987
|
{
|
|
958
988
|
name: 'Template',
|
|
@@ -1007,6 +1037,9 @@ export const CustomDateFormat: Story = {
|
|
|
1007
1037
|
|
|
1008
1038
|
export const ReadonlyMode: Story = {
|
|
1009
1039
|
parameters: {
|
|
1040
|
+
a11y: {
|
|
1041
|
+
disable: true,
|
|
1042
|
+
},
|
|
1010
1043
|
sourceCode: [
|
|
1011
1044
|
{
|
|
1012
1045
|
name: 'Template',
|
|
@@ -1073,6 +1106,9 @@ export const ReadonlyMode: Story = {
|
|
|
1073
1106
|
|
|
1074
1107
|
export const AppendIcon: Story = {
|
|
1075
1108
|
parameters: {
|
|
1109
|
+
a11y: {
|
|
1110
|
+
disable: true,
|
|
1111
|
+
},
|
|
1076
1112
|
sourceCode: [
|
|
1077
1113
|
{
|
|
1078
1114
|
name: 'Template',
|
|
@@ -1131,6 +1167,9 @@ export const AppendIcon: Story = {
|
|
|
1131
1167
|
|
|
1132
1168
|
export const WithCustomPeriod: Story = {
|
|
1133
1169
|
parameters: {
|
|
1170
|
+
a11y: {
|
|
1171
|
+
disable: true,
|
|
1172
|
+
},
|
|
1134
1173
|
sourceCode: [
|
|
1135
1174
|
{
|
|
1136
1175
|
name: 'Template',
|
|
@@ -1243,6 +1282,9 @@ export const WithCustomPeriod: Story = {
|
|
|
1243
1282
|
|
|
1244
1283
|
export const WithTextFieldActivator: Story = {
|
|
1245
1284
|
parameters: {
|
|
1285
|
+
a11y: {
|
|
1286
|
+
disable: true,
|
|
1287
|
+
},
|
|
1246
1288
|
sourceCode: [
|
|
1247
1289
|
{
|
|
1248
1290
|
name: 'Template',
|
|
@@ -1299,6 +1341,9 @@ export const WithTextFieldActivator: Story = {
|
|
|
1299
1341
|
|
|
1300
1342
|
export const AutoClampFeature: Story = {
|
|
1301
1343
|
parameters: {
|
|
1344
|
+
a11y: {
|
|
1345
|
+
disable: true,
|
|
1346
|
+
},
|
|
1302
1347
|
sourceCode: [
|
|
1303
1348
|
{
|
|
1304
1349
|
name: 'Template',
|
|
@@ -1403,6 +1448,9 @@ export const AutoClampFeature: Story = {
|
|
|
1403
1448
|
|
|
1404
1449
|
export const WithFormSubmission: Story = {
|
|
1405
1450
|
parameters: {
|
|
1451
|
+
a11y: {
|
|
1452
|
+
disable: true,
|
|
1453
|
+
},
|
|
1406
1454
|
sourceCode: [
|
|
1407
1455
|
{
|
|
1408
1456
|
name: 'Template',
|
|
@@ -1495,6 +1543,9 @@ export const WithFormSubmission: Story = {
|
|
|
1495
1543
|
|
|
1496
1544
|
export const CustomRules: Story = {
|
|
1497
1545
|
parameters: {
|
|
1546
|
+
a11y: {
|
|
1547
|
+
disable: true,
|
|
1548
|
+
},
|
|
1498
1549
|
sourceCode: [
|
|
1499
1550
|
{
|
|
1500
1551
|
name: 'Template',
|
|
@@ -1570,6 +1621,9 @@ export const CustomRules: Story = {
|
|
|
1570
1621
|
|
|
1571
1622
|
export const CustomWarningRules: Story = {
|
|
1572
1623
|
parameters: {
|
|
1624
|
+
a11y: {
|
|
1625
|
+
disable: true,
|
|
1626
|
+
},
|
|
1573
1627
|
sourceCode: [
|
|
1574
1628
|
{
|
|
1575
1629
|
name: 'Template',
|