File tree 2 files changed +26
-2
lines changed
2 files changed +26
-2
lines changed Original file line number Diff line number Diff line change @@ -186,10 +186,17 @@ class TagSelect extends React.Component {
186
186
? ( showTagsAlphabetically ? _ . sortBy ( value ) : value ) . map ( ( tag ) => {
187
187
const wrapperStyle = { }
188
188
const textStyle = { }
189
+ const BLACK = '#333333'
190
+ const WHITE = '#f1f1f1'
189
191
const color = coloredTags [ tag ]
192
+ const invertedColor = color && invertColor ( color , { black : BLACK , white : WHITE } )
193
+ let iconRemove = '../resources/icon/icon-x.svg'
190
194
if ( color ) {
191
195
wrapperStyle . backgroundColor = color
192
- textStyle . color = invertColor ( color , { black : '#222' , white : '#f1f1f1' } )
196
+ textStyle . color = invertedColor
197
+ }
198
+ if ( invertedColor === WHITE ) {
199
+ iconRemove = '../resources/icon/icon-x-light.svg'
193
200
}
194
201
return (
195
202
< span styleName = 'tag'
@@ -200,7 +207,7 @@ class TagSelect extends React.Component {
200
207
< button styleName = 'tag-removeButton'
201
208
onClick = { ( e ) => this . handleTagRemoveButtonClick ( tag ) }
202
209
>
203
- < img className = 'tag-removeButton-icon' src = '../resources/icon/icon-x.svg' width = '8px' />
210
+ < img className = 'tag-removeButton-icon' src = { iconRemove } width = '8px' />
204
211
</ button >
205
212
</ span >
206
213
)
You can’t perform that action at this time.
0 commit comments