{% extends "layouts/app.twig" %} {% import 'macros/base.twig' as m %} {% import 'macros/form.twig' as f %} {% block title %}{{ __('Design') }}{% endblock %} {% set colors=['success', 'info', 'warning', 'danger'] %} {% set types=[ 'primary', 'secondary', 'success', 'danger', 'warning', 'info', 'light', 'dark' ] %} {% set types_color=[ ['primary', 'light'], ['secondary', 'light'], ['success', 'light'], ['danger', 'light'], ['warning', 'dark'], ['info', 'dark'], ['light', 'dark'], ['dark', 'light'], ] %} {% set types_buttons=['link']|merge(types) %} {% set shortsum='Lorem ipsum dolor…' %} {% set lipsum='Lorem ipsum dolor sit amet, consectetur adipisici elit…' %} {% set linksum='Lorem ipsum! Dolor link amet, consectetur adipisici elit!' %} {% block content %}
This page should be used when creating and testing new designs to find usability and/or design issues. {{ lipsum|replace({'…': '.'}) }}
{{ linksum|raw }} {{ lipsum }}
Header 1 | Header 2 | Header 3 |
---|---|---|
Table content | {{ lipsum }} | {{ m.icon('check-lg') }} |
Another content | Lorem ipsum | {{ m.icon('x-lg') }} |
{{ linksum|raw }}
{{ lipsum }} {{ lipsum|replace({'…': '.'}) }} {{ lipsum|replace({'…': '.'}) }} {{ lipsum }}
{{ color|capitalize }}: {{ linksum|raw }}
{% for type in types_color %} {{ type[0]|capitalize }} {% endfor %}
{% for type in types_buttons %} {{ f.button(type|capitalize, {'btn_type': type, 'name': 'button-' ~ type}) }} {% endfor %}
{{ shortsum }}
angel()
{{ m.angel() }}
icon(icon_name)
{{ m.icon('star') }}
alert(message, type)
{{ m.alert('Test content', 'info') }}
user(user, opt)
{{ m.user(demo_user) }}
{{ m.user(demo_user_2, {'pronoun': true}) }}
button(label, url, type, size)
{{ m.button('Label', '#', 'info', 'sm') }}
input(name, label, type, opt)
{{ f.input('input-name', 'Label', 'text', {'required': true, 'value': 'Value'}) }}
textarea(name, label, opt)
{{ f.textarea('textarea-name', 'Label', {'required': true, 'rows': 2, 'value': lipsum}) }}
select(name, data, label, selected)
{{ f.select('select-name', {'foo': 'Foo', 'bar': 'Bar'}, 'Label', 'bar') }}
checkbox(name, label, checked, value)
{{ f.checkbox('checkbox-name', 'Label', false) }}
{{ f.checkbox('checkbox-name', 'Label', true, 'on') }}
hidden(name, value)
{{ f.hidden('hidden-name', 'hidden value') | escape }}
button(label, opt)
{{ f.button('Label', {'name': 'button-name', 'value': 'buton-value'}) }}
submit(label, opt)
{{ f.submit() }}