mirror of
https://github.com/Retrospring/retrospring.git
synced 2025-02-13 21:33:20 +01:00
Fix layout issues in questionbox
This commit is contained in:
parent
7513ef2b9e
commit
c124138a4a
2 changed files with 10 additions and 17 deletions
|
@ -6,17 +6,14 @@
|
|||
= @user.motivation_header
|
||||
.card-body
|
||||
- if @user.banned?
|
||||
.row
|
||||
.col-xs-12.text-center
|
||||
%strong= t 'views.questionbox.banned'
|
||||
.text-center
|
||||
%strong= t 'views.questionbox.banned'
|
||||
- else
|
||||
- if user_signed_in? or @user.privacy_allow_anonymous_questions?
|
||||
#question-box
|
||||
.row
|
||||
.col-xs-12
|
||||
%textarea.form-control{:name => "qb-question", :placeholder => t('views.placeholder.question')}
|
||||
%textarea.form-control{:name => "qb-question", :placeholder => t('views.placeholder.question')}
|
||||
.row{:style => "padding-top: 5px; padding-left: 5px; padding-right: 5px;"}
|
||||
.col-xs-6
|
||||
.col-6
|
||||
- if user_signed_in?
|
||||
- if @user.privacy_allow_anonymous_questions?
|
||||
%input{:name => "qb-anonymous", :type => "checkbox"}/
|
||||
|
@ -24,27 +21,23 @@
|
|||
%br/
|
||||
- else
|
||||
%input{:name => "qb-anonymous", :type => "hidden", :value => "false"}/
|
||||
.col-xs-6
|
||||
.col-6
|
||||
%p.pull-right
|
||||
%input{name: 'qb-to', type: 'hidden', :value => @user.id}/
|
||||
%button.btn.btn-primary{name: 'qb-ask', :type => "button", data: {loading_text: t('views.questionbox.load'), promote: user_signed_in? ? "false" : "true" }} Ask
|
||||
- unless user_signed_in?
|
||||
- if @user.privacy_allow_anonymous_questions?
|
||||
#question-box-promote.row{:style => "display: none;"}
|
||||
#question-box-promote{:style => "display: none;"}
|
||||
.row
|
||||
.col-xs-12.text-center
|
||||
.col-12.text-center
|
||||
%strong= t 'views.questionbox.promote.message'
|
||||
.row
|
||||
.col-sm-1
|
||||
.col-sm-5
|
||||
.col-sm-5.offset-sm-1
|
||||
%button#create-account.btn.btn-block.btn-primary= t 'views.questionbox.promote.create'
|
||||
.col-sm-5
|
||||
%button#new-question.btn.btn-block.btn-default= t 'views.questionbox.promote.another'
|
||||
.col-sm-1
|
||||
.row
|
||||
.col-sm-1
|
||||
.col-xs-12.col-sm-10.text-center
|
||||
.col-xs-12.col-sm-10.offset-sm-1.text-center
|
||||
%small= t('views.questionbox.promote.join', app_title: APP_CONFIG['site_name'])
|
||||
.col-sm-1
|
||||
- else
|
||||
%p= raw t 'views.questionbox.required', signup: link_to(t('views.sessions.new'),new_user_registration_path)
|
|
@ -1,6 +1,6 @@
|
|||
- no_header = unless @user.profile_header.exists? then "profile--no-header" else "" end
|
||||
.profile--panel-push-inner.hidden-xs{class: no_header}
|
||||
= render 'shared/questionbox'
|
||||
= render 'questionbox'
|
||||
- unless @user.banned?
|
||||
#answers
|
||||
- @answers.each do |a|
|
||||
|
|
Loading…
Reference in a new issue