From d70d779f32c62f9ca7ca84a96eadb5c71530e1c2 Mon Sep 17 00:00:00 2001 From: Ben Goldsworthy Date: Thu, 20 Feb 2025 01:22:27 +0100 Subject: [PATCH] style: fix chart figures --- assets/css/components/_chart.scss | 7 ++----- assets/css/components/_figure.scss | 5 +++++ 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/assets/css/components/_chart.scss b/assets/css/components/_chart.scss index 2137a19..fa49bd0 100644 --- a/assets/css/components/_chart.scss +++ b/assets/css/components/_chart.scss @@ -1,20 +1,17 @@ .chart-container { position: relative; - margin-inline: auto; - block-size: 100vh; - inline-size: 95vw; + inline-size: 100%; + min-block-size: 50vh; display: flex; justify-content: center; @media (orientation: landscape) { block-size: 75vh; - inline-size: 95vw; } @include mq("large") { block-size: auto; max-block-size: 80vh; - inline-size: 50vw; } & + .chart-container { diff --git a/assets/css/components/_figure.scss b/assets/css/components/_figure.scss index c8bc1a1..5a2d69d 100644 --- a/assets/css/components/_figure.scss +++ b/assets/css/components/_figure.scss @@ -2,6 +2,11 @@ inline-size: fit-content; margin: 16px auto; + &--chart { + margin: 0; + width: 100%; + } + &__caption { block-size: auto; margin: auto;