TanStack / TanStack/tanstack.com
Docs title-bar width toggle: click sticks, icon never updates, and layout flashes on refresh
Nadie ha tomado este issue todavía.
- Lenguaje dominante
- TypeScript
- Estrellas
- 1.1k
- Forks
- 401
- Merge medio
- 18 h 14 min
- PR fusionados (30 d)
- 56
Descripción
Bug: docs title-bar width toggle is broken
The expand/collapse button next to "Copy page" on docs pages (visible at ≥1535px viewport) has three issues:
- Click works only once, then gets stuck. Starting collapsed, the first click expands the layout. Subsequent clicks do nothing. Same in reverse: starting expanded, the first click collapses but it can't be re-expanded.
- Icon never updates. Even when the layout state changes (e.g., on first click), the icon stays as
UnfoldHorizontal(arrows pointing outward). It never flips toFoldHorizontal. - Flash on every refresh. When the preference is set to "expanded", refreshing the page paints the constrained (narrow) layout first, then snaps to expanded after hydration.
Repro
- Open any docs page at a viewport ≥1535px (e.g. https://tanstack.com/router/latest/docs/framework/react/overview)
- Click the expand/collapse icon on the right of the title bar
- Try clicking it again — nothing happens, and the icon hasn't changed
- Refresh while in the expanded state — observe the brief narrow → expanded flash
Video
https://github.com/user-attachments/assets/5a9b6ad5-5ca9-48d6-ad61-7b3dfa990096
I have a working branch with this fix locally. Will open a PR shortly ...
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.
Línea de trabajo
Abra la página de docs reproducida en la URL proporcionada e inspeccione el control de expandir/contraer de la barra de título situado junto a “Copy page.” Verifique que el interruptor pueda cambiar de estado repetidamente, que el icono refleje cada estado y que una preferencia expandida no muestre brevemente el diseño restringido después de actualizar. En la issue no se menciona ningún archivo fuente ni ninguna ruta de prueba.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- typescript
- Área
- documentation, frontend
- Tipo de issue
- Error
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Estado de actividad
- Tranquilo
- Claridad
- Bastante claro
- Aptitud para principiantes
- 35/100