<?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>248401</bug_id>
          
          <creation_ts>2022-11-28 09:13:36 -0800</creation_ts>
          <short_desc>ValidityState reports &quot;valid&quot; for partially completed dates</short_desc>
          <delta_ts>2023-05-05 22:27:08 -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>Forms</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>Mac (Intel)</rep_platform>
          <op_sys>macOS 11</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=148873</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>BrowserCompat, InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Jeremy Frey">jeremy.m.frey</reporter>
          <assigned_to name="Tim Nguyen (:ntim)">ntim</assigned_to>
          <cc>akeerthi</cc>
    
    <cc>cdumez</cc>
    
    <cc>karlcow</cc>
    
    <cc>webkit-bug-importer</cc>
    
    <cc>wenson_hsieh</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1914996</commentid>
    <comment_count>0</comment_count>
    <who name="Jeremy Frey">jeremy.m.frey</who>
    <bug_when>2022-11-28 09:13:36 -0800</bug_when>
    <thetext>Repro steps:

1. In an `&lt;input type=&quot;date&quot; /&gt;` element, use the keyboard to enter the month, day, or year portion of the date.
2. Leave the other date parts blank.
3. Inspect the element&apos;s ValidityState.

Expected:

`{ badInput: true, valid: false }`

Actual:

`{ badInput: false, valid: true }`

AFAIK, Blink and Gecko report badInput: true in this scenario.

A closely-related question was asked on SO which doesn&apos;t have any answers due to the current behavior: https://stackoverflow.com/questions/72915862/javascript-date-input-in-safari-validation-31-of-february-year</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1916644</commentid>
    <comment_count>1</comment_count>
    <who name="Karl Dubost">karlcow</who>
    <bug_when>2022-12-05 01:02:09 -0800</bug_when>
    <thetext>Probably related to http://wpt.live/html/semantics/forms/constraints/form-validation-checkValidity.html
https://wpt.fyi/results/html/semantics/forms/constraints/form-validation-checkValidity.html?label=experimental&amp;label=master&amp;aligned</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1916712</commentid>
    <comment_count>2</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2022-12-05 09:14:17 -0800</bug_when>
    <thetext>&lt;rdar://problem/102984901&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1953314</commentid>
    <comment_count>3</comment_count>
    <who name="Tim Nguyen (:ntim)">ntim</who>
    <bug_when>2023-05-05 14:58:26 -0700</bug_when>
    <thetext>Pull request: https://github.com/WebKit/WebKit/pull/13523</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1953377</commentid>
    <comment_count>4</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2023-05-05 22:27:05 -0700</bug_when>
    <thetext>Committed 263748@main (ec9036933491): &lt;https://commits.webkit.org/263748@main&gt;

Reviewed commits have been landed. Closing PR #13523 and removing active labels.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>