Giter VIP home page Giter VIP logo

react-aria-components's Introduction

React ARIA Components

Disclaimer: this is in an alpha stage.

For a hands-on approach to this library, see the documentation site.

Browsers support

This library publishes uncompiled source code. It is expected for host applications to set up compilation processes. For example, there is a Webpack configuration used for the documentation site.

Getting started

npm install
npm start

Visit the webpage listed in the output. The URL should have been copied to the clipboard. Otherwise, please inspect the console output.

High-level design

The components available through this module are inspired from the WAI-ARIA Authoring Practices. Each component is driven by three principles:

  1. A component is accessible.
  2. A component can be used in composition (favoring web components interfaces).
  3. A component has a minimal footprint.

Contributing

Code requirements will be evaluated through peer review. CI will run tests and linter rules -- see below for running the same scripts locally. CI will also deploy branches to Github pages -- see CI output for URL.

npm test
npm run lint

Docker

  1. Install node modules:

    docker-compose run npm install
    
  2. Start

    docker-compose up web
    
  3. Test / Lint

    docker-compose run npm test / run test:debug / run lint
    

    For example:

    docker-compose run npm test listbox
    

react-aria-components's People

Contributors

ahuth avatar dependabot[bot] avatar jsteckml avatar juanca avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

react-aria-components's Issues

React Native compatibility

A little back story: #25

Motivation: increase developer productivity thus increase library utility by providing cross-platform components.

However, do native platforms have accessibility requirements? What are those? How can those be achieved? What are some good resources for successful accessible native components?

License

Looks like we're missing a license on this repository. Whooooops.

MIT? I think that's the most friendly to open source projects.

Sponsorship(s)

I just enrolled into the Sponsorship beta program.

I would like to make react-aria-components the main project.

  • Set up (an approved) sponsorship profile
  • Enable sponsor button in project
  • Add (accessible) sponsor link in demo pages

Storybook 5?

Storybook 5 has been released, and it looks really good! What do you think @juanca about using it for the examples in this repo?

Should we use it, we'll get:

  • Sexy looking site/examples
  • Real easy to add examples
  • Built-in accessibility for the site/examples!

Downsides are:

  • Less control

In any case, I'm going to look at implementing a demo of this to look at

Tab Panel should be programmatically focusable

From w3c/aria-practices#323 (comment)

This was added to account for cases where a tab panel may not include any focusable interactive elements, or if a large amount of textual content appears at the beginning of the tabpanel and the first focusable active element is at the end, such as a license agreement form where the Agree button is at the very end.
If the tabpanel is not focusable, then sighted keyboard-only users will not be able to tab to the tabpanel content and read it from the beginning on down, but will instead jump to Agree and entirely skip all of the main content. This is also helpful for screen reader users who may wish to move directly from the focused expanded Tab and be placed at the beginning of the newly rendered Tabpanel content, instead of jumping passed it or moved to the end of it unexpectedly.

Data Grid vs Layout Grid

As I learn more about the different usages of the Grid role, a clear distinction between its usages seems to grow larger.

There seems to be two different usages of a grid:

  • Data grid: which is the current implementation in this package
  • Layout grid: which is more abstract and is not tabular

I think it will be beneficial to define these two as separate components -- and compose from each other.

More research needs to be done but using this to track the idea.

Individual releases of components

I think it may be worthwhile to release components individually (as well as a whole set together).

Initially, this repository was intended to only support the grid and tree-grid components. And I just recently got access to react-treegrid package name. https://www.npmjs.com/package/react-treegrid

Ideally, we have a straightforward process for releases all these packages.

For example, perhaps have a package.json for react-tree-grid (once I can rename the package) and a script to package the appropriate files -- minimal footprint.

Grid components, required props, cloning elements

There are prop-type validation errors when rendering the grid example.

The GridRow and GridCell have require properties which are provided after rendering via React.cloneElement.

In order to fix this, possible solutions are:

  • Use context to provide dynamic values from Grid to GridRow and GridCell
  • Refactor API to always use render props everywhere
  • Dig for other solutions

Regardless of the solution, performance should be evaluated! As far as I remember, Cursor was pretty fast as well as the grid example.

Grid component has keyboard accessbility

Although VoiceOver has good keyboard navigation in the grid example, it is still non-compliant with keyboard navigation outside VoiceOver.

This is an example with basic cells and keyboard navigation.

Pages TLC

This is opinion, but, even though we've configured the whole per branch pages stuff, there's no reason not to make those really attractive to increase interest from the public. It's been pretty proven over time that open source projects with attractive pages gain traction.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.