@alveole/components 2.0.0-alpha → 2.0.0-alpha.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/A/A.d.ts +3 -1
- package/dist/core/A/A.d.ts.map +1 -1
- package/dist/core/A/A.js +2 -2
- package/dist/core/Box/Box.d.ts +8 -8
- package/dist/core/Box/Box.d.ts.map +1 -1
- package/dist/core/Box/Box.js +6 -3
- package/dist/core/Box/Box.stories.d.ts +5 -5
- package/dist/core/Box/Box.stories.js +1 -1
- package/dist/core/Box/Box.stories.sources.d.ts.map +1 -1
- package/dist/core/Box/Box.stories.sources.js +1 -1
- package/dist/core/Box/Box.types.d.ts +3 -3
- package/dist/core/Box/Box.types.d.ts.map +1 -1
- package/dist/core/Form/Form.web.d.ts.map +1 -1
- package/dist/core/Form/Form.web.js +4 -1
- package/dist/core/Grid/Grid.stories.d.ts +4 -4
- package/dist/core/Map/useGoogleMap.d.ts +2 -1
- package/dist/core/Map/useGoogleMap.d.ts.map +1 -1
- package/dist/core/Map/useGoogleMap.js +3 -2
- package/dist/core/MarkdownDescription/MarkdownDescription.d.ts.map +1 -1
- package/dist/core/MarkdownDescription/MarkdownDescription.js +0 -4
- package/dist/core/MarkdownDescription/markdownComponents.d.ts +0 -6
- package/dist/core/MarkdownDescription/markdownComponents.d.ts.map +1 -1
- package/dist/core/MarkdownDescription/markdownComponents.js +3 -2
- package/dist/core/Page/Page.stories.d.ts +5 -0
- package/dist/core/Page/Page.stories.d.ts.map +1 -1
- package/dist/core/Page/Page.stories.js +5 -0
- package/dist/core/Page/Page.stories.sources.d.ts +2 -0
- package/dist/core/Page/Page.stories.sources.d.ts.map +1 -1
- package/dist/core/Page/Page.stories.sources.js +3 -0
- package/dist/core/Page/Page.types.d.ts +1 -0
- package/dist/core/Page/Page.types.d.ts.map +1 -1
- package/dist/core/Page/PageBackground.d.ts +5 -5
- package/dist/core/Page/PageBackground.d.ts.map +1 -1
- package/dist/core/Page/PageBackground.js +8 -5
- package/dist/core/Page/PageBackground.stories.d.ts +25 -0
- package/dist/core/Page/PageBackground.stories.d.ts.map +1 -0
- package/dist/core/Page/PageBackground.stories.js +28 -0
- package/dist/core/Page/PageBackground.stories.sources.d.ts +8 -0
- package/dist/core/Page/PageBackground.stories.sources.d.ts.map +1 -0
- package/dist/core/Page/PageBackground.stories.sources.js +8 -0
- package/dist/core/Page/PageContent.js +2 -2
- package/dist/core/Page/PageContentDefault.d.ts.map +1 -1
- package/dist/core/Page/PageContentDefault.js +1 -1
- package/dist/core/Page/PageContentScrollable.d.ts +6 -5
- package/dist/core/Page/PageContentScrollable.d.ts.map +1 -1
- package/dist/core/Page/PageContentScrollable.js +1 -1
- package/dist/core/Page/index.d.ts +1 -0
- package/dist/core/Page/index.d.ts.map +1 -1
- package/dist/core/Page/index.js +1 -0
- package/dist/core/Typography/Typography.d.ts +5 -5
- package/dist/core/Typography/Typography.d.ts.map +1 -1
- package/dist/core/Typography/Typography.js +16 -4
- package/dist/core/Typography/Typography.stories.d.ts +2 -2
- package/dist/core/Typography/couleurDuTexte.d.ts +1 -1
- package/dist/core/Typography/couleurDuTexte.d.ts.map +1 -1
- package/dist/core/UpdateRequired/UpdateRequired.d.ts.map +1 -1
- package/dist/core/UpdateRequired/UpdateRequired.js +4 -1
- package/dist/core/animation/animer.d.ts +9 -0
- package/dist/core/animation/animer.d.ts.map +1 -0
- package/dist/core/animation/animer.js +5 -0
- package/dist/core/styleTamagui/aplatirStyle.d.ts +2 -0
- package/dist/core/styleTamagui/aplatirStyle.d.ts.map +1 -0
- package/dist/core/styleTamagui/aplatirStyle.js +9 -0
- package/dist/core/styleTamagui/definis.d.ts +4 -0
- package/dist/core/styleTamagui/definis.d.ts.map +1 -0
- package/dist/core/styleTamagui/definis.js +3 -0
- package/dist/core/styleTamagui/flexDuWeb.d.ts +23 -0
- package/dist/core/styleTamagui/flexDuWeb.d.ts.map +1 -0
- package/dist/core/styleTamagui/flexDuWeb.js +19 -0
- package/dist/core/styleTamagui/fondAuSurvol.d.ts +14 -0
- package/dist/core/styleTamagui/fondAuSurvol.d.ts.map +1 -0
- package/dist/core/styleTamagui/fondAuSurvol.js +8 -0
- package/dist/core/styleTamagui/sansEstompage.d.ts +4 -0
- package/dist/core/styleTamagui/sansEstompage.d.ts.map +1 -0
- package/dist/core/styleTamagui/sansEstompage.js +4 -0
- package/dist/core/styleTamagui/soulignement.d.ts +11 -0
- package/dist/core/styleTamagui/soulignement.d.ts.map +1 -0
- package/dist/core/styleTamagui/soulignement.js +5 -0
- package/dist/generated/version.d.ts +1 -1
- package/dist/generated/version.d.ts.map +1 -1
- package/dist/generated/version.js +1 -1
- package/dist/pdfjs/pdf.min.mjs +4 -5
- package/dist/pdfjs/pdf.worker.min.mjs +4 -5
- package/dist/stories/index.d.ts +2 -1
- package/dist/stories/index.d.ts.map +1 -1
- package/dist/stories/index.js +2 -1
- package/dist/ui/Accordion/AccordionItem.d.ts.map +1 -1
- package/dist/ui/Accordion/AccordionItem.js +2 -1
- package/dist/ui/ActionMenu/ActionMenuItem.d.ts.map +1 -1
- package/dist/ui/ActionMenu/ActionMenuItem.js +5 -5
- package/dist/ui/Avatar/Avatar.d.ts.map +1 -1
- package/dist/ui/Avatar/Avatar.js +6 -1
- package/dist/ui/Badge/Badge.d.ts.map +1 -1
- package/dist/ui/Badge/Badge.js +3 -2
- package/dist/ui/Badge/Badge.stories.d.ts +16 -12
- package/dist/ui/Badge/Badge.stories.d.ts.map +1 -1
- package/dist/ui/Badge/Badge.styles.d.ts +16 -12
- package/dist/ui/Badge/Badge.styles.d.ts.map +1 -1
- package/dist/ui/Badge/Badge.styles.js +4 -2
- package/dist/ui/BottomSheet/BottomSheet.d.ts.map +1 -1
- package/dist/ui/BottomSheet/BottomSheet.js +2 -1
- package/dist/ui/BottomSheet/BottomSheet.stories.d.ts +6 -4
- package/dist/ui/BottomSheet/BottomSheet.stories.d.ts.map +1 -1
- package/dist/ui/BottomSheet/BottomSheet.styles.d.ts +6 -4
- package/dist/ui/BottomSheet/BottomSheet.styles.d.ts.map +1 -1
- package/dist/ui/BottomSheet/BottomSheet.styles.js +6 -4
- package/dist/ui/Breadcrumbs/Breadcrumbs.d.ts.map +1 -1
- package/dist/ui/Breadcrumbs/Breadcrumbs.js +2 -1
- package/dist/ui/Breadcrumbs/Breadcrumbs.stories.d.ts +5 -4
- package/dist/ui/Breadcrumbs/Breadcrumbs.stories.d.ts.map +1 -1
- package/dist/ui/Breadcrumbs/Breadcrumbs.styles.d.ts +5 -4
- package/dist/ui/Breadcrumbs/Breadcrumbs.styles.d.ts.map +1 -1
- package/dist/ui/Breadcrumbs/Breadcrumbs.styles.js +1 -4
- package/dist/ui/Button/Button.d.ts.map +1 -1
- package/dist/ui/Button/Button.js +22 -2
- package/dist/ui/Button/Button.stories.d.ts +12 -0
- package/dist/ui/Button/Button.stories.d.ts.map +1 -1
- package/dist/ui/Button/Button.stories.js +24 -4
- package/dist/ui/Button/Button.stories.sources.d.ts +2 -0
- package/dist/ui/Button/Button.stories.sources.d.ts.map +1 -1
- package/dist/ui/Button/Button.stories.sources.js +6 -3
- package/dist/ui/Button/Button.types.d.ts +4 -0
- package/dist/ui/Button/Button.types.d.ts.map +1 -1
- package/dist/ui/Button/ButtonContent.d.ts.map +1 -1
- package/dist/ui/Button/ButtonContent.js +7 -3
- package/dist/ui/Button/buttonIconStyling.d.ts +2 -2
- package/dist/ui/Button/buttonStyling.d.ts +9 -3
- package/dist/ui/Button/buttonStyling.d.ts.map +1 -1
- package/dist/ui/Button/buttonStyling.js +7 -3
- package/dist/ui/Checkbox/Checkbox.d.ts +6 -6
- package/dist/ui/Checkbox/Checkbox.js +2 -2
- package/dist/ui/Checkbox/Checkbox.stories.d.ts +7 -7
- package/dist/ui/Checkbox/Checkbox.styles.d.ts +1 -1
- package/dist/ui/Checkbox/Checkbox.styles.d.ts.map +1 -1
- package/dist/ui/Checkbox/Checkbox.styles.js +3 -4
- package/dist/ui/Checkbox/CheckboxContainer.d.ts +6 -6
- package/dist/ui/Checkbox/CheckboxContainer.d.ts.map +1 -1
- package/dist/ui/Checkbox/CheckboxContainer.js +4 -8
- package/dist/ui/Checkbox/CheckboxLabel.d.ts +1 -1
- package/dist/ui/Checkbox/CheckboxLabel.d.ts.map +1 -1
- package/dist/ui/Checkbox/CheckboxLabel.js +2 -2
- package/dist/ui/DataTable/DataTable.demo.deployments.js +1 -1
- package/dist/ui/DataTable/DataTable.stories.d.ts +3 -1
- package/dist/ui/DataTable/DataTable.stories.d.ts.map +1 -1
- package/dist/ui/DataTable/DataTable.styles.d.ts +3 -1
- package/dist/ui/DataTable/DataTable.styles.d.ts.map +1 -1
- package/dist/ui/DataTable/DataTable.styles.js +5 -1
- package/dist/ui/DataTable/DataTableCell.js +1 -1
- package/dist/ui/DataTable/DataTableRow.d.ts.map +1 -1
- package/dist/ui/DataTable/DataTableRow.js +4 -2
- package/dist/ui/DataTable/dataTableCellStyle.d.ts +2 -2
- package/dist/ui/DataTable/dataTableCellStyle.js +1 -1
- package/dist/ui/DateInput/DateInput.ios.d.ts +1 -1
- package/dist/ui/DateInput/DateInput.stories.d.ts +1 -1
- package/dist/ui/DateInput/DateInput.web.d.ts +1 -1
- package/dist/ui/DocumentViewer/DocumentViewer.stories.d.ts +1 -0
- package/dist/ui/DocumentViewer/DocumentViewer.stories.d.ts.map +1 -1
- package/dist/ui/DocumentViewer/DocumentViewer.stories.js +1 -1
- package/dist/ui/DocumentViewer/DocumentViewer.stories.sources.d.ts.map +1 -1
- package/dist/ui/DocumentViewer/DocumentViewer.stories.sources.js +1 -1
- package/dist/ui/DocumentViewer/DocumentViewer.styles.d.ts +1 -0
- package/dist/ui/DocumentViewer/DocumentViewer.styles.d.ts.map +1 -1
- package/dist/ui/DocumentViewer/DocumentViewer.styles.js +3 -0
- package/dist/ui/DocumentViewer/DocumentViewerImage.d.ts.map +1 -1
- package/dist/ui/DocumentViewer/pointeurWeb.d.ts +13 -3
- package/dist/ui/DocumentViewer/pointeurWeb.d.ts.map +1 -1
- package/dist/ui/DocumentViewer/pointeurWeb.js +1 -1
- package/dist/ui/DocumentViewer/useSurvolAvecZoom.d.ts +2 -2
- package/dist/ui/DocumentViewer/useSurvolAvecZoom.d.ts.map +1 -1
- package/dist/ui/FileDropZone/FileDropZone.d.ts +10 -0
- package/dist/ui/FileDropZone/FileDropZone.d.ts.map +1 -0
- package/dist/ui/FileDropZone/FileDropZone.js +3 -0
- package/dist/ui/FileDropZone/FileDropZone.stories.d.ts +50 -0
- package/dist/ui/FileDropZone/FileDropZone.stories.d.ts.map +1 -0
- package/dist/ui/FileDropZone/FileDropZone.stories.js +29 -0
- package/dist/ui/FileDropZone/FileDropZone.stories.sources.d.ts +10 -0
- package/dist/ui/FileDropZone/FileDropZone.stories.sources.d.ts.map +1 -0
- package/dist/ui/FileDropZone/FileDropZone.stories.sources.js +10 -0
- package/dist/ui/FileDropZone/FileDropZone.styles.d.ts +37 -0
- package/dist/ui/FileDropZone/FileDropZone.styles.d.ts.map +1 -0
- package/dist/ui/FileDropZone/FileDropZone.styles.js +35 -0
- package/dist/ui/FileDropZone/FileDropZone.web.d.ts +4 -0
- package/dist/ui/FileDropZone/FileDropZone.web.d.ts.map +1 -0
- package/dist/ui/FileDropZone/FileDropZone.web.js +11 -0
- package/dist/ui/FileDropZone/fichiersDuDataTransfer.d.ts.map +1 -0
- package/dist/ui/FileDropZone/index.d.ts +2 -0
- package/dist/ui/FileDropZone/index.d.ts.map +1 -0
- package/dist/ui/FileDropZone/index.js +1 -0
- package/dist/ui/FileDropZone/useDepotFichier.d.ts +17 -0
- package/dist/ui/FileDropZone/useDepotFichier.d.ts.map +1 -0
- package/dist/ui/FileDropZone/useDepotFichier.js +89 -0
- package/dist/ui/FilterDate/FilterDate.d.ts +1 -1
- package/dist/ui/FilterDate/FilterDate.d.ts.map +1 -1
- package/dist/ui/FormControl/FileInput.d.ts +10 -12
- package/dist/ui/FormControl/FileInput.d.ts.map +1 -1
- package/dist/ui/FormControl/FileInput.js +15 -53
- package/dist/ui/FormControl/FileInput.stories.d.ts +8 -40
- package/dist/ui/FormControl/FileInput.stories.d.ts.map +1 -1
- package/dist/ui/FormControl/FileInput.stories.js +46 -4
- package/dist/ui/FormControl/FileInput.stories.sources.d.ts +10 -0
- package/dist/ui/FormControl/FileInput.stories.sources.d.ts.map +1 -1
- package/dist/ui/FormControl/FileInput.stories.sources.js +11 -1
- package/dist/ui/FormControl/FileInput.styles.d.ts +2 -39
- package/dist/ui/FormControl/FileInput.styles.d.ts.map +1 -1
- package/dist/ui/FormControl/FileInput.styles.js +3 -32
- package/dist/ui/FormControl/FileInputListe.d.ts +11 -0
- package/dist/ui/FormControl/FileInputListe.d.ts.map +1 -0
- package/dist/ui/FormControl/FileInputListe.js +24 -0
- package/dist/ui/FormControl/fichierCorrespondAuType.d.ts +1 -0
- package/dist/ui/FormControl/fichierCorrespondAuType.d.ts.map +1 -1
- package/dist/ui/FormControl/fichierCorrespondAuType.js +5 -1
- package/dist/ui/FormControl/fichiersDuChamp.d.ts +43 -0
- package/dist/ui/FormControl/fichiersDuChamp.d.ts.map +1 -0
- package/dist/ui/FormControl/fichiersDuChamp.js +63 -0
- package/dist/ui/FormControl/useChoixDeFichier.d.ts +15 -0
- package/dist/ui/FormControl/useChoixDeFichier.d.ts.map +1 -0
- package/dist/ui/FormControl/useChoixDeFichier.js +87 -0
- package/dist/ui/FormControl/valideLeType.d.ts +1 -1
- package/dist/ui/FormControl/valideLeType.js +1 -1
- package/dist/ui/Header/Header.d.ts.map +1 -1
- package/dist/ui/Header/Header.js +1 -1
- package/dist/ui/Link/Link.d.ts.map +1 -1
- package/dist/ui/Link/Link.js +2 -1
- package/dist/ui/Link/Link.stories.d.ts +0 -4
- package/dist/ui/Link/Link.stories.d.ts.map +1 -1
- package/dist/ui/Link/Link.styles.d.ts +0 -4
- package/dist/ui/Link/Link.styles.d.ts.map +1 -1
- package/dist/ui/Link/Link.styles.js +0 -4
- package/dist/ui/ListItem/ListItem.d.ts.map +1 -1
- package/dist/ui/ListItem/ListItem.js +2 -1
- package/dist/ui/ListItem/ListItem.stories.d.ts +4 -2
- package/dist/ui/ListItem/ListItem.stories.d.ts.map +1 -1
- package/dist/ui/ListItem/ListItem.styles.d.ts +4 -2
- package/dist/ui/ListItem/ListItem.styles.d.ts.map +1 -1
- package/dist/ui/ListItem/ListItem.styles.js +6 -2
- package/dist/ui/LucideIcon/catalogueLucide.d.ts +171 -0
- package/dist/ui/LucideIcon/catalogueLucide.d.ts.map +1 -1
- package/dist/ui/LucideIcon/vendor/lab.js +1 -1
- package/dist/ui/LucideIcon/vendor/lucide.d.ts +2613 -1920
- package/dist/ui/LucideIcon/vendor/lucide.js +3 -3
- package/dist/ui/ProgressBar/ProgressBar.stories.d.ts +1 -0
- package/dist/ui/ProgressBar/ProgressBar.stories.d.ts.map +1 -1
- package/dist/ui/ProgressBar/ProgressBar.styles.d.ts +1 -0
- package/dist/ui/ProgressBar/ProgressBar.styles.d.ts.map +1 -1
- package/dist/ui/ProgressBar/ProgressBar.styles.js +2 -0
- package/dist/ui/RadioGroup/RadioGroup.d.ts +5 -3
- package/dist/ui/RadioGroup/RadioGroup.d.ts.map +1 -1
- package/dist/ui/RadioGroup/RadioGroup.js +5 -1
- package/dist/ui/RadioGroup/RadioGroup.stories.d.ts +2 -4
- package/dist/ui/RadioGroup/RadioGroup.stories.d.ts.map +1 -1
- package/dist/ui/RadioGroup/RadioGroup.styles.d.ts +1 -3
- package/dist/ui/RadioGroup/RadioGroup.styles.d.ts.map +1 -1
- package/dist/ui/RadioGroup/RadioGroup.styles.js +3 -6
- package/dist/ui/RadioGroup/RadioGroupCard.d.ts.map +1 -1
- package/dist/ui/RadioGroup/RadioGroupCard.js +2 -2
- package/dist/ui/RadioGroup/RadioGroupItem.d.ts.map +1 -1
- package/dist/ui/RadioGroup/RadioGroupItem.js +2 -2
- package/dist/ui/RadioGroup/RadioInput.d.ts.map +1 -1
- package/dist/ui/RadioGroup/RadioInput.js +5 -7
- package/dist/ui/RadioGroup/index.d.ts +1 -1
- package/dist/ui/Select/Select.types.d.ts +2 -0
- package/dist/ui/Select/Select.types.d.ts.map +1 -1
- package/dist/ui/Select/SelectBottomSheet.js +2 -2
- package/dist/ui/Select/SelectItem.js +1 -1
- package/dist/ui/Select/SelectList.styles.d.ts +1 -9
- package/dist/ui/Select/SelectList.styles.d.ts.map +1 -1
- package/dist/ui/Select/SelectList.styles.js +5 -6
- package/dist/ui/Select/SelectOptionsList.d.ts +1 -0
- package/dist/ui/Select/SelectOptionsList.d.ts.map +1 -1
- package/dist/ui/Select/selectItemStyle.d.ts +4 -4
- package/dist/ui/Select/selectItemStyle.d.ts.map +1 -1
- package/dist/ui/Select/selectItemStyle.js +7 -3
- package/dist/ui/Select/useDefilementVersSelection.d.ts +3 -2
- package/dist/ui/Select/useDefilementVersSelection.d.ts.map +1 -1
- package/dist/ui/Sidebar/Sidebar.stories.d.ts +0 -7
- package/dist/ui/Sidebar/Sidebar.stories.d.ts.map +1 -1
- package/dist/ui/Sidebar/Sidebar.styles.d.ts +0 -7
- package/dist/ui/Sidebar/Sidebar.styles.d.ts.map +1 -1
- package/dist/ui/Sidebar/Sidebar.styles.js +0 -3
- package/dist/ui/Sidebar/SidebarItem.d.ts.map +1 -1
- package/dist/ui/Sidebar/SidebarItem.js +13 -9
- package/dist/ui/Signature/Signature.d.ts +1 -1
- package/dist/ui/Signature/Signature.d.ts.map +1 -1
- package/dist/ui/Skeleton/Skeleton.stories.d.ts +1 -0
- package/dist/ui/Skeleton/Skeleton.stories.d.ts.map +1 -1
- package/dist/ui/Skeleton/Skeleton.styles.d.ts +1 -0
- package/dist/ui/Skeleton/Skeleton.styles.d.ts.map +1 -1
- package/dist/ui/Skeleton/Skeleton.styles.js +2 -0
- package/dist/ui/Switch/Switch.d.ts +1 -1
- package/dist/ui/Switch/Switch.d.ts.map +1 -1
- package/dist/ui/Switch/Switch.js +11 -8
- package/dist/ui/Switch/Switch.stories.d.ts +3 -2
- package/dist/ui/Switch/Switch.stories.d.ts.map +1 -1
- package/dist/ui/Switch/Switch.styles.d.ts +2 -1
- package/dist/ui/Switch/Switch.styles.d.ts.map +1 -1
- package/dist/ui/Switch/Switch.styles.js +5 -4
- package/dist/ui/Tabs/Tabs.d.ts +1 -1
- package/dist/ui/Tabs/Tabs.d.ts.map +1 -1
- package/dist/ui/Tabs/Tabs.js +1 -1
- package/dist/ui/Tabs/Tabs.stories.d.ts +26 -5
- package/dist/ui/Tabs/Tabs.stories.d.ts.map +1 -1
- package/dist/ui/Tabs/Tabs.styles.d.ts +26 -5
- package/dist/ui/Tabs/Tabs.styles.d.ts.map +1 -1
- package/dist/ui/Tabs/Tabs.styles.js +6 -2
- package/dist/ui/Tabs/TabsTab.js +1 -1
- package/dist/ui/Tabs/useTabsState.d.ts +1 -1
- package/dist/ui/Tabs/useTabsState.d.ts.map +1 -1
- package/dist/ui/Tabs/useTabsState.js +7 -4
- package/dist/ui/Toast/Toast.d.ts +3 -3
- package/dist/ui/Toast/Toast.d.ts.map +1 -1
- package/dist/ui/Toast/Toast.js +5 -7
- package/dist/ui/Toast/Toast.stories.d.ts +10 -7
- package/dist/ui/Toast/Toast.stories.d.ts.map +1 -1
- package/dist/ui/Toast/Toast.stories.js +12 -9
- package/dist/ui/Toast/Toast.stories.sources.js +1 -1
- package/dist/ui/Toast/ToastContext.d.ts +1 -0
- package/dist/ui/Toast/ToastContext.d.ts.map +1 -1
- package/dist/ui/Toast/ToastContext.js +1 -0
- package/dist/ui/Toast/Toasts.d.ts +2 -1
- package/dist/ui/Toast/Toasts.d.ts.map +1 -1
- package/dist/ui/Toast/Toasts.js +9 -5
- package/dist/ui/ToolbarTop/toolbarTopStyling.d.ts +2 -2
- package/dist/ui/index.d.ts +1 -1
- package/dist/ui/index.d.ts.map +1 -1
- package/dist/ui/index.js +1 -1
- package/package.json +34 -30
- package/dist/core/styleTamagui/versStyleTamagui.d.ts +0 -10
- package/dist/core/styleTamagui/versStyleTamagui.d.ts.map +0 -1
- package/dist/core/styleTamagui/versStyleTamagui.js +0 -8
- package/dist/ui/DragAndDropFile/DragAndDropFile.d.ts +0 -10
- package/dist/ui/DragAndDropFile/DragAndDropFile.d.ts.map +0 -1
- package/dist/ui/DragAndDropFile/DragAndDropFile.js +0 -13
- package/dist/ui/DragAndDropFile/DragAndDropFile.stories.d.ts +0 -56
- package/dist/ui/DragAndDropFile/DragAndDropFile.stories.d.ts.map +0 -1
- package/dist/ui/DragAndDropFile/DragAndDropFile.stories.js +0 -17
- package/dist/ui/DragAndDropFile/DragAndDropFile.stories.sources.d.ts +0 -10
- package/dist/ui/DragAndDropFile/DragAndDropFile.stories.sources.d.ts.map +0 -1
- package/dist/ui/DragAndDropFile/DragAndDropFile.stories.sources.js +0 -10
- package/dist/ui/DragAndDropFile/DragAndDropFile.styles.d.ts +0 -43
- package/dist/ui/DragAndDropFile/DragAndDropFile.styles.d.ts.map +0 -1
- package/dist/ui/DragAndDropFile/DragAndDropFile.styles.js +0 -43
- package/dist/ui/DragAndDropFile/DragAndDropFile.web.d.ts +0 -3
- package/dist/ui/DragAndDropFile/DragAndDropFile.web.d.ts.map +0 -1
- package/dist/ui/DragAndDropFile/DragAndDropFile.web.js +0 -18
- package/dist/ui/DragAndDropFile/fichiersDuDataTransfer.d.ts.map +0 -1
- package/dist/ui/DragAndDropFile/index.d.ts +0 -2
- package/dist/ui/DragAndDropFile/index.d.ts.map +0 -1
- package/dist/ui/DragAndDropFile/index.js +0 -1
- package/dist/ui/DragAndDropFile/useDepotFichier.d.ts +0 -21
- package/dist/ui/DragAndDropFile/useDepotFichier.d.ts.map +0 -1
- package/dist/ui/DragAndDropFile/useDepotFichier.js +0 -77
- package/dist/ui/Toast/ToastBridge.d.ts +0 -11
- package/dist/ui/Toast/ToastBridge.d.ts.map +0 -1
- package/dist/ui/Toast/ToastBridge.js +0 -19
- /package/dist/ui/{DragAndDropFile → FileDropZone}/fichiersDuDataTransfer.d.ts +0 -0
- /package/dist/ui/{DragAndDropFile → FileDropZone}/fichiersDuDataTransfer.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Toasts.d.ts","sourceRoot":"","sources":["../../../src/ui/Toast/Toasts.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"Toasts.d.ts","sourceRoot":"","sources":["../../../src/ui/Toast/Toasts.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAiC,KAAK,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAE9E,MAAM,MAAM,WAAW,GAAG,KAAK,CAAC,iBAAiB,CAAC,MAAM,CAAC,CAAC;AAmB1D,wBAAgB,MAAM,CAAC,KAAK,EAAE,WAAW,qBAaxC;AAED,wBAAgB,QAAQ,aAIvB"}
|
package/dist/ui/Toast/Toasts.js
CHANGED
|
@@ -1,12 +1,16 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
2
|
+
import { Toast as TamaguiToast, toast } from '@tamagui/toast';
|
|
3
3
|
import React from 'react';
|
|
4
|
-
import { Toast } from './Toast';
|
|
5
|
-
import {
|
|
6
|
-
|
|
4
|
+
import { Toast, ToastView } from './Toast';
|
|
5
|
+
import { defaultDuration, ToastContext } from './ToastContext';
|
|
6
|
+
const api = {
|
|
7
|
+
present: (title, message, opts) => {
|
|
8
|
+
toast.custom(id => (_jsx(ToastView, { title: title, message: message, variant: opts?.variant, leading: opts?.leading, onClose: () => toast.dismiss(id) })), { duration: opts?.duration });
|
|
9
|
+
},
|
|
10
|
+
};
|
|
7
11
|
export function Toasts(props) {
|
|
8
12
|
const { children } = props;
|
|
9
|
-
return (_jsx(
|
|
13
|
+
return (_jsx(TamaguiToast, { position: "bottom-center", duration: defaultDuration, swipeDirection: "horizontal", children: _jsxs(ToastContext.Provider, { value: api, children: [children, _jsx(TamaguiToast.Viewport, { offset: 32, children: _jsx(TamaguiToast.List, { renderItem: item => _jsx(Toast, { ...item }) }) })] }) }));
|
|
10
14
|
}
|
|
11
15
|
export function useToast() {
|
|
12
16
|
const ctx = React.useContext(ToastContext);
|
|
@@ -200,7 +200,7 @@ export declare const styleDuTitre: (styles: Styles, grandTitre: boolean, typogra
|
|
|
200
200
|
fontVariantNumeric?: import("csstype").Property.FontVariantNumeric | undefined;
|
|
201
201
|
fontVariantPosition?: import("csstype").Property.FontVariantPosition | undefined;
|
|
202
202
|
fontVariationSettings?: import("csstype").Property.FontVariationSettings | undefined;
|
|
203
|
-
fontWeight?: "100" | "200" | "300" | "400" | "500" | "600" | "800" | "black" |
|
|
203
|
+
fontWeight?: "100" | "200" | "300" | "400" | "500" | "600" | "800" | "black" | "light" | "medium" | "thin" | import("csstype").Property.FontWeight | "700" | "900" | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900 | "ultralight" | "regular" | "semibold" | "condensedBold" | "condensed" | "heavy" | undefined;
|
|
204
204
|
fontWidth?: import("csstype").Property.FontWidth | undefined;
|
|
205
205
|
forcedColorAdjust?: import("csstype").Property.ForcedColorAdjust | undefined;
|
|
206
206
|
gridAutoColumns?: import("csstype").Property.GridAutoColumns<string | number> | undefined;
|
|
@@ -1059,7 +1059,7 @@ export declare const styleDuSousTitre: (styles: Styles, grandTitre: boolean, typ
|
|
|
1059
1059
|
fontVariantNumeric?: import("csstype").Property.FontVariantNumeric | undefined;
|
|
1060
1060
|
fontVariantPosition?: import("csstype").Property.FontVariantPosition | undefined;
|
|
1061
1061
|
fontVariationSettings?: import("csstype").Property.FontVariationSettings | undefined;
|
|
1062
|
-
fontWeight?: "100" | "200" | "300" | "400" | "500" | "600" | "800" | "black" |
|
|
1062
|
+
fontWeight?: "100" | "200" | "300" | "400" | "500" | "600" | "800" | "black" | "light" | "medium" | "thin" | import("csstype").Property.FontWeight | "700" | "900" | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900 | "ultralight" | "regular" | "semibold" | "condensedBold" | "condensed" | "heavy" | undefined;
|
|
1063
1063
|
fontWidth?: import("csstype").Property.FontWidth | undefined;
|
|
1064
1064
|
forcedColorAdjust?: import("csstype").Property.ForcedColorAdjust | undefined;
|
|
1065
1065
|
gridAutoColumns?: import("csstype").Property.GridAutoColumns<string | number> | undefined;
|
package/dist/ui/index.d.ts
CHANGED
|
@@ -12,9 +12,9 @@ export * from './DataTable';
|
|
|
12
12
|
export * from './DateInput';
|
|
13
13
|
export * from './Divider';
|
|
14
14
|
export * from './DocumentViewer';
|
|
15
|
-
export * from './DragAndDropFile';
|
|
16
15
|
export * from './DurationInput';
|
|
17
16
|
export * from './EmptyState';
|
|
17
|
+
export * from './FileDropZone';
|
|
18
18
|
export * from './FilterDate';
|
|
19
19
|
export * from './FormControl';
|
|
20
20
|
export * from './Header';
|
package/dist/ui/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ui/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,WAAW,CAAC;AAC1B,cAAc,kBAAkB,CAAC;AACjC,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ui/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,WAAW,CAAC;AAC1B,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,UAAU,CAAC;AACzB,cAAc,wBAAwB,CAAC;AACvC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,WAAW,CAAC;AAC1B,cAAc,QAAQ,CAAC;AACvB,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,OAAO,CAAC;AACtB,cAAc,iBAAiB,CAAC;AAChC,cAAc,kBAAkB,CAAC;AACjC,cAAc,aAAa,CAAC;AAC5B,cAAc,SAAS,CAAC;AACxB,cAAc,oBAAoB,CAAC;AACnC,cAAc,cAAc,CAAC"}
|
package/dist/ui/index.js
CHANGED
|
@@ -12,9 +12,9 @@ export * from './DataTable';
|
|
|
12
12
|
export * from './DateInput';
|
|
13
13
|
export * from './Divider';
|
|
14
14
|
export * from './DocumentViewer';
|
|
15
|
-
export * from './DragAndDropFile';
|
|
16
15
|
export * from './DurationInput';
|
|
17
16
|
export * from './EmptyState';
|
|
17
|
+
export * from './FileDropZone';
|
|
18
18
|
export * from './FilterDate';
|
|
19
19
|
export * from './FormControl';
|
|
20
20
|
export * from './Header';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alveole/components",
|
|
3
|
-
"version": "2.0.0-alpha",
|
|
3
|
+
"version": "2.0.0-alpha.10",
|
|
4
4
|
"description": "Shared UI components.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -28,41 +28,43 @@
|
|
|
28
28
|
"@react-native-community/datetimepicker": "9.1.0",
|
|
29
29
|
"@react-native/jest-preset": "0.86.3",
|
|
30
30
|
"@shopify/flash-list": "2.0.2",
|
|
31
|
-
"@tamagui/core": "
|
|
32
|
-
"@tamagui/toast": "
|
|
31
|
+
"@tamagui/core": "3.0.18",
|
|
32
|
+
"@tamagui/toast": "3.0.18",
|
|
33
33
|
"@testing-library/react": "16.3.3",
|
|
34
|
-
"@testing-library/react-native": "14.0
|
|
34
|
+
"@testing-library/react-native": "14.1.0",
|
|
35
35
|
"@types/react-syntax-highlighter": "15.5.13",
|
|
36
|
-
"babel-preset-expo": "57.0.
|
|
37
|
-
"eslint": "10.
|
|
38
|
-
"expo": "57.0.
|
|
36
|
+
"babel-preset-expo": "57.0.16",
|
|
37
|
+
"eslint": "10.13.0",
|
|
38
|
+
"expo": "57.0.30",
|
|
39
39
|
"expo-application": "57.0.3",
|
|
40
|
-
"expo-asset": "57.0.
|
|
40
|
+
"expo-asset": "57.0.20",
|
|
41
41
|
"expo-document-picker": "57.0.3",
|
|
42
|
+
"expo-image-picker": "57.0.20",
|
|
42
43
|
"expo-in-app-updates": "0.12.0",
|
|
43
|
-
"expo-
|
|
44
|
-
"expo-
|
|
44
|
+
"expo-linear-gradient": "57.0.2",
|
|
45
|
+
"expo-modules-core": "57.0.23",
|
|
46
|
+
"expo-router": "57.0.28",
|
|
45
47
|
"expo-system-ui": "57.0.4",
|
|
46
48
|
"expo-web-browser": "57.0.3",
|
|
47
49
|
"jest": "29.7.0",
|
|
48
50
|
"jest-environment-jsdom": "30.5.2",
|
|
49
51
|
"jest-expo": "57.0.5",
|
|
50
|
-
"pdfjs-dist": "6.
|
|
52
|
+
"pdfjs-dist": "6.4.299",
|
|
51
53
|
"react": "19.2.3",
|
|
52
54
|
"react-dom": "19.2.3",
|
|
53
55
|
"react-native": "0.86.3",
|
|
54
56
|
"react-native-keyboard-controller": "1.21.9",
|
|
55
57
|
"react-native-otp-entry": "1.8.6",
|
|
56
|
-
"react-native-web": "0.21.
|
|
58
|
+
"react-native-web": "0.21.4",
|
|
57
59
|
"react-select": "5.10.2",
|
|
58
|
-
"react-syntax-highlighter": "16.1.
|
|
59
|
-
"tamagui": "
|
|
60
|
-
"test-renderer": "1.
|
|
60
|
+
"react-syntax-highlighter": "16.1.2",
|
|
61
|
+
"tamagui": "3.0.18",
|
|
62
|
+
"test-renderer": "1.3.1"
|
|
61
63
|
},
|
|
62
64
|
"dependencies": {
|
|
63
65
|
"react-markdown": "10.1.0",
|
|
64
66
|
"remark-gfm": "4.0.1",
|
|
65
|
-
"zod": "4.6.
|
|
67
|
+
"zod": "4.6.7"
|
|
66
68
|
},
|
|
67
69
|
"peerDependencies": {
|
|
68
70
|
"@alveole/core": "*",
|
|
@@ -70,19 +72,19 @@
|
|
|
70
72
|
"@lottiefiles/dotlottie-react": "*",
|
|
71
73
|
"@react-native-community/datetimepicker": "*",
|
|
72
74
|
"@shopify/flash-list": ">=2",
|
|
73
|
-
"@tamagui/accordion": "^
|
|
74
|
-
"@tamagui/animations-css": "^
|
|
75
|
-
"@tamagui/avatar": "^
|
|
76
|
-
"@tamagui/config": "^
|
|
77
|
-
"@tamagui/core": "^
|
|
78
|
-
"@tamagui/dialog": "^
|
|
79
|
-
"@tamagui/popover": "^
|
|
80
|
-
"@tamagui/radio-group": "^
|
|
81
|
-
"@tamagui/sheet": "^
|
|
82
|
-
"@tamagui/slider": "^
|
|
83
|
-
"@tamagui/switch": "^
|
|
84
|
-
"@tamagui/tabs": "^
|
|
85
|
-
"@tamagui/toast": "^
|
|
75
|
+
"@tamagui/accordion": "^3.0.0",
|
|
76
|
+
"@tamagui/animations-css": "^3.0.0",
|
|
77
|
+
"@tamagui/avatar": "^3.0.0",
|
|
78
|
+
"@tamagui/config": "^3.0.0",
|
|
79
|
+
"@tamagui/core": "^3.0.0",
|
|
80
|
+
"@tamagui/dialog": "^3.0.0",
|
|
81
|
+
"@tamagui/popover": "^3.0.0",
|
|
82
|
+
"@tamagui/radio-group": "^3.0.0",
|
|
83
|
+
"@tamagui/sheet": "^3.0.0",
|
|
84
|
+
"@tamagui/slider": "^3.0.0",
|
|
85
|
+
"@tamagui/switch": "^3.0.0",
|
|
86
|
+
"@tamagui/tabs": "^3.0.0",
|
|
87
|
+
"@tamagui/toast": "^3.0.0",
|
|
86
88
|
"@uiw/react-signature": "*",
|
|
87
89
|
"date-fns": "*",
|
|
88
90
|
"expo-application": "*",
|
|
@@ -90,7 +92,9 @@
|
|
|
90
92
|
"expo-constants": "*",
|
|
91
93
|
"expo-document-picker": "*",
|
|
92
94
|
"expo-image": "*",
|
|
95
|
+
"expo-image-picker": "*",
|
|
93
96
|
"expo-in-app-updates": "*",
|
|
97
|
+
"expo-linear-gradient": "*",
|
|
94
98
|
"expo-router": "*",
|
|
95
99
|
"expo-web-browser": "*",
|
|
96
100
|
"lottie-react-native": "*",
|
|
@@ -105,7 +109,7 @@
|
|
|
105
109
|
"react-native-webview": ">=13",
|
|
106
110
|
"react-select": ">=5",
|
|
107
111
|
"react-syntax-highlighter": "*",
|
|
108
|
-
"tamagui": "^
|
|
112
|
+
"tamagui": "^3.0.0"
|
|
109
113
|
},
|
|
110
114
|
"publishConfig": {
|
|
111
115
|
"access": "public"
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { CSSProperties } from 'react';
|
|
2
|
-
/**
|
|
3
|
-
* Le seul passage d'un style de survol CSS vers le type qu'attend Tamagui. `Box` et
|
|
4
|
-
* `Typography` publient `hoverStyle` en `CSSProperties`, plus large que le type de Tamagui
|
|
5
|
-
* (`flex` y accepte une chaine, Tamagui un nombre) : l'assertion ment donc au compilateur.
|
|
6
|
-
* Resserrer la prop publique casserait les apps qui lui passent des `CSSProperties` ; ce
|
|
7
|
-
* mensonge reste ici, seul et nomme, jusqu'a la prochaine version majeure.
|
|
8
|
-
*/
|
|
9
|
-
export declare const versStyleTamagui: <Cible>(css: CSSProperties | undefined) => Cible | undefined;
|
|
10
|
-
//# sourceMappingURL=versStyleTamagui.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"versStyleTamagui.d.ts","sourceRoot":"","sources":["../../../src/core/styleTamagui/versStyleTamagui.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAEtC;;;;;;GAMG;AACH,eAAO,MAAM,gBAAgB,GAAI,KAAK,EAAE,KAAK,aAAa,GAAG,SAAS,KAAY,KAAK,GAAG,SAAS,CAAC"}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Le seul passage d'un style de survol CSS vers le type qu'attend Tamagui. `Box` et
|
|
3
|
-
* `Typography` publient `hoverStyle` en `CSSProperties`, plus large que le type de Tamagui
|
|
4
|
-
* (`flex` y accepte une chaine, Tamagui un nombre) : l'assertion ment donc au compilateur.
|
|
5
|
-
* Resserrer la prop publique casserait les apps qui lui passent des `CSSProperties` ; ce
|
|
6
|
-
* mensonge reste ici, seul et nomme, jusqu'a la prochaine version majeure.
|
|
7
|
-
*/
|
|
8
|
-
export const versStyleTamagui = (css) => css;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { FileInputProps, FileInputValue, FormControlCaptionProps, FormControlHintProps } from '../FormControl';
|
|
3
|
-
import { Leading } from '../Leading';
|
|
4
|
-
export type DragAndDropFileValue = FileInputValue;
|
|
5
|
-
export type DragAndDropFileProps = FormControlHintProps & FormControlCaptionProps & FileInputProps & {
|
|
6
|
-
label: string;
|
|
7
|
-
leading?: Leading;
|
|
8
|
-
};
|
|
9
|
-
export declare const DragAndDropFile: (props: DragAndDropFileProps) => React.JSX.Element;
|
|
10
|
-
//# sourceMappingURL=DragAndDropFile.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"DragAndDropFile.d.ts","sourceRoot":"","sources":["../../../src/ui/DragAndDropFile/DragAndDropFile.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAEL,cAAc,EACd,cAAc,EAEd,uBAAuB,EAEvB,oBAAoB,EAErB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAAE,OAAO,EAAe,MAAM,YAAY,CAAC;AAGlD,MAAM,MAAM,oBAAoB,GAAG,cAAc,CAAC;AAClD,MAAM,MAAM,oBAAoB,GAAG,oBAAoB,GACrD,uBAAuB,GACvB,cAAc,GAAG;IACf,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB,CAAC;AAEJ,eAAO,MAAM,eAAe,GAAI,OAAO,oBAAoB,sBAuD1D,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import { Box } from '../../core/Box';
|
|
4
|
-
import { Image } from '../../core/Image';
|
|
5
|
-
import { FileInput, FormControlCaption, FormControlHint, FormControlLabel, } from '../FormControl';
|
|
6
|
-
import { LeadingSlot } from '../Leading';
|
|
7
|
-
import { useStyles } from './DragAndDropFile.styles';
|
|
8
|
-
export const DragAndDropFile = (props) => {
|
|
9
|
-
const { label, hint, leading, type, error, success, multiple } = props;
|
|
10
|
-
const styles = useStyles();
|
|
11
|
-
const [forceOpen, setForceOpen] = React.useState(false);
|
|
12
|
-
return (_jsxs(Box, { tag: "drag-and-drop-file", style: styles.container, display: "flex", flexDirection: "row", justify: "space-between", onPress: () => setForceOpen(true), children: [_jsxs(Box, { children: [_jsxs(Box, { tag: "drag-and-drop-file-icon", display: "flex", flexDirection: "row", justify: "center", gap: '050', children: [_jsx(LeadingSlot, { contenu: leading === undefined ? 'Upload' : leading, apparence: { size: 'md' } }), _jsx(Box, { mt: 'auto', mb: 'auto', children: _jsx(FormControlLabel, { label: label }) })] }), _jsx(Box, { tag: "drag-and-drop-file-hint", display: "flex", flexDirection: "row", justify: "center", children: hint && _jsx(FormControlHint, { hint: hint }) }), _jsx(Box, { tag: "drag-and-drop-file-input", children: _jsx(FileInput, { ...props, hideButton: true, hideFilename: true, canChange: false, reopen: forceOpen, onPickStart: () => setForceOpen(false), type: type, multiple: multiple }) }), (error || success) && (_jsx(Box, { tag: "drag-and-drop-file-error", mt: '075', display: "flex", flexDirection: "row", justify: "center", children: _jsx(Box, { p: 16, children: _jsx(FormControlCaption, { ...props }) }) }))] }), _jsx(Box, { children: props.previewURL && _jsx(Image, { source: { uri: props.previewURL }, height: 40, width: 30, contentFit: "cover" }) })] }));
|
|
13
|
-
};
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
declare const _default: {
|
|
2
|
-
title: string;
|
|
3
|
-
tags: "ui"[];
|
|
4
|
-
experimental: false;
|
|
5
|
-
webOnly: true;
|
|
6
|
-
description: string;
|
|
7
|
-
component: (props: import("./DragAndDropFile").DragAndDropFileProps) => import("react").JSX.Element;
|
|
8
|
-
styleFn: () => {
|
|
9
|
-
container: {
|
|
10
|
-
borderWidth: number;
|
|
11
|
-
borderStyle: "dashed";
|
|
12
|
-
borderColor: string;
|
|
13
|
-
padding: string | number;
|
|
14
|
-
borderRadius: import("@alveole/theme").Radius;
|
|
15
|
-
backgroundColor: string;
|
|
16
|
-
cursor: "pointer";
|
|
17
|
-
};
|
|
18
|
-
containerHover: {
|
|
19
|
-
borderStyle: "solid";
|
|
20
|
-
borderColor: string;
|
|
21
|
-
backgroundColor: string;
|
|
22
|
-
};
|
|
23
|
-
containerMouseHover: {
|
|
24
|
-
borderStyle: "dashed";
|
|
25
|
-
borderColor: string;
|
|
26
|
-
backgroundColor: string;
|
|
27
|
-
};
|
|
28
|
-
containerError: {
|
|
29
|
-
borderStyle: "dashed";
|
|
30
|
-
borderColor: string;
|
|
31
|
-
backgroundColor: string;
|
|
32
|
-
};
|
|
33
|
-
webError: {
|
|
34
|
-
width: "100%";
|
|
35
|
-
alignItems: "center";
|
|
36
|
-
};
|
|
37
|
-
icon: {
|
|
38
|
-
color: string;
|
|
39
|
-
backgroundColor: string;
|
|
40
|
-
padding: string | number;
|
|
41
|
-
borderRadius: import("@alveole/theme").Radius;
|
|
42
|
-
width: import("@alveole/theme").Spacing;
|
|
43
|
-
height: import("@alveole/theme").Spacing;
|
|
44
|
-
marginBottom: string | number;
|
|
45
|
-
};
|
|
46
|
-
fileName: {
|
|
47
|
-
fontWeight: "bold";
|
|
48
|
-
};
|
|
49
|
-
};
|
|
50
|
-
};
|
|
51
|
-
export default _default;
|
|
52
|
-
export declare const Default: () => import("react").JSX.Element;
|
|
53
|
-
export declare const Multiple: () => import("react").JSX.Element;
|
|
54
|
-
export declare const WithError: () => import("react").JSX.Element;
|
|
55
|
-
export * as Sources from './DragAndDropFile.stories.sources';
|
|
56
|
-
//# sourceMappingURL=DragAndDropFile.stories.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"DragAndDropFile.stories.d.ts","sourceRoot":"","sources":["../../../src/ui/DragAndDropFile/DragAndDropFile.stories.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAKA,wBAQkB;AAElB,eAAO,MAAM,OAAO,mCAKnB,CAAC;AAEF,eAAO,MAAM,QAAQ,mCAEpB,CAAC;AAEF,eAAO,MAAM,SAAS,mCAErB,CAAC;AAEF,OAAO,KAAK,OAAO,MAAM,mCAAmC,CAAC"}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Box } from '../../core/Box';
|
|
3
|
-
import { DragAndDropFile } from './DragAndDropFile';
|
|
4
|
-
import { useStyles } from './DragAndDropFile.styles';
|
|
5
|
-
export default {
|
|
6
|
-
title: 'DragAndDropFile',
|
|
7
|
-
tags: ['ui'],
|
|
8
|
-
experimental: false,
|
|
9
|
-
webOnly: true,
|
|
10
|
-
description: 'Zone de dépôt de fichiers par glisser-déposer ou clic.',
|
|
11
|
-
component: DragAndDropFile,
|
|
12
|
-
styleFn: useStyles,
|
|
13
|
-
};
|
|
14
|
-
export const Default = () => (_jsxs(Box, { display: "flex", flexDirection: "column", gap: 24, children: [_jsx(DragAndDropFile, { label: "Document", value: null, onChange: () => { } }), _jsx(DragAndDropFile, { label: "Image uniquement", type: "image/*", value: null, onChange: () => { } })] }));
|
|
15
|
-
export const Multiple = () => (_jsx(DragAndDropFile, { label: "Documents (plusieurs)", multiple: true, value: null, onChange: () => { } }));
|
|
16
|
-
export const WithError = () => (_jsx(DragAndDropFile, { label: "Document", error: "Format non support\u00E9", value: null, onChange: () => { } }));
|
|
17
|
-
export * as Sources from './DragAndDropFile.stories.sources';
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
export declare const Default: () => string;
|
|
2
|
-
export declare const Multiple: () => string;
|
|
3
|
-
export declare const WithError: () => string;
|
|
4
|
-
export declare const storySources: {
|
|
5
|
-
readonly Default: () => string;
|
|
6
|
-
readonly Multiple: () => string;
|
|
7
|
-
readonly WithError: () => string;
|
|
8
|
-
};
|
|
9
|
-
export type StorySourceName = keyof typeof storySources;
|
|
10
|
-
//# sourceMappingURL=DragAndDropFile.stories.sources.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"DragAndDropFile.stories.sources.d.ts","sourceRoot":"","sources":["../../../src/ui/DragAndDropFile/DragAndDropFile.stories.sources.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,OAAO,cAAsS,CAAC;AAE3T,eAAO,MAAM,QAAQ,cAA+I,CAAC;AAErK,eAAO,MAAM,SAAS,cAAwJ,CAAC;AAE/K,eAAO,MAAM,YAAY;;;;CAIf,CAAC;AAEX,MAAM,MAAM,eAAe,GAAG,MAAM,OAAO,YAAY,CAAC"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
// This file is generated. Do not edit manually.
|
|
2
|
-
// Source: src/ui/DragAndDropFile/DragAndDropFile.stories.tsx
|
|
3
|
-
export const Default = () => "export const Default = () => (\n <Box display=\"flex\" flexDirection=\"column\" gap={24}>\n <DragAndDropFile label=\"Document\" value={null} onChange={() => {}} />\n <DragAndDropFile label=\"Image uniquement\" type=\"image/*\" value={null} onChange={() => {}} />\n </Box>\n);";
|
|
4
|
-
export const Multiple = () => "export const Multiple = () => (\n <DragAndDropFile label=\"Documents (plusieurs)\" multiple value={null} onChange={() => {}} />\n);";
|
|
5
|
-
export const WithError = () => "export const WithError = () => (\n <DragAndDropFile label=\"Document\" error=\"Format non supporté\" value={null} onChange={() => {}} />\n);";
|
|
6
|
-
export const storySources = {
|
|
7
|
-
Default,
|
|
8
|
-
Multiple,
|
|
9
|
-
WithError,
|
|
10
|
-
};
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
export declare const useStyles: () => {
|
|
2
|
-
container: {
|
|
3
|
-
borderWidth: number;
|
|
4
|
-
borderStyle: "dashed";
|
|
5
|
-
borderColor: string;
|
|
6
|
-
padding: string | number;
|
|
7
|
-
borderRadius: import("@alveole/theme").Radius;
|
|
8
|
-
backgroundColor: string;
|
|
9
|
-
cursor: "pointer";
|
|
10
|
-
};
|
|
11
|
-
containerHover: {
|
|
12
|
-
borderStyle: "solid";
|
|
13
|
-
borderColor: string;
|
|
14
|
-
backgroundColor: string;
|
|
15
|
-
};
|
|
16
|
-
containerMouseHover: {
|
|
17
|
-
borderStyle: "dashed";
|
|
18
|
-
borderColor: string;
|
|
19
|
-
backgroundColor: string;
|
|
20
|
-
};
|
|
21
|
-
containerError: {
|
|
22
|
-
borderStyle: "dashed";
|
|
23
|
-
borderColor: string;
|
|
24
|
-
backgroundColor: string;
|
|
25
|
-
};
|
|
26
|
-
webError: {
|
|
27
|
-
width: "100%";
|
|
28
|
-
alignItems: "center";
|
|
29
|
-
};
|
|
30
|
-
icon: {
|
|
31
|
-
color: string;
|
|
32
|
-
backgroundColor: string;
|
|
33
|
-
padding: string | number;
|
|
34
|
-
borderRadius: import("@alveole/theme").Radius;
|
|
35
|
-
width: import("@alveole/theme").Spacing;
|
|
36
|
-
height: import("@alveole/theme").Spacing;
|
|
37
|
-
marginBottom: string | number;
|
|
38
|
-
};
|
|
39
|
-
fileName: {
|
|
40
|
-
fontWeight: "bold";
|
|
41
|
-
};
|
|
42
|
-
};
|
|
43
|
-
//# sourceMappingURL=DragAndDropFile.styles.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"DragAndDropFile.styles.d.ts","sourceRoot":"","sources":["../../../src/ui/DragAndDropFile/DragAndDropFile.styles.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyCnB,CAAC"}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { makeStyles } from '@alveole/theme';
|
|
2
|
-
export const useStyles = makeStyles(({ color, spacing, spacingValue, radius }) => ({
|
|
3
|
-
container: {
|
|
4
|
-
borderWidth: 1,
|
|
5
|
-
borderStyle: 'dashed',
|
|
6
|
-
borderColor: color.border['contrast-grey'],
|
|
7
|
-
padding: spacing('4W'),
|
|
8
|
-
borderRadius: radius('lg'),
|
|
9
|
-
backgroundColor: color.alpha(color.background['alt-grey'], 0.3),
|
|
10
|
-
cursor: 'pointer',
|
|
11
|
-
},
|
|
12
|
-
containerHover: {
|
|
13
|
-
borderStyle: 'solid',
|
|
14
|
-
borderColor: color.border['disabled-grey'],
|
|
15
|
-
backgroundColor: color.alpha(color.background['alt-grey'], 0.25),
|
|
16
|
-
},
|
|
17
|
-
containerMouseHover: {
|
|
18
|
-
borderStyle: 'dashed',
|
|
19
|
-
borderColor: color.border['contrast-grey'],
|
|
20
|
-
backgroundColor: color.alpha(color.background['alt-grey'], 0.75),
|
|
21
|
-
},
|
|
22
|
-
containerError: {
|
|
23
|
-
borderStyle: 'dashed',
|
|
24
|
-
borderColor: color.alpha(color.border['plain-error'], 0.5),
|
|
25
|
-
backgroundColor: color.alpha(color.background['alt-grey'], 0.25),
|
|
26
|
-
},
|
|
27
|
-
webError: {
|
|
28
|
-
width: '100%',
|
|
29
|
-
alignItems: 'center',
|
|
30
|
-
},
|
|
31
|
-
icon: {
|
|
32
|
-
color: color.text.mention,
|
|
33
|
-
backgroundColor: color.background['alt-grey'],
|
|
34
|
-
padding: spacing('2W'),
|
|
35
|
-
borderRadius: radius('lg'),
|
|
36
|
-
width: spacingValue('200'),
|
|
37
|
-
height: spacingValue('200'),
|
|
38
|
-
marginBottom: spacing('2W'),
|
|
39
|
-
},
|
|
40
|
-
fileName: {
|
|
41
|
-
fontWeight: 'bold',
|
|
42
|
-
},
|
|
43
|
-
}));
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"DragAndDropFile.web.d.ts","sourceRoot":"","sources":["../../../src/ui/DragAndDropFile/DragAndDropFile.web.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AAIzD,eAAO,MAAM,eAAe,GAAI,OAAO,oBAAoB,gCA6D1D,CAAC"}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Box } from '../../core/Box';
|
|
3
|
-
import { FileInput, FormControlCaption, FormControlHint, FormControlLabel } from '../FormControl';
|
|
4
|
-
import { LeadingSlot } from '../Leading';
|
|
5
|
-
import { useStyles } from './DragAndDropFile.styles';
|
|
6
|
-
import { useDepotFichier } from './useDepotFichier';
|
|
7
|
-
export const DragAndDropFile = (props) => {
|
|
8
|
-
const { label, hint, leading, type, error, success, multiple } = props;
|
|
9
|
-
const styles = useStyles();
|
|
10
|
-
const depot = useDepotFichier(props);
|
|
11
|
-
const styleContainer = {
|
|
12
|
-
...styles.container,
|
|
13
|
-
...(depot.isMouseOver ? styles.containerMouseHover : {}),
|
|
14
|
-
...(depot.isOver ? styles.containerHover : {}),
|
|
15
|
-
...(error ? styles.containerError : {}),
|
|
16
|
-
};
|
|
17
|
-
return (_jsxs("div", { tabIndex: 0, onDrop: depot.onDrop, onDragOver: depot.onDragOver, onDragEnter: depot.onDragOver, onDragLeave: depot.onDragLeave, onMouseOver: depot.onMouseOver, onMouseEnter: depot.onMouseOver, onMouseLeave: depot.onMouseLeave, onClick: depot.ouvrir, style: styleContainer, children: [_jsx(Box, { tag: "drag-and-drop-file-icon", display: "flex", flexDirection: "row", justify: "center", children: _jsx(LeadingSlot, { contenu: leading === undefined ? 'Upload' : leading, apparence: { size: 'xl', style: styles.icon } }) }), _jsx(Box, { tag: "drag-and-drop-file-label", display: "flex", flexDirection: "row", justify: "center", children: _jsx(FormControlLabel, { label: label }) }), _jsx(Box, { tag: "drag-and-drop-file-hint", display: "flex", flexDirection: "row", justify: "center", children: hint && _jsx(FormControlHint, { hint: hint }) }), _jsx(Box, { tag: "drag-and-drop-file-input", display: "flex", flexDirection: "row", justify: "center", children: _jsx(Box, { pt: 16, children: _jsx(FileInput, { ...props, canChange: false, reopen: depot.forceOpen, onPickStart: depot.fermer, multiple: multiple, type: type }) }) }), (error || success) && (_jsx(Box, { tag: "drag-and-drop-file-error", style: styles.webError, children: _jsx(FormControlCaption, { ...props }) }))] }));
|
|
18
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"fichiersDuDataTransfer.d.ts","sourceRoot":"","sources":["../../../src/ui/DragAndDropFile/fichiersDuDataTransfer.ts"],"names":[],"mappings":"AAAA,KAAK,UAAU,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,SAAS,IAAI,IAAI,GAAG,IAAI,CAAA;CAAE,CAAC;AAE7D;;;;;GAKG;AACH,KAAK,eAAe,GAAG;IAAE,KAAK,CAAC,EAAE,SAAS,CAAC,UAAU,CAAC,CAAC;IAAC,KAAK,CAAC,EAAE,SAAS,CAAC,IAAI,CAAC,CAAA;CAAE,GAAG,IAAI,GAAG,SAAS,CAAC;AAQrG;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,GAAI,IAAI,eAAe,KAAG,IAAI,EAIhE,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/ui/DragAndDropFile/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './DragAndDropFile';
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { FileInputProps } from '../FormControl';
|
|
3
|
-
/**
|
|
4
|
-
* Tout ce que la zone de depot fait en plus du champ de fichier ordinaire : suivre le survol et
|
|
5
|
-
* le survol de glissement, convertir les fichiers laches en valeurs du champ, et liberer les URL
|
|
6
|
-
* d'objet. Ecrit dans le composant, ce comportement en occupait les cinq sixiemes et noyait le
|
|
7
|
-
* peu de rendu qu'il contient.
|
|
8
|
-
*/
|
|
9
|
-
export declare const useDepotFichier: ({ value, type, multiple, onChange, }: Pick<FileInputProps, "value" | "type" | "multiple" | "onChange">) => {
|
|
10
|
-
isOver: boolean;
|
|
11
|
-
isMouseOver: boolean;
|
|
12
|
-
forceOpen: boolean;
|
|
13
|
-
ouvrir: () => void;
|
|
14
|
-
fermer: () => void;
|
|
15
|
-
onDrop: (e: React.DragEvent<HTMLDivElement>) => void;
|
|
16
|
-
onDragOver: (e: React.DragEvent<HTMLDivElement>) => void;
|
|
17
|
-
onDragLeave: (e: React.DragEvent<HTMLDivElement>) => void;
|
|
18
|
-
onMouseOver: (e: React.DragEvent<HTMLDivElement>) => void;
|
|
19
|
-
onMouseLeave: (e: React.DragEvent<HTMLDivElement>) => void;
|
|
20
|
-
};
|
|
21
|
-
//# sourceMappingURL=useDepotFichier.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"useDepotFichier.d.ts","sourceRoot":"","sources":["../../../src/ui/DragAndDropFile/useDepotFichier.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAA2B,cAAc,EAAgC,MAAM,gBAAgB,CAAC;AA0BvG;;;;;GAKG;AACH,eAAO,MAAM,eAAe,GAAI,sCAK7B,IAAI,CAAC,cAAc,EAAE,OAAO,GAAG,MAAM,GAAG,UAAU,GAAG,UAAU,CAAC;;;;;;gBAuB9C,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC;oBAS0B,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC;qBAA/B,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC;qBAA/B,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC;sBAA/B,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC;CAmB5G,CAAC"}
|
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { Alert } from '../../core/Alert';
|
|
3
|
-
import { fichierCorrespondAuType, valideLeType } from '../FormControl';
|
|
4
|
-
import { fichiersDuDataTransfer } from './fichiersDuDataTransfer';
|
|
5
|
-
const enAsset = (file) => ({
|
|
6
|
-
uri: URL.createObjectURL(file),
|
|
7
|
-
name: file.name,
|
|
8
|
-
size: file.size,
|
|
9
|
-
mimeType: file.type || 'application/octet-stream',
|
|
10
|
-
lastModified: file.lastModified,
|
|
11
|
-
file,
|
|
12
|
-
});
|
|
13
|
-
// Chaque fichier depose est publie derriere une URL d'objet, que le navigateur garde en memoire
|
|
14
|
-
// tant qu'on ne la revoque pas. Sans ce nettoyage au changement de valeur, un formulaire ou
|
|
15
|
-
// l'utilisateur hesite accumule les fichiers relaches dans l'onglet.
|
|
16
|
-
const revoquer = (value) => {
|
|
17
|
-
const uris = (Array.isArray(value) ? value : [value]).map(fichier => fichier?.uri);
|
|
18
|
-
uris.forEach(uri => {
|
|
19
|
-
if (!uri?.startsWith('blob:'))
|
|
20
|
-
return;
|
|
21
|
-
try {
|
|
22
|
-
URL.revokeObjectURL(uri);
|
|
23
|
-
}
|
|
24
|
-
catch { }
|
|
25
|
-
});
|
|
26
|
-
};
|
|
27
|
-
/**
|
|
28
|
-
* Tout ce que la zone de depot fait en plus du champ de fichier ordinaire : suivre le survol et
|
|
29
|
-
* le survol de glissement, convertir les fichiers laches en valeurs du champ, et liberer les URL
|
|
30
|
-
* d'objet. Ecrit dans le composant, ce comportement en occupait les cinq sixiemes et noyait le
|
|
31
|
-
* peu de rendu qu'il contient.
|
|
32
|
-
*/
|
|
33
|
-
export const useDepotFichier = ({ value, type, multiple, onChange, }) => {
|
|
34
|
-
const [isOver, setIsOver] = React.useState(false);
|
|
35
|
-
const [isMouseOver, setIsMouseOver] = React.useState(false);
|
|
36
|
-
const [forceOpen, setForceOpen] = React.useState(false);
|
|
37
|
-
const onValueChange = valideLeType({ type, onChange });
|
|
38
|
-
// `deposer` et `onDrop` etaient memoises en omettant `onValueChange` de leurs dependances,
|
|
39
|
-
// pour ne pas recreer les gestionnaires de glisser-deposer a chaque frappe du formulaire. Le
|
|
40
|
-
// gain etait nul : `survol` reconstruit deja les quatre autres gestionnaires a chaque rendu.
|
|
41
|
-
// Le cout, lui, etait reel : la memoisation figeait le gestionnaire du premier rendu, et un
|
|
42
|
-
// formulaire controle deposait dans un `onChange` perime.
|
|
43
|
-
const deposer = (files) => {
|
|
44
|
-
const valides = files.filter(file => fichierCorrespondAuType(file.type || '', file.name, type));
|
|
45
|
-
if (valides.length < files.length) {
|
|
46
|
-
Alert.alert({ title: 'Type de fichier incorrect', message: 'Certains fichiers ne sont pas pris en charge' });
|
|
47
|
-
}
|
|
48
|
-
if (valides.length === 0)
|
|
49
|
-
return;
|
|
50
|
-
onValueChange(multiple ? valides.map(enAsset) : enAsset(valides[0]));
|
|
51
|
-
};
|
|
52
|
-
const onDrop = (e) => {
|
|
53
|
-
e.preventDefault();
|
|
54
|
-
e.stopPropagation();
|
|
55
|
-
setIsOver(false);
|
|
56
|
-
const files = fichiersDuDataTransfer(e.dataTransfer);
|
|
57
|
-
if (files.length > 0)
|
|
58
|
-
deposer(multiple ? files : [files[0]]);
|
|
59
|
-
};
|
|
60
|
-
const survol = (actif, appliquer) => (e) => {
|
|
61
|
-
e.preventDefault();
|
|
62
|
-
appliquer(actif);
|
|
63
|
-
};
|
|
64
|
-
React.useEffect(() => () => revoquer(value), [value]);
|
|
65
|
-
return {
|
|
66
|
-
isOver,
|
|
67
|
-
isMouseOver,
|
|
68
|
-
forceOpen,
|
|
69
|
-
ouvrir: () => setForceOpen(true),
|
|
70
|
-
fermer: () => setForceOpen(false),
|
|
71
|
-
onDrop,
|
|
72
|
-
onDragOver: survol(true, setIsOver),
|
|
73
|
-
onDragLeave: survol(false, setIsOver),
|
|
74
|
-
onMouseOver: survol(true, setIsMouseOver),
|
|
75
|
-
onMouseLeave: survol(false, setIsMouseOver),
|
|
76
|
-
};
|
|
77
|
-
};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { type ToastAPIOptions } from './ToastContext';
|
|
3
|
-
export type ToastBridgeProps = React.PropsWithChildren<object>;
|
|
4
|
-
export declare const defaultDuration = 8000;
|
|
5
|
-
export declare function ToastBridge(props: ToastBridgeProps): React.JSX.Element;
|
|
6
|
-
declare module '@tamagui/toast' {
|
|
7
|
-
interface CustomData extends ToastAPIOptions {
|
|
8
|
-
presentAt?: number;
|
|
9
|
-
}
|
|
10
|
-
}
|
|
11
|
-
//# sourceMappingURL=ToastBridge.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ToastBridge.d.ts","sourceRoot":"","sources":["../../../src/ui/Toast/ToastBridge.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAA+B,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAEnF,MAAM,MAAM,gBAAgB,GAAG,KAAK,CAAC,iBAAiB,CAAC,MAAM,CAAC,CAAC;AAE/D,eAAO,MAAM,eAAe,OAAO,CAAC;AAEpC,wBAAgB,WAAW,CAAC,KAAK,EAAE,gBAAgB,qBAkBlD;AAED,OAAO,QAAQ,gBAAgB,CAAC;IAC9B,UAAU,UAAW,SAAQ,eAAe;QAC1C,SAAS,CAAC,EAAE,MAAM,CAAC;KACpB;CACF"}
|