<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>289703</bug_id>
          
          <creation_ts>2025-03-13 06:33:54 -0700</creation_ts>
          <short_desc>Page freezes when focusing input in popover with form on iOS 18.2+</short_desc>
          <delta_ts>2025-03-13 07:37:27 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>New Bugs</component>
          <version>Safari 18</version>
          <rep_platform>iPhone / iPad</rep_platform>
          <op_sys>iOS 18</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>285811</dup_id>
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Bregt">bregt.delange</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>ntim</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>2102902</commentid>
    <comment_count>0</comment_count>
    <who name="Bregt">bregt.delange</who>
    <bug_when>2025-03-13 06:33:54 -0700</bug_when>
    <thetext>I&apos;m using the Popover API to open an element that contains a form:

However, I have issues with trying the following situations to create just that

1. Using a &lt;dialog&gt; combined with a form and input causes it to block the rest of the page (https://bugs.webkit.org/show_bug.cgi?id=276864)
2. Instead I tried using a &lt;div&gt; with role=&quot;dialog&quot; and adding autofocus on the input, but that doesn&apos;t even open the popover and freezes the page. Autofocus seems to be the issue because when I removed that attribute from the input, the popover opens.
3. Skipping all that I tried using a form with an input field, and while that form opens, as soon as I focus the field the page freezes again.

This above works fine in all browsers supporting Popover API, except for Safari 18.2+ on iOS (it does work on MacOS and iOS 18 or lower).

Is there something I miss because I seem to be blocked with the combination of a form and popover on iOS Safari. Forms and popover API seem to be unusable?

Here&apos;s a Codepen with multiple situations
https://codepen.io/Bregt/pen/MYWEpvd</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2102913</commentid>
    <comment_count>1</comment_count>
    <who name="Tim Nguyen (:ntim)">ntim</who>
    <bug_when>2025-03-13 07:37:27 -0700</bug_when>
    <thetext>This is fixed in Safari 18.4 beta: https://developer.apple.com/documentation/safari-release-notes/safari-18_4-release-notes

*** This bug has been marked as a duplicate of bug 285811 ***</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>