Skip to content

Commit

Permalink
feat(YouTube - Hide layout components): Add `Hide videos based on dur…
Browse files Browse the repository at this point in the history
…ation`
  • Loading branch information
anddea committed May 5, 2024
1 parent 98c2f99 commit ebd6955
Show file tree
Hide file tree
Showing 24 changed files with 144 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 @@ -773,6 +773,12 @@ Some components may not be hidden."</string>
<string name="revanced_hide_video_ads_summary_off">Video ads are shown.</string>
<string name="revanced_hide_video_ads_summary_on">Video ads are hidden.</string>
<string name="revanced_hide_video_ads_title">Hide video ads</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_gray_description_summary">"Hide videos with gray description from search results.
Videos with a gray description include videos that are not related to search terms."</string>
<string name="revanced_hide_video_with_gray_description_title">Hide videos with gray description</string>
Expand Down
6 changes: 6 additions & 0 deletions src/main/resources/youtube/settings/xml/revanced_prefs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,12 @@
<app.revanced.integrations.youtube.settingsmenu.ResettableEditTextPreference android:title="@string/revanced_hide_video_with_greater_than_views_num_title" android:key="revanced_hide_video_with_greater_than_views_num" android:defaultValue="1 000 000 000 000" android:summary="@string/revanced_hide_video_with_greater_than_views_num_summary" android:inputType="number" />
<app.revanced.integrations.youtube.settingsmenu.ResettableEditTextPreference android:title="@string/revanced_hide_video_with_low_view_num_multiplier_title" android:key="revanced_hide_video_with_low_view_num_multiplier" android:summary="@string/revanced_hide_video_with_low_view_num_multiplier_summary" android:defaultValue="@string/revanced_hide_video_with_low_view_num_multiplier_value" android:inputType="textMultiLine" />
<SwitchPreference android:title="@string/revanced_hide_video_with_low_view_old_title" android:key="revanced_hide_video_with_low_view_old" android:defaultValue="false" android:summary="@string/revanced_hide_video_with_low_view_old_summary" />
</PreferenceScreen>
<PreferenceScreen android:title="@string/revanced_hide_video_with_duration_title" android:key="duration" android:summary="@string/revanced_hide_video_with_duration_summary">
<Preference android:title=" " android:selectable="false" android:summary="@string/revanced_hide_video_with_duration_title" />
<SwitchPreference android:title="@string/revanced_hide_video_with_duration_title" android:key="revanced_hide_video_with_duration" android:defaultValue="false" android:summary="@string/revanced_hide_video_with_duration_summary" />
<app.revanced.integrations.youtube.settingsmenu.ResettableEditTextPreference android:title="@string/revanced_hide_video_with_duration_shorter_than_title" android:key="revanced_hide_video_with_duration_shorter_than" android:defaultValue="0:10" android:summary="@string/revanced_hide_video_with_duration_shorter_than_summary" android:inputType="text" />
<app.revanced.integrations.youtube.settingsmenu.ResettableEditTextPreference android:title="@string/revanced_hide_video_with_duration_longer_than_title" android:key="revanced_hide_video_with_duration_longer_than" android:defaultValue="10:10:10:10" android:summary="@string/revanced_hide_video_with_duration_longer_than_summary" android:inputType="text" />
</PreferenceScreen> SETTINGS: HIDE_LAYOUT_COMPONENTS -->

<!-- SETTINGS: HIDE_CHANNEL_PROFILE_COMPONENTS
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,12 @@
<string name="revanced_hide_shorts_tagged_products_summary_off">Tagged products are shown</string>
<string name="revanced_hide_shorts_tagged_products_summary_on">Tagged products are hidden</string>
<string name="revanced_hide_shorts_tagged_products_title">Hide tagged products</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_greater_than_views_num_summary">Videos with views greater than this number will be hidden.</string>
<string name="revanced_hide_video_with_greater_than_views_num_title">Greater than views</string>
<string name="revanced_spoof_app_version_target_entry_17_33_42">17.33.42 - Restore old UI layout</string>
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,12 @@
<string name="revanced_hide_shorts_tagged_products_title">Hide tagged products</string>
<string name="revanced_hide_suggested_video_overlay_auto_play_summary">When you finished a video, another play automatically</string>
<string name="revanced_hide_suggested_video_overlay_auto_play_title">Auto play the next video</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_greater_than_views_num_summary">Videos with views greater than this number will be hidden.</string>
<string name="revanced_hide_video_with_greater_than_views_num_title">Greater than views</string>
<string name="revanced_hide_video_with_less_than_views_num_summary">Videos with views less than this number will be hidden.</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,12 @@ Some components may not be hidden."</string>
<string name="revanced_hide_store_tab_title">Hide store tab</string>
<string name="revanced_hide_suggested_video_overlay_auto_play_summary">When you finished a video, another play automatically</string>
<string name="revanced_hide_suggested_video_overlay_auto_play_title">Auto play the next video</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_gray_description_summary">"Hide videos with gray description from search results.
Videos with a gray description include videos that are not related to search terms."</string>
<string name="revanced_hide_video_with_gray_description_title">Hide videos with gray description</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,12 @@ Some components may not be hidden."</string>
<string name="revanced_hide_store_tab_title">Hide store tab</string>
<string name="revanced_hide_suggested_video_overlay_auto_play_summary">When you finished a video, another play automatically</string>
<string name="revanced_hide_suggested_video_overlay_auto_play_title">Auto play the next video</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_gray_description_summary">"Hide videos with gray description from search results.
Videos with a gray description include videos that are not related to search terms."</string>
<string name="revanced_hide_video_with_gray_description_title">Hide videos with gray description</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,11 @@
<string name="revanced_hide_shorts_shelf_player_summary_off">Shorts in player are shown.</string>
<string name="revanced_hide_shorts_shelf_player_summary_on">Shorts in player are hidden.</string>
<string name="revanced_hide_shorts_shelf_player_title">Hide Shorts in player</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_greater_than_views_num_summary">Videos with views greater than this number will be hidden.</string>
<string name="revanced_hide_video_with_greater_than_views_num_title">Greater than views</string>
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,11 @@
<string name="revanced_hide_shorts_shelf_player_summary_off">Shorts in player are shown.</string>
<string name="revanced_hide_shorts_shelf_player_summary_on">Shorts in player are hidden.</string>
<string name="revanced_hide_shorts_shelf_player_title">Hide Shorts in player</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_greater_than_views_num_summary">Videos with views greater than this number will be hidden.</string>
<string name="revanced_hide_video_with_greater_than_views_num_title">Greater than views</string>
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,12 @@ Some components may not be hidden."</string>
<string name="revanced_hide_store_tab_title">Hide store tab</string>
<string name="revanced_hide_suggested_video_overlay_auto_play_summary">When you finished a video, another play automatically</string>
<string name="revanced_hide_suggested_video_overlay_auto_play_title">Auto play the next video</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_gray_description_summary">"Hide videos with gray description from search results.
Videos with a gray description include videos that are not related to search terms."</string>
<string name="revanced_hide_video_with_gray_description_title">Hide videos with gray description</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,12 @@
<string name="revanced_hide_shorts_tagged_products_summary_off">Tagged products are shown</string>
<string name="revanced_hide_shorts_tagged_products_summary_on">Tagged products are hidden</string>
<string name="revanced_hide_shorts_tagged_products_title">Hide tagged products</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_greater_than_views_num_summary">Videos with views greater than this number will be hidden.</string>
<string name="revanced_hide_video_with_greater_than_views_num_title">Greater than views</string>
<string name="revanced_spoof_app_version_target_entry_17_33_42">17.33.42 - Restore old UI layout</string>
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,12 @@
<string name="revanced_hide_shorts_tagged_products_summary_off">Tagged products are shown</string>
<string name="revanced_hide_shorts_tagged_products_summary_on">Tagged products are hidden</string>
<string name="revanced_hide_shorts_tagged_products_title">Hide tagged products</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_greater_than_views_num_summary">Videos with views greater than this number will be hidden.</string>
<string name="revanced_hide_video_with_greater_than_views_num_title">Greater than views</string>
<string name="revanced_hide_video_with_less_than_views_num_summary">Videos with views less than this number will be hidden.</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,12 @@
<string name="revanced_hide_store_tab_title">Hide store tab</string>
<string name="revanced_hide_suggested_video_overlay_auto_play_summary">When you finished a video, another play automatically</string>
<string name="revanced_hide_suggested_video_overlay_auto_play_title">Auto play the next video</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_gray_description_summary">"Hide videos with gray description from search results.
Videos with a gray description include videos that are not related to search terms."</string>
<string name="revanced_hide_video_with_gray_description_title">Hide videos with gray description</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,12 @@
<string name="revanced_hide_store_tab_title">Hide store tab</string>
<string name="revanced_hide_suggested_video_overlay_auto_play_summary">When you finished a video, another play automatically</string>
<string name="revanced_hide_suggested_video_overlay_auto_play_title">Auto play the next video</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_gray_description_summary">"Hide videos with gray description from search results.
Videos with a gray description include videos that are not related to search terms."</string>
<string name="revanced_hide_video_with_gray_description_title">Hide videos with gray description</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,12 @@
<string name="revanced_hide_shorts_tagged_products_summary_off">Tagged products are shown</string>
<string name="revanced_hide_shorts_tagged_products_summary_on">Tagged products are hidden</string>
<string name="revanced_hide_shorts_tagged_products_title">Hide tagged products</string>
<string name="revanced_hide_video_with_duration_longer_than_summary">Videos with duration longer than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_longer_than_title">Longer than duration</string>
<string name="revanced_hide_video_with_duration_shorter_than_summary">Videos with duration shorter than this number will be hidden.</string>
<string name="revanced_hide_video_with_duration_shorter_than_title">Shorter than duration</string>
<string name="revanced_hide_video_with_duration_summary">Hide videos with shorter than or longer than duration.</string>
<string name="revanced_hide_video_with_duration_title">Hide videos based on duration</string>
<string name="revanced_hide_video_with_greater_than_views_num_summary">Videos with views greater than this number will be hidden.</string>
<string name="revanced_hide_video_with_greater_than_views_num_title">Greater than views</string>
<string name="revanced_spoof_app_version_target_entry_17_33_42">17.33.42 - Restore old UI layout</string>
Loading

0 comments on commit ebd6955

Please sign in to comment.