Commit graph

58 commits

Author SHA1 Message Date
KMY
d35fa72842 Merge remote-tracking branch 'parent/main' into upstream-20240109 2025-01-09 13:20:56 +09:00
Claire
7d6da219c0
Remove old notifications actions and reducers (#31843) 2025-01-03 16:12:08 +00:00
KMY
66bed31dbe Merge remote-tracking branch 'parent/main' into upstream-20241006 2024-10-05 09:10:58 +09:00
Nick Schonning
f91f077985
Enable ESLlint no-case-declarations (#30768) 2024-10-01 16:26:30 +00:00
KMY
4ce35dd837 Merge remote-tracking branch 'parent/main' into upstream-20240918 2024-09-18 08:31:34 +09:00
Claire
c620452fd7
Enable grouped notifications unconditionally (#31929) 2024-09-16 13:12:10 +00:00
KMY
fc9d27ff91 Merge remote-tracking branch 'parent/main' into upstream-20240913 2024-09-13 10:31:48 +09:00
renovate[bot]
a27f7f4e56
Update typescript-eslint monorepo to v8 (major) (#31231)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Renaud Chaput <renchap@gmail.com>
2024-09-11 13:59:46 +00:00
KMY
b39054ff3c Merge remote-tracking branch 'parent/main' into upstream-20240828 2024-08-28 20:26:35 +09:00
Claire
c73868cd78
Add ability for admins to force grouped notifications in web UI (#31610) 2024-08-27 14:55:51 +00:00
KMY
55f11765ea Merge remote-tracking branch 'parent/main' into upstream-20240822 2024-08-22 09:18:29 +09:00
Claire
d67e11733e
Add automatic notification polling for grouped notifications (#31513) 2024-08-21 14:41:31 +00:00
KMY
af0f8f01e1 Merge remote-tracking branch 'parent/main' into upstream-20240821 2024-08-21 12:39:30 +09:00
Claire
53c183f899
Reload notifications when accepted notifications are merged (streaming only) (#31419) 2024-08-19 15:59:06 +00:00
Claire
1e612c5a09
Refactor some actions to be proper async actions instead of passing a continuation (#31453) 2024-08-19 14:41:32 +00:00
KMY
e7ccc0539f Merge remote-tracking branch 'parent/main' into upstream-20240813 2024-08-13 07:01:38 +09:00
Claire
a7b718c31a
Fix all streamed notification types being stored without filtering (#31384) 2024-08-12 13:40:29 +00:00
KMY
a99f174d98 Merge commit '9e04007020' into upstream-20240725 2024-07-25 13:06:26 +09:00
Renaud Chaput
f587ff643f
Grouped Notifications UI (#30440)
Co-authored-by: Eugen Rochko <eugen@zeonfederated.com>
Co-authored-by: Claire <claire.github-309c@sitedethib.com>
2024-07-18 14:36:09 +00:00
KMY
af2727387e Merge remote-tracking branch 'parent/main' into upstream-20240624 2024-06-24 08:38:12 +09:00
Renaud Chaput
1c65932776
Convert disconnectTimeline and timelineDelete actions to Typescript (#30777) 2024-06-20 11:56:52 +00:00
KMY(雪あすか)
4a9f549dd2
Fix: #660 絵文字リアクションのストリーミングを受信した時点で投稿のカウントが更新されない (#683) 2024-04-01 08:26:30 +09:00
KMY
80498c8377 Merge remote-tracking branch 'parent/main' into kb-merge-231010 2023-10-10 22:17:15 +09:00
KMY
5c758b344c Add antenna timeline 2023-08-19 17:25:55 +09:00
KMY
bb2e964dca Merge commit 'aea67d448b' into kb_migration 2023-06-04 10:15:09 +09:00
Renaud Chaput
b0780cfeed
Fix /share and cleanup and reorganize frontend locale loading (#25240) 2023-06-02 15:00:27 +02:00
KMY
d6f8f19e31 Merge commit 'e58c36d308' into kb_migration 2023-05-25 08:46:53 +09:00
Renaud Chaput
d27216dc46
Enforce import order with ESLint (#25096) 2023-05-23 17:15:17 +02:00
KMY
5a638a9551 Add glitch-toc emoji_reaction support 2023-05-15 08:09:22 +09:00
KMY
ba3f60ba63 Merge commit 'c8181eb0a4' into kb_migration 2023-05-09 15:39:21 +09:00
Renaud Chaput
d9b93bd15e
Enforce React Rules of Hooks with eslint (#24911) 2023-05-09 03:09:11 +02:00
KMY
3a1a6ba39e Merge commit '15fd712464' into kb_migration 2023-05-01 15:05:34 +09:00
Nick Schonning
f22b4e556c
Add eslint-plugin-jsdoc (#24719) 2023-04-30 02:29:54 +02:00
KMY
a726b49476 Merge commit '77bd32a26a' into kb_migration 2023-04-04 17:05:39 +09:00
fusagiko / takayamaki
4520e6473a
[Proposal] Make able to write React in Typescript (#16210)
Co-authored-by: berlysia <berlysia@gmail.com>
Co-authored-by: fusagiko / takayamaki <takayamaki@users.noreply.github.com>
2023-04-03 03:31:39 +02:00
KMY
1c028a20ac Create new stream event type: emoji_reaction 2023-02-26 09:45:22 +09:00
Claire
02851848e9
Revamp post filtering system (#18058)
* Add model for custom filter keywords

* Use CustomFilterKeyword internally

Does not change the API

* Fix /filters/edit and /filters/new

* Add migration tests

* Remove whole_word column from custom_filters (covered by custom_filter_keywords)

* Redesign /filters

Instead of a list, present a card that displays more information and handles
multiple keywords per filter.

* Redesign /filters/new and /filters/edit to add and remove keywords

This adds a new gem dependency: cocoon, as well as a npm dependency:
cocoon-js-vanilla. Those are used to easily populate and remove form fields
from the user interface when manipulating multiple keyword filters at once.

* Add /api/v2/filters to edit filter with multiple keywords

Entities:
- `Filter`: `id`, `title`, `filter_action` (either `hide` or `warn`), `context`
  `keywords`
- `FilterKeyword`: `id`, `keyword`, `whole_word`

API endpoits:
- `GET /api/v2/filters` to list filters (including keywords)
- `POST /api/v2/filters` to create a new filter
  `keywords_attributes` can also be passed to create keywords in one request
- `GET /api/v2/filters/:id` to read a particular filter
- `PUT /api/v2/filters/:id` to update a new filter
  `keywords_attributes` can also be passed to edit, delete or add keywords in
   one request
- `DELETE /api/v2/filters/:id` to delete a particular filter
- `GET /api/v2/filters/:id/keywords` to list keywords for a filter
- `POST /api/v2/filters/:filter_id/keywords/:id` to add a new keyword to a
   filter
- `GET /api/v2/filter_keywords/:id` to read a particular keyword
- `PUT /api/v2/filter_keywords/:id` to edit a particular keyword
- `DELETE /api/v2/filter_keywords/:id` to delete a particular keyword

* Change from `irreversible` boolean to `action` enum

* Remove irrelevent `irreversible_must_be_within_context` check

* Fix /filters/new and /filters/edit with update for filter_action

* Fix Rubocop/Codeclimate complaining about task names

* Refactor FeedManager#phrase_filtered?

This moves regexp building and filter caching to the `CustomFilter` class.

This does not change the functional behavior yet, but this changes how the
cache is built, doing per-custom_filter regexps so that filters can be matched
independently, while still offering caching.

* Perform server-side filtering and output result in REST API

* Fix numerous filters_changed events being sent when editing multiple keywords at once

* Add some tests

* Use the new API in the WebUI

- use client-side logic for filters we have fetched rules for.
  This is so that filter changes can be retroactively applied without
  reloading the UI.
- use server-side logic for filters we haven't fetched rules for yet
  (e.g. network error, or initial timeline loading)

* Minor optimizations and refactoring

* Perform server-side filtering on the streaming server

* Change the wording of filter action labels

* Fix issues pointed out by linter

* Change design of “Show anyway” link in accordence to review comments

* Drop “irreversible” filtering behavior

* Move /api/v2/filter_keywords to /api/v1/filters/keywords

* Rename `filter_results` attribute to `filtered`

* Rename REST::LegacyFilterSerializer to REST::V1::FilterSerializer

* Fix systemChannelId value in streaming server

* Simplify code by removing client-side filtering code

The simplifcation comes at a cost though: filters aren't retroactively
applied anymore.
2022-06-28 09:42:13 +02:00
Claire
a39bf04fe6
Auto-fill timeline gaps when getting re-connecting to Websocket/EventSource stream (#17987) 2022-04-08 19:17:54 +02:00
Eugen Rochko
1060666c58
Add support for editing for published statuses (#16697)
* Add support for editing for published statuses

* Fix references to stripped-out code

* Various fixes and improvements

* Further fixes and improvements

* Fix updates being potentially sent to unauthorized recipients

* Various fixes and improvements

* Fix wrong words in test

* Fix notifying accounts that were tagged but were not in the audience

* Fix mistake
2022-01-19 22:37:27 +01:00
Eugen Rochko
ef057584fd
Add support for managing multiple stream subscriptions in a single connection (#14524) 2020-08-11 18:24:59 +02:00
Eugen Rochko
00448db3c8
Fix unnecessary second connection to user stream from account timeline in web UI (#14387)
Fix regression from #14212
2020-07-24 14:55:14 +02:00
Ariel
2ada2ae18a
Fix/14021 behaviour on add or remove toots (#14212)
* Add toot send by current user at local state after send a new toot

Related to #14021

* Decrement toot counter at profile when remove a toot

Related to #14021

* Remove semicolon at end of line
2020-07-19 17:04:02 +02:00
Takeshi Umeda
3a1a21ad57
Fix local streaming of hashtag timelines (#13827) 2020-05-23 05:46:29 +02:00
Takeshi Umeda
26b08a3c54
Add remote only to public timeline (#13504)
* Add remote only to public timeline

* Fix code style
2020-05-10 10:36:18 +02:00
Eugen Rochko
b9d74d4076
Add streaming API updates for announcements being modified or deleted (#12963)
Change `all_day` to be a visual client-side cue only

Publish immediately if `scheduled_at` is in the past

Add `published_at` and `updated_at` to announcements JSON
2020-01-26 20:07:26 +01:00
Eugen Rochko
f52c988e12
Add announcements (#12662)
* Add announcements

Fix #11006

* Add reactions to announcements

* Add admin UI for announcements

* Add unit tests

* Fix issues

- Add `with_dismissed` param to announcements API
- Fix end date not being formatted when time range is given
- Fix announcement delete causing reactions to send streaming updates
- Fix announcements container growing too wide and mascot too small
- Fix `all_day` being settable when no time range is given
- Change text "Update" to "Announcement"

* Fix scheduler unpublishing announcements before they are due

* Fix filter params not being passed to announcements filter
2020-01-23 22:00:13 +01:00
Eugen Rochko
be1c634b2b
Fix public timelines being broken by new toots when they are not mounted (#10131) 2019-03-07 22:17:52 +01:00
James Kiesel
4c03e05a4e Allow joining several hashtags in a single column (#8904)
* Nascent tag menu on frontend

* Hook up frontend to search

* Tag intersection backend first pass

* Update yarnlock

* WIP

* Fix for tags not searching correctly

* Make radio buttons function

* Simplify radio buttons with modeOption

* Better naming

* Rearrange options

* Add all/any/none functionality on backend

* Small PR cleanup

* Move to service from scope

* Small cleanup, add proper service tests

* Don't use send with user input :D

* Set appropriate column header

* Handle auto updating timeline

* Fix up toggle function

* Use tag value correctly

* A bit more correct to use 'self' rather than 'all' in status scope

* Fix some style issues

* Fix more code style issues

* Style select dropdown more better

* Only use to_id'ed value to ensure no SQL injection

* Revamp frontend to allow for multiple selects

* Update backend / col header to account for more flexible tagging

* Update brakeman ignore

* Codeclimate suggestions

* Fix presenter tag_url

* Implement initial PR feedback

* Handle additional tag streaming

* CodeClimate tweak
2018-11-05 18:53:25 +01:00
Eugen Rochko
774ac47373
Add conversations API (#8832)
* Add conversations API

* Add web UI for conversations

* Add test for conversations API

* Add tests for ConversationAccount

* Improve web UI

* Rename ConversationAccount to AccountConversation

* Remove conversations on block and mute

* Change last_status_id to be a denormalization of status_ids

* Add optimistic locking
2018-10-07 23:44:58 +02:00
Eugen Rochko
cdb101340a
Keyword/phrase filtering (#7905)
* Add keyword filtering

    GET|POST       /api/v1/filters
    GET|PUT|DELETE /api/v1/filters/:id

- Irreversible filters can drop toots from home or notifications
- Other filters can hide toots through the client app
- Filters use a phrase valid in particular contexts, expiration

* Make sure expired filters don't get applied client-side

* Add missing API methods

* Remove "regex filter" from column settings

* Add tests

* Add test for FeedManager

* Add CustomFilter test

* Add UI for managing filters

* Add streaming API event to allow syncing filters

* Fix tests
2018-06-29 15:34:36 +02:00