Skip to content

Commit

Permalink
Fallback to font size slug if name is undefined (#45041)
Browse files Browse the repository at this point in the history
  • Loading branch information
mikachan authored Oct 17, 2022
1 parent f38d632 commit 4c7d3e4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/components/src/font-size-picker/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ const UnforwardedFontSizePicker = (
}

// Calculate the `hint` for toggle group control.
let hint = selectedOption.name;
let hint = selectedOption?.name || selectedOption.slug;
if (
! fontSizesContainComplexValues &&
typeof selectedOption.size === 'string'
Expand Down

0 comments on commit 4c7d3e4

Please sign in to comment.