From 2c4a0be0f59c4ed0a80415be4fcc663a6f0a67e3 Mon Sep 17 00:00:00 2001 From: Gabriel Manika Koeb Date: Wed, 14 Feb 2024 19:50:04 -0300 Subject: [PATCH 1/8] Style/melhora layout da homepage MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Altera cor de fundo da aplicação. Melhora alinhamento de algumas divs. GyodaiDDA --- .../stylesheets/application.bootstrap.scss | 6 ++++ app/assets/stylesheets/layout.scss | 17 +++++++++++ app/assets/stylesheets/posts.scss | 9 ++++++ app/views/home/index.html.erb | 29 +++++++++++-------- app/views/posts/_listing.html.erb | 4 +-- app/views/posts/show.html.erb | 6 ++-- app/views/profiles/_profile_details.html.erb | 10 +++---- app/views/profiles/show.html.erb | 2 +- app/views/shared/_navbar.html.erb | 2 +- db/schema.rb | 4 +-- db/seeds/superseed.rb | 15 ++++++++-- .../posts/user_edits_post_status_spec.rb | 2 -- 12 files changed, 75 insertions(+), 31 deletions(-) diff --git a/app/assets/stylesheets/application.bootstrap.scss b/app/assets/stylesheets/application.bootstrap.scss index 12c3489..d660425 100644 --- a/app/assets/stylesheets/application.bootstrap.scss +++ b/app/assets/stylesheets/application.bootstrap.scss @@ -19,8 +19,13 @@ $primary: #a130fd; @import 'profile.scss'; @import 'layout.scss'; +:root{ + font-size: 0.8rem; +} + body{ min-width: 400px; + background-color: #F6F7F8 !important; } input[type="checkbox"]:checked { @@ -69,6 +74,7 @@ input[type="checkbox"]:checked { .trix-content{ color: rgb(10, 10, 10); + text-align: left !important; } .dropdown-item:active { diff --git a/app/assets/stylesheets/layout.scss b/app/assets/stylesheets/layout.scss index 23973fc..97b86ce 100644 --- a/app/assets/stylesheets/layout.scss +++ b/app/assets/stylesheets/layout.scss @@ -26,3 +26,20 @@ input[type="checkbox"]:checked { .categories{ width: 35% !important; } + +.most-followed-users{ + size: 22rem; +} + +.most-followed-title{ + margin-bottom: 2px !important; +} + +.most-followed-cards{ + padding: 1rem !important; + margin-bottom: 2px !important; +} + +.most-followed-cards a{ + text-decoration: none !important; +} diff --git a/app/assets/stylesheets/posts.scss b/app/assets/stylesheets/posts.scss index 6329e43..c83926a 100644 --- a/app/assets/stylesheets/posts.scss +++ b/app/assets/stylesheets/posts.scss @@ -5,4 +5,13 @@ .trix-content{ color: rgb(10, 10, 10); + text-align: left !important; +} + +.post-title{ + font-size: 1.8rem; +} + +figure.attachment{ + width: 50% !important; } \ No newline at end of file diff --git a/app/views/home/index.html.erb b/app/views/home/index.html.erb index 3d4861f..63add0f 100644 --- a/app/views/home/index.html.erb +++ b/app/views/home/index.html.erb @@ -1,8 +1,8 @@
<% if user_signed_in? %>
+
-

<%= t('.feed') %>

<% if current_user.profile.followed_count > 0 %> <% if @followed_posts.any? %>
@@ -10,29 +10,34 @@
<% else %>
-

<%= t('.what_people_are_posting') %>:

+
<%= t('.what_people_are_posting') %>:
<%= render partial: 'posts/listing', locals: { posts: @posts } %>
<% end %> <% else %>
-

<%= t('.follow_someone') %>

+
<%= t('.follow_someone') %>
<%= render partial: 'posts/listing', locals: { posts: @posts } %>
<% end %>