Greasy Fork is available in English.

YouTube Enhancer (Reveal Country Flag)

Display country flags for YouTube channels, videos and shorts.

< Отзив за YouTube Enhancer (Reveal Country Flag)

Отзив: Отлично - скриптът работи

§
Публикуван на: 03.11.2024

I love this script, super cool idea. Can you swap some of the setTimeouts with observers. There's a consistent delay when loading a video, channel or anywhere else wehre the country code flag should appear.

exyezedАвтор
§
Публикуван на: 04.11.2024

I love this script, super cool idea. Can you swap some of the setTimeouts with observers. There's a consistent delay when loading a video, channel or anywhere else wehre the country code flag should appear.

Thank you for the feedback! I’ve removed the setTimeout, so the flags now appear more quickly. Please update to version 1.2, keep in mind, if the flags don’t appear even after several refreshes, it’s likely the channel has not set a country.

§
Публикуван на: 04.11.2024

Great improvement, and I love your coding style, it's really clean. Works perfectly on videos.

Channel pages are buggy. I have another script that changes channel links to redirect to the videos tab on the channel page, and the only way to get metadata from there the country flag is with ".country-flag-container"

§
Публикуван на: 04.11.2024
Редактиран на: 04.11.2024

though your function fetchChannelCountryData still handles this so it's just the lack of visiting the homepage that causes this issue since it can't get the channel identifier from the url

§
Публикуван на: 04.11.2024
Редактиран на: 04.11.2024

I just realized, my other scripts/urlshorteners cause conflicts because of location.replace("modified url"); to modify the url, which causes the behavior of reloading the page.

Example url:
https://www.youtube.com/@Manga_Fresh_/videos

If i have time after my classes today i'll fix it

exyezedАвтор
§
Публикуван на: 05.11.2024

Great improvement, and I love your coding style, it's really clean. Works perfectly on videos.

Channel pages are buggy. I have another script that changes channel links to redirect to the videos tab on the channel page, and the only way to get metadata from there the country flag is with ".country-flag-container"



Hi, I've rewritten the code, added support for Shorts videos, and fixed the bug related to channels. Please update to version 1.3

§
Публикуван на: 05.11.2024

Nice fix, I tried to take a crack at it myself but couldn't get mine working without breakage :/

Публикувайте отговор

Влезте, за да публикувате отговор.