From 2941f5330da52ba05ff5d234e7ea883751d6d22a Mon Sep 17 00:00:00 2001 From: Mirco Wittrien Date: Sat, 25 Feb 2023 14:14:37 +0100 Subject: [PATCH] stuff --- Library/_res/0BDFDB.data.json | 14 +++++++++----- Plugins/ImageUtilities/ImageUtilities.plugin.js | 11 +++++++---- 2 files changed, 16 insertions(+), 9 deletions(-) diff --git a/Library/_res/0BDFDB.data.json b/Library/_res/0BDFDB.data.json index d4febfa8db..e662708a73 100644 --- a/Library/_res/0BDFDB.data.json +++ b/Library/_res/0BDFDB.data.json @@ -1341,6 +1341,12 @@ "userPopoutNote": "note-6O4w9y", "voiceDraggable": "draggable-1KoBzC" }, + "ModalCarousel": { + "carouselModal": "carouselModal-1eUFoq", + "nav": "nav-3QIE8_", + "navNext": "navNext-1mR5ku nav-3QIE8_", + "navPrev": "navPrev-1L-o1J nav-3QIE8_" + }, "Toast": { "avatar": "avatar-3xmbmC", "bar": "bar-95Sdw1", @@ -1479,7 +1485,6 @@ "IconDirection": {"props": ["directionDown", "directionUp"]}, "ImageAssets": {"props": ["pngImage", "stickerAsset"]}, "ImageModal": {"props": ["image", "modal"], "length": 4, "smaller": true}, - "ImageModalNavigation": {"props": ["nav", "navPrev", "navNext"]}, "ImageMosaic": {"props": ["lazyImg", "oneByOneGridSingle"]}, "ImageWrapper": {"props": ["clickable", "imageWrapperBackground"]}, "Input": {"props": ["inputMini", "inputDefault"]}, @@ -1526,7 +1531,6 @@ "MessageToolbar": {"props": ["container", "icon", "isHeader"]}, "MessageToolbarItems": {"props": ["wrapper", "button", "separator"]}, "Modal": {"props": ["root", "small", "medium"]}, - "ModalCarousel": {"props": ["carouselModal", "carousel"]}, "ModalCarouselWrapper": {"props": ["modalCarouselWrapper", "zoomedCarouselModalRoot"]}, "ModalDivider": {"props": ["divider"], "length": 1}, "ModalItems": {"props": ["guildName", "checkboxContainer"]}, @@ -2529,9 +2533,9 @@ "imageplaceholderoverlay": ["ImageWrapper", "imagePlaceholderOverlay"], "imagemodal": ["ImageModal", "modal"], "imagemodalimage": ["ImageModal", "image"], - "imagemodalnavbutton": ["ImageModalNavigation", "nav"], - "imagemodalnavbuttonprev": ["ImageModalNavigation", "navPrev"], - "imagemodalnavbuttonnext": ["ImageModalNavigation", "navNext"], + "imagemodalnavbutton": ["ModalCarousel", "nav"], + "imagemodalnavbuttonprev": ["ModalCarousel", "navPrev"], + "imagemodalnavbuttonnext": ["ModalCarousel", "navNext"], "imagemosaicattachmentscontainer": ["ImageMosaic", "mediaAttachmentsContainer"], "imagemosaiconebyonegridsingle": ["ImageMosaic", "oneByOneGridSingle"], "imagesticker": ["ImageAssets", "stickerAsset"], diff --git a/Plugins/ImageUtilities/ImageUtilities.plugin.js b/Plugins/ImageUtilities/ImageUtilities.plugin.js index 5527460320..4c6de06b50 100644 --- a/Plugins/ImageUtilities/ImageUtilities.plugin.js +++ b/Plugins/ImageUtilities/ImageUtilities.plugin.js @@ -2,7 +2,7 @@ * @name ImageUtilities * @author DevilBro * @authorId 278543574059057154 - * @version 5.1.5 + * @version 5.1.6 * @description Adds several Utilities for Images/Videos (Gallery, Download, Reverse Search, Zoom, Copy, etc.) * @invite Jx3TjNS * @donate https://www.paypal.me/MircoWittrien @@ -316,12 +316,15 @@ module.exports = (_ => { ${BDFDB.dotCN._imageutilitiesimagedetails} > span { max-width: 100px; } - ${BDFDB.dotCN._imageutilitiesgallery}, - ${BDFDB.dotCN._imageutilitiesdetailsadded} { + ${BDFDB.dotCNS._imageutilitiesgallery + BDFDB.dotCN.modal}, + ${BDFDB.dotCNS._imageutilitiesdetailsadded + BDFDB.dotCN.modal} { transform: unset !important; filter: unset !important; backdrop-filter: unset !important; } + ${BDFDB.dotCN._imageutilitiesgallery} ~ ${BDFDB.dotCN.imagemodalnavbutton} { + display: none; + } ${BDFDB.dotCNS.imagemodal + BDFDB.notCN._imageutilitiessibling} > ${BDFDB.dotCN.imagewrapper} { display: flex; justify-content: center; @@ -1205,7 +1208,7 @@ module.exports = (_ => { BDFDB.TimeUtils.clear(viewedImageTimeout); let modal = BDFDB.DOMUtils.getParent(BDFDB.dotCN.modal, e.node); if (modal) { - modal.className = BDFDB.DOMUtils.formatClassName(modal.className, this.settings.viewerSettings.galleryMode && BDFDB.disCN._imageutilitiesgallery, this.settings.viewerSettings.details && BDFDB.disCN._imageutilitiesdetailsadded); + modal.parentElement.className = BDFDB.DOMUtils.formatClassName(modal.parentElement.className, this.settings.viewerSettings.galleryMode && BDFDB.disCN._imageutilitiesgallery, this.settings.viewerSettings.details && BDFDB.disCN._imageutilitiesdetailsadded); if (this.settings.viewerSettings.galleryMode) { BDFDB.DOMUtils.addClass(modal, BDFDB.disCN.imagemodal); BDFDB.DOMUtils.removeClass(modal, BDFDB.disCN.modalcarouselmodal, BDFDB.disCN.modalcarouselmodalzoomed);