File tree Expand file tree Collapse file tree 2 files changed +21
-1
lines changed
torchci/components/benchmark Expand file tree Collapse file tree 2 files changed +21
-1
lines changed Original file line number Diff line number Diff line change @@ -179,7 +179,17 @@ export function BranchAndCommitPicker({
179
179
id = { `branch-picker-select-${ commit } ` }
180
180
>
181
181
{ displayBranches . map ( ( b : string ) => (
182
- < MenuItem key = { `${ b } -${ commit } ` } value = { b } >
182
+ < MenuItem
183
+ key = { `${ b } -${ commit } ` }
184
+ value = { b }
185
+ sx = { {
186
+ backgroundColor : b === branch ? "#e3f2fd" : "inherit" ,
187
+ fontWeight : b === branch ? "bold" : "normal" ,
188
+ "&:hover" : {
189
+ backgroundColor : b === branch ? "#bbdefb" : undefined ,
190
+ } ,
191
+ } }
192
+ >
183
193
{ b }
184
194
</ MenuItem >
185
195
) ) }
@@ -209,6 +219,14 @@ export function BranchAndCommitPicker({
209
219
value = { r . head_sha }
210
220
condition = { isCommitHighlight ( highlightConfig ?. keys , r ) }
211
221
customColor = { highlightConfig ?. highlightColor }
222
+ sx = { {
223
+ backgroundColor : r . head_sha === commit ? "#e8f5e8" : undefined ,
224
+ fontWeight : r . head_sha === commit ? "bold" : "normal" ,
225
+ "&:hover" : {
226
+ backgroundColor :
227
+ r . head_sha === commit ? "#c8e6c8" : undefined ,
228
+ } ,
229
+ } }
212
230
>
213
231
{ r . head_sha . substring ( 0 , SHA_DISPLAY_LENGTH ) } (
214
232
{ dayjs ( r . event_time ) . format ( "YYYY/MM/DD" ) } )
Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ export const HighlightMenuItem = ({
11
11
condition,
12
12
children,
13
13
customColor = DEFAULT_HIGHLIGHT_MENU_ITEM_COLOR ,
14
+ sx,
14
15
...props
15
16
} : HighlightMenuItemProps ) => {
16
17
const highlightStyle = {
@@ -22,6 +23,7 @@ export const HighlightMenuItem = ({
22
23
< MenuItem
23
24
{ ...props }
24
25
sx = { {
26
+ ...sx ,
25
27
...( condition && highlightStyle ) ,
26
28
} }
27
29
>
You can’t perform that action at this time.
0 commit comments