oulu-rails 0.7.6 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/oulu-rails/version.rb +1 -1
- data/vendor/assets/stylesheets/_oulu-base.sass +1 -1
- data/vendor/assets/stylesheets/settings/initializers/_reset.sass +0 -38
- data/vendor/assets/stylesheets/settings/initializers/_sanitize.sass +262 -0
- metadata +3 -40
- data/vendor/assets/javascripts/oulu-ie8.js +0 -6
- data/vendor/assets/javascripts/oulu-ie9.js +0 -2
- data/vendor/assets/javascripts/oulu.js +0 -2
- data/vendor/assets/javascripts/oulu/helpers/js-autosize.js.coffee +0 -2
- data/vendor/assets/javascripts/oulu/helpers/js-checkbox.js.coffee +0 -6
- data/vendor/assets/javascripts/oulu/helpers/js-click-animate.js.coffee +0 -8
- data/vendor/assets/javascripts/oulu/helpers/js-delay-hidden.js.coffee +0 -4
- data/vendor/assets/javascripts/oulu/helpers/js-focused.js.coffee +0 -7
- data/vendor/assets/javascripts/oulu/helpers/js-hack.js.coffee +0 -8
- data/vendor/assets/javascripts/oulu/helpers/js-hide-after.j.coffee +0 -5
- data/vendor/assets/javascripts/oulu/helpers/js-hover-z-index.js.coffee +0 -5
- data/vendor/assets/javascripts/oulu/helpers/js-hovered.js.coffee +0 -17
- data/vendor/assets/javascripts/oulu/helpers/js-one-animate.js.coffee +0 -5
- data/vendor/assets/javascripts/oulu/helpers/js-open-children.js.coffee +0 -28
- data/vendor/assets/javascripts/oulu/helpers/js-open.js.coffee +0 -51
- data/vendor/assets/javascripts/oulu/helpers/js-scroll-to-top.js.coffee +0 -11
- data/vendor/assets/javascripts/oulu/helpers/js-scroll.js.coffee +0 -9
- data/vendor/assets/javascripts/oulu/helpers/js-side-slide.js.coffee +0 -6
- data/vendor/assets/javascripts/oulu/helpers/js-window-loading.js.coffee +0 -15
- data/vendor/assets/javascripts/oulu/helpers/js-window-sizes.js.coffee +0 -6
- data/vendor/assets/javascripts/oulu/helpers/open-close.js.coffee +0 -23
- data/vendor/assets/javascripts/oulu/ie/PIE_IE678.js +0 -72
- data/vendor/assets/javascripts/oulu/ie/PIE_IE9.js +0 -46
- data/vendor/assets/javascripts/oulu/ie/ie-selectors.js.coffee +0 -3
- data/vendor/assets/javascripts/oulu/ie/ie8-selectors.js.coffee +0 -3
- data/vendor/assets/javascripts/oulu/ie/ie9-selectors.js.coffee +0 -6
- data/vendor/assets/javascripts/oulu/ie/jquery.belatedPNG.min.js +0 -29
- data/vendor/assets/javascripts/oulu/ie/jquery.linkscubber.js +0 -7
- data/vendor/assets/javascripts/oulu/ie/svgeezy.min.js +0 -12
- data/vendor/assets/javascripts/oulu/plugins/check-box.js.coffee +0 -34
- data/vendor/assets/javascripts/oulu/plugins/footerFixed.js +0 -74
- data/vendor/assets/javascripts/oulu/plugins/jquery.autosize.min.js +0 -7
- data/vendor/assets/javascripts/oulu/plugins/jquery.cheat-code.js +0 -63
- data/vendor/assets/javascripts/oulu/plugins/jquery.css3form.js +0 -195
- data/vendor/assets/javascripts/oulu/plugins/jquery.depend.min.js +0 -13
- data/vendor/assets/javascripts/oulu/plugins/sns-buttons.js +0 -339
- data/vendor/assets/javascripts/oulu/plugins/waves.js +0 -338
- data/vendor/assets/stylesheets/settings/functions/_grid.sass +0 -34
@@ -1,338 +0,0 @@
|
|
1
|
-
/*!
|
2
|
-
* Waves v0.6.4
|
3
|
-
* http://fian.my.id/Waves
|
4
|
-
*
|
5
|
-
* Copyright 2014 Alfiana E. Sibuea and other contributors
|
6
|
-
* Released under the MIT license
|
7
|
-
* https://github.com/fians/Waves/blob/master/LICENSE
|
8
|
-
*/
|
9
|
-
|
10
|
-
;(function(window) {
|
11
|
-
'use strict';
|
12
|
-
|
13
|
-
var Waves = Waves || {};
|
14
|
-
var $$ = document.querySelectorAll.bind(document);
|
15
|
-
|
16
|
-
// Find exact position of element
|
17
|
-
function isWindow(obj) {
|
18
|
-
return obj !== null && obj === obj.window;
|
19
|
-
}
|
20
|
-
|
21
|
-
function getWindow(elem) {
|
22
|
-
return isWindow(elem) ? elem : elem.nodeType === 9 && elem.defaultView;
|
23
|
-
}
|
24
|
-
|
25
|
-
function offset(elem) {
|
26
|
-
var docElem, win,
|
27
|
-
box = {top: 0, left: 0},
|
28
|
-
doc = elem && elem.ownerDocument;
|
29
|
-
|
30
|
-
docElem = doc.documentElement;
|
31
|
-
|
32
|
-
if (typeof elem.getBoundingClientRect !== typeof undefined) {
|
33
|
-
box = elem.getBoundingClientRect();
|
34
|
-
}
|
35
|
-
win = getWindow(doc);
|
36
|
-
return {
|
37
|
-
top: box.top + win.pageYOffset - docElem.clientTop,
|
38
|
-
left: box.left + win.pageXOffset - docElem.clientLeft
|
39
|
-
};
|
40
|
-
}
|
41
|
-
|
42
|
-
function convertStyle(obj) {
|
43
|
-
var style = '';
|
44
|
-
|
45
|
-
for (var a in obj) {
|
46
|
-
if (obj.hasOwnProperty(a)) {
|
47
|
-
style += (a + ':' + obj[a] + ';');
|
48
|
-
}
|
49
|
-
}
|
50
|
-
|
51
|
-
return style;
|
52
|
-
}
|
53
|
-
|
54
|
-
var Effect = {
|
55
|
-
|
56
|
-
// Effect delay
|
57
|
-
duration: 750,
|
58
|
-
|
59
|
-
show: function(e, element) {
|
60
|
-
|
61
|
-
// Disable right click
|
62
|
-
if (e.button === 2) {
|
63
|
-
return false;
|
64
|
-
}
|
65
|
-
|
66
|
-
var el = element || this;
|
67
|
-
|
68
|
-
// Create ripple
|
69
|
-
var ripple = document.createElement('div');
|
70
|
-
ripple.className = 'waves-ripple';
|
71
|
-
el.appendChild(ripple);
|
72
|
-
|
73
|
-
// Get click coordinate and element witdh
|
74
|
-
var pos = offset(el);
|
75
|
-
var relativeY = (e.pageY - pos.top);
|
76
|
-
var relativeX = (e.pageX - pos.left);
|
77
|
-
var scale = 'scale('+((el.clientWidth / 100) * 10)+')';
|
78
|
-
|
79
|
-
// Support for touch devices
|
80
|
-
if ('touches' in e) {
|
81
|
-
relativeY = (e.touches[0].pageY - pos.top);
|
82
|
-
relativeX = (e.touches[0].pageX - pos.left);
|
83
|
-
}
|
84
|
-
|
85
|
-
// Attach data to element
|
86
|
-
ripple.setAttribute('data-hold', Date.now());
|
87
|
-
ripple.setAttribute('data-scale', scale);
|
88
|
-
ripple.setAttribute('data-x', relativeX);
|
89
|
-
ripple.setAttribute('data-y', relativeY);
|
90
|
-
|
91
|
-
// Set ripple position
|
92
|
-
var rippleStyle = {
|
93
|
-
'top': relativeY+'px',
|
94
|
-
'left': relativeX+'px'
|
95
|
-
};
|
96
|
-
|
97
|
-
ripple.className = ripple.className + ' waves-notransition';
|
98
|
-
ripple.setAttribute('style', convertStyle(rippleStyle));
|
99
|
-
ripple.className = ripple.className.replace('waves-notransition', '');
|
100
|
-
|
101
|
-
// Scale the ripple
|
102
|
-
rippleStyle['-webkit-transform'] = scale;
|
103
|
-
rippleStyle['-moz-transform'] = scale;
|
104
|
-
rippleStyle['-ms-transform'] = scale;
|
105
|
-
rippleStyle['-o-transform'] = scale;
|
106
|
-
rippleStyle.transform = scale;
|
107
|
-
rippleStyle.opacity = '1';
|
108
|
-
|
109
|
-
rippleStyle['-webkit-transition-duration'] = Effect.duration + 'ms';
|
110
|
-
rippleStyle['-moz-transition-duration'] = Effect.duration + 'ms';
|
111
|
-
rippleStyle['-o-transition-duration'] = Effect.duration + 'ms';
|
112
|
-
rippleStyle['transition-duration'] = Effect.duration + 'ms';
|
113
|
-
|
114
|
-
rippleStyle['-webkit-transition-timing-function'] = 'cubic-bezier(0.250, 0.460, 0.450, 0.940)';
|
115
|
-
rippleStyle['-moz-transition-timing-function'] = 'cubic-bezier(0.250, 0.460, 0.450, 0.940)';
|
116
|
-
rippleStyle['-o-transition-timing-function'] = 'cubic-bezier(0.250, 0.460, 0.450, 0.940)';
|
117
|
-
rippleStyle['transition-timing-function'] = 'cubic-bezier(0.250, 0.460, 0.450, 0.940)';
|
118
|
-
|
119
|
-
ripple.setAttribute('style', convertStyle(rippleStyle));
|
120
|
-
},
|
121
|
-
|
122
|
-
hide: function(e) {
|
123
|
-
TouchHandler.touchup(e);
|
124
|
-
|
125
|
-
var el = this;
|
126
|
-
var width = el.clientWidth * 1.4;
|
127
|
-
|
128
|
-
// Get first ripple
|
129
|
-
var ripple = null;
|
130
|
-
var ripples = el.getElementsByClassName('waves-ripple');
|
131
|
-
if (ripples.length > 0) {
|
132
|
-
ripple = ripples[ripples.length - 1];
|
133
|
-
} else {
|
134
|
-
return false;
|
135
|
-
}
|
136
|
-
|
137
|
-
var relativeX = ripple.getAttribute('data-x');
|
138
|
-
var relativeY = ripple.getAttribute('data-y');
|
139
|
-
var scale = ripple.getAttribute('data-scale');
|
140
|
-
|
141
|
-
// Get delay beetween mousedown and mouse leave
|
142
|
-
var diff = Date.now() - Number(ripple.getAttribute('data-hold'));
|
143
|
-
var delay = 350 - diff;
|
144
|
-
|
145
|
-
if (delay < 0) {
|
146
|
-
delay = 0;
|
147
|
-
}
|
148
|
-
|
149
|
-
// Fade out ripple after delay
|
150
|
-
setTimeout(function() {
|
151
|
-
var style = {
|
152
|
-
'top': relativeY+'px',
|
153
|
-
'left': relativeX+'px',
|
154
|
-
'opacity': '0',
|
155
|
-
|
156
|
-
// Duration
|
157
|
-
'-webkit-transition-duration': Effect.duration + 'ms',
|
158
|
-
'-moz-transition-duration': Effect.duration + 'ms',
|
159
|
-
'-o-transition-duration': Effect.duration + 'ms',
|
160
|
-
'transition-duration': Effect.duration + 'ms',
|
161
|
-
'-webkit-transform': scale,
|
162
|
-
'-moz-transform': scale,
|
163
|
-
'-ms-transform': scale,
|
164
|
-
'-o-transform': scale,
|
165
|
-
'transform': scale,
|
166
|
-
};
|
167
|
-
|
168
|
-
ripple.setAttribute('style', convertStyle(style));
|
169
|
-
|
170
|
-
setTimeout(function() {
|
171
|
-
try {
|
172
|
-
el.removeChild(ripple);
|
173
|
-
} catch(e) {
|
174
|
-
return false;
|
175
|
-
}
|
176
|
-
}, Effect.duration);
|
177
|
-
}, delay);
|
178
|
-
},
|
179
|
-
|
180
|
-
// Little hack to make <input> can perform waves effect
|
181
|
-
wrapInput: function(elements) {
|
182
|
-
for (var a = 0; a < elements.length; a++) {
|
183
|
-
var el = elements[a];
|
184
|
-
|
185
|
-
if (el.tagName.toLowerCase() === 'input') {
|
186
|
-
var parent = el.parentNode;
|
187
|
-
|
188
|
-
// If input already have parent just pass through
|
189
|
-
if (parent.tagName.toLowerCase() === 'i' && parent.className.indexOf('waves-effect') !== -1) {
|
190
|
-
continue;
|
191
|
-
}
|
192
|
-
|
193
|
-
// Put element class and style to the specified parent
|
194
|
-
var wrapper = document.createElement('i');
|
195
|
-
wrapper.className = el.className + ' waves-input-wrapper';
|
196
|
-
|
197
|
-
var elementStyle = el.getAttribute('style');
|
198
|
-
|
199
|
-
if (!elementStyle) {
|
200
|
-
elementStyle = '';
|
201
|
-
}
|
202
|
-
|
203
|
-
wrapper.setAttribute('style', elementStyle);
|
204
|
-
|
205
|
-
el.className = 'waves-button-input';
|
206
|
-
el.removeAttribute('style');
|
207
|
-
|
208
|
-
// Put element as child
|
209
|
-
parent.replaceChild(wrapper, el);
|
210
|
-
wrapper.appendChild(el);
|
211
|
-
}
|
212
|
-
}
|
213
|
-
}
|
214
|
-
};
|
215
|
-
|
216
|
-
|
217
|
-
/**
|
218
|
-
* Disable mousedown event for 500ms during and after touch
|
219
|
-
*/
|
220
|
-
var TouchHandler = {
|
221
|
-
/* uses an integer rather than bool so there's no issues with
|
222
|
-
* needing to clear timeouts if another touch event occurred
|
223
|
-
* within the 500ms. Cannot mouseup between touchstart and
|
224
|
-
* touchend, nor in the 500ms after touchend. */
|
225
|
-
touches: 0,
|
226
|
-
allowEvent: function(e) {
|
227
|
-
var allow = true;
|
228
|
-
|
229
|
-
if (e.type === 'touchstart') {
|
230
|
-
TouchHandler.touches += 1; //push
|
231
|
-
} else if (e.type === 'touchend' || e.type === 'touchcancel') {
|
232
|
-
setTimeout(function() {
|
233
|
-
if (TouchHandler.touches > 0) {
|
234
|
-
TouchHandler.touches -= 1; //pop after 500ms
|
235
|
-
}
|
236
|
-
}, 500);
|
237
|
-
} else if (e.type === 'mousedown' && TouchHandler.touches > 0) {
|
238
|
-
allow = false;
|
239
|
-
}
|
240
|
-
|
241
|
-
return allow;
|
242
|
-
},
|
243
|
-
touchup: function(e) {
|
244
|
-
TouchHandler.allowEvent(e);
|
245
|
-
}
|
246
|
-
};
|
247
|
-
|
248
|
-
|
249
|
-
/**
|
250
|
-
* Delegated click handler for .waves-effect element.
|
251
|
-
* returns null when .waves-effect element not in "click tree"
|
252
|
-
*/
|
253
|
-
function getWavesEffectElement(e) {
|
254
|
-
if (TouchHandler.allowEvent(e) === false) {
|
255
|
-
return null;
|
256
|
-
}
|
257
|
-
|
258
|
-
var element = null;
|
259
|
-
var target = e.target || e.srcElement;
|
260
|
-
|
261
|
-
while (target.parentElement !== null) {
|
262
|
-
if (!(target instanceof SVGElement) && target.className.indexOf('waves-effect') !== -1) {
|
263
|
-
element = target;
|
264
|
-
break;
|
265
|
-
} else if (target.classList.contains('waves-effect')) {
|
266
|
-
element = target;
|
267
|
-
break;
|
268
|
-
}
|
269
|
-
target = target.parentElement;
|
270
|
-
}
|
271
|
-
|
272
|
-
return element;
|
273
|
-
}
|
274
|
-
|
275
|
-
/**
|
276
|
-
* Bubble the click and show effect if .waves-effect elem was found
|
277
|
-
*/
|
278
|
-
function showEffect(e) {
|
279
|
-
var element = getWavesEffectElement(e);
|
280
|
-
|
281
|
-
if (element !== null) {
|
282
|
-
Effect.show(e, element);
|
283
|
-
|
284
|
-
if ('ontouchstart' in window) {
|
285
|
-
element.addEventListener('touchend', Effect.hide, false);
|
286
|
-
element.addEventListener('touchcancel', Effect.hide, false);
|
287
|
-
}
|
288
|
-
|
289
|
-
element.addEventListener('mouseup', Effect.hide, false);
|
290
|
-
element.addEventListener('mouseleave', Effect.hide, false);
|
291
|
-
}
|
292
|
-
}
|
293
|
-
|
294
|
-
Waves.displayEffect = function(options) {
|
295
|
-
options = options || {};
|
296
|
-
|
297
|
-
if ('duration' in options) {
|
298
|
-
Effect.duration = options.duration;
|
299
|
-
}
|
300
|
-
|
301
|
-
//Wrap input inside <i> tag
|
302
|
-
Effect.wrapInput($$('.waves-effect'));
|
303
|
-
|
304
|
-
if ('ontouchstart' in window) {
|
305
|
-
document.body.addEventListener('touchstart', showEffect, false);
|
306
|
-
}
|
307
|
-
|
308
|
-
document.body.addEventListener('mousedown', showEffect, false);
|
309
|
-
};
|
310
|
-
|
311
|
-
/**
|
312
|
-
* Attach Waves to an input element (or any element which doesn't
|
313
|
-
* bubble mouseup/mousedown events).
|
314
|
-
* Intended to be used with dynamically loaded forms/inputs, or
|
315
|
-
* where the user doesn't want a delegated click handler.
|
316
|
-
*/
|
317
|
-
Waves.attach = function(element) {
|
318
|
-
//FUTURE: automatically add waves classes and allow users
|
319
|
-
// to specify them with an options param? Eg. light/classic/button
|
320
|
-
if (element.tagName.toLowerCase() === 'input') {
|
321
|
-
Effect.wrapInput([element]);
|
322
|
-
element = element.parentElement;
|
323
|
-
}
|
324
|
-
|
325
|
-
if ('ontouchstart' in window) {
|
326
|
-
element.addEventListener('touchstart', showEffect, false);
|
327
|
-
}
|
328
|
-
|
329
|
-
element.addEventListener('mousedown', showEffect, false);
|
330
|
-
};
|
331
|
-
|
332
|
-
window.Waves = Waves;
|
333
|
-
|
334
|
-
document.addEventListener('DOMContentLoaded', function() {
|
335
|
-
Waves.displayEffect();
|
336
|
-
}, false);
|
337
|
-
|
338
|
-
})(window);
|
@@ -1,34 +0,0 @@
|
|
1
|
-
@function gutter_width($value)
|
2
|
-
@if $value == 0 or px($value)
|
3
|
-
@return true
|
4
|
-
@else
|
5
|
-
@return null
|
6
|
-
|
7
|
-
@function columns_count($value)
|
8
|
-
@if unitless_number($value)
|
9
|
-
@if $value > 0
|
10
|
-
@return true
|
11
|
-
@else
|
12
|
-
@return null
|
13
|
-
@else
|
14
|
-
@return null
|
15
|
-
|
16
|
-
@function break_point($value)
|
17
|
-
@if string($value) and ($value == 'xs' or $value == 'sm' or $value == 'md' or $value == 'lg' or $value == 'xl')
|
18
|
-
@return true
|
19
|
-
@else if list($value) and (nth($value, 1) == 'xs' or nth($value, 1) == 'sm' or nth($value, 1) == 'md' or nth($value, 1) == 'lg' or nth($value, 1) == 'xl')
|
20
|
-
@return true
|
21
|
-
@else
|
22
|
-
@return null
|
23
|
-
|
24
|
-
@function row_class_name($value)
|
25
|
-
@if string($value) and str-slice($value, 1, 1) == ('.')
|
26
|
-
@return true
|
27
|
-
@else
|
28
|
-
@return null
|
29
|
-
|
30
|
-
@function offsets($value)
|
31
|
-
@if string($value) and $value == offsets
|
32
|
-
@return true
|
33
|
-
@else
|
34
|
-
@return null
|