diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2017-01-25 00:49:08 +0100 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2017-01-25 01:29:16 +0100 |
commit | 999cde94a6a2d67cf36160365378951d3b55b868 (patch) | |
tree | 51d86739522f79ee545f7c821507997f0a4914cb /app/views | |
parent | f8da0dd4907490f57cb14b052b767c66c95c4db3 (diff) |
Instead of using spoiler boolean and spoiler_text, simply check for non-blank spoiler_text
Federate spoiler_text using warning attribute on <content /> instead of a <category term="spoiler" /> Clean up schema file from accidental development migrations
Diffstat (limited to 'app/views')
-rw-r--r-- | app/views/api/v1/statuses/_show.rabl | 2 | ||||
-rw-r--r-- | app/views/stream_entries/_detailed_status.html.haml | 5 | ||||
-rw-r--r-- | app/views/stream_entries/_simple_status.html.haml | 5 |
3 files changed, 9 insertions, 3 deletions
diff --git a/app/views/api/v1/statuses/_show.rabl b/app/views/api/v1/statuses/_show.rabl index 8b54d5852..7309a78b8 100644 --- a/app/views/api/v1/statuses/_show.rabl +++ b/app/views/api/v1/statuses/_show.rabl @@ -1,4 +1,4 @@ -attributes :id, :created_at, :in_reply_to_id, :sensitive, :spoiler, :visibility +attributes :id, :created_at, :in_reply_to_id, :sensitive, :spoiler_text, :visibility node(:uri) { |status| TagManager.instance.uri_for(status) } node(:content) { |status| Formatter.instance.format(status) } diff --git a/app/views/stream_entries/_detailed_status.html.haml b/app/views/stream_entries/_detailed_status.html.haml index bc09d3597..6ee8c9e5b 100644 --- a/app/views/stream_entries/_detailed_status.html.haml +++ b/app/views/stream_entries/_detailed_status.html.haml @@ -7,7 +7,10 @@ %strong.p-name.emojify= display_name(status.account) %span.p-nickname= acct(status.account) - .status__content.e-content.p-name.emojify= Formatter.instance.format(status) + .status__content.e-content.p-name.emojify< + - unless status.spoiler_text.blank? + %p= status.spoiler_text + = Formatter.instance.format(status) - unless status.media_attachments.empty? - if status.media_attachments.first.video? diff --git a/app/views/stream_entries/_simple_status.html.haml b/app/views/stream_entries/_simple_status.html.haml index eba2f9ac4..95f90abd9 100644 --- a/app/views/stream_entries/_simple_status.html.haml +++ b/app/views/stream_entries/_simple_status.html.haml @@ -12,7 +12,10 @@ %strong.p-name.emojify= display_name(status.account) %span.p-nickname= acct(status.account) - .status__content.e-content.p-name.emojify= Formatter.instance.format(status) + .status__content.e-content.p-name.emojify< + - unless status.spoiler_text.blank? + %p= status.spoiler_text + = Formatter.instance.format(status) - unless status.media_attachments.empty? .status__attachments |