{% if tags|length %}

  <label for="cloud_tags_filter" >{{ 'tags.cloud.filter.text'|trans({}, 'userui') }}</label>
  <input type="text" id="cloud_tags_filter" />

  <input type="hidden" id="get_elements_url" value="{{ path('favorite_get', {
    'user_id': user_id, 
    'tags_ids_json' : ''
  }) }}" />
  
  <p><span class="help">{{ 'tag_favorites.help'|trans({}, 'elements') }}</span></p>
         
  <ul id="favorite_tags">
    {% for key, tag in tags %}
      <li class="{{ css_list_length_class(key, tags|length) }}" {% if loop.index0 > cloud_tags_limit_to_display %}style="display: none;"{% endif %}>
        <a id="filtering_tag_{{ tag.id }}" href="#" class="tag">
          {{ tag.name }}
        </a>
      </li>
    {% endfor %}
  </ul>
  <div class="clearboth" ></div>
  
  {% if tags|length > cloud_tags_limit_to_display+1 %}
    <a href="#" id="display_all_cloud_tag" >
      {{ 'tags.cloud.display_more'|trans({}, 'userui') }}
    </a>
  {% endif %}
{% endif %}