desktop-expanded-image > expanded-image

master
Aevann 2023-10-02 06:12:06 +03:00
parent 78d1d742d9
commit 19b8e18db2
8 changed files with 17 additions and 17 deletions

View File

@ -6901,13 +6901,13 @@ div.markdown {
margin-bottom: 0 !important;
}
#desktop-expanded-image {
#expanded-image {
max-width: 90%;
max-height: 100vh;
border: 5px white solid;
}
@media (max-width: 768px) {
#desktop-expanded-image {
#expanded-image {
max-width: 100%;
max-height: 65vh;
}

View File

@ -80,7 +80,7 @@ blockquote {
color: var(--gray-400) !important
}
#frontpage div#expandImageModal.modal.desktop-expanded-image-modal {
#frontpage div#expandImageModal.modal.expanded-image-modal {
background-color: transparent !important;
}

View File

@ -191,16 +191,16 @@ function expandImage(url) {
return;
e.preventDefault();
document.getElementById("desktop-expanded-image").src = '';
document.getElementById("desktop-expanded-image-wrap-link").href = '';
document.getElementById("expanded-image").src = '';
document.getElementById("expanded-image-wrap-link").href = '';
if (!url)
{
url = e.target.dataset.src
if (!url) url = e.target.src
}
document.getElementById("desktop-expanded-image").src = url.replace("200w.webp", "giphy.webp");
document.getElementById("desktop-expanded-image-wrap-link").href = url.replace("200w.webp", "giphy.webp");
document.getElementById("expanded-image").src = url.replace("200w.webp", "giphy.webp");
document.getElementById("expanded-image-wrap-link").href = url.replace("200w.webp", "giphy.webp");
location.hash = 'm-expandImage'
};

View File

@ -74,8 +74,8 @@
<div class="modal" id="m-expandImage" tabindex="-1">
<div class="modal-dialog modal-dialog-centered">
<div class="modal-body text-center p-0">
<a rel="nofollow noopener" target="_blank" id="desktop-expanded-image-wrap-link">
<img loading="lazy" alt="expanded image" class="rounded" id="desktop-expanded-image">
<a rel="nofollow noopener" target="_blank" id="expanded-image-wrap-link">
<img loading="lazy" alt="expanded image" class="rounded" id="expanded-image">
</a>
</div>
</div>

View File

@ -74,8 +74,8 @@
<div class="modal" id="m-expandImage" tabindex="-1">
<div class="modal-dialog modal-dialog-centered">
<div class="modal-body text-center p-0">
<a rel="nofollow noopener" target="_blank" id="desktop-expanded-image-wrap-link">
<img loading="lazy" alt="expanded image" class="rounded" id="desktop-expanded-image">
<a rel="nofollow noopener" target="_blank" id="expanded-image-wrap-link">
<img loading="lazy" alt="expanded image" class="rounded" id="expanded-image">
</a>
</div>
</div>

View File

@ -74,8 +74,8 @@
<div class="modal" id="m-expandImage" tabindex="-1">
<div class="modal-dialog modal-dialog-centered">
<div class="modal-body text-center p-0">
<a rel="nofollow noopener" target="_blank" id="desktop-expanded-image-wrap-link">
<img loading="lazy" alt="expanded image" class="rounded" id="desktop-expanded-image">
<a rel="nofollow noopener" target="_blank" id="expanded-image-wrap-link">
<img loading="lazy" alt="expanded image" class="rounded" id="expanded-image">
</a>
</div>
</div>

View File

@ -74,8 +74,8 @@
<div class="modal" id="m-expandImage" tabindex="-1">
<div class="modal-dialog modal-dialog-centered">
<div class="modal-body text-center p-0">
<a rel="nofollow noopener" target="_blank" id="desktop-expanded-image-wrap-link">
<img loading="lazy" alt="expanded image" class="rounded" id="desktop-expanded-image">
<a rel="nofollow noopener" target="_blank" id="expanded-image-wrap-link">
<img loading="lazy" alt="expanded image" class="rounded" id="expanded-image">
</a>
</div>
</div>

View File

@ -3,8 +3,8 @@
<div class="modal-dialog modal-dialog-centered">
<div class="modal-content" style="background-color: transparent !important; border: none !important;">
<div class="modal-body text-center p-0">
<a rel="nofollow noopener" target="_blank" id="desktop-expanded-image-wrap-link">
<img loading="lazy" alt="expanded image" class="rounded" id="desktop-expanded-image">
<a rel="nofollow noopener" target="_blank" id="expanded-image-wrap-link">
<img loading="lazy" alt="expanded image" class="rounded" id="expanded-image">
</a>
</div>
</div>