From 2752a0aad2dcde97cec4eeb00327a23fda520a38 Mon Sep 17 00:00:00 2001 From: Sam Rose <11774595+sam-b-rose@users.noreply.github.com> Date: Thu, 21 Mar 2024 09:08:35 -0400 Subject: [PATCH] Fix TextOptions and CalloutCard --- .../src/components/CalloutCard/CalloutCard.tsx | 2 +- .../Listbox/components/TextOption/TextOption.tsx | 10 ++-------- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/polaris-react/src/components/CalloutCard/CalloutCard.tsx b/polaris-react/src/components/CalloutCard/CalloutCard.tsx index ad4b4be425b..ccac74b6f20 100644 --- a/polaris-react/src/components/CalloutCard/CalloutCard.tsx +++ b/polaris-react/src/components/CalloutCard/CalloutCard.tsx @@ -82,7 +82,7 @@ export function CalloutCard({
- + {title}
diff --git a/polaris-react/src/components/Listbox/components/TextOption/TextOption.tsx b/polaris-react/src/components/Listbox/components/TextOption/TextOption.tsx index 6526bf50c65..718b66de39b 100644 --- a/polaris-react/src/components/Listbox/components/TextOption/TextOption.tsx +++ b/polaris-react/src/components/Listbox/components/TextOption/TextOption.tsx @@ -36,23 +36,17 @@ export const TextOption = memo(function TextOption({ isAction && styles.isAction, ); - const textContent = ( - - {children} - - ); - const optionMarkup = selected ? ( - {textContent} + {children} ) : ( - textContent + <>{children} ); return (