cover.relative -> cover.absolute
This commit is contained in:
parent
2e900af85d
commit
c948d475fd
|
@ -3,7 +3,7 @@
|
||||||
<meta property="og:type" content="{{ if .IsPage }}article{{ else }}website{{ end }}" />
|
<meta property="og:type" content="{{ if .IsPage }}article{{ else }}website{{ end }}" />
|
||||||
<meta property="og:url" content="{{ .Permalink }}" />
|
<meta property="og:url" content="{{ .Permalink }}" />
|
||||||
{{- if .Params.cover.image -}}
|
{{- if .Params.cover.image -}}
|
||||||
{{- if (ne .Params.cover.relative true) }}
|
{{- if (eq .Params.cover.absolute true) }}
|
||||||
<meta property="og:image" content="{{ .Params.cover.image | absURL }}" />
|
<meta property="og:image" content="{{ .Params.cover.image | absURL }}" />
|
||||||
{{- else}}
|
{{- else}}
|
||||||
<meta property="og:image" content="{{ (path.Join .RelPermalink .Params.cover.image ) | absURL }}" />
|
<meta property="og:image" content="{{ (path.Join .RelPermalink .Params.cover.image ) | absURL }}" />
|
||||||
|
|
|
@ -75,7 +75,7 @@
|
||||||
"inLanguage": {{ .Language.Lang | default "en-us" }},
|
"inLanguage": {{ .Language.Lang | default "en-us" }},
|
||||||
{{ if .Params.cover.image -}}
|
{{ if .Params.cover.image -}}
|
||||||
"image":
|
"image":
|
||||||
{{- if (ne .Params.cover.relative true) -}}
|
{{- if (eq .Params.cover.absolute true) }}
|
||||||
{{ .Params.cover.image | absURL }},
|
{{ .Params.cover.image | absURL }},
|
||||||
{{- else -}}
|
{{- else -}}
|
||||||
{{ (path.Join .RelPermalink .Params.cover.image ) | absURL }},
|
{{ (path.Join .RelPermalink .Params.cover.image ) | absURL }},
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{{- if .Params.cover.image -}}
|
{{- if .Params.cover.image -}}
|
||||||
<meta name="twitter:card" content="summary_large_image" />
|
<meta name="twitter:card" content="summary_large_image" />
|
||||||
{{- if (ne $.Params.cover.relative true) }}
|
{{- if (eq .Params.cover.absolute true) }}
|
||||||
<meta name="twitter:image" content="{{ .Params.cover.image | absURL }}" />
|
<meta name="twitter:image" content="{{ .Params.cover.image | absURL }}" />
|
||||||
{{- else }}
|
{{- else }}
|
||||||
<meta name="twitter:image" content="{{ (path.Join .RelPermalink .Params.cover.image ) | absURL }}" />
|
<meta name="twitter:image" content="{{ (path.Join .RelPermalink .Params.cover.image ) | absURL }}" />
|
||||||
|
|
Loading…
Reference in New Issue