{% if extra_buttons_mode == "dropdown" %} More {% for button in extra_buttons %} {{ button.text }} {% endfor %} {% else %} {% for button in extra_buttons %}{{ button.text }}{% endfor %} {% endif %}