Skip to content
Snippets Groups Projects
Commit 36d4b706 authored by Olivia206's avatar Olivia206
Browse files

added footer layout to search button

parent 594731b9
No related branches found
No related tags found
No related merge requests found
......@@ -148,12 +148,12 @@
padding-top: calc(#{$spacing3} + #{half($spacing0)})
.pagefind-fixed
position: fixed
background: $color-background
bottom: 0
left: $spacing3
z-index: 10
min-width: calc(#{$spacing3} * 3)
position: fixed
z-index: 10
&::after
position: absolute
right: $spacing0
......@@ -162,3 +162,8 @@
width: 100vw
&.in-page-with-toc
bottom: px2rem(44)
.pagefind-footer
padding: 0
margin-bottom: calc(#{$spacing3} + #{half($spacing3)})
......@@ -16,10 +16,12 @@
{{- partial "header/header.html" . -}}
<main{{ if .Params.contents }} class="page-with-blocks"{{ end }} id="main" tabindex="-1">
{{ if and (site.Params.search.active) (eq site.Params.search.position "fixed")}}
<button id="search-button" class="pagefind-ui__toggle pagefind-fixed " aria-expanded="false">
{{- i18n (printf "commons.search.title") -}}
</button>
{{- partial "header/search.html" . -}}
{{ partial "header/search.html"
(dict
"position" "fixed"
"context" .
)
}}
{{ end }}
{{- block "main" . }}{{- end }}
{{- partial "hooks/before-main-end" . -}}
......
......@@ -64,10 +64,12 @@
{{ end -}}
{{ if and (eq $kind "primary") (site.Params.search.active) (eq site.Params.search.position "menu")}}
<button id="search-button" class="pagefind-ui__toggle" aria-expanded="false">
{{- i18n (printf "commons.search.title") -}}
</button>
{{- partial "header/search.html" . -}}
{{ partial "header/search.html"
(dict
"position" "menu"
"context" .
)
}}
{{ end }}
{{ if and (eq $kind "primary") (site.Params.menu.i18n.display) }}
{{ partial "header/i18n.html" . }}
......
......@@ -12,6 +12,14 @@
{{ partial "footer/social.html" }}
</div>
<div class="footer-legals">
{{ if and (site.Params.search.active) (eq site.Params.search.position "footer")}}
{{ partial "header/search.html"
(dict
"position" "footer"
"context" .
)
}}
{{ end }}
{{ partial "footer/legals.html" }}
</div>
</div>
<button id="search-button" class="pagefind-ui__toggle pagefind-{{ .position }}" aria-expanded="false">
{{- i18n (printf "commons.search.title") -}}
</button>
<script src="/pagefind/pagefind-ui.js"></script>
<div id="search" class="search__modal" aria-hidden="true" aria-modal="true" role="dialog">
<button class="search__close" aria-label="{{ i18n "commons.search.close" }}">
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment