uikit 3.19.5-dev.57ec46163 → 3.19.5-dev.5db24934f

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/dist/css/uikit-core-rtl.css +2 -2
  3. package/dist/css/uikit-core-rtl.min.css +1 -1
  4. package/dist/css/uikit-core.css +2 -2
  5. package/dist/css/uikit-core.min.css +1 -1
  6. package/dist/css/uikit-rtl.css +2 -2
  7. package/dist/css/uikit-rtl.min.css +1 -1
  8. package/dist/css/uikit.css +2 -2
  9. package/dist/css/uikit.min.css +1 -1
  10. package/dist/js/components/countdown.js +1 -1
  11. package/dist/js/components/countdown.min.js +1 -1
  12. package/dist/js/components/filter.js +2 -2
  13. package/dist/js/components/filter.min.js +1 -1
  14. package/dist/js/components/lightbox-panel.js +55 -55
  15. package/dist/js/components/lightbox-panel.min.js +1 -1
  16. package/dist/js/components/lightbox.js +55 -55
  17. package/dist/js/components/lightbox.min.js +1 -1
  18. package/dist/js/components/notification.js +1 -1
  19. package/dist/js/components/notification.min.js +1 -1
  20. package/dist/js/components/parallax.js +73 -48
  21. package/dist/js/components/parallax.min.js +1 -1
  22. package/dist/js/components/slider-parallax.js +74 -49
  23. package/dist/js/components/slider-parallax.min.js +1 -1
  24. package/dist/js/components/slider.js +75 -51
  25. package/dist/js/components/slider.min.js +1 -1
  26. package/dist/js/components/slideshow-parallax.js +74 -49
  27. package/dist/js/components/slideshow-parallax.min.js +1 -1
  28. package/dist/js/components/slideshow.js +74 -49
  29. package/dist/js/components/slideshow.min.js +1 -1
  30. package/dist/js/components/sortable.js +2 -2
  31. package/dist/js/components/sortable.min.js +1 -1
  32. package/dist/js/components/tooltip.js +1 -1
  33. package/dist/js/components/tooltip.min.js +1 -1
  34. package/dist/js/components/upload.js +1 -1
  35. package/dist/js/components/upload.min.js +1 -1
  36. package/dist/js/uikit-core.js +170 -112
  37. package/dist/js/uikit-core.min.js +1 -1
  38. package/dist/js/uikit-icons.js +1 -1
  39. package/dist/js/uikit-icons.min.js +1 -1
  40. package/dist/js/uikit.js +179 -119
  41. package/dist/js/uikit.min.js +1 -1
  42. package/package.json +1 -1
  43. package/src/js/api/boot.js +6 -7
  44. package/src/js/api/component.js +4 -4
  45. package/src/js/api/computed.js +24 -23
  46. package/src/js/api/observer.js +17 -5
  47. package/src/js/components/slider-parallax.js +2 -2
  48. package/src/js/components/slider.js +1 -1
  49. package/src/js/core/drop.js +1 -2
  50. package/src/js/core/height-placeholder.js +5 -2
  51. package/src/js/core/height-viewport.js +1 -1
  52. package/src/js/core/icon.js +2 -3
  53. package/src/js/core/img.js +1 -1
  54. package/src/js/core/inverse.js +22 -5
  55. package/src/js/core/modal.js +5 -6
  56. package/src/js/core/sticky.js +1 -1
  57. package/src/js/core/switcher.js +5 -1
  58. package/src/js/core/toggle.js +7 -3
  59. package/src/js/mixin/internal/animate-fade.js +1 -3
  60. package/src/js/mixin/parallax.js +7 -3
  61. package/src/js/mixin/slider.js +0 -3
  62. package/src/js/mixin/slideshow.js +3 -0
  63. package/src/js/util/filter.js +7 -14
  64. package/src/js/util/lang.js +1 -1
  65. package/src/js/util/selector.js +71 -38
  66. package/src/js/util/svg.js +1 -12
  67. package/src/less/components/utility.less +1 -1
  68. package/src/scss/components/utility.scss +1 -1
  69. package/tests/js/index.js +12 -10
  70. package/tests/modal.html +2 -2
@@ -1,4 +1,4 @@
1
- /*! UIkit 3.19.5-dev.57ec46163 | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */
1
+ /*! UIkit 3.19.5-dev.5db24934f | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */
2
2
 
3
3
  (function (global, factory) {
4
4
  typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('uikit-util')) :
@@ -1 +1 @@
1
- /*! UIkit 3.19.5-dev.57ec46163 | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */(function(t,o){typeof exports=="object"&&typeof module<"u"?module.exports=o(require("uikit-util")):typeof define=="function"&&define.amd?define("uikitnotification",["uikit-util"],o):(t=typeof globalThis<"u"?globalThis:t||self,t.UIkitNotification=o(t.UIkit.util))})(this,function(t){"use strict";var o={props:{container:Boolean},data:{container:!0},computed:{container({container:s}){return s===!0&&this.$container||s&&t.$(s)}}},r={mixins:[o],functional:!0,args:["message","status"],data:{message:"",status:"",timeout:5e3,group:"",pos:"top-center",clsContainer:"uk-notification",clsClose:"uk-notification-close",clsMsg:"uk-notification-message"},install:c,computed:{marginProp:({pos:s})=>`margin-${s.match(/[a-z]+(?=-)/)[0]}`,startProps(){return{opacity:0,[this.marginProp]:-this.$el.offsetHeight}}},created(){const s=`${this.clsContainer}-${this.pos}`,e=`data-${this.clsContainer}-container`,i=t.$(`.${s}[${e}]`,this.container)||t.append(this.container,`<div class="${this.clsContainer} ${s}" ${e}></div>`);this.$mount(t.append(i,`<div class="${this.clsMsg}${this.status?` ${this.clsMsg}-${this.status}`:""}" role="alert"> <a href class="${this.clsClose}" data-uk-close></a> <div>${this.message}</div> </div>`))},async connected(){const s=t.toFloat(t.css(this.$el,this.marginProp));await t.Transition.start(t.css(this.$el,this.startProps),{opacity:1,[this.marginProp]:s}),this.timeout&&(this.timer=setTimeout(this.close,this.timeout))},events:{click(s){s.target.closest('a[href="#"],a[href=""]')&&s.preventDefault(),this.close()},[t.pointerEnter](){this.timer&&clearTimeout(this.timer)},[t.pointerLeave](){this.timeout&&(this.timer=setTimeout(this.close,this.timeout))}},methods:{async close(s){const e=i=>{const n=t.parent(i);t.trigger(i,"close",[this]),t.remove(i),n!=null&&n.hasChildNodes()||t.remove(n)};this.timer&&clearTimeout(this.timer),s||await t.Transition.start(this.$el,this.startProps),e(this.$el)}}};function c(s){s.notification.closeAll=function(e,i){t.apply(document.body,n=>{const a=s.getComponent(n,"notification");a&&(!e||e===a.group)&&a.close(i)})}}return typeof window<"u"&&window.UIkit&&window.UIkit.component("notification",r),r});
1
+ /*! UIkit 3.19.5-dev.5db24934f | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */(function(t,o){typeof exports=="object"&&typeof module<"u"?module.exports=o(require("uikit-util")):typeof define=="function"&&define.amd?define("uikitnotification",["uikit-util"],o):(t=typeof globalThis<"u"?globalThis:t||self,t.UIkitNotification=o(t.UIkit.util))})(this,function(t){"use strict";var o={props:{container:Boolean},data:{container:!0},computed:{container({container:s}){return s===!0&&this.$container||s&&t.$(s)}}},r={mixins:[o],functional:!0,args:["message","status"],data:{message:"",status:"",timeout:5e3,group:"",pos:"top-center",clsContainer:"uk-notification",clsClose:"uk-notification-close",clsMsg:"uk-notification-message"},install:c,computed:{marginProp:({pos:s})=>`margin-${s.match(/[a-z]+(?=-)/)[0]}`,startProps(){return{opacity:0,[this.marginProp]:-this.$el.offsetHeight}}},created(){const s=`${this.clsContainer}-${this.pos}`,e=`data-${this.clsContainer}-container`,i=t.$(`.${s}[${e}]`,this.container)||t.append(this.container,`<div class="${this.clsContainer} ${s}" ${e}></div>`);this.$mount(t.append(i,`<div class="${this.clsMsg}${this.status?` ${this.clsMsg}-${this.status}`:""}" role="alert"> <a href class="${this.clsClose}" data-uk-close></a> <div>${this.message}</div> </div>`))},async connected(){const s=t.toFloat(t.css(this.$el,this.marginProp));await t.Transition.start(t.css(this.$el,this.startProps),{opacity:1,[this.marginProp]:s}),this.timeout&&(this.timer=setTimeout(this.close,this.timeout))},events:{click(s){s.target.closest('a[href="#"],a[href=""]')&&s.preventDefault(),this.close()},[t.pointerEnter](){this.timer&&clearTimeout(this.timer)},[t.pointerLeave](){this.timeout&&(this.timer=setTimeout(this.close,this.timeout))}},methods:{async close(s){const e=i=>{const n=t.parent(i);t.trigger(i,"close",[this]),t.remove(i),n!=null&&n.hasChildNodes()||t.remove(n)};this.timer&&clearTimeout(this.timer),s||await t.Transition.start(this.$el,this.startProps),e(this.$el)}}};function c(s){s.notification.closeAll=function(e,i){t.apply(document.body,n=>{const a=s.getComponent(n,"notification");a&&(!e||e===a.group)&&a.close(i)})}}return typeof window<"u"&&window.UIkit&&window.UIkit.component("notification",r),r});
@@ -1,4 +1,4 @@
1
- /*! UIkit 3.19.5-dev.57ec46163 | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */
1
+ /*! UIkit 3.19.5-dev.5db24934f | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */
2
2
 
3
3
  (function (global, factory) {
4
4
  typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('uikit-util')) :
@@ -147,7 +147,7 @@
147
147
  return value === void 0;
148
148
  }
149
149
  function toNode(element) {
150
- return toNodes(element)[0];
150
+ return element && toNodes(element)[0];
151
151
  }
152
152
  function toNodes(element) {
153
153
  return isNode(element) ? [element] : Array.from(element || []).filter(isNode);
@@ -206,52 +206,83 @@
206
206
  function findAll(selector, context) {
207
207
  return toNodes(_query(selector, toNode(context), "querySelectorAll"));
208
208
  }
209
- const contextSelectorRe = /(^|[^\\],)\s*[!>+~-]/;
210
- const isContextSelector = memoize((selector) => selector.match(contextSelectorRe));
211
- const contextSanitizeRe = /([!>+~-])(?=\s+[!>+~-]|\s*$)/g;
212
- const sanatize = memoize((selector) => selector.replace(contextSanitizeRe, "$1 *"));
209
+ const addStarRe = /([!>+~-])(?=\s+[!>+~-]|\s*$)/g;
210
+ const splitSelectorRe = /.*?[^\\](?![^(]*\))(?:,|$)/g;
211
+ const trailingCommaRe = /\s*,$/;
212
+ const parseSelector = memoize((selector) => {
213
+ var _a;
214
+ selector = selector.replace(addStarRe, "$1 *");
215
+ let isContextSelector = false;
216
+ const selectors = [];
217
+ for (let sel of (_a = selector.match(splitSelectorRe)) != null ? _a : []) {
218
+ sel = sel.replace(trailingCommaRe, "").trim();
219
+ if (sel[0] === ">") {
220
+ sel = `:scope ${sel}`;
221
+ }
222
+ isContextSelector || (isContextSelector = ["!", "+", "~", "-"].includes(sel[0]));
223
+ selectors.push(sel);
224
+ }
225
+ return {
226
+ selector: selectors.join(","),
227
+ selectors,
228
+ isContextSelector
229
+ };
230
+ });
231
+ const parsePositionSelector = memoize((selector) => {
232
+ selector = selector.substr(1).trim();
233
+ const index2 = selector.indexOf(" ");
234
+ return ~index2 ? [selector.substring(0, index2), selector.substring(index2 + 1)] : [selector, ""];
235
+ });
213
236
  function _query(selector, context = document, queryFn) {
214
237
  if (!selector || !isString(selector)) {
215
238
  return selector;
216
239
  }
217
- selector = sanatize(selector);
218
- if (isContextSelector(selector)) {
219
- const split = splitSelector(selector);
220
- selector = "";
221
- for (let sel of split) {
222
- let ctx = context;
223
- if (sel[0] === "!") {
224
- const selectors = sel.substr(1).trim().split(" ");
225
- ctx = parent(context).closest(selectors[0]);
226
- sel = selectors.slice(1).join(" ").trim();
227
- if (!sel.length && split.length === 1) {
228
- return ctx;
229
- }
240
+ const parsed = parseSelector(selector);
241
+ if (!parsed.isContextSelector) {
242
+ return _doQuery(context, queryFn, parsed.selector);
243
+ }
244
+ selector = "";
245
+ const isSingle = parsed.selectors.length === 1;
246
+ for (let sel of parsed.selectors) {
247
+ let positionSel;
248
+ let ctx = context;
249
+ if (sel[0] === "!") {
250
+ [positionSel, sel] = parsePositionSelector(sel);
251
+ ctx = context.parentElement.closest(positionSel);
252
+ if (!sel && isSingle) {
253
+ return ctx;
230
254
  }
231
- if (sel[0] === "-") {
232
- const selectors = sel.substr(1).trim().split(" ");
233
- const prev = (ctx || context).previousElementSibling;
234
- ctx = matches(prev, sel.substr(1)) ? prev : null;
235
- sel = selectors.slice(1).join(" ");
236
- }
237
- if (ctx) {
238
- selector += `${selector ? "," : ""}${domPath(ctx)} ${sel}`;
255
+ }
256
+ if (ctx && sel[0] === "-") {
257
+ [positionSel, sel] = parsePositionSelector(sel);
258
+ ctx = ctx.previousElementSibling;
259
+ ctx = matches(ctx, positionSel) ? ctx : null;
260
+ if (!sel && isSingle) {
261
+ return ctx;
239
262
  }
263
+ } else if (sel[0] === "~" || sel[0] === "+" && isSingle) {
264
+ return _doQuery(
265
+ ctx.parentElement,
266
+ queryFn,
267
+ `:scope :nth-child(${index(ctx) + 1}) ${sel}`
268
+ );
240
269
  }
241
- if (!isDocument(context)) {
242
- context = context.ownerDocument;
270
+ if (ctx) {
271
+ selector += `${selector ? "," : ""}${domPath(ctx)} ${sel}`;
243
272
  }
244
273
  }
274
+ if (!isDocument(context)) {
275
+ context = context.ownerDocument;
276
+ }
277
+ return _doQuery(context, queryFn, selector);
278
+ }
279
+ function _doQuery(context, queryFn, selector) {
245
280
  try {
246
281
  return context[queryFn](selector);
247
282
  } catch (e) {
248
283
  return null;
249
284
  }
250
285
  }
251
- const selectorRe = /.*?[^\\](?![^(]*\))(?:,|$)/g;
252
- const splitSelector = memoize(
253
- (selector) => selector.match(selectorRe).map((selector2) => selector2.replace(/,$/, "").trim())
254
- );
255
286
  function domPath(element) {
256
287
  const names = [];
257
288
  while (element.parentNode) {
@@ -295,18 +326,10 @@
295
326
  }
296
327
 
297
328
  function getMaxPathLength(el) {
298
- return Math.ceil(
299
- Math.max(
300
- 0,
301
- ...$$("[stroke]", el).map((stroke) => {
302
- try {
303
- return stroke.getTotalLength();
304
- } catch (e) {
305
- return 0;
306
- }
307
- })
308
- )
309
- );
329
+ return Math.ceil(Math.max(0, ...$$("[stroke]", el).map((stroke) => {
330
+ var _a;
331
+ return (_a = stroke.getTotalLength) == null ? void 0 : _a.call(stroke);
332
+ })));
310
333
  }
311
334
 
312
335
  const props = {
@@ -510,6 +533,7 @@
510
533
  }
511
534
  };
512
535
  }
536
+ const loading = {};
513
537
  const dimensions = {};
514
538
  function getBackgroundImageDimensions(el) {
515
539
  const src = uikitUtil.css(el, "backgroundImage").replace(/^none|url\(["']?(.+?)["']?\)$/, "$1");
@@ -519,11 +543,12 @@
519
543
  const image = new Image();
520
544
  if (src) {
521
545
  image.src = src;
522
- if (!image.naturalWidth) {
523
- image.onload = () => {
546
+ if (!image.naturalWidth && !loading[src]) {
547
+ uikitUtil.once(image, "error load", () => {
524
548
  dimensions[src] = toDimensions(image);
525
549
  uikitUtil.trigger(el, uikitUtil.createEvent("load", false));
526
- };
550
+ });
551
+ loading[src] = true;
527
552
  return toDimensions(image);
528
553
  }
529
554
  }
@@ -1 +1 @@
1
- /*! UIkit 3.19.5-dev.57ec46163 | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */(function(i,b){typeof exports=="object"&&typeof module<"u"?module.exports=b(require("uikit-util")):typeof define=="function"&&define.amd?define("uikitparallax",["uikit-util"],b):(i=typeof globalThis<"u"?globalThis:i||self,i.UIkitParallax=b(i.UIkit.util))})(this,function(i){"use strict";function b(n,t="update"){n._connected&&n._updates.length&&(n._queued||(n._queued=new Set,i.fastdom.read(()=>{n._connected&&K(n,n._queued),delete n._queued})),n._queued.add(t.type||t))}function K(n,t){for(const{read:e,write:o,events:r=[]}of n._updates){if(!t.has("update")&&!r.some(s=>t.has(s)))continue;let c;e&&(c=e.call(n,n._data,t),c&&i.isPlainObject(c)&&i.assign(n._data,c)),o&&c!==!1&&i.fastdom.write(()=>{n._connected&&o.call(n,n._data,t)})}}function Q(n){return _(i.observeResize,n,"resize")}function X(n){return _((t,e)=>i.observeViewportResize(e),n,"resize")}function Y(n){return _((t,e)=>({disconnect:i.on(Z(t),"scroll",e,{passive:!0})}),n,"scroll")}function _(n,t,e){return{observe:n,handler(){b(this,e)},...t}}function Z(n){return i.toNodes(n).map(t=>{const{ownerDocument:e}=t,o=i.scrollParent(t,!0);return o===e.scrollingElement?e:o})}var k={props:{media:Boolean},data:{media:!1},connected(){const n=U(this.media,this.$el);if(this.matchMedia=!0,n){this.mediaObj=window.matchMedia(n);const t=()=>{this.matchMedia=this.mediaObj.matches,i.trigger(this.$el,i.createEvent("mediachange",!1,!0,[this.mediaObj]))};this.offMediaObj=i.on(this.mediaObj,"change",()=>{t(),this.$emit("resize")}),t()}},disconnected(){var n;(n=this.offMediaObj)==null||n.call(this)}};function U(n,t){if(i.isString(n)){if(i.startsWith(n,"@"))n=i.toFloat(i.css(t,`--uk-breakpoint-${n.substr(1)}`));else if(isNaN(n))return n}return n&&i.isNumeric(n)?`(min-width: ${n}px)`:""}function nn(n,t){var e;return(e=n==null?void 0:n.startsWith)==null?void 0:e.call(n,t)}const{isArray:Tn,from:tn}=Array;function en(n){return typeof n=="function"}function M(n){return n!==null&&typeof n=="object"}function rn(n){return M(n)&&n===n.window}function on(n){return I(n)===9}function E(n){return I(n)>=1}function I(n){return!rn(n)&&M(n)&&n.nodeType}function O(n){return typeof n=="string"}function cn(n){return n===void 0}function $(n){return d(n)[0]}function d(n){return E(n)?[n]:Array.from(n||[]).filter(E)}function P(n){const t=Object.create(null);return(e,...o)=>t[e]||(t[e]=n(e,...o))}function j(n,t,e){var o;if(M(t)){for(const r in t)j(n,r,t[r]);return}if(cn(e))return(o=$(n))==null?void 0:o.getAttribute(t);for(const r of d(n))en(e)&&(e=e.call(r,j(r,t))),e===null?sn(r,t):r.setAttribute(t,e)}function sn(n,t){d(n).forEach(e=>e.removeAttribute(t))}function A(n){var t;return(t=$(n))==null?void 0:t.parentElement}function an(n,t){return d(n).filter(e=>T(e,t))}function T(n,t){return d(n).some(e=>e.matches(t))}function fn(n,t){n=$(n);const e=n?tn(n.children):[];return t?an(e,t):e}function un(n,t){return t?d(n).indexOf($(t)):fn(A(n)).indexOf(n)}function dn(n,t){return d(bn(n,$(t),"querySelectorAll"))}const hn=/(^|[^\\],)\s*[!>+~-]/,ln=P(n=>n.match(hn)),gn=/([!>+~-])(?=\s+[!>+~-]|\s*$)/g,mn=P(n=>n.replace(gn,"$1 *"));function bn(n,t=document,e){if(!n||!O(n))return n;if(n=mn(n),ln(n)){const o=xn(n);n="";for(let r of o){let c=t;if(r[0]==="!"){const s=r.substr(1).trim().split(" ");if(c=A(t).closest(s[0]),r=s.slice(1).join(" ").trim(),!r.length&&o.length===1)return c}if(r[0]==="-"){const s=r.substr(1).trim().split(" "),a=(c||t).previousElementSibling;c=T(a,r.substr(1))?a:null,r=s.slice(1).join(" ")}c&&(n+=`${n?",":""}${pn(c)} ${r}`)}on(t)||(t=t.ownerDocument)}try{return t[e](n)}catch{return null}}const $n=/.*?[^\\](?![^(]*\))(?:,|$)/g,xn=P(n=>n.match($n).map(t=>t.replace(/,$/,"").trim()));function pn(n){const t=[];for(;n.parentNode;){const e=j(n,"id");if(e){t.unshift(`#${wn(e)}`);break}else{let{tagName:o}=n;o!=="HTML"&&(o+=`:nth-child(${un(n)+1})`),t.unshift(o),n=n.parentNode}}return t.join(" > ")}function wn(n){return O(n)?CSS.escape(n):""}const vn=/^<(\w+)\s*\/?>(?:<\/\1>)?$/;function yn(n){const t=vn.exec(n);if(t)return document.createElement(t[1]);const e=document.createElement("template");return e.innerHTML=n.trim(),Sn(e.content.childNodes)}function Sn(n){return n.length>1?n:n[0]}function Fn(n,t){return _n(n)?d(yn(n)):dn(n,t)}function _n(n){return O(n)&&nn(n.trim(),"<")}function Mn(n){return Math.ceil(Math.max(0,...Fn("[stroke]",n).map(t=>{try{return t.getTotalLength()}catch{return 0}})))}const v={x:y,y,rotate:y,scale:y,color:N,backgroundColor:N,borderColor:N,blur:g,hue:g,fopacity:g,grayscale:g,invert:g,saturate:g,sepia:g,opacity:jn,stroke:Nn,bgx:W,bgy:W},{keys:q}=Object;var On={mixins:[k],props:B(q(v),"list"),data:B(q(v),void 0),computed:{props(n,t){const e={};for(const r in n)r in v&&!i.isUndefined(n[r])&&(e[r]=n[r].slice());const o={};for(const r in e)o[r]=v[r](r,t,e[r],e);return o}},events:{load(){this.$emit()}},methods:{reset(){for(const n in this.getCss(0))i.css(this.$el,n,"")},getCss(n){const t={};for(const e in this.props)this.props[e](t,i.clamp(n));return t.willChange=Object.keys(t).map(i.propName).join(","),t}}};function y(n,t,e){let o=F(e)||{x:"px",y:"px",rotate:"deg"}[n]||"",r;return n==="x"||n==="y"?(n=`translate${i.ucfirst(n)}`,r=c=>i.toFloat(i.toFloat(c).toFixed(o==="px"?0:6))):n==="scale"&&(o="",r=c=>{var s;return F([c])?i.toPx(c,"width",t,!0)/t[`offset${(s=c.endsWith)!=null&&s.call(c,"vh")?"Height":"Width"}`]:i.toFloat(c)}),e.length===1&&e.unshift(n==="scale"?1:0),e=m(e,r),(c,s)=>{c.transform=`${c.transform||""} ${n}(${x(e,s)}${o})`}}function N(n,t,e){return e.length===1&&e.unshift(p(t,n,"")),e=m(e,o=>Pn(t,o)),(o,r)=>{const[c,s,a]=H(e,r),h=c.map((l,f)=>(l+=a*(s[f]-l),f===3?i.toFloat(l):parseInt(l,10))).join(",");o[n]=`rgba(${h})`}}function Pn(n,t){return p(n,"color",t).split(/[(),]/g).slice(1,-1).concat(1).slice(0,4).map(i.toFloat)}function g(n,t,e){e.length===1&&e.unshift(0);const o=F(e)||{blur:"px",hue:"deg"}[n]||"%";return n={fopacity:"opacity",hue:"hue-rotate"}[n]||n,e=m(e),(r,c)=>{const s=x(e,c);r.filter=`${r.filter||""} ${n}(${s+o})`}}function jn(n,t,e){return e.length===1&&e.unshift(p(t,n,"")),e=m(e),(o,r)=>{o[n]=x(e,r)}}function Nn(n,t,e){e.length===1&&e.unshift(0);const o=F(e),r=Mn(t);return e=m(e.reverse(),c=>(c=i.toFloat(c),o==="%"?c*r/100:c)),e.some(([c])=>c)?(i.css(t,"strokeDasharray",r),(c,s)=>{c.strokeDashoffset=x(e,s)}):i.noop}function W(n,t,e,o){e.length===1&&e.unshift(0);const r=n==="bgy"?"height":"width";o[n]=m(e,a=>i.toPx(a,r,t));const c=["bgx","bgy"].filter(a=>a in o);if(c.length===2&&n==="bgx")return i.noop;if(p(t,"backgroundSize","")==="cover")return zn(n,t,e,o);const s={};for(const a of c)s[a]=D(t,a);return R(c,s,o)}function zn(n,t,e,o){const r=Cn(t);if(!r.width)return i.noop;const c={width:t.offsetWidth,height:t.offsetHeight},s=["bgx","bgy"].filter(f=>f in o),a={};for(const f of s){const u=o[f].map(([An])=>An),w=Math.min(...u),C=Math.max(...u),G=u.indexOf(w)<u.indexOf(C),J=C-w;a[f]=`${(G?-J:0)-(G?w:C)}px`,c[f==="bgy"?"height":"width"]+=J}const h=i.Dimensions.cover(r,c);for(const f of s){const u=f==="bgy"?"height":"width",w=h[u]-c[u];a[f]=`max(${D(t,f)},-${w}px) + ${a[f]}`}const l=R(s,a,o);return(f,u)=>{l(f,u),f.backgroundSize=`${h.width}px ${h.height}px`,f.backgroundRepeat="no-repeat"}}function D(n,t){return p(n,`background-position-${t.substr(-1)}`,"")}function R(n,t,e){return function(o,r){for(const c of n){const s=x(e[c],r);o[`background-position-${c.substr(-1)}`]=`calc(${t[c]} + ${s}px)`}}}const S={};function Cn(n){const t=i.css(n,"backgroundImage").replace(/^none|url\(["']?(.+?)["']?\)$/,"$1");if(S[t])return S[t];const e=new Image;return t&&(e.src=t,!e.naturalWidth)?(e.onload=()=>{S[t]=z(e),i.trigger(n,i.createEvent("load",!1))},z(e)):S[t]=z(e)}function z(n){return{width:n.naturalWidth,height:n.naturalHeight}}function m(n,t=i.toFloat){const e=[],{length:o}=n;let r=0;for(let c=0;c<o;c++){let[s,a]=i.isString(n[c])?n[c].trim().split(/ (?![^(]*\))/):[n[c]];if(s=t(s),a=a?i.toFloat(a)/100:null,c===0?a===null?a=0:a&&e.push([s,0]):c===o-1&&(a===null?a=1:a!==1&&(e.push([s,a]),a=1)),e.push([s,a]),a===null)r++;else if(r){const h=e[c-r-1][1],l=(a-h)/(r+1);for(let f=r;f>0;f--)e[c-f][1]=h+l*(r-f+1);r=0}}return e}function H(n,t){const e=i.findIndex(n.slice(1),([,o])=>t<=o)+1;return[n[e-1][0],n[e][0],(t-n[e-1][1])/(n[e][1]-n[e-1][1])]}function x(n,t){const[e,o,r]=H(n,t);return e+Math.abs(e-o)*r*(e<o?1:-1)}const En=/^-?\d+(?:\.\d+)?(\S+)?/;function F(n,t){var e;for(const o of n){const r=(e=o.match)==null?void 0:e.call(o,En);if(r)return r[1]}return t}function p(n,t,e){const o=n.style[t],r=i.css(i.css(n,t,e),t);return n.style[t]=o,r}function B(n,t){return n.reduce((e,o)=>(e[o]=t,e),{})}function In(n,t){return t>=0?Math.pow(n,t+1):1-Math.pow(1-n,1-t)}var L={mixins:[On],props:{target:String,viewport:Number,easing:Number,start:String,end:String},data:{target:!1,viewport:1,easing:1,start:0,end:0},computed:{target:({target:n},t)=>V(n&&i.query(n,t)||t),start({start:n}){return i.toPx(n,"height",this.target,!0)},end({end:n,viewport:t}){return i.toPx(n||(t=(1-t)*100)&&`${t}vh+${t}%`,"height",this.target,!0)}},observe:[X(),Y({target:({target:n})=>n}),Q({target:({$el:n,target:t})=>[n,t,i.scrollParent(t,!0)]})],update:{read({percent:n},t){if(t.has("scroll")||(n=!1),!i.isVisible(this.$el))return!1;if(!this.matchMedia)return;const e=n;return n=In(i.scrolledOver(this.target,this.start,this.end),this.easing),{percent:n,style:e===n?!1:this.getCss(n)}},write({style:n}){if(!this.matchMedia){this.reset();return}n&&i.css(this.$el,n)},events:["scroll","resize"]}};function V(n){return n?"offsetTop"in n?n:V(i.parent(n)):document.documentElement}return typeof window<"u"&&window.UIkit&&window.UIkit.component("parallax",L),L});
1
+ /*! UIkit 3.19.5-dev.5db24934f | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */(function(s,b){typeof exports=="object"&&typeof module<"u"?module.exports=b(require("uikit-util")):typeof define=="function"&&define.amd?define("uikitparallax",["uikit-util"],b):(s=typeof globalThis<"u"?globalThis:s||self,s.UIkitParallax=b(s.UIkit.util))})(this,function(s){"use strict";function b(n,t="update"){n._connected&&n._updates.length&&(n._queued||(n._queued=new Set,s.fastdom.read(()=>{n._connected&&Y(n,n._queued),delete n._queued})),n._queued.add(t.type||t))}function Y(n,t){for(const{read:e,write:r,events:o=[]}of n._updates){if(!t.has("update")&&!o.some(a=>t.has(a)))continue;let i;e&&(i=e.call(n,n._data,t),i&&s.isPlainObject(i)&&s.assign(n._data,i)),r&&i!==!1&&s.fastdom.write(()=>{n._connected&&r.call(n,n._data,t)})}}function Z(n){return M(s.observeResize,n,"resize")}function k(n){return M((t,e)=>s.observeViewportResize(e),n,"resize")}function U(n){return M((t,e)=>({disconnect:s.on(nn(t),"scroll",e,{passive:!0})}),n,"scroll")}function M(n,t,e){return{observe:n,handler(){b(this,e)},...t}}function nn(n){return s.toNodes(n).map(t=>{const{ownerDocument:e}=t,r=s.scrollParent(t,!0);return r===e.scrollingElement?e:r})}var tn={props:{media:Boolean},data:{media:!1},connected(){const n=en(this.media,this.$el);if(this.matchMedia=!0,n){this.mediaObj=window.matchMedia(n);const t=()=>{this.matchMedia=this.mediaObj.matches,s.trigger(this.$el,s.createEvent("mediachange",!1,!0,[this.mediaObj]))};this.offMediaObj=s.on(this.mediaObj,"change",()=>{t(),this.$emit("resize")}),t()}},disconnected(){var n;(n=this.offMediaObj)==null||n.call(this)}};function en(n,t){if(s.isString(n)){if(s.startsWith(n,"@"))n=s.toFloat(s.css(t,`--uk-breakpoint-${n.substr(1)}`));else if(isNaN(n))return n}return n&&s.isNumeric(n)?`(min-width: ${n}px)`:""}function rn(n,t){var e;return(e=n==null?void 0:n.startsWith)==null?void 0:e.call(n,t)}const{isArray:Wn,from:on}=Array;function sn(n){return typeof n=="function"}function O(n){return n!==null&&typeof n=="object"}function cn(n){return O(n)&&n===n.window}function an(n){return z(n)===9}function I(n){return z(n)>=1}function z(n){return!cn(n)&&O(n)&&n.nodeType}function F(n){return typeof n=="string"}function fn(n){return n===void 0}function $(n){return n&&d(n)[0]}function d(n){return I(n)?[n]:Array.from(n||[]).filter(I)}function A(n){const t=Object.create(null);return(e,...r)=>t[e]||(t[e]=n(e,...r))}function P(n,t,e){var r;if(O(t)){for(const o in t)P(n,o,t[o]);return}if(fn(e))return(r=$(n))==null?void 0:r.getAttribute(t);for(const o of d(n))sn(e)&&(e=e.call(o,P(o,t))),e===null?un(o,t):o.setAttribute(t,e)}function un(n,t){d(n).forEach(e=>e.removeAttribute(t))}function dn(n){var t;return(t=$(n))==null?void 0:t.parentElement}function hn(n,t){return d(n).filter(e=>T(e,t))}function T(n,t){return d(n).some(e=>e.matches(t))}function ln(n,t){n=$(n);const e=n?on(n.children):[];return t?hn(e,t):e}function W(n,t){return t?d(n).indexOf($(t)):ln(dn(n)).indexOf(n)}function gn(n,t){return d(pn(n,$(t),"querySelectorAll"))}const mn=/([!>+~-])(?=\s+[!>+~-]|\s*$)/g,bn=/.*?[^\\](?![^(]*\))(?:,|$)/g,$n=/\s*,$/,xn=A(n=>{var t;n=n.replace(mn,"$1 *");let e=!1;const r=[];for(let o of(t=n.match(bn))!=null?t:[])o=o.replace($n,"").trim(),o[0]===">"&&(o=`:scope ${o}`),e||(e=["!","+","~","-"].includes(o[0])),r.push(o);return{selector:r.join(","),selectors:r,isContextSelector:e}}),D=A(n=>{n=n.substr(1).trim();const t=n.indexOf(" ");return~t?[n.substring(0,t),n.substring(t+1)]:[n,""]});function pn(n,t=document,e){if(!n||!F(n))return n;const r=xn(n);if(!r.isContextSelector)return j(t,e,r.selector);n="";const o=r.selectors.length===1;for(let i of r.selectors){let a,c=t;if(i[0]==="!"&&([a,i]=D(i),c=t.parentElement.closest(a),!i&&o))return c;if(c&&i[0]==="-"){if([a,i]=D(i),c=c.previousElementSibling,c=T(c,a)?c:null,!i&&o)return c}else if(i[0]==="~"||i[0]==="+"&&o)return j(c.parentElement,e,`:scope :nth-child(${W(c)+1}) ${i}`);c&&(n+=`${n?",":""}${vn(c)} ${i}`)}return an(t)||(t=t.ownerDocument),j(t,e,n)}function j(n,t,e){try{return n[t](e)}catch{return null}}function vn(n){const t=[];for(;n.parentNode;){const e=P(n,"id");if(e){t.unshift(`#${wn(e)}`);break}else{let{tagName:r}=n;r!=="HTML"&&(r+=`:nth-child(${W(n)+1})`),t.unshift(r),n=n.parentNode}}return t.join(" > ")}function wn(n){return F(n)?CSS.escape(n):""}const yn=/^<(\w+)\s*\/?>(?:<\/\1>)?$/;function Sn(n){const t=yn.exec(n);if(t)return document.createElement(t[1]);const e=document.createElement("template");return e.innerHTML=n.trim(),_n(e.content.childNodes)}function _n(n){return n.length>1?n:n[0]}function Mn(n,t){return On(n)?d(Sn(n)):gn(n,t)}function On(n){return F(n)&&rn(n.trim(),"<")}function Fn(n){return Math.ceil(Math.max(0,...Mn("[stroke]",n).map(t=>{var e;return(e=t.getTotalLength)==null?void 0:e.call(t)})))}const w={x:y,y,rotate:y,scale:y,color:C,backgroundColor:C,borderColor:C,blur:g,hue:g,fopacity:g,grayscale:g,invert:g,saturate:g,sepia:g,opacity:Cn,stroke:Nn,bgx:q,bgy:q},{keys:R}=Object;var Pn={mixins:[tn],props:Q(R(w),"list"),data:Q(R(w),void 0),computed:{props(n,t){const e={};for(const o in n)o in w&&!s.isUndefined(n[o])&&(e[o]=n[o].slice());const r={};for(const o in e)r[o]=w[o](o,t,e[o],e);return r}},events:{load(){this.$emit()}},methods:{reset(){for(const n in this.getCss(0))s.css(this.$el,n,"")},getCss(n){const t={};for(const e in this.props)this.props[e](t,s.clamp(n));return t.willChange=Object.keys(t).map(s.propName).join(","),t}}};function y(n,t,e){let r=_(e)||{x:"px",y:"px",rotate:"deg"}[n]||"",o;return n==="x"||n==="y"?(n=`translate${s.ucfirst(n)}`,o=i=>s.toFloat(s.toFloat(i).toFixed(r==="px"?0:6))):n==="scale"&&(r="",o=i=>{var a;return _([i])?s.toPx(i,"width",t,!0)/t[`offset${(a=i.endsWith)!=null&&a.call(i,"vh")?"Height":"Width"}`]:s.toFloat(i)}),e.length===1&&e.unshift(n==="scale"?1:0),e=m(e,o),(i,a)=>{i.transform=`${i.transform||""} ${n}(${x(e,a)}${r})`}}function C(n,t,e){return e.length===1&&e.unshift(p(t,n,"")),e=m(e,r=>jn(t,r)),(r,o)=>{const[i,a,c]=V(e,o),h=i.map((l,f)=>(l+=c*(a[f]-l),f===3?s.toFloat(l):parseInt(l,10))).join(",");r[n]=`rgba(${h})`}}function jn(n,t){return p(n,"color",t).split(/[(),]/g).slice(1,-1).concat(1).slice(0,4).map(s.toFloat)}function g(n,t,e){e.length===1&&e.unshift(0);const r=_(e)||{blur:"px",hue:"deg"}[n]||"%";return n={fopacity:"opacity",hue:"hue-rotate"}[n]||n,e=m(e),(o,i)=>{const a=x(e,i);o.filter=`${o.filter||""} ${n}(${a+r})`}}function Cn(n,t,e){return e.length===1&&e.unshift(p(t,n,"")),e=m(e),(r,o)=>{r[n]=x(e,o)}}function Nn(n,t,e){e.length===1&&e.unshift(0);const r=_(e),o=Fn(t);return e=m(e.reverse(),i=>(i=s.toFloat(i),r==="%"?i*o/100:i)),e.some(([i])=>i)?(s.css(t,"strokeDasharray",o),(i,a)=>{i.strokeDashoffset=x(e,a)}):s.noop}function q(n,t,e,r){e.length===1&&e.unshift(0);const o=n==="bgy"?"height":"width";r[n]=m(e,c=>s.toPx(c,o,t));const i=["bgx","bgy"].filter(c=>c in r);if(i.length===2&&n==="bgx")return s.noop;if(p(t,"backgroundSize","")==="cover")return En(n,t,e,r);const a={};for(const c of i)a[c]=H(t,c);return B(i,a,r)}function En(n,t,e,r){const o=In(t);if(!o.width)return s.noop;const i={width:t.offsetWidth,height:t.offsetHeight},a=["bgx","bgy"].filter(f=>f in r),c={};for(const f of a){const u=r[f].map(([Tn])=>Tn),v=Math.min(...u),E=Math.max(...u),K=u.indexOf(v)<u.indexOf(E),X=E-v;c[f]=`${(K?-X:0)-(K?v:E)}px`,i[f==="bgy"?"height":"width"]+=X}const h=s.Dimensions.cover(o,i);for(const f of a){const u=f==="bgy"?"height":"width",v=h[u]-i[u];c[f]=`max(${H(t,f)},-${v}px) + ${c[f]}`}const l=B(a,c,r);return(f,u)=>{l(f,u),f.backgroundSize=`${h.width}px ${h.height}px`,f.backgroundRepeat="no-repeat"}}function H(n,t){return p(n,`background-position-${t.substr(-1)}`,"")}function B(n,t,e){return function(r,o){for(const i of n){const a=x(e[i],o);r[`background-position-${i.substr(-1)}`]=`calc(${t[i]} + ${a}px)`}}}const L={},S={};function In(n){const t=s.css(n,"backgroundImage").replace(/^none|url\(["']?(.+?)["']?\)$/,"$1");if(S[t])return S[t];const e=new Image;return t&&(e.src=t,!e.naturalWidth&&!L[t])?(s.once(e,"error load",()=>{S[t]=N(e),s.trigger(n,s.createEvent("load",!1))}),L[t]=!0,N(e)):S[t]=N(e)}function N(n){return{width:n.naturalWidth,height:n.naturalHeight}}function m(n,t=s.toFloat){const e=[],{length:r}=n;let o=0;for(let i=0;i<r;i++){let[a,c]=s.isString(n[i])?n[i].trim().split(/ (?![^(]*\))/):[n[i]];if(a=t(a),c=c?s.toFloat(c)/100:null,i===0?c===null?c=0:c&&e.push([a,0]):i===r-1&&(c===null?c=1:c!==1&&(e.push([a,c]),c=1)),e.push([a,c]),c===null)o++;else if(o){const h=e[i-o-1][1],l=(c-h)/(o+1);for(let f=o;f>0;f--)e[i-f][1]=h+l*(o-f+1);o=0}}return e}function V(n,t){const e=s.findIndex(n.slice(1),([,r])=>t<=r)+1;return[n[e-1][0],n[e][0],(t-n[e-1][1])/(n[e][1]-n[e-1][1])]}function x(n,t){const[e,r,o]=V(n,t);return e+Math.abs(e-r)*o*(e<r?1:-1)}const zn=/^-?\d+(?:\.\d+)?(\S+)?/;function _(n,t){var e;for(const r of n){const o=(e=r.match)==null?void 0:e.call(r,zn);if(o)return o[1]}return t}function p(n,t,e){const r=n.style[t],o=s.css(s.css(n,t,e),t);return n.style[t]=r,o}function Q(n,t){return n.reduce((e,r)=>(e[r]=t,e),{})}function An(n,t){return t>=0?Math.pow(n,t+1):1-Math.pow(1-n,1-t)}var G={mixins:[Pn],props:{target:String,viewport:Number,easing:Number,start:String,end:String},data:{target:!1,viewport:1,easing:1,start:0,end:0},computed:{target:({target:n},t)=>J(n&&s.query(n,t)||t),start({start:n}){return s.toPx(n,"height",this.target,!0)},end({end:n,viewport:t}){return s.toPx(n||(t=(1-t)*100)&&`${t}vh+${t}%`,"height",this.target,!0)}},observe:[k(),U({target:({target:n})=>n}),Z({target:({$el:n,target:t})=>[n,t,s.scrollParent(t,!0)]})],update:{read({percent:n},t){if(t.has("scroll")||(n=!1),!s.isVisible(this.$el))return!1;if(!this.matchMedia)return;const e=n;return n=An(s.scrolledOver(this.target,this.start,this.end),this.easing),{percent:n,style:e===n?!1:this.getCss(n)}},write({style:n}){if(!this.matchMedia){this.reset();return}n&&s.css(this.$el,n)},events:["scroll","resize"]}};function J(n){return n?"offsetTop"in n?n:J(s.parent(n)):document.documentElement}return typeof window<"u"&&window.UIkit&&window.UIkit.component("parallax",G),G});
@@ -1,4 +1,4 @@
1
- /*! UIkit 3.19.5-dev.57ec46163 | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */
1
+ /*! UIkit 3.19.5-dev.5db24934f | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */
2
2
 
3
3
  (function (global, factory) {
4
4
  typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('uikit-util')) :
@@ -75,7 +75,7 @@
75
75
  return value === void 0;
76
76
  }
77
77
  function toNode(element) {
78
- return toNodes(element)[0];
78
+ return element && toNodes(element)[0];
79
79
  }
80
80
  function toNodes(element) {
81
81
  return isNode(element) ? [element] : Array.from(element || []).filter(isNode);
@@ -134,52 +134,83 @@
134
134
  function findAll(selector, context) {
135
135
  return toNodes(_query(selector, toNode(context), "querySelectorAll"));
136
136
  }
137
- const contextSelectorRe = /(^|[^\\],)\s*[!>+~-]/;
138
- const isContextSelector = memoize((selector) => selector.match(contextSelectorRe));
139
- const contextSanitizeRe = /([!>+~-])(?=\s+[!>+~-]|\s*$)/g;
140
- const sanatize = memoize((selector) => selector.replace(contextSanitizeRe, "$1 *"));
137
+ const addStarRe = /([!>+~-])(?=\s+[!>+~-]|\s*$)/g;
138
+ const splitSelectorRe = /.*?[^\\](?![^(]*\))(?:,|$)/g;
139
+ const trailingCommaRe = /\s*,$/;
140
+ const parseSelector = memoize((selector) => {
141
+ var _a;
142
+ selector = selector.replace(addStarRe, "$1 *");
143
+ let isContextSelector = false;
144
+ const selectors = [];
145
+ for (let sel of (_a = selector.match(splitSelectorRe)) != null ? _a : []) {
146
+ sel = sel.replace(trailingCommaRe, "").trim();
147
+ if (sel[0] === ">") {
148
+ sel = `:scope ${sel}`;
149
+ }
150
+ isContextSelector || (isContextSelector = ["!", "+", "~", "-"].includes(sel[0]));
151
+ selectors.push(sel);
152
+ }
153
+ return {
154
+ selector: selectors.join(","),
155
+ selectors,
156
+ isContextSelector
157
+ };
158
+ });
159
+ const parsePositionSelector = memoize((selector) => {
160
+ selector = selector.substr(1).trim();
161
+ const index2 = selector.indexOf(" ");
162
+ return ~index2 ? [selector.substring(0, index2), selector.substring(index2 + 1)] : [selector, ""];
163
+ });
141
164
  function _query(selector, context = document, queryFn) {
142
165
  if (!selector || !isString(selector)) {
143
166
  return selector;
144
167
  }
145
- selector = sanatize(selector);
146
- if (isContextSelector(selector)) {
147
- const split = splitSelector(selector);
148
- selector = "";
149
- for (let sel of split) {
150
- let ctx = context;
151
- if (sel[0] === "!") {
152
- const selectors = sel.substr(1).trim().split(" ");
153
- ctx = parent(context).closest(selectors[0]);
154
- sel = selectors.slice(1).join(" ").trim();
155
- if (!sel.length && split.length === 1) {
156
- return ctx;
157
- }
158
- }
159
- if (sel[0] === "-") {
160
- const selectors = sel.substr(1).trim().split(" ");
161
- const prev = (ctx || context).previousElementSibling;
162
- ctx = matches(prev, sel.substr(1)) ? prev : null;
163
- sel = selectors.slice(1).join(" ");
168
+ const parsed = parseSelector(selector);
169
+ if (!parsed.isContextSelector) {
170
+ return _doQuery(context, queryFn, parsed.selector);
171
+ }
172
+ selector = "";
173
+ const isSingle = parsed.selectors.length === 1;
174
+ for (let sel of parsed.selectors) {
175
+ let positionSel;
176
+ let ctx = context;
177
+ if (sel[0] === "!") {
178
+ [positionSel, sel] = parsePositionSelector(sel);
179
+ ctx = context.parentElement.closest(positionSel);
180
+ if (!sel && isSingle) {
181
+ return ctx;
164
182
  }
165
- if (ctx) {
166
- selector += `${selector ? "," : ""}${domPath(ctx)} ${sel}`;
183
+ }
184
+ if (ctx && sel[0] === "-") {
185
+ [positionSel, sel] = parsePositionSelector(sel);
186
+ ctx = ctx.previousElementSibling;
187
+ ctx = matches(ctx, positionSel) ? ctx : null;
188
+ if (!sel && isSingle) {
189
+ return ctx;
167
190
  }
191
+ } else if (sel[0] === "~" || sel[0] === "+" && isSingle) {
192
+ return _doQuery(
193
+ ctx.parentElement,
194
+ queryFn,
195
+ `:scope :nth-child(${index(ctx) + 1}) ${sel}`
196
+ );
168
197
  }
169
- if (!isDocument(context)) {
170
- context = context.ownerDocument;
198
+ if (ctx) {
199
+ selector += `${selector ? "," : ""}${domPath(ctx)} ${sel}`;
171
200
  }
172
201
  }
202
+ if (!isDocument(context)) {
203
+ context = context.ownerDocument;
204
+ }
205
+ return _doQuery(context, queryFn, selector);
206
+ }
207
+ function _doQuery(context, queryFn, selector) {
173
208
  try {
174
209
  return context[queryFn](selector);
175
210
  } catch (e) {
176
211
  return null;
177
212
  }
178
213
  }
179
- const selectorRe = /.*?[^\\](?![^(]*\))(?:,|$)/g;
180
- const splitSelector = memoize(
181
- (selector) => selector.match(selectorRe).map((selector2) => selector2.replace(/,$/, "").trim())
182
- );
183
214
  function domPath(element) {
184
215
  const names = [];
185
216
  while (element.parentNode) {
@@ -223,18 +254,10 @@
223
254
  }
224
255
 
225
256
  function getMaxPathLength(el) {
226
- return Math.ceil(
227
- Math.max(
228
- 0,
229
- ...$$("[stroke]", el).map((stroke) => {
230
- try {
231
- return stroke.getTotalLength();
232
- } catch (e) {
233
- return 0;
234
- }
235
- })
236
- )
237
- );
257
+ return Math.ceil(Math.max(0, ...$$("[stroke]", el).map((stroke) => {
258
+ var _a;
259
+ return (_a = stroke.getTotalLength) == null ? void 0 : _a.call(stroke);
260
+ })));
238
261
  }
239
262
 
240
263
  const props = {
@@ -438,6 +461,7 @@
438
461
  }
439
462
  };
440
463
  }
464
+ const loading = {};
441
465
  const dimensions = {};
442
466
  function getBackgroundImageDimensions(el) {
443
467
  const src = uikitUtil.css(el, "backgroundImage").replace(/^none|url\(["']?(.+?)["']?\)$/, "$1");
@@ -447,11 +471,12 @@
447
471
  const image = new Image();
448
472
  if (src) {
449
473
  image.src = src;
450
- if (!image.naturalWidth) {
451
- image.onload = () => {
474
+ if (!image.naturalWidth && !loading[src]) {
475
+ uikitUtil.once(image, "error load", () => {
452
476
  dimensions[src] = toDimensions(image);
453
477
  uikitUtil.trigger(el, uikitUtil.createEvent("load", false));
454
- };
478
+ });
479
+ loading[src] = true;
455
480
  return toDimensions(image);
456
481
  }
457
482
  }
@@ -538,7 +563,7 @@
538
563
  var Component = {
539
564
  mixins: [Parallax],
540
565
  beforeConnect() {
541
- this.item = uikitUtil.closest(this.$el, `.${this.$options.id.replace("parallax", "items")} > *`);
566
+ this.item = this.$el.closest(`.${this.$options.id.replace("parallax", "items")} > *`);
542
567
  },
543
568
  disconnected() {
544
569
  this.item = null;
@@ -1 +1 @@
1
- /*! UIkit 3.19.5-dev.57ec46163 | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */(function(c,$){typeof exports=="object"&&typeof module<"u"?module.exports=$(require("uikit-util")):typeof define=="function"&&define.amd?define("uikitslider_parallax",["uikit-util"],$):(c=typeof globalThis<"u"?globalThis:c||self,c.UIkitSlider_parallax=$(c.UIkit.util))})(this,function(c){"use strict";var $={props:{media:Boolean},data:{media:!1},connected(){const n=K(this.media,this.$el);if(this.matchMedia=!0,n){this.mediaObj=window.matchMedia(n);const e=()=>{this.matchMedia=this.mediaObj.matches,c.trigger(this.$el,c.createEvent("mediachange",!1,!0,[this.mediaObj]))};this.offMediaObj=c.on(this.mediaObj,"change",()=>{e(),this.$emit("resize")}),e()}},disconnected(){var n;(n=this.offMediaObj)==null||n.call(this)}};function K(n,e){if(c.isString(n)){if(c.startsWith(n,"@"))n=c.toFloat(c.css(e,`--uk-breakpoint-${n.substr(1)}`));else if(isNaN(n))return n}return n&&c.isNumeric(n)?`(min-width: ${n}px)`:""}function Q(n,e){var t;return(t=n==null?void 0:n.startsWith)==null?void 0:t.call(n,e)}const{isArray:Pn,from:X}=Array;function Y(n){return typeof n=="function"}function M(n){return n!==null&&typeof n=="object"}function Z(n){return M(n)&&n===n.window}function k(n){return A(n)===9}function T(n){return A(n)>=1}function A(n){return!Z(n)&&M(n)&&n.nodeType}function C(n){return typeof n=="string"}function U(n){return n===void 0}function b(n){return d(n)[0]}function d(n){return T(n)?[n]:Array.from(n||[]).filter(T)}function O(n){const e=Object.create(null);return(t,...o)=>e[t]||(e[t]=n(t,...o))}function j(n,e,t){var o;if(M(e)){for(const r in e)j(n,r,e[r]);return}if(U(t))return(o=b(n))==null?void 0:o.getAttribute(e);for(const r of d(n))Y(t)&&(t=t.call(r,j(r,e))),t===null?nn(r,e):r.setAttribute(e,t)}function nn(n,e){d(n).forEach(t=>t.removeAttribute(e))}function W(n){var e;return(e=b(n))==null?void 0:e.parentElement}function tn(n,e){return d(n).filter(t=>_(t,e))}function _(n,e){return d(n).some(t=>t.matches(e))}function en(n,e){n=b(n);const t=n?X(n.children):[];return e?tn(t,e):t}function rn(n,e){return e?d(n).indexOf(b(e)):en(W(n)).indexOf(n)}function on(n,e){return d(un(n,b(e),"querySelectorAll"))}const cn=/(^|[^\\],)\s*[!>+~-]/,sn=O(n=>n.match(cn)),an=/([!>+~-])(?=\s+[!>+~-]|\s*$)/g,fn=O(n=>n.replace(an,"$1 *"));function un(n,e=document,t){if(!n||!C(n))return n;if(n=fn(n),sn(n)){const o=hn(n);n="";for(let r of o){let i=e;if(r[0]==="!"){const s=r.substr(1).trim().split(" ");if(i=W(e).closest(s[0]),r=s.slice(1).join(" ").trim(),!r.length&&o.length===1)return i}if(r[0]==="-"){const s=r.substr(1).trim().split(" "),a=(i||e).previousElementSibling;i=_(a,r.substr(1))?a:null,r=s.slice(1).join(" ")}i&&(n+=`${n?",":""}${ln(i)} ${r}`)}k(e)||(e=e.ownerDocument)}try{return e[t](n)}catch{return null}}const dn=/.*?[^\\](?![^(]*\))(?:,|$)/g,hn=O(n=>n.match(dn).map(e=>e.replace(/,$/,"").trim()));function ln(n){const e=[];for(;n.parentNode;){const t=j(n,"id");if(t){e.unshift(`#${mn(t)}`);break}else{let{tagName:o}=n;o!=="HTML"&&(o+=`:nth-child(${rn(n)+1})`),e.unshift(o),n=n.parentNode}}return e.join(" > ")}function mn(n){return C(n)?CSS.escape(n):""}const gn=/^<(\w+)\s*\/?>(?:<\/\1>)?$/;function $n(n){const e=gn.exec(n);if(e)return document.createElement(e[1]);const t=document.createElement("template");return t.innerHTML=n.trim(),bn(t.content.childNodes)}function bn(n){return n.length>1?n:n[0]}function xn(n,e){return pn(n)?d($n(n)):on(n,e)}function pn(n){return C(n)&&Q(n.trim(),"<")}function yn(n){return Math.ceil(Math.max(0,...xn("[stroke]",n).map(e=>{try{return e.getTotalLength()}catch{return 0}})))}const w={x:v,y:v,rotate:v,scale:v,color:P,backgroundColor:P,borderColor:P,blur:m,hue:m,fopacity:m,grayscale:m,invert:m,saturate:m,sepia:m,opacity:Fn,stroke:Sn,bgx:D,bgy:D},{keys:E}=Object;var wn={mixins:[$],props:B(E(w),"list"),data:B(E(w),void 0),computed:{props(n,e){const t={};for(const r in n)r in w&&!c.isUndefined(n[r])&&(t[r]=n[r].slice());const o={};for(const r in t)o[r]=w[r](r,e,t[r],t);return o}},events:{load(){this.$emit()}},methods:{reset(){for(const n in this.getCss(0))c.css(this.$el,n,"")},getCss(n){const e={};for(const t in this.props)this.props[t](e,c.clamp(n));return e.willChange=Object.keys(e).map(c.propName).join(","),e}}};function v(n,e,t){let o=S(t)||{x:"px",y:"px",rotate:"deg"}[n]||"",r;return n==="x"||n==="y"?(n=`translate${c.ucfirst(n)}`,r=i=>c.toFloat(c.toFloat(i).toFixed(o==="px"?0:6))):n==="scale"&&(o="",r=i=>{var s;return S([i])?c.toPx(i,"width",e,!0)/e[`offset${(s=i.endsWith)!=null&&s.call(i,"vh")?"Height":"Width"}`]:c.toFloat(i)}),t.length===1&&t.unshift(n==="scale"?1:0),t=g(t,r),(i,s)=>{i.transform=`${i.transform||""} ${n}(${x(t,s)}${o})`}}function P(n,e,t){return t.length===1&&t.unshift(p(e,n,"")),t=g(t,o=>vn(e,o)),(o,r)=>{const[i,s,a]=R(t,r),h=i.map((l,f)=>(l+=a*(s[f]-l),f===3?c.toFloat(l):parseInt(l,10))).join(",");o[n]=`rgba(${h})`}}function vn(n,e){return p(n,"color",e).split(/[(),]/g).slice(1,-1).concat(1).slice(0,4).map(c.toFloat)}function m(n,e,t){t.length===1&&t.unshift(0);const o=S(t)||{blur:"px",hue:"deg"}[n]||"%";return n={fopacity:"opacity",hue:"hue-rotate"}[n]||n,t=g(t),(r,i)=>{const s=x(t,i);r.filter=`${r.filter||""} ${n}(${s+o})`}}function Fn(n,e,t){return t.length===1&&t.unshift(p(e,n,"")),t=g(t),(o,r)=>{o[n]=x(t,r)}}function Sn(n,e,t){t.length===1&&t.unshift(0);const o=S(t),r=yn(e);return t=g(t.reverse(),i=>(i=c.toFloat(i),o==="%"?i*r/100:i)),t.some(([i])=>i)?(c.css(e,"strokeDasharray",r),(i,s)=>{i.strokeDashoffset=x(t,s)}):c.noop}function D(n,e,t,o){t.length===1&&t.unshift(0);const r=n==="bgy"?"height":"width";o[n]=g(t,a=>c.toPx(a,r,e));const i=["bgx","bgy"].filter(a=>a in o);if(i.length===2&&n==="bgx")return c.noop;if(p(e,"backgroundSize","")==="cover")return Mn(n,e,t,o);const s={};for(const a of i)s[a]=z(e,a);return H(i,s,o)}function Mn(n,e,t,o){const r=Cn(e);if(!r.width)return c.noop;const i={width:e.offsetWidth,height:e.offsetHeight},s=["bgx","bgy"].filter(f=>f in o),a={};for(const f of s){const u=o[f].map(([jn])=>jn),y=Math.min(...u),N=Math.max(...u),G=u.indexOf(y)<u.indexOf(N),J=N-y;a[f]=`${(G?-J:0)-(G?y:N)}px`,i[f==="bgy"?"height":"width"]+=J}const h=c.Dimensions.cover(r,i);for(const f of s){const u=f==="bgy"?"height":"width",y=h[u]-i[u];a[f]=`max(${z(e,f)},-${y}px) + ${a[f]}`}const l=H(s,a,o);return(f,u)=>{l(f,u),f.backgroundSize=`${h.width}px ${h.height}px`,f.backgroundRepeat="no-repeat"}}function z(n,e){return p(n,`background-position-${e.substr(-1)}`,"")}function H(n,e,t){return function(o,r){for(const i of n){const s=x(t[i],r);o[`background-position-${i.substr(-1)}`]=`calc(${e[i]} + ${s}px)`}}}const F={};function Cn(n){const e=c.css(n,"backgroundImage").replace(/^none|url\(["']?(.+?)["']?\)$/,"$1");if(F[e])return F[e];const t=new Image;return e&&(t.src=e,!t.naturalWidth)?(t.onload=()=>{F[e]=I(t),c.trigger(n,c.createEvent("load",!1))},I(t)):F[e]=I(t)}function I(n){return{width:n.naturalWidth,height:n.naturalHeight}}function g(n,e=c.toFloat){const t=[],{length:o}=n;let r=0;for(let i=0;i<o;i++){let[s,a]=c.isString(n[i])?n[i].trim().split(/ (?![^(]*\))/):[n[i]];if(s=e(s),a=a?c.toFloat(a)/100:null,i===0?a===null?a=0:a&&t.push([s,0]):i===o-1&&(a===null?a=1:a!==1&&(t.push([s,a]),a=1)),t.push([s,a]),a===null)r++;else if(r){const h=t[i-r-1][1],l=(a-h)/(r+1);for(let f=r;f>0;f--)t[i-f][1]=h+l*(r-f+1);r=0}}return t}function R(n,e){const t=c.findIndex(n.slice(1),([,o])=>e<=o)+1;return[n[t-1][0],n[t][0],(e-n[t-1][1])/(n[t][1]-n[t-1][1])]}function x(n,e){const[t,o,r]=R(n,e);return t+Math.abs(t-o)*r*(t<o?1:-1)}const On=/^-?\d+(?:\.\d+)?(\S+)?/;function S(n,e){var t;for(const o of n){const r=(t=o.match)==null?void 0:t.call(o,On);if(r)return r[1]}return e}function p(n,e,t){const o=n.style[e],r=c.css(c.css(n,e,t),e);return n.style[e]=o,r}function B(n,e){return n.reduce((t,o)=>(t[o]=e,t),{})}var L={mixins:[wn],beforeConnect(){this.item=c.closest(this.$el,`.${this.$options.id.replace("parallax","items")} > *`)},disconnected(){this.item=null},events:[{name:"itemin itemout",self:!0,el(){return this.item},handler({type:n,detail:{percent:e,duration:t,timing:o,dir:r}}){c.fastdom.read(()=>{if(!this.matchMedia)return;const i=this.getCss(V(n,r,e)),s=this.getCss(q(n)?.5:r>0?1:0);c.fastdom.write(()=>{c.css(this.$el,i),c.Transition.start(this.$el,s,t,o).catch(c.noop)})})}},{name:"transitioncanceled transitionend",self:!0,el(){return this.item},handler(){c.Transition.cancel(this.$el)}},{name:"itemtranslatein itemtranslateout",self:!0,el(){return this.item},handler({type:n,detail:{percent:e,dir:t}}){c.fastdom.read(()=>{if(!this.matchMedia){this.reset();return}const o=this.getCss(V(n,t,e));c.fastdom.write(()=>c.css(this.$el,o))})}}]};function q(n){return c.endsWith(n,"in")}function V(n,e,t){return t/=2,q(n)^e<0?t:1-t}return typeof window<"u"&&window.UIkit&&window.UIkit.component("sliderParallax",L),L});
1
+ /*! UIkit 3.19.5-dev.5db24934f | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */(function(s,$){typeof exports=="object"&&typeof module<"u"?module.exports=$(require("uikit-util")):typeof define=="function"&&define.amd?define("uikitslider_parallax",["uikit-util"],$):(s=typeof globalThis<"u"?globalThis:s||self,s.UIkitSlider_parallax=$(s.UIkit.util))})(this,function(s){"use strict";var $={props:{media:Boolean},data:{media:!1},connected(){const n=Y(this.media,this.$el);if(this.matchMedia=!0,n){this.mediaObj=window.matchMedia(n);const e=()=>{this.matchMedia=this.mediaObj.matches,s.trigger(this.$el,s.createEvent("mediachange",!1,!0,[this.mediaObj]))};this.offMediaObj=s.on(this.mediaObj,"change",()=>{e(),this.$emit("resize")}),e()}},disconnected(){var n;(n=this.offMediaObj)==null||n.call(this)}};function Y(n,e){if(s.isString(n)){if(s.startsWith(n,"@"))n=s.toFloat(s.css(e,`--uk-breakpoint-${n.substr(1)}`));else if(isNaN(n))return n}return n&&s.isNumeric(n)?`(min-width: ${n}px)`:""}function Z(n,e){var t;return(t=n==null?void 0:n.startsWith)==null?void 0:t.call(n,e)}const{isArray:In,from:k}=Array;function U(n){return typeof n=="function"}function C(n){return n!==null&&typeof n=="object"}function nn(n){return C(n)&&n===n.window}function tn(n){return T(n)===9}function N(n){return T(n)>=1}function T(n){return!nn(n)&&C(n)&&n.nodeType}function M(n){return typeof n=="string"}function en(n){return n===void 0}function b(n){return n&&d(n)[0]}function d(n){return N(n)?[n]:Array.from(n||[]).filter(N)}function A(n){const e=Object.create(null);return(t,...o)=>e[t]||(e[t]=n(t,...o))}function O(n,e,t){var o;if(C(e)){for(const r in e)O(n,r,e[r]);return}if(en(t))return(o=b(n))==null?void 0:o.getAttribute(e);for(const r of d(n))U(t)&&(t=t.call(r,O(r,e))),t===null?rn(r,e):r.setAttribute(e,t)}function rn(n,e){d(n).forEach(t=>t.removeAttribute(e))}function on(n){var e;return(e=b(n))==null?void 0:e.parentElement}function sn(n,e){return d(n).filter(t=>E(t,e))}function E(n,e){return d(n).some(t=>t.matches(e))}function cn(n,e){n=b(n);const t=n?k(n.children):[];return e?sn(t,e):t}function W(n,e){return e?d(n).indexOf(b(e)):cn(on(n)).indexOf(n)}function an(n,e){return d(ln(n,b(e),"querySelectorAll"))}const fn=/([!>+~-])(?=\s+[!>+~-]|\s*$)/g,un=/.*?[^\\](?![^(]*\))(?:,|$)/g,dn=/\s*,$/,hn=A(n=>{var e;n=n.replace(fn,"$1 *");let t=!1;const o=[];for(let r of(e=n.match(un))!=null?e:[])r=r.replace(dn,"").trim(),r[0]===">"&&(r=`:scope ${r}`),t||(t=["!","+","~","-"].includes(r[0])),o.push(r);return{selector:o.join(","),selectors:o,isContextSelector:t}}),D=A(n=>{n=n.substr(1).trim();const e=n.indexOf(" ");return~e?[n.substring(0,e),n.substring(e+1)]:[n,""]});function ln(n,e=document,t){if(!n||!M(n))return n;const o=hn(n);if(!o.isContextSelector)return P(e,t,o.selector);n="";const r=o.selectors.length===1;for(let i of o.selectors){let a,c=e;if(i[0]==="!"&&([a,i]=D(i),c=e.parentElement.closest(a),!i&&r))return c;if(c&&i[0]==="-"){if([a,i]=D(i),c=c.previousElementSibling,c=E(c,a)?c:null,!i&&r)return c}else if(i[0]==="~"||i[0]==="+"&&r)return P(c.parentElement,t,`:scope :nth-child(${W(c)+1}) ${i}`);c&&(n+=`${n?",":""}${gn(c)} ${i}`)}return tn(e)||(e=e.ownerDocument),P(e,t,n)}function P(n,e,t){try{return n[e](t)}catch{return null}}function gn(n){const e=[];for(;n.parentNode;){const t=O(n,"id");if(t){e.unshift(`#${mn(t)}`);break}else{let{tagName:o}=n;o!=="HTML"&&(o+=`:nth-child(${W(n)+1})`),e.unshift(o),n=n.parentNode}}return e.join(" > ")}function mn(n){return M(n)?CSS.escape(n):""}const $n=/^<(\w+)\s*\/?>(?:<\/\1>)?$/;function bn(n){const e=$n.exec(n);if(e)return document.createElement(e[1]);const t=document.createElement("template");return t.innerHTML=n.trim(),xn(t.content.childNodes)}function xn(n){return n.length>1?n:n[0]}function pn(n,e){return yn(n)?d(bn(n)):an(n,e)}function yn(n){return M(n)&&Z(n.trim(),"<")}function wn(n){return Math.ceil(Math.max(0,...pn("[stroke]",n).map(e=>{var t;return(t=e.getTotalLength)==null?void 0:t.call(e)})))}const w={x:v,y:v,rotate:v,scale:v,color:j,backgroundColor:j,borderColor:j,blur:g,hue:g,fopacity:g,grayscale:g,invert:g,saturate:g,sepia:g,opacity:Fn,stroke:Cn,bgx:R,bgy:R},{keys:H}=Object;var vn={mixins:[$],props:q(H(w),"list"),data:q(H(w),void 0),computed:{props(n,e){const t={};for(const r in n)r in w&&!s.isUndefined(n[r])&&(t[r]=n[r].slice());const o={};for(const r in t)o[r]=w[r](r,e,t[r],t);return o}},events:{load(){this.$emit()}},methods:{reset(){for(const n in this.getCss(0))s.css(this.$el,n,"")},getCss(n){const e={};for(const t in this.props)this.props[t](e,s.clamp(n));return e.willChange=Object.keys(e).map(s.propName).join(","),e}}};function v(n,e,t){let o=F(t)||{x:"px",y:"px",rotate:"deg"}[n]||"",r;return n==="x"||n==="y"?(n=`translate${s.ucfirst(n)}`,r=i=>s.toFloat(s.toFloat(i).toFixed(o==="px"?0:6))):n==="scale"&&(o="",r=i=>{var a;return F([i])?s.toPx(i,"width",e,!0)/e[`offset${(a=i.endsWith)!=null&&a.call(i,"vh")?"Height":"Width"}`]:s.toFloat(i)}),t.length===1&&t.unshift(n==="scale"?1:0),t=m(t,r),(i,a)=>{i.transform=`${i.transform||""} ${n}(${x(t,a)}${o})`}}function j(n,e,t){return t.length===1&&t.unshift(p(e,n,"")),t=m(t,o=>Sn(e,o)),(o,r)=>{const[i,a,c]=V(t,r),h=i.map((l,f)=>(l+=c*(a[f]-l),f===3?s.toFloat(l):parseInt(l,10))).join(",");o[n]=`rgba(${h})`}}function Sn(n,e){return p(n,"color",e).split(/[(),]/g).slice(1,-1).concat(1).slice(0,4).map(s.toFloat)}function g(n,e,t){t.length===1&&t.unshift(0);const o=F(t)||{blur:"px",hue:"deg"}[n]||"%";return n={fopacity:"opacity",hue:"hue-rotate"}[n]||n,t=m(t),(r,i)=>{const a=x(t,i);r.filter=`${r.filter||""} ${n}(${a+o})`}}function Fn(n,e,t){return t.length===1&&t.unshift(p(e,n,"")),t=m(t),(o,r)=>{o[n]=x(t,r)}}function Cn(n,e,t){t.length===1&&t.unshift(0);const o=F(t),r=wn(e);return t=m(t.reverse(),i=>(i=s.toFloat(i),o==="%"?i*r/100:i)),t.some(([i])=>i)?(s.css(e,"strokeDasharray",r),(i,a)=>{i.strokeDashoffset=x(t,a)}):s.noop}function R(n,e,t,o){t.length===1&&t.unshift(0);const r=n==="bgy"?"height":"width";o[n]=m(t,c=>s.toPx(c,r,e));const i=["bgx","bgy"].filter(c=>c in o);if(i.length===2&&n==="bgx")return s.noop;if(p(e,"backgroundSize","")==="cover")return Mn(n,e,t,o);const a={};for(const c of i)a[c]=z(e,c);return B(i,a,o)}function Mn(n,e,t,o){const r=On(e);if(!r.width)return s.noop;const i={width:e.offsetWidth,height:e.offsetHeight},a=["bgx","bgy"].filter(f=>f in o),c={};for(const f of a){const u=o[f].map(([jn])=>jn),y=Math.min(...u),_=Math.max(...u),K=u.indexOf(y)<u.indexOf(_),X=_-y;c[f]=`${(K?-X:0)-(K?y:_)}px`,i[f==="bgy"?"height":"width"]+=X}const h=s.Dimensions.cover(r,i);for(const f of a){const u=f==="bgy"?"height":"width",y=h[u]-i[u];c[f]=`max(${z(e,f)},-${y}px) + ${c[f]}`}const l=B(a,c,o);return(f,u)=>{l(f,u),f.backgroundSize=`${h.width}px ${h.height}px`,f.backgroundRepeat="no-repeat"}}function z(n,e){return p(n,`background-position-${e.substr(-1)}`,"")}function B(n,e,t){return function(o,r){for(const i of n){const a=x(t[i],r);o[`background-position-${i.substr(-1)}`]=`calc(${e[i]} + ${a}px)`}}}const L={},S={};function On(n){const e=s.css(n,"backgroundImage").replace(/^none|url\(["']?(.+?)["']?\)$/,"$1");if(S[e])return S[e];const t=new Image;return e&&(t.src=e,!t.naturalWidth&&!L[e])?(s.once(t,"error load",()=>{S[e]=I(t),s.trigger(n,s.createEvent("load",!1))}),L[e]=!0,I(t)):S[e]=I(t)}function I(n){return{width:n.naturalWidth,height:n.naturalHeight}}function m(n,e=s.toFloat){const t=[],{length:o}=n;let r=0;for(let i=0;i<o;i++){let[a,c]=s.isString(n[i])?n[i].trim().split(/ (?![^(]*\))/):[n[i]];if(a=e(a),c=c?s.toFloat(c)/100:null,i===0?c===null?c=0:c&&t.push([a,0]):i===o-1&&(c===null?c=1:c!==1&&(t.push([a,c]),c=1)),t.push([a,c]),c===null)r++;else if(r){const h=t[i-r-1][1],l=(c-h)/(r+1);for(let f=r;f>0;f--)t[i-f][1]=h+l*(r-f+1);r=0}}return t}function V(n,e){const t=s.findIndex(n.slice(1),([,o])=>e<=o)+1;return[n[t-1][0],n[t][0],(e-n[t-1][1])/(n[t][1]-n[t-1][1])]}function x(n,e){const[t,o,r]=V(n,e);return t+Math.abs(t-o)*r*(t<o?1:-1)}const Pn=/^-?\d+(?:\.\d+)?(\S+)?/;function F(n,e){var t;for(const o of n){const r=(t=o.match)==null?void 0:t.call(o,Pn);if(r)return r[1]}return e}function p(n,e,t){const o=n.style[e],r=s.css(s.css(n,e,t),e);return n.style[e]=o,r}function q(n,e){return n.reduce((t,o)=>(t[o]=e,t),{})}var Q={mixins:[vn],beforeConnect(){this.item=this.$el.closest(`.${this.$options.id.replace("parallax","items")} > *`)},disconnected(){this.item=null},events:[{name:"itemin itemout",self:!0,el(){return this.item},handler({type:n,detail:{percent:e,duration:t,timing:o,dir:r}}){s.fastdom.read(()=>{if(!this.matchMedia)return;const i=this.getCss(J(n,r,e)),a=this.getCss(G(n)?.5:r>0?1:0);s.fastdom.write(()=>{s.css(this.$el,i),s.Transition.start(this.$el,a,t,o).catch(s.noop)})})}},{name:"transitioncanceled transitionend",self:!0,el(){return this.item},handler(){s.Transition.cancel(this.$el)}},{name:"itemtranslatein itemtranslateout",self:!0,el(){return this.item},handler({type:n,detail:{percent:e,dir:t}}){s.fastdom.read(()=>{if(!this.matchMedia){this.reset();return}const o=this.getCss(J(n,t,e));s.fastdom.write(()=>s.css(this.$el,o))})}}]};function G(n){return s.endsWith(n,"in")}function J(n,e,t){return t/=2,G(n)^e<0?t:1-t}return typeof window<"u"&&window.UIkit&&window.UIkit.component("sliderParallax",Q),Q});