Fix AI status badge sizing on worker page

Restore .ai-badge as a text pill and scope the compact icon circle to .ai-badge-ic (used by journal); worker page text badges now render at correct size
This commit is contained in:
dev
2026-09-11 14:38:46 +03:00
parent ad81adfe71
commit 7044505915
2 changed files with 5 additions and 4 deletions
+4 -3
View File
@@ -361,12 +361,13 @@ body{font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif;b
#aiSuggestion{font-size:.9rem;line-height:1.5} #aiSuggestion{font-size:.9rem;line-height:1.5}
/* --- AI auto-check --- */ /* --- AI auto-check --- */
.ai-badge{display:inline-flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:999px;margin-left:8px;vertical-align:middle;background:rgba(37,99,235,.1);color:var(--accent);cursor:help;flex-shrink:0} .ai-badge{display:inline-block;font-size:.68rem;font-weight:600;line-height:1;padding:3px 8px;border-radius:999px;margin-left:6px;vertical-align:middle;background:rgba(37,99,235,.1);color:var(--accent);white-space:nowrap}
.ai-badge svg{width:14px;height:14px;display:block} .ai-badge-ic{display:inline-flex;align-items:center;justify-content:center;width:22px;height:22px;padding:0;margin-left:8px;cursor:help;flex-shrink:0}
.ai-badge-ic svg{width:14px;height:14px;display:block}
.ai-badge-done{background:rgba(22,163,74,.12);color:#16a34a} .ai-badge-done{background:rgba(22,163,74,.12);color:#16a34a}
.ai-badge-error{background:rgba(239,68,68,.12);color:#ef4444} .ai-badge-error{background:rgba(239,68,68,.12);color:#ef4444}
.ai-badge-skipped,.ai-badge-reverted{background:rgba(148,163,184,.18);color:var(--muted)} .ai-badge-skipped,.ai-badge-reverted{background:rgba(148,163,184,.18);color:var(--muted)}
.ai-badge-processing .lucide-loader{animation:spin 1s linear infinite} .ai-badge-ic.ai-badge-processing .lucide-loader{animation:spin 1s linear infinite}
@keyframes spin{to{transform:rotate(360deg)}} @keyframes spin{to{transform:rotate(360deg)}}
.ai-status{margin-top:6px;font-size:.78rem;color:var(--muted)} .ai-status{margin-top:6px;font-size:.78rem;color:var(--muted)}
.ai-queue{margin-top:8px;font-size:.78rem;color:var(--muted)} .ai-queue{margin-top:8px;font-size:.78rem;color:var(--muted)}
+1 -1
View File
@@ -63,7 +63,7 @@ function aiBadge(e) {
const st = e.ai_status; const st = e.ai_status;
const label = AI_STATUS_LABELS[st] || `ИИ: ${st}`; const label = AI_STATUS_LABELS[st] || `ИИ: ${st}`;
const icon = AI_STATUS_ICONS[st] || 'sparkles'; const icon = AI_STATUS_ICONS[st] || 'sparkles';
return `<span class="ai-badge ai-badge-${esc(st)}" title="${esc(label)}" role="img" aria-label="${esc(label)}"><i data-lucide="${icon}"></i></span>`; return `<span class="ai-badge ai-badge-ic ai-badge-${esc(st)}" title="${esc(label)}" role="img" aria-label="${esc(label)}"><i data-lucide="${icon}"></i></span>`;
} }
function findFile(id) { function findFile(id) {