Browse Source

set max height on image to prevent tall images from blocking scrolling

closes #87
pull/108/head
Aaron Parecki 5 years ago
parent
commit
510c5a52a8
No known key found for this signature in database GPG Key ID: 276C2817346D6056
1 changed files with 9 additions and 3 deletions
  1. +9
    -3
      views/new-post.php

+ 9
- 3
views/new-post.php View File

@ -142,7 +142,7 @@
<div class="modal-body"> <div class="modal-body">
<div id="modal_photo_preview" class="hidden"> <div id="modal_photo_preview" class="hidden">
<img style="width:100%;">
<img>
</div> </div>
<label id="note_photo_button" class="btn btn-default btn-file" style="margin-bottom: 1em;"> <label id="note_photo_button" class="btn btn-default btn-file" style="margin-bottom: 1em;">
@ -177,7 +177,7 @@
<div class="modal-body"> <div class="modal-body">
<div id="modal_edit_photo_preview" style="margin-bottom: 4px;"> <div id="modal_edit_photo_preview" style="margin-bottom: 4px;">
<img style="width:100%;">
<img>
</div> </div>
<input type="text" id="note_edit_photo_alt" class="form-control" placeholder="Image alt text"> <input type="text" id="note_edit_photo_alt" class="form-control" placeholder="Image alt text">
@ -205,8 +205,14 @@
font-weight: bold; font-weight: bold;
} }
#modal_photo_preview {
text-align: center;
}
#modal_photo_preview img {
max-height: 40vh;
}
#modal_photo_preview img, #modal_edit_photo_preview img { #modal_photo_preview img, #modal_edit_photo_preview img {
width: 100%;
max-width: 100%;
border-radius: 4px; border-radius: 4px;
margin-bottom: 4px; margin-bottom: 4px;
} }

Loading…
Cancel
Save