{# Responsive Menu Jinja template file. NOT Safe to Copy Do Not Copy #} {% macro percentage_units(name, value) %} {% endmacro %} {% macro pixel_units(name, value) %} {% endmacro %} {% macro pixel_units_auto(name, value) %} {% endmacro %} {% macro animation_select(name, value) %} {% endmacro %} {% macro select(name, value, choices, class='') %} {% endmacro %} {% macro selectize(name, value, class='') %} {% endmacro %} {% macro font_icon(name, value, type) %} {% endmacro %} {% macro button_animation_select(name, value) %} {% endmacro %} {% macro input(name, value, class='') %} {% endmacro %} {% macro colour(name, value) %} {% endmacro %} {% macro label(for, title) %} {% endmacro %} {% macro checkbox(name, value) %} {% endmacro %} {% macro image(name, value) %}
{% endmacro %} {% macro textarea(name, value) %} {% endmacro %} {% macro row(name, title, type, options, errors, class='', pro='', select_type='', unit_type='', sub_title='', unit='', choices=[], sub_sub_title='') %} {% import _self as macros %} {{ macros.label(name, title) }} {% if sub_title %}
{{ sub_title|raw }}
{% endif %} {% if sub_sub_title %}

{{ sub_sub_title|raw }}
{% endif %} {% if pro == 'pro' %}
Click to upgrade now to use
{% endif %} {% if type == 'checkbox' %} {{ macros.checkbox(name, options[name]) }} {% elseif type == 'colour' %} {{ macros.colour(name, options[name]) }} {% elseif type == 'input' %} {{ macros.input(name, options[name], class) }} {% if class == 'has-unit' %} {% if unit_type == 'pixel' %} {{ macros.pixel_units(name ~ '_unit', options[name ~ '_unit']) }} {% elseif unit_type == 'pixel_auto' %} {{ macros.pixel_units_auto(name ~ '_unit', options[name ~ '_unit']) }} {% elseif unit_type == 'percentage' %} {{ macros.percentage_units(name ~ '_unit', options[name ~ '_unit']) }} {% endif %} {% endif %} {% elseif type == 'textarea' %} {{ macros.textarea(name, options[name], class) }} {% elseif type == 'selectize' %} {{ macros.selectize(name, options[name], class) }} {% elseif type == 'select' %} {% if select_type == 'side' %} {% set choices = { 'top': 'Top', 'left': 'Left', 'right': 'Right', 'bottom': 'Bottom' } %} {{ macros.select(name, options[name], choices) }} {% elseif select_type == 'left_right' %} {% set choices = { 'left': 'Left', 'right': 'Right' } %} {{ macros.select(name, options[name], choices) }} {% elseif select_type == 'left_right_with_none' %} {% set choices = { '': 'None', 'left': 'Left', 'right': 'Right' } %} {{ macros.select(name, options[name], choices) }} {% elseif select_type == 'left_right_centre_with_none' %} {% set choices = { '': 'None', 'left': 'Left', 'right': 'Right', 'centre': 'Centre' } %} {{ macros.select(name, options[name], choices) }} {% elseif select_type == 'mega_standard_menu_animation' %} {% set choices = { 'fade': 'Fade', 'fadeUp': 'FadeUp', 'slideDown': 'SlideDown', 'slideUp': 'SlideUp' } %} {{ macros.select(name, options[name], choices, 'is-animation-input') }} {% set choices = { '100ms': '100ms', '200ms': '200ms', '300ms': '300ms', '400ms': '400ms', '500ms': '500ms', '600ms': '600ms', '700ms': '700ms', '800ms': '800ms', '900ms': '900ms', '1000ms': '1000ms', } %} {{ macros.select(name ~ '_speed', options[name ~ '_speed'], choices, 'is-animation-input') }} {% elseif select_type == 'position' %} {% elseif select_type == 'animation' %} {{ macros.animation_select(name, options[name]) }} {% elseif select_type == 'depth' %} {% set choices = { '1': '1', '2': '2', '3': '3', '4': '4', '5': '5' } %} {{ macros.select(name, options[name], choices) }} {% elseif select_type == 'alignment' %} {% set choices = { 'left': 'Left', 'right': 'Right', 'center': 'Centered', 'justify': 'Justified' } %} {{ macros.select(name, options[name], choices) }} {% elseif select_type == 'link_locations' %} {% set choices = { '_blank': 'New Tab', '_self': 'Same Page', '_parent': 'Parent Page', '_top': 'Full Window Body' } %} {{ macros.select(name, options[name], choices) }} {% elseif select_type == 'theme' %} {% set choices = { 'dark': 'Dark', 'light': 'Light' } %} {{ macros.select(name, options[name], choices) }} {% elseif select_type == 'custom' %} {{ macros.select(name, options[name], choices) }} {% elseif select_type == 'button_animation' %} {{ macros.button_animation_select(name, options[name]) }} {% elseif select_type == 'menu_theme' %} {% set themes = get_available_themes() %} {% set choices = [] %} {% for theme, config in themes %} {% set choices = choices|merge({(theme): config.name ~ ' (' ~ theme ~ ')'}) %} {% endfor %} {{ macros.select(name, options[name], choices) }} {% endif %} {% elseif type == 'image' %} {{ macros.image(name, options[name]) }} {% elseif type == 'font-icon' %} {{ macros.font_icon(name, options[name], options[name ~ '_type']) }} {% endif %} {% if unit %} {{ unit }} {% endif %} {% endmacro %} {% macro header(title, section) %}
{{ title }} {{ section }}
{% endmacro %}