WordPress/wp-content/themes/twentytwentyone/assets/sass/06-components/footer-navigation.scss
Peter Wilson fa364267d4 Twenty Twenty-One: Reverse logic for prefers-reduced-motion media query.
Reverse the logic of the `prefers-reduced-motion` to enable transitions based on `no-preference` rather than disable them based on the `reduce` preference. This removes the need to disable transitions with the `! important` tag and unintended interactions with plugins as a result.

Props gregoiresailland, sabernhardt, ryokuhi.
Fixes #54174.


Built from https://develop.svn.wordpress.org/trunk@52835


git-svn-id: http://core.svn.wordpress.org/trunk@52424 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2022-03-10 05:21:03 +00:00

77 lines
1.5 KiB
SCSS

.footer-navigation {
margin-top: calc(2 * var(--global--spacing-vertical));
margin-bottom: var(--global--spacing-vertical);
color: var(--footer--color-text);
font-size: var(--global--font-size-xs);
font-family: var(--footer--font-family);
}
.footer-navigation-wrapper {
display: flex;
justify-content: center;
flex-wrap: wrap;
list-style: none;
padding-left: 0;
li {
display: inline;
// This is to prevent hover styles from overlapping when the menu wraps.
line-height: 3;
a {
padding: calc(1.25 * var(--primary-nav--padding)) var(--primary-nav--padding);
color: var(--footer--color-link);
&:link,
&:visited,
&:active {
color: var(--footer--color-link);
}
&:hover {
text-decoration: underline;
text-decoration-style: dotted;
text-decoration-skip-ink: none;
color: var(--footer--color-link-hover);
}
&:focus {
.is-dark-theme & {
.svg-icon {
fill: var(--wp--style--color--link, var(--global--color-background));
}
}
// Change colors when the body background is white.
.has-background-white & {
.svg-icon {
fill: var(--wp--style--color--link, var(--global--color-white));
}
}
}
}
.svg-icon {
vertical-align: middle;
fill: var(--footer--color-link);
&:hover {
transform: scale(1.1);
}
@media (prefers-reduced-motion: no-preference) {
transition: transform 0.1s ease;
}
}
}
.sub-menu-toggle,
.menu-item-description {
display: none;
}
}