2024-03-16 18:29:52 -05:00
|
|
|
<!-- views/index.etlua -->
|
2024-03-21 15:16:19 -05:00
|
|
|
<!DOCTYPE HTML>
|
2024-03-16 20:32:35 -05:00
|
|
|
<script src="/static/htmx.min.js"></script>
|
2024-03-18 19:38:28 -05:00
|
|
|
<% if not isPopulated then %>
|
2024-03-18 15:31:53 -05:00
|
|
|
<div id="clickable">
|
|
|
|
<button hx-post="/clickme" hx-target="#clickable">Start</button>
|
|
|
|
</div>
|
2024-03-18 19:38:28 -05:00
|
|
|
<% end %>
|
2024-03-16 18:29:52 -05:00
|
|
|
|
2024-03-21 15:16:19 -05:00
|
|
|
<article style="text-align: center;">
|
|
|
|
<h3>Log In / Create Game</h3>
|
2024-03-21 17:48:24 -05:00
|
|
|
<p>Player will be created if player name does not already exist. Names may not contain whitespace.</p>
|
2024-03-21 15:16:19 -05:00
|
|
|
<form>
|
|
|
|
<div class="grid">
|
|
|
|
<input type="text" name="playername">
|
|
|
|
<input type="submit" hx-post="/character-create" hx-trigger="click" value="Execute" hx-target="#replace">
|
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
<div>
|
|
|
|
<p id="replace"></p>
|
|
|
|
</div>
|
|
|
|
</article>
|
2024-03-18 15:31:53 -05:00
|
|
|
|
2024-03-21 15:16:19 -05:00
|
|
|
<a href="/game">Play Now</a>
|
2024-03-18 19:06:37 -05:00
|
|
|
</main>
|
2024-03-16 20:00:13 -05:00
|
|
|
|
2024-03-21 15:16:19 -05:00
|
|
|
<!-- TODO: On player create use Model to make new game_ref and append game_ref to self_session -->
|