diff --git a/app/views/moderation/inbox/_header.haml b/app/views/moderation/inbox/_header.haml new file mode 100644 index 00000000..54ca1cd6 --- /dev/null +++ b/app/views/moderation/inbox/_header.haml @@ -0,0 +1,8 @@ +.card.question--fixed{ class: hidden ? 'question--hidden' : '', tabindex: hidden ? -1 : '', aria: { hidden: hidden } } + .container + .card-body + .media + %a.pull-left{ href: show_user_profile_path(user.screen_name) } + %img.answerbox__question-user-avatar.avatar-md{ src: user.profile_picture.url(:medium) } + .media-body + = t(".title_html", screen_name: user.screen_name, user_id: user.id) \ No newline at end of file diff --git a/app/views/moderation/inbox/index.haml b/app/views/moderation/inbox/index.haml index 36b2ddc7..c80f0f79 100644 --- a/app/views/moderation/inbox/index.haml +++ b/app/views/moderation/inbox/index.haml @@ -1,16 +1,8 @@ - provide(:title, generate_title(t(".title", user: @user.screen_name))) -.card.question--fixed - .container - .card-body - .media - %a.pull-left{ href: show_user_profile_path(@user.screen_name) } - %img.answerbox__question-user-avatar.avatar-md{ src: @user.profile_picture.url(:medium) } - .media-body - Viewing inbox for - %br - %strong= @user.screen_name - = " (##{@user.id})" += render "header", user: @user, hidden: false += render "header", user: @user, hidden: true + .container-lg.container--main #entries - @inboxes.each do |i| diff --git a/app/views/user/_actions.haml b/app/views/user/_actions.haml index ead0c139..c1e3c437 100644 --- a/app/views/user/_actions.haml +++ b/app/views/user/_actions.haml @@ -39,7 +39,7 @@ - if current_user.mod? && user != current_user %a.dropdown-item{ href: mod_inbox_index_path(user: user.screen_name) } %i.fa.fa-inbox - View inbox + = t("views.actions.view_inbox") - if current_user.has_role? :administrator %a.dropdown-item{ href: rails_admin_path_for_resource(user), target: '_blank' } %i.fa.fa-cogs diff --git a/config/locales/en.yml b/config/locales/en.yml index 21bb3b11..b7be786b 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -221,6 +221,7 @@ en: subscribe: "Subscribe" unsubscribe: "Unsubscribe" view: "View comment smiles" + view_inbox: "View inbox" load: "Load more" follow: "Follow" unfollow: "Unfollow" diff --git a/config/locales/views.en.yml b/config/locales/views.en.yml index 5d16a7d3..c23e871a 100644 --- a/config/locales/views.en.yml +++ b/config/locales/views.en.yml @@ -328,5 +328,7 @@ en: title: "Export" moderation: inbox: + header: + title_html: "Viewing inbox for
%{screen_name} (#%{user_id})" index: title: "Inbox for %{user}"