Skip to content

Issue with @react-aria/aria-modal-polyfill@3.4.1 distributed files #2855

@JasonKaz

Description

@JasonKaz

🐛 Bug Report

The most recent update (3.4.1) to @react-aria/aria-modal-polyfill broke our local build process.

In version 3.4.0 this line was distributed as:
let addNode = Array.from(mutation.addedNodes).find(node => node.querySelector == null ? void 0 : node.querySelector('[aria-modal="true"], [data-ismodal="true"]'));

In 3.4.1 it is:
let addNode = Array.from(mutation.addedNodes).find((node)=>node.querySelector?.('[aria-modal="true"], [data-ismodal="true"]')

Our build broke because we are not transpiling the ?. operator for external modules. We could make it support that, but clearly something changed with the build process in this repo to change the output like that.

🤔 Expected Behavior

😯 Current Behavior

💁 Possible Solution

🔦 Context

💻 Code Sample

🌍 Your Environment

Software Version(s)
react-spectrum
Browser
Operating System

🧢 Your Company/Team

Adobe/Admin Console team

🕷 Tracking Issue (optional)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions