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

Question about Firefox #153

Closed
Srini-B opened this issue Nov 23, 2022 · 3 comments
Closed

Question about Firefox #153

Srini-B opened this issue Nov 23, 2022 · 3 comments

Comments

@Srini-B
Copy link

Srini-B commented Nov 23, 2022

Hi, can anyone confirm me if URLs from Firefox are captured, It doesn't work for me. I also have userchrome.css enabled which modifies the UI, maybe it's the cause. I'm on macOS 13.0.1

@anis-dr
Copy link

anis-dr commented Jul 13, 2023

I'm having the same issue, URLs are not captured from Firefox

@vojtabohm
Copy link

This is because it does not work with the approach this library uses (which is to use AppleScript to 'tell' the browser to return it's url). I solved this a while ago on my macOS project. You can actually use Accessibility API to get it.

  1. You need to set AXManualAccessibility on the Firefox process, which will enable it's DOM to be visible (this property tells the app a 'Screen reader' is present on the screen, so this is a sort of a hack).
  2. Traverse the Firefox's DOM (consisting of AXUIElement) using BFS until you find a node that has a url attribute and read that.

It's a hassle to add this, but unfortunately, no better way to do this for Firefox. I read their forums a while back.

@sindresorhus
Copy link
Owner

Duplicate of #172

@sindresorhus sindresorhus marked this as a duplicate of #172 Aug 9, 2024
@sindresorhus sindresorhus closed this as not planned Won't fix, can't repro, duplicate, stale Aug 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants