From 1e038cb1801857fd201edcb509315fedb9260a07 Mon Sep 17 00:00:00 2001 From: Star Rauchenberger Date: Fri, 6 Dec 2024 23:07:36 -0500 Subject: Added h-entry annotations to quotes --- app/views/quotes/_quote.html.haml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'app/views') diff --git a/app/views/quotes/_quote.html.haml b/app/views/quotes/_quote.html.haml index db6ab8b..acbab10 100644 --- a/app/views/quotes/_quote.html.haml +++ b/app/views/quotes/_quote.html.haml @@ -1,15 +1,17 @@ -%article.quote{ :id => "quote-#{quote.id}" } +%article.quote.h-entry{ :id => "quote-#{quote.id}" } + %data.p-name{ value: "\##{quote.id}" } + %data.u-url{ value: url_for(quote) } %header.quote-header{ :id => "quote-header-#{quote.id}" } = link_to_unless (quote.new_record? or current_page?(quote)), "\##{quote.id}", quote, :class => "quote-link" %span.vote-link{ :id => "quote-upvote-link-#{quote.id}" }= link_to_unless (quote.new_record? or quote.already_upvoted?(request.remote_ip)), "Up", upvote_quote_path(quote.id), :remote => true, :rel => "nofollow", :class => "quote-upvote-link", method: :post %span.quote-rating{ :id => "quote-rating-#{quote.id}" }= "+#{quote.upvotes}/-#{quote.downvotes}" %span.vote-link{ :id => "quote-downvote-link-#{quote.id}" }= link_to_unless (quote.new_record? or quote.already_downvoted?(request.remote_ip)), "Down", downvote_quote_path(quote.id), :remote => true, :rel => "nofollow", :class => "quote-downvote-link", method: :post - %datetime= quote.published_date + %time.dt-published{ datetime: quote.created_at.strftime("%Y-%m-%dT%H:%M:%SZ%z") }= quote.published_date - if user_signed_in? and !quote.new_record? = link_to "Edit", edit_admin_quote_path(quote), :class => "quote-edit-link" - if quote.audio.attached? .audioplayer= audio_tag(rails_blob_url(quote.audio), controls: true) - %blockquote.quote-body= raw quote_format(h(quote.content)) + %blockquote.quote-body.e-content= raw quote_format(h(quote.content)) - if !quote.new_record? and quote.has_extra? .quote-footer - if quote.has_notes? -- cgit 1.4.1