Skip to content

Commit ab24d03

Browse files
committed
Adjust padding for unlabeled settings buttons and add text truncation to navigation items
1 parent 198682b commit ab24d03

3 files changed

Lines changed: 11 additions & 2 deletions

File tree

‎packages/ui/src/components/editor/panel/SettingsButton/SettingsButton.module.scss‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,10 @@
3232
width: auto;
3333
height: auto;
3434
gap: 2px;
35-
padding: 0 4px;
35+
36+
&:not(.button--labeled) {
37+
padding-left: 3px;
38+
}
3639
}
3740
}
3841

‎packages/ui/src/components/editor/settings/NavigationItem/NavigationItem.module.scss‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,12 @@
2424
}
2525
}
2626

27+
.label {
28+
overflow: hidden;
29+
text-overflow: ellipsis;
30+
white-space: nowrap;
31+
}
32+
2733
.warning {
2834
display: flex;
2935
color: var(--cwc-text-color-orange);

‎packages/ui/src/components/editor/settings/NavigationItem/NavigationItem.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export const NavigationItem: React.FC<Props> = (props) => {
1818
})}
1919
onClick={props.on_click}
2020
>
21-
<span>{props.label}</span>
21+
<span className={styles.label}>{props.label}</span>
2222
{props.has_warning && (
2323
<div className={styles.warning}>
2424
<span className="codicon codicon-warning" />

0 commit comments

Comments
 (0)