From c3a4993335f8881989eb49e4efea6a3c1310061d Mon Sep 17 00:00:00 2001 From: Alexis Colin Date: Sat, 23 Dec 2023 12:07:23 +0100 Subject: [PATCH] style: increase doc body max width (#1485) Increase documentation website body `max-width` in order to improve the render on large screen but keeping the main column width under the recommended `max-width` for staying comfortable to read (UX).
Contributors' checklist... - [ ] Added new tests, or not needed, or not feasible - [ ] Provided an example (e.g. screenshot) to aid review or the PR is self-explanatory - [ ] Updated the official documentation or not needed - [ ] No breaking changes were made, or a `BREAKING CHANGE: xxx` message was included in the description - [ ] Added references to related issues and PRs - [ ] Provided any useful hints for running manual tests - [ ] Added new benchmarks to [generated graphs](https://gnoland.github.io/benchmarks), if any. More info [here](https://github.com/gnolang/gno/blob/master/.benchmarks/README.md).
--- misc/docusaurus/src/css/custom.css | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/misc/docusaurus/src/css/custom.css b/misc/docusaurus/src/css/custom.css index 58afeea4a35..feee9badf9d 100644 --- a/misc/docusaurus/src/css/custom.css +++ b/misc/docusaurus/src/css/custom.css @@ -35,6 +35,8 @@ --ifm-links-hover-background-color: var(--ifm-color-primary-light); --ifm-color-secondary: var(--ifm-color-primary-light); --ifm-color-white: var(--ifm-color-primary); + + --content-max-w: 50rem; } /* For readability concerns, you should choose a lighter palette in dark mode. */ @@ -61,7 +63,7 @@ body { margin-left: auto; margin-right: auto; - max-width: 84rem; + max-width: 100rem; padding-inline: 1rem; } @@ -114,6 +116,10 @@ pre code { } } +.theme-doc-markdown { + max-width: var(--content-max-w, 700px); +} + .navbar-sidebar--show ~ .main-wrapper { filter: blur(2px); } @@ -126,6 +132,7 @@ pre code { .pagination-nav { grid-template-columns: repeat(1, 100%); grid-template-rows: repeat(2, 1fr); + max-width: var(--content-max-w, 700px); } .pagination-nav__link--next { grid-column: 1/2;