Skip to content

Commit 5bfcada

Browse files
authored
Update experiment table icons to use --vscode-descriptionForeground and use --vscode-editorLightBulb-foreground for selected stars (#2604)
* update queued icon, unselected bullet and spinner colors * update indicator colors * use description foreground as icon color * add editor light bulb for selected star
1 parent 7e126bd commit 5bfcada

File tree

2 files changed

+27
-28
lines changed

2 files changed

+27
-28
lines changed

webview/src/experiments/components/table/styles.module.scss

Lines changed: 23 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ $bullet-size: calc(var(--design-unit) * 4px);
1919
left: 0;
2020
display: inline-block;
2121
position: absolute;
22-
border: 2px solid $row-action-icon-color;
22+
border: 2px solid $icon-color;
2323
border-top: unset;
2424
border-left: unset;
2525
transition: transform 0.2s, right 0.2s, bottom 0.2s;
@@ -102,7 +102,7 @@ $bullet-size: calc(var(--design-unit) * 4px);
102102
background: $checkbox-background;
103103
border-radius: $bullet-size;
104104
border: calc(var(--border-width) * 1px) solid $checkbox-border;
105-
color: $fg-color;
105+
color: $icon-color;
106106
cursor: pointer;
107107
display: flex;
108108
height: $bullet-size;
@@ -135,7 +135,7 @@ $bullet-size: calc(var(--design-unit) * 4px);
135135
width: 4px;
136136
height: 4px;
137137
vertical-align: middle;
138-
border: 1px solid $fg-color;
138+
border: 1px solid $icon-color;
139139
background-color: $checkbox-background;
140140
}
141141

@@ -163,6 +163,7 @@ $bullet-size: calc(var(--design-unit) * 4px);
163163
}
164164

165165
.queued {
166+
color: $icon-color;
166167
display: flex;
167168
height: 16px;
168169
left: 2px;
@@ -331,7 +332,7 @@ $bullet-size: calc(var(--design-unit) * 4px);
331332

332333
.expandedRowArrow,
333334
.contractedRowArrow {
334-
border-color: $row-action-selected-icon-color;
335+
border-color: $selected-icon-color;
335336
}
336337
}
337338
}
@@ -505,18 +506,6 @@ $bullet-size: calc(var(--design-unit) * 4px);
505506
margin-right: 2px;
506507
}
507508

508-
.starSwitch {
509-
display: inline-flex;
510-
align-items: center;
511-
justify-content: center;
512-
width: 14px;
513-
cursor: pointer;
514-
515-
&[aria-checked='true'] {
516-
opacity: 1;
517-
}
518-
}
519-
520509
.indicatorIcon {
521510
display: inline-flex;
522511
align-items: center;
@@ -559,15 +548,27 @@ $bullet-size: calc(var(--design-unit) * 4px);
559548
}
560549
}
561550

562-
.experimentCell .rowActions .starSwitch svg {
563-
fill: $row-action-icon-color;
551+
.starSwitch {
552+
display: inline-flex;
553+
align-items: center;
554+
justify-content: center;
555+
width: 14px;
556+
cursor: pointer;
557+
558+
svg {
559+
fill: $icon-color;
560+
561+
.rowSelected & {
562+
fill: $selected-icon-color;
563+
}
564+
}
564565

565-
.rowSelected & {
566-
fill: $row-action-selected-icon-color;
566+
&[aria-checked='true'] svg {
567+
fill: $row-action-star-checked;
567568
}
568569
}
569570

570-
.cellHintTooltip {
571+
.starSwitch .cellHintTooltip {
571572
font-size: 0.65rem;
572573
}
573574

@@ -763,10 +764,7 @@ $badge-size: 0.85rem;
763764
height: 1.5rem;
764765
cursor: pointer;
765766
svg {
766-
fill: $watermark-color;
767-
}
768-
&.indicatorWithCount svg {
769-
fill: $fg-color;
767+
fill: $icon-color;
770768
}
771769
}
772770

webview/src/shared/variables.scss

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,12 @@ $accent-color: var(--button-primary-background);
3030
$indicator-badge-background: var(--vscode-activityBarBadge-background);
3131
$indicator-badge-foreground: var(--vscode-activityBarBadge-foreground);
3232

33-
$row-action-icon-color: var(--vscode-icon-foreground);
34-
$row-action-selected-icon-color: var(
33+
$icon-color: var(--vscode-descriptionForeground);
34+
$selected-icon-color: var(
3535
--vscode-list-activeSelectionIconForeground,
36-
var(--vscode-icon-foreground)
36+
var(--vscode-descriptionForeground)
3737
);
38+
$row-action-star-checked: var(--vscode-editorLightBulb-foreground);
3839

3940
$shadow: var(--vscode-widget-shadow);
4041

0 commit comments

Comments
 (0)