Refactored generation of unique tags, URIs and object URLs into own classes,

as well as formatting of content
This commit is contained in:
Eugen Rochko
2016-09-09 20:04:34 +02:00
parent 735b4cc62e
commit 3cc47beb6e
28 changed files with 316 additions and 180 deletions

View File

@ -2,4 +2,4 @@
.content
%strong= link_to follow.account.acct, account_path(follow.account)
is now following
%strong= link_to follow.target_account.acct, url_for_target(follow.target_account)
%strong= link_to follow.target_account.acct, TagManager.instance.url_for(follow.target_account)

View File

@ -12,7 +12,7 @@
.pre-header
%i.fa.fa-retweet
Shared by
= link_to display_name(status.account), url_for_target(status.account), class: 'name'
= link_to display_name(status.account), TagManager.instance.url_for(status.account), class: 'name'
.entry__container
.avatar
@ -21,10 +21,10 @@
.entry__container__container
.header
.header__left
= link_to url_for_target(proper_status(status).account), class: 'name' do
= link_to TagManager.instance.url_for(proper_status(status).account), class: 'name' do
%strong= display_name(proper_status(status).account)
= "@#{proper_status(status).account.acct}"
= link_to url_for_target(proper_status(status)), class: 'time' do
= link_to TagManager.instance.url_for(proper_status(status)), class: 'time' do
%span{ title: proper_status(status).created_at }
= relative_time(proper_status(status).created_at)
@ -36,7 +36,7 @@
%i.fa.fa-star
%span.counter-number= proper_status(status).favourites_count
.content= content_for_status(proper_status(status))
.content= Formatter.instance.format(proper_status(status))
%ul.media-attachments
- status.media_attachments.each do |media|