@empathyco/x-components
Version:
Empathy X Components
192 lines (83 loc) • 2.92 kB
Markdown
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@empathyco/x-components](./x-components.md) > [ScrollXEvents](./x-components.scrollxevents.md)
## ScrollXEvents interface
Dictionary of the events of Scroll XModule, where each key is the event name, and the value is the event payload type or `void` if it has no payload.
**Signature:**
```typescript
export interface ScrollXEvents
```
## Properties
<table><thead><tr><th>
Property
</th><th>
Modifiers
</th><th>
Type
</th><th>
Description
</th></tr></thead>
<tbody><tr><td>
[ScrollRestoreFailed](./x-components.scrollxevents.scrollrestorefailed.md)
</td><td>
</td><td>
void
</td><td>
The scroll position has failed to be restored. Payload: none.
</td></tr>
<tr><td>
[ScrollRestoreSucceeded](./x-components.scrollxevents.scrollrestoresucceeded.md)
</td><td>
</td><td>
void
</td><td>
The scroll position has been restored successfully. Payload: none.
</td></tr>
<tr><td>
[UserAlmostReachedScrollEnd](./x-components.scrollxevents.useralmostreachedscrollend.md)
</td><td>
</td><td>
boolean
</td><td>
The user has almost reached the scroll end. Payload: True if the user has almost reached the scroll end, false if it is no longer close to the end.
</td></tr>
<tr><td>
[UserChangedScrollDirection](./x-components.scrollxevents.userchangedscrolldirection.md)
</td><td>
</td><td>
[ScrollDirection](./x-components.scrolldirection.md)
</td><td>
The user has changed the direction of scroll. Payload: The new [ScrollDirection](./x-components.scrolldirection.md) when user changes scroll direction.
</td></tr>
<tr><td>
[UserReachedScrollEnd](./x-components.scrollxevents.userreachedscrollend.md)
</td><td>
</td><td>
boolean
</td><td>
The user has reached the scroll end. Payload: True if the user has reached the ending position of the scroll. False if he is no longer in that position.
</td></tr>
<tr><td>
[UserReachedScrollStart](./x-components.scrollxevents.userreachedscrollstart.md)
</td><td>
</td><td>
boolean
</td><td>
The user has reached the scroll start. Payload: True if the user has reached the starting position of the scroll. False if he is no longer in that position.
</td></tr>
<tr><td>
[UserScrolled](./x-components.scrollxevents.userscrolled.md)
</td><td>
</td><td>
number
</td><td>
The user has scrolled. Payload: The new position of scroll.
</td></tr>
<tr><td>
[UserScrolledToElement](./x-components.scrollxevents.userscrolledtoelement.md)
</td><td>
</td><td>
string
</td><td>
The user has scrolled to an element with the given id. Payload: The scroll identifier of the element.
</td></tr>
</tbody></table>