Remove turbo-frame tags in user views

This commit is contained in:
Andreas Nedbal 2022-09-08 00:48:01 +02:00 committed by Andreas Nedbal
parent c60acebf21
commit 5d88dfcb9c
3 changed files with 27 additions and 30 deletions

View File

@ -1,12 +1,11 @@
= turbo_frame_tag "user_questions" do
#questions
- @questions.each do |q|
= render 'shared/question', q: q, type: nil
#questions
- @questions.each do |q|
= render 'shared/question', q: q, type: nil
- if @more_data_available
.d-flex.justify-content-center.justify-content-sm-start#paginator
= button_to show_user_questions_path(@user, last_id: @questions_last_id), class: "btn btn-light" do
= t("voc.load")
- if @more_data_available
.d-flex.justify-content-center.justify-content-sm-start#paginator
= button_to show_user_questions_path(@user, last_id: @questions_last_id), class: "btn btn-light" do
= t("voc.load")
- provide(:title, questions_title(@user))
- parent_layout 'user/profile'

View File

@ -1,13 +1,12 @@
= turbo_frame_tag "user_answers" do
- unless @user.banned?
#answers
- @answers.each do |a|
= render 'answerbox', a: a
- unless @user.banned?
#answers
- @answers.each do |a|
= render 'answerbox', a: a
- if @more_data_available
.d-flex.justify-content-center.justify-content-sm-start#paginator
= button_to user_path(@user, last_id: @answers_last_id), class: "btn btn-light" do
= t("voc.load")
- if @more_data_available
.d-flex.justify-content-center.justify-content-sm-start#paginator
= button_to user_path(@user, last_id: @answers_last_id), class: "btn btn-light" do
= t("voc.load")
:ruby
provide(:title, user_title(@user))

View File

@ -1,17 +1,16 @@
= turbo_frame_tag "user_#{@type}" do
.row.row-cols-1.row-cols-sm-2.row-cols-md-3#users
- @users.each do |user|
.col.pb-3
= render 'shared/userbox', user: user, type: @type
.row.row-cols-1.row-cols-sm-2.row-cols-md-3#users
- @users.each do |user|
.col.pb-3
= render 'shared/userbox', user: user, type: @type
- if @more_data_available
.d-flex.justify-content-center.justify-content-sm-start#paginator
- if @type === :follower
= button_to show_user_followers_path(@user, last_id: @relationships_last_id), class: "btn btn-light" do
= t("voc.load")
- else
= button_to show_user_followings_path(@user, last_id: @relationships_last_id), class: "btn btn-light" do
= t("voc.load")
- if @more_data_available
.d-flex.justify-content-center.justify-content-sm-start#paginator
- if @type === :follower
= button_to show_user_followers_path(@user, last_id: @relationships_last_id), class: "btn btn-light" do
= t("voc.load")
- else
= button_to show_user_followings_path(@user, last_id: @relationships_last_id), class: "btn btn-light" do
= t("voc.load")
- provide(:title, user_title(@user, 'friends and followers'))
- parent_layout 'user/profile'