Updated Blog-Post page (#1260)

* Updated Blog-Post page

* Second version of the progress bar

* Updated Progress bar for Safari and Firefox

* Returned the scroll bar in the first version
This commit is contained in:
nastyapash
2024-11-05 13:28:46 +01:00
committed by GitHub
parent 241cf2026f
commit 2f38a71bde
9 changed files with 247 additions and 9 deletions
@@ -1,5 +1,5 @@
<section class="qdrant-post {{ if eq .variant "centered" }}qdrant-post_centered{{ end }}">
<article class="container">
<section class="qdrant-post {{ if eq .variant "centered" }}qdrant-post_centered{{ else if eq .variant "blog-post" }}qdrant-blog-post{{ end }}">
<article id="article" class="container">
<div class="qdrant-post__header">
<h1 class="qdrant-post__title">{{ .context.Params.title }}</h1>
<div class="qdrant-post__about">
@@ -18,21 +18,39 @@
</picture>
{{ end }}
</div>
<div class="row">
<div class="col-12 mb-5">
<div class="row qdrant-post__breadcrumbs">
<div class="col-12">
{{ partial "breadcrumbs" .context }}
</div>
</div>
<div class="qdrant-post__body">
{{ if ne .variant "centered" }}
{{ partial "share-buttons" .context }}
{{ if eq .variant "blog-post" }}
<div class="qdrant-post__nav">
{{ with (.context.Site.GetPage "/headless/share-buttons") }}
<h6 class="qdrant-post__nav-title">{{ .Params.navTitle }}</h6>
{{ end }}
{{ .context.TableOfContents }}
<div class="qdrant-post__nav-links">
{{ $link := urlquery .context.Permalink }}
{{ $title := .context.Title }}
{{ with (.context.Site.GetPage "/headless/share-buttons") }}
{{ range .Params.buttons }}
{{ $url := .url | replaceRE "\\{\\{\\s*\\$link\\s*\\}\\}" $link | replaceRE "\\{\\{\\s*\\$title\\s*\\}\\}" $title }}
<a href="{{ $url }}" target="_blank" rel="noopener noreferrer" title="{{ .title }}">
{{ .icon | safeHTML }}
{{ .subtitle }}
</a>
{{ end }}
{{ end }}
</div>
</div>
{{ end }}
<div class="qdrant-post__content">
{{ partial "article-content" .context }}
</div>
{{ if eq .variant "centered" }}
{{ .context.Scratch.Set "variant" "horizontal" }}
{{ partial "share-buttons" .context }}