uikit 3.23.13-dev.f819730bb → 3.23.14-dev.be820cd99

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 (128) hide show
  1. package/.prettierignore +1 -0
  2. package/CHANGELOG.md +36 -0
  3. package/dist/css/uikit-core-rtl.css +301 -111
  4. package/dist/css/uikit-core-rtl.min.css +1 -1
  5. package/dist/css/uikit-core.css +301 -111
  6. package/dist/css/uikit-core.min.css +1 -1
  7. package/dist/css/uikit-rtl.css +305 -111
  8. package/dist/css/uikit-rtl.min.css +1 -1
  9. package/dist/css/uikit.css +305 -111
  10. package/dist/css/uikit.min.css +1 -1
  11. package/dist/js/components/countdown.js +1 -1
  12. package/dist/js/components/countdown.min.js +1 -1
  13. package/dist/js/components/filter.js +49 -23
  14. package/dist/js/components/filter.min.js +1 -1
  15. package/dist/js/components/lightbox-panel.js +19 -14
  16. package/dist/js/components/lightbox-panel.min.js +1 -1
  17. package/dist/js/components/lightbox.js +19 -14
  18. package/dist/js/components/lightbox.min.js +1 -1
  19. package/dist/js/components/notification.js +1 -1
  20. package/dist/js/components/notification.min.js +1 -1
  21. package/dist/js/components/parallax.js +2 -2
  22. package/dist/js/components/parallax.min.js +1 -1
  23. package/dist/js/components/slider-parallax.js +2 -2
  24. package/dist/js/components/slider-parallax.min.js +1 -1
  25. package/dist/js/components/slider.js +8 -3
  26. package/dist/js/components/slider.min.js +1 -1
  27. package/dist/js/components/slideshow-parallax.js +2 -2
  28. package/dist/js/components/slideshow-parallax.min.js +1 -1
  29. package/dist/js/components/slideshow.js +8 -3
  30. package/dist/js/components/slideshow.min.js +1 -1
  31. package/dist/js/components/sortable.js +48 -22
  32. package/dist/js/components/sortable.min.js +1 -1
  33. package/dist/js/components/tooltip.js +3 -3
  34. package/dist/js/components/tooltip.min.js +1 -1
  35. package/dist/js/components/upload.js +2 -2
  36. package/dist/js/components/upload.min.js +1 -1
  37. package/dist/js/uikit-core.js +134 -63
  38. package/dist/js/uikit-core.min.js +1 -1
  39. package/dist/js/uikit-icons.js +1 -1
  40. package/dist/js/uikit-icons.min.js +1 -1
  41. package/dist/js/uikit.js +183 -90
  42. package/dist/js/uikit.min.js +1 -1
  43. package/eslint.config.mjs +1 -1
  44. package/package.json +1 -1
  45. package/src/images/backgrounds/form-checkbox.svg +2 -2
  46. package/src/images/components/navbar-toggle-icon.svg +14 -7
  47. package/src/js/api/options.js +1 -1
  48. package/src/js/components/lightbox-panel.js +6 -4
  49. package/src/js/components/upload.js +1 -3
  50. package/src/js/core/drop.js +3 -8
  51. package/src/js/core/dropnav.js +4 -4
  52. package/src/js/core/img.js +1 -1
  53. package/src/js/core/index.js +1 -0
  54. package/src/js/core/navbar.js +3 -5
  55. package/src/js/core/overflow-fade.js +67 -0
  56. package/src/js/core/scrollspy.js +10 -10
  57. package/src/js/core/sticky.js +18 -16
  58. package/src/js/core/toggle.js +3 -5
  59. package/src/js/core/video.js +36 -10
  60. package/src/js/mixin/internal/animate-fade.js +32 -15
  61. package/src/js/mixin/internal/animate-slide.js +27 -9
  62. package/src/js/mixin/modal.js +3 -4
  63. package/src/js/mixin/slider.js +3 -1
  64. package/src/js/mixin/togglable.js +1 -1
  65. package/src/js/util/animation.js +3 -4
  66. package/src/js/util/await.js +7 -0
  67. package/src/js/util/player.js +1 -3
  68. package/src/js/util/scroll.js +2 -2
  69. package/src/js/util/selector.js +1 -1
  70. package/src/js/util/viewport.js +1 -1
  71. package/src/less/components/base.less +19 -4
  72. package/src/less/components/card.less +40 -1
  73. package/src/less/components/countdown.less +4 -42
  74. package/src/less/components/form.less +87 -67
  75. package/src/less/components/heading.less +0 -84
  76. package/src/less/components/icon.less +44 -0
  77. package/src/less/components/navbar.less +23 -9
  78. package/src/less/components/position.less +1 -1
  79. package/src/less/components/section.less +33 -0
  80. package/src/less/components/subnav.less +1 -1
  81. package/src/less/components/utility.less +45 -0
  82. package/src/less/components/visibility.less +1 -1
  83. package/src/less/components/width.less +0 -5
  84. package/src/less/theme/card.less +13 -0
  85. package/src/less/theme/icon.less +14 -0
  86. package/src/scss/components/base.scss +19 -4
  87. package/src/scss/components/card.scss +35 -1
  88. package/src/scss/components/countdown.scss +2 -40
  89. package/src/scss/components/form.scss +73 -55
  90. package/src/scss/components/heading.scss +0 -83
  91. package/src/scss/components/icon.scss +22 -0
  92. package/src/scss/components/navbar.scss +23 -9
  93. package/src/scss/components/position.scss +1 -1
  94. package/src/scss/components/section.scss +33 -0
  95. package/src/scss/components/subnav.scss +1 -1
  96. package/src/scss/components/utility.scss +45 -0
  97. package/src/scss/components/visibility.scss +1 -1
  98. package/src/scss/components/width.scss +0 -15
  99. package/src/scss/mixins-theme.scss +28 -8
  100. package/src/scss/mixins.scss +25 -8
  101. package/src/scss/variables-theme.scss +27 -30
  102. package/src/scss/variables.scss +25 -30
  103. package/tests/article.html +7 -7
  104. package/tests/base.html +13 -13
  105. package/tests/card.html +9 -1
  106. package/tests/column.html +1 -1
  107. package/tests/countdown.html +595 -8
  108. package/tests/cover.html +7 -13
  109. package/tests/dropbar.html +3 -3
  110. package/tests/dropdown.html +13 -13
  111. package/tests/dropnav.html +9 -9
  112. package/tests/form.html +56 -3
  113. package/tests/icon.html +31 -0
  114. package/tests/index.html +68 -58
  115. package/tests/js/index.js +76 -83
  116. package/tests/lightbox.html +4 -4
  117. package/tests/link.html +71 -8
  118. package/tests/modal.html +1 -1
  119. package/tests/navbar.html +32 -32
  120. package/tests/notification.html +5 -5
  121. package/tests/search.html +3 -3
  122. package/tests/slideshow.html +3 -3
  123. package/tests/sticky-navbar.html +72 -72
  124. package/tests/subnav.html +106 -2
  125. package/tests/tab.html +68 -21
  126. package/tests/table.html +8 -8
  127. package/tests/utility.html +159 -1
  128. package/tests/video.html +137 -10
package/dist/js/uikit.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! UIkit 3.23.13-dev.f819730bb | https://www.getuikit.com | (c) 2014 - 2025 YOOtheme | MIT License */
1
+ /*! UIkit 3.23.14-dev.be820cd99 | https://www.getuikit.com | (c) 2014 - 2025 YOOtheme | MIT License */
2
2
 
3
3
  (function (global, factory) {
4
4
  typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
@@ -442,7 +442,7 @@
442
442
  function _doQuery(context, queryFn, selector) {
443
443
  try {
444
444
  return context[queryFn](selector);
445
- } catch (e) {
445
+ } catch {
446
446
  return null;
447
447
  }
448
448
  }
@@ -643,13 +643,13 @@
643
643
  const clsTransition = "uk-transition";
644
644
  const transitionEnd = "transitionend";
645
645
  const transitionCanceled = "transitioncanceled";
646
- function transition$1(element, props, duration = 400, timing = "linear") {
646
+ function transition$1(element, props, duration = 400, timing = "linear", skipReflow) {
647
647
  duration = Math.round(duration);
648
648
  return Promise.all(
649
649
  toNodes(element).map(
650
650
  (element2) => new Promise((resolve, reject) => {
651
- for (const name in props) {
652
- css(element2, name);
651
+ if (!skipReflow) {
652
+ element2.offsetHeight;
653
653
  }
654
654
  const timer = setTimeout(() => trigger(element2, transitionEnd), duration);
655
655
  once(
@@ -1186,7 +1186,7 @@
1186
1186
  try {
1187
1187
  data = JSON.parse(data);
1188
1188
  return youtube && (data == null ? void 0 : data.id) === id && data.event === "onReady" || vimeo && Number(data == null ? void 0 : data.player_id) === id;
1189
- } catch (e) {
1189
+ } catch {
1190
1190
  }
1191
1191
  });
1192
1192
  el.src = `${el.src}${includes(el.src, "?") ? "&" : "?"}${youtube ? "enablejsapi=1" : `api=1&player_id=${id}`}`;
@@ -1343,7 +1343,7 @@
1343
1343
  parents(target).reverse().find(
1344
1344
  (parent2) => !parent2.contains(el) && !hasPosition(parent2, "static")
1345
1345
  )
1346
- ) < zIndex(el) || hasPosition(el, "sticky") && parent(el).contains(target)) && (!coverEl || dimensions$1(coverEl).height < dimensions$1(el).height)) {
1346
+ ) < zIndex(el) || hasPosition(el, "sticky") && (!target || parent(el).contains(target))) && (!coverEl || dimensions$1(coverEl).height < dimensions$1(el).height)) {
1347
1347
  coverEl = el;
1348
1348
  }
1349
1349
  }
@@ -1867,7 +1867,7 @@
1867
1867
  }
1868
1868
  return options2;
1869
1869
  }, {}) : {};
1870
- } catch (e) {
1870
+ } catch {
1871
1871
  return {};
1872
1872
  }
1873
1873
  }
@@ -2130,6 +2130,13 @@
2130
2130
  };
2131
2131
  }
2132
2132
 
2133
+ function awaitFrame() {
2134
+ return new Promise((resolve) => requestAnimationFrame(resolve));
2135
+ }
2136
+ function awaitTimeout(timeout) {
2137
+ return new Promise((resolve) => setTimeout(resolve, timeout));
2138
+ }
2139
+
2133
2140
  const clsLeave = "uk-transition-leave";
2134
2141
  const clsEnter = "uk-transition-enter";
2135
2142
  function fade(action, target, duration, stagger = 0) {
@@ -2140,12 +2147,18 @@
2140
2147
  const wrapIndexFn = (fn) => () => isCurrentIndex() ? fn() : Promise.reject();
2141
2148
  const leaveFn = wrapIndexFn(async () => {
2142
2149
  addClass(target, clsLeave);
2143
- await (stagger ? Promise.all(
2144
- getTransitionNodes(target).map(async (child, i) => {
2145
- await awaitTimeout(i * stagger);
2146
- return Transition.start(child, propsOut, duration / 2, "ease");
2147
- })
2148
- ) : Transition.start(target, propsOut, duration / 2, "ease"));
2150
+ await (stagger ? getTransitionNodes(target).reduce(async (promise, child, i, array) => {
2151
+ await promise;
2152
+ if (!isInView(child) || !isCurrentIndex()) {
2153
+ css(child, propsOut);
2154
+ return;
2155
+ }
2156
+ await awaitTimeout(stagger);
2157
+ const transition = Transition.start(child, propsOut, duration / 2, "ease");
2158
+ if (array.length - 1 === i) {
2159
+ await transition;
2160
+ }
2161
+ }, Promise.resolve()) : Transition.start(target, propsOut, duration / 2, "ease"));
2149
2162
  removeClass(target, clsLeave);
2150
2163
  });
2151
2164
  const enterFn = wrapIndexFn(async () => {
@@ -2164,13 +2177,20 @@
2164
2177
  if (stagger) {
2165
2178
  const nodes = getTransitionNodes(target);
2166
2179
  css(children(target), propsOut);
2167
- transitions = nodes.map(async (child, i) => {
2168
- await awaitTimeout(i * stagger);
2169
- await Transition.start(child, propsIn, duration / 2, "ease");
2170
- if (isCurrentIndex()) {
2180
+ transitions = nodes.reduce(async (promise, child, i, array) => {
2181
+ await promise;
2182
+ if (!isInView(child) || !isCurrentIndex()) {
2171
2183
  resetProps(child, propsIn);
2184
+ return;
2172
2185
  }
2173
- });
2186
+ await awaitTimeout(stagger);
2187
+ const transition = Transition.start(child, propsIn, duration / 2, "ease").then(
2188
+ () => isCurrentIndex() && resetProps(child, propsIn)
2189
+ );
2190
+ if (array.length - 1 === i) {
2191
+ await transition;
2192
+ }
2193
+ }, Promise.resolve());
2174
2194
  targetDuration += nodes.length * stagger;
2175
2195
  }
2176
2196
  if (!stagger || oldHeight !== newHeight) {
@@ -2202,31 +2222,35 @@
2202
2222
  function getTransitionNodes(target) {
2203
2223
  return getRows(children(target)).flat().filter(isVisible);
2204
2224
  }
2205
- function awaitTimeout(timeout) {
2206
- return new Promise((resolve) => setTimeout(resolve, timeout));
2207
- }
2208
2225
 
2209
2226
  async function slide(action, target, duration) {
2210
2227
  await awaitFrame();
2211
2228
  let nodes = children(target);
2212
2229
  const currentProps = nodes.map((el) => getProps$1(el, true));
2213
2230
  const targetProps = { ...css(target, ["height", "padding"]), display: "block" };
2231
+ const transitionNodes = nodes.filter((node) => isInView(node));
2214
2232
  const targets = nodes.concat(target);
2215
2233
  await Promise.all(targets.map(Transition.cancel));
2216
2234
  css(targets, "transitionProperty", "none");
2217
2235
  await action();
2218
- nodes = nodes.concat(children(target).filter((el) => !includes(nodes, el)));
2236
+ const newNodes = children(target).filter((el) => !includes(nodes, el));
2237
+ nodes = nodes.concat(newNodes);
2219
2238
  await Promise.resolve();
2220
2239
  css(targets, "transitionProperty", "");
2221
2240
  const targetStyle = attr(target, "style");
2222
2241
  const targetPropsTo = css(target, ["height", "padding"]);
2223
2242
  const [propsTo, propsFrom] = getTransitionProps(target, nodes, currentProps);
2224
2243
  const attrsTo = nodes.map((el) => ({ style: attr(el, "style") }));
2244
+ transitionNodes.push(...nodes.filter((node) => isInView(node)));
2225
2245
  nodes.forEach((el, i) => propsFrom[i] && css(el, propsFrom[i]));
2226
2246
  css(target, targetProps);
2227
2247
  trigger(target, "scroll");
2228
2248
  await awaitFrame();
2229
- const transitions = nodes.map((el, i) => parent(el) === target && Transition.start(el, propsTo[i], duration, "ease")).concat(Transition.start(target, targetPropsTo, duration, "ease"));
2249
+ const transitions = nodes.map((el, i) => {
2250
+ if (parent(el) === target && transitionNodes.includes(el)) {
2251
+ return Transition.start(el, propsTo[i], duration, "ease", !newNodes.includes(el));
2252
+ }
2253
+ }).concat(Transition.start(target, targetPropsTo, duration, "ease", true));
2230
2254
  try {
2231
2255
  await Promise.all(transitions);
2232
2256
  nodes.forEach((el, i) => {
@@ -2236,7 +2260,7 @@
2236
2260
  }
2237
2261
  });
2238
2262
  attr(target, "style", targetStyle);
2239
- } catch (e) {
2263
+ } catch {
2240
2264
  attr(nodes, "style", "");
2241
2265
  resetProps(target, targetProps);
2242
2266
  }
@@ -2277,17 +2301,19 @@
2277
2301
  }
2278
2302
  function getPositionWithMargin(el) {
2279
2303
  const { height, width } = dimensions$1(el);
2304
+ let { top, left } = position(el);
2305
+ const viewport = offsetViewport(el.ownerDocument);
2306
+ top = clamp(top, viewport.top - height - viewport.height, viewport.bottom + viewport.height);
2307
+ left = clamp(left, viewport.left - width - viewport.width, viewport.right + viewport.width);
2280
2308
  return {
2281
2309
  height,
2282
2310
  width,
2311
+ top,
2312
+ left,
2283
2313
  transform: "",
2284
- ...position(el),
2285
2314
  ...css(el, ["marginTop", "marginLeft"])
2286
2315
  };
2287
2316
  }
2288
- function awaitFrame() {
2289
- return new Promise((resolve) => requestAnimationFrame(resolve));
2290
- }
2291
2317
 
2292
2318
  var Animate = {
2293
2319
  props: {
@@ -2569,7 +2595,7 @@
2569
2595
  if (startsWith(sources, "[")) {
2570
2596
  try {
2571
2597
  sources = JSON.parse(sources);
2572
- } catch (e) {
2598
+ } catch {
2573
2599
  sources = [];
2574
2600
  }
2575
2601
  } else {
@@ -2627,7 +2653,7 @@
2627
2653
  const props = {
2628
2654
  overflowY: CSS.supports("overflow", "clip") ? "clip" : "hidden",
2629
2655
  touchAction: "none",
2630
- paddingRight: width(window) - scrollingElement.clientWidth || ""
2656
+ scrollbarGutter: "stable"
2631
2657
  };
2632
2658
  css(scrollingElement, props);
2633
2659
  return () => {
@@ -2780,7 +2806,7 @@
2780
2806
  })
2781
2807
  );
2782
2808
  return true;
2783
- } catch (e) {
2809
+ } catch {
2784
2810
  return false;
2785
2811
  }
2786
2812
  },
@@ -3055,12 +3081,10 @@
3055
3081
  toggle() {
3056
3082
  return this.isToggled() ? this.hide() : this.show();
3057
3083
  },
3058
- show() {
3084
+ async show() {
3059
3085
  if (this.container && parent(this.$el) !== this.container) {
3060
3086
  append(this.container, this.$el);
3061
- return new Promise(
3062
- (resolve) => requestAnimationFrame(() => this.show().then(resolve))
3063
- );
3087
+ await awaitFrame();
3064
3088
  }
3065
3089
  return this.toggleElement(this.$el, true, animate$1);
3066
3090
  },
@@ -3758,7 +3782,7 @@
3758
3782
  };
3759
3783
  App.util = util;
3760
3784
  App.options = {};
3761
- App.version = "3.23.13-dev.f819730bb";
3785
+ App.version = "3.23.14-dev.be820cd99";
3762
3786
 
3763
3787
  const PREFIX = "uk-";
3764
3788
  const DATA = "__uikit__";
@@ -4203,8 +4227,9 @@
4203
4227
  trigger(next, "itemshown", [this]);
4204
4228
  stack.shift();
4205
4229
  this._transitioner = null;
4230
+ await awaitFrame();
4206
4231
  if (stack.length) {
4207
- requestAnimationFrame(() => stack.length && this.show(stack.shift(), true));
4232
+ this.show(stack.shift(), true);
4208
4233
  }
4209
4234
  },
4210
4235
  getIndex(index = this.index, prev = this.index) {
@@ -4581,7 +4606,7 @@
4581
4606
  allowfullscreen: "",
4582
4607
  style: "max-width: 100%; box-sizing: border-box;",
4583
4608
  "uk-responsive": "",
4584
- "uk-video": `${Boolean(this.videoAutoplay)}`
4609
+ "uk-video": Boolean(this.videoAutoplay)
4585
4610
  };
4586
4611
  if (type === "image" || isImage(src)) {
4587
4612
  const img = createEl("img");
@@ -4600,8 +4625,9 @@
4600
4625
  playsinline: "",
4601
4626
  controls: inline ? null : "",
4602
4627
  loop: inline ? "" : null,
4628
+ muted: inline ? "" : null,
4603
4629
  poster: this.videoAutoplay ? null : item.poster,
4604
- "uk-video": inline ? "automute: true" : Boolean(this.videoAutoplay),
4630
+ "uk-video": Boolean(this.videoAutoplay),
4605
4631
  ...attrs
4606
4632
  });
4607
4633
  on(video, "loadedmetadata", () => this.setItem(item, video));
@@ -4647,7 +4673,7 @@
4647
4673
  ...attrs
4648
4674
  })
4649
4675
  );
4650
- } catch (e) {
4676
+ } catch {
4651
4677
  this.setError(item);
4652
4678
  }
4653
4679
  }
@@ -4714,7 +4740,8 @@
4714
4740
  src: item.thumb,
4715
4741
  loop: "",
4716
4742
  playsinline: "",
4717
- "uk-video": `autoplay: ${Boolean(videoAutoplay)}; automute: true`
4743
+ muted: "",
4744
+ "uk-video": videoAutoplay === "inline"
4718
4745
  }) : createEl("canvas");
4719
4746
  if (item.thumbRatio) {
4720
4747
  el.style.aspectRatio = item.thumbRatio;
@@ -6558,7 +6585,7 @@
6558
6585
  if (prop in xhr) {
6559
6586
  try {
6560
6587
  xhr[prop] = env[prop];
6561
- } catch (e) {
6588
+ } catch {
6562
6589
  }
6563
6590
  }
6564
6591
  }
@@ -6898,63 +6925,77 @@
6898
6925
  args: "autoplay",
6899
6926
  props: {
6900
6927
  automute: Boolean,
6901
- autoplay: Boolean
6928
+ autoplay: Boolean,
6929
+ restart: Boolean,
6930
+ hoverTarget: Boolean
6902
6931
  },
6903
6932
  data: {
6904
6933
  automute: false,
6905
- autoplay: true
6934
+ autoplay: true,
6935
+ restart: false,
6936
+ hoverTarget: false
6906
6937
  },
6907
6938
  beforeConnect() {
6908
- if (this.autoplay === "inview" && !hasAttr(this.$el, "preload")) {
6939
+ const isVideo = isTag(this.$el, "video");
6940
+ if (this.autoplay === "inview" && isVideo && !hasAttr(this.$el, "preload")) {
6909
6941
  this.$el.preload = "none";
6910
6942
  }
6911
- if (isTag(this.$el, "iframe") && !hasAttr(this.$el, "allow")) {
6943
+ if (!isVideo && !hasAttr(this.$el, "allow")) {
6912
6944
  this.$el.allow = "autoplay";
6913
6945
  }
6914
6946
  if (this.autoplay === "hover") {
6915
- if (isTag(this.$el, "video")) {
6947
+ if (isVideo) {
6916
6948
  this.$el.tabIndex = 0;
6917
6949
  } else {
6918
6950
  this.autoplay = true;
6919
6951
  }
6920
6952
  }
6921
- if (this.automute) {
6953
+ if (this.automute || hasAttr(this.$el, "muted")) {
6922
6954
  mute(this.$el);
6923
6955
  }
6924
6956
  },
6925
6957
  events: [
6926
6958
  {
6927
6959
  name: `${pointerEnter} focusin`,
6960
+ el: ({ hoverTarget, $el }) => query(hoverTarget, $el) || $el,
6928
6961
  filter: ({ autoplay }) => includes(autoplay, "hover"),
6929
6962
  handler(e) {
6930
6963
  if (!isTouch(e) || !isPlaying(this.$el)) {
6931
6964
  play(this.$el);
6932
6965
  } else {
6933
- pause(this.$el);
6966
+ pauseHover(this.$el, this.restart);
6934
6967
  }
6935
6968
  }
6936
6969
  },
6937
6970
  {
6938
6971
  name: `${pointerLeave} focusout`,
6972
+ el: ({ hoverTarget, $el }) => query(hoverTarget, $el) || $el,
6939
6973
  filter: ({ autoplay }) => includes(autoplay, "hover"),
6940
6974
  handler(e) {
6941
6975
  if (!isTouch(e)) {
6942
- pause(this.$el);
6976
+ pauseHover(this.$el, this.restart);
6943
6977
  }
6944
6978
  }
6945
6979
  }
6946
6980
  ],
6947
6981
  observe: [
6948
6982
  intersection({
6949
- filter: ({ autoplay }) => autoplay !== "hover",
6950
- handler([{ isIntersecting }]) {
6983
+ filter: ({ $el }) => $el.preload === "none",
6984
+ handler([{ target }]) {
6985
+ target.preload = "";
6986
+ this.$reset();
6987
+ }
6988
+ }),
6989
+ intersection({
6990
+ filter: ({ $el, autoplay }) => autoplay !== "hover" && $el.preload !== "none",
6991
+ handler([{ isIntersecting, target }]) {
6951
6992
  if (!document.fullscreenElement) {
6952
6993
  if (isIntersecting) {
6953
6994
  if (this.autoplay) {
6954
- play(this.$el);
6995
+ play(target);
6955
6996
  }
6956
6997
  } else {
6957
- pause(this.$el);
6998
+ pauseHover(target, this.restart);
6958
6999
  }
6959
7000
  }
6960
7001
  },
@@ -6968,6 +7009,12 @@
6968
7009
  function isPlaying(videoEl) {
6969
7010
  return !videoEl.paused && !videoEl.ended;
6970
7011
  }
7012
+ function pauseHover(el, restart) {
7013
+ pause(el);
7014
+ if (restart && isTag(el, "video")) {
7015
+ el.currentTime = 0;
7016
+ }
7017
+ }
6971
7018
 
6972
7019
  var cover = {
6973
7020
  mixins: [Video],
@@ -7014,7 +7061,7 @@
7014
7061
 
7015
7062
  let active;
7016
7063
  var drop = {
7017
- mixins: [Container, Position, Togglable],
7064
+ mixins: [Class, Container, Position, Togglable],
7018
7065
  args: "pos",
7019
7066
  props: {
7020
7067
  mode: "list",
@@ -7029,7 +7076,6 @@
7029
7076
  delayShow: Number,
7030
7077
  delayHide: Number,
7031
7078
  autoUpdate: Boolean,
7032
- clsDrop: String,
7033
7079
  animateOut: Boolean,
7034
7080
  bgScroll: Boolean,
7035
7081
  closeOnScroll: Boolean
@@ -7047,7 +7093,6 @@
7047
7093
  delayShow: 0,
7048
7094
  delayHide: 800,
7049
7095
  autoUpdate: true,
7050
- clsDrop: false,
7051
7096
  animateOut: false,
7052
7097
  bgScroll: true,
7053
7098
  animation: ["uk-animation-fade"],
@@ -7075,11 +7120,8 @@
7075
7120
  created() {
7076
7121
  this.tracker = new MouseTracker();
7077
7122
  },
7078
- beforeConnect() {
7079
- this.clsDrop = this.$props.clsDrop || this.$options.id;
7080
- },
7081
7123
  connected() {
7082
- addClass(this.$el, "uk-drop", this.clsDrop);
7124
+ addClass(this.$el, "uk-drop");
7083
7125
  if (this.toggle && !this.targetEl) {
7084
7126
  this.targetEl = createToggleComponent(this);
7085
7127
  }
@@ -7388,7 +7430,6 @@
7388
7430
  mixins: [Class, Container],
7389
7431
  props: {
7390
7432
  align: String,
7391
- clsDrop: String,
7392
7433
  boundary: Boolean,
7393
7434
  dropbar: Boolean,
7394
7435
  dropbarAnchor: Boolean,
@@ -7412,6 +7453,7 @@
7412
7453
  boundary: true,
7413
7454
  dropbar: false,
7414
7455
  dropbarAnchor: false,
7456
+ flip: true,
7415
7457
  delayShow: 160,
7416
7458
  duration: 200,
7417
7459
  container: false,
@@ -7424,7 +7466,7 @@
7424
7466
  return null;
7425
7467
  }
7426
7468
  dropbar = this._dropbar || query(dropbar, this.$el) || $(`+ .${this.clsDropbar}`, this.$el);
7427
- return dropbar ? dropbar : this._dropbar = $("<div></div>");
7469
+ return dropbar ? dropbar : this._dropbar = $("<div>");
7428
7470
  },
7429
7471
  dropContainer(_, $el) {
7430
7472
  return this.container || $el;
@@ -7670,10 +7712,10 @@
7670
7712
  this.dropdowns.filter((el) => !this.getDropdown(el)),
7671
7713
  {
7672
7714
  ...this.$props,
7673
- flip: false,
7715
+ flip: this.flip && !this.$props.dropbar,
7674
7716
  shift: true,
7675
7717
  pos: `bottom-${this.align}`,
7676
- boundary: this.boundary === true ? this.$el : this.boundary
7718
+ boundaryX: this.boundary === true ? this.$el : this.boundary
7677
7719
  }
7678
7720
  );
7679
7721
  }
@@ -8082,7 +8124,7 @@
8082
8124
 
8083
8125
  var navbarParentIcon = "<svg width=\"12\" height=\"12\" viewBox=\"0 0 12 12\"><polyline fill=\"none\" stroke=\"#000\" stroke-width=\"1.1\" points=\"1 3.5 6 8.5 11 3.5\"/></svg>";
8084
8126
 
8085
- var navbarToggleIcon = "<svg width=\"20\" height=\"20\" viewBox=\"0 0 20 20\"><style>.uk-navbar-toggle-icon svg&gt;[class*=&quot;line-&quot;]{transition:0.2s ease-in-out;transition-property:transform, opacity;transform-origin:center;opacity:1}.uk-navbar-toggle-icon svg&gt;.line-3{opacity:0}.uk-navbar-toggle-animate[aria-expanded=&quot;true&quot;] svg&gt;.line-3{opacity:1}.uk-navbar-toggle-animate[aria-expanded=&quot;true&quot;] svg&gt;.line-2{transform:rotate(45deg)}.uk-navbar-toggle-animate[aria-expanded=&quot;true&quot;] svg&gt;.line-3{transform:rotate(-45deg)}.uk-navbar-toggle-animate[aria-expanded=&quot;true&quot;] svg&gt;.line-1,.uk-navbar-toggle-animate[aria-expanded=&quot;true&quot;] svg&gt;.line-4{opacity:0}.uk-navbar-toggle-animate[aria-expanded=&quot;true&quot;] svg&gt;.line-1{transform:translateY(6px) scaleX(0)}.uk-navbar-toggle-animate[aria-expanded=&quot;true&quot;] svg&gt;.line-4{transform:translateY(-6px) scaleX(0)}</style><rect width=\"20\" height=\"2\" y=\"3\" class=\"line-1\"/><rect width=\"20\" height=\"2\" y=\"9\" class=\"line-2\"/><rect width=\"20\" height=\"2\" y=\"9\" class=\"line-3\"/><rect width=\"20\" height=\"2\" y=\"15\" class=\"line-4\"/></svg>";
8127
+ var navbarToggleIcon = "<svg width=\"20\" height=\"20\" viewBox=\"0 0 20 20\"><style>.uk-navbar-toggle-icon svg&gt;[class*=&quot;line-&quot;]{transition:0.2s ease-in-out;transition-property:transform, opacity;transform-origin:center;opacity:1}.uk-navbar-toggle-icon svg&gt;.line-3{opacity:0}[aria-expanded=&quot;true&quot;].uk-navbar-toggle-icon svg&gt;.line-3,[aria-expanded=&quot;true&quot;]&gt;.uk-navbar-toggle-icon svg&gt;.line-3{opacity:1}[aria-expanded=&quot;true&quot;].uk-navbar-toggle-icon svg&gt;.line-2,[aria-expanded=&quot;true&quot;]&gt;.uk-navbar-toggle-icon svg&gt;.line-2{transform:rotate(45deg)}[aria-expanded=&quot;true&quot;].uk-navbar-toggle-icon svg&gt;.line-3,[aria-expanded=&quot;true&quot;]&gt;.uk-navbar-toggle-icon svg&gt;.line-3{transform:rotate(-45deg)}[aria-expanded=&quot;true&quot;].uk-navbar-toggle-icon svg&gt;.line-1,[aria-expanded=&quot;true&quot;]&gt;.uk-navbar-toggle-icon svg&gt;.line-1,[aria-expanded=&quot;true&quot;].uk-navbar-toggle-icon svg&gt;.line-4,[aria-expanded=&quot;true&quot;]&gt;.uk-navbar-toggle-icon svg&gt;.line-4{opacity:0}[aria-expanded=&quot;true&quot;].uk-navbar-toggle-icon svg&gt;.line-1,[aria-expanded=&quot;true&quot;]&gt;.uk-navbar-toggle-icon svg&gt;.line-1{transform:translateY(6px) scaleX(0)}[aria-expanded=&quot;true&quot;].uk-navbar-toggle-icon svg&gt;.line-4,[aria-expanded=&quot;true&quot;]&gt;.uk-navbar-toggle-icon svg&gt;.line-4{transform:translateY(-6px) scaleX(0)}</style><rect width=\"20\" height=\"2\" y=\"3\" class=\"line-1\"/><rect width=\"20\" height=\"2\" y=\"9\" class=\"line-2\"/><rect width=\"20\" height=\"2\" y=\"9\" class=\"line-3\"/><rect width=\"20\" height=\"2\" y=\"15\" class=\"line-4\"/></svg>";
8086
8128
 
8087
8129
  var overlayIcon = "<svg width=\"40\" height=\"40\" viewBox=\"0 0 40 40\"><rect width=\"1\" height=\"40\" x=\"19\" y=\"0\"/><rect width=\"40\" height=\"1\" x=\"0\" y=\"19\"/></svg>";
8088
8130
 
@@ -8673,6 +8715,7 @@
8673
8715
  dropbarTransparentMode: Boolean
8674
8716
  },
8675
8717
  data: {
8718
+ flip: false,
8676
8719
  delayShow: 200,
8677
8720
  clsDrop: "uk-navbar-dropdown",
8678
8721
  selNavItem: ".uk-navbar-nav > li > a,a.uk-navbar-item,button.uk-navbar-item,.uk-navbar-item a,.uk-navbar-item button,.uk-navbar-toggle",
@@ -8707,7 +8750,7 @@
8707
8750
  name: "hide",
8708
8751
  el: ({ dropContainer }) => dropContainer,
8709
8752
  async handler() {
8710
- await awaitMacroTask();
8753
+ await awaitTimeout();
8711
8754
  if (this._transparent && (!active || !this.dropContainer.contains(active.$el))) {
8712
8755
  addClass(this.navbarContainer, clsNavbarTransparent);
8713
8756
  this._transparent = null;
@@ -8734,9 +8777,6 @@
8734
8777
  }
8735
8778
  }
8736
8779
  };
8737
- function awaitMacroTask() {
8738
- return new Promise((resolve) => setTimeout(resolve));
8739
- }
8740
8780
 
8741
8781
  var offcanvas = {
8742
8782
  mixins: [Modal],
@@ -8897,6 +8937,59 @@
8897
8937
  }
8898
8938
  };
8899
8939
 
8940
+ var overflowFade = {
8941
+ data: {
8942
+ fadeDuration: 0.05
8943
+ },
8944
+ events: {
8945
+ name: "scroll",
8946
+ self: true,
8947
+ passive: true,
8948
+ handler() {
8949
+ this.$emit();
8950
+ }
8951
+ },
8952
+ observe: [
8953
+ mutation({
8954
+ options: {
8955
+ subtree: true,
8956
+ childList: true
8957
+ }
8958
+ }),
8959
+ resize({
8960
+ target: ({ $el }) => [$el, ...children($el)]
8961
+ })
8962
+ ],
8963
+ update: {
8964
+ read() {
8965
+ const overflow = [];
8966
+ for (const prop of ["Width", "Height"]) {
8967
+ overflow.push(this.$el[`scroll${prop}`] - this.$el[`client${prop}`]);
8968
+ }
8969
+ return { overflow };
8970
+ },
8971
+ write({ overflow }) {
8972
+ for (let i = 0; i < 2; i++) {
8973
+ toggleClass(
8974
+ this.$el,
8975
+ `${this.$options.id}-${i ? "vertical" : "horizontal"}`,
8976
+ overflow[i] && !overflow[i - 1]
8977
+ );
8978
+ if (!overflow[i - 1]) {
8979
+ const dir = i ? "Top" : "Left";
8980
+ const percent = overflow[i] ? this.$el[`scroll${dir}`] / overflow[i] : 0;
8981
+ const toValue = (value) => overflow[i] ? clamp((this.fadeDuration - value) / this.fadeDuration) : 1;
8982
+ css(this.$el, {
8983
+ "--uk-overflow-fade-start-opacity": toValue(percent),
8984
+ "--uk-overflow-fade-end-opacity": toValue(1 - percent)
8985
+ });
8986
+ }
8987
+ }
8988
+ },
8989
+ events: ["resize"]
8990
+ }
8991
+ };
8992
+
8900
8993
  var responsive = {
8901
8994
  props: ["width", "height"],
8902
8995
  connected() {
@@ -8990,7 +9083,7 @@
8990
9083
  },
8991
9084
  disconnected() {
8992
9085
  for (const [el, state] of this.elementData.entries()) {
8993
- removeClass(el, clsInView, (state == null ? void 0 : state.cls) || "");
9086
+ removeClass(el, clsInView, state.cls || "");
8994
9087
  }
8995
9088
  delete this.elementData;
8996
9089
  },
@@ -9021,7 +9114,8 @@
9021
9114
  for (const [el, state] of this.elementData.entries()) {
9022
9115
  if (state.show && !state.inview && !state.queued) {
9023
9116
  state.queued = true;
9024
- data.promise = (data.promise || Promise.resolve()).then(() => new Promise((resolve) => setTimeout(resolve, this.delay))).then(() => {
9117
+ data.promise = (data.promise || Promise.resolve()).then(async () => {
9118
+ await awaitTimeout(state.show ? this.delay : 0);
9025
9119
  this.toggle(el, true);
9026
9120
  setTimeout(() => {
9027
9121
  state.queued = false;
@@ -9217,20 +9311,19 @@
9217
9311
  name: "load hashchange popstate",
9218
9312
  el: () => window,
9219
9313
  filter: ({ targetOffset }) => targetOffset !== false,
9220
- handler() {
9314
+ async handler() {
9221
9315
  const { scrollingElement } = document;
9222
9316
  if (!location.hash || scrollingElement.scrollTop === 0) {
9223
9317
  return;
9224
9318
  }
9225
- setTimeout(() => {
9226
- const targetOffset = offset($(location.hash));
9227
- const elOffset = offset(this.$el);
9228
- if (this.isFixed && intersectRect(targetOffset, elOffset)) {
9229
- scrollingElement.scrollTop = Math.ceil(
9230
- targetOffset.top - elOffset.height - toPx(this.targetOffset, "height", this.placeholder) - toPx(this.offset, "height", this.placeholder)
9231
- );
9232
- }
9233
- });
9319
+ await awaitTimeout();
9320
+ const targetOffset = offset($(location.hash));
9321
+ const elOffset = offset(this.$el);
9322
+ if (this.isFixed && intersectRect(targetOffset, elOffset)) {
9323
+ scrollingElement.scrollTop = Math.ceil(
9324
+ targetOffset.top - elOffset.height - toPx(this.targetOffset, "height", this.placeholder) - toPx(this.offset, "height", this.placeholder)
9325
+ );
9326
+ }
9234
9327
  }
9235
9328
  }
9236
9329
  ],
@@ -9489,10 +9582,11 @@
9489
9582
  css(el, { position: "", top: "", marginTop: "", width: "" });
9490
9583
  }
9491
9584
  const clsTransitionDisable = "uk-transition-disable";
9492
- function preventTransition(element) {
9585
+ async function preventTransition(element) {
9493
9586
  if (!hasClass(element, clsTransitionDisable)) {
9494
9587
  addClass(element, clsTransitionDisable);
9495
- requestAnimationFrame(() => removeClass(element, clsTransitionDisable));
9588
+ await awaitFrame();
9589
+ removeClass(element, clsTransitionDisable);
9496
9590
  }
9497
9591
  }
9498
9592
  function getVisibleParent(element) {
@@ -9830,17 +9924,15 @@
9830
9924
  }
9831
9925
  },
9832
9926
  {
9833
- // mouseenter mouseleave are added because of Firefox bug,
9834
- // where pointerleave is triggered immediately after pointerenter on scroll
9835
- name: `mouseenter mouseleave ${pointerEnter} ${pointerLeave} focus blur`,
9927
+ name: `${pointerEnter} ${pointerLeave} focus blur`,
9836
9928
  filter: ({ mode }) => includes(mode, "hover"),
9837
9929
  handler(e) {
9838
9930
  if (isTouch(e) || this.$el.disabled || document.readyState === "loading") {
9839
9931
  return;
9840
9932
  }
9841
- const show = includes(["mouseenter", pointerEnter, "focus"], e.type);
9933
+ const show = includes([pointerEnter, "focus"], e.type);
9842
9934
  const expanded = this.isToggled(this.target);
9843
- if (!show && (!isBoolean(this._showState) || e.type !== "blur" && matches(this.$el, ":focus") || e.type === "blur" && matches(this.$el, ":hover"))) {
9935
+ if (!show && (!isBoolean(this._showState) || e.type === pointerLeave && matches(this.$el, ":focus") || e.type === "blur" && matches(this.$el, ":hover"))) {
9844
9936
  if (expanded === this._showState) {
9845
9937
  this._showState = null;
9846
9938
  }
@@ -9950,6 +10042,7 @@
9950
10042
  NavbarToggleIcon: NavbarToggleIcon,
9951
10043
  Offcanvas: offcanvas,
9952
10044
  OverflowAuto: overflowAuto,
10045
+ OverflowFade: overflowFade,
9953
10046
  OverlayIcon: IconComponent,
9954
10047
  PaginationNext: PaginationNext,
9955
10048
  PaginationPrevious: PaginationPrevious,