Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion src/shared/dropdown-list/dropdown-label.styles.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ interface LabelTextStyleProps {
$disabled?: boolean;
$truncateType?: TruncateType;
$bold?: boolean;
$variant?: DropdownVariantType;
}

interface MatchedTextStyleProps {
Expand Down Expand Up @@ -73,7 +74,9 @@ export const SecondaryText = styled.div<LabelTextStyleProps>`
case "inline":
default:
return css`
${Font["body-baseline-regular"]}
${props.$variant === "small"
? Font["body-md-regular"]
: Font["body-baseline-regular"]}
`;
}
}}
Expand Down
1 change: 1 addition & 0 deletions src/shared/dropdown-list/dropdown-label.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ export const DropdownLabel = ({
$maxLines={maxLines}
$truncateType={truncationType}
$labelDisplayType={displayType}
$variant={variant}
>
{truncationType === "middle" && shouldTruncateLabel
? renderTruncatedText(sublabel)
Expand Down
3 changes: 0 additions & 3 deletions stories/form/form-select/form-select.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,6 @@ export const LabelTruncation: StoryObj<Component> = {
title: item,
secondaryLabel: item,
})}
variant="small"
/>
<Form.Select
label="This has truncation in the middle"
Expand All @@ -282,7 +281,6 @@ export const LabelTruncation: StoryObj<Component> = {
title: item,
secondaryLabel: item,
})}
variant="small"
/>
<Form.Select
label="This has no truncation"
Expand All @@ -292,7 +290,6 @@ export const LabelTruncation: StoryObj<Component> = {
title: item,
secondaryLabel: item,
})}
variant="small"
/>
</>
);
Expand Down
Loading