]> cat aescling's git repositories - mastodon.git/commit
Refactor formatter (#17828)
authorEugen Rochko <eugen@zeonfederated.com>
Sat, 26 Mar 2022 01:53:34 +0000 (02:53 +0100)
committerGitHub <noreply@github.com>
Sat, 26 Mar 2022 01:53:34 +0000 (02:53 +0100)
commitcefa526c6d3a45df2d0fcb7643ced828e2e87dea
treee3d19aa7d0881ae59d25692fb0c16b781c691b40
parent2dd30804b62f750c2780b7043318cbe00d137429
Refactor formatter (#17828)

* Refactor formatter

* Move custom emoji pre-rendering logic to view helpers

* Move more methods out of Formatter

* Fix code style issues

* Remove Formatter

* Add inline poll options to RSS feeds

* Remove unused helper method

* Fix code style issues

* Various fixes and improvements

* Fix test
44 files changed:
app/chewy/statuses_index.rb
app/controllers/api/web/embeds_controller.rb
app/helpers/accounts_helper.rb
app/helpers/admin/trends/statuses_helper.rb
app/helpers/application_helper.rb
app/helpers/formatting_helper.rb [new file with mode: 0644]
app/helpers/routing_helper.rb
app/helpers/statuses_helper.rb
app/lib/activitypub/activity/create.rb
app/lib/emoji_formatter.rb [new file with mode: 0644]
app/lib/extractor.rb
app/lib/feed_manager.rb
app/lib/formatter.rb [deleted file]
app/lib/html_aware_formatter.rb [new file with mode: 0644]
app/lib/plain_text_formatter.rb [new file with mode: 0644]
app/lib/rss/serializer.rb
app/lib/text_formatter.rb [new file with mode: 0644]
app/mailers/application_mailer.rb
app/serializers/activitypub/actor_serializer.rb
app/serializers/activitypub/note_serializer.rb
app/serializers/rest/account_serializer.rb
app/serializers/rest/announcement_serializer.rb
app/serializers/rest/status_edit_serializer.rb
app/serializers/rest/status_serializer.rb
app/services/fetch_link_card_service.rb
app/views/accounts/_bio.html.haml
app/views/admin/accounts/show.html.haml
app/views/admin/reports/_status.html.haml
app/views/admin/reports/show.html.haml
app/views/directories/index.html.haml
app/views/disputes/strikes/show.html.haml
app/views/notification_mailer/_status.html.haml
app/views/notification_mailer/_status.text.erb
app/views/notification_mailer/digest.text.erb
app/views/statuses/_detailed_status.html.haml
app/views/statuses/_poll.html.haml
app/views/statuses/_simple_status.html.haml
app/views/user_mailer/warning.html.haml
config/initializers/twitter_regex.rb
spec/lib/emoji_formatter_spec.rb [new file with mode: 0644]
spec/lib/formatter_spec.rb [deleted file]
spec/lib/html_aware_formatter.rb [new file with mode: 0644]
spec/lib/plain_text_formatter_spec.rb [new file with mode: 0644]
spec/lib/text_formatter_spec.rb [new file with mode: 0644]