source: tanzpartie-hugo/themes/bilberry-hugo-theme/layouts/partials/twitter-card.html @ 17727

Last change on this file since 17727 was 16971, checked in by Henrik Bettermann, 2 years ago
File size: 2.0 KB
RevLine 
[16971]1{{ with .Params.twitter }}
2    <meta name="twitter:card" content="{{- .card -}}">
3    <meta name="twitter:site" content="{{- .site -}}">
4    {{ if ne .card "app" -}}
5    <meta name="twitter:title" content="{{- .title -}}">
6    <meta name="twitter:image" content="{{- .image -}}">
7    {{ with .image_alt -}}<meta name="twitter:image:alt" content="{{- . -}}">{{- end }}
8    {{- end }}
9    {{ with .creator -}}<meta name="twitter:creator" content="{{- . -}}">{{- end }}
10
11    {{- if eq .card "app" }}
12    {{ with .app_country }}<meta name="twitter:app:country" content="{{- . -}}">{{ end }}
13    {{ with .app_name_iphone }}<meta name="twitter:app:name:iphone" content="{{- . -}}">{{ end }}
14    {{ with .app_id_iphone }}<meta name="twitter:app:id:iphone" content="{{- . -}}">{{ end }}
15    {{ with .app_url_iphone }}<meta name="twitter:app:url:iphone" content="{{- . -}}">{{ end }}
16    {{ with .app_name_ipad }}<meta name="twitter:app:name:ipad" content="{{- . -}}">{{ end }}
17    {{ with .app_id_ipad }}<meta name="twitter:app:id:ipad" content="{{- . -}}">{{ end }}
18    {{ with .app_url_ipad }}<meta name="twitter:app:url:ipad" content="{{- . -}}">{{ end }}
19    {{ with .app_name_googleplay }}<meta name="twitter:app:name:googleplay" content="{{- . -}}">{{ end }}
20    {{ with .app_id_googleplay }}<meta name="twitter:app:id:googleplay" content="{{- . -}}">{{ end }}
21    {{ with .app_url_googleplay }}<meta name="twitter:app:url:googleplay" content="{{- . -}}">{{ end }}
22    {{- end }}
23
24    {{- if eq .card "player" }}
25    {{ with .player }}<meta name="twitter:player" content="{{- . -}}">{{ end }}
26    {{ with .player_width }}<meta name="twitter:player:width" content="{{- . -}}">{{ end }}
27    {{ with .player_height }}<meta name="twitter:player:height" content="{{- . -}}">{{ end }}
28    {{ with .player_stream }}<meta name="twitter:player:stream" content="{{- . -}}">{{ end }}
29    {{ with .player_stream_content_type }}<meta name="twitter:player:stream:content_type" content="{{- . -}}">{{ end }}
30    {{- end }}
31{{ end }}
Note: See TracBrowser for help on using the repository browser.