From 82ea89443e9a4517bbaa59bf3a36fab981fbcf6a Mon Sep 17 00:00:00 2001 From: Daniele Tonon Date: Fri, 2 Jun 2023 13:56:48 +0200 Subject: [PATCH] Fix webkit glitches --- static/styles.css | 12 +++++------- static/styles.scss | 12 +++++------- templates/head.html | 2 +- 3 files changed, 11 insertions(+), 15 deletions(-) diff --git a/static/styles.css b/static/styles.css index 37ede3a..6ed58f8 100644 --- a/static/styles.css +++ b/static/styles.css @@ -117,14 +117,14 @@ h1, h2 { display: flex; justify-content: center; align-items: center; - margin: 1rem 0; + padding: 1rem 0; justify-content: left; } @media (max-width: 580px) { .top { display: block; width: 90%; - margin: 1rem auto 1rem auto; + padding: 1rem; font-size: 0.8rem; } } @@ -138,6 +138,8 @@ h1, h2 { .pic-wrapper { max-width: 100%; overflow: hidden; + -webkit-clip-path: url(#svg-shape); + clip-path: url(#svg-shape); } @media (max-width: 580px) { .pic-wrapper { @@ -145,14 +147,10 @@ h1, h2 { } } .pic-wrapper img.pic { + display: block; max-width: 100%; width: 100%; height: auto; - -webkit-clip-path: url(#svg-shape); - -moz-clip-path: url(#svg-shape); - -o-clip-path: url(#svg-shape); - -ms-clip-path: url(#svg-shape); - clip-path: url(#svg-shape); } .container_wrapper { diff --git a/static/styles.scss b/static/styles.scss index 46402e3..585a28e 100644 --- a/static/styles.scss +++ b/static/styles.scss @@ -185,12 +185,12 @@ a { display: flex; justify-content: center; align-items: center; - margin: 1rem 0; + padding: 1rem 0; justify-content: left; @media (max-width: 580px) { display: block; width: 90%; - margin: 1rem auto 1rem auto; + padding: 1rem; font-size: 0.8rem; } span { @@ -203,18 +203,16 @@ a { .pic-wrapper { max-width: 100%; overflow: hidden; + -webkit-clip-path: url(#svg-shape); + clip-path: url(#svg-shape); @media (max-width: 580px) { flex-basis: 40%; } img.pic { + display: block; max-width: 100%; width: 100%; height: auto; - -webkit-clip-path: url(#svg-shape); - -moz-clip-path: url(#svg-shape); - -o-clip-path: url(#svg-shape); - -ms-clip-path: url(#svg-shape); - clip-path: url(#svg-shape); } } diff --git a/templates/head.html b/templates/head.html index d67cd62..05ed147 100644 --- a/templates/head.html +++ b/templates/head.html @@ -63,5 +63,5 @@ {{end}} - +