mirror of
https://github.com/R0m1k3/noteflow.git
synced 2026-10-11 17:29:37 +02:00
Fix: Mise à jour du composant Calendar pour react-day-picker v9
Le build échouait car le composant Calendar utilisait l'ancienne API de react-day-picker (IconLeft/IconRight) qui n'est plus supportée dans la version 9. Changements: - Remplacement de IconLeft et IconRight par le composant Chevron - Le composant Chevron gère maintenant l'orientation (left/right) - Compatible avec react-day-picker v9.11.1 Cette correction résout l'erreur TypeScript TS2353 et permet au build de se terminer avec succès.
This commit is contained in:
1 file changed
+4
-2
@@ -52,8 +52,10 @@ function Calendar({
|
||||
...classNames,
|
||||
}}
|
||||
components={{
|
||||
IconLeft: ({ ..._props }) => <ChevronLeft className="h-4 w-4" />,
|
||||
IconRight: ({ ..._props }) => <ChevronRight className="h-4 w-4" />,
|
||||
Chevron: ({ orientation, ...props }) => {
|
||||
const Icon = orientation === "left" ? ChevronLeft : ChevronRight;
|
||||
return <Icon className="h-4 w-4" {...props} />;
|
||||
},
|
||||
}}
|
||||
{...props}
|
||||
/>
|
||||
|
||||
Reference in new issue
Block a user