The Simplest Way to shuffle through images in a Creative Way

Overview

#Shuffle Images by Pete R. Shuffle Images let you display and shuffle multiple images by moving cursor around or several other ways to trigger.This plugin is perfect for when you want to save space while allowing users to take a peak at what other images are related to the one displayed. It can also be used to create an interactive animation on multiple static images at once.

Created by Pete R., Founder of Travelistly and BucketListly

License: Attribution-ShareAlike 4.0 International

Demo

View demo

Compatibility

Modern browsers such as Chrome, Firefox, and Safari on desktop have been tested. Not tested on IE. Since the nature of this plugin requires mouse input, it may not work as expected on mobile.

Basic Usage

To use this plugin, simply include the latest jQuery library (preferably version 2.0.0 or higher) together with jquery.shuffle-images.js into your document's <head> follow by an HTML markup as follows:

<body>
  ..
  <div class="shuffle-me">
    <img src="images/1.jpg">
    <img src="images/2.jpg">
    <img src="images/3.jpg">
    ..
  </div>
  ..
</body>

Make sure all the images you want to shuffle are wrapped within a container where we will call the function on.

Once that is set up, simply call the plugin like this:

 $(".shuffle-me").shuffleImages({
   trigger: "imageMouseMove",     // Choose which type of trigger you want here. Available options are "imageMouseMove", "imageHover", "documentMouseMove", and "documentScroll". "imageMouseMove" will trigger when your mouse over the image and move your cursor. "imageHover" will trigger when you mouse over without moving your cursor. "documentMouseMove" will trigger when cursor is being moved anywhere on the page. "documentScroll" will trigger when you scroll the page. The default value is "imageMouseMove"
   triggerTarget: false,          // For "imageMouseMove", and "imageHover" only, you can set which element to trigger the image shuffle when mouse over. For example, if you want a container ".main" to trigger an image shuffle instead of the image itself, put $(".main") for this option. Default value is false.
   mouseMoveTrigger: 50,          // For "imageMouseMove" only, you can set how many pixels you have to move in order to trigger one image shuffle. The lower the faster. The default value is 50.
   hoverTrigger: 200,             // For "imageHover" only, you can set how long you have to hover the image until it shuffles to other images. The option accepts milliseconds without unit. The default value is 200.
   scrollTrigger: 100,          // For "documentScroll" only, you can set how many pixels you have to scroll to see the image shuffle. The default value is 100.
   target: "> img"              // In case you have a complete HTML structure, you can set your own custom selector to your images here. The default value is "> img" which means images that are directly under the "shuffle-me" will be used to shuffle.
 });

With the setup above, your images will be shuffled when you mouse over that particular image and you move around your cursor more than 50 pixels away from previous location.

Markups

You can individually assign each shuffle with its own trigger timing. Available markup are:

data-si-mousemove-trigger

You can define a custom mouseMoveTrigger option with this data attribute:

  <div class="shuffle-me" data-si-mousemove-trigger="100">
    <img src="images/1.jpg">
    ...
  </div>

data-si-hover-trigger

You can define a custom hoverTrigger option with this data attribute:

  <div class="shuffle-me" data-si-hover-trigger="1000">
    <img src="images/1.jpg">
    ...
  </div>

data-si-scroll-trigger

You can define a custom scrollTrigger option with this data attribute:

  <div class="shuffle-me" data-si-scroll-trigger="200">
    <img src="images/1.jpg">
    ...
  </div>

Now your users can see several images while moving their cursor when they interact with the first image on your website.

If you want to see more of my plugins, visit The Pete Design, or follow me on Twitter and Github.

Other Resources

  • Tutorial (Coming Soon)
You might also like...

Using a RPI 3b+ to create a PT camera accessible through Windows browser and controllable through MQTT

web-camera_PT A Web flask server converts the MJPEG stream from RPI to JPG img using opencv, then display in browser. Controls added to move Camera in

Dec 20, 2022

The simplest possible modal for jQuery

The simplest possible modal for jQuery

A simple & lightweight method of displaying modal windows with jQuery. For quick examples and demos, head to jquerymodal.com. Why another modal plugin

Dec 29, 2022

The smallest, simplest and fastest JavaScript pixel-level image comparison library

The smallest, simplest and fastest JavaScript pixel-level image comparison library

pixelmatch The smallest, simplest and fastest JavaScript pixel-level image comparison library, originally created to compare screenshots in tests. Fea

Jan 8, 2023

GNOME Shell extension to integrate Plank, the simplest dock on the planet.

GNOME Shell extension to integrate Plank, the simplest dock on the planet.

Dash to Plank Gnome Shell extension to integrate Plank, the simplest dock on the planet. To use this extension you must install Plank on your system.

Dec 9, 2022

The simplest field formatting and masking tool for React.

Format As You Type The simplest field formatting and masking tool for React. Format fields the way you want using the input components you already use

Jan 27, 2022

An attempt to create the simplest demo to describe a Consumer-Driven Contract Testing workflow with Pact

Let's Play with Pact Abstract This is an attempt to create the simplest demo to describe a Consumer-Driven Contract Testing workflow with Pact. Prereq

Feb 22, 2022

The simplest yet effective jQuery idle plugin

jquery.inactivity The simplest yet effective jQuery idle (inactivity) plugin Download Uncompressed Compressed Purpose Listen for mouse, keyboard, touc

Oct 18, 2022

This is the simplest possible nodejs api using express.

NodeJS JWT Authentication sample A Todo Application with NodeJS and ExpressJS that uses JWT authentication to manage each user's todos. Available APIs

Sep 11, 2022

The simplest implementation of Golang channels, selects and wait groups

The simplest implementation of Golang channels, selects and wait groups

TypeScript Channels The simplest implementation of Golang channels, selects and wait groups Installation You can use one of the following package mana

Dec 8, 2022

This repo has demos, content and documentation of javascript concepts and syntax, in their simplest form. Contribute by sharing your understanding of javascript! Hacktoberfest Accepted!

javascript-documentation open-source hacktoberfest2022 Submit your PR to this javascript-documentation repo 🧭 🌟 ❗ This repo has some of my javascrip

Nov 2, 2022

Simplest ever I18N 1 KB library for HTML/JavaScript apps.

Simplest ever I18N 1 KB library for HTML/JavaScript apps.

Ultimate I18n JS 🀯 Ultimate internationalization library for web applications. Super simple & easy. Less than 1KB (minified and gziped). 0 dependenci

Dec 22, 2022

Now UI Kit Bootstrap 4 - Designed by Invision. Coded by Creative Tim

Now UI Kit Bootstrap 4 - Designed by Invision. Coded by Creative Tim

Now UI Kit Now UI Kit is a responsive Bootstrap 4 kit provided for free by Invision and Creative Tim. It is a beautiful cross-platform UI kit featurin

Jan 7, 2023

A library for visualization and creative-coding

A library for visualization and creative-coding

Pts Pts is a typescript/javascript library for visualization and creative-coding. Get started at ptsjs.org. Please give it a try, file issues, and sen

Jan 3, 2023

The social network for developers. Discover creative websites and build a community.

The social network for developers. Discover creative websites and build a community.

Driwwwle The Social Network for Developers Features ⚑ Server-side rendering with Next.js πŸͺ Cookie-based authorization with JSON web tokens πŸ“œ Infinit

Dec 26, 2022

This project provides a React-powered web experience using the PokeAPI. It also is a creative space to hone frontend skills.

pokedex-nova This project provides a React-powered web experience using the PokeAPI. It also is a creative space to hone frontend skills. Available Sc

Feb 1, 2022

In game dev, generative art, and creative coding, sine is a ubiquitous function that is often used as a spring-like oscillator for a given parameter.

In game dev, generative art, and creative coding, sine is a ubiquitous function that is often used as a spring-like oscillator for a given parameter.

In game dev, generative art, and creative coding, sine is a ubiquitous function that is often used as a spring-like oscillator for a given parameter.

Feb 22, 2022

ChelseaJS - a Javascript library for creative, generative Coding

ChelseaJS - a Javascript library for creative, generative Coding

ChelseaJS is a Javascript library for creative, generative Coding. It's simple and intuitive syntax makes it easy for everyone (including non-coders)

Oct 6, 2022

Amelia is an open-source creative-coding toolkit for modern JavaScript

amelia Amelia is an open-source creative-coding toolkit for modern JavaScript. Amelia is a collection of APIs meant to make it easy to create sketches

Jun 10, 2022

✍️ Generative creative writing via OpenAI

The stars have always been a source of wonder and mystery. They have inspired poets and philosophers throughout the ages. Arthur Conan Doyle was no ex

Dec 24, 2022
Comments
  • Issue on images that are not the same size.

    Issue on images that are not the same size.

    Hello,

    According to your demo files on my side, if i use different sizes of images, the site layout shifts.

    On the video watch the footer side, Let's talk and the Lorem on how they bounce up and down. - that's because the first images are not the same size, but the other pictures which are the sizes are fine.

    see video https://www73.zippyshare.com/v/UZOoJijf/file.html

    thanks for your time.

    opened by Louboutin1017 0
  • Integrating a Magnificpopup

    Integrating a Magnificpopup

    The next thing should be integratsing something like Magnificpopup http://dimsemenov.com/plugins/magnific-popup/ where you could see all those images.

    opened by purgeru 0
MidJourney is an AI text-to-image service that generates images based on textual prompts. It is often used to create artistic or imaginative images, and is available on Discord and through a web interface here.

Midjourney MidJourney is an AI text-to-image service that generates images based on textual prompts. It is often used to create artistic or imaginativ

Andrew Tsegaye 8 May 1, 2023
"shuffle-text" is JavaScript text effect library such as cool legacy of Flash.

ShuffleText This is the JavaScript library for text effect such as Flash contents. Setup Script Install <script src="shuffle-text.js"></script> NPM In

Yasunobu Ikeda 96 Dec 24, 2022
A little animation for a big menu where the letters of a word shuffle to become the first letter of each menu item.

Letter Shuffle Animation for a Menu A little animation for a big menu where the letters of a word shuffle to become the first letter of each menu item

Codrops 29 Dec 4, 2022
A JavaScript library to shuffle the text content of a DOM element with an animated effect.

shuffle-letters.js A JavaScript library to shuffle the text content of a DOM element with an animated effect. NOTE: This library is a port to vanilla

George Raptis 6 Jun 2, 2022
Shuffle texts.

shuffleText This is JavaScript file. When mouse over element shuffle texts in html. It is easy to use it for everyone. Update Infomation If you make s

Toshiya Marukubo 9 Apr 5, 2022
The simplest way to create web components from plain objects and pure functions! πŸ’―

?? One of the four nominated projects to the "Breakthrough of the year" category of Open Source Award in 2019 hybrids is a UI library for creating web

hybrids 2.7k Dec 27, 2022
The simplest way to use AWS/GCP/Azure. From code to cloud in a few minutes.

Utopiops Utopiops is the best way for teams of any size to use cloud (AWS/Azure/GCP), with or without prior experience. We provide a platform that hel

utopiops 98 Dec 25, 2022
Easiest 1-click way to install and use Stable Diffusion on your own computer. Provides a browser UI for generating images from text prompts and images. Just enter your text prompt, and see the generated image.

Stable Diffusion UI Easiest way to install and use Stable Diffusion on your own computer. No dependencies or technical knowledge required. 1-click ins

null 3.5k Dec 30, 2022
Journeys is a django based community-focused website that allows users to bookmark URLs (through chrome extension) and share their journeys through timelines.

Journeys is a django based community-focused website that allows users to bookmark URLs (through chrome extension) and share their journeys through timelines. A timeline is a collection of links that share a common topic or a journey of building and learning something new. Users can create timelines, share them publicly, and explore resources.

Students' Web Committee 14 Jun 13, 2022