Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Elastic.ApiExplorer/_Layout.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ else
{
@(await RenderPartialAsync(_IsolatedHeader.Create<GlobalLayoutViewModel>(Model)))
}
<div id="main-container" class="flex flex-col items-center border-t-1 border-grey-20">
<div id="main-container" class="flex flex-col items-center">
<div class="max-w-(--max-layout-width) w-full h-full grid
grid-cols-1
md:grid-cols-[var(--max-sidebar-width)_1fr]
Expand Down
26 changes: 5 additions & 21 deletions src/Elastic.Documentation.Site/Assets/assembler.css
Original file line number Diff line number Diff line change
@@ -1,33 +1,17 @@
/* Assembler build type specific styles */

/* Elastic global nav is position:static (scrolls with page).
The secondary nav (Docs sub-header) is sticky on md+ viewports. */
:root {
/* Assembler uses Elastic global nav with banner - different heights at different breakpoints */
--offset-top: calc(64px + 38px); /* header height + banner height */
--offset-top: 0px;
}

@media screen and (min-width: 767px) {
@media screen and (min-width: 768px) {
:root {
--offset-top: calc(72px + 38px); /* header height + banner height */
--offset-top: calc(var(--spacing) * 18);
}
}

@media screen and (min-width: 992px) {
:root {
--offset-top: 110px;
}
}

@media screen and (min-width: 1180px) {
:root {
--offset-top: calc(80px + 38px); /* header height + banner height */
}
}

/* Elastic nav wrapper and nav styles - assembler specific */
#elastic-nav-wrapper {
min-height: var(--offset-top);
}

/* Air-gapped: uses elastic-docs-header web component instead of elastic nav */
body.air-gapped {
--offset-top: 48px;
Expand Down
4 changes: 2 additions & 2 deletions src/Elastic.Documentation.Site/Layout/_SecondaryNav.cshtml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
@inherits RazorSlice<Elastic.Documentation.Site.GlobalLayoutViewModel>
<div>
<div class="md:sticky md:top-0 md:z-30 bg-grey-10">
<ask-ai></ask-ai>
<nav id="secondary-nav" hx-select-oob="#main-container" hx-swap="none"
class="bg-grey-10 border-grey-20">
class="bg-grey-10 border-b border-grey-20">
<div class="
w-full
max-w-(--max-layout-width) flex mx-auto justify-between items-center
Expand Down
41 changes: 23 additions & 18 deletions src/Elastic.Documentation.Site/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/Elastic.Markdown/_Layout.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
@(await RenderPartialAsync(_IsolatedHeader.Create<GlobalLayoutViewModel>(Model)))
}
}
<div id="main-container" class="@(RenderHeaderAndFooter ? "border-t-1 border-grey-20" : "")">
<div id="main-container">
@switch (Model.Layout)
{
case MarkdownPageLayout.NotFound:
Expand Down
Loading