feat: Avancement sur le design
This commit is contained in:
5
layouts/_default/_markup/render-image.html
Normal file
5
layouts/_default/_markup/render-image.html
Normal file
@ -0,0 +1,5 @@
|
||||
{{/*
|
||||
S'il n'y a pas de / dans l'url d'une image alors on ajoute le path de l'article
|
||||
*/}}
|
||||
{{ $path := cond (in .Destination "/") .Destination (path.Join "/" .Page.Dir .Destination) }}
|
||||
<img src="{{ $path | safeURL }}" alt="{{ .Text }}" {{ with .Title}} title="{{ . }}"{{ end }} />
|
1
layouts/_default/_markup/render-link.html
Normal file
1
layouts/_default/_markup/render-link.html
Normal file
@ -0,0 +1 @@
|
||||
<a href="{{ .Destination | safeURL }}"{{ with .Title}} title="{{ . }}"{{ end }}{{ if strings.HasPrefix .Destination "http" }} target="_blank" rel="noopener"{{ end }}>{{ .Text | safeHTML }}</a>
|
Reference in New Issue
Block a user