{% extends "base.html" %} {% load wagtailcore_tags %} {% block content %}

Page Settings

Theme: {{ page.theme }}

Layout: {{ page.layout }}

These settings were chosen using ThumbnailRadioSelect widgets in the Wagtail admin!

{% for block in page.content %} {% if block.block_type == 'heading' %}

{{ block.value }}

{% elif block.block_type == 'paragraph' %}
{{ block.value|richtext }}
{% elif block.block_type == 'icon_block' %}

Icon Block

{% include "home/icons/inline/"|add:block.value.icon|add:".html" %} {{ block.value.text|default:"" }}
{% elif block.block_type == 'color_scheme' %}

Color Scheme Block

{% if block.value.title %}

{{ block.value.title }}

{% endif %} {% if block.value.content %}

{{ block.value.content }}

{% endif %}

Selected scheme: {{ block.value.scheme }}

{% elif block.block_type == 'button_style' %}

Button Style Block

{{ block.value.text }}

Style: {{ block.value.style }}

{% elif block.block_type == 'optional_icon' %}

Optional Icon Block (required=False)

{% if block.value.icon %}
{% include "home/icons/inline/"|add:block.value.icon|add:".html" %}
{% else %}
No icon selected
{% endif %}

{{ block.value.heading }}

Icon field is optional - can be left blank

{% elif block.block_type == 'required_icon' %}

Required Icon Block (required=True)

{% include "home/icons/inline/"|add:block.value.icon|add:".html" %}

{{ block.value.heading }}

Icon field is required - must select an icon

{% endif %} {% endfor %}
{% if not page.content %}

Welcome!

This is a demo of the Wagtail Thumbnail Choice Block. To see it in action:

  1. Go to the Wagtail admin at /admin/
  2. Edit this page
  3. Try changing the Theme and Layout settings
  4. Add content blocks with various thumbnail choice options
{% endif %} {% endblock %}