Skip to content

Commit 759942b

Browse files
maryhippMary Hipp
andauthored
bump description to two lines and bolden name if descriptoin is present (#35)
Co-authored-by: Mary Hipp <[email protected]>
1 parent 487905c commit 759942b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lib/components/combobox/custom-option.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@ export const CustomOptionComponent = typedMemo(({ children, ...props }: CustomOp
3333
{props.data.icon}
3434
</Flex>
3535
<Flex flexDir="column">
36-
<Text>{children}</Text>
36+
<Text fontWeight={props.data.description ? "semibold" : undefined}>{children}</Text>
3737
{props.data.description && (
38-
<Text data-option-desc fontSize="sm" colorScheme="base" variant="subtext" noOfLines={1}>
38+
<Text data-option-desc fontSize="sm" colorScheme="base" variant="subtext" noOfLines={2}>
3939
{props.data.description}
4040
</Text>
4141
)}
@@ -50,9 +50,9 @@ export const CustomOptionComponent = typedMemo(({ children, ...props }: CustomOp
5050
<chakraComponents.Option {...props}>
5151
<Tooltip label={props.data.tooltip}>
5252
<Flex w="full" h="full" flexDir="column" p={1} px={4}>
53-
<Text>{children}</Text>
53+
<Text fontWeight={props.data.description ? "semibold" : undefined}>{children}</Text>
5454
{props.data.description && (
55-
<Text data-option-desc fontSize="sm" colorScheme="base" variant="subtext" noOfLines={1}>
55+
<Text data-option-desc fontSize="sm" colorScheme="base" variant="subtext" noOfLines={2}>
5656
{props.data.description}
5757
</Text>
5858
)}

0 commit comments

Comments
 (0)