uikit 3.17.9-dev.73842811 → 3.17.9-dev.77c1d012a
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 +16 -2
- 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 +2 -2
- package/dist/js/components/filter.min.js +1 -1
- package/dist/js/components/lightbox-panel.js +9 -9
- package/dist/js/components/lightbox-panel.min.js +1 -1
- package/dist/js/components/lightbox.js +9 -9
- package/dist/js/components/lightbox.min.js +1 -1
- package/dist/js/components/notification.js +2 -2
- package/dist/js/components/notification.min.js +1 -1
- package/dist/js/components/parallax.js +21 -25
- package/dist/js/components/parallax.min.js +1 -1
- package/dist/js/components/slider-parallax.js +21 -25
- package/dist/js/components/slider-parallax.min.js +1 -1
- package/dist/js/components/slider.js +6 -6
- package/dist/js/components/slider.min.js +1 -1
- package/dist/js/components/slideshow-parallax.js +21 -25
- package/dist/js/components/slideshow-parallax.min.js +1 -1
- package/dist/js/components/slideshow.js +6 -6
- package/dist/js/components/slideshow.min.js +1 -1
- package/dist/js/components/sortable.js +4 -4
- package/dist/js/components/sortable.min.js +1 -1
- package/dist/js/components/tooltip.js +41 -33
- 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 +64 -67
- 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 +94 -103
- package/dist/js/uikit.min.js +1 -1
- package/package.json +12 -12
- package/src/js/api/component.js +2 -2
- package/src/js/api/events.js +1 -6
- package/src/js/api/instance.js +5 -5
- package/src/js/api/observables.js +2 -2
- package/src/js/api/options.js +15 -14
- package/src/js/api/props.js +13 -15
- package/src/js/components/filter.js +1 -2
- package/src/js/components/notification.js +1 -2
- package/src/js/components/sortable.js +4 -5
- package/src/js/components/tooltip.js +30 -35
- package/src/js/core/accordion.js +1 -2
- package/src/js/core/drop.js +23 -20
- package/src/js/core/dropnav.js +2 -3
- package/src/js/core/form-custom.js +5 -5
- package/src/js/core/icon.js +5 -6
- package/src/js/core/navbar.js +1 -2
- package/src/js/core/overflow-auto.js +3 -3
- package/src/js/core/scroll.js +1 -2
- package/src/js/core/scrollspy-nav.js +1 -2
- package/src/js/core/sticky.js +2 -5
- package/src/js/core/switcher.js +10 -12
- package/src/js/core/tab.js +2 -2
- package/src/js/core/toggle.js +3 -5
- package/src/js/mixin/animate.js +7 -7
- package/src/js/mixin/internal/animate-fade.js +2 -2
- package/src/js/mixin/modal.js +4 -6
- package/src/js/mixin/slider-drag.js +1 -2
- package/src/js/mixin/slider-nav.js +7 -8
- package/src/js/mixin/togglable.js +8 -8
- package/src/js/util/dimensions.js +4 -4
- package/src/js/util/event.js +6 -7
- package/src/js/util/lang.js +10 -10
- package/src/js/util/position.js +1 -2
- package/src/js/util/selector.js +2 -2
- package/src/js/util/style.js +2 -2
- package/src/js/util/viewport.js +18 -14
package/dist/js/uikit-core.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.17.9-dev.
|
|
1
|
+
/*! UIkit 3.17.9-dev.77c1d012a | https://www.getuikit.com | (c) 2014 - 2023 YOOtheme | MIT License */
|
|
2
2
|
|
|
3
3
|
(function (global, factory) {
|
|
4
4
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
@@ -386,7 +386,7 @@
|
|
|
386
386
|
let ctx = context;
|
|
387
387
|
if (sel[0] === "!") {
|
|
388
388
|
const selectors = sel.substr(1).trim().split(" ");
|
|
389
|
-
ctx =
|
|
389
|
+
ctx = parent(context).closest(selectors[0]);
|
|
390
390
|
sel = selectors.slice(1).join(" ").trim();
|
|
391
391
|
if (!sel.length && split.length === 1) {
|
|
392
392
|
return ctx;
|
|
@@ -502,7 +502,7 @@
|
|
|
502
502
|
}
|
|
503
503
|
function delegate(selector, listener) {
|
|
504
504
|
return (e) => {
|
|
505
|
-
const current = selector[0] === ">" ? findAll(selector, e.currentTarget).reverse().
|
|
505
|
+
const current = selector[0] === ">" ? findAll(selector, e.currentTarget).reverse().find((element) => element.contains(e.target)) : e.target.closest(selector);
|
|
506
506
|
if (current) {
|
|
507
507
|
e.current = current;
|
|
508
508
|
listener.call(this, e);
|
|
@@ -1323,11 +1323,16 @@
|
|
|
1323
1323
|
}
|
|
1324
1324
|
function getCoveringElement(target) {
|
|
1325
1325
|
return target.ownerDocument.elementsFromPoint(offset(target).left, 0).find(
|
|
1326
|
-
(el) => !el.contains(target) && (
|
|
1326
|
+
(el) => !el.contains(target) && (hasPosition(el, "fixed") && zIndex(
|
|
1327
|
+
parents(target).reverse().find((parent2) => !parent2.contains(el) && !hasPosition(parent2, "static"))
|
|
1328
|
+
) < zIndex(el) || hasPosition(el, "sticky") && parent(el).contains(target))
|
|
1327
1329
|
);
|
|
1328
1330
|
}
|
|
1329
|
-
function
|
|
1330
|
-
return
|
|
1331
|
+
function zIndex(element) {
|
|
1332
|
+
return toFloat(css(element, "zIndex"));
|
|
1333
|
+
}
|
|
1334
|
+
function hasPosition(element, position) {
|
|
1335
|
+
return css(element, "position") === position;
|
|
1331
1336
|
}
|
|
1332
1337
|
function scrollingElement(element) {
|
|
1333
1338
|
return toWindow(element).document.scrollingElement;
|
|
@@ -1454,7 +1459,7 @@
|
|
|
1454
1459
|
return viewport;
|
|
1455
1460
|
}
|
|
1456
1461
|
function commonScrollParents(element, target) {
|
|
1457
|
-
return overflowParents(target).filter((parent) =>
|
|
1462
|
+
return overflowParents(target).filter((parent) => parent.contains(element));
|
|
1458
1463
|
}
|
|
1459
1464
|
function getIntersectionArea(...rects) {
|
|
1460
1465
|
let area = {};
|
|
@@ -1818,11 +1823,7 @@
|
|
|
1818
1823
|
function registerEvent(instance, event, key) {
|
|
1819
1824
|
let { name, el, handler, capture, passive, delegate, filter, self } = isPlainObject(event) ? event : { name: key, handler: event };
|
|
1820
1825
|
el = isFunction(el) ? el.call(instance, instance) : el || instance.$el;
|
|
1821
|
-
if (isArray(el)) {
|
|
1822
|
-
el.forEach((el2) => registerEvent(instance, { ...event, el: el2 }, key));
|
|
1823
|
-
return;
|
|
1824
|
-
}
|
|
1825
|
-
if (!el || filter && !filter.call(instance)) {
|
|
1826
|
+
if (!el || isArray(el) && !el.length || filter && !filter.call(instance)) {
|
|
1826
1827
|
return;
|
|
1827
1828
|
}
|
|
1828
1829
|
instance._events.push(
|
|
@@ -1989,21 +1990,19 @@
|
|
|
1989
1990
|
}
|
|
1990
1991
|
return type ? type(value) : value;
|
|
1991
1992
|
}
|
|
1993
|
+
const listRe = /,(?![^(]*\))/;
|
|
1992
1994
|
function toList(value) {
|
|
1993
|
-
return isArray(value) ? value : isString(value) ? value.split(
|
|
1995
|
+
return isArray(value) ? value : isString(value) ? value.split(listRe).map((value2) => isNumeric(value2) ? toNumber(value2) : toBoolean(value2.trim())) : [value];
|
|
1994
1996
|
}
|
|
1995
1997
|
|
|
1996
1998
|
function initProps(instance) {
|
|
1997
|
-
const props =
|
|
1998
|
-
|
|
1999
|
-
|
|
2000
|
-
|
|
2001
|
-
|
|
2002
|
-
|
|
2003
|
-
|
|
2004
|
-
for (let key in instance.$props) {
|
|
2005
|
-
if (key in props && notIn(exclude, key)) {
|
|
2006
|
-
instance[key] = instance.$props[key];
|
|
1999
|
+
const { $options, $props } = instance;
|
|
2000
|
+
const props = getProps($options);
|
|
2001
|
+
assign($props, props);
|
|
2002
|
+
const { computed, methods } = $options;
|
|
2003
|
+
for (let key in $props) {
|
|
2004
|
+
if (key in props && (!computed || !hasOwn(computed, key)) && (!methods || !hasOwn(methods, key))) {
|
|
2005
|
+
instance[key] = $props[key];
|
|
2007
2006
|
}
|
|
2008
2007
|
}
|
|
2009
2008
|
}
|
|
@@ -2034,9 +2033,6 @@
|
|
|
2034
2033
|
}
|
|
2035
2034
|
return data$1;
|
|
2036
2035
|
}
|
|
2037
|
-
function notIn(options, key) {
|
|
2038
|
-
return options.every((arr) => !arr || !hasOwn(arr, key));
|
|
2039
|
-
}
|
|
2040
2036
|
const getAttributes = memoize((id, props) => {
|
|
2041
2037
|
const attributes = Object.keys(props);
|
|
2042
2038
|
const filter = attributes.concat(id).map((key) => [hyphenate(key), `data-${hyphenate(key)}`]).flat();
|
|
@@ -2154,7 +2150,7 @@
|
|
|
2154
2150
|
};
|
|
2155
2151
|
App.util = util;
|
|
2156
2152
|
App.options = {};
|
|
2157
|
-
App.version = "3.17.9-dev.
|
|
2153
|
+
App.version = "3.17.9-dev.77c1d012a";
|
|
2158
2154
|
|
|
2159
2155
|
const PREFIX = "uk-";
|
|
2160
2156
|
const DATA = "__uikit__";
|
|
@@ -2345,7 +2341,7 @@
|
|
|
2345
2341
|
const instance = this;
|
|
2346
2342
|
attachToElement(el, instance);
|
|
2347
2343
|
instance.$options.el = el;
|
|
2348
|
-
if (
|
|
2344
|
+
if (document.contains(el)) {
|
|
2349
2345
|
callConnected(instance);
|
|
2350
2346
|
}
|
|
2351
2347
|
};
|
|
@@ -2382,16 +2378,16 @@
|
|
|
2382
2378
|
$container: Object.getOwnPropertyDescriptor(App, "container")
|
|
2383
2379
|
});
|
|
2384
2380
|
}
|
|
2385
|
-
const ids =
|
|
2381
|
+
const ids = /* @__PURE__ */ Object.create(null);
|
|
2386
2382
|
function generateId(instance, el = instance.$el, postfix = "") {
|
|
2387
2383
|
if (el.id) {
|
|
2388
2384
|
return el.id;
|
|
2389
2385
|
}
|
|
2390
2386
|
let id = `${instance.$options.id}-${instance._uid}${postfix}`;
|
|
2391
|
-
if (
|
|
2387
|
+
if (ids[id]) {
|
|
2392
2388
|
id = generateId(instance, el, `${postfix}-2`);
|
|
2393
2389
|
}
|
|
2394
|
-
ids
|
|
2390
|
+
ids[id] = true;
|
|
2395
2391
|
return id;
|
|
2396
2392
|
}
|
|
2397
2393
|
|
|
@@ -2729,7 +2725,7 @@
|
|
|
2729
2725
|
contents(items) {
|
|
2730
2726
|
for (const el of items) {
|
|
2731
2727
|
const isOpen = hasClass(
|
|
2732
|
-
this.items.find((item) =>
|
|
2728
|
+
this.items.find((item) => item.contains(el)),
|
|
2733
2729
|
this.clsOpen
|
|
2734
2730
|
);
|
|
2735
2731
|
hide(el, !isOpen);
|
|
@@ -3232,7 +3228,7 @@
|
|
|
3232
3228
|
},
|
|
3233
3229
|
handler({ defaultPrevented, current }) {
|
|
3234
3230
|
const { hash } = current;
|
|
3235
|
-
if (!defaultPrevented && hash && isSameSiteAnchor(current) && !
|
|
3231
|
+
if (!defaultPrevented && hash && isSameSiteAnchor(current) && !this.$el.contains($(hash))) {
|
|
3236
3232
|
this.hide(false);
|
|
3237
3233
|
}
|
|
3238
3234
|
}
|
|
@@ -3336,7 +3332,7 @@
|
|
|
3336
3332
|
name: "hide",
|
|
3337
3333
|
handler({ target }) {
|
|
3338
3334
|
if (this.$el !== target) {
|
|
3339
|
-
active$1 = active$1 === null &&
|
|
3335
|
+
active$1 = active$1 === null && this.$el.contains(target) && this.isToggled() ? this : active$1;
|
|
3340
3336
|
return;
|
|
3341
3337
|
}
|
|
3342
3338
|
active$1 = this.isActive() ? null : active$1;
|
|
@@ -3368,7 +3364,7 @@
|
|
|
3368
3364
|
return;
|
|
3369
3365
|
}
|
|
3370
3366
|
let prev;
|
|
3371
|
-
while (active$1 && prev !== active$1 && !
|
|
3367
|
+
while (active$1 && prev !== active$1 && !active$1.$el.contains(this.$el)) {
|
|
3372
3368
|
prev = active$1;
|
|
3373
3369
|
active$1.hide(false, false);
|
|
3374
3370
|
}
|
|
@@ -3462,7 +3458,7 @@
|
|
|
3462
3458
|
return result;
|
|
3463
3459
|
}
|
|
3464
3460
|
function getViewport$1(el, target) {
|
|
3465
|
-
return offsetViewport(overflowParents(target).find((parent2) =>
|
|
3461
|
+
return offsetViewport(overflowParents(target).find((parent2) => parent2.contains(el)));
|
|
3466
3462
|
}
|
|
3467
3463
|
function createToggleComponent(drop) {
|
|
3468
3464
|
const { $el } = drop.$create("toggle", query(drop.toggle, drop.$el), {
|
|
@@ -3497,18 +3493,19 @@
|
|
|
3497
3493
|
}
|
|
3498
3494
|
function listenForBackgroundClose$1(drop) {
|
|
3499
3495
|
return on(document, pointerDown, ({ target }) => {
|
|
3500
|
-
if (
|
|
3501
|
-
|
|
3502
|
-
document,
|
|
3503
|
-
`${pointerUp} ${pointerCancel} scroll`,
|
|
3504
|
-
({ defaultPrevented, type, target: newTarget }) => {
|
|
3505
|
-
if (!defaultPrevented && type === pointerUp && target === newTarget && !(drop.targetEl && within(target, drop.targetEl))) {
|
|
3506
|
-
drop.hide(false);
|
|
3507
|
-
}
|
|
3508
|
-
},
|
|
3509
|
-
true
|
|
3510
|
-
);
|
|
3496
|
+
if (drop.$el.contains(target)) {
|
|
3497
|
+
return;
|
|
3511
3498
|
}
|
|
3499
|
+
once(
|
|
3500
|
+
document,
|
|
3501
|
+
`${pointerUp} ${pointerCancel} scroll`,
|
|
3502
|
+
({ defaultPrevented, type, target: newTarget }) => {
|
|
3503
|
+
if (!defaultPrevented && type === pointerUp && target === newTarget && !(drop.targetEl && within(target, drop.targetEl))) {
|
|
3504
|
+
drop.hide(false);
|
|
3505
|
+
}
|
|
3506
|
+
},
|
|
3507
|
+
true
|
|
3508
|
+
);
|
|
3512
3509
|
});
|
|
3513
3510
|
}
|
|
3514
3511
|
|
|
@@ -3565,7 +3562,7 @@
|
|
|
3565
3562
|
if (this.dropContainer !== $el) {
|
|
3566
3563
|
for (const el of $$(`.${clsDrop}`, this.dropContainer)) {
|
|
3567
3564
|
const target = (_a = this.getDropdown(el)) == null ? void 0 : _a.targetEl;
|
|
3568
|
-
if (!includes(dropdowns, el) && target &&
|
|
3565
|
+
if (!includes(dropdowns, el) && target && this.$el.contains(target)) {
|
|
3569
3566
|
dropdowns.push(el);
|
|
3570
3567
|
}
|
|
3571
3568
|
}
|
|
@@ -3605,7 +3602,7 @@
|
|
|
3605
3602
|
},
|
|
3606
3603
|
handler({ current }) {
|
|
3607
3604
|
const active2 = this.getActive();
|
|
3608
|
-
if (active2 && includes(active2.mode, "hover") && active2.targetEl && !
|
|
3605
|
+
if (active2 && includes(active2.mode, "hover") && active2.targetEl && !current.contains(active2.targetEl) && !active2.isDelaying) {
|
|
3609
3606
|
active2.hide(false);
|
|
3610
3607
|
}
|
|
3611
3608
|
}
|
|
@@ -3876,7 +3873,7 @@
|
|
|
3876
3873
|
{
|
|
3877
3874
|
name: "reset",
|
|
3878
3875
|
el() {
|
|
3879
|
-
return
|
|
3876
|
+
return this.$el.closest("form");
|
|
3880
3877
|
},
|
|
3881
3878
|
handler() {
|
|
3882
3879
|
this.$emit();
|
|
@@ -4432,7 +4429,7 @@
|
|
|
4432
4429
|
extends: IconComponent,
|
|
4433
4430
|
beforeConnect() {
|
|
4434
4431
|
const icon = this.$props.icon;
|
|
4435
|
-
this.icon =
|
|
4432
|
+
this.icon = this.$el.closest(".uk-nav-primary") ? `${icon}-large` : icon;
|
|
4436
4433
|
}
|
|
4437
4434
|
};
|
|
4438
4435
|
const Search = {
|
|
@@ -4448,7 +4445,7 @@
|
|
|
4448
4445
|
const label = this.t("toggle");
|
|
4449
4446
|
attr(this.$el, "aria-label", label);
|
|
4450
4447
|
} else {
|
|
4451
|
-
const button =
|
|
4448
|
+
const button = this.$el.closest("a,button");
|
|
4452
4449
|
if (button) {
|
|
4453
4450
|
const label = this.t("submit");
|
|
4454
4451
|
attr(button, "aria-label", label);
|
|
@@ -4475,7 +4472,7 @@
|
|
|
4475
4472
|
extends: IconComponent,
|
|
4476
4473
|
mixins: [I18n],
|
|
4477
4474
|
beforeConnect() {
|
|
4478
|
-
const button =
|
|
4475
|
+
const button = this.$el.closest("a,button");
|
|
4479
4476
|
attr(button, "role", this.role !== null && isTag(button, "a") ? "button" : this.role);
|
|
4480
4477
|
const label = this.t("label");
|
|
4481
4478
|
if (label && !hasAttr(button, "aria-label")) {
|
|
@@ -4802,7 +4799,7 @@
|
|
|
4802
4799
|
handler(e) {
|
|
4803
4800
|
const { current, defaultPrevented } = e;
|
|
4804
4801
|
const { hash } = current;
|
|
4805
|
-
if (!defaultPrevented && hash && isSameSiteAnchor(current) && !
|
|
4802
|
+
if (!defaultPrevented && hash && isSameSiteAnchor(current) && !this.$el.contains($(hash))) {
|
|
4806
4803
|
this.hide();
|
|
4807
4804
|
} else if (matches(current, this.selClose)) {
|
|
4808
4805
|
e.preventDefault();
|
|
@@ -4937,14 +4934,14 @@
|
|
|
4937
4934
|
}
|
|
4938
4935
|
function preventBackgroundFocus(modal) {
|
|
4939
4936
|
return on(document, "focusin", (e) => {
|
|
4940
|
-
if (last(active) === modal && !
|
|
4937
|
+
if (last(active) === modal && !modal.$el.contains(e.target)) {
|
|
4941
4938
|
modal.$el.focus();
|
|
4942
4939
|
}
|
|
4943
4940
|
});
|
|
4944
4941
|
}
|
|
4945
4942
|
function listenForBackgroundClose(modal) {
|
|
4946
4943
|
return on(document, pointerDown, ({ target }) => {
|
|
4947
|
-
if (last(active) !== modal || modal.overlay && !
|
|
4944
|
+
if (last(active) !== modal || modal.overlay && !modal.$el.contains(target) || modal.panel.contains(target)) {
|
|
4948
4945
|
return;
|
|
4949
4946
|
}
|
|
4950
4947
|
once(
|
|
@@ -5090,7 +5087,7 @@
|
|
|
5090
5087
|
dropbarTransparentMode: false
|
|
5091
5088
|
},
|
|
5092
5089
|
computed: {
|
|
5093
|
-
navbarContainer: (_, $el) => closest(
|
|
5090
|
+
navbarContainer: (_, $el) => $el.closest(".uk-navbar-container"),
|
|
5094
5091
|
dropbarOffset: ({ dropbarTransparentMode }, $el) => dropbarTransparentMode === "behind" ? $el.offsetHeight : 0
|
|
5095
5092
|
},
|
|
5096
5093
|
watch: {
|
|
@@ -5393,8 +5390,8 @@
|
|
|
5393
5390
|
minHeight: 150
|
|
5394
5391
|
},
|
|
5395
5392
|
computed: {
|
|
5396
|
-
container: ({ selContainer }, $el) => closest(
|
|
5397
|
-
content: ({ selContent }, $el) => closest(
|
|
5393
|
+
container: ({ selContainer }, $el) => $el.closest(selContainer),
|
|
5394
|
+
content: ({ selContent }, $el) => $el.closest(selContent)
|
|
5398
5395
|
},
|
|
5399
5396
|
observe: resize({
|
|
5400
5397
|
target: ({ container, content }) => [container, content]
|
|
@@ -5487,7 +5484,7 @@
|
|
|
5487
5484
|
return;
|
|
5488
5485
|
}
|
|
5489
5486
|
for (const instance of instances) {
|
|
5490
|
-
if (
|
|
5487
|
+
if (instance.$el.contains(e.target) && isSameSiteAnchor(instance.$el)) {
|
|
5491
5488
|
e.preventDefault();
|
|
5492
5489
|
if (window.location.href !== instance.$el.href) {
|
|
5493
5490
|
window.history.pushState({}, "", instance.$el.href);
|
|
@@ -5620,7 +5617,7 @@
|
|
|
5620
5617
|
computed: {
|
|
5621
5618
|
links: (_, $el) => $$('a[href*="#"]', $el).filter((el) => el.hash && isSameSiteAnchor(el)),
|
|
5622
5619
|
elements({ closest: selector }) {
|
|
5623
|
-
return this.links.map((el) => closest(
|
|
5620
|
+
return this.links.map((el) => el.closest(selector || "*"));
|
|
5624
5621
|
}
|
|
5625
5622
|
},
|
|
5626
5623
|
watch: {
|
|
@@ -5843,7 +5840,7 @@
|
|
|
5843
5840
|
}
|
|
5844
5841
|
const { placeholder } = this;
|
|
5845
5842
|
css(placeholder, { height, width, margin });
|
|
5846
|
-
if (!
|
|
5843
|
+
if (!document.contains(placeholder)) {
|
|
5847
5844
|
placeholder.hidden = true;
|
|
5848
5845
|
}
|
|
5849
5846
|
(sticky ? before : after)(this.$el, placeholder);
|
|
@@ -6006,7 +6003,7 @@
|
|
|
6006
6003
|
return propOffset + toPx(value, "height", el, true);
|
|
6007
6004
|
} else {
|
|
6008
6005
|
const refElement = value === true ? parent(el) : query(value, el);
|
|
6009
|
-
return offset(refElement).bottom - (padding && refElement
|
|
6006
|
+
return offset(refElement).bottom - (padding && (refElement == null ? void 0 : refElement.contains(el)) ? toFloat(css(refElement, "paddingBottom")) : 0);
|
|
6010
6007
|
}
|
|
6011
6008
|
}
|
|
6012
6009
|
function coerce(value) {
|
|
@@ -6170,7 +6167,7 @@
|
|
|
6170
6167
|
toggles: ({ toggle }, $el) => $$(toggle, $el),
|
|
6171
6168
|
children(_, $el) {
|
|
6172
6169
|
return children($el).filter(
|
|
6173
|
-
(child) => this.toggles.some((toggle) =>
|
|
6170
|
+
(child) => this.toggles.some((toggle) => child.contains(toggle))
|
|
6174
6171
|
);
|
|
6175
6172
|
}
|
|
6176
6173
|
},
|
|
@@ -6243,7 +6240,7 @@
|
|
|
6243
6240
|
return `[${this.attrItem}],[data-${this.attrItem}]`;
|
|
6244
6241
|
},
|
|
6245
6242
|
handler(e) {
|
|
6246
|
-
if (
|
|
6243
|
+
if (e.target.closest("a,button")) {
|
|
6247
6244
|
e.preventDefault();
|
|
6248
6245
|
this.show(data(e.current, this.attrItem));
|
|
6249
6246
|
}
|
|
@@ -6381,7 +6378,7 @@
|
|
|
6381
6378
|
pointerDown,
|
|
6382
6379
|
() => trigger(this.$el, "blur"),
|
|
6383
6380
|
true,
|
|
6384
|
-
(e2) => !
|
|
6381
|
+
(e2) => !this.$el.contains(e2.target)
|
|
6385
6382
|
);
|
|
6386
6383
|
if (includes(this.mode, "click")) {
|
|
6387
6384
|
this._preventClick = true;
|
|
@@ -6433,7 +6430,7 @@
|
|
|
6433
6430
|
},
|
|
6434
6431
|
handler(e) {
|
|
6435
6432
|
let link;
|
|
6436
|
-
if (this._preventClick ||
|
|
6433
|
+
if (this._preventClick || e.target.closest('a[href="#"], a[href=""]') || (link = e.target.closest("a[href]")) && (!this.isToggled(this.target) || link.hash && matches(this.target, link.hash))) {
|
|
6437
6434
|
e.preventDefault();
|
|
6438
6435
|
}
|
|
6439
6436
|
if (!this._preventClick && includes(this.mode, "click")) {
|