Kaynağa Gözat

fix: Mermaid and Plotly page overflow

Mermaid and Plotly need to have their max-width constrained or they can overflow page width as they set their own fixed max-width in pixels, which can be wider than the page.

One workaround is to set `grid-template-columns` to `100%`. Another is to set a responsive fixed max-width on their parent elements or article-container.

Fix 1c05374
George Cushen 4 yıl önce
ebeveyn
işleme
d70da89199

+ 1 - 1
wowchemy/assets/js/wowchemy.js

@@ -453,7 +453,7 @@ $(document).ready(function () {
         isDarkTheme = false;
       } else {
         // The visitor does not have a day or night preference, so use the theme's default setting.
-        isDarkTheme = isSiteThemeDark;
+        isDarkTheme = window.wc.isSiteThemeDark;
       }
       renderThemeVariation(isDarkTheme);
     }

+ 1 - 1
wowchemy/assets/scss/wowchemy/_root.scss

@@ -55,7 +55,7 @@ body.no-navbar {
   min-height: calc(100vh - 70px);
   display: grid;
   grid-template-rows: auto 1fr auto;
-  grid-template-columns: auto;
+  grid-template-columns: 100%;
 }
 @include media-breakpoint-down(md) {
   .page-wrapper {