uikit 3.16.24-dev.d6158da87 → 3.16.25-dev.12f581d90

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 (136) hide show
  1. package/.eslintrc.json +0 -9
  2. package/.prettierrc.json +3 -4
  3. package/CHANGELOG.md +2 -1
  4. package/build/build.js +2 -2
  5. package/build/less.js +2 -2
  6. package/build/prefix.js +3 -3
  7. package/build/release.js +7 -7
  8. package/build/scope.js +3 -3
  9. package/build/scss.js +9 -9
  10. package/build/util.js +11 -11
  11. package/dist/css/uikit-core-rtl.css +1 -1
  12. package/dist/css/uikit-core-rtl.min.css +1 -1
  13. package/dist/css/uikit-core.css +1 -1
  14. package/dist/css/uikit-core.min.css +1 -1
  15. package/dist/css/uikit-rtl.css +1 -1
  16. package/dist/css/uikit-rtl.min.css +1 -1
  17. package/dist/css/uikit.css +1 -1
  18. package/dist/css/uikit.min.css +1 -1
  19. package/dist/js/components/countdown.js +2 -2
  20. package/dist/js/components/countdown.min.js +1 -1
  21. package/dist/js/components/filter.js +18 -18
  22. package/dist/js/components/filter.min.js +1 -1
  23. package/dist/js/components/lightbox-panel.js +351 -350
  24. package/dist/js/components/lightbox-panel.min.js +1 -1
  25. package/dist/js/components/lightbox.js +353 -352
  26. package/dist/js/components/lightbox.min.js +1 -1
  27. package/dist/js/components/notification.js +6 -6
  28. package/dist/js/components/notification.min.js +1 -1
  29. package/dist/js/components/parallax.js +69 -69
  30. package/dist/js/components/parallax.min.js +1 -1
  31. package/dist/js/components/slider-parallax.js +37 -37
  32. package/dist/js/components/slider-parallax.min.js +1 -1
  33. package/dist/js/components/slider.js +222 -224
  34. package/dist/js/components/slider.min.js +1 -1
  35. package/dist/js/components/slideshow-parallax.js +37 -37
  36. package/dist/js/components/slideshow-parallax.min.js +1 -1
  37. package/dist/js/components/slideshow.js +300 -302
  38. package/dist/js/components/slideshow.min.js +1 -1
  39. package/dist/js/components/sortable.js +2 -2
  40. package/dist/js/components/sortable.min.js +1 -1
  41. package/dist/js/components/tooltip.js +95 -95
  42. package/dist/js/components/tooltip.min.js +1 -1
  43. package/dist/js/components/upload.js +2 -2
  44. package/dist/js/components/upload.min.js +1 -1
  45. package/dist/js/uikit-core.js +452 -449
  46. package/dist/js/uikit-core.min.js +1 -1
  47. package/dist/js/uikit-icons.js +1 -1
  48. package/dist/js/uikit-icons.min.js +1 -1
  49. package/dist/js/uikit.js +6837 -6836
  50. package/dist/js/uikit.min.js +1 -1
  51. package/package.json +8 -7
  52. package/src/js/api/app.js +1 -1
  53. package/src/js/api/boot.js +2 -2
  54. package/src/js/api/component.js +1 -1
  55. package/src/js/api/computed.js +2 -2
  56. package/src/js/api/events.js +2 -2
  57. package/src/js/api/global.js +3 -3
  58. package/src/js/api/hooks.js +4 -4
  59. package/src/js/api/instance.js +3 -3
  60. package/src/js/api/log.js +1 -1
  61. package/src/js/api/observables.js +1 -1
  62. package/src/js/api/observer.js +2 -2
  63. package/src/js/api/options.js +2 -2
  64. package/src/js/api/props.js +2 -2
  65. package/src/js/api/state.js +2 -2
  66. package/src/js/components/countdown.js +1 -1
  67. package/src/js/components/filter.js +5 -5
  68. package/src/js/components/internal/lightbox-animations.js +1 -1
  69. package/src/js/components/internal/slider-transitioner.js +6 -6
  70. package/src/js/components/internal/slideshow-animations.js +1 -1
  71. package/src/js/components/lightbox-panel.js +10 -10
  72. package/src/js/components/lightbox.js +2 -2
  73. package/src/js/components/notification.js +4 -4
  74. package/src/js/components/parallax.js +3 -3
  75. package/src/js/components/slider-parallax.js +1 -1
  76. package/src/js/components/slider.js +12 -12
  77. package/src/js/components/slideshow.js +3 -3
  78. package/src/js/components/sortable.js +4 -4
  79. package/src/js/components/tooltip.js +6 -6
  80. package/src/js/components/upload.js +4 -4
  81. package/src/js/core/accordion.js +8 -8
  82. package/src/js/core/alert.js +2 -2
  83. package/src/js/core/cover.js +1 -1
  84. package/src/js/core/drop.js +12 -12
  85. package/src/js/core/dropnav.js +7 -7
  86. package/src/js/core/form-custom.js +1 -1
  87. package/src/js/core/grid.js +9 -9
  88. package/src/js/core/height-match.js +2 -2
  89. package/src/js/core/height-viewport.js +1 -1
  90. package/src/js/core/icon.js +23 -23
  91. package/src/js/core/img.js +2 -2
  92. package/src/js/core/index.js +16 -14
  93. package/src/js/core/leader.js +2 -2
  94. package/src/js/core/modal.js +7 -7
  95. package/src/js/core/navbar.js +4 -4
  96. package/src/js/core/offcanvas.js +3 -3
  97. package/src/js/core/overflow-auto.js +3 -3
  98. package/src/js/core/responsive.js +3 -3
  99. package/src/js/core/scrollspy-nav.js +1 -1
  100. package/src/js/core/scrollspy.js +1 -1
  101. package/src/js/core/sticky.js +12 -12
  102. package/src/js/core/svg.js +4 -4
  103. package/src/js/core/switcher.js +7 -7
  104. package/src/js/core/tab.js +2 -2
  105. package/src/js/core/toggle.js +5 -5
  106. package/src/js/core/video.js +1 -1
  107. package/src/js/mixin/animate.js +1 -1
  108. package/src/js/mixin/i18n.js +1 -1
  109. package/src/js/mixin/internal/animate-fade.js +14 -14
  110. package/src/js/mixin/internal/animate-slide.js +1 -1
  111. package/src/js/mixin/internal/scroll.js +1 -1
  112. package/src/js/mixin/modal.js +15 -12
  113. package/src/js/mixin/parallax.js +2 -2
  114. package/src/js/mixin/position.js +2 -2
  115. package/src/js/mixin/slider-drag.js +1 -1
  116. package/src/js/mixin/slider-nav.js +8 -9
  117. package/src/js/mixin/slider.js +9 -9
  118. package/src/js/mixin/slideshow.js +1 -1
  119. package/src/js/mixin/togglable.js +4 -4
  120. package/src/js/uikit-core.js +2 -2
  121. package/src/js/uikit.js +2 -2
  122. package/src/js/util/animation.js +8 -8
  123. package/src/js/util/class.js +1 -1
  124. package/src/js/util/dimensions.js +5 -5
  125. package/src/js/util/dom.js +3 -3
  126. package/src/js/util/event.js +3 -3
  127. package/src/js/util/filter.js +1 -1
  128. package/src/js/util/lang.js +4 -4
  129. package/src/js/util/observer.js +2 -2
  130. package/src/js/util/player.js +1 -1
  131. package/src/js/util/position.js +5 -5
  132. package/src/js/util/selector.js +1 -1
  133. package/src/js/util/style.js +1 -1
  134. package/src/js/util/svg.js +2 -2
  135. package/src/js/util/viewport.js +6 -6
  136. package/tests/js/index.js +7 -7
@@ -1,6 +1,6 @@
1
- import { findAll } from './selector';
2
1
  import { closest, within } from './filter';
3
2
  import { isArray, isFunction, isString, toNode, toNodes } from './lang';
3
+ import { findAll } from './selector';
4
4
 
5
5
  export function on(...args) {
6
6
  let [targets, types, selector, listener, useCapture = false] = getArgs(args);
@@ -48,7 +48,7 @@ export function once(...args) {
48
48
  listener(e, result);
49
49
  }
50
50
  },
51
- useCapture
51
+ useCapture,
52
52
  );
53
53
 
54
54
  return off;
@@ -56,7 +56,7 @@ export function once(...args) {
56
56
 
57
57
  export function trigger(targets, event, detail) {
58
58
  return toEventTargets(targets).every((target) =>
59
- target.dispatchEvent(createEvent(event, true, true, detail))
59
+ target.dispatchEvent(createEvent(event, true, true, detail)),
60
60
  );
61
61
  }
62
62
 
@@ -23,7 +23,7 @@ export function isVoidElement(element) {
23
23
 
24
24
  export function isVisible(element) {
25
25
  return toNodes(element).some(
26
- (element) => element.offsetWidth || element.offsetHeight || element.getClientRects().length
26
+ (element) => element.offsetWidth || element.offsetHeight || element.getClientRects().length,
27
27
  );
28
28
  }
29
29
 
@@ -11,7 +11,7 @@ export const hyphenate = memoize((str) => str.replace(hyphenateRe, '-$1').toLowe
11
11
  const camelizeRe = /-(\w)/g;
12
12
 
13
13
  export const camelize = memoize((str) =>
14
- (str.charAt(0).toLowerCase() + str.slice(1)).replace(camelizeRe, (_, c) => c.toUpperCase())
14
+ (str.charAt(0).toLowerCase() + str.slice(1)).replace(camelizeRe, (_, c) => c.toUpperCase()),
15
15
  );
16
16
 
17
17
  export const ucfirst = memoize((str) => str.charAt(0).toUpperCase() + str.slice(1));
@@ -160,14 +160,14 @@ export function sortBy(array, prop) {
160
160
  return array
161
161
  .slice()
162
162
  .sort(({ [prop]: propA = 0 }, { [prop]: propB = 0 }) =>
163
- propA > propB ? 1 : propB > propA ? -1 : 0
163
+ propA > propB ? 1 : propB > propA ? -1 : 0,
164
164
  );
165
165
  }
166
166
 
167
167
  export function sumBy(array, iteratee) {
168
168
  return array.reduce(
169
169
  (sum, item) => sum + toFloat(isFunction(iteratee) ? iteratee(item) : item[iteratee]),
170
- 0
170
+ 0,
171
171
  );
172
172
  }
173
173
 
@@ -194,7 +194,7 @@ export function intersectRect(...rects) {
194
194
  ([minProp, maxProp]) =>
195
195
  Math.min(...rects.map(({ [minProp]: min }) => min)) -
196
196
  Math.max(...rects.map(({ [maxProp]: max }) => max)) >
197
- 0
197
+ 0,
198
198
  );
199
199
  }
200
200
 
@@ -1,6 +1,6 @@
1
+ import { inBrowser } from './env';
1
2
  import { on } from './event';
2
3
  import { toNodes } from './lang';
3
- import { inBrowser } from './env';
4
4
 
5
5
  export function observeIntersection(targets, cb, options = {}, { intersecting = true } = {}) {
6
6
  const observer = new IntersectionObserver(
@@ -11,7 +11,7 @@ export function observeIntersection(targets, cb, options = {}, { intersecting =
11
11
  }
12
12
  }
13
13
  : cb,
14
- options
14
+ options,
15
15
  );
16
16
  for (const el of toNodes(targets)) {
17
17
  observer.observe(el);
@@ -50,7 +50,7 @@ function isIFrame(el) {
50
50
 
51
51
  function isYoutube(el) {
52
52
  return !!el.src.match(
53
- /\/\/.*?youtube(-nocookie)?\.[a-z]+\/(watch\?v=[^&\s]+|embed)|youtu\.be\/.*/
53
+ /\/\/.*?youtube(-nocookie)?\.[a-z]+\/(watch\?v=[^&\s]+|embed)|youtu\.be\/.*/,
54
54
  );
55
55
  }
56
56
 
@@ -1,7 +1,7 @@
1
- import { css } from './style';
2
- import { within } from './filter';
3
1
  import { offset } from './dimensions';
2
+ import { within } from './filter';
4
3
  import { clamp, isArray, ucfirst } from './lang';
4
+ import { css } from './style';
5
5
  import { offsetViewport, overflowParents } from './viewport';
6
6
 
7
7
  const dirs = [
@@ -82,7 +82,7 @@ function getPosition(element, target, options) {
82
82
  clamp(
83
83
  clamp(position[start], viewport[start], viewport[end] - position[prop]),
84
84
  targetDim[start] - position[prop] + elOffset[i],
85
- targetDim[end] - elOffset[i]
85
+ targetDim[end] - elOffset[i],
86
86
  ) - position[start];
87
87
  }
88
88
 
@@ -116,7 +116,7 @@ function attachTo(element, target, options) {
116
116
  moveBy(attach.target[i], end, targetOffset[prop]) -
117
117
  moveBy(attach.element[i], end, elOffset[prop]) +
118
118
  +offsetBy[i],
119
- i
119
+ i,
120
120
  );
121
121
  }
122
122
  return elOffset;
@@ -145,7 +145,7 @@ function getViewport(element, target, viewportOffset, boundary, i) {
145
145
  if (boundary) {
146
146
  viewport = getIntersectionArea(
147
147
  viewport,
148
- offset(isArray(boundary) ? boundary[i] : boundary)
148
+ offset(isArray(boundary) ? boundary[i] : boundary),
149
149
  );
150
150
  }
151
151
 
@@ -77,7 +77,7 @@ function _query(selector, context = document, queryFn) {
77
77
  const selectorRe = /.*?[^\\](?:,|$)/g;
78
78
 
79
79
  const splitSelector = memoize((selector) =>
80
- selector.match(selectorRe).map((selector) => selector.replace(/,$/, '').trim())
80
+ selector.match(selectorRe).map((selector) => selector.replace(/,$/, '').trim()),
81
81
  );
82
82
 
83
83
  function domPath(element) {
@@ -46,7 +46,7 @@ export function css(element, property, value, priority) {
46
46
  : value || isNumber(value)
47
47
  ? value
48
48
  : '',
49
- priority
49
+ priority,
50
50
  );
51
51
  }
52
52
  } else if (isArray(property)) {
@@ -10,7 +10,7 @@ export function getMaxPathLength(el) {
10
10
  } catch (e) {
11
11
  return 0;
12
12
  }
13
- })
14
- )
13
+ }),
14
+ ),
15
15
  );
16
16
  }
@@ -1,6 +1,5 @@
1
- import { css } from './style';
2
- import { isVisible, parents } from './filter';
3
1
  import { offset, offsetPosition } from './dimensions';
2
+ import { isVisible, parents } from './filter';
4
3
  import {
5
4
  clamp,
6
5
  findIndex,
@@ -11,6 +10,7 @@ import {
11
10
  toWindow,
12
11
  ucfirst,
13
12
  } from './lang';
13
+ import { css } from './style';
14
14
 
15
15
  export function isInView(element, offsetTop = 0, offsetLeft = 0) {
16
16
  if (!isVisible(element)) {
@@ -29,7 +29,7 @@ export function isInView(element, offsetTop = 0, offsetLeft = 0) {
29
29
  right: right + offsetLeft,
30
30
  };
31
31
  })
32
- .concat(offset(element))
32
+ .concat(offset(element)),
33
33
  );
34
34
  }
35
35
 
@@ -62,7 +62,7 @@ export function scrollIntoView(element, { offset: offsetBy = 0 } = {}) {
62
62
 
63
63
  return () => scrollTo(scrollElement, top - scrollTop).then(fn);
64
64
  },
65
- () => Promise.resolve()
65
+ () => Promise.resolve(),
66
66
  )();
67
67
 
68
68
  function scrollTo(element, top) {
@@ -130,8 +130,8 @@ export function scrollParents(element, scrollable = false, props = []) {
130
130
  css(parent, 'overflow')
131
131
  .split(' ')
132
132
  .some((prop) => includes(['auto', 'scroll', ...props], prop)) &&
133
- (!scrollable || parent.scrollHeight > offsetViewport(parent).height)
134
- )
133
+ (!scrollable || parent.scrollHeight > offsetViewport(parent).height),
134
+ ),
135
135
  )
136
136
  .reverse();
137
137
  }
package/tests/js/index.js CHANGED
@@ -47,13 +47,13 @@ const style = styles[storage[key]] || styles.theme;
47
47
  document.writeln(
48
48
  `<link rel="stylesheet" href="${
49
49
  dir !== 'rtl' ? style.css : style.css.replace('.css', '-rtl.css')
50
- }">`
50
+ }">`,
51
51
  );
52
52
 
53
53
  // add javascript
54
54
  document.writeln('<script src="../dist/js/uikit.js"></script>');
55
55
  document.writeln(
56
- `<script src="${style.icons ? style.icons : '../dist/js/uikit-icons.js'}"></script>`
56
+ `<script src="${style.icons ? style.icons : '../dist/js/uikit-icons.js'}"></script>`,
57
57
  );
58
58
 
59
59
  on(window, 'load', () =>
@@ -73,7 +73,7 @@ on(window, 'load', () =>
73
73
  `<option value="${name}.html">${name
74
74
  .split('-')
75
75
  .map(ucfirst)
76
- .join(' ')}</option>`
76
+ .join(' ')}</option>`,
77
77
  )
78
78
  .join('')}
79
79
  </select>
@@ -92,7 +92,7 @@ on(window, 'load', () =>
92
92
  <span style="margin: 5px">RTL</span>
93
93
  </label>
94
94
  </div>
95
- `
95
+ `,
96
96
  );
97
97
 
98
98
  const [$tests, $styles, $inverse, $rtl] = $container.children;
@@ -139,7 +139,7 @@ on(window, 'load', () =>
139
139
  'uk-section-primary',
140
140
  'uk-section-secondary',
141
141
  'uk-overlay-default',
142
- 'uk-overlay-primary'
142
+ 'uk-overlay-primary',
143
143
  );
144
144
 
145
145
  addClass($$('.uk-navbar-container'), 'uk-navbar-transparent');
@@ -164,8 +164,8 @@ on(window, 'load', () =>
164
164
 
165
165
  css(docEl, 'paddingTop', '');
166
166
  }),
167
- 100
168
- )
167
+ 100,
168
+ ),
169
169
  );
170
170
 
171
171
  css(docEl, 'paddingTop', '80px');