angular-simple-slider icon indicating copy to clipboard operation
angular-simple-slider copied to clipboard

Add config provider

Open drochag opened this issue 9 years ago • 6 comments

Add a simpleSliderConfigProvider with defaults for every slider created through the directive

drochag avatar Jun 02 '15 06:06 drochag

I'm afraid this may be a bit of an overkill for such a simple directive... but if anyone is willing to give it a try I would be happy to help reviewing it :)

ruyadorno avatar Jun 03 '15 18:06 ruyadorno

@DanMMX I see you're really interested in this project so I added you as a collaborator to this repo :smile:

:+1: feel free to help me review/merge future PRs

ruyadorno avatar Jun 03 '15 18:06 ruyadorno

Thanks a lot @ruyadorno I'll try to do it asap, my interest is mostly because I'm using this one side project I'm working on, will share you the link when it's ready.

The reason for this enhancement proposal is because I have the following same markup in several places :


    .SliderBlock-slider(
        simple-slider,
        start-value='0',
        end-value='0',
        visible-value='1',
        transition-property='opacity',
        transition-duration='2',
        transition-delay='5'
    )
        div.SliderBlock-image(ng-repeat='image in event.Images', ng-style='imageBackground(image.name)')
            .SliderBlock-backgroundOverlay

and would like it to reduce it to


    .SliderBlock-slider(simple-slider)
        div.SliderBlock-image(ng-repeat='image in event.Images', ng-style='imageBackground(image.name)')
            .SliderBlock-backgroundOverlay

and it can be done with config defaults on the config run on Angular

drochag avatar Jun 03 '15 18:06 drochag

hmmmm, got it! :+1: makes sense

ruyadorno avatar Jun 03 '15 21:06 ruyadorno