File tree Expand file tree Collapse file tree 2 files changed +9
-8
lines changed
Expand file tree Collapse file tree 2 files changed +9
-8
lines changed Original file line number Diff line number Diff line change @@ -98,15 +98,8 @@ const decideContrastRequired = (colour: string) => {
9898const addContrastingBorderCss = ( colour : string ) => {
9999 const mode = decideContrastRequired ( colour ) ;
100100 if ( mode === 'none' ) return null ;
101-
102101 return css `
103- /* stylelint-disable-next-line media-query-no-invalid */
104- @media (prefers-color-scheme: ${ mode } ) {
105- border : 1px solid ${ palette ( '--football-match-stat-border' ) } ;
106- }
107- [data-color-scheme = '${ mode } ' ] & {
108- border : 1px solid ${ palette ( '--football-match-stat-border' ) } ;
109- }
102+ bor der: 1px solid ${ palette ( `--football-match-stat-contrast-${ mode } ` ) } ;
110103 ` ;
111104} ;
112105
Original file line number Diff line number Diff line change @@ -7124,6 +7124,14 @@ const paletteColours = {
71247124 light : ( ) => '#00679E' , // replace with Source's `calculateHoverColour` when available
71257125 dark : ( ) => '#00A1E6' ,
71267126 } ,
7127+ '--football-match-stat-contrast-dark' : {
7128+ light : ( ) => 'transparent' ,
7129+ dark : ( ) => sourcePalette . neutral [ 46 ] ,
7130+ } ,
7131+ '--football-match-stat-contrast-light' : {
7132+ light : ( ) => sourcePalette . neutral [ 46 ] ,
7133+ dark : ( ) => 'transparent' ,
7134+ } ,
71277135 '--football-match-stat-text' : {
71287136 light : ( ) => sourcePalette . neutral [ 7 ] ,
71297137 dark : ( ) => sourcePalette . neutral [ 86 ] ,
You can’t perform that action at this time.
0 commit comments