-
Notifications
You must be signed in to change notification settings - Fork 524
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of https://github.com/smclairecarden/otwarchive …
…into AO3-6608_deleteAltText
- Loading branch information
Showing
79 changed files
with
1,247 additions
and
747 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,72 +1,73 @@ | ||
<h3 class="landmark heading"><%= ts("Admin Navigation", key: "header") %></h3> | ||
<ul class="admin primary navigation actions" role="navigation"> | ||
<% if policy(User).can_manage_users? %> | ||
<nav aria-label="<%= t(".nav.label") %>"> | ||
<ul class="admin primary navigation actions"> | ||
<% if policy(User).can_manage_users? %> | ||
<li class="dropdown"> | ||
<%= link_to t(".nav.users.manage"), admin_users_path %> | ||
<ul class="menu"> | ||
<li><%= link_to t(".nav.users.search"), admin_users_path %></li> | ||
<li><%= link_to t(".nav.users.email_search"), bulk_search_admin_users_path %></li> | ||
</ul> | ||
</li> | ||
<% end %> | ||
|
||
<li class="dropdown"> | ||
<%= link_to ts("Manage Users", key: "header"), admin_users_path %> | ||
<ul class="menu" role="menu"> | ||
<li><%= link_to ts("Find Users", key: "header"), admin_users_path %></li> | ||
<li><%= link_to ts("Bulk Email Search", key: "header"), bulk_search_admin_users_path %></li> | ||
<%= link_to t(".nav.invitations.invitations"), admin_invitations_path %> | ||
<ul class="menu"> | ||
<li><%= link_to t(".nav.invitations.new"), admin_invitations_path %></li> | ||
<li><%= link_to t(".nav.invitations.requests"), user_invite_requests_path %></li> | ||
<% if policy(InviteRequest).can_manage? %> | ||
<li><%= link_to t(".nav.invitations.queue"), manage_invite_requests_path %></li> | ||
<% end %> | ||
</ul> | ||
</li> | ||
<% end %> | ||
|
||
<li class="dropdown"> | ||
<%= link_to ts("Invitations", key: "header"), admin_invitations_path %> | ||
<ul class="menu" role="menu"> | ||
<li><%= link_to ts("Invite New Users", key: "header"), admin_invitations_path %></li> | ||
<li><%= link_to ts("Manage Requests", key: "header"), user_invite_requests_path %></li> | ||
<% if policy(InviteRequest).can_manage? %> | ||
<li><%= link_to ts("Manage Queue", key: "header"), manage_invite_requests_path %></li> | ||
<% end %> | ||
</ul> | ||
</li> | ||
<li class="dropdown"> | ||
<%= link_to ts("Admin Posts", key: "header"), admin_posts_path %> | ||
<ul class="menu" role="menu"> | ||
<li><%= link_to ts("AO3 News", key: "header"), admin_posts_path %></li> | ||
<% if policy(AdminPost).can_post? %> | ||
<li><%= link_to ts("Post AO3 News", key: "header"), new_admin_post_path %></li> | ||
<% end %> | ||
<li><%= link_to ts("Archive FAQ", key: "header"), archive_faqs_path %></li> | ||
<li><%= link_to ts("Known Issues", key: "header"), known_issues_path %></li> | ||
<li><%= link_to ts("Wrangling Guidelines", key: "header"), wrangling_guidelines_path %></li> | ||
</ul> | ||
</li> | ||
<% if policy(AdminBlacklistedEmail).index? %> | ||
<li><%= link_to ts("Banned Emails", key: "header"), admin_blacklisted_emails_path %></li> | ||
<% end %> | ||
<li class="dropdown"> | ||
<%= link_to t(".nav.posts.admin_posts"), admin_posts_path %> | ||
<ul class="menu"> | ||
<li><%= link_to t(".nav.posts.news"), admin_posts_path %></li> | ||
<% if policy(AdminPost).can_post? %> | ||
<li><%= link_to t(".nav.posts.post_news"), new_admin_post_path %></li> | ||
<% end %> | ||
<li><%= link_to t(".nav.posts.faqs"), archive_faqs_path %></li> | ||
<li><%= link_to t(".nav.posts.known_issues"), known_issues_path %></li> | ||
<li><%= link_to t(".nav.posts.wrangling_guidelines"), wrangling_guidelines_path %></li> | ||
</ul> | ||
</li> | ||
<% if policy(AdminBlacklistedEmail).index? %> | ||
<li><%= link_to t(".nav.banned_emails"), admin_blacklisted_emails_path %></li> | ||
<% end %> | ||
|
||
<% if policy(ModeratedWork).index? %> | ||
<li><%= link_to ts("Spam", key: "header"), admin_spam_index_path %></li> | ||
<% end %> | ||
<% if policy(ModeratedWork).index? %> | ||
<li><%= link_to t(".nav.spam"), admin_spam_index_path %></li> | ||
<% end %> | ||
|
||
<% if policy(AdminSetting).can_view_settings? %> | ||
<li><%= link_to ts("Settings", key: "header"), admin_settings_path %></li> | ||
<% end %> | ||
<% if policy(AdminSetting).can_view_settings? %> | ||
<li><%= link_to t(".nav.settings"), admin_settings_path %></li> | ||
<% end %> | ||
|
||
<% if policy(AdminBanner).index? %> | ||
<li><%= link_to ts("Banners", key: "header"), admin_banners_path %></li> | ||
<% end %> | ||
<% if policy(AdminBanner).index? %> | ||
<li><%= link_to t(".nav.banners"), admin_banners_path %></li> | ||
<% end %> | ||
|
||
<% if policy(Skin).index? %> | ||
<li class="dropdown"> | ||
<%= link_to ts("Skins", key: "header"), admin_skins_path %> | ||
<ul class="menu" role="menu"> | ||
<li><%= link_to ts("Approval Queue", key: "header"), admin_skins_path %></li> | ||
<li><%= link_to ts("Approved Skins", key: "header"), index_approved_admin_skins_path %></li> | ||
<li><%= link_to ts("Rejected Skins", key: "header"), index_rejected_admin_skins_path %></li> | ||
</ul> | ||
</li> | ||
<% end %> | ||
<li><%= link_to ts("Tag Wrangling", key: "header"), tag_wranglings_path %></li> | ||
<% if policy(Skin).index? %> | ||
<li class="dropdown"> | ||
<%= link_to t(".nav.skins.skins"), admin_skins_path %> | ||
<ul class="menu"> | ||
<li><%= link_to t(".nav.skins.queue"), admin_skins_path %></li> | ||
<li><%= link_to t(".nav.skins.approved"), index_approved_admin_skins_path %></li> | ||
<li><%= link_to t(".nav.skins.rejected"), index_rejected_admin_skins_path %></li> | ||
</ul> | ||
</li> | ||
<% end %> | ||
<li><%= link_to t(".nav.wrangling"), tag_wranglings_path %></li> | ||
|
||
<% if policy(Locale).index? %> | ||
<li><%= link_to ts("Locales", key: "header"), locales_path %></li> | ||
<% end %> | ||
<% if policy(Locale).index? %> | ||
<li><%= link_to t(".nav.locales"), locales_path %></li> | ||
<% end %> | ||
|
||
<% if policy(AdminActivity).index? %> | ||
<li><%= link_to ts("Activities", key: "header"), admin_activities_path %></li> | ||
<% end %> | ||
<% if policy(AdminActivity).index? %> | ||
<li><%= link_to t(".nav.activities"), admin_activities_path %></li> | ||
<% end %> | ||
|
||
<li><%= link_to ts("Manage API Tokens", key: "header"), admin_api_index_path %></li> | ||
</ul> | ||
<li><%= link_to t(".nav.api_tokens"), admin_api_index_path %></li> | ||
</ul> | ||
</nav> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,20 @@ | ||
<% # BACK END this seems giant and messy and confusing, pls can we review? | ||
# FRONT END yes let us rewrite this | ||
%> | ||
<% unless current_user && current_user.try(:preference).try(:banner_seen) %> | ||
<% if @admin_banner && @admin_banner.active? %> | ||
<% unless current_user.nil? && session[:hide_banner] %> | ||
<div class="<%= @admin_banner.banner_type %> announcement group" id="admin-banner"> | ||
<blockquote class="userstuff"> | ||
<%=raw sanitize_field(@admin_banner, :content) %> | ||
</blockquote> | ||
<% if current_user.nil? %> | ||
<p class="submit"> | ||
<%= link_to "×".html_safe, current_path_with(hide_banner: true), :class => 'showme action', :title => ts("hide banner") %> | ||
</p> | ||
<% else %> | ||
<%= form_tag end_banner_user_path(current_user), :method => :post, :remote => true do %> | ||
<% if @admin_banner&.active? %> | ||
<% unless session[:hide_banner] || current_user&.preference&.banner_seen %> | ||
<div class="<%= @admin_banner.banner_type %> announcement group" id="admin-banner"> | ||
<blockquote class="userstuff"> | ||
<%= raw sanitize_field(@admin_banner, :content, strip_images: true) %> | ||
</blockquote> | ||
<% if current_user.nil? %> | ||
<p class="submit"> | ||
<%= submit_tag "×".html_safe, :title => ts("hide banner") %> | ||
<%= link_to "×".html_safe, current_path_with(hide_banner: true), class: "showme action", title: ts("hide banner") %> | ||
</p> | ||
<% else %> | ||
<%= form_tag end_banner_user_path(current_user), method: :post, remote: true do %> | ||
<p class="submit"> | ||
<%= submit_tag "×".html_safe, title: ts("hide banner") %> | ||
</p> | ||
<% end %> | ||
<% end %> | ||
<% end %> | ||
</div> | ||
<% end %> | ||
<% end %> | ||
</div> | ||
<% end %> | ||
<% end %> |
Oops, something went wrong.