-
Notifications
You must be signed in to change notification settings - Fork 2
/
index.html
664 lines (499 loc) · 26.8 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
<!doctype html>
<html>
<head>
<title>Quinn</title>
<link rel="stylesheet" type="text/css" href="quinn.css" />
<link rel="stylesheet" type="text/css" href="vendor/examples.css" />
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Noto+Serif:ital,wght@0,400;0,700;1,400;1,700&display=swap" rel="stylesheet">
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
</head>
<body>
<div id="content">
<!-- edit README.md, not this file -->
<!-- then run rake readme to regenerate this file -->
<!-- begin README -->
<h1 id="quinn">Quinn</h1>
<p class="github">Are you viewing this README on Github? Head to the <a href="https://antw.github.com/quinn">Quinn homepage</a>
where all of the examples below are fully interactive.</p>
<p><a href="https://github.com/antw/quinn">Quinn</a> is a jQuery-based library which creates sliders (aka. ranges,
aka. track bars) for HTML applications. The project is hosted on
<a href="https://github.com/antw/quinn">GitHub</a>; you can report bugs and discuss features on the
<a href="https://github.com/antw/quinn/issues">issue tracker</a>, or direct your tweets at <a href="https://twitter.com/antw">@antw</a>.</p>
<pre><code>$('.slider').quinn();
</code></pre>
<p>The library requires <a href="https://jquery.com">jQuery</a> and <a href="https://underscorejs.org/">Underscore.js 1.3.1+</a>.</p>
<p>Quinn has been tested and works in the following environments:</p>
<ul class="yes">
<li>Chrome 11 and newer</li>
<li>Firefox 3.5 and newer</li>
<li>Safari 4</li>
<li>Opera 11</li>
<li>Internet Explorer 7+</li>
</ul>
<p>The unit tests can be run <a href="https://antw.github.com/quinn/test">in your browser</a>.</p>
<p>Quinn was developed by <a href="https://github.com/antw">~antw</a> as part of Quintel Intelligence’s
<a href="https://www.energytransitionmodel.com">Energy Transition Model</a> application. It is released under the
<a href="https://github.com/antw/quinn/blob/main/LICENSE">New BSD License</a>.</p>
<p class="old"><strong>You probably don’t want to use this!</strong> While Quinn is still used heavily
in the Energy Transition Model, it is also quite old and its dependency on
jQuery makes it a questionable choice for new development. Consider
<a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/range"><code><input type="range"></code></a> or a more modern library.</p>
<h2 id="downloads">Downloads</h2>
<dl>
<dt><a href="https://github.com/antw/quinn/tarball/v1.2.2">Everything (1.2.2)</a></dt>
<dd>Tarball containing JS, CSS, and images</dd>
<dt><a href="https://antw.github.io/quinn/jquery.quinn.js">Development Version (1.2.2)</a></dt>
<dd>37.2kb, JS only, Uncompressed with comments</dd>
<dt><a href="https://antw.github.io/quinn/jquery.quinn.min.js">Production Version (1.2.2)</a></dt>
<dd>3.2kb, JS only, Minified and Gzipped</dd>
</dl>
<h2 id="table-of-contents">Table of Contents</h2>
<h4 id="options">Options</h4>
<p><a href="#extrema">Minima and Maxima</a>, <a href="#value">Initial Values</a>, <a href="#step">Steps</a>,
<a href="#drawTo">Drawing Options</a>, <a href="#values">Multiple Values</a>, <a href="#effects">Effects</a>,
<a href="#only">Specific Values</a>, <a href="#disable">Disabling the Slider</a></p>
<h4 id="callbackscallbacks"><a href="#callbacks">Callbacks</a></h4>
<p><a href="#onsetup">setup</a>, <a href="#onbegin">begin</a>, <a href="#ondrag">drag</a>, <a href="#onchange">change</a>,
<a href="#onabort">abort</a></p>
<h4 id="progressive-enhancementenhance"><a href="#progressive-enhancement">Progressive Enhancement</a></h4>
<h4 id="themingtheming"><a href="#theming">Theming</a></h4>
<h4 id="historyhistory"><a href="#history">History</a></h4>
<h2 id="options-1">Options</h2>
<p>In order to customise the appearance and behaviour of the Quinn slider
instance, you may pass extra options when initializing:</p>
<pre class="no-example"><code>$(selector).quinn(optionsHash);
</code></pre>
<h3 id="extrema">Minima and Maxima <code>min: value, max: value</code></h3>
<p>By default, a Quinn slider allows selection of whole numbers between 0 and
100. By supplying <strong>min</strong> and <strong>max</strong> options, you can change these values.</p>
<pre><code>/* Our volume knobs go up to eleven. */
$('.slider').quinn({ min: 0, max: 11 });
</code></pre>
<p>Negative values are perfectly acceptable, and the “active bar” (the blue
background) will always be anchored at zero.</p>
<pre><code>$('.slider').quinn({ min: -100, max: 100 });
</code></pre>
<h3 id="value">Initial Values <code>value: number</code></h3>
<p>When a slider is created without a default value, it will initialize with the
slider in the minimum value position. Supplying a <strong>value</strong> option results in
the slider being created with a different starting value.</p>
<pre><code>$('.slider').quinn({ value: 25 });
</code></pre>
<h3 id="step">Steps <code>step: number</code></h3>
<p>The <strong>step</strong> option restricts the values which may be selected using the
slider to numbers which are divisible by the step without a remainder. For
example, a step of 10 only 0, 10, 20, 30, …, n, to be chosen.</p>
<pre><code>$('.slider').quinn({ step: 10 });
</code></pre>
<p>If you supply an initial value which can’t be used as it doesn’t “fit” with
the step, the value will be rounded to the nearest acceptable point on the
slider. For example, an step of 10, and an initial value of 17 will result in
the slider being initialized with a value of 20 instead. This behaviour can
be disabled <em>for the initial value</em> by also supplying <code>strict: false</code>.</p>
<p>Combining the <strong>step</strong> option with <a href="#extrema"><strong>min</strong> and <strong>max</strong></a> options
permits the creation of sliders with arbitrary values:</p>
<pre><code>$('.slider').quinn({ min: 0, max: 1.21, step: 0.01 });
</code></pre>
<p>When using <strong>step</strong>, your provided minimum and maximum values may be altered
to ensure that they “fit” the step correctly. Note that in the example below
the minimum value 5 is not available since <code>step: 20</code> is used. The lower
value is instead rounded to 20 (not 0 since this is lower than the minimum
chosen when creating the slider). Similarly, 95 is rounded down to the nearest
inclusive step, 80.</p>
<pre><code>$('.slider').quinn({ min: 5, max: 95, step: 20 });
</code></pre>
<h3 id="drawTo">Drawing Options <code>drawTo: { left: from, right: to }</code></h3>
<p>Sometimes you might want to draw a slider which is wider than the <strong>min</strong> and
<strong>max</strong> options you gave it. This is achieved by passing a two-element array
as <strong>drawTo</strong>.</p>
<p>The example below draws the slider from a value of 0 up to 100, but only
permits selecting a value between 30 and 70.</p>
<pre><code>$('.slider').quinn({
min: 30, max: 70, drawTo: { left: 0, right: 100 }
});
</code></pre>
<h3 id="values">Multiple Values <code>value: [value1, value2, ..., valueN]</code></h3>
<p>Instead of a Quinn slider having a single value, it may instead be used to
represent a range of values, with a lower and upper value. Simply supply an
array with two numeric values.</p>
<pre><code>$('.slider').quinn({ value: [25, 75] });
</code></pre>
<p>Quinn isn’t limited to two values; add as many as you want, but with the
default renderer using more than two values will disable the blue “delta” bar.</p>
<pre><code>$('.slider').quinn({ value: [15, 30, 70, 85] });
</code></pre>
<h3 id="effects">Effects <code>effects: bool</code> <code>effectSpeed: number</code></h3>
<p>Some Quinn actions make use of jQuery effects. For example, clicking on the
slider bar immediately changes the value and animates movement of the handle
to the new position. Animation length may be altered with the <strong>effectSpeed</strong>
option which may be any valid jQuery animation length (fast, slow, or a
number), or disabled completely by setting <code>effects: false</code>.</p>
<p>If the <a href="https://gsgd.co.uk/sandbox/jquery/easing">Easing</a> library is available, your default animation easing
function will be used.</p>
<pre><code>$('.slider').quinn({ effects: false });
</code></pre>
<h3 id="only">Specific Values <code>only: [value, value, ...]</code></h3>
<p>To create a slider where the user may select only from specific values, use
the <strong>only</strong> option with an array of values which may be chosen.</p>
<pre><code>$('.slider').quinn({ only: [10, 15, 50, 80], value: 50 });
</code></pre>
<h3 id="disable">Disabling the Slider <code>disable: bool</code></h3>
<p>When you do not wish the user to be able to interact with the slider, pass
<code>false</code> with the <strong>disable</strong> option:</p>
<pre><code>$('.slider').quinn({ value: 50, disable: true });
</code></pre>
<h2 id="callbacks">Callbacks</h2>
<p>The behavior of the slider may be further customised through the use of
callback functions which are supplied as part of the options object when
creating the slider.</p>
<p>When the user alters the slider position, the order of events firing is:</p>
<ol>
<li><strong><a href="#onbegin">begin</a></strong>: Each time the user starts changing the slider value.</li>
<li><strong><a href="#ondrag">drag</a></strong>: Repeatedly as the user drags the handle to new
positions. If the callbacks all return true, and the value was changed, a
<code>redraw</code> event is then fired. <code>redraw</code> is considered internal and should
be used only if implementing your own renderer.</li>
<li><strong><a href="#onchange">change</a></strong>: When the user releases the mouse button.</li>
<li><strong><a href="#onabort">abort</a></strong>: When the user releases the mouse button, and the
change callback returns false.</li>
</ol>
<p>In addition to supplying callbacks when initializing a slider, you may bind
further callbacks to the Quinn instance:</p>
<pre class="no-example"><code>var slider = new $.Quinn(element, options);
slider.on('drag', function (value) {
console.log(value);
});
slider.on('abort', function (value) {
console.log('Value reset to ' + value);
});
</code></pre>
<h3 id="onsetup">setup <code>setup: function (currentValue, quinn)</code></h3>
<p><strong>setup</strong> is run only once, immediately after the Quinn constructor has
completed. Two arguments are supplied: the current value of the slider and the
Quinn instance. Note that the slider value given during initialization may
differ from the one given to the callback since the constructor adjusts the
slider value to fit with the <strong>min</strong>, <strong>max</strong>, and <strong>step</strong> options. The value
supplied to the callback is correct.</p>
<h3 id="onbegin">begin <code>begin: function (currentValue, quinn)</code></h3>
<p><strong>begin</strong> is fired as the user starts to adjust the slider value. This happens
when they click on the slider bar, or on the handle <em>prior</em> to the slider
being dragged to a new position.</p>
<h3 id="ondrag">drag <code>drag: function (newValue, quinn)</code></h3>
<p>The <strong>drag</strong> callback is run each time the slider value changes. The function
is supplied with two arguments: the new slider value, and the Quinn instance.</p>
<pre><code>function changeValueColour (value) {
var h = (128 - value * 1.28).toFixed(),
l = (35 + value * 0.1).toFixed();
$('.value').css('color', 'hsl('+h+', 50%, '+l+'%)');
}
$('.slider').quinn({
drag: function (newValue, slider) {
changeValueColour(newValue);
},
setup: function (value, slider) {
/* Set the initial colour. */
changeValueColour(value);
}
});
</code></pre>
<p>Be aware that the <strong>drag</strong> callback is run every time the slider value
changes, which can be extremely frequent when dragging the slider handle. This
is perfect for “hooking” in to the slider to display the value elsewhere in
your UI (such as the examples on this page), to update a graph in real-time,
etc, but is not suitable for persisting the slider value to a server unless
you like flooding your application with tens of HTTP requests per second. Use
<strong>change</strong> which is fired only after the user has finished dragging the
handle.</p>
<p>Explicitly returning false in the callback will prevent the change.</p>
<pre><code>$('.slider').quinn({
drag: function (newValue, slider) {
/* Prevent selection of 41 to 59. */
if (newValue > 40 && newValue < 60) {
return false;
}
}
});
</code></pre>
<h3 id="onchange">change <code>change: function (newValue, quinn)</code></h3>
<p><strong>change</strong> is similar to the to the <strong>drag</strong> event in that it is fired when
the slider value is changed by a user. However, unlike <strong>drag</strong> it is fired
only after the user has <em>finished</em> changing the value. This is defined as
clicking the slider bar to change the value, or lifting the left mouse button
after dragging the slider handle.</p>
<pre><code>$('.slider').quinn({
value: 25,
change: function (newValue, slider) {
/* Disallow selecting a value over 50, but only
after the user has finished moving the slider. */
if (newValue > 50) {
return false;
}
}
});
</code></pre>
<h3 id="onabort">abort <code>abort: function (restoredValue, quinn)</code></h3>
<p>The <strong>abort</strong> event is fired once the user has finished adjusting the value
(like <strong>change</strong>) but the change failed either because the <strong>change</strong> callback
returned false, or the user set the slider back to the value it was at before
they began dragging.</p>
<h2 id="progressive-enhancement">Progressive Enhancement</h2>
<p>In addition to using the Quinn directly, enhancing a <code><div></code> element, it can be
used to progressively enhance an HTML <code><input></code>, including HTML5 range elements.
In the case of range or number elements, the <code>value</code>, <code>min</code>, <code>max</code>, and <code>step</code>
attributes will be read and used when creating your Quinn element.</p>
<pre class="no-example html"><code><input type="range" value="100" min="10" max="300" step="10" />
</code></pre>
<p>If you wish to enhance a plain-ol’ <code><input></code> element, you can supply these
values as data attributes:</p>
<pre class="no-example html"><code><input type="text" value="5" data-min="-10" data-max="50" />
</code></pre>
<p>Events will be set up so that changes to the Quinn element are also made to the
HTML input, and vice versa.</p>
<pre class="no-example js"><code>$("input[type=range]").quinn();
</code></pre>
<h2 id="theming">Theming</h2>
<p>Altering Quinn’s appearance is relatively simple. The default style uses a
<a href="https://antw.github.com/quinn/images/default.png">single-image sprite</a>. If you don’t need to resize any of the
slider elements, replacing this image with <a href="https://antw.github.com/quinn/vendor/rainbow.png">an alternative</a> is
all it takes. In some cases, you may need to alter the CSS. For example:</p>
<pre class="no-example css"><code>.rainbow .bar .left, .rainbow .bar .main, .rainbow .bar .right,
.rainbow .active-bar .left, .rainbow .active-bar .main,
.rainbow .active-bar .right, .rainbow .handle {
background-image: url(vendor/rainbow.png);
}
.rainbow .bar, .rainbow .bar .left, .rainbow .bar .main,
.rainbow .bar .right, .rainbow .active-bar .left,
.rainbow .active-bar .main, .rainbow .active-bar .right {
height: 25px;
}
.rainbow .handle {
height: 24px;
width: 24px;
}
</code></pre>
<pre class="rainbow hide-code"><code>function changeValueColour (value) {
var h = (128 - value * 1.28).toFixed(),
l = (35 + value * 0.1).toFixed();
$('.value').css('color', 'hsl('+h+', 50%, '+l+'%)');
}
$('.slider').quinn({
value: 25,
drag: function (newValue, slider) {
changeValueColour(newValue);
},
setup: function (value, slider) {
/* Set the initial colour. */
changeValueColour(value);
}
});
</code></pre>
<h2 id="history">History</h2>
<h4 id="may-2022">1.2.2 <em>23 May, 2022</em></h4>
<ul>
<li>Fixes incorrectly positioned slider handle in default CSS styles. This fix
prevents the handle from always being placed <em>inside</em> the bar rather than
overhanging.</li>
</ul>
<h4 id="may-2022-1">1.2.1 <em>17 May, 2022</em></h4>
<ul>
<li>Fixes that the delta bar may be positioned incorrect if the slider container
was not visible.</li>
</ul>
<h4 id="may-2022-2">1.2.0 <em>14 May, 2022</em></h4>
<ul>
<li>An outrageously long overdue update to add role and aria accessibility
attributes to slider handles.</li>
</ul>
<h4 id="october-2014">1.1.0 <em>30 October, 2014</em></h4>
<ul>
<li>
<p>Quinn can now progressively-enhance HTML inputs, including “range” and
“number” elements. The width of the original will be retained in the enhanced
version, and values will be sent back to the original element. See
<a href="#progressive-enhancement">progressive enhancement</a> for more information.</p>
</li>
<li>
<p>Improved rendering of the blue “delta” bar, and handle positioning. If you
want your handle to overhang the edges of bar, you need to add a negative left
and right margin (not necessary with the default theme so long as you use the
updated “quinn.css” file).</p>
</li>
</ul>
<h4 id="august-16th-2012">1.0.5 <em>August 16th, 2012</em></h4>
<ul>
<li>
<p>Added support for changing the value with the keyboard arrow keys, page
up and down. Alt+Left and Alt+Right will instantly set the minimum and
maximum values respectively.</p>
<p>A new option, <code>keyFloodWait</code>, will impose a delay after the user lifts a
key, to wait and see if they repeatedly press the key to further alter
the value. This is disabled by default, but may be useful if you trigger
an expensive action (e.g. XmlHttpRequest) whenever the slider value
changes.</p>
</li>
</ul>
<h4 id="july-11th-2012">1.0.2 <em>July 11th, 2012</em></h4>
<ul>
<li>Added a HiDPI “Retina” sprite. If you wish to use it, be sure to update
not only your copy of the Quinn JS, but also the CSS file and new image
from the “images” directory.</li>
</ul>
<h4 id="may-10th-2012">1.0.1 <em>May 10th, 2012</em></h4>
<ul>
<li>Added a <code>strict</code> option which prevents the initial value being snapped
to the <code>step</code> value.</li>
</ul>
<h4 id="april-14th-2012">1.0.0 <em>April 14th, 2012</em></h4>
<ul>
<li>
<p><strong>This release contains changes which are not backwards-compatible with
previous versions.</strong> You should only need to make small changes, but this
release is not “add to the repo and go”…</p>
</li>
<li>
<p>Underscore dependency is now v1.3.1 or newer.</p>
</li>
<li>
<p>The <code>range</code> and <code>selectable</code> options has been removed and replaced with
<code>min</code> and <code>max</code>. If you wish to draw a slider wider than the minimum and
maximum values (previously possible with a combination of <code>range</code> and
<code>selectable</code>) you may instead <a href="#drawTo">use the new <code>drawTo</code> option</a>.</p>
</li>
<li>
<p>Events have been renamed. <code>onChange</code>/<code>change</code> is now <code>drag</code>, and
<code>onCommit</code>/<code>commit</code> is now <code>change</code>.</p>
</li>
<li>
<p>Quinn’s styling rules <a href="https://github.com/antw/quinn/commit/ea29f2f">have been changed</a>. If you use the
default Quinn theme with no changes you should be able to simple drop the
new stylesheet into your assets or public directory. If you customise the
theme see the <a href="https://github.com/antw/quinn/commit/ea29f2f">above referenced commit</a> for more information.
The <code>.active-bar</code> class has been renamed to <code>.delta-bar</code>.</p>
</li>
<li>
<p>Quinn has been heavily refactored. Instead of a single class trying to do
everything, there now exists a <code>Model</code> on which values are set, and is
responsible for ensuring the values set are valid. A <code>Renderer</code> has been
added which is solely responsible for creating the visual representation of
the slider. The default Renderer creates the same HTML as before, but
supplying your own renderer allows you to create completely custom sliders
(you could even write a <code>CanvasRenderer</code> if you so desired).</p>
</li>
<li>
<p>You may now use <a href="#values">more than two values</a> with Quinn.</p>
</li>
<li>
<p>The Quinn instance is no longer attached to the DOM node using
<code>jQuery.fn.data</code>. If you need to keep hold of the instance (for example, to
alter the value elsewhere) you should use the constructor manually:</p>
<pre class="no-example"><code>new $.Quinn($('element'), options);
</code></pre>
</li>
<li>
<p>Two new events have been added: <code>enabled</code> and <code>disabled</code>, triggered when the
slider is enabled and disabled.</p>
</li>
<li>
<p>Since both jQuery and Backbone renamed their <code>bind</code> methods to <code>on</code>, Quinn
has followed suit and done likewise.</p>
<pre class="no-example"><code>var quinn = new $.Quinn($('element'), options);
quinn.on('drag', function () { /* ... */ });
quinn.on('change', function () { /* ... */ });
quinn.on('abort', function () { /* ... */ });
</code></pre>
</li>
<li>
<p>The internal methods <code>__willChange</code>, <code>__hasChanged</code>, and <code>__abortChange</code>
have been renamed to <code>start</code>, <code>resolve</code>, and <code>reject</code> to more closely match
the jQuery.Deferred API. Note that $.Quinn is <em>not</em> a jQuery.Deferred
object; other Deferred methods are not provided.</p>
</li>
<li>
<p>A couple of fixes to touchevents; Quinn will behave better on smartphones
and tablets.</p>
</li>
<li>
<p>Better positioning of the slider handles. The positioning of each handle is
determined based on its radius, and the height of the slider bar to which it
belongs. This results in better handling of custom CSS which has large
handles.</p>
</li>
</ul>
<h4 id="february-10th-2012">0.4.2 <em>February 10th, 2012</em></h4>
<p>Changed the way touch-support was detected to fix clicking on the handle not
working correctly in Chrome 17.</p>
<h4 id="january-20th-2012">0.4.1 <em>January 20th, 2012</em></h4>
<p>Fix for an occasional error when clicking on the bar of sliders when animation
is enabled.</p>
<h4 id="december-8th-2011">0.4.0 <em>December 8th, 2011</em></h4>
<p>Quinn ranges may now also represent a <a href="#values">range of values</a> by providing a
two-element array as the value option. Note that this will be the last major
Quinn release which will use the current “change” and “commit” callback names;
0.5 will change these to “drag” and “change” respectively.</p>
<h4 id="october-4th-2011">0.3.9 <em>October 4th, 2011</em></h4>
<p>During <code>onChange</code> callbacks, <code>quinn.value</code> will now be the new value of the
slider, and not the previous value.</p>
<h4 id="september-29th-2011">0.3.8 <em>September 29th, 2011</em></h4>
<p>Added <code>width</code> and <code>handleWidth</code> to manually set the width of these elements.
Useful when using Quinn on a wrapper element which hasn’t yet been added to
the DOM.</p>
<h4 id="august-18th-2011">0.3.7 <em>August 18th, 2011</em></h4>
<p>Fix a bug with Firefox 6 where elements positioned absolutely with fractional
pixel values would not display correctly.</p>
<h4 id="august-15th-2011">0.3.6 <em>August 15th, 2011</em></h4>
<p>Fix a rendering error introduced in 0.3.4 where the blue active bar was placed
in the wrong position when both slider range values were above or below zero.</p>
<h4 id="august-15th-2011-1">0.3.5 <em>August 15th, 2011</em></h4>
<p>Some IE 8 fixes.</p>
<h4 id="august-14th-2011">0.3.4 <em>August 14th, 2011</em></h4>
<p>The blue “active bar” now originates at zero rather than the lowest slider
value, allowing sliders with sub-zero values to be better represented than
before.</p>
<h4 id="july-28th-2011">0.3.3 <em>July 28th, 2011</em></h4>
<p>Add a <code>disabledOpacity</code> option for controlling what opacity is used when
disabling.</p>
<h4 id="july-21st-2011">0.3.1 <em>July 21st, 2011</em></h4>
<p>Small stylesheet adjustment to ensure that the slider handle may be moved all
the way to the right of the bar.</p>
<h4 id="june-27th-2011">0.3.0 <em>June 27th, 2011</em></h4>
<p>Events may be bound to the Quinn instance just like DOM events in jQuery using
<code>bind</code>. The onComplete callback has been renamed onCommit.</p>
<h4 id="june-14th-2011">0.2.1 <em>June 14th, 2011</em></h4>
<p>Quinn has now been tested and fixed for IE7, urgh. Opera has been tested and,
unsurprisingly, works perfectly.</p>
<h4 id="june-13th-2011">0.2.0 <em>June 13th, 2011</em></h4>
<p><code>stepUp</code> and <code>stepDown</code> have been added which are similar to the methods of
the same name on HTML 5 range and number inputs. Quinn instances may now be
created using <code>new $.Quinn(...)</code> if you need to hang on to the slider instance
after creation. Default theme changed to use a modified version of Aristo.
Fixed an issue when using <code>selectable</code> with <code>step</code> when the selectable options
didn’t fit the step.</p>
<h4 id="june-10th-2011">0.1.6 <em>June 10th, 2011</em></h4>
<p>The <code>only</code> option has been added which restricts the choosable values to those
which are in the <code>only</code> array. Respects the <code>selectable</code> and <code>range</code> settings.
Clicking in the space above the visible slider bar now correctly triggers
events.</p>
<h4 id="june-9th-2011">0.1.4 <em>June 9th, 2011</em></h4>
<p>Adds support for touch devices (iOS, Android, etc). Various small fixes to
make the library “more jQuery-like”, including the ability to chain other
functions off <code>$.fn.quinn()</code>. “Click-dragging” no longer fires two
<code>onComplete</code> events; only one when the user releases the mouse button.</p>
<h4 id="june-9th-2011-1">0.1.2 <em>June 9th, 2011</em></h4>
<p>When clicking on the slider bar, the mouse button may be held down to refine
the value by dragging the handle. The click and drag actions will fire
separate <code>onComplete</code> events.</p>
<h4 id="june-8th-2011">0.1.0 <em>June 8th, 2011</em></h4>
<p>Initial release on GitHub. Supports most planned features, but tests in Opera
and Internet Explorer are not yet complete.</p>
<!-- end README -->
</div>
<script type="text/javascript" src="vendor/jquery-1.10.2.js"></script>
<script type="text/javascript" src="vendor/jquery.easing.1.3.js"></script>
<script type="text/javascript" src="vendor/underscore-1.3.1.js"></script>
<script type="text/javascript" src="jquery.quinn.js"></script>
<script type="text/javascript" src="vendor/highlight.pack.js"></script>
<script type="text/javascript" src="vendor/examples.js"></script>
</body>
</html>