Browse Source

Minor updates

tags/1.1.1
peterd 3 years ago
parent
commit
0bfa3f10b2
5 changed files with 6 additions and 6 deletions
  1. 1
    1
      README.md
  2. 1
    1
      colors.js
  3. 1
    1
      index.html
  4. 1
    1
      jqColorPicker.js.map
  5. 2
    2
      jqColorPicker.min.js

+ 1
- 1
README.md View File

@@ -66,7 +66,7 @@ $('.color').colorPicker({

The positionCallback can be used to optionally position the colorPicker different from its default; in case you want it to also show above or to the left of the input field etc.
The callback will also be called on scroll.
You need to return an object that holds ```left``` and ```top``` to position the colorPicker. See ./demo/index.js for an example:
If you return an object (```{left: x, top: y}``` to position the colorPicker) then those coordinates will be taken, otherwhise the function just executes (what you need to do: re-append for example) and it takes the internal algorithm to position the color picker. See ./demo/index.js for an example:

```javascript
positionCallback: function($elm) {

+ 1
- 1
colors.js View File

@@ -31,7 +31,7 @@
Colors = function(options) {
this.colors = {RND: {}};
this.options = {
color: 'rgba(204, 82, 37, 0.8)', // init value(s)...
color: 'rgba(0,0,0,0)', // init value(s)...
grey: grey,
luminance: luminance,
valueRanges: _valueRanges

+ 1
- 1
index.html View File

@@ -25,7 +25,7 @@
<div id="content-wrapper">
<h1>Tiny jQuery colorPicker</h1>
<p>Looking for mobile first, tiny foot print, fast, scaleable, flexible and pluggable...<br>
This <strong>4.7KB</strong> (gZip) small HSB color picker is based on a subset of <a href="https://github.com/PitPik/colorPicker/blob/master/colors.js">colors.js</a> from it's big brother <a href="http://dematte.at/colorPicker/">colorPicker</a>, supports all modern features like touch and MS pointer, GPU accelerated rendering, battery friendly requestAnimationFrame and provides a lot of hooks for developers to write plugins (See demo plugins below in <a href="#demo">Demo</a>).</p>
This <strong>5.07KB</strong> (gZip; 11.39KB minified) small HSB color picker is based on a subset of <a href="https://github.com/PitPik/colorPicker/blob/master/colors.js">colors.js</a> from it's big brother <a href="http://dematte.at/colorPicker/">colorPicker</a>, supports all modern features like touch and MS pointer, GPU accelerated rendering, battery friendly requestAnimationFrame and provides a lot of hooks for developers to write plugins (See demo plugins below in <a href="#demo">Demo</a>).</p>
<a name="demo" id="demo" class="a-inline"></a>
<h2>Demo</h2>
On all elements with className 'color': <pre>$('.color').colorPicker();</pre>

+ 1
- 1
jqColorPicker.js.map
File diff suppressed because it is too large
View File


+ 2
- 2
jqColorPicker.min.js
File diff suppressed because it is too large
View File


Loading…
Cancel
Save