style(ui): unify settings input fields with consistent label style
Build and Deploy / build-and-push (push) Successful in 52s

This commit is contained in:
2026-07-27 02:27:12 +08:00
parent 334152417b
commit f004cfc937
+37 -31
View File
@@ -267,8 +267,14 @@ export default function Settings() {
</Card>
<Card className="space-y-3 p-4">
<h2 className="font-medium"></h2>
<Input placeholder="站点标题" value={siteForm.title} onChange={(e) => setSiteForm((f) => ({ ...f, title: e.target.value }))} />
<Input placeholder="站点副标题" value={siteForm.subtitle} onChange={(e) => setSiteForm((f) => ({ ...f, subtitle: e.target.value }))} />
<div>
<label className="mb-1 block text-xs text-[var(--text-muted)]"></label>
<Input placeholder="任务池" value={siteForm.title} onChange={(e) => setSiteForm((f) => ({ ...f, title: e.target.value }))} />
</div>
<div>
<label className="mb-1 block text-xs text-[var(--text-muted)]"></label>
<Input placeholder="轻量级任务调度平台" value={siteForm.subtitle} onChange={(e) => setSiteForm((f) => ({ ...f, subtitle: e.target.value }))} />
</div>
<div className="grid gap-3 md:grid-cols-2">
<div>
<label className="mb-1 block text-xs text-[var(--text-muted)]"></label>
@@ -332,38 +338,38 @@ taskpool mcp --http :8053`}</pre>
</div>
<h3 className="pt-2 text-sm font-medium text-[var(--text-secondary)]"></h3>
<p className="text-xs text-[var(--text-muted)]"></p>
<div className="space-y-3">
<div className="rounded-md border border-[var(--border)] bg-[var(--bg-tertiary)]/50 p-3">
<div className="mb-2 text-sm font-medium text-[var(--text-primary)]"></div>
<p className="mb-2 text-xs text-[var(--text-muted)]"></p>
<div className="grid gap-2 md:grid-cols-2">
<Input placeholder="保留天数" value={siteForm.system_notice_days} onChange={(e) => setSiteForm((f) => ({ ...f, system_notice_days: e.target.value }))} />
<Input placeholder="最大条数" value={siteForm.system_notice_max_count} onChange={(e) => setSiteForm((f) => ({ ...f, system_notice_max_count: e.target.value }))} />
</div>
<div className="grid gap-3 md:grid-cols-2">
<div>
<label className="mb-1 block text-xs text-[var(--text-muted)]"></label>
<Input placeholder="7" value={siteForm.system_notice_days} onChange={(e) => setSiteForm((f) => ({ ...f, system_notice_days: e.target.value }))} />
</div>
<div className="rounded-md border border-[var(--border)] bg-[var(--bg-tertiary)]/50 p-3">
<div className="mb-2 text-sm font-medium text-[var(--text-primary)]"></div>
<p className="mb-2 text-xs text-[var(--text-muted)]">Telegram </p>
<div className="grid gap-2 md:grid-cols-2">
<Input placeholder="保留天数" value={siteForm.push_log_days} onChange={(e) => setSiteForm((f) => ({ ...f, push_log_days: e.target.value }))} />
<Input placeholder="最大条数" value={siteForm.push_log_max_count} onChange={(e) => setSiteForm((f) => ({ ...f, push_log_max_count: e.target.value }))} />
</div>
<div>
<label className="mb-1 block text-xs text-[var(--text-muted)]"></label>
<Input placeholder="1000" value={siteForm.system_notice_max_count} onChange={(e) => setSiteForm((f) => ({ ...f, system_notice_max_count: e.target.value }))} />
</div>
<div className="rounded-md border border-[var(--border)] bg-[var(--bg-tertiary)]/50 p-3">
<div className="mb-2 text-sm font-medium text-[var(--text-primary)]"></div>
<p className="mb-2 text-xs text-[var(--text-muted)]"> IP</p>
<div className="grid gap-2 md:grid-cols-2">
<Input placeholder="保留天数" value={siteForm.login_log_days} onChange={(e) => setSiteForm((f) => ({ ...f, login_log_days: e.target.value }))} />
<Input placeholder="最大条数" value={siteForm.login_log_max_count} onChange={(e) => setSiteForm((f) => ({ ...f, login_log_max_count: e.target.value }))} />
</div>
<div>
<label className="mb-1 block text-xs text-[var(--text-muted)]"></label>
<Input placeholder="7" value={siteForm.push_log_days} onChange={(e) => setSiteForm((f) => ({ ...f, push_log_days: e.target.value }))} />
</div>
<div className="rounded-md border border-[var(--border)] bg-[var(--bg-tertiary)]/50 p-3">
<div className="mb-2 text-sm font-medium text-[var(--text-primary)]"></div>
<p className="mb-2 text-xs text-[var(--text-muted)]"></p>
<div className="grid gap-2 md:grid-cols-2">
<Input placeholder="保留天数" value={siteForm.scheduler_log_days} onChange={(e) => setSiteForm((f) => ({ ...f, scheduler_log_days: e.target.value }))} />
<Input placeholder="最大条数" value={siteForm.scheduler_log_max_count} onChange={(e) => setSiteForm((f) => ({ ...f, scheduler_log_max_count: e.target.value }))} />
</div>
<div>
<label className="mb-1 block text-xs text-[var(--text-muted)]"></label>
<Input placeholder="1000" value={siteForm.push_log_max_count} onChange={(e) => setSiteForm((f) => ({ ...f, push_log_max_count: e.target.value }))} />
</div>
<div>
<label className="mb-1 block text-xs text-[var(--text-muted)]"></label>
<Input placeholder="30" value={siteForm.login_log_days} onChange={(e) => setSiteForm((f) => ({ ...f, login_log_days: e.target.value }))} />
</div>
<div>
<label className="mb-1 block text-xs text-[var(--text-muted)]"></label>
<Input placeholder="1000" value={siteForm.login_log_max_count} onChange={(e) => setSiteForm((f) => ({ ...f, login_log_max_count: e.target.value }))} />
</div>
<div>
<label className="mb-1 block text-xs text-[var(--text-muted)]"></label>
<Input placeholder="7" value={siteForm.scheduler_log_days} onChange={(e) => setSiteForm((f) => ({ ...f, scheduler_log_days: e.target.value }))} />
</div>
<div>
<label className="mb-1 block text-xs text-[var(--text-muted)]"></label>
<Input placeholder="1000" value={siteForm.scheduler_log_max_count} onChange={(e) => setSiteForm((f) => ({ ...f, scheduler_log_max_count: e.target.value }))} />
</div>
</div>
<Button onClick={() => saveSite.mutate()} disabled={saveSite.isPending}>