Improve profile style

This commit is contained in:
Jesse C. Fisher 2023-11-08 17:38:38 +00:00 committed by TheNeedful-DO
parent 22bcbb5961
commit afcadd2a26
5 changed files with 17 additions and 37 deletions

View File

@ -24,7 +24,8 @@ a
h1
font-size: 7vmin
margin: 0 0 5vmin 0
width: 100%
text-align: center
header
font-size: 3vmin
@ -55,6 +56,9 @@ header
background: #00ff0060
border-radius: 0 18em 0 0
font-size: 2em
> h1
padding-top: .6em
text-indent: -7.5em
#home-headline, .home-headline
@ -73,13 +77,6 @@ header
background-color: #33cc3399
#main-menu
// transition: all 12s ease-out
// padding: 40px
// bottom: 0
// position: relative
// display: inline-block
// margin-top: 15em
// top: 97px
flex: 1 1 auto
font-size: 5vmin
display: flex

View File

@ -15,7 +15,7 @@ a .profile
text-align: center
position: relative
background: #40a10b
background: linear-gradient(90deg, #e1b02777 0%, rgba(0,0,0,0) 88%)
background: linear-gradient(90deg, rgba(0,0,0,0) 0%, #e1b02777 47%, rgba(0, 0, 0, 0) 95%)
> a
padding: 0 1em
.dscvr-logo, .x-logo

View File

@ -1,39 +1,27 @@
%h1 Listing profiles
%p
%div{style: "align-self: start; padding-left: .8em;"}
- if policy(Profile).new?
= link_to '+ New Profile', new_profile_path
- else
= link_to 'Sign In', new_user_session_path
to create a new Profile
-# %table
-# %thead
-# %tr
-# %th User
-# %th Name
-# %th Summary
-# %th About
-# - if policy(Profile).destroy?
-# %th
-# %th
-# %tbody
- @profiles.each do |profile|
%tr
-# %td= profile.user
%td= link_to profile.name, profile
%td= profile.summary
%td= profile.about
-# - if policy(profile).destroy?
-# %td= link_to 'Edit', edit_profile_path(profile)
-# %td= link_to 'Destroy', profile, method: :delete, data: { confirm: 'Are you sure?' }
- @profiles.each do |profile|
= link_to profile do
.profile
%h1= profile.name
%span= profile.summary
-# = link_to "", "#"
.social-links
- profile.social_links.each do |social_link|
- if policy(social_link).destroy?
%span.controls
= link_to '📝', edit_social_link_path(social_link)
= link_to '❌', social_link, method: :delete, data: { confirm: 'Are you sure?' }
= social_link.to_icon.html_safe
- if policy(profile).edit?
%br= link_to '+ Add Social Link', new_social_link_path(profile_id: profile.id)
%p= profile.about
- if policy(profile).destroy?
= link_to 'Edit', edit_profile_path(profile)

View File

@ -1,6 +1,3 @@
:css
#content { padding-top: 3em; }
- if policy(@profile).edit?
.contain
= link_to 'Edit', edit_profile_path(@profile)

View File

@ -1,5 +1,3 @@
%h1 New social_link
= render 'form'
= link_to 'Back', social_links_path