question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Accessibility] SectionList not render the group with title for each session

See original GitHub issue

Description

When using SessionList, each item is rendered but don’t have any associate with the header

React Native version:

Run react-native info in your terminal and copy the results here. 0.6.3

Steps To Reproduce

Related to this example: https://reactnative.dev/docs/sectionlist The DOM render like:

<div role="header">
    <div>Main dishes</div>
</div>
<div role="menuitem">
    <div>Pizza</div>
</div>
<div role="menuitem">
    <div>Burger</div>
</div>
  • Each group render 1 item for header and some items for the content. So that, all of them have equal level and the screen reader can not know the category of the menu item when focus to it.

Expected Results

SessionList should support group for each session, so that the screen reader will figure out the session title and will speak the title when focus to the session item

<div role="menuitem" aria-label="Main dishes">
    <div role="header">
        <div>Main dishes</div>
    </div>
    <div role="group" aria-label="Main dishes">
        <div role="menuitem">
            <div>Pizza</div>
        </div>
        <div role="menuitem">
            <div>Burger</div>
        </div>
    </div>
</div>

Snack, code example, screenshot, or link to a repository:

Please provide a Snack (https://snack.expo.io/), a link to a repository on GitHub, or provide a minimal code example that reproduces the problem. You may provide a screenshot of the application if you think it is relevant to your bug report. Here are some tips for providing a minimal example: https://stackoverflow.com/help/mcve

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:8 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
necolascommented, Jan 22, 2021

I think we should extract these list components into external packages. It’s not sustainable to have these JS components in this repo if they aren’t going to be maintained to address accessibility and performance issues that other platforms surface

1reaction
chrisgleincommented, Jan 12, 2021

Okay, that explains it. And I see now you’re going off the Snack in the documentation, makes sense. This repo (github.com/facebook/react-native) covers the core infrastructure of React Native that includes Android and iOS support. Anything additional like Web, Windows, or macOS support are handled by separate repositories with their own issue tracking. You’ll want to open this issue on the React Native for Web repository, which is here: https://github.com/necolas/react-native-web/issues

Read more comments on GitHub >

github_iconTop Results From Across the Web

[Accessibility] SectionList not render the group with title for ...
The problem. When using SessionList, each item is rendered but don't have any associate with the header. How to reproduce
Read more >
Access section data from section items in react native ...
renderItem prop passes a single parameter to the function. This parameter is an object includes item and section data.
Read more >
SectionList - React Native
SectionList. A performant interface for rendering sectioned lists, supporting the most handy features: Fully cross-platform.
Read more >
What is the SectionList component and how to use it in React ...
A component class, a render function or a render element that will get rendered at the top of all the items. ListHeaderComponentStyle, styling ......
Read more >
The Generic Section element - HTML - MDN Web Docs - Mozilla
The HTML element represents a generic standalone section of a document, ... In a document, it doesn't really make any sense to have...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found