1
0
mirror of https://github.com/alexandrev/xslt-lab.git synced 2026-09-16 18:23:16 +00:00
Files
xslt-lab/site/layouts/_default/single.html
T
alexandrev-tibco e1effdef1b Reduce bounce rate: blog CTA + welcome example with auto-run
A) Blog: add prominent playground-cta card at the end of each post.
   Styled with brand gradient border, eyebrow + headline + CTA button.
   Remove the buried related-cta line from related-posts.html.

B) App: load a meaningful XSLT welcome example for first-time visitors
   (no localStorage) and auto-run it immediately (autoRunReady=true),
   so new organic users see live output instead of a blank editor.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-21 22:53:24 +02:00

28 lines
989 B
HTML

{{ define "main" }}
{{- $showAd := and .Site.Params.ethicalads.publisher (ne hugo.Environment "development") -}}
<div class="article-layout{{ if not $showAd }} article-layout--no-ad{{ end }}">
<article class="post">
<p class="eyebrow">{{ .Section | title }}</p>
<h1>{{ .Title }}</h1>
<p class="muted">{{ .Date.Format "02 Jan 2006" }}</p>
{{ with .Params.description }}<p class="lead">{{ . }}</p>{{ end }}
{{ partial "adsense/in-article.html" . }}
<div class="content">
{{ .Content }}
</div>
{{ partial "playground-cta.html" . }}
<p class="muted back-link"><a href="{{ .CurrentSection.RelPermalink }}">← Back to {{ .CurrentSection.Title }}</a></p>
{{ partial "related-posts.html" . }}
</article>
{{- if $showAd -}}
<aside class="article-sidebar">
<div
id="xsltplayground-blog"
data-ea-publisher="{{ .Site.Params.ethicalads.publisher }}"
data-ea-type="image"
></div>
</aside>
{{- end -}}
</div>
{{ end }}