Snackbar can display wrong message during hiding animation
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 35/100
- Tipo de issue
- Error
- Claridad
- Bastante claro
- Estado de actividad
- Estancado
- Stack tecnológico
- react, typescript
- Área
- frontend
Línea de trabajo
Start at the Snackbar component and inspect how AccessCodeTable and other consumers couple message with isVisible. Trace the hiding animation and the proposed null-to-non-null transition, then verify that the old message remains visible while hiding and that a rapid new message aborts the animation without showing the default message.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Context
The snackbar component uses the message: string prop to determine what to display and the isVisible: boolean prop to determine if it should be visible.
Some components that use the Snackbar component coupled these two props so that isVisible becomes false at the same time as message goes back to the default messaging. (like the AccessCodeTable used to)
isVisible switching from true to false triggers the hiding animation, if the message prop changes to the default message at the same time then the default message gets displayed for the duration of the hiding animation.
Potential solution
The snackbar does not need that many props imo, we could change message: string to message: string | null and get rid of the isVisible prop.
The parent component would simply set the message to whatever it wants to display then nullify it when it wants to hide it. The snackbar would keep its own messageToDisplay: string state that does not get updated when the given message prop is null
We would need to make sure that setting the message to null then to a non-null value in quick succession properly aborts the hiding animation
- Lenguaje dominante
- TypeScript
- Estrellas
- 9
- Forks
- 2
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de seamapi/react
-
bug seam components
Dificultad 3/5 1-2 días Aptitud para principiantes 20/100
-
seam components
Dificultad 4/5 3-5 días Aptitud para principiantes 30/100
-
Return null vs false vs <></> Abiertoseam components
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
-
seam components
Dificultad 4/5 3-5 días Aptitud para principiantes 32/100
-
seam components
Dificultad 3/5 1-2 días Aptitud para principiantes 45/100
Todos los issues de seamapi/react
Issues similares
-
VerificationGate: ATTRIBUTION quote guard never matches a normal quotation (\b around the quote) Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
danielmiessler/LifeOS#2234 ·
-
T: Bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 85/100
-
Mend: dependency security vulnerability untriaged
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100