Commit Graph

504 Commits

Author SHA1 Message Date
syeopite
0db3b830b7 Ameba: Fix Lint/HashDuplicatedKey 2024-07-24 20:03:41 -07:00
Samantaz Fox
e8a36985af API: Add APIHandler back (#4431)
This handler should no have been removed in 4276, as it adds the required CORS
header (Access-Control-Allow-Origin) for public acces to the API.

Thanks to iBicha for noticing this!
2024-02-19 00:16:17 +01:00
Samantaz Fox
962ce23cc2 WebVTT::Builder: Add logic to escape special chars (#4414)
Note: WebVTT does allow some tags in the cue payload in some circumstances
while this PR just blindly escapes everything:
https://developer.mozilla.org/en-US/docs/Web/API/WebVTT_API#cue_payload_text_tags
2024-02-19 00:16:17 +01:00
Samantaz Fox
e0ce59d3e8 Channels: Add support for multi-image community posts (#4412)
This PR adds a CSS-only image carousel for community posts with more than
one image attached.

Closes issue 3522
2024-02-19 00:16:17 +01:00
ChunkyProgrammer
26429bee3f make it so interpolation text can be a hash
Co-Authored-By: Samantaz Fox <coding@samantaz.fr>
2024-02-15 21:45:22 -05:00
ChunkyProgrammer
ef6b766b29 Add support for multi image community posts 2024-02-15 21:45:21 -05:00
Samantaz Fox
60f6a345d9 Locales: Fix broken i18Next v3/v4 plurals
Languages impacted: es, fa, pt
2024-02-15 22:12:04 +01:00
Samantaz Fox
7b84bdb29b API: Add APIHandler back
This handler should no have been removed in 4276, as it adds the required CORS
header (Access-Control-Allow-Origin) for public acces to the API.

Thanks to iBicha for noticing this!
2024-02-13 21:05:26 +01:00
Samantaz Fox
c85b908613 API: Fix missing wildcards after login redirect (#4348)
This PR fixes an issue where the `scopes` parameter would see its wildmark
characters (*) removed during the login page redirection, after that a call
to `/authorize_token` was made while the user was not logged in.

Closes issue 4200
2024-02-12 22:30:48 +01:00
Samantaz Fox
1f51255f2f API: Remove the fields parameter (#4276)
Multiple users have reported that the fields parameter is slowing down API
response times significantly. As most API endpoints are already optimized to
make as few requests as possible to Youtube, there is no point in limiting the
output. Furthermore, the added processing might be part of the broader memory
leak problem (See 1438).

In addition, the small increase in data output is not much of an issue compared
to the huge video proxy that lies next to this API.

No related issue tracked
2024-02-12 22:10:45 +01:00
syeopite
0ad2eff2a4 WebVTT::Builder: Add logic to escape special chars 2024-01-30 15:25:45 -08:00
nixos script
0917efd9cb fix issue where scope would be missing the * if the user was not logged in before calling the authorize endpoint
fix #4200
2023-12-21 13:52:19 +08:00
Samantaz Fox
9d5fa2bcc4 Helpers: remove JSONFilter logic 2023-11-23 18:30:42 +01:00
Samantaz Fox
9310d09f93 Kemal: remove APIHandler middleware 2023-11-23 18:30:37 +01:00
syeopite
ed8b84ed15 Replace more * in macro with #splat 2023-11-08 00:49:37 -08:00
syeopite
8ce91166d6 Remove instance of the * operator in macro expr 2023-11-08 00:42:46 -08:00
syeopite
8525758583 Use #splat method for macro expressions 2023-11-08 00:37:18 -08:00
syeopite
438467f69a Add playback success rate to /api/v1/stats (#4085)
* Add stats-based /videoplayback blockage status

* Count when YouTube returns wrong video as failure

* Cast playback stats hash type prior to return

* Bump stats refresh timer to 10 minutes
2023-11-04 13:52:30 +00:00
Samantaz Fox
ce0e21400e Search: Parse channel handle (#3994) 2023-10-07 19:56:07 +02:00
Samantaz Fox
1caaf63c8a Refactor WebVTT building logic into WebVTT::Builder (#4070) 2023-10-07 19:53:29 +02:00
Samantaz Fox
f26c995344 i18next: Revert some changes, as es/pt/pt-PT aren't mixed up (yet) 2023-10-07 19:12:17 +02:00
Samantaz Fox
32310b7c9f i18Next: Add exceptions for mixed v3/v4 plural forms 2023-10-06 08:19:27 +02:00
syeopite
a999438ae4 Consistency: rename #add_timestamp_component
Removes the add_ prefix for consistency with the other methods in
WebVTT::Builder
2023-09-23 09:41:43 -04:00
syeopite
e9d59a6dfd Update src/invidious/helpers/webvtt.cr
Co-authored-by: Samantaz Fox <coding@samantaz.fr>
2023-09-23 09:41:43 -04:00
syeopite
4e97d8ad09 Update documentation for WebVTT.build 2023-09-23 09:41:43 -04:00
syeopite
d371eb50f2 WebVTT::Builder: rename #line to #cue 2023-09-23 09:41:41 -04:00
syeopite
54fa59cbb0 Add method to construct WebVTT files
Similar to JSON.Build
2023-09-23 09:20:20 -04:00
ChunkyProgrammer
8781520b8a Search: Parse channel handle and hide video count when channel handle exists
Co-Authored-By: Samantaz Fox <coding@samantaz.fr>
2023-09-18 20:12:07 -04:00
Samantaz Fox
839e90aeff Extractors: Add module for 'hashtagTileRenderer' 2023-07-18 00:01:13 +02:00
Samantaz Fox
0ba22ef391 I18n: Add a function to determine if a given locale is RTL 2023-07-06 00:23:22 +02:00
Samantaz Fox
df6b51f9c6 Comments: Fix display of youtube links (#3911) 2023-06-12 21:04:57 +02:00
lamemakes
7a569d81ca Updated comment link returns 2023-06-12 09:40:26 -04:00
Samantaz Fox
69f23d95b8 User: Remove broken Google login (various functions) 2023-06-11 16:34:59 +02:00
Samantaz Fox
898066407d Utils: Update 'decode_date' to take into account short "x ago" forms 2023-05-29 12:41:53 +02:00
Samantaz Fox
10fee9da61 Community: Fix live video + parse playlist attachments (#3767) 2023-05-08 15:42:06 +02:00
chunky programmer
1b10446e5e move url parsing to utils method 2023-04-30 18:58:39 -04:00
chunky programmer
f298e225a1 fix live video attachments, parse playlists 2023-04-30 18:55:02 -04:00
ChunkyProgrammer
97825be10c add missing authorVerified to api 2023-02-07 21:52:53 -05:00
Samantaz Fox
6c687a3cac Login redirect to referer on logged-in user (#3556) 2023-02-02 21:28:24 +01:00
Samantaz Fox
dbee027ed9 Search: Fix ArithmeticOverflow + wrong subs count issues (#3535) 2023-01-22 23:12:04 +01:00
Samantaz Fox
cf93c94fc4 Formatting fix for Crystal nightly
Changes added by https://github.com/crystal-lang/crystal/pull/12951
2023-01-21 15:23:15 +01:00
Brahim Hadriche
01acb9bfbf Login redirect to referer on logged-in user 2023-01-13 19:04:37 -05:00
DUOLabs333
0d3610f63d Change regex used in short_text_to_number 2023-01-04 18:12:15 -05:00
DUOLabs333
85dd3533bb Fix for the ArithmeticOverflow Problem 2023-01-03 20:18:10 -05:00
Samantaz Fox
ce7db8d2cb extractors: Add continuation token parser 2022-12-22 16:13:26 +01:00
Samantaz Fox
afc0ec3c30 search: Fix short text parsing 2022-11-20 23:28:21 +01:00
Samantaz Fox
87a5d70062 videos: move API's JSON structure to a dedicated module 2022-10-31 20:09:04 +01:00
Samantaz Fox
4055c3bec8 i18n: Add Bengali, Catalan, Basque, Sinhala and Slovak
Add languages even if translation is <= 25%
2022-10-30 13:46:28 +01:00
Samantaz Fox
7e648840a1 Move InfoException to exceptions.cr 2022-07-19 21:05:49 +02:00
Samantaz Fox
46891437e9 Add Estonian to i18n.cr 2022-05-21 18:39:49 +02:00