{% with list_type=ordered|yesno:'ol,ul' %} <{{ list_type }} style="line-height: 1.5; padding: {{ padding|default:'0 0 0 16px' }};"> {{ text|safe }} {% endwith %}