ISticky
interface
Layout & Sizing
Return shape of the useSticky composable. Exposes the root element ref, a reactive flag indicating whether the component is currently stuck, and the computed CSS styles for the layout item slot.
TypeScript
Définition
La définition TypeScript de l'interface telle que trouvée dans le code source d'origam. Cliquez sur l'icône de copie pour copier l'extrait.
API
Propriétés
Chaque propriété déclarée par cette interface, avec son type, son caractère optionnel et sa valeur par défaut.
- rootElrequisRef<HTMLElement | undefined>
- Template ref to the sticky component root element, used to measure its dimensions for the layout item slot.
- isStickyrequisRef<boolean>
- True when the component has passed its scroll threshold and is currently in its sticky (fixed) position.
- layoutItemStylesrequisRef<CSSProperties>
- Reactive CSS properties object (height, top, etc.) provided to the Nuxt/layout slot to preserve the space the sticky component occupies in the normal flow.
Écosystème
Utilisé par
Composants et composables qui étendent ou consomment cette interface.
Usage
Exemples
Extraits de code prêts à coller utilisant cette interface.
Consuming ISticky from useSticky