Commit Graph

11 Commits

Author SHA1 Message Date
Joe Mooring
87df659c18 [PATCH] tpl/tplimpl: Fix deprecation logic in embedded templates
cherry-picked from cb98e9061b
2023-12-16 19:43:59 +05:30
Joe Mooring
3fb112bc85 [PATCH] tpl/tplimpl: Deprecate .Site.Social usage with internal templates
cherry-picked from 4910312ee7
2023-12-16 19:43:59 +05:30
Razon Yang
102e089bc3 [PATCH] tpl/embedded: Make Open Graph's series optional
cherry-picked from b82b547acb
2023-12-16 19:43:59 +05:30
Joe Mooring
3a0a4811cb
[PATCH] Fix date format in schema and opengraph templates
cherry-picked from 34e4742f0c
2022-09-03 16:29:45 +05:30
Aditya Telange
575cc0ca8c
Use site function instead of .Site or $.Site
- The site function provides global access to the same data as the .Site page method.
- Current context (`.`) is never considered.
2022-03-27 18:44:06 +05:30
Aditya Telange
24e5d82ecb
Update hugo internal templates
Remove .Site.Authors from embedded templates

f6745ad358
2021-05-01 11:32:45 +05:30
Daniel Atwood
772f571161
Update internal tempplate from hugo
cp from ffd9dac4218b8f1709de04f7131ca661715fc481 & fe77f7434bc0d7a9b54af69014eb28dbea2b236b

tpl: Update date logic of opengraph and schema internal
 templates

* Fix: updated date logic in opengraph template

* Updated date logic in schema template

* Reformatted opengraph and schema

* Wrapped PublishDate and Lastmod in with

tpl: Make the build green again

Co-authored-by: =?UTF-8?q?Bj=C3=B8rn=20Erik=20Pedersen?= <bjorn.erik.pedersen@gmail.com>

Signed-off-by: Aditya Telange <21258296+adityatelange@users.noreply.github.com>
2021-03-23 15:45:10 +05:30
Maciej Sawicki
d6b2282582 templates: Fix series detection in opengraph
When inside front matter you specified series with spaces,
then the opengraph template wouldn't detect other articles,
because in `.Site.Taxonomies.series` they are stored by
urlized key.

Example:

```yaml
series:
    - My Series
```

```gohtml
{{/* in a template */}}
{{- $series := index .Site.Taxonomies.series$name }}

{{/* was resolved to */}}
{{- $series := index {'my-series': ...} "MySeries" }}
```

(cherry picked from commit d2d493ab5d6a054001a8448ea0de2949dac4b30e)
2020-12-16 18:07:59 +05:30
Aditya Telange
23636ab326
templates: social-meta: prefer cover image over other images 2020-10-12 17:26:45 +05:30
Aditya Telange
4a4d0c009c
templates: add cover image to be linked into meta
for opengraph, schema and twitter
2020-10-11 21:04:17 +05:30
Aditya Telange
6c4e094c91
templates: Add Twitter Cards, OpenGraph, Schema
This code is licensed under Apache License 2.0
and is part of https://github.com/gohugoio/hugo
2020-10-11 20:07:43 +05:30