mirror of
				https://gitlab.crans.org/bde/nk20
				synced 2025-11-04 01:12:08 +01:00 
			
		
		
		
	bootstrap: fix minor issues with profile picture cropping
* Add required [1] "display: block;" style property to img element * Fix image overflow in modal. As cropper size inherits from img's parent element [2] (including padding according to my research), we need to wrap modal body into another div that has the padding we want. * Remove ability [3] to click away to dismiss the modal as it often interfered with user interaction when cropping. [1] https://github.com/fengyuanchen/cropperjs/tree/v1?tab=readme-ov-file#example [2] https://github.com/fengyuanchen/cropperjs/tree/v1?tab=readme-ov-file#notes [3] https://getbootstrap.com/docs/4.0/components/modal/#options See merge request bde/nk20!301
This commit is contained in:
		@@ -20,12 +20,14 @@ SPDX-License-Identifier: GPL-3.0-or-later
 | 
			
		||||
      </form>
 | 
			
		||||
    </div>
 | 
			
		||||
    <!-- MODAL TO CROP THE IMAGE -->
 | 
			
		||||
    <div class="modal fade" id="modalCrop">
 | 
			
		||||
    <div class="modal fade" id="modalCrop" data-backdrop="static">
 | 
			
		||||
      <div class="modal-dialog">
 | 
			
		||||
        <div class="modal-content">
 | 
			
		||||
          <div class="modal-body">
 | 
			
		||||
            <img src="" id="modal-image" style="max-width: 100%;">
 | 
			
		||||
          </div>
 | 
			
		||||
            <div class="modal-body-wrapper" style="width: 500px; height: 500px; padding: 16px;">
 | 
			
		||||
              <div class="modal-body" style="width: 100%; height: 100%; padding: 0">
 | 
			
		||||
                <img src="" id="modal-image" style="display: block; max-width: 100%;">
 | 
			
		||||
              </div>
 | 
			
		||||
            </div>
 | 
			
		||||
          <div class="modal-footer">
 | 
			
		||||
            <div class="btn-group pull-left" role="group">
 | 
			
		||||
              <button type="button" class="btn btn-default" id="js-zoom-in">
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user