Skip to content

Commit 06bcbd6

Browse files
committed
Make sure the popovers are scrollable
1 parent 4468faf commit 06bcbd6

1 file changed

Lines changed: 15 additions & 0 deletions

File tree

css/app.scss

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1965,6 +1965,21 @@ body {
19651965
--bs-toast-bg: var(--bs-body-bg);
19661966
--bs-toast-header-bg: var(--bs-body-bg);
19671967
}
1968+
// The container is fixed to the viewport, so a long log has to scroll inside the toast rather than grow
1969+
// past the bottom of the screen where nothing can reach it. Column flex leaves the header (and its
1970+
// close button) at its natural height and gives the rest to the body.
1971+
.notifications-container .toast:has(> .toast-header) {
1972+
display: flex;
1973+
flex-direction: column;
1974+
max-height: calc(100dvh - 2rem); // container's p-3
1975+
}
1976+
// details is worker-produced HTML injected via innerHTML: only <span style> survives cleanupOutput()'s
1977+
// sanitizer, and `contain` neutralises a crafted style trying to overlay the page via position:fixed.
1978+
// Same reasoning as .update-history-log.
1979+
.notifications-container .toast-body {
1980+
overflow-y: auto;
1981+
contain: layout paint style;
1982+
}
19681983
.notifications-container .toast-body pre {
19691984
margin: 10px -12px -12px;
19701985
padding: 12px;

0 commit comments

Comments
 (0)