angular-swiper icon indicating copy to clipboard operation
angular-swiper copied to clipboard

observers & observe-parents params no available

Open b82 opened this issue 10 years ago • 4 comments

Hi,

i have a hidden slider that appears on click. On web version this can be rightly done using observer="true" observe-parents="true", which are available for web apps. Is it possible have those params also for this plugin?

Thank you and best regards

b82 avatar Sep 30 '15 18:09 b82

This could be accomplished quite easily, however, @ksachdeva, do you believe it may be best to assign default params for at least boolean values? It will prevent a lot of similar request in the future.

brh55 avatar Nov 07 '15 03:11 brh55

Hi @brh55 since swiper has lot of options may be we should think about an approach using which we do not have to update the directive. One approach is to pass an object prepared by controller or json attribute on the element. This however destroys the 'semantic' aspect of the directive. Look at the fourth option on this gist https://gist.github.com/CMCDragonkai/6282750

ksachdeva avatar Nov 07 '15 13:11 ksachdeva

@ksachdeva Hmm, if i'm not mistaken, @b82 should be able to declare the param with the

override-parameters="{ 'observer': true, 'observe-parents': true}"

If this is the case, I think the override-parameter attribute is sufficient to extend any additional params for swiper.

brh55 avatar Nov 09 '15 13:11 brh55

This is correct. I have not tested override-parameters myself but seems to implement passing of generic attributes. One of the contributors added this.

ksachdeva avatar Nov 09 '15 15:11 ksachdeva