uikit 3.14.4-dev.871ba3c05 → 3.14.4-dev.ae765cd84
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/CHANGELOG.md +45 -11
- package/build/util.js +1 -0
- package/dist/css/uikit-core-rtl.css +385 -110
- package/dist/css/uikit-core-rtl.min.css +1 -1
- package/dist/css/uikit-core.css +385 -110
- package/dist/css/uikit-core.min.css +1 -1
- package/dist/css/uikit-rtl.css +402 -115
- package/dist/css/uikit-rtl.min.css +1 -1
- package/dist/css/uikit.css +402 -115
- package/dist/css/uikit.min.css +1 -1
- package/dist/js/components/countdown.js +1 -1
- package/dist/js/components/countdown.min.js +1 -1
- package/dist/js/components/filter.js +7 -5
- package/dist/js/components/filter.min.js +1 -1
- package/dist/js/components/lightbox-panel.js +185 -137
- package/dist/js/components/lightbox-panel.min.js +1 -1
- package/dist/js/components/lightbox.js +185 -137
- package/dist/js/components/lightbox.min.js +1 -1
- package/dist/js/components/notification.js +1 -1
- package/dist/js/components/notification.min.js +1 -1
- package/dist/js/components/parallax.js +4 -5
- package/dist/js/components/parallax.min.js +1 -1
- package/dist/js/components/slider-parallax.js +4 -5
- package/dist/js/components/slider-parallax.min.js +1 -1
- package/dist/js/components/slider.js +22 -7
- package/dist/js/components/slider.min.js +1 -1
- package/dist/js/components/slideshow-parallax.js +4 -5
- package/dist/js/components/slideshow-parallax.min.js +1 -1
- package/dist/js/components/slideshow.js +22 -7
- package/dist/js/components/slideshow.min.js +1 -1
- package/dist/js/components/sortable.js +3 -3
- package/dist/js/components/sortable.min.js +1 -1
- package/dist/js/components/tooltip.js +97 -135
- package/dist/js/components/tooltip.min.js +1 -1
- package/dist/js/components/upload.js +1 -1
- package/dist/js/components/upload.min.js +1 -1
- package/dist/js/uikit-core.js +1803 -1709
- package/dist/js/uikit-core.min.js +14 -1
- package/dist/js/uikit-icons.js +1 -1
- package/dist/js/uikit-icons.min.js +1 -1
- package/dist/js/uikit.js +1051 -940
- package/dist/js/uikit.min.js +14 -1
- package/package.json +1 -1
- package/src/images/{backgrounds/nav-parent-open.svg → components/nav-parent-icon-large.svg} +0 -0
- package/src/images/components/nav-parent-icon.svg +3 -0
- package/src/images/components/navbar-parent-icon.svg +3 -0
- package/src/images/components/navbar-toggle-icon.svg +22 -3
- package/src/js/api/state.js +2 -2
- package/src/js/components/filter.js +5 -3
- package/src/js/components/sortable.js +2 -3
- package/src/js/core/accordion.js +9 -17
- package/src/js/core/alert.js +35 -14
- package/src/js/core/drop.js +95 -61
- package/src/js/core/height-viewport.js +14 -6
- package/src/js/core/icon.js +16 -0
- package/src/js/core/index.js +2 -0
- package/src/js/core/leader.js +2 -2
- package/src/js/core/navbar.js +44 -30
- package/src/js/core/offcanvas.js +1 -47
- package/src/js/core/scroll.js +37 -10
- package/src/js/core/sticky.js +8 -9
- package/src/js/core/toggle.js +3 -5
- package/src/js/mixin/media.js +4 -5
- package/src/js/mixin/modal.js +97 -8
- package/src/js/mixin/position.js +26 -11
- package/src/js/mixin/slider-drag.js +20 -8
- package/src/js/mixin/style.js +11 -0
- package/src/js/mixin/togglable.js +80 -133
- package/src/js/util/animation.js +4 -3
- package/src/js/util/dimensions.js +6 -6
- package/src/js/util/filter.js +3 -7
- package/src/js/util/position.js +108 -107
- package/src/js/util/style.js +4 -13
- package/src/js/util/viewport.js +5 -32
- package/src/less/components/_import.less +1 -0
- package/src/less/components/drop.less +1 -18
- package/src/less/components/dropbar.less +115 -0
- package/src/less/components/dropdown.less +16 -16
- package/src/less/components/leader.less +1 -1
- package/src/less/components/nav.less +240 -63
- package/src/less/components/navbar.less +81 -38
- package/src/less/components/utility.less +21 -4
- package/src/less/theme/_import.less +1 -0
- package/src/less/theme/dropbar.less +44 -0
- package/src/less/theme/dropdown.less +0 -11
- package/src/less/theme/nav.less +43 -9
- package/src/less/theme/navbar.less +7 -11
- package/src/scss/components/_import.scss +1 -0
- package/src/scss/components/drop.scss +1 -18
- package/src/scss/components/dropbar.scss +115 -0
- package/src/scss/components/dropdown.scss +16 -16
- package/src/scss/components/leader.scss +1 -1
- package/src/scss/components/nav.scss +189 -51
- package/src/scss/components/navbar.scss +69 -38
- package/src/scss/components/utility.scss +19 -3
- package/src/scss/mixins-theme.scss +93 -25
- package/src/scss/mixins.scss +89 -17
- package/src/scss/theme/_import.scss +1 -0
- package/src/scss/theme/dropbar.scss +44 -0
- package/src/scss/theme/dropdown.scss +0 -8
- package/src/scss/theme/nav.scss +41 -9
- package/src/scss/theme/navbar.scss +7 -8
- package/src/scss/variables-theme.scss +71 -18
- package/src/scss/variables.scss +60 -14
- package/tests/accordion.html +2 -2
- package/tests/alert.html +2 -2
- package/tests/countdown.html +1 -1
- package/tests/drop.html +457 -371
- package/tests/dropbar.html +456 -0
- package/tests/dropdown.html +26 -401
- package/tests/filter.html +9 -12
- package/tests/form.html +1 -1
- package/tests/index.html +126 -107
- package/tests/js/index.js +1 -4
- package/tests/lightbox.html +5 -5
- package/tests/list.html +8 -8
- package/tests/modal.html +13 -13
- package/tests/nav.html +117 -75
- package/tests/navbar.html +2002 -1131
- package/tests/offcanvas.html +17 -21
- package/tests/parallax.html +1 -1
- package/tests/position.html +18 -16
- package/tests/progress.html +9 -9
- package/tests/scroll.html +7 -10
- package/tests/search.html +5 -5
- package/tests/slider.html +6 -5
- package/tests/slideshow.html +8 -8
- package/tests/sortable.html +6 -8
- package/tests/sticky-navbar.html +6 -6
- package/tests/sticky.html +8 -8
- package/tests/switcher.html +1 -1
- package/tests/tab.html +1 -1
- package/tests/table.html +7 -7
- package/tests/toggle.html +2 -2
- package/tests/tooltip.html +1 -1
- package/tests/upload.html +11 -11
- package/tests/utility.html +19 -0
- package/src/images/backgrounds/nav-parent-close.svg +0 -3
package/dist/js/uikit.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.14.4-dev.
|
|
1
|
+
/*! UIkit 3.14.4-dev.ae765cd84 | 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() :
|
|
@@ -383,12 +383,8 @@
|
|
|
383
383
|
}
|
|
384
384
|
|
|
385
385
|
function closest(element, selector) {
|
|
386
|
-
if (startsWith(selector, '>')) {
|
|
387
|
-
selector = selector.slice(1);
|
|
388
|
-
}
|
|
389
|
-
|
|
390
386
|
return isElement(element) ?
|
|
391
|
-
element.closest(selector) :
|
|
387
|
+
element.closest(startsWith(selector, '>') ? selector.slice(1) : selector) :
|
|
392
388
|
toNodes(element).
|
|
393
389
|
map((element) => closest(element, selector)).
|
|
394
390
|
filter(Boolean);
|
|
@@ -396,8 +392,8 @@
|
|
|
396
392
|
|
|
397
393
|
function within(element, selector) {
|
|
398
394
|
return isString(selector) ?
|
|
399
|
-
|
|
400
|
-
|
|
395
|
+
!!closest(element, selector) :
|
|
396
|
+
toNode(selector).contains(toNode(element));
|
|
401
397
|
}
|
|
402
398
|
|
|
403
399
|
function parents(element, selector) {
|
|
@@ -785,18 +781,11 @@
|
|
|
785
781
|
return elements[0];
|
|
786
782
|
}
|
|
787
783
|
|
|
788
|
-
const propertyRe = /^\s*(["'])?(.*?)\1\s*$/;
|
|
789
|
-
function getCssVar(name, element) {if (element === void 0) {element = document.documentElement;}
|
|
790
|
-
return css(element, "--uk-" + name).replace(propertyRe, '$2');
|
|
791
|
-
}
|
|
792
|
-
|
|
793
784
|
// https://drafts.csswg.org/cssom/#dom-cssstyledeclaration-setproperty
|
|
794
785
|
const propName = memoize((name) => vendorPropName(name));
|
|
795
786
|
|
|
796
|
-
const cssPrefixes = ['webkit', 'moz'];
|
|
797
|
-
|
|
798
787
|
function vendorPropName(name) {
|
|
799
|
-
if (name
|
|
788
|
+
if (startsWith(name, '--')) {
|
|
800
789
|
return name;
|
|
801
790
|
}
|
|
802
791
|
|
|
@@ -808,11 +797,8 @@
|
|
|
808
797
|
return name;
|
|
809
798
|
}
|
|
810
799
|
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
while (i--) {
|
|
815
|
-
prefixedName = "-" + cssPrefixes[i] + "-" + name;
|
|
800
|
+
for (const prefix of ['webkit', 'moz']) {
|
|
801
|
+
const prefixedName = "-" + prefix + "-" + name;
|
|
816
802
|
if (prefixedName in style) {
|
|
817
803
|
return prefixedName;
|
|
818
804
|
}
|
|
@@ -913,13 +899,14 @@
|
|
|
913
899
|
const Transition = {
|
|
914
900
|
start: transition,
|
|
915
901
|
|
|
916
|
-
stop(element) {
|
|
902
|
+
async stop(element) {
|
|
917
903
|
trigger(element, 'transitionend');
|
|
918
|
-
|
|
904
|
+
await Promise.resolve();
|
|
919
905
|
},
|
|
920
906
|
|
|
921
|
-
cancel(element) {
|
|
907
|
+
async cancel(element) {
|
|
922
908
|
trigger(element, 'transitioncanceled');
|
|
909
|
+
await Promise.resolve();
|
|
923
910
|
},
|
|
924
911
|
|
|
925
912
|
inProgress(element) {
|
|
@@ -929,7 +916,7 @@
|
|
|
929
916
|
|
|
930
917
|
const animationPrefix = 'uk-animation-';
|
|
931
918
|
|
|
932
|
-
function animate$
|
|
919
|
+
function animate$2(element, animation, duration, origin, out) {if (duration === void 0) {duration = 200;}
|
|
933
920
|
return Promise.all(
|
|
934
921
|
toNodes(element).map(
|
|
935
922
|
(element) =>
|
|
@@ -965,10 +952,10 @@
|
|
|
965
952
|
|
|
966
953
|
const inProgress = new RegExp(animationPrefix + "(enter|leave)");
|
|
967
954
|
const Animation = {
|
|
968
|
-
in: animate$
|
|
955
|
+
in: animate$2,
|
|
969
956
|
|
|
970
957
|
out(element, animation, duration, origin) {
|
|
971
|
-
return animate$
|
|
958
|
+
return animate$2(element, animation, duration, origin, true);
|
|
972
959
|
},
|
|
973
960
|
|
|
974
961
|
inProgress(element) {
|
|
@@ -1060,13 +1047,13 @@
|
|
|
1060
1047
|
}
|
|
1061
1048
|
|
|
1062
1049
|
function offsetPosition(element) {
|
|
1063
|
-
const offset = [0, 0];
|
|
1064
|
-
|
|
1065
1050
|
element = toNode(element);
|
|
1066
1051
|
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1052
|
+
const offset = [element.offsetTop, element.offsetLeft];
|
|
1053
|
+
|
|
1054
|
+
while (element = element.offsetParent) {
|
|
1055
|
+
offset[0] += element.offsetTop + toFloat(css(element, "borderTopWidth"));
|
|
1056
|
+
offset[1] += element.offsetLeft + toFloat(css(element, "borderLeftWidth"));
|
|
1070
1057
|
|
|
1071
1058
|
if (css(element, 'position') === 'fixed') {
|
|
1072
1059
|
const win = toWindow(element);
|
|
@@ -1074,7 +1061,7 @@
|
|
|
1074
1061
|
offset[1] += win.scrollX;
|
|
1075
1062
|
return offset;
|
|
1076
1063
|
}
|
|
1077
|
-
}
|
|
1064
|
+
}
|
|
1078
1065
|
|
|
1079
1066
|
return offset;
|
|
1080
1067
|
}
|
|
@@ -1293,9 +1280,9 @@
|
|
|
1293
1280
|
const hasTouch = inBrowser && 'ontouchstart' in window;
|
|
1294
1281
|
const hasPointerEvents = inBrowser && window.PointerEvent;
|
|
1295
1282
|
|
|
1296
|
-
const pointerDown = hasPointerEvents ? 'pointerdown' : hasTouch ? 'touchstart' : 'mousedown';
|
|
1297
|
-
const pointerMove = hasPointerEvents ? 'pointermove' : hasTouch ? 'touchmove' : 'mousemove';
|
|
1298
|
-
const pointerUp = hasPointerEvents ? 'pointerup' : hasTouch ? 'touchend' : 'mouseup';
|
|
1283
|
+
const pointerDown$1 = hasPointerEvents ? 'pointerdown' : hasTouch ? 'touchstart' : 'mousedown';
|
|
1284
|
+
const pointerMove$1 = hasPointerEvents ? 'pointermove' : hasTouch ? 'touchmove' : 'mousemove';
|
|
1285
|
+
const pointerUp$1 = hasPointerEvents ? 'pointerup' : hasTouch ? 'touchend' : 'mouseup';
|
|
1299
1286
|
const pointerEnter = hasPointerEvents ? 'pointerenter' : hasTouch ? '' : 'mouseenter';
|
|
1300
1287
|
const pointerLeave = hasPointerEvents ? 'pointerleave' : hasTouch ? '' : 'mouseleave';
|
|
1301
1288
|
const pointerCancel = hasPointerEvents ? 'pointercancel' : 'touchcancel';
|
|
@@ -1795,20 +1782,6 @@
|
|
|
1795
1782
|
|
|
1796
1783
|
}
|
|
1797
1784
|
|
|
1798
|
-
function scrollTop(element, top) {
|
|
1799
|
-
if (isWindow(element) || isDocument(element)) {
|
|
1800
|
-
element = scrollingElement(element);
|
|
1801
|
-
} else {
|
|
1802
|
-
element = toNode(element);
|
|
1803
|
-
}
|
|
1804
|
-
|
|
1805
|
-
if (isUndefined(top)) {
|
|
1806
|
-
return element.scrollTop;
|
|
1807
|
-
} else {
|
|
1808
|
-
element.scrollTop = top;
|
|
1809
|
-
}
|
|
1810
|
-
}
|
|
1811
|
-
|
|
1812
1785
|
function scrollIntoView(element, _temp) {let { offset: offsetBy = 0 } = _temp === void 0 ? {} : _temp;
|
|
1813
1786
|
const parents = isVisible(element) ? scrollParents(element) : [];
|
|
1814
1787
|
return parents.reduce(
|
|
@@ -1850,7 +1823,7 @@
|
|
|
1850
1823
|
(function step() {
|
|
1851
1824
|
const percent = ease(clamp((Date.now() - start) / duration));
|
|
1852
1825
|
|
|
1853
|
-
scrollTop
|
|
1826
|
+
element.scrollTop = scroll + top * percent;
|
|
1854
1827
|
|
|
1855
1828
|
// scroll more if we have not reached our destination
|
|
1856
1829
|
if (percent === 1) {
|
|
@@ -1913,12 +1886,10 @@
|
|
|
1913
1886
|
function offsetViewport(scrollElement) {
|
|
1914
1887
|
const window = toWindow(scrollElement);
|
|
1915
1888
|
const {
|
|
1916
|
-
document: {
|
|
1889
|
+
document: { documentElement } } =
|
|
1917
1890
|
window;
|
|
1918
1891
|
let viewportElement =
|
|
1919
|
-
scrollElement === scrollingElement(scrollElement)
|
|
1920
|
-
window :
|
|
1921
|
-
scrollElement;
|
|
1892
|
+
scrollElement === scrollingElement(scrollElement) ? window : scrollElement;
|
|
1922
1893
|
|
|
1923
1894
|
const { visualViewport } = window;
|
|
1924
1895
|
if (isWindow(viewportElement) && visualViewport) {
|
|
@@ -1937,7 +1908,7 @@
|
|
|
1937
1908
|
// iOS 12 returns <body> as scrollingElement
|
|
1938
1909
|
viewportElement = documentElement;
|
|
1939
1910
|
} else {
|
|
1940
|
-
rect[start] += toFloat(css(viewportElement, "border" +
|
|
1911
|
+
rect[start] += toFloat(css(viewportElement, "border-" + start + "-width"));
|
|
1941
1912
|
}
|
|
1942
1913
|
rect[prop] = rect[dir] = viewportElement["client" + ucfirst(prop)];
|
|
1943
1914
|
rect[end] = rect[prop] + rect[start];
|
|
@@ -1962,126 +1933,65 @@
|
|
|
1962
1933
|
...options.attach },
|
|
1963
1934
|
|
|
1964
1935
|
offset: [0, 0],
|
|
1936
|
+
placement: [],
|
|
1965
1937
|
...options };
|
|
1966
1938
|
|
|
1967
1939
|
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
attachTo(element, target, options);
|
|
1971
|
-
|
|
1972
|
-
offset(element, dim);
|
|
1973
|
-
}
|
|
1974
|
-
|
|
1975
|
-
function attachTo(element, target, options) {
|
|
1976
|
-
let { attach, offset: offsetBy } = {
|
|
1977
|
-
attach: {
|
|
1978
|
-
element: ['left', 'top'],
|
|
1979
|
-
target: ['left', 'top'],
|
|
1980
|
-
...options.attach },
|
|
1981
|
-
|
|
1982
|
-
offset: [0, 0],
|
|
1983
|
-
...options };
|
|
1984
|
-
|
|
1985
|
-
|
|
1986
|
-
const position = offset(element);
|
|
1987
|
-
const targetOffset = offset(target);
|
|
1988
|
-
for (const [i, [prop, dir, start, end]] of Object.entries(dirs)) {
|
|
1989
|
-
position[start] = position[dir] =
|
|
1990
|
-
targetOffset[start] +
|
|
1991
|
-
moveBy(attach.target[i], end, targetOffset[prop]) -
|
|
1992
|
-
moveBy(attach.element[i], end, position[prop]) +
|
|
1993
|
-
+offsetBy[i];
|
|
1994
|
-
position[end] = position[start] + position[prop];
|
|
1940
|
+
if (!isArray(target)) {
|
|
1941
|
+
target = [target, target];
|
|
1995
1942
|
}
|
|
1996
|
-
return position;
|
|
1997
|
-
}
|
|
1998
1943
|
|
|
1999
|
-
|
|
2000
|
-
return start === 'center' ? dim / 2 : start === end ? dim : 0;
|
|
1944
|
+
offset(element, getPosition(element, target, options));
|
|
2001
1945
|
}
|
|
2002
1946
|
|
|
2003
|
-
function
|
|
1947
|
+
function getPosition(element, target, options) {
|
|
2004
1948
|
const position = attachTo(element, target, options);
|
|
2005
|
-
const targetDim = offset(target);
|
|
2006
1949
|
|
|
2007
1950
|
let {
|
|
2008
|
-
flip,
|
|
2009
1951
|
attach: { element: elAttach, target: targetAttach },
|
|
2010
1952
|
offset: elOffset,
|
|
2011
1953
|
boundary,
|
|
2012
|
-
|
|
2013
|
-
|
|
1954
|
+
viewportOffset,
|
|
1955
|
+
placement } =
|
|
2014
1956
|
options;
|
|
2015
1957
|
|
|
2016
|
-
let
|
|
2017
|
-
|
|
2018
|
-
viewports =
|
|
2019
|
-
|
|
2020
|
-
const [scrollElement] = viewports;
|
|
2021
|
-
viewports.push(viewport);
|
|
2022
|
-
|
|
2023
|
-
const offsetPosition = { ...position };
|
|
2024
|
-
for (const [i, [prop, dir, start, end]] of Object.entries(dirs)) {
|
|
2025
|
-
if (flip !== true && !includes(flip, dir)) {
|
|
2026
|
-
continue;
|
|
2027
|
-
}
|
|
1958
|
+
let offsetPosition = position;
|
|
1959
|
+
for (const [i, [prop,, start, end]] of Object.entries(dirs)) {
|
|
1960
|
+
let viewports = scrollParents(target[i]);
|
|
1961
|
+
const [scrollElement] = viewports;
|
|
2028
1962
|
|
|
2029
|
-
|
|
2030
|
-
!intersectLine(position, targetDim, i) && intersectLine(position, targetDim, 1 - i);
|
|
2031
|
-
|
|
2032
|
-
viewport = getIntersectionArea(...viewports.filter(Boolean).map(offsetViewport));
|
|
1963
|
+
let viewport = getIntersectionArea(...viewports.map(offsetViewport));
|
|
2033
1964
|
|
|
2034
1965
|
if (viewportOffset) {
|
|
2035
1966
|
viewport[start] += viewportOffset;
|
|
2036
1967
|
viewport[end] -= viewportOffset;
|
|
2037
1968
|
}
|
|
2038
1969
|
|
|
2039
|
-
if (boundary
|
|
2040
|
-
viewport = getIntersectionArea(viewport,
|
|
1970
|
+
if (boundary) {
|
|
1971
|
+
viewport = getIntersectionArea(viewport, offsetViewport(boundary));
|
|
2041
1972
|
}
|
|
2042
1973
|
|
|
2043
|
-
const
|
|
2044
|
-
const
|
|
1974
|
+
const isInStartViewport = position[start] >= viewport[start];
|
|
1975
|
+
const isInEndViewport = position[end] <= viewport[end];
|
|
2045
1976
|
|
|
2046
|
-
if (
|
|
1977
|
+
if (isInStartViewport && isInEndViewport) {
|
|
2047
1978
|
continue;
|
|
2048
1979
|
}
|
|
2049
1980
|
|
|
2050
|
-
let offsetBy;
|
|
1981
|
+
let offsetBy = 0;
|
|
2051
1982
|
|
|
2052
1983
|
// Flip
|
|
2053
|
-
if (
|
|
1984
|
+
if (placement[i] === 'flip') {
|
|
2054
1985
|
if (
|
|
2055
|
-
|
|
2056
|
-
|
|
1986
|
+
targetAttach[i] === end && isInEndViewport ||
|
|
1987
|
+
targetAttach[i] === start && isInStartViewport)
|
|
2057
1988
|
{
|
|
2058
1989
|
continue;
|
|
2059
1990
|
}
|
|
2060
1991
|
|
|
2061
|
-
offsetBy =
|
|
2062
|
-
(elAttach[i] === start ?
|
|
2063
|
-
-position[prop] :
|
|
2064
|
-
elAttach[i] === end ?
|
|
2065
|
-
position[prop] :
|
|
2066
|
-
0) + (
|
|
2067
|
-
targetAttach[i] === start ?
|
|
2068
|
-
targetDim[prop] :
|
|
2069
|
-
targetAttach[i] === end ?
|
|
2070
|
-
-targetDim[prop] :
|
|
2071
|
-
0) -
|
|
2072
|
-
elOffset[i] * 2;
|
|
2073
|
-
|
|
2074
|
-
if (
|
|
2075
|
-
!isInScrollArea(
|
|
2076
|
-
{
|
|
2077
|
-
...position,
|
|
2078
|
-
[start]: position[start] + offsetBy,
|
|
2079
|
-
[end]: position[end] + offsetBy },
|
|
2080
|
-
|
|
2081
|
-
scrollElement,
|
|
2082
|
-
i))
|
|
1992
|
+
offsetBy = flip(element, target, options, i)[start] - position[start];
|
|
2083
1993
|
|
|
2084
|
-
{
|
|
1994
|
+
if (!isInScrollArea(applyOffset(position, offsetBy, i), scrollElement, i)) {
|
|
2085
1995
|
if (isInScrollArea(position, scrollElement, i)) {
|
|
2086
1996
|
continue;
|
|
2087
1997
|
}
|
|
@@ -2090,26 +2000,27 @@
|
|
|
2090
2000
|
return false;
|
|
2091
2001
|
}
|
|
2092
2002
|
|
|
2093
|
-
|
|
2094
|
-
|
|
2095
|
-
|
|
2096
|
-
|
|
2097
|
-
|
|
2098
|
-
target: targetAttach.map(flipDir).reverse() },
|
|
2003
|
+
const newPos = getPosition(element, target, {
|
|
2004
|
+
...options,
|
|
2005
|
+
attach: {
|
|
2006
|
+
element: elAttach.map(flipAxis).reverse(),
|
|
2007
|
+
target: targetAttach.map(flipAxis).reverse() },
|
|
2099
2008
|
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
2009
|
+
offset: elOffset.reverse(),
|
|
2010
|
+
placement: placement.reverse(),
|
|
2011
|
+
recursion: true });
|
|
2103
2012
|
|
|
2104
2013
|
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
}
|
|
2014
|
+
if (newPos && isInScrollArea(newPos, scrollElement, 1 - i)) {
|
|
2015
|
+
return newPos;
|
|
2108
2016
|
}
|
|
2017
|
+
|
|
2018
|
+
continue;
|
|
2109
2019
|
}
|
|
2110
2020
|
|
|
2111
|
-
//
|
|
2112
|
-
} else {
|
|
2021
|
+
// Shift
|
|
2022
|
+
} else if (placement[i] === 'shift') {
|
|
2023
|
+
const targetDim = offset(target[i]);
|
|
2113
2024
|
offsetBy =
|
|
2114
2025
|
clamp(
|
|
2115
2026
|
clamp(position[start], viewport[start], viewport[end] - position[prop]),
|
|
@@ -2118,13 +2029,54 @@
|
|
|
2118
2029
|
position[start];
|
|
2119
2030
|
}
|
|
2120
2031
|
|
|
2121
|
-
offsetPosition
|
|
2122
|
-
offsetPosition[end] += offsetBy;
|
|
2032
|
+
offsetPosition = applyOffset(offsetPosition, offsetBy, i);
|
|
2123
2033
|
}
|
|
2124
2034
|
|
|
2125
2035
|
return offsetPosition;
|
|
2126
2036
|
}
|
|
2127
2037
|
|
|
2038
|
+
function attachTo(element, target, options) {
|
|
2039
|
+
let { attach, offset: offsetBy } = {
|
|
2040
|
+
attach: {
|
|
2041
|
+
element: ['left', 'top'],
|
|
2042
|
+
target: ['left', 'top'],
|
|
2043
|
+
...options.attach },
|
|
2044
|
+
|
|
2045
|
+
offset: [0, 0],
|
|
2046
|
+
...options };
|
|
2047
|
+
|
|
2048
|
+
|
|
2049
|
+
let elOffset = offset(element);
|
|
2050
|
+
|
|
2051
|
+
for (const [i, [prop,, start, end]] of Object.entries(dirs)) {
|
|
2052
|
+
const targetOffset =
|
|
2053
|
+
attach.target[i] === attach.element[i] ? offsetViewport(target[i]) : offset(target[i]);
|
|
2054
|
+
|
|
2055
|
+
elOffset = applyOffset(
|
|
2056
|
+
elOffset,
|
|
2057
|
+
targetOffset[start] -
|
|
2058
|
+
elOffset[start] +
|
|
2059
|
+
moveBy(attach.target[i], end, targetOffset[prop]) -
|
|
2060
|
+
moveBy(attach.element[i], end, elOffset[prop]) +
|
|
2061
|
+
+offsetBy[i],
|
|
2062
|
+
i);
|
|
2063
|
+
|
|
2064
|
+
}
|
|
2065
|
+
return elOffset;
|
|
2066
|
+
}
|
|
2067
|
+
|
|
2068
|
+
function applyOffset(position, offset, i) {
|
|
2069
|
+
const [, dir, start, end] = dirs[i];
|
|
2070
|
+
const newPos = { ...position };
|
|
2071
|
+
newPos[start] = position[dir] = position[start] + offset;
|
|
2072
|
+
newPos[end] += offset;
|
|
2073
|
+
return newPos;
|
|
2074
|
+
}
|
|
2075
|
+
|
|
2076
|
+
function moveBy(attach, end, dim) {
|
|
2077
|
+
return attach === 'center' ? dim / 2 : attach === end ? dim : 0;
|
|
2078
|
+
}
|
|
2079
|
+
|
|
2128
2080
|
function getIntersectionArea() {
|
|
2129
2081
|
let area = {};for (var _len = arguments.length, rects = new Array(_len), _key = 0; _key < _len; _key++) {rects[_key] = arguments[_key];}
|
|
2130
2082
|
for (const rect of rects) {
|
|
@@ -2145,12 +2097,32 @@
|
|
|
2145
2097
|
return position[start] >= viewport[start] && position[end] <= viewport[end];
|
|
2146
2098
|
}
|
|
2147
2099
|
|
|
2148
|
-
function
|
|
2149
|
-
|
|
2150
|
-
|
|
2100
|
+
function flip(element, target, _ref, i) {let { offset, attach } = _ref;
|
|
2101
|
+
return attachTo(element, target, {
|
|
2102
|
+
attach: {
|
|
2103
|
+
element: flipAttach(attach.element, i),
|
|
2104
|
+
target: flipAttach(attach.target, i) },
|
|
2105
|
+
|
|
2106
|
+
offset: flipOffset(offset, i) });
|
|
2107
|
+
|
|
2108
|
+
}
|
|
2109
|
+
|
|
2110
|
+
function flipAttach(attach, i) {
|
|
2111
|
+
const newAttach = [...attach];
|
|
2112
|
+
const index = dirs[i].indexOf(attach[i]);
|
|
2113
|
+
if (~index) {
|
|
2114
|
+
newAttach[i] = dirs[i][1 - index % 2 + 2];
|
|
2115
|
+
}
|
|
2116
|
+
return newAttach;
|
|
2117
|
+
}
|
|
2118
|
+
|
|
2119
|
+
function flipOffset(offset, i) {
|
|
2120
|
+
offset = [...offset];
|
|
2121
|
+
offset[i] *= -1;
|
|
2122
|
+
return offset;
|
|
2151
2123
|
}
|
|
2152
2124
|
|
|
2153
|
-
function
|
|
2125
|
+
function flipAxis(prop) {
|
|
2154
2126
|
for (let i = 0; i < dirs.length; i++) {
|
|
2155
2127
|
const index = dirs[i].indexOf(prop);
|
|
2156
2128
|
if (~index) {
|
|
@@ -2165,7 +2137,7 @@
|
|
|
2165
2137
|
getImage: getImage,
|
|
2166
2138
|
transition: transition,
|
|
2167
2139
|
Transition: Transition,
|
|
2168
|
-
animate: animate$
|
|
2140
|
+
animate: animate$2,
|
|
2169
2141
|
Animation: Animation,
|
|
2170
2142
|
attr: attr,
|
|
2171
2143
|
hasAttr: hasAttr,
|
|
@@ -2205,9 +2177,9 @@
|
|
|
2205
2177
|
inBrowser: inBrowser,
|
|
2206
2178
|
isRtl: isRtl,
|
|
2207
2179
|
hasTouch: hasTouch,
|
|
2208
|
-
pointerDown: pointerDown,
|
|
2209
|
-
pointerMove: pointerMove,
|
|
2210
|
-
pointerUp: pointerUp,
|
|
2180
|
+
pointerDown: pointerDown$1,
|
|
2181
|
+
pointerMove: pointerMove$1,
|
|
2182
|
+
pointerUp: pointerUp$1,
|
|
2211
2183
|
pointerEnter: pointerEnter,
|
|
2212
2184
|
pointerLeave: pointerLeave,
|
|
2213
2185
|
pointerCancel: pointerCancel,
|
|
@@ -2295,10 +2267,8 @@
|
|
|
2295
2267
|
findAll: findAll,
|
|
2296
2268
|
escape: escape,
|
|
2297
2269
|
css: css,
|
|
2298
|
-
getCssVar: getCssVar,
|
|
2299
2270
|
propName: propName,
|
|
2300
2271
|
isInView: isInView,
|
|
2301
|
-
scrollTop: scrollTop,
|
|
2302
2272
|
scrollIntoView: scrollIntoView,
|
|
2303
2273
|
scrolledOver: scrolledOver,
|
|
2304
2274
|
scrollParents: scrollParents,
|
|
@@ -2621,7 +2591,7 @@
|
|
|
2621
2591
|
|
|
2622
2592
|
value = props[key] === Boolean && value === '' ? true : coerce$1(props[key], value);
|
|
2623
2593
|
|
|
2624
|
-
if (prop === 'target' &&
|
|
2594
|
+
if (prop === 'target' && startsWith(value, '_')) {
|
|
2625
2595
|
continue;
|
|
2626
2596
|
}
|
|
2627
2597
|
|
|
@@ -2632,7 +2602,7 @@
|
|
|
2632
2602
|
|
|
2633
2603
|
for (const key in options) {
|
|
2634
2604
|
const prop = camelize(key);
|
|
2635
|
-
if (props[prop]
|
|
2605
|
+
if (!isUndefined(props[prop])) {
|
|
2636
2606
|
data$1[prop] = coerce$1(props[prop], options[key]);
|
|
2637
2607
|
}
|
|
2638
2608
|
}
|
|
@@ -2961,7 +2931,7 @@
|
|
|
2961
2931
|
UIkit.data = '__uikit__';
|
|
2962
2932
|
UIkit.prefix = 'uk-';
|
|
2963
2933
|
UIkit.options = {};
|
|
2964
|
-
UIkit.version = '3.14.4-dev.
|
|
2934
|
+
UIkit.version = '3.14.4-dev.ae765cd84';
|
|
2965
2935
|
|
|
2966
2936
|
globalAPI(UIkit);
|
|
2967
2937
|
hooksAPI(UIkit);
|
|
@@ -3066,27 +3036,7 @@
|
|
|
3066
3036
|
origin: false,
|
|
3067
3037
|
transition: 'ease',
|
|
3068
3038
|
clsEnter: 'uk-togglabe-enter',
|
|
3069
|
-
clsLeave: 'uk-togglabe-leave',
|
|
3070
|
-
|
|
3071
|
-
initProps: {
|
|
3072
|
-
overflow: '',
|
|
3073
|
-
maxHeight: '',
|
|
3074
|
-
paddingTop: '',
|
|
3075
|
-
paddingBottom: '',
|
|
3076
|
-
marginTop: '',
|
|
3077
|
-
marginBottom: '',
|
|
3078
|
-
boxShadow: '' },
|
|
3079
|
-
|
|
3080
|
-
|
|
3081
|
-
hideProps: {
|
|
3082
|
-
overflow: 'hidden',
|
|
3083
|
-
maxHeight: 0,
|
|
3084
|
-
paddingTop: 0,
|
|
3085
|
-
paddingBottom: 0,
|
|
3086
|
-
marginTop: 0,
|
|
3087
|
-
marginBottom: 0,
|
|
3088
|
-
boxShadow: 'none' } },
|
|
3089
|
-
|
|
3039
|
+
clsLeave: 'uk-togglabe-leave' },
|
|
3090
3040
|
|
|
3091
3041
|
|
|
3092
3042
|
computed: {
|
|
@@ -3095,7 +3045,7 @@
|
|
|
3095
3045
|
},
|
|
3096
3046
|
|
|
3097
3047
|
hasTransition(_ref2) {let { animation } = _ref2;
|
|
3098
|
-
return startsWith(animation[0],
|
|
3048
|
+
return ['slide', 'reveal'].some((transition) => startsWith(animation[0], transition));
|
|
3099
3049
|
} },
|
|
3100
3050
|
|
|
3101
3051
|
|
|
@@ -3188,130 +3138,97 @@
|
|
|
3188
3138
|
};
|
|
3189
3139
|
}
|
|
3190
3140
|
|
|
3191
|
-
function toggleTransition(cmp) {
|
|
3192
|
-
|
|
3193
|
-
case 'slide-left':
|
|
3194
|
-
return slideHorizontal(cmp);
|
|
3195
|
-
case 'slide-right':
|
|
3196
|
-
return slideHorizontal(cmp, true);}
|
|
3197
|
-
|
|
3198
|
-
return slide$1(cmp);
|
|
3199
|
-
}
|
|
3200
|
-
|
|
3201
|
-
function slide$1(_ref4)
|
|
3202
|
-
|
|
3203
|
-
|
|
3141
|
+
function toggleTransition(cmp) {var _cmp$animation$;
|
|
3142
|
+
const [mode = 'reveal', startProp = 'top'] = ((_cmp$animation$ = cmp.animation[0]) == null ? void 0 : _cmp$animation$.split('-')) || [];
|
|
3204
3143
|
|
|
3144
|
+
const dirs = [
|
|
3145
|
+
['left', 'right'],
|
|
3146
|
+
['top', 'bottom']];
|
|
3205
3147
|
|
|
3148
|
+
const dir = dirs[includes(dirs[0], startProp) ? 0 : 1];
|
|
3149
|
+
const end = dir[1] === startProp;
|
|
3150
|
+
const props = ['width', 'height'];
|
|
3151
|
+
const dimProp = props[dirs.indexOf(dir)];
|
|
3152
|
+
const marginProp = "margin-" + dir[0];
|
|
3153
|
+
const marginStartProp = "margin-" + startProp;
|
|
3206
3154
|
|
|
3155
|
+
return async (el, show) => {
|
|
3156
|
+
let { duration, velocity, transition, _toggle } = cmp;
|
|
3207
3157
|
|
|
3158
|
+
let currentDim = dimensions$1(el)[dimProp];
|
|
3208
3159
|
|
|
3209
|
-
{let { isToggled, duration, velocity, initProps, hideProps, transition, _toggle } = _ref4;
|
|
3210
|
-
return (el, show) => {
|
|
3211
3160
|
const inProgress = Transition.inProgress(el);
|
|
3212
|
-
|
|
3213
|
-
!inProgress && el.hasChildNodes() ?
|
|
3214
|
-
toFloat(css(el.firstElementChild, 'marginTop')) +
|
|
3215
|
-
toFloat(css(el.lastElementChild, 'marginBottom')) :
|
|
3216
|
-
0;
|
|
3217
|
-
const currentHeight = isVisible(el) ? toFloat(css(el, 'height')) + inner : 0;
|
|
3218
|
-
|
|
3219
|
-
const props = inProgress ? css(el, Object.keys(initProps)) : show ? hideProps : initProps;
|
|
3220
|
-
|
|
3221
|
-
Transition.cancel(el);
|
|
3161
|
+
await Transition.cancel(el);
|
|
3222
3162
|
|
|
3223
|
-
if (
|
|
3163
|
+
if (show) {
|
|
3224
3164
|
_toggle(el, true);
|
|
3225
3165
|
}
|
|
3226
3166
|
|
|
3227
|
-
|
|
3228
|
-
|
|
3229
|
-
|
|
3230
|
-
fastdom.flush();
|
|
3231
|
-
|
|
3232
|
-
const endHeight = toFloat(css(el, 'height')) + inner;
|
|
3233
|
-
duration = velocity * endHeight + duration;
|
|
3234
|
-
|
|
3235
|
-
css(el, { ...props, maxHeight: currentHeight });
|
|
3167
|
+
const prevProps = Object.fromEntries(
|
|
3168
|
+
['padding', 'border', 'width', 'height', 'overflow', marginProp, marginStartProp].map(
|
|
3169
|
+
(key) => [key, el.style[key]]));
|
|
3236
3170
|
|
|
3237
|
-
return (
|
|
3238
|
-
show ?
|
|
3239
|
-
Transition.start(
|
|
3240
|
-
el,
|
|
3241
|
-
{ ...initProps, overflow: 'hidden', maxHeight: endHeight },
|
|
3242
|
-
duration * (1 - currentHeight / endHeight),
|
|
3243
|
-
transition) :
|
|
3244
|
-
|
|
3245
|
-
Transition.start(
|
|
3246
|
-
el,
|
|
3247
|
-
hideProps,
|
|
3248
|
-
duration * (currentHeight / endHeight),
|
|
3249
|
-
transition).
|
|
3250
|
-
then(() => _toggle(el, false))).
|
|
3251
|
-
then(() => css(el, initProps));
|
|
3252
|
-
};
|
|
3253
|
-
}
|
|
3254
|
-
|
|
3255
|
-
function slideHorizontal(_ref5, right) {let { isToggled, duration, velocity, transition, _toggle } = _ref5;
|
|
3256
|
-
return (el, show) => {
|
|
3257
|
-
const visible = isVisible(el);
|
|
3258
|
-
const marginLeft = toFloat(css(el, 'marginLeft'));
|
|
3259
3171
|
|
|
3260
|
-
Transition.cancel(el);
|
|
3261
3172
|
|
|
3262
|
-
const
|
|
3263
|
-
css(
|
|
3173
|
+
const dim = dimensions$1(el);
|
|
3174
|
+
const currentMargin = toFloat(css(el, marginProp));
|
|
3175
|
+
const marginStart = toFloat(css(el, marginStartProp));
|
|
3176
|
+
const endDim = dim[dimProp] + marginStart;
|
|
3264
3177
|
|
|
3265
|
-
if (!
|
|
3266
|
-
|
|
3178
|
+
if (!inProgress && !show) {
|
|
3179
|
+
currentDim += marginStart;
|
|
3267
3180
|
}
|
|
3268
3181
|
|
|
3269
|
-
const
|
|
3270
|
-
|
|
3182
|
+
const [wrapper] = wrapInner(el, '<div>');
|
|
3183
|
+
css(wrapper, {
|
|
3184
|
+
boxSizing: 'border-box',
|
|
3185
|
+
height: dim.height,
|
|
3186
|
+
width: dim.width,
|
|
3187
|
+
...css(el, [
|
|
3188
|
+
'padding',
|
|
3189
|
+
'borderTop',
|
|
3190
|
+
'borderRight',
|
|
3191
|
+
'borderBottom',
|
|
3192
|
+
'borderLeft',
|
|
3193
|
+
'borderImage',
|
|
3194
|
+
marginStartProp]) });
|
|
3271
3195
|
|
|
3272
|
-
const percent = visible ? (width + marginLeft * (right ? -1 : 1)) / width * 100 : 0;
|
|
3273
|
-
const offsetEl = offset(el);
|
|
3274
|
-
const useClipPath = right ?
|
|
3275
|
-
offsetEl.right < scrollElement.clientWidth :
|
|
3276
|
-
Math.round(offsetEl.left) > 0;
|
|
3277
3196
|
|
|
3278
|
-
css(el, {
|
|
3279
|
-
clipPath: useClipPath ?
|
|
3280
|
-
right ? "polygon(0 0," +
|
|
3281
|
-
percent + "% 0," + percent + "% 100%,0 100%)" : "polygon(" + (
|
|
3282
|
-
100 - percent) + "% 0,100% 0,100% 100%," + (100 - percent) + "% 100%)" :
|
|
3283
|
-
'',
|
|
3284
|
-
marginLeft: (100 - percent) * (right ? 1 : -1) / 100 * width });
|
|
3285
3197
|
|
|
3198
|
+
css(el, {
|
|
3199
|
+
padding: 0,
|
|
3200
|
+
border: 0,
|
|
3201
|
+
[marginStartProp]: 0,
|
|
3202
|
+
width: dim.width,
|
|
3203
|
+
height: dim.height,
|
|
3204
|
+
overflow: 'hidden',
|
|
3205
|
+
[dimProp]: currentDim });
|
|
3286
3206
|
|
|
3287
|
-
return (
|
|
3288
|
-
show ?
|
|
3289
|
-
Transition.start(
|
|
3290
|
-
el,
|
|
3291
|
-
{
|
|
3292
|
-
clipPath: useClipPath ? "polygon(0 0,100% 0,100% 100%,0 100%)" : '',
|
|
3293
|
-
marginLeft: 0 },
|
|
3294
3207
|
|
|
3295
|
-
|
|
3296
|
-
|
|
3208
|
+
const percent = currentDim / endDim;
|
|
3209
|
+
duration = (velocity * endDim + duration) * (show ? 1 - percent : percent);
|
|
3210
|
+
const endProps = { [dimProp]: show ? endDim : 0 };
|
|
3297
3211
|
|
|
3298
|
-
|
|
3299
|
-
|
|
3300
|
-
|
|
3301
|
-
|
|
3302
|
-
right ? "polygon(0 0,0 0,0 100%,0 100%)" : "polygon(100% 0,100% 0,100% 100%,100% 100%)" :
|
|
3212
|
+
if (end) {
|
|
3213
|
+
css(el, marginProp, endDim - currentDim + currentMargin);
|
|
3214
|
+
endProps[marginProp] = show ? currentMargin : endDim + currentMargin;
|
|
3215
|
+
}
|
|
3303
3216
|
|
|
3217
|
+
if (!end ^ mode === 'reveal') {
|
|
3218
|
+
css(wrapper, marginProp, -endDim + currentDim);
|
|
3219
|
+
Transition.start(wrapper, { [marginProp]: show ? 0 : -endDim }, duration, transition);
|
|
3220
|
+
}
|
|
3304
3221
|
|
|
3305
|
-
|
|
3306
|
-
|
|
3222
|
+
try {
|
|
3223
|
+
await Transition.start(el, endProps, duration, transition);
|
|
3224
|
+
} finally {
|
|
3225
|
+
css(el, prevProps);
|
|
3226
|
+
unwrap(wrapper.firstChild);
|
|
3307
3227
|
|
|
3308
|
-
|
|
3309
|
-
|
|
3310
|
-
|
|
3311
|
-
|
|
3312
|
-
css(scrollElement, 'overflowX', '');
|
|
3313
|
-
css(el, { clipPath: '', marginLeft: '' });
|
|
3314
|
-
});
|
|
3228
|
+
if (!show) {
|
|
3229
|
+
_toggle(el, false);
|
|
3230
|
+
}
|
|
3231
|
+
}
|
|
3315
3232
|
};
|
|
3316
3233
|
}
|
|
3317
3234
|
|
|
@@ -3336,6 +3253,7 @@
|
|
|
3336
3253
|
mixins: [Class, Lazyload, Togglable],
|
|
3337
3254
|
|
|
3338
3255
|
props: {
|
|
3256
|
+
animation: Boolean,
|
|
3339
3257
|
targets: String,
|
|
3340
3258
|
active: null,
|
|
3341
3259
|
collapsible: Boolean,
|
|
@@ -3348,7 +3266,7 @@
|
|
|
3348
3266
|
data: {
|
|
3349
3267
|
targets: '> *',
|
|
3350
3268
|
active: false,
|
|
3351
|
-
animation:
|
|
3269
|
+
animation: true,
|
|
3352
3270
|
collapsible: true,
|
|
3353
3271
|
multiple: false,
|
|
3354
3272
|
clsOpen: 'uk-open',
|
|
@@ -3394,7 +3312,7 @@
|
|
|
3394
3312
|
hide(
|
|
3395
3313
|
el,
|
|
3396
3314
|
!hasClass(
|
|
3397
|
-
this.items.find((item) =>
|
|
3315
|
+
this.items.find((item) => within(el, item)),
|
|
3398
3316
|
this.clsOpen));
|
|
3399
3317
|
|
|
3400
3318
|
|
|
@@ -3446,23 +3364,15 @@
|
|
|
3446
3364
|
toggleClass(el, this.clsOpen, show);
|
|
3447
3365
|
attr($(this.$props.toggle, el), 'aria-expanded', show);
|
|
3448
3366
|
|
|
3449
|
-
const content = $(
|
|
3367
|
+
const content = $(this.content, el);
|
|
3450
3368
|
|
|
3451
|
-
if (animate === false || !this.
|
|
3369
|
+
if (animate === false || !this.animation) {
|
|
3370
|
+
content.hidden = !show;
|
|
3452
3371
|
hide(content, !show);
|
|
3453
3372
|
return;
|
|
3454
3373
|
}
|
|
3455
3374
|
|
|
3456
|
-
|
|
3457
|
-
el._wrapper = wrapAll(content, "<div" + (show ? ' hidden' : '') + ">");
|
|
3458
|
-
}
|
|
3459
|
-
|
|
3460
|
-
hide(content, false);
|
|
3461
|
-
await slide$1(this)(el._wrapper, show);
|
|
3462
|
-
hide(content, !show);
|
|
3463
|
-
|
|
3464
|
-
delete el._wrapper;
|
|
3465
|
-
unwrap(content);
|
|
3375
|
+
await toggleTransition(this)(content, show);
|
|
3466
3376
|
|
|
3467
3377
|
if (show) {
|
|
3468
3378
|
const toggle = $(this.$props.toggle, el);
|
|
@@ -3488,18 +3398,17 @@
|
|
|
3488
3398
|
args: 'animation',
|
|
3489
3399
|
|
|
3490
3400
|
props: {
|
|
3401
|
+
animation: Boolean,
|
|
3491
3402
|
close: String },
|
|
3492
3403
|
|
|
3493
3404
|
|
|
3494
3405
|
data: {
|
|
3495
|
-
animation:
|
|
3406
|
+
animation: true,
|
|
3496
3407
|
selClose: '.uk-alert-close',
|
|
3497
|
-
duration: 150,
|
|
3498
|
-
hideProps: { opacity: 0, ...Togglable.data.hideProps } },
|
|
3408
|
+
duration: 150 },
|
|
3499
3409
|
|
|
3500
3410
|
|
|
3501
|
-
events:
|
|
3502
|
-
{
|
|
3411
|
+
events: {
|
|
3503
3412
|
name: 'click',
|
|
3504
3413
|
|
|
3505
3414
|
delegate() {
|
|
@@ -3509,16 +3418,39 @@
|
|
|
3509
3418
|
handler(e) {
|
|
3510
3419
|
e.preventDefault();
|
|
3511
3420
|
this.close();
|
|
3512
|
-
} }
|
|
3513
|
-
|
|
3421
|
+
} },
|
|
3514
3422
|
|
|
3515
3423
|
|
|
3516
3424
|
methods: {
|
|
3517
3425
|
async close() {
|
|
3518
|
-
await this.toggleElement(this.$el);
|
|
3426
|
+
await this.toggleElement(this.$el, false, animate$1(this));
|
|
3519
3427
|
this.$destroy(true);
|
|
3520
3428
|
} } };
|
|
3521
3429
|
|
|
3430
|
+
|
|
3431
|
+
|
|
3432
|
+
function animate$1(_ref) {let { duration, transition, velocity } = _ref;
|
|
3433
|
+
return (el) => {
|
|
3434
|
+
const height = toFloat(css(el, 'height'));
|
|
3435
|
+
css(el, 'height', height);
|
|
3436
|
+
return Transition.start(
|
|
3437
|
+
el,
|
|
3438
|
+
{
|
|
3439
|
+
height: 0,
|
|
3440
|
+
marginTop: 0,
|
|
3441
|
+
marginBottom: 0,
|
|
3442
|
+
paddingTop: 0,
|
|
3443
|
+
paddingBottom: 0,
|
|
3444
|
+
borderTop: 0,
|
|
3445
|
+
borderBottom: 0,
|
|
3446
|
+
opacity: 0 },
|
|
3447
|
+
|
|
3448
|
+
velocity * height + duration,
|
|
3449
|
+
transition);
|
|
3450
|
+
|
|
3451
|
+
};
|
|
3452
|
+
}
|
|
3453
|
+
|
|
3522
3454
|
var Video = {
|
|
3523
3455
|
args: 'autoplay',
|
|
3524
3456
|
|
|
@@ -3667,13 +3599,17 @@
|
|
|
3667
3599
|
props: {
|
|
3668
3600
|
pos: String,
|
|
3669
3601
|
offset: null,
|
|
3670
|
-
flip: Boolean
|
|
3602
|
+
flip: Boolean,
|
|
3603
|
+
shift: Boolean,
|
|
3604
|
+
inset: Boolean },
|
|
3671
3605
|
|
|
3672
3606
|
|
|
3673
3607
|
data: {
|
|
3674
3608
|
pos: "bottom-" + (isRtl ? 'right' : 'left'),
|
|
3609
|
+
offset: false,
|
|
3675
3610
|
flip: true,
|
|
3676
|
-
|
|
3611
|
+
shift: true,
|
|
3612
|
+
inset: false },
|
|
3677
3613
|
|
|
3678
3614
|
|
|
3679
3615
|
connected() {
|
|
@@ -3685,19 +3621,24 @@
|
|
|
3685
3621
|
methods: {
|
|
3686
3622
|
positionAt(element, target, boundary) {
|
|
3687
3623
|
let offset = [this.getPositionOffset(element), this.getShiftOffset(element)];
|
|
3624
|
+
const placement = [this.flip && 'flip', this.shift && 'shift'];
|
|
3688
3625
|
|
|
3689
3626
|
const attach = {
|
|
3690
|
-
element: [flipPosition(this.dir), this.align],
|
|
3627
|
+
element: [this.inset ? this.dir : flipPosition(this.dir), this.align],
|
|
3691
3628
|
target: [this.dir, this.align] };
|
|
3692
3629
|
|
|
3693
3630
|
|
|
3694
3631
|
if (this.axis === 'y') {
|
|
3695
3632
|
for (const prop in attach) {
|
|
3696
|
-
attach[prop]
|
|
3633
|
+
attach[prop].reverse();
|
|
3697
3634
|
}
|
|
3698
|
-
offset
|
|
3635
|
+
offset.reverse();
|
|
3636
|
+
placement.reverse();
|
|
3699
3637
|
}
|
|
3700
3638
|
|
|
3639
|
+
const [scrollElement] = scrollParents(element, /auto|scroll/);
|
|
3640
|
+
const { scrollTop, scrollLeft } = scrollElement;
|
|
3641
|
+
|
|
3701
3642
|
// Ensure none positioned element does not generate scrollbars
|
|
3702
3643
|
const elDim = dimensions$1(element);
|
|
3703
3644
|
css(element, { top: -elDim.height, left: -elDim.width });
|
|
@@ -3706,93 +3647,88 @@
|
|
|
3706
3647
|
attach,
|
|
3707
3648
|
offset,
|
|
3708
3649
|
boundary,
|
|
3709
|
-
|
|
3650
|
+
placement,
|
|
3710
3651
|
viewportOffset: this.getViewportOffset(element) });
|
|
3711
3652
|
|
|
3653
|
+
|
|
3654
|
+
// Restore scroll position
|
|
3655
|
+
scrollElement.scrollTop = scrollTop;
|
|
3656
|
+
scrollElement.scrollLeft = scrollLeft;
|
|
3712
3657
|
},
|
|
3713
3658
|
|
|
3714
3659
|
getPositionOffset(element) {
|
|
3715
3660
|
return (
|
|
3716
3661
|
toPx(
|
|
3717
|
-
this.offset === false ?
|
|
3662
|
+
this.offset === false ? css(element, '--uk-position-offset') : this.offset,
|
|
3718
3663
|
this.axis === 'x' ? 'width' : 'height',
|
|
3719
3664
|
element) * (
|
|
3720
|
-
|
|
3665
|
+
|
|
3666
|
+
includes(['left', 'top'], this.dir) ? -1 : 1) * (
|
|
3667
|
+
this.inset ? -1 : 1));
|
|
3721
3668
|
|
|
3722
3669
|
},
|
|
3723
3670
|
|
|
3724
3671
|
getShiftOffset(element) {
|
|
3725
|
-
return
|
|
3672
|
+
return this.align === 'center' ?
|
|
3726
3673
|
0 :
|
|
3727
3674
|
toPx(
|
|
3728
|
-
|
|
3675
|
+
css(element, '--uk-position-shift-offset'),
|
|
3729
3676
|
this.axis === 'y' ? 'width' : 'height',
|
|
3730
3677
|
element) * (
|
|
3731
3678
|
includes(['left', 'top'], this.align) ? 1 : -1);
|
|
3732
3679
|
},
|
|
3733
3680
|
|
|
3734
3681
|
getViewportOffset(element) {
|
|
3735
|
-
return toPx(
|
|
3682
|
+
return toPx(css(element, '--uk-position-viewport-offset'));
|
|
3736
3683
|
} } };
|
|
3737
3684
|
|
|
3738
|
-
|
|
3685
|
+
var Style = {
|
|
3686
|
+
beforeConnect() {
|
|
3687
|
+
this._style = attr(this.$el, 'style');
|
|
3688
|
+
},
|
|
3739
3689
|
|
|
3740
|
-
|
|
3741
|
-
|
|
3690
|
+
disconnected() {
|
|
3691
|
+
attr(this.$el, 'style', this._style);
|
|
3692
|
+
} };
|
|
3742
3693
|
|
|
3743
|
-
|
|
3694
|
+
const active$1 = [];
|
|
3695
|
+
|
|
3696
|
+
var Modal = {
|
|
3697
|
+
mixins: [Class, Container, Togglable],
|
|
3744
3698
|
|
|
3745
3699
|
props: {
|
|
3746
|
-
|
|
3747
|
-
|
|
3748
|
-
|
|
3749
|
-
|
|
3750
|
-
|
|
3751
|
-
delayHide: Number,
|
|
3752
|
-
display: String,
|
|
3753
|
-
clsDrop: String,
|
|
3754
|
-
animateOut: Boolean },
|
|
3700
|
+
selPanel: String,
|
|
3701
|
+
selClose: String,
|
|
3702
|
+
escClose: Boolean,
|
|
3703
|
+
bgClose: Boolean,
|
|
3704
|
+
stack: Boolean },
|
|
3755
3705
|
|
|
3756
3706
|
|
|
3757
3707
|
data: {
|
|
3758
|
-
mode: ['click', 'hover'],
|
|
3759
|
-
toggle: '- *',
|
|
3760
|
-
boundary: true,
|
|
3761
|
-
boundaryAlign: false,
|
|
3762
|
-
delayShow: 0,
|
|
3763
|
-
delayHide: 800,
|
|
3764
|
-
display: null,
|
|
3765
|
-
clsDrop: false,
|
|
3766
|
-
animation: ['uk-animation-fade'],
|
|
3767
3708
|
cls: 'uk-open',
|
|
3768
|
-
|
|
3769
|
-
|
|
3709
|
+
escClose: true,
|
|
3710
|
+
bgClose: true,
|
|
3711
|
+
overlay: true,
|
|
3712
|
+
stack: false },
|
|
3770
3713
|
|
|
3771
3714
|
|
|
3772
|
-
|
|
3773
|
-
|
|
3774
|
-
|
|
3715
|
+
computed: {
|
|
3716
|
+
panel(_ref, $el) {let { selPanel } = _ref;
|
|
3717
|
+
return $(selPanel, $el);
|
|
3718
|
+
},
|
|
3775
3719
|
|
|
3776
|
-
|
|
3777
|
-
|
|
3778
|
-
|
|
3720
|
+
transitionElement() {
|
|
3721
|
+
return this.panel;
|
|
3722
|
+
},
|
|
3779
3723
|
|
|
3780
|
-
|
|
3781
|
-
|
|
3724
|
+
bgClose(_ref2) {let { bgClose } = _ref2;
|
|
3725
|
+
return bgClose && this.panel;
|
|
3726
|
+
} },
|
|
3782
3727
|
|
|
3783
|
-
if (this.toggle && !this.target) {
|
|
3784
|
-
this.target = this.$create('toggle', query(this.toggle, this.$el), {
|
|
3785
|
-
target: this.$el,
|
|
3786
|
-
mode: this.mode }).
|
|
3787
|
-
$el;
|
|
3788
|
-
attr(this.target, 'aria-haspopup', true);
|
|
3789
|
-
this.lazyload(this.target);
|
|
3790
|
-
}
|
|
3791
|
-
},
|
|
3792
3728
|
|
|
3793
|
-
|
|
3794
|
-
if (this
|
|
3795
|
-
|
|
3729
|
+
beforeDisconnect() {
|
|
3730
|
+
if (includes(active$1, this)) {
|
|
3731
|
+
this.toggleElement(this.$el, false, false);
|
|
3796
3732
|
}
|
|
3797
3733
|
},
|
|
3798
3734
|
|
|
@@ -3801,62 +3737,439 @@
|
|
|
3801
3737
|
name: 'click',
|
|
3802
3738
|
|
|
3803
3739
|
delegate() {
|
|
3804
|
-
return
|
|
3740
|
+
return this.selClose;
|
|
3805
3741
|
},
|
|
3806
3742
|
|
|
3807
3743
|
handler(e) {
|
|
3808
3744
|
e.preventDefault();
|
|
3809
|
-
this.hide(
|
|
3745
|
+
this.hide();
|
|
3810
3746
|
} },
|
|
3811
3747
|
|
|
3812
3748
|
|
|
3813
3749
|
{
|
|
3814
|
-
name: '
|
|
3750
|
+
name: 'toggle',
|
|
3815
3751
|
|
|
3816
|
-
|
|
3817
|
-
return 'a[href^="#"]';
|
|
3818
|
-
},
|
|
3752
|
+
self: true,
|
|
3819
3753
|
|
|
3820
|
-
handler(
|
|
3821
|
-
if (
|
|
3822
|
-
|
|
3754
|
+
handler(e) {
|
|
3755
|
+
if (e.defaultPrevented) {
|
|
3756
|
+
return;
|
|
3823
3757
|
}
|
|
3824
|
-
} },
|
|
3825
|
-
|
|
3826
3758
|
|
|
3827
|
-
|
|
3828
|
-
name: 'beforescroll',
|
|
3759
|
+
e.preventDefault();
|
|
3829
3760
|
|
|
3830
|
-
|
|
3831
|
-
|
|
3761
|
+
if (this.isToggled() === includes(active$1, this)) {
|
|
3762
|
+
this.toggle();
|
|
3763
|
+
}
|
|
3832
3764
|
} },
|
|
3833
3765
|
|
|
3834
3766
|
|
|
3835
3767
|
{
|
|
3836
|
-
name: '
|
|
3768
|
+
name: 'beforeshow',
|
|
3837
3769
|
|
|
3838
3770
|
self: true,
|
|
3839
3771
|
|
|
3840
|
-
handler(e
|
|
3841
|
-
|
|
3772
|
+
handler(e) {
|
|
3773
|
+
if (includes(active$1, this)) {
|
|
3774
|
+
return false;
|
|
3775
|
+
}
|
|
3842
3776
|
|
|
3843
|
-
if (this.
|
|
3844
|
-
|
|
3777
|
+
if (!this.stack && active$1.length) {
|
|
3778
|
+
Promise.all(active$1.map((modal) => modal.hide())).then(this.show);
|
|
3779
|
+
e.preventDefault();
|
|
3845
3780
|
} else {
|
|
3846
|
-
|
|
3781
|
+
active$1.push(this);
|
|
3847
3782
|
}
|
|
3848
3783
|
} },
|
|
3849
3784
|
|
|
3850
3785
|
|
|
3851
3786
|
{
|
|
3852
|
-
name: '
|
|
3787
|
+
name: 'show',
|
|
3853
3788
|
|
|
3854
3789
|
self: true,
|
|
3855
3790
|
|
|
3856
|
-
handler(
|
|
3857
|
-
|
|
3858
|
-
this
|
|
3859
|
-
|
|
3791
|
+
handler() {
|
|
3792
|
+
once(
|
|
3793
|
+
this.$el,
|
|
3794
|
+
'hide',
|
|
3795
|
+
on(document, 'focusin', (e) => {
|
|
3796
|
+
if (last(active$1) === this && !within(e.target, this.$el)) {
|
|
3797
|
+
this.$el.focus();
|
|
3798
|
+
}
|
|
3799
|
+
}));
|
|
3800
|
+
|
|
3801
|
+
|
|
3802
|
+
if (this.overlay) {
|
|
3803
|
+
once(this.$el, 'hidden', preventOverscroll(this.$el));
|
|
3804
|
+
once(this.$el, 'hidden', preventBackgroundScroll());
|
|
3805
|
+
}
|
|
3806
|
+
|
|
3807
|
+
if (this.stack) {
|
|
3808
|
+
css(this.$el, 'zIndex', toFloat(css(this.$el, 'zIndex')) + active$1.length);
|
|
3809
|
+
}
|
|
3810
|
+
|
|
3811
|
+
addClass(document.documentElement, this.clsPage);
|
|
3812
|
+
|
|
3813
|
+
if (this.bgClose) {
|
|
3814
|
+
once(
|
|
3815
|
+
this.$el,
|
|
3816
|
+
'hide',
|
|
3817
|
+
on(document, pointerDown$1, (_ref3) => {let { target } = _ref3;
|
|
3818
|
+
if (
|
|
3819
|
+
last(active$1) !== this ||
|
|
3820
|
+
this.overlay && !within(target, this.$el) ||
|
|
3821
|
+
within(target, this.panel))
|
|
3822
|
+
{
|
|
3823
|
+
return;
|
|
3824
|
+
}
|
|
3825
|
+
|
|
3826
|
+
once(
|
|
3827
|
+
document,
|
|
3828
|
+
pointerUp$1 + " " + pointerCancel + " scroll",
|
|
3829
|
+
(_ref4) => {let { defaultPrevented, type, target: newTarget } = _ref4;
|
|
3830
|
+
if (
|
|
3831
|
+
!defaultPrevented &&
|
|
3832
|
+
type === pointerUp$1 &&
|
|
3833
|
+
target === newTarget)
|
|
3834
|
+
{
|
|
3835
|
+
this.hide();
|
|
3836
|
+
}
|
|
3837
|
+
},
|
|
3838
|
+
true);
|
|
3839
|
+
|
|
3840
|
+
}),
|
|
3841
|
+
{ self: true });
|
|
3842
|
+
|
|
3843
|
+
}
|
|
3844
|
+
|
|
3845
|
+
if (this.escClose) {
|
|
3846
|
+
once(
|
|
3847
|
+
this.$el,
|
|
3848
|
+
'hide',
|
|
3849
|
+
on(document, 'keydown', (e) => {
|
|
3850
|
+
if (e.keyCode === 27 && last(active$1) === this) {
|
|
3851
|
+
this.hide();
|
|
3852
|
+
}
|
|
3853
|
+
}),
|
|
3854
|
+
{ self: true });
|
|
3855
|
+
|
|
3856
|
+
}
|
|
3857
|
+
} },
|
|
3858
|
+
|
|
3859
|
+
|
|
3860
|
+
{
|
|
3861
|
+
name: 'shown',
|
|
3862
|
+
|
|
3863
|
+
self: true,
|
|
3864
|
+
|
|
3865
|
+
handler() {
|
|
3866
|
+
if (!isFocusable(this.$el)) {
|
|
3867
|
+
attr(this.$el, 'tabindex', '-1');
|
|
3868
|
+
}
|
|
3869
|
+
|
|
3870
|
+
if (!$(':focus', this.$el)) {
|
|
3871
|
+
this.$el.focus();
|
|
3872
|
+
}
|
|
3873
|
+
} },
|
|
3874
|
+
|
|
3875
|
+
|
|
3876
|
+
{
|
|
3877
|
+
name: 'hidden',
|
|
3878
|
+
|
|
3879
|
+
self: true,
|
|
3880
|
+
|
|
3881
|
+
handler() {
|
|
3882
|
+
if (includes(active$1, this)) {
|
|
3883
|
+
active$1.splice(active$1.indexOf(this), 1);
|
|
3884
|
+
}
|
|
3885
|
+
|
|
3886
|
+
css(this.$el, 'zIndex', '');
|
|
3887
|
+
|
|
3888
|
+
if (!active$1.some((modal) => modal.clsPage === this.clsPage)) {
|
|
3889
|
+
removeClass(document.documentElement, this.clsPage);
|
|
3890
|
+
}
|
|
3891
|
+
} }],
|
|
3892
|
+
|
|
3893
|
+
|
|
3894
|
+
|
|
3895
|
+
methods: {
|
|
3896
|
+
toggle() {
|
|
3897
|
+
return this.isToggled() ? this.hide() : this.show();
|
|
3898
|
+
},
|
|
3899
|
+
|
|
3900
|
+
show() {
|
|
3901
|
+
if (this.container && parent(this.$el) !== this.container) {
|
|
3902
|
+
append(this.container, this.$el);
|
|
3903
|
+
return new Promise((resolve) =>
|
|
3904
|
+
requestAnimationFrame(() => this.show().then(resolve)));
|
|
3905
|
+
|
|
3906
|
+
}
|
|
3907
|
+
|
|
3908
|
+
return this.toggleElement(this.$el, true, animate(this));
|
|
3909
|
+
},
|
|
3910
|
+
|
|
3911
|
+
hide() {
|
|
3912
|
+
return this.toggleElement(this.$el, false, animate(this));
|
|
3913
|
+
} } };
|
|
3914
|
+
|
|
3915
|
+
|
|
3916
|
+
|
|
3917
|
+
function animate(_ref5) {let { transitionElement, _toggle } = _ref5;
|
|
3918
|
+
return (el, show) =>
|
|
3919
|
+
new Promise((resolve, reject) =>
|
|
3920
|
+
once(el, 'show hide', () => {
|
|
3921
|
+
el._reject == null ? void 0 : el._reject();
|
|
3922
|
+
el._reject = reject;
|
|
3923
|
+
|
|
3924
|
+
_toggle(el, show);
|
|
3925
|
+
|
|
3926
|
+
const off = once(
|
|
3927
|
+
transitionElement,
|
|
3928
|
+
'transitionstart',
|
|
3929
|
+
() => {
|
|
3930
|
+
once(transitionElement, 'transitionend transitioncancel', resolve, {
|
|
3931
|
+
self: true });
|
|
3932
|
+
|
|
3933
|
+
clearTimeout(timer);
|
|
3934
|
+
},
|
|
3935
|
+
{ self: true });
|
|
3936
|
+
|
|
3937
|
+
|
|
3938
|
+
const timer = setTimeout(() => {
|
|
3939
|
+
off();
|
|
3940
|
+
resolve();
|
|
3941
|
+
}, toMs(css(transitionElement, 'transitionDuration')));
|
|
3942
|
+
})).
|
|
3943
|
+
then(() => delete el._reject);
|
|
3944
|
+
}
|
|
3945
|
+
|
|
3946
|
+
function toMs(time) {
|
|
3947
|
+
return time ? endsWith(time, 'ms') ? toFloat(time) : toFloat(time) * 1000 : 0;
|
|
3948
|
+
}
|
|
3949
|
+
|
|
3950
|
+
function preventOverscroll(el) {
|
|
3951
|
+
if (CSS.supports('overscroll-behavior', 'contain')) {
|
|
3952
|
+
const elements = filterChildren(el, (child) => /auto|scroll/.test(css(child, 'overflow')));
|
|
3953
|
+
css(elements, 'overscrollBehavior', 'contain');
|
|
3954
|
+
return () => css(elements, 'overscrollBehavior', '');
|
|
3955
|
+
}
|
|
3956
|
+
|
|
3957
|
+
let startClientY;
|
|
3958
|
+
|
|
3959
|
+
const events = [
|
|
3960
|
+
on(
|
|
3961
|
+
el,
|
|
3962
|
+
'touchstart',
|
|
3963
|
+
(_ref6) => {let { targetTouches } = _ref6;
|
|
3964
|
+
if (targetTouches.length === 1) {
|
|
3965
|
+
startClientY = targetTouches[0].clientY;
|
|
3966
|
+
}
|
|
3967
|
+
},
|
|
3968
|
+
{ passive: true }),
|
|
3969
|
+
|
|
3970
|
+
|
|
3971
|
+
on(
|
|
3972
|
+
el,
|
|
3973
|
+
'touchmove',
|
|
3974
|
+
(e) => {
|
|
3975
|
+
if (e.targetTouches.length !== 1) {
|
|
3976
|
+
return;
|
|
3977
|
+
}
|
|
3978
|
+
|
|
3979
|
+
let [scrollParent] = scrollParents(e.target, /auto|scroll/);
|
|
3980
|
+
if (!within(scrollParent, el)) {
|
|
3981
|
+
scrollParent = el;
|
|
3982
|
+
}
|
|
3983
|
+
|
|
3984
|
+
const clientY = e.targetTouches[0].clientY - startClientY;
|
|
3985
|
+
const { scrollTop, scrollHeight, clientHeight } = scrollParent;
|
|
3986
|
+
|
|
3987
|
+
if (
|
|
3988
|
+
clientHeight >= scrollHeight ||
|
|
3989
|
+
scrollTop === 0 && clientY > 0 ||
|
|
3990
|
+
scrollHeight - scrollTop <= clientHeight && clientY < 0)
|
|
3991
|
+
{
|
|
3992
|
+
e.cancelable && e.preventDefault();
|
|
3993
|
+
}
|
|
3994
|
+
},
|
|
3995
|
+
{ passive: false })];
|
|
3996
|
+
|
|
3997
|
+
|
|
3998
|
+
|
|
3999
|
+
return () => events.forEach((fn) => fn());
|
|
4000
|
+
}
|
|
4001
|
+
|
|
4002
|
+
let prevented;
|
|
4003
|
+
function preventBackgroundScroll() {
|
|
4004
|
+
if (prevented) {
|
|
4005
|
+
return noop;
|
|
4006
|
+
}
|
|
4007
|
+
prevented = true;
|
|
4008
|
+
const { body, documentElement } = document;
|
|
4009
|
+
css(body, {
|
|
4010
|
+
overflowY: width(window) > documentElement.clientWidth ? 'scroll' : '',
|
|
4011
|
+
touchAction: 'none' });
|
|
4012
|
+
|
|
4013
|
+
css(documentElement, 'overflowY', 'hidden');
|
|
4014
|
+
return () => {
|
|
4015
|
+
prevented = false;
|
|
4016
|
+
css(documentElement, 'overflowY', '');
|
|
4017
|
+
css(body, { overflowY: '', touchAction: '' });
|
|
4018
|
+
};
|
|
4019
|
+
}
|
|
4020
|
+
|
|
4021
|
+
function filterChildren(el, fn) {
|
|
4022
|
+
const children = [];
|
|
4023
|
+
apply(el, (node) => {
|
|
4024
|
+
if (fn(node)) {
|
|
4025
|
+
children.push(node);
|
|
4026
|
+
}
|
|
4027
|
+
});
|
|
4028
|
+
return children;
|
|
4029
|
+
}
|
|
4030
|
+
|
|
4031
|
+
let active;
|
|
4032
|
+
|
|
4033
|
+
var drop = {
|
|
4034
|
+
mixins: [Container, Lazyload, Position, Style, Togglable],
|
|
4035
|
+
|
|
4036
|
+
args: 'pos',
|
|
4037
|
+
|
|
4038
|
+
props: {
|
|
4039
|
+
mode: 'list',
|
|
4040
|
+
toggle: Boolean,
|
|
4041
|
+
boundary: Boolean,
|
|
4042
|
+
target: Boolean,
|
|
4043
|
+
targetX: Boolean,
|
|
4044
|
+
targetY: Boolean,
|
|
4045
|
+
stretch: Boolean,
|
|
4046
|
+
delayShow: Number,
|
|
4047
|
+
delayHide: Number,
|
|
4048
|
+
display: String,
|
|
4049
|
+
clsDrop: String,
|
|
4050
|
+
animateOut: Boolean,
|
|
4051
|
+
bgScroll: Boolean },
|
|
4052
|
+
|
|
4053
|
+
|
|
4054
|
+
data: {
|
|
4055
|
+
mode: ['click', 'hover'],
|
|
4056
|
+
toggle: '- *',
|
|
4057
|
+
boundary: false,
|
|
4058
|
+
target: false,
|
|
4059
|
+
targetX: false,
|
|
4060
|
+
targetY: false,
|
|
4061
|
+
stretch: false,
|
|
4062
|
+
delayShow: 0,
|
|
4063
|
+
delayHide: 800,
|
|
4064
|
+
display: null,
|
|
4065
|
+
clsDrop: false,
|
|
4066
|
+
animateOut: false,
|
|
4067
|
+
bgScroll: true,
|
|
4068
|
+
animation: ['uk-animation-fade'],
|
|
4069
|
+
cls: 'uk-open',
|
|
4070
|
+
container: false },
|
|
4071
|
+
|
|
4072
|
+
|
|
4073
|
+
computed: {
|
|
4074
|
+
target(_ref, $el) {let { target, targetX, targetY } = _ref;
|
|
4075
|
+
targetX = targetX || target || this.targetEl;
|
|
4076
|
+
targetY = targetY || target || this.targetEl;
|
|
4077
|
+
|
|
4078
|
+
return [
|
|
4079
|
+
targetX === true ? window : query(targetX, $el),
|
|
4080
|
+
targetY === true ? window : query(targetY, $el)];
|
|
4081
|
+
|
|
4082
|
+
} },
|
|
4083
|
+
|
|
4084
|
+
|
|
4085
|
+
created() {
|
|
4086
|
+
this.tracker = new MouseTracker();
|
|
4087
|
+
},
|
|
4088
|
+
|
|
4089
|
+
beforeConnect() {
|
|
4090
|
+
this.clsDrop = this.$props.clsDrop || "uk-" + this.$options.name;
|
|
4091
|
+
},
|
|
4092
|
+
|
|
4093
|
+
connected() {
|
|
4094
|
+
addClass(this.$el, this.clsDrop);
|
|
4095
|
+
|
|
4096
|
+
if (this.toggle && !this.targetEl) {
|
|
4097
|
+
this.targetEl = this.$create('toggle', query(this.toggle, this.$el), {
|
|
4098
|
+
target: this.$el,
|
|
4099
|
+
mode: this.mode }).
|
|
4100
|
+
$el;
|
|
4101
|
+
attr(this.targetEl, 'aria-haspopup', true);
|
|
4102
|
+
this.lazyload(this.targetEl);
|
|
4103
|
+
}
|
|
4104
|
+
},
|
|
4105
|
+
|
|
4106
|
+
disconnected() {
|
|
4107
|
+
if (this.isActive()) {
|
|
4108
|
+
active = null;
|
|
4109
|
+
}
|
|
4110
|
+
},
|
|
4111
|
+
|
|
4112
|
+
events: [
|
|
4113
|
+
{
|
|
4114
|
+
name: 'click',
|
|
4115
|
+
|
|
4116
|
+
delegate() {
|
|
4117
|
+
return "." + this.clsDrop + "-close";
|
|
4118
|
+
},
|
|
4119
|
+
|
|
4120
|
+
handler(e) {
|
|
4121
|
+
e.preventDefault();
|
|
4122
|
+
this.hide(false);
|
|
4123
|
+
} },
|
|
4124
|
+
|
|
4125
|
+
|
|
4126
|
+
{
|
|
4127
|
+
name: 'click',
|
|
4128
|
+
|
|
4129
|
+
delegate() {
|
|
4130
|
+
return 'a[href^="#"]';
|
|
4131
|
+
},
|
|
4132
|
+
|
|
4133
|
+
handler(_ref2) {let { defaultPrevented, current: { hash } } = _ref2;
|
|
4134
|
+
if (!defaultPrevented && hash && !within(hash, this.$el)) {
|
|
4135
|
+
this.hide(false);
|
|
4136
|
+
}
|
|
4137
|
+
} },
|
|
4138
|
+
|
|
4139
|
+
|
|
4140
|
+
{
|
|
4141
|
+
name: 'beforescroll',
|
|
4142
|
+
|
|
4143
|
+
handler() {
|
|
4144
|
+
this.hide(false);
|
|
4145
|
+
} },
|
|
4146
|
+
|
|
4147
|
+
|
|
4148
|
+
{
|
|
4149
|
+
name: 'toggle',
|
|
4150
|
+
|
|
4151
|
+
self: true,
|
|
4152
|
+
|
|
4153
|
+
handler(e, toggle) {
|
|
4154
|
+
e.preventDefault();
|
|
4155
|
+
|
|
4156
|
+
if (this.isToggled()) {
|
|
4157
|
+
this.hide(false);
|
|
4158
|
+
} else {
|
|
4159
|
+
this.show(toggle == null ? void 0 : toggle.$el, false);
|
|
4160
|
+
}
|
|
4161
|
+
} },
|
|
4162
|
+
|
|
4163
|
+
|
|
4164
|
+
{
|
|
4165
|
+
name: 'toggleshow',
|
|
4166
|
+
|
|
4167
|
+
self: true,
|
|
4168
|
+
|
|
4169
|
+
handler(e, toggle) {
|
|
4170
|
+
e.preventDefault();
|
|
4171
|
+
this.show(toggle == null ? void 0 : toggle.$el);
|
|
4172
|
+
} },
|
|
3860
4173
|
|
|
3861
4174
|
|
|
3862
4175
|
{
|
|
@@ -3921,25 +4234,25 @@
|
|
|
3921
4234
|
self: true,
|
|
3922
4235
|
|
|
3923
4236
|
handler() {
|
|
3924
|
-
active
|
|
4237
|
+
active = this;
|
|
3925
4238
|
|
|
3926
4239
|
this.tracker.init();
|
|
3927
4240
|
|
|
3928
4241
|
for (const handler of [
|
|
3929
4242
|
on(
|
|
3930
4243
|
document,
|
|
3931
|
-
pointerDown,
|
|
3932
|
-
(
|
|
4244
|
+
pointerDown$1,
|
|
4245
|
+
(_ref3) => {let { target } = _ref3;return (
|
|
3933
4246
|
!within(target, this.$el) &&
|
|
3934
4247
|
once(
|
|
3935
4248
|
document,
|
|
3936
|
-
pointerUp + " " + pointerCancel + " scroll",
|
|
3937
|
-
(
|
|
4249
|
+
pointerUp$1 + " " + pointerCancel + " scroll",
|
|
4250
|
+
(_ref4) => {let { defaultPrevented, type, target: newTarget } = _ref4;
|
|
3938
4251
|
if (
|
|
3939
4252
|
!defaultPrevented &&
|
|
3940
|
-
type === pointerUp &&
|
|
4253
|
+
type === pointerUp$1 &&
|
|
3941
4254
|
target === newTarget &&
|
|
3942
|
-
!(this.
|
|
4255
|
+
!(this.targetEl && within(target, this.targetEl)))
|
|
3943
4256
|
{
|
|
3944
4257
|
this.hide(false);
|
|
3945
4258
|
}
|
|
@@ -3954,13 +4267,17 @@
|
|
|
3954
4267
|
}
|
|
3955
4268
|
}),
|
|
3956
4269
|
|
|
3957
|
-
...(this.
|
|
4270
|
+
...(this.bgScroll ?
|
|
4271
|
+
[] :
|
|
4272
|
+
[preventOverscroll(this.$el), preventBackgroundScroll()]),
|
|
4273
|
+
|
|
4274
|
+
...(this.display === 'static' ?
|
|
3958
4275
|
[] :
|
|
3959
4276
|
(() => {
|
|
3960
4277
|
const handler = () => this.$emit();
|
|
3961
4278
|
return [
|
|
3962
4279
|
on(window, 'resize', handler),
|
|
3963
|
-
on(document, 'scroll', handler
|
|
4280
|
+
on([document, scrollParents(this.$el)], 'scroll', handler),
|
|
3964
4281
|
(() => {
|
|
3965
4282
|
const observer = observeResize(
|
|
3966
4283
|
scrollParents(this.$el),
|
|
@@ -3989,16 +4306,16 @@
|
|
|
3989
4306
|
{
|
|
3990
4307
|
name: 'hide',
|
|
3991
4308
|
|
|
3992
|
-
handler(
|
|
4309
|
+
handler(_ref5) {let { target } = _ref5;
|
|
3993
4310
|
if (this.$el !== target) {
|
|
3994
|
-
active
|
|
3995
|
-
active
|
|
4311
|
+
active =
|
|
4312
|
+
active === null && within(target, this.$el) && this.isToggled() ?
|
|
3996
4313
|
this :
|
|
3997
|
-
active
|
|
4314
|
+
active;
|
|
3998
4315
|
return;
|
|
3999
4316
|
}
|
|
4000
4317
|
|
|
4001
|
-
active
|
|
4318
|
+
active = this.isActive() ? null : active;
|
|
4002
4319
|
this.tracker.cancel();
|
|
4003
4320
|
} }],
|
|
4004
4321
|
|
|
@@ -4013,12 +4330,12 @@
|
|
|
4013
4330
|
|
|
4014
4331
|
|
|
4015
4332
|
methods: {
|
|
4016
|
-
show(target, delay) {if (target === void 0) {target = this.
|
|
4017
|
-
if (this.isToggled() && target && this.
|
|
4333
|
+
show(target, delay) {if (target === void 0) {target = this.targetEl;}if (delay === void 0) {delay = true;}
|
|
4334
|
+
if (this.isToggled() && target && this.targetEl && target !== this.targetEl) {
|
|
4018
4335
|
this.hide(false, false);
|
|
4019
4336
|
}
|
|
4020
4337
|
|
|
4021
|
-
this.
|
|
4338
|
+
this.targetEl = target;
|
|
4022
4339
|
|
|
4023
4340
|
this.clearTimers();
|
|
4024
4341
|
|
|
@@ -4026,16 +4343,16 @@
|
|
|
4026
4343
|
return;
|
|
4027
4344
|
}
|
|
4028
4345
|
|
|
4029
|
-
if (active
|
|
4030
|
-
if (delay && active
|
|
4346
|
+
if (active) {
|
|
4347
|
+
if (delay && active.isDelaying) {
|
|
4031
4348
|
this.showTimer = setTimeout(() => matches(target, ':hover') && this.show(), 10);
|
|
4032
4349
|
return;
|
|
4033
4350
|
}
|
|
4034
4351
|
|
|
4035
4352
|
let prev;
|
|
4036
|
-
while (active
|
|
4037
|
-
prev = active
|
|
4038
|
-
active
|
|
4353
|
+
while (active && prev !== active && !within(this.$el, active.$el)) {
|
|
4354
|
+
prev = active;
|
|
4355
|
+
active.hide(false, false);
|
|
4039
4356
|
}
|
|
4040
4357
|
}
|
|
4041
4358
|
|
|
@@ -4076,65 +4393,74 @@
|
|
|
4076
4393
|
},
|
|
4077
4394
|
|
|
4078
4395
|
isActive() {
|
|
4079
|
-
return active
|
|
4396
|
+
return active === this;
|
|
4080
4397
|
},
|
|
4081
4398
|
|
|
4082
4399
|
position() {
|
|
4083
4400
|
removeClass(this.$el, this.clsDrop + "-stack");
|
|
4084
|
-
|
|
4085
|
-
toggleClass(this.$el, this.clsDrop + "-stretch", this.align === 'stretch');
|
|
4401
|
+
attr(this.$el, 'style', this._style);
|
|
4086
4402
|
|
|
4087
|
-
|
|
4088
|
-
|
|
4089
|
-
const [scrollParent] = scrollParents(
|
|
4090
|
-
boundary && this.boundaryAlign ? boundary : this.$el);
|
|
4403
|
+
// Ensure none positioned element does not generate scrollbars
|
|
4404
|
+
this.$el.hidden = true;
|
|
4091
4405
|
|
|
4092
|
-
const
|
|
4093
|
-
const boundaryOffset = boundary
|
|
4406
|
+
const boundary = query(this.boundary, this.$el);
|
|
4407
|
+
const boundaryOffset = offsetViewport(boundary || window);
|
|
4408
|
+
const viewports = this.target.map((target) => offsetViewport(scrollParents(target)[0]));
|
|
4094
4409
|
const viewportOffset = this.getViewportOffset(this.$el);
|
|
4095
4410
|
|
|
4096
|
-
|
|
4097
|
-
|
|
4411
|
+
const dirs = [
|
|
4412
|
+
[0, ['x', 'width', 'left', 'right']],
|
|
4413
|
+
[1, ['y', 'height', 'top', 'bottom']]];
|
|
4098
4414
|
|
|
4099
|
-
|
|
4100
|
-
|
|
4101
|
-
|
|
4102
|
-
|
|
4103
|
-
|
|
4104
|
-
|
|
4105
|
-
|
|
4106
|
-
|
|
4107
|
-
|
|
4108
|
-
|
|
4109
|
-
|
|
4110
|
-
|
|
4111
|
-
|
|
4112
|
-
|
|
4113
|
-
|
|
4114
|
-
|
|
4115
|
-
const elOffset = Math.abs(this.getPositionOffset(this.$el)) + viewportOffset;
|
|
4116
|
-
|
|
4117
|
-
css(this.$el, {
|
|
4118
|
-
width:
|
|
4119
|
-
this.axis === 'y' ?
|
|
4120
|
-
viewport.width :
|
|
4121
|
-
(this.dir === 'left' ?
|
|
4122
|
-
targetDim.left - viewport.left :
|
|
4123
|
-
viewport.right - targetDim.right) - elOffset,
|
|
4124
|
-
height:
|
|
4125
|
-
this.axis === 'x' ?
|
|
4126
|
-
viewport.height :
|
|
4127
|
-
(this.dir === 'top' ?
|
|
4128
|
-
targetDim.top - viewport.top :
|
|
4129
|
-
viewport.bottom - targetDim.bottom) - elOffset });
|
|
4130
|
-
|
|
4131
|
-
} else if (this.$el.offsetWidth > maxWidth) {
|
|
4415
|
+
|
|
4416
|
+
for (const [i, [axis, prop]] of dirs) {
|
|
4417
|
+
if (this.axis !== axis && includes([axis, true], this.stretch)) {
|
|
4418
|
+
css(this.$el, {
|
|
4419
|
+
[prop]: Math.min(
|
|
4420
|
+
boundaryOffset[prop],
|
|
4421
|
+
viewports[i][prop] - 2 * viewportOffset),
|
|
4422
|
+
|
|
4423
|
+
["overflow-" + axis]: 'auto' });
|
|
4424
|
+
|
|
4425
|
+
}
|
|
4426
|
+
}
|
|
4427
|
+
|
|
4428
|
+
const maxWidth = viewports[0].width - 2 * viewportOffset;
|
|
4429
|
+
|
|
4430
|
+
if (this.$el.offsetWidth > maxWidth) {
|
|
4132
4431
|
addClass(this.$el, this.clsDrop + "-stack");
|
|
4133
4432
|
}
|
|
4134
4433
|
|
|
4135
4434
|
css(this.$el, 'maxWidth', maxWidth);
|
|
4136
4435
|
|
|
4137
|
-
this
|
|
4436
|
+
this.$el.hidden = false;
|
|
4437
|
+
|
|
4438
|
+
this.positionAt(this.$el, this.target, boundary);
|
|
4439
|
+
|
|
4440
|
+
for (const [i, [axis, prop, start, end]] of dirs) {
|
|
4441
|
+
if (this.axis === axis && includes([axis, true], this.stretch)) {
|
|
4442
|
+
const positionOffset = Math.abs(this.getPositionOffset(this.$el));
|
|
4443
|
+
const targetOffset = offset(this.target[i]);
|
|
4444
|
+
const elOffset = offset(this.$el);
|
|
4445
|
+
|
|
4446
|
+
css(this.$el, {
|
|
4447
|
+
[prop]:
|
|
4448
|
+
(targetOffset[start] > elOffset[start] ?
|
|
4449
|
+
targetOffset[start] -
|
|
4450
|
+
Math.max(
|
|
4451
|
+
boundaryOffset[start],
|
|
4452
|
+
viewports[i][start] + viewportOffset) :
|
|
4453
|
+
|
|
4454
|
+
Math.min(
|
|
4455
|
+
boundaryOffset[end],
|
|
4456
|
+
viewports[i][end] - viewportOffset) -
|
|
4457
|
+
targetOffset[end]) - positionOffset,
|
|
4458
|
+
["overflow-" + axis]: 'auto' });
|
|
4459
|
+
|
|
4460
|
+
|
|
4461
|
+
this.positionAt(this.$el, this.target, boundary);
|
|
4462
|
+
}
|
|
4463
|
+
}
|
|
4138
4464
|
} } };
|
|
4139
4465
|
|
|
4140
4466
|
|
|
@@ -4631,8 +4957,11 @@
|
|
|
4631
4957
|
let minHeight = '';
|
|
4632
4958
|
const box = boxModelAdjust(this.$el, 'height', 'content-box');
|
|
4633
4959
|
|
|
4960
|
+
const { body, scrollingElement } = document;
|
|
4634
4961
|
const [scrollElement] = scrollParents(this.$el, /auto|scroll/);
|
|
4635
|
-
const { height: viewportHeight } = offsetViewport(
|
|
4962
|
+
const { height: viewportHeight } = offsetViewport(
|
|
4963
|
+
scrollElement === body ? scrollingElement : scrollElement);
|
|
4964
|
+
|
|
4636
4965
|
|
|
4637
4966
|
if (this.expand) {
|
|
4638
4967
|
minHeight = Math.max(
|
|
@@ -4642,14 +4971,19 @@
|
|
|
4642
4971
|
0);
|
|
4643
4972
|
|
|
4644
4973
|
} else {
|
|
4645
|
-
|
|
4646
|
-
|
|
4647
|
-
document.scrollingElement === scrollElement ? '100vh' : viewportHeight + "px");
|
|
4974
|
+
const isScrollingElement =
|
|
4975
|
+
scrollingElement === scrollElement || body === scrollElement;
|
|
4648
4976
|
|
|
4977
|
+
// on mobile devices (iOS and Android) window.innerHeight !== 100vh
|
|
4978
|
+
minHeight = "calc(" + (isScrollingElement ? '100vh' : viewportHeight + "px");
|
|
4649
4979
|
|
|
4650
4980
|
if (this.offsetTop) {
|
|
4651
|
-
|
|
4652
|
-
|
|
4981
|
+
if (isScrollingElement) {
|
|
4982
|
+
const top = offsetPosition(this.$el)[0] - offsetPosition(scrollElement)[0];
|
|
4983
|
+
minHeight += top > 0 && top < viewportHeight / 2 ? " - " + top + "px" : '';
|
|
4984
|
+
} else {
|
|
4985
|
+
minHeight += " - " + css(scrollElement, 'paddingTop');
|
|
4986
|
+
}
|
|
4653
4987
|
}
|
|
4654
4988
|
|
|
4655
4989
|
if (this.offsetBottom === true) {
|
|
@@ -4888,11 +5222,17 @@
|
|
|
4888
5222
|
|
|
4889
5223
|
var closeIcon = "<svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" xmlns=\"http://www.w3.org/2000/svg\"><line fill=\"none\" stroke=\"#000\" stroke-width=\"1.1\" x1=\"1\" y1=\"1\" x2=\"13\" y2=\"13\"/><line fill=\"none\" stroke=\"#000\" stroke-width=\"1.1\" x1=\"13\" y1=\"1\" x2=\"1\" y2=\"13\"/></svg>";
|
|
4890
5224
|
|
|
4891
|
-
var closeLarge = "<svg width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><line fill=\"none\" stroke=\"#000\" stroke-width=\"1.4\" x1=\"1\" y1=\"1\" x2=\"19\" y2=\"19\"/><line fill=\"none\" stroke=\"#000\" stroke-width=\"1.4\" x1=\"19\" y1=\"1\" x2=\"1\" y2=\"19\"/></svg>";
|
|
5225
|
+
var closeLarge = "<svg width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><line fill=\"none\" stroke=\"#000\" stroke-width=\"1.4\" x1=\"1\" y1=\"1\" x2=\"19\" y2=\"19\"/><line fill=\"none\" stroke=\"#000\" stroke-width=\"1.4\" x1=\"19\" y1=\"1\" x2=\"1\" y2=\"19\"/></svg>";
|
|
5226
|
+
|
|
5227
|
+
var marker = "<svg width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><rect x=\"9\" y=\"4\" width=\"1\" height=\"11\"/><rect x=\"4\" y=\"9\" width=\"11\" height=\"1\"/></svg>";
|
|
5228
|
+
|
|
5229
|
+
var navParentIcon = "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"12\" height=\"12\" viewBox=\"0 0 12 12\"><polyline fill=\"none\" stroke=\"#000\" stroke-width=\"1.1\" points=\"1 3.5 6 8.5 11 3.5\"/></svg>";
|
|
5230
|
+
|
|
5231
|
+
var navParentIconLarge = "<svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" xmlns=\"http://www.w3.org/2000/svg\"><polyline fill=\"none\" stroke=\"#000\" stroke-width=\"1.1\" points=\"1 4 7 10 13 4\"/></svg>";
|
|
4892
5232
|
|
|
4893
|
-
var
|
|
5233
|
+
var navbarParentIcon = "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"12\" height=\"12\" viewBox=\"0 0 12 12\"><polyline fill=\"none\" stroke=\"#000\" stroke-width=\"1.1\" points=\"1 3.5 6 8.5 11 3.5\"/></svg>";
|
|
4894
5234
|
|
|
4895
|
-
var navbarToggleIcon = "<svg width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><rect y=\"
|
|
5235
|
+
var navbarToggleIcon = "<svg width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><style>.uk-navbar-toggle svg > [class*='line-'] {\n transition: 0.2s ease-in-out;\n transition-property: transform, opacity,;\n transform-origin: center;\n opacity: 1;\n }\n\n .uk-navbar-toggle[aria-expanded=\"true\"] svg > .line-2 { transform: rotate(45deg); }\n .uk-navbar-toggle[aria-expanded=\"true\"] svg > .line-3 { transform: rotate(-45deg); }\n\n .uk-navbar-toggle[aria-expanded=\"true\"] svg > .line-1,\n .uk-navbar-toggle[aria-expanded=\"true\"] svg > .line-4 { opacity: 0; }\n .uk-navbar-toggle[aria-expanded=\"true\"] svg > .line-1 { transform: translateY(6px) scaleX(0); }\n .uk-navbar-toggle[aria-expanded=\"true\"] svg > .line-4 { transform: translateY(-6px) scaleX(0); }</style><rect class=\"line-1\" y=\"3\" width=\"20\" height=\"2\"/><rect class=\"line-2\" y=\"9\" width=\"20\" height=\"2\"/><rect class=\"line-3\" y=\"9\" width=\"20\" height=\"2\"/><rect class=\"line-4\" y=\"15\" width=\"20\" height=\"2\"/></svg>";
|
|
4896
5236
|
|
|
4897
5237
|
var overlayIcon = "<svg width=\"40\" height=\"40\" viewBox=\"0 0 40 40\" xmlns=\"http://www.w3.org/2000/svg\"><rect x=\"19\" y=\"0\" width=\"1\" height=\"40\"/><rect x=\"0\" y=\"19\" width=\"40\" height=\"1\"/></svg>";
|
|
4898
5238
|
|
|
@@ -4924,6 +5264,9 @@
|
|
|
4924
5264
|
marker,
|
|
4925
5265
|
'close-icon': closeIcon,
|
|
4926
5266
|
'close-large': closeLarge,
|
|
5267
|
+
'nav-parent-icon': navParentIcon,
|
|
5268
|
+
'nav-parent-icon-large': navParentIconLarge,
|
|
5269
|
+
'navbar-parent-icon': navbarParentIcon,
|
|
4927
5270
|
'navbar-toggle-icon': navbarToggleIcon,
|
|
4928
5271
|
'overlay-icon': overlayIcon,
|
|
4929
5272
|
'pagination-next': paginationNext,
|
|
@@ -4981,6 +5324,15 @@
|
|
|
4981
5324
|
} };
|
|
4982
5325
|
|
|
4983
5326
|
|
|
5327
|
+
const NavParentIcon = {
|
|
5328
|
+
extends: IconComponent,
|
|
5329
|
+
|
|
5330
|
+
beforeConnect() {
|
|
5331
|
+
const icon = this.$props.icon;
|
|
5332
|
+
this.icon = closest(this.$el, '.uk-nav-primary') ? icon + "-large" : icon;
|
|
5333
|
+
} };
|
|
5334
|
+
|
|
5335
|
+
|
|
4984
5336
|
const Slidenav = {
|
|
4985
5337
|
extends: IconComponent,
|
|
4986
5338
|
|
|
@@ -5192,385 +5544,133 @@
|
|
|
5192
5544
|
append(picture, source);
|
|
5193
5545
|
}
|
|
5194
5546
|
append(picture, img);
|
|
5195
|
-
}
|
|
5196
|
-
}
|
|
5197
|
-
|
|
5198
|
-
function parseSources(sources) {
|
|
5199
|
-
if (!sources) {
|
|
5200
|
-
return [];
|
|
5201
|
-
}
|
|
5202
|
-
|
|
5203
|
-
if (startsWith(sources, '[')) {
|
|
5204
|
-
try {
|
|
5205
|
-
sources = JSON.parse(sources);
|
|
5206
|
-
} catch (e) {
|
|
5207
|
-
sources = [];
|
|
5208
|
-
}
|
|
5209
|
-
} else {
|
|
5210
|
-
sources = parseOptions(sources);
|
|
5211
|
-
}
|
|
5212
|
-
|
|
5213
|
-
if (!isArray(sources)) {
|
|
5214
|
-
sources = [sources];
|
|
5215
|
-
}
|
|
5216
|
-
|
|
5217
|
-
return sources.filter((source) => !isEmpty(source));
|
|
5218
|
-
}
|
|
5219
|
-
|
|
5220
|
-
function ensureSrcAttribute(el) {
|
|
5221
|
-
if (isImg(el) && !hasAttr(el, 'src')) {
|
|
5222
|
-
attr(el, 'src', 'data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg"></svg>');
|
|
5223
|
-
}
|
|
5224
|
-
}
|
|
5225
|
-
|
|
5226
|
-
function isPicture(el) {
|
|
5227
|
-
return isTag(el, 'picture');
|
|
5228
|
-
}
|
|
5229
|
-
|
|
5230
|
-
function isImg(el) {
|
|
5231
|
-
return isTag(el, 'img');
|
|
5232
|
-
}
|
|
5233
|
-
|
|
5234
|
-
var Media = {
|
|
5235
|
-
props: {
|
|
5236
|
-
media: Boolean },
|
|
5237
|
-
|
|
5238
|
-
|
|
5239
|
-
data: {
|
|
5240
|
-
media: false },
|
|
5241
|
-
|
|
5242
|
-
|
|
5243
|
-
connected() {
|
|
5244
|
-
const media = toMedia(this.media);
|
|
5245
|
-
this.matchMedia = true;
|
|
5246
|
-
if (media) {
|
|
5247
|
-
this.mediaObj = window.matchMedia(media);
|
|
5248
|
-
const handler = () => {
|
|
5249
|
-
this.matchMedia = this.mediaObj.matches;
|
|
5250
|
-
trigger(this.$el, createEvent('mediachange', false, true, [this.mediaObj]));
|
|
5251
|
-
};
|
|
5252
|
-
this.offMediaObj = on(this.mediaObj, 'change', () => {
|
|
5253
|
-
handler();
|
|
5254
|
-
this.$emit('resize');
|
|
5255
|
-
});
|
|
5256
|
-
handler();
|
|
5257
|
-
}
|
|
5258
|
-
},
|
|
5259
|
-
|
|
5260
|
-
disconnected() {var _this$offMediaObj;
|
|
5261
|
-
(_this$offMediaObj = this.offMediaObj) == null ? void 0 : _this$offMediaObj.call(this);
|
|
5262
|
-
} };
|
|
5263
|
-
|
|
5264
|
-
|
|
5265
|
-
function toMedia(value) {
|
|
5266
|
-
if (isString(value)) {
|
|
5267
|
-
if (startsWith(value, '@')) {
|
|
5268
|
-
const name = "breakpoint-" + value.substr(1);
|
|
5269
|
-
value = toFloat(getCssVar(name));
|
|
5270
|
-
} else if (isNaN(value)) {
|
|
5271
|
-
return value;
|
|
5272
|
-
}
|
|
5273
|
-
}
|
|
5274
|
-
|
|
5275
|
-
return value && isNumeric(value) ? "(min-width: " + value + "px)" : '';
|
|
5276
|
-
}
|
|
5277
|
-
|
|
5278
|
-
var leader = {
|
|
5279
|
-
mixins: [Class, Media, Resize],
|
|
5280
|
-
|
|
5281
|
-
props: {
|
|
5282
|
-
fill: String },
|
|
5283
|
-
|
|
5284
|
-
|
|
5285
|
-
data: {
|
|
5286
|
-
fill: '',
|
|
5287
|
-
clsWrapper: 'uk-leader-fill',
|
|
5288
|
-
clsHide: 'uk-leader-hide',
|
|
5289
|
-
attrFill: 'data-fill' },
|
|
5290
|
-
|
|
5291
|
-
|
|
5292
|
-
computed: {
|
|
5293
|
-
fill(_ref) {let { fill } = _ref;
|
|
5294
|
-
return fill || getCssVar('leader-fill-content');
|
|
5295
|
-
} },
|
|
5296
|
-
|
|
5297
|
-
|
|
5298
|
-
connected() {
|
|
5299
|
-
[this.wrapper] = wrapInner(this.$el, "<span class=\"" + this.clsWrapper + "\">");
|
|
5300
|
-
},
|
|
5301
|
-
|
|
5302
|
-
disconnected() {
|
|
5303
|
-
unwrap(this.wrapper.childNodes);
|
|
5304
|
-
},
|
|
5305
|
-
|
|
5306
|
-
update: {
|
|
5307
|
-
read() {
|
|
5308
|
-
const width = Math.trunc(this.$el.offsetWidth / 2);
|
|
5309
|
-
|
|
5310
|
-
return {
|
|
5311
|
-
width,
|
|
5312
|
-
fill: this.fill,
|
|
5313
|
-
hide: !this.matchMedia };
|
|
5314
|
-
|
|
5315
|
-
},
|
|
5316
|
-
|
|
5317
|
-
write(_ref2) {let { width, fill, hide } = _ref2;
|
|
5318
|
-
toggleClass(this.wrapper, this.clsHide, hide);
|
|
5319
|
-
attr(this.wrapper, this.attrFill, new Array(width).join(fill));
|
|
5320
|
-
},
|
|
5321
|
-
|
|
5322
|
-
events: ['resize'] } };
|
|
5323
|
-
|
|
5324
|
-
const active = [];
|
|
5325
|
-
|
|
5326
|
-
var Modal = {
|
|
5327
|
-
mixins: [Class, Container, Togglable],
|
|
5328
|
-
|
|
5329
|
-
props: {
|
|
5330
|
-
selPanel: String,
|
|
5331
|
-
selClose: String,
|
|
5332
|
-
escClose: Boolean,
|
|
5333
|
-
bgClose: Boolean,
|
|
5334
|
-
stack: Boolean },
|
|
5335
|
-
|
|
5336
|
-
|
|
5337
|
-
data: {
|
|
5338
|
-
cls: 'uk-open',
|
|
5339
|
-
escClose: true,
|
|
5340
|
-
bgClose: true,
|
|
5341
|
-
overlay: true,
|
|
5342
|
-
stack: false },
|
|
5343
|
-
|
|
5344
|
-
|
|
5345
|
-
computed: {
|
|
5346
|
-
panel(_ref, $el) {let { selPanel } = _ref;
|
|
5347
|
-
return $(selPanel, $el);
|
|
5348
|
-
},
|
|
5349
|
-
|
|
5350
|
-
transitionElement() {
|
|
5351
|
-
return this.panel;
|
|
5352
|
-
},
|
|
5353
|
-
|
|
5354
|
-
bgClose(_ref2) {let { bgClose } = _ref2;
|
|
5355
|
-
return bgClose && this.panel;
|
|
5356
|
-
} },
|
|
5357
|
-
|
|
5358
|
-
|
|
5359
|
-
beforeDisconnect() {
|
|
5360
|
-
if (includes(active, this)) {
|
|
5361
|
-
this.toggleElement(this.$el, false, false);
|
|
5362
|
-
}
|
|
5363
|
-
},
|
|
5364
|
-
|
|
5365
|
-
events: [
|
|
5366
|
-
{
|
|
5367
|
-
name: 'click',
|
|
5368
|
-
|
|
5369
|
-
delegate() {
|
|
5370
|
-
return this.selClose;
|
|
5371
|
-
},
|
|
5372
|
-
|
|
5373
|
-
handler(e) {
|
|
5374
|
-
e.preventDefault();
|
|
5375
|
-
this.hide();
|
|
5376
|
-
} },
|
|
5377
|
-
|
|
5378
|
-
|
|
5379
|
-
{
|
|
5380
|
-
name: 'toggle',
|
|
5381
|
-
|
|
5382
|
-
self: true,
|
|
5383
|
-
|
|
5384
|
-
handler(e) {
|
|
5385
|
-
if (e.defaultPrevented) {
|
|
5386
|
-
return;
|
|
5387
|
-
}
|
|
5388
|
-
|
|
5389
|
-
e.preventDefault();
|
|
5390
|
-
|
|
5391
|
-
if (this.isToggled() === includes(active, this)) {
|
|
5392
|
-
this.toggle();
|
|
5393
|
-
}
|
|
5394
|
-
} },
|
|
5395
|
-
|
|
5396
|
-
|
|
5397
|
-
{
|
|
5398
|
-
name: 'beforeshow',
|
|
5399
|
-
|
|
5400
|
-
self: true,
|
|
5401
|
-
|
|
5402
|
-
handler(e) {
|
|
5403
|
-
if (includes(active, this)) {
|
|
5404
|
-
return false;
|
|
5405
|
-
}
|
|
5406
|
-
|
|
5407
|
-
if (!this.stack && active.length) {
|
|
5408
|
-
Promise.all(active.map((modal) => modal.hide())).then(this.show);
|
|
5409
|
-
e.preventDefault();
|
|
5410
|
-
} else {
|
|
5411
|
-
active.push(this);
|
|
5412
|
-
}
|
|
5413
|
-
} },
|
|
5414
|
-
|
|
5415
|
-
|
|
5416
|
-
{
|
|
5417
|
-
name: 'show',
|
|
5418
|
-
|
|
5419
|
-
self: true,
|
|
5420
|
-
|
|
5421
|
-
handler() {
|
|
5422
|
-
const docEl = document.documentElement;
|
|
5423
|
-
|
|
5424
|
-
if (width(window) > docEl.clientWidth && this.overlay) {
|
|
5425
|
-
css(document.body, 'overflowY', 'scroll');
|
|
5426
|
-
}
|
|
5427
|
-
|
|
5428
|
-
if (this.stack) {
|
|
5429
|
-
css(this.$el, 'zIndex', toFloat(css(this.$el, 'zIndex')) + active.length);
|
|
5430
|
-
}
|
|
5431
|
-
|
|
5432
|
-
addClass(docEl, this.clsPage);
|
|
5433
|
-
|
|
5434
|
-
if (this.bgClose) {
|
|
5435
|
-
once(
|
|
5436
|
-
this.$el,
|
|
5437
|
-
'hide',
|
|
5438
|
-
on(document, pointerDown, (_ref3) => {let { target } = _ref3;
|
|
5439
|
-
if (
|
|
5440
|
-
last(active) !== this ||
|
|
5441
|
-
this.overlay && !within(target, this.$el) ||
|
|
5442
|
-
within(target, this.panel))
|
|
5443
|
-
{
|
|
5444
|
-
return;
|
|
5445
|
-
}
|
|
5446
|
-
|
|
5447
|
-
once(
|
|
5448
|
-
document,
|
|
5449
|
-
pointerUp + " " + pointerCancel + " scroll",
|
|
5450
|
-
(_ref4) => {let { defaultPrevented, type, target: newTarget } = _ref4;
|
|
5451
|
-
if (
|
|
5452
|
-
!defaultPrevented &&
|
|
5453
|
-
type === pointerUp &&
|
|
5454
|
-
target === newTarget)
|
|
5455
|
-
{
|
|
5456
|
-
this.hide();
|
|
5457
|
-
}
|
|
5458
|
-
},
|
|
5459
|
-
true);
|
|
5460
|
-
|
|
5461
|
-
}),
|
|
5462
|
-
{ self: true });
|
|
5547
|
+
}
|
|
5548
|
+
}
|
|
5463
5549
|
|
|
5464
|
-
|
|
5550
|
+
function parseSources(sources) {
|
|
5551
|
+
if (!sources) {
|
|
5552
|
+
return [];
|
|
5553
|
+
}
|
|
5465
5554
|
|
|
5466
|
-
|
|
5467
|
-
|
|
5468
|
-
|
|
5469
|
-
|
|
5470
|
-
|
|
5471
|
-
|
|
5472
|
-
|
|
5473
|
-
|
|
5474
|
-
|
|
5475
|
-
{ self: true });
|
|
5555
|
+
if (startsWith(sources, '[')) {
|
|
5556
|
+
try {
|
|
5557
|
+
sources = JSON.parse(sources);
|
|
5558
|
+
} catch (e) {
|
|
5559
|
+
sources = [];
|
|
5560
|
+
}
|
|
5561
|
+
} else {
|
|
5562
|
+
sources = parseOptions(sources);
|
|
5563
|
+
}
|
|
5476
5564
|
|
|
5477
|
-
|
|
5478
|
-
|
|
5565
|
+
if (!isArray(sources)) {
|
|
5566
|
+
sources = [sources];
|
|
5567
|
+
}
|
|
5479
5568
|
|
|
5569
|
+
return sources.filter((source) => !isEmpty(source));
|
|
5570
|
+
}
|
|
5480
5571
|
|
|
5481
|
-
|
|
5482
|
-
|
|
5572
|
+
function ensureSrcAttribute(el) {
|
|
5573
|
+
if (isImg(el) && !hasAttr(el, 'src')) {
|
|
5574
|
+
attr(el, 'src', 'data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg"></svg>');
|
|
5575
|
+
}
|
|
5576
|
+
}
|
|
5483
5577
|
|
|
5484
|
-
|
|
5578
|
+
function isPicture(el) {
|
|
5579
|
+
return isTag(el, 'picture');
|
|
5580
|
+
}
|
|
5485
5581
|
|
|
5486
|
-
|
|
5487
|
-
|
|
5488
|
-
|
|
5489
|
-
}
|
|
5582
|
+
function isImg(el) {
|
|
5583
|
+
return isTag(el, 'img');
|
|
5584
|
+
}
|
|
5490
5585
|
|
|
5491
|
-
|
|
5492
|
-
|
|
5493
|
-
|
|
5494
|
-
} },
|
|
5586
|
+
var Media = {
|
|
5587
|
+
props: {
|
|
5588
|
+
media: Boolean },
|
|
5495
5589
|
|
|
5496
5590
|
|
|
5497
|
-
{
|
|
5498
|
-
|
|
5591
|
+
data: {
|
|
5592
|
+
media: false },
|
|
5499
5593
|
|
|
5500
|
-
self: true,
|
|
5501
5594
|
|
|
5502
|
-
|
|
5503
|
-
|
|
5504
|
-
|
|
5505
|
-
|
|
5595
|
+
connected() {
|
|
5596
|
+
const media = toMedia(this.media, this.$el);
|
|
5597
|
+
this.matchMedia = true;
|
|
5598
|
+
if (media) {
|
|
5599
|
+
this.mediaObj = window.matchMedia(media);
|
|
5600
|
+
const handler = () => {
|
|
5601
|
+
this.matchMedia = this.mediaObj.matches;
|
|
5602
|
+
trigger(this.$el, createEvent('mediachange', false, true, [this.mediaObj]));
|
|
5603
|
+
};
|
|
5604
|
+
this.offMediaObj = on(this.mediaObj, 'change', () => {
|
|
5605
|
+
handler();
|
|
5606
|
+
this.$emit('resize');
|
|
5607
|
+
});
|
|
5608
|
+
handler();
|
|
5609
|
+
}
|
|
5610
|
+
},
|
|
5506
5611
|
|
|
5507
|
-
|
|
5508
|
-
|
|
5509
|
-
|
|
5612
|
+
disconnected() {var _this$offMediaObj;
|
|
5613
|
+
(_this$offMediaObj = this.offMediaObj) == null ? void 0 : _this$offMediaObj.call(this);
|
|
5614
|
+
} };
|
|
5510
5615
|
|
|
5511
|
-
css(this.$el, 'zIndex', '');
|
|
5512
5616
|
|
|
5513
|
-
|
|
5514
|
-
|
|
5515
|
-
|
|
5516
|
-
|
|
5617
|
+
function toMedia(value, element) {
|
|
5618
|
+
if (isString(value)) {
|
|
5619
|
+
if (startsWith(value, '@')) {
|
|
5620
|
+
value = toFloat(css(element, "--uk-breakpoint-" + value.substr(1)));
|
|
5621
|
+
} else if (isNaN(value)) {
|
|
5622
|
+
return value;
|
|
5623
|
+
}
|
|
5624
|
+
}
|
|
5517
5625
|
|
|
5626
|
+
return value && isNumeric(value) ? "(min-width: " + value + "px)" : '';
|
|
5627
|
+
}
|
|
5518
5628
|
|
|
5629
|
+
var leader = {
|
|
5630
|
+
mixins: [Class, Media, Resize],
|
|
5519
5631
|
|
|
5520
|
-
|
|
5521
|
-
|
|
5522
|
-
return this.isToggled() ? this.hide() : this.show();
|
|
5523
|
-
},
|
|
5632
|
+
props: {
|
|
5633
|
+
fill: String },
|
|
5524
5634
|
|
|
5525
|
-
show() {
|
|
5526
|
-
if (this.container && parent(this.$el) !== this.container) {
|
|
5527
|
-
append(this.container, this.$el);
|
|
5528
|
-
return new Promise((resolve) =>
|
|
5529
|
-
requestAnimationFrame(() => this.show().then(resolve)));
|
|
5530
5635
|
|
|
5531
|
-
|
|
5636
|
+
data: {
|
|
5637
|
+
fill: '',
|
|
5638
|
+
clsWrapper: 'uk-leader-fill',
|
|
5639
|
+
clsHide: 'uk-leader-hide',
|
|
5640
|
+
attrFill: 'data-fill' },
|
|
5532
5641
|
|
|
5533
|
-
return this.toggleElement(this.$el, true, animate(this));
|
|
5534
|
-
},
|
|
5535
5642
|
|
|
5536
|
-
|
|
5537
|
-
|
|
5538
|
-
|
|
5643
|
+
computed: {
|
|
5644
|
+
fill(_ref) {let { fill } = _ref;
|
|
5645
|
+
return fill || css(this.$el, '--uk-leader-fill-content');
|
|
5646
|
+
} },
|
|
5539
5647
|
|
|
5540
5648
|
|
|
5649
|
+
connected() {
|
|
5650
|
+
[this.wrapper] = wrapInner(this.$el, "<span class=\"" + this.clsWrapper + "\">");
|
|
5651
|
+
},
|
|
5541
5652
|
|
|
5542
|
-
|
|
5543
|
-
|
|
5544
|
-
|
|
5545
|
-
once(el, 'show hide', () => {
|
|
5546
|
-
el._reject == null ? void 0 : el._reject();
|
|
5547
|
-
el._reject = reject;
|
|
5653
|
+
disconnected() {
|
|
5654
|
+
unwrap(this.wrapper.childNodes);
|
|
5655
|
+
},
|
|
5548
5656
|
|
|
5549
|
-
|
|
5657
|
+
update: {
|
|
5658
|
+
read() {
|
|
5659
|
+
const width = Math.trunc(this.$el.offsetWidth / 2);
|
|
5550
5660
|
|
|
5551
|
-
|
|
5552
|
-
|
|
5553
|
-
|
|
5554
|
-
|
|
5555
|
-
once(transitionElement, 'transitionend transitioncancel', resolve, {
|
|
5556
|
-
self: true });
|
|
5661
|
+
return {
|
|
5662
|
+
width,
|
|
5663
|
+
fill: this.fill,
|
|
5664
|
+
hide: !this.matchMedia };
|
|
5557
5665
|
|
|
5558
|
-
clearTimeout(timer);
|
|
5559
5666
|
},
|
|
5560
|
-
{ self: true });
|
|
5561
5667
|
|
|
5668
|
+
write(_ref2) {let { width, fill, hide } = _ref2;
|
|
5669
|
+
toggleClass(this.wrapper, this.clsHide, hide);
|
|
5670
|
+
attr(this.wrapper, this.attrFill, new Array(width).join(fill));
|
|
5671
|
+
},
|
|
5562
5672
|
|
|
5563
|
-
|
|
5564
|
-
off();
|
|
5565
|
-
resolve();
|
|
5566
|
-
}, toMs(css(transitionElement, 'transitionDuration')));
|
|
5567
|
-
})).
|
|
5568
|
-
then(() => delete el._reject);
|
|
5569
|
-
}
|
|
5570
|
-
|
|
5571
|
-
function toMs(time) {
|
|
5572
|
-
return time ? endsWith(time, 'ms') ? toFloat(time) : toFloat(time) * 1000 : 0;
|
|
5573
|
-
}
|
|
5673
|
+
events: ['resize'] } };
|
|
5574
5674
|
|
|
5575
5675
|
var modal = {
|
|
5576
5676
|
install: install$2,
|
|
@@ -5734,7 +5834,9 @@
|
|
|
5734
5834
|
align: String,
|
|
5735
5835
|
offset: Number,
|
|
5736
5836
|
boundary: Boolean,
|
|
5737
|
-
|
|
5837
|
+
target: Boolean,
|
|
5838
|
+
targetX: Boolean,
|
|
5839
|
+
targetY: Boolean,
|
|
5738
5840
|
clsDrop: String,
|
|
5739
5841
|
delayShow: Number,
|
|
5740
5842
|
delayHide: Number,
|
|
@@ -5751,9 +5853,12 @@
|
|
|
5751
5853
|
offset: undefined,
|
|
5752
5854
|
delayShow: undefined,
|
|
5753
5855
|
delayHide: undefined,
|
|
5754
|
-
|
|
5755
|
-
|
|
5856
|
+
flip: false,
|
|
5857
|
+
shift: true,
|
|
5756
5858
|
boundary: true,
|
|
5859
|
+
target: false,
|
|
5860
|
+
targetX: false,
|
|
5861
|
+
targetY: false,
|
|
5757
5862
|
dropbar: false,
|
|
5758
5863
|
dropbarAnchor: false,
|
|
5759
5864
|
duration: 200,
|
|
@@ -5788,7 +5893,7 @@
|
|
|
5788
5893
|
},
|
|
5789
5894
|
|
|
5790
5895
|
watch(dropbar) {
|
|
5791
|
-
addClass(dropbar, 'uk-navbar-dropbar');
|
|
5896
|
+
addClass(dropbar, 'uk-dropbar', 'uk-dropbar-top', 'uk-navbar-dropbar');
|
|
5792
5897
|
},
|
|
5793
5898
|
|
|
5794
5899
|
immediate: true },
|
|
@@ -5804,7 +5909,7 @@
|
|
|
5804
5909
|
|
|
5805
5910
|
if (this.dropContainer !== $el) {
|
|
5806
5911
|
for (const el of $$("." + clsDrop, this.dropContainer)) {var _this$getDropdown;
|
|
5807
|
-
const target = (_this$getDropdown = this.getDropdown(el)) == null ? void 0 : _this$getDropdown.
|
|
5912
|
+
const target = (_this$getDropdown = this.getDropdown(el)) == null ? void 0 : _this$getDropdown.targetEl;
|
|
5808
5913
|
if (!includes(dropdowns, el) && target && within(target, this.$el)) {
|
|
5809
5914
|
dropdowns.push(el);
|
|
5810
5915
|
}
|
|
@@ -5821,8 +5926,7 @@
|
|
|
5821
5926
|
{
|
|
5822
5927
|
...this.$props,
|
|
5823
5928
|
boundary: this.boundary,
|
|
5824
|
-
pos: this.pos
|
|
5825
|
-
offset: this.dropbar || this.offset });
|
|
5929
|
+
pos: this.pos });
|
|
5826
5930
|
|
|
5827
5931
|
|
|
5828
5932
|
},
|
|
@@ -5867,8 +5971,8 @@
|
|
|
5867
5971
|
if (
|
|
5868
5972
|
active &&
|
|
5869
5973
|
includes(active.mode, 'hover') &&
|
|
5870
|
-
active.
|
|
5871
|
-
!within(active.
|
|
5974
|
+
active.targetEl &&
|
|
5975
|
+
!within(active.targetEl, current) &&
|
|
5872
5976
|
!active.isDelaying)
|
|
5873
5977
|
{
|
|
5874
5978
|
active.hide(false);
|
|
@@ -5890,7 +5994,7 @@
|
|
|
5890
5994
|
if (keyCode === keyMap.DOWN && hasAttr(current, 'aria-expanded')) {
|
|
5891
5995
|
e.preventDefault();
|
|
5892
5996
|
|
|
5893
|
-
if (!active || active.
|
|
5997
|
+
if (!active || active.targetEl !== current) {
|
|
5894
5998
|
current.click();
|
|
5895
5999
|
once(this.dropContainer, 'show', (_ref8) => {let { target } = _ref8;return (
|
|
5896
6000
|
focusFirstFocusableElement(target));});
|
|
@@ -5940,8 +6044,8 @@
|
|
|
5940
6044
|
}
|
|
5941
6045
|
}
|
|
5942
6046
|
|
|
5943
|
-
if (keyCode === keyMap.ESC) {var _active$
|
|
5944
|
-
active == null ? void 0 : (_active$
|
|
6047
|
+
if (keyCode === keyMap.ESC) {var _active$targetEl;
|
|
6048
|
+
active == null ? void 0 : (_active$targetEl = active.targetEl) == null ? void 0 : _active$targetEl.focus();
|
|
5945
6049
|
}
|
|
5946
6050
|
|
|
5947
6051
|
handleNavItemNavigation(e, this.toggles, active);
|
|
@@ -5983,8 +6087,8 @@
|
|
|
5983
6087
|
return this.dropbar;
|
|
5984
6088
|
},
|
|
5985
6089
|
|
|
5986
|
-
handler(
|
|
5987
|
-
if (!
|
|
6090
|
+
handler(_ref9) {let { target } = _ref9;
|
|
6091
|
+
if (!this.isDropbarDrop(target)) {
|
|
5988
6092
|
return;
|
|
5989
6093
|
}
|
|
5990
6094
|
|
|
@@ -5992,7 +6096,7 @@
|
|
|
5992
6096
|
after(this.dropbarAnchor || this.$el, this.dropbar);
|
|
5993
6097
|
}
|
|
5994
6098
|
|
|
5995
|
-
addClass(
|
|
6099
|
+
addClass(target, this.clsDrop + "-dropbar");
|
|
5996
6100
|
} },
|
|
5997
6101
|
|
|
5998
6102
|
|
|
@@ -6007,19 +6111,24 @@
|
|
|
6007
6111
|
return this.dropbar;
|
|
6008
6112
|
},
|
|
6009
6113
|
|
|
6010
|
-
handler(
|
|
6011
|
-
if (!
|
|
6114
|
+
handler(_ref10) {let { target } = _ref10;
|
|
6115
|
+
if (!this.isDropbarDrop(target)) {
|
|
6012
6116
|
return;
|
|
6013
6117
|
}
|
|
6014
6118
|
|
|
6015
|
-
this._observer = observeResize(
|
|
6016
|
-
|
|
6017
|
-
|
|
6018
|
-
|
|
6019
|
-
|
|
6020
|
-
|
|
6021
|
-
|
|
6119
|
+
this._observer = observeResize(target, () => {
|
|
6120
|
+
const targetOffsets = parents(target, "." + this.clsDrop).
|
|
6121
|
+
concat(target).
|
|
6122
|
+
map((el) => offset(el));
|
|
6123
|
+
const minTop = Math.min(...targetOffsets.map((_ref11) => {let { top } = _ref11;return top;}));
|
|
6124
|
+
const maxBottom = Math.max(...targetOffsets.map((_ref12) => {let { bottom } = _ref12;return bottom;}));
|
|
6125
|
+
const dropbarOffset = offset(this.dropbar);
|
|
6126
|
+
css(this.dropbar, 'top', this.dropbar.offsetTop - (dropbarOffset.top - minTop));
|
|
6127
|
+
this.transitionTo(
|
|
6128
|
+
maxBottom - minTop + toFloat(css(target, 'marginBottom')),
|
|
6129
|
+
target);
|
|
6022
6130
|
|
|
6131
|
+
});
|
|
6023
6132
|
} },
|
|
6024
6133
|
|
|
6025
6134
|
|
|
@@ -6034,13 +6143,13 @@
|
|
|
6034
6143
|
return this.dropbar;
|
|
6035
6144
|
},
|
|
6036
6145
|
|
|
6037
|
-
handler(e
|
|
6146
|
+
handler(e) {
|
|
6038
6147
|
const active = this.getActive();
|
|
6039
6148
|
|
|
6040
6149
|
if (
|
|
6041
6150
|
matches(this.dropbar, ':hover') &&
|
|
6042
|
-
(active == null ? void 0 : active.$el) ===
|
|
6043
|
-
!this.toggles.some((el) => active.
|
|
6151
|
+
(active == null ? void 0 : active.$el) === e.target &&
|
|
6152
|
+
!this.toggles.some((el) => active.targetEl !== el && matches(el, ':focus')))
|
|
6044
6153
|
{
|
|
6045
6154
|
e.preventDefault();
|
|
6046
6155
|
}
|
|
@@ -6058,8 +6167,8 @@
|
|
|
6058
6167
|
return this.dropbar;
|
|
6059
6168
|
},
|
|
6060
6169
|
|
|
6061
|
-
handler(
|
|
6062
|
-
if (!
|
|
6170
|
+
handler(_ref13) {let { target } = _ref13;
|
|
6171
|
+
if (!this.isDropbarDrop(target)) {
|
|
6063
6172
|
return;
|
|
6064
6173
|
}
|
|
6065
6174
|
|
|
@@ -6067,7 +6176,7 @@
|
|
|
6067
6176
|
|
|
6068
6177
|
const active = this.getActive();
|
|
6069
6178
|
|
|
6070
|
-
if (!active || (active == null ? void 0 : active.$el) ===
|
|
6179
|
+
if (!active || (active == null ? void 0 : active.$el) === target) {
|
|
6071
6180
|
this.transitionTo(0);
|
|
6072
6181
|
}
|
|
6073
6182
|
} }],
|
|
@@ -6076,7 +6185,7 @@
|
|
|
6076
6185
|
|
|
6077
6186
|
methods: {
|
|
6078
6187
|
getActive() {
|
|
6079
|
-
return active
|
|
6188
|
+
return active && within(active.targetEl, this.$el) && active;
|
|
6080
6189
|
},
|
|
6081
6190
|
|
|
6082
6191
|
transitionTo(newHeight, el) {
|
|
@@ -6106,13 +6215,17 @@
|
|
|
6106
6215
|
|
|
6107
6216
|
getDropdown(el) {
|
|
6108
6217
|
return this.$getComponent(el, 'drop') || this.$getComponent(el, 'dropdown');
|
|
6218
|
+
},
|
|
6219
|
+
|
|
6220
|
+
isDropbarDrop(el) {
|
|
6221
|
+
return this.getDropdown(el) && hasClass(el, this.clsDrop);
|
|
6109
6222
|
} } };
|
|
6110
6223
|
|
|
6111
6224
|
|
|
6112
6225
|
|
|
6113
6226
|
function handleNavItemNavigation(e, toggles, active) {
|
|
6114
6227
|
const { current, keyCode } = e;
|
|
6115
|
-
const target = (active == null ? void 0 : active.
|
|
6228
|
+
const target = (active == null ? void 0 : active.targetEl) || current;
|
|
6116
6229
|
const i = toggles.indexOf(target);
|
|
6117
6230
|
|
|
6118
6231
|
// Left
|
|
@@ -6169,7 +6282,7 @@
|
|
|
6169
6282
|
|
|
6170
6283
|
registerEvent(this, {
|
|
6171
6284
|
el: this.swipeTarget,
|
|
6172
|
-
name: pointerDown,
|
|
6285
|
+
name: pointerDown$1,
|
|
6173
6286
|
passive: true,
|
|
6174
6287
|
handler(e) {
|
|
6175
6288
|
if (!isTouch(e)) {
|
|
@@ -6179,7 +6292,7 @@
|
|
|
6179
6292
|
// Handle Swipe Gesture
|
|
6180
6293
|
const pos = getEventPos(e);
|
|
6181
6294
|
const target = 'tagName' in e.target ? e.target : parent(e.target);
|
|
6182
|
-
once(document, pointerUp + " " + pointerCancel + " scroll", (e) => {
|
|
6295
|
+
once(document, pointerUp$1 + " " + pointerCancel + " scroll", (e) => {
|
|
6183
6296
|
const { x, y } = getEventPos(e);
|
|
6184
6297
|
|
|
6185
6298
|
// swipe
|
|
@@ -6286,22 +6399,6 @@
|
|
|
6286
6399
|
} },
|
|
6287
6400
|
|
|
6288
6401
|
|
|
6289
|
-
{
|
|
6290
|
-
name: 'touchstart',
|
|
6291
|
-
|
|
6292
|
-
passive: true,
|
|
6293
|
-
|
|
6294
|
-
el() {
|
|
6295
|
-
return this.panel;
|
|
6296
|
-
},
|
|
6297
|
-
|
|
6298
|
-
handler(_ref8) {let { targetTouches } = _ref8;
|
|
6299
|
-
if (targetTouches.length === 1) {
|
|
6300
|
-
this.clientY = targetTouches[0].clientY;
|
|
6301
|
-
}
|
|
6302
|
-
} },
|
|
6303
|
-
|
|
6304
|
-
|
|
6305
6402
|
{
|
|
6306
6403
|
name: 'touchmove',
|
|
6307
6404
|
|
|
@@ -6317,33 +6414,6 @@
|
|
|
6317
6414
|
} },
|
|
6318
6415
|
|
|
6319
6416
|
|
|
6320
|
-
{
|
|
6321
|
-
name: 'touchmove',
|
|
6322
|
-
|
|
6323
|
-
passive: false,
|
|
6324
|
-
|
|
6325
|
-
el() {
|
|
6326
|
-
return this.panel;
|
|
6327
|
-
},
|
|
6328
|
-
|
|
6329
|
-
handler(e) {
|
|
6330
|
-
if (e.targetTouches.length !== 1) {
|
|
6331
|
-
return;
|
|
6332
|
-
}
|
|
6333
|
-
|
|
6334
|
-
const clientY = e.targetTouches[0].clientY - this.clientY;
|
|
6335
|
-
const { scrollTop, scrollHeight, clientHeight } = this.panel;
|
|
6336
|
-
|
|
6337
|
-
if (
|
|
6338
|
-
clientHeight >= scrollHeight ||
|
|
6339
|
-
scrollTop === 0 && clientY > 0 ||
|
|
6340
|
-
scrollHeight - scrollTop <= clientHeight && clientY < 0)
|
|
6341
|
-
{
|
|
6342
|
-
e.cancelable && e.preventDefault();
|
|
6343
|
-
}
|
|
6344
|
-
} },
|
|
6345
|
-
|
|
6346
|
-
|
|
6347
6417
|
{
|
|
6348
6418
|
name: 'show',
|
|
6349
6419
|
|
|
@@ -6355,7 +6425,6 @@
|
|
|
6355
6425
|
addClass(parent(this.panel), this.clsMode);
|
|
6356
6426
|
}
|
|
6357
6427
|
|
|
6358
|
-
css(document.documentElement, 'overflowY', this.overlay ? 'hidden' : '');
|
|
6359
6428
|
addClass(document.body, this.clsContainer, this.clsFlip);
|
|
6360
6429
|
css(document.body, 'touch-action', 'pan-y pinch-zoom');
|
|
6361
6430
|
css(this.$el, 'display', 'block');
|
|
@@ -6363,7 +6432,7 @@
|
|
|
6363
6432
|
addClass(
|
|
6364
6433
|
this.panel,
|
|
6365
6434
|
this.clsSidebarAnimation,
|
|
6366
|
-
this.mode
|
|
6435
|
+
this.mode === 'reveal' ? '' : this.clsMode);
|
|
6367
6436
|
|
|
6368
6437
|
|
|
6369
6438
|
height(document.body); // force reflow
|
|
@@ -6400,8 +6469,6 @@
|
|
|
6400
6469
|
removeClass(this.$el, this.clsOverlay);
|
|
6401
6470
|
css(this.$el, 'display', '');
|
|
6402
6471
|
removeClass(document.body, this.clsContainer, this.clsFlip);
|
|
6403
|
-
|
|
6404
|
-
css(document.documentElement, 'overflowY', '');
|
|
6405
6472
|
} },
|
|
6406
6473
|
|
|
6407
6474
|
|
|
@@ -6526,6 +6593,14 @@
|
|
|
6526
6593
|
offset: 0 },
|
|
6527
6594
|
|
|
6528
6595
|
|
|
6596
|
+
connected() {
|
|
6597
|
+
registerClick(this);
|
|
6598
|
+
},
|
|
6599
|
+
|
|
6600
|
+
disconnected() {
|
|
6601
|
+
unregisterClick(this);
|
|
6602
|
+
},
|
|
6603
|
+
|
|
6529
6604
|
methods: {
|
|
6530
6605
|
async scrollTo(el) {
|
|
6531
6606
|
el = el && $(el) || document.body;
|
|
@@ -6534,20 +6609,39 @@
|
|
|
6534
6609
|
await scrollIntoView(el, { offset: this.offset });
|
|
6535
6610
|
trigger(this.$el, 'scrolled', [this, el]);
|
|
6536
6611
|
}
|
|
6537
|
-
} }
|
|
6612
|
+
} } };
|
|
6538
6613
|
|
|
6539
6614
|
|
|
6540
|
-
events: {
|
|
6541
|
-
click(e) {
|
|
6542
|
-
if (e.defaultPrevented) {
|
|
6543
|
-
return;
|
|
6544
|
-
}
|
|
6545
6615
|
|
|
6546
|
-
|
|
6547
|
-
|
|
6548
|
-
|
|
6616
|
+
const components$2 = new Set();
|
|
6617
|
+
function registerClick(cmp) {
|
|
6618
|
+
if (!components$2.size) {
|
|
6619
|
+
on(document, 'click', clickHandler);
|
|
6620
|
+
}
|
|
6621
|
+
|
|
6622
|
+
components$2.add(cmp);
|
|
6623
|
+
}
|
|
6624
|
+
|
|
6625
|
+
function unregisterClick(cmp) {
|
|
6626
|
+
components$2.delete(cmp);
|
|
6627
|
+
|
|
6628
|
+
if (!components$2.length) {
|
|
6629
|
+
off(document, 'click', clickHandler);
|
|
6630
|
+
}
|
|
6631
|
+
}
|
|
6549
6632
|
|
|
6633
|
+
function clickHandler(e) {
|
|
6634
|
+
if (e.defaultPrevented) {
|
|
6635
|
+
return;
|
|
6636
|
+
}
|
|
6550
6637
|
|
|
6638
|
+
for (const component of components$2) {
|
|
6639
|
+
if (within(e.target, component.$el)) {
|
|
6640
|
+
e.preventDefault();
|
|
6641
|
+
component.scrollTo(getTargetElement(component.$el));
|
|
6642
|
+
}
|
|
6643
|
+
}
|
|
6644
|
+
}
|
|
6551
6645
|
|
|
6552
6646
|
function getTargetElement(el) {
|
|
6553
6647
|
return document.getElementById(decodeURIComponent(el.hash).substring(1));
|
|
@@ -6877,7 +6971,9 @@
|
|
|
6877
6971
|
},
|
|
6878
6972
|
|
|
6879
6973
|
handler() {
|
|
6880
|
-
|
|
6974
|
+
const { scrollingElement } = document;
|
|
6975
|
+
|
|
6976
|
+
if (!location.hash || scrollingElement.scrollTop === 0) {
|
|
6881
6977
|
return;
|
|
6882
6978
|
}
|
|
6883
6979
|
|
|
@@ -6886,13 +6982,11 @@
|
|
|
6886
6982
|
const elOffset = offset(this.$el);
|
|
6887
6983
|
|
|
6888
6984
|
if (this.isFixed && intersectRect(targetOffset, elOffset)) {
|
|
6889
|
-
scrollTop
|
|
6890
|
-
window,
|
|
6985
|
+
scrollingElement.scrollTop =
|
|
6891
6986
|
targetOffset.top -
|
|
6892
6987
|
elOffset.height -
|
|
6893
6988
|
toPx(this.targetOffset, 'height', this.placeholder) -
|
|
6894
|
-
toPx(this.offset, 'height', this.placeholder)
|
|
6895
|
-
|
|
6989
|
+
toPx(this.offset, 'height', this.placeholder);
|
|
6896
6990
|
}
|
|
6897
6991
|
});
|
|
6898
6992
|
} }],
|
|
@@ -6990,7 +7084,7 @@
|
|
|
6990
7084
|
|
|
6991
7085
|
|
|
6992
7086
|
{let { scroll: prevScroll = 0, dir: prevDir = 'down', overflow, overflowScroll = 0, start, end } = _ref4;
|
|
6993
|
-
const scroll = scrollTop
|
|
7087
|
+
const scroll = document.scrollingElement.scrollTop;
|
|
6994
7088
|
const dir = prevScroll <= scroll ? 'down' : 'up';
|
|
6995
7089
|
|
|
6996
7090
|
return {
|
|
@@ -7399,7 +7493,7 @@
|
|
|
7399
7493
|
|
|
7400
7494
|
events: [
|
|
7401
7495
|
{
|
|
7402
|
-
name: pointerDown,
|
|
7496
|
+
name: pointerDown$1,
|
|
7403
7497
|
|
|
7404
7498
|
filter() {
|
|
7405
7499
|
return includes(this.mode, 'hover');
|
|
@@ -7417,7 +7511,7 @@
|
|
|
7417
7511
|
trigger(this.$el, 'focus');
|
|
7418
7512
|
once(
|
|
7419
7513
|
document,
|
|
7420
|
-
pointerDown,
|
|
7514
|
+
pointerDown$1,
|
|
7421
7515
|
() => trigger(this.$el, 'blur'),
|
|
7422
7516
|
true,
|
|
7423
7517
|
(e) => !within(e.target, this.$el));
|
|
@@ -7510,7 +7604,7 @@
|
|
|
7510
7604
|
|
|
7511
7605
|
|
|
7512
7606
|
{
|
|
7513
|
-
name: '
|
|
7607
|
+
name: 'hide show',
|
|
7514
7608
|
|
|
7515
7609
|
self: true,
|
|
7516
7610
|
|
|
@@ -7518,10 +7612,8 @@
|
|
|
7518
7612
|
return this.target;
|
|
7519
7613
|
},
|
|
7520
7614
|
|
|
7521
|
-
handler(
|
|
7522
|
-
|
|
7523
|
-
this.updateAria(toggled);
|
|
7524
|
-
}
|
|
7615
|
+
handler(_ref2) {let { type } = _ref2;
|
|
7616
|
+
this.updateAria(type === 'show');
|
|
7525
7617
|
} },
|
|
7526
7618
|
|
|
7527
7619
|
|
|
@@ -7616,10 +7708,12 @@
|
|
|
7616
7708
|
Video: Video,
|
|
7617
7709
|
Close: Close,
|
|
7618
7710
|
Spinner: Spinner,
|
|
7711
|
+
NavParentIcon: NavParentIcon,
|
|
7619
7712
|
SlidenavNext: Slidenav,
|
|
7620
7713
|
SlidenavPrevious: Slidenav,
|
|
7621
7714
|
SearchIcon: Search,
|
|
7622
7715
|
Marker: IconComponent,
|
|
7716
|
+
NavbarParentIcon: IconComponent,
|
|
7623
7717
|
NavbarToggleIcon: IconComponent,
|
|
7624
7718
|
OverlayIcon: IconComponent,
|
|
7625
7719
|
PaginationNext: IconComponent,
|
|
@@ -8109,7 +8203,7 @@
|
|
|
8109
8203
|
|
|
8110
8204
|
},
|
|
8111
8205
|
|
|
8112
|
-
setState(state, animate) {if (animate === void 0) {animate = true;}
|
|
8206
|
+
async setState(state, animate) {if (animate === void 0) {animate = true;}
|
|
8113
8207
|
state = { filter: { '': '' }, sort: [], ...state };
|
|
8114
8208
|
|
|
8115
8209
|
trigger(this.$el, 'beforeFilter', [this, state]);
|
|
@@ -8118,15 +8212,17 @@
|
|
|
8118
8212
|
toggleClass(el, this.cls, !!matchFilter(el, this.attrItem, state)));
|
|
8119
8213
|
|
|
8120
8214
|
|
|
8121
|
-
Promise.all(
|
|
8215
|
+
await Promise.all(
|
|
8122
8216
|
$$(this.target, this.$el).map((target) => {
|
|
8123
8217
|
const filterFn = () => {
|
|
8124
8218
|
applyState(state, target, children(target));
|
|
8125
8219
|
this.$update(this.$el);
|
|
8126
8220
|
};
|
|
8127
8221
|
return animate ? this.animate(filterFn, target) : filterFn();
|
|
8128
|
-
}))
|
|
8129
|
-
|
|
8222
|
+
}));
|
|
8223
|
+
|
|
8224
|
+
|
|
8225
|
+
trigger(this.$el, 'afterFilter', [this]);
|
|
8130
8226
|
},
|
|
8131
8227
|
|
|
8132
8228
|
updateState() {
|
|
@@ -8416,6 +8512,11 @@
|
|
|
8416
8512
|
this.interval && clearInterval(this.interval);
|
|
8417
8513
|
} } };
|
|
8418
8514
|
|
|
8515
|
+
const pointerOptions = { passive: false, capture: true };
|
|
8516
|
+
const pointerDown = 'touchstart mousedown';
|
|
8517
|
+
const pointerMove = 'touchmove mousemove';
|
|
8518
|
+
const pointerUp = 'touchend touchcancel mouseup click input';
|
|
8519
|
+
|
|
8419
8520
|
var SliderDrag = {
|
|
8420
8521
|
props: {
|
|
8421
8522
|
draggable: Boolean },
|
|
@@ -8468,7 +8569,17 @@
|
|
|
8468
8569
|
|
|
8469
8570
|
handler(e) {
|
|
8470
8571
|
e.preventDefault();
|
|
8471
|
-
} }
|
|
8572
|
+
} },
|
|
8573
|
+
|
|
8574
|
+
|
|
8575
|
+
{
|
|
8576
|
+
// iOS workaround for slider stopping if swiping fast
|
|
8577
|
+
name: pointerMove + " " + pointerUp,
|
|
8578
|
+
el() {
|
|
8579
|
+
return this.list;
|
|
8580
|
+
},
|
|
8581
|
+
handler: noop,
|
|
8582
|
+
...pointerOptions }],
|
|
8472
8583
|
|
|
8473
8584
|
|
|
8474
8585
|
|
|
@@ -8490,10 +8601,10 @@
|
|
|
8490
8601
|
this.prevIndex = this.index;
|
|
8491
8602
|
}
|
|
8492
8603
|
|
|
8493
|
-
on(document, pointerMove, this.move,
|
|
8604
|
+
on(document, pointerMove, this.move, pointerOptions);
|
|
8494
8605
|
|
|
8495
8606
|
// 'input' event is triggered by video controls
|
|
8496
|
-
on(document, pointerUp
|
|
8607
|
+
on(document, pointerUp, this.end, pointerOptions);
|
|
8497
8608
|
|
|
8498
8609
|
css(this.list, 'userSelect', 'none');
|
|
8499
8610
|
},
|
|
@@ -8573,8 +8684,8 @@
|
|
|
8573
8684
|
},
|
|
8574
8685
|
|
|
8575
8686
|
end() {
|
|
8576
|
-
off(document, pointerMove, this.move,
|
|
8577
|
-
off(document, pointerUp
|
|
8687
|
+
off(document, pointerMove, this.move, pointerOptions);
|
|
8688
|
+
off(document, pointerUp, this.end, pointerOptions);
|
|
8578
8689
|
|
|
8579
8690
|
if (this.dragging) {
|
|
8580
8691
|
this.dragging = null;
|
|
@@ -8982,7 +9093,7 @@
|
|
|
8982
9093
|
|
|
8983
9094
|
events: [
|
|
8984
9095
|
{
|
|
8985
|
-
name: pointerMove + " " + pointerDown + " keydown",
|
|
9096
|
+
name: pointerMove$1 + " " + pointerDown$1 + " keydown",
|
|
8986
9097
|
|
|
8987
9098
|
handler: 'showControls' },
|
|
8988
9099
|
|
|
@@ -10637,7 +10748,7 @@
|
|
|
10637
10748
|
},
|
|
10638
10749
|
|
|
10639
10750
|
events: {
|
|
10640
|
-
name: pointerDown,
|
|
10751
|
+
name: pointerDown$1,
|
|
10641
10752
|
passive: false,
|
|
10642
10753
|
handler: 'init' },
|
|
10643
10754
|
|
|
@@ -10767,8 +10878,8 @@
|
|
|
10767
10878
|
this.placeholder = placeholder;
|
|
10768
10879
|
this.origin = { target, index: index(placeholder), ...this.pos };
|
|
10769
10880
|
|
|
10770
|
-
on(document, pointerMove, this.move);
|
|
10771
|
-
on(document, pointerUp, this.end);
|
|
10881
|
+
on(document, pointerMove$1, this.move);
|
|
10882
|
+
on(document, pointerUp$1, this.end);
|
|
10772
10883
|
|
|
10773
10884
|
if (!this.threshold) {
|
|
10774
10885
|
this.start(e);
|
|
@@ -10804,8 +10915,8 @@
|
|
|
10804
10915
|
},
|
|
10805
10916
|
|
|
10806
10917
|
end() {
|
|
10807
|
-
off(document, pointerMove, this.move);
|
|
10808
|
-
off(document, pointerUp, this.end);
|
|
10918
|
+
off(document, pointerMove$1, this.move);
|
|
10919
|
+
off(document, pointerUp$1, this.end);
|
|
10809
10920
|
|
|
10810
10921
|
if (!this.drag) {
|
|
10811
10922
|
return;
|
|
@@ -10874,7 +10985,7 @@
|
|
|
10874
10985
|
let last = Date.now();
|
|
10875
10986
|
trackTimer = setInterval(() => {
|
|
10876
10987
|
let { x, y } = pos;
|
|
10877
|
-
y += scrollTop
|
|
10988
|
+
y += document.scrollingElement.scrollTop;
|
|
10878
10989
|
|
|
10879
10990
|
const dist = (Date.now() - last) * 0.3;
|
|
10880
10991
|
last = Date.now();
|
|
@@ -10895,7 +11006,7 @@
|
|
|
10895
11006
|
}
|
|
10896
11007
|
|
|
10897
11008
|
if (scroll > 0 && scroll < scrollHeight - height) {
|
|
10898
|
-
scrollTop
|
|
11009
|
+
scrollEl.scrollTop = scroll;
|
|
10899
11010
|
return true;
|
|
10900
11011
|
}
|
|
10901
11012
|
});
|
|
@@ -11040,11 +11151,11 @@
|
|
|
11040
11151
|
|
|
11041
11152
|
this._unbind = once(
|
|
11042
11153
|
document, "show keydown " +
|
|
11043
|
-
pointerDown,
|
|
11154
|
+
pointerDown$1,
|
|
11044
11155
|
this.hide,
|
|
11045
11156
|
false,
|
|
11046
11157
|
(e) =>
|
|
11047
|
-
e.type === pointerDown && !within(e.target, this.$el) ||
|
|
11158
|
+
e.type === pointerDown$1 && !within(e.target, this.$el) ||
|
|
11048
11159
|
e.type === 'keydown' && e.keyCode === 27 ||
|
|
11049
11160
|
e.type === 'show' && e.detail[0] !== this && e.detail[0].$name === this.$name);
|
|
11050
11161
|
|
|
@@ -11115,7 +11226,7 @@
|
|
|
11115
11226
|
|
|
11116
11227
|
// Clicking a button does not give it focus on all browsers and platforms
|
|
11117
11228
|
// https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#clicking_and_focus
|
|
11118
|
-
[pointerDown](e) {
|
|
11229
|
+
[pointerDown$1](e) {
|
|
11119
11230
|
if (isTouch(e)) {
|
|
11120
11231
|
this.show();
|
|
11121
11232
|
}
|