uikit 3.14.4-dev.6a00f7fe6 → 3.14.4-dev.ca199f7a7

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 (59) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/dist/css/uikit-core-rtl.css +22 -12
  3. package/dist/css/uikit-core-rtl.min.css +1 -1
  4. package/dist/css/uikit-core.css +22 -12
  5. package/dist/css/uikit-core.min.css +1 -1
  6. package/dist/css/uikit-rtl.css +19 -12
  7. package/dist/css/uikit-rtl.min.css +1 -1
  8. package/dist/css/uikit.css +19 -12
  9. package/dist/css/uikit.min.css +1 -1
  10. package/dist/js/components/countdown.js +1 -1
  11. package/dist/js/components/countdown.min.js +1 -1
  12. package/dist/js/components/filter.js +1 -1
  13. package/dist/js/components/filter.min.js +1 -1
  14. package/dist/js/components/lightbox-panel.js +89 -5
  15. package/dist/js/components/lightbox-panel.min.js +1 -1
  16. package/dist/js/components/lightbox.js +89 -5
  17. package/dist/js/components/lightbox.min.js +1 -1
  18. package/dist/js/components/notification.js +1 -1
  19. package/dist/js/components/notification.min.js +1 -1
  20. package/dist/js/components/parallax.js +1 -1
  21. package/dist/js/components/parallax.min.js +1 -1
  22. package/dist/js/components/slider-parallax.js +1 -1
  23. package/dist/js/components/slider-parallax.min.js +1 -1
  24. package/dist/js/components/slider.js +1 -1
  25. package/dist/js/components/slider.min.js +1 -1
  26. package/dist/js/components/slideshow-parallax.js +1 -1
  27. package/dist/js/components/slideshow-parallax.min.js +1 -1
  28. package/dist/js/components/slideshow.js +1 -1
  29. package/dist/js/components/slideshow.min.js +1 -1
  30. package/dist/js/components/sortable.js +1 -1
  31. package/dist/js/components/sortable.min.js +1 -1
  32. package/dist/js/components/tooltip.js +1 -1
  33. package/dist/js/components/tooltip.min.js +1 -1
  34. package/dist/js/components/upload.js +1 -1
  35. package/dist/js/components/upload.min.js +1 -1
  36. package/dist/js/uikit-core.js +667 -612
  37. package/dist/js/uikit-core.min.js +1 -1
  38. package/dist/js/uikit-icons.js +1 -1
  39. package/dist/js/uikit-icons.min.js +1 -1
  40. package/dist/js/uikit.js +667 -612
  41. package/dist/js/uikit.min.js +1 -1
  42. package/package.json +1 -1
  43. package/src/js/core/drop.js +7 -0
  44. package/src/js/core/offcanvas.js +1 -47
  45. package/src/js/mixin/modal.js +90 -4
  46. package/src/js/util/viewport.js +20 -9
  47. package/src/less/components/nav.less +22 -4
  48. package/src/less/components/navbar.less +8 -11
  49. package/src/less/theme/nav.less +3 -7
  50. package/src/less/theme/navbar.less +3 -1
  51. package/src/scss/components/nav.scss +22 -4
  52. package/src/scss/components/navbar.scss +8 -11
  53. package/src/scss/mixins-theme.scss +1 -1
  54. package/src/scss/theme/nav.scss +3 -7
  55. package/src/scss/theme/navbar.scss +3 -1
  56. package/src/scss/variables-theme.scss +10 -4
  57. package/src/scss/variables.scss +10 -3
  58. package/tests/drop.html +6 -0
  59. package/tests/navbar.html +2041 -1267
@@ -1,4 +1,4 @@
1
- /*! UIkit 3.14.4-dev.6a00f7fe6 | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */
1
+ /*! UIkit 3.14.4-dev.ca199f7a7 | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */
2
2
 
3
3
  (function (global, factory) {
4
4
  typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
@@ -1911,18 +1911,33 @@
1911
1911
  }
1912
1912
 
1913
1913
  function offsetViewport(scrollElement) {
1914
- let viewportElement = getViewport$1(scrollElement);
1914
+ const window = toWindow(scrollElement);
1915
+ const {
1916
+ document: { body, documentElement } } =
1917
+ window;
1918
+ let viewportElement =
1919
+ scrollElement === scrollingElement(scrollElement) || scrollElement === body ?
1920
+ window :
1921
+ scrollElement;
1922
+
1923
+ const { visualViewport } = window;
1924
+ if (isWindow(viewportElement) && visualViewport) {
1925
+ let { height, width, scale, pageTop: top, pageLeft: left } = visualViewport;
1926
+ height = Math.round(height * scale);
1927
+ width = Math.round(width * scale);
1928
+ return { height, width, top, left, bottom: top + height, right: left + width };
1929
+ }
1915
1930
 
1916
1931
  let rect = offset(viewportElement);
1917
1932
  for (let [prop, dir, start, end] of [
1918
1933
  ['width', 'x', 'left', 'right'],
1919
1934
  ['height', 'y', 'top', 'bottom']])
1920
1935
  {
1921
- if (!isWindow(viewportElement)) {
1922
- rect[start] += toFloat(css(viewportElement, "border" + ucfirst(start) + "Width"));
1923
- } else {
1936
+ if (isWindow(viewportElement)) {
1924
1937
  // iOS 12 returns <body> as scrollingElement
1925
- viewportElement = viewportElement.document.documentElement;
1938
+ viewportElement = documentElement;
1939
+ } else {
1940
+ rect[start] += toFloat(css(viewportElement, "border" + ucfirst(start) + "Width"));
1926
1941
  }
1927
1942
  rect[prop] = rect[dir] = viewportElement["client" + ucfirst(prop)];
1928
1943
  rect[end] = rect[prop] + rect[start];
@@ -1934,10 +1949,6 @@
1934
1949
  return toWindow(element).document.scrollingElement;
1935
1950
  }
1936
1951
 
1937
- function getViewport$1(scrollElement) {
1938
- return scrollElement === scrollingElement(scrollElement) ? window : scrollElement;
1939
- }
1940
-
1941
1952
  const dirs = [
1942
1953
  ['width', 'x', 'left', 'right'],
1943
1954
  ['height', 'y', 'top', 'bottom']];
@@ -2950,7 +2961,7 @@
2950
2961
  UIkit.data = '__uikit__';
2951
2962
  UIkit.prefix = 'uk-';
2952
2963
  UIkit.options = {};
2953
- UIkit.version = '3.14.4-dev.6a00f7fe6';
2964
+ UIkit.version = '3.14.4-dev.ca199f7a7';
2954
2965
 
2955
2966
  globalAPI(UIkit);
2956
2967
  hooksAPI(UIkit);
@@ -3724,64 +3735,44 @@
3724
3735
  return toPx(getCssVar('position-viewport-offset', element));
3725
3736
  } } };
3726
3737
 
3727
- let active$1;
3728
-
3729
- var drop = {
3730
- mixins: [Container, Lazyload, Position, Togglable],
3738
+ const active$1 = [];
3731
3739
 
3732
- args: 'pos',
3740
+ var Modal = {
3741
+ mixins: [Class, Container, Togglable],
3733
3742
 
3734
3743
  props: {
3735
- mode: 'list',
3736
- toggle: Boolean,
3737
- boundary: Boolean,
3738
- boundaryAlign: Boolean,
3739
- delayShow: Number,
3740
- delayHide: Number,
3741
- display: String,
3742
- clsDrop: String,
3743
- animateOut: Boolean },
3744
+ selPanel: String,
3745
+ selClose: String,
3746
+ escClose: Boolean,
3747
+ bgClose: Boolean,
3748
+ stack: Boolean },
3744
3749
 
3745
3750
 
3746
3751
  data: {
3747
- mode: ['click', 'hover'],
3748
- toggle: '- *',
3749
- boundary: true,
3750
- boundaryAlign: false,
3751
- delayShow: 0,
3752
- delayHide: 800,
3753
- display: null,
3754
- clsDrop: false,
3755
- animation: ['uk-animation-fade'],
3756
3752
  cls: 'uk-open',
3757
- container: false,
3758
- animateOut: false },
3753
+ escClose: true,
3754
+ bgClose: true,
3755
+ overlay: true,
3756
+ stack: false },
3759
3757
 
3760
3758
 
3761
- created() {
3762
- this.tracker = new MouseTracker();
3763
- },
3759
+ computed: {
3760
+ panel(_ref, $el) {let { selPanel } = _ref;
3761
+ return $(selPanel, $el);
3762
+ },
3764
3763
 
3765
- beforeConnect() {
3766
- this.clsDrop = this.$props.clsDrop || "uk-" + this.$options.name;
3767
- },
3764
+ transitionElement() {
3765
+ return this.panel;
3766
+ },
3768
3767
 
3769
- connected() {
3770
- addClass(this.$el, this.clsDrop);
3768
+ bgClose(_ref2) {let { bgClose } = _ref2;
3769
+ return bgClose && this.panel;
3770
+ } },
3771
3771
 
3772
- if (this.toggle && !this.target) {
3773
- this.target = this.$create('toggle', query(this.toggle, this.$el), {
3774
- target: this.$el,
3775
- mode: this.mode }).
3776
- $el;
3777
- attr(this.target, 'aria-haspopup', true);
3778
- this.lazyload(this.target);
3779
- }
3780
- },
3781
3772
 
3782
- disconnected() {
3783
- if (this.isActive()) {
3784
- active$1 = null;
3773
+ beforeDisconnect() {
3774
+ if (includes(active$1, this)) {
3775
+ this.toggleElement(this.$el, false, false);
3785
3776
  }
3786
3777
  },
3787
3778
 
@@ -3790,34 +3781,12 @@
3790
3781
  name: 'click',
3791
3782
 
3792
3783
  delegate() {
3793
- return "." + this.clsDrop + "-close";
3784
+ return this.selClose;
3794
3785
  },
3795
3786
 
3796
3787
  handler(e) {
3797
3788
  e.preventDefault();
3798
- this.hide(false);
3799
- } },
3800
-
3801
-
3802
- {
3803
- name: 'click',
3804
-
3805
- delegate() {
3806
- return 'a[href^="#"]';
3807
- },
3808
-
3809
- handler(_ref) {let { defaultPrevented, current: { hash } } = _ref;
3810
- if (!defaultPrevented && hash && !within(hash, this.$el)) {
3811
- this.hide(false);
3812
- }
3813
- } },
3814
-
3815
-
3816
- {
3817
- name: 'beforescroll',
3818
-
3819
- handler() {
3820
- this.hide(false);
3789
+ this.hide();
3821
3790
  } },
3822
3791
 
3823
3792
 
@@ -3826,168 +3795,551 @@
3826
3795
 
3827
3796
  self: true,
3828
3797
 
3829
- handler(e, toggle) {
3830
- e.preventDefault();
3831
-
3832
- if (this.isToggled()) {
3833
- this.hide(false);
3834
- } else {
3835
- this.show(toggle == null ? void 0 : toggle.$el, false);
3798
+ handler(e) {
3799
+ if (e.defaultPrevented) {
3800
+ return;
3836
3801
  }
3837
- } },
3838
-
3839
-
3840
- {
3841
- name: 'toggleshow',
3842
-
3843
- self: true,
3844
3802
 
3845
- handler(e, toggle) {
3846
3803
  e.preventDefault();
3847
- this.show(toggle == null ? void 0 : toggle.$el);
3848
- } },
3849
-
3850
3804
 
3851
- {
3852
- name: 'togglehide',
3853
-
3854
- self: true,
3855
-
3856
- handler(e) {
3857
- e.preventDefault();
3858
- if (!matches(this.$el, ':focus,:hover')) {
3859
- this.hide();
3805
+ if (this.isToggled() === includes(active$1, this)) {
3806
+ this.toggle();
3860
3807
  }
3861
3808
  } },
3862
3809
 
3863
3810
 
3864
3811
  {
3865
- name: pointerEnter + " focusin",
3812
+ name: 'beforeshow',
3866
3813
 
3867
- filter() {
3868
- return includes(this.mode, 'hover');
3869
- },
3814
+ self: true,
3870
3815
 
3871
3816
  handler(e) {
3872
- if (!isTouch(e)) {
3873
- this.clearTimers();
3817
+ if (includes(active$1, this)) {
3818
+ return false;
3874
3819
  }
3875
- } },
3876
-
3877
-
3878
- {
3879
- name: pointerLeave + " focusout",
3880
3820
 
3881
- filter() {
3882
- return includes(this.mode, 'hover');
3883
- },
3884
-
3885
- handler(e) {
3886
- if (!isTouch(e) && e.relatedTarget) {
3887
- this.hide();
3821
+ if (!this.stack && active$1.length) {
3822
+ Promise.all(active$1.map((modal) => modal.hide())).then(this.show);
3823
+ e.preventDefault();
3824
+ } else {
3825
+ active$1.push(this);
3888
3826
  }
3889
3827
  } },
3890
3828
 
3891
3829
 
3892
3830
  {
3893
- name: 'toggled',
3831
+ name: 'show',
3894
3832
 
3895
3833
  self: true,
3896
3834
 
3897
- handler(e, toggled) {
3898
- if (!toggled) {
3899
- return;
3900
- }
3901
-
3902
- this.clearTimers();
3903
- this.position();
3904
- } },
3835
+ handler() {
3836
+ once(
3837
+ this.$el,
3838
+ 'hide',
3839
+ on(document, 'focusin', (e) => {
3840
+ if (last(active$1) === this && !within(e.target, this.$el)) {
3841
+ this.$el.focus();
3842
+ }
3843
+ }));
3905
3844
 
3906
3845
 
3907
- {
3908
- name: 'show',
3846
+ if (this.overlay) {
3847
+ once(this.$el, 'hide', preventOverscroll(this.$el));
3848
+ once(this.$el, 'hide', preventBackgroundScroll());
3849
+ }
3909
3850
 
3910
- self: true,
3851
+ if (this.stack) {
3852
+ css(this.$el, 'zIndex', toFloat(css(this.$el, 'zIndex')) + active$1.length);
3853
+ }
3911
3854
 
3912
- handler() {
3913
- active$1 = this;
3855
+ addClass(document.documentElement, this.clsPage);
3914
3856
 
3915
- this.tracker.init();
3857
+ if (this.bgClose) {
3858
+ once(
3859
+ this.$el,
3860
+ 'hide',
3861
+ on(document, pointerDown, (_ref3) => {let { target } = _ref3;
3862
+ if (
3863
+ last(active$1) !== this ||
3864
+ this.overlay && !within(target, this.$el) ||
3865
+ within(target, this.panel))
3866
+ {
3867
+ return;
3868
+ }
3916
3869
 
3917
- for (const handler of [
3918
- on(
3919
- document,
3920
- pointerDown,
3921
- (_ref2) => {let { target } = _ref2;return (
3922
- !within(target, this.$el) &&
3923
3870
  once(
3924
3871
  document,
3925
3872
  pointerUp + " " + pointerCancel + " scroll",
3926
- (_ref3) => {let { defaultPrevented, type, target: newTarget } = _ref3;
3873
+ (_ref4) => {let { defaultPrevented, type, target: newTarget } = _ref4;
3927
3874
  if (
3928
3875
  !defaultPrevented &&
3929
3876
  type === pointerUp &&
3930
- target === newTarget &&
3931
- !(this.target && within(target, this.target)))
3877
+ target === newTarget)
3932
3878
  {
3933
- this.hide(false);
3879
+ this.hide();
3934
3880
  }
3935
3881
  },
3936
- true));}),
3937
-
3938
-
3882
+ true);
3939
3883
 
3940
- on(document, 'keydown', (e) => {
3941
- if (e.keyCode === 27) {
3942
- this.hide(false);
3943
- }
3944
- }),
3884
+ }),
3885
+ { self: true });
3945
3886
 
3946
- ...(this.display === 'static' && this.align !== 'stretch' ?
3947
- [] :
3948
- (() => {
3949
- const handler = () => this.$emit();
3950
- return [
3951
- on(window, 'resize', handler),
3952
- on(document, 'scroll', handler, true),
3953
- (() => {
3954
- const observer = observeResize(
3955
- scrollParents(this.$el),
3956
- handler);
3887
+ }
3957
3888
 
3958
- return () => observer.disconnect();
3959
- })()];
3889
+ if (this.escClose) {
3890
+ once(
3891
+ this.$el,
3892
+ 'hide',
3893
+ on(document, 'keydown', (e) => {
3894
+ if (e.keyCode === 27 && last(active$1) === this) {
3895
+ this.hide();
3896
+ }
3897
+ }),
3898
+ { self: true });
3960
3899
 
3961
- })())])
3962
- {
3963
- once(this.$el, 'hide', handler, { self: true });
3964
3900
  }
3965
3901
  } },
3966
3902
 
3967
3903
 
3968
3904
  {
3969
- name: 'beforehide',
3905
+ name: 'shown',
3970
3906
 
3971
3907
  self: true,
3972
3908
 
3973
3909
  handler() {
3974
- this.clearTimers();
3910
+ if (!isFocusable(this.$el)) {
3911
+ attr(this.$el, 'tabindex', '-1');
3912
+ }
3913
+
3914
+ if (!$(':focus', this.$el)) {
3915
+ this.$el.focus();
3916
+ }
3975
3917
  } },
3976
3918
 
3977
3919
 
3978
3920
  {
3979
- name: 'hide',
3921
+ name: 'hidden',
3980
3922
 
3981
- handler(_ref4) {let { target } = _ref4;
3982
- if (this.$el !== target) {
3983
- active$1 =
3984
- active$1 === null && within(target, this.$el) && this.isToggled() ?
3985
- this :
3986
- active$1;
3987
- return;
3923
+ self: true,
3924
+
3925
+ handler() {
3926
+ if (includes(active$1, this)) {
3927
+ active$1.splice(active$1.indexOf(this), 1);
3988
3928
  }
3989
3929
 
3990
- active$1 = this.isActive() ? null : active$1;
3930
+ if (!active$1.length) {
3931
+ css(document.body, 'overflowY', '');
3932
+ }
3933
+
3934
+ css(this.$el, 'zIndex', '');
3935
+
3936
+ if (!active$1.some((modal) => modal.clsPage === this.clsPage)) {
3937
+ removeClass(document.documentElement, this.clsPage);
3938
+ }
3939
+ } }],
3940
+
3941
+
3942
+
3943
+ methods: {
3944
+ toggle() {
3945
+ return this.isToggled() ? this.hide() : this.show();
3946
+ },
3947
+
3948
+ show() {
3949
+ if (this.container && parent(this.$el) !== this.container) {
3950
+ append(this.container, this.$el);
3951
+ return new Promise((resolve) =>
3952
+ requestAnimationFrame(() => this.show().then(resolve)));
3953
+
3954
+ }
3955
+
3956
+ return this.toggleElement(this.$el, true, animate(this));
3957
+ },
3958
+
3959
+ hide() {
3960
+ return this.toggleElement(this.$el, false, animate(this));
3961
+ } } };
3962
+
3963
+
3964
+
3965
+ function animate(_ref5) {let { transitionElement, _toggle } = _ref5;
3966
+ return (el, show) =>
3967
+ new Promise((resolve, reject) =>
3968
+ once(el, 'show hide', () => {
3969
+ el._reject == null ? void 0 : el._reject();
3970
+ el._reject = reject;
3971
+
3972
+ _toggle(el, show);
3973
+
3974
+ const off = once(
3975
+ transitionElement,
3976
+ 'transitionstart',
3977
+ () => {
3978
+ once(transitionElement, 'transitionend transitioncancel', resolve, {
3979
+ self: true });
3980
+
3981
+ clearTimeout(timer);
3982
+ },
3983
+ { self: true });
3984
+
3985
+
3986
+ const timer = setTimeout(() => {
3987
+ off();
3988
+ resolve();
3989
+ }, toMs(css(transitionElement, 'transitionDuration')));
3990
+ })).
3991
+ then(() => delete el._reject);
3992
+ }
3993
+
3994
+ function toMs(time) {
3995
+ return time ? endsWith(time, 'ms') ? toFloat(time) : toFloat(time) * 1000 : 0;
3996
+ }
3997
+
3998
+ function preventOverscroll(el) {
3999
+ if (CSS.supports('overscroll-behavior', 'contain')) {
4000
+ const elements = filterChildren(el, (child) => /auto|scroll/.test(css(child, 'overflow')));
4001
+ css(elements, 'overscrollBehavior', 'contain');
4002
+ return () => css(elements, 'overscrollBehavior', '');
4003
+ }
4004
+
4005
+ let startClientY;
4006
+
4007
+ const events = [
4008
+ on(
4009
+ el,
4010
+ 'touchstart',
4011
+ (_ref6) => {let { targetTouches } = _ref6;
4012
+ if (targetTouches.length === 1) {
4013
+ startClientY = targetTouches[0].clientY;
4014
+ }
4015
+ },
4016
+ { passive: true }),
4017
+
4018
+
4019
+ on(
4020
+ el,
4021
+ 'touchmove',
4022
+ (e) => {
4023
+ if (e.targetTouches.length !== 1) {
4024
+ return;
4025
+ }
4026
+
4027
+ let [scrollParent] = scrollParents(e.target, /auto|scroll/);
4028
+ if (!within(scrollParent, el)) {
4029
+ scrollParent = el;
4030
+ }
4031
+
4032
+ const clientY = e.targetTouches[0].clientY - startClientY;
4033
+ const { scrollTop, scrollHeight, clientHeight } = scrollParent;
4034
+
4035
+ if (
4036
+ clientHeight >= scrollHeight ||
4037
+ scrollTop === 0 && clientY > 0 ||
4038
+ scrollHeight - scrollTop <= clientHeight && clientY < 0)
4039
+ {
4040
+ e.cancelable && e.preventDefault();
4041
+ }
4042
+ },
4043
+ { passive: false })];
4044
+
4045
+
4046
+
4047
+ return () => events.forEach((fn) => fn());
4048
+ }
4049
+
4050
+ function preventBackgroundScroll() {
4051
+ const { body, documentElement } = document;
4052
+ css(body, {
4053
+ overflowY: width(window) > documentElement.clientWidth ? 'scroll' : '',
4054
+ touchAction: 'none' });
4055
+
4056
+ css(documentElement, 'overflowY', 'hidden');
4057
+ return () => {
4058
+ css(documentElement, 'overflowY', '');
4059
+ css(body, { overflowY: '', touchAction: '' });
4060
+ };
4061
+ }
4062
+
4063
+ function filterChildren(el, fn) {
4064
+ const children = [];
4065
+ apply(el, (node) => {
4066
+ if (fn(node)) {
4067
+ children.push(node);
4068
+ }
4069
+ });
4070
+ return children;
4071
+ }
4072
+
4073
+ let active;
4074
+
4075
+ var drop = {
4076
+ mixins: [Container, Lazyload, Position, Togglable],
4077
+
4078
+ args: 'pos',
4079
+
4080
+ props: {
4081
+ mode: 'list',
4082
+ toggle: Boolean,
4083
+ boundary: Boolean,
4084
+ boundaryAlign: Boolean,
4085
+ delayShow: Number,
4086
+ delayHide: Number,
4087
+ display: String,
4088
+ clsDrop: String,
4089
+ animateOut: Boolean,
4090
+ bgScroll: Boolean },
4091
+
4092
+
4093
+ data: {
4094
+ mode: ['click', 'hover'],
4095
+ toggle: '- *',
4096
+ boundary: true,
4097
+ boundaryAlign: false,
4098
+ delayShow: 0,
4099
+ delayHide: 800,
4100
+ display: null,
4101
+ clsDrop: false,
4102
+ animation: ['uk-animation-fade'],
4103
+ cls: 'uk-open',
4104
+ container: false,
4105
+ animateOut: false,
4106
+ bgScroll: true },
4107
+
4108
+
4109
+ created() {
4110
+ this.tracker = new MouseTracker();
4111
+ },
4112
+
4113
+ beforeConnect() {
4114
+ this.clsDrop = this.$props.clsDrop || "uk-" + this.$options.name;
4115
+ },
4116
+
4117
+ connected() {
4118
+ addClass(this.$el, this.clsDrop);
4119
+
4120
+ if (this.toggle && !this.target) {
4121
+ this.target = this.$create('toggle', query(this.toggle, this.$el), {
4122
+ target: this.$el,
4123
+ mode: this.mode }).
4124
+ $el;
4125
+ attr(this.target, 'aria-haspopup', true);
4126
+ this.lazyload(this.target);
4127
+ }
4128
+ },
4129
+
4130
+ disconnected() {
4131
+ if (this.isActive()) {
4132
+ active = null;
4133
+ }
4134
+ },
4135
+
4136
+ events: [
4137
+ {
4138
+ name: 'click',
4139
+
4140
+ delegate() {
4141
+ return "." + this.clsDrop + "-close";
4142
+ },
4143
+
4144
+ handler(e) {
4145
+ e.preventDefault();
4146
+ this.hide(false);
4147
+ } },
4148
+
4149
+
4150
+ {
4151
+ name: 'click',
4152
+
4153
+ delegate() {
4154
+ return 'a[href^="#"]';
4155
+ },
4156
+
4157
+ handler(_ref) {let { defaultPrevented, current: { hash } } = _ref;
4158
+ if (!defaultPrevented && hash && !within(hash, this.$el)) {
4159
+ this.hide(false);
4160
+ }
4161
+ } },
4162
+
4163
+
4164
+ {
4165
+ name: 'beforescroll',
4166
+
4167
+ handler() {
4168
+ this.hide(false);
4169
+ } },
4170
+
4171
+
4172
+ {
4173
+ name: 'toggle',
4174
+
4175
+ self: true,
4176
+
4177
+ handler(e, toggle) {
4178
+ e.preventDefault();
4179
+
4180
+ if (this.isToggled()) {
4181
+ this.hide(false);
4182
+ } else {
4183
+ this.show(toggle == null ? void 0 : toggle.$el, false);
4184
+ }
4185
+ } },
4186
+
4187
+
4188
+ {
4189
+ name: 'toggleshow',
4190
+
4191
+ self: true,
4192
+
4193
+ handler(e, toggle) {
4194
+ e.preventDefault();
4195
+ this.show(toggle == null ? void 0 : toggle.$el);
4196
+ } },
4197
+
4198
+
4199
+ {
4200
+ name: 'togglehide',
4201
+
4202
+ self: true,
4203
+
4204
+ handler(e) {
4205
+ e.preventDefault();
4206
+ if (!matches(this.$el, ':focus,:hover')) {
4207
+ this.hide();
4208
+ }
4209
+ } },
4210
+
4211
+
4212
+ {
4213
+ name: pointerEnter + " focusin",
4214
+
4215
+ filter() {
4216
+ return includes(this.mode, 'hover');
4217
+ },
4218
+
4219
+ handler(e) {
4220
+ if (!isTouch(e)) {
4221
+ this.clearTimers();
4222
+ }
4223
+ } },
4224
+
4225
+
4226
+ {
4227
+ name: pointerLeave + " focusout",
4228
+
4229
+ filter() {
4230
+ return includes(this.mode, 'hover');
4231
+ },
4232
+
4233
+ handler(e) {
4234
+ if (!isTouch(e) && e.relatedTarget) {
4235
+ this.hide();
4236
+ }
4237
+ } },
4238
+
4239
+
4240
+ {
4241
+ name: 'toggled',
4242
+
4243
+ self: true,
4244
+
4245
+ handler(e, toggled) {
4246
+ if (!toggled) {
4247
+ return;
4248
+ }
4249
+
4250
+ this.clearTimers();
4251
+ this.position();
4252
+ } },
4253
+
4254
+
4255
+ {
4256
+ name: 'show',
4257
+
4258
+ self: true,
4259
+
4260
+ handler() {
4261
+ active = this;
4262
+
4263
+ this.tracker.init();
4264
+
4265
+ for (const handler of [
4266
+ on(
4267
+ document,
4268
+ pointerDown,
4269
+ (_ref2) => {let { target } = _ref2;return (
4270
+ !within(target, this.$el) &&
4271
+ once(
4272
+ document,
4273
+ pointerUp + " " + pointerCancel + " scroll",
4274
+ (_ref3) => {let { defaultPrevented, type, target: newTarget } = _ref3;
4275
+ if (
4276
+ !defaultPrevented &&
4277
+ type === pointerUp &&
4278
+ target === newTarget &&
4279
+ !(this.target && within(target, this.target)))
4280
+ {
4281
+ this.hide(false);
4282
+ }
4283
+ },
4284
+ true));}),
4285
+
4286
+
4287
+
4288
+ on(document, 'keydown', (e) => {
4289
+ if (e.keyCode === 27) {
4290
+ this.hide(false);
4291
+ }
4292
+ }),
4293
+
4294
+ ...(this.bgScroll ?
4295
+ [] :
4296
+ [preventOverscroll(this.$el), preventBackgroundScroll()]),
4297
+
4298
+ ...(this.display === 'static' && this.align !== 'stretch' ?
4299
+ [] :
4300
+ (() => {
4301
+ const handler = () => this.$emit();
4302
+ return [
4303
+ on(window, 'resize', handler),
4304
+ on(document, 'scroll', handler, true),
4305
+ (() => {
4306
+ const observer = observeResize(
4307
+ scrollParents(this.$el),
4308
+ handler);
4309
+
4310
+ return () => observer.disconnect();
4311
+ })()];
4312
+
4313
+ })())])
4314
+ {
4315
+ once(this.$el, 'hide', handler, { self: true });
4316
+ }
4317
+ } },
4318
+
4319
+
4320
+ {
4321
+ name: 'beforehide',
4322
+
4323
+ self: true,
4324
+
4325
+ handler() {
4326
+ this.clearTimers();
4327
+ } },
4328
+
4329
+
4330
+ {
4331
+ name: 'hide',
4332
+
4333
+ handler(_ref4) {let { target } = _ref4;
4334
+ if (this.$el !== target) {
4335
+ active =
4336
+ active === null && within(target, this.$el) && this.isToggled() ?
4337
+ this :
4338
+ active;
4339
+ return;
4340
+ }
4341
+
4342
+ active = this.isActive() ? null : active;
3991
4343
  this.tracker.cancel();
3992
4344
  } }],
3993
4345
 
@@ -4015,16 +4367,16 @@
4015
4367
  return;
4016
4368
  }
4017
4369
 
4018
- if (active$1) {
4019
- if (delay && active$1.isDelaying) {
4370
+ if (active) {
4371
+ if (delay && active.isDelaying) {
4020
4372
  this.showTimer = setTimeout(() => matches(target, ':hover') && this.show(), 10);
4021
4373
  return;
4022
4374
  }
4023
4375
 
4024
4376
  let prev;
4025
- while (active$1 && prev !== active$1 && !within(this.$el, active$1.$el)) {
4026
- prev = active$1;
4027
- active$1.hide(false, false);
4377
+ while (active && prev !== active && !within(this.$el, active.$el)) {
4378
+ prev = active;
4379
+ active.hide(false, false);
4028
4380
  }
4029
4381
  }
4030
4382
 
@@ -4065,7 +4417,7 @@
4065
4417
  },
4066
4418
 
4067
4419
  isActive() {
4068
- return active$1 === this;
4420
+ return active === this;
4069
4421
  },
4070
4422
 
4071
4423
  position() {
@@ -5152,414 +5504,163 @@
5152
5504
  function setSourceProps(sourceEl, targetEl) {
5153
5505
  srcProps.forEach((prop) => {
5154
5506
  const value = data(sourceEl, prop);
5155
- if (value) {
5156
- attr(targetEl, prop.replace(/^(data-)+/, ''), value);
5157
- }
5158
- });
5159
- }
5160
-
5161
- function getImageFromElement(el, src, sources) {
5162
- const img = new Image();
5163
-
5164
- wrapInPicture(img, sources);
5165
- setSourceProps(el, img);
5166
- img.onload = () => {
5167
- setSrcAttrs(el, img.currentSrc);
5168
- };
5169
- attr(img, 'src', src);
5170
- return img;
5171
- }
5172
-
5173
- function wrapInPicture(img, sources) {
5174
- sources = parseSources(sources);
5175
-
5176
- if (sources.length) {
5177
- const picture = fragment('<picture>');
5178
- for (const attrs of sources) {
5179
- const source = fragment('<source>');
5180
- attr(source, attrs);
5181
- append(picture, source);
5182
- }
5183
- append(picture, img);
5184
- }
5185
- }
5186
-
5187
- function parseSources(sources) {
5188
- if (!sources) {
5189
- return [];
5190
- }
5191
-
5192
- if (startsWith(sources, '[')) {
5193
- try {
5194
- sources = JSON.parse(sources);
5195
- } catch (e) {
5196
- sources = [];
5197
- }
5198
- } else {
5199
- sources = parseOptions(sources);
5200
- }
5201
-
5202
- if (!isArray(sources)) {
5203
- sources = [sources];
5204
- }
5205
-
5206
- return sources.filter((source) => !isEmpty(source));
5207
- }
5208
-
5209
- function ensureSrcAttribute(el) {
5210
- if (isImg(el) && !hasAttr(el, 'src')) {
5211
- attr(el, 'src', 'data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg"></svg>');
5212
- }
5213
- }
5214
-
5215
- function isPicture(el) {
5216
- return isTag(el, 'picture');
5217
- }
5218
-
5219
- function isImg(el) {
5220
- return isTag(el, 'img');
5221
- }
5222
-
5223
- var Media = {
5224
- props: {
5225
- media: Boolean },
5226
-
5227
-
5228
- data: {
5229
- media: false },
5230
-
5231
-
5232
- connected() {
5233
- const media = toMedia(this.media);
5234
- this.matchMedia = true;
5235
- if (media) {
5236
- this.mediaObj = window.matchMedia(media);
5237
- const handler = () => {
5238
- this.matchMedia = this.mediaObj.matches;
5239
- trigger(this.$el, createEvent('mediachange', false, true, [this.mediaObj]));
5240
- };
5241
- this.offMediaObj = on(this.mediaObj, 'change', () => {
5242
- handler();
5243
- this.$emit('resize');
5244
- });
5245
- handler();
5246
- }
5247
- },
5248
-
5249
- disconnected() {var _this$offMediaObj;
5250
- (_this$offMediaObj = this.offMediaObj) == null ? void 0 : _this$offMediaObj.call(this);
5251
- } };
5252
-
5253
-
5254
- function toMedia(value) {
5255
- if (isString(value)) {
5256
- if (startsWith(value, '@')) {
5257
- const name = "breakpoint-" + value.substr(1);
5258
- value = toFloat(getCssVar(name));
5259
- } else if (isNaN(value)) {
5260
- return value;
5261
- }
5262
- }
5263
-
5264
- return value && isNumeric(value) ? "(min-width: " + value + "px)" : '';
5265
- }
5266
-
5267
- var leader = {
5268
- mixins: [Class, Media, Resize],
5269
-
5270
- props: {
5271
- fill: String },
5272
-
5273
-
5274
- data: {
5275
- fill: '',
5276
- clsWrapper: 'uk-leader-fill',
5277
- clsHide: 'uk-leader-hide',
5278
- attrFill: 'data-fill' },
5279
-
5280
-
5281
- computed: {
5282
- fill(_ref) {let { fill } = _ref;
5283
- return fill || getCssVar('leader-fill-content');
5284
- } },
5285
-
5286
-
5287
- connected() {
5288
- [this.wrapper] = wrapInner(this.$el, "<span class=\"" + this.clsWrapper + "\">");
5289
- },
5290
-
5291
- disconnected() {
5292
- unwrap(this.wrapper.childNodes);
5293
- },
5294
-
5295
- update: {
5296
- read() {
5297
- const width = Math.trunc(this.$el.offsetWidth / 2);
5298
-
5299
- return {
5300
- width,
5301
- fill: this.fill,
5302
- hide: !this.matchMedia };
5303
-
5304
- },
5305
-
5306
- write(_ref2) {let { width, fill, hide } = _ref2;
5307
- toggleClass(this.wrapper, this.clsHide, hide);
5308
- attr(this.wrapper, this.attrFill, new Array(width).join(fill));
5309
- },
5310
-
5311
- events: ['resize'] } };
5312
-
5313
- const active = [];
5314
-
5315
- var Modal = {
5316
- mixins: [Class, Container, Togglable],
5317
-
5318
- props: {
5319
- selPanel: String,
5320
- selClose: String,
5321
- escClose: Boolean,
5322
- bgClose: Boolean,
5323
- stack: Boolean },
5324
-
5325
-
5326
- data: {
5327
- cls: 'uk-open',
5328
- escClose: true,
5329
- bgClose: true,
5330
- overlay: true,
5331
- stack: false },
5332
-
5333
-
5334
- computed: {
5335
- panel(_ref, $el) {let { selPanel } = _ref;
5336
- return $(selPanel, $el);
5337
- },
5338
-
5339
- transitionElement() {
5340
- return this.panel;
5341
- },
5342
-
5343
- bgClose(_ref2) {let { bgClose } = _ref2;
5344
- return bgClose && this.panel;
5345
- } },
5346
-
5347
-
5348
- beforeDisconnect() {
5349
- if (includes(active, this)) {
5350
- this.toggleElement(this.$el, false, false);
5351
- }
5352
- },
5353
-
5354
- events: [
5355
- {
5356
- name: 'click',
5357
-
5358
- delegate() {
5359
- return this.selClose;
5360
- },
5361
-
5362
- handler(e) {
5363
- e.preventDefault();
5364
- this.hide();
5365
- } },
5366
-
5367
-
5368
- {
5369
- name: 'toggle',
5370
-
5371
- self: true,
5372
-
5373
- handler(e) {
5374
- if (e.defaultPrevented) {
5375
- return;
5376
- }
5377
-
5378
- e.preventDefault();
5379
-
5380
- if (this.isToggled() === includes(active, this)) {
5381
- this.toggle();
5382
- }
5383
- } },
5384
-
5385
-
5386
- {
5387
- name: 'beforeshow',
5388
-
5389
- self: true,
5390
-
5391
- handler(e) {
5392
- if (includes(active, this)) {
5393
- return false;
5394
- }
5395
-
5396
- if (!this.stack && active.length) {
5397
- Promise.all(active.map((modal) => modal.hide())).then(this.show);
5398
- e.preventDefault();
5399
- } else {
5400
- active.push(this);
5401
- }
5402
- } },
5403
-
5404
-
5405
- {
5406
- name: 'show',
5407
-
5408
- self: true,
5409
-
5410
- handler() {
5411
- const docEl = document.documentElement;
5412
-
5413
- if (width(window) > docEl.clientWidth && this.overlay) {
5414
- css(document.body, 'overflowY', 'scroll');
5415
- }
5416
-
5417
- if (this.stack) {
5418
- css(this.$el, 'zIndex', toFloat(css(this.$el, 'zIndex')) + active.length);
5419
- }
5507
+ if (value) {
5508
+ attr(targetEl, prop.replace(/^(data-)+/, ''), value);
5509
+ }
5510
+ });
5511
+ }
5420
5512
 
5421
- addClass(docEl, this.clsPage);
5513
+ function getImageFromElement(el, src, sources) {
5514
+ const img = new Image();
5422
5515
 
5423
- if (this.bgClose) {
5424
- once(
5425
- this.$el,
5426
- 'hide',
5427
- on(document, pointerDown, (_ref3) => {let { target } = _ref3;
5428
- if (
5429
- last(active) !== this ||
5430
- this.overlay && !within(target, this.$el) ||
5431
- within(target, this.panel))
5432
- {
5433
- return;
5434
- }
5516
+ wrapInPicture(img, sources);
5517
+ setSourceProps(el, img);
5518
+ img.onload = () => {
5519
+ setSrcAttrs(el, img.currentSrc);
5520
+ };
5521
+ attr(img, 'src', src);
5522
+ return img;
5523
+ }
5435
5524
 
5436
- once(
5437
- document,
5438
- pointerUp + " " + pointerCancel + " scroll",
5439
- (_ref4) => {let { defaultPrevented, type, target: newTarget } = _ref4;
5440
- if (
5441
- !defaultPrevented &&
5442
- type === pointerUp &&
5443
- target === newTarget)
5444
- {
5445
- this.hide();
5446
- }
5447
- },
5448
- true);
5525
+ function wrapInPicture(img, sources) {
5526
+ sources = parseSources(sources);
5449
5527
 
5450
- }),
5451
- { self: true });
5528
+ if (sources.length) {
5529
+ const picture = fragment('<picture>');
5530
+ for (const attrs of sources) {
5531
+ const source = fragment('<source>');
5532
+ attr(source, attrs);
5533
+ append(picture, source);
5534
+ }
5535
+ append(picture, img);
5536
+ }
5537
+ }
5452
5538
 
5453
- }
5539
+ function parseSources(sources) {
5540
+ if (!sources) {
5541
+ return [];
5542
+ }
5454
5543
 
5455
- if (this.escClose) {
5456
- once(
5457
- this.$el,
5458
- 'hide',
5459
- on(document, 'keydown', (e) => {
5460
- if (e.keyCode === 27 && last(active) === this) {
5461
- this.hide();
5462
- }
5463
- }),
5464
- { self: true });
5544
+ if (startsWith(sources, '[')) {
5545
+ try {
5546
+ sources = JSON.parse(sources);
5547
+ } catch (e) {
5548
+ sources = [];
5549
+ }
5550
+ } else {
5551
+ sources = parseOptions(sources);
5552
+ }
5465
5553
 
5466
- }
5467
- } },
5554
+ if (!isArray(sources)) {
5555
+ sources = [sources];
5556
+ }
5468
5557
 
5558
+ return sources.filter((source) => !isEmpty(source));
5559
+ }
5469
5560
 
5470
- {
5471
- name: 'shown',
5561
+ function ensureSrcAttribute(el) {
5562
+ if (isImg(el) && !hasAttr(el, 'src')) {
5563
+ attr(el, 'src', 'data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg"></svg>');
5564
+ }
5565
+ }
5472
5566
 
5473
- self: true,
5567
+ function isPicture(el) {
5568
+ return isTag(el, 'picture');
5569
+ }
5474
5570
 
5475
- handler() {
5476
- if (!isFocusable(this.$el)) {
5477
- attr(this.$el, 'tabindex', '-1');
5478
- }
5571
+ function isImg(el) {
5572
+ return isTag(el, 'img');
5573
+ }
5479
5574
 
5480
- if (!$(':focus', this.$el)) {
5481
- this.$el.focus();
5482
- }
5483
- } },
5575
+ var Media = {
5576
+ props: {
5577
+ media: Boolean },
5484
5578
 
5485
5579
 
5486
- {
5487
- name: 'hidden',
5580
+ data: {
5581
+ media: false },
5488
5582
 
5489
- self: true,
5490
5583
 
5491
- handler() {
5492
- if (includes(active, this)) {
5493
- active.splice(active.indexOf(this), 1);
5494
- }
5584
+ connected() {
5585
+ const media = toMedia(this.media);
5586
+ this.matchMedia = true;
5587
+ if (media) {
5588
+ this.mediaObj = window.matchMedia(media);
5589
+ const handler = () => {
5590
+ this.matchMedia = this.mediaObj.matches;
5591
+ trigger(this.$el, createEvent('mediachange', false, true, [this.mediaObj]));
5592
+ };
5593
+ this.offMediaObj = on(this.mediaObj, 'change', () => {
5594
+ handler();
5595
+ this.$emit('resize');
5596
+ });
5597
+ handler();
5598
+ }
5599
+ },
5495
5600
 
5496
- if (!active.length) {
5497
- css(document.body, 'overflowY', '');
5498
- }
5601
+ disconnected() {var _this$offMediaObj;
5602
+ (_this$offMediaObj = this.offMediaObj) == null ? void 0 : _this$offMediaObj.call(this);
5603
+ } };
5499
5604
 
5500
- css(this.$el, 'zIndex', '');
5501
5605
 
5502
- if (!active.some((modal) => modal.clsPage === this.clsPage)) {
5503
- removeClass(document.documentElement, this.clsPage);
5504
- }
5505
- } }],
5606
+ function toMedia(value) {
5607
+ if (isString(value)) {
5608
+ if (startsWith(value, '@')) {
5609
+ const name = "breakpoint-" + value.substr(1);
5610
+ value = toFloat(getCssVar(name));
5611
+ } else if (isNaN(value)) {
5612
+ return value;
5613
+ }
5614
+ }
5506
5615
 
5616
+ return value && isNumeric(value) ? "(min-width: " + value + "px)" : '';
5617
+ }
5507
5618
 
5619
+ var leader = {
5620
+ mixins: [Class, Media, Resize],
5508
5621
 
5509
- methods: {
5510
- toggle() {
5511
- return this.isToggled() ? this.hide() : this.show();
5512
- },
5622
+ props: {
5623
+ fill: String },
5513
5624
 
5514
- show() {
5515
- if (this.container && parent(this.$el) !== this.container) {
5516
- append(this.container, this.$el);
5517
- return new Promise((resolve) =>
5518
- requestAnimationFrame(() => this.show().then(resolve)));
5519
5625
 
5520
- }
5626
+ data: {
5627
+ fill: '',
5628
+ clsWrapper: 'uk-leader-fill',
5629
+ clsHide: 'uk-leader-hide',
5630
+ attrFill: 'data-fill' },
5521
5631
 
5522
- return this.toggleElement(this.$el, true, animate(this));
5523
- },
5524
5632
 
5525
- hide() {
5526
- return this.toggleElement(this.$el, false, animate(this));
5527
- } } };
5633
+ computed: {
5634
+ fill(_ref) {let { fill } = _ref;
5635
+ return fill || getCssVar('leader-fill-content');
5636
+ } },
5528
5637
 
5529
5638
 
5639
+ connected() {
5640
+ [this.wrapper] = wrapInner(this.$el, "<span class=\"" + this.clsWrapper + "\">");
5641
+ },
5530
5642
 
5531
- function animate(_ref5) {let { transitionElement, _toggle } = _ref5;
5532
- return (el, show) =>
5533
- new Promise((resolve, reject) =>
5534
- once(el, 'show hide', () => {
5535
- el._reject == null ? void 0 : el._reject();
5536
- el._reject = reject;
5643
+ disconnected() {
5644
+ unwrap(this.wrapper.childNodes);
5645
+ },
5537
5646
 
5538
- _toggle(el, show);
5647
+ update: {
5648
+ read() {
5649
+ const width = Math.trunc(this.$el.offsetWidth / 2);
5539
5650
 
5540
- const off = once(
5541
- transitionElement,
5542
- 'transitionstart',
5543
- () => {
5544
- once(transitionElement, 'transitionend transitioncancel', resolve, {
5545
- self: true });
5651
+ return {
5652
+ width,
5653
+ fill: this.fill,
5654
+ hide: !this.matchMedia };
5546
5655
 
5547
- clearTimeout(timer);
5548
5656
  },
5549
- { self: true });
5550
-
5551
5657
 
5552
- const timer = setTimeout(() => {
5553
- off();
5554
- resolve();
5555
- }, toMs(css(transitionElement, 'transitionDuration')));
5556
- })).
5557
- then(() => delete el._reject);
5558
- }
5658
+ write(_ref2) {let { width, fill, hide } = _ref2;
5659
+ toggleClass(this.wrapper, this.clsHide, hide);
5660
+ attr(this.wrapper, this.attrFill, new Array(width).join(fill));
5661
+ },
5559
5662
 
5560
- function toMs(time) {
5561
- return time ? endsWith(time, 'ms') ? toFloat(time) : toFloat(time) * 1000 : 0;
5562
- }
5663
+ events: ['resize'] } };
5563
5664
 
5564
5665
  var modal = {
5565
5666
  install,
@@ -6065,7 +6166,7 @@
6065
6166
 
6066
6167
  methods: {
6067
6168
  getActive() {
6068
- return active$1 && within(active$1.target, this.$el) && active$1;
6169
+ return active && within(active.target, this.$el) && active;
6069
6170
  },
6070
6171
 
6071
6172
  transitionTo(newHeight, el) {
@@ -6275,22 +6376,6 @@
6275
6376
  } },
6276
6377
 
6277
6378
 
6278
- {
6279
- name: 'touchstart',
6280
-
6281
- passive: true,
6282
-
6283
- el() {
6284
- return this.panel;
6285
- },
6286
-
6287
- handler(_ref8) {let { targetTouches } = _ref8;
6288
- if (targetTouches.length === 1) {
6289
- this.clientY = targetTouches[0].clientY;
6290
- }
6291
- } },
6292
-
6293
-
6294
6379
  {
6295
6380
  name: 'touchmove',
6296
6381
 
@@ -6306,33 +6391,6 @@
6306
6391
  } },
6307
6392
 
6308
6393
 
6309
- {
6310
- name: 'touchmove',
6311
-
6312
- passive: false,
6313
-
6314
- el() {
6315
- return this.panel;
6316
- },
6317
-
6318
- handler(e) {
6319
- if (e.targetTouches.length !== 1) {
6320
- return;
6321
- }
6322
-
6323
- const clientY = e.targetTouches[0].clientY - this.clientY;
6324
- const { scrollTop, scrollHeight, clientHeight } = this.panel;
6325
-
6326
- if (
6327
- clientHeight >= scrollHeight ||
6328
- scrollTop === 0 && clientY > 0 ||
6329
- scrollHeight - scrollTop <= clientHeight && clientY < 0)
6330
- {
6331
- e.cancelable && e.preventDefault();
6332
- }
6333
- } },
6334
-
6335
-
6336
6394
  {
6337
6395
  name: 'show',
6338
6396
 
@@ -6344,7 +6402,6 @@
6344
6402
  addClass(parent(this.panel), this.clsMode);
6345
6403
  }
6346
6404
 
6347
- css(document.documentElement, 'overflowY', this.overlay ? 'hidden' : '');
6348
6405
  addClass(document.body, this.clsContainer, this.clsFlip);
6349
6406
  css(document.body, 'touch-action', 'pan-y pinch-zoom');
6350
6407
  css(this.$el, 'display', 'block');
@@ -6352,7 +6409,7 @@
6352
6409
  addClass(
6353
6410
  this.panel,
6354
6411
  this.clsSidebarAnimation,
6355
- this.mode !== 'reveal' ? this.clsMode : '');
6412
+ this.mode === 'reveal' ? '' : this.clsMode);
6356
6413
 
6357
6414
 
6358
6415
  height(document.body); // force reflow
@@ -6389,8 +6446,6 @@
6389
6446
  removeClass(this.$el, this.clsOverlay);
6390
6447
  css(this.$el, 'display', '');
6391
6448
  removeClass(document.body, this.clsContainer, this.clsFlip);
6392
-
6393
- css(document.documentElement, 'overflowY', '');
6394
6449
  } },
6395
6450
 
6396
6451