From 2c3365447f36c26f2f55cc2a1b42a1e3ad0a8db9 Mon Sep 17 00:00:00 2001 From: Christian Heller <c.heller@plomlompom.de> Date: Mon, 29 Apr 2024 00:07:30 +0200 Subject: [PATCH] Improve button layouts. --- templates/base.html | 12 ++++++++++++ templates/process.html | 23 +++++++++++++++++++++-- 2 files changed, 33 insertions(+), 2 deletions(-) diff --git a/templates/base.html b/templates/base.html index 3408d67..71c79b4 100644 --- a/templates/base.html +++ b/templates/base.html @@ -8,6 +8,18 @@ body { ul { list-style-type: none; } +input.btn-harmless { + color: green; +} +input.btn-dangerous { + color: red; +} +div.btn-to-right { + float: right; + text-align: right; +} +{% block css %} +{% endblock %} </style> <body> <a href="processes">processes</a> diff --git a/templates/process.html b/templates/process.html index 8c219c6..8a50e15 100644 --- a/templates/process.html +++ b/templates/process.html @@ -1,5 +1,20 @@ {% extends 'base.html' %} +{% block css %} +input.btn-harmless { + color: green; +} +input.btn-dangerous { + color: red; +} +div.btn-to-right { + float: right; + text-align: right; +} +{% endblock %} + + + {% macro step_with_steps(step_id, step_node, indent) %} <tr> <td> @@ -30,6 +45,8 @@ add step: <input name="new_step_to_{{step_id}}" list="candidates" autocomplete=" {% endif %} {% endmacro %} + + {% block content %} <h3>process</h3> <form action="process?id={{process.id_ or ''}}" method="POST"> @@ -122,8 +139,10 @@ add step: <input name="new_top_step" list="step_candidates" autocomplete="off" / <option value="{{candidate.id_}}">{{candidate.title.newest|e}}</option> {% endfor %} </datalist> -<input type="submit" name="update" value="update" /> -<input type="submit" name="delete" value="delete" /> +<input class="btn-harmless" type="submit" name="update" value="update" /> +<div class="btn-to-right"> +<input class="btn-dangerous" type="submit" name="delete" value="delete" /> +</div> </form> <h4>step of</h4> <ul> -- 2.30.2