word/edit: consistent image height in download popup
authorMischa POSLAWSKY <perl@shiar.org>
Tue, 17 Jan 2023 17:45:52 +0000 (18:45 +0100)
committerMischa POSLAWSKY <perl@shiar.org>
Thu, 9 Feb 2023 17:54:07 +0000 (18:54 +0100)
word/editor.css

index 4a848f58868001f1a7058442c294dbc7eb0f7d78..88a4c49bca3740ec50a2bceba963d6988f244856 100644 (file)
@@ -49,20 +49,26 @@ select {
 .popup {
        display: flex;
        flex-wrap: wrap;
-       align-items: end;
+       justify-content: space-evenly;
+       gap: 1em;
        position: fixed;
        left: 0;
        top: 0;
+       max-width: 100%;
+       max-height: 100%; /* scroll */
        margin: auto;
-       max-height: 90%;
-       max-width: 90%;
        overflow: auto;
        background: rgba(0, 0, 0, .8);
        border: 1px solid #CCC;
+       z-index: 1;
 }
-img.popup {
-       height: 100%; /* max assuming landscape */
-       width: auto; /* keep aspect */
+.popup img {
+       height: 20vh;
+       width: auto;
+}
+img {
+       max-width: 100%;
+       object-fit: contain;
 }
 
 h1 {