All Projects → xiel → embla-carousel-wheel-gestures

xiel / embla-carousel-wheel-gestures

Licence: MIT license
wheel interactions for Embla Carousel

Programming Languages

typescript
32286 projects
javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to embla-carousel-wheel-gestures

React Use Gesture
👇Bread n butter utility for component-tied mouse/touch gestures in React and Vanilla Javascript.
Stars: ✭ 5,704 (+18913.33%)
Mutual labels:  wheel, gestures
basicSlider
A slider in its purest form.
Stars: ✭ 27 (-10%)
Mutual labels:  gallery, slider
use-gesture
👇Bread n butter utility for component-tied mouse/touch gestures in React and Vanilla Javascript.
Stars: ✭ 6,624 (+21980%)
Mutual labels:  wheel, gestures
Vue Gallery
📷 Responsive and customizable image and video gallery, carousel and lightbox, optimized for both mobile and desktop web browsers.
Stars: ✭ 405 (+1250%)
Mutual labels:  gallery, slider
React Siema
ReactSiema Demo
Stars: ✭ 90 (+200%)
Mutual labels:  gallery, slider
Slider
Touch swipe image slider/slideshow/gallery/carousel/banner mobile responsive bootstrap
Stars: ✭ 2,046 (+6720%)
Mutual labels:  gallery, slider
skeleton-carousel
Carousel component. Horizontal and vertical swipe navigation
Stars: ✭ 31 (+3.33%)
Mutual labels:  gallery, slider
Swiper
Most modern mobile touch slider with hardware accelerated transitions
Stars: ✭ 29,519 (+98296.67%)
Mutual labels:  gallery, slider
React Grid Carousel
React responsive carousel component w/ grid layout
Stars: ✭ 29 (-3.33%)
Mutual labels:  gallery, slider
React Responsive Carousel
React.js Responsive Carousel (with Swipe)
Stars: ✭ 1,962 (+6440%)
Mutual labels:  gallery, slider
MediaSliderView
Pure java based, highly customizable media slider gallery supporting both images and videos for android.
Stars: ✭ 85 (+183.33%)
Mutual labels:  gallery, slider
vue-active-swiper
🌴 A Mobile-oriented、No dependencies、Lightweight Swiper component for Vue
Stars: ✭ 33 (+10%)
Mutual labels:  slider
PrivateGalleryCreator
Create private extension galleries for Visual Studio
Stars: ✭ 96 (+220%)
Mutual labels:  gallery
SpinningWheelAndroid
Custom Spinning Wheel View for Android
Stars: ✭ 45 (+50%)
Mutual labels:  wheel
ansible-role-admin-users
Ansible role to manage admin users, authorized keys and sudo access.
Stars: ✭ 18 (-40%)
Mutual labels:  wheel
django-content-gallery
A Django application allows to attach a collection of images to objects of any model in any app
Stars: ✭ 18 (-40%)
Mutual labels:  gallery
KJCircularSlider
Slide circularly. Soon more extended version about to come!
Stars: ✭ 23 (-23.33%)
Mutual labels:  slider
no-manylinux
Install this package to disable manylinux wheels when dowloading from pip.
Stars: ✭ 23 (-23.33%)
Mutual labels:  wheel
MaTiSSe
Markdown To Impressive Scientific Slides
Stars: ✭ 43 (+43.33%)
Mutual labels:  slider
vue3-carousel
Vue 3 carousel component
Stars: ✭ 379 (+1163.33%)
Mutual labels:  slider

Embla Carousel

Wheel Gestures for Embla Carousel

This plugin adds wheel interactions to the amazing Embla Carousel

NPM

Installation

First you need to follow the installation instructions for Embla Carousel, after that you can add wheel support:

yarn add embla-carousel-wheel-gestures # npm install --save embla-carousel-wheel-gestures

JavaScript / TypeScript

import EmblaCarousel from 'embla-carousel'
import { WheelGesturesPlugin } from 'embla-carousel-wheel-gestures'

// initialize Embla Carousel
const embla = EmblaCarousel(emblaNode, options, [
  WheelGesturesPlugin()
])

React

import { useEmblaCarousel } from 'embla-carousel-react'
import { WheelGesturesPlugin } from 'embla-carousel-wheel-gestures'

const EmblaCarouselComponent = ({ children }) => {
  const [emblaRef, embla] = useEmblaCarousel({ loop: false, skipSnaps: true }, [
    WheelGesturesPlugin(),
  ])

  // ...
}

Examples

Get started instantly with one of the CodeSandboxes below.

  JavaScript / TypeScript

  React (embla-carousel-react)

Options

wheelDraggingClass

Type: string
Default: is-wheel-dragging

Choose a classname that will be applied to the container during a wheel gesture. Pass an empty string to opt-out.

forceWheelAxis

Type: 'x' | 'y'
Default: undefined

Force an axis on which to listen for wheel events. Useful if you want to slide horizontally when scrolling vertically or vice versa.

target

Type: Element
Default: undefined

Specify the element that should be observed for wheel events.

Global Options

You can also set global options that will be applied to all instances. This allows for overriding the default plugin options with your own:

WheelGesturesPlugin.globalOptions = {
  wheelDraggingClass: 'my-class',
}

OS & Browser Support

  • Mac OS (Chrome, Firefox, Safari, Edge), Magic Mouse, Magic Trackpad
  • Windows (Chrome, Firefox, Edge), Microsoft Precision Touchpads

Legacy Browsers

If you need to support IE 10 & 11 you might need to install and add extra polyfills:

// Adds support old IE >= 10
import 'core-js/stable'
import 'events-polyfill/src/constructors/MouseEvent'

Thanks

Kudos to David Jerleke for creating Embla Carousel with its open API 🙏

License

MIT.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].