<% page_title "Site Map" %>

<div id="c-static">
  <div id="a-site-map" class="fixed-width-container space-y-4 md:flex md:space-y-0">
    <section class="flex-auto space-y-4">
      <ul>
        <li><h2>Posts</h2></li>
        <li><%= link_to_wiki "Help", "help:posts" %></li>
        <li><%= link_to("Listing", posts_path) %></li>
        <li><%= link_to("Upload", new_upload_path) %></li>
        <li><%= link_to("Upload Listing", uploads_path) %></li>
        <li><%= link_to("Popular", popular_explore_posts_path) %></li>
        <li><%= link_to("Curated", curated_explore_posts_path) %></li>
        <li><%= link_to("Most Viewed", viewed_explore_posts_path) %></li>
        <li><%= link_to("Votes", post_votes_path) %></li>
        <% if policy(PostApproval).create? %>
          <li><%= link_to("Modqueue", modqueue_index_path) %></li>
        <% end %>
      </ul>
      <ul>
        <li><h2>Post Events</h2></li>
        <li><%= link_to("Changes", post_versions_path) %></li>
        <li><%= link_to("Approvals", post_approvals_path) %></li>
        <li><%= link_to("Disapprovals", post_disapprovals_path) %></li>
        <li><%= link_to("Appeals", post_appeals_path) %></li>
        <li><%= link_to("Flags", post_flags_path) %></li>
        <li><%= link_to("Replacements", post_replacements_path) %></li>
      </ul>
      <ul>
        <li><h2>Tools</h2></li>
        <li><%= link_to("Source Code", Danbooru.config.source_code_url) %></li>
        <li><%= link_to("Bug Reports", Danbooru.config.issues_url) %></li>
        <li><%= link_to("Keyboard Shortcuts", keyboard_shortcuts_path) %></li>
        <li><%= link_to("Bookmarklet", bookmarklet_path) %></li>
        <li><%= link_to_wiki "User Scripts", "about:userscripts" %></li>
        <li><%= link_to_wiki "API Documentation", "help:api" %></li>
        <li><%= link_to("Similar Images Search", iqdb_queries_path) %></li>
      </ul>
      <ul>
        <li><h2>Artists</h2></li>
        <li><%= link_to_wiki "Help", "help:artists" %></li>
        <li><%= link_to("Listing", artists_path) %></li>
        <li><%= link_to("Banned", banned_artists_path) %></li>
        <li><%= link_to("Changes", artist_versions_path) %></li>
      </ul>
    </section>
    <section class="flex-auto space-y-4">
      <ul>
        <li><h2>Tags</h2></li>
        <li><%= link_to_wiki "Help", "help:tags" %></li>
        <li><%= link_to_wiki "Cheat sheet", "help:cheatsheet" %></li>
        <li><%= link_to("Aliases", tag_aliases_path) %></li>
        <li><%= link_to("Implications", tag_implications_path) %></li>
        <li><%= link_to("Listing", tags_path) %></li>
        <li><%= link_to("Related Tags", related_tag_path) %></li>
      </ul>
      <ul>
        <li><h2>Notes</h2></li>
        <li><%= link_to_wiki "Help", "help:notes" %></li>
        <li><%= link_to("Listing", notes_path) %></li>
        <li><%= link_to("Changes", note_versions_path) %></li>
      </ul>
      <ul>
        <li><h2>Pools</h2></li>
        <li><%= link_to_wiki "Help", "help:pools" %></li>
        <li><%= link_to("Listing", pools_path) %></li>
        <li><%= link_to("Gallery", gallery_pools_path) %></li>
        <% if PoolVersion.enabled? %>
          <li><%= link_to("Changes", pool_versions_path) %></li>
        <% end %>
      </ul>
      <ul>
        <li><h2>Reports</h2></li>
        <li><%= link_to("Performance Reports", "https://isshiki.donmai.us/user-reports") %></li>
        <li><%= link_to("Dashboard", moderator_dashboard_path) %></li>
        <li><%= link_to("Top Searches", searches_explore_posts_path) %></li>
        <li><%= link_to("Missed Searches", missed_searches_explore_posts_path) %></li>
      </ul>
    </section>
    <section class="flex-auto space-y-4">
      <ul>
        <li><h2>Comments</h2></li>
        <li><%= link_to_wiki "Help", "help:comments" %></li>
        <li><%= link_to("Listing", comments_path) %></li>
        <li><%= link_to("Search", search_comments_path) %></li>
        <li><%= link_to("Votes", comment_votes_path) %></li>
        <li><%= link_to("RSS", comments_path(:atom)) %></li>
      </ul>
      <ul>
        <li><h2>Forum</h2></li>
        <li><%= link_to_wiki "Help", "help:forum" %></li>
        <li><%= link_to("Listing", forum_topics_path) %></li>
        <li><%= link_to("Search", search_forum_posts_path) %></li>
        <li><%= link_to("Votes", forum_post_votes_path) %></li>
        <li><%= link_to("RSS", forum_topics_path(:atom)) %></li>
      </ul>
      <ul>
        <li><h2>Wiki</h2></li>
        <li><%= link_to_wiki "Help", "help:wiki" %></li>
        <li><%= link_to("Listing", wiki_pages_path) %></li>
        <li><%= link_to("Search", search_wiki_pages_path) %></li>
        <li><%= link_to("Changes", wiki_page_versions_path) %></li>
      </ul>
      <ul>
        <li><h2>Artist commentary</h2></li>
        <li><%= link_to_wiki "Help", "help:artist_commentary" %></li>
        <li><%= link_to("Listing", artist_commentaries_path) %></li>
        <li><%= link_to("Search", search_artist_commentaries_path) %></li>
        <li><%= link_to("Changes", artist_commentary_versions_path) %></li>
      </ul>
    </section>
    <section class="flex-auto space-y-4">
      <ul>
        <li><h2>Profile</h2></li>
        <% if CurrentUser.is_anonymous? %>
          <li><%= link_to "Login", login_path %></li>
          <li><%= link_to "Sign up", new_user_path %></li>
        <% else %>
          <li><%= link_to "Profile", profile_path %></li>
          <li><%= link_to "Settings", settings_path %></li>
          <% if policy(UserNameChangeRequest).create? %>
            <li><%= link_to "Change name", new_user_name_change_request_path %></li>
          <% end %>
          <li><%= link_to "Dmails", dmails_path(search: { folder: "received" }) %></li>
          <li><%= link_to "Favorites", favorites_path %></li>
          <li><%= link_to "Favorite groups", favorite_groups_path %></li>
          <li><%= link_to "Saved searches", saved_searches_path %></li>
        <% end %>
        <li><%= link_to "Upgrade information", new_user_upgrade_path %></li>
      </ul>
      <ul>
        <li><h2>Users</h2></li>
        <li><%= link_to_wiki "Help", "help:users" %></li>
        <li><%= link_to("Listing", users_path) %></li>
        <li><%= link_to("Bans", bans_path) %></li>
        <li><%= link_to("Feedback", user_feedbacks_path) %></li>
        <li><%= link_to("Terms of Service", terms_of_service_path) %></li>
        <li><%= link_to("Privacy Policy", privacy_policy_path) %></li>
      </ul>
      <ul>
        <li><h2>Admin</h2></li>
        <li><%= link_to("Mod Actions", mod_actions_path) %></li>
        <li><%= link_to("Bulk Update Requests", bulk_update_requests_path) %></li>

        <% if policy(UserNameChangeRequest).index? %>
          <li><%= link_to("User Name Change Requests", user_name_change_requests_path) %></li>
        <% end %>

        <% if policy(ModerationReport).index? %>
          <li><%= link_to("Moderation Reports", moderation_reports_path) %></li>
        <% end %>

        <% if policy(UserEvent).index? %>
          <li><%= link_to("User Events", user_events_path) %></li>
        <% end %>

        <% if policy(EmailAddress).index? %>
          <li><%= link_to("Email Addresses", emails_path) %></li>
        <% end %>

        <% if policy(IpAddress).index? %>
          <li><%= link_to("IP Addresses", ip_addresses_path) %></li>
        <% end %>

        <% if policy(IpBan).index? %>
          <li><%= link_to("IP Bans", ip_bans_path) %></li>
        <% end %>

        <% if policy(NewsUpdate).index? %>
          <li><%= link_to("News Updates", news_updates_path) %></li>
        <% end %>

        <li><%= link_to("Jobs", delayed_jobs_path) %></li>
      </ul>
    </section>
  </div>
</div>
