Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for images on Google "All" page #467

Merged
merged 3 commits into from
May 25, 2024

Conversation

aug-dev
Copy link
Contributor

@aug-dev aug-dev commented May 20, 2024

Summary

This PR adds a feature suggested by issue #462, where images in the "All" section of Google Desktop are now supported by the extension.

Here's a demo:

demo-images.webm

Additional Comments

Now with the knowledge from the master, I'm closer to enlightenment...

Jokes aside, thanks for you suggestion to use pageHandlers, I was about to go down some weird rabbit hole involving delays and setTimeout.

By the way, the use of recursion in the following snippet was really clever, my brain got really happy when I understood it LOL.

const pagerElements =
typeof innerTargets === "string"
? element.querySelectorAll<HTMLElement>(innerTargets)
: innerTargets(element);
for (const pagerElement of pagerElements) {
const { controls: pagerControls, entries: pagerEntries } =
onSerpElement(pagerElement);
controls.push(...pagerControls);
entries.push(...pagerEntries);
}

@iorate iorate merged commit 8f1b01d into iorate:master May 25, 2024
1 check passed
Copy link

🎉 This PR is included in version 8.7.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@aug-dev aug-dev deleted the fix-img-suggest-box branch May 26, 2024 23:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants