all repos — nasg @ 0d1663d0dae1748a3d3da4204866b4389950ea57

templates/block_header_close.html (view raw)

 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
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
    <style id="dark" media="all">
        {% include 'style-dark.css' %}
    </style>
    <style id="light" media="none">
        {% include 'style-light.css' %}
    </style>
    <script>
        function toggleStylesheet(trigger){
            var curr = document.querySelector('#light').getAttribute("media");
            var setto = 'all';
            if (curr == 'all') {
                setto = 'none';
            }
            document.querySelector('#light').setAttribute("media", setto);
        }
    </script>
</head>
<body>

<header class="content-header" id="main-header">
    <nav class="content-navigation">
        <ul>
            <li>
{% set cssclass = '' %}
{% if taxonomy is defined and taxonomy.name == '' %}
    {% set cssclass = 'active' %}
{% endif %}
                <a title="home" href="/" class="{{ cssclass }}">
                    <svg class="icon" width="16" height="16"><use xlink:href="#icon-home" /></svg>
                    home
                </a>
            </li>
{% set cssclass = '' %}
{% if (post is defined and post.category ==  'photo' ) or ( taxonomy is defined and taxonomy.name == 'photo' ) %}
    {% set cssclass = 'active' %}
{% endif %}
            <li>
                <a title="photos" href="/category/photo/" class="{{ cssclass }}">
                    <svg class="icon" width="18" height="16"><use xlink:href="#icon-photo" /></svg>
                    photos
                </a>
            </li>
{% set cssclass = '' %}
{% if (post is defined and post.category ==  'journal' ) or ( taxonomy is defined and taxonomy.name == 'journal' ) %}
    {% set cssclass = 'active' %}
{% endif %}
            <li>
                <a title="journal" href="/category/journal/" class="{{ cssclass }}">
                    <svg class="icon" width="16" height="16"><use xlink:href="#icon-journal" /></svg>
                    journal
                </a>
            </li>
{% set cssclass = '' %}
{% if (post is defined and post.category ==  'article' ) or ( taxonomy is defined and taxonomy.name == 'article' ) %}
    {% set cssclass = 'active' %}
{% endif %}
            <li>
                <a title="IT" href="/category/article/" class="{{ cssclass }}">
                    <svg class="icon" width="16" height="16"><use xlink:href="#icon-article" /></svg>
                    IT
                </a>
            </li>
{% set cssclass = '' %}
{% if (post is defined and post.category ==  'note' ) or ( taxonomy is defined and taxonomy.name == 'note' ) %}
    {% set cssclass = 'active' %}
{% endif %}
            <li>
                <a title="notes" href="/category/note/" class="{{ cssclass }}">
                    <svg class="icon" width="16" height="16"><use xlink:href="#icon-note" /></svg>
                    notes
                </a>
            </li>
        </ul>
    </nav>

    <form role="search" method="get" class="search-form" action="/search">
        <label for="search" class="hide">Search</label>
        <input type="search" class="search-field" placeholder="search..." value="" name="s" id="s" title="Search for:" />
        <input type="submit" class="search-submit" value="Go ➡" />
    </form>

    <p class="contrast">
        <a title="toggle site colour scheme" href="#" onclick="toggleStylesheet(this)">
            <svg class="icon" width="16" height="16"><use xlink:href="#icon-contrast" /></svg>
        </a>
    </p>


</header>