Open Bug 1918655 Opened 2 months ago Updated 24 days ago

Wrong tab focused with `window.open(); window.close()`

Categories

(Fenix :: Tabs, defect)

Firefox 133
All
Android
defect

Tracking

(firefox131 affected, firefox132 affected, firefox133 affected)

Tracking Status
firefox131 --- affected
firefox132 --- affected
firefox133 --- affected

People

(Reporter: jgraham, Unassigned)

References

(Blocks 1 open bug)

Details

(Keywords: webcompat:platform-bug)

Attachments

(1 file)

Given three pages like the following:

test1.html

<!doctype html>
<p>This is the first page</p>
<a onclick="window.open('test2.html')">Click me</a>

test2.html

<!doctype html>
<p>This is the intermediate page</p>
<a onclick="window.open('test3.html'); window.close()">Click me</a>

test3.html

<!doctype html>
<p>This is the last page</p>

Then loading test1.html and following the instructions leads to the tab with test1.html focused and test3.html in the background. It's expected this leads to test3.html in the foreground. Note the dependency where this breaks (or at least causes user confusion) for an apple.com support flow.

The severity field is not set for this bug.
:007, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(nbond)

QE, could you please try to reproduce this and provide some STR?

Flags: needinfo?(nbond) → qe-verify+

The following STR were performed in order to attempt to reproduce this issue:

  1. Create all 3 html on the Android using a code editor app
  2. Install and use File Manager Plus to open the html files on Firefox for Android.
  3. Open the test1.html file > Tap on the “Click me” button.
  4. Once the test2.html file is opened, tap on the “Click me” button.
  5. Observe if the test3.html page is opened.

If I understood correctly, after Step 4, the test3.html page should be opened and focused.
Instead, the already opened test1.html is re-focused > then the the already opened test2.html is re-focused, and the test3.html is opened in a new tab in the background.
From here, each time the “Click me” button from test2.html is tapped, the test3.html is also opened in a new tab in the background, but never focused.

Tested with Google Pixel 8 Pro (Android 14) on all latest releases: Nightly 133.0a1, Beta 132.0b8, Release 131.0.3.

Severity: -- → S3
Flags: qe-verify+
Version: unspecified → Firefox 133
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: