uikit 3.25.18-dev.9fa57fb → 3.25.18-dev.f49c4ef
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 +32 -2
- package/build/prefix.js +1 -1
- package/build/publishDev.js +1 -1
- package/build/scope.js +1 -1
- package/build/scss.js +1 -1
- package/dist/css/uikit-core-rtl.css +942 -820
- package/dist/css/uikit-core-rtl.min.css +1 -1
- package/dist/css/uikit-core.css +942 -820
- package/dist/css/uikit-core.min.css +1 -1
- package/dist/css/uikit-rtl.css +1039 -917
- package/dist/css/uikit-rtl.min.css +1 -1
- package/dist/css/uikit.css +1039 -917
- 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 +133 -132
- package/dist/js/components/lightbox-panel.min.js +1 -1
- package/dist/js/components/lightbox.js +134 -133
- package/dist/js/components/lightbox.min.js +1 -1
- package/dist/js/components/marquee.js +179 -0
- package/dist/js/components/marquee.min.js +1 -0
- package/dist/js/components/notification.js +1 -1
- package/dist/js/components/notification.min.js +1 -1
- package/dist/js/components/parallax.js +8 -12
- package/dist/js/components/parallax.min.js +1 -1
- package/dist/js/components/slider-parallax.js +8 -12
- package/dist/js/components/slider-parallax.min.js +1 -1
- package/dist/js/components/slider.js +43 -27
- package/dist/js/components/slider.min.js +1 -1
- package/dist/js/components/slideshow-parallax.js +8 -12
- package/dist/js/components/slideshow-parallax.min.js +1 -1
- package/dist/js/components/slideshow.js +71 -102
- 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 +19 -19
- 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 +752 -262
- package/dist/js/uikit-core.min.js +1 -1
- package/dist/js/uikit-icons.js +1 -1
- package/dist/js/uikit-icons.min.js +1 -1
- package/dist/js/uikit.js +629 -376
- package/dist/js/uikit.min.js +1 -1
- package/package.json +1 -1
- package/src/js/api/component.js +2 -3
- package/src/js/api/observables.js +2 -4
- package/src/js/api/options.js +6 -3
- package/src/js/api/props.js +1 -4
- package/src/js/api/state.js +7 -8
- package/src/js/components/index.js +1 -0
- package/src/js/components/internal/lightbox-animations.js +7 -26
- package/src/js/components/internal/slideshow-animations.js +15 -62
- package/src/js/components/lightbox-panel.js +121 -96
- package/src/js/components/lightbox.js +5 -8
- package/src/js/components/marquee.js +123 -0
- package/src/js/components/slider.js +2 -2
- package/src/js/components/tooltip.js +4 -2
- package/src/js/core/accordion.js +78 -29
- package/src/js/core/drop.js +5 -4
- package/src/js/core/dropnav.js +3 -3
- package/src/js/core/grid.js +5 -19
- package/src/js/core/height-match.js +1 -2
- package/src/js/core/margin.js +3 -0
- package/src/js/core/overflow-fade.js +5 -5
- package/src/js/core/sticky.js +1 -1
- package/src/js/core/switcher.js +24 -44
- package/src/js/core/video.js +172 -15
- package/src/js/mixin/connect.js +55 -0
- package/src/js/mixin/internal/slideshow-animations.js +5 -13
- package/src/js/mixin/internal/slideshow-transitioner.js +2 -2
- package/src/js/mixin/modal.js +4 -3
- package/src/js/mixin/parallax.js +1 -4
- package/src/js/mixin/position.js +1 -1
- package/src/js/mixin/scroll-driven.js +57 -0
- package/src/js/mixin/slider-nav.js +1 -1
- package/src/js/mixin/slider-parallax.js +9 -38
- package/src/js/mixin/togglable.js +13 -14
- package/src/js/util/attr.js +7 -7
- package/src/js/util/class.js +1 -1
- package/src/js/util/dom.js +3 -4
- package/src/js/util/lang.js +1 -1
- package/src/js/util/player.js +4 -4
- package/src/js/util/style.js +10 -15
- package/src/js/util/viewport.js +22 -25
- package/src/less/components/_import.less +6 -1
- package/src/less/components/base.less +1 -1
- package/src/less/components/button.less +1 -1
- package/src/less/components/dropcap.less +71 -0
- package/src/less/components/floating-shadow.less +66 -0
- package/src/less/components/form.less +5 -5
- package/src/less/components/grid.less +57 -64
- package/src/less/components/logo.less +94 -0
- package/src/less/components/margin.less +152 -124
- package/src/less/components/marquee.less +133 -0
- package/src/less/components/nav.less +1 -1
- package/src/less/components/padding.less +9 -9
- package/src/less/components/text.less +6 -0
- package/src/less/components/utility.less +0 -163
- package/src/less/theme/_import.less +5 -1
- package/src/less/theme/dropcap.less +29 -0
- package/src/less/theme/floating-shadow.less +20 -0
- package/src/less/theme/logo.less +29 -0
- package/src/less/theme/marquee.less +14 -0
- package/src/less/theme/utility.less +0 -32
- package/src/scss/components/_import.scss +6 -1
- package/src/scss/components/base.scss +1 -1
- package/src/scss/components/button.scss +1 -1
- package/src/scss/components/dropcap.scss +63 -0
- package/src/scss/components/floating-shadow.scss +63 -0
- package/src/scss/components/form.scss +5 -5
- package/src/scss/components/grid.scss +57 -64
- package/src/scss/components/logo.scss +75 -0
- package/src/scss/components/margin.scss +152 -124
- package/src/scss/components/marquee.scss +136 -0
- package/src/scss/components/nav.scss +1 -1
- package/src/scss/components/padding.scss +9 -9
- package/src/scss/components/text.scss +6 -0
- package/src/scss/components/utility.scss +0 -129
- package/src/scss/mixins-theme.scss +41 -32
- package/src/scss/mixins.scss +38 -29
- package/src/scss/variables-theme.scss +14 -14
- package/src/scss/variables.scss +14 -14
- package/tests/accordion.html +77 -10
- package/tests/alert.html +1 -1
- package/tests/align.html +5 -5
- package/tests/animation.html +4 -4
- package/tests/article.html +7 -7
- package/tests/background.html +2 -2
- package/tests/badge.html +1 -1
- package/tests/base.html +2 -2
- package/tests/button.html +1 -1
- package/tests/card.html +15 -15
- package/tests/close.html +2 -2
- package/tests/comment.html +9 -9
- package/tests/container.html +2 -2
- package/tests/countdown.html +21 -21
- package/tests/cover.html +3 -3
- package/tests/description-list.html +1 -1
- package/tests/divider.html +3 -3
- package/tests/dotnav.html +1 -1
- package/tests/drop.html +7 -7
- package/tests/dropbar.html +5 -5
- package/tests/dropcap.html +26 -0
- package/tests/dropdown.html +1 -1
- package/tests/dropnav.html +18 -18
- package/tests/filter.html +3 -3
- package/tests/floating-shadow.html +44 -0
- package/tests/form.html +14 -14
- package/tests/grid.html +41 -47
- package/tests/heading.html +2 -2
- package/tests/height-viewport.html +4 -4
- package/tests/height.html +5 -5
- package/tests/icon.html +8 -8
- package/tests/image.html +6 -6
- package/tests/index.html +13 -13
- package/tests/js/index.js +1 -1
- package/tests/leader.html +5 -5
- package/tests/lightbox.html +6 -6
- package/tests/link.html +1 -1
- package/tests/list.html +4 -4
- package/tests/logo.html +84 -0
- package/tests/margin.html +7 -7
- package/tests/marker.html +3 -3
- package/tests/marquee.html +617 -0
- package/tests/modal.html +3 -3
- package/tests/nav.html +5 -5
- package/tests/navbar.html +27 -27
- package/tests/notification.html +2 -2
- package/tests/offcanvas.html +12 -12
- package/tests/overlay.html +3 -3
- package/tests/padding.html +1 -1
- package/tests/pagination.html +3 -3
- package/tests/parallax.html +1 -1
- package/tests/position.html +6 -6
- package/tests/scrollspy.html +12 -12
- package/tests/search.html +5 -5
- package/tests/section.html +17 -17
- package/tests/slidenav.html +3 -3
- package/tests/slider.html +5 -5
- package/tests/slideshow.html +33 -3
- package/tests/sortable.html +19 -19
- package/tests/sticky-navbar.html +4 -4
- package/tests/sticky-parallax.html +3 -3
- package/tests/sticky.html +3 -3
- package/tests/svg.html +3 -2
- package/tests/switcher.html +6 -6
- package/tests/tab.html +4 -4
- package/tests/text.html +3 -3
- package/tests/tile.html +4 -4
- package/tests/toggle.html +1 -1
- package/tests/tooltip.html +3 -3
- package/tests/totop.html +2 -2
- package/tests/transition.html +1 -1
- package/tests/upload.html +5 -5
- package/tests/utility.html +16 -116
- package/tests/video.html +224 -24
- package/tests/visibility.html +4 -4
- package/tests/width.html +12 -12
package/dist/js/uikit.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.25.18-dev.
|
|
1
|
+
/*! UIkit 3.25.18-dev.f49c4ef | https://www.getuikit.com | (c) 2014 - 2026 YOOtheme | MIT License */
|
|
2
2
|
|
|
3
3
|
(function (global, factory) {
|
|
4
4
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
@@ -134,7 +134,7 @@
|
|
|
134
134
|
return array.filter(({ [prop]: check }) => seen.has(check) ? false : seen.add(check));
|
|
135
135
|
}
|
|
136
136
|
function pick(obj, props) {
|
|
137
|
-
return props.
|
|
137
|
+
return Object.fromEntries(props.map((key) => [key, obj[key]]));
|
|
138
138
|
}
|
|
139
139
|
function clamp(number, min = 0, max = 1) {
|
|
140
140
|
return Math.min(Math.max(toNumber(number) || 0, min), max);
|
|
@@ -230,7 +230,7 @@
|
|
|
230
230
|
}
|
|
231
231
|
}
|
|
232
232
|
function toClasses(str) {
|
|
233
|
-
return str ? isArray(str) ? str.
|
|
233
|
+
return str ? isArray(str) ? str.flatMap(toClasses) : String(str).split(" ").filter(Boolean) : [];
|
|
234
234
|
}
|
|
235
235
|
|
|
236
236
|
function attr(element, name, value) {
|
|
@@ -243,13 +243,12 @@
|
|
|
243
243
|
}
|
|
244
244
|
if (isUndefined(value)) {
|
|
245
245
|
return (_a = toNode(element)) == null ? void 0 : _a.getAttribute(name);
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
}
|
|
246
|
+
}
|
|
247
|
+
for (const el of toNodes(element)) {
|
|
248
|
+
if (value === null) {
|
|
249
|
+
removeAttr(el, name);
|
|
250
|
+
} else {
|
|
251
|
+
el.setAttribute(name, value);
|
|
253
252
|
}
|
|
254
253
|
}
|
|
255
254
|
}
|
|
@@ -589,19 +588,14 @@
|
|
|
589
588
|
property = propName(property);
|
|
590
589
|
if (isUndefined(value)) {
|
|
591
590
|
return getComputedStyle(element2).getPropertyValue(property);
|
|
592
|
-
} else {
|
|
593
|
-
element2.style.setProperty(
|
|
594
|
-
property,
|
|
595
|
-
isNumeric(value) && !cssNumber[property] && !isCustomProperty(property) ? `${value}px` : value || isNumber(value) ? value : "",
|
|
596
|
-
priority
|
|
597
|
-
);
|
|
598
591
|
}
|
|
592
|
+
element2.style.setProperty(
|
|
593
|
+
property,
|
|
594
|
+
isNumeric(value) && !cssNumber[property] && !isCustomProperty(property) ? `${value}px` : value || isNumber(value) ? value : "",
|
|
595
|
+
priority
|
|
596
|
+
);
|
|
599
597
|
} else if (isArray(property)) {
|
|
600
|
-
|
|
601
|
-
for (const prop of property) {
|
|
602
|
-
props[prop] = css(element2, prop);
|
|
603
|
-
}
|
|
604
|
-
return props;
|
|
598
|
+
return Object.fromEntries(property.map((prop) => [prop, css(element2, prop)]));
|
|
605
599
|
} else if (isObject(property)) {
|
|
606
600
|
for (const prop in property) {
|
|
607
601
|
css(element2, prop, property[prop], value);
|
|
@@ -785,7 +779,9 @@
|
|
|
785
779
|
);
|
|
786
780
|
}
|
|
787
781
|
function unwrap(element) {
|
|
788
|
-
toNodes(element).map(parent)
|
|
782
|
+
for (const elementParent of new Set(toNodes(element).map(parent))) {
|
|
783
|
+
elementParent.replaceWith(...elementParent.childNodes);
|
|
784
|
+
}
|
|
789
785
|
}
|
|
790
786
|
const singleTagRe = /^<(\w+)\s*\/?>(?:<\/\1>)?$/;
|
|
791
787
|
function fragment(html2) {
|
|
@@ -1147,12 +1143,12 @@
|
|
|
1147
1143
|
return isTag(el, "iframe") && (isYoutube(el) || isVimeo(el));
|
|
1148
1144
|
}
|
|
1149
1145
|
function isYoutube(el) {
|
|
1150
|
-
return
|
|
1151
|
-
|
|
1146
|
+
return /\/\/.*?youtube(-nocookie)?\.[a-z]+\/(watch\?v=[^&\s]+|embed)|youtu\.be\/.*/.test(
|
|
1147
|
+
el.src
|
|
1152
1148
|
);
|
|
1153
1149
|
}
|
|
1154
1150
|
function isVimeo(el) {
|
|
1155
|
-
return
|
|
1151
|
+
return /vimeo\.com\/video\/.*/.test(el.src);
|
|
1156
1152
|
}
|
|
1157
1153
|
async function call(el, cmd) {
|
|
1158
1154
|
await enableApi(el);
|
|
@@ -1161,7 +1157,7 @@
|
|
|
1161
1157
|
function post(el, cmd) {
|
|
1162
1158
|
el.contentWindow.postMessage(JSON.stringify({ event: "command", ...cmd }), "*");
|
|
1163
1159
|
}
|
|
1164
|
-
const stateKey =
|
|
1160
|
+
const stateKey = /* @__PURE__ */ Symbol();
|
|
1165
1161
|
let counter = 0;
|
|
1166
1162
|
function enableApi(el) {
|
|
1167
1163
|
if (el[stateKey]) {
|
|
@@ -1192,17 +1188,16 @@
|
|
|
1192
1188
|
if (!isVisible(element)) {
|
|
1193
1189
|
return false;
|
|
1194
1190
|
}
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
);
|
|
1191
|
+
const rects = overflowParents(element).map((parent2) => {
|
|
1192
|
+
const { top, left, bottom, right } = offsetViewport(parent2);
|
|
1193
|
+
return {
|
|
1194
|
+
top: top - offsetTop,
|
|
1195
|
+
left: left - offsetLeft,
|
|
1196
|
+
bottom: bottom + offsetTop,
|
|
1197
|
+
right: right + offsetLeft
|
|
1198
|
+
};
|
|
1199
|
+
});
|
|
1200
|
+
return intersectRect(...rects, offset(element));
|
|
1206
1201
|
}
|
|
1207
1202
|
function scrollIntoView(element, { offset: offsetBy = 0 } = {}) {
|
|
1208
1203
|
const parents2 = isVisible(element) ? scrollParents(element, false, ["hidden"]) : [];
|
|
@@ -1286,11 +1281,12 @@
|
|
|
1286
1281
|
if (~fixedIndex) {
|
|
1287
1282
|
ancestors = ancestors.slice(fixedIndex);
|
|
1288
1283
|
}
|
|
1289
|
-
return [
|
|
1290
|
-
|
|
1284
|
+
return [
|
|
1285
|
+
scrollEl,
|
|
1286
|
+
...ancestors.filter(
|
|
1291
1287
|
(parent2) => css(parent2, "overflow").split(" ").some((prop) => includes(["auto", "scroll", ...props], prop)) && (!scrollable || parent2.scrollHeight > offsetViewport(parent2).height)
|
|
1292
1288
|
)
|
|
1293
|
-
|
|
1289
|
+
].reverse();
|
|
1294
1290
|
}
|
|
1295
1291
|
function scrollParent(...args) {
|
|
1296
1292
|
return scrollParents(...args)[0];
|
|
@@ -1872,11 +1868,14 @@
|
|
|
1872
1868
|
function coerce$1(type, value) {
|
|
1873
1869
|
if (type === Boolean) {
|
|
1874
1870
|
return toBoolean(value);
|
|
1875
|
-
}
|
|
1871
|
+
}
|
|
1872
|
+
if (type === Number) {
|
|
1876
1873
|
return toNumber(value);
|
|
1877
|
-
}
|
|
1874
|
+
}
|
|
1875
|
+
if (type === "list") {
|
|
1878
1876
|
return toList(value);
|
|
1879
|
-
}
|
|
1877
|
+
}
|
|
1878
|
+
if (type === Object && isString(value)) {
|
|
1880
1879
|
return parseOptions(value);
|
|
1881
1880
|
}
|
|
1882
1881
|
return type ? type(value) : value;
|
|
@@ -1956,8 +1955,8 @@
|
|
|
1956
1955
|
for (const el of toNodes(isFunction(targets) ? targets(this) : targets)) {
|
|
1957
1956
|
$$('[loading="lazy"]', el).slice(0, preload - 1).forEach((el2) => removeAttr(el2, "loading"));
|
|
1958
1957
|
}
|
|
1959
|
-
for (const
|
|
1960
|
-
observer.unobserve(
|
|
1958
|
+
for (const { target } of entries.filter(({ isIntersecting }) => isIntersecting)) {
|
|
1959
|
+
observer.unobserve(target);
|
|
1961
1960
|
}
|
|
1962
1961
|
},
|
|
1963
1962
|
...options
|
|
@@ -2026,10 +2025,12 @@
|
|
|
2026
2025
|
var Margin = {
|
|
2027
2026
|
props: {
|
|
2028
2027
|
margin: String,
|
|
2028
|
+
firstRow: Boolean,
|
|
2029
2029
|
firstColumn: Boolean
|
|
2030
2030
|
},
|
|
2031
2031
|
data: {
|
|
2032
2032
|
margin: "uk-margin-small-top",
|
|
2033
|
+
firstRow: false,
|
|
2033
2034
|
firstColumn: "uk-first-column"
|
|
2034
2035
|
},
|
|
2035
2036
|
observe: [
|
|
@@ -2069,6 +2070,7 @@
|
|
|
2069
2070
|
for (const row of rows) {
|
|
2070
2071
|
for (const el of row) {
|
|
2071
2072
|
toggleClass(el, this.margin, rows[0] !== row);
|
|
2073
|
+
toggleClass(el, this.firstRow, rows[0] === row);
|
|
2072
2074
|
toggleClass(el, this.firstColumn, row[isRtl ? row.length - 1 : 0] === el);
|
|
2073
2075
|
}
|
|
2074
2076
|
}
|
|
@@ -2782,20 +2784,18 @@
|
|
|
2782
2784
|
if (show) {
|
|
2783
2785
|
_toggle(el, true);
|
|
2784
2786
|
}
|
|
2785
|
-
const prevProps =
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
|
|
2789
|
-
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
|
|
2793
|
-
|
|
2794
|
-
|
|
2795
|
-
|
|
2796
|
-
|
|
2797
|
-
].map((key) => [key, el.style[key]])
|
|
2798
|
-
);
|
|
2787
|
+
const prevProps = pick(el.style, [
|
|
2788
|
+
"padding",
|
|
2789
|
+
"border",
|
|
2790
|
+
"width",
|
|
2791
|
+
"height",
|
|
2792
|
+
"minWidth",
|
|
2793
|
+
"minHeight",
|
|
2794
|
+
"overflowY",
|
|
2795
|
+
"overflowX",
|
|
2796
|
+
marginProp,
|
|
2797
|
+
marginStartProp
|
|
2798
|
+
]);
|
|
2799
2799
|
const dim = dimensions$1(el);
|
|
2800
2800
|
const currentMargin = toFloat(css(el, marginProp));
|
|
2801
2801
|
const marginStart = toFloat(css(el, marginStartProp));
|
|
@@ -3016,12 +3016,13 @@
|
|
|
3016
3016
|
}
|
|
3017
3017
|
}
|
|
3018
3018
|
};
|
|
3019
|
+
const rejectKey = /* @__PURE__ */ Symbol();
|
|
3019
3020
|
function animate$1(el, show, { transitionElement, _toggle }) {
|
|
3020
3021
|
return new Promise(
|
|
3021
3022
|
(resolve, reject) => once(el, "show hide", () => {
|
|
3022
3023
|
var _a;
|
|
3023
|
-
(_a = el
|
|
3024
|
-
el
|
|
3024
|
+
(_a = el[rejectKey]) == null ? void 0 : _a.call(el);
|
|
3025
|
+
el[rejectKey] = reject;
|
|
3025
3026
|
_toggle(el, show);
|
|
3026
3027
|
const off = once(
|
|
3027
3028
|
transitionElement,
|
|
@@ -3042,7 +3043,7 @@
|
|
|
3042
3043
|
toMs(css(transitionElement, "transitionDuration"))
|
|
3043
3044
|
);
|
|
3044
3045
|
})
|
|
3045
|
-
).then(() => delete el
|
|
3046
|
+
).then(() => delete el[rejectKey]);
|
|
3046
3047
|
}
|
|
3047
3048
|
function toMs(time) {
|
|
3048
3049
|
return time ? endsWith(time, "ms") ? toFloat(time) : toFloat(time) * 1e3 : 0;
|
|
@@ -3092,18 +3093,11 @@
|
|
|
3092
3093
|
|
|
3093
3094
|
var Animations$2 = {
|
|
3094
3095
|
slide: {
|
|
3095
|
-
|
|
3096
|
-
|
|
3097
|
-
|
|
3098
|
-
|
|
3099
|
-
|
|
3100
|
-
},
|
|
3101
|
-
translate(percent, dir) {
|
|
3102
|
-
return [
|
|
3103
|
-
{ transform: translate(dir * -100 * percent) },
|
|
3104
|
-
{ transform: translate(dir * 100 * (1 - percent)) }
|
|
3105
|
-
];
|
|
3106
|
-
}
|
|
3096
|
+
percent: translated,
|
|
3097
|
+
translate: (percent, dir) => [
|
|
3098
|
+
{ transform: translate(dir * -100 * percent) },
|
|
3099
|
+
{ transform: translate(dir * 100 * (1 - percent)) }
|
|
3100
|
+
]
|
|
3107
3101
|
}
|
|
3108
3102
|
};
|
|
3109
3103
|
function translated(el) {
|
|
@@ -3114,8 +3108,8 @@
|
|
|
3114
3108
|
}
|
|
3115
3109
|
|
|
3116
3110
|
function Transitioner$1(prev, next, dir, { animation, easing }) {
|
|
3117
|
-
const { percent, translate
|
|
3118
|
-
const props =
|
|
3111
|
+
const { percent, translate } = animation;
|
|
3112
|
+
const props = translate(1, dir);
|
|
3119
3113
|
const { promise, resolve } = withResolvers();
|
|
3120
3114
|
return {
|
|
3121
3115
|
dir,
|
|
@@ -3396,7 +3390,7 @@
|
|
|
3396
3390
|
return Math.atan2(Math.abs(pos2.y - pos1.y), Math.abs(pos2.x - pos1.x)) * 180 / Math.PI;
|
|
3397
3391
|
}
|
|
3398
3392
|
|
|
3399
|
-
var VERSION = '3.25.18-dev.
|
|
3393
|
+
var VERSION = '3.25.18-dev.f49c4ef';
|
|
3400
3394
|
|
|
3401
3395
|
function initWatches(instance) {
|
|
3402
3396
|
instance._watches = [];
|
|
@@ -3605,7 +3599,7 @@
|
|
|
3605
3599
|
}
|
|
3606
3600
|
const getAttributes = memoize((id, props) => {
|
|
3607
3601
|
const attributes = Object.keys(props);
|
|
3608
|
-
const filter = attributes
|
|
3602
|
+
const filter = [...attributes, id].flatMap((key) => [hyphenate(key), `data-${hyphenate(key)}`]);
|
|
3609
3603
|
return { attributes, filter };
|
|
3610
3604
|
});
|
|
3611
3605
|
function initPropsObserver(instance) {
|
|
@@ -3695,14 +3689,10 @@
|
|
|
3695
3689
|
}
|
|
3696
3690
|
function normalizeData({ data = {} }, { args = [], props = {} }) {
|
|
3697
3691
|
if (isArray(data)) {
|
|
3698
|
-
data = data.slice(0, args.length).reduce(
|
|
3699
|
-
|
|
3700
|
-
|
|
3701
|
-
|
|
3702
|
-
data2[args[index]] = value;
|
|
3703
|
-
}
|
|
3704
|
-
return data2;
|
|
3705
|
-
}, {});
|
|
3692
|
+
data = data.slice(0, args.length).reduce(
|
|
3693
|
+
(data2, value, index) => assign(data2, isPlainObject(value) ? value : { [args[index]]: value }),
|
|
3694
|
+
{}
|
|
3695
|
+
);
|
|
3706
3696
|
}
|
|
3707
3697
|
for (const key in data) {
|
|
3708
3698
|
if (isUndefined(data[key])) {
|
|
@@ -3750,11 +3740,10 @@
|
|
|
3750
3740
|
function init(element2) {
|
|
3751
3741
|
const instance = getComponent(element2, name);
|
|
3752
3742
|
if (instance) {
|
|
3753
|
-
if (data) {
|
|
3754
|
-
instance.$destroy();
|
|
3755
|
-
} else {
|
|
3743
|
+
if (!data) {
|
|
3756
3744
|
return instance;
|
|
3757
3745
|
}
|
|
3746
|
+
instance.$destroy();
|
|
3758
3747
|
}
|
|
3759
3748
|
return new Component({ el: element2, data });
|
|
3760
3749
|
}
|
|
@@ -3896,7 +3885,7 @@
|
|
|
3896
3885
|
computed: {
|
|
3897
3886
|
nav: ({ selNav }, $el) => $$(selNav, $el),
|
|
3898
3887
|
navChildren() {
|
|
3899
|
-
return this.nav.
|
|
3888
|
+
return this.nav.flatMap((nav) => children(nav));
|
|
3900
3889
|
},
|
|
3901
3890
|
selNavItem: ({ attrItem }) => `[${attrItem}],[data-${attrItem}]`,
|
|
3902
3891
|
navItems(_, $el) {
|
|
@@ -4253,75 +4242,35 @@
|
|
|
4253
4242
|
var Animations$1 = {
|
|
4254
4243
|
...Animations$2,
|
|
4255
4244
|
fade: {
|
|
4256
|
-
|
|
4257
|
-
|
|
4258
|
-
},
|
|
4259
|
-
percent(current) {
|
|
4260
|
-
return 1 - css(current, "opacity");
|
|
4261
|
-
},
|
|
4262
|
-
translate(percent) {
|
|
4263
|
-
return [{ opacity: 1 - percent, zIndex: 0 }, { zIndex: -1 }];
|
|
4264
|
-
}
|
|
4245
|
+
percent: (current) => 1 - css(current, "opacity"),
|
|
4246
|
+
translate: (percent) => [{ opacity: 1 - percent, zIndex: 0 }, { zIndex: -1 }]
|
|
4265
4247
|
},
|
|
4266
4248
|
scale: {
|
|
4267
|
-
|
|
4268
|
-
|
|
4269
|
-
|
|
4270
|
-
|
|
4271
|
-
|
|
4272
|
-
},
|
|
4273
|
-
translate(percent) {
|
|
4274
|
-
return [
|
|
4275
|
-
{ opacity: 1 - percent, transform: scale3d(1 + 0.5 * percent), zIndex: 0 },
|
|
4276
|
-
{ zIndex: -1 }
|
|
4277
|
-
];
|
|
4278
|
-
}
|
|
4249
|
+
percent: (current) => 1 - css(current, "opacity"),
|
|
4250
|
+
translate: (percent) => [
|
|
4251
|
+
{ opacity: 1 - percent, transform: scale3d(1 + 0.5 * percent), zIndex: 0 },
|
|
4252
|
+
{ zIndex: -1 }
|
|
4253
|
+
]
|
|
4279
4254
|
},
|
|
4280
4255
|
pull: {
|
|
4281
|
-
|
|
4282
|
-
|
|
4283
|
-
|
|
4284
|
-
|
|
4285
|
-
|
|
4286
|
-
|
|
4287
|
-
|
|
4288
|
-
|
|
4289
|
-
},
|
|
4290
|
-
percent(current, next, dir) {
|
|
4291
|
-
return dir < 0 ? 1 - translated(next) : translated(current);
|
|
4292
|
-
},
|
|
4293
|
-
translate(percent, dir) {
|
|
4294
|
-
return dir < 0 ? [
|
|
4295
|
-
{ transform: translate(30 * percent), zIndex: -1 },
|
|
4296
|
-
{ transform: translate(-100 * (1 - percent)), zIndex: 0 }
|
|
4297
|
-
] : [
|
|
4298
|
-
{ transform: translate(-percent * 100), zIndex: 0 },
|
|
4299
|
-
{ transform: translate(30 * (1 - percent)), zIndex: -1 }
|
|
4300
|
-
];
|
|
4301
|
-
}
|
|
4256
|
+
percent: (current, next, dir) => dir < 0 ? 1 - translated(next) : translated(current),
|
|
4257
|
+
translate: (percent, dir) => dir < 0 ? [
|
|
4258
|
+
{ transform: translate(30 * percent), zIndex: -1 },
|
|
4259
|
+
{ transform: translate(-100 * (1 - percent)), zIndex: 0 }
|
|
4260
|
+
] : [
|
|
4261
|
+
{ transform: translate(-percent * 100), zIndex: 0 },
|
|
4262
|
+
{ transform: translate(30 * (1 - percent)), zIndex: -1 }
|
|
4263
|
+
]
|
|
4302
4264
|
},
|
|
4303
4265
|
push: {
|
|
4304
|
-
|
|
4305
|
-
|
|
4306
|
-
|
|
4307
|
-
|
|
4308
|
-
|
|
4309
|
-
|
|
4310
|
-
|
|
4311
|
-
|
|
4312
|
-
},
|
|
4313
|
-
percent(current, next, dir) {
|
|
4314
|
-
return dir > 0 ? 1 - translated(next) : translated(current);
|
|
4315
|
-
},
|
|
4316
|
-
translate(percent, dir) {
|
|
4317
|
-
return dir < 0 ? [
|
|
4318
|
-
{ transform: translate(percent * 100), zIndex: 0 },
|
|
4319
|
-
{ transform: translate(-30 * (1 - percent)), zIndex: -1 }
|
|
4320
|
-
] : [
|
|
4321
|
-
{ transform: translate(-30 * percent), zIndex: -1 },
|
|
4322
|
-
{ transform: translate(100 * (1 - percent)), zIndex: 0 }
|
|
4323
|
-
];
|
|
4324
|
-
}
|
|
4266
|
+
percent: (current, next, dir) => dir > 0 ? 1 - translated(next) : translated(current),
|
|
4267
|
+
translate: (percent, dir) => dir < 0 ? [
|
|
4268
|
+
{ transform: translate(percent * 100), zIndex: 0 },
|
|
4269
|
+
{ transform: translate(-30 * (1 - percent)), zIndex: -1 }
|
|
4270
|
+
] : [
|
|
4271
|
+
{ transform: translate(-30 * percent), zIndex: -1 },
|
|
4272
|
+
{ transform: translate(100 * (1 - percent)), zIndex: 0 }
|
|
4273
|
+
]
|
|
4325
4274
|
}
|
|
4326
4275
|
};
|
|
4327
4276
|
function scale3d(value) {
|
|
@@ -4331,32 +4280,15 @@
|
|
|
4331
4280
|
var Animations = {
|
|
4332
4281
|
...Animations$2,
|
|
4333
4282
|
fade: {
|
|
4334
|
-
|
|
4335
|
-
|
|
4336
|
-
},
|
|
4337
|
-
percent(current) {
|
|
4338
|
-
return 1 - css(current, "opacity");
|
|
4339
|
-
},
|
|
4340
|
-
translate(percent) {
|
|
4341
|
-
return [{ opacity: 1 - percent }, { opacity: percent }];
|
|
4342
|
-
}
|
|
4283
|
+
percent: (current) => 1 - css(current, "opacity"),
|
|
4284
|
+
translate: (percent) => [{ opacity: 1 - percent }, { opacity: percent }]
|
|
4343
4285
|
},
|
|
4344
4286
|
scale: {
|
|
4345
|
-
|
|
4346
|
-
|
|
4347
|
-
|
|
4348
|
-
|
|
4349
|
-
|
|
4350
|
-
},
|
|
4351
|
-
percent(current) {
|
|
4352
|
-
return 1 - css(current, "opacity");
|
|
4353
|
-
},
|
|
4354
|
-
translate(percent) {
|
|
4355
|
-
return [
|
|
4356
|
-
{ opacity: 1 - percent, transform: scale3d(1 - 0.2 * percent) },
|
|
4357
|
-
{ opacity: percent, transform: scale3d(1 - 0.2 + 0.2 * percent) }
|
|
4358
|
-
];
|
|
4359
|
-
}
|
|
4287
|
+
percent: (current) => 1 - css(current, "opacity"),
|
|
4288
|
+
translate: (percent) => [
|
|
4289
|
+
{ opacity: 1 - percent, transform: scale3d(1 - 0.2 * percent) },
|
|
4290
|
+
{ opacity: percent, transform: scale3d(1 - 0.2 + 0.2 * percent) }
|
|
4291
|
+
]
|
|
4360
4292
|
}
|
|
4361
4293
|
};
|
|
4362
4294
|
|
|
@@ -4539,81 +4471,22 @@
|
|
|
4539
4471
|
if (!src) {
|
|
4540
4472
|
return;
|
|
4541
4473
|
}
|
|
4542
|
-
|
|
4543
|
-
|
|
4544
|
-
|
|
4545
|
-
|
|
4546
|
-
|
|
4547
|
-
|
|
4548
|
-
|
|
4549
|
-
|
|
4550
|
-
|
|
4551
|
-
|
|
4552
|
-
|
|
4553
|
-
|
|
4554
|
-
|
|
4555
|
-
...attrs
|
|
4556
|
-
});
|
|
4557
|
-
on(img, "load", () => this.setItem(item, parent(img) || img));
|
|
4558
|
-
on(img, "error", () => this.setError(item));
|
|
4559
|
-
} else if (type === "video" || isVideo(src)) {
|
|
4560
|
-
const inline = this.videoAutoplay === "inline";
|
|
4561
|
-
const video = createEl("video", {
|
|
4562
|
-
src,
|
|
4563
|
-
playsinline: "",
|
|
4564
|
-
controls: inline ? null : "",
|
|
4565
|
-
loop: inline ? "" : null,
|
|
4566
|
-
muted: inline ? "" : null,
|
|
4567
|
-
poster: this.videoAutoplay ? null : item.poster,
|
|
4568
|
-
"uk-video": Boolean(this.videoAutoplay),
|
|
4569
|
-
...attrs
|
|
4570
|
-
});
|
|
4571
|
-
on(video, "loadedmetadata", () => this.setItem(item, video));
|
|
4572
|
-
on(video, "error", () => this.setError(item));
|
|
4573
|
-
} else if (type === "iframe" || src.match(/\.(html|php)($|\?)/i)) {
|
|
4574
|
-
this.setItem(
|
|
4575
|
-
item,
|
|
4576
|
-
createEl("iframe", {
|
|
4577
|
-
src,
|
|
4578
|
-
allowfullscreen: "",
|
|
4579
|
-
class: "uk-lightbox-iframe",
|
|
4580
|
-
...attrs
|
|
4581
|
-
})
|
|
4582
|
-
);
|
|
4583
|
-
} else if (matches2 = src.match(
|
|
4584
|
-
/\/\/(?:.*?youtube(-nocookie)?\..*?(?:[?&]v=|\/shorts\/)|youtu\.be\/)([\w-]{11})[&?]?(.*)?/
|
|
4585
|
-
)) {
|
|
4586
|
-
this.setItem(
|
|
4587
|
-
item,
|
|
4588
|
-
createEl("iframe", {
|
|
4589
|
-
src: `https://www.youtube${matches2[1] || ""}.com/embed/${matches2[2]}${matches2[3] ? `?${matches2[3]}` : ""}`,
|
|
4590
|
-
width: 1920,
|
|
4591
|
-
height: 1080,
|
|
4592
|
-
...iframeAttrs,
|
|
4593
|
-
...attrs
|
|
4594
|
-
})
|
|
4595
|
-
);
|
|
4596
|
-
} else if (matches2 = src.match(/\/\/.*?vimeo\.[a-z]+\/(\d+)[&?]?(.*)?/)) {
|
|
4597
|
-
try {
|
|
4598
|
-
const { height, width } = await (await fetch(
|
|
4599
|
-
`https://vimeo.com/api/oembed.json?maxwidth=1920&url=${encodeURI(
|
|
4600
|
-
src
|
|
4601
|
-
)}`,
|
|
4602
|
-
{ credentials: "omit" }
|
|
4603
|
-
)).json();
|
|
4604
|
-
this.setItem(
|
|
4605
|
-
item,
|
|
4606
|
-
createEl("iframe", {
|
|
4607
|
-
src: `https://player.vimeo.com/video/${matches2[1]}${matches2[2] ? `?${matches2[2]}` : ""}`,
|
|
4608
|
-
width,
|
|
4609
|
-
height,
|
|
4610
|
-
...iframeAttrs,
|
|
4611
|
-
...attrs
|
|
4612
|
-
})
|
|
4613
|
-
);
|
|
4614
|
-
} catch {
|
|
4615
|
-
this.setError(item);
|
|
4474
|
+
try {
|
|
4475
|
+
for (const loader of [
|
|
4476
|
+
loadImage,
|
|
4477
|
+
loadVideo,
|
|
4478
|
+
loadIframe,
|
|
4479
|
+
loadYouTube,
|
|
4480
|
+
loadVimeo
|
|
4481
|
+
]) {
|
|
4482
|
+
const content = await loader({ src, type, attrs, item, cmp: this });
|
|
4483
|
+
if (content) {
|
|
4484
|
+
this.setItem(item, content);
|
|
4485
|
+
return;
|
|
4486
|
+
}
|
|
4616
4487
|
}
|
|
4488
|
+
} catch {
|
|
4489
|
+
this.setError(item);
|
|
4617
4490
|
}
|
|
4618
4491
|
}
|
|
4619
4492
|
},
|
|
@@ -4673,6 +4546,91 @@
|
|
|
4673
4546
|
attr(el, attrs);
|
|
4674
4547
|
return el;
|
|
4675
4548
|
}
|
|
4549
|
+
async function loadImage({ src, type, attrs, item }) {
|
|
4550
|
+
if (type !== "image" && !isImage(src)) {
|
|
4551
|
+
return;
|
|
4552
|
+
}
|
|
4553
|
+
const img = createEl("img");
|
|
4554
|
+
wrapInPicture(img, item.sources);
|
|
4555
|
+
attr(img, {
|
|
4556
|
+
src,
|
|
4557
|
+
...pick(item, ["alt", "srcset", "sizes"]),
|
|
4558
|
+
...attrs
|
|
4559
|
+
});
|
|
4560
|
+
await img.decode();
|
|
4561
|
+
return parent(img) || img;
|
|
4562
|
+
}
|
|
4563
|
+
function loadVideo({ src, type, attrs, item, cmp }) {
|
|
4564
|
+
if (type !== "video" && !isVideo(src)) {
|
|
4565
|
+
return;
|
|
4566
|
+
}
|
|
4567
|
+
const inline = cmp.videoAutoplay === "inline";
|
|
4568
|
+
const video = createEl("video", {
|
|
4569
|
+
src,
|
|
4570
|
+
playsinline: "",
|
|
4571
|
+
controls: inline ? null : "",
|
|
4572
|
+
loop: inline ? "" : null,
|
|
4573
|
+
muted: inline ? "" : null,
|
|
4574
|
+
poster: cmp.videoAutoplay ? null : item.poster,
|
|
4575
|
+
"uk-video": Boolean(cmp.videoAutoplay),
|
|
4576
|
+
...attrs
|
|
4577
|
+
});
|
|
4578
|
+
return new Promise((resolve, reject) => {
|
|
4579
|
+
on(video, "loadedmetadata", () => resolve(video));
|
|
4580
|
+
on(video, "error", reject);
|
|
4581
|
+
});
|
|
4582
|
+
}
|
|
4583
|
+
function loadIframe({ src, type, attrs }) {
|
|
4584
|
+
if (type !== "iframe" && !/\.(html|php)($|\?)/i.test(src)) {
|
|
4585
|
+
return;
|
|
4586
|
+
}
|
|
4587
|
+
return createEl("iframe", {
|
|
4588
|
+
src,
|
|
4589
|
+
allowfullscreen: "",
|
|
4590
|
+
class: "uk-lightbox-iframe",
|
|
4591
|
+
...attrs
|
|
4592
|
+
});
|
|
4593
|
+
}
|
|
4594
|
+
function loadYouTube({ src, attrs, cmp }) {
|
|
4595
|
+
const matches2 = src.match(
|
|
4596
|
+
/\/\/(?:.*?youtube(-nocookie)?\..*?(?:[?&]v=|\/shorts\/)|youtu\.be\/)([\w-]{11})[&?]?(.*)?/
|
|
4597
|
+
);
|
|
4598
|
+
if (!matches2) {
|
|
4599
|
+
return;
|
|
4600
|
+
}
|
|
4601
|
+
return createEl("iframe", {
|
|
4602
|
+
src: `https://www.youtube${matches2[1] || ""}.com/embed/${matches2[2]}${matches2[3] ? `?${matches2[3]}` : ""}`,
|
|
4603
|
+
width: 1920,
|
|
4604
|
+
height: 1080,
|
|
4605
|
+
...getIframeAttrs(cmp),
|
|
4606
|
+
...attrs
|
|
4607
|
+
});
|
|
4608
|
+
}
|
|
4609
|
+
async function loadVimeo({ src, attrs, cmp }) {
|
|
4610
|
+
const matches2 = src.match(/\/\/.*?vimeo\.[a-z]+\/(\d+)[&?]?(.*)?/);
|
|
4611
|
+
if (!matches2) {
|
|
4612
|
+
return;
|
|
4613
|
+
}
|
|
4614
|
+
const { height, width } = await (await fetch(
|
|
4615
|
+
`https://vimeo.com/api/oembed.json?maxwidth=1920&url=${encodeURIComponent(src)}`,
|
|
4616
|
+
{ credentials: "omit" }
|
|
4617
|
+
)).json();
|
|
4618
|
+
return createEl("iframe", {
|
|
4619
|
+
src: `https://player.vimeo.com/video/${matches2[1]}${matches2[2] ? `?${matches2[2]}` : ""}`,
|
|
4620
|
+
width,
|
|
4621
|
+
height,
|
|
4622
|
+
...getIframeAttrs(cmp),
|
|
4623
|
+
...attrs
|
|
4624
|
+
});
|
|
4625
|
+
}
|
|
4626
|
+
function getIframeAttrs(cmp) {
|
|
4627
|
+
return {
|
|
4628
|
+
allowfullscreen: "",
|
|
4629
|
+
style: "max-width: 100%; box-sizing: border-box;",
|
|
4630
|
+
"uk-responsive": "",
|
|
4631
|
+
"uk-video": Boolean(cmp.videoAutoplay)
|
|
4632
|
+
};
|
|
4633
|
+
}
|
|
4676
4634
|
function toThumbnavItem(item, videoAutoplay) {
|
|
4677
4635
|
const el = item.poster || item.thumb && (item.type === "image" || isImage(item.thumb)) ? createEl("img", { src: item.poster || item.thumb, alt: "" }) : item.thumb && (item.type === "video" || isVideo(item.thumb)) ? createEl("video", {
|
|
4678
4636
|
src: item.thumb,
|
|
@@ -4758,7 +4716,7 @@
|
|
|
4758
4716
|
if (items[i].thumb) {
|
|
4759
4717
|
continue;
|
|
4760
4718
|
}
|
|
4761
|
-
const parent = parents(toggle).reverse()
|
|
4719
|
+
const parent = [...parents(toggle).reverse(), toggle].find(
|
|
4762
4720
|
(parent2) => this.$el.contains(parent2) && (parent2 === toggle || $$(this.toggle, parent2).length === 1)
|
|
4763
4721
|
);
|
|
4764
4722
|
if (!parent) {
|
|
@@ -4781,6 +4739,94 @@
|
|
|
4781
4739
|
return item;
|
|
4782
4740
|
}
|
|
4783
4741
|
|
|
4742
|
+
const hasAnimationApi = inBrowser && window.Animation;
|
|
4743
|
+
var marquee = {
|
|
4744
|
+
mixins: [Class],
|
|
4745
|
+
props: {
|
|
4746
|
+
velocity: Number,
|
|
4747
|
+
start: Number,
|
|
4748
|
+
reverse: Boolean,
|
|
4749
|
+
pause: Boolean,
|
|
4750
|
+
pauseVelocity: Number,
|
|
4751
|
+
fadeSize: null
|
|
4752
|
+
},
|
|
4753
|
+
data: {
|
|
4754
|
+
velocity: 25,
|
|
4755
|
+
start: 0,
|
|
4756
|
+
reverse: false,
|
|
4757
|
+
pause: false,
|
|
4758
|
+
pauseVelocity: 10,
|
|
4759
|
+
selList: ".uk-marquee-items",
|
|
4760
|
+
fadeSize: 0
|
|
4761
|
+
},
|
|
4762
|
+
computed: {
|
|
4763
|
+
list: ({ selList }, $el) => $(selList, $el),
|
|
4764
|
+
items() {
|
|
4765
|
+
return children(this.list);
|
|
4766
|
+
}
|
|
4767
|
+
},
|
|
4768
|
+
observe: [
|
|
4769
|
+
resize({
|
|
4770
|
+
target: ({ $el, items }) => [$el, ...items]
|
|
4771
|
+
}),
|
|
4772
|
+
intersection({
|
|
4773
|
+
handler(entries) {
|
|
4774
|
+
for (const entry of entries) {
|
|
4775
|
+
entry.target.inert = !entry.isIntersecting;
|
|
4776
|
+
}
|
|
4777
|
+
},
|
|
4778
|
+
target: ({ items }) => items,
|
|
4779
|
+
args: { intersecting: false },
|
|
4780
|
+
options: ({ $el }) => ({ root: $el })
|
|
4781
|
+
})
|
|
4782
|
+
],
|
|
4783
|
+
events: {
|
|
4784
|
+
name: [pointerEnter, pointerLeave],
|
|
4785
|
+
el: ({ $el }) => $el,
|
|
4786
|
+
self: true,
|
|
4787
|
+
filter: ({ pause }) => hasAnimationApi && pause,
|
|
4788
|
+
handler(e) {
|
|
4789
|
+
for (const el of this.items) {
|
|
4790
|
+
for (const animation of el.getAnimations()) {
|
|
4791
|
+
animation.playbackRate = e.type === pointerEnter ? this.pauseVelocity / this.velocity : 1;
|
|
4792
|
+
}
|
|
4793
|
+
}
|
|
4794
|
+
}
|
|
4795
|
+
},
|
|
4796
|
+
update: {
|
|
4797
|
+
write() {
|
|
4798
|
+
const prefix = this.$options.id;
|
|
4799
|
+
const items = this.items;
|
|
4800
|
+
const vertical = hasClass(this.$el, `${prefix}-vertical`);
|
|
4801
|
+
css(items, "offset", "none");
|
|
4802
|
+
const dir = vertical ? ["top", "bottom"] : ["left", "right"];
|
|
4803
|
+
if (!vertical && isRtl) {
|
|
4804
|
+
dir.reverse();
|
|
4805
|
+
}
|
|
4806
|
+
const listStart = dimensions$1(this.list)[dir[0]];
|
|
4807
|
+
const listEnd = Math[!vertical && isRtl ? "min" : "max"](
|
|
4808
|
+
...items.map((el) => dimensions$1(el)[dir[1]])
|
|
4809
|
+
);
|
|
4810
|
+
for (const el of items) {
|
|
4811
|
+
const elEnd = dimensions$1(el)[dir[1]];
|
|
4812
|
+
const line1 = listEnd - elEnd;
|
|
4813
|
+
const line2 = elEnd - listStart;
|
|
4814
|
+
const path = vertical ? `"M0 0 v${line1}M0 ${-line2} v${line2}"` : `"M0 0 h${line1}M${-line2} 0 h${line2}"`;
|
|
4815
|
+
css(el, `--${prefix}-path`, path);
|
|
4816
|
+
}
|
|
4817
|
+
css(this.$el, {
|
|
4818
|
+
[`--${prefix}-duration`]: `${Math.abs(listStart - listEnd) / this.velocity}s`,
|
|
4819
|
+
[`--${prefix}-start`]: this.start,
|
|
4820
|
+
[`--${prefix}-direction`]: this.reverse ? "reverse" : "normal",
|
|
4821
|
+
"--uk-overflow-fade-size": this.fadeSize ? `${toPx(this.fadeSize, vertical ? "height" : "width", this.$el, true)}px` : ""
|
|
4822
|
+
});
|
|
4823
|
+
toggleClass(this.$el, `${prefix}-fade`, this.fadeSize);
|
|
4824
|
+
css(items, "offset", "");
|
|
4825
|
+
},
|
|
4826
|
+
events: ["resize"]
|
|
4827
|
+
}
|
|
4828
|
+
};
|
|
4829
|
+
|
|
4784
4830
|
var notification = {
|
|
4785
4831
|
mixins: [Container],
|
|
4786
4832
|
functional: true,
|
|
@@ -5213,10 +5259,7 @@
|
|
|
5213
5259
|
return val;
|
|
5214
5260
|
}
|
|
5215
5261
|
function fillObject(keys2, value) {
|
|
5216
|
-
return keys2.
|
|
5217
|
-
data[prop] = value;
|
|
5218
|
-
return data;
|
|
5219
|
-
}, {});
|
|
5262
|
+
return Object.fromEntries(keys2.map((prop) => [prop, value]));
|
|
5220
5263
|
}
|
|
5221
5264
|
function ease(percent, easing) {
|
|
5222
5265
|
return easing >= 0 ? Math.pow(percent, easing + 1) : 1 - Math.pow(1 - percent, 1 - easing);
|
|
@@ -5290,16 +5333,14 @@
|
|
|
5290
5333
|
return el ? "offsetTop" in el ? el : getOffsetElement(parent(el)) : document.documentElement;
|
|
5291
5334
|
}
|
|
5292
5335
|
|
|
5293
|
-
var
|
|
5336
|
+
var ScrollDriven = {
|
|
5294
5337
|
props: {
|
|
5295
|
-
parallax: Boolean,
|
|
5296
5338
|
parallaxTarget: Boolean,
|
|
5297
5339
|
parallaxStart: String,
|
|
5298
5340
|
parallaxEnd: String,
|
|
5299
5341
|
parallaxEasing: Number
|
|
5300
5342
|
},
|
|
5301
5343
|
data: {
|
|
5302
|
-
parallax: false,
|
|
5303
5344
|
parallaxTarget: false,
|
|
5304
5345
|
parallaxStart: 0,
|
|
5305
5346
|
parallaxEnd: 0,
|
|
@@ -5313,26 +5354,48 @@
|
|
|
5313
5354
|
scroll$1({ filter: ({ parallax }) => parallax })
|
|
5314
5355
|
],
|
|
5315
5356
|
computed: {
|
|
5357
|
+
parallaxTargetFallback: ($props, $el) => $el,
|
|
5316
5358
|
parallaxTarget({ parallaxTarget }, $el) {
|
|
5317
|
-
return parallaxTarget && query(parallaxTarget, $el) || this.
|
|
5359
|
+
return parallaxTarget && query(parallaxTarget, $el) || this.parallaxTargetFallback;
|
|
5318
5360
|
}
|
|
5319
5361
|
},
|
|
5320
5362
|
update: {
|
|
5321
5363
|
read() {
|
|
5322
5364
|
if (!this.parallax) {
|
|
5323
|
-
return
|
|
5365
|
+
return;
|
|
5324
5366
|
}
|
|
5325
5367
|
const target = this.parallaxTarget;
|
|
5326
5368
|
if (!target) {
|
|
5327
|
-
return
|
|
5369
|
+
return;
|
|
5328
5370
|
}
|
|
5329
5371
|
const start = toPx(this.parallaxStart, "height", target, true);
|
|
5330
5372
|
const end = toPx(this.parallaxEnd, "height", target, true);
|
|
5331
5373
|
const percent = ease(scrolledOver(target, start, end), this.parallaxEasing);
|
|
5332
|
-
return {
|
|
5374
|
+
return { percent };
|
|
5333
5375
|
},
|
|
5334
|
-
|
|
5335
|
-
|
|
5376
|
+
events: ["scroll", "resize"]
|
|
5377
|
+
}
|
|
5378
|
+
};
|
|
5379
|
+
|
|
5380
|
+
var SliderParallax = {
|
|
5381
|
+
mixins: [ScrollDriven],
|
|
5382
|
+
props: {
|
|
5383
|
+
parallax: Boolean
|
|
5384
|
+
},
|
|
5385
|
+
data: {
|
|
5386
|
+
parallax: false
|
|
5387
|
+
},
|
|
5388
|
+
computed: {
|
|
5389
|
+
parallaxTargetFallback() {
|
|
5390
|
+
return this.list;
|
|
5391
|
+
}
|
|
5392
|
+
},
|
|
5393
|
+
update: {
|
|
5394
|
+
write({ percent }) {
|
|
5395
|
+
if (!this.parallax) {
|
|
5396
|
+
return;
|
|
5397
|
+
}
|
|
5398
|
+
const [prevIndex, slidePercent] = this.getIndexAt(percent);
|
|
5336
5399
|
const nextIndex = this.getValidIndex(prevIndex + Math.ceil(slidePercent));
|
|
5337
5400
|
const prev = this.slides[prevIndex];
|
|
5338
5401
|
const next = this.slides[nextIndex];
|
|
@@ -5632,7 +5695,7 @@
|
|
|
5632
5695
|
},
|
|
5633
5696
|
observe: [
|
|
5634
5697
|
resize({
|
|
5635
|
-
target: ({
|
|
5698
|
+
target: ({ slides, $el }) => [$el, ...slides]
|
|
5636
5699
|
}),
|
|
5637
5700
|
intersection({
|
|
5638
5701
|
handler(entries) {
|
|
@@ -5640,7 +5703,7 @@
|
|
|
5640
5703
|
target.ariaHidden = target.inert = !isIntersecting;
|
|
5641
5704
|
}
|
|
5642
5705
|
},
|
|
5643
|
-
target: ({
|
|
5706
|
+
target: ({ slides }) => slides,
|
|
5644
5707
|
args: { intersecting: false },
|
|
5645
5708
|
options: ({ $el }) => ({ root: $el, rootMargin: "0px -10px" })
|
|
5646
5709
|
})
|
|
@@ -6242,7 +6305,7 @@
|
|
|
6242
6305
|
inset: false
|
|
6243
6306
|
},
|
|
6244
6307
|
connected() {
|
|
6245
|
-
this.pos = this.$props.pos.split("-")
|
|
6308
|
+
this.pos = [...this.$props.pos.split("-"), "center"].slice(0, 2);
|
|
6246
6309
|
[this.dir, this.align] = this.pos;
|
|
6247
6310
|
this.axis = includes(["top", "bottom"], this.dir) ? "y" : "x";
|
|
6248
6311
|
},
|
|
@@ -6421,10 +6484,12 @@
|
|
|
6421
6484
|
}
|
|
6422
6485
|
function parseProps(options) {
|
|
6423
6486
|
const { el, id, data: data$1 } = options;
|
|
6424
|
-
return
|
|
6487
|
+
return {
|
|
6488
|
+
delay: data(el, "delay"),
|
|
6489
|
+
title: data(el, "title"),
|
|
6425
6490
|
...parseOptions(data(el, id), ["title"]),
|
|
6426
6491
|
...data$1
|
|
6427
|
-
}
|
|
6492
|
+
};
|
|
6428
6493
|
}
|
|
6429
6494
|
|
|
6430
6495
|
var upload = {
|
|
@@ -6643,6 +6708,7 @@
|
|
|
6643
6708
|
Filter: filter,
|
|
6644
6709
|
Lightbox: lightbox,
|
|
6645
6710
|
LightboxPanel: LightboxPanel,
|
|
6711
|
+
Marquee: marquee,
|
|
6646
6712
|
Notification: notification,
|
|
6647
6713
|
Parallax: parallax,
|
|
6648
6714
|
Slider: slider,
|
|
@@ -6726,28 +6792,76 @@
|
|
|
6726
6792
|
globalApi(App);
|
|
6727
6793
|
instanceApi(App);
|
|
6728
6794
|
|
|
6795
|
+
var Connect = {
|
|
6796
|
+
mixins: [Togglable],
|
|
6797
|
+
props: {
|
|
6798
|
+
connect: String
|
|
6799
|
+
},
|
|
6800
|
+
data: {
|
|
6801
|
+
connect: "",
|
|
6802
|
+
cls: "uk-active"
|
|
6803
|
+
},
|
|
6804
|
+
computed: {
|
|
6805
|
+
connects: {
|
|
6806
|
+
get: ({ connect }, $el) => connect ? queryAll(connect, $el) : [],
|
|
6807
|
+
observe: ({ connect }) => connect
|
|
6808
|
+
},
|
|
6809
|
+
connectChildren() {
|
|
6810
|
+
return this.connects.flatMap((el) => children(el));
|
|
6811
|
+
}
|
|
6812
|
+
},
|
|
6813
|
+
watch: {
|
|
6814
|
+
connects(connects) {
|
|
6815
|
+
for (const el of connects) {
|
|
6816
|
+
if (isTag(el, "ul")) {
|
|
6817
|
+
el.role = "presentation";
|
|
6818
|
+
}
|
|
6819
|
+
}
|
|
6820
|
+
}
|
|
6821
|
+
},
|
|
6822
|
+
observe: lazyload({ targets: ({ connectChildren }) => connectChildren }),
|
|
6823
|
+
methods: {
|
|
6824
|
+
showConnects(index, animate) {
|
|
6825
|
+
const toggle = async ({ children: children2 }) => {
|
|
6826
|
+
const actives = toArray(children2).filter(
|
|
6827
|
+
(child, i) => i !== index && hasClass(child, this.cls)
|
|
6828
|
+
);
|
|
6829
|
+
if (await this.toggleElement(actives, false, animate)) {
|
|
6830
|
+
await this.toggleElement(children2[index], true, animate);
|
|
6831
|
+
}
|
|
6832
|
+
};
|
|
6833
|
+
return Promise.all(this.connects.map(toggle));
|
|
6834
|
+
}
|
|
6835
|
+
}
|
|
6836
|
+
};
|
|
6837
|
+
|
|
6729
6838
|
var Accordion = {
|
|
6730
|
-
mixins: [Class,
|
|
6839
|
+
mixins: [Class, Connect],
|
|
6731
6840
|
props: {
|
|
6732
|
-
animation: Boolean,
|
|
6733
6841
|
targets: String,
|
|
6734
6842
|
active: null,
|
|
6735
6843
|
collapsible: Boolean,
|
|
6736
6844
|
multiple: Boolean,
|
|
6737
6845
|
toggle: String,
|
|
6738
6846
|
content: String,
|
|
6739
|
-
offset: Number
|
|
6847
|
+
offset: Number,
|
|
6848
|
+
switcherConnect: String
|
|
6740
6849
|
},
|
|
6741
6850
|
data: {
|
|
6742
6851
|
targets: "> *",
|
|
6743
6852
|
active: false,
|
|
6744
|
-
animation: true,
|
|
6853
|
+
animation: [true],
|
|
6745
6854
|
collapsible: true,
|
|
6746
6855
|
multiple: false,
|
|
6747
6856
|
clsOpen: "uk-open",
|
|
6857
|
+
cls: "uk-active",
|
|
6748
6858
|
toggle: ".uk-accordion-title",
|
|
6749
6859
|
content: ".uk-accordion-content",
|
|
6750
|
-
offset: 0
|
|
6860
|
+
offset: 0,
|
|
6861
|
+
switcherConnect: ""
|
|
6862
|
+
},
|
|
6863
|
+
beforeConnect() {
|
|
6864
|
+
this.connect = this.$props.connect = this.switcherConnect;
|
|
6751
6865
|
},
|
|
6752
6866
|
computed: {
|
|
6753
6867
|
items: ({ targets }, $el) => $$(targets, $el),
|
|
@@ -6771,6 +6885,12 @@
|
|
|
6771
6885
|
this.toggle(active, false);
|
|
6772
6886
|
}
|
|
6773
6887
|
},
|
|
6888
|
+
connectChildren() {
|
|
6889
|
+
this.showConnects(
|
|
6890
|
+
findIndex(this.items, (el) => hasClass(el, this.clsOpen)),
|
|
6891
|
+
false
|
|
6892
|
+
);
|
|
6893
|
+
},
|
|
6774
6894
|
toggles() {
|
|
6775
6895
|
this.$emit();
|
|
6776
6896
|
},
|
|
@@ -6821,43 +6941,66 @@
|
|
|
6821
6941
|
continue;
|
|
6822
6942
|
}
|
|
6823
6943
|
toggle.id = generateId(this, toggle);
|
|
6824
|
-
content.id = generateId(this, content);
|
|
6825
6944
|
const active = includes(activeItems, this.items[index2]);
|
|
6945
|
+
attr(content, {
|
|
6946
|
+
id: generateId(this, content),
|
|
6947
|
+
role: "region",
|
|
6948
|
+
"aria-labelledby": toggle.id
|
|
6949
|
+
});
|
|
6950
|
+
if (isTag(content, "ul")) {
|
|
6951
|
+
attr(children(content), "role", "presentation");
|
|
6952
|
+
}
|
|
6953
|
+
const controls = [content.id];
|
|
6954
|
+
for (const { children: children2 } of this.connects) {
|
|
6955
|
+
const item = children2[index2];
|
|
6956
|
+
if (!item) {
|
|
6957
|
+
continue;
|
|
6958
|
+
}
|
|
6959
|
+
attr(item, {
|
|
6960
|
+
id: generateId(this, item),
|
|
6961
|
+
role: "tabpanel",
|
|
6962
|
+
"aria-labelledby": toggle.id
|
|
6963
|
+
});
|
|
6964
|
+
controls.push(item.id);
|
|
6965
|
+
}
|
|
6826
6966
|
attr(toggle, {
|
|
6827
6967
|
role: isTag(toggle, "a") ? "button" : null,
|
|
6828
|
-
"aria-controls":
|
|
6968
|
+
"aria-controls": controls.join(" "),
|
|
6829
6969
|
"aria-expanded": active,
|
|
6830
6970
|
"aria-disabled": !this.collapsible && activeItems.length < 2 && active
|
|
6831
6971
|
});
|
|
6832
|
-
attr(content, { role: "region", "aria-labelledby": toggle.id });
|
|
6833
|
-
if (isTag(content, "ul")) {
|
|
6834
|
-
attr(children(content), "role", "presentation");
|
|
6835
|
-
}
|
|
6836
6972
|
}
|
|
6837
6973
|
},
|
|
6838
6974
|
methods: {
|
|
6839
|
-
toggle(item, animate) {
|
|
6840
|
-
|
|
6975
|
+
async toggle(item, animate) {
|
|
6976
|
+
animate = animate !== false;
|
|
6977
|
+
const next = getIndex(item, this.items);
|
|
6978
|
+
item = this.items[next];
|
|
6841
6979
|
let items = [item];
|
|
6842
6980
|
const activeItems = filter$1(this.items, `.${this.clsOpen}`);
|
|
6843
|
-
|
|
6844
|
-
|
|
6845
|
-
|
|
6846
|
-
|
|
6847
|
-
|
|
6848
|
-
|
|
6849
|
-
|
|
6850
|
-
|
|
6851
|
-
|
|
6852
|
-
|
|
6853
|
-
|
|
6854
|
-
|
|
6855
|
-
|
|
6856
|
-
|
|
6857
|
-
|
|
6858
|
-
|
|
6859
|
-
)
|
|
6860
|
-
|
|
6981
|
+
const isActive = includes(activeItems, item);
|
|
6982
|
+
if (isActive && !this.collapsible && activeItems.length < 2) {
|
|
6983
|
+
return;
|
|
6984
|
+
}
|
|
6985
|
+
if (!isActive && !this.multiple) {
|
|
6986
|
+
items.push(...activeItems);
|
|
6987
|
+
}
|
|
6988
|
+
const toggle = (el) => this.toggleElement(el, !includes(activeItems, el), (el2, show) => {
|
|
6989
|
+
toggleClass(el2, this.clsOpen, show);
|
|
6990
|
+
if (!animate || !this.hasAnimation) {
|
|
6991
|
+
hide($(this.content, el2), !show);
|
|
6992
|
+
return;
|
|
6993
|
+
}
|
|
6994
|
+
return transition(el2, show, this);
|
|
6995
|
+
});
|
|
6996
|
+
const hideIndex = () => {
|
|
6997
|
+
const index2 = findIndex(children(this.connects[0]), (el) => hasClass(el, this.cls));
|
|
6998
|
+
return index2 === next ? findIndex(this.items, (i) => i !== item && includes(activeItems, i)) : index2;
|
|
6999
|
+
};
|
|
7000
|
+
return Promise.all([
|
|
7001
|
+
...items.map(toggle),
|
|
7002
|
+
this.showConnects(isActive ? hideIndex() : next, animate)
|
|
7003
|
+
]);
|
|
6861
7004
|
}
|
|
6862
7005
|
}
|
|
6863
7006
|
};
|
|
@@ -6948,22 +7091,40 @@
|
|
|
6948
7091
|
);
|
|
6949
7092
|
}
|
|
6950
7093
|
|
|
7094
|
+
const loopKey = /* @__PURE__ */ Symbol();
|
|
6951
7095
|
var Video = {
|
|
7096
|
+
mixins: [ScrollDriven],
|
|
6952
7097
|
args: "autoplay",
|
|
6953
7098
|
props: {
|
|
6954
7099
|
automute: Boolean,
|
|
6955
7100
|
autoplay: Boolean,
|
|
6956
7101
|
restart: Boolean,
|
|
6957
|
-
|
|
7102
|
+
inviewMargin: String,
|
|
7103
|
+
inviewQueued: Number,
|
|
7104
|
+
hoverTarget: Boolean,
|
|
7105
|
+
hoverRewind: Number,
|
|
7106
|
+
reducedMotionTime: Number
|
|
6958
7107
|
},
|
|
6959
7108
|
data: {
|
|
6960
7109
|
automute: false,
|
|
6961
7110
|
autoplay: true,
|
|
6962
7111
|
restart: false,
|
|
6963
|
-
|
|
7112
|
+
inviewMargin: "0px",
|
|
7113
|
+
inviewQueued: 0,
|
|
7114
|
+
hoverTarget: false,
|
|
7115
|
+
hoverRewind: 0,
|
|
7116
|
+
reducedMotionTime: 0
|
|
6964
7117
|
},
|
|
6965
7118
|
beforeConnect() {
|
|
6966
7119
|
const isVideo = isTag(this.$el, "video");
|
|
7120
|
+
this.restart = isVideo && this.restart;
|
|
7121
|
+
this.parallax = isVideo && this.autoplay === "parallax";
|
|
7122
|
+
this.manualControl = ["hover", "parallax"].includes(this.autoplay);
|
|
7123
|
+
this.inviewQueued = this.autoplay === "inview" && this.inviewQueued;
|
|
7124
|
+
if (this.inviewQueued) {
|
|
7125
|
+
this.$el[loopKey] = this.$el.loop;
|
|
7126
|
+
this.$el.loop = false;
|
|
7127
|
+
}
|
|
6967
7128
|
if (this.autoplay === "inview" && isVideo && !hasAttr(this.$el, "preload")) {
|
|
6968
7129
|
this.$el.preload = "none";
|
|
6969
7130
|
}
|
|
@@ -6972,7 +7133,10 @@
|
|
|
6972
7133
|
}
|
|
6973
7134
|
if (this.autoplay === "hover") {
|
|
6974
7135
|
if (isVideo) {
|
|
6975
|
-
this
|
|
7136
|
+
this.hoverTarget = query(this.hoverTarget, this.$el) || this.$el;
|
|
7137
|
+
if (!isFocusable(this.hoverTarget)) {
|
|
7138
|
+
this.hoverTarget.tabIndex = 0;
|
|
7139
|
+
}
|
|
6976
7140
|
} else {
|
|
6977
7141
|
this.autoplay = true;
|
|
6978
7142
|
}
|
|
@@ -6981,27 +7145,48 @@
|
|
|
6981
7145
|
mute(this.$el);
|
|
6982
7146
|
}
|
|
6983
7147
|
},
|
|
7148
|
+
disconnected() {
|
|
7149
|
+
if (this.$el[loopKey]) {
|
|
7150
|
+
this.$el.loop = true;
|
|
7151
|
+
}
|
|
7152
|
+
queue.delete(this.$el);
|
|
7153
|
+
},
|
|
6984
7154
|
events: [
|
|
6985
7155
|
{
|
|
6986
7156
|
name: `${pointerEnter} focusin`,
|
|
6987
|
-
el: ({ hoverTarget
|
|
7157
|
+
el: ({ hoverTarget }) => hoverTarget,
|
|
6988
7158
|
filter: ({ autoplay }) => autoplay === "hover",
|
|
6989
7159
|
handler(e) {
|
|
7160
|
+
var _a;
|
|
7161
|
+
(_a = this._reverseAbort) == null ? void 0 : _a.abort();
|
|
6990
7162
|
if (!isTouch(e) || !isPlaying(this.$el)) {
|
|
6991
|
-
play(
|
|
7163
|
+
this.play();
|
|
6992
7164
|
} else {
|
|
6993
|
-
|
|
7165
|
+
this.pause();
|
|
6994
7166
|
}
|
|
6995
7167
|
}
|
|
6996
7168
|
},
|
|
6997
7169
|
{
|
|
6998
7170
|
name: `${pointerLeave} focusout`,
|
|
6999
|
-
el: ({ hoverTarget
|
|
7171
|
+
el: ({ hoverTarget }) => hoverTarget,
|
|
7000
7172
|
filter: ({ autoplay }) => autoplay === "hover",
|
|
7001
7173
|
handler(e) {
|
|
7174
|
+
var _a;
|
|
7002
7175
|
if (!isTouch(e)) {
|
|
7003
|
-
|
|
7176
|
+
(_a = this._reverseAbort) == null ? void 0 : _a.abort();
|
|
7177
|
+
this.pause();
|
|
7178
|
+
this._reverseAbort = playReverse(this.$el, this.hoverRewind);
|
|
7179
|
+
}
|
|
7180
|
+
}
|
|
7181
|
+
},
|
|
7182
|
+
{
|
|
7183
|
+
name: "error pause ended",
|
|
7184
|
+
filter: ({ inviewQueued }) => inviewQueued,
|
|
7185
|
+
handler(e) {
|
|
7186
|
+
if (e.type === "error" || e.type === "ended" && !this.$el[loopKey]) {
|
|
7187
|
+
queue.delete(this.$el);
|
|
7004
7188
|
}
|
|
7189
|
+
playNextQueued();
|
|
7005
7190
|
}
|
|
7006
7191
|
}
|
|
7007
7192
|
],
|
|
@@ -7014,33 +7199,118 @@
|
|
|
7014
7199
|
}
|
|
7015
7200
|
}),
|
|
7016
7201
|
intersection({
|
|
7017
|
-
filter: ({ $el,
|
|
7018
|
-
handler([{ isIntersecting
|
|
7202
|
+
filter: ({ $el, manualControl }) => !manualControl && $el.preload !== "none",
|
|
7203
|
+
handler([{ isIntersecting }]) {
|
|
7019
7204
|
if (!document.fullscreenElement) {
|
|
7020
7205
|
if (isIntersecting) {
|
|
7021
7206
|
if (this.autoplay) {
|
|
7022
|
-
|
|
7207
|
+
this._autoplay();
|
|
7023
7208
|
}
|
|
7024
7209
|
} else {
|
|
7025
|
-
|
|
7210
|
+
this.pause();
|
|
7026
7211
|
}
|
|
7027
7212
|
}
|
|
7028
7213
|
},
|
|
7029
7214
|
args: { intersecting: false },
|
|
7030
|
-
options: ({ $el, autoplay }) => ({
|
|
7031
|
-
root: autoplay === "inview" ? null : parent($el).closest(":not(a)")
|
|
7215
|
+
options: ({ $el, autoplay, inviewMargin }) => ({
|
|
7216
|
+
root: autoplay === "inview" ? null : parent($el).closest(":not(a)"),
|
|
7217
|
+
rootMargin: autoplay === "inview" ? inviewMargin : "0px"
|
|
7032
7218
|
})
|
|
7033
7219
|
})
|
|
7034
|
-
]
|
|
7220
|
+
],
|
|
7221
|
+
update: {
|
|
7222
|
+
write({ percent }) {
|
|
7223
|
+
if (!this.parallax) {
|
|
7224
|
+
return;
|
|
7225
|
+
}
|
|
7226
|
+
const { duration, seeking } = this.$el;
|
|
7227
|
+
if (!isNaN(duration) && !seeking) {
|
|
7228
|
+
this.$el.currentTime = percent * duration;
|
|
7229
|
+
}
|
|
7230
|
+
},
|
|
7231
|
+
events: ["scroll", "resize"]
|
|
7232
|
+
},
|
|
7233
|
+
methods: {
|
|
7234
|
+
_autoplay() {
|
|
7235
|
+
if (window.matchMedia("(prefers-reduced-motion: reduce)").matches) {
|
|
7236
|
+
this.pause();
|
|
7237
|
+
if (isTag(this.$el, "video")) {
|
|
7238
|
+
this.$el.currentTime = this.reducedMotionTime;
|
|
7239
|
+
}
|
|
7240
|
+
} else {
|
|
7241
|
+
this.play();
|
|
7242
|
+
}
|
|
7243
|
+
},
|
|
7244
|
+
play() {
|
|
7245
|
+
if (this.inviewQueued) {
|
|
7246
|
+
queue.set(this.$el, this.inviewQueued);
|
|
7247
|
+
playNextQueued();
|
|
7248
|
+
} else {
|
|
7249
|
+
play(this.$el);
|
|
7250
|
+
}
|
|
7251
|
+
},
|
|
7252
|
+
pause() {
|
|
7253
|
+
pause(this.$el);
|
|
7254
|
+
queue.delete(this.$el);
|
|
7255
|
+
if (this.restart) {
|
|
7256
|
+
this.$el.currentTime = 0;
|
|
7257
|
+
}
|
|
7258
|
+
}
|
|
7259
|
+
}
|
|
7035
7260
|
};
|
|
7036
7261
|
function isPlaying(videoEl) {
|
|
7037
7262
|
return !videoEl.paused && !videoEl.ended;
|
|
7038
7263
|
}
|
|
7039
|
-
|
|
7040
|
-
|
|
7041
|
-
|
|
7042
|
-
|
|
7264
|
+
const queue = /* @__PURE__ */ new Map();
|
|
7265
|
+
const played = /* @__PURE__ */ new WeakMap();
|
|
7266
|
+
let frame;
|
|
7267
|
+
async function playNextQueued() {
|
|
7268
|
+
cancelAnimationFrame(frame);
|
|
7269
|
+
await new Promise((resolve) => frame = requestAnimationFrame(resolve));
|
|
7270
|
+
const getPlayed = (el) => {
|
|
7271
|
+
var _a;
|
|
7272
|
+
return (_a = played.get(el)) != null ? _a : 0;
|
|
7273
|
+
};
|
|
7274
|
+
const videos = shuffle(queue.keys()).sort((a, b) => getPlayed(a) - getPlayed(b));
|
|
7275
|
+
for (const el of videos) {
|
|
7276
|
+
const maxQueued = queue.get(el);
|
|
7277
|
+
if (isPlaying(el) || videos.filter(isPlaying).length / queue.size >= maxQueued) {
|
|
7278
|
+
continue;
|
|
7279
|
+
}
|
|
7280
|
+
played.set(el, getPlayed(el) + 1);
|
|
7281
|
+
play(el);
|
|
7282
|
+
}
|
|
7283
|
+
}
|
|
7284
|
+
function shuffle(array) {
|
|
7285
|
+
array = [...array];
|
|
7286
|
+
for (let i = array.length - 1; i > 0; i--) {
|
|
7287
|
+
let j = Math.floor(Math.random() * (i + 1));
|
|
7288
|
+
[array[i], array[j]] = [array[j], array[i]];
|
|
7043
7289
|
}
|
|
7290
|
+
return array;
|
|
7291
|
+
}
|
|
7292
|
+
function playReverse(el, playbackRate) {
|
|
7293
|
+
const start = el.currentTime;
|
|
7294
|
+
if (isNaN(start) || !playbackRate) {
|
|
7295
|
+
return;
|
|
7296
|
+
}
|
|
7297
|
+
playbackRate *= Math.max(1, start / 10 + 0.5);
|
|
7298
|
+
const controller = new AbortController();
|
|
7299
|
+
const time = Date.now();
|
|
7300
|
+
(function next() {
|
|
7301
|
+
requestAnimationFrame(() => {
|
|
7302
|
+
if (controller.signal.aborted) {
|
|
7303
|
+
return;
|
|
7304
|
+
}
|
|
7305
|
+
if (!el.seeking) {
|
|
7306
|
+
el.currentTime = Math.max(0, start - (Date.now() - time) * playbackRate / 1e3);
|
|
7307
|
+
}
|
|
7308
|
+
if (el.currentTime > 0) {
|
|
7309
|
+
next();
|
|
7310
|
+
}
|
|
7311
|
+
});
|
|
7312
|
+
})();
|
|
7313
|
+
return controller;
|
|
7044
7314
|
}
|
|
7045
7315
|
|
|
7046
7316
|
var cover = {
|
|
@@ -7358,6 +7628,7 @@
|
|
|
7358
7628
|
css(this.$el, this._style);
|
|
7359
7629
|
this.$el.hidden = true;
|
|
7360
7630
|
const viewports = this.target.map((target) => getViewport$1(this.$el, target));
|
|
7631
|
+
const boundaryOffsets = this.boundary.map((el) => offset(el));
|
|
7361
7632
|
const viewportOffset = this.getViewportOffset(this.$el);
|
|
7362
7633
|
const dirs = [
|
|
7363
7634
|
[0, ["x", "width", "left", "right"]],
|
|
@@ -7367,7 +7638,7 @@
|
|
|
7367
7638
|
if (this.axis !== axis && includes([axis, true], this.stretch)) {
|
|
7368
7639
|
css(this.$el, {
|
|
7369
7640
|
[prop]: Math.min(
|
|
7370
|
-
|
|
7641
|
+
boundaryOffsets[i][prop],
|
|
7371
7642
|
viewports[i][prop] - 2 * viewportOffset
|
|
7372
7643
|
),
|
|
7373
7644
|
[`overflow-${axis}`]: "auto"
|
|
@@ -7389,10 +7660,10 @@
|
|
|
7389
7660
|
const elOffset = offset(this.$el);
|
|
7390
7661
|
css(this.$el, {
|
|
7391
7662
|
[prop]: (targetOffset[start] > elOffset[start] ? targetOffset[this.inset ? end : start] - Math.max(
|
|
7392
|
-
|
|
7663
|
+
boundaryOffsets[i][start],
|
|
7393
7664
|
viewports[i][start] + viewportOffset
|
|
7394
7665
|
) : Math.min(
|
|
7395
|
-
|
|
7666
|
+
boundaryOffsets[i][end],
|
|
7396
7667
|
viewports[i][end] - viewportOffset
|
|
7397
7668
|
) - targetOffset[this.inset ? start : end]) - positionOffset,
|
|
7398
7669
|
[`overflow-${axis}`]: "auto"
|
|
@@ -7421,7 +7692,7 @@
|
|
|
7421
7692
|
observeViewportResize(update),
|
|
7422
7693
|
observeResize(overflowParents(drop.$el).concat(drop.target), update)
|
|
7423
7694
|
];
|
|
7424
|
-
return () => off.
|
|
7695
|
+
return () => off.forEach((observer) => observer.disconnect());
|
|
7425
7696
|
}
|
|
7426
7697
|
function listenForScroll(drop, fn = () => drop.$emit()) {
|
|
7427
7698
|
return on([document, ...overflowParents(drop.$el)], "scroll", fn, {
|
|
@@ -7656,7 +7927,9 @@
|
|
|
7656
7927
|
const drop = this.getDropdown(target);
|
|
7657
7928
|
const adjustHeight = () => {
|
|
7658
7929
|
const maxBottom = Math.max(
|
|
7659
|
-
...parents(target, `.${this.clsDrop}`)
|
|
7930
|
+
...[...parents(target, `.${this.clsDrop}`), target].map(
|
|
7931
|
+
(el) => offset(el).bottom
|
|
7932
|
+
)
|
|
7660
7933
|
);
|
|
7661
7934
|
offset(this.dropbar, {
|
|
7662
7935
|
left: offset(this.dropbar).left,
|
|
@@ -7845,7 +8118,8 @@
|
|
|
7845
8118
|
parallaxJustify: Boolean
|
|
7846
8119
|
},
|
|
7847
8120
|
data: {
|
|
7848
|
-
margin: "
|
|
8121
|
+
margin: "",
|
|
8122
|
+
firstRow: "uk-first-row",
|
|
7849
8123
|
clsStack: "uk-grid-stack",
|
|
7850
8124
|
masonry: false,
|
|
7851
8125
|
parallax: 0,
|
|
@@ -7867,14 +8141,14 @@
|
|
|
7867
8141
|
{
|
|
7868
8142
|
read(data) {
|
|
7869
8143
|
const { rows } = data;
|
|
7870
|
-
let { masonry, parallax, parallaxJustify
|
|
8144
|
+
let { masonry, parallax, parallaxJustify } = this;
|
|
7871
8145
|
parallax = Math.max(0, toPx(parallax));
|
|
7872
8146
|
if (!(masonry || parallax || parallaxJustify) || positionedAbsolute(rows) || rows[0].some(
|
|
7873
8147
|
(el, i) => rows.some((row) => row[i] && row[i].offsetWidth !== el.offsetWidth)
|
|
7874
8148
|
)) {
|
|
7875
8149
|
return data.translates = data.scrollColumns = false;
|
|
7876
8150
|
}
|
|
7877
|
-
let gutter =
|
|
8151
|
+
let gutter = toFloat(css(this.$el, "row-gap"));
|
|
7878
8152
|
let columns;
|
|
7879
8153
|
let translates;
|
|
7880
8154
|
if (masonry) {
|
|
@@ -7967,10 +8241,6 @@
|
|
|
7967
8241
|
}
|
|
7968
8242
|
return [columns, translates];
|
|
7969
8243
|
}
|
|
7970
|
-
function getGutter(rows, cls) {
|
|
7971
|
-
const node = rows.flat().find((el) => hasClass(el, cls));
|
|
7972
|
-
return toFloat(node ? css(node, "marginTop") : css(rows[0][0], "paddingLeft"));
|
|
7973
|
-
}
|
|
7974
8244
|
function transpose(rows) {
|
|
7975
8245
|
const columns = [];
|
|
7976
8246
|
for (const row of rows) {
|
|
@@ -8001,7 +8271,7 @@
|
|
|
8001
8271
|
elements: ({ target }, $el) => $$(target, $el)
|
|
8002
8272
|
},
|
|
8003
8273
|
observe: resize({
|
|
8004
|
-
target: ({ $el, elements }) => elements.
|
|
8274
|
+
target: ({ $el, elements }) => [$el, ...elements.flatMap((el) => [el, ...el.children])]
|
|
8005
8275
|
}),
|
|
8006
8276
|
events: {
|
|
8007
8277
|
// Hidden elements may change height when fonts load
|
|
@@ -9010,11 +9280,11 @@
|
|
|
9010
9280
|
],
|
|
9011
9281
|
update: {
|
|
9012
9282
|
read() {
|
|
9013
|
-
|
|
9014
|
-
|
|
9015
|
-
|
|
9016
|
-
|
|
9017
|
-
|
|
9283
|
+
return {
|
|
9284
|
+
overflow: ["Width", "Height"].map(
|
|
9285
|
+
(prop) => this.$el[`scroll${prop}`] - this.$el[`client${prop}`]
|
|
9286
|
+
)
|
|
9287
|
+
};
|
|
9018
9288
|
},
|
|
9019
9289
|
write({ overflow }) {
|
|
9020
9290
|
for (let i = 0; i < 2; i++) {
|
|
@@ -9645,7 +9915,7 @@
|
|
|
9645
9915
|
if (!value) {
|
|
9646
9916
|
return 0;
|
|
9647
9917
|
}
|
|
9648
|
-
if (isNumeric(value) || isString(value) &&
|
|
9918
|
+
if (isNumeric(value) || isString(value) && /^-?\d/.test(value)) {
|
|
9649
9919
|
return propOffset + toPx(value, "height", el, true);
|
|
9650
9920
|
} else {
|
|
9651
9921
|
const refElement = value === true ? getVisibleParent(el) : query(value, el);
|
|
@@ -9760,10 +10030,9 @@
|
|
|
9760
10030
|
|
|
9761
10031
|
const selDisabled = ".uk-disabled *, .uk-disabled, [disabled]";
|
|
9762
10032
|
var Switcher = {
|
|
9763
|
-
mixins: [
|
|
10033
|
+
mixins: [Connect],
|
|
9764
10034
|
args: "connect",
|
|
9765
10035
|
props: {
|
|
9766
|
-
connect: String,
|
|
9767
10036
|
toggle: String,
|
|
9768
10037
|
itemNav: String,
|
|
9769
10038
|
active: Number,
|
|
@@ -9775,20 +10044,12 @@
|
|
|
9775
10044
|
toggle: "> * > :first-child",
|
|
9776
10045
|
itemNav: false,
|
|
9777
10046
|
active: 0,
|
|
9778
|
-
cls: "uk-active",
|
|
9779
10047
|
attrItem: "uk-switcher-item",
|
|
9780
10048
|
selVertical: ".uk-nav",
|
|
9781
10049
|
followFocus: false,
|
|
9782
10050
|
swiping: true
|
|
9783
10051
|
},
|
|
9784
10052
|
computed: {
|
|
9785
|
-
connects: {
|
|
9786
|
-
get: ({ connect }, $el) => queryAll(connect, $el),
|
|
9787
|
-
observe: ({ connect }) => connect
|
|
9788
|
-
},
|
|
9789
|
-
connectChildren() {
|
|
9790
|
-
return this.connects.map((el) => children(el)).flat();
|
|
9791
|
-
},
|
|
9792
10053
|
toggles: ({ toggle }, $el) => $$(toggle, $el),
|
|
9793
10054
|
children(_, $el) {
|
|
9794
10055
|
return children($el).filter(
|
|
@@ -9819,10 +10080,7 @@
|
|
|
9819
10080
|
connected() {
|
|
9820
10081
|
this.$el.role = "tablist";
|
|
9821
10082
|
},
|
|
9822
|
-
observe:
|
|
9823
|
-
lazyload({ targets: ({ connectChildren }) => connectChildren }),
|
|
9824
|
-
swipe({ target: ({ connects }) => connects, filter: ({ swiping }) => swiping })
|
|
9825
|
-
],
|
|
10083
|
+
observe: swipe({ target: ({ connects }) => connects, filter: ({ swiping }) => swiping }),
|
|
9826
10084
|
events: [
|
|
9827
10085
|
{
|
|
9828
10086
|
name: "click keydown",
|
|
@@ -9872,24 +10130,27 @@
|
|
|
9872
10130
|
}
|
|
9873
10131
|
],
|
|
9874
10132
|
update() {
|
|
9875
|
-
var _a;
|
|
9876
|
-
for (const el of this.connects) {
|
|
9877
|
-
if (isTag(el, "ul")) {
|
|
9878
|
-
el.role = "presentation";
|
|
9879
|
-
}
|
|
9880
|
-
}
|
|
9881
10133
|
attr(children(this.$el), "role", "presentation");
|
|
9882
10134
|
for (const index in this.toggles) {
|
|
9883
10135
|
const toggle = this.toggles[index];
|
|
9884
|
-
const item = (_a = this.connects[0]) == null ? void 0 : _a.children[index];
|
|
9885
|
-
toggle.role = "tab";
|
|
9886
|
-
if (!item) {
|
|
9887
|
-
continue;
|
|
9888
|
-
}
|
|
9889
10136
|
toggle.id = generateId(this, toggle);
|
|
9890
|
-
|
|
9891
|
-
|
|
9892
|
-
|
|
10137
|
+
const controls = [];
|
|
10138
|
+
for (const { children: children2 } of this.connects) {
|
|
10139
|
+
const item = children2[index];
|
|
10140
|
+
if (!item) {
|
|
10141
|
+
continue;
|
|
10142
|
+
}
|
|
10143
|
+
attr(item, {
|
|
10144
|
+
id: generateId(this, item),
|
|
10145
|
+
role: "tabpanel",
|
|
10146
|
+
"aria-labelledby": toggle.id
|
|
10147
|
+
});
|
|
10148
|
+
controls.push(item.id);
|
|
10149
|
+
}
|
|
10150
|
+
attr(toggle, {
|
|
10151
|
+
role: "tab",
|
|
10152
|
+
"aria-controls": controls.join(" ")
|
|
10153
|
+
});
|
|
9893
10154
|
}
|
|
9894
10155
|
attr(this.$el, "aria-orientation", matches(this.$el, this.selVertical) ? "vertical" : null);
|
|
9895
10156
|
},
|
|
@@ -9922,15 +10183,7 @@
|
|
|
9922
10183
|
tabindex: next === i ? null : -1
|
|
9923
10184
|
});
|
|
9924
10185
|
});
|
|
9925
|
-
|
|
9926
|
-
this.connects.forEach(async ({ children: children2 }) => {
|
|
9927
|
-
const actives = toArray(children2).filter(
|
|
9928
|
-
(child, i) => i !== next && hasClass(child, this.cls)
|
|
9929
|
-
);
|
|
9930
|
-
if (await this.toggleElement(actives, false, animate)) {
|
|
9931
|
-
await this.toggleElement(children2[next], true, animate);
|
|
9932
|
-
}
|
|
9933
|
-
});
|
|
10186
|
+
return this.showConnects(next, prev >= 0 && prev !== next);
|
|
9934
10187
|
}
|
|
9935
10188
|
}
|
|
9936
10189
|
};
|