Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add setting to blur and unblur subtitle tracks on mouse hover #413

Merged
merged 5 commits into from
May 27, 2024

Conversation

nekorushi
Copy link
Contributor

@nekorushi nekorushi commented Apr 30, 2024

Added setting that allows for blurring of selected subtitle tracks. When mouse hovered, they unblur.

@killergerbah
Copy link
Owner

killergerbah commented May 1, 2024

@nekorushi Thanks for taking the time to contribute your idea and implementation. The only major feedback I have is that I would prefer if the data model for the settings future-proofed itself against the possibility of more track-specific settings. This would make it more trivial to implement more of these types of settings for more than 3 tracks, with less code duplication, and with less hardcoding of keys that look like foo1, foo2, foo3, .... For example, I have received a feature request to make subtitle alignment track-specific as well, and the implementation for this would be simplified if the data model already readily supported track-specific settings. This is my suggestion for the settings data model:

subtitleTracks: [{"blur": true/false}, {"blur": true/false}, ...]

"subtitleBlurTrack1": "Track 1",
"subtitleBlurTrack2": "Track 2",
"subtitleBlurTrack3": "Track 3",
"subtitleBlurDescription": "Hides selected subtitle tracks by blurring them, can be unblurred on mouse hover",
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nitpick: Hides selected subtitle tracks by blurring them. Can be un-blurred on mouse hover.

@nekorushi nekorushi marked this pull request as ready for review May 17, 2024 12:43
@killergerbah
Copy link
Owner

Thanks @nekorushi for your contribution. It is close to merge, can you just make yarn run verify pass? You can update the loc keys for non-English languages by running node merge-loc-from-en.js inside of scripts.

@nekorushi
Copy link
Contributor Author

Hey @killergerbah sorry for the delay. I've updated the locale and some missing config found with yarn run verify

@killergerbah killergerbah added this to the Extension v1.3.0 milestone May 27, 2024
@killergerbah killergerbah merged commit e33a132 into killergerbah:main May 27, 2024
1 check passed
@killergerbah
Copy link
Owner

Thank you @nekorushi !

@Kellenok
Copy link

I haven't seen this in action yet. but i have a few questions: is the blur degree adjustable and does the blur appear smoothly or not? Using stylus I made a css that does this. I would like it to be like this video. Anyway, thanks for the useful feature

@nekorushi
Copy link
Contributor Author

@Kellen-wq It doesn't animate. Originally I added such CSS on my side. But for the regular use it felt very annoying due to delaying the reveal. Degree is also not adjustable. I've set the blur to 10px so the text is surely not readable.

The settings surely could be added but for the usability of the feature I am not sure if it's really needed. If you insist though, the earliest I could take a look would be the end of the next month due to personal plans.

@Kellenok
Copy link

@nekorushi that's not necessary, thank you again for adding this function.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants