mirror of
https://github.com/Sped0n/bridget.git
synced 2026-04-14 10:09:31 -07:00
refactor: replace svh with a more compatible approach (#252)
* first attempt * second attempt * blind commit
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
@import '_core/mixins';
|
@import '_core/mixins';
|
||||||
|
|
||||||
:root {
|
:root {
|
||||||
--window-height: 100svh;
|
--window-height: 100vh;
|
||||||
--nav-height: 2rem;
|
--nav-height: 2rem;
|
||||||
--space-standard: 0.625rem;
|
--space-standard: 0.625rem;
|
||||||
|
|
||||||
|
|||||||
@@ -18,6 +18,16 @@
|
|||||||
{{- partial "plugin/style.html" $style -}}
|
{{- partial "plugin/style.html" $style -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/* fuck safari */}}
|
||||||
|
<script>
|
||||||
|
function z() {
|
||||||
|
const r = document.querySelector(':root')
|
||||||
|
r.style.setProperty('--window-height', `${window.innerHeight}px`)
|
||||||
|
}
|
||||||
|
z()
|
||||||
|
window.addEventListener('resize', z, { passive: true })
|
||||||
|
</script>
|
||||||
|
|
||||||
{{/* main js */}}
|
{{/* main js */}}
|
||||||
{{- $script := dict "Link" "/bundled/js/main.js" "Defer" true "Esm" true -}}
|
{{- $script := dict "Link" "/bundled/js/main.js" "Defer" true "Esm" true -}}
|
||||||
{{- partial "plugin/script.html" $script -}}
|
{{- partial "plugin/script.html" $script -}}
|
||||||
|
|||||||
Reference in New Issue
Block a user