Blazorise Gestures API
Explore the Blazorise Gestures API reference for parameters, events, methods, and related types.
For examples and usage guidance, see the Gestures documentation.
API
Parameters
| Parameter | Description | Type | Default |
|---|---|---|---|
ChildContent |
Gets or sets the content that will be observed for gestures. |
RenderFragment | null |
Direction |
Gets or sets the directions that can produce swipe events. Possible values: |
GestureDirection | default(GestureDirection) |
Disabled |
Disables gesture handling. |
bool | false |
LongPressDuration |
Gets or sets the duration in milliseconds required to recognize a long press. |
int | 500 |
LongPressMoveTolerance |
Gets or sets the movement tolerance in pixels before a pending long press is canceled. |
double | 10 |
MoveThrottleInterval |
Gets or sets the minimum interval, in milliseconds, between GestureMoved callbacks. |
int | 50 |
PreventNativeDrag |
Gets or sets whether native browser dragging is prevented inside the gesture area. |
bool | true |
SwipeThreshold |
Gets or sets the minimum swipe distance in pixels. |
double | 50 |
SwipeVelocityThreshold |
Gets or sets the minimum swipe velocity in pixels per millisecond. |
double | 0.3 |
TapMaximumDistance |
Gets or sets the maximum movement in pixels that can still be recognized as a tap. |
double | 10 |
TapMaximumDuration |
Gets or sets the maximum duration in milliseconds that can still be recognized as a tap. |
int | 300 |
TouchAction |
Gets or sets the browser touch-action behavior applied to the gestures element. Possible values: |
GestureTouchAction | GestureTouchAction.Auto |
Events
| Event | Description | Type |
|---|---|---|
GestureEnded |
Raised when a gesture ends or is canceled. |
EventCallback<GestureEventArgs> |
GestureMoved |
Raised while an active gesture moves. The callback is throttled by MoveThrottleInterval. |
EventCallback<GestureEventArgs> |
GestureStarted |
Raised when a gesture starts. |
EventCallback<GestureEventArgs> |
LongPressed |
Raised when an active gesture is held long enough to be recognized as a long press. |
EventCallback<LongPressEventArgs> |
Swiped |
Raised when a completed gesture is recognized as a swipe. |
EventCallback<SwipeEventArgs> |
Tapped |
Raised when a completed gesture is recognized as a tap. |
EventCallback<TapEventArgs> |
Methods
| Method | Description | Return | Parameters |
|---|---|---|---|
OnGestureEnded |
Handles a gesture end notification from the browser. | Task | GestureEventArgs eventArgs |
OnGestureMoved |
Handles a gesture move notification from the browser. | Task | GestureEventArgs eventArgs |
OnGestureStarted |
Handles a gesture start notification from the browser. | Task | GestureEventArgs eventArgs |
OnLongPressed |
Handles a long-press notification from the browser. | Task | LongPressEventArgs eventArgs |
OnSwiped |
Handles a swipe notification from the browser. | Task | SwipeEventArgs eventArgs |
OnTapped |
Handles a tap notification from the browser. | Task | TapEventArgs eventArgs |