Skip to content

Commit a522495

Browse files
fix(YouTube - Hide layout components): Fix "Hide AI-generated video summary" in video description
1 parent 9a286b4 commit a522495

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

extensions/youtube/src/main/java/app/revanced/extension/youtube/patches/components/DescriptionComponentsFilter.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,12 @@ public DescriptionComponentsFilter() {
104104
@Override
105105
boolean isFiltered(@Nullable String identifier, String path, byte[] protobufBufferArray,
106106
StringFilterGroup matchedGroup, FilterContentType contentType, int contentIndex) {
107+
108+
if (matchedGroup == aiGeneratedVideoSummarySection) {
109+
// Only hide if player is open, in case this component is used somewhere else.
110+
return PlayerType.getCurrent().isMaximizedOrFullscreen();
111+
}
112+
107113
if (exceptions.matches(path)) return false;
108114

109115
if (matchedGroup == macroMarkersCarousel) {

0 commit comments

Comments
 (0)