An open API service indexing awesome lists of open source software.

https://github.com/kalesh13/z-carousel

A simple, high-performance and cross-browser jQuery text rotator and carousel plugin for Vue. The plugin supports usage of Animate.css animations.
https://github.com/kalesh13/z-carousel

animatecss carousel-plugin css-animations html image-rotator javascript jquery-plugin text-animation text-rotation vuejs

Last synced: 12 days ago
JSON representation

A simple, high-performance and cross-browser jQuery text rotator and carousel plugin for Vue. The plugin supports usage of Animate.css animations.

Awesome Lists containing this project

README

          

# z-Carousel [![GitHub release](https://img.shields.io/github/release/kalesh13/z-Carousel.svg)](https://github.com/kalesh13/z-Carousel/releases) [![npm version](https://badge.fury.io/js/z-carousel.svg)](https://badge.fury.io/js/z-carousel)
A simple, high-performance and cross-browser jQuery text rotator and carousel plugin for Vue.js. The plugin supports usage of Animate.css animations.

### Prerequisites

z-Carousel is a jQuery based plugin. So, please make sure that jQuery is installed and has been initialized before z-Carousel is initialized.

Install jQuery via npm:

```
npm install --save-dev jquery
```

z-Carousel by default uses jQuery's ```fadeIn``` animation. [Animate.css](https://github.com/daneden/animate.css) has to be installed if you want to use a custom animation.

Install Animate.css via npm:

```
npm install --save-dev animate.css
```

z-Carousel also supports carousel pagination which uses a [FontAwesome](https://github.com/FortAwesome/Font-Awesome) icon by default. Install FontAwesome to use the default pagination style. You can skip FontAwesome installation, if pagination is not required or if you want to custom style the pagination icons.

Install FontAwesome via npm:

```
npm install --save-dev font-awesome
```

## Installation

**Install via npm:**

```
npm install --save-dev z-carousel
```

**Or, Standalone installation**

* Download the file from [here](https://raw.githubusercontent.com/kalesh13/z-Carousel/master/build/index.js)
* Save the downloaded file in your server.
* Import the file in your application using ``````
* Plugin initialization is given at the bottom of Usage section.

## Usage

z-Carousel is easy to implement in your existing applications.

**HTML Sample**

```


```

* Carousel pagination, if required, is added by the plugin as the last child element of ```z-carousel-wrapper``` container. So, it is adviced to keep the carousel element list within this container.

* A single page can have multiple carousel elements and z-Carousel will handle each carousel differently. z-Carousel looks for all the elements in the DOM with ```z-carousel``` class and register a carousel for the element.

* Set the ```li``` items to have ```display:none;``` style. This is to make sure that the UI does not look bad before the initilization of the plugin.

* As you can see, the element with ```z-carousel``` is where we define the various customization options. Following are the data fields and their default values used in the plugin to customise the carousel.

| Data | Default | Description |
| :------ | :-------: | :----------- |
| data-pagination | false | Set this field ```data-pagination='true'``` to show carousel pagination |
| data-delay | 2000ms | Define the initial delay after which the carousel rotation should begin. For initial delay of 5 seconds, set ```data-delay='5000'``` as in ```