Fix styles

Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr>
This commit is contained in:
Kévin Commaille 2023-12-26 11:29:58 +01:00
parent e732605062
commit 15e4592ae9
No known key found for this signature in database
GPG key ID: 29A48C1F03620416
3 changed files with 27 additions and 16 deletions

View file

@ -18,9 +18,6 @@ limitations under the License.
Custom SCSS for the Matrix spec Custom SCSS for the Matrix spec
*/ */
@import "variables_project";
@import "variables";
/* Import the CSS classes for the syntax highlighter. /* Import the CSS classes for the syntax highlighter.
* *
* This is generated with: * This is generated with:
@ -49,6 +46,10 @@ Custom SCSS for the Matrix spec
} }
.nav-link {
font-weight: normal;
}
a { a {
color: $black; color: $black;
} }
@ -292,7 +293,7 @@ footer {
} }
/* Styles for sections that are rendered from data, such as HTTP APIs and event schemas */ /* Styles for sections that are rendered from data, such as HTTP APIs and event schemas */
.rendered-data { .td-content .rendered-data {
background-color: $secondary-lightest-background; background-color: $secondary-lightest-background;
padding: 0.85rem; padding: 0.85rem;
margin: 0.85rem 0; margin: 0.85rem 0;
@ -346,7 +347,7 @@ footer {
} }
p code, table code { p code, table code {
background-color: inherit; background-color: transparent;
} }
table { table {
@ -396,6 +397,7 @@ footer {
th, td, caption { th, td, caption {
padding: 1rem; padding: 1rem;
border-top: 1px $table-border-color solid;
} }
&.object-table, &.response-table, &.content-type-table { &.object-table, &.response-table, &.content-type-table {
@ -408,14 +410,12 @@ footer {
// ... but avoid double border between caption and table // ... but avoid double border between caption and table
border-bottom: 0; border-bottom: 0;
background-color: $secondary-lighter-background;
} }
caption, tbody tr { tbody tr {
background-color: $table-row-default; --bs-table-striped-bg: #{$secondary-lighter-background};
}
tbody tr:nth-child(even) {
background-color: $table-row-alternate;
} }
} }
@ -517,3 +517,15 @@ dd {
border-radius: 0.25rem; // was $border-radius, but that var isn't accessible here. border-radius: 0.25rem; // was $border-radius, but that var isn't accessible here.
} }
} }
/* Style for breadcrumbs */
.td-breadcrumbs {
padding: .75rem 1rem;
background-color: #eee;
border-radius: .25rem;
margin-bottom: 1rem;
.breadcrumb {
margin: 0;
}
}

View file

@ -20,7 +20,7 @@ $dark: #333;
$gray-100: #FBFBFB; $gray-100: #FBFBFB;
$secondary-background: #E5F5FB; $secondary-background: #E5F5FB;
$secondary-lighter-background: #F4FaFC; $secondary-lighter-background: #F4FAFC;
$secondary-lightest-background: #FBFDFD; $secondary-lightest-background: #FBFDFD;
@ -33,8 +33,7 @@ $warning-background: #FFE0E0;
// colours for definition tables. // colours for definition tables.
// the border colour matches that used for "highlight" divs // the border colour matches that used for "highlight" divs
$table-border-color: rgba(black, .125); $table-border-color: rgba(black, .125);
$table-row-alternate: $secondary-lightest-background; $table-bg: $secondary-lightest-background;
$table-row-default: $secondary-lighter-background;
/* Configure docsy to use the default system fonts instead of Google Fonts. /* Configure docsy to use the default system fonts instead of Google Fonts.
* See https://www.docsy.dev/docs/adding-content/lookandfeel/#fonts */ * See https://www.docsy.dev/docs/adding-content/lookandfeel/#fonts */

View file

@ -8,8 +8,8 @@
*/}} */}}
{{ if not .IsHome }} {{ if not .IsHome }}
<nav aria-label="breadcrumb" class="d-none d-md-block d-print-none"> <nav aria-label="breadcrumb" class="td-breadcrumbs">
<ol class="breadcrumb spb-1"> <ol class="breadcrumb">
{{ template "breadcrumbnav" (dict "p1" . "p2" .) }} {{ template "breadcrumbnav" (dict "p1" . "p2" .) }}
</ol> </ol>
</nav > </nav >