From 65b151c63d8cf1ff1c144d6ff9bf55cda67326c3 Mon Sep 17 00:00:00 2001 From: daudix Date: Sun, 31 Mar 2024 00:10:28 +0300 Subject: [PATCH] Fix images with transparent class having shadow on hover --- sass/_media.scss | 32 ++++++++++++++++++-------------- 1 file changed, 18 insertions(+), 14 deletions(-) diff --git a/sass/_media.scss b/sass/_media.scss index 01a80a1..1976442 100644 --- a/sass/_media.scss +++ b/sass/_media.scss @@ -1,3 +1,17 @@ +img { + transition: var(--transition-longer); + + &:not(.no-hover) { + cursor: zoom-in; + } + + &:not(.no-hover):hover { + border-radius: 0; + box-shadow: var(--shadow-raised); + transform: scale(1.1); + } +} + img, video { border-radius: var(--rounded-corner); @@ -17,19 +31,9 @@ video { &.transparent { border-radius: 0; box-shadow: none; - } -} - -img { - transition: var(--transition-longer); - - &:not(.no-hover) { - cursor: zoom-in; - } - - &:not(.no-hover):hover { - border-radius: 0; - box-shadow: var(--shadow-raised); - transform: scale(1.1); + + &:hover { + box-shadow: none; + } } }