From 0830c999224d817a55085f9e0c69cd4e20f0d8e7 Mon Sep 17 00:00:00 2001 From: dev Date: Sun, 1 Nov 2026 22:16:25 +0300 Subject: [PATCH] fix(feedback): ring around resident photo img --- public/feedback.html | 6 ++++-- public/js/feedback.js | 6 ++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/public/feedback.html b/public/feedback.html index 1f31dbd..1612e40 100644 --- a/public/feedback.html +++ b/public/feedback.html @@ -38,7 +38,8 @@ .fb-tpl-row button:disabled { opacity:.5; cursor:default; } .fb-mark-wrap { position:relative; } .fb-mark-stripe { position:absolute; left:2px; right:2px; bottom:-6px; height:3px; border-radius:999px; z-index:0; transition:background .25s ease, box-shadow .25s ease; } - #fbResidentPhoto .fb-mark-stripe { left:0; right:0; top:0; bottom:0; height:auto; border-radius:50%; pointer-events:none; z-index:3; transition:border-color .25s ease, box-shadow .25s ease; } + #fbResidentPhoto .fb-mark-stripe { left:0; right:0; top:0; bottom:0; height:auto; border-radius:50%; pointer-events:none; z-index:3; display:flex; align-items:center; justify-content:center; overflow:hidden; transition:border-color .25s ease, box-shadow .25s ease; } + #fbResidentPhoto .fb-mark-stripe img { width:100%; height:100%; object-fit:cover; display:block; border-radius:50%; } .fb-mark-stripe[hidden] { display:none; } .fb-card-resident { display:flex; align-items:center; gap:10px; min-width:0; } .fb-card-meta { display:flex; align-items:center; gap:8px; flex-wrap:wrap; min-width:0; } @@ -59,6 +60,7 @@ #fbResidentPhoto[hidden] { display:none; } .fb-resident-photo { width:34px; height:34px; flex:none; border-radius:50%; overflow:hidden; border:1px solid var(--border); background:var(--bg); cursor:pointer; display:inline-flex; align-items:center; justify-content:center; } .fb-resident-photo img { width:100%; height:100%; object-fit:cover; display:block; } + #fbResidentPhoto .fb-mark-stripe img { width:100%; height:100%; object-fit:cover; display:block; border-radius:50%; } #fbPromptModal { overflow:auto; align-items:flex-start; padding:4vh 16px; } #fbPromptModal > .edit-modal { margin:auto; } #fbQuickModal { z-index:105; } @@ -162,7 +164,7 @@
- + diff --git a/public/js/feedback.js b/public/js/feedback.js index c915de7..ccf0e73 100644 --- a/public/js/feedback.js +++ b/public/js/feedback.js @@ -718,15 +718,13 @@ const m = k ? workMarks.get(k) : null; const photo = document.getElementById('fbResidentPhoto'); if (!m) { - el.hidden = true; - el.style.border = ''; - el.style.boxShadow = ''; + el.style.border = '3px solid transparent'; + el.style.boxShadow = 'none'; if (photo) photo.title = 'Увеличить фото'; return; } const t = Math.max(-4, Math.min(4, m.total)); const hue = Math.round(120 * (t + 4) / 8); - el.hidden = false; el.style.border = `3px solid hsl(${hue}, 72%, 45%)`; el.style.boxShadow = `inset 0 0 10px hsla(${hue}, 72%, 45%, .4)`; if (photo) photo.title = `Отметки работы: ${m.total > 0 ? '+' : ''}${m.total} (отметок: ${m.marks})`;