Skip to content

Commit

Permalink
Merge pull request #3447 from jrochkind/dialog_modal_scroll
Browse files Browse the repository at this point in the history
Fix scrolling of longer-than-viewport bootstrap modal in a <dialog>
  • Loading branch information
jrochkind authored Dec 5, 2024
2 parents 49aba4c + 8b8874b commit 391979b
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion app/assets/stylesheets/blacklight/_bootstrap_overrides.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,16 @@
white-space: nowrap;
}

.modal[open] {
// Blacklight's decision to try to use bootstrap modal CSS with an html5 dialog --
// in such a way the <dialog> element actually serves as the modal backdrop --
// requires some fixes to both bootstrap CSS and user-agent default css
dialog.modal[open] {
// override bootstrap .modal class default display: none
// since we aren't using bootstrap JS that sets and unsets the display
display: block;
background: none;
border: none;

max-height: unset; // override user-agent dialog
max-width: unset; // override user-agent dialog
}

0 comments on commit 391979b

Please sign in to comment.