-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
can.ui.Slider API #1
Comments
I think we could support computed props like: Todo = can.Observe({
prettyDate : can.prop(function(){
return this.attr('date').toString()
})
}) |
I think it would be nice to support ranges by passing a array to the 'value' attribute. |
I'm a fan of option 1. Not only do I think that it would be the easiest to implement (we wouldn't have to create some new "standard representation" of properties of models), but I think the code reads easier as well. Option 1 is more decoupled IMO. |
Should this progressively enhance input type=range els? http://wufoo.com/html5/types/8-range.html |
Purpose
Make an extensible slider that can be used on it's own or with our model layer.
Learn from
http://jqueryui.com/demos/slider/
Options
Events
Methods
Theming
Examples
vertical
horizontal
Slider controls tabs
Notes
In preparation for CanUI, I've been thinking a lot about MXUI's slider: http://javascriptmvc.com/docs.html#!Mxui.Nav.Slider and how to solve the following:
Hookup a slider to a "percent complete" on a model instance and, how we could tell a grid to somehow hook this up.
Hookin a slider
A basic slider, one that knows nothing of a model has 4 values that determine what it looks like:
With a DOM-centric approach, you can hook it up ( and respond to updates in the model) like:
The DOM-centric approach makes it easy to use slider with anything. However, the purpose of CanUI is to make it easier to setup UI elements with Observes and models. How can this be done?
Option 1 - pass model and an attribute
Option 2 - pass a standard representation of the model / attribute
What does task.prop return to help you?
Hooking up to the grid
With EJS:
Gross!
The text was updated successfully, but these errors were encountered: