dynamic header logo

main
alexanderroese 2024-06-22 10:48:47 +02:00
parent b44ec07f0e
commit 957eba590f
1 changed files with 3 additions and 23 deletions

View File

@ -177,7 +177,6 @@
{% capture sizes %}(max-width: {{ settings.logo_width | times: 2 }}px) 50vw, {{ settings.logo_width }}px{% endcapture %}
{% capture widths %}{{ settings.logo_width }}, {{ settings.logo_width | times: 1.5 | round }}, {{ settings.logo_width | times: 2 }}{% endcapture %}
{% comment %}
{% liquid
capture shx_current_page
render "shx-get-current-page"
@ -186,32 +185,13 @@
assign shx_header_logo = settings.logo
if shx_current_page contains "texte"
assign shx_header_logo = settings.shx_logo_texte | image_url
assign shx_header_logo = settings.shx_logo2
elsif shx_current_page contains "figuren"
assign shx_header_logo = settings.shx_logo_figuren | image_url
assign shx_header_logo = settings.shx_logo2
endif
%}
<h1>curr {{ shx_current_page }} {{ shx_current_page contains "texte" }}</h1>
<h1>{{ shx_header_logo }}</h1>
<h1>{{ settings.logo }}</h1>
<h1>{{ settings.shx_logo_texte }}</h1>
{% endcomment %}
<h1>here {{ settings.logo }}</h1>
<h2>here2 {{ settings.logo2 }}</h2>
{{ settings.shx_logo2 | image_url: width: 600 | image_tag:
class: 'header__heading-logo motion-reduce',
widths: widths,
height: logo_height,
width: settings.logo_width,
alt: logo_alt,
sizes: sizes,
preload: true
}}
{{ settings.logo | image_url: width: 600 | image_tag:
{{ shx_current_page | image_url: width: 600 | image_tag:
class: 'header__heading-logo motion-reduce',
widths: widths,
height: logo_height,