change to relative links
Signed-off-by: Toshaan Bharvani <toshaan@vantosh.com>remotes/1693380793390951372/master
parent
966d86dffa
commit
2cc67a4542
@ -1,30 +1,27 @@
|
|||||||
{{ partial "header.html" . }}
|
{{ partial "header.html" . }}
|
||||||
|
|
||||||
{{ partial "navbar.html" . }}
|
{{ partial "navbar.html" . }}
|
||||||
|
<main class="main">
|
||||||
<main class="main">
|
<div class="container">
|
||||||
<div class="container">
|
<div class="row">
|
||||||
<div class="row">
|
<div class="col-md-6">
|
||||||
<div class="col-md-6">
|
<h1 class="h2 section-header my-3 my-md-5 pb-2">{{ .Title }}</h1>
|
||||||
<h1 class="h2 section-header my-3 my-md-5 pb-2">{{ .Title }}</h1>
|
{{ .Content }}
|
||||||
{{ .Content }}
|
|
||||||
</div>
|
|
||||||
{{ if .Param "image" }}
|
|
||||||
<div class="col-md-6 pt-5 pl-3 pr-0">
|
|
||||||
{{ $imagefilename := .Param "image.file" }}
|
|
||||||
{{ $imagesize := .Param "image.size" }}
|
|
||||||
{{ $imagelocation := printf "%s/%s" "images" $imagefilename }}
|
|
||||||
{{ $imageresource := resources.Get $imagelocation }}
|
|
||||||
{{ if $imageresource }}
|
|
||||||
{{ $imagefile := $imageresource.Fit "600x600" }}
|
|
||||||
<figure class="figure d-flex pt-3">
|
|
||||||
<img src="{{ $imagefile.RelPermalink }}">
|
|
||||||
</figure>
|
|
||||||
{{ end }}
|
|
||||||
</div>
|
|
||||||
{{ end }}
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</main>
|
{{ if .Param "image" }}
|
||||||
|
<div class="col-md-6 pt-5 pl-3 pr-0">
|
||||||
|
{{ $imagefilename := .Param "image.file" }}
|
||||||
|
{{ $imagesize := .Param "image.size" }}
|
||||||
|
{{ $imagelocation := printf "%s/%s" "images" $imagefilename }}
|
||||||
|
{{ $imageresource := resources.Get $imagelocation }}
|
||||||
|
{{ if $imageresource }}
|
||||||
|
{{ $imagefile := $imageresource.Fit "600x600" }}
|
||||||
|
<figure class="figure d-flex pt-3">
|
||||||
|
<img src="{{ $imagefile.RelPermalink }}">
|
||||||
|
</figure>
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</main>
|
||||||
{{ partial "footer.html" . }}
|
{{ partial "footer.html" . }}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"title": "{{ .Title }}",
|
"title": "{{ .Title }}",
|
||||||
"permalink": "{{ .Permalink }}",
|
"permalink": "{{ .RelPermalink }}",
|
||||||
"content": "{{ .PlainWords }}"
|
"content": "{{ .PlainWords }}"
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{{- $.Scratch.Add "index" slice -}}
|
{{- $.Scratch.Add "index" slice -}}
|
||||||
{{- range .Data.Pages -}}
|
{{- range .Data.Pages -}}
|
||||||
{{- $.Scratch.Add "index" (dict "title" .Title "permalink" .Permalink "contents" .Plain "tags" .Params.tags) }}
|
{{- $.Scratch.Add "index" (dict "title" .Title "permalink" .RelPermalink "contents" .Plain "tags" .Params.tags) }}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- $.Scratch.Get "index" | jsonify -}}
|
{{- $.Scratch.Get "index" | jsonify -}}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{{- $.Scratch.Add "index" slice -}}
|
{{- $.Scratch.Add "index" slice -}}
|
||||||
{{- range .Data.Pages -}}
|
{{- range .Data.Pages -}}
|
||||||
{{- $.Scratch.Add "index" (dict "title" .Title "permalink" .Permalink "contents" .Plain "tags" .Params.tags) }}
|
{{- $.Scratch.Add "index" (dict "title" .Title "permalink" .RelPermalink "contents" .Plain "tags" .Params.tags) }}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- $.Scratch.Get "index" | jsonify -}}
|
{{- $.Scratch.Get "index" | jsonify -}}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{{- $.Scratch.Add "index" slice -}}
|
{{- $.Scratch.Add "index" slice -}}
|
||||||
{{- range .Data.Pages -}}
|
{{- range .Data.Pages -}}
|
||||||
{{- $.Scratch.Add "index" (dict "title" .Title "permalink" .Permalink "contents" .Plain "tags" .Params.tags) }}
|
{{- $.Scratch.Add "index" (dict "title" .Title "permalink" .RelPermalink "contents" .Plain "tags" .Params.tags) }}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- $.Scratch.Get "index" | jsonify -}}
|
{{- $.Scratch.Get "index" | jsonify -}}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{{- $.Scratch.Add "index" slice -}}
|
{{- $.Scratch.Add "index" slice -}}
|
||||||
{{- range .Data.Pages -}}
|
{{- range .Data.Pages -}}
|
||||||
{{- $.Scratch.Add "index" (dict "title" .Title "permalink" .Permalink "contents" .Plain "tags" .Params.tags) }}
|
{{- $.Scratch.Add "index" (dict "title" .Title "permalink" .RelPermalink "contents" .Plain "tags" .Params.tags) }}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- $.Scratch.Get "index" | jsonify -}}
|
{{- $.Scratch.Get "index" | jsonify -}}
|
||||||
|
Loading…
Reference in New Issue