summaryrefslogtreecommitdiff
path: root/addons/website/static/src/snippets
diff options
context:
space:
mode:
authornie <nie@odoo.com>2020-12-22 09:25:53 +0000
committernie <nie@odoo.com>2020-12-22 09:25:53 +0000
commitb34d27449920cfd683223969fd9d24a19e715d04 (patch)
tree8cc997b3a6baaae904ddedda92b155e5a8c1aea1 /addons/website/static/src/snippets
parent0734bf2b32e7e6843cd85d5e353259d92118470d (diff)
[FIX] website: gallery cover img inside anchor is not well placed
Steps: - Go to "Website" > "Go to Website" - Click Edit - Add an image gallery - Add an image to the gallery - Add the same image to the gallery - Click the first image - Click "Image Cover" in the side panel - Click on the Link button in the bottom-right of the side panel - Add a link and save Bug: The first image is not displayed in the same way as the second one. Explanation: The layout is not carried over to `img` when it's nested into an `a` tag. Redefining the layout on the `a` tag fixes the issue. opw:2394953 closes odoo/odoo#63675 Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Diffstat (limited to 'addons/website/static/src/snippets')
-rw-r--r--addons/website/static/src/snippets/s_image_gallery/001.scss15
1 files changed, 11 insertions, 4 deletions
diff --git a/addons/website/static/src/snippets/s_image_gallery/001.scss b/addons/website/static/src/snippets/s_image_gallery/001.scss
index 5d16381ec7b..b20d0be30f6 100644
--- a/addons/website/static/src/snippets/s_image_gallery/001.scss
+++ b/addons/website/static/src/snippets/s_image_gallery/001.scss
@@ -115,10 +115,17 @@
> .container, > .container-fluid, > .o_container_small {
height: 100%;
}
- &.s_image_gallery_cover .carousel-item > img {
- width: 100%;
- height: 100%;
- object-fit: cover;
+ &.s_image_gallery_cover .carousel-item {
+ > a {
+ width: 100%;
+ height: 100%;
+ }
+ > a > img,
+ > img {
+ width: 100%;
+ height: 100%;
+ object-fit: cover;
+ }
}
&:not(.s_image_gallery_show_indicators) .carousel {
ul.carousel-indicators {