Skip to content

Commit 20b0073

Browse files
authored
Sticky footer (#841)
1 parent ed6aa8a commit 20b0073

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

src/Elastic.Markdown/Assets/styles.css

+9
Original file line numberDiff line numberDiff line change
@@ -232,3 +232,12 @@
232232
#elastic-nav {
233233
min-height: var(--offset-top);
234234
}
235+
236+
html, body {
237+
height: 100%;
238+
}
239+
240+
body {
241+
display: grid;
242+
grid-template-rows: auto auto 1fr auto;
243+
}

src/Elastic.Markdown/Slices/_Layout.cshtml

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
@functions {
2525
private async Task DefaultLayout()
2626
{
27-
<div class="container grid gap-2 grid-cols-1 md:grid-cols-[calc(var(--spacing)*65)_auto] lg:grid-cols-[calc(var(--spacing)*65)_auto_calc(var(--spacing)*50)] px-6">
27+
<div class="container h-full grid gap-2 grid-cols-1 md:grid-cols-[calc(var(--spacing)*65)_auto] lg:grid-cols-[calc(var(--spacing)*65)_auto_calc(var(--spacing)*50)] px-6">
2828
@await RenderPartialAsync(_PagesNav.Create(Model))
2929
@await RenderPartialAsync(_TableOfContents.Create(Model))
3030
<main id="content-container" class="w-full flex flex-col order-2 relative pb-30 overflow-x-hidden">

0 commit comments

Comments
 (0)