From 9b2c3e8497e95cef130e0032d404d0efa603c289 Mon Sep 17 00:00:00 2001 From: Rob Paisley Date: Mon, 7 Oct 2024 14:06:15 -0400 Subject: [PATCH] feat: support disabling animations --- assets/scss/style.scss | 2 ++ hugo.toml.example | 1 + layouts/404.html | 2 +- layouts/_default/list.html | 2 +- layouts/_default/single.html | 2 +- layouts/index.html | 2 +- layouts/partials/footer.html | 2 +- layouts/partials/header.html | 4 ++-- layouts/partials/social-share.html | 2 +- layouts/posts/single.html | 2 +- 10 files changed, 12 insertions(+), 9 deletions(-) diff --git a/assets/scss/style.scss b/assets/scss/style.scss index 07c7a7f..35a8123 100644 --- a/assets/scss/style.scss +++ b/assets/scss/style.scss @@ -1,7 +1,9 @@ @import "predefined.scss"; @import "normalize.scss"; @import "syntax.scss"; +{{ if ne false .Site.Params.usesAnimation }} @import "animate.scss"; +{{ end }} @import "scroll.scss"; @import "socialshare.scss"; {{ if (fileExists "assets/scss/userstyles.scss") }} diff --git a/hugo.toml.example b/hugo.toml.example index cb97a63..cbfa8fc 100644 --- a/hugo.toml.example +++ b/hugo.toml.example @@ -119,6 +119,7 @@ expiryDate = ["expiryDate"] # allowRobots = "index, follow" # siteNoIndex = false # noIndexPages = ["404 Page not found"] + # usesAnimation = true # Defaults to true [[params.socialLinks]] diff --git a/layouts/404.html b/layouts/404.html index 60c4ad0..9fbeae3 100644 --- a/layouts/404.html +++ b/layouts/404.html @@ -1,5 +1,5 @@ {{ define "main" }} -
+

{{- partial "svg.html" (dict "context" . "name" "404-lighthouse") -}}