uikit 3.25.29-dev.f3e1c53 → 3.25.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +5 -1
- package/dist/css/uikit-core-rtl.css +1 -1
- package/dist/css/uikit-core-rtl.min.css +1 -1
- package/dist/css/uikit-core.css +1 -1
- package/dist/css/uikit-core.min.css +1 -1
- package/dist/css/uikit-rtl.css +1 -1
- package/dist/css/uikit-rtl.min.css +1 -1
- package/dist/css/uikit.css +1 -1
- package/dist/css/uikit.min.css +1 -1
- package/dist/js/components/countdown.js +1 -1
- package/dist/js/components/countdown.min.js +1 -1
- package/dist/js/components/filter.js +1 -1
- package/dist/js/components/filter.min.js +1 -1
- package/dist/js/components/lightbox-panel.js +4 -4
- package/dist/js/components/lightbox-panel.min.js +1 -1
- package/dist/js/components/lightbox.js +4 -4
- package/dist/js/components/lightbox.min.js +1 -1
- package/dist/js/components/notification.js +1 -1
- package/dist/js/components/notification.min.js +1 -1
- package/dist/js/components/parallax.js +11 -15
- package/dist/js/components/parallax.min.js +1 -1
- package/dist/js/components/slider-parallax.js +11 -15
- package/dist/js/components/slider-parallax.min.js +1 -1
- package/dist/js/components/slider.js +11 -15
- package/dist/js/components/slider.min.js +1 -1
- package/dist/js/components/slideshow-parallax.js +11 -15
- package/dist/js/components/slideshow-parallax.min.js +1 -1
- package/dist/js/components/slideshow.js +11 -15
- package/dist/js/components/slideshow.min.js +1 -1
- package/dist/js/components/sortable.js +1 -1
- package/dist/js/components/sortable.min.js +1 -1
- package/dist/js/components/tooltip.js +1 -1
- package/dist/js/components/tooltip.min.js +1 -1
- package/dist/js/components/upload.js +1 -1
- package/dist/js/components/upload.min.js +1 -1
- package/dist/js/uikit-core.js +24 -10
- package/dist/js/uikit-core.min.js +1 -1
- package/dist/js/uikit-icons.js +1 -1
- package/dist/js/uikit-icons.min.js +1 -1
- package/dist/js/uikit.js +27 -13
- package/dist/js/uikit.min.js +1 -1
- package/package.json +1 -1
- package/src/js/components/lightbox-panel.js +3 -3
- package/src/js/core/svg.js +5 -1
- package/src/js/util/filter.js +6 -1
- package/src/js/util/svg.js +7 -6
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "uikit",
|
|
3
3
|
"title": "UIkit",
|
|
4
4
|
"description": "UIkit is a lightweight and modular front-end framework for developing fast and powerful web interfaces.",
|
|
5
|
-
"version": "3.25.29
|
|
5
|
+
"version": "3.25.29",
|
|
6
6
|
"main": "dist/js/uikit.js",
|
|
7
7
|
"style": "dist/css/uikit.css",
|
|
8
8
|
"sideEffects": [
|
|
@@ -344,7 +344,7 @@ export default {
|
|
|
344
344
|
try {
|
|
345
345
|
const { height, width } = await (
|
|
346
346
|
await fetch(
|
|
347
|
-
`https://vimeo.com/api/oembed.json?maxwidth=1920&url=${
|
|
347
|
+
`https://vimeo.com/api/oembed.json?maxwidth=1920&url=${encodeURIComponent(
|
|
348
348
|
src,
|
|
349
349
|
)}`,
|
|
350
350
|
{ credentials: 'omit' },
|
|
@@ -463,9 +463,9 @@ function toThumbnavItem(item, videoAutoplay) {
|
|
|
463
463
|
}
|
|
464
464
|
|
|
465
465
|
function isImage(src) {
|
|
466
|
-
return src?.match(/\.(avif|jpe?g|jfif|a?png|gif|svg|webp)(
|
|
466
|
+
return src?.match(/\.(avif|jpe?g|jfif|a?png|gif|svg|webp)($|[?#])/i);
|
|
467
467
|
}
|
|
468
468
|
|
|
469
469
|
function isVideo(src) {
|
|
470
|
-
return src?.match(/\.(mp4|webm|ogv)(
|
|
470
|
+
return src?.match(/\.(mp4|webm|ogv)($|[?#])/i);
|
|
471
471
|
}
|
package/src/js/core/svg.js
CHANGED
|
@@ -51,7 +51,11 @@ export default {
|
|
|
51
51
|
methods: {
|
|
52
52
|
async getSvg() {
|
|
53
53
|
if (isTag(this.$el, 'img') && !this.$el.complete && this.$el.loading === 'lazy') {
|
|
54
|
-
await new Promise((resolve) =>
|
|
54
|
+
await new Promise((resolve, reject) =>
|
|
55
|
+
once(this.$el, 'load error', (event) =>
|
|
56
|
+
event.type === 'load' ? resolve() : reject(event),
|
|
57
|
+
),
|
|
58
|
+
);
|
|
55
59
|
}
|
|
56
60
|
|
|
57
61
|
return parseSVG(await loadSVG(this.src), this.icon) || Promise.reject('SVG not found.');
|
package/src/js/util/filter.js
CHANGED
|
@@ -83,7 +83,12 @@ export function isSameSiteAnchor(el) {
|
|
|
83
83
|
export function getTargetedElement(el) {
|
|
84
84
|
if (isSameSiteAnchor(el)) {
|
|
85
85
|
const { hash, ownerDocument } = toNode(el);
|
|
86
|
-
|
|
86
|
+
let id = hash.slice(1);
|
|
87
|
+
try {
|
|
88
|
+
id = decodeURIComponent(id);
|
|
89
|
+
} catch {
|
|
90
|
+
// Fall back to the literal fragment for malformed encoding.
|
|
91
|
+
}
|
|
87
92
|
return id
|
|
88
93
|
? ownerDocument.getElementById(id) || ownerDocument.getElementsByName(id)[0]
|
|
89
94
|
: ownerDocument.documentElement;
|
package/src/js/util/svg.js
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { $$ } from './dom';
|
|
2
|
-
import { isVisible } from './filter.js';
|
|
3
2
|
|
|
4
3
|
export function getMaxPathLength(el) {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
4
|
+
try {
|
|
5
|
+
return Math.ceil(
|
|
6
|
+
Math.max(0, ...$$('[stroke]', el).map((stroke) => stroke.getTotalLength?.() || 0)),
|
|
7
|
+
);
|
|
8
|
+
} catch {
|
|
9
|
+
return 0;
|
|
10
|
+
}
|
|
10
11
|
}
|