API reference
lib/glide
Exports
Section titled “Exports”| Kind | Export | Description |
|---|---|---|
| function | useGlide() | One highlight that glides between a list’s rows instead of blinking from row to
row. lit selects the highlighted row (keyboard or pointer). While the
highlight moves, a single stand-in carrying that row’s own resting background
and radius travels from the previous row and the rows’ own highlights are held
back, so at rest every row looks exactly as it always has. Within one open list
the glide remembers its last row, so leaving and re-entering glides from where
it was. Timing and easing are the theme’s; reduced motion moves the highlight at
once. |
useGlide()function
Section titled “useGlide()”function useGlide(lit): RefCallback<HTMLElement>;One highlight that glides between a list’s rows instead of blinking from row to
row. lit selects the highlighted row (keyboard or pointer). While the
highlight moves, a single stand-in carrying that row’s own resting background
and radius travels from the previous row and the rows’ own highlights are held
back, so at rest every row looks exactly as it always has. Within one open list
the glide remembers its last row, so leaving and re-entering glides from where
it was. Timing and easing are the theme’s; reduced motion moves the highlight at
once.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
lit |
string |
Returns
Section titled “Returns”RefCallback<HTMLElement>