[css-snappoints] - JavaScript API/DOM events

Hi all,

Firstly, please excuse me if I知 breaking any etiquette. I have searched through these archives looking for for previous discussion on this topic, but found nothing. I can only assume I知 either in the wrong place or I知 terrible at searching - please inform me if either is true :)

I知 a developer and I have been working on a JavaScript-based slider with fairly deep support. This could be supplanted almost entirely by the css-snappoints spec, so I知 very interested in the progress of this proposal. However I have not seen any discussion of the JS/DOM side of the spec. As I asked above, firstly I壇 like to know if there is already an existing proposal for exposing some of this functionality in JS? 

To be able to *entirely* supplant the code I知 working on with features from this spec there would need to be some extension points in JS, which I知 sure we can agree are quite standard use-cases:

1. move slider position programmatically
	* this would allow consumers to add pager-type controls and next/previous buttons to their slider
2. capture slide events
	* I知 not sure on the fidelity of the events but at the very least we壇 need an event when moving from slide X to slide Y
 	* Possibly even events for the next slide being partially exposed but not slid to

These seems like they could/should be exposed through the standard DOM EventTarget interface - dispatchEvent could handle (1) and addEventListenever could fulfil (2).

Thoughts?

Again, please inform me if I知 in entirely the wrong place.

Thanks,
Nick Williams

Received on Tuesday, 17 December 2013 15:50:37 UTC