Procházet zdrojové kódy

Adds color swatches to minimap options

main
Eric Amodio před 1 rokem
rodič
revize
7457baa606
2 změnil soubory, kde provedl 35 přidání a 0 odebrání
  1. +10
    -0
      src/webviews/apps/plus/graph/GraphWrapper.tsx
  2. +25
    -0
      src/webviews/apps/plus/graph/graph.scss

+ 10
- 0
src/webviews/apps/plus/graph/GraphWrapper.tsx Zobrazit soubor

@ -1266,6 +1266,10 @@ export function GraphWrapper({
graphConfig?.minimapMarkerTypes?.includes('localBranches') ?? false
}
>
<span
className="minimap-marker-swatch"
data-marker="localBranches"
></span>
Local Branches
</VSCodeCheckbox>
</MenuItem>
@ -1277,6 +1281,10 @@ export function GraphWrapper({
graphConfig?.minimapMarkerTypes?.includes('remoteBranches') ?? true
}
>
<span
className="minimap-marker-swatch"
data-marker="remoteBranches"
></span>
Remote Branches
</VSCodeCheckbox>
</MenuItem>
@ -1288,6 +1296,7 @@ export function GraphWrapper({
graphConfig?.minimapMarkerTypes?.includes('stashes') ?? false
}
>
<span className="minimap-marker-swatch" data-marker="stashes"></span>
Stashes
</VSCodeCheckbox>
</MenuItem>
@ -1299,6 +1308,7 @@ export function GraphWrapper({
graphConfig?.minimapMarkerTypes?.includes('tags') ?? true
}
>
<span className="minimap-marker-swatch" data-marker="tags"></span>
Tags
</VSCodeCheckbox>
</MenuItem>

+ 25
- 0
src/webviews/apps/plus/graph/graph.scss Zobrazit soubor

@ -1079,3 +1079,28 @@ button:not([disabled]),
white-space: break-spaces;
}
}
.minimap-marker-swatch {
display: inline-block;
width: 1.6rem;
height: 1.6rem;
border-radius: 3px;
margin-right: 0.75rem;
vertical-align: bottom;
&[data-marker='localBranches'] {
background-color: var(--color-graph-minimap-marker-local-branches);
}
&[data-marker='remoteBranches'] {
background-color: var(--color-graph-minimap-marker-remote-branches);
}
&[data-marker='stashes'] {
background-color: var(--color-graph-minimap-marker-stashes);
}
&[data-marker='tags'] {
background-color: var(--color-graph-minimap-marker-tags);
}
}

Načítá se…
Zrušit
Uložit