<?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>260641</bug_id>
          
          <creation_ts>2023-08-23 17:44:16 -0700</creation_ts>
          <short_desc>AX: intent to remove non-standard role=text feature</short_desc>
          <delta_ts>2025-12-11 17:53:41 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Accessibility</component>
          <version>WebKit Nightly Build</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=260685</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="James Craig">jcraig</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>andresg_22</cc>
    
    <cc>herr.ernst</cc>
    
    <cc>webkit-bug-importer</cc>
    
    <cc>yegor.jbanov</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1973158</commentid>
    <comment_count>0</comment_count>
    <who name="James Craig">jcraig</who>
    <bug_when>2023-08-23 17:44:16 -0700</bug_when>
    <thetext>AX: Consider dropping role=text (non-standard, WebKit-only implementation, that the ARIA WG declined to specify)

WebKit&apos;s role=text was never in a shipping version of ARIA, and WebKit&apos;s implementation pre-dated any spec discussion. Once the feature was discussed, the ARIA Working Group had a variety of concerns and declined to adopt it. As far as I know, it has never shipped in any other engine.

1. The original use case (workaround) is no longer used in a high-profile product. (That product was the reason we couldn&apos;t originally drop support when ARIA declined to standardize it.) 
2. The implementation makes any interactive descendants entirely inaccessible, which is often not the intention of authors, and unknown to them when they don’t test in VoiceOver, etc. This could potentially be fixed, but we think the fix is riskier and has a higher performance cost than dropping support.
3. There are other, standard ways to achieve combined content label... The primary benefit of WebKit&apos;s `role=text` implementation.
4. There are some sites still using it, mostly due to legacy support of a jQuery Ratings widget, but we don&apos;t believe removing this support will break anything... A VO user might just hear a slightly more verbose label in places.


So it seems like the right time for WebKit to drop support for the non-standard `role=text` feature.

Current plan-of-record is to leave support behind a deselected runtime flag... Providing a temporary user workaround in case some high-traffic site is relying on this for some reason.

I&apos;m posting this intent-to-remove-non-standard-text-role here so we can shop the idea around, in case others have concerns.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1973159</commentid>
    <comment_count>1</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2023-08-23 17:44:23 -0700</bug_when>
    <thetext>&lt;rdar://problem/114354058&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1973408</commentid>
    <comment_count>2</comment_count>
    <who name="James Craig">jcraig</who>
    <bug_when>2023-08-24 18:01:52 -0700</bug_when>
    <thetext>Patch up at https://webkit.org/b/260684</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1973409</commentid>
    <comment_count>3</comment_count>
    <who name="James Craig">jcraig</who>
    <bug_when>2023-08-24 18:05:14 -0700</bug_when>
    <thetext>Tracker to remove entirely at some point in the future is https://webkit.org/b/260685</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2013337</commentid>
    <comment_count>4</comment_count>
    <who name="Yegor">yegor.jbanov</who>
    <bug_when>2024-02-13 15:48:25 -0800</bug_when>
    <thetext>Consider not removing role=text. When text is rendered into a 2d, WebGL, or WebGPU canvas a DOM overlay is necessary to communicate to a screen reader such as VoiceOver what text is rendered in the canvas. Currently, thanks to role=text in Safari there&apos;s a clean way to annotate it (and VoiceOver does a good job of reading it). Other browsers require hacks to make text work, such as artificially giving the text a different role (e.g. heading, or group, even when the text is neither).

I filed a feature request for Chromium to adopt role=text with more detail: https://issues.chromium.org/issues/40875151

I hope you reconsider and instead push for the standards committee to adopt the text role.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2013340</commentid>
    <comment_count>5</comment_count>
    <who name="Yegor">yegor.jbanov</who>
    <bug_when>2024-02-13 15:50:28 -0800</bug_when>
    <thetext>For an example of a high-traffic site, earth.google.com uses it in Safari (transitively via Flutter).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2013343</commentid>
    <comment_count>6</comment_count>
    <who name="Yegor">yegor.jbanov</who>
    <bug_when>2024-02-13 15:52:48 -0800</bug_when>
    <thetext>I wish I knew about this intent earlier, but this went through way too quickly. I posted more detail in https://bugs.webkit.org/show_bug.cgi?id=260641, but I think it&apos;s better to push other browsers to adopt this role rather than remove it. There&apos;s an important use-case for the text role.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2014009</commentid>
    <comment_count>7</comment_count>
    <who name="Yegor">yegor.jbanov</who>
    <bug_when>2024-02-15 10:53:25 -0800</bug_when>
    <thetext>Sorry, I meant to post my last message in https://bugs.webkit.org/show_bug.cgi?id=260685, not here.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2165295</commentid>
    <comment_count>8</comment_count>
    <who name="James Craig">jcraig</who>
    <bug_when>2025-12-11 17:47:32 -0800</bug_when>
    <thetext>&gt;  I think it&apos;s better to push other browsers to adopt this role rather than remove it. 

Steve Faulkner and I made that case as long ago as 2011. The ARIA Working Group has rejected it a number of times since then. Some of the ancient history is linked in:

https://github.com/w3c/aria/issues/870#issuecomment-705827591</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2165298</commentid>
    <comment_count>9</comment_count>
    <who name="James Craig">jcraig</who>
    <bug_when>2025-12-11 17:50:29 -0800</bug_when>
    <thetext>As for current status, `role=text` support is now behind an ON-by-default feature flag. The OFF-by-default flag was inverted while additional text stitching issue are being worked out in VoiceOver. https://webkit.org/b/260684</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2165302</commentid>
    <comment_count>10</comment_count>
    <who name="James Craig">jcraig</who>
    <bug_when>2025-12-11 17:53:41 -0800</bug_when>
    <thetext>&gt; When text is rendered into a 2d, WebGL, or WebGPU canvas a DOM overlay is necessary to communicate to a screen reader what text is rendered in the canvas.

Look into the HTML-in-Canvas proposal:
https://github.com/WICG/html-in-canvas</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>