mirror of
https://github.com/wukko/cobalt.git
synced 2025-01-23 19:26:26 +01:00
web/PageNav: add a prop for enabling content padding
This commit is contained in:
parent
56008676f5
commit
7e8ae2ca61
1 changed files with 10 additions and 0 deletions
|
@ -12,6 +12,7 @@
|
||||||
export let homeDesktopPath: string;
|
export let homeDesktopPath: string;
|
||||||
export let homeTitle: string;
|
export let homeTitle: string;
|
||||||
export let pageSubtitle = "";
|
export let pageSubtitle = "";
|
||||||
|
export let contentPadding = false;
|
||||||
|
|
||||||
let screenWidth: number;
|
let screenWidth: number;
|
||||||
|
|
||||||
|
@ -91,6 +92,7 @@
|
||||||
<main
|
<main
|
||||||
id="{pageName}-page-content"
|
id="{pageName}-page-content"
|
||||||
class="subnav-page-content"
|
class="subnav-page-content"
|
||||||
|
class:padding={contentPadding}
|
||||||
tabindex="-1"
|
tabindex="-1"
|
||||||
data-first-focus
|
data-first-focus
|
||||||
data-focus-ring-hidden
|
data-focus-ring-hidden
|
||||||
|
@ -122,6 +124,10 @@
|
||||||
overflow-y: scroll;
|
overflow-y: scroll;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.subnav-page-content.padding {
|
||||||
|
padding: var(--subnav-padding);
|
||||||
|
}
|
||||||
|
|
||||||
.subnav-sidebar,
|
.subnav-sidebar,
|
||||||
.subnav-navigation {
|
.subnav-navigation {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
@ -207,6 +213,10 @@
|
||||||
max-width: unset;
|
max-width: unset;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.subnav-page-content.padding {
|
||||||
|
padding: var(--padding);
|
||||||
|
}
|
||||||
|
|
||||||
.subnav-header {
|
.subnav-header {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|
Loading…
Reference in a new issue