[Elements] are optional

Class SAPO.Component.ColorPicker

class SAPO.Component.ColorPicker

requires SAPO.Dom.Event

requires SAPO.Dom.Element

requires SAPO.Dom.Css

requires SAPO.Utility.Dimensions

Adds a colorpicker to a form input element

Defined in Component/ColorPicker/0.1/lib.js

Constructor Summary
ColorPicker (String|DOMElement el, [Object options])

Constructor Details

constructor ColorPicker

ColorPicker(String|DOMElement el, [Object options])
el - target input element
[options] - options for the new picker
  • [ String colors ] - comma separated list of the hexadecimal color codes for the picker
  • [ String cssURI ] - URI of the CSS stylesheet for the picker
  • [ Function callBack ] - callback executed when a color is picked. Receives picked value as a parameter