mirror of
https://github.com/kemko/liquid.git
synced 2026-01-02 16:25:42 +03:00
1.4 KiB
1.4 KiB
layout, title, nav
| layout | title | nav | ||
|---|---|---|---|---|
| default | theme |
|
theme
The theme object contains information about published themes in a shop. You can also use themes to iterate through both themes.
Input
{% highlight html %}{% raw %} {% for t in themes %} {{ t.role }} theme: {{ t.name }} {% endfor %} {% endraw %}{% endhighlight %}Output
{% highlight html %}{% raw %}
mobile theme: minimal
main theme: radiance
{% endraw %}{% endhighlight %}
The theme object has the following attributes:
{% anchor_link "theme.id", "theme-id" %}
Returns the theme's id. This is useful for when you want to link a user directly to the theme's Theme Settings.
Input
{% highlight html %}{% raw %}
Go to your theme settings to change your logo.
{% endraw %}{% endhighlight %}
Output
{% highlight html %}{% raw %}
Go to your theme settings to change your logo.
{% endraw %}{% endhighlight %}
{% anchor_link "theme.role", "theme-role" %}
Returns one of the two possible roles of a theme: main or mobile.
{% anchor_link "theme.name", "theme-name" %}
Returns the name of the theme.