build:
- sed '/id=\"menu\"/s/middle/top/; /id=\"about\"/s/class=\".*\"/class=\"selected\"/; /data-name=\"about\"/s/class=\"\"/class=\"selected\"/' < index.html > about/index.html
- sed '/id=\"menu\"/s/middle/top/; /id=\"code\"/s/class=\".*\"/class=\"selected\"/; /data-name=\"code\"/s/class=\"\"/class=\"selected\"/' < index.html > code/index.html
- sed '/id=\"menu\"/s/middle/top/; /id=\"writing\"/s/class=\".*\"/class=\"selected\"/; /data-name=\"writing\"/s/class=\"\"/class=\"selected\"/' < index.html > writing/index.html
+ sed '/id=\"menu\"/s/middle/top/; /<body/s/yellow/green/; /id=\"about\"/s/class=\".*\"/class=\"selected\"/; /data-name=\"about\"/s/class=\"\"/class=\"selected\"/' < index.html > about/index.html
+ sed '/id=\"menu\"/s/middle/top/; /<body/s/yellow/blue/; /id=\"code\"/s/class=\".*\"/class=\"selected\"/; /data-name=\"code\"/s/class=\"\"/class=\"selected\"/' < index.html > code/index.html
+ sed '/id=\"menu\"/s/middle/top/; /<body/s/yellow/pink/; /id=\"writing\"/s/class=\".*\"/class=\"selected\"/; /data-name=\"writing\"/s/class=\"\"/class=\"selected\"/' < index.html > writing/index.html
<title>Jack Kinsey</title>
</head>
- <body>
+ <body class="green">
+ <main>
<menu id="menu" class="top">
- <div id="avatar"><a href="/" class="home"><img src="/res/face.png"></img></a></div></a>
- <div id="name"><a href="/" class="home"><h1>Jack Kinsey</h1></a></div>
+ <div id="avatar"><a href="/" data-color="yellow" class="home"><img src="/res/face.png"></img></a></div></a>
+ <div id="name"><a href="/" data-color="yellow" class="home"><h1>Jack Kinsey</h1></a></div>
<nav id="links">
<ul>
- <li><a href="/writing" class="" data-name="writing">Writing</a></li>
- <li><a href="/code" class="" data-name="code">Code</a></li>
- <li><a href="/about" class="selected" data-name="about">About</a></li>
+ <li><a href="/writing" class="" data-color="pink" data-name="writing">Writing</a></li>
+ <li><a href="/code" class="" data-color="blue" data-name="code">Code</a></li>
+ <li><a href="/about" class="selected" data-color="green" data-name="about">About</a></li>
<li><a href="/kinsey17-resume.pdf" data-name="resume">Résumé</a></li>
</ul>
</nav>
</article>
</div>
+ </main>
</body>
</html>
<title>Jack Kinsey</title>
</head>
- <body>
+ <body class="blue">
+ <main>
<menu id="menu" class="top">
- <div id="avatar"><a href="/" class="home"><img src="/res/face.png"></img></a></div></a>
- <div id="name"><a href="/" class="home"><h1>Jack Kinsey</h1></a></div>
+ <div id="avatar"><a href="/" data-color="yellow" class="home"><img src="/res/face.png"></img></a></div></a>
+ <div id="name"><a href="/" data-color="yellow" class="home"><h1>Jack Kinsey</h1></a></div>
<nav id="links">
<ul>
- <li><a href="/writing" class="" data-name="writing">Writing</a></li>
- <li><a href="/code" class="selected" data-name="code">Code</a></li>
- <li><a href="/about" class="" data-name="about">About</a></li>
+ <li><a href="/writing" class="" data-color="pink" data-name="writing">Writing</a></li>
+ <li><a href="/code" class="selected" data-color="blue" data-name="code">Code</a></li>
+ <li><a href="/about" class="" data-color="green" data-name="about">About</a></li>
<li><a href="/kinsey17-resume.pdf" data-name="resume">Résumé</a></li>
</ul>
</nav>
</article>
</div>
+ </main>
</body>
</html>
<title>Jack Kinsey</title>
</head>
- <body>
+ <body class="yellow">
+ <main>
<menu id="menu" class="middle">
- <div id="avatar"><a href="/" class="home"><img src="/res/face.png"></img></a></div></a>
- <div id="name"><a href="/" class="home"><h1>Jack Kinsey</h1></a></div>
+ <div id="avatar"><a href="/" data-color="yellow" class="home"><img src="/res/face.png"></img></a></div></a>
+ <div id="name"><a href="/" data-color="yellow" class="home"><h1>Jack Kinsey</h1></a></div>
<nav id="links">
<ul>
- <li><a href="/writing" class="" data-name="writing">Writing</a></li>
- <li><a href="/code" class="" data-name="code">Code</a></li>
- <li><a href="/about" class="" data-name="about">About</a></li>
+ <li><a href="/writing" class="" data-color="pink" data-name="writing">Writing</a></li>
+ <li><a href="/code" class="" data-color="blue" data-name="code">Code</a></li>
+ <li><a href="/about" class="" data-color="green" data-name="about">About</a></li>
<li><a href="/kinsey17-resume.pdf" data-name="resume">Résumé</a></li>
</ul>
</nav>
</article>
</div>
+ </main>
</body>
</html>
var home = document.getElementsByClassName("home");
var menu = document.getElementById("menu");
var content = document.getElementById("content");
+ var body = document.getElementsByTagName("body")[0];
var menuLoc = parseInt(getComputedStyle(menu).getPropertyValue("top"));
function menuOperator(position, token="") {
var article = document.getElementById(name);
article.setAttribute("class", "selected");
}
+ var color = node.getAttribute("data-color");
+ if(color) {
+ body.setAttribute("class", color);
+ }
window.history.pushState("object or string", "Title", node.href);
}
@import url('https://fonts.googleapis.com/css?family=Cutive+Mono|Source+Code+Pro:300');
+/* pink:473a47
+ * blue:004350
+ * green:0c5b57
+ * yellow:4b4432
+ */
body {
width:100%;
overflow-x:hidden;
font-family:'Cutive Mono', monospace;
color:#FFF1FF;
- #background-image:linear-gradient(to right,#00c4f4 0%,#278fba 20%,#278fba 80%,#00c4f4 100%);
- #background-color:#278fba;
- background:url(http://static.jkinsey.net/img/pinkishstardust.png) #323;
+ transition:background-color .6s cubic-bezier(0.23, 1, 0.32, 1);
+}
+
+body.pink {
+ background-color:#161216;
+}
+
+body.blue {
+ background-color:#001216;
+}
+
+body.green {
+ background-color:#031514;
+}
+
+body.yellow {
+ background-color:#191710;
+}
+
+main {
+ width:100%;
+ height:100%;
+ background:url(stars.png);
}
menu {
<title>Jack Kinsey</title>
</head>
- <body>
+ <body class="pink">
+ <main>
<menu id="menu" class="top">
- <div id="avatar"><a href="/" class="home"><img src="/res/face.png"></img></a></div></a>
- <div id="name"><a href="/" class="home"><h1>Jack Kinsey</h1></a></div>
+ <div id="avatar"><a href="/" data-color="yellow" class="home"><img src="/res/face.png"></img></a></div></a>
+ <div id="name"><a href="/" data-color="yellow" class="home"><h1>Jack Kinsey</h1></a></div>
<nav id="links">
<ul>
- <li><a href="/writing" class="selected" data-name="writing">Writing</a></li>
- <li><a href="/code" class="" data-name="code">Code</a></li>
- <li><a href="/about" class="" data-name="about">About</a></li>
+ <li><a href="/writing" class="selected" data-color="pink" data-name="writing">Writing</a></li>
+ <li><a href="/code" class="" data-color="blue" data-name="code">Code</a></li>
+ <li><a href="/about" class="" data-color="green" data-name="about">About</a></li>
<li><a href="/kinsey17-resume.pdf" data-name="resume">Résumé</a></li>
</ul>
</nav>
</article>
</div>
+ </main>
</body>
</html>