feat(ui): highlight delete targets on hover

This commit is contained in:
Shantur Rathore
2026-02-25 23:08:53 +00:00
parent 57b81f00f8
commit 1122070b9c
4 changed files with 119 additions and 17 deletions

View File

@@ -2,6 +2,7 @@
@import "./messaging/prompt-input.css";
@import "./messaging/message-section.css";
@import "./messaging/message-block-list.css";
@import "./messaging/delete-overlays.css";
@import "./messaging/message-timeline.css";
@import "./messaging/tool-call.css";
@import "./messaging/log-view.css";
@@ -110,4 +111,3 @@
.reasoning-label {
font-weight: var(--font-weight-medium);
}

View File

@@ -0,0 +1,37 @@
/* Hover overlays for destructive actions (delete part / delete message). */
.message-stream-block[data-delete-message-hover="true"] {
position: relative;
}
.message-stream-block[data-delete-message-hover="true"]::before {
content: "";
position: absolute;
inset: -2px;
background: var(--status-error-bg);
box-shadow: inset 0 0 0 1px var(--status-error-fg);
border-radius: 10px;
pointer-events: none;
/* Overlay must sit above the message cards (they have opaque backgrounds). */
z-index: 10;
}
.message-part-shell {
display: block;
}
.delete-hover-scope[data-delete-part-hover="true"] {
position: relative;
}
.delete-hover-scope[data-delete-part-hover="true"]::before {
content: "";
position: absolute;
inset: -2px;
background: var(--status-error-bg);
box-shadow: inset 0 0 0 1px var(--status-error-fg);
border-radius: 10px;
pointer-events: none;
/* Overlay must sit above the part card background. */
z-index: 10;
}