fomantic-ui 2.9.2-beta.0 → 2.9.2-beta.10
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/.github/workflows/ci.yml +1 -1
- package/dist/components/accordion.css +1 -1
- package/dist/components/accordion.js +4 -4
- package/dist/components/accordion.min.css +1 -1
- package/dist/components/accordion.min.js +2 -2
- package/dist/components/ad.css +2 -2
- package/dist/components/ad.min.css +1 -1
- package/dist/components/api.js +1 -1
- package/dist/components/api.min.js +1 -1
- package/dist/components/breadcrumb.css +1 -1
- package/dist/components/breadcrumb.min.css +1 -1
- package/dist/components/button.css +1 -1
- package/dist/components/button.min.css +1 -1
- package/dist/components/calendar.css +7 -1
- package/dist/components/calendar.js +1 -1
- package/dist/components/calendar.min.css +1 -1
- package/dist/components/calendar.min.js +1 -1
- package/dist/components/card.css +2 -2
- package/dist/components/card.min.css +1 -1
- package/dist/components/checkbox.css +40 -40
- package/dist/components/checkbox.js +1 -1
- package/dist/components/checkbox.min.css +2 -2
- package/dist/components/checkbox.min.js +1 -1
- package/dist/components/comment.css +2 -2
- package/dist/components/comment.min.css +1 -1
- package/dist/components/container.css +1 -1
- package/dist/components/container.min.css +1 -1
- package/dist/components/dimmer.css +1 -1
- package/dist/components/dimmer.js +3 -3
- 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 +8 -6
- package/dist/components/dropdown.js +3 -3
- package/dist/components/dropdown.min.css +2 -2
- package/dist/components/dropdown.min.js +2 -2
- package/dist/components/embed.css +2 -2
- package/dist/components/embed.js +2 -2
- package/dist/components/embed.min.css +2 -2
- package/dist/components/embed.min.js +2 -2
- package/dist/components/emoji.css +6 -0
- package/dist/components/feed.css +2 -2
- package/dist/components/feed.min.css +1 -1
- package/dist/components/flag.css +1 -1
- package/dist/components/flag.min.css +1 -1
- package/dist/components/flyout.css +7 -1
- package/dist/components/flyout.js +18 -30
- package/dist/components/flyout.min.css +1 -1
- package/dist/components/flyout.min.js +2 -2
- package/dist/components/form.css +66 -37
- package/dist/components/form.js +102 -94
- package/dist/components/form.min.css +2 -2
- package/dist/components/form.min.js +2 -2
- package/dist/components/grid.css +1 -1
- package/dist/components/grid.min.css +1 -1
- package/dist/components/header.css +1 -1
- package/dist/components/header.min.css +1 -1
- package/dist/components/icon.css +1 -1
- package/dist/components/icon.min.css +1 -1
- package/dist/components/image.css +1 -1
- package/dist/components/image.min.css +1 -1
- package/dist/components/input.css +59 -25
- 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 +1 -1
- package/dist/components/label.min.css +1 -1
- package/dist/components/list.css +2 -2
- package/dist/components/list.min.css +1 -1
- package/dist/components/loader.css +1 -1
- package/dist/components/loader.min.css +1 -1
- package/dist/components/menu.css +31 -7
- package/dist/components/menu.min.css +9 -1
- package/dist/components/message.css +2 -2
- package/dist/components/message.min.css +1 -1
- package/dist/components/modal.css +1 -1
- package/dist/components/modal.js +15 -8
- package/dist/components/modal.min.css +1 -1
- package/dist/components/modal.min.js +2 -2
- package/dist/components/nag.css +1 -1
- package/dist/components/nag.js +1 -1
- package/dist/components/nag.min.css +1 -1
- package/dist/components/nag.min.js +1 -1
- package/dist/components/placeholder.css +7 -1
- package/dist/components/placeholder.min.css +1 -1
- package/dist/components/popup.css +148 -3
- package/dist/components/popup.js +20 -8
- 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 +3 -29
- 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 +1 -1
- package/dist/components/rating.js +1 -1
- package/dist/components/rating.min.css +1 -1
- package/dist/components/rating.min.js +1 -1
- package/dist/components/reset.css +1 -1
- package/dist/components/reset.min.css +1 -1
- package/dist/components/reveal.css +1 -1
- package/dist/components/reveal.min.css +1 -1
- package/dist/components/search.css +1 -1
- package/dist/components/search.js +2 -2
- package/dist/components/search.min.css +1 -1
- package/dist/components/search.min.js +2 -2
- package/dist/components/segment.css +3 -3
- package/dist/components/segment.min.css +2 -2
- package/dist/components/shape.css +1 -1
- package/dist/components/shape.js +15 -37
- package/dist/components/shape.min.css +1 -1
- package/dist/components/shape.min.js +2 -2
- package/dist/components/sidebar.css +1 -1
- package/dist/components/sidebar.js +7 -27
- package/dist/components/sidebar.min.css +1 -1
- package/dist/components/sidebar.min.js +2 -2
- package/dist/components/site.css +1 -10
- package/dist/components/site.js +1 -1
- package/dist/components/site.min.css +2 -2
- package/dist/components/site.min.js +1 -1
- package/dist/components/slider.css +6 -0
- package/dist/components/slider.js +1 -1
- package/dist/components/slider.min.js +1 -1
- package/dist/components/state.js +1 -1
- package/dist/components/state.min.js +1 -1
- package/dist/components/statistic.css +2 -2
- package/dist/components/statistic.min.css +1 -1
- 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 +1 -1
- package/dist/components/sticky.min.css +1 -1
- package/dist/components/sticky.min.js +1 -1
- package/dist/components/tab.css +1 -1
- package/dist/components/tab.js +1 -1
- package/dist/components/tab.min.css +1 -1
- package/dist/components/tab.min.js +1 -1
- package/dist/components/table.css +2 -2
- package/dist/components/table.min.css +2 -2
- package/dist/components/text.css +7 -1
- package/dist/components/text.min.css +1 -1
- package/dist/components/toast.css +7 -1
- package/dist/components/toast.js +3 -3
- package/dist/components/toast.min.css +1 -1
- package/dist/components/toast.min.js +2 -2
- package/dist/components/transition.css +1 -1
- package/dist/components/transition.js +10 -61
- package/dist/components/transition.min.css +1 -1
- package/dist/components/transition.min.js +2 -2
- package/dist/components/visibility.js +1 -1
- package/dist/components/visibility.min.js +1 -1
- package/dist/semantic.css +512 -196
- package/dist/semantic.js +220 -324
- package/dist/semantic.min.css +2 -2
- package/dist/semantic.min.js +2 -2
- package/package.json +1 -1
- package/src/_site/collections/breadcrumb.variables +1 -1
- package/src/_site/collections/message.overrides +1 -1
- package/src/_site/elements/emoji.overrides +3 -0
- package/src/_site/{modules/chatroom.variables → elements/emoji.variables} +0 -0
- package/src/_site/elements/flag.variables +3 -3
- package/src/_site/elements/list.overrides +1 -1
- package/src/_site/elements/placeholder.overrides +3 -0
- package/src/_site/elements/placeholder.variables +3 -0
- package/src/_site/elements/text.overrides +3 -0
- package/src/_site/elements/text.variables +3 -0
- package/src/_site/modules/{chatroom.overrides → calendar.overrides} +0 -0
- package/src/_site/modules/calendar.variables +3 -0
- package/src/_site/modules/flyout.overrides +3 -0
- package/src/_site/modules/flyout.variables +3 -0
- package/src/_site/modules/modal.variables +1 -1
- package/src/_site/modules/rating.variables +1 -1
- package/src/_site/modules/search.variables +1 -1
- package/src/_site/modules/sidebar.variables +1 -1
- package/src/_site/modules/slider.overrides +3 -0
- package/src/_site/modules/slider.variables +3 -0
- package/src/_site/modules/sticky.variables +1 -1
- package/src/_site/modules/toast.overrides +3 -0
- package/src/_site/modules/toast.variables +3 -0
- package/src/_site/views/ad.overrides +1 -1
- package/src/_site/views/card.overrides +1 -1
- package/src/_site/views/comment.overrides +1 -1
- package/src/_site/views/feed.overrides +1 -1
- package/src/_site/views/item.overrides +1 -1
- package/src/_site/views/statistic.overrides +1 -1
- package/src/definitions/behaviors/form.js +101 -93
- package/src/definitions/collections/form.less +4 -14
- package/src/definitions/collections/menu.less +39 -6
- package/src/definitions/elements/input.less +6 -20
- package/src/definitions/globals/site.less +0 -18
- package/src/definitions/modules/accordion.js +3 -3
- package/src/definitions/modules/checkbox.less +39 -39
- package/src/definitions/modules/dimmer.js +2 -2
- package/src/definitions/modules/dropdown.js +2 -2
- package/src/definitions/modules/dropdown.less +6 -10
- package/src/definitions/modules/embed.js +1 -1
- package/src/definitions/modules/embed.less +1 -1
- package/src/definitions/modules/flyout.js +17 -29
- package/src/definitions/modules/modal.js +14 -7
- package/src/definitions/modules/popup.js +19 -7
- package/src/definitions/modules/popup.less +48 -4
- package/src/definitions/modules/progress.js +2 -28
- package/src/definitions/modules/search.js +1 -1
- package/src/definitions/modules/shape.js +14 -36
- package/src/definitions/modules/sidebar.js +6 -26
- package/src/definitions/modules/toast.js +2 -2
- package/src/definitions/modules/transition.js +9 -60
- package/src/theme.less +4 -12
- package/src/themes/default/collections/menu.variables +1 -3
- package/src/themes/default/collections/table.variables +1 -3
- package/src/themes/default/elements/segment.variables +1 -3
- package/src/themes/default/elements/step.variables +1 -1
- package/src/themes/default/globals/site.variables +1 -0
- package/src/themes/default/globals/variation.variables +2 -0
- package/src/themes/default/modules/popup.variables +8 -0
- package/src/themes/default/views/item.variables +1 -1
- package/tasks/config/project/install.js +1 -1
- package/tasks/install.js +8 -0
@@ -125,9 +125,9 @@
|
|
125
125
|
}
|
126
126
|
}
|
127
127
|
if (settings.popup) {
|
128
|
-
|
128
|
+
module.set.invisible();
|
129
129
|
$offsetParent = module.get.offsetParent();
|
130
|
-
|
130
|
+
module.remove.invisible();
|
131
131
|
if (settings.movePopup && module.has.popup() && module.get.offsetParent($popup)[0] !== $offsetParent[0]) {
|
132
132
|
module.debug('Moving popup to the same offset parent as target');
|
133
133
|
$popup
|
@@ -414,7 +414,7 @@
|
|
414
414
|
animate: {
|
415
415
|
show: function (callback) {
|
416
416
|
callback = isFunction(callback) ? callback : function () {};
|
417
|
-
if (settings.transition && module.can.useElement('transition')
|
417
|
+
if (settings.transition && module.can.useElement('transition')) {
|
418
418
|
module.set.visible();
|
419
419
|
$popup
|
420
420
|
.transition({
|
@@ -436,7 +436,7 @@
|
|
436
436
|
hide: function (callback) {
|
437
437
|
callback = isFunction(callback) ? callback : function () {};
|
438
438
|
module.debug('Hiding pop-up');
|
439
|
-
if (settings.transition && $.fn.transition !== undefined
|
439
|
+
if (settings.transition && $.fn.transition !== undefined) {
|
440
440
|
$popup
|
441
441
|
.transition({
|
442
442
|
animation: (settings.transition.hideMethod || settings.transition) + ' out',
|
@@ -901,8 +901,8 @@
|
|
901
901
|
.css(positioning)
|
902
902
|
.removeClass(className.position)
|
903
903
|
.addClass(position)
|
904
|
-
.addClass(className.loading)
|
905
904
|
;
|
905
|
+
module.set.invisible();
|
906
906
|
|
907
907
|
popupOffset = module.get.popupOffset();
|
908
908
|
|
@@ -926,7 +926,7 @@
|
|
926
926
|
module.debug('Popup could not find a position to display', $popup);
|
927
927
|
module.error(error.cannotPlace, element);
|
928
928
|
module.remove.attempts();
|
929
|
-
module.remove.
|
929
|
+
module.remove.invisible();
|
930
930
|
module.reset();
|
931
931
|
settings.onUnplaceable.call($popup, element);
|
932
932
|
|
@@ -935,7 +935,7 @@
|
|
935
935
|
}
|
936
936
|
module.debug('Position is on stage', position);
|
937
937
|
module.remove.attempts();
|
938
|
-
module.remove.
|
938
|
+
module.remove.invisible();
|
939
939
|
if (settings.setFluidWidth && module.is.fluid()) {
|
940
940
|
module.set.fluidWidth(calculations);
|
941
941
|
}
|
@@ -949,6 +949,14 @@
|
|
949
949
|
$popup.css('width', calculations.container.width);
|
950
950
|
},
|
951
951
|
|
952
|
+
loading: function () {
|
953
|
+
$popup.addClass(className.loading);
|
954
|
+
},
|
955
|
+
|
956
|
+
invisible: function () {
|
957
|
+
$popup.addClass(className.invisible);
|
958
|
+
},
|
959
|
+
|
952
960
|
variation: function (variation) {
|
953
961
|
variation = variation || module.get.variation();
|
954
962
|
if (variation && module.has.popup()) {
|
@@ -966,6 +974,9 @@
|
|
966
974
|
loading: function () {
|
967
975
|
$popup.removeClass(className.loading);
|
968
976
|
},
|
977
|
+
invisible: function () {
|
978
|
+
$popup.removeClass(className.invisible);
|
979
|
+
},
|
969
980
|
variation: function (variation) {
|
970
981
|
variation = variation || module.get.variation();
|
971
982
|
if (variation) {
|
@@ -1475,6 +1486,7 @@
|
|
1475
1486
|
basic: 'basic',
|
1476
1487
|
animating: 'animating',
|
1477
1488
|
dropdown: 'dropdown',
|
1489
|
+
invisible: 'invisible',
|
1478
1490
|
fluid: 'fluid',
|
1479
1491
|
loading: 'loading',
|
1480
1492
|
popup: 'ui popup',
|
@@ -704,12 +704,36 @@
|
|
704
704
|
*******************************/
|
705
705
|
& when (@variationPopupLoading) {
|
706
706
|
.ui.loading.popup {
|
707
|
-
|
708
|
-
|
709
|
-
|
707
|
+
cursor: default;
|
708
|
+
pointer-events: @loadingPointerEvents;
|
709
|
+
user-select: none;
|
710
|
+
& * {
|
711
|
+
opacity: @loadingOpacity;
|
712
|
+
}
|
713
|
+
&::after {
|
714
|
+
position: absolute;
|
715
|
+
content: "";
|
716
|
+
top: 50%;
|
717
|
+
left: 50%;
|
718
|
+
margin: @loaderMargin;
|
719
|
+
width: @loaderSize;
|
720
|
+
height: @loaderSize;
|
721
|
+
animation: loader @loaderSpeed infinite linear;
|
722
|
+
border: @loaderLineWidth solid @loaderLineColor;
|
723
|
+
border-radius: @circularRadius;
|
724
|
+
box-shadow: 0 0 0 1px transparent;
|
725
|
+
visibility: visible;
|
726
|
+
z-index: @loaderLineZIndex;
|
727
|
+
}
|
710
728
|
}
|
711
729
|
}
|
712
730
|
|
731
|
+
.ui.invisible.popup {
|
732
|
+
display: block;
|
733
|
+
visibility: hidden !important;
|
734
|
+
z-index: @invisibleZIndex;
|
735
|
+
}
|
736
|
+
|
713
737
|
.ui.animating.popup,
|
714
738
|
.ui.visible.popup {
|
715
739
|
display: block;
|
@@ -793,7 +817,7 @@
|
|
793
817
|
box-shadow: @invertedBoxShadow;
|
794
818
|
}
|
795
819
|
.ui.inverted.popup .header {
|
796
|
-
background
|
820
|
+
background: @invertedHeaderBackground;
|
797
821
|
color: @invertedHeaderColor;
|
798
822
|
}
|
799
823
|
.ui.inverted.popup::before {
|
@@ -807,6 +831,8 @@
|
|
807
831
|
@color: @value;
|
808
832
|
@c: @colors[@@color][color];
|
809
833
|
@l: @colors[@@color][light];
|
834
|
+
@cl: lighten(@c, @loadingColoredPercent);
|
835
|
+
@ll: darken(@l, @loadingColoredPercent);
|
810
836
|
|
811
837
|
& when not (@variationPopupTooltip) {
|
812
838
|
.ui.ui.ui.@{color}.popup::before,
|
@@ -814,6 +840,9 @@
|
|
814
840
|
background: @c;
|
815
841
|
color: @white;
|
816
842
|
border: none;
|
843
|
+
.loading& when (@variationPopupLoading) {
|
844
|
+
background: @cl;
|
845
|
+
}
|
817
846
|
}
|
818
847
|
.ui.ui.ui.@{color}.popup::before {
|
819
848
|
box-shadow: none;
|
@@ -823,6 +852,9 @@
|
|
823
852
|
.ui.inverted.@{color}.popup {
|
824
853
|
background: @l;
|
825
854
|
color: @black;
|
855
|
+
.loading& when (@variationPopupLoading) {
|
856
|
+
background: @ll;
|
857
|
+
}
|
826
858
|
}
|
827
859
|
}
|
828
860
|
}
|
@@ -835,6 +867,12 @@
|
|
835
867
|
color: @white;
|
836
868
|
border: none;
|
837
869
|
}
|
870
|
+
& when (@variationPopupLoading) {
|
871
|
+
.ui.ui.ui.@{color}.loading.popup::before,
|
872
|
+
.ui.@{color}.loading.popup {
|
873
|
+
background: @cl;
|
874
|
+
}
|
875
|
+
}
|
838
876
|
.ui.ui.ui.@{color}.popup::before,
|
839
877
|
[data-tooltip][data-variation~="@{color}"]::before {
|
840
878
|
box-shadow: none;
|
@@ -847,6 +885,12 @@
|
|
847
885
|
background: @l;
|
848
886
|
color: @black;
|
849
887
|
}
|
888
|
+
& when (@variationPopupLoading) {
|
889
|
+
.ui.ui.ui.inverted.@{color}.loading.popup::before,
|
890
|
+
.ui.inverted.@{color}.loading.popup {
|
891
|
+
background: @ll;
|
892
|
+
}
|
893
|
+
}
|
850
894
|
}
|
851
895
|
}
|
852
896
|
});
|
@@ -59,7 +59,6 @@
|
|
59
59
|
instance = $module.data(moduleNamespace),
|
60
60
|
|
61
61
|
animating = false,
|
62
|
-
transitionEnd,
|
63
62
|
module
|
64
63
|
;
|
65
64
|
module = {
|
@@ -115,7 +114,6 @@
|
|
115
114
|
|
116
115
|
initialize: function () {
|
117
116
|
module.set.duration();
|
118
|
-
module.set.transitionEvent();
|
119
117
|
module.debug(element);
|
120
118
|
|
121
119
|
module.read.metadata();
|
@@ -195,17 +193,14 @@
|
|
195
193
|
|
196
194
|
bind: {
|
197
195
|
transitionEnd: function (callback) {
|
198
|
-
var
|
199
|
-
transitionEnd = module.get.transitionEnd()
|
200
|
-
;
|
201
196
|
$bars
|
202
|
-
.one(
|
197
|
+
.one('transitionend' + eventNamespace, function (event) {
|
203
198
|
clearTimeout(module.failSafeTimer);
|
204
199
|
callback.call(this, event);
|
205
200
|
})
|
206
201
|
;
|
207
202
|
module.failSafeTimer = setTimeout(function () {
|
208
|
-
$bars.triggerHandler(
|
203
|
+
$bars.triggerHandler('transitionend');
|
209
204
|
}, settings.duration + settings.failSafeDelay);
|
210
205
|
module.verbose('Adding fail safe timer', module.timer);
|
211
206
|
},
|
@@ -330,24 +325,6 @@
|
|
330
325
|
: value;
|
331
326
|
},
|
332
327
|
|
333
|
-
transitionEnd: function () {
|
334
|
-
var
|
335
|
-
element = document.createElement('element'),
|
336
|
-
transitions = {
|
337
|
-
transition: 'transitionend',
|
338
|
-
OTransition: 'oTransitionEnd',
|
339
|
-
MozTransition: 'transitionend',
|
340
|
-
WebkitTransition: 'webkitTransitionEnd',
|
341
|
-
},
|
342
|
-
transition
|
343
|
-
;
|
344
|
-
for (transition in transitions) {
|
345
|
-
if (element.style[transition] !== undefined) {
|
346
|
-
return transitions[transition];
|
347
|
-
}
|
348
|
-
}
|
349
|
-
},
|
350
|
-
|
351
328
|
// gets current displayed percentage (if animating values this is the intermediary value)
|
352
329
|
displayPercent: function (index) {
|
353
330
|
var
|
@@ -687,9 +664,6 @@
|
|
687
664
|
settings.onError.call(element, module.value, module.total);
|
688
665
|
});
|
689
666
|
},
|
690
|
-
transitionEvent: function () {
|
691
|
-
transitionEnd = module.get.transitionEnd();
|
692
|
-
},
|
693
667
|
total: function (totalValue) {
|
694
668
|
module.total = totalValue;
|
695
669
|
},
|
@@ -408,7 +408,7 @@
|
|
408
408
|
return module.is.focused() && !module.is.visible() && !module.is.empty();
|
409
409
|
},
|
410
410
|
transition: function () {
|
411
|
-
return settings.transition && $.fn.transition !== undefined
|
411
|
+
return settings.transition && $.fn.transition !== undefined;
|
412
412
|
},
|
413
413
|
},
|
414
414
|
|
@@ -116,33 +116,29 @@
|
|
116
116
|
module.set.active();
|
117
117
|
};
|
118
118
|
settings.onBeforeChange.call($nextSide[0]);
|
119
|
-
|
120
|
-
|
119
|
+
module.verbose('Starting CSS animation');
|
120
|
+
$module
|
121
|
+
.addClass(className.animating)
|
122
|
+
;
|
123
|
+
$sides
|
124
|
+
.css(propertyObject)
|
125
|
+
.one('transitionend', callback)
|
126
|
+
;
|
127
|
+
module.set.duration(settings.duration);
|
128
|
+
requestAnimationFrame(function () {
|
121
129
|
$module
|
122
130
|
.addClass(className.animating)
|
123
131
|
;
|
124
|
-
$
|
125
|
-
.
|
126
|
-
.one(module.get.transitionEvent(), callback)
|
132
|
+
$activeSide
|
133
|
+
.addClass(className.hidden)
|
127
134
|
;
|
128
|
-
|
129
|
-
requestAnimationFrame(function () {
|
130
|
-
$module
|
131
|
-
.addClass(className.animating)
|
132
|
-
;
|
133
|
-
$activeSide
|
134
|
-
.addClass(className.hidden)
|
135
|
-
;
|
136
|
-
});
|
137
|
-
} else {
|
138
|
-
callback();
|
139
|
-
}
|
135
|
+
});
|
140
136
|
},
|
141
137
|
|
142
138
|
queue: function (method) {
|
143
139
|
module.debug('Queueing animation of', method);
|
144
140
|
$sides
|
145
|
-
.one(
|
141
|
+
.one('transitionend', function () {
|
146
142
|
module.debug('Executing queued animation');
|
147
143
|
setTimeout(function () {
|
148
144
|
$module.shape(method);
|
@@ -412,24 +408,6 @@
|
|
412
408
|
},
|
413
409
|
},
|
414
410
|
|
415
|
-
transitionEvent: function () {
|
416
|
-
var
|
417
|
-
element = document.createElement('element'),
|
418
|
-
transitions = {
|
419
|
-
transition: 'transitionend',
|
420
|
-
OTransition: 'oTransitionEnd',
|
421
|
-
MozTransition: 'transitionend',
|
422
|
-
WebkitTransition: 'webkitTransitionEnd',
|
423
|
-
},
|
424
|
-
transition
|
425
|
-
;
|
426
|
-
for (transition in transitions) {
|
427
|
-
if (element.style[transition] !== undefined) {
|
428
|
-
return transitions[transition];
|
429
|
-
}
|
430
|
-
}
|
431
|
-
},
|
432
|
-
|
433
411
|
nextSide: function () {
|
434
412
|
return $activeSide.next(selector.side).length > 0
|
435
413
|
? $activeSide.next(selector.side)
|
@@ -69,7 +69,6 @@
|
|
69
69
|
elementNamespace,
|
70
70
|
id,
|
71
71
|
currentScroll,
|
72
|
-
transitionEvent,
|
73
72
|
initialBodyMargin = '',
|
74
73
|
tempBodyMargin = '',
|
75
74
|
hadScrollbar = false,
|
@@ -84,8 +83,6 @@
|
|
84
83
|
|
85
84
|
module.create.id();
|
86
85
|
|
87
|
-
transitionEvent = module.get.transitionEvent();
|
88
|
-
|
89
86
|
// avoids locking rendering if initialized in onReady
|
90
87
|
if (settings.delaySetup) {
|
91
88
|
requestAnimationFrame(module.setup.layout);
|
@@ -492,13 +489,13 @@
|
|
492
489
|
};
|
493
490
|
transitionEnd = function (event) {
|
494
491
|
if (event.target === $transition[0]) {
|
495
|
-
$transition.off(
|
492
|
+
$transition.off('transitionend' + elementNamespace, transitionEnd);
|
496
493
|
module.remove.animating();
|
497
494
|
callback.call(element);
|
498
495
|
}
|
499
496
|
};
|
500
|
-
$transition.off(
|
501
|
-
$transition.on(
|
497
|
+
$transition.off('transitionend' + elementNamespace);
|
498
|
+
$transition.on('transitionend' + elementNamespace, transitionEnd);
|
502
499
|
requestAnimationFrame(animate);
|
503
500
|
if (settings.dimPage && !module.othersVisible()) {
|
504
501
|
requestAnimationFrame(dim);
|
@@ -532,7 +529,7 @@
|
|
532
529
|
};
|
533
530
|
transitionEnd = function (event) {
|
534
531
|
if (event.target === $transition[0]) {
|
535
|
-
$transition.off(
|
532
|
+
$transition.off('transitionend' + elementNamespace, transitionEnd);
|
536
533
|
module.remove.animating();
|
537
534
|
module.remove.closing();
|
538
535
|
module.remove.transition();
|
@@ -546,8 +543,8 @@
|
|
546
543
|
callback.call(element);
|
547
544
|
}
|
548
545
|
};
|
549
|
-
$transition.off(
|
550
|
-
$transition.on(
|
546
|
+
$transition.off('transitionend' + elementNamespace);
|
547
|
+
$transition.on('transitionend' + elementNamespace, transitionEnd);
|
551
548
|
requestAnimationFrame(animate);
|
552
549
|
},
|
553
550
|
|
@@ -722,23 +719,6 @@
|
|
722
719
|
|
723
720
|
return transition;
|
724
721
|
},
|
725
|
-
transitionEvent: function () {
|
726
|
-
var
|
727
|
-
element = document.createElement('element'),
|
728
|
-
transitions = {
|
729
|
-
transition: 'transitionend',
|
730
|
-
OTransition: 'oTransitionEnd',
|
731
|
-
MozTransition: 'transitionend',
|
732
|
-
WebkitTransition: 'webkitTransitionEnd',
|
733
|
-
},
|
734
|
-
transition
|
735
|
-
;
|
736
|
-
for (transition in transitions) {
|
737
|
-
if (element.style[transition] !== undefined) {
|
738
|
-
return transitions[transition];
|
739
|
-
}
|
740
|
-
}
|
741
|
-
},
|
742
722
|
},
|
743
723
|
has: {
|
744
724
|
scrollbar: function () {
|
@@ -397,7 +397,7 @@
|
|
397
397
|
animate: {
|
398
398
|
show: function (callback) {
|
399
399
|
callback = isFunction(callback) ? callback : function () {};
|
400
|
-
if (settings.transition && module.can.useElement('transition')
|
400
|
+
if (settings.transition && module.can.useElement('transition')) {
|
401
401
|
module.set.visible();
|
402
402
|
$toastBox
|
403
403
|
.transition({
|
@@ -417,7 +417,7 @@
|
|
417
417
|
},
|
418
418
|
close: function (callback) {
|
419
419
|
callback = isFunction(callback) ? callback : function () {};
|
420
|
-
if (settings.transition && $.fn.transition !== undefined
|
420
|
+
if (settings.transition && $.fn.transition !== undefined) {
|
421
421
|
$toastBox
|
422
422
|
.transition({
|
423
423
|
animation: settings.transition.hideMethod + ' out',
|
@@ -46,7 +46,6 @@
|
|
46
46
|
error,
|
47
47
|
className,
|
48
48
|
metadata,
|
49
|
-
animationEnd,
|
50
49
|
|
51
50
|
moduleNamespace,
|
52
51
|
eventNamespace,
|
@@ -69,9 +68,6 @@
|
|
69
68
|
moduleNamespace = 'module-' + settings.namespace;
|
70
69
|
instance = $module.data(moduleNamespace) || module;
|
71
70
|
|
72
|
-
// get vendor specific events
|
73
|
-
animationEnd = module.get.animationEndEvent();
|
74
|
-
|
75
71
|
if (methodInvoked) {
|
76
72
|
methodInvoked = module.invoke(query);
|
77
73
|
}
|
@@ -152,11 +148,7 @@
|
|
152
148
|
|
153
149
|
animate: function (overrideSettings) {
|
154
150
|
settings = overrideSettings || settings;
|
155
|
-
if (!module.is.supported()) {
|
156
|
-
module.error(error.support);
|
157
151
|
|
158
|
-
return false;
|
159
|
-
}
|
160
152
|
module.debug('Preparing animation', settings.animation);
|
161
153
|
if (module.is.animating()) {
|
162
154
|
if (settings.queue) {
|
@@ -195,7 +187,7 @@
|
|
195
187
|
module.debug('Queueing animation of', animation);
|
196
188
|
module.queuing = true;
|
197
189
|
$module
|
198
|
-
.one(
|
190
|
+
.one('animationend.queue' + eventNamespace, function () {
|
199
191
|
module.queuing = false;
|
200
192
|
module.repaint();
|
201
193
|
module.animate.apply(this, settings);
|
@@ -216,7 +208,7 @@
|
|
216
208
|
module.restore.conditions();
|
217
209
|
module.hide();
|
218
210
|
} else if (module.is.inward()) {
|
219
|
-
module.verbose('Animation is
|
211
|
+
module.verbose('Animation is inward, showing element');
|
220
212
|
module.restore.conditions();
|
221
213
|
module.show();
|
222
214
|
} else {
|
@@ -375,7 +367,7 @@
|
|
375
367
|
module.debug('Starting tween', animationClass);
|
376
368
|
$module
|
377
369
|
.addClass(animationClass)
|
378
|
-
.one(
|
370
|
+
.one('animationend.complete' + eventNamespace, module.complete)
|
379
371
|
;
|
380
372
|
if (settings.useFailSafe) {
|
381
373
|
module.add.failSafe();
|
@@ -424,7 +416,7 @@
|
|
424
416
|
duration = module.get.duration()
|
425
417
|
;
|
426
418
|
module.timer = setTimeout(function () {
|
427
|
-
$module.triggerHandler(
|
419
|
+
$module.triggerHandler('animationend');
|
428
420
|
}, duration + settings.failSafeDelay);
|
429
421
|
module.verbose('Adding fail safe timer', module.timer);
|
430
422
|
},
|
@@ -612,45 +604,6 @@
|
|
612
604
|
transitionExists: function (animation) {
|
613
605
|
return $.fn.transition.exists[animation];
|
614
606
|
},
|
615
|
-
animationStartEvent: function () {
|
616
|
-
var
|
617
|
-
element = document.createElement('div'),
|
618
|
-
animations = {
|
619
|
-
animation: 'animationstart',
|
620
|
-
OAnimation: 'oAnimationStart',
|
621
|
-
MozAnimation: 'mozAnimationStart',
|
622
|
-
WebkitAnimation: 'webkitAnimationStart',
|
623
|
-
},
|
624
|
-
animation
|
625
|
-
;
|
626
|
-
for (animation in animations) {
|
627
|
-
if (element.style[animation] !== undefined) {
|
628
|
-
return animations[animation];
|
629
|
-
}
|
630
|
-
}
|
631
|
-
|
632
|
-
return false;
|
633
|
-
},
|
634
|
-
animationEndEvent: function () {
|
635
|
-
var
|
636
|
-
element = document.createElement('div'),
|
637
|
-
animations = {
|
638
|
-
animation: 'animationend',
|
639
|
-
OAnimation: 'oAnimationEnd',
|
640
|
-
MozAnimation: 'mozAnimationEnd',
|
641
|
-
WebkitAnimation: 'webkitAnimationEnd',
|
642
|
-
},
|
643
|
-
animation
|
644
|
-
;
|
645
|
-
for (animation in animations) {
|
646
|
-
if (element.style[animation] !== undefined) {
|
647
|
-
return animations[animation];
|
648
|
-
}
|
649
|
-
}
|
650
|
-
|
651
|
-
return false;
|
652
|
-
},
|
653
|
-
|
654
607
|
},
|
655
608
|
|
656
609
|
can: {
|
@@ -750,7 +703,8 @@
|
|
750
703
|
return $module.css('visibility') === 'hidden';
|
751
704
|
},
|
752
705
|
supported: function () {
|
753
|
-
|
706
|
+
// keep method for backward compatibility until 2.10.0
|
707
|
+
return true;
|
754
708
|
},
|
755
709
|
},
|
756
710
|
|
@@ -801,13 +755,13 @@
|
|
801
755
|
|
802
756
|
stop: function () {
|
803
757
|
module.debug('Stopping current animation');
|
804
|
-
$module.triggerHandler(
|
758
|
+
$module.triggerHandler('animationend');
|
805
759
|
},
|
806
760
|
|
807
761
|
stopAll: function () {
|
808
762
|
module.debug('Stopping all animation');
|
809
763
|
module.remove.queueCallback();
|
810
|
-
$module.triggerHandler(
|
764
|
+
$module.triggerHandler('animationend');
|
811
765
|
},
|
812
766
|
|
813
767
|
clear: {
|
@@ -945,8 +899,7 @@
|
|
945
899
|
$.each(query, function (depth, value) {
|
946
900
|
var camelCaseValue = depth !== maxDepth
|
947
901
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
948
|
-
: query
|
949
|
-
;
|
902
|
+
: query;
|
950
903
|
if ($.isPlainObject(object[camelCaseValue]) && (depth !== maxDepth)) {
|
951
904
|
object = object[camelCaseValue];
|
952
905
|
} else if (object[camelCaseValue] !== undefined) {
|
@@ -960,8 +913,6 @@
|
|
960
913
|
|
961
914
|
return false;
|
962
915
|
} else {
|
963
|
-
module.error(error.method, query);
|
964
|
-
|
965
916
|
return false;
|
966
917
|
}
|
967
918
|
});
|
@@ -1077,8 +1028,6 @@
|
|
1077
1028
|
// possible errors
|
1078
1029
|
error: {
|
1079
1030
|
noAnimation: 'Element is no longer attached to DOM. Unable to animate. Use silent setting to suppress this warning in production.',
|
1080
|
-
method: 'The method you called is not defined',
|
1081
|
-
support: 'This browser does not support CSS animations',
|
1082
1031
|
},
|
1083
1032
|
|
1084
1033
|
};
|
package/src/theme.less
CHANGED
@@ -16,14 +16,10 @@
|
|
16
16
|
@import "@{themesFolder}/default/globals/site.variables";
|
17
17
|
|
18
18
|
/* Packaged site.variables */
|
19
|
-
|
20
|
-
@import (optional) "@{themesFolder}/@{site}/globals/site.variables";
|
21
|
-
}
|
19
|
+
@import (optional) "@{themesFolder}/@{site}/globals/site.variables";
|
22
20
|
|
23
21
|
/* Component's site.variables */
|
24
|
-
|
25
|
-
@import (optional) "@{themesFolder}/@{theme}/globals/site.variables";
|
26
|
-
}
|
22
|
+
@import (optional) "@{themesFolder}/@{theme}/globals/site.variables";
|
27
23
|
|
28
24
|
/* Site theme site.variables */
|
29
25
|
@import (optional) "@{siteFolder}/globals/site.variables";
|
@@ -49,14 +45,10 @@
|
|
49
45
|
@import "@{themesFolder}/default/globals/colors.less";
|
50
46
|
|
51
47
|
/* Packaged colors.less */
|
52
|
-
|
53
|
-
@import (optional) "@{themesFolder}/@{site}/globals/colors.less";
|
54
|
-
}
|
48
|
+
@import (optional) "@{themesFolder}/@{site}/globals/colors.less";
|
55
49
|
|
56
50
|
/* Packaged Theme */
|
57
|
-
|
58
|
-
@import (optional) "@{themesFolder}/@{theme}/globals/colors.less";
|
59
|
-
}
|
51
|
+
@import (optional) "@{themesFolder}/@{theme}/globals/colors.less";
|
60
52
|
|
61
53
|
/* Site Theme */
|
62
54
|
@import (optional) "@{siteFolder}/globals/colors.less";
|
@@ -428,9 +428,7 @@
|
|
428
428
|
@attachedWidth: e(%("calc(100%% + %d)", -@attachedHorizontalOffset * 2));
|
429
429
|
@attachedBoxShadow: none;
|
430
430
|
@attachedBorder: @borderWidth solid @solidBorderColor;
|
431
|
-
@attachedBottomBoxShadow:
|
432
|
-
@boxShadow,
|
433
|
-
@attachedBoxShadow;
|
431
|
+
@attachedBottomBoxShadow: @attachedBoxShadow;
|
434
432
|
|
435
433
|
/* Resize large sizes */
|
436
434
|
@mini: @11px;
|
@@ -166,9 +166,7 @@
|
|
166
166
|
@attachedWidth: e(%("calc(100%% + %d)", -@attachedHorizontalOffset * 2));
|
167
167
|
@attachedBoxShadow: none;
|
168
168
|
@attachedBorder: @borderWidth solid @solidBorderColor;
|
169
|
-
@attachedBottomBoxShadow:
|
170
|
-
@boxShadow,
|
171
|
-
@attachedBoxShadow;
|
169
|
+
@attachedBottomBoxShadow: @attachedBoxShadow;
|
172
170
|
|
173
171
|
/* Striped */
|
174
172
|
@stripedBackground: rgba(0, 0, 50, 0.02);
|
@@ -104,9 +104,7 @@
|
|
104
104
|
@attachedWidth: e(%("calc(100%% + %d)", -@attachedHorizontalOffset * 2));
|
105
105
|
@attachedBoxShadow: none;
|
106
106
|
@attachedBorder: @borderWidth solid @solidBorderColor;
|
107
|
-
@attachedBottomBoxShadow:
|
108
|
-
@boxShadow,
|
109
|
-
@attachedBoxShadow;
|
107
|
+
@attachedBottomBoxShadow: @bottomShadow;
|
110
108
|
|
111
109
|
/* Inverted */
|
112
110
|
@invertedBackground: @black;
|