rails-uikit-sass 2.27.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (151) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE.txt +22 -0
  3. data/README.md +43 -0
  4. data/lib/assets/stylesheets/rails-uikit-sass.scss +3 -0
  5. data/lib/rails-uikit-sass.rb +12 -0
  6. data/vendor/assets/fonts/FontAwesome.otf +0 -0
  7. data/vendor/assets/fonts/fontawesome-webfont.ttf +0 -0
  8. data/vendor/assets/fonts/fontawesome-webfont.woff +0 -0
  9. data/vendor/assets/fonts/fontawesome-webfont.woff2 +0 -0
  10. data/vendor/assets/javascripts/components/accordion.js +180 -0
  11. data/vendor/assets/javascripts/components/accordion.min.js +2 -0
  12. data/vendor/assets/javascripts/components/autocomplete.js +340 -0
  13. data/vendor/assets/javascripts/components/autocomplete.min.js +2 -0
  14. data/vendor/assets/javascripts/components/datepicker.js +3167 -0
  15. data/vendor/assets/javascripts/components/datepicker.min.js +3 -0
  16. data/vendor/assets/javascripts/components/form-password.js +67 -0
  17. data/vendor/assets/javascripts/components/form-password.min.js +2 -0
  18. data/vendor/assets/javascripts/components/form-select.js +85 -0
  19. data/vendor/assets/javascripts/components/form-select.min.js +2 -0
  20. data/vendor/assets/javascripts/components/grid-parallax.js +168 -0
  21. data/vendor/assets/javascripts/components/grid-parallax.min.js +2 -0
  22. data/vendor/assets/javascripts/components/grid.js +540 -0
  23. data/vendor/assets/javascripts/components/grid.min.js +2 -0
  24. data/vendor/assets/javascripts/components/htmleditor.js +679 -0
  25. data/vendor/assets/javascripts/components/htmleditor.min.js +2 -0
  26. data/vendor/assets/javascripts/components/lightbox.js +588 -0
  27. data/vendor/assets/javascripts/components/lightbox.min.js +2 -0
  28. data/vendor/assets/javascripts/components/nestable.js +653 -0
  29. data/vendor/assets/javascripts/components/nestable.min.js +2 -0
  30. data/vendor/assets/javascripts/components/notify.js +189 -0
  31. data/vendor/assets/javascripts/components/notify.min.js +2 -0
  32. data/vendor/assets/javascripts/components/pagination.js +147 -0
  33. data/vendor/assets/javascripts/components/pagination.min.js +2 -0
  34. data/vendor/assets/javascripts/components/parallax.js +462 -0
  35. data/vendor/assets/javascripts/components/parallax.min.js +2 -0
  36. data/vendor/assets/javascripts/components/search.js +92 -0
  37. data/vendor/assets/javascripts/components/search.min.js +2 -0
  38. data/vendor/assets/javascripts/components/slider.js +552 -0
  39. data/vendor/assets/javascripts/components/slider.min.js +2 -0
  40. data/vendor/assets/javascripts/components/slideset.js +523 -0
  41. data/vendor/assets/javascripts/components/slideset.min.js +2 -0
  42. data/vendor/assets/javascripts/components/slideshow-fx.js +382 -0
  43. data/vendor/assets/javascripts/components/slideshow-fx.min.js +2 -0
  44. data/vendor/assets/javascripts/components/slideshow.js +596 -0
  45. data/vendor/assets/javascripts/components/slideshow.min.js +2 -0
  46. data/vendor/assets/javascripts/components/sortable.js +688 -0
  47. data/vendor/assets/javascripts/components/sortable.min.js +2 -0
  48. data/vendor/assets/javascripts/components/sticky.js +364 -0
  49. data/vendor/assets/javascripts/components/sticky.min.js +2 -0
  50. data/vendor/assets/javascripts/components/timepicker.js +192 -0
  51. data/vendor/assets/javascripts/components/timepicker.min.js +2 -0
  52. data/vendor/assets/javascripts/components/tooltip.js +235 -0
  53. data/vendor/assets/javascripts/components/tooltip.min.js +2 -0
  54. data/vendor/assets/javascripts/components/upload.js +262 -0
  55. data/vendor/assets/javascripts/components/upload.min.js +2 -0
  56. data/vendor/assets/javascripts/core/alert.js +66 -0
  57. data/vendor/assets/javascripts/core/alert.min.js +2 -0
  58. data/vendor/assets/javascripts/core/button.js +156 -0
  59. data/vendor/assets/javascripts/core/button.min.js +2 -0
  60. data/vendor/assets/javascripts/core/core.js +820 -0
  61. data/vendor/assets/javascripts/core/core.min.js +2 -0
  62. data/vendor/assets/javascripts/core/cover.js +87 -0
  63. data/vendor/assets/javascripts/core/cover.min.js +2 -0
  64. data/vendor/assets/javascripts/core/dropdown.js +534 -0
  65. data/vendor/assets/javascripts/core/dropdown.min.js +2 -0
  66. data/vendor/assets/javascripts/core/grid.js +117 -0
  67. data/vendor/assets/javascripts/core/grid.min.js +2 -0
  68. data/vendor/assets/javascripts/core/modal.js +387 -0
  69. data/vendor/assets/javascripts/core/modal.min.js +2 -0
  70. data/vendor/assets/javascripts/core/nav.js +153 -0
  71. data/vendor/assets/javascripts/core/nav.min.js +2 -0
  72. data/vendor/assets/javascripts/core/offcanvas.js +197 -0
  73. data/vendor/assets/javascripts/core/offcanvas.min.js +2 -0
  74. data/vendor/assets/javascripts/core/scrollspy.js +209 -0
  75. data/vendor/assets/javascripts/core/scrollspy.min.js +2 -0
  76. data/vendor/assets/javascripts/core/smooth-scroll.js +62 -0
  77. data/vendor/assets/javascripts/core/smooth-scroll.min.js +2 -0
  78. data/vendor/assets/javascripts/core/switcher.js +307 -0
  79. data/vendor/assets/javascripts/core/switcher.min.js +2 -0
  80. data/vendor/assets/javascripts/core/tab.js +169 -0
  81. data/vendor/assets/javascripts/core/tab.min.js +2 -0
  82. data/vendor/assets/javascripts/core/toggle.js +124 -0
  83. data/vendor/assets/javascripts/core/toggle.min.js +2 -0
  84. data/vendor/assets/javascripts/core/touch.js +175 -0
  85. data/vendor/assets/javascripts/core/touch.min.js +2 -0
  86. data/vendor/assets/javascripts/core/utility.js +335 -0
  87. data/vendor/assets/javascripts/core/utility.min.js +2 -0
  88. data/vendor/assets/javascripts/uikit.js +3898 -0
  89. data/vendor/assets/javascripts/uikit.min.js +3 -0
  90. data/vendor/assets/stylesheets/components/accordion.scss +94 -0
  91. data/vendor/assets/stylesheets/components/autocomplete.scss +107 -0
  92. data/vendor/assets/stylesheets/components/datepicker.scss +197 -0
  93. data/vendor/assets/stylesheets/components/dotnav.scss +212 -0
  94. data/vendor/assets/stylesheets/components/form-advanced.scss +128 -0
  95. data/vendor/assets/stylesheets/components/form-file.scss +63 -0
  96. data/vendor/assets/stylesheets/components/form-password.scss +74 -0
  97. data/vendor/assets/stylesheets/components/form-select.scss +66 -0
  98. data/vendor/assets/stylesheets/components/htmleditor.scss +269 -0
  99. data/vendor/assets/stylesheets/components/nestable.scss +231 -0
  100. data/vendor/assets/stylesheets/components/notify.scss +190 -0
  101. data/vendor/assets/stylesheets/components/placeholder.scss +66 -0
  102. data/vendor/assets/stylesheets/components/progress.scss +173 -0
  103. data/vendor/assets/stylesheets/components/search.scss +309 -0
  104. data/vendor/assets/stylesheets/components/slidenav.scss +183 -0
  105. data/vendor/assets/stylesheets/components/slider.scss +139 -0
  106. data/vendor/assets/stylesheets/components/slideshow.scss +208 -0
  107. data/vendor/assets/stylesheets/components/sortable.scss +124 -0
  108. data/vendor/assets/stylesheets/components/sticky.scss +57 -0
  109. data/vendor/assets/stylesheets/components/tooltip.scss +178 -0
  110. data/vendor/assets/stylesheets/components/upload.scss +34 -0
  111. data/vendor/assets/stylesheets/core/alert.scss +141 -0
  112. data/vendor/assets/stylesheets/core/animation.scss +599 -0
  113. data/vendor/assets/stylesheets/core/article.scss +139 -0
  114. data/vendor/assets/stylesheets/core/badge.scss +110 -0
  115. data/vendor/assets/stylesheets/core/base.scss +563 -0
  116. data/vendor/assets/stylesheets/core/block.scss +155 -0
  117. data/vendor/assets/stylesheets/core/breadcrumb.scss +86 -0
  118. data/vendor/assets/stylesheets/core/button.scss +406 -0
  119. data/vendor/assets/stylesheets/core/close.scss +132 -0
  120. data/vendor/assets/stylesheets/core/column.scss +209 -0
  121. data/vendor/assets/stylesheets/core/comment.scss +172 -0
  122. data/vendor/assets/stylesheets/core/contrast.scss +493 -0
  123. data/vendor/assets/stylesheets/core/cover.scss +70 -0
  124. data/vendor/assets/stylesheets/core/description-list.scss +71 -0
  125. data/vendor/assets/stylesheets/core/dropdown.scss +283 -0
  126. data/vendor/assets/stylesheets/core/flex.scss +320 -0
  127. data/vendor/assets/stylesheets/core/form.scss +629 -0
  128. data/vendor/assets/stylesheets/core/grid.scss +731 -0
  129. data/vendor/assets/stylesheets/core/icon.scss +930 -0
  130. data/vendor/assets/stylesheets/core/list.scss +102 -0
  131. data/vendor/assets/stylesheets/core/modal.scss +343 -0
  132. data/vendor/assets/stylesheets/core/nav.scss +468 -0
  133. data/vendor/assets/stylesheets/core/navbar.scss +325 -0
  134. data/vendor/assets/stylesheets/core/offcanvas.scss +203 -0
  135. data/vendor/assets/stylesheets/core/overlay.scss +534 -0
  136. data/vendor/assets/stylesheets/core/pagination.scss +197 -0
  137. data/vendor/assets/stylesheets/core/panel.scss +332 -0
  138. data/vendor/assets/stylesheets/core/print.scss +61 -0
  139. data/vendor/assets/stylesheets/core/subnav.scss +213 -0
  140. data/vendor/assets/stylesheets/core/switcher.scss +38 -0
  141. data/vendor/assets/stylesheets/core/tab.scss +368 -0
  142. data/vendor/assets/stylesheets/core/table.scss +147 -0
  143. data/vendor/assets/stylesheets/core/text.scss +136 -0
  144. data/vendor/assets/stylesheets/core/thumbnail.scss +122 -0
  145. data/vendor/assets/stylesheets/core/thumbnav.scss +122 -0
  146. data/vendor/assets/stylesheets/core/utility.scss +610 -0
  147. data/vendor/assets/stylesheets/core/variables.scss +23 -0
  148. data/vendor/assets/stylesheets/uikit-mixins.scss +327 -0
  149. data/vendor/assets/stylesheets/uikit-variables.scss +819 -0
  150. data/vendor/assets/stylesheets/uikit.scss +52 -0
  151. metadata +251 -0
@@ -0,0 +1,2 @@
1
+ /*! UIkit 2.27.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */
2
+ !function(e){var t;window.UIkit&&(t=e(UIkit)),"function"==typeof define&&define.amd&&define("uikit-upload",["uikit"],function(){return t||e(UIkit)})}(function(e){"use strict";function t(o,a){function r(t,n){var o=new FormData,a=new XMLHttpRequest;if(n.before(n,t)!==!1){for(var r,i=0;r=t[i];i++)o.append(n.param,r);for(var l in n.params)o.append(l,n.params[l]);a.upload.addEventListener("progress",function(e){var t=e.loaded/e.total*100;n.progress(t,e)},!1),a.addEventListener("loadstart",function(e){n.loadstart(e)},!1),a.addEventListener("load",function(e){n.load(e)},!1),a.addEventListener("loadend",function(e){n.loadend(e)},!1),a.addEventListener("error",function(e){n.error(e)},!1),a.addEventListener("abort",function(e){n.abort(e)},!1),a.open(n.method,n.action,!0),"json"==n.type&&a.setRequestHeader("Accept","application/json");for(var s in n.headers)a.setRequestHeader(s,n.headers[s]);a.onreadystatechange=function(){if(n.readystatechange(a),4==a.readyState){var t=a.responseText;if("json"==n.type)try{t=e.$.parseJSON(t)}catch(o){t=!1}n.complete(t,a)}},n.beforeSend(a),a.send(o)}}if(!e.support.ajaxupload)return this;if(a=e.$.extend({},t.defaults,a),o.length){if("*.*"!==a.allow)for(var i,l=0;i=o[l];l++)if(!n(a.allow,i.name))return"string"==typeof a.notallowed?alert(a.notallowed):a.notallowed(i,a),void 0;var s=a.complete;if(a.single){var d=o.length,f=0,p=!0;a.beforeAll(o),a.complete=function(e,t){f+=1,s(e,t),a.filelimit&&f>=a.filelimit&&(p=!1),p&&d>f?r([o[f]],a):a.allcomplete(e,t)},r([o[0]],a)}else a.complete=function(e,t){s(e,t),a.allcomplete(e,t)},r(o,a)}}function n(e,t){var n="^"+e.replace(/\//g,"\\/").replace(/\*\*/g,"(\\/[^\\/]+)*").replace(/\*/g,"[^\\/]+").replace(/((?!\\))\?/g,"$1.")+"$";return n="^"+n+"$",null!==t.match(new RegExp(n,"i"))}return e.component("uploadSelect",{init:function(){var e=this;this.on("change",function(){t(e.element[0].files,e.options);var n=e.element.clone(!0).data("uploadSelect",e);e.element.replaceWith(n),e.element=n})}}),e.component("uploadDrop",{defaults:{dragoverClass:"uk-dragover"},init:function(){var e=this,n=!1;this.on("drop",function(n){n.originalEvent.dataTransfer&&n.originalEvent.dataTransfer.files&&(n.stopPropagation(),n.preventDefault(),e.element.removeClass(e.options.dragoverClass),e.element.trigger("dropped.uk.upload",[n.originalEvent.dataTransfer.files]),t(n.originalEvent.dataTransfer.files,e.options))}).on("dragenter",function(e){e.stopPropagation(),e.preventDefault()}).on("dragover",function(t){t.stopPropagation(),t.preventDefault(),n||(e.element.addClass(e.options.dragoverClass),n=!0)}).on("dragleave",function(t){t.stopPropagation(),t.preventDefault(),e.element.removeClass(e.options.dragoverClass),n=!1})}}),e.support.ajaxupload=function(){function e(){var e=document.createElement("INPUT");return e.type="file","files"in e}function t(){var e=new XMLHttpRequest;return!!(e&&"upload"in e&&"onprogress"in e.upload)}function n(){return!!window.FormData}return e()&&t()&&n()}(),t.defaults={action:"",single:!0,method:"POST",param:"files[]",params:{},allow:"*.*",type:"text",filelimit:!1,headers:{},before:function(){},beforeSend:function(){},beforeAll:function(){},loadstart:function(){},load:function(){},loadend:function(){},error:function(){},abort:function(){},progress:function(){},complete:function(){},allcomplete:function(){},readystatechange:function(){},notallowed:function(e,t){alert("Only the following file types are allowed: "+t.allow)}},e.Utils.xhrupload=t,t});
@@ -0,0 +1,66 @@
1
+ /*! UIkit 2.27.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */
2
+ (function(UI) {
3
+
4
+ "use strict";
5
+
6
+ UI.component('alert', {
7
+
8
+ defaults: {
9
+ fade: true,
10
+ duration: 200,
11
+ trigger: '.uk-alert-close'
12
+ },
13
+
14
+ boot: function() {
15
+
16
+ // init code
17
+ UI.$html.on('click.alert.uikit', '[data-uk-alert]', function(e) {
18
+
19
+ var ele = UI.$(this);
20
+
21
+ if (!ele.data('alert')) {
22
+
23
+ var alert = UI.alert(ele, UI.Utils.options(ele.attr('data-uk-alert')));
24
+
25
+ if (UI.$(e.target).is(alert.options.trigger)) {
26
+ e.preventDefault();
27
+ alert.close();
28
+ }
29
+ }
30
+ });
31
+ },
32
+
33
+ init: function() {
34
+
35
+ var $this = this;
36
+
37
+ this.on('click', this.options.trigger, function(e) {
38
+ e.preventDefault();
39
+ $this.close();
40
+ });
41
+ },
42
+
43
+ close: function() {
44
+
45
+ var element = this.trigger('close.uk.alert'),
46
+ removeElement = function () {
47
+ this.trigger('closed.uk.alert').remove();
48
+ }.bind(this);
49
+
50
+ if (this.options.fade) {
51
+ element.css('overflow', 'hidden').css("max-height", element.height()).animate({
52
+ height : 0,
53
+ opacity : 0,
54
+ paddingTop : 0,
55
+ paddingBottom : 0,
56
+ marginTop : 0,
57
+ marginBottom : 0
58
+ }, this.options.duration, removeElement);
59
+ } else {
60
+ removeElement();
61
+ }
62
+ }
63
+
64
+ });
65
+
66
+ })(UIkit);
@@ -0,0 +1,2 @@
1
+ /*! UIkit 2.27.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */
2
+ !function(t){"use strict";t.component("alert",{defaults:{fade:!0,duration:200,trigger:".uk-alert-close"},boot:function(){t.$html.on("click.alert.uikit","[data-uk-alert]",function(i){var o=t.$(this);if(!o.data("alert")){var e=t.alert(o,t.Utils.options(o.attr("data-uk-alert")));t.$(i.target).is(e.options.trigger)&&(i.preventDefault(),e.close())}})},init:function(){var t=this;this.on("click",this.options.trigger,function(i){i.preventDefault(),t.close()})},close:function(){var t=this.trigger("close.uk.alert"),i=function(){this.trigger("closed.uk.alert").remove()}.bind(this);this.options.fade?t.css("overflow","hidden").css("max-height",t.height()).animate({height:0,opacity:0,paddingTop:0,paddingBottom:0,marginTop:0,marginBottom:0},this.options.duration,i):i()}})}(UIkit);
@@ -0,0 +1,156 @@
1
+ /*! UIkit 2.27.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */
2
+ (function(UI) {
3
+
4
+ "use strict";
5
+
6
+ UI.component('buttonRadio', {
7
+
8
+ defaults: {
9
+ activeClass: 'uk-active',
10
+ target: '.uk-button'
11
+ },
12
+
13
+ boot: function() {
14
+
15
+ // init code
16
+ UI.$html.on('click.buttonradio.uikit', '[data-uk-button-radio]', function(e) {
17
+
18
+ var ele = UI.$(this);
19
+
20
+ if (!ele.data('buttonRadio')) {
21
+
22
+ var obj = UI.buttonRadio(ele, UI.Utils.options(ele.attr('data-uk-button-radio'))),
23
+ target = UI.$(e.target);
24
+
25
+ if (target.is(obj.options.target)) {
26
+ target.trigger('click');
27
+ }
28
+ }
29
+ });
30
+ },
31
+
32
+ init: function() {
33
+
34
+ var $this = this;
35
+
36
+ // Init ARIA
37
+ this.find($this.options.target).attr('aria-checked', 'false').filter('.' + $this.options.activeClass).attr('aria-checked', 'true');
38
+
39
+ this.on('click', this.options.target, function(e) {
40
+
41
+ var ele = UI.$(this);
42
+
43
+ if (ele.is('a[href="#"]')) e.preventDefault();
44
+
45
+ $this.find($this.options.target).not(ele).removeClass($this.options.activeClass).blur();
46
+ ele.addClass($this.options.activeClass);
47
+
48
+ // Update ARIA
49
+ $this.find($this.options.target).not(ele).attr('aria-checked', 'false');
50
+ ele.attr('aria-checked', 'true');
51
+
52
+ $this.trigger('change.uk.button', [ele]);
53
+ });
54
+
55
+ },
56
+
57
+ getSelected: function() {
58
+ return this.find('.' + this.options.activeClass);
59
+ }
60
+ });
61
+
62
+ UI.component('buttonCheckbox', {
63
+
64
+ defaults: {
65
+ activeClass: 'uk-active',
66
+ target: '.uk-button'
67
+ },
68
+
69
+ boot: function() {
70
+
71
+ UI.$html.on('click.buttoncheckbox.uikit', '[data-uk-button-checkbox]', function(e) {
72
+ var ele = UI.$(this);
73
+
74
+ if (!ele.data('buttonCheckbox')) {
75
+
76
+ var obj = UI.buttonCheckbox(ele, UI.Utils.options(ele.attr('data-uk-button-checkbox'))),
77
+ target = UI.$(e.target);
78
+
79
+ if (target.is(obj.options.target)) {
80
+ target.trigger('click');
81
+ }
82
+ }
83
+ });
84
+ },
85
+
86
+ init: function() {
87
+
88
+ var $this = this;
89
+
90
+ // Init ARIA
91
+ this.find($this.options.target).attr('aria-checked', 'false').filter('.' + $this.options.activeClass).attr('aria-checked', 'true');
92
+
93
+ this.on('click', this.options.target, function(e) {
94
+ var ele = UI.$(this);
95
+
96
+ if (ele.is('a[href="#"]')) e.preventDefault();
97
+
98
+ ele.toggleClass($this.options.activeClass).blur();
99
+
100
+ // Update ARIA
101
+ ele.attr('aria-checked', ele.hasClass($this.options.activeClass));
102
+
103
+ $this.trigger('change.uk.button', [ele]);
104
+ });
105
+
106
+ },
107
+
108
+ getSelected: function() {
109
+ return this.find('.' + this.options.activeClass);
110
+ }
111
+ });
112
+
113
+
114
+ UI.component('button', {
115
+
116
+ defaults: {},
117
+
118
+ boot: function() {
119
+
120
+ UI.$html.on('click.button.uikit', '[data-uk-button]', function(e) {
121
+ var ele = UI.$(this);
122
+
123
+ if (!ele.data('button')) {
124
+
125
+ var obj = UI.button(ele, UI.Utils.options(ele.attr('data-uk-button')));
126
+ ele.trigger('click');
127
+ }
128
+ });
129
+ },
130
+
131
+ init: function() {
132
+
133
+ var $this = this;
134
+
135
+ // Init ARIA
136
+ this.element.attr('aria-pressed', this.element.hasClass("uk-active"));
137
+
138
+ this.on('click', function(e) {
139
+
140
+ if ($this.element.is('a[href="#"]')) e.preventDefault();
141
+
142
+ $this.toggle();
143
+ $this.trigger('change.uk.button', [$this.element.blur().hasClass('uk-active')]);
144
+ });
145
+
146
+ },
147
+
148
+ toggle: function() {
149
+ this.element.toggleClass('uk-active');
150
+
151
+ // Update ARIA
152
+ this.element.attr('aria-pressed', this.element.hasClass('uk-active'));
153
+ }
154
+ });
155
+
156
+ })(UIkit);
@@ -0,0 +1,2 @@
1
+ /*! UIkit 2.27.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */
2
+ !function(t){"use strict";t.component("buttonRadio",{defaults:{activeClass:"uk-active",target:".uk-button"},boot:function(){t.$html.on("click.buttonradio.uikit","[data-uk-button-radio]",function(i){var a=t.$(this);if(!a.data("buttonRadio")){var e=t.buttonRadio(a,t.Utils.options(a.attr("data-uk-button-radio"))),o=t.$(i.target);o.is(e.options.target)&&o.trigger("click")}})},init:function(){var i=this;this.find(i.options.target).attr("aria-checked","false").filter("."+i.options.activeClass).attr("aria-checked","true"),this.on("click",this.options.target,function(a){var e=t.$(this);e.is('a[href="#"]')&&a.preventDefault(),i.find(i.options.target).not(e).removeClass(i.options.activeClass).blur(),e.addClass(i.options.activeClass),i.find(i.options.target).not(e).attr("aria-checked","false"),e.attr("aria-checked","true"),i.trigger("change.uk.button",[e])})},getSelected:function(){return this.find("."+this.options.activeClass)}}),t.component("buttonCheckbox",{defaults:{activeClass:"uk-active",target:".uk-button"},boot:function(){t.$html.on("click.buttoncheckbox.uikit","[data-uk-button-checkbox]",function(i){var a=t.$(this);if(!a.data("buttonCheckbox")){var e=t.buttonCheckbox(a,t.Utils.options(a.attr("data-uk-button-checkbox"))),o=t.$(i.target);o.is(e.options.target)&&o.trigger("click")}})},init:function(){var i=this;this.find(i.options.target).attr("aria-checked","false").filter("."+i.options.activeClass).attr("aria-checked","true"),this.on("click",this.options.target,function(a){var e=t.$(this);e.is('a[href="#"]')&&a.preventDefault(),e.toggleClass(i.options.activeClass).blur(),e.attr("aria-checked",e.hasClass(i.options.activeClass)),i.trigger("change.uk.button",[e])})},getSelected:function(){return this.find("."+this.options.activeClass)}}),t.component("button",{defaults:{},boot:function(){t.$html.on("click.button.uikit","[data-uk-button]",function(){var i=t.$(this);if(!i.data("button")){{t.button(i,t.Utils.options(i.attr("data-uk-button")))}i.trigger("click")}})},init:function(){var t=this;this.element.attr("aria-pressed",this.element.hasClass("uk-active")),this.on("click",function(i){t.element.is('a[href="#"]')&&i.preventDefault(),t.toggle(),t.trigger("change.uk.button",[t.element.blur().hasClass("uk-active")])})},toggle:function(){this.element.toggleClass("uk-active"),this.element.attr("aria-pressed",this.element.hasClass("uk-active"))}})}(UIkit);
@@ -0,0 +1,820 @@
1
+ /*! UIkit 2.27.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */
2
+ (function(core) {
3
+
4
+ if (typeof define == 'function' && define.amd) { // AMD
5
+
6
+ define('uikit', function(){
7
+
8
+ var uikit = window.UIkit || core(window, window.jQuery, window.document);
9
+
10
+ uikit.load = function(res, req, onload, config) {
11
+
12
+ var resources = res.split(','), load = [], i, base = (config.config && config.config.uikit && config.config.uikit.base ? config.config.uikit.base : '').replace(/\/+$/g, '');
13
+
14
+ if (!base) {
15
+ throw new Error('Please define base path to UIkit in the requirejs config.');
16
+ }
17
+
18
+ for (i = 0; i < resources.length; i += 1) {
19
+ var resource = resources[i].replace(/\./g, '/');
20
+ load.push(base+'/components/'+resource);
21
+ }
22
+
23
+ req(load, function() {
24
+ onload(uikit);
25
+ });
26
+ };
27
+
28
+ return uikit;
29
+ });
30
+ }
31
+
32
+ if (!window.jQuery) {
33
+ throw new Error('UIkit requires jQuery');
34
+ }
35
+
36
+ if (window && window.jQuery) {
37
+ core(window, window.jQuery, window.document);
38
+ }
39
+
40
+
41
+ })(function(global, $, doc) {
42
+
43
+ "use strict";
44
+
45
+ var UI = {}, _UI = global.UIkit ? Object.create(global.UIkit) : undefined;
46
+
47
+ UI.version = '2.27.2';
48
+
49
+ UI.noConflict = function() {
50
+ // restore UIkit version
51
+ if (_UI) {
52
+ global.UIkit = _UI;
53
+ $.UIkit = _UI;
54
+ $.fn.uk = _UI.fn;
55
+ }
56
+
57
+ return UI;
58
+ };
59
+
60
+ UI.prefix = function(str) {
61
+ return str;
62
+ };
63
+
64
+ // cache jQuery
65
+ UI.$ = $;
66
+
67
+ UI.$doc = UI.$(document);
68
+ UI.$win = UI.$(window);
69
+ UI.$html = UI.$('html');
70
+
71
+ UI.support = {};
72
+ UI.support.transition = (function() {
73
+
74
+ var transitionEnd = (function() {
75
+
76
+ var element = doc.body || doc.documentElement,
77
+ transEndEventNames = {
78
+ WebkitTransition : 'webkitTransitionEnd',
79
+ MozTransition : 'transitionend',
80
+ OTransition : 'oTransitionEnd otransitionend',
81
+ transition : 'transitionend'
82
+ }, name;
83
+
84
+ for (name in transEndEventNames) {
85
+ if (element.style[name] !== undefined) return transEndEventNames[name];
86
+ }
87
+ }());
88
+
89
+ return transitionEnd && { end: transitionEnd };
90
+ })();
91
+
92
+ UI.support.animation = (function() {
93
+
94
+ var animationEnd = (function() {
95
+
96
+ var element = doc.body || doc.documentElement,
97
+ animEndEventNames = {
98
+ WebkitAnimation : 'webkitAnimationEnd',
99
+ MozAnimation : 'animationend',
100
+ OAnimation : 'oAnimationEnd oanimationend',
101
+ animation : 'animationend'
102
+ }, name;
103
+
104
+ for (name in animEndEventNames) {
105
+ if (element.style[name] !== undefined) return animEndEventNames[name];
106
+ }
107
+ }());
108
+
109
+ return animationEnd && { end: animationEnd };
110
+ })();
111
+
112
+ // requestAnimationFrame polyfill
113
+ //https://github.com/darius/requestAnimationFrame
114
+ (function() {
115
+
116
+ Date.now = Date.now || function() { return new Date().getTime(); };
117
+
118
+ var vendors = ['webkit', 'moz'];
119
+ for (var i = 0; i < vendors.length && !window.requestAnimationFrame; ++i) {
120
+ var vp = vendors[i];
121
+ window.requestAnimationFrame = window[vp+'RequestAnimationFrame'];
122
+ window.cancelAnimationFrame = (window[vp+'CancelAnimationFrame']
123
+ || window[vp+'CancelRequestAnimationFrame']);
124
+ }
125
+ if (/iP(ad|hone|od).*OS 6/.test(window.navigator.userAgent) // iOS6 is buggy
126
+ || !window.requestAnimationFrame || !window.cancelAnimationFrame) {
127
+ var lastTime = 0;
128
+ window.requestAnimationFrame = function(callback) {
129
+ var now = Date.now();
130
+ var nextTime = Math.max(lastTime + 16, now);
131
+ return setTimeout(function() { callback(lastTime = nextTime); },
132
+ nextTime - now);
133
+ };
134
+ window.cancelAnimationFrame = clearTimeout;
135
+ }
136
+ }());
137
+
138
+ UI.support.touch = (
139
+ ('ontouchstart' in document) ||
140
+ (global.DocumentTouch && document instanceof global.DocumentTouch) ||
141
+ (global.navigator.msPointerEnabled && global.navigator.msMaxTouchPoints > 0) || //IE 10
142
+ (global.navigator.pointerEnabled && global.navigator.maxTouchPoints > 0) || //IE >=11
143
+ false
144
+ );
145
+
146
+ UI.support.mutationobserver = (global.MutationObserver || global.WebKitMutationObserver || null);
147
+
148
+ UI.Utils = {};
149
+
150
+ UI.Utils.isFullscreen = function() {
151
+ return document.webkitFullscreenElement || document.mozFullScreenElement || document.msFullscreenElement || document.fullscreenElement || false;
152
+ };
153
+
154
+ UI.Utils.str2json = function(str, notevil) {
155
+ try {
156
+ if (notevil) {
157
+ return JSON.parse(str
158
+ // wrap keys without quote with valid double quote
159
+ .replace(/([\$\w]+)\s*:/g, function(_, $1){return '"'+$1+'":';})
160
+ // replacing single quote wrapped ones to double quote
161
+ .replace(/'([^']+)'/g, function(_, $1){return '"'+$1+'"';})
162
+ );
163
+ } else {
164
+ return (new Function('', 'var json = ' + str + '; return JSON.parse(JSON.stringify(json));'))();
165
+ }
166
+ } catch(e) { return false; }
167
+ };
168
+
169
+ UI.Utils.debounce = function(func, wait, immediate) {
170
+ var timeout;
171
+ return function() {
172
+ var context = this, args = arguments;
173
+ var later = function() {
174
+ timeout = null;
175
+ if (!immediate) func.apply(context, args);
176
+ };
177
+ var callNow = immediate && !timeout;
178
+ clearTimeout(timeout);
179
+ timeout = setTimeout(later, wait);
180
+ if (callNow) func.apply(context, args);
181
+ };
182
+ };
183
+
184
+ UI.Utils.throttle = function (func, limit) {
185
+ var wait = false;
186
+ return function () {
187
+ if (!wait) {
188
+ func.call();
189
+ wait = true;
190
+ setTimeout(function () {
191
+ wait = false;
192
+ }, limit);
193
+ }
194
+ }
195
+ };
196
+
197
+ UI.Utils.removeCssRules = function(selectorRegEx) {
198
+ var idx, idxs, stylesheet, _i, _j, _k, _len, _len1, _len2, _ref;
199
+
200
+ if(!selectorRegEx) return;
201
+
202
+ setTimeout(function(){
203
+ try {
204
+ _ref = document.styleSheets;
205
+ for (_i = 0, _len = _ref.length; _i < _len; _i++) {
206
+ stylesheet = _ref[_i];
207
+ idxs = [];
208
+ stylesheet.cssRules = stylesheet.cssRules;
209
+ for (idx = _j = 0, _len1 = stylesheet.cssRules.length; _j < _len1; idx = ++_j) {
210
+ if (stylesheet.cssRules[idx].type === CSSRule.STYLE_RULE && selectorRegEx.test(stylesheet.cssRules[idx].selectorText)) {
211
+ idxs.unshift(idx);
212
+ }
213
+ }
214
+ for (_k = 0, _len2 = idxs.length; _k < _len2; _k++) {
215
+ stylesheet.deleteRule(idxs[_k]);
216
+ }
217
+ }
218
+ } catch (_error) {}
219
+ }, 0);
220
+ };
221
+
222
+ UI.Utils.isInView = function(element, options) {
223
+
224
+ var $element = $(element);
225
+
226
+ if (!$element.is(':visible')) {
227
+ return false;
228
+ }
229
+
230
+ var window_left = UI.$win.scrollLeft(), window_top = UI.$win.scrollTop(), offset = $element.offset(), left = offset.left, top = offset.top;
231
+
232
+ options = $.extend({topoffset:0, leftoffset:0}, options);
233
+
234
+ if (top + $element.height() >= window_top && top - options.topoffset <= window_top + UI.$win.height() &&
235
+ left + $element.width() >= window_left && left - options.leftoffset <= window_left + UI.$win.width()) {
236
+ return true;
237
+ } else {
238
+ return false;
239
+ }
240
+ };
241
+
242
+ UI.Utils.checkDisplay = function(context, initanimation) {
243
+
244
+ var elements = UI.$('[data-uk-margin], [data-uk-grid-match], [data-uk-grid-margin], [data-uk-check-display]', context || document), animated;
245
+
246
+ if (context && !elements.length) {
247
+ elements = $(context);
248
+ }
249
+
250
+ elements.trigger('display.uk.check');
251
+
252
+ // fix firefox / IE animations
253
+ if (initanimation) {
254
+
255
+ if (typeof(initanimation)!='string') {
256
+ initanimation = '[class*="uk-animation-"]';
257
+ }
258
+
259
+ elements.find(initanimation).each(function(){
260
+
261
+ var ele = UI.$(this),
262
+ cls = ele.attr('class'),
263
+ anim = cls.match(/uk-animation-(.+)/);
264
+
265
+ ele.removeClass(anim[0]).width();
266
+
267
+ ele.addClass(anim[0]);
268
+ });
269
+ }
270
+
271
+ return elements;
272
+ };
273
+
274
+ UI.Utils.options = function(string) {
275
+
276
+ if ($.type(string)!='string') return string;
277
+
278
+ if (string.indexOf(':') != -1 && string.trim().substr(-1) != '}') {
279
+ string = '{'+string+'}';
280
+ }
281
+
282
+ var start = (string ? string.indexOf("{") : -1), options = {};
283
+
284
+ if (start != -1) {
285
+ try {
286
+ options = UI.Utils.str2json(string.substr(start));
287
+ } catch (e) {}
288
+ }
289
+
290
+ return options;
291
+ };
292
+
293
+ UI.Utils.animate = function(element, cls) {
294
+
295
+ var d = $.Deferred();
296
+
297
+ element = UI.$(element);
298
+
299
+ element.css('display', 'none').addClass(cls).one(UI.support.animation.end, function() {
300
+ element.removeClass(cls);
301
+ d.resolve();
302
+ });
303
+
304
+ element.css('display', '');
305
+
306
+ return d.promise();
307
+ };
308
+
309
+ UI.Utils.uid = function(prefix) {
310
+ return (prefix || 'id') + (new Date().getTime())+"RAND"+(Math.ceil(Math.random() * 100000));
311
+ };
312
+
313
+ UI.Utils.template = function(str, data) {
314
+
315
+ var tokens = str.replace(/\n/g, '\\n').replace(/\{\{\{\s*(.+?)\s*\}\}\}/g, "{{!$1}}").split(/(\{\{\s*(.+?)\s*\}\})/g),
316
+ i=0, toc, cmd, prop, val, fn, output = [], openblocks = 0;
317
+
318
+ while(i < tokens.length) {
319
+
320
+ toc = tokens[i];
321
+
322
+ if(toc.match(/\{\{\s*(.+?)\s*\}\}/)) {
323
+ i = i + 1;
324
+ toc = tokens[i];
325
+ cmd = toc[0];
326
+ prop = toc.substring(toc.match(/^(\^|\#|\!|\~|\:)/) ? 1:0);
327
+
328
+ switch(cmd) {
329
+ case '~':
330
+ output.push('for(var $i=0;$i<'+prop+'.length;$i++) { var $item = '+prop+'[$i];');
331
+ openblocks++;
332
+ break;
333
+ case ':':
334
+ output.push('for(var $key in '+prop+') { var $val = '+prop+'[$key];');
335
+ openblocks++;
336
+ break;
337
+ case '#':
338
+ output.push('if('+prop+') {');
339
+ openblocks++;
340
+ break;
341
+ case '^':
342
+ output.push('if(!'+prop+') {');
343
+ openblocks++;
344
+ break;
345
+ case '/':
346
+ output.push('}');
347
+ openblocks--;
348
+ break;
349
+ case '!':
350
+ output.push('__ret.push('+prop+');');
351
+ break;
352
+ default:
353
+ output.push('__ret.push(escape('+prop+'));');
354
+ break;
355
+ }
356
+ } else {
357
+ output.push("__ret.push('"+toc.replace(/\'/g, "\\'")+"');");
358
+ }
359
+ i = i + 1;
360
+ }
361
+
362
+ fn = new Function('$data', [
363
+ 'var __ret = [];',
364
+ 'try {',
365
+ 'with($data){', (!openblocks ? output.join('') : '__ret = ["Not all blocks are closed correctly."]'), '};',
366
+ '}catch(e){__ret = [e.message];}',
367
+ 'return __ret.join("").replace(/\\n\\n/g, "\\n");',
368
+ "function escape(html) { return String(html).replace(/&/g, '&amp;').replace(/\"/g, '&quot;').replace(/</g, '&lt;').replace(/>/g, '&gt;');}"
369
+ ].join("\n"));
370
+
371
+ return data ? fn(data) : fn;
372
+ };
373
+
374
+ UI.Utils.focus = function(element, extra) {
375
+
376
+ element = $(element);
377
+
378
+ if (!element.length) {
379
+ return element;
380
+ }
381
+
382
+ var autofocus = element.find('[autofocus]:first'), tabidx;
383
+
384
+ if (autofocus.length) {
385
+ return autofocus.focus();
386
+ }
387
+
388
+ autofocus = element.find(':input'+(extra && (','+extra) || '')).first();
389
+
390
+ if (autofocus.length) {
391
+ return autofocus.focus();
392
+ }
393
+
394
+ if (!element.attr('tabindex')) {
395
+ tabidx = 1000;
396
+ element.attr('tabindex', tabidx);
397
+ }
398
+
399
+ element[0].focus();
400
+
401
+ if (tabidx) {
402
+ element.attr('tabindex', '');
403
+ }
404
+
405
+ return element;
406
+ }
407
+
408
+ UI.Utils.events = {};
409
+ UI.Utils.events.click = UI.support.touch ? 'tap' : 'click';
410
+
411
+ global.UIkit = UI;
412
+
413
+ // deprecated
414
+
415
+ UI.fn = function(command, options) {
416
+
417
+ var args = arguments, cmd = command.match(/^([a-z\-]+)(?:\.([a-z]+))?/i), component = cmd[1], method = cmd[2];
418
+
419
+ if (!UI[component]) {
420
+ $.error('UIkit component [' + component + '] does not exist.');
421
+ return this;
422
+ }
423
+
424
+ return this.each(function() {
425
+ var $this = $(this), data = $this.data(component);
426
+ if (!data) $this.data(component, (data = UI[component](this, method ? undefined : options)));
427
+ if (method) data[method].apply(data, Array.prototype.slice.call(args, 1));
428
+ });
429
+ };
430
+
431
+ $.UIkit = UI;
432
+ $.fn.uk = UI.fn;
433
+
434
+ UI.langdirection = UI.$html.attr("dir") == "rtl" ? "right" : "left";
435
+
436
+ UI.components = {};
437
+
438
+ UI.component = function(name, def) {
439
+
440
+ var fn = function(element, options) {
441
+
442
+ var $this = this;
443
+
444
+ this.UIkit = UI;
445
+ this.element = element ? UI.$(element) : null;
446
+ this.options = $.extend(true, {}, this.defaults, options);
447
+ this.plugins = {};
448
+
449
+ if (this.element) {
450
+ this.element.data(name, this);
451
+ }
452
+
453
+ this.init();
454
+
455
+ (this.options.plugins.length ? this.options.plugins : Object.keys(fn.plugins)).forEach(function(plugin) {
456
+
457
+ if (fn.plugins[plugin].init) {
458
+ fn.plugins[plugin].init($this);
459
+ $this.plugins[plugin] = true;
460
+ }
461
+
462
+ });
463
+
464
+ this.trigger('init.uk.component', [name, this]);
465
+
466
+ return this;
467
+ };
468
+
469
+ fn.plugins = {};
470
+
471
+ $.extend(true, fn.prototype, {
472
+
473
+ defaults : {plugins: []},
474
+
475
+ boot: function(){},
476
+ init: function(){},
477
+
478
+ on: function(a1,a2,a3){
479
+ return UI.$(this.element || this).on(a1,a2,a3);
480
+ },
481
+
482
+ one: function(a1,a2,a3){
483
+ return UI.$(this.element || this).one(a1,a2,a3);
484
+ },
485
+
486
+ off: function(evt){
487
+ return UI.$(this.element || this).off(evt);
488
+ },
489
+
490
+ trigger: function(evt, params) {
491
+ return UI.$(this.element || this).trigger(evt, params);
492
+ },
493
+
494
+ find: function(selector) {
495
+ return UI.$(this.element ? this.element: []).find(selector);
496
+ },
497
+
498
+ proxy: function(obj, methods) {
499
+
500
+ var $this = this;
501
+
502
+ methods.split(' ').forEach(function(method) {
503
+ if (!$this[method]) $this[method] = function() { return obj[method].apply(obj, arguments); };
504
+ });
505
+ },
506
+
507
+ mixin: function(obj, methods) {
508
+
509
+ var $this = this;
510
+
511
+ methods.split(' ').forEach(function(method) {
512
+ if (!$this[method]) $this[method] = obj[method].bind($this);
513
+ });
514
+ },
515
+
516
+ option: function() {
517
+
518
+ if (arguments.length == 1) {
519
+ return this.options[arguments[0]] || undefined;
520
+ } else if (arguments.length == 2) {
521
+ this.options[arguments[0]] = arguments[1];
522
+ }
523
+ }
524
+
525
+ }, def);
526
+
527
+ this.components[name] = fn;
528
+
529
+ this[name] = function() {
530
+
531
+ var element, options;
532
+
533
+ if (arguments.length) {
534
+
535
+ switch(arguments.length) {
536
+ case 1:
537
+
538
+ if (typeof arguments[0] === 'string' || arguments[0].nodeType || arguments[0] instanceof jQuery) {
539
+ element = $(arguments[0]);
540
+ } else {
541
+ options = arguments[0];
542
+ }
543
+
544
+ break;
545
+ case 2:
546
+
547
+ element = $(arguments[0]);
548
+ options = arguments[1];
549
+ break;
550
+ }
551
+ }
552
+
553
+ if (element && element.data(name)) {
554
+ return element.data(name);
555
+ }
556
+
557
+ return (new UI.components[name](element, options));
558
+ };
559
+
560
+ if (UI.domready) {
561
+ UI.component.boot(name);
562
+ }
563
+
564
+ return fn;
565
+ };
566
+
567
+ UI.plugin = function(component, name, def) {
568
+ this.components[component].plugins[name] = def;
569
+ };
570
+
571
+ UI.component.boot = function(name) {
572
+
573
+ if (UI.components[name].prototype && UI.components[name].prototype.boot && !UI.components[name].booted) {
574
+ UI.components[name].prototype.boot.apply(UI, []);
575
+ UI.components[name].booted = true;
576
+ }
577
+ };
578
+
579
+ UI.component.bootComponents = function() {
580
+
581
+ for (var component in UI.components) {
582
+ UI.component.boot(component);
583
+ }
584
+ };
585
+
586
+
587
+ // DOM mutation save ready helper function
588
+
589
+ UI.domObservers = [];
590
+ UI.domready = false;
591
+
592
+ UI.ready = function(fn) {
593
+
594
+ UI.domObservers.push(fn);
595
+
596
+ if (UI.domready) {
597
+ fn(document);
598
+ }
599
+ };
600
+
601
+ UI.on = function(a1,a2,a3){
602
+
603
+ if (a1 && a1.indexOf('ready.uk.dom') > -1 && UI.domready) {
604
+ a2.apply(UI.$doc);
605
+ }
606
+
607
+ return UI.$doc.on(a1,a2,a3);
608
+ };
609
+
610
+ UI.one = function(a1,a2,a3){
611
+
612
+ if (a1 && a1.indexOf('ready.uk.dom') > -1 && UI.domready) {
613
+ a2.apply(UI.$doc);
614
+ return UI.$doc;
615
+ }
616
+
617
+ return UI.$doc.one(a1,a2,a3);
618
+ };
619
+
620
+ UI.trigger = function(evt, params) {
621
+ return UI.$doc.trigger(evt, params);
622
+ };
623
+
624
+ UI.domObserve = function(selector, fn) {
625
+
626
+ if(!UI.support.mutationobserver) return;
627
+
628
+ fn = fn || function() {};
629
+
630
+ UI.$(selector).each(function() {
631
+
632
+ var element = this,
633
+ $element = UI.$(element);
634
+
635
+ if ($element.data('observer')) {
636
+ return;
637
+ }
638
+
639
+ try {
640
+
641
+ var observer = new UI.support.mutationobserver(UI.Utils.debounce(function(mutations) {
642
+ fn.apply(element, [$element]);
643
+ $element.trigger('changed.uk.dom');
644
+ }, 50), {childList: true, subtree: true});
645
+
646
+ // pass in the target node, as well as the observer options
647
+ observer.observe(element, { childList: true, subtree: true });
648
+
649
+ $element.data('observer', observer);
650
+
651
+ } catch(e) {}
652
+ });
653
+ };
654
+
655
+ UI.init = function(root) {
656
+
657
+ root = root || document;
658
+
659
+ UI.domObservers.forEach(function(fn){
660
+ fn(root);
661
+ });
662
+ };
663
+
664
+ UI.on('domready.uk.dom', function(){
665
+
666
+ UI.init();
667
+
668
+ if (UI.domready) UI.Utils.checkDisplay();
669
+ });
670
+
671
+ document.addEventListener('DOMContentLoaded', function(){
672
+
673
+ var domReady = function() {
674
+
675
+ UI.$body = UI.$('body');
676
+
677
+ UI.trigger('beforeready.uk.dom');
678
+
679
+ UI.component.bootComponents();
680
+
681
+ // custom scroll observer
682
+ var rafToken = requestAnimationFrame((function(){
683
+
684
+ var memory = {dir: {x:0, y:0}, x: window.pageXOffset, y:window.pageYOffset};
685
+
686
+ var fn = function(){
687
+ // reading this (window.page[X|Y]Offset) causes a full page recalc of the layout in Chrome,
688
+ // so we only want to do this once
689
+ var wpxo = window.pageXOffset;
690
+ var wpyo = window.pageYOffset;
691
+
692
+ // Did the scroll position change since the last time we were here?
693
+ if (memory.x != wpxo || memory.y != wpyo) {
694
+
695
+ // Set the direction of the scroll and store the new position
696
+ if (wpxo != memory.x) {memory.dir.x = wpxo > memory.x ? 1:-1; } else { memory.dir.x = 0; }
697
+ if (wpyo != memory.y) {memory.dir.y = wpyo > memory.y ? 1:-1; } else { memory.dir.y = 0; }
698
+
699
+ memory.x = wpxo;
700
+ memory.y = wpyo;
701
+
702
+ // Trigger the scroll event, this could probably be sent using memory.clone() but this is
703
+ // more explicit and easier to see exactly what is being sent in the event.
704
+ UI.$doc.trigger('scrolling.uk.document', [{
705
+ dir: {x: memory.dir.x, y: memory.dir.y}, x: wpxo, y: wpyo
706
+ }]);
707
+ }
708
+
709
+ cancelAnimationFrame(rafToken);
710
+ rafToken = requestAnimationFrame(fn);
711
+ };
712
+
713
+ if (UI.support.touch) {
714
+ UI.$html.on('touchmove touchend MSPointerMove MSPointerUp pointermove pointerup', fn);
715
+ }
716
+
717
+ if (memory.x || memory.y) fn();
718
+
719
+ return fn;
720
+
721
+ })());
722
+
723
+ // run component init functions on dom
724
+ UI.trigger('domready.uk.dom');
725
+
726
+ if (UI.support.touch) {
727
+
728
+ // remove css hover rules for touch devices
729
+ // UI.Utils.removeCssRules(/\.uk-(?!navbar).*:hover/);
730
+
731
+ // viewport unit fix for uk-height-viewport - should be fixed in iOS 8
732
+ if (navigator.userAgent.match(/(iPad|iPhone|iPod)/g)) {
733
+
734
+ UI.$win.on('load orientationchange resize', UI.Utils.debounce((function(){
735
+
736
+ var fn = function() {
737
+ $('.uk-height-viewport').css('height', window.innerHeight);
738
+ return fn;
739
+ };
740
+
741
+ return fn();
742
+
743
+ })(), 100));
744
+ }
745
+ }
746
+
747
+ UI.trigger('afterready.uk.dom');
748
+
749
+ // mark that domready is left behind
750
+ UI.domready = true;
751
+
752
+ // auto init js components
753
+ if (UI.support.mutationobserver) {
754
+
755
+ var initFn = UI.Utils.debounce(function(){
756
+ requestAnimationFrame(function(){ UI.init(document.body);});
757
+ }, 10);
758
+
759
+ (new UI.support.mutationobserver(function(mutations) {
760
+
761
+ var init = false;
762
+
763
+ mutations.every(function(mutation){
764
+
765
+ if (mutation.type != 'childList') return true;
766
+
767
+ for (var i = 0, node; i < mutation.addedNodes.length; ++i) {
768
+
769
+ node = mutation.addedNodes[i];
770
+
771
+ if (node.outerHTML && node.outerHTML.indexOf('data-uk-') !== -1) {
772
+ return (init = true) && false;
773
+ }
774
+ }
775
+ return true;
776
+ });
777
+
778
+ if (init) initFn();
779
+
780
+ })).observe(document.body, {childList: true, subtree: true});
781
+ }
782
+ };
783
+
784
+ if (document.readyState == 'complete' || document.readyState == 'interactive') {
785
+ setTimeout(domReady);
786
+ }
787
+
788
+ return domReady;
789
+
790
+ }());
791
+
792
+ // add touch identifier class
793
+ UI.$html.addClass(UI.support.touch ? 'uk-touch' : 'uk-notouch');
794
+
795
+ // add uk-hover class on tap to support overlays on touch devices
796
+ if (UI.support.touch) {
797
+
798
+ var hoverset = false,
799
+ exclude,
800
+ hovercls = 'uk-hover',
801
+ selector = '.uk-overlay, .uk-overlay-hover, .uk-overlay-toggle, .uk-animation-hover, .uk-has-hover';
802
+
803
+ UI.$html.on('mouseenter touchstart MSPointerDown pointerdown', selector, function() {
804
+
805
+ if (hoverset) $('.'+hovercls).removeClass(hovercls);
806
+
807
+ hoverset = $(this).addClass(hovercls);
808
+
809
+ }).on('mouseleave touchend MSPointerUp pointerup', function(e) {
810
+
811
+ exclude = $(e.target).parents(selector);
812
+
813
+ if (hoverset) {
814
+ hoverset.not(exclude).removeClass(hovercls);
815
+ }
816
+ });
817
+ }
818
+
819
+ return UI;
820
+ });