@@ -188,23 +188,18 @@ const _generateStyles = (
188
188
const fadedBlue = color . fadedBlue ;
189
189
// Light pink
190
190
const activeLightVisited = mix ( fade ( white , 0.32 ) , pink ) ;
191
- // Dark blue
192
- const activeDefaultPrimary = color . activeBlue ;
193
191
194
- const primaryDefaultTextColor = light ? white : blue ;
195
- const defaultTextColor = primaryDefaultTextColor ;
192
+ const restTextColor = light ? white : blue ;
193
+ const pressTextColor = light ? fadedBlue : color . activeBlue ;
196
194
197
- const primaryActiveColor = light ? fadedBlue : activeDefaultPrimary ;
198
- const activeColor = primaryActiveColor ;
199
-
200
- const defaultVisited = visitable
195
+ const restVisited = visitable
201
196
? {
202
197
":visited" : {
203
198
color : light ? pink : linkPurple ,
204
199
} ,
205
200
}
206
201
: Object . freeze ( { } ) ;
207
- const activeVisited = visitable
202
+ const pressVisited = visitable
208
203
? {
209
204
":visited" : {
210
205
color : light
@@ -215,35 +210,35 @@ const _generateStyles = (
215
210
: Object . freeze ( { } ) ;
216
211
217
212
const focusStyling = {
218
- color : defaultTextColor ,
213
+ color : restTextColor ,
219
214
outline : `1px solid ${ light ? white : blue } ` ,
220
215
borderRadius : 3 ,
221
- ...defaultVisited ,
216
+ ...restVisited ,
222
217
} ;
223
218
224
219
const pressStyling = {
225
- color : activeColor ,
220
+ color : pressTextColor ,
226
221
textDecoration : "underline currentcolor solid" ,
227
222
// TODO(WB-1521): Update the underline offset to be 4px after
228
223
// the Link audit.
229
224
// textUnderlineOffset: 4,
230
- ...activeVisited ,
225
+ ...pressVisited ,
231
226
} ;
232
227
233
228
const newStyles : StyleDeclaration = {
234
229
rest : {
235
- color : defaultTextColor ,
236
- ...defaultVisited ,
230
+ color : restTextColor ,
231
+ ...restVisited ,
237
232
":hover" : {
238
233
// TODO(WB-1521): Update text decoration to the 1px dashed
239
234
// underline after the Link audit.
240
235
// textDecoration: "underline currentcolor dashed 2px",
241
236
textDecoration : "underline currentcolor solid" ,
242
- color : defaultTextColor ,
237
+ color : restTextColor ,
243
238
// TODO(WB-1521): Update the underline offset to be 4px after
244
239
// the Link audit.
245
240
// textUnderlineOffset: 4,
246
- ...defaultVisited ,
241
+ ...restVisited ,
247
242
} ,
248
243
// Focus styles only show up with keyboard navigation.
249
244
// Mouse users don't see focus styles.
0 commit comments