-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
executable file
·244 lines (181 loc) · 7.39 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
<!DOCTYPE html>
<html lang="en">
<head>
<title>Living Color</title>
<meta name="description" content="You can hue what you want to hue">
<meta charset="UTF-8">
<link rel="shortcut icon" href="favicon.ico">
<link href="assets/main.css" type="text/css" rel="stylesheet">
<link href="http://fonts.googleapis.com/css?family=Archivo+Black|Archivo+Narrow:400,700" rel="stylesheet" type="text/css">
<link href="assets/prettify.css" type="text/css" rel="stylesheet">
<script type="text/javascript" src="assets/prettify.js"></script>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js"></script>
<!--
<script type="text/javascript" src="http://cdnjs.cloudflare.com/ajax/libs/zepto/1.0rc1/zepto.min.js"></script>
-->
<script type="text/javascript" src="LivingColor.js"></script>
<script type="text/javascript">
$(function()
{
prettyPrint();
LivingColor.start({
// "minimized": true,
"defaultScheme": [
{ "selector": "body", "color": "4D2201", "backgroundColor": "FFD4B8", "filters": [] },
{ "selector": "h1", "color": "ED5118", "backgroundColor": "", "filters": [] },
{ "selector": "h1 span", "color": "322F87", "backgroundColor": "", "filters": [] },
{ "selector": "#demo_image", "color": "", "backgroundColor": "",
"filters": ["saturate(150%)"] }
]
});
$("#try").on("click", function()
{
if($("#LivingColor").is(".minimized"))
$("#LivingColor h4 a.minimize").click();
$("#LivingColor .wrap input:eq(0)").focus();
});
$(document).on("mousemove", "#LivingColorFilters .sepia input[type='range']", function(e)
{
if(e.which !== 1 || LivingColor['$selector'].val() !== '#demo_stephen')
return true;
var val = parseInt($("#LivingColorFilters .sepia input[type='range']").val());
var $div = $("#demo_stephen");
if(val > 20)
{
var opacity = val / 50;
opacity = ((opacity * opacity) / 4);
$div.css("opacity", opacity * 0.95).show();
if(val > 80)
{
var invert = (val - 80) / 10;
invert = ((invert * invert) / 4);
$div[0].style[LivingColor.prefixedFilterRule()] = "invert("+(100*invert)+"%)";
}
}
else $div.hide();
});
if(navigator.userAgent.match(/Firefox/))
$("body").addClass("firefox");
});
</script>
</head>
<body>
<div id="demo_stephen"></div>
<a id="ribbon" href="http://github.com/lukifer/LivingColor"></a>
<div id="container">
<div class="row">
<div class="column grid_12">
<div id="logo">
<h1>Living <span>Color</span></h1>
<h3>Experiment on the colors of your website, with real-time feedback</h3>
</div> <!-- #logo -->
</div>
</div>
<div class="row">
<div class="column grid_5">
<ul id="Fs-n-Bs">
<li>Choose page elements using <a href="https://developer.mozilla.org/en-US/docs/Web/Guide/CSS/Getting_started/Selectors">CSS selectors</a>, or the handy targeting tool (<span class="target_icon"></span>).</li>
<li>Play with <span class="text_color">text color</span> and <span class="background_color">background color</span>, seeing your changes as they're applied.</li>
<li>Click the filter icon (<span class="filters_icon"></span>) to change brightness, contrast, saturation, blur, and more.</li>
<li>Save color schemes to compare.</li>
<li>Supports Chrome, Safari, and Firefox 35+.</li>
<li><a href="http://opensource.org/licenses/MIT">MIT Licensed</a></li>
<!-- <li><a id="try" href="javascript:void(0);">Try it now!</a></li> -->
</ul>
<div id="downloads">
<a id="try" href="javascript:void(0);" class="button">
<label>Try It Now!</label>
</a>
<a id="download_js" href="LivingColor.js" download="LivingColor.js" class="button">
<span>⬇</span>
<label>Download (Javascript)</label>
<img src="assets/js.png" />
</a>
<a id="download_chrome" href="javascript:void(0);" class="button" disabled="disabled">
<span>⊕</span>
<!-- <span>+</span> -->
<label>Install (Chrome)</label>
<label class="subtext">Coming Soon!</label>
<img src="assets/chrome.png" />
<!-- <label class="subsubtext">Passive aggressive comments hiding in source code</label> -->
</a>
</div>
</div>
<!-- .grid_5 -->
<div class="column grid_7">
<div id="demo_frame">
<img id="demo_image" src="assets/spacehawking.jpg" alt="Lego Stephen Hawking In Space" />
</div>
<h5 id="demo_subtitle">Whatever you do, don't make Professor Hawking sepia.<br>You wouldn't like him when he's sepia.</h5>
<!-- <h5 id="demo_subtitle">Click the filter icon (<span class="filters_icon"></span>) to change contrast, saturation and more!</h5> -->
</div>
<!-- .grid_7 -->
</div>
<div class="row">
<div class="column grid_12">
<a name="usage"></a>
<h2>Usage</h2>
</div>
<div class="column grid_6">
<pre class="prettyprint"><!-- HTML -->
<script src="LivingColor.js"></script>
</pre>
</div>
<div class="column grid_6">
<pre class="prettyprint">// Javascript
$(function() { LivingColor.start(); }
</pre>
</div>
</div>
<div id="faq" class="row">
<div class="column grid_12">
<h2>Fastidiously Asked Questions</h2>
</div>
<div class="column grid_4">
<p><b>Q: Why don't you have any questions yet?</b></p>
<p>A: I am Jack's superfluous paradox.</p>
</div>
<div class="column grid_4">
</div>
<div class="column grid_4">
</div>
</div>
<div class="row">
<div class="column grid_6">
<h2>Version History</h2>
<h3>v1.0</h3>
<ul>
<li>Colors and backgrounds and filters, oh my!</li>
<li>Docmentation and example</li>
</ul>
</div>
<div class="column grid_6">
<h2>Known Bugs</h2>
<ul>
<li>Inline styles of targeted elements will be overwritten. (Don't use inline styles, kids.)</li>
<li>Page styling can sometimes over-ride Living Color's own styling and make it look goofy.</li>
<li>Setting a <code>transform</code> value on <code><body></code> screws up window positioning. If possible, set the transform on a wrapper div instead.</li>
</ul>
</div>
</div>
</div>
<div id="footer">
<div class="shadow"></div>
<div class="row">
<div class="column grid_12">
<a class="me" href="http://lukifer.net/"><img width="60" height="60" border="0" alt="Lukifer"
src="http://www.gravatar.com/avatar/ce1509ecb78ccb5f2b4f002eda3afb12.png"></a>
<div class="tagline tagline_left">
<p>Brought to you by <a href="http://lukifer.net/">Lukifer</a></p>
<p>Follow on <a href="http://twitter.com/lkfr" alt="@lkfr">Twitter</a> or <a href="https://github.com/lukifer" alt="@lukifer">GitHub</a></p>
</div>
<div class="tagline tagline_right">
<p>Report bugs via the <a href="https://github.com/lukifer/HoverForMore.js/issues">Issue Tracker</a></p>
<p>Donations welcomed via <a href="https://www.gittip.com/lukifer/">GitTip</a> or <a href="https://www.paypal.com/cgi-bin/webscr?cmd=_donations&[email protected]&item_name=HoverForMore¤cy_code=USD">PayPal</a></p>
</div>
<a class="github" href="http://github.com"><img src="assets/github.png" width="130" height="60" alt="GitHub: Social Coding" /></a>
</div>
</div>
</div>
</body>
</html>