<% root_taxons.each do |root_taxon| %>
  <% root_taxon = TopicTreePresenter.new(root_taxon, collapsed: root_taxons.size > 1) %>

  <div class="topic-tree">
    <a class="<%= root_taxon.toggle_classes %>" data-toggle="collapse" href="#<%= root_taxon.content_id %>"><span class='icon'></span><%= root_taxon.name %></a>

    <div class="<%= root_taxon.tree_classes %>" id="<%= root_taxon.content_id %>">
      <%= render partial: "sub_taxons", locals: {form: @edition_tag_form, taxons: root_taxon.children } %>
    </div>
  </div>
<% end %>

<% root_taxons.each do |root_taxon| %>
  <% root_taxon = TopicTreePresenter.new(root_taxon, collapsed: root_taxons.size > 1) %>

  <% if root_taxon.children.empty? %>
    <%= render partial: "sub_taxons", locals: { form: @edition_tag_form, taxons: [root_taxon] } %>
  <% else %>
    <div class="topic-tree">
      <a class="<%= root_taxon.toggle_classes %>" data-toggle="collapse" href="#<%= root_taxon.content_id %>"><span class='icon'></span><%= root_taxon.name %></a>

      <div class="<%= root_taxon.tree_classes %>" id="<%= root_taxon.content_id %>">
        <%= render partial: "sub_taxons", locals: {form: @edition_tag_form, taxons: root_taxon.children } %>
      </div>
    </div>
  <% end %>
<% end %>

Allow tagging to singular root taxons
Allow tagging to singular root taxons
