@cnamts/synapse 1.0.1 → 1.0.3
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/README.md +1 -1
- package/dist/{DateFilter-BmRuzQ9Z.js → DateFilter-DFKfon7L.js} +1 -1
- package/dist/{NumberFilter-CnIPDHqx.js → NumberFilter-DmhIL2Pr.js} +1 -1
- package/dist/{PeriodFilter-CZwZ8CnQ.js → PeriodFilter-C46V6bYN.js} +1 -1
- package/dist/SelectFilter-B8dtHtHo.js +136 -0
- package/dist/{TextFilter-DTxZHJwX.js → TextFilter-COKGday2.js} +1 -1
- package/dist/assets/amelipro/icons.d.ts +5 -0
- package/dist/components/Accordion/Accordion.d.ts +2 -1
- package/dist/components/Accordion/composables/useAccordionGroupCommunication.d.ts +5 -0
- package/dist/components/Accordion/composables/useAccordionKeyboardNavigation.d.ts +12 -0
- package/dist/components/Accordion/composables/useAccordionState.d.ts +13 -0
- package/dist/components/Amelipro/AmeliproAutoCompleteField/AmeliproAutoCompleteField.d.ts +6554 -0
- package/dist/components/Amelipro/AmeliproAutoCompleteField/types.d.ts +12 -0
- package/dist/components/Amelipro/AmeliproBreadcrumb/AmeliproBreadcrumb.d.ts +28 -0
- package/dist/components/Amelipro/AmeliproBreadcrumb/types.d.ts +7 -0
- package/dist/components/Amelipro/AmeliproBtn/AmeliproBtn.d.ts +258 -0
- package/dist/components/Amelipro/AmeliproCallback/AmeliproCallback.d.ts +128 -0
- package/dist/components/Amelipro/AmeliproCard/AmeliproCard.d.ts +151 -0
- package/dist/components/Amelipro/AmeliproCheckbox/AmeliproCheckbox.d.ts +98 -0
- package/dist/components/Amelipro/AmeliproCheckbox/types.d.ts +5 -0
- package/dist/components/Amelipro/AmeliproCheckboxGroup/AmeliproCheckboxGroup.d.ts +149 -0
- package/dist/components/Amelipro/AmeliproCheckboxGroup/types.d.ts +7 -0
- package/dist/components/Amelipro/AmeliproChips/AmeliproChips.d.ts +24 -0
- package/dist/components/Amelipro/AmeliproDialog/AmeliproDialog.d.ts +164 -0
- package/dist/components/Amelipro/AmeliproDisclosure/AmeliproDisclosure.d.ts +37 -0
- package/dist/components/Amelipro/AmeliproFooter/A11yComplianceEnum.d.ts +6 -0
- package/dist/components/Amelipro/AmeliproFooter/AmeliproFooter.d.ts +313 -0
- package/dist/components/Amelipro/AmeliproFooter/locales.d.ts +13 -0
- package/dist/components/Amelipro/AmeliproFooter/types.d.ts +33 -0
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeader.d.ts +191 -0
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBar.d.ts +77 -0
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBrandSection/AmeliproHeaderBrandSection.d.ts +76 -0
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBrandSection/dividerDimensionsMapping.d.ts +2 -0
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBrandSection/locales.d.ts +5 -0
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBrandSection/types.d.ts +4 -0
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproLogoAm/AmeliproLogoAm.d.ts +35 -0
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproLogoAm/LogoSizeEnum.d.ts +5 -0
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproLogoAm/locales.d.ts +5 -0
- package/dist/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproLogoAm/logoDimensionsMapping.d.ts +2 -0
- package/dist/components/Amelipro/AmeliproHeader/types.d.ts +24 -0
- package/dist/components/Amelipro/AmeliproIcon/AmeliproIcon.d.ts +137 -0
- package/dist/components/Amelipro/AmeliproIcon/iconList.d.ts +5 -0
- package/dist/components/Amelipro/AmeliproIconBtn/AmeliproIconBtn.d.ts +449 -0
- package/dist/components/Amelipro/AmeliproIllustratedDataTile/AmeliproIllustratedDataTile.d.ts +104 -0
- package/dist/components/Amelipro/AmeliproIllustratedDataTile/types.d.ts +4 -0
- package/dist/components/Amelipro/AmeliproIllustratedRadioGroup/AmeliproIllustratedRadioGroup.d.ts +80 -0
- package/dist/components/Amelipro/AmeliproIllustratedRadioGroup/locales.d.ts +3 -0
- package/dist/components/Amelipro/AmeliproIllustratedRadioGroup/types.d.ts +8 -0
- package/dist/components/Amelipro/AmeliproMailTile/AmeliproMailTile.d.ts +38 -0
- package/dist/components/Amelipro/AmeliproMailTile/types.d.ts +13 -0
- package/dist/components/Amelipro/AmeliproMenu/AmeliproMenu.d.ts +57 -0
- package/dist/components/Amelipro/AmeliproMenu/types.d.ts +9 -0
- package/dist/components/Amelipro/AmeliproMessage/AmeliproMessage.d.ts +172 -0
- package/dist/components/Amelipro/AmeliproMessage/AmeliproMessageTypes.d.ts +2 -0
- package/dist/components/Amelipro/AmeliproMessage/types.d.ts +7 -0
- package/dist/components/Amelipro/AmeliproMessagingLayout/AmeliproDropdownMenu/types.d.ts +7 -0
- package/dist/components/Amelipro/AmeliproMessagingLayout/types.d.ts +9 -0
- package/dist/components/Amelipro/AmeliproMultipleFoldingCard/AmeliproMultipleFoldingCard.d.ts +123 -0
- package/dist/components/Amelipro/AmeliproMultipleFoldingCard/types.d.ts +6 -0
- package/dist/components/Amelipro/AmeliproNumberedCard/AmeliproNumberedCard.d.ts +79 -0
- package/dist/components/Amelipro/AmeliproNumberedCard/types.d.ts +4 -0
- package/dist/components/Amelipro/AmeliproOnboarding/AmeliproOnboarding.d.ts +125 -0
- package/dist/components/Amelipro/AmeliproOnboarding/types.d.ts +5 -0
- package/dist/components/Amelipro/AmeliproPageLayout/AmeliproPageLayout.d.ts +63 -0
- package/dist/components/Amelipro/AmeliproPageLayout/locales.d.ts +3 -0
- package/dist/components/Amelipro/AmeliproPageLayout/types.d.ts +14 -0
- package/dist/components/Amelipro/AmeliproPagination/AmeliproPagination.d.ts +37 -0
- package/dist/components/Amelipro/AmeliproPagination/AmeliproPaginationBtn/AmeliproPaginationBtn.d.ts +63 -0
- package/dist/components/Amelipro/AmeliproPagination/types.d.ts +5 -0
- package/dist/components/Amelipro/AmeliproPatientBanner/AmeliproPatientBanner.d.ts +127 -0
- package/dist/components/Amelipro/AmeliproPatientBanner/locales.d.ts +6 -0
- package/dist/components/Amelipro/AmeliproPatientBanner/types.d.ts +15 -0
- package/dist/components/Amelipro/AmeliproRadioGroup/AmeliproRadioGroup.d.ts +139 -0
- package/dist/components/Amelipro/AmeliproRadioGroup/locales.d.ts +3 -0
- package/dist/components/Amelipro/AmeliproRadioGroup/types.d.ts +6 -0
- package/dist/components/Amelipro/AmeliproSelect/AmeliproSelect.d.ts +6513 -0
- package/dist/components/Amelipro/AmeliproSelect/types.d.ts +10 -0
- package/dist/components/Amelipro/AmeliproStateTile/AmeliproStateTile.d.ts +138 -0
- package/dist/components/Amelipro/AmeliproStateTile/AmeliproStateTileTypes.d.ts +2 -0
- package/dist/components/Amelipro/AmeliproStateTile/types.d.ts +11 -0
- package/dist/components/Amelipro/AmeliproStatus/AmeliproStatus.d.ts +62 -0
- package/dist/components/Amelipro/AmeliproStatus/AmeliproStatusTypes.d.ts +2 -0
- package/dist/components/Amelipro/AmeliproStatus/types.d.ts +5 -0
- package/dist/components/Amelipro/AmeliproStepper/AmeliproStepBtn/AmeliproStepBtn.d.ts +43 -0
- package/dist/components/Amelipro/AmeliproStepper/AmeliproStepper.d.ts +213 -0
- package/dist/components/Amelipro/AmeliproStepper/types.d.ts +5 -0
- package/dist/components/Amelipro/AmeliproTabs/AmeliproTabBtn/AmeliproTabBtn.d.ts +76 -0
- package/dist/components/Amelipro/AmeliproTabs/AmeliproTabs.d.ts +6839 -0
- package/dist/components/Amelipro/AmeliproTabs/types.d.ts +10 -0
- package/dist/components/Amelipro/AmeliproTextArea/AmeliproTextArea.d.ts +1063 -0
- package/dist/components/Amelipro/AmeliproTextArea/types.d.ts +4 -0
- package/dist/components/Amelipro/AmeliproTextField/AmeliproTextField.d.ts +1681 -0
- package/dist/components/Amelipro/AmeliproTextField/types.d.ts +4 -0
- package/dist/components/Amelipro/AmeliproTileBtn/AmeliproTileBtn.d.ts +199 -0
- package/dist/components/Amelipro/AmeliproTooltips/AmeliproTooltips.d.ts +115 -0
- package/dist/components/Amelipro/AmeliproTransmission/AmeliproTransmission.d.ts +121 -0
- package/dist/components/Amelipro/ServiceMenu/ServiceBtn/ServiceBtn.d.ts +44 -0
- package/dist/components/Amelipro/ServiceMenu/ServiceBtn/types.d.ts +8 -0
- package/dist/components/Amelipro/ServiceMenu/ServiceList/ServiceList.d.ts +41 -0
- package/dist/components/Amelipro/ServiceMenu/ServiceMenu.d.ts +84 -0
- package/dist/components/Amelipro/ServiceMenu/ServiceMenuContent/ServiceMenuContent.d.ts +57 -0
- package/dist/components/Amelipro/ServiceMenu/types.d.ts +12 -0
- package/dist/components/Amelipro/StructureMenu/StructureBtn/StructureBtn.d.ts +49 -0
- package/dist/components/Amelipro/StructureMenu/StructureItem/StructureItem.d.ts +53 -0
- package/dist/components/Amelipro/StructureMenu/StructureItem/locales.d.ts +4 -0
- package/dist/components/Amelipro/StructureMenu/StructureItem/types.d.ts +6 -0
- package/dist/components/Amelipro/StructureMenu/StructureList/StructureList.d.ts +62 -0
- package/dist/components/Amelipro/StructureMenu/StructureList/locales.d.ts +4 -0
- package/dist/components/Amelipro/StructureMenu/StructureMenu.d.ts +105 -0
- package/dist/components/Amelipro/StructureMenu/StructureTabs/StructureTabs.d.ts +176 -0
- package/dist/components/Amelipro/StructureMenu/StructureTabs/locales.d.ts +4 -0
- package/dist/components/Amelipro/StructureMenu/StructureTabs/types.d.ts +11 -0
- package/dist/components/Amelipro/StructureMenu/locales.d.ts +10 -0
- package/dist/components/Amelipro/StructureMenu/types.d.ts +34 -0
- package/dist/components/Amelipro/UserInformationSummary/UserInformationSummary.d.ts +25 -0
- package/dist/components/Amelipro/UserInformationSummary/types.d.ts +9 -0
- package/dist/components/Amelipro/UserMenu/UserMenu.d.ts +57 -0
- package/dist/components/Amelipro/UserMenu/UserMenuDetails/UserMenuDetails.d.ts +25 -0
- package/dist/components/Amelipro/UserMenu/UserMenuDetails/types.d.ts +20 -0
- package/dist/components/Amelipro/UserMenu/types.d.ts +8 -0
- package/dist/components/Amelipro/types.d.ts +4 -0
- package/dist/components/BackToTopBtn/BackToTopBtn.d.ts +1 -1
- package/dist/components/ChipList/ChipList.d.ts +1 -1
- package/dist/components/ContextualMenu/ContextualMenu.d.ts +2 -1
- package/dist/components/ContextualMenu/DeepMenu.d.ts +12 -0
- package/dist/components/ContextualMenu/types.d.ts +7 -0
- package/dist/components/CookieBanner/CookieBanner.d.ts +1 -1
- package/dist/components/CookiesSelection/CookiesSelection.d.ts +8 -4
- package/dist/components/{SelectBtnField → Customs/Selects/SelectBtnField}/AccessibiliteItems.d.ts +1 -1
- package/dist/components/{SelectBtnField → Customs/Selects/SelectBtnField}/SelectBtnField.d.ts +5 -5
- package/dist/components/Customs/{SyBtnSelect → Selects/SyBtnSelect}/AccessibiliteItems.d.ts +1 -1
- package/dist/components/Customs/{SyBtnSelect → Selects/SyBtnSelect}/SyBtnSelect.d.ts +5 -5
- package/dist/components/Customs/{SyInputSelect → Selects/SyInputSelect}/AccessibiliteItems.d.ts +1 -1
- package/dist/components/Customs/{SyInputSelect → Selects/SyInputSelect}/SyInputSelect.d.ts +10 -8
- package/dist/components/Customs/{SySelect → Selects/SySelect}/AccessibiliteItems.d.ts +1 -1
- package/dist/components/Customs/{SySelect → Selects/SySelect}/SySelect.d.ts +138 -98
- package/dist/components/Customs/Selects/SySelect/composables/useSySelectKeyboard.d.ts +29 -0
- package/dist/components/Customs/SyCheckbox/SyCheckbox.d.ts +91 -0
- package/dist/components/Customs/SyCheckbox/locales.d.ts +3 -0
- package/dist/components/Customs/SyIcon/SyIcon.d.ts +11 -0
- package/dist/components/Customs/SyIcon/utils/iconUtils.d.ts +24 -0
- package/dist/components/Customs/SyPagination/SyPagination.d.ts +49 -0
- package/dist/components/Customs/SyTextField/SyTextField.d.ts +120 -100
- package/dist/components/DataList/DataList.d.ts +2 -2
- package/dist/components/DataList/DataListLoading/DataListLoading.d.ts +1 -1
- package/dist/components/DataListItem/DataListItem.d.ts +2 -2
- package/dist/components/DatePicker/ComplexDatePicker/ComplexDatePicker.d.ts +1925 -1667
- package/dist/components/DatePicker/DatePicker/DatePicker.d.ts +428 -289
- package/dist/components/DatePicker/DateTextInput/DateTextInput.d.ts +157 -135
- package/dist/components/DatePicker/composables/index.d.ts +2 -0
- package/dist/components/DatePicker/composables/useAsteriskDisplay.d.ts +14 -0
- package/dist/components/DatePicker/composables/useDateAutoClamp.d.ts +16 -0
- package/dist/components/DatePicker/composables/useDateRangeInput.d.ts +1 -1
- package/dist/components/DatePicker/composables/useDisplayedDateString.d.ts +3 -0
- package/dist/components/DatePicker/composables/useIconState.d.ts +2 -2
- package/dist/components/DatePicker/composables/useInputBlurHandler.d.ts +1 -0
- package/dist/components/DatePicker/composables/useMonthButtonCustomization.d.ts +5 -2
- package/dist/components/DialogBox/DialogBox.d.ts +24 -16
- package/dist/components/DownloadBtn/DownloadBtn.d.ts +1 -1
- package/dist/components/ErrorPage/ErrorPage.d.ts +1 -1
- package/dist/components/ExternalLinks/ExternalLinks.d.ts +3 -3
- package/dist/components/FileList/FileList.d.ts +1 -1
- package/dist/components/FileList/UploadItem/UploadItem.d.ts +1 -1
- package/dist/components/FilePreview/FilePreview.d.ts +4 -4
- package/dist/components/FileUpload/FileUpload.d.ts +1 -1
- package/dist/components/FilterInline/FilterInline.d.ts +1 -1
- package/dist/components/FilterSideBar/FilterSideBar.d.ts +31 -19
- package/dist/components/FooterBar/FooterBar.d.ts +2 -2
- package/dist/components/LangBtn/LangBtn.d.ts +47 -27
- package/dist/components/Logo/Logo.d.ts +6 -6
- package/dist/components/Logo/LogoSize.d.ts +1 -1
- package/dist/components/NirField/NirField.d.ts +321 -277
- package/dist/components/NirField/nirValidation.d.ts +1 -1
- package/dist/components/NotificationBar/NotificationBar.d.ts +1 -1
- package/dist/components/PageContainer/PageContainer.d.ts +1 -1
- package/dist/components/PaginatedTable/PaginatedTable.d.ts +19 -1
- package/dist/components/PasswordField/PasswordField.d.ts +10 -8
- package/dist/components/PeriodField/PeriodField.d.ts +900 -606
- package/dist/components/PhoneField/PhoneField.d.ts +7 -7
- package/dist/components/RangeField/RangeField.d.ts +4 -2
- package/dist/components/RangeField/RangeSlider/RangeSlider.d.ts +2 -2
- package/dist/components/RatingPicker/EmotionPicker/EmotionPicker.d.ts +1 -1
- package/dist/components/RatingPicker/NumberPicker/NumberPicker.d.ts +1 -1
- package/dist/components/RatingPicker/RatingPicker.d.ts +1 -1
- package/dist/components/RatingPicker/StarsPicker/StarsPicker.d.ts +1 -1
- package/dist/components/SearchListField/SearchListField.d.ts +423 -2
- package/dist/components/SocialMediaLinks/SocialMediaLinks.d.ts +20 -0
- package/dist/components/SyAlert/SyAlert.d.ts +6 -2
- package/dist/components/SyTextArea/SyTextArea.d.ts +63 -50
- package/dist/components/TableToolbar/TableToolbar.d.ts +1 -1
- package/dist/components/Tables/SyServerTable/SyServerTable.d.ts +32 -36
- package/dist/components/Tables/SyTable/SyTable.d.ts +30 -34
- package/dist/components/Tables/common/SyTableFilter.d.ts +2 -2
- package/dist/components/Tables/common/SyTablePagination.d.ts +1656 -0
- package/dist/components/Tables/common/TableHeader.d.ts +2 -20
- package/dist/components/Tables/common/filters/DateFilter.d.ts +2 -2
- package/dist/components/Tables/common/filters/NumberFilter.d.ts +2 -2
- package/dist/components/Tables/common/filters/PeriodFilter.d.ts +2 -2
- package/dist/components/Tables/common/filters/SelectFilter.d.ts +7 -7
- package/dist/components/Tables/common/filters/TextFilter.d.ts +2 -2
- package/dist/components/Tables/common/filters/getFilterComponent.d.ts +1 -0
- package/dist/components/Tables/common/filters/locales.d.ts +4 -0
- package/dist/components/Tables/common/filters/logics/date.d.ts +1 -0
- package/dist/components/Tables/common/filters/logics/number.d.ts +1 -0
- package/dist/components/Tables/common/filters/logics/period.d.ts +1 -0
- package/dist/components/Tables/common/filters/logics/select.d.ts +1 -0
- package/dist/components/Tables/common/filters/logics/text.d.ts +1 -0
- package/dist/components/Tables/common/locales.d.ts +21 -0
- package/dist/components/Tables/common/organizeColumns/OrganizeColumns.d.ts +279 -0
- package/dist/components/Tables/common/organizeColumns/sortHeaders.d.ts +2 -0
- package/dist/components/Tables/common/tableFilterUtils.d.ts +1 -0
- package/dist/components/Tables/common/tableStorageUtils.d.ts +41 -1
- package/dist/components/Tables/common/tableUtils.d.ts +42 -5
- package/dist/components/Tables/common/types.d.ts +23 -8
- package/dist/components/Tables/common/usePagination.d.ts +22 -0
- package/dist/components/Tables/common/useTableCheckbox.d.ts +20 -0
- package/dist/components/Tables/common/useTableHeaders.d.ts +76 -0
- package/dist/components/Tables/common/useTableItems.d.ts +24 -0
- package/dist/components/Tables/common/useTableOptions.d.ts +18 -0
- package/dist/components/ToolbarContainer/ToolbarContainer.d.ts +11 -0
- package/dist/components/UploadWorkflow/UploadWorkflow.d.ts +12 -8
- package/dist/components/UserMenuBtn/UserMenuBtn.d.ts +9 -2
- package/dist/components/index.d.ts +103 -58
- package/dist/composables/date/useDatePickerAccessibility.d.ts +1 -0
- package/dist/composables/useError.d.ts +4 -0
- package/dist/design-system-v3.js +160 -98
- package/dist/design-system-v3.umd.cjs +1014 -22
- package/dist/designTokens/index.d.ts +6 -1
- package/dist/designTokens/tokens/amelipro/apColors.d.ts +73 -0
- package/dist/designTokens/tokens/amelipro/apContextual.d.ts +58 -0
- package/dist/designTokens/tokens/amelipro/apDarkTheme.d.ts +1 -0
- package/dist/designTokens/tokens/amelipro/apLightTheme.d.ts +8 -0
- package/dist/designTokens/tokens/amelipro/apSemantic.d.ts +87 -0
- package/dist/directives/rgaaSvgFix.d.ts +5 -0
- package/dist/main-DoYCrS2Q.js +26573 -0
- package/dist/main.d.ts +1 -0
- package/dist/services/NotificationService.d.ts +2 -2
- package/dist/stories/Accessibilite/Vuetify/VuetifyItems.d.ts +14 -2
- package/dist/stories/DesignTokens/StylesTypographiques.stories.new.d.ts +8 -0
- package/dist/stories/DesignTokens/TypographyDisplay.d.ts +28 -0
- package/dist/stories/DesignTokens/vue-shims.d.ts +6 -0
- package/dist/style.css +1 -1
- package/dist/utils/amelipro/dateHelper/dateHelper.d.ts +48 -0
- package/dist/utils/amelipro/numberHelper/numberHelper.d.ts +8 -0
- package/dist/utils/amelipro/rules/maxNumber/index.d.ts +3 -0
- package/dist/utils/amelipro/rules/minNumber/index.d.ts +3 -0
- package/dist/utils/amelipro/rules/notAfterDate/index.d.ts +3 -0
- package/dist/utils/amelipro/rules/notBeforeDate/index.d.ts +3 -0
- package/dist/utils/functions/ameliproColors/ameliproColors.d.ts +2 -0
- package/dist/utils/functions/ameliproColors/types.d.ts +5 -0
- package/dist/utils/functions/classToHex.d.ts +1 -0
- package/dist/utils/functions/convertToHex.d.ts +1 -0
- package/dist/utils/functions/isCssColor.d.ts +1 -0
- package/dist/utils/index.d.ts +19 -0
- package/dist/vuetifyConfig.d.ts +4 -3
- package/package.json +1 -1
- package/src/assets/_elevations.scss +30 -0
- package/src/assets/_radius.scss +17 -0
- package/src/assets/_spacers.scss +61 -4
- package/src/assets/amelipro/apTokens.scss +315 -0
- package/src/assets/amelipro/icons/btn_structures.svg +19 -0
- package/src/assets/amelipro/icons/ga.svg +23 -0
- package/src/assets/amelipro/icons/icone_dsg.svg +29 -0
- package/src/assets/amelipro/icons/icone_hr.svg +30 -0
- package/src/assets/amelipro/icons/icone_infosPatient_actif.svg +30 -0
- package/src/assets/amelipro/icons/icone_mes_commandes.svg +31 -0
- package/src/assets/amelipro/icons/icone_pse.svg +34 -0
- package/src/assets/amelipro/icons/info.svg +16 -0
- package/src/assets/amelipro/icons/releve_activites_fb.svg +22 -0
- package/src/assets/amelipro/icons/retourHaut_fb.svg +11 -0
- package/src/assets/amelipro/icons/shc.svg +19 -0
- package/src/assets/amelipro/icons.ts +1141 -0
- package/src/assets/amelipro/img/amelipro.svg +1 -0
- package/src/assets/amelipro/img/cartouche_nouveauTEL.svg +47 -0
- package/src/assets/amelipro/img/logo-menu.svg +52 -0
- package/src/assets/settings.scss +6 -0
- package/src/common/imgs/accessibility-svgrepo-com.svg +4 -0
- package/src/components/Accordion/Accessibilite/AccessibilityGuide.mdx +249 -0
- package/src/components/Accordion/Accordion.vue +48 -76
- package/src/components/Accordion/composables/__tests__/useAccordionGroupCommunication.spec.ts +146 -0
- package/src/components/Accordion/composables/__tests__/useAccordionKeyboardNavigation.spec.ts +209 -0
- package/src/components/Accordion/composables/__tests__/useAccordionState.spec.ts +144 -0
- package/src/components/Accordion/composables/useAccordionGroupCommunication.ts +52 -0
- package/src/components/Accordion/composables/useAccordionKeyboardNavigation.ts +111 -0
- package/src/components/Accordion/composables/useAccordionState.ts +59 -0
- package/src/components/Accordion/tests/__snapshots__/accordion.spec.ts.snap +3 -0
- package/src/components/Amelipro/AmeliproAutoCompleteField/AmeliproAutoCompleteField.mdx +15 -0
- package/src/components/Amelipro/AmeliproAutoCompleteField/AmeliproAutoCompleteField.stories.ts +170 -0
- package/src/components/Amelipro/AmeliproAutoCompleteField/AmeliproAutoCompleteField.vue +393 -0
- package/src/components/Amelipro/AmeliproAutoCompleteField/__tests__/AmeliproAutoCompleteField.spec.ts +62 -0
- package/src/components/Amelipro/AmeliproAutoCompleteField/__tests__/__snapshots__/AmeliproAutoCompleteField.spec.ts.snap +245 -0
- package/src/components/Amelipro/AmeliproAutoCompleteField/types.d.ts +12 -0
- package/src/components/Amelipro/AmeliproBreadcrumb/AmeliproBreadcrumb.mdx +15 -0
- package/src/components/Amelipro/AmeliproBreadcrumb/AmeliproBreadcrumb.stories.ts +92 -0
- package/src/components/Amelipro/AmeliproBreadcrumb/AmeliproBreadcrumb.vue +89 -0
- package/src/components/Amelipro/AmeliproBreadcrumb/__tests__/AmeliproBreadcrumb.spec.ts +37 -0
- package/src/components/Amelipro/AmeliproBreadcrumb/__tests__/__snapshots__/AmeliproBreadcrumb.spec.ts.snap +192 -0
- package/src/components/Amelipro/AmeliproBreadcrumb/types.d.ts +8 -0
- package/src/components/Amelipro/AmeliproBtn/AmeliproBtn.mdx +24 -0
- package/src/components/Amelipro/AmeliproBtn/AmeliproBtn.stories.ts +182 -0
- package/src/components/Amelipro/AmeliproBtn/AmeliproBtn.vue +382 -0
- package/src/components/Amelipro/AmeliproBtn/tests/AmeliproBtn.spec.ts +22 -0
- package/src/components/Amelipro/AmeliproBtn/tests/__snapshots__/AmeliproBtn.spec.ts.snap +42 -0
- package/src/components/Amelipro/AmeliproCallback/AmeliproCallback.mdx +21 -0
- package/src/components/Amelipro/AmeliproCallback/AmeliproCallback.stories.ts +69 -0
- package/src/components/Amelipro/AmeliproCallback/AmeliproCallback.vue +170 -0
- package/src/components/Amelipro/AmeliproCallback/tests/AmeliproCallback.spec.ts +21 -0
- package/src/components/Amelipro/AmeliproCallback/tests/__snapshots__/AmeliproCallback.spec.ts.snap +154 -0
- package/src/components/Amelipro/AmeliproCard/AmeliproCard.mdx +15 -0
- package/src/components/Amelipro/AmeliproCard/AmeliproCard.stories.ts +95 -0
- package/src/components/Amelipro/AmeliproCard/AmeliproCard.vue +312 -0
- package/src/components/Amelipro/AmeliproCard/tests/AmeliproCard.spec.ts +23 -0
- package/src/components/Amelipro/AmeliproCard/tests/__snapshots__/AmeliproCard.spec.ts.snap +71 -0
- package/src/components/Amelipro/AmeliproCheckbox/AmeliproCheckbox.mdx +15 -0
- package/src/components/Amelipro/AmeliproCheckbox/AmeliproCheckbox.stories.ts +104 -0
- package/src/components/Amelipro/AmeliproCheckbox/AmeliproCheckbox.vue +276 -0
- package/src/components/Amelipro/AmeliproCheckbox/tests/AmeliproCheckbox.spec.ts +23 -0
- package/src/components/Amelipro/AmeliproCheckbox/tests/__snapshots__/AmeliproCheckbox.spec.ts.snap +40 -0
- package/src/components/Amelipro/AmeliproCheckbox/types.d.ts +5 -0
- package/src/components/Amelipro/AmeliproCheckboxGroup/AmeliproCheckboxGroup.mdx +15 -0
- package/src/components/Amelipro/AmeliproCheckboxGroup/AmeliproCheckboxGroup.stories.ts +176 -0
- package/src/components/Amelipro/AmeliproCheckboxGroup/AmeliproCheckboxGroup.vue +396 -0
- package/src/components/Amelipro/AmeliproCheckboxGroup/tests/AmeliproCheckboxGroup.spec.ts +50 -0
- package/src/components/Amelipro/AmeliproCheckboxGroup/tests/__snapshots__/AmeliproCheckboxGroup.spec.ts.snap +249 -0
- package/src/components/Amelipro/AmeliproCheckboxGroup/types.d.ts +7 -0
- package/src/components/Amelipro/AmeliproChips/AmeliproChips.mdx +15 -0
- package/src/components/Amelipro/AmeliproChips/AmeliproChips.stories.ts +54 -0
- package/src/components/Amelipro/AmeliproChips/AmeliproChips.vue +51 -0
- package/src/components/Amelipro/AmeliproChips/tests/AmeliproChips.spec.ts +20 -0
- package/src/components/Amelipro/AmeliproChips/tests/__snapshots__/AmeliproChips.spec.ts.snap +94 -0
- package/src/components/Amelipro/AmeliproDialog/AmeliproDialog.mdx +30 -0
- package/src/components/Amelipro/AmeliproDialog/AmeliproDialog.stories.ts +130 -0
- package/src/components/Amelipro/AmeliproDialog/AmeliproDialog.vue +326 -0
- package/src/components/Amelipro/AmeliproDialog/tests/AmeliproDialog.spec.ts +26 -0
- package/src/components/Amelipro/AmeliproDialog/tests/__snapshots__/AmeliproDialog.spec.ts.snap +126 -0
- package/src/components/Amelipro/AmeliproDisclosure/AmeliproDisclosure.mdx +15 -0
- package/src/components/Amelipro/AmeliproDisclosure/AmeliproDisclosure.stories.ts +58 -0
- package/src/components/Amelipro/AmeliproDisclosure/AmeliproDisclosure.vue +78 -0
- package/src/components/Amelipro/AmeliproDisclosure/tests/AmeliproDisclosure.spec.ts +23 -0
- package/src/components/Amelipro/AmeliproDisclosure/tests/__snapshots__/AmeliproDisclosure.spec.ts.snap +88 -0
- package/src/components/Amelipro/AmeliproFooter/A11yComplianceEnum.ts +7 -0
- package/src/components/Amelipro/AmeliproFooter/AmeliproFooter.mdx +15 -0
- package/src/components/Amelipro/AmeliproFooter/AmeliproFooter.stories.ts +105 -0
- package/src/components/Amelipro/AmeliproFooter/AmeliproFooter.vue +415 -0
- package/src/components/Amelipro/AmeliproFooter/locales.ts +16 -0
- package/src/components/Amelipro/AmeliproFooter/tests/AmeliproFooter.spec.ts +19 -0
- package/src/components/Amelipro/AmeliproFooter/tests/__snapshots__/AmeliproFooter.spec.ts.snap +404 -0
- package/src/components/Amelipro/AmeliproFooter/types.d.ts +34 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeader.mdx +15 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeader.stories.ts +746 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeader.vue +487 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBar.vue +131 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBrandSection/AmeliproHeaderBrandSection.vue +239 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBrandSection/dividerDimensionsMapping.ts +16 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBrandSection/locales.ts +7 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBrandSection/tests/AmeliproHeaderBrandSection.spec.ts +19 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBrandSection/tests/__snapshots__/AmeliproHeaderBrandSection.spec.ts.snap +132 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproHeaderBrandSection/types.d.ts +4 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproLogoAm/AmeliproLogoAm.vue +133 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproLogoAm/LogoSizeEnum.ts +5 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproLogoAm/locales.ts +5 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproLogoAm/logoDimensionsMapping.ts +17 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproLogoAm/tests/AmeliproLogoAm.spec.ts +19 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/AmeliproLogoAm/tests/__snapshots__/AmeliproLogoAm.spec.ts.snap +92 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/tests/AmeliproHeaderBar.spec.ts +19 -0
- package/src/components/Amelipro/AmeliproHeader/AmeliproHeaderBar/tests/__snapshots__/AmeliproHeaderBar.spec.ts.snap +170 -0
- package/src/components/Amelipro/AmeliproHeader/tests/AmeliproHeader.spec.ts +163 -0
- package/src/components/Amelipro/AmeliproHeader/tests/__snapshots__/AmeliproHeader.spec.ts.snap +1448 -0
- package/src/components/Amelipro/AmeliproHeader/types.d.ts +25 -0
- package/src/components/Amelipro/AmeliproIcon/AmeliproIcon.mdx +17 -0
- package/src/components/Amelipro/AmeliproIcon/AmeliproIcon.stories.ts +101 -0
- package/src/components/Amelipro/AmeliproIcon/AmeliproIcon.vue +248 -0
- package/src/components/Amelipro/AmeliproIcon/iconList.ts +230 -0
- package/src/components/Amelipro/AmeliproIcon/tests/AmeliproIcon.spec.ts +23 -0
- package/src/components/Amelipro/AmeliproIcon/tests/__snapshots__/AmeliproIcon.spec.ts.snap +46 -0
- package/src/components/Amelipro/AmeliproIconBtn/AmeliproIconBtn.mdx +17 -0
- package/src/components/Amelipro/AmeliproIconBtn/AmeliproIconBtn.stories.ts +81 -0
- package/src/components/Amelipro/AmeliproIconBtn/AmeliproIconBtn.vue +318 -0
- package/src/components/Amelipro/AmeliproIconBtn/tests/AmeliproIconBtn.spec.ts +26 -0
- package/src/components/Amelipro/AmeliproIconBtn/tests/__snapshots__/AmeliproIconBtn.spec.ts.snap +84 -0
- package/src/components/Amelipro/AmeliproIllustratedDataTile/AmeliproIllustratedDataTile.mdx +15 -0
- package/src/components/Amelipro/AmeliproIllustratedDataTile/AmeliproIllustratedDataTile.stories.ts +67 -0
- package/src/components/Amelipro/AmeliproIllustratedDataTile/AmeliproIllustratedDataTile.vue +174 -0
- package/src/components/Amelipro/AmeliproIllustratedDataTile/tests/AmeliproIllustratedDataTile.spec.ts +24 -0
- package/src/components/Amelipro/AmeliproIllustratedDataTile/tests/__snapshots__/AmeliproIllustratedDataTile.spec.ts.snap +66 -0
- package/src/components/Amelipro/AmeliproIllustratedDataTile/types.d.ts +4 -0
- package/src/components/Amelipro/AmeliproIllustratedRadioGroup/AmeliproIllustratedRadioGroup.mdx +15 -0
- package/src/components/Amelipro/AmeliproIllustratedRadioGroup/AmeliproIllustratedRadioGroup.stories.ts +162 -0
- package/src/components/Amelipro/AmeliproIllustratedRadioGroup/AmeliproIllustratedRadioGroup.vue +252 -0
- package/src/components/Amelipro/AmeliproIllustratedRadioGroup/locales.ts +1 -0
- package/src/components/Amelipro/AmeliproIllustratedRadioGroup/tests/AmeliproIllustratedRadioGroup.spec.ts +57 -0
- package/src/components/Amelipro/AmeliproIllustratedRadioGroup/tests/__snapshots__/AmeliproIllustratedRadioGroup.spec.ts.snap +524 -0
- package/src/components/Amelipro/AmeliproIllustratedRadioGroup/types.d.ts +8 -0
- package/src/components/Amelipro/AmeliproMailTile/AmeliproMailTile.mdx +15 -0
- package/src/components/Amelipro/AmeliproMailTile/AmeliproMailTile.stories.ts +151 -0
- package/src/components/Amelipro/AmeliproMailTile/AmeliproMailTile.vue +408 -0
- package/src/components/Amelipro/AmeliproMailTile/tests/AmeliproMailTile.spec.ts +29 -0
- package/src/components/Amelipro/AmeliproMailTile/tests/__snapshots__/AmeliproMailTile.spec.ts.snap +160 -0
- package/src/components/Amelipro/AmeliproMailTile/types.d.ts +14 -0
- package/src/components/Amelipro/AmeliproMenu/AmeliproMenu.mdx +15 -0
- package/src/components/Amelipro/AmeliproMenu/AmeliproMenu.stories.ts +205 -0
- package/src/components/Amelipro/AmeliproMenu/AmeliproMenu.vue +390 -0
- package/src/components/Amelipro/AmeliproMenu/tests/AmeliproMenu.spec.ts +87 -0
- package/src/components/Amelipro/AmeliproMenu/tests/__snapshots__/AmeliproMenu.spec.ts.snap +475 -0
- package/src/components/Amelipro/AmeliproMenu/types.d.ts +10 -0
- package/src/components/Amelipro/AmeliproMessage/AmeliproMessage.mdx +17 -0
- package/src/components/Amelipro/AmeliproMessage/AmeliproMessage.stories.ts +127 -0
- package/src/components/Amelipro/AmeliproMessage/AmeliproMessage.vue +253 -0
- package/src/components/Amelipro/AmeliproMessage/AmeliproMessageTypes.ts +26 -0
- package/src/components/Amelipro/AmeliproMessage/tests/AmeliproMessage.spec.ts +22 -0
- package/src/components/Amelipro/AmeliproMessage/tests/__snapshots__/AmeliproMessage.spec.ts.snap +85 -0
- package/src/components/Amelipro/AmeliproMessage/types.d.ts +7 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproDropdownMenu/AmeliproDropdownMenu.vue +225 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproDropdownMenu/AmeliproDropdownMenuBtn/AmeliproDropdownMenuBtn.vue +85 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproDropdownMenu/AmeliproDropdownMenuBtn/tests/AmeliproDropdownMenuBtn.spec.ts +20 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproDropdownMenu/AmeliproDropdownMenuBtn/tests/__snapshots__/AmeliproDropdownMenuBtn.spec.ts.snap +52 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproDropdownMenu/tests/AmeliproDropdownMenu.spec.ts +32 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproDropdownMenu/tests/__snapshots__/AmeliproDropdownMenu.spec.ts.snap +280 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproDropdownMenu/types.d.ts +8 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproMessagingLayout.mdx +15 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproMessagingLayout.stories.ts +149 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproMessagingLayout.vue +191 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproMessagingMenuBtn/AmeliproMessagingMenuBtn.vue +98 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproMessagingMenuBtn/tests/AmeliproMessagingMenuBtn.spec.ts +20 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/AmeliproMessagingMenuBtn/tests/__snapshots__/AmeliproMessagingMenuBtn.spec.ts.snap +81 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/tests/AmeliproMessagingLayout.spec.ts +34 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/tests/__snapshots__/AmeliproMessagingLayout.spec.ts.snap +405 -0
- package/src/components/Amelipro/AmeliproMessagingLayout/types.d.ts +10 -0
- package/src/components/Amelipro/AmeliproMultipleFoldingCard/AmeliproMultipleFoldingCard.mdx +15 -0
- package/src/components/Amelipro/AmeliproMultipleFoldingCard/AmeliproMultipleFoldingCard.stories.ts +146 -0
- package/src/components/Amelipro/AmeliproMultipleFoldingCard/AmeliproMultipleFoldingCard.vue +378 -0
- package/src/components/Amelipro/AmeliproMultipleFoldingCard/tests/AmeliproMultipleFoldingCard.spec.ts +44 -0
- package/src/components/Amelipro/AmeliproMultipleFoldingCard/tests/__snapshots__/AmeliproMultipleFoldingCard.spec.ts.snap +359 -0
- package/src/components/Amelipro/AmeliproMultipleFoldingCard/types.d.ts +6 -0
- package/src/components/Amelipro/AmeliproNumberedCard/AmeliproNumberedCard.mdx +22 -0
- package/src/components/Amelipro/AmeliproNumberedCard/AmeliproNumberedCard.stories.ts +178 -0
- package/src/components/Amelipro/AmeliproNumberedCard/AmeliproNumberedCard.vue +270 -0
- package/src/components/Amelipro/AmeliproNumberedCard/tests/AmeliproNumberedCard.spec.ts +27 -0
- package/src/components/Amelipro/AmeliproNumberedCard/tests/__snapshots__/AmeliproNumberedCard.spec.ts.snap +160 -0
- package/src/components/Amelipro/AmeliproNumberedCard/types.d.ts +4 -0
- package/src/components/Amelipro/AmeliproOnboarding/AmeliproOnboarding.mdx +15 -0
- package/src/components/Amelipro/AmeliproOnboarding/AmeliproOnboarding.stories.ts +160 -0
- package/src/components/Amelipro/AmeliproOnboarding/AmeliproOnboarding.vue +242 -0
- package/src/components/Amelipro/AmeliproOnboarding/tests/AmeliproOnboarding.spec.ts +45 -0
- package/src/components/Amelipro/AmeliproOnboarding/tests/__snapshots__/AmeliproOnboarding.spec.ts.snap +3 -0
- package/src/components/Amelipro/AmeliproOnboarding/types.d.ts +5 -0
- package/src/components/Amelipro/AmeliproPageLayout/AmeliproPageLayout.mdx +15 -0
- package/src/components/Amelipro/AmeliproPageLayout/AmeliproPageLayout.stories.ts +746 -0
- package/src/components/Amelipro/AmeliproPageLayout/AmeliproPageLayout.vue +252 -0
- package/src/components/Amelipro/AmeliproPageLayout/locales.ts +1 -0
- package/src/components/Amelipro/AmeliproPageLayout/tests/AmeliproPageLayout.spec.ts +187 -0
- package/src/components/Amelipro/AmeliproPageLayout/tests/__snapshots__/AmeliproPageLayout.spec.ts.snap +2144 -0
- package/src/components/Amelipro/AmeliproPageLayout/types.d.ts +15 -0
- package/src/components/Amelipro/AmeliproPagination/AmeliproPagination.mdx +15 -0
- package/src/components/Amelipro/AmeliproPagination/AmeliproPagination.stories.ts +96 -0
- package/src/components/Amelipro/AmeliproPagination/AmeliproPagination.vue +161 -0
- package/src/components/Amelipro/AmeliproPagination/AmeliproPaginationBtn/AmeliproPaginationBtn.vue +84 -0
- package/src/components/Amelipro/AmeliproPagination/AmeliproPaginationBtn/tests/AmeliproPaginationBtn.spec.ts +19 -0
- package/src/components/Amelipro/AmeliproPagination/AmeliproPaginationBtn/tests/__snapshots__/AmeliproPaginationBtn.spec.ts.snap +42 -0
- package/src/components/Amelipro/AmeliproPagination/tests/AmeliproPagination.spec.ts +19 -0
- package/src/components/Amelipro/AmeliproPagination/tests/__snapshots__/AmeliproPagination.spec.ts.snap +108 -0
- package/src/components/Amelipro/AmeliproPagination/types.d.ts +5 -0
- package/src/components/Amelipro/AmeliproPatientBanner/AmeliproPatientBanner.mdx +57 -0
- package/src/components/Amelipro/AmeliproPatientBanner/AmeliproPatientBanner.stories.ts +78 -0
- package/src/components/Amelipro/AmeliproPatientBanner/AmeliproPatientBanner.vue +219 -0
- package/src/components/Amelipro/AmeliproPatientBanner/locales.ts +6 -0
- package/src/components/Amelipro/AmeliproPatientBanner/tests/AmeliproPatientBanner.spec.ts +28 -0
- package/src/components/Amelipro/AmeliproPatientBanner/tests/__snapshots__/AmeliproPatientBanner.spec.ts.snap +246 -0
- package/src/components/Amelipro/AmeliproPatientBanner/types.d.ts +16 -0
- package/src/components/Amelipro/AmeliproRadioGroup/AmeliproRadioGroup.mdx +15 -0
- package/src/components/Amelipro/AmeliproRadioGroup/AmeliproRadioGroup.stories.ts +148 -0
- package/src/components/Amelipro/AmeliproRadioGroup/AmeliproRadioGroup.vue +391 -0
- package/src/components/Amelipro/AmeliproRadioGroup/locales.ts +1 -0
- package/src/components/Amelipro/AmeliproRadioGroup/tests/AmeliproRadioGroup.spec.ts +47 -0
- package/src/components/Amelipro/AmeliproRadioGroup/tests/__snapshots__/AmeliproRadioGroup.spec.ts.snap +262 -0
- package/src/components/Amelipro/AmeliproRadioGroup/types.d.ts +6 -0
- package/src/components/Amelipro/AmeliproSelect/AmeliproSelect.mdx +15 -0
- package/src/components/Amelipro/AmeliproSelect/AmeliproSelect.stories.ts +160 -0
- package/src/components/Amelipro/AmeliproSelect/AmeliproSelect.vue +373 -0
- package/src/components/Amelipro/AmeliproSelect/tests/AmeliproSelect.spec.ts +42 -0
- package/src/components/Amelipro/AmeliproSelect/tests/__snapshots__/AmeliproSelect.spec.ts.snap +186 -0
- package/src/components/Amelipro/AmeliproSelect/types.d.ts +10 -0
- package/src/components/Amelipro/AmeliproStateTile/AmeliproStateTile.mdx +15 -0
- package/src/components/Amelipro/AmeliproStateTile/AmeliproStateTile.stories.ts +86 -0
- package/src/components/Amelipro/AmeliproStateTile/AmeliproStateTile.vue +362 -0
- package/src/components/Amelipro/AmeliproStateTile/AmeliproStateTileTypes.ts +51 -0
- package/src/components/Amelipro/AmeliproStateTile/tests/AmeliproStateTile.spec.ts +24 -0
- package/src/components/Amelipro/AmeliproStateTile/tests/__snapshots__/AmeliproStateTile.spec.ts.snap +79 -0
- package/src/components/Amelipro/AmeliproStateTile/types.d.ts +11 -0
- package/src/components/Amelipro/AmeliproStatus/AmeliproStatus.mdx +15 -0
- package/src/components/Amelipro/AmeliproStatus/AmeliproStatus.stories.ts +56 -0
- package/src/components/Amelipro/AmeliproStatus/AmeliproStatus.vue +63 -0
- package/src/components/Amelipro/AmeliproStatus/AmeliproStatusTypes.ts +36 -0
- package/src/components/Amelipro/AmeliproStatus/tests/AmeliproStatus.spec.ts +20 -0
- package/src/components/Amelipro/AmeliproStatus/tests/__snapshots__/AmeliproStatus.spec.ts.snap +17 -0
- package/src/components/Amelipro/AmeliproStatus/types.d.ts +5 -0
- package/src/components/Amelipro/AmeliproStepper/AmeliproStepBtn/AmeliproStepBtn.vue +70 -0
- package/src/components/Amelipro/AmeliproStepper/AmeliproStepBtn/tests/AmeliproStepBtn.spec.ts +22 -0
- package/src/components/Amelipro/AmeliproStepper/AmeliproStepBtn/tests/__snapshots__/AmeliproStepBtn.spec.ts.snap +28 -0
- package/src/components/Amelipro/AmeliproStepper/AmeliproStepper.mdx +15 -0
- package/src/components/Amelipro/AmeliproStepper/AmeliproStepper.stories.ts +145 -0
- package/src/components/Amelipro/AmeliproStepper/AmeliproStepper.vue +416 -0
- package/src/components/Amelipro/AmeliproStepper/tests/AmeliproStepper.spec.ts +40 -0
- package/src/components/Amelipro/AmeliproStepper/tests/__snapshots__/AmeliproStepper.spec.ts.snap +312 -0
- package/src/components/Amelipro/AmeliproStepper/types.d.ts +5 -0
- package/src/components/Amelipro/AmeliproTabs/AmeliproTabBtn/AmeliproTabBtn.vue +196 -0
- package/src/components/Amelipro/AmeliproTabs/AmeliproTabBtn/tests/AmeliproTabBtn.spec.ts +24 -0
- package/src/components/Amelipro/AmeliproTabs/AmeliproTabBtn/tests/__snapshots__/AmeliproTabBtn.spec.ts.snap +30 -0
- package/src/components/Amelipro/AmeliproTabs/AmeliproTabs.mdx +23 -0
- package/src/components/Amelipro/AmeliproTabs/AmeliproTabs.stories.ts +204 -0
- package/src/components/Amelipro/AmeliproTabs/AmeliproTabs.vue +333 -0
- package/src/components/Amelipro/AmeliproTabs/tests/AmeliproTabs.spec.ts +43 -0
- package/src/components/Amelipro/AmeliproTabs/tests/__snapshots__/AmeliproTabs.spec.ts.snap +200 -0
- package/src/components/Amelipro/AmeliproTabs/types.d.ts +11 -0
- package/src/components/Amelipro/AmeliproTextArea/AmeliproTextArea.mdx +18 -0
- package/src/components/Amelipro/AmeliproTextArea/AmeliproTextArea.stories.ts +90 -0
- package/src/components/Amelipro/AmeliproTextArea/AmeliproTextArea.vue +321 -0
- package/src/components/Amelipro/AmeliproTextArea/__tests__/AmeliproTextArea.spec.ts +20 -0
- package/src/components/Amelipro/AmeliproTextArea/__tests__/__snapshots__/AmeliproTextArea.spec.ts.snap +174 -0
- package/src/components/Amelipro/AmeliproTextArea/types.d.ts +4 -0
- package/src/components/Amelipro/AmeliproTextField/AmeliproTextField.mdx +35 -0
- package/src/components/Amelipro/AmeliproTextField/AmeliproTextField.stories.ts +238 -0
- package/src/components/Amelipro/AmeliproTextField/AmeliproTextField.vue +390 -0
- package/src/components/Amelipro/AmeliproTextField/tests/AmeliproTextField.spec.ts +20 -0
- package/src/components/Amelipro/AmeliproTextField/tests/__snapshots__/AmeliproTextField.spec.ts.snap +155 -0
- package/src/components/Amelipro/AmeliproTextField/types.d.ts +4 -0
- package/src/components/Amelipro/AmeliproTileBtn/AmeliproTileBtn.mdx +18 -0
- package/src/components/Amelipro/AmeliproTileBtn/AmeliproTileBtn.stories.ts +135 -0
- package/src/components/Amelipro/AmeliproTileBtn/AmeliproTileBtn.vue +360 -0
- package/src/components/Amelipro/AmeliproTileBtn/tests/AmeliproTileBtn.spec.ts +21 -0
- package/src/components/Amelipro/AmeliproTileBtn/tests/__snapshots__/AmeliproTileBtn.spec.ts.snap +58 -0
- package/src/components/Amelipro/AmeliproTooltips/AmeliproTooltips.mdx +15 -0
- package/src/components/Amelipro/AmeliproTooltips/AmeliproTooltips.stories.ts +60 -0
- package/src/components/Amelipro/AmeliproTooltips/AmeliproTooltips.vue +114 -0
- package/src/components/Amelipro/AmeliproTooltips/tests/AmeliproTooltips.spec.ts +20 -0
- package/src/components/Amelipro/AmeliproTooltips/tests/__snapshots__/AmeliproTooltips.spec.ts.snap +100 -0
- package/src/components/Amelipro/AmeliproTransmission/AmeliproTransmission.mdx +24 -0
- package/src/components/Amelipro/AmeliproTransmission/AmeliproTransmission.stories.ts +67 -0
- package/src/components/Amelipro/AmeliproTransmission/AmeliproTransmission.vue +139 -0
- package/src/components/Amelipro/AmeliproTransmission/tests/AmeliproTransmission.spec.ts +20 -0
- package/src/components/Amelipro/AmeliproTransmission/tests/__snapshots__/AmeliproTransmission.spec.ts.snap +225 -0
- package/src/components/Amelipro/ServiceMenu/ServiceBtn/ServiceBtn.vue +113 -0
- package/src/components/Amelipro/ServiceMenu/ServiceBtn/tests/ServiceBtn.spec.ts +25 -0
- package/src/components/Amelipro/ServiceMenu/ServiceBtn/tests/__snapshots__/ServiceBtn.spec.ts.snap +93 -0
- package/src/components/Amelipro/ServiceMenu/ServiceBtn/types.d.ts +8 -0
- package/src/components/Amelipro/ServiceMenu/ServiceList/ServiceList.vue +96 -0
- package/src/components/Amelipro/ServiceMenu/ServiceList/tests/ServiceList.spec.ts +29 -0
- package/src/components/Amelipro/ServiceMenu/ServiceList/tests/__snapshots__/ServiceList.spec.ts.snap +231 -0
- package/src/components/Amelipro/ServiceMenu/ServiceMenu.mdx +15 -0
- package/src/components/Amelipro/ServiceMenu/ServiceMenu.stories.ts +338 -0
- package/src/components/Amelipro/ServiceMenu/ServiceMenu.vue +183 -0
- package/src/components/Amelipro/ServiceMenu/ServiceMenuContent/ServiceMenuContent.vue +135 -0
- package/src/components/Amelipro/ServiceMenu/ServiceMenuContent/tests/ServiceMenuContent.spec.ts +49 -0
- package/src/components/Amelipro/ServiceMenu/ServiceMenuContent/tests/__snapshots__/ServiceMenuContent.spec.ts.snap +733 -0
- package/src/components/Amelipro/ServiceMenu/tests/ServiceMenu.spec.ts +50 -0
- package/src/components/Amelipro/ServiceMenu/tests/__snapshots__/ServiceMenu.spec.ts.snap +863 -0
- package/src/components/Amelipro/ServiceMenu/types.d.ts +13 -0
- package/src/components/Amelipro/StructureMenu/StructureBtn/StructureBtn.vue +76 -0
- package/src/components/Amelipro/StructureMenu/StructureBtn/tests/StructureBtn.spec.ts +21 -0
- package/src/components/Amelipro/StructureMenu/StructureBtn/tests/__snapshots__/StructureBtn.spec.ts.snap +34 -0
- package/src/components/Amelipro/StructureMenu/StructureItem/StructureItem.vue +129 -0
- package/src/components/Amelipro/StructureMenu/StructureItem/locales.ts +4 -0
- package/src/components/Amelipro/StructureMenu/StructureItem/tests/StructureItem.spec.ts +25 -0
- package/src/components/Amelipro/StructureMenu/StructureItem/tests/__snapshots__/StructureItem.spec.ts.snap +102 -0
- package/src/components/Amelipro/StructureMenu/StructureItem/types.d.ts +6 -0
- package/src/components/Amelipro/StructureMenu/StructureList/StructureList.vue +130 -0
- package/src/components/Amelipro/StructureMenu/StructureList/locales.ts +4 -0
- package/src/components/Amelipro/StructureMenu/StructureList/tests/StructureList.spec.ts +37 -0
- package/src/components/Amelipro/StructureMenu/StructureList/tests/__snapshots__/StructureList.spec.ts.snap +342 -0
- package/src/components/Amelipro/StructureMenu/StructureMenu.mdx +15 -0
- package/src/components/Amelipro/StructureMenu/StructureMenu.stories.ts +268 -0
- package/src/components/Amelipro/StructureMenu/StructureMenu.vue +240 -0
- package/src/components/Amelipro/StructureMenu/StructureTabs/StructureTabs.vue +167 -0
- package/src/components/Amelipro/StructureMenu/StructureTabs/locales.ts +4 -0
- package/src/components/Amelipro/StructureMenu/StructureTabs/tests/StructureTabs.spec.ts +64 -0
- package/src/components/Amelipro/StructureMenu/StructureTabs/tests/__snapshots__/StructureTabs.spec.ts.snap +801 -0
- package/src/components/Amelipro/StructureMenu/StructureTabs/types.d.ts +12 -0
- package/src/components/Amelipro/StructureMenu/locales.ts +10 -0
- package/src/components/Amelipro/StructureMenu/tests/StructureMenu.spec.ts +71 -0
- package/src/components/Amelipro/StructureMenu/tests/__snapshots__/StructureMenu.spec.ts.snap +1321 -0
- package/src/components/Amelipro/StructureMenu/types.d.ts +35 -0
- package/src/components/Amelipro/UserInformationSummary/UserInformationSummary.vue +73 -0
- package/src/components/Amelipro/UserInformationSummary/tests/UserInformationSummary.spec.ts +28 -0
- package/src/components/Amelipro/UserInformationSummary/tests/__snapshots__/UserInformationSummary.spec.ts.snap +80 -0
- package/src/components/Amelipro/UserInformationSummary/types.d.ts +9 -0
- package/src/components/Amelipro/UserMenu/UserMenu.mdx +15 -0
- package/src/components/Amelipro/UserMenu/UserMenu.stories.ts +133 -0
- package/src/components/Amelipro/UserMenu/UserMenu.vue +169 -0
- package/src/components/Amelipro/UserMenu/UserMenuDetails/UserMenuDetails.vue +99 -0
- package/src/components/Amelipro/UserMenu/UserMenuDetails/tests/UserMenuDetails.spec.ts +37 -0
- package/src/components/Amelipro/UserMenu/UserMenuDetails/tests/__snapshots__/UserMenuDetails.spec.ts.snap +3 -0
- package/src/components/Amelipro/UserMenu/UserMenuDetails/types.d.ts +20 -0
- package/src/components/Amelipro/UserMenu/tests/UserMenu.spec.ts +38 -0
- package/src/components/Amelipro/UserMenu/tests/__snapshots__/UserMenu.spec.ts.snap +91 -0
- package/src/components/Amelipro/UserMenu/types.d.ts +9 -0
- package/src/components/Amelipro/types.ts +5 -0
- package/src/components/CollapsibleList/Accessibilite.stories.ts +4 -0
- package/src/components/CollapsibleList/CollapsibleList.vue +23 -8
- package/src/components/ContextualMenu/Accessibilite.stories.ts +4 -0
- package/src/components/ContextualMenu/ContextualMenu.stories.ts +58 -28
- package/src/components/ContextualMenu/ContextualMenu.vue +87 -54
- package/src/components/ContextualMenu/DeepMenu.vue +82 -0
- package/src/components/ContextualMenu/tests/ContextualMenu.spec.ts +154 -0
- package/src/components/ContextualMenu/tests/__snapshots__/ContextualMenu.spec.ts.snap +436 -31
- package/src/components/ContextualMenu/types.ts +8 -0
- package/src/components/{SelectBtnField → Customs/Selects/SelectBtnField}/Accessibilite.stories.ts +1 -1
- package/src/components/{SelectBtnField → Customs/Selects/SelectBtnField}/SelectBtnField.mdx +1 -1
- package/src/components/{SelectBtnField → Customs/Selects/SelectBtnField}/SelectBtnField.stories.ts +2 -2
- package/src/components/{SelectBtnField → Customs/Selects/SelectBtnField}/Usages.stories.ts +1 -1
- package/src/components/Customs/Selects/SelectOverview.mdx +350 -0
- package/src/components/Customs/{SyBtnSelect → Selects/SyBtnSelect}/Accessibilite.stories.ts +1 -1
- package/src/components/Customs/{SyBtnSelect → Selects/SyBtnSelect}/SyBtnSelect.mdx +1 -1
- package/src/components/Customs/{SyBtnSelect → Selects/SyBtnSelect}/SyBtnSelect.stories.ts +1 -1
- package/src/components/Customs/{SyInputSelect → Selects/SyInputSelect}/Accessibilite.stories.ts +1 -1
- package/src/components/Customs/{SyInputSelect → Selects/SyInputSelect}/SyInputSelect.mdx +1 -1
- package/src/components/Customs/{SyInputSelect → Selects/SyInputSelect}/SyInputSelect.stories.ts +3 -2
- package/src/components/Customs/{SyInputSelect → Selects/SyInputSelect}/SyInputSelect.vue +8 -1
- package/src/components/Customs/Selects/SySelect/Accessibilite.mdx +204 -0
- package/src/components/Customs/{SySelect → Selects/SySelect}/Accessibilite.stories.ts +73 -3
- package/src/components/Customs/{SySelect → Selects/SySelect}/SySelect.mdx +1 -1
- package/src/components/Customs/{SySelect → Selects/SySelect}/SySelect.stories.ts +195 -7
- package/src/components/Customs/Selects/SySelect/SySelect.vue +788 -0
- package/src/components/Customs/{SySelect → Selects/SySelect}/Usages.stories.ts +1 -1
- package/src/components/Customs/Selects/SySelect/composables/tests/useSySelectKeyboard.spec.ts +272 -0
- package/src/components/Customs/Selects/SySelect/composables/useSySelectKeyboard.ts +272 -0
- package/src/components/Customs/{SySelect → Selects/SySelect}/tests/SySelect.spec.ts +230 -0
- package/src/components/Customs/SyCheckbox/Accessibilite.mdx +303 -0
- package/src/components/Customs/SyCheckbox/SyCheckbox.mdx +50 -0
- package/src/components/Customs/SyCheckbox/SyCheckbox.stories.ts +630 -0
- package/src/components/Customs/SyCheckbox/SyCheckbox.vue +351 -0
- package/src/components/Customs/SyCheckbox/locales.ts +3 -0
- package/src/components/Customs/SyCheckbox/tests/SyCheckbox.spec.ts +201 -0
- package/src/components/Customs/SyIcon/Accessibilite.mdx +103 -0
- package/src/components/Customs/SyIcon/Accessibilite.stories.ts +27 -0
- package/src/components/Customs/SyIcon/SyIcon.mdx +72 -0
- package/src/components/Customs/SyIcon/SyIcon.spec.ts +127 -0
- package/src/components/Customs/SyIcon/SyIcon.stories.ts +310 -0
- package/src/components/Customs/SyIcon/SyIcon.vue +72 -0
- package/src/components/Customs/SyIcon/SyIconAccessibility.vue +306 -0
- package/src/components/Customs/SyIcon/utils/iconUtils.ts +52 -0
- package/src/components/Customs/SyPagination/SyPagination.mdx +150 -0
- package/src/components/Customs/SyPagination/SyPagination.stories.ts +213 -0
- package/src/components/Customs/SyPagination/SyPagination.vue +437 -0
- package/src/components/Customs/SyPagination/tests/SyPagination.spec.ts +179 -0
- package/src/components/Customs/SyTextField/SyTextField.stories.ts +3 -2
- package/src/components/Customs/SyTextField/SyTextField.vue +19 -8
- package/src/components/DatePicker/ComplexDatePicker/ComplexDatePicker.stories.ts +241 -31
- package/src/components/DatePicker/ComplexDatePicker/ComplexDatePicker.vue +305 -57
- package/src/components/DatePicker/ComplexDatePicker/tests/ComplexDatePicker.events.spec.ts +161 -0
- package/src/components/DatePicker/ComplexDatePicker/tests/ComplexDatePicker.spec.ts +4 -2
- package/src/components/DatePicker/DatePicker/DatePicker.stories.ts +259 -137
- package/src/components/DatePicker/DatePicker/DatePicker.vue +159 -30
- package/src/components/DatePicker/DatePicker/tests/DatePicker.events.spec.ts +189 -0
- package/src/components/DatePicker/DatePicker/{DatePicker.spec.ts → tests/DatePicker.spec.ts} +1 -15
- package/src/components/DatePicker/DateTextInput/DateRange.stories.ts +24 -14
- package/src/components/DatePicker/DateTextInput/DateTextInput.events.spec.ts +148 -0
- package/src/components/DatePicker/DateTextInput/DateTextInput.spec.ts +3 -1
- package/src/components/DatePicker/DateTextInput/DateTextInput.vue +202 -5
- package/src/components/DatePicker/DateTextInput/NoCalendar.stories.ts +241 -31
- package/src/components/DatePicker/composables/index.ts +2 -0
- package/src/components/DatePicker/composables/tests/useDateAutoClamp.spec.ts +190 -0
- package/src/components/DatePicker/composables/tests/useInputBlurHandler.spec.ts +182 -4
- package/src/components/DatePicker/composables/tests/useMonthButtonCustomization.spec.ts +105 -80
- package/src/components/DatePicker/composables/useAsteriskDisplay.ts +31 -0
- package/src/components/DatePicker/composables/useDateAutoClamp.ts +136 -0
- package/src/components/DatePicker/composables/useDateRangeInput.ts +21 -18
- package/src/components/DatePicker/composables/useDisplayedDateString.ts +13 -1
- package/src/components/DatePicker/composables/useInputBlurHandler.ts +84 -20
- package/src/components/DatePicker/composables/useMonthButtonCustomization.ts +149 -51
- package/src/components/DiacriticPicker/DiacriticPicker.stories.ts +10 -0
- package/src/components/ErrorPage/Accessibilite.stories.ts +8 -0
- package/src/components/ErrorPage/ErrorPage.vue +12 -6
- package/src/components/ErrorPage/tests/__snapshots__/ErrorPage.spec.ts.snap +4 -4
- package/src/components/FilterSideBar/FilterSideBar.vue +3 -2
- package/src/components/FilterSideBar/tests/FilterSideBar.spec.ts +1 -1
- package/src/components/MaintenancePage/Accessibilite.stories.ts +8 -0
- package/src/components/MaintenancePage/MaintenancePage.vue +3 -2
- package/src/components/MaintenancePage/tests/__snapshots__/MaintenancePage.spec.ts.snap +1 -2
- package/src/components/NirField/NirField.mdx +22 -9
- package/src/components/NirField/NirField.stories.ts +26 -2
- package/src/components/NirField/NirField.vue +209 -22
- package/src/components/NirField/nirValidation.ts +17 -3
- package/src/components/NirField/tests/NirField.spec.ts +2 -2
- package/src/components/NotFoundPage/Accessibilite.stories.ts +8 -0
- package/src/components/NotFoundPage/NotFoundPage.vue +2 -1
- package/src/components/NotFoundPage/tests/__snapshots__/NotFoundPage.spec.ts.snap +8 -6
- package/src/components/PaginatedTable/PaginatedTable.mdx +2 -0
- package/src/components/PaginatedTable/PaginatedTable.stories.ts +22 -0
- package/src/components/PaginatedTable/PaginatedTable.vue +10 -2
- package/src/components/PasswordField/PasswordField.stories.ts +4 -0
- package/src/components/PasswordField/PasswordField.vue +3 -0
- package/src/components/PeriodField/PeriodField.vue +2 -0
- package/src/components/PhoneField/PhoneField.stories.ts +15 -15
- package/src/components/PhoneField/PhoneField.vue +2 -2
- package/src/components/RangeField/RangeField.stories.ts +9 -0
- package/src/components/RangeField/RangeField.vue +4 -0
- package/src/components/RangeField/tests/__snapshots__/RangeField.spec.ts.snap +12 -0
- package/src/components/RatingPicker/NumberPicker/NumberPicker.vue +2 -2
- package/src/components/RatingPicker/RatingPicker.stories.ts +1 -1
- package/src/components/SearchListField/SearchListField.mdx +1 -1
- package/src/components/SearchListField/SearchListField.stories.ts +7 -1
- package/src/components/SearchListField/SearchListField.vue +38 -49
- package/src/components/SocialMediaLinks/Accessibilite.stories.ts +8 -0
- package/src/components/SocialMediaLinks/SocialMediaLinks.stories.ts +34 -2
- package/src/components/SocialMediaLinks/SocialMediaLinks.vue +43 -8
- package/src/components/SocialMediaLinks/tests/SocialMediaLinks.spec.ts +98 -2
- package/src/components/SocialMediaLinks/tests/__snapshots__/SocialMediaLinks.spec.ts.snap +76 -8
- package/src/components/SyTextArea/SyTextArea.vue +3 -0
- package/src/components/SyTextArea/tests/SyTextArea.spec.ts +0 -1
- package/src/components/TableToolbar/TableToolbar.stories.ts +1 -1
- package/src/components/Tables/SyServerTable/FilterRules.stories.ts +632 -15
- package/src/components/Tables/SyServerTable/SyServerTable.mdx +25 -5
- package/src/components/Tables/SyServerTable/SyServerTable.stories.ts +3925 -1591
- package/src/components/Tables/SyServerTable/SyServerTable.vue +169 -66
- package/src/components/Tables/SyServerTable/tests/SyServerTable.spec.ts +256 -4
- package/src/components/Tables/SyTable/FilterRules.stories.ts +183 -0
- package/src/components/Tables/SyTable/SyTable.mdx +24 -4
- package/src/components/Tables/SyTable/SyTable.stories.ts +1832 -437
- package/src/components/Tables/SyTable/SyTable.vue +167 -72
- package/src/components/Tables/SyTable/tests/SyTable.spec.ts +366 -4
- package/src/components/Tables/common/SyTableFilter.vue +3 -56
- package/src/components/Tables/common/SyTablePagination.vue +203 -0
- package/src/components/Tables/common/TableHeader.vue +45 -32
- package/src/components/Tables/common/filters/SelectFilter.vue +132 -23
- package/src/components/Tables/common/filters/getFilterComponent.ts +54 -0
- package/src/components/Tables/common/filters/locales.ts +4 -0
- package/src/components/Tables/common/filters/logics/date.ts +12 -0
- package/src/components/Tables/common/filters/logics/number.ts +48 -0
- package/src/components/Tables/common/filters/logics/period.ts +25 -0
- package/src/components/Tables/common/filters/logics/select.ts +27 -0
- package/src/components/Tables/common/filters/logics/tests/TextFilterLogic.spec.ts +177 -0
- package/src/components/Tables/common/filters/logics/text.ts +62 -0
- package/src/components/Tables/common/filters/tests/SelectFilter.spec.ts +1 -1
- package/src/components/Tables/common/filters/tests/TextFilter.spec.ts +11 -11
- package/src/components/Tables/common/locales.ts +24 -0
- package/src/components/Tables/common/organizeColumns/OrganizeColumns.vue +269 -0
- package/src/components/Tables/common/organizeColumns/sortHeaders.ts +9 -0
- package/src/components/Tables/common/tableFilterUtils.ts +43 -295
- package/src/components/Tables/common/tableStorageUtils.ts +27 -2
- package/src/components/Tables/common/tableStyles.scss +26 -0
- package/src/components/Tables/common/tableUtils.ts +3 -16
- package/src/components/Tables/common/tests/SyTablePagination.spec.ts +173 -0
- package/src/components/Tables/common/tests/TableHeader.spec.ts +272 -0
- package/src/components/Tables/common/tests/filterByRange.spec.ts +215 -0
- package/src/components/Tables/common/tests/tableFilterUtils.spec.ts +0 -14
- package/src/components/Tables/common/tests/tableUtils.spec.ts +7 -51
- package/src/components/Tables/common/types.ts +21 -6
- package/src/components/Tables/common/usePagination.ts +83 -0
- package/src/components/Tables/common/useTableCheckbox.ts +58 -0
- package/src/components/Tables/common/useTableHeaders.ts +88 -0
- package/src/components/Tables/common/useTableItems.ts +87 -0
- package/src/components/Tables/common/useTableOptions.ts +93 -0
- package/src/components/ToolbarContainer/ToolbarContainer.mdx +16 -0
- package/src/components/ToolbarContainer/ToolbarContainer.stories.ts +675 -0
- package/src/components/ToolbarContainer/ToolbarContainer.vue +128 -0
- package/src/components/ToolbarContainer/tests/ToolbarContainer.spec.ts +156 -0
- package/src/components/UserMenuBtn/UserMenuBtn.stories.ts +74 -0
- package/src/components/UserMenuBtn/UserMenuBtn.vue +20 -18
- package/src/components/index.ts +154 -58
- package/src/composables/date/useDatePickerAccessibility.ts +163 -14
- package/src/composables/useError.ts +9 -0
- package/src/designTokens/apColors.md +66 -0
- package/src/designTokens/index.ts +10 -0
- package/src/designTokens/tokens/amelipro/apColors.ts +81 -0
- package/src/designTokens/tokens/amelipro/apContextual.ts +58 -0
- package/src/designTokens/tokens/amelipro/apDarkTheme.ts +5 -0
- package/src/designTokens/tokens/amelipro/apLightTheme.ts +13 -0
- package/src/designTokens/tokens/amelipro/apSemantic.ts +87 -0
- package/src/directives/rgaaSvgFix.ts +279 -0
- package/src/main.ts +1 -0
- package/src/stories/Accessibilite/Aculturation/AuditDesignSystem.mdx +293 -20
- package/src/stories/Accessibilite/Aculturation/SensibilisationAccessibilite.mdx +448 -54
- package/src/stories/Accessibilite/Audit/RGAA.mdx +231 -23
- package/src/stories/Accessibilite/Avancement/Avancement.mdx +591 -7
- package/src/stories/Accessibilite/Avancement/Avancement.stories.ts +145 -43
- package/src/stories/Accessibilite/Introduction.mdx +258 -18
- package/src/stories/Accessibilite/KitDePreAudit/Echantillonnage.mdx +221 -31
- package/src/stories/Accessibilite/KitDePreAudit/Introduction.mdx +204 -22
- package/src/stories/Accessibilite/KitDePreAudit/Outils/Introduction.mdx +537 -24
- package/src/stories/Accessibilite/KitDePreAudit/Outils/LecteursDEcran.mdx +577 -70
- package/src/stories/Accessibilite/KitDePreAudit/Outils/Tanaguru.mdx +382 -31
- package/src/stories/Accessibilite/KitDePreAudit/Preaudit.mdx +419 -81
- package/src/stories/Accessibilite/Vuetify/Vuetify.mdx +170 -5
- package/src/stories/Accessibilite/Vuetify/Vuetify.stories.ts +370 -146
- package/src/stories/Accessibilite/Vuetify/VuetifyItems.ts +55 -60
- package/src/stories/Demarrer/Accueil.mdx +1 -1
- package/src/stories/Demarrer/Accueil.stories.ts +85 -46
- package/src/stories/Demarrer/Releases.stories.ts +3 -0
- package/src/stories/DesignTokens/ColorDisplay.vue +117 -28
- package/src/stories/DesignTokens/Colors.mdx +9 -27
- package/src/stories/DesignTokens/StylesTypographiques.mdx +10 -9
- package/src/stories/DesignTokens/StylesTypographiques.stories.new.ts +397 -0
- package/src/stories/DesignTokens/StylesTypographiques.stories.ts +397 -0
- package/src/stories/DesignTokens/TypographyDisplay.vue +155 -0
- package/src/stories/DesignTokens/colors.stories.ts +507 -23
- package/src/stories/DesignTokens/vue-shims.d.ts +6 -0
- package/src/stories/Directives/SvgDirective.mdx +432 -0
- package/src/stories/GuideDuDev/ClassesUtilitaires/DataUtilities.mdx +318 -0
- package/src/stories/GuideDuDev/ClassesUtilitaires/DomBrowserUtilities.mdx +344 -0
- package/src/stories/GuideDuDev/ClassesUtilitaires/FormattingUtilities.mdx +287 -0
- package/src/stories/GuideDuDev/ClassesUtilitaires/StorageUtilities.mdx +145 -0
- package/src/stories/GuideDuDev/ClassesUtilitaires/ValidationRules.mdx +437 -0
- package/src/stories/GuideDuDev/ClassesUtilitaires/ValidationUtilities.mdx +364 -0
- package/src/stories/GuideDuDev/ClassesUtilitaires/index.mdx +292 -0
- package/src/stories/GuideDuDev/LesBreackingChanges.mdx +0 -2
- package/src/stories/GuideDuDev/MigrationDepuisBridge.mdx +1 -1
- package/src/stories/GuideDuDev/MigrationDepuisVue2.mdx +1 -1
- package/src/stories/GuideDuDev/PortailAgent.mdx +10 -0
- package/src/stories/GuideDuDev/PortailAgent.stories.ts +526 -0
- package/src/stories/GuideDuDev/Theme.mdx +42 -0
- package/src/utils/amelipro/dateHelper/dateHelper.ts +97 -0
- package/src/utils/amelipro/dateHelper/tests/dateHelper.spec.ts +49 -0
- package/src/utils/amelipro/numberHelper/numberHelper.ts +20 -0
- package/src/utils/amelipro/numberHelper/tests/numberHelper.spec.ts +24 -0
- package/src/utils/amelipro/rules/maxNumber/index.ts +24 -0
- package/src/utils/amelipro/rules/maxNumber/tests/maxNumber.spec.ts +22 -0
- package/src/utils/amelipro/rules/minNumber/index.ts +24 -0
- package/src/utils/amelipro/rules/minNumber/tests/minNumber.spec.ts +22 -0
- package/src/utils/amelipro/rules/notAfterDate/index.ts +33 -0
- package/src/utils/amelipro/rules/notAfterDate/tests/notAfterDate.spec.ts +32 -0
- package/src/utils/amelipro/rules/notBeforeDate/index.ts +33 -0
- package/src/utils/amelipro/rules/notBeforeDate/tests/notBeforeDate.spec.ts +32 -0
- package/src/utils/functions/ameliproColors/ameliproColors.ts +57 -0
- package/src/utils/functions/ameliproColors/types.d.ts +5 -0
- package/src/utils/functions/classToHex.ts +38 -0
- package/src/utils/functions/convertToHex.ts +23 -0
- package/src/utils/functions/isCssColor.ts +3 -0
- package/src/utils/index.ts +45 -0
- package/src/vuetifyConfig.ts +15 -0
- package/dist/SelectFilter-Cj-GW2Cc.js +0 -97
- package/dist/main-WDqeoGM-.js +0 -14788
- package/src/components/Customs/SySelect/SySelect.vue +0 -382
- package/src/components/PaginatedTable/tests/__snapshots__/PaginatedTable.spec.ts.snap +0 -886
- package/src/components/SelectBtnField/Accessibilite.mdx +0 -14
- package/src/components/Tables/SyServerTable/tests/__snapshots__/SyServerTable.spec.ts.snap +0 -521
- package/src/components/Tables/SyTable/tests/__snapshots__/SyTable.spec.ts.snap +0 -521
- package/src/stories/DesignTokens/ThemePA.mdx +0 -35
- /package/dist/components/{SelectBtnField → Customs/Selects/SelectBtnField}/config.d.ts +0 -0
- /package/dist/components/{SelectBtnField → Customs/Selects/SelectBtnField}/types.d.ts +0 -0
- /package/dist/components/Customs/{SyInputSelect → Selects/SyInputSelect}/config.d.ts +0 -0
- /package/dist/components/Customs/{SySelect → Selects/SySelect}/locales.d.ts +0 -0
- /package/src/components/Customs/{SyBtnSelect → Selects/SelectBtnField}/Accessibilite.mdx +0 -0
- /package/src/components/{SelectBtnField → Customs/Selects/SelectBtnField}/AccessibiliteItems.ts +0 -0
- /package/src/components/{SelectBtnField → Customs/Selects/SelectBtnField}/SelectBtnField.vue +0 -0
- /package/src/components/Customs/{SySelect → Selects/SelectBtnField}/Usages.mdx +0 -0
- /package/src/components/{SelectBtnField → Customs/Selects/SelectBtnField}/config.ts +0 -0
- /package/src/components/{SelectBtnField → Customs/Selects/SelectBtnField}/tests/SelectBtnField.spec.ts +0 -0
- /package/src/components/{SelectBtnField → Customs/Selects/SelectBtnField}/tests/__snapshots__/SelectBtnField.spec.ts.snap +0 -0
- /package/src/components/{SelectBtnField → Customs/Selects/SelectBtnField}/types.d.ts +0 -0
- /package/src/components/Customs/{SyInputSelect → Selects/SyBtnSelect}/Accessibilite.mdx +0 -0
- /package/src/components/Customs/{SyBtnSelect → Selects/SyBtnSelect}/AccessibiliteItems.ts +0 -0
- /package/src/components/Customs/{SyBtnSelect → Selects/SyBtnSelect}/SyBtnSelect.vue +0 -0
- /package/src/components/Customs/{SyBtnSelect → Selects/SyBtnSelect}/tests/SyBtnSelect.spec.ts +0 -0
- /package/src/components/Customs/{SySelect → Selects/SyInputSelect}/Accessibilite.mdx +0 -0
- /package/src/components/Customs/{SyInputSelect → Selects/SyInputSelect}/AccessibiliteItems.ts +0 -0
- /package/src/components/Customs/{SyInputSelect → Selects/SyInputSelect}/config.ts +0 -0
- /package/src/components/Customs/{SyInputSelect → Selects/SyInputSelect}/tests/SyInputSelect.spec.ts +0 -0
- /package/src/components/Customs/{SySelect → Selects/SySelect}/AccessibiliteItems.ts +0 -0
- /package/src/components/{SelectBtnField → Customs/Selects/SySelect}/Usages.mdx +0 -0
- /package/src/components/Customs/{SySelect → Selects/SySelect}/locales.ts +0 -0
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
2
|
+
import { fn } from '@storybook/test'
|
|
3
|
+
import { ref } from 'vue'
|
|
2
4
|
import SyTable from './SyTable.vue'
|
|
3
5
|
import type { DataOptions, FilterType } from '../common/types'
|
|
4
|
-
import { ref } from 'vue'
|
|
5
6
|
import type { VDataTable } from 'vuetify/components'
|
|
6
7
|
import dayjs from 'dayjs'
|
|
7
8
|
|
|
@@ -18,7 +19,7 @@ const meta = {
|
|
|
18
19
|
},
|
|
19
20
|
argTypes: {
|
|
20
21
|
headers: {
|
|
21
|
-
description: 'Liste des colonnes du tableau',
|
|
22
|
+
description: 'Liste des colonnes du tableau (voir : https://vuetifyjs.com/en/api/v-data-table/#props-headers)',
|
|
22
23
|
control: { type: 'object' },
|
|
23
24
|
table: {
|
|
24
25
|
category: 'props',
|
|
@@ -29,6 +30,9 @@ const meta = {
|
|
|
29
30
|
control: { type: 'object' },
|
|
30
31
|
table: {
|
|
31
32
|
category: 'props',
|
|
33
|
+
defaultValue: {
|
|
34
|
+
summary: '[]',
|
|
35
|
+
},
|
|
32
36
|
},
|
|
33
37
|
},
|
|
34
38
|
density: {
|
|
@@ -66,12 +70,35 @@ const meta = {
|
|
|
66
70
|
},
|
|
67
71
|
required: true,
|
|
68
72
|
},
|
|
69
|
-
itemsPerPage: {
|
|
70
|
-
description: 'Nombre d\'éléments par page',
|
|
71
|
-
control: { type: 'number' },
|
|
72
|
-
},
|
|
73
73
|
resizableColumns: {
|
|
74
74
|
description: 'Permet de redimensionner les colonnes du tableau',
|
|
75
|
+
control: { type: 'boolean' },
|
|
76
|
+
table: {
|
|
77
|
+
category: 'props',
|
|
78
|
+
type: { summary: 'boolean' },
|
|
79
|
+
},
|
|
80
|
+
},
|
|
81
|
+
multiSort: {
|
|
82
|
+
description: 'Permet de trier sur plusieurs colonnes simultanément. Lorsque activé, des indicateurs numériques apparaissent à côté des icônes de tri pour montrer l\'ordre de priorité.',
|
|
83
|
+
control: { type: 'boolean' },
|
|
84
|
+
table: {
|
|
85
|
+
category: 'props',
|
|
86
|
+
type: { summary: 'boolean' },
|
|
87
|
+
defaultValue: {
|
|
88
|
+
summary: 'false',
|
|
89
|
+
},
|
|
90
|
+
},
|
|
91
|
+
},
|
|
92
|
+
mustSort: {
|
|
93
|
+
description: 'Force au moins une colonne à être toujours triée. Si désactivé, toutes les colonnes peuvent être non triées.',
|
|
94
|
+
control: { type: 'boolean' },
|
|
95
|
+
table: {
|
|
96
|
+
category: 'props',
|
|
97
|
+
type: { summary: 'boolean' },
|
|
98
|
+
defaultValue: {
|
|
99
|
+
summary: 'false',
|
|
100
|
+
},
|
|
101
|
+
},
|
|
75
102
|
},
|
|
76
103
|
caption: {
|
|
77
104
|
description: 'Texte de la légende du tableau',
|
|
@@ -81,6 +108,25 @@ const meta = {
|
|
|
81
108
|
description: 'Affiche les filtres au-dessus du tableau',
|
|
82
109
|
control: { type: 'boolean' },
|
|
83
110
|
},
|
|
111
|
+
enableColumnControls: {
|
|
112
|
+
description: 'Allow the users to re-organize the columns',
|
|
113
|
+
table: {
|
|
114
|
+
defaultValue: {
|
|
115
|
+
summary: 'false',
|
|
116
|
+
},
|
|
117
|
+
type: { summary: 'boolean' },
|
|
118
|
+
category: 'props',
|
|
119
|
+
},
|
|
120
|
+
control: { type: 'boolean' },
|
|
121
|
+
},
|
|
122
|
+
showSelect: {
|
|
123
|
+
description: 'Affiche des cases à cocher pour sélectionner des lignes',
|
|
124
|
+
control: { type: 'boolean' },
|
|
125
|
+
table: {
|
|
126
|
+
category: 'props',
|
|
127
|
+
type: { summary: 'boolean' },
|
|
128
|
+
},
|
|
129
|
+
},
|
|
84
130
|
},
|
|
85
131
|
} satisfies Meta<typeof SyTable & typeof VDataTable>
|
|
86
132
|
|
|
@@ -168,7 +214,7 @@ export const Default: Story = {
|
|
|
168
214
|
],
|
|
169
215
|
},
|
|
170
216
|
args: {
|
|
171
|
-
headers: [
|
|
217
|
+
'headers': [
|
|
172
218
|
{
|
|
173
219
|
title: 'Nom',
|
|
174
220
|
key: 'lastname',
|
|
@@ -182,7 +228,7 @@ export const Default: Story = {
|
|
|
182
228
|
value: 'email',
|
|
183
229
|
},
|
|
184
230
|
],
|
|
185
|
-
items: [
|
|
231
|
+
'items': [
|
|
186
232
|
{
|
|
187
233
|
firstname: 'Virginie',
|
|
188
234
|
lastname: 'Beauchesne',
|
|
@@ -214,15 +260,16 @@ export const Default: Story = {
|
|
|
214
260
|
email: 'agate.roy@exemple.com',
|
|
215
261
|
},
|
|
216
262
|
],
|
|
217
|
-
options: {
|
|
263
|
+
'options': {
|
|
218
264
|
itemsPerPage: 4,
|
|
219
265
|
},
|
|
220
|
-
caption: '',
|
|
221
|
-
suffix: 'default-table',
|
|
222
|
-
density: 'default',
|
|
223
|
-
striped: false,
|
|
266
|
+
'caption': '',
|
|
267
|
+
'suffix': 'default-table',
|
|
268
|
+
'density': 'default',
|
|
269
|
+
'striped': false,
|
|
270
|
+
'onUpdate:options': fn(),
|
|
224
271
|
},
|
|
225
|
-
render(args) {
|
|
272
|
+
render: (args) => {
|
|
226
273
|
return {
|
|
227
274
|
components: { SyTable },
|
|
228
275
|
setup() {
|
|
@@ -231,13 +278,7 @@ export const Default: Story = {
|
|
|
231
278
|
template: `
|
|
232
279
|
<SyTable
|
|
233
280
|
v-model:options="args.options"
|
|
234
|
-
|
|
235
|
-
:items="args.items"
|
|
236
|
-
:caption="args.caption"
|
|
237
|
-
:suffix="args.suffix"
|
|
238
|
-
:density="args.density"
|
|
239
|
-
:striped="args.striped"
|
|
240
|
-
:resizable-columns="args.resizableColumns"
|
|
281
|
+
v-bind="args"
|
|
241
282
|
/>
|
|
242
283
|
`,
|
|
243
284
|
}
|
|
@@ -331,7 +372,7 @@ export const SortBy: Story = {
|
|
|
331
372
|
],
|
|
332
373
|
},
|
|
333
374
|
args: {
|
|
334
|
-
headers: [
|
|
375
|
+
'headers': [
|
|
335
376
|
{
|
|
336
377
|
title: 'Nom',
|
|
337
378
|
key: 'lastname',
|
|
@@ -345,7 +386,7 @@ export const SortBy: Story = {
|
|
|
345
386
|
value: 'email',
|
|
346
387
|
},
|
|
347
388
|
],
|
|
348
|
-
items: [
|
|
389
|
+
'items': [
|
|
349
390
|
{
|
|
350
391
|
firstname: 'Virginie',
|
|
351
392
|
lastname: 'Beauchesne',
|
|
@@ -377,8 +418,8 @@ export const SortBy: Story = {
|
|
|
377
418
|
email: 'agate.roy@exemple.com',
|
|
378
419
|
},
|
|
379
420
|
],
|
|
380
|
-
caption: '',
|
|
381
|
-
options: {
|
|
421
|
+
'caption': '',
|
|
422
|
+
'options': {
|
|
382
423
|
itemsPerPage: 4,
|
|
383
424
|
sortBy: [
|
|
384
425
|
{
|
|
@@ -387,11 +428,12 @@ export const SortBy: Story = {
|
|
|
387
428
|
},
|
|
388
429
|
],
|
|
389
430
|
},
|
|
390
|
-
suffix: 'sort-table',
|
|
391
|
-
density: 'default',
|
|
392
|
-
striped: false,
|
|
431
|
+
'suffix': 'sort-table',
|
|
432
|
+
'density': 'default',
|
|
433
|
+
'striped': false,
|
|
434
|
+
'onUpdate:options': fn(),
|
|
393
435
|
},
|
|
394
|
-
render(args) {
|
|
436
|
+
render: (args) => {
|
|
395
437
|
return {
|
|
396
438
|
components: { SyTable },
|
|
397
439
|
setup() {
|
|
@@ -400,19 +442,233 @@ export const SortBy: Story = {
|
|
|
400
442
|
template: `
|
|
401
443
|
<SyTable
|
|
402
444
|
v-model:options="args.options"
|
|
403
|
-
|
|
404
|
-
:items="args.items"
|
|
405
|
-
:caption="args.caption"
|
|
406
|
-
:suffix="args.suffix"
|
|
407
|
-
:density="args.density"
|
|
408
|
-
:striped="args.striped"
|
|
409
|
-
:resizable-columns="args.resizableColumns"
|
|
445
|
+
v-bind="args"
|
|
410
446
|
/>
|
|
411
447
|
`,
|
|
412
448
|
}
|
|
413
449
|
},
|
|
414
450
|
}
|
|
415
451
|
|
|
452
|
+
export const MultiSort: Story = {
|
|
453
|
+
parameters: {
|
|
454
|
+
sourceCode: [
|
|
455
|
+
{
|
|
456
|
+
name: 'Template',
|
|
457
|
+
code: `
|
|
458
|
+
<template>
|
|
459
|
+
<div>
|
|
460
|
+
<p class="mb-4">
|
|
461
|
+
Cet exemple montre le tri multiple avec des indicateurs d'ordre de priorité.
|
|
462
|
+
Les chiffres à côté des icônes de tri indiquent l'ordre de priorité du tri.
|
|
463
|
+
</p>
|
|
464
|
+
<SyTable
|
|
465
|
+
v-model:options="options"
|
|
466
|
+
:headers="headers"
|
|
467
|
+
:items="items"
|
|
468
|
+
:multi-sort="true"
|
|
469
|
+
suffix="multi-sort-table"
|
|
470
|
+
/>
|
|
471
|
+
</div>
|
|
472
|
+
</template>
|
|
473
|
+
`,
|
|
474
|
+
},
|
|
475
|
+
{
|
|
476
|
+
name: 'Script',
|
|
477
|
+
code: `
|
|
478
|
+
<script setup lang="ts">
|
|
479
|
+
import { ref } from 'vue'
|
|
480
|
+
import { SyTable } from '@cnamts/synapse'
|
|
481
|
+
|
|
482
|
+
const options = ref({
|
|
483
|
+
itemsPerPage: 4,
|
|
484
|
+
multiSort: true,
|
|
485
|
+
sortBy: [
|
|
486
|
+
{
|
|
487
|
+
key: 'lastname',
|
|
488
|
+
order: 'desc',
|
|
489
|
+
},
|
|
490
|
+
{
|
|
491
|
+
key: 'firstname',
|
|
492
|
+
order: 'asc',
|
|
493
|
+
},
|
|
494
|
+
],
|
|
495
|
+
})
|
|
496
|
+
|
|
497
|
+
const headers = ref([
|
|
498
|
+
{
|
|
499
|
+
title: 'Nom',
|
|
500
|
+
key: 'lastname',
|
|
501
|
+
},
|
|
502
|
+
{
|
|
503
|
+
title: 'Prénom',
|
|
504
|
+
key: 'firstname',
|
|
505
|
+
},
|
|
506
|
+
{
|
|
507
|
+
title: 'Email',
|
|
508
|
+
value: 'email',
|
|
509
|
+
},
|
|
510
|
+
{
|
|
511
|
+
title: 'Ville',
|
|
512
|
+
key: 'city',
|
|
513
|
+
},
|
|
514
|
+
])
|
|
515
|
+
|
|
516
|
+
const items = ref([
|
|
517
|
+
{
|
|
518
|
+
firstname: 'Virginie',
|
|
519
|
+
lastname: 'Beauchesne',
|
|
520
|
+
email: 'virginie.beauchesne@example.com',
|
|
521
|
+
city: 'Paris',
|
|
522
|
+
},
|
|
523
|
+
{
|
|
524
|
+
firstname: 'Simone',
|
|
525
|
+
lastname: 'Bellefeuille',
|
|
526
|
+
email: 'simone.bellefeuille@example.com',
|
|
527
|
+
city: 'Lyon',
|
|
528
|
+
},
|
|
529
|
+
{
|
|
530
|
+
firstname: 'Étienne',
|
|
531
|
+
lastname: 'Salois',
|
|
532
|
+
email: 'etienne.salois@example.com',
|
|
533
|
+
city: 'Marseille',
|
|
534
|
+
},
|
|
535
|
+
{
|
|
536
|
+
firstname: 'Thierry',
|
|
537
|
+
lastname: 'Bobu',
|
|
538
|
+
email: 'thierry.bobu@example.com',
|
|
539
|
+
city: 'Toulouse',
|
|
540
|
+
},
|
|
541
|
+
{
|
|
542
|
+
firstname: 'Bernadette',
|
|
543
|
+
lastname: 'Langelier',
|
|
544
|
+
email: 'bernadette.langelier@exemple.com',
|
|
545
|
+
city: 'Nice',
|
|
546
|
+
},
|
|
547
|
+
{
|
|
548
|
+
firstname: 'Agate',
|
|
549
|
+
lastname: 'Roy',
|
|
550
|
+
email: 'agate.roy@exemple.com',
|
|
551
|
+
city: 'Bordeaux',
|
|
552
|
+
},
|
|
553
|
+
{
|
|
554
|
+
firstname: 'Agate',
|
|
555
|
+
lastname: 'Beauchesne',
|
|
556
|
+
email: 'agate.beauchesne@exemple.com',
|
|
557
|
+
city: 'Lille',
|
|
558
|
+
}
|
|
559
|
+
])
|
|
560
|
+
</script>
|
|
561
|
+
`,
|
|
562
|
+
},
|
|
563
|
+
],
|
|
564
|
+
},
|
|
565
|
+
args: {
|
|
566
|
+
'headers': [
|
|
567
|
+
{
|
|
568
|
+
title: 'Nom',
|
|
569
|
+
key: 'lastname',
|
|
570
|
+
},
|
|
571
|
+
{
|
|
572
|
+
title: 'Prénom',
|
|
573
|
+
key: 'firstname',
|
|
574
|
+
},
|
|
575
|
+
{
|
|
576
|
+
title: 'Email',
|
|
577
|
+
value: 'email',
|
|
578
|
+
},
|
|
579
|
+
{
|
|
580
|
+
title: 'Ville',
|
|
581
|
+
key: 'city',
|
|
582
|
+
},
|
|
583
|
+
],
|
|
584
|
+
'items': [
|
|
585
|
+
{
|
|
586
|
+
firstname: 'Virginie',
|
|
587
|
+
lastname: 'Beauchesne',
|
|
588
|
+
email: 'virginie.beauchesne@example.com',
|
|
589
|
+
city: 'Paris',
|
|
590
|
+
},
|
|
591
|
+
{
|
|
592
|
+
firstname: 'Simone',
|
|
593
|
+
lastname: 'Bellefeuille',
|
|
594
|
+
email: 'simone.bellefeuille@example.com',
|
|
595
|
+
city: 'Lyon',
|
|
596
|
+
},
|
|
597
|
+
{
|
|
598
|
+
firstname: 'Étienne',
|
|
599
|
+
lastname: 'Salois',
|
|
600
|
+
email: 'etienne.salois@example.com',
|
|
601
|
+
city: 'Marseille',
|
|
602
|
+
},
|
|
603
|
+
{
|
|
604
|
+
firstname: 'Thierry',
|
|
605
|
+
lastname: 'Bobu',
|
|
606
|
+
email: 'thierry.bobu@example.com',
|
|
607
|
+
city: 'Toulouse',
|
|
608
|
+
},
|
|
609
|
+
{
|
|
610
|
+
firstname: 'Bernadette',
|
|
611
|
+
lastname: 'Langelier',
|
|
612
|
+
email: 'bernadette.langelier@exemple.com',
|
|
613
|
+
city: 'Nice',
|
|
614
|
+
},
|
|
615
|
+
{
|
|
616
|
+
firstname: 'Agate',
|
|
617
|
+
lastname: 'Roy',
|
|
618
|
+
email: 'agate.roy@exemple.com',
|
|
619
|
+
city: 'Bordeaux',
|
|
620
|
+
},
|
|
621
|
+
{
|
|
622
|
+
firstname: 'Agate',
|
|
623
|
+
lastname: 'Beauchesne',
|
|
624
|
+
email: 'agate.beauchesne@exemple.com',
|
|
625
|
+
city: 'Lille',
|
|
626
|
+
},
|
|
627
|
+
],
|
|
628
|
+
'caption': '',
|
|
629
|
+
'options': {
|
|
630
|
+
itemsPerPage: 4,
|
|
631
|
+
multiSort: true,
|
|
632
|
+
sortBy: [
|
|
633
|
+
{
|
|
634
|
+
key: 'lastname',
|
|
635
|
+
order: 'desc',
|
|
636
|
+
},
|
|
637
|
+
{
|
|
638
|
+
key: 'firstname',
|
|
639
|
+
order: 'asc',
|
|
640
|
+
},
|
|
641
|
+
],
|
|
642
|
+
},
|
|
643
|
+
'suffix': 'multi-sort-table',
|
|
644
|
+
'density': 'default',
|
|
645
|
+
'striped': false,
|
|
646
|
+
'multiSort': true,
|
|
647
|
+
'onUpdate:options': fn(),
|
|
648
|
+
},
|
|
649
|
+
render: (args) => {
|
|
650
|
+
return {
|
|
651
|
+
components: { SyTable },
|
|
652
|
+
setup() {
|
|
653
|
+
return { args }
|
|
654
|
+
},
|
|
655
|
+
template: `
|
|
656
|
+
<div>
|
|
657
|
+
<p class="mb-4">
|
|
658
|
+
Cet exemple montre le tri multiple avec des indicateurs d'ordre de priorité.
|
|
659
|
+
Les chiffres à côté des icônes de tri indiquent l'ordre de priorité du tri.
|
|
660
|
+
</p>
|
|
661
|
+
<SyTable
|
|
662
|
+
v-model:options="args.options"
|
|
663
|
+
v-bind="args"
|
|
664
|
+
suffix="multi-sort-table"
|
|
665
|
+
/>
|
|
666
|
+
</div>
|
|
667
|
+
`,
|
|
668
|
+
}
|
|
669
|
+
},
|
|
670
|
+
}
|
|
671
|
+
|
|
416
672
|
export const FilterByText: Story = {
|
|
417
673
|
parameters: {
|
|
418
674
|
sourceCode: [
|
|
@@ -501,7 +757,7 @@ export const FilterByText: Story = {
|
|
|
501
757
|
],
|
|
502
758
|
},
|
|
503
759
|
args: {
|
|
504
|
-
headers: [
|
|
760
|
+
'headers': [
|
|
505
761
|
{
|
|
506
762
|
title: 'Nom',
|
|
507
763
|
key: 'lastname',
|
|
@@ -521,7 +777,7 @@ export const FilterByText: Story = {
|
|
|
521
777
|
filterType: 'text',
|
|
522
778
|
},
|
|
523
779
|
],
|
|
524
|
-
items: [
|
|
780
|
+
'items': [
|
|
525
781
|
{
|
|
526
782
|
firstname: 'Virginie',
|
|
527
783
|
lastname: 'Beauchesne',
|
|
@@ -553,17 +809,18 @@ export const FilterByText: Story = {
|
|
|
553
809
|
email: 'agate.roy@exemple.com',
|
|
554
810
|
},
|
|
555
811
|
],
|
|
556
|
-
caption: '',
|
|
557
|
-
options: {
|
|
812
|
+
'caption': '',
|
|
813
|
+
'options': {
|
|
558
814
|
itemsPerPage: 4,
|
|
559
815
|
filters: [],
|
|
560
816
|
},
|
|
561
|
-
showFilters: true,
|
|
562
|
-
suffix: 'filter-text-table',
|
|
563
|
-
density: 'default',
|
|
564
|
-
striped: false,
|
|
817
|
+
'showFilters': true,
|
|
818
|
+
'suffix': 'filter-text-table',
|
|
819
|
+
'density': 'default',
|
|
820
|
+
'striped': false,
|
|
821
|
+
'onUpdate:options': fn(),
|
|
565
822
|
},
|
|
566
|
-
render(args) {
|
|
823
|
+
render: (args) => {
|
|
567
824
|
return {
|
|
568
825
|
components: { SyTable },
|
|
569
826
|
setup() {
|
|
@@ -579,15 +836,9 @@ export const FilterByText: Story = {
|
|
|
579
836
|
},
|
|
580
837
|
template: `
|
|
581
838
|
<SyTable
|
|
582
|
-
v-model:options="options"
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
:caption="args.caption"
|
|
586
|
-
:show-filters="args.showFilters"
|
|
587
|
-
:suffix="args.suffix"
|
|
588
|
-
:density="args.density"
|
|
589
|
-
:striped="args.striped"
|
|
590
|
-
:resizable-columns="args.resizableColumns"
|
|
839
|
+
v-model:options="args.options"
|
|
840
|
+
v-bind="args"
|
|
841
|
+
suffix="filter-text-table"
|
|
591
842
|
/>
|
|
592
843
|
`,
|
|
593
844
|
}
|
|
@@ -677,7 +928,7 @@ export const FilterByNumber: Story = {
|
|
|
677
928
|
],
|
|
678
929
|
},
|
|
679
930
|
args: {
|
|
680
|
-
headers: [
|
|
931
|
+
'headers': [
|
|
681
932
|
{
|
|
682
933
|
title: 'Nom',
|
|
683
934
|
key: 'name',
|
|
@@ -697,7 +948,7 @@ export const FilterByNumber: Story = {
|
|
|
697
948
|
filterType: 'number',
|
|
698
949
|
},
|
|
699
950
|
],
|
|
700
|
-
items: [
|
|
951
|
+
'items': [
|
|
701
952
|
{
|
|
702
953
|
name: 'Jean Dupont',
|
|
703
954
|
age: 32,
|
|
@@ -724,17 +975,18 @@ export const FilterByNumber: Story = {
|
|
|
724
975
|
salary: 58000,
|
|
725
976
|
},
|
|
726
977
|
],
|
|
727
|
-
caption: '',
|
|
728
|
-
options: {
|
|
978
|
+
'caption': '',
|
|
979
|
+
'options': {
|
|
729
980
|
itemsPerPage: 5,
|
|
730
981
|
filters: [],
|
|
731
982
|
},
|
|
732
|
-
showFilters: true,
|
|
733
|
-
suffix: 'filter-number-table',
|
|
734
|
-
density: 'default',
|
|
735
|
-
striped: false,
|
|
983
|
+
'showFilters': true,
|
|
984
|
+
'suffix': 'filter-number-table',
|
|
985
|
+
'density': 'default',
|
|
986
|
+
'striped': false,
|
|
987
|
+
'onUpdate:options': fn(),
|
|
736
988
|
},
|
|
737
|
-
render(args) {
|
|
989
|
+
render: (args) => {
|
|
738
990
|
return {
|
|
739
991
|
components: { SyTable },
|
|
740
992
|
setup() {
|
|
@@ -750,15 +1002,9 @@ export const FilterByNumber: Story = {
|
|
|
750
1002
|
},
|
|
751
1003
|
template: `
|
|
752
1004
|
<SyTable
|
|
753
|
-
v-model:options="options"
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
:caption="args.caption"
|
|
757
|
-
:show-filters="args.showFilters"
|
|
758
|
-
:suffix="args.suffix"
|
|
759
|
-
:density="args.density"
|
|
760
|
-
:striped="args.striped"
|
|
761
|
-
:resizable-columns="args.resizableColumns"
|
|
1005
|
+
v-model:options="args.options"
|
|
1006
|
+
v-bind="args"
|
|
1007
|
+
suffix="filter-number-table"
|
|
762
1008
|
/>
|
|
763
1009
|
`,
|
|
764
1010
|
}
|
|
@@ -861,7 +1107,7 @@ export const FilterBySelect: Story = {
|
|
|
861
1107
|
],
|
|
862
1108
|
},
|
|
863
1109
|
args: {
|
|
864
|
-
headers: [
|
|
1110
|
+
'headers': [
|
|
865
1111
|
{
|
|
866
1112
|
title: 'Nom',
|
|
867
1113
|
key: 'name',
|
|
@@ -894,7 +1140,7 @@ export const FilterBySelect: Story = {
|
|
|
894
1140
|
],
|
|
895
1141
|
},
|
|
896
1142
|
],
|
|
897
|
-
items: [
|
|
1143
|
+
'items': [
|
|
898
1144
|
{
|
|
899
1145
|
name: 'Jean Dupont',
|
|
900
1146
|
department: 'RH',
|
|
@@ -921,17 +1167,18 @@ export const FilterBySelect: Story = {
|
|
|
921
1167
|
status: 'Inactif',
|
|
922
1168
|
},
|
|
923
1169
|
],
|
|
924
|
-
caption: '',
|
|
925
|
-
options: {
|
|
1170
|
+
'caption': '',
|
|
1171
|
+
'options': {
|
|
926
1172
|
itemsPerPage: 5,
|
|
927
1173
|
filters: [],
|
|
928
1174
|
},
|
|
929
|
-
showFilters: true,
|
|
930
|
-
suffix: 'filter-select-table',
|
|
931
|
-
density: 'default',
|
|
932
|
-
striped: false,
|
|
1175
|
+
'showFilters': true,
|
|
1176
|
+
'suffix': 'filter-select-table',
|
|
1177
|
+
'density': 'default',
|
|
1178
|
+
'striped': false,
|
|
1179
|
+
'onUpdate:options': fn(),
|
|
933
1180
|
},
|
|
934
|
-
render(args) {
|
|
1181
|
+
render: (args) => {
|
|
935
1182
|
return {
|
|
936
1183
|
components: { SyTable },
|
|
937
1184
|
setup() {
|
|
@@ -947,22 +1194,16 @@ export const FilterBySelect: Story = {
|
|
|
947
1194
|
},
|
|
948
1195
|
template: `
|
|
949
1196
|
<SyTable
|
|
950
|
-
v-model:options="options"
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
:caption="args.caption"
|
|
954
|
-
:show-filters="args.showFilters"
|
|
955
|
-
:suffix="args.suffix"
|
|
956
|
-
:density="args.density"
|
|
957
|
-
:striped="args.striped"
|
|
958
|
-
:resizable-columns="args.resizableColumns"
|
|
1197
|
+
v-model:options="args.options"
|
|
1198
|
+
v-bind="args"
|
|
1199
|
+
suffix="filter-select-table"
|
|
959
1200
|
/>
|
|
960
1201
|
`,
|
|
961
1202
|
}
|
|
962
1203
|
},
|
|
963
1204
|
}
|
|
964
1205
|
|
|
965
|
-
export const
|
|
1206
|
+
export const FilterBySelectMultiple: Story = {
|
|
966
1207
|
parameters: {
|
|
967
1208
|
sourceCode: [
|
|
968
1209
|
{
|
|
@@ -973,8 +1214,208 @@ export const FilterByDate: Story = {
|
|
|
973
1214
|
v-model:options="options"
|
|
974
1215
|
:headers="headers"
|
|
975
1216
|
:items="items"
|
|
976
|
-
|
|
977
|
-
suffix="filter-
|
|
1217
|
+
show-filters
|
|
1218
|
+
suffix="filter-select-table"
|
|
1219
|
+
/>
|
|
1220
|
+
</template>
|
|
1221
|
+
`,
|
|
1222
|
+
},
|
|
1223
|
+
{
|
|
1224
|
+
name: 'Script',
|
|
1225
|
+
code: `
|
|
1226
|
+
<script setup lang="ts">
|
|
1227
|
+
import { ref } from 'vue'
|
|
1228
|
+
import { SyTable } from '@cnamts/synapse'
|
|
1229
|
+
|
|
1230
|
+
const options = ref({
|
|
1231
|
+
itemsPerPage: 5,
|
|
1232
|
+
filters: []
|
|
1233
|
+
})
|
|
1234
|
+
|
|
1235
|
+
const headers = ref([
|
|
1236
|
+
{
|
|
1237
|
+
title: 'Nom',
|
|
1238
|
+
key: 'name',
|
|
1239
|
+
filterable: true,
|
|
1240
|
+
filterType: 'text'
|
|
1241
|
+
},
|
|
1242
|
+
{
|
|
1243
|
+
title: 'Département',
|
|
1244
|
+
key: 'department',
|
|
1245
|
+
filterable: true,
|
|
1246
|
+
filterType: 'select',
|
|
1247
|
+
multiple: true,
|
|
1248
|
+
chips: true,
|
|
1249
|
+
hideMessages: true,
|
|
1250
|
+
filterOptions: [
|
|
1251
|
+
{ text: 'RH', value: 'RH' },
|
|
1252
|
+
{ text: 'IT', value: 'IT' },
|
|
1253
|
+
{ text: 'Finance', value: 'Finance' },
|
|
1254
|
+
{ text: 'Marketing', value: 'Marketing' },
|
|
1255
|
+
]
|
|
1256
|
+
},
|
|
1257
|
+
{
|
|
1258
|
+
title: 'Statut',
|
|
1259
|
+
key: 'status',
|
|
1260
|
+
filterable: true,
|
|
1261
|
+
multiple: true,
|
|
1262
|
+
chips: true,
|
|
1263
|
+
filterType: 'select',
|
|
1264
|
+
hideMessages: true,
|
|
1265
|
+
filterOptions: [
|
|
1266
|
+
{ text: 'Actif', value: 'Actif' },
|
|
1267
|
+
{ text: 'En congé', value: 'En congé' },
|
|
1268
|
+
{ text: 'Inactif', value: 'Inactif' },
|
|
1269
|
+
]
|
|
1270
|
+
},
|
|
1271
|
+
])
|
|
1272
|
+
|
|
1273
|
+
const items = ref([
|
|
1274
|
+
{
|
|
1275
|
+
name: 'Jean Dupont',
|
|
1276
|
+
department: 'RH',
|
|
1277
|
+
status: 'Actif',
|
|
1278
|
+
},
|
|
1279
|
+
{
|
|
1280
|
+
name: 'Marie Martin',
|
|
1281
|
+
department: 'IT',
|
|
1282
|
+
status: 'En congé',
|
|
1283
|
+
},
|
|
1284
|
+
{
|
|
1285
|
+
name: 'Pierre Durand',
|
|
1286
|
+
department: 'Finance',
|
|
1287
|
+
status: 'Actif',
|
|
1288
|
+
},
|
|
1289
|
+
{
|
|
1290
|
+
name: 'Sophie Petit',
|
|
1291
|
+
department: 'Marketing',
|
|
1292
|
+
status: 'Actif',
|
|
1293
|
+
},
|
|
1294
|
+
{
|
|
1295
|
+
name: 'Thomas Leroy',
|
|
1296
|
+
department: 'IT',
|
|
1297
|
+
status: 'Inactif',
|
|
1298
|
+
},
|
|
1299
|
+
])
|
|
1300
|
+
</script>
|
|
1301
|
+
`,
|
|
1302
|
+
},
|
|
1303
|
+
],
|
|
1304
|
+
},
|
|
1305
|
+
args: {
|
|
1306
|
+
'headers': [
|
|
1307
|
+
{
|
|
1308
|
+
title: 'Nom',
|
|
1309
|
+
key: 'name',
|
|
1310
|
+
filterable: true,
|
|
1311
|
+
filterType: 'text',
|
|
1312
|
+
},
|
|
1313
|
+
{
|
|
1314
|
+
title: 'Département',
|
|
1315
|
+
key: 'department',
|
|
1316
|
+
filterable: true,
|
|
1317
|
+
filterType: 'select',
|
|
1318
|
+
multiple: true,
|
|
1319
|
+
chips: true,
|
|
1320
|
+
hideMessages: true,
|
|
1321
|
+
filterOptions: [
|
|
1322
|
+
{ text: 'RH', value: 'RH' },
|
|
1323
|
+
{ text: 'IT', value: 'IT' },
|
|
1324
|
+
{ text: 'Finance', value: 'Finance' },
|
|
1325
|
+
{ text: 'Marketing', value: 'Marketing' },
|
|
1326
|
+
],
|
|
1327
|
+
},
|
|
1328
|
+
{
|
|
1329
|
+
title: 'Statut',
|
|
1330
|
+
key: 'status',
|
|
1331
|
+
filterable: true,
|
|
1332
|
+
filterType: 'select',
|
|
1333
|
+
multiple: true,
|
|
1334
|
+
chips: true,
|
|
1335
|
+
hideMessages: true,
|
|
1336
|
+
filterOptions: [
|
|
1337
|
+
{ text: 'Actif', value: 'Actif' },
|
|
1338
|
+
{ text: 'En congé', value: 'En congé' },
|
|
1339
|
+
{ text: 'Inactif', value: 'Inactif' },
|
|
1340
|
+
],
|
|
1341
|
+
},
|
|
1342
|
+
],
|
|
1343
|
+
'items': [
|
|
1344
|
+
{
|
|
1345
|
+
name: 'Jean Dupont',
|
|
1346
|
+
department: 'RH',
|
|
1347
|
+
status: 'Actif',
|
|
1348
|
+
},
|
|
1349
|
+
{
|
|
1350
|
+
name: 'Marie Martin',
|
|
1351
|
+
department: 'IT',
|
|
1352
|
+
status: 'En congé',
|
|
1353
|
+
},
|
|
1354
|
+
{
|
|
1355
|
+
name: 'Pierre Durand',
|
|
1356
|
+
department: 'Finance',
|
|
1357
|
+
status: 'Actif',
|
|
1358
|
+
},
|
|
1359
|
+
{
|
|
1360
|
+
name: 'Sophie Petit',
|
|
1361
|
+
department: 'Marketing',
|
|
1362
|
+
status: 'Actif',
|
|
1363
|
+
},
|
|
1364
|
+
{
|
|
1365
|
+
name: 'Thomas Leroy',
|
|
1366
|
+
department: 'IT',
|
|
1367
|
+
status: 'Inactif',
|
|
1368
|
+
},
|
|
1369
|
+
],
|
|
1370
|
+
'caption': '',
|
|
1371
|
+
'options': {
|
|
1372
|
+
itemsPerPage: 5,
|
|
1373
|
+
filters: [],
|
|
1374
|
+
},
|
|
1375
|
+
'showFilters': true,
|
|
1376
|
+
'suffix': 'filter-select-table',
|
|
1377
|
+
'density': 'default',
|
|
1378
|
+
'striped': false,
|
|
1379
|
+
'onUpdate:options': fn(),
|
|
1380
|
+
},
|
|
1381
|
+
render: (args) => {
|
|
1382
|
+
return {
|
|
1383
|
+
components: { SyTable },
|
|
1384
|
+
setup() {
|
|
1385
|
+
// Create reactive references
|
|
1386
|
+
const options = ref(args.options)
|
|
1387
|
+
const items = ref(args.items)
|
|
1388
|
+
|
|
1389
|
+
return {
|
|
1390
|
+
args,
|
|
1391
|
+
options,
|
|
1392
|
+
items,
|
|
1393
|
+
}
|
|
1394
|
+
},
|
|
1395
|
+
template: `
|
|
1396
|
+
<SyTable
|
|
1397
|
+
v-model:options="args.options"
|
|
1398
|
+
v-bind="args"
|
|
1399
|
+
suffix="filter-select-table"
|
|
1400
|
+
/>
|
|
1401
|
+
`,
|
|
1402
|
+
}
|
|
1403
|
+
},
|
|
1404
|
+
}
|
|
1405
|
+
|
|
1406
|
+
export const FilterByExactDate: Story = {
|
|
1407
|
+
parameters: {
|
|
1408
|
+
sourceCode: [
|
|
1409
|
+
{
|
|
1410
|
+
name: 'Template',
|
|
1411
|
+
code: `
|
|
1412
|
+
<template>
|
|
1413
|
+
<SyTable
|
|
1414
|
+
v-model:options="options"
|
|
1415
|
+
:headers="headers"
|
|
1416
|
+
:items="items"
|
|
1417
|
+
:show-filters="true"
|
|
1418
|
+
suffix="filter-date-table"
|
|
978
1419
|
/>
|
|
979
1420
|
</template>
|
|
980
1421
|
`,
|
|
@@ -1006,55 +1447,28 @@ export const FilterByDate: Story = {
|
|
|
1006
1447
|
filterType: 'date',
|
|
1007
1448
|
dateFormat: 'DD/MM/YYYY',
|
|
1008
1449
|
},
|
|
1009
|
-
{
|
|
1010
|
-
title: 'Période de congés',
|
|
1011
|
-
key: 'vacationPeriod',
|
|
1012
|
-
filterable: true,
|
|
1013
|
-
filterType: 'period',
|
|
1014
|
-
dateFormat: 'DD/MM/YYYY',
|
|
1015
|
-
},
|
|
1016
1450
|
])
|
|
1017
1451
|
|
|
1018
1452
|
const items = ref([
|
|
1019
1453
|
{
|
|
1020
1454
|
name: 'Jean Dupont',
|
|
1021
1455
|
hireDate: dayjs('2020-05-15').format('DD/MM/YYYY'),
|
|
1022
|
-
vacationPeriod: {
|
|
1023
|
-
from: dayjs('2023-07-01').format('DD/MM/YYYY'),
|
|
1024
|
-
to: dayjs('2023-07-15').format('DD/MM/YYYY')
|
|
1025
|
-
},
|
|
1026
1456
|
},
|
|
1027
1457
|
{
|
|
1028
1458
|
name: 'Marie Martin',
|
|
1029
1459
|
hireDate: dayjs('2019-03-10').format('DD/MM/YYYY'),
|
|
1030
|
-
vacationPeriod: {
|
|
1031
|
-
from: dayjs('2023-08-01').format('DD/MM/YYYY'),
|
|
1032
|
-
to: dayjs('2023-08-20').format('DD/MM/YYYY'),
|
|
1033
|
-
},
|
|
1034
1460
|
},
|
|
1035
1461
|
{
|
|
1036
1462
|
name: 'Pierre Dupont',
|
|
1037
1463
|
hireDate: dayjs('2025-11-22').format('DD/MM/YYYY'),
|
|
1038
|
-
vacationPeriod: {
|
|
1039
|
-
from: dayjs('2025-06-15').format('DD/MM/YYYY'),
|
|
1040
|
-
to: dayjs('2025-07-05').format('DD/MM/YYYY'),
|
|
1041
|
-
},
|
|
1042
1464
|
},
|
|
1043
1465
|
{
|
|
1044
1466
|
name: 'Sophie Garnier',
|
|
1045
1467
|
hireDate: dayjs('2025-01-08').format('DD/MM/YYYY'),
|
|
1046
|
-
vacationPeriod: {
|
|
1047
|
-
from: dayjs('2025-12-20').format('DD/MM/YYYY'),
|
|
1048
|
-
to: dayjs('2025-01-05').format('DD/MM/YYYY'),
|
|
1049
|
-
},
|
|
1050
1468
|
},
|
|
1051
1469
|
{
|
|
1052
1470
|
name: 'Thomas Leroy',
|
|
1053
1471
|
hireDate: dayjs('2025-07-30').format('DD/MM/YYYY'),
|
|
1054
|
-
vacationPeriod: {
|
|
1055
|
-
from: dayjs('2025-09-10').format('DD/MM/YYYY'),
|
|
1056
|
-
to: dayjs('2025-09-25').format('DD/MM/YYYY'),
|
|
1057
|
-
},
|
|
1058
1472
|
},
|
|
1059
1473
|
])
|
|
1060
1474
|
</script>
|
|
@@ -1063,7 +1477,7 @@ export const FilterByDate: Story = {
|
|
|
1063
1477
|
],
|
|
1064
1478
|
},
|
|
1065
1479
|
args: {
|
|
1066
|
-
headers: [
|
|
1480
|
+
'headers': [
|
|
1067
1481
|
{
|
|
1068
1482
|
title: 'Nom',
|
|
1069
1483
|
key: 'name',
|
|
@@ -1077,67 +1491,41 @@ export const FilterByDate: Story = {
|
|
|
1077
1491
|
filterType: 'date',
|
|
1078
1492
|
dateFormat: 'DD/MM/YYYY',
|
|
1079
1493
|
},
|
|
1080
|
-
{
|
|
1081
|
-
title: 'Période de congés',
|
|
1082
|
-
key: 'vacationPeriod',
|
|
1083
|
-
filterable: true,
|
|
1084
|
-
filterType: 'period',
|
|
1085
|
-
dateFormat: 'DD/MM/YYYY',
|
|
1086
|
-
},
|
|
1087
1494
|
],
|
|
1088
|
-
items: [
|
|
1495
|
+
'items': [
|
|
1089
1496
|
{
|
|
1090
1497
|
name: 'Jean Dupont',
|
|
1091
1498
|
hireDate: dayjs('2025-05-15').format('DD/MM/YYYY'),
|
|
1092
|
-
vacationPeriod: {
|
|
1093
|
-
from: dayjs('2025-07-01').format('DD/MM/YYYY'),
|
|
1094
|
-
to: dayjs('2025-07-15').format('DD/MM/YYYY'),
|
|
1095
|
-
},
|
|
1096
1499
|
},
|
|
1097
1500
|
{
|
|
1098
1501
|
name: 'Marie Martin',
|
|
1099
1502
|
hireDate: dayjs('2025-03-10').format('DD/MM/YYYY'),
|
|
1100
|
-
vacationPeriod: {
|
|
1101
|
-
from: dayjs('2025-08-01').format('DD/MM/YYYY'),
|
|
1102
|
-
to: dayjs('2025-08-20').format('DD/MM/YYYY'),
|
|
1103
|
-
},
|
|
1104
1503
|
},
|
|
1105
1504
|
{
|
|
1106
1505
|
name: 'Pierre Durand',
|
|
1107
1506
|
hireDate: dayjs('2025-11-22').format('DD/MM/YYYY'),
|
|
1108
|
-
vacationPeriod: {
|
|
1109
|
-
from: dayjs('2025-06-15').format('DD/MM/YYYY'),
|
|
1110
|
-
to: dayjs('2025-07-05').format('DD/MM/YYYY'),
|
|
1111
|
-
},
|
|
1112
1507
|
},
|
|
1113
1508
|
{
|
|
1114
1509
|
name: 'Sophie Petit',
|
|
1115
1510
|
hireDate: dayjs('2025-01-08').format('DD/MM/YYYY'),
|
|
1116
|
-
vacationPeriod: {
|
|
1117
|
-
from: dayjs('2025-12-20').format('DD/MM/YYYY'),
|
|
1118
|
-
to: dayjs('2025-01-05').format('DD/MM/YYYY'),
|
|
1119
|
-
},
|
|
1120
1511
|
},
|
|
1121
1512
|
{
|
|
1122
1513
|
name: 'Thomas Leroy',
|
|
1123
1514
|
hireDate: dayjs('2025-07-30').format('DD/MM/YYYY'),
|
|
1124
|
-
vacationPeriod: {
|
|
1125
|
-
from: dayjs('2025-09-10').format('DD/MM/YYYY'),
|
|
1126
|
-
to: dayjs('2025-09-25').format('DD/MM/YYYY'),
|
|
1127
|
-
},
|
|
1128
1515
|
},
|
|
1129
1516
|
],
|
|
1130
|
-
caption: '',
|
|
1131
|
-
options: {
|
|
1517
|
+
'caption': '',
|
|
1518
|
+
'options': {
|
|
1132
1519
|
itemsPerPage: 5,
|
|
1133
1520
|
filters: [],
|
|
1134
1521
|
},
|
|
1135
|
-
showFilters: true,
|
|
1136
|
-
suffix: 'filter-date-table',
|
|
1137
|
-
density: 'default',
|
|
1138
|
-
striped: false,
|
|
1522
|
+
'showFilters': true,
|
|
1523
|
+
'suffix': 'filter-date-table',
|
|
1524
|
+
'density': 'default',
|
|
1525
|
+
'striped': false,
|
|
1526
|
+
'onUpdate:options': fn(),
|
|
1139
1527
|
},
|
|
1140
|
-
render(args) {
|
|
1528
|
+
render: (args) => {
|
|
1141
1529
|
return {
|
|
1142
1530
|
components: { SyTable },
|
|
1143
1531
|
setup() {
|
|
@@ -1153,22 +1541,16 @@ export const FilterByDate: Story = {
|
|
|
1153
1541
|
},
|
|
1154
1542
|
template: `
|
|
1155
1543
|
<SyTable
|
|
1156
|
-
v-model:options="options"
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
:caption="args.caption"
|
|
1160
|
-
:show-filters="args.showFilters"
|
|
1161
|
-
:suffix="args.suffix"
|
|
1162
|
-
:density="args.density"
|
|
1163
|
-
:striped="args.striped"
|
|
1164
|
-
:resizable-columns="args.resizableColumns"
|
|
1544
|
+
v-model:options="args.options"
|
|
1545
|
+
v-bind="args"
|
|
1546
|
+
suffix="filter-date-table"
|
|
1165
1547
|
/>
|
|
1166
1548
|
`,
|
|
1167
1549
|
}
|
|
1168
1550
|
},
|
|
1169
1551
|
}
|
|
1170
1552
|
|
|
1171
|
-
export const
|
|
1553
|
+
export const FilterByPeriod: Story = {
|
|
1172
1554
|
parameters: {
|
|
1173
1555
|
sourceCode: [
|
|
1174
1556
|
{
|
|
@@ -1179,38 +1561,1139 @@ export const CustomFilterSlot: Story = {
|
|
|
1179
1561
|
v-model:options="options"
|
|
1180
1562
|
:headers="headers"
|
|
1181
1563
|
:items="items"
|
|
1182
|
-
show-filters
|
|
1183
|
-
suffix="
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1564
|
+
:show-filters="true"
|
|
1565
|
+
suffix="filter-date-table"
|
|
1566
|
+
/>
|
|
1567
|
+
</template>
|
|
1568
|
+
`,
|
|
1569
|
+
},
|
|
1570
|
+
{
|
|
1571
|
+
name: 'Script',
|
|
1572
|
+
code: `
|
|
1573
|
+
<script setup lang="ts">
|
|
1574
|
+
import { ref } from 'vue'
|
|
1575
|
+
import { SyTable } from '@cnamts/synapse'
|
|
1576
|
+
import dayjs from 'dayjs';
|
|
1577
|
+
|
|
1578
|
+
const options = ref({
|
|
1579
|
+
itemsPerPage: 5,
|
|
1580
|
+
filters: [],
|
|
1581
|
+
})
|
|
1582
|
+
|
|
1583
|
+
const headers = ref([
|
|
1584
|
+
{
|
|
1585
|
+
title: 'Nom',
|
|
1586
|
+
key: 'name',
|
|
1587
|
+
filterable: true,
|
|
1588
|
+
filterType: 'text',
|
|
1589
|
+
},
|
|
1590
|
+
{
|
|
1591
|
+
title: 'Date d'embauche',
|
|
1592
|
+
key: 'hireDate',
|
|
1593
|
+
filterable: true,
|
|
1594
|
+
filterType: 'period',
|
|
1595
|
+
dateFormat: 'DD/MM/YYYY',
|
|
1596
|
+
},
|
|
1597
|
+
])
|
|
1598
|
+
|
|
1599
|
+
const items = ref([
|
|
1600
|
+
{
|
|
1601
|
+
name: 'Jean Dupont',
|
|
1602
|
+
hireDate: dayjs('2020-05-15').format('DD/MM/YYYY'),
|
|
1603
|
+
},
|
|
1604
|
+
{
|
|
1605
|
+
name: 'Marie Martin',
|
|
1606
|
+
hireDate: dayjs('2019-03-10').format('DD/MM/YYYY'),
|
|
1607
|
+
},
|
|
1608
|
+
{
|
|
1609
|
+
name: 'Pierre Dupont',
|
|
1610
|
+
hireDate: dayjs('2025-11-22').format('DD/MM/YYYY'),
|
|
1611
|
+
},
|
|
1612
|
+
{
|
|
1613
|
+
name: 'Sophie Garnier',
|
|
1614
|
+
hireDate: dayjs('2025-01-08').format('DD/MM/YYYY'),
|
|
1615
|
+
},
|
|
1616
|
+
{
|
|
1617
|
+
name: 'Thomas Leroy',
|
|
1618
|
+
hireDate: dayjs('2025-07-30').format('DD/MM/YYYY'),
|
|
1619
|
+
},
|
|
1620
|
+
])
|
|
1621
|
+
</script>
|
|
1622
|
+
`,
|
|
1623
|
+
},
|
|
1624
|
+
],
|
|
1625
|
+
},
|
|
1626
|
+
args: {
|
|
1627
|
+
'headers': [
|
|
1628
|
+
{
|
|
1629
|
+
title: 'Nom',
|
|
1630
|
+
key: 'name',
|
|
1631
|
+
filterable: true,
|
|
1632
|
+
filterType: 'text',
|
|
1633
|
+
},
|
|
1634
|
+
{
|
|
1635
|
+
title: 'Date d\'embauche',
|
|
1636
|
+
key: 'hireDate',
|
|
1637
|
+
filterable: true,
|
|
1638
|
+
filterType: 'period',
|
|
1639
|
+
dateFormat: 'DD/MM/YYYY',
|
|
1640
|
+
},
|
|
1641
|
+
],
|
|
1642
|
+
'items': [
|
|
1643
|
+
{
|
|
1644
|
+
name: 'Jean Dupont',
|
|
1645
|
+
hireDate: dayjs('2025-05-15').format('DD/MM/YYYY'),
|
|
1646
|
+
},
|
|
1647
|
+
{
|
|
1648
|
+
name: 'Marie Martin',
|
|
1649
|
+
hireDate: dayjs('2025-03-10').format('DD/MM/YYYY'),
|
|
1650
|
+
},
|
|
1651
|
+
{
|
|
1652
|
+
name: 'Pierre Durand',
|
|
1653
|
+
hireDate: dayjs('2025-11-22').format('DD/MM/YYYY'),
|
|
1654
|
+
},
|
|
1655
|
+
{
|
|
1656
|
+
name: 'Sophie Petit',
|
|
1657
|
+
hireDate: dayjs('2025-01-08').format('DD/MM/YYYY'),
|
|
1658
|
+
},
|
|
1659
|
+
{
|
|
1660
|
+
name: 'Thomas Leroy',
|
|
1661
|
+
hireDate: dayjs('2025-07-30').format('DD/MM/YYYY'),
|
|
1662
|
+
},
|
|
1663
|
+
],
|
|
1664
|
+
'caption': '',
|
|
1665
|
+
'options': {
|
|
1666
|
+
itemsPerPage: 5,
|
|
1667
|
+
filters: [],
|
|
1668
|
+
},
|
|
1669
|
+
'showFilters': true,
|
|
1670
|
+
'suffix': 'filter-date-table',
|
|
1671
|
+
'density': 'default',
|
|
1672
|
+
'striped': false,
|
|
1673
|
+
'onUpdate:options': fn(),
|
|
1674
|
+
},
|
|
1675
|
+
render: (args) => {
|
|
1676
|
+
return {
|
|
1677
|
+
components: { SyTable },
|
|
1678
|
+
setup() {
|
|
1679
|
+
// Create reactive references
|
|
1680
|
+
const options = ref(args.options)
|
|
1681
|
+
const items = ref(args.items)
|
|
1682
|
+
|
|
1683
|
+
return {
|
|
1684
|
+
args,
|
|
1685
|
+
options,
|
|
1686
|
+
items,
|
|
1687
|
+
}
|
|
1688
|
+
},
|
|
1689
|
+
template: `
|
|
1690
|
+
<SyTable
|
|
1691
|
+
v-model:options="args.options"
|
|
1692
|
+
v-bind="args"
|
|
1693
|
+
suffix="filter-date-table"
|
|
1694
|
+
/>
|
|
1695
|
+
`,
|
|
1696
|
+
}
|
|
1697
|
+
},
|
|
1698
|
+
}
|
|
1699
|
+
|
|
1700
|
+
export const CustomFilterSlot: Story = {
|
|
1701
|
+
parameters: {
|
|
1702
|
+
docs: {
|
|
1703
|
+
description: {
|
|
1704
|
+
story: 'Cette story démontre comment utiliser un slot personnalisé pour le filtrage. Le filtre personnalisé utilise un v-select pour filtrer par statut.',
|
|
1705
|
+
},
|
|
1706
|
+
},
|
|
1707
|
+
sourceCode: [
|
|
1708
|
+
{
|
|
1709
|
+
name: 'Template',
|
|
1710
|
+
code: `
|
|
1711
|
+
<template>
|
|
1712
|
+
<SyTable
|
|
1713
|
+
v-model:options="options"
|
|
1714
|
+
:headers="headers"
|
|
1715
|
+
:items="items"
|
|
1716
|
+
show-filters
|
|
1717
|
+
suffix="custom-filter-slot-table"
|
|
1718
|
+
>
|
|
1719
|
+
<template #filter.custom="{ header, updateFilter }">
|
|
1720
|
+
<div class="custom-filter-container">
|
|
1721
|
+
<div class="custom-filter-info mb-2">
|
|
1722
|
+
Filtre personnalisé :
|
|
1723
|
+
</div>
|
|
1724
|
+
<v-select
|
|
1725
|
+
v-model="customFilterValue"
|
|
1726
|
+
:items="statusOptions"
|
|
1727
|
+
label="Statut"
|
|
1728
|
+
variant="outlined"
|
|
1729
|
+
density="compact"
|
|
1730
|
+
color="primary"
|
|
1731
|
+
bg-color="white"
|
|
1732
|
+
@update:model-value="(val) => {
|
|
1733
|
+
// Use updateFilter provided by the slot props
|
|
1734
|
+
updateFilter(val);
|
|
1735
|
+
// Also update our local state
|
|
1736
|
+
handleFilterChange(val);
|
|
1737
|
+
}"
|
|
1738
|
+
/>
|
|
1739
|
+
</div>
|
|
1740
|
+
</template>
|
|
1741
|
+
</SyTable>
|
|
1742
|
+
</template>
|
|
1743
|
+
`,
|
|
1744
|
+
},
|
|
1745
|
+
{
|
|
1746
|
+
name: 'Script',
|
|
1747
|
+
code: `
|
|
1748
|
+
<script setup lang="ts">
|
|
1749
|
+
import { ref } from 'vue'
|
|
1750
|
+
import { SyTable } from '@cnamts/synapse'
|
|
1751
|
+
|
|
1752
|
+
const options = ref({
|
|
1753
|
+
page: 1,
|
|
1754
|
+
itemsPerPage: 4,
|
|
1755
|
+
filters: []
|
|
1756
|
+
})
|
|
1757
|
+
|
|
1758
|
+
const customFilterValue = ref('')
|
|
1759
|
+
const statusOptions = ['Actif', 'Inactif', 'En attente']
|
|
1760
|
+
|
|
1761
|
+
// Function to update the filter when the select value changes
|
|
1762
|
+
function handleFilterChange(val) {
|
|
1763
|
+
// Create a new filters array
|
|
1764
|
+
const newFilters = options.value.filters.filter(f => f.key !== 'status')
|
|
1765
|
+
|
|
1766
|
+
// Add the new filter if a value is selected
|
|
1767
|
+
if (val) {
|
|
1768
|
+
newFilters.push({
|
|
1769
|
+
key: 'status',
|
|
1770
|
+
value: val,
|
|
1771
|
+
type: 'select' // Use 'select' type for compatibility with filtering logic
|
|
1772
|
+
})
|
|
1773
|
+
}
|
|
1774
|
+
|
|
1775
|
+
// Update the options with the new filters
|
|
1776
|
+
options.value = {
|
|
1777
|
+
...options.value,
|
|
1778
|
+
filters: newFilters
|
|
1779
|
+
}
|
|
1780
|
+
}
|
|
1781
|
+
|
|
1782
|
+
const headers = ref([
|
|
1783
|
+
{
|
|
1784
|
+
title: 'Nom',
|
|
1785
|
+
key: 'lastname',
|
|
1786
|
+
filterable: true,
|
|
1787
|
+
filterType: 'text'
|
|
1788
|
+
},
|
|
1789
|
+
{
|
|
1790
|
+
title: 'Prénom',
|
|
1791
|
+
key: 'firstname',
|
|
1792
|
+
filterable: true,
|
|
1793
|
+
filterType: 'text'
|
|
1794
|
+
},
|
|
1795
|
+
{
|
|
1796
|
+
title: 'Statut',
|
|
1797
|
+
key: 'status',
|
|
1798
|
+
filterable: true,
|
|
1799
|
+
filterType: 'custom' // Utilisation du type 'custom' pour activer le slot personnalisé
|
|
1800
|
+
},
|
|
1801
|
+
])
|
|
1802
|
+
|
|
1803
|
+
const items = ref([
|
|
1804
|
+
{
|
|
1805
|
+
firstname: 'Virginie',
|
|
1806
|
+
lastname: 'Beauchesne',
|
|
1807
|
+
status: 'Actif',
|
|
1808
|
+
},
|
|
1809
|
+
{
|
|
1810
|
+
firstname: 'Simone',
|
|
1811
|
+
lastname: 'Bellefeuille',
|
|
1812
|
+
status: 'Inactif',
|
|
1813
|
+
},
|
|
1814
|
+
{
|
|
1815
|
+
firstname: 'Étienne',
|
|
1816
|
+
lastname: 'Salois',
|
|
1817
|
+
status: 'En attente',
|
|
1818
|
+
},
|
|
1819
|
+
{
|
|
1820
|
+
firstname: 'Thierry',
|
|
1821
|
+
lastname: 'Bobu',
|
|
1822
|
+
status: 'Actif',
|
|
1823
|
+
},
|
|
1824
|
+
{
|
|
1825
|
+
firstname: 'Bernadette',
|
|
1826
|
+
lastname: 'Langelier',
|
|
1827
|
+
status: 'Inactif'
|
|
1828
|
+
},
|
|
1829
|
+
{
|
|
1830
|
+
firstname: 'Agate',
|
|
1831
|
+
lastname: 'Roy',
|
|
1832
|
+
status: 'En attente'
|
|
1833
|
+
}
|
|
1834
|
+
])
|
|
1835
|
+
</script>
|
|
1836
|
+
`,
|
|
1837
|
+
},
|
|
1838
|
+
{
|
|
1839
|
+
name: 'Style',
|
|
1840
|
+
code: `
|
|
1841
|
+
<style scoped>
|
|
1842
|
+
.custom-filter-container {
|
|
1843
|
+
display: flex;
|
|
1844
|
+
flex-direction: column;
|
|
1845
|
+
gap: 4px;
|
|
1846
|
+
}
|
|
1847
|
+
|
|
1848
|
+
.custom-filter-info {
|
|
1849
|
+
font-size: 12px;
|
|
1850
|
+
color: #666;
|
|
1851
|
+
margin-top: 4px;
|
|
1852
|
+
}
|
|
1853
|
+
</style>
|
|
1854
|
+
`,
|
|
1855
|
+
},
|
|
1856
|
+
],
|
|
1857
|
+
},
|
|
1858
|
+
args: {
|
|
1859
|
+
'headers': [
|
|
1860
|
+
{
|
|
1861
|
+
title: 'Nom',
|
|
1862
|
+
key: 'lastname',
|
|
1863
|
+
filterable: true,
|
|
1864
|
+
filterType: 'text',
|
|
1865
|
+
},
|
|
1866
|
+
{
|
|
1867
|
+
title: 'Prénom',
|
|
1868
|
+
key: 'firstname',
|
|
1869
|
+
filterable: true,
|
|
1870
|
+
filterType: 'text',
|
|
1871
|
+
},
|
|
1872
|
+
{
|
|
1873
|
+
title: 'Statut',
|
|
1874
|
+
key: 'status',
|
|
1875
|
+
filterable: true,
|
|
1876
|
+
filterType: 'custom',
|
|
1877
|
+
},
|
|
1878
|
+
],
|
|
1879
|
+
'items': [
|
|
1880
|
+
{
|
|
1881
|
+
firstname: 'Virginie',
|
|
1882
|
+
lastname: 'Beauchesne',
|
|
1883
|
+
status: 'Actif',
|
|
1884
|
+
},
|
|
1885
|
+
{
|
|
1886
|
+
firstname: 'Simone',
|
|
1887
|
+
lastname: 'Bellefeuille',
|
|
1888
|
+
status: 'Inactif',
|
|
1889
|
+
},
|
|
1890
|
+
{
|
|
1891
|
+
firstname: 'Étienne',
|
|
1892
|
+
lastname: 'Salois',
|
|
1893
|
+
status: 'En attente',
|
|
1894
|
+
},
|
|
1895
|
+
{
|
|
1896
|
+
firstname: 'Thierry',
|
|
1897
|
+
lastname: 'Bobu',
|
|
1898
|
+
status: 'Actif',
|
|
1899
|
+
},
|
|
1900
|
+
{
|
|
1901
|
+
firstname: 'Bernadette',
|
|
1902
|
+
lastname: 'Langelier',
|
|
1903
|
+
status: 'Inactif',
|
|
1904
|
+
},
|
|
1905
|
+
{
|
|
1906
|
+
firstname: 'Agate',
|
|
1907
|
+
lastname: 'Roy',
|
|
1908
|
+
status: 'En attente',
|
|
1909
|
+
},
|
|
1910
|
+
],
|
|
1911
|
+
'caption': '',
|
|
1912
|
+
'options': {
|
|
1913
|
+
itemsPerPage: 4,
|
|
1914
|
+
filters: [],
|
|
1915
|
+
},
|
|
1916
|
+
'showFilters': true,
|
|
1917
|
+
'suffix': 'custom-filter-slot-table',
|
|
1918
|
+
'density': 'default',
|
|
1919
|
+
'striped': false,
|
|
1920
|
+
'onUpdate:options': fn(),
|
|
1921
|
+
},
|
|
1922
|
+
render: (args) => {
|
|
1923
|
+
return {
|
|
1924
|
+
components: { SyTable },
|
|
1925
|
+
setup() {
|
|
1926
|
+
// Create a fresh copy of the options to avoid reactivity issues
|
|
1927
|
+
const options = ref<DataOptions>({
|
|
1928
|
+
page: 1,
|
|
1929
|
+
itemsPerPage: 4,
|
|
1930
|
+
filters: [] as import('../common/types').FilterOption[],
|
|
1931
|
+
sortBy: [],
|
|
1932
|
+
})
|
|
1933
|
+
|
|
1934
|
+
// Create a reactive reference for the custom filter value
|
|
1935
|
+
const customFilterValue = ref('')
|
|
1936
|
+
const statusOptions = ['Actif', 'Inactif', 'En attente']
|
|
1937
|
+
|
|
1938
|
+
// Function to update the filter when the select value changes
|
|
1939
|
+
function handleFilterChange(val) {
|
|
1940
|
+
// Ensure options.value.filters is initialized
|
|
1941
|
+
if (!options.value.filters) {
|
|
1942
|
+
options.value.filters = []
|
|
1943
|
+
}
|
|
1944
|
+
|
|
1945
|
+
// Create a new filters array with proper typing
|
|
1946
|
+
const currentFilters = options.value.filters as import('../common/types').FilterOption[]
|
|
1947
|
+
const newFilters = [...currentFilters].filter(f => f.key !== 'status')
|
|
1948
|
+
|
|
1949
|
+
// Add the new filter if a value is selected
|
|
1950
|
+
if (val) {
|
|
1951
|
+
newFilters.push({
|
|
1952
|
+
key: 'status',
|
|
1953
|
+
value: val,
|
|
1954
|
+
type: 'select' as FilterType, // Use 'select' type for compatibility with filtering logic
|
|
1955
|
+
})
|
|
1956
|
+
}
|
|
1957
|
+
|
|
1958
|
+
// Update the options with the new filters
|
|
1959
|
+
options.value = {
|
|
1960
|
+
...options.value,
|
|
1961
|
+
filters: newFilters,
|
|
1962
|
+
}
|
|
1963
|
+
}
|
|
1964
|
+
|
|
1965
|
+
return {
|
|
1966
|
+
args,
|
|
1967
|
+
options,
|
|
1968
|
+
customFilterValue,
|
|
1969
|
+
statusOptions,
|
|
1970
|
+
handleFilterChange,
|
|
1971
|
+
}
|
|
1972
|
+
},
|
|
1973
|
+
template: `
|
|
1974
|
+
<SyTable
|
|
1975
|
+
v-model:options="options"
|
|
1976
|
+
:headers="args.headers"
|
|
1977
|
+
:items="args.items"
|
|
1978
|
+
show-filters
|
|
1979
|
+
suffix="custom-filter-slot-table"
|
|
1980
|
+
>
|
|
1981
|
+
<template #filter.custom="{ header, updateFilter }">
|
|
1982
|
+
<div class="custom-filter-container">
|
|
1983
|
+
<div class="custom-filter-info mb-2">
|
|
1984
|
+
Filtre personnalisé :
|
|
1985
|
+
</div>
|
|
1986
|
+
<v-select
|
|
1987
|
+
v-model="customFilterValue"
|
|
1988
|
+
:items="statusOptions"
|
|
1989
|
+
label="Statut"
|
|
1990
|
+
variant="outlined"
|
|
1991
|
+
density="compact"
|
|
1992
|
+
color="primary"
|
|
1993
|
+
bg-color="white"
|
|
1994
|
+
@update:model-value="(val) => {
|
|
1995
|
+
// Use updateFilter provided by the slot props
|
|
1996
|
+
updateFilter(val);
|
|
1997
|
+
// Also update our local state
|
|
1998
|
+
handleFilterChange(val);
|
|
1999
|
+
}"
|
|
2000
|
+
/>
|
|
2001
|
+
</div>
|
|
2002
|
+
</template>
|
|
2003
|
+
</SyTable>
|
|
2004
|
+
`,
|
|
2005
|
+
}
|
|
2006
|
+
},
|
|
2007
|
+
}
|
|
2008
|
+
|
|
2009
|
+
export const CustomFilterInputs: Story = {
|
|
2010
|
+
parameters: {
|
|
2011
|
+
sourceCode: [
|
|
2012
|
+
{
|
|
2013
|
+
name: 'Template',
|
|
2014
|
+
code: `
|
|
2015
|
+
<template>
|
|
2016
|
+
<SyTable
|
|
2017
|
+
v-model:options="options"
|
|
2018
|
+
:headers="headers"
|
|
2019
|
+
:items="items"
|
|
2020
|
+
:filter-input-config="filterInputConfig"
|
|
2021
|
+
show-filters
|
|
2022
|
+
suffix="filter-text-table"
|
|
2023
|
+
/>
|
|
2024
|
+
</template>
|
|
2025
|
+
`,
|
|
2026
|
+
},
|
|
2027
|
+
{
|
|
2028
|
+
name: 'Script',
|
|
2029
|
+
code: `
|
|
2030
|
+
<script setup lang="ts">
|
|
2031
|
+
import { ref } from 'vue'
|
|
2032
|
+
import { SyTable } from '@cnamts/synapse'
|
|
2033
|
+
|
|
2034
|
+
const options = ref({
|
|
2035
|
+
itemsPerPage: 4,
|
|
2036
|
+
filters: []
|
|
2037
|
+
})
|
|
2038
|
+
|
|
2039
|
+
const headers = ref([
|
|
2040
|
+
{
|
|
2041
|
+
title: 'Nom',
|
|
2042
|
+
key: 'lastname',
|
|
2043
|
+
filterable: true,
|
|
2044
|
+
filterType: 'text'
|
|
2045
|
+
},
|
|
2046
|
+
{
|
|
2047
|
+
title: 'Prénom',
|
|
2048
|
+
key: 'firstname',
|
|
2049
|
+
filterable: true,
|
|
2050
|
+
filterType: 'text'
|
|
2051
|
+
},
|
|
2052
|
+
{
|
|
2053
|
+
title: 'Email',
|
|
2054
|
+
value: 'email',
|
|
2055
|
+
filterable: true,
|
|
2056
|
+
filterType: 'text'
|
|
2057
|
+
},
|
|
2058
|
+
])
|
|
2059
|
+
|
|
2060
|
+
const items = ref([
|
|
2061
|
+
{
|
|
2062
|
+
firstname: 'Virginie',
|
|
2063
|
+
lastname: 'Beauchesne',
|
|
2064
|
+
email: 'virginie.beauchesne@example.com',
|
|
2065
|
+
},
|
|
2066
|
+
{
|
|
2067
|
+
firstname: 'Simone',
|
|
2068
|
+
lastname: 'Bellefeuille',
|
|
2069
|
+
email: 'simone.bellefeuille@example.com',
|
|
2070
|
+
},
|
|
2071
|
+
{
|
|
2072
|
+
firstname: 'Étienne',
|
|
2073
|
+
lastname: 'Salois',
|
|
2074
|
+
email: 'etienne.salois@example.com',
|
|
2075
|
+
},
|
|
2076
|
+
{
|
|
2077
|
+
firstname: 'Thierry',
|
|
2078
|
+
lastname: 'Bobu',
|
|
2079
|
+
email: 'thierry.bobu@example.com',
|
|
2080
|
+
},
|
|
2081
|
+
{
|
|
2082
|
+
firstname: 'Bernadette',
|
|
2083
|
+
lastname: 'Langelier',
|
|
2084
|
+
email: 'bernadette.langelier@exemple.com'
|
|
2085
|
+
},
|
|
2086
|
+
{
|
|
2087
|
+
firstname: 'Agate',
|
|
2088
|
+
lastname: 'Roy',
|
|
2089
|
+
email: 'agate.roy@exemple.com'
|
|
2090
|
+
}
|
|
2091
|
+
])
|
|
2092
|
+
|
|
2093
|
+
const filterInputConfig = ref({
|
|
2094
|
+
variant: 'outlined',
|
|
2095
|
+
density: 'comfortable',
|
|
2096
|
+
hideDetails: true,
|
|
2097
|
+
clearable: false,
|
|
2098
|
+
disableErrorHandling: true,
|
|
2099
|
+
})
|
|
2100
|
+
</script>
|
|
2101
|
+
`,
|
|
2102
|
+
},
|
|
2103
|
+
],
|
|
2104
|
+
},
|
|
2105
|
+
args: {
|
|
2106
|
+
'headers': [
|
|
2107
|
+
{
|
|
2108
|
+
title: 'Nom',
|
|
2109
|
+
key: 'lastname',
|
|
2110
|
+
filterable: true,
|
|
2111
|
+
filterType: 'text',
|
|
2112
|
+
},
|
|
2113
|
+
{
|
|
2114
|
+
title: 'Prénom',
|
|
2115
|
+
key: 'firstname',
|
|
2116
|
+
filterable: true,
|
|
2117
|
+
filterType: 'text',
|
|
2118
|
+
},
|
|
2119
|
+
{
|
|
2120
|
+
title: 'Email',
|
|
2121
|
+
value: 'email',
|
|
2122
|
+
filterable: true,
|
|
2123
|
+
filterType: 'text',
|
|
2124
|
+
},
|
|
2125
|
+
],
|
|
2126
|
+
'items': [
|
|
2127
|
+
{
|
|
2128
|
+
firstname: 'Virginie',
|
|
2129
|
+
lastname: 'Beauchesne',
|
|
2130
|
+
email: 'virginie.beauchesne@example.com',
|
|
2131
|
+
},
|
|
2132
|
+
{
|
|
2133
|
+
firstname: 'Simone',
|
|
2134
|
+
lastname: 'Bellefeuille',
|
|
2135
|
+
email: 'simone.bellefeuille@example.com',
|
|
2136
|
+
},
|
|
2137
|
+
{
|
|
2138
|
+
firstname: 'Étienne',
|
|
2139
|
+
lastname: 'Salois',
|
|
2140
|
+
email: 'etienne.salois@example.com',
|
|
2141
|
+
},
|
|
2142
|
+
{
|
|
2143
|
+
firstname: 'Thierry',
|
|
2144
|
+
lastname: 'Bobu',
|
|
2145
|
+
email: 'thierry.bobu@example.com',
|
|
2146
|
+
},
|
|
2147
|
+
{
|
|
2148
|
+
firstname: 'Bernadette',
|
|
2149
|
+
lastname: 'Langelier',
|
|
2150
|
+
email: 'bernadette.langelier@exemple.com',
|
|
2151
|
+
},
|
|
2152
|
+
{
|
|
2153
|
+
firstname: 'Agate',
|
|
2154
|
+
lastname: 'Roy',
|
|
2155
|
+
email: 'agate.roy@exemple.com',
|
|
2156
|
+
},
|
|
2157
|
+
],
|
|
2158
|
+
'caption': '',
|
|
2159
|
+
'options': {
|
|
2160
|
+
itemsPerPage: 4,
|
|
2161
|
+
filters: [],
|
|
2162
|
+
},
|
|
2163
|
+
'filterInputConfig': {
|
|
2164
|
+
variant: 'outlined',
|
|
2165
|
+
density: 'comfortable',
|
|
2166
|
+
hideDetails: true,
|
|
2167
|
+
clearable: false,
|
|
2168
|
+
disableErrorHandling: true,
|
|
2169
|
+
},
|
|
2170
|
+
'showFilters': true,
|
|
2171
|
+
'suffix': 'filter-text-table',
|
|
2172
|
+
'density': 'default',
|
|
2173
|
+
'striped': false,
|
|
2174
|
+
'onUpdate:options': fn(),
|
|
2175
|
+
},
|
|
2176
|
+
render: (args) => {
|
|
2177
|
+
return {
|
|
2178
|
+
components: { SyTable },
|
|
2179
|
+
setup() {
|
|
2180
|
+
// Create reactive references
|
|
2181
|
+
const options = ref(args.options)
|
|
2182
|
+
const items = ref(args.items)
|
|
2183
|
+
|
|
2184
|
+
return {
|
|
2185
|
+
args,
|
|
2186
|
+
options,
|
|
2187
|
+
items,
|
|
2188
|
+
}
|
|
2189
|
+
},
|
|
2190
|
+
template: `
|
|
2191
|
+
<SyTable
|
|
2192
|
+
v-model:options="args.options"
|
|
2193
|
+
v-bind="args"
|
|
2194
|
+
suffix="filter-custom-input"
|
|
2195
|
+
/>
|
|
2196
|
+
`,
|
|
2197
|
+
}
|
|
2198
|
+
},
|
|
2199
|
+
}
|
|
2200
|
+
|
|
2201
|
+
export const ManyTables: Story = {
|
|
2202
|
+
parameters: {
|
|
2203
|
+
sourceCode: [
|
|
2204
|
+
{
|
|
2205
|
+
name: 'Template',
|
|
2206
|
+
code: `
|
|
2207
|
+
<template>
|
|
2208
|
+
<div class="d-flex flex-column gap-4">
|
|
2209
|
+
<SyTable
|
|
2210
|
+
v-model:options="options1"
|
|
2211
|
+
:headers="headers"
|
|
2212
|
+
:items="items1"
|
|
2213
|
+
suffix="table-1"
|
|
2214
|
+
/>
|
|
2215
|
+
<SyTable
|
|
2216
|
+
v-model:options="options2"
|
|
2217
|
+
:headers="headers"
|
|
2218
|
+
:items="items2"
|
|
2219
|
+
suffix="table-2"
|
|
2220
|
+
/>
|
|
2221
|
+
</div>
|
|
2222
|
+
</template>
|
|
2223
|
+
`,
|
|
2224
|
+
},
|
|
2225
|
+
{
|
|
2226
|
+
name: 'Script',
|
|
2227
|
+
code: `
|
|
2228
|
+
<script setup lang="ts">
|
|
2229
|
+
import { ref } from 'vue'
|
|
2230
|
+
import { SyTable } from '@cnamts/synapse'
|
|
2231
|
+
|
|
2232
|
+
const options1 = ref({
|
|
2233
|
+
itemsPerPage: 4,
|
|
2234
|
+
})
|
|
2235
|
+
|
|
2236
|
+
const options2 = ref({
|
|
2237
|
+
itemsPerPage: 2,
|
|
2238
|
+
})
|
|
2239
|
+
|
|
2240
|
+
const headers = ref([
|
|
2241
|
+
{
|
|
2242
|
+
title: 'Nom',
|
|
2243
|
+
key: 'lastname',
|
|
2244
|
+
},
|
|
2245
|
+
{
|
|
2246
|
+
title: 'Prénom',
|
|
2247
|
+
key: 'firstname',
|
|
2248
|
+
},
|
|
2249
|
+
{
|
|
2250
|
+
title: 'Email',
|
|
2251
|
+
value: 'email',
|
|
2252
|
+
},
|
|
2253
|
+
])
|
|
2254
|
+
|
|
2255
|
+
const items = ref([
|
|
2256
|
+
{
|
|
2257
|
+
firstname: 'Virginie',
|
|
2258
|
+
lastname: 'Beauchesne',
|
|
2259
|
+
email: 'virginie.beauchesne@example.com',
|
|
2260
|
+
},
|
|
2261
|
+
{
|
|
2262
|
+
firstname: 'Simone',
|
|
2263
|
+
lastname: 'Bellefeuille',
|
|
2264
|
+
email: 'simone.bellefeuille@example.com',
|
|
2265
|
+
},
|
|
2266
|
+
{
|
|
2267
|
+
firstname: 'Étienne',
|
|
2268
|
+
lastname: 'Salois',
|
|
2269
|
+
email: 'etienne.salois@example.com',
|
|
2270
|
+
},
|
|
2271
|
+
{
|
|
2272
|
+
firstname: 'Thierry',
|
|
2273
|
+
lastname: 'Bobu',
|
|
2274
|
+
email: 'thierry.bobu@example.com',
|
|
2275
|
+
},
|
|
2276
|
+
{
|
|
2277
|
+
firstname: 'Bernadette',
|
|
2278
|
+
lastname: 'Langelier',
|
|
2279
|
+
email: 'bernadette.langelier@exemple.com'
|
|
2280
|
+
},
|
|
2281
|
+
{
|
|
2282
|
+
firstname: 'Agate',
|
|
2283
|
+
lastname: 'Roy',
|
|
2284
|
+
email: 'agate.roy@exemple.com'
|
|
2285
|
+
}
|
|
2286
|
+
])
|
|
2287
|
+
</script>
|
|
2288
|
+
`,
|
|
2289
|
+
},
|
|
2290
|
+
],
|
|
2291
|
+
},
|
|
2292
|
+
args: {
|
|
2293
|
+
'headers': [
|
|
2294
|
+
{
|
|
2295
|
+
title: 'Nom',
|
|
2296
|
+
key: 'lastname',
|
|
2297
|
+
},
|
|
2298
|
+
{
|
|
2299
|
+
title: 'Prénom',
|
|
2300
|
+
key: 'firstname',
|
|
2301
|
+
},
|
|
2302
|
+
{
|
|
2303
|
+
title: 'Email',
|
|
2304
|
+
value: 'email',
|
|
2305
|
+
},
|
|
2306
|
+
],
|
|
2307
|
+
'items': [
|
|
2308
|
+
{
|
|
2309
|
+
firstname: 'Virginie',
|
|
2310
|
+
lastname: 'Beauchesne',
|
|
2311
|
+
email: 'virginie.beauchesne@example.com',
|
|
2312
|
+
},
|
|
2313
|
+
{
|
|
2314
|
+
firstname: 'Simone',
|
|
2315
|
+
lastname: 'Bellefeuille',
|
|
2316
|
+
email: 'simone.bellefeuille@example.com',
|
|
2317
|
+
},
|
|
2318
|
+
{
|
|
2319
|
+
firstname: 'Étienne',
|
|
2320
|
+
lastname: 'Salois',
|
|
2321
|
+
email: 'etienne.salois@example.com',
|
|
2322
|
+
},
|
|
2323
|
+
{
|
|
2324
|
+
firstname: 'Thierry',
|
|
2325
|
+
lastname: 'Bobu',
|
|
2326
|
+
email: 'thierry.bobu@example.com',
|
|
2327
|
+
},
|
|
2328
|
+
{
|
|
2329
|
+
firstname: 'Bernadette',
|
|
2330
|
+
lastname: 'Langelier',
|
|
2331
|
+
email: 'bernadette.langelier@exemple.com',
|
|
2332
|
+
},
|
|
2333
|
+
{
|
|
2334
|
+
firstname: 'Agate',
|
|
2335
|
+
lastname: 'Roy',
|
|
2336
|
+
email: 'agate.roy@exemple.com',
|
|
2337
|
+
},
|
|
2338
|
+
],
|
|
2339
|
+
'caption': '',
|
|
2340
|
+
'suffix': 'multi-server',
|
|
2341
|
+
'density': 'default',
|
|
2342
|
+
'striped': false,
|
|
2343
|
+
'onUpdate:options': fn(),
|
|
2344
|
+
},
|
|
2345
|
+
render: (args) => {
|
|
2346
|
+
return {
|
|
2347
|
+
components: { SyTable },
|
|
2348
|
+
setup() {
|
|
2349
|
+
const options1 = ref<Partial<DataOptions>>({
|
|
2350
|
+
itemsPerPage: 4,
|
|
2351
|
+
})
|
|
2352
|
+
const options2 = ref<Partial<DataOptions>>({
|
|
2353
|
+
itemsPerPage: 2,
|
|
2354
|
+
})
|
|
2355
|
+
return { args, options1, options2 }
|
|
2356
|
+
},
|
|
2357
|
+
template: `
|
|
2358
|
+
<div>
|
|
2359
|
+
<SyTable
|
|
2360
|
+
v-model:options="options1"
|
|
2361
|
+
v-bind="args"
|
|
2362
|
+
suffix="table1"
|
|
2363
|
+
class="mb-10"
|
|
2364
|
+
/>
|
|
2365
|
+
<SyTable
|
|
2366
|
+
v-model:options="options2"
|
|
2367
|
+
v-bind="args"
|
|
2368
|
+
suffix="table2"
|
|
2369
|
+
/>
|
|
2370
|
+
</div>
|
|
2371
|
+
`,
|
|
2372
|
+
}
|
|
2373
|
+
},
|
|
2374
|
+
}
|
|
2375
|
+
|
|
2376
|
+
export const DataAlignment: Story = {
|
|
2377
|
+
parameters: {
|
|
2378
|
+
sourceCode: [
|
|
2379
|
+
{
|
|
2380
|
+
name: 'Template',
|
|
2381
|
+
code: `
|
|
2382
|
+
<template>
|
|
2383
|
+
<SyTable
|
|
2384
|
+
v-model:options="options"
|
|
2385
|
+
:headers="headers"
|
|
2386
|
+
:items="items"
|
|
2387
|
+
suffix="alignment-table"
|
|
2388
|
+
/>
|
|
2389
|
+
</template>
|
|
2390
|
+
`,
|
|
2391
|
+
},
|
|
2392
|
+
{
|
|
2393
|
+
name: 'Script',
|
|
2394
|
+
code: `
|
|
2395
|
+
<script setup lang="ts">
|
|
2396
|
+
import { ref } from 'vue'
|
|
2397
|
+
import { SyTable } from '@cnamts/synapse'
|
|
2398
|
+
|
|
2399
|
+
const options = ref({
|
|
2400
|
+
itemsPerPage: 4,
|
|
2401
|
+
})
|
|
2402
|
+
|
|
2403
|
+
const headers = ref([
|
|
2404
|
+
{
|
|
2405
|
+
title: 'ID',
|
|
2406
|
+
key: 'id',
|
|
2407
|
+
align: 'center',
|
|
2408
|
+
},
|
|
2409
|
+
{
|
|
2410
|
+
title: 'Nom',
|
|
2411
|
+
key: 'lastname',
|
|
2412
|
+
align: 'start',
|
|
2413
|
+
},
|
|
2414
|
+
{
|
|
2415
|
+
title: 'Date de naissance',
|
|
2416
|
+
key: 'birthdate',
|
|
2417
|
+
align: 'center',
|
|
2418
|
+
},
|
|
2419
|
+
{
|
|
2420
|
+
title: 'NIR',
|
|
2421
|
+
key: 'nir',
|
|
2422
|
+
align: 'end',
|
|
2423
|
+
},
|
|
2424
|
+
])
|
|
2425
|
+
|
|
2426
|
+
const items = ref([
|
|
2427
|
+
{
|
|
2428
|
+
id: '1',
|
|
2429
|
+
lastname: 'Lefebvre',
|
|
2430
|
+
birthdate: '18/02/1989',
|
|
2431
|
+
nir: '1 89 02 75 120 005 79',
|
|
2432
|
+
},
|
|
2433
|
+
{
|
|
2434
|
+
id: '2',
|
|
2435
|
+
lastname: 'Richard',
|
|
2436
|
+
birthdate: '22/05/1991',
|
|
2437
|
+
nir: '2 91 05 75 120 005 76',
|
|
2438
|
+
},
|
|
2439
|
+
{
|
|
2440
|
+
id: '3',
|
|
2441
|
+
lastname: 'Fournier',
|
|
2442
|
+
birthdate: '11/11/2000',
|
|
2443
|
+
nir: '2 00 11 42 120 008 87',
|
|
2444
|
+
},
|
|
2445
|
+
])
|
|
2446
|
+
</script>
|
|
2447
|
+
`,
|
|
2448
|
+
},
|
|
2449
|
+
],
|
|
2450
|
+
},
|
|
2451
|
+
args: {
|
|
2452
|
+
'headers': [
|
|
2453
|
+
{
|
|
2454
|
+
title: 'ID',
|
|
2455
|
+
key: 'id',
|
|
2456
|
+
align: 'center',
|
|
2457
|
+
sortable: false,
|
|
2458
|
+
},
|
|
2459
|
+
{
|
|
2460
|
+
title: 'Nom',
|
|
2461
|
+
key: 'lastname',
|
|
2462
|
+
align: 'start',
|
|
2463
|
+
sortable: false,
|
|
2464
|
+
},
|
|
2465
|
+
{
|
|
2466
|
+
title: 'Date de naissance',
|
|
2467
|
+
key: 'birthdate',
|
|
2468
|
+
align: 'center',
|
|
2469
|
+
sortable: false,
|
|
2470
|
+
},
|
|
2471
|
+
{
|
|
2472
|
+
title: 'NIR',
|
|
2473
|
+
key: 'nir',
|
|
2474
|
+
align: 'end',
|
|
2475
|
+
sortable: false,
|
|
2476
|
+
},
|
|
2477
|
+
],
|
|
2478
|
+
'items': [
|
|
2479
|
+
{
|
|
2480
|
+
id: '1',
|
|
2481
|
+
lastname: 'Lefebvre',
|
|
2482
|
+
birthdate: '18/02/1989',
|
|
2483
|
+
nir: '1 89 02 75 120 005 79',
|
|
2484
|
+
},
|
|
2485
|
+
{
|
|
2486
|
+
id: '2',
|
|
2487
|
+
lastname: 'Richard',
|
|
2488
|
+
birthdate: '22/05/1991',
|
|
2489
|
+
nir: '2 91 05 75 120 005 76',
|
|
2490
|
+
},
|
|
2491
|
+
{
|
|
2492
|
+
id: '3',
|
|
2493
|
+
lastname: 'Fournier',
|
|
2494
|
+
birthdate: '11/11/2000',
|
|
2495
|
+
nir: '2 00 11 42 120 008 87',
|
|
2496
|
+
},
|
|
2497
|
+
],
|
|
2498
|
+
'options': {
|
|
2499
|
+
itemsPerPage: 4,
|
|
2500
|
+
},
|
|
2501
|
+
'suffix': 'alignment-table',
|
|
2502
|
+
'onUpdate:options': fn(),
|
|
2503
|
+
},
|
|
2504
|
+
render: (args) => {
|
|
2505
|
+
return {
|
|
2506
|
+
components: { SyTable },
|
|
2507
|
+
setup() {
|
|
2508
|
+
return { args }
|
|
2509
|
+
},
|
|
2510
|
+
template: `
|
|
2511
|
+
<SyTable
|
|
2512
|
+
v-model:options="args.options"
|
|
2513
|
+
v-bind="args"
|
|
2514
|
+
suffix="alignment-table"
|
|
2515
|
+
/>
|
|
2516
|
+
`,
|
|
2517
|
+
}
|
|
2518
|
+
},
|
|
2519
|
+
}
|
|
2520
|
+
|
|
2521
|
+
export const ResizableColumns: Story = {
|
|
2522
|
+
parameters: {
|
|
2523
|
+
sourceCode: [
|
|
2524
|
+
{
|
|
2525
|
+
name: 'Template',
|
|
2526
|
+
code: `
|
|
2527
|
+
<template>
|
|
2528
|
+
<SyTable
|
|
2529
|
+
v-model:options="options"
|
|
2530
|
+
:headers="headers"
|
|
2531
|
+
:items="items"
|
|
2532
|
+
:resizable-columns="true"
|
|
2533
|
+
suffix="resizable-columns"
|
|
2534
|
+
/>
|
|
2535
|
+
</template>
|
|
2536
|
+
`,
|
|
2537
|
+
},
|
|
2538
|
+
{
|
|
2539
|
+
name: 'Script',
|
|
2540
|
+
code: `
|
|
2541
|
+
<script setup lang="ts">
|
|
2542
|
+
import { ref } from 'vue'
|
|
2543
|
+
import { SyTable } from '@cnamts/synapse'
|
|
2544
|
+
|
|
2545
|
+
const options = ref({
|
|
2546
|
+
itemsPerPage: 4,
|
|
2547
|
+
})
|
|
2548
|
+
|
|
2549
|
+
const headers = ref([
|
|
2550
|
+
{
|
|
2551
|
+
title: 'Nom',
|
|
2552
|
+
key: 'lastname',
|
|
2553
|
+
},
|
|
2554
|
+
{
|
|
2555
|
+
title: 'Prénom',
|
|
2556
|
+
key: 'firstname',
|
|
2557
|
+
},
|
|
2558
|
+
{
|
|
2559
|
+
title: 'Email',
|
|
2560
|
+
value: 'email',
|
|
2561
|
+
},
|
|
2562
|
+
])
|
|
2563
|
+
|
|
2564
|
+
const items = ref([
|
|
2565
|
+
{
|
|
2566
|
+
firstname: 'Virginie',
|
|
2567
|
+
lastname: 'Beauchesne',
|
|
2568
|
+
email: 'virginie.beauchesne@example.com',
|
|
2569
|
+
},
|
|
2570
|
+
{
|
|
2571
|
+
firstname: 'Simone',
|
|
2572
|
+
lastname: 'Bellefeuille',
|
|
2573
|
+
email: 'simone.bellefeuille@example.com',
|
|
2574
|
+
},
|
|
2575
|
+
{
|
|
2576
|
+
firstname: 'Étienne',
|
|
2577
|
+
lastname: 'Salois',
|
|
2578
|
+
email: 'etienne.salois@example.com',
|
|
2579
|
+
},
|
|
2580
|
+
{
|
|
2581
|
+
firstname: 'Thierry',
|
|
2582
|
+
lastname: 'Bobu',
|
|
2583
|
+
email: 'thierry.bobu@example.com',
|
|
2584
|
+
},
|
|
2585
|
+
{
|
|
2586
|
+
firstname: 'Bernadette',
|
|
2587
|
+
lastname: 'Langelier',
|
|
2588
|
+
email: 'bernadette.langelier@exemple.com'
|
|
2589
|
+
},
|
|
2590
|
+
{
|
|
2591
|
+
firstname: 'Agate',
|
|
2592
|
+
lastname: 'Roy',
|
|
2593
|
+
email: 'agate.roy@exemple.com'
|
|
2594
|
+
}
|
|
2595
|
+
])
|
|
2596
|
+
</script>
|
|
2597
|
+
`,
|
|
2598
|
+
},
|
|
2599
|
+
],
|
|
2600
|
+
},
|
|
2601
|
+
args: {
|
|
2602
|
+
'resizableColumns': true,
|
|
2603
|
+
'headers': [
|
|
2604
|
+
{
|
|
2605
|
+
title: 'Nom',
|
|
2606
|
+
key: 'lastname',
|
|
2607
|
+
},
|
|
2608
|
+
{
|
|
2609
|
+
title: 'Prénom',
|
|
2610
|
+
key: 'firstname',
|
|
2611
|
+
},
|
|
2612
|
+
{
|
|
2613
|
+
title: 'Email',
|
|
2614
|
+
value: 'email',
|
|
2615
|
+
},
|
|
2616
|
+
],
|
|
2617
|
+
'items': [
|
|
2618
|
+
{
|
|
2619
|
+
firstname: 'Virginie',
|
|
2620
|
+
lastname: 'Beauchesne',
|
|
2621
|
+
email: 'virginie.beauchesne@example.com',
|
|
2622
|
+
},
|
|
2623
|
+
{
|
|
2624
|
+
firstname: 'Simone',
|
|
2625
|
+
lastname: 'Bellefeuille',
|
|
2626
|
+
email: 'simone.bellefeuille@example.com',
|
|
2627
|
+
},
|
|
2628
|
+
{
|
|
2629
|
+
firstname: 'Étienne',
|
|
2630
|
+
lastname: 'Salois',
|
|
2631
|
+
email: 'etienne.salois@example.com',
|
|
2632
|
+
},
|
|
2633
|
+
{
|
|
2634
|
+
firstname: 'Thierry',
|
|
2635
|
+
lastname: 'Bobu',
|
|
2636
|
+
email: 'thierry.bobu@example.com',
|
|
2637
|
+
},
|
|
2638
|
+
{
|
|
2639
|
+
firstname: 'Bernadette',
|
|
2640
|
+
lastname: 'Langelier',
|
|
2641
|
+
email: 'bernadette.langelier@exemple.com',
|
|
2642
|
+
},
|
|
2643
|
+
{
|
|
2644
|
+
firstname: 'Agate',
|
|
2645
|
+
lastname: 'Roy',
|
|
2646
|
+
email: 'agate.roy@exemple.com',
|
|
2647
|
+
},
|
|
2648
|
+
],
|
|
2649
|
+
'options': {
|
|
2650
|
+
itemsPerPage: 4,
|
|
2651
|
+
},
|
|
2652
|
+
'suffix': 'resizable-columns',
|
|
2653
|
+
'onUpdate:options': fn(),
|
|
2654
|
+
},
|
|
2655
|
+
render: (args) => {
|
|
2656
|
+
return {
|
|
2657
|
+
components: { SyTable },
|
|
2658
|
+
setup() {
|
|
2659
|
+
return { args }
|
|
2660
|
+
},
|
|
2661
|
+
template: `
|
|
2662
|
+
<SyTable
|
|
2663
|
+
v-model:options="args.options"
|
|
2664
|
+
v-bind="args"
|
|
2665
|
+
suffix="resizable-columns"
|
|
2666
|
+
/>
|
|
2667
|
+
`,
|
|
2668
|
+
}
|
|
2669
|
+
},
|
|
2670
|
+
}
|
|
2671
|
+
|
|
2672
|
+
export const RowSelection: Story = {
|
|
2673
|
+
name: 'Row Selection',
|
|
2674
|
+
parameters: {
|
|
2675
|
+
sourceCode: [
|
|
2676
|
+
{
|
|
2677
|
+
name: 'Template',
|
|
2678
|
+
code: `
|
|
2679
|
+
<template>
|
|
2680
|
+
<SyTable
|
|
2681
|
+
v-model:options="options"
|
|
2682
|
+
v-model="selection"
|
|
2683
|
+
:headers="headers"
|
|
2684
|
+
:items="items"
|
|
2685
|
+
show-select
|
|
2686
|
+
show-filters
|
|
2687
|
+
suffix="selection-table"
|
|
2688
|
+
/>
|
|
2689
|
+
<div v-if="selection.length" class="mt-4 pa-4 bg-grey-lighten-4">
|
|
2690
|
+
<h3 class="text-h6 mb-3">Item(s) sélectionné(s) ({{ selection.length }})</h3>
|
|
2691
|
+
<div v-for="(item, index) in selection" :key="index" class="mb-2 pa-2 bg-grey-lighten-3">
|
|
2692
|
+
<div><strong>Nom:</strong> {{ typeof item === 'object' ? item.lastname : items.find(i => JSON.stringify(i) === item)?.lastname }}</div>
|
|
2693
|
+
<div><strong>Prénom:</strong> {{ typeof item === 'object' ? item.firstname : items.find(i => JSON.stringify(i) === item)?.firstname }}</div>
|
|
2694
|
+
<div><strong>Email:</strong> {{ typeof item === 'object' ? item.email : items.find(i => JSON.stringify(i) === item)?.email }}</div>
|
|
2695
|
+
</div>
|
|
2696
|
+
</div>
|
|
1214
2697
|
</template>
|
|
1215
2698
|
`,
|
|
1216
2699
|
},
|
|
@@ -1223,30 +2706,20 @@ export const CustomFilterSlot: Story = {
|
|
|
1223
2706
|
|
|
1224
2707
|
const options = ref({
|
|
1225
2708
|
itemsPerPage: 4,
|
|
1226
|
-
filters: []
|
|
1227
2709
|
})
|
|
1228
2710
|
|
|
1229
|
-
const customFilterValue = ref('')
|
|
1230
|
-
const statusOptions = ['Actif', 'Inactif', 'En attente']
|
|
1231
|
-
|
|
1232
2711
|
const headers = ref([
|
|
1233
2712
|
{
|
|
1234
2713
|
title: 'Nom',
|
|
1235
2714
|
key: 'lastname',
|
|
1236
|
-
filterable: true,
|
|
1237
|
-
filterType: 'text'
|
|
1238
2715
|
},
|
|
1239
2716
|
{
|
|
1240
2717
|
title: 'Prénom',
|
|
1241
2718
|
key: 'firstname',
|
|
1242
|
-
filterable: true,
|
|
1243
|
-
filterType: 'text'
|
|
1244
2719
|
},
|
|
1245
2720
|
{
|
|
1246
|
-
title: '
|
|
1247
|
-
|
|
1248
|
-
filterable: true,
|
|
1249
|
-
filterType: 'custom' // Utilisation du type 'custom' pour activer le slot personnalisé
|
|
2721
|
+
title: 'Email',
|
|
2722
|
+
value: 'email',
|
|
1250
2723
|
},
|
|
1251
2724
|
])
|
|
1252
2725
|
|
|
@@ -1254,55 +2727,37 @@ export const CustomFilterSlot: Story = {
|
|
|
1254
2727
|
{
|
|
1255
2728
|
firstname: 'Virginie',
|
|
1256
2729
|
lastname: 'Beauchesne',
|
|
1257
|
-
|
|
2730
|
+
email: 'virginie.beauchesne@example.com',
|
|
1258
2731
|
},
|
|
1259
2732
|
{
|
|
1260
2733
|
firstname: 'Simone',
|
|
1261
2734
|
lastname: 'Bellefeuille',
|
|
1262
|
-
|
|
2735
|
+
email: 'simone.bellefeuille@example.com',
|
|
1263
2736
|
},
|
|
1264
2737
|
{
|
|
1265
2738
|
firstname: 'Étienne',
|
|
1266
2739
|
lastname: 'Salois',
|
|
1267
|
-
|
|
2740
|
+
email: 'etienne.salois@example.com',
|
|
1268
2741
|
},
|
|
1269
2742
|
{
|
|
1270
2743
|
firstname: 'Thierry',
|
|
1271
2744
|
lastname: 'Bobu',
|
|
1272
|
-
|
|
2745
|
+
email: 'thierry.bobu@example.com',
|
|
1273
2746
|
},
|
|
1274
2747
|
{
|
|
1275
2748
|
firstname: 'Bernadette',
|
|
1276
2749
|
lastname: 'Langelier',
|
|
1277
|
-
|
|
2750
|
+
email: 'bernadette.langelier@exemple.com'
|
|
1278
2751
|
},
|
|
1279
2752
|
{
|
|
1280
2753
|
firstname: 'Agate',
|
|
1281
2754
|
lastname: 'Roy',
|
|
1282
|
-
|
|
2755
|
+
email: 'agate.roy@exemple.com'
|
|
1283
2756
|
}
|
|
1284
2757
|
])
|
|
1285
2758
|
</script>
|
|
1286
2759
|
`,
|
|
1287
2760
|
},
|
|
1288
|
-
{
|
|
1289
|
-
name: 'Style',
|
|
1290
|
-
code: `
|
|
1291
|
-
<style scoped>
|
|
1292
|
-
.custom-filter-container {
|
|
1293
|
-
display: flex;
|
|
1294
|
-
flex-direction: column;
|
|
1295
|
-
gap: 4px;
|
|
1296
|
-
}
|
|
1297
|
-
|
|
1298
|
-
.custom-filter-info {
|
|
1299
|
-
font-size: 12px;
|
|
1300
|
-
color: #666;
|
|
1301
|
-
margin-top: 4px;
|
|
1302
|
-
}
|
|
1303
|
-
</style>
|
|
1304
|
-
`,
|
|
1305
|
-
},
|
|
1306
2761
|
],
|
|
1307
2762
|
},
|
|
1308
2763
|
args: {
|
|
@@ -1310,129 +2765,89 @@ export const CustomFilterSlot: Story = {
|
|
|
1310
2765
|
{
|
|
1311
2766
|
title: 'Nom',
|
|
1312
2767
|
key: 'lastname',
|
|
1313
|
-
filterable: true,
|
|
1314
|
-
filterType: 'text',
|
|
1315
2768
|
},
|
|
1316
2769
|
{
|
|
1317
2770
|
title: 'Prénom',
|
|
1318
2771
|
key: 'firstname',
|
|
1319
|
-
filterable: true,
|
|
1320
|
-
filterType: 'text',
|
|
1321
2772
|
},
|
|
1322
2773
|
{
|
|
1323
|
-
title: '
|
|
1324
|
-
|
|
1325
|
-
filterable: true,
|
|
1326
|
-
filterType: 'custom' as FilterType,
|
|
2774
|
+
title: 'Email',
|
|
2775
|
+
value: 'email',
|
|
1327
2776
|
},
|
|
1328
2777
|
],
|
|
1329
2778
|
items: [
|
|
1330
2779
|
{
|
|
1331
2780
|
firstname: 'Virginie',
|
|
1332
2781
|
lastname: 'Beauchesne',
|
|
1333
|
-
|
|
2782
|
+
email: 'virginie.beauchesne@example.com',
|
|
1334
2783
|
},
|
|
1335
2784
|
{
|
|
1336
2785
|
firstname: 'Simone',
|
|
1337
2786
|
lastname: 'Bellefeuille',
|
|
1338
|
-
|
|
2787
|
+
email: 'simone.bellefeuille@example.com',
|
|
1339
2788
|
},
|
|
1340
2789
|
{
|
|
1341
2790
|
firstname: 'Étienne',
|
|
1342
2791
|
lastname: 'Salois',
|
|
1343
|
-
|
|
2792
|
+
email: 'etienne.salois@example.com',
|
|
1344
2793
|
},
|
|
1345
2794
|
{
|
|
1346
2795
|
firstname: 'Thierry',
|
|
1347
2796
|
lastname: 'Bobu',
|
|
1348
|
-
|
|
2797
|
+
email: 'thierry.bobu@example.com',
|
|
1349
2798
|
},
|
|
1350
2799
|
{
|
|
1351
2800
|
firstname: 'Bernadette',
|
|
1352
2801
|
lastname: 'Langelier',
|
|
1353
|
-
|
|
2802
|
+
email: 'bernadette.langelier@exemple.com',
|
|
1354
2803
|
},
|
|
1355
2804
|
{
|
|
1356
2805
|
firstname: 'Agate',
|
|
1357
2806
|
lastname: 'Roy',
|
|
1358
|
-
|
|
2807
|
+
email: 'agate.roy@exemple.com',
|
|
1359
2808
|
},
|
|
1360
2809
|
],
|
|
1361
|
-
caption: '',
|
|
1362
2810
|
options: {
|
|
1363
2811
|
itemsPerPage: 4,
|
|
1364
|
-
filters: [],
|
|
1365
2812
|
},
|
|
1366
|
-
|
|
1367
|
-
suffix: '
|
|
2813
|
+
caption: '',
|
|
2814
|
+
suffix: 'selection-table',
|
|
1368
2815
|
density: 'default',
|
|
1369
2816
|
striped: false,
|
|
2817
|
+
showSelect: true,
|
|
2818
|
+
showFilters: true,
|
|
1370
2819
|
},
|
|
1371
2820
|
render(args) {
|
|
1372
2821
|
return {
|
|
1373
2822
|
components: { SyTable },
|
|
1374
2823
|
setup() {
|
|
1375
|
-
// Create reactive references
|
|
1376
|
-
const options = ref(args.options)
|
|
1377
2824
|
const items = ref(args.items)
|
|
1378
|
-
const
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
return {
|
|
1382
|
-
args,
|
|
1383
|
-
options,
|
|
1384
|
-
items,
|
|
1385
|
-
customFilterValue,
|
|
1386
|
-
statusOptions,
|
|
1387
|
-
}
|
|
2825
|
+
const selection = ref([])
|
|
2826
|
+
return { args, selection, items }
|
|
1388
2827
|
},
|
|
1389
2828
|
template: `
|
|
1390
|
-
<
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
<div class="custom-filter-info mb-2">
|
|
1404
|
-
Filtre personnalisé :
|
|
1405
|
-
</div>
|
|
1406
|
-
<v-select
|
|
1407
|
-
v-model="customFilterValue"
|
|
1408
|
-
:items="statusOptions"
|
|
1409
|
-
label="Statut"
|
|
1410
|
-
variant="outlined"
|
|
1411
|
-
density="compact"
|
|
1412
|
-
color="primary"
|
|
1413
|
-
bg-color="white"
|
|
1414
|
-
@update:model-value="(val) => {
|
|
1415
|
-
// Manually create a select filter
|
|
1416
|
-
const currentFilters = [...options.filters || []]
|
|
1417
|
-
// Remove existing filter for this key if any
|
|
1418
|
-
const filteredFilters = currentFilters.filter(f => f.key !== 'status')
|
|
1419
|
-
// Add new filter if value is not empty
|
|
1420
|
-
if (val) {
|
|
1421
|
-
filteredFilters.push({ key: 'status', value: val, type: 'select' })
|
|
1422
|
-
}
|
|
1423
|
-
// Update options with new filters
|
|
1424
|
-
options.filters = filteredFilters
|
|
1425
|
-
}"
|
|
1426
|
-
/>
|
|
2829
|
+
<div>
|
|
2830
|
+
<SyTable
|
|
2831
|
+
v-model:options="args.options"
|
|
2832
|
+
v-model="selection"
|
|
2833
|
+
v-bind="args"
|
|
2834
|
+
suffix="selection-table"
|
|
2835
|
+
/>
|
|
2836
|
+
<div v-if="selection.length" class="mt-4 pa-4 bg-grey-lighten-4">
|
|
2837
|
+
<h3 class="text-h6 mb-3">Item(s) sélectionné(s) ({{ selection.length }})</h3>
|
|
2838
|
+
<div v-for="(item, index) in selection" :key="index" class="mb-2 pa-2 bg-grey-lighten-3">
|
|
2839
|
+
<div><strong>Nom:</strong> {{ typeof item === 'object' ? item.lastname : args.items.find(i => JSON.stringify(i) === item)?.lastname }}</div>
|
|
2840
|
+
<div><strong>Prénom:</strong> {{ typeof item === 'object' ? item.firstname : args.items.find(i => JSON.stringify(i) === item)?.firstname }}</div>
|
|
2841
|
+
<div><strong>Email:</strong> {{ typeof item === 'object' ? item.email : args.items.find(i => JSON.stringify(i) === item)?.email }}</div>
|
|
1427
2842
|
</div>
|
|
1428
|
-
</
|
|
1429
|
-
</
|
|
2843
|
+
</div>
|
|
2844
|
+
</div>
|
|
1430
2845
|
`,
|
|
1431
2846
|
}
|
|
1432
2847
|
},
|
|
1433
2848
|
}
|
|
1434
2849
|
|
|
1435
|
-
export const
|
|
2850
|
+
export const ColumnControls: Story = {
|
|
1436
2851
|
parameters: {
|
|
1437
2852
|
sourceCode: [
|
|
1438
2853
|
{
|
|
@@ -1443,9 +2858,8 @@ export const CustomFilterInputs: Story = {
|
|
|
1443
2858
|
v-model:options="options"
|
|
1444
2859
|
:headers="headers"
|
|
1445
2860
|
:items="items"
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
suffix="filter-text-table"
|
|
2861
|
+
suffix="column-control-table"
|
|
2862
|
+
enable-column-controls
|
|
1449
2863
|
/>
|
|
1450
2864
|
</template>
|
|
1451
2865
|
`,
|
|
@@ -1459,27 +2873,20 @@ export const CustomFilterInputs: Story = {
|
|
|
1459
2873
|
|
|
1460
2874
|
const options = ref({
|
|
1461
2875
|
itemsPerPage: 4,
|
|
1462
|
-
filters: []
|
|
1463
2876
|
})
|
|
1464
2877
|
|
|
1465
2878
|
const headers = ref([
|
|
1466
2879
|
{
|
|
1467
2880
|
title: 'Nom',
|
|
1468
2881
|
key: 'lastname',
|
|
1469
|
-
filterable: true,
|
|
1470
|
-
filterType: 'text'
|
|
1471
2882
|
},
|
|
1472
2883
|
{
|
|
1473
2884
|
title: 'Prénom',
|
|
1474
2885
|
key: 'firstname',
|
|
1475
|
-
filterable: true,
|
|
1476
|
-
filterType: 'text'
|
|
1477
2886
|
},
|
|
1478
2887
|
{
|
|
1479
|
-
|
|
2888
|
+
title: 'Email',
|
|
1480
2889
|
value: 'email',
|
|
1481
|
-
filterable: true,
|
|
1482
|
-
filterType: 'text'
|
|
1483
2890
|
},
|
|
1484
2891
|
])
|
|
1485
2892
|
|
|
@@ -1515,41 +2922,27 @@ export const CustomFilterInputs: Story = {
|
|
|
1515
2922
|
email: 'agate.roy@exemple.com'
|
|
1516
2923
|
}
|
|
1517
2924
|
])
|
|
1518
|
-
|
|
1519
|
-
const filterInputConfig = ref({
|
|
1520
|
-
variant: 'outlined',
|
|
1521
|
-
density: 'comfortable',
|
|
1522
|
-
hideDetails: true,
|
|
1523
|
-
clearable: false,
|
|
1524
|
-
disableErrorHandling: true,
|
|
1525
|
-
})
|
|
1526
2925
|
</script>
|
|
1527
2926
|
`,
|
|
1528
2927
|
},
|
|
1529
2928
|
],
|
|
1530
2929
|
},
|
|
1531
2930
|
args: {
|
|
1532
|
-
headers: [
|
|
2931
|
+
'headers': [
|
|
1533
2932
|
{
|
|
1534
2933
|
title: 'Nom',
|
|
1535
2934
|
key: 'lastname',
|
|
1536
|
-
filterable: true,
|
|
1537
|
-
filterType: 'text',
|
|
1538
2935
|
},
|
|
1539
2936
|
{
|
|
1540
2937
|
title: 'Prénom',
|
|
1541
2938
|
key: 'firstname',
|
|
1542
|
-
filterable: true,
|
|
1543
|
-
filterType: 'text',
|
|
1544
2939
|
},
|
|
1545
2940
|
{
|
|
1546
2941
|
title: 'Email',
|
|
1547
2942
|
value: 'email',
|
|
1548
|
-
filterable: true,
|
|
1549
|
-
filterType: 'text',
|
|
1550
2943
|
},
|
|
1551
2944
|
],
|
|
1552
|
-
items: [
|
|
2945
|
+
'items': [
|
|
1553
2946
|
{
|
|
1554
2947
|
firstname: 'Virginie',
|
|
1555
2948
|
lastname: 'Beauchesne',
|
|
@@ -1581,75 +2974,60 @@ export const CustomFilterInputs: Story = {
|
|
|
1581
2974
|
email: 'agate.roy@exemple.com',
|
|
1582
2975
|
},
|
|
1583
2976
|
],
|
|
1584
|
-
|
|
1585
|
-
options: {
|
|
2977
|
+
'options': {
|
|
1586
2978
|
itemsPerPage: 4,
|
|
1587
|
-
filters: [],
|
|
1588
|
-
},
|
|
1589
|
-
filterInputConfig: {
|
|
1590
|
-
variant: 'outlined',
|
|
1591
|
-
density: 'comfortable',
|
|
1592
|
-
hideDetails: true,
|
|
1593
|
-
clearable: false,
|
|
1594
|
-
disableErrorHandling: true,
|
|
1595
2979
|
},
|
|
1596
|
-
|
|
1597
|
-
suffix: '
|
|
1598
|
-
density: 'default',
|
|
1599
|
-
striped: false,
|
|
2980
|
+
'caption': '',
|
|
2981
|
+
'suffix': 'column-control-table',
|
|
2982
|
+
'density': 'default',
|
|
2983
|
+
'striped': false,
|
|
2984
|
+
'enableColumnControls': true,
|
|
2985
|
+
'onUpdate:options': fn(),
|
|
1600
2986
|
},
|
|
1601
|
-
render(args) {
|
|
2987
|
+
render: (args) => {
|
|
1602
2988
|
return {
|
|
1603
2989
|
components: { SyTable },
|
|
1604
2990
|
setup() {
|
|
1605
|
-
|
|
1606
|
-
const options = ref(args.options)
|
|
1607
|
-
const items = ref(args.items)
|
|
1608
|
-
|
|
1609
|
-
return {
|
|
1610
|
-
args,
|
|
1611
|
-
options,
|
|
1612
|
-
items,
|
|
1613
|
-
}
|
|
2991
|
+
return { args }
|
|
1614
2992
|
},
|
|
1615
2993
|
template: `
|
|
1616
2994
|
<SyTable
|
|
1617
|
-
v-model:options="options"
|
|
1618
|
-
|
|
1619
|
-
:items="items"
|
|
1620
|
-
:caption="args.caption"
|
|
1621
|
-
:show-filters="args.showFilters"
|
|
1622
|
-
:filter-input-config="args.filterInputConfig"
|
|
1623
|
-
:resizable-columns="args.resizableColumns"
|
|
1624
|
-
:suffix="args.suffix"
|
|
1625
|
-
:density="args.density"
|
|
2995
|
+
v-model:options="args.options"
|
|
2996
|
+
v-bind="args"
|
|
1626
2997
|
/>
|
|
1627
2998
|
`,
|
|
1628
2999
|
}
|
|
1629
3000
|
},
|
|
1630
3001
|
}
|
|
1631
3002
|
|
|
1632
|
-
export const
|
|
3003
|
+
export const SlotItem: Story = {
|
|
1633
3004
|
parameters: {
|
|
1634
3005
|
sourceCode: [
|
|
1635
3006
|
{
|
|
1636
3007
|
name: 'Template',
|
|
1637
3008
|
code: `
|
|
1638
3009
|
<template>
|
|
1639
|
-
<
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
3010
|
+
<SyTable
|
|
3011
|
+
v-model:options="options"
|
|
3012
|
+
:headers="headers"
|
|
3013
|
+
:items="items"
|
|
3014
|
+
suffix="slot-item-table"
|
|
3015
|
+
>
|
|
3016
|
+
<template #item="{ item }">
|
|
3017
|
+
<tr>
|
|
3018
|
+
<td>{{ item.lastname }}</td>
|
|
3019
|
+
<td>
|
|
3020
|
+
<a
|
|
3021
|
+
href="#"
|
|
3022
|
+
class="text-primary"
|
|
3023
|
+
>
|
|
3024
|
+
{{ item.firstname }}
|
|
3025
|
+
</a>
|
|
3026
|
+
</td>
|
|
3027
|
+
<td>{{ item.email }}</td>
|
|
3028
|
+
</tr>
|
|
3029
|
+
</template>
|
|
3030
|
+
</SyTable>
|
|
1653
3031
|
</template>
|
|
1654
3032
|
`,
|
|
1655
3033
|
},
|
|
@@ -1660,14 +3038,10 @@ export const ManyTables: Story = {
|
|
|
1660
3038
|
import { ref } from 'vue'
|
|
1661
3039
|
import { SyTable } from '@cnamts/synapse'
|
|
1662
3040
|
|
|
1663
|
-
const
|
|
3041
|
+
const options = ref({
|
|
1664
3042
|
itemsPerPage: 4,
|
|
1665
3043
|
})
|
|
1666
3044
|
|
|
1667
|
-
const options2 = ref({
|
|
1668
|
-
itemsPerPage: 2,
|
|
1669
|
-
})
|
|
1670
|
-
|
|
1671
3045
|
const headers = ref([
|
|
1672
3046
|
{
|
|
1673
3047
|
title: 'Nom',
|
|
@@ -1721,7 +3095,7 @@ export const ManyTables: Story = {
|
|
|
1721
3095
|
],
|
|
1722
3096
|
},
|
|
1723
3097
|
args: {
|
|
1724
|
-
headers: [
|
|
3098
|
+
'headers': [
|
|
1725
3099
|
{
|
|
1726
3100
|
title: 'Nom',
|
|
1727
3101
|
key: 'lastname',
|
|
@@ -1735,7 +3109,7 @@ export const ManyTables: Story = {
|
|
|
1735
3109
|
value: 'email',
|
|
1736
3110
|
},
|
|
1737
3111
|
],
|
|
1738
|
-
items: [
|
|
3112
|
+
'items': [
|
|
1739
3113
|
{
|
|
1740
3114
|
firstname: 'Virginie',
|
|
1741
3115
|
lastname: 'Beauchesne',
|
|
@@ -1767,53 +3141,48 @@ export const ManyTables: Story = {
|
|
|
1767
3141
|
email: 'agate.roy@exemple.com',
|
|
1768
3142
|
},
|
|
1769
3143
|
],
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
3144
|
+
'options': {
|
|
3145
|
+
itemsPerPage: 4,
|
|
3146
|
+
},
|
|
3147
|
+
'caption': '',
|
|
3148
|
+
'suffix': 'slot-item-table',
|
|
3149
|
+
'density': 'default',
|
|
3150
|
+
'striped': false,
|
|
3151
|
+
'onUpdate:options': fn(),
|
|
1774
3152
|
},
|
|
1775
|
-
render(args) {
|
|
3153
|
+
render: (args) => {
|
|
1776
3154
|
return {
|
|
1777
3155
|
components: { SyTable },
|
|
1778
3156
|
setup() {
|
|
1779
|
-
|
|
1780
|
-
itemsPerPage: 4,
|
|
1781
|
-
})
|
|
1782
|
-
const options2 = ref<Partial<DataOptions>>({
|
|
1783
|
-
itemsPerPage: 2,
|
|
1784
|
-
})
|
|
1785
|
-
return { args, options1, options2 }
|
|
3157
|
+
return { args }
|
|
1786
3158
|
},
|
|
1787
3159
|
template: `
|
|
1788
|
-
<
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
suffix="table2"
|
|
1809
|
-
/>
|
|
1810
|
-
</div>
|
|
3160
|
+
<SyTable
|
|
3161
|
+
v-model:options="args.options"
|
|
3162
|
+
v-bind="args"
|
|
3163
|
+
suffix="slot-item-table"
|
|
3164
|
+
>
|
|
3165
|
+
<template #item="{ item }">
|
|
3166
|
+
<tr>
|
|
3167
|
+
<td>{{ item.lastname }}</td>
|
|
3168
|
+
<td>
|
|
3169
|
+
<a
|
|
3170
|
+
href="#"
|
|
3171
|
+
class="text-primary"
|
|
3172
|
+
>
|
|
3173
|
+
{{ item.firstname }}
|
|
3174
|
+
</a>
|
|
3175
|
+
</td>
|
|
3176
|
+
<td>{{ item.email }}</td>
|
|
3177
|
+
</tr>
|
|
3178
|
+
</template>
|
|
3179
|
+
</SyTable>
|
|
1811
3180
|
`,
|
|
1812
3181
|
}
|
|
1813
3182
|
},
|
|
1814
3183
|
}
|
|
1815
3184
|
|
|
1816
|
-
export const
|
|
3185
|
+
export const SlotHeaders: Story = {
|
|
1817
3186
|
parameters: {
|
|
1818
3187
|
sourceCode: [
|
|
1819
3188
|
{
|
|
@@ -1824,9 +3193,21 @@ export const ResizableColumns: Story = {
|
|
|
1824
3193
|
v-model:options="options"
|
|
1825
3194
|
:headers="headers"
|
|
1826
3195
|
:items="items"
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
3196
|
+
suffix="slot-item-table"
|
|
3197
|
+
>
|
|
3198
|
+
<template #headers="{ columns }">
|
|
3199
|
+
<tr>
|
|
3200
|
+
<th
|
|
3201
|
+
v-for="column in columns"
|
|
3202
|
+
:key="column.key"
|
|
3203
|
+
>
|
|
3204
|
+
<span class="font-weight-bold text-primary">
|
|
3205
|
+
{{ column.title }}
|
|
3206
|
+
</span>
|
|
3207
|
+
</th>
|
|
3208
|
+
</tr>
|
|
3209
|
+
</template>
|
|
3210
|
+
</SyTable>
|
|
1830
3211
|
</template>
|
|
1831
3212
|
`,
|
|
1832
3213
|
},
|
|
@@ -1851,7 +3232,7 @@ export const ResizableColumns: Story = {
|
|
|
1851
3232
|
key: 'firstname',
|
|
1852
3233
|
},
|
|
1853
3234
|
{
|
|
1854
|
-
|
|
3235
|
+
title: 'Email',
|
|
1855
3236
|
value: 'email',
|
|
1856
3237
|
},
|
|
1857
3238
|
])
|
|
@@ -1894,8 +3275,7 @@ export const ResizableColumns: Story = {
|
|
|
1894
3275
|
],
|
|
1895
3276
|
},
|
|
1896
3277
|
args: {
|
|
1897
|
-
|
|
1898
|
-
headers: [
|
|
3278
|
+
'headers': [
|
|
1899
3279
|
{
|
|
1900
3280
|
title: 'Nom',
|
|
1901
3281
|
key: 'lastname',
|
|
@@ -1909,7 +3289,7 @@ export const ResizableColumns: Story = {
|
|
|
1909
3289
|
value: 'email',
|
|
1910
3290
|
},
|
|
1911
3291
|
],
|
|
1912
|
-
items: [
|
|
3292
|
+
'items': [
|
|
1913
3293
|
{
|
|
1914
3294
|
firstname: 'Virginie',
|
|
1915
3295
|
lastname: 'Beauchesne',
|
|
@@ -1941,12 +3321,16 @@ export const ResizableColumns: Story = {
|
|
|
1941
3321
|
email: 'agate.roy@exemple.com',
|
|
1942
3322
|
},
|
|
1943
3323
|
],
|
|
1944
|
-
options: {
|
|
3324
|
+
'options': {
|
|
1945
3325
|
itemsPerPage: 4,
|
|
1946
3326
|
},
|
|
1947
|
-
|
|
3327
|
+
'caption': '',
|
|
3328
|
+
'suffix': 'slot-item-table',
|
|
3329
|
+
'density': 'default',
|
|
3330
|
+
'striped': false,
|
|
3331
|
+
'onUpdate:options': fn(),
|
|
1948
3332
|
},
|
|
1949
|
-
render(args) {
|
|
3333
|
+
render: (args) => {
|
|
1950
3334
|
return {
|
|
1951
3335
|
components: { SyTable },
|
|
1952
3336
|
setup() {
|
|
@@ -1955,11 +3339,22 @@ export const ResizableColumns: Story = {
|
|
|
1955
3339
|
template: `
|
|
1956
3340
|
<SyTable
|
|
1957
3341
|
v-model:options="args.options"
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
|
|
3342
|
+
v-bind="args"
|
|
3343
|
+
suffix="slot-item-table"
|
|
3344
|
+
>
|
|
3345
|
+
<template #headers="{ columns }">
|
|
3346
|
+
<tr>
|
|
3347
|
+
<th
|
|
3348
|
+
v-for="column in columns"
|
|
3349
|
+
:key="column.key"
|
|
3350
|
+
>
|
|
3351
|
+
<span class="font-weight-bold text-primary">
|
|
3352
|
+
{{ column.title }}
|
|
3353
|
+
</span>
|
|
3354
|
+
</th>
|
|
3355
|
+
</tr>
|
|
3356
|
+
</template>
|
|
3357
|
+
</SyTable>
|
|
1963
3358
|
`,
|
|
1964
3359
|
}
|
|
1965
3360
|
},
|