From 32f3ed1aa24d1f9040f180762b59c851bf5f3ebc Mon Sep 17 00:00:00 2001 From: Bryton Hall Date: Thu, 25 May 2023 02:47:16 -0400 Subject: [PATCH] docs: fix module details table overflow --- docs/assets/_custom.scss | 16 +++++++--- docs/layouts/partials/details.html | 50 ++++++++++++++++-------------- 2 files changed, 38 insertions(+), 28 deletions(-) diff --git a/docs/assets/_custom.scss b/docs/assets/_custom.scss index e5618ea..ae4aa72 100644 --- a/docs/assets/_custom.scss +++ b/docs/assets/_custom.scss @@ -21,10 +21,12 @@ details { padding: 0rem 1rem !important; margin: 1rem; padding: 0 !important; + width: 100%; > summary { padding: 0rem !important; margin: 0 !important; + overflow-x: scroll; // do not show arrow bullet point list-style: none; @@ -34,8 +36,6 @@ details { // replace builtin arrows with custom ones pre { - display: inline-block; - width: 100%; margin: 0 !important; padding-left: 42px !important; vertical-align: middle; @@ -49,10 +49,18 @@ details { @include arrow(45deg); } + .table-container { + overflow-x: scroll !important; + } + + table { + display: inline-table !important; + // TODO: no idea where this extra pixel comes from + width: calc(100% - 1px); + } + table, tbody { // fill entire width - width: 100% !important; - display: table; margin: 0 !important; tr { diff --git a/docs/layouts/partials/details.html b/docs/layouts/partials/details.html index f249d1f..1345d56 100644 --- a/docs/layouts/partials/details.html +++ b/docs/layouts/partials/details.html @@ -9,32 +9,34 @@
{{ $name }}
- - - - - +
+
Description{{ $option.description }}
+ + + + - - - - + + + + - - - - + + + + - {{ with $option.example }} - - - - - {{ end }} + {{ with $option.example }} + + + + + {{ end }} - - - - -
Description{{ $option.description }}
Type
{{ $option.type }}
Type
{{ $option.type }}
Default{{ partial "highlight" $option.default }}
Default{{ partial "highlight" $option.default }}
Example{{ partial "highlight" . }}
Example{{ partial "highlight" . }}
Declared in{{ $path }}
+ + Declared in + {{ $path }} + + + \ No newline at end of file