Commit graph

9729 commits

Author SHA1 Message Date
Benjamin Neff
fddfd8b8c0
Merge pull request #8363 from cmrd-senya/fix-api-tags-stream-to-hide-ignores
API: update Search endpoint to be aware of ignored users
2024-06-05 01:06:26 +02:00
Benjamin Neff
c3eaa212af
Merge pull request #8406 from Flaburgan/6184-service-disabled
Do not show the service to the user if it is disabled, fixes #6184

Fixes #6184
2024-06-05 01:04:00 +02:00
Benjamin Neff
7ec2a68256
Merge pull request #8439 from jhass/feature/comment_likes_api
add API routes for comment likes
2024-06-05 01:01:52 +02:00
Benjamin Neff
80beedfe63
Merge pull request #8442 from Flaburgan/mark-like-on-comment-notifications-as-read
Mark Likes on comment notifications as read when visiting a post
2024-06-05 01:01:04 +02:00
Benjamin Neff
813e44c0a9
Bump jquery-ui-rails 2024-06-05 00:34:00 +02:00
Benjamin Neff
541da9f682
Bump carrierwave
Carrierwave 3.0.4 cleans the original_filename after store, but we can
still get the original filename from the file directly.
2024-06-05 00:33:58 +02:00
Benjamin Neff
4b49270be7
Simplify comment and post validation
It's enough to check if the comment exists on the specified post, if it
doesn't exist at all, that check will also fail.

Also do that check directly on SQL level and just check if the comment
exist instead of looping through all comments.
2024-06-05 00:14:31 +02:00
Benjamin Neff
649d8c5b56
Mark notifications as read in a single SQL query
There is no need to load all comments only to count them. Lets just let
the database do all the work. If there are no comments found, nothing
will happen anyway.

Also already filter the comments to only search for notifications for
own comments.

And add some tests :)
2024-06-03 00:11:45 +02:00
Benjamin Neff
52424fba6d
Add available_services helper to be used for desktop and mobile 2024-06-02 05:08:29 +02:00
flaburgan
71e6f20740 Mark Likes on comment notifications as read when visiting a post 2024-02-11 18:40:29 +01:00
flaburgan
14cf4ff85d Do not show the service to the user if it is disabled, fixes #6184 2024-02-11 17:12:02 +01:00
Benjamin Neff
ae3b7804f0
Merge pull request #8441 from SuperTux88/fix-fetch-comments
Allow fetching comments
2024-01-24 01:03:08 +01:00
Benjamin Neff
9e61693e20
Allow fetching comments
Now with likes on comments, diaspora also tries to fetch comments if it
receives a like for a comment it doesn't know yet. So this now also
allows to fetch comments with `/fetch/comment/<guid>`.
2024-01-21 23:30:51 +01:00
Jonne Haß
1e1130e211 add API routes for comment likes 2023-11-24 18:12:59 +01:00
flaburgan
89f906b1b1 Fix horizontal scroll and captcha on mobile, host for user id 2023-11-13 22:13:44 +01:00
flaburgan
7782a32921 New registration page, mentionning the import, fixes #8009 2023-11-13 21:06:20 +01:00
Benjamin Neff
42ffd6322f
Merge pull request #8203 from tclaus/2999-likes-comment
Re-introduce likes on comments
2023-11-13 02:32:43 +01:00
Benjamin Neff
b0c196aea0
Add notifications for likes on comments 2023-11-13 02:27:55 +01:00
Benjamin Neff
3e1407d242
Fix comments not being lazy loaded in streams anymore 2023-11-13 02:27:55 +01:00
Benjamin Neff
df8275f000
Fix participations for likes on comments in the backend
When liking a comment, the post also gets a participation, and if all
likes/comments get removed again, the participation also gets removed
again.

The only thing still not working properly is the frontend, but that is
already broken when unliking a post. So it shows an invalids state in
the frontend when unliking the post/comment.
2023-11-13 02:27:55 +01:00
flaburgan
5153534f4c
Fix pronto in Ruby 2023-11-13 02:27:55 +01:00
flaburgan
1b2f85c384
Improve styling for mobile comments 2023-11-13 02:27:55 +01:00
Benjamin Neff
71d071be60
Only show heart icon when avatars are shown for comment likes 2023-11-13 02:27:55 +01:00
Benjamin Neff
ad6c9dd55f
Fix styling and spacing for likes on comments 2023-11-13 02:27:55 +01:00
Thorsten Claus
9c0f8cdf11
Dont send all likes with list of comments
Due to historic reasons with a comment the list of all likes was sent to the frontend.
This is needed just to detect if one of the likes is current users like.
So if sending just the own like, the frontend can do it's job.

When the frontend is refactured in any way, post and comment like handling should be improved.
2023-11-13 02:27:55 +01:00
Thorsten Claus
c2a2fb63b0
In API dont fetch liked from all comments 2023-11-13 02:27:55 +01:00
Thorsten Claus
67f8ba5d57
Refacor files namespaces 2023-11-13 02:27:55 +01:00
Thorsten Claus
9b19be18f2
Adding eventhandler for Mobile views 2023-11-13 02:26:59 +01:00
Thorsten Claus
06a0dc68a9
Enabled likes-on-comments in mobile view 2023-11-13 02:26:59 +01:00
Thorsten Claus
35f1cd61b1
set correct comment like avatar by removing size 2023-11-13 02:26:59 +01:00
flaburgan
8d6548b610
Introduce like-interactions.js
Adapt to latest development

User likes
 Set css class for inline likes on comment

Re-set participation on comment likes

Co-authored-by: Thorsten Claus <ThorstenClaus@web.de>
2023-11-13 02:26:59 +01:00
flaburgan
82ff57a750
Bring back likes on comments 2023-11-13 02:26:59 +01:00
flaburgan
587e106095
Add a more detailed modal when reporting a post or a comment 2023-11-13 00:15:33 +01:00
Benjamin Neff
14c4010471
Downgrade sidekiq to latest 6.x version
Sidekiq 7 requires redis 6.2+, which isn't available in a lot of distros
yet :( So lets wait with this for a while.

This partially reverts commit a59505574a.
2023-06-28 14:05:55 +02:00
Benjamin Neff
a59505574a
Bump sidekiq, sidekiq-cron and migrate to redis-client
This breaks compatibility with redis <6
2023-06-28 01:19:34 +02:00
Benjamin Neff
02182e3b59
Merge pull request #8421 from SuperTux88/cleanup-from-header-unicode-emojis
Cleanup unicode emojis from email headers
2023-06-10 17:26:48 +02:00
Benjamin Neff
5508401ed8
Don't modify default translations when merging with other language
`deep_merge!` modifies the hash of the default translation, and it looks
like `I18n.t` always returns the same instance, so after that, the
default stays translated. So lets duplicate the hash first, before
modifying it, this also helps because we also add more keys below, which
probably also shouldn't be added to the original.
2023-06-10 05:00:27 +02:00
Benjamin Neff
dc9a18e24d
Cleanup unicode emojis from email headers
Some email providers (for example gmail) block emails if they have
emojis in the from header, as they could be confused with UI elements.
So the easy solution is to just filter all emojis from the name.

The normal `\p{Emoji}` selector also matches normal numbers, because of
the emoji-version of numbers (1️⃣), but the `\p{Emoji_Presentation}` then
doesn't match colored emojis anymore (❄️), so we need a mix of both to
find all emojis
2023-06-09 04:20:15 +02:00
Benjamin Neff
6f802417c6
Remove i18n-inflector-rails dependency
There are no new releases anymore and the current version isn't
compatible with ruby 3.x.

As this feature wasn't really used a lot (Icelandic didn't even setup
inflections properly), it's probably not worth fighting for it, so lets
just drop it.

Related to #8369
2023-06-09 01:13:16 +02:00
Benjamin Neff
bb7e5a369d
Correctly escape username pattern regex
Without the escaping, the backslash doesn't get renderet in the frontend
which leads to some browsers (chrome >= 114?) just allowing every input.
2023-06-05 23:35:31 +02:00
Benjamin Neff
ce32a7d16b
Merge pull request #8409 from tclaus/add_app_smart_banner
Add app smart banner to web site when using an iOS device
2023-06-04 21:38:34 +02:00
Benjamin Neff
763dffa328
Always strip exif data and drop user setting for it
Some imagemagick-versions (I tested Ubuntu 22.04 and debian bullseye)
always loose exif data when converting from jpg to webp. So this made
our CI fail now, but even if it wasn't failing before, some pods always
had and have versions which might loose the information anyway. So
having a setting to keep exif information is kinda pointless, if we
can't guarantee that the information isn't lost. Also, diaspora isn't a
photo sharing platform and we don't display exif information anywhere,
so I think we should just always strip exif data (which was already the
default before), as we don't need them.
2023-06-04 04:25:01 +02:00
Thorsten Claus
83a2274f47 Adding Smart App Banner for insporation on iOS devices 2022-11-17 23:20:35 +01:00
Benjamin Neff
b0b2083fea
Merge pull request #8407 from Flaburgan/4821-help-mobile
Tell users that there is no help in mobile version, allow to switch to desktop
2022-11-04 02:07:36 +01:00
flaburgan
3d84ae18a7 Tell users that there is no help in mobile version, allow to switch to desktop, fixes #4821 2022-11-02 23:27:58 +01:00
Benjamin Neff
5f6b01e086
Merge pull request #8404 from Flaburgan/8118-scrolling-photos
Do not recreate blueimp each time you're scrolling in the photos page
2022-11-01 21:20:12 +01:00
Benjamin Neff
80c0888176
Merge pull request #8403 from SuperTux88/cleanup-duplicate-pods-for-real-this-time
Cleanup duplicate pods
2022-11-01 21:17:17 +01:00
flaburgan
fbc096c7a7 Add info links (the ones in the footer in the desktop version) into the drawer for mobile, fixes #7949 2022-10-31 12:11:46 +01:00
flaburgan
35c254c88c Do not recreate blueimp each time you're scrolling in the photos page, fixes #8118 2022-10-31 11:21:08 +01:00
Benjamin Neff
800f394870
Show ports on pods list
otherwise pods with different ports (or without port) all look the same,
like if they are duplicates
2022-10-31 01:45:13 +01:00