Update web/templates/settings/home.html

This commit is contained in:
2025-08-20 02:12:07 +00:00
parent 127d2f1c31
commit 717e9aa959
+28 -16
View File
@@ -7,13 +7,14 @@
<!-- Blank Settings box --> <!-- Blank Settings box -->
<div class="settings-card"> <div class="settings-card">
<p class="muted small">No settings here yet — add options later.</p> <h2 class="section-title">Settings</h2>
<!-- Add form fields or options inside this box as needed --> <p class="muted small">Add your settings here when youre ready.</p>
<!-- Your future settings content goes here -->
</div> </div>
<!-- Tools box --> <!-- Tools box -->
<h1 class="page-title">Tools</h1>
<div class="settings-card"> <div class="settings-card">
<h2 class="section-title">Tools</h2>
<!-- Scripture Normalizer --> <!-- Scripture Normalizer -->
<div class="tool-block"> <div class="tool-block">
@@ -25,8 +26,9 @@
<div class="tool-actions"> <div class="tool-actions">
<form method="get" action="{% url 'normalize_scripture' %}" class="inline"> <form method="get" action="{% url 'normalize_scripture' %}" class="inline">
<input type="number" min="0" name="limit" placeholder="Preview limit (optional)" class="tool-input"> <input type="number" min="0" name="limit" placeholder="Preview limit (optional)" class="tool-input">
<button class="btn btn-secondary">Preview (dry-run)</button> <button class="btn btn-secondary">Preview (dryrun)</button>
</form> </form>
{% if user.is_authenticated and user.is_staff %} {% if user.is_authenticated and user.is_staff %}
<form method="post" action="{% url 'normalize_scripture' %}" class="inline"> <form method="post" action="{% url 'normalize_scripture' %}" class="inline">
{% csrf_token %} {% csrf_token %}
@@ -45,14 +47,15 @@
<div class="tool-block"> <div class="tool-block">
<h3>Source Normalizer</h3> <h3>Source Normalizer</h3>
<p class="small muted"> <p class="small muted">
Converts Watchtower/Awake!/Yearbook/KM references (e.g., “March 15, 2013 WT page 14”) into WOL short-codes Converts Watchtower/Awake!/Yearbook/KM references (e.g., “March 15, 2013 WT page 14”) into WOL shortcodes
like <code>w13 3/15 p.14</code>. Non-JW sources are left unchanged. like <code>w13 3/15 p.14</code>. NonJW sources are left unchanged.
</p> </p>
<div class="tool-actions"> <div class="tool-actions">
<form method="get" action="{% url 'normalize_source' %}" class="inline"> <form method="get" action="{% url 'normalize_source' %}" class="inline">
<input type="number" min="0" name="limit" placeholder="Preview limit (optional)" class="tool-input"> <input type="number" min="0" name="limit" placeholder="Preview limit (optional)" class="tool-input">
<button class="btn btn-secondary">Preview (dry-run)</button> <button class="btn btn-secondary">Preview (dryrun)</button>
</form> </form>
{% if user.is_authenticated and user.is_staff %} {% if user.is_authenticated and user.is_staff %}
<form method="post" action="{% url 'normalize_source' %}" class="inline"> <form method="post" action="{% url 'normalize_source' %}" class="inline">
{% csrf_token %} {% csrf_token %}
@@ -71,15 +74,16 @@
<div class="tool-block"> <div class="tool-block">
<h3>Subject Normalizer</h3> <h3>Subject Normalizer</h3>
<p class="small muted"> <p class="small muted">
Normalize the <strong>Subject</strong> field so individual subjects are comma-separated. Normalize the <strong>Subject</strong> field so individual subjects are commaseparated.
Preserves multi-word subjects; lightly fixes separators like “;” and spaced dashes. Preserves multiword subjects; lightly fixes separators like “;” and spaced dashes.
Uses your <code>subjects.txt</code> catalog when available. Uses your <code>subjects.txt</code> catalog when available.
</p> </p>
<div class="tool-actions"> <div class="tool-actions">
<form method="get" action="{% url 'normalize_subjects' %}" class="inline"> <form method="get" action="{% url 'normalize_subjects' %}" class="inline">
<input type="number" min="0" name="limit" placeholder="Preview limit (optional)" class="tool-input"> <input type="number" min="0" name="limit" placeholder="Preview limit (optional)" class="tool-input">
<button class="btn btn-secondary">Dry-run Preview</button> <button class="btn btn-secondary">Dryrun Preview</button>
</form> </form>
{% if user.is_authenticated and user.is_staff %} {% if user.is_authenticated and user.is_staff %}
<form method="post" action="{% url 'normalize_subjects' %}" class="inline"> <form method="post" action="{% url 'normalize_subjects' %}" class="inline">
{% csrf_token %} {% csrf_token %}
@@ -95,9 +99,15 @@
</div> </div>
<style> <style>
/* Background for Settings page */ /* Darker, caution-leaning gradient (no white stop) */
.settings-bg { .settings-bg {
background: linear-gradient(135deg, #fef9c3, #f3f4f6, #ffffff); /* tweak these if you want it warmer/cooler */
--caution-1: #d97706; /* amber-600 */
--caution-2: #92400e; /* amber/bronze-700 */
--caution-3: #374151; /* slate-700 */
background:
radial-gradient(900px 600px at 85% 15%, var(--caution-1) 0%, transparent 60%),
linear-gradient(135deg, var(--caution-2) 0%, var(--caution-3) 100%);
min-height: 100vh; min-height: 100vh;
} }
@@ -106,7 +116,7 @@
border:1px solid var(--border, #e5e7eb); border:1px solid var(--border, #e5e7eb);
border-radius:16px; border-radius:16px;
padding:20px; padding:20px;
box-shadow:0 6px 20px rgba(0,0,0,.05); box-shadow:0 6px 20px rgba(0,0,0,.08);
margin-top:20px; margin-top:20px;
} }
@@ -117,9 +127,7 @@
color:#1f2937; color:#1f2937;
} }
.tool-block { .tool-block { margin-bottom:16px; }
margin-bottom:16px;
}
.tool-block h3 { .tool-block h3 {
margin:0 0 6px; margin:0 0 6px;
font-size:18px; font-size:18px;
@@ -143,5 +151,9 @@
border-top:1px solid var(--border, #e5e7eb); border-top:1px solid var(--border, #e5e7eb);
margin:18px 0; margin:18px 0;
} }
/* Optional: improve contrast of buttons on this darker theme */
.btn.btn-secondary { background:#f3f4f6; border-color:#e5e7eb; }
.btn.btn-secondary:hover { background:#e5e7eb; }
</style> </style>
{% endblock %} {% endblock %}