Getting icon loading in the root styles working

This commit is contained in:
Jeff Avallone
2018-02-10 17:55:48 -05:00
parent 2377cb2497
commit 74d622c7a4
6 changed files with 82 additions and 33 deletions
+1 -1
View File
@@ -4,7 +4,7 @@ import ReactDOM from 'react-dom';
import '../style.css';
import Message from '../components/Message';
import ErrorIcon from 'feather-icons/dist/icons/alert-octagon.svg';
import ErrorIcon from '!svg-react-loader!feather-icons/dist/icons/alert-octagon.svg';
ReactDOM.render(
<Message icon={ ErrorIcon } heading="404 Page Not Found">
+22 -9
View File
@@ -25,7 +25,7 @@ body {
font-size: 1.6rem;
}
:global(#main) {
#main {
background: var(--color-green) linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,0.4) 100%);
box-shadow: 0 0 1rem var(--color-black);
padding: 0 var(--content-margin);
@@ -33,7 +33,7 @@ body {
position: relative;
}
:global(#main) h1 {
#main h1 {
font-family: 'Bangers', 'cursive';
font-size: 4rem;
font-weight: normal;
@@ -42,20 +42,20 @@ body {
line-height: var(--header-height);
}
:global(#main) a {
#main a {
text-decoration: none;
display: inline-block;
}
:global(#main) ul {
#main ul {
line-height: var(--header-height);
position: absolute;
top: 0;
right: var(--content-margin);
}
:global(#main) li a:hover,
:global(#main) li a:active {
#main li a:hover,
#main li a:active {
text-decoration: underline;
}
@@ -84,15 +84,28 @@ li {
display: inline-block;
}
:global(.inline-list) li {
.inline-list li {
white-space: nowrap;
}
:global(.inline-list) li:after {
.inline-list li:after {
content: '//';
padding: 0 0.5rem;
}
:global(.inline-list) li:last-child:after {
.inline-list li:last-child:after {
content: '';
}
[icon] {
display: inline-block;
width: 1em;
height: 1em;
background-size: 1em 1em;
margin-right: 0.5rem;
vertical-align: text-top;
}
[icon="github"] {
background-image: url('~feather-icons/dist/icons/github.svg');
}
+1 -1
View File
@@ -17,7 +17,7 @@
<ul>
<li><a href="https://github.com/javallone/regexper-static">
Source on GitHub
<i icon="github"></i>Source on GitHub
</a></li>
</ul>
</header>