{% load i18n widget_tweaks spider_rdf %}
<ul class="w3-ul" rel="spkc:properties">
  {% for field in form.visible_fields %}
    <li class="" typeof="spkc:Property">
      <div class="">
        <div class="w3-cell w3-padding">
          <data hidden="hidden" property="spkc:fieldname" datatype="xsd:string">{{field.html_name}}</data>
          <data hidden="hidden" property="spkc:name" datatype="xsd:string">{{field.name}}</data>
          <div>{{ field.label_tag }}</div>
          {% if field.field.widget.input_type == "select" and field.field.widget.allow_multiple_selected %}
            {% if field.field.queryset %}
              <ul class="w3-white">
                {% for q in field.field.queryset %}
                  {% literalize q as LiteralData %}
                  <li><a property="spkc:value" datatype="{{LiteralData.datatype}}" href="{{q.get_absolute_url}}">{{q}}</a></li>
                {% endfor %}
              </ul>
            {% else %}
              <ul class="w3-white">
                {% for q in field.value %}
                  {% literalize q as LiteralData %}
                  <li property="spkc:value" datatype="{{LiteralData.datatype}}" content="{{LiteralData}}">{{q|default_if_none:""}}</li>
                {% endfor %}
              </ul>
            {% endif %}
          {% elif field|widget_type == "url" %}
            {% literalize field as LiteralData %}
            <a property="spkc:value" datatype="{{LiteralData.datatype}}" class="w3-white" href={{field.value}}>{{field.name}}</a>
          {% else %}
            {% literalize field as LiteralData %}
            <span property="spkc:value" datatype="{{LiteralData.datatype}}" content="{{LiteralData}}" class="w3-white">{{field.value|default_if_none:""}}</span>
          {% endif %}
        </div>
      </div>
    </li>
  {% empty %}{{form_empty_message|safe}}{% endfor %}
</ul>
