Moving list styles complete to use @apply

This commit is contained in:
Jeff Avallone 2018-02-15 09:08:50 -05:00
parent 672ded87af
commit 895827e881
7 changed files with 10 additions and 31 deletions

View File

@ -2,9 +2,7 @@
exports[`Footer rendering 1`] = `
<footer>
<ul
className="inline with-separator"
>
<ul>
<li>
<Trans>
Created by

View File

@ -5,7 +5,7 @@ import './style.css';
const Footer = () => (
<footer>
<ul className="inline with-separator">
<ul>
<li>
<Trans>Created by <a href="mailto:jeff.avallone@gmail.com">Jeff Avallone</a></Trans>
</li>

View File

@ -3,6 +3,11 @@
footer {
margin: var(--spacing-margin) 0;
& ul {
@apply --inline-list;
@apply --with-separator;
}
& img {
vertical-align: text-top;
width: 80px;

View File

@ -12,9 +12,7 @@ exports[`Header rendering 1`] = `
Regexper
</a>
</h1>
<ul
className="inline"
>
<ul>
<li>
<a
href="https://github.com/javallone/regexper-static"

View File

@ -10,7 +10,7 @@ const Header = () => (
<a href="/">Regexper</a>
</h1>
<ul className="inline">
<ul>
<li><a href="https://github.com/javallone/regexper-static">
<GithubIcon/><Trans>Source on GitHub</Trans>
</a></li>

View File

@ -38,6 +38,7 @@
}
& ul {
@apply --inline-list;
line-height: var(--header-height);
position: absolute;
top: 0;

View File

@ -16,26 +16,3 @@ body {
a {
color: inherit;
}
ul:global(.inline) {
list-style: none;
margin: 0;
padding: 0;
& li {
list-style-type: none;
display: inline-block;
white-space: nowrap;
}
&:global(.with-separator) {
& li:after {
content: '//';
padding: 0 0.5rem;
}
& li:last-child:after {
content: '';
}
}
}