patternfly / patternfly/patternfly-react

Drawer - automatically manage focus when drawer is opened/closed

Abierto
#8,534 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

A11y Breaking change :boom: PF Team
Lenguaje dominante
TypeScript
Estrellas
862
Forks
392
Merge medio
4 d 8 h
PR fusionados (30 d)
9

Descripción

Follow up for core issue https://github.com/patternfly/patternfly/issues/5319
A more consistent solution than was used to fix https://github.com/patternfly/patternfly-react/issues/8394

move the close button to the top of the drawer body rather than the end.

The modal component automatically places focus on the first interactable element in the modal when it is opened.
In the case of the Drawer, that should be the close button by default.
If the close button is not provided, then it should be the first interactable element in the drawer.
If there are no interactable elements, focus should be placed on the drawer body.

Like the modal, this should happen automatically for the drawer, unless overridden by the consumer.

When the drawer is closed, focus should be returned to the drawer toggle - or at least, the props needed for the consumer to implement this focus management should be exposed. All related examples/demos should be updated to use this behavior (including the wizard with drawer)


Jira Issue: PF-145

Guía de contribución

Abrir la guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Línea de trabajo

Empieza comparando el comportamiento del foco de Drawer con el comportamiento existente de Modal y revisa los ejemplos de Drawer, incluido el wizard con drawer. Implementa el comportamiento de foco indicado al abrir y cerrar, con sobrescrituras del consumer, y después actualiza todos los ejemplos y demos relacionados. Se considera terminado cuando el foco llega al botón de cierre, al primer elemento interactivo o al cuerpo del drawer según corresponda, y vuelve al toggle del drawer al cerrarlo.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
react, typescript
Área
accessibility, frontend
Tipo de issue
Nueva funcionalidad
Dificultad
4/5
Tiempo estimado
3-5 días
Estado de actividad
Estancado
Claridad
Bastante claro
Aptitud para principiantes
35/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.