Skip to content

Commit abc70d2

Browse files
authored
Merge pull request #3 from gracegrimwood/issue-31-scroll-margin-fix
fix sticky header collapse, add scroll margin to content
2 parents cecae3d + cab7ed9 commit abc70d2

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

_layouts/default.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010
<script src="https://cdnjs.cloudflare.com/ajax/libs/bootstrap/5.3.2/js/bootstrap.bundle.min.js" integrity="sha512-X/YkDZyjTf4wyc2Vy16YGCPHwAY8rZJY+POgokZjQB2mhIRFJCckEGc6YyX9eNsPfn0PzThEuNs+uaomE5CO6A==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
1111
{% seo %}
1212
</head>
13-
<body class="d-flex flex-column vh-100" data-bs-theme="light">
13+
<body class="d-flex flex-column" data-bs-theme="light">
1414
{% include nav.html %}
15-
<div class="container-fluid px-0" data-bs-theme="light">
15+
<div class="container-fluid px-0 krx-content" data-bs-theme="light">
1616
{{ content }}
1717
</div>
1818
{% include footer.html %}

_sass/kroxylicious.scss

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,14 @@ $navbar-dark-disabled-color: rgba($white, 0.45);
3333
// Custom bootstrap variables must be set or imported *before* bootstrap.
3434
@import "./bootstrap/scss/bootstrap";
3535

36+
body {
37+
height: fit-content!important;
38+
}
39+
40+
.krx-content * {
41+
scroll-margin-top: 5rem!important;
42+
}
43+
3644
.list-group-item:hover {
3745
background-color: tint-color($primary, 50%);
3846
}

0 commit comments

Comments
 (0)