mirror of
https://github.com/facebook/docusaurus.git
synced 2025-07-17 08:37:57 +02:00
fix(v2): add shadow to skip link on hover only (#5050)
This commit is contained in:
parent
99270dbab2
commit
aa79387e12
2 changed files with 2 additions and 5 deletions
|
@ -6,7 +6,6 @@
|
|||
*/
|
||||
|
||||
import React, {useRef} from 'react';
|
||||
import clsx from 'clsx';
|
||||
import Translate from '@docusaurus/Translate';
|
||||
import {useLocationChange} from '@docusaurus/theme-common';
|
||||
|
||||
|
@ -40,10 +39,7 @@ function SkipToContent(): JSX.Element {
|
|||
|
||||
return (
|
||||
<div ref={containerRef}>
|
||||
<a
|
||||
href="#main"
|
||||
className={clsx(styles.skipToContent, 'shadow--md')}
|
||||
onClick={handleSkip}>
|
||||
<a href="#main" className={styles.skipToContent} onClick={handleSkip}>
|
||||
<Translate
|
||||
id="theme.common.skipToMainContent"
|
||||
description="The skip to content label used for accessibility, allowing to rapidly navigate to main content with keyboard tab/enter navigation">
|
||||
|
|
|
@ -10,4 +10,5 @@
|
|||
|
||||
.skipToContent:focus {
|
||||
left: 1rem;
|
||||
box-shadow: var(--ifm-global-shadow-md);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue