<nav class="navbar navbar-default navbar-fixed-top" role="navigation">
    <div class="container">
        <div class="navbar-header">
            <a class="navbar-brand" href="/">
                <img class="navbar-brand-logo js-pride-logo" src="{{ "/images/logo.svg" | relative_url }}" data-pride-src="{{ "/images/logo-pride.svg" | relative_url }}" alt="" />
                <span>chaospott</span>
            </a>
            <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target=".navbar-collapse">
                <span class="sr-only">Toggle navigation</span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
            </button>
        </div>
        <div class="navbar-collapse collapse">
            <ul class="nav navbar-nav">
                <li><a href="/">Home</a></li>
                <li class="divider-vertical"></li>
                <li><a href="/blog/">Logbuch</a></li>
                <li class="divider-vertical"></li>
                <li><a href="{{ '/blog/repaircafe/' | relative_url }}">Repaircafé</a></li>
                <li class="divider-vertical"></li>
                <li><a href="/about.html">&Uuml;ber uns</a></li>
                <!-- <li class="divider-vertical"></li>
                <li><a href="/virtuell.html">Virtueller c3e</a></li> -->
                <li class="divider-vertical"></li>
                <li><a href="/projects/projects.html">Projekte</a></li>
                <li class="divider-vertical"></li>
                <li><a href="/cms.html">Schule</a></li>
                <li class="divider-vertical"></li>
                <li><a href="https://wiki.chaospott.de">Wiki</a></li>
                <li class="divider-vertical"></li>
                <li><a href="https://podcast.chaospott.de">Podcast</a></li>
                <li class="divider-vertical"></li>
                <li><a href="/calendar.html">Termine</a></li>
            </ul>
            <ul class="nav navbar-nav navbar-right">
                <script>
                    $.getJSON("https://status.chaospott.de/status.json").done(function (data) {
                        if (data.state.open) {
                            $("#foodoor").removeClass("unknown").addClass("open");
                            $("#status_bar").css("borderColor", "#29A900");
                        } else {
                            $("#foodoor").removeClass("unknown").addClass("closed");
                            $("#status_bar").css("borderColor", "#D9534F");
                        }
                    });
                    $.getJSON("https://status.chaospott.de/chaospott_mumble.json").done(function (data) {
                        if (data.connected_users > 1) {
                            $("#mumble").removeClass("unknown").addClass("open");
                            document.getElementById("mumble_users_online").textContent = data.connected_users;
                        } else {
                            $("#mumble").removeClass("unknown").addClass("closed");
                        }
                    });
                </script>

                <li id="foodoor" class="status unknown">
                    <a href="#" style="color:#ffffff !important;">
                        <span class="ifunknown" title="Clubstatus unbekannt">Club: <i class="fa fa-question"></i></span>
                        <span class="ifopen" title="Der Club ist geöffnet">Club: <i class="fa fa-lock-open"></i></span>
                        <span class="ifclosed" title="Der Club ist geschlossen">Club: <i class="fa fa-lock"></i></span>
                    </a>
                </li>

                <li id="spacer" style="background-color:#d2d4bc">&nbsp;</li>

                <li id="mumble" class="status unknown">
                    <a href="mumble://mumble.chaospott.de" style="color:#ffffff !important;">
                        <span class="ifunknown"><i class="fa fa-microphone-alt"></i> Mumble</span>
                        <span class="ifopen"><i class="fa fa-microphone"></i> Mumble: <span id="mumble_users_online"></span></span>
                        <span class="ifclosed"><i class="fa fa-microphone-slash"></i> Mumble: 0</span>
                    </a>
                </li>
            </ul>
        </div>
    </div>
    <hr id="status_bar">
</nav>
