Skip to content

Commit

Permalink
fix(google): hide/highlight whole featured snippets
Browse files Browse the repository at this point in the history
  • Loading branch information
iorate committed Dec 11, 2022
1 parent 7d42ed7 commit 6836e13
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/scripts/search-engines/google-desktop.ts
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,8 @@ const desktopSerpHandlers: Record<string, SerpHandler> = {
// Featured Snippet
{
target: '.g .xpdopen .ifM9O .g',
level: target => target.parentElement?.closest('.g') ?? null,
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
level: target => target.closest('.M8OgIe') || target.parentElement!.closest('.g'),
url: '.yuRUbf > a',
title: 'h3',
actionTarget: '.eFM0qc',
Expand Down

0 comments on commit 6836e13

Please sign in to comment.