-
Notifications
You must be signed in to change notification settings - Fork 0
/
colorpicker.html
56 lines (50 loc) · 1.94 KB
/
colorpicker.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
<html>
<link rel="stylesheet" href="static/colorpicker/colorpicker.css" type="text/css" />
<body>
<div>
<input class='testinput'/>
<input style='position:absolute;left:300px;top:300px;' class='testinput'/>
<input style='position:absolute;right:0px;bottom:0px;' class='testinput'/>
</div>
</body>
<script type="text/javascript" src="static/jquery-1.9.1.js"></script>
<script type="text/javascript" src="static/jquery-ui-1.10.1.custom.min.js"></script>
<script type='text' description='raw html before javascript encode'>
<div id='colorchooser'>
<div class='innercontainer'>
<canvas class='colorcanvas' width="200" height="230"></canvas>
<div class='sidebox'>
<div class='backboxtile'></div>
<div class='previewbox'></div>
<div class='comparebox'></div>
<div class='inputbox'>
<span class='label'>Hue:</span><br />
<input name='hue'></input><br />
<span class='label'>Saturation:</span><br />
<input name='saturation'></input><br />
<span class='label'>Lightness:</span><br />
<input name='lightness'></input><br />
<span class='label'>Alpha:</span><br />
<input name='alpha'></input><br />
</div>
</div>
<div class='palettebox'>
<div class='paletteicon'></div>
<div class='palettelist'>
</div>
</div>
</div>
</div>
</script>
<script src='static/colorpicker.js'></script>
<script>
window.colorpickerstaticpath='static/colorpicker/';
$(".testinput").click(function(){
showColorChooser($(this));
return false;
});
$(".testinput").change(function(){
console.log("Value change "+$(this).val());
});
</script>
</html>