{% extends "bookmarks/layout.html" %}
{% load static %}
{% load shared %}
{% load bookmarks %}

{% block content %}
  <div class="bookmarks-page grid columns-md-1"
       ld-bookmark-page
       bookmarks-url="{% url 'bookmarks:partials.bookmark_list.shared' %}"
       tags-url="{% url 'bookmarks:partials.tag_cloud.shared' %}">

    {# Bookmark list #}
    <section class="content-area col-2">
      <div class="content-area-header">
        <h2>Shared bookmarks</h2>
        <div class="header-controls">
          {% bookmark_search bookmark_list.search tag_cloud.tags mode='shared' %}
          <button ld-modal modal-content=".tag-cloud" class="btn ml-2 show-md">Tags</button>
        </div>
      </div>

      <form class="bookmark-actions" action="{{ bookmark_list.action_url|safe }}"
            method="post">
        {% csrf_token %}

        <div class="bookmark-list-container">
          {% include 'bookmarks/bookmark_list.html' %}
        </div>
      </form>
    </section>

    {# Filters #}
    <section class="content-area col-1 hide-md">
      <div class="content-area-header">
        <h2>User</h2>
      </div>
      <div>
        {% user_select bookmark_list.search users %}
        <br>
      </div>
      <div class="content-area-header">
        <h2>Tags</h2>
      </div>
      <div class="tag-cloud-container">
        {% include 'bookmarks/tag_cloud.html' %}
      </div>
    </section>
  </div>

  <script src="{% static "bundle.js" %}?v={{ app_version }}"></script>
{% endblock %}
