fomantic-ui-sass 2.8.4 → 2.8.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +4 -0
  3. data/app/assets/fonts/semantic-ui/brand-icons.eot +0 -0
  4. data/app/assets/fonts/semantic-ui/brand-icons.svg +95 -56
  5. data/app/assets/fonts/semantic-ui/brand-icons.ttf +0 -0
  6. data/app/assets/fonts/semantic-ui/brand-icons.woff +0 -0
  7. data/app/assets/fonts/semantic-ui/brand-icons.woff2 +0 -0
  8. data/app/assets/fonts/semantic-ui/icons.eot +0 -0
  9. data/app/assets/fonts/semantic-ui/icons.svg +121 -88
  10. data/app/assets/fonts/semantic-ui/icons.ttf +0 -0
  11. data/app/assets/fonts/semantic-ui/icons.woff +0 -0
  12. data/app/assets/fonts/semantic-ui/icons.woff2 +0 -0
  13. data/app/assets/fonts/semantic-ui/outline-icons.eot +0 -0
  14. data/app/assets/fonts/semantic-ui/outline-icons.svg +10 -10
  15. data/app/assets/fonts/semantic-ui/outline-icons.ttf +0 -0
  16. data/app/assets/fonts/semantic-ui/outline-icons.woff +0 -0
  17. data/app/assets/fonts/semantic-ui/outline-icons.woff2 +0 -0
  18. data/app/assets/javascripts/semantic-ui/calendar.js +41 -36
  19. data/app/assets/javascripts/semantic-ui/dropdown.js +8 -5
  20. data/app/assets/javascripts/semantic-ui/form.js +4 -10
  21. data/app/assets/javascripts/semantic-ui/popup.js +6 -5
  22. data/app/assets/javascripts/semantic-ui/search.js +27 -0
  23. data/app/assets/javascripts/semantic-ui/tab.js +3 -2
  24. data/app/assets/javascripts/semantic-ui/visibility.js +1 -1
  25. data/app/assets/stylesheets/semantic-ui/collections/_form.scss +24 -24
  26. data/app/assets/stylesheets/semantic-ui/elements/_button.scss +9 -3
  27. data/app/assets/stylesheets/semantic-ui/elements/_icon.scss +112 -15
  28. data/app/assets/stylesheets/semantic-ui/elements/_input.scss +16 -16
  29. data/app/assets/stylesheets/semantic-ui/elements/_step.scss +7 -0
  30. data/app/assets/stylesheets/semantic-ui/modules/_dropdown.scss +6 -7
  31. data/app/assets/stylesheets/semantic-ui/modules/_modal.scss +3 -3
  32. data/app/assets/stylesheets/semantic-ui/modules/_progress.scss +32 -3
  33. data/app/assets/stylesheets/semantic-ui/modules/_search.scss +90 -0
  34. data/lib/fomantic/ui/sass/version.rb +2 -2
  35. metadata +1 -1
@@ -1,12 +1,12 @@
1
1
  <?xml version="1.0" standalone="no"?>
2
2
  <!--
3
- Font Awesome Free 5.11.2 by @fontawesome - https://fontawesome.com
3
+ Font Awesome Free 5.12.0 by @fontawesome - https://fontawesome.com
4
4
  License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
5
5
  -->
6
6
  <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
7
7
  <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1">
8
8
  <metadata>
9
- Created by FontForge 20190801 at Mon Sep 23 12:53:49 2019
9
+ Created by FontForge 20190801 at Tue Dec 10 16:09:21 2019
10
10
  By Robert Madole
11
11
  Copyright (c) Font Awesome
12
12
  </metadata>
@@ -435,14 +435,14 @@ c-44.1123 0 -80 35.8877 -80 80v8c0 30.8779 25.1211 56 56 56h293.917c24.5 0 47.08
435
435
  c-4.41113 0 -8 -3.58887 -8 -8v-8c0 -17.6445 14.3555 -32 32 -32h213.471c25.2021 0 42.626 -25.293 33.6299 -48.8457l-24.5518 -64.2812c-7.05371 -18.4658 -25.0732 -30.873 -44.8398 -30.873h-113.709c-22.0557 0 -40 -17.9443 -40 -40c0 -4.41113 3.58887 -8 8 -8
436
436
  h131.552h0.0517578c7.44141 0 19.1074 -2.19238 26.041 -4.89355l99.752 -38.7881c18.5898 -7.22852 30.6035 -24.7881 30.6035 -44.7363v-23.582h128z" />
437
437
  <glyph glyph-name="hand-spock" unicode="&#xf259;"
438
- d="M21.0957 66.21c-26.9688 25.3818 -28.2471 67.7461 -2.87109 94.707c24.1982 25.7139 64.2881 28.2373 91.4824 5.72168l-31.04 136.509c-9.38379 41.2803 21.4336 81.0127 64.0713 81.8438c1.74414 28.9062 22.2656 54.4912 51.8818 61.2949
439
- c36.001 8.27539 72.0176 -14.2266 80.3037 -50.2959l21.6748 -131.99l16.9014 105.25c9.02344 36.0947 45.4473 57.7021 81.25 48.75c27.3066 -6.82715 45.7061 -29.1357 49.8496 -53.9922c43.2285 0.212891 75.6436 -40.1133 65.5439 -82.5244l-31.7295 -133.41
440
- c-0.938477 -3.94141 -1.41406 -7.99414 -1.41406 -12.0449v-36.8389v-0.00683594c0 -9.29102 -2.14355 -24.0596 -4.78516 -32.9668l-31.8145 -107.312c-4.02734 -13.585 -16.5107 -22.9043 -30.6807 -22.9043h-237.6c-7.00586 0 -16.8311 3.89648 -21.9316 8.69824z
441
- M53.1641 128.021c-7.17969 -7.62891 -6.81543 -19.6777 0.813477 -26.8574l124.487 -117.164h219.311l28.4199 95.8613c1.86133 6.27637 2.80469 12.7793 2.80469 19.3281v36.8389c0.000976562 6.48047 1.21973 16.8574 2.71973 23.1621l31.7549 133.407
442
- c5.83105 24.4893 -31.1445 33.25 -36.9658 8.80273l-26.9229 -113.105c-1.61523 -6.78711 -8.58887 -12.2949 -15.5645 -12.2949h-9.69434c-10.4072 0 -18.043 9.79199 -15.5225 19.8799l38.127 152.512c6.09766 24.376 -30.7607 33.6396 -36.8643 9.21777l-42.3721 -169.49
443
- c-1.67285 -6.68945 -8.62695 -12.1191 -15.5225 -12.1191h-13.2168v0c-7.0332 0 -14.0195 5.5625 -15.5938 12.417l-45.2207 196.828c-5.64453 24.5684 -42.6572 15.9609 -37.0342 -8.50781l41.6191 -181.153c2.30078 -10.0156 -5.31738 -19.583 -15.5938 -19.583h-8.60352
444
- h-0.000976562c-7.0498 0 -14.04 5.5791 -15.6025 12.4541l-30.3984 133.757c-5.55273 24.4395 -42.6504 16.1963 -37.0547 -8.4209l34.1299 -150.172c0.263672 -1.16309 0.397461 -2.35352 0.397461 -3.5459v-69.4795c0 -13.9941 -16.7754 -21.2432 -26.9658 -11.6523
445
- l-53.0117 49.8936c-7.61523 7.16699 -19.6377 6.85938 -26.8564 -0.8125z" />
438
+ d="M501.03 331.824c6.05762 -9.77832 10.9746 -27.0498 10.9746 -38.5518c0 -4.80664 -0.915039 -12.499 -2.04297 -17.1709l-57.623 -241.963c-12.748 -54.1729 -68.2627 -98.1387 -123.915 -98.1387h-0.345703h-107.455h-0.224609
439
+ c-33.8135 0 -81.2148 18.834 -105.807 42.041l-91.3652 85.9766c-12.8213 12.0469 -23.2266 36.1016 -23.2266 53.6943c0 16.1299 8.97266 38.7529 20.0273 50.499c5.31836 5.66406 29.875 29.3926 68.1152 21.8477l-24.3594 82.1973
440
+ c-1.68164 5.66406 -3.0459 15.0576 -3.0459 20.9668c0 37.5938 30.417 70.502 67.8955 73.4551c-0.204102 2.03125 -0.369141 5.33691 -0.369141 7.37891c0 31.627 24.8594 63.6895 55.4902 71.5684c43.248 10.9785 80.5645 -17.7012 89.6602 -53.0723l13.6836 -53.207
441
+ l4.64648 22.6602c6.76074 32.417 39.123 58.8115 72.2373 58.916c8.73438 0 56.625 -3.26953 70.7383 -54.0801c15.0664 0.710938 46.9199 -3.50977 66.3105 -35.0176zM463.271 287.219c7.86914 32.9844 -42.1211 45.2695 -50.0859 11.9219l-24.8008 -104.146
442
+ c-4.38867 -18.4141 -31.7783 -11.8926 -28.0557 6.2168l28.5479 139.166c7.39844 36.0703 -43.3076 45.0703 -50.1182 11.9629l-31.791 -154.971c-3.54883 -17.3086 -28.2832 -18.0469 -32.7109 -0.804688l-47.3262 184.035
443
+ c-8.43359 32.8105 -58.3691 20.2676 -49.8652 -12.8359l42.4414 -165.039c4.81641 -18.7207 -23.3711 -26.9121 -28.9648 -8.00781l-31.3438 105.779c-9.6875 32.6465 -59.1191 18.2578 -49.3867 -14.625l36.0137 -121.539
444
+ c5.61816 -18.9521 10.1777 -50.377 10.1777 -70.1436v-0.00878906c0 -6.54297 -8.05664 -10.9355 -13.4824 -5.82617l-51.123 48.1074c-24.7852 23.4082 -60.0527 -14.1875 -35.2793 -37.4902l91.3691 -85.9805c16.9629 -16.0068 49.6592 -28.998 72.9824 -28.998h0.154297
445
+ h107.455h0.216797c34.7402 0 69.3936 27.4443 77.3525 61.2598z" />
446
446
  <glyph glyph-name="hand-pointer" unicode="&#xf25a;" horiz-adv-x="448"
447
447
  d="M358.182 268.639c43.1934 16.6348 89.8184 -15.7949 89.8184 -62.6387v-84c-0.000976562 -4.25 -0.775391 -11.0615 -1.72754 -15.2041l-27.4297 -118.999c-6.98242 -30.2969 -33.7549 -51.7969 -64.5566 -51.7969h-178.286c-21.2588 0 -41.3682 10.4102 -53.791 27.8457
448
448
  l-109.699 154.001c-21.2432 29.8193 -14.8047 71.3574 14.5498 93.1523c18.8115 13.9658 42.1748 16.2822 62.083 8.87207v161.129c0 36.9443 29.7363 67 66.2861 67s66.2861 -30.0557 66.2861 -67v-73.6338c20.4131 2.85742 41.4678 -3.94238 56.5947 -19.6289
@@ -116,6 +116,7 @@ $.fn.calendar = function(parameters) {
116
116
  module.set.maxDate($module.data(metadata.maxDate));
117
117
  }
118
118
  module.setting('type', module.get.type());
119
+ module.setting('on', settings.on || ($input.length ? 'focus' : 'click'));
119
120
  },
120
121
  popup: function () {
121
122
  if (settings.inline) {
@@ -159,7 +160,7 @@ $.fn.calendar = function(parameters) {
159
160
  module.set.mode(settings.startMode);
160
161
  return settings.onShow.apply($container, arguments);
161
162
  };
162
- var on = settings.on || ($input.length ? 'focus' : 'click');
163
+ var on = module.setting('on');
163
164
  var options = $.extend({}, settings.popupOptions, {
164
165
  popup: $container,
165
166
  on: on,
@@ -202,33 +203,38 @@ $.fn.calendar = function(parameters) {
202
203
  calendar: function () {
203
204
  var i, r, c, p, row, cell, pageGrid;
204
205
 
205
- var mode = module.get.mode();
206
- var today = new Date();
207
- var date = module.get.date();
208
- var focusDate = module.get.focusDate();
209
- var display = focusDate || date || settings.initialDate || today;
210
- display = module.helper.dateInRange(display);
206
+ var
207
+ mode = module.get.mode(),
208
+ today = new Date(),
209
+ date = module.get.date(),
210
+ focusDate = module.get.focusDate(),
211
+ display = module.helper.dateInRange(focusDate || date || settings.initialDate || today)
212
+ ;
211
213
 
212
214
  if (!focusDate) {
213
215
  focusDate = display;
214
216
  module.set.focusDate(focusDate, false, false);
215
217
  }
216
218
 
217
- var isYear = mode === 'year';
218
- var isMonth = mode === 'month';
219
- var isDay = mode === 'day';
220
- var isHour = mode === 'hour';
221
- var isMinute = mode === 'minute';
222
- var isTimeOnly = settings.type === 'time';
219
+ var
220
+ isYear = mode === 'year',
221
+ isMonth = mode === 'month',
222
+ isDay = mode === 'day',
223
+ isHour = mode === 'hour',
224
+ isMinute = mode === 'minute',
225
+ isTimeOnly = settings.type === 'time'
226
+ ;
223
227
 
224
228
  var multiMonth = Math.max(settings.multiMonth, 1);
225
229
  var monthOffset = !isDay ? 0 : module.get.monthOffset();
226
230
 
227
- var minute = display.getMinutes();
228
- var hour = display.getHours();
229
- var day = display.getDate();
230
- var startMonth = display.getMonth() + monthOffset;
231
- var year = display.getFullYear();
231
+ var
232
+ minute = display.getMinutes(),
233
+ hour = display.getHours(),
234
+ day = display.getDate(),
235
+ startMonth = display.getMonth() + monthOffset,
236
+ year = display.getFullYear()
237
+ ;
232
238
 
233
239
  var columns = isDay ? settings.showWeekNumbers ? 8 : 7 : isHour ? 4 : timeGap['column'];
234
240
  var rows = isDay || isHour ? 6 : timeGap['row'];
@@ -254,17 +260,18 @@ $.fn.calendar = function(parameters) {
254
260
  rows = Math.ceil(requiredCells / 7);
255
261
  }
256
262
 
257
- var yearChange = isYear ? 10 : isMonth ? 1 : 0;
258
- var monthChange = isDay ? 1 : 0;
259
- var dayChange = isHour || isMinute ? 1 : 0;
260
- var prevNextDay = isHour || isMinute ? day : 1;
261
- var prevDate = new Date(year - yearChange, month - monthChange, prevNextDay - dayChange, hour);
262
- var nextDate = new Date(year + yearChange, month + monthChange, prevNextDay + dayChange, hour);
263
-
264
- var prevLast = isYear ? new Date(Math.ceil(year / 10) * 10 - 9, 0, 0) :
265
- isMonth ? new Date(year, 0, 0) : isDay ? new Date(year, month, 0) : new Date(year, month, day, -1);
266
- var nextFirst = isYear ? new Date(Math.ceil(year / 10) * 10 + 1, 0, 1) :
267
- isMonth ? new Date(year + 1, 0, 1) : isDay ? new Date(year, month + 1, 1) : new Date(year, month, day + 1);
263
+ var
264
+ yearChange = isYear ? 10 : isMonth ? 1 : 0,
265
+ monthChange = isDay ? 1 : 0,
266
+ dayChange = isHour || isMinute ? 1 : 0,
267
+ prevNextDay = isHour || isMinute ? day : 1,
268
+ prevDate = new Date(year - yearChange, month - monthChange, prevNextDay - dayChange, hour),
269
+ nextDate = new Date(year + yearChange, month + monthChange, prevNextDay + dayChange, hour),
270
+ prevLast = isYear ? new Date(Math.ceil(year / 10) * 10 - 9, 0, 0) :
271
+ isMonth ? new Date(year, 0, 0) : isDay ? new Date(year, month, 0) : new Date(year, month, day, -1),
272
+ nextFirst = isYear ? new Date(Math.ceil(year / 10) * 10 + 1, 0, 1) :
273
+ isMonth ? new Date(year + 1, 0, 1) : isDay ? new Date(year, month + 1, 1) : new Date(year, month, day + 1)
274
+ ;
268
275
 
269
276
  var tempMode = mode;
270
277
  if (isDay && settings.showWeekNumbers){
@@ -440,7 +447,6 @@ $.fn.calendar = function(parameters) {
440
447
  $input.on('input' + eventNamespace, module.event.inputChange);
441
448
  $input.on('focus' + eventNamespace, module.event.inputFocus);
442
449
  $input.on('blur' + eventNamespace, module.event.inputBlur);
443
- $input.on('click' + eventNamespace, module.event.inputClick);
444
450
  $input.on('keydown' + eventNamespace, module.event.keydown);
445
451
  } else {
446
452
  $container.on('keydown' + eventNamespace, module.event.keydown);
@@ -569,9 +575,6 @@ $.fn.calendar = function(parameters) {
569
575
  var text = formatter.datetime(date, settings);
570
576
  $input.val(text);
571
577
  }
572
- },
573
- inputClick: function () {
574
- module.popup('show');
575
578
  }
576
579
  },
577
580
 
@@ -796,10 +799,12 @@ $.fn.calendar = function(parameters) {
796
799
  var canceled = module.set.date(date) === false;
797
800
  if (!canceled && settings.closable) {
798
801
  module.popup('hide');
799
- //if this is a range calendar, show the end date calendar popup and focus the input
802
+ //if this is a range calendar, focus the container or input. This will open the popup from its event listeners.
800
803
  var endModule = module.get.calendarModule(settings.endCalendar);
801
804
  if (endModule) {
802
- endModule.popup('show');
805
+ if (endModule.setting('on') !== 'focus') {
806
+ endModule.popup('show');
807
+ }
803
808
  endModule.focus();
804
809
  }
805
810
  }
@@ -809,7 +814,7 @@ $.fn.calendar = function(parameters) {
809
814
  module.set.mode(newMode);
810
815
  if (mode === 'hour' || (mode === 'day' && module.get.date())) {
811
816
  //the user has chosen enough to consider a valid date/time has been chosen
812
- module.set.date(date);
817
+ module.set.date(date, true, false);
813
818
  } else {
814
819
  module.set.focusDate(date);
815
820
  }
@@ -117,7 +117,9 @@ $.fn.dropdown = function(parameters) {
117
117
  module.setup.layout();
118
118
 
119
119
  if(settings.values) {
120
+ module.set.initialLoad();
120
121
  module.change.values(settings.values);
122
+ module.remove.initialLoad();
121
123
  }
122
124
 
123
125
  module.refreshData();
@@ -541,6 +543,7 @@ $.fn.dropdown = function(parameters) {
541
543
  } else if( module.can.click() ) {
542
544
  module.unbind.intent();
543
545
  }
546
+ iconClicked = false;
544
547
  },
545
548
 
546
549
  hideOthers: function() {
@@ -1772,7 +1775,7 @@ $.fn.dropdown = function(parameters) {
1772
1775
  return $text.text();
1773
1776
  },
1774
1777
  query: function() {
1775
- return $.trim($search.val());
1778
+ return String($search.val()).trim();
1776
1779
  },
1777
1780
  searchWidth: function(value) {
1778
1781
  value = (value !== undefined)
@@ -1915,8 +1918,8 @@ $.fn.dropdown = function(parameters) {
1915
1918
  return ($choice.data(metadata.text) !== undefined)
1916
1919
  ? $choice.data(metadata.text)
1917
1920
  : (preserveHTML)
1918
- ? $.trim($choice.html())
1919
- : $.trim($choice.text())
1921
+ ? $choice.html().trim()
1922
+ : $choice.text().trim()
1920
1923
  ;
1921
1924
  }
1922
1925
  },
@@ -1928,11 +1931,11 @@ $.fn.dropdown = function(parameters) {
1928
1931
  return ($choice.data(metadata.value) !== undefined)
1929
1932
  ? String( $choice.data(metadata.value) )
1930
1933
  : (typeof choiceText === 'string')
1931
- ? $.trim(
1934
+ ? String(
1932
1935
  settings.ignoreSearchCase
1933
1936
  ? choiceText.toLowerCase()
1934
1937
  : choiceText
1935
- )
1938
+ ).trim()
1936
1939
  : String(choiceText)
1937
1940
  ;
1938
1941
  },
@@ -336,7 +336,7 @@ $.fn.form = function(parameters) {
336
336
  }
337
337
  },
338
338
  blank: function($field) {
339
- return $.trim($field.val()) === '';
339
+ return String($field.val()).trim() === '';
340
340
  },
341
341
  valid: function(field) {
342
342
  var
@@ -1128,7 +1128,7 @@ $.fn.form = function(parameters) {
1128
1128
  $elGroup = $(el).closest($group),
1129
1129
  isCheckbox = ($el.filter(selector.checkbox).length > 0),
1130
1130
  isRequired = $el.prop('required') || $elGroup.hasClass(className.required) || $elGroup.parent().hasClass(className.required),
1131
- isDisabled = $el.prop('disabled') || $elGroup.hasClass(className.disabled) || $elGroup.parent().hasClass(className.disabled),
1131
+ isDisabled = $el.is(':disabled') || $elGroup.hasClass(className.disabled) || $elGroup.parent().hasClass(className.disabled),
1132
1132
  validation = module.get.validation($el),
1133
1133
  hasEmptyRule = validation
1134
1134
  ? $.grep(validation.rules, function(rule) { return rule.type == "empty" }) !== 0
@@ -1207,13 +1207,7 @@ $.fn.form = function(parameters) {
1207
1207
  module.debug('Using field name as identifier', identifier);
1208
1208
  field.identifier = identifier;
1209
1209
  }
1210
- var isDisabled = true;
1211
- $.each($field, function(){
1212
- if(!$(this).prop('disabled')) {
1213
- isDisabled = false;
1214
- return false;
1215
- }
1216
- });
1210
+ var isDisabled = !$field.filter(':not(:disabled)').length;
1217
1211
  if(isDisabled) {
1218
1212
  module.debug('Field is disabled. Skipping', identifier);
1219
1213
  }
@@ -1270,7 +1264,7 @@ $.fn.form = function(parameters) {
1270
1264
  // cast to string avoiding encoding special values
1271
1265
  value = (value === undefined || value === '' || value === null)
1272
1266
  ? ''
1273
- : (settings.shouldTrim) ? $.trim(value + '') : String(value + '')
1267
+ : (settings.shouldTrim) ? String(value + '').trim() : String(value + '')
1274
1268
  ;
1275
1269
  return ruleFunction.call(field, value, ancillary, $module);
1276
1270
  }
@@ -510,9 +510,10 @@ $.fn.popup = function(parameters) {
510
510
  $popupOffsetParent = module.get.offsetParent($popup),
511
511
  targetElement = $target[0],
512
512
  isWindow = ($boundary[0] == window),
513
- targetPosition = (settings.inline || (settings.popup && settings.movePopup))
514
- ? $target.position()
515
- : $target.offset(),
513
+ targetOffset = $target.offset(),
514
+ parentOffset = settings.inline || (settings.popup && settings.movePopup)
515
+ ? $target.offsetParent().offset()
516
+ : { top: 0, left: 0 },
516
517
  screenPosition = (isWindow)
517
518
  ? { top: 0, left: 0 }
518
519
  : $boundary.offset(),
@@ -528,8 +529,8 @@ $.fn.popup = function(parameters) {
528
529
  element : $target[0],
529
530
  width : $target.outerWidth(),
530
531
  height : $target.outerHeight(),
531
- top : targetPosition.top,
532
- left : targetPosition.left,
532
+ top : targetOffset.top - parentOffset.top,
533
+ left : targetOffset.left - parentOffset.left,
533
534
  margin : {}
534
535
  },
535
536
  // popup itself
@@ -250,6 +250,25 @@ $.fn.search = function(parameters) {
250
250
  }
251
251
  }
252
252
  },
253
+ ensureVisible: function ensureVisible($el) {
254
+ var elTop, elBottom, resultsScrollTop, resultsHeight;
255
+
256
+ elTop = $el.position().top;
257
+ elBottom = elTop + $el.outerHeight(true);
258
+
259
+ resultsScrollTop = $results.scrollTop();
260
+ resultsHeight = $results.height()
261
+ parseInt($results.css('paddingTop'), 0) +
262
+ parseInt($results.css('paddingBottom'), 0);
263
+
264
+ if (elTop < 0) {
265
+ $results.scrollTop(resultsScrollTop + elTop);
266
+ }
267
+
268
+ else if (resultsHeight < elBottom) {
269
+ $results.scrollTop(resultsScrollTop + (elBottom - resultsHeight));
270
+ }
271
+ },
253
272
  handleKeyboard: function(event) {
254
273
  var
255
274
  // force selector refresh
@@ -301,6 +320,7 @@ $.fn.search = function(parameters) {
301
320
  .closest($category)
302
321
  .addClass(className.active)
303
322
  ;
323
+ module.ensureVisible($result.eq(newIndex));
304
324
  event.preventDefault();
305
325
  }
306
326
  else if(keyCode == keys.downArrow) {
@@ -319,6 +339,7 @@ $.fn.search = function(parameters) {
319
339
  .closest($category)
320
340
  .addClass(className.active)
321
341
  ;
342
+ module.ensureVisible($result.eq(newIndex));
322
343
  event.preventDefault();
323
344
  }
324
345
  }
@@ -952,6 +973,12 @@ $.fn.search = function(parameters) {
952
973
  debug : settings.debug,
953
974
  verbose : settings.verbose,
954
975
  duration : settings.duration,
976
+ onShow : function() {
977
+ var $firstResult = $module.find(selector.result).eq(0);
978
+ if($firstResult.length > 0) {
979
+ module.ensureVisible($firstResult);
980
+ }
981
+ },
955
982
  onComplete : function() {
956
983
  callback();
957
984
  },
@@ -100,9 +100,9 @@ $.fn.tab = function(parameters) {
100
100
  initializedHistory = true;
101
101
  }
102
102
 
103
- if(instance === undefined && module.determine.activeTab() == null) {
103
+ if(settings.autoTabActivation && instance === undefined && module.determine.activeTab() == null) {
104
104
  module.debug('No active tab detected, setting first tab active', module.get.initialPath());
105
- module.changeTab(module.get.initialPath());
105
+ module.changeTab(settings.autoTabActivation === true ? module.get.initialPath() : settings.autoTabActivation);
106
106
  };
107
107
 
108
108
  module.instantiate();
@@ -953,6 +953,7 @@ $.fn.tab.settings = {
953
953
 
954
954
  apiSettings : false, // settings for api call
955
955
  evaluateScripts : 'once', // whether inline scripts should be parsed (true/false/once). Once will not re-evaluate on cached content
956
+ autoTabActivation: true, // whether a non existing active tab will auto activate the first available tab
956
957
 
957
958
  onFirstLoad : function(tabPath, parameterArray, historyEvent) {}, // called first time loaded
958
959
  onLoad : function(tabPath, parameterArray, historyEvent) {}, // called on every load
@@ -902,7 +902,7 @@ $.fn.visibility = function(parameters) {
902
902
  element.offset.top += $context.scrollTop() - $context.offset().top;
903
903
  }
904
904
  if(module.is.horizontallyScrollableContext()) {
905
- element.offset.left += $context.scrollLeft - $context.offset().left;
905
+ element.offset.left += $context.scrollLeft() - $context.offset().left;
906
906
  }
907
907
  // store
908
908
  module.cache.element = element;
@@ -406,33 +406,33 @@
406
406
  -webkit-box-shadow: 0 0 0 0 rgba(34, 36, 38, 0.35) inset;
407
407
  box-shadow: 0 0 0 0 rgba(34, 36, 38, 0.35) inset;
408
408
  }
409
- .ui.form .ui.action.input:not(.left) input:not([type]):focus,
410
- .ui.form .ui.action.input:not(.left) input[type="date"]:focus,
411
- .ui.form .ui.action.input:not(.left) input[type="datetime-local"]:focus,
412
- .ui.form .ui.action.input:not(.left) input[type="email"]:focus,
413
- .ui.form .ui.action.input:not(.left) input[type="number"]:focus,
414
- .ui.form .ui.action.input:not(.left) input[type="password"]:focus,
415
- .ui.form .ui.action.input:not(.left) input[type="search"]:focus,
416
- .ui.form .ui.action.input:not(.left) input[type="tel"]:focus,
417
- .ui.form .ui.action.input:not(.left) input[type="time"]:focus,
418
- .ui.form .ui.action.input:not(.left) input[type="text"]:focus,
419
- .ui.form .ui.action.input:not(.left) input[type="file"]:focus,
420
- .ui.form .ui.action.input:not(.left) input[type="url"]:focus {
409
+ .ui.form .ui.action.input:not([class*="left action"]) input:not([type]):focus,
410
+ .ui.form .ui.action.input:not([class*="left action"]) input[type="date"]:focus,
411
+ .ui.form .ui.action.input:not([class*="left action"]) input[type="datetime-local"]:focus,
412
+ .ui.form .ui.action.input:not([class*="left action"]) input[type="email"]:focus,
413
+ .ui.form .ui.action.input:not([class*="left action"]) input[type="number"]:focus,
414
+ .ui.form .ui.action.input:not([class*="left action"]) input[type="password"]:focus,
415
+ .ui.form .ui.action.input:not([class*="left action"]) input[type="search"]:focus,
416
+ .ui.form .ui.action.input:not([class*="left action"]) input[type="tel"]:focus,
417
+ .ui.form .ui.action.input:not([class*="left action"]) input[type="time"]:focus,
418
+ .ui.form .ui.action.input:not([class*="left action"]) input[type="text"]:focus,
419
+ .ui.form .ui.action.input:not([class*="left action"]) input[type="file"]:focus,
420
+ .ui.form .ui.action.input:not([class*="left action"]) input[type="url"]:focus {
421
421
  border-top-right-radius: 0;
422
422
  border-bottom-right-radius: 0;
423
423
  }
424
- .ui.form .ui.action.input.left input:not([type]),
425
- .ui.form .ui.action.input.left input[type="date"],
426
- .ui.form .ui.action.input.left input[type="datetime-local"],
427
- .ui.form .ui.action.input.left input[type="email"],
428
- .ui.form .ui.action.input.left input[type="number"],
429
- .ui.form .ui.action.input.left input[type="password"],
430
- .ui.form .ui.action.input.left input[type="search"],
431
- .ui.form .ui.action.input.left input[type="tel"],
432
- .ui.form .ui.action.input.left input[type="time"],
433
- .ui.form .ui.action.input.left input[type="text"],
434
- .ui.form .ui.action.input.left input[type="file"],
435
- .ui.form .ui.action.input.left input[type="url"] {
424
+ .ui.form .ui[class*="left action"].input input:not([type]),
425
+ .ui.form .ui[class*="left action"].input input[type="date"],
426
+ .ui.form .ui[class*="left action"].input input[type="datetime-local"],
427
+ .ui.form .ui[class*="left action"].input input[type="email"],
428
+ .ui.form .ui[class*="left action"].input input[type="number"],
429
+ .ui.form .ui[class*="left action"].input input[type="password"],
430
+ .ui.form .ui[class*="left action"].input input[type="search"],
431
+ .ui.form .ui[class*="left action"].input input[type="tel"],
432
+ .ui.form .ui[class*="left action"].input input[type="time"],
433
+ .ui.form .ui[class*="left action"].input input[type="text"],
434
+ .ui.form .ui[class*="left action"].input input[type="file"],
435
+ .ui.form .ui[class*="left action"].input input[type="url"] {
436
436
  border-bottom-left-radius: 0;
437
437
  border-top-left-radius: 0;
438
438
  }