Skip to content

Commit

Permalink
feat(YouTube - Hide Shorts components): Hide live chat messages and h…
Browse files Browse the repository at this point in the history
…eader in Shorts

Using Smali instead of Litho would be a better solution to hide Live Chat. Maybe will do that later.
  • Loading branch information
anddea committed Apr 17, 2024
1 parent 4d997f8 commit 71de5f4
Show file tree
Hide file tree
Showing 24 changed files with 140 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/main/resources/youtube/settings/host/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -646,6 +646,12 @@ Some components may not be hidden."</string>
<string name="revanced_hide_shorts_button_title">Hide shorts button</string>
<string name="revanced_hide_shorts_component_summary">Hides Shorts section or the Shorts player component.</string>
<string name="revanced_hide_shorts_component_title">Hide shorts component</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_player_comments_button_summary_off">Comments button is shown.</string>
<string name="revanced_hide_shorts_player_comments_button_summary_on">Comments button is hidden.</string>
<string name="revanced_hide_shorts_player_comments_button_title">Hide comments button</string>
Expand Down
2 changes: 2 additions & 0 deletions src/main/resources/youtube/settings/xml/revanced_prefs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -506,6 +506,8 @@
<SwitchPreference android:title="@string/revanced_hide_shorts_tagged_products_title" android:key="revanced_hide_shorts_tagged_products" android:defaultValue="true" android:summaryOn="@string/revanced_hide_shorts_tagged_products_summary_on" android:summaryOff="@string/revanced_hide_shorts_tagged_products_summary_off" />
<SwitchPreference android:title="@string/revanced_hide_shorts_search_suggestions_title" android:key="revanced_hide_shorts_search_suggestions" android:defaultValue="true" android:summaryOn="@string/revanced_hide_shorts_search_suggestions_summary_on" android:summaryOff="@string/revanced_hide_shorts_search_suggestions_summary_off" />
<SwitchPreference android:title="@string/revanced_hide_shorts_player_shop_button_title" android:key="revanced_hide_shorts_player_shop_button" android:defaultValue="true" android:summaryOn="@string/revanced_hide_shorts_player_shop_button_summary_on" android:summaryOff="@string/revanced_hide_shorts_player_shop_button_summary_off" />
<SwitchPreference android:title="@string/revanced_hide_shorts_live_chat_title" android:key="revanced_hide_shorts_live_chat" android:defaultValue="false" android:summaryOn="@string/revanced_hide_shorts_live_chat_summary_on" android:summaryOff="@string/revanced_hide_shorts_live_chat_summary_off" />
<SwitchPreference android:title="@string/revanced_hide_shorts_live_header_title" android:key="revanced_hide_shorts_live_header" android:defaultValue="false" android:summaryOn="@string/revanced_hide_shorts_live_header_summary_on" android:summaryOff="@string/revanced_hide_shorts_live_header_summary_off" />
<SwitchPreference android:title="@string/revanced_hide_shorts_location_label_title" android:key="revanced_hide_shorts_location_label" android:defaultValue="true" android:summaryOn="@string/revanced_hide_shorts_location_label_summary_on" android:summaryOff="@string/revanced_hide_shorts_location_label_summary_off" />
<SwitchPreference android:title="@string/revanced_hide_shorts_subscribe_button_title" android:key="revanced_hide_shorts_subscribe_button" android:defaultValue="true" android:summaryOn="@string/revanced_hide_shorts_subscribe_button_summary_on" android:summaryOff="@string/revanced_hide_shorts_subscribe_button_summary_off" />
<SwitchPreference android:title="@string/revanced_hide_shorts_player_save_sound_button_title" android:key="revanced_hide_shorts_player_save_sound_button" android:defaultValue="true" android:summaryOn="@string/revanced_hide_shorts_player_save_sound_button_summary_on" android:summaryOff="@string/revanced_hide_shorts_player_save_sound_button_summary_off" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,12 @@
<string name="revanced_hide_playables_summary_off">Playables are shown</string>
<string name="revanced_hide_playables_summary_on">Playables are hidden</string>
<string name="revanced_hide_playables_title">Hide playables</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,12 @@
<string name="revanced_hide_player_button_background_summary_off">Player buttons background is shown.</string>
<string name="revanced_hide_player_button_background_summary_on">Player buttons background is hidden.</string>
<string name="revanced_hide_player_button_background_title">Hide player buttons background</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,12 @@ Some components may not be hidden."</string>
<string name="revanced_hide_shopping_links_summary_off">Shopping links are shown.</string>
<string name="revanced_hide_shopping_links_summary_on">Shopping links are hidden.</string>
<string name="revanced_hide_shopping_links_title">Hide shopping links</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,12 @@ Some components may not be hidden."</string>
<string name="revanced_hide_shopping_links_summary_off">Shopping links are shown.</string>
<string name="revanced_hide_shopping_links_summary_on">Shopping links are hidden.</string>
<string name="revanced_hide_shopping_links_title">Hide shopping links</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,12 @@
<string name="revanced_hide_player_button_background_summary_off">Player buttons background is shown.</string>
<string name="revanced_hide_player_button_background_summary_on">Player buttons background is hidden.</string>
<string name="revanced_hide_player_button_background_title">Hide player buttons background</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,12 @@
<string name="revanced_hide_playables_summary_off">Playables are shown</string>
<string name="revanced_hide_playables_summary_on">Playables are hidden</string>
<string name="revanced_hide_playables_title">Hide playables</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,12 @@ Some components may not be hidden."</string>
<string name="revanced_hide_shopping_links_summary_off">Shopping links are shown.</string>
<string name="revanced_hide_shopping_links_summary_on">Shopping links are hidden.</string>
<string name="revanced_hide_shopping_links_title">Hide shopping links</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@
<string name="revanced_hide_playables_summary_off">Playables are shown</string>
<string name="revanced_hide_playables_summary_on">Playables are hidden</string>
<string name="revanced_hide_playables_title">Hide playables</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,12 @@
<string name="revanced_hide_player_button_background_summary_off">Player buttons background is shown.</string>
<string name="revanced_hide_player_button_background_summary_on">Player buttons background is hidden.</string>
<string name="revanced_hide_player_button_background_title">Hide player buttons background</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,12 @@ Note: This feature hasn't been tested."</string>
<string name="revanced_hide_shopping_links_summary_off">Shopping links are shown.</string>
<string name="revanced_hide_shopping_links_summary_on">Shopping links are hidden.</string>
<string name="revanced_hide_shopping_links_title">Hide shopping links</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,12 @@ Note: This feature hasn't been tested."</string>
<string name="revanced_hide_shopping_links_summary_off">Shopping links are shown.</string>
<string name="revanced_hide_shopping_links_summary_on">Shopping links are hidden.</string>
<string name="revanced_hide_shopping_links_title">Hide shopping links</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,12 @@
<string name="revanced_hide_playables_summary_off">Playables are shown</string>
<string name="revanced_hide_playables_summary_on">Playables are hidden</string>
<string name="revanced_hide_playables_title">Hide playables</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,12 @@
<string name="revanced_hide_playables_summary_off">Playables are shown</string>
<string name="revanced_hide_playables_summary_on">Playables are hidden</string>
<string name="revanced_hide_playables_title">Hide playables</string>
<string name="revanced_hide_shorts_live_chat_summary_off">Live chat messages are shown</string>
<string name="revanced_hide_shorts_live_chat_summary_on">Live chat messages are hidden</string>
<string name="revanced_hide_shorts_live_chat_title">Hide live chat messages</string>
<string name="revanced_hide_shorts_live_header_summary_off">Live chat header is shown.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_summary_on">Live chat header is hidden.\n\nBack button in header won't be hidden.</string>
<string name="revanced_hide_shorts_live_header_title">Hide live chat header</string>
<string name="revanced_hide_shorts_location_label_summary_off">Location label is shown.</string>
<string name="revanced_hide_shorts_location_label_summary_on">Location label is hidden.</string>
<string name="revanced_hide_shorts_location_label_title">Hide location label</string>
Expand Down
Loading

0 comments on commit 71de5f4

Please sign in to comment.