materialize-sass 0.100.2.1 → 1.0.0.alpha1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (126) hide show
  1. checksums.yaml +5 -5
  2. data/README.md +18 -42
  3. data/Rakefile +17 -17
  4. data/{app/assets → assets}/javascripts/materialize-sprockets.js +8 -12
  5. data/assets/javascripts/materialize.js +11877 -0
  6. data/assets/javascripts/materialize/autocomplete.js +420 -0
  7. data/assets/javascripts/materialize/buttons.js +388 -0
  8. data/assets/javascripts/materialize/cards.js +28 -0
  9. data/assets/javascripts/materialize/carousel.js +791 -0
  10. data/assets/javascripts/materialize/cash.js +992 -0
  11. data/assets/javascripts/materialize/characterCounter.js +180 -0
  12. data/assets/javascripts/materialize/chips.js +555 -0
  13. data/assets/javascripts/materialize/collapsible.js +275 -0
  14. data/assets/javascripts/materialize/datepicker.js +898 -0
  15. data/assets/javascripts/materialize/dropdown.js +530 -0
  16. data/{app/assets → assets}/javascripts/materialize/extras/nouislider.js +1 -1
  17. data/{app/assets → assets}/javascripts/materialize/extras/nouislider.min.js +1 -1
  18. data/assets/javascripts/materialize/forms.js +223 -0
  19. data/assets/javascripts/materialize/global.js +353 -0
  20. data/assets/javascripts/materialize/materialbox.js +432 -0
  21. data/{app/assets → assets}/javascripts/materialize/modal.js +82 -113
  22. data/assets/javascripts/materialize/parallax.js +135 -0
  23. data/assets/javascripts/materialize/pushpin.js +158 -0
  24. data/assets/javascripts/materialize/range.js +305 -0
  25. data/assets/javascripts/materialize/scrollspy.js +322 -0
  26. data/assets/javascripts/materialize/select.js +426 -0
  27. data/assets/javascripts/materialize/sidenav.js +584 -0
  28. data/assets/javascripts/materialize/slider.js +383 -0
  29. data/assets/javascripts/materialize/tabs.js +460 -0
  30. data/assets/javascripts/materialize/tapTarget.js +347 -0
  31. data/assets/javascripts/materialize/timepicker.js +616 -0
  32. data/{app/assets → assets}/javascripts/materialize/toasts.js +42 -46
  33. data/assets/javascripts/materialize/tooltip.js +325 -0
  34. data/assets/javascripts/materialize/velocity.min.js +782 -0
  35. data/{app/assets → assets}/javascripts/materialize/waves.js +0 -0
  36. data/{app/assets → assets}/stylesheets/materialize.scss +5 -6
  37. data/{app/assets → assets}/stylesheets/materialize/components/_badges.scss +1 -1
  38. data/{app/assets → assets}/stylesheets/materialize/components/_buttons.scss +34 -2
  39. data/{app/assets → assets}/stylesheets/materialize/components/_cards.scss +0 -0
  40. data/{app/assets → assets}/stylesheets/materialize/components/_carousel.scss +1 -1
  41. data/{app/assets → assets}/stylesheets/materialize/components/_chips.scss +6 -5
  42. data/{app/assets → assets}/stylesheets/materialize/components/_collapsible.scss +3 -3
  43. data/{app/assets → assets}/stylesheets/materialize/components/_color.scss +0 -0
  44. data/assets/stylesheets/materialize/components/_datepicker.scss +180 -0
  45. data/{app/assets → assets}/stylesheets/materialize/components/_dropdown.scss +16 -15
  46. data/{app/assets → assets}/stylesheets/materialize/components/_global.scss +49 -14
  47. data/{app/assets → assets}/stylesheets/materialize/components/_grid.scss +1 -1
  48. data/{app/assets → assets}/stylesheets/materialize/components/_icons-material-design.scss +0 -0
  49. data/{app/assets → assets}/stylesheets/materialize/components/_materialbox.scss +0 -0
  50. data/assets/stylesheets/materialize/components/_mixins.scss +5 -0
  51. data/{app/assets → assets}/stylesheets/materialize/components/_modal.scss +1 -1
  52. data/{app/assets → assets}/stylesheets/materialize/components/_navbar.scss +0 -0
  53. data/assets/stylesheets/materialize/components/_normalize.scss +447 -0
  54. data/{app/assets → assets}/stylesheets/materialize/components/_preloader.scss +0 -0
  55. data/{app/assets → assets}/stylesheets/materialize/components/_pulse.scss +0 -0
  56. data/{app/assets/stylesheets/materialize/components/_sideNav.scss → assets/stylesheets/materialize/components/_sidenav.scss} +23 -21
  57. data/{app/assets → assets}/stylesheets/materialize/components/_slider.scss +0 -0
  58. data/{app/assets → assets}/stylesheets/materialize/components/_table_of_contents.scss +3 -3
  59. data/{app/assets → assets}/stylesheets/materialize/components/_tabs.scss +2 -2
  60. data/{app/assets → assets}/stylesheets/materialize/components/_tapTarget.scss +0 -0
  61. data/assets/stylesheets/materialize/components/_timepicker.scss +182 -0
  62. data/{app/assets → assets}/stylesheets/materialize/components/_toast.scss +0 -0
  63. data/{app/assets → assets}/stylesheets/materialize/components/_tooltip.scss +1 -0
  64. data/{app/assets → assets}/stylesheets/materialize/components/_transitions.scss +0 -0
  65. data/{app/assets → assets}/stylesheets/materialize/components/_typography.scss +8 -8
  66. data/{app/assets → assets}/stylesheets/materialize/components/_variables.scss +42 -44
  67. data/{app/assets → assets}/stylesheets/materialize/components/_waves.scss +0 -0
  68. data/{app/assets → assets}/stylesheets/materialize/components/forms/_checkboxes.scss +24 -24
  69. data/{app/assets → assets}/stylesheets/materialize/components/forms/_file-input.scss +0 -0
  70. data/{app/assets → assets}/stylesheets/materialize/components/forms/_forms.scss +0 -0
  71. data/{app/assets → assets}/stylesheets/materialize/components/forms/_input-fields.scss +49 -35
  72. data/{app/assets → assets}/stylesheets/materialize/components/forms/_radio-buttons.scss +29 -29
  73. data/{app/assets → assets}/stylesheets/materialize/components/forms/_range.scss +32 -31
  74. data/{app/assets → assets}/stylesheets/materialize/components/forms/_select.scss +20 -11
  75. data/{app/assets → assets}/stylesheets/materialize/components/forms/_switches.scss +0 -0
  76. data/{app/assets → assets}/stylesheets/materialize/extras/nouislider.css +1 -1
  77. data/lib/materialize-sass.rb +13 -23
  78. data/lib/materialize-sass/engine.rb +6 -9
  79. data/lib/materialize-sass/version.rb +1 -1
  80. data/materialize-sass.gemspec +2 -1
  81. metadata +97 -97
  82. data/app/assets/fonts/roboto/Roboto-Bold.woff +0 -0
  83. data/app/assets/fonts/roboto/Roboto-Bold.woff2 +0 -0
  84. data/app/assets/fonts/roboto/Roboto-Light.woff +0 -0
  85. data/app/assets/fonts/roboto/Roboto-Light.woff2 +0 -0
  86. data/app/assets/fonts/roboto/Roboto-Medium.woff +0 -0
  87. data/app/assets/fonts/roboto/Roboto-Medium.woff2 +0 -0
  88. data/app/assets/fonts/roboto/Roboto-Regular.woff +0 -0
  89. data/app/assets/fonts/roboto/Roboto-Regular.woff2 +0 -0
  90. data/app/assets/fonts/roboto/Roboto-Thin.woff +0 -0
  91. data/app/assets/fonts/roboto/Roboto-Thin.woff2 +0 -0
  92. data/app/assets/javascripts/materialize.js +0 -10021
  93. data/app/assets/javascripts/materialize/animation.js +0 -7
  94. data/app/assets/javascripts/materialize/buttons.js +0 -253
  95. data/app/assets/javascripts/materialize/cards.js +0 -28
  96. data/app/assets/javascripts/materialize/carousel.js +0 -543
  97. data/app/assets/javascripts/materialize/character_counter.js +0 -64
  98. data/app/assets/javascripts/materialize/chips.js +0 -315
  99. data/app/assets/javascripts/materialize/collapsible.js +0 -178
  100. data/app/assets/javascripts/materialize/date_picker/picker.date.js +0 -1399
  101. data/app/assets/javascripts/materialize/date_picker/picker.js +0 -1196
  102. data/app/assets/javascripts/materialize/date_picker/picker.time.js +0 -646
  103. data/app/assets/javascripts/materialize/dropdown.js +0 -257
  104. data/app/assets/javascripts/materialize/forms.js +0 -806
  105. data/app/assets/javascripts/materialize/global.js +0 -170
  106. data/app/assets/javascripts/materialize/hammer.min.js +0 -424
  107. data/app/assets/javascripts/materialize/initial.js +0 -10
  108. data/app/assets/javascripts/materialize/jquery.easing.1.4.js +0 -144
  109. data/app/assets/javascripts/materialize/jquery.hammer.js +0 -33
  110. data/app/assets/javascripts/materialize/materialbox.js +0 -263
  111. data/app/assets/javascripts/materialize/parallax.js +0 -54
  112. data/app/assets/javascripts/materialize/pushpin.js +0 -68
  113. data/app/assets/javascripts/materialize/scrollFire.js +0 -49
  114. data/app/assets/javascripts/materialize/scrollspy.js +0 -230
  115. data/app/assets/javascripts/materialize/sideNav.js +0 -395
  116. data/app/assets/javascripts/materialize/slider.js +0 -295
  117. data/app/assets/javascripts/materialize/tabs.js +0 -244
  118. data/app/assets/javascripts/materialize/tapTarget.js +0 -184
  119. data/app/assets/javascripts/materialize/tooltip.js +0 -227
  120. data/app/assets/javascripts/materialize/transitions.js +0 -163
  121. data/app/assets/javascripts/materialize/velocity.min.js +0 -626
  122. data/app/assets/stylesheets/materialize/components/_normalize.scss +0 -424
  123. data/app/assets/stylesheets/materialize/components/_roboto.scss +0 -39
  124. data/app/assets/stylesheets/materialize/components/date_picker/_default.date.scss +0 -469
  125. data/app/assets/stylesheets/materialize/components/date_picker/_default.scss +0 -216
  126. data/app/assets/stylesheets/materialize/components/date_picker/_default.time.scss +0 -267
@@ -1,626 +0,0 @@
1
- /*! VelocityJS.org (1.2.3). (C) 2014 Julian Shapiro. MIT @license: en.wikipedia.org/wiki/MIT_License */
2
- /*! VelocityJS.org jQuery Shim (1.0.1). (C) 2014 The jQuery Foundation. MIT @license: en.wikipedia.org/wiki/MIT_License. */
3
- /*! Note that this has been modified by Materialize to confirm that Velocity is not already being imported. */
4
- jQuery.Velocity ? console.log("Velocity is already loaded. You may be needlessly importing Velocity again; note that Materialize includes Velocity.") : (!function (e) {
5
- function t(e) {
6
- var t = e.length,
7
- a = r.type(e);return "function" === a || r.isWindow(e) ? !1 : 1 === e.nodeType && t ? !0 : "array" === a || 0 === t || "number" == typeof t && t > 0 && t - 1 in e;
8
- }if (!e.jQuery) {
9
- var r = function (e, t) {
10
- return new r.fn.init(e, t);
11
- };r.isWindow = function (e) {
12
- return null != e && e == e.window;
13
- }, r.type = function (e) {
14
- return null == e ? e + "" : "object" == typeof e || "function" == typeof e ? n[i.call(e)] || "object" : typeof e;
15
- }, r.isArray = Array.isArray || function (e) {
16
- return "array" === r.type(e);
17
- }, r.isPlainObject = function (e) {
18
- var t;if (!e || "object" !== r.type(e) || e.nodeType || r.isWindow(e)) return !1;try {
19
- if (e.constructor && !o.call(e, "constructor") && !o.call(e.constructor.prototype, "isPrototypeOf")) return !1;
20
- } catch (a) {
21
- return !1;
22
- }for (t in e) {}return void 0 === t || o.call(e, t);
23
- }, r.each = function (e, r, a) {
24
- var n,
25
- o = 0,
26
- i = e.length,
27
- s = t(e);if (a) {
28
- if (s) for (; i > o && (n = r.apply(e[o], a), n !== !1); o++) {} else for (o in e) {
29
- if (n = r.apply(e[o], a), n === !1) break;
30
- }
31
- } else if (s) for (; i > o && (n = r.call(e[o], o, e[o]), n !== !1); o++) {} else for (o in e) {
32
- if (n = r.call(e[o], o, e[o]), n === !1) break;
33
- }return e;
34
- }, r.data = function (e, t, n) {
35
- if (void 0 === n) {
36
- var o = e[r.expando],
37
- i = o && a[o];if (void 0 === t) return i;if (i && t in i) return i[t];
38
- } else if (void 0 !== t) {
39
- var o = e[r.expando] || (e[r.expando] = ++r.uuid);return a[o] = a[o] || {}, a[o][t] = n, n;
40
- }
41
- }, r.removeData = function (e, t) {
42
- var n = e[r.expando],
43
- o = n && a[n];o && r.each(t, function (e, t) {
44
- delete o[t];
45
- });
46
- }, r.extend = function () {
47
- var e,
48
- t,
49
- a,
50
- n,
51
- o,
52
- i,
53
- s = arguments[0] || {},
54
- l = 1,
55
- u = arguments.length,
56
- c = !1;for ("boolean" == typeof s && (c = s, s = arguments[l] || {}, l++), "object" != typeof s && "function" !== r.type(s) && (s = {}), l === u && (s = this, l--); u > l; l++) {
57
- if (null != (o = arguments[l])) for (n in o) {
58
- e = s[n], a = o[n], s !== a && (c && a && (r.isPlainObject(a) || (t = r.isArray(a))) ? (t ? (t = !1, i = e && r.isArray(e) ? e : []) : i = e && r.isPlainObject(e) ? e : {}, s[n] = r.extend(c, i, a)) : void 0 !== a && (s[n] = a));
59
- }
60
- }return s;
61
- }, r.queue = function (e, a, n) {
62
- function o(e, r) {
63
- var a = r || [];return null != e && (t(Object(e)) ? !function (e, t) {
64
- for (var r = +t.length, a = 0, n = e.length; r > a;) {
65
- e[n++] = t[a++];
66
- }if (r !== r) for (; void 0 !== t[a];) {
67
- e[n++] = t[a++];
68
- }return e.length = n, e;
69
- }(a, "string" == typeof e ? [e] : e) : [].push.call(a, e)), a;
70
- }if (e) {
71
- a = (a || "fx") + "queue";var i = r.data(e, a);return n ? (!i || r.isArray(n) ? i = r.data(e, a, o(n)) : i.push(n), i) : i || [];
72
- }
73
- }, r.dequeue = function (e, t) {
74
- r.each(e.nodeType ? [e] : e, function (e, a) {
75
- t = t || "fx";var n = r.queue(a, t),
76
- o = n.shift();"inprogress" === o && (o = n.shift()), o && ("fx" === t && n.unshift("inprogress"), o.call(a, function () {
77
- r.dequeue(a, t);
78
- }));
79
- });
80
- }, r.fn = r.prototype = { init: function (e) {
81
- if (e.nodeType) return this[0] = e, this;throw new Error("Not a DOM node.");
82
- }, offset: function () {
83
- var t = this[0].getBoundingClientRect ? this[0].getBoundingClientRect() : { top: 0, left: 0 };return { top: t.top + (e.pageYOffset || document.scrollTop || 0) - (document.clientTop || 0), left: t.left + (e.pageXOffset || document.scrollLeft || 0) - (document.clientLeft || 0) };
84
- }, position: function () {
85
- function e() {
86
- for (var e = this.offsetParent || document; e && "html" === !e.nodeType.toLowerCase && "static" === e.style.position;) {
87
- e = e.offsetParent;
88
- }return e || document;
89
- }var t = this[0],
90
- e = e.apply(t),
91
- a = this.offset(),
92
- n = /^(?:body|html)$/i.test(e.nodeName) ? { top: 0, left: 0 } : r(e).offset();return a.top -= parseFloat(t.style.marginTop) || 0, a.left -= parseFloat(t.style.marginLeft) || 0, e.style && (n.top += parseFloat(e.style.borderTopWidth) || 0, n.left += parseFloat(e.style.borderLeftWidth) || 0), { top: a.top - n.top, left: a.left - n.left };
93
- } };var a = {};r.expando = "velocity" + new Date().getTime(), r.uuid = 0;for (var n = {}, o = n.hasOwnProperty, i = n.toString, s = "Boolean Number String Function Array Date RegExp Object Error".split(" "), l = 0; l < s.length; l++) {
94
- n["[object " + s[l] + "]"] = s[l].toLowerCase();
95
- }r.fn.init.prototype = r.fn, e.Velocity = { Utilities: r };
96
- }
97
- }(window), function (e) {
98
- "object" == typeof module && "object" == typeof module.exports ? module.exports = e() : "function" == typeof define && define.amd ? define(e) : e();
99
- }(function () {
100
- return function (e, t, r, a) {
101
- function n(e) {
102
- for (var t = -1, r = e ? e.length : 0, a = []; ++t < r;) {
103
- var n = e[t];n && a.push(n);
104
- }return a;
105
- }function o(e) {
106
- return m.isWrapped(e) ? e = [].slice.call(e) : m.isNode(e) && (e = [e]), e;
107
- }function i(e) {
108
- var t = f.data(e, "velocity");return null === t ? a : t;
109
- }function s(e) {
110
- return function (t) {
111
- return Math.round(t * e) * (1 / e);
112
- };
113
- }function l(e, r, a, n) {
114
- function o(e, t) {
115
- return 1 - 3 * t + 3 * e;
116
- }function i(e, t) {
117
- return 3 * t - 6 * e;
118
- }function s(e) {
119
- return 3 * e;
120
- }function l(e, t, r) {
121
- return ((o(t, r) * e + i(t, r)) * e + s(t)) * e;
122
- }function u(e, t, r) {
123
- return 3 * o(t, r) * e * e + 2 * i(t, r) * e + s(t);
124
- }function c(t, r) {
125
- for (var n = 0; m > n; ++n) {
126
- var o = u(r, e, a);if (0 === o) return r;var i = l(r, e, a) - t;r -= i / o;
127
- }return r;
128
- }function p() {
129
- for (var t = 0; b > t; ++t) {
130
- w[t] = l(t * x, e, a);
131
- }
132
- }function f(t, r, n) {
133
- var o,
134
- i,
135
- s = 0;do {
136
- i = r + (n - r) / 2, o = l(i, e, a) - t, o > 0 ? n = i : r = i;
137
- } while (Math.abs(o) > h && ++s < v);return i;
138
- }function d(t) {
139
- for (var r = 0, n = 1, o = b - 1; n != o && w[n] <= t; ++n) {
140
- r += x;
141
- }--n;var i = (t - w[n]) / (w[n + 1] - w[n]),
142
- s = r + i * x,
143
- l = u(s, e, a);return l >= y ? c(t, s) : 0 == l ? s : f(t, r, r + x);
144
- }function g() {
145
- V = !0, (e != r || a != n) && p();
146
- }var m = 4,
147
- y = .001,
148
- h = 1e-7,
149
- v = 10,
150
- b = 11,
151
- x = 1 / (b - 1),
152
- S = "Float32Array" in t;if (4 !== arguments.length) return !1;for (var P = 0; 4 > P; ++P) {
153
- if ("number" != typeof arguments[P] || isNaN(arguments[P]) || !isFinite(arguments[P])) return !1;
154
- }e = Math.min(e, 1), a = Math.min(a, 1), e = Math.max(e, 0), a = Math.max(a, 0);var w = S ? new Float32Array(b) : new Array(b),
155
- V = !1,
156
- C = function (t) {
157
- return V || g(), e === r && a === n ? t : 0 === t ? 0 : 1 === t ? 1 : l(d(t), r, n);
158
- };C.getControlPoints = function () {
159
- return [{ x: e, y: r }, { x: a, y: n }];
160
- };var T = "generateBezier(" + [e, r, a, n] + ")";return C.toString = function () {
161
- return T;
162
- }, C;
163
- }function u(e, t) {
164
- var r = e;return m.isString(e) ? b.Easings[e] || (r = !1) : r = m.isArray(e) && 1 === e.length ? s.apply(null, e) : m.isArray(e) && 2 === e.length ? x.apply(null, e.concat([t])) : m.isArray(e) && 4 === e.length ? l.apply(null, e) : !1, r === !1 && (r = b.Easings[b.defaults.easing] ? b.defaults.easing : v), r;
165
- }function c(e) {
166
- if (e) {
167
- var t = new Date().getTime(),
168
- r = b.State.calls.length;r > 1e4 && (b.State.calls = n(b.State.calls));for (var o = 0; r > o; o++) {
169
- if (b.State.calls[o]) {
170
- var s = b.State.calls[o],
171
- l = s[0],
172
- u = s[2],
173
- d = s[3],
174
- g = !!d,
175
- y = null;d || (d = b.State.calls[o][3] = t - 16);for (var h = Math.min((t - d) / u.duration, 1), v = 0, x = l.length; x > v; v++) {
176
- var P = l[v],
177
- V = P.element;if (i(V)) {
178
- var C = !1;if (u.display !== a && null !== u.display && "none" !== u.display) {
179
- if ("flex" === u.display) {
180
- var T = ["-webkit-box", "-moz-box", "-ms-flexbox", "-webkit-flex"];f.each(T, function (e, t) {
181
- S.setPropertyValue(V, "display", t);
182
- });
183
- }S.setPropertyValue(V, "display", u.display);
184
- }u.visibility !== a && "hidden" !== u.visibility && S.setPropertyValue(V, "visibility", u.visibility);for (var k in P) {
185
- if ("element" !== k) {
186
- var A,
187
- F = P[k],
188
- j = m.isString(F.easing) ? b.Easings[F.easing] : F.easing;if (1 === h) A = F.endValue;else {
189
- var E = F.endValue - F.startValue;if (A = F.startValue + E * j(h, u, E), !g && A === F.currentValue) continue;
190
- }if (F.currentValue = A, "tween" === k) y = A;else {
191
- if (S.Hooks.registered[k]) {
192
- var H = S.Hooks.getRoot(k),
193
- N = i(V).rootPropertyValueCache[H];N && (F.rootPropertyValue = N);
194
- }var L = S.setPropertyValue(V, k, F.currentValue + (0 === parseFloat(A) ? "" : F.unitType), F.rootPropertyValue, F.scrollData);S.Hooks.registered[k] && (i(V).rootPropertyValueCache[H] = S.Normalizations.registered[H] ? S.Normalizations.registered[H]("extract", null, L[1]) : L[1]), "transform" === L[0] && (C = !0);
195
- }
196
- }
197
- }u.mobileHA && i(V).transformCache.translate3d === a && (i(V).transformCache.translate3d = "(0px, 0px, 0px)", C = !0), C && S.flushTransformCache(V);
198
- }
199
- }u.display !== a && "none" !== u.display && (b.State.calls[o][2].display = !1), u.visibility !== a && "hidden" !== u.visibility && (b.State.calls[o][2].visibility = !1), u.progress && u.progress.call(s[1], s[1], h, Math.max(0, d + u.duration - t), d, y), 1 === h && p(o);
200
- }
201
- }
202
- }b.State.isTicking && w(c);
203
- }function p(e, t) {
204
- if (!b.State.calls[e]) return !1;for (var r = b.State.calls[e][0], n = b.State.calls[e][1], o = b.State.calls[e][2], s = b.State.calls[e][4], l = !1, u = 0, c = r.length; c > u; u++) {
205
- var p = r[u].element;if (t || o.loop || ("none" === o.display && S.setPropertyValue(p, "display", o.display), "hidden" === o.visibility && S.setPropertyValue(p, "visibility", o.visibility)), o.loop !== !0 && (f.queue(p)[1] === a || !/\.velocityQueueEntryFlag/i.test(f.queue(p)[1])) && i(p)) {
206
- i(p).isAnimating = !1, i(p).rootPropertyValueCache = {};var d = !1;f.each(S.Lists.transforms3D, function (e, t) {
207
- var r = /^scale/.test(t) ? 1 : 0,
208
- n = i(p).transformCache[t];i(p).transformCache[t] !== a && new RegExp("^\\(" + r + "[^.]").test(n) && (d = !0, delete i(p).transformCache[t]);
209
- }), o.mobileHA && (d = !0, delete i(p).transformCache.translate3d), d && S.flushTransformCache(p), S.Values.removeClass(p, "velocity-animating");
210
- }if (!t && o.complete && !o.loop && u === c - 1) try {
211
- o.complete.call(n, n);
212
- } catch (g) {
213
- setTimeout(function () {
214
- throw g;
215
- }, 1);
216
- }s && o.loop !== !0 && s(n), i(p) && o.loop === !0 && !t && (f.each(i(p).tweensContainer, function (e, t) {
217
- /^rotate/.test(e) && 360 === parseFloat(t.endValue) && (t.endValue = 0, t.startValue = 360), /^backgroundPosition/.test(e) && 100 === parseFloat(t.endValue) && "%" === t.unitType && (t.endValue = 0, t.startValue = 100);
218
- }), b(p, "reverse", { loop: !0, delay: o.delay })), o.queue !== !1 && f.dequeue(p, o.queue);
219
- }b.State.calls[e] = !1;for (var m = 0, y = b.State.calls.length; y > m; m++) {
220
- if (b.State.calls[m] !== !1) {
221
- l = !0;break;
222
- }
223
- }l === !1 && (b.State.isTicking = !1, delete b.State.calls, b.State.calls = []);
224
- }var f,
225
- d = function () {
226
- if (r.documentMode) return r.documentMode;for (var e = 7; e > 4; e--) {
227
- var t = r.createElement("div");if (t.innerHTML = "<!--[if IE " + e + "]><span></span><![endif]-->", t.getElementsByTagName("span").length) return t = null, e;
228
- }return a;
229
- }(),
230
- g = function () {
231
- var e = 0;return t.webkitRequestAnimationFrame || t.mozRequestAnimationFrame || function (t) {
232
- var r,
233
- a = new Date().getTime();return r = Math.max(0, 16 - (a - e)), e = a + r, setTimeout(function () {
234
- t(a + r);
235
- }, r);
236
- };
237
- }(),
238
- m = { isString: function (e) {
239
- return "string" == typeof e;
240
- }, isArray: Array.isArray || function (e) {
241
- return "[object Array]" === Object.prototype.toString.call(e);
242
- }, isFunction: function (e) {
243
- return "[object Function]" === Object.prototype.toString.call(e);
244
- }, isNode: function (e) {
245
- return e && e.nodeType;
246
- }, isNodeList: function (e) {
247
- return "object" == typeof e && /^\[object (HTMLCollection|NodeList|Object)\]$/.test(Object.prototype.toString.call(e)) && e.length !== a && (0 === e.length || "object" == typeof e[0] && e[0].nodeType > 0);
248
- }, isWrapped: function (e) {
249
- return e && (e.jquery || t.Zepto && t.Zepto.zepto.isZ(e));
250
- }, isSVG: function (e) {
251
- return t.SVGElement && e instanceof t.SVGElement;
252
- }, isEmptyObject: function (e) {
253
- for (var t in e) {
254
- return !1;
255
- }return !0;
256
- } },
257
- y = !1;if (e.fn && e.fn.jquery ? (f = e, y = !0) : f = t.Velocity.Utilities, 8 >= d && !y) throw new Error("Velocity: IE8 and below require jQuery to be loaded before Velocity.");if (7 >= d) return void (jQuery.fn.velocity = jQuery.fn.animate);var h = 400,
258
- v = "swing",
259
- b = { State: { isMobile: /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent), isAndroid: /Android/i.test(navigator.userAgent), isGingerbread: /Android 2\.3\.[3-7]/i.test(navigator.userAgent), isChrome: t.chrome, isFirefox: /Firefox/i.test(navigator.userAgent), prefixElement: r.createElement("div"), prefixMatches: {}, scrollAnchor: null, scrollPropertyLeft: null, scrollPropertyTop: null, isTicking: !1, calls: [] }, CSS: {}, Utilities: f, Redirects: {}, Easings: {}, Promise: t.Promise, defaults: { queue: "", duration: h, easing: v, begin: a, complete: a, progress: a, display: a, visibility: a, loop: !1, delay: !1, mobileHA: !0, _cacheValues: !0 }, init: function (e) {
260
- f.data(e, "velocity", { isSVG: m.isSVG(e), isAnimating: !1, computedStyle: null, tweensContainer: null, rootPropertyValueCache: {}, transformCache: {} });
261
- }, hook: null, mock: !1, version: { major: 1, minor: 2, patch: 2 }, debug: !1 };t.pageYOffset !== a ? (b.State.scrollAnchor = t, b.State.scrollPropertyLeft = "pageXOffset", b.State.scrollPropertyTop = "pageYOffset") : (b.State.scrollAnchor = r.documentElement || r.body.parentNode || r.body, b.State.scrollPropertyLeft = "scrollLeft", b.State.scrollPropertyTop = "scrollTop");var x = function () {
262
- function e(e) {
263
- return -e.tension * e.x - e.friction * e.v;
264
- }function t(t, r, a) {
265
- var n = { x: t.x + a.dx * r, v: t.v + a.dv * r, tension: t.tension, friction: t.friction };return { dx: n.v, dv: e(n) };
266
- }function r(r, a) {
267
- var n = { dx: r.v, dv: e(r) },
268
- o = t(r, .5 * a, n),
269
- i = t(r, .5 * a, o),
270
- s = t(r, a, i),
271
- l = 1 / 6 * (n.dx + 2 * (o.dx + i.dx) + s.dx),
272
- u = 1 / 6 * (n.dv + 2 * (o.dv + i.dv) + s.dv);return r.x = r.x + l * a, r.v = r.v + u * a, r;
273
- }return function a(e, t, n) {
274
- var o,
275
- i,
276
- s,
277
- l = { x: -1, v: 0, tension: null, friction: null },
278
- u = [0],
279
- c = 0,
280
- p = 1e-4,
281
- f = .016;for (e = parseFloat(e) || 500, t = parseFloat(t) || 20, n = n || null, l.tension = e, l.friction = t, o = null !== n, o ? (c = a(e, t), i = c / n * f) : i = f; s = r(s || l, i), u.push(1 + s.x), c += 16, Math.abs(s.x) > p && Math.abs(s.v) > p;) {}return o ? function (e) {
282
- return u[e * (u.length - 1) | 0];
283
- } : c;
284
- };
285
- }();b.Easings = { linear: function (e) {
286
- return e;
287
- }, swing: function (e) {
288
- return .5 - Math.cos(e * Math.PI) / 2;
289
- }, spring: function (e) {
290
- return 1 - Math.cos(4.5 * e * Math.PI) * Math.exp(6 * -e);
291
- } }, f.each([["ease", [.25, .1, .25, 1]], ["ease-in", [.42, 0, 1, 1]], ["ease-out", [0, 0, .58, 1]], ["ease-in-out", [.42, 0, .58, 1]], ["easeInSine", [.47, 0, .745, .715]], ["easeOutSine", [.39, .575, .565, 1]], ["easeInOutSine", [.445, .05, .55, .95]], ["easeInQuad", [.55, .085, .68, .53]], ["easeOutQuad", [.25, .46, .45, .94]], ["easeInOutQuad", [.455, .03, .515, .955]], ["easeInCubic", [.55, .055, .675, .19]], ["easeOutCubic", [.215, .61, .355, 1]], ["easeInOutCubic", [.645, .045, .355, 1]], ["easeInQuart", [.895, .03, .685, .22]], ["easeOutQuart", [.165, .84, .44, 1]], ["easeInOutQuart", [.77, 0, .175, 1]], ["easeInQuint", [.755, .05, .855, .06]], ["easeOutQuint", [.23, 1, .32, 1]], ["easeInOutQuint", [.86, 0, .07, 1]], ["easeInExpo", [.95, .05, .795, .035]], ["easeOutExpo", [.19, 1, .22, 1]], ["easeInOutExpo", [1, 0, 0, 1]], ["easeInCirc", [.6, .04, .98, .335]], ["easeOutCirc", [.075, .82, .165, 1]], ["easeInOutCirc", [.785, .135, .15, .86]]], function (e, t) {
292
- b.Easings[t[0]] = l.apply(null, t[1]);
293
- });var S = b.CSS = { RegEx: { isHex: /^#([A-f\d]{3}){1,2}$/i, valueUnwrap: /^[A-z]+\((.*)\)$/i, wrappedValueAlreadyExtracted: /[0-9.]+ [0-9.]+ [0-9.]+( [0-9.]+)?/, valueSplit: /([A-z]+\(.+\))|(([A-z0-9#-.]+?)(?=\s|$))/gi }, Lists: { colors: ["fill", "stroke", "stopColor", "color", "backgroundColor", "borderColor", "borderTopColor", "borderRightColor", "borderBottomColor", "borderLeftColor", "outlineColor"], transformsBase: ["translateX", "translateY", "scale", "scaleX", "scaleY", "skewX", "skewY", "rotateZ"], transforms3D: ["transformPerspective", "translateZ", "scaleZ", "rotateX", "rotateY"] }, Hooks: { templates: { textShadow: ["Color X Y Blur", "black 0px 0px 0px"], boxShadow: ["Color X Y Blur Spread", "black 0px 0px 0px 0px"], clip: ["Top Right Bottom Left", "0px 0px 0px 0px"], backgroundPosition: ["X Y", "0% 0%"], transformOrigin: ["X Y Z", "50% 50% 0px"], perspectiveOrigin: ["X Y", "50% 50%"] }, registered: {}, register: function () {
294
- for (var e = 0; e < S.Lists.colors.length; e++) {
295
- var t = "color" === S.Lists.colors[e] ? "0 0 0 1" : "255 255 255 1";S.Hooks.templates[S.Lists.colors[e]] = ["Red Green Blue Alpha", t];
296
- }var r, a, n;if (d) for (r in S.Hooks.templates) {
297
- a = S.Hooks.templates[r], n = a[0].split(" ");var o = a[1].match(S.RegEx.valueSplit);"Color" === n[0] && (n.push(n.shift()), o.push(o.shift()), S.Hooks.templates[r] = [n.join(" "), o.join(" ")]);
298
- }for (r in S.Hooks.templates) {
299
- a = S.Hooks.templates[r], n = a[0].split(" ");for (var e in n) {
300
- var i = r + n[e],
301
- s = e;S.Hooks.registered[i] = [r, s];
302
- }
303
- }
304
- }, getRoot: function (e) {
305
- var t = S.Hooks.registered[e];return t ? t[0] : e;
306
- }, cleanRootPropertyValue: function (e, t) {
307
- return S.RegEx.valueUnwrap.test(t) && (t = t.match(S.RegEx.valueUnwrap)[1]), S.Values.isCSSNullValue(t) && (t = S.Hooks.templates[e][1]), t;
308
- }, extractValue: function (e, t) {
309
- var r = S.Hooks.registered[e];if (r) {
310
- var a = r[0],
311
- n = r[1];return t = S.Hooks.cleanRootPropertyValue(a, t), t.toString().match(S.RegEx.valueSplit)[n];
312
- }return t;
313
- }, injectValue: function (e, t, r) {
314
- var a = S.Hooks.registered[e];if (a) {
315
- var n,
316
- o,
317
- i = a[0],
318
- s = a[1];return r = S.Hooks.cleanRootPropertyValue(i, r), n = r.toString().match(S.RegEx.valueSplit), n[s] = t, o = n.join(" ");
319
- }return r;
320
- } }, Normalizations: { registered: { clip: function (e, t, r) {
321
- switch (e) {case "name":
322
- return "clip";case "extract":
323
- var a;return S.RegEx.wrappedValueAlreadyExtracted.test(r) ? a = r : (a = r.toString().match(S.RegEx.valueUnwrap), a = a ? a[1].replace(/,(\s+)?/g, " ") : r), a;case "inject":
324
- return "rect(" + r + ")";}
325
- }, blur: function (e, t, r) {
326
- switch (e) {case "name":
327
- return b.State.isFirefox ? "filter" : "-webkit-filter";case "extract":
328
- var a = parseFloat(r);if (!a && 0 !== a) {
329
- var n = r.toString().match(/blur\(([0-9]+[A-z]+)\)/i);a = n ? n[1] : 0;
330
- }return a;case "inject":
331
- return parseFloat(r) ? "blur(" + r + ")" : "none";}
332
- }, opacity: function (e, t, r) {
333
- if (8 >= d) switch (e) {case "name":
334
- return "filter";case "extract":
335
- var a = r.toString().match(/alpha\(opacity=(.*)\)/i);return r = a ? a[1] / 100 : 1;case "inject":
336
- return t.style.zoom = 1, parseFloat(r) >= 1 ? "" : "alpha(opacity=" + parseInt(100 * parseFloat(r), 10) + ")";} else switch (e) {case "name":
337
- return "opacity";case "extract":
338
- return r;case "inject":
339
- return r;}
340
- } }, register: function () {
341
- 9 >= d || b.State.isGingerbread || (S.Lists.transformsBase = S.Lists.transformsBase.concat(S.Lists.transforms3D));for (var e = 0; e < S.Lists.transformsBase.length; e++) {
342
- !function () {
343
- var t = S.Lists.transformsBase[e];S.Normalizations.registered[t] = function (e, r, n) {
344
- switch (e) {case "name":
345
- return "transform";case "extract":
346
- return i(r) === a || i(r).transformCache[t] === a ? /^scale/i.test(t) ? 1 : 0 : i(r).transformCache[t].replace(/[()]/g, "");case "inject":
347
- var o = !1;switch (t.substr(0, t.length - 1)) {case "translate":
348
- o = !/(%|px|em|rem|vw|vh|\d)$/i.test(n);break;case "scal":case "scale":
349
- b.State.isAndroid && i(r).transformCache[t] === a && 1 > n && (n = 1), o = !/(\d)$/i.test(n);break;case "skew":
350
- o = !/(deg|\d)$/i.test(n);break;case "rotate":
351
- o = !/(deg|\d)$/i.test(n);}return o || (i(r).transformCache[t] = "(" + n + ")"), i(r).transformCache[t];}
352
- };
353
- }();
354
- }for (var e = 0; e < S.Lists.colors.length; e++) {
355
- !function () {
356
- var t = S.Lists.colors[e];S.Normalizations.registered[t] = function (e, r, n) {
357
- switch (e) {case "name":
358
- return t;case "extract":
359
- var o;if (S.RegEx.wrappedValueAlreadyExtracted.test(n)) o = n;else {
360
- var i,
361
- s = { black: "rgb(0, 0, 0)", blue: "rgb(0, 0, 255)", gray: "rgb(128, 128, 128)", green: "rgb(0, 128, 0)", red: "rgb(255, 0, 0)", white: "rgb(255, 255, 255)" };/^[A-z]+$/i.test(n) ? i = s[n] !== a ? s[n] : s.black : S.RegEx.isHex.test(n) ? i = "rgb(" + S.Values.hexToRgb(n).join(" ") + ")" : /^rgba?\(/i.test(n) || (i = s.black), o = (i || n).toString().match(S.RegEx.valueUnwrap)[1].replace(/,(\s+)?/g, " ");
362
- }return 8 >= d || 3 !== o.split(" ").length || (o += " 1"), o;case "inject":
363
- return 8 >= d ? 4 === n.split(" ").length && (n = n.split(/\s+/).slice(0, 3).join(" ")) : 3 === n.split(" ").length && (n += " 1"), (8 >= d ? "rgb" : "rgba") + "(" + n.replace(/\s+/g, ",").replace(/\.(\d)+(?=,)/g, "") + ")";}
364
- };
365
- }();
366
- }
367
- } }, Names: { camelCase: function (e) {
368
- return e.replace(/-(\w)/g, function (e, t) {
369
- return t.toUpperCase();
370
- });
371
- }, SVGAttribute: function (e) {
372
- var t = "width|height|x|y|cx|cy|r|rx|ry|x1|x2|y1|y2";return (d || b.State.isAndroid && !b.State.isChrome) && (t += "|transform"), new RegExp("^(" + t + ")$", "i").test(e);
373
- }, prefixCheck: function (e) {
374
- if (b.State.prefixMatches[e]) return [b.State.prefixMatches[e], !0];for (var t = ["", "Webkit", "Moz", "ms", "O"], r = 0, a = t.length; a > r; r++) {
375
- var n;if (n = 0 === r ? e : t[r] + e.replace(/^\w/, function (e) {
376
- return e.toUpperCase();
377
- }), m.isString(b.State.prefixElement.style[n])) return b.State.prefixMatches[e] = n, [n, !0];
378
- }return [e, !1];
379
- } }, Values: { hexToRgb: function (e) {
380
- var t,
381
- r = /^#?([a-f\d])([a-f\d])([a-f\d])$/i,
382
- a = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i;return e = e.replace(r, function (e, t, r, a) {
383
- return t + t + r + r + a + a;
384
- }), t = a.exec(e), t ? [parseInt(t[1], 16), parseInt(t[2], 16), parseInt(t[3], 16)] : [0, 0, 0];
385
- }, isCSSNullValue: function (e) {
386
- return 0 == e || /^(none|auto|transparent|(rgba\(0, ?0, ?0, ?0\)))$/i.test(e);
387
- }, getUnitType: function (e) {
388
- return (/^(rotate|skew)/i.test(e) ? "deg" : /(^(scale|scaleX|scaleY|scaleZ|alpha|flexGrow|flexHeight|zIndex|fontWeight)$)|((opacity|red|green|blue|alpha)$)/i.test(e) ? "" : "px"
389
- );
390
- }, getDisplayType: function (e) {
391
- var t = e && e.tagName.toString().toLowerCase();return (/^(b|big|i|small|tt|abbr|acronym|cite|code|dfn|em|kbd|strong|samp|var|a|bdo|br|img|map|object|q|script|span|sub|sup|button|input|label|select|textarea)$/i.test(t) ? "inline" : /^(li)$/i.test(t) ? "list-item" : /^(tr)$/i.test(t) ? "table-row" : /^(table)$/i.test(t) ? "table" : /^(tbody)$/i.test(t) ? "table-row-group" : "block"
392
- );
393
- }, addClass: function (e, t) {
394
- e.classList ? e.classList.add(t) : e.className += (e.className.length ? " " : "") + t;
395
- }, removeClass: function (e, t) {
396
- e.classList ? e.classList.remove(t) : e.className = e.className.toString().replace(new RegExp("(^|\\s)" + t.split(" ").join("|") + "(\\s|$)", "gi"), " ");
397
- } }, getPropertyValue: function (e, r, n, o) {
398
- function s(e, r) {
399
- function n() {
400
- u && S.setPropertyValue(e, "display", "none");
401
- }var l = 0;if (8 >= d) l = f.css(e, r);else {
402
- var u = !1;if (/^(width|height)$/.test(r) && 0 === S.getPropertyValue(e, "display") && (u = !0, S.setPropertyValue(e, "display", S.Values.getDisplayType(e))), !o) {
403
- if ("height" === r && "border-box" !== S.getPropertyValue(e, "boxSizing").toString().toLowerCase()) {
404
- var c = e.offsetHeight - (parseFloat(S.getPropertyValue(e, "borderTopWidth")) || 0) - (parseFloat(S.getPropertyValue(e, "borderBottomWidth")) || 0) - (parseFloat(S.getPropertyValue(e, "paddingTop")) || 0) - (parseFloat(S.getPropertyValue(e, "paddingBottom")) || 0);return n(), c;
405
- }if ("width" === r && "border-box" !== S.getPropertyValue(e, "boxSizing").toString().toLowerCase()) {
406
- var p = e.offsetWidth - (parseFloat(S.getPropertyValue(e, "borderLeftWidth")) || 0) - (parseFloat(S.getPropertyValue(e, "borderRightWidth")) || 0) - (parseFloat(S.getPropertyValue(e, "paddingLeft")) || 0) - (parseFloat(S.getPropertyValue(e, "paddingRight")) || 0);return n(), p;
407
- }
408
- }var g;g = i(e) === a ? t.getComputedStyle(e, null) : i(e).computedStyle ? i(e).computedStyle : i(e).computedStyle = t.getComputedStyle(e, null), "borderColor" === r && (r = "borderTopColor"), l = 9 === d && "filter" === r ? g.getPropertyValue(r) : g[r], ("" === l || null === l) && (l = e.style[r]), n();
409
- }if ("auto" === l && /^(top|right|bottom|left)$/i.test(r)) {
410
- var m = s(e, "position");("fixed" === m || "absolute" === m && /top|left/i.test(r)) && (l = f(e).position()[r] + "px");
411
- }return l;
412
- }var l;if (S.Hooks.registered[r]) {
413
- var u = r,
414
- c = S.Hooks.getRoot(u);n === a && (n = S.getPropertyValue(e, S.Names.prefixCheck(c)[0])), S.Normalizations.registered[c] && (n = S.Normalizations.registered[c]("extract", e, n)), l = S.Hooks.extractValue(u, n);
415
- } else if (S.Normalizations.registered[r]) {
416
- var p, g;p = S.Normalizations.registered[r]("name", e), "transform" !== p && (g = s(e, S.Names.prefixCheck(p)[0]), S.Values.isCSSNullValue(g) && S.Hooks.templates[r] && (g = S.Hooks.templates[r][1])), l = S.Normalizations.registered[r]("extract", e, g);
417
- }if (!/^[\d-]/.test(l)) if (i(e) && i(e).isSVG && S.Names.SVGAttribute(r)) {
418
- if (/^(height|width)$/i.test(r)) try {
419
- l = e.getBBox()[r];
420
- } catch (m) {
421
- l = 0;
422
- } else l = e.getAttribute(r);
423
- } else l = s(e, S.Names.prefixCheck(r)[0]);return S.Values.isCSSNullValue(l) && (l = 0), b.debug >= 2 && console.log("Get " + r + ": " + l), l;
424
- }, setPropertyValue: function (e, r, a, n, o) {
425
- var s = r;if ("scroll" === r) o.container ? o.container["scroll" + o.direction] = a : "Left" === o.direction ? t.scrollTo(a, o.alternateValue) : t.scrollTo(o.alternateValue, a);else if (S.Normalizations.registered[r] && "transform" === S.Normalizations.registered[r]("name", e)) S.Normalizations.registered[r]("inject", e, a), s = "transform", a = i(e).transformCache[r];else {
426
- if (S.Hooks.registered[r]) {
427
- var l = r,
428
- u = S.Hooks.getRoot(r);n = n || S.getPropertyValue(e, u), a = S.Hooks.injectValue(l, a, n), r = u;
429
- }if (S.Normalizations.registered[r] && (a = S.Normalizations.registered[r]("inject", e, a), r = S.Normalizations.registered[r]("name", e)), s = S.Names.prefixCheck(r)[0], 8 >= d) try {
430
- e.style[s] = a;
431
- } catch (c) {
432
- b.debug && console.log("Browser does not support [" + a + "] for [" + s + "]");
433
- } else i(e) && i(e).isSVG && S.Names.SVGAttribute(r) ? e.setAttribute(r, a) : e.style[s] = a;b.debug >= 2 && console.log("Set " + r + " (" + s + "): " + a);
434
- }return [s, a];
435
- }, flushTransformCache: function (e) {
436
- function t(t) {
437
- return parseFloat(S.getPropertyValue(e, t));
438
- }var r = "";if ((d || b.State.isAndroid && !b.State.isChrome) && i(e).isSVG) {
439
- var a = { translate: [t("translateX"), t("translateY")], skewX: [t("skewX")], skewY: [t("skewY")], scale: 1 !== t("scale") ? [t("scale"), t("scale")] : [t("scaleX"), t("scaleY")], rotate: [t("rotateZ"), 0, 0] };f.each(i(e).transformCache, function (e) {
440
- /^translate/i.test(e) ? e = "translate" : /^scale/i.test(e) ? e = "scale" : /^rotate/i.test(e) && (e = "rotate"), a[e] && (r += e + "(" + a[e].join(" ") + ") ", delete a[e]);
441
- });
442
- } else {
443
- var n, o;f.each(i(e).transformCache, function (t) {
444
- return n = i(e).transformCache[t], "transformPerspective" === t ? (o = n, !0) : (9 === d && "rotateZ" === t && (t = "rotate"), void (r += t + n + " "));
445
- }), o && (r = "perspective" + o + " " + r);
446
- }S.setPropertyValue(e, "transform", r);
447
- } };S.Hooks.register(), S.Normalizations.register(), b.hook = function (e, t, r) {
448
- var n = a;return e = o(e), f.each(e, function (e, o) {
449
- if (i(o) === a && b.init(o), r === a) n === a && (n = b.CSS.getPropertyValue(o, t));else {
450
- var s = b.CSS.setPropertyValue(o, t, r);"transform" === s[0] && b.CSS.flushTransformCache(o), n = s;
451
- }
452
- }), n;
453
- };var P = function () {
454
- function e() {
455
- return s ? k.promise || null : l;
456
- }function n() {
457
- function e(e) {
458
- function p(e, t) {
459
- var r = a,
460
- n = a,
461
- i = a;return m.isArray(e) ? (r = e[0], !m.isArray(e[1]) && /^[\d-]/.test(e[1]) || m.isFunction(e[1]) || S.RegEx.isHex.test(e[1]) ? i = e[1] : (m.isString(e[1]) && !S.RegEx.isHex.test(e[1]) || m.isArray(e[1])) && (n = t ? e[1] : u(e[1], s.duration), e[2] !== a && (i = e[2]))) : r = e, t || (n = n || s.easing), m.isFunction(r) && (r = r.call(o, V, w)), m.isFunction(i) && (i = i.call(o, V, w)), [r || 0, n, i];
462
- }function d(e, t) {
463
- var r, a;return a = (t || "0").toString().toLowerCase().replace(/[%A-z]+$/, function (e) {
464
- return r = e, "";
465
- }), r || (r = S.Values.getUnitType(e)), [a, r];
466
- }function h() {
467
- var e = { myParent: o.parentNode || r.body, position: S.getPropertyValue(o, "position"), fontSize: S.getPropertyValue(o, "fontSize") },
468
- a = e.position === L.lastPosition && e.myParent === L.lastParent,
469
- n = e.fontSize === L.lastFontSize;L.lastParent = e.myParent, L.lastPosition = e.position, L.lastFontSize = e.fontSize;var s = 100,
470
- l = {};if (n && a) l.emToPx = L.lastEmToPx, l.percentToPxWidth = L.lastPercentToPxWidth, l.percentToPxHeight = L.lastPercentToPxHeight;else {
471
- var u = i(o).isSVG ? r.createElementNS("http://www.w3.org/2000/svg", "rect") : r.createElement("div");b.init(u), e.myParent.appendChild(u), f.each(["overflow", "overflowX", "overflowY"], function (e, t) {
472
- b.CSS.setPropertyValue(u, t, "hidden");
473
- }), b.CSS.setPropertyValue(u, "position", e.position), b.CSS.setPropertyValue(u, "fontSize", e.fontSize), b.CSS.setPropertyValue(u, "boxSizing", "content-box"), f.each(["minWidth", "maxWidth", "width", "minHeight", "maxHeight", "height"], function (e, t) {
474
- b.CSS.setPropertyValue(u, t, s + "%");
475
- }), b.CSS.setPropertyValue(u, "paddingLeft", s + "em"), l.percentToPxWidth = L.lastPercentToPxWidth = (parseFloat(S.getPropertyValue(u, "width", null, !0)) || 1) / s, l.percentToPxHeight = L.lastPercentToPxHeight = (parseFloat(S.getPropertyValue(u, "height", null, !0)) || 1) / s, l.emToPx = L.lastEmToPx = (parseFloat(S.getPropertyValue(u, "paddingLeft")) || 1) / s, e.myParent.removeChild(u);
476
- }return null === L.remToPx && (L.remToPx = parseFloat(S.getPropertyValue(r.body, "fontSize")) || 16), null === L.vwToPx && (L.vwToPx = parseFloat(t.innerWidth) / 100, L.vhToPx = parseFloat(t.innerHeight) / 100), l.remToPx = L.remToPx, l.vwToPx = L.vwToPx, l.vhToPx = L.vhToPx, b.debug >= 1 && console.log("Unit ratios: " + JSON.stringify(l), o), l;
477
- }if (s.begin && 0 === V) try {
478
- s.begin.call(g, g);
479
- } catch (x) {
480
- setTimeout(function () {
481
- throw x;
482
- }, 1);
483
- }if ("scroll" === A) {
484
- var P,
485
- C,
486
- T,
487
- F = /^x$/i.test(s.axis) ? "Left" : "Top",
488
- j = parseFloat(s.offset) || 0;s.container ? m.isWrapped(s.container) || m.isNode(s.container) ? (s.container = s.container[0] || s.container, P = s.container["scroll" + F], T = P + f(o).position()[F.toLowerCase()] + j) : s.container = null : (P = b.State.scrollAnchor[b.State["scrollProperty" + F]], C = b.State.scrollAnchor[b.State["scrollProperty" + ("Left" === F ? "Top" : "Left")]], T = f(o).offset()[F.toLowerCase()] + j), l = { scroll: { rootPropertyValue: !1, startValue: P, currentValue: P, endValue: T, unitType: "", easing: s.easing, scrollData: { container: s.container, direction: F, alternateValue: C } }, element: o }, b.debug && console.log("tweensContainer (scroll): ", l.scroll, o);
489
- } else if ("reverse" === A) {
490
- if (!i(o).tweensContainer) return void f.dequeue(o, s.queue);"none" === i(o).opts.display && (i(o).opts.display = "auto"), "hidden" === i(o).opts.visibility && (i(o).opts.visibility = "visible"), i(o).opts.loop = !1, i(o).opts.begin = null, i(o).opts.complete = null, v.easing || delete s.easing, v.duration || delete s.duration, s = f.extend({}, i(o).opts, s);var E = f.extend(!0, {}, i(o).tweensContainer);for (var H in E) {
491
- if ("element" !== H) {
492
- var N = E[H].startValue;E[H].startValue = E[H].currentValue = E[H].endValue, E[H].endValue = N, m.isEmptyObject(v) || (E[H].easing = s.easing), b.debug && console.log("reverse tweensContainer (" + H + "): " + JSON.stringify(E[H]), o);
493
- }
494
- }l = E;
495
- } else if ("start" === A) {
496
- var E;i(o).tweensContainer && i(o).isAnimating === !0 && (E = i(o).tweensContainer), f.each(y, function (e, t) {
497
- if (RegExp("^" + S.Lists.colors.join("$|^") + "$").test(e)) {
498
- var r = p(t, !0),
499
- n = r[0],
500
- o = r[1],
501
- i = r[2];if (S.RegEx.isHex.test(n)) {
502
- for (var s = ["Red", "Green", "Blue"], l = S.Values.hexToRgb(n), u = i ? S.Values.hexToRgb(i) : a, c = 0; c < s.length; c++) {
503
- var f = [l[c]];o && f.push(o), u !== a && f.push(u[c]), y[e + s[c]] = f;
504
- }delete y[e];
505
- }
506
- }
507
- });for (var z in y) {
508
- var O = p(y[z]),
509
- q = O[0],
510
- $ = O[1],
511
- M = O[2];z = S.Names.camelCase(z);var I = S.Hooks.getRoot(z),
512
- B = !1;if (i(o).isSVG || "tween" === I || S.Names.prefixCheck(I)[1] !== !1 || S.Normalizations.registered[I] !== a) {
513
- (s.display !== a && null !== s.display && "none" !== s.display || s.visibility !== a && "hidden" !== s.visibility) && /opacity|filter/.test(z) && !M && 0 !== q && (M = 0), s._cacheValues && E && E[z] ? (M === a && (M = E[z].endValue + E[z].unitType), B = i(o).rootPropertyValueCache[I]) : S.Hooks.registered[z] ? M === a ? (B = S.getPropertyValue(o, I), M = S.getPropertyValue(o, z, B)) : B = S.Hooks.templates[I][1] : M === a && (M = S.getPropertyValue(o, z));var W,
514
- G,
515
- Y,
516
- D = !1;if (W = d(z, M), M = W[0], Y = W[1], W = d(z, q), q = W[0].replace(/^([+-\/*])=/, function (e, t) {
517
- return D = t, "";
518
- }), G = W[1], M = parseFloat(M) || 0, q = parseFloat(q) || 0, "%" === G && (/^(fontSize|lineHeight)$/.test(z) ? (q /= 100, G = "em") : /^scale/.test(z) ? (q /= 100, G = "") : /(Red|Green|Blue)$/i.test(z) && (q = q / 100 * 255, G = "")), /[\/*]/.test(D)) G = Y;else if (Y !== G && 0 !== M) if (0 === q) G = Y;else {
519
- n = n || h();var Q = /margin|padding|left|right|width|text|word|letter/i.test(z) || /X$/.test(z) || "x" === z ? "x" : "y";switch (Y) {case "%":
520
- M *= "x" === Q ? n.percentToPxWidth : n.percentToPxHeight;break;case "px":
521
- break;default:
522
- M *= n[Y + "ToPx"];}switch (G) {case "%":
523
- M *= 1 / ("x" === Q ? n.percentToPxWidth : n.percentToPxHeight);break;case "px":
524
- break;default:
525
- M *= 1 / n[G + "ToPx"];}
526
- }switch (D) {case "+":
527
- q = M + q;break;case "-":
528
- q = M - q;break;case "*":
529
- q = M * q;break;case "/":
530
- q = M / q;}l[z] = { rootPropertyValue: B, startValue: M, currentValue: M, endValue: q, unitType: G, easing: $ }, b.debug && console.log("tweensContainer (" + z + "): " + JSON.stringify(l[z]), o);
531
- } else b.debug && console.log("Skipping [" + I + "] due to a lack of browser support.");
532
- }l.element = o;
533
- }l.element && (S.Values.addClass(o, "velocity-animating"), R.push(l), "" === s.queue && (i(o).tweensContainer = l, i(o).opts = s), i(o).isAnimating = !0, V === w - 1 ? (b.State.calls.push([R, g, s, null, k.resolver]), b.State.isTicking === !1 && (b.State.isTicking = !0, c())) : V++);
534
- }var n,
535
- o = this,
536
- s = f.extend({}, b.defaults, v),
537
- l = {};switch (i(o) === a && b.init(o), parseFloat(s.delay) && s.queue !== !1 && f.queue(o, s.queue, function (e) {
538
- b.velocityQueueEntryFlag = !0, i(o).delayTimer = { setTimeout: setTimeout(e, parseFloat(s.delay)), next: e };
539
- }), s.duration.toString().toLowerCase()) {case "fast":
540
- s.duration = 200;break;case "normal":
541
- s.duration = h;break;case "slow":
542
- s.duration = 600;break;default:
543
- s.duration = parseFloat(s.duration) || 1;}b.mock !== !1 && (b.mock === !0 ? s.duration = s.delay = 1 : (s.duration *= parseFloat(b.mock) || 1, s.delay *= parseFloat(b.mock) || 1)), s.easing = u(s.easing, s.duration), s.begin && !m.isFunction(s.begin) && (s.begin = null), s.progress && !m.isFunction(s.progress) && (s.progress = null), s.complete && !m.isFunction(s.complete) && (s.complete = null), s.display !== a && null !== s.display && (s.display = s.display.toString().toLowerCase(), "auto" === s.display && (s.display = b.CSS.Values.getDisplayType(o))), s.visibility !== a && null !== s.visibility && (s.visibility = s.visibility.toString().toLowerCase()), s.mobileHA = s.mobileHA && b.State.isMobile && !b.State.isGingerbread, s.queue === !1 ? s.delay ? setTimeout(e, s.delay) : e() : f.queue(o, s.queue, function (t, r) {
544
- return r === !0 ? (k.promise && k.resolver(g), !0) : (b.velocityQueueEntryFlag = !0, void e(t));
545
- }), "" !== s.queue && "fx" !== s.queue || "inprogress" === f.queue(o)[0] || f.dequeue(o);
546
- }var s,
547
- l,
548
- d,
549
- g,
550
- y,
551
- v,
552
- x = arguments[0] && (arguments[0].p || f.isPlainObject(arguments[0].properties) && !arguments[0].properties.names || m.isString(arguments[0].properties));if (m.isWrapped(this) ? (s = !1, d = 0, g = this, l = this) : (s = !0, d = 1, g = x ? arguments[0].elements || arguments[0].e : arguments[0]), g = o(g)) {
553
- x ? (y = arguments[0].properties || arguments[0].p, v = arguments[0].options || arguments[0].o) : (y = arguments[d], v = arguments[d + 1]);var w = g.length,
554
- V = 0;if (!/^(stop|finish)$/i.test(y) && !f.isPlainObject(v)) {
555
- var C = d + 1;v = {};for (var T = C; T < arguments.length; T++) {
556
- m.isArray(arguments[T]) || !/^(fast|normal|slow)$/i.test(arguments[T]) && !/^\d/.test(arguments[T]) ? m.isString(arguments[T]) || m.isArray(arguments[T]) ? v.easing = arguments[T] : m.isFunction(arguments[T]) && (v.complete = arguments[T]) : v.duration = arguments[T];
557
- }
558
- }var k = { promise: null, resolver: null, rejecter: null };s && b.Promise && (k.promise = new b.Promise(function (e, t) {
559
- k.resolver = e, k.rejecter = t;
560
- }));var A;switch (y) {case "scroll":
561
- A = "scroll";break;case "reverse":
562
- A = "reverse";break;case "finish":case "stop":
563
- f.each(g, function (e, t) {
564
- i(t) && i(t).delayTimer && (clearTimeout(i(t).delayTimer.setTimeout), i(t).delayTimer.next && i(t).delayTimer.next(), delete i(t).delayTimer);
565
- });var F = [];return f.each(b.State.calls, function (e, t) {
566
- t && f.each(t[1], function (r, n) {
567
- var o = v === a ? "" : v;return o === !0 || t[2].queue === o || v === a && t[2].queue === !1 ? void f.each(g, function (r, a) {
568
- a === n && ((v === !0 || m.isString(v)) && (f.each(f.queue(a, m.isString(v) ? v : ""), function (e, t) {
569
- m.isFunction(t) && t(null, !0);
570
- }), f.queue(a, m.isString(v) ? v : "", [])), "stop" === y ? (i(a) && i(a).tweensContainer && o !== !1 && f.each(i(a).tweensContainer, function (e, t) {
571
- t.endValue = t.currentValue;
572
- }), F.push(e)) : "finish" === y && (t[2].duration = 1));
573
- }) : !0;
574
- });
575
- }), "stop" === y && (f.each(F, function (e, t) {
576
- p(t, !0);
577
- }), k.promise && k.resolver(g)), e();default:
578
- if (!f.isPlainObject(y) || m.isEmptyObject(y)) {
579
- if (m.isString(y) && b.Redirects[y]) {
580
- var j = f.extend({}, v),
581
- E = j.duration,
582
- H = j.delay || 0;return j.backwards === !0 && (g = f.extend(!0, [], g).reverse()), f.each(g, function (e, t) {
583
- parseFloat(j.stagger) ? j.delay = H + parseFloat(j.stagger) * e : m.isFunction(j.stagger) && (j.delay = H + j.stagger.call(t, e, w)), j.drag && (j.duration = parseFloat(E) || (/^(callout|transition)/.test(y) ? 1e3 : h), j.duration = Math.max(j.duration * (j.backwards ? 1 - e / w : (e + 1) / w), .75 * j.duration, 200)), b.Redirects[y].call(t, t, j || {}, e, w, g, k.promise ? k : a);
584
- }), e();
585
- }var N = "Velocity: First argument (" + y + ") was not a property map, a known action, or a registered redirect. Aborting.";return k.promise ? k.rejecter(new Error(N)) : console.log(N), e();
586
- }A = "start";}var L = { lastParent: null, lastPosition: null, lastFontSize: null, lastPercentToPxWidth: null, lastPercentToPxHeight: null, lastEmToPx: null, remToPx: null, vwToPx: null, vhToPx: null },
587
- R = [];f.each(g, function (e, t) {
588
- m.isNode(t) && n.call(t);
589
- });var z,
590
- j = f.extend({}, b.defaults, v);if (j.loop = parseInt(j.loop), z = 2 * j.loop - 1, j.loop) for (var O = 0; z > O; O++) {
591
- var q = { delay: j.delay, progress: j.progress };O === z - 1 && (q.display = j.display, q.visibility = j.visibility, q.complete = j.complete), P(g, "reverse", q);
592
- }return e();
593
- }
594
- };b = f.extend(P, b), b.animate = P;var w = t.requestAnimationFrame || g;return b.State.isMobile || r.hidden === a || r.addEventListener("visibilitychange", function () {
595
- r.hidden ? (w = function (e) {
596
- return setTimeout(function () {
597
- e(!0);
598
- }, 16);
599
- }, c()) : w = t.requestAnimationFrame || g;
600
- }), e.Velocity = b, e !== t && (e.fn.velocity = P, e.fn.velocity.defaults = b.defaults), f.each(["Down", "Up"], function (e, t) {
601
- b.Redirects["slide" + t] = function (e, r, n, o, i, s) {
602
- var l = f.extend({}, r),
603
- u = l.begin,
604
- c = l.complete,
605
- p = { height: "", marginTop: "", marginBottom: "", paddingTop: "", paddingBottom: "" },
606
- d = {};l.display === a && (l.display = "Down" === t ? "inline" === b.CSS.Values.getDisplayType(e) ? "inline-block" : "block" : "none"), l.begin = function () {
607
- u && u.call(i, i);for (var r in p) {
608
- d[r] = e.style[r];var a = b.CSS.getPropertyValue(e, r);p[r] = "Down" === t ? [a, 0] : [0, a];
609
- }d.overflow = e.style.overflow, e.style.overflow = "hidden";
610
- }, l.complete = function () {
611
- for (var t in d) {
612
- e.style[t] = d[t];
613
- }c && c.call(i, i), s && s.resolver(i);
614
- }, b(e, p, l);
615
- };
616
- }), f.each(["In", "Out"], function (e, t) {
617
- b.Redirects["fade" + t] = function (e, r, n, o, i, s) {
618
- var l = f.extend({}, r),
619
- u = { opacity: "In" === t ? 1 : 0 },
620
- c = l.complete;l.complete = n !== o - 1 ? l.begin = null : function () {
621
- c && c.call(i, i), s && s.resolver(i);
622
- }, l.display === a && (l.display = "In" === t ? "auto" : "none"), b(this, u, l);
623
- };
624
- }), b;
625
- }(window.jQuery || window.Zepto || window, window, document);
626
- }));