diff --git a/lib/aiRuns.js b/lib/aiRuns.js index 467e371..bc2fd77 100644 --- a/lib/aiRuns.js +++ b/lib/aiRuns.js @@ -6,6 +6,7 @@ const path = require('path'); const db = require('./db'); const store = require('./store'); const ai = require('./ai'); +const fingerprint = require('./fingerprint'); const CONCURRENCY = 3; const MAX_FAILURES_IN_A_ROW = 5; @@ -133,6 +134,8 @@ async function processRun(runId) { const results = await Promise.all(items.map((item) => tagOne(runId, item.model_id, config, { images, knownTags, overwrite: overwriteDescriptions }))); + // New tags and descriptions change a model's search text, so refresh the index. + if (results.some((r) => r.ok)) fingerprint.kick(); for (const r of results) { if (r.imageRejected && images) { images = false; diff --git a/public/styles.css b/public/styles.css index f66cf23..2921deb 100644 --- a/public/styles.css +++ b/public/styles.css @@ -105,7 +105,7 @@ header { .tags-list { display: flex; flex-wrap: wrap; gap: 6px; } .tag { - font-size: 12px; padding: 4px 10px; border-radius: 12px; cursor: pointer; + font-size: 12px; padding: 4px 10px; border-radius: 12px; cursor: pointer; white-space: nowrap; background: var(--surface-2); color: var(--text-muted); border: 1px solid var(--border); transition: all 0.12s; } @@ -202,7 +202,8 @@ label { display: block; font-size: 13px; font-weight: 500; color: var(--text-mut .modal-body { padding: 22px; } .form-group { margin-bottom: 18px; } .print-settings { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; } -.form-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; } +.form-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; margin-top: 22px; } +.form-actions .btn { white-space: nowrap; } /* ---- model detail ---- */ /* minmax(0, …) keeps a long file name from widening its column and crushing the viewer */ @@ -250,6 +251,7 @@ label { display: block; font-size: 13px; font-weight: 500; color: var(--text-mut .info-section:last-of-type { margin-bottom: 0; } .info-section h3 { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-dim); margin-bottom: 9px; } .info-section p, .info-section div { color: var(--text); font-size: 14px; line-height: 1.6; } +.info-section .tags { display: flex; flex-wrap: wrap; gap: 6px; } .info-section .tag { cursor: default; } .file-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--border); font-size: 14px; color: var(--text-muted); }