m-chrzan.xyz
aboutsummaryrefslogtreecommitdiff
path: root/src/template.html.erb
blob: 20555713d6be394ac0dfb3c80c66700866b45b14 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<!DOCTYPE html>
<head>
    <title><%= head_title %></title>
    <link rel='stylesheet' type='text/css' href='<%= path_to 'style' %>'>
    <meta charset='utf-8'>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>
<body>
    <h1><%= h1_title %></h1>

    <hr />

    <ul class='links'>
        <li><a href='<%= path_to 'index' %>'>Home</a></li>
        <li><a id='writings' href='<%= path_to 'blog' %>'>Writings</a></li>
        <li><a href='<%= path_to 'projects' %>'>Projects</a></li>
    </ul>

    <hr />

    <%= content %>

    <script>
        var synonyms = [
            'Writings',
            'Blog',
            'Articles',
            'Posts',
            'Notes',
            'Memos',
            'Thoughths',
            'Words'
        ]
        var writings = document.getElementById('writings')
        writings.addEventListener('mouseenter', function (event) {

            writings.innerHTML =
                synonyms[Math.floor(Math.random() * synonyms.length)]
        })
    </script>
</body>