From 3e119813cd31a77d11d09f34dff5b33cc7b26fa7 Mon Sep 17 00:00:00 2001 From: Julien Froidefond Date: Mon, 8 Dec 2025 07:51:30 +0100 Subject: [PATCH] refactor: simplify Check component rendering in CategoryCombobox for improved readability and maintainability --- components/ui/category-combobox.tsx | 27 +++++++++------------------ 1 file changed, 9 insertions(+), 18 deletions(-) diff --git a/components/ui/category-combobox.tsx b/components/ui/category-combobox.tsx index 752c5e8..49479a4 100644 --- a/components/ui/category-combobox.tsx +++ b/components/ui/category-combobox.tsx @@ -206,12 +206,9 @@ export function CategoryCombobox({ handleSelect(null)}> Aucune catégorie - + {value === null && ( + + )} @@ -227,12 +224,9 @@ export function CategoryCombobox({ size={16} /> {parent.name} - + {value === parent.id && ( + + )} {childrenByParent[parent.id]?.map((child) => ( {child.name} - + {value === child.id && ( + + )} ))}