uikit 3.14.4-dev.4bd89c5ca → 3.14.4-dev.6923b7e2c
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 +34 -17
- package/dist/css/uikit-core-rtl.css +337 -159
- package/dist/css/uikit-core-rtl.min.css +1 -1
- package/dist/css/uikit-core.css +337 -159
- package/dist/css/uikit-core.min.css +1 -1
- package/dist/css/uikit-rtl.css +357 -163
- package/dist/css/uikit-rtl.min.css +1 -1
- package/dist/css/uikit.css +357 -163
- 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 +1 -1
- package/dist/js/components/filter.min.js +1 -1
- package/dist/js/components/lightbox-panel.js +69 -114
- package/dist/js/components/lightbox-panel.min.js +1 -1
- package/dist/js/components/lightbox.js +69 -114
- 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 +1 -1
- 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 +1 -1
- package/dist/js/components/slideshow.min.js +1 -1
- package/dist/js/components/sortable.js +1 -1
- package/dist/js/components/sortable.min.js +1 -1
- package/dist/js/components/tooltip.js +88 -134
- 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 +366 -361
- 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 +366 -361
- package/dist/js/uikit.min.js +14 -1
- package/package.json +1 -1
- package/src/images/{backgrounds/nav-parent-close.svg → components/nav-parent-icon-large.svg} +0 -0
- package/src/images/{backgrounds/navbar-parent-close.svg → components/nav-parent-icon.svg} +0 -0
- package/src/images/{backgrounds/navbar-parent-open.svg → components/navbar-parent-icon.svg} +1 -1
- package/src/images/components/navbar-toggle-icon.svg +22 -3
- package/src/js/api/state.js +1 -1
- package/src/js/core/accordion.js +9 -17
- package/src/js/core/alert.js +35 -14
- package/src/js/core/drop.js +87 -61
- package/src/js/core/height-viewport.js +4 -2
- 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 +28 -45
- package/src/js/core/scroll.js +37 -10
- package/src/js/mixin/media.js +4 -5
- package/src/js/mixin/position.js +21 -24
- package/src/js/mixin/togglable.js +80 -124
- package/src/js/util/animation.js +4 -3
- package/src/js/util/filter.js +3 -7
- package/src/js/util/position.js +42 -47
- package/src/js/util/style.js +4 -13
- package/src/js/util/viewport.js +3 -5
- 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 +11 -19
- package/src/less/components/leader.less +1 -1
- package/src/less/components/nav.less +218 -59
- package/src/less/components/navbar.less +36 -82
- package/src/less/components/utility.less +10 -2
- 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 +45 -7
- package/src/less/theme/navbar.less +1 -13
- 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 +11 -19
- package/src/scss/components/leader.scss +1 -1
- package/src/scss/components/nav.scss +167 -47
- package/src/scss/components/navbar.scss +36 -70
- package/src/scss/components/utility.scss +8 -1
- package/src/scss/mixins-theme.scss +80 -33
- package/src/scss/mixins.scss +77 -29
- 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 +43 -7
- package/src/scss/theme/navbar.scss +1 -13
- package/src/scss/variables-theme.scss +54 -22
- package/src/scss/variables.scss +43 -20
- package/tests/accordion.html +2 -2
- package/tests/alert.html +2 -2
- package/tests/countdown.html +1 -1
- package/tests/drop.html +442 -412
- package/tests/drop2.html +475 -0
- package/tests/dropbar.html +456 -0
- package/tests/dropdown.html +8 -470
- package/tests/filter.html +9 -12
- package/tests/form.html +1 -1
- package/tests/index.html +126 -107
- 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 +94 -241
- package/tests/offcanvas.html +17 -21
- package/tests/parallax.html +1 -1
- package/tests/position.html +13 -24
- package/tests/progress.html +9 -9
- package/tests/scroll.html +7 -10
- package/tests/search.html +5 -5
- package/tests/slide.html +191 -0
- 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-open.svg +0 -3
package/dist/js/uikit-core.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.14.4-dev.
|
|
1
|
+
/*! UIkit 3.14.4-dev.6923b7e2c | 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) {
|
|
@@ -1899,12 +1886,10 @@
|
|
|
1899
1886
|
function offsetViewport(scrollElement) {
|
|
1900
1887
|
const window = toWindow(scrollElement);
|
|
1901
1888
|
const {
|
|
1902
|
-
document: {
|
|
1889
|
+
document: { documentElement } } =
|
|
1903
1890
|
window;
|
|
1904
1891
|
let viewportElement =
|
|
1905
|
-
scrollElement === scrollingElement(scrollElement)
|
|
1906
|
-
window :
|
|
1907
|
-
scrollElement;
|
|
1892
|
+
scrollElement === scrollingElement(scrollElement) ? window : scrollElement;
|
|
1908
1893
|
|
|
1909
1894
|
const { visualViewport } = window;
|
|
1910
1895
|
if (isWindow(viewportElement) && visualViewport) {
|
|
@@ -1923,7 +1908,7 @@
|
|
|
1923
1908
|
// iOS 12 returns <body> as scrollingElement
|
|
1924
1909
|
viewportElement = documentElement;
|
|
1925
1910
|
} else {
|
|
1926
|
-
rect[start] += toFloat(css(viewportElement, "border" +
|
|
1911
|
+
rect[start] += toFloat(css(viewportElement, "border-" + start + "-width"));
|
|
1927
1912
|
}
|
|
1928
1913
|
rect[prop] = rect[dir] = viewportElement["client" + ucfirst(prop)];
|
|
1929
1914
|
rect[end] = rect[prop] + rect[start];
|
|
@@ -1951,11 +1936,11 @@
|
|
|
1951
1936
|
...options };
|
|
1952
1937
|
|
|
1953
1938
|
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
|
|
1939
|
+
if (!isArray(target)) {
|
|
1940
|
+
target = [target, target];
|
|
1941
|
+
}
|
|
1957
1942
|
|
|
1958
|
-
offset(element,
|
|
1943
|
+
offset(element, getPosition(element, target, options));
|
|
1959
1944
|
}
|
|
1960
1945
|
|
|
1961
1946
|
function attachTo(element, target, options) {
|
|
@@ -1970,8 +1955,11 @@
|
|
|
1970
1955
|
|
|
1971
1956
|
|
|
1972
1957
|
const position = offset(element);
|
|
1973
|
-
|
|
1958
|
+
|
|
1974
1959
|
for (const [i, [prop, dir, start, end]] of Object.entries(dirs)) {
|
|
1960
|
+
const targetOffset =
|
|
1961
|
+
attach.target[i] === attach.element[i] ? offsetViewport(target[i]) : offset(target[i]);
|
|
1962
|
+
|
|
1975
1963
|
position[start] = position[dir] =
|
|
1976
1964
|
targetOffset[start] +
|
|
1977
1965
|
moveBy(attach.target[i], end, targetOffset[prop]) -
|
|
@@ -1986,60 +1974,54 @@
|
|
|
1986
1974
|
return start === 'center' ? dim / 2 : start === end ? dim : 0;
|
|
1987
1975
|
}
|
|
1988
1976
|
|
|
1989
|
-
function
|
|
1977
|
+
function getPosition(element, target, options) {
|
|
1990
1978
|
const position = attachTo(element, target, options);
|
|
1991
|
-
const targetDim = offset(target);
|
|
1992
1979
|
|
|
1993
1980
|
let {
|
|
1994
1981
|
flip,
|
|
1982
|
+
shift,
|
|
1995
1983
|
attach: { element: elAttach, target: targetAttach },
|
|
1996
1984
|
offset: elOffset,
|
|
1997
1985
|
boundary,
|
|
1998
|
-
viewport,
|
|
1999
1986
|
viewportOffset } =
|
|
2000
1987
|
options;
|
|
2001
1988
|
|
|
2002
|
-
|
|
2003
|
-
|
|
2004
|
-
viewports = viewports.filter((viewport) => viewport !== boundary);
|
|
1989
|
+
if (!flip && !shift) {
|
|
1990
|
+
return position;
|
|
2005
1991
|
}
|
|
2006
|
-
const [scrollElement] = viewports;
|
|
2007
|
-
viewports.push(viewport);
|
|
2008
1992
|
|
|
2009
1993
|
const offsetPosition = { ...position };
|
|
2010
1994
|
for (const [i, [prop, dir, start, end]] of Object.entries(dirs)) {
|
|
2011
|
-
|
|
2012
|
-
|
|
2013
|
-
}
|
|
1995
|
+
let viewports = scrollParents(target[i]);
|
|
1996
|
+
const [scrollElement] = viewports;
|
|
2014
1997
|
|
|
2015
|
-
|
|
2016
|
-
!intersectLine(position, targetDim, i) && intersectLine(position, targetDim, 1 - i);
|
|
2017
|
-
|
|
2018
|
-
viewport = getIntersectionArea(...viewports.filter(Boolean).map(offsetViewport));
|
|
1998
|
+
let viewport = getIntersectionArea(...viewports.map(offsetViewport));
|
|
2019
1999
|
|
|
2020
2000
|
if (viewportOffset) {
|
|
2021
2001
|
viewport[start] += viewportOffset;
|
|
2022
2002
|
viewport[end] -= viewportOffset;
|
|
2023
2003
|
}
|
|
2024
2004
|
|
|
2025
|
-
if (boundary
|
|
2026
|
-
viewport = getIntersectionArea(viewport,
|
|
2005
|
+
if (boundary) {
|
|
2006
|
+
viewport = getIntersectionArea(viewport, offsetViewport(boundary));
|
|
2027
2007
|
}
|
|
2028
2008
|
|
|
2029
|
-
const
|
|
2030
|
-
const
|
|
2009
|
+
const isInStartViewport = position[start] >= viewport[start];
|
|
2010
|
+
const isInEndViewport = position[end] <= viewport[end];
|
|
2031
2011
|
|
|
2032
|
-
if (
|
|
2012
|
+
if (isInStartViewport && isInEndViewport) {
|
|
2033
2013
|
continue;
|
|
2034
2014
|
}
|
|
2035
2015
|
|
|
2036
|
-
let offsetBy;
|
|
2016
|
+
let offsetBy = 0;
|
|
2017
|
+
const targetDim = offset(target[i]);
|
|
2037
2018
|
|
|
2038
2019
|
// Flip
|
|
2039
|
-
if (
|
|
2020
|
+
if (!intersectLine(position, targetDim, i) && intersectLine(position, targetDim, 1 - i)) {
|
|
2040
2021
|
if (
|
|
2041
|
-
|
|
2042
|
-
elAttach[i] ===
|
|
2022
|
+
!flip ||
|
|
2023
|
+
elAttach[i] === end && isInStartViewport ||
|
|
2024
|
+
elAttach[i] === start && isInEndViewport)
|
|
2043
2025
|
{
|
|
2044
2026
|
continue;
|
|
2045
2027
|
}
|
|
@@ -2076,27 +2058,25 @@
|
|
|
2076
2058
|
return false;
|
|
2077
2059
|
}
|
|
2078
2060
|
|
|
2079
|
-
|
|
2080
|
-
|
|
2081
|
-
|
|
2082
|
-
|
|
2083
|
-
|
|
2084
|
-
target: targetAttach.map(flipDir).reverse() },
|
|
2061
|
+
const newPos = getPosition(element, target, {
|
|
2062
|
+
...options,
|
|
2063
|
+
attach: {
|
|
2064
|
+
element: elAttach.map(flipDir).reverse(),
|
|
2065
|
+
target: targetAttach.map(flipDir).reverse() },
|
|
2085
2066
|
|
|
2086
|
-
|
|
2087
|
-
|
|
2088
|
-
recursion: true });
|
|
2067
|
+
offset: elOffset.reverse(),
|
|
2068
|
+
recursion: true });
|
|
2089
2069
|
|
|
2090
2070
|
|
|
2091
|
-
|
|
2092
|
-
|
|
2093
|
-
}
|
|
2071
|
+
if (newPos && isInScrollArea(newPos, scrollElement, 1 - i)) {
|
|
2072
|
+
return newPos;
|
|
2094
2073
|
}
|
|
2074
|
+
|
|
2095
2075
|
continue;
|
|
2096
2076
|
}
|
|
2097
2077
|
|
|
2098
|
-
//
|
|
2099
|
-
} else {
|
|
2078
|
+
// Shift
|
|
2079
|
+
} else if (shift) {
|
|
2100
2080
|
offsetBy =
|
|
2101
2081
|
clamp(
|
|
2102
2082
|
clamp(position[start], viewport[start], viewport[end] - position[prop]),
|
|
@@ -2152,7 +2132,7 @@
|
|
|
2152
2132
|
getImage: getImage,
|
|
2153
2133
|
transition: transition,
|
|
2154
2134
|
Transition: Transition,
|
|
2155
|
-
animate: animate$
|
|
2135
|
+
animate: animate$2,
|
|
2156
2136
|
Animation: Animation,
|
|
2157
2137
|
attr: attr,
|
|
2158
2138
|
hasAttr: hasAttr,
|
|
@@ -2282,7 +2262,6 @@
|
|
|
2282
2262
|
findAll: findAll,
|
|
2283
2263
|
escape: escape,
|
|
2284
2264
|
css: css,
|
|
2285
|
-
getCssVar: getCssVar,
|
|
2286
2265
|
propName: propName,
|
|
2287
2266
|
isInView: isInView,
|
|
2288
2267
|
scrollIntoView: scrollIntoView,
|
|
@@ -2607,7 +2586,7 @@
|
|
|
2607
2586
|
|
|
2608
2587
|
value = props[key] === Boolean && value === '' ? true : coerce$1(props[key], value);
|
|
2609
2588
|
|
|
2610
|
-
if (prop === 'target' &&
|
|
2589
|
+
if (prop === 'target' && startsWith(value, '_')) {
|
|
2611
2590
|
continue;
|
|
2612
2591
|
}
|
|
2613
2592
|
|
|
@@ -2947,7 +2926,7 @@
|
|
|
2947
2926
|
UIkit.data = '__uikit__';
|
|
2948
2927
|
UIkit.prefix = 'uk-';
|
|
2949
2928
|
UIkit.options = {};
|
|
2950
|
-
UIkit.version = '3.14.4-dev.
|
|
2929
|
+
UIkit.version = '3.14.4-dev.6923b7e2c';
|
|
2951
2930
|
|
|
2952
2931
|
globalAPI(UIkit);
|
|
2953
2932
|
hooksAPI(UIkit);
|
|
@@ -3052,27 +3031,7 @@
|
|
|
3052
3031
|
origin: false,
|
|
3053
3032
|
transition: 'ease',
|
|
3054
3033
|
clsEnter: 'uk-togglabe-enter',
|
|
3055
|
-
clsLeave: 'uk-togglabe-leave',
|
|
3056
|
-
|
|
3057
|
-
initProps: {
|
|
3058
|
-
overflow: '',
|
|
3059
|
-
maxHeight: '',
|
|
3060
|
-
paddingTop: '',
|
|
3061
|
-
paddingBottom: '',
|
|
3062
|
-
marginTop: '',
|
|
3063
|
-
marginBottom: '',
|
|
3064
|
-
boxShadow: '' },
|
|
3065
|
-
|
|
3066
|
-
|
|
3067
|
-
hideProps: {
|
|
3068
|
-
overflow: 'hidden',
|
|
3069
|
-
maxHeight: 0,
|
|
3070
|
-
paddingTop: 0,
|
|
3071
|
-
paddingBottom: 0,
|
|
3072
|
-
marginTop: 0,
|
|
3073
|
-
marginBottom: 0,
|
|
3074
|
-
boxShadow: 'none' } },
|
|
3075
|
-
|
|
3034
|
+
clsLeave: 'uk-togglabe-leave' },
|
|
3076
3035
|
|
|
3077
3036
|
|
|
3078
3037
|
computed: {
|
|
@@ -3081,7 +3040,7 @@
|
|
|
3081
3040
|
},
|
|
3082
3041
|
|
|
3083
3042
|
hasTransition(_ref2) {let { animation } = _ref2;
|
|
3084
|
-
return startsWith(animation[0],
|
|
3043
|
+
return ['slide', 'reveal'].some((transition) => startsWith(animation[0], transition));
|
|
3085
3044
|
} },
|
|
3086
3045
|
|
|
3087
3046
|
|
|
@@ -3174,122 +3133,97 @@
|
|
|
3174
3133
|
};
|
|
3175
3134
|
}
|
|
3176
3135
|
|
|
3177
|
-
function toggleTransition(cmp) {
|
|
3178
|
-
|
|
3179
|
-
case 'slide-left':
|
|
3180
|
-
return slideHorizontal(cmp);
|
|
3181
|
-
case 'slide-right':
|
|
3182
|
-
return slideHorizontal(cmp, true);}
|
|
3183
|
-
|
|
3184
|
-
return slide(cmp);
|
|
3185
|
-
}
|
|
3186
|
-
|
|
3187
|
-
function slide(_ref4)
|
|
3188
|
-
|
|
3136
|
+
function toggleTransition(cmp) {var _cmp$animation$;
|
|
3137
|
+
const [mode = 'reveal', startProp = 'top'] = ((_cmp$animation$ = cmp.animation[0]) == null ? void 0 : _cmp$animation$.split('-')) || [];
|
|
3189
3138
|
|
|
3139
|
+
const dirs = [
|
|
3140
|
+
['left', 'right'],
|
|
3141
|
+
['top', 'bottom']];
|
|
3190
3142
|
|
|
3143
|
+
const dir = dirs[includes(dirs[0], startProp) ? 0 : 1];
|
|
3144
|
+
const end = dir[1] === startProp;
|
|
3145
|
+
const props = ['width', 'height'];
|
|
3146
|
+
const dimProp = props[dirs.indexOf(dir)];
|
|
3147
|
+
const marginProp = "margin-" + dir[0];
|
|
3148
|
+
const marginStartProp = "margin-" + startProp;
|
|
3191
3149
|
|
|
3150
|
+
return async (el, show) => {
|
|
3151
|
+
let { duration, velocity, transition, _toggle } = cmp;
|
|
3192
3152
|
|
|
3153
|
+
let currentDim = dimensions(el)[dimProp];
|
|
3193
3154
|
|
|
3194
|
-
|
|
3195
|
-
{let { isToggled, duration, velocity, initProps, hideProps, transition, _toggle } = _ref4;
|
|
3196
|
-
return (el, show) => {
|
|
3197
3155
|
const inProgress = Transition.inProgress(el);
|
|
3198
|
-
|
|
3199
|
-
!inProgress && el.hasChildNodes() ?
|
|
3200
|
-
toFloat(css(el.firstElementChild, 'marginTop')) +
|
|
3201
|
-
toFloat(css(el.lastElementChild, 'marginBottom')) :
|
|
3202
|
-
0;
|
|
3203
|
-
const currentHeight = isVisible(el) ? toFloat(css(el, 'height')) + inner : 0;
|
|
3204
|
-
|
|
3205
|
-
const props = inProgress ? css(el, Object.keys(initProps)) : show ? hideProps : initProps;
|
|
3156
|
+
await Transition.cancel(el);
|
|
3206
3157
|
|
|
3207
|
-
|
|
3208
|
-
|
|
3209
|
-
if (!isToggled(el)) {
|
|
3158
|
+
if (show) {
|
|
3210
3159
|
_toggle(el, true);
|
|
3211
3160
|
}
|
|
3212
3161
|
|
|
3213
|
-
|
|
3162
|
+
const prevProps = Object.fromEntries(
|
|
3163
|
+
['padding', 'border', 'width', 'height', 'overflow', marginProp, marginStartProp].map(
|
|
3164
|
+
(key) => [key, el.style[key]]));
|
|
3214
3165
|
|
|
3215
|
-
// Update child components first
|
|
3216
|
-
fastdom.flush();
|
|
3217
3166
|
|
|
3218
|
-
const endHeight = toFloat(css(el, 'height')) + inner;
|
|
3219
|
-
duration = velocity * endHeight + duration;
|
|
3220
3167
|
|
|
3221
|
-
|
|
3222
|
-
|
|
3223
|
-
|
|
3224
|
-
|
|
3225
|
-
Transition.start(
|
|
3226
|
-
el,
|
|
3227
|
-
{ ...initProps, overflow: 'hidden', maxHeight: endHeight },
|
|
3228
|
-
duration * (1 - currentHeight / endHeight),
|
|
3229
|
-
transition) :
|
|
3230
|
-
|
|
3231
|
-
Transition.start(
|
|
3232
|
-
el,
|
|
3233
|
-
hideProps,
|
|
3234
|
-
duration * (currentHeight / endHeight),
|
|
3235
|
-
transition).
|
|
3236
|
-
then(() => _toggle(el, false))).
|
|
3237
|
-
then(() => css(el, initProps));
|
|
3238
|
-
};
|
|
3239
|
-
}
|
|
3240
|
-
|
|
3241
|
-
function slideHorizontal(_ref5, right) {let { isToggled, duration, velocity, transition, _toggle } = _ref5;
|
|
3242
|
-
return (el, show) => {
|
|
3243
|
-
const visible = isVisible(el);
|
|
3244
|
-
const marginLeft = toFloat(css(el, 'marginLeft'));
|
|
3245
|
-
|
|
3246
|
-
Transition.cancel(el);
|
|
3168
|
+
const dim = dimensions(el);
|
|
3169
|
+
const currentMargin = toFloat(css(el, marginProp));
|
|
3170
|
+
const marginStart = toFloat(css(el, marginStartProp));
|
|
3171
|
+
const endDim = dim[dimProp] + marginStart;
|
|
3247
3172
|
|
|
3248
|
-
|
|
3249
|
-
|
|
3250
|
-
|
|
3251
|
-
if (!isToggled(el)) {
|
|
3252
|
-
_toggle(el, true);
|
|
3173
|
+
if (!inProgress && !show) {
|
|
3174
|
+
currentDim += marginStart;
|
|
3253
3175
|
}
|
|
3254
3176
|
|
|
3255
|
-
const
|
|
3256
|
-
|
|
3177
|
+
const [wrapper] = wrapInner(el, '<div>');
|
|
3178
|
+
css(wrapper, {
|
|
3179
|
+
boxSizing: 'border-box',
|
|
3180
|
+
height: dim.height,
|
|
3181
|
+
width: dim.width,
|
|
3182
|
+
...css(el, [
|
|
3183
|
+
'padding',
|
|
3184
|
+
'borderTop',
|
|
3185
|
+
'borderRight',
|
|
3186
|
+
'borderBottom',
|
|
3187
|
+
'borderLeft',
|
|
3188
|
+
'borderImage',
|
|
3189
|
+
marginStartProp]) });
|
|
3257
3190
|
|
|
3258
|
-
const percent = visible ? (width + marginLeft * (right ? -1 : 1)) / width * 100 : 0;
|
|
3259
3191
|
|
|
3260
|
-
css(el, {
|
|
3261
|
-
clipPath: right ? "polygon(0 0," +
|
|
3262
|
-
percent + "% 0," + percent + "% 100%,0 100%)" : "polygon(" + (
|
|
3263
|
-
100 - percent) + "% 0,100% 0,100% 100%," + (100 - percent) + "% 100%)",
|
|
3264
|
-
marginLeft: (100 - percent) * (right ? 1 : -1) / 100 * width });
|
|
3265
3192
|
|
|
3193
|
+
css(el, {
|
|
3194
|
+
padding: 0,
|
|
3195
|
+
border: 0,
|
|
3196
|
+
[marginStartProp]: 0,
|
|
3197
|
+
width: dim.width,
|
|
3198
|
+
height: dim.height,
|
|
3199
|
+
overflow: 'hidden',
|
|
3200
|
+
[dimProp]: currentDim });
|
|
3266
3201
|
|
|
3267
|
-
return (
|
|
3268
|
-
show ?
|
|
3269
|
-
Transition.start(
|
|
3270
|
-
el,
|
|
3271
|
-
{
|
|
3272
|
-
clipPath: "polygon(0 0,100% 0,100% 100%,0 100%)",
|
|
3273
|
-
marginLeft: 0 },
|
|
3274
3202
|
|
|
3275
|
-
|
|
3276
|
-
|
|
3203
|
+
const percent = currentDim / endDim;
|
|
3204
|
+
duration = (velocity * endDim + duration) * (show ? 1 - percent : percent);
|
|
3205
|
+
const endProps = { [dimProp]: show ? endDim : 0 };
|
|
3277
3206
|
|
|
3278
|
-
|
|
3279
|
-
|
|
3280
|
-
|
|
3281
|
-
|
|
3207
|
+
if (end) {
|
|
3208
|
+
css(el, marginProp, endDim - currentDim + currentMargin);
|
|
3209
|
+
endProps[marginProp] = show ? currentMargin : endDim + currentMargin;
|
|
3210
|
+
}
|
|
3282
3211
|
|
|
3212
|
+
if (!end ^ mode === 'reveal') {
|
|
3213
|
+
css(wrapper, marginProp, -endDim + currentDim);
|
|
3214
|
+
Transition.start(wrapper, { [marginProp]: show ? 0 : -endDim }, duration, transition);
|
|
3215
|
+
}
|
|
3283
3216
|
|
|
3284
|
-
|
|
3217
|
+
try {
|
|
3218
|
+
await Transition.start(el, endProps, duration, transition);
|
|
3219
|
+
} finally {
|
|
3220
|
+
css(el, prevProps);
|
|
3221
|
+
unwrap(wrapper.firstChild);
|
|
3285
3222
|
|
|
3286
|
-
|
|
3287
|
-
|
|
3288
|
-
|
|
3289
|
-
|
|
3290
|
-
css(scrollElement, 'overflowX', '');
|
|
3291
|
-
css(el, { clipPath: '', marginLeft: '' });
|
|
3292
|
-
});
|
|
3223
|
+
if (!show) {
|
|
3224
|
+
_toggle(el, false);
|
|
3225
|
+
}
|
|
3226
|
+
}
|
|
3293
3227
|
};
|
|
3294
3228
|
}
|
|
3295
3229
|
|
|
@@ -3314,6 +3248,7 @@
|
|
|
3314
3248
|
mixins: [Class, Lazyload, Togglable],
|
|
3315
3249
|
|
|
3316
3250
|
props: {
|
|
3251
|
+
animation: Boolean,
|
|
3317
3252
|
targets: String,
|
|
3318
3253
|
active: null,
|
|
3319
3254
|
collapsible: Boolean,
|
|
@@ -3326,7 +3261,7 @@
|
|
|
3326
3261
|
data: {
|
|
3327
3262
|
targets: '> *',
|
|
3328
3263
|
active: false,
|
|
3329
|
-
animation:
|
|
3264
|
+
animation: true,
|
|
3330
3265
|
collapsible: true,
|
|
3331
3266
|
multiple: false,
|
|
3332
3267
|
clsOpen: 'uk-open',
|
|
@@ -3372,7 +3307,7 @@
|
|
|
3372
3307
|
hide(
|
|
3373
3308
|
el,
|
|
3374
3309
|
!hasClass(
|
|
3375
|
-
this.items.find((item) =>
|
|
3310
|
+
this.items.find((item) => within(el, item)),
|
|
3376
3311
|
this.clsOpen));
|
|
3377
3312
|
|
|
3378
3313
|
|
|
@@ -3424,23 +3359,15 @@
|
|
|
3424
3359
|
toggleClass(el, this.clsOpen, show);
|
|
3425
3360
|
attr($(this.$props.toggle, el), 'aria-expanded', show);
|
|
3426
3361
|
|
|
3427
|
-
const content = $(
|
|
3362
|
+
const content = $(this.content, el);
|
|
3428
3363
|
|
|
3429
|
-
if (animate === false || !this.
|
|
3364
|
+
if (animate === false || !this.animation) {
|
|
3365
|
+
content.hidden = !show;
|
|
3430
3366
|
hide(content, !show);
|
|
3431
3367
|
return;
|
|
3432
3368
|
}
|
|
3433
3369
|
|
|
3434
|
-
|
|
3435
|
-
el._wrapper = wrapAll(content, "<div" + (show ? ' hidden' : '') + ">");
|
|
3436
|
-
}
|
|
3437
|
-
|
|
3438
|
-
hide(content, false);
|
|
3439
|
-
await slide(this)(el._wrapper, show);
|
|
3440
|
-
hide(content, !show);
|
|
3441
|
-
|
|
3442
|
-
delete el._wrapper;
|
|
3443
|
-
unwrap(content);
|
|
3370
|
+
await toggleTransition(this)(content, show);
|
|
3444
3371
|
|
|
3445
3372
|
if (show) {
|
|
3446
3373
|
const toggle = $(this.$props.toggle, el);
|
|
@@ -3466,18 +3393,17 @@
|
|
|
3466
3393
|
args: 'animation',
|
|
3467
3394
|
|
|
3468
3395
|
props: {
|
|
3396
|
+
animation: Boolean,
|
|
3469
3397
|
close: String },
|
|
3470
3398
|
|
|
3471
3399
|
|
|
3472
3400
|
data: {
|
|
3473
|
-
animation:
|
|
3401
|
+
animation: true,
|
|
3474
3402
|
selClose: '.uk-alert-close',
|
|
3475
|
-
duration: 150,
|
|
3476
|
-
hideProps: { opacity: 0, ...Togglable.data.hideProps } },
|
|
3403
|
+
duration: 150 },
|
|
3477
3404
|
|
|
3478
3405
|
|
|
3479
|
-
events:
|
|
3480
|
-
{
|
|
3406
|
+
events: {
|
|
3481
3407
|
name: 'click',
|
|
3482
3408
|
|
|
3483
3409
|
delegate() {
|
|
@@ -3487,16 +3413,39 @@
|
|
|
3487
3413
|
handler(e) {
|
|
3488
3414
|
e.preventDefault();
|
|
3489
3415
|
this.close();
|
|
3490
|
-
} }
|
|
3491
|
-
|
|
3416
|
+
} },
|
|
3492
3417
|
|
|
3493
3418
|
|
|
3494
3419
|
methods: {
|
|
3495
3420
|
async close() {
|
|
3496
|
-
await this.toggleElement(this.$el);
|
|
3421
|
+
await this.toggleElement(this.$el, false, animate$1(this));
|
|
3497
3422
|
this.$destroy(true);
|
|
3498
3423
|
} } };
|
|
3499
3424
|
|
|
3425
|
+
|
|
3426
|
+
|
|
3427
|
+
function animate$1(_ref) {let { duration, transition, velocity } = _ref;
|
|
3428
|
+
return (el) => {
|
|
3429
|
+
const height = toFloat(css(el, 'height'));
|
|
3430
|
+
css(el, 'height', height);
|
|
3431
|
+
return Transition.start(
|
|
3432
|
+
el,
|
|
3433
|
+
{
|
|
3434
|
+
height: 0,
|
|
3435
|
+
marginTop: 0,
|
|
3436
|
+
marginBottom: 0,
|
|
3437
|
+
paddingTop: 0,
|
|
3438
|
+
paddingBottom: 0,
|
|
3439
|
+
borderTop: 0,
|
|
3440
|
+
borderBottom: 0,
|
|
3441
|
+
opacity: 0 },
|
|
3442
|
+
|
|
3443
|
+
velocity * height + duration,
|
|
3444
|
+
transition);
|
|
3445
|
+
|
|
3446
|
+
};
|
|
3447
|
+
}
|
|
3448
|
+
|
|
3500
3449
|
var Video = {
|
|
3501
3450
|
args: 'autoplay',
|
|
3502
3451
|
|
|
@@ -3645,13 +3594,17 @@
|
|
|
3645
3594
|
props: {
|
|
3646
3595
|
pos: String,
|
|
3647
3596
|
offset: null,
|
|
3648
|
-
flip: Boolean
|
|
3597
|
+
flip: Boolean,
|
|
3598
|
+
shift: Boolean,
|
|
3599
|
+
inset: Boolean },
|
|
3649
3600
|
|
|
3650
3601
|
|
|
3651
3602
|
data: {
|
|
3652
3603
|
pos: "bottom-" + (isRtl ? 'right' : 'left'),
|
|
3604
|
+
offset: false,
|
|
3653
3605
|
flip: true,
|
|
3654
|
-
|
|
3606
|
+
shift: true,
|
|
3607
|
+
inset: false },
|
|
3655
3608
|
|
|
3656
3609
|
|
|
3657
3610
|
connected() {
|
|
@@ -3665,7 +3618,7 @@
|
|
|
3665
3618
|
let offset = [this.getPositionOffset(element), this.getShiftOffset(element)];
|
|
3666
3619
|
|
|
3667
3620
|
const attach = {
|
|
3668
|
-
element: [flipPosition(this.dir), this.align],
|
|
3621
|
+
element: [this.inset ? this.dir : flipPosition(this.dir), this.align],
|
|
3669
3622
|
target: [this.dir, this.align] };
|
|
3670
3623
|
|
|
3671
3624
|
|
|
@@ -3683,21 +3636,14 @@
|
|
|
3683
3636
|
const elDim = dimensions(element);
|
|
3684
3637
|
css(element, { top: -elDim.height, left: -elDim.width });
|
|
3685
3638
|
|
|
3686
|
-
|
|
3687
|
-
element,
|
|
3688
|
-
target,
|
|
3689
|
-
{
|
|
3639
|
+
positionAt(element, target, {
|
|
3690
3640
|
attach,
|
|
3691
3641
|
offset,
|
|
3692
3642
|
boundary,
|
|
3693
3643
|
flip: this.flip,
|
|
3694
|
-
|
|
3695
|
-
|
|
3696
|
-
|
|
3644
|
+
shift: this.shift,
|
|
3645
|
+
viewportOffset: this.getViewportOffset(element) });
|
|
3697
3646
|
|
|
3698
|
-
trigger(element, 'beforeposition', args);
|
|
3699
|
-
|
|
3700
|
-
positionAt(...args);
|
|
3701
3647
|
|
|
3702
3648
|
// Restore scroll position
|
|
3703
3649
|
scrollElement.scrollTop = scrollTop;
|
|
@@ -3707,25 +3653,27 @@
|
|
|
3707
3653
|
getPositionOffset(element) {
|
|
3708
3654
|
return (
|
|
3709
3655
|
toPx(
|
|
3710
|
-
this.offset === false ?
|
|
3656
|
+
this.offset === false ? css(element, '--uk-position-offset') : this.offset,
|
|
3711
3657
|
this.axis === 'x' ? 'width' : 'height',
|
|
3712
3658
|
element) * (
|
|
3713
|
-
|
|
3659
|
+
|
|
3660
|
+
includes(['left', 'top'], this.dir) ? -1 : 1) * (
|
|
3661
|
+
this.inset ? -1 : 1));
|
|
3714
3662
|
|
|
3715
3663
|
},
|
|
3716
3664
|
|
|
3717
3665
|
getShiftOffset(element) {
|
|
3718
|
-
return
|
|
3666
|
+
return this.align === 'center' ?
|
|
3719
3667
|
0 :
|
|
3720
3668
|
toPx(
|
|
3721
|
-
|
|
3669
|
+
css(element, '--uk-position-shift-offset'),
|
|
3722
3670
|
this.axis === 'y' ? 'width' : 'height',
|
|
3723
3671
|
element) * (
|
|
3724
3672
|
includes(['left', 'top'], this.align) ? 1 : -1);
|
|
3725
3673
|
},
|
|
3726
3674
|
|
|
3727
3675
|
getViewportOffset(element) {
|
|
3728
|
-
return toPx(
|
|
3676
|
+
return toPx(css(element, '--uk-position-viewport-offset'));
|
|
3729
3677
|
} } };
|
|
3730
3678
|
|
|
3731
3679
|
const active$1 = [];
|
|
@@ -4074,7 +4022,10 @@
|
|
|
4074
4022
|
mode: 'list',
|
|
4075
4023
|
toggle: Boolean,
|
|
4076
4024
|
boundary: Boolean,
|
|
4077
|
-
|
|
4025
|
+
target: Boolean,
|
|
4026
|
+
targetX: Boolean,
|
|
4027
|
+
targetY: Boolean,
|
|
4028
|
+
stretch: Boolean,
|
|
4078
4029
|
delayShow: Number,
|
|
4079
4030
|
delayHide: Number,
|
|
4080
4031
|
display: String,
|
|
@@ -4086,17 +4037,32 @@
|
|
|
4086
4037
|
data: {
|
|
4087
4038
|
mode: ['click', 'hover'],
|
|
4088
4039
|
toggle: '- *',
|
|
4089
|
-
boundary:
|
|
4090
|
-
|
|
4040
|
+
boundary: false,
|
|
4041
|
+
target: false,
|
|
4042
|
+
targetX: false,
|
|
4043
|
+
targetY: false,
|
|
4044
|
+
stretch: false,
|
|
4091
4045
|
delayShow: 0,
|
|
4092
4046
|
delayHide: 800,
|
|
4093
4047
|
display: null,
|
|
4094
4048
|
clsDrop: false,
|
|
4049
|
+
animateOut: false,
|
|
4050
|
+
bgScroll: true,
|
|
4095
4051
|
animation: ['uk-animation-fade'],
|
|
4096
4052
|
cls: 'uk-open',
|
|
4097
|
-
container: false,
|
|
4098
|
-
|
|
4099
|
-
|
|
4053
|
+
container: false },
|
|
4054
|
+
|
|
4055
|
+
|
|
4056
|
+
computed: {
|
|
4057
|
+
target(_ref, $el) {let { target, targetX, targetY } = _ref;
|
|
4058
|
+
targetX = targetX || target || this.targetEl;
|
|
4059
|
+
targetY = targetY || target || this.targetEl;
|
|
4060
|
+
|
|
4061
|
+
return [
|
|
4062
|
+
targetX === true ? window : query(targetX, $el),
|
|
4063
|
+
targetY === true ? window : query(targetY, $el)];
|
|
4064
|
+
|
|
4065
|
+
} },
|
|
4100
4066
|
|
|
4101
4067
|
|
|
4102
4068
|
created() {
|
|
@@ -4110,13 +4076,13 @@
|
|
|
4110
4076
|
connected() {
|
|
4111
4077
|
addClass(this.$el, this.clsDrop);
|
|
4112
4078
|
|
|
4113
|
-
if (this.toggle && !this.
|
|
4114
|
-
this.
|
|
4079
|
+
if (this.toggle && !this.targetEl) {
|
|
4080
|
+
this.targetEl = this.$create('toggle', query(this.toggle, this.$el), {
|
|
4115
4081
|
target: this.$el,
|
|
4116
4082
|
mode: this.mode }).
|
|
4117
4083
|
$el;
|
|
4118
|
-
attr(this.
|
|
4119
|
-
this.lazyload(this.
|
|
4084
|
+
attr(this.targetEl, 'aria-haspopup', true);
|
|
4085
|
+
this.lazyload(this.targetEl);
|
|
4120
4086
|
}
|
|
4121
4087
|
},
|
|
4122
4088
|
|
|
@@ -4147,7 +4113,7 @@
|
|
|
4147
4113
|
return 'a[href^="#"]';
|
|
4148
4114
|
},
|
|
4149
4115
|
|
|
4150
|
-
handler(
|
|
4116
|
+
handler(_ref2) {let { defaultPrevented, current: { hash } } = _ref2;
|
|
4151
4117
|
if (!defaultPrevented && hash && !within(hash, this.$el)) {
|
|
4152
4118
|
this.hide(false);
|
|
4153
4119
|
}
|
|
@@ -4259,17 +4225,17 @@
|
|
|
4259
4225
|
on(
|
|
4260
4226
|
document,
|
|
4261
4227
|
pointerDown,
|
|
4262
|
-
(
|
|
4228
|
+
(_ref3) => {let { target } = _ref3;return (
|
|
4263
4229
|
!within(target, this.$el) &&
|
|
4264
4230
|
once(
|
|
4265
4231
|
document,
|
|
4266
4232
|
pointerUp + " " + pointerCancel + " scroll",
|
|
4267
|
-
(
|
|
4233
|
+
(_ref4) => {let { defaultPrevented, type, target: newTarget } = _ref4;
|
|
4268
4234
|
if (
|
|
4269
4235
|
!defaultPrevented &&
|
|
4270
4236
|
type === pointerUp &&
|
|
4271
4237
|
target === newTarget &&
|
|
4272
|
-
!(this.
|
|
4238
|
+
!(this.targetEl && within(target, this.targetEl)))
|
|
4273
4239
|
{
|
|
4274
4240
|
this.hide(false);
|
|
4275
4241
|
}
|
|
@@ -4288,13 +4254,13 @@
|
|
|
4288
4254
|
[] :
|
|
4289
4255
|
[preventOverscroll(this.$el), preventBackgroundScroll()]),
|
|
4290
4256
|
|
|
4291
|
-
...(this.display === 'static'
|
|
4257
|
+
...(this.display === 'static' ?
|
|
4292
4258
|
[] :
|
|
4293
4259
|
(() => {
|
|
4294
4260
|
const handler = () => this.$emit();
|
|
4295
4261
|
return [
|
|
4296
4262
|
on(window, 'resize', handler),
|
|
4297
|
-
on(document, 'scroll', handler
|
|
4263
|
+
on([document, scrollParents(this.$el)], 'scroll', handler),
|
|
4298
4264
|
(() => {
|
|
4299
4265
|
const observer = observeResize(
|
|
4300
4266
|
scrollParents(this.$el),
|
|
@@ -4323,7 +4289,7 @@
|
|
|
4323
4289
|
{
|
|
4324
4290
|
name: 'hide',
|
|
4325
4291
|
|
|
4326
|
-
handler(
|
|
4292
|
+
handler(_ref5) {let { target } = _ref5;
|
|
4327
4293
|
if (this.$el !== target) {
|
|
4328
4294
|
active =
|
|
4329
4295
|
active === null && within(target, this.$el) && this.isToggled() ?
|
|
@@ -4347,12 +4313,12 @@
|
|
|
4347
4313
|
|
|
4348
4314
|
|
|
4349
4315
|
methods: {
|
|
4350
|
-
show(target, delay) {if (target === void 0) {target = this.
|
|
4351
|
-
if (this.isToggled() && target && this.
|
|
4316
|
+
show(target, delay) {if (target === void 0) {target = this.targetEl;}if (delay === void 0) {delay = true;}
|
|
4317
|
+
if (this.isToggled() && target && this.targetEl && target !== this.targetEl) {
|
|
4352
4318
|
this.hide(false, false);
|
|
4353
4319
|
}
|
|
4354
4320
|
|
|
4355
|
-
this.
|
|
4321
|
+
this.targetEl = target;
|
|
4356
4322
|
|
|
4357
4323
|
this.clearTimers();
|
|
4358
4324
|
|
|
@@ -4415,60 +4381,69 @@
|
|
|
4415
4381
|
|
|
4416
4382
|
position() {
|
|
4417
4383
|
removeClass(this.$el, this.clsDrop + "-stack");
|
|
4418
|
-
|
|
4419
|
-
toggleClass(this.$el, this.clsDrop + "-stretch", this.align === 'stretch');
|
|
4384
|
+
css(this.$el, { width: '', height: '', maxWidth: '', top: '', left: '' });
|
|
4420
4385
|
|
|
4421
|
-
|
|
4422
|
-
|
|
4423
|
-
const [scrollParent] = scrollParents(
|
|
4424
|
-
boundary && this.boundaryAlign ? boundary : this.$el);
|
|
4386
|
+
// Ensure none positioned element does not generate scrollbars
|
|
4387
|
+
this.$el.hidden = true;
|
|
4425
4388
|
|
|
4426
|
-
const
|
|
4427
|
-
const boundaryOffset = boundary
|
|
4389
|
+
const boundary = query(this.boundary, this.$el);
|
|
4390
|
+
const boundaryOffset = offsetViewport(boundary || window);
|
|
4391
|
+
const viewports = this.target.map((target) => offsetViewport(scrollParents(target)[0]));
|
|
4428
4392
|
const viewportOffset = this.getViewportOffset(this.$el);
|
|
4429
4393
|
|
|
4430
|
-
|
|
4431
|
-
|
|
4394
|
+
const dirs = [
|
|
4395
|
+
[0, ['x', 'width', 'left', 'right']],
|
|
4396
|
+
[1, ['y', 'height', 'top', 'bottom']]];
|
|
4432
4397
|
|
|
4433
|
-
|
|
4434
|
-
|
|
4435
|
-
|
|
4436
|
-
|
|
4437
|
-
|
|
4438
|
-
|
|
4439
|
-
|
|
4440
|
-
|
|
4441
|
-
|
|
4442
|
-
|
|
4443
|
-
|
|
4444
|
-
|
|
4445
|
-
|
|
4446
|
-
|
|
4447
|
-
|
|
4448
|
-
|
|
4449
|
-
const elOffset = Math.abs(this.getPositionOffset(this.$el)) + viewportOffset;
|
|
4450
|
-
|
|
4451
|
-
css(this.$el, {
|
|
4452
|
-
width:
|
|
4453
|
-
this.axis === 'y' ?
|
|
4454
|
-
viewport.width :
|
|
4455
|
-
(this.dir === 'left' ?
|
|
4456
|
-
targetDim.left - viewport.left :
|
|
4457
|
-
viewport.right - targetDim.right) - elOffset,
|
|
4458
|
-
height:
|
|
4459
|
-
this.axis === 'x' ?
|
|
4460
|
-
viewport.height :
|
|
4461
|
-
(this.dir === 'top' ?
|
|
4462
|
-
targetDim.top - viewport.top :
|
|
4463
|
-
viewport.bottom - targetDim.bottom) - elOffset });
|
|
4464
|
-
|
|
4465
|
-
} else if (this.$el.offsetWidth > maxWidth) {
|
|
4398
|
+
|
|
4399
|
+
for (const [i, [axis, prop]] of dirs) {
|
|
4400
|
+
if (this.axis !== axis && includes([axis, true], this.stretch)) {
|
|
4401
|
+
css(this.$el, {
|
|
4402
|
+
[prop]: Math.min(
|
|
4403
|
+
boundaryOffset[prop],
|
|
4404
|
+
viewports[i][prop] - 2 * viewportOffset),
|
|
4405
|
+
|
|
4406
|
+
["overflow-" + axis]: 'auto' });
|
|
4407
|
+
|
|
4408
|
+
}
|
|
4409
|
+
}
|
|
4410
|
+
|
|
4411
|
+
const maxWidth = viewports[0].width - 2 * viewportOffset;
|
|
4412
|
+
|
|
4413
|
+
if (this.$el.offsetWidth > maxWidth) {
|
|
4466
4414
|
addClass(this.$el, this.clsDrop + "-stack");
|
|
4467
4415
|
}
|
|
4468
4416
|
|
|
4469
4417
|
css(this.$el, 'maxWidth', maxWidth);
|
|
4470
4418
|
|
|
4471
|
-
this
|
|
4419
|
+
this.$el.hidden = false;
|
|
4420
|
+
|
|
4421
|
+
this.positionAt(this.$el, this.target, boundary);
|
|
4422
|
+
|
|
4423
|
+
for (const [i, [axis, prop, start, end]] of dirs) {
|
|
4424
|
+
if (this.axis === axis && includes([axis, true], this.stretch)) {
|
|
4425
|
+
const positionOffset = Math.abs(this.getPositionOffset(this.$el));
|
|
4426
|
+
const targetOffset = offset(this.target[i]);
|
|
4427
|
+
const elOffset = offset(this.$el);
|
|
4428
|
+
|
|
4429
|
+
css(this.$el, {
|
|
4430
|
+
[prop]:
|
|
4431
|
+
(targetOffset[start] > elOffset[start] ?
|
|
4432
|
+
targetOffset[start] -
|
|
4433
|
+
Math.max(
|
|
4434
|
+
boundaryOffset[start],
|
|
4435
|
+
viewports[i][start] + viewportOffset) :
|
|
4436
|
+
|
|
4437
|
+
Math.min(
|
|
4438
|
+
boundaryOffset[end],
|
|
4439
|
+
viewports[i][end] - viewportOffset) -
|
|
4440
|
+
targetOffset[end]) - positionOffset,
|
|
4441
|
+
["overflow-" + axis]: 'auto' });
|
|
4442
|
+
|
|
4443
|
+
|
|
4444
|
+
this.positionAt(this.$el, this.target, boundary);
|
|
4445
|
+
}
|
|
4446
|
+
}
|
|
4472
4447
|
} } };
|
|
4473
4448
|
|
|
4474
4449
|
|
|
@@ -4965,8 +4940,11 @@
|
|
|
4965
4940
|
let minHeight = '';
|
|
4966
4941
|
const box = boxModelAdjust(this.$el, 'height', 'content-box');
|
|
4967
4942
|
|
|
4943
|
+
const { body, scrollingElement } = document;
|
|
4968
4944
|
const [scrollElement] = scrollParents(this.$el, /auto|scroll/);
|
|
4969
|
-
const { height: viewportHeight } = offsetViewport(
|
|
4945
|
+
const { height: viewportHeight } = offsetViewport(
|
|
4946
|
+
scrollElement === body ? scrollingElement : scrollElement);
|
|
4947
|
+
|
|
4970
4948
|
|
|
4971
4949
|
if (this.expand) {
|
|
4972
4950
|
minHeight = Math.max(
|
|
@@ -4976,7 +4954,6 @@
|
|
|
4976
4954
|
0);
|
|
4977
4955
|
|
|
4978
4956
|
} else {
|
|
4979
|
-
const { body, scrollingElement } = document;
|
|
4980
4957
|
const isScrollingElement =
|
|
4981
4958
|
scrollingElement === scrollElement || body === scrollElement;
|
|
4982
4959
|
|
|
@@ -5232,7 +5209,13 @@
|
|
|
5232
5209
|
|
|
5233
5210
|
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>";
|
|
5234
5211
|
|
|
5235
|
-
var
|
|
5212
|
+
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>";
|
|
5213
|
+
|
|
5214
|
+
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>";
|
|
5215
|
+
|
|
5216
|
+
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>";
|
|
5217
|
+
|
|
5218
|
+
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>";
|
|
5236
5219
|
|
|
5237
5220
|
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>";
|
|
5238
5221
|
|
|
@@ -5264,6 +5247,9 @@
|
|
|
5264
5247
|
marker,
|
|
5265
5248
|
'close-icon': closeIcon,
|
|
5266
5249
|
'close-large': closeLarge,
|
|
5250
|
+
'nav-parent-icon': navParentIcon,
|
|
5251
|
+
'nav-parent-icon-large': navParentIconLarge,
|
|
5252
|
+
'navbar-parent-icon': navbarParentIcon,
|
|
5267
5253
|
'navbar-toggle-icon': navbarToggleIcon,
|
|
5268
5254
|
'overlay-icon': overlayIcon,
|
|
5269
5255
|
'pagination-next': paginationNext,
|
|
@@ -5321,6 +5307,15 @@
|
|
|
5321
5307
|
} };
|
|
5322
5308
|
|
|
5323
5309
|
|
|
5310
|
+
const NavParentIcon = {
|
|
5311
|
+
extends: IconComponent,
|
|
5312
|
+
|
|
5313
|
+
beforeConnect() {
|
|
5314
|
+
const icon = this.$props.icon;
|
|
5315
|
+
this.icon = closest(this.$el, '.uk-nav-primary') ? icon + "-large" : icon;
|
|
5316
|
+
} };
|
|
5317
|
+
|
|
5318
|
+
|
|
5324
5319
|
const Slidenav = {
|
|
5325
5320
|
extends: IconComponent,
|
|
5326
5321
|
|
|
@@ -5581,7 +5576,7 @@
|
|
|
5581
5576
|
|
|
5582
5577
|
|
|
5583
5578
|
connected() {
|
|
5584
|
-
const media = toMedia(this.media);
|
|
5579
|
+
const media = toMedia(this.media, this.$el);
|
|
5585
5580
|
this.matchMedia = true;
|
|
5586
5581
|
if (media) {
|
|
5587
5582
|
this.mediaObj = window.matchMedia(media);
|
|
@@ -5602,11 +5597,10 @@
|
|
|
5602
5597
|
} };
|
|
5603
5598
|
|
|
5604
5599
|
|
|
5605
|
-
function toMedia(value) {
|
|
5600
|
+
function toMedia(value, element) {
|
|
5606
5601
|
if (isString(value)) {
|
|
5607
5602
|
if (startsWith(value, '@')) {
|
|
5608
|
-
|
|
5609
|
-
value = toFloat(getCssVar(name));
|
|
5603
|
+
value = toFloat(css(element, "--uk-breakpoint-" + value.substr(1)));
|
|
5610
5604
|
} else if (isNaN(value)) {
|
|
5611
5605
|
return value;
|
|
5612
5606
|
}
|
|
@@ -5631,7 +5625,7 @@
|
|
|
5631
5625
|
|
|
5632
5626
|
computed: {
|
|
5633
5627
|
fill(_ref) {let { fill } = _ref;
|
|
5634
|
-
return fill ||
|
|
5628
|
+
return fill || css(this.$el, '--uk-leader-fill-content');
|
|
5635
5629
|
} },
|
|
5636
5630
|
|
|
5637
5631
|
|
|
@@ -5823,7 +5817,7 @@
|
|
|
5823
5817
|
align: String,
|
|
5824
5818
|
offset: Number,
|
|
5825
5819
|
boundary: Boolean,
|
|
5826
|
-
|
|
5820
|
+
target: Boolean,
|
|
5827
5821
|
clsDrop: String,
|
|
5828
5822
|
delayShow: Number,
|
|
5829
5823
|
delayHide: Number,
|
|
@@ -5840,9 +5834,12 @@
|
|
|
5840
5834
|
offset: undefined,
|
|
5841
5835
|
delayShow: undefined,
|
|
5842
5836
|
delayHide: undefined,
|
|
5843
|
-
|
|
5844
|
-
|
|
5837
|
+
flip: false,
|
|
5838
|
+
shift: true,
|
|
5845
5839
|
boundary: true,
|
|
5840
|
+
target: false,
|
|
5841
|
+
targetX: false,
|
|
5842
|
+
targetY: false,
|
|
5846
5843
|
dropbar: false,
|
|
5847
5844
|
dropbarAnchor: false,
|
|
5848
5845
|
duration: 200,
|
|
@@ -5877,7 +5874,7 @@
|
|
|
5877
5874
|
},
|
|
5878
5875
|
|
|
5879
5876
|
watch(dropbar) {
|
|
5880
|
-
addClass(dropbar, 'uk-navbar-dropbar');
|
|
5877
|
+
addClass(dropbar, 'uk-dropbar', 'uk-dropbar-top', 'uk-navbar-dropbar');
|
|
5881
5878
|
},
|
|
5882
5879
|
|
|
5883
5880
|
immediate: true },
|
|
@@ -5893,7 +5890,7 @@
|
|
|
5893
5890
|
|
|
5894
5891
|
if (this.dropContainer !== $el) {
|
|
5895
5892
|
for (const el of $$("." + clsDrop, this.dropContainer)) {var _this$getDropdown;
|
|
5896
|
-
const target = (_this$getDropdown = this.getDropdown(el)) == null ? void 0 : _this$getDropdown.
|
|
5893
|
+
const target = (_this$getDropdown = this.getDropdown(el)) == null ? void 0 : _this$getDropdown.targetEl;
|
|
5897
5894
|
if (!includes(dropdowns, el) && target && within(target, this.$el)) {
|
|
5898
5895
|
dropdowns.push(el);
|
|
5899
5896
|
}
|
|
@@ -5955,8 +5952,8 @@
|
|
|
5955
5952
|
if (
|
|
5956
5953
|
active &&
|
|
5957
5954
|
includes(active.mode, 'hover') &&
|
|
5958
|
-
active.
|
|
5959
|
-
!within(active.
|
|
5955
|
+
active.targetEl &&
|
|
5956
|
+
!within(active.targetEl, current) &&
|
|
5960
5957
|
!active.isDelaying)
|
|
5961
5958
|
{
|
|
5962
5959
|
active.hide(false);
|
|
@@ -5978,7 +5975,7 @@
|
|
|
5978
5975
|
if (keyCode === keyMap.DOWN && hasAttr(current, 'aria-expanded')) {
|
|
5979
5976
|
e.preventDefault();
|
|
5980
5977
|
|
|
5981
|
-
if (!active || active.
|
|
5978
|
+
if (!active || active.targetEl !== current) {
|
|
5982
5979
|
current.click();
|
|
5983
5980
|
once(this.dropContainer, 'show', (_ref8) => {let { target } = _ref8;return (
|
|
5984
5981
|
focusFirstFocusableElement(target));});
|
|
@@ -6028,8 +6025,8 @@
|
|
|
6028
6025
|
}
|
|
6029
6026
|
}
|
|
6030
6027
|
|
|
6031
|
-
if (keyCode === keyMap.ESC) {var _active$
|
|
6032
|
-
active == null ? void 0 : (_active$
|
|
6028
|
+
if (keyCode === keyMap.ESC) {var _active$targetEl;
|
|
6029
|
+
active == null ? void 0 : (_active$targetEl = active.targetEl) == null ? void 0 : _active$targetEl.focus();
|
|
6033
6030
|
}
|
|
6034
6031
|
|
|
6035
6032
|
handleNavItemNavigation(e, this.toggles, active);
|
|
@@ -6100,39 +6097,19 @@
|
|
|
6100
6097
|
return;
|
|
6101
6098
|
}
|
|
6102
6099
|
|
|
6103
|
-
this._observer = observeResize(target, () =>
|
|
6104
|
-
|
|
6105
|
-
|
|
6106
|
-
|
|
6107
|
-
|
|
6108
|
-
|
|
6100
|
+
this._observer = observeResize(target, () => {
|
|
6101
|
+
const targetOffsets = parents(target, "." + this.clsDrop).
|
|
6102
|
+
concat(target).
|
|
6103
|
+
map((el) => offset(el));
|
|
6104
|
+
const minTop = Math.min(...targetOffsets.map((_ref11) => {let { top } = _ref11;return top;}));
|
|
6105
|
+
const maxBottom = Math.max(...targetOffsets.map((_ref12) => {let { bottom } = _ref12;return bottom;}));
|
|
6106
|
+
const dropbarOffset = offset(this.dropbar);
|
|
6107
|
+
css(this.dropbar, 'top', this.dropbar.offsetTop - (dropbarOffset.top - minTop));
|
|
6108
|
+
this.transitionTo(
|
|
6109
|
+
maxBottom - minTop + toFloat(css(target, 'marginBottom')),
|
|
6110
|
+
target);
|
|
6109
6111
|
|
|
6110
|
-
|
|
6111
|
-
} },
|
|
6112
|
-
|
|
6113
|
-
|
|
6114
|
-
{
|
|
6115
|
-
name: 'beforeposition',
|
|
6116
|
-
|
|
6117
|
-
el() {
|
|
6118
|
-
return this.dropContainer;
|
|
6119
|
-
},
|
|
6120
|
-
|
|
6121
|
-
filter() {
|
|
6122
|
-
return this.dropbar;
|
|
6123
|
-
},
|
|
6124
|
-
|
|
6125
|
-
handler(e, element, target, options) {
|
|
6126
|
-
if (!this.isDropbarDrop(element)) {
|
|
6127
|
-
return;
|
|
6128
|
-
}
|
|
6129
|
-
|
|
6130
|
-
const dropbarOffset = offset(this.dropbar);
|
|
6131
|
-
|
|
6132
|
-
css(element, 'maxWidth', dropbarOffset.width - options.viewportOffset * 2);
|
|
6133
|
-
|
|
6134
|
-
options.offset[1] = dropbarOffset.top - offset(target).bottom;
|
|
6135
|
-
options.viewportOffset += dropbarOffset.left;
|
|
6112
|
+
});
|
|
6136
6113
|
} },
|
|
6137
6114
|
|
|
6138
6115
|
|
|
@@ -6153,7 +6130,7 @@
|
|
|
6153
6130
|
if (
|
|
6154
6131
|
matches(this.dropbar, ':hover') &&
|
|
6155
6132
|
(active == null ? void 0 : active.$el) === e.target &&
|
|
6156
|
-
!this.toggles.some((el) => active.
|
|
6133
|
+
!this.toggles.some((el) => active.targetEl !== el && matches(el, ':focus')))
|
|
6157
6134
|
{
|
|
6158
6135
|
e.preventDefault();
|
|
6159
6136
|
}
|
|
@@ -6171,7 +6148,7 @@
|
|
|
6171
6148
|
return this.dropbar;
|
|
6172
6149
|
},
|
|
6173
6150
|
|
|
6174
|
-
handler(
|
|
6151
|
+
handler(_ref13) {let { target } = _ref13;
|
|
6175
6152
|
if (!this.isDropbarDrop(target)) {
|
|
6176
6153
|
return;
|
|
6177
6154
|
}
|
|
@@ -6189,7 +6166,7 @@
|
|
|
6189
6166
|
|
|
6190
6167
|
methods: {
|
|
6191
6168
|
getActive() {
|
|
6192
|
-
return active && within(active.
|
|
6169
|
+
return active && within(active.targetEl, this.$el) && active;
|
|
6193
6170
|
},
|
|
6194
6171
|
|
|
6195
6172
|
transitionTo(newHeight, el) {
|
|
@@ -6222,15 +6199,14 @@
|
|
|
6222
6199
|
},
|
|
6223
6200
|
|
|
6224
6201
|
isDropbarDrop(el) {
|
|
6225
|
-
|
|
6226
|
-
return drop && hasClass(el, this.clsDrop) && drop.align !== 'stretch';
|
|
6202
|
+
return this.getDropdown(el) && hasClass(el, this.clsDrop);
|
|
6227
6203
|
} } };
|
|
6228
6204
|
|
|
6229
6205
|
|
|
6230
6206
|
|
|
6231
6207
|
function handleNavItemNavigation(e, toggles, active) {
|
|
6232
6208
|
const { current, keyCode } = e;
|
|
6233
|
-
const target = (active == null ? void 0 : active.
|
|
6209
|
+
const target = (active == null ? void 0 : active.targetEl) || current;
|
|
6234
6210
|
const i = toggles.indexOf(target);
|
|
6235
6211
|
|
|
6236
6212
|
// Left
|
|
@@ -6598,6 +6574,14 @@
|
|
|
6598
6574
|
offset: 0 },
|
|
6599
6575
|
|
|
6600
6576
|
|
|
6577
|
+
connected() {
|
|
6578
|
+
registerClick(this);
|
|
6579
|
+
},
|
|
6580
|
+
|
|
6581
|
+
disconnected() {
|
|
6582
|
+
unregisterClick(this);
|
|
6583
|
+
},
|
|
6584
|
+
|
|
6601
6585
|
methods: {
|
|
6602
6586
|
async scrollTo(el) {
|
|
6603
6587
|
el = el && $(el) || document.body;
|
|
@@ -6606,20 +6590,39 @@
|
|
|
6606
6590
|
await scrollIntoView(el, { offset: this.offset });
|
|
6607
6591
|
trigger(this.$el, 'scrolled', [this, el]);
|
|
6608
6592
|
}
|
|
6609
|
-
} }
|
|
6593
|
+
} } };
|
|
6610
6594
|
|
|
6611
6595
|
|
|
6612
|
-
events: {
|
|
6613
|
-
click(e) {
|
|
6614
|
-
if (e.defaultPrevented) {
|
|
6615
|
-
return;
|
|
6616
|
-
}
|
|
6617
6596
|
|
|
6618
|
-
|
|
6619
|
-
|
|
6620
|
-
|
|
6597
|
+
const components$1 = new Set();
|
|
6598
|
+
function registerClick(cmp) {
|
|
6599
|
+
if (!components$1.size) {
|
|
6600
|
+
on(document, 'click', clickHandler);
|
|
6601
|
+
}
|
|
6602
|
+
|
|
6603
|
+
components$1.add(cmp);
|
|
6604
|
+
}
|
|
6605
|
+
|
|
6606
|
+
function unregisterClick(cmp) {
|
|
6607
|
+
components$1.delete(cmp);
|
|
6621
6608
|
|
|
6609
|
+
if (!components$1.length) {
|
|
6610
|
+
off(document, 'click', clickHandler);
|
|
6611
|
+
}
|
|
6612
|
+
}
|
|
6622
6613
|
|
|
6614
|
+
function clickHandler(e) {
|
|
6615
|
+
if (e.defaultPrevented) {
|
|
6616
|
+
return;
|
|
6617
|
+
}
|
|
6618
|
+
|
|
6619
|
+
for (const component of components$1) {
|
|
6620
|
+
if (within(e.target, component.$el)) {
|
|
6621
|
+
e.preventDefault();
|
|
6622
|
+
component.scrollTo(getTargetElement(component.$el));
|
|
6623
|
+
}
|
|
6624
|
+
}
|
|
6625
|
+
}
|
|
6623
6626
|
|
|
6624
6627
|
function getTargetElement(el) {
|
|
6625
6628
|
return document.getElementById(decodeURIComponent(el.hash).substring(1));
|
|
@@ -7688,10 +7691,12 @@
|
|
|
7688
7691
|
Video: Video,
|
|
7689
7692
|
Close: Close,
|
|
7690
7693
|
Spinner: Spinner,
|
|
7694
|
+
NavParentIcon: NavParentIcon,
|
|
7691
7695
|
SlidenavNext: Slidenav,
|
|
7692
7696
|
SlidenavPrevious: Slidenav,
|
|
7693
7697
|
SearchIcon: Search,
|
|
7694
7698
|
Marker: IconComponent,
|
|
7699
|
+
NavbarParentIcon: IconComponent,
|
|
7695
7700
|
NavbarToggleIcon: IconComponent,
|
|
7696
7701
|
OverlayIcon: IconComponent,
|
|
7697
7702
|
PaginationNext: IconComponent,
|