fomantic-ui 2.9.1-beta.24 → 2.9.1-beta.26
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.
- package/.eslint/eqeqeq-rule.js +18 -0
- package/.eslint/index.js +3 -0
- package/.eslintrc.js +1 -2
- package/.stylelintrc.js +8 -12
- package/dist/components/accordion.css +3 -3
- package/dist/components/accordion.js +4 -4
- package/dist/components/accordion.min.css +2 -2
- package/dist/components/accordion.min.js +2 -2
- package/dist/components/ad.css +1 -1
- package/dist/components/ad.min.css +1 -1
- package/dist/components/api.js +19 -19
- package/dist/components/api.min.js +2 -2
- package/dist/components/breadcrumb.css +1 -1
- package/dist/components/breadcrumb.min.css +1 -1
- package/dist/components/button.css +5 -5
- package/dist/components/button.min.css +2 -2
- package/dist/components/calendar.css +1 -1
- package/dist/components/calendar.js +18 -17
- package/dist/components/calendar.min.css +1 -1
- package/dist/components/calendar.min.js +2 -2
- package/dist/components/card.css +4 -4
- package/dist/components/card.min.css +2 -2
- package/dist/components/checkbox.css +3 -3
- package/dist/components/checkbox.js +11 -11
- package/dist/components/checkbox.min.css +1 -1
- package/dist/components/checkbox.min.js +2 -2
- package/dist/components/comment.css +1 -1
- package/dist/components/comment.min.css +1 -1
- package/dist/components/container.css +2 -2
- package/dist/components/container.min.css +2 -2
- package/dist/components/dimmer.css +2 -2
- package/dist/components/dimmer.js +9 -9
- package/dist/components/dimmer.min.css +1 -1
- package/dist/components/dimmer.min.js +2 -2
- package/dist/components/divider.css +1 -1
- package/dist/components/divider.min.css +1 -1
- package/dist/components/dropdown.css +13 -13
- package/dist/components/dropdown.js +103 -91
- package/dist/components/dropdown.min.css +2 -2
- package/dist/components/dropdown.min.js +2 -2
- package/dist/components/embed.css +1 -1
- package/dist/components/embed.js +5 -5
- package/dist/components/embed.min.css +1 -1
- package/dist/components/embed.min.js +2 -2
- package/dist/components/emoji.css +3547 -3547
- package/dist/components/feed.css +1 -1
- package/dist/components/feed.min.css +1 -1
- package/dist/components/flag.css +265 -265
- package/dist/components/flag.min.css +1 -1
- package/dist/components/flyout.css +7 -7
- package/dist/components/flyout.js +10 -10
- package/dist/components/flyout.min.css +1 -1
- package/dist/components/flyout.min.js +2 -2
- package/dist/components/form.css +13 -13
- package/dist/components/form.js +77 -60
- package/dist/components/form.min.css +2 -2
- package/dist/components/form.min.js +2 -2
- package/dist/components/grid.css +2 -2
- package/dist/components/grid.min.css +2 -2
- package/dist/components/header.css +2 -2
- package/dist/components/header.min.css +2 -2
- package/dist/components/icon.css +1960 -1960
- package/dist/components/icon.min.css +2 -2
- package/dist/components/image.css +1 -1
- package/dist/components/image.min.css +1 -1
- package/dist/components/input.css +2 -2
- package/dist/components/input.min.css +2 -2
- package/dist/components/item.css +3 -3
- package/dist/components/item.min.css +2 -2
- package/dist/components/label.css +2 -2
- package/dist/components/label.min.css +2 -2
- package/dist/components/list.css +4 -4
- package/dist/components/list.min.css +2 -2
- package/dist/components/loader.css +1 -1
- package/dist/components/loader.min.css +1 -1
- package/dist/components/menu.css +2 -2
- package/dist/components/menu.min.css +1 -1
- package/dist/components/message.css +2 -2
- package/dist/components/message.min.css +2 -2
- package/dist/components/modal.css +2 -2
- package/dist/components/modal.js +4 -4
- package/dist/components/modal.min.css +2 -2
- package/dist/components/modal.min.js +2 -2
- package/dist/components/nag.css +1 -1
- package/dist/components/nag.js +5 -5
- package/dist/components/nag.min.css +1 -1
- package/dist/components/nag.min.js +2 -2
- package/dist/components/placeholder.css +1 -1
- package/dist/components/placeholder.min.css +1 -1
- package/dist/components/popup.css +2 -2
- package/dist/components/popup.js +39 -31
- package/dist/components/popup.min.css +2 -2
- package/dist/components/popup.min.js +2 -2
- package/dist/components/progress.css +1 -1
- package/dist/components/progress.js +12 -12
- package/dist/components/progress.min.css +1 -1
- package/dist/components/progress.min.js +2 -2
- package/dist/components/rail.css +1 -1
- package/dist/components/rail.min.css +1 -1
- package/dist/components/rating.css +31 -31
- package/dist/components/rating.js +6 -6
- package/dist/components/rating.min.css +1 -1
- package/dist/components/rating.min.js +2 -2
- package/dist/components/reset.css +1 -1
- package/dist/components/reset.min.css +1 -1
- package/dist/components/reveal.css +13 -13
- package/dist/components/reveal.min.css +1 -1
- package/dist/components/search.css +4 -4
- package/dist/components/search.js +16 -16
- package/dist/components/search.min.css +2 -2
- package/dist/components/search.min.js +2 -2
- package/dist/components/segment.css +2 -2
- package/dist/components/segment.min.css +2 -2
- package/dist/components/shape.css +1 -1
- package/dist/components/shape.js +5 -5
- package/dist/components/shape.min.css +1 -1
- package/dist/components/shape.min.js +2 -2
- package/dist/components/sidebar.css +33 -33
- package/dist/components/sidebar.js +13 -13
- package/dist/components/sidebar.min.css +1 -1
- package/dist/components/sidebar.min.js +2 -2
- package/dist/components/site.css +18 -18
- package/dist/components/site.js +4 -4
- package/dist/components/site.min.css +2 -2
- package/dist/components/site.min.js +2 -2
- package/dist/components/slider.js +50 -37
- package/dist/components/slider.min.js +2 -2
- package/dist/components/state.js +5 -5
- package/dist/components/state.min.js +2 -2
- package/dist/components/statistic.css +3 -3
- package/dist/components/statistic.min.css +2 -2
- package/dist/components/step.css +4 -4
- package/dist/components/step.min.css +2 -2
- package/dist/components/sticky.css +1 -1
- package/dist/components/sticky.js +8 -8
- package/dist/components/sticky.min.css +1 -1
- package/dist/components/sticky.min.js +2 -2
- package/dist/components/tab.css +1 -1
- package/dist/components/tab.js +17 -17
- package/dist/components/tab.min.css +1 -1
- package/dist/components/tab.min.js +2 -2
- package/dist/components/table.css +8 -2
- package/dist/components/table.min.css +1 -1
- package/dist/components/text.css +1 -1
- package/dist/components/text.min.css +1 -1
- package/dist/components/toast.css +1 -1
- package/dist/components/toast.js +4 -4
- package/dist/components/toast.min.css +1 -1
- package/dist/components/toast.min.js +2 -2
- package/dist/components/transition.css +97 -97
- package/dist/components/transition.js +8 -8
- package/dist/components/transition.min.css +1 -1
- package/dist/components/transition.min.js +2 -2
- package/dist/components/visibility.js +12 -12
- package/dist/components/visibility.min.js +2 -2
- package/dist/semantic.css +6078 -6074
- package/dist/semantic.js +464 -413
- package/dist/semantic.min.css +2 -2
- package/dist/semantic.min.js +2 -2
- package/package.json +1 -1
- package/src/_site/modules/embed.variables +3 -0
- package/src/definitions/behaviors/api.js +18 -18
- package/src/definitions/behaviors/form.js +76 -59
- package/src/definitions/behaviors/state.js +4 -4
- package/src/definitions/behaviors/visibility.js +11 -11
- package/src/definitions/collections/breadcrumb.less +2 -2
- package/src/definitions/collections/form.less +12 -12
- package/src/definitions/collections/grid.less +7 -7
- package/src/definitions/collections/menu.less +4 -4
- package/src/definitions/collections/message.less +38 -38
- package/src/definitions/collections/table.less +3 -3
- package/src/definitions/elements/button.less +12 -12
- package/src/definitions/elements/container.less +2 -2
- package/src/definitions/elements/divider.less +2 -2
- package/src/definitions/elements/emoji.less +5 -5
- package/src/definitions/elements/flag.less +11 -11
- package/src/definitions/elements/header.less +2 -2
- package/src/definitions/elements/icon.less +22 -22
- package/src/definitions/elements/image.less +2 -2
- package/src/definitions/elements/input.less +2 -2
- package/src/definitions/elements/label.less +4 -4
- package/src/definitions/elements/list.less +3 -3
- package/src/definitions/elements/loader.less +2 -2
- package/src/definitions/elements/placeholder.less +2 -2
- package/src/definitions/elements/rail.less +2 -2
- package/src/definitions/elements/reveal.less +8 -8
- package/src/definitions/elements/segment.less +3 -3
- package/src/definitions/elements/step.less +2 -2
- package/src/definitions/elements/text.less +2 -2
- package/src/definitions/globals/reset.less +2 -2
- package/src/definitions/globals/site.js +3 -3
- package/src/definitions/globals/site.less +9 -9
- package/src/definitions/modules/accordion.js +3 -3
- package/src/definitions/modules/accordion.less +2 -2
- package/src/definitions/modules/calendar.js +17 -16
- package/src/definitions/modules/calendar.less +2 -2
- package/src/definitions/modules/checkbox.js +10 -10
- package/src/definitions/modules/checkbox.less +2 -2
- package/src/definitions/modules/dimmer.js +8 -8
- package/src/definitions/modules/dimmer.less +3 -3
- package/src/definitions/modules/dropdown.js +102 -90
- package/src/definitions/modules/dropdown.less +6 -6
- package/src/definitions/modules/embed.js +4 -4
- package/src/definitions/modules/embed.less +2 -2
- package/src/definitions/modules/flyout.js +9 -9
- package/src/definitions/modules/flyout.less +5 -5
- package/src/definitions/modules/modal.js +3 -3
- package/src/definitions/modules/modal.less +7 -7
- package/src/definitions/modules/nag.js +4 -4
- package/src/definitions/modules/nag.less +3 -3
- package/src/definitions/modules/popup.js +38 -30
- package/src/definitions/modules/popup.less +2 -2
- package/src/definitions/modules/progress.js +11 -11
- package/src/definitions/modules/progress.less +2 -2
- package/src/definitions/modules/rating.js +5 -5
- package/src/definitions/modules/rating.less +14 -10
- package/src/definitions/modules/search.js +15 -15
- package/src/definitions/modules/search.less +2 -2
- package/src/definitions/modules/shape.js +4 -4
- package/src/definitions/modules/shape.less +2 -2
- package/src/definitions/modules/sidebar.js +12 -12
- package/src/definitions/modules/sidebar.less +18 -18
- package/src/definitions/modules/slider.js +49 -36
- package/src/definitions/modules/slider.less +2 -2
- package/src/definitions/modules/sticky.js +7 -7
- package/src/definitions/modules/sticky.less +2 -2
- package/src/definitions/modules/tab.js +16 -16
- package/src/definitions/modules/tab.less +2 -2
- package/src/definitions/modules/toast.js +3 -3
- package/src/definitions/modules/toast.less +5 -5
- package/src/definitions/modules/transition.js +7 -7
- package/src/definitions/modules/transition.less +2 -2
- package/src/definitions/views/ad.less +2 -2
- package/src/definitions/views/card.less +16 -16
- package/src/definitions/views/comment.less +2 -2
- package/src/definitions/views/feed.less +2 -2
- package/src/definitions/views/item.less +3 -3
- package/src/definitions/views/statistic.less +2 -2
- package/src/semantic.less +54 -52
- package/src/theme.config.example +53 -53
- package/src/theme.less +13 -13
- package/src/themes/amazon/elements/button.variables +1 -1
- package/src/themes/amazon/globals/site.variables +5 -5
- package/src/themes/basic/elements/icon.overrides +4 -4
- package/src/themes/basic/elements/icon.variables +2 -2
- package/src/themes/basic/modules/progress.variables +2 -2
- package/src/themes/basic/views/card.variables +3 -3
- package/src/themes/bookish/elements/header.variables +1 -1
- package/src/themes/bootstrap3/elements/button.overrides +3 -0
- package/src/themes/bootstrap3/elements/button.variables +8 -8
- package/src/themes/chubby/collections/menu.overrides +3 -0
- package/src/themes/chubby/collections/menu.variables +2 -2
- package/src/themes/chubby/elements/button.overrides +4 -4
- package/src/themes/chubby/elements/header.variables +1 -1
- package/src/themes/chubby/modules/accordion.variables +1 -1
- package/src/themes/chubby/views/comment.overrides +1 -1
- package/src/themes/chubby/views/comment.variables +4 -4
- package/src/themes/classic/collections/table.variables +1 -1
- package/src/themes/classic/elements/button.variables +17 -17
- package/src/themes/classic/modules/progress.variables +1 -1
- package/src/themes/classic/views/card.overrides +13 -13
- package/src/themes/classic/views/card.variables +2 -2
- package/src/themes/colored/modules/checkbox.overrides +3 -0
- package/src/themes/colored/modules/checkbox.variables +1 -1
- package/src/themes/default/collections/grid.variables +1 -1
- package/src/themes/default/collections/menu.variables +2 -2
- package/src/themes/default/collections/table.overrides +3 -0
- package/src/themes/default/collections/table.variables +1 -1
- package/src/themes/default/elements/container.variables +9 -9
- package/src/themes/default/elements/divider.variables +2 -2
- package/src/themes/default/elements/emoji.variables +2 -2
- package/src/themes/default/elements/flag.variables +2 -2
- package/src/themes/default/elements/header.variables +15 -15
- package/src/themes/default/elements/icon.variables +1979 -1979
- package/src/themes/default/elements/label.variables +24 -24
- package/src/themes/default/elements/list.variables +3 -3
- package/src/themes/default/elements/loader.variables +8 -8
- package/src/themes/default/elements/rail.variables +2 -2
- package/src/themes/default/elements/segment.variables +1 -1
- package/src/themes/default/elements/step.overrides +2 -2
- package/src/themes/default/elements/step.variables +1 -1
- package/src/themes/default/globals/colors.less +450 -450
- package/src/themes/default/globals/site.variables +821 -821
- package/src/themes/default/modules/accordion.overrides +1 -1
- package/src/themes/default/modules/checkbox.overrides +2 -2
- package/src/themes/default/modules/dimmer.variables +7 -7
- package/src/themes/default/modules/dropdown.overrides +8 -8
- package/src/themes/default/modules/dropdown.variables +2 -2
- package/src/themes/default/modules/flyout.variables +1 -1
- package/src/themes/default/modules/modal.variables +1 -1
- package/src/themes/default/modules/popup.variables +1 -1
- package/src/themes/default/modules/search.variables +1 -1
- package/src/themes/default/modules/sidebar.variables +1 -1
- package/src/themes/default/modules/slider.variables +45 -45
- package/src/themes/default/modules/toast.variables +6 -6
- package/src/themes/default/modules/transition.overrides +24 -24
- package/src/themes/default/views/card.variables +11 -11
- package/src/themes/default/views/item.variables +4 -4
- package/src/themes/famfamfam/elements/flag.variables +2 -2
- package/src/themes/fixed-width/collections/grid.variables +3 -3
- package/src/themes/fixed-width/modules/modal.variables +9 -9
- package/src/themes/flat/collections/form.overrides +1 -1
- package/src/themes/flat/collections/form.variables +9 -9
- package/src/themes/flat/globals/site.variables +50 -50
- package/src/themes/github/collections/form.overrides +2 -2
- package/src/themes/github/collections/form.variables +2 -2
- package/src/themes/github/collections/menu.overrides +1 -1
- package/src/themes/github/collections/menu.variables +4 -4
- package/src/themes/github/collections/message.variables +5 -5
- package/src/themes/github/elements/button.variables +2 -2
- package/src/themes/github/elements/icon.variables +2 -2
- package/src/themes/github/elements/segment.variables +2 -2
- package/src/themes/github/elements/step.overrides +1 -1
- package/src/themes/github/elements/step.variables +2 -2
- package/src/themes/github/globals/site.variables +5 -5
- package/src/themes/github/modules/dropdown.overrides +4 -4
- package/src/themes/github/modules/dropdown.variables +6 -6
- package/src/themes/gmail/collections/message.overrides +3 -0
- package/src/themes/gmail/collections/message.variables +2 -2
- package/src/themes/instagram/views/card.overrides +1 -1
- package/src/themes/instagram/views/card.variables +1 -1
- package/src/themes/joypixels/elements/emoji.variables +2 -2
- package/src/themes/material/collections/menu.variables +2 -2
- package/src/themes/material/elements/button.overrides +4 -4
- package/src/themes/material/elements/button.variables +25 -25
- package/src/themes/material/elements/header.variables +6 -6
- package/src/themes/material/elements/icon.variables +4 -4
- package/src/themes/material/globals/site.overrides +3 -0
- package/src/themes/material/globals/site.variables +52 -52
- package/src/themes/material/modules/dropdown.overrides +1 -1
- package/src/themes/material/modules/dropdown.variables +3 -3
- package/src/themes/material/modules/modal.overrides +1 -1
- package/src/themes/material/modules/modal.variables +3 -3
- package/src/themes/pulsar/elements/loader.overrides +4 -4
- package/src/themes/round/elements/button.overrides +3 -0
- package/src/themes/round/elements/button.variables +15 -15
- package/src/themes/rtl/globals/site.variables +3 -3
- package/src/themes/striped/modules/progress.overrides +1 -1
- package/src/themes/systemfont/globals/site.variables +6 -6
- package/src/themes/timeline/views/feed.variables +4 -4
- package/src/themes/twitter/elements/button.overrides +1 -1
- package/src/themes/twitter/elements/button.variables +1 -1
- package/src/themes/twitter/elements/emoji.variables +2 -2
- package/tasks/admin/components/init.js +1 -1
- package/tasks/admin/components/update.js +1 -1
- package/tasks/admin/distributions/create.js +4 -5
- package/tasks/admin/distributions/init.js +1 -1
- package/tasks/admin/distributions/update.js +1 -1
- package/tasks/config/project/config.js +2 -2
- package/tasks/config/project/install.js +8 -8
- package/tasks/config/project/release.js +1 -1
- package/tasks/config/tasks.js +2 -2
- package/tasks/docs/metadata.js +1 -1
- package/tasks/install.js +3 -3
- package/test/modules/module.spec.js +1 -1
@@ -279,7 +279,7 @@
|
|
279
279
|
storedValue = null;
|
280
280
|
}
|
281
281
|
}
|
282
|
-
if (storedValue
|
282
|
+
if (storedValue === 'undefined' || storedValue === 'null' || storedValue === undefined || storedValue === null) {
|
283
283
|
storedValue = undefined;
|
284
284
|
}
|
285
285
|
|
@@ -409,17 +409,17 @@
|
|
409
409
|
query = query.split(/[ .]/);
|
410
410
|
maxDepth = query.length - 1;
|
411
411
|
$.each(query, function (depth, value) {
|
412
|
-
var camelCaseValue = depth
|
412
|
+
var camelCaseValue = depth !== maxDepth
|
413
413
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
414
414
|
: query
|
415
415
|
;
|
416
|
-
if ($.isPlainObject(object[camelCaseValue]) && (depth
|
416
|
+
if ($.isPlainObject(object[camelCaseValue]) && (depth !== maxDepth)) {
|
417
417
|
object = object[camelCaseValue];
|
418
418
|
} else if (object[camelCaseValue] !== undefined) {
|
419
419
|
found = object[camelCaseValue];
|
420
420
|
|
421
421
|
return false;
|
422
|
-
} else if ($.isPlainObject(object[value]) && (depth
|
422
|
+
} else if ($.isPlainObject(object[value]) && (depth !== maxDepth)) {
|
423
423
|
object = object[value];
|
424
424
|
} else if (object[value] !== undefined) {
|
425
425
|
found = object[value];
|
@@ -12,8 +12,8 @@
|
|
12
12
|
Theme
|
13
13
|
*******************************/
|
14
14
|
|
15
|
-
@type
|
16
|
-
@element
|
15
|
+
@type: 'module';
|
16
|
+
@element: 'nag';
|
17
17
|
|
18
18
|
@import (multiple) '../../theme.config';
|
19
19
|
|
@@ -142,7 +142,7 @@ a.ui.nag {
|
|
142
142
|
-------------------- */
|
143
143
|
each(@variationNagSizes, {
|
144
144
|
@s: @@value;
|
145
|
-
@sr:
|
145
|
+
@sr: '@{value}Raw';
|
146
146
|
.ui.@{value}.nag,
|
147
147
|
.ui.@{value}.nags .nag {
|
148
148
|
font-size: @s;
|
@@ -212,7 +212,7 @@
|
|
212
212
|
[].forEach.call(mutations, function (mutation) {
|
213
213
|
if (mutation.removedNodes) {
|
214
214
|
[].forEach.call(mutation.removedNodes, function (node) {
|
215
|
-
if (node
|
215
|
+
if (node === element || $(node).find(element).length > 0) {
|
216
216
|
module.debug('Element removed from DOM, tearing down events');
|
217
217
|
module.destroy();
|
218
218
|
}
|
@@ -497,7 +497,7 @@
|
|
497
497
|
var
|
498
498
|
$popupOffsetParent = module.get.offsetParent($popup),
|
499
499
|
targetElement = $target[0],
|
500
|
-
isWindowEl = $boundary[0]
|
500
|
+
isWindowEl = $boundary[0] === window,
|
501
501
|
targetOffset = $target.offset(),
|
502
502
|
parentOffset = settings.inline || (settings.popup && settings.movePopup)
|
503
503
|
? $target.offsetParent().offset()
|
@@ -587,10 +587,10 @@
|
|
587
587
|
return id;
|
588
588
|
},
|
589
589
|
startEvent: function () {
|
590
|
-
if (settings.on
|
590
|
+
if (settings.on === 'hover') {
|
591
591
|
return 'mouseenter';
|
592
592
|
}
|
593
|
-
if (settings.on
|
593
|
+
if (settings.on === 'focus') {
|
594
594
|
return 'focus';
|
595
595
|
}
|
596
596
|
|
@@ -600,10 +600,10 @@
|
|
600
600
|
return 'scroll';
|
601
601
|
},
|
602
602
|
endEvent: function () {
|
603
|
-
if (settings.on
|
603
|
+
if (settings.on === 'hover') {
|
604
604
|
return 'mouseleave';
|
605
605
|
}
|
606
|
-
if (settings.on
|
606
|
+
if (settings.on === 'focus') {
|
607
607
|
return 'blur';
|
608
608
|
}
|
609
609
|
|
@@ -698,7 +698,7 @@
|
|
698
698
|
'bottom left': 'left center',
|
699
699
|
'left center': 'top left',
|
700
700
|
},
|
701
|
-
adjacentsAvailable = verticalPosition
|
701
|
+
adjacentsAvailable = verticalPosition === 'top' || verticalPosition === 'bottom',
|
702
702
|
oppositeTried = false,
|
703
703
|
adjacentTried = false,
|
704
704
|
nextPosition = false
|
@@ -764,11 +764,11 @@
|
|
764
764
|
|
765
765
|
if (module.should.centerArrow(calculations)) {
|
766
766
|
module.verbose('Adjusting offset to center arrow on small target element');
|
767
|
-
if (position
|
767
|
+
if (position === 'top left' || position === 'bottom left') {
|
768
768
|
offset += target.width / 2;
|
769
769
|
offset -= settings.arrowPixelsFromEdge;
|
770
770
|
}
|
771
|
-
if (position
|
771
|
+
if (position === 'top right' || position === 'bottom right') {
|
772
772
|
offset -= target.width / 2;
|
773
773
|
offset += settings.arrowPixelsFromEdge;
|
774
774
|
}
|
@@ -782,10 +782,10 @@
|
|
782
782
|
|
783
783
|
if (settings.inline) {
|
784
784
|
module.debug('Adding margin to calculation', target.margin);
|
785
|
-
if (position
|
785
|
+
if (position === 'left center' || position === 'right center') {
|
786
786
|
offset += target.margin.top;
|
787
787
|
distanceAway += -target.margin.left;
|
788
|
-
} else if (position
|
788
|
+
} else if (position === 'top left' || position === 'top center' || position === 'top right') {
|
789
789
|
offset += target.margin.left;
|
790
790
|
distanceAway -= target.margin.top;
|
791
791
|
} else {
|
@@ -798,7 +798,7 @@
|
|
798
798
|
|
799
799
|
if (module.is.rtl()) {
|
800
800
|
position = position.replace(/left|right/g, function (match) {
|
801
|
-
return match
|
801
|
+
return match === 'left'
|
802
802
|
? 'right'
|
803
803
|
: 'left';
|
804
804
|
});
|
@@ -806,12 +806,12 @@
|
|
806
806
|
}
|
807
807
|
|
808
808
|
// if last attempt use specified last resort position
|
809
|
-
if (searchDepth
|
809
|
+
if (searchDepth === settings.maxSearchDepth && typeof settings.lastResort === 'string') {
|
810
810
|
position = settings.lastResort;
|
811
811
|
}
|
812
812
|
|
813
813
|
switch (position) {
|
814
|
-
case 'top left':
|
814
|
+
case 'top left': {
|
815
815
|
positioning = {
|
816
816
|
top: 'auto',
|
817
817
|
bottom: parent.height - target.top + distanceAway,
|
@@ -820,7 +820,8 @@
|
|
820
820
|
};
|
821
821
|
|
822
822
|
break;
|
823
|
-
|
823
|
+
}
|
824
|
+
case 'top center': {
|
824
825
|
positioning = {
|
825
826
|
bottom: parent.height - target.top + distanceAway,
|
826
827
|
left: target.left + (target.width / 2) - (popup.width / 2) + offset,
|
@@ -829,7 +830,8 @@
|
|
829
830
|
};
|
830
831
|
|
831
832
|
break;
|
832
|
-
|
833
|
+
}
|
834
|
+
case 'top right': {
|
833
835
|
positioning = {
|
834
836
|
bottom: parent.height - target.top + distanceAway,
|
835
837
|
right: parent.width - target.left - target.width - offset,
|
@@ -838,7 +840,8 @@
|
|
838
840
|
};
|
839
841
|
|
840
842
|
break;
|
841
|
-
|
843
|
+
}
|
844
|
+
case 'left center': {
|
842
845
|
positioning = {
|
843
846
|
top: target.top + (target.height / 2) - (popup.height / 2) + offset,
|
844
847
|
right: parent.width - target.left + distanceAway,
|
@@ -847,7 +850,8 @@
|
|
847
850
|
};
|
848
851
|
|
849
852
|
break;
|
850
|
-
|
853
|
+
}
|
854
|
+
case 'right center': {
|
851
855
|
positioning = {
|
852
856
|
top: target.top + (target.height / 2) - (popup.height / 2) + offset,
|
853
857
|
left: target.left + target.width + distanceAway,
|
@@ -856,7 +860,8 @@
|
|
856
860
|
};
|
857
861
|
|
858
862
|
break;
|
859
|
-
|
863
|
+
}
|
864
|
+
case 'bottom left': {
|
860
865
|
positioning = {
|
861
866
|
top: target.top + target.height + distanceAway,
|
862
867
|
left: target.left + offset,
|
@@ -865,7 +870,8 @@
|
|
865
870
|
};
|
866
871
|
|
867
872
|
break;
|
868
|
-
|
873
|
+
}
|
874
|
+
case 'bottom center': {
|
869
875
|
positioning = {
|
870
876
|
top: target.top + target.height + distanceAway,
|
871
877
|
left: target.left + (target.width / 2) - (popup.width / 2) + offset,
|
@@ -874,7 +880,8 @@
|
|
874
880
|
};
|
875
881
|
|
876
882
|
break;
|
877
|
-
|
883
|
+
}
|
884
|
+
case 'bottom right': {
|
878
885
|
positioning = {
|
879
886
|
top: target.top + target.height + distanceAway,
|
880
887
|
right: parent.width - target.left - target.width - offset,
|
@@ -883,6 +890,7 @@
|
|
883
890
|
};
|
884
891
|
|
885
892
|
break;
|
893
|
+
}
|
886
894
|
}
|
887
895
|
if (positioning === undefined) {
|
888
896
|
module.error(error.invalidPosition, position);
|
@@ -980,12 +988,12 @@
|
|
980
988
|
bind: {
|
981
989
|
events: function () {
|
982
990
|
module.debug('Binding popup events to module');
|
983
|
-
if (settings.on
|
991
|
+
if (settings.on === 'click') {
|
984
992
|
$module
|
985
993
|
.on(clickEvent + eventNamespace, module.toggle)
|
986
994
|
;
|
987
995
|
}
|
988
|
-
if (settings.on
|
996
|
+
if (settings.on === 'hover') {
|
989
997
|
$module
|
990
998
|
.on('touchstart' + eventNamespace, module.event.touchstart)
|
991
999
|
;
|
@@ -1011,12 +1019,12 @@
|
|
1011
1019
|
}
|
1012
1020
|
},
|
1013
1021
|
close: function () {
|
1014
|
-
if (settings.hideOnScroll === true || (settings.hideOnScroll
|
1022
|
+
if (settings.hideOnScroll === true || (settings.hideOnScroll === 'auto' && settings.on !== 'click')) {
|
1015
1023
|
module.bind.closeOnScroll();
|
1016
1024
|
}
|
1017
1025
|
if (module.is.closable()) {
|
1018
1026
|
module.bind.clickaway();
|
1019
|
-
} else if (settings.on
|
1027
|
+
} else if (settings.on === 'hover' && openedWithTouch) {
|
1020
1028
|
module.bind.touchClose();
|
1021
1029
|
}
|
1022
1030
|
},
|
@@ -1079,8 +1087,8 @@
|
|
1079
1087
|
|
1080
1088
|
is: {
|
1081
1089
|
closable: function () {
|
1082
|
-
if (settings.closable
|
1083
|
-
return settings.on
|
1090
|
+
if (settings.closable === 'auto') {
|
1091
|
+
return settings.on !== 'hover';
|
1084
1092
|
}
|
1085
1093
|
|
1086
1094
|
return settings.closable;
|
@@ -1248,17 +1256,17 @@
|
|
1248
1256
|
query = query.split(/[ .]/);
|
1249
1257
|
maxDepth = query.length - 1;
|
1250
1258
|
$.each(query, function (depth, value) {
|
1251
|
-
var camelCaseValue = depth
|
1259
|
+
var camelCaseValue = depth !== maxDepth
|
1252
1260
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
1253
1261
|
: query
|
1254
1262
|
;
|
1255
|
-
if ($.isPlainObject(object[camelCaseValue]) && (depth
|
1263
|
+
if ($.isPlainObject(object[camelCaseValue]) && (depth !== maxDepth)) {
|
1256
1264
|
object = object[camelCaseValue];
|
1257
1265
|
} else if (object[camelCaseValue] !== undefined) {
|
1258
1266
|
found = object[camelCaseValue];
|
1259
1267
|
|
1260
1268
|
return false;
|
1261
|
-
} else if ($.isPlainObject(object[value]) && (depth
|
1269
|
+
} else if ($.isPlainObject(object[value]) && (depth !== maxDepth)) {
|
1262
1270
|
object = object[value];
|
1263
1271
|
} else if (object[value] !== undefined) {
|
1264
1272
|
found = object[value];
|
@@ -309,7 +309,7 @@
|
|
309
309
|
},
|
310
310
|
|
311
311
|
updateInterval: function () {
|
312
|
-
if (settings.updateInterval
|
312
|
+
if (settings.updateInterval === 'auto') {
|
313
313
|
return settings.duration;
|
314
314
|
}
|
315
315
|
|
@@ -460,7 +460,7 @@
|
|
460
460
|
if (isMultiple && allZero) {
|
461
461
|
$bar.css('background', 'transparent');
|
462
462
|
}
|
463
|
-
if (firstNonZeroIndex
|
463
|
+
if (firstNonZeroIndex === -1) {
|
464
464
|
firstNonZeroIndex = index;
|
465
465
|
}
|
466
466
|
lastNonZeroIndex = index;
|
@@ -475,10 +475,10 @@
|
|
475
475
|
values.forEach(function (_, index) {
|
476
476
|
var $bar = $($bars[index]);
|
477
477
|
$bar.css({
|
478
|
-
borderTopLeftRadius: index
|
479
|
-
borderBottomLeftRadius: index
|
480
|
-
borderTopRightRadius: index
|
481
|
-
borderBottomRightRadius: index
|
478
|
+
borderTopLeftRadius: index === firstNonZeroIndex ? '' : '0',
|
479
|
+
borderBottomLeftRadius: index === firstNonZeroIndex ? '' : '0',
|
480
|
+
borderTopRightRadius: index === lastNonZeroIndex ? '' : '0',
|
481
|
+
borderBottomRightRadius: index === lastNonZeroIndex ? '' : '0',
|
482
482
|
});
|
483
483
|
});
|
484
484
|
$module
|
@@ -610,10 +610,10 @@
|
|
610
610
|
var $progress = $(element);
|
611
611
|
if (text !== undefined) {
|
612
612
|
$progress.text(module.get.text(text, index));
|
613
|
-
} else if (settings.label
|
613
|
+
} else if (settings.label === 'ratio' && module.has.total()) {
|
614
614
|
module.verbose('Adding ratio to bar label');
|
615
615
|
$progress.text(module.get.text(settings.text.ratio, index));
|
616
|
-
} else if (settings.label
|
616
|
+
} else if (settings.label === 'percent') {
|
617
617
|
module.verbose('Adding percentage to bar label');
|
618
618
|
$progress.text(module.get.text(settings.text.percent, index));
|
619
619
|
}
|
@@ -862,17 +862,17 @@
|
|
862
862
|
query = query.split(/[ .]/);
|
863
863
|
maxDepth = query.length - 1;
|
864
864
|
$.each(query, function (depth, value) {
|
865
|
-
var camelCaseValue = depth
|
865
|
+
var camelCaseValue = depth !== maxDepth
|
866
866
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
867
867
|
: query
|
868
868
|
;
|
869
|
-
if ($.isPlainObject(object[camelCaseValue]) && (depth
|
869
|
+
if ($.isPlainObject(object[camelCaseValue]) && (depth !== maxDepth)) {
|
870
870
|
object = object[camelCaseValue];
|
871
871
|
} else if (object[camelCaseValue] !== undefined) {
|
872
872
|
found = object[camelCaseValue];
|
873
873
|
|
874
874
|
return false;
|
875
|
-
} else if ($.isPlainObject(object[value]) && (depth
|
875
|
+
} else if ($.isPlainObject(object[value]) && (depth !== maxDepth)) {
|
876
876
|
object = object[value];
|
877
877
|
} else if (object[value] !== undefined) {
|
878
878
|
found = object[value];
|
@@ -143,11 +143,11 @@
|
|
143
143
|
$activeIcon = $(this),
|
144
144
|
currentRating = module.get.rating(),
|
145
145
|
rating = $icon.index($activeIcon) + 1,
|
146
|
-
canClear = settings.clearable
|
146
|
+
canClear = settings.clearable === 'auto'
|
147
147
|
? $icon.length === 1
|
148
148
|
: settings.clearable
|
149
149
|
;
|
150
|
-
if (canClear && currentRating
|
150
|
+
if (canClear && currentRating === rating) {
|
151
151
|
module.clearRating();
|
152
152
|
} else {
|
153
153
|
module.set.rating(rating);
|
@@ -414,17 +414,17 @@
|
|
414
414
|
query = query.split(/[ .]/);
|
415
415
|
maxDepth = query.length - 1;
|
416
416
|
$.each(query, function (depth, value) {
|
417
|
-
var camelCaseValue = depth
|
417
|
+
var camelCaseValue = depth !== maxDepth
|
418
418
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
419
419
|
: query
|
420
420
|
;
|
421
|
-
if ($.isPlainObject(object[camelCaseValue]) && (depth
|
421
|
+
if ($.isPlainObject(object[camelCaseValue]) && (depth !== maxDepth)) {
|
422
422
|
object = object[camelCaseValue];
|
423
423
|
} else if (object[camelCaseValue] !== undefined) {
|
424
424
|
found = object[camelCaseValue];
|
425
425
|
|
426
426
|
return false;
|
427
|
-
} else if ($.isPlainObject(object[value]) && (depth
|
427
|
+
} else if ($.isPlainObject(object[value]) && (depth !== maxDepth)) {
|
428
428
|
object = object[value];
|
429
429
|
} else if (object[value] !== undefined) {
|
430
430
|
found = object[value];
|
@@ -12,8 +12,8 @@
|
|
12
12
|
Theme
|
13
13
|
*******************************/
|
14
14
|
|
15
|
-
@type
|
16
|
-
@element
|
15
|
+
@type: 'module';
|
16
|
+
@element: 'rating';
|
17
17
|
|
18
18
|
@import (multiple) '../../theme.config';
|
19
19
|
|
@@ -103,20 +103,24 @@
|
|
103
103
|
|
104
104
|
.ui.@{color}.rating .active.icon {
|
105
105
|
color: @l;
|
106
|
-
text-shadow:
|
107
|
-
|
108
|
-
|
109
|
-
|
106
|
+
text-shadow:
|
107
|
+
0 -@shadowWidth 0 @c,
|
108
|
+
-@shadowWidth 0 0 @c,
|
109
|
+
0 @shadowWidth 0 @c,
|
110
|
+
@shadowWidth 0 0 @c
|
111
|
+
;
|
110
112
|
}
|
111
113
|
.ui.@{color}.rating .icon.selected,
|
112
114
|
.ui.@{color}.rating .icon.selected.active,
|
113
115
|
.ui.@{color}.rating .icon.selected.partial.active {
|
114
116
|
background: inherit;
|
115
117
|
color: @lh;
|
116
|
-
text-shadow:
|
117
|
-
|
118
|
-
|
119
|
-
|
118
|
+
text-shadow:
|
119
|
+
0 -@shadowWidth 0 @h,
|
120
|
+
-@shadowWidth 0 0 @h,
|
121
|
+
0 @shadowWidth 0 @h,
|
122
|
+
@shadowWidth 0 0 @h
|
123
|
+
;
|
120
124
|
|
121
125
|
-webkit-text-stroke: unset;
|
122
126
|
background-clip: unset;
|
@@ -237,7 +237,7 @@
|
|
237
237
|
if (href) {
|
238
238
|
event.preventDefault();
|
239
239
|
module.verbose('Opening search link found in result', $link);
|
240
|
-
if (target
|
240
|
+
if (target === '_blank' || event.ctrlKey) {
|
241
241
|
window.open(href);
|
242
242
|
} else {
|
243
243
|
window.location.href = href;
|
@@ -289,7 +289,7 @@
|
|
289
289
|
newIndex
|
290
290
|
;
|
291
291
|
// search shortcuts
|
292
|
-
if (keyCode
|
292
|
+
if (keyCode === keys.escape) {
|
293
293
|
if (!module.is.visible()) {
|
294
294
|
module.verbose('Escape key pressed, blurring search field');
|
295
295
|
$prompt.trigger('blur');
|
@@ -300,7 +300,7 @@
|
|
300
300
|
resultsDismissed = true;
|
301
301
|
}
|
302
302
|
if (module.is.visible()) {
|
303
|
-
if (keyCode
|
303
|
+
if (keyCode === keys.enter) {
|
304
304
|
module.verbose('Enter key pressed, selecting active result');
|
305
305
|
if ($result.filter('.' + className.active).length > 0) {
|
306
306
|
module.event.result.click.call($result.filter('.' + className.active), event);
|
@@ -308,7 +308,7 @@
|
|
308
308
|
|
309
309
|
return false;
|
310
310
|
}
|
311
|
-
} else if (keyCode
|
311
|
+
} else if (keyCode === keys.upArrow && hasActiveResult) {
|
312
312
|
module.verbose('Up key pressed, changing active result');
|
313
313
|
newIndex = currentIndex - 1 < 0
|
314
314
|
? currentIndex
|
@@ -325,7 +325,7 @@
|
|
325
325
|
;
|
326
326
|
module.ensureVisible($result.eq(newIndex));
|
327
327
|
event.preventDefault();
|
328
|
-
} else if (keyCode
|
328
|
+
} else if (keyCode === keys.downArrow) {
|
329
329
|
module.verbose('Down key pressed, changing active result');
|
330
330
|
newIndex = currentIndex + 1 >= resultSize
|
331
331
|
? currentIndex
|
@@ -345,7 +345,7 @@
|
|
345
345
|
}
|
346
346
|
} else {
|
347
347
|
// query shortcuts
|
348
|
-
if (keyCode
|
348
|
+
if (keyCode === keys.enter) {
|
349
349
|
module.verbose('Enter key pressed, executing query');
|
350
350
|
module.query();
|
351
351
|
module.set.buttonPressed();
|
@@ -596,7 +596,7 @@
|
|
596
596
|
module.debug('Using specified max results', results);
|
597
597
|
results = results.slice(0, settings.maxResults);
|
598
598
|
}
|
599
|
-
if (settings.type
|
599
|
+
if (settings.type === 'category') {
|
600
600
|
results = module.create.categoryResults(results);
|
601
601
|
}
|
602
602
|
searchHTML = module.generateResults({
|
@@ -634,9 +634,9 @@
|
|
634
634
|
// avoid duplicates when pushing results
|
635
635
|
addResult = function (array, result) {
|
636
636
|
var
|
637
|
-
notResult = $.inArray(result, results)
|
638
|
-
notFuzzyResult = $.inArray(result, fuzzyResults)
|
639
|
-
notExactResults = $.inArray(result, exactResults)
|
637
|
+
notResult = $.inArray(result, results) === -1,
|
638
|
+
notFuzzyResult = $.inArray(result, fuzzyResults) === -1,
|
639
|
+
notExactResults = $.inArray(result, exactResults) === -1
|
640
640
|
;
|
641
641
|
if (notResult && notFuzzyResult && notExactResults) {
|
642
642
|
array.push(result);
|
@@ -782,7 +782,7 @@
|
|
782
782
|
html = $results.html()
|
783
783
|
;
|
784
784
|
|
785
|
-
return html
|
785
|
+
return html !== '';
|
786
786
|
},
|
787
787
|
},
|
788
788
|
|
@@ -1052,7 +1052,7 @@
|
|
1052
1052
|
if (isProperObject || isProperArray) {
|
1053
1053
|
if (settings.maxResults > 0) {
|
1054
1054
|
if (isProperObject) {
|
1055
|
-
if (settings.type
|
1055
|
+
if (settings.type === 'standard') {
|
1056
1056
|
module.error(error.maxResults);
|
1057
1057
|
}
|
1058
1058
|
} else {
|
@@ -1190,17 +1190,17 @@
|
|
1190
1190
|
query = query.split(/[ .]/);
|
1191
1191
|
maxDepth = query.length - 1;
|
1192
1192
|
$.each(query, function (depth, value) {
|
1193
|
-
var camelCaseValue = depth
|
1193
|
+
var camelCaseValue = depth !== maxDepth
|
1194
1194
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
1195
1195
|
: query
|
1196
1196
|
;
|
1197
|
-
if ($.isPlainObject(object[camelCaseValue]) && (depth
|
1197
|
+
if ($.isPlainObject(object[camelCaseValue]) && (depth !== maxDepth)) {
|
1198
1198
|
object = object[camelCaseValue];
|
1199
1199
|
} else if (object[camelCaseValue] !== undefined) {
|
1200
1200
|
found = object[camelCaseValue];
|
1201
1201
|
|
1202
1202
|
return false;
|
1203
|
-
} else if ($.isPlainObject(object[value]) && (depth
|
1203
|
+
} else if ($.isPlainObject(object[value]) && (depth !== maxDepth)) {
|
1204
1204
|
object = object[value];
|
1205
1205
|
} else if (object[value] !== undefined) {
|
1206
1206
|
found = object[value];
|
@@ -185,7 +185,7 @@
|
|
185
185
|
|
186
186
|
is: {
|
187
187
|
complete: function () {
|
188
|
-
return $side.filter('.' + className.active)[0]
|
188
|
+
return $side.filter('.' + className.active)[0] === $nextSide[0];
|
189
189
|
},
|
190
190
|
animating: function () {
|
191
191
|
return $module.hasClass(className.animating);
|
@@ -704,17 +704,17 @@
|
|
704
704
|
query = query.split(/[ .]/);
|
705
705
|
maxDepth = query.length - 1;
|
706
706
|
$.each(query, function (depth, value) {
|
707
|
-
var camelCaseValue = depth
|
707
|
+
var camelCaseValue = depth !== maxDepth
|
708
708
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
709
709
|
: query
|
710
710
|
;
|
711
|
-
if ($.isPlainObject(object[camelCaseValue]) && (depth
|
711
|
+
if ($.isPlainObject(object[camelCaseValue]) && (depth !== maxDepth)) {
|
712
712
|
object = object[camelCaseValue];
|
713
713
|
} else if (object[camelCaseValue] !== undefined) {
|
714
714
|
found = object[camelCaseValue];
|
715
715
|
|
716
716
|
return false;
|
717
|
-
} else if ($.isPlainObject(object[value]) && (depth
|
717
|
+
} else if ($.isPlainObject(object[value]) && (depth !== maxDepth)) {
|
718
718
|
object = object[value];
|
719
719
|
} else if (object[value] !== undefined) {
|
720
720
|
found = object[value];
|