Style microposts

This commit is contained in:
Jesse C. Fisher 2023-11-21 09:26:09 +00:00
parent 38e983ce08
commit eec022a47b
2 changed files with 17 additions and 5 deletions

View File

@ -5,3 +5,14 @@
color: #ddd
box-shadow: 0px 0px 0px 10px black inset, 0px 0px 0px 43px white inset, 0px 0px 116px 62px black inset
rotate: -36deg
.micropost
.display-name, .timestamp
font-family: "Press Start 2P", "Anton", Impact, fantasy, sans-serif
font-size: .4em
margin: 1em
padding: 1em
background: #ffffff33
.content
font-family: sans
font-size: .8em
text-shadow: none

View File

@ -1,6 +1,7 @@
%li{id: "micropost-#{micropost.id}"}
%span= link_to micropost.micropostable.display_name, micropost.micropostable
%li.micropost{id: "micropost-#{micropost.id}"}
%div
%span.display-name= link_to micropost.micropostable.display_name, micropost.micropostable
%span.timestamp #{time_ago_in_words(micropost.created_at)} ago.
- if policy(micropost).destroy?
%span= link_to "❌", micropost, method: :delete, data: { confirm: 'Are you sure?' }
%span.content= micropost.content
%span.timestamp Posted #{time_ago_in_words(micropost.created_at)} ago.
- if policy(micropost).destroy?
%span= link_to "❌", micropost, method: :delete, data: { confirm: 'Are you sure?' }