Improve selected node highlighting by using minWidth instead of width

This commit is contained in:
Brian Vaughn
2019-02-28 12:56:49 -08:00
parent bffa72c601
commit c7f8557202
2 changed files with 2 additions and 1 deletions
-1
View File
@@ -1,6 +1,5 @@
.Element,
.SelectedElement {
width: 100%;
border-radius: 0.25em;
position: relative;
white-space: nowrap;
+2
View File
@@ -89,6 +89,8 @@ export default function ElementView({ index, style }: Props) {
style={{
...style, // "style" comes from react-window
paddingLeft: `${(depth - baseDepth) * 0.75 + 0.25}rem`,
width: undefined,
minWidth: '100%',
}}
>
<span className={styles.Component} ref={ref}>