Giter VIP home page Giter VIP logo

angular-slidezilla's Introduction

Angular Slidezilla

Angular Slidezilla is a pure angular slider directive which makes it incredibly simple to have reliable sliders in angular.

Talk is cheap: See THE DEMO here.

##Why Slidezilla?

There are several other angular slider directives. Most of them depend on jQuery and/or are really glitchy or don't have the features I wanted. So I created my own and I needed a unique name for the plugin and this was the first thing that popped in my head.

##Installation

Dependencies: Angular

Download and include angular-slidezilla.js and pretty-slidezilla.css

Create an angular app and inject angular-slidezilla. That's about it.

bower

bower install angular-slidezilla

##Usage

basic

<slider ng-model="slider1.val"></slider>

controller:

    //set slider value as a number to have 1 slider
    //all properties default values
    $scope.slider1 = {val:5};

static

<slider ng-model="slider2.val" min="-25" max="25" step="1"></slider>

controller:

    //set slider value as a number to have 1 slider
    // properties defined in html
    $scope.slider2 = {val:-7};

dynamic

<slider ng-model="slider3.val" min="slider3.min" max="slider3.max" step="slider3.step"></slider>

controller:

    //set slider value as a number to have 1 slider
    // properties defined below
    $scope.slider3 = {
        val:5.5,
        min: 0,
        max: 10,
        step: 0.5
    };

range

<slider ng-model="slider4.val"></slider>

controller:

    //set value as an array to have 2 sliders
    $scope.slider4 = { val:[5,20] };

##Configuration

Name Values Description Default
min variable or number (float) Min value of slider. 0
max variable or number (float) Max value of slider 100
step variable or number (float) Step value of slider. Slider will increment by this value. 5

##Customization

Simply modify angular-slidezilla.css

angular-slidezilla's People

Contributors

itslenny avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

angular-slidezilla's Issues

Handle goes out of the track at 100%

Hi,
Great directive ! Very simple and nothing fancy, perfect for my needs ;-)

Is it on purpose that the handle starts in the track but when at 100% it's out of the track ? Wouldn't it be better it it stops when the handle corner touches the end of the track ?

Thanks !

Vertical Slider

I see in angular-slidezilla.css the classes for the "vertical" slider but in the directive it hasn't got the implementation. Could you build it?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.