Skip to content

Commit acee412

Browse files
committed
Add github project link to demo
1 parent 8c032b0 commit acee412

File tree

2 files changed

+28
-0
lines changed

2 files changed

+28
-0
lines changed

demo/src/js/components/Header.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ import 'sass/header';
55
export default function Header() {
66
return (
77
<header>
8+
<a href="https://github.com/wrakky/react-html-parser" target="_blank">
9+
<svg height="16" width="16" xmlns="http://www.w3.org/2000/svg">
10+
<path id="github" d="M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59 0.4 0.07 0.55-0.17 0.55-0.38 0-0.19-0.01-0.82-0.01-1.49-2.01 0.37-2.53-0.49-2.69-0.94-0.09-0.23-0.48-0.94-0.82-1.13-0.28-0.15-0.68-0.52-0.01-0.53 0.63-0.01 1.08 0.58 1.23 0.82 0.72 1.21 1.87 0.87 2.33 0.66 0.07-0.52 0.28-0.87 0.51-1.07-1.78-0.2-3.64-0.89-3.64-3.95 0-0.87 0.31-1.59 0.82-2.15-0.08-0.2-0.36-1.02 0.08-2.12 0 0 0.67-0.21 2.2 0.82 0.64-0.18 1.32-0.27 2-0.27 0.68 0 1.36 0.09 2 0.27 1.53-1.04 2.2-0.82 2.2-0.82 0.44 1.1 0.16 1.92 0.08 2.12 0.51 0.56 0.82 1.27 0.82 2.15 0 3.07-1.87 3.75-3.65 3.95 0.29 0.25 0.54 0.73 0.54 1.48 0 1.07-0.01 1.93-0.01 2.2 0 0.21 0.15 0.46 0.55 0.38C13.71 14.53 16 11.53 16 8 16 3.58 12.42 0 8 0z" />
11+
</svg>
12+
View Project on GitHub
13+
</a>
814
<h1>React HTML Parser Demo</h1>
915
</header>
1016
);

demo/src/sass/header.scss

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,27 @@
1+
$headerLinkColor: #cc0000;
2+
13
header {
24
h1 {
35
padding: 0 0 1rem;
46
}
7+
a {
8+
float: right;
9+
text-decoration: none;
10+
color: $headerLinkColor;
11+
line-height: 32px;
12+
svg {
13+
margin-right: 5px;
14+
position: relative;
15+
top: 2px;
16+
#github {
17+
fill: $headerLinkColor;
18+
}
19+
}
20+
&:hover {
21+
color: darken($headerLinkColor, 10%);
22+
#github {
23+
fill: darken($headerLinkColor, 10%);
24+
}
25+
}
26+
}
527
}

0 commit comments

Comments
 (0)