diff options
Diffstat (limited to 'templates/index.j2')
| -rw-r--r-- | templates/index.j2 | 79 |
1 files changed, 8 insertions, 71 deletions
diff --git a/templates/index.j2 b/templates/index.j2 index 4ccdf92..fcea4e3 100644 --- a/templates/index.j2 +++ b/templates/index.j2 @@ -6,24 +6,8 @@ <title>Match Up!</title> <link rel="icon" type="image/x-icon" href="{{ url_for('static', filename='favicon.ico') }}"> <link rel="stylesheet" href="{{ url_for('static', filename='bulma.min.css') }}"> + <link rel="stylesheet" href="{{ url_for('static', filename='custom.css') }}"> <script src="{{ url_for('static', filename='htmx.min.js') }}"></script> - <style> - button, input, .select, .select select { - width: 100%; - } - table { - font-size: 30px; - } - td { - width: 20%; - } - img { - position: absolute; - top: 50%; - left: 50%; - transform: translate(-50%,-50%); - } - </style> </head> <body> <section class="section"> @@ -36,63 +20,16 @@ </div> </div> <div class="level-item"> - <p class="title">Today's Games</p> + <p class="title">Match Up!</p> + </div> + <div class="level-right"> + <div hx-get="/time" hx-swap="outerHTML" hx-trigger="revealed"></div> </div> </nav> </section> <section class="section"> - <p class="title">Games</p> - <div class="columns"> - <div class="column"> - <div class="field has-addons"> - <div class="control"> - <button class="button is-large is-responsive is-dark" - style="text-align:center" - hx-post="/decrement" - hx-swap="outerHTML" - hx-target="#guests">-</button> - </div> - <div hx-get="/guests" hx-swap="outerHTML" hx-trigger="revealed"></div> - <div class="control"> - <button class="button is-large is-responsive is-dark" - style="text-align:center" - hx-post="/increment" - hx-swap="outerHTML" - hx-target="#guests">+</button> - </div> - </div> - </div> - <div class="column"> - <div class="select is-large is-responsive"> - <select name="type"> - <option>10 Levels</option> - <option>8 Levels</option> - <option>6 Levels</option> - <option>4 Levels</option> - <option>2 Levels</option> - <option>0 Levels</option> - </select> - </div> - </div> - <div class="column"> - <button class="button is-dark is-large is-responsive" - hx-post="/propose" - hx-target="#games" - hx-include="[name='type']">New Round</button> - </div> - <div class="column"></div> - <div class="column"> - <button class="button is-dark is-large is-responsive" - hx-post="/confirm" - hx-target="#games">Start Round</button> - </div> - <div class="column"> - <button class="button is-dark is-large is-responsive" - hx-post="/clear" - hx-target="#games">Reset</button> - </div> - </div> - <div hx-post="/clear" hx-swap="outerHTML" hx-trigger="revealed"></div> + <p class="title">Games</p> + {% include 'controls.j2' %} </section> <section class="section"> <h2 class="title">Courts</h2> @@ -104,7 +41,7 @@ </section> <footer class="footer"> <div class="content has-text-centered"> - Made by <a href="https://karanjayachandra.com/">K. Jayachandra</a> using <a href="https://flask.palletsprojects.com">Flask</a>, <a href="https://htmx.org/">HTMX</a> and <a href="https://bulma.io">Bulma</a> + Made by <a href="https://karanjayachandra.com/">Karan</a> using <a href="https://flask.palletsprojects.com">Flask</a>, <a href="https://htmx.org/">HTMX</a> and <a href="https://bulma.io">Bulma</a> </div> </footer> </body> |
