<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Loading... - magneticow</title>

    <link rel="stylesheet" href="/static/styles/reset.css">
    <link rel="stylesheet" href="/static/styles/vanillatree-v0.0.3.css">
    <link rel="stylesheet" href="/static/styles/essential.css">
    <link rel="stylesheet" href="/static/styles/torrent.css">

    <script src="/static/scripts/naturalSort-v0.8.1.js"></script>
    <script src="/static/scripts/mustache-v2.3.0.min.js"></script>
    <script src="/static/scripts/vanillatree-v0.0.3.js"></script>

    <!-- Goes into <main> -->
    <script id="main-template" type="text/x-handlebars-template">
        <div id="title">
            <h2>{{ name }}</h2>
            <a href="magnet:?xt=urn:btih:{{ infoHash }}&amp;dn={{ name }}">
                <img src="/static/assets/magnet.gif" alt="Magnet link"
                     title="Download this torrent using magnet"/>
                <small>{{ infoHash }}</small>
            </a>
        </div>

        <table>
            <tr>
                <th scope="row">Size</th>
                <td>{{ sizeHumanised }}</td>
            </tr>
            <tr>
                <th scope="row">Discovered on</th>
                <td>{{ discoveredOnHumanised }}</td>
            </tr>
            <tr>
                <th scope="row">Files</th>
                <td>{{ nFiles }}</td>
            </tr>
        </table>

        <h3>Files</h3>
        <div id="fileTree"></div>

        <h3>Readme</h3>
        <pre id="readme">Loading...</pre>
    </script>
</head>
<body>
<header>
    <div><a href="/"><b>magnetico<sup>w</sup></b></a>&#8203;<sub>(pre-alpha)</sub></div>
    <form action="/torrents" method="get" autocomplete="off" role="search">
        <input type="search" name="query" placeholder="Search the BitTorrent DHT">
    </form>
</header>
<main>

</main>

<script src="/static/scripts/common.js"></script>
<script src="/static/scripts/torrent.js"></script>
</body>
</html>