71 lines
2.1 KiB
Plaintext
71 lines
2.1 KiB
Plaintext
package pages
|
|
|
|
import (
|
|
"fmt"
|
|
c "git.ekzyis.com/ekzyis/delphi.market/server/router/context"
|
|
)
|
|
|
|
templ Index() {
|
|
<html>
|
|
<head>
|
|
<title>delphi.market</title>
|
|
<link rel="icon" type="image/x-icon" href="/favicon.ico"/>
|
|
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png"/>
|
|
<link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png"/>
|
|
<link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png"/>
|
|
<link rel="manifest" href="/site.webmanifest"/>
|
|
<link rel="stylesheet" href="/css/index.css"/>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<meta name="theme-color" content="#091833"/>
|
|
<script src="/js/htmx.js" integrity="sha384-Xh+GLLi0SMFPwtHQjT72aPG19QvKB8grnyRbYBNIdHWc2NkCrz65jlU7YrzO6qRp" crossorigin="anonymous"></script>
|
|
if ctx.Value(c.EnvContextKey) == "development" {
|
|
<script defer src="/js/hotreload.js"></script>
|
|
}
|
|
</head>
|
|
<body>
|
|
<header class="flex flex-row text-center justify-center pt-1">
|
|
<nav>
|
|
<a href="/">home</a>
|
|
if ctx.Value(c.SessionContextKey) != nil {
|
|
<a href="/user">user</a>
|
|
} else {
|
|
<a href="/login">login</a>
|
|
}
|
|
</nav>
|
|
</header>
|
|
<div class="container flex flex-column text-center">
|
|
<code>
|
|
<strong>
|
|
<!-- need to escape backslashes or backtick here ... -->
|
|
<pre>
|
|
{ fmt.Sprintf(""+
|
|
" _ _ _ _ \n"+
|
|
" __| | ___| |_ __ | |__ (_)\n"+
|
|
" / _` |/ _ \\ | '_ \\| '_ \\| |\n"+
|
|
"| (_| | __/ | |_) | | | | |\n"+
|
|
" \\__,_|\\___|_| .__/|_| |_|_|\n"+
|
|
" |_| \n") }
|
|
</pre>
|
|
</strong>
|
|
</code>
|
|
<div class="font-mono mb-1">A prediction market using the lightning network [WIP]</div>
|
|
</div>
|
|
<footer class="flex justify-center">
|
|
<div>
|
|
<hr/>
|
|
<small>
|
|
<code>
|
|
running
|
|
<a
|
|
href={ templ.SafeURL("https://github.com/ekzyis/delphi.market/commit/" + ctx.Value(c.CommitContextKey).(string)) }
|
|
target="_blank"
|
|
rel="noopener noreferrer"
|
|
>{ ctx.Value(c.CommitContextKey).(string) }</a>
|
|
</code>
|
|
</small>
|
|
</div>
|
|
</footer>
|
|
</body>
|
|
</html>
|
|
}
|