35 lines
1.7 KiB
Plaintext
35 lines
1.7 KiB
Plaintext
.d-flex
|
|
- unless hide_avatar?
|
|
.flex-shrink-0
|
|
%a{ href: user_path(@question.user) }
|
|
= render AvatarComponent.new(user: @question.user, size: "md", classes: ["question__avatar"])
|
|
.flex-grow-1
|
|
%h6.text-muted.question__user
|
|
- if @question.author_is_anonymous
|
|
%span{ title: t(".anon_hint"), data: { controller: :tooltip, bs_placement: :bottom } }
|
|
%i.fas.fa-user-secret
|
|
- if @profile_question && @question.direct
|
|
- if user_signed_in? && @question.user == current_user
|
|
%span.d-inline-block{ title: t(".visible_to_you"), data: { controller: :tooltip, bs_placement: :bottom } }
|
|
%i.fa.fa-eye-slash
|
|
- elsif moderation_view?
|
|
%span{ title: t(".visible_mod_mode"), data: { controller: :tooltip, bs_placement: :bottom } }
|
|
%i.fa.fa-eye-slash
|
|
= user_screen_name(@question.user, context_user: @context_user, author_identifier: author_identifier)
|
|
- if follower_question?
|
|
·
|
|
%a{ href: question_path(@question.user.screen_name, @question.id), data: { selection_hotkey: "a" } }
|
|
= t(".answers", count: @question.answer_count)
|
|
·
|
|
= time_tooltip(@question)
|
|
- if user_signed_in?
|
|
.dropdown.d-inline
|
|
%button.btn.btn-link.btn-sm.p-0{ data: { bs_toggle: :dropdown }, aria: { expanded: false } }
|
|
%i.fa.fa-fw.fa-ellipsis
|
|
= render "actions/question", question: @question
|
|
.question__body{ data: { controller: @question.long? ? "collapse" : nil } }
|
|
.question__text{ class: @question.long? && @collapse ? "collapsed" : "", data: { collapse_target: "content" } }
|
|
= question_markdown @question.content
|
|
- if @question.long? && @collapse
|
|
= render "shared/collapse", type: "question"
|