<?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>145265</bug_id>
          
          <creation_ts>2015-05-21 07:41:12 -0700</creation_ts>
          <short_desc>Changing the type attribute on an input field causes later events to stop propagation</short_desc>
          <delta_ts>2022-08-19 16:12: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>DOM</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>OS X 10.10</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          
          <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="Charlie">blevins.charlie</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>ahmad.saleem792</cc>
    
    <cc>ap</cc>
    
    <cc>bfulgham</cc>
    
    <cc>cdumez</cc>
    
    <cc>rniwa</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1096576</commentid>
    <comment_count>0</comment_count>
    <who name="Charlie">blevins.charlie</who>
    <bug_when>2015-05-21 07:41:12 -0700</bug_when>
    <thetext>Changing the type attribute on an input field onfocus causes the click event to stop propagation.

Example: http://jsfiddle.net/7ps7LzrL/6/

I realize that this may be by design, however I was not able to find any documentation about this type of behavior.

Expected Output: The click event would fire after the focus event.

Received Output: The click event is not fired on the input after the focus event.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1096800</commentid>
    <comment_count>1</comment_count>
      <attachid>253580</attachid>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2015-05-22 00:00:46 -0700</bug_when>
    <thetext>Created attachment 253580
test case

Same test as an attachment.

For what it&apos;s worth, this behavior matches Firefox. I don&apos;t know if that&apos;s intentional, this seems like a very rare case.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1892526</commentid>
    <comment_count>2</comment_count>
    <who name="Ahmad Saleem">ahmad.saleem792</who>
    <bug_when>2022-08-19 15:17:06 -0700</bug_when>
    <thetext>Please find updated results:

*** Safari Technology Preview 151 ***

First click in input filed -&gt; just &quot;focus&quot; event
Second click in input field -&gt; &quot;focus&quot; and then &quot;click&quot; event

*** Chrome Canary 106 ***

First click in input filed -&gt; just &quot;focus&quot; event
Second click in input field -&gt; &quot;focus&quot; and then &quot;click&quot; event

*** Firefox Nightly 105 ***

First click in input filed -&gt; &quot;focus&quot; and then &quot;click&quot; event</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>253580</attachid>
            <date>2015-05-22 00:00:46 -0700</date>
            <delta_ts>2015-05-22 00:00:46 -0700</delta_ts>
            <desc>test case</desc>
            <filename>145265.html</filename>
            <type>text/html</type>
            <size>562</size>
            <attacher name="Alexey Proskuryakov">ap</attacher>
            
              <data encoding="base64">PGJvZHk+Cjxmb3JtIGFjdGlvbj0iIyI+CiAgICA8aW5wdXQgdHlwZT0iZW1haWwiIGlkPSJlbWFp
bEZpZWxkIj4KPC9mb3JtPgogICAgCjxkaXYgaWQ9Im91dHB1dCI+PC9kaXY+CjxzY3JpcHQ+CnZh
ciBlbWFpbEZpZWxkID0gZG9jdW1lbnQuZ2V0RWxlbWVudEJ5SWQoJ2VtYWlsRmllbGQnKTsKZW1h
aWxGaWVsZC5vbmNsaWNrID0gY2xrOwplbWFpbEZpZWxkLm9uZm9jdXMgPSBmb2M7Cgp2YXIgb3V0
cHV0ID0gZG9jdW1lbnQuZ2V0RWxlbWVudEJ5SWQoJ291dHB1dCcpOwpmdW5jdGlvbiBjbGsgKCkg
ewogICAgb3V0cHV0LmlubmVySFRNTCA9IG91dHB1dC5pbm5lckhUTUwgKyAnY2xpY2s8YnI+JzsK
fQpmdW5jdGlvbiBmb2MgKCkgewogICAgb3V0cHV0LmlubmVySFRNTCA9IG91dHB1dC5pbm5lckhU
TUwgKyAnZm9jdXM8YnI+JzsKICAgIAogICAgLy8gVGhpcyBsaW5lIGNhdXNlcyB0aGUgcHJvcGFn
YXRpb24gb2YgdGhlIAogICAgLy8gY2xpY2sgZXZlbnQgdG8gc3RvcAogICAgZW1haWxGaWVsZC5z
ZXRBdHRyaWJ1dGUoJ3R5cGUnLCAndGV4dCcpOwp9Cjwvc2NyaXB0Pgo8L2JvZHk+Cg==
</data>

          </attachment>
      

    </bug>

</bugzilla>