ayyyy vodka
This commit is contained in:
parent
19cf4da0e8
commit
2caf81d08e
|
@ -1,7 +1,7 @@
|
|||
.container.j2-page
|
||||
= render 'layouts/messages'
|
||||
- @inbox.each do |i|
|
||||
.panel.inbox-box{'data-id' => i.id, class: "panel-#{i.new? ? 'primary' : 'default'}" }
|
||||
.panel.inbox-box{class: "panel-#{i.new? ? 'primary' : 'default'}", data: { id: i.id }}
|
||||
.panel-heading
|
||||
.media
|
||||
- unless i.question.author_is_anonymous
|
||||
|
@ -20,11 +20,11 @@
|
|||
#{i.question.answer_count} response(s)
|
||||
%p.answerbox-question-text= i.question.content
|
||||
.panel-body
|
||||
%textarea.form-control{name: 'ib-answer', 'data-id' => i.id}
|
||||
%textarea.form-control{name: 'ib-answer', data: { id: i.id }}
|
||||
%br/
|
||||
%button.btn.btn-success{name: 'ib-answer', 'data-ib-id' => i.id}
|
||||
%button.btn.btn-success{name: 'ib-answer', data: { id: i.id }}
|
||||
Answer
|
||||
%button.btn.btn-danger{name: 'ib-destroy', 'data-ib-id' => i.id}
|
||||
%button.btn.btn-danger{name: 'ib-destroy', data: { id: i.id }}
|
||||
Delete
|
||||
|
||||
- if @inbox.empty?
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
.panel.panel-default.answer-box{'data-id' => a.id}
|
||||
.panel.panel-default.answer-box{data: { id: a.id }}
|
||||
- if @question.nil?
|
||||
.panel-heading
|
||||
.media
|
||||
|
|
|
@ -5,16 +5,16 @@
|
|||
users smiled this
|
||||
- if user_signed_in?
|
||||
- if current_user.smiled? a
|
||||
%button.btn.btn-info.btn-sm{type: :button, name: 'ab-smile', 'data-a-id' => a.id, 'data-action' => 'unsmile'}
|
||||
%button.btn.btn-info.btn-sm{type: :button, name: 'ab-smile', data: { a_id: a.id, action: :unsmile }}
|
||||
%i.fa.fa-frown-o
|
||||
%span{id: "ab-smile-count-#{a.id}"}= a.smile_count
|
||||
- else
|
||||
%button.btn.btn-info.btn-sm{type: :button, name: 'ab-smile', 'data-a-id' => a.id, 'data-action' => 'smile'}
|
||||
%button.btn.btn-info.btn-sm{type: :button, name: 'ab-smile', data: { a_id: a.id, action: :smile }}
|
||||
%i.fa.fa-smile-o
|
||||
%span{id: "ab-smile-count-#{a.id}"}= a.smile_count
|
||||
%button.btn.btn-primary.btn-sm{type: :button, name: 'ab-comments', 'data-a-id' => a.id, 'data-state' => :hidden}
|
||||
%button.btn.btn-primary.btn-sm{type: :button, name: 'ab-comments', data: { a_id: a.id, state: :hidden }}
|
||||
%i.fa.fa-comments
|
||||
%span{id: "ab-comment-count-#{a.id}"}= a.comment_count
|
||||
- if privileged? a.user
|
||||
%button.btn.btn-danger.btn-sm{name: 'ab-destroy', 'data-a-id' => a.id}
|
||||
%button.btn.btn-danger.btn-sm{name: 'ab-destroy', data: { a_id: a.id }}
|
||||
%i.fa.fa-trash-o
|
|
@ -3,11 +3,11 @@
|
|||
- else # TODO: some design guy (i.e. pixeldesu) should make some black magic here
|
||||
%ul.comments
|
||||
- a.comments.all.each do |comment|
|
||||
%li{'data-comment-id' => comment.id}
|
||||
%li{data: { comment_id: comment.id }}
|
||||
%img.img-answerbox-small{src: gravatar_url(comment.user)}
|
||||
%b= user_screen_name comment.user
|
||||
= comment.content
|
||||
- if user_signed_in?
|
||||
.form-group.has-feedback{name: 'ab-comment-new-group', 'data-a-id' => a.id}
|
||||
%input.form-control{type: :text, placeholder: 'Comment...', name: 'ab-comment-new', 'data-a-id' => a.id}
|
||||
%input.form-control{type: :text, placeholder: 'Comment...', name: 'ab-comment-new', data: {a_id: a.id }}
|
||||
%span.text-muted.form-control-feedback.comment-count{id: "ab-comment-charcount-#{a.id}"} 160
|
|
@ -10,4 +10,4 @@
|
|||
%textarea.form-control{:name => "qb-all-question", :placeholder => "Type your question here…"}
|
||||
.modal-footer
|
||||
%button.btn.btn-default{"data-dismiss" => "modal", :type => "button"} Cancel
|
||||
%button.btn.btn-primary{name: 'qb-all-ask', 'data-loading-text' => "Asking...", :type => "button"} Ask
|
||||
%button.btn.btn-primary{name: 'qb-all-ask', :type => "button", data: {loading_text: 'Asking...' }} Ask
|
|
@ -19,7 +19,7 @@
|
|||
.col-xs-6
|
||||
%p.pull-right
|
||||
%input{name: 'qb-to', type: 'hidden', :value => @user.id}/
|
||||
%button.btn.btn-primary{name: 'qb-ask', 'data-loading-text' => "Asking...", "data-promote" => user_signed_in? ? "false" : "true", :type => "button"} Ask
|
||||
%button.btn.btn-primary{name: 'qb-ask', :type => "button", data: {loading_text: 'Asking...', promote: user_signed_in? ? "false" : "true" }} Ask
|
||||
- unless user_signed_in?
|
||||
#question-box-promote.row{:style => "display: none;"}
|
||||
.row
|
||||
|
|
|
@ -44,7 +44,7 @@
|
|||
#pagination= will_paginate @timeline, renderer: BootstrapPagination::Rails, page_links: false
|
||||
|
||||
- if @timeline.next_page
|
||||
%button#load-more-btn.btn.btn-default{type: :button, 'data-current-page' => @timeline.current_page}
|
||||
%button#load-more-btn.btn.btn-default{type: :button, data: { current_page: @timeline.current_page }}
|
||||
Load more
|
||||
.visible-xs= render 'shared/links'
|
||||
- else
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
%a.btn.btn-default.btn-block{href: edit_user_profile_path} Edit profile
|
||||
- else
|
||||
- if current_user.following? @user
|
||||
%button#editprofile.btn.btn-default.btn-block{type: :button, name: 'user-action', 'data-action' => :unfollow, 'data-target' => @user.screen_name}
|
||||
%button#editprofile.btn.btn-default.btn-block{type: :button, name: 'user-action', data: { action: :unfollow, target: @user.screen_name }}
|
||||
Unfollow
|
||||
- else
|
||||
%button#editprofile.btn.btn-primary.btn-block{type: :button, name: 'user-action', 'data-action' => :follow, 'data-target' => @user.screen_name}
|
||||
%button#editprofile.btn.btn-primary.btn-block{type: :button, name: 'user-action', data: { action: :follow, target: @user.screen_name }}
|
||||
Follow
|
|
@ -50,6 +50,6 @@
|
|||
#pagination= will_paginate @answers, renderer: BootstrapPagination::Rails, page_links: false
|
||||
|
||||
- if @answers.next_page
|
||||
%button#load-more-btn.btn.btn-default{type: :button, 'data-current-page' => @answers.current_page}
|
||||
%button#load-more-btn.btn.btn-default{type: :button, data: { current_page: @answers.current_page }}
|
||||
Load more
|
||||
.visible-xs= render 'shared/links'
|
||||
|
|
Loading…
Reference in New Issue