mirror of
https://github.com/nunocoracao/blowfish.git
synced 2026-01-30 16:31:52 +01:00
Merge pull request #2654 from ZhenShuo2021/patch
🐛 Fix: multiple small patches
This commit is contained in:
@@ -51,7 +51,7 @@
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
<div class="min-w-0 min-h-0 max-w-prose">
|
||||
<div class="min-w-0 min-h-0 max-w-prose w-full">
|
||||
{{ .Content }}
|
||||
</div>
|
||||
</section>
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
{{ $imgWrapperClasses := "" }}
|
||||
{{ $cardContentClasses := "" }}
|
||||
|
||||
{{ if site.Params.list.showCards }}
|
||||
{{ if .Params.showCards | default site.Params.list.showCards }}
|
||||
{{ $cardClasses = printf "%s overflow-hidden rounded-lg border border-neutral-300 dark:border-neutral-600" $cardClasses }}
|
||||
{{ $imgWrapperClasses = "" }}
|
||||
{{ $cardContentClasses = printf "%s p-4" $cardContentClasses }}
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
{{ if $authorImage }}
|
||||
{{ $final := $authorImage }}
|
||||
{{ $squareImage := $authorImage }}
|
||||
{{ if not $disableImageOptimization }}
|
||||
{{ if not (or $disableImageOptimization (eq $authorImage.MediaType.SubType "svg")) }}
|
||||
{{ $final = $authorImage.Fill "192x192" }}
|
||||
{{ $shortSide := int (math.Min $authorImage.Width $authorImage.Height) }}
|
||||
{{ $squareImage = $authorImage.Crop (printf "%dx%d" $shortSide $shortSide ) }}
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
{{ if $authorImage }}
|
||||
{{ $final := $authorImage }}
|
||||
{{ $squareImage := $authorImage }}
|
||||
{{ if not $disableImageOptimization }}
|
||||
{{ if not (or $disableImageOptimization (eq $authorImage.MediaType.SubType "svg")) }}
|
||||
{{ $final = $authorImage.Fill "192x192" }}
|
||||
{{ $shortSide := int (math.Min $authorImage.Width $authorImage.Height) }}
|
||||
{{ $squareImage = $authorImage.Crop (printf "%dx%d" $shortSide $shortSide ) }}
|
||||
|
||||
@@ -99,7 +99,7 @@
|
||||
{{/* CSS */}}
|
||||
{{ $cssResources := slice }}
|
||||
{{ $schemeName := .Site.Params.colorScheme | default "blowfish" }}
|
||||
{{ $cssScheme := resources.Get (printf "css/schemes/%s.css" $schemeName) | default (resources.Get "css/schemes/blowfish.css") }}
|
||||
{{ $cssScheme := resources.Get (printf "css/schemes/%s.css" (lower $schemeName)) | default (resources.Get "css/schemes/blowfish.css") }}
|
||||
{{ $cssResources = $cssResources | append $cssScheme }}
|
||||
{{ $cssResources = $cssResources | append (resources.Get "css/compiled/main.css") }}
|
||||
{{ with resources.Get "css/custom.css" }}
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
{{ if $authorImage }}
|
||||
{{ $final := $authorImage }}
|
||||
{{ $squareImage := $authorImage }}
|
||||
{{ if not $disableImageOptimization }}
|
||||
{{ if not (or $disableImageOptimization (eq $authorImage.MediaType.SubType "svg")) }}
|
||||
{{ $final = $authorImage.Fill (print "288x288 q" ( $.Site.Params.Author.imagequality | default "96" )) }}
|
||||
{{ $shortSide := int (math.Min $authorImage.Width $authorImage.Height) }}
|
||||
{{ $squareImage = $authorImage.Crop (printf "%dx%d" $shortSide $shortSide ) }}
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
{{ if $authorImage }}
|
||||
{{ $final := $authorImage }}
|
||||
{{ $squareImage := $authorImage }}
|
||||
{{ if not $disableImageOptimization }}
|
||||
{{ if not (or $disableImageOptimization (eq $authorImage.MediaType.SubType "svg")) }}
|
||||
{{ $final = $authorImage.Fill (print "288x288 q" ( $.Site.Params.Author.imagequality | default "96" )) }}
|
||||
{{ $shortSide := int (math.Min $authorImage.Width $authorImage.Height) }}
|
||||
{{ $squareImage = $authorImage.Crop (printf "%dx%d" $shortSide $shortSide ) }}
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
{{ if $authorImage }}
|
||||
{{ $final := $authorImage }}
|
||||
{{ $squareImage := $authorImage }}
|
||||
{{ if not $disableImageOptimization }}
|
||||
{{ if not (or $disableImageOptimization (eq $authorImage.MediaType.SubType "svg")) }}
|
||||
{{ $final = $authorImage.Fill (print "288x288 q" ( $.Site.Params.Author.imagequality | default "96" )) }}
|
||||
{{ $shortSide := int (math.Min $authorImage.Width $authorImage.Height) }}
|
||||
{{ $squareImage = $authorImage.Crop (printf "%dx%d" $shortSide $shortSide ) }}
|
||||
|
||||
@@ -25,7 +25,6 @@
|
||||
"name": "{{ .Title | safeJS }}",
|
||||
"headline": "{{ .Title | safeJS }}",
|
||||
{{ with .Description }}"description": "{{ . | safeJS }}",{{ end }}
|
||||
{{ with .Summary }}"abstract": "{{ . | safeJS }}",{{ end }}
|
||||
{{ with .Site.LanguageCode }}"inLanguage": "{{ . }}",{{ end }}
|
||||
"url" : {{ .Permalink }},
|
||||
"author" : {
|
||||
@@ -49,22 +48,25 @@
|
||||
"@context": "https://schema.org",
|
||||
"@type": "BreadcrumbList",
|
||||
"itemListElement": [
|
||||
{{- $breadcrumbs := slice -}}
|
||||
{{- $position := 0 -}}
|
||||
{{- range .Ancestors -}}
|
||||
{{- if not .IsHome -}}
|
||||
{{- $breadcrumbs = $breadcrumbs | append . -}}
|
||||
{{- $position = add $position 1 -}}
|
||||
{
|
||||
"@type": "ListItem",
|
||||
"position": {{ $position }},
|
||||
"name": "{{ .Title }}",
|
||||
"item": {{ .Permalink }}
|
||||
},
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- $breadcrumbs = $breadcrumbs | append . -}}
|
||||
|
||||
{{- range $index, $element := $breadcrumbs -}}
|
||||
{
|
||||
"@type": "ListItem",
|
||||
"position": {{ add $index 1 }},
|
||||
"name": "{{ .Title }}",
|
||||
"item": {{ .Permalink }},
|
||||
}{{ if ne (add $index 1) (len $breadcrumbs) }},{{ end }}
|
||||
{{- end -}}
|
||||
{{- $position = add $position 1 -}}
|
||||
{
|
||||
"@type": "ListItem",
|
||||
"position": {{ $position }},
|
||||
"name": "{{ .Title }}",
|
||||
"item": {{ .Permalink }}
|
||||
}
|
||||
]
|
||||
}{{ end }}]
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user