Skip to content

[Help]: Auto Scroll plugin interaction container #1209

Closed Answered by davidjerleke
Cchumi asked this question in Help
Discussion options

You must be logged in to vote

Hi @Cchumi,
No worries—your English is totally fine, and your explanation is clear.

To get the behavior you want (pausing only when hovering over the left or right side of the carousel), here’s how you can do it:

  1. Set stopOnMouseEnter: false in the Autoscroll plugin options. This will disable the default behavior of the plugin:
    AutoScroll Plugin Options

  2. Add your own custom hover logic. You have two main options for detecting when to pause:

    • Option A: Add transparent or visible elements to the left and right sides of the carousel. Attach mouseenter and mouseleave events to those elements.
    • Option B: Listen to mouseenter and mousemove events on the entire container, and calculate the mous…

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
5 replies
@Cchumi
Comment options

@davidjerleke
Comment options

Answer selected by davidjerleke
@Cchumi
Comment options

@Cchumi
Comment options

@davidjerleke
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
resolved This issue is resolved question Question about how to achieve something plugin Issue is related to plugins
2 participants