[Webkit-unassigned] [Bug 282025] New: REGRESSION: "tabs" field missing from windows.create returned windows.Window

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Oct 23 19:53:15 PDT 2024


https://bugs.webkit.org/show_bug.cgi?id=282025

            Bug ID: 282025
           Summary: REGRESSION: "tabs" field missing from windows.create
                    returned windows.Window
           Product: WebKit
           Version: Safari 18
          Hardware: Mac (Apple Silicon)
                OS: macOS 15
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: WebKit Extensions
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: medias.medial.06 at icloud.com
                CC: timothy at apple.com, webkit-bug-importer at group.apple.com

The `tabs` field missing from windows.create returned windows.Window, where the `tabs` field was supposed to be available according to MDN:

https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/windows/create#return_value
>This Window object will always have its tabs property set, unlike the Window objects returned from windows.get() and similar APIs, which only contain tabs if the populate option is passed.

and it used to be available prior to Safari 18.

# Reproduce

manifest.json

```json
{
  "manifest_version": 2,
  "name": "example",
  "version": "0.0.0",
  "permissions": ["<all_urls>"],
  "background": {
    "page": "background.html",
    "persistent": true
  }
}
```

background.html

```html
<script type="module" crossorigin src="./background.js"></script>
```

background.js

```js
console.log(await browser.windows.create({ url: 'https://example.com', type: 'popup' }))
```

# Expected Result:

Safari 17.6

```json
{
  "alwaysOnTop": false,
  "focused": true,
  "height": 809,
  "id": 9,
  "incognito": false,
  "left": 184,
  "state": "normal",
  "tabs": [
    {
      "active": true,
      "audible": false,
      "height": 809,
      "highlighted": true,
      "id": 34,
      "incognito": false,
      "index": 0,
      "isArticle": false,
      "isInReaderMode": false,
      "mutedInfo": { "muted": false },
      "pendingUrl": "https://example.com/",
      "pinned": false,
      "status": "loading",
      "url": "https://example.com/",
      "width": 1010,
      "windowId": 9
    }
  ],
  "top": 25,
  "type": "popup",
  "width": 1010
}
```

# Actual Result:

Safari 18.0.1

```json
{
  "alwaysOnTop": false,
  "focused": true,
  "height": 1415,
  "id": 320718,
  "incognito": false,
  "left": 244,
  "state": "normal",
  "top": 25,
  "type": "popup",
  "width": 2316
}
```

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20241024/8b7db480/attachment.htm>


More information about the webkit-unassigned mailing list