fomantic-ui-sass 2.6.4 → 2.7.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (127) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +1 -0
  3. data/.rubocop.yml +1 -0
  4. data/.rubocop_todo.yml +102 -0
  5. data/.travis.yml +9 -3
  6. data/README.md +4 -2
  7. data/Rakefile +25 -3
  8. data/app/assets/fonts/semantic-ui/brand-icons.eot +0 -0
  9. data/app/assets/fonts/semantic-ui/brand-icons.svg +178 -11
  10. data/app/assets/fonts/semantic-ui/brand-icons.ttf +0 -0
  11. data/app/assets/fonts/semantic-ui/brand-icons.woff +0 -0
  12. data/app/assets/fonts/semantic-ui/brand-icons.woff2 +0 -0
  13. data/app/assets/fonts/semantic-ui/icons.eot +0 -0
  14. data/app/assets/fonts/semantic-ui/icons.svg +1138 -92
  15. data/app/assets/fonts/semantic-ui/icons.ttf +0 -0
  16. data/app/assets/fonts/semantic-ui/icons.woff +0 -0
  17. data/app/assets/fonts/semantic-ui/icons.woff2 +0 -0
  18. data/app/assets/fonts/semantic-ui/outline-icons.eot +0 -0
  19. data/app/assets/fonts/semantic-ui/outline-icons.svg +127 -26
  20. data/app/assets/fonts/semantic-ui/outline-icons.ttf +0 -0
  21. data/app/assets/fonts/semantic-ui/outline-icons.woff +0 -0
  22. data/app/assets/fonts/semantic-ui/outline-icons.woff2 +0 -0
  23. data/app/assets/javascripts/semantic-ui.js +1 -1
  24. data/app/assets/javascripts/semantic-ui/accordion.js +5 -1
  25. data/app/assets/javascripts/semantic-ui/api.js +9 -2
  26. data/app/assets/javascripts/semantic-ui/calendar.js +25 -12
  27. data/app/assets/javascripts/semantic-ui/checkbox.js +39 -2
  28. data/app/assets/javascripts/semantic-ui/dimmer.js +25 -5
  29. data/app/assets/javascripts/semantic-ui/dropdown.js +130 -47
  30. data/app/assets/javascripts/semantic-ui/embed.js +5 -1
  31. data/app/assets/javascripts/semantic-ui/form.js +24 -19
  32. data/app/assets/javascripts/semantic-ui/modal.js +33 -17
  33. data/app/assets/javascripts/semantic-ui/nag.js +5 -1
  34. data/app/assets/javascripts/semantic-ui/popup.js +10 -5
  35. data/app/assets/javascripts/semantic-ui/progress.js +5 -1
  36. data/app/assets/javascripts/semantic-ui/rating.js +21 -6
  37. data/app/assets/javascripts/semantic-ui/search.js +43 -27
  38. data/app/assets/javascripts/semantic-ui/shape.js +5 -1
  39. data/app/assets/javascripts/semantic-ui/sidebar.js +7 -3
  40. data/app/assets/javascripts/semantic-ui/site.js +6 -2
  41. data/app/assets/javascripts/semantic-ui/slider.js +1216 -0
  42. data/app/assets/javascripts/semantic-ui/state.js +5 -1
  43. data/app/assets/javascripts/semantic-ui/sticky.js +5 -1
  44. data/app/assets/javascripts/semantic-ui/tab.js +10 -3
  45. data/app/assets/javascripts/semantic-ui/toast.js +6 -2
  46. data/app/assets/javascripts/semantic-ui/transition.js +6 -2
  47. data/app/assets/javascripts/semantic-ui/visibility.js +6 -2
  48. data/app/assets/stylesheets/semantic-ui/collections/_breadcrumb.scss +7 -7
  49. data/app/assets/stylesheets/semantic-ui/collections/_form.scss +59 -83
  50. data/app/assets/stylesheets/semantic-ui/collections/_grid.scss +110 -124
  51. data/app/assets/stylesheets/semantic-ui/collections/_menu.scss +262 -237
  52. data/app/assets/stylesheets/semantic-ui/collections/_message.scss +155 -118
  53. data/app/assets/stylesheets/semantic-ui/collections/_table.scss +332 -145
  54. data/app/assets/stylesheets/semantic-ui/elements/_button.scss +2281 -2415
  55. data/app/assets/stylesheets/semantic-ui/elements/_container.scss +1 -1
  56. data/app/assets/stylesheets/semantic-ui/elements/_divider.scss +10 -10
  57. data/app/assets/stylesheets/semantic-ui/elements/_flag.scss +81 -81
  58. data/app/assets/stylesheets/semantic-ui/elements/_header.scss +178 -191
  59. data/app/assets/stylesheets/semantic-ui/elements/_icon.scss +71 -103
  60. data/app/assets/stylesheets/semantic-ui/elements/_image.scss +8 -8
  61. data/app/assets/stylesheets/semantic-ui/elements/_input.scss +61 -40
  62. data/app/assets/stylesheets/semantic-ui/elements/_label.scss +1087 -444
  63. data/app/assets/stylesheets/semantic-ui/elements/_list.scss +69 -69
  64. data/app/assets/stylesheets/semantic-ui/elements/_loader.scss +510 -155
  65. data/app/assets/stylesheets/semantic-ui/elements/_placeholder.scss +20 -14
  66. data/app/assets/stylesheets/semantic-ui/elements/_rail.scss +26 -26
  67. data/app/assets/stylesheets/semantic-ui/elements/_reveal.scss +8 -8
  68. data/app/assets/stylesheets/semantic-ui/elements/_segment.scss +180 -216
  69. data/app/assets/stylesheets/semantic-ui/elements/_step.scss +34 -39
  70. data/app/assets/stylesheets/semantic-ui/elements/_text.scss +114 -0
  71. data/app/assets/stylesheets/semantic-ui/globals/_reset.scss +1 -1
  72. data/app/assets/stylesheets/semantic-ui/globals/_site.scss +11 -20
  73. data/app/assets/stylesheets/semantic-ui/modules/_accordion.scss +16 -16
  74. data/app/assets/stylesheets/semantic-ui/modules/_all.scss +1 -1
  75. data/app/assets/stylesheets/semantic-ui/modules/_calendar.scss +1 -1
  76. data/app/assets/stylesheets/semantic-ui/modules/_checkbox.scss +23 -23
  77. data/app/assets/stylesheets/semantic-ui/modules/_dimmer.scss +32 -32
  78. data/app/assets/stylesheets/semantic-ui/modules/_dropdown.scss +128 -155
  79. data/app/assets/stylesheets/semantic-ui/modules/_embed.scss +13 -13
  80. data/app/assets/stylesheets/semantic-ui/modules/_modal.scss +50 -48
  81. data/app/assets/stylesheets/semantic-ui/modules/_nag.scss +15 -15
  82. data/app/assets/stylesheets/semantic-ui/modules/_popup.scss +50 -50
  83. data/app/assets/stylesheets/semantic-ui/modules/_progress.scss +30 -44
  84. data/app/assets/stylesheets/semantic-ui/modules/_rating.scss +137 -111
  85. data/app/assets/stylesheets/semantic-ui/modules/_search.scss +24 -28
  86. data/app/assets/stylesheets/semantic-ui/modules/_shape.scss +6 -6
  87. data/app/assets/stylesheets/semantic-ui/modules/_sidebar.scss +29 -29
  88. data/app/assets/stylesheets/semantic-ui/modules/_slider.scss +768 -0
  89. data/app/assets/stylesheets/semantic-ui/modules/_sticky.scss +3 -3
  90. data/app/assets/stylesheets/semantic-ui/modules/_tab.scss +10 -14
  91. data/app/assets/stylesheets/semantic-ui/modules/_toast.scss +27 -16
  92. data/app/assets/stylesheets/semantic-ui/modules/_transition.scss +1 -1
  93. data/app/assets/stylesheets/semantic-ui/views/_ad.scss +6 -6
  94. data/app/assets/stylesheets/semantic-ui/views/_card.scss +103 -133
  95. data/app/assets/stylesheets/semantic-ui/views/_comment.scss +26 -26
  96. data/app/assets/stylesheets/semantic-ui/views/_feed.scss +27 -27
  97. data/app/assets/stylesheets/semantic-ui/views/_item.scss +54 -54
  98. data/app/assets/stylesheets/semantic-ui/views/_statistic.scss +138 -108
  99. data/app/helpers/semantic_breadcrumbs_helper.rb +1 -1
  100. data/app/helpers/semantic_flash_helper.rb +4 -2
  101. data/app/helpers/semantic_icon_helper.rb +1 -1
  102. data/fomantic-ui-sass.gemspec +20 -19
  103. data/gemfiles/rails_5.0.gemfile +5 -0
  104. data/gemfiles/rails_5.1.gemfile +5 -0
  105. data/gemfiles/rails_5.2.gemfile +5 -0
  106. data/lib/fomantic-ui-sass.rb +3 -4
  107. data/lib/fomantic/ui/sass/breadcrumbs.rb +2 -4
  108. data/lib/fomantic/ui/sass/engine.rb +3 -3
  109. data/lib/fomantic/ui/sass/version.rb +2 -2
  110. data/spec/dummy/Rakefile +1 -1
  111. data/spec/dummy/bin/bundle +1 -1
  112. data/spec/dummy/bin/rails +1 -1
  113. data/spec/dummy/bin/rake +0 -0
  114. data/spec/dummy/config.ru +1 -1
  115. data/spec/dummy/config/application.rb +5 -6
  116. data/spec/dummy/config/boot.rb +3 -3
  117. data/spec/dummy/config/environment.rb +1 -1
  118. data/spec/dummy/config/environments/test.rb +1 -1
  119. data/spec/helpers/semantic_breadcrumbs_helper_spec.rb +30 -32
  120. data/spec/helpers/semantic_flash_helper_spec.rb +15 -16
  121. data/spec/helpers/semantic_icon_helper_spec.rb +10 -10
  122. data/spec/spec_helper.rb +4 -6
  123. data/tasks/converter.rb +61 -73
  124. data/templates/project/manifest.rb +1 -2
  125. metadata +45 -23
  126. data/app/assets/javascripts/semantic-ui/range.js +0 -278
  127. data/app/assets/stylesheets/semantic-ui/modules/_range.scss +0 -192
@@ -12,6 +12,10 @@
12
12
 
13
13
  "use strict";
14
14
 
15
+ $.isFunction = $.isFunction || function(obj) {
16
+ return typeof obj === "function" && typeof obj.nodeType !== "number";
17
+ };
18
+
15
19
  window = (typeof window != 'undefined' && window.Math == Math)
16
20
  ? window
17
21
  : (typeof self != 'undefined' && self.Math == Math)
@@ -541,7 +545,7 @@ $.fn.embed = function(parameters) {
541
545
  else if(found !== undefined) {
542
546
  response = found;
543
547
  }
544
- if($.isArray(returnedValue)) {
548
+ if(Array.isArray(returnedValue)) {
545
549
  returnedValue.push(response);
546
550
  }
547
551
  else if(returnedValue !== undefined) {
@@ -12,6 +12,10 @@
12
12
 
13
13
  'use strict';
14
14
 
15
+ $.isFunction = $.isFunction || function(obj) {
16
+ return typeof obj === "function" && typeof obj.nodeType !== "number";
17
+ };
18
+
15
19
  window = (typeof window != 'undefined' && window.Math == Math)
16
20
  ? window
17
21
  : (typeof self != 'undefined' && self.Math == Math)
@@ -261,7 +265,7 @@ $.fn.form = function(parameters) {
261
265
  },
262
266
  // duck type rule test
263
267
  shorthandRules: function(rules) {
264
- return (typeof rules == 'string' || $.isArray(rules));
268
+ return (typeof rules == 'string' || Array.isArray(rules));
265
269
  },
266
270
  empty: function($field) {
267
271
  if(!$field || $field.length === 0) {
@@ -514,17 +518,18 @@ $.fn.form = function(parameters) {
514
518
  field: function(identifier) {
515
519
  module.verbose('Finding field with identifier', identifier);
516
520
  identifier = module.escape.string(identifier);
517
- if($field.filter('#' + identifier).length > 0 ) {
518
- return $field.filter('#' + identifier);
521
+ var t;
522
+ if((t=$field.filter('#' + identifier)).length > 0 ) {
523
+ return t;
519
524
  }
520
- else if( $field.filter('[name="' + identifier +'"]').length > 0 ) {
521
- return $field.filter('[name="' + identifier +'"]');
525
+ if((t=$field.filter('[name="' + identifier +'"]')).length > 0 ) {
526
+ return t;
522
527
  }
523
- else if( $field.filter('[name="' + identifier +'[]"]').length > 0 ) {
524
- return $field.filter('[name="' + identifier +'[]"]');
528
+ if((t=$field.filter('[name="' + identifier +'[]"]')).length > 0 ) {
529
+ return t;
525
530
  }
526
- else if( $field.filter('[data-' + metadata.validate + '="'+ identifier +'"]').length > 0 ) {
527
- return $field.filter('[data-' + metadata.validate + '="'+ identifier +'"]');
531
+ if((t=$field.filter('[data-' + metadata.validate + '="'+ identifier +'"]')).length > 0 ) {
532
+ return t;
528
533
  }
529
534
  return $('<input/>');
530
535
  },
@@ -565,7 +570,7 @@ $.fn.form = function(parameters) {
565
570
  },
566
571
  values: function (fields) {
567
572
  var
568
- $fields = $.isArray(fields)
573
+ $fields = Array.isArray(fields)
569
574
  ? module.get.fields(fields)
570
575
  : $field,
571
576
  values = {}
@@ -667,7 +672,7 @@ $.fn.form = function(parameters) {
667
672
  newValidation = {}
668
673
  ;
669
674
  if(module.is.shorthandRules(rules)) {
670
- rules = $.isArray(rules)
675
+ rules = Array.isArray(rules)
671
676
  ? rules
672
677
  : [rules]
673
678
  ;
@@ -750,7 +755,7 @@ $.fn.form = function(parameters) {
750
755
  remove: {
751
756
  rule: function(field, rule) {
752
757
  var
753
- rules = $.isArray(rule)
758
+ rules = Array.isArray(rule)
754
759
  ? rule
755
760
  : [rule]
756
761
  ;
@@ -759,7 +764,7 @@ $.fn.form = function(parameters) {
759
764
  validation[field].rules = [];
760
765
  return;
761
766
  }
762
- if(validation[field] == undefined || !$.isArray(validation[field].rules)) {
767
+ if(validation[field] == undefined || !Array.isArray(validation[field].rules)) {
763
768
  return;
764
769
  }
765
770
  $.each(validation[field].rules, function(index, rule) {
@@ -771,7 +776,7 @@ $.fn.form = function(parameters) {
771
776
  },
772
777
  field: function(field) {
773
778
  var
774
- fields = $.isArray(field)
779
+ fields = Array.isArray(field)
775
780
  ? field
776
781
  : [field]
777
782
  ;
@@ -781,7 +786,7 @@ $.fn.form = function(parameters) {
781
786
  },
782
787
  // alias
783
788
  rules: function(field, rules) {
784
- if($.isArray(field)) {
789
+ if(Array.isArray(field)) {
785
790
  $.each(fields, function(index, field) {
786
791
  module.remove.rule(field, rules);
787
792
  });
@@ -862,7 +867,7 @@ $.fn.form = function(parameters) {
862
867
  var
863
868
  $field = module.get.field(key),
864
869
  $element = $field.parent(),
865
- isMultiple = $.isArray(value),
870
+ isMultiple = Array.isArray(value),
866
871
  isCheckbox = $element.is(selector.uiCheckbox),
867
872
  isDropdown = $element.is(selector.uiDropdown),
868
873
  isRadio = ($field.is(selector.radio) && isCheckbox),
@@ -1180,7 +1185,7 @@ $.fn.form = function(parameters) {
1180
1185
  else if(found !== undefined) {
1181
1186
  response = found;
1182
1187
  }
1183
- if($.isArray(returnedValue)) {
1188
+ if(Array.isArray(returnedValue)) {
1184
1189
  returnedValue.push(response);
1185
1190
  }
1186
1191
  else if(returnedValue !== undefined) {
@@ -1239,7 +1244,7 @@ $.fn.form.settings = {
1239
1244
  bracket : /\[(.*)\]/i,
1240
1245
  decimal : /^\d+\.?\d*$/,
1241
1246
  email : /^[a-z0-9!#$%&'*+\/=?^_`{|}~.-]+@[a-z0-9]([a-z0-9-]*[a-z0-9])?(\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)*$/i,
1242
- escape : /[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,
1247
+ escape : /[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|:,=@]/g,
1243
1248
  flags : /^\/(.*)\/(.*)?/,
1244
1249
  integer : /^\-?\d+$/,
1245
1250
  number : /^\-?\d*(\.\d+)?$/,
@@ -1336,7 +1341,7 @@ $.fn.form.settings = {
1336
1341
 
1337
1342
  // is not empty or blank string
1338
1343
  empty: function(value) {
1339
- return !(value === undefined || '' === value || $.isArray(value) && value.length === 0);
1344
+ return !(value === undefined || '' === value || Array.isArray(value) && value.length === 0);
1340
1345
  },
1341
1346
 
1342
1347
  // checkbox checked
@@ -12,6 +12,10 @@
12
12
 
13
13
  'use strict';
14
14
 
15
+ $.isFunction = $.isFunction || function(obj) {
16
+ return typeof obj === "function" && typeof obj.nodeType !== "number";
17
+ };
18
+
15
19
  window = (typeof window != 'undefined' && window.Math == Math)
16
20
  ? window
17
21
  : (typeof self != 'undefined' && self.Math == Math)
@@ -252,7 +256,9 @@ $.fn.modal = function(parameters) {
252
256
  });
253
257
  },
254
258
  preventScroll: function(event) {
255
- event.preventDefault();
259
+ if(event.target.className.indexOf('dimmer') !== -1) {
260
+ event.preventDefault();
261
+ }
256
262
  },
257
263
  deny: function() {
258
264
  if(ignoreRepeatedEvents || settings.onDeny.call(element, $(this)) === false) {
@@ -290,15 +296,17 @@ $.fn.modal = function(parameters) {
290
296
  isInModal = ($target.closest(selector.modal).length > 0),
291
297
  isInDOM = $.contains(document.documentElement, event.target)
292
298
  ;
293
- if(!isInModal && isInDOM && module.is.active()) {
299
+ if(!isInModal && isInDOM && module.is.active() && $module.hasClass(className.top) ) {
294
300
  module.debug('Dimmer clicked, hiding all modals');
295
- module.remove.clickaway();
296
301
  if(settings.allowMultiple) {
297
- module.hideAll();
302
+ if(!module.hideAll()) {
303
+ return;
304
+ }
298
305
  }
299
- else {
300
- module.hide();
306
+ else if(!module.hide()){
307
+ return;
301
308
  }
309
+ module.remove.clickaway();
302
310
  }
303
311
  },
304
312
  debounce: function(method, delay) {
@@ -357,7 +365,7 @@ $.fn.modal = function(parameters) {
357
365
  : function(){}
358
366
  ;
359
367
  module.refreshModals();
360
- module.hideModal(callback);
368
+ return module.hideModal(callback);
361
369
  },
362
370
 
363
371
  showModal: function(callback) {
@@ -386,7 +394,7 @@ $.fn.modal = function(parameters) {
386
394
  else {
387
395
  if( settings.allowMultiple ) {
388
396
  if ( module.others.active() ) {
389
- $otherModals.filter('.' + className.active).find(selector.dimmer).addClass('active')
397
+ $otherModals.filter('.' + className.active).find(selector.dimmer).addClass('active');
390
398
  }
391
399
 
392
400
  if ( settings.detachable ) {
@@ -439,7 +447,7 @@ $.fn.modal = function(parameters) {
439
447
  module.debug('Hiding modal');
440
448
  if(settings.onHide.call(element, $(this)) === false) {
441
449
  module.verbose('Hide callback returned false cancelling hide');
442
- return;
450
+ return false;
443
451
  }
444
452
 
445
453
  if( module.is.animating() || module.is.active() ) {
@@ -461,15 +469,16 @@ $.fn.modal = function(parameters) {
461
469
  }
462
470
  },
463
471
  onComplete : function() {
472
+ module.unbind.scrollLock();
464
473
  if ( settings.allowMultiple ) {
465
474
  $previousModal.addClass(className.top);
466
475
  $module.removeClass(className.top);
467
476
 
468
477
  if ( hideOthersToo ) {
469
- $allModals.find(selector.dimmer).removeClass('active')
478
+ $allModals.find(selector.dimmer).removeClass('active');
470
479
  }
471
480
  else {
472
- $previousModal.find(selector.dimmer).removeClass('active')
481
+ $previousModal.find(selector.dimmer).removeClass('active');
473
482
  }
474
483
  }
475
484
  settings.onHidden.call(element);
@@ -520,10 +529,17 @@ $.fn.modal = function(parameters) {
520
529
  ;
521
530
  if( $visibleModals.length > 0 ) {
522
531
  module.debug('Hiding all visible modals');
523
- module.hideDimmer();
524
- $visibleModals
525
- .modal('hide modal', callback, false, true)
526
- ;
532
+ var hideOk = true;
533
+ //check in reverse order trying to hide most top displayed modal first
534
+ $($visibleModals.get().reverse()).each(function(index,element){
535
+ if(hideOk){
536
+ hideOk = $(element).modal('hide modal', callback, false, true);
537
+ }
538
+ });
539
+ if(hideOk) {
540
+ module.hideDimmer();
541
+ }
542
+ return hideOk;
527
543
  }
528
544
  },
529
545
 
@@ -790,7 +806,7 @@ $.fn.modal = function(parameters) {
790
806
  },
791
807
  active: function() {
792
808
  $module.addClass(className.active + ' ' + className.top);
793
- $otherModals.filter('.' + className.active).removeClass(className.top)
809
+ $otherModals.filter('.' + className.active).removeClass(className.top);
794
810
  },
795
811
  scrolling: function() {
796
812
  $dimmable.addClass(className.scrolling);
@@ -967,7 +983,7 @@ $.fn.modal = function(parameters) {
967
983
  else if(found !== undefined) {
968
984
  response = found;
969
985
  }
970
- if($.isArray(returnedValue)) {
986
+ if(Array.isArray(returnedValue)) {
971
987
  returnedValue.push(response);
972
988
  }
973
989
  else if(returnedValue !== undefined) {
@@ -12,6 +12,10 @@
12
12
 
13
13
  'use strict';
14
14
 
15
+ $.isFunction = $.isFunction || function(obj) {
16
+ return typeof obj === "function" && typeof obj.nodeType !== "number";
17
+ };
18
+
15
19
  window = (typeof window != 'undefined' && window.Math == Math)
16
20
  ? window
17
21
  : (typeof self != 'undefined' && self.Math == Math)
@@ -405,7 +409,7 @@ $.fn.nag = function(parameters) {
405
409
  else if(found !== undefined) {
406
410
  response = found;
407
411
  }
408
- if($.isArray(returnedValue)) {
412
+ if(Array.isArray(returnedValue)) {
409
413
  returnedValue.push(response);
410
414
  }
411
415
  else if(returnedValue !== undefined) {
@@ -12,6 +12,10 @@
12
12
 
13
13
  'use strict';
14
14
 
15
+ $.isFunction = $.isFunction || function(obj) {
16
+ return typeof obj === "function" && typeof obj.nodeType !== "number";
17
+ };
18
+
15
19
  window = (typeof window != 'undefined' && window.Math == Math)
16
20
  ? window
17
21
  : (typeof self != 'undefined' && self.Math == Math)
@@ -28,7 +32,6 @@ $.fn.popup = function(parameters) {
28
32
 
29
33
  moduleSelector = $allModules.selector || '',
30
34
 
31
- hasTouch = (true),
32
35
  time = new Date().getTime(),
33
36
  performance = [],
34
37
 
@@ -185,7 +188,7 @@ $.fn.popup = function(parameters) {
185
188
  : settings.delay
186
189
  ;
187
190
  clearTimeout(module.hideTimer);
188
- if(!openedWithTouch) {
191
+ if(!openedWithTouch || (openedWithTouch && settings.addTouchEvents) ) {
189
192
  module.showTimer = setTimeout(module.show, delay);
190
193
  }
191
194
  },
@@ -200,7 +203,9 @@ $.fn.popup = function(parameters) {
200
203
  },
201
204
  touchstart: function(event) {
202
205
  openedWithTouch = true;
203
- module.show();
206
+ if(settings.addTouchEvents) {
207
+ module.show();
208
+ }
204
209
  },
205
210
  resize: function() {
206
211
  if( module.is.visible() ) {
@@ -983,7 +988,7 @@ $.fn.popup = function(parameters) {
983
988
  .on('click' + eventNamespace, module.toggle)
984
989
  ;
985
990
  }
986
- if(settings.on == 'hover' && hasTouch) {
991
+ if(settings.on == 'hover') {
987
992
  $module
988
993
  .on('touchstart' + eventNamespace, module.event.touchstart)
989
994
  ;
@@ -1290,7 +1295,7 @@ $.fn.popup = function(parameters) {
1290
1295
  else if(found !== undefined) {
1291
1296
  response = found;
1292
1297
  }
1293
- if($.isArray(returnedValue)) {
1298
+ if(Array.isArray(returnedValue)) {
1294
1299
  returnedValue.push(response);
1295
1300
  }
1296
1301
  else if(returnedValue !== undefined) {
@@ -12,6 +12,10 @@
12
12
 
13
13
  'use strict';
14
14
 
15
+ $.isFunction = $.isFunction || function(obj) {
16
+ return typeof obj === "function" && typeof obj.nodeType !== "number";
17
+ };
18
+
15
19
  window = (typeof window != 'undefined' && window.Math == Math)
16
20
  ? window
17
21
  : (typeof self != 'undefined' && self.Math == Math)
@@ -801,7 +805,7 @@ $.fn.progress = function(parameters) {
801
805
  else if(found !== undefined) {
802
806
  response = found;
803
807
  }
804
- if($.isArray(returnedValue)) {
808
+ if(Array.isArray(returnedValue)) {
805
809
  returnedValue.push(response);
806
810
  }
807
811
  else if(returnedValue !== undefined) {
@@ -12,6 +12,10 @@
12
12
 
13
13
  'use strict';
14
14
 
15
+ $.isFunction = $.isFunction || function(obj) {
16
+ return typeof obj === "function" && typeof obj.nodeType !== "number";
17
+ };
18
+
15
19
  window = (typeof window != 'undefined' && window.Math == Math)
16
20
  ? window
17
21
  : (typeof self != 'undefined' && self.Math == Math)
@@ -103,7 +107,8 @@ $.fn.rating = function(parameters) {
103
107
  layout: function() {
104
108
  var
105
109
  maxRating = module.get.maxRating(),
106
- html = $.fn.rating.settings.templates.icon(maxRating)
110
+ icon = module.get.icon(),
111
+ html = $.fn.rating.settings.templates.icon(maxRating, icon)
107
112
  ;
108
113
  module.debug('Generating icon html dynamically');
109
114
  $module
@@ -211,6 +216,13 @@ $.fn.rating = function(parameters) {
211
216
  },
212
217
 
213
218
  get: {
219
+ icon: function(){
220
+ var icon = $module.data(metadata.icon);
221
+ if (icon) {
222
+ $module.removeData(metadata.icon);
223
+ }
224
+ return icon || settings.icon;
225
+ },
214
226
  initialRating: function() {
215
227
  if($module.data(metadata.rating) !== undefined) {
216
228
  $module.removeData(metadata.rating);
@@ -418,7 +430,7 @@ $.fn.rating = function(parameters) {
418
430
  else if(found !== undefined) {
419
431
  response = found;
420
432
  }
421
- if($.isArray(returnedValue)) {
433
+ if(Array.isArray(returnedValue)) {
422
434
  returnedValue.push(response);
423
435
  }
424
436
  else if(returnedValue !== undefined) {
@@ -456,7 +468,9 @@ $.fn.rating.settings = {
456
468
  name : 'Rating',
457
469
  namespace : 'rating',
458
470
 
459
- slent : false,
471
+ icon : 'star',
472
+
473
+ silent : false,
460
474
  debug : false,
461
475
  verbose : false,
462
476
  performance : true,
@@ -478,7 +492,8 @@ $.fn.rating.settings = {
478
492
 
479
493
  metadata: {
480
494
  rating : 'rating',
481
- maxRating : 'maxRating'
495
+ maxRating : 'maxRating',
496
+ icon : 'icon'
482
497
  },
483
498
 
484
499
  className : {
@@ -493,13 +508,13 @@ $.fn.rating.settings = {
493
508
  },
494
509
 
495
510
  templates: {
496
- icon: function(maxRating) {
511
+ icon: function(maxRating, iconClass) {
497
512
  var
498
513
  icon = 1,
499
514
  html = ''
500
515
  ;
501
516
  while(icon <= maxRating) {
502
- html += '<i class="icon"></i>';
517
+ html += '<i class="'+iconClass+' icon"></i>';
503
518
  icon++;
504
519
  }
505
520
  return html;