uikit 3.23.13 → 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 +136 -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 +185 -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 +3 -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
@@ -1,4 +1,4 @@
1
- /*! UIkit 3.23.13 | 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}`}`;
@@ -1332,10 +1332,12 @@
1332
1332
  return rect;
1333
1333
  }
1334
1334
  function getCoveringElement(target) {
1335
+ const { document } = toWindow(target);
1336
+ target = target || document.body;
1335
1337
  const { left, width, top } = dimensions(target);
1336
1338
  for (const position of top ? [0, top] : [0]) {
1337
1339
  let coverEl;
1338
- for (const el of toWindow(target).document.elementsFromPoint(left + width / 2, position)) {
1340
+ for (const el of document.elementsFromPoint(left + width / 2, position)) {
1339
1341
  if (!el.contains(target) && // If e.g. Offcanvas is not yet closed
1340
1342
  !hasClass(el, "uk-togglable-leave") && (hasPosition(el, "fixed") && zIndex(
1341
1343
  parents(target).reverse().find(
@@ -1989,7 +1991,7 @@
1989
1991
  }
1990
1992
  return options2;
1991
1993
  }, {}) : {};
1992
- } catch (e) {
1994
+ } catch {
1993
1995
  return {};
1994
1996
  }
1995
1997
  }
@@ -2164,7 +2166,7 @@
2164
2166
  };
2165
2167
  App.util = util;
2166
2168
  App.options = {};
2167
- App.version = "3.23.13";
2169
+ App.version = "3.23.14-dev.be820cd99";
2168
2170
 
2169
2171
  const PREFIX = "uk-";
2170
2172
  const DATA = "__uikit__";
@@ -2621,7 +2623,7 @@
2621
2623
  })
2622
2624
  );
2623
2625
  return true;
2624
- } catch (e) {
2626
+ } catch {
2625
2627
  return false;
2626
2628
  }
2627
2629
  },
@@ -2989,63 +2991,77 @@
2989
2991
  args: "autoplay",
2990
2992
  props: {
2991
2993
  automute: Boolean,
2992
- autoplay: Boolean
2994
+ autoplay: Boolean,
2995
+ restart: Boolean,
2996
+ hoverTarget: Boolean
2993
2997
  },
2994
2998
  data: {
2995
2999
  automute: false,
2996
- autoplay: true
3000
+ autoplay: true,
3001
+ restart: false,
3002
+ hoverTarget: false
2997
3003
  },
2998
3004
  beforeConnect() {
2999
- if (this.autoplay === "inview" && !hasAttr(this.$el, "preload")) {
3005
+ const isVideo = isTag(this.$el, "video");
3006
+ if (this.autoplay === "inview" && isVideo && !hasAttr(this.$el, "preload")) {
3000
3007
  this.$el.preload = "none";
3001
3008
  }
3002
- if (isTag(this.$el, "iframe") && !hasAttr(this.$el, "allow")) {
3009
+ if (!isVideo && !hasAttr(this.$el, "allow")) {
3003
3010
  this.$el.allow = "autoplay";
3004
3011
  }
3005
3012
  if (this.autoplay === "hover") {
3006
- if (isTag(this.$el, "video")) {
3013
+ if (isVideo) {
3007
3014
  this.$el.tabIndex = 0;
3008
3015
  } else {
3009
3016
  this.autoplay = true;
3010
3017
  }
3011
3018
  }
3012
- if (this.automute) {
3019
+ if (this.automute || hasAttr(this.$el, "muted")) {
3013
3020
  mute(this.$el);
3014
3021
  }
3015
3022
  },
3016
3023
  events: [
3017
3024
  {
3018
3025
  name: `${pointerEnter} focusin`,
3026
+ el: ({ hoverTarget, $el }) => query(hoverTarget, $el) || $el,
3019
3027
  filter: ({ autoplay }) => includes(autoplay, "hover"),
3020
3028
  handler(e) {
3021
3029
  if (!isTouch(e) || !isPlaying(this.$el)) {
3022
3030
  play(this.$el);
3023
3031
  } else {
3024
- pause(this.$el);
3032
+ pauseHover(this.$el, this.restart);
3025
3033
  }
3026
3034
  }
3027
3035
  },
3028
3036
  {
3029
3037
  name: `${pointerLeave} focusout`,
3038
+ el: ({ hoverTarget, $el }) => query(hoverTarget, $el) || $el,
3030
3039
  filter: ({ autoplay }) => includes(autoplay, "hover"),
3031
3040
  handler(e) {
3032
3041
  if (!isTouch(e)) {
3033
- pause(this.$el);
3042
+ pauseHover(this.$el, this.restart);
3034
3043
  }
3035
3044
  }
3036
3045
  }
3037
3046
  ],
3038
3047
  observe: [
3039
3048
  intersection({
3040
- filter: ({ autoplay }) => autoplay !== "hover",
3041
- handler([{ isIntersecting }]) {
3049
+ filter: ({ $el }) => $el.preload === "none",
3050
+ handler([{ target }]) {
3051
+ target.preload = "";
3052
+ this.$reset();
3053
+ }
3054
+ }),
3055
+ intersection({
3056
+ filter: ({ $el, autoplay }) => autoplay !== "hover" && $el.preload !== "none",
3057
+ handler([{ isIntersecting, target }]) {
3042
3058
  if (!document.fullscreenElement) {
3043
3059
  if (isIntersecting) {
3044
3060
  if (this.autoplay) {
3045
- play(this.$el);
3061
+ play(target);
3046
3062
  }
3047
3063
  } else {
3048
- pause(this.$el);
3064
+ pauseHover(target, this.restart);
3049
3065
  }
3050
3066
  }
3051
3067
  },
@@ -3059,6 +3075,12 @@
3059
3075
  function isPlaying(videoEl) {
3060
3076
  return !videoEl.paused && !videoEl.ended;
3061
3077
  }
3078
+ function pauseHover(el, restart) {
3079
+ pause(el);
3080
+ if (restart && isTag(el, "video")) {
3081
+ el.currentTime = 0;
3082
+ }
3083
+ }
3062
3084
 
3063
3085
  var cover = {
3064
3086
  mixins: [Video],
@@ -3160,7 +3182,7 @@
3160
3182
  const props = {
3161
3183
  overflowY: CSS.supports("overflow", "clip") ? "clip" : "hidden",
3162
3184
  touchAction: "none",
3163
- paddingRight: width(window) - scrollingElement.clientWidth || ""
3185
+ scrollbarGutter: "stable"
3164
3186
  };
3165
3187
  css(scrollingElement, props);
3166
3188
  return () => {
@@ -3172,7 +3194,7 @@
3172
3194
 
3173
3195
  let active$1;
3174
3196
  var drop = {
3175
- mixins: [Container, Position, Togglable],
3197
+ mixins: [Class, Container, Position, Togglable],
3176
3198
  args: "pos",
3177
3199
  props: {
3178
3200
  mode: "list",
@@ -3187,7 +3209,6 @@
3187
3209
  delayShow: Number,
3188
3210
  delayHide: Number,
3189
3211
  autoUpdate: Boolean,
3190
- clsDrop: String,
3191
3212
  animateOut: Boolean,
3192
3213
  bgScroll: Boolean,
3193
3214
  closeOnScroll: Boolean
@@ -3205,7 +3226,6 @@
3205
3226
  delayShow: 0,
3206
3227
  delayHide: 800,
3207
3228
  autoUpdate: true,
3208
- clsDrop: false,
3209
3229
  animateOut: false,
3210
3230
  bgScroll: true,
3211
3231
  animation: ["uk-animation-fade"],
@@ -3233,11 +3253,8 @@
3233
3253
  created() {
3234
3254
  this.tracker = new MouseTracker();
3235
3255
  },
3236
- beforeConnect() {
3237
- this.clsDrop = this.$props.clsDrop || this.$options.id;
3238
- },
3239
3256
  connected() {
3240
- addClass(this.$el, "uk-drop", this.clsDrop);
3257
+ addClass(this.$el, "uk-drop");
3241
3258
  if (this.toggle && !this.targetEl) {
3242
3259
  this.targetEl = createToggleComponent(this);
3243
3260
  }
@@ -3546,7 +3563,6 @@
3546
3563
  mixins: [Class, Container],
3547
3564
  props: {
3548
3565
  align: String,
3549
- clsDrop: String,
3550
3566
  boundary: Boolean,
3551
3567
  dropbar: Boolean,
3552
3568
  dropbarAnchor: Boolean,
@@ -3570,6 +3586,7 @@
3570
3586
  boundary: true,
3571
3587
  dropbar: false,
3572
3588
  dropbarAnchor: false,
3589
+ flip: true,
3573
3590
  delayShow: 160,
3574
3591
  duration: 200,
3575
3592
  container: false,
@@ -3582,7 +3599,7 @@
3582
3599
  return null;
3583
3600
  }
3584
3601
  dropbar = this._dropbar || query(dropbar, this.$el) || $(`+ .${this.clsDropbar}`, this.$el);
3585
- return dropbar ? dropbar : this._dropbar = $("<div></div>");
3602
+ return dropbar ? dropbar : this._dropbar = $("<div>");
3586
3603
  },
3587
3604
  dropContainer(_, $el) {
3588
3605
  return this.container || $el;
@@ -3828,10 +3845,10 @@
3828
3845
  this.dropdowns.filter((el) => !this.getDropdown(el)),
3829
3846
  {
3830
3847
  ...this.$props,
3831
- flip: false,
3848
+ flip: this.flip && !this.$props.dropbar,
3832
3849
  shift: true,
3833
3850
  pos: `bottom-${this.align}`,
3834
- boundary: this.boundary === true ? this.$el : this.boundary
3851
+ boundaryX: this.boundary === true ? this.$el : this.boundary
3835
3852
  }
3836
3853
  );
3837
3854
  }
@@ -4345,7 +4362,7 @@
4345
4362
 
4346
4363
  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>";
4347
4364
 
4348
- 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>";
4365
+ 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>";
4349
4366
 
4350
4367
  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>";
4351
4368
 
@@ -4759,7 +4776,7 @@
4759
4776
  if (startsWith(sources, "[")) {
4760
4777
  try {
4761
4778
  sources = JSON.parse(sources);
4762
- } catch (e) {
4779
+ } catch {
4763
4780
  sources = [];
4764
4781
  }
4765
4782
  } else {
@@ -4981,6 +4998,13 @@
4981
4998
  }
4982
4999
  };
4983
5000
 
5001
+ function awaitFrame() {
5002
+ return new Promise((resolve) => requestAnimationFrame(resolve));
5003
+ }
5004
+ function awaitTimeout(timeout) {
5005
+ return new Promise((resolve) => setTimeout(resolve, timeout));
5006
+ }
5007
+
4984
5008
  const active = [];
4985
5009
  var Modal = {
4986
5010
  mixins: [Class, Container, Togglable],
@@ -5125,12 +5149,10 @@
5125
5149
  toggle() {
5126
5150
  return this.isToggled() ? this.hide() : this.show();
5127
5151
  },
5128
- show() {
5152
+ async show() {
5129
5153
  if (this.container && parent(this.$el) !== this.container) {
5130
5154
  append(this.container, this.$el);
5131
- return new Promise(
5132
- (resolve) => requestAnimationFrame(() => this.show().then(resolve))
5133
- );
5155
+ await awaitFrame();
5134
5156
  }
5135
5157
  return this.toggleElement(this.$el, true, animate);
5136
5158
  },
@@ -5335,6 +5357,7 @@
5335
5357
  dropbarTransparentMode: Boolean
5336
5358
  },
5337
5359
  data: {
5360
+ flip: false,
5338
5361
  delayShow: 200,
5339
5362
  clsDrop: "uk-navbar-dropdown",
5340
5363
  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",
@@ -5369,7 +5392,7 @@
5369
5392
  name: "hide",
5370
5393
  el: ({ dropContainer }) => dropContainer,
5371
5394
  async handler() {
5372
- await awaitMacroTask();
5395
+ await awaitTimeout();
5373
5396
  if (this._transparent && (!active$1 || !this.dropContainer.contains(active$1.$el))) {
5374
5397
  addClass(this.navbarContainer, clsNavbarTransparent);
5375
5398
  this._transparent = null;
@@ -5396,9 +5419,6 @@
5396
5419
  }
5397
5420
  }
5398
5421
  };
5399
- function awaitMacroTask() {
5400
- return new Promise((resolve) => setTimeout(resolve));
5401
- }
5402
5422
 
5403
5423
  var offcanvas = {
5404
5424
  mixins: [Modal],
@@ -5559,6 +5579,59 @@
5559
5579
  }
5560
5580
  };
5561
5581
 
5582
+ var overflowFade = {
5583
+ data: {
5584
+ fadeDuration: 0.05
5585
+ },
5586
+ events: {
5587
+ name: "scroll",
5588
+ self: true,
5589
+ passive: true,
5590
+ handler() {
5591
+ this.$emit();
5592
+ }
5593
+ },
5594
+ observe: [
5595
+ mutation({
5596
+ options: {
5597
+ subtree: true,
5598
+ childList: true
5599
+ }
5600
+ }),
5601
+ resize({
5602
+ target: ({ $el }) => [$el, ...children($el)]
5603
+ })
5604
+ ],
5605
+ update: {
5606
+ read() {
5607
+ const overflow = [];
5608
+ for (const prop of ["Width", "Height"]) {
5609
+ overflow.push(this.$el[`scroll${prop}`] - this.$el[`client${prop}`]);
5610
+ }
5611
+ return { overflow };
5612
+ },
5613
+ write({ overflow }) {
5614
+ for (let i = 0; i < 2; i++) {
5615
+ toggleClass(
5616
+ this.$el,
5617
+ `${this.$options.id}-${i ? "vertical" : "horizontal"}`,
5618
+ overflow[i] && !overflow[i - 1]
5619
+ );
5620
+ if (!overflow[i - 1]) {
5621
+ const dir = i ? "Top" : "Left";
5622
+ const percent = overflow[i] ? this.$el[`scroll${dir}`] / overflow[i] : 0;
5623
+ const toValue = (value) => overflow[i] ? clamp((this.fadeDuration - value) / this.fadeDuration) : 1;
5624
+ css(this.$el, {
5625
+ "--uk-overflow-fade-start-opacity": toValue(percent),
5626
+ "--uk-overflow-fade-end-opacity": toValue(1 - percent)
5627
+ });
5628
+ }
5629
+ }
5630
+ },
5631
+ events: ["resize"]
5632
+ }
5633
+ };
5634
+
5562
5635
  var responsive = {
5563
5636
  props: ["width", "height"],
5564
5637
  connected() {
@@ -5652,7 +5725,7 @@
5652
5725
  },
5653
5726
  disconnected() {
5654
5727
  for (const [el, state] of this.elementData.entries()) {
5655
- removeClass(el, clsInView, (state == null ? void 0 : state.cls) || "");
5728
+ removeClass(el, clsInView, state.cls || "");
5656
5729
  }
5657
5730
  delete this.elementData;
5658
5731
  },
@@ -5683,7 +5756,8 @@
5683
5756
  for (const [el, state] of this.elementData.entries()) {
5684
5757
  if (state.show && !state.inview && !state.queued) {
5685
5758
  state.queued = true;
5686
- data.promise = (data.promise || Promise.resolve()).then(() => new Promise((resolve) => setTimeout(resolve, this.delay))).then(() => {
5759
+ data.promise = (data.promise || Promise.resolve()).then(async () => {
5760
+ await awaitTimeout(state.show ? this.delay : 0);
5687
5761
  this.toggle(el, true);
5688
5762
  setTimeout(() => {
5689
5763
  state.queued = false;
@@ -5879,20 +5953,19 @@
5879
5953
  name: "load hashchange popstate",
5880
5954
  el: () => window,
5881
5955
  filter: ({ targetOffset }) => targetOffset !== false,
5882
- handler() {
5956
+ async handler() {
5883
5957
  const { scrollingElement } = document;
5884
5958
  if (!location.hash || scrollingElement.scrollTop === 0) {
5885
5959
  return;
5886
5960
  }
5887
- setTimeout(() => {
5888
- const targetOffset = offset($(location.hash));
5889
- const elOffset = offset(this.$el);
5890
- if (this.isFixed && intersectRect(targetOffset, elOffset)) {
5891
- scrollingElement.scrollTop = Math.ceil(
5892
- targetOffset.top - elOffset.height - toPx(this.targetOffset, "height", this.placeholder) - toPx(this.offset, "height", this.placeholder)
5893
- );
5894
- }
5895
- });
5961
+ await awaitTimeout();
5962
+ const targetOffset = offset($(location.hash));
5963
+ const elOffset = offset(this.$el);
5964
+ if (this.isFixed && intersectRect(targetOffset, elOffset)) {
5965
+ scrollingElement.scrollTop = Math.ceil(
5966
+ targetOffset.top - elOffset.height - toPx(this.targetOffset, "height", this.placeholder) - toPx(this.offset, "height", this.placeholder)
5967
+ );
5968
+ }
5896
5969
  }
5897
5970
  }
5898
5971
  ],
@@ -6151,10 +6224,11 @@
6151
6224
  css(el, { position: "", top: "", marginTop: "", width: "" });
6152
6225
  }
6153
6226
  const clsTransitionDisable = "uk-transition-disable";
6154
- function preventTransition(element) {
6227
+ async function preventTransition(element) {
6155
6228
  if (!hasClass(element, clsTransitionDisable)) {
6156
6229
  addClass(element, clsTransitionDisable);
6157
- requestAnimationFrame(() => removeClass(element, clsTransitionDisable));
6230
+ await awaitFrame();
6231
+ removeClass(element, clsTransitionDisable);
6158
6232
  }
6159
6233
  }
6160
6234
  function getVisibleParent(element) {
@@ -6501,17 +6575,15 @@
6501
6575
  }
6502
6576
  },
6503
6577
  {
6504
- // mouseenter mouseleave are added because of Firefox bug,
6505
- // where pointerleave is triggered immediately after pointerenter on scroll
6506
- name: `mouseenter mouseleave ${pointerEnter} ${pointerLeave} focus blur`,
6578
+ name: `${pointerEnter} ${pointerLeave} focus blur`,
6507
6579
  filter: ({ mode }) => includes(mode, "hover"),
6508
6580
  handler(e) {
6509
6581
  if (isTouch(e) || this.$el.disabled || document.readyState === "loading") {
6510
6582
  return;
6511
6583
  }
6512
- const show = includes(["mouseenter", pointerEnter, "focus"], e.type);
6584
+ const show = includes([pointerEnter, "focus"], e.type);
6513
6585
  const expanded = this.isToggled(this.target);
6514
- if (!show && (!isBoolean(this._showState) || e.type !== "blur" && matches(this.$el, ":focus") || e.type === "blur" && matches(this.$el, ":hover"))) {
6586
+ if (!show && (!isBoolean(this._showState) || e.type === pointerLeave && matches(this.$el, ":focus") || e.type === "blur" && matches(this.$el, ":hover"))) {
6515
6587
  if (expanded === this._showState) {
6516
6588
  this._showState = null;
6517
6589
  }
@@ -6621,6 +6693,7 @@
6621
6693
  NavbarToggleIcon: NavbarToggleIcon,
6622
6694
  Offcanvas: offcanvas,
6623
6695
  OverflowAuto: overflowAuto,
6696
+ OverflowFade: overflowFade,
6624
6697
  OverlayIcon: IconComponent,
6625
6698
  PaginationNext: PaginationNext,
6626
6699
  PaginationPrevious: PaginationPrevious,