File

graph.tmpl @ 14:1187d1379ac1 draft default tip

footer.tmpl: point URLs to my own site instead.
author Trần H. Trung <xmpp:trần.h.trung@trung.fun>
date Tue, 29 Aug 2023 15:50:06 +0700
parent 2:5ffc6136763b
line wrap: on
line source

{header}
<title>Graph {repo|escape}: revision</title>
<link rel="alternate" type="application/atom+xml"
   href="{url|urlescape}atom-log" title="Atom feed for {repo|escape}: log" />
<link rel="alternate" type="application/rss+xml"
   href="{url|urlescape}rss-log" title="RSS feed for {repo|escape}: log" />
</head>
<body>
    <div class="main">
        <div class="dd-hover menu">
        <div class="dd-content">
            <hr />
            <h6>{repo|escape}</h6>
            <ul>
                <li><a href="{url|urlescape}shortlog/{symrev}{sessionvars%urlparameter}">log</a></li>
                <li class="active">Graph</li>
                <li><a href="{url|urlescape}tags{sessionvars%urlparameter}">tags</a></li>
                <li><a href="{url|urlescape}bookmarks{sessionvars%urlparameter}">bookmarks</a></li>
                <li><a href="{url|urlescape}branches{sessionvars%urlparameter}">branches</a></li>
            </ul>
            <hr />
            <h6>{symrev}</h6>
            <ul>
                <li><a href="{url|urlescape}file/{symrev}{path|urlescape}{sessionvars%urlparameter}">browse</a></li>
                <li><a href="{url|urlescape}rev/{symrev}{sessionvars%urlparameter}">changeset</a></li>
            </ul>
            <ul>
                {archives%archiveentry}
            </ul>
            <hr />
            <ul>
                 <li><a href="{url|urlescape}help{sessionvars%urlparameter}">help</a></li>
            </ul>
            <div class="atom-logo">
                <a href="{url|urlescape}rss-bookmarks" title="subscribe to RSS feed">
                    RSS: <img class="rss-logo" src="{staticurl|urlescape}feed-icon-14x14.png" alt="RSS feed" />
                </a>
                <a href="{url|urlescape}atom-log" title="subscribe to Atom feed">
                    Atom: <img class="atom-logo" src="{staticurl|urlescape}feed-icon-14x14.png" alt="Atom feed" />
                </a>
            </div>
        </div>
            {logo}
        </div>
        <main>
            <hr />
            {searchform}

            <hr />
            <h3 class="breadcrumb"><a href="/">Software</a> {pathdef%breadcrumb}</h3>

            <hr />
            <h1>Graph</h1>
            <div class="navigate">
                <a href="{url|urlescape}graph/{symrev}{lessvars%urlparameter}">less</a>
                <a href="{url|urlescape}graph/{symrev}{morevars%urlparameter}">more</a>
                | rev {rev}: {changenav%navgraph}
            </div>

            <noscript><p>The revision graph only works with JavaScript-enabled browsers.</p></noscript>

            <div id="wrapper">
            <canvas id="graph"></canvas>
            <ul id="graphnodes" class="stripes2">{nodes%graphentry}</ul>
            </div>

            <script type="text/javascript"{if(nonce, ' nonce="{nonce}"')}>
            var data = {jsdata|json};
            var graph = new Graph();
            graph.scale({bg_height});
            graph.render(data);
            </script>

            <div class="navigate">
                <a href="{url|urlescape}graph/{symrev}{lessvars%urlparameter}">less</a>
                <a href="{url|urlescape}graph/{symrev}{morevars%urlparameter}">more</a>
                | rev {rev}: {changenav%navgraph}
            </div>

            <p>Scroll all the way down to load more.</p>

            <script type="text/javascript"{if(nonce, ' nonce="{nonce}"')}>
            ajaxScrollInit(
                    '{url|urlescape}graph/%next%{graphvars%urlparameter}',
                    '{nextentry%"{node}"}', <!-- NEXTHASH
                    function (htmlText) \{
                    var m = htmlText.match(/'(\w+)', <!-- NEXTHASH/);
                    return m ? m[1] : null;
                    },
                    '#wrapper',
                    '<div class="%class%" style="text-align: center;">%text%</div>',
                    'graph'
                    );
            </script>

        <p></p>
        <hr />
        </main>
    </div>
{logo}
    {banner}
{footer}