Tidy styles for community section

This change enables an opt-in switch to new styles for /community
It is opt-in to enable localizations to migrate to the new page on their
own timeline.
This commit is contained in:
Tim Bannister
2022-02-08 11:09:06 +00:00
parent c67d45de83
commit e993de5dc6
5 changed files with 428 additions and 16 deletions
+8
View File
@@ -92,6 +92,14 @@
<script async src="{{ "js/mermaid.min.js" | relURL }}"></script>
{{ end }}
{{- if eq (lower .Params.cid) "community" -}}
{{- if eq .Params.community_styles_migrated true -}}
<link href="/css/community.css" rel="stylesheet"><!-- legacy styles -->
{{- else -}}
<link href="/css/legacy_community.css" rel="stylesheet">
{{- end -}}
<script defer src="https://platform.twitter.com/widgets.js" charset="utf-8"></script>
{{- end -}}
<script src="{{ "js/script.js" | relURL }}"></script>
{{ with .Params.js }}{{ range (split . ",") }}<script src="{{ (trim . " ") | relURL }}"></script><!-- custom js added -->
{{ end }}{{ else }}<!-- no custom js detected -->{{ end }}