Skip to content

Commit b52ae76

Browse files
authored
fix: Empty description space for color-inputs in the combobox (#4591)
## Description closes #4585 Do not show description panel if zero descriptions are available ## Steps for reproduction 1. click button 2. expect xyz ## Code Review - [ ] hi @kof, I need you to do - conceptual review (architecture, feature-correctness) - detailed review (read every line) - test it on preview ## Before requesting a review - [ ] made a self-review - [ ] added inline comments where things may be not obvious (the "why", not "what") ## Before merging - [ ] tested locally and on preview environment (preview dev login: 0000) - [ ] updated [test cases](https://github.com/webstudio-is/webstudio/blob/main/apps/builder/docs/test-cases.md) document - [ ] added tests - [ ] if any new env variables are added, added them to `.env` file
1 parent 58e6143 commit b52ae76

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

apps/builder/app/builder/features/style-panel/shared/css-value-input/css-value-input.tsx

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -920,10 +920,11 @@ export const CssValueInput = ({
920920
</ComboboxListboxItem>
921921
))}
922922
</ComboboxScrollArea>
923-
924-
<ComboboxItemDescription descriptions={descriptions}>
925-
<Description>{description}</Description>
926-
</ComboboxItemDescription>
923+
{descriptions.length > 0 && (
924+
<ComboboxItemDescription descriptions={descriptions}>
925+
<Description>{description}</Description>
926+
</ComboboxItemDescription>
927+
)}
927928
</ComboboxListbox>
928929
</ComboboxContent>
929930
)}

0 commit comments

Comments
 (0)