🐛 fix: hugo minify breaks repo cards

Make all repo cards behave consistently as in #2090
This commit is contained in:
ZhenShuo Leo
2025-05-25 03:59:15 +08:00
parent 1d21656d5e
commit 7c70f27a62
4 changed files with 8 additions and 0 deletions

View File

@@ -4,6 +4,7 @@
{{- $codebergColors := .Site.Data.codebergColors -}}
{{- with $codebergData -}}
<div class="codeberg-card-wrapper">
<a id="{{ $id }}" target="_blank" href="{{ .html_url }}" class="cursor-pointer">
<div
class="w-full md:w-auto pt-3 p-5 border border-neutral-200 dark:border-neutral-700 border rounded-md shadow-2xl">
@@ -64,4 +65,5 @@
.catch(error => console.error(error))
</script>
</a>
</div>
{{- end -}}

View File

@@ -4,6 +4,7 @@
{{- $forgejoColors := .Site.Data.forgejoColors -}}
{{- with $forgejoData -}}
<div class="forgejo-card-wrapper">
<a id="{{ $id }}" target="_blank" href="{{ .html_url }}" class="cursor-pointer">
<div
class="w-full md:w-auto pt-3 p-5 border border-neutral-200 dark:border-neutral-700 border rounded-md shadow-2xl">
@@ -64,4 +65,5 @@
.catch(error => console.error(error))
</script>
</a>
</div>
{{- end -}}

View File

@@ -4,6 +4,7 @@
{{- $giteaColors := .Site.Data.giteaColors -}}
{{- with $giteaData -}}
<div class="gitea-card-wrapper">
<a id="{{ $id }}" target="_blank" href="{{ .html_url }}" class="cursor-pointer">
<div
class="w-full md:w-auto pt-3 p-5 border border-neutral-200 dark:border-neutral-700 border rounded-md shadow-2xl">
@@ -64,4 +65,5 @@
.catch(error => console.error(error))
</script>
</a>
</div>
{{- end -}}

View File

@@ -4,6 +4,7 @@
{{- $gitLabData := resources.GetRemote $gitlabURL | transform.Unmarshal -}}
{{- with $gitLabData -}}
<div class="gitlab-card-wrapper">
<a id="{{ $id }}" target="_blank" href="{{ .web_url }}" class="cursor-pointer">
<div class="w-full md:w-auto pt-3 p-5 border border-neutral-200 dark:border-neutral-700 border rounded-md shadow-2xl">
@@ -54,4 +55,5 @@
.catch(error => console.error(error))
</script>
</a>
</div>
{{- end -}}