Ver Fonte

ref: extract integration features into own category

Sv443 há 8 meses atrás
pai
commit
5a1b39eb3a

+ 2 - 0
assets/resources.json

@@ -4,6 +4,8 @@
   "css-auto_like": "style/autoLike.css",
   "css-fix_hdr": "style/fixHDR.css",
   "css-fix_spacing": "style/fixSpacing.css",
+  "css-fix_sponsorblock": "style/fixSponsorBlock.css",
+  "css-fix_themesong": "style/fixThemeSong.css",
   "css-show_votes": "style/showVotes.css",
   "css-vol_slider_size": "style/volSliderSize.css",
   "doc-changelog": "/changelog.md",

+ 4 - 0
assets/style/fixSponsorBlock.css

@@ -0,0 +1,4 @@
+.sponsorSkipNoticeContainer,
+.sponsorSkipObject {
+  z-index: 4;
+}

+ 58 - 30
assets/translations/README.md

@@ -16,15 +16,15 @@ To submit or edit a translation, please follow [this guide](../../contributing.m
 ### Translation progress:
 |   | Locale | Translated keys | Based on |
 | :----: | ------ | --------------- | :------: |
-| ─ | [`en_US`](./en_US.json) | 282 (default locale) |  |
-| ‼️ | [`de_DE`](./de_DE.json) | `203/282` (72%) | ─ |
-| ─ | [`en_UK`](./en_UK.json) | `282` (100%) | `en_US` |
-| ‼️ | [`es_ES`](./es_ES.json) | `203/282` (72%) | ─ |
-| ‼️ | [`fr_FR`](./fr_FR.json) | `203/282` (72%) | ─ |
-| ‼️ | [`hi_IN`](./hi_IN.json) | `203/282` (72%) | ─ |
-| ‼️ | [`ja_JA`](./ja_JA.json) | `203/282` (72%) | ─ |
-| ‼️ | [`pt_BR`](./pt_BR.json) | `203/282` (72%) | ─ |
-| ‼️ | [`zh_CN`](./zh_CN.json) | `203/282` (72%) | ─ |
+| ─ | [`en_US`](./en_US.json) | 287 (default locale) |  |
+| ‼️ | [`de_DE`](./de_DE.json) | `204/287` (71.1%) | ─ |
+| ─ | [`en_UK`](./en_UK.json) | `287` (100%) | `en_US` |
+| ‼️ | [`es_ES`](./es_ES.json) | `204/287` (71.1%) | ─ |
+| ‼️ | [`fr_FR`](./fr_FR.json) | `204/287` (71.1%) | ─ |
+| ‼️ | [`hi_IN`](./hi_IN.json) | `204/287` (71.1%) | ─ |
+| ‼️ | [`ja_JA`](./ja_JA.json) | `204/287` (71.1%) | ─ |
+| ‼️ | [`pt_BR`](./pt_BR.json) | `204/287` (71.1%) | ─ |
+| ‼️ | [`zh_CN`](./zh_CN.json) | `204/287` (71.1%) | ─ |
 
 <sub>
 ✅ - Fully translated
@@ -45,7 +45,7 @@ This means to figure out which keys are untranslated, you will need to manually
 
 ### Missing keys:
 
-<details><summary><code>de_DE</code> - 79 missing keys <i>(click to show)</i></summary><br>
+<details><summary><code>de_DE</code> - 83 missing keys <i>(click to show)</i></summary><br>
 
 | Key | English text |
 | --- | ------------ |
@@ -102,6 +102,8 @@ This means to figure out which keys are untranslated, you will need to manually
 | `vote_ratio_blue_gray` | `Blue and gray` |
 | `votes_format_short` | `Shortened` |
 | `votes_format_long` | `Full number` |
+| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
+| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 | `feature_desc_showVotes` | `Show the amount of likes and dislikes on the currently playing song` |
 | `feature_helptext_showVotes` | `This feature is powered by Return YouTube Dislike and will show the approximate amount of likes and dislikes on the currently playing song.` |
 | `feature_desc_showVotesFormat` | `How should the likes and dislikes be formatted?` |
@@ -118,6 +120,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_autoLikeOpenMgmtDialog` | `Open the dialog to manage auto-liked channels` |
 | `feature_btn_autoLikeOpenMgmtDialog` | `Open dialog` |
 | `feature_btn_autoLikeOpenMgmtDialog_running` | `Opening...` |
+| `feature_desc_sponsorBlockIntegration` | `Make some fixes to the layout in case SponsorBlock is installed` |
+| `feature_helptext_sponsorBlockIntegration` | `If you have the SponsorBlock extension installed, this feature will make some fixes to the layout of the site to prevent issues that might occur.\nThis feature will have no effect if the extension is not installed and can be left activated in that case.` |
+| `feature_desc_themeSongIntegration` | `Make the styling of the page match the theme set by the ThemeSong extension` |
+| `feature_helptext_themeSongIntegration` | `If you have the ThemeSong extension installed, this feature will make the styling of the page match the theme set by ThemeSong.\nThis feature might mess up the layout of the page if the extension is not installed, so make sure to disable it in that case.` |
 | `feature_desc_initTimeout` | `How many seconds to wait for features to initialize before considering them to likely be in an errored state` |
 | `feature_helptext_initTimeout` | `This is the amount of time in milliseconds that the script will wait for features to initialize before considering them to likely be in an errored state.\nThis will not affect the script's behavior in a significant way, but if one of your plugins can't initialize in time, you should try increasing this value.` |
 | `feature_desc_toastDuration` | `For how many seconds custom toast notifications should be shown - 0 to disable them entirely` |
@@ -126,12 +132,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_resetConfig` | `Reset all settings to their default values` |
 | `feature_btn_resetConfig` | `Reset settings` |
 | `feature_btn_resetConfig_running` | `Confirming...` |
-| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
-| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 
 <br></details>
 
-<details><summary><code>es_ES</code> - 79 missing keys <i>(click to show)</i></summary><br>
+<details><summary><code>es_ES</code> - 83 missing keys <i>(click to show)</i></summary><br>
 
 | Key | English text |
 | --- | ------------ |
@@ -188,6 +192,8 @@ This means to figure out which keys are untranslated, you will need to manually
 | `vote_ratio_blue_gray` | `Blue and gray` |
 | `votes_format_short` | `Shortened` |
 | `votes_format_long` | `Full number` |
+| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
+| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 | `feature_desc_showVotes` | `Show the amount of likes and dislikes on the currently playing song` |
 | `feature_helptext_showVotes` | `This feature is powered by Return YouTube Dislike and will show the approximate amount of likes and dislikes on the currently playing song.` |
 | `feature_desc_showVotesFormat` | `How should the likes and dislikes be formatted?` |
@@ -204,6 +210,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_autoLikeOpenMgmtDialog` | `Open the dialog to manage auto-liked channels` |
 | `feature_btn_autoLikeOpenMgmtDialog` | `Open dialog` |
 | `feature_btn_autoLikeOpenMgmtDialog_running` | `Opening...` |
+| `feature_desc_sponsorBlockIntegration` | `Make some fixes to the layout in case SponsorBlock is installed` |
+| `feature_helptext_sponsorBlockIntegration` | `If you have the SponsorBlock extension installed, this feature will make some fixes to the layout of the site to prevent issues that might occur.\nThis feature will have no effect if the extension is not installed and can be left activated in that case.` |
+| `feature_desc_themeSongIntegration` | `Make the styling of the page match the theme set by the ThemeSong extension` |
+| `feature_helptext_themeSongIntegration` | `If you have the ThemeSong extension installed, this feature will make the styling of the page match the theme set by ThemeSong.\nThis feature might mess up the layout of the page if the extension is not installed, so make sure to disable it in that case.` |
 | `feature_desc_initTimeout` | `How many seconds to wait for features to initialize before considering them to likely be in an errored state` |
 | `feature_helptext_initTimeout` | `This is the amount of time in milliseconds that the script will wait for features to initialize before considering them to likely be in an errored state.\nThis will not affect the script's behavior in a significant way, but if one of your plugins can't initialize in time, you should try increasing this value.` |
 | `feature_desc_toastDuration` | `For how many seconds custom toast notifications should be shown - 0 to disable them entirely` |
@@ -212,12 +222,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_resetConfig` | `Reset all settings to their default values` |
 | `feature_btn_resetConfig` | `Reset settings` |
 | `feature_btn_resetConfig_running` | `Confirming...` |
-| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
-| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 
 <br></details>
 
-<details><summary><code>fr_FR</code> - 79 missing keys <i>(click to show)</i></summary><br>
+<details><summary><code>fr_FR</code> - 83 missing keys <i>(click to show)</i></summary><br>
 
 | Key | English text |
 | --- | ------------ |
@@ -274,6 +282,8 @@ This means to figure out which keys are untranslated, you will need to manually
 | `vote_ratio_blue_gray` | `Blue and gray` |
 | `votes_format_short` | `Shortened` |
 | `votes_format_long` | `Full number` |
+| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
+| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 | `feature_desc_showVotes` | `Show the amount of likes and dislikes on the currently playing song` |
 | `feature_helptext_showVotes` | `This feature is powered by Return YouTube Dislike and will show the approximate amount of likes and dislikes on the currently playing song.` |
 | `feature_desc_showVotesFormat` | `How should the likes and dislikes be formatted?` |
@@ -290,6 +300,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_autoLikeOpenMgmtDialog` | `Open the dialog to manage auto-liked channels` |
 | `feature_btn_autoLikeOpenMgmtDialog` | `Open dialog` |
 | `feature_btn_autoLikeOpenMgmtDialog_running` | `Opening...` |
+| `feature_desc_sponsorBlockIntegration` | `Make some fixes to the layout in case SponsorBlock is installed` |
+| `feature_helptext_sponsorBlockIntegration` | `If you have the SponsorBlock extension installed, this feature will make some fixes to the layout of the site to prevent issues that might occur.\nThis feature will have no effect if the extension is not installed and can be left activated in that case.` |
+| `feature_desc_themeSongIntegration` | `Make the styling of the page match the theme set by the ThemeSong extension` |
+| `feature_helptext_themeSongIntegration` | `If you have the ThemeSong extension installed, this feature will make the styling of the page match the theme set by ThemeSong.\nThis feature might mess up the layout of the page if the extension is not installed, so make sure to disable it in that case.` |
 | `feature_desc_initTimeout` | `How many seconds to wait for features to initialize before considering them to likely be in an errored state` |
 | `feature_helptext_initTimeout` | `This is the amount of time in milliseconds that the script will wait for features to initialize before considering them to likely be in an errored state.\nThis will not affect the script's behavior in a significant way, but if one of your plugins can't initialize in time, you should try increasing this value.` |
 | `feature_desc_toastDuration` | `For how many seconds custom toast notifications should be shown - 0 to disable them entirely` |
@@ -298,12 +312,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_resetConfig` | `Reset all settings to their default values` |
 | `feature_btn_resetConfig` | `Reset settings` |
 | `feature_btn_resetConfig_running` | `Confirming...` |
-| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
-| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 
 <br></details>
 
-<details><summary><code>hi_IN</code> - 79 missing keys <i>(click to show)</i></summary><br>
+<details><summary><code>hi_IN</code> - 83 missing keys <i>(click to show)</i></summary><br>
 
 | Key | English text |
 | --- | ------------ |
@@ -360,6 +372,8 @@ This means to figure out which keys are untranslated, you will need to manually
 | `vote_ratio_blue_gray` | `Blue and gray` |
 | `votes_format_short` | `Shortened` |
 | `votes_format_long` | `Full number` |
+| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
+| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 | `feature_desc_showVotes` | `Show the amount of likes and dislikes on the currently playing song` |
 | `feature_helptext_showVotes` | `This feature is powered by Return YouTube Dislike and will show the approximate amount of likes and dislikes on the currently playing song.` |
 | `feature_desc_showVotesFormat` | `How should the likes and dislikes be formatted?` |
@@ -376,6 +390,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_autoLikeOpenMgmtDialog` | `Open the dialog to manage auto-liked channels` |
 | `feature_btn_autoLikeOpenMgmtDialog` | `Open dialog` |
 | `feature_btn_autoLikeOpenMgmtDialog_running` | `Opening...` |
+| `feature_desc_sponsorBlockIntegration` | `Make some fixes to the layout in case SponsorBlock is installed` |
+| `feature_helptext_sponsorBlockIntegration` | `If you have the SponsorBlock extension installed, this feature will make some fixes to the layout of the site to prevent issues that might occur.\nThis feature will have no effect if the extension is not installed and can be left activated in that case.` |
+| `feature_desc_themeSongIntegration` | `Make the styling of the page match the theme set by the ThemeSong extension` |
+| `feature_helptext_themeSongIntegration` | `If you have the ThemeSong extension installed, this feature will make the styling of the page match the theme set by ThemeSong.\nThis feature might mess up the layout of the page if the extension is not installed, so make sure to disable it in that case.` |
 | `feature_desc_initTimeout` | `How many seconds to wait for features to initialize before considering them to likely be in an errored state` |
 | `feature_helptext_initTimeout` | `This is the amount of time in milliseconds that the script will wait for features to initialize before considering them to likely be in an errored state.\nThis will not affect the script's behavior in a significant way, but if one of your plugins can't initialize in time, you should try increasing this value.` |
 | `feature_desc_toastDuration` | `For how many seconds custom toast notifications should be shown - 0 to disable them entirely` |
@@ -384,12 +402,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_resetConfig` | `Reset all settings to their default values` |
 | `feature_btn_resetConfig` | `Reset settings` |
 | `feature_btn_resetConfig_running` | `Confirming...` |
-| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
-| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 
 <br></details>
 
-<details><summary><code>ja_JA</code> - 79 missing keys <i>(click to show)</i></summary><br>
+<details><summary><code>ja_JA</code> - 83 missing keys <i>(click to show)</i></summary><br>
 
 | Key | English text |
 | --- | ------------ |
@@ -446,6 +462,8 @@ This means to figure out which keys are untranslated, you will need to manually
 | `vote_ratio_blue_gray` | `Blue and gray` |
 | `votes_format_short` | `Shortened` |
 | `votes_format_long` | `Full number` |
+| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
+| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 | `feature_desc_showVotes` | `Show the amount of likes and dislikes on the currently playing song` |
 | `feature_helptext_showVotes` | `This feature is powered by Return YouTube Dislike and will show the approximate amount of likes and dislikes on the currently playing song.` |
 | `feature_desc_showVotesFormat` | `How should the likes and dislikes be formatted?` |
@@ -462,6 +480,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_autoLikeOpenMgmtDialog` | `Open the dialog to manage auto-liked channels` |
 | `feature_btn_autoLikeOpenMgmtDialog` | `Open dialog` |
 | `feature_btn_autoLikeOpenMgmtDialog_running` | `Opening...` |
+| `feature_desc_sponsorBlockIntegration` | `Make some fixes to the layout in case SponsorBlock is installed` |
+| `feature_helptext_sponsorBlockIntegration` | `If you have the SponsorBlock extension installed, this feature will make some fixes to the layout of the site to prevent issues that might occur.\nThis feature will have no effect if the extension is not installed and can be left activated in that case.` |
+| `feature_desc_themeSongIntegration` | `Make the styling of the page match the theme set by the ThemeSong extension` |
+| `feature_helptext_themeSongIntegration` | `If you have the ThemeSong extension installed, this feature will make the styling of the page match the theme set by ThemeSong.\nThis feature might mess up the layout of the page if the extension is not installed, so make sure to disable it in that case.` |
 | `feature_desc_initTimeout` | `How many seconds to wait for features to initialize before considering them to likely be in an errored state` |
 | `feature_helptext_initTimeout` | `This is the amount of time in milliseconds that the script will wait for features to initialize before considering them to likely be in an errored state.\nThis will not affect the script's behavior in a significant way, but if one of your plugins can't initialize in time, you should try increasing this value.` |
 | `feature_desc_toastDuration` | `For how many seconds custom toast notifications should be shown - 0 to disable them entirely` |
@@ -470,12 +492,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_resetConfig` | `Reset all settings to their default values` |
 | `feature_btn_resetConfig` | `Reset settings` |
 | `feature_btn_resetConfig_running` | `Confirming...` |
-| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
-| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 
 <br></details>
 
-<details><summary><code>pt_BR</code> - 79 missing keys <i>(click to show)</i></summary><br>
+<details><summary><code>pt_BR</code> - 83 missing keys <i>(click to show)</i></summary><br>
 
 | Key | English text |
 | --- | ------------ |
@@ -532,6 +552,8 @@ This means to figure out which keys are untranslated, you will need to manually
 | `vote_ratio_blue_gray` | `Blue and gray` |
 | `votes_format_short` | `Shortened` |
 | `votes_format_long` | `Full number` |
+| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
+| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 | `feature_desc_showVotes` | `Show the amount of likes and dislikes on the currently playing song` |
 | `feature_helptext_showVotes` | `This feature is powered by Return YouTube Dislike and will show the approximate amount of likes and dislikes on the currently playing song.` |
 | `feature_desc_showVotesFormat` | `How should the likes and dislikes be formatted?` |
@@ -548,6 +570,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_autoLikeOpenMgmtDialog` | `Open the dialog to manage auto-liked channels` |
 | `feature_btn_autoLikeOpenMgmtDialog` | `Open dialog` |
 | `feature_btn_autoLikeOpenMgmtDialog_running` | `Opening...` |
+| `feature_desc_sponsorBlockIntegration` | `Make some fixes to the layout in case SponsorBlock is installed` |
+| `feature_helptext_sponsorBlockIntegration` | `If you have the SponsorBlock extension installed, this feature will make some fixes to the layout of the site to prevent issues that might occur.\nThis feature will have no effect if the extension is not installed and can be left activated in that case.` |
+| `feature_desc_themeSongIntegration` | `Make the styling of the page match the theme set by the ThemeSong extension` |
+| `feature_helptext_themeSongIntegration` | `If you have the ThemeSong extension installed, this feature will make the styling of the page match the theme set by ThemeSong.\nThis feature might mess up the layout of the page if the extension is not installed, so make sure to disable it in that case.` |
 | `feature_desc_initTimeout` | `How many seconds to wait for features to initialize before considering them to likely be in an errored state` |
 | `feature_helptext_initTimeout` | `This is the amount of time in milliseconds that the script will wait for features to initialize before considering them to likely be in an errored state.\nThis will not affect the script's behavior in a significant way, but if one of your plugins can't initialize in time, you should try increasing this value.` |
 | `feature_desc_toastDuration` | `For how many seconds custom toast notifications should be shown - 0 to disable them entirely` |
@@ -556,12 +582,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_resetConfig` | `Reset all settings to their default values` |
 | `feature_btn_resetConfig` | `Reset settings` |
 | `feature_btn_resetConfig_running` | `Confirming...` |
-| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
-| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 
 <br></details>
 
-<details><summary><code>zh_CN</code> - 79 missing keys <i>(click to show)</i></summary><br>
+<details><summary><code>zh_CN</code> - 83 missing keys <i>(click to show)</i></summary><br>
 
 | Key | English text |
 | --- | ------------ |
@@ -618,6 +642,8 @@ This means to figure out which keys are untranslated, you will need to manually
 | `vote_ratio_blue_gray` | `Blue and gray` |
 | `votes_format_short` | `Shortened` |
 | `votes_format_long` | `Full number` |
+| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
+| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 | `feature_desc_showVotes` | `Show the amount of likes and dislikes on the currently playing song` |
 | `feature_helptext_showVotes` | `This feature is powered by Return YouTube Dislike and will show the approximate amount of likes and dislikes on the currently playing song.` |
 | `feature_desc_showVotesFormat` | `How should the likes and dislikes be formatted?` |
@@ -634,6 +660,10 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_autoLikeOpenMgmtDialog` | `Open the dialog to manage auto-liked channels` |
 | `feature_btn_autoLikeOpenMgmtDialog` | `Open dialog` |
 | `feature_btn_autoLikeOpenMgmtDialog_running` | `Opening...` |
+| `feature_desc_sponsorBlockIntegration` | `Make some fixes to the layout in case SponsorBlock is installed` |
+| `feature_helptext_sponsorBlockIntegration` | `If you have the SponsorBlock extension installed, this feature will make some fixes to the layout of the site to prevent issues that might occur.\nThis feature will have no effect if the extension is not installed and can be left activated in that case.` |
+| `feature_desc_themeSongIntegration` | `Make the styling of the page match the theme set by the ThemeSong extension` |
+| `feature_helptext_themeSongIntegration` | `If you have the ThemeSong extension installed, this feature will make the styling of the page match the theme set by ThemeSong.\nThis feature might mess up the layout of the page if the extension is not installed, so make sure to disable it in that case.` |
 | `feature_desc_initTimeout` | `How many seconds to wait for features to initialize before considering them to likely be in an errored state` |
 | `feature_helptext_initTimeout` | `This is the amount of time in milliseconds that the script will wait for features to initialize before considering them to likely be in an errored state.\nThis will not affect the script's behavior in a significant way, but if one of your plugins can't initialize in time, you should try increasing this value.` |
 | `feature_desc_toastDuration` | `For how many seconds custom toast notifications should be shown - 0 to disable them entirely` |
@@ -642,7 +672,5 @@ This means to figure out which keys are untranslated, you will need to manually
 | `feature_desc_resetConfig` | `Reset all settings to their default values` |
 | `feature_btn_resetConfig` | `Reset settings` |
 | `feature_btn_resetConfig_running` | `Confirming...` |
-| `plugin_validation_error_invalid_property-1` | `Property '%1' with value '%2' is invalid. Example value: %3` |
-| `plugin_validation_error_invalid_property-n` | `Property '%1' with value '%2' is invalid. Example values: %3` |
 
 <br></details>

+ 1 - 0
assets/translations/de_DE.json

@@ -133,6 +133,7 @@
     "feature_category_behavior": "Verhalten",
     "feature_category_input": "Eingabe",
     "feature_category_lyrics": "Songtexte",
+    "feature_category_integrations": "Integrationen",
     "feature_category_general": "Allgemein",
 
     "feature_desc_watermarkEnabled": "Zeige ein Wasserzeichen unter dem Seitenlogo, das dieses Einstellungsmenü öffnet",

+ 1 - 0
assets/translations/es_ES.json

@@ -133,6 +133,7 @@
     "feature_category_behavior": "Comportamiento",
     "feature_category_input": "Entrada",
     "feature_category_lyrics": "Letras",
+    "feature_category_integrations": "Integraciones",
     "feature_category_general": "General",
 
     "feature_desc_watermarkEnabled": "Mostrar una marca de agua debajo del logotipo del sitio que abre este menú de configuración",

+ 1 - 0
assets/translations/fr_FR.json

@@ -133,6 +133,7 @@
     "feature_category_behavior": "Comportement",
     "feature_category_input": "Entrée",
     "feature_category_lyrics": "Paroles",
+    "feature_category_integrations": "Intégrations",
     "feature_category_general": "Général",
 
     "feature_desc_watermarkEnabled": "Afficher un filigrane sous le logo du site qui ouvre ce menu de configuration",

+ 1 - 0
assets/translations/hi_IN.json

@@ -133,6 +133,7 @@
     "feature_category_behavior": "व्यवहार",
     "feature_category_input": "इनपुट",
     "feature_category_lyrics": "बोल",
+    "feature_category_integrations": "एकीकरण",
     "feature_category_general": "सामान्य",
 
     "feature_desc_watermarkEnabled": "एक वॉटरमार्क दिखाएं जो इस कॉन्फ़िग मेनू को खोलता है",

+ 1 - 0
assets/translations/ja_JA.json

@@ -133,6 +133,7 @@
     "feature_category_behavior": "動作",
     "feature_category_input": "入力",
     "feature_category_lyrics": "歌詞",
+    "feature_category_integrations": "統合",
     "feature_category_general": "一般的な",
 
     "feature_desc_watermarkEnabled": "この構成メニューを開くサイトロゴの下に透かしを表示する",

+ 1 - 0
assets/translations/pt_BR.json

@@ -133,6 +133,7 @@
     "feature_category_behavior": "Comportamento",
     "feature_category_input": "Entrada",
     "feature_category_lyrics": "Letras",
+    "feature_category_integrations": "Integrações",
     "feature_category_general": "Geral",
 
     "feature_desc_watermarkEnabled": "Mostrar uma marca d'água sob o logotipo do site que abre este menu de configuração",

+ 1 - 0
assets/translations/zh_CN.json

@@ -133,6 +133,7 @@
     "feature_category_behavior": "行为",
     "feature_category_input": "输入",
     "feature_category_lyrics": "歌词",
+    "feature_category_integrations": "集成",
     "feature_category_general": "一般的",
 
     "feature_desc_watermarkEnabled": "在网站标志下方显示一个水印,以打开此配置菜单",

+ 2 - 1
src/config.ts

@@ -95,7 +95,8 @@ export const migrations: DataMigrationsDict = {
 
   // 6 -> 7 (v2.2)
   7: (oldData: FeatureConfig) => useDefaultConfig(oldData, [
-    "showToastOnGenericError",
+    "showToastOnGenericError", "themeSongIntegration",
+    "sponsorBlockIntegration",
   ]),
 } as const satisfies DataMigrationsDict;
 

+ 0 - 15
src/features/behavior.ts

@@ -222,18 +222,3 @@ async function remTimeDeleteEntry(watchID: string) {
   remVidsCache = [...remVidsCache.filter(entry => entry.watchID !== watchID)];
   await GM.setValue("bytm-rem-songs", JSON.stringify(remVidsCache));
 }
-
-//#region disable darkreader
-
-/** Disables Dark Reader if it is present */
-export function disableDarkReader() {
-  if(getFeature("disableDarkReaderSites") !== getDomain() && getFeature("disableDarkReaderSites") !== "all")
-    return;
-
-  const metaElem = document.createElement("meta");
-  metaElem.name = "darkreader-lock";
-  metaElem.id = "bytm-disable-dark-reader";
-  document.head.appendChild(metaElem);
-
-  info("Disabled Dark Reader");
-}

+ 21 - 8
src/features/index.ts

@@ -12,6 +12,7 @@ import { mode } from "../constants.js";
 export * from "./layout.js";
 export * from "./behavior.js";
 export * from "./input.js";
+export * from "./integrations.js";
 export * from "./lyrics.js";
 export * from "./lyricsCache.js";
 export * from "./songLists.js";
@@ -249,14 +250,6 @@ export const featInfo = {
     advanced: true,
     textAdornment: () => combineAdornments([adornments.advanced, adornments.reloadRequired]),
   },
-  disableDarkReaderSites: {
-    type: "select",
-    category: "layout",
-    options: options.siteSelectionOrNone,
-    default: "all",
-    advanced: true,
-    textAdornment: () => combineAdornments([adornments.advanced, adornments.reloadRequired]),
-  },
   showVotes: {
     type: "toggle",
     category: "layout",
@@ -640,6 +633,26 @@ export const featInfo = {
   //   enable: noop,
   // },
 
+  //#region integrations
+  disableDarkReaderSites: {
+    type: "select",
+    category: "integrations",
+    options: options.siteSelectionOrNone,
+    default: "all",
+    advanced: true,
+    textAdornment: () => combineAdornments([adornments.advanced, adornments.reloadRequired]),
+  },
+  sponsorBlockIntegration: {
+    type: "toggle",
+    category: "integrations",
+    default: true,
+  },
+  themeSongIntegration: {
+    type: "toggle",
+    category: "integrations",
+    default: false,
+  },
+
   //#region general
   locale: {
     type: "select",

+ 43 - 0
src/features/integrations.ts

@@ -0,0 +1,43 @@
+import { getDomain } from "../utils/misc.js";
+import { addStyleFromResource } from "../utils/dom.js";
+import { error, info } from "../utils/logging.js";
+import { getFeature } from "../config.js";
+
+//#region Dark Reader
+
+/** Disables Dark Reader if it is present */
+export async function disableDarkReader() {
+  if(getFeature("disableDarkReaderSites") !== getDomain() && getFeature("disableDarkReaderSites") !== "all")
+    return;
+
+  const metaElem = document.createElement("meta");
+  metaElem.name = "darkreader-lock";
+  metaElem.id = "bytm-disable-dark-reader";
+  document.head.appendChild(metaElem);
+
+  info("Disabled Dark Reader");
+}
+
+//#region SponsorBlock
+
+/** Fixes the z-index of the SponsorBlock panel */
+export async function fixSponsorBlock() {
+  try {
+    return addStyleFromResource("css-fix_sponsorblock");
+  }
+  catch(err) {
+    error("Failed to fix SponsorBlock styling:", err);
+  }
+}
+
+//#region ThemeSong
+
+/** Adjust the BetterYTM styles to respect the theme from ThemeSong */
+export async function fixThemeSong() {
+  try {
+    return addStyleFromResource("css-fix_themesong");
+  }
+  catch(err) {
+    error("Failed to fix ThemeSong styling:", err);
+  }
+}

+ 0 - 7
src/features/layout.css

@@ -191,13 +191,6 @@ button[disabled].bytm-busy {
   cursor: progress;
 }
 
-/* #region random fixes */
-
-.sponsorSkipNoticeContainer,
-.sponsorSkipObject {
-  z-index: 4;
-}
-
 /* #region menu */
 
 .bytm-cfg-menu-option {