forge
Explore
Log in

Don't you dare go Hollow

Confirm pops overlay the page instead of scrolling it

Browse files at this commit

1abf2417050fba13afd80c39ec573a4eda74b977Ahmet Kaan GümüşParent: 01ad124
Opening a Rotate/Revoke confirm grew the page: the pop was absolutely
anchored under its button, inside .admin-table-wrap — a scroll container
since it takes the tables' sideways scroll, and a non-visible x-axis
forces the y-axis to auto, so the pop extended that scroll area (the
long page thumb) instead of overlaying the screen.

Port iz's delete-confirm model: the open pop is position:fixed and
viewport-centered, which escapes every overflow ancestor, reads as the
page's one dialog, and is row-agnostic — the first row's pop and the
last row's pop land identically at any width. The im pop keeps its own
compact box and flat shadow. Verified in a browser at 900px and 1400px,
first and last rows: documentElement scrollWidth == clientWidth and
scrollHeight == clientHeight while the pop is open, pop fully inside
the viewport, Revoke unobscured.
style/main.scssmodified+12 -3
@@ -1195,15 +1195,24 @@ body:has(.log-list) {
11951195 }
11961196
11971197 .admin-confirm-pop {
1198- position: absolute;
1199- right: 0;
1200- top: calc(100% + 6px);
1198+ // Viewport-fixed and centered, iz's delete-confirm model: position:fixed
1199+ // escapes every overflow ancestor, and the table wrap is a scroll
1200+ // container (it takes the tables' sideways scroll) — an absolutely
1201+ // anchored pop inside it would grow that scroll area instead of
1202+ // overlaying the page. Centered also reads as the page's one dialog and
1203+ // is row-agnostic: the first row's pop and the last row's pop land the
1204+ // same, at any width.
1205+ position: fixed;
1206+ top: 50%;
1207+ left: 50%;
1208+ transform: translate(-50%, -50%);
12011209 z-index: 30;
12021210 width: 240px;
12031211 padding: 12px;
12041212 background: var(--surface);
12051213 border: 1px solid var(--border-strong);
12061214 border-radius: var(--radius);
1215+ box-shadow: var(--shadow-2);
12071216 display: flex;
12081217 flex-direction: column;
12091218 gap: 8px;