<div class="db_list_scroller">
<div class="db_list">
    {% set properties = site.pages[page['children'][0]]['properties_md'] %}
    {% if properties != {} %}
    <div class="row header">
        <div class="cell"> </div>
    {% for property_title, property in properties.items() %}
    {% set property_type = site.pages[page['children'][0]]['properties'][property_title]["type"]  %}
        {% if property_type == 'rich_text' %}
        <div class="cell"> <i class="fas fa-align-left"></i>&nbsp;{{property_title}}</div>
        {% elif property_type == 'number' %}
        <div class="cell"> <i class="fas fa-hashtag"></i>&nbsp;{{property_title}}</div>
        {% elif property_type == 'select' %}
        <div class="cell"> <i class="fas fa-caret-square-down"></i>&nbsp;{{property_title}}</div>
        {% elif property_type == 'multi_select' %}
        <div class="cell"> <i class="fas fa-list"></i>&nbsp;{{property_title}} </div>
        {% elif property_type == 'date' %}
        <div class="cell"> <i class="far fa-calendar-alt"></i>&nbsp;{{property_title}}</div>
        {% elif property_type == 'people' %}
        <div class="cell"> <i class="fas fa-user"></i>&nbsp;{{property_title}} </div>
        {% elif property_type == 'files' %}
        <div class="cell"> <i class="fas fa-paperclip"></i>&nbsp;{{property_title}} </div>
        {% elif property_type == 'checkbox' %}
        <div class="cell"> <i class="far fa-check-square"></i>&nbsp;{{property_title}} </div>
        {% elif property_type == 'url' %}
        <div class="cell"> <i class="fas fa-link"></i>&nbsp;{{property_title}}</div>
        {% elif property_type == 'email' %}
        <div class="cell"> <i class="far fa-envelope"></i>&nbsp;{{property_title}} </div>
        {% elif property_type == 'phone_number' %}
        <div class="cell"> <i class="fas fa-phone"></i>&nbsp;{{property_title}} </div>
        {% elif property_type == 'created_time' %}
        <div class="cell"> <i class="far fa-clock"></i>&nbsp;{{property_title}} </div>
        {% endif %}
        {% endfor %}
    </div>
    {% endif %}

    {% for child_id in page.children %}
    {% set db_entry = site.pages[child_id] %}
    <div class="row">
    <a href="{{db_entry.url}}">
        {% if db_entry.emoji %}
        <div class="cell">{{db_entry.emoji}} {{db_entry.title}}</div>
        {% elif db_entry.icon %}
        <div class="cell"><span><span class="miniicon">  <img src="{{db_entry.icon}}">  </span> {{db_entry.title}} </span></div>
        {% else %}
        <div class="cell">{{db_entry.title}}</div>
        {% endif %}
    </a>

        {% for property_title, property_md in db_entry['properties_md'].items() %}
        {% if db_entry['properties'][property_title]['type'] in ['files', 'url'] %}
        {% if property_md != '' %}
        <div class="cell" data-title="{{property_title}}"><a href="{{property_md.split('](')[1][:-1]}}"> {{property_md.split('](')[0][1:]}} </a></div> 
        {% else %}
        <div class="cell" data-title="{{property_title}}">{{property_md}}</div>
        {% endif %}
        {% else %}
        <div class="cell" data-title="{{property_title}}">{{property_md}}</div> 
        {% endif %}
        {% endfor %}
        </div>
        {% endfor %}
</div>
</div>