Commit Graph

448 Commits (d0be8f6c99a28e0f38f6d46535d4c9378777ca14)

Author SHA1 Message Date
Eugen Rochko 764904edf3 Fix missing string for appeal validation error (#18410) 2022-05-14 06:51:59 +02:00
Eugen Rochko 41ad817afa Change RSS feeds (#18356)
* Change RSS feeds

- Use date and time for titles instead of ellipsized text
- Use full content in body, even when there is a content warning
- Use media extensions

* Change feed icons and add width and height attributes to custom emojis

* Fix custom emoji animate on hover breaking

* Fix tests
2022-05-09 07:43:08 +02:00
Claire 345dc4d102 Fix ambiguous wording on appeal actions (#18328)
Fixes #18322
2022-05-06 21:41:34 +02:00
Yamagishi Kazutoshi 95f81f574e Add translatable string for #17431 (#18227)
* Add translatable string for #17431

* Update config/locales/en.yml

Co-authored-by: Eugen Rochko <eugen@zeonfederated.com>

Co-authored-by: Eugen Rochko <eugen@zeonfederated.com>
2022-05-02 03:39:45 +02:00
Yamagishi Kazutoshi 9c42093e82 Add missing locale (#18061) 2022-04-21 20:26:10 +02:00
dependabot[bot] 9de4369d43 Bump i18n-tasks from 0.9.37 to 1.0.8 (#17993)
* Bump i18n-tasks from 0.9.37 to 1.0.8

Bumps [i18n-tasks](https://github.com/glebm/i18n-tasks) from 0.9.37 to 1.0.8.
- [Release notes](https://github.com/glebm/i18n-tasks/releases)
- [Changelog](https://github.com/glebm/i18n-tasks/blob/main/CHANGES.md)
- [Commits](https://github.com/glebm/i18n-tasks/compare/v0.9.37...v1.0.8)

---
updated-dependencies:
- dependency-name: i18n-tasks
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* Run `bundle exec i18n-tasks normalize`

* Add `admin_mailer.new_appeal.actions.*` to ignore_unused

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Yamagishi Kazutoshi <ykzts@desire.sh>
2022-04-08 20:14:50 +09:00
Eugen Rochko f982d56b4e Remove sign-in token authentication, instead send e-mail about new sign-in (#17970) 2022-04-06 20:58:12 +02:00
Ondřej Pokorný c3eacaecfe Update en.yml (#17942)
typo
2022-04-03 14:02:29 +02:00
Claire 1cd9fef010 Fix extra “zero” key in some plural translation strings (#17883) 2022-03-28 01:16:02 +02:00
Eugen Rochko 066703df31 Chore: i18n-tasks normalize (#17873) 2022-03-25 21:41:17 +01:00
Claire d17dfe4e87 Add admin dashboard checks for Elasticsearch version (#17863) 2022-03-25 21:00:59 +01:00
Claire 236bc22945 Add tooltip for instance delivery warnings (#17854) 2022-03-22 18:41:46 +01:00
Claire 981cd24311 Fix “edited at” in public pages not being properly localized (#17806)
Fixes #17804
2022-03-15 19:07:25 +01:00
Eugen Rochko ec22be2701 Fix not being able to upload GIF emojis in admin UI (#17759) 2022-03-14 05:45:22 +01:00
Claire c8f4894518 Change text version of warning mail to mention appeals instead of mails (#17725)
Also, the instruction to reply to e-mail would probably not work in many cases
where the notifications e-mail address is not able to receive incoming emails
or the mailbox is not actively monitored.
2022-03-09 12:11:11 +01:00
Eugen Rochko 11e848bf95 Change design of federation pages in admin UI (#17704)
* Change design of federation pages in admin UI

* Fix query performance in instance media attachments measure

* Fix reblogs being included in instance languages dimension
2022-03-09 08:52:32 +01:00
Eugen Rochko 563964dd80 Change appearance of account cards in web UI (#17689)
* Change appearance of account cards in web UI

* Various fixes and improvements

* Various fixes and improvements
2022-03-07 11:38:52 +01:00
Claire d8c9612493 Add option to automatically delete toots after one week (#17691)
Fixes #17658
2022-03-03 16:18:58 +01:00
Claire 102e3df7ca Redesign /about when already logged in (#17348)
* Redesign /about when already logged in

* Fix sign up form still showing when OMNIAUTH_ONLY is set

* Fix tests

* Change wording based on suggestions

Co-authored-by: Eugen Rochko <eugen@zeonfederated.com>

Co-authored-by: Eugen Rochko <eugen@zeonfederated.com>
2022-03-03 16:14:44 +01:00
Eugen Rochko dc23b3aeef Add descriptions to trending features in admin UI (#17677) 2022-03-02 18:57:44 +01:00
Eugen Rochko ec7a152446 Fix notification about deleted statuses being too threatening (#17679) 2022-03-01 23:07:57 +01:00
Eugen Rochko b25b703cce Add ability to mark statuses as sensitive from reports in admin UI (#17668)
* Add ability to mark statuses as sensitive from reports in admin UI

* Allow mark as sensitive action on statuses with preview cards
2022-03-01 22:20:29 +01:00
Claire 514842c9c6 Change old moderation strikes to be displayed in a separate page (#17566)
* Change old moderation strikes to be displayed in a separate page

Fixes #17552

This changes the moderation strikes displayed on `/auth/edit` to be those from
the past 3 months, and make all moderation strikes targeting the current user
available in `/disputes`.

* Add short description of what the strikes page is for

* Move link to list of strikes to “Account status” instead of navigation item

* Normalize i18n file

* Fix layout and styling of strikes link

* Revert highlights_on regexp

* Reintroduce account status summary

- this way, “Account status” is never empty
- account status is not necessarily bound to strikes, or recent strikes
2022-03-01 19:37:47 +01:00
Claire 2d5edf2090 Fix remote reports with comments revealing remote reporter (#17652)
* Display username rather than display name in report comment

For consistency with report notes and appeals

* Fix remote reports with comments revealing remote reporter

* Display instance name in placeholder

* Make instance name in report comment a link to the federation admin page

* Normalize i18n file
2022-02-26 21:14:12 +01:00
Eugen Rochko e6d2b07ec1 Add trending statuses (#17431)
* Add trending statuses

* Fix dangling items with stale scores in localized sets

* Various fixes and improvements

- Change approve_all/reject_all to approve_accounts/reject_accounts
- Change Trends::Query methods to not mutate the original query
- Change Trends::Query#skip to offset
- Change follow recommendations to be refreshed in a transaction

* Add tests for trending statuses filtering behaviour

* Fix not applying filtering scope in controller
2022-02-25 00:34:14 +01:00
Eugen Rochko ea5bf21a1d Change e-mail domain blocks to block IPs dynamically (#17635)
* Change e-mail domain blocks to block IPs dynamically

* Update app/workers/scheduler/email_domain_block_refresh_scheduler.rb

Co-authored-by: Yamagishi Kazutoshi <ykzts@desire.sh>

* Update app/workers/scheduler/email_domain_block_refresh_scheduler.rb

Co-authored-by: Yamagishi Kazutoshi <ykzts@desire.sh>

Co-authored-by: Yamagishi Kazutoshi <ykzts@desire.sh>
2022-02-24 17:28:23 +01:00
Eugen Rochko eef9eec5d3 Add notifications for new sign-ups (#16953) 2022-02-23 16:45:22 +01:00
Claire 9239d7173c Fix 0 pluralization for some localization strings (#17576)
Apparently, when the `zero` case is not defined, the translation string used
for `0` depends on the language. In French, `one` is used, causing some strings
with hardcoded “one” or `1` to misrepresent the actual data.

For instance, the dashboard would display « 1 utilisateur·rice en attente » for
both 0 and 1 pending users.
2022-02-16 14:57:57 +01:00
Eugen Rochko 82f8d19424 Add appeals (#17364)
* Add appeals

* Add ability to reject appeals and ability to browse pending appeals in admin UI

* Add strikes to account page in settings

* Various fixes and improvements

- Add separate notification setting for appeals, separate from reports
- Fix style of links in report/strike header
- Change approving an appeal to not restore statuses (due to federation complexities)
- Change style of successfully appealed strikes on account settings page
- Change account settings page to only show unappealed or recently appealed strikes

* Change appealed_at to overruled_at

* Fix missing method error
2022-02-14 21:27:53 +01:00
Eugen Rochko 8ffc48ebfa Add notifications when a reblogged status has been updated (#17404)
* Add notifications when a reblogged status has been updated

* Change wording to say "edit" instead of "update" and add missing controls

* Replace previous update notifications with the most up-to-date one
2022-02-11 22:20:19 +01:00
Eugen Rochko 9b42aad433 Change actions in reports to require only one click (#17487) 2022-02-11 21:51:57 +01:00
Eugen Rochko 2c9def57b3 Add `category` and `rule_ids` params to `POST /api/v1/reports` (#17492) 2022-02-10 00:10:16 +01:00
Eugen Rochko a44cc7931a Remove language detection through cld3 (#17478)
* Remove language detection through cld3

* Update app/helpers/languages_helper.rb

Co-authored-by: Yamagishi Kazutoshi <ykzts@desire.sh>

Co-authored-by: Yamagishi Kazutoshi <ykzts@desire.sh>
2022-02-08 02:41:17 +01:00
Claire 06f653972a Add OMNIAUTH_ONLY environment variable to enforce externa log-in (#17288)
* Remove support for OAUTH_REDIRECT_AT_SIGN_IN

Fixes #15959

Introduced in #6540, OAUTH_REDIRECT_AT_SIGN_IN allowed skipping the log-in form
to instead redirect to the external OmniAuth login provider.

However, it did not prevent the log-in form on /about introduced by #10232 from
appearing, and completely broke with the introduction of #15228.

As I restoring that previous log-in flow without introducing a security
vulnerability may require extensive care and knowledge of how OmniAuth works,
this commit removes support for OAUTH_REDIRECT_AT_SIGN_IN instead for the time
being.

* Add OMNIAUTH_ONLY environment variable to enforce external log-in only

* Disable user registration when OMNIAUTH_ONLY is set to true

* Replace log-in links When OMNIAUTH_ONLY is set with exactly one OmniAuth provider
2022-01-23 15:52:58 +01:00
Claire 68a9057420 Add post edited notice in admin and public UIs (#17335)
* Add edited toot flag on public pages

* Add toot edit flag to admin pages
2022-01-20 13:37:31 +01:00
Eugen Rochko 2fb76550a9 Add notifications for statuses deleted by moderators (#17204) 2022-01-17 09:41:33 +01:00
Claire 5aade2baac Add support for private pinned posts (#16954)
* Add support for private pinned toots

* Allow local user to pin private toots

* Change wording to avoid "direct message"
2022-01-17 00:49:55 +01:00
Claire d8da1689c1 Add ability for admins to delete canonical email blocks (#16644)
* Add admin option to remove canonical email blocks from a deleted account

* Add tootctl canonical_email_blocks to inspect and remove canonical email blocks
2021-12-17 23:02:14 +01:00
Claire 44c8b6ff2f Add ability to purge undeliverable domains from admin interface (#16686)
* Add ability to purge undeliverable domains from admin interface

* Add tests
2021-12-17 23:01:21 +01:00
Claire 58178dca25 Fix incorrect singular version of some translation strings (#17124)
Fixes #17120

Co-authored-by: Mélanie Chauvel <perso@hack-libre.org>

Co-authored-by: Mélanie Chauvel <perso@hack-libre.org>
2021-12-13 18:25:25 +01:00
Eugen Rochko 7bf5924339 Add batch suspend for accounts in admin UI (#17009) 2021-12-05 21:48:39 +01:00
Eugen Rochko 4375813ea7 Remove Keybase integration (#17045) 2021-11-26 05:58:18 +01:00
Eugen Rochko ad73becf3e Add trending links (#16917)
* Add trending links

* Add overriding specific links trendability

* Add link type to preview cards and only trend articles

Change trends review notifications from being sent every 5 minutes to being sent every 2 hours

Change threshold from 5 unique accounts to 15 unique accounts

* Fix tests
2021-11-25 13:07:38 +01:00
Jeong Arm 95688e49b7 Allow keeping only 1 boosts/favs on auto deleting posts (#16653)
* Allow keeping 1 boosts/favs on auto deleting posts

* Fix tests
2021-10-14 21:11:14 +02:00
Eugen Rochko cad446611c Add graphs and retention metrics to admin dashboard (#16829) 2021-10-14 20:44:59 +02:00
Claire 4893216634 Fix suspicious sign-in mail text being out of date (#16690)
Fixes #16687
2021-09-04 16:44:50 +02:00
Claire 1fcf310c60 Add feature to automatically delete old toots (#16529)
* Add account statuses cleanup policy model

* Record last inspected toot to delete to speed up successive calls to statuses_to_delete

* Add service to cleanup a given account's statuses within a budget

* Add worker to go through account policies and delete old toots

* Fix last inspected status id logic

All existing statuses older or equal to last inspected status id must be
kept by the current policy. This is an invariant that must be kept so that
resuming deletion from the last inspected status remains sound.

* Add tests

* Refactor scheduler and add tests

* Add user interface

* Add support for discriminating based on boosts/favs

* Add UI support for min_reblogs and min_favs, rework UI

* Address first round of review comments

* Replace Snowflake#id_at_start with with_random parameter

* Add tests

* Add tests for StatusesCleanupController

* Rework settings page

* Adjust load-avoiding mechanisms

* Please CodeClimate
2021-08-09 23:11:50 +02:00
Eugen Rochko 2bc9e256cc Add ability to filter reports by origin of target account (#16487) 2021-07-11 11:01:38 +02:00
Eugen Rochko 34dd743b58 Add ability to skip sign-in token authentication for specific users (#16427)
Remove "active within last two weeks" exception for sign in token requirement

Change admin reset password to lock access until the password is reset
2021-07-08 05:31:28 +02:00
Eugen Rochko 2067b0bf34 Add authentication history (#16408) 2021-06-21 17:07:30 +02:00