From 8d28227da697a63810ac8a2e62ad495deeef3b12 Mon Sep 17 00:00:00 2001 From: Sam Chau Date: Sun, 12 Jan 2025 01:31:52 +1030 Subject: [PATCH] fix: standardize button sizes and improve selection indicators in ProfileCard and RegexCard components --- .../src/components/profile/ProfileCard.jsx | 68 ++++++++++--------- frontend/src/components/regex/RegexCard.jsx | 65 ++++++++++-------- 2 files changed, 70 insertions(+), 63 deletions(-) diff --git a/frontend/src/components/profile/ProfileCard.jsx b/frontend/src/components/profile/ProfileCard.jsx index 8799777..20cdb04 100644 --- a/frontend/src/components/profile/ProfileCard.jsx +++ b/frontend/src/components/profile/ProfileCard.jsx @@ -94,41 +94,43 @@ const ProfileCard = ({ )} )} - {isSelectionMode ? ( - -
+ {isSelectionMode ? ( + - {isSelected && ( - - )} - {willBeSelected && !isSelected && ( -
- )} -
-
- ) : ( - - )} + ? 'Will be selected' + : 'Select' + }> +
+ {isSelected && ( + + )} + {willBeSelected && !isSelected && ( +
+ )} +
+ + ) : ( + + )} +
diff --git a/frontend/src/components/regex/RegexCard.jsx b/frontend/src/components/regex/RegexCard.jsx index ba529f8..52e332e 100644 --- a/frontend/src/components/regex/RegexCard.jsx +++ b/frontend/src/components/regex/RegexCard.jsx @@ -62,38 +62,43 @@ const RegexCard = ({

{pattern.name}

- {isSelectionMode ? ( - -
+ {isSelectionMode ? ( + - {isSelected && ( - - )} - {willBeSelected && !isSelected && ( -
- )} -
-
- ) : ( - - )} + ? 'Will be selected' + : 'Select' + }> +
+ {isSelected && ( + + )} + {willBeSelected && !isSelected && ( +
+ )} +
+ + ) : ( + + )} +
{/* Pattern Display */}