<?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>227224</bug_id>
          
          <creation_ts>2021-06-21 10:52:16 -0700</creation_ts>
          <short_desc>Text disappears for multiple seconds when font requested but load interrupted</short_desc>
          <delta_ts>2021-06-28 10:53:14 -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>Text</component>
          <version>Safari 14</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=227143</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Trivial</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>ian</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>mmaxfield</cc>
    
    <cc>webkit-bug-importer</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1771344</commentid>
    <comment_count>0</comment_count>
    <who name="">ian</who>
    <bug_when>2021-06-21 10:52:16 -0700</bug_when>
    <thetext>In Safari/Mobile Safari 14 text stops rendering for a several seconds in an peculiar circumstance:

• Nothing on the page initially needed a font specified in @font-face.
• A style was changed such that that font is now needed, triggering the lazy load.
• The font-face in question has font-display:auto.
• The font download is ~interrupted~ after it&apos;s requested.

In Chrome, Firefox, and earlier versions of Safari there is an observable but brief &apos;blink&apos; (maybe ~250ms), but in Safari 14 the disappearance can be several seconds long

Reproduction is here: http://ianbellomy.com/test/font-failure-test.html

(Note that caching may eliminate the issue if the page is refreshed.)

Admittedly the situation is pretty peculiar but it also seems like &apos;auto&apos; should not lead to a behavior like this. 

FWIW, I ran into this after having done something bone-headed but it seems possible to inadvertently hit this in a large project, if, through some project change, a font is no longer needed on initial presentation, and additional network traffic is needed to properly display the site. In a PWA type situation for example a user might install the PWA but not hit an area that needs a font until they go to use the PWA while offline. I haven&apos;t tested for a &apos;failed&apos; response though (opposed to an interruption).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1773134</commentid>
    <comment_count>1</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2021-06-28 10:53:14 -0700</bug_when>
    <thetext>&lt;rdar://problem/79871859&gt;</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>